@@ -89,10 +89,10 @@ import { subscribe, unsubscribe, type Event as NextcloudEvent, type EventHandler
8989import { loadState } from ' @nextcloud/initial-state'
9090import { t } from ' @nextcloud/l10n'
9191import { generateOcsUrl } from ' @nextcloud/router'
92- import { computed , getCurrentInstance , nextTick , onBeforeUnmount , onMounted , ref } from ' vue'
92+ import { computed , getCurrentInstance , nextTick , onBeforeUnmount , onMounted , ref , type ComponentPublicInstance } from ' vue'
9393
9494import PdfEditor from ' ../PdfEditor/PdfEditor.vue'
95- import type { PdfEditorObject , PdfEditorPublicApi , PdfEditorSigner } from ' ../PdfEditor/types '
95+ import type { PdfEditorObject , PdfEditorSigner } from ' ../PdfEditor/pdfEditorModel '
9696import Signer from ' ../Signers/Signer.vue'
9797
9898import { FILE_STATUS } from ' ../../constants.js'
@@ -167,8 +167,11 @@ type PdfElementsRef = {
167167 isAddingMode? : boolean
168168}
169169
170- type PdfEditorRef = PdfEditorPublicApi & {
170+ type PdfEditorRef = ComponentPublicInstance & {
171171 $refs? : { pdfElements? : PdfElementsRef }
172+ startAddingSigner? : (signer : PlacementSigner | null | undefined , size : { width? : number , height? : number }) => boolean
173+ cancelAdding? : () => void
174+ addSigner? : (signer : PlacementSigner ) => Promise <void >
172175}
173176
174177type FilesStore = Pick <ReturnType <typeof useFilesStore >, ' loading' | ' getFile' | ' saveOrUpdateSignatureRequest' > & {
@@ -715,7 +718,7 @@ function buildVisibleElements() {
715718
716719 for (let docIndex = 0 ; docIndex < numDocuments ; docIndex ++ ) {
717720 const objects = pdfElements ?.getAllObjects (docIndex ) || []
718- objects .forEach ((object ) => {
721+ objects .forEach ((object : PdfObject ) => {
719722 if (! object .signer ) return
720723
721724 let globalPageNumber = object .pageNumber
0 commit comments