@globalpayments/vega 2.91.0 → 2.93.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/dist/cjs/{app-globals-7bb10088.js → app-globals-f7ad9275.js} +17 -10
- package/dist/cjs/{child-nodes-event-prevent-slimmer-76d19d56.js → child-nodes-event-prevent-slimmer-e67ee84c.js} +2 -2
- package/dist/cjs/{code-block-c1039791.js → code-block-2f3d0f38.js} +64 -11
- package/dist/cjs/{component-value-history-controller-slimmer.abstract-1d36641d.js → component-value-history-controller-slimmer.abstract-31d2c7aa.js} +72 -39
- package/dist/cjs/{content-state-a6105949.js → content-state-13daf87a.js} +91 -8
- package/dist/cjs/copy-d021c780.js +7 -0
- package/dist/cjs/{date-required-rule-c4997459.js → date-required-rule-e65ddd7d.js} +1 -1
- package/dist/cjs/{design-token-f65eab4a.js → design-token-47393cbb.js} +3 -3
- package/dist/cjs/{element-appender-slimmer-316668d0.js → element-appender-slimmer-29c4ac60.js} +18 -9
- package/dist/cjs/{event-emit-slimmer-5bab10c2.js → event-emit-slimmer-d234a619.js} +1 -1
- package/dist/cjs/{file-uploader-required-rule-cc51d4ab.js → file-uploader-required-rule-5520bbec.js} +1 -1
- package/dist/cjs/{form-field-controller-slimmer-b0c35330.js → form-field-controller-slimmer-3bfcf88c.js} +1 -1
- package/dist/cjs/{image-annotation-action-e4596726.js → image-annotation-action-c2b163bb.js} +3 -3
- package/dist/cjs/image-extension-4e99b620.js +39 -0
- package/dist/cjs/index-58ea899e.js +4 -0
- package/dist/cjs/index.cjs.js +30 -22
- package/dist/cjs/{inject-keyboard-manager-1f5bbb19.js → inject-keyboard-manager-4b2ebbe4.js} +1 -1
- package/dist/cjs/{internal-calendar-period-factory-9c66cf36.js → internal-calendar-period-factory-7a0ecdb1.js} +1 -1
- package/dist/cjs/{internal-translation-controller-5905469e.js → internal-translation-controller-31f2b057.js} +18 -0
- package/dist/cjs/{internal-vega-event-manager-7196a847.js → internal-vega-event-manager-13c4012b.js} +2 -1
- package/dist/cjs/{keyboard-manager-61e8ce38.js → keyboard-manager-c78b46bd.js} +1 -1
- package/dist/cjs/{keyboard-manager-slimmer-079a7e87.js → keyboard-manager-slimmer-d350c931.js} +1 -1
- package/dist/cjs/{link-extension-a7ac28f3.js → link-extension-455c02b3.js} +3 -3
- package/dist/cjs/loader.cjs.js +17 -15
- package/dist/cjs/{month-view-generator-48215a05.js → month-view-generator-006562dc.js} +1 -1
- package/dist/cjs/{public-rules-66540638.js → public-rules-c59eba88.js} +10 -10
- package/dist/cjs/{range-dea19a90.js → range-bf80fa40.js} +25 -3
- package/dist/cjs/{replace-selected-text-action-6d1ebbf9.js → replace-selected-text-action-a80f5a6a.js} +1 -1
- package/dist/cjs/{required-field-rule-b12a29e1.js → required-field-rule-400690c3.js} +1 -1
- package/dist/cjs/{responsive-format-facade-10ff730e.js → responsive-format-facade-1af54330.js} +2 -2
- package/dist/cjs/{rich-text-editor-required-rule-63492ca3.js → rich-text-editor-required-rule-1085c71a.js} +1 -1
- package/dist/cjs/{split-cell-operation-30e5dd4a.js → split-cell-operation-2fa5c9e4.js} +3 -3
- package/dist/cjs/{state-border-formatter-e7779964.js → state-border-formatter-501f6645.js} +1 -1
- package/dist/cjs/{string-format-strategy.abstract-a22f0cb1.js → string-format-strategy.abstract-a02bf002.js} +1 -1
- package/dist/cjs/{string-input-formatter-slimmer-8179eb40.js → string-input-formatter-slimmer-9cca6151.js} +1 -1
- package/dist/cjs/{string-mask-strategy-8b9bb0c1.js → string-mask-strategy-4c174ebf.js} +2 -2
- package/dist/cjs/{style-formatter-380b9a86.js → style-formatter-2c749500.js} +2 -2
- package/dist/cjs/{time-required-rule-080d975b.js → time-required-rule-04994a5e.js} +1 -1
- package/dist/cjs/{token-extension-619379a3.js → token-extension-d217914d.js} +3622 -742
- package/dist/cjs/{translation-slimmer-2af6f141.js → translation-slimmer-7fb6e94c.js} +1 -1
- package/dist/cjs/{type-guard-0171e779.js → type-guard-1c3770d4.js} +1 -1
- package/dist/cjs/{valid-credit-card-number-rule-fdfca83e.js → valid-credit-card-number-rule-f719a8c6.js} +1 -1
- package/dist/cjs/vega-accordion.cjs.entry.js +21 -13
- package/dist/cjs/vega-app-footer.cjs.entry.js +3 -3
- package/dist/cjs/vega-app-header-button.cjs.entry.js +10 -10
- package/dist/cjs/vega-banner.cjs.entry.js +6 -9
- package/dist/cjs/vega-box.cjs.entry.js +7 -7
- package/dist/cjs/vega-breadcrumb.cjs.entry.js +5 -5
- package/dist/cjs/vega-button-circle.cjs.entry.js +10 -10
- package/dist/cjs/vega-button-group_2.cjs.entry.js +5 -5
- package/dist/cjs/vega-button-link.cjs.entry.js +5 -5
- package/dist/cjs/vega-button.cjs.entry.js +8 -8
- package/dist/cjs/vega-calendar_5.cjs.entry.js +12 -12
- package/dist/cjs/vega-card.cjs.entry.js +6 -6
- package/dist/cjs/vega-carousel.cjs.entry.js +7 -7
- package/dist/cjs/vega-checkbox_2.cjs.entry.js +8 -8
- package/dist/cjs/vega-chip.cjs.entry.js +10 -10
- package/dist/cjs/vega-code-block.cjs.entry.js +15 -18
- package/dist/cjs/vega-color-picker.cjs.entry.js +7 -7
- package/dist/cjs/vega-color-swatch-picker.cjs.entry.js +9 -9
- package/dist/cjs/vega-color-swatch.cjs.entry.js +5 -5
- package/dist/cjs/vega-combo-box.cjs.entry.js +21 -15
- package/dist/cjs/vega-date-picker_2.cjs.entry.js +18 -18
- package/dist/cjs/vega-dialog_2.cjs.entry.js +21 -10
- package/dist/cjs/vega-divider.cjs.entry.js +6 -6
- package/dist/cjs/vega-dropdown_5.cjs.entry.js +694 -196
- package/dist/cjs/vega-env-manager-23b8b23c.js +2 -2
- package/dist/cjs/{vega-event-id-df22d80e.js → vega-event-id-58afed7a.js} +2 -0
- package/dist/cjs/vega-field-label.cjs.entry.js +16 -12
- package/dist/cjs/vega-file-uploader.cjs.entry.js +9 -9
- package/dist/cjs/vega-flag-icon.cjs.entry.js +6 -6
- package/dist/cjs/vega-flex.cjs.entry.js +7 -7
- package/dist/cjs/vega-font.cjs.entry.js +6 -6
- package/dist/cjs/vega-form.cjs.entry.js +8 -8
- package/dist/cjs/vega-grid.cjs.entry.js +6 -6
- package/dist/cjs/vega-icon.cjs.entry.js +6 -6
- package/dist/cjs/vega-image-uploader.cjs.entry.js +11 -11
- package/dist/cjs/vega-input-credit-card.cjs.entry.js +12 -12
- package/dist/cjs/vega-input-numeric.cjs.entry.js +11 -11
- package/dist/cjs/vega-input-passcode.cjs.entry.js +11 -11
- package/dist/cjs/vega-input-phone-number.cjs.entry.js +9 -9
- package/dist/cjs/vega-input-range.cjs.entry.js +8 -8
- package/dist/cjs/vega-input-select.cjs.entry.js +11 -11
- package/dist/cjs/vega-input.cjs.entry.js +12 -12
- package/dist/cjs/vega-item-toggle.cjs.entry.js +3 -3
- package/dist/cjs/vega-left-nav_5.cjs.entry.js +11 -11
- package/dist/cjs/vega-loader-wrapper_2.cjs.entry.js +4 -4
- package/dist/cjs/vega-page-notification_2.cjs.entry.js +1 -1
- package/dist/cjs/vega-pagination-page-selector-mobile.cjs.entry.js +4 -4
- package/dist/cjs/vega-pagination-page-size-selector-mobile.cjs.entry.js +3 -3
- package/dist/cjs/vega-pagination.cjs.entry.js +9 -9
- package/dist/cjs/vega-popover_2.cjs.entry.js +12 -12
- package/dist/cjs/vega-progress-tracker_2.cjs.entry.js +7 -7
- package/dist/cjs/vega-radio_2.cjs.entry.js +11 -11
- package/dist/cjs/vega-rich-text-content.cjs.entry.js +7 -7
- package/dist/cjs/vega-rich-text-editor_4.cjs.entry.js +677 -95
- package/dist/cjs/vega-rich-text-find-replace-panel.cjs.entry.js +233 -0
- package/dist/cjs/vega-rich-text-special-characters-panel.cjs.entry.js +8 -8
- package/dist/cjs/vega-rich-text-table-properties_3.cjs.entry.js +13 -13
- package/dist/cjs/vega-segment-control.cjs.entry.js +3 -3
- package/dist/cjs/vega-selection-chip_2.cjs.entry.js +10 -10
- package/dist/cjs/vega-selection-tile_2.cjs.entry.js +8 -8
- package/dist/cjs/vega-sidenav_3.cjs.entry.js +7 -7
- package/dist/cjs/vega-signature-capture.cjs.entry.js +12 -12
- package/dist/cjs/vega-stepper.cjs.entry.js +7 -7
- package/dist/cjs/vega-tab-group_2.cjs.entry.js +5 -5
- package/dist/cjs/vega-table_11.cjs.entry.js +912 -429
- package/dist/cjs/vega-textarea.cjs.entry.js +9 -11
- package/dist/cjs/vega-time-picker_2.cjs.entry.js +35 -15
- package/dist/cjs/vega-toggle-switch.cjs.entry.js +5 -5
- package/dist/cjs/vega-tooltip_2.cjs.entry.js +7 -7
- package/dist/cjs/vega.cjs.js +17 -15
- package/dist/cjs/xmark-large-faae5a80.js +7 -0
- package/dist/collection/collection-manifest.json +6 -0
- package/dist/collection/components/vega-accordion/slimmers/vega-accordion-renderer.js +11 -3
- package/dist/collection/components/vega-box/vega-box.js +3 -3
- package/dist/collection/components/vega-code-block/slimmers/renderers/vega-code-block-copy-button-renderer.js +1 -1
- package/dist/collection/components/vega-combo-box/slimmers/renderers/vega-combo-box-dropdown-renderer.js +4 -1
- package/dist/collection/components/vega-combo-box/vega-combo-box.js +7 -1
- package/dist/collection/components/vega-dialog/vega-dialog.js +1 -1
- package/dist/collection/components/vega-dropdown/constants.js +1 -0
- package/dist/collection/components/vega-dropdown/slimmers/controllers/vega-dropdown-appender-controller.js +9 -0
- package/dist/collection/components/vega-dropdown/slimmers/controllers/vega-dropdown-children-controller.js +97 -4
- package/dist/collection/components/vega-dropdown/slimmers/controllers/vega-dropdown-select-all-controller.js +219 -0
- package/dist/collection/components/vega-dropdown/slimmers/controllers/vega-dropdown-selected-controller.js +78 -13
- package/dist/collection/components/vega-dropdown/slimmers/controllers/vega-dropdown-source-controller.js +13 -1
- package/dist/collection/components/vega-dropdown/slimmers/renderers/vega-dropdown-list-renderer.js +7 -0
- package/dist/collection/components/vega-dropdown/vega-dropdown-item/slimmers/controllers/vega-dropdown-item-state-controller.js +52 -1
- package/dist/collection/components/vega-dropdown/vega-dropdown-item/slimmers/renderers/vega-dropdown-item-renderer.js +4 -1
- package/dist/collection/components/vega-dropdown/vega-dropdown-item/vega-dropdown-item.js +5 -0
- package/dist/collection/components/vega-dropdown/vega-dropdown.js +126 -1
- package/dist/collection/components/vega-field-label/slimmers/renderers/vega-field-label-suffix-element-renderer.js +5 -4
- package/dist/collection/components/vega-field-label/vega-field-label.css +20 -0
- package/dist/collection/components/vega-field-label/vega-field-label.js +7 -4
- package/dist/collection/components/vega-hint/vega-hint.js +1 -1
- package/dist/collection/components/vega-input/vega-input.css +1 -0
- package/dist/collection/components/vega-input/vega-input.js +1 -1
- package/dist/collection/components/vega-input-select/vega-input-select.js +1 -1
- package/dist/collection/components/vega-modal/slimmers/renderers/vega-modal-renderer.js +4 -1
- package/dist/collection/components/vega-modal/vega-modal.css +0 -1
- package/dist/collection/components/vega-modal/vega-modal.js +38 -0
- package/dist/collection/components/vega-rich-text-editor/assets/cut.js +3 -0
- package/dist/collection/components/vega-rich-text-editor/assets/redo.js +1 -1
- package/dist/collection/components/vega-rich-text-editor/assets/undo.js +1 -1
- package/dist/collection/components/vega-rich-text-editor/dto/action-handle-strategies/modify-content-strategies/block-delete-text-or-decorator-node-strategy.js +16 -1
- package/dist/collection/components/vega-rich-text-editor/dto/action-handle-strategies/modify-content-strategies/block-insert-line-break-strategy.js +11 -5
- package/dist/collection/components/vega-rich-text-editor/dto/action-handle-strategies/modify-content-strategies/block-merge-nodes-strategy.js +25 -0
- package/dist/collection/components/vega-rich-text-editor/dto/action-handle-strategies/modify-content-strategies/block-split-with-text-node-strategy.js +9 -4
- package/dist/collection/components/vega-rich-text-editor/dto/action-handle-strategies/modify-content-strategies/delete-selected-content-strategy.js +16 -0
- package/dist/collection/components/vega-rich-text-editor/dto/action-handle-strategies/modify-content-strategies/paste-content-strategy.js +61 -5
- package/dist/collection/components/vega-rich-text-editor/dto/actions/delete-selected-content-action.js +17 -0
- package/dist/collection/components/vega-rich-text-editor/dto/actions/modify-content-action.abstract.js +1 -0
- package/dist/collection/components/vega-rich-text-editor/dto/actions/paste-content-action.js +1 -0
- package/dist/collection/components/vega-rich-text-editor/dto/content-state.js +2 -0
- package/dist/collection/components/vega-rich-text-editor/dto/nodes/text-node.js +6 -1
- package/dist/collection/components/vega-rich-text-editor/dto/range.js +24 -2
- package/dist/collection/components/vega-rich-text-editor/extensions/blockquote/action-handler-interceptors/blockquote-exit-on-enter-interceptor.js +61 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/blockquote/action-handler-strategies/block-transform-to-blockquote-strategy.js +40 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/blockquote/action-handler-strategies/remove-blockquote-strategy.js +20 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/blockquote/actions/remove-blockquote-action.js +17 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/blockquote/actions/transform-to-blockquote-action.js +19 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/blockquote/assets/quote-left.js +4 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/blockquote/blockquote-extension.js +47 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/blockquote/dto/blockquote-annotation.js +76 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/blockquote/dto/rte-blockquote-block.js +70 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/blockquote/element-to-dto-strategies/blockquote-to-blockquote-block-strategy.js +53 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/blockquote/filter-styles-strategies/blockquote-block/blockquote-filter-styles-strategy.js +41 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/blockquote/renderers/blockquote-block-renderer.js +21 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/blockquote/renderers/blockquote-toolbar-button-renderer.js +260 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/copy/action-handler-strategies/copy-selected-content-strategy.js +226 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/copy/actions/copy-selected-content-action.js +21 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/copy/copy-extension.js +20 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/copy/copy-toolbar-button-renderer.js +58 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/cut/cut-extension.js +15 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/cut/cut-toolbar-button-renderer.js +44 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/find-replace/assets/find-and-replace.js +3 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/find-replace/find-replace-extension.js +18 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/find-replace/slimmer/controllers/find-controller.js +105 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/find-replace/slimmer/controllers/find-replace-controller.abstract.js +68 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/find-replace/slimmer/controllers/helper/block-search-strategies/block-search-strategy.abstract.js +8 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/find-replace/slimmer/controllers/helper/block-search-strategies/code-block-search-strategy.js +19 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/find-replace/slimmer/controllers/helper/block-search-strategies/container-block-search-strategy.js +23 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/find-replace/slimmer/controllers/helper/block-search-strategies/list-item-block-search-strategy.js +30 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/find-replace/slimmer/controllers/helper/block-search-strategies/text-block-search-strategy.js +20 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/find-replace/slimmer/controllers/helper/find-replace-highlight-manager.js +266 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/find-replace/slimmer/controllers/helper/find-replace-state.js +346 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/find-replace/slimmer/controllers/replace-controller.js +113 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/find-replace/slimmer/renderers/find-replace-toolbar-button-renderer.js +194 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/find-replace/vega-rich-text-find-replace-panel/slimmers/renderers/find-replace-panel-renderer.js +153 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/find-replace/vega-rich-text-find-replace-panel/vega-rich-text-find-replace-panel.css +50 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/find-replace/vega-rich-text-find-replace-panel/vega-rich-text-find-replace-panel.js +156 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/functions/function-extension.js +2 -1
- package/dist/collection/components/vega-rich-text-editor/extensions/horizontal-line/horizontal-line-extension.js +2 -1
- package/dist/collection/components/vega-rich-text-editor/extensions/image/image-extension.js +34 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/image/type.js +1 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/languages/language-extension.js +2 -1
- package/dist/collection/components/vega-rich-text-editor/extensions/line-height/line-height-extension.js +2 -1
- package/dist/collection/components/vega-rich-text-editor/extensions/paste/assets/paste.js +3 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/paste/paste-chooser-ui.js +144 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/paste/paste-constants.js +6 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/paste/paste-extension.js +442 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/special-characters/special-characters-extension.js +2 -1
- package/dist/collection/components/vega-rich-text-editor/extensions/table/renderers/table-renderer.js +1 -1
- package/dist/collection/components/vega-rich-text-editor/extensions/table/table-extension.js +6 -4
- package/dist/collection/components/vega-rich-text-editor/extensions/table/vega-rich-text-table-selection-widget/slimmers/controllers/selection-widget-keyboard-controller.js +1 -1
- package/dist/collection/components/vega-rich-text-editor/extensions/tokens/token-extension.js +2 -1
- package/dist/collection/components/vega-rich-text-editor/helpers/utils.js +14 -0
- package/dist/collection/components/vega-rich-text-editor/public-api.js +7 -0
- package/dist/collection/components/vega-rich-text-editor/slimmers/controllers/helper/input-event-handler/abstract-delete-content-handler.js +133 -0
- package/dist/collection/components/vega-rich-text-editor/slimmers/controllers/helper/input-event-handler/backward-delete-content-handler.js +35 -0
- package/dist/collection/components/vega-rich-text-editor/slimmers/controllers/helper/input-event-handler/base-handler.js +1 -1
- package/dist/collection/components/vega-rich-text-editor/slimmers/controllers/helper/input-event-handler/forward-delete-content-handler.js +93 -0
- package/dist/collection/components/vega-rich-text-editor/slimmers/controllers/helper/input-event-handler/insert-line-break-handler.js +1 -1
- package/dist/collection/components/vega-rich-text-editor/slimmers/controllers/helper/input-event-handler/insert-paste-handler.js +385 -25
- package/dist/collection/components/vega-rich-text-editor/slimmers/controllers/selection-controller.js +69 -36
- package/dist/collection/components/vega-rich-text-editor/slimmers/controllers/user-input-controller.js +9 -3
- package/dist/collection/components/vega-rich-text-editor/slimmers/renderers/tools/image-toolbar-button-slimmer.js +59 -14
- package/dist/collection/components/vega-rich-text-editor/vega-rich-text-editor-toolbar-button/slimmers/renderers/vega-rich-text-editor-toolbar-button-renderer.js +6 -1
- package/dist/collection/components/vega-rich-text-editor/vega-rich-text-editor-toolbar-button/vega-rich-text-editor-toolbar-button.js +28 -1
- package/dist/collection/components/vega-rich-text-editor/vega-rich-text-editor.js +1 -1
- package/dist/collection/components/vega-rich-text-editor/vega-rich-text-image-editor/vega-rich-text-image-editor.js +1 -1
- package/dist/collection/components/vega-rich-text-editor/vega-rich-text-link-editor/vega-rich-text-link-editor.js +1 -1
- package/dist/collection/components/vega-table/slimmers/controllers/dto/column-render-input-model.js +32 -0
- package/dist/collection/components/vega-table/slimmers/controllers/vega-table-body-col-span-controller.js +77 -0
- package/dist/collection/components/vega-table/slimmers/renderers/vega-table-body-col-span-resolver.js +121 -0
- package/dist/collection/components/vega-table/slimmers/renderers/vega-table-cell-renderer.js +39 -14
- package/dist/collection/components/vega-table/slimmers/renderers/vega-table-pinned-renderer.js +207 -7
- package/dist/collection/components/vega-table/slimmers/renderers/vega-table-row-renderer.js +16 -3
- package/dist/collection/components/vega-table/vega-table-cell/vega-table-cell.js +24 -4
- package/dist/collection/components/vega-table/vega-table-expand-row/slimmers/controllers/vega-table-expand-row-col-span-controller.js +11 -2
- package/dist/collection/components/vega-table/vega-table-foot-cell/slimmers/renderers/vega-table-foot-cell-renderer.js +5 -1
- package/dist/collection/components/vega-table/vega-table-foot-cell/vega-table-foot-cell.js +22 -1
- package/dist/collection/components/vega-table/vega-table.css +5 -0
- package/dist/collection/components/vega-table/vega-table.js +5 -0
- package/dist/collection/components/vega-text/vega-text.js +1 -1
- package/dist/collection/components/vega-textarea/vega-textarea.js +2 -4
- package/dist/collection/components/vega-time-picker/slimmers/controllers/vega-time-picker-range-dropdown-controller.js +4 -0
- package/dist/collection/components/vega-time-picker/slimmers/controllers/vega-time-picker-single-dropdown-controller.js +4 -0
- package/dist/collection/components/vega-time-picker/vega-time-picker.js +39 -0
- package/dist/collection/constants/ui.js +1 -0
- package/dist/collection/global/scripts/before-vega-load.js +12 -0
- package/dist/collection/helpers/event-manager/event-id/component-event-id-map.js +2 -1
- package/dist/collection/helpers/event-manager/event-id/vega-event-id.js +1 -0
- package/dist/collection/helpers/slimmers/element-appender/element-appender-slimmer.js +11 -4
- package/dist/collection/helpers/translation/locales/en.js +18 -0
- package/dist/collection/helpers/ui/element-appender.js +5 -2
- package/dist/esm/{app-globals-6041f52f.js → app-globals-9950d055.js} +17 -10
- package/dist/esm/{aria-dialog-focusable-trap-slimmer-1332c071.js → aria-dialog-focusable-trap-slimmer-9eae86c6.js} +1 -1
- package/dist/esm/{child-nodes-event-prevent-slimmer-50022584.js → child-nodes-event-prevent-slimmer-96c14f5a.js} +2 -2
- package/dist/esm/{code-block-37294847.js → code-block-ae2337c2.js} +65 -13
- package/dist/esm/{component-value-history-controller-slimmer.abstract-45ccddc9.js → component-value-history-controller-slimmer.abstract-b1ee1b8e.js} +73 -40
- package/dist/esm/{content-state-67950b80.js → content-state-c3b85ae6.js} +92 -9
- package/dist/esm/copy-54e45e2d.js +5 -0
- package/dist/esm/{date-required-rule-958cf380.js → date-required-rule-e06115f8.js} +1 -1
- package/dist/esm/{design-token-e7e78f18.js → design-token-4e682056.js} +3 -3
- package/dist/esm/{element-appender-slimmer-ebda526d.js → element-appender-slimmer-a4485ef6.js} +19 -10
- package/dist/esm/{event-emit-slimmer-b94cec83.js → event-emit-slimmer-db4a82e0.js} +1 -1
- package/dist/esm/{file-uploader-required-rule-82188a61.js → file-uploader-required-rule-96952e1a.js} +1 -1
- package/dist/esm/{form-field-controller-slimmer-0a2ba886.js → form-field-controller-slimmer-a1c7b28c.js} +3 -3
- package/dist/esm/{image-annotation-action-7f7a5678.js → image-annotation-action-4c77d314.js} +3 -3
- package/dist/esm/image-extension-7108c27d.js +37 -0
- package/dist/esm/index-090d31ca.js +4 -0
- package/dist/esm/index.js +24 -23
- package/dist/esm/{inject-keyboard-manager-2b19c121.js → inject-keyboard-manager-e8ddb78d.js} +1 -1
- package/dist/esm/{internal-calendar-period-factory-fff8aaee.js → internal-calendar-period-factory-6f19d767.js} +1 -1
- package/dist/esm/{internal-translation-controller-aa09ca87.js → internal-translation-controller-09b8bd13.js} +18 -0
- package/dist/esm/{internal-vega-event-manager-956cf128.js → internal-vega-event-manager-48690e5b.js} +2 -1
- package/dist/esm/{keyboard-manager-3e5b157f.js → keyboard-manager-ec18721b.js} +1 -1
- package/dist/esm/{keyboard-manager-slimmer-ba5cc767.js → keyboard-manager-slimmer-531ddb0e.js} +1 -1
- package/dist/esm/{link-extension-afb404fb.js → link-extension-74eaa826.js} +3 -3
- package/dist/esm/loader.js +18 -16
- package/dist/esm/{month-view-generator-7a0c869c.js → month-view-generator-afd78ff8.js} +1 -1
- package/dist/esm/{public-rules-f64b0b78.js → public-rules-5fce32a5.js} +11 -11
- package/dist/esm/{range-4d09a305.js → range-8f877dbf.js} +25 -3
- package/dist/esm/{replace-selected-text-action-12bc8b82.js → replace-selected-text-action-c9278a0f.js} +1 -1
- package/dist/esm/{required-field-rule-a4634842.js → required-field-rule-897fe8d1.js} +1 -1
- package/dist/esm/{responsive-format-facade-844c5e09.js → responsive-format-facade-299e6304.js} +2 -2
- package/dist/esm/{rich-text-editor-required-rule-d62d418e.js → rich-text-editor-required-rule-3047bab0.js} +1 -1
- package/dist/esm/{split-cell-operation-c515669e.js → split-cell-operation-98d58410.js} +3 -3
- package/dist/esm/{state-border-formatter-f53847a5.js → state-border-formatter-da52b626.js} +1 -1
- package/dist/esm/{string-format-strategy.abstract-a0327405.js → string-format-strategy.abstract-a45b5ff7.js} +1 -1
- package/dist/esm/{string-input-formatter-slimmer-12de4a25.js → string-input-formatter-slimmer-4a032fed.js} +3 -3
- package/dist/esm/{string-mask-strategy-3bb03155.js → string-mask-strategy-37e53e48.js} +2 -2
- package/dist/esm/{style-formatter-df7bf8ec.js → style-formatter-3d5ddfb1.js} +2 -2
- package/dist/esm/{sub-state-notify-slimmer-7ef94141.js → sub-state-notify-slimmer-0f72ce74.js} +1 -1
- package/dist/esm/{sub-state-observer-slimmer-d9ad2bdd.js → sub-state-observer-slimmer-64532d94.js} +1 -1
- package/dist/esm/{time-required-rule-db0dee53.js → time-required-rule-355b73d2.js} +1 -1
- package/dist/esm/{token-extension-8ff92d14.js → token-extension-ecfafe94.js} +3618 -745
- package/dist/esm/{translation-slimmer-4904e7fe.js → translation-slimmer-3ea56354.js} +1 -1
- package/dist/esm/{type-guard-a2cbaae9.js → type-guard-2bfb2c7b.js} +1 -1
- package/dist/esm/{valid-credit-card-number-rule-a3f9858d.js → valid-credit-card-number-rule-52c6b029.js} +1 -1
- package/dist/esm/vega-accordion.entry.js +21 -13
- package/dist/esm/vega-app-footer.entry.js +3 -3
- package/dist/esm/vega-app-header-button.entry.js +10 -10
- package/dist/esm/vega-banner.entry.js +5 -8
- package/dist/esm/vega-box.entry.js +7 -7
- package/dist/esm/vega-breadcrumb.entry.js +5 -5
- package/dist/esm/vega-button-circle.entry.js +11 -11
- package/dist/esm/vega-button-group_2.entry.js +8 -8
- package/dist/esm/vega-button-link.entry.js +5 -5
- package/dist/esm/vega-button.entry.js +9 -9
- package/dist/esm/vega-calendar_5.entry.js +15 -15
- package/dist/esm/vega-card.entry.js +6 -6
- package/dist/esm/vega-carousel.entry.js +7 -7
- package/dist/esm/vega-checkbox_2.entry.js +10 -10
- package/dist/esm/vega-chip.entry.js +10 -10
- package/dist/esm/vega-code-block.entry.js +15 -18
- package/dist/esm/vega-color-picker.entry.js +9 -9
- package/dist/esm/vega-color-swatch-picker.entry.js +11 -11
- package/dist/esm/vega-color-swatch.entry.js +5 -5
- package/dist/esm/vega-combo-box.entry.js +23 -17
- package/dist/esm/vega-date-picker_2.entry.js +22 -22
- package/dist/esm/vega-dialog_2.entry.js +23 -12
- package/dist/esm/vega-divider.entry.js +6 -6
- package/dist/esm/vega-dropdown_5.entry.js +700 -202
- package/dist/esm/vega-env-manager-8f8dc473.js +2 -2
- package/dist/esm/{vega-event-id-268f8def.js → vega-event-id-270fe47e.js} +2 -1
- package/dist/esm/vega-field-label.entry.js +16 -12
- package/dist/esm/vega-file-uploader.entry.js +11 -11
- package/dist/esm/vega-flag-icon.entry.js +6 -6
- package/dist/esm/vega-flex.entry.js +7 -7
- package/dist/esm/vega-font.entry.js +6 -6
- package/dist/esm/vega-form.entry.js +11 -11
- package/dist/esm/vega-grid.entry.js +6 -6
- package/dist/esm/vega-icon.entry.js +6 -6
- package/dist/esm/vega-image-uploader.entry.js +13 -13
- package/dist/esm/vega-input-credit-card.entry.js +14 -14
- package/dist/esm/vega-input-numeric.entry.js +14 -14
- package/dist/esm/vega-input-passcode.entry.js +13 -13
- package/dist/esm/vega-input-phone-number.entry.js +11 -11
- package/dist/esm/vega-input-range.entry.js +10 -10
- package/dist/esm/vega-input-select.entry.js +13 -13
- package/dist/esm/vega-input.entry.js +15 -15
- package/dist/esm/{vega-internal-event-id-22151a4d.js → vega-internal-event-id-827eb1ce.js} +1 -1
- package/dist/esm/vega-item-toggle.entry.js +3 -3
- package/dist/esm/vega-left-nav_5.entry.js +14 -14
- package/dist/esm/vega-loader-wrapper_2.entry.js +4 -4
- package/dist/esm/vega-page-notification_2.entry.js +1 -1
- package/dist/esm/vega-pagination-page-selector-mobile.entry.js +5 -5
- package/dist/esm/vega-pagination-page-size-selector-mobile.entry.js +4 -4
- package/dist/esm/vega-pagination.entry.js +10 -10
- package/dist/esm/vega-popover_2.entry.js +14 -14
- package/dist/esm/vega-progress-tracker_2.entry.js +10 -10
- package/dist/esm/vega-radio_2.entry.js +13 -13
- package/dist/esm/vega-rich-text-content.entry.js +10 -10
- package/dist/esm/vega-rich-text-editor_4.entry.js +681 -99
- package/dist/esm/vega-rich-text-find-replace-panel.entry.js +229 -0
- package/dist/esm/vega-rich-text-special-characters-panel.entry.js +8 -8
- package/dist/esm/vega-rich-text-table-properties_3.entry.js +14 -14
- package/dist/esm/vega-segment-control.entry.js +3 -3
- package/dist/esm/vega-selection-chip_2.entry.js +13 -13
- package/dist/esm/vega-selection-tile_2.entry.js +11 -11
- package/dist/esm/vega-sidenav_3.entry.js +10 -10
- package/dist/esm/vega-signature-capture.entry.js +14 -14
- package/dist/esm/vega-stepper.entry.js +9 -9
- package/dist/esm/vega-tab-group_2.entry.js +5 -5
- package/dist/esm/vega-table_11.entry.js +915 -432
- package/dist/esm/vega-textarea.entry.js +11 -13
- package/dist/esm/vega-time-picker_2.entry.js +37 -17
- package/dist/esm/vega-toggle-switch.entry.js +7 -7
- package/dist/esm/vega-tooltip_2.entry.js +8 -8
- package/dist/esm/vega.js +18 -16
- package/dist/esm/{wait-for-component-did-render-0488922a.js → wait-for-component-did-render-0c237cb8.js} +1 -1
- package/dist/esm/xmark-large-c5ae7944.js +5 -0
- package/dist/sri/vega-sri-manifest.json +392 -376
- package/dist/types/components/vega-accordion/slimmers/vega-accordion-renderer.d.ts +2 -0
- package/dist/types/components/vega-combo-box/types.d.ts +6 -1
- package/dist/types/components/vega-combo-box/vega-combo-box.d.ts +1 -0
- package/dist/types/components/vega-dropdown/constants.d.ts +1 -0
- package/dist/types/components/vega-dropdown/slimmers/controllers/vega-dropdown-appender-controller.d.ts +2 -0
- package/dist/types/components/vega-dropdown/slimmers/controllers/vega-dropdown-children-controller.d.ts +36 -0
- package/dist/types/components/vega-dropdown/slimmers/controllers/vega-dropdown-select-all-controller.d.ts +107 -0
- package/dist/types/components/vega-dropdown/slimmers/controllers/vega-dropdown-selected-controller.d.ts +17 -0
- package/dist/types/components/vega-dropdown/slimmers/controllers/vega-dropdown-source-controller.d.ts +5 -0
- package/dist/types/components/vega-dropdown/slimmers/renderers/vega-dropdown-list-renderer.d.ts +2 -0
- package/dist/types/components/vega-dropdown/types.d.ts +8 -0
- package/dist/types/components/vega-dropdown/vega-dropdown-item/slimmers/controllers/vega-dropdown-item-state-controller.d.ts +25 -0
- package/dist/types/components/vega-dropdown/vega-dropdown-item/slimmers/renderers/vega-dropdown-item-renderer.d.ts +1 -0
- package/dist/types/components/vega-dropdown/vega-dropdown-item/vega-dropdown-item.d.ts +4 -0
- package/dist/types/components/vega-dropdown/vega-dropdown.d.ts +48 -0
- package/dist/types/components/vega-field-label/slimmers/renderers/vega-field-label-suffix-element-renderer.d.ts +1 -0
- package/dist/types/components/vega-field-label/types.d.ts +12 -0
- package/dist/types/components/vega-modal/slimmers/renderers/vega-modal-renderer.d.ts +2 -1
- package/dist/types/components/vega-modal/vega-modal.d.ts +9 -1
- package/dist/types/components/vega-rich-text-editor/dto/action-handle-strategies/modify-content-strategies/block-merge-nodes-strategy.d.ts +9 -0
- package/dist/types/components/vega-rich-text-editor/dto/action-handle-strategies/modify-content-strategies/delete-selected-content-strategy.d.ts +13 -0
- package/dist/types/components/vega-rich-text-editor/dto/action-handle-strategies/modify-content-strategies/paste-content-strategy.d.ts +14 -4
- package/dist/types/components/vega-rich-text-editor/dto/actions/delete-selected-content-action.d.ts +12 -0
- package/dist/types/components/vega-rich-text-editor/dto/actions/modify-content-action.abstract.d.ts +2 -1
- package/dist/types/components/vega-rich-text-editor/dto/actions/paste-content-action.d.ts +7 -0
- package/dist/types/components/vega-rich-text-editor/dto/range.d.ts +16 -0
- package/dist/types/components/vega-rich-text-editor/extensions/blockquote/action-handler-interceptors/blockquote-exit-on-enter-interceptor.d.ts +34 -0
- package/dist/types/components/vega-rich-text-editor/extensions/blockquote/action-handler-strategies/block-transform-to-blockquote-strategy.d.ts +13 -0
- package/dist/types/components/vega-rich-text-editor/extensions/blockquote/action-handler-strategies/remove-blockquote-strategy.d.ts +13 -0
- package/dist/types/components/vega-rich-text-editor/extensions/blockquote/actions/remove-blockquote-action.d.ts +14 -0
- package/dist/types/components/vega-rich-text-editor/extensions/blockquote/actions/transform-to-blockquote-action.d.ts +18 -0
- package/dist/types/components/vega-rich-text-editor/extensions/blockquote/assets/quote-left.d.ts +3 -0
- package/dist/types/components/vega-rich-text-editor/extensions/blockquote/blockquote-extension.d.ts +9 -0
- package/dist/types/components/vega-rich-text-editor/extensions/blockquote/dto/blockquote-annotation.d.ts +48 -0
- package/dist/types/components/vega-rich-text-editor/extensions/blockquote/dto/rte-blockquote-block.d.ts +56 -0
- package/dist/types/components/vega-rich-text-editor/extensions/blockquote/element-to-dto-strategies/blockquote-to-blockquote-block-strategy.d.ts +35 -0
- package/dist/types/components/vega-rich-text-editor/extensions/blockquote/filter-styles-strategies/blockquote-block/blockquote-filter-styles-strategy.d.ts +31 -0
- package/dist/types/components/vega-rich-text-editor/extensions/blockquote/renderers/blockquote-block-renderer.d.ts +18 -0
- package/dist/types/components/vega-rich-text-editor/extensions/blockquote/renderers/blockquote-toolbar-button-renderer.d.ts +113 -0
- package/dist/types/components/vega-rich-text-editor/extensions/copy/action-handler-strategies/copy-selected-content-strategy.d.ts +79 -0
- package/dist/types/components/vega-rich-text-editor/extensions/copy/actions/copy-selected-content-action.d.ts +18 -0
- package/dist/types/components/vega-rich-text-editor/extensions/copy/copy-extension.d.ts +10 -0
- package/dist/types/components/vega-rich-text-editor/extensions/copy/copy-toolbar-button-renderer.d.ts +36 -0
- package/dist/types/components/vega-rich-text-editor/extensions/cut/cut-extension.d.ts +11 -0
- package/dist/types/components/vega-rich-text-editor/extensions/cut/cut-toolbar-button-renderer.d.ts +24 -0
- package/dist/types/components/vega-rich-text-editor/extensions/find-replace/assets/find-and-replace.d.ts +3 -0
- package/dist/types/components/vega-rich-text-editor/extensions/find-replace/find-replace-extension.d.ts +15 -0
- package/dist/types/components/vega-rich-text-editor/extensions/find-replace/slimmer/controllers/find-controller.d.ts +65 -0
- package/dist/types/components/vega-rich-text-editor/extensions/find-replace/slimmer/controllers/find-replace-controller.abstract.d.ts +65 -0
- package/dist/types/components/vega-rich-text-editor/extensions/find-replace/slimmer/controllers/helper/block-search-strategies/block-search-strategy.abstract.d.ts +29 -0
- package/dist/types/components/vega-rich-text-editor/extensions/find-replace/slimmer/controllers/helper/block-search-strategies/code-block-search-strategy.d.ts +17 -0
- package/dist/types/components/vega-rich-text-editor/extensions/find-replace/slimmer/controllers/helper/block-search-strategies/container-block-search-strategy.d.ts +21 -0
- package/dist/types/components/vega-rich-text-editor/extensions/find-replace/slimmer/controllers/helper/block-search-strategies/list-item-block-search-strategy.d.ts +21 -0
- package/dist/types/components/vega-rich-text-editor/extensions/find-replace/slimmer/controllers/helper/block-search-strategies/text-block-search-strategy.d.ts +18 -0
- package/dist/types/components/vega-rich-text-editor/extensions/find-replace/slimmer/controllers/helper/find-replace-highlight-manager.d.ts +88 -0
- package/dist/types/components/vega-rich-text-editor/extensions/find-replace/slimmer/controllers/helper/find-replace-state.d.ts +200 -0
- package/dist/types/components/vega-rich-text-editor/extensions/find-replace/slimmer/controllers/replace-controller.d.ts +73 -0
- package/dist/types/components/vega-rich-text-editor/extensions/find-replace/slimmer/renderers/find-replace-toolbar-button-renderer.d.ts +64 -0
- package/dist/types/components/vega-rich-text-editor/extensions/find-replace/vega-rich-text-find-replace-panel/slimmers/renderers/find-replace-panel-renderer.d.ts +28 -0
- package/dist/types/components/vega-rich-text-editor/extensions/find-replace/vega-rich-text-find-replace-panel/vega-rich-text-find-replace-panel.d.ts +56 -0
- package/dist/types/components/vega-rich-text-editor/extensions/functions/function-extension.d.ts +1 -0
- package/dist/types/components/vega-rich-text-editor/extensions/horizontal-line/horizontal-line-extension.d.ts +1 -0
- package/dist/types/components/vega-rich-text-editor/extensions/image/image-extension.d.ts +27 -0
- package/dist/types/components/vega-rich-text-editor/extensions/image/type.d.ts +13 -0
- package/dist/types/components/vega-rich-text-editor/extensions/languages/language-extension.d.ts +1 -0
- package/dist/types/components/vega-rich-text-editor/extensions/line-height/line-height-extension.d.ts +1 -0
- package/dist/types/components/vega-rich-text-editor/extensions/paste/assets/paste.d.ts +3 -0
- package/dist/types/components/vega-rich-text-editor/extensions/paste/paste-chooser-ui.d.ts +58 -0
- package/dist/types/components/vega-rich-text-editor/extensions/paste/paste-constants.d.ts +6 -0
- package/dist/types/components/vega-rich-text-editor/extensions/paste/paste-extension.d.ts +150 -0
- package/dist/types/components/vega-rich-text-editor/extensions/special-characters/special-characters-extension.d.ts +1 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/table-extension.d.ts +1 -0
- package/dist/types/components/vega-rich-text-editor/extensions/tokens/token-extension.d.ts +1 -0
- package/dist/types/components/vega-rich-text-editor/helpers/utils.d.ts +7 -0
- package/dist/types/components/vega-rich-text-editor/public-api.d.ts +7 -0
- package/dist/types/components/vega-rich-text-editor/slimmers/controllers/helper/input-event-handler/abstract-delete-content-handler.d.ts +60 -0
- package/dist/types/components/vega-rich-text-editor/slimmers/controllers/helper/input-event-handler/backward-delete-content-handler.d.ts +8 -0
- package/dist/types/components/vega-rich-text-editor/slimmers/controllers/helper/input-event-handler/forward-delete-content-handler.d.ts +8 -0
- package/dist/types/components/vega-rich-text-editor/slimmers/controllers/helper/input-event-handler/insert-paste-handler.d.ts +114 -3
- package/dist/types/components/vega-rich-text-editor/slimmers/controllers/selection-controller.d.ts +22 -13
- package/dist/types/components/vega-rich-text-editor/slimmers/controllers/user-input-controller.d.ts +2 -1
- package/dist/types/components/vega-rich-text-editor/slimmers/renderers/tools/image-toolbar-button-slimmer.d.ts +10 -2
- package/dist/types/components/vega-rich-text-editor/vega-rich-text-editor-toolbar-button/slimmers/renderers/vega-rich-text-editor-toolbar-button-renderer.d.ts +1 -0
- package/dist/types/components/vega-rich-text-editor/vega-rich-text-editor-toolbar-button/vega-rich-text-editor-toolbar-button.d.ts +6 -0
- package/dist/types/components/vega-rich-text-editor/vega-rich-text-editor.d.ts +4 -4
- package/dist/types/components/vega-rich-text-editor/vega-rich-text-image-editor/vega-rich-text-image-editor.d.ts +1 -1
- package/dist/types/components/vega-rich-text-editor/vega-rich-text-link-editor/vega-rich-text-link-editor.d.ts +1 -1
- package/dist/types/components/vega-table/interface.d.ts +18 -0
- package/dist/types/components/vega-table/slimmers/controllers/dto/column-render-input-model.d.ts +13 -0
- package/dist/types/components/vega-table/slimmers/controllers/vega-table-body-col-span-controller.d.ts +43 -0
- package/dist/types/components/vega-table/slimmers/renderers/vega-table-body-col-span-resolver.d.ts +38 -0
- package/dist/types/components/vega-table/slimmers/renderers/vega-table-cell-renderer.d.ts +11 -2
- package/dist/types/components/vega-table/slimmers/renderers/vega-table-pinned-renderer.d.ts +4 -0
- package/dist/types/components/vega-table/slimmers/renderers/vega-table-row-renderer.d.ts +1 -0
- package/dist/types/components/vega-table/vega-table-cell/slimmers/controllers/vega-table-row-state-subscriber.d.ts +1 -1
- package/dist/types/components/vega-table/vega-table-cell/vega-table-cell.d.ts +9 -0
- package/dist/types/components/vega-table/vega-table-foot-cell/slimmers/renderers/vega-table-foot-cell-renderer.d.ts +1 -0
- package/dist/types/components/vega-table/vega-table-foot-cell/vega-table-foot-cell.d.ts +9 -0
- package/dist/types/components/vega-table/vega-table.d.ts +2 -0
- package/dist/types/components/vega-time-picker/slimmers/controllers/vega-time-picker-range-dropdown-controller.d.ts +1 -0
- package/dist/types/components/vega-time-picker/slimmers/controllers/vega-time-picker-single-dropdown-controller.d.ts +1 -0
- package/dist/types/components/vega-time-picker/types.d.ts +7 -0
- package/dist/types/components/vega-time-picker/vega-time-picker.d.ts +11 -1
- package/dist/types/components.d.ts +114 -3
- package/dist/types/constants/ui.d.ts +1 -1
- package/dist/types/global/icons/copy.d.ts +3 -0
- package/dist/types/helpers/event-manager/event-id/vega-event-id.d.ts +1 -0
- package/dist/types/helpers/translation/interface.d.ts +20 -1
- package/dist/types/helpers/ui/element-appender.d.ts +4 -1
- package/dist/types/types/components.type.d.ts +5 -1
- package/dist/types/types/ui.type.d.ts +1 -1
- package/dist/vega/index.esm.js +1 -1
- package/dist/vega/{p-94845302.entry.js → p-05f937c5.entry.js} +1 -1
- package/dist/vega/p-07562b9c.js +1 -0
- package/dist/vega/p-09d50f59.entry.js +1 -0
- package/dist/vega/{p-cc8bf6e7.entry.js → p-0cb78838.entry.js} +1 -1
- package/dist/vega/p-0e607b44.js +1 -0
- package/dist/vega/{p-1acd5f04.entry.js → p-0f1d6ceb.entry.js} +1 -1
- package/dist/vega/{p-ef44d516.js → p-140616fe.js} +1 -1
- package/dist/vega/{p-e75e75c9.entry.js → p-1818f399.entry.js} +1 -1
- package/dist/vega/{p-4037126d.js → p-18a5e8bc.js} +1 -1
- package/dist/vega/{p-2b22091e.js → p-19c42e30.js} +1 -1
- package/dist/vega/{p-c87c7ef4.js → p-1efab41b.js} +1 -1
- package/dist/vega/{p-cd2a1ffb.js → p-21e21f51.js} +1 -1
- package/dist/vega/{p-4644ccf9.entry.js → p-26c7fe8b.entry.js} +1 -1
- package/dist/vega/p-282b37cb.js +1 -0
- package/dist/vega/p-29e3eb12.js +1 -0
- package/dist/vega/{p-6ecb3c7d.entry.js → p-2dc5edd0.entry.js} +1 -1
- package/dist/vega/{p-014e2cf9.js → p-2de61f1b.js} +1 -1
- package/dist/vega/{p-b77e85e0.entry.js → p-2de88b4a.entry.js} +1 -1
- package/dist/vega/{p-12b5c5e3.entry.js → p-2fcc604c.entry.js} +1 -1
- package/dist/vega/{p-73b9868f.js → p-32a67ba1.js} +1 -1
- package/dist/vega/p-392e049c.entry.js +1 -0
- package/dist/vega/{p-70352240.entry.js → p-3932f964.entry.js} +1 -1
- package/dist/vega/{p-5ffc7cb8.js → p-3a68b729.js} +1 -1
- package/dist/vega/{p-9e327397.entry.js → p-3c9da3cd.entry.js} +1 -1
- package/dist/vega/{p-4cef4812.js → p-3f183b52.js} +1 -1
- package/dist/vega/{p-216ef41e.entry.js → p-3f7b10b9.entry.js} +1 -1
- package/dist/vega/{p-64b5fe2a.entry.js → p-422d88ae.entry.js} +1 -1
- package/dist/vega/p-4256252c.js +3 -0
- package/dist/vega/{p-329c808e.entry.js → p-44439ecc.entry.js} +1 -1
- package/dist/vega/p-45e8424a.entry.js +1 -0
- package/dist/vega/p-4c49b2e3.js +1 -0
- package/dist/vega/{p-a14d8767.js → p-4d9562bc.js} +1 -1
- package/dist/vega/p-4e1aa86f.js +1 -0
- package/dist/vega/p-4ef5c4a7.entry.js +1 -0
- package/dist/vega/{p-7f086e54.entry.js → p-4f327808.entry.js} +1 -1
- package/dist/vega/{p-8019c156.js → p-5139e516.js} +1 -1
- package/dist/vega/{p-5bed3fd2.entry.js → p-56c4e349.entry.js} +1 -1
- package/dist/vega/{p-fea33425.js → p-5dbfffcd.js} +1 -1
- package/dist/vega/p-5f377954.js +1 -1
- package/dist/vega/p-615a2b8c.entry.js +1 -0
- package/dist/vega/{p-aaa6e976.entry.js → p-63101cb4.entry.js} +1 -1
- package/dist/vega/{p-a4826f3f.entry.js → p-653a6dd8.entry.js} +1 -1
- package/dist/vega/{p-044496e0.entry.js → p-66b7d1c7.entry.js} +1 -1
- package/dist/vega/{p-42a1d300.entry.js → p-6712a9c7.entry.js} +1 -1
- package/dist/vega/p-698fbd73.js +1 -0
- package/dist/vega/p-6ad7144a.entry.js +1 -0
- package/dist/vega/{p-6e7c1b19.entry.js → p-6b1893f6.entry.js} +1 -1
- package/dist/vega/{p-cec8ffdc.js → p-6d40635e.js} +1 -1
- package/dist/vega/{p-81591449.entry.js → p-73fd18d9.entry.js} +1 -1
- package/dist/vega/p-751a5cd6.entry.js +1 -0
- package/dist/vega/{p-42f3c0b1.entry.js → p-7b93a756.entry.js} +1 -1
- package/dist/vega/p-7c8e579e.entry.js +1 -0
- package/dist/vega/{p-0707aa21.js → p-7d54e9c1.js} +1 -1
- package/dist/vega/p-832d1a72.entry.js +1 -0
- package/dist/vega/p-846b1ab9.entry.js +1 -0
- package/dist/vega/p-88863658.js +1 -0
- package/dist/vega/p-88a6c89a.js +1 -0
- package/dist/vega/p-890a5254.js +1 -0
- package/dist/vega/{p-14bfc113.js → p-8bc15ed0.js} +1 -1
- package/dist/vega/{p-50d7a1c4.entry.js → p-8c1a5fa4.entry.js} +1 -1
- package/dist/vega/p-8d27b9cc.js +1 -0
- package/dist/vega/{p-3863187f.entry.js → p-944b43ce.entry.js} +1 -1
- package/dist/vega/{p-aea912ac.js → p-95d6c85f.js} +1 -1
- package/dist/vega/{p-da067259.entry.js → p-99b699be.entry.js} +1 -1
- package/dist/vega/{p-d00b3910.js → p-9a01be93.js} +1 -1
- package/dist/vega/p-9a472a04.entry.js +1 -0
- package/dist/vega/{p-e9a82603.entry.js → p-9cafbc26.entry.js} +1 -1
- package/dist/vega/{p-cd21adb8.js → p-a2bd621e.js} +1 -1
- package/dist/vega/{p-5a4e598f.js → p-a359e53c.js} +1 -1
- package/dist/vega/p-a9a87b9a.js +1 -0
- package/dist/vega/p-acbba6da.entry.js +1 -0
- package/dist/vega/{p-c75872a4.entry.js → p-ad35dea4.entry.js} +1 -1
- package/dist/vega/{p-8bc23bcf.entry.js → p-af98539f.entry.js} +1 -1
- package/dist/vega/{p-141f74ff.js → p-afb96938.js} +1 -1
- package/dist/vega/{p-6820b488.entry.js → p-b042e3b4.entry.js} +1 -1
- package/dist/vega/{p-822f70b0.js → p-b1ff70bf.js} +1 -1
- package/dist/vega/{p-c65a5778.entry.js → p-b39d4a88.entry.js} +1 -1
- package/dist/vega/{p-5df53125.entry.js → p-b5bee669.entry.js} +1 -1
- package/dist/vega/p-b5f308ee.entry.js +1 -0
- package/dist/vega/p-b6225d01.js +1 -0
- package/dist/vega/{p-8982796b.entry.js → p-bbabb1c8.entry.js} +1 -1
- package/dist/vega/p-bbf1f988.entry.js +1 -0
- package/dist/vega/{p-5fcb825c.entry.js → p-c2d28797.entry.js} +1 -1
- package/dist/vega/{p-42ed76ee.entry.js → p-c3c0e415.entry.js} +1 -1
- package/dist/vega/{p-5e282e41.js → p-c553d37e.js} +1 -1
- package/dist/vega/{p-2f48162f.entry.js → p-c5ecbc53.entry.js} +1 -1
- package/dist/vega/p-c9c6daa6.entry.js +1 -0
- package/dist/vega/p-cb81fc2a.entry.js +1 -0
- package/dist/vega/p-ccb9bf86.js +1 -0
- package/dist/vega/{p-49b4ab2b.js → p-ccf7518b.js} +1 -1
- package/dist/vega/{p-da2b1fd0.entry.js → p-cf8d5b3f.entry.js} +1 -1
- package/dist/vega/{p-bb0040d4.entry.js → p-d3a36d19.entry.js} +1 -1
- package/dist/vega/{p-ce27c273.entry.js → p-d44943e2.entry.js} +1 -1
- package/dist/vega/{p-ae728041.entry.js → p-d4bb6f93.entry.js} +1 -1
- package/dist/vega/p-d62b85ff.entry.js +1 -0
- package/dist/vega/p-d7f32ccf.entry.js +1 -0
- package/dist/vega/{p-d0060bdb.js → p-dca3278f.js} +1 -1
- package/dist/vega/{p-15da9d58.entry.js → p-ddd28a8e.entry.js} +1 -1
- package/dist/vega/p-ddf03de1.entry.js +1 -0
- package/dist/vega/{p-21775cc7.js → p-e0ecafca.js} +1 -1
- package/dist/vega/p-e33e1e90.js +1 -0
- package/dist/vega/{p-316a1e5c.entry.js → p-e410c4ad.entry.js} +1 -1
- package/dist/vega/p-e4309574.js +1 -0
- package/dist/vega/p-e5187a86.entry.js +1 -0
- package/dist/vega/{p-335e3237.entry.js → p-e86c6802.entry.js} +1 -1
- package/dist/vega/{p-4979fd7d.js → p-ef605271.js} +1 -1
- package/dist/vega/{p-0e03daa6.js → p-f0d4c78c.js} +1 -1
- package/dist/vega/p-f2f22b5d.entry.js +1 -0
- package/dist/vega/{p-58a00869.entry.js → p-f8a29127.entry.js} +1 -1
- package/dist/vega/{p-a04b95aa.entry.js → p-fbd3be00.entry.js} +1 -1
- package/dist/vega/p-fd70418f.js +1 -0
- package/dist/vega/{p-9756c6b9.entry.js → p-fda6e2cc.entry.js} +1 -1
- package/dist/vega/p-ff8dd200.js +1 -0
- package/dist/vega/{p-522dd15f.entry.js → p-ffdacaf9.entry.js} +1 -1
- package/dist/vega/vega.esm.js +1 -1
- package/package.json +2 -16
- package/readme.md +0 -5
- package/dist/collection/components/vega-rich-text-editor/slimmers/controllers/helper/input-event-handler/delete-content-handler.js +0 -92
- package/dist/types/components/vega-rich-text-editor/slimmers/controllers/helper/input-event-handler/delete-content-handler.d.ts +0 -26
- package/dist/vega/p-0605c656.entry.js +0 -1
- package/dist/vega/p-144d4b30.js +0 -1
- package/dist/vega/p-2944c76e.entry.js +0 -1
- package/dist/vega/p-3372f34a.entry.js +0 -1
- package/dist/vega/p-3cf298a4.entry.js +0 -1
- package/dist/vega/p-3fe43f7a.entry.js +0 -1
- package/dist/vega/p-507612f6.entry.js +0 -1
- package/dist/vega/p-53ed3b1f.js +0 -1
- package/dist/vega/p-57f7c257.js +0 -1
- package/dist/vega/p-5e1cd1cc.js +0 -1
- package/dist/vega/p-5e1ec2b8.entry.js +0 -1
- package/dist/vega/p-61d42e9b.entry.js +0 -1
- package/dist/vega/p-63ae5ada.entry.js +0 -1
- package/dist/vega/p-66905cbf.js +0 -1
- package/dist/vega/p-689070f9.entry.js +0 -1
- package/dist/vega/p-74fa0f5b.entry.js +0 -1
- package/dist/vega/p-7bb39b97.js +0 -1
- package/dist/vega/p-7f139b74.js +0 -1
- package/dist/vega/p-85d78ac1.js +0 -1
- package/dist/vega/p-92a144bc.js +0 -1
- package/dist/vega/p-9f608b97.js +0 -1
- package/dist/vega/p-aca134a3.entry.js +0 -1
- package/dist/vega/p-b2f89dbd.js +0 -1
- package/dist/vega/p-b2f9698a.entry.js +0 -1
- package/dist/vega/p-b504a8b4.entry.js +0 -1
- package/dist/vega/p-b7b0930a.entry.js +0 -1
- package/dist/vega/p-bd94b904.entry.js +0 -1
- package/dist/vega/p-c0c2a917.js +0 -3
- package/dist/vega/p-c40555c4.entry.js +0 -1
- package/dist/vega/p-cb4033ef.js +0 -1
- package/dist/vega/p-d14ddf80.js +0 -1
- package/dist/vega/p-dc78e8d6.js +0 -1
- package/dist/vega/p-ddc2d219.js +0 -1
- package/dist/vega/p-f362c07b.entry.js +0 -1
- package/dist/vega/p-fb1ef3e6.entry.js +0 -1
- package/dist/vega/p-fc103347.entry.js +0 -1
- /package/dist/cjs/{feature-flag-controller-438a1510.js → feature-flag-controller-c19d0b58.js} +0 -0
- /package/dist/collection/{components/vega-code-block/assets → global/icons}/copy.js +0 -0
- /package/dist/esm/{feature-flag-controller-2a89f20c.js → feature-flag-controller-3fd04ea9.js} +0 -0
- /package/dist/types/components/{vega-code-block/assets/copy.d.ts → vega-rich-text-editor/assets/cut.d.ts} +0 -0
- /package/dist/vega/{p-bc73ce30.js → p-87a4d75f.js} +0 -0
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import { ModifyContentAction } from '../../../dto/actions/modify-content-action.abstract';
|
|
2
|
+
/**
|
|
3
|
+
* Action type discriminator. Plain string constant — intentionally NOT added
|
|
4
|
+
* to {@link ModifyContentActionType} enum to keep the extension self-contained.
|
|
5
|
+
*/
|
|
6
|
+
export const TRANSFORM_TO_BLOCKQUOTE = 'TRANSFORM_TO_BLOCKQUOTE';
|
|
7
|
+
/**
|
|
8
|
+
* Wrap the supplied blocks into a new `<blockquote>` block while preserving
|
|
9
|
+
* their order. Strategy reads `selectedBlocks` and replaces them in-place
|
|
10
|
+
* with a single `RTEBlockquoteBlock` that adopts them as children.
|
|
11
|
+
*/
|
|
12
|
+
export class TransformToBlockquoteAction extends ModifyContentAction {
|
|
13
|
+
constructor(selectedBlocks) {
|
|
14
|
+
super();
|
|
15
|
+
this.isFlushable = true;
|
|
16
|
+
this.type = TRANSFORM_TO_BLOCKQUOTE;
|
|
17
|
+
this.selectedBlocks = selectedBlocks;
|
|
18
|
+
}
|
|
19
|
+
}
|
package/dist/collection/components/vega-rich-text-editor/extensions/blockquote/assets/quote-left.js
ADDED
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
// FontAwesome 7.2.0 — `quote-left` (solid).
|
|
2
|
+
export default {
|
|
3
|
+
icon: `<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 448 512"><path fill="currentColor" d="M0 216C0 149.7 53.7 96 120 96l8 0c17.7 0 32 14.3 32 32s-14.3 32-32 32l-8 0c-30.9 0-56 25.1-56 56l0 8 64 0c35.3 0 64 28.7 64 64l0 64c0 35.3-28.7 64-64 64l-64 0c-35.3 0-64-28.7-64-64L0 216zm256 0c0-66.3 53.7-120 120-120l8 0c17.7 0 32 14.3 32 32s-14.3 32-32 32l-8 0c-30.9 0-56 25.1-56 56l0 8 64 0c35.3 0 64 28.7 64 64l0 64c0 35.3-28.7 64-64 64l-64 0c-35.3 0-64-28.7-64-64l0-136z"/></svg>`,
|
|
4
|
+
};
|
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
import { VegaRTEExtension } from '../extension.abstract';
|
|
2
|
+
import { VegaRTEContent } from '../../dto/content-state';
|
|
3
|
+
import { RTETableCellBlock } from '../table/dto/table-cell-block';
|
|
4
|
+
import { RTETableHeadCellBlock } from '../table/dto/table-head-cell-block';
|
|
5
|
+
import { ModifyContentActionType } from '../../dto/actions/modify-content-action.abstract';
|
|
6
|
+
import { RTETextBlock } from '../../dto/blocks/text-block';
|
|
7
|
+
import { BlockTransformToBlockquoteStrategy } from './action-handler-strategies/block-transform-to-blockquote-strategy';
|
|
8
|
+
import { RemoveBlockquoteStrategy } from './action-handler-strategies/remove-blockquote-strategy';
|
|
9
|
+
import { BlockquoteExitOnEnterInterceptor } from './action-handler-interceptors/blockquote-exit-on-enter-interceptor';
|
|
10
|
+
import { TRANSFORM_TO_BLOCKQUOTE } from './actions/transform-to-blockquote-action';
|
|
11
|
+
import { REMOVE_BLOCKQUOTE } from './actions/remove-blockquote-action';
|
|
12
|
+
import { RTEBlockquoteBlock } from './dto/rte-blockquote-block';
|
|
13
|
+
import { BlockquoteToBlockquoteBlockStrategy } from './element-to-dto-strategies/blockquote-to-blockquote-block-strategy';
|
|
14
|
+
import RTEBlockquoteBlockRenderer from './renderers/blockquote-block-renderer';
|
|
15
|
+
import { RTEBlockquoteToolbarButtonRenderer } from './renderers/blockquote-toolbar-button-renderer';
|
|
16
|
+
import { BlockquoteFilterStylesStrategy } from './filter-styles-strategies/blockquote-block/blockquote-filter-styles-strategy';
|
|
17
|
+
/**
|
|
18
|
+
* Adds `<blockquote>` support to the Vega Rich Text Editor.
|
|
19
|
+
*/
|
|
20
|
+
export class VegaRTEBlockquoteExtension extends VegaRTEExtension {
|
|
21
|
+
constructor() {
|
|
22
|
+
super();
|
|
23
|
+
this.toolbarButtonRenderer = new RTEBlockquoteToolbarButtonRenderer();
|
|
24
|
+
this.registerBlockBasicStrategies(RTEBlockquoteBlock.name);
|
|
25
|
+
this.registerNode('blockquote', RTEBlockquoteBlock);
|
|
26
|
+
this.registerRenderer('blockquote', RTEBlockquoteBlockRenderer);
|
|
27
|
+
this.registerToolbarButtonRenderer(VegaRTEBlockquoteExtension.TOOLBAR_BUTTON_KEY, this.toolbarButtonRenderer);
|
|
28
|
+
this.registerElementToBlockDTOClassStrategy(new BlockquoteToBlockquoteBlockStrategy());
|
|
29
|
+
// Register filter styles strategy for source edit round-trip.
|
|
30
|
+
VegaRTEExtension.registerFilterStylesStrategy(RTEBlockquoteBlock.dtoName, new BlockquoteFilterStylesStrategy());
|
|
31
|
+
}
|
|
32
|
+
}
|
|
33
|
+
(() => {
|
|
34
|
+
const wrapStrategy = new BlockTransformToBlockquoteStrategy();
|
|
35
|
+
// Root container — wrap top-level blocks.
|
|
36
|
+
VegaRTEExtension.registerActionHandleStrategy(VegaRTEContent.name, TRANSFORM_TO_BLOCKQUOTE, wrapStrategy);
|
|
37
|
+
// Table cells (body + header) — wrap is scoped to the closest cell.
|
|
38
|
+
// Other container blocks (code, list item, function) are intentionally
|
|
39
|
+
// not registered, so the toolbar stays disabled inside them.
|
|
40
|
+
VegaRTEExtension.registerActionHandleStrategy(RTETableCellBlock.name, TRANSFORM_TO_BLOCKQUOTE, wrapStrategy);
|
|
41
|
+
VegaRTEExtension.registerActionHandleStrategy(RTETableHeadCellBlock.name, TRANSFORM_TO_BLOCKQUOTE, wrapStrategy);
|
|
42
|
+
VegaRTEExtension.registerActionHandleStrategy(RTEBlockquoteBlock.name, REMOVE_BLOCKQUOTE, new RemoveBlockquoteStrategy());
|
|
43
|
+
// Enables exiting the blockquote via the keyboard: pressing Enter on an empty
|
|
44
|
+
// trailing paragraph breaks out to a new paragraph after the blockquote.
|
|
45
|
+
VegaRTEExtension.registerActionHandlerInterceptor(RTETextBlock.name, ModifyContentActionType.INSERT_NEW_PARAGRAPH, new BlockquoteExitOnEnterInterceptor());
|
|
46
|
+
})();
|
|
47
|
+
VegaRTEBlockquoteExtension.TOOLBAR_BUTTON_KEY = 'blockquote';
|
|
@@ -0,0 +1,76 @@
|
|
|
1
|
+
import { BlockAnnotation } from '../../../dto/annotations/block-annotation.abstract';
|
|
2
|
+
import { camelToDashCase } from '../../../../../utils/string';
|
|
3
|
+
export var RTEBlockquoteExtensionAnnotationTypeEnum;
|
|
4
|
+
(function (RTEBlockquoteExtensionAnnotationTypeEnum) {
|
|
5
|
+
RTEBlockquoteExtensionAnnotationTypeEnum["BLOCKQUOTE"] = "BLOCKQUOTE";
|
|
6
|
+
})(RTEBlockquoteExtensionAnnotationTypeEnum || (RTEBlockquoteExtensionAnnotationTypeEnum = {}));
|
|
7
|
+
/**
|
|
8
|
+
* CSS class applied to `<blockquote>` elements rendered inside the editor.
|
|
9
|
+
*/
|
|
10
|
+
export const BLOCKQUOTE_CLASS_NAME = 'v-rte-blockquote';
|
|
11
|
+
/**
|
|
12
|
+
* Default visual styles for the `<blockquote>` element in the RTE.
|
|
13
|
+
*/
|
|
14
|
+
export const BLOCKQUOTE_DEFAULT_STYLES = {
|
|
15
|
+
overflow: 'hidden',
|
|
16
|
+
marginInline: '0',
|
|
17
|
+
paddingInline: '24px',
|
|
18
|
+
borderInlineStart: 'solid 5px hsl(0, 0%, 80%)',
|
|
19
|
+
};
|
|
20
|
+
/**
|
|
21
|
+
* Blockquote annotation.
|
|
22
|
+
*/
|
|
23
|
+
export class BlockquoteAnnotation extends BlockAnnotation {
|
|
24
|
+
constructor() {
|
|
25
|
+
super(...arguments);
|
|
26
|
+
this.type = RTEBlockquoteExtensionAnnotationTypeEnum.BLOCKQUOTE;
|
|
27
|
+
}
|
|
28
|
+
/**
|
|
29
|
+
* Generate the map item for the annotation.
|
|
30
|
+
*
|
|
31
|
+
* @returns {[RTEBlockquoteExtensionAnnotationTypeEnum.BLOCKQUOTE, BlockquoteAnnotation]} Map item.
|
|
32
|
+
*/
|
|
33
|
+
static from() {
|
|
34
|
+
return [RTEBlockquoteExtensionAnnotationTypeEnum.BLOCKQUOTE, new BlockquoteAnnotation()];
|
|
35
|
+
}
|
|
36
|
+
/**
|
|
37
|
+
* Get the default CSS rule for the blockquote element.
|
|
38
|
+
*
|
|
39
|
+
* @returns {string} The default CSS rule.
|
|
40
|
+
*/
|
|
41
|
+
static getDefaultCssText() {
|
|
42
|
+
const declarations = Object.entries(BLOCKQUOTE_DEFAULT_STYLES)
|
|
43
|
+
.map(([key, value]) => `\t${camelToDashCase(key)}: ${value};`)
|
|
44
|
+
.join('\n');
|
|
45
|
+
return `.${BLOCKQUOTE_CLASS_NAME} {\n${declarations}\n}`;
|
|
46
|
+
}
|
|
47
|
+
/**
|
|
48
|
+
* @inheritDoc
|
|
49
|
+
*/
|
|
50
|
+
toJSON() {
|
|
51
|
+
// Blockquote identity is captured by the block type; nothing to serialize.
|
|
52
|
+
return null;
|
|
53
|
+
}
|
|
54
|
+
/**
|
|
55
|
+
* @inheritDoc
|
|
56
|
+
*/
|
|
57
|
+
clone() {
|
|
58
|
+
return new BlockquoteAnnotation();
|
|
59
|
+
}
|
|
60
|
+
/**
|
|
61
|
+
* @inheritDoc
|
|
62
|
+
*/
|
|
63
|
+
renderClass(options) {
|
|
64
|
+
if (options === null || options === void 0 ? void 0 : options.standalone)
|
|
65
|
+
return null;
|
|
66
|
+
return BLOCKQUOTE_CLASS_NAME;
|
|
67
|
+
}
|
|
68
|
+
/**
|
|
69
|
+
* @inheritDoc
|
|
70
|
+
*/
|
|
71
|
+
renderStyle(options) {
|
|
72
|
+
if (!(options === null || options === void 0 ? void 0 : options.standalone))
|
|
73
|
+
return null;
|
|
74
|
+
return BLOCKQUOTE_DEFAULT_STYLES;
|
|
75
|
+
}
|
|
76
|
+
}
|
|
@@ -0,0 +1,70 @@
|
|
|
1
|
+
import { RTEBlock } from '../../../dto/blocks/block.abstract';
|
|
2
|
+
import { BlockquoteAnnotation } from './blockquote-annotation';
|
|
3
|
+
/**
|
|
4
|
+
* DTO representing a `<blockquote>` block.
|
|
5
|
+
*/
|
|
6
|
+
export class RTEBlockquoteBlock extends RTEBlock {
|
|
7
|
+
constructor(id, options) {
|
|
8
|
+
super(id);
|
|
9
|
+
this.dtoName = RTEBlockquoteBlock.dtoName;
|
|
10
|
+
this.type = 'blockquote';
|
|
11
|
+
this.children = [];
|
|
12
|
+
const { autoMatchFormat = true } = options !== null && options !== void 0 ? options : {};
|
|
13
|
+
if (autoMatchFormat) {
|
|
14
|
+
this.annotationMap = new Map([BlockquoteAnnotation.from()]);
|
|
15
|
+
}
|
|
16
|
+
}
|
|
17
|
+
/**
|
|
18
|
+
* Convert a JSON block payload into an `RTEBlockquoteBlock` instance.
|
|
19
|
+
*
|
|
20
|
+
* @param {VegaRTEBlockquoteBlock} block - JSON payload.
|
|
21
|
+
* @param {VegaRTETransformOptions} [options] - Transform options.
|
|
22
|
+
* @returns {RTEBlockquoteBlock} The created blockquote block.
|
|
23
|
+
*/
|
|
24
|
+
static from(block, options) {
|
|
25
|
+
const blockquote = new RTEBlockquoteBlock(block.id, options);
|
|
26
|
+
if (block.annotations) {
|
|
27
|
+
RTEBlock.convertAnnotationsToMap(blockquote.annotationMap, block.annotations);
|
|
28
|
+
}
|
|
29
|
+
blockquote.children = RTEBlock.generateBlockChildren(block.children, options, blockquote);
|
|
30
|
+
return blockquote;
|
|
31
|
+
}
|
|
32
|
+
/**
|
|
33
|
+
* @inheritDoc
|
|
34
|
+
*/
|
|
35
|
+
clone(parent) {
|
|
36
|
+
const cloned = new RTEBlockquoteBlock(this.id);
|
|
37
|
+
const clonedAsChildParent = cloned;
|
|
38
|
+
cloned.children = this.children.map((child) => child.clone(clonedAsChildParent));
|
|
39
|
+
cloned.annotationMap = this.cloneAnnotations();
|
|
40
|
+
cloned.parent = parent;
|
|
41
|
+
return cloned;
|
|
42
|
+
}
|
|
43
|
+
/**
|
|
44
|
+
* @inheritDoc
|
|
45
|
+
*/
|
|
46
|
+
getLastNode() {
|
|
47
|
+
return this.children[this.children.length - 1].getLastNode();
|
|
48
|
+
}
|
|
49
|
+
/**
|
|
50
|
+
* @inheritDoc
|
|
51
|
+
*/
|
|
52
|
+
isNotEmpty() {
|
|
53
|
+
return this.children.length > 0;
|
|
54
|
+
}
|
|
55
|
+
/**
|
|
56
|
+
* @inheritDoc
|
|
57
|
+
*/
|
|
58
|
+
toHtml(options) {
|
|
59
|
+
const attrStr = this.generateAttributeString(options);
|
|
60
|
+
const inner = this.children.map((child) => child.toHtml(options)).join('');
|
|
61
|
+
return `<blockquote${attrStr}>${inner}</blockquote>`;
|
|
62
|
+
}
|
|
63
|
+
/**
|
|
64
|
+
* @inheritDoc
|
|
65
|
+
*/
|
|
66
|
+
toJSON() {
|
|
67
|
+
return Object.assign(Object.assign({}, super.toJSON()), { id: this.id, type: 'blockquote', children: this.children.map((child) => child.toJSON()) });
|
|
68
|
+
}
|
|
69
|
+
}
|
|
70
|
+
RTEBlockquoteBlock.dtoName = 'RTEBlockquoteBlock';
|
|
@@ -0,0 +1,53 @@
|
|
|
1
|
+
import { generateUUID } from '../../../../../utils/misc';
|
|
2
|
+
import { ElementToDTOStrategy } from '../../../slimmers/controllers/helper/element-to-dto-strategy/element-to-dto-strategy.abstract';
|
|
3
|
+
import htmlElementToAnnotationGenerator from '../../../slimmers/controllers/helper/element-to-dto-strategy/annotation-handler/html-element-to-annotation-generator';
|
|
4
|
+
import { RTEBlockquoteBlock } from '../dto/rte-blockquote-block';
|
|
5
|
+
/**
|
|
6
|
+
* Claim every `<blockquote>` element encountered during HTML → DTO conversion
|
|
7
|
+
* and produce an {@link RTEBlockquoteBlock}.
|
|
8
|
+
*
|
|
9
|
+
* Nested `<blockquote>` elements are flattened to a single level in
|
|
10
|
+
* {@link appendChildBlocks}: any direct child that arrives as another
|
|
11
|
+
* `<blockquote>` is replaced by its own children, lifting them one level up.
|
|
12
|
+
*/
|
|
13
|
+
export class BlockquoteToBlockquoteBlockStrategy extends ElementToDTOStrategy {
|
|
14
|
+
/**
|
|
15
|
+
* @inheritDoc
|
|
16
|
+
*/
|
|
17
|
+
canHandle(elementsArray, currentIndex) {
|
|
18
|
+
return elementsArray[currentIndex].tagName === 'BLOCKQUOTE' ? 1 : 0;
|
|
19
|
+
}
|
|
20
|
+
/**
|
|
21
|
+
* @inheritDoc
|
|
22
|
+
*/
|
|
23
|
+
handle(elementsArray, options) {
|
|
24
|
+
const element = elementsArray[0];
|
|
25
|
+
const annotations = htmlElementToAnnotationGenerator.generate(RTEBlockquoteBlock, element, options);
|
|
26
|
+
return RTEBlockquoteBlock.from({
|
|
27
|
+
id: generateUUID(),
|
|
28
|
+
type: 'blockquote',
|
|
29
|
+
annotations,
|
|
30
|
+
children: [],
|
|
31
|
+
}, options);
|
|
32
|
+
}
|
|
33
|
+
/**
|
|
34
|
+
* Flatten nested `<blockquote>` elements: any direct child that is itself
|
|
35
|
+
* an {@link RTEBlockquoteBlock} is replaced by its own children, lifting
|
|
36
|
+
* them one level up.
|
|
37
|
+
*
|
|
38
|
+
* @inheritDoc
|
|
39
|
+
*/
|
|
40
|
+
appendChildBlocks(currentBlock, childBlocks) {
|
|
41
|
+
const flattened = childBlocks.flatMap((child) => child instanceof RTEBlockquoteBlock ? child.children : [child]);
|
|
42
|
+
currentBlock.children = flattened.map((block) => {
|
|
43
|
+
block.parent = currentBlock;
|
|
44
|
+
return block;
|
|
45
|
+
});
|
|
46
|
+
}
|
|
47
|
+
/**
|
|
48
|
+
* @inheritDoc
|
|
49
|
+
*/
|
|
50
|
+
shouldProceedToElementChildren() {
|
|
51
|
+
return true;
|
|
52
|
+
}
|
|
53
|
+
}
|
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
import { RTEFilterStylesStrategy, } from '../../../../dto/filter-styles-strategies/filter-styles-strategy.abstract';
|
|
2
|
+
import { BLOCKQUOTE_DEFAULT_STYLES } from '../../dto/blockquote-annotation';
|
|
3
|
+
/**
|
|
4
|
+
* Filter styles strategy for blockquote blocks.
|
|
5
|
+
* Strips default blockquote visual styles during output and refills them during input,
|
|
6
|
+
* ensuring source edit round-trips do not lose information.
|
|
7
|
+
*/
|
|
8
|
+
export class BlockquoteFilterStylesStrategy extends RTEFilterStylesStrategy {
|
|
9
|
+
constructor() {
|
|
10
|
+
super(...arguments);
|
|
11
|
+
this.stylesToBeFiltered = BLOCKQUOTE_DEFAULT_STYLES;
|
|
12
|
+
this.elementTagName = 'blockquote';
|
|
13
|
+
}
|
|
14
|
+
/**
|
|
15
|
+
* Checks if the given block dto class name corresponds to a blockquote block.
|
|
16
|
+
*
|
|
17
|
+
* @param {string} className The class name to check.
|
|
18
|
+
* @returns {boolean} True if the class name corresponds to a blockquote block, false otherwise.
|
|
19
|
+
*/
|
|
20
|
+
static isBlockquoteBlock(className) {
|
|
21
|
+
return className === 'RTEBlockquoteBlock';
|
|
22
|
+
}
|
|
23
|
+
/**
|
|
24
|
+
* @inheritDoc
|
|
25
|
+
*/
|
|
26
|
+
canFilter(blockOrNodeInstance) {
|
|
27
|
+
return BlockquoteFilterStylesStrategy.isBlockquoteBlock(blockOrNodeInstance.dtoName);
|
|
28
|
+
}
|
|
29
|
+
/**
|
|
30
|
+
* @inheritDoc
|
|
31
|
+
*/
|
|
32
|
+
canRefill(_blockOrNodeClassName, element) {
|
|
33
|
+
return element.tagName.toLowerCase() === this.elementTagName;
|
|
34
|
+
}
|
|
35
|
+
/**
|
|
36
|
+
* @inheritDoc
|
|
37
|
+
*/
|
|
38
|
+
toCssText() {
|
|
39
|
+
return this.buildCssTextForStyles(this.elementTagName, this.classNameToBeAdded);
|
|
40
|
+
}
|
|
41
|
+
}
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import { VegaRTEExtensionRenderer } from '../../base-extension-renderer';
|
|
2
|
+
import { BlockquoteAnnotation } from '../dto/blockquote-annotation';
|
|
3
|
+
/**
|
|
4
|
+
* Renderer for blockquote blocks in the rich text editor.
|
|
5
|
+
*/
|
|
6
|
+
export class RTEBlockquoteBlockRenderer extends VegaRTEExtensionRenderer {
|
|
7
|
+
/**
|
|
8
|
+
* @inheritDoc
|
|
9
|
+
*/
|
|
10
|
+
doRender(createElement, block, rteContext) {
|
|
11
|
+
var _a;
|
|
12
|
+
return createElement('blockquote', Object.assign({ key: block.id, class: block.getClasses(rteContext), style: block.getStyles(rteContext), ref: this.useRef(block) }, (_a = block.getCustomAttributesAnnotation()) === null || _a === void 0 ? void 0 : _a.render()));
|
|
13
|
+
}
|
|
14
|
+
/**
|
|
15
|
+
* @inheritDoc
|
|
16
|
+
*/
|
|
17
|
+
injectRTEScopeStyles() {
|
|
18
|
+
return BlockquoteAnnotation.getDefaultCssText();
|
|
19
|
+
}
|
|
20
|
+
}
|
|
21
|
+
export default new RTEBlockquoteBlockRenderer();
|
|
@@ -0,0 +1,260 @@
|
|
|
1
|
+
import { generateUUID } from '../../../../../utils/misc';
|
|
2
|
+
import { VegaInternalIconManager } from '../../../../../helpers/icon/internal-icon-manager';
|
|
3
|
+
import { ActionHandleStrategyRegistry } from '../../../dto/action-handle-strategies/action-handle-strategy-registry';
|
|
4
|
+
import { RTETextBlock } from '../../../dto/blocks/text-block';
|
|
5
|
+
import { VegaRTEContent } from '../../../dto/content-state';
|
|
6
|
+
import { VegaRTEToolbarButtonRenderer } from '../../base-toolbar-button-renderer';
|
|
7
|
+
import { InsertChildrenAfterAction } from '../../../dto/actions/insert-children-after-block';
|
|
8
|
+
import { UpdateCursorPositionAction } from '../../../dto/actions/update-cursor-position-action';
|
|
9
|
+
import { RemoveBlockquoteAction } from '../actions/remove-blockquote-action';
|
|
10
|
+
import { TRANSFORM_TO_BLOCKQUOTE, TransformToBlockquoteAction, } from '../actions/transform-to-blockquote-action';
|
|
11
|
+
import { RTEBlockquoteBlock } from '../dto/rte-blockquote-block';
|
|
12
|
+
import QuoteLeftIcon from '../assets/quote-left';
|
|
13
|
+
/**
|
|
14
|
+
* Toolbar button renderer for the blockquote extension.
|
|
15
|
+
*
|
|
16
|
+
* Behaviors implemented:
|
|
17
|
+
* - Active (`selected`) when the caret/selection is inside any blockquote
|
|
18
|
+
* ancestor.
|
|
19
|
+
* - Click wraps the current block(s) into a new `<blockquote>`, or unwraps
|
|
20
|
+
* the nearest blockquote ancestor when active. Inside a list, the entire
|
|
21
|
+
* list is wrapped (escalating to the outermost list block). With no
|
|
22
|
+
* selection, a new empty blockquote is appended at the end and focused.
|
|
23
|
+
* - Disabled when the wrap container does not support the wrap strategy
|
|
24
|
+
* (e.g. inside a code block or function block); the button remains
|
|
25
|
+
* enabled inside a blockquote so it can be toggled off, and with no
|
|
26
|
+
* selection so it can append a new blockquote.
|
|
27
|
+
* - Hidden in source-edit mode (inherited from {@link VegaRTEToolbarButtonRenderer}).
|
|
28
|
+
*/
|
|
29
|
+
export class RTEBlockquoteToolbarButtonRenderer extends VegaRTEToolbarButtonRenderer {
|
|
30
|
+
/**
|
|
31
|
+
* @inheritDoc
|
|
32
|
+
*/
|
|
33
|
+
render(createElement, editorContext) {
|
|
34
|
+
return this.renderButton(createElement, editorContext, {
|
|
35
|
+
icon: 'quote-left',
|
|
36
|
+
tooltip: { text: 'Block quote' },
|
|
37
|
+
});
|
|
38
|
+
}
|
|
39
|
+
/**
|
|
40
|
+
* @inheritDoc
|
|
41
|
+
*/
|
|
42
|
+
isSelected(editorContext) {
|
|
43
|
+
const startNode = this.getStartNode(editorContext);
|
|
44
|
+
return startNode ? this.findBlockquoteAncestor(startNode) !== null : false;
|
|
45
|
+
}
|
|
46
|
+
/**
|
|
47
|
+
* @inheritDoc
|
|
48
|
+
*/
|
|
49
|
+
isDisabled(editorContext) {
|
|
50
|
+
if (editorContext.host.disabled) {
|
|
51
|
+
return true;
|
|
52
|
+
}
|
|
53
|
+
const startNode = this.getStartNode(editorContext);
|
|
54
|
+
// No selection — click appends a new blockquote at the end.
|
|
55
|
+
// Inside a blockquote — click toggles it off.
|
|
56
|
+
// Either way, the button stays enabled.
|
|
57
|
+
if (!startNode || this.findBlockquoteAncestor(startNode) !== null) {
|
|
58
|
+
return false;
|
|
59
|
+
}
|
|
60
|
+
const { container } = this.resolveWrapAnchor(startNode.parent);
|
|
61
|
+
return !ActionHandleStrategyRegistry.canHandle(TRANSFORM_TO_BLOCKQUOTE, container);
|
|
62
|
+
}
|
|
63
|
+
/**
|
|
64
|
+
* @inheritDoc
|
|
65
|
+
*/
|
|
66
|
+
handleButtonClick(editorContext) {
|
|
67
|
+
const context = this.getExtensionContext(editorContext.host);
|
|
68
|
+
if (context) {
|
|
69
|
+
const { host, getSelectedNodes } = context;
|
|
70
|
+
const selectedNodes = getSelectedNodes();
|
|
71
|
+
const startNode = selectedNodes[0];
|
|
72
|
+
if (!startNode) {
|
|
73
|
+
// No active selection → append a new empty blockquote at the end (mirrors text-style toolbar).
|
|
74
|
+
this.appendEmptyBlockquote(host.value);
|
|
75
|
+
return;
|
|
76
|
+
}
|
|
77
|
+
// Direction is decided by the first selected block only.
|
|
78
|
+
if (this.findBlockquoteAncestor(startNode)) {
|
|
79
|
+
const blockquoteAncestors = this.collectBlockquoteAncestors(selectedNodes);
|
|
80
|
+
blockquoteAncestors.forEach((blockquote) => {
|
|
81
|
+
blockquote.apply(new RemoveBlockquoteAction());
|
|
82
|
+
});
|
|
83
|
+
}
|
|
84
|
+
else {
|
|
85
|
+
this.wrapSelectedBlocks(selectedNodes);
|
|
86
|
+
}
|
|
87
|
+
host.value.apply(new UpdateCursorPositionAction(startNode, editorContext.rteRange.startOffset));
|
|
88
|
+
}
|
|
89
|
+
}
|
|
90
|
+
/* istanbul ignore next */
|
|
91
|
+
/**
|
|
92
|
+
* @inheritDoc
|
|
93
|
+
*/
|
|
94
|
+
handleDropdownClick() {
|
|
95
|
+
// No dropdown — single toggle button.
|
|
96
|
+
}
|
|
97
|
+
/**
|
|
98
|
+
* Append an empty paragraph wrapped in a new blockquote to the end of the
|
|
99
|
+
* content and place the caret inside it.
|
|
100
|
+
*
|
|
101
|
+
* @param {VegaRTEContent} content - Editor content to append to.
|
|
102
|
+
*/
|
|
103
|
+
appendEmptyBlockquote(content) {
|
|
104
|
+
if (content.children.length > 0) {
|
|
105
|
+
const lastBlock = content.children[content.children.length - 1];
|
|
106
|
+
const newBlock = RTETextBlock.from({
|
|
107
|
+
id: generateUUID(),
|
|
108
|
+
type: 'paragraph',
|
|
109
|
+
nodes: [{ id: generateUUID(), type: 'text', text: '' }],
|
|
110
|
+
});
|
|
111
|
+
content.apply(new InsertChildrenAfterAction(lastBlock, newBlock));
|
|
112
|
+
content.apply(new TransformToBlockquoteAction([newBlock]));
|
|
113
|
+
content.apply(new UpdateCursorPositionAction(newBlock.getLastNode(), 0));
|
|
114
|
+
}
|
|
115
|
+
}
|
|
116
|
+
/**
|
|
117
|
+
* Wrap the selection's unique parent blocks into a new blockquote. Blocks
|
|
118
|
+
* inside a list or other nested container escalate to the top-level block.
|
|
119
|
+
* When the selection spans multiple top-level (root) blocks, any scoped
|
|
120
|
+
* container touched along the way (e.g. a table cell) is treated as an
|
|
121
|
+
* opaque block instead of an independent wrap target — the whole
|
|
122
|
+
* selection wraps as one, and any blockquote nested deeper than the
|
|
123
|
+
* top-level block (e.g. inside a table cell) is left untouched. Existing
|
|
124
|
+
* top-level blockquote blocks in the selection are merged (flattened)
|
|
125
|
+
* into the new one rather than nested.
|
|
126
|
+
*
|
|
127
|
+
* @param {RTENode[]} selectedNodes - Currently selected nodes.
|
|
128
|
+
*/
|
|
129
|
+
wrapSelectedBlocks(selectedNodes) {
|
|
130
|
+
var _a, _b;
|
|
131
|
+
const uniqueBlocks = this.getUniqueBlocks(selectedNodes);
|
|
132
|
+
// If the selection spans more than one top-level block, force every
|
|
133
|
+
// anchor resolution to escalate all the way to the root, ignoring any
|
|
134
|
+
// scoped container (e.g. a table cell) it passes through.
|
|
135
|
+
const rootAncestors = new Set(uniqueBlocks.map((block) => { var _a; return (_a = this.resolveWrapAnchor(block, true).wrapBlock) !== null && _a !== void 0 ? _a : block; }));
|
|
136
|
+
const forceRootScope = rootAncestors.size > 1;
|
|
137
|
+
// Pass 1: unwrap any existing blockquote reachable from the selection so it merges instead of nesting.
|
|
138
|
+
const alreadyUnwrapped = new Set();
|
|
139
|
+
for (const block of uniqueBlocks) {
|
|
140
|
+
const { wrapBlock } = this.resolveWrapAnchor(block, forceRootScope);
|
|
141
|
+
if (wrapBlock instanceof RTEBlockquoteBlock && !alreadyUnwrapped.has(wrapBlock)) {
|
|
142
|
+
alreadyUnwrapped.add(wrapBlock);
|
|
143
|
+
wrapBlock.apply(new RemoveBlockquoteAction());
|
|
144
|
+
}
|
|
145
|
+
}
|
|
146
|
+
// Pass 2: group targets by their resolved container so each container is wrapped independently.
|
|
147
|
+
const containerMap = new Map();
|
|
148
|
+
for (const block of uniqueBlocks) {
|
|
149
|
+
const anchor = this.resolveWrapAnchor(block, forceRootScope);
|
|
150
|
+
const { container } = anchor;
|
|
151
|
+
if (container) {
|
|
152
|
+
const target = (_a = anchor.wrapBlock) !== null && _a !== void 0 ? _a : block;
|
|
153
|
+
const targets = (_b = containerMap.get(container)) !== null && _b !== void 0 ? _b : new Set();
|
|
154
|
+
targets.add(target);
|
|
155
|
+
containerMap.set(container, targets);
|
|
156
|
+
}
|
|
157
|
+
}
|
|
158
|
+
for (const [container, targets] of containerMap) {
|
|
159
|
+
container.apply(new TransformToBlockquoteAction([...targets]));
|
|
160
|
+
}
|
|
161
|
+
}
|
|
162
|
+
/**
|
|
163
|
+
* Resolve the starting node of the current toolbar selection, if any.
|
|
164
|
+
*
|
|
165
|
+
* @param {VegaRTEToolbarRenderContext} editorContext - Render context.
|
|
166
|
+
* @returns {Nullable<RTENode>} The first selected node, or null.
|
|
167
|
+
*/
|
|
168
|
+
getStartNode(editorContext) {
|
|
169
|
+
const context = this.getExtensionContext(editorContext.host);
|
|
170
|
+
return context === null || context === void 0 ? void 0 : context.getSelectedNodes()[0];
|
|
171
|
+
}
|
|
172
|
+
/**
|
|
173
|
+
* Collect the unique closest blockquote ancestors of every selected node.
|
|
174
|
+
* Multiple selected nodes that share the same blockquote ancestor collapse
|
|
175
|
+
* into a single entry, so applying {@link RemoveBlockquoteAction} to each
|
|
176
|
+
* result unwraps every distinct blockquote in the selection exactly once.
|
|
177
|
+
*
|
|
178
|
+
* @param {RTENode[]} nodes - Selected nodes.
|
|
179
|
+
* @returns {Set<RTEBlockquoteBlock>} Unique blockquote ancestors, preserving insertion order.
|
|
180
|
+
*/
|
|
181
|
+
collectBlockquoteAncestors(nodes) {
|
|
182
|
+
const ancestors = new Set();
|
|
183
|
+
nodes.forEach((node) => {
|
|
184
|
+
const ancestor = this.findBlockquoteAncestor(node);
|
|
185
|
+
if (ancestor) {
|
|
186
|
+
ancestors.add(ancestor);
|
|
187
|
+
}
|
|
188
|
+
});
|
|
189
|
+
return ancestors;
|
|
190
|
+
}
|
|
191
|
+
/**
|
|
192
|
+
* Walk up the block ancestors of the supplied node looking for an
|
|
193
|
+
* {@link RTEBlockquoteBlock}.
|
|
194
|
+
*
|
|
195
|
+
* @param {RTENode} node - Starting node.
|
|
196
|
+
* @returns {Nullable<RTEBlockquoteBlock>} The closest blockquote ancestor, or null.
|
|
197
|
+
*/
|
|
198
|
+
findBlockquoteAncestor(node) {
|
|
199
|
+
let current = node.parent;
|
|
200
|
+
while (current && !(current instanceof VegaRTEContent)) {
|
|
201
|
+
if (current instanceof RTEBlockquoteBlock) {
|
|
202
|
+
return current;
|
|
203
|
+
}
|
|
204
|
+
current = current.parent;
|
|
205
|
+
}
|
|
206
|
+
return null;
|
|
207
|
+
}
|
|
208
|
+
/**
|
|
209
|
+
* Collect unique block ancestors (immediate parent blocks) from a list of
|
|
210
|
+
* selected nodes, preserving order of first appearance.
|
|
211
|
+
*
|
|
212
|
+
* @param {RTENode[]} nodes - Selected nodes.
|
|
213
|
+
* @returns {RTEBlock[]} Unique parent blocks.
|
|
214
|
+
*/
|
|
215
|
+
getUniqueBlocks(nodes) {
|
|
216
|
+
const seen = new Set();
|
|
217
|
+
const result = [];
|
|
218
|
+
nodes.forEach((node) => {
|
|
219
|
+
const block = node.parent;
|
|
220
|
+
if (block && !seen.has(block)) {
|
|
221
|
+
seen.add(block);
|
|
222
|
+
result.push(block);
|
|
223
|
+
}
|
|
224
|
+
});
|
|
225
|
+
return result;
|
|
226
|
+
}
|
|
227
|
+
/**
|
|
228
|
+
* Walk up from `block` to find the nearest ancestor that is a direct child
|
|
229
|
+
* of a container registered to handle {@link TRANSFORM_TO_BLOCKQUOTE}
|
|
230
|
+
* (e.g. {@link VegaRTEContent}, {@link RTETableCellBlock}).
|
|
231
|
+
*
|
|
232
|
+
* Stops as soon as the parent can handle the wrap action, so that blocks
|
|
233
|
+
* inside a table cell are scoped to the cell (not escalated to the root)
|
|
234
|
+
* while blocks inside a list are still escalated to the top-level list.
|
|
235
|
+
* Pass `forceRootScope` to ignore scoped containers and always escalate
|
|
236
|
+
* to the root — used when the overall selection spans multiple top-level
|
|
237
|
+
* blocks, so a table (or any other scoped container) is wrapped as a
|
|
238
|
+
* single opaque block alongside its siblings instead of independently.
|
|
239
|
+
*
|
|
240
|
+
* @param {RTEBlock} block - Immediate parent block of the selected node.
|
|
241
|
+
* @param {boolean} [forceRootScope] - Ignore scoped containers and escalate to the root.
|
|
242
|
+
* @returns {WrapAnchor} `wrapBlock` is the top-level ancestor when the block
|
|
243
|
+
* is nested (otherwise null); `container` is the nearest wrap-capable parent.
|
|
244
|
+
*/
|
|
245
|
+
resolveWrapAnchor(block, forceRootScope = false) {
|
|
246
|
+
let current = block;
|
|
247
|
+
while (current.parent &&
|
|
248
|
+
!(current.parent instanceof VegaRTEContent) &&
|
|
249
|
+
(forceRootScope ||
|
|
250
|
+
!ActionHandleStrategyRegistry.canHandle(TRANSFORM_TO_BLOCKQUOTE, current.parent))) {
|
|
251
|
+
current = current.parent;
|
|
252
|
+
}
|
|
253
|
+
const wrapBlock = current !== block ? current : null;
|
|
254
|
+
const container = current.parent;
|
|
255
|
+
return { wrapBlock, container };
|
|
256
|
+
}
|
|
257
|
+
}
|
|
258
|
+
(() => {
|
|
259
|
+
VegaInternalIconManager.register({ 'quote-left': QuoteLeftIcon });
|
|
260
|
+
})();
|