@heartlandone/vega 2.71.0-RTE-table-preview → 2.72.0-RTE-table-preview
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-4d077e56.js +433 -0
- package/dist/cjs/child-nodes-event-prevent-slimmer-871855df.js +158 -0
- package/dist/cjs/code-block-bf3642ef.js +4436 -0
- package/dist/cjs/column-operation-1cac8386.js +1325 -0
- package/dist/cjs/component-value-history-controller-slimmer.abstract-ebecb74a.js +757 -0
- package/dist/cjs/date-required-rule-99cca681.js +92 -0
- package/dist/cjs/design-token-ac429fe9.js +402 -0
- package/dist/cjs/dom-node-subject-observer-factory-1c8f7880.js +305 -0
- package/dist/cjs/dto-renderer-manager-04428a77.js +3930 -0
- package/dist/cjs/element-appender-slimmer-1b062054.js +1508 -0
- package/dist/cjs/event-emit-slimmer-f7255138.js +267 -0
- package/dist/cjs/form-field-controller-slimmer-57525f26.js +1267 -0
- package/dist/cjs/image-annotation-action-7fa5d30d.js +312 -0
- package/dist/cjs/index-58ea899e.js +4 -4
- package/dist/cjs/index-c7fbf32b.js +43 -0
- package/dist/cjs/index.cjs.js +17 -19
- package/dist/cjs/inject-keyboard-manager-a6101379.js +37 -0
- package/dist/cjs/internal-vega-event-manager-0e1ba774.js +487 -0
- package/dist/cjs/keyboard-manager-d8adb0ed.js +140 -0
- package/dist/cjs/keyboard-manager-slimmer-15e65357.js +39 -0
- package/dist/cjs/language-extension-6ad0b5a0.js +210 -0
- package/dist/cjs/loader.cjs.js +14 -14
- package/dist/cjs/month-view-generator-706c5477.js +102 -0
- package/dist/cjs/public-rules-76bcf49c.js +47 -0
- package/dist/cjs/range-449bcdd0.js +178 -0
- package/dist/cjs/responsive-format-facade-e61c7f7e.js +925 -0
- package/dist/cjs/rich-text-editor-required-rule-40216fee.js +64 -0
- package/dist/cjs/string-format-strategy.abstract-a8264fca.js +60 -0
- package/dist/cjs/string-input-formatter-slimmer-4332d1c7.js +230 -0
- package/dist/cjs/string-mask-strategy-4e7d3780.js +172 -0
- package/dist/cjs/style-formatter-e2a0ad27.js +34 -0
- package/dist/cjs/sub-state-notify-slimmer-9fe1ab65.js +81 -0
- package/dist/cjs/sub-state-observer-slimmer-2f6f4d28.js +134 -0
- package/dist/cjs/table-extension-1f162c4c.js +4836 -0
- package/dist/cjs/time-required-rule-9d39a620.js +141 -0
- package/dist/cjs/type-guard-69d2cf01.js +1965 -0
- package/dist/cjs/valid-credit-card-number-rule-9f40d1d9.js +173 -0
- package/dist/cjs/vega-accordion.cjs.entry.js +12 -13
- package/dist/cjs/vega-app-header-button.cjs.entry.js +17 -18
- package/dist/cjs/vega-banner.cjs.entry.js +3 -3
- package/dist/cjs/vega-box.cjs.entry.js +16 -17
- package/dist/cjs/vega-breadcrumb.cjs.entry.js +4 -4
- package/dist/cjs/vega-button-circle.cjs.entry.js +16 -17
- package/dist/cjs/vega-button-group_2.cjs.entry.js +60 -10
- package/dist/cjs/vega-button-link.cjs.entry.js +5 -5
- package/dist/cjs/vega-button.cjs.entry.js +16 -16
- package/dist/cjs/vega-calendar_4.cjs.entry.js +87 -909
- package/dist/cjs/vega-card.cjs.entry.js +15 -16
- package/dist/cjs/vega-carousel.cjs.entry.js +15 -15
- package/dist/cjs/vega-checkbox_2.cjs.entry.js +7 -7
- package/dist/cjs/vega-chip.cjs.entry.js +17 -18
- package/dist/cjs/vega-code-block.cjs.entry.js +13 -13
- package/dist/cjs/vega-color-picker.cjs.entry.js +6 -6
- package/dist/cjs/vega-combo-box.cjs.entry.js +13 -13
- package/dist/cjs/vega-date-picker_2.cjs.entry.js +1758 -1568
- package/dist/cjs/vega-dialog_2.cjs.entry.js +14 -15
- package/dist/cjs/vega-divider.cjs.entry.js +11 -12
- package/dist/cjs/vega-dropdown_5.cjs.entry.js +18 -29
- package/dist/cjs/vega-env-manager-23b8b23c.js +2 -2
- package/dist/cjs/vega-field-label.cjs.entry.js +3 -3
- package/dist/cjs/vega-file-uploader.cjs.entry.js +6 -6
- package/dist/cjs/vega-flag-icon.cjs.entry.js +11 -12
- package/dist/cjs/vega-flex.cjs.entry.js +16 -17
- package/dist/cjs/vega-font.cjs.entry.js +15 -16
- package/dist/cjs/vega-form.cjs.entry.js +9 -9
- package/dist/cjs/vega-grid.cjs.entry.js +15 -16
- package/dist/cjs/vega-icon.cjs.entry.js +15 -16
- package/dist/cjs/vega-image-uploader.cjs.entry.js +16 -16
- package/dist/cjs/vega-input-credit-card.cjs.entry.js +14 -14
- package/dist/cjs/vega-input-numeric.cjs.entry.js +13 -13
- package/dist/cjs/vega-input-passcode.cjs.entry.js +12 -12
- package/dist/cjs/vega-input-phone-number.cjs.entry.js +14 -14
- package/dist/cjs/vega-input-range.cjs.entry.js +7 -7
- package/dist/cjs/vega-input-select.cjs.entry.js +14 -14
- package/dist/cjs/vega-input.cjs.entry.js +11 -11
- package/dist/cjs/vega-internal-event-id-a5ef414b.js +112 -0
- package/dist/cjs/vega-item-toggle.cjs.entry.js +3 -3
- package/dist/cjs/vega-left-nav_5.cjs.entry.js +15 -16
- package/dist/cjs/vega-loader-wrapper_2.cjs.entry.js +10 -10
- 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 +2 -2
- package/dist/cjs/vega-pagination.cjs.entry.js +13 -13
- package/dist/cjs/vega-popover_2.cjs.entry.js +21 -21
- package/dist/cjs/vega-progress-tracker_2.cjs.entry.js +905 -0
- package/dist/cjs/vega-radio_2.cjs.entry.js +10 -10
- package/dist/cjs/vega-rich-text-content.cjs.entry.js +9 -8
- package/dist/cjs/vega-rich-text-editor_5.cjs.entry.js +20 -20
- package/dist/cjs/vega-rich-text-table-selection-widget.cjs.entry.js +8 -3
- package/dist/cjs/vega-segment-control.cjs.entry.js +3 -3
- package/dist/cjs/vega-selection-chip_2.cjs.entry.js +17 -17
- package/dist/cjs/vega-selection-tile_2.cjs.entry.js +8 -8
- package/dist/cjs/vega-sidenav_3.cjs.entry.js +13 -13
- package/dist/cjs/vega-signature-capture.cjs.entry.js +14 -15
- package/dist/cjs/vega-stepper.cjs.entry.js +7 -7
- package/dist/cjs/vega-tab-group_2.cjs.entry.js +4 -4
- package/dist/cjs/vega-table_11.cjs.entry.js +13 -13
- package/dist/cjs/vega-textarea.cjs.entry.js +7 -7
- package/dist/cjs/vega-time-picker_2.cjs.entry.js +39 -40
- package/dist/cjs/vega-toggle-switch.cjs.entry.js +6 -6
- package/dist/cjs/vega-tooltip_2.cjs.entry.js +15 -15
- package/dist/cjs/vega.cjs.js +14 -14
- package/dist/collection/collection-manifest.json +7 -5
- package/dist/collection/components/vega-button/vega-button.css +4 -0
- package/dist/collection/components/vega-button-group/vega-button-group-item/slimmers/controllers/vega-button-group-item-sub-state-controller.js +7 -0
- package/dist/collection/components/vega-button-group/vega-button-group-item/slimmers/renderers/vega-button-group-item-renderer.js +25 -2
- package/dist/collection/components/vega-button-group/vega-button-group-item/vega-button-group-item.js +31 -2
- package/dist/collection/components/vega-button-group/vega-button-group.js +37 -0
- package/dist/collection/components/vega-button-link/vega-button-link.css +4 -0
- package/dist/collection/components/vega-date-picker/slimmers/controllers/vega-date-picker-calendar-open-state-controller.js +149 -0
- package/dist/collection/components/vega-date-picker/slimmers/controllers/vega-date-picker-format-controller.js +3 -1
- package/dist/collection/components/vega-date-picker/slimmers/controllers/vega-date-picker-keyboard-controller.js +1 -1
- package/dist/collection/components/vega-date-picker/slimmers/controllers/vega-date-picker-value-controller.js +10 -26
- package/dist/collection/components/vega-date-picker/slimmers/renderers/vega-date-picker-calendar-renderer.js +107 -445
- package/dist/collection/components/vega-date-picker/slimmers/renderers/vega-date-picker-input-renderer-base.abstract.js +5 -1
- package/dist/collection/components/vega-date-picker/slimmers/renderers/vega-date-picker-range-input-renderer.js +24 -17
- package/dist/collection/components/vega-date-picker/slimmers/renderers/vega-date-picker-renderer.js +15 -20
- package/dist/collection/components/vega-date-picker/slimmers/renderers/vega-date-picker-single-input-renderer.js +6 -17
- package/dist/collection/components/vega-date-picker/vega-date-picker-calendar/constants.js +14 -0
- package/dist/collection/components/vega-date-picker/vega-date-picker-calendar/dto/calendar-selection.js +126 -0
- package/dist/collection/components/vega-date-picker/vega-date-picker-calendar/slimmers/controllers/vega-date-picker-calendar-allow-repick-controller.js +70 -0
- package/dist/collection/components/vega-date-picker/vega-date-picker-calendar/slimmers/controllers/vega-date-picker-calendar-current-period-controller.js +204 -0
- package/dist/collection/components/vega-date-picker/vega-date-picker-calendar/slimmers/controllers/vega-date-picker-calendar-min-max-date-controller.js +56 -0
- package/dist/collection/components/vega-date-picker/vega-date-picker-calendar/slimmers/controllers/vega-date-picker-calendar-selection-controller.js +191 -0
- package/dist/collection/components/vega-date-picker/vega-date-picker-calendar/slimmers/controllers/vega-date-picker-calendar-state-base.abstract.js +54 -0
- package/dist/collection/components/vega-date-picker/vega-date-picker-calendar/slimmers/controllers/vega-date-picker-calendar-today-controller.js +37 -0
- package/dist/collection/components/vega-date-picker/vega-date-picker-calendar/slimmers/renderers/vega-date-picker-calendar-renderer.js +76 -0
- package/dist/collection/components/vega-date-picker/vega-date-picker-calendar/slimmers/renderers/vega-date-picker-calendar-year-month-switcher-renderer.js +192 -0
- package/dist/collection/components/vega-date-picker/vega-date-picker-calendar/slimmers/renderers/vega-date-picker-month-item-renderer.js +168 -0
- package/dist/collection/components/vega-date-picker/vega-date-picker-calendar/vega-date-picker-calendar.css +669 -278
- package/dist/collection/components/vega-date-picker/vega-date-picker-calendar/vega-date-picker-calendar.js +667 -3
- package/dist/collection/components/vega-date-picker/vega-date-picker.css +0 -11
- package/dist/collection/components/vega-date-picker/vega-date-picker.js +23 -40
- package/dist/collection/components/vega-dropdown/slimmers/controllers/vega-dropdown-appender-controller.js +3 -15
- package/dist/collection/components/vega-input/vega-input.js +1 -1
- package/dist/collection/components/vega-input-phone-number/slimmers/renderers/phone-number-input-renderer.js +1 -1
- package/dist/collection/components/vega-input-select/vega-input-select.js +1 -1
- package/dist/collection/components/vega-popover/vega-popover.js +14 -4
- package/dist/collection/components/vega-progress-tracker/slimmers/controllers/dto/internal-progress-tracker-step.js +75 -0
- package/dist/collection/components/vega-progress-tracker/slimmers/controllers/vega-progress-tracker-current-direction-controller.js +88 -0
- package/dist/collection/components/vega-progress-tracker/slimmers/controllers/vega-progress-tracker-current-step-controller.js +153 -0
- package/dist/collection/components/vega-progress-tracker/slimmers/controllers/vega-progress-tracker-current-steps-controller.js +125 -0
- package/dist/collection/components/vega-progress-tracker/slimmers/controllers/vega-progress-tracker-render-mode-controller.js +40 -0
- package/dist/collection/components/vega-progress-tracker/slimmers/renderers/vega-progress-tracker-renderer.js +94 -0
- package/dist/collection/components/vega-progress-tracker/vega-progress-tracker-step/slimmers/controllers/vega-progress-tracker-step-state-controller.js +43 -0
- package/dist/collection/components/vega-progress-tracker/vega-progress-tracker-step/vega-progress-tracker-step.css +79 -0
- package/dist/collection/components/vega-progress-tracker/vega-progress-tracker-step/vega-progress-tracker-step.js +84 -0
- package/dist/collection/components/vega-progress-tracker/vega-progress-tracker.css +69 -153
- package/dist/collection/components/vega-progress-tracker/vega-progress-tracker.js +88 -85
- package/dist/collection/components/vega-rich-text-editor/dto/annotations/text-style-annotation.js +11 -63
- package/dist/collection/components/vega-rich-text-editor/extensions/tokens/insert-token-node-strategy.js +5 -1
- package/dist/collection/components/vega-rich-text-editor/extensions/tokens/span-to-token-node-strategy.js +12 -1
- package/dist/collection/components/vega-rich-text-editor/extensions/tokens/token-node-renderer.js +16 -10
- package/dist/collection/components/vega-rich-text-editor/extensions/tokens/token-node.js +1 -1
- package/dist/collection/components/vega-rich-text-editor/test/dto/annotation-style.test.js +2 -1
- package/dist/collection/components/vega-rich-text-editor/test/dto/annotations.test.js +9 -0
- package/dist/collection/components/vega-rich-text-editor/test/dto/blocks/text-block.test.js +1 -1
- package/dist/collection/components/vega-rich-text-editor/test/dto/content-state.test.js +15 -15
- package/dist/collection/constants/regex.js +1 -0
- package/dist/collection/constants/ui.js +3 -0
- package/dist/collection/helpers/calendar/calendar-date.js +273 -1
- package/dist/collection/helpers/calendar/calendar-period/calendar-period.abstract.js +9 -0
- package/dist/collection/helpers/calendar/calendar-period/month-period.js +16 -4
- package/dist/collection/helpers/calendar/test/calendar-date.test.js +73 -0
- package/dist/collection/helpers/calendar/test/calendar-period/day-period.test.js +9 -0
- package/dist/collection/helpers/calendar/test/calendar-period/month-period.test.js +41 -0
- package/dist/collection/helpers/calendar/test/calendar-period/week-period.test.js +11 -0
- package/dist/collection/helpers/event-manager/event-id/component-event-id-map.js +3 -2
- package/dist/collection/helpers/event-manager/event-id/vega-event-id.js +3 -1
- package/dist/collection/helpers/event-manager/event-id/vega-internal-event-id.js +5 -2
- package/dist/collection/helpers/slimmers/element-appender/element-appender-slimmer.js +2 -1
- package/dist/collection/helpers/slimmers/position-calculation/position-calculation-controller.js +7 -0
- package/dist/collection/helpers/ui/element-appender.js +35 -5
- package/dist/collection/types/type-guard.js +10 -0
- package/dist/collection/utils/date.js +14 -3
- package/dist/collection/utils/e2e-utils.js +8 -2
- package/dist/collection/utils/test/date.test.js +2 -0
- package/dist/esm/app-globals-e7a8d0cc.js +431 -0
- package/dist/esm/child-nodes-event-prevent-slimmer-9ae34332.js +156 -0
- package/dist/esm/code-block-3d3a9030.js +4378 -0
- package/dist/esm/column-operation-4a93bf52.js +1300 -0
- package/dist/esm/component-value-history-controller-slimmer.abstract-d84e7bab.js +751 -0
- package/dist/esm/date-required-rule-a9980386.js +90 -0
- package/dist/esm/design-token-1575f6d9.js +388 -0
- package/dist/esm/dom-node-subject-observer-factory-f81f215f.js +248 -0
- package/dist/esm/dto-renderer-manager-23784148.js +3910 -0
- package/dist/esm/element-appender-slimmer-1a50e184.js +1506 -0
- package/dist/esm/event-emit-slimmer-966716fa.js +265 -0
- package/dist/esm/form-field-controller-slimmer-0020997d.js +1265 -0
- package/dist/esm/image-annotation-action-dba16587.js +306 -0
- package/dist/esm/index-090d31ca.js +4 -4
- package/dist/esm/index-d72e7fb3.js +40 -0
- package/dist/esm/index.js +19 -21
- package/dist/esm/inject-keyboard-manager-9241968c.js +35 -0
- package/dist/esm/internal-vega-event-manager-4f51b17c.js +483 -0
- package/dist/esm/keyboard-manager-89acac79.js +138 -0
- package/dist/esm/keyboard-manager-slimmer-e303cb7d.js +37 -0
- package/dist/esm/language-extension-710fe56d.js +207 -0
- package/dist/esm/loader.js +16 -16
- package/dist/esm/month-view-generator-4bec99fd.js +98 -0
- package/dist/esm/page-resize-observer-slimmer-8744cb44.js +171 -0
- package/dist/esm/public-rules-522ba4b1.js +32 -0
- package/dist/esm/range-cdd85d30.js +176 -0
- package/dist/esm/responsive-format-facade-405f90d2.js +921 -0
- package/dist/esm/rich-text-editor-required-rule-7d2d9615.js +62 -0
- package/dist/esm/string-format-strategy.abstract-75540c16.js +58 -0
- package/dist/esm/string-input-formatter-slimmer-96ccc8cf.js +228 -0
- package/dist/esm/string-mask-strategy-4a18ed1a.js +170 -0
- package/dist/esm/style-formatter-52cd20f7.js +32 -0
- package/dist/esm/sub-state-notify-slimmer-97953a87.js +79 -0
- package/dist/esm/sub-state-observer-slimmer-3f2b954f.js +132 -0
- package/dist/esm/table-extension-164b0d6c.js +4816 -0
- package/dist/esm/time-required-rule-8ec1faf5.js +138 -0
- package/dist/esm/type-guard-b48aec98.js +1894 -0
- package/dist/esm/ui-28fd4193.js +38 -0
- package/dist/esm/valid-credit-card-number-rule-96eaf9b1.js +171 -0
- package/dist/esm/vega-accordion.entry.js +14 -15
- package/dist/esm/vega-app-header-button.entry.js +19 -20
- package/dist/esm/vega-banner.entry.js +3 -3
- package/dist/esm/vega-box.entry.js +18 -19
- package/dist/esm/vega-breadcrumb.entry.js +4 -4
- package/dist/esm/vega-button-circle.entry.js +18 -19
- package/dist/esm/vega-button-group_2.entry.js +60 -10
- package/dist/esm/vega-button-link.entry.js +5 -5
- package/dist/esm/vega-button.entry.js +18 -18
- package/dist/esm/vega-calendar_4.entry.js +46 -868
- package/dist/esm/vega-card.entry.js +17 -18
- package/dist/esm/vega-carousel.entry.js +17 -17
- package/dist/esm/vega-checkbox_2.entry.js +9 -9
- package/dist/esm/vega-chip.entry.js +19 -20
- package/dist/esm/vega-code-block.entry.js +14 -14
- package/dist/esm/vega-color-picker.entry.js +8 -8
- package/dist/esm/vega-combo-box.entry.js +15 -15
- package/dist/esm/vega-date-picker_2.entry.js +1745 -1555
- package/dist/esm/vega-dialog_2.entry.js +16 -17
- package/dist/esm/vega-divider.entry.js +13 -14
- package/dist/esm/vega-dropdown_5.entry.js +20 -31
- package/dist/esm/vega-env-manager-8f8dc473.js +2 -2
- package/dist/esm/vega-field-label.entry.js +3 -3
- package/dist/esm/vega-file-uploader.entry.js +8 -8
- package/dist/esm/vega-flag-icon.entry.js +13 -14
- package/dist/esm/vega-flex.entry.js +18 -19
- package/dist/esm/vega-font.entry.js +17 -18
- package/dist/esm/vega-form.entry.js +11 -11
- package/dist/esm/vega-grid.entry.js +17 -18
- package/dist/esm/vega-icon.entry.js +17 -18
- package/dist/esm/vega-image-uploader.entry.js +18 -18
- package/dist/esm/vega-input-credit-card.entry.js +16 -16
- package/dist/esm/vega-input-numeric.entry.js +15 -15
- package/dist/esm/vega-input-passcode.entry.js +14 -14
- package/dist/esm/vega-input-phone-number.entry.js +16 -16
- package/dist/esm/vega-input-range.entry.js +9 -9
- package/dist/esm/vega-input-select.entry.js +16 -16
- package/dist/esm/vega-input.entry.js +13 -13
- package/dist/esm/vega-internal-event-id-54ce7562.js +66 -0
- package/dist/esm/vega-item-toggle.entry.js +4 -4
- package/dist/esm/vega-left-nav_5.entry.js +17 -18
- package/dist/esm/vega-loader-wrapper_2.entry.js +12 -12
- package/dist/esm/vega-page-notification_2.entry.js +1 -1
- package/dist/esm/vega-pagination-page-selector-mobile.entry.js +4 -4
- package/dist/esm/vega-pagination-page-size-selector-mobile.entry.js +2 -2
- package/dist/esm/vega-pagination.entry.js +15 -15
- package/dist/esm/vega-popover_2.entry.js +23 -23
- package/dist/esm/vega-progress-tracker_2.entry.js +900 -0
- package/dist/esm/vega-radio_2.entry.js +12 -12
- package/dist/esm/vega-rich-text-content.entry.js +10 -9
- package/dist/esm/vega-rich-text-editor_5.entry.js +22 -22
- package/dist/esm/vega-rich-text-table-selection-widget.entry.js +9 -4
- package/dist/esm/vega-segment-control.entry.js +5 -5
- package/dist/esm/vega-selection-chip_2.entry.js +19 -19
- package/dist/esm/vega-selection-tile_2.entry.js +10 -10
- package/dist/esm/vega-sidenav_3.entry.js +15 -15
- package/dist/esm/vega-signature-capture.entry.js +16 -17
- package/dist/esm/vega-stepper.entry.js +9 -9
- package/dist/esm/vega-tab-group_2.entry.js +6 -6
- package/dist/esm/vega-table_11.entry.js +15 -15
- package/dist/esm/vega-text.entry.js +2 -2
- package/dist/esm/vega-textarea.entry.js +9 -9
- package/dist/esm/vega-time-picker_2.entry.js +20 -21
- package/dist/esm/vega-toggle-switch.entry.js +8 -8
- package/dist/esm/vega-tooltip_2.entry.js +17 -17
- package/dist/esm/vega.js +16 -16
- package/dist/sri/vega-sri-manifest.json +349 -357
- package/dist/types/components/vega-button-group/types.d.ts +2 -1
- package/dist/types/components/vega-button-group/vega-button-group-item/slimmers/controllers/vega-button-group-item-sub-state-controller.d.ts +1 -0
- package/dist/types/components/vega-button-group/vega-button-group-item/slimmers/renderers/vega-button-group-item-renderer.d.ts +11 -0
- package/dist/types/components/vega-button-group/vega-button-group-item/vega-button-group-item.d.ts +7 -0
- package/dist/types/components/vega-button-group/vega-button-group.d.ts +8 -0
- package/dist/types/components/vega-date-picker/slimmers/controllers/vega-date-picker-calendar-open-state-controller.d.ts +60 -0
- package/dist/types/components/vega-date-picker/slimmers/controllers/vega-date-picker-value-controller.d.ts +3 -4
- package/dist/types/components/vega-date-picker/slimmers/renderers/vega-date-picker-calendar-renderer.d.ts +29 -124
- package/dist/types/components/vega-date-picker/slimmers/renderers/vega-date-picker-input-renderer-base.abstract.d.ts +1 -0
- package/dist/types/components/vega-date-picker/slimmers/renderers/vega-date-picker-range-input-renderer.d.ts +5 -5
- package/dist/types/components/vega-date-picker/slimmers/renderers/vega-date-picker-renderer.d.ts +2 -3
- package/dist/types/components/vega-date-picker/slimmers/renderers/vega-date-picker-single-input-renderer.d.ts +1 -4
- package/dist/types/components/vega-date-picker/types.d.ts +9 -0
- package/dist/types/components/vega-date-picker/vega-date-picker-calendar/constants.d.ts +1 -0
- package/dist/types/components/vega-date-picker/vega-date-picker-calendar/dto/calendar-selection.d.ts +62 -0
- package/dist/types/components/vega-date-picker/vega-date-picker-calendar/slimmers/controllers/vega-date-picker-calendar-allow-repick-controller.d.ts +31 -0
- package/dist/types/components/vega-date-picker/vega-date-picker-calendar/slimmers/controllers/vega-date-picker-calendar-current-period-controller.d.ts +78 -0
- package/dist/types/components/vega-date-picker/vega-date-picker-calendar/slimmers/controllers/vega-date-picker-calendar-min-max-date-controller.d.ts +20 -0
- package/dist/types/components/vega-date-picker/vega-date-picker-calendar/slimmers/controllers/vega-date-picker-calendar-selection-controller.d.ts +75 -0
- package/dist/types/components/vega-date-picker/vega-date-picker-calendar/slimmers/controllers/vega-date-picker-calendar-state-base.abstract.d.ts +29 -0
- package/dist/types/components/vega-date-picker/vega-date-picker-calendar/slimmers/controllers/vega-date-picker-calendar-today-controller.d.ts +15 -0
- package/dist/types/components/vega-date-picker/vega-date-picker-calendar/slimmers/renderers/vega-date-picker-calendar-renderer.d.ts +18 -0
- package/dist/types/components/vega-date-picker/vega-date-picker-calendar/slimmers/renderers/vega-date-picker-calendar-year-month-switcher-renderer.d.ts +40 -0
- package/dist/types/components/vega-date-picker/vega-date-picker-calendar/slimmers/renderers/vega-date-picker-month-item-renderer.d.ts +32 -0
- package/dist/types/components/vega-date-picker/vega-date-picker-calendar/vega-date-picker-calendar.d.ts +182 -0
- package/dist/types/components/vega-date-picker/vega-date-picker.d.ts +6 -14
- package/dist/types/components/vega-dropdown/slimmers/controllers/vega-dropdown-appender-controller.d.ts +0 -4
- package/dist/types/components/vega-input/vega-input.d.ts +1 -1
- package/dist/types/components/vega-popover/vega-popover.d.ts +2 -1
- package/dist/types/components/vega-progress-tracker/slimmers/controllers/dto/internal-progress-tracker-step.d.ts +55 -0
- package/dist/types/components/vega-progress-tracker/slimmers/controllers/vega-progress-tracker-current-direction-controller.d.ts +27 -0
- package/dist/types/components/vega-progress-tracker/slimmers/controllers/vega-progress-tracker-current-step-controller.d.ts +63 -0
- package/dist/types/components/vega-progress-tracker/slimmers/controllers/vega-progress-tracker-current-steps-controller.d.ts +39 -0
- package/dist/types/components/vega-progress-tracker/slimmers/controllers/vega-progress-tracker-render-mode-controller.d.ts +21 -0
- package/dist/types/components/vega-progress-tracker/slimmers/renderers/vega-progress-tracker-renderer.d.ts +21 -0
- package/dist/types/components/vega-progress-tracker/type.d.ts +1 -0
- package/dist/types/components/vega-progress-tracker/vega-progress-tracker-step/slimmers/controllers/vega-progress-tracker-step-state-controller.d.ts +12 -0
- package/dist/types/components/vega-progress-tracker/vega-progress-tracker-step/vega-progress-tracker-step.d.ts +22 -0
- package/dist/types/components/vega-progress-tracker/vega-progress-tracker.d.ts +24 -10
- package/dist/types/components/vega-rich-text-editor/dto/annotations/text-style-annotation.d.ts +7 -0
- package/dist/types/components/vega-rich-text-editor/extensions/tokens/span-to-token-node-strategy.d.ts +7 -0
- package/dist/types/components/vega-rich-text-editor/extensions/tokens/token-extension.d.ts +1 -1
- package/dist/types/components/vega-rich-text-editor/extensions/tokens/token-node-renderer.d.ts +7 -0
- package/dist/types/components/vega-rich-text-editor/extensions/tokens/token-toolbar-button-renderer.d.ts +2 -2
- package/dist/types/components/vega-rich-text-editor/interface.d.ts +6 -1
- package/dist/types/components.d.ts +224 -8
- package/dist/types/constants/regex.d.ts +1 -0
- package/dist/types/constants/ui.d.ts +1 -1
- package/dist/types/helpers/calendar/calendar-date.d.ts +86 -2
- package/dist/types/helpers/calendar/calendar-period/calendar-period.abstract.d.ts +7 -0
- package/dist/types/helpers/event-manager/event-id/vega-event-id.d.ts +3 -1
- package/dist/types/helpers/event-manager/event-id/vega-internal-event-id.d.ts +5 -2
- package/dist/types/helpers/ui/element-appender.d.ts +14 -0
- package/dist/types/types/components.type.d.ts +4 -0
- package/dist/types/types/type-guard.d.ts +8 -0
- package/dist/types/utils/date.d.ts +11 -2
- package/dist/types/utils/e2e-utils.d.ts +7 -0
- package/dist/vega/index.esm.js +1 -1
- package/dist/vega/p-09561e90.entry.js +1 -0
- package/dist/vega/p-095c778c.entry.js +1 -0
- package/dist/vega/p-0bca50ab.entry.js +1 -0
- package/dist/vega/p-10ac8b57.js +1 -0
- package/dist/vega/p-11a7daad.entry.js +1 -0
- package/dist/vega/p-1282b67e.js +1 -0
- package/dist/vega/p-137e5c70.entry.js +1 -0
- package/dist/vega/p-161b9c5b.js +1 -0
- package/dist/vega/p-174db33b.js +1 -0
- package/dist/vega/p-1815e753.entry.js +1 -0
- package/dist/vega/p-18bcfd7a.js +1 -0
- package/dist/vega/p-194722fe.entry.js +1 -0
- package/dist/vega/p-1be7c6c4.js +1 -0
- package/dist/vega/p-1c33d25e.entry.js +1 -0
- package/dist/vega/p-1dd07d64.entry.js +1 -0
- package/dist/vega/p-1e0d8228.entry.js +1 -0
- package/dist/vega/p-207cfa6a.js +1 -0
- package/dist/vega/p-218e29c2.js +1 -0
- package/dist/vega/p-2249b040.entry.js +1 -0
- package/dist/vega/p-23183d4d.js +1 -0
- package/dist/vega/p-238ec2b9.entry.js +1 -0
- package/dist/vega/p-2428457e.entry.js +1 -0
- package/dist/vega/p-263ad7b6.js +1 -0
- package/dist/vega/p-2688bc6f.entry.js +1 -0
- package/dist/vega/p-26a43b4c.js +1 -0
- package/dist/vega/p-285815b5.entry.js +1 -0
- package/dist/vega/p-2c07b213.entry.js +1 -0
- package/dist/vega/p-31a65402.entry.js +1 -0
- package/dist/vega/p-34a1a0c5.entry.js +1 -0
- package/dist/vega/p-3d85411d.js +1 -0
- package/dist/vega/p-3f561dd5.entry.js +1 -0
- package/dist/vega/p-40f39194.js +1 -0
- package/dist/vega/p-475f7bda.js +1 -0
- package/dist/vega/p-4785203e.entry.js +1 -0
- package/dist/vega/p-5051f0c1.entry.js +1 -0
- package/dist/vega/p-529daab4.entry.js +1 -0
- package/dist/vega/p-53c6ce54.entry.js +1 -0
- package/dist/vega/p-5504ebdf.js +1 -0
- package/dist/vega/p-5585d2b5.js +1 -0
- package/dist/vega/p-56ce0c4b.entry.js +1 -0
- package/dist/vega/p-58f5da43.js +1 -0
- package/dist/vega/p-596895ec.js +1 -0
- package/dist/vega/p-5b472921.js +1 -0
- package/dist/vega/p-5d7e908a.entry.js +1 -0
- package/dist/vega/p-5f377954.js +1 -1
- package/dist/vega/p-5fb6a3b5.js +1 -0
- package/dist/vega/p-63c84ff6.entry.js +1 -0
- package/dist/vega/p-6961fac0.entry.js +1 -0
- package/dist/vega/p-699e46d1.entry.js +1 -0
- package/dist/vega/p-6aa7ace9.js +1 -0
- package/dist/vega/p-6b631ff1.entry.js +1 -0
- package/dist/vega/p-6c1ef2ed.js +1 -0
- package/dist/vega/p-6ee3b103.js +1 -0
- package/dist/vega/p-71f2235e.js +1 -0
- package/dist/vega/p-776b2f3d.entry.js +1 -0
- package/dist/vega/p-7ac32e71.js +1 -0
- package/dist/vega/p-7e6c5eb8.entry.js +1 -0
- package/dist/vega/p-7eaa8ac0.entry.js +1 -0
- package/dist/vega/p-8014cb45.entry.js +1 -0
- package/dist/vega/p-877b36ae.entry.js +1 -0
- package/dist/vega/p-883c5174.entry.js +1 -0
- package/dist/vega/p-8b969a71.entry.js +1 -0
- package/dist/vega/p-8f6d42b0.entry.js +1 -0
- package/dist/vega/p-8feb1298.entry.js +1 -0
- package/dist/vega/p-95188267.entry.js +1 -0
- package/dist/vega/p-96aa0f3b.js +1 -0
- package/dist/vega/p-9a83a6b0.js +1 -0
- package/dist/vega/p-9e2cf904.entry.js +1 -0
- package/dist/vega/p-9e545fde.entry.js +1 -0
- package/dist/vega/p-9f4364ec.entry.js +1 -0
- package/dist/vega/p-a33dc7eb.entry.js +1 -0
- package/dist/vega/p-a3a80712.js +1 -0
- package/dist/vega/p-a4ec6575.js +1 -0
- package/dist/vega/p-a8dad05d.js +1 -0
- package/dist/vega/p-b47df664.js +1 -0
- package/dist/vega/p-b737b93a.entry.js +1 -0
- package/dist/vega/p-baa44cf5.entry.js +1 -0
- package/dist/vega/p-badc14cc.entry.js +1 -0
- package/dist/vega/p-bc2451f7.entry.js +1 -0
- package/dist/vega/p-bdb5362c.entry.js +1 -0
- package/dist/vega/p-be33db7b.js +1 -0
- package/dist/vega/p-bfe01850.js +1 -0
- package/dist/vega/p-c141b10e.entry.js +1 -0
- package/dist/vega/p-c465b6dd.entry.js +1 -0
- package/dist/vega/p-d1d0f08a.js +1 -0
- package/dist/vega/p-d6032515.entry.js +1 -0
- package/dist/vega/p-d69a6454.entry.js +1 -0
- package/dist/vega/p-d6cc786a.entry.js +1 -0
- package/dist/vega/p-d85d7862.entry.js +1 -0
- package/dist/vega/p-d991fb11.js +1 -0
- package/dist/vega/p-da77d71f.entry.js +1 -0
- package/dist/vega/p-de70aac1.js +1 -0
- package/dist/vega/p-e47ae7bc.entry.js +1 -0
- package/dist/vega/p-e8495b6c.entry.js +1 -0
- package/dist/vega/p-e8654ab5.entry.js +1 -0
- package/dist/vega/p-e94701e2.entry.js +1 -0
- package/dist/vega/p-e9e1293a.entry.js +1 -0
- package/dist/vega/p-ef48178e.entry.js +1 -0
- package/dist/vega/p-f729743c.entry.js +9 -0
- package/dist/vega/p-fb6b3b98.js +1 -0
- package/dist/vega/p-fca7c998.entry.js +1 -0
- package/dist/vega/vega.esm.js +1 -1
- package/package.json +2 -3
- package/style/vega-icons.css +17266 -0
- package/dist/cjs/app-globals-246e5160.js +0 -432
- package/dist/cjs/child-nodes-event-prevent-slimmer-f8840f1b.js +0 -158
- package/dist/cjs/code-block-36fb0e69.js +0 -4488
- package/dist/cjs/column-operation-aa0673f6.js +0 -1325
- package/dist/cjs/component-value-history-controller-slimmer.abstract-eec38ad7.js +0 -757
- package/dist/cjs/date-0a6bb035.js +0 -95
- package/dist/cjs/date-required-rule-4e1f84fd.js +0 -92
- package/dist/cjs/design-token-6f95b09f.js +0 -403
- package/dist/cjs/dom-node-subject-observer-factory-f040608b.js +0 -301
- package/dist/cjs/dto-renderer-manager-fbc93cb5.js +0 -3930
- package/dist/cjs/element-appender-slimmer-ec537994.js +0 -1470
- package/dist/cjs/event-emit-slimmer-7afe8d78.js +0 -267
- package/dist/cjs/form-field-controller-slimmer-f865d397.js +0 -1267
- package/dist/cjs/image-annotation-action-ae1310ef.js +0 -312
- package/dist/cjs/index-4b896e76.js +0 -43
- package/dist/cjs/inject-keyboard-manager-13c66257.js +0 -37
- package/dist/cjs/internal-vega-event-manager-45d451de.js +0 -486
- package/dist/cjs/keyboard-manager-af0d08a6.js +0 -140
- package/dist/cjs/keyboard-manager-slimmer-62f072cd.js +0 -39
- package/dist/cjs/language-extension-2df8cfd3.js +0 -210
- package/dist/cjs/mobilefriendly-aa2e50e9.js +0 -13
- package/dist/cjs/public-rules-6432194e.js +0 -47
- package/dist/cjs/range-d24916d7.js +0 -178
- package/dist/cjs/responsive-format-facade-0b610205.js +0 -925
- package/dist/cjs/rich-text-editor-required-rule-eb34a576.js +0 -64
- package/dist/cjs/state-background-color-formatter-aa5570f6.js +0 -85
- package/dist/cjs/string-format-strategy.abstract-07a95352.js +0 -60
- package/dist/cjs/string-input-formatter-slimmer-8236b5e1.js +0 -230
- package/dist/cjs/string-mask-strategy-6bdad95e.js +0 -172
- package/dist/cjs/style-formatter-1450a252.js +0 -34
- package/dist/cjs/sub-state-notify-slimmer-78682046.js +0 -81
- package/dist/cjs/sub-state-observer-slimmer-73aecfff.js +0 -134
- package/dist/cjs/table-extension-3b713932.js +0 -4815
- package/dist/cjs/time-required-rule-ccf178e7.js +0 -141
- package/dist/cjs/type-guard-f12b5bae.js +0 -742
- package/dist/cjs/valid-credit-card-number-rule-ce5c9147.js +0 -173
- package/dist/cjs/vega-internal-event-id-6d4a2c53.js +0 -110
- package/dist/cjs/vega-progress-tracker.cjs.entry.js +0 -252
- package/dist/collection/components/vega-date-picker/slimmers/controllers/vega-date-picker-calendar-controller.js +0 -282
- package/dist/collection/components/vega-date-picker/slimmers/controllers/vega-date-picker-element-appender-controller.js +0 -35
- package/dist/collection/components/vega-date-picker/slimmers/controllers/vega-date-picker-mobile-controller.js +0 -53
- package/dist/collection/components/vega-date-picker/slimmers/controllers/vega-date-picker-month-year-change-event-controller.js +0 -139
- package/dist/collection/components/vega-date-picker/slimmers/controllers/vega-date-picker-zindex-controller.js +0 -49
- package/dist/collection/components/vega-date-picker/slimmers/renderers/vega-date-picker-calendar-month-year-dropdown-renderer.js +0 -341
- package/dist/esm/app-globals-e3ba8241.js +0 -430
- package/dist/esm/child-nodes-event-prevent-slimmer-66a11e63.js +0 -156
- package/dist/esm/code-block-f2f0cff5.js +0 -4430
- package/dist/esm/column-operation-9805e482.js +0 -1300
- package/dist/esm/component-value-history-controller-slimmer.abstract-400e0bd2.js +0 -751
- package/dist/esm/date-c55b97f0.js +0 -87
- package/dist/esm/date-required-rule-8944f3bf.js +0 -90
- package/dist/esm/design-token-6f4086a9.js +0 -389
- package/dist/esm/dom-node-subject-observer-factory-4401eb10.js +0 -246
- package/dist/esm/dto-renderer-manager-8b93cc6f.js +0 -3910
- package/dist/esm/element-appender-slimmer-cc465622.js +0 -1468
- package/dist/esm/event-emit-slimmer-7fade5b2.js +0 -265
- package/dist/esm/form-field-controller-slimmer-d88dc81a.js +0 -1265
- package/dist/esm/image-annotation-action-f62cfec3.js +0 -306
- package/dist/esm/index-e7660797.js +0 -40
- package/dist/esm/inject-keyboard-manager-ffd351b9.js +0 -35
- package/dist/esm/internal-vega-event-manager-c171f709.js +0 -482
- package/dist/esm/keyboard-manager-5d8f3582.js +0 -138
- package/dist/esm/keyboard-manager-slimmer-f39214e4.js +0 -37
- package/dist/esm/language-extension-87abdcf0.js +0 -207
- package/dist/esm/mobilefriendly-c5d0573d.js +0 -11
- package/dist/esm/page-resize-observer-slimmer-0bf7fbf3.js +0 -171
- package/dist/esm/public-rules-b6ad63e6.js +0 -32
- package/dist/esm/range-686c5d0c.js +0 -176
- package/dist/esm/responsive-format-facade-603dddd7.js +0 -921
- package/dist/esm/rich-text-editor-required-rule-4d14da42.js +0 -62
- package/dist/esm/state-background-color-formatter-0f01d27a.js +0 -82
- package/dist/esm/string-format-strategy.abstract-452f4398.js +0 -58
- package/dist/esm/string-input-formatter-slimmer-47305317.js +0 -228
- package/dist/esm/string-mask-strategy-6232a1c1.js +0 -170
- package/dist/esm/style-formatter-d76a67cb.js +0 -32
- package/dist/esm/sub-state-notify-slimmer-0a927f34.js +0 -79
- package/dist/esm/sub-state-observer-slimmer-33e0dd73.js +0 -132
- package/dist/esm/table-extension-5da1a8db.js +0 -4795
- package/dist/esm/time-required-rule-a01163b5.js +0 -138
- package/dist/esm/type-guard-12f7654b.js +0 -692
- package/dist/esm/ui-8424715a.js +0 -38
- package/dist/esm/valid-credit-card-number-rule-81443274.js +0 -171
- package/dist/esm/vega-internal-event-id-49fef150.js +0 -65
- package/dist/esm/vega-progress-tracker.entry.js +0 -248
- package/dist/types/components/vega-date-picker/slimmers/controllers/vega-date-picker-calendar-controller.d.ts +0 -96
- package/dist/types/components/vega-date-picker/slimmers/controllers/vega-date-picker-element-appender-controller.d.ts +0 -12
- package/dist/types/components/vega-date-picker/slimmers/controllers/vega-date-picker-mobile-controller.d.ts +0 -18
- package/dist/types/components/vega-date-picker/slimmers/controllers/vega-date-picker-month-year-change-event-controller.d.ts +0 -46
- package/dist/types/components/vega-date-picker/slimmers/controllers/vega-date-picker-zindex-controller.d.ts +0 -15
- package/dist/types/components/vega-date-picker/slimmers/renderers/vega-date-picker-calendar-month-year-dropdown-renderer.d.ts +0 -97
- package/dist/vega/p-0492fb42.entry.js +0 -1
- package/dist/vega/p-06840396.entry.js +0 -1
- package/dist/vega/p-06bc02cb.entry.js +0 -1
- package/dist/vega/p-070c3970.js +0 -1
- package/dist/vega/p-07c1a2a2.entry.js +0 -1
- package/dist/vega/p-08835909.js +0 -1
- package/dist/vega/p-10e142f1.js +0 -1
- package/dist/vega/p-12faf818.entry.js +0 -1
- package/dist/vega/p-1546855d.entry.js +0 -1
- package/dist/vega/p-18711501.js +0 -1
- package/dist/vega/p-194e32a2.js +0 -1
- package/dist/vega/p-19522949.js +0 -1
- package/dist/vega/p-197affbe.entry.js +0 -1
- package/dist/vega/p-1a282bfa.entry.js +0 -9
- package/dist/vega/p-1e5c2206.entry.js +0 -1
- package/dist/vega/p-1fb466db.js +0 -1
- package/dist/vega/p-24e66056.entry.js +0 -1
- package/dist/vega/p-26bde99c.entry.js +0 -1
- package/dist/vega/p-2762e4a7.entry.js +0 -1
- package/dist/vega/p-2b079386.entry.js +0 -1
- package/dist/vega/p-2c88b9c9.js +0 -1
- package/dist/vega/p-2de37a60.entry.js +0 -1
- package/dist/vega/p-2f866855.entry.js +0 -1
- package/dist/vega/p-3185b22d.entry.js +0 -1
- package/dist/vega/p-33cb78bd.entry.js +0 -1
- package/dist/vega/p-35609e2d.entry.js +0 -1
- package/dist/vega/p-36753b56.entry.js +0 -1
- package/dist/vega/p-37fd6859.entry.js +0 -1
- package/dist/vega/p-388953e4.entry.js +0 -1
- package/dist/vega/p-3925c16b.js +0 -1
- package/dist/vega/p-3ae691a0.entry.js +0 -1
- package/dist/vega/p-3ce90ecd.entry.js +0 -1
- package/dist/vega/p-4115d58a.entry.js +0 -1
- package/dist/vega/p-4a895707.js +0 -1
- package/dist/vega/p-502b7062.entry.js +0 -1
- package/dist/vega/p-532ff2d2.entry.js +0 -13
- package/dist/vega/p-5e1e91db.entry.js +0 -1
- package/dist/vega/p-5f53c228.entry.js +0 -1
- package/dist/vega/p-61519b5c.entry.js +0 -1
- package/dist/vega/p-62bf35fd.entry.js +0 -1
- package/dist/vega/p-64994265.entry.js +0 -1
- package/dist/vega/p-651ac54f.entry.js +0 -1
- package/dist/vega/p-67f159c3.js +0 -1
- package/dist/vega/p-70c898c6.entry.js +0 -1
- package/dist/vega/p-71f9c4d4.js +0 -1
- package/dist/vega/p-71fc7286.js +0 -1
- package/dist/vega/p-74168615.js +0 -1
- package/dist/vega/p-78d6dead.js +0 -1
- package/dist/vega/p-7d083222.entry.js +0 -1
- package/dist/vega/p-7d397c32.js +0 -1
- package/dist/vega/p-7d9cd9c8.js +0 -1
- package/dist/vega/p-7edd4b79.js +0 -1
- package/dist/vega/p-824a06ba.js +0 -1
- package/dist/vega/p-84d34816.js +0 -1
- package/dist/vega/p-853abdfd.entry.js +0 -1
- package/dist/vega/p-867a4970.js +0 -1
- package/dist/vega/p-8da8c2cf.entry.js +0 -1
- package/dist/vega/p-8daadaf3.entry.js +0 -1
- package/dist/vega/p-8eefbd15.entry.js +0 -1
- package/dist/vega/p-8fae8f9e.js +0 -1
- package/dist/vega/p-9112f67d.js +0 -1
- package/dist/vega/p-924b4e24.js +0 -1
- package/dist/vega/p-932c3efc.entry.js +0 -1
- package/dist/vega/p-9443c292.js +0 -1
- package/dist/vega/p-96c941d5.entry.js +0 -1
- package/dist/vega/p-9939e407.entry.js +0 -1
- package/dist/vega/p-99c52315.entry.js +0 -1
- package/dist/vega/p-99c6df1e.entry.js +0 -1
- package/dist/vega/p-9ce249a9.js +0 -1
- package/dist/vega/p-9f6632cc.entry.js +0 -1
- package/dist/vega/p-a10b9f2e.js +0 -12
- package/dist/vega/p-a6010b93.entry.js +0 -1
- package/dist/vega/p-a996636d.js +0 -1
- package/dist/vega/p-ae0edda4.entry.js +0 -1
- package/dist/vega/p-afe7bb0b.entry.js +0 -1
- package/dist/vega/p-b06ceb0f.entry.js +0 -1
- package/dist/vega/p-b1faebe0.js +0 -1
- package/dist/vega/p-b390be9d.entry.js +0 -1
- package/dist/vega/p-b555b253.js +0 -1
- package/dist/vega/p-baaf9264.js +0 -1
- package/dist/vega/p-bbc12975.js +0 -1
- package/dist/vega/p-bc749d3f.entry.js +0 -1
- package/dist/vega/p-c0b986af.js +0 -1
- package/dist/vega/p-c11c0d61.js +0 -1
- package/dist/vega/p-c4f6e01c.entry.js +0 -1
- package/dist/vega/p-c6ee2d47.entry.js +0 -1
- package/dist/vega/p-c8b76028.entry.js +0 -1
- package/dist/vega/p-cad733c8.js +0 -1
- package/dist/vega/p-d54a1453.entry.js +0 -1
- package/dist/vega/p-d94f149a.entry.js +0 -1
- package/dist/vega/p-de44727f.entry.js +0 -1
- package/dist/vega/p-e2a0f7ae.js +0 -1
- package/dist/vega/p-e6879699.entry.js +0 -1
- package/dist/vega/p-ec7bc15a.js +0 -1
- package/dist/vega/p-f14578ee.entry.js +0 -1
- package/dist/vega/p-f2de3d76.entry.js +0 -1
- package/dist/vega/p-f2f6f24d.entry.js +0 -1
- package/dist/vega/p-f41ef9e2.entry.js +0 -1
- package/dist/vega/p-f782a531.js +0 -1
- package/dist/vega/p-fc6617cb.entry.js +0 -1
- package/dist/vega/p-fc79b3c3.entry.js +0 -1
- package/dist/vega/p-ff67a25f.js +0 -1
- package/style/vega_min.css +0 -1
- package/style/visual-screenshots (1)/builds/master.json +0 -13385
- package/style/visual-screenshots (1)/compare.html +0 -26
- package/style/visual-screenshots (1)/connector.js +0 -10
- package/style/visual-screenshots (1)/images/00c9dbc329ca6b1ad78ea743b91ee0bc.png +0 -0
- package/style/visual-screenshots (1)/images/00deb6ff94de798b3fcc6414aedc040c.png +0 -0
- package/style/visual-screenshots (1)/images/014c955d050d2ebb917fd03590730572.png +0 -0
- package/style/visual-screenshots (1)/images/0182583c546dba469600a0251240cf21.png +0 -0
- package/style/visual-screenshots (1)/images/01a0575c0db1270ea83316b5c6c20601.png +0 -0
- package/style/visual-screenshots (1)/images/027defd97df9a5b4a7653be56ccdb0ac.png +0 -0
- package/style/visual-screenshots (1)/images/02ba6083bbf1c0e01a725f1f9f92aff9.png +0 -0
- package/style/visual-screenshots (1)/images/036795373db4daaf365beee11d8c25a7.png +0 -0
- package/style/visual-screenshots (1)/images/04a8eee512eeb23c1c2b87cda93a6776.png +0 -0
- package/style/visual-screenshots (1)/images/04bb561662f78f189085275de6678f41.png +0 -0
- package/style/visual-screenshots (1)/images/04eef932b78ca112212112ce585f27ab.png +0 -0
- package/style/visual-screenshots (1)/images/050cba57fa9a35e3803c85fbb59b4024.png +0 -0
- package/style/visual-screenshots (1)/images/051edd1219d1ddca517459b788cc9d2b.png +0 -0
- package/style/visual-screenshots (1)/images/0528ddc76f74747fa440e96db6907a43.png +0 -0
- package/style/visual-screenshots (1)/images/05395d74d64a1da223fb94b2874f2d66.png +0 -0
- package/style/visual-screenshots (1)/images/0545ef2f0796fa5f1d878254825adaf4.png +0 -0
- package/style/visual-screenshots (1)/images/0582c1933e54f696b632a1e1659073b2.png +0 -0
- package/style/visual-screenshots (1)/images/059772f121132ead0d6fa0a48168338b.png +0 -0
- package/style/visual-screenshots (1)/images/05feee4ecb06f066f3dafb653f33b6fb.png +0 -0
- package/style/visual-screenshots (1)/images/0640963c7a9fddb30a953c2624ba42eb.png +0 -0
- package/style/visual-screenshots (1)/images/065795600809ccab42d0f13ba71eb633.png +0 -0
- package/style/visual-screenshots (1)/images/0666dfce480647c3cb8857d2bb059847.png +0 -0
- package/style/visual-screenshots (1)/images/0700cef6f6f83545e2e7d3ecedc042d4.png +0 -0
- package/style/visual-screenshots (1)/images/0723f0263fa389ae876735ff57f46681.png +0 -0
- package/style/visual-screenshots (1)/images/073c1445dacdaac8c0aa6480212492f9.png +0 -0
- package/style/visual-screenshots (1)/images/073d4f053baf4c24d6af8de20eeae2aa.png +0 -0
- package/style/visual-screenshots (1)/images/076e14b0ccac0c02052e66256be50d47.png +0 -0
- package/style/visual-screenshots (1)/images/0775b2b66ba608e1677bb4bd032f707e.png +0 -0
- package/style/visual-screenshots (1)/images/078f2e93590c93c74f514e02ac05e4a3.png +0 -0
- package/style/visual-screenshots (1)/images/080f0f2d3f06372a9302e80f14aeb74e.png +0 -0
- package/style/visual-screenshots (1)/images/08872613981eb5e038fd62286300c583.png +0 -0
- package/style/visual-screenshots (1)/images/08cfa8c87053192e64e3b0b448d0dfaa.png +0 -0
- package/style/visual-screenshots (1)/images/08fc2250530bdc6b684a493406e75dcb.png +0 -0
- package/style/visual-screenshots (1)/images/0918181ef6fad9b51bbf411785719c7f.png +0 -0
- package/style/visual-screenshots (1)/images/091c16a1900c15eaf442677f7b7712a4.png +0 -0
- package/style/visual-screenshots (1)/images/09271a89642f3deb1534537363d82adf.png +0 -0
- package/style/visual-screenshots (1)/images/0968ada1c88a12c121d7e4cd9d1a4c31.png +0 -0
- package/style/visual-screenshots (1)/images/098cf2d4feb36daa5935d431b4cc2af9.png +0 -0
- package/style/visual-screenshots (1)/images/098ee2f12b7cd94ed7e3d9678dca8d9d.png +0 -0
- package/style/visual-screenshots (1)/images/09afb7f891103d16ca4e69cced183010.png +0 -0
- package/style/visual-screenshots (1)/images/0a8740f45dfa3ef686362af82744d0f8.png +0 -0
- package/style/visual-screenshots (1)/images/0aecce7dd5c65d8a1cd2bc3007aa039c.png +0 -0
- package/style/visual-screenshots (1)/images/0afce1548cbbf477be056364879ed645.png +0 -0
- package/style/visual-screenshots (1)/images/0b0e6917a067495e267dea6d4f1d2c89.png +0 -0
- package/style/visual-screenshots (1)/images/0b422eacde0c1264cc993d15ce94f3f2.png +0 -0
- package/style/visual-screenshots (1)/images/0b462aed27368fadffaf4042b4bf124f.png +0 -0
- package/style/visual-screenshots (1)/images/0bd41559a47131117d6b5d48f9384e2b.png +0 -0
- package/style/visual-screenshots (1)/images/0cdf8442f9e597e7782a97d05b9f0167.png +0 -0
- package/style/visual-screenshots (1)/images/0ce13d831ed54f898c0ddc60c7a3bfe9.png +0 -0
- package/style/visual-screenshots (1)/images/0d7e570e1a0f76d5114975280c8e36dc.png +0 -0
- package/style/visual-screenshots (1)/images/0dd901512ef46e6320b55ebb543c7a38.png +0 -0
- package/style/visual-screenshots (1)/images/0de77d7c6aedecc1948bf82730e77f9b.png +0 -0
- package/style/visual-screenshots (1)/images/0e588e87d0e0617c6fefe1e8203ceaf5.png +0 -0
- package/style/visual-screenshots (1)/images/0eb8a80ddc22191daad2b765098af978.png +0 -0
- package/style/visual-screenshots (1)/images/0ee82b520727d5a484ae47df46170f6b.png +0 -0
- package/style/visual-screenshots (1)/images/0ef7219055c2204179e5a87ce6393ecd.png +0 -0
- package/style/visual-screenshots (1)/images/0f20d9909852d49d83662e354d774330.png +0 -0
- package/style/visual-screenshots (1)/images/0fe5e32a6e5d62baa9eb9e9ef32b8ac0.png +0 -0
- package/style/visual-screenshots (1)/images/101fe127c73e1204c7b0a9532ddf5f33.png +0 -0
- package/style/visual-screenshots (1)/images/10dc76469583d7bb071c415b4c2500f5.png +0 -0
- package/style/visual-screenshots (1)/images/111ceb449af342ffefc9bf18313e9f2d.png +0 -0
- package/style/visual-screenshots (1)/images/116f44589ef708d63b88f72c07020d65.png +0 -0
- package/style/visual-screenshots (1)/images/11809d0dd4f56bd7e75c1ee424ea6049.png +0 -0
- package/style/visual-screenshots (1)/images/11e8c569dc91a4263915d38d41797b7c.png +0 -0
- package/style/visual-screenshots (1)/images/11f644637e7bf9e488c92e597243b372.png +0 -0
- package/style/visual-screenshots (1)/images/11f85d78db6278a0b9309de5e1971968.png +0 -0
- package/style/visual-screenshots (1)/images/126484246367b441a4874bf1c80eb701.png +0 -0
- package/style/visual-screenshots (1)/images/12b7614a6bca5fba19b2c207c9399eec.png +0 -0
- package/style/visual-screenshots (1)/images/12f9db657f5f215db4fd81d60e61ac05.png +0 -0
- package/style/visual-screenshots (1)/images/12fd30dca14bdb10e138bf9957cb67d6.png +0 -0
- package/style/visual-screenshots (1)/images/12ff293bb7a3fb35ba9e71b36d1ede58.png +0 -0
- package/style/visual-screenshots (1)/images/132fad75fe05d0c78d642c7d18b36364.png +0 -0
- package/style/visual-screenshots (1)/images/133df50a253039a25dc23c11be89ceb7.png +0 -0
- package/style/visual-screenshots (1)/images/13b9e970f1e6fc8dde0c10722f66bb73.png +0 -0
- package/style/visual-screenshots (1)/images/13d533f8842a49a2a160723a46eb8a32.png +0 -0
- package/style/visual-screenshots (1)/images/14391d1ca80560f5e01b72b0a32a2e43.png +0 -0
- package/style/visual-screenshots (1)/images/14b81ce49feb5c4033d2b6bf9ce8b584.png +0 -0
- package/style/visual-screenshots (1)/images/16548b7507dad1afa018cf73f656e123.png +0 -0
- package/style/visual-screenshots (1)/images/16bbd810a35c9542672c143620dd124b.png +0 -0
- package/style/visual-screenshots (1)/images/17f1ac08aef0b15a2a93576bd0c69a8b.png +0 -0
- package/style/visual-screenshots (1)/images/1823fb8764090e5f139555434673b999.png +0 -0
- package/style/visual-screenshots (1)/images/184a290d2680a6b9ed5fd3e875866f6c.png +0 -0
- package/style/visual-screenshots (1)/images/1853b22c2e9f57c3c0465f1ad677fd02.png +0 -0
- package/style/visual-screenshots (1)/images/1917b4c75462018e96fd444a55f92fdb.png +0 -0
- package/style/visual-screenshots (1)/images/19cb20f82a883631ec08e6fce09c9346.png +0 -0
- package/style/visual-screenshots (1)/images/19d6ef3f0f09ad264bd4565a890f4de3.png +0 -0
- package/style/visual-screenshots (1)/images/19f0f11a1678b49278906815b94aa63b.png +0 -0
- package/style/visual-screenshots (1)/images/1a334e822ac119215ecd18f1289048cf.png +0 -0
- package/style/visual-screenshots (1)/images/1a396fba8af913178a057a63bc2812ef.png +0 -0
- package/style/visual-screenshots (1)/images/1a4712761391165e44e0399e574800c7.png +0 -0
- package/style/visual-screenshots (1)/images/1a6407989995cf5d9451432c30bd8af5.png +0 -0
- package/style/visual-screenshots (1)/images/1a66f2485b63b12007df9713afc7abbd.png +0 -0
- package/style/visual-screenshots (1)/images/1a9961bc790f0e542d0e1df7ec61162c.png +0 -0
- package/style/visual-screenshots (1)/images/1aad56b95fdc16ee9739410e31f4b04b.png +0 -0
- package/style/visual-screenshots (1)/images/1ab773baf811c86dcc3fd48c486b948e.png +0 -0
- package/style/visual-screenshots (1)/images/1acd824e815dd8290f73aa3eac0e9aa7.png +0 -0
- package/style/visual-screenshots (1)/images/1b7e059b6e4adb5f3a15dc7737195bef.png +0 -0
- package/style/visual-screenshots (1)/images/1b83910bbcff965492bf79d17f7f3952.png +0 -0
- package/style/visual-screenshots (1)/images/1b8acd3ed0bb87d0b41963d3c4566324.png +0 -0
- package/style/visual-screenshots (1)/images/1bcb2ad6de61cbc5cb2bfbc40dcf3c75.png +0 -0
- package/style/visual-screenshots (1)/images/1c01fa461439431ed056e345914504aa.png +0 -0
- package/style/visual-screenshots (1)/images/1c1622f4ff1c0169e2efe5af5fab7238.png +0 -0
- package/style/visual-screenshots (1)/images/1c2ae0a43c9aea9e17e639f2486ad76c.png +0 -0
- package/style/visual-screenshots (1)/images/1c2c279749b3bab613be5efd8411a9fb.png +0 -0
- package/style/visual-screenshots (1)/images/1cdb0dbdb6a4398f94988e3d40162f2c.png +0 -0
- package/style/visual-screenshots (1)/images/1cfacd6c8ac80ee3c4a7f8584bd1441c.png +0 -0
- package/style/visual-screenshots (1)/images/1d1444203dac3cbe71c951d381126d03.png +0 -0
- package/style/visual-screenshots (1)/images/1d73f593bed08ad694e2b573a39ae06f.png +0 -0
- package/style/visual-screenshots (1)/images/1dac4a7712234a30253ab6f9160d50a6.png +0 -0
- package/style/visual-screenshots (1)/images/1ebaf53fb8db94bb9a8154e86a3e5ed2.png +0 -0
- package/style/visual-screenshots (1)/images/1ec0c1febc3f0dd1786eea003e0dee38.png +0 -0
- package/style/visual-screenshots (1)/images/1ec3bebcdac3683aad4e93ea70ee4a1e.png +0 -0
- package/style/visual-screenshots (1)/images/1f7f87a3bfb22d7b6d5489170a691439.png +0 -0
- package/style/visual-screenshots (1)/images/217dca423214acf6733443967bd4bb91.png +0 -0
- package/style/visual-screenshots (1)/images/21a4579340bd071933dc4222aca885e8.png +0 -0
- package/style/visual-screenshots (1)/images/21e702dbfac3ae3c84ad5cf4a3a5fd33.png +0 -0
- package/style/visual-screenshots (1)/images/2205a5e15323173cf82e53036b89f3d2.png +0 -0
- package/style/visual-screenshots (1)/images/2239056187956d81a9a7a3ff086123ec.png +0 -0
- package/style/visual-screenshots (1)/images/22a392ca2f7b01e9145de8a1d16d8ac1.png +0 -0
- package/style/visual-screenshots (1)/images/2395e15caf0facec892a787fbf1baa61.png +0 -0
- package/style/visual-screenshots (1)/images/2430226e2b211252d8793d0b24bd105b.png +0 -0
- package/style/visual-screenshots (1)/images/249af52548a661890ebb3990c81e7bec.png +0 -0
- package/style/visual-screenshots (1)/images/24adff266f0ccc120bbab22610a7afef.png +0 -0
- package/style/visual-screenshots (1)/images/250d4d8b44fd5e3f83114560684c7a33.png +0 -0
- package/style/visual-screenshots (1)/images/2517969a2f9a119f248ef574ce68957a.png +0 -0
- package/style/visual-screenshots (1)/images/251e0de35a82707d6372ae27e6a28f19.png +0 -0
- package/style/visual-screenshots (1)/images/25596d87f964d9e9e48bcdcb815d97b0.png +0 -0
- package/style/visual-screenshots (1)/images/257aafcb25e5c45c1fdb794c500845af.png +0 -0
- package/style/visual-screenshots (1)/images/25eeda071a6e8ec33338f621edfccce7.png +0 -0
- package/style/visual-screenshots (1)/images/260117a8a096031e2d4a00137e1fb6e7.png +0 -0
- package/style/visual-screenshots (1)/images/2609faace1c9661a650574dcc408030d.png +0 -0
- package/style/visual-screenshots (1)/images/2613cd2759c32063cc30bd0bd33358dc.png +0 -0
- package/style/visual-screenshots (1)/images/2694ff3a617c6cf218bdd37a19c83b8a.png +0 -0
- package/style/visual-screenshots (1)/images/26e2f8a3530bb0e0ea2384f2bdc9a81a.png +0 -0
- package/style/visual-screenshots (1)/images/2729771eeefd444ff898c491f1273357.png +0 -0
- package/style/visual-screenshots (1)/images/27f11a528d6b5f15d45f2c420edc00fb.png +0 -0
- package/style/visual-screenshots (1)/images/2818dab1bc771c7ed5eb71d561228863.png +0 -0
- package/style/visual-screenshots (1)/images/28cf1d93f7722430ee1437df8a14127f.png +0 -0
- package/style/visual-screenshots (1)/images/2939e1e89e29a3b71f5be665edf472c2.png +0 -0
- package/style/visual-screenshots (1)/images/2a3e1613614fa6bf58ebcb820d6fc84f.png +0 -0
- package/style/visual-screenshots (1)/images/2a8fce144b32ae297bcc8650d13cdb1c.png +0 -0
- package/style/visual-screenshots (1)/images/2aa7766d32787734fc8a534acc98bf77.png +0 -0
- package/style/visual-screenshots (1)/images/2ae27049402468e5e2baf2b664365f8a.png +0 -0
- package/style/visual-screenshots (1)/images/2b1b3ff73541c559ff4f0f22f70db3d1.png +0 -0
- package/style/visual-screenshots (1)/images/2b3af1d887b41d5123e82575fbfa3958.png +0 -0
- package/style/visual-screenshots (1)/images/2b8c160de3305bb7deef1bd108bd0850.png +0 -0
- package/style/visual-screenshots (1)/images/2b8df5a2aa5bea6bb21551b1ea4a5fe3.png +0 -0
- package/style/visual-screenshots (1)/images/2bb42f7f640cb97e6ddd996cc4bdf0da.png +0 -0
- package/style/visual-screenshots (1)/images/2c0ab17426c134629732d0a71b6a0745.png +0 -0
- package/style/visual-screenshots (1)/images/2c20e396014f9b12f047545579b878ca.png +0 -0
- package/style/visual-screenshots (1)/images/2c2c8816739b979c0a3dbdcbea9c8f98.png +0 -0
- package/style/visual-screenshots (1)/images/2c532e1252a0775b10aed847a4f06e4a.png +0 -0
- package/style/visual-screenshots (1)/images/2cdd6aee7de3219ce296baef83119f45.png +0 -0
- package/style/visual-screenshots (1)/images/2cebfc565448f890d0a3fa2de61cfd61.png +0 -0
- package/style/visual-screenshots (1)/images/2d76b6c335af030ecc073359d3565529.png +0 -0
- package/style/visual-screenshots (1)/images/2d7f41ff4f3900f029adbcdbdfdef905.png +0 -0
- package/style/visual-screenshots (1)/images/2d8b857c7a81cd7e90b75c9fcb974e09.png +0 -0
- package/style/visual-screenshots (1)/images/2e1f9e506e8e09a191c0d86899e8975a.png +0 -0
- package/style/visual-screenshots (1)/images/2e8755615c5b55dfeb5ced872b9b89f6.png +0 -0
- package/style/visual-screenshots (1)/images/2efe3ccdf954982fb10f12ceb79cc902.png +0 -0
- package/style/visual-screenshots (1)/images/2f2a4fe573c824c9c651ae5fb24e26f6.png +0 -0
- package/style/visual-screenshots (1)/images/2f426e5f71eae6eaf7bb54b4aafa88d6.png +0 -0
- package/style/visual-screenshots (1)/images/2f4e9578c9f11b5c8e2d034824689dce.png +0 -0
- package/style/visual-screenshots (1)/images/2f5ec86f7334a79914c09ee94eae2f8d.png +0 -0
- package/style/visual-screenshots (1)/images/2f76ed17b978cfa3e663760d5c651b0f.png +0 -0
- package/style/visual-screenshots (1)/images/2f8832e36833e875c53bdf68ac53de11.png +0 -0
- package/style/visual-screenshots (1)/images/2fe54d475ff814eaf2b323bfa6990a25.png +0 -0
- package/style/visual-screenshots (1)/images/30423ab0c5ce8c26a9b4e30fb4ad50b5.png +0 -0
- package/style/visual-screenshots (1)/images/3079876e71da7c207489af4b38314ca3.png +0 -0
- package/style/visual-screenshots (1)/images/30ac31802c8421ee59c2b0e64fdd40d1.png +0 -0
- package/style/visual-screenshots (1)/images/30efef6537f882daf60ba808d25ab35c.png +0 -0
- package/style/visual-screenshots (1)/images/3111d7bc39ef23e1d19a8022f2f78d4f.png +0 -0
- package/style/visual-screenshots (1)/images/3155c15ead85acf928e71fc4958b1e65.png +0 -0
- package/style/visual-screenshots (1)/images/317b0753146b2d6c57ef618e2d6c9aff.png +0 -0
- package/style/visual-screenshots (1)/images/31bb19c3949134774cce7f0af132f001.png +0 -0
- package/style/visual-screenshots (1)/images/32009df7a0440dc1227d6c59fcdc22a8.png +0 -0
- package/style/visual-screenshots (1)/images/3205ce4d4ec27524cb360e23cb250a2e.png +0 -0
- package/style/visual-screenshots (1)/images/3221fe82f718cdb8d3a013e35e75d966.png +0 -0
- package/style/visual-screenshots (1)/images/322755f4d634ab3e62663c98413cf4bb.png +0 -0
- package/style/visual-screenshots (1)/images/3263cb4ecdc16ecec1cf03d96c1d83d1.png +0 -0
- package/style/visual-screenshots (1)/images/329d69f11e6409b7e7855c3e576057f6.png +0 -0
- package/style/visual-screenshots (1)/images/32b3faa4eb5356a1ac8b30c722b7f282.png +0 -0
- package/style/visual-screenshots (1)/images/332160dde332162d8e3b9e12dd376546.png +0 -0
- package/style/visual-screenshots (1)/images/33519a891e6922542f2b3fc18ab26670.png +0 -0
- package/style/visual-screenshots (1)/images/33a7eaf167f347d52bc910511d2fc029.png +0 -0
- package/style/visual-screenshots (1)/images/33b0ac3141f5f2ea19f81d742269bcab.png +0 -0
- package/style/visual-screenshots (1)/images/343327cf17cc3b6a5e451c4d86577491.png +0 -0
- package/style/visual-screenshots (1)/images/3474b54aac010b234998e46521894bde.png +0 -0
- package/style/visual-screenshots (1)/images/34a84ed26a53ffb27dbcdabeaf10c665.png +0 -0
- package/style/visual-screenshots (1)/images/34efd6c9f4e5031eeb8c1f1a51bd3eaa.png +0 -0
- package/style/visual-screenshots (1)/images/3531a86fca237cc6d8764eb9eeb8e394.png +0 -0
- package/style/visual-screenshots (1)/images/3598a332200dbe7f32ab86015e6cd61e.png +0 -0
- package/style/visual-screenshots (1)/images/35a2ea7b24e787bdea1313703512d37f.png +0 -0
- package/style/visual-screenshots (1)/images/35ea4500d8a65ff3e52c0404ded68018.png +0 -0
- package/style/visual-screenshots (1)/images/363f015a5323e01c8f7c421607ba7a85.png +0 -0
- package/style/visual-screenshots (1)/images/365a47a407c464a973116590d1280542.png +0 -0
- package/style/visual-screenshots (1)/images/3666d49f301336a1d92abe8c48811dd0.png +0 -0
- package/style/visual-screenshots (1)/images/36a3aa27abb0e8fb45cbe4e842bb793b.png +0 -0
- package/style/visual-screenshots (1)/images/36be2d1cc4bbea216ebfa024f2b5d9d3.png +0 -0
- package/style/visual-screenshots (1)/images/36d5ce3a43f8a8bbaddb83a756174e09.png +0 -0
- package/style/visual-screenshots (1)/images/3715717d75b5ec943086b9392d05747a.png +0 -0
- package/style/visual-screenshots (1)/images/3718308a2535e0badb74e0ed39da3e98.png +0 -0
- package/style/visual-screenshots (1)/images/376d9c365f202b555efc6152eb4dbb7a.png +0 -0
- package/style/visual-screenshots (1)/images/37ff2d44fb6261e53203d05e1d130b48.png +0 -0
- package/style/visual-screenshots (1)/images/3829933c4a23d7033a63119484708ab4.png +0 -0
- package/style/visual-screenshots (1)/images/38c924efe546ddde14e0cb343a2ed551.png +0 -0
- package/style/visual-screenshots (1)/images/390f5b1f49dc988e023255d1878b769a.png +0 -0
- package/style/visual-screenshots (1)/images/394ab2b92eacbc9f634b3d0618b877d0.png +0 -0
- package/style/visual-screenshots (1)/images/3961f21e98b5d1f616215c9588f0c8ea.png +0 -0
- package/style/visual-screenshots (1)/images/396af4eab814a3a2dc1429581b3452b3.png +0 -0
- package/style/visual-screenshots (1)/images/3a3ec2d1cafe6685d14ef24be74aace4.png +0 -0
- package/style/visual-screenshots (1)/images/3ae1c7c33ebd96fe70ad90acc7b1d693.png +0 -0
- package/style/visual-screenshots (1)/images/3b19874ff7c8b2b92d6e200634b760c5.png +0 -0
- package/style/visual-screenshots (1)/images/3b4f2951c9cbd00ad924a358e0f24304.png +0 -0
- package/style/visual-screenshots (1)/images/3bc5adf4dec1f65342d09fa825073ee7.png +0 -0
- package/style/visual-screenshots (1)/images/3be29fbf67e05c10ef9effda5b0d1b9c.png +0 -0
- package/style/visual-screenshots (1)/images/3bfdd784ff28564271d8067439c72fb2.png +0 -0
- package/style/visual-screenshots (1)/images/3c101349056155ee16f6d40d67566bb2.png +0 -0
- package/style/visual-screenshots (1)/images/3c24263abc9fe6f48efe83953f33d38f.png +0 -0
- package/style/visual-screenshots (1)/images/3c4b7cb9bc584cc8d417763e4e332cad.png +0 -0
- package/style/visual-screenshots (1)/images/3cb9028699d3dc4a5ff9ed62acf26f38.png +0 -0
- package/style/visual-screenshots (1)/images/3d5e1f1170e3c54f19f3966925138df0.png +0 -0
- package/style/visual-screenshots (1)/images/3d7ee9ac11ff5492525a094beaa220b1.png +0 -0
- package/style/visual-screenshots (1)/images/3d82c97ab6d96c4026d0f3ca072b02ae.png +0 -0
- package/style/visual-screenshots (1)/images/3ec93ead42526589356ac0b756d043ec.png +0 -0
- package/style/visual-screenshots (1)/images/3f1b42c8f0cb41c374b0893eb31f2fda.png +0 -0
- package/style/visual-screenshots (1)/images/3ff96bd3c1034fe2a3af47eb4f729eeb.png +0 -0
- package/style/visual-screenshots (1)/images/400b3fe6558f8ae340d796c834456f82.png +0 -0
- package/style/visual-screenshots (1)/images/404d5c7fe65c1df1162feb7af57adadd.png +0 -0
- package/style/visual-screenshots (1)/images/4060b53b47c6e063d1770980ecb101b2.png +0 -0
- package/style/visual-screenshots (1)/images/40dd05574156c243449caad139d9b9a2.png +0 -0
- package/style/visual-screenshots (1)/images/40f479e6d12eaa5687a4ac9784aa717e.png +0 -0
- package/style/visual-screenshots (1)/images/40f48b85da52ec3ef05fa4696c72f7ff.png +0 -0
- package/style/visual-screenshots (1)/images/4169f0823fcd903e16d7c3f9344cc491.png +0 -0
- package/style/visual-screenshots (1)/images/419a4e8e4b8708b8e6ff45f643a7cf5d.png +0 -0
- package/style/visual-screenshots (1)/images/41c7990e66fbed660d2b55e76fd2ea25.png +0 -0
- package/style/visual-screenshots (1)/images/423ae4e26846f800ea31ed24d79e7472.png +0 -0
- package/style/visual-screenshots (1)/images/427c562ebb511d853cd3437eb8c73c0f.png +0 -0
- package/style/visual-screenshots (1)/images/428ec68c1c5771403f8939976018c14e.png +0 -0
- package/style/visual-screenshots (1)/images/4291cb1eaed75fba4800f0033b689208.png +0 -0
- package/style/visual-screenshots (1)/images/42ed1e77d86bf5e0d7a8f90acf2ab6b2.png +0 -0
- package/style/visual-screenshots (1)/images/4313e10ac1318b7526eed35c0d704f05.png +0 -0
- package/style/visual-screenshots (1)/images/438f453be7d1213a8e2872e4608a410c.png +0 -0
- package/style/visual-screenshots (1)/images/439f69b339c6f6ca820a4b62382ca877.png +0 -0
- package/style/visual-screenshots (1)/images/43f6607e4b8ff0d5f6c4c5d323c96677.png +0 -0
- package/style/visual-screenshots (1)/images/44caefac207b436ffeffdef86eaae21a.png +0 -0
- package/style/visual-screenshots (1)/images/44eaf11aa4495c9d8d76941a1254dcb0.png +0 -0
- package/style/visual-screenshots (1)/images/453742c5e578099953f9bff69e3982ef.png +0 -0
- package/style/visual-screenshots (1)/images/459214ef33a21425f776796767256e3c.png +0 -0
- package/style/visual-screenshots (1)/images/45a13beb6b9356d7b1b4690370914252.png +0 -0
- package/style/visual-screenshots (1)/images/45a569fd48a72db5047a02e192c35363.png +0 -0
- package/style/visual-screenshots (1)/images/45c1ac110c0dc20d35d2c2be1e469e49.png +0 -0
- package/style/visual-screenshots (1)/images/466d83d9df37025413fcc77e2528d150.png +0 -0
- package/style/visual-screenshots (1)/images/46ffc37786e06461d5ffc3c101841ea6.png +0 -0
- package/style/visual-screenshots (1)/images/4708081357611e1ad1adb36ea5f91ebe.png +0 -0
- package/style/visual-screenshots (1)/images/4799a82b4f5b3242bcf158dc12aeb8da.png +0 -0
- package/style/visual-screenshots (1)/images/47a4ae1ed1de0348708e630718bf58e0.png +0 -0
- package/style/visual-screenshots (1)/images/47cd6b92f4697a387f4392729f019da0.png +0 -0
- package/style/visual-screenshots (1)/images/47d36e03c0973961a65d47f31bbce64d.png +0 -0
- package/style/visual-screenshots (1)/images/48812bb1c24cf4529f36152c045aefe4.png +0 -0
- package/style/visual-screenshots (1)/images/48b348f52bcf73e7b84273b59414d9c0.png +0 -0
- package/style/visual-screenshots (1)/images/48ccc273160dcf8a8eee6caa44dacdd1.png +0 -0
- package/style/visual-screenshots (1)/images/4946b39b68b5cf6879cab368a43dde2d.png +0 -0
- package/style/visual-screenshots (1)/images/494f07c31c273d35487cbacefb179211.png +0 -0
- package/style/visual-screenshots (1)/images/495c33cb81b92e71a59064b036deacb3.png +0 -0
- package/style/visual-screenshots (1)/images/4988de5d9c64f2451adb83cc9781f31d.png +0 -0
- package/style/visual-screenshots (1)/images/4a5c84ab5b32f8b3652f31aca7f82547.png +0 -0
- package/style/visual-screenshots (1)/images/4abedbcd1f3c2b3cb5af44393cc4edd3.png +0 -0
- package/style/visual-screenshots (1)/images/4ac246764de2e6eaea78d1eee8fa0680.png +0 -0
- package/style/visual-screenshots (1)/images/4b49f29e64109f5d844bae574d9368e9.png +0 -0
- package/style/visual-screenshots (1)/images/4ba5027ab476151e2ba4f16cade9a316.png +0 -0
- package/style/visual-screenshots (1)/images/4be038b7049b5639096cdf45dc0166d5.png +0 -0
- package/style/visual-screenshots (1)/images/4be0509c9e49770d5d3ab93a9d824c0c.png +0 -0
- package/style/visual-screenshots (1)/images/4c007d54467c97735191d53b1b89700a.png +0 -0
- package/style/visual-screenshots (1)/images/4c04913dd6ac89f9c03580ffcfc9dce2.png +0 -0
- package/style/visual-screenshots (1)/images/4c39dc9b5530f8cfa389453f323f2562.png +0 -0
- package/style/visual-screenshots (1)/images/4cf7eb7fbbfcbad4194ef321b793a243.png +0 -0
- package/style/visual-screenshots (1)/images/4d34a53adeaf6b96b5f910e0e57f91f7.png +0 -0
- package/style/visual-screenshots (1)/images/4d3538775024b65cc11c656ee312bfb7.png +0 -0
- package/style/visual-screenshots (1)/images/4d614a3bd7821f52b699427abf3440e2.png +0 -0
- package/style/visual-screenshots (1)/images/4d85b89464845f56b18d7e329f1394a4.png +0 -0
- package/style/visual-screenshots (1)/images/4d9140a7a2defdf17daec4df653cccb8.png +0 -0
- package/style/visual-screenshots (1)/images/4e52657b6cd66fa0e8da6225c3923833.png +0 -0
- package/style/visual-screenshots (1)/images/4eb94875d887dfece7a7e2cc00425848.png +0 -0
- package/style/visual-screenshots (1)/images/4f3481e7bcab3c6a115931bdc7bde793.png +0 -0
- package/style/visual-screenshots (1)/images/4f736b3787086298b179837d13ea2e27.png +0 -0
- package/style/visual-screenshots (1)/images/4f7e9c28d6d15df090c3857fe8172a90.png +0 -0
- package/style/visual-screenshots (1)/images/4f831bf4925c85ef517fd84fed27cefc.png +0 -0
- package/style/visual-screenshots (1)/images/4f8cc269620de9911fba4dff6724c7a5.png +0 -0
- package/style/visual-screenshots (1)/images/4f9cf3ca13066408925b4d1cdc856337.png +0 -0
- package/style/visual-screenshots (1)/images/4fe4b5357ee618b9ca1265408d74ad97.png +0 -0
- package/style/visual-screenshots (1)/images/5018ce083222fefeb9e4686ed2e1edaf.png +0 -0
- package/style/visual-screenshots (1)/images/5022d94c55bd146ad125a05b5c9f15dd.png +0 -0
- package/style/visual-screenshots (1)/images/503a0b5aa58f32f0892efbb58b46b996.png +0 -0
- package/style/visual-screenshots (1)/images/50a9c832d93ea3ba546abb94fd08af87.png +0 -0
- package/style/visual-screenshots (1)/images/5118ecf3e50d06897080ed1b2bafcef3.png +0 -0
- package/style/visual-screenshots (1)/images/5158dd83988845a3839627ad959dbb01.png +0 -0
- package/style/visual-screenshots (1)/images/51923db19fef9e029f0893a8a2003614.png +0 -0
- package/style/visual-screenshots (1)/images/51f5169578f81f7fb04205fa02f761c6.png +0 -0
- package/style/visual-screenshots (1)/images/52525fe087784b1fdffe1cfc03eed02d.png +0 -0
- package/style/visual-screenshots (1)/images/5266c70656af2dd7ea757c126c555489.png +0 -0
- package/style/visual-screenshots (1)/images/5273adef332dbb60fac11c48a989c42d.png +0 -0
- package/style/visual-screenshots (1)/images/52cfe294a3f7300731ce4dbe4717bdea.png +0 -0
- package/style/visual-screenshots (1)/images/5328d69dc10bb02003c30fed0e25a64b.png +0 -0
- package/style/visual-screenshots (1)/images/53e6290d0b3f1294543ba28828558bae.png +0 -0
- package/style/visual-screenshots (1)/images/53eeaa26642fb7b44a83b9bf5d285b1a.png +0 -0
- package/style/visual-screenshots (1)/images/540524e243acf3f3f5bfa8c392ffba52.png +0 -0
- package/style/visual-screenshots (1)/images/5436543a753e26c1c2224e9b8ed3f30c.png +0 -0
- package/style/visual-screenshots (1)/images/54c4e2aa7af0622b71ab1b91e0216497.png +0 -0
- package/style/visual-screenshots (1)/images/54cf609aa15fa2609c3079a322e9f60a.png +0 -0
- package/style/visual-screenshots (1)/images/54e4e6b63e13d2f360b1bd0d1ade4ebd.png +0 -0
- package/style/visual-screenshots (1)/images/5505895e66a4d80a8eb40be714de2da1.png +0 -0
- package/style/visual-screenshots (1)/images/554637773a92e812811d95933b06d047.png +0 -0
- package/style/visual-screenshots (1)/images/55b1e1c7415f8f22ab377f2e4fd5a91d.png +0 -0
- package/style/visual-screenshots (1)/images/55c30ec12d513e3c365e94ef76330703.png +0 -0
- package/style/visual-screenshots (1)/images/5737582ac302d9b30b549c875dc0e823.png +0 -0
- package/style/visual-screenshots (1)/images/5838b2544ecf964a999cab746d5bd97d.png +0 -0
- package/style/visual-screenshots (1)/images/58b847761ee38a8c47f208aeb558e0a9.png +0 -0
- package/style/visual-screenshots (1)/images/58cae6127379fa56b766c6c3528a286a.png +0 -0
- package/style/visual-screenshots (1)/images/58cd807e8212d20223020a0c6404765b.png +0 -0
- package/style/visual-screenshots (1)/images/5909df37c419a947f3725ea71a9680c3.png +0 -0
- package/style/visual-screenshots (1)/images/590d2d0fa1c7e1204816f4badda94716.png +0 -0
- package/style/visual-screenshots (1)/images/592abe77a6d530f6d9c77c1fe68d1315.png +0 -0
- package/style/visual-screenshots (1)/images/593cacdf991a89066c6887dda6214279.png +0 -0
- package/style/visual-screenshots (1)/images/597612a74ca61e8e3cee1183251cac24.png +0 -0
- package/style/visual-screenshots (1)/images/59b59b3d221c4be96d27770926f6eb7c.png +0 -0
- package/style/visual-screenshots (1)/images/59d0c2dc9de3c7ca52811e6d03005db0.png +0 -0
- package/style/visual-screenshots (1)/images/59e20e58e24364f8ea8e94f2708de92f.png +0 -0
- package/style/visual-screenshots (1)/images/5a0638a95840412ad0883e0e14dd22f4.png +0 -0
- package/style/visual-screenshots (1)/images/5a251791db123f6cf0fc8207cd34d605.png +0 -0
- package/style/visual-screenshots (1)/images/5a8cf1ada7ead3e071e59c233e45d826.png +0 -0
- package/style/visual-screenshots (1)/images/5a98898f2c6c913e34e6370769a2e419.png +0 -0
- package/style/visual-screenshots (1)/images/5aa02d6e18a0fa7b46ad23263f5372f9.png +0 -0
- package/style/visual-screenshots (1)/images/5ab4fc80d22b19429b70cd3a6ab8bb05.png +0 -0
- package/style/visual-screenshots (1)/images/5acd13c49bb19fc300b6a7c2460945db.png +0 -0
- package/style/visual-screenshots (1)/images/5add1e2e0f9c785f9e969cce0b11e0a6.png +0 -0
- package/style/visual-screenshots (1)/images/5aeed5c2ec2ca7b5ae286bae76bb6f72.png +0 -0
- package/style/visual-screenshots (1)/images/5b2591966426d8c77601565dfa914b5c.png +0 -0
- package/style/visual-screenshots (1)/images/5b424b673e5f6814bbcc687a2f5ba7ff.png +0 -0
- package/style/visual-screenshots (1)/images/5bd4d4b7e0890bcb1d81ede114ee4b72.png +0 -0
- package/style/visual-screenshots (1)/images/5beea7f2f00f4db6f09fcf15bd6b73de.png +0 -0
- package/style/visual-screenshots (1)/images/5c02af94f4d5ed86c881612dcfb31b02.png +0 -0
- package/style/visual-screenshots (1)/images/5c0c0f1dbdb3aca383c35ec0cb67c599.png +0 -0
- package/style/visual-screenshots (1)/images/5c520e4228567e2374f5d96b7f15c0d9.png +0 -0
- package/style/visual-screenshots (1)/images/5cb10edf424ba13d586e83e60ac14a2d.png +0 -0
- package/style/visual-screenshots (1)/images/5cca63b3d493de7befd4382f24a2aabd.png +0 -0
- package/style/visual-screenshots (1)/images/5d5ef2d78f31c874edb28ebdfbfbd8f9.png +0 -0
- package/style/visual-screenshots (1)/images/5d8110526b6ba5e9621d0f2fa57aa132.png +0 -0
- package/style/visual-screenshots (1)/images/5d8f7a0eff0b6d546331f921490f25b9.png +0 -0
- package/style/visual-screenshots (1)/images/5eab49b89384ab1f74be37d4e905021a.png +0 -0
- package/style/visual-screenshots (1)/images/5ebfae0149ca72238011292fa3e486cb.png +0 -0
- package/style/visual-screenshots (1)/images/5ecd509cfe196a8262a7e85d3d4c64b0.png +0 -0
- package/style/visual-screenshots (1)/images/5f153464c343cd768216633b852073e7.png +0 -0
- package/style/visual-screenshots (1)/images/5f69e3fcc20bdb527e040185048788e4.png +0 -0
- package/style/visual-screenshots (1)/images/5fb4421e5a6d1eaef21a54bb431bdacb.png +0 -0
- package/style/visual-screenshots (1)/images/5fd1665ddd85bf70339a29ddf3a98915.png +0 -0
- package/style/visual-screenshots (1)/images/602fb4d5d2c9707f008b0d6a1a0487a7.png +0 -0
- package/style/visual-screenshots (1)/images/604007e0cd1142f4e425d57ad9a1c5ef.png +0 -0
- package/style/visual-screenshots (1)/images/605d581f35cd72dc9d7083dcc8066af1.png +0 -0
- package/style/visual-screenshots (1)/images/6188b93026521a32345a4319fb10271e.png +0 -0
- package/style/visual-screenshots (1)/images/621e7fcf64cbb08d121b599a81acb46a.png +0 -0
- package/style/visual-screenshots (1)/images/626302e61eedc90d62298f66f46b8ec0.png +0 -0
- package/style/visual-screenshots (1)/images/6289549bdd1f3ba4ee0ffa76fa3a8636.png +0 -0
- package/style/visual-screenshots (1)/images/62a7d5f3d5afe23177d5dbab5f1e4c79.png +0 -0
- package/style/visual-screenshots (1)/images/6355a9180ed5c4dd8df56c9ead71b0c8.png +0 -0
- package/style/visual-screenshots (1)/images/63981d8aaadcbe9b9e73af3669b3c180.png +0 -0
- package/style/visual-screenshots (1)/images/63bd485372b912309753349358f50eda.png +0 -0
- package/style/visual-screenshots (1)/images/6415c0bc3637ea962fb1761ae69b5dda.png +0 -0
- package/style/visual-screenshots (1)/images/64174556b9d8b4d18b7b8cfd531987a7.png +0 -0
- package/style/visual-screenshots (1)/images/64443c554e8813c1fff9032b53c52b76.png +0 -0
- package/style/visual-screenshots (1)/images/6478d52ea2380b15c4b549d9a1f77bac.png +0 -0
- package/style/visual-screenshots (1)/images/649745ba63be2d7bf9d4f766d7b8ca38.png +0 -0
- package/style/visual-screenshots (1)/images/64f2a771825679d512c73923c1bd5184.png +0 -0
- package/style/visual-screenshots (1)/images/65147f30150f68dd99a34e3de9adb4a2.png +0 -0
- package/style/visual-screenshots (1)/images/651e96edc124365985fcf260c7695452.png +0 -0
- package/style/visual-screenshots (1)/images/6542deed80a8908b2ba2e40b482a5829.png +0 -0
- package/style/visual-screenshots (1)/images/6548c65bf55806aa5acde87bc4d2017e.png +0 -0
- package/style/visual-screenshots (1)/images/65be34b043114b668dad4ce359310ad3.png +0 -0
- package/style/visual-screenshots (1)/images/65f1fc5ed87fb18c756988c6719c3b05.png +0 -0
- package/style/visual-screenshots (1)/images/6618ae614b5a59f18f1f9f627b81f0ba.png +0 -0
- package/style/visual-screenshots (1)/images/6710405c63cd71667e3533429bc8ac74.png +0 -0
- package/style/visual-screenshots (1)/images/675177ec55467292992f6c641b44352e.png +0 -0
- package/style/visual-screenshots (1)/images/679ff4b5301290556ec91463a47cf018.png +0 -0
- package/style/visual-screenshots (1)/images/67d9619b97865d42f5617413a025f62a.png +0 -0
- package/style/visual-screenshots (1)/images/686cdd39835b173225bd0b6ce4448b88.png +0 -0
- package/style/visual-screenshots (1)/images/6874ed35cef726f65cda16ed1d544b35.png +0 -0
- package/style/visual-screenshots (1)/images/68a92328d49b056ca74e3abe51c91d76.png +0 -0
- package/style/visual-screenshots (1)/images/68b78b4cec15c23fa5e7d0148bead95f.png +0 -0
- package/style/visual-screenshots (1)/images/68bca5cfcf4cb2cf91bbae3869730a14.png +0 -0
- package/style/visual-screenshots (1)/images/68c9260329ceafbae03b1cf59a2dc832.png +0 -0
- package/style/visual-screenshots (1)/images/698a7f9c8600bee3c0154879e8642fb8.png +0 -0
- package/style/visual-screenshots (1)/images/698be3296b927df039453c078d8c5e90.png +0 -0
- package/style/visual-screenshots (1)/images/69995300e1755ca4f61767ebb603e28d.png +0 -0
- package/style/visual-screenshots (1)/images/69b579e4e3d21f8d7c6bb64fa7dec383.png +0 -0
- package/style/visual-screenshots (1)/images/69c6368a387225497235ea4cabbbe05d.png +0 -0
- package/style/visual-screenshots (1)/images/69cdde73ed1979a49fa379514fb747ea.png +0 -0
- package/style/visual-screenshots (1)/images/69d4879c64376442acf44968fb02d9a6.png +0 -0
- package/style/visual-screenshots (1)/images/6a152f420237560d826a59b1ba95c6e8.png +0 -0
- package/style/visual-screenshots (1)/images/6a1e34197166e3475343c3ba9a4ce398.png +0 -0
- package/style/visual-screenshots (1)/images/6a2d5d8d6ff350c3b22a97e221506c72.png +0 -0
- package/style/visual-screenshots (1)/images/6a7102578dc5e69e6eed2dd81169959d.png +0 -0
- package/style/visual-screenshots (1)/images/6a76062bfc3391871480fbaed258138f.png +0 -0
- package/style/visual-screenshots (1)/images/6a98dfe1e3633e72cf1fc24d6f6b641b.png +0 -0
- package/style/visual-screenshots (1)/images/6abbbe132416f98c6a1cb3a1897cc551.png +0 -0
- package/style/visual-screenshots (1)/images/6b443b374cbe7fd349b21cd82a439dd6.png +0 -0
- package/style/visual-screenshots (1)/images/6bb098fcece5553a617d03e539e2b14d.png +0 -0
- package/style/visual-screenshots (1)/images/6bcde51c95aafa27fed83fd83b8f0397.png +0 -0
- package/style/visual-screenshots (1)/images/6c156cba7e8245e73aefe4afbd35276d.png +0 -0
- package/style/visual-screenshots (1)/images/6c569ef8ad97932e1a82ac1ed9e30960.png +0 -0
- package/style/visual-screenshots (1)/images/6c91461ed0c3153c9c403d1ab687dbe5.png +0 -0
- package/style/visual-screenshots (1)/images/6cae73cd2745b0af1530ae4e9cb9ebfa.png +0 -0
- package/style/visual-screenshots (1)/images/6d470bf081f9dfcf72f63d5ef93e627e.png +0 -0
- package/style/visual-screenshots (1)/images/6d6fcb40cbe35f57b4a2caced4ab52c1.png +0 -0
- package/style/visual-screenshots (1)/images/6d8758b4434c1abb115eb61256323a84.png +0 -0
- package/style/visual-screenshots (1)/images/6d8bd755e87330765b74bce670116692.png +0 -0
- package/style/visual-screenshots (1)/images/6e42402b7dd8bc3a23292b766284e384.png +0 -0
- package/style/visual-screenshots (1)/images/6e9e15b49f9bd7e2b60f666b85f4c3b7.png +0 -0
- package/style/visual-screenshots (1)/images/6ecd70c7e06430c86fd514a412dcc6f4.png +0 -0
- package/style/visual-screenshots (1)/images/6f3b3334cd7e0046e583348aa29babcf.png +0 -0
- package/style/visual-screenshots (1)/images/6f5da1c8d233cf9d5e8e88fd2ef3ec0a.png +0 -0
- package/style/visual-screenshots (1)/images/6fa2cf8bec030e4a0749e769ba026482.png +0 -0
- package/style/visual-screenshots (1)/images/6fe1a8093050cb06ea5b1c3334503e24.png +0 -0
- package/style/visual-screenshots (1)/images/7005941c708d4fec5abcdc7e6e10bab8.png +0 -0
- package/style/visual-screenshots (1)/images/700ade8610923958d3f90d68dfa4e05b.png +0 -0
- package/style/visual-screenshots (1)/images/7038ca0faeb969aa8e7e62cd4f626e6f.png +0 -0
- package/style/visual-screenshots (1)/images/706755c17ed932b4bef33524f6daa4f5.png +0 -0
- package/style/visual-screenshots (1)/images/706dfb70e1074e2aad57ab8526b0f360.png +0 -0
- package/style/visual-screenshots (1)/images/70a28845b5c345c56575b55667b70da1.png +0 -0
- package/style/visual-screenshots (1)/images/70b41db21992f19bda5e6b0f70c1fc09.png +0 -0
- package/style/visual-screenshots (1)/images/70bdf7355dba6c76a2d79bde106e6d1d.png +0 -0
- package/style/visual-screenshots (1)/images/70be87330902c743947ed9e77285f871.png +0 -0
- package/style/visual-screenshots (1)/images/70c8dce297f073384a4e8079bff68adf.png +0 -0
- package/style/visual-screenshots (1)/images/7129b9342de7f5e37c6eeeb9e174e2de.png +0 -0
- package/style/visual-screenshots (1)/images/715b51ef2b67f378bba07e7ad9343754.png +0 -0
- package/style/visual-screenshots (1)/images/71efbcd39c9d1ace0e25003ceb0db23e.png +0 -0
- package/style/visual-screenshots (1)/images/7245e631025f99f3554df69b14a843fa.png +0 -0
- package/style/visual-screenshots (1)/images/7268f09b0b1a0e124434eca4bbd818fa.png +0 -0
- package/style/visual-screenshots (1)/images/7329d3d684fa7430845616c496c3e3d5.png +0 -0
- package/style/visual-screenshots (1)/images/73ff7a530dde350815d23ff6a24031a0.png +0 -0
- package/style/visual-screenshots (1)/images/743a4ff37dbc8c26ed1379fad764407d.png +0 -0
- package/style/visual-screenshots (1)/images/745ce91134a9c726aee22be8e5dfcd28.png +0 -0
- package/style/visual-screenshots (1)/images/7476eb8a4b6b6c21d7366cd7b839cd8e.png +0 -0
- package/style/visual-screenshots (1)/images/74a5d110629e8bed44951ecc69d46e37.png +0 -0
- package/style/visual-screenshots (1)/images/74d2a451e8fe666e4cdd4ee104e3fbcb.png +0 -0
- package/style/visual-screenshots (1)/images/76dcdcc9887459636f81578fa8e72f0d.png +0 -0
- package/style/visual-screenshots (1)/images/772fd7072ade47ddd50f5daf9fe78b06.png +0 -0
- package/style/visual-screenshots (1)/images/77555003b57945e07b81f4bbc8da45a5.png +0 -0
- package/style/visual-screenshots (1)/images/7845c6559ae2b8cfa3eec51d52e628c1.png +0 -0
- package/style/visual-screenshots (1)/images/784772bde66cc378572a46b681b6cafe.png +0 -0
- package/style/visual-screenshots (1)/images/791f88fcb8a69681a876b21c6059e038.png +0 -0
- package/style/visual-screenshots (1)/images/7a14e2ed34311c3ddd03ab2b7e8b57e5.png +0 -0
- package/style/visual-screenshots (1)/images/7a5376f8127ccbce92efa2dc7d6e434a.png +0 -0
- package/style/visual-screenshots (1)/images/7b05dd84aacb821c812f835a0580c001.png +0 -0
- package/style/visual-screenshots (1)/images/7b11547ab77114942b3590f5274ccb36.png +0 -0
- package/style/visual-screenshots (1)/images/7b6676b606f3fd4fa89d824c97473517.png +0 -0
- package/style/visual-screenshots (1)/images/7b6e5af31520f5e8813017dd4f98c8d6.png +0 -0
- package/style/visual-screenshots (1)/images/7b89bf68bb12f5cee6947bd5af2520d7.png +0 -0
- package/style/visual-screenshots (1)/images/7b90db4c1dcaeed7cf71f5bae65d327a.png +0 -0
- package/style/visual-screenshots (1)/images/7bb540ca4abee17cdffe6944c8ff0948.png +0 -0
- package/style/visual-screenshots (1)/images/7c01812ede9c4d58571ccf59904bb1b1.png +0 -0
- package/style/visual-screenshots (1)/images/7c096666a0954392e0d657c8759963eb.png +0 -0
- package/style/visual-screenshots (1)/images/7c7593da4f5a9d04f800284023edb554.png +0 -0
- package/style/visual-screenshots (1)/images/7c82ecbc586641289f31f0cc27b017cd.png +0 -0
- package/style/visual-screenshots (1)/images/7c8e1def6b12da12f07536140e2b88b3.png +0 -0
- package/style/visual-screenshots (1)/images/7c916534306207f114d952bfe9340e5e.png +0 -0
- package/style/visual-screenshots (1)/images/7d3331d3cf93defe00a04cd10c57c6c6.png +0 -0
- package/style/visual-screenshots (1)/images/7da3d1c71e1e4b088f77e751a940b6a2.png +0 -0
- package/style/visual-screenshots (1)/images/7da65ded5bfe4c858e0c24ff1e1aa22d.png +0 -0
- package/style/visual-screenshots (1)/images/7daca2b5b705d27e8d5090f7dbb8acac.png +0 -0
- package/style/visual-screenshots (1)/images/7e8b4c9c2ac796fd5c5c730a430ef2e4.png +0 -0
- package/style/visual-screenshots (1)/images/7f06654399aca40b333099bec24468af.png +0 -0
- package/style/visual-screenshots (1)/images/7f8ae3d8e54291115e892c51d485df16.png +0 -0
- package/style/visual-screenshots (1)/images/7fb8ddb922c39be025d60076f51efcbd.png +0 -0
- package/style/visual-screenshots (1)/images/7fc57b3e4c1d14d0a86891a6c80ff12f.png +0 -0
- package/style/visual-screenshots (1)/images/8062b189081773e44a640a8d067046a0.png +0 -0
- package/style/visual-screenshots (1)/images/8083c957effa18fb290a5b0bdf2ad6cb.png +0 -0
- package/style/visual-screenshots (1)/images/80bbb318ca9792a3f16de017ea346d0c.png +0 -0
- package/style/visual-screenshots (1)/images/81c89f3dbeafdd793458d9339c7c607b.png +0 -0
- package/style/visual-screenshots (1)/images/81d7507828e5d8d66f7e161f74e45405.png +0 -0
- package/style/visual-screenshots (1)/images/82045c605de46b4aa7f386601ddb8884.png +0 -0
- package/style/visual-screenshots (1)/images/8245fbfd4b80b96b0254563f86b726ba.png +0 -0
- package/style/visual-screenshots (1)/images/82497fc1570674a5421e926475feac1b.png +0 -0
- package/style/visual-screenshots (1)/images/8252196c9f384ba181cc026acd29d928.png +0 -0
- package/style/visual-screenshots (1)/images/82706af2011a1e7149813131c420a1fa.png +0 -0
- package/style/visual-screenshots (1)/images/82a37a51e30a418ac408149f02adbbee.png +0 -0
- package/style/visual-screenshots (1)/images/83080cdc524b169211c70c9dfdb6fd9e.png +0 -0
- package/style/visual-screenshots (1)/images/830ba1a526dd905bce415b056de3ddb9.png +0 -0
- package/style/visual-screenshots (1)/images/833dc08e69770233fa3915653b3dfb4d.png +0 -0
- package/style/visual-screenshots (1)/images/8375d9df6b63faa9f30eda79e8c80a83.png +0 -0
- package/style/visual-screenshots (1)/images/839c2b39bcaa6830906b9da5d890c1ae.png +0 -0
- package/style/visual-screenshots (1)/images/8431110776be033ec282fd895a9ae813.png +0 -0
- package/style/visual-screenshots (1)/images/851318a57f46c9da1144fe8faf984da4.png +0 -0
- package/style/visual-screenshots (1)/images/8514c1d4ee26054ee07d11a0fe33f0db.png +0 -0
- package/style/visual-screenshots (1)/images/855d767000e9a4a272a2e753628a8474.png +0 -0
- package/style/visual-screenshots (1)/images/85d83f9f94a1adc9dcb60e0c13db29c1.png +0 -0
- package/style/visual-screenshots (1)/images/86236e1f7726cc775fdfbd9d967b892e.png +0 -0
- package/style/visual-screenshots (1)/images/865d7994dfb71cc52f659c784ab77089.png +0 -0
- package/style/visual-screenshots (1)/images/867dba1a3a0e5d10d9852a57eaf4f7f2.png +0 -0
- package/style/visual-screenshots (1)/images/868a694b756597afd5cbd8991ed9fa6e.png +0 -0
- package/style/visual-screenshots (1)/images/86fd1791a257ca240a96d32f587a6798.png +0 -0
- package/style/visual-screenshots (1)/images/8731210b8a1307c635c914344026cd7c.png +0 -0
- package/style/visual-screenshots (1)/images/874d6a50e723c879a585b73e4e54229b.png +0 -0
- package/style/visual-screenshots (1)/images/8753b744d14e6bf1be2fd926a564c3e9.png +0 -0
- package/style/visual-screenshots (1)/images/87eeecd4041819cac6f766c67f879a0d.png +0 -0
- package/style/visual-screenshots (1)/images/8816c9e1431fdfd5465d5a40c052309b.png +0 -0
- package/style/visual-screenshots (1)/images/885b77ceaf7e7a8908fd5b147c5a5217.png +0 -0
- package/style/visual-screenshots (1)/images/8923cdd532219aac9e71558dbd1186f9.png +0 -0
- package/style/visual-screenshots (1)/images/894bd3d4137d2ca7f4f71b2d53de379c.png +0 -0
- package/style/visual-screenshots (1)/images/8a801b5532051d67612de96df713f59a.png +0 -0
- package/style/visual-screenshots (1)/images/8aca19545cb02a7fd00f5d84a1fc4ee1.png +0 -0
- package/style/visual-screenshots (1)/images/8ae35388a8ed4604acc175b6953b1a12.png +0 -0
- package/style/visual-screenshots (1)/images/8b12f8f1234a0fdcd5cb800f5fdd4704.png +0 -0
- package/style/visual-screenshots (1)/images/8b674a86e1db9dda1dedaa07cc25a569.png +0 -0
- package/style/visual-screenshots (1)/images/8b7cd1fafd046cdd7200189a3a8e424f.png +0 -0
- package/style/visual-screenshots (1)/images/8ba1ee43c2d10f779da98898000d6d6f.png +0 -0
- package/style/visual-screenshots (1)/images/8bfc88f25acf24bb557f3790231b9cc5.png +0 -0
- package/style/visual-screenshots (1)/images/8c0bc63f7d57338b59338292b4d20e1c.png +0 -0
- package/style/visual-screenshots (1)/images/8c2a062564d8b55e5686d80995c0132e.png +0 -0
- package/style/visual-screenshots (1)/images/8c98ce176a13df14843cbb6423fd6440.png +0 -0
- package/style/visual-screenshots (1)/images/8cc5eded9abb67747e8a18cefb51df6d.png +0 -0
- package/style/visual-screenshots (1)/images/8d31ec4d9f7bbc9f753f70f2e2fe7781.png +0 -0
- package/style/visual-screenshots (1)/images/8d4761d0c860b4bdc923c78a60c6c7db.png +0 -0
- package/style/visual-screenshots (1)/images/8d8c786a27f502d297333e0f65e5fe7e.png +0 -0
- package/style/visual-screenshots (1)/images/8da3dcbc2a7e12489844a3d5e034ce78.png +0 -0
- package/style/visual-screenshots (1)/images/8e4e5baa65c536003c41d48d4a9d468c.png +0 -0
- package/style/visual-screenshots (1)/images/8e8f3e052eed01419d45167ec3d31705.png +0 -0
- package/style/visual-screenshots (1)/images/8ec5450454d067c364839f82e25a956d.png +0 -0
- package/style/visual-screenshots (1)/images/8ed1408bb2065b8a868349005c1f140d.png +0 -0
- package/style/visual-screenshots (1)/images/8f1c9b14d29c9264c5491f98fa9de9e8.png +0 -0
- package/style/visual-screenshots (1)/images/8f5f36e9fcfb73d98fc44d844ead6bcd.png +0 -0
- package/style/visual-screenshots (1)/images/8f69a3e8bb80e42b327daa0413f484a3.png +0 -0
- package/style/visual-screenshots (1)/images/8fbd2b83ca71d26193f78355c1a7469d.png +0 -0
- package/style/visual-screenshots (1)/images/9026dfe577f38e5be6fec9dafa010056.png +0 -0
- package/style/visual-screenshots (1)/images/906cf5fcfc43ec7f7a1743b1fbba08d0.png +0 -0
- package/style/visual-screenshots (1)/images/909185691877d3ab730fbc98e563b5cc.png +0 -0
- package/style/visual-screenshots (1)/images/9093d74b6c429faa6d6098bb3b42122e.png +0 -0
- package/style/visual-screenshots (1)/images/90b4a73410a4a0f48bf9d2803fc71b38.png +0 -0
- package/style/visual-screenshots (1)/images/90c068953b90c743da83a12da5204a0e.png +0 -0
- package/style/visual-screenshots (1)/images/914841508f534fc579907f3ff4e94eda.png +0 -0
- package/style/visual-screenshots (1)/images/926a60a1ac5968259e786e8c4c8c9d26.png +0 -0
- package/style/visual-screenshots (1)/images/93f5b096a1eb89744a98d090479f90c9.png +0 -0
- package/style/visual-screenshots (1)/images/946bbf46e754018058a8a17e5781b37c.png +0 -0
- package/style/visual-screenshots (1)/images/94a53d14a1e5f3fcb2f22b91642dc2cb.png +0 -0
- package/style/visual-screenshots (1)/images/94f93fc2109c3efac0cc508846fc09c6.png +0 -0
- package/style/visual-screenshots (1)/images/953979d501129c69e5cc0e1fd9acedf9.png +0 -0
- package/style/visual-screenshots (1)/images/9554d90e572ac282fec64cefe1d65eae.png +0 -0
- package/style/visual-screenshots (1)/images/95a3854979faaf7e3da15b81212fdddd.png +0 -0
- package/style/visual-screenshots (1)/images/95d64ce8dc7d7f80747dbb433cbd69b2.png +0 -0
- package/style/visual-screenshots (1)/images/95f250a29638c7a592e162fe065bc851.png +0 -0
- package/style/visual-screenshots (1)/images/962f28dd09eac1fa2811894bf4be9b70.png +0 -0
- package/style/visual-screenshots (1)/images/964706df4434f4e905f967de3d3dc125.png +0 -0
- package/style/visual-screenshots (1)/images/9681d81d32fb1f90ca44c3f69b9f0921.png +0 -0
- package/style/visual-screenshots (1)/images/97660bd70cc5e96d6258c1ed95c0935c.png +0 -0
- package/style/visual-screenshots (1)/images/976ebf4299d8ca702219b1e74419f704.png +0 -0
- package/style/visual-screenshots (1)/images/97cf49835bd0c2bf7811a7bdf3be89bc.png +0 -0
- package/style/visual-screenshots (1)/images/97e8a0e95dcff699c46f9b1b88b87d8a.png +0 -0
- package/style/visual-screenshots (1)/images/9807fabc447e7dae30fbbe6754e02c0d.png +0 -0
- package/style/visual-screenshots (1)/images/98ee9e5fb88515a8dbf5fe0e091c993a.png +0 -0
- package/style/visual-screenshots (1)/images/9997cd9e92d50b13a900ecb22fc74e83.png +0 -0
- package/style/visual-screenshots (1)/images/9a0b82d87e48b2c9e146bfbd4b51a177.png +0 -0
- package/style/visual-screenshots (1)/images/9a41a04f72770185eb42d3941627c6a1.png +0 -0
- package/style/visual-screenshots (1)/images/9a5b6ff3d85a26850b93d3129de94bbc.png +0 -0
- package/style/visual-screenshots (1)/images/9a9397907d86e4bdce381d4017ec5c33.png +0 -0
- package/style/visual-screenshots (1)/images/9ae63f1d387740d15676acf9a5bc48b8.png +0 -0
- package/style/visual-screenshots (1)/images/9b00734aa8cbf1a9acd3fbf08c137b0a.png +0 -0
- package/style/visual-screenshots (1)/images/9b07449ac15dc7e1d1deb9b825be0924.png +0 -0
- package/style/visual-screenshots (1)/images/9b18a6ddb96cbd44795e2bbc536f4f2a.png +0 -0
- package/style/visual-screenshots (1)/images/9b4014c74037f975344b9ac678229e65.png +0 -0
- package/style/visual-screenshots (1)/images/9b5118241eb4c97880a8a53129b9ea63.png +0 -0
- package/style/visual-screenshots (1)/images/9b594e815378bc9a2ef6cd6251dc9d6b.png +0 -0
- package/style/visual-screenshots (1)/images/9bc0a1284fc2c56e95ff22ae764e02c0.png +0 -0
- package/style/visual-screenshots (1)/images/9bdf5a8be0ecbe48e58b74552e4c5888.png +0 -0
- package/style/visual-screenshots (1)/images/9ce93b76501e11f52d1d6c27c6d3afb7.png +0 -0
- package/style/visual-screenshots (1)/images/9d272894b4135cdb24bd6dd6d23dd421.png +0 -0
- package/style/visual-screenshots (1)/images/9d3806b2870669edff4fea8574250bf7.png +0 -0
- package/style/visual-screenshots (1)/images/9d6ec965e5a23731bd189dfbb3c80e84.png +0 -0
- package/style/visual-screenshots (1)/images/9da4037f79a0f2ad50f8adc04687eb12.png +0 -0
- package/style/visual-screenshots (1)/images/9dcd7eda71b2347d026409b2342b3e39.png +0 -0
- package/style/visual-screenshots (1)/images/9de702c3bb72425b0e61d0b4d5a30b82.png +0 -0
- package/style/visual-screenshots (1)/images/9e08fce5233bbc69e681eb1ef349acc0.png +0 -0
- package/style/visual-screenshots (1)/images/9ea6570856b521aa566047e92d0f8305.png +0 -0
- package/style/visual-screenshots (1)/images/9ebdf4d34c2713e0f0cedb0c778b2c35.png +0 -0
- package/style/visual-screenshots (1)/images/9ec5435fc1248519bcc369f282c010c9.png +0 -0
- package/style/visual-screenshots (1)/images/9ee6d0e821a1f9c789514aef157a40ee.png +0 -0
- package/style/visual-screenshots (1)/images/9f1bfd0ae43a5c83303dcf205dc86aac.png +0 -0
- package/style/visual-screenshots (1)/images/9f268b6848b910b5d9c8094077405609.png +0 -0
- package/style/visual-screenshots (1)/images/9f3bdce5cba7a4c333f3e4e32697ed1e.png +0 -0
- package/style/visual-screenshots (1)/images/9fa64b6dd5e2432e5ac5be0125de88c5.png +0 -0
- package/style/visual-screenshots (1)/images/a00ff5334e96e86b5de74ca70e158365.png +0 -0
- package/style/visual-screenshots (1)/images/a0273543e221b5e74f2f92eedff87bbf.png +0 -0
- package/style/visual-screenshots (1)/images/a0860b4739ea0bf437f0fa1dc983edcc.png +0 -0
- package/style/visual-screenshots (1)/images/a09b998ff83fe0c8ba190c43be2c8281.png +0 -0
- package/style/visual-screenshots (1)/images/a0a9b6948dfa55de2c2391e66f116bef.png +0 -0
- package/style/visual-screenshots (1)/images/a0d9fd7c91a3666c82a8a1d1473647ff.png +0 -0
- package/style/visual-screenshots (1)/images/a122b735ee40793efef3ad06ff66c62a.png +0 -0
- package/style/visual-screenshots (1)/images/a1595ea5cac31981a01027ab16de609d.png +0 -0
- package/style/visual-screenshots (1)/images/a19c2ba30b43cb891f2536ebda33b5b9.png +0 -0
- package/style/visual-screenshots (1)/images/a19daa3bfb03b36036e5954c38b3c09b.png +0 -0
- package/style/visual-screenshots (1)/images/a1c13afc2158133f6f248eeec0c213c9.png +0 -0
- package/style/visual-screenshots (1)/images/a234da24efdb5886b5017293c9ec4983.png +0 -0
- package/style/visual-screenshots (1)/images/a267c84cc70ffcfd9f9098872b4d0e33.png +0 -0
- package/style/visual-screenshots (1)/images/a29ab04f7b14796a43ec1004d07e1191.png +0 -0
- package/style/visual-screenshots (1)/images/a331b266be3fe60d1510fc44c8462f8b.png +0 -0
- package/style/visual-screenshots (1)/images/a3b55159499c5529bdb159350ea483f8.png +0 -0
- package/style/visual-screenshots (1)/images/a3d54f0bbe60534633595f92c0af0606.png +0 -0
- package/style/visual-screenshots (1)/images/a3f82ac3c6348fa4452a198cb503860d.png +0 -0
- package/style/visual-screenshots (1)/images/a481b24ed810261cbae6bce62a1fd6da.png +0 -0
- package/style/visual-screenshots (1)/images/a4da8641e0ebce45d567a27b1b9d71c9.png +0 -0
- package/style/visual-screenshots (1)/images/a4e17fa06168594ff442f3d84ca346e0.png +0 -0
- package/style/visual-screenshots (1)/images/a4ec66bb6e0a2bf7d26898a7ec6fa6cb.png +0 -0
- package/style/visual-screenshots (1)/images/a4f5b46346578f27b509ab8ba9062b2a.png +0 -0
- package/style/visual-screenshots (1)/images/a524cc5916040ea0985aa14f5039cd08.png +0 -0
- package/style/visual-screenshots (1)/images/a56c0004f5f488bc5f4f8812479ff919.png +0 -0
- package/style/visual-screenshots (1)/images/a5760e6af3aac912f3c69d88eabc9571.png +0 -0
- package/style/visual-screenshots (1)/images/a5823b26b36bef69818dc786e72722c7.png +0 -0
- package/style/visual-screenshots (1)/images/a59e098a82b3b2b4a8e6e6e0ae9a82ee.png +0 -0
- package/style/visual-screenshots (1)/images/a5b60fb10746df7698e43bccb21df11b.png +0 -0
- package/style/visual-screenshots (1)/images/a5e9bd136ccd404fa0c0a275e757246f.png +0 -0
- package/style/visual-screenshots (1)/images/a62e4c8295a725e4a66cc2ec4408c4bd.png +0 -0
- package/style/visual-screenshots (1)/images/a6492327cb0dabcd2d74dbd1816f422d.png +0 -0
- package/style/visual-screenshots (1)/images/a6cfa33b833e8507b5f3cbfa260ee54f.png +0 -0
- package/style/visual-screenshots (1)/images/a75a60a4aa5b275fd399051abf56d08e.png +0 -0
- package/style/visual-screenshots (1)/images/a770465023ed9653c5209e93264e927e.png +0 -0
- package/style/visual-screenshots (1)/images/a83dbd9419c386d226bee5eda2e6673b.png +0 -0
- package/style/visual-screenshots (1)/images/a87075c6eb331fcab77dedffee6c8321.png +0 -0
- package/style/visual-screenshots (1)/images/a8b8f7209998b3d0a72b9719083dc02a.png +0 -0
- package/style/visual-screenshots (1)/images/a9a1de0b8dd7b6ccab5b47f73dd7f842.png +0 -0
- package/style/visual-screenshots (1)/images/a9c7c835f865512a77038fc5c15de21b.png +0 -0
- package/style/visual-screenshots (1)/images/aa30e7b644de69d60faa5380ca95c5a1.png +0 -0
- package/style/visual-screenshots (1)/images/aa4abb72226bb8321d4b9258f9857b71.png +0 -0
- package/style/visual-screenshots (1)/images/aa51db31d331669430896690342d81dc.png +0 -0
- package/style/visual-screenshots (1)/images/aa9b522302f4dd7150ecbfbb275320e6.png +0 -0
- package/style/visual-screenshots (1)/images/aaa1b0619e13093f63d4156375b60010.png +0 -0
- package/style/visual-screenshots (1)/images/ab5d93b635bae2b5fe23f583eac012ce.png +0 -0
- package/style/visual-screenshots (1)/images/abb03b840550301215bf11bcfc214de4.png +0 -0
- package/style/visual-screenshots (1)/images/ac03f528e1ea478ed33ba9fb5322e3fb.png +0 -0
- package/style/visual-screenshots (1)/images/ac1974812f40ea59d34307ac02a5f70c.png +0 -0
- package/style/visual-screenshots (1)/images/ac2cf23c673a4453be9f71a678bf457e.png +0 -0
- package/style/visual-screenshots (1)/images/ac4258921c4fac19bf9d885fe18d1783.png +0 -0
- package/style/visual-screenshots (1)/images/ac5b064d25b63e5ecd63a91d495dfe5b.png +0 -0
- package/style/visual-screenshots (1)/images/ac8524eb52a8b18d3727f9755658f457.png +0 -0
- package/style/visual-screenshots (1)/images/acd224f13e0e43e4d81990ea06b683f1.png +0 -0
- package/style/visual-screenshots (1)/images/acd8684a795357b531129eb92d03dbf0.png +0 -0
- package/style/visual-screenshots (1)/images/ace6a74377e1fd6f83aa5dba48c8f4ee.png +0 -0
- package/style/visual-screenshots (1)/images/ad0b716887153cae4ebdd7a50e332ad1.png +0 -0
- package/style/visual-screenshots (1)/images/ad74bf7ecefe38d32f843eac59d05bcf.png +0 -0
- package/style/visual-screenshots (1)/images/adad3039bbf24803cc0c800fa1ab52b2.png +0 -0
- package/style/visual-screenshots (1)/images/add742b5f9addb0c591ef066157dd0d7.png +0 -0
- package/style/visual-screenshots (1)/images/adf3ec3a8e97c3b33e77394946ad2434.png +0 -0
- package/style/visual-screenshots (1)/images/adfd03e01df5610028a7b8c22de1d1b5.png +0 -0
- package/style/visual-screenshots (1)/images/ae308ee925b5ad76aea7d7c989003c6c.png +0 -0
- package/style/visual-screenshots (1)/images/ae5ba79ab620185002de1e0e2869fea8.png +0 -0
- package/style/visual-screenshots (1)/images/aed0d8ffabcb9d4680499b39bb909cfb.png +0 -0
- package/style/visual-screenshots (1)/images/af5ce31cf5f312b6bda76f748fabb52f.png +0 -0
- package/style/visual-screenshots (1)/images/af77365d82e0f07b3957f3c77dfa5810.png +0 -0
- package/style/visual-screenshots (1)/images/afc1be11da46a18bb8982a85c65fb4b0.png +0 -0
- package/style/visual-screenshots (1)/images/b011549fe677ebb17fa307dbc03d36d9.png +0 -0
- package/style/visual-screenshots (1)/images/b0bff9f5d7141b079b666e5fb16abd22.png +0 -0
- package/style/visual-screenshots (1)/images/b0dbbbef7ff3804d58ce28e9685b88e0.png +0 -0
- package/style/visual-screenshots (1)/images/b0dfa6af25989c4c3d2e9aef64daab17.png +0 -0
- package/style/visual-screenshots (1)/images/b10bf8e372bca5d68241320f75bc1748.png +0 -0
- package/style/visual-screenshots (1)/images/b10ed3d6ec38c9c253a4446e106e75ea.png +0 -0
- package/style/visual-screenshots (1)/images/b141a65b0038d524dd290c00eddace3d.png +0 -0
- package/style/visual-screenshots (1)/images/b16111054dc7e5c31d822180d54ea0e6.png +0 -0
- package/style/visual-screenshots (1)/images/b1776e0a89f070ea680f256ed27ebf1e.png +0 -0
- package/style/visual-screenshots (1)/images/b27ff00e501d23c43b509c1a0168ef39.png +0 -0
- package/style/visual-screenshots (1)/images/b2aa4c06bcefcb7c92204acdd30d3197.png +0 -0
- package/style/visual-screenshots (1)/images/b2fef056d1f15f4ba8619f31541dd0e5.png +0 -0
- package/style/visual-screenshots (1)/images/b35f5b3650f7806ab3390e0ba67df1a4.png +0 -0
- package/style/visual-screenshots (1)/images/b3dd87d68dcdfd82fa97cdf4e39c2b27.png +0 -0
- package/style/visual-screenshots (1)/images/b3e5876c63e8256843b4090dc4b441ad.png +0 -0
- package/style/visual-screenshots (1)/images/b3f19d58a18bfd34f92764ec41877c3c.png +0 -0
- package/style/visual-screenshots (1)/images/b43533c13c416aad326bc67d0f44929e.png +0 -0
- package/style/visual-screenshots (1)/images/b4382971635528760348cbe2b70605fe.png +0 -0
- package/style/visual-screenshots (1)/images/b45844d5501be7c8431cc1306e3f3ae5.png +0 -0
- package/style/visual-screenshots (1)/images/b468a14b6c8e54db94b61c71b9662af0.png +0 -0
- package/style/visual-screenshots (1)/images/b4a02c9fc04ef4dc159e7beccd7ccfa7.png +0 -0
- package/style/visual-screenshots (1)/images/b4b41ceb35d80f9f629859558b75b19e.png +0 -0
- package/style/visual-screenshots (1)/images/b4edb5a1c390edd5c541c18e1a4ab68f.png +0 -0
- package/style/visual-screenshots (1)/images/b513f66c5fdbab3a28e7db1b23bfb8c2.png +0 -0
- package/style/visual-screenshots (1)/images/b5160b2c865a5e7b7d8b1e1abbf8d002.png +0 -0
- package/style/visual-screenshots (1)/images/b52890091cf696f0150eae61232cb1dd.png +0 -0
- package/style/visual-screenshots (1)/images/b56bb2b3dd4141b8e698820a515b8798.png +0 -0
- package/style/visual-screenshots (1)/images/b5af14253c4cc74f16ddb0b6164f185c.png +0 -0
- package/style/visual-screenshots (1)/images/b63069789fa7ac11755ea759d30a64a5.png +0 -0
- package/style/visual-screenshots (1)/images/b651f7f296cf9f30e419d94a8c4895cf.png +0 -0
- package/style/visual-screenshots (1)/images/b65482e30ffb8bec6c85103dcb71113d.png +0 -0
- package/style/visual-screenshots (1)/images/b65b4bdb5c82820722ea76182517bc74.png +0 -0
- package/style/visual-screenshots (1)/images/b65b9d44dcba156ab3152a6ee2592277.png +0 -0
- package/style/visual-screenshots (1)/images/b68552f8eb800b1891a49bf1cd4d987d.png +0 -0
- package/style/visual-screenshots (1)/images/b68eacd41b21135a2c2431a3ddc2dae5.png +0 -0
- package/style/visual-screenshots (1)/images/b6a9a44405f5e4034c95f55ee8aed681.png +0 -0
- package/style/visual-screenshots (1)/images/b6d2d0f7d50094fd163351d07a5e9251.png +0 -0
- package/style/visual-screenshots (1)/images/b6ec4162d1414d4011b787dd127bad96.png +0 -0
- package/style/visual-screenshots (1)/images/b6fe711492d73a1ad83be68fd782b5be.png +0 -0
- package/style/visual-screenshots (1)/images/b702cca4b4fe43f208a58f37e4a7d0c8.png +0 -0
- package/style/visual-screenshots (1)/images/b74e84ef684b263e0390552911c7b630.png +0 -0
- package/style/visual-screenshots (1)/images/b76dc3cd48583a70f3f99348e259a192.png +0 -0
- package/style/visual-screenshots (1)/images/b79d300707e6efd85959e1727354cda9.png +0 -0
- package/style/visual-screenshots (1)/images/b7f774a62a166681f5e34f4f92e7df96.png +0 -0
- package/style/visual-screenshots (1)/images/b85b4a6d8172ec3d4fe3875d1d5be438.png +0 -0
- package/style/visual-screenshots (1)/images/b8fd7356a98d56ee49951392bc0a19f5.png +0 -0
- package/style/visual-screenshots (1)/images/b9239778dee867ed3f14d2f3ffecd8d5.png +0 -0
- package/style/visual-screenshots (1)/images/b936ab1e543d95bd0c818b0d2ddade05.png +0 -0
- package/style/visual-screenshots (1)/images/b9afd9043e717ea55cd0a7c2e8768ec0.png +0 -0
- package/style/visual-screenshots (1)/images/b9b032bae3f927fc7492af0717480a7c.png +0 -0
- package/style/visual-screenshots (1)/images/ba1fea1b865b3beef1a1135bd779a706.png +0 -0
- package/style/visual-screenshots (1)/images/ba2cbf010b08ef17e500a9a6f09756eb.png +0 -0
- package/style/visual-screenshots (1)/images/ba900133c62ae20a043c8145deb72e61.png +0 -0
- package/style/visual-screenshots (1)/images/bab341bf211ffe1d1cdcff9735458a37.png +0 -0
- package/style/visual-screenshots (1)/images/bb54094e275897982cdadf3573cae164.png +0 -0
- package/style/visual-screenshots (1)/images/bb551e3ba230869e0f7f74597ebdc929.png +0 -0
- package/style/visual-screenshots (1)/images/bb5dc88ef581957bcde4779c0b6f96be.png +0 -0
- package/style/visual-screenshots (1)/images/bb671a54edc0e2807e0ee792010765ce.png +0 -0
- package/style/visual-screenshots (1)/images/bb6a7307e19bf9e4c588df181c01cf82.png +0 -0
- package/style/visual-screenshots (1)/images/bb9c61c2c52257e6ac08122fc873e0a5.png +0 -0
- package/style/visual-screenshots (1)/images/bb9d4ba104d323a504b867a9e7c26fa7.png +0 -0
- package/style/visual-screenshots (1)/images/bbfc81ede881c3480dedc09c932b357c.png +0 -0
- package/style/visual-screenshots (1)/images/bc69c3fc828d0ccd43620f5d7789f687.png +0 -0
- package/style/visual-screenshots (1)/images/bc6a45c5e234c06fe2909be16df5cd68.png +0 -0
- package/style/visual-screenshots (1)/images/bc7fbfc8cfa6fbaf42c181a83bc8f12e.png +0 -0
- package/style/visual-screenshots (1)/images/bc812929e7194062888770b42ea680fa.png +0 -0
- package/style/visual-screenshots (1)/images/bcf29c250245fcd6d4cd80fbb2076fe6.png +0 -0
- package/style/visual-screenshots (1)/images/bd0adcbbc6b9f54fd8dc2c45f91118cf.png +0 -0
- package/style/visual-screenshots (1)/images/bd2c0d240faaa73548693dd8792bd334.png +0 -0
- package/style/visual-screenshots (1)/images/bd3c8aca71ef1e1bfcf54c9bdf7ec0c1.png +0 -0
- package/style/visual-screenshots (1)/images/bd742a3ba78f04988baceee07b34b4c8.png +0 -0
- package/style/visual-screenshots (1)/images/bde82fcc550d92789d65c593e33b9fa1.png +0 -0
- package/style/visual-screenshots (1)/images/be0d5c5d87ffd9eb20686d37ded21477.png +0 -0
- package/style/visual-screenshots (1)/images/be2d1a5e2a20ec9e70974dfd8ad15c05.png +0 -0
- package/style/visual-screenshots (1)/images/be343f108940ac377accd7cd07cdd1e7.png +0 -0
- package/style/visual-screenshots (1)/images/be40fd335f837d2f5a1d803b3aed4c94.png +0 -0
- package/style/visual-screenshots (1)/images/bea6a7939bf5c8f3034f9f36d3aa83a0.png +0 -0
- package/style/visual-screenshots (1)/images/bed34ed4f9077f51952b51283f4b473b.png +0 -0
- package/style/visual-screenshots (1)/images/bedd63152750246fbfff2f3b8694840a.png +0 -0
- package/style/visual-screenshots (1)/images/bf112e6d28f4ea8ab3c84b88d685cb92.png +0 -0
- package/style/visual-screenshots (1)/images/bf1e7977779e36731e8cf90de8a2c018.png +0 -0
- package/style/visual-screenshots (1)/images/bfbf13672d796f88652747c1c627c225.png +0 -0
- package/style/visual-screenshots (1)/images/c14ed538a5d1e19c581b8a480a410873.png +0 -0
- package/style/visual-screenshots (1)/images/c1a6e457a74e6f1e39d8056a575c6b61.png +0 -0
- package/style/visual-screenshots (1)/images/c1bf639cb4ef73d3097a86bbe242e67b.png +0 -0
- package/style/visual-screenshots (1)/images/c1e92e74a76d59360620dd36a44b48d7.png +0 -0
- package/style/visual-screenshots (1)/images/c25a03ca4b6a75b60ca989c922a8c0ea.png +0 -0
- package/style/visual-screenshots (1)/images/c29a6ce74d404486b42547c80ac64827.png +0 -0
- package/style/visual-screenshots (1)/images/c2a8fd8eb01504bdf199bc631948fd65.png +0 -0
- package/style/visual-screenshots (1)/images/c2b2a82c12745e02edc5a4296e64952e.png +0 -0
- package/style/visual-screenshots (1)/images/c2e70eb9bba973017e04fde58f20439f.png +0 -0
- package/style/visual-screenshots (1)/images/c31b279c27c044ff8023b74161774d65.png +0 -0
- package/style/visual-screenshots (1)/images/c3de791621e788d6d096d488fdbf7eb7.png +0 -0
- package/style/visual-screenshots (1)/images/c4347eb0e8a14227ad18be6b9de1cbc7.png +0 -0
- package/style/visual-screenshots (1)/images/c45a7afc0498379e5b620ff4394e1759.png +0 -0
- package/style/visual-screenshots (1)/images/c4bd15f6119ec6a9f86c7311605b8e9a.png +0 -0
- package/style/visual-screenshots (1)/images/c5d033ba89e8621d33f0c1251f26cb94.png +0 -0
- package/style/visual-screenshots (1)/images/c5f4925f4e800c08c097ac6cb57973c4.png +0 -0
- package/style/visual-screenshots (1)/images/c645ca1d792395177ed9f550dc65ef98.png +0 -0
- package/style/visual-screenshots (1)/images/c66f1911986c1798aa132cfda4c757c1.png +0 -0
- package/style/visual-screenshots (1)/images/c6835996ac4b2b3f962a7c89245faa9e.png +0 -0
- package/style/visual-screenshots (1)/images/c7295480cd7fd4a11a50458bb4bfc9c3.png +0 -0
- package/style/visual-screenshots (1)/images/c76344aa17e7856258e6a7aba903caab.png +0 -0
- package/style/visual-screenshots (1)/images/c7bbfb83d1e415c898256cc0fdcce3ca.png +0 -0
- package/style/visual-screenshots (1)/images/c7c0f8a05585087c37d8209208bbcb54.png +0 -0
- package/style/visual-screenshots (1)/images/c7de1a12552658b7fe3ce32a7f7ffb3e.png +0 -0
- package/style/visual-screenshots (1)/images/c914e1a43cca34efae86f296ac56fdee.png +0 -0
- package/style/visual-screenshots (1)/images/c9861de44663e597f55adc84ea88e5fc.png +0 -0
- package/style/visual-screenshots (1)/images/c99d35eeb0dc348c34f4c8a9fe1c5f1d.png +0 -0
- package/style/visual-screenshots (1)/images/ca32c8781f959efc16e24eeda14cc2d5.png +0 -0
- package/style/visual-screenshots (1)/images/ca9c87751da7c73377da05d1cbf34974.png +0 -0
- package/style/visual-screenshots (1)/images/cab16e07722c54b790e38a8b9995af8f.png +0 -0
- package/style/visual-screenshots (1)/images/cb4e5d44970f3d22cfd664c95d5c23c6.png +0 -0
- package/style/visual-screenshots (1)/images/cb99b0bf33401c42eebea1020004a1a8.png +0 -0
- package/style/visual-screenshots (1)/images/cba574213771f455a9bd90fdd5711b82.png +0 -0
- package/style/visual-screenshots (1)/images/cc30aaecf3c497e88d6e7aecae1b7583.png +0 -0
- package/style/visual-screenshots (1)/images/cc690d6b70d361022b64cfd7e15aced7.png +0 -0
- package/style/visual-screenshots (1)/images/ccc7eefe88ff7124ce9b7256a2754224.png +0 -0
- package/style/visual-screenshots (1)/images/cd0ec559f03f247915ac7f28d051477f.png +0 -0
- package/style/visual-screenshots (1)/images/cda5b907bdad7cc13b55cb525ff72402.png +0 -0
- package/style/visual-screenshots (1)/images/ce19129cba94fa6ccfd2ab5416d93033.png +0 -0
- package/style/visual-screenshots (1)/images/ce3c54aab036c6395dd8817abc6acfc6.png +0 -0
- package/style/visual-screenshots (1)/images/ce4c143e3f25acaecf95fc6c74091386.png +0 -0
- package/style/visual-screenshots (1)/images/ce639e1186fedb84b5d709bf36126612.png +0 -0
- package/style/visual-screenshots (1)/images/ceca1dbf2a40a6524da989acf8c45825.png +0 -0
- package/style/visual-screenshots (1)/images/cecd8cd95992457e1748c3bb0dd14f35.png +0 -0
- package/style/visual-screenshots (1)/images/ced9cb27f2fe15debe7cae42e1b6347d.png +0 -0
- package/style/visual-screenshots (1)/images/cf8ad194e11dfdb8aea6017def809c6f.png +0 -0
- package/style/visual-screenshots (1)/images/cf95c3fcdb08ca9fd096c2aa90538a9f.png +0 -0
- package/style/visual-screenshots (1)/images/d055162ca44e10714f581c72517de67a.png +0 -0
- package/style/visual-screenshots (1)/images/d0907dbf3bbf9051d9ab0090a74eb8a2.png +0 -0
- package/style/visual-screenshots (1)/images/d0dbadb5f8a71fe6a666cf4741ba583e.png +0 -0
- package/style/visual-screenshots (1)/images/d0fc1daaab9d8154ac99b9923aca965e.png +0 -0
- package/style/visual-screenshots (1)/images/d10379d630b08ba69cdbadef68160b74.png +0 -0
- package/style/visual-screenshots (1)/images/d1dec19c84cc7d9d44d9bdbdc4ed0113.png +0 -0
- package/style/visual-screenshots (1)/images/d1ecf153cbe7e6e5ab9df3ba963ac56a.png +0 -0
- package/style/visual-screenshots (1)/images/d2085cde486b22d26ed3ed7dd092ac67.png +0 -0
- package/style/visual-screenshots (1)/images/d21f0611ffb064596292ba09f7ae0aa7.png +0 -0
- package/style/visual-screenshots (1)/images/d26da906f6e40a9f2de474ef00ffe192.png +0 -0
- package/style/visual-screenshots (1)/images/d32bdba3c211974c488f05e49fdbd38e.png +0 -0
- package/style/visual-screenshots (1)/images/d3f2e40808a135432120eec842002667.png +0 -0
- package/style/visual-screenshots (1)/images/d3f4fb7a3520050add88a228446786c0.png +0 -0
- package/style/visual-screenshots (1)/images/d42695727875489f5c823fc6a7637fc0.png +0 -0
- package/style/visual-screenshots (1)/images/d43099f8107adb7d25c029fd861236c7.png +0 -0
- package/style/visual-screenshots (1)/images/d465de97945852f83e9cfec896fda7fd.png +0 -0
- package/style/visual-screenshots (1)/images/d4cb357a97d0069493f671c36973b023.png +0 -0
- package/style/visual-screenshots (1)/images/d507e6178365edabfc44712f507b1ad4.png +0 -0
- package/style/visual-screenshots (1)/images/d5c0ef8532ff82ac36069cd1a325ef27.png +0 -0
- package/style/visual-screenshots (1)/images/d5d677892ed26746228c30990678ac38.png +0 -0
- package/style/visual-screenshots (1)/images/d5ea4a9c77534f236c32e8f31e078587.png +0 -0
- package/style/visual-screenshots (1)/images/d5f1ba6ddf9bbc40e86be0e2b82118af.png +0 -0
- package/style/visual-screenshots (1)/images/d6069a71d1cf53673964d866460d32c8.png +0 -0
- package/style/visual-screenshots (1)/images/d6242fd259465d2ba316d672684afcf7.png +0 -0
- package/style/visual-screenshots (1)/images/d6b1c4c2db737fef0105bc33cda83309.png +0 -0
- package/style/visual-screenshots (1)/images/d6c65a3c2f45d3f68984a0be5f3490bb.png +0 -0
- package/style/visual-screenshots (1)/images/d6f1781682597261b255669cebe81e42.png +0 -0
- package/style/visual-screenshots (1)/images/d7d9fb5a7dfc870527fb24b3642a56e3.png +0 -0
- package/style/visual-screenshots (1)/images/d7deed321c78b937b9aac780d75a67e6.png +0 -0
- package/style/visual-screenshots (1)/images/d8291cc7ad6e1607c344ed2ed1368ea3.png +0 -0
- package/style/visual-screenshots (1)/images/d8560f2f2aeb2cf5601aac513f502b55.png +0 -0
- package/style/visual-screenshots (1)/images/d8ba46aafe0f9c6e1a513c118e4ed9bc.png +0 -0
- package/style/visual-screenshots (1)/images/d95148fef77af3db17d99a9e6d582f37.png +0 -0
- package/style/visual-screenshots (1)/images/d9579cafca730bedcd047d6b5e00d6a4.png +0 -0
- package/style/visual-screenshots (1)/images/d98fa9b6727f84959b2953eb2fb4bbd9.png +0 -0
- package/style/visual-screenshots (1)/images/d9ccd1f0853f04288d98faaa99ffd839.png +0 -0
- package/style/visual-screenshots (1)/images/d9d48b2652b1aec6a09d29ff489a2559.png +0 -0
- package/style/visual-screenshots (1)/images/d9d72a2b10b10048726ee220b48fa527.png +0 -0
- package/style/visual-screenshots (1)/images/d9d8147e7f3bb24b517f342fcccde022.png +0 -0
- package/style/visual-screenshots (1)/images/d9df19d7691aa789d2a8bc95bf35da2c.png +0 -0
- package/style/visual-screenshots (1)/images/da1074f521e0588e392120962859f25f.png +0 -0
- package/style/visual-screenshots (1)/images/da3533dfa11d516896891b192864e447.png +0 -0
- package/style/visual-screenshots (1)/images/dae067c3ccb9466b05711591ecd99896.png +0 -0
- package/style/visual-screenshots (1)/images/db652f7540592f22fce8d51c2db86e93.png +0 -0
- package/style/visual-screenshots (1)/images/db68bc1a1dabafb95a485a230f9a8891.png +0 -0
- package/style/visual-screenshots (1)/images/db9207243bf814e40de5d4f04ca70316.png +0 -0
- package/style/visual-screenshots (1)/images/db9f75240f51bca9b761494cedeccff2.png +0 -0
- package/style/visual-screenshots (1)/images/dbc774ff92faa624b4987219fa52042d.png +0 -0
- package/style/visual-screenshots (1)/images/dc0de0f379b7b76e387beb9d57e912eb.png +0 -0
- package/style/visual-screenshots (1)/images/dd3dcde1007bc96a7e41eeb1436699a5.png +0 -0
- package/style/visual-screenshots (1)/images/dda39199ff0717086ab54dd718ad525f.png +0 -0
- package/style/visual-screenshots (1)/images/ddcd258c6ad4c8489c1b51df313691e9.png +0 -0
- package/style/visual-screenshots (1)/images/ddcf43a676ca66b76dd293e2217bff54.png +0 -0
- package/style/visual-screenshots (1)/images/ddf8772071d057082129df7ddb91cb63.png +0 -0
- package/style/visual-screenshots (1)/images/de538ffe7bb41fe54ed51f548dbe2fba.png +0 -0
- package/style/visual-screenshots (1)/images/df18d193dd77c73ceb593e100945b30d.png +0 -0
- package/style/visual-screenshots (1)/images/df7a11e9552448272332cb2a6d8194b8.png +0 -0
- package/style/visual-screenshots (1)/images/df8a111e64e1601833438a267e53d53e.png +0 -0
- package/style/visual-screenshots (1)/images/dfb1101ae11b4e4cbcd14e109f2c2810.png +0 -0
- package/style/visual-screenshots (1)/images/dfd25ea8862f0ef09292b87930278f8b.png +0 -0
- package/style/visual-screenshots (1)/images/e010fa0f10828dfec180f664eb3b904e.png +0 -0
- package/style/visual-screenshots (1)/images/e019e72c9310bf80c7d8a060b05b9c37.png +0 -0
- package/style/visual-screenshots (1)/images/e0fad740e1ea1190ae5bafcc312b7345.png +0 -0
- package/style/visual-screenshots (1)/images/e129f142d3b5053ef5be1eb5b2c3e892.png +0 -0
- package/style/visual-screenshots (1)/images/e166d553d849e0c78ef876004aad7a5f.png +0 -0
- package/style/visual-screenshots (1)/images/e16f3ba70a3637f3220f043e2135e130.png +0 -0
- package/style/visual-screenshots (1)/images/e1e5fe1fd5d6ee275513f269c86d6305.png +0 -0
- package/style/visual-screenshots (1)/images/e23bd037d12d40a0719647cc0e872a58.png +0 -0
- package/style/visual-screenshots (1)/images/e2a3a5bb4365d8f726c66cdd0502df93.png +0 -0
- package/style/visual-screenshots (1)/images/e2c01035d03336301a1d9b296c8d9ab3.png +0 -0
- package/style/visual-screenshots (1)/images/e2d8e8137e7670d15c4607f1d656477f.png +0 -0
- package/style/visual-screenshots (1)/images/e302c8e4a9ea160a0a19968825d55dab.png +0 -0
- package/style/visual-screenshots (1)/images/e34b18aac8583e91e021b41bbfd7fd5f.png +0 -0
- package/style/visual-screenshots (1)/images/e356cf56ccaa076bbc8d34dc8f793843.png +0 -0
- package/style/visual-screenshots (1)/images/e35d22101819324c038cd263e9c8f518.png +0 -0
- package/style/visual-screenshots (1)/images/e3805efcd137ad98512fa1c3f8d54a1d.png +0 -0
- package/style/visual-screenshots (1)/images/e39ce053c84fc3a5528ac4b5641ac9cf.png +0 -0
- package/style/visual-screenshots (1)/images/e3a3c7767a5eb9522dea438bff6728cc.png +0 -0
- package/style/visual-screenshots (1)/images/e3aab7603407b6e1b444b0eac170a7ec.png +0 -0
- package/style/visual-screenshots (1)/images/e43a752514e8b393cb628520b605b584.png +0 -0
- package/style/visual-screenshots (1)/images/e442163823ed8edcc7160818be69b398.png +0 -0
- package/style/visual-screenshots (1)/images/e4b10dde183f07a84513d76d429a6958.png +0 -0
- package/style/visual-screenshots (1)/images/e4d50b654335e71fc4967b82c344dbfe.png +0 -0
- package/style/visual-screenshots (1)/images/e51ca2c2a84b03fc98f79f02fe7068aa.png +0 -0
- package/style/visual-screenshots (1)/images/e58ef5ed950fbb2b1079d74d45b7c881.png +0 -0
- package/style/visual-screenshots (1)/images/e5ade203143dc82491aa076121660e52.png +0 -0
- package/style/visual-screenshots (1)/images/e605ecbc474952712389539463a04aa7.png +0 -0
- package/style/visual-screenshots (1)/images/e6262e247906000955ae8374d655a906.png +0 -0
- package/style/visual-screenshots (1)/images/e6595c721f80b610721aaeeb5e2f75a6.png +0 -0
- package/style/visual-screenshots (1)/images/e6709d9c191735263eb3b486e7a72f85.png +0 -0
- package/style/visual-screenshots (1)/images/e6d314422345a30bf6c0ef3e18e583a0.png +0 -0
- package/style/visual-screenshots (1)/images/e6d939c8648a17c13549f5f2adb346e7.png +0 -0
- package/style/visual-screenshots (1)/images/e6dbee568bfdc18e352b077e374ff82f.png +0 -0
- package/style/visual-screenshots (1)/images/e703bac13e2532ce5533d2a57a8a5fa6.png +0 -0
- package/style/visual-screenshots (1)/images/e716cb5e49fdadf37afefab471babf94.png +0 -0
- package/style/visual-screenshots (1)/images/e7441187368963e6b130042df812ef91.png +0 -0
- package/style/visual-screenshots (1)/images/e7c2f6b6c968145071f9cb8636dfbc3e.png +0 -0
- package/style/visual-screenshots (1)/images/e7e9cbbc3d0dd144406d6a315ec0ddc0.png +0 -0
- package/style/visual-screenshots (1)/images/e7fa6277441b9b69cc3b5306e16b7cf1.png +0 -0
- package/style/visual-screenshots (1)/images/e83fb6530e1c56b78ecf6b7ecf9093b4.png +0 -0
- package/style/visual-screenshots (1)/images/e84d5f9378fbad753243b00f534b5a2b.png +0 -0
- package/style/visual-screenshots (1)/images/e874c84e2c3efc6531e1ed444ef48e0c.png +0 -0
- package/style/visual-screenshots (1)/images/e880df04bcd581fdc14320972bb587c7.png +0 -0
- package/style/visual-screenshots (1)/images/e888e0e6d4a78e02b76328fa84356ca8.png +0 -0
- package/style/visual-screenshots (1)/images/e8ae475c96c0350cab5788186441a468.png +0 -0
- package/style/visual-screenshots (1)/images/e8b5543222dd07074f913c0ee347cc2a.png +0 -0
- package/style/visual-screenshots (1)/images/e92d837bf473dd88b1644ce81eeb8271.png +0 -0
- package/style/visual-screenshots (1)/images/e9690ff4793f30325dfc007d07f11515.png +0 -0
- package/style/visual-screenshots (1)/images/e9a4edf0d472871407e3de2a94491d38.png +0 -0
- package/style/visual-screenshots (1)/images/e9da22cdb0b57bbbb78d72fa243613f1.png +0 -0
- package/style/visual-screenshots (1)/images/e9f7a5fc6028e6009408ba7587604837.png +0 -0
- package/style/visual-screenshots (1)/images/ea87140d4d01e99436eb8517e1a59744.png +0 -0
- package/style/visual-screenshots (1)/images/eb1e5e278264b3344fd8251f8e3a567c.png +0 -0
- package/style/visual-screenshots (1)/images/eb270de24170c48625abe27e1add013b.png +0 -0
- package/style/visual-screenshots (1)/images/eb321262ddafb26c0121bd595505ffd4.png +0 -0
- package/style/visual-screenshots (1)/images/eb89e9322f47193680a195eedec9ca1f.png +0 -0
- package/style/visual-screenshots (1)/images/eb8ba90ad716449ab1fbe18715131465.png +0 -0
- package/style/visual-screenshots (1)/images/ebea496ec420dde6eb11929ef25c9d4e.png +0 -0
- package/style/visual-screenshots (1)/images/ec06a26e681c9d07ecb4aa29d4e551f4.png +0 -0
- package/style/visual-screenshots (1)/images/ec418171a7341bd39a64ee5e1405de5c.png +0 -0
- package/style/visual-screenshots (1)/images/ec801a1f7ded7e4f72b3b83d56ef137b.png +0 -0
- package/style/visual-screenshots (1)/images/eceac800e5e5ec35a7ac973102588b9a.png +0 -0
- package/style/visual-screenshots (1)/images/ed32af8a6de2ef712782d8c700d5ea9c.png +0 -0
- package/style/visual-screenshots (1)/images/ed996049ed03540673123208a1939af9.png +0 -0
- package/style/visual-screenshots (1)/images/edea0089834ada9ac7c1955bbc7b60e8.png +0 -0
- package/style/visual-screenshots (1)/images/ee0321657e33c16d1cafb4124cc8b84e.png +0 -0
- package/style/visual-screenshots (1)/images/ee2e3f6e90b8c2a479d187d5c33257d9.png +0 -0
- package/style/visual-screenshots (1)/images/ee5c6318a17593c06dc4893c84e64535.png +0 -0
- package/style/visual-screenshots (1)/images/ee880fd8c1965895a4c79cf4c744feac.png +0 -0
- package/style/visual-screenshots (1)/images/eed96dc07ed46b9585a3fa2f9655268f.png +0 -0
- package/style/visual-screenshots (1)/images/efcf97ad2d48fcce21b8052fb8e1f02d.png +0 -0
- package/style/visual-screenshots (1)/images/f02927c03369f309483a9c4ddf1dd918.png +0 -0
- package/style/visual-screenshots (1)/images/f033f0f98be280ace4c6d4b0366bb46f.png +0 -0
- package/style/visual-screenshots (1)/images/f039bdda30367e329cf997e85fe4c5e8.png +0 -0
- package/style/visual-screenshots (1)/images/f04add34ff27aa15ee72e77d143d3ed8.png +0 -0
- package/style/visual-screenshots (1)/images/f05fc5650db3e0ecc2baf3860da0d195.png +0 -0
- package/style/visual-screenshots (1)/images/f095476fc0248cf27fa814706177534f.png +0 -0
- package/style/visual-screenshots (1)/images/f0ca029abc93f4e8105da3e5ab56e1c4.png +0 -0
- package/style/visual-screenshots (1)/images/f136123d6a6e67a75080296043b5e5de.png +0 -0
- package/style/visual-screenshots (1)/images/f14f173c0407db4e2e0d465809e3035f.png +0 -0
- package/style/visual-screenshots (1)/images/f1c37fd272da405acfb07e2bcd9e2e86.png +0 -0
- package/style/visual-screenshots (1)/images/f1d9cb85975d8f2259098078a9801e0f.png +0 -0
- package/style/visual-screenshots (1)/images/f1ec44ad9bd197b6cf6709425b1f493c.png +0 -0
- package/style/visual-screenshots (1)/images/f2357c90c5bc52def3fac87e0ec9997a.png +0 -0
- package/style/visual-screenshots (1)/images/f27d1e0db5abfe19d41b8158d4d2e864.png +0 -0
- package/style/visual-screenshots (1)/images/f28b1b0716ee2f45646a13b5b5c25ece.png +0 -0
- package/style/visual-screenshots (1)/images/f2a9936c632f6d5df93af4b94ca90234.png +0 -0
- package/style/visual-screenshots (1)/images/f2e3472901c35c71c0182432ed609d7f.png +0 -0
- package/style/visual-screenshots (1)/images/f3492d235f8072e4adf1060958453ee6.png +0 -0
- package/style/visual-screenshots (1)/images/f3e92ee96aa91f49801ea4202f6081ac.png +0 -0
- package/style/visual-screenshots (1)/images/f43bdfc49eaa4bc64a3d388173c76744.png +0 -0
- package/style/visual-screenshots (1)/images/f43fae61c6f1cfb638fd3741f3742d5b.png +0 -0
- package/style/visual-screenshots (1)/images/f44444b4e7bcd9cc38987cfbca3c88bc.png +0 -0
- package/style/visual-screenshots (1)/images/f457b6c69704125d620b062e0a63c81d.png +0 -0
- package/style/visual-screenshots (1)/images/f49bdba18143e37cebfccebb84983aaa.png +0 -0
- package/style/visual-screenshots (1)/images/f4a592740204a611f064fd861eea879f.png +0 -0
- package/style/visual-screenshots (1)/images/f4b874f85d61abcdb5d4dac56574e983.png +0 -0
- package/style/visual-screenshots (1)/images/f4d48a8d20e7217ab3bd4eb920e2e90b.png +0 -0
- package/style/visual-screenshots (1)/images/f4fa32cbd842631dda4967bb7b0805f4.png +0 -0
- package/style/visual-screenshots (1)/images/f5a634ee1f8883b9a9910709b1a70dd9.png +0 -0
- package/style/visual-screenshots (1)/images/f5f154f17b8ddd7fe6584229e3e433dc.png +0 -0
- package/style/visual-screenshots (1)/images/f5f5aa0c94bc0096ca632bde832e4ac0.png +0 -0
- package/style/visual-screenshots (1)/images/f611a4b1de325f7426c8b29b43cfae35.png +0 -0
- package/style/visual-screenshots (1)/images/f63233f9dc04d7dcfd4ff56369f0b130.png +0 -0
- package/style/visual-screenshots (1)/images/f692554ff308ca1cd0fbe7a22b3b22ca.png +0 -0
- package/style/visual-screenshots (1)/images/f75eda47bbe4bbe2ea30a65b7856a44b.png +0 -0
- package/style/visual-screenshots (1)/images/f781be55c666aac6c83ca4d07e9c42ca.png +0 -0
- package/style/visual-screenshots (1)/images/f7bf00972a29fdf599c8217b28de96d6.png +0 -0
- package/style/visual-screenshots (1)/images/f86fea7ffab0866bda8a3b414f7cd3b7.png +0 -0
- package/style/visual-screenshots (1)/images/f87eb71c300ab4b2d498be9a55ee1618.png +0 -0
- package/style/visual-screenshots (1)/images/f8b36602184f5158860506fe64079c89.png +0 -0
- package/style/visual-screenshots (1)/images/f8ee607f6421ba60f973b9bff376ae28.png +0 -0
- package/style/visual-screenshots (1)/images/f9080ba22d397d83f09047ebdfe84239.png +0 -0
- package/style/visual-screenshots (1)/images/f9145ef284d04f6336229ff666af70e3.png +0 -0
- package/style/visual-screenshots (1)/images/f93aaf6c9ea9f70abb350f5255767c3f.png +0 -0
- package/style/visual-screenshots (1)/images/f95685e60e185b4b3da22bb8bf70e7e2.png +0 -0
- package/style/visual-screenshots (1)/images/f97ab81b758db662a2eb1617a6efe217.png +0 -0
- package/style/visual-screenshots (1)/images/fa7325e4f52bb809c79c2f8df2699b93.png +0 -0
- package/style/visual-screenshots (1)/images/fa793989f4717dd55b1c603086785688.png +0 -0
- package/style/visual-screenshots (1)/images/faab9362d2ff082b2ec255bd3f87f52c.png +0 -0
- package/style/visual-screenshots (1)/images/fad9c13edad825e537ef70d1f5ac9ffc.png +0 -0
- package/style/visual-screenshots (1)/images/faf67bf2491d228a3147ca1b197ce7c0.png +0 -0
- package/style/visual-screenshots (1)/images/fb0bba6fa80d2f1d58b9fe1a3cae80fd.png +0 -0
- package/style/visual-screenshots (1)/images/fb21968682604e963f859ce4a3063449.png +0 -0
- package/style/visual-screenshots (1)/images/fb2756dae46b9f5078e264cd3419bb7f.png +0 -0
- package/style/visual-screenshots (1)/images/fc344f5b8408cc30060f888515927391.png +0 -0
- package/style/visual-screenshots (1)/images/fca29f7a114d6e4df2ca093e1d9cf90a.png +0 -0
- package/style/visual-screenshots (1)/images/fced6958bf1d22d95b4609bb6cb90c07.png +0 -0
- package/style/visual-screenshots (1)/images/fd92b9e1229dbd6160436f5b92cd21b0.png +0 -0
- package/style/visual-screenshots (1)/images/fdf7376c972f3c4f40789c0f217c0480.png +0 -0
- package/style/visual-screenshots (1)/images/fe13a66e7e5ede78792937bf010f022c.png +0 -0
- package/style/visual-screenshots (1)/images/fe2c4234c413f4ad2d054fd091242f8e.png +0 -0
- package/style/visual-screenshots (1)/images/fe4603d37d7b7abc55ebda66bb81b8d9.png +0 -0
- package/style/visual-screenshots (1)/images/fe9188d474135ba66971a9ea60921c3d.png +0 -0
- package/style/visual-screenshots (1)/images/febb9b60ded19124b91a836fcbc37936.png +0 -0
- package/style/visual-screenshots (1)/images/fedb6514016e34df2fcb29eef107d385.png +0 -0
- package/style/visual-screenshots (1)/images/ff5d801d62c71a38028c2d406af30b8f.png +0 -0
- package/style/visual-screenshots (1)/images/ffa3e2813a91c22ec33346792ba47461.png +0 -0
- package/style/visual-screenshots (1)/images/ffb7b8ff61c2ce675eaeaa8104a3f178.png +0 -0
|
@@ -0,0 +1,4816 @@
|
|
|
1
|
+
import { I as InjectVegaTelemetrySlimmer, c as createPublicAPIRuntimeMetricsSlimmer, g as generateUUID } from './create-public-api-runtime-metrics-slimmer-bedf3a1e.js';
|
|
2
|
+
import { a as arrayToClassString, g as getDeviceType, D as DeviceType, f as findParent } from './ui-bb99c0c2.js';
|
|
3
|
+
import { L as LogUtility, I as InjectVegaSlimmer } from './global-slimmer-registry-17c4efd4.js';
|
|
4
|
+
import { c as createDynamicSlimmer } from './dynamic-slimmer-90b8af32.js';
|
|
5
|
+
import { P as PageResizeObserverSlimmer } from './page-resize-observer-slimmer-8744cb44.js';
|
|
6
|
+
import { V as VegaInternalThemeManager } from './dark-mode-style-controller-de88a117.js';
|
|
7
|
+
import { i as internalVegaEventManager } from './internal-vega-event-manager-4f51b17c.js';
|
|
8
|
+
import { c as convertToNumber } from './number-4398f2e1.js';
|
|
9
|
+
import { R as RTEDTORendererManager, a as RTEDTOActionStrategyManager, E as ElementToDTOClassStrategyManager, U as UpdateCursorPositionAction, b as ElementToDTOStrategy, h as htmlElementToAnnotationGenerator, c as RTEListItemBlock, V as VegaRTEContent, B as BlockToRTEBlockStrategyAbstract, I as InsertNewParagraphAction, d as RTEImageBlock, e as InsertChildrenBeforeStrategy, P as PasteContentStrategy } from './dto-renderer-manager-23784148.js';
|
|
10
|
+
import { s as stateEntityRenderingRegistry, A as ActionHandleStrategyRegistry, a as ActionHandlerInterceptorRegistry, R as RTEDTOClassManager, M as ModifyContentAction, b as RTETextNode, c as ModifyContentActionType, d as ActionHandleStrategy, C as CustomAttributeAnnotation, e as RTETextBlock, f as RTEBlock, g as RTEAnnotationStyle, I as InsertChildrenAfterAction, h as AppendChildrenAction, i as RTENode, j as InsertChildrenBeforeAction, k as InternalAnnotationTypeEnum, B as BlockAnnotation, l as RemoveChildrenAction } from './code-block-3d3a9030.js';
|
|
11
|
+
import { i as isNonNullable } from './type-guard-b48aec98.js';
|
|
12
|
+
import './translation-96e5debd.js';
|
|
13
|
+
import { a as VegaInternalIconManager } from './internal-icon-manager-f0486245.js';
|
|
14
|
+
import { R as RTETableExtensionAnnotationTypeEnum, S as SettingEventHandler, T as TableSettingType, a as RowOperationEventHandler, C as ColumnOperationEventHandler, r as remoteInvocationRegistry, b as RTETableBlock, g as generateTableBody, c as RTETableCellBlock, d as RTETableRowBlock, I as InsertTableRowDirection, e as RTETableBodyBlock, f as RTETableHeadBlock, h as getParentBlockByType, i as RTETableHeadCellBlock, j as TableColumnStrategy, k as getAllTableRows, l as InsertTableColumnDirection, m as getDefaultCellBlockTemplate, n as getFirstNode, o as INSERT_TABLE_ROW, D as DELETE_TABLE_ROW, p as TOGGLE_HEADER_ROW, q as INSERT_TABLE_COLUMN, s as DELETE_TABLE_COLUMN, t as TOGGLE_HEADER_TABLE_COLUMN, u as ToggleHeaderTableColumnStrategy, v as SELECT_TABLE_COLUMN } from './column-operation-4a93bf52.js';
|
|
15
|
+
import { c as cleanObject } from './object-66c37948.js';
|
|
16
|
+
import { V as VegaRTEBaseRenderer } from './base-renderer-101f6d04.js';
|
|
17
|
+
import { D as DomNodeSubjectObserverFactory, V as VegaDropdownClick, a as VegaClick, d as domNodeSubjectFactory, b as VegaPopoverShow, c as VegaPopoverHide } from './dom-node-subject-observer-factory-f81f215f.js';
|
|
18
|
+
import { V as VegaInternalPopoverUpdateTarget } from './vega-internal-event-id-54ce7562.js';
|
|
19
|
+
import { d as debounce } from './timer-9321173b.js';
|
|
20
|
+
import { t as tryGetDocument } from './try-get-document-bef0f526.js';
|
|
21
|
+
|
|
22
|
+
const VegaLoaderRuntimeMetricsPayloadDefinition = [
|
|
23
|
+
{
|
|
24
|
+
payloadKey: 'IS_LOAD_METHOD_CALLED',
|
|
25
|
+
payloadDescription: 'Indicate if the method load of public API VegaLoaderController is called',
|
|
26
|
+
/**
|
|
27
|
+
* Indicate whether the method is collected when the method been called .
|
|
28
|
+
*
|
|
29
|
+
* @param {string} scope - The class name of public api
|
|
30
|
+
* @param {string} methodName - The method name called by the public api
|
|
31
|
+
* @returns {boolean} A boolean value
|
|
32
|
+
*/
|
|
33
|
+
canAccept: (scope, methodName) => scope === 'VegaLoaderController' && methodName === 'load',
|
|
34
|
+
/**
|
|
35
|
+
* The function checks if the method name is load.
|
|
36
|
+
*
|
|
37
|
+
* @returns {boolean} A boolean value
|
|
38
|
+
*/
|
|
39
|
+
payloadValue: () => {
|
|
40
|
+
return true;
|
|
41
|
+
},
|
|
42
|
+
},
|
|
43
|
+
{
|
|
44
|
+
payloadKey: 'IS_CLOSE_METHOD_CALLED',
|
|
45
|
+
payloadDescription: 'Indicate if the method close of public API VegaLoaderController is called',
|
|
46
|
+
/**
|
|
47
|
+
* Indicate whether the method is collected when the method been called .
|
|
48
|
+
*
|
|
49
|
+
* @param {string} scope - The class name of public api
|
|
50
|
+
* @param {string} methodName - The method name called by the public api
|
|
51
|
+
* @returns {boolean} A boolean value
|
|
52
|
+
*/
|
|
53
|
+
canAccept: (scope, methodName) => scope === 'VegaLoaderController' && methodName === 'close',
|
|
54
|
+
/**
|
|
55
|
+
* The function checks if the method name is close.
|
|
56
|
+
*
|
|
57
|
+
* @returns {boolean} A boolean value
|
|
58
|
+
*/
|
|
59
|
+
payloadValue: () => {
|
|
60
|
+
return true;
|
|
61
|
+
},
|
|
62
|
+
},
|
|
63
|
+
];
|
|
64
|
+
|
|
65
|
+
var __decorate$6 = (undefined && undefined.__decorate) || function (decorators, target, key, desc) {
|
|
66
|
+
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
67
|
+
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
68
|
+
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
69
|
+
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
70
|
+
};
|
|
71
|
+
/**
|
|
72
|
+
* Vega loader controller to control the loading indicator
|
|
73
|
+
*/
|
|
74
|
+
class VegaLoaderController {
|
|
75
|
+
constructor() {
|
|
76
|
+
this.vegaPublicAPIRuntimeMetricsSlimmer = createPublicAPIRuntimeMetricsSlimmer(VegaLoaderController, ['load', 'close'], VegaLoaderRuntimeMetricsPayloadDefinition);
|
|
77
|
+
}
|
|
78
|
+
/**
|
|
79
|
+
* Create a loading indicator and append it to the container
|
|
80
|
+
*
|
|
81
|
+
* @param {VegaLoaderIndicatorOptions} options - VegaLoaderOptions = {} options of the method
|
|
82
|
+
* @returns {Nullable<string>} The uuid of the loader.
|
|
83
|
+
* @vegaVersion 1.16.0
|
|
84
|
+
*/
|
|
85
|
+
load(options = {}) {
|
|
86
|
+
let containerSelector = options.containerSelector || 'body';
|
|
87
|
+
let containerElement = document.querySelector(containerSelector);
|
|
88
|
+
if (containerElement &&
|
|
89
|
+
VegaLoaderController.SPECIAL_ELEMENT_TO_WRAP_FULL_BODY.includes(containerElement.tagName)) {
|
|
90
|
+
containerSelector = 'body';
|
|
91
|
+
containerElement = document.querySelector('body');
|
|
92
|
+
}
|
|
93
|
+
if (!containerElement) {
|
|
94
|
+
LogUtility.error('Container is not found by selector: ', containerSelector);
|
|
95
|
+
return null;
|
|
96
|
+
}
|
|
97
|
+
const loadingIndicator = this.createLoadingIndicator(options.indicatorOptions);
|
|
98
|
+
const loader = this.createLoader(containerSelector);
|
|
99
|
+
loader.append(loadingIndicator);
|
|
100
|
+
return this.appendLoader(loader, containerElement);
|
|
101
|
+
}
|
|
102
|
+
/**
|
|
103
|
+
* Close the loader by id
|
|
104
|
+
*
|
|
105
|
+
* @param {string} id - The id of the loader.
|
|
106
|
+
* @vegaVersion 1.16.0
|
|
107
|
+
*/
|
|
108
|
+
close(id) {
|
|
109
|
+
const loader = this.findLoader(id);
|
|
110
|
+
if (loader) {
|
|
111
|
+
if (loader.dataset.container) {
|
|
112
|
+
const container = document.querySelector(loader.dataset.container);
|
|
113
|
+
if (container) {
|
|
114
|
+
if (container.dataset['vegaLoaderOriginPosition']) {
|
|
115
|
+
container.style.position = container.dataset['vegaLoaderOriginPosition'];
|
|
116
|
+
}
|
|
117
|
+
}
|
|
118
|
+
}
|
|
119
|
+
loader.remove();
|
|
120
|
+
}
|
|
121
|
+
}
|
|
122
|
+
/**
|
|
123
|
+
* Find loader by id, if the id include '>>>' it will find inside shadowRoot
|
|
124
|
+
*
|
|
125
|
+
* @param {string} id - The id of the loader.
|
|
126
|
+
* @returns {Nullable<HTMLElement>} The loader found by id.
|
|
127
|
+
*/
|
|
128
|
+
findLoader(id) {
|
|
129
|
+
var _a, _b;
|
|
130
|
+
let loader;
|
|
131
|
+
if (id.includes('>>>')) {
|
|
132
|
+
const [containerSelector, loaderSelector] = id.split('>>>');
|
|
133
|
+
loader = (_b = (_a = document.querySelector(containerSelector)) === null || _a === void 0 ? void 0 : _a.shadowRoot) === null || _b === void 0 ? void 0 : _b.getElementById(loaderSelector);
|
|
134
|
+
}
|
|
135
|
+
else {
|
|
136
|
+
loader = document.getElementById(id);
|
|
137
|
+
}
|
|
138
|
+
return loader;
|
|
139
|
+
}
|
|
140
|
+
/**
|
|
141
|
+
* Create a loader for loading indicator
|
|
142
|
+
*
|
|
143
|
+
* @param {string} containerSelector The container which you want to append
|
|
144
|
+
* @returns {HTMLElement} a wrapper for loader
|
|
145
|
+
*/
|
|
146
|
+
createLoader(containerSelector) {
|
|
147
|
+
const loader = document.createElement('vega-loader-wrapper');
|
|
148
|
+
loader.className = arrayToClassString([
|
|
149
|
+
containerSelector === 'body' ? 'fixed-wrapper' : 'absolute-wrapper',
|
|
150
|
+
]);
|
|
151
|
+
loader.dataset['container'] = containerSelector;
|
|
152
|
+
loader.id = `vega-loader-${generateUUID()}`;
|
|
153
|
+
return loader;
|
|
154
|
+
}
|
|
155
|
+
/**
|
|
156
|
+
* Create a loading indicator
|
|
157
|
+
*
|
|
158
|
+
* @param {VegaLoaderIndicatorOptions} indicatorOptions the props of vega loading indicator
|
|
159
|
+
* @returns {HTMLVegaLoadingIndicatorElement} vega-loading-indicator component template
|
|
160
|
+
*/
|
|
161
|
+
createLoadingIndicator(indicatorOptions = {}) {
|
|
162
|
+
const loadingIndicator = document.createElement('vega-loading-indicator');
|
|
163
|
+
Object.assign(loadingIndicator, indicatorOptions);
|
|
164
|
+
return loadingIndicator;
|
|
165
|
+
}
|
|
166
|
+
/**
|
|
167
|
+
* Append the loader to the container
|
|
168
|
+
*
|
|
169
|
+
* @param {HTMLElement} loader A loader with loading indicator
|
|
170
|
+
* @param {string} containerElement The container which you want to append the loader to
|
|
171
|
+
* @returns {string} The uuid of the loader.
|
|
172
|
+
*/
|
|
173
|
+
appendLoader(loader, containerElement) {
|
|
174
|
+
containerElement.dataset['vegaLoaderOriginPosition'] = containerElement.style.position;
|
|
175
|
+
containerElement.style.position = 'relative';
|
|
176
|
+
if (containerElement.shadowRoot) {
|
|
177
|
+
containerElement.shadowRoot.append(loader);
|
|
178
|
+
return `${loader.dataset['container']}>>>${loader.id}`;
|
|
179
|
+
}
|
|
180
|
+
else {
|
|
181
|
+
containerElement.append(loader);
|
|
182
|
+
return loader.id;
|
|
183
|
+
}
|
|
184
|
+
}
|
|
185
|
+
}
|
|
186
|
+
VegaLoaderController.SPECIAL_ELEMENT_TO_WRAP_FULL_BODY = ['VEGA-MODAL'];
|
|
187
|
+
__decorate$6([
|
|
188
|
+
InjectVegaTelemetrySlimmer()
|
|
189
|
+
], VegaLoaderController.prototype, "vegaPublicAPIRuntimeMetricsSlimmer", void 0);
|
|
190
|
+
const VegaLoader = new VegaLoaderController();
|
|
191
|
+
|
|
192
|
+
const BASE_BASIC_Z_INDEX = 10000;
|
|
193
|
+
const TOP_BASIC_Z_INDEX = 11000;
|
|
194
|
+
/**
|
|
195
|
+
* Base level is for custom element such as modal, tooltip, dropdown, sidenav and header.
|
|
196
|
+
* the z-index of current showing element is highly than already show.
|
|
197
|
+
* Top level is for element that always display to top, such as notification.
|
|
198
|
+
*/
|
|
199
|
+
class InternalVegaZIndexManager {
|
|
200
|
+
constructor() {
|
|
201
|
+
this.baseBasicZIndex = BASE_BASIC_Z_INDEX;
|
|
202
|
+
this.topBasicZIndex = TOP_BASIC_Z_INDEX;
|
|
203
|
+
this.levelEntry = {
|
|
204
|
+
base: {
|
|
205
|
+
zIndex: this.baseBasicZIndex,
|
|
206
|
+
elements: [],
|
|
207
|
+
},
|
|
208
|
+
top: {
|
|
209
|
+
zIndex: this.topBasicZIndex,
|
|
210
|
+
elements: [],
|
|
211
|
+
},
|
|
212
|
+
};
|
|
213
|
+
}
|
|
214
|
+
/**
|
|
215
|
+
* "If the element is not already the current element, then increment the z-index and set the element
|
|
216
|
+
* to the current element."
|
|
217
|
+
*
|
|
218
|
+
* The function is a little more complicated than that, but not much. The function takes an element and
|
|
219
|
+
* a level. The level is optional and defaults to 'base'. The level is used to keep track of the
|
|
220
|
+
* z-index for each level. The function uses a private variable, levelStatus, to keep track of the
|
|
221
|
+
* current element and z-index for each level
|
|
222
|
+
*
|
|
223
|
+
* @param {HTMLElement} element - The element to set the z-index of.
|
|
224
|
+
* @param {ZIndexLevelType} [level=base] - The level of the element.
|
|
225
|
+
* @returns {void}
|
|
226
|
+
*/
|
|
227
|
+
setZIndex(element, level = 'base') {
|
|
228
|
+
if (element === null)
|
|
229
|
+
return;
|
|
230
|
+
this.removeZIndex(element, level);
|
|
231
|
+
const zIndexEntry = this.levelEntry[level];
|
|
232
|
+
if (element && zIndexEntry) {
|
|
233
|
+
if (level === 'base' && this.isBaseLevelOver()) {
|
|
234
|
+
LogUtility.warn(`The max 'z-index' of base level is '11000', but the current 'z-index' is over, Please optimize the use of 'z-index', otherwise there will be some performance overhead.`);
|
|
235
|
+
this.increaseTopEntry();
|
|
236
|
+
}
|
|
237
|
+
zIndexEntry.elements.push(element);
|
|
238
|
+
zIndexEntry.zIndex += 1;
|
|
239
|
+
element.style.zIndex = zIndexEntry.zIndex.toString();
|
|
240
|
+
}
|
|
241
|
+
}
|
|
242
|
+
/**
|
|
243
|
+
* It removes the element from the level's array of elements, and then decrements the z-index of all
|
|
244
|
+
* elements after the removed element
|
|
245
|
+
*
|
|
246
|
+
* @param {HTMLElement} element - HTMLElement - The element to move
|
|
247
|
+
* @param {ZIndexLevelType} [level=base] - Level = 'base'
|
|
248
|
+
* @returns {void}
|
|
249
|
+
*/
|
|
250
|
+
removeZIndex(element, level = 'base') {
|
|
251
|
+
if (element === null)
|
|
252
|
+
return;
|
|
253
|
+
const zIndexEntry = this.levelEntry[level];
|
|
254
|
+
if (element && zIndexEntry) {
|
|
255
|
+
let startAt = -1;
|
|
256
|
+
zIndexEntry.elements.forEach((e, index) => {
|
|
257
|
+
if (e === element)
|
|
258
|
+
startAt = index;
|
|
259
|
+
if (startAt >= 0 && index > startAt) {
|
|
260
|
+
e.style.zIndex = `${convertToNumber(e.style.zIndex) - 1}`;
|
|
261
|
+
}
|
|
262
|
+
});
|
|
263
|
+
if (startAt >= 0) {
|
|
264
|
+
element.style.removeProperty('z-index');
|
|
265
|
+
zIndexEntry.elements.splice(startAt, 1);
|
|
266
|
+
zIndexEntry.zIndex -= 1;
|
|
267
|
+
}
|
|
268
|
+
}
|
|
269
|
+
}
|
|
270
|
+
/**
|
|
271
|
+
* The function "overrideZIndexBasicValues" updates the base and top basic z-index values based on the
|
|
272
|
+
* input provided.
|
|
273
|
+
*
|
|
274
|
+
* @param {ZIndexBasicValues} input - The input parameter is of type ZIndexBasicValues, which is an
|
|
275
|
+
* object with two properties: base and top. Both properties are optional and can be either a number or
|
|
276
|
+
* undefined.
|
|
277
|
+
*/
|
|
278
|
+
overrideZIndexBasicValues(input) {
|
|
279
|
+
const basicValues = this.formatZIndexBasicValues(input);
|
|
280
|
+
if (this.validBasicValues(basicValues)) {
|
|
281
|
+
this.updateBasicValues(basicValues);
|
|
282
|
+
}
|
|
283
|
+
}
|
|
284
|
+
/**
|
|
285
|
+
* The function `formatZIndexBasicValues` takes an input object and returns a new object with additional
|
|
286
|
+
* properties `base` and `top` added to it.
|
|
287
|
+
*
|
|
288
|
+
* @param {ZIndexBasicValues} input - The input parameter is of type ZIndexBasicValues. It is an object
|
|
289
|
+
* that contains properties for base and top.
|
|
290
|
+
* @returns {ZIndexBasicValues} - an object that combines the properties of the input object `input` with the properties
|
|
291
|
+
* `base` and `top`. The values of `base` and `top` are taken from the `this.baseBasicZIndex` and
|
|
292
|
+
* `this.topBasicZIndex` variables respectively.
|
|
293
|
+
*/
|
|
294
|
+
formatZIndexBasicValues(input) {
|
|
295
|
+
return Object.assign({
|
|
296
|
+
base: this.baseBasicZIndex,
|
|
297
|
+
top: this.topBasicZIndex,
|
|
298
|
+
}, input);
|
|
299
|
+
}
|
|
300
|
+
/**
|
|
301
|
+
* The function checks if the input values for base and top levels of a z-index are valid.
|
|
302
|
+
*
|
|
303
|
+
* @param {ZIndexBasicValues} input - The input parameter is an object of type ZIndexBasicValues. It
|
|
304
|
+
* has two properties: base and top. Both properties should be of type number.
|
|
305
|
+
* @returns {boolean} a boolean value.
|
|
306
|
+
*/
|
|
307
|
+
validBasicValues(input) {
|
|
308
|
+
if (typeof input.base !== 'number' || typeof input.top !== 'number') {
|
|
309
|
+
LogUtility.error('Change z-index basic value failed, both base level and top level should be of type number!');
|
|
310
|
+
return false;
|
|
311
|
+
}
|
|
312
|
+
else if (input.base >= input.top) {
|
|
313
|
+
LogUtility.error('Change z-index basic value failed, the base level should be smaller than the top level!');
|
|
314
|
+
return false;
|
|
315
|
+
}
|
|
316
|
+
return true;
|
|
317
|
+
}
|
|
318
|
+
/**
|
|
319
|
+
* The function updates the z-index values of elements based on the input values.
|
|
320
|
+
*
|
|
321
|
+
* @param {ZIndexBasicValues} input - The input parameter is an object of type ZIndexBasicValues. It
|
|
322
|
+
* has two properties: base and top, both of which are optional and can be of type number.
|
|
323
|
+
*/
|
|
324
|
+
updateBasicValues(input) {
|
|
325
|
+
// update basic z-index value
|
|
326
|
+
this.baseBasicZIndex = input.base;
|
|
327
|
+
this.topBasicZIndex = input.top;
|
|
328
|
+
// update base level entry
|
|
329
|
+
const baseLevel = this.levelEntry.base;
|
|
330
|
+
baseLevel.elements.forEach((element, index) => {
|
|
331
|
+
element.style.zIndex = `${this.baseBasicZIndex + index + 1}`;
|
|
332
|
+
});
|
|
333
|
+
baseLevel.zIndex = this.baseBasicZIndex + baseLevel.elements.length;
|
|
334
|
+
// update top level entry
|
|
335
|
+
const topLevel = this.levelEntry.top;
|
|
336
|
+
topLevel.elements.forEach((element, index) => {
|
|
337
|
+
element.style.zIndex = `${this.topBasicZIndex + index + 1}`;
|
|
338
|
+
});
|
|
339
|
+
topLevel.zIndex = this.topBasicZIndex + topLevel.elements.length;
|
|
340
|
+
}
|
|
341
|
+
/**
|
|
342
|
+
* It increases the z-index of all the elements in the top entry by 1
|
|
343
|
+
*
|
|
344
|
+
* @returns {void}
|
|
345
|
+
*/
|
|
346
|
+
increaseTopEntry() {
|
|
347
|
+
const topEntry = this.levelEntry['top'];
|
|
348
|
+
topEntry.elements.forEach((element) => {
|
|
349
|
+
element.style.zIndex = `${convertToNumber(element.style.zIndex) + 1}`;
|
|
350
|
+
});
|
|
351
|
+
topEntry.zIndex += 1;
|
|
352
|
+
}
|
|
353
|
+
/**
|
|
354
|
+
* If the z-index of the level is over 1000 greater than the basic z-index of the level, then return
|
|
355
|
+
* true.
|
|
356
|
+
*
|
|
357
|
+
* @returns {boolean} - The zIndexEntry.zIndex - this.getBasicZIndexByLevel(level) >= 1000 is being returned.
|
|
358
|
+
*/
|
|
359
|
+
isBaseLevelOver() {
|
|
360
|
+
const baseEntry = this.levelEntry['base'];
|
|
361
|
+
return baseEntry.zIndex >= this.topBasicZIndex;
|
|
362
|
+
}
|
|
363
|
+
}
|
|
364
|
+
const InternalVegaZIndexManager$1 = new InternalVegaZIndexManager();
|
|
365
|
+
|
|
366
|
+
const VegaNotifyRuntimeMetricsPayloadDefinition = [
|
|
367
|
+
{
|
|
368
|
+
payloadKey: 'IS_OPEN_METHOD_CALLED',
|
|
369
|
+
payloadDescription: 'Indicate if the method open of public API VegaNotifyController is called',
|
|
370
|
+
/**
|
|
371
|
+
* Indicate whether the method is collected when the method been called .
|
|
372
|
+
*
|
|
373
|
+
* @param {string} scope - The class name of public api
|
|
374
|
+
* @param {string} methodName - The method name called by the public api
|
|
375
|
+
* @returns {boolean} A boolean value
|
|
376
|
+
*/
|
|
377
|
+
canAccept: (scope, methodName) => scope === 'VegaNotifyController' && methodName === 'open',
|
|
378
|
+
/**
|
|
379
|
+
* The function checks if the method name is open.
|
|
380
|
+
*
|
|
381
|
+
* @returns {boolean} A boolean value
|
|
382
|
+
*/
|
|
383
|
+
payloadValue: () => {
|
|
384
|
+
return true;
|
|
385
|
+
},
|
|
386
|
+
},
|
|
387
|
+
{
|
|
388
|
+
payloadKey: 'IS_CLOSE_METHOD_CALLED',
|
|
389
|
+
payloadDescription: 'Indicate if the method close of public API VegaNotifyController is called',
|
|
390
|
+
/**
|
|
391
|
+
* Indicate whether the method is collected when the method been called .
|
|
392
|
+
*
|
|
393
|
+
* @param {string} scope - The class name of public api
|
|
394
|
+
* @param {string} methodName - The method name called by the public api
|
|
395
|
+
* @returns {boolean} A boolean value
|
|
396
|
+
*/
|
|
397
|
+
canAccept: (scope, methodName) => scope === 'VegaNotifyController' && methodName === 'close',
|
|
398
|
+
/**
|
|
399
|
+
* The function checks if the method name is close.
|
|
400
|
+
*
|
|
401
|
+
* @returns {boolean} A boolean value
|
|
402
|
+
*/
|
|
403
|
+
payloadValue: () => {
|
|
404
|
+
return true;
|
|
405
|
+
},
|
|
406
|
+
},
|
|
407
|
+
{
|
|
408
|
+
payloadKey: 'IS_CLOSEALL_METHOD_CALLED',
|
|
409
|
+
payloadDescription: 'Indicate if the method closeAll of public API VegaNotifyController is called',
|
|
410
|
+
/**
|
|
411
|
+
* Indicate whether the method is collected when the method been called .
|
|
412
|
+
*
|
|
413
|
+
* @param {string} scope - The class name of public api
|
|
414
|
+
* @param {string} methodName - The method name called by the public api
|
|
415
|
+
* @returns {boolean} A boolean value
|
|
416
|
+
*/
|
|
417
|
+
canAccept: (scope, methodName) => scope === 'VegaNotifyController' && methodName === 'closeAll',
|
|
418
|
+
/**
|
|
419
|
+
* The function checks if the method name is closeAll.
|
|
420
|
+
*
|
|
421
|
+
* @returns {boolean} A boolean value
|
|
422
|
+
*/
|
|
423
|
+
payloadValue: () => {
|
|
424
|
+
return true;
|
|
425
|
+
},
|
|
426
|
+
},
|
|
427
|
+
];
|
|
428
|
+
|
|
429
|
+
var __decorate$5 = (undefined && undefined.__decorate) || function (decorators, target, key, desc) {
|
|
430
|
+
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
431
|
+
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
432
|
+
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
433
|
+
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
434
|
+
};
|
|
435
|
+
/**
|
|
436
|
+
* The page notification controller
|
|
437
|
+
*/
|
|
438
|
+
class VegaNotifyController {
|
|
439
|
+
constructor() {
|
|
440
|
+
this.resizeObserverSlimmer = createDynamicSlimmer(VegaNotifyController, PageResizeObserverSlimmer, [], [{ mapFrom: 'connectResizeObserver', mapTo: 'connectResizeObserver' }], [
|
|
441
|
+
{
|
|
442
|
+
// eslint-disable-next-line jsdoc/require-jsdoc
|
|
443
|
+
callback: (entries) => {
|
|
444
|
+
var _a;
|
|
445
|
+
const currentVisible = entries[0].contentRect.height > 0;
|
|
446
|
+
if (!currentVisible && ((_a = this.container) === null || _a === void 0 ? void 0 : _a.classList.contains('hydrated'))) {
|
|
447
|
+
InternalVegaZIndexManager$1.removeZIndex(this.container, 'top');
|
|
448
|
+
this.container.remove();
|
|
449
|
+
this.container = null;
|
|
450
|
+
}
|
|
451
|
+
},
|
|
452
|
+
// eslint-disable-next-line jsdoc/require-jsdoc
|
|
453
|
+
target: () => this.container,
|
|
454
|
+
},
|
|
455
|
+
]);
|
|
456
|
+
this.vegaPublicAPIRuntimeMetricsSlimmer = createPublicAPIRuntimeMetricsSlimmer(VegaNotifyController, ['open', 'close', 'closeAll'], VegaNotifyRuntimeMetricsPayloadDefinition);
|
|
457
|
+
}
|
|
458
|
+
/**
|
|
459
|
+
* It creates a new notification element, adds it to the container, and returns the notification's ID
|
|
460
|
+
*
|
|
461
|
+
* @param {VegaNotifyOption} options - VegaNotifyProps
|
|
462
|
+
* @returns {Promise<string>} The ID of the notification.
|
|
463
|
+
* @vegaVersion 1.17.0
|
|
464
|
+
*/
|
|
465
|
+
async open(options) {
|
|
466
|
+
const pageNotification = this.createPageNotification(options);
|
|
467
|
+
this.getContainer().append(pageNotification);
|
|
468
|
+
return pageNotification.id;
|
|
469
|
+
}
|
|
470
|
+
/**
|
|
471
|
+
* It closes all notifications
|
|
472
|
+
*
|
|
473
|
+
* @vegaVersion 1.17.0
|
|
474
|
+
*/
|
|
475
|
+
async closeAll() {
|
|
476
|
+
this.container &&
|
|
477
|
+
Array.from(this.container.children).forEach((item) => {
|
|
478
|
+
void item.close();
|
|
479
|
+
});
|
|
480
|
+
}
|
|
481
|
+
/**
|
|
482
|
+
* It closes the notification with the given id
|
|
483
|
+
*
|
|
484
|
+
* @param {string} id - The id of the notification to close.
|
|
485
|
+
* @vegaVersion 1.17.0
|
|
486
|
+
*/
|
|
487
|
+
async close(id) {
|
|
488
|
+
// eslint-disable-next-line no-restricted-globals
|
|
489
|
+
await document.getElementById(id).close();
|
|
490
|
+
}
|
|
491
|
+
/**
|
|
492
|
+
* The function "connectResizeObserver" is used to connect a resize observer.
|
|
493
|
+
*
|
|
494
|
+
* @vegaVersion 1.17.0
|
|
495
|
+
*/
|
|
496
|
+
connectResizeObserver() {
|
|
497
|
+
}
|
|
498
|
+
/**
|
|
499
|
+
* It creates a new page notification element, sets its properties, and returns it
|
|
500
|
+
*
|
|
501
|
+
* @param {VegaNotifyOption} props - VegaNotifyProps - the properties of the notification
|
|
502
|
+
* @returns {HTMLVegaPageNotificationElement} A function that takes in a props object and returns a pageNotification element.
|
|
503
|
+
*/
|
|
504
|
+
createPageNotification(props) {
|
|
505
|
+
const pageNotification =
|
|
506
|
+
// eslint-disable-next-line no-restricted-globals
|
|
507
|
+
document.createElement('vega-page-notification');
|
|
508
|
+
Object.keys(props).forEach((propName) => {
|
|
509
|
+
props[propName] !== undefined && (pageNotification[propName] = props[propName]);
|
|
510
|
+
});
|
|
511
|
+
pageNotification.style.marginBottom = getDeviceType() === DeviceType.MOBILE ? '12px' : '16px';
|
|
512
|
+
pageNotification.id = `vega-page-notification-${generateUUID()}`;
|
|
513
|
+
return pageNotification;
|
|
514
|
+
}
|
|
515
|
+
/**
|
|
516
|
+
* It creates a div element, sets its z-index to be on top of everything else, adds a class to it, and
|
|
517
|
+
* then adds it to the body of the page
|
|
518
|
+
*
|
|
519
|
+
* @returns {HTMLVegaPageNotificationListElement} The container is being returned.
|
|
520
|
+
*/
|
|
521
|
+
getContainer() {
|
|
522
|
+
if (this.container) {
|
|
523
|
+
return this.container;
|
|
524
|
+
}
|
|
525
|
+
// eslint-disable-next-line no-restricted-globals
|
|
526
|
+
this.container = document.createElement('vega-page-notification-list');
|
|
527
|
+
InternalVegaZIndexManager$1.setZIndex(this.container, 'top');
|
|
528
|
+
if (getDeviceType() === DeviceType.MOBILE) {
|
|
529
|
+
this.container.classList.add('vega-page-notification-list-bottom');
|
|
530
|
+
}
|
|
531
|
+
else {
|
|
532
|
+
this.container.classList.add('vega-page-notification-list-topRight');
|
|
533
|
+
}
|
|
534
|
+
// eslint-disable-next-line no-restricted-globals
|
|
535
|
+
document.body.append(this.container);
|
|
536
|
+
this.connectResizeObserver();
|
|
537
|
+
return this.container;
|
|
538
|
+
}
|
|
539
|
+
}
|
|
540
|
+
__decorate$5([
|
|
541
|
+
InjectVegaSlimmer()
|
|
542
|
+
], VegaNotifyController.prototype, "resizeObserverSlimmer", void 0);
|
|
543
|
+
__decorate$5([
|
|
544
|
+
InjectVegaTelemetrySlimmer()
|
|
545
|
+
], VegaNotifyController.prototype, "vegaPublicAPIRuntimeMetricsSlimmer", void 0);
|
|
546
|
+
const VegaNotify = new VegaNotifyController();
|
|
547
|
+
|
|
548
|
+
const ThemeManagerRuntimeMetricsPayloadDefinition = [
|
|
549
|
+
{
|
|
550
|
+
payloadKey: 'IS_OVERRIDECOLORS_METHOD_CALLED',
|
|
551
|
+
payloadDescription: 'Indicate if the method overrideColors of public API ThemeManager is called',
|
|
552
|
+
/**
|
|
553
|
+
* Indicate whether the method is collected when the method been called .
|
|
554
|
+
*
|
|
555
|
+
* @param {string} scope - The class name of public api
|
|
556
|
+
* @param {string} methodName - The method name called by the public api
|
|
557
|
+
* @returns {boolean} A boolean value
|
|
558
|
+
*/
|
|
559
|
+
canAccept: (scope, methodName) => scope === 'ThemeManager' && methodName === 'overrideColors',
|
|
560
|
+
/**
|
|
561
|
+
* The function checks if the method is be called.
|
|
562
|
+
*
|
|
563
|
+
* @returns {boolean} A boolean value
|
|
564
|
+
*/
|
|
565
|
+
payloadValue: () => {
|
|
566
|
+
return true;
|
|
567
|
+
},
|
|
568
|
+
},
|
|
569
|
+
{
|
|
570
|
+
payloadKey: 'IS_RESET_METHOD_CALLED',
|
|
571
|
+
payloadDescription: 'Indicate if the method reset of public API ThemeManager is called',
|
|
572
|
+
/**
|
|
573
|
+
* Indicate whether the method is collected when the method been called .
|
|
574
|
+
*
|
|
575
|
+
* @param {string} scope - The class name of public api
|
|
576
|
+
* @param {string} methodName - The method name called by the public api
|
|
577
|
+
* @returns {boolean} A boolean value
|
|
578
|
+
*/
|
|
579
|
+
canAccept: (scope, methodName) => scope === 'ThemeManager' && methodName === 'reset',
|
|
580
|
+
/**
|
|
581
|
+
* The function checks if the method is be called.
|
|
582
|
+
*
|
|
583
|
+
* @returns {boolean} A boolean value
|
|
584
|
+
*/
|
|
585
|
+
payloadValue: () => {
|
|
586
|
+
return true;
|
|
587
|
+
},
|
|
588
|
+
},
|
|
589
|
+
{
|
|
590
|
+
payloadKey: 'IS_TOGGLEDARKMODE_METHOD_CALLED',
|
|
591
|
+
payloadDescription: 'Indicate if the method toggleDarkMode of public API ThemeManager is called',
|
|
592
|
+
/**
|
|
593
|
+
* Indicate whether the method is collected when the method been called .
|
|
594
|
+
*
|
|
595
|
+
* @param {string} scope - The class name of public api
|
|
596
|
+
* @param {string} methodName - The method name called by the public api
|
|
597
|
+
* @returns {boolean} A boolean value
|
|
598
|
+
*/
|
|
599
|
+
canAccept: (scope, methodName) => scope === 'ThemeManager' && methodName === 'toggleDarkMode',
|
|
600
|
+
/**
|
|
601
|
+
* The function checks if the method is be called.
|
|
602
|
+
*
|
|
603
|
+
* @returns {boolean} A boolean value
|
|
604
|
+
*/
|
|
605
|
+
payloadValue: () => {
|
|
606
|
+
return true;
|
|
607
|
+
},
|
|
608
|
+
},
|
|
609
|
+
{
|
|
610
|
+
payloadKey: 'IS_ISDARKMODE_METHOD_CALLED',
|
|
611
|
+
payloadDescription: 'Indicate if the method isDarkMode of public API ThemeManager is called',
|
|
612
|
+
/**
|
|
613
|
+
* Indicate whether the method is collected when the method been called .
|
|
614
|
+
*
|
|
615
|
+
* @param {string} scope - The class name of public api
|
|
616
|
+
* @param {string} methodName - The method name called by the public api
|
|
617
|
+
* @returns {boolean} A boolean value
|
|
618
|
+
*/
|
|
619
|
+
canAccept: (scope, methodName) => scope === 'ThemeManager' && methodName === 'isDarkMode',
|
|
620
|
+
/**
|
|
621
|
+
* The function checks if the method is be called.
|
|
622
|
+
*
|
|
623
|
+
* @returns {boolean} A boolean value
|
|
624
|
+
*/
|
|
625
|
+
payloadValue: () => {
|
|
626
|
+
return true;
|
|
627
|
+
},
|
|
628
|
+
},
|
|
629
|
+
{
|
|
630
|
+
payloadKey: 'IS_APPLY_BRANDING_METHOD_CALLED',
|
|
631
|
+
payloadDescription: 'Indicate if the method applyBranding of public API ThemeManager is called',
|
|
632
|
+
/**
|
|
633
|
+
* Indicate whether the method is collected when the method been called .
|
|
634
|
+
*
|
|
635
|
+
* @param {string} scope - The class name of public api
|
|
636
|
+
* @param {string} methodName - The method name called by the public api
|
|
637
|
+
* @returns {boolean} A boolean value
|
|
638
|
+
*/
|
|
639
|
+
canAccept: (scope, methodName) => scope === 'ThemeManager' && methodName === 'applyBranding',
|
|
640
|
+
/**
|
|
641
|
+
* The function checks if the method is be called.
|
|
642
|
+
*
|
|
643
|
+
* @returns {boolean} A boolean value
|
|
644
|
+
*/
|
|
645
|
+
payloadValue: () => {
|
|
646
|
+
return true;
|
|
647
|
+
},
|
|
648
|
+
},
|
|
649
|
+
];
|
|
650
|
+
|
|
651
|
+
var __decorate$4 = (undefined && undefined.__decorate) || function (decorators, target, key, desc) {
|
|
652
|
+
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
653
|
+
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
654
|
+
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
655
|
+
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
656
|
+
};
|
|
657
|
+
/**
|
|
658
|
+
* Vega components theme manager
|
|
659
|
+
*/
|
|
660
|
+
class ThemeManager {
|
|
661
|
+
constructor() {
|
|
662
|
+
this.vegaPublicAPIRuntimeMetricsSlimmer = createPublicAPIRuntimeMetricsSlimmer(ThemeManager, ['overrideColors', 'reset', 'toggleDarkMode', 'isDarkMode', 'applyBranding'], ThemeManagerRuntimeMetricsPayloadDefinition);
|
|
663
|
+
}
|
|
664
|
+
/**
|
|
665
|
+
* It takes the colors you passed in, parses them into the correct format, and then applies them to the theme
|
|
666
|
+
*
|
|
667
|
+
* @param {VegaThemeOverrideColors} overrideColors - OverrideColors - This is the object that you pass to the function.
|
|
668
|
+
* @vegaVersion 1.20.0
|
|
669
|
+
*/
|
|
670
|
+
async overrideColors(overrideColors) {
|
|
671
|
+
void VegaInternalThemeManager.overrideColors(overrideColors);
|
|
672
|
+
}
|
|
673
|
+
/**
|
|
674
|
+
* It removes all the custom override theme styles from the DOM
|
|
675
|
+
*
|
|
676
|
+
* @vegaVersion 1.20.0
|
|
677
|
+
*/
|
|
678
|
+
async reset() {
|
|
679
|
+
void VegaInternalThemeManager.reset();
|
|
680
|
+
}
|
|
681
|
+
/**
|
|
682
|
+
* This function toggles the dark mode of a webpage by adding or removing a 'dark' class to the HTML element.
|
|
683
|
+
*
|
|
684
|
+
* @param {boolean | undefined} darkMode - A boolean or undefined value that determines whether to enable or disable dark mode.
|
|
685
|
+
* If it is true, dark mode is enabled.
|
|
686
|
+
* If it is false, dark mode is disabled.
|
|
687
|
+
* @vegaVersion 1.32.0
|
|
688
|
+
*/
|
|
689
|
+
toggleDarkMode(darkMode) {
|
|
690
|
+
VegaInternalThemeManager.toggleDarkMode(darkMode);
|
|
691
|
+
}
|
|
692
|
+
/**
|
|
693
|
+
* The function checks if the HTML element has a class of "dark" and returns a boolean value accordingly.
|
|
694
|
+
*
|
|
695
|
+
* @returns {boolean} A boolean value indicating whether the HTML element has a class of "dark", which is
|
|
696
|
+
* typically used to indicate that the website is in dark mode.
|
|
697
|
+
* @vegaVersion 1.32.0
|
|
698
|
+
*/
|
|
699
|
+
isDarkMode() {
|
|
700
|
+
return VegaInternalThemeManager.isDarkMode();
|
|
701
|
+
}
|
|
702
|
+
/**
|
|
703
|
+
* This function switches the Vega theme to a brand theme based on the provided options.
|
|
704
|
+
*
|
|
705
|
+
* @param {BrandOptions} options - The options includes 'gp', 'genius' and 'heartland' options
|
|
706
|
+
* @vegaVersion 2.47.0
|
|
707
|
+
*/
|
|
708
|
+
applyBranding(options) {
|
|
709
|
+
VegaInternalThemeManager.applyBranding(options);
|
|
710
|
+
}
|
|
711
|
+
}
|
|
712
|
+
__decorate$4([
|
|
713
|
+
InjectVegaTelemetrySlimmer()
|
|
714
|
+
], ThemeManager.prototype, "vegaPublicAPIRuntimeMetricsSlimmer", void 0);
|
|
715
|
+
const VegaThemeManager = new ThemeManager();
|
|
716
|
+
|
|
717
|
+
const VegaDialogRuntimeMetricsPayloadDefinition = [
|
|
718
|
+
{
|
|
719
|
+
payloadKey: 'IS_OPEN_METHOD_CALLED',
|
|
720
|
+
payloadDescription: 'Indicate if the method open of public API VegaDialogController is called',
|
|
721
|
+
/**
|
|
722
|
+
* Indicate whether the method is collected when the method been called .
|
|
723
|
+
*
|
|
724
|
+
* @param {string} scope - The class name of public api
|
|
725
|
+
* @param {string} methodName - The method name called by the public api
|
|
726
|
+
* @returns {boolean} A boolean value
|
|
727
|
+
*/
|
|
728
|
+
canAccept: (scope, methodName) => scope === 'VegaDialogController' && methodName === 'open',
|
|
729
|
+
/**
|
|
730
|
+
* The function checks if the method name is open.
|
|
731
|
+
*
|
|
732
|
+
* @returns {boolean} A boolean value
|
|
733
|
+
*/
|
|
734
|
+
payloadValue: () => {
|
|
735
|
+
return true;
|
|
736
|
+
},
|
|
737
|
+
},
|
|
738
|
+
];
|
|
739
|
+
|
|
740
|
+
var __decorate$3 = (undefined && undefined.__decorate) || function (decorators, target, key, desc) {
|
|
741
|
+
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
742
|
+
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
743
|
+
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
744
|
+
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
745
|
+
};
|
|
746
|
+
var __rest$1 = (undefined && undefined.__rest) || function (s, e) {
|
|
747
|
+
var t = {};
|
|
748
|
+
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)
|
|
749
|
+
t[p] = s[p];
|
|
750
|
+
if (s != null && typeof Object.getOwnPropertySymbols === "function")
|
|
751
|
+
for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
|
|
752
|
+
if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))
|
|
753
|
+
t[p[i]] = s[p[i]];
|
|
754
|
+
}
|
|
755
|
+
return t;
|
|
756
|
+
};
|
|
757
|
+
/**
|
|
758
|
+
* The dialog controller
|
|
759
|
+
*/
|
|
760
|
+
class VegaDialogController {
|
|
761
|
+
constructor() {
|
|
762
|
+
this.vegaPublicAPIRuntimeMetricsSlimmer = createPublicAPIRuntimeMetricsSlimmer(VegaDialogController, ['open'], VegaDialogRuntimeMetricsPayloadDefinition);
|
|
763
|
+
}
|
|
764
|
+
/**
|
|
765
|
+
*
|
|
766
|
+
* It creates a new `vega-dialog` element, sets its properties, appends it to the DOM, and opens it
|
|
767
|
+
*
|
|
768
|
+
* @param {VegaDialogOption} options - VegaDialogOption
|
|
769
|
+
* @returns {HTMLVegaDialogElement} The dialog reference.
|
|
770
|
+
* @vegaVersion 1.24.0
|
|
771
|
+
*/
|
|
772
|
+
open(options) {
|
|
773
|
+
// eslint-disable-next-line no-restricted-globals
|
|
774
|
+
const dialog = document.createElement('vega-dialog');
|
|
775
|
+
const { isVerticallyCenter, isVerticallyCentered, showCloseButton, size, title, handleClose } = options, dialogProps = __rest$1(options, ["isVerticallyCenter", "isVerticallyCentered", "showCloseButton", "size", "title", "handleClose"]);
|
|
776
|
+
dialog.id = `vega-dialog-${generateUUID()}`;
|
|
777
|
+
dialog.dialogTitle = title;
|
|
778
|
+
dialog.modalProps = { isVerticallyCenter, isVerticallyCentered, showCloseButton, size, handleClose };
|
|
779
|
+
Object.keys(dialogProps).forEach((propName) => {
|
|
780
|
+
if (dialogProps[propName] !== undefined) {
|
|
781
|
+
dialog[propName] = dialogProps[propName];
|
|
782
|
+
}
|
|
783
|
+
});
|
|
784
|
+
// eslint-disable-next-line no-restricted-globals
|
|
785
|
+
document.body.append(dialog);
|
|
786
|
+
return dialog;
|
|
787
|
+
}
|
|
788
|
+
}
|
|
789
|
+
__decorate$3([
|
|
790
|
+
InjectVegaTelemetrySlimmer()
|
|
791
|
+
], VegaDialogController.prototype, "vegaPublicAPIRuntimeMetricsSlimmer", void 0);
|
|
792
|
+
const VegaDialog = new VegaDialogController();
|
|
793
|
+
|
|
794
|
+
/* istanbul ignore next */
|
|
795
|
+
const VegaEventManagerRuntimeMetricsPayloadDefinition = [
|
|
796
|
+
{
|
|
797
|
+
payloadKey: 'IS_SETSEMANTICS_METHOD_CALLED',
|
|
798
|
+
payloadDescription: 'Indicate if the method setSemantics of public API VegaEventManager is called',
|
|
799
|
+
/**
|
|
800
|
+
* Indicate whether the method is collected when the method been called .
|
|
801
|
+
*
|
|
802
|
+
* @param {string} scope - The class name of public api
|
|
803
|
+
* @param {string} methodName - The method name called by the public api
|
|
804
|
+
* @returns {boolean} A boolean value
|
|
805
|
+
*/
|
|
806
|
+
canAccept: (scope, methodName) => scope === 'VegaEventManager' && methodName === 'setSemantics',
|
|
807
|
+
/**
|
|
808
|
+
* The function checks if the method is been called.
|
|
809
|
+
*
|
|
810
|
+
* @returns {boolean} A boolean value
|
|
811
|
+
*/
|
|
812
|
+
payloadValue: () => {
|
|
813
|
+
return true;
|
|
814
|
+
},
|
|
815
|
+
},
|
|
816
|
+
{
|
|
817
|
+
payloadKey: 'IS_GETSEMANTICS_METHOD_CALLED',
|
|
818
|
+
payloadDescription: 'Indicate if the method getSemantics of public API VegaEventManager is called',
|
|
819
|
+
/**
|
|
820
|
+
* Indicate whether the method is collected when the method been called .
|
|
821
|
+
*
|
|
822
|
+
* @param {string} scope - The class name of public api
|
|
823
|
+
* @param {string} methodName - The method name called by the public api
|
|
824
|
+
* @returns {boolean} A boolean value
|
|
825
|
+
*/
|
|
826
|
+
canAccept: (scope, methodName) => scope === 'VegaEventManager' && methodName === 'getSemantics',
|
|
827
|
+
/**
|
|
828
|
+
* The function checks if the method is been called.
|
|
829
|
+
*
|
|
830
|
+
* @returns {boolean} A boolean value
|
|
831
|
+
*/
|
|
832
|
+
payloadValue: () => {
|
|
833
|
+
return true;
|
|
834
|
+
},
|
|
835
|
+
},
|
|
836
|
+
{
|
|
837
|
+
payloadKey: 'IS_GETENABLEDEVENTIDSBYCOMPONENT_METHOD_CALLED',
|
|
838
|
+
payloadDescription: 'Indicate if the method getEnabledEventIdsByComponent of public API VegaEventManager is called',
|
|
839
|
+
/**
|
|
840
|
+
* Indicate whether the method is collected when the method been called .
|
|
841
|
+
*
|
|
842
|
+
* @param {string} scope - The class name of public api
|
|
843
|
+
* @param {string} methodName - The method name called by the public api
|
|
844
|
+
* @returns {boolean} A boolean value
|
|
845
|
+
*/
|
|
846
|
+
canAccept: (scope, methodName) => scope === 'VegaEventManager' && methodName === 'getEnabledEventIdsByComponent',
|
|
847
|
+
/**
|
|
848
|
+
* The function checks if the method is been called.
|
|
849
|
+
*
|
|
850
|
+
* @returns {boolean} A boolean value
|
|
851
|
+
*/
|
|
852
|
+
payloadValue: () => {
|
|
853
|
+
return true;
|
|
854
|
+
},
|
|
855
|
+
},
|
|
856
|
+
{
|
|
857
|
+
payloadKey: 'globalEventIsNative',
|
|
858
|
+
payloadDescription: 'Indicate if the vega components will emit events without the vega prefix',
|
|
859
|
+
/**
|
|
860
|
+
* Indicate whether the method is collected when the method been called .
|
|
861
|
+
*
|
|
862
|
+
* @param {string} scope - The class name of public api
|
|
863
|
+
* @param {string} methodName - The method name called by the public api
|
|
864
|
+
* @returns {boolean} A boolean value
|
|
865
|
+
*/
|
|
866
|
+
canAccept: (scope, methodName) => scope === 'VegaEventManager' && methodName === 'setSemantics',
|
|
867
|
+
/**
|
|
868
|
+
* The function checks if the method is been called.
|
|
869
|
+
*
|
|
870
|
+
* @param {unknown[]} args - The args parameter is an object
|
|
871
|
+
* @returns {boolean} A boolean value
|
|
872
|
+
*/
|
|
873
|
+
payloadValue: (args) => {
|
|
874
|
+
const config = args;
|
|
875
|
+
return !!(config.global && config.global.namespace === 'native');
|
|
876
|
+
},
|
|
877
|
+
},
|
|
878
|
+
{
|
|
879
|
+
payloadKey: 'eventOfSpecificComponentsIsNative',
|
|
880
|
+
payloadDescription: 'Indicate if the vega components will emit events with the vega prefix, but special components will emit events without vega prefix',
|
|
881
|
+
/**
|
|
882
|
+
* Indicate whether the method is collected when the method been called .
|
|
883
|
+
*
|
|
884
|
+
* @param {string} scope - The class name of public api
|
|
885
|
+
* @param {string} methodName - The method name called by the public api
|
|
886
|
+
* @returns {boolean} A boolean value
|
|
887
|
+
*/
|
|
888
|
+
canAccept: (scope, methodName) => scope === 'VegaEventManager' && methodName === 'setSemantics',
|
|
889
|
+
/**
|
|
890
|
+
* The function checks if the method is been called.
|
|
891
|
+
*
|
|
892
|
+
* @param {unknown[]} args - The args parameter is an object
|
|
893
|
+
* @returns {boolean} A boolean value
|
|
894
|
+
*/
|
|
895
|
+
payloadValue: (args) => {
|
|
896
|
+
const config = args;
|
|
897
|
+
if (config.components) {
|
|
898
|
+
const specialComponents = Object.keys(config.components);
|
|
899
|
+
return !!(specialComponents.length > 0 &&
|
|
900
|
+
config.components[specialComponents[0]].namespace === 'native');
|
|
901
|
+
}
|
|
902
|
+
return false;
|
|
903
|
+
},
|
|
904
|
+
},
|
|
905
|
+
{
|
|
906
|
+
payloadKey: 'eventOfSpecificComponentsIsVega',
|
|
907
|
+
payloadDescription: 'Indicate if the vega components will emit events without the vega prefix, but special components will emit events with vega prefix',
|
|
908
|
+
/**
|
|
909
|
+
* Indicate whether the method is collected when the method been called .
|
|
910
|
+
*
|
|
911
|
+
* @param {string} scope - The class name of public api
|
|
912
|
+
* @param {string} methodName - The method name called by the public api
|
|
913
|
+
* @returns {boolean} A boolean value
|
|
914
|
+
*/
|
|
915
|
+
canAccept: (scope, methodName) => scope === 'VegaEventManager' && methodName === 'setSemantics',
|
|
916
|
+
/**
|
|
917
|
+
* The function checks if the method is been called.
|
|
918
|
+
*
|
|
919
|
+
* @param {unknown[]} args - The args parameter is an object
|
|
920
|
+
* @returns {boolean} A boolean value
|
|
921
|
+
*/
|
|
922
|
+
payloadValue: (args) => {
|
|
923
|
+
const config = args;
|
|
924
|
+
if (config.global && config.components) {
|
|
925
|
+
const specialComponents = Object.keys(config.components);
|
|
926
|
+
return !!(config.global.namespace === 'native' &&
|
|
927
|
+
specialComponents.length > 0 &&
|
|
928
|
+
config.components[specialComponents[0]].namespace === 'vega');
|
|
929
|
+
}
|
|
930
|
+
return false;
|
|
931
|
+
},
|
|
932
|
+
},
|
|
933
|
+
{
|
|
934
|
+
payloadKey: 'globalJqueryDelegatedEventIsTrue',
|
|
935
|
+
payloadDescription: 'Indicate if the use jQuery with event delegation',
|
|
936
|
+
/**
|
|
937
|
+
* Indicate whether the method is collected when the method been called .
|
|
938
|
+
*
|
|
939
|
+
* @param {string} scope - The class name of public api
|
|
940
|
+
* @param {string} methodName - The method name called by the public api
|
|
941
|
+
* @returns {boolean} A boolean value
|
|
942
|
+
*/
|
|
943
|
+
canAccept: (scope, methodName) => scope === 'VegaEventManager' && methodName === 'setSemantics',
|
|
944
|
+
/**
|
|
945
|
+
* The function checks if the method is been called.
|
|
946
|
+
*
|
|
947
|
+
* @param {unknown[]} args - The args parameter is an object
|
|
948
|
+
* @returns {boolean} A boolean value
|
|
949
|
+
*/
|
|
950
|
+
payloadValue: (args) => {
|
|
951
|
+
const config = args;
|
|
952
|
+
return !!(config.global && config.global.jqueryDelegatedEvent === true);
|
|
953
|
+
},
|
|
954
|
+
},
|
|
955
|
+
{
|
|
956
|
+
payloadKey: 'jqueryDelegatedEventIsCustomStrategy',
|
|
957
|
+
payloadDescription: 'Indicate if the use jQuery with event delegation',
|
|
958
|
+
/**
|
|
959
|
+
* Indicate whether the method is collected when the method been called .
|
|
960
|
+
*
|
|
961
|
+
* @param {string} scope - The class name of public api
|
|
962
|
+
* @param {string} methodName - The method name called by the public api
|
|
963
|
+
* @returns {boolean} A boolean value
|
|
964
|
+
*/
|
|
965
|
+
canAccept: (scope, methodName) => scope === 'VegaEventManager' && methodName === 'setSemantics',
|
|
966
|
+
/**
|
|
967
|
+
* The function checks if the method is been called.
|
|
968
|
+
*
|
|
969
|
+
* @param {unknown[]} args - The args parameter is an object
|
|
970
|
+
* @returns {boolean} A boolean value
|
|
971
|
+
*/
|
|
972
|
+
payloadValue: (args) => {
|
|
973
|
+
const config = args;
|
|
974
|
+
return !!(config.global &&
|
|
975
|
+
Array.isArray(config.global.jqueryDelegatedEvent) &&
|
|
976
|
+
config.global.jqueryDelegatedEvent.length > 0);
|
|
977
|
+
},
|
|
978
|
+
},
|
|
979
|
+
{
|
|
980
|
+
payloadKey: 'jqueryDelegatedEventOfSpecialComponentsIsTrue',
|
|
981
|
+
payloadDescription: 'Indicate if the use jQuery with event delegation',
|
|
982
|
+
/**
|
|
983
|
+
* Indicate whether the method is collected when the method been called .
|
|
984
|
+
*
|
|
985
|
+
* @param {string} scope - The class name of public api
|
|
986
|
+
* @param {string} methodName - The method name called by the public api
|
|
987
|
+
* @returns {boolean} A boolean value
|
|
988
|
+
*/
|
|
989
|
+
canAccept: (scope, methodName) => scope === 'VegaEventManager' && methodName === 'setSemantics',
|
|
990
|
+
/**
|
|
991
|
+
* The function checks if the method is been called.
|
|
992
|
+
*
|
|
993
|
+
* @param {unknown[]} args - The args parameter is an object
|
|
994
|
+
* @returns {boolean} A boolean value
|
|
995
|
+
*/
|
|
996
|
+
payloadValue: (args) => {
|
|
997
|
+
const config = args;
|
|
998
|
+
if (config.components) {
|
|
999
|
+
const specialComponents = Object.keys(config.components);
|
|
1000
|
+
return !!(specialComponents.length > 0 &&
|
|
1001
|
+
config.components[specialComponents[0]].jqueryDelegatedEvent === true);
|
|
1002
|
+
}
|
|
1003
|
+
return false;
|
|
1004
|
+
},
|
|
1005
|
+
},
|
|
1006
|
+
];
|
|
1007
|
+
|
|
1008
|
+
var __decorate$2 = (undefined && undefined.__decorate) || function (decorators, target, key, desc) {
|
|
1009
|
+
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
1010
|
+
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
1011
|
+
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
1012
|
+
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
1013
|
+
};
|
|
1014
|
+
/**
|
|
1015
|
+
* The VegaEventManager class provides methods for setting and retrieving event semantics configuration,
|
|
1016
|
+
* as well as getting the corresponding native event name for a given event.
|
|
1017
|
+
*/
|
|
1018
|
+
class VegaEventManager {
|
|
1019
|
+
constructor() {
|
|
1020
|
+
this.vegaPublicAPIRuntimeMetricsSlimmer = createPublicAPIRuntimeMetricsSlimmer(VegaEventManager, ['setSemantics', 'getSemantics', 'getEnabledEventIdsByComponent'], VegaEventManagerRuntimeMetricsPayloadDefinition);
|
|
1021
|
+
}
|
|
1022
|
+
/**
|
|
1023
|
+
* The function sets the semantics configuration for event management.
|
|
1024
|
+
*
|
|
1025
|
+
* @param {EventSemanticsConfig} config - The config parameter is an object that contains the
|
|
1026
|
+
* configuration settings for the event semantics. It may include properties such as the event type,
|
|
1027
|
+
* event source, event target, event data, and any other relevant information for setting up the
|
|
1028
|
+
* semantics of the event.
|
|
1029
|
+
* @vegaVersion 2.0.0
|
|
1030
|
+
*/
|
|
1031
|
+
setSemantics(config) {
|
|
1032
|
+
internalVegaEventManager.setSemantics(config);
|
|
1033
|
+
}
|
|
1034
|
+
/**
|
|
1035
|
+
* The function "getSemantics" returns the event semantics of an HTML element.
|
|
1036
|
+
*
|
|
1037
|
+
* @param {HTMLElement} host - The host parameter is an HTMLElement, which represents an HTML element
|
|
1038
|
+
* in the DOM (Document Object Model). It can be any valid HTML element such as a div, span, button,
|
|
1039
|
+
* etc.
|
|
1040
|
+
* @returns {EventSemantics} an object of type EventSemantics.
|
|
1041
|
+
* @vegaVersion 2.0.0
|
|
1042
|
+
*/
|
|
1043
|
+
getSemantics(host) {
|
|
1044
|
+
return internalVegaEventManager.getSemantics(host);
|
|
1045
|
+
}
|
|
1046
|
+
/**
|
|
1047
|
+
* The function "getEnabledEventIdsByComponent" returns the all eventIds in component.
|
|
1048
|
+
*
|
|
1049
|
+
* @param {VegaComponentName} componentName - The component name,
|
|
1050
|
+
* etc.
|
|
1051
|
+
* @returns {Nullable<VegaEventID[]>} All eventIds.
|
|
1052
|
+
* @vegaVersion 2.0.0
|
|
1053
|
+
*/
|
|
1054
|
+
getEnabledEventIdsByComponent(componentName) {
|
|
1055
|
+
return internalVegaEventManager.getEnabledEventIdsByComponent(componentName);
|
|
1056
|
+
}
|
|
1057
|
+
}
|
|
1058
|
+
__decorate$2([
|
|
1059
|
+
InjectVegaTelemetrySlimmer()
|
|
1060
|
+
], VegaEventManager.prototype, "vegaPublicAPIRuntimeMetricsSlimmer", void 0);
|
|
1061
|
+
const VegaEventManager$1 = new VegaEventManager();
|
|
1062
|
+
|
|
1063
|
+
const ZIndexManagerRuntimeMetricsPayloadDefinition = [
|
|
1064
|
+
{
|
|
1065
|
+
payloadKey: 'IS_OVERRIDEZINDEXBASICVALUES_METHOD_CALLED',
|
|
1066
|
+
payloadDescription: 'Indicate if the method overrideZIndexBasicValues of public API ZIndexManager is called',
|
|
1067
|
+
/**
|
|
1068
|
+
* Indicate whether the method is collected when the method been called .
|
|
1069
|
+
*
|
|
1070
|
+
* @param {string} scope - The class name of public api
|
|
1071
|
+
* @param {string} methodName - The method name called by the public api
|
|
1072
|
+
* @returns {boolean} A boolean value
|
|
1073
|
+
*/
|
|
1074
|
+
canAccept: (scope, methodName) => scope === 'VegaZIndexManager' && methodName === 'overrideZIndexBasicValues',
|
|
1075
|
+
/**
|
|
1076
|
+
* The function checks if the method name is load.
|
|
1077
|
+
*
|
|
1078
|
+
* @returns {boolean} A boolean value
|
|
1079
|
+
*/
|
|
1080
|
+
payloadValue: () => {
|
|
1081
|
+
return true;
|
|
1082
|
+
},
|
|
1083
|
+
},
|
|
1084
|
+
{
|
|
1085
|
+
payloadKey: 'zIndexBasicValuesGreatThanTenThousand',
|
|
1086
|
+
payloadDescription: 'Indicate if the basic z-index value is great than ten thousand',
|
|
1087
|
+
/**
|
|
1088
|
+
* Indicate whether the method is collected when the method been called .
|
|
1089
|
+
*
|
|
1090
|
+
* @param {string} scope - The class name of public api
|
|
1091
|
+
* @param {string} methodName - The method name called by the public api
|
|
1092
|
+
* @returns {boolean} A boolean value
|
|
1093
|
+
*/
|
|
1094
|
+
canAccept: (scope, methodName) => scope === 'VegaZIndexManager' && methodName === 'overrideZIndexBasicValues',
|
|
1095
|
+
/**
|
|
1096
|
+
* The function checks if the method name is load.
|
|
1097
|
+
*
|
|
1098
|
+
* @param {unknown[]} args - The parameter of slimmer method
|
|
1099
|
+
* @returns {boolean} A boolean value
|
|
1100
|
+
*/
|
|
1101
|
+
payloadValue: (args) => {
|
|
1102
|
+
return args['base'] > 10000;
|
|
1103
|
+
},
|
|
1104
|
+
},
|
|
1105
|
+
];
|
|
1106
|
+
|
|
1107
|
+
var __decorate$1 = (undefined && undefined.__decorate) || function (decorators, target, key, desc) {
|
|
1108
|
+
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
1109
|
+
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
1110
|
+
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
1111
|
+
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
1112
|
+
};
|
|
1113
|
+
/**
|
|
1114
|
+
* The VegaZIndexManager class calls a method in the ZIndexManager class to
|
|
1115
|
+
* change z-index values based on the input.
|
|
1116
|
+
*/
|
|
1117
|
+
class VegaZIndexManager {
|
|
1118
|
+
constructor() {
|
|
1119
|
+
this.vegaPublicAPIRuntimeMetricsSlimmer = createPublicAPIRuntimeMetricsSlimmer(VegaZIndexManager, ['overrideZIndexBasicValues'], ZIndexManagerRuntimeMetricsPayloadDefinition);
|
|
1120
|
+
}
|
|
1121
|
+
/**
|
|
1122
|
+
* The function "overrideZIndexBasicValues" calls a method in the "ZIndexManager" class to change the
|
|
1123
|
+
* z-index values based on the input.
|
|
1124
|
+
*
|
|
1125
|
+
* @param {ZIndexBasicValues} input - The input parameter is of type ZIndexBasicValues.
|
|
1126
|
+
* @vegaVersion 2.3.0
|
|
1127
|
+
*/
|
|
1128
|
+
overrideZIndexBasicValues(input) {
|
|
1129
|
+
InternalVegaZIndexManager$1.overrideZIndexBasicValues(input);
|
|
1130
|
+
}
|
|
1131
|
+
}
|
|
1132
|
+
__decorate$1([
|
|
1133
|
+
InjectVegaTelemetrySlimmer()
|
|
1134
|
+
], VegaZIndexManager.prototype, "vegaPublicAPIRuntimeMetricsSlimmer", void 0);
|
|
1135
|
+
const VegaZIndexManager$1 = new VegaZIndexManager();
|
|
1136
|
+
|
|
1137
|
+
const VegaSkeletonRuntimeMetricsPayloadDefinition = [
|
|
1138
|
+
{
|
|
1139
|
+
payloadKey: 'IS_LOAD_METHOD_CALLED',
|
|
1140
|
+
payloadDescription: 'Indicate if the method load of public API VegaSkeletonLoaderController is called',
|
|
1141
|
+
/**
|
|
1142
|
+
* Indicate whether the method is collected when the method been called .
|
|
1143
|
+
*
|
|
1144
|
+
* @param {string} scope - The class name of public api
|
|
1145
|
+
* @param {string} methodName - The method name called by the public api
|
|
1146
|
+
* @returns {boolean} A boolean value
|
|
1147
|
+
*/
|
|
1148
|
+
canAccept: (scope, methodName) => scope === 'VegaSkeletonLoaderController' && methodName === 'load',
|
|
1149
|
+
/**
|
|
1150
|
+
* The function checks if the method name is load.
|
|
1151
|
+
*
|
|
1152
|
+
* @returns {boolean} A boolean value
|
|
1153
|
+
*/
|
|
1154
|
+
payloadValue: () => {
|
|
1155
|
+
return true;
|
|
1156
|
+
},
|
|
1157
|
+
},
|
|
1158
|
+
{
|
|
1159
|
+
payloadKey: 'IS_UNLOAD_METHOD_CALLED',
|
|
1160
|
+
payloadDescription: 'Indicate if the method unLoad of public API VegaSkeletonLoaderController is called',
|
|
1161
|
+
/**
|
|
1162
|
+
* Indicate whether the method is collected when the method been called .
|
|
1163
|
+
*
|
|
1164
|
+
* @param {string} scope - The class name of public api
|
|
1165
|
+
* @param {string} methodName - The method name called by the public api
|
|
1166
|
+
* @returns {boolean} A boolean value
|
|
1167
|
+
*/
|
|
1168
|
+
canAccept: (scope, methodName) => scope === 'VegaSkeletonLoaderController' && methodName === 'unLoad',
|
|
1169
|
+
/**
|
|
1170
|
+
* The function checks if the method name is unLoad.
|
|
1171
|
+
*
|
|
1172
|
+
* @returns {boolean} A boolean value
|
|
1173
|
+
*/
|
|
1174
|
+
payloadValue: () => {
|
|
1175
|
+
return true;
|
|
1176
|
+
},
|
|
1177
|
+
},
|
|
1178
|
+
{
|
|
1179
|
+
payloadKey: 'IS_UNLOADALL_METHOD_CALLED',
|
|
1180
|
+
payloadDescription: 'Indicate if the method unLoadAll of public API VegaSkeletonLoaderController is called',
|
|
1181
|
+
/**
|
|
1182
|
+
* Indicate whether the method is collected when the method been called .
|
|
1183
|
+
*
|
|
1184
|
+
* @param {string} scope - The class name of public api
|
|
1185
|
+
* @param {string} methodName - The method name called by the public api
|
|
1186
|
+
* @returns {boolean} A boolean value
|
|
1187
|
+
*/
|
|
1188
|
+
canAccept: (scope, methodName) => scope === 'VegaSkeletonLoaderController' && methodName === 'unLoadAll',
|
|
1189
|
+
/**
|
|
1190
|
+
* The function checks if the method name is unLoadAll.
|
|
1191
|
+
*
|
|
1192
|
+
* @returns {boolean} A boolean value
|
|
1193
|
+
*/
|
|
1194
|
+
payloadValue: () => {
|
|
1195
|
+
return true;
|
|
1196
|
+
},
|
|
1197
|
+
},
|
|
1198
|
+
];
|
|
1199
|
+
|
|
1200
|
+
var __decorate = (undefined && undefined.__decorate) || function (decorators, target, key, desc) {
|
|
1201
|
+
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
1202
|
+
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
1203
|
+
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
1204
|
+
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
1205
|
+
};
|
|
1206
|
+
/**
|
|
1207
|
+
* Vega Skeleton Loader Controller to show skeletons in the target elements
|
|
1208
|
+
*/
|
|
1209
|
+
class VegaSkeletonLoaderController {
|
|
1210
|
+
constructor() {
|
|
1211
|
+
this.vegaPublicAPIRuntimeMetricsSlimmer = createPublicAPIRuntimeMetricsSlimmer(VegaSkeletonLoaderController, ['load', 'unLoad', 'unLoadAll'], VegaSkeletonRuntimeMetricsPayloadDefinition);
|
|
1212
|
+
this.loaderMap = new Map();
|
|
1213
|
+
}
|
|
1214
|
+
/**
|
|
1215
|
+
* Load the skeletons in the target elements
|
|
1216
|
+
*
|
|
1217
|
+
* @param { VegaSkeletonLoaderConfig } config - Configuration for the loading function
|
|
1218
|
+
* @param {string} config.target - Target elements to show the skeletons.
|
|
1219
|
+
* @param {VegaSkeletonLoaderConfig.type} [config.type = 'text'] - Type of the skeleton.
|
|
1220
|
+
* @param {VegaSkeletonLoaderConfig.width} config.width - Width of the skeleton.
|
|
1221
|
+
* @param {VegaSkeletonLoaderConfig.height} config.height - Height of the skeleton.
|
|
1222
|
+
* @param {VegaSkeletonLoaderConfig.items} config.items - Configuration for multiple skeleton items.
|
|
1223
|
+
* @param {VegaSkeletonLoaderConfig.layout} config.layout - Layout of the skeleton items.
|
|
1224
|
+
* @returns { string } - Key of the loaded skeleton items.
|
|
1225
|
+
* @vegaVersion 2.16.0
|
|
1226
|
+
*/
|
|
1227
|
+
load({ target, type = 'text', width, height, items, layout }) {
|
|
1228
|
+
// eslint-disable-next-line no-restricted-globals
|
|
1229
|
+
const targets = Array.from(document.body.querySelectorAll(target));
|
|
1230
|
+
const key = `vega-skeleton-loader-${generateUUID()}`;
|
|
1231
|
+
const loaderItems = [];
|
|
1232
|
+
targets.forEach((target) => {
|
|
1233
|
+
const skeletonsLoaders = !items
|
|
1234
|
+
? [this.createSkeleton({ type, width, height })]
|
|
1235
|
+
: items.map(this.createSkeleton);
|
|
1236
|
+
const itemsWithKey = (layout ? [this.wrapLayout(skeletonsLoaders, layout)] : skeletonsLoaders).map((item) => {
|
|
1237
|
+
item.dataset[VegaSkeletonLoaderController.LOADER_DATA_SET_KEY] = key;
|
|
1238
|
+
return item;
|
|
1239
|
+
});
|
|
1240
|
+
loaderItems.push(...itemsWithKey);
|
|
1241
|
+
target.append(...itemsWithKey);
|
|
1242
|
+
});
|
|
1243
|
+
this.loaderMap.set(key, loaderItems);
|
|
1244
|
+
return key;
|
|
1245
|
+
}
|
|
1246
|
+
/**
|
|
1247
|
+
* Remove the skeletons from the dom.
|
|
1248
|
+
*
|
|
1249
|
+
* @param {string} key - The key returned from {@link VegaSkeletonLoaderController.load}.
|
|
1250
|
+
* @vegaVersion 2.16.0
|
|
1251
|
+
*/
|
|
1252
|
+
unLoad(key) {
|
|
1253
|
+
if (this.loaderMap.has(key)) {
|
|
1254
|
+
this.loaderMap.get(key).forEach((item) => item.remove());
|
|
1255
|
+
this.loaderMap.delete(key);
|
|
1256
|
+
}
|
|
1257
|
+
}
|
|
1258
|
+
/**
|
|
1259
|
+
* Remove all the skeletons from the dom.
|
|
1260
|
+
*
|
|
1261
|
+
* @vegaVersion 2.16.0
|
|
1262
|
+
*/
|
|
1263
|
+
unLoadAll() {
|
|
1264
|
+
for (const items of this.loaderMap.values()) {
|
|
1265
|
+
items.forEach((item) => item.remove());
|
|
1266
|
+
}
|
|
1267
|
+
this.loaderMap.clear();
|
|
1268
|
+
}
|
|
1269
|
+
/**
|
|
1270
|
+
* Create a skeleton item. The skeleton animated always be true
|
|
1271
|
+
*
|
|
1272
|
+
* @param {VegaSkeletonLoaderItem} config - Configuration for the skeleton item.
|
|
1273
|
+
* @returns {HTMLVegaSkeletonElement} - Skeleton item.
|
|
1274
|
+
*/
|
|
1275
|
+
createSkeleton(config) {
|
|
1276
|
+
const { type, width, height } = config;
|
|
1277
|
+
// eslint-disable-next-line no-restricted-globals
|
|
1278
|
+
const skeleton = document.createElement('vega-skeleton');
|
|
1279
|
+
Object.assign(skeleton, { animated: true, type, width, height });
|
|
1280
|
+
return skeleton;
|
|
1281
|
+
}
|
|
1282
|
+
/**
|
|
1283
|
+
* Wrap the flex layout for the skeletons.
|
|
1284
|
+
*
|
|
1285
|
+
* @param {HTMLElement[]} skeletons - Skeleton elements of the loader.
|
|
1286
|
+
* @param {VegaSkeletonLoaderLayout} layout - Flex properties for the layout.
|
|
1287
|
+
* @returns {HTMLVegaFlexElement} - Container wrapping the skeletons in the specified flex layout.
|
|
1288
|
+
*/
|
|
1289
|
+
wrapLayout(skeletons, layout) {
|
|
1290
|
+
// eslint-disable-next-line no-restricted-globals
|
|
1291
|
+
const skeletonContainer = document.createElement('vega-flex');
|
|
1292
|
+
Object.assign(skeletonContainer, Object.assign({ className: 'vega-skeleton-loader-template-container' }, layout.props));
|
|
1293
|
+
Object.assign(skeletonContainer.style, layout.style);
|
|
1294
|
+
skeletonContainer.append(...skeletons);
|
|
1295
|
+
return skeletonContainer;
|
|
1296
|
+
}
|
|
1297
|
+
}
|
|
1298
|
+
VegaSkeletonLoaderController.LOADER_DATA_SET_KEY = 'vegaSkeletonLoaderKey';
|
|
1299
|
+
__decorate([
|
|
1300
|
+
InjectVegaTelemetrySlimmer()
|
|
1301
|
+
], VegaSkeletonLoaderController.prototype, "vegaPublicAPIRuntimeMetricsSlimmer", void 0);
|
|
1302
|
+
const VegaSkeletonLoader = new VegaSkeletonLoaderController();
|
|
1303
|
+
|
|
1304
|
+
/**
|
|
1305
|
+
* Base renderer for Vega Rich Text Editor.
|
|
1306
|
+
*/
|
|
1307
|
+
class VegaRTEExtensionRenderer extends VegaRTEBaseRenderer {
|
|
1308
|
+
/**
|
|
1309
|
+
* Returns the styles to be injected into the RTE scope.
|
|
1310
|
+
* Override this method to provide custom styles for the custom blocks or nodes.
|
|
1311
|
+
*
|
|
1312
|
+
* @returns {string} - The styles as a string.
|
|
1313
|
+
*/
|
|
1314
|
+
injectRTEScopeStyles() {
|
|
1315
|
+
return '';
|
|
1316
|
+
}
|
|
1317
|
+
/**
|
|
1318
|
+
* Renders the given data as a DOM element.
|
|
1319
|
+
*
|
|
1320
|
+
* @param {RTEBlock | RTENode} renderData - The data to render, which can be a block or a node.
|
|
1321
|
+
* @param {RTERenderContext} rteContext - The rte editor context.
|
|
1322
|
+
* @param {VegaRTECreateElementFunction} createElement - The function to create a DOM element.
|
|
1323
|
+
* @returns {VegaRTERenderResult} - The rendered DOM element.
|
|
1324
|
+
*/
|
|
1325
|
+
render(renderData, rteContext, createElement) {
|
|
1326
|
+
var _a;
|
|
1327
|
+
const element = this.doRender(createElement, renderData, rteContext);
|
|
1328
|
+
this.fallbackRegisterRef(element, renderData);
|
|
1329
|
+
this.appendChildren(((_a = element.childrenContainerGetter) === null || _a === void 0 ? void 0 : _a.call(element)) || element, renderData, rteContext, createElement);
|
|
1330
|
+
return element;
|
|
1331
|
+
}
|
|
1332
|
+
/**
|
|
1333
|
+
* Register the reference of the element in the rendering registry.
|
|
1334
|
+
*
|
|
1335
|
+
* @param {RTEBlock | RTENode} renderData - The data to register with the element.
|
|
1336
|
+
* @returns {VegaRTEUseRef} - The function to register the element.
|
|
1337
|
+
*/
|
|
1338
|
+
useRef(renderData) {
|
|
1339
|
+
renderData[VegaRTEExtensionRenderer.REGISTER_REF_FLAG] = true;
|
|
1340
|
+
return function (element) {
|
|
1341
|
+
if (element) {
|
|
1342
|
+
stateEntityRenderingRegistry.register(element, renderData);
|
|
1343
|
+
}
|
|
1344
|
+
};
|
|
1345
|
+
}
|
|
1346
|
+
/**
|
|
1347
|
+
* Get a registered renderer by its key.
|
|
1348
|
+
*
|
|
1349
|
+
* @param {string} key - The key of the renderer.
|
|
1350
|
+
* @returns {Nullable<BaseRenderer>} - The registered renderer or null if not found.
|
|
1351
|
+
*/
|
|
1352
|
+
getDTORenderer(key) {
|
|
1353
|
+
return RTEDTORendererManager.getRTERenderer(key);
|
|
1354
|
+
}
|
|
1355
|
+
/**
|
|
1356
|
+
* Auto render the block children if the block element is not exist
|
|
1357
|
+
*
|
|
1358
|
+
* @param {VegaRTERenderResult} parentElement - The parent element to append children to.
|
|
1359
|
+
* @param {RTEBlock | RTENode} renderData - The data to render children for.
|
|
1360
|
+
* @param {RTERenderContext} rteContext - The render context.
|
|
1361
|
+
* @param {VegaRTECreateElementFunction} createElement - The function to create a DOM element.
|
|
1362
|
+
*/
|
|
1363
|
+
appendChildren(parentElement, renderData, rteContext, createElement) {
|
|
1364
|
+
if (Array.isArray(renderData['children']) &&
|
|
1365
|
+
renderData['children'].length &&
|
|
1366
|
+
!parentElement['$children$']) {
|
|
1367
|
+
parentElement['$children$'] = renderData['children']
|
|
1368
|
+
.map((child) => {
|
|
1369
|
+
return this.renderChildren(child, rteContext, createElement);
|
|
1370
|
+
})
|
|
1371
|
+
.filter(isNonNullable);
|
|
1372
|
+
}
|
|
1373
|
+
}
|
|
1374
|
+
/**
|
|
1375
|
+
* Render the children node.
|
|
1376
|
+
*
|
|
1377
|
+
* @param {RTENode | RTEBlock} renderData - The node to render children for.
|
|
1378
|
+
* @param {RTERenderContext} rteContext - The render context.
|
|
1379
|
+
* @param {VegaRTECreateElementFunction} createElement - The function to create a DOM element.
|
|
1380
|
+
* @returns {Nullable<VegaRTERenderResult>} - The rendered DOM element.
|
|
1381
|
+
*/
|
|
1382
|
+
renderChildren(renderData, rteContext, createElement) {
|
|
1383
|
+
const renderer = this.getDTORenderer(renderData.type);
|
|
1384
|
+
if (renderer) {
|
|
1385
|
+
return renderer.render(renderData, rteContext, createElement);
|
|
1386
|
+
}
|
|
1387
|
+
}
|
|
1388
|
+
/**
|
|
1389
|
+
* Fallback register reference for the element.
|
|
1390
|
+
*
|
|
1391
|
+
* @param {VegaRTERenderResult} element - The rendered DOM element.
|
|
1392
|
+
* @param {RTEBlock | RTENode} renderData - The data to register with the element.
|
|
1393
|
+
*/
|
|
1394
|
+
fallbackRegisterRef(element, renderData) {
|
|
1395
|
+
if (!renderData[VegaRTEExtensionRenderer.REGISTER_REF_FLAG] &&
|
|
1396
|
+
element['$attrs$'] &&
|
|
1397
|
+
!element['$attrs$']['ref']) {
|
|
1398
|
+
// eslint-disable-next-line jsdoc/require-jsdoc
|
|
1399
|
+
element['$attrs$']['ref'] = this.useRef(renderData);
|
|
1400
|
+
}
|
|
1401
|
+
}
|
|
1402
|
+
}
|
|
1403
|
+
VegaRTEExtensionRenderer.REGISTER_REF_FLAG = '__registeredRef__';
|
|
1404
|
+
|
|
1405
|
+
/**
|
|
1406
|
+
* Abstract class for Vega Rich Text Editor extensions.
|
|
1407
|
+
*/
|
|
1408
|
+
class VegaRTEExtension {
|
|
1409
|
+
constructor() {
|
|
1410
|
+
/**
|
|
1411
|
+
* The context of the RTE extension, which may include references to the host editor and other relevant information.
|
|
1412
|
+
*/
|
|
1413
|
+
this.extensionContext = null;
|
|
1414
|
+
this.hasCustomStylesRenderers = new Set();
|
|
1415
|
+
}
|
|
1416
|
+
/**
|
|
1417
|
+
* Registers an action handle strategy for a specific node or block class.
|
|
1418
|
+
*
|
|
1419
|
+
* @param {string} nodeOrBlockClassName - The name of the node or block class.
|
|
1420
|
+
* @param {string} actionType - The type of the action.
|
|
1421
|
+
* @param {ActionHandleStrategy<ModifyContentAction, RTENode | RTEBlock | VegaRTEContent>} strategy - The strategy to register.
|
|
1422
|
+
*/
|
|
1423
|
+
static registerActionHandleStrategy(nodeOrBlockClassName, actionType, strategy) {
|
|
1424
|
+
ActionHandleStrategyRegistry.register(actionType, nodeOrBlockClassName, strategy);
|
|
1425
|
+
}
|
|
1426
|
+
/**
|
|
1427
|
+
* Registers an action handler interceptor for a specific node or block class.
|
|
1428
|
+
*
|
|
1429
|
+
* @param {string} nodeOrBlockClassName - The name of the node or block class.
|
|
1430
|
+
* @param {string} actionType - The type of the action.
|
|
1431
|
+
* @param {ActionHandlerInterceptor<ModifyContentAction, RTENode | RTEBlock | VegaRTEContent>} strategy - The interceptor to register.
|
|
1432
|
+
*/
|
|
1433
|
+
static registerActionHandlerInterceptor(nodeOrBlockClassName, actionType, strategy) {
|
|
1434
|
+
ActionHandlerInterceptorRegistry.register(actionType, nodeOrBlockClassName, strategy);
|
|
1435
|
+
}
|
|
1436
|
+
/**
|
|
1437
|
+
* Initializes the RTE extension with the provided context.
|
|
1438
|
+
*
|
|
1439
|
+
* @param {RTEExtensionContext} context - The context of the RTE extension.
|
|
1440
|
+
*/
|
|
1441
|
+
initialExtension(context) {
|
|
1442
|
+
this.extensionContext = context;
|
|
1443
|
+
}
|
|
1444
|
+
/**
|
|
1445
|
+
* Callback method invoked when the extension is destroyed.
|
|
1446
|
+
* Override this method to perform any necessary cleanup.
|
|
1447
|
+
*/
|
|
1448
|
+
destroyExtension() {
|
|
1449
|
+
}
|
|
1450
|
+
/**
|
|
1451
|
+
* Collect custom styles for the extension renderers.
|
|
1452
|
+
* If custom nodes have special styles, override this method to provide the styles.
|
|
1453
|
+
*
|
|
1454
|
+
* @returns {string} - The custom styles as a string.
|
|
1455
|
+
*/
|
|
1456
|
+
collectExtensionRendererStyles() {
|
|
1457
|
+
let styles = '';
|
|
1458
|
+
if (this.hasCustomStylesRenderers.size > 0) {
|
|
1459
|
+
this.hasCustomStylesRenderers.forEach((renderer) => {
|
|
1460
|
+
styles += `${renderer.injectRTEScopeStyles()}\n`;
|
|
1461
|
+
});
|
|
1462
|
+
}
|
|
1463
|
+
return styles;
|
|
1464
|
+
}
|
|
1465
|
+
/**
|
|
1466
|
+
* Register a node type with the extension.
|
|
1467
|
+
*
|
|
1468
|
+
* @param {string} type - The type of the node or block. The type should be a string that uniquely identifies the node or block.
|
|
1469
|
+
* @param {ClassType<RTEBlock | RTENode>} DTOClass - The DTO class to register.
|
|
1470
|
+
*/
|
|
1471
|
+
registerNode(type, DTOClass) {
|
|
1472
|
+
RTEDTOClassManager.registerRTEDTOClass(type, DTOClass);
|
|
1473
|
+
}
|
|
1474
|
+
/**
|
|
1475
|
+
* Register a renderer for a node type with the extension.
|
|
1476
|
+
*
|
|
1477
|
+
* @param {string} type - The type of the node or block. The type should be a string that uniquely identifies the node or block.
|
|
1478
|
+
* @param {BaseRenderer} renderer - The renderer to register.
|
|
1479
|
+
*/
|
|
1480
|
+
registerRenderer(type, renderer) {
|
|
1481
|
+
RTEDTORendererManager.registerRTEDTORenderer(type, renderer);
|
|
1482
|
+
if (renderer instanceof VegaRTEExtensionRenderer && renderer.injectRTEScopeStyles()) {
|
|
1483
|
+
this.hasCustomStylesRenderers.add(renderer);
|
|
1484
|
+
}
|
|
1485
|
+
}
|
|
1486
|
+
/**
|
|
1487
|
+
* Register a toolbar button renderer for the extension.
|
|
1488
|
+
*
|
|
1489
|
+
* @param {string} type - The type of the toolbar button.
|
|
1490
|
+
* @param {VegaRTEToolbarButtonRenderer} renderer - The renderer to register.
|
|
1491
|
+
*/
|
|
1492
|
+
registerToolbarButtonRenderer(type, renderer) {
|
|
1493
|
+
RTEDTORendererManager.registerRTEToolbarButtonRenderer(type, renderer);
|
|
1494
|
+
}
|
|
1495
|
+
/**
|
|
1496
|
+
* This is a helper method that utilizes RTEUtils to register common strategies.
|
|
1497
|
+
* Call the method with the class name of the block to make it support basic strategies like:
|
|
1498
|
+
* - Delete children
|
|
1499
|
+
* - Append the children
|
|
1500
|
+
* - Delete the block children content
|
|
1501
|
+
*
|
|
1502
|
+
* @param {string} blockClassName - The class name of the block to register strategies for.
|
|
1503
|
+
*/
|
|
1504
|
+
registerBlockBasicStrategies(blockClassName) {
|
|
1505
|
+
RTEDTOActionStrategyManager.registerBlockBasicStrategies(blockClassName);
|
|
1506
|
+
}
|
|
1507
|
+
/**
|
|
1508
|
+
* Unregister a strategy for a specific action type and block class if not need.
|
|
1509
|
+
*
|
|
1510
|
+
* @param {string} actionType - The special action type or the action class name.
|
|
1511
|
+
* @param {string} blockClassName - The class name of the block to unregister the strategy for.
|
|
1512
|
+
*/
|
|
1513
|
+
unRegisterStrategy(actionType, blockClassName) {
|
|
1514
|
+
ActionHandleStrategyRegistry.unregister(actionType, blockClassName);
|
|
1515
|
+
}
|
|
1516
|
+
/**
|
|
1517
|
+
* Unregister a strategy for a specific action type and block class if not need.
|
|
1518
|
+
*
|
|
1519
|
+
* @param {string} actionType - The special action type or the action class name.
|
|
1520
|
+
* @param {string} blockClassName - The class name of the block to unregister the strategy for.
|
|
1521
|
+
* @param {ActionHandlerInterceptor<ModifyContentAction, RTENode | RTEBlock | VegaRTEContent>} strategy - The interceptor to unregister.
|
|
1522
|
+
*/
|
|
1523
|
+
unRegisterInterceptor(actionType, blockClassName, strategy) {
|
|
1524
|
+
ActionHandlerInterceptorRegistry.unregister(actionType, blockClassName, strategy);
|
|
1525
|
+
}
|
|
1526
|
+
/**
|
|
1527
|
+
* Register an element to block DTO class strategy.
|
|
1528
|
+
*
|
|
1529
|
+
* @param {ElementToDTOStrategy} strategy - The strategy to register.
|
|
1530
|
+
*/
|
|
1531
|
+
registerElementToBlockDTOClassStrategy(strategy) {
|
|
1532
|
+
ElementToDTOClassStrategyManager.registerElementToBlockStrategy(strategy);
|
|
1533
|
+
}
|
|
1534
|
+
/**
|
|
1535
|
+
* Register an element to node DTO class strategy.
|
|
1536
|
+
*
|
|
1537
|
+
* @param {ElementToDTOStrategy} strategy - The strategy to register.
|
|
1538
|
+
*/
|
|
1539
|
+
registerElementToNodeDTOClassStrategy(strategy) {
|
|
1540
|
+
ElementToDTOClassStrategyManager.registerElementToNodeStrategy(strategy);
|
|
1541
|
+
}
|
|
1542
|
+
/**
|
|
1543
|
+
* Get the registered element to node DTO class strategies.
|
|
1544
|
+
*
|
|
1545
|
+
* @returns {ElementToDTOStrategy[]} - The registered element to node DTO class strategies.
|
|
1546
|
+
*/
|
|
1547
|
+
getElementToNodeDTOClassStrategies() {
|
|
1548
|
+
return ElementToDTOClassStrategyManager.getElementToNodeStrategies();
|
|
1549
|
+
}
|
|
1550
|
+
}
|
|
1551
|
+
|
|
1552
|
+
/**
|
|
1553
|
+
* Base class for rendering extension toolbar button in the rich text editor.
|
|
1554
|
+
* The renderer provides common functionalities for rendering toolbar buttons, including:
|
|
1555
|
+
* - Rendering a button with an icon, label, and optional arrow icon.
|
|
1556
|
+
* - Rendering a dropdown with a list of items.
|
|
1557
|
+
* - Rendering dropdown items.
|
|
1558
|
+
* - Rendering template for dropdown list.
|
|
1559
|
+
* - Determining if the button should be disabled based on the editor context.
|
|
1560
|
+
* - Handling button and dropdown click events.
|
|
1561
|
+
* Override the methods to customize the rendering and behavior of the button.
|
|
1562
|
+
*/
|
|
1563
|
+
class VegaRTEToolbarButtonRenderer {
|
|
1564
|
+
/**
|
|
1565
|
+
* Checks if the button should be hidden.
|
|
1566
|
+
*
|
|
1567
|
+
* @param {VegaRTEToolbarRenderContext} editorContext The render context for the editor.
|
|
1568
|
+
* @returns {boolean} True if the button is hidden, false otherwise.
|
|
1569
|
+
*/
|
|
1570
|
+
isHidden(editorContext) {
|
|
1571
|
+
return editorContext.sourceEditMode;
|
|
1572
|
+
}
|
|
1573
|
+
/**
|
|
1574
|
+
* Renders a dropdown component with the specified properties and children.
|
|
1575
|
+
*
|
|
1576
|
+
* @param {VegaRTECreateElementFunction} h - Create element function.
|
|
1577
|
+
* @param {VegaRTEToolbarRenderContext} editorContext - The render context for the editor.
|
|
1578
|
+
* @param {RTEToolbarDropdownProps} dropdownProps - The properties for the dropdown.
|
|
1579
|
+
* @param {VegaRTERenderResult[]} children - The children elements for the dropdown.
|
|
1580
|
+
* @returns {VegaRTERenderResult} - The render result for the dropdown.
|
|
1581
|
+
*/
|
|
1582
|
+
renderDropdown(h, editorContext, dropdownProps, children) {
|
|
1583
|
+
return h('vega-dropdown', Object.assign({ trigger: 'click', searchable: false, maxWidth: '200', itemDisplayRule: 'ellipsis',
|
|
1584
|
+
// eslint-disable-next-line jsdoc/require-jsdoc
|
|
1585
|
+
ref: (el) => {
|
|
1586
|
+
DomNodeSubjectObserverFactory.addUniqueObserverToNode(el, VegaDropdownClick, (input) => this.handleDropdownClick(input.detail, editorContext));
|
|
1587
|
+
} }, dropdownProps), children);
|
|
1588
|
+
}
|
|
1589
|
+
/**
|
|
1590
|
+
* Renders the dropdown list template.
|
|
1591
|
+
*
|
|
1592
|
+
* @param {VegaRTECreateElementFunction} h - Create element function.
|
|
1593
|
+
* @param {(RTEDropdownListItem | RTEDropdownListGroup)[]} itemList - The list of dropdown items.
|
|
1594
|
+
* @returns {VegaRTERenderResult} - The render result for the dropdown list.
|
|
1595
|
+
*/
|
|
1596
|
+
renderDropdownListTemplate(h, itemList) {
|
|
1597
|
+
return h('div', {
|
|
1598
|
+
slot: 'items',
|
|
1599
|
+
onMouseDown: this.preventDefault,
|
|
1600
|
+
}, itemList.map((item) => {
|
|
1601
|
+
return 'children' in item
|
|
1602
|
+
? this.renderDropdownGroup(h, item)
|
|
1603
|
+
: this.renderDropdownItem(h, item);
|
|
1604
|
+
}));
|
|
1605
|
+
}
|
|
1606
|
+
/**
|
|
1607
|
+
* Renders a dropdown item for the toolbar button.
|
|
1608
|
+
*
|
|
1609
|
+
* @param {VegaRTECreateElementFunction} h - Create element function.
|
|
1610
|
+
* @param {RTEDropdownListItem} item - The dropdown item.
|
|
1611
|
+
* @returns {VegaRTERenderResult} - The render result for the dropdown item.
|
|
1612
|
+
*/
|
|
1613
|
+
renderDropdownItem(h, item) {
|
|
1614
|
+
return h('vega-dropdown-item', {
|
|
1615
|
+
key: item.key,
|
|
1616
|
+
itemKey: item.key,
|
|
1617
|
+
label: item.label,
|
|
1618
|
+
prefixIcon: item.icon,
|
|
1619
|
+
});
|
|
1620
|
+
}
|
|
1621
|
+
/**
|
|
1622
|
+
* Renders a dropdown item for the toolbar button.
|
|
1623
|
+
*
|
|
1624
|
+
* @param {VegaRTECreateElementFunction} h - Create element function.
|
|
1625
|
+
* @param {RTEDropdownListGroup} item - The dropdown group.
|
|
1626
|
+
* @returns {VegaRTERenderResult} - The render result for the dropdown item.
|
|
1627
|
+
*/
|
|
1628
|
+
renderDropdownGroup(h, item) {
|
|
1629
|
+
return h('vega-dropdown-group', {
|
|
1630
|
+
key: item.key,
|
|
1631
|
+
label: item.label,
|
|
1632
|
+
divide: false,
|
|
1633
|
+
}, item.children.map((child) => {
|
|
1634
|
+
return 'children' in child
|
|
1635
|
+
? this.renderDropdownGroup(h, child)
|
|
1636
|
+
: this.renderDropdownItem(h, child);
|
|
1637
|
+
}));
|
|
1638
|
+
}
|
|
1639
|
+
/**
|
|
1640
|
+
* Renders a common toolbar button with optional icon, label, and arrow icon.
|
|
1641
|
+
*
|
|
1642
|
+
* @param {VegaRTECreateElementFunction} h - Create element function.
|
|
1643
|
+
* @param {VegaRTEToolbarRenderContext} editorContext - The render context for the editor.
|
|
1644
|
+
* @param {RTEToolbarButtonProps} buttonProps - The properties for the button.
|
|
1645
|
+
* @returns {VegaRTERenderResult} - The render result for the button.
|
|
1646
|
+
*/
|
|
1647
|
+
renderButton(h, editorContext, buttonProps) {
|
|
1648
|
+
const { icon, label, showArrowIcon } = buttonProps;
|
|
1649
|
+
const isDisabled = this.isDisabled(editorContext);
|
|
1650
|
+
return h('vega-rich-text-editor-toolbar-button', {
|
|
1651
|
+
disabled: isDisabled,
|
|
1652
|
+
icon: icon,
|
|
1653
|
+
hidden: this.isHidden(editorContext),
|
|
1654
|
+
selected: this.isSelected(editorContext),
|
|
1655
|
+
// eslint-disable-next-line jsdoc/require-jsdoc
|
|
1656
|
+
ref: (el) => {
|
|
1657
|
+
DomNodeSubjectObserverFactory.addUniqueObserverToNode(el, VegaClick, () => this.handleButtonClick(editorContext));
|
|
1658
|
+
},
|
|
1659
|
+
onMouseDown: this.preventDefault,
|
|
1660
|
+
}, [
|
|
1661
|
+
this.renderButtonLabel(h, editorContext, label),
|
|
1662
|
+
showArrowIcon
|
|
1663
|
+
? h('vega-icon', {
|
|
1664
|
+
size: 'size-8',
|
|
1665
|
+
color: isDisabled ? 'text-disabled' : 'text-secondary',
|
|
1666
|
+
style: { marginLeft: '8px' },
|
|
1667
|
+
icon: VegaInternalIconManager.getIconKey('chevron-down'),
|
|
1668
|
+
})
|
|
1669
|
+
: null,
|
|
1670
|
+
].filter(isNonNullable));
|
|
1671
|
+
}
|
|
1672
|
+
/**
|
|
1673
|
+
* Renders the button label.
|
|
1674
|
+
*
|
|
1675
|
+
* @param {VegaRTECreateElementFunction} h - Create element function.
|
|
1676
|
+
* @param {VegaRTEToolbarRenderContext} editorContext - The render context for the editor.
|
|
1677
|
+
* @param {Nullable<string>} label - The button label if exist.
|
|
1678
|
+
* @returns {Nullable<VegaRTERenderResult>} - The render result for the button.
|
|
1679
|
+
*/
|
|
1680
|
+
renderButtonLabel(h, editorContext, label) {
|
|
1681
|
+
if (label) {
|
|
1682
|
+
const isDisabled = this.isDisabled(editorContext);
|
|
1683
|
+
return h('vega-font', {
|
|
1684
|
+
variant: 'font-field-label-sm',
|
|
1685
|
+
color: isDisabled ? 'text-disabled' : 'text-primary',
|
|
1686
|
+
}, label);
|
|
1687
|
+
}
|
|
1688
|
+
return null;
|
|
1689
|
+
}
|
|
1690
|
+
/**
|
|
1691
|
+
* Determines if the button should be disabled based on the editor context.
|
|
1692
|
+
*
|
|
1693
|
+
* @param {VegaRTEToolbarRenderContext} editorContext - The render context for the editor.
|
|
1694
|
+
* @returns {boolean} - True if the button should be disabled, false otherwise.
|
|
1695
|
+
*/
|
|
1696
|
+
isDisabled(editorContext) {
|
|
1697
|
+
return editorContext.host.disabled;
|
|
1698
|
+
}
|
|
1699
|
+
/**
|
|
1700
|
+
* Checks if the button should be selected.
|
|
1701
|
+
*
|
|
1702
|
+
* @param {VegaRTEToolbarRenderContext} _editorContext The render context for the editor.
|
|
1703
|
+
* @returns {boolean} True if the button is selected, false otherwise.
|
|
1704
|
+
*/
|
|
1705
|
+
// eslint-disable-next-line @typescript-eslint/no-unused-vars
|
|
1706
|
+
isSelected(_editorContext) {
|
|
1707
|
+
return false;
|
|
1708
|
+
}
|
|
1709
|
+
/**
|
|
1710
|
+
* Prevents the default action of the click event. This is to avoid losing focus from the editor when the button is clicked.
|
|
1711
|
+
*
|
|
1712
|
+
* @param {MouseEvent} e The mouse event to prevent default action for.
|
|
1713
|
+
*/
|
|
1714
|
+
preventDefault(e) {
|
|
1715
|
+
e.preventDefault();
|
|
1716
|
+
}
|
|
1717
|
+
/**
|
|
1718
|
+
* Recursively searches for a dropdown list item by its key.
|
|
1719
|
+
*
|
|
1720
|
+
* @param {(RTEDropdownListItem | RTEDropdownListGroup)[]} itemList The list of dropdown items or groups to search through.
|
|
1721
|
+
* @param {string} key The key of the item to find.
|
|
1722
|
+
* @returns {Nullable<RTEDropdownListItem>} The dropdown list item if found, otherwise null.
|
|
1723
|
+
*/
|
|
1724
|
+
getListItemByKey(itemList, key) {
|
|
1725
|
+
for (const item of itemList) {
|
|
1726
|
+
if ('children' in item) {
|
|
1727
|
+
const foundItem = this.getListItemByKey(item.children, key);
|
|
1728
|
+
if (foundItem) {
|
|
1729
|
+
return foundItem;
|
|
1730
|
+
}
|
|
1731
|
+
}
|
|
1732
|
+
else if (item.key === key) {
|
|
1733
|
+
return item;
|
|
1734
|
+
}
|
|
1735
|
+
}
|
|
1736
|
+
return null;
|
|
1737
|
+
}
|
|
1738
|
+
}
|
|
1739
|
+
|
|
1740
|
+
/**
|
|
1741
|
+
* Action to insert a token node at a specified range in the Rich Text Editor.
|
|
1742
|
+
*
|
|
1743
|
+
* @example block.apply(new InsertTokenNodeAction(rteRange, tokenNode));
|
|
1744
|
+
*/
|
|
1745
|
+
class InsertTokenNodeAction extends ModifyContentAction {
|
|
1746
|
+
constructor(rteRange, token) {
|
|
1747
|
+
super();
|
|
1748
|
+
this.type = 'INSERT_TOKEN_NODE';
|
|
1749
|
+
this.rteRange = null;
|
|
1750
|
+
this.actionHandleResult = false;
|
|
1751
|
+
this.rteRange = rteRange;
|
|
1752
|
+
this.token = token;
|
|
1753
|
+
}
|
|
1754
|
+
}
|
|
1755
|
+
|
|
1756
|
+
/**
|
|
1757
|
+
* Renderer for the token toolbar button in the Vega Rich Text Editor.
|
|
1758
|
+
*/
|
|
1759
|
+
class RTETokenToolbarButtonRenderer extends VegaRTEToolbarButtonRenderer {
|
|
1760
|
+
constructor(tokenList) {
|
|
1761
|
+
super();
|
|
1762
|
+
this.tokenList = [];
|
|
1763
|
+
this.extensionContext = null;
|
|
1764
|
+
this.tokenList = tokenList;
|
|
1765
|
+
}
|
|
1766
|
+
/**
|
|
1767
|
+
* Sets the RTE extension context.
|
|
1768
|
+
*
|
|
1769
|
+
* @param {RTEExtensionContext} context - The context of the RTE extension.
|
|
1770
|
+
*/
|
|
1771
|
+
injectExtensionContext(context) {
|
|
1772
|
+
this.extensionContext = context;
|
|
1773
|
+
}
|
|
1774
|
+
/**
|
|
1775
|
+
* Renders the token toolbar button.
|
|
1776
|
+
*
|
|
1777
|
+
* @param {VegaRTECreateElementFunction} createElement Function to create elements in the rich text editor.
|
|
1778
|
+
* @param {VegaRTEToolbarRenderContext} editorContext The render context for the editor.
|
|
1779
|
+
* @returns {VegaRTERenderResult} Token toolbar button.
|
|
1780
|
+
*/
|
|
1781
|
+
render(createElement, editorContext) {
|
|
1782
|
+
return this.renderDropdown(createElement, editorContext, {}, [
|
|
1783
|
+
this.renderButton(createElement, editorContext, { label: 'Tokens', showArrowIcon: true }),
|
|
1784
|
+
this.renderDropdownListTemplate(createElement, this.tokenList),
|
|
1785
|
+
]);
|
|
1786
|
+
}
|
|
1787
|
+
/**
|
|
1788
|
+
* Checks if the token toolbar button is disabled.
|
|
1789
|
+
*
|
|
1790
|
+
* @returns {boolean} True if the button is disabled, false otherwise.
|
|
1791
|
+
*/
|
|
1792
|
+
isDisabled() {
|
|
1793
|
+
if (this.extensionContext) {
|
|
1794
|
+
const { host, getSelectedNodes } = this.extensionContext;
|
|
1795
|
+
const [startNode] = getSelectedNodes();
|
|
1796
|
+
return startNode
|
|
1797
|
+
? host.disabled ||
|
|
1798
|
+
!ActionHandleStrategyRegistry.canHandle('INSERT_TOKEN_NODE', startNode.parent)
|
|
1799
|
+
: host.disabled;
|
|
1800
|
+
}
|
|
1801
|
+
return false;
|
|
1802
|
+
}
|
|
1803
|
+
/* istanbul ignore next */
|
|
1804
|
+
/**
|
|
1805
|
+
* Handles the button click event. No need this method for token button.
|
|
1806
|
+
*
|
|
1807
|
+
* @param {VegaRTEToolbarRenderContext} editorContext - The render context for the editor.
|
|
1808
|
+
*/
|
|
1809
|
+
handleButtonClick(editorContext) {
|
|
1810
|
+
}
|
|
1811
|
+
/**
|
|
1812
|
+
* Handles the token item click event from the dropdown.
|
|
1813
|
+
*
|
|
1814
|
+
* @param {string} itemKey - The key of the clicked token item.
|
|
1815
|
+
* @param {VegaRTEToolbarRenderContext} editorContext - The render context for the editor.
|
|
1816
|
+
*/
|
|
1817
|
+
handleDropdownClick(itemKey, editorContext) {
|
|
1818
|
+
const token = this.getListItemByKey(this.tokenList, itemKey);
|
|
1819
|
+
const { rteRange } = editorContext;
|
|
1820
|
+
const { startNode } = rteRange;
|
|
1821
|
+
if (startNode && startNode.parent) {
|
|
1822
|
+
const action = new InsertTokenNodeAction(rteRange, token);
|
|
1823
|
+
startNode.parent.apply(action);
|
|
1824
|
+
if (action.actionHandleResult) {
|
|
1825
|
+
this.flushEditorUI();
|
|
1826
|
+
}
|
|
1827
|
+
}
|
|
1828
|
+
}
|
|
1829
|
+
/**
|
|
1830
|
+
* Refreshes the editor UI.
|
|
1831
|
+
*/
|
|
1832
|
+
flushEditorUI() {
|
|
1833
|
+
if (this.extensionContext) {
|
|
1834
|
+
const { host, flushValue } = this.extensionContext;
|
|
1835
|
+
flushValue(host.value);
|
|
1836
|
+
}
|
|
1837
|
+
}
|
|
1838
|
+
}
|
|
1839
|
+
|
|
1840
|
+
/**
|
|
1841
|
+
* Token node for the Vega Rich Text Editor.
|
|
1842
|
+
*/
|
|
1843
|
+
class RTETokenNode extends RTETextNode {
|
|
1844
|
+
constructor(id, token, text, parentBlock, annotations) {
|
|
1845
|
+
super(id, text, parentBlock, annotations);
|
|
1846
|
+
this.type = 'token';
|
|
1847
|
+
this.token = token;
|
|
1848
|
+
this.text = text;
|
|
1849
|
+
}
|
|
1850
|
+
/**
|
|
1851
|
+
* @inheritDoc
|
|
1852
|
+
*/
|
|
1853
|
+
static from(value, parent) {
|
|
1854
|
+
const node = new RTETokenNode(value.id, value.token, value.text, parent);
|
|
1855
|
+
if (value.annotations) {
|
|
1856
|
+
node.annotationMap = this.generateTextAnnotationMap(value.annotations);
|
|
1857
|
+
}
|
|
1858
|
+
return node;
|
|
1859
|
+
}
|
|
1860
|
+
/**
|
|
1861
|
+
* Converts the token node to a JSON representation.
|
|
1862
|
+
*
|
|
1863
|
+
* @returns {VegaRTETokenNode} - The JSON representation of the token node.
|
|
1864
|
+
*/
|
|
1865
|
+
toJSON() {
|
|
1866
|
+
const json = super.toJSON();
|
|
1867
|
+
return Object.assign({ id: this.id, type: this.type, text: this.text, token: this.token }, (json.annotations ? { annotations: json.annotations } : {}));
|
|
1868
|
+
}
|
|
1869
|
+
/**
|
|
1870
|
+
* Determines if the token node is content editable.
|
|
1871
|
+
*
|
|
1872
|
+
* @returns {boolean} - Always returns false for token nodes.
|
|
1873
|
+
*/
|
|
1874
|
+
isContentEditable() {
|
|
1875
|
+
return false;
|
|
1876
|
+
}
|
|
1877
|
+
/**
|
|
1878
|
+
* Clones the token node.
|
|
1879
|
+
*
|
|
1880
|
+
* @param {RTETextBlock} parent - The parent block for the cloned node.
|
|
1881
|
+
* @returns {RTETokenNode} - The cloned token node.
|
|
1882
|
+
*/
|
|
1883
|
+
clone(parent) {
|
|
1884
|
+
return new RTETokenNode(this.id, this.token, this.text, parent, this.annotationMap);
|
|
1885
|
+
}
|
|
1886
|
+
/**
|
|
1887
|
+
* Converts the token node to an HTML representation.
|
|
1888
|
+
*
|
|
1889
|
+
* @returns {string} - The HTML representation of the token node.
|
|
1890
|
+
*/
|
|
1891
|
+
toHtml() {
|
|
1892
|
+
return `<span class="token" contenteditable="false" template-token-key="${this.token}" token-key="${this.token}"${super.generateAttributeString()}>${this.text}</span>`;
|
|
1893
|
+
}
|
|
1894
|
+
}
|
|
1895
|
+
|
|
1896
|
+
/**
|
|
1897
|
+
* Token node renderer for the rich text editor.
|
|
1898
|
+
*/
|
|
1899
|
+
class RTETokenNodeRenderer extends VegaRTEExtensionRenderer {
|
|
1900
|
+
constructor() {
|
|
1901
|
+
super(...arguments);
|
|
1902
|
+
this.extensionContext = null;
|
|
1903
|
+
}
|
|
1904
|
+
/**
|
|
1905
|
+
* Renders the token node as a DOM element.
|
|
1906
|
+
*
|
|
1907
|
+
* @param {VegaRTECreateElementFunction} createElement - The function to create a DOM element.
|
|
1908
|
+
* @param {RTETokenNode} node - The token node to render.
|
|
1909
|
+
* @param {RTERenderContext} editorContent - The editor content context.
|
|
1910
|
+
* @returns {VegaRTERenderResult} - The rendered DOM element.
|
|
1911
|
+
*/
|
|
1912
|
+
doRender(createElement, node, editorContent) {
|
|
1913
|
+
const { id, token } = node;
|
|
1914
|
+
return createElement('span', Object.assign(Object.assign({ 'key': id, 'template-token-key': token, 'token-key': token, 'contenteditable': 'false', 'style': node.getStyles(), 'class': `token ${node.getClasses()}` }, this.additionalAttributes(node)), { 'ref': this.useRef(node),
|
|
1915
|
+
// eslint-disable-next-line jsdoc/require-jsdoc
|
|
1916
|
+
'onClick': (event) => {
|
|
1917
|
+
event.preventDefault();
|
|
1918
|
+
if (editorContent && editorContent.editable !== false) {
|
|
1919
|
+
this.handleTokenElementClick(event, node);
|
|
1920
|
+
}
|
|
1921
|
+
} }), node.text);
|
|
1922
|
+
}
|
|
1923
|
+
/**
|
|
1924
|
+
* Sets the RTE extension context.
|
|
1925
|
+
*
|
|
1926
|
+
* @param {RTEExtensionContext} context - The context of the RTE extension.
|
|
1927
|
+
*/
|
|
1928
|
+
injectExtensionContext(context) {
|
|
1929
|
+
this.extensionContext = context;
|
|
1930
|
+
}
|
|
1931
|
+
/**
|
|
1932
|
+
* Override to inject RTE scope styles for the token node.
|
|
1933
|
+
*
|
|
1934
|
+
* @returns {string} The CSS styles for the token node.
|
|
1935
|
+
*/
|
|
1936
|
+
injectRTEScopeStyles() {
|
|
1937
|
+
return `span[token-key]{padding: 0 2px; margin: 0 1px; background-color: rgba(var(--v-bg-status-info, 205,209,211))}`;
|
|
1938
|
+
}
|
|
1939
|
+
/**
|
|
1940
|
+
* Handle the click event on the token element.
|
|
1941
|
+
*
|
|
1942
|
+
* @param {MouseEvent} event - The click event.
|
|
1943
|
+
* @param {RTETokenNode} node - The token node that was clicked.
|
|
1944
|
+
*/
|
|
1945
|
+
handleTokenElementClick(event, node) {
|
|
1946
|
+
event.preventDefault();
|
|
1947
|
+
if (this.extensionContext) {
|
|
1948
|
+
this.extensionContext.host.value.apply(new UpdateCursorPositionAction(node, undefined, true));
|
|
1949
|
+
}
|
|
1950
|
+
}
|
|
1951
|
+
/**
|
|
1952
|
+
* Additional attributes for the token node.
|
|
1953
|
+
*
|
|
1954
|
+
* @param {RTETokenNode} node - The token node.
|
|
1955
|
+
* @returns {Record<string, string>} Additional attributes
|
|
1956
|
+
*/
|
|
1957
|
+
additionalAttributes(node) {
|
|
1958
|
+
const annotation = node.getCustomAttributesAnnotation();
|
|
1959
|
+
let result = { wrapped: 'true' };
|
|
1960
|
+
if (annotation) {
|
|
1961
|
+
result = Object.assign(Object.assign({}, result), annotation.render());
|
|
1962
|
+
}
|
|
1963
|
+
return result;
|
|
1964
|
+
}
|
|
1965
|
+
}
|
|
1966
|
+
|
|
1967
|
+
/**
|
|
1968
|
+
* Insert a new children to the nearest position of the parent container
|
|
1969
|
+
*
|
|
1970
|
+
* @example parent.apply(new InsertNodeToNearestRoot(rteRange, nodeToBeInserted))
|
|
1971
|
+
*/
|
|
1972
|
+
class InsertNodeToNearestRootAction extends ModifyContentAction {
|
|
1973
|
+
constructor(rteRange, nodeToBeInserted) {
|
|
1974
|
+
super();
|
|
1975
|
+
this.type = ModifyContentActionType.INSERT_NODE_TO_NEAREST_ROOT;
|
|
1976
|
+
this.rteRange = rteRange;
|
|
1977
|
+
this.nodeToBeInserted = nodeToBeInserted;
|
|
1978
|
+
}
|
|
1979
|
+
}
|
|
1980
|
+
|
|
1981
|
+
/**
|
|
1982
|
+
* Strategy to handle the insertion of a token node into the nearest root block.
|
|
1983
|
+
*/
|
|
1984
|
+
class InsertTokenNodeStrategy extends ActionHandleStrategy {
|
|
1985
|
+
/**
|
|
1986
|
+
* @inheritDoc
|
|
1987
|
+
*/
|
|
1988
|
+
handleAction(action, block) {
|
|
1989
|
+
const { rteRange, token } = action;
|
|
1990
|
+
if (rteRange && rteRange.startNode) {
|
|
1991
|
+
// eslint-disable-next-line @typescript-eslint/no-unused-vars
|
|
1992
|
+
const { key, label, customAttrs = { wrapped: 'true' } } = token;
|
|
1993
|
+
const tokenNode = new RTETokenNode(generateUUID(), key, label, block);
|
|
1994
|
+
tokenNode.annotationMap.set('CUSTOM_ATTRIBUTE', new CustomAttributeAnnotation(customAttrs));
|
|
1995
|
+
block.apply(new InsertNodeToNearestRootAction(rteRange, tokenNode));
|
|
1996
|
+
action.actionHandleResult = true;
|
|
1997
|
+
}
|
|
1998
|
+
}
|
|
1999
|
+
}
|
|
2000
|
+
|
|
2001
|
+
var __rest = (undefined && undefined.__rest) || function (s, e) {
|
|
2002
|
+
var t = {};
|
|
2003
|
+
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)
|
|
2004
|
+
t[p] = s[p];
|
|
2005
|
+
if (s != null && typeof Object.getOwnPropertySymbols === "function")
|
|
2006
|
+
for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
|
|
2007
|
+
if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))
|
|
2008
|
+
t[p[i]] = s[p[i]];
|
|
2009
|
+
}
|
|
2010
|
+
return t;
|
|
2011
|
+
};
|
|
2012
|
+
/**
|
|
2013
|
+
* Strategy to convert <span class="token" token-key="...">...</span> to a token node
|
|
2014
|
+
*/
|
|
2015
|
+
class SpanToTokenNodeStrategy extends ElementToDTOStrategy {
|
|
2016
|
+
/**
|
|
2017
|
+
* @inheritDoc
|
|
2018
|
+
*/
|
|
2019
|
+
canHandle(elementsArray, currentIndex) {
|
|
2020
|
+
const element = elementsArray[currentIndex];
|
|
2021
|
+
if (element.nodeName === 'SPAN' &&
|
|
2022
|
+
element.classList.contains('token') &&
|
|
2023
|
+
element.hasAttribute('token-key')) {
|
|
2024
|
+
return 1;
|
|
2025
|
+
}
|
|
2026
|
+
return 0;
|
|
2027
|
+
}
|
|
2028
|
+
/**
|
|
2029
|
+
* @inheritDoc
|
|
2030
|
+
*/
|
|
2031
|
+
handle(elementsArray) {
|
|
2032
|
+
const element = elementsArray[0];
|
|
2033
|
+
const tokenKey = element.getAttribute('token-key');
|
|
2034
|
+
const text = element.textContent;
|
|
2035
|
+
const annotations = htmlElementToAnnotationGenerator.generate(RTETextNode, element);
|
|
2036
|
+
// Exclude customAttribute and customClass from annotations
|
|
2037
|
+
// eslint-disable-next-line @typescript-eslint/no-unused-vars
|
|
2038
|
+
const { customAttribute, customClass } = annotations, restAnnotations = __rest(annotations, ["customAttribute", "customClass"]);
|
|
2039
|
+
return {
|
|
2040
|
+
id: generateUUID(),
|
|
2041
|
+
type: 'token',
|
|
2042
|
+
token: tokenKey,
|
|
2043
|
+
text,
|
|
2044
|
+
annotations: Object.assign(Object.assign({}, restAnnotations), { customAttribute: this.createCustomAttrs(customAttribute) }),
|
|
2045
|
+
};
|
|
2046
|
+
}
|
|
2047
|
+
/**
|
|
2048
|
+
* @inheritDoc
|
|
2049
|
+
*/
|
|
2050
|
+
// eslint-disable-next-line @typescript-eslint/no-empty-function
|
|
2051
|
+
appendChildBlocks() { }
|
|
2052
|
+
/**
|
|
2053
|
+
* @inheritDoc
|
|
2054
|
+
*/
|
|
2055
|
+
shouldProceedToElementChildren() {
|
|
2056
|
+
return false;
|
|
2057
|
+
}
|
|
2058
|
+
/**
|
|
2059
|
+
* Creates custom attributes record from the given custom attribute object, clean some fixed attributes.
|
|
2060
|
+
*
|
|
2061
|
+
* @param {Record<string, string>} customAttribute - The custom attribute object
|
|
2062
|
+
* @returns {Record<string, string>} The processed custom attributes
|
|
2063
|
+
*/
|
|
2064
|
+
createCustomAttrs(customAttribute) {
|
|
2065
|
+
const result = Object.assign(Object.assign({}, customAttribute), { 'contenteditable': null, 'template-token-key': null, 'token-key': null, 'wrapped': customAttribute.wrapped === 'false' ? 'false' : 'true' });
|
|
2066
|
+
return cleanObject(result);
|
|
2067
|
+
}
|
|
2068
|
+
}
|
|
2069
|
+
|
|
2070
|
+
const spanToTokenNodeStrategy = new SpanToTokenNodeStrategy();
|
|
2071
|
+
/**
|
|
2072
|
+
* Vega Rich Text Editor Token Extension
|
|
2073
|
+
*/
|
|
2074
|
+
class VegaRTETokenExtension extends VegaRTEExtension {
|
|
2075
|
+
constructor(tokenList = []) {
|
|
2076
|
+
super();
|
|
2077
|
+
this.tokenRenderer = new RTETokenNodeRenderer();
|
|
2078
|
+
this.registerNode('token', RTETokenNode);
|
|
2079
|
+
this.registerRenderer('token', this.tokenRenderer);
|
|
2080
|
+
this.tokenToolbarButtonRenderer = new RTETokenToolbarButtonRenderer(tokenList);
|
|
2081
|
+
this.registerToolbarButtonRenderer('token', this.tokenToolbarButtonRenderer);
|
|
2082
|
+
this.registerElementToNodeDTOClassStrategy(spanToTokenNodeStrategy);
|
|
2083
|
+
}
|
|
2084
|
+
/**
|
|
2085
|
+
* @inheritDoc
|
|
2086
|
+
*/
|
|
2087
|
+
initialExtension(context) {
|
|
2088
|
+
super.initialExtension(context);
|
|
2089
|
+
this.tokenRenderer.injectExtensionContext(context);
|
|
2090
|
+
if (this.tokenToolbarButtonRenderer) {
|
|
2091
|
+
this.tokenToolbarButtonRenderer.injectExtensionContext(context);
|
|
2092
|
+
}
|
|
2093
|
+
}
|
|
2094
|
+
}
|
|
2095
|
+
(() => {
|
|
2096
|
+
const insertTokenNodeStrategy = new InsertTokenNodeStrategy();
|
|
2097
|
+
VegaRTEExtension.registerActionHandleStrategy(RTETextBlock.name, 'INSERT_TOKEN_NODE', insertTokenNodeStrategy);
|
|
2098
|
+
VegaRTEExtension.registerActionHandleStrategy(RTEListItemBlock.name, 'INSERT_TOKEN_NODE', insertTokenNodeStrategy);
|
|
2099
|
+
})();
|
|
2100
|
+
|
|
2101
|
+
const INSERT_FUNCTION_BLOCK = 'INSERT_FUNCTION_BLOCK';
|
|
2102
|
+
/**
|
|
2103
|
+
* Action to insert a function block into the rich text editor.
|
|
2104
|
+
*
|
|
2105
|
+
* @example focusedBlock.apply(new InsertFunctionBlockAction('IF'))
|
|
2106
|
+
* @example host.value.apply(new InsertFunctionBlockAction('IF'))
|
|
2107
|
+
*/
|
|
2108
|
+
class InsertFunctionBlockAction extends ModifyContentAction {
|
|
2109
|
+
constructor(functionType) {
|
|
2110
|
+
super();
|
|
2111
|
+
this.type = INSERT_FUNCTION_BLOCK;
|
|
2112
|
+
this.functionType = functionType;
|
|
2113
|
+
}
|
|
2114
|
+
}
|
|
2115
|
+
|
|
2116
|
+
/**
|
|
2117
|
+
* RTE Function Block
|
|
2118
|
+
*/
|
|
2119
|
+
class RTEFunctionBlock extends RTEBlock {
|
|
2120
|
+
constructor(id) {
|
|
2121
|
+
super(id);
|
|
2122
|
+
this.type = 'function-block';
|
|
2123
|
+
this.children = [];
|
|
2124
|
+
}
|
|
2125
|
+
/**
|
|
2126
|
+
* Creates an RTEFunctionBlock from a VegaFunctionBlock.
|
|
2127
|
+
*
|
|
2128
|
+
* @param {VegaFunctionBlock} block - The custom block to convert.
|
|
2129
|
+
* @param {VegaRTETransformOptions} [options] - Optional transformation options.
|
|
2130
|
+
* @returns {RTEFunctionBlock} The resulting RTEFunctionBlock.
|
|
2131
|
+
*/
|
|
2132
|
+
static from(block, options) {
|
|
2133
|
+
const functionBlock = new RTEFunctionBlock(block.id);
|
|
2134
|
+
const defaultAnnotation = { customClass: ['statement'] };
|
|
2135
|
+
let { annotations } = block;
|
|
2136
|
+
annotations = annotations
|
|
2137
|
+
? Object.assign(Object.assign({}, annotations), defaultAnnotation) : defaultAnnotation;
|
|
2138
|
+
super.convertAnnotationsToMap(functionBlock.annotationMap, annotations);
|
|
2139
|
+
functionBlock.children = this.generateBlockChildren(block.children, options, functionBlock);
|
|
2140
|
+
return functionBlock;
|
|
2141
|
+
}
|
|
2142
|
+
/**
|
|
2143
|
+
* Converts the RTEFunctionBlock and its children to an HTML string.
|
|
2144
|
+
*
|
|
2145
|
+
* @returns {string} The HTML string representation of the function block.
|
|
2146
|
+
*/
|
|
2147
|
+
toHtml() {
|
|
2148
|
+
const childrenHtml = this.children
|
|
2149
|
+
.map((child) => {
|
|
2150
|
+
if (child instanceof RTETextBlock) {
|
|
2151
|
+
const attrStr = this.getFunctionContentStyle(child);
|
|
2152
|
+
return `<div class="statementelement"${attrStr}>${child.getChildrenHtml()}</div>`;
|
|
2153
|
+
}
|
|
2154
|
+
else {
|
|
2155
|
+
return child.toHtml();
|
|
2156
|
+
}
|
|
2157
|
+
})
|
|
2158
|
+
.join('');
|
|
2159
|
+
return `<div class="statement">${childrenHtml}</div>`;
|
|
2160
|
+
}
|
|
2161
|
+
/**
|
|
2162
|
+
* @inheritDoc
|
|
2163
|
+
*/
|
|
2164
|
+
clone(parent) {
|
|
2165
|
+
const clonedBlock = new RTEFunctionBlock(generateUUID());
|
|
2166
|
+
clonedBlock.parent = parent;
|
|
2167
|
+
clonedBlock.children = this.children.map((child) => {
|
|
2168
|
+
const clonedChild = child.clone(clonedBlock);
|
|
2169
|
+
return clonedChild;
|
|
2170
|
+
});
|
|
2171
|
+
clonedBlock.annotationMap = super.cloneAnnotations();
|
|
2172
|
+
return clonedBlock;
|
|
2173
|
+
}
|
|
2174
|
+
/**
|
|
2175
|
+
* @inheritDoc
|
|
2176
|
+
*/
|
|
2177
|
+
getLastNode() {
|
|
2178
|
+
return this.children[this.children.length - 1].getLastNode();
|
|
2179
|
+
}
|
|
2180
|
+
/**
|
|
2181
|
+
* @inheritDoc
|
|
2182
|
+
*/
|
|
2183
|
+
isNotEmpty() {
|
|
2184
|
+
return this.children.length > 0;
|
|
2185
|
+
}
|
|
2186
|
+
/**
|
|
2187
|
+
* @inheritDoc
|
|
2188
|
+
*/
|
|
2189
|
+
toJSON() {
|
|
2190
|
+
return Object.assign(Object.assign({}, super.toJSON()), { id: this.id, type: this.type, children: this.children.map((child) => child.toJSON()) });
|
|
2191
|
+
}
|
|
2192
|
+
/**
|
|
2193
|
+
* Get the style string for function content block, excluding default paragraph styles.
|
|
2194
|
+
*
|
|
2195
|
+
* @param {RTETextBlock} block - The text block to extract styles from
|
|
2196
|
+
* @returns {string} - The style attribute string
|
|
2197
|
+
*/
|
|
2198
|
+
getFunctionContentStyle(block) {
|
|
2199
|
+
const blockAnnotationStyle = new RTEAnnotationStyle(block);
|
|
2200
|
+
let styles = blockAnnotationStyle.toCssText({ standalone: true });
|
|
2201
|
+
const textStyleAnnotation = block.getAnnotationByType('TEXT_STYLE');
|
|
2202
|
+
if (textStyleAnnotation && textStyleAnnotation.textStyle === 'paragraph') {
|
|
2203
|
+
const defaultParagraphStyles = blockAnnotationStyle.toCssText(undefined, undefined, textStyleAnnotation.renderStyle({ standalone: true }));
|
|
2204
|
+
styles = styles.replace(defaultParagraphStyles, '').trim();
|
|
2205
|
+
}
|
|
2206
|
+
return styles ? ` style="${styles}"` : '';
|
|
2207
|
+
}
|
|
2208
|
+
}
|
|
2209
|
+
|
|
2210
|
+
/**
|
|
2211
|
+
* Strategy to handle the insertion of a function block into the rich text editor.
|
|
2212
|
+
*/
|
|
2213
|
+
class InsertFunctionBlockStrategy extends ActionHandleStrategy {
|
|
2214
|
+
/**
|
|
2215
|
+
* @inheritDoc
|
|
2216
|
+
*/
|
|
2217
|
+
handleAction(action, target) {
|
|
2218
|
+
const { functionType } = action;
|
|
2219
|
+
const functionBlock = this.getFunctionBlock(functionType);
|
|
2220
|
+
const emptyParagraph = this.createNewParagraph('');
|
|
2221
|
+
const referenceBlock = this.getReferenceBlock(target);
|
|
2222
|
+
if (referenceBlock) {
|
|
2223
|
+
referenceBlock.parent.apply(new InsertChildrenAfterAction(referenceBlock, functionBlock, emptyParagraph));
|
|
2224
|
+
}
|
|
2225
|
+
else {
|
|
2226
|
+
target.apply(new AppendChildrenAction([functionBlock, emptyParagraph]));
|
|
2227
|
+
}
|
|
2228
|
+
if (emptyParagraph) {
|
|
2229
|
+
action.nextFocusNode = emptyParagraph.children[0];
|
|
2230
|
+
}
|
|
2231
|
+
}
|
|
2232
|
+
/**
|
|
2233
|
+
* Get a function block based on the specified type.
|
|
2234
|
+
*
|
|
2235
|
+
* @param {string} type - The type of function block to create.
|
|
2236
|
+
* @returns {RTEFunctionBlock} The function block instance.
|
|
2237
|
+
*/
|
|
2238
|
+
getFunctionBlock(type) {
|
|
2239
|
+
const id = generateUUID();
|
|
2240
|
+
return RTEFunctionBlock.from({
|
|
2241
|
+
id: id,
|
|
2242
|
+
type: 'function-block',
|
|
2243
|
+
children: [
|
|
2244
|
+
{
|
|
2245
|
+
id: `${id}-1`,
|
|
2246
|
+
type: 'logic-control-block',
|
|
2247
|
+
statementText: type.toUpperCase(),
|
|
2248
|
+
},
|
|
2249
|
+
{
|
|
2250
|
+
id: `${id}-2`,
|
|
2251
|
+
annotations: {
|
|
2252
|
+
customClass: ['statementelement'],
|
|
2253
|
+
},
|
|
2254
|
+
type: 'paragraph',
|
|
2255
|
+
nodes: [
|
|
2256
|
+
{
|
|
2257
|
+
id: `${id}-2-1`,
|
|
2258
|
+
type: 'text',
|
|
2259
|
+
text: ' ',
|
|
2260
|
+
},
|
|
2261
|
+
],
|
|
2262
|
+
},
|
|
2263
|
+
{
|
|
2264
|
+
id: `${id}-3`,
|
|
2265
|
+
type: 'logic-control-block',
|
|
2266
|
+
statementText: 'SHOW',
|
|
2267
|
+
},
|
|
2268
|
+
{
|
|
2269
|
+
id: `${id}-4`,
|
|
2270
|
+
annotations: {
|
|
2271
|
+
customClass: ['statementelement'],
|
|
2272
|
+
},
|
|
2273
|
+
type: 'paragraph',
|
|
2274
|
+
nodes: [
|
|
2275
|
+
{
|
|
2276
|
+
id: `${id}-4-1`,
|
|
2277
|
+
type: 'text',
|
|
2278
|
+
text: ' ',
|
|
2279
|
+
},
|
|
2280
|
+
],
|
|
2281
|
+
},
|
|
2282
|
+
],
|
|
2283
|
+
});
|
|
2284
|
+
}
|
|
2285
|
+
/**
|
|
2286
|
+
* We need to get the correct block if the current target is a function block element to avoid nesting function blocks.
|
|
2287
|
+
*
|
|
2288
|
+
* @param {RTEBlock | VegaRTEContent} currentTarget - The current target block or content.
|
|
2289
|
+
* @returns {Nullable<RTEBlock>} The reference block.
|
|
2290
|
+
*/
|
|
2291
|
+
getReferenceBlock(currentTarget) {
|
|
2292
|
+
if (!(currentTarget instanceof VegaRTEContent)) {
|
|
2293
|
+
const parentBlock = currentTarget.parent;
|
|
2294
|
+
if (parentBlock instanceof RTEFunctionBlock) {
|
|
2295
|
+
return parentBlock;
|
|
2296
|
+
}
|
|
2297
|
+
else {
|
|
2298
|
+
return currentTarget;
|
|
2299
|
+
}
|
|
2300
|
+
}
|
|
2301
|
+
}
|
|
2302
|
+
}
|
|
2303
|
+
|
|
2304
|
+
/**
|
|
2305
|
+
* Class representing a logic control node in the rich text editor.
|
|
2306
|
+
*/
|
|
2307
|
+
class RTELogicControlNode extends RTENode {
|
|
2308
|
+
constructor(id, text, parent) {
|
|
2309
|
+
super(id);
|
|
2310
|
+
this.type = 'logic-control-node';
|
|
2311
|
+
this.text = '';
|
|
2312
|
+
this.text = text;
|
|
2313
|
+
this.parent = parent;
|
|
2314
|
+
}
|
|
2315
|
+
/**
|
|
2316
|
+
* Clone the current node instance.
|
|
2317
|
+
*
|
|
2318
|
+
* @returns {RTELogicControlNode} - A new instance of RTELogicControlNode.
|
|
2319
|
+
*/
|
|
2320
|
+
clone() {
|
|
2321
|
+
return new RTELogicControlNode(this.id, this.text, this.parent);
|
|
2322
|
+
}
|
|
2323
|
+
/**
|
|
2324
|
+
* Convert the node to its HTML representation.
|
|
2325
|
+
*
|
|
2326
|
+
* @returns {string} - The HTML string of the logic control node.
|
|
2327
|
+
*/
|
|
2328
|
+
toHtml() {
|
|
2329
|
+
return this.text;
|
|
2330
|
+
}
|
|
2331
|
+
/**
|
|
2332
|
+
* Convert the node to a JSON representation.
|
|
2333
|
+
*
|
|
2334
|
+
* @returns {unknown} - The JSON object of the statement syntax node.
|
|
2335
|
+
*/
|
|
2336
|
+
toJSON() {
|
|
2337
|
+
return {
|
|
2338
|
+
id: this.id,
|
|
2339
|
+
type: this.type,
|
|
2340
|
+
text: this.text,
|
|
2341
|
+
};
|
|
2342
|
+
}
|
|
2343
|
+
/**
|
|
2344
|
+
* Get the end offset of the node's range.
|
|
2345
|
+
*
|
|
2346
|
+
* @returns {number} - The end offset of the node's range.
|
|
2347
|
+
*/
|
|
2348
|
+
getRangeEndOffset() {
|
|
2349
|
+
return 1;
|
|
2350
|
+
}
|
|
2351
|
+
/**
|
|
2352
|
+
* Get the container element for the node's range.
|
|
2353
|
+
*
|
|
2354
|
+
* @returns {Nullable<Node>} - The container node for the range.
|
|
2355
|
+
*/
|
|
2356
|
+
getRangeContainer() {
|
|
2357
|
+
const element = stateEntityRenderingRegistry.getDOMByEntity(this);
|
|
2358
|
+
if (element) {
|
|
2359
|
+
return element.parentElement;
|
|
2360
|
+
}
|
|
2361
|
+
}
|
|
2362
|
+
/**
|
|
2363
|
+
* Get the content editable state of the node.
|
|
2364
|
+
*
|
|
2365
|
+
* @returns {boolean} - The content editable state of the node.
|
|
2366
|
+
*/
|
|
2367
|
+
isContentEditable() {
|
|
2368
|
+
return false;
|
|
2369
|
+
}
|
|
2370
|
+
}
|
|
2371
|
+
|
|
2372
|
+
/**
|
|
2373
|
+
* Class representing a logic control block in the rich text editor.
|
|
2374
|
+
*/
|
|
2375
|
+
class RTELogicControlBlock extends RTEBlock {
|
|
2376
|
+
constructor(id, statementText, parent) {
|
|
2377
|
+
super(id);
|
|
2378
|
+
this.type = 'logic-control-block';
|
|
2379
|
+
this.children = [];
|
|
2380
|
+
this.statementText = '';
|
|
2381
|
+
this.statementText = statementText;
|
|
2382
|
+
this.children = [new RTELogicControlNode(`${id}-node-1`, statementText, this)];
|
|
2383
|
+
if (parent) {
|
|
2384
|
+
this.parent = parent;
|
|
2385
|
+
}
|
|
2386
|
+
}
|
|
2387
|
+
/**
|
|
2388
|
+
* Create a logic control block from a JSON representation.
|
|
2389
|
+
*
|
|
2390
|
+
* @param {VegaRTELogicControlBlock} json - The JSON object representing the logic control block.
|
|
2391
|
+
* @returns {RTELogicControlBlock} - The created logic control block.
|
|
2392
|
+
*/
|
|
2393
|
+
static from(json) {
|
|
2394
|
+
const block = new RTELogicControlBlock(json.id, json.statementText);
|
|
2395
|
+
return block;
|
|
2396
|
+
}
|
|
2397
|
+
/**
|
|
2398
|
+
* Check the block is not empty.
|
|
2399
|
+
*
|
|
2400
|
+
* @returns {boolean} - Always true for logic control block.
|
|
2401
|
+
*/
|
|
2402
|
+
isNotEmpty() {
|
|
2403
|
+
return true;
|
|
2404
|
+
}
|
|
2405
|
+
/**
|
|
2406
|
+
* Get the last node of the block.
|
|
2407
|
+
*
|
|
2408
|
+
* @returns {RTELogicControlNode} - The last node in the block.
|
|
2409
|
+
*/
|
|
2410
|
+
getLastNode() {
|
|
2411
|
+
return this.children[this.children.length - 1];
|
|
2412
|
+
}
|
|
2413
|
+
/**
|
|
2414
|
+
* Convert the block to its HTML representation.
|
|
2415
|
+
*
|
|
2416
|
+
* @returns {string} - The HTML string of the logic control block.
|
|
2417
|
+
*/
|
|
2418
|
+
toHtml() {
|
|
2419
|
+
return `<div class='statementsyntax' contenteditable='false'>${this.statementText}</div>`;
|
|
2420
|
+
}
|
|
2421
|
+
/**
|
|
2422
|
+
* Clone the current block instance.
|
|
2423
|
+
*
|
|
2424
|
+
* @param { RTEFunctionBlock } parent - The parent function block for the cloned instance.
|
|
2425
|
+
* @returns {RTELogicControlBlock} - A new instance of RTEStatementSyntaxBlock.
|
|
2426
|
+
*/
|
|
2427
|
+
clone(parent) {
|
|
2428
|
+
return new RTELogicControlBlock(this.id, this.statementText, parent);
|
|
2429
|
+
}
|
|
2430
|
+
/**
|
|
2431
|
+
* Get the JSON representation of the block.
|
|
2432
|
+
*
|
|
2433
|
+
* @returns {VegaRTELogicControlBlock} - The JSON object of the logic control block.
|
|
2434
|
+
*/
|
|
2435
|
+
toJSON() {
|
|
2436
|
+
return {
|
|
2437
|
+
id: this.id,
|
|
2438
|
+
type: this.type,
|
|
2439
|
+
statementText: this.statementText,
|
|
2440
|
+
};
|
|
2441
|
+
}
|
|
2442
|
+
}
|
|
2443
|
+
|
|
2444
|
+
/**
|
|
2445
|
+
* Function toolbar button renderer class.
|
|
2446
|
+
*/
|
|
2447
|
+
class FunctionToolbarButtonRenderer extends VegaRTEToolbarButtonRenderer {
|
|
2448
|
+
/**
|
|
2449
|
+
* Injects the extension context
|
|
2450
|
+
*
|
|
2451
|
+
* @param {RTEExtensionContext} context - extension context
|
|
2452
|
+
*/
|
|
2453
|
+
injectExtensionContext(context) {
|
|
2454
|
+
this.extensionContext = context;
|
|
2455
|
+
}
|
|
2456
|
+
/**
|
|
2457
|
+
* @inheritDoc
|
|
2458
|
+
*/
|
|
2459
|
+
render(h, editorContext) {
|
|
2460
|
+
return this.renderDropdown(h, editorContext, {}, [
|
|
2461
|
+
this.renderButton(h, editorContext, {
|
|
2462
|
+
label: 'Functions',
|
|
2463
|
+
showArrowIcon: true,
|
|
2464
|
+
}),
|
|
2465
|
+
this.renderDropdownListTemplate(h, FunctionToolbarButtonRenderer.FUNCTION_LIST),
|
|
2466
|
+
]);
|
|
2467
|
+
}
|
|
2468
|
+
/**
|
|
2469
|
+
* Overrides the isDisabled method to determine if the button should be disabled.
|
|
2470
|
+
*
|
|
2471
|
+
* @returns {boolean} - true if the button should be disabled, false otherwise.
|
|
2472
|
+
*/
|
|
2473
|
+
isDisabled() {
|
|
2474
|
+
if (this.extensionContext) {
|
|
2475
|
+
const { host, getSelectedNodes } = this.extensionContext;
|
|
2476
|
+
const focusNode = getSelectedNodes()[0];
|
|
2477
|
+
let enableInsert = true;
|
|
2478
|
+
if (focusNode) {
|
|
2479
|
+
enableInsert = ActionHandleStrategyRegistry.canHandle(INSERT_FUNCTION_BLOCK, focusNode.parent);
|
|
2480
|
+
}
|
|
2481
|
+
return host.disabled || !enableInsert;
|
|
2482
|
+
}
|
|
2483
|
+
return false;
|
|
2484
|
+
}
|
|
2485
|
+
/* istanbul ignore next */
|
|
2486
|
+
// eslint-disable-next-line jsdoc/require-jsdoc
|
|
2487
|
+
handleButtonClick() {
|
|
2488
|
+
throw new Error('Method not implemented.');
|
|
2489
|
+
}
|
|
2490
|
+
/**
|
|
2491
|
+
* Handles dropdown click event
|
|
2492
|
+
*
|
|
2493
|
+
* @param {RTEExtensionFunctionType} itemKey - key of the clicked item
|
|
2494
|
+
*/
|
|
2495
|
+
handleDropdownClick(itemKey) {
|
|
2496
|
+
const { host, getSelectedNodes } = this.extensionContext;
|
|
2497
|
+
const focusNode = getSelectedNodes()[0];
|
|
2498
|
+
const action = new InsertFunctionBlockAction(itemKey);
|
|
2499
|
+
if (!focusNode) {
|
|
2500
|
+
host.value.apply(action);
|
|
2501
|
+
}
|
|
2502
|
+
else if (focusNode.parent) {
|
|
2503
|
+
focusNode.parent.apply(action);
|
|
2504
|
+
}
|
|
2505
|
+
if (action.nextFocusNode) {
|
|
2506
|
+
host.value.apply(new UpdateCursorPositionAction(action.nextFocusNode, 1));
|
|
2507
|
+
}
|
|
2508
|
+
}
|
|
2509
|
+
}
|
|
2510
|
+
FunctionToolbarButtonRenderer.FUNCTION_LIST = [
|
|
2511
|
+
{ key: 'IF', label: 'Conditional' },
|
|
2512
|
+
{ key: 'FOREACH', label: 'Foreach' },
|
|
2513
|
+
];
|
|
2514
|
+
|
|
2515
|
+
/**
|
|
2516
|
+
* Renders a logic control block in the rich text editor.
|
|
2517
|
+
*/
|
|
2518
|
+
class RTELogicControlBlockRenderer extends VegaRTEExtensionRenderer {
|
|
2519
|
+
/**
|
|
2520
|
+
* @inheritDoc
|
|
2521
|
+
*/
|
|
2522
|
+
doRender(h, renderData) {
|
|
2523
|
+
return h('div', {
|
|
2524
|
+
key: renderData.id,
|
|
2525
|
+
class: 'statementsyntax',
|
|
2526
|
+
ref: this.useRef(renderData),
|
|
2527
|
+
}, h('span', {
|
|
2528
|
+
key: `${renderData.id}-1`,
|
|
2529
|
+
contenteditable: 'false',
|
|
2530
|
+
ref: this.useRef(renderData.children[0]),
|
|
2531
|
+
}, renderData.statementText));
|
|
2532
|
+
}
|
|
2533
|
+
}
|
|
2534
|
+
|
|
2535
|
+
/**
|
|
2536
|
+
* Strategy to convert a div with class 'statementsyntax' into an RTELogicControlBlock DTO.
|
|
2537
|
+
*/
|
|
2538
|
+
class DivToLogicControlBlockStrategy extends BlockToRTEBlockStrategyAbstract {
|
|
2539
|
+
constructor() {
|
|
2540
|
+
super(...arguments);
|
|
2541
|
+
this.blockClassName = 'statementsyntax';
|
|
2542
|
+
}
|
|
2543
|
+
/**
|
|
2544
|
+
* @inheritDoc
|
|
2545
|
+
*/
|
|
2546
|
+
canHandle(elementsArray, currentIndex) {
|
|
2547
|
+
const element = elementsArray[currentIndex];
|
|
2548
|
+
return element &&
|
|
2549
|
+
element.nodeType === Node.ELEMENT_NODE &&
|
|
2550
|
+
element.classList.contains(this.blockClassName) &&
|
|
2551
|
+
this.isFunctionBlockChild(element)
|
|
2552
|
+
? 1
|
|
2553
|
+
: 0;
|
|
2554
|
+
}
|
|
2555
|
+
/**
|
|
2556
|
+
* @inheritDoc
|
|
2557
|
+
*/
|
|
2558
|
+
handle(elementsArray) {
|
|
2559
|
+
const element = elementsArray[0];
|
|
2560
|
+
return RTELogicControlBlock.from({
|
|
2561
|
+
id: generateUUID(),
|
|
2562
|
+
type: 'logic-control-block',
|
|
2563
|
+
statementText: element.innerText,
|
|
2564
|
+
});
|
|
2565
|
+
}
|
|
2566
|
+
/**
|
|
2567
|
+
* The logic control block does not have child blocks to append. so this method is intentionally left empty.
|
|
2568
|
+
*/
|
|
2569
|
+
// eslint-disable-next-line @typescript-eslint/no-empty-function
|
|
2570
|
+
appendChildBlocks() { }
|
|
2571
|
+
/**
|
|
2572
|
+
* @inheritDoc
|
|
2573
|
+
*/
|
|
2574
|
+
shouldProceedToElementChildren() {
|
|
2575
|
+
return false;
|
|
2576
|
+
}
|
|
2577
|
+
/**
|
|
2578
|
+
* Checks if the given element is a child of a function block
|
|
2579
|
+
*
|
|
2580
|
+
* @param {HTMLElement} element - The HTML element to check
|
|
2581
|
+
* @returns {boolean} True if the element is a child of a function block, false otherwise
|
|
2582
|
+
*/
|
|
2583
|
+
isFunctionBlockChild(element) {
|
|
2584
|
+
return !!(element.parentElement && element.parentElement.classList.contains('statement'));
|
|
2585
|
+
}
|
|
2586
|
+
}
|
|
2587
|
+
|
|
2588
|
+
/**
|
|
2589
|
+
* Strategy to convert a div with class 'statement' into an function block.
|
|
2590
|
+
*/
|
|
2591
|
+
class DivToFunctionBlockStrategy extends ElementToDTOStrategy {
|
|
2592
|
+
/**
|
|
2593
|
+
* @inheritDoc
|
|
2594
|
+
*/
|
|
2595
|
+
canHandle(elementsArray, currentIndex) {
|
|
2596
|
+
const element = elementsArray[currentIndex];
|
|
2597
|
+
return element &&
|
|
2598
|
+
element.tagName === 'DIV' &&
|
|
2599
|
+
element.classList.contains('statement') &&
|
|
2600
|
+
element.childNodes.length &&
|
|
2601
|
+
element.querySelector('.statementsyntax')
|
|
2602
|
+
? 1
|
|
2603
|
+
: 0;
|
|
2604
|
+
}
|
|
2605
|
+
/**
|
|
2606
|
+
* @inheritDoc
|
|
2607
|
+
*/
|
|
2608
|
+
handle() {
|
|
2609
|
+
return RTEFunctionBlock.from({
|
|
2610
|
+
id: generateUUID(),
|
|
2611
|
+
type: 'function-block',
|
|
2612
|
+
annotations: {
|
|
2613
|
+
customClass: ['statement'],
|
|
2614
|
+
},
|
|
2615
|
+
children: [],
|
|
2616
|
+
});
|
|
2617
|
+
}
|
|
2618
|
+
/**
|
|
2619
|
+
* @inheritDoc
|
|
2620
|
+
*/
|
|
2621
|
+
appendChildBlocks(currentBlock, childBlocks) {
|
|
2622
|
+
currentBlock.children = childBlocks.map((block) => {
|
|
2623
|
+
block.parent = currentBlock;
|
|
2624
|
+
return block;
|
|
2625
|
+
});
|
|
2626
|
+
}
|
|
2627
|
+
/**
|
|
2628
|
+
* @inheritDoc
|
|
2629
|
+
*/
|
|
2630
|
+
shouldProceedToElementChildren() {
|
|
2631
|
+
return true;
|
|
2632
|
+
}
|
|
2633
|
+
}
|
|
2634
|
+
|
|
2635
|
+
/**
|
|
2636
|
+
* Strategy to convert a div with class 'statementelement' into an function block.
|
|
2637
|
+
*/
|
|
2638
|
+
class DivToFunctionContentStrategy extends DivToLogicControlBlockStrategy {
|
|
2639
|
+
constructor() {
|
|
2640
|
+
super(...arguments);
|
|
2641
|
+
this.blockClassName = 'statementelement';
|
|
2642
|
+
}
|
|
2643
|
+
/**
|
|
2644
|
+
* @inheritDoc
|
|
2645
|
+
*/
|
|
2646
|
+
handle(elementsArray, options) {
|
|
2647
|
+
const element = elementsArray[0];
|
|
2648
|
+
const annotations = htmlElementToAnnotationGenerator.generate(RTETextBlock, element);
|
|
2649
|
+
const nodes = Array.from(elementsArray[0].childNodes);
|
|
2650
|
+
return RTETextBlock.from({
|
|
2651
|
+
id: generateUUID(),
|
|
2652
|
+
type: 'paragraph',
|
|
2653
|
+
annotations: Object.assign({ customClass: [this.blockClassName] }, annotations),
|
|
2654
|
+
nodes: this.generateChildNodes(nodes, undefined, options),
|
|
2655
|
+
});
|
|
2656
|
+
}
|
|
2657
|
+
}
|
|
2658
|
+
|
|
2659
|
+
const functionBlockStylesCss = "div.statement{padding:2px 4px;background:rgba(var(--v-bg-accent3-secondary, 255, 239, 200));border:1px solid rgba(var(--v-bg-accent3-primary, 255, 220, 131));border-radius:4px;display:flex;flex-direction:row;justify-content:flex-start;align-items:stretch;gap:4px}div.statement .statementsyntax{padding:3px 0;line-height:22px}.rich-text-content div.statement .statementsyntax,.rich-text-content div.statement .statementelement{display:inline-block}div.statement+div.statement{margin-top:2px}div.statement .statementsyntax span{color:rgb(38, 42, 255);font-weight:bold}div.statement .statementelement{padding:2px 4px;background:rgba(var(--v-bg-secondary, 245, 247, 247));border:1px solid rgba(var(--v-border-color-input-field, 171, 198, 216));border-radius:4px;margin:0;min-width:8px}";
|
|
2660
|
+
|
|
2661
|
+
/**
|
|
2662
|
+
* Renderer for Function Block
|
|
2663
|
+
*/
|
|
2664
|
+
class RTEFunctionBlockRenderer extends VegaRTEExtensionRenderer {
|
|
2665
|
+
/**
|
|
2666
|
+
* @inheritDoc
|
|
2667
|
+
*/
|
|
2668
|
+
doRender(createElement, renderData) {
|
|
2669
|
+
return createElement('div', {
|
|
2670
|
+
key: renderData.id,
|
|
2671
|
+
class: this.getElementClassName(renderData),
|
|
2672
|
+
ref: this.useRef(renderData),
|
|
2673
|
+
});
|
|
2674
|
+
}
|
|
2675
|
+
/**
|
|
2676
|
+
* Defines the function block styles to be injected into the RTE scope.
|
|
2677
|
+
*
|
|
2678
|
+
* @returns {string} - The styles as a string.
|
|
2679
|
+
*/
|
|
2680
|
+
injectRTEScopeStyles() {
|
|
2681
|
+
return functionBlockStylesCss;
|
|
2682
|
+
}
|
|
2683
|
+
/**
|
|
2684
|
+
* Gets the class name for the function block element.
|
|
2685
|
+
*
|
|
2686
|
+
* @param {RTEFunctionBlock} block - The function block.
|
|
2687
|
+
* @returns {string} The class name for the function block element.
|
|
2688
|
+
*/
|
|
2689
|
+
getElementClassName(block) {
|
|
2690
|
+
let classes = block.getClasses();
|
|
2691
|
+
if (classes.indexOf('statement') < 0) {
|
|
2692
|
+
classes = 'statement ' + classes;
|
|
2693
|
+
}
|
|
2694
|
+
return classes.trim();
|
|
2695
|
+
}
|
|
2696
|
+
}
|
|
2697
|
+
|
|
2698
|
+
/**
|
|
2699
|
+
* Abstract class for action handler interceptors, which can intercept actions before they are handled.
|
|
2700
|
+
*/
|
|
2701
|
+
class ActionHandlerInterceptor {
|
|
2702
|
+
}
|
|
2703
|
+
|
|
2704
|
+
/**
|
|
2705
|
+
* Prevent special type input in function block.
|
|
2706
|
+
*/
|
|
2707
|
+
class PreventNewParagraphInterceptor extends ActionHandlerInterceptor {
|
|
2708
|
+
/**
|
|
2709
|
+
* Checks the target block parent whether is function block.
|
|
2710
|
+
*
|
|
2711
|
+
* @param {InsertNewParagraphAction} _action - the action to be intercepted
|
|
2712
|
+
* @param {RTETextBlock} target - the target block
|
|
2713
|
+
* @returns {boolean} - true if the target block parent is function block, false otherwise
|
|
2714
|
+
*/
|
|
2715
|
+
canIntercept(_action, target) {
|
|
2716
|
+
return target.parent && target.parent instanceof RTEFunctionBlock;
|
|
2717
|
+
}
|
|
2718
|
+
/**
|
|
2719
|
+
* Insert a new paragraph behind of the function block instead of the target block.
|
|
2720
|
+
*
|
|
2721
|
+
* @param {ActionHandlerExecution} _execution - the original execution function
|
|
2722
|
+
* @param {ModifyContentAction} _action - the action to be intercepted
|
|
2723
|
+
* @param {RTETextBlock} target - the target block
|
|
2724
|
+
*/
|
|
2725
|
+
intercept(_execution, _action, target) {
|
|
2726
|
+
const insertParagraphAction = new InsertNewParagraphAction(target.children[0], 0);
|
|
2727
|
+
insertParagraphAction.isFlushable = true;
|
|
2728
|
+
target.parent.apply(insertParagraphAction);
|
|
2729
|
+
}
|
|
2730
|
+
}
|
|
2731
|
+
|
|
2732
|
+
/**
|
|
2733
|
+
* Insert a new paragraph behind of current function block strategy.
|
|
2734
|
+
*/
|
|
2735
|
+
class FunctionBlockInsertParagraphStrategy extends ActionHandleStrategy {
|
|
2736
|
+
/**
|
|
2737
|
+
* @inheritDoc
|
|
2738
|
+
*/
|
|
2739
|
+
handleAction(action, target) {
|
|
2740
|
+
const newParagraph = this.createNewParagraph('');
|
|
2741
|
+
if (newParagraph) {
|
|
2742
|
+
target.parent.apply(new InsertChildrenAfterAction(target, newParagraph));
|
|
2743
|
+
action.newBlock = newParagraph;
|
|
2744
|
+
this.focusToNextLine(newParagraph);
|
|
2745
|
+
}
|
|
2746
|
+
}
|
|
2747
|
+
/**
|
|
2748
|
+
* Focus to next paragraph.
|
|
2749
|
+
*
|
|
2750
|
+
* @param {RTETextBlock} block - The paragraph need to focus.
|
|
2751
|
+
*/
|
|
2752
|
+
focusToNextLine(block) {
|
|
2753
|
+
const root = this.getRootContent(block);
|
|
2754
|
+
if (root) {
|
|
2755
|
+
root.apply(new UpdateCursorPositionAction(block.children[0], 1));
|
|
2756
|
+
}
|
|
2757
|
+
}
|
|
2758
|
+
}
|
|
2759
|
+
|
|
2760
|
+
const PASTE_PLAIN_TEXT = 'PASTE_PLAIN_TEXT';
|
|
2761
|
+
/**
|
|
2762
|
+
* Action to paste plain text content into function block.
|
|
2763
|
+
*
|
|
2764
|
+
* @example functionBlock.apply(new PastePlainTextAction('content', range))
|
|
2765
|
+
* @example host.value.apply(new PastePlainTextAction('content', range))
|
|
2766
|
+
*/
|
|
2767
|
+
class PastePlainTextAction extends ModifyContentAction {
|
|
2768
|
+
constructor(blocksToBeInserted, startNode, startOffset) {
|
|
2769
|
+
super();
|
|
2770
|
+
this.type = PASTE_PLAIN_TEXT;
|
|
2771
|
+
this.blocksToBeInserted = blocksToBeInserted;
|
|
2772
|
+
this.startNode = startNode;
|
|
2773
|
+
this.startOffset = startOffset;
|
|
2774
|
+
}
|
|
2775
|
+
}
|
|
2776
|
+
|
|
2777
|
+
/**
|
|
2778
|
+
* Prevent special type input in function block.
|
|
2779
|
+
*/
|
|
2780
|
+
class PreventPasteContentInterceptor extends PreventNewParagraphInterceptor {
|
|
2781
|
+
/**
|
|
2782
|
+
* Paste plain text into text block.
|
|
2783
|
+
*
|
|
2784
|
+
* @param {ActionHandlerExecution} _execution - the original execution function
|
|
2785
|
+
* @param {ModifyContentAction} action - the action to be intercepted
|
|
2786
|
+
* @param {RTETextBlock} target - the target block
|
|
2787
|
+
*/
|
|
2788
|
+
intercept(_execution, action, target) {
|
|
2789
|
+
const { blocksToBeInserted, rteRange } = action;
|
|
2790
|
+
let { startNode, startOffset } = action;
|
|
2791
|
+
// Set the start offset from rteRange if available, this is to handle the paste issue https://gethired.atlassian.net/browse/VD-7779
|
|
2792
|
+
if (rteRange) {
|
|
2793
|
+
startNode = rteRange.startNode;
|
|
2794
|
+
startOffset = rteRange.startOffset;
|
|
2795
|
+
}
|
|
2796
|
+
const pastePlainTextAction = new PastePlainTextAction(blocksToBeInserted, startNode, startOffset);
|
|
2797
|
+
target.apply(pastePlainTextAction);
|
|
2798
|
+
}
|
|
2799
|
+
}
|
|
2800
|
+
|
|
2801
|
+
/**
|
|
2802
|
+
* Strategy to handle the paste content into function block.
|
|
2803
|
+
*/
|
|
2804
|
+
class PastePlainTextStrategy extends ActionHandleStrategy {
|
|
2805
|
+
/**
|
|
2806
|
+
* @inheritDoc
|
|
2807
|
+
*/
|
|
2808
|
+
handleAction(action, target) {
|
|
2809
|
+
const { blocksToBeInserted, startNode, startOffset } = action;
|
|
2810
|
+
if (startNode instanceof RTETextNode) {
|
|
2811
|
+
const textNodes = blocksToBeInserted.flatMap((block) => {
|
|
2812
|
+
if (block instanceof RTETextBlock) {
|
|
2813
|
+
this.copyLinkGroupAnnotations(target.annotationMap, block.annotationMap);
|
|
2814
|
+
return block.children;
|
|
2815
|
+
}
|
|
2816
|
+
return [];
|
|
2817
|
+
});
|
|
2818
|
+
if (textNodes.length > 0) {
|
|
2819
|
+
if (startOffset > 0) {
|
|
2820
|
+
target.apply(new InsertChildrenAfterAction(startNode, ...textNodes));
|
|
2821
|
+
}
|
|
2822
|
+
else {
|
|
2823
|
+
target.apply(new InsertChildrenBeforeAction(startNode, ...textNodes));
|
|
2824
|
+
}
|
|
2825
|
+
this.focusToNextLine(textNodes[textNodes.length - 1], textNodes[textNodes.length - 1].getRangeEndOffset());
|
|
2826
|
+
}
|
|
2827
|
+
}
|
|
2828
|
+
}
|
|
2829
|
+
/**
|
|
2830
|
+
* Focus to next paragraph.
|
|
2831
|
+
*
|
|
2832
|
+
* @param {RTETextNode} node - The text node need to focus.
|
|
2833
|
+
* @param {number} startOffset - The offset need to focus.
|
|
2834
|
+
*/
|
|
2835
|
+
focusToNextLine(node, startOffset) {
|
|
2836
|
+
const root = this.getRootContent(node);
|
|
2837
|
+
if (root) {
|
|
2838
|
+
root.apply(new UpdateCursorPositionAction(node, startOffset));
|
|
2839
|
+
}
|
|
2840
|
+
}
|
|
2841
|
+
/**
|
|
2842
|
+
* Copy link group annotations from copied block to target block.
|
|
2843
|
+
*
|
|
2844
|
+
* @param {BlockAnnotations} blockAnnotationMap - The target block annotation map.
|
|
2845
|
+
* @param {BlockAnnotations} copiedAnnotationMap - The copied block annotation map.
|
|
2846
|
+
*/
|
|
2847
|
+
copyLinkGroupAnnotations(blockAnnotationMap, copiedAnnotationMap) {
|
|
2848
|
+
if (copiedAnnotationMap && copiedAnnotationMap.has(InternalAnnotationTypeEnum.LINK_GROUP)) {
|
|
2849
|
+
const copiedLinkGroupAnnotation = copiedAnnotationMap.get(InternalAnnotationTypeEnum.LINK_GROUP);
|
|
2850
|
+
if (!blockAnnotationMap.has(InternalAnnotationTypeEnum.LINK_GROUP)) {
|
|
2851
|
+
blockAnnotationMap.set(InternalAnnotationTypeEnum.LINK_GROUP, copiedAnnotationMap.get(InternalAnnotationTypeEnum.LINK_GROUP));
|
|
2852
|
+
}
|
|
2853
|
+
else {
|
|
2854
|
+
copiedLinkGroupAnnotation.linkGroups.forEach((nodes, groupKey) => {
|
|
2855
|
+
const existingAnnotation = blockAnnotationMap.get(InternalAnnotationTypeEnum.LINK_GROUP);
|
|
2856
|
+
existingAnnotation.linkGroups.set(groupKey, nodes);
|
|
2857
|
+
});
|
|
2858
|
+
}
|
|
2859
|
+
}
|
|
2860
|
+
}
|
|
2861
|
+
}
|
|
2862
|
+
|
|
2863
|
+
const convertLogicControlBlockStrategy = new DivToLogicControlBlockStrategy();
|
|
2864
|
+
const convertFunctionContentStrategy = new DivToFunctionContentStrategy();
|
|
2865
|
+
const convertFunctionBlockStrategy = new DivToFunctionBlockStrategy();
|
|
2866
|
+
/**
|
|
2867
|
+
* Function extension class for Vega Rich Text Editor.
|
|
2868
|
+
*/
|
|
2869
|
+
class VegaRTEFunctionExtension extends VegaRTEExtension {
|
|
2870
|
+
constructor() {
|
|
2871
|
+
super();
|
|
2872
|
+
this.toolbarButtonRenderer = new FunctionToolbarButtonRenderer();
|
|
2873
|
+
this.registerBlockBasicStrategies(RTELogicControlBlock.name);
|
|
2874
|
+
this.registerBlockBasicStrategies(RTEFunctionBlock.name);
|
|
2875
|
+
this.preventFunctionBlockDefaultInsertNewParagraph();
|
|
2876
|
+
this.registerNode('logic-control-block', RTELogicControlBlock);
|
|
2877
|
+
this.registerRenderer('logic-control-block', new RTELogicControlBlockRenderer());
|
|
2878
|
+
this.registerNode('function-block', RTEFunctionBlock);
|
|
2879
|
+
this.registerRenderer('function-block', new RTEFunctionBlockRenderer());
|
|
2880
|
+
this.registerToolbarButtonRenderer('functions', this.toolbarButtonRenderer);
|
|
2881
|
+
this.registerElementToBlockDTOClassStrategy(convertLogicControlBlockStrategy);
|
|
2882
|
+
this.registerElementToBlockDTOClassStrategy(convertFunctionContentStrategy);
|
|
2883
|
+
this.registerElementToBlockDTOClassStrategy(convertFunctionBlockStrategy);
|
|
2884
|
+
}
|
|
2885
|
+
/**
|
|
2886
|
+
* Initializes the extension with the given context
|
|
2887
|
+
*
|
|
2888
|
+
* @param {RTEExtensionContext} context - extension context
|
|
2889
|
+
*/
|
|
2890
|
+
initialExtension(context) {
|
|
2891
|
+
super.initialExtension(context);
|
|
2892
|
+
if (this.toolbarButtonRenderer) {
|
|
2893
|
+
this.toolbarButtonRenderer.injectExtensionContext(context);
|
|
2894
|
+
}
|
|
2895
|
+
}
|
|
2896
|
+
/**
|
|
2897
|
+
* Remove the appen children strategies to prevent default insert new paragraph logic in function block
|
|
2898
|
+
*/
|
|
2899
|
+
preventFunctionBlockDefaultInsertNewParagraph() {
|
|
2900
|
+
this.unRegisterStrategy(ModifyContentActionType.INSERT_NEW_PARAGRAPH, RTELogicControlBlock.name);
|
|
2901
|
+
this.unRegisterStrategy(ModifyContentActionType.APPEND_CHILDREN, RTEFunctionBlock.name);
|
|
2902
|
+
this.unRegisterStrategy(ModifyContentActionType.INSERT_CHILDREN_AFTER, RTEFunctionBlock.name);
|
|
2903
|
+
this.unRegisterStrategy(ModifyContentActionType.INSERT_CHILDREN_BEFORE, RTEFunctionBlock.name);
|
|
2904
|
+
this.unRegisterStrategy(ModifyContentActionType.PASTE_CONTENT, RTELogicControlBlock.name);
|
|
2905
|
+
VegaRTEExtension.registerActionHandleStrategy(RTEFunctionBlock.name, ModifyContentActionType.INSERT_NEW_PARAGRAPH, new FunctionBlockInsertParagraphStrategy());
|
|
2906
|
+
}
|
|
2907
|
+
}
|
|
2908
|
+
(() => {
|
|
2909
|
+
const insertFunctionBlockStrategy = new InsertFunctionBlockStrategy();
|
|
2910
|
+
VegaRTEExtension.registerActionHandleStrategy(VegaRTEContent.name, INSERT_FUNCTION_BLOCK, insertFunctionBlockStrategy);
|
|
2911
|
+
VegaRTEExtension.registerActionHandleStrategy(RTETextBlock.name, INSERT_FUNCTION_BLOCK, insertFunctionBlockStrategy);
|
|
2912
|
+
VegaRTEExtension.registerActionHandleStrategy(RTEImageBlock.name, INSERT_FUNCTION_BLOCK, insertFunctionBlockStrategy);
|
|
2913
|
+
VegaRTEExtension.registerActionHandleStrategy(RTELogicControlBlock.name, INSERT_FUNCTION_BLOCK, insertFunctionBlockStrategy);
|
|
2914
|
+
VegaRTEExtension.registerActionHandleStrategy(RTETextBlock.name, PASTE_PLAIN_TEXT, new PastePlainTextStrategy());
|
|
2915
|
+
VegaRTEExtension.registerActionHandlerInterceptor(RTETextBlock.name, ModifyContentActionType.INSERT_NEW_PARAGRAPH, new PreventNewParagraphInterceptor());
|
|
2916
|
+
VegaRTEExtension.registerActionHandlerInterceptor(RTETextBlock.name, ModifyContentActionType.PASTE_CONTENT, new PreventPasteContentInterceptor());
|
|
2917
|
+
})();
|
|
2918
|
+
|
|
2919
|
+
const tableBlockStylesCss = ".v-rte--extension-table-container{display:table}table.v-rte--extension-table{border-collapse:collapse}table.v-rte--extension-table th,table.v-rte--extension-table td{border:1px solid #ddd;padding:12px;text-align:left;vertical-align:middle;min-width:30px;position:relative}table.v-rte--extension-table th{background-color:#f2f2f2}.rte-table-setting-popover,.rte-table-dynamic-popover{display:block}table.v-rte--extension-table .v-rte-table-cell-focused::after,table.v-rte--extension-table .v-rte-table-cell-selected::after{content:'';position:absolute;top:0;left:0;right:0;bottom:0;pointer-events:none;background-color:rgba(158, 207, 250, 0.3)}table.v-rte--extension-table:has(.v-rte-table-cell-selected){caret-color:transparent}table.v-rte--extension-table:has(.v-rte-table-cell-selected) ::selection{background-color:transparent}table.v-rte--extension-table:has(.v-rte-table-cell-selected) ::-moz-selection{background-color:transparent}.v-rte--extension-table-caption{padding:8px;border:1px solid #ddd;border-bottom:none;background-color:#f7f7f7;position:relative;display:table-caption;caption-side:top;min-height:22px;text-align:center;word-break:break-word;overflow-wrap:break-word}.v-rte--extension-table-caption.showPlaceholder::before{position:absolute;left:0;right:0;content:attr(data-placeholder);font-family:'Inter', sans-serif;font-size:16px;font-weight:400;line-height:24px;letter-spacing:0;color:rgba(var(--v-text-input-placeholder, 176, 180, 181, 1));text-align:center;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.rte-cell-properties-popover,.rte-table-properties-popover{display:none}";
|
|
2920
|
+
|
|
2921
|
+
const DELETE_TABLE_BLOCK = 'DELETE_TABLE_BLOCK';
|
|
2922
|
+
/**
|
|
2923
|
+
* Action to delete a table block
|
|
2924
|
+
*/
|
|
2925
|
+
class DeleteTableBlockAction extends ModifyContentAction {
|
|
2926
|
+
constructor(target) {
|
|
2927
|
+
super();
|
|
2928
|
+
this.isFlushable = true;
|
|
2929
|
+
this.type = DELETE_TABLE_BLOCK;
|
|
2930
|
+
this.tableBlock = target;
|
|
2931
|
+
}
|
|
2932
|
+
}
|
|
2933
|
+
|
|
2934
|
+
/**
|
|
2935
|
+
* Class representing a table caption annotation in the rich text editor.
|
|
2936
|
+
*/
|
|
2937
|
+
class RTETableCaptionAnnotation extends BlockAnnotation {
|
|
2938
|
+
constructor() {
|
|
2939
|
+
super(...arguments);
|
|
2940
|
+
this.type = RTETableExtensionAnnotationTypeEnum.CAPTION;
|
|
2941
|
+
}
|
|
2942
|
+
/**
|
|
2943
|
+
* @inheritDoc
|
|
2944
|
+
*/
|
|
2945
|
+
clone() {
|
|
2946
|
+
return new RTETableCaptionAnnotation();
|
|
2947
|
+
}
|
|
2948
|
+
/**
|
|
2949
|
+
* @inheritDoc
|
|
2950
|
+
*/
|
|
2951
|
+
renderClass(options) {
|
|
2952
|
+
if (options === null || options === void 0 ? void 0 : options.standalone)
|
|
2953
|
+
return null;
|
|
2954
|
+
return 'v-rte--extension-table-caption';
|
|
2955
|
+
}
|
|
2956
|
+
/**
|
|
2957
|
+
* @inheritDoc
|
|
2958
|
+
*/
|
|
2959
|
+
renderStyle(options) {
|
|
2960
|
+
if (!(options === null || options === void 0 ? void 0 : options.standalone))
|
|
2961
|
+
return null;
|
|
2962
|
+
return {
|
|
2963
|
+
padding: '8px',
|
|
2964
|
+
border: '1px solid #ddd',
|
|
2965
|
+
borderBottom: 'none',
|
|
2966
|
+
backgroundColor: '#f7f7f7',
|
|
2967
|
+
position: 'relative',
|
|
2968
|
+
textAlign: 'center',
|
|
2969
|
+
minHeight: '22px',
|
|
2970
|
+
};
|
|
2971
|
+
}
|
|
2972
|
+
/**
|
|
2973
|
+
* @inheritDoc
|
|
2974
|
+
*/
|
|
2975
|
+
toJSON() {
|
|
2976
|
+
return {
|
|
2977
|
+
caption: {
|
|
2978
|
+
padding: '8px 12px',
|
|
2979
|
+
border: '1px solid #ddd',
|
|
2980
|
+
borderBottom: 'none',
|
|
2981
|
+
backgroundColor: '#f7f7f7',
|
|
2982
|
+
position: 'relative',
|
|
2983
|
+
textAlign: 'center',
|
|
2984
|
+
minHeight: '22px',
|
|
2985
|
+
},
|
|
2986
|
+
};
|
|
2987
|
+
}
|
|
2988
|
+
}
|
|
2989
|
+
|
|
2990
|
+
/**
|
|
2991
|
+
* Represents the optional caption block for a table.
|
|
2992
|
+
*/
|
|
2993
|
+
class RTETableCaptionBlock extends RTEBlock {
|
|
2994
|
+
constructor(id) {
|
|
2995
|
+
super(id);
|
|
2996
|
+
this.type = 'table-caption';
|
|
2997
|
+
this.annotationMap.set(RTETableExtensionAnnotationTypeEnum.CAPTION, new RTETableCaptionAnnotation());
|
|
2998
|
+
}
|
|
2999
|
+
/**
|
|
3000
|
+
* @inheritDoc
|
|
3001
|
+
*/
|
|
3002
|
+
static from(block, options) {
|
|
3003
|
+
const captionBlock = new RTETableCaptionBlock(block.id);
|
|
3004
|
+
super.convertAnnotationsToMap(captionBlock.annotationMap, Object.assign({}, block.annotations));
|
|
3005
|
+
captionBlock.children = super.generateBlockChildren(block.children, options, captionBlock);
|
|
3006
|
+
return captionBlock;
|
|
3007
|
+
}
|
|
3008
|
+
/**
|
|
3009
|
+
* @inheritDoc
|
|
3010
|
+
*/
|
|
3011
|
+
clone(parent) {
|
|
3012
|
+
const clonedBlock = new RTETableCaptionBlock(this.id);
|
|
3013
|
+
clonedBlock.children = this.children.map((child) => child.clone(clonedBlock));
|
|
3014
|
+
clonedBlock.parent = parent;
|
|
3015
|
+
return clonedBlock;
|
|
3016
|
+
}
|
|
3017
|
+
/**
|
|
3018
|
+
* @inheritDoc
|
|
3019
|
+
*/
|
|
3020
|
+
getLastNode() {
|
|
3021
|
+
return this.children[this.children.length - 1].getLastNode();
|
|
3022
|
+
}
|
|
3023
|
+
/**
|
|
3024
|
+
* @inheritDoc
|
|
3025
|
+
*/
|
|
3026
|
+
isNotEmpty() {
|
|
3027
|
+
return this.children.length > 0 && this.children.some((child) => child.isNotEmpty());
|
|
3028
|
+
}
|
|
3029
|
+
/**
|
|
3030
|
+
* @inheritDoc
|
|
3031
|
+
*/
|
|
3032
|
+
toHtml() {
|
|
3033
|
+
const childrenHtml = this.children.map((child) => child.toHtml()).join('');
|
|
3034
|
+
const attrStr = super.generateAttributeString();
|
|
3035
|
+
return `<caption${attrStr}>${childrenHtml}</caption>`;
|
|
3036
|
+
}
|
|
3037
|
+
/**
|
|
3038
|
+
* @inheritDoc
|
|
3039
|
+
*/
|
|
3040
|
+
toJSON() {
|
|
3041
|
+
return Object.assign(Object.assign({}, super.toJSON()), { type: this.type, children: this.children.map((child) => child.toJSON()) });
|
|
3042
|
+
}
|
|
3043
|
+
}
|
|
3044
|
+
(() => {
|
|
3045
|
+
ActionHandleStrategyRegistry.register(ModifyContentActionType.INSERT_CHILDREN_BEFORE, RTETableCaptionBlock.name, new InsertChildrenBeforeStrategy());
|
|
3046
|
+
ActionHandleStrategyRegistry.register(ModifyContentActionType.PASTE_CONTENT, RTETableCaptionBlock.name, new PasteContentStrategy());
|
|
3047
|
+
})();
|
|
3048
|
+
|
|
3049
|
+
const TOGGLE_TABLE_CAPTION = 'TOGGLE_TABLE_CAPTION';
|
|
3050
|
+
/**
|
|
3051
|
+
* Action payload for toggling the optional table caption block.
|
|
3052
|
+
*/
|
|
3053
|
+
class TableCaptionAction extends ModifyContentAction {
|
|
3054
|
+
constructor(shouldEnable) {
|
|
3055
|
+
super();
|
|
3056
|
+
this.type = TOGGLE_TABLE_CAPTION;
|
|
3057
|
+
this.isFlushable = true;
|
|
3058
|
+
this.shouldEnable = shouldEnable;
|
|
3059
|
+
}
|
|
3060
|
+
}
|
|
3061
|
+
|
|
3062
|
+
/**
|
|
3063
|
+
* Event handler for row operations in a table.
|
|
3064
|
+
*/
|
|
3065
|
+
class CaptionOperationEventHandler extends SettingEventHandler {
|
|
3066
|
+
/**
|
|
3067
|
+
* @inheritDoc
|
|
3068
|
+
*/
|
|
3069
|
+
canHandle(action) {
|
|
3070
|
+
return action[0] === TableSettingType.CAPTION;
|
|
3071
|
+
}
|
|
3072
|
+
/**
|
|
3073
|
+
* Toggle caption state for the target table block when the caption menu item is clicked.
|
|
3074
|
+
*
|
|
3075
|
+
* @param {Array<string>} action - Table setting payload, e.g. ['CAPTION', 'rte-table-caption'].
|
|
3076
|
+
* @param {RTEExtensionContext} _extensionContext - Current editor extension context (unused here).
|
|
3077
|
+
* @param {RTETableBlock} tableBlock - Table block that owns the caption.
|
|
3078
|
+
*/
|
|
3079
|
+
execute(action, _extensionContext, tableBlock) {
|
|
3080
|
+
const shouldEnable = action[1] === 'rte-table-caption';
|
|
3081
|
+
const toggleAction = new TableCaptionAction(shouldEnable);
|
|
3082
|
+
const existingCaption = tableBlock.getCaption();
|
|
3083
|
+
if (shouldEnable) {
|
|
3084
|
+
const hydratedCaption = existingCaption && existingCaption.isNotEmpty()
|
|
3085
|
+
? existingCaption
|
|
3086
|
+
: this.createCaptionBlock(existingCaption === null || existingCaption === void 0 ? void 0 : existingCaption.id);
|
|
3087
|
+
if (!existingCaption || hydratedCaption !== existingCaption) {
|
|
3088
|
+
tableBlock.setCaption(hydratedCaption);
|
|
3089
|
+
}
|
|
3090
|
+
toggleAction.nextFocusNode = hydratedCaption.getLastNode();
|
|
3091
|
+
}
|
|
3092
|
+
else {
|
|
3093
|
+
if (existingCaption) {
|
|
3094
|
+
tableBlock.setCaption(null);
|
|
3095
|
+
toggleAction.nextFocusNode = tableBlock.getFirstNode();
|
|
3096
|
+
}
|
|
3097
|
+
}
|
|
3098
|
+
this.syncCursorPosition(tableBlock, toggleAction.nextFocusNode);
|
|
3099
|
+
}
|
|
3100
|
+
/**
|
|
3101
|
+
* Applies a cursor update action so the editor focuses on the resolved node.
|
|
3102
|
+
*
|
|
3103
|
+
* @param {RTETableBlock} block - Table block currently being toggled.
|
|
3104
|
+
* @param {Nullable<RTENode>} focusNode - Target node that should receive the caret.
|
|
3105
|
+
*/
|
|
3106
|
+
syncCursorPosition(block, focusNode) {
|
|
3107
|
+
super.syncCursorPosition(block, focusNode);
|
|
3108
|
+
}
|
|
3109
|
+
/**
|
|
3110
|
+
* Build a fresh caption block with a default paragraph + placeholder text.
|
|
3111
|
+
*
|
|
3112
|
+
* @param {string} id - table-caption id
|
|
3113
|
+
* @returns {RTETableCaptionBlock} Newly created caption DTO ready for rendering.
|
|
3114
|
+
*/
|
|
3115
|
+
createCaptionBlock(id) {
|
|
3116
|
+
const captionData = {
|
|
3117
|
+
id: id !== null && id !== void 0 ? id : generateUUID(),
|
|
3118
|
+
type: 'table-caption',
|
|
3119
|
+
children: [
|
|
3120
|
+
{
|
|
3121
|
+
id: generateUUID(),
|
|
3122
|
+
type: 'paragraph',
|
|
3123
|
+
nodes: [
|
|
3124
|
+
{
|
|
3125
|
+
id: generateUUID(),
|
|
3126
|
+
type: 'text',
|
|
3127
|
+
text: '',
|
|
3128
|
+
},
|
|
3129
|
+
],
|
|
3130
|
+
},
|
|
3131
|
+
],
|
|
3132
|
+
};
|
|
3133
|
+
return RTETableCaptionBlock.from(captionData);
|
|
3134
|
+
}
|
|
3135
|
+
}
|
|
3136
|
+
|
|
3137
|
+
/**
|
|
3138
|
+
* Centralizes the popover rendering and interaction logic for table settings.
|
|
3139
|
+
*/
|
|
3140
|
+
class TableSettingPopoverRenderer {
|
|
3141
|
+
constructor() {
|
|
3142
|
+
this.settingHandlers = [
|
|
3143
|
+
new RowOperationEventHandler(),
|
|
3144
|
+
new CaptionOperationEventHandler(),
|
|
3145
|
+
new ColumnOperationEventHandler(),
|
|
3146
|
+
];
|
|
3147
|
+
/**
|
|
3148
|
+
* Show table setting popover when table is clicked.
|
|
3149
|
+
* Only the popover belonging to the nearest table will be shown,
|
|
3150
|
+
* which avoids outer tables showing their popover when an inner (nested) table is clicked.
|
|
3151
|
+
*
|
|
3152
|
+
* @param {MouseEvent} event - The MouseEvent that triggered the table action
|
|
3153
|
+
* @param {HTMLElement} trigger - The element that can triggered the popover open.
|
|
3154
|
+
*/
|
|
3155
|
+
this.handleTableClick = (event, trigger) => {
|
|
3156
|
+
const target = event.target;
|
|
3157
|
+
const ownTrigger = target.closest('.v-rte--extension-table-popover-trigger');
|
|
3158
|
+
if (trigger !== ownTrigger) {
|
|
3159
|
+
void this.popoverRef.hide();
|
|
3160
|
+
void this.tableDynamicPopover.hide();
|
|
3161
|
+
return;
|
|
3162
|
+
}
|
|
3163
|
+
void this.tableDynamicPopover.hide();
|
|
3164
|
+
if (!this.popoverShow) {
|
|
3165
|
+
remoteInvocationRegistry.call(domNodeSubjectFactory.getSubject(this.popoverRef, VegaInternalPopoverUpdateTarget), ownTrigger);
|
|
3166
|
+
void this.popoverRef.show();
|
|
3167
|
+
}
|
|
3168
|
+
};
|
|
3169
|
+
/**
|
|
3170
|
+
* Sync the selected cells from the table selection to the table setting component.
|
|
3171
|
+
*/
|
|
3172
|
+
this.syncSelectedCells = () => {
|
|
3173
|
+
if (this.tableSettingRef) {
|
|
3174
|
+
const selectedCells = this.getTableSelectedCells();
|
|
3175
|
+
this.tableSettingRef.selectedCells = selectedCells;
|
|
3176
|
+
}
|
|
3177
|
+
};
|
|
3178
|
+
/**
|
|
3179
|
+
* Receive setting menu click events.
|
|
3180
|
+
*
|
|
3181
|
+
* @param {CustomEvent<Array<string>>} event - The custom event emitted from the setting menu.
|
|
3182
|
+
*/
|
|
3183
|
+
this.handleSettingMenuClick = (event) => {
|
|
3184
|
+
const handler = this.settingHandlers.find((handler) => handler.canHandle(event.detail));
|
|
3185
|
+
if (handler) {
|
|
3186
|
+
handler.execute(event.detail, this.extensionContext, this.tableData);
|
|
3187
|
+
if (event.detail[0] === TableSettingType.CAPTION) {
|
|
3188
|
+
this.updateTableSettingCaption();
|
|
3189
|
+
}
|
|
3190
|
+
}
|
|
3191
|
+
if (event.detail[0] === TableSettingType.TABLE_PROPERTIES ||
|
|
3192
|
+
event.detail[0] === TableSettingType.CELL_PROPERTIES) {
|
|
3193
|
+
void this.popoverRef.hide();
|
|
3194
|
+
void this.tableDynamicPopover.show(event.detail[0]);
|
|
3195
|
+
}
|
|
3196
|
+
};
|
|
3197
|
+
/**
|
|
3198
|
+
* Handles the popover show event to sync the selected table cells to the table setting component.
|
|
3199
|
+
*/
|
|
3200
|
+
this.handleTableSettingPopoverShow = () => {
|
|
3201
|
+
this.syncSelectedCells();
|
|
3202
|
+
this.popoverShow = true;
|
|
3203
|
+
};
|
|
3204
|
+
}
|
|
3205
|
+
/**
|
|
3206
|
+
* Injects the RTE extension context.
|
|
3207
|
+
*
|
|
3208
|
+
* @param {RTETableExtensionContext} context - The RTE extension context.
|
|
3209
|
+
*/
|
|
3210
|
+
injectRTEExtensionContext(context) {
|
|
3211
|
+
this.extensionContext = context;
|
|
3212
|
+
}
|
|
3213
|
+
/**
|
|
3214
|
+
* Render the popover host and inject the table-setting component with refs wired up.
|
|
3215
|
+
*
|
|
3216
|
+
* @param {VegaRTECreateElementFunction} h - The create element function.
|
|
3217
|
+
* @param {RTETableBlock} renderData - The table block to render.
|
|
3218
|
+
* @param {TableDynamicPopoverRenderer} tableDynamicPopover - Renderer used to show
|
|
3219
|
+
* the secondary table popover (for example, table-properties-specific settings).
|
|
3220
|
+
* @returns {VegaRTERenderResult} The rendered popover structure.
|
|
3221
|
+
*/
|
|
3222
|
+
render(h, renderData, tableDynamicPopover) {
|
|
3223
|
+
this.tableData = renderData;
|
|
3224
|
+
this.tableDynamicPopover = tableDynamicPopover;
|
|
3225
|
+
return h('vega-popover', {
|
|
3226
|
+
trigger: 'click',
|
|
3227
|
+
isScreenPosition: true,
|
|
3228
|
+
class: 'rte-table-setting-popover',
|
|
3229
|
+
// eslint-disable-next-line jsdoc/require-jsdoc
|
|
3230
|
+
ref: (popover) => {
|
|
3231
|
+
this.popoverRef = popover;
|
|
3232
|
+
if (this.popoverRef) {
|
|
3233
|
+
DomNodeSubjectObserverFactory.addUniqueObserverToNode(popover, VegaPopoverShow, this.handleTableSettingPopoverShow);
|
|
3234
|
+
DomNodeSubjectObserverFactory.addUniqueObserverToNode(popover, VegaPopoverHide, () => (this.popoverShow = false));
|
|
3235
|
+
}
|
|
3236
|
+
},
|
|
3237
|
+
}, [
|
|
3238
|
+
h('div', { slot: 'popover' }, [
|
|
3239
|
+
h('vega-rich-text-table-setting', {
|
|
3240
|
+
// eslint-disable-next-line jsdoc/require-jsdoc
|
|
3241
|
+
ref: (el) => {
|
|
3242
|
+
this.tableSettingRef = el;
|
|
3243
|
+
},
|
|
3244
|
+
selectedCells: this.getTableSelectedCells(),
|
|
3245
|
+
onVegaClick: this.handleSettingMenuClick,
|
|
3246
|
+
}),
|
|
3247
|
+
]),
|
|
3248
|
+
]);
|
|
3249
|
+
}
|
|
3250
|
+
/**
|
|
3251
|
+
* Updates the table setting component caption state to match the given table data.
|
|
3252
|
+
*/
|
|
3253
|
+
updateTableSettingCaption() {
|
|
3254
|
+
const hasCaption = this.tableData.hasCaption();
|
|
3255
|
+
if (this.tableSettingRef && this.tableSettingRef.hasCaption !== hasCaption) {
|
|
3256
|
+
this.tableSettingRef.hasCaption = hasCaption;
|
|
3257
|
+
}
|
|
3258
|
+
}
|
|
3259
|
+
/**
|
|
3260
|
+
* Collects and returns the currently selected table cells.
|
|
3261
|
+
*
|
|
3262
|
+
* @returns {RTETableCellBlock[]} The array of currently selected table cell blocks.
|
|
3263
|
+
*/
|
|
3264
|
+
getTableSelectedCells() {
|
|
3265
|
+
let selectedCells = [];
|
|
3266
|
+
if (this.extensionContext && this.extensionContext.tableSelection) {
|
|
3267
|
+
const { tableSelection } = this.extensionContext;
|
|
3268
|
+
selectedCells = tableSelection.getSelectedCells();
|
|
3269
|
+
}
|
|
3270
|
+
return selectedCells;
|
|
3271
|
+
}
|
|
3272
|
+
}
|
|
3273
|
+
|
|
3274
|
+
const CONTENT_CLASS_MAP = {
|
|
3275
|
+
[TableSettingType.TABLE_PROPERTIES]: 'rte-table-properties-popover',
|
|
3276
|
+
[TableSettingType.CELL_PROPERTIES]: 'rte-cell-properties-popover',
|
|
3277
|
+
};
|
|
3278
|
+
/**
|
|
3279
|
+
* Renderer for a generic, dynamically positioned popover used within table-related extensions.
|
|
3280
|
+
*
|
|
3281
|
+
* - The popover target is based on the current cursor/selection position.
|
|
3282
|
+
* - The popover content is rendered dynamic content.
|
|
3283
|
+
*/
|
|
3284
|
+
class TableDynamicPopoverRenderer {
|
|
3285
|
+
/**
|
|
3286
|
+
* Shows the popover. Before showing, it will refresh the target so
|
|
3287
|
+
* that the popover is positioned relative to the latest cursor position.
|
|
3288
|
+
*
|
|
3289
|
+
* @param {string} type - The table setting type determining which
|
|
3290
|
+
* content variant to display (for example, table properties or cell properties).
|
|
3291
|
+
*/
|
|
3292
|
+
async show(type) {
|
|
3293
|
+
let target = this.getTableRef();
|
|
3294
|
+
const cells = this.extensionContext.tableSelection.getSelectedCells();
|
|
3295
|
+
if (type !== TableSettingType.TABLE_PROPERTIES && cells.length === 1) {
|
|
3296
|
+
target = stateEntityRenderingRegistry.getDOMByEntity(cells[0]);
|
|
3297
|
+
}
|
|
3298
|
+
this.updateContent(type);
|
|
3299
|
+
remoteInvocationRegistry.call(domNodeSubjectFactory.getSubject(this.popoverRef, VegaInternalPopoverUpdateTarget), target);
|
|
3300
|
+
await this.popoverRef.show();
|
|
3301
|
+
}
|
|
3302
|
+
/**
|
|
3303
|
+
* hide the popover.
|
|
3304
|
+
*/
|
|
3305
|
+
async hide() {
|
|
3306
|
+
await this.popoverRef.hide();
|
|
3307
|
+
}
|
|
3308
|
+
/**
|
|
3309
|
+
* Injects the RTE extension context.
|
|
3310
|
+
*
|
|
3311
|
+
* @param {RTETableExtensionContext} context - The RTE extension context.
|
|
3312
|
+
*/
|
|
3313
|
+
injectRTEExtensionContext(context) {
|
|
3314
|
+
this.extensionContext = context;
|
|
3315
|
+
}
|
|
3316
|
+
/**
|
|
3317
|
+
* Renders a vega-popover whose target and content are provided dynamically by callers.
|
|
3318
|
+
*
|
|
3319
|
+
* @param {VegaRTECreateElementFunction} h - The create element function.
|
|
3320
|
+
* @param {() => HTMLElement} getTableRef - Current table DOM reference
|
|
3321
|
+
* @returns {VegaRTERenderResult} The rendered popover host.
|
|
3322
|
+
*/
|
|
3323
|
+
render(h, getTableRef) {
|
|
3324
|
+
this.getTableRef = getTableRef;
|
|
3325
|
+
return h('vega-popover', {
|
|
3326
|
+
trigger: 'click',
|
|
3327
|
+
isScreenPosition: true,
|
|
3328
|
+
class: 'rte-table-dynamic-popover',
|
|
3329
|
+
// eslint-disable-next-line jsdoc/require-jsdoc
|
|
3330
|
+
ref: (popover) => {
|
|
3331
|
+
this.popoverRef = popover;
|
|
3332
|
+
},
|
|
3333
|
+
}, [
|
|
3334
|
+
h('div', {
|
|
3335
|
+
slot: 'popover',
|
|
3336
|
+
class: 'rte-table-dynamic-popover-content',
|
|
3337
|
+
// eslint-disable-next-line jsdoc/require-jsdoc
|
|
3338
|
+
ref: (ref) => (this.contentRef = ref),
|
|
3339
|
+
}, [
|
|
3340
|
+
h('div', {
|
|
3341
|
+
class: CONTENT_CLASS_MAP[TableSettingType.TABLE_PROPERTIES],
|
|
3342
|
+
}, 'table-properties'),
|
|
3343
|
+
h('div', {
|
|
3344
|
+
class: CONTENT_CLASS_MAP[TableSettingType.CELL_PROPERTIES],
|
|
3345
|
+
}, 'cell-properties'),
|
|
3346
|
+
]),
|
|
3347
|
+
]);
|
|
3348
|
+
}
|
|
3349
|
+
/**
|
|
3350
|
+
* Updates the visibility of the pre-rendered content blocks based on type.
|
|
3351
|
+
*
|
|
3352
|
+
* @param {string} type - The table setting type determining which content variant should be visible.
|
|
3353
|
+
*/
|
|
3354
|
+
updateContent(type) {
|
|
3355
|
+
if (type !== this.currentType) {
|
|
3356
|
+
this.currentType = type;
|
|
3357
|
+
this.contentRef.childNodes.forEach((child) => {
|
|
3358
|
+
if (child.classList.contains(CONTENT_CLASS_MAP[this.currentType])) {
|
|
3359
|
+
child.style.display = 'block';
|
|
3360
|
+
}
|
|
3361
|
+
else {
|
|
3362
|
+
child.style.display = 'none';
|
|
3363
|
+
}
|
|
3364
|
+
});
|
|
3365
|
+
}
|
|
3366
|
+
}
|
|
3367
|
+
}
|
|
3368
|
+
|
|
3369
|
+
/**
|
|
3370
|
+
* Renderer for the RTETableBlock.
|
|
3371
|
+
*/
|
|
3372
|
+
class RTETableBlockRenderer extends VegaRTEExtensionRenderer {
|
|
3373
|
+
constructor() {
|
|
3374
|
+
super(...arguments);
|
|
3375
|
+
this.extensionContext = null;
|
|
3376
|
+
}
|
|
3377
|
+
/**
|
|
3378
|
+
* @inheritDoc
|
|
3379
|
+
*/
|
|
3380
|
+
doRender(h, renderData, rteContext) {
|
|
3381
|
+
const tableSettingPopoverRenderer = new TableSettingPopoverRenderer();
|
|
3382
|
+
const tableDynamicPopoverRenderer = new TableDynamicPopoverRenderer();
|
|
3383
|
+
if (this.extensionContext) {
|
|
3384
|
+
tableSettingPopoverRenderer.injectRTEExtensionContext(this.extensionContext);
|
|
3385
|
+
tableDynamicPopoverRenderer.injectRTEExtensionContext(this.extensionContext);
|
|
3386
|
+
}
|
|
3387
|
+
let tableRef;
|
|
3388
|
+
const table = this.renderTable(h, renderData);
|
|
3389
|
+
const tableSettingPopover = tableSettingPopoverRenderer.render(h, renderData, tableDynamicPopoverRenderer);
|
|
3390
|
+
const tableDynamicPopover = tableDynamicPopoverRenderer.render(h, () => tableRef);
|
|
3391
|
+
const tableAnnotation = renderData.getAnnotationByType(RTETableExtensionAnnotationTypeEnum.TABLE);
|
|
3392
|
+
const children = rteContext.editable
|
|
3393
|
+
? [
|
|
3394
|
+
h('vega-rich-text-table-selection-widget', {
|
|
3395
|
+
// eslint-disable-next-line jsdoc/require-jsdoc
|
|
3396
|
+
onVegaRemove: (e) => {
|
|
3397
|
+
e.stopPropagation();
|
|
3398
|
+
this.handleTableRemove(renderData);
|
|
3399
|
+
},
|
|
3400
|
+
// eslint-disable-next-line jsdoc/require-jsdoc
|
|
3401
|
+
onClick: (event) => tableSettingPopoverRenderer.handleTableClick(event, tableRef),
|
|
3402
|
+
// eslint-disable-next-line jsdoc/require-jsdoc
|
|
3403
|
+
onMouseLeave: () => {
|
|
3404
|
+
tableSettingPopoverRenderer.syncSelectedCells();
|
|
3405
|
+
},
|
|
3406
|
+
}, [
|
|
3407
|
+
h('vega-box', {
|
|
3408
|
+
class: 'v-rte--extension-table-popover-trigger',
|
|
3409
|
+
// eslint-disable-next-line jsdoc/require-jsdoc
|
|
3410
|
+
ref: (ref) => (tableRef = ref),
|
|
3411
|
+
}, [table, tableSettingPopover, tableDynamicPopover]),
|
|
3412
|
+
]),
|
|
3413
|
+
]
|
|
3414
|
+
: [table];
|
|
3415
|
+
const result = h('div', {
|
|
3416
|
+
class: 'v-rte--extension-table-container',
|
|
3417
|
+
style: Object.assign({}, (tableAnnotation && tableAnnotation.renderAlignmentStyle())),
|
|
3418
|
+
}, children);
|
|
3419
|
+
/**
|
|
3420
|
+
* The getter for the children container.
|
|
3421
|
+
*
|
|
3422
|
+
* @returns {VegaRTERenderResult} - The children container render result.
|
|
3423
|
+
*/
|
|
3424
|
+
result.childrenContainerGetter = () => table;
|
|
3425
|
+
return result;
|
|
3426
|
+
}
|
|
3427
|
+
/**
|
|
3428
|
+
* @inheritDoc
|
|
3429
|
+
*/
|
|
3430
|
+
injectRTEScopeStyles() {
|
|
3431
|
+
return tableBlockStylesCss;
|
|
3432
|
+
}
|
|
3433
|
+
/**
|
|
3434
|
+
* Injects the RTE extension context.
|
|
3435
|
+
*
|
|
3436
|
+
* @param {RTETableExtensionContext} context - The RTE extension context.
|
|
3437
|
+
*/
|
|
3438
|
+
injectExtensionContext(context) {
|
|
3439
|
+
this.extensionContext = context;
|
|
3440
|
+
}
|
|
3441
|
+
/**
|
|
3442
|
+
* Renders the table element.
|
|
3443
|
+
*
|
|
3444
|
+
* @param {VegaRTECreateElementFunction} h - The create element function.
|
|
3445
|
+
* @param {RTETableBlock} renderData - The table block to render.
|
|
3446
|
+
* @returns {VegaRTERenderResult} - The rendered table element.
|
|
3447
|
+
*/
|
|
3448
|
+
renderTable(h, renderData) {
|
|
3449
|
+
var _a;
|
|
3450
|
+
return h('table', Object.assign(Object.assign({ key: renderData.id }, (_a = renderData.getCustomAttributesAnnotation()) === null || _a === void 0 ? void 0 : _a.render()), { style: renderData.getStyles(), class: [RTETableBlockRenderer.EXTENSION_TABLE_CLASS, renderData.getClasses()].join(' '),
|
|
3451
|
+
// eslint-disable-next-line jsdoc/require-jsdoc
|
|
3452
|
+
ref: (ref) => {
|
|
3453
|
+
this.useRef(renderData)(ref);
|
|
3454
|
+
} }));
|
|
3455
|
+
}
|
|
3456
|
+
/**
|
|
3457
|
+
* Handles the removal of the table block.
|
|
3458
|
+
*
|
|
3459
|
+
* @param {RTETableBlock} renderData - The table block to remove.
|
|
3460
|
+
*/
|
|
3461
|
+
handleTableRemove(renderData) {
|
|
3462
|
+
renderData.parent.apply(new DeleteTableBlockAction(renderData));
|
|
3463
|
+
}
|
|
3464
|
+
}
|
|
3465
|
+
RTETableBlockRenderer.EXTENSION_TABLE_CLASS = 'v-rte--extension-table';
|
|
3466
|
+
|
|
3467
|
+
/**
|
|
3468
|
+
* Renders a logic control block in the rich text editor.
|
|
3469
|
+
*/
|
|
3470
|
+
class RTETableHeadRenderer extends VegaRTEExtensionRenderer {
|
|
3471
|
+
/**
|
|
3472
|
+
* @inheritDoc
|
|
3473
|
+
*/
|
|
3474
|
+
doRender(h, renderData) {
|
|
3475
|
+
return h('thead', {
|
|
3476
|
+
key: renderData.id,
|
|
3477
|
+
ref: this.useRef(renderData),
|
|
3478
|
+
});
|
|
3479
|
+
}
|
|
3480
|
+
}
|
|
3481
|
+
|
|
3482
|
+
/**
|
|
3483
|
+
* Renders a logic control block in the rich text editor.
|
|
3484
|
+
*/
|
|
3485
|
+
class RTETableRowBlockRenderer extends VegaRTEExtensionRenderer {
|
|
3486
|
+
/**
|
|
3487
|
+
* @inheritDoc
|
|
3488
|
+
*/
|
|
3489
|
+
doRender(h, renderData) {
|
|
3490
|
+
return h('tr', {
|
|
3491
|
+
key: renderData.id,
|
|
3492
|
+
ref: this.useRef(renderData),
|
|
3493
|
+
});
|
|
3494
|
+
}
|
|
3495
|
+
}
|
|
3496
|
+
|
|
3497
|
+
/**
|
|
3498
|
+
* Renders a table cell block in the rich text editor.
|
|
3499
|
+
*/
|
|
3500
|
+
class RTETableCellRenderer extends VegaRTEExtensionRenderer {
|
|
3501
|
+
/**
|
|
3502
|
+
* @inheritDoc
|
|
3503
|
+
*/
|
|
3504
|
+
doRender(h, renderData, rteContext) {
|
|
3505
|
+
return this.renderByCellType(h, renderData, rteContext, 'td');
|
|
3506
|
+
}
|
|
3507
|
+
/**
|
|
3508
|
+
* Injects the extension context
|
|
3509
|
+
*
|
|
3510
|
+
* @param {RTETableExtensionContext} context - extension context
|
|
3511
|
+
*/
|
|
3512
|
+
injectExtensionContext(context) {
|
|
3513
|
+
this.extensionContext = context;
|
|
3514
|
+
}
|
|
3515
|
+
/**
|
|
3516
|
+
* Renders the table cell based on its type (td or th).
|
|
3517
|
+
*
|
|
3518
|
+
* @param {VegaRTECreateElementFunction} h - The create element function.
|
|
3519
|
+
* @param {RTETableCellBlock} renderData - The table cell block to render.
|
|
3520
|
+
* @param {RTERenderContext} rteContext - The rte editor context.
|
|
3521
|
+
* @param {'td' | 'th'} elementType - The type of table cell element ('td' or 'th').
|
|
3522
|
+
* @returns {VegaRTERenderResult} - The rendered table cell element.
|
|
3523
|
+
*/
|
|
3524
|
+
renderByCellType(h, renderData, rteContext, elementType) {
|
|
3525
|
+
var _a;
|
|
3526
|
+
return h(elementType, Object.assign(Object.assign(Object.assign({ key: renderData.id, ref: this.useRef(renderData) }, (_a = renderData.getCustomAttributesAnnotation()) === null || _a === void 0 ? void 0 : _a.render()), { style: renderData.getStyles(rteContext), class: renderData.getClasses() }), (rteContext.editable ? this.onSelectionListeners(renderData) : undefined)));
|
|
3527
|
+
}
|
|
3528
|
+
/**
|
|
3529
|
+
* Returns the mouse event listeners for selection handling.
|
|
3530
|
+
*
|
|
3531
|
+
* @param {RTETableCellBlock} renderData - The table cell block to render.
|
|
3532
|
+
* @returns {RTETableSelectionListenersType} - The mouse event listeners.
|
|
3533
|
+
*/
|
|
3534
|
+
onSelectionListeners(renderData) {
|
|
3535
|
+
return {
|
|
3536
|
+
/**
|
|
3537
|
+
* Handles the mouse down event to focus a cell.
|
|
3538
|
+
*
|
|
3539
|
+
* @param {MouseEvent} event - The mouse event.
|
|
3540
|
+
*/
|
|
3541
|
+
onMouseDown: (event) => {
|
|
3542
|
+
const targetParentTable = findParent(event.target, 'table');
|
|
3543
|
+
const currentTable = findParent(event.currentTarget, 'table');
|
|
3544
|
+
const inCurrentTable = currentTable === targetParentTable;
|
|
3545
|
+
const cellRef = event.target.closest('td, th');
|
|
3546
|
+
if (inCurrentTable && cellRef) {
|
|
3547
|
+
this.extensionContext.tableSelection.focusCell(cellRef);
|
|
3548
|
+
}
|
|
3549
|
+
},
|
|
3550
|
+
/**
|
|
3551
|
+
* Handles the mouse move event to start selection.
|
|
3552
|
+
*
|
|
3553
|
+
* @param {MouseEvent} event - The mouse event.
|
|
3554
|
+
*/
|
|
3555
|
+
onMouseMove: (event) => {
|
|
3556
|
+
event.stopPropagation();
|
|
3557
|
+
event.preventDefault();
|
|
3558
|
+
this.extensionContext.tableSelection.dragOver(renderData);
|
|
3559
|
+
},
|
|
3560
|
+
/**
|
|
3561
|
+
* Handles the mouse up event to end selection.
|
|
3562
|
+
*/
|
|
3563
|
+
onMouseUp: () => {
|
|
3564
|
+
this.extensionContext.tableSelection.endDrag();
|
|
3565
|
+
},
|
|
3566
|
+
};
|
|
3567
|
+
}
|
|
3568
|
+
}
|
|
3569
|
+
|
|
3570
|
+
/**
|
|
3571
|
+
* Renders a table body block in the rich text editor.
|
|
3572
|
+
*/
|
|
3573
|
+
class RTETableBodyRenderer extends VegaRTEExtensionRenderer {
|
|
3574
|
+
/**
|
|
3575
|
+
* @inheritDoc
|
|
3576
|
+
*/
|
|
3577
|
+
doRender(h, renderData) {
|
|
3578
|
+
return h('tbody', {
|
|
3579
|
+
key: renderData.id,
|
|
3580
|
+
ref: this.useRef(renderData),
|
|
3581
|
+
});
|
|
3582
|
+
}
|
|
3583
|
+
}
|
|
3584
|
+
|
|
3585
|
+
/**
|
|
3586
|
+
* Renders a head cell block in the rich text editor.
|
|
3587
|
+
*/
|
|
3588
|
+
class RTETableHeadCellRenderer extends RTETableCellRenderer {
|
|
3589
|
+
/**
|
|
3590
|
+
* @inheritDoc
|
|
3591
|
+
*/
|
|
3592
|
+
doRender(h, renderData, rteContext) {
|
|
3593
|
+
return super.renderByCellType(h, renderData, rteContext, 'th');
|
|
3594
|
+
}
|
|
3595
|
+
}
|
|
3596
|
+
|
|
3597
|
+
const INSERT_TABLE_BLOCK = 'INSERT_TABLE_BLOCK';
|
|
3598
|
+
/**
|
|
3599
|
+
* Action to insert a table block into the rich text editor.
|
|
3600
|
+
*/
|
|
3601
|
+
class InsertTableBlockAction extends ModifyContentAction {
|
|
3602
|
+
constructor(rowCount, columnCount) {
|
|
3603
|
+
super();
|
|
3604
|
+
this.type = INSERT_TABLE_BLOCK;
|
|
3605
|
+
this.rowCount = rowCount;
|
|
3606
|
+
this.columnCount = columnCount;
|
|
3607
|
+
}
|
|
3608
|
+
}
|
|
3609
|
+
|
|
3610
|
+
const tableIcon = {
|
|
3611
|
+
icon: `<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 512 512"><!--! Font Awesome Pro 6.3.0 by @fontawesome - https://fontawesome.com License - https://fontawesome.com/license (Commercial License) Copyright 2023 Fonticons, Inc. --><path fill="currentColor" d="M48 264V160H232V264H48zm0 48H232V432H64c-8.8 0-16-7.2-16-16V312zM280 432V312H464V416c0 8.8-7.2 16-16 16H280zM464 264H280V160H464V264zM64 32C28.7 32 0 60.7 0 96V416c0 35.3 28.7 64 64 64H448c35.3 0 64-28.7 64-64V96c0-35.3-28.7-64-64-64H64z"/></svg>`,
|
|
3612
|
+
};
|
|
3613
|
+
|
|
3614
|
+
/**
|
|
3615
|
+
* Function toolbar button renderer class.
|
|
3616
|
+
*/
|
|
3617
|
+
class RTETableToolbarButtonRenderer extends VegaRTEToolbarButtonRenderer {
|
|
3618
|
+
constructor() {
|
|
3619
|
+
super(...arguments);
|
|
3620
|
+
this.hoveredRows = 1;
|
|
3621
|
+
this.hoveredCols = 1;
|
|
3622
|
+
}
|
|
3623
|
+
/**
|
|
3624
|
+
* Injects the extension context
|
|
3625
|
+
*
|
|
3626
|
+
* @param {RTETableExtensionContext} context - extension context
|
|
3627
|
+
*/
|
|
3628
|
+
injectExtensionContext(context) {
|
|
3629
|
+
this.extensionContext = context;
|
|
3630
|
+
}
|
|
3631
|
+
/**
|
|
3632
|
+
* @inheritDoc
|
|
3633
|
+
*/
|
|
3634
|
+
render(h, editorContext) {
|
|
3635
|
+
return this.renderTablePicker(h, super.renderButton(h, editorContext, {
|
|
3636
|
+
showArrowIcon: true,
|
|
3637
|
+
icon: 'rte-table',
|
|
3638
|
+
}));
|
|
3639
|
+
}
|
|
3640
|
+
/**
|
|
3641
|
+
* Overrides the isDisabled method to determine if the button should be disabled.
|
|
3642
|
+
*
|
|
3643
|
+
* @returns {boolean} - true if the button should be disabled, false otherwise.
|
|
3644
|
+
*/
|
|
3645
|
+
isDisabled() {
|
|
3646
|
+
const { host, getSelectedNodes } = this.extensionContext;
|
|
3647
|
+
const focusNode = getSelectedNodes()[0];
|
|
3648
|
+
let enableInsert = true;
|
|
3649
|
+
if (focusNode) {
|
|
3650
|
+
enableInsert =
|
|
3651
|
+
ActionHandleStrategyRegistry.canHandle(INSERT_TABLE_BLOCK, focusNode.parent) &&
|
|
3652
|
+
ActionHandleStrategyRegistry.canHandle(ModifyContentActionType.INSERT_CHILDREN_AFTER, focusNode.parent.parent);
|
|
3653
|
+
}
|
|
3654
|
+
return host.disabled || !enableInsert;
|
|
3655
|
+
}
|
|
3656
|
+
/**
|
|
3657
|
+
* @inheritDoc
|
|
3658
|
+
*/
|
|
3659
|
+
handleButtonClick() {
|
|
3660
|
+
}
|
|
3661
|
+
/* istanbul ignore next */
|
|
3662
|
+
/**
|
|
3663
|
+
* @inheritDoc
|
|
3664
|
+
*/
|
|
3665
|
+
handleDropdownClick() {
|
|
3666
|
+
}
|
|
3667
|
+
/**
|
|
3668
|
+
* Renders the table size picker popover.
|
|
3669
|
+
*
|
|
3670
|
+
* @param {VegaRTECreateElementFunction} h - Create element function.
|
|
3671
|
+
* @param {VegaRTERenderResult} children - The children elements to render inside the popover.
|
|
3672
|
+
* @returns {VegaRTERenderResult} - The render result for the table size picker popover.
|
|
3673
|
+
*/
|
|
3674
|
+
renderTablePicker(h, children) {
|
|
3675
|
+
return h('vega-popover', {
|
|
3676
|
+
trigger: 'click',
|
|
3677
|
+
alignment: 'start',
|
|
3678
|
+
placement: 'bottom',
|
|
3679
|
+
showArrow: false,
|
|
3680
|
+
// eslint-disable-next-line jsdoc/require-jsdoc
|
|
3681
|
+
ref: (ref) => {
|
|
3682
|
+
if (ref) {
|
|
3683
|
+
this.tablePickerPopoverRef = ref;
|
|
3684
|
+
DomNodeSubjectObserverFactory.addUniqueObserverToNode(ref, VegaPopoverShow, () => {
|
|
3685
|
+
this.resetPicker();
|
|
3686
|
+
});
|
|
3687
|
+
}
|
|
3688
|
+
},
|
|
3689
|
+
}, [
|
|
3690
|
+
h('div', { slot: 'popover' }, [this.generatePickerStyles(h), this.generateTableSizeGrid(h)]),
|
|
3691
|
+
h('div', { slot: 'popover-content' }, children),
|
|
3692
|
+
]);
|
|
3693
|
+
}
|
|
3694
|
+
/**
|
|
3695
|
+
* Generates the table size picker grid.
|
|
3696
|
+
*
|
|
3697
|
+
* @param {VegaRTECreateElementFunction} h - Create element function.
|
|
3698
|
+
* @returns {VegaRTERenderResult} - The render result for the table size picker.
|
|
3699
|
+
*/
|
|
3700
|
+
generateTableSizeGrid(h) {
|
|
3701
|
+
const rows = 10;
|
|
3702
|
+
const cols = 10;
|
|
3703
|
+
const gridCells = [];
|
|
3704
|
+
for (let r = 1; r <= rows; r++) {
|
|
3705
|
+
for (let c = 1; c <= cols; c++) {
|
|
3706
|
+
gridCells.push(h('button', {
|
|
3707
|
+
'class': `rte-table-picker__cell`,
|
|
3708
|
+
'data-row': r,
|
|
3709
|
+
'data-col': c,
|
|
3710
|
+
'onMouseenter': this.handlePickerCellHover.bind(this, r, c),
|
|
3711
|
+
'onClick': this.handlePickerClick.bind(this, r, c),
|
|
3712
|
+
}, []));
|
|
3713
|
+
}
|
|
3714
|
+
}
|
|
3715
|
+
return h('div', { class: 'rte-table-picker' }, [
|
|
3716
|
+
h('div', {
|
|
3717
|
+
class: 'rte-table-picker__grid',
|
|
3718
|
+
// eslint-disable-next-line jsdoc/require-jsdoc
|
|
3719
|
+
ref: (ref) => {
|
|
3720
|
+
if (ref) {
|
|
3721
|
+
this.tablePickerGridRef = ref;
|
|
3722
|
+
}
|
|
3723
|
+
},
|
|
3724
|
+
style: {
|
|
3725
|
+
gridTemplateColumns: `repeat(${cols}, 16px)`,
|
|
3726
|
+
gridTemplateRows: `repeat(${rows}, 16px)`,
|
|
3727
|
+
},
|
|
3728
|
+
}, gridCells),
|
|
3729
|
+
h('div', {
|
|
3730
|
+
class: 'rte-table-picker__hint',
|
|
3731
|
+
}, h('vega-hint', {
|
|
3732
|
+
// eslint-disable-next-line jsdoc/require-jsdoc
|
|
3733
|
+
ref: (ref) => {
|
|
3734
|
+
if (ref) {
|
|
3735
|
+
this.selectedHintRef = ref;
|
|
3736
|
+
}
|
|
3737
|
+
},
|
|
3738
|
+
}, [`${this.hoveredRows} × ${this.hoveredCols}`])),
|
|
3739
|
+
]);
|
|
3740
|
+
}
|
|
3741
|
+
/**
|
|
3742
|
+
* Generates the styles for the table size picker.
|
|
3743
|
+
*
|
|
3744
|
+
* @param {VegaRTECreateElementFunction} h - Create element function.
|
|
3745
|
+
* @returns {VegaRTERenderResult} - The render result for the styles.
|
|
3746
|
+
*/
|
|
3747
|
+
generatePickerStyles(h) {
|
|
3748
|
+
return h('style', {}, [
|
|
3749
|
+
// eslint-disable-next-line spellcheck/spell-checker
|
|
3750
|
+
`
|
|
3751
|
+
.rte-table-picker__grid { display: grid; gap: 2px; }
|
|
3752
|
+
.rte-table-picker__cell {
|
|
3753
|
+
box-sizing: border-box;
|
|
3754
|
+
border: 1px solid #ccc;
|
|
3755
|
+
background-color: transparent;
|
|
3756
|
+
cursor: pointer;
|
|
3757
|
+
}
|
|
3758
|
+
.rte-table-picker__cell:hover {
|
|
3759
|
+
background-color: #cae1fc;
|
|
3760
|
+
}
|
|
3761
|
+
.rte-table-picker__cell.active {
|
|
3762
|
+
background-color: #cae1fc;
|
|
3763
|
+
}
|
|
3764
|
+
.rte-table-picker__hint {
|
|
3765
|
+
text-align: center;
|
|
3766
|
+
}
|
|
3767
|
+
`,
|
|
3768
|
+
]);
|
|
3769
|
+
}
|
|
3770
|
+
/**
|
|
3771
|
+
* Creates a table block with the specified number of rows and columns.
|
|
3772
|
+
*
|
|
3773
|
+
* @param {number} row - The number of rows for the table.
|
|
3774
|
+
* @param {number} column - The number of columns for the table.
|
|
3775
|
+
*/
|
|
3776
|
+
createTable(row, column) {
|
|
3777
|
+
const { host, getSelectedNodes } = this.extensionContext;
|
|
3778
|
+
const focusNode = getSelectedNodes()[0];
|
|
3779
|
+
const action = new InsertTableBlockAction(row, column);
|
|
3780
|
+
if (!focusNode) {
|
|
3781
|
+
host.value.apply(action);
|
|
3782
|
+
}
|
|
3783
|
+
else if (focusNode.parent) {
|
|
3784
|
+
focusNode.parent.apply(action);
|
|
3785
|
+
}
|
|
3786
|
+
if (action.nextFocusNode) {
|
|
3787
|
+
host.value.apply(new UpdateCursorPositionAction(action.nextFocusNode, 1));
|
|
3788
|
+
}
|
|
3789
|
+
}
|
|
3790
|
+
/**
|
|
3791
|
+
* Handles the click event on a picker cell.
|
|
3792
|
+
*
|
|
3793
|
+
* @param {number} r - The number of rows selected.
|
|
3794
|
+
* @param {number} c - The number of columns selected.
|
|
3795
|
+
*/
|
|
3796
|
+
handlePickerClick(r, c) {
|
|
3797
|
+
this.createTable(r, c);
|
|
3798
|
+
void this.tablePickerPopoverRef.hide();
|
|
3799
|
+
}
|
|
3800
|
+
/**
|
|
3801
|
+
* Handles the hover event on a picker cell.
|
|
3802
|
+
*
|
|
3803
|
+
* @param {number} r - The number of rows being hovered over.
|
|
3804
|
+
* @param {number} c - The number of columns being hovered over.
|
|
3805
|
+
*/
|
|
3806
|
+
handlePickerCellHover(r, c) {
|
|
3807
|
+
this.hoveredRows = r;
|
|
3808
|
+
this.hoveredCols = c;
|
|
3809
|
+
Array.from(this.tablePickerGridRef.children).forEach((cell) => {
|
|
3810
|
+
const rIndex = Number(cell.dataset.row);
|
|
3811
|
+
const cIndex = Number(cell.dataset.col);
|
|
3812
|
+
if (rIndex <= this.hoveredRows && cIndex <= this.hoveredCols) {
|
|
3813
|
+
cell.classList.add('active');
|
|
3814
|
+
}
|
|
3815
|
+
else {
|
|
3816
|
+
cell.classList.remove('active');
|
|
3817
|
+
}
|
|
3818
|
+
});
|
|
3819
|
+
this.selectedHintRef.textContent = `${this.hoveredRows} × ${this.hoveredCols}`;
|
|
3820
|
+
}
|
|
3821
|
+
/**
|
|
3822
|
+
* Resets the table picker to its initial state.
|
|
3823
|
+
*/
|
|
3824
|
+
resetPicker() {
|
|
3825
|
+
this.handlePickerCellHover(1, 1);
|
|
3826
|
+
}
|
|
3827
|
+
}
|
|
3828
|
+
(() => {
|
|
3829
|
+
VegaInternalIconManager.register({ 'rte-table': tableIcon });
|
|
3830
|
+
})();
|
|
3831
|
+
|
|
3832
|
+
/**
|
|
3833
|
+
* Strategy to handle the insertion of a block into the rich text editor.
|
|
3834
|
+
*/
|
|
3835
|
+
class InsertTableBlockStrategy extends ActionHandleStrategy {
|
|
3836
|
+
/**
|
|
3837
|
+
* @inheritDoc
|
|
3838
|
+
*/
|
|
3839
|
+
handleAction(action, target) {
|
|
3840
|
+
const tableBlock = this.createTableBlock(action.rowCount, action.columnCount);
|
|
3841
|
+
const emptyParagraph = super.createNewParagraph('');
|
|
3842
|
+
const referenceBlock = this.getReferenceBlock(target);
|
|
3843
|
+
if (referenceBlock) {
|
|
3844
|
+
referenceBlock.parent.apply(new InsertChildrenAfterAction(referenceBlock, tableBlock, emptyParagraph));
|
|
3845
|
+
}
|
|
3846
|
+
else {
|
|
3847
|
+
target.apply(new AppendChildrenAction([tableBlock, emptyParagraph]));
|
|
3848
|
+
}
|
|
3849
|
+
action.nextFocusNode = tableBlock.getFirstNode();
|
|
3850
|
+
}
|
|
3851
|
+
/**
|
|
3852
|
+
* Create a table block with the specified number of rows and columns.
|
|
3853
|
+
*
|
|
3854
|
+
* @param {number} row - The number of rows in the table.
|
|
3855
|
+
* @param {number} column - The number of columns in the table.
|
|
3856
|
+
* @returns {RTETableBlock} The created table block.
|
|
3857
|
+
*/
|
|
3858
|
+
createTableBlock(row, column) {
|
|
3859
|
+
const normalizedRowCount = Math.max(row, 1);
|
|
3860
|
+
const normalizedColumnCount = Math.max(column, 1);
|
|
3861
|
+
return RTETableBlock.from({
|
|
3862
|
+
id: generateUUID(),
|
|
3863
|
+
type: 'table-block',
|
|
3864
|
+
children: [generateTableBody(normalizedRowCount, normalizedColumnCount)],
|
|
3865
|
+
});
|
|
3866
|
+
}
|
|
3867
|
+
/**
|
|
3868
|
+
* We need to get the correct block if the current target is a block element to avoid nesting blocks.
|
|
3869
|
+
*
|
|
3870
|
+
* @param {RTEBlock} currentTarget - The current target block or content.
|
|
3871
|
+
* @returns {Nullable<RTEBlock>} The reference block.
|
|
3872
|
+
*/
|
|
3873
|
+
getReferenceBlock(currentTarget) {
|
|
3874
|
+
if (!(currentTarget instanceof VegaRTEContent)) {
|
|
3875
|
+
return currentTarget;
|
|
3876
|
+
}
|
|
3877
|
+
}
|
|
3878
|
+
}
|
|
3879
|
+
|
|
3880
|
+
/**
|
|
3881
|
+
* Interceptor to prevent deletion of a table cell if it is the cell with empty content.
|
|
3882
|
+
*/
|
|
3883
|
+
class PreventCellContentDeleteInterceptor extends ActionHandlerInterceptor {
|
|
3884
|
+
/**
|
|
3885
|
+
* Prevent deletion if the target block is the only child of a table cell and is empty.
|
|
3886
|
+
*
|
|
3887
|
+
* @param {DeleteBlockContentAction} _action - the action to be intercepted
|
|
3888
|
+
* @param {RTETextBlock} target - the target block
|
|
3889
|
+
* @returns {boolean} - true if the deletion should be intercepted, false otherwise
|
|
3890
|
+
*/
|
|
3891
|
+
canIntercept(_action, target) {
|
|
3892
|
+
const cell = target.parent;
|
|
3893
|
+
return cell instanceof RTETableCellBlock && cell.children.length === 1 && !target.isNotEmpty();
|
|
3894
|
+
}
|
|
3895
|
+
/**
|
|
3896
|
+
* @inheritDoc
|
|
3897
|
+
*/
|
|
3898
|
+
intercept() {
|
|
3899
|
+
}
|
|
3900
|
+
}
|
|
3901
|
+
|
|
3902
|
+
/**
|
|
3903
|
+
* Strategy to handle the deletion of a table block from the parent.
|
|
3904
|
+
*/
|
|
3905
|
+
class DeleteTableBlockStrategy extends ActionHandleStrategy {
|
|
3906
|
+
/**
|
|
3907
|
+
* Deletes the specified table block and updates the cursor position.
|
|
3908
|
+
*
|
|
3909
|
+
* @param {DeleteTableBlockAction} action - The action containing the table block to delete.
|
|
3910
|
+
*/
|
|
3911
|
+
handleAction(action) {
|
|
3912
|
+
const tableBlock = action.tableBlock;
|
|
3913
|
+
const parent = tableBlock.parent;
|
|
3914
|
+
const root = super.getRootContent(tableBlock);
|
|
3915
|
+
const newParagraph = super.createNewParagraph('');
|
|
3916
|
+
parent.apply(new InsertChildrenAfterAction(tableBlock, newParagraph));
|
|
3917
|
+
parent.apply(new RemoveChildrenAction(tableBlock));
|
|
3918
|
+
if (root) {
|
|
3919
|
+
root.apply(new UpdateCursorPositionAction(newParagraph.getLastNode()));
|
|
3920
|
+
}
|
|
3921
|
+
}
|
|
3922
|
+
}
|
|
3923
|
+
|
|
3924
|
+
/**
|
|
3925
|
+
* Interceptor to prevent removal of all children from a cell, ensuring at least one child remains.
|
|
3926
|
+
*/
|
|
3927
|
+
class PreventCellChildrenRemoveInterceptor extends ActionHandlerInterceptor {
|
|
3928
|
+
/**
|
|
3929
|
+
* Prevent removal if the target cell would be left empty after the action.
|
|
3930
|
+
*
|
|
3931
|
+
* @param {RemoveChildrenAction} action - the action to be intercepted
|
|
3932
|
+
* @param {RTETableCellBlock | RTETableHeadCellBlock} target - the target cell block
|
|
3933
|
+
* @returns {boolean} - true if the removal should be intercepted, false otherwise
|
|
3934
|
+
*/
|
|
3935
|
+
canIntercept(action, target) {
|
|
3936
|
+
return action.entityToBeRemoved && target.children.length === 1;
|
|
3937
|
+
}
|
|
3938
|
+
/**
|
|
3939
|
+
* Add a new empty text node to the cell to prevent it from removal.
|
|
3940
|
+
*
|
|
3941
|
+
* @param {ActionHandlerExecution} _execution - the original execution function
|
|
3942
|
+
* @param {RemoveChildrenAction} action - the action to be intercepted
|
|
3943
|
+
* @param {RTETableCellBlock | RTETableHeadCellBlock} target - the target cell block
|
|
3944
|
+
*/
|
|
3945
|
+
intercept(_execution, action, target) {
|
|
3946
|
+
if (!(action.entityToBeRemoved instanceof RTETextBlock)) {
|
|
3947
|
+
const newParagraph = RTETextBlock.from({
|
|
3948
|
+
id: generateUUID(),
|
|
3949
|
+
type: 'paragraph',
|
|
3950
|
+
nodes: [{ id: generateUUID(), type: 'text', text: '' }],
|
|
3951
|
+
});
|
|
3952
|
+
target.children = [];
|
|
3953
|
+
target.apply(new AppendChildrenAction([newParagraph]));
|
|
3954
|
+
return;
|
|
3955
|
+
}
|
|
3956
|
+
action.entityToBeRemoved.apply(new AppendChildrenAction([
|
|
3957
|
+
new RTETextNode(generateUUID(), '', action.entityToBeRemoved),
|
|
3958
|
+
]));
|
|
3959
|
+
}
|
|
3960
|
+
}
|
|
3961
|
+
|
|
3962
|
+
/**
|
|
3963
|
+
* Strategy class for handling the insertion of a new row into a table.
|
|
3964
|
+
*/
|
|
3965
|
+
class InsertTableRowStrategy extends ActionHandleStrategy {
|
|
3966
|
+
/**
|
|
3967
|
+
* @inheritDoc
|
|
3968
|
+
*/
|
|
3969
|
+
handleAction(action, target) {
|
|
3970
|
+
const { insertDirection, selectedRows } = action;
|
|
3971
|
+
// The reference block will control where to insert the new row
|
|
3972
|
+
let refBlock = insertDirection === InsertTableRowDirection.ABOVE
|
|
3973
|
+
? selectedRows[0]
|
|
3974
|
+
: selectedRows[selectedRows.length - 1];
|
|
3975
|
+
// The row need to be inserted is a header row
|
|
3976
|
+
if (this.shouldInsertHeaderRow(refBlock, insertDirection)) {
|
|
3977
|
+
const headerBlock = RTETableRowBlock.from({
|
|
3978
|
+
id: generateUUID(),
|
|
3979
|
+
type: 'table-row',
|
|
3980
|
+
children: refBlock.children.map((item) => {
|
|
3981
|
+
return this.getDefaultCellBlockTemplate(item.type);
|
|
3982
|
+
}),
|
|
3983
|
+
});
|
|
3984
|
+
if (insertDirection === InsertTableRowDirection.ABOVE) {
|
|
3985
|
+
refBlock.parent.apply(new InsertChildrenBeforeAction(refBlock, headerBlock));
|
|
3986
|
+
}
|
|
3987
|
+
else {
|
|
3988
|
+
refBlock.parent.apply(new InsertChildrenAfterAction(refBlock, headerBlock));
|
|
3989
|
+
}
|
|
3990
|
+
}
|
|
3991
|
+
else {
|
|
3992
|
+
let direction = insertDirection;
|
|
3993
|
+
let tableBody = target.children.find((block) => block instanceof RTETableBodyBlock);
|
|
3994
|
+
// Should insert into body if reference block is in head row and body exists
|
|
3995
|
+
if (refBlock.parent instanceof RTETableHeadBlock && tableBody) {
|
|
3996
|
+
refBlock = tableBody.children[0];
|
|
3997
|
+
direction = InsertTableRowDirection.ABOVE;
|
|
3998
|
+
}
|
|
3999
|
+
const refBlockIsHeaderRow = refBlock.parent instanceof RTETableHeadBlock;
|
|
4000
|
+
const rowBlock = RTETableRowBlock.from({
|
|
4001
|
+
id: generateUUID(),
|
|
4002
|
+
type: 'table-row',
|
|
4003
|
+
children: refBlock.children.map((item) => {
|
|
4004
|
+
return this.getDefaultCellBlockTemplate(refBlockIsHeaderRow ? 'table-cell' : item.type);
|
|
4005
|
+
}),
|
|
4006
|
+
});
|
|
4007
|
+
if (!tableBody) {
|
|
4008
|
+
tableBody = RTETableBodyBlock.from({
|
|
4009
|
+
id: generateUUID(),
|
|
4010
|
+
type: 'table-body',
|
|
4011
|
+
children: [],
|
|
4012
|
+
});
|
|
4013
|
+
tableBody.apply(new AppendChildrenAction([rowBlock]));
|
|
4014
|
+
target.apply(new AppendChildrenAction([tableBody]));
|
|
4015
|
+
}
|
|
4016
|
+
else {
|
|
4017
|
+
if (direction === InsertTableRowDirection.ABOVE) {
|
|
4018
|
+
tableBody.apply(new InsertChildrenBeforeAction(refBlock, rowBlock));
|
|
4019
|
+
}
|
|
4020
|
+
else {
|
|
4021
|
+
tableBody.apply(new InsertChildrenAfterAction(refBlock, rowBlock));
|
|
4022
|
+
}
|
|
4023
|
+
}
|
|
4024
|
+
}
|
|
4025
|
+
}
|
|
4026
|
+
/**
|
|
4027
|
+
* Checks if a header row should be inserted based on the selected rows and position.
|
|
4028
|
+
*
|
|
4029
|
+
* @param {RTETableRowBlock} refBlock - The reference table row block.
|
|
4030
|
+
* @param {InsertTableRowDirection} direction - The direction to insert the new row (above or below).
|
|
4031
|
+
* @returns {boolean} True if a header row should be inserted, false otherwise.
|
|
4032
|
+
*/
|
|
4033
|
+
shouldInsertHeaderRow(refBlock, direction) {
|
|
4034
|
+
if (direction === InsertTableRowDirection.ABOVE) {
|
|
4035
|
+
return refBlock.parent instanceof RTETableHeadBlock;
|
|
4036
|
+
}
|
|
4037
|
+
else {
|
|
4038
|
+
const parentBlock = refBlock.parent;
|
|
4039
|
+
return (parentBlock instanceof RTETableHeadBlock &&
|
|
4040
|
+
parentBlock.children[parentBlock.children.length - 1] !== refBlock);
|
|
4041
|
+
}
|
|
4042
|
+
}
|
|
4043
|
+
/**
|
|
4044
|
+
* Get the default cell block template.
|
|
4045
|
+
*
|
|
4046
|
+
* @param {string} cellType - The type of the cell block.
|
|
4047
|
+
* @returns {VegaRTETableCellBlock | VegaRTETableHeadCellBlock} The default cell block template.
|
|
4048
|
+
*/
|
|
4049
|
+
getDefaultCellBlockTemplate(cellType) {
|
|
4050
|
+
const id = generateUUID();
|
|
4051
|
+
return {
|
|
4052
|
+
id,
|
|
4053
|
+
type: cellType,
|
|
4054
|
+
children: [
|
|
4055
|
+
{
|
|
4056
|
+
id: `${id}-p`,
|
|
4057
|
+
type: 'paragraph',
|
|
4058
|
+
nodes: [
|
|
4059
|
+
{
|
|
4060
|
+
id: `${id}-p-t`,
|
|
4061
|
+
type: 'text',
|
|
4062
|
+
text: '',
|
|
4063
|
+
},
|
|
4064
|
+
],
|
|
4065
|
+
},
|
|
4066
|
+
],
|
|
4067
|
+
};
|
|
4068
|
+
}
|
|
4069
|
+
}
|
|
4070
|
+
|
|
4071
|
+
const TABLE_CAPTION_PLACEHOLDER_TEXT = 'Enter table caption';
|
|
4072
|
+
/**
|
|
4073
|
+
* Renderer for the optional table caption node.
|
|
4074
|
+
*/
|
|
4075
|
+
class RTETableCaptionRenderer extends VegaRTEExtensionRenderer {
|
|
4076
|
+
/**
|
|
4077
|
+
* @inheritDoc
|
|
4078
|
+
*/
|
|
4079
|
+
doRender(h, renderData) {
|
|
4080
|
+
return h('caption', {
|
|
4081
|
+
'key': renderData.id,
|
|
4082
|
+
'ref': this.useRef(renderData),
|
|
4083
|
+
'style': renderData.getStyles(),
|
|
4084
|
+
'class': [renderData.getClasses(), renderData.isNotEmpty() ? null : 'showPlaceholder']
|
|
4085
|
+
.filter(isNonNullable)
|
|
4086
|
+
.join(' '),
|
|
4087
|
+
'data-placeholder': TABLE_CAPTION_PLACEHOLDER_TEXT,
|
|
4088
|
+
});
|
|
4089
|
+
}
|
|
4090
|
+
}
|
|
4091
|
+
|
|
4092
|
+
/**
|
|
4093
|
+
* Strategy class for handling the deletion of table rows.
|
|
4094
|
+
*/
|
|
4095
|
+
class DeleteTableRowStrategy extends ActionHandleStrategy {
|
|
4096
|
+
/**
|
|
4097
|
+
* @inheritDoc
|
|
4098
|
+
*/
|
|
4099
|
+
handleAction(action, target) {
|
|
4100
|
+
const { rowsToBeRemoved } = action;
|
|
4101
|
+
const futureFocusRow = this.getFutureFocusRow(rowsToBeRemoved[0], rowsToBeRemoved[rowsToBeRemoved.length - 1], target);
|
|
4102
|
+
rowsToBeRemoved.forEach((row) => {
|
|
4103
|
+
this.removeRow(row);
|
|
4104
|
+
});
|
|
4105
|
+
if (futureFocusRow) {
|
|
4106
|
+
const root = this.getRootContent(target);
|
|
4107
|
+
if (root) {
|
|
4108
|
+
const focusNode = futureFocusRow.getLastNode();
|
|
4109
|
+
root.apply(new UpdateCursorPositionAction(focusNode, focusNode.getRangeEndOffset()));
|
|
4110
|
+
}
|
|
4111
|
+
}
|
|
4112
|
+
}
|
|
4113
|
+
/**
|
|
4114
|
+
* Removes the specified row from its parent table section.
|
|
4115
|
+
* // TODO: Add handling for when selected row has or in merge column.
|
|
4116
|
+
*
|
|
4117
|
+
* @param {RTETableRowBlock} rowToBeRemoved The row to be removed.
|
|
4118
|
+
*/
|
|
4119
|
+
removeRow(rowToBeRemoved) {
|
|
4120
|
+
rowToBeRemoved.parent.apply(new RemoveChildrenAction(rowToBeRemoved));
|
|
4121
|
+
}
|
|
4122
|
+
/**
|
|
4123
|
+
* Get the future focus row after deletion.
|
|
4124
|
+
*
|
|
4125
|
+
* @param {RTETableRowBlock} startRow - The first row to be deleted.
|
|
4126
|
+
* @param {RTETableRowBlock} endRow - The last row to be deleted.
|
|
4127
|
+
* @param {RTETableBlock} table - The table containing the rows.
|
|
4128
|
+
* @returns {Nullable<RTETableRowBlock>} The row to be focused after deletion.
|
|
4129
|
+
*/
|
|
4130
|
+
getFutureFocusRow(startRow, endRow, table) {
|
|
4131
|
+
const allRows = table.children
|
|
4132
|
+
.filter((item) => item instanceof RTETableHeadBlock || item instanceof RTETableBodyBlock)
|
|
4133
|
+
.flatMap((block) => block.children);
|
|
4134
|
+
const startIndex = allRows.indexOf(startRow);
|
|
4135
|
+
const endIndex = allRows.indexOf(endRow);
|
|
4136
|
+
if (allRows[startIndex - 1]) {
|
|
4137
|
+
return allRows[startIndex - 1];
|
|
4138
|
+
}
|
|
4139
|
+
else if (allRows[endIndex + 1]) {
|
|
4140
|
+
return allRows[endIndex + 1];
|
|
4141
|
+
}
|
|
4142
|
+
}
|
|
4143
|
+
}
|
|
4144
|
+
|
|
4145
|
+
/**
|
|
4146
|
+
* Table selection helper used for mouse drag selection of cells.
|
|
4147
|
+
*/
|
|
4148
|
+
class RTETableSelection {
|
|
4149
|
+
constructor() {
|
|
4150
|
+
/**
|
|
4151
|
+
* Indicates whether the user is currently performing a drag selection.
|
|
4152
|
+
*/
|
|
4153
|
+
this.dragging = false;
|
|
4154
|
+
/**
|
|
4155
|
+
* Anchor cell where the drag selection started.
|
|
4156
|
+
*/
|
|
4157
|
+
this.anchorCell = null;
|
|
4158
|
+
/**
|
|
4159
|
+
* Collection of currently selected cells.
|
|
4160
|
+
*/
|
|
4161
|
+
this.selectedCells = new Set();
|
|
4162
|
+
this.syncRTESelectionWithDebounce = debounce(this.syncRTESelection, 100, this);
|
|
4163
|
+
this.handleSelectionChangeWithDebounce = debounce(this.handleSelectionChange, 10, this);
|
|
4164
|
+
/**
|
|
4165
|
+
* Recursively filter and collect selected table cell blocks within the given node.
|
|
4166
|
+
*
|
|
4167
|
+
* @param {Range} range - The current selection range.
|
|
4168
|
+
* @param {Node} node - The current node to check for selection.
|
|
4169
|
+
* @returns {RTETableCellBlock[]} A list of selected table cell blocks.
|
|
4170
|
+
*/
|
|
4171
|
+
this.filterSelectedCell = (range, node) => {
|
|
4172
|
+
const selectedCells = new Set();
|
|
4173
|
+
if (range.intersectsNode(node)) {
|
|
4174
|
+
if (node.nodeType === Node.TEXT_NODE) {
|
|
4175
|
+
const focusedNodeDto = stateEntityRenderingRegistry.getEntityByDOM(node.parentElement);
|
|
4176
|
+
if (focusedNodeDto) {
|
|
4177
|
+
const cell = getParentBlockByType(focusedNodeDto.parent, RTETableCellBlock);
|
|
4178
|
+
if (cell) {
|
|
4179
|
+
selectedCells.add(cell);
|
|
4180
|
+
return Array.from(selectedCells);
|
|
4181
|
+
}
|
|
4182
|
+
}
|
|
4183
|
+
}
|
|
4184
|
+
node.childNodes.forEach((child) => this.filterSelectedCell(range, child).forEach((cell) => {
|
|
4185
|
+
selectedCells.add(cell);
|
|
4186
|
+
}));
|
|
4187
|
+
}
|
|
4188
|
+
return Array.from(selectedCells);
|
|
4189
|
+
};
|
|
4190
|
+
/**
|
|
4191
|
+
* Update the styles of the selected cells.
|
|
4192
|
+
*
|
|
4193
|
+
* @param {RTETableCellBlock} cell - The cell to update style for.
|
|
4194
|
+
* @param {number} total - The total number of selected cells.
|
|
4195
|
+
*/
|
|
4196
|
+
this.updateSelectedStyles = (cell, total) => {
|
|
4197
|
+
const selectedClass = total === 1 ? 'v-rte-table-cell-focused' : 'v-rte-table-cell-selected';
|
|
4198
|
+
const cellRef = stateEntityRenderingRegistry.getDOMByEntity(cell);
|
|
4199
|
+
if (cellRef) {
|
|
4200
|
+
cellRef.classList.add(selectedClass);
|
|
4201
|
+
}
|
|
4202
|
+
};
|
|
4203
|
+
/**
|
|
4204
|
+
* Handles the document mouse up event to finish drag selection.
|
|
4205
|
+
*/
|
|
4206
|
+
this.handleDocMouseUp = () => {
|
|
4207
|
+
this.endDrag();
|
|
4208
|
+
const safeDocument = tryGetDocument();
|
|
4209
|
+
if (safeDocument) {
|
|
4210
|
+
safeDocument.removeEventListener('mouseup', this.handleDocMouseUp);
|
|
4211
|
+
}
|
|
4212
|
+
};
|
|
4213
|
+
/**
|
|
4214
|
+
* Resets the table selection when clicking outside the table.
|
|
4215
|
+
*/
|
|
4216
|
+
this.handleContentClick = () => {
|
|
4217
|
+
this.clearSelection();
|
|
4218
|
+
const editorContent =
|
|
4219
|
+
// eslint-disable-next-line @typescript-eslint/no-non-null-assertion
|
|
4220
|
+
this.context.host.shadowRoot.querySelector('.rich-text-editor-container');
|
|
4221
|
+
if (editorContent) {
|
|
4222
|
+
editorContent.removeEventListener('mousedown', this.handleContentClick, true);
|
|
4223
|
+
}
|
|
4224
|
+
};
|
|
4225
|
+
}
|
|
4226
|
+
/**
|
|
4227
|
+
* Compute all cells inside the rectangle defined by the start and end cells.
|
|
4228
|
+
*
|
|
4229
|
+
* Note: this only performs the calculation and does not modify the internal `selectedCells` set,
|
|
4230
|
+
* so callers can decide how to apply the result.
|
|
4231
|
+
*
|
|
4232
|
+
* @param {RTETableCellBlock | RTETableHeadCellBlock} anchor - Drag start cell (anchor cell).
|
|
4233
|
+
* @param {RTETableCellBlock | RTETableHeadCellBlock} focus - Current drag focus cell.
|
|
4234
|
+
* @returns {(RTETableCellBlock | RTETableHeadCellBlock)[]} All cells in the rectangular selection area.
|
|
4235
|
+
*/
|
|
4236
|
+
static computeRectRange(anchor, focus) {
|
|
4237
|
+
// Collect all row blocks (from both head and body) under the same table,
|
|
4238
|
+
// then compute the rectangle over this flattened row list.
|
|
4239
|
+
const anchorRow = anchor.parent;
|
|
4240
|
+
const focusRow = focus.parent;
|
|
4241
|
+
const anchorSection = anchorRow.parent;
|
|
4242
|
+
const focusSection = focusRow.parent;
|
|
4243
|
+
const anchorTable = anchorSection.parent;
|
|
4244
|
+
const focusTable = focusSection.parent;
|
|
4245
|
+
// If they are not in the same table at all, just return empty.
|
|
4246
|
+
if (anchorTable !== focusTable) {
|
|
4247
|
+
return [];
|
|
4248
|
+
}
|
|
4249
|
+
// Flatten head rows (if any) + body rows into a single ordered list.
|
|
4250
|
+
const allRows = [];
|
|
4251
|
+
const tableChildren = anchorTable.children;
|
|
4252
|
+
tableChildren.forEach((section) => {
|
|
4253
|
+
section.children.forEach((row) => allRows.push(row));
|
|
4254
|
+
});
|
|
4255
|
+
const anchorRowIndex = allRows.indexOf(anchorRow);
|
|
4256
|
+
const focusRowIndex = allRows.indexOf(focusRow);
|
|
4257
|
+
const startRow = Math.min(anchorRowIndex, focusRowIndex);
|
|
4258
|
+
const endRow = Math.max(anchorRowIndex, focusRowIndex);
|
|
4259
|
+
const anchorColIndex = anchorRow.children.indexOf(anchor);
|
|
4260
|
+
const focusColIndex = focusRow.children.indexOf(focus);
|
|
4261
|
+
const startCol = Math.min(anchorColIndex, focusColIndex);
|
|
4262
|
+
const endCol = Math.max(anchorColIndex, focusColIndex);
|
|
4263
|
+
const result = [];
|
|
4264
|
+
for (let r = startRow; r <= endRow; r++) {
|
|
4265
|
+
const row = allRows[r];
|
|
4266
|
+
for (let c = startCol; c <= endCol; c++) {
|
|
4267
|
+
const cell = row.children[c];
|
|
4268
|
+
if (cell) {
|
|
4269
|
+
result.push(cell);
|
|
4270
|
+
}
|
|
4271
|
+
}
|
|
4272
|
+
}
|
|
4273
|
+
return result;
|
|
4274
|
+
}
|
|
4275
|
+
/**
|
|
4276
|
+
* Clean up event listeners.
|
|
4277
|
+
*/
|
|
4278
|
+
destroy() {
|
|
4279
|
+
this.removeSelectionChangeListener();
|
|
4280
|
+
}
|
|
4281
|
+
/**
|
|
4282
|
+
* Inject the extension context and set up selection change listener.
|
|
4283
|
+
*
|
|
4284
|
+
* @param {RTEExtensionContext} context - The extension context.
|
|
4285
|
+
*/
|
|
4286
|
+
init(context) {
|
|
4287
|
+
this.context = context;
|
|
4288
|
+
this.addSelectionChangeListener();
|
|
4289
|
+
}
|
|
4290
|
+
/**
|
|
4291
|
+
* Set the selected cells to the given list, replacing any existing selection.
|
|
4292
|
+
*
|
|
4293
|
+
* @param {RTETableCellBlock} cells - The cells to select.
|
|
4294
|
+
*/
|
|
4295
|
+
setSelectedCells(cells) {
|
|
4296
|
+
this.updateSelectedCells(cells);
|
|
4297
|
+
}
|
|
4298
|
+
/**
|
|
4299
|
+
* Get all currently selected cells.
|
|
4300
|
+
*
|
|
4301
|
+
* @returns {(RTETableCellBlock | RTETableHeadCellBlock)[]} A flat list of selected cells.
|
|
4302
|
+
*/
|
|
4303
|
+
getSelectedCells() {
|
|
4304
|
+
return Array.from(this.selectedCells);
|
|
4305
|
+
}
|
|
4306
|
+
/**
|
|
4307
|
+
* Handle mouse down on a cell: start drag selection from the given cell.
|
|
4308
|
+
*
|
|
4309
|
+
* @param {HTMLElement} cellRef - The cell where the drag starts.
|
|
4310
|
+
*/
|
|
4311
|
+
focusCell(cellRef) {
|
|
4312
|
+
const cellBlock = stateEntityRenderingRegistry.getEntityByDOM(cellRef);
|
|
4313
|
+
if (cellBlock) {
|
|
4314
|
+
this.anchorCell = cellBlock;
|
|
4315
|
+
this.setSelectedCells([cellBlock]);
|
|
4316
|
+
this.addListeners();
|
|
4317
|
+
}
|
|
4318
|
+
}
|
|
4319
|
+
/**
|
|
4320
|
+
* Handle drag over a cell (typically called on `mouseenter` while dragging).
|
|
4321
|
+
* Maintains a rectangular selection between the anchor cell and the current cell.
|
|
4322
|
+
*
|
|
4323
|
+
* @param {RTETableCellBlock | RTETableHeadCellBlock} cell - The cell currently under the drag.
|
|
4324
|
+
*/
|
|
4325
|
+
dragOver(cell) {
|
|
4326
|
+
if (!this.anchorCell) {
|
|
4327
|
+
return;
|
|
4328
|
+
}
|
|
4329
|
+
// Always compute the rectangle strictly from the original anchorCell
|
|
4330
|
+
// (the cell where startDrag was first called) to the current cell.
|
|
4331
|
+
const rectCells = RTETableSelection.computeRectRange(this.anchorCell, cell);
|
|
4332
|
+
if (rectCells.length > 1) {
|
|
4333
|
+
this.startDrag();
|
|
4334
|
+
}
|
|
4335
|
+
if (this.dragging) {
|
|
4336
|
+
this.preventTextSelection(rectCells);
|
|
4337
|
+
this.updateSelectedCells(rectCells, { debounceSync: true });
|
|
4338
|
+
}
|
|
4339
|
+
}
|
|
4340
|
+
/**
|
|
4341
|
+
* Handle mouse up: stop drag selection.
|
|
4342
|
+
*/
|
|
4343
|
+
endDrag() {
|
|
4344
|
+
this.dragging = false;
|
|
4345
|
+
// Reset anchor after drag ends so the next drag can start from a new cell.
|
|
4346
|
+
this.anchorCell = null;
|
|
4347
|
+
}
|
|
4348
|
+
/**
|
|
4349
|
+
* Clear the current selection state without changing the drag flag.
|
|
4350
|
+
*/
|
|
4351
|
+
clearSelection() {
|
|
4352
|
+
this.selectedCells.forEach((cell) => {
|
|
4353
|
+
const cellRef = stateEntityRenderingRegistry.getDOMByEntity(cell);
|
|
4354
|
+
if (cellRef) {
|
|
4355
|
+
cellRef.classList.remove('v-rte-table-cell-selected', 'v-rte-table-cell-focused');
|
|
4356
|
+
}
|
|
4357
|
+
});
|
|
4358
|
+
this.selectedCells.clear();
|
|
4359
|
+
}
|
|
4360
|
+
/**
|
|
4361
|
+
* Add a selectionchange listener to the document to handle cell click selection.
|
|
4362
|
+
*/
|
|
4363
|
+
addSelectionChangeListener() {
|
|
4364
|
+
const safeDocument = tryGetDocument();
|
|
4365
|
+
if (safeDocument) {
|
|
4366
|
+
safeDocument.addEventListener('selectionchange', this.handleSelectionChangeWithDebounce);
|
|
4367
|
+
}
|
|
4368
|
+
}
|
|
4369
|
+
/**
|
|
4370
|
+
* Remove the selectionchange listener from the document.
|
|
4371
|
+
*/
|
|
4372
|
+
removeSelectionChangeListener() {
|
|
4373
|
+
const safeDocument = tryGetDocument();
|
|
4374
|
+
if (safeDocument) {
|
|
4375
|
+
safeDocument.removeEventListener('selectionchange', this.handleSelectionChangeWithDebounce);
|
|
4376
|
+
}
|
|
4377
|
+
}
|
|
4378
|
+
/**
|
|
4379
|
+
* Handle selection change events from the document for the cell click selection.
|
|
4380
|
+
*/
|
|
4381
|
+
handleSelectionChange() {
|
|
4382
|
+
if (this.dragging) {
|
|
4383
|
+
this.syncRTESelectionWithDebounce();
|
|
4384
|
+
return;
|
|
4385
|
+
}
|
|
4386
|
+
const selection = this.context.getSelection();
|
|
4387
|
+
if (selection.rangeCount > 0) {
|
|
4388
|
+
const range = selection.getRangeAt(0);
|
|
4389
|
+
const commonAncestorContainer = range.commonAncestorContainer;
|
|
4390
|
+
const rangeInTable = !!findParent(commonAncestorContainer, `table.${RTETableBlockRenderer.EXTENSION_TABLE_CLASS}`);
|
|
4391
|
+
if (rangeInTable) {
|
|
4392
|
+
const selectedCells = this.filterSelectedCell(range, commonAncestorContainer);
|
|
4393
|
+
this.setSelectedCells(selectedCells);
|
|
4394
|
+
}
|
|
4395
|
+
}
|
|
4396
|
+
}
|
|
4397
|
+
/**
|
|
4398
|
+
* Mark the beginning of a drag operation.
|
|
4399
|
+
*/
|
|
4400
|
+
startDrag() {
|
|
4401
|
+
this.dragging = true;
|
|
4402
|
+
}
|
|
4403
|
+
/**
|
|
4404
|
+
* Add the given cells to the current selection set.
|
|
4405
|
+
*
|
|
4406
|
+
* @param {RTETableCellBlock[]} cells - The cells to add to the selection.
|
|
4407
|
+
* @param {{ debounceSync?: boolean }} [options] - Options for updating selection.
|
|
4408
|
+
* @param {boolean} [options.debounceSync] - Whether to debounce the RTE selection sync.
|
|
4409
|
+
*/
|
|
4410
|
+
updateSelectedCells(cells, { debounceSync } = {}) {
|
|
4411
|
+
this.clearSelection();
|
|
4412
|
+
cells.forEach((cell) => {
|
|
4413
|
+
this.selectedCells.add(cell);
|
|
4414
|
+
this.updateSelectedStyles(cell, cells.length);
|
|
4415
|
+
});
|
|
4416
|
+
if (debounceSync) {
|
|
4417
|
+
this.syncRTESelectionWithDebounce();
|
|
4418
|
+
}
|
|
4419
|
+
else {
|
|
4420
|
+
this.syncRTESelection();
|
|
4421
|
+
}
|
|
4422
|
+
}
|
|
4423
|
+
/**
|
|
4424
|
+
* Synchronizes the rich text editor selection with the selected table cells.
|
|
4425
|
+
*/
|
|
4426
|
+
syncRTESelection() {
|
|
4427
|
+
const cells = Array.from(this.selectedCells);
|
|
4428
|
+
const nodes = cells
|
|
4429
|
+
.flatMap((cell) => {
|
|
4430
|
+
return cell.children.flatMap((block) => {
|
|
4431
|
+
return block.children.flatMap((node) => {
|
|
4432
|
+
// TODO: Nested table deletion will track in https://gethired.atlassian.net/browse/VD-7860
|
|
4433
|
+
if (node instanceof RTENode) {
|
|
4434
|
+
return node;
|
|
4435
|
+
}
|
|
4436
|
+
});
|
|
4437
|
+
});
|
|
4438
|
+
})
|
|
4439
|
+
.filter(isNonNullable);
|
|
4440
|
+
if (cells.length > 1) {
|
|
4441
|
+
this.context.setSelectedNodes(nodes, {
|
|
4442
|
+
startNode: nodes[0],
|
|
4443
|
+
endNode: nodes[nodes.length - 1],
|
|
4444
|
+
startOffset: 0,
|
|
4445
|
+
endOffset: nodes[nodes.length - 1].getRangeEndOffset(),
|
|
4446
|
+
});
|
|
4447
|
+
}
|
|
4448
|
+
}
|
|
4449
|
+
/**
|
|
4450
|
+
* Prevents text selection during drag operations.
|
|
4451
|
+
*
|
|
4452
|
+
* @param {RTETableCellBlock[]} selectedCells - The currently selected table cells.
|
|
4453
|
+
*/
|
|
4454
|
+
preventTextSelection(selectedCells) {
|
|
4455
|
+
const selection = this.context.getSelection();
|
|
4456
|
+
selection.removeAllRanges();
|
|
4457
|
+
if (selectedCells.length > 0) {
|
|
4458
|
+
const startContainer = stateEntityRenderingRegistry.getDOMByEntity(selectedCells[0]);
|
|
4459
|
+
if (startContainer) {
|
|
4460
|
+
const newRange = new Range();
|
|
4461
|
+
newRange.setStart(startContainer, 0);
|
|
4462
|
+
newRange.setEnd(startContainer, 0);
|
|
4463
|
+
selection.addRange(newRange);
|
|
4464
|
+
}
|
|
4465
|
+
}
|
|
4466
|
+
}
|
|
4467
|
+
/**
|
|
4468
|
+
* Adds a mouse up listener to the document to finish drag selection.
|
|
4469
|
+
*
|
|
4470
|
+
*/
|
|
4471
|
+
addListeners() {
|
|
4472
|
+
const safeDocument = tryGetDocument();
|
|
4473
|
+
if (safeDocument) {
|
|
4474
|
+
safeDocument.addEventListener('mouseup', this.handleDocMouseUp);
|
|
4475
|
+
}
|
|
4476
|
+
const editorContent =
|
|
4477
|
+
// eslint-disable-next-line @typescript-eslint/no-non-null-assertion
|
|
4478
|
+
this.context.host.shadowRoot.querySelector('.rich-text-editor-container');
|
|
4479
|
+
if (editorContent) {
|
|
4480
|
+
editorContent.addEventListener('mousedown', this.handleContentClick, true);
|
|
4481
|
+
}
|
|
4482
|
+
}
|
|
4483
|
+
}
|
|
4484
|
+
|
|
4485
|
+
/**
|
|
4486
|
+
* Strategy class for handling converting selected rows to header rows or reverting them back to normal rows.
|
|
4487
|
+
*/
|
|
4488
|
+
class ToggleHeaderRowStrategy extends ActionHandleStrategy {
|
|
4489
|
+
/**
|
|
4490
|
+
* @inheritDoc
|
|
4491
|
+
*/
|
|
4492
|
+
handleAction(action, target) {
|
|
4493
|
+
const { selectedRows } = action;
|
|
4494
|
+
const headerRows = [];
|
|
4495
|
+
const bodyRows = [];
|
|
4496
|
+
for (const row of selectedRows) {
|
|
4497
|
+
if (row.parent instanceof RTETableBodyBlock) {
|
|
4498
|
+
bodyRows.push(row);
|
|
4499
|
+
}
|
|
4500
|
+
else {
|
|
4501
|
+
headerRows.push(row);
|
|
4502
|
+
}
|
|
4503
|
+
}
|
|
4504
|
+
if (bodyRows.length > 0) {
|
|
4505
|
+
this.convertToHeaderRows(bodyRows, target);
|
|
4506
|
+
}
|
|
4507
|
+
else {
|
|
4508
|
+
this.revertToBodyRows(headerRows, target);
|
|
4509
|
+
}
|
|
4510
|
+
const root = this.getRootContent(target);
|
|
4511
|
+
if (root) {
|
|
4512
|
+
const focusNode = selectedRows[0].getFirstNode();
|
|
4513
|
+
focusNode && root.apply(new UpdateCursorPositionAction(focusNode, 0));
|
|
4514
|
+
}
|
|
4515
|
+
}
|
|
4516
|
+
/**
|
|
4517
|
+
* Converts normal rows to header rows.
|
|
4518
|
+
*
|
|
4519
|
+
* @param {RTETableRowBlock[]} rows - The table row blocks to convert.
|
|
4520
|
+
* @param {RTETableBlock} table - The table block containing the rows.
|
|
4521
|
+
*/
|
|
4522
|
+
convertToHeaderRows(rows, table) {
|
|
4523
|
+
let tableHead = table.children.find((block) => block instanceof RTETableHeadBlock);
|
|
4524
|
+
const tableBody = rows[0].parent;
|
|
4525
|
+
if (!tableHead) {
|
|
4526
|
+
tableHead = RTETableHeadBlock.from({
|
|
4527
|
+
id: generateUUID(),
|
|
4528
|
+
type: 'table-head',
|
|
4529
|
+
children: [],
|
|
4530
|
+
});
|
|
4531
|
+
table.apply(new InsertChildrenBeforeAction(tableBody, tableHead));
|
|
4532
|
+
}
|
|
4533
|
+
const endIndex = tableBody.children.indexOf(rows[rows.length - 1]);
|
|
4534
|
+
const shouldConvertRows = tableBody.children.slice(0, endIndex + 1);
|
|
4535
|
+
for (let i = 0; i < shouldConvertRows.length; i++) {
|
|
4536
|
+
const rowBlock = shouldConvertRows[i];
|
|
4537
|
+
rowBlock.children = rowBlock.children.map((cell) => this.convertTdToTh(cell));
|
|
4538
|
+
tableBody.apply(new RemoveChildrenAction(rowBlock));
|
|
4539
|
+
}
|
|
4540
|
+
tableHead.apply(new AppendChildrenAction(shouldConvertRows));
|
|
4541
|
+
}
|
|
4542
|
+
/**
|
|
4543
|
+
* Converts header rows back to normal rows.
|
|
4544
|
+
*
|
|
4545
|
+
* @param {RTETableRowBlock[]} rows - The table row blocks to convert.
|
|
4546
|
+
* @param {RTETableBlock} table - The table block containing the rows.
|
|
4547
|
+
*/
|
|
4548
|
+
revertToBodyRows(rows, table) {
|
|
4549
|
+
let tableBody = table.children.find((block) => block instanceof RTETableBodyBlock);
|
|
4550
|
+
const tableHead = rows[0].parent;
|
|
4551
|
+
if (!tableBody) {
|
|
4552
|
+
tableBody = RTETableBodyBlock.from({
|
|
4553
|
+
id: generateUUID(),
|
|
4554
|
+
type: 'table-body',
|
|
4555
|
+
children: [],
|
|
4556
|
+
});
|
|
4557
|
+
table.apply(new InsertChildrenAfterAction(tableHead, tableBody));
|
|
4558
|
+
}
|
|
4559
|
+
const firstBodyRow = tableBody.children[0];
|
|
4560
|
+
const startIndex = tableHead.children.indexOf(rows[0]);
|
|
4561
|
+
const shouldConvertRows = tableHead.children.slice(startIndex);
|
|
4562
|
+
for (let i = 0; i < shouldConvertRows.length; i++) {
|
|
4563
|
+
const rowBlock = shouldConvertRows[i];
|
|
4564
|
+
tableHead.apply(new RemoveChildrenAction(rowBlock));
|
|
4565
|
+
rowBlock.children = this.convertThToTd(rowBlock, firstBodyRow);
|
|
4566
|
+
if (firstBodyRow) {
|
|
4567
|
+
tableBody.apply(new InsertChildrenBeforeAction(firstBodyRow, rowBlock));
|
|
4568
|
+
}
|
|
4569
|
+
}
|
|
4570
|
+
if (!firstBodyRow) {
|
|
4571
|
+
tableBody.apply(new AppendChildrenAction(shouldConvertRows));
|
|
4572
|
+
}
|
|
4573
|
+
}
|
|
4574
|
+
/**
|
|
4575
|
+
* Converts a table data cell to a table header cell.
|
|
4576
|
+
*
|
|
4577
|
+
* @param {RTETableHeadCellBlock} cell - The table cell block to convert.
|
|
4578
|
+
* @returns {RTETableHeadCellBlock} The converted table header cell block.
|
|
4579
|
+
*/
|
|
4580
|
+
convertTdToTh(cell) {
|
|
4581
|
+
if (cell instanceof RTETableHeadCellBlock) {
|
|
4582
|
+
return cell;
|
|
4583
|
+
}
|
|
4584
|
+
const headCell = RTETableHeadCellBlock.from(cell.toJSON());
|
|
4585
|
+
headCell.parent = cell.parent;
|
|
4586
|
+
return headCell;
|
|
4587
|
+
}
|
|
4588
|
+
/**
|
|
4589
|
+
* Converts table header cells to table body cells.
|
|
4590
|
+
*
|
|
4591
|
+
* @param {RTETableRowBlock} row - The table row block containing the cells.
|
|
4592
|
+
* @param {Nullable<RTETableRowBlock>} referenceRow - The reference row for comparison.
|
|
4593
|
+
* @returns {RTETableCellBlock[]} The converted table body cell blocks.
|
|
4594
|
+
*/
|
|
4595
|
+
convertThToTd(row, referenceRow) {
|
|
4596
|
+
return row.children.map((cell, index) => {
|
|
4597
|
+
let bodyCell = cell;
|
|
4598
|
+
if (!referenceRow || referenceRow.children[index].type !== cell.type) {
|
|
4599
|
+
const cellJSON = cell.toJSON();
|
|
4600
|
+
bodyCell = RTETableCellBlock.from(cellJSON);
|
|
4601
|
+
}
|
|
4602
|
+
bodyCell.parent = row;
|
|
4603
|
+
return bodyCell;
|
|
4604
|
+
});
|
|
4605
|
+
}
|
|
4606
|
+
}
|
|
4607
|
+
|
|
4608
|
+
/**
|
|
4609
|
+
* Strategy to handle the insertion of a table column into the RTETable.
|
|
4610
|
+
*/
|
|
4611
|
+
class InsertTableColumnStrategy extends TableColumnStrategy {
|
|
4612
|
+
/**
|
|
4613
|
+
* @inheritDoc
|
|
4614
|
+
*/
|
|
4615
|
+
handleAction(action, target) {
|
|
4616
|
+
const insertDirection = action.insertDirection;
|
|
4617
|
+
const [startCellIndex, endCellIndex] = this.getBoundaryCellIndexOfRow(action.tableCellInsertRange);
|
|
4618
|
+
const allTableRows = getAllTableRows(target);
|
|
4619
|
+
allTableRows.forEach((row) => {
|
|
4620
|
+
if (insertDirection === InsertTableColumnDirection.LEFT) {
|
|
4621
|
+
const newCell = this.generateTableCell(row.children[startCellIndex]);
|
|
4622
|
+
row.apply(new InsertChildrenBeforeAction(row.children[startCellIndex], newCell));
|
|
4623
|
+
}
|
|
4624
|
+
else {
|
|
4625
|
+
const newCell = this.generateTableCell(row.children[endCellIndex + 1] || row.children[endCellIndex]);
|
|
4626
|
+
row.apply(new InsertChildrenAfterAction(row.children[endCellIndex], newCell));
|
|
4627
|
+
}
|
|
4628
|
+
});
|
|
4629
|
+
}
|
|
4630
|
+
/**
|
|
4631
|
+
* Generate a new table cell based on the original cell type.
|
|
4632
|
+
*
|
|
4633
|
+
* @param {RTETableCellBlock | RTETableHeadCellBlock} originalCell The original table cell block to base the new cell on.
|
|
4634
|
+
* @returns {RTETableCellBlock | RTETableHeadCellBlock} The newly generated table cell block.
|
|
4635
|
+
*/
|
|
4636
|
+
generateTableCell(originalCell) {
|
|
4637
|
+
if (originalCell instanceof RTETableHeadCellBlock) {
|
|
4638
|
+
return RTETableHeadCellBlock.from(getDefaultCellBlockTemplate(originalCell.type));
|
|
4639
|
+
}
|
|
4640
|
+
return RTETableCellBlock.from(getDefaultCellBlockTemplate(originalCell.type));
|
|
4641
|
+
}
|
|
4642
|
+
}
|
|
4643
|
+
|
|
4644
|
+
/**
|
|
4645
|
+
* Strategy to handle the deletion of table column from the parent.
|
|
4646
|
+
*/
|
|
4647
|
+
class DeleteTableColumnStrategy extends TableColumnStrategy {
|
|
4648
|
+
/**
|
|
4649
|
+
* Deletes the specified table column and updates the cursor position.
|
|
4650
|
+
*
|
|
4651
|
+
* @param {DeleteTableColumnAction} action - The action containing the table column to delete.
|
|
4652
|
+
* @param {RTETableBlock} target - The target table block from which the column will be deleted.
|
|
4653
|
+
*/
|
|
4654
|
+
handleAction(action, target) {
|
|
4655
|
+
const [startCellIndex, endCellIndex] = this.getBoundaryCellIndexOfRow(action.tableCellDeleteRange);
|
|
4656
|
+
const allTableRows = getAllTableRows(target);
|
|
4657
|
+
// Find the next focusable cell before deletion
|
|
4658
|
+
const nextFocusableCell = this.findNextFocusableCell(action.tableCellDeleteRange, [startCellIndex, endCellIndex]);
|
|
4659
|
+
allTableRows.forEach((row) => {
|
|
4660
|
+
this.deleteCellsInRow(row, startCellIndex, endCellIndex);
|
|
4661
|
+
});
|
|
4662
|
+
const root = this.getRootContent(target);
|
|
4663
|
+
const nextFocusNode = getFirstNode(nextFocusableCell);
|
|
4664
|
+
if (root && nextFocusNode) {
|
|
4665
|
+
root.apply(new UpdateCursorPositionAction(nextFocusNode));
|
|
4666
|
+
}
|
|
4667
|
+
}
|
|
4668
|
+
/**
|
|
4669
|
+
* Find the next focusable cell either after the deleted range or before it.
|
|
4670
|
+
*
|
|
4671
|
+
* @param {RTETableCellBlock[]} tableCellBlockDeleteRange - The range of table cell blocks to be deleted.
|
|
4672
|
+
* @param {number[]} indexRange - The start and end indices of the cells to be deleted.
|
|
4673
|
+
* @returns {Nullable<RTETableCellBlock | RTETableHeadCellBlock>} The next focusable cell.
|
|
4674
|
+
*/
|
|
4675
|
+
findNextFocusableCell(tableCellBlockDeleteRange, indexRange) {
|
|
4676
|
+
const cellAfterEndOfRange = tableCellBlockDeleteRange[tableCellBlockDeleteRange.length - 1].parent.children[indexRange[indexRange.length - 1] + 1];
|
|
4677
|
+
const cellBeforeStartOfRange = tableCellBlockDeleteRange[0].parent.children[indexRange[0] - 1];
|
|
4678
|
+
return cellAfterEndOfRange !== null && cellAfterEndOfRange !== void 0 ? cellAfterEndOfRange : cellBeforeStartOfRange;
|
|
4679
|
+
}
|
|
4680
|
+
/**
|
|
4681
|
+
* Deletes cells in a given row from start index to end index.
|
|
4682
|
+
*
|
|
4683
|
+
* @param {RTETableRowBlock} row - The table row block.
|
|
4684
|
+
* @param {number} startCellIndex - The start index of the cell to delete.
|
|
4685
|
+
* @param {number} endCellIndex - The end index of the cell to delete.
|
|
4686
|
+
*/
|
|
4687
|
+
deleteCellsInRow(row, startCellIndex, endCellIndex) {
|
|
4688
|
+
const needDeleteCells = [];
|
|
4689
|
+
for (let index = startCellIndex; index <= endCellIndex; index++) {
|
|
4690
|
+
needDeleteCells.push(row.children[index]);
|
|
4691
|
+
}
|
|
4692
|
+
needDeleteCells.forEach((cell) => {
|
|
4693
|
+
row.apply(new RemoveChildrenAction(cell));
|
|
4694
|
+
});
|
|
4695
|
+
}
|
|
4696
|
+
}
|
|
4697
|
+
|
|
4698
|
+
/**
|
|
4699
|
+
* Strategy to handle the selection of a table column.
|
|
4700
|
+
*/
|
|
4701
|
+
class SelectTableColumnStrategy extends TableColumnStrategy {
|
|
4702
|
+
/**
|
|
4703
|
+
* @inheritDoc
|
|
4704
|
+
*/
|
|
4705
|
+
handleAction(action, target) {
|
|
4706
|
+
const [startCellIndex, endCellIndex] = this.getBoundaryCellIndexOfRow(action.tableCellSelectRange);
|
|
4707
|
+
const allTableRows = getAllTableRows(target);
|
|
4708
|
+
const allNeedSelectedCells = [];
|
|
4709
|
+
allTableRows.forEach((row) => {
|
|
4710
|
+
for (let cellIndex = startCellIndex; cellIndex <= endCellIndex; cellIndex++) {
|
|
4711
|
+
const cellToSelect = row.children[cellIndex];
|
|
4712
|
+
allNeedSelectedCells.push(cellToSelect);
|
|
4713
|
+
}
|
|
4714
|
+
});
|
|
4715
|
+
action.selectCellCallback(allNeedSelectedCells);
|
|
4716
|
+
}
|
|
4717
|
+
}
|
|
4718
|
+
|
|
4719
|
+
/**
|
|
4720
|
+
* Interceptor to prevent insertion of non-cell blocks into a table row.
|
|
4721
|
+
*/
|
|
4722
|
+
class PreventRowInsertInterceptor extends ActionHandlerInterceptor {
|
|
4723
|
+
/**
|
|
4724
|
+
* Prevent insertion if any of the children to be inserted is not a table cell block.
|
|
4725
|
+
*
|
|
4726
|
+
* @param {InsertChildrenBeforeAction} action - the action to be intercepted
|
|
4727
|
+
* @returns {boolean} - true if the insertion should be intercepted, false otherwise
|
|
4728
|
+
*/
|
|
4729
|
+
canIntercept(action) {
|
|
4730
|
+
return action.childrenToBeInserted.some((item) => !(item instanceof RTETableCellBlock));
|
|
4731
|
+
}
|
|
4732
|
+
/**
|
|
4733
|
+
* @inheritDoc
|
|
4734
|
+
*/
|
|
4735
|
+
intercept() {
|
|
4736
|
+
}
|
|
4737
|
+
}
|
|
4738
|
+
|
|
4739
|
+
/**
|
|
4740
|
+
* Function extension class for Vega Rich Text Editor.
|
|
4741
|
+
*/
|
|
4742
|
+
class VegaRTETableExtension extends VegaRTEExtension {
|
|
4743
|
+
constructor() {
|
|
4744
|
+
super();
|
|
4745
|
+
this.toolbarButtonRenderer = new RTETableToolbarButtonRenderer();
|
|
4746
|
+
this.tableBlockRenderer = new RTETableBlockRenderer();
|
|
4747
|
+
this.tableRowBlockRenderer = new RTETableRowBlockRenderer();
|
|
4748
|
+
this.tableCellRenderer = new RTETableCellRenderer();
|
|
4749
|
+
this.tableHeadCellRenderer = new RTETableHeadCellRenderer();
|
|
4750
|
+
this.tableSelection = new RTETableSelection();
|
|
4751
|
+
this.registerToolbarButtonRenderer('table', this.toolbarButtonRenderer);
|
|
4752
|
+
this.registerBlockBasicStrategies(RTETableBlock.name);
|
|
4753
|
+
this.registerBlockBasicStrategies(RTETableHeadBlock.name);
|
|
4754
|
+
this.registerBlockBasicStrategies(RTETableHeadCellBlock.name);
|
|
4755
|
+
this.registerBlockBasicStrategies(RTETableRowBlock.name);
|
|
4756
|
+
this.registerBlockBasicStrategies(RTETableCellBlock.name);
|
|
4757
|
+
this.registerBlockBasicStrategies(RTETableBodyBlock.name);
|
|
4758
|
+
this.registerRenderer('table-block', this.tableBlockRenderer);
|
|
4759
|
+
this.registerRenderer('table-head', new RTETableHeadRenderer());
|
|
4760
|
+
this.registerRenderer('table-head-cell', this.tableHeadCellRenderer);
|
|
4761
|
+
this.registerRenderer('table-row', this.tableRowBlockRenderer);
|
|
4762
|
+
this.registerRenderer('table-cell', this.tableCellRenderer);
|
|
4763
|
+
this.registerRenderer('table-body', new RTETableBodyRenderer());
|
|
4764
|
+
this.registerRenderer('table-caption', new RTETableCaptionRenderer());
|
|
4765
|
+
this.registerNode('table-block', RTETableBlock);
|
|
4766
|
+
this.registerNode('table-head', RTETableHeadBlock);
|
|
4767
|
+
this.registerNode('table-head-cell', RTETableHeadCellBlock);
|
|
4768
|
+
this.registerNode('table-row', RTETableRowBlock);
|
|
4769
|
+
this.registerNode('table-cell', RTETableCellBlock);
|
|
4770
|
+
this.registerNode('table-body', RTETableBodyBlock);
|
|
4771
|
+
this.registerNode('table-caption', RTETableCaptionBlock);
|
|
4772
|
+
}
|
|
4773
|
+
/**
|
|
4774
|
+
* Initializes the extension with the given context
|
|
4775
|
+
*
|
|
4776
|
+
* @param {RTEExtensionContext} context - extension context
|
|
4777
|
+
*/
|
|
4778
|
+
initialExtension(context) {
|
|
4779
|
+
super.initialExtension(context);
|
|
4780
|
+
this.tableSelection.init(context);
|
|
4781
|
+
const tableExtensionContext = Object.assign(Object.assign({}, context), { tableSelection: this.tableSelection });
|
|
4782
|
+
this.toolbarButtonRenderer.injectExtensionContext(tableExtensionContext);
|
|
4783
|
+
this.tableBlockRenderer.injectExtensionContext(tableExtensionContext);
|
|
4784
|
+
this.tableCellRenderer.injectExtensionContext(tableExtensionContext);
|
|
4785
|
+
this.tableHeadCellRenderer.injectExtensionContext(tableExtensionContext);
|
|
4786
|
+
}
|
|
4787
|
+
/**
|
|
4788
|
+
* @inheritDoc
|
|
4789
|
+
*/
|
|
4790
|
+
destroyExtension() {
|
|
4791
|
+
this.tableSelection.destroy();
|
|
4792
|
+
}
|
|
4793
|
+
}
|
|
4794
|
+
(() => {
|
|
4795
|
+
const insertTableBlockStrategy = new InsertTableBlockStrategy();
|
|
4796
|
+
const deleteTableBlockStrategy = new DeleteTableBlockStrategy();
|
|
4797
|
+
VegaRTEExtension.registerActionHandleStrategy(VegaRTEContent.name, INSERT_TABLE_BLOCK, insertTableBlockStrategy);
|
|
4798
|
+
VegaRTEExtension.registerActionHandleStrategy(VegaRTEContent.name, DELETE_TABLE_BLOCK, deleteTableBlockStrategy);
|
|
4799
|
+
VegaRTEExtension.registerActionHandleStrategy(RTETableCellBlock.name, DELETE_TABLE_BLOCK, deleteTableBlockStrategy);
|
|
4800
|
+
VegaRTEExtension.registerActionHandleStrategy(RTETableHeadCellBlock.name, DELETE_TABLE_BLOCK, deleteTableBlockStrategy);
|
|
4801
|
+
VegaRTEExtension.registerActionHandleStrategy(RTETextBlock.name, INSERT_TABLE_BLOCK, insertTableBlockStrategy);
|
|
4802
|
+
VegaRTEExtension.registerActionHandleStrategy(RTEImageBlock.name, INSERT_TABLE_BLOCK, insertTableBlockStrategy);
|
|
4803
|
+
VegaRTEExtension.registerActionHandleStrategy(RTETableBlock.name, INSERT_TABLE_ROW, new InsertTableRowStrategy());
|
|
4804
|
+
VegaRTEExtension.registerActionHandleStrategy(RTETableBlock.name, DELETE_TABLE_ROW, new DeleteTableRowStrategy());
|
|
4805
|
+
VegaRTEExtension.registerActionHandleStrategy(RTETableBlock.name, TOGGLE_HEADER_ROW, new ToggleHeaderRowStrategy());
|
|
4806
|
+
VegaRTEExtension.registerActionHandleStrategy(RTETableBlock.name, INSERT_TABLE_COLUMN, new InsertTableColumnStrategy());
|
|
4807
|
+
VegaRTEExtension.registerActionHandleStrategy(RTETableBlock.name, DELETE_TABLE_COLUMN, new DeleteTableColumnStrategy());
|
|
4808
|
+
VegaRTEExtension.registerActionHandleStrategy(RTETableBlock.name, TOGGLE_HEADER_TABLE_COLUMN, new ToggleHeaderTableColumnStrategy());
|
|
4809
|
+
VegaRTEExtension.registerActionHandleStrategy(RTETableBlock.name, SELECT_TABLE_COLUMN, new SelectTableColumnStrategy());
|
|
4810
|
+
VegaRTEExtension.registerActionHandlerInterceptor(RTETextBlock.name, ModifyContentActionType.DELETE_BLOCK_CONTENT, new PreventCellContentDeleteInterceptor());
|
|
4811
|
+
VegaRTEExtension.registerActionHandlerInterceptor(RTETableRowBlock.name, ModifyContentActionType.INSERT_CHILDREN_BEFORE, new PreventRowInsertInterceptor());
|
|
4812
|
+
VegaRTEExtension.registerActionHandlerInterceptor(RTETableCellBlock.name, ModifyContentActionType.DELETE_CHILDREN, new PreventCellChildrenRemoveInterceptor());
|
|
4813
|
+
VegaRTEExtension.registerActionHandlerInterceptor(RTETableHeadCellBlock.name, ModifyContentActionType.DELETE_CHILDREN, new PreventCellChildrenRemoveInterceptor());
|
|
4814
|
+
})();
|
|
4815
|
+
|
|
4816
|
+
export { ActionHandlerInterceptor as A, InsertNodeToNearestRootAction as I, RTETokenToolbarButtonRenderer as R, VegaLoader as V, VegaNotify as a, VegaThemeManager as b, VegaDialog as c, VegaEventManager$1 as d, VegaZIndexManager$1 as e, VegaSkeletonLoader as f, VegaRTETokenExtension as g, VegaRTEFunctionExtension as h, VegaRTETableExtension as i, VegaRTEToolbarButtonRenderer as j, VegaRTEExtension as k, VegaRTEExtensionRenderer as l, RTETokenNode as m, RTETokenNodeRenderer as n, InternalVegaZIndexManager$1 as o };
|