Skip to content

armgit / ente

Public Imported from GitHub
0

πŸ’š End-to-end encrypted cloud for everything.

refractor(web):move-photos-specfic-component-from-pkgs-p4

Aswin Asokd83eeb60441d
diff --git a/web/apps/photos/package.json b/web/apps/photos/package.json
index ebd56d8037..e59fc12993 100644
--- a/web/apps/photos/package.json
+++ b/web/apps/photos/package.json
@@ -9,6 +9,8 @@
"@fontsource-variable/outfit": "5.2.8",
"@hugeicons/core-free-icons": "1.2.1",
"@hugeicons/react": "1.1.6",
+ "@mui/icons-material": "9.2.0",
+ "@mui/material": "9.2.0",
"chrono-node": "2.9.1",
"debounce": "2.2.0",
"ente-accounts": "*",
@@ -18,11 +20,13 @@
"ente-media": "*",
"ente-new": "*",
"ente-wasm": "*",
+ "i18next": "26.3.1",
"memoize-one": "6.0.0",
"ml-matrix": "6.12.2",
"p-debounce": "5.1.0",
"react": "19.2.7",
"react-dom": "19.2.7",
+ "react-i18next": "16.6.6",
"react-leaflet": "5.0.0",
"react-select": "5.10.2",
"react-top-loading-bar": "3.0.2",
diff --git a/web/apps/photos/src/components/gallery/helpers.ts b/web/apps/photos/src/components/gallery/helpers.ts
index f8930521d2..a14bde9e2b 100644
--- a/web/apps/photos/src/components/gallery/helpers.ts
+++ b/web/apps/photos/src/components/gallery/helpers.ts
@@ -1,13 +1,8 @@
/**
- * @file code that really belongs to pages/gallery.tsx itself, but it written
- * here in a separate file so that we can write in this package that has
- * TypeScript strict mode enabled.
- *
- * Once the original gallery.tsx is strict mode, this code can be inlined back
- * there.
+ * @file [Note: Gallery page logic] Logic and components for the gallery page, split out of pages/gallery.tsx.
*
* Separate from index.tsx so that it can export non-(React-)components, which
- * is a needed for fast refresh to work.
+ * is needed for fast refresh to work.
*/
import type { CollectionOp } from "@/components/SelectedFileOptions";
diff --git a/web/apps/photos/src/components/gallery/index.tsx b/web/apps/photos/src/components/gallery/index.tsx
index aa86defd8b..fa7ef1ff83 100644
--- a/web/apps/photos/src/components/gallery/index.tsx
+++ b/web/apps/photos/src/components/gallery/index.tsx
@@ -1,10 +1,5 @@
/**
- * @file code that really belongs to pages/gallery.tsx itself (or related
- * files), but it written here in a separate file so that we can write in this
- * package that has TypeScript strict mode enabled.
- *
- * Once the original gallery.tsx is strict mode, this code can be inlined back
- * there.
+ * @file [Note: Gallery page logic] Logic and components for the gallery page, split out of pages/gallery.tsx.
*/
import { EnableML, FaceConsent } from "@/components/sidebar/MLSettings";
diff --git a/web/apps/photos/tests/file-actions.test.ts b/web/apps/photos/tests/file-actions.test.ts
index c334eba472..f6b8d8b2e8 100644
--- a/web/apps/photos/tests/file-actions.test.ts
+++ b/web/apps/photos/tests/file-actions.test.ts
@@ -1,6 +1,6 @@
+import { getAvailableFileActions } from "@/utils/file-actions";
import type { CollectionSummary } from "ente-new/photos/services/collection-summary";
import { describe, expect, test } from "vitest";
-import { getAvailableFileActions } from "../src/utils/file-actions";
describe("getAvailableFileActions", () => {
test("uses shared actions for an incoming uncategorized collection", () => {
diff --git a/web/apps/photos/vitest.config.ts b/web/apps/photos/vitest.config.ts
new file mode 100644
index 0000000000..c6ba486028
--- /dev/null
+++ b/web/apps/photos/vitest.config.ts
@@ -0,0 +1,6 @@
+import path from "node:path";
+import { defineConfig } from "vitest/config";
+
+export default defineConfig({
+ resolve: { alias: { "@": path.resolve(__dirname, "./src") } },
+});
diff --git a/web/package-lock.json b/web/package-lock.json
index 48ca2af0a4..46983cbe73 100644
--- a/web/package-lock.json
+++ b/web/package-lock.json
@@ -283,6 +283,8 @@
"@fontsource-variable/outfit": "5.2.8",
"@hugeicons/core-free-icons": "1.2.1",
"@hugeicons/react": "1.1.6",
+ "@mui/icons-material": "9.2.0",
+ "@mui/material": "9.2.0",
"chrono-node": "2.9.1",
"debounce": "2.2.0",
"ente-accounts": "*",
@@ -292,11 +294,13 @@
"ente-media": "*",
"ente-new": "*",
"ente-wasm": "*",
+ "i18next": "26.3.1",
"memoize-one": "6.0.0",
"ml-matrix": "6.12.2",
"p-debounce": "5.1.0",
"react": "19.2.7",
"react-dom": "19.2.7",
+ "react-i18next": "16.6.6",
"react-leaflet": "5.0.0",
"react-select": "5.10.2",
"react-top-loading-bar": "3.0.2",
@@ -11243,17 +11247,13 @@
"name": "ente-new",
"version": "0.0.0",
"dependencies": {
- "@hugeicons/core-free-icons": "1.2.1",
- "@hugeicons/react": "1.1.6",
"@mui/material": "9.2.0",
- "@mui/system": "9.2.0",
"@mui/x-date-pickers": "9.8.0",
"dayjs": "1.11.21",
"ente-base": "*",
"ente-gallery": "*",
"ente-utils": "*",
- "react": "19.2.7",
- "react-dom": "19.2.7"
+ "react": "19.2.7"
},
"devDependencies": {
"@types/react": "19.2.17",
diff --git a/web/packages/new/package.json b/web/packages/new/package.json
index 8406c1a457..2bedfbbdfd 100644
--- a/web/packages/new/package.json
+++ b/web/packages/new/package.json
@@ -3,17 +3,13 @@
"version": "0.0.0",
"private": true,
"dependencies": {
- "@hugeicons/core-free-icons": "1.2.1",
- "@hugeicons/react": "1.1.6",
"@mui/material": "9.2.0",
- "@mui/system": "9.2.0",
"@mui/x-date-pickers": "9.8.0",
"dayjs": "1.11.21",
"ente-base": "*",
"ente-gallery": "*",
"ente-utils": "*",
- "react": "19.2.7",
- "react-dom": "19.2.7"
+ "react": "19.2.7"
},
"devDependencies": {
"@types/react": "19.2.17",