@heartlandone/vega 2.78.0 → 2.79.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cjs/align-left-4a76df69.js +22 -0
- package/dist/cjs/{app-globals-55e26945.js → app-globals-e9fdfbf9.js} +11 -9
- package/dist/cjs/aria-dialog-focusable-trap-slimmer-6faafc3e.js +218 -0
- package/dist/cjs/auto-run-when-re-render-task-queue-slimmer.abstract-5734634d.js +51 -0
- package/dist/cjs/{breakpoints-a8ff22f0.js → breakpoints-1cc2c4c6.js} +1 -1
- package/dist/cjs/{child-nodes-notify-observer-slimmer-ed39283b.js → child-nodes-notify-observer-slimmer-06c78f97.js} +1 -1
- package/dist/cjs/{code-block-1a5fafed.js → code-block-847534e3.js} +38 -7
- package/dist/cjs/{component-value-history-controller-slimmer.abstract-42683f23.js → component-value-history-controller-slimmer.abstract-d7f9812a.js} +34 -56
- package/dist/cjs/{dto-renderer-manager-7557d562.js → content-state-99be18a3.js} +19 -62
- package/dist/cjs/{date-required-rule-ad536cb5.js → date-required-rule-3823d506.js} +1 -1
- package/dist/cjs/{deprecated-property-slimmer-1eb8f031.js → deprecated-property-slimmer-300a3929.js} +1 -1
- package/dist/cjs/{design-token-45ebd5e4.js → design-token-b497bb6e.js} +3 -3
- package/dist/cjs/{dom-node-subject-observer-factory-c62823de.js → dom-node-subject-observer-factory-f7ed3bdc.js} +1 -1
- package/dist/cjs/dto-renderer-manager-ae5fcbba.js +58 -0
- package/dist/cjs/{element-appender-slimmer-16ec8591.js → element-appender-slimmer-eba4f3a2.js} +8 -8
- package/dist/cjs/{event-emit-slimmer-c84121c8.js → event-emit-slimmer-83f8e2bd.js} +1 -1
- package/dist/cjs/{form-field-controller-slimmer-73f5849e.js → form-field-controller-slimmer-93ca7239.js} +6 -6
- package/dist/cjs/{image-annotation-action-f275863e.js → image-annotation-action-9d6af380.js} +4 -32
- package/dist/cjs/index-58ea899e.js +4 -0
- package/dist/cjs/index.cjs.js +41 -36
- package/dist/cjs/{inject-keyboard-manager-6667c0f1.js → inject-keyboard-manager-23d07d87.js} +1 -1
- package/dist/cjs/{internal-translation-controller-24df468f.js → internal-translation-controller-9f58a4e4.js} +2 -0
- package/dist/cjs/{keyboard-manager-7de7ecfd.js → keyboard-manager-3923e29b.js} +2 -2
- package/dist/cjs/{keyboard-manager-slimmer-b44f0dc9.js → keyboard-manager-slimmer-f602725d.js} +1 -1
- package/dist/cjs/loader.cjs.js +26 -21
- package/dist/cjs/{month-view-generator-36c42772.js → month-view-generator-aa8e8e74.js} +1 -1
- package/dist/cjs/{object-e2e28e3d.js → object-b53e9416.js} +6 -4
- package/dist/cjs/{page-resize-observer-slimmer-e050cd26.js → page-resize-observer-slimmer-273d62ef.js} +1 -1
- package/dist/cjs/{public-rules-6c6cb4ac.js → public-rules-1dbda124.js} +12 -12
- package/dist/cjs/{range-e298d4aa.js → range-60fb9dd2.js} +2 -2
- package/dist/cjs/{responsive-format-facade-bddac47c.js → responsive-format-facade-a32cdb67.js} +31 -3
- package/dist/cjs/{rich-text-editor-required-rule-6346a888.js → rich-text-editor-required-rule-b4aab68d.js} +2 -2
- package/dist/cjs/split-cell-operation-190d4a87.js +2411 -0
- package/dist/cjs/{string-format-strategy.abstract-814d66c4.js → string-format-strategy.abstract-730088ee.js} +1 -1
- package/dist/cjs/{string-input-formatter-slimmer-749e3cfe.js → string-input-formatter-slimmer-9d6df58b.js} +4 -4
- package/dist/cjs/{string-mask-strategy-d00871c2.js → string-mask-strategy-b69e3b9e.js} +2 -2
- package/dist/cjs/{style-formatter-94c1a1ff.js → style-formatter-9d8a4ad2.js} +2 -2
- package/dist/cjs/{sub-state-notify-slimmer-ac1dae32.js → sub-state-notify-slimmer-c80b9d21.js} +2 -2
- package/dist/cjs/{sub-state-observer-slimmer-e692d849.js → sub-state-observer-slimmer-15740c97.js} +3 -3
- package/dist/cjs/{time-required-rule-f1f3c8c2.js → time-required-rule-6524b650.js} +1 -1
- package/dist/cjs/token-extension-b7c4ea17.js +7438 -0
- package/dist/cjs/{translation-slimmer-3fa03d81.js → translation-slimmer-c069ca84.js} +1 -1
- package/dist/cjs/{type-guard-a0d9ff1f.js → type-guard-2a46bca5.js} +12 -2
- package/dist/cjs/{ui-024696c0.js → ui-32120990.js} +3 -0
- package/dist/cjs/{ui-234ea151.js → ui-b3db0122.js} +21 -0
- package/dist/cjs/{valid-credit-card-number-rule-cba7d66a.js → valid-credit-card-number-rule-8eb02ea7.js} +1 -1
- package/dist/cjs/vega-accordion.cjs.entry.js +9 -9
- package/dist/cjs/vega-app-header-button.cjs.entry.js +10 -10
- package/dist/cjs/vega-backdrop.cjs.entry.js +2 -2
- package/dist/cjs/vega-banner.cjs.entry.js +3 -3
- package/dist/cjs/vega-box.cjs.entry.js +9 -9
- package/dist/cjs/vega-breadcrumb.cjs.entry.js +3 -3
- package/dist/cjs/vega-button-circle.cjs.entry.js +10 -10
- package/dist/cjs/vega-button-group_2.cjs.entry.js +6 -6
- package/dist/cjs/vega-button-link.cjs.entry.js +3 -3
- package/dist/cjs/vega-button.cjs.entry.js +10 -10
- package/dist/cjs/vega-calendar_4.cjs.entry.js +226 -165
- package/dist/cjs/vega-card.cjs.entry.js +7 -7
- package/dist/cjs/vega-carousel.cjs.entry.js +11 -11
- package/dist/cjs/vega-checkbox_2.cjs.entry.js +11 -11
- package/dist/cjs/vega-chip.cjs.entry.js +10 -10
- package/dist/cjs/vega-code-block.cjs.entry.js +16 -15
- package/dist/cjs/vega-color-picker.cjs.entry.js +10 -10
- package/dist/cjs/vega-combo-box.cjs.entry.js +13 -13
- package/dist/cjs/vega-date-picker_2.cjs.entry.js +104 -31
- package/dist/cjs/vega-dialog_2.cjs.entry.js +52 -15
- package/dist/cjs/vega-divider.cjs.entry.js +7 -7
- package/dist/cjs/vega-dropdown_5.cjs.entry.js +17 -17
- 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 +11 -11
- package/dist/cjs/vega-flag-icon.cjs.entry.js +6 -6
- package/dist/cjs/vega-flex.cjs.entry.js +9 -9
- package/dist/cjs/vega-font.cjs.entry.js +8 -8
- package/dist/cjs/vega-form.cjs.entry.js +13 -13
- package/dist/cjs/vega-grid.cjs.entry.js +9 -8
- package/dist/cjs/vega-icon.cjs.entry.js +7 -7
- package/dist/cjs/vega-image-uploader.cjs.entry.js +13 -13
- package/dist/cjs/vega-input-credit-card.cjs.entry.js +14 -14
- package/dist/cjs/vega-input-numeric.cjs.entry.js +14 -14
- package/dist/cjs/vega-input-passcode.cjs.entry.js +13 -13
- package/dist/cjs/vega-input-phone-number.cjs.entry.js +12 -12
- package/dist/cjs/vega-input-range.cjs.entry.js +11 -11
- package/dist/cjs/vega-input-select.cjs.entry.js +13 -13
- package/dist/cjs/vega-input.cjs.entry.js +30 -17
- package/dist/cjs/{vega-internal-event-id-e0aeac45.js → vega-internal-event-id-67bb91c1.js} +4 -0
- package/dist/cjs/vega-item-toggle.cjs.entry.js +6 -6
- package/dist/cjs/vega-left-nav_5.cjs.entry.js +15 -15
- package/dist/cjs/vega-loader-wrapper_2.cjs.entry.js +7 -7
- package/dist/cjs/vega-page-notification_2.cjs.entry.js +2 -2
- package/dist/cjs/vega-pagination-page-selector-mobile.cjs.entry.js +3 -3
- package/dist/cjs/vega-pagination-page-size-selector-mobile.cjs.entry.js +5 -5
- package/dist/cjs/vega-pagination.cjs.entry.js +11 -11
- package/dist/cjs/vega-popover_2.cjs.entry.js +15 -14
- package/dist/cjs/vega-progress-tracker_2.cjs.entry.js +14 -14
- package/dist/cjs/vega-radio_2.cjs.entry.js +14 -14
- package/dist/cjs/vega-rich-text-content.cjs.entry.js +22 -24
- package/dist/cjs/vega-rich-text-editor_4.cjs.entry.js +217 -252
- package/dist/cjs/vega-rich-text-table-properties_3.cjs.entry.js +1527 -0
- package/dist/cjs/vega-segment-control.cjs.entry.js +6 -6
- package/dist/cjs/vega-selection-chip_2.cjs.entry.js +13 -13
- package/dist/cjs/vega-selection-tile_2.cjs.entry.js +12 -12
- package/dist/cjs/vega-sidenav_3.cjs.entry.js +12 -12
- package/dist/cjs/vega-signature-capture.cjs.entry.js +15 -15
- package/dist/cjs/vega-stepper.cjs.entry.js +10 -10
- package/dist/cjs/vega-tab-group_2.cjs.entry.js +6 -6
- package/dist/cjs/vega-table_11.cjs.entry.js +14 -14
- package/dist/cjs/vega-text.cjs.entry.js +4 -4
- package/dist/cjs/vega-textarea.cjs.entry.js +10 -10
- package/dist/cjs/vega-time-picker_2.cjs.entry.js +62 -20
- package/dist/cjs/vega-toggle-switch.cjs.entry.js +10 -10
- package/dist/cjs/vega-tooltip_2.cjs.entry.js +14 -14
- package/dist/cjs/vega.cjs.js +26 -21
- package/dist/cjs/{wait-for-component-did-render-cbebfc33.js → wait-for-component-did-render-9e41b39e.js} +2 -2
- package/dist/collection/collection-manifest.json +10 -0
- package/dist/collection/components/vega-backdrop/slimmers/renerers/vega-backdrop-renderer.js +1 -1
- package/dist/collection/components/vega-calendar/slimmers/common/controllers/vega-calendar-day-view-focus-slimmer.js +34 -0
- package/dist/collection/components/vega-calendar/slimmers/common/renderers/vega-calendar-switch-panel.js +1 -1
- package/dist/collection/components/vega-calendar/slimmers/day-view/renderers/vega-calendar-view-with-time-renderer.js +2 -1
- package/dist/collection/components/vega-calendar/slimmers/month-view/renderers/vega-calendar-month-view-renderer.js +28 -7
- package/dist/collection/components/vega-calendar/vega-calendar-event-preview/slimmers/renderers/vega-calendar-event-preview-detail-renderer.js +4 -1
- package/dist/collection/components/vega-calendar/vega-calendar.js +5 -0
- package/dist/collection/components/vega-date-picker/slimmers/controllers/vega-date-picker-calendar-open-state-controller.js +13 -1
- package/dist/collection/components/vega-date-picker/slimmers/renderers/vega-date-picker-calendar-renderer.js +28 -2
- package/dist/collection/components/vega-date-picker/slimmers/renderers/vega-date-picker-input-renderer-base.abstract.js +7 -1
- package/dist/collection/components/vega-date-picker/slimmers/renderers/vega-date-picker-range-input-renderer.js +15 -2
- package/dist/collection/components/vega-date-picker/slimmers/renderers/vega-date-picker-renderer.js +1 -1
- package/dist/collection/components/vega-date-picker/slimmers/renderers/vega-date-picker-single-input-renderer.js +18 -1
- package/dist/collection/components/vega-grid/vega-grid.css +72 -0
- package/dist/collection/components/vega-grid/vega-grid.js +30 -0
- package/dist/collection/components/vega-input/slimmers/renderers/vega-input-input-renderer.js +4 -1
- package/dist/collection/components/vega-input/vega-input.js +34 -0
- package/dist/collection/components/vega-modal/slimmers/controllers/vega-modal-open-state-controller.js +34 -1
- package/dist/collection/components/vega-modal/slimmers/renderers/vega-modal-renderer.js +7 -2
- package/dist/collection/components/vega-popover/slimmers/controllers/vega-popover-appender-controller.js +1 -0
- package/dist/collection/components/vega-rich-text-content/vega-rich-text-content.js +9 -1
- package/dist/collection/components/vega-rich-text-editor/dto/action-handle-strategies/action-handle-strategy.abstract.js +10 -0
- package/dist/collection/components/vega-rich-text-editor/dto/blocks/block.abstract.js +24 -2
- package/dist/collection/components/vega-rich-text-editor/dto/filter-styles-strategies/filter-styles-strategy-registry.js +35 -0
- package/dist/collection/components/vega-rich-text-editor/dto/filter-styles-strategies/filter-styles-strategy.abstract.js +31 -0
- package/dist/collection/components/vega-rich-text-editor/dto/renderers/nodes/text-node-renderer.js +0 -10
- package/dist/collection/components/vega-rich-text-editor/extensions/base-extension-renderer.js +2 -1
- package/dist/collection/components/vega-rich-text-editor/extensions/base-toolbar-button-renderer.js +10 -5
- package/dist/collection/components/vega-rich-text-editor/extensions/extension.abstract.js +18 -1
- package/dist/collection/components/vega-rich-text-editor/extensions/table/action-handler-interceptors/prevent-cell-children-remove-interceptor.js +42 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/action-handler-interceptors/prevent-cell-content-delete-interceptor.js +26 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/action-handler-interceptors/prevent-row-insert-interceptor.js +23 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/action-handler-interceptors/prevent-table-insert-paragraph-interceptor.js +55 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/action-handler-strategies/create-segment-table-cell-strategy.js +33 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/action-handler-strategies/delete-table-block-strategy.js +25 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/action-handler-strategies/delete-table-column-strategy.js +176 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/action-handler-strategies/delete-table-row-strategy.js +154 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/action-handler-strategies/insert-table-block-strategy.js +54 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/action-handler-strategies/insert-table-column-strategy.js +163 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/action-handler-strategies/insert-table-row-into-different-section-strategy.js +83 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/action-handler-strategies/insert-table-row-into-same-section-strategy.js +55 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/action-handler-strategies/merge-cells-strategy.js +120 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/action-handler-strategies/replace-table-cell-strategy.js +21 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/action-handler-strategies/select-table-column-strategy.js +33 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/action-handler-strategies/split-cell-horizontally-strategy.js +143 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/action-handler-strategies/split-cell-vertically-strategy.js +80 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/action-handler-strategies/split-table-cell-strategy.js +45 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/action-handler-strategies/table-column-strategy.abstract.js +27 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/action-handler-strategies/table-row-strategy.abstract.js +296 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/action-handler-strategies/toggle-header-row-strategy.js +274 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/action-handler-strategies/toggle-header-table-column-strategy.js +159 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/action-handler-strategies/update-table-cell-properties-strategy.js +33 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/action-handler-strategies/update-table-properties-strategy.js +36 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/actions/create-segment-table-cell-action.js +13 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/actions/delete-table-block-action.js +13 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/actions/delete-table-column-action.js +13 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/actions/delete-table-row-action.js +18 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/actions/insert-table-block-action.js +13 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/actions/insert-table-column-action.js +19 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/actions/insert-table-row-into-different-section-action.js +21 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/actions/insert-table-row-into-same-section-action.js +27 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/actions/merge-cells-action.js +17 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/actions/replace-table-cell-action.js +13 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/actions/select-table-column-action.js +13 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/actions/split-cell-horizontally-action.js +12 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/actions/split-cell-vertically-action.js +12 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/actions/split-table-cell-action.js +13 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/actions/table-annotations-action.js +18 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/actions/table-caption-action.js +13 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/actions/table-cell-annotations-action.js +28 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/actions/table-head-cell-annotations-action.js +17 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/actions/toggle-header-row-action.js +13 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/actions/toggle-header-table-column-action.js +15 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/actions/update-table-properties-action.js +38 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/annotation-handler/table-annotation-handler-base.js +78 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/annotation-handler/table-annotation-handler.js +69 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/annotation-handler/table-cell-annotation-handler.js +108 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/annotation-handler/table-head-cell-annotation-handler.js +14 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/annotations/table-annotation.js +106 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/annotations/table-caption-annotation.js +69 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/annotations/table-cell-annotation.js +192 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/annotations/table-color-annotation.js +66 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/annotations/table-head-cell-annotation.js +56 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/constants/styles.constants.js +27 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/dto/table-block.js +119 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/dto/table-body-block.js +56 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/dto/table-caption-block.js +69 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/dto/table-cell-block.js +97 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/dto/table-head-block.js +60 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/dto/table-head-cell-block.js +53 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/dto/table-row-block.js +60 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/element-to-dto-strategies/caption-to-caption-block-strategy.js +71 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/element-to-dto-strategies/table-to-table-block-strategy.js +42 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/element-to-dto-strategies/tbody-to-table-body-block-strategy.js +42 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/element-to-dto-strategies/td-to-table-cell-block-strategy.js +93 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/element-to-dto-strategies/thead-to-table-head-block-strategy.js +42 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/element-to-dto-strategies/tr-to-table-row-block-strategy.js +42 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/renderers/table-body-renderer.js +15 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/renderers/table-caption-renderer.js +22 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/renderers/table-cell-renderer.js +72 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/renderers/table-dynamic-popover-renderer.js +263 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/renderers/table-head-cell-renderer.js +12 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/renderers/table-head-renderer.js +15 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/renderers/table-popover-base-renderer.js +19 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/renderers/table-renderer.js +116 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/renderers/table-row-renderer.js +15 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/renderers/table-setting-popover-renderer.js +148 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/renderers/table-toolbar-popover-renderer.js +178 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/setting-event-handlers/caption-operation.js +78 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/setting-event-handlers/cell-properties-cancel-event-handler.js +17 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/setting-event-handlers/cell-properties-change-event-handler.js +15 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/setting-event-handlers/cell-properties-save-event-handler.js +19 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/setting-event-handlers/cell-properties.js +136 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/setting-event-handlers/column-operation.js +109 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/setting-event-handlers/merge-cells-operation.js +100 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/setting-event-handlers/row-operation.js +160 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/setting-event-handlers/setting-event-handler.abstract.js +45 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/setting-event-handlers/split-cell-operation.js +57 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/setting-event-handlers/table-properties-cancel-event-handler.js +19 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/setting-event-handlers/table-properties-change-event-handler.js +20 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/setting-event-handlers/table-properties-save-event-handler.js +20 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/setting-event-handlers/table-properties.js +50 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/table-extension.js +174 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/table-icon.js +3 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/table-selection.js +460 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/table-toolbar-button-renderer.js +61 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/utils/table-color-manager.js +55 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/utils/utils.js +436 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/vega-rich-text-table-properties/assets/align-bottom.js +3 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/vega-rich-text-table-properties/assets/align-middle.js +3 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/vega-rich-text-table-properties/assets/align-top.js +3 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/vega-rich-text-table-properties/assets/objects-align-center-horizontal.js +3 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/vega-rich-text-table-properties/assets/objects-align-left.js +3 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/vega-rich-text-table-properties/assets/objects-align-right.js +3 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/vega-rich-text-table-properties/slimmers/controllers/vega-rich-text-table-properties-color-controller.js +58 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/vega-rich-text-table-properties/slimmers/renderers/vega-rich-text-cell-properties-form-field-renderer.js +106 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/vega-rich-text-table-properties/slimmers/renderers/vega-rich-text-table-properties-basic-form-field-renderer.abstract.js +291 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/vega-rich-text-table-properties/slimmers/renderers/vega-rich-text-table-properties-form-field-renderer.js +58 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/vega-rich-text-table-properties/slimmers/renderers/vega-rich-text-table-properties-form-renderer.js +111 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/vega-rich-text-table-properties/vega-rich-text-table-properties.css +149 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/vega-rich-text-table-properties/vega-rich-text-table-properties.js +251 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/vega-rich-text-table-selection-widget/slimmers/controllers/selection-widget-keyboard-controller.js +36 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/vega-rich-text-table-selection-widget/slimmers/renderers/selection-widget-renderer.js +83 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/vega-rich-text-table-selection-widget/vega-rich-text-table-selection-widget.css +41 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/vega-rich-text-table-selection-widget/vega-rich-text-table-selection-widget.js +80 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/vega-rich-text-table-setting/assets/icon.js +20 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/vega-rich-text-table-setting/slimmers/renderers/caption-button-slimmer.js +27 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/vega-rich-text-table-setting/slimmers/renderers/cell-properties-button-slimmer.js +26 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/vega-rich-text-table-setting/slimmers/renderers/column-button-slimmer.js +90 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/vega-rich-text-table-setting/slimmers/renderers/merge-cells-button-slimmer.js +117 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/vega-rich-text-table-setting/slimmers/renderers/row-button-slimmer.js +103 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/vega-rich-text-table-setting/slimmers/renderers/table-properties-button-slimmer.js +26 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/vega-rich-text-table-setting/slimmers/renderers/table-setting-button-slimmer.abstract.js +76 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/vega-rich-text-table-setting/slimmers/renderers/vega-rich-text-table-setting-renderer.js +55 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/vega-rich-text-table-setting/vega-rich-text-table-setting.css +23 -0
- package/dist/collection/components/vega-rich-text-editor/extensions/table/vega-rich-text-table-setting/vega-rich-text-table-setting.js +222 -0
- package/dist/collection/components/vega-rich-text-editor/helpers/extension-context-manager.test.js +2 -0
- package/dist/collection/components/vega-rich-text-editor/public-api.js +1 -0
- package/dist/collection/components/vega-rich-text-editor/slimmers/controllers/extension-controller.js +35 -6
- package/dist/collection/components/vega-rich-text-editor/slimmers/controllers/helper/element-to-dto-strategy/annotation-handler/html-element-to-annotation-generator.js +10 -0
- package/dist/collection/components/vega-rich-text-editor/slimmers/controllers/helper/input-event-handler/insert-paragraph-handler.js +2 -1
- package/dist/collection/components/vega-rich-text-editor/slimmers/controllers/selection-controller.js +26 -2
- package/dist/collection/components/vega-rich-text-editor/test/dto/content-state.test.js +252 -0
- package/dist/collection/components/vega-rich-text-editor/test/extensions/extension-test-utils.js +2 -0
- package/dist/collection/components/vega-rich-text-editor/test/extensions/table/annotation-handler/annotation-handler-registration.test.js +164 -0
- package/dist/collection/components/vega-rich-text-editor/test/extensions/table/annotation-handler/table-annotation-handler.test.js +298 -0
- package/dist/collection/components/vega-rich-text-editor/test/extensions/table/annotation-handler/table-cell-annotation-handler.test.js +316 -0
- package/dist/collection/components/vega-rich-text-editor/test/extensions/table/annotation-handler/table-head-cell-annotation-handler.test.js +411 -0
- package/dist/collection/components/vega-rich-text-editor/test/extensions/table/caption-operation.test.js +99 -0
- package/dist/collection/components/vega-rich-text-editor/test/extensions/table/table-annotation.test.js +181 -0
- package/dist/collection/components/vega-rich-text-editor/test/extensions/table/table-caption-annotations.test.js +84 -0
- package/dist/collection/components/vega-rich-text-editor/test/extensions/table/table-cell-annotation.test.js +331 -0
- package/dist/collection/components/vega-rich-text-editor/test/extensions/table/table-color-annotation.test.js +32 -0
- package/dist/collection/components/vega-rich-text-editor/test/extensions/table/table-dto.test.js +1094 -0
- package/dist/collection/components/vega-rich-text-editor/test/extensions/table/table-element-to-dto-strategies.test.js +1590 -0
- package/dist/collection/components/vega-rich-text-editor/test/extensions/table/table-test-utils.js +172 -0
- package/dist/collection/components/vega-rich-text-editor/test/filter-styles-strategies/filter-styles-strategy.test.js +129 -0
- package/dist/collection/components/vega-rich-text-editor/test/spec-utils.js +5 -2
- package/dist/collection/components/vega-rich-text-editor/vega-rich-text-editor.css +4 -0
- package/dist/collection/components/vega-rich-text-editor/vega-rich-text-editor.js +0 -5
- package/dist/collection/components/vega-time-picker/slimmers/renderers/vega-time-picker-range-input-renderer.js +5 -2
- package/dist/collection/components/vega-time-picker/slimmers/renderers/vega-time-picker-single-input-renderer.js +4 -1
- package/dist/collection/components/vega-time-picker/vega-time-picker.js +36 -0
- package/dist/collection/constants/runtime-metrics-payload-definition/vega-time-picker/runtime-metrics-payload-definition.js +24 -0
- package/dist/collection/constants/ui.js +2 -0
- package/dist/collection/global/scripts/before-vega-load.js +2 -0
- package/dist/collection/helpers/event-manager/event-id/vega-internal-event-id.js +2 -0
- package/dist/collection/helpers/formatter/responsive-map-formatter/responsive-format-facade.js +3 -0
- package/dist/collection/helpers/formatter/responsive-map-formatter/responsive-grid-justify-items-formatter.js +29 -0
- package/dist/collection/helpers/formatter/test/responsive-map-formatter/responsive-grid-justify-items-formatter.test.js +19 -0
- package/dist/collection/helpers/slimmers/aria-dialog-focusable-trap-slimmer.js +213 -0
- package/dist/collection/helpers/slimmers/element-appender/body-positioned-wrapper/test/vega-popover-wrapper.test.js +66 -0
- package/dist/collection/helpers/slimmers/position-calculation/base-position-calculation-strategy.js +1 -1
- package/dist/collection/helpers/slimmers/position-calculation/test/body-position-calculation-strategy.test.js +49 -3
- package/dist/collection/helpers/slimmers/position-calculation/test/screen-position-calculation-strategy.test.js +18 -0
- package/dist/collection/helpers/slimmers/test/aria-dialog-focusable-trap-slimmer.test.js +375 -0
- package/dist/collection/helpers/translation/locales/en.js +2 -0
- package/dist/collection/helpers/translation/tests/internal-translation-controller.test.js +2 -0
- package/dist/collection/types/type-guard.js +10 -1
- package/dist/collection/utils/e2e-utils.js +51 -3
- package/dist/collection/utils/object.js +6 -4
- package/dist/collection/utils/spec-utils.js +4 -3
- package/dist/collection/utils/ui.js +20 -0
- package/dist/esm/align-left-7f959adf.js +17 -0
- package/dist/esm/{app-globals-3b97bb20.js → app-globals-776ccaa3.js} +8 -6
- package/dist/esm/aria-dialog-focusable-trap-slimmer-cc98a7a4.js +216 -0
- package/dist/esm/auto-run-when-re-render-task-queue-slimmer.abstract-27820d4c.js +49 -0
- package/dist/esm/{breakpoints-13353e09.js → breakpoints-332702ed.js} +1 -1
- package/dist/esm/{child-nodes-event-prevent-slimmer-4feabae0.js → child-nodes-event-prevent-slimmer-2ecc3e1f.js} +1 -1
- package/dist/esm/{child-nodes-notify-observer-slimmer-541dd6a4.js → child-nodes-notify-observer-slimmer-c7297b9f.js} +1 -1
- package/dist/esm/{code-block-d65bab61.js → code-block-58d1dbe5.js} +39 -8
- package/dist/esm/{component-value-history-controller-slimmer.abstract-556fcf2a.js → component-value-history-controller-slimmer.abstract-5beb8acb.js} +35 -56
- package/dist/esm/{dto-renderer-manager-73df5cbe.js → content-state-dad1fd71.js} +17 -62
- package/dist/esm/{date-required-rule-4ffd9cae.js → date-required-rule-4c40a4eb.js} +1 -1
- package/dist/esm/{deprecated-property-slimmer-2c14df89.js → deprecated-property-slimmer-ea34fa7b.js} +1 -1
- package/dist/esm/{design-token-b518a2aa.js → design-token-9c4eb6b1.js} +3 -3
- package/dist/esm/{dom-node-subject-observer-factory-82f346e3.js → dom-node-subject-observer-factory-94b2e2c3.js} +1 -1
- package/dist/esm/dto-renderer-manager-12bc9121.js +56 -0
- package/dist/esm/{element-appender-slimmer-36b7a572.js → element-appender-slimmer-fde815dc.js} +8 -8
- package/dist/esm/{event-emit-slimmer-f879fd58.js → event-emit-slimmer-b236945b.js} +2 -2
- package/dist/esm/{form-field-controller-slimmer-9a880420.js → form-field-controller-slimmer-00fa3678.js} +6 -6
- package/dist/esm/{image-annotation-action-eb3dcad5.js → image-annotation-action-1ec7b461.js} +5 -32
- package/dist/esm/index-090d31ca.js +4 -0
- package/dist/esm/index.js +30 -26
- package/dist/esm/{inject-keyboard-manager-e5481833.js → inject-keyboard-manager-784b1364.js} +1 -1
- package/dist/esm/{internal-translation-controller-0787a7a7.js → internal-translation-controller-b08aa9ab.js} +2 -0
- package/dist/esm/{internal-vega-event-manager-3aebbe55.js → internal-vega-event-manager-59f5bd47.js} +1 -1
- package/dist/esm/{keyboard-manager-4dfc625f.js → keyboard-manager-e020039f.js} +2 -2
- package/dist/esm/{keyboard-manager-slimmer-87bf68f1.js → keyboard-manager-slimmer-4722d20c.js} +1 -1
- package/dist/esm/loader.js +26 -21
- package/dist/esm/{month-view-generator-94134ec5.js → month-view-generator-6fe1f491.js} +1 -1
- package/dist/esm/{object-66c37948.js → object-0c277f57.js} +6 -4
- package/dist/esm/{page-resize-observer-slimmer-e0505250.js → page-resize-observer-slimmer-e24d36c5.js} +1 -1
- package/dist/esm/{public-rules-49912d52.js → public-rules-1626fb0d.js} +12 -12
- package/dist/esm/{range-0a22b512.js → range-4f9bf69d.js} +2 -2
- package/dist/esm/{responsive-format-facade-b3799ff9.js → responsive-format-facade-e8534e59.js} +31 -3
- package/dist/esm/{rich-text-editor-required-rule-d86e3a51.js → rich-text-editor-required-rule-c391aeb6.js} +1 -1
- package/dist/esm/split-cell-operation-55cd9fae.js +2360 -0
- package/dist/esm/{string-format-strategy.abstract-e40a0df7.js → string-format-strategy.abstract-8c48e515.js} +1 -1
- package/dist/esm/{string-input-formatter-slimmer-076764fc.js → string-input-formatter-slimmer-519480ce.js} +4 -4
- package/dist/esm/{string-mask-strategy-df1f5707.js → string-mask-strategy-8070817e.js} +2 -2
- package/dist/esm/{style-formatter-95255392.js → style-formatter-7afd0680.js} +2 -2
- package/dist/esm/{sub-state-notify-slimmer-f4b3b0b9.js → sub-state-notify-slimmer-54531808.js} +2 -2
- package/dist/esm/{sub-state-observer-slimmer-058feaf0.js → sub-state-observer-slimmer-b3a773c5.js} +3 -3
- package/dist/esm/{time-required-rule-b4af75ae.js → time-required-rule-2569e5ad.js} +1 -1
- package/dist/esm/token-extension-612575cb.js +7417 -0
- package/dist/esm/{translation-slimmer-e788cae4.js → translation-slimmer-35b1d0fa.js} +1 -1
- package/dist/esm/{type-guard-f69d2935.js → type-guard-c20cbbff.js} +12 -3
- package/dist/esm/{ui-41f725b7.js → ui-93922c59.js} +3 -1
- package/dist/esm/{ui-ee31416b.js → ui-ac244bf0.js} +21 -1
- package/dist/esm/{valid-credit-card-number-rule-c023326d.js → valid-credit-card-number-rule-b9c3c2f8.js} +1 -1
- package/dist/esm/vega-accordion.entry.js +11 -11
- package/dist/esm/vega-app-header-button.entry.js +13 -13
- package/dist/esm/vega-backdrop.entry.js +2 -2
- package/dist/esm/vega-banner.entry.js +5 -5
- package/dist/esm/vega-box.entry.js +9 -9
- package/dist/esm/vega-breadcrumb.entry.js +6 -6
- package/dist/esm/vega-button-circle.entry.js +13 -13
- package/dist/esm/vega-button-group_2.entry.js +9 -9
- package/dist/esm/vega-button-link.entry.js +6 -6
- package/dist/esm/vega-button.entry.js +13 -13
- package/dist/esm/vega-calendar_4.entry.js +229 -168
- package/dist/esm/vega-card.entry.js +7 -7
- package/dist/esm/vega-carousel.entry.js +13 -13
- package/dist/esm/vega-checkbox_2.entry.js +14 -14
- package/dist/esm/vega-chip.entry.js +13 -13
- package/dist/esm/vega-code-block.entry.js +18 -17
- package/dist/esm/vega-color-picker.entry.js +12 -12
- package/dist/esm/vega-combo-box.entry.js +16 -16
- package/dist/esm/vega-date-picker_2.entry.js +107 -34
- package/dist/esm/vega-dialog_2.entry.js +55 -18
- package/dist/esm/vega-divider.entry.js +7 -7
- package/dist/esm/vega-dropdown_5.entry.js +20 -20
- package/dist/esm/vega-env-manager-8f8dc473.js +2 -2
- package/dist/esm/{vega-event-id-fdc58a67.js → vega-event-id-4ede557a.js} +1 -1
- package/dist/esm/vega-field-label.entry.js +5 -5
- package/dist/esm/vega-file-uploader.entry.js +13 -13
- package/dist/esm/vega-flag-icon.entry.js +6 -6
- package/dist/esm/vega-flex.entry.js +9 -9
- package/dist/esm/vega-font.entry.js +8 -8
- package/dist/esm/vega-form.entry.js +16 -16
- package/dist/esm/vega-grid.entry.js +9 -8
- package/dist/esm/vega-icon.entry.js +7 -7
- package/dist/esm/vega-image-uploader.entry.js +16 -16
- package/dist/esm/vega-input-credit-card.entry.js +17 -17
- package/dist/esm/vega-input-numeric.entry.js +17 -17
- package/dist/esm/vega-input-passcode.entry.js +16 -16
- package/dist/esm/vega-input-phone-number.entry.js +15 -15
- package/dist/esm/vega-input-range.entry.js +14 -14
- package/dist/esm/vega-input-select.entry.js +16 -16
- package/dist/esm/vega-input.entry.js +32 -19
- package/dist/esm/{vega-internal-event-id-12783594.js → vega-internal-event-id-8002b179.js} +3 -1
- package/dist/esm/vega-item-toggle.entry.js +8 -8
- package/dist/esm/vega-left-nav_5.entry.js +17 -17
- package/dist/esm/vega-loader-wrapper_2.entry.js +7 -7
- package/dist/esm/vega-page-notification_2.entry.js +3 -3
- package/dist/esm/vega-pagination-page-selector-mobile.entry.js +6 -6
- package/dist/esm/vega-pagination-page-size-selector-mobile.entry.js +6 -6
- package/dist/esm/vega-pagination.entry.js +14 -14
- package/dist/esm/vega-popover_2.entry.js +17 -16
- package/dist/esm/vega-progress-tracker_2.entry.js +16 -16
- package/dist/esm/vega-radio_2.entry.js +17 -17
- package/dist/esm/vega-rich-text-content.entry.js +21 -23
- package/dist/esm/vega-rich-text-editor_4.entry.js +196 -231
- package/dist/esm/vega-rich-text-table-properties_3.entry.js +1521 -0
- package/dist/esm/vega-segment-control.entry.js +8 -8
- package/dist/esm/vega-selection-chip_2.entry.js +16 -16
- package/dist/esm/vega-selection-tile_2.entry.js +15 -15
- package/dist/esm/vega-sidenav_3.entry.js +14 -14
- package/dist/esm/vega-signature-capture.entry.js +17 -17
- package/dist/esm/vega-stepper.entry.js +13 -13
- package/dist/esm/vega-tab-group_2.entry.js +9 -9
- package/dist/esm/vega-table_11.entry.js +17 -17
- package/dist/esm/vega-text.entry.js +4 -4
- package/dist/esm/vega-textarea.entry.js +13 -13
- package/dist/esm/vega-time-picker_2.entry.js +65 -23
- package/dist/esm/vega-toggle-switch.entry.js +12 -12
- package/dist/esm/vega-tooltip_2.entry.js +14 -14
- package/dist/esm/vega.js +26 -21
- package/dist/esm/{wait-for-component-did-render-4d0a3428.js → wait-for-component-did-render-1e62d6f7.js} +2 -2
- package/dist/sri/vega-sri-manifest.json +384 -360
- package/dist/types/components/vega-calendar/slimmers/common/controllers/vega-calendar-day-view-focus-slimmer.d.ts +15 -0
- package/dist/types/components/vega-calendar/slimmers/month-view/renderers/vega-calendar-month-view-renderer.d.ts +3 -0
- package/dist/types/components/vega-calendar/vega-calendar-event-preview/slimmers/renderers/vega-calendar-event-preview-detail-renderer.d.ts +1 -0
- package/dist/types/components/vega-calendar/vega-calendar.d.ts +2 -0
- package/dist/types/components/vega-date-picker/slimmers/controllers/vega-date-picker-calendar-open-state-controller.d.ts +2 -0
- package/dist/types/components/vega-date-picker/slimmers/renderers/vega-date-picker-calendar-renderer.d.ts +5 -0
- package/dist/types/components/vega-date-picker/slimmers/renderers/vega-date-picker-input-renderer-base.abstract.d.ts +2 -0
- package/dist/types/components/vega-date-picker/slimmers/renderers/vega-date-picker-range-input-renderer.d.ts +3 -0
- package/dist/types/components/vega-date-picker/slimmers/renderers/vega-date-picker-single-input-renderer.d.ts +5 -0
- package/dist/types/components/vega-grid/vega-grid.d.ts +13 -1
- package/dist/types/components/vega-input/slimmers/renderers/vega-input-input-renderer.d.ts +1 -0
- package/dist/types/components/vega-input/vega-input.d.ts +10 -0
- package/dist/types/components/vega-modal/slimmers/controllers/vega-modal-open-state-controller.d.ts +13 -0
- package/dist/types/components/vega-modal/slimmers/renderers/vega-modal-renderer.d.ts +1 -0
- package/dist/types/components/vega-popover/slimmers/controllers/vega-popover-appender-controller.d.ts +1 -0
- package/dist/types/components/vega-rich-text-content/vega-rich-text-content.d.ts +3 -0
- package/dist/types/components/vega-rich-text-editor/dto/action-handle-strategies/action-handle-strategy.abstract.d.ts +7 -0
- package/dist/types/components/vega-rich-text-editor/dto/annotations/annotation.abstract.d.ts +2 -5
- package/dist/types/components/vega-rich-text-editor/dto/annotations/block-annotation.abstract.d.ts +3 -3
- package/dist/types/components/vega-rich-text-editor/dto/annotations/custom-attribute-annotation.d.ts +1 -1
- package/dist/types/components/vega-rich-text-editor/dto/blocks/block.abstract.d.ts +10 -6
- package/dist/types/components/vega-rich-text-editor/dto/filter-styles-strategies/filter-styles-strategy-registry.d.ts +28 -0
- package/dist/types/components/vega-rich-text-editor/dto/filter-styles-strategies/filter-styles-strategy.abstract.d.ts +25 -0
- package/dist/types/components/vega-rich-text-editor/dto/renderers/nodes/text-node-renderer.d.ts +0 -2
- package/dist/types/components/vega-rich-text-editor/extensions/extension.abstract.d.ts +15 -2
- package/dist/types/components/vega-rich-text-editor/extensions/table/action-handler-interceptors/prevent-cell-children-remove-interceptor.d.ts +25 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/action-handler-interceptors/prevent-cell-content-delete-interceptor.d.ts +20 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/action-handler-interceptors/prevent-row-insert-interceptor.d.ts +19 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/action-handler-interceptors/prevent-table-insert-paragraph-interceptor.d.ts +31 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/action-handler-strategies/create-segment-table-cell-strategy.d.ts +20 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/action-handler-strategies/delete-table-block-strategy.d.ts +14 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/action-handler-strategies/delete-table-column-strategy.d.ts +74 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/action-handler-strategies/delete-table-row-strategy.d.ts +55 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/action-handler-strategies/insert-table-block-strategy.d.ts +27 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/action-handler-strategies/insert-table-column-strategy.d.ts +60 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/action-handler-strategies/insert-table-row-into-different-section-strategy.d.ts +21 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/action-handler-strategies/insert-table-row-into-same-section-strategy.d.ts +13 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/action-handler-strategies/merge-cells-strategy.d.ts +38 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/action-handler-strategies/replace-table-cell-strategy.d.ts +12 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/action-handler-strategies/select-table-column-strategy.d.ts +12 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/action-handler-strategies/split-cell-horizontally-strategy.d.ts +43 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/action-handler-strategies/split-cell-vertically-strategy.d.ts +27 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/action-handler-strategies/split-table-cell-strategy.d.ts +12 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/action-handler-strategies/table-column-strategy.abstract.d.ts +23 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/action-handler-strategies/table-row-strategy.abstract.d.ts +120 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/action-handler-strategies/toggle-header-row-strategy.d.ts +86 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/action-handler-strategies/toggle-header-table-column-strategy.d.ts +55 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/action-handler-strategies/update-table-cell-properties-strategy.d.ts +13 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/action-handler-strategies/update-table-properties-strategy.d.ts +12 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/actions/create-segment-table-cell-action.d.ts +21 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/actions/delete-table-block-action.d.ts +12 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/actions/delete-table-column-action.d.ts +15 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/actions/delete-table-row-action.d.ts +17 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/actions/insert-table-block-action.d.ts +20 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/actions/insert-table-column-action.d.ts +23 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/actions/insert-table-row-into-different-section-action.d.ts +20 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/actions/insert-table-row-into-same-section-action.d.ts +24 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/actions/merge-cells-action.d.ts +33 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/actions/replace-table-cell-action.d.ts +13 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/actions/select-table-column-action.d.ts +18 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/actions/split-cell-horizontally-action.d.ts +10 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/actions/split-cell-vertically-action.d.ts +10 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/actions/split-table-cell-action.d.ts +22 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/actions/table-annotations-action.d.ts +16 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/actions/table-caption-action.d.ts +14 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/actions/table-cell-annotations-action.d.ts +20 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/actions/table-head-cell-annotations-action.d.ts +14 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/actions/toggle-header-row-action.d.ts +12 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/actions/toggle-header-table-column-action.d.ts +16 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/actions/update-table-properties-action.d.ts +18 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/annotation-handler/table-annotation-handler-base.d.ts +36 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/annotation-handler/table-annotation-handler.d.ts +26 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/annotation-handler/table-cell-annotation-handler.d.ts +56 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/annotation-handler/table-head-cell-annotation-handler.d.ts +13 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/annotations/table-annotation.d.ts +73 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/annotations/table-caption-annotation.d.ts +32 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/annotations/table-cell-annotation.d.ts +100 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/annotations/table-color-annotation.d.ts +44 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/annotations/table-head-cell-annotation.d.ts +27 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/constants/styles.constants.d.ts +4 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/dto/table-block.d.ts +79 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/dto/table-body-block.d.ts +42 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/dto/table-caption-block.d.ts +41 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/dto/table-cell-block.d.ts +64 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/dto/table-head-block.d.ts +42 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/dto/table-head-cell-block.d.ts +34 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/dto/table-row-block.d.ts +44 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/element-to-dto-strategies/caption-to-caption-block-strategy.d.ts +37 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/element-to-dto-strategies/table-to-table-block-strategy.d.ts +26 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/element-to-dto-strategies/tbody-to-table-body-block-strategy.d.ts +26 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/element-to-dto-strategies/td-to-table-cell-block-strategy.d.ts +35 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/element-to-dto-strategies/thead-to-table-head-block-strategy.d.ts +26 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/element-to-dto-strategies/tr-to-table-row-block-strategy.d.ts +26 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/renderers/table-body-renderer.d.ts +12 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/renderers/table-caption-renderer.d.ts +13 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/renderers/table-cell-renderer.d.ts +30 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/renderers/table-dynamic-popover-renderer.d.ts +81 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/renderers/table-head-cell-renderer.d.ts +12 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/renderers/table-head-renderer.d.ts +12 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/renderers/table-popover-base-renderer.d.ts +16 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/renderers/table-renderer.d.ts +38 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/renderers/table-row-renderer.d.ts +12 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/renderers/table-setting-popover-renderer.d.ts +59 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/renderers/table-toolbar-popover-renderer.d.ts +59 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/setting-event-handlers/caption-operation.d.ts +36 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/setting-event-handlers/cell-properties-cancel-event-handler.d.ts +17 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/setting-event-handlers/cell-properties-change-event-handler.d.ts +15 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/setting-event-handlers/cell-properties-save-event-handler.d.ts +17 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/setting-event-handlers/cell-properties.d.ts +62 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/setting-event-handlers/column-operation.d.ts +55 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/setting-event-handlers/merge-cells-operation.d.ts +44 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/setting-event-handlers/row-operation.d.ts +69 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/setting-event-handlers/setting-event-handler.abstract.d.ts +48 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/setting-event-handlers/split-cell-operation.d.ts +31 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/setting-event-handlers/table-properties-cancel-event-handler.d.ts +19 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/setting-event-handlers/table-properties-change-event-handler.d.ts +17 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/setting-event-handlers/table-properties-save-event-handler.d.ts +17 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/setting-event-handlers/table-properties.d.ts +33 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/table-extension.d.ts +36 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/table-icon.d.ts +3 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/table-selection.d.ts +164 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/table-toolbar-button-renderer.d.ts +26 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/utils/table-color-manager.d.ts +27 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/utils/utils.d.ts +190 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/vega-rich-text-table-properties/assets/align-bottom.d.ts +3 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/vega-rich-text-table-properties/assets/align-middle.d.ts +3 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/vega-rich-text-table-properties/assets/align-top.d.ts +3 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/vega-rich-text-table-properties/assets/objects-align-center-horizontal.d.ts +3 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/vega-rich-text-table-properties/assets/objects-align-left.d.ts +3 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/vega-rich-text-table-properties/assets/objects-align-right.d.ts +3 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/vega-rich-text-table-properties/slimmers/controllers/vega-rich-text-table-properties-color-controller.d.ts +29 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/vega-rich-text-table-properties/slimmers/renderers/vega-rich-text-cell-properties-form-field-renderer.d.ts +49 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/vega-rich-text-table-properties/slimmers/renderers/vega-rich-text-table-properties-basic-form-field-renderer.abstract.d.ts +111 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/vega-rich-text-table-properties/slimmers/renderers/vega-rich-text-table-properties-form-field-renderer.d.ts +27 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/vega-rich-text-table-properties/slimmers/renderers/vega-rich-text-table-properties-form-renderer.d.ts +39 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/vega-rich-text-table-properties/vega-rich-text-table-properties.d.ts +60 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/vega-rich-text-table-selection-widget/slimmers/controllers/selection-widget-keyboard-controller.d.ts +15 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/vega-rich-text-table-selection-widget/slimmers/renderers/selection-widget-renderer.d.ts +31 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/vega-rich-text-table-selection-widget/vega-rich-text-table-selection-widget.d.ts +27 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/vega-rich-text-table-setting/assets/icon.d.ts +2 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/vega-rich-text-table-setting/slimmers/renderers/caption-button-slimmer.d.ts +11 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/vega-rich-text-table-setting/slimmers/renderers/cell-properties-button-slimmer.d.ts +11 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/vega-rich-text-table-setting/slimmers/renderers/column-button-slimmer.d.ts +28 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/vega-rich-text-table-setting/slimmers/renderers/merge-cells-button-slimmer.d.ts +23 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/vega-rich-text-table-setting/slimmers/renderers/row-button-slimmer.d.ts +36 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/vega-rich-text-table-setting/slimmers/renderers/table-properties-button-slimmer.d.ts +11 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/vega-rich-text-table-setting/slimmers/renderers/table-setting-button-slimmer.abstract.d.ts +36 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/vega-rich-text-table-setting/slimmers/renderers/vega-rich-text-table-setting-renderer.d.ts +12 -0
- package/dist/types/components/vega-rich-text-editor/extensions/table/vega-rich-text-table-setting/vega-rich-text-table-setting.d.ts +58 -0
- package/dist/types/components/vega-rich-text-editor/interface.d.ts +34 -2
- package/dist/types/components/vega-rich-text-editor/public-api.d.ts +1 -0
- package/dist/types/components/vega-rich-text-editor/slimmers/controllers/extension-controller.d.ts +10 -0
- package/dist/types/components/vega-rich-text-editor/slimmers/controllers/helper/element-to-dto-strategy/annotation-handler/html-element-to-annotation-generator.d.ts +9 -0
- package/dist/types/components/vega-rich-text-editor/slimmers/controllers/selection-controller.d.ts +19 -6
- package/dist/types/components/vega-rich-text-editor/test/extensions/table/annotation-handler/annotation-handler-registration.test.d.ts +1 -0
- package/dist/types/components/vega-rich-text-editor/test/extensions/table/annotation-handler/table-annotation-handler.test.d.ts +1 -0
- package/dist/types/components/vega-rich-text-editor/test/extensions/table/annotation-handler/table-cell-annotation-handler.test.d.ts +8 -0
- package/dist/types/components/vega-rich-text-editor/test/extensions/table/annotation-handler/table-head-cell-annotation-handler.test.d.ts +1 -0
- package/dist/types/components/vega-rich-text-editor/test/extensions/table/caption-operation.test.d.ts +1 -0
- package/dist/types/components/vega-rich-text-editor/test/extensions/table/table-annotation.test.d.ts +1 -0
- package/dist/types/components/vega-rich-text-editor/test/extensions/table/table-caption-annotations.test.d.ts +1 -0
- package/dist/types/components/vega-rich-text-editor/test/extensions/table/table-cell-annotation.test.d.ts +1 -0
- package/dist/types/components/vega-rich-text-editor/test/extensions/table/table-color-annotation.test.d.ts +1 -0
- package/dist/types/components/vega-rich-text-editor/test/extensions/table/table-dto.test.d.ts +1 -0
- package/dist/types/components/vega-rich-text-editor/test/extensions/table/table-element-to-dto-strategies.test.d.ts +1 -0
- package/dist/types/components/vega-rich-text-editor/test/extensions/table/table-test-utils.d.ts +11 -0
- package/dist/types/components/vega-rich-text-editor/test/filter-styles-strategies/filter-styles-strategy.test.d.ts +1 -0
- package/dist/types/components/vega-rich-text-editor/test/spec-utils.d.ts +4 -0
- package/dist/types/components/vega-rich-text-editor/vega-rich-text-editor.d.ts +0 -2
- package/dist/types/components/vega-time-picker/slimmers/renderers/vega-time-picker-range-input-renderer.d.ts +1 -0
- package/dist/types/components/vega-time-picker/slimmers/renderers/vega-time-picker-single-input-renderer.d.ts +1 -0
- package/dist/types/components/vega-time-picker/vega-time-picker.d.ts +12 -0
- package/dist/types/components.d.ts +173 -2
- package/dist/types/constants/ui.d.ts +1 -0
- package/dist/types/helpers/event-manager/event-id/vega-internal-event-id.d.ts +2 -0
- package/dist/types/helpers/formatter/responsive-map-formatter/responsive-grid-justify-items-formatter.d.ts +19 -0
- package/dist/types/helpers/formatter/test/responsive-map-formatter/responsive-grid-justify-items-formatter.test.d.ts +1 -0
- package/dist/types/helpers/slimmers/aria-dialog-focusable-trap-slimmer.d.ts +93 -0
- package/dist/types/helpers/slimmers/element-appender/body-positioned-wrapper/test/vega-popover-wrapper.test.d.ts +1 -0
- package/dist/types/helpers/slimmers/test/aria-dialog-focusable-trap-slimmer.test.d.ts +1 -0
- package/dist/types/helpers/translation/interface.d.ts +3 -1
- package/dist/types/types/components.type.d.ts +5 -0
- package/dist/types/types/type-guard.d.ts +7 -0
- package/dist/types/types/ui.type.d.ts +13 -1
- package/dist/types/utils/e2e-utils.d.ts +10 -0
- package/dist/types/utils/object.d.ts +6 -2
- package/dist/types/utils/spec-utils.d.ts +2 -1
- package/dist/types/utils/ui.d.ts +9 -0
- package/dist/vega/index.esm.js +1 -1
- package/dist/vega/p-02bab5ea.entry.js +1 -0
- package/dist/vega/p-02fec68b.entry.js +1 -0
- package/dist/vega/{p-3fd3861c.entry.js → p-04f9b0d4.entry.js} +1 -1
- package/dist/vega/{p-0681ffee.entry.js → p-076c6445.entry.js} +1 -1
- package/dist/vega/{p-c2df94f6.js → p-085d45c9.js} +1 -1
- package/dist/vega/p-0ac91609.entry.js +1 -0
- package/dist/vega/p-10e9438e.js +1 -0
- package/dist/vega/{p-ae6ed091.entry.js → p-14dfdba3.entry.js} +1 -1
- package/dist/vega/{p-7f665911.entry.js → p-1665d4b8.entry.js} +1 -1
- package/dist/vega/{p-71cd1d9e.entry.js → p-1784724a.entry.js} +1 -1
- package/dist/vega/{p-1ff45314.entry.js → p-18378017.entry.js} +1 -1
- package/dist/vega/{p-f49e8cc5.entry.js → p-19adff1f.entry.js} +1 -1
- package/dist/vega/{p-3b7ad04b.entry.js → p-20981b17.entry.js} +1 -1
- package/dist/vega/p-2697b52b.js +1 -0
- package/dist/vega/p-28c8ffb4.js +1 -0
- package/dist/vega/{p-3e484d99.entry.js → p-28ed34b3.entry.js} +1 -1
- package/dist/vega/{p-8852361b.js → p-2a9960c9.js} +1 -1
- package/dist/vega/{p-6b4021f0.entry.js → p-2bbbdf87.entry.js} +1 -1
- package/dist/vega/p-2fd266fa.js +1 -0
- package/dist/vega/p-31945d6c.js +1 -0
- package/dist/vega/p-3224e47c.js +1 -0
- package/dist/vega/{p-d7434f44.entry.js → p-32a0eed4.entry.js} +1 -1
- package/dist/vega/p-33475bcf.entry.js +1 -0
- package/dist/vega/{p-7f398d23.entry.js → p-33cacbd6.entry.js} +1 -1
- package/dist/vega/p-3a0b3fed.entry.js +1 -0
- package/dist/vega/p-3d2d267d.js +1 -0
- package/dist/vega/{p-abb81b7b.js → p-405ab757.js} +1 -1
- package/dist/vega/{p-31ac7386.js → p-4068e7de.js} +1 -1
- package/dist/vega/{p-57180993.entry.js → p-408a1baa.entry.js} +1 -1
- package/dist/vega/{p-a253e791.entry.js → p-439c7c13.entry.js} +1 -1
- package/dist/vega/{p-db92453f.entry.js → p-441fd2b3.entry.js} +1 -1
- package/dist/vega/{p-4e0344bc.entry.js → p-46c7763f.entry.js} +1 -1
- package/dist/vega/p-49a2e141.js +1 -0
- package/dist/vega/{p-951c0172.js → p-4a9be903.js} +1 -1
- package/dist/vega/p-4d65756f.js +1 -0
- package/dist/vega/{p-e52890db.js → p-4e15958f.js} +1 -1
- package/dist/vega/p-4e76a84d.entry.js +1 -0
- package/dist/vega/{p-0009e0bc.entry.js → p-4ea3cf5f.entry.js} +1 -1
- package/dist/vega/{p-f5b6059d.entry.js → p-5395faac.entry.js} +1 -1
- package/dist/vega/p-541ae774.entry.js +1 -0
- package/dist/vega/{p-19883e27.entry.js → p-558a707e.entry.js} +1 -1
- package/dist/vega/{p-cc243e62.entry.js → p-561e9097.entry.js} +1 -1
- package/dist/vega/p-5b90bbfe.js +1 -0
- package/dist/vega/p-5d397ee0.entry.js +1 -0
- package/dist/vega/{p-8fbb677e.entry.js → p-5dfd36d3.entry.js} +1 -1
- package/dist/vega/p-5f377954.js +1 -1
- package/dist/vega/p-603b851c.js +1 -0
- package/dist/vega/{p-9dc77b66.entry.js → p-615bc3de.entry.js} +1 -1
- package/dist/vega/p-6554a801.js +1 -0
- package/dist/vega/{p-a432708d.entry.js → p-667d5b80.entry.js} +1 -1
- package/dist/vega/p-679a4046.entry.js +1 -0
- package/dist/vega/{p-c208a3b7.js → p-68a531cf.js} +1 -1
- package/dist/vega/{p-309b5016.entry.js → p-6b19d33a.entry.js} +1 -1
- package/dist/vega/p-6d6ea8b4.js +1 -0
- package/dist/vega/p-6db0556d.js +1 -0
- package/dist/vega/p-6e05fc55.js +1 -0
- package/dist/vega/p-6e13e2fc.js +1 -0
- package/dist/vega/p-71720290.entry.js +1 -0
- package/dist/vega/{p-5ed5aa26.js → p-76f2e0f5.js} +1 -1
- package/dist/vega/p-79df30e3.entry.js +1 -0
- package/dist/vega/p-7f68abf7.js +1 -0
- package/dist/vega/{p-e7a8b61e.entry.js → p-814c37be.entry.js} +1 -1
- package/dist/vega/{p-7db918f4.js → p-81dd00d0.js} +1 -1
- package/dist/vega/{p-fb40a829.js → p-82016096.js} +1 -1
- package/dist/vega/{p-03280f85.entry.js → p-820906b8.entry.js} +1 -1
- package/dist/vega/{p-3d4b8066.entry.js → p-833b79ad.entry.js} +1 -1
- package/dist/vega/{p-5b238c6d.js → p-8cd70b3b.js} +1 -1
- package/dist/vega/p-8f88fb57.js +1 -0
- package/dist/vega/{p-1828f9e6.entry.js → p-905cf163.entry.js} +1 -1
- package/dist/vega/{p-b5e31243.entry.js → p-916ef5dd.entry.js} +1 -1
- package/dist/vega/p-937d5317.entry.js +1 -0
- package/dist/vega/{p-47c202eb.entry.js → p-972c594b.entry.js} +1 -1
- package/dist/vega/{p-c2560608.entry.js → p-9e6e76b2.entry.js} +1 -1
- package/dist/vega/{p-c3eec160.entry.js → p-a01ef160.entry.js} +1 -1
- package/dist/vega/p-a02f77c7.js +1 -0
- package/dist/vega/{p-882a220c.js → p-a0a39ec3.js} +1 -1
- package/dist/vega/{p-9c713bc0.js → p-a2161e9d.js} +1 -1
- package/dist/vega/{p-536ad3d7.entry.js → p-a5543b6a.entry.js} +1 -1
- package/dist/vega/{p-a113fd15.entry.js → p-a6ad6515.entry.js} +1 -1
- package/dist/vega/{p-3a537cd0.js → p-a6fb81c5.js} +1 -1
- package/dist/vega/p-a841cf13.js +1 -0
- package/dist/vega/{p-7440325c.entry.js → p-ace7aa6c.entry.js} +1 -1
- package/dist/vega/{p-5ba34330.js → p-b15a2d4b.js} +1 -1
- package/dist/vega/{p-53e0b2bd.entry.js → p-b4d72eff.entry.js} +1 -1
- package/dist/vega/{p-3592a26d.entry.js → p-b589cafd.entry.js} +1 -1
- package/dist/vega/{p-77908e45.entry.js → p-b67672ae.entry.js} +1 -1
- package/dist/vega/p-b7dd3ef2.entry.js +1 -0
- package/dist/vega/{p-a3272850.entry.js → p-b91aff06.entry.js} +1 -1
- package/dist/vega/{p-c25577ae.entry.js → p-bc142c5c.entry.js} +1 -1
- package/dist/vega/{p-99c8f9a4.entry.js → p-c58c3e7e.entry.js} +1 -1
- package/dist/vega/{p-5f81beae.js → p-c5eb0fa6.js} +1 -1
- package/dist/vega/p-c78fe943.js +1 -0
- package/dist/vega/p-c962cf5b.js +1 -0
- package/dist/vega/p-cb0324e7.entry.js +1 -0
- package/dist/vega/p-d4ea8e22.js +1 -0
- package/dist/vega/{p-e5be807b.entry.js → p-d5a8bb62.entry.js} +1 -1
- package/dist/vega/{p-6c170474.js → p-d6875e49.js} +1 -1
- package/dist/vega/p-d862195c.entry.js +1 -0
- package/dist/vega/{p-764425e4.entry.js → p-d94d785a.entry.js} +1 -1
- package/dist/vega/p-db29681a.entry.js +1 -0
- package/dist/vega/{p-c87cf96a.entry.js → p-dba91c23.entry.js} +1 -1
- package/dist/vega/{p-d42dbe39.js → p-dccda3d1.js} +1 -1
- package/dist/vega/p-dce9349e.js +1 -0
- package/dist/vega/{p-cd3d177b.entry.js → p-dd4c3d9b.entry.js} +1 -1
- package/dist/vega/{p-24b4c64f.js → p-e2268eef.js} +1 -1
- package/dist/vega/p-e5da9f66.js +1 -0
- package/dist/vega/p-f7505267.js +1 -0
- package/dist/vega/{p-f46f6679.entry.js → p-fadeb5a2.entry.js} +1 -1
- package/dist/vega/{p-d5570331.entry.js → p-fb92092b.entry.js} +1 -1
- package/dist/vega/{p-a957e15f.js → p-fc3d6d9d.js} +1 -1
- package/dist/vega/{p-2e7ec8e0.entry.js → p-fc93b467.entry.js} +1 -1
- package/dist/vega/p-fcabf0dc.js +1 -0
- package/dist/vega/p-fef22245.js +1 -0
- package/dist/vega/vega.esm.js +1 -1
- package/package.json +1 -1
- package/dist/cjs/token-extension-1e98ddf3.js +0 -3062
- package/dist/collection/components/vega-rich-text-editor/slimmers/controllers/text-node-color-controller.js +0 -51
- package/dist/collection/components/vega-rich-text-editor/slimmers/controllers/text-node-rendering-registry.js +0 -26
- package/dist/esm/token-extension-ffd98170.js +0 -3041
- package/dist/types/components/vega-rich-text-editor/slimmers/controllers/text-node-color-controller.d.ts +0 -22
- package/dist/types/components/vega-rich-text-editor/slimmers/controllers/text-node-rendering-registry.d.ts +0 -22
- package/dist/vega/p-02976501.js +0 -1
- package/dist/vega/p-03b1e442.js +0 -1
- package/dist/vega/p-093aa0cb.entry.js +0 -1
- package/dist/vega/p-1e015382.js +0 -1
- package/dist/vega/p-383e235a.entry.js +0 -1
- package/dist/vega/p-3992038a.js +0 -1
- package/dist/vega/p-4079e932.js +0 -1
- package/dist/vega/p-43df17a1.js +0 -1
- package/dist/vega/p-473ceda5.entry.js +0 -1
- package/dist/vega/p-474b97cf.entry.js +0 -1
- package/dist/vega/p-4efe9cd8.entry.js +0 -1
- package/dist/vega/p-5e1d0f21.entry.js +0 -1
- package/dist/vega/p-6a8ac66d.entry.js +0 -1
- package/dist/vega/p-6b3776ec.js +0 -1
- package/dist/vega/p-6cf28c27.js +0 -1
- package/dist/vega/p-7ade785e.js +0 -1
- package/dist/vega/p-7db5e003.js +0 -1
- package/dist/vega/p-840f156e.entry.js +0 -1
- package/dist/vega/p-87379d3c.js +0 -1
- package/dist/vega/p-87ed06cd.entry.js +0 -1
- package/dist/vega/p-898bcb24.js +0 -1
- package/dist/vega/p-9493d87a.js +0 -1
- package/dist/vega/p-95919581.entry.js +0 -1
- package/dist/vega/p-95d1b547.js +0 -1
- package/dist/vega/p-9f467a59.js +0 -1
- package/dist/vega/p-a57a7ab8.entry.js +0 -1
- package/dist/vega/p-a58bd510.entry.js +0 -1
- package/dist/vega/p-b88ca09b.js +0 -1
- package/dist/vega/p-b901d624.js +0 -1
- package/dist/vega/p-ba475520.entry.js +0 -1
- package/dist/vega/p-bf04ff19.js +0 -1
- package/dist/vega/p-bf19682d.js +0 -1
- package/dist/vega/p-c6031d3f.entry.js +0 -1
- package/dist/vega/p-c72e08c6.entry.js +0 -1
- package/dist/vega/p-d0687ec0.js +0 -1
- package/dist/vega/p-d25db724.js +0 -1
- package/dist/vega/p-d5797747.js +0 -1
- package/dist/vega/p-e6f0097f.js +0 -1
|
@@ -0,0 +1,1590 @@
|
|
|
1
|
+
import '../../../../../polyfill/test-polyfill/unit/index';
|
|
2
|
+
import { VegaRTEContent } from '../../../dto/content-state';
|
|
3
|
+
import { RTETableBlock } from '../../../extensions/table/dto/table-block';
|
|
4
|
+
import { RTETableCaptionBlock, } from '../../../extensions/table/dto/table-caption-block';
|
|
5
|
+
import { RTETableHeadBlock } from '../../../extensions/table/dto/table-head-block';
|
|
6
|
+
import { RTETableBodyBlock } from '../../../extensions/table/dto/table-body-block';
|
|
7
|
+
import { RTETableHeadCellBlock } from '../../../extensions/table/dto/table-head-cell-block';
|
|
8
|
+
import { RTETableRowBlock } from '../../../extensions/table/dto/table-row-block';
|
|
9
|
+
import { RTETableCellBlock } from '../../../extensions/table/dto/table-cell-block';
|
|
10
|
+
import { RTEHtmlBlock } from '../../../dto/blocks/html-block';
|
|
11
|
+
import { VegaRTETableExtension } from '../../../extensions/table/table-extension';
|
|
12
|
+
import { VegaInternalThemeManager } from '../../../../../helpers/theme/internal-theme-manager';
|
|
13
|
+
describe('table element to dto strategies', () => {
|
|
14
|
+
beforeAll(() => {
|
|
15
|
+
new VegaRTETableExtension().initialExtension(null);
|
|
16
|
+
});
|
|
17
|
+
it('should convert the table with children elements to extension table DTOs', () => {
|
|
18
|
+
const html = `<table>
|
|
19
|
+
<caption>Table Caption</caption>
|
|
20
|
+
<thead>
|
|
21
|
+
<tr>
|
|
22
|
+
<th>Header 1</th>
|
|
23
|
+
<th>Header 2</th>
|
|
24
|
+
</tr>
|
|
25
|
+
</thead>
|
|
26
|
+
<tbody>
|
|
27
|
+
<tr>
|
|
28
|
+
<td>Cell 1</td>
|
|
29
|
+
<td>Cell 2</td>
|
|
30
|
+
</tr>
|
|
31
|
+
<tr>
|
|
32
|
+
<td>Cell 3</td>
|
|
33
|
+
<td>Cell 4</td>
|
|
34
|
+
</tr>
|
|
35
|
+
</tbody>
|
|
36
|
+
</table>`;
|
|
37
|
+
const value = VegaRTEContent.fromHtml(html);
|
|
38
|
+
const table = value.children[0];
|
|
39
|
+
const caption = table.children[0];
|
|
40
|
+
const thead = table.children[1];
|
|
41
|
+
const tbody = table.children[2];
|
|
42
|
+
const theadRow = thead.children[0];
|
|
43
|
+
const theadCell = theadRow.children[0];
|
|
44
|
+
const tbodyRow = tbody.children[0];
|
|
45
|
+
const tbodyCell = tbodyRow.children[0];
|
|
46
|
+
expect(table).toBeInstanceOf(RTETableBlock);
|
|
47
|
+
expect(caption).toBeInstanceOf(RTETableCaptionBlock);
|
|
48
|
+
expect(thead).toBeInstanceOf(RTETableHeadBlock);
|
|
49
|
+
expect(theadRow).toBeInstanceOf(RTETableRowBlock);
|
|
50
|
+
expect(theadCell).toBeInstanceOf(RTETableHeadCellBlock);
|
|
51
|
+
expect(tbody).toBeInstanceOf(RTETableBodyBlock);
|
|
52
|
+
expect(tbodyRow).toBeInstanceOf(RTETableRowBlock);
|
|
53
|
+
expect(tbodyCell).toBeInstanceOf(RTETableCellBlock);
|
|
54
|
+
expect(VegaRTEContent.fromHtml(html).toJSON()).toEqual([
|
|
55
|
+
{
|
|
56
|
+
id: expect.anything(),
|
|
57
|
+
annotations: {
|
|
58
|
+
table: {
|
|
59
|
+
alignment: 'center',
|
|
60
|
+
borderCollapse: 'collapse',
|
|
61
|
+
},
|
|
62
|
+
},
|
|
63
|
+
type: 'table-block',
|
|
64
|
+
children: [
|
|
65
|
+
{
|
|
66
|
+
id: expect.anything(),
|
|
67
|
+
type: 'table-caption',
|
|
68
|
+
annotations: {
|
|
69
|
+
caption: {
|
|
70
|
+
backgroundColor: '#F0F3F7',
|
|
71
|
+
border: '1px solid #ddd',
|
|
72
|
+
borderBottom: 'none',
|
|
73
|
+
minHeight: '22px',
|
|
74
|
+
padding: '8px 12px',
|
|
75
|
+
position: 'relative',
|
|
76
|
+
textAlign: 'center',
|
|
77
|
+
},
|
|
78
|
+
},
|
|
79
|
+
children: [
|
|
80
|
+
{
|
|
81
|
+
id: expect.anything(),
|
|
82
|
+
annotations: {
|
|
83
|
+
textStyle: 'paragraph',
|
|
84
|
+
},
|
|
85
|
+
type: 'paragraph',
|
|
86
|
+
nodes: [
|
|
87
|
+
{
|
|
88
|
+
id: expect.anything(),
|
|
89
|
+
type: 'text',
|
|
90
|
+
text: 'Table Caption',
|
|
91
|
+
},
|
|
92
|
+
],
|
|
93
|
+
},
|
|
94
|
+
],
|
|
95
|
+
},
|
|
96
|
+
{
|
|
97
|
+
id: expect.anything(),
|
|
98
|
+
type: 'table-head',
|
|
99
|
+
children: [
|
|
100
|
+
{
|
|
101
|
+
id: expect.anything(),
|
|
102
|
+
type: 'table-row',
|
|
103
|
+
children: [
|
|
104
|
+
{
|
|
105
|
+
id: expect.anything(),
|
|
106
|
+
annotations: {
|
|
107
|
+
tableCell: {
|
|
108
|
+
padding: '12px',
|
|
109
|
+
border: {
|
|
110
|
+
style: 'solid',
|
|
111
|
+
width: '1px',
|
|
112
|
+
color: '#ddd',
|
|
113
|
+
},
|
|
114
|
+
textAlign: 'left',
|
|
115
|
+
verticalAlign: 'middle',
|
|
116
|
+
minWidth: '55px',
|
|
117
|
+
boxSizing: 'border-box',
|
|
118
|
+
},
|
|
119
|
+
},
|
|
120
|
+
type: 'table-head-cell',
|
|
121
|
+
children: [
|
|
122
|
+
{
|
|
123
|
+
id: expect.anything(),
|
|
124
|
+
annotations: {
|
|
125
|
+
textStyle: 'paragraph',
|
|
126
|
+
},
|
|
127
|
+
type: 'paragraph',
|
|
128
|
+
nodes: [
|
|
129
|
+
{
|
|
130
|
+
id: expect.anything(),
|
|
131
|
+
type: 'text',
|
|
132
|
+
text: 'Header 1',
|
|
133
|
+
},
|
|
134
|
+
],
|
|
135
|
+
},
|
|
136
|
+
],
|
|
137
|
+
},
|
|
138
|
+
{
|
|
139
|
+
id: expect.anything(),
|
|
140
|
+
annotations: {
|
|
141
|
+
tableCell: {
|
|
142
|
+
padding: '12px',
|
|
143
|
+
border: {
|
|
144
|
+
style: 'solid',
|
|
145
|
+
width: '1px',
|
|
146
|
+
color: '#ddd',
|
|
147
|
+
},
|
|
148
|
+
textAlign: 'left',
|
|
149
|
+
verticalAlign: 'middle',
|
|
150
|
+
minWidth: '55px',
|
|
151
|
+
boxSizing: 'border-box',
|
|
152
|
+
},
|
|
153
|
+
},
|
|
154
|
+
type: 'table-head-cell',
|
|
155
|
+
children: [
|
|
156
|
+
{
|
|
157
|
+
id: expect.anything(),
|
|
158
|
+
annotations: {
|
|
159
|
+
textStyle: 'paragraph',
|
|
160
|
+
},
|
|
161
|
+
type: 'paragraph',
|
|
162
|
+
nodes: [
|
|
163
|
+
{
|
|
164
|
+
id: expect.anything(),
|
|
165
|
+
type: 'text',
|
|
166
|
+
text: 'Header 2',
|
|
167
|
+
},
|
|
168
|
+
],
|
|
169
|
+
},
|
|
170
|
+
],
|
|
171
|
+
},
|
|
172
|
+
],
|
|
173
|
+
},
|
|
174
|
+
],
|
|
175
|
+
},
|
|
176
|
+
{
|
|
177
|
+
id: expect.anything(),
|
|
178
|
+
type: 'table-body',
|
|
179
|
+
children: [
|
|
180
|
+
{
|
|
181
|
+
id: expect.anything(),
|
|
182
|
+
type: 'table-row',
|
|
183
|
+
children: [
|
|
184
|
+
{
|
|
185
|
+
id: expect.anything(),
|
|
186
|
+
annotations: {
|
|
187
|
+
tableCell: {
|
|
188
|
+
padding: '12px',
|
|
189
|
+
border: {
|
|
190
|
+
style: 'solid',
|
|
191
|
+
width: '1px',
|
|
192
|
+
color: '#ddd',
|
|
193
|
+
},
|
|
194
|
+
textAlign: 'left',
|
|
195
|
+
verticalAlign: 'middle',
|
|
196
|
+
minWidth: '55px',
|
|
197
|
+
boxSizing: 'border-box',
|
|
198
|
+
},
|
|
199
|
+
},
|
|
200
|
+
type: 'table-cell',
|
|
201
|
+
children: [
|
|
202
|
+
{
|
|
203
|
+
id: expect.anything(),
|
|
204
|
+
annotations: {
|
|
205
|
+
textStyle: 'paragraph',
|
|
206
|
+
},
|
|
207
|
+
type: 'paragraph',
|
|
208
|
+
nodes: [
|
|
209
|
+
{
|
|
210
|
+
id: expect.anything(),
|
|
211
|
+
type: 'text',
|
|
212
|
+
text: 'Cell 1',
|
|
213
|
+
},
|
|
214
|
+
],
|
|
215
|
+
},
|
|
216
|
+
],
|
|
217
|
+
},
|
|
218
|
+
{
|
|
219
|
+
id: expect.anything(),
|
|
220
|
+
annotations: {
|
|
221
|
+
tableCell: {
|
|
222
|
+
padding: '12px',
|
|
223
|
+
border: {
|
|
224
|
+
style: 'solid',
|
|
225
|
+
width: '1px',
|
|
226
|
+
color: '#ddd',
|
|
227
|
+
},
|
|
228
|
+
textAlign: 'left',
|
|
229
|
+
verticalAlign: 'middle',
|
|
230
|
+
minWidth: '55px',
|
|
231
|
+
boxSizing: 'border-box',
|
|
232
|
+
},
|
|
233
|
+
},
|
|
234
|
+
type: 'table-cell',
|
|
235
|
+
children: [
|
|
236
|
+
{
|
|
237
|
+
id: expect.anything(),
|
|
238
|
+
annotations: {
|
|
239
|
+
textStyle: 'paragraph',
|
|
240
|
+
},
|
|
241
|
+
type: 'paragraph',
|
|
242
|
+
nodes: [
|
|
243
|
+
{
|
|
244
|
+
id: expect.anything(),
|
|
245
|
+
type: 'text',
|
|
246
|
+
text: 'Cell 2',
|
|
247
|
+
},
|
|
248
|
+
],
|
|
249
|
+
},
|
|
250
|
+
],
|
|
251
|
+
},
|
|
252
|
+
],
|
|
253
|
+
},
|
|
254
|
+
{
|
|
255
|
+
id: expect.anything(),
|
|
256
|
+
type: 'table-row',
|
|
257
|
+
children: [
|
|
258
|
+
{
|
|
259
|
+
id: expect.anything(),
|
|
260
|
+
annotations: {
|
|
261
|
+
tableCell: {
|
|
262
|
+
padding: '12px',
|
|
263
|
+
border: {
|
|
264
|
+
style: 'solid',
|
|
265
|
+
width: '1px',
|
|
266
|
+
color: '#ddd',
|
|
267
|
+
},
|
|
268
|
+
textAlign: 'left',
|
|
269
|
+
verticalAlign: 'middle',
|
|
270
|
+
minWidth: '55px',
|
|
271
|
+
boxSizing: 'border-box',
|
|
272
|
+
},
|
|
273
|
+
},
|
|
274
|
+
type: 'table-cell',
|
|
275
|
+
children: [
|
|
276
|
+
{
|
|
277
|
+
id: expect.anything(),
|
|
278
|
+
annotations: {
|
|
279
|
+
textStyle: 'paragraph',
|
|
280
|
+
},
|
|
281
|
+
type: 'paragraph',
|
|
282
|
+
nodes: [
|
|
283
|
+
{
|
|
284
|
+
id: expect.anything(),
|
|
285
|
+
type: 'text',
|
|
286
|
+
text: 'Cell 3',
|
|
287
|
+
},
|
|
288
|
+
],
|
|
289
|
+
},
|
|
290
|
+
],
|
|
291
|
+
},
|
|
292
|
+
{
|
|
293
|
+
id: expect.anything(),
|
|
294
|
+
annotations: {
|
|
295
|
+
tableCell: {
|
|
296
|
+
padding: '12px',
|
|
297
|
+
border: {
|
|
298
|
+
style: 'solid',
|
|
299
|
+
width: '1px',
|
|
300
|
+
color: '#ddd',
|
|
301
|
+
},
|
|
302
|
+
textAlign: 'left',
|
|
303
|
+
verticalAlign: 'middle',
|
|
304
|
+
minWidth: '55px',
|
|
305
|
+
boxSizing: 'border-box',
|
|
306
|
+
},
|
|
307
|
+
},
|
|
308
|
+
type: 'table-cell',
|
|
309
|
+
children: [
|
|
310
|
+
{
|
|
311
|
+
id: expect.anything(),
|
|
312
|
+
annotations: {
|
|
313
|
+
textStyle: 'paragraph',
|
|
314
|
+
},
|
|
315
|
+
type: 'paragraph',
|
|
316
|
+
nodes: [
|
|
317
|
+
{
|
|
318
|
+
id: expect.anything(),
|
|
319
|
+
type: 'text',
|
|
320
|
+
text: 'Cell 4',
|
|
321
|
+
},
|
|
322
|
+
],
|
|
323
|
+
},
|
|
324
|
+
],
|
|
325
|
+
},
|
|
326
|
+
],
|
|
327
|
+
},
|
|
328
|
+
],
|
|
329
|
+
},
|
|
330
|
+
],
|
|
331
|
+
},
|
|
332
|
+
]);
|
|
333
|
+
expect(VegaRTEContent.fromHtml(html, { autoMatchFormat: false }).toJSON()).toEqual([
|
|
334
|
+
{
|
|
335
|
+
id: expect.anything(),
|
|
336
|
+
type: 'table-block',
|
|
337
|
+
children: [
|
|
338
|
+
{
|
|
339
|
+
id: expect.anything(),
|
|
340
|
+
type: 'table-caption',
|
|
341
|
+
children: [
|
|
342
|
+
{
|
|
343
|
+
id: expect.anything(),
|
|
344
|
+
type: 'paragraph',
|
|
345
|
+
annotations: {
|
|
346
|
+
internalWrapper: true,
|
|
347
|
+
},
|
|
348
|
+
nodes: [
|
|
349
|
+
{
|
|
350
|
+
id: expect.anything(),
|
|
351
|
+
type: 'text',
|
|
352
|
+
text: 'Table Caption',
|
|
353
|
+
annotations: {
|
|
354
|
+
plainText: true,
|
|
355
|
+
},
|
|
356
|
+
},
|
|
357
|
+
],
|
|
358
|
+
},
|
|
359
|
+
],
|
|
360
|
+
},
|
|
361
|
+
{
|
|
362
|
+
id: expect.anything(),
|
|
363
|
+
type: 'table-head',
|
|
364
|
+
children: [
|
|
365
|
+
{
|
|
366
|
+
id: expect.anything(),
|
|
367
|
+
type: 'table-row',
|
|
368
|
+
children: [
|
|
369
|
+
{
|
|
370
|
+
id: expect.anything(),
|
|
371
|
+
type: 'table-head-cell',
|
|
372
|
+
children: [
|
|
373
|
+
{
|
|
374
|
+
id: expect.anything(),
|
|
375
|
+
annotations: {
|
|
376
|
+
internalWrapper: true,
|
|
377
|
+
},
|
|
378
|
+
type: 'paragraph',
|
|
379
|
+
nodes: [
|
|
380
|
+
{
|
|
381
|
+
id: expect.anything(),
|
|
382
|
+
annotations: {
|
|
383
|
+
plainText: true,
|
|
384
|
+
},
|
|
385
|
+
type: 'text',
|
|
386
|
+
text: 'Header 1',
|
|
387
|
+
},
|
|
388
|
+
],
|
|
389
|
+
},
|
|
390
|
+
],
|
|
391
|
+
},
|
|
392
|
+
{
|
|
393
|
+
id: expect.anything(),
|
|
394
|
+
type: 'table-head-cell',
|
|
395
|
+
children: [
|
|
396
|
+
{
|
|
397
|
+
id: expect.anything(),
|
|
398
|
+
annotations: {
|
|
399
|
+
internalWrapper: true,
|
|
400
|
+
},
|
|
401
|
+
type: 'paragraph',
|
|
402
|
+
nodes: [
|
|
403
|
+
{
|
|
404
|
+
id: expect.anything(),
|
|
405
|
+
annotations: {
|
|
406
|
+
plainText: true,
|
|
407
|
+
},
|
|
408
|
+
type: 'text',
|
|
409
|
+
text: 'Header 2',
|
|
410
|
+
},
|
|
411
|
+
],
|
|
412
|
+
},
|
|
413
|
+
],
|
|
414
|
+
},
|
|
415
|
+
],
|
|
416
|
+
},
|
|
417
|
+
],
|
|
418
|
+
},
|
|
419
|
+
{
|
|
420
|
+
id: expect.anything(),
|
|
421
|
+
type: 'table-body',
|
|
422
|
+
children: [
|
|
423
|
+
{
|
|
424
|
+
id: expect.anything(),
|
|
425
|
+
type: 'table-row',
|
|
426
|
+
children: [
|
|
427
|
+
{
|
|
428
|
+
id: expect.anything(),
|
|
429
|
+
type: 'table-cell',
|
|
430
|
+
children: [
|
|
431
|
+
{
|
|
432
|
+
id: expect.anything(),
|
|
433
|
+
annotations: {
|
|
434
|
+
internalWrapper: true,
|
|
435
|
+
},
|
|
436
|
+
type: 'paragraph',
|
|
437
|
+
nodes: [
|
|
438
|
+
{
|
|
439
|
+
id: expect.anything(),
|
|
440
|
+
annotations: {
|
|
441
|
+
plainText: true,
|
|
442
|
+
},
|
|
443
|
+
type: 'text',
|
|
444
|
+
text: 'Cell 1',
|
|
445
|
+
},
|
|
446
|
+
],
|
|
447
|
+
},
|
|
448
|
+
],
|
|
449
|
+
},
|
|
450
|
+
{
|
|
451
|
+
id: expect.anything(),
|
|
452
|
+
type: 'table-cell',
|
|
453
|
+
children: [
|
|
454
|
+
{
|
|
455
|
+
id: expect.anything(),
|
|
456
|
+
annotations: {
|
|
457
|
+
internalWrapper: true,
|
|
458
|
+
},
|
|
459
|
+
type: 'paragraph',
|
|
460
|
+
nodes: [
|
|
461
|
+
{
|
|
462
|
+
id: expect.anything(),
|
|
463
|
+
annotations: {
|
|
464
|
+
plainText: true,
|
|
465
|
+
},
|
|
466
|
+
type: 'text',
|
|
467
|
+
text: 'Cell 2',
|
|
468
|
+
},
|
|
469
|
+
],
|
|
470
|
+
},
|
|
471
|
+
],
|
|
472
|
+
},
|
|
473
|
+
],
|
|
474
|
+
},
|
|
475
|
+
{
|
|
476
|
+
id: expect.anything(),
|
|
477
|
+
type: 'table-row',
|
|
478
|
+
children: [
|
|
479
|
+
{
|
|
480
|
+
id: expect.anything(),
|
|
481
|
+
type: 'table-cell',
|
|
482
|
+
children: [
|
|
483
|
+
{
|
|
484
|
+
id: expect.anything(),
|
|
485
|
+
annotations: {
|
|
486
|
+
internalWrapper: true,
|
|
487
|
+
},
|
|
488
|
+
type: 'paragraph',
|
|
489
|
+
nodes: [
|
|
490
|
+
{
|
|
491
|
+
id: expect.anything(),
|
|
492
|
+
annotations: {
|
|
493
|
+
plainText: true,
|
|
494
|
+
},
|
|
495
|
+
type: 'text',
|
|
496
|
+
text: 'Cell 3',
|
|
497
|
+
},
|
|
498
|
+
],
|
|
499
|
+
},
|
|
500
|
+
],
|
|
501
|
+
},
|
|
502
|
+
{
|
|
503
|
+
id: expect.anything(),
|
|
504
|
+
type: 'table-cell',
|
|
505
|
+
children: [
|
|
506
|
+
{
|
|
507
|
+
id: expect.anything(),
|
|
508
|
+
annotations: {
|
|
509
|
+
internalWrapper: true,
|
|
510
|
+
},
|
|
511
|
+
type: 'paragraph',
|
|
512
|
+
nodes: [
|
|
513
|
+
{
|
|
514
|
+
id: expect.anything(),
|
|
515
|
+
annotations: {
|
|
516
|
+
plainText: true,
|
|
517
|
+
},
|
|
518
|
+
type: 'text',
|
|
519
|
+
text: 'Cell 4',
|
|
520
|
+
},
|
|
521
|
+
],
|
|
522
|
+
},
|
|
523
|
+
],
|
|
524
|
+
},
|
|
525
|
+
],
|
|
526
|
+
},
|
|
527
|
+
],
|
|
528
|
+
},
|
|
529
|
+
],
|
|
530
|
+
},
|
|
531
|
+
]);
|
|
532
|
+
});
|
|
533
|
+
it('should convert the not defined table children elements to html block DTOs', () => {
|
|
534
|
+
const html = `
|
|
535
|
+
<table>
|
|
536
|
+
<caption>
|
|
537
|
+
Front-end web developer course 2021
|
|
538
|
+
</caption>
|
|
539
|
+
<colgroup>
|
|
540
|
+
<col />
|
|
541
|
+
<col span="2" class="batman" />
|
|
542
|
+
<col span="2" class="flash" />
|
|
543
|
+
</colgroup>
|
|
544
|
+
<thead>
|
|
545
|
+
<tr>
|
|
546
|
+
<th scope="col">Person</th>
|
|
547
|
+
<th scope="col">Most interest in</th>
|
|
548
|
+
<th scope="col">Age</th>
|
|
549
|
+
</tr>
|
|
550
|
+
</thead>
|
|
551
|
+
<tbody>
|
|
552
|
+
<tr>
|
|
553
|
+
<th scope="row">Chris</th>
|
|
554
|
+
<td>HTML tables</td>
|
|
555
|
+
<td>22</td>
|
|
556
|
+
</tr>
|
|
557
|
+
<tr>
|
|
558
|
+
<th scope="row">Dennis</th>
|
|
559
|
+
<td>Web accessibility</td>
|
|
560
|
+
<td>45</td>
|
|
561
|
+
</tr>
|
|
562
|
+
<tr>
|
|
563
|
+
<th scope="row">Sarah</th>
|
|
564
|
+
<td>JavaScript frameworks</td>
|
|
565
|
+
<td>29</td>
|
|
566
|
+
</tr>
|
|
567
|
+
<tr>
|
|
568
|
+
<th scope="row">Karen</th>
|
|
569
|
+
<td>Web performance</td>
|
|
570
|
+
<td>36</td>
|
|
571
|
+
</tr>
|
|
572
|
+
</tbody>
|
|
573
|
+
<tfoot>
|
|
574
|
+
<tr>
|
|
575
|
+
<th scope="row" colspan="2">Average age</th>
|
|
576
|
+
<td>33</td>
|
|
577
|
+
</tr>
|
|
578
|
+
</tfoot>
|
|
579
|
+
</table>
|
|
580
|
+
`;
|
|
581
|
+
const value = VegaRTEContent.fromHtml(html, { autoMatchFormat: false });
|
|
582
|
+
const table = value.children[0];
|
|
583
|
+
const caption = table.children[0];
|
|
584
|
+
const colgroup = table.children[1];
|
|
585
|
+
const thead = table.children[2];
|
|
586
|
+
const tbody = table.children[3];
|
|
587
|
+
const tfoot = table.children[4];
|
|
588
|
+
const theadRow = thead.children[0];
|
|
589
|
+
const theadCell = theadRow.children[0];
|
|
590
|
+
const tbodyRow = tbody.children[0];
|
|
591
|
+
const tbodyCell = tbodyRow.children[0];
|
|
592
|
+
expect(table).toBeInstanceOf(RTETableBlock);
|
|
593
|
+
expect(caption).toBeInstanceOf(RTETableCaptionBlock);
|
|
594
|
+
expect(thead).toBeInstanceOf(RTETableHeadBlock);
|
|
595
|
+
expect(theadRow).toBeInstanceOf(RTETableRowBlock);
|
|
596
|
+
expect(theadCell).toBeInstanceOf(RTETableHeadCellBlock);
|
|
597
|
+
expect(tbody).toBeInstanceOf(RTETableBodyBlock);
|
|
598
|
+
expect(tbodyRow).toBeInstanceOf(RTETableRowBlock);
|
|
599
|
+
expect(tbodyCell).toBeInstanceOf(RTETableCellBlock);
|
|
600
|
+
// colgroup and tfoot are not defined in the custom table extension dto
|
|
601
|
+
expect(colgroup).toBeInstanceOf(RTEHtmlBlock);
|
|
602
|
+
expect(tfoot).toBeInstanceOf(RTEHtmlBlock);
|
|
603
|
+
expect(value.toHtml()).toEqualHtml(html);
|
|
604
|
+
});
|
|
605
|
+
it('should convert the table with children DTOs to table html elements', () => {
|
|
606
|
+
const html = `<table>
|
|
607
|
+
<caption>Table Caption</caption>
|
|
608
|
+
<thead>
|
|
609
|
+
<tr>
|
|
610
|
+
<th>Header 1</th>
|
|
611
|
+
<th>Header 2</th>
|
|
612
|
+
</tr>
|
|
613
|
+
</thead>
|
|
614
|
+
<tbody>
|
|
615
|
+
<tr>
|
|
616
|
+
<td>Cell 1</td>
|
|
617
|
+
<td>Cell 2</td>
|
|
618
|
+
</tr>
|
|
619
|
+
<tr>
|
|
620
|
+
<td>Cell 3</td>
|
|
621
|
+
<td>Cell 4</td>
|
|
622
|
+
</tr>
|
|
623
|
+
</tbody>
|
|
624
|
+
</table>`;
|
|
625
|
+
expect(VegaRTEContent.fromHtml(html).toHtml()).toEqualHtml(`
|
|
626
|
+
<table style="border-collapse: collapse; margin: 0 auto;">
|
|
627
|
+
<caption style="padding: 8px; border: 1px solid #ddd; border-bottom: none; background-color: #F0F3F7; position: relative; text-align: center; min-height: 22px;">
|
|
628
|
+
<p style="font-family: Inter; font-size: 16px; line-height: 22px; min-height: 22px; font-weight: 500; margin-top: 0px; margin-bottom: 0px;">
|
|
629
|
+
<span>
|
|
630
|
+
Table Caption
|
|
631
|
+
</span>
|
|
632
|
+
</p>
|
|
633
|
+
</caption>
|
|
634
|
+
<thead>
|
|
635
|
+
<tr>
|
|
636
|
+
<th style="padding: 12px; border: solid 1px #ddd; text-align: left; vertical-align: middle; min-width: 55px; box-sizing: border-box; background-color: #F0F3F7;">
|
|
637
|
+
<p style="font-family: Inter; font-size: 16px; line-height: 22px; min-height: 22px; font-weight: 500; margin-top: 0px; margin-bottom: 0px;">
|
|
638
|
+
<span>
|
|
639
|
+
Header 1
|
|
640
|
+
</span>
|
|
641
|
+
</p>
|
|
642
|
+
</th>
|
|
643
|
+
<th style="padding: 12px; border: solid 1px #ddd; text-align: left; vertical-align: middle; min-width: 55px; box-sizing: border-box; background-color: #F0F3F7;">
|
|
644
|
+
<p style="font-family: Inter; font-size: 16px; line-height: 22px; min-height: 22px; font-weight: 500; margin-top: 0px; margin-bottom: 0px;">
|
|
645
|
+
<span>
|
|
646
|
+
Header 2
|
|
647
|
+
</span>
|
|
648
|
+
</p>
|
|
649
|
+
</th>
|
|
650
|
+
</tr>
|
|
651
|
+
</thead>
|
|
652
|
+
<tbody>
|
|
653
|
+
<tr>
|
|
654
|
+
<td style="padding: 12px; border: solid 1px #ddd; text-align: left; vertical-align: middle; min-width: 55px; box-sizing: border-box;">
|
|
655
|
+
<p style="font-family: Inter; font-size: 16px; line-height: 22px; min-height: 22px; font-weight: 500; margin-top: 0px; margin-bottom: 0px;">
|
|
656
|
+
<span>
|
|
657
|
+
Cell 1
|
|
658
|
+
</span>
|
|
659
|
+
</p>
|
|
660
|
+
</td>
|
|
661
|
+
<td style="padding: 12px; border: solid 1px #ddd; text-align: left; vertical-align: middle; min-width: 55px; box-sizing: border-box;">
|
|
662
|
+
<p style="font-family: Inter; font-size: 16px; line-height: 22px; min-height: 22px; font-weight: 500; margin-top: 0px; margin-bottom: 0px;">
|
|
663
|
+
<span>
|
|
664
|
+
Cell 2
|
|
665
|
+
</span>
|
|
666
|
+
</p>
|
|
667
|
+
</td>
|
|
668
|
+
</tr>
|
|
669
|
+
<tr>
|
|
670
|
+
<td style="padding: 12px; border: solid 1px #ddd; text-align: left; vertical-align: middle; min-width: 55px; box-sizing: border-box;">
|
|
671
|
+
<p style="font-family: Inter; font-size: 16px; line-height: 22px; min-height: 22px; font-weight: 500; margin-top: 0px; margin-bottom: 0px;">
|
|
672
|
+
<span>
|
|
673
|
+
Cell 3
|
|
674
|
+
</span>
|
|
675
|
+
</p>
|
|
676
|
+
</td>
|
|
677
|
+
<td style="padding: 12px; border: solid 1px #ddd; text-align: left; vertical-align: middle; min-width: 55px; box-sizing: border-box;">
|
|
678
|
+
<p style="font-family: Inter; font-size: 16px; line-height: 22px; min-height: 22px; font-weight: 500; margin-top: 0px; margin-bottom: 0px;">
|
|
679
|
+
<span>
|
|
680
|
+
Cell 4
|
|
681
|
+
</span>
|
|
682
|
+
</p>
|
|
683
|
+
</td>
|
|
684
|
+
</tr>
|
|
685
|
+
</tbody>
|
|
686
|
+
</table>`);
|
|
687
|
+
expect(VegaRTEContent.fromHtml(html, { autoMatchFormat: false }).toHtml()).toEqualHtml(html);
|
|
688
|
+
});
|
|
689
|
+
it('should convert custom annotations as expect', () => {
|
|
690
|
+
const html = `<table id='table' style='background: blue' class='table'>
|
|
691
|
+
<caption id='caption' style='color: yellow' class='caption'>Table Caption</caption>
|
|
692
|
+
<thead id='head' style='background: red' class='thead'>
|
|
693
|
+
<tr id='row-1' style='background: purple' class='tr'>
|
|
694
|
+
<th id='head-cell-1' style='background: pink' class='th'>Header 1</th>
|
|
695
|
+
<th>Header 2</th>
|
|
696
|
+
</tr>
|
|
697
|
+
</thead>
|
|
698
|
+
<tbody id='body' style='background: green' class='tbody'>
|
|
699
|
+
<tr>
|
|
700
|
+
<td id='cell-1' style='background: yellow' class='td'>Cell 1</td>
|
|
701
|
+
<td>Cell 2</td>
|
|
702
|
+
</tr>
|
|
703
|
+
<tr>
|
|
704
|
+
<td>Cell 3</td>
|
|
705
|
+
<td>Cell 4</td>
|
|
706
|
+
</tr>
|
|
707
|
+
</tbody>
|
|
708
|
+
</table>`;
|
|
709
|
+
expect(VegaRTEContent.fromHtml(html, { autoMatchFormat: false }).toJSON()).toEqual([
|
|
710
|
+
{
|
|
711
|
+
id: expect.anything(),
|
|
712
|
+
annotations: {
|
|
713
|
+
customAttribute: {
|
|
714
|
+
id: 'table',
|
|
715
|
+
},
|
|
716
|
+
customClass: ['table'],
|
|
717
|
+
customStyle: {
|
|
718
|
+
background: 'blue',
|
|
719
|
+
},
|
|
720
|
+
},
|
|
721
|
+
type: 'table-block',
|
|
722
|
+
children: [
|
|
723
|
+
{
|
|
724
|
+
id: expect.anything(),
|
|
725
|
+
annotations: {
|
|
726
|
+
customAttribute: {
|
|
727
|
+
id: 'caption',
|
|
728
|
+
},
|
|
729
|
+
customClass: ['caption'],
|
|
730
|
+
customStyle: {
|
|
731
|
+
color: 'yellow',
|
|
732
|
+
},
|
|
733
|
+
},
|
|
734
|
+
type: 'table-caption',
|
|
735
|
+
children: [
|
|
736
|
+
{
|
|
737
|
+
id: expect.anything(),
|
|
738
|
+
annotations: {
|
|
739
|
+
internalWrapper: true,
|
|
740
|
+
},
|
|
741
|
+
type: 'paragraph',
|
|
742
|
+
nodes: [
|
|
743
|
+
{
|
|
744
|
+
id: expect.anything(),
|
|
745
|
+
annotations: {
|
|
746
|
+
plainText: true,
|
|
747
|
+
},
|
|
748
|
+
type: 'text',
|
|
749
|
+
text: 'Table Caption',
|
|
750
|
+
},
|
|
751
|
+
],
|
|
752
|
+
},
|
|
753
|
+
],
|
|
754
|
+
},
|
|
755
|
+
{
|
|
756
|
+
id: expect.anything(),
|
|
757
|
+
annotations: {
|
|
758
|
+
customAttribute: {
|
|
759
|
+
id: 'head',
|
|
760
|
+
},
|
|
761
|
+
customClass: ['thead'],
|
|
762
|
+
customStyle: {
|
|
763
|
+
background: 'red',
|
|
764
|
+
},
|
|
765
|
+
},
|
|
766
|
+
type: 'table-head',
|
|
767
|
+
children: [
|
|
768
|
+
{
|
|
769
|
+
id: expect.anything(),
|
|
770
|
+
annotations: {
|
|
771
|
+
customAttribute: {
|
|
772
|
+
id: 'row-1',
|
|
773
|
+
},
|
|
774
|
+
customClass: ['tr'],
|
|
775
|
+
customStyle: {
|
|
776
|
+
background: 'purple',
|
|
777
|
+
},
|
|
778
|
+
},
|
|
779
|
+
type: 'table-row',
|
|
780
|
+
children: [
|
|
781
|
+
{
|
|
782
|
+
id: expect.anything(),
|
|
783
|
+
annotations: {
|
|
784
|
+
customAttribute: {
|
|
785
|
+
id: 'head-cell-1',
|
|
786
|
+
},
|
|
787
|
+
customClass: ['th'],
|
|
788
|
+
customStyle: {
|
|
789
|
+
background: 'pink',
|
|
790
|
+
},
|
|
791
|
+
},
|
|
792
|
+
type: 'table-head-cell',
|
|
793
|
+
children: [
|
|
794
|
+
{
|
|
795
|
+
id: expect.anything(),
|
|
796
|
+
annotations: {
|
|
797
|
+
internalWrapper: true,
|
|
798
|
+
},
|
|
799
|
+
type: 'paragraph',
|
|
800
|
+
nodes: [
|
|
801
|
+
{
|
|
802
|
+
id: expect.anything(),
|
|
803
|
+
annotations: {
|
|
804
|
+
plainText: true,
|
|
805
|
+
},
|
|
806
|
+
type: 'text',
|
|
807
|
+
text: 'Header 1',
|
|
808
|
+
},
|
|
809
|
+
],
|
|
810
|
+
},
|
|
811
|
+
],
|
|
812
|
+
},
|
|
813
|
+
{
|
|
814
|
+
id: expect.anything(),
|
|
815
|
+
type: 'table-head-cell',
|
|
816
|
+
children: [
|
|
817
|
+
{
|
|
818
|
+
id: expect.anything(),
|
|
819
|
+
annotations: {
|
|
820
|
+
internalWrapper: true,
|
|
821
|
+
},
|
|
822
|
+
type: 'paragraph',
|
|
823
|
+
nodes: [
|
|
824
|
+
{
|
|
825
|
+
id: expect.anything(),
|
|
826
|
+
annotations: {
|
|
827
|
+
plainText: true,
|
|
828
|
+
},
|
|
829
|
+
type: 'text',
|
|
830
|
+
text: 'Header 2',
|
|
831
|
+
},
|
|
832
|
+
],
|
|
833
|
+
},
|
|
834
|
+
],
|
|
835
|
+
},
|
|
836
|
+
],
|
|
837
|
+
},
|
|
838
|
+
],
|
|
839
|
+
},
|
|
840
|
+
{
|
|
841
|
+
id: expect.anything(),
|
|
842
|
+
annotations: {
|
|
843
|
+
customAttribute: {
|
|
844
|
+
id: 'body',
|
|
845
|
+
},
|
|
846
|
+
customClass: ['tbody'],
|
|
847
|
+
customStyle: {
|
|
848
|
+
background: 'green',
|
|
849
|
+
},
|
|
850
|
+
},
|
|
851
|
+
type: 'table-body',
|
|
852
|
+
children: [
|
|
853
|
+
{
|
|
854
|
+
id: expect.anything(),
|
|
855
|
+
type: 'table-row',
|
|
856
|
+
children: [
|
|
857
|
+
{
|
|
858
|
+
id: expect.anything(),
|
|
859
|
+
annotations: {
|
|
860
|
+
customAttribute: {
|
|
861
|
+
id: 'cell-1',
|
|
862
|
+
},
|
|
863
|
+
customClass: ['td'],
|
|
864
|
+
customStyle: {
|
|
865
|
+
background: 'yellow',
|
|
866
|
+
},
|
|
867
|
+
},
|
|
868
|
+
type: 'table-cell',
|
|
869
|
+
children: [
|
|
870
|
+
{
|
|
871
|
+
id: expect.anything(),
|
|
872
|
+
annotations: {
|
|
873
|
+
internalWrapper: true,
|
|
874
|
+
},
|
|
875
|
+
type: 'paragraph',
|
|
876
|
+
nodes: [
|
|
877
|
+
{
|
|
878
|
+
id: expect.anything(),
|
|
879
|
+
annotations: {
|
|
880
|
+
plainText: true,
|
|
881
|
+
},
|
|
882
|
+
type: 'text',
|
|
883
|
+
text: 'Cell 1',
|
|
884
|
+
},
|
|
885
|
+
],
|
|
886
|
+
},
|
|
887
|
+
],
|
|
888
|
+
},
|
|
889
|
+
{
|
|
890
|
+
id: expect.anything(),
|
|
891
|
+
type: 'table-cell',
|
|
892
|
+
children: [
|
|
893
|
+
{
|
|
894
|
+
id: expect.anything(),
|
|
895
|
+
annotations: {
|
|
896
|
+
internalWrapper: true,
|
|
897
|
+
},
|
|
898
|
+
type: 'paragraph',
|
|
899
|
+
nodes: [
|
|
900
|
+
{
|
|
901
|
+
id: expect.anything(),
|
|
902
|
+
annotations: {
|
|
903
|
+
plainText: true,
|
|
904
|
+
},
|
|
905
|
+
type: 'text',
|
|
906
|
+
text: 'Cell 2',
|
|
907
|
+
},
|
|
908
|
+
],
|
|
909
|
+
},
|
|
910
|
+
],
|
|
911
|
+
},
|
|
912
|
+
],
|
|
913
|
+
},
|
|
914
|
+
{
|
|
915
|
+
id: expect.anything(),
|
|
916
|
+
type: 'table-row',
|
|
917
|
+
children: [
|
|
918
|
+
{
|
|
919
|
+
id: expect.anything(),
|
|
920
|
+
type: 'table-cell',
|
|
921
|
+
children: [
|
|
922
|
+
{
|
|
923
|
+
id: expect.anything(),
|
|
924
|
+
annotations: {
|
|
925
|
+
internalWrapper: true,
|
|
926
|
+
},
|
|
927
|
+
type: 'paragraph',
|
|
928
|
+
nodes: [
|
|
929
|
+
{
|
|
930
|
+
id: expect.anything(),
|
|
931
|
+
annotations: {
|
|
932
|
+
plainText: true,
|
|
933
|
+
},
|
|
934
|
+
type: 'text',
|
|
935
|
+
text: 'Cell 3',
|
|
936
|
+
},
|
|
937
|
+
],
|
|
938
|
+
},
|
|
939
|
+
],
|
|
940
|
+
},
|
|
941
|
+
{
|
|
942
|
+
id: expect.anything(),
|
|
943
|
+
type: 'table-cell',
|
|
944
|
+
children: [
|
|
945
|
+
{
|
|
946
|
+
id: expect.anything(),
|
|
947
|
+
annotations: {
|
|
948
|
+
internalWrapper: true,
|
|
949
|
+
},
|
|
950
|
+
type: 'paragraph',
|
|
951
|
+
nodes: [
|
|
952
|
+
{
|
|
953
|
+
id: expect.anything(),
|
|
954
|
+
annotations: {
|
|
955
|
+
plainText: true,
|
|
956
|
+
},
|
|
957
|
+
type: 'text',
|
|
958
|
+
text: 'Cell 4',
|
|
959
|
+
},
|
|
960
|
+
],
|
|
961
|
+
},
|
|
962
|
+
],
|
|
963
|
+
},
|
|
964
|
+
],
|
|
965
|
+
},
|
|
966
|
+
],
|
|
967
|
+
},
|
|
968
|
+
],
|
|
969
|
+
},
|
|
970
|
+
]);
|
|
971
|
+
expect(VegaRTEContent.fromHtml(html).toJSON()).toEqual([
|
|
972
|
+
{
|
|
973
|
+
id: expect.anything(),
|
|
974
|
+
annotations: {
|
|
975
|
+
table: {
|
|
976
|
+
alignment: 'center',
|
|
977
|
+
borderCollapse: 'collapse',
|
|
978
|
+
},
|
|
979
|
+
customAttribute: {
|
|
980
|
+
id: 'table',
|
|
981
|
+
},
|
|
982
|
+
customClass: ['table'],
|
|
983
|
+
customStyle: {
|
|
984
|
+
background: 'blue',
|
|
985
|
+
},
|
|
986
|
+
},
|
|
987
|
+
type: 'table-block',
|
|
988
|
+
children: [
|
|
989
|
+
{
|
|
990
|
+
id: expect.anything(),
|
|
991
|
+
annotations: {
|
|
992
|
+
caption: {
|
|
993
|
+
padding: '8px 12px',
|
|
994
|
+
border: '1px solid #ddd',
|
|
995
|
+
borderBottom: 'none',
|
|
996
|
+
backgroundColor: '#F0F3F7',
|
|
997
|
+
position: 'relative',
|
|
998
|
+
textAlign: 'center',
|
|
999
|
+
minHeight: '22px',
|
|
1000
|
+
},
|
|
1001
|
+
customAttribute: {
|
|
1002
|
+
id: 'caption',
|
|
1003
|
+
},
|
|
1004
|
+
customClass: ['caption'],
|
|
1005
|
+
customStyle: {
|
|
1006
|
+
color: 'yellow',
|
|
1007
|
+
},
|
|
1008
|
+
},
|
|
1009
|
+
type: 'table-caption',
|
|
1010
|
+
children: [
|
|
1011
|
+
{
|
|
1012
|
+
id: expect.anything(),
|
|
1013
|
+
annotations: {
|
|
1014
|
+
textStyle: 'paragraph',
|
|
1015
|
+
customAttribute: {
|
|
1016
|
+
id: 'caption',
|
|
1017
|
+
},
|
|
1018
|
+
customClass: ['caption'],
|
|
1019
|
+
customStyle: {
|
|
1020
|
+
color: 'yellow',
|
|
1021
|
+
},
|
|
1022
|
+
},
|
|
1023
|
+
type: 'paragraph',
|
|
1024
|
+
nodes: [
|
|
1025
|
+
{
|
|
1026
|
+
id: expect.anything(),
|
|
1027
|
+
type: 'text',
|
|
1028
|
+
text: 'Table Caption',
|
|
1029
|
+
},
|
|
1030
|
+
],
|
|
1031
|
+
},
|
|
1032
|
+
],
|
|
1033
|
+
},
|
|
1034
|
+
{
|
|
1035
|
+
id: expect.anything(),
|
|
1036
|
+
annotations: {
|
|
1037
|
+
customAttribute: {
|
|
1038
|
+
id: 'head',
|
|
1039
|
+
},
|
|
1040
|
+
customClass: ['thead'],
|
|
1041
|
+
customStyle: {
|
|
1042
|
+
background: 'red',
|
|
1043
|
+
},
|
|
1044
|
+
},
|
|
1045
|
+
type: 'table-head',
|
|
1046
|
+
children: [
|
|
1047
|
+
{
|
|
1048
|
+
id: expect.anything(),
|
|
1049
|
+
annotations: {
|
|
1050
|
+
customAttribute: {
|
|
1051
|
+
id: 'row-1',
|
|
1052
|
+
},
|
|
1053
|
+
customClass: ['tr'],
|
|
1054
|
+
customStyle: {
|
|
1055
|
+
background: 'purple',
|
|
1056
|
+
},
|
|
1057
|
+
},
|
|
1058
|
+
type: 'table-row',
|
|
1059
|
+
children: [
|
|
1060
|
+
{
|
|
1061
|
+
id: expect.anything(),
|
|
1062
|
+
annotations: {
|
|
1063
|
+
tableCell: {
|
|
1064
|
+
padding: '12px',
|
|
1065
|
+
border: {
|
|
1066
|
+
style: 'solid',
|
|
1067
|
+
width: '1px',
|
|
1068
|
+
color: '#ddd',
|
|
1069
|
+
},
|
|
1070
|
+
textAlign: 'left',
|
|
1071
|
+
verticalAlign: 'middle',
|
|
1072
|
+
minWidth: '55px',
|
|
1073
|
+
boxSizing: 'border-box',
|
|
1074
|
+
},
|
|
1075
|
+
customAttribute: {
|
|
1076
|
+
id: 'head-cell-1',
|
|
1077
|
+
},
|
|
1078
|
+
customClass: ['th'],
|
|
1079
|
+
customStyle: {
|
|
1080
|
+
background: 'pink',
|
|
1081
|
+
},
|
|
1082
|
+
},
|
|
1083
|
+
type: 'table-head-cell',
|
|
1084
|
+
children: [
|
|
1085
|
+
{
|
|
1086
|
+
id: expect.anything(),
|
|
1087
|
+
annotations: {
|
|
1088
|
+
textStyle: 'paragraph',
|
|
1089
|
+
customAttribute: {
|
|
1090
|
+
id: 'head-cell-1',
|
|
1091
|
+
},
|
|
1092
|
+
customClass: ['th'],
|
|
1093
|
+
customStyle: {
|
|
1094
|
+
background: 'pink',
|
|
1095
|
+
},
|
|
1096
|
+
},
|
|
1097
|
+
type: 'paragraph',
|
|
1098
|
+
nodes: [
|
|
1099
|
+
{
|
|
1100
|
+
id: expect.anything(),
|
|
1101
|
+
type: 'text',
|
|
1102
|
+
text: 'Header 1',
|
|
1103
|
+
},
|
|
1104
|
+
],
|
|
1105
|
+
},
|
|
1106
|
+
],
|
|
1107
|
+
},
|
|
1108
|
+
{
|
|
1109
|
+
id: expect.anything(),
|
|
1110
|
+
annotations: {
|
|
1111
|
+
tableCell: {
|
|
1112
|
+
padding: '12px',
|
|
1113
|
+
border: {
|
|
1114
|
+
style: 'solid',
|
|
1115
|
+
width: '1px',
|
|
1116
|
+
color: '#ddd',
|
|
1117
|
+
},
|
|
1118
|
+
textAlign: 'left',
|
|
1119
|
+
verticalAlign: 'middle',
|
|
1120
|
+
minWidth: '55px',
|
|
1121
|
+
boxSizing: 'border-box',
|
|
1122
|
+
},
|
|
1123
|
+
},
|
|
1124
|
+
type: 'table-head-cell',
|
|
1125
|
+
children: [
|
|
1126
|
+
{
|
|
1127
|
+
id: expect.anything(),
|
|
1128
|
+
annotations: {
|
|
1129
|
+
textStyle: 'paragraph',
|
|
1130
|
+
},
|
|
1131
|
+
type: 'paragraph',
|
|
1132
|
+
nodes: [
|
|
1133
|
+
{
|
|
1134
|
+
id: expect.anything(),
|
|
1135
|
+
type: 'text',
|
|
1136
|
+
text: 'Header 2',
|
|
1137
|
+
},
|
|
1138
|
+
],
|
|
1139
|
+
},
|
|
1140
|
+
],
|
|
1141
|
+
},
|
|
1142
|
+
],
|
|
1143
|
+
},
|
|
1144
|
+
],
|
|
1145
|
+
},
|
|
1146
|
+
{
|
|
1147
|
+
id: expect.anything(),
|
|
1148
|
+
annotations: {
|
|
1149
|
+
customAttribute: {
|
|
1150
|
+
id: 'body',
|
|
1151
|
+
},
|
|
1152
|
+
customClass: ['tbody'],
|
|
1153
|
+
customStyle: {
|
|
1154
|
+
background: 'green',
|
|
1155
|
+
},
|
|
1156
|
+
},
|
|
1157
|
+
type: 'table-body',
|
|
1158
|
+
children: [
|
|
1159
|
+
{
|
|
1160
|
+
id: expect.anything(),
|
|
1161
|
+
type: 'table-row',
|
|
1162
|
+
children: [
|
|
1163
|
+
{
|
|
1164
|
+
id: expect.anything(),
|
|
1165
|
+
annotations: {
|
|
1166
|
+
tableCell: {
|
|
1167
|
+
padding: '12px',
|
|
1168
|
+
border: {
|
|
1169
|
+
style: 'solid',
|
|
1170
|
+
width: '1px',
|
|
1171
|
+
color: '#ddd',
|
|
1172
|
+
},
|
|
1173
|
+
textAlign: 'left',
|
|
1174
|
+
verticalAlign: 'middle',
|
|
1175
|
+
minWidth: '55px',
|
|
1176
|
+
boxSizing: 'border-box',
|
|
1177
|
+
},
|
|
1178
|
+
customAttribute: {
|
|
1179
|
+
id: 'cell-1',
|
|
1180
|
+
},
|
|
1181
|
+
customClass: ['td'],
|
|
1182
|
+
customStyle: {
|
|
1183
|
+
background: 'yellow',
|
|
1184
|
+
},
|
|
1185
|
+
},
|
|
1186
|
+
type: 'table-cell',
|
|
1187
|
+
children: [
|
|
1188
|
+
{
|
|
1189
|
+
id: expect.anything(),
|
|
1190
|
+
annotations: {
|
|
1191
|
+
textStyle: 'paragraph',
|
|
1192
|
+
customAttribute: {
|
|
1193
|
+
id: 'cell-1',
|
|
1194
|
+
},
|
|
1195
|
+
customClass: ['td'],
|
|
1196
|
+
customStyle: {
|
|
1197
|
+
background: 'yellow',
|
|
1198
|
+
},
|
|
1199
|
+
},
|
|
1200
|
+
type: 'paragraph',
|
|
1201
|
+
nodes: [
|
|
1202
|
+
{
|
|
1203
|
+
id: expect.anything(),
|
|
1204
|
+
type: 'text',
|
|
1205
|
+
text: 'Cell 1',
|
|
1206
|
+
},
|
|
1207
|
+
],
|
|
1208
|
+
},
|
|
1209
|
+
],
|
|
1210
|
+
},
|
|
1211
|
+
{
|
|
1212
|
+
id: expect.anything(),
|
|
1213
|
+
annotations: {
|
|
1214
|
+
tableCell: {
|
|
1215
|
+
padding: '12px',
|
|
1216
|
+
border: {
|
|
1217
|
+
style: 'solid',
|
|
1218
|
+
width: '1px',
|
|
1219
|
+
color: '#ddd',
|
|
1220
|
+
},
|
|
1221
|
+
textAlign: 'left',
|
|
1222
|
+
verticalAlign: 'middle',
|
|
1223
|
+
minWidth: '55px',
|
|
1224
|
+
boxSizing: 'border-box',
|
|
1225
|
+
},
|
|
1226
|
+
},
|
|
1227
|
+
type: 'table-cell',
|
|
1228
|
+
children: [
|
|
1229
|
+
{
|
|
1230
|
+
id: expect.anything(),
|
|
1231
|
+
annotations: {
|
|
1232
|
+
textStyle: 'paragraph',
|
|
1233
|
+
},
|
|
1234
|
+
type: 'paragraph',
|
|
1235
|
+
nodes: [
|
|
1236
|
+
{
|
|
1237
|
+
id: expect.anything(),
|
|
1238
|
+
type: 'text',
|
|
1239
|
+
text: 'Cell 2',
|
|
1240
|
+
},
|
|
1241
|
+
],
|
|
1242
|
+
},
|
|
1243
|
+
],
|
|
1244
|
+
},
|
|
1245
|
+
],
|
|
1246
|
+
},
|
|
1247
|
+
{
|
|
1248
|
+
id: expect.anything(),
|
|
1249
|
+
type: 'table-row',
|
|
1250
|
+
children: [
|
|
1251
|
+
{
|
|
1252
|
+
id: expect.anything(),
|
|
1253
|
+
annotations: {
|
|
1254
|
+
tableCell: {
|
|
1255
|
+
padding: '12px',
|
|
1256
|
+
border: {
|
|
1257
|
+
style: 'solid',
|
|
1258
|
+
width: '1px',
|
|
1259
|
+
color: '#ddd',
|
|
1260
|
+
},
|
|
1261
|
+
textAlign: 'left',
|
|
1262
|
+
verticalAlign: 'middle',
|
|
1263
|
+
minWidth: '55px',
|
|
1264
|
+
boxSizing: 'border-box',
|
|
1265
|
+
},
|
|
1266
|
+
},
|
|
1267
|
+
type: 'table-cell',
|
|
1268
|
+
children: [
|
|
1269
|
+
{
|
|
1270
|
+
id: expect.anything(),
|
|
1271
|
+
annotations: {
|
|
1272
|
+
textStyle: 'paragraph',
|
|
1273
|
+
},
|
|
1274
|
+
type: 'paragraph',
|
|
1275
|
+
nodes: [
|
|
1276
|
+
{
|
|
1277
|
+
id: expect.anything(),
|
|
1278
|
+
type: 'text',
|
|
1279
|
+
text: 'Cell 3',
|
|
1280
|
+
},
|
|
1281
|
+
],
|
|
1282
|
+
},
|
|
1283
|
+
],
|
|
1284
|
+
},
|
|
1285
|
+
{
|
|
1286
|
+
id: expect.anything(),
|
|
1287
|
+
annotations: {
|
|
1288
|
+
tableCell: {
|
|
1289
|
+
padding: '12px',
|
|
1290
|
+
border: {
|
|
1291
|
+
style: 'solid',
|
|
1292
|
+
width: '1px',
|
|
1293
|
+
color: '#ddd',
|
|
1294
|
+
},
|
|
1295
|
+
textAlign: 'left',
|
|
1296
|
+
verticalAlign: 'middle',
|
|
1297
|
+
minWidth: '55px',
|
|
1298
|
+
boxSizing: 'border-box',
|
|
1299
|
+
},
|
|
1300
|
+
},
|
|
1301
|
+
type: 'table-cell',
|
|
1302
|
+
children: [
|
|
1303
|
+
{
|
|
1304
|
+
id: expect.anything(),
|
|
1305
|
+
annotations: {
|
|
1306
|
+
textStyle: 'paragraph',
|
|
1307
|
+
},
|
|
1308
|
+
type: 'paragraph',
|
|
1309
|
+
nodes: [
|
|
1310
|
+
{
|
|
1311
|
+
id: expect.anything(),
|
|
1312
|
+
type: 'text',
|
|
1313
|
+
text: 'Cell 4',
|
|
1314
|
+
},
|
|
1315
|
+
],
|
|
1316
|
+
},
|
|
1317
|
+
],
|
|
1318
|
+
},
|
|
1319
|
+
],
|
|
1320
|
+
},
|
|
1321
|
+
],
|
|
1322
|
+
},
|
|
1323
|
+
],
|
|
1324
|
+
},
|
|
1325
|
+
]);
|
|
1326
|
+
expect(VegaRTEContent.fromHtml(html, { autoMatchFormat: false }).toHtml()).toEqualHtml(html);
|
|
1327
|
+
expect(VegaRTEContent.fromHtml(html).toHtml())
|
|
1328
|
+
.toEqualHtml(`<table class="table" id="table" style="border-collapse: collapse; margin: 0 auto; background: blue;">
|
|
1329
|
+
<caption class="caption" id="caption" style="padding: 8px; border: 1px solid #ddd; border-bottom: none; background-color: #F0F3F7; position: relative; text-align: center; min-height: 22px; color: yellow;">
|
|
1330
|
+
<p class="caption" id="caption" style="font-family: Inter; font-size: 16px; line-height: 22px; min-height: 22px; font-weight: 500; margin-top: 0px; margin-bottom: 0px; color: yellow;">
|
|
1331
|
+
<span>
|
|
1332
|
+
Table Caption
|
|
1333
|
+
</span>
|
|
1334
|
+
</p>
|
|
1335
|
+
</caption>
|
|
1336
|
+
<thead class="thead" id="head" style="background: red;">
|
|
1337
|
+
<tr class="tr" id="row-1" style="background: purple;">
|
|
1338
|
+
<th class="th" id="head-cell-1" style="padding: 12px; border: solid 1px #ddd; text-align: left; vertical-align: middle; min-width: 55px; box-sizing: border-box; background-color: #F0F3F7; background: pink;">
|
|
1339
|
+
<p class="th" id="head-cell-1" style="font-family: Inter; font-size: 16px; line-height: 22px; min-height: 22px; font-weight: 500; margin-top: 0px; margin-bottom: 0px; background: pink;">
|
|
1340
|
+
<span>
|
|
1341
|
+
Header 1
|
|
1342
|
+
</span>
|
|
1343
|
+
</p>
|
|
1344
|
+
</th>
|
|
1345
|
+
<th style="padding: 12px; border: solid 1px #ddd; text-align: left; vertical-align: middle; min-width: 55px; box-sizing: border-box; background-color: #F0F3F7;">
|
|
1346
|
+
<p style="font-family: Inter; font-size: 16px; line-height: 22px; min-height: 22px; font-weight: 500; margin-top: 0px; margin-bottom: 0px;">
|
|
1347
|
+
<span>
|
|
1348
|
+
Header 2
|
|
1349
|
+
</span>
|
|
1350
|
+
</p>
|
|
1351
|
+
</th>
|
|
1352
|
+
</tr>
|
|
1353
|
+
</thead>
|
|
1354
|
+
<tbody class="tbody" id="body" style="background: green;">
|
|
1355
|
+
<tr>
|
|
1356
|
+
<td class="td" id="cell-1" style="padding: 12px; border: solid 1px #ddd; text-align: left; vertical-align: middle; min-width: 55px; box-sizing: border-box; background: yellow;">
|
|
1357
|
+
<p class="td" id="cell-1" style="font-family: Inter; font-size: 16px; line-height: 22px; min-height: 22px; font-weight: 500; margin-top: 0px; margin-bottom: 0px; background: yellow;">
|
|
1358
|
+
<span>
|
|
1359
|
+
Cell 1
|
|
1360
|
+
</span>
|
|
1361
|
+
</p>
|
|
1362
|
+
</td>
|
|
1363
|
+
<td style="padding: 12px; border: solid 1px #ddd; text-align: left; vertical-align: middle; min-width: 55px; box-sizing: border-box;">
|
|
1364
|
+
<p style="font-family: Inter; font-size: 16px; line-height: 22px; min-height: 22px; font-weight: 500; margin-top: 0px; margin-bottom: 0px;">
|
|
1365
|
+
<span>
|
|
1366
|
+
Cell 2
|
|
1367
|
+
</span>
|
|
1368
|
+
</p>
|
|
1369
|
+
</td>
|
|
1370
|
+
</tr>
|
|
1371
|
+
<tr>
|
|
1372
|
+
<td style="padding: 12px; border: solid 1px #ddd; text-align: left; vertical-align: middle; min-width: 55px; box-sizing: border-box;">
|
|
1373
|
+
<p style="font-family: Inter; font-size: 16px; line-height: 22px; min-height: 22px; font-weight: 500; margin-top: 0px; margin-bottom: 0px;">
|
|
1374
|
+
<span>
|
|
1375
|
+
Cell 3
|
|
1376
|
+
</span>
|
|
1377
|
+
</p>
|
|
1378
|
+
</td>
|
|
1379
|
+
<td style="padding: 12px; border: solid 1px #ddd; text-align: left; vertical-align: middle; min-width: 55px; box-sizing: border-box;">
|
|
1380
|
+
<p style="font-family: Inter; font-size: 16px; line-height: 22px; min-height: 22px; font-weight: 500; margin-top: 0px; margin-bottom: 0px;">
|
|
1381
|
+
<span>
|
|
1382
|
+
Cell 4
|
|
1383
|
+
</span>
|
|
1384
|
+
</p>
|
|
1385
|
+
</td>
|
|
1386
|
+
</tr>
|
|
1387
|
+
</tbody>
|
|
1388
|
+
</table>`);
|
|
1389
|
+
});
|
|
1390
|
+
it('should convert empty cell with default paragraph if autoMatchFormat is not false', () => {
|
|
1391
|
+
const html = `<table>
|
|
1392
|
+
<thead>
|
|
1393
|
+
<tr>
|
|
1394
|
+
<th></th>
|
|
1395
|
+
<th>Header 2</th>
|
|
1396
|
+
</tr>
|
|
1397
|
+
</thead>
|
|
1398
|
+
<tbody>
|
|
1399
|
+
<tr>
|
|
1400
|
+
<td></td>
|
|
1401
|
+
<td>Cell 2</td>
|
|
1402
|
+
</tr>
|
|
1403
|
+
</tbody>
|
|
1404
|
+
</table>`;
|
|
1405
|
+
const value = VegaRTEContent.fromHtml(html);
|
|
1406
|
+
const table = value.children[0];
|
|
1407
|
+
const thead = table.children[0];
|
|
1408
|
+
const tbody = table.children[1];
|
|
1409
|
+
const theadRow = thead.children[0];
|
|
1410
|
+
const theadCell = theadRow.children[0];
|
|
1411
|
+
const tbodyRow = tbody.children[0];
|
|
1412
|
+
const tbodyCell = tbodyRow.children[0];
|
|
1413
|
+
expect(theadCell.children.length).toBe(1);
|
|
1414
|
+
expect(theadCell.children[0].toJSON()).toEqual({
|
|
1415
|
+
id: expect.anything(),
|
|
1416
|
+
type: 'paragraph',
|
|
1417
|
+
annotations: { textStyle: 'paragraph' },
|
|
1418
|
+
nodes: [{ id: expect.anything(), text: '', type: 'text' }],
|
|
1419
|
+
});
|
|
1420
|
+
expect(tbodyCell.children.length).toBe(1);
|
|
1421
|
+
expect(tbodyCell.children[0].toJSON()).toEqual({
|
|
1422
|
+
id: expect.anything(),
|
|
1423
|
+
type: 'paragraph',
|
|
1424
|
+
annotations: { textStyle: 'paragraph' },
|
|
1425
|
+
nodes: [{ id: expect.anything(), text: '', type: 'text' }],
|
|
1426
|
+
});
|
|
1427
|
+
});
|
|
1428
|
+
it('should convert empty cell with default paragraph wrapper if autoMatchFormat is false', () => {
|
|
1429
|
+
const html = `<table>
|
|
1430
|
+
<thead>
|
|
1431
|
+
<tr>
|
|
1432
|
+
<th></th>
|
|
1433
|
+
<th>Header 2</th>
|
|
1434
|
+
</tr>
|
|
1435
|
+
</thead>
|
|
1436
|
+
<tbody>
|
|
1437
|
+
<tr>
|
|
1438
|
+
<td></td>
|
|
1439
|
+
<td>Cell 2</td>
|
|
1440
|
+
</tr>
|
|
1441
|
+
</tbody>
|
|
1442
|
+
</table>`;
|
|
1443
|
+
const value = VegaRTEContent.fromHtml(html, { autoMatchFormat: false });
|
|
1444
|
+
const table = value.children[0];
|
|
1445
|
+
const thead = table.children[0];
|
|
1446
|
+
const tbody = table.children[1];
|
|
1447
|
+
const theadRow = thead.children[0];
|
|
1448
|
+
const theadCell = theadRow.children[0];
|
|
1449
|
+
const tbodyRow = tbody.children[0];
|
|
1450
|
+
const tbodyCell = tbodyRow.children[0];
|
|
1451
|
+
expect(theadCell.children.length).toBe(1);
|
|
1452
|
+
expect(theadCell.children[0].toJSON()).toEqual({
|
|
1453
|
+
id: expect.anything(),
|
|
1454
|
+
type: 'paragraph',
|
|
1455
|
+
annotations: { internalWrapper: true },
|
|
1456
|
+
nodes: [{ id: expect.anything(), annotations: { plainText: true }, text: '', type: 'text' }],
|
|
1457
|
+
});
|
|
1458
|
+
expect(tbodyCell.children.length).toBe(1);
|
|
1459
|
+
expect(tbodyCell.children[0].toJSON()).toEqual({
|
|
1460
|
+
id: expect.anything(),
|
|
1461
|
+
type: 'paragraph',
|
|
1462
|
+
annotations: { internalWrapper: true },
|
|
1463
|
+
nodes: [{ id: expect.anything(), annotations: { plainText: true }, text: '', type: 'text' }],
|
|
1464
|
+
});
|
|
1465
|
+
});
|
|
1466
|
+
it('should convert changed minWidth and boxSizing', () => {
|
|
1467
|
+
const html = `<table style="border-collapse: collapse;margin: 0 auto;">
|
|
1468
|
+
<tbody>
|
|
1469
|
+
<tr>
|
|
1470
|
+
<td style="padding: 12px;border: solid 1px #ddd;text-align: left;vertical-align: middle;min-width: 100px;box-sizing: border-box;">
|
|
1471
|
+
<p style="font-family: Inter;font-size: 16px;line-height: 22px;min-height: 22px;font-weight: 500;margin-top: 0px;margin-bottom: 0px;">
|
|
1472
|
+
<span>A</span>
|
|
1473
|
+
</p>
|
|
1474
|
+
</td>
|
|
1475
|
+
<td style="padding: 12px;border: solid 1px #ddd;text-align: left;vertical-align: middle;min-width: 55px;box-sizing: content-box;">
|
|
1476
|
+
<p style="font-family: Inter;font-size: 16px;line-height: 22px;min-height: 22px;font-weight: 500;margin-top: 0px;margin-bottom: 0px;">
|
|
1477
|
+
<span>B</span>
|
|
1478
|
+
</p>
|
|
1479
|
+
</td>
|
|
1480
|
+
</tr>
|
|
1481
|
+
<tr>
|
|
1482
|
+
<td style="padding: 12px;border: solid 1px #ddd;text-align: left;vertical-align: middle;min-width: 55px;box-sizing: border-box;">
|
|
1483
|
+
<p style="font-family: Inter;font-size: 16px;line-height: 22px;min-height: 22px;font-weight: 500;margin-top: 0px;margin-bottom: 0px;">
|
|
1484
|
+
<span>C</span>
|
|
1485
|
+
</p>
|
|
1486
|
+
</td>
|
|
1487
|
+
<td style="padding: 12px;border: solid 1px #ddd;text-align: left;vertical-align: middle;min-width: 55px;box-sizing: border-box;">
|
|
1488
|
+
<p style="font-family: Inter;font-size: 16px;line-height: 22px;min-height: 22px;font-weight: 500;margin-top: 0px;margin-bottom: 0px;">
|
|
1489
|
+
<span>D</span>
|
|
1490
|
+
</p>
|
|
1491
|
+
</td>
|
|
1492
|
+
</tr>
|
|
1493
|
+
</tbody>
|
|
1494
|
+
</table>`;
|
|
1495
|
+
const value = VegaRTEContent.fromHtml(html);
|
|
1496
|
+
const jsonValue = value.toJSON()[0];
|
|
1497
|
+
const tbody = jsonValue.children[0];
|
|
1498
|
+
const firstRow = tbody.children[0];
|
|
1499
|
+
const firstCell = firstRow.children[0];
|
|
1500
|
+
const secondCell = firstRow.children[1];
|
|
1501
|
+
expect(firstCell.annotations.tableCell.minWidth).toBe('100px');
|
|
1502
|
+
expect(secondCell.annotations.tableCell.boxSizing).toBe('content-box');
|
|
1503
|
+
expect(firstCell.annotations.customStyle.minWidth).toBe('100px');
|
|
1504
|
+
expect(secondCell.annotations.customStyle.boxSizing).toBe('content-box');
|
|
1505
|
+
expect(value.toHtml()).toEqualHtml(html);
|
|
1506
|
+
});
|
|
1507
|
+
it('should convert changed minWidth and boxSizing when autoMatchFormat is false', () => {
|
|
1508
|
+
const html = `<table style="border-collapse: collapse;margin: 0 auto;">
|
|
1509
|
+
<tbody>
|
|
1510
|
+
<tr>
|
|
1511
|
+
<td style="padding: 12px;border: solid 1px #ddd;text-align: left;vertical-align: middle;min-width: 100px;box-sizing: border-box;">
|
|
1512
|
+
<p><span>A</span></p>
|
|
1513
|
+
</td>
|
|
1514
|
+
<td style="padding: 12px;border: solid 1px #ddd;text-align: left;vertical-align: middle;min-width: 55px;box-sizing: content-box;">
|
|
1515
|
+
<p><span>B</span></p>
|
|
1516
|
+
</td>
|
|
1517
|
+
</tr>
|
|
1518
|
+
<tr>
|
|
1519
|
+
<td style="padding: 12px;border: solid 1px #ddd;text-align: left;vertical-align: middle;min-width: 55px;box-sizing: border-box;">
|
|
1520
|
+
<p><span>C</span></p>
|
|
1521
|
+
</td>
|
|
1522
|
+
<td style="padding: 12px;border: solid 1px #ddd;text-align: left;vertical-align: middle;min-width: 55px;box-sizing: border-box;">
|
|
1523
|
+
<p><span>D</span></p>
|
|
1524
|
+
</td>
|
|
1525
|
+
</tr>
|
|
1526
|
+
</tbody>
|
|
1527
|
+
</table>`;
|
|
1528
|
+
const value = VegaRTEContent.fromHtml(html, { autoMatchFormat: false });
|
|
1529
|
+
const jsonValue = value.toJSON()[0];
|
|
1530
|
+
const tbody = jsonValue.children[0];
|
|
1531
|
+
const firstRow = tbody.children[0];
|
|
1532
|
+
const firstCell = firstRow.children[0];
|
|
1533
|
+
const secondCell = firstRow.children[1];
|
|
1534
|
+
expect(firstCell.annotations.tableCell.minWidth).toBe('100px');
|
|
1535
|
+
expect(secondCell.annotations.tableCell.boxSizing).toBe('content-box');
|
|
1536
|
+
expect(firstCell.annotations.customStyle.minWidth).toBe('100px');
|
|
1537
|
+
expect(secondCell.annotations.customStyle.boxSizing).toBe('content-box');
|
|
1538
|
+
expect(value.toHtml()).toEqualHtml(html);
|
|
1539
|
+
});
|
|
1540
|
+
it('should convert table head cell background color to default when it matches the default', () => {
|
|
1541
|
+
var _a, _b, _c, _d;
|
|
1542
|
+
const html = `<table style="border-collapse: collapse;margin: 0 auto;">
|
|
1543
|
+
<thead>
|
|
1544
|
+
<tr>
|
|
1545
|
+
<th style="background-color: rgb(240, 243, 247)">
|
|
1546
|
+
<p><span>A</span></p>
|
|
1547
|
+
</th>
|
|
1548
|
+
</tr>
|
|
1549
|
+
</thead>
|
|
1550
|
+
</table>`;
|
|
1551
|
+
const value = VegaRTEContent.fromHtml(html, { autoMatchFormat: false });
|
|
1552
|
+
const jsonValue = value.toJSON()[0];
|
|
1553
|
+
const thead = jsonValue.children[0];
|
|
1554
|
+
const firstRow = thead.children[0];
|
|
1555
|
+
const firstCell = firstRow.children[0];
|
|
1556
|
+
expect((_b = (_a = firstCell.annotations) === null || _a === void 0 ? void 0 : _a.tableCell) === null || _b === void 0 ? void 0 : _b.backgroundColor).toBeUndefined();
|
|
1557
|
+
expect((_d = (_c = firstCell.annotations) === null || _c === void 0 ? void 0 : _c.customStyle) === null || _d === void 0 ? void 0 : _d.backgroundColor).toBeUndefined();
|
|
1558
|
+
});
|
|
1559
|
+
it('should convert table head cell background color to default when it matches the default in dark mode', () => {
|
|
1560
|
+
var _a, _b, _c, _d;
|
|
1561
|
+
VegaInternalThemeManager.toggleDarkMode(true);
|
|
1562
|
+
const html = `<table style="border-collapse: collapse;margin: 0 auto;">
|
|
1563
|
+
<thead>
|
|
1564
|
+
<tr>
|
|
1565
|
+
<th style="background-color: rgb(24, 24, 48)">
|
|
1566
|
+
<p><span>A</span></p>
|
|
1567
|
+
</th>
|
|
1568
|
+
</tr>
|
|
1569
|
+
</thead>
|
|
1570
|
+
</table>`;
|
|
1571
|
+
const value = VegaRTEContent.fromHtml(html, { autoMatchFormat: false });
|
|
1572
|
+
const jsonValue = value.toJSON()[0];
|
|
1573
|
+
const thead = jsonValue.children[0];
|
|
1574
|
+
const firstRow = thead.children[0];
|
|
1575
|
+
const firstCell = firstRow.children[0];
|
|
1576
|
+
expect((_b = (_a = firstCell.annotations) === null || _a === void 0 ? void 0 : _a.tableCell) === null || _b === void 0 ? void 0 : _b.backgroundColor).toBeUndefined();
|
|
1577
|
+
expect((_d = (_c = firstCell.annotations) === null || _c === void 0 ? void 0 : _c.customStyle) === null || _d === void 0 ? void 0 : _d.backgroundColor).toBeUndefined();
|
|
1578
|
+
VegaInternalThemeManager.toggleDarkMode(false);
|
|
1579
|
+
});
|
|
1580
|
+
it('should convert table caption background color to default when it matches the default', () => {
|
|
1581
|
+
var _a, _b;
|
|
1582
|
+
const html = `<table style="border-collapse: collapse;margin: 0 auto;">
|
|
1583
|
+
<caption style="background-color: rgb(240, 243, 247)"></caption>
|
|
1584
|
+
</table>`;
|
|
1585
|
+
const value = VegaRTEContent.fromHtml(html, { autoMatchFormat: false });
|
|
1586
|
+
const jsonValue = value.toJSON()[0];
|
|
1587
|
+
const caption = jsonValue.children[0];
|
|
1588
|
+
expect((_b = (_a = caption.annotations) === null || _a === void 0 ? void 0 : _a.customStyle) === null || _b === void 0 ? void 0 : _b.backgroundColor).toBeUndefined();
|
|
1589
|
+
});
|
|
1590
|
+
});
|