diff --git a/apps/readest-app/src/app/reader/components/FoliateViewer.tsx b/apps/readest-app/src/app/reader/components/FoliateViewer.tsx index e006c693..23254720 100644 --- a/apps/readest-app/src/app/reader/components/FoliateViewer.tsx +++ b/apps/readest-app/src/app/reader/components/FoliateViewer.tsx @@ -178,6 +178,13 @@ const FoliateViewer: React.FC<{ manageSyntaxHighlighting(detail.doc, viewSettings); } + setTimeout(() => { + const booknotes = config.booknotes || []; + booknotes + .filter((item) => !item.deletedAt && item.type === 'annotation' && item.style) + .forEach((annotation) => viewRef.current?.addAnnotation(annotation)); + }, 100); + if (!detail.doc.isEventListenersAdded) { // listened events in iframes are posted to the main window // and then used by useMouseEvent and useTouchEvent