@heartlandone/vega 2.79.0 → 2.80.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (1025) hide show
  1. package/dist/cjs/{app-globals-e9fdfbf9.js → app-globals-7a48292d.js} +6 -6
  2. package/dist/cjs/{aria-dialog-focusable-trap-slimmer-6faafc3e.js → aria-dialog-focusable-trap-slimmer-5a0a78fe.js} +60 -6
  3. package/dist/cjs/{child-nodes-notify-observer-slimmer-06c78f97.js → child-nodes-notify-observer-slimmer-a8d13f4c.js} +1 -1
  4. package/dist/cjs/{code-block-847534e3.js → code-block-71a330a1.js} +124 -56
  5. package/dist/cjs/{component-value-history-controller-slimmer.abstract-d7f9812a.js → component-value-history-controller-slimmer.abstract-fd077a6c.js} +6 -6
  6. package/dist/cjs/{content-state-99be18a3.js → content-state-afa26456.js} +401 -18
  7. package/dist/cjs/{date-required-rule-3823d506.js → date-required-rule-9f0e3e99.js} +1 -1
  8. package/dist/cjs/{design-token-b497bb6e.js → design-token-3f9589eb.js} +2 -2
  9. package/dist/cjs/{dom-node-subject-observer-factory-f7ed3bdc.js → dom-node-subject-observer-factory-a3a60da4.js} +1 -1
  10. package/dist/cjs/{element-appender-slimmer-eba4f3a2.js → element-appender-slimmer-7a66229b.js} +5 -5
  11. package/dist/cjs/{event-emit-slimmer-83f8e2bd.js → event-emit-slimmer-024e26bb.js} +1 -1
  12. package/dist/cjs/{form-field-controller-slimmer-93ca7239.js → form-field-controller-slimmer-c487cf2b.js} +4 -4
  13. package/dist/cjs/{image-annotation-action-9d6af380.js → image-annotation-action-4e72af4b.js} +3 -3
  14. package/dist/cjs/index.cjs.js +15 -15
  15. package/dist/cjs/{inject-keyboard-manager-23d07d87.js → inject-keyboard-manager-d1a82089.js} +1 -1
  16. package/dist/cjs/{keyboard-manager-3923e29b.js → keyboard-manager-9dbbb0d4.js} +13 -5
  17. package/dist/cjs/{keyboard-manager-slimmer-f602725d.js → keyboard-manager-slimmer-68cff676.js} +1 -1
  18. package/dist/cjs/loader.cjs.js +10 -10
  19. package/dist/cjs/{month-view-generator-aa8e8e74.js → month-view-generator-65a2f883.js} +2 -3
  20. package/dist/cjs/{public-rules-1dbda124.js → public-rules-36f202b3.js} +9 -9
  21. package/dist/cjs/{range-60fb9dd2.js → range-fa15d524.js} +2 -2
  22. package/dist/cjs/{responsive-format-facade-a32cdb67.js → responsive-format-facade-4419b4ae.js} +1 -1
  23. package/dist/cjs/{rich-text-editor-required-rule-b4aab68d.js → rich-text-editor-required-rule-7d4c2973.js} +1 -1
  24. package/dist/cjs/{split-cell-operation-190d4a87.js → split-cell-operation-19f98afb.js} +4 -4
  25. package/dist/cjs/{string-format-strategy.abstract-730088ee.js → string-format-strategy.abstract-c65d9861.js} +5 -2
  26. package/dist/cjs/{string-input-formatter-slimmer-9d6df58b.js → string-input-formatter-slimmer-c2e04acc.js} +4 -4
  27. package/dist/cjs/{string-mask-strategy-b69e3b9e.js → string-mask-strategy-418fc0b8.js} +40 -9
  28. package/dist/cjs/{style-formatter-9d8a4ad2.js → style-formatter-3c9ce0e5.js} +2 -2
  29. package/dist/cjs/{sub-state-notify-slimmer-c80b9d21.js → sub-state-notify-slimmer-7a4c6061.js} +2 -2
  30. package/dist/cjs/{sub-state-observer-slimmer-15740c97.js → sub-state-observer-slimmer-f728e068.js} +3 -3
  31. package/dist/cjs/{time-required-rule-6524b650.js → time-required-rule-ad091302.js} +1 -1
  32. package/dist/cjs/{token-extension-b7c4ea17.js → token-extension-90396de7.js} +7 -7
  33. package/dist/cjs/{type-guard-2a46bca5.js → type-guard-d760850a.js} +11 -0
  34. package/dist/cjs/{ui-b3db0122.js → ui-9e8c9732.js} +8 -2
  35. package/dist/cjs/{valid-credit-card-number-rule-8eb02ea7.js → valid-credit-card-number-rule-5ce8e973.js} +1 -1
  36. package/dist/cjs/vega-accordion.cjs.entry.js +6 -6
  37. package/dist/cjs/vega-app-header-button.cjs.entry.js +6 -6
  38. package/dist/cjs/vega-backdrop.cjs.entry.js +1 -1
  39. package/dist/cjs/vega-banner.cjs.entry.js +3 -3
  40. package/dist/cjs/vega-box.cjs.entry.js +5 -5
  41. package/dist/cjs/vega-breadcrumb.cjs.entry.js +3 -3
  42. package/dist/cjs/vega-button-circle.cjs.entry.js +7 -7
  43. package/dist/cjs/vega-button-group_2.cjs.entry.js +6 -6
  44. package/dist/cjs/vega-button-link.cjs.entry.js +3 -3
  45. package/dist/cjs/vega-button.cjs.entry.js +6 -6
  46. package/dist/cjs/vega-calendar_4.cjs.entry.js +30 -17
  47. package/dist/cjs/vega-card.cjs.entry.js +4 -4
  48. package/dist/cjs/vega-carousel.cjs.entry.js +5 -5
  49. package/dist/cjs/vega-checkbox_2.cjs.entry.js +7 -7
  50. package/dist/cjs/vega-chip.cjs.entry.js +6 -6
  51. package/dist/cjs/vega-code-block.cjs.entry.js +10 -10
  52. package/dist/cjs/vega-color-picker.cjs.entry.js +6 -6
  53. package/dist/cjs/vega-combo-box.cjs.entry.js +9 -9
  54. package/dist/cjs/vega-date-picker_2.cjs.entry.js +23 -23
  55. package/dist/cjs/vega-dialog_2.cjs.entry.js +8 -7
  56. package/dist/cjs/vega-divider.cjs.entry.js +3 -3
  57. package/dist/cjs/vega-dropdown_5.cjs.entry.js +12 -12
  58. package/dist/cjs/vega-env-manager-23b8b23c.js +2 -2
  59. package/dist/cjs/vega-field-label.cjs.entry.js +3 -3
  60. package/dist/cjs/vega-file-uploader.cjs.entry.js +6 -6
  61. package/dist/cjs/vega-flag-icon.cjs.entry.js +3 -3
  62. package/dist/cjs/vega-flex.cjs.entry.js +5 -5
  63. package/dist/cjs/vega-font.cjs.entry.js +4 -4
  64. package/dist/cjs/vega-form.cjs.entry.js +9 -9
  65. package/dist/cjs/vega-grid.cjs.entry.js +4 -4
  66. package/dist/cjs/vega-icon.cjs.entry.js +4 -4
  67. package/dist/cjs/vega-image-uploader.cjs.entry.js +8 -8
  68. package/dist/cjs/vega-input-credit-card.cjs.entry.js +10 -10
  69. package/dist/cjs/vega-input-numeric.cjs.entry.js +10 -10
  70. package/dist/cjs/vega-input-passcode.cjs.entry.js +9 -9
  71. package/dist/cjs/vega-input-phone-number.cjs.entry.js +8 -8
  72. package/dist/cjs/vega-input-range.cjs.entry.js +6 -6
  73. package/dist/cjs/vega-input-select.cjs.entry.js +8 -8
  74. package/dist/cjs/vega-input.cjs.entry.js +37 -27
  75. package/dist/cjs/{vega-internal-event-id-67bb91c1.js → vega-internal-event-id-a1837fa2.js} +2 -0
  76. package/dist/cjs/vega-item-toggle.cjs.entry.js +3 -3
  77. package/dist/cjs/vega-left-nav_5.cjs.entry.js +9 -9
  78. package/dist/cjs/vega-loader-wrapper_2.cjs.entry.js +3 -3
  79. package/dist/cjs/vega-page-notification_2.cjs.entry.js +2 -2
  80. package/dist/cjs/vega-pagination-page-selector-mobile.cjs.entry.js +3 -3
  81. package/dist/cjs/vega-pagination-page-size-selector-mobile.cjs.entry.js +3 -3
  82. package/dist/cjs/vega-pagination.cjs.entry.js +6 -6
  83. package/dist/cjs/vega-popover_2.cjs.entry.js +48 -12
  84. package/dist/cjs/vega-progress-tracker_2.cjs.entry.js +8 -8
  85. package/dist/cjs/vega-radio_2.cjs.entry.js +10 -10
  86. package/dist/cjs/vega-rich-text-content.cjs.entry.js +9 -9
  87. package/dist/cjs/vega-rich-text-editor_4.cjs.entry.js +17 -17
  88. package/dist/cjs/vega-rich-text-table-properties_3.cjs.entry.js +9 -9
  89. package/dist/cjs/vega-segment-control.cjs.entry.js +3 -3
  90. package/dist/cjs/vega-selection-chip_2.cjs.entry.js +9 -9
  91. package/dist/cjs/vega-selection-tile_2.cjs.entry.js +8 -8
  92. package/dist/cjs/vega-sidenav_3.cjs.entry.js +8 -8
  93. package/dist/cjs/vega-signature-capture.cjs.entry.js +9 -9
  94. package/dist/cjs/vega-stepper.cjs.entry.js +6 -6
  95. package/dist/cjs/vega-tab-group_2.cjs.entry.js +3 -3
  96. package/dist/cjs/vega-table_11.cjs.entry.js +8 -8
  97. package/dist/cjs/vega-text.cjs.entry.js +1 -1
  98. package/dist/cjs/vega-textarea.cjs.entry.js +6 -6
  99. package/dist/cjs/vega-time-picker_2.cjs.entry.js +12 -12
  100. package/dist/cjs/vega-toggle-switch.cjs.entry.js +6 -6
  101. package/dist/cjs/vega-tooltip_2.cjs.entry.js +8 -8
  102. package/dist/cjs/vega.cjs.js +10 -10
  103. package/dist/cjs/{wait-for-component-did-render-9e41b39e.js → wait-for-component-did-render-b6aba2de.js} +2 -2
  104. package/dist/collection/components/vega-calendar/vega-calendar-event/slimmers/renderers/vega-calendar-event-renderer.js +4 -4
  105. package/dist/collection/components/vega-calendar/vega-calendar-event/vega-calendar-event.css +15 -12
  106. package/dist/collection/components/vega-calendar/vega-calendar-event/vega-calendar-event.js +1 -1
  107. package/dist/collection/components/vega-calendar/vega-calendar-event-preview/slimmers/renderers/vega-calendar-event-preview-detail-renderer.js +17 -3
  108. package/dist/collection/components/vega-calendar/vega-calendar.css +1 -1
  109. package/dist/collection/components/vega-date-picker/vega-date-picker-calendar/slimmers/renderers/vega-date-picker-month-item-renderer.js +5 -5
  110. package/dist/collection/components/vega-input/slimmers/controllers/vega-input-mask-config-controller.js +13 -12
  111. package/dist/collection/components/vega-input/vega-input.js +1 -1
  112. package/dist/collection/components/vega-popover/slimmers/controllers/vega-popover-appender-controller.js +25 -1
  113. package/dist/collection/components/vega-popover/vega-popover-content-box/vega-popover-content-box.js +6 -1
  114. package/dist/collection/components/vega-popover/vega-popover.js +7 -0
  115. package/dist/collection/components/vega-rich-text-editor/dto/annotations/bold-annotation.js +2 -1
  116. package/dist/collection/components/vega-rich-text-editor/dto/annotations/code-annotation.js +13 -6
  117. package/dist/collection/components/vega-rich-text-editor/dto/annotations/horizontal-alignment-annotation.js +18 -9
  118. package/dist/collection/components/vega-rich-text-editor/dto/annotations/image-annotation.js +11 -1
  119. package/dist/collection/components/vega-rich-text-editor/dto/annotations/italic-annotation.js +2 -1
  120. package/dist/collection/components/vega-rich-text-editor/dto/annotations/link-group-annotation.js +12 -1
  121. package/dist/collection/components/vega-rich-text-editor/dto/annotations/list-annotation.js +12 -4
  122. package/dist/collection/components/vega-rich-text-editor/dto/annotations/strikethrough-annotation.js +2 -1
  123. package/dist/collection/components/vega-rich-text-editor/dto/annotations/text-format-default-styles.js +22 -0
  124. package/dist/collection/components/vega-rich-text-editor/dto/annotations/text-style-annotation.js +43 -32
  125. package/dist/collection/components/vega-rich-text-editor/dto/annotations/underline-annotation.js +2 -1
  126. package/dist/collection/components/vega-rich-text-editor/dto/filter-styles-strategies/filter-styles-strategy.abstract.js +31 -0
  127. package/dist/collection/components/vega-rich-text-editor/dto/filter-styles-strategies/image-node/image-filter-styles-strategy.js +16 -0
  128. package/dist/collection/components/vega-rich-text-editor/dto/filter-styles-strategies/list-block/list-block-filter-styles-strategy.js +12 -0
  129. package/dist/collection/components/vega-rich-text-editor/dto/filter-styles-strategies/list-block/list-item-block-filter-styles-strategy.js +13 -0
  130. package/dist/collection/components/vega-rich-text-editor/dto/filter-styles-strategies/text-block/alignment-filter-styles-strategy.js +39 -0
  131. package/dist/collection/components/vega-rich-text-editor/dto/filter-styles-strategies/text-node/code-filter-styles-strategy.js +26 -0
  132. package/dist/collection/components/vega-rich-text-editor/dto/filter-styles-strategies/text-node/link-filter-styles-strategy.js +30 -0
  133. package/dist/collection/components/vega-rich-text-editor/dto/filter-styles-strategies/text-node/text-format-filter-styles-strategy.js +89 -0
  134. package/dist/collection/components/vega-rich-text-editor/dto/setup.js +18 -0
  135. package/dist/collection/components/vega-rich-text-editor/slimmers/controllers/helper/element-to-dto-strategy/annotation-handler/bold-annotaion-handler.js +3 -2
  136. package/dist/collection/components/vega-rich-text-editor/slimmers/controllers/helper/element-to-dto-strategy/annotation-handler/html-element-to-annotation-generator.js +40 -2
  137. package/dist/collection/components/vega-rich-text-editor/slimmers/controllers/helper/element-to-dto-strategy/annotation-handler/italic-annotation-handler.js +2 -1
  138. package/dist/collection/components/vega-rich-text-editor/slimmers/controllers/helper/element-to-dto-strategy/annotation-handler/strike-through-annotation-handler.js +2 -1
  139. package/dist/collection/components/vega-rich-text-editor/slimmers/controllers/helper/element-to-dto-strategy/annotation-handler/text-style-annotation-handler.js +3 -1
  140. package/dist/collection/components/vega-rich-text-editor/slimmers/controllers/helper/element-to-dto-strategy/annotation-handler/underline-annotation-handler.js +2 -1
  141. package/dist/collection/helpers/calendar/calendar-date.js +10 -0
  142. package/dist/collection/helpers/calendar/calendar-view-generator/calendar-view-generator.abstract.js +2 -2
  143. package/dist/collection/helpers/event-manager/event-id/vega-internal-event-id.js +1 -0
  144. package/dist/collection/helpers/formatter/string-formatter/custom-formatter-strategy.js +3 -1
  145. package/dist/collection/helpers/formatter/string-formatter/number-mask-strategy.js +3 -1
  146. package/dist/collection/helpers/formatter/string-formatter/number-thousand-comma-strategy.js +3 -2
  147. package/dist/collection/helpers/formatter/string-formatter/string-format-strategy.abstract.js +4 -1
  148. package/dist/collection/helpers/formatter/string-formatter/string-mask-strategy.js +38 -7
  149. package/dist/collection/helpers/formatter/string-formatter/thousand-comma-strategy.js +4 -0
  150. package/dist/collection/helpers/keyboard/keyboard-manager.js +11 -3
  151. package/dist/collection/helpers/slimmers/aria-dialog-focusable-trap-slimmer.js +59 -5
  152. package/dist/collection/utils/ui.js +8 -2
  153. package/dist/esm/{app-globals-776ccaa3.js → app-globals-e77015e3.js} +6 -6
  154. package/dist/esm/{aria-dialog-focusable-trap-slimmer-cc98a7a4.js → aria-dialog-focusable-trap-slimmer-5a2f92be.js} +60 -6
  155. package/dist/esm/{child-nodes-notify-observer-slimmer-c7297b9f.js → child-nodes-notify-observer-slimmer-b7f0e419.js} +1 -1
  156. package/dist/esm/{code-block-58d1dbe5.js → code-block-7d6f231b.js} +117 -57
  157. package/dist/esm/{component-value-history-controller-slimmer.abstract-5beb8acb.js → component-value-history-controller-slimmer.abstract-acf65b17.js} +6 -6
  158. package/dist/esm/{content-state-dad1fd71.js → content-state-084cd705.js} +401 -18
  159. package/dist/esm/{date-required-rule-4c40a4eb.js → date-required-rule-29608215.js} +1 -1
  160. package/dist/esm/{design-token-9c4eb6b1.js → design-token-edcd787b.js} +2 -2
  161. package/dist/esm/{dom-node-subject-observer-factory-94b2e2c3.js → dom-node-subject-observer-factory-cea9248d.js} +1 -1
  162. package/dist/esm/{element-appender-slimmer-fde815dc.js → element-appender-slimmer-08ec429b.js} +5 -5
  163. package/dist/esm/{event-emit-slimmer-b236945b.js → event-emit-slimmer-4fba1b35.js} +1 -1
  164. package/dist/esm/{form-field-controller-slimmer-00fa3678.js → form-field-controller-slimmer-8dd39707.js} +4 -4
  165. package/dist/esm/{image-annotation-action-1ec7b461.js → image-annotation-action-a6b33a81.js} +3 -3
  166. package/dist/esm/index.js +15 -15
  167. package/dist/esm/{inject-keyboard-manager-784b1364.js → inject-keyboard-manager-7557816f.js} +1 -1
  168. package/dist/esm/{keyboard-manager-e020039f.js → keyboard-manager-1846c6a5.js} +13 -5
  169. package/dist/esm/{keyboard-manager-slimmer-4722d20c.js → keyboard-manager-slimmer-1ae0aa4d.js} +1 -1
  170. package/dist/esm/loader.js +10 -10
  171. package/dist/esm/{month-view-generator-6fe1f491.js → month-view-generator-b700ed08.js} +2 -3
  172. package/dist/esm/{public-rules-1626fb0d.js → public-rules-fe2c7934.js} +9 -9
  173. package/dist/esm/{range-4f9bf69d.js → range-00afe462.js} +2 -2
  174. package/dist/esm/{responsive-format-facade-e8534e59.js → responsive-format-facade-37d4d850.js} +1 -1
  175. package/dist/esm/{rich-text-editor-required-rule-c391aeb6.js → rich-text-editor-required-rule-6487ec94.js} +1 -1
  176. package/dist/esm/{split-cell-operation-55cd9fae.js → split-cell-operation-9445e642.js} +4 -4
  177. package/dist/esm/{string-format-strategy.abstract-8c48e515.js → string-format-strategy.abstract-ec6d627b.js} +5 -2
  178. package/dist/esm/{string-input-formatter-slimmer-519480ce.js → string-input-formatter-slimmer-959dff7a.js} +4 -4
  179. package/dist/esm/{string-mask-strategy-8070817e.js → string-mask-strategy-49be41f0.js} +40 -9
  180. package/dist/esm/{style-formatter-7afd0680.js → style-formatter-ad0b2bac.js} +2 -2
  181. package/dist/esm/{sub-state-notify-slimmer-54531808.js → sub-state-notify-slimmer-ee8c417b.js} +2 -2
  182. package/dist/esm/{sub-state-observer-slimmer-b3a773c5.js → sub-state-observer-slimmer-4d30fa5c.js} +3 -3
  183. package/dist/esm/{time-required-rule-2569e5ad.js → time-required-rule-414b1590.js} +1 -1
  184. package/dist/esm/{token-extension-612575cb.js → token-extension-600b1c88.js} +7 -7
  185. package/dist/esm/{type-guard-c20cbbff.js → type-guard-23a08026.js} +11 -1
  186. package/dist/esm/{ui-ac244bf0.js → ui-ba5a4758.js} +8 -2
  187. package/dist/esm/{valid-credit-card-number-rule-b9c3c2f8.js → valid-credit-card-number-rule-60abddac.js} +1 -1
  188. package/dist/esm/vega-accordion.entry.js +6 -6
  189. package/dist/esm/vega-app-header-button.entry.js +6 -6
  190. package/dist/esm/vega-backdrop.entry.js +1 -1
  191. package/dist/esm/vega-banner.entry.js +3 -3
  192. package/dist/esm/vega-box.entry.js +5 -5
  193. package/dist/esm/vega-breadcrumb.entry.js +3 -3
  194. package/dist/esm/vega-button-circle.entry.js +7 -7
  195. package/dist/esm/vega-button-group_2.entry.js +6 -6
  196. package/dist/esm/vega-button-link.entry.js +3 -3
  197. package/dist/esm/vega-button.entry.js +6 -6
  198. package/dist/esm/vega-calendar_4.entry.js +30 -17
  199. package/dist/esm/vega-card.entry.js +4 -4
  200. package/dist/esm/vega-carousel.entry.js +5 -5
  201. package/dist/esm/vega-checkbox_2.entry.js +7 -7
  202. package/dist/esm/vega-chip.entry.js +6 -6
  203. package/dist/esm/vega-code-block.entry.js +10 -10
  204. package/dist/esm/vega-color-picker.entry.js +6 -6
  205. package/dist/esm/vega-combo-box.entry.js +9 -9
  206. package/dist/esm/vega-date-picker_2.entry.js +23 -23
  207. package/dist/esm/vega-dialog_2.entry.js +8 -7
  208. package/dist/esm/vega-divider.entry.js +3 -3
  209. package/dist/esm/vega-dropdown_5.entry.js +12 -12
  210. package/dist/esm/vega-env-manager-8f8dc473.js +2 -2
  211. package/dist/esm/vega-field-label.entry.js +3 -3
  212. package/dist/esm/vega-file-uploader.entry.js +6 -6
  213. package/dist/esm/vega-flag-icon.entry.js +3 -3
  214. package/dist/esm/vega-flex.entry.js +5 -5
  215. package/dist/esm/vega-font.entry.js +4 -4
  216. package/dist/esm/vega-form.entry.js +9 -9
  217. package/dist/esm/vega-grid.entry.js +4 -4
  218. package/dist/esm/vega-icon.entry.js +4 -4
  219. package/dist/esm/vega-image-uploader.entry.js +8 -8
  220. package/dist/esm/vega-input-credit-card.entry.js +10 -10
  221. package/dist/esm/vega-input-numeric.entry.js +10 -10
  222. package/dist/esm/vega-input-passcode.entry.js +9 -9
  223. package/dist/esm/vega-input-phone-number.entry.js +8 -8
  224. package/dist/esm/vega-input-range.entry.js +6 -6
  225. package/dist/esm/vega-input-select.entry.js +8 -8
  226. package/dist/esm/vega-input.entry.js +37 -27
  227. package/dist/esm/{vega-internal-event-id-8002b179.js → vega-internal-event-id-70bd893d.js} +2 -1
  228. package/dist/esm/vega-item-toggle.entry.js +3 -3
  229. package/dist/esm/vega-left-nav_5.entry.js +9 -9
  230. package/dist/esm/vega-loader-wrapper_2.entry.js +3 -3
  231. package/dist/esm/vega-page-notification_2.entry.js +2 -2
  232. package/dist/esm/vega-pagination-page-selector-mobile.entry.js +3 -3
  233. package/dist/esm/vega-pagination-page-size-selector-mobile.entry.js +3 -3
  234. package/dist/esm/vega-pagination.entry.js +6 -6
  235. package/dist/esm/vega-popover_2.entry.js +48 -12
  236. package/dist/esm/vega-progress-tracker_2.entry.js +8 -8
  237. package/dist/esm/vega-radio_2.entry.js +10 -10
  238. package/dist/esm/vega-rich-text-content.entry.js +9 -9
  239. package/dist/esm/vega-rich-text-editor_4.entry.js +17 -17
  240. package/dist/esm/vega-rich-text-table-properties_3.entry.js +9 -9
  241. package/dist/esm/vega-segment-control.entry.js +3 -3
  242. package/dist/esm/vega-selection-chip_2.entry.js +9 -9
  243. package/dist/esm/vega-selection-tile_2.entry.js +8 -8
  244. package/dist/esm/vega-sidenav_3.entry.js +8 -8
  245. package/dist/esm/vega-signature-capture.entry.js +9 -9
  246. package/dist/esm/vega-stepper.entry.js +6 -6
  247. package/dist/esm/vega-tab-group_2.entry.js +3 -3
  248. package/dist/esm/vega-table_11.entry.js +8 -8
  249. package/dist/esm/vega-text.entry.js +1 -1
  250. package/dist/esm/vega-textarea.entry.js +6 -6
  251. package/dist/esm/vega-time-picker_2.entry.js +12 -12
  252. package/dist/esm/vega-toggle-switch.entry.js +6 -6
  253. package/dist/esm/vega-tooltip_2.entry.js +8 -8
  254. package/dist/esm/vega.js +10 -10
  255. package/dist/esm/{wait-for-component-did-render-1e62d6f7.js → wait-for-component-did-render-03e7ccb2.js} +2 -2
  256. package/dist/sri/vega-sri-manifest.json +346 -346
  257. package/dist/types/components/vega-calendar/vega-calendar-event-preview/slimmers/renderers/vega-calendar-event-preview-detail-renderer.d.ts +5 -0
  258. package/dist/types/components/vega-input/slimmers/controllers/vega-input-mask-config-controller.d.ts +1 -0
  259. package/dist/types/components/vega-input/types.d.ts +30 -1
  260. package/dist/types/components/vega-popover/slimmers/controllers/vega-popover-appender-controller.d.ts +6 -0
  261. package/dist/types/components/vega-rich-text-editor/dto/annotations/code-annotation.d.ts +6 -0
  262. package/dist/types/components/vega-rich-text-editor/dto/annotations/horizontal-alignment-annotation.d.ts +7 -0
  263. package/dist/types/components/vega-rich-text-editor/dto/annotations/image-annotation.d.ts +6 -0
  264. package/dist/types/components/vega-rich-text-editor/dto/annotations/link-group-annotation.d.ts +7 -0
  265. package/dist/types/components/vega-rich-text-editor/dto/annotations/list-annotation.d.ts +6 -0
  266. package/dist/types/components/vega-rich-text-editor/dto/annotations/text-format-default-styles.d.ts +22 -0
  267. package/dist/types/components/vega-rich-text-editor/dto/annotations/text-style-annotation.d.ts +7 -0
  268. package/dist/types/components/vega-rich-text-editor/dto/filter-styles-strategies/filter-styles-strategy.abstract.d.ts +20 -0
  269. package/dist/types/components/vega-rich-text-editor/dto/filter-styles-strategies/image-node/image-filter-styles-strategy.d.ts +10 -0
  270. package/dist/types/components/vega-rich-text-editor/dto/filter-styles-strategies/list-block/list-block-filter-styles-strategy.d.ts +8 -0
  271. package/dist/types/components/vega-rich-text-editor/dto/filter-styles-strategies/list-block/list-item-block-filter-styles-strategy.d.ts +9 -0
  272. package/dist/types/components/vega-rich-text-editor/dto/filter-styles-strategies/text-block/alignment-filter-styles-strategy.d.ts +27 -0
  273. package/dist/types/components/vega-rich-text-editor/dto/filter-styles-strategies/text-node/code-filter-styles-strategy.d.ts +17 -0
  274. package/dist/types/components/vega-rich-text-editor/dto/filter-styles-strategies/text-node/link-filter-styles-strategy.d.ts +17 -0
  275. package/dist/types/components/vega-rich-text-editor/dto/filter-styles-strategies/text-node/text-format-filter-styles-strategy.d.ts +41 -0
  276. package/dist/types/components/vega-rich-text-editor/slimmers/controllers/helper/element-to-dto-strategy/annotation-handler/html-element-to-annotation-generator.d.ts +10 -0
  277. package/dist/types/helpers/calendar/calendar-date.d.ts +7 -0
  278. package/dist/types/helpers/calendar/calendar-view-generator/calendar-view-generator.abstract.d.ts +0 -1
  279. package/dist/types/helpers/event-manager/event-id/vega-internal-event-id.d.ts +1 -0
  280. package/dist/types/helpers/formatter/string-formatter/custom-formatter-strategy.d.ts +2 -1
  281. package/dist/types/helpers/formatter/string-formatter/number-mask-strategy.d.ts +2 -1
  282. package/dist/types/helpers/formatter/string-formatter/number-thousand-comma-strategy.d.ts +2 -1
  283. package/dist/types/helpers/formatter/string-formatter/string-format-strategy.abstract.d.ts +1 -0
  284. package/dist/types/helpers/formatter/string-formatter/string-mask-strategy.d.ts +32 -4
  285. package/dist/types/helpers/formatter/string-formatter/thousand-comma-strategy.d.ts +1 -0
  286. package/dist/types/helpers/keyboard/keyboard-manager.d.ts +1 -0
  287. package/dist/types/helpers/slimmers/aria-dialog-focusable-trap-slimmer.d.ts +19 -0
  288. package/dist/types/utils/ui.d.ts +3 -1
  289. package/dist/vega/index.esm.js +1 -1
  290. package/dist/vega/{p-8cd70b3b.js → p-010b5e74.js} +1 -1
  291. package/dist/vega/{p-33cacbd6.entry.js → p-01883ffc.entry.js} +1 -1
  292. package/dist/vega/{p-7f68abf7.js → p-02578a59.js} +1 -1
  293. package/dist/vega/{p-916ef5dd.entry.js → p-0313393d.entry.js} +1 -1
  294. package/dist/vega/p-043e685a.entry.js +1 -0
  295. package/dist/vega/{p-972c594b.entry.js → p-04e56b0c.entry.js} +1 -1
  296. package/dist/vega/p-07a2b42a.js +1 -0
  297. package/dist/vega/{p-fb92092b.entry.js → p-08780df0.entry.js} +1 -1
  298. package/dist/vega/p-10fa4eac.js +1 -0
  299. package/dist/vega/{p-19adff1f.entry.js → p-1557ed92.entry.js} +1 -1
  300. package/dist/vega/{p-405ab757.js → p-18619467.js} +1 -1
  301. package/dist/vega/{p-a5543b6a.entry.js → p-19ad4f15.entry.js} +1 -1
  302. package/dist/vega/{p-46c7763f.entry.js → p-1a2f92a3.entry.js} +1 -1
  303. package/dist/vega/{p-085d45c9.js → p-1c45565d.js} +1 -1
  304. package/dist/vega/{p-b91aff06.entry.js → p-1feb4f2a.entry.js} +1 -1
  305. package/dist/vega/{p-14dfdba3.entry.js → p-203bc4db.entry.js} +1 -1
  306. package/dist/vega/{p-6e13e2fc.js → p-204c7d41.js} +1 -1
  307. package/dist/vega/{p-833b79ad.entry.js → p-21c9e1ca.entry.js} +1 -1
  308. package/dist/vega/p-22336063.js +1 -0
  309. package/dist/vega/{p-1784724a.entry.js → p-224b67ff.entry.js} +1 -1
  310. package/dist/vega/{p-dccda3d1.js → p-2c2df248.js} +1 -1
  311. package/dist/vega/{p-667d5b80.entry.js → p-2d917e2d.entry.js} +1 -1
  312. package/dist/vega/{p-02bab5ea.entry.js → p-2e73582d.entry.js} +1 -1
  313. package/dist/vega/{p-b7dd3ef2.entry.js → p-334e3b02.entry.js} +1 -1
  314. package/dist/vega/{p-6554a801.js → p-33860e54.js} +1 -1
  315. package/dist/vega/{p-dba91c23.entry.js → p-35386999.entry.js} +1 -1
  316. package/dist/vega/{p-bc142c5c.entry.js → p-365d21ac.entry.js} +1 -1
  317. package/dist/vega/{p-fadeb5a2.entry.js → p-367d44d9.entry.js} +1 -1
  318. package/dist/vega/{p-a6ad6515.entry.js → p-382b71a3.entry.js} +1 -1
  319. package/dist/vega/{p-b67672ae.entry.js → p-434fc427.entry.js} +1 -1
  320. package/dist/vega/p-44c5cbb7.js +1 -0
  321. package/dist/vega/{p-408a1baa.entry.js → p-47ca1f69.entry.js} +1 -1
  322. package/dist/vega/{p-5d397ee0.entry.js → p-4eb282ef.entry.js} +1 -1
  323. package/dist/vega/{p-b589cafd.entry.js → p-517434d4.entry.js} +1 -1
  324. package/dist/vega/p-559197f8.js +1 -0
  325. package/dist/vega/{p-6e05fc55.js → p-576fe408.js} +1 -1
  326. package/dist/vega/p-5ae4ea20.entry.js +1 -0
  327. package/dist/vega/p-5f377954.js +1 -1
  328. package/dist/vega/{p-b15a2d4b.js → p-60cf2a68.js} +1 -1
  329. package/dist/vega/p-612e3ded.js +1 -0
  330. package/dist/vega/{p-679a4046.entry.js → p-65900dbf.entry.js} +1 -1
  331. package/dist/vega/p-68124bc5.js +1 -0
  332. package/dist/vega/{p-28ed34b3.entry.js → p-6af55f1c.entry.js} +1 -1
  333. package/dist/vega/{p-5b90bbfe.js → p-6c5250b3.js} +1 -1
  334. package/dist/vega/p-6f2e5bc6.js +1 -0
  335. package/dist/vega/{p-439c7c13.entry.js → p-70f1cf4e.entry.js} +1 -1
  336. package/dist/vega/{p-a02f77c7.js → p-716c71e6.js} +1 -1
  337. package/dist/vega/{p-d862195c.entry.js → p-7362723e.entry.js} +1 -1
  338. package/dist/vega/{p-28c8ffb4.js → p-7618dde4.js} +1 -1
  339. package/dist/vega/p-76b80a0c.js +1 -0
  340. package/dist/vega/{p-937d5317.entry.js → p-7912741f.entry.js} +1 -1
  341. package/dist/vega/{p-6b19d33a.entry.js → p-7942c042.entry.js} +1 -1
  342. package/dist/vega/{p-820906b8.entry.js → p-7c2fecfd.entry.js} +1 -1
  343. package/dist/vega/{p-02fec68b.entry.js → p-7ceab8c7.entry.js} +1 -1
  344. package/dist/vega/p-8327635d.js +1 -0
  345. package/dist/vega/{p-db29681a.entry.js → p-840ad046.entry.js} +1 -1
  346. package/dist/vega/{p-4068e7de.js → p-878851f6.js} +1 -1
  347. package/dist/vega/{p-a2161e9d.js → p-89e56502.js} +1 -1
  348. package/dist/vega/{p-9e6e76b2.entry.js → p-8adf9732.entry.js} +1 -1
  349. package/dist/vega/{p-18378017.entry.js → p-90137c68.entry.js} +1 -1
  350. package/dist/vega/p-9341c1a9.js +1 -0
  351. package/dist/vega/{p-cb0324e7.entry.js → p-9390a94b.entry.js} +1 -1
  352. package/dist/vega/p-9551da9c.entry.js +1 -0
  353. package/dist/vega/p-9862d1a8.entry.js +1 -0
  354. package/dist/vega/{p-2bbbdf87.entry.js → p-9dc23325.entry.js} +1 -1
  355. package/dist/vega/p-a4dbf2cc.js +1 -0
  356. package/dist/vega/{p-561e9097.entry.js → p-a99e75a1.entry.js} +1 -1
  357. package/dist/vega/{p-b4d72eff.entry.js → p-ab21fdf6.entry.js} +1 -1
  358. package/dist/vega/{p-fc3d6d9d.js → p-b3e40faf.js} +1 -1
  359. package/dist/vega/{p-4ea3cf5f.entry.js → p-b5a6bd0f.entry.js} +1 -1
  360. package/dist/vega/{p-5dfd36d3.entry.js → p-b5c2fff3.entry.js} +1 -1
  361. package/dist/vega/{p-a0a39ec3.js → p-b696a861.js} +1 -1
  362. package/dist/vega/{p-076c6445.entry.js → p-ba415db6.entry.js} +1 -1
  363. package/dist/vega/{p-814c37be.entry.js → p-be3517be.entry.js} +1 -1
  364. package/dist/vega/{p-615bc3de.entry.js → p-c045e4c1.entry.js} +1 -1
  365. package/dist/vega/{p-4e76a84d.entry.js → p-c4e32125.entry.js} +1 -1
  366. package/dist/vega/{p-20981b17.entry.js → p-c5b698f6.entry.js} +1 -1
  367. package/dist/vega/{p-71720290.entry.js → p-c61279a7.entry.js} +1 -1
  368. package/dist/vega/p-c6d62f0d.js +1 -0
  369. package/dist/vega/{p-4e15958f.js → p-c9201bf4.js} +1 -1
  370. package/dist/vega/{p-ace7aa6c.entry.js → p-cc055723.entry.js} +1 -1
  371. package/dist/vega/{p-fc93b467.entry.js → p-cca5042b.entry.js} +1 -1
  372. package/dist/vega/{p-c58c3e7e.entry.js → p-cda45d2a.entry.js} +1 -1
  373. package/dist/vega/p-cdf5b2f0.entry.js +1 -0
  374. package/dist/vega/p-cf70c57d.js +1 -0
  375. package/dist/vega/{p-441fd2b3.entry.js → p-d1494c7c.entry.js} +1 -1
  376. package/dist/vega/{p-a6fb81c5.js → p-d1ca70a1.js} +1 -1
  377. package/dist/vega/p-d202e69d.entry.js +1 -0
  378. package/dist/vega/{p-dd4c3d9b.entry.js → p-dc9b5063.entry.js} +1 -1
  379. package/dist/vega/{p-d6875e49.js → p-dcd18ab1.js} +1 -1
  380. package/dist/vega/p-df5bfbc4.entry.js +1 -0
  381. package/dist/vega/{p-d5a8bb62.entry.js → p-e4726dcd.entry.js} +1 -1
  382. package/dist/vega/{p-76f2e0f5.js → p-e84b95d4.js} +1 -1
  383. package/dist/vega/p-ea21462f.js +1 -0
  384. package/dist/vega/{p-905cf163.entry.js → p-ec1d76c6.entry.js} +1 -1
  385. package/dist/vega/{p-04f9b0d4.entry.js → p-f3456993.entry.js} +1 -1
  386. package/dist/vega/{p-32a0eed4.entry.js → p-f4190826.entry.js} +1 -1
  387. package/dist/vega/{p-558a707e.entry.js → p-f48c43f4.entry.js} +1 -1
  388. package/dist/vega/{p-1665d4b8.entry.js → p-fdac91c4.entry.js} +1 -1
  389. package/dist/vega/{p-5395faac.entry.js → p-ffa2e3a6.entry.js} +1 -1
  390. package/dist/vega/vega.esm.js +1 -1
  391. package/package.json +3 -2
  392. package/dist/collection/components/vega-calendar/slimmers/common/helpers/test/calendar-event-repeat-pattern-factory.test.js +0 -195
  393. package/dist/collection/components/vega-calendar/slimmers/common/layout/test/long-event-layout-generator.test.js +0 -94
  394. package/dist/collection/components/vega-calendar/slimmers/day-view/renderers/timed-event/layout/test/day-view-event-layout-generator.test.js +0 -72
  395. package/dist/collection/components/vega-code-block/test/code-block-range.test.js +0 -81
  396. package/dist/collection/components/vega-dropdown/test/share.js +0 -13
  397. package/dist/collection/components/vega-input-credit-card/test/share.js +0 -21
  398. package/dist/collection/components/vega-nav/vega-left-nav/test/vega-left-nav-mock-data.js +0 -147
  399. package/dist/collection/components/vega-rich-text-editor/helpers/extension-context-manager.test.js +0 -21
  400. package/dist/collection/components/vega-rich-text-editor/test/dto/action-handle-strategies/action-handle-strategy-registry.test.js +0 -71
  401. package/dist/collection/components/vega-rich-text-editor/test/dto/action-handle-strategies/block-delete-node-content-strategy.test.js +0 -69
  402. package/dist/collection/components/vega-rich-text-editor/test/dto/action-handle-strategies/block-insert-line-break-with-blocks-strategy.test.js +0 -24
  403. package/dist/collection/components/vega-rich-text-editor/test/dto/action-handle-strategies/code-block-strategy-registry.test.js +0 -20
  404. package/dist/collection/components/vega-rich-text-editor/test/dto/action-handle-strategies/content-state-strategy-registry.test.js +0 -15
  405. package/dist/collection/components/vega-rich-text-editor/test/dto/action-handle-strategies/image-block-strategy-register.test.js +0 -32
  406. package/dist/collection/components/vega-rich-text-editor/test/dto/action-handle-strategies/image-set-annotation-map-strategy.test.js +0 -11
  407. package/dist/collection/components/vega-rich-text-editor/test/dto/action-handle-strategies/image-update-url-strategy.test.js +0 -16
  408. package/dist/collection/components/vega-rich-text-editor/test/dto/action-handle-strategies/list-block-strategy-register.test.js +0 -20
  409. package/dist/collection/components/vega-rich-text-editor/test/dto/action-handle-strategies/list-item-strategy-register.test.js +0 -87
  410. package/dist/collection/components/vega-rich-text-editor/test/dto/action-handle-strategies/node-split-text-strategy.test.js +0 -32
  411. package/dist/collection/components/vega-rich-text-editor/test/dto/action-handle-strategies/node-update-annotation-map-strategy.test.js +0 -17
  412. package/dist/collection/components/vega-rich-text-editor/test/dto/action-handle-strategies/text-block-strategy-register.test.js +0 -77
  413. package/dist/collection/components/vega-rich-text-editor/test/dto/action-handle-strategies/update-selected-text-strategy.test.js +0 -23
  414. package/dist/collection/components/vega-rich-text-editor/test/dto/annotation-actions.test.js +0 -39
  415. package/dist/collection/components/vega-rich-text-editor/test/dto/annotation-style.test.js +0 -71
  416. package/dist/collection/components/vega-rich-text-editor/test/dto/annotations.test.js +0 -381
  417. package/dist/collection/components/vega-rich-text-editor/test/dto/blocks/code-block.test.js +0 -54
  418. package/dist/collection/components/vega-rich-text-editor/test/dto/blocks/html-block.test.js +0 -167
  419. package/dist/collection/components/vega-rich-text-editor/test/dto/blocks/image-block.test.js +0 -90
  420. package/dist/collection/components/vega-rich-text-editor/test/dto/blocks/list-block.test.js +0 -176
  421. package/dist/collection/components/vega-rich-text-editor/test/dto/blocks/list-item.test.js +0 -188
  422. package/dist/collection/components/vega-rich-text-editor/test/dto/blocks/text-block.test.js +0 -193
  423. package/dist/collection/components/vega-rich-text-editor/test/dto/content-state.test.js +0 -3375
  424. package/dist/collection/components/vega-rich-text-editor/test/dto/nodes/image-node.test.js +0 -108
  425. package/dist/collection/components/vega-rich-text-editor/test/dto/nodes/text-node.test.js +0 -510
  426. package/dist/collection/components/vega-rich-text-editor/test/dto/range.test.js +0 -53
  427. package/dist/collection/components/vega-rich-text-editor/test/e2e-utils.js +0 -182
  428. package/dist/collection/components/vega-rich-text-editor/test/element-to-dto-strategy/custom-attribute-annotation-handler.test.js +0 -49
  429. package/dist/collection/components/vega-rich-text-editor/test/element-to-dto-strategy/element-to-text-node-strategy.test.js +0 -38
  430. package/dist/collection/components/vega-rich-text-editor/test/element-to-dto-strategy/html-element-to-annotation-generator.test.js +0 -26
  431. package/dist/collection/components/vega-rich-text-editor/test/element-to-dto-strategy/jira-code-to-rte-code-block-strategy.test.js +0 -32
  432. package/dist/collection/components/vega-rich-text-editor/test/element-to-dto-strategy/vega-code-block-to-rte-code-block-strategy.test.js +0 -61
  433. package/dist/collection/components/vega-rich-text-editor/test/extensions/extension-test-utils.js +0 -43
  434. package/dist/collection/components/vega-rich-text-editor/test/extensions/table/annotation-handler/annotation-handler-registration.test.js +0 -164
  435. package/dist/collection/components/vega-rich-text-editor/test/extensions/table/annotation-handler/table-annotation-handler.test.js +0 -298
  436. package/dist/collection/components/vega-rich-text-editor/test/extensions/table/annotation-handler/table-cell-annotation-handler.test.js +0 -316
  437. package/dist/collection/components/vega-rich-text-editor/test/extensions/table/annotation-handler/table-head-cell-annotation-handler.test.js +0 -411
  438. package/dist/collection/components/vega-rich-text-editor/test/extensions/table/caption-operation.test.js +0 -99
  439. package/dist/collection/components/vega-rich-text-editor/test/extensions/table/table-annotation.test.js +0 -181
  440. package/dist/collection/components/vega-rich-text-editor/test/extensions/table/table-caption-annotations.test.js +0 -84
  441. package/dist/collection/components/vega-rich-text-editor/test/extensions/table/table-cell-annotation.test.js +0 -331
  442. package/dist/collection/components/vega-rich-text-editor/test/extensions/table/table-color-annotation.test.js +0 -32
  443. package/dist/collection/components/vega-rich-text-editor/test/extensions/table/table-dto.test.js +0 -1094
  444. package/dist/collection/components/vega-rich-text-editor/test/extensions/table/table-element-to-dto-strategies.test.js +0 -1590
  445. package/dist/collection/components/vega-rich-text-editor/test/extensions/table/table-test-utils.js +0 -172
  446. package/dist/collection/components/vega-rich-text-editor/test/filter-styles-strategies/filter-styles-strategy.test.js +0 -129
  447. package/dist/collection/components/vega-rich-text-editor/test/fixture.js +0 -257
  448. package/dist/collection/components/vega-rich-text-editor/test/html-cleaner/html-content-cleaner.test.js +0 -186
  449. package/dist/collection/components/vega-rich-text-editor/test/html-cleaner/remove-whitespace-after-opening-tag-processor.test.js +0 -22
  450. package/dist/collection/components/vega-rich-text-editor/test/html-cleaner/remove-whitespace-before-closing-tag-processor.test.js +0 -22
  451. package/dist/collection/components/vega-rich-text-editor/test/html-cleaner/remove-whitespace-between-tags-processor.test.js +0 -26
  452. package/dist/collection/components/vega-rich-text-editor/test/spec-utils.js +0 -35
  453. package/dist/collection/components/vega-sidenav/test/test.helper.js +0 -68
  454. package/dist/collection/components/vega-table/slimmers/controllers/dto/test/column-render-input-model.test.js +0 -83
  455. package/dist/collection/components/vega-table/slimmers/controllers/dto/test/column-structure-model.test.js +0 -147
  456. package/dist/collection/components/vega-table/test/utils.js +0 -22
  457. package/dist/collection/components/vega-table/test/vega-table-sorter.test.js +0 -508
  458. package/dist/collection/constants/tests/validator.test.js +0 -24
  459. package/dist/collection/decorators/method-decorators/tests/component-load-required.test.js +0 -114
  460. package/dist/collection/decorators/property-decorators/tests/inject-element-appender-proxy.test.js +0 -237
  461. package/dist/collection/decorators/property-decorators/tests/inject-keyboard-manager.test.js +0 -91
  462. package/dist/collection/global/tests/before-vega-load.test.js +0 -62
  463. package/dist/collection/helpers/calendar/test/calendar-date-time.test.js +0 -27
  464. package/dist/collection/helpers/calendar/test/calendar-date.test.js +0 -172
  465. package/dist/collection/helpers/calendar/test/calendar-event.test.js +0 -263
  466. package/dist/collection/helpers/calendar/test/calendar-period/day-period.test.js +0 -118
  467. package/dist/collection/helpers/calendar/test/calendar-period/month-period.test.js +0 -144
  468. package/dist/collection/helpers/calendar/test/calendar-period/week-period.test.js +0 -114
  469. package/dist/collection/helpers/calendar/test/calendar-time.test.js +0 -45
  470. package/dist/collection/helpers/calendar/test/calendar-view-generator/day-view-generator.test.js +0 -19
  471. package/dist/collection/helpers/calendar/test/calendar-view-generator/month-view-generator.test.js +0 -123
  472. package/dist/collection/helpers/calendar/test/calendar-view-generator/week-view-generator.test.js +0 -43
  473. package/dist/collection/helpers/calendar/test/calendar-view.test.js +0 -9
  474. package/dist/collection/helpers/calendar/test/index.test.js +0 -13
  475. package/dist/collection/helpers/calendar/test/utils.test.js +0 -62
  476. package/dist/collection/helpers/change-manager/test/change-manager.test.js +0 -30
  477. package/dist/collection/helpers/change-manager/test/dom-node-subject-factory.test.js +0 -38
  478. package/dist/collection/helpers/chart/test/controllers/chart-dimension-controller.test.js +0 -63
  479. package/dist/collection/helpers/chart/test/drawers/arc-path-drawer.test.js +0 -55
  480. package/dist/collection/helpers/chart/test/drawers/legend-drawer.test.js +0 -94
  481. package/dist/collection/helpers/chart/test/drawers/line-drawer.test.js +0 -25
  482. package/dist/collection/helpers/chart/test/drawers/path-drawer.test.js +0 -21
  483. package/dist/collection/helpers/chart/test/drawers/rect-drawer.test.js +0 -78
  484. package/dist/collection/helpers/chart/test/drawers/text-drawer.test.js +0 -25
  485. package/dist/collection/helpers/chart/test/drawers/x-axis-drawer.test.js +0 -38
  486. package/dist/collection/helpers/chart/test/drawers/y-axis-drawer.test.js +0 -44
  487. package/dist/collection/helpers/chart/test/graph-context-factory.test.js +0 -17
  488. package/dist/collection/helpers/chart/test/input-processors/format-time-positions-input-processor.test.js +0 -62
  489. package/dist/collection/helpers/chart/test/input-processors/horizontal-x-axis-input-processor.test.js +0 -45
  490. package/dist/collection/helpers/chart/test/input-processors/horizontal-y-axis-input-processor.test.js +0 -80
  491. package/dist/collection/helpers/chart/test/input-processors/layout-input-processor.test.js +0 -40
  492. package/dist/collection/helpers/chart/test/input-processors/line-path-input-processor.test.js +0 -16
  493. package/dist/collection/helpers/chart/test/input-processors/pie-chart-filter-input-processor.test.js +0 -20
  494. package/dist/collection/helpers/chart/test/input-processors/pie-chart-radius-input-processor.test.js +0 -48
  495. package/dist/collection/helpers/chart/test/input-processors/sort-positions-input-processor.test.js +0 -53
  496. package/dist/collection/helpers/chart/test/input-processors/x-axis-input-processor.test.js +0 -78
  497. package/dist/collection/helpers/chart/test/input-processors/x-axis-label-formatter-input-processor.test.js +0 -109
  498. package/dist/collection/helpers/chart/test/input-processors/y-axis-input-processor.coverage.test.js +0 -39
  499. package/dist/collection/helpers/chart/test/input-processors/y-axis-input-processor.test.js +0 -55
  500. package/dist/collection/helpers/chart/test/interacting-entry-generator/arc-path-hover-generator.test.js +0 -11
  501. package/dist/collection/helpers/chart/test/interacting-entry-generator/pie-legend-hover-generator.test.js +0 -25
  502. package/dist/collection/helpers/chart/test/interactors/interactor-factory.test.js +0 -19
  503. package/dist/collection/helpers/chart/test/interactors/svg-interactor.test.js +0 -48
  504. package/dist/collection/helpers/chart/test/line-chart.test.js +0 -96
  505. package/dist/collection/helpers/chart/test/pie-chart.test.js +0 -38
  506. package/dist/collection/helpers/chart/test/renderers/canvas-renderer.test.js +0 -31
  507. package/dist/collection/helpers/chart/test/renderers/renderer-factory.test.js +0 -19
  508. package/dist/collection/helpers/chart/test/renderers/svg-renderer.test.js +0 -99
  509. package/dist/collection/helpers/code-format/test/code-formatter.test.js +0 -410
  510. package/dist/collection/helpers/common/test/common.test.js +0 -7
  511. package/dist/collection/helpers/common/test/wait-for-component-did-render.test.js +0 -67
  512. package/dist/collection/helpers/common/test/wait-for-vega-handler.test.js +0 -17
  513. package/dist/collection/helpers/csp/test/styles-preservator.test.js +0 -207
  514. package/dist/collection/helpers/csp/test/vega-nonce-manager.test.js +0 -177
  515. package/dist/collection/helpers/dialog/test/vega-dialog-controller.test.js +0 -114
  516. package/dist/collection/helpers/event-manager/test/child-nodes-event-prevent-slimmer.test.js +0 -209
  517. package/dist/collection/helpers/event-manager/test/child-nodes-notify-observer-slimmer.test.js +0 -81
  518. package/dist/collection/helpers/event-manager/test/component-event-id-map.test.js +0 -16
  519. package/dist/collection/helpers/event-manager/test/event-emit-slimmer.test.js +0 -144
  520. package/dist/collection/helpers/event-manager/test/internal-vega-event-manager.test.js +0 -70
  521. package/dist/collection/helpers/event-manager/test/jquery-delegated-strategy-controller.test.js +0 -131
  522. package/dist/collection/helpers/event-manager/test/vega-event-id.test.js +0 -16
  523. package/dist/collection/helpers/event-manager/test/vega-event-manager.test.js +0 -97
  524. package/dist/collection/helpers/feature-control/tests/feature-flag-controller.test.js +0 -69
  525. package/dist/collection/helpers/formatter/test/responsive-map-formatter/responsive-border-radius-formatter.test.js +0 -64
  526. package/dist/collection/helpers/formatter/test/responsive-map-formatter/responsive-border-radius-style-formatter.test.js +0 -32
  527. package/dist/collection/helpers/formatter/test/responsive-map-formatter/responsive-box-display-formatter.test.js +0 -31
  528. package/dist/collection/helpers/formatter/test/responsive-map-formatter/responsive-custom-formatter.test.js +0 -17
  529. package/dist/collection/helpers/formatter/test/responsive-map-formatter/responsive-display-formatter.test.js +0 -23
  530. package/dist/collection/helpers/formatter/test/responsive-map-formatter/responsive-flex-direction-formatter.test.js +0 -19
  531. package/dist/collection/helpers/formatter/test/responsive-map-formatter/responsive-flex-wrap-formatter.test.js +0 -19
  532. package/dist/collection/helpers/formatter/test/responsive-map-formatter/responsive-format-mediator.test.js +0 -43
  533. package/dist/collection/helpers/formatter/test/responsive-map-formatter/responsive-gap-formatter.ts.test.js +0 -29
  534. package/dist/collection/helpers/formatter/test/responsive-map-formatter/responsive-grid-column-formatter.test.js +0 -23
  535. package/dist/collection/helpers/formatter/test/responsive-map-formatter/responsive-grid-justify-items-formatter.test.js +0 -19
  536. package/dist/collection/helpers/formatter/test/responsive-map-formatter/responsive-grid-row-formatter.test.js +0 -27
  537. package/dist/collection/helpers/formatter/test/responsive-map-formatter/responsive-margin-formatter.test.js +0 -43
  538. package/dist/collection/helpers/formatter/test/responsive-map-formatter/responsive-margin-style-formatter.test.js +0 -28
  539. package/dist/collection/helpers/formatter/test/responsive-map-formatter/responsive-padding-formatter.test.js +0 -43
  540. package/dist/collection/helpers/formatter/test/responsive-map-formatter/responsive-padding-style-formatter.test.js +0 -28
  541. package/dist/collection/helpers/formatter/test/responsive-map-formatter/responsive-size-formatter.test.js +0 -27
  542. package/dist/collection/helpers/formatter/test/responsive-map-formatter/responsive-text-align-formatter.test.js +0 -19
  543. package/dist/collection/helpers/formatter/test/responsive-map-formatter/responsive-translocation-formatter.test.js +0 -51
  544. package/dist/collection/helpers/formatter/test/responsive-map-formatter/responsive-width-and-height-formatter.test.js +0 -20
  545. package/dist/collection/helpers/formatter/test/state-formatter/state-background-color-formatter.test.js +0 -18
  546. package/dist/collection/helpers/formatter/test/state-formatter/state-border-color-formatter.test.js +0 -13
  547. package/dist/collection/helpers/formatter/test/state-formatter/state-border-formatter.test.js +0 -13
  548. package/dist/collection/helpers/formatter/test/state-formatter/state-format-facade.test.js +0 -27
  549. package/dist/collection/helpers/formatter/test/state-formatter/state-shadow-formatter.test.js +0 -13
  550. package/dist/collection/helpers/formatter/test/string-formatter/custom-formatter-strategy.test.js +0 -13
  551. package/dist/collection/helpers/formatter/test/string-formatter/number-mask-strategy.test.js +0 -101
  552. package/dist/collection/helpers/formatter/test/string-formatter/number-thousand-comma-mask-strategy.test.js +0 -40
  553. package/dist/collection/helpers/formatter/test/string-formatter/string-mask-strategy.test.js +0 -147
  554. package/dist/collection/helpers/formatter/test/string-formatter/thousand-comma-strategy.test.js +0 -21
  555. package/dist/collection/helpers/formatter/test/string-formatter/vega-phone-number-input-strategy.test.js +0 -43
  556. package/dist/collection/helpers/formatter/test/style-formatter.test.js +0 -16
  557. package/dist/collection/helpers/icon/test/icon-manager-controller.test.js +0 -101
  558. package/dist/collection/helpers/icon/test/internal-icon-manager.test.js +0 -18
  559. package/dist/collection/helpers/immutable/test/immutable-array.test.js +0 -78
  560. package/dist/collection/helpers/immutable/test/immutable-map.test.js +0 -83
  561. package/dist/collection/helpers/immutable/test/immutable-set.test.js +0 -87
  562. package/dist/collection/helpers/keyboard/test/keyboard-manager.test.js +0 -241
  563. package/dist/collection/helpers/level-tracker/test/nested-level-tracker.test.js +0 -33
  564. package/dist/collection/helpers/loading-indicator/tests/vega-loader-controller.test.js +0 -192
  565. package/dist/collection/helpers/notify/tests/vega-notify-controller.test.js +0 -165
  566. package/dist/collection/helpers/paginator/test/value-paginator.test.js +0 -15
  567. package/dist/collection/helpers/queue/test/synchronize-task-queue.test.js +0 -76
  568. package/dist/collection/helpers/remote-invocation/remote-invocation-registry.test.js +0 -17
  569. package/dist/collection/helpers/rte-manager/rte.manager.test.js +0 -94
  570. package/dist/collection/helpers/skeleton-loader/tests/vega-skeleton-loader-controller.test.js +0 -194
  571. package/dist/collection/helpers/slimmers/element-appender/body-positioned-wrapper/test/vega-popover-wrapper.test.js +0 -66
  572. package/dist/collection/helpers/slimmers/element-appender/test/element-appender-slimmer.test.js +0 -621
  573. package/dist/collection/helpers/slimmers/mutation-observer/test/aria-attributes-value-mapper.test.js +0 -248
  574. package/dist/collection/helpers/slimmers/mutation-observer/test/data-tab-index-value-mapper.test.js +0 -120
  575. package/dist/collection/helpers/slimmers/mutation-observer/test/mutation-observer-slimmer.test.js +0 -182
  576. package/dist/collection/helpers/slimmers/position-calculation/test/body-position-calculation-strategy.test.js +0 -399
  577. package/dist/collection/helpers/slimmers/position-calculation/test/screen-position-calculation-strategy.test.js +0 -383
  578. package/dist/collection/helpers/slimmers/runtime-metrics/test/public-api-runtime-metrics-slimmer-base.test.js +0 -96
  579. package/dist/collection/helpers/slimmers/sub-state/test/sub-state-observer-slimmer.test.js +0 -228
  580. package/dist/collection/helpers/slimmers/test/aria-dialog-focusable-trap-slimmer.test.js +0 -375
  581. package/dist/collection/helpers/slimmers/test/auto-run-when-re-render-task-queue-slimmer.test.js +0 -46
  582. package/dist/collection/helpers/slimmers/test/brand-switch-state-controller-slimmer.test.js +0 -75
  583. package/dist/collection/helpers/slimmers/test/component-global-style-slimmer.test.js +0 -104
  584. package/dist/collection/helpers/slimmers/test/component-usage-runtime-metrics.test.js +0 -72
  585. package/dist/collection/helpers/slimmers/test/dark-mode-state-controller.test.js +0 -65
  586. package/dist/collection/helpers/slimmers/test/deprecated-property-slimmer.test.js +0 -36
  587. package/dist/collection/helpers/slimmers/test/field-error-controller-slimmer.test.js +0 -55
  588. package/dist/collection/helpers/slimmers/test/form-field-controller-slimmer.test.js +0 -278
  589. package/dist/collection/helpers/slimmers/test/form-field-valid-invoke-slimmer.test.js +0 -106
  590. package/dist/collection/helpers/slimmers/test/global/vega-nonce-injector-slimmer.test.js +0 -64
  591. package/dist/collection/helpers/slimmers/test/global/vega-translate-observer-slimmer.test.js +0 -89
  592. package/dist/collection/helpers/slimmers/test/global/vega-watch-method-cancel-slimmer.test.js +0 -101
  593. package/dist/collection/helpers/slimmers/test/keyboard-manager-slimmer.test.js +0 -90
  594. package/dist/collection/helpers/slimmers/test/page-resize-observer-slimmer.test.js +0 -278
  595. package/dist/collection/helpers/slimmers/test/string-input-formatter-slimmer.test.js +0 -220
  596. package/dist/collection/helpers/slimmers/test/translation-slimmer.test.js +0 -89
  597. package/dist/collection/helpers/theme/tests/theme-manager-controller.test.js +0 -614
  598. package/dist/collection/helpers/touch-helper/test/touch-listener.test.js +0 -122
  599. package/dist/collection/helpers/translation/tests/internal-translation-controller.test.js +0 -288
  600. package/dist/collection/helpers/translation/tests/translation.test.js +0 -46
  601. package/dist/collection/helpers/ui/test/element-appender.test.js +0 -530
  602. package/dist/collection/helpers/validator/test/rules/check-box-required-rule.test.js +0 -88
  603. package/dist/collection/helpers/validator/test/rules/custom-validation-rule.test.js +0 -56
  604. package/dist/collection/helpers/validator/test/rules/date-range-rule.test.js +0 -67
  605. package/dist/collection/helpers/validator/test/rules/date-required-rule.test.js +0 -120
  606. package/dist/collection/helpers/validator/test/rules/email-field-rule.test.js +0 -69
  607. package/dist/collection/helpers/validator/test/rules/file-uploader-required-rule.test.js +0 -7
  608. package/dist/collection/helpers/validator/test/rules/input-phone-number-required-rule.test.js +0 -105
  609. package/dist/collection/helpers/validator/test/rules/input-range-min-and-max-rule.test.js +0 -146
  610. package/dist/collection/helpers/validator/test/rules/input-range-required-rule.test.js +0 -82
  611. package/dist/collection/helpers/validator/test/rules/input-select-value-in-source-rule.test.js +0 -99
  612. package/dist/collection/helpers/validator/test/rules/max-number-rule.test.js +0 -97
  613. package/dist/collection/helpers/validator/test/rules/max-string-length-rule.test.js +0 -85
  614. package/dist/collection/helpers/validator/test/rules/min-and-max-date-rule.test.js +0 -174
  615. package/dist/collection/helpers/validator/test/rules/min-number-rule.test.js +0 -97
  616. package/dist/collection/helpers/validator/test/rules/min-string-length-rule.test.js +0 -85
  617. package/dist/collection/helpers/validator/test/rules/public-rules.test.js +0 -80
  618. package/dist/collection/helpers/validator/test/rules/required-field-rule.test.js +0 -126
  619. package/dist/collection/helpers/validator/test/rules/rich-text-editor-required-rule.test.js +0 -360
  620. package/dist/collection/helpers/validator/test/rules/time-range-required-rule.test.js +0 -82
  621. package/dist/collection/helpers/validator/test/rules/time-range-rule.test.js +0 -67
  622. package/dist/collection/helpers/validator/test/rules/time-required-rule.test.js +0 -116
  623. package/dist/collection/helpers/validator/test/rules/toggle-switch-required-rule.test.js +0 -72
  624. package/dist/collection/helpers/validator/test/rules/valid-credit-card-number-rule.test.js +0 -135
  625. package/dist/collection/helpers/validator/test/rules/valid-phone-number-rule.test.js +0 -95
  626. package/dist/collection/helpers/validator/test/validation-rule-handler/form-field-validation-rule-handler-chain.test.js +0 -65
  627. package/dist/collection/helpers/validator/test/validation-rule-handler/form-field-validation-rule-handler.test.js +0 -82
  628. package/dist/collection/helpers/validator/test/validator/form-field-controller.test.js +0 -205
  629. package/dist/collection/helpers/vega-telemetry-helper/test/vega-env-manager.test.js +0 -14
  630. package/dist/collection/helpers/zindex/test/internal-vega-z-index-manager.test.js +0 -176
  631. package/dist/collection/helpers/zindex/test/vega-z-index-manager.test.js +0 -46
  632. package/dist/collection/polyfill/d3/test/d3-array-polyfill.test.js +0 -72
  633. package/dist/collection/polyfill/d3/test/d3-axis-polyfill.test.js +0 -171
  634. package/dist/collection/polyfill/d3/test/d3-integration.test.js +0 -137
  635. package/dist/collection/polyfill/d3/test/d3-scale-polyfill.test.js +0 -382
  636. package/dist/collection/polyfill/d3/test/d3-selection-polyfill.test.js +0 -239
  637. package/dist/collection/polyfill/d3/test/d3-shape-polyfill.test.js +0 -225
  638. package/dist/collection/polyfill/d3/test/d3-time-format-polyfill.test.js +0 -162
  639. package/dist/collection/polyfill/d3/test/d3-time-polyfill.test.js +0 -76
  640. package/dist/collection/polyfill/d3/test/index.test.js +0 -78
  641. package/dist/collection/polyfill/libphonenumber/test/as-you-type.test.js +0 -309
  642. package/dist/collection/polyfill/libphonenumber/test/format-helpers.test.js +0 -192
  643. package/dist/collection/polyfill/libphonenumber/test/index.test.js +0 -16
  644. package/dist/collection/polyfill/libphonenumber/test/metadata.test.js +0 -196
  645. package/dist/collection/polyfill/libphonenumber/test/parse-phone-number.test.js +0 -218
  646. package/dist/collection/polyfill/libphonenumber/test/phone-number.test.js +0 -56
  647. package/dist/collection/polyfill/prism/test/css.test.js +0 -61
  648. package/dist/collection/polyfill/prism/test/javascript.test.js +0 -113
  649. package/dist/collection/polyfill/prism/test/jsx.test.js +0 -48
  650. package/dist/collection/polyfill/prism/test/language-registry.test.js +0 -77
  651. package/dist/collection/polyfill/prism/test/markup.test.js +0 -57
  652. package/dist/collection/polyfill/prism/test/test-utils.js +0 -22
  653. package/dist/collection/polyfill/prism/test/tokenizer.test.js +0 -180
  654. package/dist/collection/polyfill/prism/test/tsx.test.js +0 -87
  655. package/dist/collection/polyfill/prism/test/typescript.test.js +0 -86
  656. package/dist/collection/polyfill/shadow-selection/test/shadow-selection-polyfill.test.js +0 -234
  657. package/dist/collection/polyfill/test-polyfill/e2e/retry.js +0 -42
  658. package/dist/collection/polyfill/test-polyfill/unit/create-touch-event.js +0 -31
  659. package/dist/collection/polyfill/test-polyfill/unit/events.js +0 -100
  660. package/dist/collection/polyfill/test-polyfill/unit/index.js +0 -3
  661. package/dist/collection/polyfill/test-polyfill/unit/methods.js +0 -47
  662. package/dist/collection/polyfill/test-polyfill/unit/range.js +0 -15
  663. package/dist/collection/polyfill/test-polyfill/unit/shadow-selection.js +0 -17
  664. package/dist/collection/polyfill/tinycolor/tinycolor-polyfill.test.js +0 -361
  665. package/dist/collection/test-assets/test-icons.js +0 -5
  666. package/dist/collection/types/test/type-guard.test.js +0 -46
  667. package/dist/collection/utils/e2e-utils.js +0 -389
  668. package/dist/collection/utils/sanitize/test/empty-strategy.test.js +0 -12
  669. package/dist/collection/utils/sanitize/test/html-sanitizer.test.js +0 -57
  670. package/dist/collection/utils/sanitize/test/label-strategy.test.js +0 -56
  671. package/dist/collection/utils/sanitize/test/sanitize-strategy.test.js +0 -85
  672. package/dist/collection/utils/sanitize/test/sanitize.test.js +0 -22
  673. package/dist/collection/utils/sanitize/test/serialize-fragment.test.js +0 -25
  674. package/dist/collection/utils/sanitize/test/style-strategy.test.js +0 -45
  675. package/dist/collection/utils/spec-utils.js +0 -226
  676. package/dist/collection/utils/test/accessibility.test.js +0 -40
  677. package/dist/collection/utils/test/api.test.js +0 -34
  678. package/dist/collection/utils/test/array.test.js +0 -260
  679. package/dist/collection/utils/test/breakpoint.test.js +0 -37
  680. package/dist/collection/utils/test/component.test.js +0 -59
  681. package/dist/collection/utils/test/date.test.js +0 -104
  682. package/dist/collection/utils/test/design-token.test.js +0 -91
  683. package/dist/collection/utils/test/effect.test.js +0 -64
  684. package/dist/collection/utils/test/local-storage.test.js +0 -38
  685. package/dist/collection/utils/test/log.test.js +0 -49
  686. package/dist/collection/utils/test/misc.test.js +0 -40
  687. package/dist/collection/utils/test/number.test.js +0 -18
  688. package/dist/collection/utils/test/object.test.js +0 -77
  689. package/dist/collection/utils/test/pagination.test.js +0 -40
  690. package/dist/collection/utils/test/pixel.test.js +0 -29
  691. package/dist/collection/utils/test/safe-document.test.js +0 -13
  692. package/dist/collection/utils/test/spec-utils.test.js +0 -73
  693. package/dist/collection/utils/test/string.test.js +0 -8
  694. package/dist/collection/utils/test/test-utils.test.js +0 -70
  695. package/dist/collection/utils/test/timer.test.js +0 -16
  696. package/dist/collection/utils/test/ui.test.js +0 -301
  697. package/dist/collection/utils/test-utils.js +0 -156
  698. package/dist/types/components/vega-calendar/slimmers/common/helpers/test/calendar-event-repeat-pattern-factory.test.d.ts +0 -1
  699. package/dist/types/components/vega-calendar/slimmers/common/layout/test/long-event-layout-generator.test.d.ts +0 -1
  700. package/dist/types/components/vega-calendar/slimmers/day-view/renderers/timed-event/layout/test/day-view-event-layout-generator.test.d.ts +0 -1
  701. package/dist/types/components/vega-code-block/test/code-block-range.test.d.ts +0 -1
  702. package/dist/types/components/vega-dropdown/test/share.d.ts +0 -12
  703. package/dist/types/components/vega-input-credit-card/test/share.d.ts +0 -18
  704. package/dist/types/components/vega-nav/vega-left-nav/test/vega-left-nav-mock-data.d.ts +0 -4
  705. package/dist/types/components/vega-rich-text-editor/helpers/extension-context-manager.test.d.ts +0 -1
  706. package/dist/types/components/vega-rich-text-editor/test/dto/action-handle-strategies/action-handle-strategy-registry.test.d.ts +0 -1
  707. package/dist/types/components/vega-rich-text-editor/test/dto/action-handle-strategies/block-delete-node-content-strategy.test.d.ts +0 -1
  708. package/dist/types/components/vega-rich-text-editor/test/dto/action-handle-strategies/block-insert-line-break-with-blocks-strategy.test.d.ts +0 -1
  709. package/dist/types/components/vega-rich-text-editor/test/dto/action-handle-strategies/code-block-strategy-registry.test.d.ts +0 -1
  710. package/dist/types/components/vega-rich-text-editor/test/dto/action-handle-strategies/content-state-strategy-registry.test.d.ts +0 -1
  711. package/dist/types/components/vega-rich-text-editor/test/dto/action-handle-strategies/image-block-strategy-register.test.d.ts +0 -1
  712. package/dist/types/components/vega-rich-text-editor/test/dto/action-handle-strategies/image-set-annotation-map-strategy.test.d.ts +0 -1
  713. package/dist/types/components/vega-rich-text-editor/test/dto/action-handle-strategies/image-update-url-strategy.test.d.ts +0 -1
  714. package/dist/types/components/vega-rich-text-editor/test/dto/action-handle-strategies/list-block-strategy-register.test.d.ts +0 -1
  715. package/dist/types/components/vega-rich-text-editor/test/dto/action-handle-strategies/list-item-strategy-register.test.d.ts +0 -1
  716. package/dist/types/components/vega-rich-text-editor/test/dto/action-handle-strategies/node-split-text-strategy.test.d.ts +0 -1
  717. package/dist/types/components/vega-rich-text-editor/test/dto/action-handle-strategies/node-update-annotation-map-strategy.test.d.ts +0 -1
  718. package/dist/types/components/vega-rich-text-editor/test/dto/action-handle-strategies/text-block-strategy-register.test.d.ts +0 -1
  719. package/dist/types/components/vega-rich-text-editor/test/dto/action-handle-strategies/update-selected-text-strategy.test.d.ts +0 -1
  720. package/dist/types/components/vega-rich-text-editor/test/dto/annotation-actions.test.d.ts +0 -1
  721. package/dist/types/components/vega-rich-text-editor/test/dto/annotation-style.test.d.ts +0 -1
  722. package/dist/types/components/vega-rich-text-editor/test/dto/annotations.test.d.ts +0 -1
  723. package/dist/types/components/vega-rich-text-editor/test/dto/blocks/code-block.test.d.ts +0 -1
  724. package/dist/types/components/vega-rich-text-editor/test/dto/blocks/html-block.test.d.ts +0 -1
  725. package/dist/types/components/vega-rich-text-editor/test/dto/blocks/image-block.test.d.ts +0 -1
  726. package/dist/types/components/vega-rich-text-editor/test/dto/blocks/list-block.test.d.ts +0 -1
  727. package/dist/types/components/vega-rich-text-editor/test/dto/blocks/list-item.test.d.ts +0 -1
  728. package/dist/types/components/vega-rich-text-editor/test/dto/blocks/text-block.test.d.ts +0 -1
  729. package/dist/types/components/vega-rich-text-editor/test/dto/content-state.test.d.ts +0 -1
  730. package/dist/types/components/vega-rich-text-editor/test/dto/nodes/image-node.test.d.ts +0 -1
  731. package/dist/types/components/vega-rich-text-editor/test/dto/nodes/text-node.test.d.ts +0 -1
  732. package/dist/types/components/vega-rich-text-editor/test/dto/range.test.d.ts +0 -1
  733. package/dist/types/components/vega-rich-text-editor/test/e2e-utils.d.ts +0 -67
  734. package/dist/types/components/vega-rich-text-editor/test/element-to-dto-strategy/custom-attribute-annotation-handler.test.d.ts +0 -1
  735. package/dist/types/components/vega-rich-text-editor/test/element-to-dto-strategy/element-to-text-node-strategy.test.d.ts +0 -1
  736. package/dist/types/components/vega-rich-text-editor/test/element-to-dto-strategy/html-element-to-annotation-generator.test.d.ts +0 -1
  737. package/dist/types/components/vega-rich-text-editor/test/element-to-dto-strategy/jira-code-to-rte-code-block-strategy.test.d.ts +0 -1
  738. package/dist/types/components/vega-rich-text-editor/test/element-to-dto-strategy/vega-code-block-to-rte-code-block-strategy.test.d.ts +0 -1
  739. package/dist/types/components/vega-rich-text-editor/test/extensions/extension-test-utils.d.ts +0 -21
  740. package/dist/types/components/vega-rich-text-editor/test/extensions/table/annotation-handler/annotation-handler-registration.test.d.ts +0 -1
  741. package/dist/types/components/vega-rich-text-editor/test/extensions/table/annotation-handler/table-annotation-handler.test.d.ts +0 -1
  742. package/dist/types/components/vega-rich-text-editor/test/extensions/table/annotation-handler/table-cell-annotation-handler.test.d.ts +0 -8
  743. package/dist/types/components/vega-rich-text-editor/test/extensions/table/annotation-handler/table-head-cell-annotation-handler.test.d.ts +0 -1
  744. package/dist/types/components/vega-rich-text-editor/test/extensions/table/caption-operation.test.d.ts +0 -1
  745. package/dist/types/components/vega-rich-text-editor/test/extensions/table/table-annotation.test.d.ts +0 -1
  746. package/dist/types/components/vega-rich-text-editor/test/extensions/table/table-caption-annotations.test.d.ts +0 -1
  747. package/dist/types/components/vega-rich-text-editor/test/extensions/table/table-cell-annotation.test.d.ts +0 -1
  748. package/dist/types/components/vega-rich-text-editor/test/extensions/table/table-color-annotation.test.d.ts +0 -1
  749. package/dist/types/components/vega-rich-text-editor/test/extensions/table/table-dto.test.d.ts +0 -1
  750. package/dist/types/components/vega-rich-text-editor/test/extensions/table/table-element-to-dto-strategies.test.d.ts +0 -1
  751. package/dist/types/components/vega-rich-text-editor/test/extensions/table/table-test-utils.d.ts +0 -11
  752. package/dist/types/components/vega-rich-text-editor/test/filter-styles-strategies/filter-styles-strategy.test.d.ts +0 -1
  753. package/dist/types/components/vega-rich-text-editor/test/fixture.d.ts +0 -19
  754. package/dist/types/components/vega-rich-text-editor/test/html-cleaner/html-content-cleaner.test.d.ts +0 -1
  755. package/dist/types/components/vega-rich-text-editor/test/html-cleaner/remove-whitespace-after-opening-tag-processor.test.d.ts +0 -1
  756. package/dist/types/components/vega-rich-text-editor/test/html-cleaner/remove-whitespace-before-closing-tag-processor.test.d.ts +0 -1
  757. package/dist/types/components/vega-rich-text-editor/test/html-cleaner/remove-whitespace-between-tags-processor.test.d.ts +0 -1
  758. package/dist/types/components/vega-rich-text-editor/test/spec-utils.d.ts +0 -19
  759. package/dist/types/components/vega-sidenav/test/test.helper.d.ts +0 -6
  760. package/dist/types/components/vega-table/slimmers/controllers/dto/test/column-render-input-model.test.d.ts +0 -1
  761. package/dist/types/components/vega-table/slimmers/controllers/dto/test/column-structure-model.test.d.ts +0 -1
  762. package/dist/types/components/vega-table/test/utils.d.ts +0 -9
  763. package/dist/types/components/vega-table/test/vega-table-sorter.test.d.ts +0 -1
  764. package/dist/types/constants/tests/validator.test.d.ts +0 -1
  765. package/dist/types/decorators/method-decorators/tests/component-load-required.test.d.ts +0 -1
  766. package/dist/types/decorators/property-decorators/tests/inject-element-appender-proxy.test.d.ts +0 -1
  767. package/dist/types/decorators/property-decorators/tests/inject-keyboard-manager.test.d.ts +0 -1
  768. package/dist/types/global/tests/before-vega-load.test.d.ts +0 -1
  769. package/dist/types/helpers/calendar/test/calendar-date-time.test.d.ts +0 -1
  770. package/dist/types/helpers/calendar/test/calendar-date.test.d.ts +0 -1
  771. package/dist/types/helpers/calendar/test/calendar-event.test.d.ts +0 -1
  772. package/dist/types/helpers/calendar/test/calendar-period/day-period.test.d.ts +0 -1
  773. package/dist/types/helpers/calendar/test/calendar-period/month-period.test.d.ts +0 -1
  774. package/dist/types/helpers/calendar/test/calendar-period/week-period.test.d.ts +0 -1
  775. package/dist/types/helpers/calendar/test/calendar-time.test.d.ts +0 -1
  776. package/dist/types/helpers/calendar/test/calendar-view-generator/day-view-generator.test.d.ts +0 -1
  777. package/dist/types/helpers/calendar/test/calendar-view-generator/month-view-generator.test.d.ts +0 -1
  778. package/dist/types/helpers/calendar/test/calendar-view-generator/week-view-generator.test.d.ts +0 -1
  779. package/dist/types/helpers/calendar/test/calendar-view.test.d.ts +0 -1
  780. package/dist/types/helpers/calendar/test/index.test.d.ts +0 -1
  781. package/dist/types/helpers/calendar/test/utils.test.d.ts +0 -1
  782. package/dist/types/helpers/change-manager/test/change-manager.test.d.ts +0 -1
  783. package/dist/types/helpers/change-manager/test/dom-node-subject-factory.test.d.ts +0 -1
  784. package/dist/types/helpers/chart/test/controllers/chart-dimension-controller.test.d.ts +0 -1
  785. package/dist/types/helpers/chart/test/drawers/arc-path-drawer.test.d.ts +0 -1
  786. package/dist/types/helpers/chart/test/drawers/legend-drawer.test.d.ts +0 -1
  787. package/dist/types/helpers/chart/test/drawers/line-drawer.test.d.ts +0 -1
  788. package/dist/types/helpers/chart/test/drawers/path-drawer.test.d.ts +0 -1
  789. package/dist/types/helpers/chart/test/drawers/rect-drawer.test.d.ts +0 -1
  790. package/dist/types/helpers/chart/test/drawers/text-drawer.test.d.ts +0 -1
  791. package/dist/types/helpers/chart/test/drawers/x-axis-drawer.test.d.ts +0 -1
  792. package/dist/types/helpers/chart/test/drawers/y-axis-drawer.test.d.ts +0 -1
  793. package/dist/types/helpers/chart/test/graph-context-factory.test.d.ts +0 -1
  794. package/dist/types/helpers/chart/test/input-processors/format-time-positions-input-processor.test.d.ts +0 -1
  795. package/dist/types/helpers/chart/test/input-processors/horizontal-x-axis-input-processor.test.d.ts +0 -1
  796. package/dist/types/helpers/chart/test/input-processors/horizontal-y-axis-input-processor.test.d.ts +0 -1
  797. package/dist/types/helpers/chart/test/input-processors/layout-input-processor.test.d.ts +0 -1
  798. package/dist/types/helpers/chart/test/input-processors/line-path-input-processor.test.d.ts +0 -1
  799. package/dist/types/helpers/chart/test/input-processors/pie-chart-filter-input-processor.test.d.ts +0 -1
  800. package/dist/types/helpers/chart/test/input-processors/pie-chart-radius-input-processor.test.d.ts +0 -1
  801. package/dist/types/helpers/chart/test/input-processors/sort-positions-input-processor.test.d.ts +0 -1
  802. package/dist/types/helpers/chart/test/input-processors/x-axis-input-processor.test.d.ts +0 -1
  803. package/dist/types/helpers/chart/test/input-processors/x-axis-label-formatter-input-processor.test.d.ts +0 -1
  804. package/dist/types/helpers/chart/test/input-processors/y-axis-input-processor.coverage.test.d.ts +0 -1
  805. package/dist/types/helpers/chart/test/input-processors/y-axis-input-processor.test.d.ts +0 -1
  806. package/dist/types/helpers/chart/test/interacting-entry-generator/arc-path-hover-generator.test.d.ts +0 -1
  807. package/dist/types/helpers/chart/test/interacting-entry-generator/pie-legend-hover-generator.test.d.ts +0 -1
  808. package/dist/types/helpers/chart/test/interactors/interactor-factory.test.d.ts +0 -1
  809. package/dist/types/helpers/chart/test/interactors/svg-interactor.test.d.ts +0 -1
  810. package/dist/types/helpers/chart/test/line-chart.test.d.ts +0 -1
  811. package/dist/types/helpers/chart/test/pie-chart.test.d.ts +0 -1
  812. package/dist/types/helpers/chart/test/renderers/canvas-renderer.test.d.ts +0 -1
  813. package/dist/types/helpers/chart/test/renderers/renderer-factory.test.d.ts +0 -1
  814. package/dist/types/helpers/chart/test/renderers/svg-renderer.test.d.ts +0 -1
  815. package/dist/types/helpers/code-format/test/code-formatter.test.d.ts +0 -1
  816. package/dist/types/helpers/common/test/common.test.d.ts +0 -1
  817. package/dist/types/helpers/common/test/wait-for-component-did-render.test.d.ts +0 -1
  818. package/dist/types/helpers/common/test/wait-for-vega-handler.test.d.ts +0 -1
  819. package/dist/types/helpers/csp/test/styles-preservator.test.d.ts +0 -1
  820. package/dist/types/helpers/csp/test/vega-nonce-manager.test.d.ts +0 -1
  821. package/dist/types/helpers/dialog/test/vega-dialog-controller.test.d.ts +0 -1
  822. package/dist/types/helpers/event-manager/test/child-nodes-event-prevent-slimmer.test.d.ts +0 -1
  823. package/dist/types/helpers/event-manager/test/child-nodes-notify-observer-slimmer.test.d.ts +0 -1
  824. package/dist/types/helpers/event-manager/test/component-event-id-map.test.d.ts +0 -1
  825. package/dist/types/helpers/event-manager/test/event-emit-slimmer.test.d.ts +0 -1
  826. package/dist/types/helpers/event-manager/test/internal-vega-event-manager.test.d.ts +0 -1
  827. package/dist/types/helpers/event-manager/test/jquery-delegated-strategy-controller.test.d.ts +0 -1
  828. package/dist/types/helpers/event-manager/test/vega-event-id.test.d.ts +0 -1
  829. package/dist/types/helpers/event-manager/test/vega-event-manager.test.d.ts +0 -1
  830. package/dist/types/helpers/feature-control/tests/feature-flag-controller.test.d.ts +0 -1
  831. package/dist/types/helpers/formatter/test/responsive-map-formatter/responsive-border-radius-formatter.test.d.ts +0 -1
  832. package/dist/types/helpers/formatter/test/responsive-map-formatter/responsive-border-radius-style-formatter.test.d.ts +0 -1
  833. package/dist/types/helpers/formatter/test/responsive-map-formatter/responsive-box-display-formatter.test.d.ts +0 -1
  834. package/dist/types/helpers/formatter/test/responsive-map-formatter/responsive-custom-formatter.test.d.ts +0 -1
  835. package/dist/types/helpers/formatter/test/responsive-map-formatter/responsive-display-formatter.test.d.ts +0 -1
  836. package/dist/types/helpers/formatter/test/responsive-map-formatter/responsive-flex-direction-formatter.test.d.ts +0 -1
  837. package/dist/types/helpers/formatter/test/responsive-map-formatter/responsive-flex-wrap-formatter.test.d.ts +0 -1
  838. package/dist/types/helpers/formatter/test/responsive-map-formatter/responsive-format-mediator.test.d.ts +0 -1
  839. package/dist/types/helpers/formatter/test/responsive-map-formatter/responsive-gap-formatter.ts.test.d.ts +0 -1
  840. package/dist/types/helpers/formatter/test/responsive-map-formatter/responsive-grid-column-formatter.test.d.ts +0 -1
  841. package/dist/types/helpers/formatter/test/responsive-map-formatter/responsive-grid-justify-items-formatter.test.d.ts +0 -1
  842. package/dist/types/helpers/formatter/test/responsive-map-formatter/responsive-grid-row-formatter.test.d.ts +0 -1
  843. package/dist/types/helpers/formatter/test/responsive-map-formatter/responsive-margin-formatter.test.d.ts +0 -1
  844. package/dist/types/helpers/formatter/test/responsive-map-formatter/responsive-margin-style-formatter.test.d.ts +0 -1
  845. package/dist/types/helpers/formatter/test/responsive-map-formatter/responsive-padding-formatter.test.d.ts +0 -1
  846. package/dist/types/helpers/formatter/test/responsive-map-formatter/responsive-padding-style-formatter.test.d.ts +0 -1
  847. package/dist/types/helpers/formatter/test/responsive-map-formatter/responsive-size-formatter.test.d.ts +0 -1
  848. package/dist/types/helpers/formatter/test/responsive-map-formatter/responsive-text-align-formatter.test.d.ts +0 -1
  849. package/dist/types/helpers/formatter/test/responsive-map-formatter/responsive-translocation-formatter.test.d.ts +0 -1
  850. package/dist/types/helpers/formatter/test/responsive-map-formatter/responsive-width-and-height-formatter.test.d.ts +0 -1
  851. package/dist/types/helpers/formatter/test/state-formatter/state-background-color-formatter.test.d.ts +0 -1
  852. package/dist/types/helpers/formatter/test/state-formatter/state-border-color-formatter.test.d.ts +0 -1
  853. package/dist/types/helpers/formatter/test/state-formatter/state-border-formatter.test.d.ts +0 -1
  854. package/dist/types/helpers/formatter/test/state-formatter/state-format-facade.test.d.ts +0 -1
  855. package/dist/types/helpers/formatter/test/state-formatter/state-shadow-formatter.test.d.ts +0 -1
  856. package/dist/types/helpers/formatter/test/string-formatter/custom-formatter-strategy.test.d.ts +0 -1
  857. package/dist/types/helpers/formatter/test/string-formatter/number-mask-strategy.test.d.ts +0 -1
  858. package/dist/types/helpers/formatter/test/string-formatter/number-thousand-comma-mask-strategy.test.d.ts +0 -1
  859. package/dist/types/helpers/formatter/test/string-formatter/string-mask-strategy.test.d.ts +0 -1
  860. package/dist/types/helpers/formatter/test/string-formatter/thousand-comma-strategy.test.d.ts +0 -1
  861. package/dist/types/helpers/formatter/test/string-formatter/vega-phone-number-input-strategy.test.d.ts +0 -1
  862. package/dist/types/helpers/formatter/test/style-formatter.test.d.ts +0 -1
  863. package/dist/types/helpers/icon/test/icon-manager-controller.test.d.ts +0 -1
  864. package/dist/types/helpers/icon/test/internal-icon-manager.test.d.ts +0 -1
  865. package/dist/types/helpers/immutable/test/immutable-array.test.d.ts +0 -1
  866. package/dist/types/helpers/immutable/test/immutable-map.test.d.ts +0 -1
  867. package/dist/types/helpers/immutable/test/immutable-set.test.d.ts +0 -1
  868. package/dist/types/helpers/keyboard/test/keyboard-manager.test.d.ts +0 -1
  869. package/dist/types/helpers/level-tracker/test/nested-level-tracker.test.d.ts +0 -1
  870. package/dist/types/helpers/loading-indicator/tests/vega-loader-controller.test.d.ts +0 -1
  871. package/dist/types/helpers/notify/tests/vega-notify-controller.test.d.ts +0 -1
  872. package/dist/types/helpers/paginator/test/value-paginator.test.d.ts +0 -1
  873. package/dist/types/helpers/queue/test/synchronize-task-queue.test.d.ts +0 -1
  874. package/dist/types/helpers/remote-invocation/remote-invocation-registry.test.d.ts +0 -1
  875. package/dist/types/helpers/rte-manager/rte.manager.test.d.ts +0 -1
  876. package/dist/types/helpers/skeleton-loader/tests/vega-skeleton-loader-controller.test.d.ts +0 -1
  877. package/dist/types/helpers/slimmers/element-appender/body-positioned-wrapper/test/vega-popover-wrapper.test.d.ts +0 -1
  878. package/dist/types/helpers/slimmers/element-appender/test/element-appender-slimmer.test.d.ts +0 -1
  879. package/dist/types/helpers/slimmers/mutation-observer/test/aria-attributes-value-mapper.test.d.ts +0 -1
  880. package/dist/types/helpers/slimmers/mutation-observer/test/data-tab-index-value-mapper.test.d.ts +0 -1
  881. package/dist/types/helpers/slimmers/mutation-observer/test/mutation-observer-slimmer.test.d.ts +0 -1
  882. package/dist/types/helpers/slimmers/position-calculation/test/body-position-calculation-strategy.test.d.ts +0 -15
  883. package/dist/types/helpers/slimmers/position-calculation/test/screen-position-calculation-strategy.test.d.ts +0 -1
  884. package/dist/types/helpers/slimmers/runtime-metrics/test/public-api-runtime-metrics-slimmer-base.test.d.ts +0 -1
  885. package/dist/types/helpers/slimmers/sub-state/test/sub-state-observer-slimmer.test.d.ts +0 -1
  886. package/dist/types/helpers/slimmers/test/aria-dialog-focusable-trap-slimmer.test.d.ts +0 -1
  887. package/dist/types/helpers/slimmers/test/auto-run-when-re-render-task-queue-slimmer.test.d.ts +0 -1
  888. package/dist/types/helpers/slimmers/test/brand-switch-state-controller-slimmer.test.d.ts +0 -1
  889. package/dist/types/helpers/slimmers/test/component-global-style-slimmer.test.d.ts +0 -1
  890. package/dist/types/helpers/slimmers/test/component-usage-runtime-metrics.test.d.ts +0 -1
  891. package/dist/types/helpers/slimmers/test/dark-mode-state-controller.test.d.ts +0 -1
  892. package/dist/types/helpers/slimmers/test/deprecated-property-slimmer.test.d.ts +0 -1
  893. package/dist/types/helpers/slimmers/test/field-error-controller-slimmer.test.d.ts +0 -1
  894. package/dist/types/helpers/slimmers/test/form-field-controller-slimmer.test.d.ts +0 -1
  895. package/dist/types/helpers/slimmers/test/form-field-valid-invoke-slimmer.test.d.ts +0 -1
  896. package/dist/types/helpers/slimmers/test/global/vega-nonce-injector-slimmer.test.d.ts +0 -1
  897. package/dist/types/helpers/slimmers/test/global/vega-translate-observer-slimmer.test.d.ts +0 -1
  898. package/dist/types/helpers/slimmers/test/global/vega-watch-method-cancel-slimmer.test.d.ts +0 -1
  899. package/dist/types/helpers/slimmers/test/keyboard-manager-slimmer.test.d.ts +0 -1
  900. package/dist/types/helpers/slimmers/test/page-resize-observer-slimmer.test.d.ts +0 -1
  901. package/dist/types/helpers/slimmers/test/string-input-formatter-slimmer.test.d.ts +0 -1
  902. package/dist/types/helpers/slimmers/test/translation-slimmer.test.d.ts +0 -1
  903. package/dist/types/helpers/theme/tests/theme-manager-controller.test.d.ts +0 -1
  904. package/dist/types/helpers/touch-helper/test/touch-listener.test.d.ts +0 -1
  905. package/dist/types/helpers/translation/tests/internal-translation-controller.test.d.ts +0 -1
  906. package/dist/types/helpers/translation/tests/translation.test.d.ts +0 -1
  907. package/dist/types/helpers/ui/test/element-appender.test.d.ts +0 -1
  908. package/dist/types/helpers/validator/test/rules/check-box-required-rule.test.d.ts +0 -1
  909. package/dist/types/helpers/validator/test/rules/custom-validation-rule.test.d.ts +0 -1
  910. package/dist/types/helpers/validator/test/rules/date-range-rule.test.d.ts +0 -1
  911. package/dist/types/helpers/validator/test/rules/date-required-rule.test.d.ts +0 -1
  912. package/dist/types/helpers/validator/test/rules/email-field-rule.test.d.ts +0 -1
  913. package/dist/types/helpers/validator/test/rules/file-uploader-required-rule.test.d.ts +0 -1
  914. package/dist/types/helpers/validator/test/rules/input-phone-number-required-rule.test.d.ts +0 -1
  915. package/dist/types/helpers/validator/test/rules/input-range-min-and-max-rule.test.d.ts +0 -1
  916. package/dist/types/helpers/validator/test/rules/input-range-required-rule.test.d.ts +0 -1
  917. package/dist/types/helpers/validator/test/rules/input-select-value-in-source-rule.test.d.ts +0 -1
  918. package/dist/types/helpers/validator/test/rules/max-number-rule.test.d.ts +0 -1
  919. package/dist/types/helpers/validator/test/rules/max-string-length-rule.test.d.ts +0 -1
  920. package/dist/types/helpers/validator/test/rules/min-and-max-date-rule.test.d.ts +0 -1
  921. package/dist/types/helpers/validator/test/rules/min-number-rule.test.d.ts +0 -1
  922. package/dist/types/helpers/validator/test/rules/min-string-length-rule.test.d.ts +0 -1
  923. package/dist/types/helpers/validator/test/rules/public-rules.test.d.ts +0 -1
  924. package/dist/types/helpers/validator/test/rules/required-field-rule.test.d.ts +0 -1
  925. package/dist/types/helpers/validator/test/rules/rich-text-editor-required-rule.test.d.ts +0 -1
  926. package/dist/types/helpers/validator/test/rules/time-range-required-rule.test.d.ts +0 -1
  927. package/dist/types/helpers/validator/test/rules/time-range-rule.test.d.ts +0 -1
  928. package/dist/types/helpers/validator/test/rules/time-required-rule.test.d.ts +0 -1
  929. package/dist/types/helpers/validator/test/rules/toggle-switch-required-rule.test.d.ts +0 -1
  930. package/dist/types/helpers/validator/test/rules/valid-credit-card-number-rule.test.d.ts +0 -1
  931. package/dist/types/helpers/validator/test/rules/valid-phone-number-rule.test.d.ts +0 -1
  932. package/dist/types/helpers/validator/test/validation-rule-handler/form-field-validation-rule-handler-chain.test.d.ts +0 -1
  933. package/dist/types/helpers/validator/test/validation-rule-handler/form-field-validation-rule-handler.test.d.ts +0 -1
  934. package/dist/types/helpers/validator/test/validator/form-field-controller.test.d.ts +0 -1
  935. package/dist/types/helpers/vega-telemetry-helper/test/vega-env-manager.test.d.ts +0 -1
  936. package/dist/types/helpers/zindex/test/internal-vega-z-index-manager.test.d.ts +0 -1
  937. package/dist/types/helpers/zindex/test/vega-z-index-manager.test.d.ts +0 -1
  938. package/dist/types/polyfill/d3/test/d3-array-polyfill.test.d.ts +0 -1
  939. package/dist/types/polyfill/d3/test/d3-axis-polyfill.test.d.ts +0 -1
  940. package/dist/types/polyfill/d3/test/d3-integration.test.d.ts +0 -1
  941. package/dist/types/polyfill/d3/test/d3-scale-polyfill.test.d.ts +0 -1
  942. package/dist/types/polyfill/d3/test/d3-selection-polyfill.test.d.ts +0 -1
  943. package/dist/types/polyfill/d3/test/d3-shape-polyfill.test.d.ts +0 -1
  944. package/dist/types/polyfill/d3/test/d3-time-format-polyfill.test.d.ts +0 -1
  945. package/dist/types/polyfill/d3/test/d3-time-polyfill.test.d.ts +0 -1
  946. package/dist/types/polyfill/d3/test/index.test.d.ts +0 -1
  947. package/dist/types/polyfill/libphonenumber/test/as-you-type.test.d.ts +0 -1
  948. package/dist/types/polyfill/libphonenumber/test/format-helpers.test.d.ts +0 -1
  949. package/dist/types/polyfill/libphonenumber/test/index.test.d.ts +0 -1
  950. package/dist/types/polyfill/libphonenumber/test/metadata.test.d.ts +0 -1
  951. package/dist/types/polyfill/libphonenumber/test/parse-phone-number.test.d.ts +0 -1
  952. package/dist/types/polyfill/libphonenumber/test/phone-number.test.d.ts +0 -1
  953. package/dist/types/polyfill/prism/test/css.test.d.ts +0 -1
  954. package/dist/types/polyfill/prism/test/javascript.test.d.ts +0 -1
  955. package/dist/types/polyfill/prism/test/jsx.test.d.ts +0 -1
  956. package/dist/types/polyfill/prism/test/language-registry.test.d.ts +0 -1
  957. package/dist/types/polyfill/prism/test/markup.test.d.ts +0 -1
  958. package/dist/types/polyfill/prism/test/test-utils.d.ts +0 -10
  959. package/dist/types/polyfill/prism/test/tokenizer.test.d.ts +0 -1
  960. package/dist/types/polyfill/prism/test/tsx.test.d.ts +0 -1
  961. package/dist/types/polyfill/prism/test/typescript.test.d.ts +0 -1
  962. package/dist/types/polyfill/shadow-selection/test/shadow-selection-polyfill.test.d.ts +0 -0
  963. package/dist/types/polyfill/test-polyfill/e2e/retry.d.ts +0 -8
  964. package/dist/types/polyfill/test-polyfill/unit/create-touch-event.d.ts +0 -11
  965. package/dist/types/polyfill/test-polyfill/unit/events.d.ts +0 -1
  966. package/dist/types/polyfill/test-polyfill/unit/index.d.ts +0 -3
  967. package/dist/types/polyfill/test-polyfill/unit/methods.d.ts +0 -1
  968. package/dist/types/polyfill/test-polyfill/unit/range.d.ts +0 -7
  969. package/dist/types/polyfill/test-polyfill/unit/shadow-selection.d.ts +0 -0
  970. package/dist/types/polyfill/tinycolor/tinycolor-polyfill.test.d.ts +0 -1
  971. package/dist/types/test-assets/test-icons.d.ts +0 -4
  972. package/dist/types/types/test/type-guard.test.d.ts +0 -1
  973. package/dist/types/utils/e2e-utils.d.ts +0 -160
  974. package/dist/types/utils/sanitize/test/empty-strategy.test.d.ts +0 -1
  975. package/dist/types/utils/sanitize/test/html-sanitizer.test.d.ts +0 -1
  976. package/dist/types/utils/sanitize/test/label-strategy.test.d.ts +0 -1
  977. package/dist/types/utils/sanitize/test/sanitize-strategy.test.d.ts +0 -1
  978. package/dist/types/utils/sanitize/test/sanitize.test.d.ts +0 -1
  979. package/dist/types/utils/sanitize/test/serialize-fragment.test.d.ts +0 -1
  980. package/dist/types/utils/sanitize/test/style-strategy.test.d.ts +0 -1
  981. package/dist/types/utils/spec-utils.d.ts +0 -109
  982. package/dist/types/utils/test/accessibility.test.d.ts +0 -1
  983. package/dist/types/utils/test/api.test.d.ts +0 -1
  984. package/dist/types/utils/test/array.test.d.ts +0 -1
  985. package/dist/types/utils/test/breakpoint.test.d.ts +0 -1
  986. package/dist/types/utils/test/component.test.d.ts +0 -1
  987. package/dist/types/utils/test/date.test.d.ts +0 -1
  988. package/dist/types/utils/test/design-token.test.d.ts +0 -1
  989. package/dist/types/utils/test/effect.test.d.ts +0 -1
  990. package/dist/types/utils/test/local-storage.test.d.ts +0 -1
  991. package/dist/types/utils/test/log.test.d.ts +0 -1
  992. package/dist/types/utils/test/misc.test.d.ts +0 -1
  993. package/dist/types/utils/test/number.test.d.ts +0 -1
  994. package/dist/types/utils/test/object.test.d.ts +0 -1
  995. package/dist/types/utils/test/pagination.test.d.ts +0 -1
  996. package/dist/types/utils/test/pixel.test.d.ts +0 -1
  997. package/dist/types/utils/test/safe-document.test.d.ts +0 -1
  998. package/dist/types/utils/test/spec-utils.test.d.ts +0 -1
  999. package/dist/types/utils/test/string.test.d.ts +0 -1
  1000. package/dist/types/utils/test/test-utils.test.d.ts +0 -1
  1001. package/dist/types/utils/test/timer.test.d.ts +0 -1
  1002. package/dist/types/utils/test/ui.test.d.ts +0 -1
  1003. package/dist/types/utils/test-utils.d.ts +0 -61
  1004. package/dist/vega/p-0ac91609.entry.js +0 -1
  1005. package/dist/vega/p-10e9438e.js +0 -1
  1006. package/dist/vega/p-2697b52b.js +0 -1
  1007. package/dist/vega/p-2fd266fa.js +0 -1
  1008. package/dist/vega/p-31945d6c.js +0 -1
  1009. package/dist/vega/p-33475bcf.entry.js +0 -1
  1010. package/dist/vega/p-3a0b3fed.entry.js +0 -1
  1011. package/dist/vega/p-4a9be903.js +0 -1
  1012. package/dist/vega/p-541ae774.entry.js +0 -1
  1013. package/dist/vega/p-603b851c.js +0 -1
  1014. package/dist/vega/p-6d6ea8b4.js +0 -1
  1015. package/dist/vega/p-6db0556d.js +0 -1
  1016. package/dist/vega/p-79df30e3.entry.js +0 -1
  1017. package/dist/vega/p-8f88fb57.js +0 -1
  1018. package/dist/vega/p-a01ef160.entry.js +0 -1
  1019. package/dist/vega/p-c962cf5b.js +0 -1
  1020. package/dist/vega/p-d94d785a.entry.js +0 -1
  1021. package/dist/vega/p-dce9349e.js +0 -1
  1022. package/dist/vega/p-e2268eef.js +0 -1
  1023. package/dist/vega/p-e5da9f66.js +0 -1
  1024. package/dist/vega/p-f7505267.js +0 -1
  1025. package/dist/vega/p-fef22245.js +0 -1
@@ -1 +1 @@
1
- import{g as t}from"./p-8b5d3a52.js";import{a as e,g as n,D as s,f as o,r as i}from"./p-d6875e49.js";import{L as r,I as a}from"./p-6e1ab235.js";import{I as l,c}from"./p-593e0f80.js";import{I as h}from"./p-781fd6e0.js";import{c as d}from"./p-6a334573.js";import{P as u}from"./p-81dd00d0.js";import{i as p}from"./p-3d2d267d.js";import{V as f}from"./p-82016096.js";import{R as g,E as b,h as w,U as y,V as m,B as v,a as C,I as x,b as T,c as E,P as S,A as k,d as A}from"./p-6db0556d.js";import{s as R,A as O,a as I,R as L,M as B,b as j,c as N,d as _,e as M,f as D,I as V,g as P,h as H,i as F,j as K,k as $,B as z,l as W,m as G,C as U,n as Z}from"./p-2697b52b.js";import{i as J}from"./p-6d6ea8b4.js";import{R as X}from"./p-fcabf0dc.js";import{V as q}from"./p-a7b5f497.js";import{V as Q}from"./p-e1fbfd20.js";import{v as Y}from"./p-4866e390.js";import{D as tt,d as et}from"./p-4068e7de.js";import{V as nt,a as st,b as ot,c as it}from"./p-c5eb0fa6.js";import{R as rt,a as at,S as lt,T as ct,b as ht,C as dt,M as ut,c as pt,d as ft,e as gt,f as bt,g as wt,h as yt,i as mt,j as vt,k as Ct,l as xt,m as Tt,n as Et,o as St,p as kt,q as At,s as Rt,r as Ot,t as It,I as Lt,u as Bt,v as jt,w as Nt,x as _t,y as Mt,z as Dt,A as Vt,B as Pt,D as Ht,E as Ft,F as Kt,G as $t,H as zt,J as Wt,K as Gt,L as Ut,N as Zt,O as Jt,P as Xt,Q as qt,U as Qt,W as Yt,X as te,Y as ee}from"./p-7f68abf7.js";import{r as ne}from"./p-77e64f26.js";import{V as se,a as oe,b as ie}from"./p-6554a801.js";import{V as re}from"./p-8ac2d165.js";import{t as ae}from"./p-b75ee3ba.js";import{p as le}from"./p-0c667d6a.js";import{c as ce}from"./p-a841cf13.js";import{C as he}from"./p-2d0d575f.js";import{d as de}from"./p-1bc5b3bc.js";const ue=[{payloadKey:"IS_LOAD_METHOD_CALLED",payloadDescription:"Indicate if the method load of public API VegaLoaderController is called",canAccept:(t,e)=>"VegaLoaderController"===t&&"load"===e,payloadValue:()=>!0},{payloadKey:"IS_CLOSE_METHOD_CALLED",payloadDescription:"Indicate if the method close of public API VegaLoaderController is called",canAccept:(t,e)=>"VegaLoaderController"===t&&"close"===e,payloadValue:()=>!0}];class pe{constructor(){this.vegaPublicAPIRuntimeMetricsSlimmer=c(pe,["load","close"],ue)}load(t={}){let e=t.containerSelector||"body",n=document.querySelector(e);if(n&&pe.SPECIAL_ELEMENT_TO_WRAP_FULL_BODY.includes(n.tagName)&&(e="body",n=document.querySelector("body")),!n)return r.error("Container is not found by selector: ",e),null;const s=this.createLoadingIndicator(t.indicatorOptions),o=this.createLoader(e);return o.append(s),this.appendLoader(o,n)}close(t){const e=this.findLoader(t);if(e){if(e.dataset.container){const t=document.querySelector(e.dataset.container);t&&t.dataset.vegaLoaderOriginPosition&&(t.style.position=t.dataset.vegaLoaderOriginPosition)}e.remove()}}findLoader(t){var e,n;let s;if(t.includes(">>>")){const[o,i]=t.split(">>>");s=null===(n=null===(e=document.querySelector(o))||void 0===e?void 0:e.shadowRoot)||void 0===n?void 0:n.getElementById(i)}else s=document.getElementById(t);return s}createLoader(n){const s=document.createElement("vega-loader-wrapper");return s.className=e(["body"===n?"fixed-wrapper":"absolute-wrapper"]),s.dataset.container=n,s.id=`vega-loader-${t()}`,s}createLoadingIndicator(t={}){const e=document.createElement("vega-loading-indicator");return Object.assign(e,t),e}appendLoader(t,e){return e.dataset.vegaLoaderOriginPosition=e.style.position,e.style.position="relative",e.shadowRoot?(e.shadowRoot.append(t),`${t.dataset.container}>>>${t.id}`):(e.append(t),t.id)}}pe.SPECIAL_ELEMENT_TO_WRAP_FULL_BODY=["VEGA-MODAL"],function(t,e,n,s){var o,i=arguments.length,r=i<3?e:null===s?s=Object.getOwnPropertyDescriptor(e,n):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)r=Reflect.decorate(t,e,n,s);else for(var a=t.length-1;a>=0;a--)(o=t[a])&&(r=(i<3?o(r):i>3?o(e,n,r):o(e,n))||r);i>3&&r&&Object.defineProperty(e,n,r)}([l()],pe.prototype,"vegaPublicAPIRuntimeMetricsSlimmer",void 0);const fe=new pe,ge=[{payloadKey:"IS_OPEN_METHOD_CALLED",payloadDescription:"Indicate if the method open of public API VegaNotifyController is called",canAccept:(t,e)=>"VegaNotifyController"===t&&"open"===e,payloadValue:()=>!0},{payloadKey:"IS_CLOSE_METHOD_CALLED",payloadDescription:"Indicate if the method close of public API VegaNotifyController is called",canAccept:(t,e)=>"VegaNotifyController"===t&&"close"===e,payloadValue:()=>!0},{payloadKey:"IS_CLOSEALL_METHOD_CALLED",payloadDescription:"Indicate if the method closeAll of public API VegaNotifyController is called",canAccept:(t,e)=>"VegaNotifyController"===t&&"closeAll"===e,payloadValue:()=>!0}];var be=function(t,e,n,s){var o,i=arguments.length,r=i<3?e:null===s?s=Object.getOwnPropertyDescriptor(e,n):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)r=Reflect.decorate(t,e,n,s);else for(var a=t.length-1;a>=0;a--)(o=t[a])&&(r=(i<3?o(r):i>3?o(e,n,r):o(e,n))||r);return i>3&&r&&Object.defineProperty(e,n,r),r};class we{constructor(){this.resizeObserverSlimmer=d(we,u,[],[{mapFrom:"connectResizeObserver",mapTo:"connectResizeObserver"}],[{callback:t=>{var e;!(t[0].contentRect.height>0)&&(null===(e=this.container)||void 0===e?void 0:e.classList.contains("hydrated"))&&(h.removeZIndex(this.container,"top"),this.container.remove(),this.container=null)},target:()=>this.container}]),this.vegaPublicAPIRuntimeMetricsSlimmer=c(we,["open","close","closeAll"],ge)}async open(t){const e=this.createPageNotification(t);return this.getContainer().append(e),e.id}async closeAll(){this.container&&Array.from(this.container.children).forEach((t=>{t.close()}))}async close(t){await document.getElementById(t).close()}connectResizeObserver(){}createPageNotification(e){const o=document.createElement("vega-page-notification");return Object.keys(e).forEach((t=>{void 0!==e[t]&&(o[t]=e[t])})),o.style.marginBottom=n()===s.MOBILE?"12px":"16px",o.id=`vega-page-notification-${t()}`,o}getContainer(){return this.container||(this.container=document.createElement("vega-page-notification-list"),h.setZIndex(this.container,"top"),n()===s.MOBILE?this.container.classList.add("vega-page-notification-list-bottom"):this.container.classList.add("vega-page-notification-list-topRight"),document.body.append(this.container),this.connectResizeObserver()),this.container}}be([a()],we.prototype,"resizeObserverSlimmer",void 0),be([l()],we.prototype,"vegaPublicAPIRuntimeMetricsSlimmer",void 0);const ye=new we,me=[{payloadKey:"IS_SETSEMANTICS_METHOD_CALLED",payloadDescription:"Indicate if the method setSemantics of public API VegaEventManager is called",canAccept:(t,e)=>"VegaEventManager"===t&&"setSemantics"===e,payloadValue:()=>!0},{payloadKey:"IS_GETSEMANTICS_METHOD_CALLED",payloadDescription:"Indicate if the method getSemantics of public API VegaEventManager is called",canAccept:(t,e)=>"VegaEventManager"===t&&"getSemantics"===e,payloadValue:()=>!0},{payloadKey:"IS_GETENABLEDEVENTIDSBYCOMPONENT_METHOD_CALLED",payloadDescription:"Indicate if the method getEnabledEventIdsByComponent of public API VegaEventManager is called",canAccept:(t,e)=>"VegaEventManager"===t&&"getEnabledEventIdsByComponent"===e,payloadValue:()=>!0},{payloadKey:"globalEventIsNative",payloadDescription:"Indicate if the vega components will emit events without the vega prefix",canAccept:(t,e)=>"VegaEventManager"===t&&"setSemantics"===e,payloadValue:t=>!(!t.global||"native"!==t.global.namespace)},{payloadKey:"eventOfSpecificComponentsIsNative",payloadDescription:"Indicate if the vega components will emit events with the vega prefix, but special components will emit events without vega prefix",canAccept:(t,e)=>"VegaEventManager"===t&&"setSemantics"===e,payloadValue:t=>{const e=t;if(e.components){const t=Object.keys(e.components);return!!(t.length>0&&"native"===e.components[t[0]].namespace)}return!1}},{payloadKey:"eventOfSpecificComponentsIsVega",payloadDescription:"Indicate if the vega components will emit events without the vega prefix, but special components will emit events with vega prefix",canAccept:(t,e)=>"VegaEventManager"===t&&"setSemantics"===e,payloadValue:t=>{const e=t;if(e.global&&e.components){const t=Object.keys(e.components);return!!("native"===e.global.namespace&&t.length>0&&"vega"===e.components[t[0]].namespace)}return!1}},{payloadKey:"globalJqueryDelegatedEventIsTrue",payloadDescription:"Indicate if the use jQuery with event delegation",canAccept:(t,e)=>"VegaEventManager"===t&&"setSemantics"===e,payloadValue:t=>!(!t.global||!0!==t.global.jqueryDelegatedEvent)},{payloadKey:"jqueryDelegatedEventIsCustomStrategy",payloadDescription:"Indicate if the use jQuery with event delegation",canAccept:(t,e)=>"VegaEventManager"===t&&"setSemantics"===e,payloadValue:t=>{const e=t;return!!(e.global&&Array.isArray(e.global.jqueryDelegatedEvent)&&e.global.jqueryDelegatedEvent.length>0)}},{payloadKey:"jqueryDelegatedEventOfSpecialComponentsIsTrue",payloadDescription:"Indicate if the use jQuery with event delegation",canAccept:(t,e)=>"VegaEventManager"===t&&"setSemantics"===e,payloadValue:t=>{const e=t;if(e.components){const t=Object.keys(e.components);return!!(t.length>0&&!0===e.components[t[0]].jqueryDelegatedEvent)}return!1}}];class ve{constructor(){this.vegaPublicAPIRuntimeMetricsSlimmer=c(ve,["setSemantics","getSemantics","getEnabledEventIdsByComponent"],me)}setSemantics(t){p.setSemantics(t)}getSemantics(t){return p.getSemantics(t)}getEnabledEventIdsByComponent(t){return p.getEnabledEventIdsByComponent(t)}}!function(t,e,n,s){var o,i=arguments.length,r=i<3?e:null===s?s=Object.getOwnPropertyDescriptor(e,n):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)r=Reflect.decorate(t,e,n,s);else for(var a=t.length-1;a>=0;a--)(o=t[a])&&(r=(i<3?o(r):i>3?o(e,n,r):o(e,n))||r);i>3&&r&&Object.defineProperty(e,n,r)}([l()],ve.prototype,"vegaPublicAPIRuntimeMetricsSlimmer",void 0);const Ce=new ve,xe=[{payloadKey:"IS_OVERRIDEZINDEXBASICVALUES_METHOD_CALLED",payloadDescription:"Indicate if the method overrideZIndexBasicValues of public API ZIndexManager is called",canAccept:(t,e)=>"VegaZIndexManager"===t&&"overrideZIndexBasicValues"===e,payloadValue:()=>!0},{payloadKey:"zIndexBasicValuesGreatThanTenThousand",payloadDescription:"Indicate if the basic z-index value is great than ten thousand",canAccept:(t,e)=>"VegaZIndexManager"===t&&"overrideZIndexBasicValues"===e,payloadValue:t=>t.base>1e4}];class Te{constructor(){this.vegaPublicAPIRuntimeMetricsSlimmer=c(Te,["overrideZIndexBasicValues"],xe)}overrideZIndexBasicValues(t){h.overrideZIndexBasicValues(t)}}!function(t,e,n,s){var o,i=arguments.length,r=i<3?e:null===s?s=Object.getOwnPropertyDescriptor(e,n):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)r=Reflect.decorate(t,e,n,s);else for(var a=t.length-1;a>=0;a--)(o=t[a])&&(r=(i<3?o(r):i>3?o(e,n,r):o(e,n))||r);i>3&&r&&Object.defineProperty(e,n,r)}([l()],Te.prototype,"vegaPublicAPIRuntimeMetricsSlimmer",void 0);const Ee=new Te,Se=[{payloadKey:"IS_WAITFORVEGA_METHOD_CALLED",payloadDescription:"Indicate if the method waitForVega of public API WaitForVegaHandler is called",canAccept:(t,e)=>"WaitForVegaHandler"===t&&"handle"===e,payloadValue:()=>!0}];class ke{constructor(){this.vegaPublicAPIRuntimeMetricsSlimmer=c(ke,["handle"],Se)}async handle(){return await Promise.all(Array.from(document.querySelectorAll("*:not(.hydrated)")).filter((t=>t.tagName.startsWith("VEGA"))).map((t=>{var e;return null===(e=t.componentOnReady)||void 0===e?void 0:e.call(t)})))}}!function(t,e,n,s){var o,i=arguments.length,r=i<3?e:null===s?s=Object.getOwnPropertyDescriptor(e,n):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)r=Reflect.decorate(t,e,n,s);else for(var a=t.length-1;a>=0;a--)(o=t[a])&&(r=(i<3?o(r):i>3?o(e,n,r):o(e,n))||r);i>3&&r&&Object.defineProperty(e,n,r)}([l()],ke.prototype,"vegaPublicAPIRuntimeMetricsSlimmer",void 0);const Ae=new ke,Re=async()=>Ae.handle(),Oe=[{payloadKey:"IS_LOAD_METHOD_CALLED",payloadDescription:"Indicate if the method load of public API VegaSkeletonLoaderController is called",canAccept:(t,e)=>"VegaSkeletonLoaderController"===t&&"load"===e,payloadValue:()=>!0},{payloadKey:"IS_UNLOAD_METHOD_CALLED",payloadDescription:"Indicate if the method unLoad of public API VegaSkeletonLoaderController is called",canAccept:(t,e)=>"VegaSkeletonLoaderController"===t&&"unLoad"===e,payloadValue:()=>!0},{payloadKey:"IS_UNLOADALL_METHOD_CALLED",payloadDescription:"Indicate if the method unLoadAll of public API VegaSkeletonLoaderController is called",canAccept:(t,e)=>"VegaSkeletonLoaderController"===t&&"unLoadAll"===e,payloadValue:()=>!0}];class Ie{constructor(){this.vegaPublicAPIRuntimeMetricsSlimmer=c(Ie,["load","unLoad","unLoadAll"],Oe),this.loaderMap=new Map}load({target:e,type:n="text",width:s,height:o,items:i,layout:r}){const a=Array.from(document.body.querySelectorAll(e)),l=`vega-skeleton-loader-${t()}`,c=[];return a.forEach((t=>{const e=i?i.map(this.createSkeleton):[this.createSkeleton({type:n,width:s,height:o})],a=(r?[this.wrapLayout(e,r)]:e).map((t=>(t.dataset[Ie.LOADER_DATA_SET_KEY]=l,t)));c.push(...a),t.append(...a)})),this.loaderMap.set(l,c),l}unLoad(t){this.loaderMap.has(t)&&(this.loaderMap.get(t).forEach((t=>t.remove())),this.loaderMap.delete(t))}unLoadAll(){for(const t of this.loaderMap.values())t.forEach((t=>t.remove()));this.loaderMap.clear()}createSkeleton(t){const{type:e,width:n,height:s}=t,o=document.createElement("vega-skeleton");return Object.assign(o,{animated:!0,type:e,width:n,height:s}),o}wrapLayout(t,e){const n=document.createElement("vega-flex");return Object.assign(n,Object.assign({className:"vega-skeleton-loader-template-container"},e.props)),Object.assign(n.style,e.style),n.append(...t),n}}Ie.LOADER_DATA_SET_KEY="vegaSkeletonLoaderKey",function(t,e,n,s){var o,i=arguments.length,r=i<3?e:null===s?s=Object.getOwnPropertyDescriptor(e,n):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)r=Reflect.decorate(t,e,n,s);else for(var a=t.length-1;a>=0;a--)(o=t[a])&&(r=(i<3?o(r):i>3?o(e,n,r):o(e,n))||r);i>3&&r&&Object.defineProperty(e,n,r)}([l()],Ie.prototype,"vegaPublicAPIRuntimeMetricsSlimmer",void 0);const Le=new Ie,Be=[{payloadKey:"IS_INIT_METHOD_CALLED",payloadDescription:"Indicate if the method load of public API VegaTranslation.init is called",canAccept:(t,e)=>"TranslationController"===t&&"init"===e,payloadValue:()=>!0},{payloadKey:"IS_CHANGE_LANGUAGE_METHOD_CALLED",payloadDescription:"Indicate if the method load of public API VegaTranslation.changeLanguage is called",canAccept:(t,e)=>"TranslationController"===t&&"changeLanguage"===e,payloadValue:()=>!0}];class je{constructor(){this.vegaPublicAPIRuntimeMetricsSlimmer=c(je,["init","changeLanguage"],Be)}get currentLanguage(){return f.currentLanguage}init(t){f.init(t)}changeLanguage(t){f.changeLanguage(t)}}!function(t,e,n,s){var o,i=arguments.length,r=i<3?e:null===s?s=Object.getOwnPropertyDescriptor(e,n):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)r=Reflect.decorate(t,e,n,s);else for(var a=t.length-1;a>=0;a--)(o=t[a])&&(r=(i<3?o(r):i>3?o(e,n,r):o(e,n))||r);i>3&&r&&Object.defineProperty(e,n,r)}([l()],je.prototype,"vegaPublicAPIRuntimeMetricsSlimmer",void 0);const Ne=new je,_e=new class{constructor(){this.extensionContextMap=new WeakMap}setExtensionContext(t){t&&t.host&&this.extensionContextMap.set(t.host,t)}getExtensionContext(t){return t?this.extensionContextMap.get(t):null}};class Me extends q{injectRTEScopeStyles(){return""}render(t,e,n){var s;const o=this.doRender(n,t,e);return this.fallbackRegisterRef(o,t),this.appendChildren((null===(s=o.childrenContainerGetter)||void 0===s?void 0:s.call(o))||o,t,e,n),o}useRef(t){return t[Me.REGISTER_REF_FLAG]=!0,function(e){e&&R.register(e,t)}}getDTORenderer(t){return X.getRTERenderer(t)}getExtensionContext(t){return _e.getExtensionContext(t)}appendChildren(t,e,n,s){Array.isArray(e.children)&&e.children.length&&!t.t&&(t.t=e.children.map((t=>this.renderChildren(t,n,s))).filter(J))}renderChildren(t,e,n){const s=this.getDTORenderer(t.type);if(s)return s.render(t,e,n)}fallbackRegisterRef(t,e){e[Me.REGISTER_REF_FLAG]||!t.o||t.o.ref||(t.o.ref=this.useRef(e))}}Me.REGISTER_REF_FLAG="__registeredRef__";class De{constructor(){this.extensionContext=null,this.hasCustomStylesRenderers=new Set}static registerActionHandleStrategy(t,e,n){O.register(e,t,n)}static registerActionHandlerInterceptor(t,e,n){I.register(e,t,n)}initialExtension(t){this.extensionContext=t,_e.setExtensionContext(t)}destroyExtension(){}collectExtensionRendererStyles(){let t="";return this.hasCustomStylesRenderers.size>0&&this.hasCustomStylesRenderers.forEach((e=>{t+=`${e.injectRTEScopeStyles()}\n`})),t}registerNode(t,e){L.registerRTEDTOClass(t,e)}registerRenderer(t,e){X.registerRTEDTORenderer(t,e),e instanceof Me&&e.injectRTEScopeStyles()&&this.hasCustomStylesRenderers.add(e)}registerToolbarButtonRenderer(t,e){X.registerRTEToolbarButtonRenderer(t,e)}registerBlockBasicStrategies(t){g.registerBlockBasicStrategies(t)}unRegisterStrategy(t,e){O.unregister(t,e)}unRegisterInterceptor(t,e,n){I.unregister(t,e,n)}registerElementToBlockDTOClassStrategy(t){b.registerElementToBlockStrategy(t)}registerElementToNodeDTOClassStrategy(t){b.registerElementToNodeStrategy(t)}getElementToNodeDTOClassStrategies(){return b.getElementToNodeStrategies()}registerAnnotationHandler(t){w.registerHandler(t)}}class Ve{isHidden(t){return t.sourceEditMode}getExtensionContext(t){return _e.getExtensionContext(t)}renderDropdown(t,e,n,s){return t("vega-dropdown",Object.assign({trigger:"click",searchable:!1,maxWidth:"200",itemDisplayRule:"ellipsis",ref:t=>{tt.addUniqueObserverToNode(t,nt,(t=>{this.handleDropdownClick(t.detail,e)}))}},n),s)}renderDropdownListTemplate(t,e){return t("div",{slot:"items",onMouseDown:this.preventDefault,class:"rte-dropdown-list"},[t("style",{nonce:Y.nonce},".rte-dropdown-list vega-dropdown-group vega-dropdown-group { padding-left: 4px }"),...e.map((e=>"children"in e?this.renderDropdownGroup(t,e):this.renderDropdownItem(t,e)))])}renderDropdownItem(t,e){return t("vega-dropdown-item",{key:e.key,itemKey:e.key,label:e.label,prefixIcon:e.icon})}renderDropdownGroup(t,e){return t("vega-dropdown-group",{key:e.key,label:e.label,divide:!1},e.children.map((e=>"children"in e?this.renderDropdownGroup(t,e):this.renderDropdownItem(t,e))))}renderButton(t,e,n){const{icon:s,label:o,showArrowIcon:i}=n,r=this.isDisabled(e);return t("vega-rich-text-editor-toolbar-button",{disabled:r,icon:s,hidden:this.isHidden(e),selected:this.isSelected(e),ref:t=>{tt.addUniqueObserverToNode(t,st,(()=>this.handleButtonClick(e)))},onMouseDown:this.preventDefault},[this.renderButtonLabel(t,e,o),i?t("vega-icon",{size:"size-8",color:r?"text-disabled":"text-secondary",style:{marginLeft:"8px"},icon:Q.getIconKey("chevron-down")}):null].filter(J))}renderButtonLabel(t,e,n){return n?t("vega-font",{variant:"font-field-label-sm",color:this.isDisabled(e)?"text-disabled":"text-primary"},n):null}isDisabled(t){return t.host.disabled}isSelected(t){return!1}preventDefault(t){t.preventDefault()}getListItemByKey(t,e){for(const n of t)if("children"in n){const t=this.getListItemByKey(n.children,e);if(t)return t}else if(n.key===e)return n;return null}}class Pe extends B{constructor(t,e){super(),this.type="INSERT_TOKEN_NODE",this.rteRange=null,this.actionHandleResult=!1,this.rteRange=t,this.token=e}}class He extends Ve{constructor(t){super(),this.tokenList=[],this.tokenList=t}render(t,e){return this.renderDropdown(t,e,{},[this.renderButton(t,e,{label:"Tokens",showArrowIcon:!0}),this.renderDropdownListTemplate(t,this.tokenList)])}isDisabled(t){const e=this.getExtensionContext(t.host);if(e){const{host:t,getSelectedNodes:n}=e,[s]=n();return s?t.disabled||!O.canHandle("INSERT_TOKEN_NODE",s.parent):t.disabled}return!1}handleButtonClick(t){}handleDropdownClick(t,e){const n=this.getListItemByKey(this.tokenList,t),{rteRange:s}=e,{startNode:o}=s;if(o&&o.parent){const t=new Pe(s,n);o.parent.apply(t),t.actionHandleResult&&this.flushEditorUI(e)}}flushEditorUI(t){const e=this.getExtensionContext(t.host);if(e){const{host:t,flushValue:n}=e;n(t.value)}}}class RTETokenNode extends j{constructor(t,e,n,s,o){super(t,n,s,o),this.type="token",this.token=e,this.text=n}static from(t,e){const n=new RTETokenNode(t.id,t.token,t.text,e);return t.annotations&&(n.annotationMap=this.generateTextAnnotationMap(t.annotations)),n}toJSON(){const t=super.toJSON();return Object.assign({id:this.id,type:this.type,text:this.text,token:this.token},t.annotations?{annotations:t.annotations}:{})}isContentEditable(){return!1}clone(t){return new RTETokenNode(this.id,this.token,this.text,t,this.annotationMap)}toHtml(){return`<span class="token" contenteditable="false" template-token-key="${this.token}" token-key="${this.token}"${super.generateAttributeString()}>${this.text}</span>`}}class Fe extends Me{doRender(t,e,n){const{id:s,token:o}=e;return t("span",Object.assign(Object.assign({key:s,"template-token-key":o,"token-key":o,contenteditable:"false",style:e.getStyles(),class:`token ${e.getClasses()}`},this.additionalAttributes(e)),{ref:this.useRef(e),onClick:t=>{t.preventDefault(),n&&!1!==n.editable&&this.handleTokenElementClick(t,e,n.host)}}),e.text)}injectRTEScopeStyles(){return"span[token-key]{padding: 0 2px; margin: 0 1px; background-color: rgba(var(--v-bg-status-info, 205,209,211))}"}handleTokenElementClick(t,e,n){t.preventDefault(),n&&n.value.apply(new y(e,void 0,!0))}additionalAttributes(t){const e=t.getCustomAttributesAnnotation();let n={wrapped:"true"};return e&&(n=Object.assign(Object.assign({},n),e.render())),n}}class Ke extends Ve{constructor(t,e,n){super(),this.languageList=[],this.selectedLanguage="Select Language",this.labelRef=null,this.handleDropdownClick=t=>{this.setSelectedLanguage(t),"function"==typeof this.languageChangeCallback&&this.languageChangeCallback(this.selectedLanguage)},this.languageList=t,this.selectedLanguage=n,this.languageChangeCallback=e}setSelectedLanguage(t){this.selectedLanguage=t,this.labelRef&&(this.labelRef.textContent=this.getLanguageLabelByKey(t))}isHidden(){return!1}render(t,e){return this.renderDropdown(t,e,{source:this.languageList},[this.renderButton(t,e,{label:this.getLanguageLabelByKey(this.selectedLanguage),showArrowIcon:!0})])}renderButtonLabel(t,e,n){return t("vega-font",{variant:"font-field-label-sm",color:this.isDisabled(e)?"text-disabled":"text-primary",ref:t=>this.labelRef=t},n)}handleButtonClick(t){}getLanguageLabelByKey(t){return this.getListItemByKey(this.languageList,t).label}}class $e extends De{constructor(t,e){super(),this.languageState={selectedLanguage:"",contentMap:{}},this.languageChangeCallBack=t=>{const e=this.languageState.selectedLanguage;this.extensionContext&&e&&(this.languageState.contentMap[e]=this.getRTELatestValue(this.extensionContext.host)),this.languageState.selectedLanguage=t,this.applyLanguageContent(t,this.languageState.contentMap)},e&&(this.languageState=Object.assign(Object.assign({},this.languageState),e)),!this.languageState.selectedLanguage&&t.length>0&&(this.languageState.selectedLanguage=t[0].key),this.languageToolbarButtonRenderer=new Ke(t,this.languageChangeCallBack,this.languageState.selectedLanguage),this.registerToolbarButtonRenderer("languages",this.languageToolbarButtonRenderer)}initialExtension(t){super.initialExtension(t);const{selectedLanguage:e,contentMap:n}=this.languageState;n&&n[e]&&this.applyLanguageContent(this.languageState.selectedLanguage,this.languageState.contentMap)}setState(t){const{selectedLanguage:e,contentMap:n}=t;this.languageToolbarButtonRenderer.setSelectedLanguage(e),this.languageState.selectedLanguage=e,this.languageState.contentMap=Object.assign({},n),this.applyLanguageContent(e,n)}getState(){const{selectedLanguage:t,contentMap:e}=this.languageState;return this.extensionContext&&(e[t]=this.getRTELatestValue(this.extensionContext.host)),this.languageState}applyLanguageContent(t,e){if(this.extensionContext&&e){let n=e[t];const{host:s,flushValue:o}=this.extensionContext;n=n?n instanceof m?n:m.fromJSON(n,s.sourceEditConfig):m.createEmptyContent(),s.value!==n&&o(n,!0)}}getRTELatestValue(t){let e=t.value;if(this.extensionContext&&this.extensionContext.isSourceEditMode()&&t.shadowRoot){const n=t.shadowRoot.querySelector(".source-view-container vega-code-block");n&&(e=m.fromHtml(n.value.code,{autoMatchFormat:t.sourceEditConfig.autoMatchFormat}))}return e}}class ze extends B{constructor(t){super(),this.type="INSERT_FUNCTION_BLOCK",this.functionType=t}}class RTEFunctionBlock extends N{constructor(t){super(t),this.type="function-block",this.children=[]}static from(t,e){const n=new RTEFunctionBlock(t.id),s={customClass:["statement"]};let{annotations:o}=t;return o=o?Object.assign(Object.assign({},o),s):s,super.convertAnnotationsToMap(n.annotationMap,o),n.children=this.generateBlockChildren(t.children,e,n),n}toHtml(){return`<div class="statement">${this.children.map((t=>t instanceof _?`<div class="statementelement"${this.getFunctionContentStyle(t)}>${t.getChildrenHtml()}</div>`:t.toHtml())).join("")}</div>`}clone(e){const n=new RTEFunctionBlock(t());return n.parent=e,n.children=this.children.map((t=>t.clone(n))),n.annotationMap=super.cloneAnnotations(),n}getLastNode(){return this.children[this.children.length-1].getLastNode()}isNotEmpty(){return this.children.length>0}toJSON(){return Object.assign(Object.assign({},super.toJSON()),{id:this.id,type:this.type,children:this.children.map((t=>t.toJSON()))})}getFunctionContentStyle(t){const e=new M(t);let n=e.toCssText({standalone:!0});const s=t.getAnnotationByType("TEXT_STYLE");if(s&&"paragraph"===s.textStyle){const t=e.toCssText(void 0,void 0,s.renderStyle({standalone:!0}));n=n.replace(t,"").trim()}return n?` style="${n}"`:""}}class We extends D{handleAction(t,e){const{functionType:n}=t,s=this.getFunctionBlock(n),o=this.createNewParagraph(""),i=this.getReferenceBlock(e);i?i.parent.apply(new V(i,s,o)):e.apply(new P([s,o])),o&&(t.nextFocusNode=o.children[0])}getFunctionBlock(e){const n=t();return RTEFunctionBlock.from({id:n,type:"function-block",children:[{id:`${n}-1`,type:"logic-control-block",statementText:e.toUpperCase()},{id:`${n}-2`,annotations:{customClass:["statementelement"]},type:"paragraph",nodes:[{id:`${n}-2-1`,type:"text",text:" "}]},{id:`${n}-3`,type:"logic-control-block",statementText:"SHOW"},{id:`${n}-4`,annotations:{customClass:["statementelement"]},type:"paragraph",nodes:[{id:`${n}-4-1`,type:"text",text:" "}]}]})}getReferenceBlock(t){if(!(t instanceof m)){const e=t.parent;return e instanceof RTEFunctionBlock?e:t}}}class RTELogicControlNode extends H{constructor(t,e,n){super(t),this.type="logic-control-node",this.text="",this.text=e,this.parent=n}clone(){return new RTELogicControlNode(this.id,this.text,this.parent)}toHtml(){return this.text}toJSON(){return{id:this.id,type:this.type,text:this.text}}getRangeEndOffset(){return 1}getRangeContainer(){const t=R.getDOMByEntity(this);if(t)return t.parentElement}isContentEditable(){return!1}}class RTELogicControlBlock extends N{constructor(t,e,n){super(t),this.type="logic-control-block",this.children=[],this.statementText="",this.statementText=e,this.children=[new RTELogicControlNode(`${t}-node-1`,e,this)],n&&(this.parent=n)}static from(t){return new RTELogicControlBlock(t.id,t.statementText)}isNotEmpty(){return!0}getLastNode(){return this.children[this.children.length-1]}toHtml(){return`<div class='statementsyntax' contenteditable='false'>${this.statementText}</div>`}clone(t){return new RTELogicControlBlock(this.id,this.statementText,t)}toJSON(){return{id:this.id,type:this.type,statementText:this.statementText}}}class Ge extends Ve{render(t,e){return this.renderDropdown(t,e,{},[this.renderButton(t,e,{label:"Functions",showArrowIcon:!0}),this.renderDropdownListTemplate(t,Ge.FUNCTION_LIST)])}isDisabled(t){const e=this.getExtensionContext(t.host);if(e){const{host:t,getSelectedNodes:n}=e,s=n()[0];let o=!0;return s&&(o=O.canHandle("INSERT_FUNCTION_BLOCK",s.parent)),t.disabled||!o}return!1}handleButtonClick(){throw new Error("Method not implemented.")}handleDropdownClick(t,e){if(e){const n=this.getExtensionContext(e.host);if(n){const{host:e,getSelectedNodes:s}=n,o=s()[0],i=new ze(t);o?o.parent&&o.parent.apply(i):e.value.apply(i),i.nextFocusNode&&e.value.apply(new y(i.nextFocusNode,1))}}}}Ge.FUNCTION_LIST=[{key:"IF",label:"Conditional"},{key:"FOREACH",label:"Foreach"}];class Ue extends Me{doRender(t,e){return t("div",{key:e.id,class:"statementsyntax",ref:this.useRef(e)},t("span",{key:`${e.id}-1`,contenteditable:"false",ref:this.useRef(e.children[0])},e.statementText))}}class Ze extends v{constructor(){super(...arguments),this.blockClassName="statementsyntax"}canHandle(t,e){const n=t[e];return n&&n.nodeType===Node.ELEMENT_NODE&&n.classList.contains(this.blockClassName)&&this.isFunctionBlockChild(n)?1:0}handle(e){const n=e[0];return RTELogicControlBlock.from({id:t(),type:"logic-control-block",statementText:n.innerText})}appendChildBlocks(){}shouldProceedToElementChildren(){return!1}isFunctionBlockChild(t){return!(!t.parentElement||!t.parentElement.classList.contains("statement"))}}class Je extends Me{doRender(t,e){return t("div",{key:e.id,class:this.getElementClassName(e),ref:this.useRef(e)})}injectRTEScopeStyles(){return"div.statement{padding:2px 4px;background:rgba(var(--v-bg-accent3-secondary, 255, 239, 200));border:1px solid rgba(var(--v-bg-accent3-primary, 255, 220, 131));border-radius:4px;display:flex;flex-direction:row;justify-content:flex-start;align-items:stretch;gap:4px}div.statement .statementsyntax{padding:3px 0;line-height:22px}.rich-text-content div.statement .statementsyntax,.rich-text-content div.statement .statementelement{display:inline-block}div.statement+div.statement{margin-top:2px}div.statement .statementsyntax span{color:rgb(38, 42, 255);font-weight:bold}div.statement .statementelement{padding:2px 4px;background:rgba(var(--v-bg-secondary, 245, 247, 247));border:1px solid rgba(var(--v-border-color-input-field, 171, 198, 216));border-radius:4px;margin:0;min-width:8px}"}getElementClassName(t){let e=t.getClasses();return e.indexOf("statement")<0&&(e="statement "+e),e.trim()}}class Xe{}class qe extends Xe{canIntercept(t,e){return e.parent&&e.parent instanceof RTEFunctionBlock}intercept(t,e,n){const s=new x(n.children[0],0);s.isFlushable=!0,n.parent.apply(s)}}class Qe extends D{handleAction(t,e){const n=this.createNewParagraph("");n&&(e.parent.apply(new V(e,n)),t.newBlock=n,this.focusToNextLine(n))}focusToNextLine(t){const e=this.getRootContent(t);e&&e.apply(new y(t.children[0],1))}}class Ye extends B{constructor(t,e,n){super(),this.type="PASTE_PLAIN_TEXT",this.blocksToBeInserted=t,this.startNode=e,this.startOffset=n}}class tn extends qe{intercept(t,e,n){const{blocksToBeInserted:s,rteRange:o}=e;let{startNode:i,startOffset:r}=e;o&&(i=o.startNode,r=o.startOffset);const a=new Ye(s,i,r);n.apply(a)}}class en extends D{handleAction(t,e){const{blocksToBeInserted:n,startNode:s,startOffset:o}=t;if(s instanceof j){const t=n.flatMap((t=>t instanceof _?(this.copyLinkGroupAnnotations(e.annotationMap,t.annotationMap),t.children):[]));t.length>0&&(e.apply(o>0?new V(s,...t):new F(s,...t)),this.focusToNextLine(t[t.length-1],t[t.length-1].getRangeEndOffset()))}}focusToNextLine(t,e){const n=this.getRootContent(t);n&&n.apply(new y(t,e))}copyLinkGroupAnnotations(t,e){if(e&&e.has(K.LINK_GROUP)){const n=e.get(K.LINK_GROUP);t.has(K.LINK_GROUP)?n.linkGroups.forEach(((e,n)=>{t.get(K.LINK_GROUP).linkGroups.set(n,e)})):t.set(K.LINK_GROUP,e.get(K.LINK_GROUP))}}}const nn=new Ze,sn=new class extends Ze{constructor(){super(...arguments),this.blockClassName="statementelement"}handle(e,n){const s=w.generate(_,e[0]),o=Array.from(e[0].childNodes);return _.from({id:t(),type:"paragraph",annotations:Object.assign({customClass:[this.blockClassName]},s),nodes:this.generateChildNodes(o,void 0,n)})}},on=new class extends C{canHandle(t,e){const n=t[e];return n&&"DIV"===n.tagName&&n.classList.contains("statement")&&n.childNodes.length&&n.querySelector(".statementsyntax")?1:0}handle(){return RTEFunctionBlock.from({id:t(),type:"function-block",annotations:{customClass:["statement"]},children:[]})}appendChildBlocks(t,e){t.children=e.map((e=>(e.parent=t,e)))}shouldProceedToElementChildren(){return!0}};class rn extends De{constructor(){super(),this.toolbarButtonRenderer=new Ge,this.registerBlockBasicStrategies(RTELogicControlBlock.name),this.registerBlockBasicStrategies(RTEFunctionBlock.name),this.preventFunctionBlockDefaultInsertNewParagraph(),this.registerNode("logic-control-block",RTELogicControlBlock),this.registerRenderer("logic-control-block",new Ue),this.registerNode("function-block",RTEFunctionBlock),this.registerRenderer("function-block",new Je),this.registerToolbarButtonRenderer("functions",this.toolbarButtonRenderer),this.registerElementToBlockDTOClassStrategy(nn),this.registerElementToBlockDTOClassStrategy(sn),this.registerElementToBlockDTOClassStrategy(on)}preventFunctionBlockDefaultInsertNewParagraph(){this.unRegisterStrategy($.INSERT_NEW_PARAGRAPH,RTELogicControlBlock.name),this.unRegisterStrategy($.APPEND_CHILDREN,RTEFunctionBlock.name),this.unRegisterStrategy($.INSERT_CHILDREN_AFTER,RTEFunctionBlock.name),this.unRegisterStrategy($.INSERT_CHILDREN_BEFORE,RTEFunctionBlock.name),this.unRegisterStrategy($.PASTE_CONTENT,RTELogicControlBlock.name),De.registerActionHandleStrategy(RTEFunctionBlock.name,$.INSERT_NEW_PARAGRAPH,new Qe)}}(()=>{const t=new We;De.registerActionHandleStrategy(m.name,"INSERT_FUNCTION_BLOCK",t),De.registerActionHandleStrategy(_.name,"INSERT_FUNCTION_BLOCK",t),De.registerActionHandleStrategy(T.name,"INSERT_FUNCTION_BLOCK",t),De.registerActionHandleStrategy(RTELogicControlBlock.name,"INSERT_FUNCTION_BLOCK",t),De.registerActionHandleStrategy(_.name,"PASTE_PLAIN_TEXT",new en),De.registerActionHandlerInterceptor(_.name,$.INSERT_NEW_PARAGRAPH,new qe),De.registerActionHandlerInterceptor(_.name,$.PASTE_CONTENT,new tn)})();class an extends B{constructor(t){super(),this.isFlushable=!0,this.type="DELETE_TABLE_BLOCK",this.tableBlock=t}}class ln extends z{constructor(){super(...arguments),this.type=rt.CAPTION}clone(){return new ln}renderClass(t){return(null==t?void 0:t.standalone)?null:"v-rte--extension-table-caption"}renderStyle(t){return(null==t?void 0:t.standalone)?{padding:"8px",border:"1px solid #ddd",borderBottom:"none",backgroundColor:this.getCaptionBackgroundColor(),position:"relative",textAlign:"center",minHeight:"22px"}:null}toJSON(){return{caption:{padding:"8px 12px",border:"1px solid #ddd",borderBottom:"none",backgroundColor:this.getCaptionBackgroundColor(),position:"relative",textAlign:"center",minHeight:"22px"}}}getCaptionBackgroundColor(){return re.isDarkMode()?at.dark:at.light}}class RTETableCaptionBlock extends N{constructor(t,e){super(t),this.type="table-caption";const{autoMatchFormat:n}=e||{autoMatchFormat:!0};n&&this.annotationMap.set(rt.CAPTION,new ln)}static from(t,e){const n=new RTETableCaptionBlock(t.id,e);return super.convertAnnotationsToMap(n.annotationMap,Object.assign({},t.annotations)),n.children=super.generateBlockChildren(t.children,e,n),n}clone(t){const e=new RTETableCaptionBlock(this.id);return e.children=this.children.map((t=>t.clone(e))),e.parent=t,e.annotationMap=super.cloneAnnotations(),e}getLastNode(){return this.children[this.children.length-1].getLastNode()}isNotEmpty(){return this.children.length>0&&this.children.some((t=>t.isNotEmpty()))}toHtml(){const t=this.children.map((t=>t.toHtml())).join("");return`<caption${super.generateAttributeString()}>${t}</caption>`}toJSON(){return Object.assign(Object.assign({},super.toJSON()),{type:this.type,children:this.children.map((t=>t.toJSON()))})}}O.register($.INSERT_CHILDREN_BEFORE,RTETableCaptionBlock.name,new E),O.register($.PASTE_CONTENT,RTETableCaptionBlock.name,new S);class cn extends B{constructor(t){super(),this.type="TOGGLE_TABLE_CAPTION",this.isFlushable=!0,this.shouldEnable=t}}class hn extends lt{canHandle(t){return t[0]===ct.CAPTION}execute(t,e,n){const s="rte-table-caption"===t[1],o=new cn(s),i=n.getCaption();if(s){const t=i&&i.isNotEmpty()?i:this.createCaptionBlock(null==i?void 0:i.id);i&&t===i||n.setCaption(t),o.nextFocusNode=t.getLastNode()}else i&&(n.setCaption(null),o.nextFocusNode=n.getFirstNode());this.syncCursorPosition(n,o.nextFocusNode)}syncCursorPosition(t,e){super.syncCursorPosition(t,e)}createCaptionBlock(e){const n={id:null!=e?e:t(),type:"table-caption",children:[{id:t(),type:"paragraph",nodes:[{id:t(),type:"text",text:""}]}]};return RTETableCaptionBlock.from(n)}}class dn{constructor(t){this.renderContext=t}getTableExtensionContext(){return this.renderContext?_e.getExtensionContext(this.renderContext.host):null}}class un extends dn{constructor(){super(...arguments),this.settingHandlers=[new ht,new hn,new dt,new ut,new pt],this.handleTableClick=(t,e)=>{const n=t.target.closest("table");if(e!==n)return this.popoverRef.hide(),void this.tableDynamicPopover.hide();this.tableDynamicPopover.hide(),this.popoverShow||(ne.call(et.getSubject(this.popoverRef,se),n),this.popoverRef.show())},this.syncSelectedCells=()=>{if(this.tableSettingRef){const t=this.getTableSelectedCells();this.tableSettingRef.selectedCells=t}},this.handleSettingMenuClick=t=>{const e=this.settingHandlers.find((e=>e.canHandle(t.detail)));if(e){const n=this.getTableExtensionContext();n&&e.execute(t.detail,n,this.tableData),t.detail[0]===ct.CAPTION&&this.updateTableSettingCaption()}t.detail[0]!==ct.TABLE&&t.detail[0]!==ct.CELL||(this.popoverRef.hide(),this.tableDynamicPopover.show(t.detail[0]))},this.handleTableSettingPopoverShow=()=>{this.syncSelectedCells(),this.popoverShow=!0}}render(t,e,n,s){return this.tableData=e,this.tableDynamicPopover=s,t("vega-popover",{trigger:"click",isScreenPosition:!0,class:"rte-table-setting-popover",ref:t=>{this.popoverRef=t,this.popoverRef&&(tt.addUniqueObserverToNode(t,ot,this.handleTableSettingPopoverShow),tt.addUniqueObserverToNode(t,it,(()=>this.popoverShow=!1)))}},[t("div",{slot:"popover"},[t("vega-rich-text-table-setting",{ref:t=>{this.tableSettingRef=t,t&&(t.target=n())},selectedCells:this.getTableSelectedCells(),onVegaClick:this.handleSettingMenuClick})])])}updateTableSettingCaption(){const t=this.tableData.hasCaption();this.tableSettingRef&&this.tableSettingRef.hasCaption!==t&&(this.tableSettingRef.hasCaption=t)}getTableSelectedCells(){let t=[];const e=this.getTableExtensionContext();if(e&&e.tableSelection){const{tableSelection:n}=e;t=n.getSelectedCells()}return t}}class pn{static generateTablePropertiesForm(t){const e=t.annotationMap.get(rt.TABLE);let n={borderStyle:"none",borderColor:"",borderWidth:"",backgroundColor:"",width:"",height:"",textAlign:"center"};if(e){const t=e.toJSON().table,{style:s="none",color:o="",width:i=""}=t.border||{style:"none",color:"",width:""};n={backgroundColor:t.backgroundColor||"",width:t.width||"",height:t.height||"",textAlign:t.alignment,borderStyle:s,borderColor:o,borderWidth:i}}return n}updateCursorPosition(t,e){t&&e&&t.host.value.apply(new y(e,0))}}class fn extends W{constructor(t){super(),this.isFlushable=!0;const{textAlign:e,width:n,borderWidth:s,borderColor:o,borderStyle:i,height:r}=t,a=function(t,e){var n={};for(var s in t)Object.prototype.hasOwnProperty.call(t,s)&&e.indexOf(s)<0&&(n[s]=t[s]);if(null!=t&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(s=Object.getOwnPropertySymbols(t);o<s.length;o++)e.indexOf(s[o])<0&&Object.prototype.propertyIsEnumerable.call(t,s[o])&&(n[s[o]]=t[s[o]])}return n}(t,["textAlign","width","borderWidth","borderColor","borderStyle","height"]);this.tableProperties=Object.assign(Object.assign({},a),{alignment:e,border:{style:i,color:o,width:s?le(s):""},width:n?le(n):"",height:r?le(r):""})}toAnnotation(){return new ft(this.tableProperties)}}class gn extends pn{handle(t,e,n,s){e.apply(new fn(n)),this.updateCursorPosition(t,s)}}class bn extends pn{handle(t,e,n,s){t&&t.host&&(t.flushValue(t.host.value),this.updateCursorPosition(t,s))}}class wn extends pn{handle(t,e,n){const s=new fn(n);s.isFlushable=!1,e.apply(s)}}class yn extends W{constructor(t,e){super(),this.isFlushable=!0,this.cellAnnotation=t,this.originAnnotation=e}toAnnotation(){return this.updateOriginAnnotation(),this.originAnnotation}updateOriginAnnotation(){Object.keys(this.cellAnnotation).forEach((t=>{this.originAnnotation[t]=this.cellAnnotation[t]}))}}class mn extends yn{constructor(t,e){super(t,e),this.isFlushable=!0}toAnnotation(){return this.updateOriginAnnotation(),this.originAnnotation}}var vn=function(t,e){var n={};for(var s in t)Object.prototype.hasOwnProperty.call(t,s)&&e.indexOf(s)<0&&(n[s]=t[s]);if(null!=t&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(s=Object.getOwnPropertySymbols(t);o<s.length;o++)e.indexOf(s[o])<0&&Object.prototype.propertyIsEnumerable.call(t,s[o])&&(n[s[o]]=t[s[o]])}return n};class Cn{static getStyleCollectionFromCell(t){return t.reduce(((t,e)=>{const n=e.getAnnotationByType(rt.CELL);if(t[e.id]={},n){const s=n.toJSON().tableCell,{border:o}=s,i=vn(s,["border"]),r={};o&&(r.borderStyle=o.style,r.borderColor=o.color,r.borderWidth=o.width),t[e.id]=ce(Object.assign(Object.assign({},i),r))}return t}),{})}static convertStyleMapToFormField(t){const e={};for(const n in t){const s=t[n];for(const t in s)e[t]?e[t].push(s[t]):e[t]=[s[t]]}const n=Object.keys(t).length,s={};for(const t in e){const o=e[t],i=new Set(o);o.length===n&&1===i.size&&(s[t]=o[0])}return s}applyProperties(t,e,n){t.tableSelection.getSelectedCells().forEach((t=>{const s=e[t.id];if(s){const e=this.convertToVegaTableCellAnnotation(Object.assign({},s));this.applyAnnotation(t,e,n)}}))}updateCursorPosition(t,e){t&&e&&t.host.value.apply(new y(e,0))}convertToVegaTableCellAnnotation(t){const{borderStyle:e,borderWidth:n,borderColor:s}=t,o=vn(t,["borderStyle","borderWidth","borderColor"]),i=ce({style:e,width:n?le(n):"",color:s});return ce(Object.assign(Object.assign({},o),{backgroundColor:o.backgroundColor||"",padding:o.padding?le(o.padding):"",width:o.width?le(o.width):"",height:o.height?le(o.height):"",verticalAlign:o.verticalAlign||"",textAlign:o.textAlign||"",border:i}))}applyAnnotation(t,e,n){const s=t.getAnnotationByType(rt.CELL)||new gt({},!1),o=t instanceof bt?new mn(e,s):new yn(e,s);o.isFlushable=n,t.apply(o)}}class xn extends Cn{handle(t,e,n){t&&t.host&&(t.flushValue(t.host.value),this.updateCursorPosition(t,n))}}class Tn extends Cn{handle(t,e){this.applyProperties(t,e,!1)}}class En extends Cn{handle(t,e,n){this.applyProperties(t,e,!0),this.updateCursorPosition(t,n)}}class Sn extends dn{constructor(t,e){super(e),this.tableColorSchema=[],this.popoverCloseType="none",this.tablePropertiesHandlerMap={save:new bn,cancel:new gn,change:new wn},this.cellPropertiesHandlerMap={save:new xn,cancel:new En,change:new Tn},this.handleTablePropertiesUpdate=t=>{const e=t.type.replace("vega","").toLowerCase();this.popoverCloseType=e,"change"!==e&&this.hide();const n=this.getTableExtensionContext();n&&this.tablePropertiesHandlerMap[e].handle(n,this.currentTableBlock,t.detail,this.currentFocusNode),"change"===e&&this.popoverRef&&this.popoverRef.show(!0)},this.handleCellPropertiesUpdate=t=>{const e=t.type.replace("vega","").toLowerCase();this.popoverCloseType=e,"change"!==e&&this.hide();const n=this.getTableExtensionContext();n&&this.cellPropertiesHandlerMap[e].handle(n,t.detail,this.currentFocusNode),"change"===e&&this.popoverRef&&this.popoverRef.show(!0)},this.tableColorSchema=t}destroy(){this.selectionAnchorRef&&this.selectionAnchorRef.parentNode&&(tt.removeUniqueObserverFromNode(this.selectionAnchorRef,oe),this.selectionAnchorRef.parentNode.removeChild(this.selectionAnchorRef),this.selectionAnchorRef=null)}async show(t){let e=this.getTableRef();const n=this.getTableExtensionContext();let s=[];if(n&&(s=n.tableSelection.getSelectedCells()),t===ct.CELL&&s.length>1){const t=this.getOrCreateSelectionAnchor(s,e);t&&(e=t)}else t===ct.CELL&&1===s.length&&(e=R.getDOMByEntity(s[0]));this.updateContent(t),this.storeCurrentFocusNode(),ne.call(et.getSubject(this.popoverRef,se),e),await this.popoverRef.show()}async hide(){await this.popoverRef.hide()}render(t,e,n){return this.getTableRef=e,this.currentTableBlock=n,t("vega-popover",{trigger:"click",isScreenPosition:!0,class:"rte-table-dynamic-popover",ref:t=>{this.popoverRef=t,tt.addUniqueObserverToNode(t,it,(()=>{const t=this.getTableExtensionContext();"change"===this.popoverCloseType&&t&&t.flushValue(t.host.value)}))}},[t("div",{slot:"popover",class:"rte-table-dynamic-popover-content"},[t("vega-rich-text-table-properties",{ref:t=>this.tablePropertiesFormRef=t,colors:this.tableColorSchema,type:ct.TABLE,onVegaCancel:this.handleTablePropertiesUpdate,onVegaChange:this.handleTablePropertiesUpdate,onVegaSave:this.handleTablePropertiesUpdate}),t("vega-rich-text-table-properties",{ref:t=>this.cellPropertiesFormRef=t,colors:this.tableColorSchema,type:ct.CELL,onVegaCancel:this.handleCellPropertiesUpdate,onVegaChange:this.handleCellPropertiesUpdate,onVegaSave:this.handleCellPropertiesUpdate})])])}updateContent(t){this.popoverCloseType="none";const e=this.getTableExtensionContext();this.tablePropertiesFormRef&&"TABLE"===t?(this.tablePropertiesFormRef.classList.remove("vega-hidden"),this.cellPropertiesFormRef.classList.add("vega-hidden"),this.tablePropertiesFormRef.defaultValue=pn.generateTablePropertiesForm(this.currentTableBlock)):this.cellPropertiesFormRef&&"CELL"===t&&(this.cellPropertiesFormRef.classList.remove("vega-hidden"),this.tablePropertiesFormRef.classList.add("vega-hidden"),e&&(this.cellPropertiesFormRef.styleMap=Cn.getStyleCollectionFromCell(e.tableSelection.getSelectedCells())),this.cellPropertiesFormRef.defaultValue=Cn.convertStyleMapToFormField(this.cellPropertiesFormRef.styleMap)),e&&e.getSelection().removeAllRanges()}storeCurrentFocusNode(){const t=this.getTableExtensionContext();t&&(this.currentFocusNode=t.getSelectedNodes()[0])}getOrCreateSelectionAnchor(t,e){const n=ae();if(n&&e){const s=e.closest(".rich-text-content"),o=s.getBoundingClientRect();let i=Number.POSITIVE_INFINITY,r=Number.NEGATIVE_INFINITY,a=Number.POSITIVE_INFINITY,l=Number.NEGATIVE_INFINITY;t.map((t=>R.getDOMByEntity(t))).filter(J).forEach((t=>{const e=t.getBoundingClientRect();i=Math.min(i,e.left-o.left),r=Math.max(r,e.right-o.left),a=Math.min(a,e.top-o.top),l=Math.max(l,e.bottom-o.top)}));const c=r-i,h=l-a;return this.selectionAnchorRef=s.querySelector(".rte-table-selection-popover-anchor"),this.selectionAnchorRef||(this.selectionAnchorRef=n.createElement("div"),this.selectionAnchorRef.className="rte-table-selection-popover-anchor",this.selectionAnchorRef.style.position="absolute",this.selectionAnchorRef.style.pointerEvents="none",s.appendChild(this.selectionAnchorRef),tt.addUniqueObserverToNode(this.selectionAnchorRef,oe,(()=>{this.destroy()}))),this.selectionAnchorRef.style.left=`${i}px`,this.selectionAnchorRef.style.top=`${a}px`,this.selectionAnchorRef.style.width=`${c}px`,this.selectionAnchorRef.style.height=`${h}px`,this.selectionAnchorRef}}}class kn extends Me{doRender(t,e,n){const s=new un(n),o=new Sn(wt.getTableColors(),n);let i;const r=this.renderTable(t,e,(t=>i=t)),a=s.render(t,e,(()=>i),o),l=o.render(t,(()=>i),e),c=e.getAnnotationByType(rt.TABLE),h=n.editable?[t("vega-rich-text-table-selection-widget",{onVegaRemove:t=>{t.stopPropagation(),this.handleTableRemove(e,i)},onClick:t=>s.handleTableClick(t,i),onMouseLeave:()=>{s.syncSelectedCells()}},[t("div",{contentEditable:!0,ref:this.useRef(e)},[r,a,l])])]:[r],d={};if(c){const t=c.renderStyle();d.width=t.width,d.margin=t.margin}const u=t("div",{class:"v-rte--extension-table-container",style:Object.assign({},d)},h);return u.childrenContainerGetter=()=>r,u}injectRTEScopeStyles(){return".v-rte--extension-table-container{display:table}table.v-rte--extension-table{border-collapse:collapse}table.v-rte--extension-table th,table.v-rte--extension-table td{border:1px solid #ddd;padding:12px;text-align:left;vertical-align:middle;min-width:55px;box-sizing:border-box;position:relative}table.v-rte--extension-table th{background-color:#f2f2f2}.rte-table-setting-popover,.rte-table-dynamic-popover{display:block}table.v-rte--extension-table .v-rte-table-cell-focused::after,table.v-rte--extension-table .v-rte-table-cell-selected::after{content:'';position:absolute;top:0;left:0;right:0;bottom:0;pointer-events:none;background-color:rgba(158, 207, 250, 0.3)}table.v-rte--extension-table:has(.v-rte-table-cell-selected){caret-color:transparent}table.v-rte--extension-table:has(.v-rte-table-cell-selected) ::selection{background-color:transparent}table.v-rte--extension-table:has(.v-rte-table-cell-selected) ::-moz-selection{background-color:transparent}.v-rte--extension-table-caption{padding:8px;border:1px solid #ddd;border-bottom:none;background-color:rgba(var(--v-bg-table-header, 24, 24, 48));position:relative;display:table-caption;caption-side:top;min-height:22px;text-align:center;word-break:break-word;overflow-wrap:break-word}.v-rte--extension-table-caption.showPlaceholder::before{position:absolute;left:0;right:0;content:attr(data-placeholder);font-family:'Inter', sans-serif;font-size:16px;font-weight:400;line-height:24px;letter-spacing:0;color:rgba(var(--v-text-input-placeholder, 176, 180, 181, 1));text-align:center;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}"}renderTable(t,e,n){var s;return t("table",Object.assign(Object.assign({key:e.id},null===(s=e.getCustomAttributesAnnotation())||void 0===s?void 0:s.render()),{style:e.getStyles(),class:e.getClasses(),ref:t=>{this.useRef(e)(t),n(t)}}))}handleTableRemove(t,e){t.parent.apply(new an(t)),this.destroySelectionAnchor(e)}destroySelectionAnchor(t){const e=t.closest(".rich-text-content");if(e){const t=e.querySelector(".rte-table-selection-popover-anchor");t&&he.notify(et.getSubject(t,oe),{host:t})}}}class An extends Me{doRender(t,e){return t("thead",{key:e.id,ref:this.useRef(e)})}}class Rn extends Me{doRender(t,e){return t("tr",{key:e.id,ref:this.useRef(e)})}}class On extends Me{doRender(t,e,n){return this.renderByCellType(t,e,n,"td")}renderByCellType(t,e,n,s){var o;return t(s,Object.assign(Object.assign(Object.assign({key:`${e.id}-${s}`,ref:this.useRef(e)},null===(o=e.getCustomAttributesAnnotation())||void 0===o?void 0:o.render()),{style:e.getStyles(n),class:e.getClasses()}),n.editable?this.onSelectionListeners(e,n):void 0))}onSelectionListeners(t,e){return{onMouseDown:t=>{const n=o(t.target,"table"),s=o(t.currentTarget,"table")===n,i=t.target.closest("td, th");if(s&&i){const t=this.getExtensionContext(e.host);t&&t.tableSelection.focusCell(i)}},onMouseMove:n=>{n.stopPropagation(),n.preventDefault();const s=this.getExtensionContext(e.host);s&&s.tableSelection.dragOver(t)},onMouseUp:()=>{const t=this.getExtensionContext(e.host);t&&t.tableSelection.endDrag()}}}}class In extends Me{doRender(t,e){return t("tbody",{key:e.id,ref:this.useRef(e)})}}class Ln extends On{doRender(t,e,n){return super.renderByCellType(t,e,n,"th")}}class Bn extends B{constructor(t,e){super(),this.type="INSERT_TABLE_BLOCK",this.rowCount=t,this.columnCount=e}}class jn extends dn{constructor(){super(...arguments),this.hoveredRows=1,this.hoveredCols=1}render(t,e){return t("vega-popover",{trigger:"click",alignment:"start",placement:"bottom",showArrow:!1,ref:t=>{t&&(this.tablePickerPopoverRef=t,tt.addUniqueObserverToNode(t,ot,(()=>{this.resetPicker()})))}},[t("div",{slot:"popover"},[this.generatePickerStyles(t),this.generateTableSizeGrid(t)]),t("div",{slot:"popover-content"},e)])}generateTableSizeGrid(t){const e=[];for(let n=1;n<=10;n++)for(let s=1;s<=10;s++)e.push(t("button",{class:"rte-table-picker__cell","data-row":n,"data-col":s,onMouseenter:this.handlePickerCellHover.bind(this,n,s),onClick:this.handlePickerClick.bind(this,n,s)},[]));return t("div",{class:"rte-table-picker"},[t("div",{class:"rte-table-picker__grid",ref:t=>{t&&(this.tablePickerGridRef=t)},style:{gridTemplateColumns:"repeat(10, 16px)",gridTemplateRows:"repeat(10, 16px)"}},e),t("div",{class:"rte-table-picker__hint"},t("vega-hint",{ref:t=>{t&&(this.selectedHintRef=t)}},[`${this.hoveredRows} × ${this.hoveredCols}`]))])}generatePickerStyles(t){return t("style",{},["\n.rte-table-picker__grid { display: grid; gap: 2px; }\n.rte-table-picker__cell {\n box-sizing: border-box;\n border: 1px solid #ccc;\n background-color: transparent;\n cursor: pointer;\n}\n.rte-table-picker__cell:hover {\n background-color: #cae1fc;\n}\n.rte-table-picker__cell.active {\n background-color: #cae1fc;\n}\n.rte-table-picker__hint {\n text-align: center;\n}\n "])}createTable(t,e){const n=this.getTableExtensionContext();if(n){const{host:s,getSelectedNodes:o}=n,i=o()[0],r=new Bn(t,e);i?i.parent&&i.parent.apply(r):s.value.apply(r),r.nextFocusNode&&s.value.apply(new y(r.nextFocusNode,1))}}handlePickerClick(t,e){this.createTable(t,e),this.tablePickerPopoverRef.hide()}handlePickerCellHover(t,e){this.hoveredRows=t,this.hoveredCols=e,Array.from(this.tablePickerGridRef.children).forEach((t=>{const e=Number(t.dataset.row),n=Number(t.dataset.col);e<=this.hoveredRows&&n<=this.hoveredCols?t.classList.add("active"):t.classList.remove("active")})),this.selectedHintRef.textContent=`${this.hoveredRows} × ${this.hoveredCols}`}resetPicker(){this.handlePickerCellHover(1,1)}}class Nn extends Ve{render(t,e){return new jn(e).render(t,super.renderButton(t,e,{showArrowIcon:!0,icon:"rte-table"}))}isDisabled(t){let e=super.isDisabled(t);const n=this.getExtensionContext(t.host);if(n){const{host:t,getSelectedNodes:s}=n,o=s()[0];let i=!0;o&&(i=O.canHandle("INSERT_TABLE_BLOCK",o.parent)&&O.canHandle($.INSERT_CHILDREN_AFTER,o.parent.parent)),e=t.disabled||!i}return e}handleButtonClick(){}handleDropdownClick(){}}Q.register({"rte-table":{icon:'<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 512 512">\x3c!--! Font Awesome Pro 6.3.0 by @fontawesome - https://fontawesome.com License - https://fontawesome.com/license (Commercial License) Copyright 2023 Fonticons, Inc. --\x3e<path fill="currentColor" d="M48 264V160H232V264H48zm0 48H232V432H64c-8.8 0-16-7.2-16-16V312zM280 432V312H464V416c0 8.8-7.2 16-16 16H280zM464 264H280V160H464V264zM64 32C28.7 32 0 60.7 0 96V416c0 35.3 28.7 64 64 64H448c35.3 0 64-28.7 64-64V96c0-35.3-28.7-64-64-64H64z"/></svg>'}});class _n extends D{handleAction(t,e){const n=this.createTableBlock(t.rowCount,t.columnCount),s=super.createNewParagraph(""),o=this.getReferenceBlock(e);o?o.parent.apply(new V(o,n,s)):e.apply(new P([n,s])),t.nextFocusNode=n.getFirstNode()}createTableBlock(e,n){const s=Math.max(e,1),o=Math.max(n,1);return yt.from({id:t(),type:"table-block",children:[mt(s,o)]})}getReferenceBlock(t){if(!(t instanceof m))return t}}class Mn extends Xe{canIntercept(t,e){const n=e.parent;return n instanceof vt&&1===n.children.length&&0===t.startOffset}intercept(){}}class Dn extends D{handleAction(t){const e=t.tableBlock,n=e.parent,s=super.getRootContent(e),o=super.createNewParagraph("");n.apply(new V(e,o)),n.apply(new G(e)),s&&s.apply(new y(o.getLastNode()))}}class Vn extends Xe{canIntercept(t,e){return t.entityToBeRemoved&&1===e.children.length}intercept(e,n,s){if(!(n.entityToBeRemoved instanceof _)){const e=_.from({id:t(),type:"paragraph",nodes:[{id:t(),type:"text",text:""}]});return s.children=[],void s.apply(new P([e]))}n.entityToBeRemoved.apply(new P([new j(t(),"",n.entityToBeRemoved)]))}}class Pn extends Me{doRender(t,e){return t("caption",{key:e.id,ref:this.useRef(e),style:e.getStyles(),class:[e.getClasses(),e.isNotEmpty()?null:"showPlaceholder"].filter(J).join(" "),"data-placeholder":"Enter table caption"})}}class Hn extends D{getRowsMaxCellCount(t){let e=0;for(const n of t){let t=0;for(const e of n.children)t+=e.colSpan;e=Math.max(e,t)}return e}getRowCellStartCols(t){const e=this.getRowsMaxCellCount(t),n=new Array(t.length),s=new Array(e).fill(0);for(let e=0;e<t.length;e++){const o=t[e].children,i=new Array(o.length);let r=0;for(let t=0;t<o.length;t++){const e=o[t];for(;r<s.length&&s[r]>0;)r++;i[t]=r;const n=Math.max(e.colSpan,Hn.DEFAULT_CELLSPAN);if(e.rowSpan>Hn.DEFAULT_CELLSPAN)for(let t=0;t<n;t++){const n=r+t;n<s.length&&(s[n]=Math.max(s[n],e.rowSpan))}r+=n}n[e]=i;for(let t=0;t<s.length;t++)s[t]>0&&s[t]--}return n}updateCellSpan(t,e,n){const s=t.getCustomAttributesAnnotation();if(n<=Hn.DEFAULT_CELLSPAN){if(s){const n=s.render();delete n[e],t.annotationMap.set(U.CUSTOM_ATTRIBUTE,new Z(n))}}else{const o=s?s.render():{};o[e]=n.toString(),t.annotationMap.set(U.CUSTOM_ATTRIBUTE,new Z(o))}}insertMovedCells(t,e,n){t.forEach(((t,s)=>{const o=e[s];if(o){const e=n[s]||[];t.sort(((t,e)=>t.logicalStartCol===e.logicalStartCol?e.cellIndex-t.cellIndex:e.logicalStartCol-t.logicalStartCol)),t.forEach((t=>{const{cell:n,logicalStartCol:s}=t;if(0===o.children.length)return o.apply(new P([n])),void(e[0]=s);const i=e.findIndex((t=>t>=s));-1===i?(o.apply(new V(o.children[o.children.length-1],n)),e.push(s)):0===i?(o.apply(new F(o.children[0],n)),e.unshift(s)):(o.apply(new F(o.children[i],n)),e.splice(i,0,s))}))}}))}splitRowsBySection(t){const e=[],n=[];return t.forEach((t=>{t.parent instanceof Ct?e.push(t):n.push(t)})),[e,n]}buildSelectedIndices(t,e){return new Set(t.map((t=>e.indexOf(t))).filter((t=>t>=0)))}intersectsRemovalRange(t,e,n,s){return t<=s&&e>=n}countRemovedRows(t,e,n){let s=0;for(let o=t;o<=e;o++)n.has(o)&&s++;return s}getHeadCellLength(t){let e=0;for(let n=0;n<t.children.length;n++){const s=t.children[n];if(!(s instanceof bt))break;e+=s.colSpan}return e}getTheStartSpanCell(t,e,n,s){const o={rowIndex:n};for(let i=n;i>=0;i--){const n=e[i];if(n.includes(s)){o.cell=t[i].children[n.indexOf(s)],o.rowIndex=i;break}}return o}getDefaultCellBlockTemplate(e,n,s=1){const o=ce({colspan:n>1?n.toString():null,rowspan:s>1?s.toString():null}),i=t(),r={id:i,type:e,children:[{id:`${i}-p`,type:"paragraph",nodes:[{id:`${i}-p-t`,type:"text",text:""}]}]};return Object.keys(o).length>0&&(r.annotations={customAttribute:o}),r}getSortedValuesByNumericKey(t){return Array.from(t.entries()).sort((([t],[e])=>t-e)).map((([,t])=>t))}}Hn.DEFAULT_CELLSPAN=1;class Fn extends Hn{handleAction(t,e){const{rowsToBeRemoved:n}=t,s=this.getFutureFocusRow(n[0],n[n.length-1],e),o=this.splitRowsBySection(n);if(this.removeRows(o[0]),this.removeRows(o[1]),s){const t=this.getRootContent(e);if(t){const e=s.getLastNode();t.apply(new y(e,e.getRangeEndOffset()))}}}removeRows(t){if(0===t.length)return;const e=t[0].parent,n=e.children,s=this.buildSelectedIndices(t,n);if(s.size>0){if(n.length===t.length)return void e.parent.apply(new G(e));const o=Math.min(...s),i=Math.max(...s),r=this.getRowCellStartCols(n),a=this.collectCellsToMove(n,r,s,o,i);this.insertMovedCells(a,n,r),t.forEach((t=>{t.parent.apply(new G(t))}))}}collectCellsToMove(t,e,n,s,o){const i=new Map,r=t.length;for(let a=0;a<r;a++){const l=t[a],c=l.children.length;for(let t=0;t<c;t++){const c=l.children[t],h=c.rowSpan;if(h<=Hn.DEFAULT_CELLSPAN)continue;const d=a+h-1;if(!this.intersectsRemovalRange(a,d,s,o))continue;const u=h-this.countRemovedRows(a,d,n);if(a<s&&d>=s)this.updateCellSpan(c,"rowspan",u);else if(a>=s&&d>o){const s=o+1;if(s<r&&!n.has(s)){const n=e[a][t];i.has(s)||i.set(s,[]),i.get(s).push({cell:this.cloneCellWithRowSpan(c,u),newRowSpan:u,cellIndex:t,logicalStartCol:n})}}}}return i}cloneCellWithRowSpan(t,e){const n=t.clone(t.parent);return this.updateCellSpan(n,"rowspan",e),n}getFutureFocusRow(t,e,n){const s=n.children.filter((t=>t instanceof Ct||t instanceof xt)).flatMap((t=>t.children)),o=s.indexOf(t),i=s.indexOf(e);return s[o-1]?s[o-1]:s[i+1]?s[i+1]:void 0}}class Kn{constructor(){this.dragging=!1,this.anchorCell=null,this.selectedCells=new Set,this.syncRTESelectionWithDebounce=de(this.syncRTESelection,100,this),this.handleSelectionChangeWithDebounce=de(this.handleSelectionChange,10,this),this.filterSelectedCell=(t,e)=>{const n=new Set;if(t.intersectsNode(e)){if(e.nodeType===Node.TEXT_NODE){const t=R.getEntityByDOM(e.parentElement);if(t){const e=Tt(t.parent,vt);if(e)return n.add(e),Array.from(n)}}e.childNodes.forEach((e=>this.filterSelectedCell(t,e).forEach((t=>{n.add(t)}))))}return Array.from(n)},this.updateSelectedStyles=(t,e)=>{const n=1===e?"v-rte-table-cell-focused":"v-rte-table-cell-selected",s=R.getDOMByEntity(t);s&&s.classList.add(n)},this.handleDocMouseUp=()=>{this.endDrag();const t=ae();t&&t.removeEventListener("mouseup",this.handleDocMouseUp)},this.handleContentClick=()=>{this.clearSelection();const t=this.context.host.shadowRoot.querySelector(".rich-text-editor-container");t&&t.removeEventListener("mousedown",this.handleContentClick,!0)}}static computeRectRange(t,e){const n=t.parent.parent.parent;if(n!==e.parent.parent.parent)return[];const s=[];n.children.forEach((t=>{t.children.forEach((t=>s.push(t)))}));const{grid:o,cellMeta:i}=Kn.buildCellGrid(s),r=i.get(t),a=i.get(e);if(!r||!a)return[];const l=r.row+r.rowSpan-1,c=r.col,h=r.col+r.colSpan-1,d=a.row+a.rowSpan-1,u=a.col,p=a.col+a.colSpan-1,f=Math.min(r.row,a.row),g=Math.max(l,d),b=Math.min(c,u),w=Math.max(h,p),y=new Set;for(let t=f;t<=g;t++){const e=o[t];for(let t=b;t<=w;t++){const n=e[t];n&&y.add(n)}}return Array.from(y)}static getCellSpan(t){let e=1,n=1;const s=t.getAnnotationByType(U.CUSTOM_ATTRIBUTE);if(s&&s.customAttribute){const t=s.customAttribute;t.rowSpan&&(e=parseInt(t.rowSpan,10)),t.colSpan&&(n=parseInt(t.colSpan,10))}if(1===e&&1===n){const s=R.getDOMByEntity(t);if(s){const t=s.getAttribute("rowSpan"),o=s.getAttribute("colSpan");t&&(e=parseInt(t,10)),o&&(n=parseInt(o,10))}}return{rowSpan:Number.isFinite(e)&&e>0?e:1,colSpan:Number.isFinite(n)&&n>0?n:1}}static buildCellGrid(t){const e=[],n=new Map;for(let s=0;s<t.length;s++){const o=t[s];e[s]||(e[s]=[]);let i=0;for(let t=0;t<o.children.length;t++){const r=o.children[t];for(;e[s][i];)i+=1;const{rowSpan:a,colSpan:l}=Kn.getCellSpan(r);n.set(r,{row:s,col:i,rowSpan:a,colSpan:l});for(let t=0;t<a;t++){const n=s+t;e[n]||(e[n]=[]);for(let t=0;t<l;t++)e[n][i+t]=r}i+=l}}return{grid:e,cellMeta:n}}destroy(){this.removeSelectionChangeListener()}init(t){this.context=t,this.addSelectionChangeListener()}setSelectedCells(t){const e=Array.from(this.selectedCells)[0]||t[0];this.updateSelectedCells(t),this.emitCellSelectionChange(e,t)}getSelectedCells(){return Array.from(this.selectedCells)}focusCell(t){const e=R.getEntityByDOM(t);e&&(this.anchorCell=e,this.setSelectedCells([e]),this.addListeners())}dragOver(t){if(!this.anchorCell)return;const e=Kn.computeRectRange(this.anchorCell,t);e.length>1&&this.startDrag(),this.dragging&&(this.preventTextSelection(e),this.updateSelectedCells(e,{debounceSync:!0}))}endDrag(){this.dragging=!1,this.anchorCell=null}emitCellSelectionChange(t,e){const n=Tt(t,yt);if(n){const t=R.getDOMByEntity(n);t&&he.notify(et.getSubject(t,ie),{host:t,detail:e})}}clearSelection(){this.selectedCells.forEach((t=>{const e=R.getDOMByEntity(t);e&&e.classList.remove("v-rte-table-cell-selected","v-rte-table-cell-focused")})),this.selectedCells.clear()}addSelectionChangeListener(){const t=ae();t&&t.addEventListener("selectionchange",this.handleSelectionChangeWithDebounce)}removeSelectionChangeListener(){const t=ae();t&&t.removeEventListener("selectionchange",this.handleSelectionChangeWithDebounce)}handleSelectionChange(){if(this.dragging)return void this.syncRTESelectionWithDebounce();const t=this.context.getSelection();if(t.rangeCount>0){const e=t.getRangeAt(0),n=e.commonAncestorContainer;if(o(n,"table")){const t=this.filterSelectedCell(e,n);this.setSelectedCells(t)}}}startDrag(){this.dragging=!0}updateSelectedCells(t,{debounceSync:e}={}){this.clearSelection(),t.forEach((e=>{this.selectedCells.add(e),this.updateSelectedStyles(e,t.length)})),e?this.syncRTESelectionWithDebounce():this.syncRTESelection()}syncRTESelection(){const t=Array.from(this.selectedCells),e=t.flatMap((t=>t.children.flatMap((t=>t.children.flatMap((t=>{if(t instanceof H)return t})))))).filter(J);t.length>1&&this.context.setSelectedNodes(e,{startNode:e[0],endNode:e[e.length-1],startOffset:0,endOffset:e[e.length-1].getRangeEndOffset()})}preventTextSelection(t){const e=this.context.getSelection();if(e.removeAllRanges(),t.length>0){const n=R.getDOMByEntity(t[0]);if(n){const t=new Range;t.setStart(n,0),t.setEnd(n,0),e.addRange(t)}}}addListeners(){const t=ae();t&&t.addEventListener("mouseup",this.handleDocMouseUp);const e=this.context.host.shadowRoot.querySelector(".rich-text-editor-container");e&&e.addEventListener("mousedown",this.handleContentClick,!0)}}class $n extends Hn{handleAction(t,e){const{selectedRows:n}=t,[s,o]=this.splitRowsBySection(n);o.length>0?this.convertToHeaderRows(o,e):this.revertToBodyRows(s,e);const i=this.getRootContent(e);if(i){const t=n[0].getFirstNode();t&&i.apply(new y(t,0))}}convertToHeaderRows(e,n){let s=n.children.find((t=>t instanceof Ct));const o=e[0].parent;s||(s=Ct.from({id:t(),type:"table-head",children:[]}),n.apply(new F(o,s)));const i=o.children.indexOf(e[e.length-1]),r=o.children.slice(0,i+1),a=this.buildSelectedIndices(r,o.children),l=Math.min(...a),c=Math.max(...a);if(a.size>0){if(a.size<o.children.length){const t=this.getRowCellStartCols(o.children),e=this.collectCellsToMove(o.children,t,a,l,c);this.insertMovedCells(e,o.children,t)}this.convertBodyRowsToHeaderRows(o,s,r)}}convertBodyRowsToHeaderRows(t,e,n){for(let e=0;e<n.length;e++){const s=n[e];s.children=s.children.map((t=>this.convertTdToTh(t))),t.apply(new G(s))}e.apply(new P(n))}revertToBodyRows(e,n){let s=n.children.find((t=>t instanceof xt));const o=e[0].parent;s||(s=xt.from({id:t(),type:"table-body",children:[]}),n.apply(new V(o,s)));const i=o.children.indexOf(e[0]),r=o.children.slice(i),a=this.buildSelectedIndices(r,o.children);if(a.size>0){const t=this.getRowCellStartCols(o.children),e=this.collectCellsToMove(o.children,t,a,Math.min(...a),Math.max(...a));this.insertMovedCells(e,o.children,t),this.convertHeadRowsToBodyRows(o,s,r)}}convertHeadRowsToBodyRows(t,e,n){const s=e.children[0],o=this.getRowCellStartCols(n);for(let i=0;i<n.length;i++){const r=n[i];t.apply(new G(r));const a=s?this.getHeadCellLength(s):0;r.children=this.convertThToTd(r,o[i],a),s&&e.apply(new F(s,r))}s||e.apply(new P(n))}collectCellsToMove(t,e,n,s,o){const i=new Map,r=t.length;for(let a=0;a<r;a++){const l=t[a],c=l.children.length;for(let t=0;t<c;t++){const c=l.children[t],h=c.rowSpan;if(h<=Hn.DEFAULT_CELLSPAN)continue;const d=a+h-1;if(!this.intersectsRemovalRange(a,d,s,o))continue;const u=this.countRemovedRows(a,d,n),p=h-u;if(a<s&&d>=s){this.updateCellSpan(c,"rowspan",p);const o=s;if(o<r&&n.has(o)){const n=e[a][t];i.has(o)||i.set(o,[]),i.get(o).push({cell:this.cloneCellWithRowSpan(c,u),newRowSpan:u,cellIndex:t,logicalStartCol:n})}}else if(a>=s&&d>o){this.updateCellSpan(c,"rowspan",u);const s=o+1;if(s<r&&!n.has(s)){const n=e[a][t];i.has(s)||i.set(s,[]),i.get(s).push({cell:this.cloneCellWithRowSpan(c,p),newRowSpan:p,cellIndex:t,logicalStartCol:n})}}}}return i}convertTdToTh(t){if(t instanceof bt)return t;const e=bt.from(t.toJSON());return e.parent=t.parent,e}convertThToTd(t,e,n){return t.children.map(((s,o)=>{let i=s;const r=e[o]<n,a=s.toJSON();return i=r?s:vt.from(this.deleteHeadCellDefaultBackground(a)),i.parent=t,i}))}cloneCellWithRowSpan(e,n){const s=e.clone(e.parent);s.id=t(),s.children=[];const o=this.createNewParagraph("");return o&&s.apply(new P([o])),this.updateCellSpan(s,"rowspan",n),s}deleteHeadCellDefaultBackground(t){var e;if(t&&t.annotations&&t.annotations.customStyle){delete t.annotations.tableCell;const n=t.annotations.customStyle.backgroundColor,s=Et.getDefaultBackgroundColor();!n||n!==s&&(null===(e=i(n))||void 0===e?void 0:e.toUpperCase())!==s||delete t.annotations.customStyle.backgroundColor}return t}}class zn extends St{handleAction(t,e){const{insertDirection:n,tableCellInsertRange:s}=t,o=new Set(s.map((t=>t.id))),i=kt(e),r=At(i),[a,l]=this.getBoundaryCellColumnRange(s,i,r),c=n===Lt.LEFT?a:l+1,h=this.hasSelectedCellInsideTargetColumn(i,r,c,o),d=new Set;i.forEach(((t,s)=>{if(d.has(s))return;const a=this.findExpandableCell(t,s,c,r,n,o,h);if(a){const t=a.rowSpan;if(Rt(a,a.colSpan+1,a.rowSpan,e,!0),t>1)for(let e=1;e<t;e++)d.add(s+e);return}const l=this.findInsertPosition(t,s,c,r,i);if(l){const e=this.generateTableCell(l.templateCell);t.apply(l.before?new F(l.anchorCell,e):new V(l.anchorCell,e))}}))}findExpandableCell(t,e,n,s,o,i,r){const a=s[e],l=t.children.reduce(((t,e)=>t+(i.has(e.id)?1:0)),0);for(const c of t.children){const t=a.indexOf(c.id),h=t+c.colSpan,d=n===h,u=e+c.rowSpan>=s.length,p=i.has(c.id),f=n>t&&n<h;if(o===Lt.LEFT?f:f&&(!p||!u)||d&&c.colSpan>1&&p&&!u&&1===l&&!r)return c}return null}hasSelectedCellInsideTargetColumn(t,e,n,s){for(let o=0;o<t.length;o++){const i=t[o],r=e[o];for(const t of i.children){if(!s.has(t.id))continue;const e=r.indexOf(t.id),o=e+t.colSpan;if(n>e&&n<o)return!0}}return!1}findInsertPosition(t,e,n,s,o){const i=s[e];let r=t.children[0];if(n>=0&&n<i.length){const t=Ot(o,i[n]);t&&(r=t)}let a=0;for(let e=0;e<t.children.length;e++){const s=t.children[e];for(;a<i.length&&i[a]!==s.id;)a++;if(a>=n)return{anchorCell:s,templateCell:r,before:!0};const o=a+s.colSpan;if(o>n||e===t.children.length-1)return{anchorCell:s,templateCell:r,before:!1};a=o}return null}generateTableCell(t){return t instanceof bt?bt.from(It(t.type)):vt.from(It(t.type))}}class Wn extends St{handleAction(t,e){const n=kt(e),s=At(n),[o,i]=this.getBoundaryCellColumnRange(t.tableCellDeleteRange,n,s),r=Math.max(n.indexOf(t.tableCellDeleteRange[t.tableCellDeleteRange.length-1].parent),0),{coveredCellIds:a,coveredCells:l,adjustmentCellInfo:c}=this.getDeleteCellsInfo(n,o,i,s),h=this.findNextFocusableCell(n,s,o,i,a,r);this.deleteCells(l,c,e);const d=this.getRootContent(e),u=Nt(h);d&&u&&d.apply(new y(u))}getDeleteCellsInfo(t,e,n,s){const o=[],i=new Set,r=[],a=Bt(s);return t.forEach((t=>{t.children.forEach((t=>{const s=a.get(t.id);if(void 0===s)return;const{colSpan:l,rowSpan:c}=_t(t),h=this.getColumnOverlapCount(s,l,e,n);if(h<=0)return;if(h===l)return o.push(t),void i.add(t.id);const d=Math.max(1,l-h);r.push({cell:t,nextColSpan:d,rowSpan:c})}))})),{coveredCells:o,coveredCellIds:i,adjustmentCellInfo:r}}findNextFocusableCell(t,e,n,s,o,i){for(let r=0;r<t.length;r++){const a=this.findFocusableCellIdInGridRow(e[(i+r)%t.length],n,s,o);if(!a)continue;const l=Ot(t,a);if(l)return l}return null}findFocusableCellIdInGridRow(t,e,n,s){for(let e=n+1;e<t.length;e++){const n=t[e];if(n&&!s.has(n))return n}for(let n=e-1;n>=0;n--){const e=t[n];if(e&&!s.has(e))return e}return null}deleteCells(t,e,n){t.forEach((t=>{t.parent.apply(new G(t))}));const s=new Set;e.forEach((({cell:t,nextColSpan:e,rowSpan:o})=>{s.add(t.id),Rt(t,e,o,n)})),this.normalizeRemainingCellSpans(n,s)}normalizeRemainingCellSpans(t,e){kt(t).forEach((n=>{n.children.forEach((n=>{const{colSpan:s,rowSpan:o}=_t(n);if(e.has(n.id)){const e=jt(t);if(!(o>1&&s===e))return}Rt(n,s,o,t)}))}))}getColumnOverlapCount(t,e,n,s){const o=t+e-1,i=Math.max(t,n),r=Math.min(o,s);return i<=r?r-i+1:0}}class Gn extends B{constructor(t){super(),this.isFlushable=!0,this.type="CREATE_SEGMENT_TABLE_CELL",this.payload=t}}class Un extends D{handleAction(t,e){const{table:n,sourceCell:s,colSpan:o,cellType:i,keepSourceContent:r}=t.payload,a=r?this.convertCellType(s,i):Mt(i);Rt(a,o,s.rowSpan,n),e.apply(new F(s,a))}convertCellType(t,e){return"table-head-cell"===e?bt.from(t.toJSON()):vt.from(t.toJSON())}}class Zn extends D{handleAction(t,e){const{cell:n,targetCellType:s}=t.payload,o="table-head-cell"===s?bt.from(n.toJSON()):vt.from(n.toJSON());e.apply(new F(n,o)),e.apply(new G(n))}}class Jn extends D{handleAction(t,e){const{table:n,cell:s,col:o,cellStartCol:i,endCol:r,targetCellType:a}=t.payload,l=i+s.colSpan-1,c=o>i?o-i:0,h=Math.min(r,l),d=h-o+1,u=l-h;c>0&&e.apply(new Gn({table:n,sourceCell:s,colSpan:c,cellType:s.type,keepSourceContent:!0})),e.apply(new Gn({table:n,sourceCell:s,colSpan:d,cellType:a,keepSourceContent:0===c})),u>0&&e.apply(new Gn({table:n,sourceCell:s,colSpan:u,cellType:s.type,keepSourceContent:0===c&&d===s.colSpan})),e.apply(new G(s))}}class Xn extends St{handleAction(t,e){const n=kt(e),s=At(n),o=Bt(s),[i,r]=this.getBoundaryCellColumnRange(t.tableCellSelectRange,n,s),a=[],l=new Set;n.forEach((t=>{t.children.forEach((t=>{const e=o.get(t.id);void 0!==e&&e>=i&&e<=r&&!l.has(t.id)&&(l.add(t.id),a.push(t))}))})),t.selectCellCallback(a)}}class qn extends Xe{canIntercept(t){return t.childrenToBeInserted.some((t=>!(t instanceof vt)))}intercept(){}}class Qn extends D{handleAction(t,e){const{targetCell:n,mergeCells:s,colSpan:o,rowSpan:i,direction:r}=t;this.mergeContentToTargetCell(n,s),Rt(n,o,i,e),this.deleteOtherSelectedCells(s,n),r!==Dt.MERGE_CELL_LEFT&&r!==Dt.MERGE_CELL_RIGHT&&i>1&&this.clearRowSpanIfUniformAcrossRow(n,e,i);const a=this.getRootContent(e),l=Nt(n);a&&l&&a.apply(new y(l))}mergeContentToTargetCell(t,e){const n=e.flatMap((t=>t.children)),s=n.filter((t=>t.isNotEmpty()));t.children=(s.length>0?s:[n[0]]).map((e=>e.clone(t)))}deleteOtherSelectedCells(t,e){t.forEach((t=>{t!==e&&t.parent.apply(new G(t))}))}clearRowSpanIfUniformAcrossRow(t,e,n){const s=t.parent.parent.children,o=At(s),i=[];for(let e=0;e<o.length;e++)o[e].includes(t.id)&&i.push(e);if(i.length>1){const t=i[0],r=t+n-1,a=new Set;let l=Number.POSITIVE_INFINITY;for(let e=0;e<o[0].length;e++){let n=o[t][e],s=1,i=!1;for(let c=t+1;c<=r;c++)o[c][e]!==n?(s>1&&(i=!0,l=Math.min(l,s),a.add(n)),s=1,n=o[c][e]):s++;if(s<2&&!i){a.clear();break}s>1&&(l=Math.min(l,s),a.add(n))}a.size>0&&s.forEach((t=>{t.children.forEach((t=>{if(a.has(t.id)){const{rowSpan:n,colSpan:s}=_t(t);Rt(t,s,n-l+1,e)}}))}))}}}class Yn extends C{canHandle(t,e){const n=t[e];return n&&"TABLE"===n.tagName?1:0}handle(e,n){return yt.from({id:t(),type:"table-block",annotations:w.generate(yt,e[0],n),children:[]},n)}appendChildBlocks(t,e){t.children=e.map((e=>(e.parent=t,e)))}shouldProceedToElementChildren(){return!0}}class ts extends v{canHandle(t,e){const n=t[e];return n&&"THEAD"===n.tagName?1:0}handle(e,n){return Ct.from({id:t(),type:"table-head",annotations:w.generate(Ct,e[0],n),children:[]},n)}appendChildBlocks(t,e){t.children=e.map((e=>(e.parent=t,e)))}shouldProceedToElementChildren(){return!0}}class es extends v{canHandle(t,e){const n=t[e];return n&&"TBODY"===n.tagName?1:0}handle(e,n){return xt.from({id:t(),type:"table-body",annotations:w.generate(xt,e[0],n),children:[]},n)}appendChildBlocks(t,e){t.children=e.map((e=>(e.parent=t,e)))}shouldProceedToElementChildren(){return!0}}class ns extends v{canHandle(t,e){const n=t[e];return n&&"TR"===n.tagName?1:0}handle(e,n){return Vt.from({id:t(),type:"table-row",annotations:w.generate(Vt,e[0],n),children:[]},n)}appendChildBlocks(t,e){t.children=e.map((e=>(e.parent=t,e)))}shouldProceedToElementChildren(){return!0}}class ss extends v{canHandle(t,e){const n=t[e];return!n||"TD"!==n.tagName&&"TH"!==n.tagName?0:1}handle(e,n){const s=e[0],o=[{id:t(),type:"paragraph",annotations:{internalWrapper:n&&!n.autoMatchFormat},nodes:[{id:t(),type:"text",annotations:{plainText:n&&!n.autoMatchFormat},text:""}]}];return"TH"===s.tagName?bt.from({id:t(),type:"table-head-cell",annotations:this.getTableHeadCellAnnotations(s,n),children:o},n):vt.from({id:t(),type:"table-cell",annotations:w.generate(bt,s,n),children:o},n)}appendChildBlocks(t,e){t.children=e.map((e=>(e.parent=t,e)))}shouldProceedToElementChildren(){return!0}getTableHeadCellAnnotations(t,e){const n=w.generate(vt,t,e);return n&&n.tableCell&&wt.getColorKey(n.tableCell.backgroundColor,!0)===at.key&&(delete n.tableCell.backgroundColor,n.customStyle&&delete n.customStyle.backgroundColor),n}}class os extends C{canHandle(t,e){const n=t[e];return n&&n.parentElement&&"TABLE"===n.parentElement.tagName&&"CAPTION"===n.tagName?1:0}handle(e,n){return RTETableCaptionBlock.from({id:t(),type:"table-caption",annotations:this.getTableCaptionAnnotations(e[0],n),children:[]},n)}appendChildBlocks(t,e){t.children=e.map((e=>(e.parent=t,e)))}shouldProceedToElementChildren(){return!0}getTableCaptionAnnotations(t,e){const n=w.generate(RTETableCaptionBlock,t,e);return n&&n.customStyle&&n.customStyle.backgroundColor&&wt.getColorKey(n.customStyle.backgroundColor,!0)===at.key&&delete n.customStyle.backgroundColor,n}}class is extends k{getBackgroundColor(t){return t.style.backgroundColor?wt.getColorKey(t.style.backgroundColor)||t.style.backgroundColor:null}getBorder(t){const e=t.style,n=e.borderStyle,s=e.borderWidth,o=e.borderColor;if(o||n||s){const t="initial"===o?"":o;return{style:"initial"===n?"":n,width:"initial"===s?"":s,color:wt.getColorKey(t)||t}}return null}getWidth(t){if(t.style.width)return t.style.width;const e=t.getAttribute("width");return e?/^\d+$/.test(e)?`${e}px`:e:null}getHeight(t){if(t.style.height)return t.style.height;const e=t.getAttribute("height");return e?/^\d+$/.test(e)?`${e}px`:e:null}}class rs extends is{canHandle(t){return"RTETableBlock"===t.name}handle(t){const e=ce({backgroundColor:this.getBackgroundColor(t),border:this.getBorder(t),width:this.getWidth(t),height:this.getHeight(t),alignment:this.getAlignment(t)});return Object.keys(e).length>0?{table:e}:{}}getAlignment(t){const e=t.classList;if(e.contains("v-rte--extension-table-align-left"))return"left";if(e.contains("v-rte--extension-table-align-center"))return"center";if(e.contains("v-rte--extension-table-align-right"))return"right";const n=t.style,s=n.marginLeft,o=n.marginRight;if("auto"===s&&"auto"===o)return"center";if("0"===s||"0px"===s)return"left";if("0"===o||"0px"===o)return"right";const i=t.getAttribute("align");return i&&["left","center","right"].includes(i)?i:null}}class as extends is{canHandle(t){return"RTETableCellBlock"===t.name}handle(t){const e=ce({backgroundColor:this.getBackgroundColor(t),padding:this.getPadding(t),border:this.getBorder(t),width:this.getWidth(t),height:this.getHeight(t),textAlign:this.getTextAlign(t),verticalAlign:this.getVerticalAlign(t),minWidth:this.getMinWidth(t),boxSizing:this.getBoxSizing(t)});return Object.keys(e).length>0?{tableCell:e}:{}}getMinWidth(t){return t.style.minWidth?t.style.minWidth:null}getBoxSizing(t){return t.style.boxSizing?t.style.boxSizing:null}getPadding(t){return t.style.padding?t.style.padding:null}getTextAlign(t){if(t.style.textAlign){const e=t.style.textAlign;if(["left","center","right","justify"].includes(e))return e}const e=t.getAttribute("align");return e&&["left","center","right","justify"].includes(e)?e:null}getVerticalAlign(t){if(t.style.verticalAlign){const e=t.style.verticalAlign;if(["top","middle","bottom"].includes(e))return e}return null}}class ls extends as{canHandle(t){return"RTETableHeadCellBlock"===t.name}}class cs extends D{handleAction(t,e){const n=t.toAnnotation(),s=this.getDOMByEntity(e);if(s){const t=s.closest(".v-rte--extension-table-container"),{backgroundColorAnnotation:o,width:i,height:r}=n;s.style.backgroundColor=o.renderStyle().color,s.style.border=n.borderStr,s.style.width=i,s.style.height=r;const a=n.renderAlignmentStyle().margin;s.style.margin=a,t&&(t.style.width=i,t.style.height=r,t.style.margin=a),this.updateCustomStyleAnnotation(e,["backgroundColor","border","width","height","margin"])}}}class hs extends D{handleAction(t,e){const n=t.toAnnotation(),s=this.getDOMByEntity(e);if(s){const{width:t,height:o,borderStr:i,padding:r,textAlign:a,verticalAlign:l}=n,c=n.renderStyle().backgroundColor||"";s.style.backgroundColor=c,s.style.border=i,s.style.width=t,s.style.height=o,s.style.padding=r,s.style.textAlign=a,s.style.verticalAlign=l,this.updateCustomStyleAnnotation(e,["backgroundColor","border","width","height","padding","textAlign","verticalAlign"])}}}class ds extends D{handleAction(t,e){const n=e.parent,s=n.parent,o=Tt(n,yt),i=kt(o),r=i.indexOf(n),{colSpan:a,rowSpan:l}=_t(e),c=Pt(e,i),h=Math.ceil(l/2),d=Math.max(1,l-h),u=1===l;Rt(e,a,h,o);const p=r+h,f=Mt(e.type);if(Rt(f,a,d,o),u){const t=this.createNewRowWithCell(s,f),r=s.children.indexOf(n);s.apply(new V(s.children[r],t)),i.splice(p,0,t),this.updateCellsSpanningThroughInsertionPoint(i,p,e,o)}else{const t=i[p],e=this.findInsertPosition(t,c,i,p);t.children.splice(e,0,f),f.parent=t}}findInsertPosition(t,e,n,s){let o=0;for(let t=0;t<s;t++){const i=n[t];for(const r of i.children){const{colSpan:i,rowSpan:a}=_t(r);t+a>s&&Pt(r,n)<e&&(o+=i)}}let i=o;for(let n=0;n<t.children.length;n++){if(i>=e)return n;const s=t.children[n],{colSpan:o}=_t(s);i+=o}return t.children.length}createNewRowWithCell(e,n){const s={id:t(),type:"table-row",children:[]},o=Vt.from(s);return o.parent=e,o.children.push(n),n.parent=o,o}updateCellsSpanningThroughInsertionPoint(t,e,n,s){for(let o=0;o<e;o++){const i=t[o];for(const t of i.children){if(t===n)continue;const{colSpan:i,rowSpan:r}=_t(t);o+r>=e&&Rt(t,i,r+1,s)}}}}class us extends D{handleAction(t,e){const n=e.parent,s=Tt(n,yt),o=kt(s),i=o.indexOf(n),{colSpan:r,rowSpan:a}=_t(e),l=Pt(e,o),c=l+r-1,h=Math.ceil(r/2),d=Math.floor(r/2);Rt(e,h,a,s);const u=Mt(e.type);Rt(u,d,a,s),n.apply(new V(e,u));const p=1===r?1:0;p>0&&this.updateOtherRowsCells(o,i,l,c,a,p,s)}updateOtherRowsCells(t,e,n,s,o,i,r){for(let a=0;a<t.length;a++){const l=t[a];if(!(a>=e&&a<e+o))for(const e of l.children){const o=Pt(e,t),{colSpan:a,rowSpan:l}=_t(e);if(o+a-1>=n&&o<=s){Rt(e,a+i,l,r);break}}}}}class ps extends Hn{handleAction(e,n){const{selectedRows:s}=e,o=s[s.length-1];let i=n.children.find((t=>t instanceof xt));const r={id:t(),type:"table-row",children:[]};let a=0,l=null;i?(l=i.children[0],a=this.getHeadCellLength(l)):(i=xt.from({id:t(),type:"table-body",children:[]}),n.apply(new P([i])));const c=o.parent.children,h=this.getRowsMaxCellCount(c);if(this.getRowsMaxCellCount([o])<h){const t=c.indexOf(o),e=this.getRowCellStartCols(c),n=new Map;for(let s=0;s<h;s++){const o=s<a?"table-head-cell":"table-cell",{cell:i}=this.getTheStartSpanCell(c,e,t,s);if(i){const t=i.colSpan;n.set(s,this.getDefaultCellBlockTemplate(o,t)),s+=t-1}}r.children=this.getSortedValuesByNumericKey(n)}else r.children=this.createTableCells(o,a);const d=l?new F(l,Vt.from(r)):new P([Vt.from(r)]);i.apply(d)}createTableCells(t,e){const n=[];let s=0;for(const o of t.children)n.push(this.getDefaultCellBlockTemplate(s<e?"table-head-cell":"table-cell",o.colSpan)),s+=o.colSpan;return n}}class fs extends Hn{handleAction(e){const{insertDirection:n,selectedRows:s}=e,o=n===Ht.ABOVE?s[0]:s[s.length-1],i={id:t(),type:"table-row",children:[]},r=o.parent.children,a=this.getRowsMaxCellCount(r),l=r.indexOf(o),c=this.getRowCellStartCols(r),h=new Map;for(let t=0;t<a;t++){const{cell:e,rowIndex:s}=this.getTheStartSpanCell(r,c,l,t);if(e){const{colSpan:o,rowSpan:i}=e;if(n===Ht.ABOVE?s!==l:s+i>l+1){this.updateCellSpan(e,"rowspan",i+1),t+=o-1;continue}h.set(t,this.getDefaultCellBlockTemplate(e.type,o)),t+=o-1}}i.children=this.getSortedValuesByNumericKey(h);const d=Vt.from(i),u=n===Ht.ABOVE?new F(o,d):new V(o,d);o.parent.apply(u)}}class gs extends Xe{canIntercept(t,e){return Boolean(e.parent)}intercept(t,e,n){const s=this.createNewParagraph("");s&&(n.parent.apply(0===e.startOffset?new F(n,s):new V(n,s)),e.newBlock=s)}createNewParagraph(e){const n=L.getRTEBlockClass("paragraph");if(n)return n.from({id:t(),type:"paragraph",nodes:[{id:t(),type:"text",text:e}]})}}class bs extends De{constructor(t=Ft){super(),this.toolbarButtonRenderer=new Nn,this.tableBlockRenderer=new kn,this.tableRowBlockRenderer=new Rn,this.tableCellRenderer=new On,this.tableHeadCellRenderer=new Ln,this.tableSelection=new Kn,wt.setTableColors(t),this.registerToolbarButtonRenderer("table",this.toolbarButtonRenderer),this.registerBlockBasicStrategies(yt.name),this.registerBlockBasicStrategies(Ct.name),this.registerBlockBasicStrategies(bt.name),this.registerBlockBasicStrategies(Vt.name),this.registerBlockBasicStrategies(vt.name),this.registerBlockBasicStrategies(xt.name),this.registerRenderer("table-block",this.tableBlockRenderer),this.registerRenderer("table-head",new An),this.registerRenderer("table-head-cell",this.tableHeadCellRenderer),this.registerRenderer("table-row",this.tableRowBlockRenderer),this.registerRenderer("table-cell",this.tableCellRenderer),this.registerRenderer("table-body",new In),this.registerRenderer("table-caption",new Pn),this.registerNode("table-block",yt),this.registerNode("table-head",Ct),this.registerNode("table-head-cell",bt),this.registerNode("table-row",Vt),this.registerNode("table-cell",vt),this.registerNode("table-body",xt),this.registerNode("table-caption",RTETableCaptionBlock),this.registerElementToBlockDTOClassStrategy(new Yn),this.registerElementToBlockDTOClassStrategy(new ts),this.registerElementToBlockDTOClassStrategy(new es),this.registerElementToBlockDTOClassStrategy(new ns),this.registerElementToBlockDTOClassStrategy(new ss),this.registerElementToBlockDTOClassStrategy(new os),this.registerAnnotationHandler(new rs),this.registerAnnotationHandler(new as),this.registerAnnotationHandler(new ls)}initialExtension(t){this.tableSelection.init(t);const e=Object.assign(Object.assign({},t),{tableSelection:this.tableSelection});super.initialExtension(e)}destroyExtension(){this.tableSelection.destroy()}}(()=>{const t=new _n,e=new Dn;De.registerActionHandleStrategy(m.name,"INSERT_TABLE_BLOCK",t),De.registerActionHandleStrategy(m.name,"DELETE_TABLE_BLOCK",e),De.registerActionHandleStrategy(vt.name,"DELETE_TABLE_BLOCK",e),De.registerActionHandleStrategy(bt.name,"DELETE_TABLE_BLOCK",e),De.registerActionHandleStrategy(_.name,"INSERT_TABLE_BLOCK",t),De.registerActionHandleStrategy(T.name,"INSERT_TABLE_BLOCK",t),De.registerActionHandleStrategy(yt.name,Kt,new ps),De.registerActionHandleStrategy(yt.name,$t,new fs),De.registerActionHandleStrategy(yt.name,zt,new Fn),De.registerActionHandleStrategy(yt.name,Wt,new $n),De.registerActionHandleStrategy(yt.name,Gt,new zn),De.registerActionHandleStrategy(yt.name,Ut,new Wn),De.registerActionHandleStrategy(yt.name,Zt,new Jt),De.registerActionHandleStrategy(Vt.name,Xt,new Jn),De.registerActionHandleStrategy(Vt.name,"CREATE_SEGMENT_TABLE_CELL",new Un),De.registerActionHandleStrategy(Vt.name,qt,new Zn),De.registerActionHandleStrategy(vt.name,Qt,new ds),De.registerActionHandleStrategy(vt.name,Yt,new us),De.registerActionHandleStrategy(bt.name,Qt,new ds),De.registerActionHandleStrategy(bt.name,Yt,new us),De.registerActionHandleStrategy(yt.name,te,new Xn),De.registerActionHandleStrategy(yt.name,ee,new Qn),De.registerActionHandleStrategy(yt.name,fn.name,new cs),De.registerActionHandleStrategy(vt.name,yn.name,new hs),De.registerActionHandleStrategy(bt.name,mn.name,new hs),De.registerActionHandlerInterceptor(_.name,$.DELETE_BLOCK_CONTENT,new Mn),De.registerActionHandlerInterceptor(Vt.name,$.INSERT_CHILDREN_BEFORE,new qn),De.registerActionHandlerInterceptor(vt.name,$.DELETE_CHILDREN,new Vn),De.registerActionHandlerInterceptor(bt.name,$.DELETE_CHILDREN,new Vn),De.registerActionHandlerInterceptor(yt.name,$.INSERT_NEW_PARAGRAPH,new gs)})();class ws extends B{constructor(t,e){super(),this.type=$.INSERT_NODE_TO_NEAREST_ROOT,this.rteRange=t,this.nodeToBeInserted=e}}class ys extends D{handleAction(e,n){const{rteRange:s,token:o}=e;if(s&&s.startNode){const{key:i,label:r,customAttrs:a={wrapped:"true"}}=o,l=new RTETokenNode(t(),i,r,n);l.annotationMap.set("CUSTOM_ATTRIBUTE",new Z(a)),n.apply(new ws(s,l)),e.actionHandleResult=!0}}}const ms=new class extends C{canHandle(t,e){const n=t[e];return"SPAN"===n.nodeName&&n.classList.contains("token")&&n.hasAttribute("token-key")?1:0}handle(e){const n=e[0],s=n.getAttribute("token-key"),o=n.textContent,i=w.generate(j,n),{customAttribute:r}=i,a=function(t,e){var n={};for(var s in t)Object.prototype.hasOwnProperty.call(t,s)&&e.indexOf(s)<0&&(n[s]=t[s]);if(null!=t&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(s=Object.getOwnPropertySymbols(t);o<s.length;o++)e.indexOf(s[o])<0&&Object.prototype.propertyIsEnumerable.call(t,s[o])&&(n[s[o]]=t[s[o]])}return n}(i,["customAttribute","customClass"]);return{id:t(),type:"token",token:s,text:o,annotations:Object.assign(Object.assign({},a),{customAttribute:this.createCustomAttrs(r)})}}appendChildBlocks(){}shouldProceedToElementChildren(){return!1}createCustomAttrs(t){const e=Object.assign(Object.assign({},t),{contenteditable:null,"template-token-key":null,"token-key":null,wrapped:"false"===t.wrapped?"false":"true"});return ce(e)}};class vs extends De{constructor(t=[]){super(),this.tokenRenderer=new Fe,this.registerNode("token",RTETokenNode),this.registerRenderer("token",this.tokenRenderer),this.tokenToolbarButtonRenderer=new He(t),this.registerToolbarButtonRenderer("token",this.tokenToolbarButtonRenderer),this.registerElementToNodeDTOClassStrategy(ms)}}(()=>{const t=new ys;De.registerActionHandleStrategy(_.name,"INSERT_TOKEN_NODE",t),De.registerActionHandleStrategy(A.name,"INSERT_TOKEN_NODE",t)})();export{Xe as A,ws as I,He as R,fe as V,ye as a,Ce as b,Ee as c,Le as d,Ne as e,vs as f,$e as g,rn as h,bs as i,De as j,Me as k,Ve as l,RTETokenNode as m,Fe as n,Ke as o,Re as w}
1
+ import{g as t}from"./p-8b5d3a52.js";import{a as e,g as n,D as s,f as o,r as i}from"./p-dcd18ab1.js";import{L as r,I as a}from"./p-6e1ab235.js";import{I as l,c}from"./p-593e0f80.js";import{I as h}from"./p-781fd6e0.js";import{c as d}from"./p-6a334573.js";import{P as u}from"./p-81dd00d0.js";import{i as p}from"./p-3d2d267d.js";import{V as f}from"./p-82016096.js";import{R as g,E as b,h as w,U as y,V as m,B as v,a as C,I as x,b as T,c as E,P as S,A as k,d as A}from"./p-559197f8.js";import{s as R,A as O,a as I,R as L,M as B,b as j,c as N,d as _,e as M,f as D,I as V,g as P,h as H,i as F,j as K,k as $,B as z,l as W,m as G,C as U,n as Z}from"./p-68124bc5.js";import{i as J}from"./p-c6d62f0d.js";import{R as X}from"./p-fcabf0dc.js";import{V as q}from"./p-a7b5f497.js";import{V as Q}from"./p-e1fbfd20.js";import{v as Y}from"./p-4866e390.js";import{D as tt,d as et}from"./p-878851f6.js";import{V as nt,a as st,b as ot,c as it}from"./p-c5eb0fa6.js";import{R as rt,a as at,S as lt,T as ct,b as ht,C as dt,M as ut,c as pt,d as ft,e as gt,f as bt,g as wt,h as yt,i as mt,j as vt,k as Ct,l as xt,m as Tt,n as Et,o as St,p as kt,q as At,s as Rt,r as Ot,t as It,I as Lt,u as Bt,v as jt,w as Nt,x as _t,y as Mt,z as Dt,A as Vt,B as Pt,D as Ht,E as Ft,F as Kt,G as $t,H as zt,J as Wt,K as Gt,L as Ut,N as Zt,O as Jt,P as Xt,Q as qt,U as Qt,W as Yt,X as te,Y as ee}from"./p-02578a59.js";import{r as ne}from"./p-77e64f26.js";import{V as se,a as oe,b as ie}from"./p-33860e54.js";import{V as re}from"./p-8ac2d165.js";import{t as ae}from"./p-b75ee3ba.js";import{p as le}from"./p-0c667d6a.js";import{c as ce}from"./p-a841cf13.js";import{C as he}from"./p-2d0d575f.js";import{d as de}from"./p-1bc5b3bc.js";const ue=[{payloadKey:"IS_LOAD_METHOD_CALLED",payloadDescription:"Indicate if the method load of public API VegaLoaderController is called",canAccept:(t,e)=>"VegaLoaderController"===t&&"load"===e,payloadValue:()=>!0},{payloadKey:"IS_CLOSE_METHOD_CALLED",payloadDescription:"Indicate if the method close of public API VegaLoaderController is called",canAccept:(t,e)=>"VegaLoaderController"===t&&"close"===e,payloadValue:()=>!0}];class pe{constructor(){this.vegaPublicAPIRuntimeMetricsSlimmer=c(pe,["load","close"],ue)}load(t={}){let e=t.containerSelector||"body",n=document.querySelector(e);if(n&&pe.SPECIAL_ELEMENT_TO_WRAP_FULL_BODY.includes(n.tagName)&&(e="body",n=document.querySelector("body")),!n)return r.error("Container is not found by selector: ",e),null;const s=this.createLoadingIndicator(t.indicatorOptions),o=this.createLoader(e);return o.append(s),this.appendLoader(o,n)}close(t){const e=this.findLoader(t);if(e){if(e.dataset.container){const t=document.querySelector(e.dataset.container);t&&t.dataset.vegaLoaderOriginPosition&&(t.style.position=t.dataset.vegaLoaderOriginPosition)}e.remove()}}findLoader(t){var e,n;let s;if(t.includes(">>>")){const[o,i]=t.split(">>>");s=null===(n=null===(e=document.querySelector(o))||void 0===e?void 0:e.shadowRoot)||void 0===n?void 0:n.getElementById(i)}else s=document.getElementById(t);return s}createLoader(n){const s=document.createElement("vega-loader-wrapper");return s.className=e(["body"===n?"fixed-wrapper":"absolute-wrapper"]),s.dataset.container=n,s.id=`vega-loader-${t()}`,s}createLoadingIndicator(t={}){const e=document.createElement("vega-loading-indicator");return Object.assign(e,t),e}appendLoader(t,e){return e.dataset.vegaLoaderOriginPosition=e.style.position,e.style.position="relative",e.shadowRoot?(e.shadowRoot.append(t),`${t.dataset.container}>>>${t.id}`):(e.append(t),t.id)}}pe.SPECIAL_ELEMENT_TO_WRAP_FULL_BODY=["VEGA-MODAL"],function(t,e,n,s){var o,i=arguments.length,r=i<3?e:null===s?s=Object.getOwnPropertyDescriptor(e,n):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)r=Reflect.decorate(t,e,n,s);else for(var a=t.length-1;a>=0;a--)(o=t[a])&&(r=(i<3?o(r):i>3?o(e,n,r):o(e,n))||r);i>3&&r&&Object.defineProperty(e,n,r)}([l()],pe.prototype,"vegaPublicAPIRuntimeMetricsSlimmer",void 0);const fe=new pe,ge=[{payloadKey:"IS_OPEN_METHOD_CALLED",payloadDescription:"Indicate if the method open of public API VegaNotifyController is called",canAccept:(t,e)=>"VegaNotifyController"===t&&"open"===e,payloadValue:()=>!0},{payloadKey:"IS_CLOSE_METHOD_CALLED",payloadDescription:"Indicate if the method close of public API VegaNotifyController is called",canAccept:(t,e)=>"VegaNotifyController"===t&&"close"===e,payloadValue:()=>!0},{payloadKey:"IS_CLOSEALL_METHOD_CALLED",payloadDescription:"Indicate if the method closeAll of public API VegaNotifyController is called",canAccept:(t,e)=>"VegaNotifyController"===t&&"closeAll"===e,payloadValue:()=>!0}];var be=function(t,e,n,s){var o,i=arguments.length,r=i<3?e:null===s?s=Object.getOwnPropertyDescriptor(e,n):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)r=Reflect.decorate(t,e,n,s);else for(var a=t.length-1;a>=0;a--)(o=t[a])&&(r=(i<3?o(r):i>3?o(e,n,r):o(e,n))||r);return i>3&&r&&Object.defineProperty(e,n,r),r};class we{constructor(){this.resizeObserverSlimmer=d(we,u,[],[{mapFrom:"connectResizeObserver",mapTo:"connectResizeObserver"}],[{callback:t=>{var e;!(t[0].contentRect.height>0)&&(null===(e=this.container)||void 0===e?void 0:e.classList.contains("hydrated"))&&(h.removeZIndex(this.container,"top"),this.container.remove(),this.container=null)},target:()=>this.container}]),this.vegaPublicAPIRuntimeMetricsSlimmer=c(we,["open","close","closeAll"],ge)}async open(t){const e=this.createPageNotification(t);return this.getContainer().append(e),e.id}async closeAll(){this.container&&Array.from(this.container.children).forEach((t=>{t.close()}))}async close(t){await document.getElementById(t).close()}connectResizeObserver(){}createPageNotification(e){const o=document.createElement("vega-page-notification");return Object.keys(e).forEach((t=>{void 0!==e[t]&&(o[t]=e[t])})),o.style.marginBottom=n()===s.MOBILE?"12px":"16px",o.id=`vega-page-notification-${t()}`,o}getContainer(){return this.container||(this.container=document.createElement("vega-page-notification-list"),h.setZIndex(this.container,"top"),n()===s.MOBILE?this.container.classList.add("vega-page-notification-list-bottom"):this.container.classList.add("vega-page-notification-list-topRight"),document.body.append(this.container),this.connectResizeObserver()),this.container}}be([a()],we.prototype,"resizeObserverSlimmer",void 0),be([l()],we.prototype,"vegaPublicAPIRuntimeMetricsSlimmer",void 0);const ye=new we,me=[{payloadKey:"IS_SETSEMANTICS_METHOD_CALLED",payloadDescription:"Indicate if the method setSemantics of public API VegaEventManager is called",canAccept:(t,e)=>"VegaEventManager"===t&&"setSemantics"===e,payloadValue:()=>!0},{payloadKey:"IS_GETSEMANTICS_METHOD_CALLED",payloadDescription:"Indicate if the method getSemantics of public API VegaEventManager is called",canAccept:(t,e)=>"VegaEventManager"===t&&"getSemantics"===e,payloadValue:()=>!0},{payloadKey:"IS_GETENABLEDEVENTIDSBYCOMPONENT_METHOD_CALLED",payloadDescription:"Indicate if the method getEnabledEventIdsByComponent of public API VegaEventManager is called",canAccept:(t,e)=>"VegaEventManager"===t&&"getEnabledEventIdsByComponent"===e,payloadValue:()=>!0},{payloadKey:"globalEventIsNative",payloadDescription:"Indicate if the vega components will emit events without the vega prefix",canAccept:(t,e)=>"VegaEventManager"===t&&"setSemantics"===e,payloadValue:t=>!(!t.global||"native"!==t.global.namespace)},{payloadKey:"eventOfSpecificComponentsIsNative",payloadDescription:"Indicate if the vega components will emit events with the vega prefix, but special components will emit events without vega prefix",canAccept:(t,e)=>"VegaEventManager"===t&&"setSemantics"===e,payloadValue:t=>{const e=t;if(e.components){const t=Object.keys(e.components);return!!(t.length>0&&"native"===e.components[t[0]].namespace)}return!1}},{payloadKey:"eventOfSpecificComponentsIsVega",payloadDescription:"Indicate if the vega components will emit events without the vega prefix, but special components will emit events with vega prefix",canAccept:(t,e)=>"VegaEventManager"===t&&"setSemantics"===e,payloadValue:t=>{const e=t;if(e.global&&e.components){const t=Object.keys(e.components);return!!("native"===e.global.namespace&&t.length>0&&"vega"===e.components[t[0]].namespace)}return!1}},{payloadKey:"globalJqueryDelegatedEventIsTrue",payloadDescription:"Indicate if the use jQuery with event delegation",canAccept:(t,e)=>"VegaEventManager"===t&&"setSemantics"===e,payloadValue:t=>!(!t.global||!0!==t.global.jqueryDelegatedEvent)},{payloadKey:"jqueryDelegatedEventIsCustomStrategy",payloadDescription:"Indicate if the use jQuery with event delegation",canAccept:(t,e)=>"VegaEventManager"===t&&"setSemantics"===e,payloadValue:t=>{const e=t;return!!(e.global&&Array.isArray(e.global.jqueryDelegatedEvent)&&e.global.jqueryDelegatedEvent.length>0)}},{payloadKey:"jqueryDelegatedEventOfSpecialComponentsIsTrue",payloadDescription:"Indicate if the use jQuery with event delegation",canAccept:(t,e)=>"VegaEventManager"===t&&"setSemantics"===e,payloadValue:t=>{const e=t;if(e.components){const t=Object.keys(e.components);return!!(t.length>0&&!0===e.components[t[0]].jqueryDelegatedEvent)}return!1}}];class ve{constructor(){this.vegaPublicAPIRuntimeMetricsSlimmer=c(ve,["setSemantics","getSemantics","getEnabledEventIdsByComponent"],me)}setSemantics(t){p.setSemantics(t)}getSemantics(t){return p.getSemantics(t)}getEnabledEventIdsByComponent(t){return p.getEnabledEventIdsByComponent(t)}}!function(t,e,n,s){var o,i=arguments.length,r=i<3?e:null===s?s=Object.getOwnPropertyDescriptor(e,n):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)r=Reflect.decorate(t,e,n,s);else for(var a=t.length-1;a>=0;a--)(o=t[a])&&(r=(i<3?o(r):i>3?o(e,n,r):o(e,n))||r);i>3&&r&&Object.defineProperty(e,n,r)}([l()],ve.prototype,"vegaPublicAPIRuntimeMetricsSlimmer",void 0);const Ce=new ve,xe=[{payloadKey:"IS_OVERRIDEZINDEXBASICVALUES_METHOD_CALLED",payloadDescription:"Indicate if the method overrideZIndexBasicValues of public API ZIndexManager is called",canAccept:(t,e)=>"VegaZIndexManager"===t&&"overrideZIndexBasicValues"===e,payloadValue:()=>!0},{payloadKey:"zIndexBasicValuesGreatThanTenThousand",payloadDescription:"Indicate if the basic z-index value is great than ten thousand",canAccept:(t,e)=>"VegaZIndexManager"===t&&"overrideZIndexBasicValues"===e,payloadValue:t=>t.base>1e4}];class Te{constructor(){this.vegaPublicAPIRuntimeMetricsSlimmer=c(Te,["overrideZIndexBasicValues"],xe)}overrideZIndexBasicValues(t){h.overrideZIndexBasicValues(t)}}!function(t,e,n,s){var o,i=arguments.length,r=i<3?e:null===s?s=Object.getOwnPropertyDescriptor(e,n):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)r=Reflect.decorate(t,e,n,s);else for(var a=t.length-1;a>=0;a--)(o=t[a])&&(r=(i<3?o(r):i>3?o(e,n,r):o(e,n))||r);i>3&&r&&Object.defineProperty(e,n,r)}([l()],Te.prototype,"vegaPublicAPIRuntimeMetricsSlimmer",void 0);const Ee=new Te,Se=[{payloadKey:"IS_WAITFORVEGA_METHOD_CALLED",payloadDescription:"Indicate if the method waitForVega of public API WaitForVegaHandler is called",canAccept:(t,e)=>"WaitForVegaHandler"===t&&"handle"===e,payloadValue:()=>!0}];class ke{constructor(){this.vegaPublicAPIRuntimeMetricsSlimmer=c(ke,["handle"],Se)}async handle(){return await Promise.all(Array.from(document.querySelectorAll("*:not(.hydrated)")).filter((t=>t.tagName.startsWith("VEGA"))).map((t=>{var e;return null===(e=t.componentOnReady)||void 0===e?void 0:e.call(t)})))}}!function(t,e,n,s){var o,i=arguments.length,r=i<3?e:null===s?s=Object.getOwnPropertyDescriptor(e,n):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)r=Reflect.decorate(t,e,n,s);else for(var a=t.length-1;a>=0;a--)(o=t[a])&&(r=(i<3?o(r):i>3?o(e,n,r):o(e,n))||r);i>3&&r&&Object.defineProperty(e,n,r)}([l()],ke.prototype,"vegaPublicAPIRuntimeMetricsSlimmer",void 0);const Ae=new ke,Re=async()=>Ae.handle(),Oe=[{payloadKey:"IS_LOAD_METHOD_CALLED",payloadDescription:"Indicate if the method load of public API VegaSkeletonLoaderController is called",canAccept:(t,e)=>"VegaSkeletonLoaderController"===t&&"load"===e,payloadValue:()=>!0},{payloadKey:"IS_UNLOAD_METHOD_CALLED",payloadDescription:"Indicate if the method unLoad of public API VegaSkeletonLoaderController is called",canAccept:(t,e)=>"VegaSkeletonLoaderController"===t&&"unLoad"===e,payloadValue:()=>!0},{payloadKey:"IS_UNLOADALL_METHOD_CALLED",payloadDescription:"Indicate if the method unLoadAll of public API VegaSkeletonLoaderController is called",canAccept:(t,e)=>"VegaSkeletonLoaderController"===t&&"unLoadAll"===e,payloadValue:()=>!0}];class Ie{constructor(){this.vegaPublicAPIRuntimeMetricsSlimmer=c(Ie,["load","unLoad","unLoadAll"],Oe),this.loaderMap=new Map}load({target:e,type:n="text",width:s,height:o,items:i,layout:r}){const a=Array.from(document.body.querySelectorAll(e)),l=`vega-skeleton-loader-${t()}`,c=[];return a.forEach((t=>{const e=i?i.map(this.createSkeleton):[this.createSkeleton({type:n,width:s,height:o})],a=(r?[this.wrapLayout(e,r)]:e).map((t=>(t.dataset[Ie.LOADER_DATA_SET_KEY]=l,t)));c.push(...a),t.append(...a)})),this.loaderMap.set(l,c),l}unLoad(t){this.loaderMap.has(t)&&(this.loaderMap.get(t).forEach((t=>t.remove())),this.loaderMap.delete(t))}unLoadAll(){for(const t of this.loaderMap.values())t.forEach((t=>t.remove()));this.loaderMap.clear()}createSkeleton(t){const{type:e,width:n,height:s}=t,o=document.createElement("vega-skeleton");return Object.assign(o,{animated:!0,type:e,width:n,height:s}),o}wrapLayout(t,e){const n=document.createElement("vega-flex");return Object.assign(n,Object.assign({className:"vega-skeleton-loader-template-container"},e.props)),Object.assign(n.style,e.style),n.append(...t),n}}Ie.LOADER_DATA_SET_KEY="vegaSkeletonLoaderKey",function(t,e,n,s){var o,i=arguments.length,r=i<3?e:null===s?s=Object.getOwnPropertyDescriptor(e,n):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)r=Reflect.decorate(t,e,n,s);else for(var a=t.length-1;a>=0;a--)(o=t[a])&&(r=(i<3?o(r):i>3?o(e,n,r):o(e,n))||r);i>3&&r&&Object.defineProperty(e,n,r)}([l()],Ie.prototype,"vegaPublicAPIRuntimeMetricsSlimmer",void 0);const Le=new Ie,Be=[{payloadKey:"IS_INIT_METHOD_CALLED",payloadDescription:"Indicate if the method load of public API VegaTranslation.init is called",canAccept:(t,e)=>"TranslationController"===t&&"init"===e,payloadValue:()=>!0},{payloadKey:"IS_CHANGE_LANGUAGE_METHOD_CALLED",payloadDescription:"Indicate if the method load of public API VegaTranslation.changeLanguage is called",canAccept:(t,e)=>"TranslationController"===t&&"changeLanguage"===e,payloadValue:()=>!0}];class je{constructor(){this.vegaPublicAPIRuntimeMetricsSlimmer=c(je,["init","changeLanguage"],Be)}get currentLanguage(){return f.currentLanguage}init(t){f.init(t)}changeLanguage(t){f.changeLanguage(t)}}!function(t,e,n,s){var o,i=arguments.length,r=i<3?e:null===s?s=Object.getOwnPropertyDescriptor(e,n):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)r=Reflect.decorate(t,e,n,s);else for(var a=t.length-1;a>=0;a--)(o=t[a])&&(r=(i<3?o(r):i>3?o(e,n,r):o(e,n))||r);i>3&&r&&Object.defineProperty(e,n,r)}([l()],je.prototype,"vegaPublicAPIRuntimeMetricsSlimmer",void 0);const Ne=new je,_e=new class{constructor(){this.extensionContextMap=new WeakMap}setExtensionContext(t){t&&t.host&&this.extensionContextMap.set(t.host,t)}getExtensionContext(t){return t?this.extensionContextMap.get(t):null}};class Me extends q{injectRTEScopeStyles(){return""}render(t,e,n){var s;const o=this.doRender(n,t,e);return this.fallbackRegisterRef(o,t),this.appendChildren((null===(s=o.childrenContainerGetter)||void 0===s?void 0:s.call(o))||o,t,e,n),o}useRef(t){return t[Me.REGISTER_REF_FLAG]=!0,function(e){e&&R.register(e,t)}}getDTORenderer(t){return X.getRTERenderer(t)}getExtensionContext(t){return _e.getExtensionContext(t)}appendChildren(t,e,n,s){Array.isArray(e.children)&&e.children.length&&!t.t&&(t.t=e.children.map((t=>this.renderChildren(t,n,s))).filter(J))}renderChildren(t,e,n){const s=this.getDTORenderer(t.type);if(s)return s.render(t,e,n)}fallbackRegisterRef(t,e){e[Me.REGISTER_REF_FLAG]||!t.o||t.o.ref||(t.o.ref=this.useRef(e))}}Me.REGISTER_REF_FLAG="__registeredRef__";class De{constructor(){this.extensionContext=null,this.hasCustomStylesRenderers=new Set}static registerActionHandleStrategy(t,e,n){O.register(e,t,n)}static registerActionHandlerInterceptor(t,e,n){I.register(e,t,n)}initialExtension(t){this.extensionContext=t,_e.setExtensionContext(t)}destroyExtension(){}collectExtensionRendererStyles(){let t="";return this.hasCustomStylesRenderers.size>0&&this.hasCustomStylesRenderers.forEach((e=>{t+=`${e.injectRTEScopeStyles()}\n`})),t}registerNode(t,e){L.registerRTEDTOClass(t,e)}registerRenderer(t,e){X.registerRTEDTORenderer(t,e),e instanceof Me&&e.injectRTEScopeStyles()&&this.hasCustomStylesRenderers.add(e)}registerToolbarButtonRenderer(t,e){X.registerRTEToolbarButtonRenderer(t,e)}registerBlockBasicStrategies(t){g.registerBlockBasicStrategies(t)}unRegisterStrategy(t,e){O.unregister(t,e)}unRegisterInterceptor(t,e,n){I.unregister(t,e,n)}registerElementToBlockDTOClassStrategy(t){b.registerElementToBlockStrategy(t)}registerElementToNodeDTOClassStrategy(t){b.registerElementToNodeStrategy(t)}getElementToNodeDTOClassStrategies(){return b.getElementToNodeStrategies()}registerAnnotationHandler(t){w.registerHandler(t)}}class Ve{isHidden(t){return t.sourceEditMode}getExtensionContext(t){return _e.getExtensionContext(t)}renderDropdown(t,e,n,s){return t("vega-dropdown",Object.assign({trigger:"click",searchable:!1,maxWidth:"200",itemDisplayRule:"ellipsis",ref:t=>{tt.addUniqueObserverToNode(t,nt,(t=>{this.handleDropdownClick(t.detail,e)}))}},n),s)}renderDropdownListTemplate(t,e){return t("div",{slot:"items",onMouseDown:this.preventDefault,class:"rte-dropdown-list"},[t("style",{nonce:Y.nonce},".rte-dropdown-list vega-dropdown-group vega-dropdown-group { padding-left: 4px }"),...e.map((e=>"children"in e?this.renderDropdownGroup(t,e):this.renderDropdownItem(t,e)))])}renderDropdownItem(t,e){return t("vega-dropdown-item",{key:e.key,itemKey:e.key,label:e.label,prefixIcon:e.icon})}renderDropdownGroup(t,e){return t("vega-dropdown-group",{key:e.key,label:e.label,divide:!1},e.children.map((e=>"children"in e?this.renderDropdownGroup(t,e):this.renderDropdownItem(t,e))))}renderButton(t,e,n){const{icon:s,label:o,showArrowIcon:i}=n,r=this.isDisabled(e);return t("vega-rich-text-editor-toolbar-button",{disabled:r,icon:s,hidden:this.isHidden(e),selected:this.isSelected(e),ref:t=>{tt.addUniqueObserverToNode(t,st,(()=>this.handleButtonClick(e)))},onMouseDown:this.preventDefault},[this.renderButtonLabel(t,e,o),i?t("vega-icon",{size:"size-8",color:r?"text-disabled":"text-secondary",style:{marginLeft:"8px"},icon:Q.getIconKey("chevron-down")}):null].filter(J))}renderButtonLabel(t,e,n){return n?t("vega-font",{variant:"font-field-label-sm",color:this.isDisabled(e)?"text-disabled":"text-primary"},n):null}isDisabled(t){return t.host.disabled}isSelected(t){return!1}preventDefault(t){t.preventDefault()}getListItemByKey(t,e){for(const n of t)if("children"in n){const t=this.getListItemByKey(n.children,e);if(t)return t}else if(n.key===e)return n;return null}}class Pe extends B{constructor(t,e){super(),this.type="INSERT_TOKEN_NODE",this.rteRange=null,this.actionHandleResult=!1,this.rteRange=t,this.token=e}}class He extends Ve{constructor(t){super(),this.tokenList=[],this.tokenList=t}render(t,e){return this.renderDropdown(t,e,{},[this.renderButton(t,e,{label:"Tokens",showArrowIcon:!0}),this.renderDropdownListTemplate(t,this.tokenList)])}isDisabled(t){const e=this.getExtensionContext(t.host);if(e){const{host:t,getSelectedNodes:n}=e,[s]=n();return s?t.disabled||!O.canHandle("INSERT_TOKEN_NODE",s.parent):t.disabled}return!1}handleButtonClick(t){}handleDropdownClick(t,e){const n=this.getListItemByKey(this.tokenList,t),{rteRange:s}=e,{startNode:o}=s;if(o&&o.parent){const t=new Pe(s,n);o.parent.apply(t),t.actionHandleResult&&this.flushEditorUI(e)}}flushEditorUI(t){const e=this.getExtensionContext(t.host);if(e){const{host:t,flushValue:n}=e;n(t.value)}}}class RTETokenNode extends j{constructor(t,e,n,s,o){super(t,n,s,o),this.type="token",this.token=e,this.text=n}static from(t,e){const n=new RTETokenNode(t.id,t.token,t.text,e);return t.annotations&&(n.annotationMap=this.generateTextAnnotationMap(t.annotations)),n}toJSON(){const t=super.toJSON();return Object.assign({id:this.id,type:this.type,text:this.text,token:this.token},t.annotations?{annotations:t.annotations}:{})}isContentEditable(){return!1}clone(t){return new RTETokenNode(this.id,this.token,this.text,t,this.annotationMap)}toHtml(){return`<span class="token" contenteditable="false" template-token-key="${this.token}" token-key="${this.token}"${super.generateAttributeString()}>${this.text}</span>`}}class Fe extends Me{doRender(t,e,n){const{id:s,token:o}=e;return t("span",Object.assign(Object.assign({key:s,"template-token-key":o,"token-key":o,contenteditable:"false",style:e.getStyles(),class:`token ${e.getClasses()}`},this.additionalAttributes(e)),{ref:this.useRef(e),onClick:t=>{t.preventDefault(),n&&!1!==n.editable&&this.handleTokenElementClick(t,e,n.host)}}),e.text)}injectRTEScopeStyles(){return"span[token-key]{padding: 0 2px; margin: 0 1px; background-color: rgba(var(--v-bg-status-info, 205,209,211))}"}handleTokenElementClick(t,e,n){t.preventDefault(),n&&n.value.apply(new y(e,void 0,!0))}additionalAttributes(t){const e=t.getCustomAttributesAnnotation();let n={wrapped:"true"};return e&&(n=Object.assign(Object.assign({},n),e.render())),n}}class Ke extends Ve{constructor(t,e,n){super(),this.languageList=[],this.selectedLanguage="Select Language",this.labelRef=null,this.handleDropdownClick=t=>{this.setSelectedLanguage(t),"function"==typeof this.languageChangeCallback&&this.languageChangeCallback(this.selectedLanguage)},this.languageList=t,this.selectedLanguage=n,this.languageChangeCallback=e}setSelectedLanguage(t){this.selectedLanguage=t,this.labelRef&&(this.labelRef.textContent=this.getLanguageLabelByKey(t))}isHidden(){return!1}render(t,e){return this.renderDropdown(t,e,{source:this.languageList},[this.renderButton(t,e,{label:this.getLanguageLabelByKey(this.selectedLanguage),showArrowIcon:!0})])}renderButtonLabel(t,e,n){return t("vega-font",{variant:"font-field-label-sm",color:this.isDisabled(e)?"text-disabled":"text-primary",ref:t=>this.labelRef=t},n)}handleButtonClick(t){}getLanguageLabelByKey(t){return this.getListItemByKey(this.languageList,t).label}}class $e extends De{constructor(t,e){super(),this.languageState={selectedLanguage:"",contentMap:{}},this.languageChangeCallBack=t=>{const e=this.languageState.selectedLanguage;this.extensionContext&&e&&(this.languageState.contentMap[e]=this.getRTELatestValue(this.extensionContext.host)),this.languageState.selectedLanguage=t,this.applyLanguageContent(t,this.languageState.contentMap)},e&&(this.languageState=Object.assign(Object.assign({},this.languageState),e)),!this.languageState.selectedLanguage&&t.length>0&&(this.languageState.selectedLanguage=t[0].key),this.languageToolbarButtonRenderer=new Ke(t,this.languageChangeCallBack,this.languageState.selectedLanguage),this.registerToolbarButtonRenderer("languages",this.languageToolbarButtonRenderer)}initialExtension(t){super.initialExtension(t);const{selectedLanguage:e,contentMap:n}=this.languageState;n&&n[e]&&this.applyLanguageContent(this.languageState.selectedLanguage,this.languageState.contentMap)}setState(t){const{selectedLanguage:e,contentMap:n}=t;this.languageToolbarButtonRenderer.setSelectedLanguage(e),this.languageState.selectedLanguage=e,this.languageState.contentMap=Object.assign({},n),this.applyLanguageContent(e,n)}getState(){const{selectedLanguage:t,contentMap:e}=this.languageState;return this.extensionContext&&(e[t]=this.getRTELatestValue(this.extensionContext.host)),this.languageState}applyLanguageContent(t,e){if(this.extensionContext&&e){let n=e[t];const{host:s,flushValue:o}=this.extensionContext;n=n?n instanceof m?n:m.fromJSON(n,s.sourceEditConfig):m.createEmptyContent(),s.value!==n&&o(n,!0)}}getRTELatestValue(t){let e=t.value;if(this.extensionContext&&this.extensionContext.isSourceEditMode()&&t.shadowRoot){const n=t.shadowRoot.querySelector(".source-view-container vega-code-block");n&&(e=m.fromHtml(n.value.code,{autoMatchFormat:t.sourceEditConfig.autoMatchFormat}))}return e}}class ze extends B{constructor(t){super(),this.type="INSERT_FUNCTION_BLOCK",this.functionType=t}}class RTEFunctionBlock extends N{constructor(t){super(t),this.type="function-block",this.children=[]}static from(t,e){const n=new RTEFunctionBlock(t.id),s={customClass:["statement"]};let{annotations:o}=t;return o=o?Object.assign(Object.assign({},o),s):s,super.convertAnnotationsToMap(n.annotationMap,o),n.children=this.generateBlockChildren(t.children,e,n),n}toHtml(){return`<div class="statement">${this.children.map((t=>t instanceof _?`<div class="statementelement"${this.getFunctionContentStyle(t)}>${t.getChildrenHtml()}</div>`:t.toHtml())).join("")}</div>`}clone(e){const n=new RTEFunctionBlock(t());return n.parent=e,n.children=this.children.map((t=>t.clone(n))),n.annotationMap=super.cloneAnnotations(),n}getLastNode(){return this.children[this.children.length-1].getLastNode()}isNotEmpty(){return this.children.length>0}toJSON(){return Object.assign(Object.assign({},super.toJSON()),{id:this.id,type:this.type,children:this.children.map((t=>t.toJSON()))})}getFunctionContentStyle(t){const e=new M(t);let n=e.toCssText({standalone:!0});const s=t.getAnnotationByType("TEXT_STYLE");if(s&&"paragraph"===s.textStyle){const t=e.toCssText(void 0,void 0,s.renderStyle({standalone:!0}));n=n.replace(t,"").trim()}return n?` style="${n}"`:""}}class We extends D{handleAction(t,e){const{functionType:n}=t,s=this.getFunctionBlock(n),o=this.createNewParagraph(""),i=this.getReferenceBlock(e);i?i.parent.apply(new V(i,s,o)):e.apply(new P([s,o])),o&&(t.nextFocusNode=o.children[0])}getFunctionBlock(e){const n=t();return RTEFunctionBlock.from({id:n,type:"function-block",children:[{id:`${n}-1`,type:"logic-control-block",statementText:e.toUpperCase()},{id:`${n}-2`,annotations:{customClass:["statementelement"]},type:"paragraph",nodes:[{id:`${n}-2-1`,type:"text",text:" "}]},{id:`${n}-3`,type:"logic-control-block",statementText:"SHOW"},{id:`${n}-4`,annotations:{customClass:["statementelement"]},type:"paragraph",nodes:[{id:`${n}-4-1`,type:"text",text:" "}]}]})}getReferenceBlock(t){if(!(t instanceof m)){const e=t.parent;return e instanceof RTEFunctionBlock?e:t}}}class RTELogicControlNode extends H{constructor(t,e,n){super(t),this.type="logic-control-node",this.text="",this.text=e,this.parent=n}clone(){return new RTELogicControlNode(this.id,this.text,this.parent)}toHtml(){return this.text}toJSON(){return{id:this.id,type:this.type,text:this.text}}getRangeEndOffset(){return 1}getRangeContainer(){const t=R.getDOMByEntity(this);if(t)return t.parentElement}isContentEditable(){return!1}}class RTELogicControlBlock extends N{constructor(t,e,n){super(t),this.type="logic-control-block",this.children=[],this.statementText="",this.statementText=e,this.children=[new RTELogicControlNode(`${t}-node-1`,e,this)],n&&(this.parent=n)}static from(t){return new RTELogicControlBlock(t.id,t.statementText)}isNotEmpty(){return!0}getLastNode(){return this.children[this.children.length-1]}toHtml(){return`<div class='statementsyntax' contenteditable='false'>${this.statementText}</div>`}clone(t){return new RTELogicControlBlock(this.id,this.statementText,t)}toJSON(){return{id:this.id,type:this.type,statementText:this.statementText}}}class Ge extends Ve{render(t,e){return this.renderDropdown(t,e,{},[this.renderButton(t,e,{label:"Functions",showArrowIcon:!0}),this.renderDropdownListTemplate(t,Ge.FUNCTION_LIST)])}isDisabled(t){const e=this.getExtensionContext(t.host);if(e){const{host:t,getSelectedNodes:n}=e,s=n()[0];let o=!0;return s&&(o=O.canHandle("INSERT_FUNCTION_BLOCK",s.parent)),t.disabled||!o}return!1}handleButtonClick(){throw new Error("Method not implemented.")}handleDropdownClick(t,e){if(e){const n=this.getExtensionContext(e.host);if(n){const{host:e,getSelectedNodes:s}=n,o=s()[0],i=new ze(t);o?o.parent&&o.parent.apply(i):e.value.apply(i),i.nextFocusNode&&e.value.apply(new y(i.nextFocusNode,1))}}}}Ge.FUNCTION_LIST=[{key:"IF",label:"Conditional"},{key:"FOREACH",label:"Foreach"}];class Ue extends Me{doRender(t,e){return t("div",{key:e.id,class:"statementsyntax",ref:this.useRef(e)},t("span",{key:`${e.id}-1`,contenteditable:"false",ref:this.useRef(e.children[0])},e.statementText))}}class Ze extends v{constructor(){super(...arguments),this.blockClassName="statementsyntax"}canHandle(t,e){const n=t[e];return n&&n.nodeType===Node.ELEMENT_NODE&&n.classList.contains(this.blockClassName)&&this.isFunctionBlockChild(n)?1:0}handle(e){const n=e[0];return RTELogicControlBlock.from({id:t(),type:"logic-control-block",statementText:n.innerText})}appendChildBlocks(){}shouldProceedToElementChildren(){return!1}isFunctionBlockChild(t){return!(!t.parentElement||!t.parentElement.classList.contains("statement"))}}class Je extends Me{doRender(t,e){return t("div",{key:e.id,class:this.getElementClassName(e),ref:this.useRef(e)})}injectRTEScopeStyles(){return"div.statement{padding:2px 4px;background:rgba(var(--v-bg-accent3-secondary, 255, 239, 200));border:1px solid rgba(var(--v-bg-accent3-primary, 255, 220, 131));border-radius:4px;display:flex;flex-direction:row;justify-content:flex-start;align-items:stretch;gap:4px}div.statement .statementsyntax{padding:3px 0;line-height:22px}.rich-text-content div.statement .statementsyntax,.rich-text-content div.statement .statementelement{display:inline-block}div.statement+div.statement{margin-top:2px}div.statement .statementsyntax span{color:rgb(38, 42, 255);font-weight:bold}div.statement .statementelement{padding:2px 4px;background:rgba(var(--v-bg-secondary, 245, 247, 247));border:1px solid rgba(var(--v-border-color-input-field, 171, 198, 216));border-radius:4px;margin:0;min-width:8px}"}getElementClassName(t){let e=t.getClasses();return e.indexOf("statement")<0&&(e="statement "+e),e.trim()}}class Xe{}class qe extends Xe{canIntercept(t,e){return e.parent&&e.parent instanceof RTEFunctionBlock}intercept(t,e,n){const s=new x(n.children[0],0);s.isFlushable=!0,n.parent.apply(s)}}class Qe extends D{handleAction(t,e){const n=this.createNewParagraph("");n&&(e.parent.apply(new V(e,n)),t.newBlock=n,this.focusToNextLine(n))}focusToNextLine(t){const e=this.getRootContent(t);e&&e.apply(new y(t.children[0],1))}}class Ye extends B{constructor(t,e,n){super(),this.type="PASTE_PLAIN_TEXT",this.blocksToBeInserted=t,this.startNode=e,this.startOffset=n}}class tn extends qe{intercept(t,e,n){const{blocksToBeInserted:s,rteRange:o}=e;let{startNode:i,startOffset:r}=e;o&&(i=o.startNode,r=o.startOffset);const a=new Ye(s,i,r);n.apply(a)}}class en extends D{handleAction(t,e){const{blocksToBeInserted:n,startNode:s,startOffset:o}=t;if(s instanceof j){const t=n.flatMap((t=>t instanceof _?(this.copyLinkGroupAnnotations(e.annotationMap,t.annotationMap),t.children):[]));t.length>0&&(e.apply(o>0?new V(s,...t):new F(s,...t)),this.focusToNextLine(t[t.length-1],t[t.length-1].getRangeEndOffset()))}}focusToNextLine(t,e){const n=this.getRootContent(t);n&&n.apply(new y(t,e))}copyLinkGroupAnnotations(t,e){if(e&&e.has(K.LINK_GROUP)){const n=e.get(K.LINK_GROUP);t.has(K.LINK_GROUP)?n.linkGroups.forEach(((e,n)=>{t.get(K.LINK_GROUP).linkGroups.set(n,e)})):t.set(K.LINK_GROUP,e.get(K.LINK_GROUP))}}}const nn=new Ze,sn=new class extends Ze{constructor(){super(...arguments),this.blockClassName="statementelement"}handle(e,n){const s=w.generate(_,e[0]),o=Array.from(e[0].childNodes);return _.from({id:t(),type:"paragraph",annotations:Object.assign({customClass:[this.blockClassName]},s),nodes:this.generateChildNodes(o,void 0,n)})}},on=new class extends C{canHandle(t,e){const n=t[e];return n&&"DIV"===n.tagName&&n.classList.contains("statement")&&n.childNodes.length&&n.querySelector(".statementsyntax")?1:0}handle(){return RTEFunctionBlock.from({id:t(),type:"function-block",annotations:{customClass:["statement"]},children:[]})}appendChildBlocks(t,e){t.children=e.map((e=>(e.parent=t,e)))}shouldProceedToElementChildren(){return!0}};class rn extends De{constructor(){super(),this.toolbarButtonRenderer=new Ge,this.registerBlockBasicStrategies(RTELogicControlBlock.name),this.registerBlockBasicStrategies(RTEFunctionBlock.name),this.preventFunctionBlockDefaultInsertNewParagraph(),this.registerNode("logic-control-block",RTELogicControlBlock),this.registerRenderer("logic-control-block",new Ue),this.registerNode("function-block",RTEFunctionBlock),this.registerRenderer("function-block",new Je),this.registerToolbarButtonRenderer("functions",this.toolbarButtonRenderer),this.registerElementToBlockDTOClassStrategy(nn),this.registerElementToBlockDTOClassStrategy(sn),this.registerElementToBlockDTOClassStrategy(on)}preventFunctionBlockDefaultInsertNewParagraph(){this.unRegisterStrategy($.INSERT_NEW_PARAGRAPH,RTELogicControlBlock.name),this.unRegisterStrategy($.APPEND_CHILDREN,RTEFunctionBlock.name),this.unRegisterStrategy($.INSERT_CHILDREN_AFTER,RTEFunctionBlock.name),this.unRegisterStrategy($.INSERT_CHILDREN_BEFORE,RTEFunctionBlock.name),this.unRegisterStrategy($.PASTE_CONTENT,RTELogicControlBlock.name),De.registerActionHandleStrategy(RTEFunctionBlock.name,$.INSERT_NEW_PARAGRAPH,new Qe)}}(()=>{const t=new We;De.registerActionHandleStrategy(m.name,"INSERT_FUNCTION_BLOCK",t),De.registerActionHandleStrategy(_.name,"INSERT_FUNCTION_BLOCK",t),De.registerActionHandleStrategy(T.name,"INSERT_FUNCTION_BLOCK",t),De.registerActionHandleStrategy(RTELogicControlBlock.name,"INSERT_FUNCTION_BLOCK",t),De.registerActionHandleStrategy(_.name,"PASTE_PLAIN_TEXT",new en),De.registerActionHandlerInterceptor(_.name,$.INSERT_NEW_PARAGRAPH,new qe),De.registerActionHandlerInterceptor(_.name,$.PASTE_CONTENT,new tn)})();class an extends B{constructor(t){super(),this.isFlushable=!0,this.type="DELETE_TABLE_BLOCK",this.tableBlock=t}}class ln extends z{constructor(){super(...arguments),this.type=rt.CAPTION}clone(){return new ln}renderClass(t){return(null==t?void 0:t.standalone)?null:"v-rte--extension-table-caption"}renderStyle(t){return(null==t?void 0:t.standalone)?{padding:"8px",border:"1px solid #ddd",borderBottom:"none",backgroundColor:this.getCaptionBackgroundColor(),position:"relative",textAlign:"center",minHeight:"22px"}:null}toJSON(){return{caption:{padding:"8px 12px",border:"1px solid #ddd",borderBottom:"none",backgroundColor:this.getCaptionBackgroundColor(),position:"relative",textAlign:"center",minHeight:"22px"}}}getCaptionBackgroundColor(){return re.isDarkMode()?at.dark:at.light}}class RTETableCaptionBlock extends N{constructor(t,e){super(t),this.type="table-caption";const{autoMatchFormat:n}=e||{autoMatchFormat:!0};n&&this.annotationMap.set(rt.CAPTION,new ln)}static from(t,e){const n=new RTETableCaptionBlock(t.id,e);return super.convertAnnotationsToMap(n.annotationMap,Object.assign({},t.annotations)),n.children=super.generateBlockChildren(t.children,e,n),n}clone(t){const e=new RTETableCaptionBlock(this.id);return e.children=this.children.map((t=>t.clone(e))),e.parent=t,e.annotationMap=super.cloneAnnotations(),e}getLastNode(){return this.children[this.children.length-1].getLastNode()}isNotEmpty(){return this.children.length>0&&this.children.some((t=>t.isNotEmpty()))}toHtml(){const t=this.children.map((t=>t.toHtml())).join("");return`<caption${super.generateAttributeString()}>${t}</caption>`}toJSON(){return Object.assign(Object.assign({},super.toJSON()),{type:this.type,children:this.children.map((t=>t.toJSON()))})}}O.register($.INSERT_CHILDREN_BEFORE,RTETableCaptionBlock.name,new E),O.register($.PASTE_CONTENT,RTETableCaptionBlock.name,new S);class cn extends B{constructor(t){super(),this.type="TOGGLE_TABLE_CAPTION",this.isFlushable=!0,this.shouldEnable=t}}class hn extends lt{canHandle(t){return t[0]===ct.CAPTION}execute(t,e,n){const s="rte-table-caption"===t[1],o=new cn(s),i=n.getCaption();if(s){const t=i&&i.isNotEmpty()?i:this.createCaptionBlock(null==i?void 0:i.id);i&&t===i||n.setCaption(t),o.nextFocusNode=t.getLastNode()}else i&&(n.setCaption(null),o.nextFocusNode=n.getFirstNode());this.syncCursorPosition(n,o.nextFocusNode)}syncCursorPosition(t,e){super.syncCursorPosition(t,e)}createCaptionBlock(e){const n={id:null!=e?e:t(),type:"table-caption",children:[{id:t(),type:"paragraph",nodes:[{id:t(),type:"text",text:""}]}]};return RTETableCaptionBlock.from(n)}}class dn{constructor(t){this.renderContext=t}getTableExtensionContext(){return this.renderContext?_e.getExtensionContext(this.renderContext.host):null}}class un extends dn{constructor(){super(...arguments),this.settingHandlers=[new ht,new hn,new dt,new ut,new pt],this.handleTableClick=(t,e)=>{const n=t.target.closest("table");if(e!==n)return this.popoverRef.hide(),void this.tableDynamicPopover.hide();this.tableDynamicPopover.hide(),this.popoverShow||(ne.call(et.getSubject(this.popoverRef,se),n),this.popoverRef.show())},this.syncSelectedCells=()=>{if(this.tableSettingRef){const t=this.getTableSelectedCells();this.tableSettingRef.selectedCells=t}},this.handleSettingMenuClick=t=>{const e=this.settingHandlers.find((e=>e.canHandle(t.detail)));if(e){const n=this.getTableExtensionContext();n&&e.execute(t.detail,n,this.tableData),t.detail[0]===ct.CAPTION&&this.updateTableSettingCaption()}t.detail[0]!==ct.TABLE&&t.detail[0]!==ct.CELL||(this.popoverRef.hide(),this.tableDynamicPopover.show(t.detail[0]))},this.handleTableSettingPopoverShow=()=>{this.syncSelectedCells(),this.popoverShow=!0}}render(t,e,n,s){return this.tableData=e,this.tableDynamicPopover=s,t("vega-popover",{trigger:"click",isScreenPosition:!0,class:"rte-table-setting-popover",ref:t=>{this.popoverRef=t,this.popoverRef&&(tt.addUniqueObserverToNode(t,ot,this.handleTableSettingPopoverShow),tt.addUniqueObserverToNode(t,it,(()=>this.popoverShow=!1)))}},[t("div",{slot:"popover"},[t("vega-rich-text-table-setting",{ref:t=>{this.tableSettingRef=t,t&&(t.target=n())},selectedCells:this.getTableSelectedCells(),onVegaClick:this.handleSettingMenuClick})])])}updateTableSettingCaption(){const t=this.tableData.hasCaption();this.tableSettingRef&&this.tableSettingRef.hasCaption!==t&&(this.tableSettingRef.hasCaption=t)}getTableSelectedCells(){let t=[];const e=this.getTableExtensionContext();if(e&&e.tableSelection){const{tableSelection:n}=e;t=n.getSelectedCells()}return t}}class pn{static generateTablePropertiesForm(t){const e=t.annotationMap.get(rt.TABLE);let n={borderStyle:"none",borderColor:"",borderWidth:"",backgroundColor:"",width:"",height:"",textAlign:"center"};if(e){const t=e.toJSON().table,{style:s="none",color:o="",width:i=""}=t.border||{style:"none",color:"",width:""};n={backgroundColor:t.backgroundColor||"",width:t.width||"",height:t.height||"",textAlign:t.alignment,borderStyle:s,borderColor:o,borderWidth:i}}return n}updateCursorPosition(t,e){t&&e&&t.host.value.apply(new y(e,0))}}class fn extends W{constructor(t){super(),this.isFlushable=!0;const{textAlign:e,width:n,borderWidth:s,borderColor:o,borderStyle:i,height:r}=t,a=function(t,e){var n={};for(var s in t)Object.prototype.hasOwnProperty.call(t,s)&&e.indexOf(s)<0&&(n[s]=t[s]);if(null!=t&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(s=Object.getOwnPropertySymbols(t);o<s.length;o++)e.indexOf(s[o])<0&&Object.prototype.propertyIsEnumerable.call(t,s[o])&&(n[s[o]]=t[s[o]])}return n}(t,["textAlign","width","borderWidth","borderColor","borderStyle","height"]);this.tableProperties=Object.assign(Object.assign({},a),{alignment:e,border:{style:i,color:o,width:s?le(s):""},width:n?le(n):"",height:r?le(r):""})}toAnnotation(){return new ft(this.tableProperties)}}class gn extends pn{handle(t,e,n,s){e.apply(new fn(n)),this.updateCursorPosition(t,s)}}class bn extends pn{handle(t,e,n,s){t&&t.host&&(t.flushValue(t.host.value),this.updateCursorPosition(t,s))}}class wn extends pn{handle(t,e,n){const s=new fn(n);s.isFlushable=!1,e.apply(s)}}class yn extends W{constructor(t,e){super(),this.isFlushable=!0,this.cellAnnotation=t,this.originAnnotation=e}toAnnotation(){return this.updateOriginAnnotation(),this.originAnnotation}updateOriginAnnotation(){Object.keys(this.cellAnnotation).forEach((t=>{this.originAnnotation[t]=this.cellAnnotation[t]}))}}class mn extends yn{constructor(t,e){super(t,e),this.isFlushable=!0}toAnnotation(){return this.updateOriginAnnotation(),this.originAnnotation}}var vn=function(t,e){var n={};for(var s in t)Object.prototype.hasOwnProperty.call(t,s)&&e.indexOf(s)<0&&(n[s]=t[s]);if(null!=t&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(s=Object.getOwnPropertySymbols(t);o<s.length;o++)e.indexOf(s[o])<0&&Object.prototype.propertyIsEnumerable.call(t,s[o])&&(n[s[o]]=t[s[o]])}return n};class Cn{static getStyleCollectionFromCell(t){return t.reduce(((t,e)=>{const n=e.getAnnotationByType(rt.CELL);if(t[e.id]={},n){const s=n.toJSON().tableCell,{border:o}=s,i=vn(s,["border"]),r={};o&&(r.borderStyle=o.style,r.borderColor=o.color,r.borderWidth=o.width),t[e.id]=ce(Object.assign(Object.assign({},i),r))}return t}),{})}static convertStyleMapToFormField(t){const e={};for(const n in t){const s=t[n];for(const t in s)e[t]?e[t].push(s[t]):e[t]=[s[t]]}const n=Object.keys(t).length,s={};for(const t in e){const o=e[t],i=new Set(o);o.length===n&&1===i.size&&(s[t]=o[0])}return s}applyProperties(t,e,n){t.tableSelection.getSelectedCells().forEach((t=>{const s=e[t.id];if(s){const e=this.convertToVegaTableCellAnnotation(Object.assign({},s));this.applyAnnotation(t,e,n)}}))}updateCursorPosition(t,e){t&&e&&t.host.value.apply(new y(e,0))}convertToVegaTableCellAnnotation(t){const{borderStyle:e,borderWidth:n,borderColor:s}=t,o=vn(t,["borderStyle","borderWidth","borderColor"]),i=ce({style:e,width:n?le(n):"",color:s});return ce(Object.assign(Object.assign({},o),{backgroundColor:o.backgroundColor||"",padding:o.padding?le(o.padding):"",width:o.width?le(o.width):"",height:o.height?le(o.height):"",verticalAlign:o.verticalAlign||"",textAlign:o.textAlign||"",border:i}))}applyAnnotation(t,e,n){const s=t.getAnnotationByType(rt.CELL)||new gt({},!1),o=t instanceof bt?new mn(e,s):new yn(e,s);o.isFlushable=n,t.apply(o)}}class xn extends Cn{handle(t,e,n){t&&t.host&&(t.flushValue(t.host.value),this.updateCursorPosition(t,n))}}class Tn extends Cn{handle(t,e){this.applyProperties(t,e,!1)}}class En extends Cn{handle(t,e,n){this.applyProperties(t,e,!0),this.updateCursorPosition(t,n)}}class Sn extends dn{constructor(t,e){super(e),this.tableColorSchema=[],this.popoverCloseType="none",this.tablePropertiesHandlerMap={save:new bn,cancel:new gn,change:new wn},this.cellPropertiesHandlerMap={save:new xn,cancel:new En,change:new Tn},this.handleTablePropertiesUpdate=t=>{const e=t.type.replace("vega","").toLowerCase();this.popoverCloseType=e,"change"!==e&&this.hide();const n=this.getTableExtensionContext();n&&this.tablePropertiesHandlerMap[e].handle(n,this.currentTableBlock,t.detail,this.currentFocusNode),"change"===e&&this.popoverRef&&this.popoverRef.show(!0)},this.handleCellPropertiesUpdate=t=>{const e=t.type.replace("vega","").toLowerCase();this.popoverCloseType=e,"change"!==e&&this.hide();const n=this.getTableExtensionContext();n&&this.cellPropertiesHandlerMap[e].handle(n,t.detail,this.currentFocusNode),"change"===e&&this.popoverRef&&this.popoverRef.show(!0)},this.tableColorSchema=t}destroy(){this.selectionAnchorRef&&this.selectionAnchorRef.parentNode&&(tt.removeUniqueObserverFromNode(this.selectionAnchorRef,oe),this.selectionAnchorRef.parentNode.removeChild(this.selectionAnchorRef),this.selectionAnchorRef=null)}async show(t){let e=this.getTableRef();const n=this.getTableExtensionContext();let s=[];if(n&&(s=n.tableSelection.getSelectedCells()),t===ct.CELL&&s.length>1){const t=this.getOrCreateSelectionAnchor(s,e);t&&(e=t)}else t===ct.CELL&&1===s.length&&(e=R.getDOMByEntity(s[0]));this.updateContent(t),this.storeCurrentFocusNode(),ne.call(et.getSubject(this.popoverRef,se),e),await this.popoverRef.show()}async hide(){await this.popoverRef.hide()}render(t,e,n){return this.getTableRef=e,this.currentTableBlock=n,t("vega-popover",{trigger:"click",isScreenPosition:!0,class:"rte-table-dynamic-popover",ref:t=>{this.popoverRef=t,tt.addUniqueObserverToNode(t,it,(()=>{const t=this.getTableExtensionContext();"change"===this.popoverCloseType&&t&&t.flushValue(t.host.value)}))}},[t("div",{slot:"popover",class:"rte-table-dynamic-popover-content"},[t("vega-rich-text-table-properties",{ref:t=>this.tablePropertiesFormRef=t,colors:this.tableColorSchema,type:ct.TABLE,onVegaCancel:this.handleTablePropertiesUpdate,onVegaChange:this.handleTablePropertiesUpdate,onVegaSave:this.handleTablePropertiesUpdate}),t("vega-rich-text-table-properties",{ref:t=>this.cellPropertiesFormRef=t,colors:this.tableColorSchema,type:ct.CELL,onVegaCancel:this.handleCellPropertiesUpdate,onVegaChange:this.handleCellPropertiesUpdate,onVegaSave:this.handleCellPropertiesUpdate})])])}updateContent(t){this.popoverCloseType="none";const e=this.getTableExtensionContext();this.tablePropertiesFormRef&&"TABLE"===t?(this.tablePropertiesFormRef.classList.remove("vega-hidden"),this.cellPropertiesFormRef.classList.add("vega-hidden"),this.tablePropertiesFormRef.defaultValue=pn.generateTablePropertiesForm(this.currentTableBlock)):this.cellPropertiesFormRef&&"CELL"===t&&(this.cellPropertiesFormRef.classList.remove("vega-hidden"),this.tablePropertiesFormRef.classList.add("vega-hidden"),e&&(this.cellPropertiesFormRef.styleMap=Cn.getStyleCollectionFromCell(e.tableSelection.getSelectedCells())),this.cellPropertiesFormRef.defaultValue=Cn.convertStyleMapToFormField(this.cellPropertiesFormRef.styleMap)),e&&e.getSelection().removeAllRanges()}storeCurrentFocusNode(){const t=this.getTableExtensionContext();t&&(this.currentFocusNode=t.getSelectedNodes()[0])}getOrCreateSelectionAnchor(t,e){const n=ae();if(n&&e){const s=e.closest(".rich-text-content"),o=s.getBoundingClientRect();let i=Number.POSITIVE_INFINITY,r=Number.NEGATIVE_INFINITY,a=Number.POSITIVE_INFINITY,l=Number.NEGATIVE_INFINITY;t.map((t=>R.getDOMByEntity(t))).filter(J).forEach((t=>{const e=t.getBoundingClientRect();i=Math.min(i,e.left-o.left),r=Math.max(r,e.right-o.left),a=Math.min(a,e.top-o.top),l=Math.max(l,e.bottom-o.top)}));const c=r-i,h=l-a;return this.selectionAnchorRef=s.querySelector(".rte-table-selection-popover-anchor"),this.selectionAnchorRef||(this.selectionAnchorRef=n.createElement("div"),this.selectionAnchorRef.className="rte-table-selection-popover-anchor",this.selectionAnchorRef.style.position="absolute",this.selectionAnchorRef.style.pointerEvents="none",s.appendChild(this.selectionAnchorRef),tt.addUniqueObserverToNode(this.selectionAnchorRef,oe,(()=>{this.destroy()}))),this.selectionAnchorRef.style.left=`${i}px`,this.selectionAnchorRef.style.top=`${a}px`,this.selectionAnchorRef.style.width=`${c}px`,this.selectionAnchorRef.style.height=`${h}px`,this.selectionAnchorRef}}}class kn extends Me{doRender(t,e,n){const s=new un(n),o=new Sn(wt.getTableColors(),n);let i;const r=this.renderTable(t,e,(t=>i=t)),a=s.render(t,e,(()=>i),o),l=o.render(t,(()=>i),e),c=e.getAnnotationByType(rt.TABLE),h=n.editable?[t("vega-rich-text-table-selection-widget",{onVegaRemove:t=>{t.stopPropagation(),this.handleTableRemove(e,i)},onClick:t=>s.handleTableClick(t,i),onMouseLeave:()=>{s.syncSelectedCells()}},[t("div",{contentEditable:!0,ref:this.useRef(e)},[r,a,l])])]:[r],d={};if(c){const t=c.renderStyle();d.width=t.width,d.margin=t.margin}const u=t("div",{class:"v-rte--extension-table-container",style:Object.assign({},d)},h);return u.childrenContainerGetter=()=>r,u}injectRTEScopeStyles(){return".v-rte--extension-table-container{display:table}table.v-rte--extension-table{border-collapse:collapse}table.v-rte--extension-table th,table.v-rte--extension-table td{border:1px solid #ddd;padding:12px;text-align:left;vertical-align:middle;min-width:55px;box-sizing:border-box;position:relative}table.v-rte--extension-table th{background-color:#f2f2f2}.rte-table-setting-popover,.rte-table-dynamic-popover{display:block}table.v-rte--extension-table .v-rte-table-cell-focused::after,table.v-rte--extension-table .v-rte-table-cell-selected::after{content:'';position:absolute;top:0;left:0;right:0;bottom:0;pointer-events:none;background-color:rgba(158, 207, 250, 0.3)}table.v-rte--extension-table:has(.v-rte-table-cell-selected){caret-color:transparent}table.v-rte--extension-table:has(.v-rte-table-cell-selected) ::selection{background-color:transparent}table.v-rte--extension-table:has(.v-rte-table-cell-selected) ::-moz-selection{background-color:transparent}.v-rte--extension-table-caption{padding:8px;border:1px solid #ddd;border-bottom:none;background-color:rgba(var(--v-bg-table-header, 24, 24, 48));position:relative;display:table-caption;caption-side:top;min-height:22px;text-align:center;word-break:break-word;overflow-wrap:break-word}.v-rte--extension-table-caption.showPlaceholder::before{position:absolute;left:0;right:0;content:attr(data-placeholder);font-family:'Inter', sans-serif;font-size:16px;font-weight:400;line-height:24px;letter-spacing:0;color:rgba(var(--v-text-input-placeholder, 176, 180, 181, 1));text-align:center;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}"}renderTable(t,e,n){var s;return t("table",Object.assign(Object.assign({key:e.id},null===(s=e.getCustomAttributesAnnotation())||void 0===s?void 0:s.render()),{style:e.getStyles(),class:e.getClasses(),ref:t=>{this.useRef(e)(t),n(t)}}))}handleTableRemove(t,e){t.parent.apply(new an(t)),this.destroySelectionAnchor(e)}destroySelectionAnchor(t){const e=t.closest(".rich-text-content");if(e){const t=e.querySelector(".rte-table-selection-popover-anchor");t&&he.notify(et.getSubject(t,oe),{host:t})}}}class An extends Me{doRender(t,e){return t("thead",{key:e.id,ref:this.useRef(e)})}}class Rn extends Me{doRender(t,e){return t("tr",{key:e.id,ref:this.useRef(e)})}}class On extends Me{doRender(t,e,n){return this.renderByCellType(t,e,n,"td")}renderByCellType(t,e,n,s){var o;return t(s,Object.assign(Object.assign(Object.assign({key:`${e.id}-${s}`,ref:this.useRef(e)},null===(o=e.getCustomAttributesAnnotation())||void 0===o?void 0:o.render()),{style:e.getStyles(n),class:e.getClasses()}),n.editable?this.onSelectionListeners(e,n):void 0))}onSelectionListeners(t,e){return{onMouseDown:t=>{const n=o(t.target,"table"),s=o(t.currentTarget,"table")===n,i=t.target.closest("td, th");if(s&&i){const t=this.getExtensionContext(e.host);t&&t.tableSelection.focusCell(i)}},onMouseMove:n=>{n.stopPropagation(),n.preventDefault();const s=this.getExtensionContext(e.host);s&&s.tableSelection.dragOver(t)},onMouseUp:()=>{const t=this.getExtensionContext(e.host);t&&t.tableSelection.endDrag()}}}}class In extends Me{doRender(t,e){return t("tbody",{key:e.id,ref:this.useRef(e)})}}class Ln extends On{doRender(t,e,n){return super.renderByCellType(t,e,n,"th")}}class Bn extends B{constructor(t,e){super(),this.type="INSERT_TABLE_BLOCK",this.rowCount=t,this.columnCount=e}}class jn extends dn{constructor(){super(...arguments),this.hoveredRows=1,this.hoveredCols=1}render(t,e){return t("vega-popover",{trigger:"click",alignment:"start",placement:"bottom",showArrow:!1,ref:t=>{t&&(this.tablePickerPopoverRef=t,tt.addUniqueObserverToNode(t,ot,(()=>{this.resetPicker()})))}},[t("div",{slot:"popover"},[this.generatePickerStyles(t),this.generateTableSizeGrid(t)]),t("div",{slot:"popover-content"},e)])}generateTableSizeGrid(t){const e=[];for(let n=1;n<=10;n++)for(let s=1;s<=10;s++)e.push(t("button",{class:"rte-table-picker__cell","data-row":n,"data-col":s,onMouseenter:this.handlePickerCellHover.bind(this,n,s),onClick:this.handlePickerClick.bind(this,n,s)},[]));return t("div",{class:"rte-table-picker"},[t("div",{class:"rte-table-picker__grid",ref:t=>{t&&(this.tablePickerGridRef=t)},style:{gridTemplateColumns:"repeat(10, 16px)",gridTemplateRows:"repeat(10, 16px)"}},e),t("div",{class:"rte-table-picker__hint"},t("vega-hint",{ref:t=>{t&&(this.selectedHintRef=t)}},[`${this.hoveredRows} × ${this.hoveredCols}`]))])}generatePickerStyles(t){return t("style",{},["\n.rte-table-picker__grid { display: grid; gap: 2px; }\n.rte-table-picker__cell {\n box-sizing: border-box;\n border: 1px solid #ccc;\n background-color: transparent;\n cursor: pointer;\n}\n.rte-table-picker__cell:hover {\n background-color: #cae1fc;\n}\n.rte-table-picker__cell.active {\n background-color: #cae1fc;\n}\n.rte-table-picker__hint {\n text-align: center;\n}\n "])}createTable(t,e){const n=this.getTableExtensionContext();if(n){const{host:s,getSelectedNodes:o}=n,i=o()[0],r=new Bn(t,e);i?i.parent&&i.parent.apply(r):s.value.apply(r),r.nextFocusNode&&s.value.apply(new y(r.nextFocusNode,1))}}handlePickerClick(t,e){this.createTable(t,e),this.tablePickerPopoverRef.hide()}handlePickerCellHover(t,e){this.hoveredRows=t,this.hoveredCols=e,Array.from(this.tablePickerGridRef.children).forEach((t=>{const e=Number(t.dataset.row),n=Number(t.dataset.col);e<=this.hoveredRows&&n<=this.hoveredCols?t.classList.add("active"):t.classList.remove("active")})),this.selectedHintRef.textContent=`${this.hoveredRows} × ${this.hoveredCols}`}resetPicker(){this.handlePickerCellHover(1,1)}}class Nn extends Ve{render(t,e){return new jn(e).render(t,super.renderButton(t,e,{showArrowIcon:!0,icon:"rte-table"}))}isDisabled(t){let e=super.isDisabled(t);const n=this.getExtensionContext(t.host);if(n){const{host:t,getSelectedNodes:s}=n,o=s()[0];let i=!0;o&&(i=O.canHandle("INSERT_TABLE_BLOCK",o.parent)&&O.canHandle($.INSERT_CHILDREN_AFTER,o.parent.parent)),e=t.disabled||!i}return e}handleButtonClick(){}handleDropdownClick(){}}Q.register({"rte-table":{icon:'<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 512 512">\x3c!--! Font Awesome Pro 6.3.0 by @fontawesome - https://fontawesome.com License - https://fontawesome.com/license (Commercial License) Copyright 2023 Fonticons, Inc. --\x3e<path fill="currentColor" d="M48 264V160H232V264H48zm0 48H232V432H64c-8.8 0-16-7.2-16-16V312zM280 432V312H464V416c0 8.8-7.2 16-16 16H280zM464 264H280V160H464V264zM64 32C28.7 32 0 60.7 0 96V416c0 35.3 28.7 64 64 64H448c35.3 0 64-28.7 64-64V96c0-35.3-28.7-64-64-64H64z"/></svg>'}});class _n extends D{handleAction(t,e){const n=this.createTableBlock(t.rowCount,t.columnCount),s=super.createNewParagraph(""),o=this.getReferenceBlock(e);o?o.parent.apply(new V(o,n,s)):e.apply(new P([n,s])),t.nextFocusNode=n.getFirstNode()}createTableBlock(e,n){const s=Math.max(e,1),o=Math.max(n,1);return yt.from({id:t(),type:"table-block",children:[mt(s,o)]})}getReferenceBlock(t){if(!(t instanceof m))return t}}class Mn extends Xe{canIntercept(t,e){const n=e.parent;return n instanceof vt&&1===n.children.length&&0===t.startOffset}intercept(){}}class Dn extends D{handleAction(t){const e=t.tableBlock,n=e.parent,s=super.getRootContent(e),o=super.createNewParagraph("");n.apply(new V(e,o)),n.apply(new G(e)),s&&s.apply(new y(o.getLastNode()))}}class Vn extends Xe{canIntercept(t,e){return t.entityToBeRemoved&&1===e.children.length}intercept(e,n,s){if(!(n.entityToBeRemoved instanceof _)){const e=_.from({id:t(),type:"paragraph",nodes:[{id:t(),type:"text",text:""}]});return s.children=[],void s.apply(new P([e]))}n.entityToBeRemoved.apply(new P([new j(t(),"",n.entityToBeRemoved)]))}}class Pn extends Me{doRender(t,e){return t("caption",{key:e.id,ref:this.useRef(e),style:e.getStyles(),class:[e.getClasses(),e.isNotEmpty()?null:"showPlaceholder"].filter(J).join(" "),"data-placeholder":"Enter table caption"})}}class Hn extends D{getRowsMaxCellCount(t){let e=0;for(const n of t){let t=0;for(const e of n.children)t+=e.colSpan;e=Math.max(e,t)}return e}getRowCellStartCols(t){const e=this.getRowsMaxCellCount(t),n=new Array(t.length),s=new Array(e).fill(0);for(let e=0;e<t.length;e++){const o=t[e].children,i=new Array(o.length);let r=0;for(let t=0;t<o.length;t++){const e=o[t];for(;r<s.length&&s[r]>0;)r++;i[t]=r;const n=Math.max(e.colSpan,Hn.DEFAULT_CELLSPAN);if(e.rowSpan>Hn.DEFAULT_CELLSPAN)for(let t=0;t<n;t++){const n=r+t;n<s.length&&(s[n]=Math.max(s[n],e.rowSpan))}r+=n}n[e]=i;for(let t=0;t<s.length;t++)s[t]>0&&s[t]--}return n}updateCellSpan(t,e,n){const s=t.getCustomAttributesAnnotation();if(n<=Hn.DEFAULT_CELLSPAN){if(s){const n=s.render();delete n[e],t.annotationMap.set(U.CUSTOM_ATTRIBUTE,new Z(n))}}else{const o=s?s.render():{};o[e]=n.toString(),t.annotationMap.set(U.CUSTOM_ATTRIBUTE,new Z(o))}}insertMovedCells(t,e,n){t.forEach(((t,s)=>{const o=e[s];if(o){const e=n[s]||[];t.sort(((t,e)=>t.logicalStartCol===e.logicalStartCol?e.cellIndex-t.cellIndex:e.logicalStartCol-t.logicalStartCol)),t.forEach((t=>{const{cell:n,logicalStartCol:s}=t;if(0===o.children.length)return o.apply(new P([n])),void(e[0]=s);const i=e.findIndex((t=>t>=s));-1===i?(o.apply(new V(o.children[o.children.length-1],n)),e.push(s)):0===i?(o.apply(new F(o.children[0],n)),e.unshift(s)):(o.apply(new F(o.children[i],n)),e.splice(i,0,s))}))}}))}splitRowsBySection(t){const e=[],n=[];return t.forEach((t=>{t.parent instanceof Ct?e.push(t):n.push(t)})),[e,n]}buildSelectedIndices(t,e){return new Set(t.map((t=>e.indexOf(t))).filter((t=>t>=0)))}intersectsRemovalRange(t,e,n,s){return t<=s&&e>=n}countRemovedRows(t,e,n){let s=0;for(let o=t;o<=e;o++)n.has(o)&&s++;return s}getHeadCellLength(t){let e=0;for(let n=0;n<t.children.length;n++){const s=t.children[n];if(!(s instanceof bt))break;e+=s.colSpan}return e}getTheStartSpanCell(t,e,n,s){const o={rowIndex:n};for(let i=n;i>=0;i--){const n=e[i];if(n.includes(s)){o.cell=t[i].children[n.indexOf(s)],o.rowIndex=i;break}}return o}getDefaultCellBlockTemplate(e,n,s=1){const o=ce({colspan:n>1?n.toString():null,rowspan:s>1?s.toString():null}),i=t(),r={id:i,type:e,children:[{id:`${i}-p`,type:"paragraph",nodes:[{id:`${i}-p-t`,type:"text",text:""}]}]};return Object.keys(o).length>0&&(r.annotations={customAttribute:o}),r}getSortedValuesByNumericKey(t){return Array.from(t.entries()).sort((([t],[e])=>t-e)).map((([,t])=>t))}}Hn.DEFAULT_CELLSPAN=1;class Fn extends Hn{handleAction(t,e){const{rowsToBeRemoved:n}=t,s=this.getFutureFocusRow(n[0],n[n.length-1],e),o=this.splitRowsBySection(n);if(this.removeRows(o[0]),this.removeRows(o[1]),s){const t=this.getRootContent(e);if(t){const e=s.getLastNode();t.apply(new y(e,e.getRangeEndOffset()))}}}removeRows(t){if(0===t.length)return;const e=t[0].parent,n=e.children,s=this.buildSelectedIndices(t,n);if(s.size>0){if(n.length===t.length)return void e.parent.apply(new G(e));const o=Math.min(...s),i=Math.max(...s),r=this.getRowCellStartCols(n),a=this.collectCellsToMove(n,r,s,o,i);this.insertMovedCells(a,n,r),t.forEach((t=>{t.parent.apply(new G(t))}))}}collectCellsToMove(t,e,n,s,o){const i=new Map,r=t.length;for(let a=0;a<r;a++){const l=t[a],c=l.children.length;for(let t=0;t<c;t++){const c=l.children[t],h=c.rowSpan;if(h<=Hn.DEFAULT_CELLSPAN)continue;const d=a+h-1;if(!this.intersectsRemovalRange(a,d,s,o))continue;const u=h-this.countRemovedRows(a,d,n);if(a<s&&d>=s)this.updateCellSpan(c,"rowspan",u);else if(a>=s&&d>o){const s=o+1;if(s<r&&!n.has(s)){const n=e[a][t];i.has(s)||i.set(s,[]),i.get(s).push({cell:this.cloneCellWithRowSpan(c,u),newRowSpan:u,cellIndex:t,logicalStartCol:n})}}}}return i}cloneCellWithRowSpan(t,e){const n=t.clone(t.parent);return this.updateCellSpan(n,"rowspan",e),n}getFutureFocusRow(t,e,n){const s=n.children.filter((t=>t instanceof Ct||t instanceof xt)).flatMap((t=>t.children)),o=s.indexOf(t),i=s.indexOf(e);return s[o-1]?s[o-1]:s[i+1]?s[i+1]:void 0}}class Kn{constructor(){this.dragging=!1,this.anchorCell=null,this.selectedCells=new Set,this.syncRTESelectionWithDebounce=de(this.syncRTESelection,100,this),this.handleSelectionChangeWithDebounce=de(this.handleSelectionChange,10,this),this.filterSelectedCell=(t,e)=>{const n=new Set;if(t.intersectsNode(e)){if(e.nodeType===Node.TEXT_NODE){const t=R.getEntityByDOM(e.parentElement);if(t){const e=Tt(t.parent,vt);if(e)return n.add(e),Array.from(n)}}e.childNodes.forEach((e=>this.filterSelectedCell(t,e).forEach((t=>{n.add(t)}))))}return Array.from(n)},this.updateSelectedStyles=(t,e)=>{const n=1===e?"v-rte-table-cell-focused":"v-rte-table-cell-selected",s=R.getDOMByEntity(t);s&&s.classList.add(n)},this.handleDocMouseUp=()=>{this.endDrag();const t=ae();t&&t.removeEventListener("mouseup",this.handleDocMouseUp)},this.handleContentClick=()=>{this.clearSelection();const t=this.context.host.shadowRoot.querySelector(".rich-text-editor-container");t&&t.removeEventListener("mousedown",this.handleContentClick,!0)}}static computeRectRange(t,e){const n=t.parent.parent.parent;if(n!==e.parent.parent.parent)return[];const s=[];n.children.forEach((t=>{t.children.forEach((t=>s.push(t)))}));const{grid:o,cellMeta:i}=Kn.buildCellGrid(s),r=i.get(t),a=i.get(e);if(!r||!a)return[];const l=r.row+r.rowSpan-1,c=r.col,h=r.col+r.colSpan-1,d=a.row+a.rowSpan-1,u=a.col,p=a.col+a.colSpan-1,f=Math.min(r.row,a.row),g=Math.max(l,d),b=Math.min(c,u),w=Math.max(h,p),y=new Set;for(let t=f;t<=g;t++){const e=o[t];for(let t=b;t<=w;t++){const n=e[t];n&&y.add(n)}}return Array.from(y)}static getCellSpan(t){let e=1,n=1;const s=t.getAnnotationByType(U.CUSTOM_ATTRIBUTE);if(s&&s.customAttribute){const t=s.customAttribute;t.rowSpan&&(e=parseInt(t.rowSpan,10)),t.colSpan&&(n=parseInt(t.colSpan,10))}if(1===e&&1===n){const s=R.getDOMByEntity(t);if(s){const t=s.getAttribute("rowSpan"),o=s.getAttribute("colSpan");t&&(e=parseInt(t,10)),o&&(n=parseInt(o,10))}}return{rowSpan:Number.isFinite(e)&&e>0?e:1,colSpan:Number.isFinite(n)&&n>0?n:1}}static buildCellGrid(t){const e=[],n=new Map;for(let s=0;s<t.length;s++){const o=t[s];e[s]||(e[s]=[]);let i=0;for(let t=0;t<o.children.length;t++){const r=o.children[t];for(;e[s][i];)i+=1;const{rowSpan:a,colSpan:l}=Kn.getCellSpan(r);n.set(r,{row:s,col:i,rowSpan:a,colSpan:l});for(let t=0;t<a;t++){const n=s+t;e[n]||(e[n]=[]);for(let t=0;t<l;t++)e[n][i+t]=r}i+=l}}return{grid:e,cellMeta:n}}destroy(){this.removeSelectionChangeListener()}init(t){this.context=t,this.addSelectionChangeListener()}setSelectedCells(t){const e=Array.from(this.selectedCells)[0]||t[0];this.updateSelectedCells(t),this.emitCellSelectionChange(e,t)}getSelectedCells(){return Array.from(this.selectedCells)}focusCell(t){const e=R.getEntityByDOM(t);e&&(this.anchorCell=e,this.setSelectedCells([e]),this.addListeners())}dragOver(t){if(!this.anchorCell)return;const e=Kn.computeRectRange(this.anchorCell,t);e.length>1&&this.startDrag(),this.dragging&&(this.preventTextSelection(e),this.updateSelectedCells(e,{debounceSync:!0}))}endDrag(){this.dragging=!1,this.anchorCell=null}emitCellSelectionChange(t,e){const n=Tt(t,yt);if(n){const t=R.getDOMByEntity(n);t&&he.notify(et.getSubject(t,ie),{host:t,detail:e})}}clearSelection(){this.selectedCells.forEach((t=>{const e=R.getDOMByEntity(t);e&&e.classList.remove("v-rte-table-cell-selected","v-rte-table-cell-focused")})),this.selectedCells.clear()}addSelectionChangeListener(){const t=ae();t&&t.addEventListener("selectionchange",this.handleSelectionChangeWithDebounce)}removeSelectionChangeListener(){const t=ae();t&&t.removeEventListener("selectionchange",this.handleSelectionChangeWithDebounce)}handleSelectionChange(){if(this.dragging)return void this.syncRTESelectionWithDebounce();const t=this.context.getSelection();if(t.rangeCount>0){const e=t.getRangeAt(0),n=e.commonAncestorContainer;if(o(n,"table")){const t=this.filterSelectedCell(e,n);this.setSelectedCells(t)}}}startDrag(){this.dragging=!0}updateSelectedCells(t,{debounceSync:e}={}){this.clearSelection(),t.forEach((e=>{this.selectedCells.add(e),this.updateSelectedStyles(e,t.length)})),e?this.syncRTESelectionWithDebounce():this.syncRTESelection()}syncRTESelection(){const t=Array.from(this.selectedCells),e=t.flatMap((t=>t.children.flatMap((t=>t.children.flatMap((t=>{if(t instanceof H)return t})))))).filter(J);t.length>1&&this.context.setSelectedNodes(e,{startNode:e[0],endNode:e[e.length-1],startOffset:0,endOffset:e[e.length-1].getRangeEndOffset()})}preventTextSelection(t){const e=this.context.getSelection();if(e.removeAllRanges(),t.length>0){const n=R.getDOMByEntity(t[0]);if(n){const t=new Range;t.setStart(n,0),t.setEnd(n,0),e.addRange(t)}}}addListeners(){const t=ae();t&&t.addEventListener("mouseup",this.handleDocMouseUp);const e=this.context.host.shadowRoot.querySelector(".rich-text-editor-container");e&&e.addEventListener("mousedown",this.handleContentClick,!0)}}class $n extends Hn{handleAction(t,e){const{selectedRows:n}=t,[s,o]=this.splitRowsBySection(n);o.length>0?this.convertToHeaderRows(o,e):this.revertToBodyRows(s,e);const i=this.getRootContent(e);if(i){const t=n[0].getFirstNode();t&&i.apply(new y(t,0))}}convertToHeaderRows(e,n){let s=n.children.find((t=>t instanceof Ct));const o=e[0].parent;s||(s=Ct.from({id:t(),type:"table-head",children:[]}),n.apply(new F(o,s)));const i=o.children.indexOf(e[e.length-1]),r=o.children.slice(0,i+1),a=this.buildSelectedIndices(r,o.children),l=Math.min(...a),c=Math.max(...a);if(a.size>0){if(a.size<o.children.length){const t=this.getRowCellStartCols(o.children),e=this.collectCellsToMove(o.children,t,a,l,c);this.insertMovedCells(e,o.children,t)}this.convertBodyRowsToHeaderRows(o,s,r)}}convertBodyRowsToHeaderRows(t,e,n){for(let e=0;e<n.length;e++){const s=n[e];s.children=s.children.map((t=>this.convertTdToTh(t))),t.apply(new G(s))}e.apply(new P(n))}revertToBodyRows(e,n){let s=n.children.find((t=>t instanceof xt));const o=e[0].parent;s||(s=xt.from({id:t(),type:"table-body",children:[]}),n.apply(new V(o,s)));const i=o.children.indexOf(e[0]),r=o.children.slice(i),a=this.buildSelectedIndices(r,o.children);if(a.size>0){const t=this.getRowCellStartCols(o.children),e=this.collectCellsToMove(o.children,t,a,Math.min(...a),Math.max(...a));this.insertMovedCells(e,o.children,t),this.convertHeadRowsToBodyRows(o,s,r)}}convertHeadRowsToBodyRows(t,e,n){const s=e.children[0],o=this.getRowCellStartCols(n);for(let i=0;i<n.length;i++){const r=n[i];t.apply(new G(r));const a=s?this.getHeadCellLength(s):0;r.children=this.convertThToTd(r,o[i],a),s&&e.apply(new F(s,r))}s||e.apply(new P(n))}collectCellsToMove(t,e,n,s,o){const i=new Map,r=t.length;for(let a=0;a<r;a++){const l=t[a],c=l.children.length;for(let t=0;t<c;t++){const c=l.children[t],h=c.rowSpan;if(h<=Hn.DEFAULT_CELLSPAN)continue;const d=a+h-1;if(!this.intersectsRemovalRange(a,d,s,o))continue;const u=this.countRemovedRows(a,d,n),p=h-u;if(a<s&&d>=s){this.updateCellSpan(c,"rowspan",p);const o=s;if(o<r&&n.has(o)){const n=e[a][t];i.has(o)||i.set(o,[]),i.get(o).push({cell:this.cloneCellWithRowSpan(c,u),newRowSpan:u,cellIndex:t,logicalStartCol:n})}}else if(a>=s&&d>o){this.updateCellSpan(c,"rowspan",u);const s=o+1;if(s<r&&!n.has(s)){const n=e[a][t];i.has(s)||i.set(s,[]),i.get(s).push({cell:this.cloneCellWithRowSpan(c,p),newRowSpan:p,cellIndex:t,logicalStartCol:n})}}}}return i}convertTdToTh(t){if(t instanceof bt)return t;const e=bt.from(t.toJSON());return e.parent=t.parent,e}convertThToTd(t,e,n){return t.children.map(((s,o)=>{let i=s;const r=e[o]<n,a=s.toJSON();return i=r?s:vt.from(this.deleteHeadCellDefaultBackground(a)),i.parent=t,i}))}cloneCellWithRowSpan(e,n){const s=e.clone(e.parent);s.id=t(),s.children=[];const o=this.createNewParagraph("");return o&&s.apply(new P([o])),this.updateCellSpan(s,"rowspan",n),s}deleteHeadCellDefaultBackground(t){var e;if(t&&t.annotations&&t.annotations.customStyle){delete t.annotations.tableCell;const n=t.annotations.customStyle.backgroundColor,s=Et.getDefaultBackgroundColor();!n||n!==s&&(null===(e=i(n))||void 0===e?void 0:e.toUpperCase())!==s||delete t.annotations.customStyle.backgroundColor}return t}}class zn extends St{handleAction(t,e){const{insertDirection:n,tableCellInsertRange:s}=t,o=new Set(s.map((t=>t.id))),i=kt(e),r=At(i),[a,l]=this.getBoundaryCellColumnRange(s,i,r),c=n===Lt.LEFT?a:l+1,h=this.hasSelectedCellInsideTargetColumn(i,r,c,o),d=new Set;i.forEach(((t,s)=>{if(d.has(s))return;const a=this.findExpandableCell(t,s,c,r,n,o,h);if(a){const t=a.rowSpan;if(Rt(a,a.colSpan+1,a.rowSpan,e,!0),t>1)for(let e=1;e<t;e++)d.add(s+e);return}const l=this.findInsertPosition(t,s,c,r,i);if(l){const e=this.generateTableCell(l.templateCell);t.apply(l.before?new F(l.anchorCell,e):new V(l.anchorCell,e))}}))}findExpandableCell(t,e,n,s,o,i,r){const a=s[e],l=t.children.reduce(((t,e)=>t+(i.has(e.id)?1:0)),0);for(const c of t.children){const t=a.indexOf(c.id),h=t+c.colSpan,d=n===h,u=e+c.rowSpan>=s.length,p=i.has(c.id),f=n>t&&n<h;if(o===Lt.LEFT?f:f&&(!p||!u)||d&&c.colSpan>1&&p&&!u&&1===l&&!r)return c}return null}hasSelectedCellInsideTargetColumn(t,e,n,s){for(let o=0;o<t.length;o++){const i=t[o],r=e[o];for(const t of i.children){if(!s.has(t.id))continue;const e=r.indexOf(t.id),o=e+t.colSpan;if(n>e&&n<o)return!0}}return!1}findInsertPosition(t,e,n,s,o){const i=s[e];let r=t.children[0];if(n>=0&&n<i.length){const t=Ot(o,i[n]);t&&(r=t)}let a=0;for(let e=0;e<t.children.length;e++){const s=t.children[e];for(;a<i.length&&i[a]!==s.id;)a++;if(a>=n)return{anchorCell:s,templateCell:r,before:!0};const o=a+s.colSpan;if(o>n||e===t.children.length-1)return{anchorCell:s,templateCell:r,before:!1};a=o}return null}generateTableCell(t){return t instanceof bt?bt.from(It(t.type)):vt.from(It(t.type))}}class Wn extends St{handleAction(t,e){const n=kt(e),s=At(n),[o,i]=this.getBoundaryCellColumnRange(t.tableCellDeleteRange,n,s),r=Math.max(n.indexOf(t.tableCellDeleteRange[t.tableCellDeleteRange.length-1].parent),0),{coveredCellIds:a,coveredCells:l,adjustmentCellInfo:c}=this.getDeleteCellsInfo(n,o,i,s),h=this.findNextFocusableCell(n,s,o,i,a,r);this.deleteCells(l,c,e);const d=this.getRootContent(e),u=Nt(h);d&&u&&d.apply(new y(u))}getDeleteCellsInfo(t,e,n,s){const o=[],i=new Set,r=[],a=Bt(s);return t.forEach((t=>{t.children.forEach((t=>{const s=a.get(t.id);if(void 0===s)return;const{colSpan:l,rowSpan:c}=_t(t),h=this.getColumnOverlapCount(s,l,e,n);if(h<=0)return;if(h===l)return o.push(t),void i.add(t.id);const d=Math.max(1,l-h);r.push({cell:t,nextColSpan:d,rowSpan:c})}))})),{coveredCells:o,coveredCellIds:i,adjustmentCellInfo:r}}findNextFocusableCell(t,e,n,s,o,i){for(let r=0;r<t.length;r++){const a=this.findFocusableCellIdInGridRow(e[(i+r)%t.length],n,s,o);if(!a)continue;const l=Ot(t,a);if(l)return l}return null}findFocusableCellIdInGridRow(t,e,n,s){for(let e=n+1;e<t.length;e++){const n=t[e];if(n&&!s.has(n))return n}for(let n=e-1;n>=0;n--){const e=t[n];if(e&&!s.has(e))return e}return null}deleteCells(t,e,n){t.forEach((t=>{t.parent.apply(new G(t))}));const s=new Set;e.forEach((({cell:t,nextColSpan:e,rowSpan:o})=>{s.add(t.id),Rt(t,e,o,n)})),this.normalizeRemainingCellSpans(n,s)}normalizeRemainingCellSpans(t,e){kt(t).forEach((n=>{n.children.forEach((n=>{const{colSpan:s,rowSpan:o}=_t(n);if(e.has(n.id)){const e=jt(t);if(!(o>1&&s===e))return}Rt(n,s,o,t)}))}))}getColumnOverlapCount(t,e,n,s){const o=t+e-1,i=Math.max(t,n),r=Math.min(o,s);return i<=r?r-i+1:0}}class Gn extends B{constructor(t){super(),this.isFlushable=!0,this.type="CREATE_SEGMENT_TABLE_CELL",this.payload=t}}class Un extends D{handleAction(t,e){const{table:n,sourceCell:s,colSpan:o,cellType:i,keepSourceContent:r}=t.payload,a=r?this.convertCellType(s,i):Mt(i);Rt(a,o,s.rowSpan,n),e.apply(new F(s,a))}convertCellType(t,e){return"table-head-cell"===e?bt.from(t.toJSON()):vt.from(t.toJSON())}}class Zn extends D{handleAction(t,e){const{cell:n,targetCellType:s}=t.payload,o="table-head-cell"===s?bt.from(n.toJSON()):vt.from(n.toJSON());e.apply(new F(n,o)),e.apply(new G(n))}}class Jn extends D{handleAction(t,e){const{table:n,cell:s,col:o,cellStartCol:i,endCol:r,targetCellType:a}=t.payload,l=i+s.colSpan-1,c=o>i?o-i:0,h=Math.min(r,l),d=h-o+1,u=l-h;c>0&&e.apply(new Gn({table:n,sourceCell:s,colSpan:c,cellType:s.type,keepSourceContent:!0})),e.apply(new Gn({table:n,sourceCell:s,colSpan:d,cellType:a,keepSourceContent:0===c})),u>0&&e.apply(new Gn({table:n,sourceCell:s,colSpan:u,cellType:s.type,keepSourceContent:0===c&&d===s.colSpan})),e.apply(new G(s))}}class Xn extends St{handleAction(t,e){const n=kt(e),s=At(n),o=Bt(s),[i,r]=this.getBoundaryCellColumnRange(t.tableCellSelectRange,n,s),a=[],l=new Set;n.forEach((t=>{t.children.forEach((t=>{const e=o.get(t.id);void 0!==e&&e>=i&&e<=r&&!l.has(t.id)&&(l.add(t.id),a.push(t))}))})),t.selectCellCallback(a)}}class qn extends Xe{canIntercept(t){return t.childrenToBeInserted.some((t=>!(t instanceof vt)))}intercept(){}}class Qn extends D{handleAction(t,e){const{targetCell:n,mergeCells:s,colSpan:o,rowSpan:i,direction:r}=t;this.mergeContentToTargetCell(n,s),Rt(n,o,i,e),this.deleteOtherSelectedCells(s,n),r!==Dt.MERGE_CELL_LEFT&&r!==Dt.MERGE_CELL_RIGHT&&i>1&&this.clearRowSpanIfUniformAcrossRow(n,e,i);const a=this.getRootContent(e),l=Nt(n);a&&l&&a.apply(new y(l))}mergeContentToTargetCell(t,e){const n=e.flatMap((t=>t.children)),s=n.filter((t=>t.isNotEmpty()));t.children=(s.length>0?s:[n[0]]).map((e=>e.clone(t)))}deleteOtherSelectedCells(t,e){t.forEach((t=>{t!==e&&t.parent.apply(new G(t))}))}clearRowSpanIfUniformAcrossRow(t,e,n){const s=t.parent.parent.children,o=At(s),i=[];for(let e=0;e<o.length;e++)o[e].includes(t.id)&&i.push(e);if(i.length>1){const t=i[0],r=t+n-1,a=new Set;let l=Number.POSITIVE_INFINITY;for(let e=0;e<o[0].length;e++){let n=o[t][e],s=1,i=!1;for(let c=t+1;c<=r;c++)o[c][e]!==n?(s>1&&(i=!0,l=Math.min(l,s),a.add(n)),s=1,n=o[c][e]):s++;if(s<2&&!i){a.clear();break}s>1&&(l=Math.min(l,s),a.add(n))}a.size>0&&s.forEach((t=>{t.children.forEach((t=>{if(a.has(t.id)){const{rowSpan:n,colSpan:s}=_t(t);Rt(t,s,n-l+1,e)}}))}))}}}class Yn extends C{canHandle(t,e){const n=t[e];return n&&"TABLE"===n.tagName?1:0}handle(e,n){return yt.from({id:t(),type:"table-block",annotations:w.generate(yt,e[0],n),children:[]},n)}appendChildBlocks(t,e){t.children=e.map((e=>(e.parent=t,e)))}shouldProceedToElementChildren(){return!0}}class ts extends v{canHandle(t,e){const n=t[e];return n&&"THEAD"===n.tagName?1:0}handle(e,n){return Ct.from({id:t(),type:"table-head",annotations:w.generate(Ct,e[0],n),children:[]},n)}appendChildBlocks(t,e){t.children=e.map((e=>(e.parent=t,e)))}shouldProceedToElementChildren(){return!0}}class es extends v{canHandle(t,e){const n=t[e];return n&&"TBODY"===n.tagName?1:0}handle(e,n){return xt.from({id:t(),type:"table-body",annotations:w.generate(xt,e[0],n),children:[]},n)}appendChildBlocks(t,e){t.children=e.map((e=>(e.parent=t,e)))}shouldProceedToElementChildren(){return!0}}class ns extends v{canHandle(t,e){const n=t[e];return n&&"TR"===n.tagName?1:0}handle(e,n){return Vt.from({id:t(),type:"table-row",annotations:w.generate(Vt,e[0],n),children:[]},n)}appendChildBlocks(t,e){t.children=e.map((e=>(e.parent=t,e)))}shouldProceedToElementChildren(){return!0}}class ss extends v{canHandle(t,e){const n=t[e];return!n||"TD"!==n.tagName&&"TH"!==n.tagName?0:1}handle(e,n){const s=e[0],o=[{id:t(),type:"paragraph",annotations:{internalWrapper:n&&!n.autoMatchFormat},nodes:[{id:t(),type:"text",annotations:{plainText:n&&!n.autoMatchFormat},text:""}]}];return"TH"===s.tagName?bt.from({id:t(),type:"table-head-cell",annotations:this.getTableHeadCellAnnotations(s,n),children:o},n):vt.from({id:t(),type:"table-cell",annotations:w.generate(bt,s,n),children:o},n)}appendChildBlocks(t,e){t.children=e.map((e=>(e.parent=t,e)))}shouldProceedToElementChildren(){return!0}getTableHeadCellAnnotations(t,e){const n=w.generate(vt,t,e);return n&&n.tableCell&&wt.getColorKey(n.tableCell.backgroundColor,!0)===at.key&&(delete n.tableCell.backgroundColor,n.customStyle&&delete n.customStyle.backgroundColor),n}}class os extends C{canHandle(t,e){const n=t[e];return n&&n.parentElement&&"TABLE"===n.parentElement.tagName&&"CAPTION"===n.tagName?1:0}handle(e,n){return RTETableCaptionBlock.from({id:t(),type:"table-caption",annotations:this.getTableCaptionAnnotations(e[0],n),children:[]},n)}appendChildBlocks(t,e){t.children=e.map((e=>(e.parent=t,e)))}shouldProceedToElementChildren(){return!0}getTableCaptionAnnotations(t,e){const n=w.generate(RTETableCaptionBlock,t,e);return n&&n.customStyle&&n.customStyle.backgroundColor&&wt.getColorKey(n.customStyle.backgroundColor,!0)===at.key&&delete n.customStyle.backgroundColor,n}}class is extends k{getBackgroundColor(t){return t.style.backgroundColor?wt.getColorKey(t.style.backgroundColor)||t.style.backgroundColor:null}getBorder(t){const e=t.style,n=e.borderStyle,s=e.borderWidth,o=e.borderColor;if(o||n||s){const t="initial"===o?"":o;return{style:"initial"===n?"":n,width:"initial"===s?"":s,color:wt.getColorKey(t)||t}}return null}getWidth(t){if(t.style.width)return t.style.width;const e=t.getAttribute("width");return e?/^\d+$/.test(e)?`${e}px`:e:null}getHeight(t){if(t.style.height)return t.style.height;const e=t.getAttribute("height");return e?/^\d+$/.test(e)?`${e}px`:e:null}}class rs extends is{canHandle(t){return"RTETableBlock"===t.name}handle(t){const e=ce({backgroundColor:this.getBackgroundColor(t),border:this.getBorder(t),width:this.getWidth(t),height:this.getHeight(t),alignment:this.getAlignment(t)});return Object.keys(e).length>0?{table:e}:{}}getAlignment(t){const e=t.classList;if(e.contains("v-rte--extension-table-align-left"))return"left";if(e.contains("v-rte--extension-table-align-center"))return"center";if(e.contains("v-rte--extension-table-align-right"))return"right";const n=t.style,s=n.marginLeft,o=n.marginRight;if("auto"===s&&"auto"===o)return"center";if("0"===s||"0px"===s)return"left";if("0"===o||"0px"===o)return"right";const i=t.getAttribute("align");return i&&["left","center","right"].includes(i)?i:null}}class as extends is{canHandle(t){return"RTETableCellBlock"===t.name}handle(t){const e=ce({backgroundColor:this.getBackgroundColor(t),padding:this.getPadding(t),border:this.getBorder(t),width:this.getWidth(t),height:this.getHeight(t),textAlign:this.getTextAlign(t),verticalAlign:this.getVerticalAlign(t),minWidth:this.getMinWidth(t),boxSizing:this.getBoxSizing(t)});return Object.keys(e).length>0?{tableCell:e}:{}}getMinWidth(t){return t.style.minWidth?t.style.minWidth:null}getBoxSizing(t){return t.style.boxSizing?t.style.boxSizing:null}getPadding(t){return t.style.padding?t.style.padding:null}getTextAlign(t){if(t.style.textAlign){const e=t.style.textAlign;if(["left","center","right","justify"].includes(e))return e}const e=t.getAttribute("align");return e&&["left","center","right","justify"].includes(e)?e:null}getVerticalAlign(t){if(t.style.verticalAlign){const e=t.style.verticalAlign;if(["top","middle","bottom"].includes(e))return e}return null}}class ls extends as{canHandle(t){return"RTETableHeadCellBlock"===t.name}}class cs extends D{handleAction(t,e){const n=t.toAnnotation(),s=this.getDOMByEntity(e);if(s){const t=s.closest(".v-rte--extension-table-container"),{backgroundColorAnnotation:o,width:i,height:r}=n;s.style.backgroundColor=o.renderStyle().color,s.style.border=n.borderStr,s.style.width=i,s.style.height=r;const a=n.renderAlignmentStyle().margin;s.style.margin=a,t&&(t.style.width=i,t.style.height=r,t.style.margin=a),this.updateCustomStyleAnnotation(e,["backgroundColor","border","width","height","margin"])}}}class hs extends D{handleAction(t,e){const n=t.toAnnotation(),s=this.getDOMByEntity(e);if(s){const{width:t,height:o,borderStr:i,padding:r,textAlign:a,verticalAlign:l}=n,c=n.renderStyle().backgroundColor||"";s.style.backgroundColor=c,s.style.border=i,s.style.width=t,s.style.height=o,s.style.padding=r,s.style.textAlign=a,s.style.verticalAlign=l,this.updateCustomStyleAnnotation(e,["backgroundColor","border","width","height","padding","textAlign","verticalAlign"])}}}class ds extends D{handleAction(t,e){const n=e.parent,s=n.parent,o=Tt(n,yt),i=kt(o),r=i.indexOf(n),{colSpan:a,rowSpan:l}=_t(e),c=Pt(e,i),h=Math.ceil(l/2),d=Math.max(1,l-h),u=1===l;Rt(e,a,h,o);const p=r+h,f=Mt(e.type);if(Rt(f,a,d,o),u){const t=this.createNewRowWithCell(s,f),r=s.children.indexOf(n);s.apply(new V(s.children[r],t)),i.splice(p,0,t),this.updateCellsSpanningThroughInsertionPoint(i,p,e,o)}else{const t=i[p],e=this.findInsertPosition(t,c,i,p);t.children.splice(e,0,f),f.parent=t}}findInsertPosition(t,e,n,s){let o=0;for(let t=0;t<s;t++){const i=n[t];for(const r of i.children){const{colSpan:i,rowSpan:a}=_t(r);t+a>s&&Pt(r,n)<e&&(o+=i)}}let i=o;for(let n=0;n<t.children.length;n++){if(i>=e)return n;const s=t.children[n],{colSpan:o}=_t(s);i+=o}return t.children.length}createNewRowWithCell(e,n){const s={id:t(),type:"table-row",children:[]},o=Vt.from(s);return o.parent=e,o.children.push(n),n.parent=o,o}updateCellsSpanningThroughInsertionPoint(t,e,n,s){for(let o=0;o<e;o++){const i=t[o];for(const t of i.children){if(t===n)continue;const{colSpan:i,rowSpan:r}=_t(t);o+r>=e&&Rt(t,i,r+1,s)}}}}class us extends D{handleAction(t,e){const n=e.parent,s=Tt(n,yt),o=kt(s),i=o.indexOf(n),{colSpan:r,rowSpan:a}=_t(e),l=Pt(e,o),c=l+r-1,h=Math.ceil(r/2),d=Math.floor(r/2);Rt(e,h,a,s);const u=Mt(e.type);Rt(u,d,a,s),n.apply(new V(e,u));const p=1===r?1:0;p>0&&this.updateOtherRowsCells(o,i,l,c,a,p,s)}updateOtherRowsCells(t,e,n,s,o,i,r){for(let a=0;a<t.length;a++){const l=t[a];if(!(a>=e&&a<e+o))for(const e of l.children){const o=Pt(e,t),{colSpan:a,rowSpan:l}=_t(e);if(o+a-1>=n&&o<=s){Rt(e,a+i,l,r);break}}}}}class ps extends Hn{handleAction(e,n){const{selectedRows:s}=e,o=s[s.length-1];let i=n.children.find((t=>t instanceof xt));const r={id:t(),type:"table-row",children:[]};let a=0,l=null;i?(l=i.children[0],a=this.getHeadCellLength(l)):(i=xt.from({id:t(),type:"table-body",children:[]}),n.apply(new P([i])));const c=o.parent.children,h=this.getRowsMaxCellCount(c);if(this.getRowsMaxCellCount([o])<h){const t=c.indexOf(o),e=this.getRowCellStartCols(c),n=new Map;for(let s=0;s<h;s++){const o=s<a?"table-head-cell":"table-cell",{cell:i}=this.getTheStartSpanCell(c,e,t,s);if(i){const t=i.colSpan;n.set(s,this.getDefaultCellBlockTemplate(o,t)),s+=t-1}}r.children=this.getSortedValuesByNumericKey(n)}else r.children=this.createTableCells(o,a);const d=l?new F(l,Vt.from(r)):new P([Vt.from(r)]);i.apply(d)}createTableCells(t,e){const n=[];let s=0;for(const o of t.children)n.push(this.getDefaultCellBlockTemplate(s<e?"table-head-cell":"table-cell",o.colSpan)),s+=o.colSpan;return n}}class fs extends Hn{handleAction(e){const{insertDirection:n,selectedRows:s}=e,o=n===Ht.ABOVE?s[0]:s[s.length-1],i={id:t(),type:"table-row",children:[]},r=o.parent.children,a=this.getRowsMaxCellCount(r),l=r.indexOf(o),c=this.getRowCellStartCols(r),h=new Map;for(let t=0;t<a;t++){const{cell:e,rowIndex:s}=this.getTheStartSpanCell(r,c,l,t);if(e){const{colSpan:o,rowSpan:i}=e;if(n===Ht.ABOVE?s!==l:s+i>l+1){this.updateCellSpan(e,"rowspan",i+1),t+=o-1;continue}h.set(t,this.getDefaultCellBlockTemplate(e.type,o)),t+=o-1}}i.children=this.getSortedValuesByNumericKey(h);const d=Vt.from(i),u=n===Ht.ABOVE?new F(o,d):new V(o,d);o.parent.apply(u)}}class gs extends Xe{canIntercept(t,e){return Boolean(e.parent)}intercept(t,e,n){const s=this.createNewParagraph("");s&&(n.parent.apply(0===e.startOffset?new F(n,s):new V(n,s)),e.newBlock=s)}createNewParagraph(e){const n=L.getRTEBlockClass("paragraph");if(n)return n.from({id:t(),type:"paragraph",nodes:[{id:t(),type:"text",text:e}]})}}class bs extends De{constructor(t=Ft){super(),this.toolbarButtonRenderer=new Nn,this.tableBlockRenderer=new kn,this.tableRowBlockRenderer=new Rn,this.tableCellRenderer=new On,this.tableHeadCellRenderer=new Ln,this.tableSelection=new Kn,wt.setTableColors(t),this.registerToolbarButtonRenderer("table",this.toolbarButtonRenderer),this.registerBlockBasicStrategies(yt.name),this.registerBlockBasicStrategies(Ct.name),this.registerBlockBasicStrategies(bt.name),this.registerBlockBasicStrategies(Vt.name),this.registerBlockBasicStrategies(vt.name),this.registerBlockBasicStrategies(xt.name),this.registerRenderer("table-block",this.tableBlockRenderer),this.registerRenderer("table-head",new An),this.registerRenderer("table-head-cell",this.tableHeadCellRenderer),this.registerRenderer("table-row",this.tableRowBlockRenderer),this.registerRenderer("table-cell",this.tableCellRenderer),this.registerRenderer("table-body",new In),this.registerRenderer("table-caption",new Pn),this.registerNode("table-block",yt),this.registerNode("table-head",Ct),this.registerNode("table-head-cell",bt),this.registerNode("table-row",Vt),this.registerNode("table-cell",vt),this.registerNode("table-body",xt),this.registerNode("table-caption",RTETableCaptionBlock),this.registerElementToBlockDTOClassStrategy(new Yn),this.registerElementToBlockDTOClassStrategy(new ts),this.registerElementToBlockDTOClassStrategy(new es),this.registerElementToBlockDTOClassStrategy(new ns),this.registerElementToBlockDTOClassStrategy(new ss),this.registerElementToBlockDTOClassStrategy(new os),this.registerAnnotationHandler(new rs),this.registerAnnotationHandler(new as),this.registerAnnotationHandler(new ls)}initialExtension(t){this.tableSelection.init(t);const e=Object.assign(Object.assign({},t),{tableSelection:this.tableSelection});super.initialExtension(e)}destroyExtension(){this.tableSelection.destroy()}}(()=>{const t=new _n,e=new Dn;De.registerActionHandleStrategy(m.name,"INSERT_TABLE_BLOCK",t),De.registerActionHandleStrategy(m.name,"DELETE_TABLE_BLOCK",e),De.registerActionHandleStrategy(vt.name,"DELETE_TABLE_BLOCK",e),De.registerActionHandleStrategy(bt.name,"DELETE_TABLE_BLOCK",e),De.registerActionHandleStrategy(_.name,"INSERT_TABLE_BLOCK",t),De.registerActionHandleStrategy(T.name,"INSERT_TABLE_BLOCK",t),De.registerActionHandleStrategy(yt.name,Kt,new ps),De.registerActionHandleStrategy(yt.name,$t,new fs),De.registerActionHandleStrategy(yt.name,zt,new Fn),De.registerActionHandleStrategy(yt.name,Wt,new $n),De.registerActionHandleStrategy(yt.name,Gt,new zn),De.registerActionHandleStrategy(yt.name,Ut,new Wn),De.registerActionHandleStrategy(yt.name,Zt,new Jt),De.registerActionHandleStrategy(Vt.name,Xt,new Jn),De.registerActionHandleStrategy(Vt.name,"CREATE_SEGMENT_TABLE_CELL",new Un),De.registerActionHandleStrategy(Vt.name,qt,new Zn),De.registerActionHandleStrategy(vt.name,Qt,new ds),De.registerActionHandleStrategy(vt.name,Yt,new us),De.registerActionHandleStrategy(bt.name,Qt,new ds),De.registerActionHandleStrategy(bt.name,Yt,new us),De.registerActionHandleStrategy(yt.name,te,new Xn),De.registerActionHandleStrategy(yt.name,ee,new Qn),De.registerActionHandleStrategy(yt.name,fn.name,new cs),De.registerActionHandleStrategy(vt.name,yn.name,new hs),De.registerActionHandleStrategy(bt.name,mn.name,new hs),De.registerActionHandlerInterceptor(_.name,$.DELETE_BLOCK_CONTENT,new Mn),De.registerActionHandlerInterceptor(Vt.name,$.INSERT_CHILDREN_BEFORE,new qn),De.registerActionHandlerInterceptor(vt.name,$.DELETE_CHILDREN,new Vn),De.registerActionHandlerInterceptor(bt.name,$.DELETE_CHILDREN,new Vn),De.registerActionHandlerInterceptor(yt.name,$.INSERT_NEW_PARAGRAPH,new gs)})();class ws extends B{constructor(t,e){super(),this.type=$.INSERT_NODE_TO_NEAREST_ROOT,this.rteRange=t,this.nodeToBeInserted=e}}class ys extends D{handleAction(e,n){const{rteRange:s,token:o}=e;if(s&&s.startNode){const{key:i,label:r,customAttrs:a={wrapped:"true"}}=o,l=new RTETokenNode(t(),i,r,n);l.annotationMap.set("CUSTOM_ATTRIBUTE",new Z(a)),n.apply(new ws(s,l)),e.actionHandleResult=!0}}}const ms=new class extends C{canHandle(t,e){const n=t[e];return"SPAN"===n.nodeName&&n.classList.contains("token")&&n.hasAttribute("token-key")?1:0}handle(e){const n=e[0],s=n.getAttribute("token-key"),o=n.textContent,i=w.generate(j,n),{customAttribute:r}=i,a=function(t,e){var n={};for(var s in t)Object.prototype.hasOwnProperty.call(t,s)&&e.indexOf(s)<0&&(n[s]=t[s]);if(null!=t&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(s=Object.getOwnPropertySymbols(t);o<s.length;o++)e.indexOf(s[o])<0&&Object.prototype.propertyIsEnumerable.call(t,s[o])&&(n[s[o]]=t[s[o]])}return n}(i,["customAttribute","customClass"]);return{id:t(),type:"token",token:s,text:o,annotations:Object.assign(Object.assign({},a),{customAttribute:this.createCustomAttrs(r)})}}appendChildBlocks(){}shouldProceedToElementChildren(){return!1}createCustomAttrs(t){const e=Object.assign(Object.assign({},t),{contenteditable:null,"template-token-key":null,"token-key":null,wrapped:"false"===t.wrapped?"false":"true"});return ce(e)}};class vs extends De{constructor(t=[]){super(),this.tokenRenderer=new Fe,this.registerNode("token",RTETokenNode),this.registerRenderer("token",this.tokenRenderer),this.tokenToolbarButtonRenderer=new He(t),this.registerToolbarButtonRenderer("token",this.tokenToolbarButtonRenderer),this.registerElementToNodeDTOClassStrategy(ms)}}(()=>{const t=new ys;De.registerActionHandleStrategy(_.name,"INSERT_TOKEN_NODE",t),De.registerActionHandleStrategy(A.name,"INSERT_TOKEN_NODE",t)})();export{Xe as A,ws as I,He as R,fe as V,ye as a,Ce as b,Ee as c,Le as d,Ne as e,vs as f,$e as g,rn as h,bs as i,De as j,Me as k,Ve as l,RTETokenNode as m,Fe as n,Ke as o,Re as w}
@@ -0,0 +1 @@
1
+ import{M as t,V as i}from"./p-6e1ab235.js";import{l as s,e}from"./p-dcd18ab1.js";import{S as n}from"./p-1fb56e14.js";import{O as a}from"./p-331a62d5.js";import{C as o}from"./p-2d0d575f.js";import{C as c}from"./p-33860e54.js";import{d as h}from"./p-878851f6.js";var l=function(t,i,s,e){var n,a=arguments.length,o=a<3?i:null===e?e=Object.getOwnPropertyDescriptor(i,s):e;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)o=Reflect.decorate(t,i,s,e);else for(var c=t.length-1;c>=0;c--)(n=t[c])&&(o=(a<3?n(o):a>3?n(i,s,o):n(i,s))||o);return a>3&&o&&Object.defineProperty(i,s,o),o};const r=["a[href]","area[href]","button","input","select","textarea","iframe","object","embed",'[contenteditable="true"]','[contenteditable=""]',"[tabindex]"].join(",");class d extends i{constructor(t){super(),this.isVoiceOverClick=!1,this.focusTriggerElement=null,this.focusDialogTaskQueue=new n,this.dialogContentReadyObserver=null,this.dialogContentReadySubject=null,this.isChildFocused=!1,this.eventListenerHandler=()=>{(this.entry.triggerEl()||window).addEventListener("click",this.handleClickEvent,{capture:!0})},this.eventListenerRemover=()=>{const t=this.entry.triggerEl();t&&t.removeEventListener("click",this.handleClickEvent,{capture:!0}),window.removeEventListener("click",this.handleClickEvent,{capture:!0})},this.handleClickEvent=t=>{this.isVoiceOverClick=s(t),this.isVoiceOverClick||(this.focusTriggerElement=null)},this.getFirstFocusableElement=t=>{const i=t=>{if(t instanceof HTMLElement&&this.isFocusableElement(t))return t;const s=Array.from(t.querySelectorAll("*"));for(const t of s){if(this.isFocusableElement(t))return t;if(t.shadowRoot){const s=i(t.shadowRoot);if(s)return s}}return null};return t instanceof HTMLElement&&t.shadowRoot?this.isFocusableElement(t)?t:i(t)||i(t.shadowRoot):i(t)},this.isFocusableElement=t=>!!t.matches(r)&&!t.hasAttribute("disabled")&&!t.hasAttribute("inert")&&"true"!==t.getAttribute("aria-hidden")&&!(t instanceof HTMLInputElement&&"hidden"===t.type)&&t.tabIndex>=0,this.focusOnFirstFocusableElement=()=>{if(!this.isChildFocused){const t=this.entry.dialogEl(),i=this.getFirstFocusableElement(t);i?(this.isChildFocused=!0,i.focus()):t.focus()}},this.entry=t}connectedCallback(){this.eventListenerHandler(),this.subscribeDialogContentReady()}disconnectedCallback(){this.eventListenerRemover(),this.unsubscribeDialogContentReady()}componentDidLoad(){this.eventListenerHandler(),this.subscribeDialogContentReady()}async componentDidRender(){await this.focusDialogTaskQueue.runTask()}async toggle(t){t?await this.show():await this.hide()}async show(){const t=e(document,!0);t&&(this.isChildFocused=!1,await this.focusDialogTaskQueue.enqueue({run:async()=>{this.isVoiceOverClick&&(this.focusTriggerElement=t,this.focusOnFirstFocusableElement())}},!1))}async hide(){this.focusTriggerElement&&await this.focusDialogTaskQueue.enqueue({run:async()=>{this.focusTriggerElement&&this.focusTriggerElement.focus(),this.focusTriggerElement=null}},!1)}subscribeDialogContentReady(){this.entry.dialogEl()&&!this.dialogContentReadySubject&&(this.dialogContentReadySubject=h.getSubject(this.entry.dialogEl(),c),this.dialogContentReadyObserver=new a((()=>!0),(()=>{this.isVoiceOverClick&&this.focusOnFirstFocusableElement()})),o.register(this.dialogContentReadySubject,this.dialogContentReadyObserver))}unsubscribeDialogContentReady(){this.dialogContentReadyObserver&&this.dialogContentReadySubject&&(o.unregister(this.dialogContentReadySubject,this.dialogContentReadyObserver),this.dialogContentReadyObserver=null,this.dialogContentReadySubject=null)}}l([t("connectedCallback")],d.prototype,"connectedCallback",null),l([t("disconnectedCallback")],d.prototype,"disconnectedCallback",null),l([t("componentDidLoad")],d.prototype,"componentDidLoad",null),l([t("componentDidRender")],d.prototype,"componentDidRender",null);export{d as A}
@@ -1 +1 @@
1
- import{h as t,r as e,c as i,H as s,g as a}from"./p-6b2342e0.js";import{C as o}from"./p-2d0d575f.js";import{d as r,e as n,F as l,b as c,a as d,c as h}from"./p-a528714c.js";import{s as m}from"./p-519a7d55.js";import{c as u,M as f,V as p,I as v}from"./p-6e1ab235.js";import{m as b}from"./p-6bd5c49b.js";import{V as j,I as g}from"./p-4415ad28.js";import{c as V}from"./p-a6fb81c5.js";import{C as F}from"./p-68a531cf.js";import{B as w,C as y,D as C}from"./p-c5eb0fa6.js";import{c as R}from"./p-8cd70b3b.js";import{S as O}from"./p-6e05fc55.js";import{F as S}from"./p-a0a39ec3.js";import{t as k}from"./p-b75ee3ba.js";import{f as E,i as M,g as B}from"./p-6554a801.js";import{d as P}from"./p-4068e7de.js";import{O as I}from"./p-331a62d5.js";import{f as N,b as A,d as x}from"./p-d6875e49.js";import{i as D}from"./p-6d6ea8b4.js";import{I as H}from"./p-b28d4f7d.js";import{C as $}from"./p-4e15958f.js";import{d as T}from"./p-d27ae9ff.js";import"./p-6a334573.js";import"./p-3d2d267d.js";import"./p-5f377954.js";import"./p-18e8d9b7.js";import"./p-5a25014f.js";import"./p-02841589.js";import"./p-8b5d3a52.js";import"./p-82016096.js";import"./p-f0e828d8.js";import"./p-81dd00d0.js";import"./p-49a2e141.js";import"./p-d4ea8e22.js";import"./p-ed45b3b6.js";import"./p-abd7aeaa.js";import"./p-78a57a17.js";import"./p-52b8f2d2.js";import"./p-d884c644.js";import"./p-262ec334.js";var W=function(t,e,i,s){var a,o=arguments.length,r=o<3?e:null===s?s=Object.getOwnPropertyDescriptor(e,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)r=Reflect.decorate(t,e,i,s);else for(var n=t.length-1;n>=0;n--)(a=t[n])&&(r=(o<3?a(r):o>3?a(e,i,r):a(e,i))||r);return o>3&&r&&Object.defineProperty(e,i,r),r};class G extends O{constructor(){super({parent:"vega-form",subStates:[{subStateName:"disableBlurValidation",parentStateName:"disableBlurValidation"}]})}}W([u()],G.prototype,"host",void 0),W([u({writable:!0})],G.prototype,"disableBlurValidation",void 0);var U=function(t,e,i,s){var a,o=arguments.length,r=o<3?e:null===s?s=Object.getOwnPropertyDescriptor(e,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)r=Reflect.decorate(t,e,i,s);else for(var n=t.length-1;n>=0;n--)(a=t[n])&&(r=(o<3?a(r):o>3?a(e,i,r):a(e,i))||r);return o>3&&r&&Object.defineProperty(e,i,r),r};class _ extends p{setValidationStates(t){0!==t.length?t.forEach((t=>{const e=this.getHostByFieldName(t.fieldName);e&&this.updateFieldValidationState(e,{isValid:t.isValid,errorMessage:t.isValid?"":t.errorMessage})})):Array.from(this.host.querySelectorAll("[data-vega-form]")).filter((t=>S.isValidFormField(t))).forEach((t=>{this.updateFieldValidationState(t,{isValid:!0})}))}getHostByFieldName(t){const e=t.split(".");let i=this.host;for(const t of e){const e=i.querySelector(`[data-vega-form="${t}"]`);if(!S.isValidFormField(e))return null;i=e}return i}updateFieldValidationState(t,{isValid:e,errorMessage:i}){t.isValid=e,o.notify(r,{host:t,message:e?"":i,isValid:e}),o.notify(n,{host:t,detail:e})}}U([u()],_.prototype,"host",void 0),U([f("setValidationStates")],_.prototype,"setValidationStates",null);var q=function(t,e,i,s){var a,o=arguments.length,r=o<3?e:null===s?s=Object.getOwnPropertyDescriptor(e,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)r=Reflect.decorate(t,e,i,s);else for(var n=t.length-1;n>=0;n--)(a=t[n])&&(r=(o<3?a(r):o>3?a(e,i,r):a(e,i))||r);return o>3&&r&&Object.defineProperty(e,i,r),r};class z extends p{getNativeFormRef(){return this.nativeFormRef}render(){return t("form",{action:this.action,method:this.method,ref:t=>{t&&(this.nativeFormRef=t)}},t("slot",null))}}q([u()],z.prototype,"method",void 0),q([u()],z.prototype,"action",void 0);var J=function(t,e,i,s){var a,o=arguments.length,r=o<3?e:null===s?s=Object.getOwnPropertyDescriptor(e,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)r=Reflect.decorate(t,e,i,s);else for(var n=t.length-1;n>=0;n--)(a=t[n])&&(r=(o<3?a(r):o>3?a(e,i,r):a(e,i))||r);return o>3&&r&&Object.defineProperty(e,i,r),r};class K extends p{connectedCallback(){this.registerFormSubmitChangeManager()}disconnectedCallback(){this.unregisterFormSubmitChangeManager()}async submitWithFormData(){if(!this.useNativeForm)return;const t=await this.host.getValue();for(const e in t)if("object"==typeof t[e]){const i=this.flattenObjectWithBrackets({[e]:t[e]});for(const t in i){const e=this.createHiddenInput(t,i[t]);this.nativeFormRenderer.getNativeFormRef().append(e)}}else{const i=this.createHiddenInput(e,t[e]);this.nativeFormRenderer.getNativeFormRef().append(i)}this.nativeFormRenderer.getNativeFormRef().requestSubmit()}createHiddenInput(t,e){const i=k().createElement("input");return i.type="hidden",i.name=t,i.value=D(e)?String(e):"",i}registerFormSubmitChangeManager(){var t;this.formSubmitEventObserver=new I(this.canAcceptFormSubmitEvent.bind(this),this.handleSubmitEvents.bind(this));const e=null!==(t=N(this.host,"vega-form",{outerMost:!0}))&&void 0!==t?t:this.host;o.register(P.getSubject(e,E),this.formSubmitEventObserver)}unregisterFormSubmitChangeManager(){var t;const e=null!==(t=N(this.host,"vega-form",{outerMost:!0}))&&void 0!==t?t:this.host;o.unregister(P.getSubject(e,E),this.formSubmitEventObserver)}canAcceptFormSubmitEvent(t){return this.vegaFormFieldController.isElementInCurrentForm(t.host)}async handleSubmitEvents(){if((await this.host.valid()).isValid){const t=await this.host.getValue();this.submitEventEmitter.emit(t).defaultPrevented||await this.submitWithFormData()}}flattenObjectWithBrackets(t,e="",i={}){return Object.entries(t).forEach((([t,s])=>{const a=e?`${e}[${t}]`:t;Array.isArray(s)?s.forEach(((t,e)=>{const s=`${a}[${e}]`;"object"==typeof t&&null!==t?this.flattenObjectWithBrackets(t,s,i):i[s]=t})):D(s)&&"object"==typeof s?this.flattenObjectWithBrackets(s,a,i):i[a]=s})),i}}J([u()],K.prototype,"host",void 0),J([u()],K.prototype,"useNativeForm",void 0),J([u()],K.prototype,"nativeFormRenderer",void 0),J([u()],K.prototype,"submitEventEmitter",void 0),J([u()],K.prototype,"vegaFormFieldController",void 0),J([f("connectedCallback")],K.prototype,"connectedCallback",null),J([f("disconnectedCallback")],K.prototype,"disconnectedCallback",null);var L=function(t,e,i,s){var a,o=arguments.length,r=o<3?e:null===s?s=Object.getOwnPropertyDescriptor(e,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)r=Reflect.decorate(t,e,i,s);else for(var n=t.length-1;n>=0;n--)(a=t[n])&&(r=(o<3?a(r):o>3?a(e,i,r):a(e,i))||r);return o>3&&r&&Object.defineProperty(e,i,r),r};class Q extends p{constructor(){super(...arguments),this.childNotifyObserver=new $(n,(t=>this.updateInternalValidStatus(t))),this.childNodeValueChangeObserver=new $(l,(()=>{this.isTouched=!0})),this._invalidFieldPathMap=new H(new Map,(t=>{this._invalidFieldPathMap=t,this.updateIsValidFlag()})),this._pendingValidFieldPathMap=new H(new Map,(t=>{this._pendingValidFieldPathMap=t,this.updateIsValidFlag()})),this.updateInternalValidStatus=t=>{if(t.host!==this.host){const e=t.host,i=t.detail;S.isValidFormField(e)&&this.shouldVisitElement(e,!1,!1)&&(i?this.invalidFieldPathMap.delete(e):this.invalidFieldPathMap.set(e,e.dataset.vegaForm))}}}connectedCallback(){this.initFormFieldDisconnectedObserver(),this.registerFormFieldPendingValid()}disconnectedCallback(){o.notify(c,{host:this.host}),o.unregister(c,this.formFieldDisconnectedObserver),o.unregister(d,this.formFieldPendingValidObserver)}async getValue(t){const e={};return await this.navigateVegaFormChildren((async(i,s)=>{const a=this.getFormFieldName(i);e[a]=s?await i.getValue(t):this.getFormFieldValue(i)}),t),T(e)?Object.values(e):e}async setValue(t,e){t&&(await this.navigateVegaFormChildren((async(i,s)=>{const a=this.getFormFieldName(i);s?await i.setValue(t[a],e):(await i.componentOnReady(),void 0!==t[a]&&("function"==typeof i.setValue?await i.setValue(t[a]):i.value=t[a]))}),e),this.isTouched=!1)}async valid(t=!0){const e={isValid:!0,invalidFields:[]};return await this.navigateVegaFormChildren((async(i,s)=>{if("function"==typeof i.valid&&s){const s=await i.valid(t);s.isValid||(e.isValid=!1,e.invalidFields.push(...s.invalidFields),e.invalidFieldsErrorMessages=Object.assign(Object.assign({},e.invalidFieldsErrorMessages),s.invalidFieldsErrorMessages))}else{const{isValid:s,message:a}=await this.handleChildFormFieldElementValid(i,t);s||(e.isValid=!1,e.invalidFields.push(this.getFormFieldName(i)),e.invalidFieldsErrorMessages||(e.invalidFieldsErrorMessages={}),e.invalidFieldsErrorMessages[this.getFormFieldName(i)]=a)}})),e}get invalidFieldPathMap(){return this._invalidFieldPathMap}get pendingValidFieldPathMap(){return this._pendingValidFieldPathMap}setIsTouched(t){this.isTouched=t}getFormFieldName(t){return t.dataset.vegaForm}isElementInCurrentForm(t){return this.invalidFieldPathMap.has(t)||A(t,this.host)}async navigateVegaFormChildren(t,e,i=this.host){const s=[];Array.from(i.children).forEach((i=>{S.isValidFormField(i)?this.shouldVisitElement(i,null==e?void 0:e.skipDisabled,null==e?void 0:e.skipInvisible)&&s.push(t(i,"VEGA-FORM"===i.tagName)):s.push(this.navigateVegaFormChildren(t,e,i))})),await Promise.all(s)}updateIsValidFlag(){this.isValid=this.pendingValidFieldPathMap.size>0?null:0===this.invalidFieldPathMap.size}registerFormFieldPendingValid(){this.formFieldPendingValidObserver=new I(this.canAcceptFormFieldPendingValid.bind(this),this.handleFieldPendingValid.bind(this)),o.register(d,this.formFieldPendingValidObserver)}canAcceptFormFieldPendingValid(t){return this.isElementInCurrentForm(t.host)}handleFieldPendingValid(t){"boolean"==typeof t.detail?this.pendingValidFieldPathMap.delete(t.host):this.pendingValidFieldPathMap.set(t.host,t.host.dataset.vegaForm)}initFormFieldDisconnectedObserver(){this.formFieldDisconnectedObserver=new I(this.canAcceptFormFieldDisconnectedOperation.bind(this),this.updateInvalidFieldPath.bind(this)),o.register(c,this.formFieldDisconnectedObserver)}canAcceptFormFieldDisconnectedOperation(t){return this.invalidFieldPathMap.has(t.host)}async updateInvalidFieldPath(t){this.invalidFieldPathMap.delete(t.host),this.pendingValidFieldPathMap.delete(t.host)}shouldVisitElement(t,e,i){return this.getFormFieldName(t)&&(!e||!t.disabled)&&(!i||x(t))}getFormFieldValue(t){return void 0===t.value?t.getAttribute("value"):t.value}async handleChildFormFieldElementValid(t,e){const i=P.getSubject(t,M),{isValid:s,message:a}=await new Promise((s=>{const a=setTimeout((()=>{s({isValid:!0,message:""})}),2e3);o.notify(i,{host:t,message:e,promiseResolve:s,timerId:a})}));return{isValid:s,message:a}}}L([u()],Q.prototype,"host",void 0),L([u({writable:!0})],Q.prototype,"isValid",void 0),L([u({writable:!0})],Q.prototype,"isTouched",void 0),L([v()],Q.prototype,"childNotifyObserver",void 0),L([v()],Q.prototype,"childNodeValueChangeObserver",void 0),L([f("connectedCallback")],Q.prototype,"connectedCallback",null),L([f("disconnectedCallback")],Q.prototype,"disconnectedCallback",null),L([f("getValue")],Q.prototype,"getValue",null),L([f("setValue")],Q.prototype,"setValue",null),L([f("valid")],Q.prototype,"valid",null);var X=function(t,e,i,s){var a,o=arguments.length,r=o<3?e:null===s?s=Object.getOwnPropertyDescriptor(e,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)r=Reflect.decorate(t,e,i,s);else for(var n=t.length-1;n>=0;n--)(a=t[n])&&(r=(o<3?a(r):o>3?a(e,i,r):a(e,i))||r);return o>3&&r&&Object.defineProperty(e,i,r),r};class Y extends p{connectedCallback(){this.registerFormResetChangeManager()}disconnectedCallback(){this.unregisterFormResetChangeManager()}async reset(t={},e){await this.vegaFormFieldController.navigateVegaFormChildren((async(i,s)=>{const a=this.vegaFormFieldController.getFormFieldName(i);s&&await i.reset(t[a]||{},e)}),e),o.notify(h,{host:this.host,defaultValueMap:t,option:e}),this.vegaFormFieldController.setIsTouched(!1)}registerFormResetChangeManager(){var t;const e=null!==(t=N(this.host,"vega-form",{outerMost:!0}))&&void 0!==t?t:this.host;this.formResetEventObserver=new I(this.canAcceptFormResetEvent.bind(this),this.handleResetEvents.bind(this)),o.register(P.getSubject(e,B),this.formResetEventObserver)}unregisterFormResetChangeManager(){var t;const e=null!==(t=N(this.host,"vega-form",{outerMost:!0}))&&void 0!==t?t:this.host;o.unregister(P.getSubject(e,B),this.formResetEventObserver)}canAcceptFormResetEvent(t){return this.vegaFormFieldController.isElementInCurrentForm(t.host)}async handleResetEvents(){await this.host.reset(),this.resetEventEmitter.emit()}}X([u()],Y.prototype,"host",void 0),X([u()],Y.prototype,"vegaFormFieldController",void 0),X([u()],Y.prototype,"resetEventEmitter",void 0),X([f("connectedCallback")],Y.prototype,"connectedCallback",null),X([f("disconnectedCallback")],Y.prototype,"disconnectedCallback",null),X([f("reset")],Y.prototype,"reset",null);var Z=function(t,e,i,s){var a,o=arguments.length,r=o<3?e:null===s?s=Object.getOwnPropertyDescriptor(e,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)r=Reflect.decorate(t,e,i,s);else for(var n=t.length-1;n>=0;n--)(a=t[n])&&(r=(o<3?a(r):o>3?a(e,i,r):a(e,i))||r);return o>3&&r&&Object.defineProperty(e,i,r),r};const tt=class{constructor(t){e(this,t),this.vegaValidate=i(this,"vegaValidate",7),this.validate=i(this,"validate",7),this.vegaFormSubmit=i(this,"vegaFormSubmit",7),this.formSubmit=i(this,"formSubmit",7),this.vegaFormReset=i(this,"vegaFormReset",7),this.formReset=i(this,"formReset",7),this.globalSlimmers={},this.submitEventEmitter=V(tt,w),this.resetEventEmitter=V(tt,y),this.validateEventEmitter=V(tt,C),this.disableBlurValidationNotifySlimmer=R(tt,"disableBlurValidation","watchDisableBlurValidation"),this.stateController=new G,this.childEventPrevent=new F([w,y],(()=>this.host.querySelector("vega-form")),{customPreventHandle:t=>{t.stopPropagation()}}),this.childFormValidateEventPrevent=new F([C],(()=>this.host),{customPreventHandle:t=>{t.stopPropagation()}}),this.vegaComponentUsageRuntimeMetricsSlimmer=new j,this.vegaFormFieldValidationStateController=new _,this.nativeFormRenderer=new z,this.vegaFormSubmitController=new K,this.vegaFormResetController=new Y,this.vegaFormFieldController=new Q,this.isValid=null,this.isTouched=!1,this.disableBlurValidation=!1,this.useNativeForm=!1,this.method="get"}watchIsValid(){this.validateEventEmitter.emit(this.isValid),o.notify(n,{host:this.host,detail:this.isValid})}watchDisableBlurValidation(){}async valid(t=!0){return b(t)}async getValue(t){return b(t)}async setValue(t,e){}async reset(t={},e){}async setValidationStates(t){}render(){return m(t(s,null,this.useNativeForm?this.nativeFormRenderer.render():t("slot",null)),this.host)}get host(){return a(this)}static get watchers(){return{isValid:["watchIsValid"],disableBlurValidation:["watchDisableBlurValidation"]}}};Z([g()],tt.prototype,"globalSlimmers",void 0),Z([v()],tt.prototype,"submitEventEmitter",void 0),Z([v()],tt.prototype,"resetEventEmitter",void 0),Z([v()],tt.prototype,"validateEventEmitter",void 0),Z([v()],tt.prototype,"disableBlurValidationNotifySlimmer",void 0),Z([v()],tt.prototype,"stateController",void 0),Z([v()],tt.prototype,"childEventPrevent",void 0),Z([v()],tt.prototype,"childFormValidateEventPrevent",void 0),Z([v()],tt.prototype,"vegaComponentUsageRuntimeMetricsSlimmer",void 0),Z([v()],tt.prototype,"vegaFormFieldValidationStateController",void 0),Z([v()],tt.prototype,"nativeFormRenderer",void 0),Z([v()],tt.prototype,"vegaFormSubmitController",void 0),Z([v()],tt.prototype,"vegaFormResetController",void 0),Z([v()],tt.prototype,"vegaFormFieldController",void 0),tt.style=":host{display:block}";export{tt as vega_form}
1
+ import{h as t,r as e,c as i,H as s,g as a}from"./p-6b2342e0.js";import{C as o}from"./p-2d0d575f.js";import{d as r,e as n,F as l,b as c,a as d,c as h}from"./p-a528714c.js";import{s as m}from"./p-519a7d55.js";import{c as u,M as f,V as p,I as v}from"./p-6e1ab235.js";import{m as b}from"./p-6bd5c49b.js";import{V as j,I as g}from"./p-4415ad28.js";import{c as V}from"./p-d1ca70a1.js";import{C as F}from"./p-68a531cf.js";import{B as w,C as y,D as C}from"./p-c5eb0fa6.js";import{c as R}from"./p-010b5e74.js";import{S as O}from"./p-576fe408.js";import{F as S}from"./p-b696a861.js";import{t as k}from"./p-b75ee3ba.js";import{f as E,i as M,g as B}from"./p-33860e54.js";import{d as P}from"./p-878851f6.js";import{O as I}from"./p-331a62d5.js";import{f as N,b as A,d as x}from"./p-dcd18ab1.js";import{i as D}from"./p-c6d62f0d.js";import{I as H}from"./p-b28d4f7d.js";import{C as $}from"./p-c9201bf4.js";import{d as T}from"./p-d27ae9ff.js";import"./p-6a334573.js";import"./p-3d2d267d.js";import"./p-5f377954.js";import"./p-18e8d9b7.js";import"./p-5a25014f.js";import"./p-02841589.js";import"./p-8b5d3a52.js";import"./p-82016096.js";import"./p-f0e828d8.js";import"./p-81dd00d0.js";import"./p-49a2e141.js";import"./p-d4ea8e22.js";import"./p-ed45b3b6.js";import"./p-abd7aeaa.js";import"./p-78a57a17.js";import"./p-52b8f2d2.js";import"./p-d884c644.js";import"./p-262ec334.js";var W=function(t,e,i,s){var a,o=arguments.length,r=o<3?e:null===s?s=Object.getOwnPropertyDescriptor(e,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)r=Reflect.decorate(t,e,i,s);else for(var n=t.length-1;n>=0;n--)(a=t[n])&&(r=(o<3?a(r):o>3?a(e,i,r):a(e,i))||r);return o>3&&r&&Object.defineProperty(e,i,r),r};class G extends O{constructor(){super({parent:"vega-form",subStates:[{subStateName:"disableBlurValidation",parentStateName:"disableBlurValidation"}]})}}W([u()],G.prototype,"host",void 0),W([u({writable:!0})],G.prototype,"disableBlurValidation",void 0);var U=function(t,e,i,s){var a,o=arguments.length,r=o<3?e:null===s?s=Object.getOwnPropertyDescriptor(e,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)r=Reflect.decorate(t,e,i,s);else for(var n=t.length-1;n>=0;n--)(a=t[n])&&(r=(o<3?a(r):o>3?a(e,i,r):a(e,i))||r);return o>3&&r&&Object.defineProperty(e,i,r),r};class _ extends p{setValidationStates(t){0!==t.length?t.forEach((t=>{const e=this.getHostByFieldName(t.fieldName);e&&this.updateFieldValidationState(e,{isValid:t.isValid,errorMessage:t.isValid?"":t.errorMessage})})):Array.from(this.host.querySelectorAll("[data-vega-form]")).filter((t=>S.isValidFormField(t))).forEach((t=>{this.updateFieldValidationState(t,{isValid:!0})}))}getHostByFieldName(t){const e=t.split(".");let i=this.host;for(const t of e){const e=i.querySelector(`[data-vega-form="${t}"]`);if(!S.isValidFormField(e))return null;i=e}return i}updateFieldValidationState(t,{isValid:e,errorMessage:i}){t.isValid=e,o.notify(r,{host:t,message:e?"":i,isValid:e}),o.notify(n,{host:t,detail:e})}}U([u()],_.prototype,"host",void 0),U([f("setValidationStates")],_.prototype,"setValidationStates",null);var q=function(t,e,i,s){var a,o=arguments.length,r=o<3?e:null===s?s=Object.getOwnPropertyDescriptor(e,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)r=Reflect.decorate(t,e,i,s);else for(var n=t.length-1;n>=0;n--)(a=t[n])&&(r=(o<3?a(r):o>3?a(e,i,r):a(e,i))||r);return o>3&&r&&Object.defineProperty(e,i,r),r};class z extends p{getNativeFormRef(){return this.nativeFormRef}render(){return t("form",{action:this.action,method:this.method,ref:t=>{t&&(this.nativeFormRef=t)}},t("slot",null))}}q([u()],z.prototype,"method",void 0),q([u()],z.prototype,"action",void 0);var J=function(t,e,i,s){var a,o=arguments.length,r=o<3?e:null===s?s=Object.getOwnPropertyDescriptor(e,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)r=Reflect.decorate(t,e,i,s);else for(var n=t.length-1;n>=0;n--)(a=t[n])&&(r=(o<3?a(r):o>3?a(e,i,r):a(e,i))||r);return o>3&&r&&Object.defineProperty(e,i,r),r};class K extends p{connectedCallback(){this.registerFormSubmitChangeManager()}disconnectedCallback(){this.unregisterFormSubmitChangeManager()}async submitWithFormData(){if(!this.useNativeForm)return;const t=await this.host.getValue();for(const e in t)if("object"==typeof t[e]){const i=this.flattenObjectWithBrackets({[e]:t[e]});for(const t in i){const e=this.createHiddenInput(t,i[t]);this.nativeFormRenderer.getNativeFormRef().append(e)}}else{const i=this.createHiddenInput(e,t[e]);this.nativeFormRenderer.getNativeFormRef().append(i)}this.nativeFormRenderer.getNativeFormRef().requestSubmit()}createHiddenInput(t,e){const i=k().createElement("input");return i.type="hidden",i.name=t,i.value=D(e)?String(e):"",i}registerFormSubmitChangeManager(){var t;this.formSubmitEventObserver=new I(this.canAcceptFormSubmitEvent.bind(this),this.handleSubmitEvents.bind(this));const e=null!==(t=N(this.host,"vega-form",{outerMost:!0}))&&void 0!==t?t:this.host;o.register(P.getSubject(e,E),this.formSubmitEventObserver)}unregisterFormSubmitChangeManager(){var t;const e=null!==(t=N(this.host,"vega-form",{outerMost:!0}))&&void 0!==t?t:this.host;o.unregister(P.getSubject(e,E),this.formSubmitEventObserver)}canAcceptFormSubmitEvent(t){return this.vegaFormFieldController.isElementInCurrentForm(t.host)}async handleSubmitEvents(){if((await this.host.valid()).isValid){const t=await this.host.getValue();this.submitEventEmitter.emit(t).defaultPrevented||await this.submitWithFormData()}}flattenObjectWithBrackets(t,e="",i={}){return Object.entries(t).forEach((([t,s])=>{const a=e?`${e}[${t}]`:t;Array.isArray(s)?s.forEach(((t,e)=>{const s=`${a}[${e}]`;"object"==typeof t&&null!==t?this.flattenObjectWithBrackets(t,s,i):i[s]=t})):D(s)&&"object"==typeof s?this.flattenObjectWithBrackets(s,a,i):i[a]=s})),i}}J([u()],K.prototype,"host",void 0),J([u()],K.prototype,"useNativeForm",void 0),J([u()],K.prototype,"nativeFormRenderer",void 0),J([u()],K.prototype,"submitEventEmitter",void 0),J([u()],K.prototype,"vegaFormFieldController",void 0),J([f("connectedCallback")],K.prototype,"connectedCallback",null),J([f("disconnectedCallback")],K.prototype,"disconnectedCallback",null);var L=function(t,e,i,s){var a,o=arguments.length,r=o<3?e:null===s?s=Object.getOwnPropertyDescriptor(e,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)r=Reflect.decorate(t,e,i,s);else for(var n=t.length-1;n>=0;n--)(a=t[n])&&(r=(o<3?a(r):o>3?a(e,i,r):a(e,i))||r);return o>3&&r&&Object.defineProperty(e,i,r),r};class Q extends p{constructor(){super(...arguments),this.childNotifyObserver=new $(n,(t=>this.updateInternalValidStatus(t))),this.childNodeValueChangeObserver=new $(l,(()=>{this.isTouched=!0})),this._invalidFieldPathMap=new H(new Map,(t=>{this._invalidFieldPathMap=t,this.updateIsValidFlag()})),this._pendingValidFieldPathMap=new H(new Map,(t=>{this._pendingValidFieldPathMap=t,this.updateIsValidFlag()})),this.updateInternalValidStatus=t=>{if(t.host!==this.host){const e=t.host,i=t.detail;S.isValidFormField(e)&&this.shouldVisitElement(e,!1,!1)&&(i?this.invalidFieldPathMap.delete(e):this.invalidFieldPathMap.set(e,e.dataset.vegaForm))}}}connectedCallback(){this.initFormFieldDisconnectedObserver(),this.registerFormFieldPendingValid()}disconnectedCallback(){o.notify(c,{host:this.host}),o.unregister(c,this.formFieldDisconnectedObserver),o.unregister(d,this.formFieldPendingValidObserver)}async getValue(t){const e={};return await this.navigateVegaFormChildren((async(i,s)=>{const a=this.getFormFieldName(i);e[a]=s?await i.getValue(t):this.getFormFieldValue(i)}),t),T(e)?Object.values(e):e}async setValue(t,e){t&&(await this.navigateVegaFormChildren((async(i,s)=>{const a=this.getFormFieldName(i);s?await i.setValue(t[a],e):(await i.componentOnReady(),void 0!==t[a]&&("function"==typeof i.setValue?await i.setValue(t[a]):i.value=t[a]))}),e),this.isTouched=!1)}async valid(t=!0){const e={isValid:!0,invalidFields:[]};return await this.navigateVegaFormChildren((async(i,s)=>{if("function"==typeof i.valid&&s){const s=await i.valid(t);s.isValid||(e.isValid=!1,e.invalidFields.push(...s.invalidFields),e.invalidFieldsErrorMessages=Object.assign(Object.assign({},e.invalidFieldsErrorMessages),s.invalidFieldsErrorMessages))}else{const{isValid:s,message:a}=await this.handleChildFormFieldElementValid(i,t);s||(e.isValid=!1,e.invalidFields.push(this.getFormFieldName(i)),e.invalidFieldsErrorMessages||(e.invalidFieldsErrorMessages={}),e.invalidFieldsErrorMessages[this.getFormFieldName(i)]=a)}})),e}get invalidFieldPathMap(){return this._invalidFieldPathMap}get pendingValidFieldPathMap(){return this._pendingValidFieldPathMap}setIsTouched(t){this.isTouched=t}getFormFieldName(t){return t.dataset.vegaForm}isElementInCurrentForm(t){return this.invalidFieldPathMap.has(t)||A(t,this.host)}async navigateVegaFormChildren(t,e,i=this.host){const s=[];Array.from(i.children).forEach((i=>{S.isValidFormField(i)?this.shouldVisitElement(i,null==e?void 0:e.skipDisabled,null==e?void 0:e.skipInvisible)&&s.push(t(i,"VEGA-FORM"===i.tagName)):s.push(this.navigateVegaFormChildren(t,e,i))})),await Promise.all(s)}updateIsValidFlag(){this.isValid=this.pendingValidFieldPathMap.size>0?null:0===this.invalidFieldPathMap.size}registerFormFieldPendingValid(){this.formFieldPendingValidObserver=new I(this.canAcceptFormFieldPendingValid.bind(this),this.handleFieldPendingValid.bind(this)),o.register(d,this.formFieldPendingValidObserver)}canAcceptFormFieldPendingValid(t){return this.isElementInCurrentForm(t.host)}handleFieldPendingValid(t){"boolean"==typeof t.detail?this.pendingValidFieldPathMap.delete(t.host):this.pendingValidFieldPathMap.set(t.host,t.host.dataset.vegaForm)}initFormFieldDisconnectedObserver(){this.formFieldDisconnectedObserver=new I(this.canAcceptFormFieldDisconnectedOperation.bind(this),this.updateInvalidFieldPath.bind(this)),o.register(c,this.formFieldDisconnectedObserver)}canAcceptFormFieldDisconnectedOperation(t){return this.invalidFieldPathMap.has(t.host)}async updateInvalidFieldPath(t){this.invalidFieldPathMap.delete(t.host),this.pendingValidFieldPathMap.delete(t.host)}shouldVisitElement(t,e,i){return this.getFormFieldName(t)&&(!e||!t.disabled)&&(!i||x(t))}getFormFieldValue(t){return void 0===t.value?t.getAttribute("value"):t.value}async handleChildFormFieldElementValid(t,e){const i=P.getSubject(t,M),{isValid:s,message:a}=await new Promise((s=>{const a=setTimeout((()=>{s({isValid:!0,message:""})}),2e3);o.notify(i,{host:t,message:e,promiseResolve:s,timerId:a})}));return{isValid:s,message:a}}}L([u()],Q.prototype,"host",void 0),L([u({writable:!0})],Q.prototype,"isValid",void 0),L([u({writable:!0})],Q.prototype,"isTouched",void 0),L([v()],Q.prototype,"childNotifyObserver",void 0),L([v()],Q.prototype,"childNodeValueChangeObserver",void 0),L([f("connectedCallback")],Q.prototype,"connectedCallback",null),L([f("disconnectedCallback")],Q.prototype,"disconnectedCallback",null),L([f("getValue")],Q.prototype,"getValue",null),L([f("setValue")],Q.prototype,"setValue",null),L([f("valid")],Q.prototype,"valid",null);var X=function(t,e,i,s){var a,o=arguments.length,r=o<3?e:null===s?s=Object.getOwnPropertyDescriptor(e,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)r=Reflect.decorate(t,e,i,s);else for(var n=t.length-1;n>=0;n--)(a=t[n])&&(r=(o<3?a(r):o>3?a(e,i,r):a(e,i))||r);return o>3&&r&&Object.defineProperty(e,i,r),r};class Y extends p{connectedCallback(){this.registerFormResetChangeManager()}disconnectedCallback(){this.unregisterFormResetChangeManager()}async reset(t={},e){await this.vegaFormFieldController.navigateVegaFormChildren((async(i,s)=>{const a=this.vegaFormFieldController.getFormFieldName(i);s&&await i.reset(t[a]||{},e)}),e),o.notify(h,{host:this.host,defaultValueMap:t,option:e}),this.vegaFormFieldController.setIsTouched(!1)}registerFormResetChangeManager(){var t;const e=null!==(t=N(this.host,"vega-form",{outerMost:!0}))&&void 0!==t?t:this.host;this.formResetEventObserver=new I(this.canAcceptFormResetEvent.bind(this),this.handleResetEvents.bind(this)),o.register(P.getSubject(e,B),this.formResetEventObserver)}unregisterFormResetChangeManager(){var t;const e=null!==(t=N(this.host,"vega-form",{outerMost:!0}))&&void 0!==t?t:this.host;o.unregister(P.getSubject(e,B),this.formResetEventObserver)}canAcceptFormResetEvent(t){return this.vegaFormFieldController.isElementInCurrentForm(t.host)}async handleResetEvents(){await this.host.reset(),this.resetEventEmitter.emit()}}X([u()],Y.prototype,"host",void 0),X([u()],Y.prototype,"vegaFormFieldController",void 0),X([u()],Y.prototype,"resetEventEmitter",void 0),X([f("connectedCallback")],Y.prototype,"connectedCallback",null),X([f("disconnectedCallback")],Y.prototype,"disconnectedCallback",null),X([f("reset")],Y.prototype,"reset",null);var Z=function(t,e,i,s){var a,o=arguments.length,r=o<3?e:null===s?s=Object.getOwnPropertyDescriptor(e,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)r=Reflect.decorate(t,e,i,s);else for(var n=t.length-1;n>=0;n--)(a=t[n])&&(r=(o<3?a(r):o>3?a(e,i,r):a(e,i))||r);return o>3&&r&&Object.defineProperty(e,i,r),r};const tt=class{constructor(t){e(this,t),this.vegaValidate=i(this,"vegaValidate",7),this.validate=i(this,"validate",7),this.vegaFormSubmit=i(this,"vegaFormSubmit",7),this.formSubmit=i(this,"formSubmit",7),this.vegaFormReset=i(this,"vegaFormReset",7),this.formReset=i(this,"formReset",7),this.globalSlimmers={},this.submitEventEmitter=V(tt,w),this.resetEventEmitter=V(tt,y),this.validateEventEmitter=V(tt,C),this.disableBlurValidationNotifySlimmer=R(tt,"disableBlurValidation","watchDisableBlurValidation"),this.stateController=new G,this.childEventPrevent=new F([w,y],(()=>this.host.querySelector("vega-form")),{customPreventHandle:t=>{t.stopPropagation()}}),this.childFormValidateEventPrevent=new F([C],(()=>this.host),{customPreventHandle:t=>{t.stopPropagation()}}),this.vegaComponentUsageRuntimeMetricsSlimmer=new j,this.vegaFormFieldValidationStateController=new _,this.nativeFormRenderer=new z,this.vegaFormSubmitController=new K,this.vegaFormResetController=new Y,this.vegaFormFieldController=new Q,this.isValid=null,this.isTouched=!1,this.disableBlurValidation=!1,this.useNativeForm=!1,this.method="get"}watchIsValid(){this.validateEventEmitter.emit(this.isValid),o.notify(n,{host:this.host,detail:this.isValid})}watchDisableBlurValidation(){}async valid(t=!0){return b(t)}async getValue(t){return b(t)}async setValue(t,e){}async reset(t={},e){}async setValidationStates(t){}render(){return m(t(s,null,this.useNativeForm?this.nativeFormRenderer.render():t("slot",null)),this.host)}get host(){return a(this)}static get watchers(){return{isValid:["watchIsValid"],disableBlurValidation:["watchDisableBlurValidation"]}}};Z([g()],tt.prototype,"globalSlimmers",void 0),Z([v()],tt.prototype,"submitEventEmitter",void 0),Z([v()],tt.prototype,"resetEventEmitter",void 0),Z([v()],tt.prototype,"validateEventEmitter",void 0),Z([v()],tt.prototype,"disableBlurValidationNotifySlimmer",void 0),Z([v()],tt.prototype,"stateController",void 0),Z([v()],tt.prototype,"childEventPrevent",void 0),Z([v()],tt.prototype,"childFormValidateEventPrevent",void 0),Z([v()],tt.prototype,"vegaComponentUsageRuntimeMetricsSlimmer",void 0),Z([v()],tt.prototype,"vegaFormFieldValidationStateController",void 0),Z([v()],tt.prototype,"nativeFormRenderer",void 0),Z([v()],tt.prototype,"vegaFormSubmitController",void 0),Z([v()],tt.prototype,"vegaFormResetController",void 0),Z([v()],tt.prototype,"vegaFormFieldController",void 0),tt.style=":host{display:block}";export{tt as vega_form}