FaceEditor previously required an HTMLImageElement | HTMLVideoElement prop to compute layout metrics and generate the face crop preview. This was unavailable for video assets, so the preview thumbnail in the Create Person modal was always missing, and face positions could be NaN during image load (naturalWidth is 0 before the image decodes). Replace the DOM element prop with assetSize: Size and containerSize: Size, using asset metadata dimensions that are always available from the API response. computeContentMetrics() is extracted as a pure utility alongside mapContentRectToNatural() for converting face rect coordinates back to original image space. For videos, VideoNativeViewer now captures the current frame to canvas when face edit mode opens and sets assetViewerManager.imgRef, giving FaceEditor the same image-based preview path as photo assets. Change-Id: I0e9da549e3af40211abad4ab2c0270706a6a6964 |
||
|---|---|---|
| .. | ||
| bin | ||
| src | ||
| static | ||
| tests | ||
| .browserslistrc | ||
| .dockerignore | ||
| .gitignore | ||
| .npmrc | ||
| .prettierignore | ||
| .prettierrc | ||
| README.md | ||
| eslint.config.js | ||
| mise.toml | ||
| package.json | ||
| svelte.config.js | ||
| tsconfig.json | ||
| vite.config.ts | ||
README.md
Immich web project
This project uses the SvelteKit web framework. Please refer to the SvelteKit docs for information on getting started as a contributor to this project. In particular, it will help you navigate the project's code if you understand the basics of SvelteKit routing.
When developing locally, you will run a SvelteKit Node.js server. When this project is deployed to production, it is built as a SPA and deployed as part of the server project.