diff --git a/web/package-lock.json b/web/package-lock.json index 82ff896da0..7d228eedd3 100644 --- a/web/package-lock.json +++ b/web/package-lock.json @@ -18,6 +18,7 @@ "luxon": "^3.1.1", "rxjs": "^7.8.0", "socket.io-client": "^4.5.1", + "svelte-keydown": "^0.5.0", "svelte-material-icons": "^2.0.2" }, "devDependencies": { @@ -54,6 +55,7 @@ "svelte": "^3.44.0", "svelte-check": "^2.7.1", "svelte-jester": "^2.3.2", + "svelte-keydown": "^0.5.0", "svelte-preprocess": "^4.10.7", "tailwindcss": "^3.0.24", "tslib": "^2.3.1", @@ -10599,6 +10601,12 @@ "svelte": ">= 3" } }, + "node_modules/svelte-keydown": { + "version": "0.5.0", + "resolved": "https://registry.npmjs.org/svelte-keydown/-/svelte-keydown-0.5.0.tgz", + "integrity": "sha512-DgY6AYlKbBocSvjC3kUeNPcStJQOTOCxAGG9ymVHzJdsQ1hRJuB8pcnB4UFH8uH3bAPdYyXXa3LwenLDL41eqQ==", + "dev": true + }, "node_modules/svelte-material-icons": { "version": "2.0.4", "resolved": "https://registry.npmjs.org/svelte-material-icons/-/svelte-material-icons-2.0.4.tgz", @@ -19039,6 +19047,12 @@ "dev": true, "requires": {} }, + "svelte-keydown": { + "version": "0.5.0", + "resolved": "https://registry.npmjs.org/svelte-keydown/-/svelte-keydown-0.5.0.tgz", + "integrity": "sha512-DgY6AYlKbBocSvjC3kUeNPcStJQOTOCxAGG9ymVHzJdsQ1hRJuB8pcnB4UFH8uH3bAPdYyXXa3LwenLDL41eqQ==", + "dev": true + }, "svelte-material-icons": { "version": "2.0.4", "resolved": "https://registry.npmjs.org/svelte-material-icons/-/svelte-material-icons-2.0.4.tgz", diff --git a/web/package.json b/web/package.json index 30261e1baa..7872f283a3 100644 --- a/web/package.json +++ b/web/package.json @@ -52,6 +52,7 @@ "svelte": "^3.44.0", "svelte-check": "^2.7.1", "svelte-jester": "^2.3.2", + "svelte-keydown": "^0.5.0", "svelte-preprocess": "^4.10.7", "tailwindcss": "^3.0.24", "tslib": "^2.3.1", @@ -69,6 +70,7 @@ "luxon": "^3.1.1", "rxjs": "^7.8.0", "socket.io-client": "^4.5.1", + "svelte-keydown": "^0.5.0", "svelte-material-icons": "^2.0.2" } } diff --git a/web/src/lib/components/asset-viewer/asset-viewer.svelte b/web/src/lib/components/asset-viewer/asset-viewer.svelte index 0703abfe11..2199359432 100644 --- a/web/src/lib/components/asset-viewer/asset-viewer.svelte +++ b/web/src/lib/components/asset-viewer/asset-viewer.svelte @@ -304,7 +304,7 @@ on:onVideoEnded={() => (shouldPlayMotionPhoto = false)} /> {:else} - + {/if} {:else} diff --git a/web/src/lib/components/asset-viewer/photo-viewer.svelte b/web/src/lib/components/asset-viewer/photo-viewer.svelte index 63ab7107b9..9a2d2dacf2 100644 --- a/web/src/lib/components/asset-viewer/photo-viewer.svelte +++ b/web/src/lib/components/asset-viewer/photo-viewer.svelte @@ -1,21 +1,39 @@ - + + + await doCopy()} />
- {#await loadAssetData()} - - {:then assetData} - {asset.id} - {/await} + {#if assetInfo} + {#await loadAssetData()} + + {:then assetData} + {assetId} + {/await} + {/if}
diff --git a/web/src/lib/components/asset-viewer/video-viewer.svelte b/web/src/lib/components/asset-viewer/video-viewer.svelte index 9af30c8c16..ba1e580b00 100644 --- a/web/src/lib/components/asset-viewer/video-viewer.svelte +++ b/web/src/lib/components/asset-viewer/video-viewer.svelte @@ -1,17 +1,40 @@