From 7bce77925449e2bcfa2db5d66dc5f808e04058c7 Mon Sep 17 00:00:00 2001 From: Reto Brunner Date: Mon, 15 May 2023 09:37:40 +0200 Subject: [PATCH 1/2] Remove unused code --- client/components/App.vue | 5 ----- 1 file changed, 5 deletions(-) diff --git a/client/components/App.vue b/client/components/App.vue index 61bbb3b7..9ae4190f 100644 --- a/client/components/App.vue +++ b/client/components/App.vue @@ -38,7 +38,6 @@ import { ref, Ref, InjectionKey, - inject, } from "vue"; import {useStore} from "../js/store"; import type {DebouncedFunc} from "lodash"; @@ -47,10 +46,6 @@ export const imageViewerKey = Symbol() as InjectionKey>; const confirmDialogKey = Symbol() as InjectionKey>; -export const useImageViewer = () => { - return inject(imageViewerKey) as Ref; -}; - export default defineComponent({ name: "App", components: { From 93889604973eeefb3a875e3ad5c9de737638888c Mon Sep 17 00:00:00 2001 From: Reto Brunner Date: Mon, 15 May 2023 09:38:09 +0200 Subject: [PATCH 2/2] linkPreview: Pass channel prop Else the update logic doesn't work and we don't show the next / prev buttons --- client/components/ImageViewer.vue | 1 + 1 file changed, 1 insertion(+) diff --git a/client/components/ImageViewer.vue b/client/components/ImageViewer.vue index 31b8d750..04ca49d3 100644 --- a/client/components/ImageViewer.vue +++ b/client/components/ImageViewer.vue @@ -456,6 +456,7 @@ export default defineComponent({ return { link, + channel, image, transform, closeViewer,