superdoc 2.28.0 → 2.29.0-next.13

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (192) hide show
  1. package/dist/chunks/{FindReplaceSurface-Dm043CZP.es.js → FindReplaceSurface-BKVHzhQ4.es.js} +34 -26
  2. package/dist/chunks/{FindReplaceSurface-BRs3JrCq.cjs → FindReplaceSurface-BNDrJ6VS.cjs} +34 -26
  3. package/dist/chunks/{PasswordPromptSurface-DGjmN7A-.es.js → PasswordPromptSurface-6mF6Azda.es.js} +6 -4
  4. package/dist/chunks/{PasswordPromptSurface-BpqP4pUa.cjs → PasswordPromptSurface-BNkaztaP.cjs} +6 -4
  5. package/dist/chunks/{PdfViewer-Cg072l5d.cjs → PdfViewer-DmSkZehl.cjs} +72 -100
  6. package/dist/chunks/{PdfViewer-JHXZQZ9x.es.js → PdfViewer-aOWhUVI7.es.js} +69 -97
  7. package/dist/chunks/{constants-DpXuDx_g.cjs → constants-BeeNZoQp.cjs} +1 -1
  8. package/dist/chunks/{constants-B6VBlmKp.es.js → constants-BvNs_ybI.es.js} +1 -1
  9. package/dist/chunks/{create-super-doc-ui-BbjHD1ul.es.js → create-super-doc-ui-DdT4b29f.es.js} +200 -65
  10. package/dist/chunks/{create-super-doc-ui-BfgYblyI.cjs → create-super-doc-ui-_SbygYQ4.cjs} +227 -68
  11. package/dist/chunks/is-finite-number-BEXgTRgc.cjs +11 -0
  12. package/dist/chunks/is-finite-number-BpL4F38c.es.js +6 -0
  13. package/dist/collaboration-upgrade-engine.cjs +1 -1
  14. package/dist/collaboration-upgrade-engine.es.js +1 -1
  15. package/dist/document-api/src/capabilities/html-markdown-support.d.ts +4 -6
  16. package/dist/document-api/src/comments/comments.d.ts +2 -0
  17. package/dist/document-api/src/contract/metadata-types.d.ts +1 -1
  18. package/dist/document-api/src/contract/operation-definitions.d.ts +3 -3
  19. package/dist/document-api/src/contract/operation-registry.d.ts +10 -9
  20. package/dist/document-api/src/index.d.ts +8 -7
  21. package/dist/document-api/src/insert/insert.d.ts +2 -2
  22. package/dist/document-api/src/lists/lists.d.ts +79 -79
  23. package/dist/document-api/src/replace/replace.d.ts +3 -2
  24. package/dist/document-api/src/tables/tables.d.ts +2 -1
  25. package/dist/document-api/src/types/address.d.ts +3 -0
  26. package/dist/document-api/src/types/table-operations.types.d.ts +1 -0
  27. package/dist/document-api/src/types/temporary-mutation.d.ts +5 -1
  28. package/dist/document-api/src/write/write.d.ts +18 -11
  29. package/dist/layout-engine/contracts/src/index.d.ts +1 -1
  30. package/dist/layout-engine/contracts/src/paragraph-visible-text.d.ts +3 -1
  31. package/dist/layout-engine/painters/dom/src/page-content.d.ts +1 -1
  32. package/dist/layout-engine/painters/dom/src/persistent-page-surface.d.ts +2 -0
  33. package/dist/public/ui-react.cjs +1 -1
  34. package/dist/public/ui-react.es.js +1 -1
  35. package/dist/public/ui-vue.cjs +1 -1
  36. package/dist/public/ui-vue.es.js +1 -1
  37. package/dist/public/ui.cjs +1 -1
  38. package/dist/public/ui.es.js +1 -1
  39. package/dist/style.css +1 -1
  40. package/dist/style.layered.css +1 -1
  41. package/dist/superdoc/src/SuperDoc.vue.d.ts +137 -61
  42. package/dist/superdoc/src/components/CommentsLayer/CommentDialog.vue.d.ts +533 -48
  43. package/dist/superdoc/src/components/CommentsLayer/CommentHeader.vue.d.ts +107 -23
  44. package/dist/superdoc/src/components/CommentsLayer/CommentInput.vue.d.ts +74 -14
  45. package/dist/superdoc/src/components/CommentsLayer/CommentsDropdown.vue.d.ts +55 -20
  46. package/dist/superdoc/src/components/CommentsLayer/FloatingComments.vue.d.ts +21 -8
  47. package/dist/superdoc/src/components/CommentsLayer/InternalDropdown.vue.d.ts +24 -8
  48. package/dist/superdoc/src/components/CommentsLayer/PdfCommentsLayer.vue.d.ts +5 -3
  49. package/dist/superdoc/src/components/CommentsLayer/commentsList/ReviewDirectoryListItem.vue.d.ts +60 -12
  50. package/dist/superdoc/src/components/CommentsLayer/commentsList/commentsList.vue.d.ts +20 -6
  51. package/dist/superdoc/src/components/CommentsLayer/floating-comment-positioning.d.ts +24 -23
  52. package/dist/superdoc/src/components/CommentsLayer/tracked-change-threading.d.ts +0 -1
  53. package/dist/superdoc/src/components/CommentsLayer/use-comment.d.ts +29 -13
  54. package/dist/superdoc/src/components/PdfViewer/PdfViewer.vue.d.ts +132 -45
  55. package/dist/superdoc/src/components/PdfViewer/PdfViewerDocument.vue.d.ts +62 -16
  56. package/dist/superdoc/src/components/PdfViewer/PdfViewerPage.vue.d.ts +77 -17
  57. package/dist/superdoc/src/components/PdfViewer/pdf-viewer-types.d.ts +45 -0
  58. package/dist/superdoc/src/components/Whiteboard/WhiteboardLayer.vue.d.ts +81 -16
  59. package/dist/superdoc/src/components/Whiteboard/WhiteboardPage.vue.d.ts +49 -13
  60. package/dist/superdoc/src/components/Whiteboard/use-whiteboard.d.ts +30 -15
  61. package/dist/superdoc/src/components/Whiteboard/whiteboard-types.d.ts +11 -0
  62. package/dist/superdoc/src/components/general/Avatar.vue.d.ts +14 -0
  63. package/dist/superdoc/src/components/surfaces/FindReplaceSurface.vue.d.ts +58 -15
  64. package/dist/superdoc/src/components/surfaces/PasswordPromptSurface.vue.d.ts +58 -15
  65. package/dist/superdoc/src/components/surfaces/SurfaceDialog.vue.d.ts +27 -9
  66. package/dist/superdoc/src/components/surfaces/SurfaceExternalMount.vue.d.ts +53 -16
  67. package/dist/superdoc/src/components/surfaces/SurfaceFloating.vue.d.ts +14 -6
  68. package/dist/superdoc/src/components/surfaces/SurfaceHost.vue.d.ts +25 -15
  69. package/dist/superdoc/src/components/surfaces/focusable-selector.d.ts +1 -5
  70. package/dist/superdoc/src/components/surfaces/watermark-surface-runtime.d.ts +7 -7
  71. package/dist/superdoc/src/composables/find-shortcut-owner.d.ts +16 -9
  72. package/dist/superdoc/src/composables/replace-continuation.d.ts +11 -15
  73. package/dist/superdoc/src/composables/use-comment-small-screen.d.ts +11 -7
  74. package/dist/superdoc/src/composables/use-compact-comment-popover.d.ts +44 -18
  75. package/dist/superdoc/src/composables/use-document.d.ts +1210 -30
  76. package/dist/superdoc/src/composables/use-field.d.ts +88 -25
  77. package/dist/superdoc/src/composables/use-link-popover.d.ts +3 -3
  78. package/dist/superdoc/src/composables/use-password-prompt.d.ts +23 -24
  79. package/dist/superdoc/src/composables/use-superdoc-instance.d.ts +4 -1
  80. package/dist/superdoc/src/composables/use-viewport-fit.d.ts +40 -26
  81. package/dist/superdoc/src/composables/useUiFontFamily.d.ts +3 -11
  82. package/dist/superdoc/src/core/SuperDoc.d.ts +3 -8
  83. package/dist/superdoc/src/core/collaboration/collaboration-comments.d.ts +9 -4
  84. package/dist/superdoc/src/core/collaboration/helpers.d.ts +20 -3
  85. package/dist/superdoc/src/core/collaboration/permissions.d.ts +15 -9
  86. package/dist/superdoc/src/core/collaboration/resolve-v2-collaboration-target.d.ts +4 -3
  87. package/dist/superdoc/src/core/collaboration/v2-awareness-bridge.d.ts +2 -1
  88. package/dist/superdoc/src/core/config/merge-comments-config.d.ts +1 -5
  89. package/dist/superdoc/src/core/config/merge-defined.d.ts +3 -8
  90. package/dist/superdoc/src/core/config/normalize-hyperlinks-config.d.ts +7 -12
  91. package/dist/superdoc/src/core/config/normalize-surfaces-config.d.ts +9 -12
  92. package/dist/superdoc/src/core/config/normalize-ui-config.d.ts +1 -12
  93. package/dist/superdoc/src/core/create-app.d.ts +13 -24
  94. package/dist/superdoc/src/core/editor-runtime/conformance/fake-v2-runtime.d.ts +2 -1
  95. package/dist/superdoc/src/core/editor-runtime/editor-runtime-registry.d.ts +2 -1
  96. package/dist/superdoc/src/core/editor-runtime/index.d.ts +1 -1
  97. package/dist/superdoc/src/core/editor-runtime/types.d.ts +9 -1
  98. package/dist/superdoc/src/core/editor-runtime/v2/v2-editor-runtime-adapter.d.ts +2 -1
  99. package/dist/superdoc/src/core/editor-runtime/v2/v2-session-shortcut-routes.d.ts +1 -1
  100. package/dist/superdoc/src/core/helpers/export.d.ts +3 -2
  101. package/dist/superdoc/src/core/helpers/file.d.ts +8 -45
  102. package/dist/superdoc/src/core/helpers/normalize-track-changes-config.d.ts +6 -60
  103. package/dist/superdoc/src/core/pdf/helpers/constants.d.ts +2 -2
  104. package/dist/superdoc/src/core/pdf/helpers/floor.d.ts +1 -1
  105. package/dist/superdoc/src/core/pdf/helpers/range.d.ts +1 -1
  106. package/dist/superdoc/src/core/pdf/helpers/read-file.d.ts +1 -1
  107. package/dist/superdoc/src/core/pdf/pdf-adapter.d.ts +24 -61
  108. package/dist/superdoc/src/core/superdoc-ui-owner.d.ts +1 -1
  109. package/dist/superdoc/src/core/surface-manager.d.ts +21 -83
  110. package/dist/superdoc/src/core/types/index.d.ts +14 -23
  111. package/dist/superdoc/src/core/v2-integration/v2-integration.d.ts +10 -10
  112. package/dist/superdoc/src/core/whiteboard/Whiteboard.d.ts +22 -208
  113. package/dist/superdoc/src/core/whiteboard/WhiteboardPage.d.ts +163 -189
  114. package/dist/superdoc/src/core/whiteboard/helpers/createTextarea.d.ts +14 -1
  115. package/dist/superdoc/src/core/whiteboard/helpers/flattenPoints.d.ts +1 -1
  116. package/dist/superdoc/src/core/whiteboard/helpers/getRandomId.d.ts +1 -1
  117. package/dist/superdoc/src/helpers/comment-focus.d.ts +21 -4
  118. package/dist/superdoc/src/helpers/deprecation.d.ts +5 -11
  119. package/dist/superdoc/src/helpers/interaction-trace.d.ts +7 -24
  120. package/dist/superdoc/src/helpers/is-finite-number.d.ts +1 -0
  121. package/dist/superdoc/src/helpers/mark-raw-component.d.ts +1 -0
  122. package/dist/superdoc/src/helpers/object-guards.d.ts +1 -5
  123. package/dist/superdoc/src/helpers/selection-source.d.ts +1 -1
  124. package/dist/superdoc/src/helpers/use-selection.d.ts +35 -15
  125. package/dist/superdoc/src/helpers/v2-author-required-rejection.d.ts +8 -11
  126. package/dist/superdoc/src/helpers/v2-bulk-decision-event.d.ts +9 -7
  127. package/dist/superdoc/src/helpers/v2-keyboard-edit-rejection.d.ts +8 -7
  128. package/dist/superdoc/src/helpers/v2-mutation-exception.d.ts +12 -8
  129. package/dist/superdoc/src/helpers/v2-review-target.d.ts +11 -1
  130. package/dist/superdoc/src/helpers/v2-selection-sync.d.ts +40 -14
  131. package/dist/superdoc/src/helpers/v2-typing-mutation-event.d.ts +14 -5
  132. package/dist/superdoc/src/icons.d.ts +11 -11
  133. package/dist/superdoc/src/internal/diagnostics/diagnostic-dedupe.d.ts +7 -16
  134. package/dist/superdoc/src/internal/toolbar/built-in/AIWriter.vue.d.ts +77 -16
  135. package/dist/superdoc/src/internal/toolbar/built-in/AlignmentButtons.vue.d.ts +5 -3
  136. package/dist/superdoc/src/internal/toolbar/built-in/ButtonGroup.vue.d.ts +85 -5
  137. package/dist/superdoc/src/internal/toolbar/built-in/DocumentMode.vue.d.ts +20 -6
  138. package/dist/superdoc/src/internal/toolbar/built-in/FontFamilyCombobox.vue.d.ts +32 -8
  139. package/dist/superdoc/src/internal/toolbar/built-in/FontSizeCombobox.vue.d.ts +32 -8
  140. package/dist/superdoc/src/internal/toolbar/built-in/IconGrid.vue.d.ts +44 -12
  141. package/dist/superdoc/src/internal/toolbar/built-in/IconGridRow.vue.d.ts +32 -9
  142. package/dist/superdoc/src/internal/toolbar/built-in/LinkInput.vue.d.ts +181 -36
  143. package/dist/superdoc/src/internal/toolbar/built-in/LinkedStyle.vue.d.ts +39 -10
  144. package/dist/superdoc/src/internal/toolbar/built-in/PageNumberMenu.vue.d.ts +133 -22
  145. package/dist/superdoc/src/internal/toolbar/built-in/SdTooltip.vue.d.ts +62 -23
  146. package/dist/superdoc/src/internal/toolbar/built-in/StyleButtonsList.vue.d.ts +39 -10
  147. package/dist/superdoc/src/internal/toolbar/built-in/TableActions.vue.d.ts +24 -6
  148. package/dist/superdoc/src/internal/toolbar/built-in/TableGrid.vue.d.ts +7 -3
  149. package/dist/superdoc/src/internal/toolbar/built-in/Toolbar.vue.d.ts +9 -3
  150. package/dist/superdoc/src/internal/toolbar/built-in/ToolbarButton.vue.d.ts +101 -16
  151. package/dist/superdoc/src/internal/toolbar/built-in/ToolbarButtonIcon.vue.d.ts +31 -10
  152. package/dist/superdoc/src/internal/toolbar/built-in/ToolbarComboBox.vue.d.ts +80 -11
  153. package/dist/superdoc/src/internal/toolbar/built-in/ToolbarDropdown.vue.d.ts +113 -33
  154. package/dist/superdoc/src/internal/toolbar/built-in/ToolbarSeparator.vue.d.ts +16 -6
  155. package/dist/superdoc/src/internal/toolbar/built-in/color-dropdown-helpers.d.ts +10 -20
  156. package/dist/superdoc/src/internal/toolbar/built-in/constants.d.ts +12 -45
  157. package/dist/superdoc/src/internal/toolbar/built-in/default-items.d.ts +34 -17
  158. package/dist/superdoc/src/internal/toolbar/built-in/list-style-buttons.d.ts +2 -2
  159. package/dist/superdoc/src/internal/toolbar/built-in/toolbar-focus-helpers.d.ts +10 -2
  160. package/dist/superdoc/src/internal/toolbar/built-in/toolbarIcons.d.ts +67 -0
  161. package/dist/superdoc/src/internal/toolbar/built-in/toolbarTexts.d.ts +61 -61
  162. package/dist/superdoc/src/internal/toolbar/built-in/use-toolbar-item.d.ts +110 -49
  163. package/dist/superdoc/src/internal/toolbar/built-in-toolbar.d.ts +7 -27
  164. package/dist/superdoc/src/internal/toolbar/compatibility-catalog.d.ts +4 -3
  165. package/dist/superdoc/src/internal/toolbar/toolbar-item-aliases.d.ts +1 -1
  166. package/dist/superdoc/src/public/browser-document-api.d.ts +5 -4
  167. package/dist/superdoc/src/public/index.d.cts +26 -0
  168. package/dist/superdoc/src/public/index.d.ts +13 -0
  169. package/dist/superdoc/src/public/ui/commands.d.ts +14 -13
  170. package/dist/superdoc/src/public/ui/create-super-doc-ui.d.ts +1 -1
  171. package/dist/superdoc/src/public/ui/entity-at.d.ts +2 -1
  172. package/dist/superdoc/src/public/ui/format-painter-helpers.d.ts +2 -8
  173. package/dist/superdoc/src/public/ui/style-match-patch.d.ts +2 -2
  174. package/dist/superdoc/src/public/ui/types.d.ts +1 -1
  175. package/dist/superdoc/src/stores/comments-store.d.ts +372 -123
  176. package/dist/superdoc/src/stores/helpers/comment-draft-text.d.ts +1 -0
  177. package/dist/superdoc/src/stores/helpers/comment-grouping.d.ts +30 -0
  178. package/dist/superdoc/src/stores/helpers/comment-identity.d.ts +40 -0
  179. package/dist/superdoc/src/stores/helpers/floating-comment-instances.d.ts +48 -13
  180. package/dist/superdoc/src/stores/helpers/tracked-change-identity.d.ts +19 -0
  181. package/dist/superdoc/src/stores/helpers/tracked-change-row-values.d.ts +21 -0
  182. package/dist/superdoc/src/stores/helpers/tracked-change-thread-index.d.ts +21 -24
  183. package/dist/superdoc/src/stores/superdoc-store.d.ts +1117 -370
  184. package/dist/superdoc.cjs +1923 -2838
  185. package/dist/superdoc.es.js +1863 -2783
  186. package/dist-cdn/style.layered.css +1 -1
  187. package/dist-cdn/superdoc.min.css +1 -1
  188. package/dist-cdn/superdoc.min.js +42 -42
  189. package/package.json +2 -2
  190. package/dist/superdoc/src/internal/toolbar/built-in/OverflowMenu.vue.d.ts +0 -104
  191. package/dist/superdoc/src/internal/toolbar/index.d.ts +0 -10
  192. package/dist/superdoc/src/main.d.ts +0 -1
@@ -11,15 +11,10 @@ export const useCommentsStore: import('pinia').StoreDefinition<"comments", Pick<
11
11
  readonly CHANGE_ACCEPTED: "change-accepted";
12
12
  readonly CHANGE_REJECTED: "change-rejected";
13
13
  };
14
- isDebugging: boolean;
15
- hasInitializedComments: import('vue').Ref<boolean, boolean>;
16
14
  hasSyncedCollaborationComments: import('vue').Ref<boolean, boolean>;
17
15
  editingCommentId: import('vue').Ref<null, null>;
18
16
  activeComment: import('vue').Ref<null, null>;
19
17
  activeFloatingCommentInstanceId: import('vue').Ref<null, null>;
20
- commentDialogs: import('vue').Ref<never[], never[]>;
21
- overlappingComments: import('vue').Ref<never[], never[]>;
22
- overlappedIds: Set<never>;
23
18
  suppressInternalExternal: import('vue').Ref<boolean, boolean>;
24
19
  pendingComment: import('vue').Ref<null, null>;
25
20
  currentCommentText: import('vue').Ref<string, string>;
@@ -37,8 +32,6 @@ export const useCommentsStore: import('pinia').StoreDefinition<"comments", Pick<
37
32
  isCommentHighlighted: import('vue').Ref<boolean, boolean>;
38
33
  floatingCommentsOffset: import('vue').Ref<number, number>;
39
34
  committedReviewPresentations: import('vue').ShallowRef<{}, {}>;
40
- sortedConversations: import('vue').Ref<never[], never[]>;
41
- visibleConversations: import('vue').Ref<never[], never[]>;
42
35
  skipSelectionUpdate: import('vue').Ref<boolean, boolean>;
43
36
  isFloatingCommentsReady: import('vue').Ref<boolean, boolean>;
44
37
  instantSidebarAlignmentTargetY: import('vue').Ref<null, null>;
@@ -60,27 +53,43 @@ export const useCommentsStore: import('pinia').StoreDefinition<"comments", Pick<
60
53
  resolvedComments: any[];
61
54
  }>;
62
55
  hasOpenTrackedChanges: import('vue').ComputedRef<boolean>;
63
- getCommentsByPosition: import('vue').ComputedRef<{
64
- parentComments: any[];
65
- resolvedComments: any[];
66
- }>;
67
56
  getFloatingComments: import('vue').ComputedRef<any[]>;
68
57
  getFloatingCommentInstances: import('vue').ComputedRef<{
69
- id: any;
70
- threadId: any;
58
+ id: string;
59
+ threadId: string | null;
71
60
  comment: any;
72
- positionKey: any;
73
- pageIndex: any;
61
+ positionKey: string | null;
62
+ positionEntry: {
63
+ pageIndex?: number | null;
64
+ rects?: readonly ({
65
+ pageIndex?: number | null;
66
+ left?: number;
67
+ top?: number;
68
+ right?: number;
69
+ bottom?: number;
70
+ } | null | undefined)[] | null;
71
+ bounds?: Partial<{
72
+ left: number;
73
+ top: number;
74
+ right: number;
75
+ bottom: number;
76
+ width: number;
77
+ height: number;
78
+ }> | null;
79
+ } | null;
80
+ pageIndex: number | null;
74
81
  isPrimary: boolean;
75
- positionEntry: any;
76
82
  }[]>;
77
- getCommentAliasIds: (commentOrId: any) => (string | null)[];
83
+ getCommentAliasIds: (commentOrId: string | number | import('./helpers/comment-identity.js').CommentIdentityRow | null | undefined) => string[];
78
84
  getTrackedChangeThread: (parentComment: any) => any[] | readonly never[];
79
- getCommentPositionKey: (commentOrId: Object | string | null | undefined) => string | null;
85
+ getCommentPositionKey: (commentOrId: import('./helpers/comment-identity.js').CommentIdentityRow | string | null | undefined) => unknown;
80
86
  getCommentPosition: (commentOrId: Object | string) => Object | null;
81
- resolveCommentPositionEntry: (commentOrId: any, preferredId: any) => {
82
- key: string | null;
83
- entry: any;
87
+ resolveCommentPositionEntry: (commentOrId: string | number | import('./helpers/comment-identity.js').CommentIdentityRow | null | undefined, preferredId?: unknown) => {
88
+ key: string;
89
+ entry: import('./helpers/comment-identity.js').CommentPositionEntry;
90
+ } | {
91
+ key: null;
92
+ entry: null;
84
93
  };
85
94
  getCommentDocumentId: (comment: any) => string | null;
86
95
  belongsToDocument: (comment: any, activeDocumentId: any, options?: {}) => any;
@@ -93,31 +102,46 @@ export const useCommentsStore: import('pinia').StoreDefinition<"comments", Pick<
93
102
  shouldRenderReviewInViewing: import('vue').ComputedRef<boolean>;
94
103
  init: (config?: Object) => void;
95
104
  setViewingVisibility: ({ documentMode, commentsVisible, trackChangesVisible }?: {}) => void;
96
- getComment: (id: string) => Record<string, unknown> | null | undefined;
105
+ getComment: (id: unknown) => import('./helpers/comment-identity.js').CommentIdentityRow | null;
97
106
  setActiveComment: (superdoc: Object | undefined | null, id: string | undefined | null) => void;
98
- getCommentLocation: (selection: any, parent: any) => {
99
- top: any;
100
- left: any;
101
- };
102
- hasOverlapId: (id: any) => any;
103
107
  getPendingComment: ({ selection, documentId, parentCommentId, ...options }: {
104
- selection: Object;
105
- documentId: string;
106
- parentCommentId: string;
107
- }) => Object;
108
+ selection?: Object | undefined;
109
+ documentId?: string | null | undefined;
110
+ parentCommentId?: string | null | undefined;
111
+ }) => ReturnType<typeof useComment>;
108
112
  showAddComment: (superdoc: any, targetClientY?: null) => any;
109
113
  addComment: ({ superdoc, comment, skipEditorUpdate, broadcastChanges }: {
110
114
  superdoc: any;
111
115
  comment: any;
112
116
  skipEditorUpdate?: boolean | undefined;
113
117
  broadcastChanges?: boolean | undefined;
114
- }) => void;
118
+ }) => {
119
+ ok: boolean;
120
+ reason?: string;
121
+ detail?: string;
122
+ code?: string;
123
+ } | Promise<{
124
+ ok: boolean;
125
+ reason?: string;
126
+ detail?: string;
127
+ code?: string;
128
+ }>;
115
129
  addHydratedComment: ({ superdoc, comment, skipEditorUpdate, broadcastChanges }: {
116
130
  superdoc: any;
117
131
  comment: any;
118
132
  skipEditorUpdate?: boolean | undefined;
119
133
  broadcastChanges?: boolean | undefined;
120
- }) => void;
134
+ }) => {
135
+ ok: boolean;
136
+ reason?: string;
137
+ detail?: string;
138
+ code?: string;
139
+ } | Promise<{
140
+ ok: boolean;
141
+ reason?: string;
142
+ detail?: string;
143
+ code?: string;
144
+ }>;
121
145
  cancelComment: (superdoc: any) => void;
122
146
  deleteComment: ({ commentId: commentIdToDelete, superdoc }: {
123
147
  commentId: any;
@@ -154,16 +178,59 @@ export const useCommentsStore: import('pinia').StoreDefinition<"comments", Pick<
154
178
  clearInstantSidebarAlignment: () => void;
155
179
  decideTrackedChangeFromSidebar: ({ superdoc, comment, decision }: {
156
180
  superdoc: Object;
157
- editor: Object;
158
- }) => void;
181
+ comment: Object;
182
+ decision: string;
183
+ }) => {
184
+ ok: boolean;
185
+ success?: boolean;
186
+ reason?: string;
187
+ } | Promise<{
188
+ ok: boolean;
189
+ success?: boolean;
190
+ reason?: string;
191
+ }>;
159
192
  v2CommentsAdapter: import('vue').ShallowRef<null, null>;
160
193
  setV2CommentsAdapter: (adapter: any) => void;
161
194
  getV2CommentsAdapter: (superdoc: any) => any;
162
- applyReviewWindowFromV2: ({ superdoc, commentsAdapter, trackedChangesAdapter, documentId, commentItems, trackedChangeItems, preparedReview, requestedCommentIds, requestedTrackedChangeIds, unresolvedCommentIds, trackedList, sourceCoverageRevision, evaluatedRevision, patch, }?: {}) => any;
195
+ applyReviewWindowFromV2: ({ superdoc, commentsAdapter, trackedChangesAdapter, documentId, commentItems, trackedChangeItems, preparedReview, requestedCommentIds, requestedTrackedChangeIds, unresolvedCommentIds, trackedList, sourceCoverageRevision, evaluatedRevision, patch, }?: {}) => {
196
+ ok: boolean;
197
+ geometryOnly: boolean;
198
+ commentItems?: undefined;
199
+ trackedItems?: undefined;
200
+ reason?: undefined;
201
+ detail?: undefined;
202
+ } | {
203
+ ok: boolean;
204
+ commentItems: any;
205
+ trackedItems: any;
206
+ geometryOnly?: undefined;
207
+ reason?: undefined;
208
+ detail?: undefined;
209
+ } | {
210
+ ok: boolean;
211
+ reason: any;
212
+ geometryOnly?: undefined;
213
+ commentItems?: undefined;
214
+ trackedItems?: undefined;
215
+ detail?: undefined;
216
+ } | {
217
+ ok: boolean;
218
+ reason: string;
219
+ detail: any;
220
+ geometryOnly?: undefined;
221
+ commentItems?: undefined;
222
+ trackedItems?: undefined;
223
+ };
163
224
  reconcileCommentsFromV2: ({ superdoc, adapter, documentId, items, preparedInputs, pruneStale, hydrationGeneration, }?: {
164
225
  preparedInputs?: null | undefined;
165
226
  pruneStale?: boolean | undefined;
166
- }) => any;
227
+ }) => {
228
+ added: null;
229
+ dropped: string;
230
+ } | {
231
+ added: any;
232
+ dropped?: undefined;
233
+ };
167
234
  announceV2CommentCreated: ({ superdoc, commentId }?: {}) => Promise<{
168
235
  ok: boolean;
169
236
  reason: string;
@@ -186,7 +253,19 @@ export const useCommentsStore: import('pinia').StoreDefinition<"comments", Pick<
186
253
  };
187
254
  isV2EditorActive: (superdoc: any) => boolean;
188
255
  replyCommentV2: ({ superdoc, parentCommentId, text, mentions, trackedChangeTarget }?: {
189
- mentions?: never[] | undefined;
256
+ superdoc?: Object | undefined;
257
+ parentCommentId?: string | null | undefined;
258
+ text?: string | undefined;
259
+ mentions?: {
260
+ name?: string | null;
261
+ email?: string | null;
262
+ }[] | undefined;
263
+ trackedChangeTarget?: {
264
+ kind: "trackedChange";
265
+ trackedChangeId: string;
266
+ story?: unknown;
267
+ side?: import('./helpers/tracked-change-thread-index.js').TrackedChangeSideGroup;
268
+ } | undefined;
190
269
  }) => Promise<any>;
191
270
  editCommentV2: ({ superdoc, commentId, text }?: {}) => Promise<any>;
192
271
  resolveCommentV2: ({ superdoc, commentId }?: {}) => Promise<any>;
@@ -214,7 +293,7 @@ export const useCommentsStore: import('pinia').StoreDefinition<"comments", Pick<
214
293
  resolvedIds: never[];
215
294
  unresolvedIds: never[];
216
295
  allResolved: boolean;
217
- removedRows: any;
296
+ removedRows: number;
218
297
  reason?: undefined;
219
298
  removedIds?: undefined;
220
299
  } | {
@@ -234,9 +313,13 @@ export const useCommentsStore: import('pinia').StoreDefinition<"comments", Pick<
234
313
  previousPreparedPresentation?: null | undefined;
235
314
  liveIds?: null | undefined;
236
315
  liveAnchorKeys?: null | undefined;
237
- }) => any;
316
+ }) => {
317
+ liveIds: Set<any>;
318
+ liveAnchorKeys: Set<any>;
319
+ appliedCount: number;
320
+ } | undefined;
238
321
  remapTrackedChangeIdentities: (pairs?: any[], { documentId }?: {}) => void;
239
- }, "suppressInternalExternal" | "activeComment" | "activeFloatingCommentInstanceId" | "floatingCommentsOffset" | "pendingComment" | "currentCommentText" | "currentCommentMentions" | "isDebugging" | "editingCommentId" | "editorCommentPositions" | "isCommentHighlighted" | "v2CommentsAdapter" | "COMMENT_EVENTS" | "hasInitializedComments" | "hasSyncedCollaborationComments" | "commentDialogs" | "overlappingComments" | "overlappedIds" | "commentsList" | "reviewDirectoryList" | "isCommentsListVisible" | "isReviewDirectoryActive" | "isReviewDirectoryLoading" | "generalCommentIds" | "editorCommentIds" | "commentsParentElement" | "hasInitializedLocations" | "committedReviewPresentations" | "sortedConversations" | "visibleConversations" | "skipSelectionUpdate" | "isFloatingCommentsReady" | "instantSidebarAlignmentTargetY" | "instantSidebarAlignmentThreadId" | "instantSidebarAlignmentInstanceId" | "viewingVisibility" | "v2TrackedChangesAdapter">, Pick<{
322
+ }, "COMMENT_EVENTS" | "hasSyncedCollaborationComments" | "editingCommentId" | "activeComment" | "activeFloatingCommentInstanceId" | "suppressInternalExternal" | "pendingComment" | "currentCommentText" | "currentCommentMentions" | "commentsList" | "reviewDirectoryList" | "isCommentsListVisible" | "isReviewDirectoryActive" | "isReviewDirectoryLoading" | "generalCommentIds" | "editorCommentIds" | "commentsParentElement" | "editorCommentPositions" | "hasInitializedLocations" | "isCommentHighlighted" | "floatingCommentsOffset" | "committedReviewPresentations" | "skipSelectionUpdate" | "isFloatingCommentsReady" | "instantSidebarAlignmentTargetY" | "instantSidebarAlignmentThreadId" | "instantSidebarAlignmentInstanceId" | "viewingVisibility" | "v2CommentsAdapter" | "v2TrackedChangesAdapter">, Pick<{
240
323
  COMMENT_EVENTS: {
241
324
  readonly RESOLVED: "resolved";
242
325
  readonly NEW: "new";
@@ -249,15 +332,10 @@ export const useCommentsStore: import('pinia').StoreDefinition<"comments", Pick<
249
332
  readonly CHANGE_ACCEPTED: "change-accepted";
250
333
  readonly CHANGE_REJECTED: "change-rejected";
251
334
  };
252
- isDebugging: boolean;
253
- hasInitializedComments: import('vue').Ref<boolean, boolean>;
254
335
  hasSyncedCollaborationComments: import('vue').Ref<boolean, boolean>;
255
336
  editingCommentId: import('vue').Ref<null, null>;
256
337
  activeComment: import('vue').Ref<null, null>;
257
338
  activeFloatingCommentInstanceId: import('vue').Ref<null, null>;
258
- commentDialogs: import('vue').Ref<never[], never[]>;
259
- overlappingComments: import('vue').Ref<never[], never[]>;
260
- overlappedIds: Set<never>;
261
339
  suppressInternalExternal: import('vue').Ref<boolean, boolean>;
262
340
  pendingComment: import('vue').Ref<null, null>;
263
341
  currentCommentText: import('vue').Ref<string, string>;
@@ -275,8 +353,6 @@ export const useCommentsStore: import('pinia').StoreDefinition<"comments", Pick<
275
353
  isCommentHighlighted: import('vue').Ref<boolean, boolean>;
276
354
  floatingCommentsOffset: import('vue').Ref<number, number>;
277
355
  committedReviewPresentations: import('vue').ShallowRef<{}, {}>;
278
- sortedConversations: import('vue').Ref<never[], never[]>;
279
- visibleConversations: import('vue').Ref<never[], never[]>;
280
356
  skipSelectionUpdate: import('vue').Ref<boolean, boolean>;
281
357
  isFloatingCommentsReady: import('vue').Ref<boolean, boolean>;
282
358
  instantSidebarAlignmentTargetY: import('vue').Ref<null, null>;
@@ -298,27 +374,43 @@ export const useCommentsStore: import('pinia').StoreDefinition<"comments", Pick<
298
374
  resolvedComments: any[];
299
375
  }>;
300
376
  hasOpenTrackedChanges: import('vue').ComputedRef<boolean>;
301
- getCommentsByPosition: import('vue').ComputedRef<{
302
- parentComments: any[];
303
- resolvedComments: any[];
304
- }>;
305
377
  getFloatingComments: import('vue').ComputedRef<any[]>;
306
378
  getFloatingCommentInstances: import('vue').ComputedRef<{
307
- id: any;
308
- threadId: any;
379
+ id: string;
380
+ threadId: string | null;
309
381
  comment: any;
310
- positionKey: any;
311
- pageIndex: any;
382
+ positionKey: string | null;
383
+ positionEntry: {
384
+ pageIndex?: number | null;
385
+ rects?: readonly ({
386
+ pageIndex?: number | null;
387
+ left?: number;
388
+ top?: number;
389
+ right?: number;
390
+ bottom?: number;
391
+ } | null | undefined)[] | null;
392
+ bounds?: Partial<{
393
+ left: number;
394
+ top: number;
395
+ right: number;
396
+ bottom: number;
397
+ width: number;
398
+ height: number;
399
+ }> | null;
400
+ } | null;
401
+ pageIndex: number | null;
312
402
  isPrimary: boolean;
313
- positionEntry: any;
314
403
  }[]>;
315
- getCommentAliasIds: (commentOrId: any) => (string | null)[];
404
+ getCommentAliasIds: (commentOrId: string | number | import('./helpers/comment-identity.js').CommentIdentityRow | null | undefined) => string[];
316
405
  getTrackedChangeThread: (parentComment: any) => any[] | readonly never[];
317
- getCommentPositionKey: (commentOrId: Object | string | null | undefined) => string | null;
406
+ getCommentPositionKey: (commentOrId: import('./helpers/comment-identity.js').CommentIdentityRow | string | null | undefined) => unknown;
318
407
  getCommentPosition: (commentOrId: Object | string) => Object | null;
319
- resolveCommentPositionEntry: (commentOrId: any, preferredId: any) => {
320
- key: string | null;
321
- entry: any;
408
+ resolveCommentPositionEntry: (commentOrId: string | number | import('./helpers/comment-identity.js').CommentIdentityRow | null | undefined, preferredId?: unknown) => {
409
+ key: string;
410
+ entry: import('./helpers/comment-identity.js').CommentPositionEntry;
411
+ } | {
412
+ key: null;
413
+ entry: null;
322
414
  };
323
415
  getCommentDocumentId: (comment: any) => string | null;
324
416
  belongsToDocument: (comment: any, activeDocumentId: any, options?: {}) => any;
@@ -331,31 +423,46 @@ export const useCommentsStore: import('pinia').StoreDefinition<"comments", Pick<
331
423
  shouldRenderReviewInViewing: import('vue').ComputedRef<boolean>;
332
424
  init: (config?: Object) => void;
333
425
  setViewingVisibility: ({ documentMode, commentsVisible, trackChangesVisible }?: {}) => void;
334
- getComment: (id: string) => Record<string, unknown> | null | undefined;
426
+ getComment: (id: unknown) => import('./helpers/comment-identity.js').CommentIdentityRow | null;
335
427
  setActiveComment: (superdoc: Object | undefined | null, id: string | undefined | null) => void;
336
- getCommentLocation: (selection: any, parent: any) => {
337
- top: any;
338
- left: any;
339
- };
340
- hasOverlapId: (id: any) => any;
341
428
  getPendingComment: ({ selection, documentId, parentCommentId, ...options }: {
342
- selection: Object;
343
- documentId: string;
344
- parentCommentId: string;
345
- }) => Object;
429
+ selection?: Object | undefined;
430
+ documentId?: string | null | undefined;
431
+ parentCommentId?: string | null | undefined;
432
+ }) => ReturnType<typeof useComment>;
346
433
  showAddComment: (superdoc: any, targetClientY?: null) => any;
347
434
  addComment: ({ superdoc, comment, skipEditorUpdate, broadcastChanges }: {
348
435
  superdoc: any;
349
436
  comment: any;
350
437
  skipEditorUpdate?: boolean | undefined;
351
438
  broadcastChanges?: boolean | undefined;
352
- }) => void;
439
+ }) => {
440
+ ok: boolean;
441
+ reason?: string;
442
+ detail?: string;
443
+ code?: string;
444
+ } | Promise<{
445
+ ok: boolean;
446
+ reason?: string;
447
+ detail?: string;
448
+ code?: string;
449
+ }>;
353
450
  addHydratedComment: ({ superdoc, comment, skipEditorUpdate, broadcastChanges }: {
354
451
  superdoc: any;
355
452
  comment: any;
356
453
  skipEditorUpdate?: boolean | undefined;
357
454
  broadcastChanges?: boolean | undefined;
358
- }) => void;
455
+ }) => {
456
+ ok: boolean;
457
+ reason?: string;
458
+ detail?: string;
459
+ code?: string;
460
+ } | Promise<{
461
+ ok: boolean;
462
+ reason?: string;
463
+ detail?: string;
464
+ code?: string;
465
+ }>;
359
466
  cancelComment: (superdoc: any) => void;
360
467
  deleteComment: ({ commentId: commentIdToDelete, superdoc }: {
361
468
  commentId: any;
@@ -392,16 +499,59 @@ export const useCommentsStore: import('pinia').StoreDefinition<"comments", Pick<
392
499
  clearInstantSidebarAlignment: () => void;
393
500
  decideTrackedChangeFromSidebar: ({ superdoc, comment, decision }: {
394
501
  superdoc: Object;
395
- editor: Object;
396
- }) => void;
502
+ comment: Object;
503
+ decision: string;
504
+ }) => {
505
+ ok: boolean;
506
+ success?: boolean;
507
+ reason?: string;
508
+ } | Promise<{
509
+ ok: boolean;
510
+ success?: boolean;
511
+ reason?: string;
512
+ }>;
397
513
  v2CommentsAdapter: import('vue').ShallowRef<null, null>;
398
514
  setV2CommentsAdapter: (adapter: any) => void;
399
515
  getV2CommentsAdapter: (superdoc: any) => any;
400
- applyReviewWindowFromV2: ({ superdoc, commentsAdapter, trackedChangesAdapter, documentId, commentItems, trackedChangeItems, preparedReview, requestedCommentIds, requestedTrackedChangeIds, unresolvedCommentIds, trackedList, sourceCoverageRevision, evaluatedRevision, patch, }?: {}) => any;
516
+ applyReviewWindowFromV2: ({ superdoc, commentsAdapter, trackedChangesAdapter, documentId, commentItems, trackedChangeItems, preparedReview, requestedCommentIds, requestedTrackedChangeIds, unresolvedCommentIds, trackedList, sourceCoverageRevision, evaluatedRevision, patch, }?: {}) => {
517
+ ok: boolean;
518
+ geometryOnly: boolean;
519
+ commentItems?: undefined;
520
+ trackedItems?: undefined;
521
+ reason?: undefined;
522
+ detail?: undefined;
523
+ } | {
524
+ ok: boolean;
525
+ commentItems: any;
526
+ trackedItems: any;
527
+ geometryOnly?: undefined;
528
+ reason?: undefined;
529
+ detail?: undefined;
530
+ } | {
531
+ ok: boolean;
532
+ reason: any;
533
+ geometryOnly?: undefined;
534
+ commentItems?: undefined;
535
+ trackedItems?: undefined;
536
+ detail?: undefined;
537
+ } | {
538
+ ok: boolean;
539
+ reason: string;
540
+ detail: any;
541
+ geometryOnly?: undefined;
542
+ commentItems?: undefined;
543
+ trackedItems?: undefined;
544
+ };
401
545
  reconcileCommentsFromV2: ({ superdoc, adapter, documentId, items, preparedInputs, pruneStale, hydrationGeneration, }?: {
402
546
  preparedInputs?: null | undefined;
403
547
  pruneStale?: boolean | undefined;
404
- }) => any;
548
+ }) => {
549
+ added: null;
550
+ dropped: string;
551
+ } | {
552
+ added: any;
553
+ dropped?: undefined;
554
+ };
405
555
  announceV2CommentCreated: ({ superdoc, commentId }?: {}) => Promise<{
406
556
  ok: boolean;
407
557
  reason: string;
@@ -424,7 +574,19 @@ export const useCommentsStore: import('pinia').StoreDefinition<"comments", Pick<
424
574
  };
425
575
  isV2EditorActive: (superdoc: any) => boolean;
426
576
  replyCommentV2: ({ superdoc, parentCommentId, text, mentions, trackedChangeTarget }?: {
427
- mentions?: never[] | undefined;
577
+ superdoc?: Object | undefined;
578
+ parentCommentId?: string | null | undefined;
579
+ text?: string | undefined;
580
+ mentions?: {
581
+ name?: string | null;
582
+ email?: string | null;
583
+ }[] | undefined;
584
+ trackedChangeTarget?: {
585
+ kind: "trackedChange";
586
+ trackedChangeId: string;
587
+ story?: unknown;
588
+ side?: import('./helpers/tracked-change-thread-index.js').TrackedChangeSideGroup;
589
+ } | undefined;
428
590
  }) => Promise<any>;
429
591
  editCommentV2: ({ superdoc, commentId, text }?: {}) => Promise<any>;
430
592
  resolveCommentV2: ({ superdoc, commentId }?: {}) => Promise<any>;
@@ -452,7 +614,7 @@ export const useCommentsStore: import('pinia').StoreDefinition<"comments", Pick<
452
614
  resolvedIds: never[];
453
615
  unresolvedIds: never[];
454
616
  allResolved: boolean;
455
- removedRows: any;
617
+ removedRows: number;
456
618
  reason?: undefined;
457
619
  removedIds?: undefined;
458
620
  } | {
@@ -472,9 +634,13 @@ export const useCommentsStore: import('pinia').StoreDefinition<"comments", Pick<
472
634
  previousPreparedPresentation?: null | undefined;
473
635
  liveIds?: null | undefined;
474
636
  liveAnchorKeys?: null | undefined;
475
- }) => any;
637
+ }) => {
638
+ liveIds: Set<any>;
639
+ liveAnchorKeys: Set<any>;
640
+ appliedCount: number;
641
+ } | undefined;
476
642
  remapTrackedChangeIdentities: (pairs?: any[], { documentId }?: {}) => void;
477
- }, "getConfig" | "documentsWithConverations" | "getGroupedComments" | "getGroupedReviewDirectory" | "hasOpenTrackedChanges" | "getCommentsByPosition" | "getFloatingComments" | "getFloatingCommentInstances" | "isViewingMode" | "shouldRenderReviewInViewing">, Pick<{
643
+ }, "getConfig" | "documentsWithConverations" | "getGroupedComments" | "getGroupedReviewDirectory" | "hasOpenTrackedChanges" | "getFloatingComments" | "getFloatingCommentInstances" | "isViewingMode" | "shouldRenderReviewInViewing">, Pick<{
478
644
  COMMENT_EVENTS: {
479
645
  readonly RESOLVED: "resolved";
480
646
  readonly NEW: "new";
@@ -487,15 +653,10 @@ export const useCommentsStore: import('pinia').StoreDefinition<"comments", Pick<
487
653
  readonly CHANGE_ACCEPTED: "change-accepted";
488
654
  readonly CHANGE_REJECTED: "change-rejected";
489
655
  };
490
- isDebugging: boolean;
491
- hasInitializedComments: import('vue').Ref<boolean, boolean>;
492
656
  hasSyncedCollaborationComments: import('vue').Ref<boolean, boolean>;
493
657
  editingCommentId: import('vue').Ref<null, null>;
494
658
  activeComment: import('vue').Ref<null, null>;
495
659
  activeFloatingCommentInstanceId: import('vue').Ref<null, null>;
496
- commentDialogs: import('vue').Ref<never[], never[]>;
497
- overlappingComments: import('vue').Ref<never[], never[]>;
498
- overlappedIds: Set<never>;
499
660
  suppressInternalExternal: import('vue').Ref<boolean, boolean>;
500
661
  pendingComment: import('vue').Ref<null, null>;
501
662
  currentCommentText: import('vue').Ref<string, string>;
@@ -513,8 +674,6 @@ export const useCommentsStore: import('pinia').StoreDefinition<"comments", Pick<
513
674
  isCommentHighlighted: import('vue').Ref<boolean, boolean>;
514
675
  floatingCommentsOffset: import('vue').Ref<number, number>;
515
676
  committedReviewPresentations: import('vue').ShallowRef<{}, {}>;
516
- sortedConversations: import('vue').Ref<never[], never[]>;
517
- visibleConversations: import('vue').Ref<never[], never[]>;
518
677
  skipSelectionUpdate: import('vue').Ref<boolean, boolean>;
519
678
  isFloatingCommentsReady: import('vue').Ref<boolean, boolean>;
520
679
  instantSidebarAlignmentTargetY: import('vue').Ref<null, null>;
@@ -536,27 +695,43 @@ export const useCommentsStore: import('pinia').StoreDefinition<"comments", Pick<
536
695
  resolvedComments: any[];
537
696
  }>;
538
697
  hasOpenTrackedChanges: import('vue').ComputedRef<boolean>;
539
- getCommentsByPosition: import('vue').ComputedRef<{
540
- parentComments: any[];
541
- resolvedComments: any[];
542
- }>;
543
698
  getFloatingComments: import('vue').ComputedRef<any[]>;
544
699
  getFloatingCommentInstances: import('vue').ComputedRef<{
545
- id: any;
546
- threadId: any;
700
+ id: string;
701
+ threadId: string | null;
547
702
  comment: any;
548
- positionKey: any;
549
- pageIndex: any;
703
+ positionKey: string | null;
704
+ positionEntry: {
705
+ pageIndex?: number | null;
706
+ rects?: readonly ({
707
+ pageIndex?: number | null;
708
+ left?: number;
709
+ top?: number;
710
+ right?: number;
711
+ bottom?: number;
712
+ } | null | undefined)[] | null;
713
+ bounds?: Partial<{
714
+ left: number;
715
+ top: number;
716
+ right: number;
717
+ bottom: number;
718
+ width: number;
719
+ height: number;
720
+ }> | null;
721
+ } | null;
722
+ pageIndex: number | null;
550
723
  isPrimary: boolean;
551
- positionEntry: any;
552
724
  }[]>;
553
- getCommentAliasIds: (commentOrId: any) => (string | null)[];
725
+ getCommentAliasIds: (commentOrId: string | number | import('./helpers/comment-identity.js').CommentIdentityRow | null | undefined) => string[];
554
726
  getTrackedChangeThread: (parentComment: any) => any[] | readonly never[];
555
- getCommentPositionKey: (commentOrId: Object | string | null | undefined) => string | null;
727
+ getCommentPositionKey: (commentOrId: import('./helpers/comment-identity.js').CommentIdentityRow | string | null | undefined) => unknown;
556
728
  getCommentPosition: (commentOrId: Object | string) => Object | null;
557
- resolveCommentPositionEntry: (commentOrId: any, preferredId: any) => {
558
- key: string | null;
559
- entry: any;
729
+ resolveCommentPositionEntry: (commentOrId: string | number | import('./helpers/comment-identity.js').CommentIdentityRow | null | undefined, preferredId?: unknown) => {
730
+ key: string;
731
+ entry: import('./helpers/comment-identity.js').CommentPositionEntry;
732
+ } | {
733
+ key: null;
734
+ entry: null;
560
735
  };
561
736
  getCommentDocumentId: (comment: any) => string | null;
562
737
  belongsToDocument: (comment: any, activeDocumentId: any, options?: {}) => any;
@@ -569,31 +744,46 @@ export const useCommentsStore: import('pinia').StoreDefinition<"comments", Pick<
569
744
  shouldRenderReviewInViewing: import('vue').ComputedRef<boolean>;
570
745
  init: (config?: Object) => void;
571
746
  setViewingVisibility: ({ documentMode, commentsVisible, trackChangesVisible }?: {}) => void;
572
- getComment: (id: string) => Record<string, unknown> | null | undefined;
747
+ getComment: (id: unknown) => import('./helpers/comment-identity.js').CommentIdentityRow | null;
573
748
  setActiveComment: (superdoc: Object | undefined | null, id: string | undefined | null) => void;
574
- getCommentLocation: (selection: any, parent: any) => {
575
- top: any;
576
- left: any;
577
- };
578
- hasOverlapId: (id: any) => any;
579
749
  getPendingComment: ({ selection, documentId, parentCommentId, ...options }: {
580
- selection: Object;
581
- documentId: string;
582
- parentCommentId: string;
583
- }) => Object;
750
+ selection?: Object | undefined;
751
+ documentId?: string | null | undefined;
752
+ parentCommentId?: string | null | undefined;
753
+ }) => ReturnType<typeof useComment>;
584
754
  showAddComment: (superdoc: any, targetClientY?: null) => any;
585
755
  addComment: ({ superdoc, comment, skipEditorUpdate, broadcastChanges }: {
586
756
  superdoc: any;
587
757
  comment: any;
588
758
  skipEditorUpdate?: boolean | undefined;
589
759
  broadcastChanges?: boolean | undefined;
590
- }) => void;
760
+ }) => {
761
+ ok: boolean;
762
+ reason?: string;
763
+ detail?: string;
764
+ code?: string;
765
+ } | Promise<{
766
+ ok: boolean;
767
+ reason?: string;
768
+ detail?: string;
769
+ code?: string;
770
+ }>;
591
771
  addHydratedComment: ({ superdoc, comment, skipEditorUpdate, broadcastChanges }: {
592
772
  superdoc: any;
593
773
  comment: any;
594
774
  skipEditorUpdate?: boolean | undefined;
595
775
  broadcastChanges?: boolean | undefined;
596
- }) => void;
776
+ }) => {
777
+ ok: boolean;
778
+ reason?: string;
779
+ detail?: string;
780
+ code?: string;
781
+ } | Promise<{
782
+ ok: boolean;
783
+ reason?: string;
784
+ detail?: string;
785
+ code?: string;
786
+ }>;
597
787
  cancelComment: (superdoc: any) => void;
598
788
  deleteComment: ({ commentId: commentIdToDelete, superdoc }: {
599
789
  commentId: any;
@@ -630,16 +820,59 @@ export const useCommentsStore: import('pinia').StoreDefinition<"comments", Pick<
630
820
  clearInstantSidebarAlignment: () => void;
631
821
  decideTrackedChangeFromSidebar: ({ superdoc, comment, decision }: {
632
822
  superdoc: Object;
633
- editor: Object;
634
- }) => void;
823
+ comment: Object;
824
+ decision: string;
825
+ }) => {
826
+ ok: boolean;
827
+ success?: boolean;
828
+ reason?: string;
829
+ } | Promise<{
830
+ ok: boolean;
831
+ success?: boolean;
832
+ reason?: string;
833
+ }>;
635
834
  v2CommentsAdapter: import('vue').ShallowRef<null, null>;
636
835
  setV2CommentsAdapter: (adapter: any) => void;
637
836
  getV2CommentsAdapter: (superdoc: any) => any;
638
- applyReviewWindowFromV2: ({ superdoc, commentsAdapter, trackedChangesAdapter, documentId, commentItems, trackedChangeItems, preparedReview, requestedCommentIds, requestedTrackedChangeIds, unresolvedCommentIds, trackedList, sourceCoverageRevision, evaluatedRevision, patch, }?: {}) => any;
837
+ applyReviewWindowFromV2: ({ superdoc, commentsAdapter, trackedChangesAdapter, documentId, commentItems, trackedChangeItems, preparedReview, requestedCommentIds, requestedTrackedChangeIds, unresolvedCommentIds, trackedList, sourceCoverageRevision, evaluatedRevision, patch, }?: {}) => {
838
+ ok: boolean;
839
+ geometryOnly: boolean;
840
+ commentItems?: undefined;
841
+ trackedItems?: undefined;
842
+ reason?: undefined;
843
+ detail?: undefined;
844
+ } | {
845
+ ok: boolean;
846
+ commentItems: any;
847
+ trackedItems: any;
848
+ geometryOnly?: undefined;
849
+ reason?: undefined;
850
+ detail?: undefined;
851
+ } | {
852
+ ok: boolean;
853
+ reason: any;
854
+ geometryOnly?: undefined;
855
+ commentItems?: undefined;
856
+ trackedItems?: undefined;
857
+ detail?: undefined;
858
+ } | {
859
+ ok: boolean;
860
+ reason: string;
861
+ detail: any;
862
+ geometryOnly?: undefined;
863
+ commentItems?: undefined;
864
+ trackedItems?: undefined;
865
+ };
639
866
  reconcileCommentsFromV2: ({ superdoc, adapter, documentId, items, preparedInputs, pruneStale, hydrationGeneration, }?: {
640
867
  preparedInputs?: null | undefined;
641
868
  pruneStale?: boolean | undefined;
642
- }) => any;
869
+ }) => {
870
+ added: null;
871
+ dropped: string;
872
+ } | {
873
+ added: any;
874
+ dropped?: undefined;
875
+ };
643
876
  announceV2CommentCreated: ({ superdoc, commentId }?: {}) => Promise<{
644
877
  ok: boolean;
645
878
  reason: string;
@@ -662,7 +895,19 @@ export const useCommentsStore: import('pinia').StoreDefinition<"comments", Pick<
662
895
  };
663
896
  isV2EditorActive: (superdoc: any) => boolean;
664
897
  replyCommentV2: ({ superdoc, parentCommentId, text, mentions, trackedChangeTarget }?: {
665
- mentions?: never[] | undefined;
898
+ superdoc?: Object | undefined;
899
+ parentCommentId?: string | null | undefined;
900
+ text?: string | undefined;
901
+ mentions?: {
902
+ name?: string | null;
903
+ email?: string | null;
904
+ }[] | undefined;
905
+ trackedChangeTarget?: {
906
+ kind: "trackedChange";
907
+ trackedChangeId: string;
908
+ story?: unknown;
909
+ side?: import('./helpers/tracked-change-thread-index.js').TrackedChangeSideGroup;
910
+ } | undefined;
666
911
  }) => Promise<any>;
667
912
  editCommentV2: ({ superdoc, commentId, text }?: {}) => Promise<any>;
668
913
  resolveCommentV2: ({ superdoc, commentId }?: {}) => Promise<any>;
@@ -690,7 +935,7 @@ export const useCommentsStore: import('pinia').StoreDefinition<"comments", Pick<
690
935
  resolvedIds: never[];
691
936
  unresolvedIds: never[];
692
937
  allResolved: boolean;
693
- removedRows: any;
938
+ removedRows: number;
694
939
  reason?: undefined;
695
940
  removedIds?: undefined;
696
941
  } | {
@@ -710,6 +955,10 @@ export const useCommentsStore: import('pinia').StoreDefinition<"comments", Pick<
710
955
  previousPreparedPresentation?: null | undefined;
711
956
  liveIds?: null | undefined;
712
957
  liveAnchorKeys?: null | undefined;
713
- }) => any;
958
+ }) => {
959
+ liveIds: Set<any>;
960
+ liveAnchorKeys: Set<any>;
961
+ appliedCount: number;
962
+ } | undefined;
714
963
  remapTrackedChangeIdentities: (pairs?: any[], { documentId }?: {}) => void;
715
- }, "getCommentAliasIds" | "getTrackedChangeThread" | "getCommentPositionKey" | "getCommentPosition" | "resolveCommentPositionEntry" | "getCommentDocumentId" | "belongsToDocument" | "init" | "setViewingVisibility" | "getComment" | "setActiveComment" | "getCommentLocation" | "hasOverlapId" | "getPendingComment" | "showAddComment" | "addComment" | "addHydratedComment" | "cancelComment" | "deleteComment" | "removePendingComment" | "removeCommentsForDocument" | "setReviewDirectoryFromV2" | "clearReviewDirectory" | "handleEditorLocationsUpdate" | "clearEditorCommentPositions" | "handleTrackedChangeUpdate" | "syncResolvedCommentsWithDocument" | "setActiveFloatingCommentInstance" | "requestInstantSidebarAlignment" | "peekInstantSidebarAlignment" | "clearInstantSidebarAlignment" | "decideTrackedChangeFromSidebar" | "setV2CommentsAdapter" | "getV2CommentsAdapter" | "applyReviewWindowFromV2" | "reconcileCommentsFromV2" | "announceV2CommentCreated" | "dropCommentsFromMutationImpact" | "isV2EditorActive" | "replyCommentV2" | "editCommentV2" | "resolveCommentV2" | "reopenCommentV2" | "setV2TrackedChangesAdapter" | "getV2TrackedChangesAdapter" | "getV2TrackedChangeRowCount" | "reconcileTrackedChangeMutationFromV2" | "reconcileTrackedChangesFromV2" | "remapTrackedChangeIdentities">>;
964
+ }, "resolveCommentPositionEntry" | "getCommentAliasIds" | "getCommentPositionKey" | "getComment" | "getTrackedChangeThread" | "getCommentPosition" | "getCommentDocumentId" | "belongsToDocument" | "init" | "setViewingVisibility" | "setActiveComment" | "getPendingComment" | "showAddComment" | "addComment" | "addHydratedComment" | "cancelComment" | "deleteComment" | "removePendingComment" | "removeCommentsForDocument" | "setReviewDirectoryFromV2" | "clearReviewDirectory" | "handleEditorLocationsUpdate" | "clearEditorCommentPositions" | "handleTrackedChangeUpdate" | "syncResolvedCommentsWithDocument" | "setActiveFloatingCommentInstance" | "requestInstantSidebarAlignment" | "peekInstantSidebarAlignment" | "clearInstantSidebarAlignment" | "decideTrackedChangeFromSidebar" | "setV2CommentsAdapter" | "getV2CommentsAdapter" | "applyReviewWindowFromV2" | "reconcileCommentsFromV2" | "announceV2CommentCreated" | "dropCommentsFromMutationImpact" | "isV2EditorActive" | "replyCommentV2" | "editCommentV2" | "resolveCommentV2" | "reopenCommentV2" | "setV2TrackedChangesAdapter" | "getV2TrackedChangesAdapter" | "getV2TrackedChangeRowCount" | "reconcileTrackedChangeMutationFromV2" | "reconcileTrackedChangesFromV2" | "remapTrackedChangeIdentities">>;