ooxml-ui 1.34.0 → 1.36.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.
- package/custom-elements.json +14 -1
- package/dist/chart/format-pane-analysis.d.ts +0 -1
- package/dist/chart/format-pane-effects.d.ts +0 -1
- package/dist/chart/format-pane-fill-kinds.d.ts +0 -1
- package/dist/chart/format-pane-fill-line.d.ts +0 -1
- package/dist/chart/format-pane-targets.d.ts +0 -1
- package/dist/chart/format-pane-text.d.ts +0 -1
- package/dist/chrome/tab-drag.d.ts +27 -0
- package/dist/chrome/tab-drag.d.ts.map +1 -0
- package/dist/chrome/tab-strip.d.ts +25 -1
- package/dist/chrome/tab-strip.d.ts.map +1 -1
- package/dist/{chunk-CDC5MAZS.js → chunk-6VF4FEMY.js} +1 -1
- package/dist/chunk-7RRN2GPO.js +19 -0
- package/dist/{chunk-3AOIYE3R.js → chunk-7ST5QRD5.js} +1 -1
- package/dist/{chunk-6TS7ASDJ.js → chunk-C4KI635Q.js} +2 -17
- package/dist/{chunk-CALEXPBD.js → chunk-GZNBWWJ5.js} +840 -51
- package/dist/{chunk-KYXSQFDB.js → chunk-QAX4FAB7.js} +139 -4
- package/dist/{chunk-SWDVBUBW.js → chunk-Z4DML5NW.js} +3 -3
- package/dist/controls.d.ts +1 -1
- package/dist/controls.d.ts.map +1 -1
- package/dist/controls.js +1 -1
- package/dist/docx/building-blocks-actions.d.ts +2 -2
- package/dist/docx/editable-region-view.d.ts +4 -0
- package/dist/docx/editor-chrome.d.ts +1 -1
- package/dist/docx/editor-core.d.ts +4 -0
- package/dist/docx/editor-plugins.d.ts +3 -0
- package/dist/docx/file-commands.d.ts +5 -0
- package/dist/docx/format-dialogs.d.ts +6 -1
- package/dist/docx/insert-controller.d.ts +5 -0
- package/dist/docx/list-commands.d.ts +3 -1
- package/dist/docx/list-marker-display.d.ts +1 -1
- package/dist/docx/locales/en-app.d.ts +0 -1
- package/dist/docx/locales/en-ribbon.d.ts +51 -0
- package/dist/docx/locales/en.d.ts +51 -1
- package/dist/docx/localization-strings.d.ts +51 -1
- package/dist/docx/paragraph-styles.d.ts +1 -1
- package/dist/docx/print-picture.d.ts +4 -0
- package/dist/docx/protection-controls.d.ts +4 -0
- package/dist/docx/restrict-editing-pane.d.ts +14 -0
- package/dist/docx/ribbon-action.d.ts +4 -0
- package/dist/docx/ribbon-icons.d.ts +1 -0
- package/dist/docx/search-controller.d.ts +12 -5
- package/dist/docx/search-document.d.ts +32 -0
- package/dist/docx.js +1227 -390
- package/dist/export/pdf-embedded-font.d.ts +65 -0
- package/dist/export/pdf-fonts.d.ts +14 -0
- package/dist/export/pdf-vector.d.ts +84 -0
- package/dist/image-native-size.d.ts +43 -0
- package/dist/image-native-size.d.ts.map +1 -0
- package/dist/index.js +5 -5
- package/dist/picture-artistic-filters.d.ts +9 -0
- package/dist/picture-artistic-filters.d.ts.map +1 -0
- package/dist/picture-artistic-preview.d.ts +3 -0
- package/dist/picture-artistic-preview.d.ts.map +1 -0
- package/dist/picture-effects.d.ts +3 -1
- package/dist/picture-effects.d.ts.map +1 -0
- package/dist/picture-paint.d.ts +23 -0
- package/dist/picture-paint.d.ts.map +1 -0
- package/dist/picture-pixels.d.ts +11 -0
- package/dist/picture-pixels.d.ts.map +1 -0
- package/dist/picture-standard-filter.d.ts +6 -0
- package/dist/picture-standard-filter.d.ts.map +1 -0
- package/dist/picture-view.d.ts +10 -0
- package/dist/picture-view.d.ts.map +1 -0
- package/dist/pptx/ai/bridge-factory.d.ts +4 -1
- package/dist/pptx/ai/bridge-factory.d.ts.map +1 -1
- package/dist/pptx/ai/config.d.ts +1 -1
- package/dist/pptx/ai/config.d.ts.map +1 -1
- package/dist/pptx/ai/host.cjs +36 -36
- package/dist/pptx/ai/host.mjs +1 -1
- package/dist/pptx/ai/index.cjs +50 -43
- package/dist/pptx/ai/index.mjs +10 -3
- package/dist/pptx/ai/system-prompt.d.ts +1 -1
- package/dist/pptx/ai/system-prompt.d.ts.map +1 -1
- package/dist/pptx/ai/tool-summary.d.ts.map +1 -1
- package/dist/pptx/ai/tools/mcp-registry.d.ts.map +1 -1
- package/dist/pptx/{chart-3d-view-scene-HNL4NWJT.mjs → chart-3d-view-scene-BKNMGRGO.mjs} +3 -25
- package/dist/pptx/{chart-3d-view-scene-OPVBTZL5.cjs → chart-3d-view-scene-V55XPBBF.cjs} +39 -61
- package/dist/pptx/{chunk-KGDMMWIY.mjs → chunk-2AK5MS6H.mjs} +11 -0
- package/dist/pptx/{chunk-M55PNMFQ.cjs → chunk-4OKSYRYA.cjs} +11 -0
- package/dist/pptx/{chunk-CH4Z6H6C.mjs → chunk-4RSRCNRM.mjs} +1192 -382
- package/dist/pptx/{chunk-TDIJHLS5.cjs → chunk-6JJD3LFT.cjs} +1532 -715
- package/dist/pptx/{chunk-46HIE4IE.cjs → chunk-CRV7G4GC.cjs} +8 -0
- package/dist/pptx/{chunk-S3L5NNCK.cjs → chunk-FROIGMTI.cjs} +1 -1
- package/dist/pptx/{chunk-S5I64Y55.cjs → chunk-HIRBPTML.cjs} +12 -12
- package/dist/pptx/{chunk-D4LJJ7Z7.cjs → chunk-KJICUZXM.cjs} +171 -540
- package/dist/pptx/{chunk-7DT3UJQB.mjs → chunk-KNCCSPAV.mjs} +7 -3
- package/dist/pptx/{chunk-RZVEPTLN.mjs → chunk-QK6LJT3K.mjs} +140 -529
- package/dist/pptx/{chunk-ZS5EVODY.cjs → chunk-SI7GQYSL.cjs} +52 -48
- package/dist/pptx/{chunk-LCCRLB7Q.mjs → chunk-UHDWWRTX.mjs} +1 -1
- package/dist/pptx/{chunk-6MEBLCNK.mjs → chunk-WQI3NLMY.mjs} +8 -0
- package/dist/pptx/{chunk-SPOECCPV.mjs → chunk-WZHYA2B3.mjs} +1 -1
- package/dist/pptx/dom/elements/smartart.d.ts.map +1 -1
- package/dist/pptx/dom/index.cjs +427 -427
- package/dist/pptx/dom/index.mjs +10 -10
- package/dist/pptx/export/html2canvas-clone.cjs +6 -6
- package/dist/pptx/export/html2canvas-clone.mjs +1 -1
- package/dist/pptx/i18n/index.cjs +6 -6
- package/dist/pptx/i18n/index.mjs +1 -1
- package/dist/pptx/i18n/translations-en.d.ts.map +1 -1
- package/dist/pptx/index.cjs +3361 -3353
- package/dist/pptx/index.mjs +5 -5
- package/dist/pptx/render/chart-3d-projection.d.ts +5 -54
- package/dist/pptx/render/chart-3d-projection.d.ts.map +1 -1
- package/dist/pptx/render/chart-3d-shading.d.ts +7 -10
- package/dist/pptx/render/chart-3d-shading.d.ts.map +1 -1
- package/dist/pptx/render/chart-combo-stock.cjs +3 -3
- package/dist/pptx/render/chart-combo-stock.mjs +1 -1
- package/dist/pptx/render/chart-funnel-sunburst.d.ts +1 -1
- package/dist/pptx/render/chart-funnel-sunburst.d.ts.map +1 -1
- package/dist/pptx/render/chart-map-projection.d.ts +2 -37
- package/dist/pptx/render/chart-map-projection.d.ts.map +1 -1
- package/dist/pptx/render/chart-overlays.cjs +7 -7
- package/dist/pptx/render/chart-overlays.mjs +1 -1
- package/dist/pptx/render/chart-region-map-alias.d.ts +1 -11
- package/dist/pptx/render/chart-region-map-alias.d.ts.map +1 -1
- package/dist/pptx/render/chart-region-map-colors.d.ts +1 -3
- package/dist/pptx/render/chart-region-map-colors.d.ts.map +1 -1
- package/dist/pptx/render/chart-region-map-data.d.ts +2 -44
- package/dist/pptx/render/chart-region-map-data.d.ts.map +1 -1
- package/dist/pptx/render/chart-region-map-view.d.ts.map +1 -1
- package/dist/pptx/render/chart-surface-treemap.cjs +4 -4
- package/dist/pptx/render/chart-surface-treemap.mjs +1 -1
- package/dist/pptx/render/chart-view-model-types.d.ts +2 -0
- package/dist/pptx/render/chart-view-model-types.d.ts.map +1 -1
- package/dist/pptx/render/chart-view-model.cjs +44 -44
- package/dist/pptx/render/chart-view-model.mjs +1 -1
- package/dist/pptx/render/chart-waterfall-map.cjs +6 -6
- package/dist/pptx/render/chart-waterfall-map.mjs +1 -1
- package/dist/pptx/render/controller/custom-shows-controller.d.ts +93 -0
- package/dist/pptx/render/controller/custom-shows-controller.d.ts.map +1 -0
- package/dist/pptx/render/controller/index.d.ts +2 -0
- package/dist/pptx/render/controller/index.d.ts.map +1 -1
- package/dist/pptx/render/custom-shows.d.ts +10 -2
- package/dist/pptx/render/custom-shows.d.ts.map +1 -1
- package/dist/pptx/render/editor-key-target.d.ts.map +1 -1
- package/dist/pptx/render/image-effect-filter-values.d.ts +1 -10
- package/dist/pptx/render/image-effect-filter-values.d.ts.map +1 -1
- package/dist/pptx/render/image-effects.d.ts +1 -0
- package/dist/pptx/render/image-effects.d.ts.map +1 -1
- package/dist/pptx/render/image-native-size.d.ts +1 -42
- package/dist/pptx/render/image-native-size.d.ts.map +1 -1
- package/dist/pptx/render/image-tiling.d.ts.map +1 -1
- package/dist/pptx/render/index.d.ts +1 -1
- package/dist/pptx/render/index.d.ts.map +1 -1
- package/dist/pptx/render/render-cache.d.ts +1 -3
- package/dist/pptx/render/render-cache.d.ts.map +1 -1
- package/dist/pptx/render/smartart-drawing.d.ts +3 -0
- package/dist/pptx/render/smartart-drawing.d.ts.map +1 -1
- package/dist/pptx/render/smartart-picture-image.d.ts +9 -0
- package/dist/pptx/render/smartart-picture-image.d.ts.map +1 -0
- package/dist/pptx/render/smartart-reflow-to-shapes.d.ts.map +1 -1
- package/dist/pptx/{smartart-insert-preview-RQUFRLSV.mjs → smartart-insert-preview-JH5TXECK.mjs} +6 -6
- package/dist/pptx/{smartart-insert-preview-YKNB37GE.cjs → smartart-insert-preview-QWROEVZL.cjs} +7 -7
- package/dist/render-cache.d.ts +4 -0
- package/dist/render-cache.d.ts.map +1 -0
- package/dist/smartart/smartart-paint.d.ts +2 -1
- package/dist/smartart/smartart-picture.d.ts +4 -3
- package/dist/smartart/smartart-text-pane-tools.d.ts +0 -1
- package/dist/smartart.d.ts +3 -0
- package/dist/smartart.js +1 -1
- package/dist/teams.js +2 -2
- package/dist/theme-bridge.d.ts +0 -1
- package/dist/theme.d.ts +0 -1
- package/dist/touch-targets.d.ts +0 -1
- package/dist/visio/binding.d.ts +2 -1
- package/dist/visio/canvas-editing.d.ts +2 -0
- package/dist/visio/controller.d.ts +3 -0
- package/dist/visio/pdf-path.d.ts +37 -0
- package/dist/visio/pdf-svg-gradient.d.ts +23 -0
- package/dist/visio/pdf-svg-style.d.ts +20 -0
- package/dist/visio/pdf-svg-text.d.ts +8 -0
- package/dist/visio/pdf-svg.d.ts +22 -0
- package/dist/visio/ribbon-action.d.ts +47 -5
- package/dist/visio/ribbon-arrange.d.ts +9 -0
- package/dist/visio/ribbon-contextual-formats.d.ts +18 -0
- package/dist/visio/ribbon-org-chart.d.ts +7 -0
- package/dist/visio/ribbon-router.d.ts +18 -0
- package/dist/visio/ribbon-shape-format.d.ts +7 -0
- package/dist/visio/ribbon-size-fields.d.ts +5 -0
- package/dist/visio/ribbon-swimlane.d.ts +9 -0
- package/dist/visio/ribbon-themes.d.ts +13 -3
- package/dist/visio/ribbon.d.ts +5 -1
- package/dist/visio/shapes-files-ui.d.ts +1 -1
- package/dist/visio/template-thumbnails.d.ts +10 -0
- package/dist/visio/viewer-backstage.d.ts +9 -3
- package/dist/visio/viewer-chart-editor.d.ts +2 -1
- package/dist/visio/viewer-contextual-tabs.d.ts +21 -0
- package/dist/visio/viewer-diagram-parts.d.ts +9 -1
- package/dist/visio/viewer-element.d.ts +10 -0
- package/dist/visio/viewer-export.d.ts +1 -6
- package/dist/visio/viewer-file-commands.d.ts +6 -1
- package/dist/visio/viewer-guides.d.ts +8 -1
- package/dist/visio/viewer-inline-size.d.ts +15 -0
- package/dist/visio/viewer-insert-dialog.d.ts +1 -0
- package/dist/visio/viewer-new-drawing.d.ts +3 -2
- package/dist/visio/viewer-org-chart.d.ts +19 -0
- package/dist/visio/viewer-pdf-options.d.ts +26 -0
- package/dist/visio/viewer-pdf.d.ts +47 -0
- package/dist/visio/viewer-picture-format.d.ts +20 -0
- package/dist/visio/viewer-resize-handles.d.ts +13 -1
- package/dist/visio/viewer-swimlanes.d.ts +34 -0
- package/dist/visio.js +4079 -742
- package/dist/xlsx/dialogs/audit-dialogs.d.ts +9 -0
- package/dist/xlsx/dialogs/custom-autofilter.d.ts +12 -0
- package/dist/xlsx/dialogs/custom-lists.d.ts +6 -0
- package/dist/xlsx/dialogs/filter-dates.d.ts +4 -0
- package/dist/xlsx/dialogs/help-dialogs.d.ts +2 -2
- package/dist/xlsx/dialogs/sort-dialog.d.ts +3 -3
- package/dist/xlsx/dialogs/text-to-columns.d.ts +0 -7
- package/dist/xlsx/dialogs/top10-filter.d.ts +5 -0
- package/dist/xlsx/dialogs/watch-window.d.ts +4 -0
- package/dist/xlsx/grid/audit-layer.d.ts +3 -0
- package/dist/xlsx/grid/filter-buttons.d.ts +11 -0
- package/dist/xlsx/grid/filter-menu.d.ts +10 -0
- package/dist/xlsx/grid/filter-presets.d.ts +19 -0
- package/dist/xlsx/grid/grid-view.d.ts +23 -1
- package/dist/xlsx/grid/pane-chrome.d.ts +2 -0
- package/dist/xlsx/grid/split-bars.d.ts +2 -0
- package/dist/xlsx/grid/styles.d.ts +1 -1
- package/dist/xlsx/sheet-tabs/drag.d.ts +1 -2
- package/dist/xlsx.js +1991 -450
- package/package.json +2 -2
|
@@ -326,7 +326,6 @@ export declare const strings: {
|
|
|
326
326
|
readonly 'Save As': 'Save As';
|
|
327
327
|
readonly 'Save a copy of this document to your device.': 'Save a copy of this document to your device.';
|
|
328
328
|
readonly 'Word Document (*.docx)': 'Word Document (*.docx)';
|
|
329
|
-
readonly 'Word 97-2003 Document (*.doc)': 'Word 97-2003 Document (*.doc)';
|
|
330
329
|
readonly 'Paper size': 'Paper size';
|
|
331
330
|
readonly 'Printing uses the browser print dialog. Page breaks come from Print Layout, which approximates Word.': 'Printing uses the browser print dialog. Page breaks come from Print Layout, which approximates Word.';
|
|
332
331
|
readonly Export: 'Export';
|
|
@@ -819,6 +818,7 @@ export declare const strings: {
|
|
|
819
818
|
readonly 'Numbered list': 'Numbered list';
|
|
820
819
|
readonly 'Decrease list level': 'Decrease list level';
|
|
821
820
|
readonly 'Increase list level': 'Increase list level';
|
|
821
|
+
readonly 'Picture bullet...': 'Picture bullet...';
|
|
822
822
|
readonly 'Remove list': 'Remove list';
|
|
823
823
|
readonly 'Insert row above': 'Insert row above';
|
|
824
824
|
readonly 'Insert row below': 'Insert row below';
|
|
@@ -875,6 +875,29 @@ export declare const strings: {
|
|
|
875
875
|
readonly 'Close search': 'Close search';
|
|
876
876
|
readonly 'Search results': 'Search results';
|
|
877
877
|
readonly 'Enter text to search': 'Enter text to search';
|
|
878
|
+
readonly 'Invalid search pattern': 'Invalid search pattern';
|
|
879
|
+
readonly 'More >>': 'More >>';
|
|
880
|
+
readonly '<< Less': '<< Less';
|
|
881
|
+
readonly 'Search options': 'Search options';
|
|
882
|
+
readonly 'Find whole words only': 'Find whole words only';
|
|
883
|
+
readonly 'Use wildcards': 'Use wildcards';
|
|
884
|
+
readonly 'Match prefix': 'Match prefix';
|
|
885
|
+
readonly 'Match suffix': 'Match suffix';
|
|
886
|
+
readonly 'Ignore punctuation characters': 'Ignore punctuation characters';
|
|
887
|
+
readonly 'Ignore white-space characters': 'Ignore white-space characters';
|
|
888
|
+
readonly 'Special characters': 'Special characters';
|
|
889
|
+
readonly 'Paragraph Mark': 'Paragraph Mark';
|
|
890
|
+
readonly 'Tab Character': 'Tab Character';
|
|
891
|
+
readonly 'Any Character': 'Any Character';
|
|
892
|
+
readonly 'Any Digit': 'Any Digit';
|
|
893
|
+
readonly 'Any Letter': 'Any Letter';
|
|
894
|
+
readonly 'Caret Character': 'Caret Character';
|
|
895
|
+
readonly 'Manual Line Break': 'Manual Line Break';
|
|
896
|
+
readonly 'Page Break': 'Page Break';
|
|
897
|
+
readonly 'Optional Hyphen': 'Optional Hyphen';
|
|
898
|
+
readonly 'Nonbreaking Hyphen': 'Nonbreaking Hyphen';
|
|
899
|
+
readonly 'Nonbreaking Space': 'Nonbreaking Space';
|
|
900
|
+
readonly 'White Space': 'White Space';
|
|
878
901
|
readonly 'No matches': '0 matches';
|
|
879
902
|
readonly 'matches one': 'match';
|
|
880
903
|
readonly 'matches many': 'matches';
|
|
@@ -982,6 +1005,33 @@ export declare const strings: {
|
|
|
982
1005
|
readonly 'Finish & Merge': 'Finish & Merge';
|
|
983
1006
|
readonly Help: 'Help';
|
|
984
1007
|
readonly 'Not available in this editor': 'Not available in this editor';
|
|
1008
|
+
readonly Protect: 'Protect';
|
|
1009
|
+
readonly 'Restrict editing': 'Restrict editing';
|
|
1010
|
+
readonly 'Formatting restrictions': 'Formatting restrictions';
|
|
1011
|
+
readonly 'Limit formatting to a selection of styles': 'Limit formatting to a selection of styles';
|
|
1012
|
+
readonly 'Editing restrictions': 'Editing restrictions';
|
|
1013
|
+
readonly 'Allow only this type of editing in the document': 'Allow only this type of editing in the document';
|
|
1014
|
+
readonly 'No changes (Read only)': 'No changes (Read only)';
|
|
1015
|
+
readonly 'Filling in forms': 'Filling in forms';
|
|
1016
|
+
readonly 'Exceptions (optional)': 'Exceptions (optional)';
|
|
1017
|
+
readonly Everyone: 'Everyone';
|
|
1018
|
+
readonly 'Start enforcement': 'Start enforcement';
|
|
1019
|
+
readonly 'Yes, start enforcing protection': 'Yes, start enforcing protection';
|
|
1020
|
+
readonly 'Enter new password (optional)': 'Enter new password (optional)';
|
|
1021
|
+
readonly 'Reenter password to confirm': 'Reenter password to confirm';
|
|
1022
|
+
readonly Password: 'Password';
|
|
1023
|
+
readonly 'Stop protection': 'Stop protection';
|
|
1024
|
+
readonly 'The document is protected': 'The document is protected';
|
|
1025
|
+
readonly 'The passwords do not match': 'The passwords do not match';
|
|
1026
|
+
readonly 'Incorrect password': 'Incorrect password';
|
|
1027
|
+
readonly 'This protection uses a password that cannot be checked here': 'This protection uses a password that cannot be checked here';
|
|
1028
|
+
readonly 'Select text first': 'Select text first';
|
|
1029
|
+
readonly 'This exception continues into another paragraph; change it in Word': 'This exception continues into another paragraph; change it in Word';
|
|
1030
|
+
readonly 'Choose the type of editing to allow': 'Choose the type of editing to allow';
|
|
1031
|
+
readonly 'Editing is restricted by document protection': 'Editing is restricted by document protection';
|
|
1032
|
+
readonly 'Highlight the regions I can edit': 'Highlight the regions I can edit';
|
|
1033
|
+
readonly 'Find next region I can edit': 'Find next region I can edit';
|
|
1034
|
+
readonly 'There are no regions you can edit': 'There are no regions you can edit';
|
|
985
1035
|
readonly "(No style)": string;
|
|
986
1036
|
readonly "Add tab stop at (inches)": string;
|
|
987
1037
|
readonly "Aligned at (inches)": string;
|
|
@@ -2,5 +2,5 @@ import { Plugin } from 'prosemirror-state';
|
|
|
2
2
|
import { type DocumentModel } from 'ooxml-core/docx';
|
|
3
3
|
import type { ReviewDisplayMode } from './review-display.js';
|
|
4
4
|
/** Derived display formatting stays out of document attributes and collaboration steps. */
|
|
5
|
-
export declare function paragraphStylesPlugin(getModel: () => DocumentModel, getMode?: () => ReviewDisplayMode): Plugin<any>;
|
|
5
|
+
export declare function paragraphStylesPlugin(getModel: () => DocumentModel, getMode?: () => ReviewDisplayMode, pictureUrl?: (partName: string, contentType: string) => string | undefined): Plugin<any>;
|
|
6
6
|
export { resetStylePicker, syncStylePicker } from './styles-group.js';
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import type { DrawingFill } from 'ooxml-core/drawingml';
|
|
1
2
|
/** Resolves a package picture part to a displayable URL; undefined draws a placeholder box. */
|
|
2
3
|
export type PictureUrl = (partName: string, contentType: string) => string | undefined;
|
|
3
4
|
/**
|
|
@@ -8,6 +9,9 @@ export type PictureUrl = (partName: string, contentType: string) => string | und
|
|
|
8
9
|
*/
|
|
9
10
|
export declare function sanitizeChartSvg(svg: Element): void;
|
|
10
11
|
export declare function pictureElement(object: {
|
|
12
|
+
pictureFill?: Extract<DrawingFill, {
|
|
13
|
+
kind: 'picture';
|
|
14
|
+
}>;
|
|
11
15
|
partName: string;
|
|
12
16
|
contentType: string;
|
|
13
17
|
widthPx: number;
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
import type { DocumentProtection } from 'ooxml-core/docx';
|
|
2
|
+
import { type EditorLocale } from './localization.js';
|
|
3
|
+
/** Disables the commands the enforced protection forbids, and enables nothing it did not disable. */
|
|
4
|
+
export declare function syncProtectionControls(toolbar: HTMLElement, protection: DocumentProtection | undefined, locale: EditorLocale): void;
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { type DocumentProtection } from 'ooxml-core/docx';
|
|
2
|
+
import type { EditorView } from 'prosemirror-view';
|
|
3
|
+
import type { FormatDialog } from './font-dialog.js';
|
|
4
|
+
export interface RestrictEditingHost {
|
|
5
|
+
view(): EditorView | undefined;
|
|
6
|
+
protection(): DocumentProtection | undefined;
|
|
7
|
+
/** Stores the protection in the document (undefined stops it) and redraws what depends on it. */
|
|
8
|
+
apply(protection: DocumentProtection | undefined): void;
|
|
9
|
+
/** The review author, whose exceptions count. */
|
|
10
|
+
user(): string;
|
|
11
|
+
highlight(): boolean;
|
|
12
|
+
setHighlight(on: boolean): void;
|
|
13
|
+
}
|
|
14
|
+
export declare function createRestrictEditingPane(host: RestrictEditingHost): FormatDialog;
|
|
@@ -171,6 +171,10 @@ export type RibbonAction = {
|
|
|
171
171
|
key: 'toggle' | 'add' | 'delete' | 'previous' | 'next';
|
|
172
172
|
} | {
|
|
173
173
|
type: 'insertPicture';
|
|
174
|
+
}
|
|
175
|
+
/** Bullets > Picture bullet...: choose an image file and start a list that draws it. */
|
|
176
|
+
| {
|
|
177
|
+
type: 'pictureBullet';
|
|
174
178
|
} | {
|
|
175
179
|
type: 'shapePicker';
|
|
176
180
|
} | {
|
|
@@ -58,6 +58,7 @@ declare const paths: {
|
|
|
58
58
|
readonly firstPage: 'M6 3h9l3 3v15H6z M9 8h6 M9 12h6 M9 16h3';
|
|
59
59
|
readonly oddEven: 'M3 5h8v14H3z M13 5h8v14h-8z M6 9h2 M16 9h2';
|
|
60
60
|
readonly track: 'M4 20l4-1 11-11-3-3L5 16z M14 20h7';
|
|
61
|
+
readonly protect: 'M7 11V8a5 5 0 0 1 10 0v3 M5 11h14v10H5z M12 15v2';
|
|
61
62
|
readonly previous: 'M6 14l6-6 6 6';
|
|
62
63
|
readonly next: 'M6 10l6 6 6-6';
|
|
63
64
|
readonly accept: 'M5 12.5l4.5 4.5L19 7';
|
|
@@ -1,5 +1,6 @@
|
|
|
1
|
-
import { type Node as ProseMirrorNode } from 'prosemirror-model';
|
|
2
1
|
import type { EditorView } from 'prosemirror-view';
|
|
2
|
+
import { type FindOptions } from 'ooxml-core/docx/ui';
|
|
3
|
+
import { findDocumentMatches } from './search-document.js';
|
|
3
4
|
export interface SearchMatch {
|
|
4
5
|
from: number;
|
|
5
6
|
to: number;
|
|
@@ -9,24 +10,30 @@ export interface SearchStatus {
|
|
|
9
10
|
count: number;
|
|
10
11
|
active: number;
|
|
11
12
|
readOnly: boolean;
|
|
13
|
+
/** The query is a wildcard pattern Word would reject; nothing matches it. */
|
|
14
|
+
invalid: boolean;
|
|
12
15
|
}
|
|
16
|
+
/** The Find options of the dialog: Match case, whole words, wildcards and the rest of More >>. */
|
|
17
|
+
export type SearchOptions = FindOptions;
|
|
13
18
|
export declare class SearchController {
|
|
14
19
|
private readonly getView;
|
|
15
20
|
private query;
|
|
16
|
-
private
|
|
21
|
+
private options;
|
|
17
22
|
private matches;
|
|
18
23
|
private activeIndex;
|
|
24
|
+
private invalid;
|
|
19
25
|
constructor(getView: () => EditorView | undefined);
|
|
20
26
|
get status(): SearchStatus;
|
|
21
|
-
search(query: string,
|
|
27
|
+
search(query: string, options?: SearchOptions): SearchStatus;
|
|
22
28
|
refresh(): SearchStatus;
|
|
23
29
|
findNext(): SearchMatch | null;
|
|
24
30
|
findPrevious(): SearchMatch | null;
|
|
25
31
|
replaceOne(replacement: string): boolean;
|
|
26
32
|
replaceAll(replacement: string): number;
|
|
27
|
-
private currentMatches;
|
|
28
33
|
private indexAtSelection;
|
|
29
34
|
private select;
|
|
35
|
+
/** Replaces the matches (in document order) in one undoable step; false if the replacement is invalid. */
|
|
30
36
|
private replace;
|
|
31
37
|
}
|
|
32
|
-
|
|
38
|
+
/** Every match of a query in the document, as ranges (Find without its replacement details). */
|
|
39
|
+
export declare function findTextMatches(doc: Parameters<typeof findDocumentMatches>[0], query: string, options?: SearchOptions): SearchMatch[];
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
import { type Node as ProseMirrorNode } from 'prosemirror-model';
|
|
2
|
+
import type { EditorState, Transaction } from 'prosemirror-state';
|
|
3
|
+
import { type FindOptions, type ReplacementPart } from 'ooxml-core/docx/ui';
|
|
4
|
+
export interface DocumentMatch {
|
|
5
|
+
readonly from: number;
|
|
6
|
+
readonly to: number;
|
|
7
|
+
readonly text: string;
|
|
8
|
+
readonly groups: readonly string[];
|
|
9
|
+
}
|
|
10
|
+
export interface ReplacementTarget {
|
|
11
|
+
readonly from: number;
|
|
12
|
+
readonly to: number;
|
|
13
|
+
readonly parts: readonly ReplacementPart[];
|
|
14
|
+
}
|
|
15
|
+
interface FindableText {
|
|
16
|
+
readonly text: string;
|
|
17
|
+
/** The document position where each character of `text` starts. */
|
|
18
|
+
readonly from: readonly number[];
|
|
19
|
+
/** The document position where each character of `text` ends. */
|
|
20
|
+
readonly to: readonly number[];
|
|
21
|
+
}
|
|
22
|
+
/** The document's text with each character's position; objects and breaks stand for their codes. */
|
|
23
|
+
export declare function findableText(doc: ProseMirrorNode): FindableText;
|
|
24
|
+
/** Every match of the query in the document, in document order. */
|
|
25
|
+
export declare function findDocumentMatches(doc: ProseMirrorNode, query: string, options?: FindOptions): DocumentMatch[];
|
|
26
|
+
/**
|
|
27
|
+
* One transaction that replaces every target. Targets are applied last first so the earlier
|
|
28
|
+
* positions still hold. A replacement is spliced as an open slice of paragraphs, so a match that
|
|
29
|
+
* spans paragraph marks joins them and a `^p` in the replacement splits them.
|
|
30
|
+
*/
|
|
31
|
+
export declare function replaceTargets(state: EditorState, targets: readonly ReplacementTarget[]): Transaction;
|
|
32
|
+
export {};
|