This commit is contained in:
isUnknown 2024-12-11 13:44:50 +01:00
parent c8f99347d2
commit c7fbbe1c01
4 changed files with 22 additions and 5 deletions

View file

@ -0,0 +1,9 @@
Cover:
----
Uuid: b2ltra1aFapPGYX7
----
Template: pdf

View file

@ -6,7 +6,7 @@ Rawglass: - file://WrFkfiMVZuxwdYad
----
Finishedglass: - file://6pNYNJpB2BCTWAEn
Finishedglass: - file://b2ltra1aFapPGYX7
----

View file

@ -1,5 +1,6 @@
<template>
<VPdfViewer
v-if="!isViewerDisabled"
:darkMode="true"
:initialThumbnailsVisible="true"
:src="openedFile.url"
@ -33,6 +34,8 @@ const { openedFile, isCommentsOpen, comments } = storeToRefs(useDialogStore());
const draftComment = ref(null);
const isViewerDisabled = ref(false);
watch(isCommentsOpen, (newVal) => {
if (newVal) {
setCommentMarkers();
@ -42,10 +45,15 @@ watch(isCommentsOpen, (newVal) => {
});
watch(openedFile, (newVal) => {
removeCommentMarkers();
if (newVal.comments) {
setCommentMarkers();
}
isViewerDisabled.value = true;
setTimeout(() => {
isViewerDisabled.value = false;
removeCommentMarkers();
if (newVal.comments) {
setCommentMarkers();
}
}, 100);
});
const currentPageIndex = ref(1);