diff --git a/src/components/Metadata.vue b/src/components/Metadata.vue index 31bbde9a..d31f80ed 100644 --- a/src/components/Metadata.vue +++ b/src/components/Metadata.vue @@ -2,7 +2,7 @@
{{ t('memories', 'Albums') }}
- +
{{ t('memories', 'Metadata') }}
@@ -74,6 +74,7 @@ import TagIcon from 'vue-material-design-icons/Tag.vue'; import * as utils from '../services/Utils'; import { API } from '../services/API'; +import router from '../router'; import type { IAlbum, IImageInfo, IPhoto } from '../types'; @@ -373,6 +374,16 @@ export default defineComponent({ return (this.albums = list); }, + openAlbum(album: IAlbum) { + router.push({ + name: 'albums', + params: { + name: album.name, + user: album.user, + }, + }); + }, + handleFileUpdated({ fileid }: { fileid: number }) { if (fileid && this.fileid === fileid) { this.update(this.fileid); diff --git a/src/components/Timeline.vue b/src/components/Timeline.vue index f5f168bc..415221b6 100644 --- a/src/components/Timeline.vue +++ b/src/components/Timeline.vue @@ -275,7 +275,7 @@ export default defineComponent({ } globalThis.mViewer.open(photo, this.list); - } else if (from?.hash?.startsWith('#v') && !to.hash?.startsWith('#v') && viewerIsOpen) { + } else if (!to.hash?.startsWith('#v') && viewerIsOpen) { // Close viewer globalThis.mViewer.close(); } diff --git a/src/components/modal/AlbumPicker.vue b/src/components/modal/AlbumPicker.vue index 79ab29d6..c5beade0 100644 --- a/src/components/modal/AlbumPicker.vue +++ b/src/components/modal/AlbumPicker.vue @@ -1,6 +1,6 @@