@stll/folio-vue 0.23.0 → 0.25.0

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 (116) hide show
  1. package/README.md +24 -0
  2. package/dist/ListButtons-B8HxA64I.cjs +4 -0
  3. package/dist/{ListButtons-DjLPhg8p.js → ListButtons-BeELtp_-.js} +201 -188
  4. package/dist/{SplitCellDialog-Id6nLwrR.js → SplitCellDialog-CSqbtDum.js} +748 -732
  5. package/dist/SplitCellDialog-DzKBu09z.cjs +15 -0
  6. package/dist/components/AnonymizationRectsOverlay.vue.d.ts +20 -0
  7. package/dist/components/AutocompleteCaretOverlay.vue.d.ts +4 -0
  8. package/dist/components/AutocompleteSuggestionOverlay.vue.d.ts +11 -0
  9. package/dist/components/CommentMarginMarkers.vue.d.ts +16 -0
  10. package/dist/components/ContentControlWidgetsOverlay.vue.d.ts +8 -0
  11. package/dist/components/DecorationLayer.vue.d.ts +12 -0
  12. package/dist/components/DocumentName.vue.d.ts +13 -0
  13. package/dist/components/DocumentOutline.vue.d.ts +28 -0
  14. package/dist/components/DocxEditor/DocxEditorDialogs.vue.d.ts +73 -0
  15. package/dist/components/DocxEditor/DocxEditorMenuBar.vue.d.ts +39 -0
  16. package/dist/components/DocxEditor/DocxEditorOverlays.vue.d.ts +42 -0
  17. package/dist/components/DocxEditor/types.d.ts +11 -4
  18. package/dist/components/DocxEditor.vue.d.ts +58 -0
  19. package/dist/components/EditingModeDropdown.vue.d.ts +11 -0
  20. package/dist/components/EditorToolbar.vue.d.ts +30 -0
  21. package/dist/components/FormattingBar.vue.d.ts +20 -0
  22. package/dist/components/HeaderFooterSelectionOverlay.vue.d.ts +12 -0
  23. package/dist/components/ImageContextMenu.vue.d.ts +24 -0
  24. package/dist/components/ImageSelectionOverlay.vue.d.ts +21 -0
  25. package/dist/components/InlineHeaderFooterEditor.vue.d.ts +15 -0
  26. package/dist/components/MenuBar.vue.d.ts +18 -0
  27. package/dist/components/PageIndicator.vue.d.ts +8 -0
  28. package/dist/components/PassageHighlightOverlay.vue.d.ts +16 -0
  29. package/dist/components/PrintButton.vue.d.ts +16 -0
  30. package/dist/components/ReviewControls.vue.d.ts +17 -0
  31. package/dist/components/TemplateDirectivesOverlay.vue.d.ts +15 -0
  32. package/dist/components/TextContextMenu.vue.d.ts +46 -0
  33. package/dist/components/TitleBar.vue.d.ts +17 -0
  34. package/dist/components/Toolbar.vue.d.ts +139 -0
  35. package/dist/components/UnifiedSidebar.vue.d.ts +55 -0
  36. package/dist/components/dialogs/FindReplaceDialog.vue.d.ts +20 -0
  37. package/dist/components/dialogs/FootnotePropertiesDialog.vue.d.ts +15 -0
  38. package/dist/components/dialogs/HyperlinkDialog.vue.d.ts +30 -0
  39. package/dist/components/dialogs/ImagePositionDialog.vue.d.ts +29 -0
  40. package/dist/components/dialogs/ImagePropertiesDialog.vue.d.ts +13 -0
  41. package/dist/components/dialogs/InsertImageDialog.vue.d.ts +21 -0
  42. package/dist/components/dialogs/InsertSymbolDialog.vue.d.ts +12 -0
  43. package/dist/components/dialogs/InsertTableDialog.vue.d.ts +22 -0
  44. package/dist/components/dialogs/PageSetupDialog.vue.d.ts +14 -0
  45. package/dist/components/dialogs/PasteSpecialDialog.vue.d.ts +16 -0
  46. package/dist/components/dialogs/SetNumberingValueDialog.vue.d.ts +12 -0
  47. package/dist/components/dialogs/SplitCellDialog.vue.d.ts +22 -0
  48. package/dist/components/dialogs/TablePropertiesDialog.vue.d.ts +15 -0
  49. package/dist/components/dialogs/WatermarkDialog.vue.d.ts +14 -0
  50. package/dist/components/dialogs/index.d.ts +13 -13
  51. package/dist/components/sidebar/AddCommentCard.vue.d.ts +9 -0
  52. package/dist/components/sidebar/Avatar.vue.d.ts +10 -0
  53. package/dist/components/sidebar/CommentCard.vue.d.ts +21 -0
  54. package/dist/components/sidebar/ReplyInput.vue.d.ts +7 -0
  55. package/dist/components/sidebar/ReplyThread.vue.d.ts +8 -0
  56. package/dist/components/sidebar/ResolvedCommentMarker.vue.d.ts +11 -0
  57. package/dist/components/sidebar/TrackedChangeCard.vue.d.ts +20 -0
  58. package/dist/components/ui/AlignmentButtons.vue.d.ts +15 -0
  59. package/dist/components/ui/Button.vue.d.ts +30 -0
  60. package/dist/components/ui/Checkbox.vue.d.ts +11 -0
  61. package/dist/components/ui/ColorPicker.vue.d.ts +30 -0
  62. package/dist/components/ui/DatePickerPopover.vue.d.ts +13 -0
  63. package/dist/components/ui/Dialog.vue.d.ts +28 -0
  64. package/dist/components/ui/FontPicker.vue.d.ts +21 -0
  65. package/dist/components/ui/FontSizePicker.vue.d.ts +27 -0
  66. package/dist/components/ui/HorizontalRuler.vue.d.ts +39 -0
  67. package/dist/components/ui/HyperlinkPopup.vue.d.ts +21 -0
  68. package/dist/components/ui/IconGridDropdown.vue.d.ts +32 -0
  69. package/dist/components/ui/ImageTransformDropdown.vue.d.ts +11 -0
  70. package/dist/components/ui/ImageWrapDropdown.vue.d.ts +15 -0
  71. package/dist/components/ui/Input.vue.d.ts +17 -0
  72. package/dist/components/ui/LineSpacingPicker.vue.d.ts +20 -0
  73. package/dist/components/ui/ListButtons.vue.d.ts +30 -0
  74. package/dist/components/ui/MaterialSymbol.vue.d.ts +13 -0
  75. package/dist/components/ui/MenuDropdown.vue.d.ts +42 -0
  76. package/dist/components/ui/OutlineRail.vue.d.ts +19 -0
  77. package/dist/components/ui/Popover.vue.d.ts +40 -0
  78. package/dist/components/ui/Select.vue.d.ts +15 -0
  79. package/dist/components/ui/StylePicker.vue.d.ts +16 -0
  80. package/dist/components/ui/TableBorderColorPicker.vue.d.ts +14 -0
  81. package/dist/components/ui/TableBorderPicker.vue.d.ts +11 -0
  82. package/dist/components/ui/TableBorderWidthPicker.vue.d.ts +10 -0
  83. package/dist/components/ui/TableCellFillPicker.vue.d.ts +14 -0
  84. package/dist/components/ui/TableGridInline.vue.d.ts +14 -0
  85. package/dist/components/ui/TableGridPicker.vue.d.ts +18 -0
  86. package/dist/components/ui/TableMoreDropdown.vue.d.ts +51 -0
  87. package/dist/components/ui/TableStyleGallery.vue.d.ts +10 -0
  88. package/dist/components/ui/TableToolbar.vue.d.ts +61 -0
  89. package/dist/components/ui/VerticalRuler.vue.d.ts +20 -0
  90. package/dist/components/ui/ZoomControl.vue.d.ts +12 -0
  91. package/dist/components/ui/icon-paths.json.d.ts +276 -0
  92. package/dist/composables/useDocxEditor.d.ts +3 -0
  93. package/dist/composables/useDocxEditorRefApi.d.ts +3 -0
  94. package/dist/composables/useFindReplace.d.ts +5 -1
  95. package/dist/composables/useFontLifecycle.d.ts +1 -0
  96. package/dist/composables.cjs +2 -2
  97. package/dist/composables.js +45 -44
  98. package/dist/dialogs.cjs +1 -1
  99. package/dist/dialogs.js +2 -5
  100. package/dist/folio-vue.css +1 -156
  101. package/dist/index.cjs +1 -1
  102. package/dist/index.d.ts +2 -0
  103. package/dist/index.js +1456 -1409
  104. package/dist/ui.cjs +1 -1
  105. package/dist/ui.js +2 -2
  106. package/dist/useFindReplace-BbW0xWo7.js +74 -0
  107. package/dist/useFindReplace-neQmDh2i.cjs +1 -0
  108. package/dist/useZoom-B1miNAf_.cjs +1 -0
  109. package/dist/{useZoom-D8Wi1XkB.js → useZoom-Bw5gp69V.js} +262 -252
  110. package/dist/utils/embeddedFonts.d.ts +1 -1
  111. package/package.json +22 -10
  112. package/dist/ListButtons-DIWR-Q8d.cjs +0 -4
  113. package/dist/SplitCellDialog-B_z6ynxm.cjs +0 -15
  114. package/dist/useFindReplace-CL8Rbc3y.js +0 -59
  115. package/dist/useFindReplace-ZCrdvwEk.cjs +0 -1
  116. package/dist/useZoom-CkbPWZ64.cjs +0 -1
@@ -0,0 +1,28 @@
1
+ import { HeadingInfo } from '@stll/folio-core/utils/headingCollector';
2
+ import { OutlineDepth } from '@stll/folio-core/utils/outlineDepth';
3
+ import { OutlineSurface } from '../composables/useOutlineDrawerFocus';
4
+ type __VLS_Props = {
5
+ headings: HeadingInfo[];
6
+ available: boolean;
7
+ outlineDepth: OutlineDepth;
8
+ getScrollContainer: () => HTMLElement | null;
9
+ docSize: number;
10
+ activeId: string | null;
11
+ surface: OutlineSurface;
12
+ expanded?: boolean;
13
+ };
14
+ declare const __VLS_export: import('vue').DefineComponent<__VLS_Props, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {
15
+ close: () => any;
16
+ navigate: (pmPos: number) => any;
17
+ expand: () => any;
18
+ outlineDepthChange: (depth: OutlineDepth) => any;
19
+ }, string, import('vue').PublicProps, Readonly<__VLS_Props> & Readonly<{
20
+ onClose?: () => any;
21
+ onNavigate?: (pmPos: number) => any;
22
+ onExpand?: () => any;
23
+ onOutlineDepthChange?: (depth: OutlineDepth) => any;
24
+ }>, {
25
+ expanded: boolean;
26
+ }, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, any>;
27
+ declare const _default: typeof __VLS_export;
28
+ export default _default;
@@ -0,0 +1,73 @@
1
+ import { EditorView } from 'prosemirror-view';
2
+ import { DisplayMode, EditorReadOnlyReason } from '@stll/folio-core/managers/EditorModeManager';
3
+ import { TablePropertiesCommand } from '@stll/folio-core/utils/tableOperations';
4
+ import { SectionProperties } from '@stll/folio-core/types/document';
5
+ import { Watermark } from '@stll/folio-core/watermark';
6
+ type BookmarkOption = {
7
+ name: string;
8
+ label?: string;
9
+ };
10
+ type HyperlinkSubmitPayload = {
11
+ url?: string;
12
+ bookmark?: string;
13
+ displayText: string;
14
+ tooltip: string;
15
+ };
16
+ type __VLS_Props = {
17
+ view: EditorView | null;
18
+ markupView?: DisplayMode;
19
+ readOnly?: boolean;
20
+ onReadonlyEditAttempt?: (reason: EditorReadOnlyReason) => void;
21
+ bookmarks: BookmarkOption[];
22
+ selectedImagePmPos: number | null;
23
+ sectionProperties: SectionProperties | null;
24
+ scrollVisiblePositionIntoView: (pmPos: number) => void;
25
+ showFindReplace: boolean;
26
+ showHyperlink: boolean;
27
+ showInsertSymbol: boolean;
28
+ showImageProperties: boolean;
29
+ showPageSetup: boolean;
30
+ showTableProperties: boolean;
31
+ showWatermark: boolean;
32
+ showNumberingValue: boolean;
33
+ currentWatermark: Watermark | undefined;
34
+ tableProperties: TablePropertiesCommand;
35
+ };
36
+ declare const __VLS_export: import('vue').DefineComponent<__VLS_Props, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {} & {
37
+ "update:showFindReplace": (value: boolean) => any;
38
+ "update:showHyperlink": (value: boolean) => any;
39
+ "update:showInsertSymbol": (value: boolean) => any;
40
+ "update:showImageProperties": (value: boolean) => any;
41
+ "update:showPageSetup": (value: boolean) => any;
42
+ "update:showTableProperties": (value: boolean) => any;
43
+ "update:showWatermark": (value: boolean) => any;
44
+ "update:showNumberingValue": (value: boolean) => any;
45
+ "numbering-value-apply": (value: number) => any;
46
+ "insert-symbol": (symbol: string) => any;
47
+ "hyperlink-submit": (data: HyperlinkSubmitPayload) => any;
48
+ "hyperlink-remove": () => any;
49
+ "page-setup-apply": (props: Partial<SectionProperties>) => any;
50
+ "table-properties-apply": (props: TablePropertiesCommand) => any;
51
+ "watermark-apply": (watermark: Watermark | undefined) => any;
52
+ }, string, import('vue').PublicProps, Readonly<__VLS_Props> & Readonly<{
53
+ "onUpdate:showFindReplace"?: (value: boolean) => any;
54
+ "onUpdate:showHyperlink"?: (value: boolean) => any;
55
+ "onUpdate:showInsertSymbol"?: (value: boolean) => any;
56
+ "onUpdate:showImageProperties"?: (value: boolean) => any;
57
+ "onUpdate:showPageSetup"?: (value: boolean) => any;
58
+ "onUpdate:showTableProperties"?: (value: boolean) => any;
59
+ "onUpdate:showWatermark"?: (value: boolean) => any;
60
+ "onUpdate:showNumberingValue"?: (value: boolean) => any;
61
+ "onNumbering-value-apply"?: (value: number) => any;
62
+ "onInsert-symbol"?: (symbol: string) => any;
63
+ "onHyperlink-submit"?: (data: HyperlinkSubmitPayload) => any;
64
+ "onHyperlink-remove"?: () => any;
65
+ "onPage-setup-apply"?: (props: Partial<SectionProperties>) => any;
66
+ "onTable-properties-apply"?: (props: TablePropertiesCommand) => any;
67
+ "onWatermark-apply"?: (watermark: Watermark | undefined) => any;
68
+ }>, {
69
+ markupView: DisplayMode;
70
+ readOnly: boolean;
71
+ }, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, any>;
72
+ declare const _default: typeof __VLS_export;
73
+ export default _default;
@@ -0,0 +1,39 @@
1
+ type __VLS_Props = {
2
+ showMenuBar?: boolean;
3
+ documentName?: string;
4
+ documentNameEditable?: boolean;
5
+ showFileOpen?: boolean;
6
+ showHelpMenu?: boolean;
7
+ /** Gates the Insert > Table menu item (mirrors the toolbar's showTableInsert). */
8
+ showTableInsert?: boolean;
9
+ };
10
+ declare var __VLS_1: {}, __VLS_18: {};
11
+ type __VLS_Slots = {} & {
12
+ 'title-bar-left'?: (props: typeof __VLS_1) => any;
13
+ } & {
14
+ 'title-bar-right'?: (props: typeof __VLS_18) => any;
15
+ };
16
+ declare const __VLS_base: import('vue').DefineComponent<__VLS_Props, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {} & {
17
+ "insert-table": (rows: number, cols: number) => any;
18
+ rename: (name: string) => any;
19
+ "menu-action": (action: string) => any;
20
+ }, string, import('vue').PublicProps, Readonly<__VLS_Props> & Readonly<{
21
+ "onInsert-table"?: (rows: number, cols: number) => any;
22
+ onRename?: (name: string) => any;
23
+ "onMenu-action"?: (action: string) => any;
24
+ }>, {
25
+ showFileOpen: boolean;
26
+ showHelpMenu: boolean;
27
+ showTableInsert: boolean;
28
+ showMenuBar: boolean;
29
+ documentName: string;
30
+ documentNameEditable: boolean;
31
+ }, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, any>;
32
+ declare const __VLS_export: __VLS_WithSlots<typeof __VLS_base, __VLS_Slots>;
33
+ declare const _default: typeof __VLS_export;
34
+ export default _default;
35
+ type __VLS_WithSlots<T, S> = T & {
36
+ new (): {
37
+ $slots: S;
38
+ };
39
+ };
@@ -0,0 +1,42 @@
1
+ import { ImageLayoutTarget } from '@stll/folio-core/layout-painter/imageLayout';
2
+ import { ListNumberingMenuState } from '@stll/folio-core/prosemirror';
3
+ import { ImageContextMenuState, ImageContextMenuTextAction } from '../imageContextMenuTypes';
4
+ import { CustomTextMenuItem } from '../TextContextMenu.vue';
5
+ /** Text/table context-menu state (mirrors useContextMenus `TextContextMenuState`). */
6
+ type TextContextMenuState = {
7
+ isOpen: boolean;
8
+ position: {
9
+ x: number;
10
+ y: number;
11
+ };
12
+ hasSelection: boolean;
13
+ inTable: boolean;
14
+ onImage: boolean;
15
+ canMergeCells: boolean;
16
+ canSplitCell: boolean;
17
+ listNumbering: ListNumberingMenuState;
18
+ };
19
+ type __VLS_Props = {
20
+ readOnly: boolean;
21
+ contextMenu: TextContextMenuState;
22
+ imageContextMenu: ImageContextMenuState | null;
23
+ imageContextMenuTextActions: ImageContextMenuTextAction[];
24
+ canOpenImageProperties: boolean;
25
+ /** Host-injected menu entries leading the text menu. */
26
+ customTextMenuItems: readonly CustomTextMenuItem[];
27
+ };
28
+ declare const __VLS_export: import('vue').DefineComponent<__VLS_Props, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {} & {
29
+ "context-menu-action": (action: string) => any;
30
+ "close-context-menu": () => any;
31
+ "image-wrap-select": (target: ImageLayoutTarget) => any;
32
+ "close-image-context-menu": () => any;
33
+ "open-image-properties": () => any;
34
+ }, string, import('vue').PublicProps, Readonly<__VLS_Props> & Readonly<{
35
+ "onContext-menu-action"?: (action: string) => any;
36
+ "onClose-context-menu"?: () => any;
37
+ "onImage-wrap-select"?: (target: ImageLayoutTarget) => any;
38
+ "onClose-image-context-menu"?: () => any;
39
+ "onOpen-image-properties"?: () => any;
40
+ }>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, any>;
41
+ declare const _default: typeof __VLS_export;
42
+ export default _default;
@@ -1,4 +1,6 @@
1
1
  import { CSSProperties, VNodeChild } from 'vue';
2
+ import { ReviewDisplayMode } from '@stll/folio-core/managers/reviewDisplayMode';
3
+ import { EditorReadOnlyReason, EditorMode } from '@stll/folio-core/managers/EditorModeManager';
2
4
  import { PageRendererName } from '@stll/folio-core/display-list/editor/pageRenderer';
3
5
  import { Plugin } from 'prosemirror-state';
4
6
  import { EditorView } from 'prosemirror-view';
@@ -20,7 +22,6 @@ import { DocxInput } from '@stll/folio-core/utils/docxInput';
20
22
  import { OutlineDepth } from '@stll/folio-core/utils/outlineDepth';
21
23
  import { ScrollToParaIdOptions } from '@stll/folio-core/paged-layout/paragraphFlash';
22
24
  import { BlockRect } from '@stll/folio-core/paged-layout/blockGeometry';
23
- import { EditorMode } from '@stll/folio-core/managers/EditorModeManager';
24
25
  import { DocumentLoadState } from '@stll/folio-core/managers/DocumentLoaderManager';
25
26
  import { FolioUIComponents } from '../../ui/folio-ui';
26
27
  import { FontOption } from '../../utils/fontOptions';
@@ -164,9 +165,9 @@ export type DocxEditorProps = {
164
165
  * replace (Cmd/Ctrl+F, Cmd/Ctrl+H), hyperlink (Cmd/Ctrl+K), `File > Open`
165
166
  * (Cmd/Ctrl+O) and zoom (Cmd/Ctrl+0, +, -). Editing keymaps inside the
166
167
  * document body are unaffected.
167
- * - `"document"`: every press on the page. Default; for a page whose only
168
+ * - `"document"`: every press on the page; for a page whose only
168
169
  * surface is the editor.
169
- * - `"editor"`: only a press whose target is inside this editor, so a host
170
+ * - `"editor"` (default): only a press whose target is inside this editor, so a host
170
171
  * that docks the editor beside other panes keeps its own bindings
171
172
  * elsewhere.
172
173
  * - `"none"`: the editor answers no page-level press. The host dispatches
@@ -183,6 +184,10 @@ export type DocxEditorProps = {
183
184
  hostShortcuts?: readonly HostShortcut[];
184
185
  /** Whether the editor is read-only. When true, hides toolbar and rulers */
185
186
  readOnly?: boolean;
187
+ /** Controlled review view. Defaults to all-markup; saving preserves all revisions. */
188
+ reviewDisplayMode?: ReviewDisplayMode;
189
+ /** Show comment highlights in all-markup (default: true); hidden in final/original. */
190
+ showCommentHighlights?: boolean;
186
191
  /** Whether comments/tracked changes should auto-open the review sidebar (default: true) */
187
192
  autoOpenReviewSidebar?: boolean;
188
193
  /**
@@ -244,7 +249,7 @@ export type DocxEditorProps = {
244
249
  /** Callback when the editing mode changes */
245
250
  onModeChange?: (mode: EditorMode) => void;
246
251
  /** Callback when a readonly user action would mutate the document. */
247
- onReadonlyEditAttempt?: () => void;
252
+ onReadonlyEditAttempt?: (reason: EditorReadOnlyReason) => void;
248
253
  /**
249
254
  * Controlled comments array. When provided, the editor reads comment thread
250
255
  * metadata from this prop and emits every change through `onCommentsChange`.
@@ -373,6 +378,8 @@ export type HighlightPassageOptions = {
373
378
  * Imperative handle exposed by the DocxEditor component.
374
379
  */
375
380
  export type DocxEditorRef = {
381
+ /** Why user edits are blocked in the current view, or null when editing is enabled. */
382
+ getReadOnlyReason: () => EditorReadOnlyReason | null;
376
383
  /** Get the current document */
377
384
  getDocument: () => Document | null;
378
385
  /** Whether the live ProseMirror state has edits that have not been serialized. */
@@ -0,0 +1,58 @@
1
+ import { Comment } from '@stll/folio-core/types/content';
2
+ import { Document } from '@stll/folio-core/types/document';
3
+ import { DocxEditorProps, EditorMode } from './DocxEditor/types';
4
+ declare var __VLS_12: {}, __VLS_15: {}, __VLS_50: {}, __VLS_70: {}, __VLS_77: {};
5
+ type __VLS_Slots = {} & {
6
+ 'title-bar-left'?: (props: typeof __VLS_12) => any;
7
+ } & {
8
+ 'title-bar-right'?: (props: typeof __VLS_15) => any;
9
+ } & {
10
+ 'toolbar-extra'?: (props: typeof __VLS_50) => any;
11
+ } & {
12
+ 'loading-indicator'?: (props: typeof __VLS_70) => any;
13
+ } & {
14
+ placeholder?: (props: typeof __VLS_77) => any;
15
+ };
16
+ declare const __VLS_base: import('vue').DefineComponent<DocxEditorProps, import('..').DocxEditorRef, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {} & {
17
+ error: (error: Error) => any;
18
+ change: (doc: Document) => any;
19
+ rename: (name: string) => any;
20
+ "menu-action": (action: string) => any;
21
+ ready: () => any;
22
+ "mode-change": (mode: EditorMode) => any;
23
+ "update:document": (doc: Document | null) => any;
24
+ "comments-change": (comments: Comment[]) => any;
25
+ }, string, import('vue').PublicProps, Readonly<DocxEditorProps> & Readonly<{
26
+ onError?: (error: Error) => any;
27
+ onChange?: (doc: Document) => any;
28
+ onRename?: (name: string) => any;
29
+ "onMenu-action"?: (action: string) => any;
30
+ onReady?: () => any;
31
+ "onMode-change"?: (mode: EditorMode) => any;
32
+ "onUpdate:document"?: (doc: Document | null) => any;
33
+ "onComments-change"?: (comments: Comment[]) => any;
34
+ }>, {
35
+ document: Document | null;
36
+ mode: EditorMode;
37
+ author: string;
38
+ className: string;
39
+ readOnly: boolean;
40
+ showTableInsert: boolean | undefined;
41
+ showZoomControl: boolean;
42
+ showReviewControls: boolean;
43
+ showCommentHighlights: boolean;
44
+ documentBuffer: import('@stll/folio-core/utils/docxInput').DocxInput | null;
45
+ showToolbar: boolean;
46
+ showHeaderFooterEditing: boolean;
47
+ initialZoom: number;
48
+ autoOpenReviewSidebar: boolean;
49
+ showOutline: boolean;
50
+ }, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, any>;
51
+ declare const __VLS_export: __VLS_WithSlots<typeof __VLS_base, __VLS_Slots>;
52
+ declare const _default: typeof __VLS_export;
53
+ export default _default;
54
+ type __VLS_WithSlots<T, S> = T & {
55
+ new (): {
56
+ $slots: S;
57
+ };
58
+ };
@@ -0,0 +1,11 @@
1
+ import { EditorMode } from './DocxEditor/types';
2
+ type __VLS_Props = {
3
+ modelValue: EditorMode;
4
+ };
5
+ declare const __VLS_export: import('vue').DefineComponent<__VLS_Props, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {} & {
6
+ "update:modelValue": (mode: EditorMode) => any;
7
+ }, string, import('vue').PublicProps, Readonly<__VLS_Props> & Readonly<{
8
+ "onUpdate:modelValue"?: (mode: EditorMode) => any;
9
+ }>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, any>;
10
+ declare const _default: typeof __VLS_export;
11
+ export default _default;
@@ -0,0 +1,30 @@
1
+ type __VLS_Props = {
2
+ showMenuBar?: boolean;
3
+ };
4
+ declare var __VLS_1: {}, __VLS_3: {}, __VLS_5: {}, __VLS_14: {}, __VLS_16: {};
5
+ type __VLS_Slots = {} & {
6
+ 'title-bar'?: (props: typeof __VLS_1) => any;
7
+ } & {
8
+ 'title-bar-left'?: (props: typeof __VLS_3) => any;
9
+ } & {
10
+ 'document-name'?: (props: typeof __VLS_5) => any;
11
+ } & {
12
+ 'title-bar-right'?: (props: typeof __VLS_14) => any;
13
+ } & {
14
+ toolbar?: (props: typeof __VLS_16) => any;
15
+ };
16
+ declare const __VLS_base: import('vue').DefineComponent<__VLS_Props, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {} & {
17
+ "menu-action": (action: string) => any;
18
+ }, string, import('vue').PublicProps, Readonly<__VLS_Props> & Readonly<{
19
+ "onMenu-action"?: (action: string) => any;
20
+ }>, {
21
+ showMenuBar: boolean;
22
+ }, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, any>;
23
+ declare const __VLS_export: __VLS_WithSlots<typeof __VLS_base, __VLS_Slots>;
24
+ declare const _default: typeof __VLS_export;
25
+ export default _default;
26
+ type __VLS_WithSlots<T, S> = T & {
27
+ new (): {
28
+ $slots: S;
29
+ };
30
+ };
@@ -0,0 +1,20 @@
1
+ import { FormattingAction, FormattingBarProps } from './FormattingBar.types';
2
+ declare const __VLS_export: import('vue').DefineComponent<FormattingBarProps, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {} & {
3
+ format: (action: FormattingAction) => any;
4
+ undo: () => any;
5
+ redo: () => any;
6
+ }, string, import('vue').PublicProps, Readonly<FormattingBarProps> & Readonly<{
7
+ onFormat?: (action: FormattingAction) => any;
8
+ onUndo?: () => any;
9
+ onRedo?: () => any;
10
+ }>, {
11
+ disabled: boolean;
12
+ canUndo: boolean;
13
+ canRedo: boolean;
14
+ showStylePicker: boolean;
15
+ showTextColorPicker: boolean;
16
+ showAlignmentButtons: boolean;
17
+ showListButtons: boolean;
18
+ }, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, any>;
19
+ declare const _default: typeof __VLS_export;
20
+ export default _default;
@@ -0,0 +1,12 @@
1
+ import { EditorView } from 'prosemirror-view';
2
+ import { HeaderFooterSelection } from '@stll/folio-core/render-dom/HeaderFooterSelectionOverlay';
3
+ type __VLS_Props = {
4
+ pagesContainer: HTMLElement | null;
5
+ hiddenContainer: HTMLElement | null;
6
+ editorView: EditorView | null;
7
+ selection: HeaderFooterSelection | null;
8
+ zoom: number;
9
+ };
10
+ declare const __VLS_export: import('vue').DefineComponent<__VLS_Props, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<__VLS_Props> & Readonly<{}>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, any>;
11
+ declare const _default: typeof __VLS_export;
12
+ export default _default;
@@ -0,0 +1,24 @@
1
+ import { ImageLayoutTarget } from '@stll/folio-core/layout-painter/imageLayout';
2
+ import { ImageContextMenuState, ImageContextMenuTextAction } from './imageContextMenuTypes';
3
+ export type { ImageContextMenuState, ImageContextMenuTextAction };
4
+ type __VLS_Props = {
5
+ state: ImageContextMenuState | null;
6
+ textActions?: ImageContextMenuTextAction[];
7
+ /** When true, an "Image properties…" entry appears at the top of the menu. */
8
+ canOpenProperties?: boolean;
9
+ };
10
+ declare const __VLS_export: import('vue').DefineComponent<__VLS_Props, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {} & {
11
+ close: () => any;
12
+ select: (target: ImageLayoutTarget) => any;
13
+ "text-action": (action: string) => any;
14
+ "open-properties": () => any;
15
+ }, string, import('vue').PublicProps, Readonly<__VLS_Props> & Readonly<{
16
+ onClose?: () => any;
17
+ onSelect?: (target: ImageLayoutTarget) => any;
18
+ "onText-action"?: (action: string) => any;
19
+ "onOpen-properties"?: () => any;
20
+ }>, {
21
+ canOpenProperties: boolean;
22
+ }, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, any>;
23
+ declare const _default: typeof __VLS_export;
24
+ export default _default;
@@ -0,0 +1,21 @@
1
+ import { EditorView } from 'prosemirror-view';
2
+ import { ImageSelectionInfo } from './imageSelectionTypes';
3
+ export type { ImageSelectionInfo };
4
+ type __VLS_Props = {
5
+ imageInfo: ImageSelectionInfo | null;
6
+ zoom: number;
7
+ view: EditorView | null;
8
+ };
9
+ declare const __VLS_export: import('vue').DefineComponent<__VLS_Props, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {} & {
10
+ "context-menu": (event: MouseEvent) => any;
11
+ deselect: () => any;
12
+ "interact-start": () => any;
13
+ "interact-end": () => any;
14
+ }, string, import('vue').PublicProps, Readonly<__VLS_Props> & Readonly<{
15
+ "onContext-menu"?: (event: MouseEvent) => any;
16
+ onDeselect?: () => any;
17
+ "onInteract-start"?: () => any;
18
+ "onInteract-end"?: () => any;
19
+ }>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, any>;
20
+ declare const _default: typeof __VLS_export;
21
+ export default _default;
@@ -0,0 +1,15 @@
1
+ import { EditorView } from 'prosemirror-view';
2
+ import { HfEditState } from '../composables/usePagesPointer';
3
+ type __VLS_Props = {
4
+ edit: HfEditState;
5
+ getView: () => EditorView | null;
6
+ };
7
+ declare const __VLS_export: import('vue').DefineComponent<__VLS_Props, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {
8
+ close: () => any;
9
+ remove: () => any;
10
+ }, string, import('vue').PublicProps, Readonly<__VLS_Props> & Readonly<{
11
+ onClose?: () => any;
12
+ onRemove?: () => any;
13
+ }>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, any>;
14
+ declare const _default: typeof __VLS_export;
15
+ export default _default;
@@ -0,0 +1,18 @@
1
+ type __VLS_Props = {
2
+ showFileOpen?: boolean;
3
+ showHelpMenu?: boolean;
4
+ showTableInsert?: boolean;
5
+ };
6
+ declare const __VLS_export: import('vue').DefineComponent<__VLS_Props, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {} & {
7
+ action: (action: string) => any;
8
+ "insert-table": (rows: number, cols: number) => any;
9
+ }, string, import('vue').PublicProps, Readonly<__VLS_Props> & Readonly<{
10
+ onAction?: (action: string) => any;
11
+ "onInsert-table"?: (rows: number, cols: number) => any;
12
+ }>, {
13
+ showFileOpen: boolean;
14
+ showHelpMenu: boolean;
15
+ showTableInsert: boolean;
16
+ }, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, any>;
17
+ declare const _default: typeof __VLS_export;
18
+ export default _default;
@@ -0,0 +1,8 @@
1
+ type __VLS_Props = {
2
+ currentPage: number;
3
+ totalPages: number;
4
+ visible: boolean;
5
+ };
6
+ declare const __VLS_export: import('vue').DefineComponent<__VLS_Props, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<__VLS_Props> & Readonly<{}>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, any>;
7
+ declare const _default: typeof __VLS_export;
8
+ export default _default;
@@ -0,0 +1,16 @@
1
+ import { FlowBlock, Layout, Measure } from '@stll/folio-core/layout-engine/types';
2
+ type __VLS_Props = {
3
+ /** PM range to highlight, or null to paint nothing. */
4
+ range: {
5
+ from: number;
6
+ to: number;
7
+ } | null;
8
+ getPagesContainer: () => HTMLElement | null;
9
+ zoom: number;
10
+ layout: Layout | null;
11
+ blocks: FlowBlock[];
12
+ measures: Measure[];
13
+ };
14
+ declare const __VLS_export: import('vue').DefineComponent<__VLS_Props, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<__VLS_Props> & Readonly<{}>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, any>;
15
+ declare const _default: typeof __VLS_export;
16
+ export default _default;
@@ -0,0 +1,16 @@
1
+ type __VLS_Props = {
2
+ disabled?: boolean;
3
+ label?: string;
4
+ compact?: boolean;
5
+ };
6
+ declare const __VLS_export: import('vue').DefineComponent<__VLS_Props, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {} & {
7
+ print: () => any;
8
+ }, string, import('vue').PublicProps, Readonly<__VLS_Props> & Readonly<{
9
+ onPrint?: () => any;
10
+ }>, {
11
+ label: string;
12
+ compact: boolean;
13
+ disabled: boolean;
14
+ }, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, any>;
15
+ declare const _default: typeof __VLS_export;
16
+ export default _default;
@@ -0,0 +1,17 @@
1
+ import { DisplayMode } from '@stll/folio-core/managers/EditorModeManager';
2
+ type __VLS_Props = {
3
+ trackChangesOn: boolean;
4
+ displayMode: DisplayMode;
5
+ readOnly?: boolean;
6
+ };
7
+ declare const __VLS_export: import('vue').DefineComponent<__VLS_Props, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {} & {
8
+ "toggle-track-changes": () => any;
9
+ "update:display-mode": (mode: "original" | "all-markup" | "simple-markup" | "no-markup") => any;
10
+ }, string, import('vue').PublicProps, Readonly<__VLS_Props> & Readonly<{
11
+ "onToggle-track-changes"?: () => any;
12
+ "onUpdate:display-mode"?: (mode: "original" | "all-markup" | "simple-markup" | "no-markup") => any;
13
+ }>, {
14
+ readOnly: boolean;
15
+ }, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, any>;
16
+ declare const _default: typeof __VLS_export;
17
+ export default _default;
@@ -0,0 +1,15 @@
1
+ import { EditorState } from 'prosemirror-state';
2
+ import { EditorView } from 'prosemirror-view';
3
+ import { FlowBlock, Layout, Measure } from '@stll/folio-core/layout-engine/types';
4
+ type __VLS_Props = {
5
+ getView: () => EditorView | null;
6
+ getPagesContainer: () => HTMLElement | null;
7
+ editorState: EditorState | null;
8
+ zoom: number;
9
+ layout: Layout | null;
10
+ blocks: FlowBlock[];
11
+ measures: Measure[];
12
+ };
13
+ declare const __VLS_export: import('vue').DefineComponent<__VLS_Props, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<__VLS_Props> & Readonly<{}>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, any>;
14
+ declare const _default: typeof __VLS_export;
15
+ export default _default;
@@ -0,0 +1,46 @@
1
+ import { VNodeChild } from 'vue';
2
+ import { ListNumberingMenuState } from '@stll/folio-core/prosemirror';
3
+ export type ContextMenuItem = {
4
+ id: string;
5
+ label: string;
6
+ action: string;
7
+ shortcut?: string;
8
+ disabled?: boolean;
9
+ divider?: boolean;
10
+ /** Host-injected primary action — rendered slightly bolder. */
11
+ emphasis?: boolean;
12
+ /** Optional leading icon (host `customContextMenuItems` entries). */
13
+ icon?: VNodeChild;
14
+ };
15
+ /** Host-injected menu entry, already filtered by `requiresSelection`. */
16
+ export type CustomTextMenuItem = {
17
+ id: string;
18
+ label: string;
19
+ icon?: VNodeChild;
20
+ };
21
+ type __VLS_Props = {
22
+ isOpen: boolean;
23
+ position: {
24
+ x: number;
25
+ y: number;
26
+ };
27
+ hasSelection: boolean;
28
+ isEditable: boolean;
29
+ inTable?: boolean;
30
+ onImage?: boolean;
31
+ canMergeCells?: boolean;
32
+ canSplitCell?: boolean;
33
+ /** Restart / continue / set-value entries for the list item under the caret. */
34
+ listNumbering?: ListNumberingMenuState;
35
+ /** Host-provided entries that lead the menu (already selection-filtered). */
36
+ customItems?: readonly CustomTextMenuItem[];
37
+ };
38
+ declare const __VLS_export: import('vue').DefineComponent<__VLS_Props, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {} & {
39
+ close: () => any;
40
+ action: (action: string) => any;
41
+ }, string, import('vue').PublicProps, Readonly<__VLS_Props> & Readonly<{
42
+ onClose?: () => any;
43
+ onAction?: (action: string) => any;
44
+ }>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, any>;
45
+ declare const _default: typeof __VLS_export;
46
+ export default _default;
@@ -0,0 +1,17 @@
1
+ declare var __VLS_1: {}, __VLS_3: {}, __VLS_5: {};
2
+ type __VLS_Slots = {} & {
3
+ left?: (props: typeof __VLS_1) => any;
4
+ } & {
5
+ default?: (props: typeof __VLS_3) => any;
6
+ } & {
7
+ right?: (props: typeof __VLS_5) => any;
8
+ };
9
+ declare const __VLS_base: import('vue').DefineComponent<{}, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, true, {}, any>;
10
+ declare const __VLS_export: __VLS_WithSlots<typeof __VLS_base, __VLS_Slots>;
11
+ declare const _default: typeof __VLS_export;
12
+ export default _default;
13
+ type __VLS_WithSlots<T, S> = T & {
14
+ new (): {
15
+ $slots: S;
16
+ };
17
+ };