@heartlandone/vega 2.75.0-RTE-table-preview → 2.75.1

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 (639) hide show
  1. package/dist/cjs/{app-globals-6c9a0e62.js → app-globals-35614ce8.js} +17 -19
  2. package/dist/cjs/{code-block-d9001f03.js → code-block-c1d2e6a8.js} +3 -34
  3. package/dist/cjs/{component-value-history-controller-slimmer.abstract-b00e9f58.js → component-value-history-controller-slimmer.abstract-787c67dc.js} +5 -26
  4. package/dist/cjs/{design-token-a569577e.js → design-token-bb39e07e.js} +1 -1
  5. package/dist/cjs/{content-state-466f277f.js → dto-renderer-manager-03e1a038.js} +255 -37
  6. package/dist/cjs/{element-appender-slimmer-b7fdd82e.js → element-appender-slimmer-daa8b9f5.js} +6 -6
  7. package/dist/cjs/{form-field-controller-slimmer-3ea2464a.js → form-field-controller-slimmer-aef2fb1e.js} +2 -2
  8. package/dist/cjs/function-extension-cfbbc57e.js +2927 -0
  9. package/dist/cjs/{image-annotation-action-4435d531.js → image-annotation-action-3fa501b7.js} +31 -3
  10. package/dist/cjs/index-58ea899e.js +0 -4
  11. package/dist/cjs/{index-19e5b936.js → index-95fca64f.js} +1 -1
  12. package/dist/cjs/index.cjs.js +43 -48
  13. package/dist/cjs/{language-extension-26331915.js → language-extension-8c4a56ff.js} +8 -8
  14. package/dist/cjs/loader.cjs.js +13 -18
  15. package/dist/cjs/{public-rules-942bd931.js → public-rules-dc2a8d62.js} +4 -4
  16. package/dist/cjs/{range-cafe69a9.js → range-79b668e7.js} +1 -1
  17. package/dist/cjs/{responsive-format-facade-6c22bbbd.js → responsive-format-facade-d5dba942.js} +3 -4
  18. package/dist/cjs/{rich-text-editor-required-rule-0dcb08c8.js → rich-text-editor-required-rule-ba312af9.js} +2 -2
  19. package/dist/cjs/{string-input-formatter-slimmer-655d0322.js → string-input-formatter-slimmer-f3e0bbc7.js} +2 -2
  20. package/dist/cjs/{style-formatter-0e0ae896.js → style-formatter-49693da7.js} +1 -1
  21. package/dist/cjs/{sub-state-notify-slimmer-3fa87162.js → sub-state-notify-slimmer-468e19aa.js} +1 -1
  22. package/dist/cjs/{sub-state-observer-slimmer-77deba40.js → sub-state-observer-slimmer-5d0b8ac3.js} +1 -1
  23. package/dist/cjs/vega-accordion.cjs.entry.js +8 -12
  24. package/dist/cjs/vega-app-header-button.cjs.entry.js +8 -12
  25. package/dist/cjs/vega-box.cjs.entry.js +10 -14
  26. package/dist/cjs/vega-button-circle.cjs.entry.js +8 -12
  27. package/dist/cjs/vega-button-group_2.cjs.entry.js +3 -3
  28. package/dist/cjs/vega-button.cjs.entry.js +7 -11
  29. package/dist/cjs/vega-calendar_4.cjs.entry.js +3 -3
  30. package/dist/cjs/vega-card.cjs.entry.js +10 -14
  31. package/dist/cjs/vega-carousel.cjs.entry.js +7 -11
  32. package/dist/cjs/vega-checkbox_2.cjs.entry.js +3 -3
  33. package/dist/cjs/vega-chip.cjs.entry.js +8 -12
  34. package/dist/cjs/vega-code-block.cjs.entry.js +4 -4
  35. package/dist/cjs/vega-color-picker.cjs.entry.js +3 -3
  36. package/dist/cjs/vega-combo-box.cjs.entry.js +3 -3
  37. package/dist/cjs/vega-date-picker_2.cjs.entry.js +13 -17
  38. package/dist/cjs/vega-dialog_2.cjs.entry.js +16 -20
  39. package/dist/cjs/vega-divider.cjs.entry.js +11 -15
  40. package/dist/cjs/vega-dropdown_5.cjs.entry.js +11 -14
  41. package/dist/cjs/vega-env-manager-23b8b23c.js +2 -2
  42. package/dist/cjs/vega-file-uploader.cjs.entry.js +3 -3
  43. package/dist/cjs/vega-flag-icon.cjs.entry.js +9 -13
  44. package/dist/cjs/vega-flex.cjs.entry.js +11 -15
  45. package/dist/cjs/vega-font.cjs.entry.js +10 -14
  46. package/dist/cjs/vega-form.cjs.entry.js +4 -4
  47. package/dist/cjs/vega-grid.cjs.entry.js +10 -14
  48. package/dist/cjs/vega-icon.cjs.entry.js +10 -14
  49. package/dist/cjs/vega-image-uploader.cjs.entry.js +10 -14
  50. package/dist/cjs/vega-input-credit-card.cjs.entry.js +3 -3
  51. package/dist/cjs/vega-input-numeric.cjs.entry.js +4 -4
  52. package/dist/cjs/vega-input-passcode.cjs.entry.js +3 -3
  53. package/dist/cjs/vega-input-phone-number.cjs.entry.js +8 -12
  54. package/dist/cjs/vega-input-range.cjs.entry.js +3 -3
  55. package/dist/cjs/vega-input-select.cjs.entry.js +9 -12
  56. package/dist/cjs/vega-input.cjs.entry.js +5 -5
  57. package/dist/cjs/{vega-internal-event-id-73334b4b.js → vega-internal-event-id-f2465f1b.js} +0 -4
  58. package/dist/cjs/vega-left-nav_5.cjs.entry.js +13 -17
  59. package/dist/cjs/vega-loader-wrapper_2.cjs.entry.js +14 -18
  60. package/dist/cjs/vega-pagination-page-selector-mobile.cjs.entry.js +1 -1
  61. package/dist/cjs/vega-pagination-page-size-selector-mobile.cjs.entry.js +1 -1
  62. package/dist/cjs/vega-pagination.cjs.entry.js +8 -12
  63. package/dist/cjs/vega-popover_2.cjs.entry.js +9 -13
  64. package/dist/cjs/vega-progress-tracker_2.cjs.entry.js +8 -12
  65. package/dist/cjs/vega-radio_2.cjs.entry.js +3 -3
  66. package/dist/cjs/vega-rich-text-content.cjs.entry.js +18 -16
  67. package/dist/cjs/vega-rich-text-editor_4.cjs.entry.js +287 -192
  68. package/dist/cjs/vega-selection-chip_2.cjs.entry.js +10 -14
  69. package/dist/cjs/vega-selection-tile_2.cjs.entry.js +4 -4
  70. package/dist/cjs/vega-sidenav_3.cjs.entry.js +15 -19
  71. package/dist/cjs/vega-signature-capture.cjs.entry.js +10 -14
  72. package/dist/cjs/vega-stepper.cjs.entry.js +3 -3
  73. package/dist/cjs/vega-table_11.cjs.entry.js +14 -17
  74. package/dist/cjs/vega-textarea.cjs.entry.js +3 -3
  75. package/dist/cjs/vega-time-picker_2.cjs.entry.js +9 -13
  76. package/dist/cjs/vega-toggle-switch.cjs.entry.js +3 -3
  77. package/dist/cjs/vega-tooltip_2.cjs.entry.js +10 -14
  78. package/dist/cjs/vega.cjs.js +13 -18
  79. package/dist/collection/collection-manifest.json +0 -10
  80. package/dist/collection/components/vega-popover/slimmers/controllers/vega-popover-appender-controller.js +0 -1
  81. package/dist/collection/components/vega-rich-text-content/vega-rich-text-content.js +1 -9
  82. package/dist/collection/components/vega-rich-text-editor/dto/action-handle-strategies/action-handle-strategy.abstract.js +0 -10
  83. package/dist/collection/components/vega-rich-text-editor/dto/blocks/block.abstract.js +2 -24
  84. package/dist/collection/components/vega-rich-text-editor/dto/blocks/html-block.js +16 -0
  85. package/dist/collection/components/vega-rich-text-editor/dto/content-state.js +3 -22
  86. package/dist/collection/components/vega-rich-text-editor/dto/renderers/nodes/text-node-renderer.js +10 -0
  87. package/dist/collection/components/vega-rich-text-editor/extensions/base-extension-renderer.js +1 -2
  88. package/dist/collection/components/vega-rich-text-editor/extensions/extension.abstract.js +1 -18
  89. package/dist/collection/components/vega-rich-text-editor/public-api.js +0 -1
  90. package/dist/collection/components/vega-rich-text-editor/slimmers/controllers/extension-controller.js +0 -20
  91. package/dist/collection/components/vega-rich-text-editor/slimmers/controllers/helper/element-to-dto-strategy/annotation-handler/html-element-to-annotation-generator.js +0 -10
  92. package/dist/collection/components/vega-rich-text-editor/slimmers/controllers/html-cleaner/html-content-cleaner.js +59 -0
  93. package/dist/collection/components/vega-rich-text-editor/slimmers/controllers/html-cleaner/index.js +4 -0
  94. package/dist/collection/components/vega-rich-text-editor/slimmers/controllers/html-cleaner/processors/remove-whitespace-after-opening-tag-processor.js +21 -0
  95. package/dist/collection/components/vega-rich-text-editor/slimmers/controllers/html-cleaner/processors/remove-whitespace-before-closing-tag-processor.js +21 -0
  96. package/dist/collection/components/vega-rich-text-editor/slimmers/controllers/html-cleaner/processors/remove-whitespace-between-tags-processor.js +77 -0
  97. package/dist/collection/components/vega-rich-text-editor/slimmers/controllers/selection-controller.js +2 -23
  98. package/dist/collection/components/vega-rich-text-editor/slimmers/controllers/text-node-color-controller.js +51 -0
  99. package/dist/collection/components/vega-rich-text-editor/slimmers/controllers/text-node-rendering-registry.js +26 -0
  100. package/dist/collection/components/vega-rich-text-editor/test/dto/blocks/html-block.test.js +39 -0
  101. package/dist/collection/components/vega-rich-text-editor/test/dto/content-state.test.js +166 -253
  102. package/dist/collection/components/vega-rich-text-editor/test/html-cleaner/html-content-cleaner.test.js +186 -0
  103. package/dist/collection/components/vega-rich-text-editor/test/html-cleaner/remove-whitespace-after-opening-tag-processor.test.js +22 -0
  104. package/dist/collection/components/vega-rich-text-editor/test/html-cleaner/remove-whitespace-before-closing-tag-processor.test.js +22 -0
  105. package/dist/collection/components/vega-rich-text-editor/test/html-cleaner/remove-whitespace-between-tags-processor.test.js +26 -0
  106. package/dist/collection/components/vega-rich-text-editor/test/spec-utils.js +2 -5
  107. package/dist/collection/components/vega-rich-text-editor/vega-rich-text-editor.css +0 -4
  108. package/dist/collection/components/vega-rich-text-editor/vega-rich-text-editor.js +5 -0
  109. package/dist/collection/global/scripts/before-vega-load.js +0 -2
  110. package/dist/collection/helpers/code-format/code-formatter.js +57 -7
  111. package/dist/collection/helpers/code-format/test/code-formatter.test.js +48 -0
  112. package/dist/collection/helpers/event-manager/event-id/vega-internal-event-id.js +0 -2
  113. package/dist/collection/utils/spec-utils.js +3 -4
  114. package/dist/esm/{app-globals-4146c01c.js → app-globals-2ac60ff5.js} +6 -8
  115. package/dist/esm/{child-nodes-event-prevent-slimmer-225e7b58.js → child-nodes-event-prevent-slimmer-e662bee2.js} +1 -1
  116. package/dist/esm/{code-block-36393b45.js → code-block-8ee34ab6.js} +5 -36
  117. package/dist/esm/{component-value-history-controller-slimmer.abstract-82339b2b.js → component-value-history-controller-slimmer.abstract-a61bf821.js} +6 -27
  118. package/dist/esm/{design-token-c57a58b4.js → design-token-007efbaa.js} +1 -1
  119. package/dist/esm/{dom-node-subject-observer-factory-d4e16f66.js → dom-node-subject-observer-factory-064ee2b2.js} +1 -1
  120. package/dist/esm/{content-state-e8ef033a.js → dto-renderer-manager-ee1a5864.js} +256 -36
  121. package/dist/esm/{element-appender-slimmer-a7341fc1.js → element-appender-slimmer-35e26b5a.js} +4 -4
  122. package/dist/esm/{event-emit-slimmer-1bb4b533.js → event-emit-slimmer-09827cec.js} +2 -2
  123. package/dist/esm/{form-field-controller-slimmer-907bf7c2.js → form-field-controller-slimmer-5d9dc384.js} +3 -3
  124. package/dist/esm/function-extension-e8c0e43e.js +2908 -0
  125. package/dist/esm/{image-annotation-action-82cef6e4.js → image-annotation-action-285d432e.js} +31 -4
  126. package/dist/esm/index-090d31ca.js +0 -4
  127. package/dist/esm/{index-2466b0c0.js → index-51a7da7f.js} +2 -2
  128. package/dist/esm/index.js +18 -22
  129. package/dist/esm/{internal-vega-event-manager-2cbb828a.js → internal-vega-event-manager-efb6786e.js} +1 -1
  130. package/dist/esm/{language-extension-dcc43702.js → language-extension-29bf8acd.js} +2 -2
  131. package/dist/esm/loader.js +13 -18
  132. package/dist/esm/polyfills/core-js.js +0 -0
  133. package/dist/esm/polyfills/dom.js +0 -0
  134. package/dist/esm/polyfills/es5-html-element.js +0 -0
  135. package/dist/esm/polyfills/index.js +0 -0
  136. package/dist/esm/polyfills/system.js +0 -0
  137. package/dist/esm/{public-rules-b8ea651f.js → public-rules-724873f5.js} +5 -5
  138. package/dist/esm/{range-872aad9f.js → range-5257c062.js} +1 -1
  139. package/dist/esm/{responsive-format-facade-9278eae4.js → responsive-format-facade-28ee2dbd.js} +3 -4
  140. package/dist/esm/{rich-text-editor-required-rule-36dd4242.js → rich-text-editor-required-rule-873e2e67.js} +1 -1
  141. package/dist/esm/{string-input-formatter-slimmer-7a1e8754.js → string-input-formatter-slimmer-ee32b1fd.js} +3 -3
  142. package/dist/esm/{style-formatter-e937952a.js → style-formatter-314b37f3.js} +1 -1
  143. package/dist/esm/{sub-state-notify-slimmer-2ecdba12.js → sub-state-notify-slimmer-4453047a.js} +2 -2
  144. package/dist/esm/{sub-state-observer-slimmer-2d5dba8d.js → sub-state-observer-slimmer-202ec7dc.js} +2 -2
  145. package/dist/esm/vega-accordion.entry.js +10 -14
  146. package/dist/esm/vega-app-header-button.entry.js +11 -15
  147. package/dist/esm/vega-banner.entry.js +3 -3
  148. package/dist/esm/vega-box.entry.js +11 -15
  149. package/dist/esm/vega-breadcrumb.entry.js +4 -4
  150. package/dist/esm/vega-button-circle.entry.js +11 -15
  151. package/dist/esm/vega-button-group_2.entry.js +7 -7
  152. package/dist/esm/vega-button-link.entry.js +4 -4
  153. package/dist/esm/vega-button.entry.js +10 -14
  154. package/dist/esm/vega-calendar_4.entry.js +7 -7
  155. package/dist/esm/vega-card.entry.js +10 -14
  156. package/dist/esm/vega-carousel.entry.js +9 -13
  157. package/dist/esm/vega-checkbox_2.entry.js +7 -7
  158. package/dist/esm/vega-chip.entry.js +11 -15
  159. package/dist/esm/vega-code-block.entry.js +8 -8
  160. package/dist/esm/vega-color-picker.entry.js +6 -6
  161. package/dist/esm/vega-combo-box.entry.js +7 -7
  162. package/dist/esm/vega-date-picker_2.entry.js +17 -21
  163. package/dist/esm/vega-dialog_2.entry.js +13 -17
  164. package/dist/esm/vega-divider.entry.js +11 -15
  165. package/dist/esm/vega-dropdown_5.entry.js +14 -17
  166. package/dist/esm/vega-env-manager-8f8dc473.js +2 -2
  167. package/dist/esm/vega-field-label.entry.js +3 -3
  168. package/dist/esm/vega-file-uploader.entry.js +6 -6
  169. package/dist/esm/vega-flag-icon.entry.js +9 -13
  170. package/dist/esm/vega-flex.entry.js +11 -15
  171. package/dist/esm/vega-font.entry.js +10 -14
  172. package/dist/esm/vega-form.entry.js +8 -8
  173. package/dist/esm/vega-grid.entry.js +10 -14
  174. package/dist/esm/vega-icon.entry.js +10 -14
  175. package/dist/esm/vega-image-uploader.entry.js +13 -17
  176. package/dist/esm/vega-input-credit-card.entry.js +7 -7
  177. package/dist/esm/vega-input-numeric.entry.js +8 -8
  178. package/dist/esm/vega-input-passcode.entry.js +7 -7
  179. package/dist/esm/vega-input-phone-number.entry.js +12 -16
  180. package/dist/esm/vega-input-range.entry.js +7 -7
  181. package/dist/esm/vega-input-select.entry.js +12 -15
  182. package/dist/esm/vega-input.entry.js +8 -8
  183. package/dist/esm/{vega-internal-event-id-3edc9b4e.js → vega-internal-event-id-4a06d705.js} +1 -3
  184. package/dist/esm/vega-item-toggle.entry.js +3 -3
  185. package/dist/esm/vega-left-nav_5.entry.js +12 -16
  186. package/dist/esm/vega-loader-wrapper_2.entry.js +12 -16
  187. package/dist/esm/vega-page-notification_2.entry.js +1 -1
  188. package/dist/esm/vega-pagination-page-selector-mobile.entry.js +4 -4
  189. package/dist/esm/vega-pagination-page-size-selector-mobile.entry.js +2 -2
  190. package/dist/esm/vega-pagination.entry.js +12 -16
  191. package/dist/esm/vega-popover_2.entry.js +12 -16
  192. package/dist/esm/vega-progress-tracker_2.entry.js +11 -15
  193. package/dist/esm/vega-radio_2.entry.js +7 -7
  194. package/dist/esm/vega-rich-text-content.entry.js +17 -15
  195. package/dist/esm/vega-rich-text-editor_4.entry.js +269 -174
  196. package/dist/esm/vega-segment-control.entry.js +3 -3
  197. package/dist/esm/vega-selection-chip_2.entry.js +13 -17
  198. package/dist/esm/vega-selection-tile_2.entry.js +8 -8
  199. package/dist/esm/vega-sidenav_3.entry.js +14 -18
  200. package/dist/esm/vega-signature-capture.entry.js +12 -16
  201. package/dist/esm/vega-stepper.entry.js +7 -7
  202. package/dist/esm/vega-tab-group_2.entry.js +4 -4
  203. package/dist/esm/vega-table_11.entry.js +12 -15
  204. package/dist/esm/vega-textarea.entry.js +7 -7
  205. package/dist/esm/vega-time-picker_2.entry.js +12 -16
  206. package/dist/esm/vega-toggle-switch.entry.js +6 -6
  207. package/dist/esm/vega-tooltip_2.entry.js +11 -15
  208. package/dist/esm/vega.js +13 -18
  209. package/dist/sri/vega-sri-manifest.json +301 -317
  210. package/dist/types/components/vega-popover/slimmers/controllers/vega-popover-appender-controller.d.ts +0 -1
  211. package/dist/types/components/vega-rich-text-content/vega-rich-text-content.d.ts +0 -3
  212. package/dist/types/components/vega-rich-text-editor/dto/action-handle-strategies/action-handle-strategy.abstract.d.ts +0 -7
  213. package/dist/types/components/vega-rich-text-editor/dto/annotations/annotation.abstract.d.ts +5 -2
  214. package/dist/types/components/vega-rich-text-editor/dto/annotations/block-annotation.abstract.d.ts +3 -3
  215. package/dist/types/components/vega-rich-text-editor/dto/annotations/custom-attribute-annotation.d.ts +1 -1
  216. package/dist/types/components/vega-rich-text-editor/dto/blocks/block.abstract.d.ts +6 -10
  217. package/dist/types/components/vega-rich-text-editor/dto/blocks/html-block.d.ts +10 -0
  218. package/dist/types/components/vega-rich-text-editor/dto/renderers/nodes/text-node-renderer.d.ts +2 -0
  219. package/dist/types/components/vega-rich-text-editor/extensions/extension.abstract.d.ts +2 -15
  220. package/dist/types/components/vega-rich-text-editor/interface.d.ts +2 -34
  221. package/dist/types/components/vega-rich-text-editor/public-api.d.ts +0 -1
  222. package/dist/types/components/vega-rich-text-editor/slimmers/controllers/extension-controller.d.ts +0 -4
  223. package/dist/types/components/vega-rich-text-editor/slimmers/controllers/helper/element-to-dto-strategy/annotation-handler/html-element-to-annotation-generator.d.ts +0 -9
  224. package/dist/types/components/vega-rich-text-editor/slimmers/controllers/html-cleaner/html-content-cleaner-processor.interface.d.ts +13 -0
  225. package/dist/types/components/vega-rich-text-editor/slimmers/controllers/html-cleaner/html-content-cleaner.d.ts +35 -0
  226. package/dist/types/components/vega-rich-text-editor/slimmers/controllers/html-cleaner/index.d.ts +4 -0
  227. package/dist/types/components/vega-rich-text-editor/slimmers/controllers/html-cleaner/processors/remove-whitespace-after-opening-tag-processor.d.ts +19 -0
  228. package/dist/types/components/vega-rich-text-editor/slimmers/controllers/html-cleaner/processors/remove-whitespace-before-closing-tag-processor.d.ts +19 -0
  229. package/dist/types/components/vega-rich-text-editor/slimmers/controllers/html-cleaner/processors/remove-whitespace-between-tags-processor.d.ts +59 -0
  230. package/dist/types/components/vega-rich-text-editor/slimmers/controllers/selection-controller.d.ts +6 -19
  231. package/dist/types/components/vega-rich-text-editor/slimmers/controllers/text-node-color-controller.d.ts +22 -0
  232. package/dist/types/components/vega-rich-text-editor/slimmers/controllers/text-node-rendering-registry.d.ts +22 -0
  233. package/dist/types/components/vega-rich-text-editor/test/spec-utils.d.ts +0 -4
  234. package/dist/types/components/vega-rich-text-editor/vega-rich-text-editor.d.ts +2 -0
  235. package/dist/types/components.d.ts +1 -138
  236. package/dist/types/helpers/code-format/code-formatter.d.ts +14 -0
  237. package/dist/types/helpers/event-manager/event-id/vega-internal-event-id.d.ts +0 -2
  238. package/dist/types/types/components.type.d.ts +0 -4
  239. package/dist/types/utils/spec-utils.d.ts +1 -2
  240. package/dist/vega/index.esm.js +1 -1
  241. package/dist/vega/{p-3a6ff599.entry.js → p-011b94b1.entry.js} +1 -1
  242. package/dist/vega/p-012753b5.entry.js +1 -0
  243. package/dist/vega/p-024331ce.entry.js +1 -0
  244. package/dist/vega/{p-29f6b2d5.js → p-0575d22e.js} +1 -1
  245. package/dist/vega/p-08a90cc6.entry.js +1 -0
  246. package/dist/vega/p-0ede1fea.entry.js +1 -0
  247. package/dist/vega/{p-e1de1cdc.js → p-1298b126.js} +1 -1
  248. package/dist/vega/{p-9c624e03.entry.js → p-17c55205.entry.js} +1 -1
  249. package/dist/vega/p-3353b3d7.js +1 -0
  250. package/dist/vega/p-365b1b35.entry.js +1 -0
  251. package/dist/vega/p-3ae9ee3d.entry.js +1 -0
  252. package/dist/vega/p-3af92370.entry.js +1 -0
  253. package/dist/vega/p-3bf66be2.js +1 -0
  254. package/dist/vega/{p-e7cfb6b6.entry.js → p-3c5a28e4.entry.js} +1 -1
  255. package/dist/vega/p-430be941.js +1 -0
  256. package/dist/vega/{p-fdebc47f.entry.js → p-43f585f7.entry.js} +1 -1
  257. package/dist/vega/p-45296fd4.entry.js +1 -0
  258. package/dist/vega/p-491618a6.entry.js +1 -0
  259. package/dist/vega/{p-c5e7035b.entry.js → p-4a537391.entry.js} +1 -1
  260. package/dist/vega/p-4aa893ef.entry.js +1 -0
  261. package/dist/vega/p-4c47e8bb.entry.js +1 -0
  262. package/dist/vega/{p-d907f8a2.js → p-4da75f2b.js} +1 -1
  263. package/dist/vega/{p-60483e3d.entry.js → p-509eb52e.entry.js} +1 -1
  264. package/dist/vega/p-5110ba73.entry.js +1 -0
  265. package/dist/vega/p-556f9a21.entry.js +1 -0
  266. package/dist/vega/p-55b54ba0.entry.js +1 -0
  267. package/dist/vega/p-5b71c85e.js +1 -0
  268. package/dist/vega/p-5ea2e43c.entry.js +1 -0
  269. package/dist/vega/p-5efc6fe1.entry.js +1 -0
  270. package/dist/vega/p-5f377954.js +1 -1
  271. package/dist/vega/p-64cd1931.entry.js +1 -0
  272. package/dist/vega/{p-c841be8d.js → p-66fa700b.js} +1 -1
  273. package/dist/vega/{p-2c830cba.entry.js → p-67fcf6f2.entry.js} +1 -1
  274. package/dist/vega/{p-61ddae59.js → p-68df4288.js} +1 -1
  275. package/dist/vega/{p-5fdb9047.js → p-691ba1ae.js} +1 -1
  276. package/dist/vega/{p-87764570.entry.js → p-6a2205a1.entry.js} +1 -1
  277. package/dist/vega/{p-18560714.entry.js → p-6a4277df.entry.js} +1 -1
  278. package/dist/vega/{p-20010bd6.js → p-6e136980.js} +1 -1
  279. package/dist/vega/p-6f8be8ea.js +1 -0
  280. package/dist/vega/p-6fa8e231.entry.js +1 -0
  281. package/dist/vega/{p-585edae4.entry.js → p-7045e84c.entry.js} +1 -1
  282. package/dist/vega/{p-22989693.js → p-7288f8c4.js} +1 -1
  283. package/dist/vega/{p-85bfa0f7.js → p-749f96a4.js} +1 -1
  284. package/dist/vega/{p-e819940c.js → p-77edf50c.js} +1 -1
  285. package/dist/vega/p-7aaece55.entry.js +1 -0
  286. package/dist/vega/p-7ec6a104.entry.js +1 -0
  287. package/dist/vega/{p-01dc2e48.entry.js → p-81134e9e.entry.js} +1 -1
  288. package/dist/vega/p-89d685a8.js +1 -0
  289. package/dist/vega/{p-6e4e7192.entry.js → p-8c0eb12f.entry.js} +1 -1
  290. package/dist/vega/{p-11a6c1b7.js → p-8d0ca805.js} +1 -1
  291. package/dist/vega/p-8d701832.entry.js +1 -0
  292. package/dist/vega/{p-4f4c7593.entry.js → p-8e42a14c.entry.js} +1 -1
  293. package/dist/vega/p-8ed0faa2.entry.js +1 -0
  294. package/dist/vega/{p-849f78a7.entry.js → p-94394df7.entry.js} +1 -1
  295. package/dist/vega/p-99aa554b.entry.js +1 -0
  296. package/dist/vega/p-9a2446f1.entry.js +1 -0
  297. package/dist/vega/p-a475d525.entry.js +1 -0
  298. package/dist/vega/{p-bccaf3d2.entry.js → p-a530797f.entry.js} +1 -1
  299. package/dist/vega/{p-76d144f5.entry.js → p-a85ad369.entry.js} +1 -1
  300. package/dist/vega/p-ac5e9955.entry.js +1 -0
  301. package/dist/vega/{p-9472d19a.js → p-aedf7146.js} +1 -1
  302. package/dist/vega/p-b1f869fb.js +1 -0
  303. package/dist/vega/{p-b5b75a2f.entry.js → p-bb4a558d.entry.js} +1 -1
  304. package/dist/vega/{p-0bf4a3a7.entry.js → p-bb8339ed.entry.js} +1 -1
  305. package/dist/vega/{p-28e630b2.entry.js → p-be930e85.entry.js} +1 -1
  306. package/dist/vega/p-bf2bd6d0.entry.js +1 -0
  307. package/dist/vega/p-c2488ed6.js +1 -0
  308. package/dist/vega/{p-4c36b528.entry.js → p-c379a5a5.entry.js} +1 -1
  309. package/dist/vega/{p-89083d63.js → p-c9b6b5a9.js} +1 -1
  310. package/dist/vega/{p-61145506.entry.js → p-ca3472c1.entry.js} +1 -1
  311. package/dist/vega/p-cc43bffb.js +1 -0
  312. package/dist/vega/p-cf5b80f9.entry.js +1 -0
  313. package/dist/vega/p-db60a38e.entry.js +1 -0
  314. package/dist/vega/p-e93545fd.js +1 -0
  315. package/dist/vega/{p-77c9949d.entry.js → p-e9c4fd24.entry.js} +1 -1
  316. package/dist/vega/{p-326b5392.entry.js → p-eb60cfe1.entry.js} +1 -1
  317. package/dist/vega/p-ec192283.entry.js +1 -0
  318. package/dist/vega/p-f2a3a1ec.entry.js +1 -0
  319. package/dist/vega/p-f2cdd212.entry.js +1 -0
  320. package/dist/vega/{p-4ecf0ee7.entry.js → p-f3c3ff26.entry.js} +1 -1
  321. package/dist/vega/p-f4c05b4a.entry.js +1 -0
  322. package/dist/vega/{p-228784f7.entry.js → p-f52a0155.entry.js} +1 -1
  323. package/dist/vega/p-f8641214.entry.js +1 -0
  324. package/dist/vega/p-f89443aa.entry.js +1 -0
  325. package/dist/vega/{p-de850e98.entry.js → p-f8f7cf48.entry.js} +1 -1
  326. package/dist/vega/{p-3532aa12.js → p-fe12eff6.js} +1 -1
  327. package/dist/vega/vega.esm.js +1 -1
  328. package/package.json +1 -1
  329. package/dist/cjs/align-left-4a76df69.js +0 -22
  330. package/dist/cjs/dto-renderer-manager-ae5fcbba.js +0 -58
  331. package/dist/cjs/split-cell-operation-9930fde8.js +0 -2133
  332. package/dist/cjs/table-extension-5f27207f.js +0 -6321
  333. package/dist/cjs/vega-rich-text-table-properties_3.cjs.entry.js +0 -1521
  334. package/dist/collection/components/vega-rich-text-editor/extensions/table/action-handler-interceptors/prevent-cell-children-remove-interceptor.js +0 -42
  335. package/dist/collection/components/vega-rich-text-editor/extensions/table/action-handler-interceptors/prevent-cell-content-delete-interceptor.js +0 -26
  336. package/dist/collection/components/vega-rich-text-editor/extensions/table/action-handler-interceptors/prevent-row-insert-interceptor.js +0 -23
  337. package/dist/collection/components/vega-rich-text-editor/extensions/table/action-handler-strategies/delete-table-block-strategy.js +0 -25
  338. package/dist/collection/components/vega-rich-text-editor/extensions/table/action-handler-strategies/delete-table-column-strategy.js +0 -57
  339. package/dist/collection/components/vega-rich-text-editor/extensions/table/action-handler-strategies/delete-table-row-strategy.js +0 -57
  340. package/dist/collection/components/vega-rich-text-editor/extensions/table/action-handler-strategies/insert-table-block-strategy.js +0 -54
  341. package/dist/collection/components/vega-rich-text-editor/extensions/table/action-handler-strategies/insert-table-column-strategy.js +0 -42
  342. package/dist/collection/components/vega-rich-text-editor/extensions/table/action-handler-strategies/insert-table-row-strategy.js +0 -163
  343. package/dist/collection/components/vega-rich-text-editor/extensions/table/action-handler-strategies/merge-cells-strategy.js +0 -120
  344. package/dist/collection/components/vega-rich-text-editor/extensions/table/action-handler-strategies/select-table-column-strategy.js +0 -22
  345. package/dist/collection/components/vega-rich-text-editor/extensions/table/action-handler-strategies/split-cell-horizontally-strategy.js +0 -143
  346. package/dist/collection/components/vega-rich-text-editor/extensions/table/action-handler-strategies/split-cell-vertically-strategy.js +0 -80
  347. package/dist/collection/components/vega-rich-text-editor/extensions/table/action-handler-strategies/table-column-strategy.abstract.js +0 -19
  348. package/dist/collection/components/vega-rich-text-editor/extensions/table/action-handler-strategies/toggle-header-row-strategy.js +0 -133
  349. package/dist/collection/components/vega-rich-text-editor/extensions/table/action-handler-strategies/toggle-header-table-column-strategy.js +0 -99
  350. package/dist/collection/components/vega-rich-text-editor/extensions/table/action-handler-strategies/update-table-cell-properties-strategy.js +0 -24
  351. package/dist/collection/components/vega-rich-text-editor/extensions/table/action-handler-strategies/update-table-properties-strategy.js +0 -29
  352. package/dist/collection/components/vega-rich-text-editor/extensions/table/actions/delete-table-block-action.js +0 -13
  353. package/dist/collection/components/vega-rich-text-editor/extensions/table/actions/delete-table-column-action.js +0 -13
  354. package/dist/collection/components/vega-rich-text-editor/extensions/table/actions/delete-table-row-action.js +0 -18
  355. package/dist/collection/components/vega-rich-text-editor/extensions/table/actions/insert-table-block-action.js +0 -13
  356. package/dist/collection/components/vega-rich-text-editor/extensions/table/actions/insert-table-column-action.js +0 -19
  357. package/dist/collection/components/vega-rich-text-editor/extensions/table/actions/insert-table-row-action.js +0 -26
  358. package/dist/collection/components/vega-rich-text-editor/extensions/table/actions/merge-cells-action.js +0 -17
  359. package/dist/collection/components/vega-rich-text-editor/extensions/table/actions/select-table-column-action.js +0 -13
  360. package/dist/collection/components/vega-rich-text-editor/extensions/table/actions/split-cell-horizontally-action.js +0 -12
  361. package/dist/collection/components/vega-rich-text-editor/extensions/table/actions/split-cell-vertically-action.js +0 -12
  362. package/dist/collection/components/vega-rich-text-editor/extensions/table/actions/table-annotations-action.js +0 -18
  363. package/dist/collection/components/vega-rich-text-editor/extensions/table/actions/table-caption-action.js +0 -13
  364. package/dist/collection/components/vega-rich-text-editor/extensions/table/actions/table-cell-annotations-action.js +0 -18
  365. package/dist/collection/components/vega-rich-text-editor/extensions/table/actions/table-head-cell-annotations-action.js +0 -18
  366. package/dist/collection/components/vega-rich-text-editor/extensions/table/actions/toggle-header-row-action.js +0 -13
  367. package/dist/collection/components/vega-rich-text-editor/extensions/table/actions/toggle-header-table-column-action.js +0 -15
  368. package/dist/collection/components/vega-rich-text-editor/extensions/table/actions/update-table-properties-action.js +0 -38
  369. package/dist/collection/components/vega-rich-text-editor/extensions/table/annotation-handler/table-annotation-handler-base.js +0 -76
  370. package/dist/collection/components/vega-rich-text-editor/extensions/table/annotation-handler/table-annotation-handler.js +0 -69
  371. package/dist/collection/components/vega-rich-text-editor/extensions/table/annotation-handler/table-cell-annotation-handler.js +0 -108
  372. package/dist/collection/components/vega-rich-text-editor/extensions/table/annotation-handler/table-head-cell-annotation-handler.js +0 -14
  373. package/dist/collection/components/vega-rich-text-editor/extensions/table/annotations/table-annotation.js +0 -106
  374. package/dist/collection/components/vega-rich-text-editor/extensions/table/annotations/table-caption-annotation.js +0 -57
  375. package/dist/collection/components/vega-rich-text-editor/extensions/table/annotations/table-cell-annotation.js +0 -161
  376. package/dist/collection/components/vega-rich-text-editor/extensions/table/annotations/table-color-annotation.js +0 -66
  377. package/dist/collection/components/vega-rich-text-editor/extensions/table/annotations/table-head-cell-annotation.js +0 -45
  378. package/dist/collection/components/vega-rich-text-editor/extensions/table/constants/styles.constants.js +0 -21
  379. package/dist/collection/components/vega-rich-text-editor/extensions/table/dto/table-block.js +0 -119
  380. package/dist/collection/components/vega-rich-text-editor/extensions/table/dto/table-body-block.js +0 -56
  381. package/dist/collection/components/vega-rich-text-editor/extensions/table/dto/table-caption-block.js +0 -69
  382. package/dist/collection/components/vega-rich-text-editor/extensions/table/dto/table-cell-block.js +0 -97
  383. package/dist/collection/components/vega-rich-text-editor/extensions/table/dto/table-head-block.js +0 -60
  384. package/dist/collection/components/vega-rich-text-editor/extensions/table/dto/table-head-cell-block.js +0 -53
  385. package/dist/collection/components/vega-rich-text-editor/extensions/table/dto/table-row-block.js +0 -60
  386. package/dist/collection/components/vega-rich-text-editor/extensions/table/element-to-dto-strategies/caption-to-caption-block-strategy.js +0 -50
  387. package/dist/collection/components/vega-rich-text-editor/extensions/table/element-to-dto-strategies/table-to-table-block-strategy.js +0 -42
  388. package/dist/collection/components/vega-rich-text-editor/extensions/table/element-to-dto-strategies/tbody-to-table-body-block-strategy.js +0 -42
  389. package/dist/collection/components/vega-rich-text-editor/extensions/table/element-to-dto-strategies/td-to-table-cell-block-strategy.js +0 -71
  390. package/dist/collection/components/vega-rich-text-editor/extensions/table/element-to-dto-strategies/thead-to-table-head-block-strategy.js +0 -42
  391. package/dist/collection/components/vega-rich-text-editor/extensions/table/element-to-dto-strategies/tr-to-table-row-block-strategy.js +0 -42
  392. package/dist/collection/components/vega-rich-text-editor/extensions/table/renderers/table-body-renderer.js +0 -15
  393. package/dist/collection/components/vega-rich-text-editor/extensions/table/renderers/table-caption-renderer.js +0 -22
  394. package/dist/collection/components/vega-rich-text-editor/extensions/table/renderers/table-cell-renderer.js +0 -76
  395. package/dist/collection/components/vega-rich-text-editor/extensions/table/renderers/table-dynamic-popover-renderer.js +0 -254
  396. package/dist/collection/components/vega-rich-text-editor/extensions/table/renderers/table-head-cell-renderer.js +0 -12
  397. package/dist/collection/components/vega-rich-text-editor/extensions/table/renderers/table-head-renderer.js +0 -15
  398. package/dist/collection/components/vega-rich-text-editor/extensions/table/renderers/table-renderer.js +0 -142
  399. package/dist/collection/components/vega-rich-text-editor/extensions/table/renderers/table-row-renderer.js +0 -15
  400. package/dist/collection/components/vega-rich-text-editor/extensions/table/renderers/table-setting-popover-renderer.js +0 -152
  401. package/dist/collection/components/vega-rich-text-editor/extensions/table/setting-event-handlers/caption-operation.js +0 -78
  402. package/dist/collection/components/vega-rich-text-editor/extensions/table/setting-event-handlers/cell-properties-cancel-event-handler.js +0 -17
  403. package/dist/collection/components/vega-rich-text-editor/extensions/table/setting-event-handlers/cell-properties-change-event-handler.js +0 -15
  404. package/dist/collection/components/vega-rich-text-editor/extensions/table/setting-event-handlers/cell-properties-save-event-handler.js +0 -19
  405. package/dist/collection/components/vega-rich-text-editor/extensions/table/setting-event-handlers/cell-properties.js +0 -135
  406. package/dist/collection/components/vega-rich-text-editor/extensions/table/setting-event-handlers/column-operation.js +0 -109
  407. package/dist/collection/components/vega-rich-text-editor/extensions/table/setting-event-handlers/merge-cells-operation.js +0 -100
  408. package/dist/collection/components/vega-rich-text-editor/extensions/table/setting-event-handlers/row-operation.js +0 -132
  409. package/dist/collection/components/vega-rich-text-editor/extensions/table/setting-event-handlers/setting-event-handler.abstract.js +0 -45
  410. package/dist/collection/components/vega-rich-text-editor/extensions/table/setting-event-handlers/split-cell-operation.js +0 -57
  411. package/dist/collection/components/vega-rich-text-editor/extensions/table/setting-event-handlers/table-properties-cancel-event-handler.js +0 -19
  412. package/dist/collection/components/vega-rich-text-editor/extensions/table/setting-event-handlers/table-properties-change-event-handler.js +0 -20
  413. package/dist/collection/components/vega-rich-text-editor/extensions/table/setting-event-handlers/table-properties-save-event-handler.js +0 -20
  414. package/dist/collection/components/vega-rich-text-editor/extensions/table/setting-event-handlers/table-properties.js +0 -50
  415. package/dist/collection/components/vega-rich-text-editor/extensions/table/table-extension.js +0 -164
  416. package/dist/collection/components/vega-rich-text-editor/extensions/table/table-icon.js +0 -3
  417. package/dist/collection/components/vega-rich-text-editor/extensions/table/table-selection.js +0 -460
  418. package/dist/collection/components/vega-rich-text-editor/extensions/table/table-toolbar-button-renderer.js +0 -234
  419. package/dist/collection/components/vega-rich-text-editor/extensions/table/utils/table-color-manager.js +0 -51
  420. package/dist/collection/components/vega-rich-text-editor/extensions/table/utils/utils.js +0 -355
  421. package/dist/collection/components/vega-rich-text-editor/extensions/table/vega-rich-text-table-properties/assets/align-bottom.js +0 -3
  422. package/dist/collection/components/vega-rich-text-editor/extensions/table/vega-rich-text-table-properties/assets/align-middle.js +0 -3
  423. package/dist/collection/components/vega-rich-text-editor/extensions/table/vega-rich-text-table-properties/assets/align-top.js +0 -3
  424. package/dist/collection/components/vega-rich-text-editor/extensions/table/vega-rich-text-table-properties/assets/objects-align-center-horizontal.js +0 -3
  425. package/dist/collection/components/vega-rich-text-editor/extensions/table/vega-rich-text-table-properties/assets/objects-align-left.js +0 -3
  426. package/dist/collection/components/vega-rich-text-editor/extensions/table/vega-rich-text-table-properties/assets/objects-align-right.js +0 -3
  427. package/dist/collection/components/vega-rich-text-editor/extensions/table/vega-rich-text-table-properties/slimmers/controllers/vega-rich-text-table-properties-color-controller.js +0 -58
  428. package/dist/collection/components/vega-rich-text-editor/extensions/table/vega-rich-text-table-properties/slimmers/renderers/vega-rich-text-cell-properties-form-field-renderer.js +0 -106
  429. package/dist/collection/components/vega-rich-text-editor/extensions/table/vega-rich-text-table-properties/slimmers/renderers/vega-rich-text-table-properties-basic-form-field-renderer.abstract.js +0 -291
  430. package/dist/collection/components/vega-rich-text-editor/extensions/table/vega-rich-text-table-properties/slimmers/renderers/vega-rich-text-table-properties-form-field-renderer.js +0 -58
  431. package/dist/collection/components/vega-rich-text-editor/extensions/table/vega-rich-text-table-properties/slimmers/renderers/vega-rich-text-table-properties-form-renderer.js +0 -111
  432. package/dist/collection/components/vega-rich-text-editor/extensions/table/vega-rich-text-table-properties/vega-rich-text-table-properties.css +0 -149
  433. package/dist/collection/components/vega-rich-text-editor/extensions/table/vega-rich-text-table-properties/vega-rich-text-table-properties.js +0 -251
  434. package/dist/collection/components/vega-rich-text-editor/extensions/table/vega-rich-text-table-selection-widget/slimmers/controllers/selection-widget-keyboard-controller.js +0 -36
  435. package/dist/collection/components/vega-rich-text-editor/extensions/table/vega-rich-text-table-selection-widget/slimmers/renderers/selection-widget-renderer.js +0 -83
  436. package/dist/collection/components/vega-rich-text-editor/extensions/table/vega-rich-text-table-selection-widget/vega-rich-text-table-selection-widget.css +0 -41
  437. package/dist/collection/components/vega-rich-text-editor/extensions/table/vega-rich-text-table-selection-widget/vega-rich-text-table-selection-widget.js +0 -80
  438. package/dist/collection/components/vega-rich-text-editor/extensions/table/vega-rich-text-table-setting/assets/icon.js +0 -20
  439. package/dist/collection/components/vega-rich-text-editor/extensions/table/vega-rich-text-table-setting/slimmers/renderers/caption-button-slimmer.js +0 -27
  440. package/dist/collection/components/vega-rich-text-editor/extensions/table/vega-rich-text-table-setting/slimmers/renderers/cell-properties-button-slimmer.js +0 -26
  441. package/dist/collection/components/vega-rich-text-editor/extensions/table/vega-rich-text-table-setting/slimmers/renderers/column-button-slimmer.js +0 -86
  442. package/dist/collection/components/vega-rich-text-editor/extensions/table/vega-rich-text-table-setting/slimmers/renderers/merge-cells-button-slimmer.js +0 -117
  443. package/dist/collection/components/vega-rich-text-editor/extensions/table/vega-rich-text-table-setting/slimmers/renderers/row-button-slimmer.js +0 -103
  444. package/dist/collection/components/vega-rich-text-editor/extensions/table/vega-rich-text-table-setting/slimmers/renderers/table-properties-button-slimmer.js +0 -26
  445. package/dist/collection/components/vega-rich-text-editor/extensions/table/vega-rich-text-table-setting/slimmers/renderers/table-setting-button-slimmer.abstract.js +0 -75
  446. package/dist/collection/components/vega-rich-text-editor/extensions/table/vega-rich-text-table-setting/slimmers/renderers/vega-rich-text-table-setting-renderer.js +0 -55
  447. package/dist/collection/components/vega-rich-text-editor/extensions/table/vega-rich-text-table-setting/vega-rich-text-table-setting.css +0 -20
  448. package/dist/collection/components/vega-rich-text-editor/extensions/table/vega-rich-text-table-setting/vega-rich-text-table-setting.js +0 -222
  449. package/dist/collection/components/vega-rich-text-editor/test/extensions/table/annotation-handler/annotation-handler-registration.test.js +0 -164
  450. package/dist/collection/components/vega-rich-text-editor/test/extensions/table/annotation-handler/table-annotation-handler.test.js +0 -288
  451. package/dist/collection/components/vega-rich-text-editor/test/extensions/table/annotation-handler/table-cell-annotation-handler.test.js +0 -316
  452. package/dist/collection/components/vega-rich-text-editor/test/extensions/table/annotation-handler/table-head-cell-annotation-handler.test.js +0 -411
  453. package/dist/collection/components/vega-rich-text-editor/test/extensions/table/caption-operation.test.js +0 -99
  454. package/dist/collection/components/vega-rich-text-editor/test/extensions/table/table-annotation.test.js +0 -181
  455. package/dist/collection/components/vega-rich-text-editor/test/extensions/table/table-caption-annotations.test.js +0 -79
  456. package/dist/collection/components/vega-rich-text-editor/test/extensions/table/table-cell-annotation.test.js +0 -323
  457. package/dist/collection/components/vega-rich-text-editor/test/extensions/table/table-color-annotation.test.js +0 -32
  458. package/dist/collection/components/vega-rich-text-editor/test/extensions/table/table-dto.test.js +0 -1094
  459. package/dist/collection/components/vega-rich-text-editor/test/extensions/table/table-element-to-dto-strategies.test.js +0 -1539
  460. package/dist/collection/components/vega-rich-text-editor/test/extensions/table/table-test-utils.js +0 -172
  461. package/dist/esm/align-left-7f959adf.js +0 -17
  462. package/dist/esm/dto-renderer-manager-12bc9121.js +0 -56
  463. package/dist/esm/split-cell-operation-6749f654.js +0 -2090
  464. package/dist/esm/table-extension-6b31754b.js +0 -6302
  465. package/dist/esm/vega-rich-text-table-properties_3.entry.js +0 -1515
  466. package/dist/types/components/vega-rich-text-editor/extensions/table/action-handler-interceptors/prevent-cell-children-remove-interceptor.d.ts +0 -25
  467. package/dist/types/components/vega-rich-text-editor/extensions/table/action-handler-interceptors/prevent-cell-content-delete-interceptor.d.ts +0 -20
  468. package/dist/types/components/vega-rich-text-editor/extensions/table/action-handler-interceptors/prevent-row-insert-interceptor.d.ts +0 -19
  469. package/dist/types/components/vega-rich-text-editor/extensions/table/action-handler-strategies/delete-table-block-strategy.d.ts +0 -14
  470. package/dist/types/components/vega-rich-text-editor/extensions/table/action-handler-strategies/delete-table-column-strategy.d.ts +0 -31
  471. package/dist/types/components/vega-rich-text-editor/extensions/table/action-handler-strategies/delete-table-row-strategy.d.ts +0 -28
  472. package/dist/types/components/vega-rich-text-editor/extensions/table/action-handler-strategies/insert-table-block-strategy.d.ts +0 -27
  473. package/dist/types/components/vega-rich-text-editor/extensions/table/action-handler-strategies/insert-table-column-strategy.d.ts +0 -19
  474. package/dist/types/components/vega-rich-text-editor/extensions/table/action-handler-strategies/insert-table-row-strategy.d.ts +0 -44
  475. package/dist/types/components/vega-rich-text-editor/extensions/table/action-handler-strategies/merge-cells-strategy.d.ts +0 -38
  476. package/dist/types/components/vega-rich-text-editor/extensions/table/action-handler-strategies/select-table-column-strategy.d.ts +0 -12
  477. package/dist/types/components/vega-rich-text-editor/extensions/table/action-handler-strategies/split-cell-horizontally-strategy.d.ts +0 -43
  478. package/dist/types/components/vega-rich-text-editor/extensions/table/action-handler-strategies/split-cell-vertically-strategy.d.ts +0 -27
  479. package/dist/types/components/vega-rich-text-editor/extensions/table/action-handler-strategies/table-column-strategy.abstract.d.ts +0 -20
  480. package/dist/types/components/vega-rich-text-editor/extensions/table/action-handler-strategies/toggle-header-row-strategy.d.ts +0 -41
  481. package/dist/types/components/vega-rich-text-editor/extensions/table/action-handler-strategies/toggle-header-table-column-strategy.d.ts +0 -45
  482. package/dist/types/components/vega-rich-text-editor/extensions/table/action-handler-strategies/update-table-cell-properties-strategy.d.ts +0 -13
  483. package/dist/types/components/vega-rich-text-editor/extensions/table/action-handler-strategies/update-table-properties-strategy.d.ts +0 -12
  484. package/dist/types/components/vega-rich-text-editor/extensions/table/actions/delete-table-block-action.d.ts +0 -12
  485. package/dist/types/components/vega-rich-text-editor/extensions/table/actions/delete-table-column-action.d.ts +0 -15
  486. package/dist/types/components/vega-rich-text-editor/extensions/table/actions/delete-table-row-action.d.ts +0 -17
  487. package/dist/types/components/vega-rich-text-editor/extensions/table/actions/insert-table-block-action.d.ts +0 -20
  488. package/dist/types/components/vega-rich-text-editor/extensions/table/actions/insert-table-column-action.d.ts +0 -23
  489. package/dist/types/components/vega-rich-text-editor/extensions/table/actions/insert-table-row-action.d.ts +0 -23
  490. package/dist/types/components/vega-rich-text-editor/extensions/table/actions/merge-cells-action.d.ts +0 -33
  491. package/dist/types/components/vega-rich-text-editor/extensions/table/actions/select-table-column-action.d.ts +0 -18
  492. package/dist/types/components/vega-rich-text-editor/extensions/table/actions/split-cell-horizontally-action.d.ts +0 -10
  493. package/dist/types/components/vega-rich-text-editor/extensions/table/actions/split-cell-vertically-action.d.ts +0 -10
  494. package/dist/types/components/vega-rich-text-editor/extensions/table/actions/table-annotations-action.d.ts +0 -16
  495. package/dist/types/components/vega-rich-text-editor/extensions/table/actions/table-caption-action.d.ts +0 -14
  496. package/dist/types/components/vega-rich-text-editor/extensions/table/actions/table-cell-annotations-action.d.ts +0 -14
  497. package/dist/types/components/vega-rich-text-editor/extensions/table/actions/table-head-cell-annotations-action.d.ts +0 -15
  498. package/dist/types/components/vega-rich-text-editor/extensions/table/actions/toggle-header-row-action.d.ts +0 -12
  499. package/dist/types/components/vega-rich-text-editor/extensions/table/actions/toggle-header-table-column-action.d.ts +0 -16
  500. package/dist/types/components/vega-rich-text-editor/extensions/table/actions/update-table-properties-action.d.ts +0 -18
  501. package/dist/types/components/vega-rich-text-editor/extensions/table/annotation-handler/table-annotation-handler-base.d.ts +0 -36
  502. package/dist/types/components/vega-rich-text-editor/extensions/table/annotation-handler/table-annotation-handler.d.ts +0 -26
  503. package/dist/types/components/vega-rich-text-editor/extensions/table/annotation-handler/table-cell-annotation-handler.d.ts +0 -56
  504. package/dist/types/components/vega-rich-text-editor/extensions/table/annotation-handler/table-head-cell-annotation-handler.d.ts +0 -13
  505. package/dist/types/components/vega-rich-text-editor/extensions/table/annotations/table-annotation.d.ts +0 -73
  506. package/dist/types/components/vega-rich-text-editor/extensions/table/annotations/table-caption-annotation.d.ts +0 -26
  507. package/dist/types/components/vega-rich-text-editor/extensions/table/annotations/table-cell-annotation.d.ts +0 -76
  508. package/dist/types/components/vega-rich-text-editor/extensions/table/annotations/table-color-annotation.d.ts +0 -43
  509. package/dist/types/components/vega-rich-text-editor/extensions/table/annotations/table-head-cell-annotation.d.ts +0 -22
  510. package/dist/types/components/vega-rich-text-editor/extensions/table/constants/styles.constants.d.ts +0 -3
  511. package/dist/types/components/vega-rich-text-editor/extensions/table/dto/table-block.d.ts +0 -79
  512. package/dist/types/components/vega-rich-text-editor/extensions/table/dto/table-body-block.d.ts +0 -42
  513. package/dist/types/components/vega-rich-text-editor/extensions/table/dto/table-caption-block.d.ts +0 -41
  514. package/dist/types/components/vega-rich-text-editor/extensions/table/dto/table-cell-block.d.ts +0 -64
  515. package/dist/types/components/vega-rich-text-editor/extensions/table/dto/table-head-block.d.ts +0 -42
  516. package/dist/types/components/vega-rich-text-editor/extensions/table/dto/table-head-cell-block.d.ts +0 -34
  517. package/dist/types/components/vega-rich-text-editor/extensions/table/dto/table-row-block.d.ts +0 -44
  518. package/dist/types/components/vega-rich-text-editor/extensions/table/element-to-dto-strategies/caption-to-caption-block-strategy.d.ts +0 -29
  519. package/dist/types/components/vega-rich-text-editor/extensions/table/element-to-dto-strategies/table-to-table-block-strategy.d.ts +0 -26
  520. package/dist/types/components/vega-rich-text-editor/extensions/table/element-to-dto-strategies/tbody-to-table-body-block-strategy.d.ts +0 -26
  521. package/dist/types/components/vega-rich-text-editor/extensions/table/element-to-dto-strategies/td-to-table-cell-block-strategy.d.ts +0 -27
  522. package/dist/types/components/vega-rich-text-editor/extensions/table/element-to-dto-strategies/thead-to-table-head-block-strategy.d.ts +0 -26
  523. package/dist/types/components/vega-rich-text-editor/extensions/table/element-to-dto-strategies/tr-to-table-row-block-strategy.d.ts +0 -26
  524. package/dist/types/components/vega-rich-text-editor/extensions/table/renderers/table-body-renderer.d.ts +0 -12
  525. package/dist/types/components/vega-rich-text-editor/extensions/table/renderers/table-caption-renderer.d.ts +0 -13
  526. package/dist/types/components/vega-rich-text-editor/extensions/table/renderers/table-cell-renderer.d.ts +0 -37
  527. package/dist/types/components/vega-rich-text-editor/extensions/table/renderers/table-dynamic-popover-renderer.d.ts +0 -88
  528. package/dist/types/components/vega-rich-text-editor/extensions/table/renderers/table-head-cell-renderer.d.ts +0 -12
  529. package/dist/types/components/vega-rich-text-editor/extensions/table/renderers/table-head-renderer.d.ts +0 -12
  530. package/dist/types/components/vega-rich-text-editor/extensions/table/renderers/table-renderer.d.ts +0 -54
  531. package/dist/types/components/vega-rich-text-editor/extensions/table/renderers/table-row-renderer.d.ts +0 -12
  532. package/dist/types/components/vega-rich-text-editor/extensions/table/renderers/table-setting-popover-renderer.d.ts +0 -66
  533. package/dist/types/components/vega-rich-text-editor/extensions/table/setting-event-handlers/caption-operation.d.ts +0 -36
  534. package/dist/types/components/vega-rich-text-editor/extensions/table/setting-event-handlers/cell-properties-cancel-event-handler.d.ts +0 -17
  535. package/dist/types/components/vega-rich-text-editor/extensions/table/setting-event-handlers/cell-properties-change-event-handler.d.ts +0 -15
  536. package/dist/types/components/vega-rich-text-editor/extensions/table/setting-event-handlers/cell-properties-save-event-handler.d.ts +0 -17
  537. package/dist/types/components/vega-rich-text-editor/extensions/table/setting-event-handlers/cell-properties.d.ts +0 -62
  538. package/dist/types/components/vega-rich-text-editor/extensions/table/setting-event-handlers/column-operation.d.ts +0 -55
  539. package/dist/types/components/vega-rich-text-editor/extensions/table/setting-event-handlers/merge-cells-operation.d.ts +0 -44
  540. package/dist/types/components/vega-rich-text-editor/extensions/table/setting-event-handlers/row-operation.d.ts +0 -61
  541. package/dist/types/components/vega-rich-text-editor/extensions/table/setting-event-handlers/setting-event-handler.abstract.d.ts +0 -48
  542. package/dist/types/components/vega-rich-text-editor/extensions/table/setting-event-handlers/split-cell-operation.d.ts +0 -31
  543. package/dist/types/components/vega-rich-text-editor/extensions/table/setting-event-handlers/table-properties-cancel-event-handler.d.ts +0 -19
  544. package/dist/types/components/vega-rich-text-editor/extensions/table/setting-event-handlers/table-properties-change-event-handler.d.ts +0 -17
  545. package/dist/types/components/vega-rich-text-editor/extensions/table/setting-event-handlers/table-properties-save-event-handler.d.ts +0 -17
  546. package/dist/types/components/vega-rich-text-editor/extensions/table/setting-event-handlers/table-properties.d.ts +0 -33
  547. package/dist/types/components/vega-rich-text-editor/extensions/table/table-extension.d.ts +0 -36
  548. package/dist/types/components/vega-rich-text-editor/extensions/table/table-icon.d.ts +0 -3
  549. package/dist/types/components/vega-rich-text-editor/extensions/table/table-selection.d.ts +0 -164
  550. package/dist/types/components/vega-rich-text-editor/extensions/table/table-toolbar-button-renderer.d.ts +0 -86
  551. package/dist/types/components/vega-rich-text-editor/extensions/table/utils/table-color-manager.d.ts +0 -26
  552. package/dist/types/components/vega-rich-text-editor/extensions/table/utils/utils.d.ts +0 -153
  553. package/dist/types/components/vega-rich-text-editor/extensions/table/vega-rich-text-table-properties/assets/align-bottom.d.ts +0 -3
  554. package/dist/types/components/vega-rich-text-editor/extensions/table/vega-rich-text-table-properties/assets/align-middle.d.ts +0 -3
  555. package/dist/types/components/vega-rich-text-editor/extensions/table/vega-rich-text-table-properties/assets/align-top.d.ts +0 -3
  556. package/dist/types/components/vega-rich-text-editor/extensions/table/vega-rich-text-table-properties/assets/objects-align-center-horizontal.d.ts +0 -3
  557. package/dist/types/components/vega-rich-text-editor/extensions/table/vega-rich-text-table-properties/assets/objects-align-left.d.ts +0 -3
  558. package/dist/types/components/vega-rich-text-editor/extensions/table/vega-rich-text-table-properties/assets/objects-align-right.d.ts +0 -3
  559. package/dist/types/components/vega-rich-text-editor/extensions/table/vega-rich-text-table-properties/slimmers/controllers/vega-rich-text-table-properties-color-controller.d.ts +0 -29
  560. package/dist/types/components/vega-rich-text-editor/extensions/table/vega-rich-text-table-properties/slimmers/renderers/vega-rich-text-cell-properties-form-field-renderer.d.ts +0 -49
  561. package/dist/types/components/vega-rich-text-editor/extensions/table/vega-rich-text-table-properties/slimmers/renderers/vega-rich-text-table-properties-basic-form-field-renderer.abstract.d.ts +0 -111
  562. package/dist/types/components/vega-rich-text-editor/extensions/table/vega-rich-text-table-properties/slimmers/renderers/vega-rich-text-table-properties-form-field-renderer.d.ts +0 -27
  563. package/dist/types/components/vega-rich-text-editor/extensions/table/vega-rich-text-table-properties/slimmers/renderers/vega-rich-text-table-properties-form-renderer.d.ts +0 -39
  564. package/dist/types/components/vega-rich-text-editor/extensions/table/vega-rich-text-table-properties/vega-rich-text-table-properties.d.ts +0 -60
  565. package/dist/types/components/vega-rich-text-editor/extensions/table/vega-rich-text-table-selection-widget/slimmers/controllers/selection-widget-keyboard-controller.d.ts +0 -15
  566. package/dist/types/components/vega-rich-text-editor/extensions/table/vega-rich-text-table-selection-widget/slimmers/renderers/selection-widget-renderer.d.ts +0 -31
  567. package/dist/types/components/vega-rich-text-editor/extensions/table/vega-rich-text-table-selection-widget/vega-rich-text-table-selection-widget.d.ts +0 -27
  568. package/dist/types/components/vega-rich-text-editor/extensions/table/vega-rich-text-table-setting/assets/icon.d.ts +0 -2
  569. package/dist/types/components/vega-rich-text-editor/extensions/table/vega-rich-text-table-setting/slimmers/renderers/caption-button-slimmer.d.ts +0 -11
  570. package/dist/types/components/vega-rich-text-editor/extensions/table/vega-rich-text-table-setting/slimmers/renderers/cell-properties-button-slimmer.d.ts +0 -11
  571. package/dist/types/components/vega-rich-text-editor/extensions/table/vega-rich-text-table-setting/slimmers/renderers/column-button-slimmer.d.ts +0 -28
  572. package/dist/types/components/vega-rich-text-editor/extensions/table/vega-rich-text-table-setting/slimmers/renderers/merge-cells-button-slimmer.d.ts +0 -23
  573. package/dist/types/components/vega-rich-text-editor/extensions/table/vega-rich-text-table-setting/slimmers/renderers/row-button-slimmer.d.ts +0 -36
  574. package/dist/types/components/vega-rich-text-editor/extensions/table/vega-rich-text-table-setting/slimmers/renderers/table-properties-button-slimmer.d.ts +0 -11
  575. package/dist/types/components/vega-rich-text-editor/extensions/table/vega-rich-text-table-setting/slimmers/renderers/table-setting-button-slimmer.abstract.d.ts +0 -36
  576. package/dist/types/components/vega-rich-text-editor/extensions/table/vega-rich-text-table-setting/slimmers/renderers/vega-rich-text-table-setting-renderer.d.ts +0 -12
  577. package/dist/types/components/vega-rich-text-editor/extensions/table/vega-rich-text-table-setting/vega-rich-text-table-setting.d.ts +0 -58
  578. package/dist/types/components/vega-rich-text-editor/test/extensions/table/annotation-handler/table-cell-annotation-handler.test.d.ts +0 -8
  579. package/dist/types/components/vega-rich-text-editor/test/extensions/table/table-caption-annotations.test.d.ts +0 -1
  580. package/dist/types/components/vega-rich-text-editor/test/extensions/table/table-cell-annotation.test.d.ts +0 -1
  581. package/dist/types/components/vega-rich-text-editor/test/extensions/table/table-color-annotation.test.d.ts +0 -1
  582. package/dist/types/components/vega-rich-text-editor/test/extensions/table/table-dto.test.d.ts +0 -1
  583. package/dist/types/components/vega-rich-text-editor/test/extensions/table/table-element-to-dto-strategies.test.d.ts +0 -1
  584. package/dist/types/components/vega-rich-text-editor/test/extensions/table/table-test-utils.d.ts +0 -11
  585. package/dist/vega/p-0459a474.entry.js +0 -1
  586. package/dist/vega/p-0770a0eb.entry.js +0 -1
  587. package/dist/vega/p-0d57293b.js +0 -1
  588. package/dist/vega/p-1199ebf6.entry.js +0 -1
  589. package/dist/vega/p-1415d93b.entry.js +0 -1
  590. package/dist/vega/p-1431c8b9.js +0 -1
  591. package/dist/vega/p-1a161082.entry.js +0 -1
  592. package/dist/vega/p-1b44db34.js +0 -1
  593. package/dist/vega/p-205d8401.js +0 -1
  594. package/dist/vega/p-20a98a99.entry.js +0 -1
  595. package/dist/vega/p-273911b2.entry.js +0 -1
  596. package/dist/vega/p-2af2e1ad.entry.js +0 -1
  597. package/dist/vega/p-2af78c38.entry.js +0 -1
  598. package/dist/vega/p-3224d794.entry.js +0 -1
  599. package/dist/vega/p-3413a678.entry.js +0 -1
  600. package/dist/vega/p-395cdd84.entry.js +0 -1
  601. package/dist/vega/p-3be82c0f.entry.js +0 -1
  602. package/dist/vega/p-3c0f55f7.entry.js +0 -1
  603. package/dist/vega/p-3e30567a.js +0 -1
  604. package/dist/vega/p-42cd1fde.js +0 -1
  605. package/dist/vega/p-4b6c60cb.entry.js +0 -1
  606. package/dist/vega/p-5b048141.js +0 -1
  607. package/dist/vega/p-64386be8.entry.js +0 -1
  608. package/dist/vega/p-6490b69a.entry.js +0 -1
  609. package/dist/vega/p-6bc1552e.entry.js +0 -1
  610. package/dist/vega/p-76eb9cd0.entry.js +0 -1
  611. package/dist/vega/p-8198a77c.js +0 -1
  612. package/dist/vega/p-82ad1006.entry.js +0 -1
  613. package/dist/vega/p-839c9d62.entry.js +0 -1
  614. package/dist/vega/p-88c894e8.entry.js +0 -1
  615. package/dist/vega/p-96657262.entry.js +0 -1
  616. package/dist/vega/p-979e4bd4.entry.js +0 -1
  617. package/dist/vega/p-a01f985f.entry.js +0 -1
  618. package/dist/vega/p-a495463f.entry.js +0 -1
  619. package/dist/vega/p-b56b0b89.js +0 -1
  620. package/dist/vega/p-bde5c990.entry.js +0 -1
  621. package/dist/vega/p-beb6c1ce.entry.js +0 -1
  622. package/dist/vega/p-c02b01ec.entry.js +0 -1
  623. package/dist/vega/p-c1fdcb62.js +0 -1
  624. package/dist/vega/p-c78fe943.js +0 -1
  625. package/dist/vega/p-cd078909.entry.js +0 -1
  626. package/dist/vega/p-d5c09a94.entry.js +0 -1
  627. package/dist/vega/p-e1dd23f8.entry.js +0 -1
  628. package/dist/vega/p-e95ed6f3.entry.js +0 -1
  629. package/dist/vega/p-ebb14c84.js +0 -1
  630. package/dist/vega/p-f0a8aed3.entry.js +0 -1
  631. package/dist/vega/p-f2b8abd3.entry.js +0 -1
  632. package/dist/vega/p-fb238751.entry.js +0 -1
  633. package/dist/vega/p-fcabf0dc.js +0 -1
  634. package/style/vega-icons.css +0 -17266
  635. /package/dist/{types/components/vega-rich-text-editor/test/extensions/table/annotation-handler/annotation-handler-registration.test.d.ts → collection/components/vega-rich-text-editor/slimmers/controllers/html-cleaner/html-content-cleaner-processor.interface.js} +0 -0
  636. /package/dist/types/components/vega-rich-text-editor/test/{extensions/table/annotation-handler/table-annotation-handler.test.d.ts → html-cleaner/html-content-cleaner.test.d.ts} +0 -0
  637. /package/dist/types/components/vega-rich-text-editor/test/{extensions/table/annotation-handler/table-head-cell-annotation-handler.test.d.ts → html-cleaner/remove-whitespace-after-opening-tag-processor.test.d.ts} +0 -0
  638. /package/dist/types/components/vega-rich-text-editor/test/{extensions/table/caption-operation.test.d.ts → html-cleaner/remove-whitespace-before-closing-tag-processor.test.d.ts} +0 -0
  639. /package/dist/types/components/vega-rich-text-editor/test/{extensions/table/table-annotation.test.d.ts → html-cleaner/remove-whitespace-between-tags-processor.test.d.ts} +0 -0
@@ -1 +1 @@
1
- import{h as t}from"./p-6b2342e0.js";import{a as e}from"./p-8c9ea6f4.js";import{c as o,V as s}from"./p-6e1ab235.js";import{A as r,P as i,b as n,$ as c,D as l,l as a}from"./p-5b048141.js";import{D as h,a as u,b as d,c as p,i as f}from"./p-11a6c1b7.js";import{a as v}from"./p-ef9cbad1.js";import{g as b}from"./p-b56b0b89.js";var m=function(t,e,o,s){var r,i=arguments.length,n=i<3?e:null===s?s=Object.getOwnPropertyDescriptor(e,o):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(t,e,o,s);else for(var c=t.length-1;c>=0;c--)(r=t[c])&&(n=(i<3?r(n):i>3?r(e,o,n):r(e,o))||n);return i>3&&n&&Object.defineProperty(e,o,n),n};class C extends s{constructor({icon:e,tooltip:o,autoFocusOnClick:s=!0}){super(),this.renderBtn=({showArrowIcon:e,iconColor:o}={})=>{var s;return t("vega-tooltip",{text:this.translationSlimmer.t(this.tooltip.text),placement:["bottom","top"]},t("vega-rich-text-editor-toolbar-button",Object.assign({showArrowIcon:e,icon:this.icon,iconColor:o,ref:t=>{h.addUniqueObserverToNode(t,u,(()=>{this.handleClick()}))},selected:this.isSelected(),disabled:this.isDisabled(),hidden:this.isHidden()},this.preventLostFocus()),null===(s=this.renderSlotContent)||void 0===s?void 0:s.call(this)))},this.handleClick=()=>{"function"==typeof this.onClick&&(!this.selectionController.getSelectedNodes().length&&this.autoFocusOnClick?this.focusController.focusOnLastTextNode().then((()=>{this.onClick()})):this.onClick())},this.icon=e,this.tooltip=o,this.autoFocusOnClick=s}setIcon(t){this.icon=t}isHidden(){return!1}render(){return"function"==typeof this.renderBtnWrapper?this.renderBtnWrapper(this.renderBtn):this.renderBtn()}isDisabled(){return this.disabled}preventLostFocus(){return{onMouseDown:t=>t.preventDefault()}}}m([o()],C.prototype,"translationSlimmer",void 0),m([o()],C.prototype,"selectionController",void 0),m([o()],C.prototype,"focusController",void 0),m([o()],C.prototype,"disabled",void 0);class w extends C{constructor(t){super(t)}isHidden(){return this.sourceView}isDisabled(){return super.isDisabled()&&!this.sourceView}shouldDisabledToolbar(t,e){return t&&!r.canHandle(e,t)}}!function(t,e,o,s){var r,i=arguments.length,n=i<3?e:null===s?s=Object.getOwnPropertyDescriptor(e,o):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(t,e,o,s);else for(var c=t.length-1;c>=0;c--)(r=t[c])&&(n=(i<3?r(n):i>3?r(e,o,n):r(e,o))||n);i>3&&n&&Object.defineProperty(e,o,n)}([o()],w.prototype,"sourceView",void 0);var j=function(t,e,o,s){var r,i=arguments.length,n=i<3?e:null===s?s=Object.getOwnPropertyDescriptor(e,o):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(t,e,o,s);else for(var c=t.length-1;c>=0;c--)(r=t[c])&&(n=(i<3?r(n):i>3?r(e,o,n):r(e,o))||n);return i>3&&n&&Object.defineProperty(e,o,n),n};class x extends w{constructor(){super({icon:"text",tooltip:{text:"Text Color"}}),this.popoverShow=!1,v.registerCustomDarkModeColor(x.formatDarkModeColor())}static formatDarkModeColor(){return i.reduce(((t,e)=>(e.dark&&(t[`rich-text-editor-${e.key}`]=e.dark),t)),{})}renderSlotContent(){return t("div",{class:{"toolbar-btn-color-preview-box":!0,disabled:this.isDisabled()},style:{backgroundColor:this.getCurrentColor()}})}handlePopoverShowChange(){this.popoverShow=!0}handlePopoverHideChange(){this.popoverShow=!1}renderBtnWrapper(e){return t("vega-popover",{placement:"bottom",alignment:"center",ref:t=>{this.popoverRef=t,h.addUniqueObserverToNode(t,d,this.handlePopoverShowChange.bind(this)),h.addUniqueObserverToNode(t,p,this.handlePopoverHideChange.bind(this))}},t("div",{slot:"popover-content"},e({showArrowIcon:!1})),t("div",Object.assign({slot:"popover",style:{userSelect:"none"}},super.preventLostFocus()),this.renderPopoverContent()))}renderPopoverContent(){return t("vega-color-picker",{isInline:!0,colors:i.map((t=>t[this.isInDarkMode?"dark":"light"])),ref:t=>{h.addUniqueObserverToNode(t,f,this.handleChange.bind(this))},value:this.getCurrentColor()})}async handleChange(t){this.popoverShow&&(this.selectionController.getSelectedNodes().length||await this.focusController.focusOnLastTextNode(),this.selectionController.getSelectedNodes().filter((t=>t instanceof n)).forEach((e=>e.apply(new c(this.matchColor(t.detail).key))))),this.popoverRef.hide()}matchColor(t){return i.find((e=>e[this.isInDarkMode?"dark":"light"]===t))}getCurrentColor(){let t=i[0];const e=this.selectionController.getSelectedNodes();return e.length>1&&(t=this.isSelectedSameColor(e)?this.getTextColor(e[0]):null),1===e.length&&(t=this.getTextColor(e[0])),t?t[this.isInDarkMode?"dark":"light"]:null}isSelected(){return!1}isSelectedSameColor(t){return t.every((e=>this.getTextColor(e).key===this.getTextColor(t[0]).key))}getTextColor(t){var e;return(null===(e=t.getAnnotationByType("TEXT_COLOR"))||void 0===e?void 0:e.textColor)||i[0]}isDisabled(){const t=this.selectionController.getSelectedNodes();return super.isDisabled()||t.some((t=>{var e;return(null===(e=t.getAnnotationByType(l.CODE))||void 0===e?void 0:e.code)||t.getAnnotationByType(l.LINK)||this.shouldDisabledToolbar(t,c.name)}))}}e.register({text:{icon:'<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 448 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="M64 96v32c0 17.7-14.3 32-32 32s-32-14.3-32-32V80C0 53.5 21.5 32 48 32H224 400c26.5 0 48 21.5 48 48v48c0 17.7-14.3 32-32 32s-32-14.3-32-32V96H256l0 320h48c17.7 0 32 14.3 32 32s-14.3 32-32 32H144c-17.7 0-32-14.3-32-32s14.3-32 32-32h48l0-320H64z"/></svg>'}}),j([o()],x.prototype,"host",void 0),j([o()],x.prototype,"isInDarkMode",void 0),j([o()],x.prototype,"selectionController",void 0),j([o()],x.prototype,"focusController",void 0);class g extends a{constructor(t,e){super(),this.isFlushable=!0,this.size=t,this.alt=e}toAnnotation(){return new b(this.size,this.alt)}}export{g as I,x as T,w as V,C as a}
1
+ import{h as t}from"./p-6b2342e0.js";import{a as e}from"./p-8c9ea6f4.js";import{c as o,V as s}from"./p-6e1ab235.js";import{A as r,O as i,b as n,$ as c,y as l,F as a}from"./p-6f8be8ea.js";import{D as h,a as u,W as d,X as p,g as f}from"./p-8d0ca805.js";import{a as v}from"./p-ef9cbad1.js";import{g as b}from"./p-b1f869fb.js";var m=function(t,e,o,s){var r,i=arguments.length,n=i<3?e:null===s?s=Object.getOwnPropertyDescriptor(e,o):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(t,e,o,s);else for(var c=t.length-1;c>=0;c--)(r=t[c])&&(n=(i<3?r(n):i>3?r(e,o,n):r(e,o))||n);return i>3&&n&&Object.defineProperty(e,o,n),n};class C extends s{constructor({icon:e,tooltip:o,autoFocusOnClick:s=!0}){super(),this.renderBtn=({showArrowIcon:e,iconColor:o}={})=>{var s;return t("vega-tooltip",{text:this.translationSlimmer.t(this.tooltip.text),placement:["bottom","top"]},t("vega-rich-text-editor-toolbar-button",Object.assign({showArrowIcon:e,icon:this.icon,iconColor:o,ref:t=>{h.addUniqueObserverToNode(t,u,(()=>{this.handleClick()}))},selected:this.isSelected(),disabled:this.isDisabled(),hidden:this.isHidden()},this.preventLostFocus()),null===(s=this.renderSlotContent)||void 0===s?void 0:s.call(this)))},this.handleClick=()=>{"function"==typeof this.onClick&&(!this.selectionController.getSelectedNodes().length&&this.autoFocusOnClick?this.focusController.focusOnLastTextNode().then((()=>{this.onClick()})):this.onClick())},this.icon=e,this.tooltip=o,this.autoFocusOnClick=s}setIcon(t){this.icon=t}isHidden(){return!1}render(){return"function"==typeof this.renderBtnWrapper?this.renderBtnWrapper(this.renderBtn):this.renderBtn()}isDisabled(){return this.disabled}preventLostFocus(){return{onMouseDown:t=>t.preventDefault()}}}m([o()],C.prototype,"translationSlimmer",void 0),m([o()],C.prototype,"selectionController",void 0),m([o()],C.prototype,"focusController",void 0),m([o()],C.prototype,"disabled",void 0);class w extends C{constructor(t){super(t)}isHidden(){return this.sourceView}isDisabled(){return super.isDisabled()&&!this.sourceView}shouldDisabledToolbar(t,e){return t&&!r.canHandle(e,t)}}!function(t,e,o,s){var r,i=arguments.length,n=i<3?e:null===s?s=Object.getOwnPropertyDescriptor(e,o):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(t,e,o,s);else for(var c=t.length-1;c>=0;c--)(r=t[c])&&(n=(i<3?r(n):i>3?r(e,o,n):r(e,o))||n);i>3&&n&&Object.defineProperty(e,o,n)}([o()],w.prototype,"sourceView",void 0);var g=function(t,e,o,s){var r,i=arguments.length,n=i<3?e:null===s?s=Object.getOwnPropertyDescriptor(e,o):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(t,e,o,s);else for(var c=t.length-1;c>=0;c--)(r=t[c])&&(n=(i<3?r(n):i>3?r(e,o,n):r(e,o))||n);return i>3&&n&&Object.defineProperty(e,o,n),n};class x extends w{constructor(){super({icon:"text",tooltip:{text:"Text Color"}}),this.popoverShow=!1,v.registerCustomDarkModeColor(x.formatDarkModeColor())}static formatDarkModeColor(){return i.reduce(((t,e)=>(e.dark&&(t[`rich-text-editor-${e.key}`]=e.dark),t)),{})}renderSlotContent(){return t("div",{class:{"toolbar-btn-color-preview-box":!0,disabled:this.isDisabled()},style:{backgroundColor:this.getCurrentColor()}})}handlePopoverShowChange(){this.popoverShow=!0}handlePopoverHideChange(){this.popoverShow=!1}renderBtnWrapper(e){return t("vega-popover",{placement:"bottom",alignment:"center",ref:t=>{this.popoverRef=t,h.addUniqueObserverToNode(t,d,this.handlePopoverShowChange.bind(this)),h.addUniqueObserverToNode(t,p,this.handlePopoverHideChange.bind(this))}},t("div",{slot:"popover-content"},e({showArrowIcon:!1})),t("div",Object.assign({slot:"popover",style:{userSelect:"none"}},super.preventLostFocus()),this.renderPopoverContent()))}renderPopoverContent(){return t("vega-color-picker",{isInline:!0,colors:i.map((t=>t[this.isInDarkMode?"dark":"light"])),ref:t=>{h.addUniqueObserverToNode(t,f,this.handleChange.bind(this))},value:this.getCurrentColor()})}async handleChange(t){this.popoverShow&&(this.selectionController.getSelectedNodes().length||await this.focusController.focusOnLastTextNode(),this.selectionController.getSelectedNodes().filter((t=>t instanceof n)).forEach((e=>e.apply(new c(this.matchColor(t.detail).key))))),this.popoverRef.hide()}matchColor(t){return i.find((e=>e[this.isInDarkMode?"dark":"light"]===t))}getCurrentColor(){let t=i[0];const e=this.selectionController.getSelectedNodes();return e.length>1&&(t=this.isSelectedSameColor(e)?this.getTextColor(e[0]):null),1===e.length&&(t=this.getTextColor(e[0])),t?t[this.isInDarkMode?"dark":"light"]:null}isSelected(){return!1}isSelectedSameColor(t){return t.every((e=>this.getTextColor(e).key===this.getTextColor(t[0]).key))}getTextColor(t){var e;return(null===(e=t.getAnnotationByType("TEXT_COLOR"))||void 0===e?void 0:e.textColor)||i[0]}isDisabled(){const t=this.selectionController.getSelectedNodes();return super.isDisabled()||t.some((t=>{var e;return(null===(e=t.getAnnotationByType(l.CODE))||void 0===e?void 0:e.code)||t.getAnnotationByType(l.LINK)||this.shouldDisabledToolbar(t,c.name)}))}}e.register({text:{icon:'<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 448 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="M64 96v32c0 17.7-14.3 32-32 32s-32-14.3-32-32V80C0 53.5 21.5 32 48 32H224 400c26.5 0 48 21.5 48 48v48c0 17.7-14.3 32-32 32s-32-14.3-32-32V96H256l0 320h48c17.7 0 32 14.3 32 32s-14.3 32-32 32H144c-17.7 0-32-14.3-32-32s14.3-32 32-32h48l0-320H64z"/></svg>'}}),g([o()],x.prototype,"host",void 0),g([o()],x.prototype,"isInDarkMode",void 0),g([o()],x.prototype,"selectionController",void 0),g([o()],x.prototype,"focusController",void 0);const j=new class{constructor(){this.textNodeElements=new Map}register(t,e){this.textNodeElements.set(t,e)}getTextNodeElements(){return this.textNodeElements}};class y extends a{constructor(t,e){super(),this.isFlushable=!0,this.size=t,this.alt=e}toAnnotation(){return new b(this.size,this.alt)}}export{y as I,j as T,w as V,x as a,C as b}
@@ -1 +1 @@
1
- import{j as r,k as e,b as t,e as a,l as s,f as o,g as n,m as i,n as u,o as f,p as c,q as l,r as d,s as b,t as v,u as p,h as m,v as $,B as h,C as g,w as j}from"./p-1f83cebf.js";import{B as k}from"./p-ed45b3b6.js";import{L as w}from"./p-6e1ab235.js";import{R as x}from"./p-ebb14c84.js";import{a as T}from"./p-d884c644.js";import{B as O}from"./p-40f39194.js";const C=new class extends r{constructor(){super(...arguments),this.states=["default","focus-visible","hover","active"]}formatToken(r){return e(r)?`border-color: ${a[r]};`:(w.warn(`The borderColor value ${r} is invalid, it must be a value of: `,t),"")}getStates(){return this.states}},S=new class extends r{constructor(){super(...arguments),this.states=["default","focus-visible","hover"]}formatToken(r){return s(r)?`box-shadow: ${n[r]};`:(w.warn(`The shadow value ${r} is invalid, it must be a value of: `,o),"")}getStates(){return this.states}},B=new class extends r{constructor(){super(...arguments),this.states=["default","focus-visible","hover","active"]}formatToken(r){return i(r)?`border: ${f[r]};`:(w.warn(`The border value ${r} is invalid, it must be a value of: `,u),"")}getStates(){return this.states}},F=new class{format(r,e){switch(e){case"backgroundColor":return c.format(r);case"borderColor":return C.format(r);case"shadow":return S.format(r);case"border":return B.format(r);default:throw new Error(`Invalid flag ${e} passed into StateFormatFacade`)}}};function q(r,e,t){w.warn(`The ${r} value ${e} is invalid, it must be a value of: `,t)}function y(r,e){let t="";return e.includes("dark")&&(t+=` dark:v-dark-${r}`),t}function E(r){if(l(r))return`v-p-${r}`;q("padding",r,Object.keys(m))}function I(r){if($(r))return`v-border-${r}`;q("border-style",r,O)}function L(r){if(d(r))return`v-${r}`;q("border-radius",r,Object.keys(h))}function R(r){if(e(r))return`v-${r}`;q("border-color",r,g.filter((()=>/^border-color-.+$/.test)))}function z(r,e=[]){if(b(r))return`v-${r}`+y(r,e);q("background-color",r,g.filter((()=>/^bg-.+$/.test)))}function A(r,e=[]){if(v(r))return`v-${r}`+y(r,e);q("text-color",r,g.filter((()=>/^text-.+$/.test)))}function D(r){if(p(r))return`vega-flex-${r}`;q("breakpoint",r,Object.keys(k))}function G(r){if(p(r))return k[r];q("breakpoint",r,Object.keys(k))}function H(r){if(l(r))return`v-gap-${r}`;q("gap",r,Object.keys(m))}function J(r,e=[]){if(s(r))return`v-${r}`+y(r,e);q("shadows",r,o)}function K(r,e){if(null!=r)return x.format(r,e)}function M(r){if(j(r))return`v-${r}`;q("font",r,T)}function N(r,e){if(null!=r)return F.format(r,e)}export{H as a,J as b,G as c,z as d,R as e,K as f,L as g,E as h,A as i,N as j,I as k,D as l,M as m}
1
+ import{j as r,k as e,b as t,e as a,l as s,f as o,g as n,m as i,n as u,o as f,p as c,q as l,r as d,s as b,t as v,u as p,h as m,v as $,B as h,C as g,w as j}from"./p-1f83cebf.js";import{B as k}from"./p-ed45b3b6.js";import{L as w}from"./p-6e1ab235.js";import{R as x}from"./p-430be941.js";import{a as T}from"./p-d884c644.js";import{B as O}from"./p-40f39194.js";const C=new class extends r{constructor(){super(...arguments),this.states=["default","focus-visible","hover","active"]}formatToken(r){return e(r)?`border-color: ${a[r]};`:(w.warn(`The borderColor value ${r} is invalid, it must be a value of: `,t),"")}getStates(){return this.states}},S=new class extends r{constructor(){super(...arguments),this.states=["default","focus-visible","hover"]}formatToken(r){return s(r)?`box-shadow: ${n[r]};`:(w.warn(`The shadow value ${r} is invalid, it must be a value of: `,o),"")}getStates(){return this.states}},B=new class extends r{constructor(){super(...arguments),this.states=["default","focus-visible","hover","active"]}formatToken(r){return i(r)?`border: ${f[r]};`:(w.warn(`The border value ${r} is invalid, it must be a value of: `,u),"")}getStates(){return this.states}},F=new class{format(r,e){switch(e){case"backgroundColor":return c.format(r);case"borderColor":return C.format(r);case"shadow":return S.format(r);case"border":return B.format(r);default:throw new Error(`Invalid flag ${e} passed into StateFormatFacade`)}}};function q(r,e,t){w.warn(`The ${r} value ${e} is invalid, it must be a value of: `,t)}function y(r,e){let t="";return e.includes("dark")&&(t+=` dark:v-dark-${r}`),t}function E(r){if(l(r))return`v-p-${r}`;q("padding",r,Object.keys(m))}function I(r){if($(r))return`v-border-${r}`;q("border-style",r,O)}function L(r){if(d(r))return`v-${r}`;q("border-radius",r,Object.keys(h))}function R(r){if(e(r))return`v-${r}`;q("border-color",r,g.filter((()=>/^border-color-.+$/.test)))}function z(r,e=[]){if(b(r))return`v-${r}`+y(r,e);q("background-color",r,g.filter((()=>/^bg-.+$/.test)))}function A(r,e=[]){if(v(r))return`v-${r}`+y(r,e);q("text-color",r,g.filter((()=>/^text-.+$/.test)))}function D(r){if(p(r))return`vega-flex-${r}`;q("breakpoint",r,Object.keys(k))}function G(r){if(p(r))return k[r];q("breakpoint",r,Object.keys(k))}function H(r){if(l(r))return`v-gap-${r}`;q("gap",r,Object.keys(m))}function J(r,e=[]){if(s(r))return`v-${r}`+y(r,e);q("shadows",r,o)}function K(r,e){if(null!=r)return x.format(r,e)}function M(r){if(j(r))return`v-${r}`;q("font",r,T)}function N(r,e){if(null!=r)return F.format(r,e)}export{H as a,J as b,G as c,z as d,R as e,K as f,L as g,E as h,A as i,N as j,I as k,D as l,M as m}
@@ -1 +1 @@
1
- import{h as t,r as e,H as i,g as o}from"./p-6b2342e0.js";import{c as r,V as s,I as a}from"./p-6e1ab235.js";import{V as n,I as l}from"./p-d849e0f5.js";import{s as c}from"./p-519a7d55.js";import{D as f,C as p,J as h,a as v,d,i as m}from"./p-11a6c1b7.js";import{n as u,c as g}from"./p-262ec334.js";import{f as b}from"./p-d9671d27.js";import{C as j}from"./p-2d0d575f.js";import{u as y}from"./p-1b44db34.js";import{C as x}from"./p-89083d63.js";import"./p-331a62d5.js";import"./p-3532aa12.js";import"./p-5f377954.js";import"./p-e77a83e4.js";import"./p-db8cdba6.js";import"./p-112455b1.js";var R=function(t,e,i,o){var r,s=arguments.length,a=s<3?e:null===o?o=Object.getOwnPropertyDescriptor(e,i):o;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(t,e,i,o);else for(var n=t.length-1;n>=0;n--)(r=t[n])&&(a=(s<3?r(a):s>3?r(e,i,a):r(e,i))||a);return s>3&&a&&Object.defineProperty(e,i,a),a};class C extends s{constructor(){super(...arguments),this.handleChange=()=>{if(this.inputRef.value){const t=u(g(this.inputRef.value,1),1,this.pageCount);this.inputRef.value=t.toString(),this.prevAndNextButtonRenderer.notifyParentPagination(t.toString())}}}render(){return"pageSelectorMobile"===this.type?this.renderPageSelectorMobile():this.renderPageSelectorMobileAndGoTo()}renderPageSelectorMobile(){return t("vega-flex",{alignItems:"center",justifyContent:"center",gap:"size-8"},this.prevAndNextButtonRenderer.render("prev"),t("vega-font",{variant:"font-field-label",color:"text-primary"},this.current.toString()),t("vega-font",{variant:"font-field-label",color:"text-primary"},"/"),t("vega-font",{variant:"font-field-label",color:"text-primary"},this.pageCount.toString()),this.prevAndNextButtonRenderer.render("next"))}renderPageSelectorMobileAndGoTo(){return t("vega-flex",{alignItems:"center",justifyContent:"center",gap:"size-8"},this.prevAndNextButtonRenderer.render("prev"),t("vega-form",{ref:t=>{f.addUniqueObserverToNode(t,p,this.handleChange)}},t("vega-input",{"data-vega-form":"pageSelectorMobile_goTo",size:"small",showClearIcon:!1,style:{width:"54px"},maskConfig:{type:"number",options:{allowNegative:!1,precision:0}},value:this.current.toString(),ref:t=>{this.inputRef=t,f.addUniqueObserverToNode(t,h,this.handleChange)}})),t("vega-font",{variant:"font-field-label",color:"text-primary"},"/"),t("vega-font",{variant:"font-field-label",color:"text-primary"},this.pageCount.toString()),this.prevAndNextButtonRenderer.render("next"))}}R([r()],C.prototype,"host",void 0),R([r()],C.prototype,"type",void 0),R([r()],C.prototype,"current",void 0),R([r()],C.prototype,"pageCount",void 0),R([r()],C.prototype,"prevAndNextButtonRenderer",void 0);var w=function(t,e,i,o){var r,s=arguments.length,a=s<3?e:null===o?o=Object.getOwnPropertyDescriptor(e,i):o;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(t,e,i,o);else for(var n=t.length-1;n>=0;n--)(r=t[n])&&(a=(s<3?r(a):s>3?r(e,i,a):r(e,i))||a);return s>3&&a&&Object.defineProperty(e,i,a),a};class S extends s{constructor(){super(...arguments),this.pagerButton=(e,i,o)=>t("vega-button-circle",{variant:"icon-only",icon:e,iconColor:"text-link",size:"small",disabled:i,ref:t=>{f.addUniqueObserverToNode(t,v,o)}}),this.renderPrevButton=()=>this.pagerButton("chevron-left",0===this.total||1===this.current,(()=>{this.notifyParentPagination((this.current-1).toString())})),this.renderNextButton=()=>this.pagerButton("chevron-right",0===this.total||this.current===this.pageCount,(()=>{this.notifyParentPagination((this.current+1).toString())}))}notifyParentPagination(t){const e=b(this.host,"vega-pagination");e&&j.notify(d.getSubject(e,y),{host:this.host,detail:t})}render(t){return"prev"===t?this.renderPrevButton():this.renderNextButton()}}w([r()],S.prototype,"host",void 0),w([r()],S.prototype,"current",void 0),w([r()],S.prototype,"total",void 0),w([r()],S.prototype,"pageCount",void 0);var M=function(t,e,i,o){var r,s=arguments.length,a=s<3?e:null===o?o=Object.getOwnPropertyDescriptor(e,i):o;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(t,e,i,o);else for(var n=t.length-1;n>=0;n--)(r=t[n])&&(a=(s<3?r(a):s>3?r(e,i,a):r(e,i))||a);return s>3&&a&&Object.defineProperty(e,i,a),a};const O=class{constructor(t){e(this,t),this.globalSlimmers={},this.vegaComponentUsageRuntimeMetricsSlimmer=new n,this.childEventPrevent=new x([m],(()=>this.host)),this.pageSelectorMobileRenderer=new C,this.prevAndNextButtonRenderer=new S,this.pageCount=0,this.current=1,this.total=0}render(){return c(t(i,null,this.pageSelectorMobileRenderer.render()),this.host)}get host(){return o(this)}};M([l()],O.prototype,"globalSlimmers",void 0),M([a()],O.prototype,"vegaComponentUsageRuntimeMetricsSlimmer",void 0),M([a()],O.prototype,"childEventPrevent",void 0),M([a()],O.prototype,"pageSelectorMobileRenderer",void 0),M([a()],O.prototype,"prevAndNextButtonRenderer",void 0),O.style=":host{display:inline-block}";export{O as vega_pagination_page_selector_mobile}
1
+ import{h as t,r as e,H as i,g as o}from"./p-6b2342e0.js";import{c as r,V as s,I as a}from"./p-6e1ab235.js";import{V as n,I as l}from"./p-d849e0f5.js";import{s as c}from"./p-519a7d55.js";import{D as f,A as p,H as h,a as v,d,g as m}from"./p-8d0ca805.js";import{n as g,c as u}from"./p-262ec334.js";import{f as b}from"./p-d9671d27.js";import{C as j}from"./p-2d0d575f.js";import{r as y}from"./p-5b71c85e.js";import{C as x}from"./p-c9b6b5a9.js";import"./p-331a62d5.js";import"./p-fe12eff6.js";import"./p-5f377954.js";import"./p-e77a83e4.js";import"./p-db8cdba6.js";import"./p-112455b1.js";var R=function(t,e,i,o){var r,s=arguments.length,a=s<3?e:null===o?o=Object.getOwnPropertyDescriptor(e,i):o;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(t,e,i,o);else for(var n=t.length-1;n>=0;n--)(r=t[n])&&(a=(s<3?r(a):s>3?r(e,i,a):r(e,i))||a);return s>3&&a&&Object.defineProperty(e,i,a),a};class C extends s{constructor(){super(...arguments),this.handleChange=()=>{if(this.inputRef.value){const t=g(u(this.inputRef.value,1),1,this.pageCount);this.inputRef.value=t.toString(),this.prevAndNextButtonRenderer.notifyParentPagination(t.toString())}}}render(){return"pageSelectorMobile"===this.type?this.renderPageSelectorMobile():this.renderPageSelectorMobileAndGoTo()}renderPageSelectorMobile(){return t("vega-flex",{alignItems:"center",justifyContent:"center",gap:"size-8"},this.prevAndNextButtonRenderer.render("prev"),t("vega-font",{variant:"font-field-label",color:"text-primary"},this.current.toString()),t("vega-font",{variant:"font-field-label",color:"text-primary"},"/"),t("vega-font",{variant:"font-field-label",color:"text-primary"},this.pageCount.toString()),this.prevAndNextButtonRenderer.render("next"))}renderPageSelectorMobileAndGoTo(){return t("vega-flex",{alignItems:"center",justifyContent:"center",gap:"size-8"},this.prevAndNextButtonRenderer.render("prev"),t("vega-form",{ref:t=>{f.addUniqueObserverToNode(t,p,this.handleChange)}},t("vega-input",{"data-vega-form":"pageSelectorMobile_goTo",size:"small",showClearIcon:!1,style:{width:"54px"},maskConfig:{type:"number",options:{allowNegative:!1,precision:0}},value:this.current.toString(),ref:t=>{this.inputRef=t,f.addUniqueObserverToNode(t,h,this.handleChange)}})),t("vega-font",{variant:"font-field-label",color:"text-primary"},"/"),t("vega-font",{variant:"font-field-label",color:"text-primary"},this.pageCount.toString()),this.prevAndNextButtonRenderer.render("next"))}}R([r()],C.prototype,"host",void 0),R([r()],C.prototype,"type",void 0),R([r()],C.prototype,"current",void 0),R([r()],C.prototype,"pageCount",void 0),R([r()],C.prototype,"prevAndNextButtonRenderer",void 0);var w=function(t,e,i,o){var r,s=arguments.length,a=s<3?e:null===o?o=Object.getOwnPropertyDescriptor(e,i):o;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(t,e,i,o);else for(var n=t.length-1;n>=0;n--)(r=t[n])&&(a=(s<3?r(a):s>3?r(e,i,a):r(e,i))||a);return s>3&&a&&Object.defineProperty(e,i,a),a};class S extends s{constructor(){super(...arguments),this.pagerButton=(e,i,o)=>t("vega-button-circle",{variant:"icon-only",icon:e,iconColor:"text-link",size:"small",disabled:i,ref:t=>{f.addUniqueObserverToNode(t,v,o)}}),this.renderPrevButton=()=>this.pagerButton("chevron-left",0===this.total||1===this.current,(()=>{this.notifyParentPagination((this.current-1).toString())})),this.renderNextButton=()=>this.pagerButton("chevron-right",0===this.total||this.current===this.pageCount,(()=>{this.notifyParentPagination((this.current+1).toString())}))}notifyParentPagination(t){const e=b(this.host,"vega-pagination");e&&j.notify(d.getSubject(e,y),{host:this.host,detail:t})}render(t){return"prev"===t?this.renderPrevButton():this.renderNextButton()}}w([r()],S.prototype,"host",void 0),w([r()],S.prototype,"current",void 0),w([r()],S.prototype,"total",void 0),w([r()],S.prototype,"pageCount",void 0);var M=function(t,e,i,o){var r,s=arguments.length,a=s<3?e:null===o?o=Object.getOwnPropertyDescriptor(e,i):o;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(t,e,i,o);else for(var n=t.length-1;n>=0;n--)(r=t[n])&&(a=(s<3?r(a):s>3?r(e,i,a):r(e,i))||a);return s>3&&a&&Object.defineProperty(e,i,a),a};const O=class{constructor(t){e(this,t),this.globalSlimmers={},this.vegaComponentUsageRuntimeMetricsSlimmer=new n,this.childEventPrevent=new x([m],(()=>this.host)),this.pageSelectorMobileRenderer=new C,this.prevAndNextButtonRenderer=new S,this.pageCount=0,this.current=1,this.total=0}render(){return c(t(i,null,this.pageSelectorMobileRenderer.render()),this.host)}get host(){return o(this)}};M([l()],O.prototype,"globalSlimmers",void 0),M([a()],O.prototype,"vegaComponentUsageRuntimeMetricsSlimmer",void 0),M([a()],O.prototype,"childEventPrevent",void 0),M([a()],O.prototype,"pageSelectorMobileRenderer",void 0),M([a()],O.prototype,"prevAndNextButtonRenderer",void 0),O.style=":host{display:inline-block}";export{O as vega_pagination_page_selector_mobile}
@@ -1 +1 @@
1
- import{h as t,r as e,c as i,H as s,g as o}from"./p-6b2342e0.js";import{s as r}from"./p-519a7d55.js";import{c as a,V as n,M as p,I as l}from"./p-6e1ab235.js";import{V as h,I as c}from"./p-d849e0f5.js";import{D as m,i as f,J as u}from"./p-11a6c1b7.js";import{n as d,c as v,b}from"./p-262ec334.js";import{C as j}from"./p-89083d63.js";import{c as w}from"./p-c841be8d.js";import{F as x}from"./p-a528714c.js";import{C as y}from"./p-2d0d575f.js";import{K as R}from"./p-920719ad.js";import{F as C}from"./p-20010bd6.js";import{R as g}from"./p-280cbcdb.js";import{c as I}from"./p-e819940c.js";import{M as V,a as N}from"./p-f0ff4463.js";import"./p-331a62d5.js";import"./p-d9671d27.js";import"./p-3532aa12.js";import"./p-5f377954.js";import"./p-e77a83e4.js";import"./p-db8cdba6.js";import"./p-112455b1.js";import"./p-6a334573.js";import"./p-b75ee3ba.js";import"./p-476a173a.js";import"./p-1f83cebf.js";import"./p-ed45b3b6.js";import"./p-40f39194.js";import"./p-d884c644.js";import"./p-f69f84a7.js";import"./p-a4670e23.js";import"./p-02841589.js";import"./p-1b44db34.js";import"./p-10ac8b57.js";import"./p-abd7aeaa.js";import"./p-78a57a17.js";import"./p-52b8f2d2.js";import"./p-d27ae9ff.js";import"./p-0d57293b.js";var T=function(t,e,i,s){var o,r=arguments.length,a=r<3?e:null===s?s=Object.getOwnPropertyDescriptor(e,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(t,e,i,s);else for(var n=t.length-1;n>=0;n--)(o=t[n])&&(a=(r<3?o(a):r>3?o(e,i,a):o(e,i))||a);return r>3&&a&&Object.defineProperty(e,i,a),a};class S extends n{constructor(){super(...arguments),this.onInputChange=t=>{this.valueController.updateValue(t.detail)},this.onInputBlur=t=>{const e=t.host.value.replace(/,/g,"");if(""!==e&&!isNaN(e)){let t=d(Number(e),this.min,this.max);this.integerOnly&&(t===this.min?t=Math.ceil(this.min):t===this.max&&(t=Math.floor(this.max))),t!==Number(e)&&this.valueController.updateValue(t.toString())}}}getInputRef(){return this.vegaInputRef.shadowRoot.querySelector("input")}getContainerRef(){return this.vegaInputRef.shadowRoot.querySelector(".vega-input-container")}render(){const e={thousandComma:this.thousandComma};return this.integerOnly&&(e.precision=0),t("vega-input",{value:this.value||"",showClearIcon:this.showClearIcon,disabled:this.disabled,label:this.label,hint:this.hint,required:this.required,type:"number",placeholder:this.placeholder,size:"small"===this.size?"small":"default",prefixIcon:this.prefixIcon,ref:t=>{this.vegaInputRef=t,m.addUniqueObserverToNode(t,f,(t=>this.onInputChange(t))),m.addUniqueObserverToNode(t,u,(t=>this.onInputBlur(t)))},maskConfig:{type:"number",options:e}})}}T([a()],S.prototype,"prefixIcon",void 0),T([a()],S.prototype,"showClearIcon",void 0),T([a()],S.prototype,"value",void 0),T([a()],S.prototype,"size",void 0),T([a()],S.prototype,"disabled",void 0),T([a()],S.prototype,"placeholder",void 0),T([a()],S.prototype,"label",void 0),T([a()],S.prototype,"hint",void 0),T([a()],S.prototype,"required",void 0),T([a()],S.prototype,"thousandComma",void 0),T([a()],S.prototype,"integerOnly",void 0),T([a()],S.prototype,"min",void 0),T([a()],S.prototype,"max",void 0),T([a()],S.prototype,"valueController",void 0);var O=function(t,e,i,s){var o,r=arguments.length,a=r<3?e:null===s?s=Object.getOwnPropertyDescriptor(e,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(t,e,i,s);else for(var n=t.length-1;n>=0;n--)(o=t[n])&&(a=(r<3?o(a):r>3?o(e,i,a):o(e,i))||a);return r>3&&a&&Object.defineProperty(e,i,a),a};class k extends n{watchValue(){this.changeEventEmitter.emit(this.value),y.notify(x,{host:this.host,detail:this.value})}updateValue(t){this.value=t}}O([a()],k.prototype,"host",void 0),O([a({writable:!0})],k.prototype,"value",void 0),O([a()],k.prototype,"changeEventEmitter",void 0),O([p("watchValue")],k.prototype,"watchValue",null);var E=function(t,e,i,s){var o,r=arguments.length,a=r<3?e:null===s?s=Object.getOwnPropertyDescriptor(e,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(t,e,i,s);else for(var n=t.length-1;n>=0;n--)(o=t[n])&&(a=(r<3?o(a):r>3?o(e,i,a):o(e,i))||a);return r>3&&a&&Object.defineProperty(e,i,a),a};class A extends R{constructor(){super((t=>[{keyCode:["ArrowUp","ArrowDown"],activeElementInScope:[t.host],callback:t.onArrowUpOrDown},{keyCode:["ArrowUp"],eventName:"keydown",activeElementInScope:[t.host],callback:t=>{t.preventDefault()}}])),this.onArrowUpOrDown=t=>{const e=t.shiftKey?this.majorIncrement:this.minorIncrement,i=v(this.value.replace(/,/g,""))||0,s=Math.max(b(i),b(e));"ArrowUp"===t.code?this.valueController.updateValue(`${(i+e).toFixed(s)}`):"ArrowDown"===t.code&&this.valueController.updateValue(`${(i-e).toFixed(s)}`)}}}E([a()],A.prototype,"host",void 0),E([a()],A.prototype,"value",void 0),E([a()],A.prototype,"minorIncrement",void 0),E([a()],A.prototype,"majorIncrement",void 0),E([a()],A.prototype,"valueController",void 0);var F=function(t,e,i,s){var o,r=arguments.length,a=r<3?e:null===s?s=Object.getOwnPropertyDescriptor(e,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(t,e,i,s);else for(var n=t.length-1;n>=0;n--)(o=t[n])&&(a=(r<3?o(a):r>3?o(e,i,a):o(e,i))||a);return r>3&&a&&Object.defineProperty(e,i,a),a};const M=class{constructor(t){e(this,t),this.vegaChange=i(this,"vegaChange",7),this.change=i(this,"change",7),this.globalSlimmers={},this.valueController=new k,this.keyboardController=new A,this.renderer=new S,this.changeEventEmitter=w(M,f),this.inputEventPrevent=new j([f],(()=>this.host),{useCapture:!0}),this.formFieldController=new C({propertyRules:[{propertyName:"required",ruleFactory:t=>t?new g:null},{propertyName:"min",ruleFactory:t=>"number"==typeof t?new V({minValue:t}):null},{propertyName:"max",ruleFactory:t=>"number"==typeof t?new N({maxValue:t}):null}],validationRulesName:"validationRules",inputContainerGetter:()=>this.renderer.getContainerRef(),touchableAreaGetter:()=>[this.renderer.getInputRef()],defaultValue:"",attributeGetter:t=>this[t]}),this.prefixTextNotifySlimmer=I(M,"prefixText","watchPrefixText"),this.suffixTextNotifySlimmer=I(M,"suffixText","watchSuffixText"),this.isCompactInputWidthNotifySlimmer=I(M,"isCompactInputWidth"),this.vegaComponentUsageRuntimeMetricsSlimmer=new h,this.isCompactInputWidth=!0,this.prefixText="",this.value="",this.size="medium",this.thousandComma=!1,this.integerOnly=!1,this.disabled=!1,this.minorIncrement=1,this.majorIncrement=10,this.label="",this.validationRules=[],this.isValid=null,this.autoValidation=!0,this.showClearIcon=!0,this.min=null,this.max=null}watchPrefixText(){}watchSuffixText(){}watchValue(){}watchValidationRules(){}render(){return r(t(s,null,this.renderer.render()),this.host)}get host(){return o(this)}static get watchers(){return{prefixText:["watchPrefixText"],suffixText:["watchSuffixText"],value:["watchValue"],validationRules:["watchValidationRules"]}}};F([c()],M.prototype,"globalSlimmers",void 0),F([l()],M.prototype,"valueController",void 0),F([l()],M.prototype,"keyboardController",void 0),F([l()],M.prototype,"renderer",void 0),F([l()],M.prototype,"changeEventEmitter",void 0),F([l()],M.prototype,"inputEventPrevent",void 0),F([l()],M.prototype,"formFieldController",void 0),F([l()],M.prototype,"prefixTextNotifySlimmer",void 0),F([l()],M.prototype,"suffixTextNotifySlimmer",void 0),F([l()],M.prototype,"isCompactInputWidthNotifySlimmer",void 0),F([l()],M.prototype,"vegaComponentUsageRuntimeMetricsSlimmer",void 0),M.style=":host{display:inline-block;width:100%}";export{M as vega_input_numeric}
1
+ import{h as t,r as e,c as i,H as s,g as o}from"./p-6b2342e0.js";import{s as r}from"./p-519a7d55.js";import{c as a,V as n,M as p,I as l}from"./p-6e1ab235.js";import{V as h,I as c}from"./p-d849e0f5.js";import{D as f,g as m,H as u}from"./p-8d0ca805.js";import{n as d,c as v,b}from"./p-262ec334.js";import{C as j}from"./p-c9b6b5a9.js";import{c as w}from"./p-66fa700b.js";import{F as x}from"./p-a528714c.js";import{C as y}from"./p-2d0d575f.js";import{K as R}from"./p-920719ad.js";import{F as g}from"./p-6e136980.js";import{R as C}from"./p-280cbcdb.js";import{c as I}from"./p-77edf50c.js";import{M as V,a as N}from"./p-f0ff4463.js";import"./p-331a62d5.js";import"./p-d9671d27.js";import"./p-fe12eff6.js";import"./p-5f377954.js";import"./p-e77a83e4.js";import"./p-db8cdba6.js";import"./p-112455b1.js";import"./p-6a334573.js";import"./p-b75ee3ba.js";import"./p-476a173a.js";import"./p-1f83cebf.js";import"./p-ed45b3b6.js";import"./p-40f39194.js";import"./p-d884c644.js";import"./p-f69f84a7.js";import"./p-a4670e23.js";import"./p-02841589.js";import"./p-5b71c85e.js";import"./p-10ac8b57.js";import"./p-abd7aeaa.js";import"./p-78a57a17.js";import"./p-52b8f2d2.js";import"./p-d27ae9ff.js";import"./p-3bf66be2.js";var T=function(t,e,i,s){var o,r=arguments.length,a=r<3?e:null===s?s=Object.getOwnPropertyDescriptor(e,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(t,e,i,s);else for(var n=t.length-1;n>=0;n--)(o=t[n])&&(a=(r<3?o(a):r>3?o(e,i,a):o(e,i))||a);return r>3&&a&&Object.defineProperty(e,i,a),a};class S extends n{constructor(){super(...arguments),this.onInputChange=t=>{this.valueController.updateValue(t.detail)},this.onInputBlur=t=>{const e=t.host.value.replace(/,/g,"");if(""!==e&&!isNaN(e)){let t=d(Number(e),this.min,this.max);this.integerOnly&&(t===this.min?t=Math.ceil(this.min):t===this.max&&(t=Math.floor(this.max))),t!==Number(e)&&this.valueController.updateValue(t.toString())}}}getInputRef(){return this.vegaInputRef.shadowRoot.querySelector("input")}getContainerRef(){return this.vegaInputRef.shadowRoot.querySelector(".vega-input-container")}render(){const e={thousandComma:this.thousandComma};return this.integerOnly&&(e.precision=0),t("vega-input",{value:this.value||"",showClearIcon:this.showClearIcon,disabled:this.disabled,label:this.label,hint:this.hint,required:this.required,type:"number",placeholder:this.placeholder,size:"small"===this.size?"small":"default",prefixIcon:this.prefixIcon,ref:t=>{this.vegaInputRef=t,f.addUniqueObserverToNode(t,m,(t=>this.onInputChange(t))),f.addUniqueObserverToNode(t,u,(t=>this.onInputBlur(t)))},maskConfig:{type:"number",options:e}})}}T([a()],S.prototype,"prefixIcon",void 0),T([a()],S.prototype,"showClearIcon",void 0),T([a()],S.prototype,"value",void 0),T([a()],S.prototype,"size",void 0),T([a()],S.prototype,"disabled",void 0),T([a()],S.prototype,"placeholder",void 0),T([a()],S.prototype,"label",void 0),T([a()],S.prototype,"hint",void 0),T([a()],S.prototype,"required",void 0),T([a()],S.prototype,"thousandComma",void 0),T([a()],S.prototype,"integerOnly",void 0),T([a()],S.prototype,"min",void 0),T([a()],S.prototype,"max",void 0),T([a()],S.prototype,"valueController",void 0);var O=function(t,e,i,s){var o,r=arguments.length,a=r<3?e:null===s?s=Object.getOwnPropertyDescriptor(e,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(t,e,i,s);else for(var n=t.length-1;n>=0;n--)(o=t[n])&&(a=(r<3?o(a):r>3?o(e,i,a):o(e,i))||a);return r>3&&a&&Object.defineProperty(e,i,a),a};class k extends n{watchValue(){this.changeEventEmitter.emit(this.value),y.notify(x,{host:this.host,detail:this.value})}updateValue(t){this.value=t}}O([a()],k.prototype,"host",void 0),O([a({writable:!0})],k.prototype,"value",void 0),O([a()],k.prototype,"changeEventEmitter",void 0),O([p("watchValue")],k.prototype,"watchValue",null);var E=function(t,e,i,s){var o,r=arguments.length,a=r<3?e:null===s?s=Object.getOwnPropertyDescriptor(e,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(t,e,i,s);else for(var n=t.length-1;n>=0;n--)(o=t[n])&&(a=(r<3?o(a):r>3?o(e,i,a):o(e,i))||a);return r>3&&a&&Object.defineProperty(e,i,a),a};class A extends R{constructor(){super((t=>[{keyCode:["ArrowUp","ArrowDown"],activeElementInScope:[t.host],callback:t.onArrowUpOrDown},{keyCode:["ArrowUp"],eventName:"keydown",activeElementInScope:[t.host],callback:t=>{t.preventDefault()}}])),this.onArrowUpOrDown=t=>{const e=t.shiftKey?this.majorIncrement:this.minorIncrement,i=v(this.value.replace(/,/g,""))||0,s=Math.max(b(i),b(e));"ArrowUp"===t.code?this.valueController.updateValue(`${(i+e).toFixed(s)}`):"ArrowDown"===t.code&&this.valueController.updateValue(`${(i-e).toFixed(s)}`)}}}E([a()],A.prototype,"host",void 0),E([a()],A.prototype,"value",void 0),E([a()],A.prototype,"minorIncrement",void 0),E([a()],A.prototype,"majorIncrement",void 0),E([a()],A.prototype,"valueController",void 0);var F=function(t,e,i,s){var o,r=arguments.length,a=r<3?e:null===s?s=Object.getOwnPropertyDescriptor(e,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(t,e,i,s);else for(var n=t.length-1;n>=0;n--)(o=t[n])&&(a=(r<3?o(a):r>3?o(e,i,a):o(e,i))||a);return r>3&&a&&Object.defineProperty(e,i,a),a};const M=class{constructor(t){e(this,t),this.vegaChange=i(this,"vegaChange",7),this.change=i(this,"change",7),this.globalSlimmers={},this.valueController=new k,this.keyboardController=new A,this.renderer=new S,this.changeEventEmitter=w(M,m),this.inputEventPrevent=new j([m],(()=>this.host),{useCapture:!0}),this.formFieldController=new g({propertyRules:[{propertyName:"required",ruleFactory:t=>t?new C:null},{propertyName:"min",ruleFactory:t=>"number"==typeof t?new V({minValue:t}):null},{propertyName:"max",ruleFactory:t=>"number"==typeof t?new N({maxValue:t}):null}],validationRulesName:"validationRules",inputContainerGetter:()=>this.renderer.getContainerRef(),touchableAreaGetter:()=>[this.renderer.getInputRef()],defaultValue:"",attributeGetter:t=>this[t]}),this.prefixTextNotifySlimmer=I(M,"prefixText","watchPrefixText"),this.suffixTextNotifySlimmer=I(M,"suffixText","watchSuffixText"),this.isCompactInputWidthNotifySlimmer=I(M,"isCompactInputWidth"),this.vegaComponentUsageRuntimeMetricsSlimmer=new h,this.isCompactInputWidth=!0,this.prefixText="",this.value="",this.size="medium",this.thousandComma=!1,this.integerOnly=!1,this.disabled=!1,this.minorIncrement=1,this.majorIncrement=10,this.label="",this.validationRules=[],this.isValid=null,this.autoValidation=!0,this.showClearIcon=!0,this.min=null,this.max=null}watchPrefixText(){}watchSuffixText(){}watchValue(){}watchValidationRules(){}render(){return r(t(s,null,this.renderer.render()),this.host)}get host(){return o(this)}static get watchers(){return{prefixText:["watchPrefixText"],suffixText:["watchSuffixText"],value:["watchValue"],validationRules:["watchValidationRules"]}}};F([c()],M.prototype,"globalSlimmers",void 0),F([l()],M.prototype,"valueController",void 0),F([l()],M.prototype,"keyboardController",void 0),F([l()],M.prototype,"renderer",void 0),F([l()],M.prototype,"changeEventEmitter",void 0),F([l()],M.prototype,"inputEventPrevent",void 0),F([l()],M.prototype,"formFieldController",void 0),F([l()],M.prototype,"prefixTextNotifySlimmer",void 0),F([l()],M.prototype,"suffixTextNotifySlimmer",void 0),F([l()],M.prototype,"isCompactInputWidthNotifySlimmer",void 0),F([l()],M.prototype,"vegaComponentUsageRuntimeMetricsSlimmer",void 0),M.style=":host{display:inline-block;width:100%}";export{M as vega_input_numeric}
@@ -1 +1 @@
1
- import{V as t,I as e,c as s,M as i}from"./p-6e1ab235.js";import{c as r}from"./p-02841589.js";import{C as o}from"./p-2d0d575f.js";import{O as n}from"./p-331a62d5.js";import{U as a,a as l,b as h,F as c,c as d,d as u,e as f}from"./p-a528714c.js";import{f as m,d as p}from"./p-d9671d27.js";import{i as v,g as b}from"./p-a4670e23.js";import{c as g}from"./p-6a334573.js";import{d as R,D as j}from"./p-11a6c1b7.js";import{i as y,g as w,j as O}from"./p-1b44db34.js";import{V as E}from"./p-f69f84a7.js";import{P as V}from"./p-10ac8b57.js";import{I as F}from"./p-abd7aeaa.js";import{M as I}from"./p-78a57a17.js";import{A as C}from"./p-52b8f2d2.js";import{i as S}from"./p-d27ae9ff.js";import{S as A}from"./p-0d57293b.js";class k{constructor(t){this.rule=t}getStatus(t,e,s){return{canEvaluate:this.rule.canEvaluate(t,e,s),isAsync:v(this.rule.evaluate)}}shouldShowError(t,e){try{return this.rule.shouldShowError?this.rule.shouldShowError(t,e):this.defaultShouldShowError(t)}catch(t){return!1}}handle(t){try{return this.rule.evaluate(t)}catch(t){return{isValid:!0,message:""}}}defaultShouldShowError(t){return!t.disabled&&t.visible&&(t.touched||t.modified)}}class T{constructor(){this.handlers=[],this.processId=""}checkIncludesAsyncRuleHandler(t,e,s){return!!this.handlers.find((i=>{const r=i.getStatus(t,e,s);return r.canEvaluate&&r.isAsync}))}setHandlersByRules(t){this.handlers=t&&t.length?t.map((t=>new k(t))):[]}async process(t,e,s,i,r){const o=this.preProcess();let n;for(const i of this.handlers){if(o!==this.processId)break;const r=i.getStatus(t,e,s);if(!r.canEvaluate)continue;let a;if(r.isAsync)try{a=await i.handle(t)}catch(t){}else a=i.handle(t);if(a&&!a.isValid){const t=i.shouldShowError(e,s);n=Object.assign(Object.assign({},a),{shouldShowError:t});break}}return this.postProcess(o,i,n,r),n?{isValid:!1,message:n.message}:{isValid:!0,message:""}}preProcess(){const t=b();return this.processId=t,t}postProcess(t,e,s,i){this.processId===t&&i(e,s)}}class L{run(t){const e=t.nextElementSibling;return e&&e.querySelector(".vega-error")?e.querySelector(".vega-error"):null}}class M{run(t){let e=t.nextElementSibling;return e&&!e.classList.contains("vega-error")&&(e=document.createElement("label"),e.classList.add("vega-error"),e.setAttribute("part","field-error-message"),t.after(e)),e}}class D{run(t){let e=t.nextElementSibling;return e||(e=document.createElement("label"),e.classList.add("vega-error"),e.setAttribute("part","field-error-message"),t.after(e)),e}}class B extends t{getTranslatedMessage(t){return"string"==typeof t?E.t(t):E.t(t.key,...t.args||[])}}var H=function(t,e,s,i){var r,o=arguments.length,n=o<3?e:null===i?i=Object.getOwnPropertyDescriptor(e,s):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(t,e,s,i);else for(var a=t.length-1;a>=0;a--)(r=t[a])&&(n=(o<3?r(n):o>3?r(e,s,n):r(e,s))||n);return o>3&&n&&Object.defineProperty(e,s,n),n};class U extends t{constructor(){super(),this.formFieldMessageTranslatorSlimmer=new B,this.fieldErrorUiControllerStrategies=[new L,new M,new D],this.initTranslationObserver()}applyInputInvalidUI(t){const e=this.getInputElementContainer();if(o.notify(R.getSubject(this.host,y),{host:this.host,showError:!0}),e&&(e.classList.add("error"),t)){this.errorMessage=t;const s=this.getErrorContainer(e);s.innerHTML=this.formFieldMessageTranslatorSlimmer.getTranslatedMessage(t),s.classList.remove("vega-hidden")}}resetInputInvalidUI(){this.errorMessage="";const t=this.getInputElementContainer();t&&(this.getErrorContainer(t).classList.add("vega-hidden"),t.classList.remove("error"),o.notify(R.getSubject(this.host,y),{host:this.host,showError:!1}))}getInputElementContainer(){return this.options&&this.options.inputContainerGetter?this.options.inputContainerGetter():null}getErrorContainer(t){for(const e of this.fieldErrorUiControllerStrategies){const s=e.run(t);if(s)return s}}initTranslationObserver(){const t=new n(this.isAcceptableTranslationObserver.bind(this),(()=>{if(!this.errorMessage)return;const t=this.getInputElementContainer();if(t){const e=this.getErrorContainer(t);e&&(e.innerHTML=this.formFieldMessageTranslatorSlimmer.getTranslatedMessage(this.errorMessage))}}));o.register(a,t)}isAcceptableTranslationObserver(){return!0}}H([e()],U.prototype,"formFieldMessageTranslatorSlimmer",void 0),H([s()],U.prototype,"host",void 0),H([s()],U.prototype,"options",void 0);var x=function(t,e,s,i){var r,o=arguments.length,n=o<3?e:null===i?i=Object.getOwnPropertyDescriptor(e,s):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(t,e,s,i);else for(var a=t.length-1;a>=0;a--)(r=t[a])&&(n=(o<3?r(n):o>3?r(e,s,n):r(e,s))||n);return o>3&&n&&Object.defineProperty(e,s,n),n};class G{constructor(t,e,s,i){var r,n;this.formFieldMessageTranslatorSlimmer=new B,this.fieldErrorUIController=new U,this.resizeObserverSlimmer=g(G,V,[],[{mapFrom:"connectResizeObserver",mapTo:"connectResizeObserver"}],[{callback:t=>{const e=this.isVisible,s=t[0].contentRect.height>0;this.isVisible=s,this.isAutoValidationEnabled()&&m(this.host,"vega-form")&&e!==s&&this.valid(["visible"])},target:()=>this.host}]),this.defaultRules=[],this.additionalRules=[],this.listeners=[],this.isTouched=!1,this.isModified=!1,this.isVisible=!1,this.formFieldValidationRuleHandlerChain=new T,this.hostChildAddedBlurEventMap=new WeakMap,this.handleValidationResult=(t,e)=>{let s=!0;return e?("rule"===t?e.shouldShowError?this.fieldErrorUIController.applyInputInvalidUI(e.message):this.fieldErrorUIController.resetInputInvalidUI():t?this.fieldErrorUIController.applyInputInvalidUI(e.message):this.fieldErrorUIController.resetInputInvalidUI(),s=!1):this.fieldErrorUIController.resetInputInvalidUI(),this.invokeListeners(s),o.notify(l,{host:this.host,detail:s}),s},this.setupTouchedListener=()=>{this.getTouchableAreaElements().filter((t=>t&&!0!==this.hostChildAddedBlurEventMap.get(t))).forEach((t=>{t.addEventListener("blur",(()=>{this.updateIsTouched(!0)})),this.hostChildAddedBlurEventMap.set(t,!0)}))},this.defaultRules=t||[],this.host=e,this.defaultValue=s,this.options=i,this.initDisabledAttrObserver(),this.connectResizeObserver(),this.initFormResetObserver(),null===(n=(r=this.host).componentOnReady)||void 0===n||n.call(r).then((()=>{this.didRender()})),this.setupModifiedListener(),this.listenHostElementKeydown(),this.updateValidationHandlers()}async validate(t){return await this.valid([],t)}addListener(t){this.listeners.push(t)}getRules(){const t=[...this.additionalRules];return[...this.defaultRules.map((e=>this.overrideDefaultRuleByAdditionalRule(e,t))),...t]}setDefaultRules(t){this.defaultRules=t,this.updateValidationHandlers()}setAdditionalRules(t){this.additionalRules=t,this.updateValidationHandlers()}destroy(){o.notify(h,{host:this.host}),this.unregisterFormResetObserver(),o.unregister(c,this.hostValueChangeObserver),this.hostChildrenObserver&&this.hostChildrenObserver.disconnect()}connectResizeObserver(){}updateDisableBlurValidation(t){this.disableBlurValidation=t}updateValidationHandlers(){this.formFieldValidationRuleHandlerChain.setHandlersByRules(this.getRules())}async valid(t,e="rule"){const s=this.getStatus(),i=this.host.value;this.formFieldValidationRuleHandlerChain.checkIncludesAsyncRuleHandler(i,s,t)&&o.notify(l,{host:this.host,detail:null});const{isValid:r,message:n}=await this.formFieldValidationRuleHandlerChain.process(i,s,t,e,this.handleValidationResult);return{isValid:r,message:this.formFieldMessageTranslatorSlimmer.getTranslatedMessage(n)}}invokeListeners(t){this.listeners.forEach((e=>e.callback(t)))}getStatus(){return{touched:this.isTouched,modified:this.isModified,disabled:this.host.disabled,visible:this.isVisible}}updateIsTouched(t){const e=this.isTouched;this.isTouched=t,!this.disableBlurValidation&&this.isAutoValidationEnabled()&&this.valid(e===t?[]:["touched"])}updateIsModified(t){const e=this.isModified;this.isModified=t,this.isAutoValidationEnabled()&&this.valid(e===t?[]:["modified"])}initDisabledAttrObserver(){this.disabledAttrObserver=new MutationObserver((()=>{this.isAutoValidationEnabled()&&this.valid(["disabled"])})),this.disabledAttrObserver.observe(this.host,{attributes:!0,attributeFilter:["disabled"]})}canAcceptFormResetOperation(t){return m(this.host,"vega-form")===t.host}unregisterFormResetObserver(){o.unregister(d,this.formResetTriggeredObserver)}monitorTouchedListener(){const t=this.getInputContainerElements();t&&(this.hostChildrenObserver=new MutationObserver((()=>{this.setupTouchedListener()})),this.hostChildrenObserver.observe(t,{childList:!0,subtree:!0})),this.setupTouchedListener()}getTouchableAreaElements(){return this.options&&this.options.touchableAreaGetter?this.options.touchableAreaGetter():[]}getInputContainerElements(){return this.options&&this.options.inputContainerGetter?this.options.inputContainerGetter():null}setupModifiedListener(){this.hostValueChangeObserver=new n(this.isCurrentTarget.bind(this),(()=>this.updateIsModified(!0))),o.register(c,this.hostValueChangeObserver)}isCurrentTarget(t){return this.host===t.host}async reset(t){var e,s;if(this.shouldVisitElement(this.host,null===(e=t.option)||void 0===e?void 0:e.skipDisabled,null===(s=t.option)||void 0===s?void 0:s.skipInvisible)){const e=t.defaultValueMap,s=this.host.dataset.vegaForm,i=null==e[s]?this.getDefaultValue():e[s];"function"==typeof this.host.setValue?await this.host.setValue(i):this.host.value=i,this.isTouched=!1,this.isModified=!1,this.fieldErrorUIController.resetInputInvalidUI()}}getDefaultValue(){return this.defaultValue instanceof Function?this.defaultValue(this.host):this.defaultValue}didRender(){this.monitorTouchedListener()}initFormResetObserver(){this.formResetTriggeredObserver=new n(this.canAcceptFormResetOperation.bind(this),this.reset.bind(this)),o.register(d,this.formResetTriggeredObserver)}isAutoValidationEnabled(){return!1!==this.host.autoValidation}shouldVisitElement(t,e,s){return!(!t.dataset.vegaForm||e&&t.disabled||s&&!p(t))}listenHostElementKeydown(){this.host.addEventListener("keydown",(t=>{if(this.canSubmitFormByEvent(t)){const t=m(this.host,"vega-form",{outerMost:!0});t&&o.notify(R.getSubject(t,w),{host:this.host})}}))}canSubmitFormByEvent(t){const e="Enter"===t.key||13===t.keyCode,s=e&&t.shiftKey;switch(this.host.tagName){case"VEGA-TEXTAREA":case"VEGA-DATE-PICKER":case"VEGA-TIME-PICKER":return s&&t.preventDefault(),s;case"VEGA-RICH-TEXT-EDITOR":return!1;default:return e}}overrideDefaultRuleByAdditionalRule(t,e){if(t&&e){const s=e.findIndex((e=>e instanceof F&&e instanceof t.constructor&&e.overrideDefault));if(s>-1)return e.splice(s,1)[0]}return t}}x([e()],G.prototype,"formFieldMessageTranslatorSlimmer",void 0),x([e()],G.prototype,"fieldErrorUIController",void 0),x([e()],G.prototype,"resizeObserverSlimmer",void 0);var P=function(t,e,s,i){var r,o=arguments.length,n=o<3?e:null===i?i=Object.getOwnPropertyDescriptor(e,s):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(t,e,s,i);else for(var a=t.length-1;a>=0;a--)(r=t[a])&&(n=(o<3?r(n):o>3?r(e,s,n):r(e,s))||n);return o>3&&n&&Object.defineProperty(e,s,n),n};class W extends t{constructor(){super(...arguments),this.fieldErrorUIController=new U,this.handleFieldErrorMessageUpdate=t=>{const{message:e,isValid:s}=t;s?this.fieldErrorUIController.resetInputInvalidUI():this.fieldErrorUIController.applyInputInvalidUI(e)}}handleComponentWillLoadByFieldErrorSlimmer(){this.fieldErrorMessageChangeObserver=new n(this.canAcceptFieldErrorMessageUpdate.bind(this),this.handleFieldErrorMessageUpdate),o.register(u,this.fieldErrorMessageChangeObserver)}handleUnregisterObserver(){o.unregister(u,this.fieldErrorMessageChangeObserver)}canAcceptFieldErrorMessageUpdate(t){const{host:e}=t,s=this.host.parentElement;return s&&s===e&&"VEGA-FIELD-ERROR"===s.tagName||this.host===e}}P([s()],W.prototype,"host",void 0),P([s()],W.prototype,"options",void 0),P([e()],W.prototype,"fieldErrorUIController",void 0),P([i("setInjectFormFieldHelper")],W.prototype,"handleComponentWillLoadByFieldErrorSlimmer",null),P([i("disconnectedCallback")],W.prototype,"handleUnregisterObserver",null);var z=function(t,e,s,i){var r,o=arguments.length,n=o<3?e:null===i?i=Object.getOwnPropertyDescriptor(e,s):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(t,e,s,i);else for(var a=t.length-1;a>=0;a--)(r=t[a])&&(n=(o<3?r(n):o>3?r(e,s,n):r(e,s))||n);return o>3&&n&&Object.defineProperty(e,s,n),n};class K extends t{constructor(){super(...arguments),this.handleValidInvocation=async t=>{if(this.validator){void 0!==t.timerId&&clearTimeout(t.timerId);const e=await this.validator.validate(t.message);if(e){const{isValid:s,message:i}=e;"function"==typeof t.promiseResolve&&t.promiseResolve({isValid:s,message:i})}}}}registerValidInvocationObserver(){j.addUniqueObserverToNode(this.host,O,this.handleValidInvocation)}handleUnregisterObserver(){j.removeUniqueObserverFromNode(this.host,O)}}z([s()],K.prototype,"host",void 0),z([s()],K.prototype,"validator",void 0),z([i("setInjectFormFieldHelper")],K.prototype,"registerValidInvocationObserver",null),z([i("disconnectedCallback")],K.prototype,"handleUnregisterObserver",null);var N=function(t,e,s,i){var r,o=arguments.length,n=o<3?e:null===i?i=Object.getOwnPropertyDescriptor(e,s):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(t,e,s,i);else for(var a=t.length-1;a>=0;a--)(r=t[a])&&(n=(o<3?r(n):o>3?r(e,s,n):r(e,s))||n);return o>3&&n&&Object.defineProperty(e,s,n),n};class X extends A{constructor(){super({parent:"vega-form",subStates:[{subStateName:"disableBlurValidation",parentStateName:"disableBlurValidation",callback:t=>{var e;null===(e=this.validator)||void 0===e||e.updateDisableBlurValidation(t)}}]})}componentWillLoad(){super.componentWillLoad()}}N([s()],X.prototype,"host",void 0),N([s()],X.prototype,"validator",void 0),N([i("setInjectFormFieldHelper")],X.prototype,"componentWillLoad",null);var q=function(t,e,s,i){var r,o=arguments.length,n=o<3?e:null===i?i=Object.getOwnPropertyDescriptor(e,s):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(t,e,s,i);else for(var a=t.length-1;a>=0;a--)(r=t[a])&&(n=(o<3?r(n):o>3?r(e,s,n):r(e,s))||n);return o>3&&n&&Object.defineProperty(e,s,n),n};class J extends t{constructor(t){super(),this.fieldErrorSlimmer=new W,this.formFieldValidInvokeSlimmer=new K,this.formFormStateController=new X,this.mutationObserverCallBack=()=>{this.validator&&(this.setDefaultRules(),this.internalValidate())},this.options=t,this.setMutationObserverSlimmer()}connectedCallback(){null===this.validator&&this.setInjectFormFieldHelper()}disconnectedCallback(){this.validator&&(this.validator.destroy(),this.validator=null)}componentDidLoad(){}static isValidFormField(t){return t&&Boolean(t.getAttribute("data-vega-form"))}watchValidationRulesByFormControllerSlimmer(t,e){S(t,e,!1,((t,e)=>t===e?0:-1))||(this.setAdditionalRules(),this.internalValidate())}setInjectFormFieldHelper(){if(J.isValidFormField(this.host)){const{defaultValue:t}=this.options,e=new G(this.getPropertyRules(),this.host,t,this.options);e.addListener({callback:t=>{this.isValid!=t&&(this.isValid=t,o.notify(f,{host:this.host,detail:t}))}}),this.validator=e,this.setAdditionalRules()}}setAdditionalRules(){this.options.validationRulesName&&"validationRules"===this.options.validationRulesName&&this.validator&&this.validator.setAdditionalRules(this.validationRules||[])}setDefaultRules(){this.validator&&this.validator.setDefaultRules(this.getPropertyRules())}getPropertyRules(){const{propertyRules:t,attributeGetter:e}=this.options;return t.map((t=>{const s=t.dependence&&"string"==typeof t.dependence?[e(t.dependence)]:Array.isArray(t.dependence)?t.dependence.map((t=>e(t))):[null];return t.ruleFactory(e(t.propertyName),...s)})).filter(Boolean)}internalValidate(){!this.disabled&&this.validator&&this.validator.validate()}setMutationObserverSlimmer(){this.mutationObserverSlimmer=new I({options:{attributeFilter:this.options.propertyRules.map((t=>r(t.propertyName))),attributeOldValue:!0},mutationFilter:C(),callback:this.mutationObserverCallBack})}}q([s()],J.prototype,"host",void 0),q([s({writable:!0})],J.prototype,"validationRules",void 0),q([s()],J.prototype,"disabled",void 0),q([s()],J.prototype,"autoValidation",void 0),q([s({writable:!0})],J.prototype,"isValid",void 0),q([e()],J.prototype,"fieldErrorSlimmer",void 0),q([e()],J.prototype,"formFieldValidInvokeSlimmer",void 0),q([e()],J.prototype,"mutationObserverSlimmer",void 0),q([e()],J.prototype,"formFormStateController",void 0),q([i("connectedCallback")],J.prototype,"connectedCallback",null),q([i("disconnectedCallback")],J.prototype,"disconnectedCallback",null),q([i("componentDidLoad")],J.prototype,"componentDidLoad",null),q([i("watchValidationRules")],J.prototype,"watchValidationRulesByFormControllerSlimmer",null),q([i("componentWillLoad")],J.prototype,"setInjectFormFieldHelper",null);export{J as F}
1
+ import{V as t,I as e,c as s,M as i}from"./p-6e1ab235.js";import{c as r}from"./p-02841589.js";import{C as o}from"./p-2d0d575f.js";import{O as n}from"./p-331a62d5.js";import{U as a,a as l,b as h,F as c,c as d,d as u,e as f}from"./p-a528714c.js";import{f as m,d as p}from"./p-d9671d27.js";import{i as v,g as b}from"./p-a4670e23.js";import{c as g}from"./p-6a334573.js";import{d as R,D as j}from"./p-8d0ca805.js";import{f as y,d as w,g as O}from"./p-5b71c85e.js";import{V as E}from"./p-f69f84a7.js";import{P as V}from"./p-10ac8b57.js";import{I as F}from"./p-abd7aeaa.js";import{M as I}from"./p-78a57a17.js";import{A as C}from"./p-52b8f2d2.js";import{i as S}from"./p-d27ae9ff.js";import{S as A}from"./p-3bf66be2.js";class k{constructor(t){this.rule=t}getStatus(t,e,s){return{canEvaluate:this.rule.canEvaluate(t,e,s),isAsync:v(this.rule.evaluate)}}shouldShowError(t,e){try{return this.rule.shouldShowError?this.rule.shouldShowError(t,e):this.defaultShouldShowError(t)}catch(t){return!1}}handle(t){try{return this.rule.evaluate(t)}catch(t){return{isValid:!0,message:""}}}defaultShouldShowError(t){return!t.disabled&&t.visible&&(t.touched||t.modified)}}class T{constructor(){this.handlers=[],this.processId=""}checkIncludesAsyncRuleHandler(t,e,s){return!!this.handlers.find((i=>{const r=i.getStatus(t,e,s);return r.canEvaluate&&r.isAsync}))}setHandlersByRules(t){this.handlers=t&&t.length?t.map((t=>new k(t))):[]}async process(t,e,s,i,r){const o=this.preProcess();let n;for(const i of this.handlers){if(o!==this.processId)break;const r=i.getStatus(t,e,s);if(!r.canEvaluate)continue;let a;if(r.isAsync)try{a=await i.handle(t)}catch(t){}else a=i.handle(t);if(a&&!a.isValid){const t=i.shouldShowError(e,s);n=Object.assign(Object.assign({},a),{shouldShowError:t});break}}return this.postProcess(o,i,n,r),n?{isValid:!1,message:n.message}:{isValid:!0,message:""}}preProcess(){const t=b();return this.processId=t,t}postProcess(t,e,s,i){this.processId===t&&i(e,s)}}class L{run(t){const e=t.nextElementSibling;return e&&e.querySelector(".vega-error")?e.querySelector(".vega-error"):null}}class M{run(t){let e=t.nextElementSibling;return e&&!e.classList.contains("vega-error")&&(e=document.createElement("label"),e.classList.add("vega-error"),e.setAttribute("part","field-error-message"),t.after(e)),e}}class D{run(t){let e=t.nextElementSibling;return e||(e=document.createElement("label"),e.classList.add("vega-error"),e.setAttribute("part","field-error-message"),t.after(e)),e}}class B extends t{getTranslatedMessage(t){return"string"==typeof t?E.t(t):E.t(t.key,...t.args||[])}}var H=function(t,e,s,i){var r,o=arguments.length,n=o<3?e:null===i?i=Object.getOwnPropertyDescriptor(e,s):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(t,e,s,i);else for(var a=t.length-1;a>=0;a--)(r=t[a])&&(n=(o<3?r(n):o>3?r(e,s,n):r(e,s))||n);return o>3&&n&&Object.defineProperty(e,s,n),n};class U extends t{constructor(){super(),this.formFieldMessageTranslatorSlimmer=new B,this.fieldErrorUiControllerStrategies=[new L,new M,new D],this.initTranslationObserver()}applyInputInvalidUI(t){const e=this.getInputElementContainer();if(o.notify(R.getSubject(this.host,y),{host:this.host,showError:!0}),e&&(e.classList.add("error"),t)){this.errorMessage=t;const s=this.getErrorContainer(e);s.innerHTML=this.formFieldMessageTranslatorSlimmer.getTranslatedMessage(t),s.classList.remove("vega-hidden")}}resetInputInvalidUI(){this.errorMessage="";const t=this.getInputElementContainer();t&&(this.getErrorContainer(t).classList.add("vega-hidden"),t.classList.remove("error"),o.notify(R.getSubject(this.host,y),{host:this.host,showError:!1}))}getInputElementContainer(){return this.options&&this.options.inputContainerGetter?this.options.inputContainerGetter():null}getErrorContainer(t){for(const e of this.fieldErrorUiControllerStrategies){const s=e.run(t);if(s)return s}}initTranslationObserver(){const t=new n(this.isAcceptableTranslationObserver.bind(this),(()=>{if(!this.errorMessage)return;const t=this.getInputElementContainer();if(t){const e=this.getErrorContainer(t);e&&(e.innerHTML=this.formFieldMessageTranslatorSlimmer.getTranslatedMessage(this.errorMessage))}}));o.register(a,t)}isAcceptableTranslationObserver(){return!0}}H([e()],U.prototype,"formFieldMessageTranslatorSlimmer",void 0),H([s()],U.prototype,"host",void 0),H([s()],U.prototype,"options",void 0);var x=function(t,e,s,i){var r,o=arguments.length,n=o<3?e:null===i?i=Object.getOwnPropertyDescriptor(e,s):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(t,e,s,i);else for(var a=t.length-1;a>=0;a--)(r=t[a])&&(n=(o<3?r(n):o>3?r(e,s,n):r(e,s))||n);return o>3&&n&&Object.defineProperty(e,s,n),n};class G{constructor(t,e,s,i){var r,n;this.formFieldMessageTranslatorSlimmer=new B,this.fieldErrorUIController=new U,this.resizeObserverSlimmer=g(G,V,[],[{mapFrom:"connectResizeObserver",mapTo:"connectResizeObserver"}],[{callback:t=>{const e=this.isVisible,s=t[0].contentRect.height>0;this.isVisible=s,this.isAutoValidationEnabled()&&m(this.host,"vega-form")&&e!==s&&this.valid(["visible"])},target:()=>this.host}]),this.defaultRules=[],this.additionalRules=[],this.listeners=[],this.isTouched=!1,this.isModified=!1,this.isVisible=!1,this.formFieldValidationRuleHandlerChain=new T,this.hostChildAddedBlurEventMap=new WeakMap,this.handleValidationResult=(t,e)=>{let s=!0;return e?("rule"===t?e.shouldShowError?this.fieldErrorUIController.applyInputInvalidUI(e.message):this.fieldErrorUIController.resetInputInvalidUI():t?this.fieldErrorUIController.applyInputInvalidUI(e.message):this.fieldErrorUIController.resetInputInvalidUI(),s=!1):this.fieldErrorUIController.resetInputInvalidUI(),this.invokeListeners(s),o.notify(l,{host:this.host,detail:s}),s},this.setupTouchedListener=()=>{this.getTouchableAreaElements().filter((t=>t&&!0!==this.hostChildAddedBlurEventMap.get(t))).forEach((t=>{t.addEventListener("blur",(()=>{this.updateIsTouched(!0)})),this.hostChildAddedBlurEventMap.set(t,!0)}))},this.defaultRules=t||[],this.host=e,this.defaultValue=s,this.options=i,this.initDisabledAttrObserver(),this.connectResizeObserver(),this.initFormResetObserver(),null===(n=(r=this.host).componentOnReady)||void 0===n||n.call(r).then((()=>{this.didRender()})),this.setupModifiedListener(),this.listenHostElementKeydown(),this.updateValidationHandlers()}async validate(t){return await this.valid([],t)}addListener(t){this.listeners.push(t)}getRules(){const t=[...this.additionalRules];return[...this.defaultRules.map((e=>this.overrideDefaultRuleByAdditionalRule(e,t))),...t]}setDefaultRules(t){this.defaultRules=t,this.updateValidationHandlers()}setAdditionalRules(t){this.additionalRules=t,this.updateValidationHandlers()}destroy(){o.notify(h,{host:this.host}),this.unregisterFormResetObserver(),o.unregister(c,this.hostValueChangeObserver),this.hostChildrenObserver&&this.hostChildrenObserver.disconnect()}connectResizeObserver(){}updateDisableBlurValidation(t){this.disableBlurValidation=t}updateValidationHandlers(){this.formFieldValidationRuleHandlerChain.setHandlersByRules(this.getRules())}async valid(t,e="rule"){const s=this.getStatus(),i=this.host.value;this.formFieldValidationRuleHandlerChain.checkIncludesAsyncRuleHandler(i,s,t)&&o.notify(l,{host:this.host,detail:null});const{isValid:r,message:n}=await this.formFieldValidationRuleHandlerChain.process(i,s,t,e,this.handleValidationResult);return{isValid:r,message:this.formFieldMessageTranslatorSlimmer.getTranslatedMessage(n)}}invokeListeners(t){this.listeners.forEach((e=>e.callback(t)))}getStatus(){return{touched:this.isTouched,modified:this.isModified,disabled:this.host.disabled,visible:this.isVisible}}updateIsTouched(t){const e=this.isTouched;this.isTouched=t,!this.disableBlurValidation&&this.isAutoValidationEnabled()&&this.valid(e===t?[]:["touched"])}updateIsModified(t){const e=this.isModified;this.isModified=t,this.isAutoValidationEnabled()&&this.valid(e===t?[]:["modified"])}initDisabledAttrObserver(){this.disabledAttrObserver=new MutationObserver((()=>{this.isAutoValidationEnabled()&&this.valid(["disabled"])})),this.disabledAttrObserver.observe(this.host,{attributes:!0,attributeFilter:["disabled"]})}canAcceptFormResetOperation(t){return m(this.host,"vega-form")===t.host}unregisterFormResetObserver(){o.unregister(d,this.formResetTriggeredObserver)}monitorTouchedListener(){const t=this.getInputContainerElements();t&&(this.hostChildrenObserver=new MutationObserver((()=>{this.setupTouchedListener()})),this.hostChildrenObserver.observe(t,{childList:!0,subtree:!0})),this.setupTouchedListener()}getTouchableAreaElements(){return this.options&&this.options.touchableAreaGetter?this.options.touchableAreaGetter():[]}getInputContainerElements(){return this.options&&this.options.inputContainerGetter?this.options.inputContainerGetter():null}setupModifiedListener(){this.hostValueChangeObserver=new n(this.isCurrentTarget.bind(this),(()=>this.updateIsModified(!0))),o.register(c,this.hostValueChangeObserver)}isCurrentTarget(t){return this.host===t.host}async reset(t){var e,s;if(this.shouldVisitElement(this.host,null===(e=t.option)||void 0===e?void 0:e.skipDisabled,null===(s=t.option)||void 0===s?void 0:s.skipInvisible)){const e=t.defaultValueMap,s=this.host.dataset.vegaForm,i=null==e[s]?this.getDefaultValue():e[s];"function"==typeof this.host.setValue?await this.host.setValue(i):this.host.value=i,this.isTouched=!1,this.isModified=!1,this.fieldErrorUIController.resetInputInvalidUI()}}getDefaultValue(){return this.defaultValue instanceof Function?this.defaultValue(this.host):this.defaultValue}didRender(){this.monitorTouchedListener()}initFormResetObserver(){this.formResetTriggeredObserver=new n(this.canAcceptFormResetOperation.bind(this),this.reset.bind(this)),o.register(d,this.formResetTriggeredObserver)}isAutoValidationEnabled(){return!1!==this.host.autoValidation}shouldVisitElement(t,e,s){return!(!t.dataset.vegaForm||e&&t.disabled||s&&!p(t))}listenHostElementKeydown(){this.host.addEventListener("keydown",(t=>{if(this.canSubmitFormByEvent(t)){const t=m(this.host,"vega-form",{outerMost:!0});t&&o.notify(R.getSubject(t,w),{host:this.host})}}))}canSubmitFormByEvent(t){const e="Enter"===t.key||13===t.keyCode,s=e&&t.shiftKey;switch(this.host.tagName){case"VEGA-TEXTAREA":case"VEGA-DATE-PICKER":case"VEGA-TIME-PICKER":return s&&t.preventDefault(),s;case"VEGA-RICH-TEXT-EDITOR":return!1;default:return e}}overrideDefaultRuleByAdditionalRule(t,e){if(t&&e){const s=e.findIndex((e=>e instanceof F&&e instanceof t.constructor&&e.overrideDefault));if(s>-1)return e.splice(s,1)[0]}return t}}x([e()],G.prototype,"formFieldMessageTranslatorSlimmer",void 0),x([e()],G.prototype,"fieldErrorUIController",void 0),x([e()],G.prototype,"resizeObserverSlimmer",void 0);var P=function(t,e,s,i){var r,o=arguments.length,n=o<3?e:null===i?i=Object.getOwnPropertyDescriptor(e,s):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(t,e,s,i);else for(var a=t.length-1;a>=0;a--)(r=t[a])&&(n=(o<3?r(n):o>3?r(e,s,n):r(e,s))||n);return o>3&&n&&Object.defineProperty(e,s,n),n};class W extends t{constructor(){super(...arguments),this.fieldErrorUIController=new U,this.handleFieldErrorMessageUpdate=t=>{const{message:e,isValid:s}=t;s?this.fieldErrorUIController.resetInputInvalidUI():this.fieldErrorUIController.applyInputInvalidUI(e)}}handleComponentWillLoadByFieldErrorSlimmer(){this.fieldErrorMessageChangeObserver=new n(this.canAcceptFieldErrorMessageUpdate.bind(this),this.handleFieldErrorMessageUpdate),o.register(u,this.fieldErrorMessageChangeObserver)}handleUnregisterObserver(){o.unregister(u,this.fieldErrorMessageChangeObserver)}canAcceptFieldErrorMessageUpdate(t){const{host:e}=t,s=this.host.parentElement;return s&&s===e&&"VEGA-FIELD-ERROR"===s.tagName||this.host===e}}P([s()],W.prototype,"host",void 0),P([s()],W.prototype,"options",void 0),P([e()],W.prototype,"fieldErrorUIController",void 0),P([i("setInjectFormFieldHelper")],W.prototype,"handleComponentWillLoadByFieldErrorSlimmer",null),P([i("disconnectedCallback")],W.prototype,"handleUnregisterObserver",null);var z=function(t,e,s,i){var r,o=arguments.length,n=o<3?e:null===i?i=Object.getOwnPropertyDescriptor(e,s):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(t,e,s,i);else for(var a=t.length-1;a>=0;a--)(r=t[a])&&(n=(o<3?r(n):o>3?r(e,s,n):r(e,s))||n);return o>3&&n&&Object.defineProperty(e,s,n),n};class K extends t{constructor(){super(...arguments),this.handleValidInvocation=async t=>{if(this.validator){void 0!==t.timerId&&clearTimeout(t.timerId);const e=await this.validator.validate(t.message);if(e){const{isValid:s,message:i}=e;"function"==typeof t.promiseResolve&&t.promiseResolve({isValid:s,message:i})}}}}registerValidInvocationObserver(){j.addUniqueObserverToNode(this.host,O,this.handleValidInvocation)}handleUnregisterObserver(){j.removeUniqueObserverFromNode(this.host,O)}}z([s()],K.prototype,"host",void 0),z([s()],K.prototype,"validator",void 0),z([i("setInjectFormFieldHelper")],K.prototype,"registerValidInvocationObserver",null),z([i("disconnectedCallback")],K.prototype,"handleUnregisterObserver",null);var N=function(t,e,s,i){var r,o=arguments.length,n=o<3?e:null===i?i=Object.getOwnPropertyDescriptor(e,s):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(t,e,s,i);else for(var a=t.length-1;a>=0;a--)(r=t[a])&&(n=(o<3?r(n):o>3?r(e,s,n):r(e,s))||n);return o>3&&n&&Object.defineProperty(e,s,n),n};class X extends A{constructor(){super({parent:"vega-form",subStates:[{subStateName:"disableBlurValidation",parentStateName:"disableBlurValidation",callback:t=>{var e;null===(e=this.validator)||void 0===e||e.updateDisableBlurValidation(t)}}]})}componentWillLoad(){super.componentWillLoad()}}N([s()],X.prototype,"host",void 0),N([s()],X.prototype,"validator",void 0),N([i("setInjectFormFieldHelper")],X.prototype,"componentWillLoad",null);var q=function(t,e,s,i){var r,o=arguments.length,n=o<3?e:null===i?i=Object.getOwnPropertyDescriptor(e,s):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(t,e,s,i);else for(var a=t.length-1;a>=0;a--)(r=t[a])&&(n=(o<3?r(n):o>3?r(e,s,n):r(e,s))||n);return o>3&&n&&Object.defineProperty(e,s,n),n};class J extends t{constructor(t){super(),this.fieldErrorSlimmer=new W,this.formFieldValidInvokeSlimmer=new K,this.formFormStateController=new X,this.mutationObserverCallBack=()=>{this.validator&&(this.setDefaultRules(),this.internalValidate())},this.options=t,this.setMutationObserverSlimmer()}connectedCallback(){null===this.validator&&this.setInjectFormFieldHelper()}disconnectedCallback(){this.validator&&(this.validator.destroy(),this.validator=null)}componentDidLoad(){}static isValidFormField(t){return t&&Boolean(t.getAttribute("data-vega-form"))}watchValidationRulesByFormControllerSlimmer(t,e){S(t,e,!1,((t,e)=>t===e?0:-1))||(this.setAdditionalRules(),this.internalValidate())}setInjectFormFieldHelper(){if(J.isValidFormField(this.host)){const{defaultValue:t}=this.options,e=new G(this.getPropertyRules(),this.host,t,this.options);e.addListener({callback:t=>{this.isValid!=t&&(this.isValid=t,o.notify(f,{host:this.host,detail:t}))}}),this.validator=e,this.setAdditionalRules()}}setAdditionalRules(){this.options.validationRulesName&&"validationRules"===this.options.validationRulesName&&this.validator&&this.validator.setAdditionalRules(this.validationRules||[])}setDefaultRules(){this.validator&&this.validator.setDefaultRules(this.getPropertyRules())}getPropertyRules(){const{propertyRules:t,attributeGetter:e}=this.options;return t.map((t=>{const s=t.dependence&&"string"==typeof t.dependence?[e(t.dependence)]:Array.isArray(t.dependence)?t.dependence.map((t=>e(t))):[null];return t.ruleFactory(e(t.propertyName),...s)})).filter(Boolean)}internalValidate(){!this.disabled&&this.validator&&this.validator.validate()}setMutationObserverSlimmer(){this.mutationObserverSlimmer=new I({options:{attributeFilter:this.options.propertyRules.map((t=>r(t.propertyName))),attributeOldValue:!0},mutationFilter:C(),callback:this.mutationObserverCallBack})}}q([s()],J.prototype,"host",void 0),q([s({writable:!0})],J.prototype,"validationRules",void 0),q([s()],J.prototype,"disabled",void 0),q([s()],J.prototype,"autoValidation",void 0),q([s({writable:!0})],J.prototype,"isValid",void 0),q([e()],J.prototype,"fieldErrorSlimmer",void 0),q([e()],J.prototype,"formFieldValidInvokeSlimmer",void 0),q([e()],J.prototype,"mutationObserverSlimmer",void 0),q([e()],J.prototype,"formFormStateController",void 0),q([i("connectedCallback")],J.prototype,"connectedCallback",null),q([i("disconnectedCallback")],J.prototype,"disconnectedCallback",null),q([i("componentDidLoad")],J.prototype,"componentDidLoad",null),q([i("watchValidationRules")],J.prototype,"watchValidationRulesByFormControllerSlimmer",null),q([i("componentWillLoad")],J.prototype,"setInjectFormFieldHelper",null);export{J as F}
@@ -0,0 +1 @@
1
+ import{C as t}from"./p-2d0d575f.js";import{d as e}from"./p-8d0ca805.js";import{b as s,c as n}from"./p-5b71c85e.js";import{c as r}from"./p-02841589.js";import{L as i}from"./p-6e1ab235.js";import{i as o}from"./p-1f83cebf.js";import{g as c}from"./p-a4670e23.js";import{V as a}from"./p-ef9cbad1.js";import{c as l}from"./p-bf19682d.js";import{f as h}from"./p-d9671d27.js";var u,d;!function(t){t.SELECTION_RANGE="SELECTION_RANGE",t.CLEAR_FORMATTING="CLEAR_FORMATTING",t.LINK_GROUP="LINK_GROUP"}(u||(u={}));class p{}!function(t){t.ALIGNMENT="ALIGNMENT",t.TEXT_STYLE="TEXT_STYLE",t.INDENT="INDENT",t.LIST="LIST",t.INTERNAL_WRAPPER="INTERNAL_WRAPPER"}(d||(d={}));class f extends p{}const T=new class{constructor(){this.domToEntity=new WeakMap,this.entityToDOM=new WeakMap,this.contentEntityToRootDom=new Map,this.rootDomToContentEntity=new WeakMap}register(t,e){this.isVegaRTEContent(e)?this.registerRootDomAndContentEntity(t,e):(this.domToEntity.set(t,e),this.entityToDOM.set(e,t))}getEntityByDOM(t){return this.domToEntity.get(t)}getDOMByEntity(t){return this.isVegaRTEContent(t)?this.contentEntityToRootDom.get(t):this.entityToDOM.get(t)}removeDirtyDomRef(t){this.domToEntity.delete(t)}registerRootDomAndContentEntity(t,e){const s=this.rootDomToContentEntity.get(t);s&&s!==e&&this.contentEntityToRootDom.delete(s),this.rootDomToContentEntity.set(t,e),this.contentEntityToRootDom.set(e,t)}isVegaRTEContent(t){return t&&"VegaRTEContent"===t.constructor.name}};var x,E,g,w;!function(t){t.DELETE_CHILDREN="DELETE_CHILDREN",t.DELETE_NEST_LIST="DELETE_NEST_LIST",t.UPDATE_TEXT="UPDATE_TEXT",t.REPLACE_SELECTED_TEXT="REPLACE_SELECTED_TEXT",t.APPEND_CHILDREN="APPEND_CHILDREN",t.INSERT_CHILDREN_AFTER="INSERT_CHILDREN_AFTER",t.INSERT_CHILDREN_BEFORE="INSERT_CHILDREN_BEFORE",t.SPLIT_BLOCK_WITH_NODE="SPLIT_BLOCK_WITH_NODE",t.REPLACE_CHILD_NODES="REPLACE_CHILD_NODES",t.REPLACE_NEST_LIST="REPLACE_NEST_LIST",t.MERGE_TWO_BLOCKS_NODES="MERGE_TWO_BLOCKS_NODES",t.INSERT_NEW_PARAGRAPH="INSERT_NEW_PARAGRAPH",t.LINE_BREAK_SINGLE_BLOCK="LINE_BREAK_SINGLE_BLOCK",t.LINE_BREAK_MULTIPLE_BLOCKS="LINE_BREAK_MULTIPLE_BLOCKS",t.TRANSFORM_LIST_BLOCK="TRANSFORM_LIST_BLOCK",t.TRANSFORM_PARAGRAPH_BLOCK="TRANSFORM_PARAGRAPH_BLOCK",t.DELETE_BLOCK_CONTENT="DELETE_BLOCK_CONTENT",t.INSERT_IMAGE_TO_BLOCK="INSERT_IMAGE_TO_BLOCK",t.UPDATE_IMAGE_NODE_URL="UPDATE_IMAGE_NODE_URL",t.TRANSFORM_TO_CODE_BLOCK="TRANSFORM_TO_CODE_BLOCK",t.UPDATE_CODE_BLOCK="UPDATE_CODE_BLOCK",t.SWITCH_OUT_FROM_CODE_BLOCK="SWITCH_OUT_FROM_CODE_BLOCK",t.DELETE_CODE_BLOCK="DELETE_CODE_BLOCK",t.UNLINK_LINK_GROUP="UNLINK_LINK_GROUP",t.LINK_GROUP_NODE_SPLIT="LINK_GROUP_NODE_SPLIT",t.DELETE_LINK_GROUP="DELETE_LINK_GROUP",t.UPDATE_CURSOR_POSITION="UPDATE_CURSOR_POSITION",t.INSERT_TEXT_TO_DECORATOR_NODE="INSERT_TEXT_TO_DECORATOR_NODE",t.INSERT_NODE_TO_NEAREST_ROOT="INSERT_NODE_TO_NEAREST_ROOT",t.PASTE_CONTENT="PASTE_CONTENT"}(x||(x={}));class m{constructor(){this.isFlushable=!1}}class A extends p{constructor(t){super(),this.type=u.LINK_GROUP,this.linkGroups=new Map,this.linkGroups=new Map([[t,[]]])}clone(){const t=new A("");return this.linkGroups.forEach(((e,s)=>{t.linkGroups.set(s,e.map((t=>t.clone(t.parent))))})),t}toString(t,e){const s=this.toJsx(t,e);return Object.entries(s).map((([t,e])=>{const s="string"==typeof e?e:this.formatStyleToString(e);return`${r(t)}="${s}"`})).join(" ")}toJsx(t,e){const s=this.getStyle(t,e),n=this.getClass(t,e),r=this.getAttribute(t);return n.length>0&&(r.class=n.join(" ")),s&&Object.keys(s).length>0&&(r.style=s),r}getClass(t,e){const s=[];return t.link.customClass&&s.push(...t.link.customClass),!(null==e?void 0:e.standalone)&&t.useInternalStyle&&s.push("v-rte--link"),s}getStyle(t,e){const s={};return t.link.customStyle&&Object.assign(s,t.link.customStyle),(null==e?void 0:e.standalone)&&t.useInternalStyle&&(s.color="rgba(var(--v-text-link, 19, 98, 226, 1))"),s}getAttribute(t){const{href:e,customAttribute:s={}}=t.link,n=t.useInternalStyle,r=s.target||(n?"_blank":"");return Object.assign(Object.assign(Object.assign({},s),e||n?{href:e}:{}),r?{target:r}:{})}formatStyleToString(t){return Object.entries(t).map((([t,e])=>`${r(t)}: ${e};`)).join(" ")}}class O extends f{constructor(t){super(),this.type=d.ALIGNMENT,this.textAlign=t}static from(t){return[d.ALIGNMENT,new O(t)]}toJSON(){return{textAlign:this.textAlign}}renderClass(t){if(null==t?void 0:t.standalone)return null;switch(this.textAlign){case"right":case"center":case"justify":return`v-rte--horizontal-alignment-${this.textAlign}`;case"left":default:return"v-rte--horizontal-alignment-left"}}clone(){return new O(this.textAlign)}renderStyle(t){if(!(null==t?void 0:t.standalone))return null;switch(this.textAlign){case"right":case"center":case"justify":return{textAlign:this.textAlign};case"left":default:return{textAlign:"left"}}}}class N extends f{constructor(t){super(),this.type=d.INDENT,this.indent=Math.max(0,t)}static from(t){return[d.INDENT,new N(t)]}toJSON(){return this.indent>0?{indent:this.indent}:null}clone(){return new N(this.indent)}renderClass(){return null}renderStyle(){return this.indent>0?{marginLeft:16*this.indent+"px"}:null}}class R{static register(t,e,s){this.registry.has(e)||this.registry.set(e,new Map),this.registry.get(e).has(t)||this.registry.get(e).set(t,new Set),this.registry.get(e).get(t).add(s)}static unregister(t,e,s){const n=this.registry.get(e);if(n){const e=n.get(t);e&&e.delete(s)}}static get(t,e){const s=t instanceof m?t.type:t.constructor.name,n=this.registry.get(e.constructor.name);if(n){const r=n.get(s);if(r&&r.size>0)return Array.from(r).find((s=>s.canIntercept(t,e)))}}}R.registry=new Map;class y{static register(t,e,s){this.registry.has(e)||this.registry.set(e,new Map),this.registry.get(e).set(t,s)}static unregister(t,e){const s=this.registry.get(e);s&&s.delete(t)}static get(t,e){const s=this.registry.get(e);if(s)return s.get(t)}static executeTheStrategy(t,e){const s=R.get(t,e),n=()=>{const s=t instanceof m?t.type:t.constructor.name,n=y.get(s,e.constructor.name);if(n)return t.executedFlag=!0,n.execute(t,e);i.warn(`Type ${s} action handle strategy is not registered in class ${e.constructor.name}`)};return s?s.intercept(n,t,e):n()}static canHandle(t,e){return!!y.get(t,e.constructor.name)}}y.registry=new Map,function(t){t.CUSTOM_ATTRIBUTE="CUSTOM_ATTRIBUTE",t.CUSTOM_CLASS="CUSTOM_CLASS",t.CUSTOM_STYLE="CUSTOM_STYLE"}(E||(E={}));class S extends p{}class C extends S{constructor(t){super(),this.type=E.CUSTOM_ATTRIBUTE,this.BOOLEAN_ATTRS=new Set(["controls","disabled","checked","readonly","multiple","required","autoplay","muted"]),this.customAttribute=t}static from(t){return[E.CUSTOM_ATTRIBUTE,new C(t)]}toJSON(){return{customAttribute:this.customAttribute}}clone(){return new C(this.customAttribute)}toString(t=[]){const e=t.map((t=>t.split("=")[0]));return Object.keys(this.customAttribute).map((t=>e.includes(t)?null:`${t}="${this.customAttribute[t]}"`)).filter(o)}render(t={}){var e;const s=Object.assign({},this.customAttribute);return null===(e=t.filterAttributes)||void 0===e||e.forEach((t=>delete s[t])),Object.keys(s).forEach((t=>{this.BOOLEAN_ATTRS.has(t)&&""===s[t]&&(s[t]="true")})),s}}class b extends S{constructor(t){super(),this.type=E.CUSTOM_CLASS,this.customClass=t}static from(t){return[E.CUSTOM_CLASS,new b(t)]}toJSON(){return{customClass:this.customClass}}clone(){return new b(this.customClass)}toString(){return`class="${this.customClass.join(" ")}"`}renderClass(){return this.customClass}}class k extends S{constructor(t){super(),this.type=E.CUSTOM_STYLE,this.customStyle=t}static from(t){return[E.CUSTOM_STYLE,new k(t)]}toJSON(){return{customStyle:this.customStyle}}clone(){return new k(this.customStyle)}renderStyle(){return this.customStyle}removeStyles(t){const e=Object.assign({},this.customStyle);return t.forEach((t=>delete e[t])),e}toString(){return`style="${Object.entries(this.customStyle).map((([t,e])=>`${t}: ${e};`)).join(" ")}"`}}class B extends f{constructor(t){super(),this.type=d.INTERNAL_WRAPPER,this.internalWrapper=t}static from(t){return[d.INTERNAL_WRAPPER,new B(t)]}clone(){return new B(this.internalWrapper)}renderClass(){}renderStyle(){}toJSON(){return this.internalWrapper?{internalWrapper:this.internalWrapper}:void 0}}!function(t){t.BOLD="BOLD",t.ITALIC="ITALIC",t.UNDERLINE="UNDERLINE",t.STRIKETHROUGH="STRIKETHROUGH",t.SELECTION_RANGE="SELECTION_RANGE",t.IMAGE="IMAGE",t.CODE="CODE",t.TEXT_COLOR="TEXT_COLOR",t.LINK="LINK",t.INLINE_HTML="INLINE_HTML",t.PLAIN_TEXT="PLAIN_TEXT"}(g||(g={}));class v extends p{}class _{constructor(t){this.dtoType=t instanceof RTEBlock?"block":"node",this.annotationMap=t.annotationMap}toCssText(t={standalone:!1},e,s){return s=s||this.toJSON(t,e),Object.entries(Object.assign({},s)).map((([t,e])=>`${r(t)}: ${e};`)).join("")}toJSON(t={standalone:!1},e){const s=Array.from(this.annotationMap.values()).filter((t=>this.filterAnnotation(t)||t instanceof k)).map((e=>e.renderStyle(t))).filter(o);return e&&e.length>0?this.mergeAnnotationStyles(s,e):s.reduce(((t,e)=>Object.assign(Object.assign({},t),e)),{})}filterAnnotation(t){return"block"===this.dtoType?t instanceof f:t instanceof v}mergeAnnotationStyles(t,e){const s={};for(const n of t)for(const t in n){const r=n[t],i=s[t];s[t]="string"==typeof i&&"string"==typeof r&&e.includes(t)?Array.from(new Set(`${i} ${r}`.split(/\s+/).filter(Boolean))).join(" "):r}return s}}!function(t){t.TEXT="TEXT",t.IMAGE="IMAGE",t.CODE_BLOCK_NODE="CODE_BLOCK_NODE"}(w||(w={}));class RTENode{constructor(t,e){this.annotationMap=new Map,this.id=t,e&&(this.annotationMap=e)}static from(t,e,s){throw new Error(`[Vega] ${this.constructor.name}.from(${JSON.stringify(t)}, ${e}, ${s}) is not implemented. Please implement this method in the subclass.`)}static createAnnotationEntity(t,e){switch(t){case"customAttribute":return C.from(e);case"customClass":return b.from(e);case"customStyle":return k.from(e)}}getAnnotationByType(t){return this.annotationMap.get(t)}deleteAnnotationByType(t){this.annotationMap.delete(t),this.flushChange()}apply(t){return this.doApply(t),t.isFlushable&&this.flushChange(),this}getStyles(t={standalone:!1}){return new _(this).toJSON(t,["textDecoration"])}getClasses(t={standalone:!1}){return Array.from(this.annotationMap.values()).filter((t=>t instanceof v||t instanceof b)).map((e=>e.renderClass(t))).filter(o).reduce(((t,e)=>[t,e].join(" ").trim()),"")}getCustomAttributesAnnotation(){return this.annotationMap.get(E.CUSTOM_ATTRIBUTE)}isTextNode(){return!1}getElementRef(){return T.getDOMByEntity(this)}generateAttributeString(...t){var e;const s=new _(this).toCssText({standalone:!0},["textDecoration"]),n=this.annotationMap.get(E.CUSTOM_CLASS),r=[...(null===(e=this.getCustomAttributesAnnotation())||void 0===e?void 0:e.toString(t))||[],null==n?void 0:n.toString(),s?`style="${s}"`:null,...t].filter(o);return r.length?` ${r.join(" ")}`:""}doApply(t){t instanceof m?this.doModifyActionApply(t):this.doAnnotationActionApply(t)}flushChange(){const n=T.getDOMByEntity(this);if(n){const r=e.getSubjectFromParentNodeByEventId(n,s);r&&t.notify(r,{})}}cloneAnnotations(){return new Map(Array.from(this.annotationMap.entries()).map((([t,e])=>[t,e.clone()])))}doAnnotationActionApply(t){}doModifyActionApply(t){}}const L=new class{constructor(){this.RTE_BLOCK_DTO_CLASS_MAP=new Map,this.RTE_NODE_DTO_CLASS_MAP=new Map}registerRTEDTOClass(t,e){if(e.prototype instanceof RTEBlock)this.RTE_BLOCK_DTO_CLASS_MAP.set(t,e);else{if(!(e.prototype instanceof RTENode))throw new Error(`Invalid RTE DTO class type: ${t}`);this.RTE_NODE_DTO_CLASS_MAP.set(t,e)}}getRTEBlockClass(t){return this.RTE_BLOCK_DTO_CLASS_MAP.get(t)}getRTENodeClass(t){return this.RTE_NODE_DTO_CLASS_MAP.get(t)}};class RTEBlock{constructor(t){this.annotationMap=new Map,this.id=t}static from(t,e){throw new Error(`[Vega] ${this.constructor.name}.from(${JSON.stringify(t)}, ${e}) is not implemented. Please implement this method in the subclass.`)}static generateBlockChildren(t,e,s){return t.map((t=>{const n=L.getRTEBlockClass(t.type);if(n){const r=n.from(t,e);return r.parent=s,r}})).filter(o)}static createAnnotationEntity(t,e){switch(t){case"textAlign":return O.from(e);case"indent":return N.from(e);case"customAttribute":return C.from(e);case"customClass":return b.from(e);case"customStyle":return k.from(e);case"internalWrapper":return B.from(e)}}static convertAnnotationsToMap(t,e){Object.entries(e).forEach((([e,s])=>{const n=this.createAnnotationEntity(e,s);o(n)&&t.set(...n)}))}shouldRenderAsInternalWrapper(){const t=this.getAnnotationByType(d.INTERNAL_WRAPPER);return!!t&&t.internalWrapper&&0===Array.from(this.annotationMap.values()).filter((t=>!(t instanceof A||t instanceof B))).length}toJSON(){const t=Array.from(this.annotationMap.values()).filter((t=>t instanceof f||t instanceof S)).reduce(((t,e)=>Object.assign(Object.assign({},t),e.toJSON())),{});return Object.assign({id:this.id},Object.keys(t).length>0?{annotations:t}:{})}getAnnotationByType(t){return this.annotationMap.get(t)}apply(n){if(this.doApply(n),n.isFlushable){const n=T.getDOMByEntity(this);if(n){const r=e.getSubjectFromParentNodeByEventId(n,s);r&&t.notify(r,{})}}}isListItemBlock(){return"list-item"===this.type}getStyles(t={standalone:!1}){const e=new _(this).toJSON(t);return Object.assign(Object.assign({},e),this.shouldRenderAsInternalWrapper()?{display:"contents"}:{})}getClasses(t={standalone:!1}){return Array.from(this.annotationMap.values()).filter((t=>t instanceof f||t instanceof b)).map((e=>e.renderClass(t))).filter(o).reduce(((t,e)=>[t,e].join(" ").trim()),"")}getCustomAttributesAnnotation(){return this.annotationMap.get(E.CUSTOM_ATTRIBUTE)}generateAttributeString(...t){var e;const s=new _(this).toCssText({standalone:!0}),n=this.annotationMap.get(E.CUSTOM_CLASS),r=[...(null===(e=this.getCustomAttributesAnnotation())||void 0===e?void 0:e.toString(t))||[],null==n?void 0:n.toString(),s?`style="${s}"`:null,...t].filter(o);return r.length?` ${r.join(" ")}`:""}doApply(t){t instanceof m?y.executeTheStrategy(t,this):this.applyAnnotationAction(t)}applyAnnotationAction(t){const e=t.toAnnotation();e instanceof A||this.annotationMap.set(e.type,e),"function"==typeof this.doAnnotationActionApply&&this.doAnnotationActionApply(t)}cloneAnnotations(){return new Map(Array.from(this.annotationMap.entries()).map((([t,e])=>[t,e.clone()])))}}class j{}class D extends j{constructor(){super(...arguments),this.doSplit=!0}}class I extends p{constructor(t){super(),this.type=u.SELECTION_RANGE,this.range=t}clone(){return new I(this.range)}}class $ extends v{constructor(t){super(),this.type=g.STRIKETHROUGH,this.strikethrough=t}static from(t){return[g.STRIKETHROUGH,new $(t)]}toJSON(){return{strikethrough:this.strikethrough}}clone(){return new $(this.strikethrough)}renderClass(t){return(null==t?void 0:t.standalone)?null:this.strikethrough?"v-rte--strikethrough":null}renderStyle(t){return(null==t?void 0:t.standalone)&&this.strikethrough?{textDecoration:"line-through"}:null}}class M extends v{constructor(t){super(),this.type=g.UNDERLINE,this.underline=t}static from(t){return[g.UNDERLINE,new M(t)]}toJSON(){return{underline:this.underline}}clone(){return new M(this.underline)}renderClass(t){return(null==t?void 0:t.standalone)?null:this.underline?"v-rte--underline":null}renderStyle(t){return(null==t?void 0:t.standalone)&&this.underline?{textDecoration:"underline"}:null}}class H extends v{constructor(t){super(),this.type=g.ITALIC,this.italic=t}static from(t){return[g.ITALIC,new H(t)]}toJSON(){return{italic:this.italic}}clone(){return new H(this.italic)}renderClass(t){return(null==t?void 0:t.standalone)?null:this.italic?"v-rte--italic":null}renderStyle(t){return(null==t?void 0:t.standalone)&&this.italic?{fontStyle:"italic"}:null}}class P extends v{constructor(t){super(),this.type=g.BOLD,this.bold=t}static from(t){return[g.BOLD,new P(t)]}toJSON(){return{bold:this.bold}}clone(){return new P(this.bold)}renderClass(t){return(null==t?void 0:t.standalone)?null:this.bold?"v-rte--bold":null}renderStyle(t){return(null==t?void 0:t.standalone)&&this.bold?{fontWeight:"700"}:null}}class J extends v{constructor(t,e=!0){super(),this.type=g.CODE,this.code=t,this.useInternalStyle=e}static from(t,e){return[g.CODE,new J(t,e)]}toJSON(){return{code:this.code}}clone(){return new J(this.code,this.useInternalStyle)}renderClass(t){return(null==t?void 0:t.standalone)?null:this.code&&this.useInternalStyle?"v-rte--code":null}renderStyle(t){return(null==t?void 0:t.standalone)&&this.code&&this.useInternalStyle?{fontFamily:"Roboto Mono",whiteSpace:"pre-wrap"}:null}}const K={key:"black",light:"#111128",dark:"#E3E3E8"},F=[K,{key:"gray",light:"#5E5E6D",dark:"#B9B9C1"},{key:"green",light:"#01801F",dark:"#59D977"},{key:"red",light:"#BD2947",dark:"#FFB2B5"},{key:"purple",light:"#563D82",dark:"#BEB2FF"},{key:"teal",light:"#17758F",dark:"#4CD8FF"}],U="​",W=[["textStyles"],["bold","italic","underline","strikethrough","code"],["textColor"],["horizontalAlignment","bulletsNumbers"],["moreIndent","lessIndent"],["link"],["image"],["clearStyle"]];class G extends v{constructor(t){super(),this.type=g.TEXT_COLOR,this.textColor=this.formatTextColor(t)}static from(t){return[g.TEXT_COLOR,new G(t)]}toJSON(){return{textColor:this.textColor.key}}clone(){return new G(this.textColor.key)}renderClass(){return null}renderStyle(){return{color:a.isDarkMode()?this.textColor.dark:this.textColor.light}}formatTextColor(t){return F.find((e=>e.key===t))||F[0]}}class z extends v{constructor(t,e=!0){super(),this.type=g.LINK,this.link=t,this.useInternalStyle=e}static from(t,e=!0){return[g.LINK,new z(t,e)]}toJSON(){return{link:this.link}}clone(){return new z(this.link,this.useInternalStyle)}toEqual(t){return this.link.groupKey===t.link.groupKey}renderClass(){return null}renderStyle(){return null}}class V extends j{constructor(t,e,s){super(),this.isFlushable=!1,this.groupKey=t,this.nodes=e,this.type=s}toAnnotation(){return new A(this.groupKey)}}class X extends j{constructor(){super(),this.isFlushable=!1}toAnnotation(){return null}}class q{execute(t,e){return i.log(`Executing action ${t.constructor.name} on ${e.constructor.name} ${e.id}`),this.handleAction(t,e)}updateCustomStyleAnnotation(t,e){const s=t.annotationMap.get(E.CUSTOM_STYLE);s&&this.isCustomStyle(s,e)&&t.annotationMap.set(s.type,new k(s.removeStyles(e)))}createNewParagraph(t){const e=L.getRTEBlockClass("paragraph");if(e)return e.from({id:c(),type:"paragraph",nodes:[{id:c(),type:"text",text:t}]})}getRootContent(t){const e=t.parent;if(e)return"VegaRTEContent"===e.constructor.name?e:this.getRootContent(e)}isCaretPositionAtBlockStart(t,e,s){return e===t.children[0]&&0===s}isCaretPositionAtBlockEnd(t,e,s){return e.isContentEditable()?this.isCaretPositionAtTextBlockEnd(t,e,s):this.isCaretPositionAtDecoratorBlockEnd(t,e,s)}isCaretPositionAtTextBlockEnd(t,e,s){const n=t.children[t.children.length-1];return e===n&&(e.isEmpty()||s===n.text.length)}isCaretPositionAtDecoratorBlockEnd(t,e,s){return e===t.children[t.children.length-1]&&0!==s}isCustomStyle(t,e){return e.some((e=>Object.keys(t.customStyle).includes(e)))}}class Y extends m{constructor(t){super(),this.type=x.LINK_GROUP_NODE_SPLIT,this.splittedTextNodes=t}}class Q extends q{constructor(){super(...arguments),this.applyTargetNode=null}handleAction(t,e){const s=e.getAnnotationByType(u.SELECTION_RANGE);if(this.setApplyTargetNode(null),t instanceof D&&t.doSplit&&s){const{startContainer:t,endContainer:n,startOffset:r,endOffset:i}=s.range,o=t===n&&r===i;e.parent.children=e.parent.children.flatMap((t=>{if(t.id===e.id){if(o)return this.insertNewNode(r,e);if(this.shouldSplitSelection(s.range)&&e.isContentEditable()){const n=this.splitTextNode(s.range,e);return t.annotationMap.has("LINK")&&t.apply(new Y(n)),n}return this.setApplyTargetNode(e),e}return t}))}return this.applyTargetNode}insertNewNode(t,e){const s=e.cloneWithText("");this.setApplyTargetNode(s);const n=e.parent.children.findIndex((t=>t===e));return 0===t||!e.isContentEditable()&&t===n?[s,e]:t===e.text.length||!e.isContentEditable()&&t===n+1?[e,s]:[e.cloneWithText(e.text.substring(0,t)),s,e.cloneWithText(e.text.substring(t))]}shouldSplitSelection(t){const{startContainer:e,endContainer:s,startOffset:n,endOffset:r}=t;return e!==s||n>0||r<(s.textContent?s.textContent.length:0)}splitTextNode(t,e){const{startContainer:s,endContainer:n,startOffset:r}=t,i=s.parentElement,o=n.parentElement,c=(t,s,n)=>{const r=t.substring(0,s),i=t.substring(s,n),o=t.substring(n);return[e.cloneWithText(r),e.cloneWithText(i),e.cloneWithText(o)]},a=i&&T.getEntityByDOM(i),l=o&&T.getEntityByDOM(o);if(a&&a.id===e.id){const i=s===n?t.endOffset:e.text.length,[o,a,l]=c(e.text,r,i);return this.setApplyTargetNode(a),[o,a,l].filter((t=>!!t.text))}if(l&&l.id===e.id){const[s,n,r]=c(e.text,0,t.endOffset);return this.setApplyTargetNode(n),[s,n,r].filter((t=>!!t.text))}return this.setApplyTargetNode(e),e}setApplyTargetNode(t){this.applyTargetNode=t}}class Z extends D{constructor(t){super(),this.isFlushable=!0,this.bold=t}toAnnotation(){return new P(this.bold)}}class tt extends p{constructor(){super(...arguments),this.type=u.CLEAR_FORMATTING,this.items=[g.BOLD,g.ITALIC,g.UNDERLINE,g.STRIKETHROUGH,g.TEXT_COLOR,g.CODE,E.CUSTOM_STYLE]}}class et extends D{constructor(){super(...arguments),this.isFlushable=!0}toAnnotation(){return new tt}}class st extends D{constructor(t){super(),this.isFlushable=!0,this.code=t}toAnnotation(){return new J(this.code)}}class nt extends j{constructor(t){super(),this.isFlushable=!0,this.annotationType=t}toAnnotation(){}}class rt extends D{constructor(t){super(),this.isFlushable=!0,this.italic=t}toAnnotation(){return new H(this.italic)}}class it extends D{constructor({link:t,newText:e,needMergeNode:s,doSplit:n,type:r}){super(),this.isFlushable=!0,this.link=t,this.needMergeNode=s,this.newText=e,this.type=r,o(n)&&(this.doSplit=n)}toAnnotation(){return new z(this.link)}}class ot extends D{constructor(t){super(),this.isFlushable=!0,this.strikethrough=t}toAnnotation(){return new $(this.strikethrough)}}class ct extends D{constructor(t){super(),this.isFlushable=!0,this.underline=t}toAnnotation(){return new M(this.underline)}}class at extends q{handleAction(t,e){const s=t.toAnnotation();if(t instanceof nt)e.annotationMap.delete(t.annotationType);else{if(!(s instanceof tt))return s instanceof v||s instanceof I?(t instanceof it&&(o(t.newText)&&(e.text=t.newText),e.parent.apply(new V(t.link.groupKey,[e],t.type))),t instanceof st&&this.handleAction(new et,e),t instanceof Z&&this.updateCustomStyleAnnotation(e,["fontWeight"]),t instanceof rt&&this.updateCustomStyleAnnotation(e,["fontStyle"]),(t instanceof ct||t instanceof ot)&&this.updateCustomStyleAnnotation(e,["textDecoration"]),void e.annotationMap.set(s.type,s)):void 0;s.items.forEach((t=>{e.deleteAnnotationByType(t)}))}}}class lt extends m{constructor(){super(...arguments),this.type=x.DELETE_LINK_GROUP}}class ht extends q{handleAction(t,e){e.text=t.newTextContent,!e.text&&e.annotationMap.has("LINK")&&e.apply(new lt)}}class ut extends m{constructor(t){super(),this.type=x.UPDATE_TEXT,this.newTextContent="",this.newTextContent=t}}class dt extends q{handleAction(t,e){this.replaceSelectedText(t.textToBeInsert,t.currentRange,e)}replaceSelectedText(t,e,s){if(e&&e.startContainer&&e.endContainer){const{startContainer:n,endContainer:r,startOffset:i,endOffset:o}=e;let c=s.text;if(n===r&&i===o&&t)c=s.text.slice(0,i)+t+s.text.slice(i);else{const e=n.parentElement,a=r.parentElement,l=e&&T.getEntityByDOM(e),h=a&&T.getEntityByDOM(a);let u=0,d=s.text.length;l&&l===s?(u=i,d=n===r?o:d):h&&h===s&&(d=o),c=s.text.slice(0,u)+t+s.text.slice(d)}s.apply(new ut(c))}}}class pt extends p{constructor(t){super(),this.type=g.INLINE_HTML,this.htmlTag=t}static from(t){const{htmlTag:e,child:s,customStyle:n,customClass:r,customAttribute:i}=t,o=new pt(e);return o.child=s?pt.from(s)[1]:void 0,o.customAttribute=i?C.from(i)[1]:void 0,o.customClass=r?b.from(r)[1]:void 0,o.customStyle=n?k.from(n)[1]:void 0,[g.INLINE_HTML,o]}clone(){var t,e,s,n;const r=new pt(this.htmlTag);return r.child=null===(t=this.child)||void 0===t?void 0:t.clone(),r.customAttribute=null===(e=this.customAttribute)||void 0===e?void 0:e.clone(),r.customClass=null===(s=this.customClass)||void 0===s?void 0:s.clone(),r.customStyle=null===(n=this.customStyle)||void 0===n?void 0:n.clone(),r}toJSON(){var t,e,s,n;return{inlineHtml:l({htmlTag:this.htmlTag,child:null===(t=this.child)||void 0===t?void 0:t.toJSON().inlineHtml,customAttribute:null===(e=this.customAttribute)||void 0===e?void 0:e.toJSON().customAttribute,customClass:null===(s=this.customClass)||void 0===s?void 0:s.toJSON().customClass,customStyle:null===(n=this.customStyle)||void 0===n?void 0:n.toJSON().customStyle})}}}class ft extends q{handleAction(t,e){const s=e.parent.getAnnotationByType(u.LINK_GROUP);if(s){const n=e.annotationMap.get("LINK").link.groupKey,r=s.linkGroups.get(n);if(r){const i=r.indexOf(e);-1!==i&&(r.splice(i,1,...Array.isArray(t.splittedTextNodes)?t.splittedTextNodes:[t.splittedTextNodes]),s.linkGroups.set(n,r))}}}}class Tt extends q{handleAction(t,e){const s=e.parent.getAnnotationByType(u.LINK_GROUP);if(s){const t=e.annotationMap.get(g.LINK).link.groupKey,n=s.linkGroups.get(t);if(n){const r=n.indexOf(e);-1!==r&&n.splice(r,1),0===n.length&&s.linkGroups.delete(t),0===s.linkGroups.size&&e.parent.annotationMap.delete(u.LINK_GROUP)}}e.annotationMap.delete(g.LINK)}}class xt extends v{constructor(t){super(),this.type=g.PLAIN_TEXT,this.plainText=!0,this.plainText=t}static from(t){return[g.PLAIN_TEXT,new xt(t)]}clone(){return new xt(this.plainText)}renderClass(){}renderStyle(){}toJSON(){return this.plainText?{plainText:this.plainText}:void 0}}class Et extends D{constructor(t){super(),this.isFlushable=!0,this.textColor=t}toAnnotation(){return new G(this.textColor)}}class RTETextNode extends RTENode{constructor(t,e,s,n){super(t,n),this.type=w.TEXT,this.parent=s,this.text=e,this.registerModifyStrategy()}static supportsHtmlTag(t){return["span","code"].includes(t)}static from(t,e,s={autoMatchFormat:!0}){const n=new RTETextNode(t.id,t.text,e),{annotations:r}=t;return r&&(n.annotationMap=this.generateTextAnnotationMap(r,s,e,n)),n}static generateTextAnnotationMap(t,e,s,n){return new Map(Object.keys(t).map((r=>("link"===r&&t.link&&s&&n&&s.apply(new V(t.link.groupKey,[n],"link")),this.createAnnotationEntity(r,t[r],e)))).filter(o))}static createAnnotationEntity(t,e,s){const n=!(!s||!s.autoMatchFormat);switch(t){case"bold":return P.from(e);case"italic":return H.from(e);case"underline":return M.from(e);case"strikethrough":return $.from(e);case"code":return J.from(e,n);case"textColor":return G.from(e);case"link":return z.from(e,n);case"inlineHtml":return pt.from(e);case"plainText":return xt.from(e)}return RTENode.createAnnotationEntity(t,e)}toJSON(){const t=Array.from(this.annotationMap.values()).filter((t=>t instanceof v||t instanceof S||t instanceof pt)).reduce(((t,e)=>Object.assign(Object.assign({},t),e.toJSON())),{});return Object.assign(Object.assign({id:this.id},Object.keys(t).length>0?{annotations:t}:{}),{type:"text",text:this.text})}toHtml(){const t=this.getAnnotationByType(g.INLINE_HTML);return t?this.renderWithWrapperStr(t):this.renderTextStr()}cloneWithText(t){return new RTETextNode(c(),t,this.parent,super.cloneAnnotations())}clone(t){return new RTETextNode(this.id,this.text,t,super.cloneAnnotations())}isEmpty(){return!this.text||"​"===this.text||"\n"===this.text}isTextNode(){return!0}getRangeEndOffset(){return!this.isContentEditable()&&this.parent?this.parent.children.indexOf(this)+1:"\n"===this.text?0:this.text.length}getRangeContainer(){const t=this.getElementRef();if(t)return this.isContentEditable()?t.firstChild:t.parentElement}isContentEditable(){return!0}registerModifyStrategy(){const t=this.constructor.name;RTETextNode.registerActionStrategyStatus[t]||(this.isContentEditable()&&(y.register(x.UPDATE_TEXT,t,new ht),y.register(x.REPLACE_SELECTED_TEXT,t,new dt),y.register(x.LINK_GROUP_NODE_SPLIT,t,new ft),y.register(it.name,t,new at)),y.register(D.name,t,new Q),y.register(x.DELETE_LINK_GROUP,t,new Tt),y.register(Z.name,t,new at),y.register(et.name,t,new at),y.register(rt.name,t,new at),y.register(ct.name,t,new at),y.register(Et.name,t,new at),y.register(ot.name,t,new at),y.register(st.name,t,new at),y.register(j.name,t,new at),RTETextNode.registerActionStrategyStatus[t]=!0)}doAnnotationActionApply(t){const e=this.getAnnotationByType(u.SELECTION_RANGE);if(t instanceof D&&t.doSplit&&e){const e=y.get(D.name,this.constructor.name);if(e){const s=e.execute(t,this);s&&this.applyActionToNode(s,t)}}else this.applyActionToNode(this,t);"function"==typeof this.parent.mergeNodes&&this.parent.mergeNodes(t)}doModifyActionApply(t){y.executeTheStrategy(t,this)}applyActionToNode(t,e){const s=e.toAnnotation();if(e instanceof X)return void this.syncUpSelectedNodes(t);s instanceof I||this.syncUpSelectedNodes(t);const n=y.get(e.constructor.name,t.constructor.name);if(n)return void n.execute(e,t);const r=y.get(j.name,RTETextNode.name);r&&r.execute(e,t)}syncUpSelectedNodes(s){const r=this.getElementRef();if(r){const i=e.getSubjectFromParentNodeByEventId(r,n);i&&t.notify(i,{node:s})}}renderWithWrapperStr(t){const{htmlTag:e,customAttribute:s,customClass:n,customStyle:r,child:i}=t,c=[...(null==s?void 0:s.toString())||[],null==n?void 0:n.toString(),null==r?void 0:r.toString()].filter(o),a=c.length>0?` ${c.join(" ")}`:"";return i?`<${e}${a}>${this.renderWithWrapperStr(i)}</${e}>`:`<${e}${a}>${this.renderTextStr()}</${e}>`}renderTextStr(){var t;const e=(null===(t=this.getAnnotationByType(g.CODE))||void 0===t?void 0:t.code)?"code":"span",s=super.generateAttributeString();return"\n"===this.text?"<br>":this.shouldRenderAsPlainText()?this.text:`<${e}${s}>${this.text}</${e}>`}shouldRenderAsPlainText(){const t=super.getAnnotationByType(g.PLAIN_TEXT);return!!t&&t.plainText&&0===Array.from(this.annotationMap.values()).filter((t=>t instanceof v&&!(t instanceof z)&&!(t instanceof xt)||t instanceof S)).length}}RTETextNode.registerActionStrategyStatus={},RTETextNode.htmlTag="span";class gt extends m{constructor(t){super(),this.type=x.APPEND_CHILDREN,this.entityToBeAppended=t}}class wt extends f{constructor(t){super(),this.type=d.TEXT_STYLE,this.textStyle=t}static from(t){return[d.TEXT_STYLE,new wt(t)]}toJSON(){return{textStyle:this.textStyle}}clone(){return new wt(this.textStyle)}renderClass(t){return(null==t?void 0:t.standalone)?null:this.textStyle?`v-rte--text-style-${this.textStyle}`:null}renderStyle(t){if(!(null==t?void 0:t.standalone))return null;const e={fontFamily:"Inter",fontSize:"16px",lineHeight:"22px",minHeight:"22px",fontWeight:"500"},s=Object.assign(Object.assign({},e),{marginTop:"0px",marginBottom:"0px"});switch(this.textStyle){case"paragraph":return s;case"title":return Object.assign(Object.assign({},e),{fontSize:"36px",lineHeight:"40px",minHeight:"40px"});case"subtitle":return Object.assign(Object.assign({},e),{fontSize:"28px",lineHeight:"32px",minHeight:"32px"});case"heading-1":return Object.assign(Object.assign({},e),{fontSize:"22px",lineHeight:"24px",minHeight:"24px",marginTop:"0px",marginBottom:"0px"});case"heading-2":return Object.assign(Object.assign({},e),{fontSize:"20px",lineHeight:"24px",minHeight:"24px",marginTop:"0px",marginBottom:"0px"});case"heading-3":return Object.assign(Object.assign({},e),{fontSize:"18px",lineHeight:"22px",minHeight:"22px",marginTop:"0px",marginBottom:"0px"});case"heading-4":return Object.assign(Object.assign({},e),{fontSize:"16px",lineHeight:"22px",minHeight:"22px",marginTop:"0px",marginBottom:"0px"});case"heading-5":return Object.assign(Object.assign({},e),{fontSize:"14px",lineHeight:"22px",minHeight:"22px",marginTop:"0px",marginBottom:"0px"});case"heading-6":return Object.assign(Object.assign({},e),{fontSize:"12px",lineHeight:"22px",minHeight:"22px",marginTop:"0px",marginBottom:"0px"})}}}class mt extends j{constructor(t,e){super(),this.isFlushable=!0,this.textStyle=t,this.bold=e}toAnnotation(){return new wt(this.textStyle)}}class At extends q{handleAction(t,e){"list-item"!==e.type&&(e.type=t.textStyle),e.children.forEach(t.bold?t=>{const e=new Z(!0);e.doSplit=!1,t.apply(e)}:t=>{t.apply(new nt(g.BOLD))}),this.updateCustomStyleAnnotation(e,["fontFamily","lineHeight","fontWeight","fontSize"])}}class Ot extends m{constructor(t,...e){super(),this.type=x.INSERT_CHILDREN_AFTER,this.referChildren=t,this.childrenToBeInserted=e}}class Nt extends m{constructor(t){super(),this.type=x.REPLACE_CHILD_NODES,this.newChildNodes=t}}class Rt extends q{handleAction(t,e){t.newBlock=this.splitTextNodeBlock(t.splitPointNode,t.startOffsetOfNode,e)}splitTextNodeBlock(t,e,s){if(t){const n=t.text.slice(0,e),r=t.text.slice(e),i=s.children.indexOf(t);if(i>-1){const e=s.children.slice(0,i),o=s.children.slice(i+1);n&&e.push(t.cloneWithText(n)),r&&o.unshift(t.cloneWithText(r)),s.apply(new Nt(e));const c=s.cloneWithNodes(o);return s.parent.apply(new Ot(s,c)),c}}}}class yt extends q{handleAction(t,e){e.children=[],e.apply(new gt(t.newChildNodes))}}class St extends m{constructor(t){super(),this.type=x.DELETE_CHILDREN,this.entityToBeRemoved=t}}class Ct extends q{handleAction(t,e){const s=t.blockNeedToBeMerged;if(e.type===s.type||"image"!==e.type&&"image"!==s.type){let t=s.children;"image"!==s.type&&(t=s.children.filter((t=>t.text))),e.apply(new gt(t)),s.parent.apply(new St(s))}}}class bt extends q{handleAction(t,e){t.lineBreakNode=this.lineBreakSingleBlock(t.startContainerNode,t.startOffset,e)}lineBreakSingleBlock(t,e,s){if(t){const n=new RTETextNode(c(),"\n",s),r=t.text.slice(0,e),i=t.text.slice(e),o=s.children.indexOf(t);if(o>-1){const e=s.children.slice(0,o),c=s.children.slice(o+1);r&&e.push(t.cloneWithText(r)),i&&c.unshift(t.cloneWithText(i)),this.mergeLineBreakNodes(e,n,c,s)}return n}}mergeLineBreakNodes(t,e,s,n){(0===s.length||s[0]&&""===s[0].text)&&s.push(new RTETextNode(c(),"\n",n,t[t.length-1]&&t[t.length-1].annotationMap)),n.apply(new Nt([...t,e,...s]))}}class kt extends q{handleAction(t,e){t.lineBreakNode=this.lineBreakMultipleBlocks(t.selectedBlocks,e)}lineBreakMultipleBlocks(t,e){const s=e.children,n=new RTETextNode(c(),"\n",e),r=this.concatBlocksNodes(t.slice(1));return this.mergeLineBreakNodes(s,n,r,e),n}concatBlocksNodes(t){const e=[];return t.map((t=>{"image"!==t.type&&(e.push(...t.children),t.parent.apply(new St(t)))})),e}mergeLineBreakNodes(t,e,s,n){(0===s.length||s[0]&&""===s[0].text)&&s.push(new RTETextNode(c(),"\n",n,t[t.length-1]&&t[t.length-1].annotationMap)),n.apply(new Nt([...t,e,...s]))}}class Bt extends m{constructor(t,...e){super(),this.type=x.INSERT_CHILDREN_BEFORE,this.referChildren=t,this.childrenToBeInserted=e}}class vt extends m{constructor(t,e){super(),this.type=x.SPLIT_BLOCK_WITH_NODE,this.splitPointNode=t,this.startOffsetOfNode=e}}class _t extends j{constructor(t){super(),this.isFlushable=!0,this.textAlign=t}toAnnotation(){return new O(this.textAlign)}}class Lt extends q{handleAction(t,e){this.updateCustomStyleAnnotation(e,["textAlign"])}}class jt extends j{constructor(t){super(),this.isFlushable=!0,this.indent=t}toAnnotation(){return new N(this.indent)}}class RTETextBlock extends RTEBlock{constructor(t,e,s){super(t),this.children=[],this.type=e;const{autoMatchFormat:n}=s||{autoMatchFormat:!0};n&&(this.annotationMap=RTETextBlock.isAcceptableTextStyle(e)?new Map([wt.from(e)]):new Map([wt.from("paragraph")]))}static from(t,e={autoMatchFormat:!0}){var s,n;const r=new RTETextBlock(t.id,t.type,e),i=e.autoMatchFormat?Object.assign(Object.assign({},t.annotations),{textStyle:null!==(n=null===(s=t.annotations)||void 0===s?void 0:s.textStyle)&&void 0!==n?n:r.type}):t.annotations;return r.children=t.nodes.map((t=>{const s=L.getRTENodeClass(t.type);if(s)return s.from(t,r,e)})).filter(o),i&&super.convertAnnotationsToMap(r.annotationMap,i),r}static createAnnotationEntity(t,e){return"textStyle"===t?wt.from(e):super.createAnnotationEntity(t,e)}static isAcceptableTextStyle(t){return["title","subtitle","paragraph","heading-1","heading-2","heading-3","heading-4","heading-5","heading-6"].includes(t)}mergeNodes(t){this.children=this.children.reduce(((e,s)=>{const n=e.at(-1);if(t instanceof it&&t.needMergeNode){const t=null==n?void 0:n.getAnnotationByType(g.LINK),r=s.getAnnotationByType(g.LINK);if(t&&r&&t.toEqual(r))return e}return[...e,s]}),[])}toJSON(){return Object.assign(Object.assign({},super.toJSON()),{type:this.type,nodes:this.children.map((t=>t.toJSON()))})}toHtml(){const t=this.getBlockTag(),e=super.generateAttributeString(),s=this.getChildrenHtml();return super.shouldRenderAsInternalWrapper()?s:[`<${t}${e}>`,s,`</${t}>`].join("")}cloneWithNodes(t){const e=new RTETextBlock(c(),this.type);return e.annotationMap=super.cloneAnnotations(),e.apply(new gt(t)),e}clone(t){const e=new RTETextBlock(this.id,this.type);return e.children=this.children.map((t=>t.clone(e))),e.annotationMap=super.cloneAnnotations(),e.parent=t,e}isNotEmpty(){return this.children.length>0&&this.children.some((t=>!t.isEmpty()))}getLastNode(){return this.children[this.children.length-1]}getBlockTag(){switch(this.type){case"title":case"subtitle":return"div";case"heading-1":return"h1";case"heading-2":return"h2";case"heading-3":return"h3";case"heading-4":return"h4";case"heading-5":return"h5";case"heading-6":return"h6";case"paragraph":default:return"p"}}getChildrenHtml(){const t=this.getAnnotationByType(u.LINK_GROUP);let e=this.children.map((t=>t.toHtml())).join("");return t&&this.children.length>0&&(e=this.generateLinkHtml(t,e)),e}doAnnotationActionApply(t){const e=y.get(t.constructor.name,RTETextBlock.name);e&&e.execute(t,this)}generateLinkHtml(t,e){e="";let s=[];for(let n=0;n<this.children.length;n++){const r=this.children[n].getAnnotationByType(g.LINK),i=this.children[n+1]?this.children[n+1].getAnnotationByType(g.LINK):null;if(r){if(s.push(this.children[n]),!i||r.link.groupKey!==i.link.groupKey){const n=t.toString(r,{standalone:!0});e+=[`<a${n?` ${n}`:""}>`,s.map((t=>t.toHtml())).join(""),"</a>"].join(""),s=[]}}else e+=this.children[n].toHtml()}return e}}y.register(mt.name,RTETextBlock.name,new At),y.register(_t.name,RTETextBlock.name,new Lt),y.register(jt.name,RTETextBlock.name,new class extends q{handleAction(t,e){this.updateCustomStyleAnnotation(e,["marginLeft"])}}),y.register(V.name,RTETextBlock.name,new class extends q{handleAction(t,e){let s=e.getAnnotationByType(u.LINK_GROUP);if("update_link"===t.type){if(s){const e=s.linkGroups.get(t.groupKey);e&&s.linkGroups.set(t.groupKey,[e[0]])}}else{if(s){const e=s.linkGroups.get(t.groupKey)||[];s.linkGroups.set(t.groupKey,[...e,...t.nodes])}else s=t.toAnnotation(),s.linkGroups.set(t.groupKey,[...t.nodes]);e.annotationMap.set(u.LINK_GROUP,s)}}}),y.register(x.UNLINK_LINK_GROUP,RTETextBlock.name,new class extends q{handleAction(t,e){const s=e.getAnnotationByType(u.LINK_GROUP);s&&(s.linkGroups.size>1?s.linkGroups.delete(t.groupKey):e.annotationMap.delete(u.LINK_GROUP))}}),y.register(x.SPLIT_BLOCK_WITH_NODE,RTETextBlock.name,new Rt),y.register(x.REPLACE_CHILD_NODES,RTETextBlock.name,new yt),y.register(x.MERGE_TWO_BLOCKS_NODES,RTETextBlock.name,new Ct),y.register(x.LINE_BREAK_SINGLE_BLOCK,RTETextBlock.name,new bt),y.register(x.LINE_BREAK_MULTIPLE_BLOCKS,RTETextBlock.name,new kt),y.register(x.INSERT_IMAGE_TO_BLOCK,RTETextBlock.name,new class extends q{handleAction(t,e){const s=t.splitPointNode,n=t.startOffsetOfNode,r=t.imageBlockToBeInserted;if(this.isCaretPositionAtBlockEnd(e,s,n))e.parent.apply(new Ot(e,r));else if(this.isCaretPositionAtBlockStart(e,s,n))e.parent.apply(new Bt(e,r));else{const t=new vt(s,n);e.apply(t),e.parent.apply(new Ot(e,r))}}}),y.register(x.TRANSFORM_LIST_BLOCK,RTETextBlock.name,new class extends q{handleAction(t,e){const s=e.parent,n=s.createList(t.listType),r=t.selectedBlocks,i=r.map((t=>s.toListItem(t)));n.apply(new gt(i)),s.apply(new Ot(t.selectedBlocks[0],n)),r.forEach((t=>{t.parent.apply(new St(t))}))}});class Dt extends q{getPreviousNode(t){const e=t.parent,s=e.children.indexOf(t);if(s>0)return e.children[s-1];if(e.parent){const t=this.getPreviousBlock(e);if(t)return this.getBlockLastNode(t)}}getNextNode(t){const e=t.parent,s=e.children.indexOf(t);if(e.children[s+1])return e.children[s+1];if(e.parent){const t=this.getNextBlock(e);if(t)return this.getBlockFirstNode(t)}}isContentFirstNode(t){const e=t.parent,s=e.children.indexOf(t),n=e.parent;if(e.isListItemBlock()){const t=n.parent;return 0===s&&Array.isArray(n.children)&&n.children[0]===e&&"list-item"!==t.type&&Array.isArray(t.children)&&t.children[0]===n}return 0===s&&Array.isArray(n.children)&&n.children[0]===e}getPreviousBlock(t){if(t&&t.parent&&t.parent.children){const e=t.parent.children.indexOf(t);if(e>0)return t.parent.children[e-1];if(this.isRTEBlock(t.parent)&&0===e)return this.getPreviousBlock(t.parent)}}getBlockLastNode(t){return t.getLastNode()}getBlockFirstNode(t){if("number-list"===t.type||"bullet-list"===t.type){if(t.children)return this.getBlockFirstNode(t.children[0])}else if(t.children)return t.children[0]}getNextBlock(t){if(t&&t.parent&&t.parent.children){const e=t.parent.children.indexOf(t);if(t.parent.children[e+1])return t.parent.children[e+1];if("list-item"===t.type&&t.parent.children.length===e+1)return this.getNextBlock(t.parent)}}isRTEBlock(t){return t&&"VegaRTEContent"!==t.constructor.name}}class It extends m{constructor(t,e){super(),this.isFlushable=!0,this.type=x.UPDATE_CODE_BLOCK,this.content=t,this.language=e}}class $t extends j{constructor(t){super(),this.isFlushable=!1,this.range=t}toAnnotation(){return new I(this.range)}}class RTEDecoratorNode extends RTENode{constructor(){super(...arguments),this.type="decorator-node",this.isSelected=!1}static isDecoratorNodeContainerElement(t){return t&&t.classList.contains(RTEDecoratorNode.DECORATOR_CONTAINER_CLASS)}static getDecoratorNodeElement(t){return t.querySelector(`.${RTEDecoratorNode.DECORATOR_NODE_CLASS}`)}getRangeEndOffset(){return 1}getRangeContainer(){const t=this.getElementRef();if(t)return h(t,`.${RTEDecoratorNode.DECORATOR_CONTAINER_CLASS}`)}isContentEditable(){return!1}}RTEDecoratorNode.DECORATOR_CONTAINER_CLASS="v-internal-decorator-container",RTEDecoratorNode.DECORATOR_NODE_CLASS="v-internal-decorator-node";class RTECodeBlockNode extends RTEDecoratorNode{constructor(t,e,s,n){super(t),this.type=w.CODE_BLOCK_NODE,this.text="",this.annotationMap=new Map,this.text=e,this.parent=n,this.language=s}toJSON(){return{id:this.id,type:"text",text:this.text,language:this.language}}toHtml(){return`<code style='box-sizing: border-box;color: rgba(var(--v-text-primary, 32, 54, 69, 1));text-align: left;font-family: "Roboto Mono";font-weight: 400;line-height: 22px;font-size: 16px;white-space: pre-wrap;min-height: 22px;tab-size: 2px;'>${this.text}</code>`}clone(t){return new RTECodeBlockNode(this.id,this.text,this.language,t)}doAnnotationActionApply(t){y.executeTheStrategy(t,this)}doModifyActionApply(t){y.executeTheStrategy(t,this)}}y.register(x.UPDATE_CODE_BLOCK,RTECodeBlockNode.name,new class extends q{handleAction(t,e){const{content:s,language:n}=t;e.language=n,e.text=s}}),y.register($t.name,RTECodeBlockNode.name,new class extends q{handleAction(t,e){e.annotationMap.set(u.SELECTION_RANGE,t.toAnnotation())}});var Mt;!function(t){t.CSS="css",t.HTML="html",t.JavaScript="js",t.JSX="jsx",t["Plain Text"]="plainText",t.TypeScript="ts",t.TSX="tsx"}(Mt||(Mt={}));class Ht extends q{handleAction(t,e){e.children=e.children.filter((e=>e!==t.entityToBeRemoved)),0===e.children.length&&"parent"in e&&e.parent&&(e.isListItemBlock()&&e.nestList&&e.nestList.length||e.parent.apply(new St(e)))}}class RTECodeBlock extends RTEBlock{constructor(t,e,s){super(t),this.type="code-block",this.children=[new RTECodeBlockNode(`${t}-1`,e,s,this)]}static from(t){return new RTECodeBlock(t.id,t.content,t.language)}toJSON(){const{language:t,text:e}=this.children[0];return{id:this.id,type:"code-block",content:e,language:t}}toHtml(){const{language:t=Mt["Plain Text"]}=this.children[0];return`<pre data-language="${t}" style="background-color: rgba(var(--v-bg-secondary, 245, 247, 247, 1)); padding: 12px">${this.children.map((t=>t.toHtml()))}</pre>`}clone(t){const e=RTECodeBlock.from(this.toJSON());return e.parent=t,e}apply(n){if(n instanceof m&&y.executeTheStrategy(n,this),n.isFlushable){const n=T.getDOMByEntity(this);if(n){const r=e.getSubjectFromParentNodeByEventId(n,s);r&&t.notify(r,{})}}}isNotEmpty(){return!!this.children.length}getLastNode(){return this.children[0]}isSelected(){return this.children[0].annotationMap.has(u.SELECTION_RANGE)}}y.register(x.DELETE_CODE_BLOCK,RTECodeBlock.name,new class extends Dt{handleAction(t,e){const s=e.children[0],n=e.parent;if(n){let t=this.getPreviousNode(s),r=this.getRTENodeEndOffset(t);t||(t=this.getNextNode(s),r=0),n.apply(new St(e));const i=t?T.getDOMByEntity(t):null;if(0===n.children.length){const s=RTETextBlock.from({id:c(),type:"paragraph",nodes:[{id:c(),type:"text",text:""}]});e.parent.apply(new gt([s])),t=s.children[0],r=0}this.notifyUpdateSelection(t,i,r,e)}}notifyUpdateSelection(s,r,i,o){const c=T.getDOMByEntity(o);if(c){const o=e.getSubjectFromParentNodeByEventId(c,n);o&&t.notify(o,{node:s,updateDirectly:!!r,offset:i})}}getRTENodeEndOffset(t){return t?t.getRangeEndOffset():0}}),y.register(x.DELETE_CHILDREN,RTECodeBlock.name,new Ht),y.register(x.SWITCH_OUT_FROM_CODE_BLOCK,RTECodeBlock.name,new class extends q{handleAction(s,r){const{content:i,language:o}=s,a=i.split("\n"),l=new It(a.slice(0,a.length-2).join("\n"),o);l.isFlushable=!1,r.children[0].apply(l);const h=RTETextBlock.from({id:c(),type:"paragraph",nodes:[{id:c(),text:"",type:"text"}]});r.parent.apply(new Ot(r,h));const u=T.getDOMByEntity(r);if(u){const s=e.getSubjectFromParentNodeByEventId(u,n);s&&t.notify(s,{node:h.children[0]})}}}),y.register(x.INSERT_IMAGE_TO_BLOCK,RTECodeBlock.name,new class extends q{handleAction(t,e){e.parent.apply(new Ot(e,t.imageBlockToBeInserted))}}),RTECodeBlock.CODE_BLOCK_PLACEHOLDER_CLASS_NAME="code-block-placeholder-element";export{Et as $,y as A,At as B,C,w as D,S as E,j as F,Nt as G,_t as H,Ot as I,vt as J,Dt as K,Ht as L,m as M,v as N,F as O,K as P,Mt as Q,L as R,X as S,mt as T,ut as U,W as V,it as W,E as X,It as Y,U as Z,$t as _,R as a,RTECodeBlockNode as a0,Z as a1,rt as a2,ct as a3,wt as a4,P as a5,et as a6,st as a7,ot as a8,jt as a9,RTETextNode as b,x as c,q as d,RTETextBlock as e,RTEBlock as f,_ as g,gt as h,RTENode as i,Bt as j,u as k,Lt as l,bt as m,kt as n,Rt as o,yt as p,Ct as q,St as r,T as s,f as t,d as u,k as v,b as w,RTECodeBlock as x,g as y,RTEDecoratorNode as z}
@@ -0,0 +1 @@
1
+ import{r as t,h as e,H as i,g as r}from"./p-6b2342e0.js";import{g as o,I as s}from"./p-16493e5b.js";import{h as a}from"./p-1f83cebf.js";import{s as v}from"./p-519a7d55.js";import{i as n}from"./p-691ba1ae.js";import{a as h}from"./p-d9671d27.js";import{V as c}from"./p-8c9ea6f4.js";import{L as p,I as l}from"./p-6e1ab235.js";import{V as x,I as d}from"./p-d849e0f5.js";import{t as m}from"./p-b75ee3ba.js";import"./p-ed45b3b6.js";import"./p-40f39194.js";import"./p-d884c644.js";import"./p-f69f84a7.js";import"./p-2d0d575f.js";import"./p-a528714c.js";import"./p-a4670e23.js";import"./p-6a334573.js";import"./p-430be941.js";import"./p-10ac8b57.js";import"./p-262ec334.js";import"./p-0c667d6a.js";import"./p-d27ae9ff.js";import"./p-5f377954.js";import"./p-c2488ed6.js";import"./p-ef9cbad1.js";import"./p-331a62d5.js";import"./p-112455b1.js";import"./p-4866e390.js";import"./p-fe12eff6.js";import"./p-8d0ca805.js";import"./p-b1f869fb.js";import"./p-6f8be8ea.js";import"./p-5b71c85e.js";import"./p-02841589.js";import"./p-bf19682d.js";import"./p-a7b5f497.js";import"./p-e77a83e4.js";import"./p-db8cdba6.js";import"./p-5d676a94.js";var g=function(t,e,i,r){var o,s=arguments.length,a=s<3?e:null===r?r=Object.getOwnPropertyDescriptor(e,i):r;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(t,e,i,r);else for(var v=t.length-1;v>=0;v--)(o=t[v])&&(a=(s<3?o(a):s>3?o(e,i,a):o(e,i))||a);return s>3&&a&&Object.defineProperty(e,i,a),a};const b=class{constructor(e){t(this,e),this.globalSlimmers={},this.vegaComponentUsageRuntimeMetricsSlimmer=new x,this.size="size-16",this.cloneFAIconStyles=()=>{if(this.isThirdPartyIcon(this.icon)){const t=this.getIconStyleHTML();t&&this.appendStyles(t);let e=0;const i=window.setInterval((()=>{if(!(e<10))return p.warn("[Vega] Loading Font Awesome timeout.",this.icon),void clearInterval(i);{e++;const t=this.getIconStyleHTML();if(t)return this.appendStyles(t),void clearInterval(i)}}),300)}}}watchIcon(){this.cloneFAIconStyles()}componentWillLoad(){this.cloneFAIconStyles()}render(){const t=s.findIndex((t=>t===this.icon));if(c.hasIcon(this.icon)){const{icon:t,autoSize:e}=c.getIcon(this.icon);return this.renderForVegaIconToken(t,e?null:this.size,e)}return t>-1?this.renderForVegaIconToken(o(this.icon),this.size):this.renderForThirdPartyIcon()}isThirdPartyIcon(t){return!c.hasIcon(t)&&!s.find((e=>e===t))}renderForVegaIconToken(t,r,o=!1){const s=r?this.formatAndValidSize(this.size):null;return v(e(i,{class:h([s,this.color&&n(this.color),o&&"vega-auto-size"]),innerHTML:t},e("slot",null)),this.host)}renderForThirdPartyIcon(){return v(e(i,{class:h([this.color&&n(this.color)]),style:this.formatThirdPartyIconSize(this.size)},e("i",{part:"icon",class:this.icon})),this.host)}formatAndValidSize(t){return`v-w-${t} v-h-${t}`}formatThirdPartyIconSize(t){return{"font-size":`${a[t]}px`}}appendStyles(t){var e;if(t&&m()){const i=null!==(e=this.host.shadowRoot.querySelector("#fa-icon-styles"))&&void 0!==e?e:m().createElement("style");i.id="fa-icon-styles",i.innerHTML=t,this.host.shadowRoot.appendChild(i)}}getIconStyleHTML(){var t;if(b.iconStyleCache.has(this.icon))return b.iconStyleCache.get(this.icon);if(m()){const e=m().createElement("i");e.className=this.icon,e.style.display="none",m().body.appendChild(e);const i=getComputedStyle(e);if(null===(t=i.fontFamily)||void 0===t?void 0:t.includes("Font Awesome")){const t=getComputedStyle(e,"::before"),r=getComputedStyle(e,"::after"),o=`\n\t\t\t\ti {\n\t\t\t\t\tfont-weight: ${i.fontWeight};\n\t\t\t\t\tfont-family: ${i.fontFamily};\n\t\t\t\t\tfont-style: ${i.fontStyle};\n\t\t\t\t\tposition: ${i.position};\n\t\t\t\t\tletter-spacing: ${i.letterSpacing};\n\t\t\t\t}\n\t\t\t\ti::before {\n\t\t\t\t\tcontent: ${t.content};\n\t\t\t\t\tposition: ${t.position};\n\t\t\t\t\topacity: ${t.opacity};\n\t\t\t\t}\n\t\t\t\ti::after {\n\t\t\t\t\tcontent: ${r.content};\n\t\t\t\t\tposition: ${r.position};\n\t\t\t\t\topacity: ${r.opacity};\n\t\t\t\t}\n\t\t\t`.replace(/[\n\t]/gi,"");return b.iconStyleCache.set(this.icon,o),m().body.removeChild(e),o}return m().body.removeChild(e),null}}get host(){return r(this)}static get watchers(){return{icon:["watchIcon"]}}};b.iconStyleCache=new Map,g([d()],b.prototype,"globalSlimmers",void 0),g([l()],b.prototype,"vegaComponentUsageRuntimeMetricsSlimmer",void 0),b.style=":host(.v-text-primary),.v-text-primary{color:rgba(var(--v-text-primary, 32, 54, 69, 1))}:host(.v-text-secondary),.v-text-secondary{color:rgba(var(--v-text-secondary, 107, 116, 125, 1))}:host(.v-text-inverted-primary),.v-text-inverted-primary{color:rgba(var(--v-text-inverted-primary, 252, 252, 252, 1))}:host(.v-text-inverted-secondary),.v-text-inverted-secondary{color:rgba(var(--v-text-inverted-secondary, 188, 186, 213, 1))}:host(.v-text-black),.v-text-black{color:rgba(var(--v-text-black, 32, 54, 69, 1))}:host(.v-text-white),.v-text-white{color:rgba(var(--v-text-white, 252, 252, 252, 1))}:host(.v-text-brand),.v-text-brand{color:rgba(var(--v-text-brand, 51, 57, 61, 1))}:host(.v-text-danger-link),.v-text-danger-link{color:rgba(var(--v-text-danger-link, 230, 50, 87, 1))}:host(.v-text-danger-link-hover),.v-text-danger-link-hover{color:rgba(var(--v-text-danger-link-hover, 233, 71, 104, 1))}:host(.v-text-danger-link-active),.v-text-danger-link-active{color:rgba(var(--v-text-danger-link-active, 189, 41, 71, 1))}:host(.v-text-danger-link-focus),.v-text-danger-link-focus{color:rgba(var(--v-text-danger-link-focus, 240, 52, 91, 1))}:host(.v-text-danger-link-visited),.v-text-danger-link-visited{color:rgba(var(--v-text-danger-link-visited, 230, 50, 87, 1))}:host(.v-text-disabled),.v-text-disabled{color:rgba(var(--v-text-disabled, 176, 180, 181, 1))}:host(.v-text-error),.v-text-error{color:rgba(var(--v-text-error, 189, 41, 71, 1))}:host(.v-text-input-disabled),.v-text-input-disabled{color:rgba(var(--v-text-input-disabled, 107, 116, 125, 1))}:host(.v-text-input-placeholder),.v-text-input-placeholder{color:rgba(var(--v-text-input-placeholder, 176, 180, 181, 1))}:host(.v-text-link),.v-text-link{color:rgba(var(--v-text-link, 19, 98, 226, 1))}:host(.v-text-link-hover),.v-text-link-hover{color:rgba(var(--v-text-link-hover, 4, 112, 236, 1))}:host(.v-text-link-active),.v-text-link-active{color:rgba(var(--v-text-link-active, 29, 65, 195, 1))}:host(.v-text-link-focus),.v-text-link-focus{color:rgba(var(--v-text-link-focus, 4, 112, 236, 1))}:host(.v-text-link-visited),.v-text-link-visited{color:rgba(var(--v-text-link-visited, 95, 56, 206, 1))}:host(.v-text-on-action),.v-text-on-action{color:rgba(var(--v-text-on-action, 252, 252, 252, 1))}:host(.v-text-on-danger),.v-text-on-danger{color:rgba(var(--v-text-on-danger, 252, 252, 252, 1))}:host(.v-text-on-disabled),.v-text-on-disabled{color:rgba(var(--v-text-on-disabled, 252, 252, 252, 1))}:host(.v-text-sidebar-link),.v-text-sidebar-link{color:rgba(var(--v-text-sidebar-link, 188, 186, 213, 1))}:host(.v-text-sidebar-link-hover),.v-text-sidebar-link-hover{color:rgba(var(--v-text-sidebar-link-hover, 18, 18, 39, 1))}:host(.v-text-sidebar-link-selected),.v-text-sidebar-link-selected{color:rgba(var(--v-text-sidebar-link-selected, 252, 252, 252, 1))}:host(.v-text-site-footer-link),.v-text-site-footer-link{color:rgba(var(--v-text-site-footer-link, 171, 198, 216, 1))}:host(.v-text-site-footer-link-hover),.v-text-site-footer-link-hover{color:rgba(var(--v-text-site-footer-link-hover, 199, 217, 229, 1))}:host(.v-text-site-footer-link-active),.v-text-site-footer-link-active{color:rgba(var(--v-text-site-footer-link-active, 143, 179, 203, 1))}:host(.v-text-success),.v-text-success{color:rgba(var(--v-text-success, 1, 128, 31, 1))}:host(.v-text-inverted-success),.v-text-inverted-success{color:rgba(var(--v-text-inverted-success, 89, 217, 119, 1))}:host(.v-text-accent1-primary),.v-text-accent1-primary{color:rgba(var(--v-text-accent1-primary, 115, 230, 220, 1))}:host(.v-text-accent2-primary),.v-text-accent2-primary{color:rgba(var(--v-text-accent2-primary, 128, 107, 255, 1))}:host(.v-text-accent3-primary),.v-text-accent3-primary{color:rgba(var(--v-text-accent3-primary, 255, 220, 131, 1))}:host(.v-text-accent4-primary),.v-text-accent4-primary{color:rgba(var(--v-text-accent4-primary, 255, 149, 113, 1))}:host(.v-text-accent5-primary),.v-text-accent5-primary{color:rgba(var(--v-text-accent5-primary, 0, 187, 255, 1))}:host(.v-text-accent6-primary),.v-text-accent6-primary{color:rgba(var(--v-text-accent6-primary, 240, 52, 91, 1))}:host(.v-text-accent7-primary),.v-text-accent7-primary{color:rgba(var(--v-text-accent7-primary, 37, 159, 159, 1))}:host(.v-text-accent8-primary),.v-text-accent8-primary{color:rgba(var(--v-text-accent8-primary, 86, 61, 130, 1))}:host(.v-text-accent9-primary),.v-text-accent9-primary{color:rgba(var(--v-text-accent9-primary, 255, 191, 63, 1))}:host(.v-text-accent10-primary),.v-text-accent10-primary{color:rgba(var(--v-text-accent10-primary, 237, 122, 35, 1))}:host(.v-w-0),.v-w-0{width:0px}:host(.v-w-size-0),.v-w-size-0{width:0px}:host(.v-w-size-4),.v-w-size-4{width:4px}:host(.v-w-size-8),.v-w-size-8{width:8px}:host(.v-w-size-12),.v-w-size-12{width:12px}:host(.v-w-size-16),.v-w-size-16{width:16px}:host(.v-w-size-20),.v-w-size-20{width:20px}:host(.v-w-size-24),.v-w-size-24{width:24px}:host(.v-w-size-32),.v-w-size-32{width:32px}:host(.v-w-size-40),.v-w-size-40{width:40px}:host(.v-w-size-48),.v-w-size-48{width:48px}:host(.v-w-size-64),.v-w-size-64{width:64px}:host(.v-w-size-72),.v-w-size-72{width:72px}:host(.v-w-size-80),.v-w-size-80{width:80px}:host(.v-w-size-112),.v-w-size-112{width:112px}:host(.v-w-size-2),.v-w-size-2{width:2px}:host(.v-h-0),.v-h-0{height:0px}:host(.v-h-size-0),.v-h-size-0{height:0px}:host(.v-h-size-4),.v-h-size-4{height:4px}:host(.v-h-size-8),.v-h-size-8{height:8px}:host(.v-h-size-12),.v-h-size-12{height:12px}:host(.v-h-size-16),.v-h-size-16{height:16px}:host(.v-h-size-20),.v-h-size-20{height:20px}:host(.v-h-size-24),.v-h-size-24{height:24px}:host(.v-h-size-32),.v-h-size-32{height:32px}:host(.v-h-size-40),.v-h-size-40{height:40px}:host(.v-h-size-48),.v-h-size-48{height:48px}:host(.v-h-size-64),.v-h-size-64{height:64px}:host(.v-h-size-72),.v-h-size-72{height:72px}:host(.v-h-size-80),.v-h-size-80{height:80px}:host(.v-h-size-112),.v-h-size-112{height:112px}:host(.v-h-size-2),.v-h-size-2{height:2px}:host{display:inline-flex;user-select:none}i{line-height:1}:host(:not(.vega-auto-size)) ::slotted(svg){width:100%;height:100%}";export{b as vega_icon}
@@ -1 +1 @@
1
- import{h as t,r as e,c as i,H as n,g as s}from"./p-6b2342e0.js";import{I as o}from"./p-abd7aeaa.js";import{M as a,a as r}from"./p-f0ff4463.js";import{M as l,a as p}from"./p-cdbbdcc2.js";import{R as c}from"./p-280cbcdb.js";import{s as h}from"./p-519a7d55.js";import{C as d}from"./p-75b58efe.js";import{c as u,V as f,M as g,I as v}from"./p-6e1ab235.js";import{s as x}from"./p-6bd5c49b.js";import{V as m,I as b}from"./p-d849e0f5.js";import{F as w}from"./p-20010bd6.js";import{c as y}from"./p-c841be8d.js";import{D as C,a as j,d as k,y as I,V as S,i as R,H as z,I as E,J as O,K as D,L as T}from"./p-11a6c1b7.js";import{S as V}from"./p-dd11f735.js";import{S as L}from"./p-badad9ed.js";import{i as M}from"./p-1f83cebf.js";import{S as N}from"./p-22989693.js";import{i as F}from"./p-d27ae9ff.js";import{d as A}from"./p-bf19682d.js";import{p as P,q as $,r as B,m as _}from"./p-1b44db34.js";import{P as U}from"./p-10ac8b57.js";import{S as W}from"./p-0d57293b.js";import{a as K}from"./p-8c9ea6f4.js";import{c as q}from"./p-86194314.js";import{C as H}from"./p-2d0d575f.js";import{F as G}from"./p-a528714c.js";import{C as J}from"./p-8187878e.js";import"./p-262ec334.js";import"./p-02841589.js";import"./p-331a62d5.js";import"./p-d9671d27.js";import"./p-a4670e23.js";import"./p-6a334573.js";import"./p-f69f84a7.js";import"./p-78a57a17.js";import"./p-52b8f2d2.js";import"./p-3532aa12.js";import"./p-b75ee3ba.js";import"./p-ed45b3b6.js";import"./p-40f39194.js";import"./p-d884c644.js";import"./p-9472d19a.js";import"./p-5d676a94.js";const X=/^(?:[a-z0-9!#$%&'*+/=?^_`{|}~-]+(?:\.[a-z0-9!#$%&'*+/=?^_`{|}~-]+)*|"(?:[\x01-\x08\x0b\x0c\x0e-\x1f\x21\x23-\x5b\x5d-\x7f]|\\[\x01-\x09\x0b\x0c\x0e-\x7f])*")@(?:(?:[a-z0-9](?:[a-z0-9-]*[a-z0-9])?\.)+[a-z0-9](?:[a-z0-9-]*[a-z0-9])?|\[(?:(?:25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\.){3}(?:25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?|[a-z0-9-]*[a-z0-9]:(?:[\x01-\x08\x0b\x0c\x0e-\x1f\x21-\x5a\x53-\x7f]|\\[\x01-\x09\x0b\x0c\x0e-\x7f])+)])$/;class Y extends o{evaluate(t){if(!this.isAcceptedInputType(t))throw new Error(`Unexpected type of input: ${typeof t}: ${t}`);const e=X.test(t.toLowerCase());return{isValid:e,message:e?"":"Please enter the correct email format."}}canEvaluate(t,e){return e?this.isAcceptedInputType(t)&&!e.disabled&&e.visible:this.isAcceptedInputType(t)}shouldShowError(t){return!t.disabled&&t.visible&&(t.touched||t.modified)}isAcceptedInputType(t){return"string"==typeof t&&t.length>0}}class Q extends f{getCopyPasteProps(){return this.disableCopyPaste?{onCopy:this.preventDefault,onCut:this.preventDefault,onPaste:this.preventDefault}:{}}preventDefault(t){t.preventDefault()}}!function(t,e,i,n){var s,o=arguments.length,a=o<3?e:null===n?n=Object.getOwnPropertyDescriptor(e,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(t,e,i,n);else for(var r=t.length-1;r>=0;r--)(s=t[r])&&(a=(o<3?s(a):o>3?s(e,i,a):s(e,i))||a);o>3&&a&&Object.defineProperty(e,i,a)}([u()],Q.prototype,"disableCopyPaste",void 0);var Z=function(t,e,i,n){var s,o=arguments.length,a=o<3?e:null===n?n=Object.getOwnPropertyDescriptor(e,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(t,e,i,n);else for(var r=t.length-1;r>=0;r--)(s=t[r])&&(a=(o<3?s(a):o>3?s(e,i,a):s(e,i))||a);return o>3&&a&&Object.defineProperty(e,i,a),a};class tt extends f{render(){const e=this.hasPrefixSlot();if(this.prefixIcon||e)return t("div",{class:{"vega-input-prefix":!0,"vega-input-prefix-slot":e},part:"prefix-icon-container"},this.prefixIcon&&!e?t("vega-icon",{icon:this.prefixIcon,size:"size-16"}):null,t("slot",{name:"prefix-icon"}))}hasPrefixSlot(){return!!this.host.querySelector('[slot="prefix-icon"]')}}Z([u()],tt.prototype,"host",void 0),Z([u()],tt.prototype,"prefixIcon",void 0);class et extends L{format(t){if(!t.length)return t;const e=Number(t.replace(/,/g,""));return!isNaN(e)&&e<=Number.MAX_SAFE_INTEGER?e.toLocaleString("en-US"):t}calculateCaretPosition(t,e){const i=this.format(t),n=t.substring(0,e),s=i.substring(0,e),o=(n.match(/,/g)||[]).length;return e+((s.match(/,/g)||[]).length-o)}}class it extends L{constructor(t){super(),this.maskConfig={allowNegative:!0},this.skipFormat=t=>this.maskConfig.allowNegative&&"-"===t||null!=this.maskConfig.precision&&this.maskConfig.precision>0&&t.split(".").length-1==1&&t.endsWith(".")&&!t.startsWith("."),this.maskConfig=Object.assign(Object.assign({},this.maskConfig),t),this.mask=new RegExp(this.getRegExp())}format(t){const e=this.redressAbnormalNumber(t);if(this.skipFormat(e))return e;const i=[...e];for(let t=e.length-1;t>=0;t--){const t=i.join("");this.inputNeedFormat(t)&&i.pop()}return i.join("")}calculateCaretPosition(t,e){if(M(e)){const i=this.redressAbnormalNumber(t);return e-(t.length-i.length)}}inputNeedFormat(t){return!this.mask.test(t)}redressAbnormalNumber(t){let e=t.replace(/^0+(?!$)/,"");return e.startsWith(".")&&(e=`0${e}`),e}getRegExp(){const t=this.maskConfig.allowNegative?"(\\-)?":"";let e;return e=0===this.maskConfig.precision?`^${t}(0|[1-9][0-9]*)$`:this.maskConfig.precision&&this.maskConfig.precision>0?`^${t}(0|0\\.\\d{1,${this.maskConfig.precision}}|[1-9][0-9]*(\\.\\d{1,${this.maskConfig.precision}})?)$`:`^${t}(0|0\\.\\d*|[1-9][0-9]*(\\.\\d*)?)$`,e}}class nt extends L{constructor(t,e=!1){super(),this.resetCaretPositionFlag=!1,this.formatter=t,this.resetCaretPositionFlag=e}format(t){return this.formatter(t)}calculateCaretPosition(t,e){if(!0===this.resetCaretPositionFlag)return this.format(t).length;if(M(e)){const i=t.substring(0,e);return e+(this.format(i).length-i.length)}}shouldTriggerAtInit(){return!0}}class st extends it{constructor(t){super(t)}format(t){const e=this.redressAbnormalNumber(t);if(this.skipFormat(e))return e;const i=[...e];for(let t=e.length-1;t>=0;t--){const t=i.join("");this.inputNeedFormat(t.replace(/,/g,""))&&i.pop()}return this.thousandCommaFormat(i.join(""))}calculateCaretPosition(t,e){const i=this.redressAbnormalNumber(t),n=this.format(t),s=t.substring(0,e),o=n.substring(0,e),a=(s.match(/,/g)||[]).length;return e+((o.match(/,/g)||[]).length-a)-(t.length-i.length)}thousandCommaFormat(t){if(!t.length)return t;const e=t.replace(/[^\d.-]/g,""),i=e.indexOf("."),n=e.length>1&&i>=1?e.slice(i):"",s=Number(e.split(".")[0]);return!isNaN(s)&&s<=Number.MAX_SAFE_INTEGER?s.toLocaleString("en-US")+n:e}}var ot=function(t,e,i,n){var s,o=arguments.length,a=o<3?e:null===n?n=Object.getOwnPropertyDescriptor(e,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(t,e,i,n);else for(var r=t.length-1;r>=0;r--)(s=t[r])&&(a=(o<3?s(a):o>3?s(e,i,a):s(e,i))||a);return o>3&&a&&Object.defineProperty(e,i,a),a};class at extends N{constructor(){super(...arguments),this.getInputElementRef=()=>this.inputRenderer.getInputRef(),this.getInputModeStrategy=()=>this.generateMaskStrategy("input"),this.getBlurModeStrategy=()=>this.generateMaskStrategy("blur")}connectedCallback(){this.initSetupMaskConfigObserver()}disconnectedCallback(){this.removeSetupMaskConfigObserver()}watchValue(t,e){t!==e&&this.formatValueAfterValueChange()}watchMaskChange(t,e){this.areMaskConfigsEqual(t,e)||this.setup()}watchTypeChange(t,e){"number"!==t&&"number"!==e||this.setup()}generateMaskStrategy(t){let e=null;Array.isArray(this.maskConfig)?e=this.maskConfig.find((e=>"blur"===t?this.isBlurModeMaskConfig(e):!this.isBlurModeMaskConfig(e))):this.maskConfig&&("blur"===t&&this.isBlurModeMaskConfig(this.maskConfig)?e=this.maskConfig:"input"!==t||this.isBlurModeMaskConfig(this.maskConfig)||(e=this.maskConfig));let i=null;switch(null==e?void 0:e.type){case"phone":i=V.PHONE_MASK;break;case"taxId":i=V.TAX_ID_MASK;break;case"zipcode":i=V.ZIPCODE_MASK;break;case"thousand-comma":i=new et;break;case"number":i=this.getNumberTypeMaskStrategy(e.options);break;case"custom":i=e.strategy?e.strategy():new V(e.options);break;case"custom-formatter":i=new nt(e.formatter,e.resetCaretPosition)}return"number"!==this.type||"input"!==t||e||(i=new it),i}getNumberTypeMaskStrategy(t){return t&&t.thousandComma?new st(t):new it(t)}isBlurModeMaskConfig(t){return"custom"===t.type&&"blur"===t.trigger}areMaskConfigsEqual(t,e){const i=Array.isArray(t)?t:[t],n=Array.isArray(e)?e:[e];return F(i,n,!0,((t,e)=>A(t,e)?0:-1))}initSetupMaskConfigObserver(){C.addUniqueObserverToNode(this.host,P,this.setup.bind(this))}removeSetupMaskConfigObserver(){C.removeUniqueObserverFromNode(this.host,P)}}ot([u()],at.prototype,"maskConfig",void 0),ot([u()],at.prototype,"disableCopyPaste",void 0),ot([u()],at.prototype,"type",void 0),ot([u()],at.prototype,"inputRenderer",void 0),ot([g("connectedCallback")],at.prototype,"connectedCallback",null),ot([g("disconnectedCallback")],at.prototype,"disconnectedCallback",null),ot([g("watchValue")],at.prototype,"watchValue",null),ot([g("watchMaskChange")],at.prototype,"watchMaskChange",null),ot([g("watchTypeChange")],at.prototype,"watchTypeChange",null);const rt=[{payloadKey:"AUTO_VALIDATION_IS_TRUE",payloadDescription:"Determines whether the input field should undergo automatic validation during the user's input",payloadValue:t=>!0===t.autoValidation},{payloadKey:"AUTO_VALIDATION_IS_FALSE",payloadDescription:"Determines whether the input field should undergo automatic validation during the user's input",payloadValue:t=>!1===t.autoValidation},{payloadKey:"EMAIL_IS_TRUE",payloadDescription:"@deprecated Enforces proper email format validation for the input field.",payloadValue:t=>!0===t.email},{payloadKey:"EMAIL_IS_FALSE",payloadDescription:"@deprecated Enforces proper email format validation for the input field.",payloadValue:t=>!1===t.email}];var lt=function(t,e,i,n){var s,o=arguments.length,a=o<3?e:null===n?n=Object.getOwnPropertyDescriptor(e,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(t,e,i,n);else for(var r=t.length-1;r>=0;r--)(s=t[r])&&(a=(o<3?s(a):o>3?s(e,i,a):s(e,i))||a);return o>3&&a&&Object.defineProperty(e,i,a),a};class pt extends f{componentDidLoad(){this.setInputAutoWidth()}watchValue(){this.setInputAutoWidth()}watchSuffixText(){this.setInputAutoWidth()}setInputAutoWidth(){const t=this.host.shadowRoot.querySelector(".vega-input-container"),e=null==t?void 0:t.querySelector(".vega-input-input"),i=null==e?void 0:e.querySelector("input");if(i&&(t.classList.remove("auto-width"),i.style.removeProperty("width"),this.isCompactInputWidth&&this.suffixText)){const n=this.getActualInputWidth();e.getBoundingClientRect().width>n&&(i.style.width=`${n}px`,t.classList.add("auto-width"))}}getActualInputWidth(){const t=this.getCalculateTextWidthContainer();t.style.display="inline-block",t.textContent=`${this.value||this.placeholder||""}`;const e=t.getBoundingClientRect().width;return t.style.display="none",e}getCalculateTextWidthContainer(){if(!this.calculateTextWidthContainer){const t=document.createElement("div");t.classList.add("v-font-field-value"),t.style.visibility="hidden",t.style.display="none",this.host.shadowRoot.append(t),this.calculateTextWidthContainer=t}return this.calculateTextWidthContainer}}lt([u()],pt.prototype,"host",void 0),lt([u()],pt.prototype,"value",void 0),lt([u()],pt.prototype,"placeholder",void 0),lt([u()],pt.prototype,"isCompactInputWidth",void 0),lt([u()],pt.prototype,"suffixText",void 0),lt([g("componentDidLoad")],pt.prototype,"componentDidLoad",null),lt([g("watchValue")],pt.prototype,"watchValue",null),lt([g("watchSuffixText")],pt.prototype,"watchSuffixText",null);var ct=function(t,e,i,n){var s,o=arguments.length,a=o<3?e:null===n?n=Object.getOwnPropertyDescriptor(e,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(t,e,i,n);else for(var r=t.length-1;r>=0;r--)(s=t[r])&&(a=(o<3?s(a):o>3?s(e,i,a):s(e,i))||a);return o>3&&a&&Object.defineProperty(e,i,a),a};class ht extends W{constructor(){super({parent:"vega-input-numeric",subStates:[{subStateName:"prefixText",parentStateName:"prefixText"},{subStateName:"suffixText",parentStateName:"suffixText"},{subStateName:"isCompactInputWidth",parentStateName:"isCompactInputWidth"}]})}}ct([u()],ht.prototype,"host",void 0),ct([u({writable:!0})],ht.prototype,"prefixText",void 0),ct([u({writable:!0})],ht.prototype,"suffixText",void 0),ct([u({writable:!0})],ht.prototype,"isCompactInputWidth",void 0);var dt=function(t,e,i,n){var s,o=arguments.length,a=o<3?e:null===n?n=Object.getOwnPropertyDescriptor(e,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(t,e,i,n);else for(var r=t.length-1;r>=0;r--)(s=t[r])&&(a=(o<3?s(a):o>3?s(e,i,a):s(e,i))||a);return o>3&&a&&Object.defineProperty(e,i,a),a};class ut extends f{render(){return t("vega-button-circle",{icon:K.getIconKey(this.isPasswordDisplay?"eye":"eye-slash"),variant:"icon-only",size:"small",class:"password-eye-button",ref:t=>{this.addEyeIconObserver(t)}})}addEyeIconObserver(t){C.addUniqueObserverToNode(t,j,(()=>{this.isPasswordDisplay=!this.isPasswordDisplay}))}}K.register({eye:{icon:'<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 576 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="M288 32c-80.8 0-145.5 36.8-192.6 80.6C48.6 156 17.3 208 2.5 243.7c-3.3 7.9-3.3 16.7 0 24.6C17.3 304 48.6 356 95.4 399.4C142.5 443.2 207.2 480 288 480s145.5-36.8 192.6-80.6c46.8-43.5 78.1-95.4 93-131.1c3.3-7.9 3.3-16.7 0-24.6c-14.9-35.7-46.2-87.7-93-131.1C433.5 68.8 368.8 32 288 32zM144 256a144 144 0 1 1 288 0 144 144 0 1 1 -288 0zm144-64c0 35.3-28.7 64-64 64c-7.1 0-13.9-1.2-20.3-3.3c-5.5-1.8-11.9 1.6-11.7 7.4c.3 6.9 1.3 13.8 3.2 20.7c13.7 51.2 66.4 81.6 117.6 67.9s81.6-66.4 67.9-117.6c-11.1-41.5-47.8-69.4-88.6-71.1c-5.8-.2-9.2 6.1-7.4 11.7c2.1 6.4 3.3 13.2 3.3 20.3z"/></svg>'},"eye-slash":{icon:'<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 640 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="M38.8 5.1C28.4-3.1 13.3-1.2 5.1 9.2S-1.2 34.7 9.2 42.9l592 464c10.4 8.2 25.5 6.3 33.7-4.1s6.3-25.5-4.1-33.7L525.6 386.7c39.6-40.6 66.4-86.1 79.9-118.4c3.3-7.9 3.3-16.7 0-24.6c-14.9-35.7-46.2-87.7-93-131.1C465.5 68.8 400.8 32 320 32c-68.2 0-125 26.3-169.3 60.8L38.8 5.1zM223.1 149.5C248.6 126.2 282.7 112 320 112c79.5 0 144 64.5 144 144c0 24.9-6.3 48.3-17.4 68.7L408 294.5c8.4-19.3 10.6-41.4 4.8-63.3c-11.1-41.5-47.8-69.4-88.6-71.1c-5.8-.2-9.2 6.1-7.4 11.7c2.1 6.4 3.3 13.2 3.3 20.3c0 10.2-2.4 19.8-6.6 28.3l-90.3-70.8zM373 389.9c-16.4 6.5-34.3 10.1-53 10.1c-79.5 0-144-64.5-144-144c0-6.9 .5-13.6 1.4-20.2L83.1 161.5C60.3 191.2 44 220.8 34.5 243.7c-3.3 7.9-3.3 16.7 0 24.6c14.9 35.7 46.2 87.7 93 131.1C174.5 443.2 239.2 480 320 480c47.8 0 89.9-12.9 126.2-32.5L373 389.9z"/></svg>'}}),dt([u()],ut.prototype,"host",void 0),dt([u({writable:!0})],ut.prototype,"isPasswordDisplay",void 0),dt([u()],ut.prototype,"type",void 0);var ft=function(t,e,i,n){var s,o=arguments.length,a=o<3?e:null===n?n=Object.getOwnPropertyDescriptor(e,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(t,e,i,n);else for(var r=t.length-1;r>=0;r--)(s=t[r])&&(a=(o<3?s(a):o>3?s(e,i,a):s(e,i))||a);return o>3&&a&&Object.defineProperty(e,i,a),a};class gt extends f{constructor(){super(...arguments),this.renderPrefixText=()=>this.prefixText&&t("div",{class:"prefix-text"},this.prefixText),this.renderSuffixText=()=>this.suffixText&&t("div",{class:"suffix-text"},this.suffixText),this.onClickClearIcon=()=>{H.notify(k.getSubject(this.host,$),"")},this.isClearIconVisible=()=>!this.disabled&&Boolean(this.value),this.onClearInputFocus=()=>{this.inputContainerRef.classList.add("no-focus")},this.onClearInputBlur=()=>{this.inputContainerRef.classList.remove("no-focus")},this.onContainerClick=()=>{H.notify(k.getSubject(this.host,B),{})}}getInputContainerRef(){return this.inputContainerRef}render(){return t("div",{ref:t=>this.inputContainerRef=t,part:"input-container",class:{"vega-input-container":!0,"with-value":!!this.value,[`vega-input-size-${this.size}`]:!0,"vega-input-disabled":this.disabled,"compact-input-width":this.isCompactInputWidth},onClick:this.onContainerClick,"aria-label":"input container","aria-disabled":`${this.disabled}`,role:"textbox",tabIndex:this.disabled?null:-1,onKeyDown:q()},this.prefixSlotRenderer.render(),this.renderPrefixText(),this.inputRenderer.render(),this.renderSuffixText(),"password"===this.type?this.passwordEyeRenderer.render():this.showClearIcon&&this.renderClearIcon())}renderClearIcon(){return t("div",{class:{"vega-input-clear-icon":!0,invisible:!this.isClearIconVisible()},tabIndex:this.disabled?-1:0,"aria-label":"clear input",role:"button",onClick:this.onClickClearIcon,onKeyDown:q(),onFocusin:this.onClearInputFocus,onFocusout:this.onClearInputBlur},t("vega-icon",{icon:"close"}))}}ft([u()],gt.prototype,"host",void 0),ft([u()],gt.prototype,"value",void 0),ft([u()],gt.prototype,"size",void 0),ft([u()],gt.prototype,"disabled",void 0),ft([u()],gt.prototype,"type",void 0),ft([u()],gt.prototype,"showClearIcon",void 0),ft([u()],gt.prototype,"prefixText",void 0),ft([u()],gt.prototype,"suffixText",void 0),ft([u()],gt.prototype,"isCompactInputWidth",void 0),ft([u()],gt.prototype,"prefixSlotRenderer",void 0),ft([u()],gt.prototype,"passwordEyeRenderer",void 0),ft([u()],gt.prototype,"inputRenderer",void 0);var vt=function(t,e,i,n){var s,o=arguments.length,a=o<3?e:null===n?n=Object.getOwnPropertyDescriptor(e,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(t,e,i,n);else for(var r=t.length-1;r>=0;r--)(s=t[r])&&(a=(o<3?s(a):o>3?s(e,i,a):s(e,i))||a);return o>3&&a&&Object.defineProperty(e,i,a),a};class xt extends f{constructor(){super(...arguments),this.setInputRef=t=>{t&&this.inputRef!==t&&(this.inputRef=t,this.notifySetupMaskConfig())},this.handleInputFocus=t=>{this.focusEventEmitter.emit(void 0,t)},this.handleInputBlur=t=>{this.blurEventEmitter.emit(void 0,t)},this.handleInputPaste=t=>{this.pasteEventEmitter.emit(t.clipboardData).defaultPrevented&&t.preventDefault()},this.onInputHandler=()=>{"change"!==this.valueUpdateTrigger&&this.notifyInputValueChange()},this.inputChangeHandler=()=>{"change"===this.valueUpdateTrigger&&this.notifyInputValueChange()}}connectedCallback(){this.initInputFocusObserver()}disconnectedCallback(){this.removeInputFocusObserver()}doFocus(){this.focusInput()}doBlur(){this.inputRef.blur()}getInputRef(){return this.inputRef}render(){return t("div",{class:"vega-input-input"},t("input",Object.assign({part:"input",name:this.name,type:this.getInputType(),autoComplete:this.autocomplete,inputmode:this.inputmode,value:this.value,ref:this.setInputRef,placeholder:this.placeholder,disabled:this.disabled,"aria-label":this.label||"No label defined",minLength:this.minLength,maxLength:this.maxLength,onBlur:t=>this.handleInputBlur(t),onFocus:t=>this.handleInputFocus(t),onChange:this.inputChangeHandler,onInput:this.onInputHandler,onPaste:t=>this.handleInputPaste(t)},this.copyPasteController.getCopyPasteProps())))}getInputType(){switch(this.type){case"number":return"text";case"password":return this.isPasswordDisplay?"text":"password";default:return this.type}}notifyInputValueChange(){this.inputRef.value!==this.value&&this.nativeInputChangeEventEmitter.emit(this.inputRef.value),H.notify(k.getSubject(this.host,$),this.inputRef.value)}notifySetupMaskConfig(){H.notify(k.getSubject(this.host,P),{})}initInputFocusObserver(){C.addUniqueObserverToNode(this.host,B,this.focusInput.bind(this))}removeInputFocusObserver(){C.removeUniqueObserverFromNode(this.host,B)}focusInput(){this.inputRef.focus()}}vt([u()],xt.prototype,"host",void 0),vt([u()],xt.prototype,"value",void 0),vt([u()],xt.prototype,"disabled",void 0),vt([u()],xt.prototype,"type",void 0),vt([u()],xt.prototype,"label",void 0),vt([u()],xt.prototype,"name",void 0),vt([u()],xt.prototype,"autocomplete",void 0),vt([u()],xt.prototype,"inputmode",void 0),vt([u()],xt.prototype,"placeholder",void 0),vt([u()],xt.prototype,"minLength",void 0),vt([u()],xt.prototype,"maxLength",void 0),vt([u()],xt.prototype,"isPasswordDisplay",void 0),vt([u()],xt.prototype,"valueUpdateTrigger",void 0),vt([u()],xt.prototype,"focusEventEmitter",void 0),vt([u()],xt.prototype,"blurEventEmitter",void 0),vt([u()],xt.prototype,"pasteEventEmitter",void 0),vt([u()],xt.prototype,"copyPasteController",void 0),vt([u()],xt.prototype,"nativeInputChangeEventEmitter",void 0),vt([g("connectedCallback")],xt.prototype,"connectedCallback",null),vt([g("disconnectedCallback")],xt.prototype,"disconnectedCallback",null),vt([g("doFocus")],xt.prototype,"doFocus",null),vt([g("doBlur")],xt.prototype,"doBlur",null);var mt=function(t,e,i,n){var s,o=arguments.length,a=o<3?e:null===n?n=Object.getOwnPropertyDescriptor(e,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(t,e,i,n);else for(var r=t.length-1;r>=0;r--)(s=t[r])&&(a=(o<3?s(a):o>3?s(e,i,a):s(e,i))||a);return o>3&&a&&Object.defineProperty(e,i,a),a};class bt extends f{constructor(){super(...arguments),this.handleLabelButtonClick=()=>{this.labelButtonClickEventEmitter.emit()},this.handleLabelClick=()=>{H.notify(k.getSubject(this.host,B),{})}}render(){return t("div",{class:"vega-input",part:"container-wrapper"},this.renderLabelDom(),this.renderInputContainer(),this.renderHintDom())}renderInputContainer(){return this.renderModeController.isSource()||this.renderModeController.isTemplate()?this.inputSuggestionsRenderer.render(this.inputContainerRenderer.render()):this.inputContainerRenderer.render()}renderLabelDom(){return t("vega-field-label",{"is-field-required":this.required,disabled:this.disabled,label:this.label,suffixButtonProps:this.labelSuffixButtonProps,suffixButtonConfig:this.labelSuffixButtonConfig,ref:t=>{C.addUniqueObserverToNode(t,I,this.handleLabelButtonClick),C.addUniqueObserverToNode(t,j,this.handleLabelClick)}})}renderHintDom(){return""!==this.hint?t("div",{class:"vega-hint"},t("label",null,this.hint)):null}}mt([u()],bt.prototype,"host",void 0),mt([u()],bt.prototype,"disabled",void 0),mt([u()],bt.prototype,"required",void 0),mt([u()],bt.prototype,"label",void 0),mt([u()],bt.prototype,"hint",void 0),mt([u()],bt.prototype,"labelSuffixButtonProps",void 0),mt([u()],bt.prototype,"labelSuffixButtonConfig",void 0),mt([u()],bt.prototype,"labelButtonClickEventEmitter",void 0),mt([u()],bt.prototype,"inputContainerRenderer",void 0),mt([u()],bt.prototype,"inputSuggestionsRenderer",void 0),mt([u()],bt.prototype,"renderModeController",void 0);var wt=function(t,e,i,n){var s,o=arguments.length,a=o<3?e:null===n?n=Object.getOwnPropertyDescriptor(e,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(t,e,i,n);else for(var r=t.length-1;r>=0;r--)(s=t[r])&&(a=(o<3?s(a):o>3?s(e,i,a):s(e,i))||a);return o>3&&a&&Object.defineProperty(e,i,a),a};class yt extends f{connectedCallback(){this.initValueUpdateObserver()}disconnectedCallback(){this.removeValueUpdateObserver()}watchValue(t){this.changeEventEmitter.emit(t);const e=this.inputRenderer.getInputRef();e.value!==this.value&&(e.value=this.value),H.notify(G,{host:this.host,detail:this.value})}initValueUpdateObserver(){C.addUniqueObserverToNode(this.host,$,this.setValue.bind(this))}removeValueUpdateObserver(){C.removeUniqueObserverFromNode(this.host,$)}setValue(t){this.value=t}}wt([u()],yt.prototype,"host",void 0),wt([u({writable:!0})],yt.prototype,"value",void 0),wt([u()],yt.prototype,"changeEventEmitter",void 0),wt([u()],yt.prototype,"inputRenderer",void 0),wt([g("connectedCallback")],yt.prototype,"connectedCallback",null),wt([g("disconnectedCallback")],yt.prototype,"disconnectedCallback",null),wt([g("watchValue")],yt.prototype,"watchValue",null);var Ct=function(t,e,i,n){var s,o=arguments.length,a=o<3?e:null===n?n=Object.getOwnPropertyDescriptor(e,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(t,e,i,n);else for(var r=t.length-1;r>=0;r--)(s=t[r])&&(a=(o<3?s(a):o>3?s(e,i,a):s(e,i))||a);return o>3&&a&&Object.defineProperty(e,i,a),a};class jt extends f{constructor(){super(...arguments),this.templateItems=[],this.onDropdownItemClick=async t=>{const e=this.renderModeController.isTemplate()?this.templateItems:this.suggestionsDropdownSource,i=this.findItem(e,t.detail);if(i){const t=this.suggestionItemClickEventEmitter.emit(i);H.notify(k.getSubject(this.host,$),t.defaultPrevented?this.value:i.label)}}}appendHostItemsToDropdown(){this.renderModeController.isTemplate()&&this.itemsSlotRef&&this.dropdownRef&&(this.itemsSlotRef.remove(),this.dropdownRef.append(this.host.querySelector("[slot=items]")))}async showSuggestionsDropdown(t={}){this.suggestionsDropdownConfig=t,await this.showSuggestions()}async hideSuggestionsDropdown(){await this.dropdownRef.hide()}async watchValue(){await this.searchSuggestions()}async watchSuggestionsDropdownSource(){await this.searchSuggestions()}render(e){return t("vega-dropdown",Object.assign({},this.suggestionsDropdownConfig,{source:this.suggestionsDropdownSource,trigger:new J,matchTargetWidth:!0,searchable:!1,placement:["top","bottom"],translocation:{X:0,Y:6},ref:t=>{this.dropdownRef=t,this.addDropdownObserver(t)},style:{display:"block"}}),e,this.renderItemsSlot())}renderItemsSlot(){return this.renderModeController.isTemplate()&&t("div",{slot:"items",ref:t=>{this.itemsSlotRef=t}})}addDropdownObserver(t){C.addUniqueObserverToNode(t,S,this.onDropdownItemClick.bind(this)),C.addUniqueObserverToNode(t,_,(t=>{this.templateItems=Array.from(t).map((t=>({key:t.itemKey,label:t.label})))}))}findItem(t,e){for(const i of t){if(i.children&&i.children.length>0){const t=this.findItem(i.children,e);if(t)return t}if(i.key.toString()===e)return i}return null}async showSuggestions(){(this.renderModeController.isSource()||this.renderModeController.isTemplate())&&await this.dropdownRef.show()}async searchSuggestions(){this.renderModeController.isSource()&&this.suggestionsDropdownSource.length>0&&await this.dropdownRef.search(this.value)}}Ct([u()],jt.prototype,"host",void 0),Ct([u()],jt.prototype,"value",void 0),Ct([u({writable:!0})],jt.prototype,"suggestionsDropdownConfig",void 0),Ct([u()],jt.prototype,"suggestionsDropdownSource",void 0),Ct([u()],jt.prototype,"renderModeController",void 0),Ct([u()],jt.prototype,"suggestionItemClickEventEmitter",void 0),Ct([g("componentDidLoad")],jt.prototype,"appendHostItemsToDropdown",null),Ct([g("showSuggestionsDropdown")],jt.prototype,"showSuggestionsDropdown",null),Ct([g("hideSuggestionsDropdown")],jt.prototype,"hideSuggestionsDropdown",null),Ct([g("watchValue")],jt.prototype,"watchValue",null),Ct([g("watchSuggestionsDropdownSource")],jt.prototype,"watchSuggestionsDropdownSource",null);var kt=function(t,e,i,n){var s,o=arguments.length,a=o<3?e:null===n?n=Object.getOwnPropertyDescriptor(e,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(t,e,i,n);else for(var r=t.length-1;r>=0;r--)(s=t[r])&&(a=(o<3?s(a):o>3?s(e,i,a):s(e,i))||a);return o>3&&a&&Object.defineProperty(e,i,a),a};class It extends f{constructor(){super(...arguments),this.hasItemsSlot=!1,this.hasDropdownSource=!1}connectedCallback(){this.setRenderMode()}isSource(){return this.hasDropdownSource}isTemplate(){return this.hasItemsSlot}setRenderMode(){this.hasItemsSlot=!!this.host.querySelector("[slot=items]"),this.hasDropdownSource=Array.isArray(this.suggestionsDropdownSource)}}kt([u()],It.prototype,"host",void 0),kt([u()],It.prototype,"suggestionsDropdownSource",void 0),kt([g("connectedCallback")],It.prototype,"connectedCallback",null);var St=function(t,e,i,n){var s,o=arguments.length,a=o<3?e:null===n?n=Object.getOwnPropertyDescriptor(e,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(t,e,i,n);else for(var r=t.length-1;r>=0;r--)(s=t[r])&&(a=(o<3?s(a):o>3?s(e,i,a):s(e,i))||a);return o>3&&a&&Object.defineProperty(e,i,a),a};const Rt=class{constructor(t){e(this,t),this.vegaChange=i(this,"vegaChange",7),this.change=i(this,"change",7),this.vegaNativeInputChange=i(this,"vegaNativeInputChange",7),this.nativeInputChange=i(this,"nativeInputChange",7),this.vegaBlur=i(this,"vegaBlur",7),this.blur=i(this,"blur",7),this.vegaFocus=i(this,"vegaFocus",7),this.focus=i(this,"focus",7),this.vegaLabelButtonClick=i(this,"vegaLabelButtonClick",7),this.labelButtonClick=i(this,"labelButtonClick",7),this.vegaPaste=i(this,"vegaPaste",7),this.paste=i(this,"paste",7),this.vegaSuggestionItemClick=i(this,"vegaSuggestionItemClick",7),this.suggestionItemClick=i(this,"suggestionItemClick",7),this.globalSlimmers={},this.formFieldController=new w({propertyRules:[{propertyName:"required",ruleFactory:t=>t?new c:null},{propertyName:"min",ruleFactory:t=>"number"==typeof t?new a({minValue:t}):null},{propertyName:"max",ruleFactory:t=>"number"==typeof t?new r({maxValue:t}):null},{propertyName:"minLength",ruleFactory:t=>t?new l({minStrLength:t}):null},{propertyName:"maxLength",ruleFactory:t=>t?new p({maxStrLength:t}):null},{propertyName:"email",ruleFactory:t=>t?new Y:null},{propertyName:"type",ruleFactory:t=>"email"===t?new Y:null}],validationRulesName:"validationRules",defaultValue:"",attributeGetter:t=>this[t],inputContainerGetter:()=>this.inputContainerRenderer.getInputContainerRef(),touchableAreaGetter:()=>[this.inputRenderer.getInputRef()]}),this.pageResizeObserverSlimmer=new U({callback:()=>this.compactWidthController.setInputAutoWidth()}),this.renderModeController=new It,this.copyPasteController=new Q,this.compactWidthController=new pt,this.stateController=new ht,this.maskConfigController=new at,this.valueController=new yt,this.prefixSlotRenderer=new tt,this.renderer=new bt,this.inputContainerRenderer=new gt,this.inputRenderer=new xt,this.inputSuggestionsRenderer=new jt,this.changeEventEmitter=y(Rt,R),this.nativeInputChangeEventEmitter=y(Rt,z),this.focusEventEmitter=y(Rt,E),this.blurEventEmitter=y(Rt,O),this.labelButtonClickEventEmitter=y(Rt,I),this.suggestionItemClickEventEmitter=y(Rt,D),this.pasteEventEmitter=y(Rt,T),this.vegaComponentUsageRuntimeMetricsSlimmer=new m(rt),this.passwordEyeRenderer=new ut,this.label="",this.labelSuffixButtonProps=null,this.labelSuffixButtonConfig=null,this.value="",this.valueUpdateTrigger="input",this.type="text",this.name="",this.autocomplete="off",this.email=!1,this.required=!1,this.min=null,this.max=null,this.minLength=null,this.maxLength=null,this.showClearIcon=!0,this.isValid=null,this.autoValidation=!0,this.validationRules=[],this.size="default",this.disabled=!1,this.hint="",this.disableCopyPaste=!1}watchSuffixText(){}watchValue(t){}watchTypeChange(t,e){}watchValidationRules(){}watchMaskChange(t,e){}watchSuggestionsDropdownSource(){}async doFocus(){}async doBlur(){}async showSuggestionsDropdown(t){}async hideSuggestionsDropdown(){}render(){return x(t("slot",null)),h(t(n,{class:"hidden"===this.type?"vega-input-hidden":"vega-input-inline-block"},this.renderer.render()),this.host)}get host(){return s(this)}static get watchers(){return{suffixText:["watchSuffixText"],value:["watchValue"],type:["watchTypeChange"],validationRules:["watchValidationRules"],maskConfig:["watchMaskChange"],suggestionsDropdownSource:["watchSuggestionsDropdownSource"]}}};St([b()],Rt.prototype,"globalSlimmers",void 0),St([v()],Rt.prototype,"formFieldController",void 0),St([v()],Rt.prototype,"pageResizeObserverSlimmer",void 0),St([v()],Rt.prototype,"renderModeController",void 0),St([v()],Rt.prototype,"copyPasteController",void 0),St([v()],Rt.prototype,"compactWidthController",void 0),St([v()],Rt.prototype,"stateController",void 0),St([v()],Rt.prototype,"maskConfigController",void 0),St([v()],Rt.prototype,"valueController",void 0),St([v()],Rt.prototype,"prefixSlotRenderer",void 0),St([v()],Rt.prototype,"renderer",void 0),St([v()],Rt.prototype,"inputContainerRenderer",void 0),St([v()],Rt.prototype,"inputRenderer",void 0),St([v()],Rt.prototype,"inputSuggestionsRenderer",void 0),St([v()],Rt.prototype,"changeEventEmitter",void 0),St([v()],Rt.prototype,"nativeInputChangeEventEmitter",void 0),St([v()],Rt.prototype,"focusEventEmitter",void 0),St([v()],Rt.prototype,"blurEventEmitter",void 0),St([v()],Rt.prototype,"labelButtonClickEventEmitter",void 0),St([v()],Rt.prototype,"suggestionItemClickEventEmitter",void 0),St([v()],Rt.prototype,"pasteEventEmitter",void 0),St([v()],Rt.prototype,"vegaComponentUsageRuntimeMetricsSlimmer",void 0),St([v()],Rt.prototype,"passwordEyeRenderer",void 0),St([d()],Rt.prototype,"watchMaskChange",null),Rt.style=':host{cursor:text;display:block;text-align:left;line-height:normal}:host(.vega-input-inline-block){display:inline-block;width:100%}:host(.vega-input-hidden){display:none}vega-field-label{margin-bottom:8px}.vega-input-container{display:flex;align-items:center;border-radius:8px;gap:8px;background-color:rgba(var(--v-bg-primary, 252, 252, 252, 1));border:1px solid rgba(var(--v-border-input-field, 171, 198, 216, 1))}.vega-input-container:hover{border:1px solid rgba(var(--v-border-input-field-hover, 115, 160, 190, 1))}.vega-input-container.vega-input-disabled{background-color:rgba(var(--v-bg-secondary, 245, 247, 247, 1));border:1px solid rgba(var(--v-border-input-field-disabled, 222, 225, 227, 1))}.vega-input-container.vega-input-disabled:hover{border:1px solid rgba(var(--v-border-input-field-disabled, 222, 225, 227, 1))}.vega-input-container.vega-input-disabled input{color:rgba(var(--v-text-input-disabled, 107, 116, 125, 1))}.vega-input-container.with-value{border-width:1px;border-style:solid;border-radius:8px}.vega-input-container:not(.no-focus):focus-within{outline:2px solid rgba(var(--v-border-color-action, 19, 98, 226, 1));outline-offset:3px;border:1px solid rgba(var(--v-border-color-input-field-focus, 19, 98, 226, 1))}.vega-input-container.error{border:1px solid rgba(var(--v-border-input-field-danger, 230, 50, 87, 1))}.vega-input-container.error:hover{border:1px solid rgba(var(--v-border-input-field-danger-hover, 255, 87, 114, 1))}.vega-input-container.error:not(.no-focus):focus-within{outline:2px solid rgba(var(--v-border-color-danger, 230, 50, 87, 1));outline-offset:3px;border:1px solid rgba(var(--v-border-color-input-field-danger-focus, 233, 71, 104, 1))}.vega-input-container.error .vega-input-clear-icon:focus-within{outline:2px solid rgba(var(--v-border-color-danger, 230, 50, 87, 1));outline-offset:2px}.vega-input-prefix{text-align:center;color:rgba(var(--v-text-secondary, 107, 116, 125, 1));font-size:0px}.vega-input-prefix.vega-input-prefix-slot{height:24px;overflow:hidden}.vega-input-input{flex:1 1 0%;position:relative}.vega-input-input input{width:100%;outline:2px solid transparent;outline-offset:2px;border-style:none;height:24px;box-sizing:border-box;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;font-family:"Inter", sans-serif;font-size:16px;font-weight:400;line-height:24px;letter-spacing:0px;color:rgba(var(--v-text-primary, 32, 54, 69, 1));background-color:rgba(var(--v-bg-primary, 252, 252, 252, 1))}@media screen and (min-width: 768px) and (max-width: 1023px){.vega-input-input input{font-family:"Inter", sans-serif;font-size:16px;font-weight:400;line-height:24px;letter-spacing:0px}}@media screen and (min-width: 1024px) and (max-width: 1439px){.vega-input-input input{font-family:"Inter", sans-serif;font-size:16px;font-weight:400;line-height:24px;letter-spacing:0px}}@media screen and (min-width: 1440px) and (max-width: 9999px){.vega-input-input input{font-family:"Inter", sans-serif;font-size:16px;font-weight:400;line-height:24px;letter-spacing:0px}}.vega-input-input input::placeholder{color:rgba(var(--v-text-input-placeholder, 176, 180, 181, 1))}.vega-input-size-small{padding-top:8px;padding-right:12px;padding-bottom:8px;padding-left:12px}.vega-input-size-default{padding-top:12px;padding-right:16px;padding-bottom:12px;padding-left:16px}.vega-input-input input:disabled{background-color:rgba(var(--v-bg-secondary, 245, 247, 247, 1))}.vega-hint{padding-top:12px;padding-right:8px;padding-left:8px}.vega-hint>label{font-family:"Inter", sans-serif;font-size:14px;font-weight:400;line-height:18px;letter-spacing:0px;color:rgba(var(--v-text-secondary, 107, 116, 125, 1))}@media screen and (min-width: 768px) and (max-width: 1023px){.vega-hint>label{font-family:"Inter", sans-serif;font-size:14px;font-weight:400;line-height:18px;letter-spacing:0px}}@media screen and (min-width: 1024px) and (max-width: 1439px){.vega-hint>label{font-family:"Inter", sans-serif;font-size:14px;font-weight:400;line-height:18px;letter-spacing:0px}}@media screen and (min-width: 1440px) and (max-width: 9999px){.vega-hint>label{font-family:"Inter", sans-serif;font-size:14px;font-weight:400;line-height:18px;letter-spacing:0px}}.vega-error{font-family:"Inter", sans-serif;font-size:14px;font-weight:400;line-height:18px;letter-spacing:0px;color:rgba(var(--v-text-error, 189, 41, 71, 1));display:block;padding-top:12px;padding-right:8px;padding-left:8px}@media screen and (min-width: 768px) and (max-width: 1023px){.vega-error{font-family:"Inter", sans-serif;font-size:14px;font-weight:400;line-height:18px;letter-spacing:0px}}@media screen and (min-width: 1024px) and (max-width: 1439px){.vega-error{font-family:"Inter", sans-serif;font-size:14px;font-weight:400;line-height:18px;letter-spacing:0px}}@media screen and (min-width: 1440px) and (max-width: 9999px){.vega-error{font-family:"Inter", sans-serif;font-size:14px;font-weight:400;line-height:18px;letter-spacing:0px}}.vega-hidden{display:none}.vega-input-clear-icon{width:16px;height:16px;cursor:pointer;color:rgba(var(--v-text-secondary, 107, 116, 125, 1))}.vega-input-clear-icon:focus-within{outline:2px solid rgba(var(--v-border-color-action, 19, 98, 226, 1));outline-offset:2px;border-radius:4px;padding:2px}.vega-input-clear-icon.invisible{visibility:hidden}.vega-input-clear-icon vega-icon{min-width:-webkit-min-content;min-width:-moz-min-content;min-width:min-content;flex-shrink:0}input[type=number]::-webkit-outer-spin-button,input[type=number]::-webkit-inner-spin-button{-webkit-appearance:none;margin:0}input[type=number]{-moz-appearance:textfield}input[type=password]::-ms-reveal{display:none}.vega-input-container.compact-input-width{gap:0px}.vega-input-container.compact-input-width .vega-input-prefix{margin-right:8px}.vega-input-container.compact-input-width .prefix-text,.vega-input-container.compact-input-width .suffix-text{margin-right:2px}.vega-input-container.compact-input-width .vega-input-clear-icon{margin-left:2px}.vega-input-container.compact-input-width .vega-input-input input{padding:0px;min-width:1px}.vega-input-container.compact-input-width.auto-width .vega-input-input{flex-grow:0}.vega-input-container.compact-input-width.auto-width .suffix-text{flex-grow:1}.vega-input-container .prefix-text,.vega-input-container .suffix-text{font-family:"Inter", sans-serif;font-size:16px;font-weight:400;line-height:24px;letter-spacing:0px;color:rgba(var(--v-text-secondary, 107, 116, 125, 1));min-width:-webkit-min-content;min-width:-moz-min-content;min-width:min-content;flex-shrink:0;flex-grow:0}@media screen and (min-width: 768px) and (max-width: 1023px){.vega-input-container .prefix-text,.vega-input-container .suffix-text{font-family:"Inter", sans-serif;font-size:16px;font-weight:400;line-height:24px;letter-spacing:0px}}@media screen and (min-width: 1024px) and (max-width: 1439px){.vega-input-container .prefix-text,.vega-input-container .suffix-text{font-family:"Inter", sans-serif;font-size:16px;font-weight:400;line-height:24px;letter-spacing:0px}}@media screen and (min-width: 1440px) and (max-width: 9999px){.vega-input-container .prefix-text,.vega-input-container .suffix-text{font-family:"Inter", sans-serif;font-size:16px;font-weight:400;line-height:24px;letter-spacing:0px}}.v-font-field-value{font-family:"Inter", sans-serif;font-size:16px;font-weight:400;line-height:24px;letter-spacing:0px}@media screen and (min-width: 768px) and (max-width: 1023px){.v-font-field-value{font-family:"Inter", sans-serif;font-size:16px;font-weight:400;line-height:24px;letter-spacing:0px}}@media screen and (min-width: 1024px) and (max-width: 1439px){.v-font-field-value{font-family:"Inter", sans-serif;font-size:16px;font-weight:400;line-height:24px;letter-spacing:0px}}@media screen and (min-width: 1440px) and (max-width: 9999px){.v-font-field-value{font-family:"Inter", sans-serif;font-size:16px;font-weight:400;line-height:24px;letter-spacing:0px}}.vega-input-container .password-eye-button{width:16px;height:16px}.vega-input-container .password-eye-button::part(button){width:16px;height:16px;padding:0px}.vega-input-container .password-eye-button::part(button):hover{background-color:rgba(var(--v-bg-transparent, 0, 0, 0, 0))}@supports (-webkit-touch-callout: none){:host([data-vega-form=pageSelectorMobile_goTo]) .vega-input-container input{box-sizing:border-box;padding-left:0px;padding-right:0px}}';export{Rt as vega_input}
1
+ import{h as t,r as e,c as i,H as n,g as s}from"./p-6b2342e0.js";import{I as o}from"./p-abd7aeaa.js";import{M as a,a as r}from"./p-f0ff4463.js";import{M as l,a as p}from"./p-cdbbdcc2.js";import{R as c}from"./p-280cbcdb.js";import{s as h}from"./p-519a7d55.js";import{C as d}from"./p-75b58efe.js";import{c as u,V as f,M as g,I as v}from"./p-6e1ab235.js";import{s as x}from"./p-6bd5c49b.js";import{V as m,I as b}from"./p-d849e0f5.js";import{F as w}from"./p-6e136980.js";import{c as y}from"./p-66fa700b.js";import{D as C,a as j,d as k,w as I,V as S,g as R,F as z,G as E,H as O,I as D,J as T}from"./p-8d0ca805.js";import{S as V}from"./p-dd11f735.js";import{S as M}from"./p-badad9ed.js";import{i as N}from"./p-1f83cebf.js";import{S as F}from"./p-7288f8c4.js";import{i as L}from"./p-d27ae9ff.js";import{d as A}from"./p-bf19682d.js";import{m as P,n as $,o as B,j as _}from"./p-5b71c85e.js";import{P as U}from"./p-10ac8b57.js";import{S as W}from"./p-3bf66be2.js";import{a as K}from"./p-8c9ea6f4.js";import{c as H}from"./p-86194314.js";import{C as q}from"./p-2d0d575f.js";import{F as G}from"./p-a528714c.js";import{C as J}from"./p-8187878e.js";import"./p-262ec334.js";import"./p-02841589.js";import"./p-331a62d5.js";import"./p-d9671d27.js";import"./p-a4670e23.js";import"./p-6a334573.js";import"./p-f69f84a7.js";import"./p-78a57a17.js";import"./p-52b8f2d2.js";import"./p-fe12eff6.js";import"./p-b75ee3ba.js";import"./p-ed45b3b6.js";import"./p-40f39194.js";import"./p-d884c644.js";import"./p-aedf7146.js";import"./p-5d676a94.js";const X=/^(?:[a-z0-9!#$%&'*+/=?^_`{|}~-]+(?:\.[a-z0-9!#$%&'*+/=?^_`{|}~-]+)*|"(?:[\x01-\x08\x0b\x0c\x0e-\x1f\x21\x23-\x5b\x5d-\x7f]|\\[\x01-\x09\x0b\x0c\x0e-\x7f])*")@(?:(?:[a-z0-9](?:[a-z0-9-]*[a-z0-9])?\.)+[a-z0-9](?:[a-z0-9-]*[a-z0-9])?|\[(?:(?:25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\.){3}(?:25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?|[a-z0-9-]*[a-z0-9]:(?:[\x01-\x08\x0b\x0c\x0e-\x1f\x21-\x5a\x53-\x7f]|\\[\x01-\x09\x0b\x0c\x0e-\x7f])+)])$/;class Y extends o{evaluate(t){if(!this.isAcceptedInputType(t))throw new Error(`Unexpected type of input: ${typeof t}: ${t}`);const e=X.test(t.toLowerCase());return{isValid:e,message:e?"":"Please enter the correct email format."}}canEvaluate(t,e){return e?this.isAcceptedInputType(t)&&!e.disabled&&e.visible:this.isAcceptedInputType(t)}shouldShowError(t){return!t.disabled&&t.visible&&(t.touched||t.modified)}isAcceptedInputType(t){return"string"==typeof t&&t.length>0}}class Q extends f{getCopyPasteProps(){return this.disableCopyPaste?{onCopy:this.preventDefault,onCut:this.preventDefault,onPaste:this.preventDefault}:{}}preventDefault(t){t.preventDefault()}}!function(t,e,i,n){var s,o=arguments.length,a=o<3?e:null===n?n=Object.getOwnPropertyDescriptor(e,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(t,e,i,n);else for(var r=t.length-1;r>=0;r--)(s=t[r])&&(a=(o<3?s(a):o>3?s(e,i,a):s(e,i))||a);o>3&&a&&Object.defineProperty(e,i,a)}([u()],Q.prototype,"disableCopyPaste",void 0);var Z=function(t,e,i,n){var s,o=arguments.length,a=o<3?e:null===n?n=Object.getOwnPropertyDescriptor(e,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(t,e,i,n);else for(var r=t.length-1;r>=0;r--)(s=t[r])&&(a=(o<3?s(a):o>3?s(e,i,a):s(e,i))||a);return o>3&&a&&Object.defineProperty(e,i,a),a};class tt extends f{render(){const e=this.hasPrefixSlot();if(this.prefixIcon||e)return t("div",{class:{"vega-input-prefix":!0,"vega-input-prefix-slot":e},part:"prefix-icon-container"},this.prefixIcon&&!e?t("vega-icon",{icon:this.prefixIcon,size:"size-16"}):null,t("slot",{name:"prefix-icon"}))}hasPrefixSlot(){return!!this.host.querySelector('[slot="prefix-icon"]')}}Z([u()],tt.prototype,"host",void 0),Z([u()],tt.prototype,"prefixIcon",void 0);class et extends M{format(t){if(!t.length)return t;const e=Number(t.replace(/,/g,""));return!isNaN(e)&&e<=Number.MAX_SAFE_INTEGER?e.toLocaleString("en-US"):t}calculateCaretPosition(t,e){const i=this.format(t),n=t.substring(0,e),s=i.substring(0,e),o=(n.match(/,/g)||[]).length;return e+((s.match(/,/g)||[]).length-o)}}class it extends M{constructor(t){super(),this.maskConfig={allowNegative:!0},this.skipFormat=t=>this.maskConfig.allowNegative&&"-"===t||null!=this.maskConfig.precision&&this.maskConfig.precision>0&&t.split(".").length-1==1&&t.endsWith(".")&&!t.startsWith("."),this.maskConfig=Object.assign(Object.assign({},this.maskConfig),t),this.mask=new RegExp(this.getRegExp())}format(t){const e=this.redressAbnormalNumber(t);if(this.skipFormat(e))return e;const i=[...e];for(let t=e.length-1;t>=0;t--){const t=i.join("");this.inputNeedFormat(t)&&i.pop()}return i.join("")}calculateCaretPosition(t,e){if(N(e)){const i=this.redressAbnormalNumber(t);return e-(t.length-i.length)}}inputNeedFormat(t){return!this.mask.test(t)}redressAbnormalNumber(t){let e=t.replace(/^0+(?!$)/,"");return e.startsWith(".")&&(e=`0${e}`),e}getRegExp(){const t=this.maskConfig.allowNegative?"(\\-)?":"";let e;return e=0===this.maskConfig.precision?`^${t}(0|[1-9][0-9]*)$`:this.maskConfig.precision&&this.maskConfig.precision>0?`^${t}(0|0\\.\\d{1,${this.maskConfig.precision}}|[1-9][0-9]*(\\.\\d{1,${this.maskConfig.precision}})?)$`:`^${t}(0|0\\.\\d*|[1-9][0-9]*(\\.\\d*)?)$`,e}}class nt extends M{constructor(t,e=!1){super(),this.resetCaretPositionFlag=!1,this.formatter=t,this.resetCaretPositionFlag=e}format(t){return this.formatter(t)}calculateCaretPosition(t,e){if(!0===this.resetCaretPositionFlag)return this.format(t).length;if(N(e)){const i=t.substring(0,e);return e+(this.format(i).length-i.length)}}shouldTriggerAtInit(){return!0}}class st extends it{constructor(t){super(t)}format(t){const e=this.redressAbnormalNumber(t);if(this.skipFormat(e))return e;const i=[...e];for(let t=e.length-1;t>=0;t--){const t=i.join("");this.inputNeedFormat(t.replace(/,/g,""))&&i.pop()}return this.thousandCommaFormat(i.join(""))}calculateCaretPosition(t,e){const i=this.redressAbnormalNumber(t),n=this.format(t),s=t.substring(0,e),o=n.substring(0,e),a=(s.match(/,/g)||[]).length;return e+((o.match(/,/g)||[]).length-a)-(t.length-i.length)}thousandCommaFormat(t){if(!t.length)return t;const e=t.replace(/[^\d.-]/g,""),i=e.indexOf("."),n=e.length>1&&i>=1?e.slice(i):"",s=Number(e.split(".")[0]);return!isNaN(s)&&s<=Number.MAX_SAFE_INTEGER?s.toLocaleString("en-US")+n:e}}var ot=function(t,e,i,n){var s,o=arguments.length,a=o<3?e:null===n?n=Object.getOwnPropertyDescriptor(e,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(t,e,i,n);else for(var r=t.length-1;r>=0;r--)(s=t[r])&&(a=(o<3?s(a):o>3?s(e,i,a):s(e,i))||a);return o>3&&a&&Object.defineProperty(e,i,a),a};class at extends F{constructor(){super(...arguments),this.getInputElementRef=()=>this.inputRenderer.getInputRef(),this.getInputModeStrategy=()=>this.generateMaskStrategy("input"),this.getBlurModeStrategy=()=>this.generateMaskStrategy("blur")}connectedCallback(){this.initSetupMaskConfigObserver()}disconnectedCallback(){this.removeSetupMaskConfigObserver()}watchValue(t,e){t!==e&&this.formatValueAfterValueChange()}watchMaskChange(t,e){this.areMaskConfigsEqual(t,e)||this.setup()}watchTypeChange(t,e){"number"!==t&&"number"!==e||this.setup()}generateMaskStrategy(t){let e=null;Array.isArray(this.maskConfig)?e=this.maskConfig.find((e=>"blur"===t?this.isBlurModeMaskConfig(e):!this.isBlurModeMaskConfig(e))):this.maskConfig&&("blur"===t&&this.isBlurModeMaskConfig(this.maskConfig)?e=this.maskConfig:"input"!==t||this.isBlurModeMaskConfig(this.maskConfig)||(e=this.maskConfig));let i=null;switch(null==e?void 0:e.type){case"phone":i=V.PHONE_MASK;break;case"taxId":i=V.TAX_ID_MASK;break;case"zipcode":i=V.ZIPCODE_MASK;break;case"thousand-comma":i=new et;break;case"number":i=this.getNumberTypeMaskStrategy(e.options);break;case"custom":i=e.strategy?e.strategy():new V(e.options);break;case"custom-formatter":i=new nt(e.formatter,e.resetCaretPosition)}return"number"!==this.type||"input"!==t||e||(i=new it),i}getNumberTypeMaskStrategy(t){return t&&t.thousandComma?new st(t):new it(t)}isBlurModeMaskConfig(t){return"custom"===t.type&&"blur"===t.trigger}areMaskConfigsEqual(t,e){const i=Array.isArray(t)?t:[t],n=Array.isArray(e)?e:[e];return L(i,n,!0,((t,e)=>A(t,e)?0:-1))}initSetupMaskConfigObserver(){C.addUniqueObserverToNode(this.host,P,this.setup.bind(this))}removeSetupMaskConfigObserver(){C.removeUniqueObserverFromNode(this.host,P)}}ot([u()],at.prototype,"maskConfig",void 0),ot([u()],at.prototype,"disableCopyPaste",void 0),ot([u()],at.prototype,"type",void 0),ot([u()],at.prototype,"inputRenderer",void 0),ot([g("connectedCallback")],at.prototype,"connectedCallback",null),ot([g("disconnectedCallback")],at.prototype,"disconnectedCallback",null),ot([g("watchValue")],at.prototype,"watchValue",null),ot([g("watchMaskChange")],at.prototype,"watchMaskChange",null),ot([g("watchTypeChange")],at.prototype,"watchTypeChange",null);const rt=[{payloadKey:"AUTO_VALIDATION_IS_TRUE",payloadDescription:"Determines whether the input field should undergo automatic validation during the user's input",payloadValue:t=>!0===t.autoValidation},{payloadKey:"AUTO_VALIDATION_IS_FALSE",payloadDescription:"Determines whether the input field should undergo automatic validation during the user's input",payloadValue:t=>!1===t.autoValidation},{payloadKey:"EMAIL_IS_TRUE",payloadDescription:"@deprecated Enforces proper email format validation for the input field.",payloadValue:t=>!0===t.email},{payloadKey:"EMAIL_IS_FALSE",payloadDescription:"@deprecated Enforces proper email format validation for the input field.",payloadValue:t=>!1===t.email}];var lt=function(t,e,i,n){var s,o=arguments.length,a=o<3?e:null===n?n=Object.getOwnPropertyDescriptor(e,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(t,e,i,n);else for(var r=t.length-1;r>=0;r--)(s=t[r])&&(a=(o<3?s(a):o>3?s(e,i,a):s(e,i))||a);return o>3&&a&&Object.defineProperty(e,i,a),a};class pt extends f{componentDidLoad(){this.setInputAutoWidth()}watchValue(){this.setInputAutoWidth()}watchSuffixText(){this.setInputAutoWidth()}setInputAutoWidth(){const t=this.host.shadowRoot.querySelector(".vega-input-container"),e=null==t?void 0:t.querySelector(".vega-input-input"),i=null==e?void 0:e.querySelector("input");if(i&&(t.classList.remove("auto-width"),i.style.removeProperty("width"),this.isCompactInputWidth&&this.suffixText)){const n=this.getActualInputWidth();e.getBoundingClientRect().width>n&&(i.style.width=`${n}px`,t.classList.add("auto-width"))}}getActualInputWidth(){const t=this.getCalculateTextWidthContainer();t.style.display="inline-block",t.textContent=`${this.value||this.placeholder||""}`;const e=t.getBoundingClientRect().width;return t.style.display="none",e}getCalculateTextWidthContainer(){if(!this.calculateTextWidthContainer){const t=document.createElement("div");t.classList.add("v-font-field-value"),t.style.visibility="hidden",t.style.display="none",this.host.shadowRoot.append(t),this.calculateTextWidthContainer=t}return this.calculateTextWidthContainer}}lt([u()],pt.prototype,"host",void 0),lt([u()],pt.prototype,"value",void 0),lt([u()],pt.prototype,"placeholder",void 0),lt([u()],pt.prototype,"isCompactInputWidth",void 0),lt([u()],pt.prototype,"suffixText",void 0),lt([g("componentDidLoad")],pt.prototype,"componentDidLoad",null),lt([g("watchValue")],pt.prototype,"watchValue",null),lt([g("watchSuffixText")],pt.prototype,"watchSuffixText",null);var ct=function(t,e,i,n){var s,o=arguments.length,a=o<3?e:null===n?n=Object.getOwnPropertyDescriptor(e,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(t,e,i,n);else for(var r=t.length-1;r>=0;r--)(s=t[r])&&(a=(o<3?s(a):o>3?s(e,i,a):s(e,i))||a);return o>3&&a&&Object.defineProperty(e,i,a),a};class ht extends W{constructor(){super({parent:"vega-input-numeric",subStates:[{subStateName:"prefixText",parentStateName:"prefixText"},{subStateName:"suffixText",parentStateName:"suffixText"},{subStateName:"isCompactInputWidth",parentStateName:"isCompactInputWidth"}]})}}ct([u()],ht.prototype,"host",void 0),ct([u({writable:!0})],ht.prototype,"prefixText",void 0),ct([u({writable:!0})],ht.prototype,"suffixText",void 0),ct([u({writable:!0})],ht.prototype,"isCompactInputWidth",void 0);var dt=function(t,e,i,n){var s,o=arguments.length,a=o<3?e:null===n?n=Object.getOwnPropertyDescriptor(e,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(t,e,i,n);else for(var r=t.length-1;r>=0;r--)(s=t[r])&&(a=(o<3?s(a):o>3?s(e,i,a):s(e,i))||a);return o>3&&a&&Object.defineProperty(e,i,a),a};class ut extends f{render(){return t("vega-button-circle",{icon:K.getIconKey(this.isPasswordDisplay?"eye":"eye-slash"),variant:"icon-only",size:"small",class:"password-eye-button",ref:t=>{this.addEyeIconObserver(t)}})}addEyeIconObserver(t){C.addUniqueObserverToNode(t,j,(()=>{this.isPasswordDisplay=!this.isPasswordDisplay}))}}K.register({eye:{icon:'<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 576 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="M288 32c-80.8 0-145.5 36.8-192.6 80.6C48.6 156 17.3 208 2.5 243.7c-3.3 7.9-3.3 16.7 0 24.6C17.3 304 48.6 356 95.4 399.4C142.5 443.2 207.2 480 288 480s145.5-36.8 192.6-80.6c46.8-43.5 78.1-95.4 93-131.1c3.3-7.9 3.3-16.7 0-24.6c-14.9-35.7-46.2-87.7-93-131.1C433.5 68.8 368.8 32 288 32zM144 256a144 144 0 1 1 288 0 144 144 0 1 1 -288 0zm144-64c0 35.3-28.7 64-64 64c-7.1 0-13.9-1.2-20.3-3.3c-5.5-1.8-11.9 1.6-11.7 7.4c.3 6.9 1.3 13.8 3.2 20.7c13.7 51.2 66.4 81.6 117.6 67.9s81.6-66.4 67.9-117.6c-11.1-41.5-47.8-69.4-88.6-71.1c-5.8-.2-9.2 6.1-7.4 11.7c2.1 6.4 3.3 13.2 3.3 20.3z"/></svg>'},"eye-slash":{icon:'<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 640 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="M38.8 5.1C28.4-3.1 13.3-1.2 5.1 9.2S-1.2 34.7 9.2 42.9l592 464c10.4 8.2 25.5 6.3 33.7-4.1s6.3-25.5-4.1-33.7L525.6 386.7c39.6-40.6 66.4-86.1 79.9-118.4c3.3-7.9 3.3-16.7 0-24.6c-14.9-35.7-46.2-87.7-93-131.1C465.5 68.8 400.8 32 320 32c-68.2 0-125 26.3-169.3 60.8L38.8 5.1zM223.1 149.5C248.6 126.2 282.7 112 320 112c79.5 0 144 64.5 144 144c0 24.9-6.3 48.3-17.4 68.7L408 294.5c8.4-19.3 10.6-41.4 4.8-63.3c-11.1-41.5-47.8-69.4-88.6-71.1c-5.8-.2-9.2 6.1-7.4 11.7c2.1 6.4 3.3 13.2 3.3 20.3c0 10.2-2.4 19.8-6.6 28.3l-90.3-70.8zM373 389.9c-16.4 6.5-34.3 10.1-53 10.1c-79.5 0-144-64.5-144-144c0-6.9 .5-13.6 1.4-20.2L83.1 161.5C60.3 191.2 44 220.8 34.5 243.7c-3.3 7.9-3.3 16.7 0 24.6c14.9 35.7 46.2 87.7 93 131.1C174.5 443.2 239.2 480 320 480c47.8 0 89.9-12.9 126.2-32.5L373 389.9z"/></svg>'}}),dt([u()],ut.prototype,"host",void 0),dt([u({writable:!0})],ut.prototype,"isPasswordDisplay",void 0),dt([u()],ut.prototype,"type",void 0);var ft=function(t,e,i,n){var s,o=arguments.length,a=o<3?e:null===n?n=Object.getOwnPropertyDescriptor(e,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(t,e,i,n);else for(var r=t.length-1;r>=0;r--)(s=t[r])&&(a=(o<3?s(a):o>3?s(e,i,a):s(e,i))||a);return o>3&&a&&Object.defineProperty(e,i,a),a};class gt extends f{constructor(){super(...arguments),this.renderPrefixText=()=>this.prefixText&&t("div",{class:"prefix-text"},this.prefixText),this.renderSuffixText=()=>this.suffixText&&t("div",{class:"suffix-text"},this.suffixText),this.onClickClearIcon=()=>{q.notify(k.getSubject(this.host,$),"")},this.isClearIconVisible=()=>!this.disabled&&Boolean(this.value),this.onClearInputFocus=()=>{this.inputContainerRef.classList.add("no-focus")},this.onClearInputBlur=()=>{this.inputContainerRef.classList.remove("no-focus")},this.onContainerClick=()=>{q.notify(k.getSubject(this.host,B),{})}}getInputContainerRef(){return this.inputContainerRef}render(){return t("div",{ref:t=>this.inputContainerRef=t,part:"input-container",class:{"vega-input-container":!0,"with-value":!!this.value,[`vega-input-size-${this.size}`]:!0,"vega-input-disabled":this.disabled,"compact-input-width":this.isCompactInputWidth},onClick:this.onContainerClick,"aria-label":"input container","aria-disabled":`${this.disabled}`,role:"textbox",tabIndex:this.disabled?null:-1,onKeyDown:H()},this.prefixSlotRenderer.render(),this.renderPrefixText(),this.inputRenderer.render(),this.renderSuffixText(),"password"===this.type?this.passwordEyeRenderer.render():this.showClearIcon&&this.renderClearIcon())}renderClearIcon(){return t("div",{class:{"vega-input-clear-icon":!0,invisible:!this.isClearIconVisible()},tabIndex:this.disabled?-1:0,"aria-label":"clear input",role:"button",onClick:this.onClickClearIcon,onKeyDown:H(),onFocusin:this.onClearInputFocus,onFocusout:this.onClearInputBlur},t("vega-icon",{icon:"close"}))}}ft([u()],gt.prototype,"host",void 0),ft([u()],gt.prototype,"value",void 0),ft([u()],gt.prototype,"size",void 0),ft([u()],gt.prototype,"disabled",void 0),ft([u()],gt.prototype,"type",void 0),ft([u()],gt.prototype,"showClearIcon",void 0),ft([u()],gt.prototype,"prefixText",void 0),ft([u()],gt.prototype,"suffixText",void 0),ft([u()],gt.prototype,"isCompactInputWidth",void 0),ft([u()],gt.prototype,"prefixSlotRenderer",void 0),ft([u()],gt.prototype,"passwordEyeRenderer",void 0),ft([u()],gt.prototype,"inputRenderer",void 0);var vt=function(t,e,i,n){var s,o=arguments.length,a=o<3?e:null===n?n=Object.getOwnPropertyDescriptor(e,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(t,e,i,n);else for(var r=t.length-1;r>=0;r--)(s=t[r])&&(a=(o<3?s(a):o>3?s(e,i,a):s(e,i))||a);return o>3&&a&&Object.defineProperty(e,i,a),a};class xt extends f{constructor(){super(...arguments),this.setInputRef=t=>{t&&this.inputRef!==t&&(this.inputRef=t,this.notifySetupMaskConfig())},this.handleInputFocus=t=>{this.focusEventEmitter.emit(void 0,t)},this.handleInputBlur=t=>{this.blurEventEmitter.emit(void 0,t)},this.handleInputPaste=t=>{this.pasteEventEmitter.emit(t.clipboardData).defaultPrevented&&t.preventDefault()},this.onInputHandler=()=>{"change"!==this.valueUpdateTrigger&&this.notifyInputValueChange()},this.inputChangeHandler=()=>{"change"===this.valueUpdateTrigger&&this.notifyInputValueChange()}}connectedCallback(){this.initInputFocusObserver()}disconnectedCallback(){this.removeInputFocusObserver()}doFocus(){this.focusInput()}doBlur(){this.inputRef.blur()}getInputRef(){return this.inputRef}render(){return t("div",{class:"vega-input-input"},t("input",Object.assign({part:"input",name:this.name,type:this.getInputType(),autoComplete:this.autocomplete,inputmode:this.inputmode,value:this.value,ref:this.setInputRef,placeholder:this.placeholder,disabled:this.disabled,"aria-label":this.label||"No label defined",minLength:this.minLength,maxLength:this.maxLength,onBlur:t=>this.handleInputBlur(t),onFocus:t=>this.handleInputFocus(t),onChange:this.inputChangeHandler,onInput:this.onInputHandler,onPaste:t=>this.handleInputPaste(t)},this.copyPasteController.getCopyPasteProps())))}getInputType(){switch(this.type){case"number":return"text";case"password":return this.isPasswordDisplay?"text":"password";default:return this.type}}notifyInputValueChange(){this.inputRef.value!==this.value&&this.nativeInputChangeEventEmitter.emit(this.inputRef.value),q.notify(k.getSubject(this.host,$),this.inputRef.value)}notifySetupMaskConfig(){q.notify(k.getSubject(this.host,P),{})}initInputFocusObserver(){C.addUniqueObserverToNode(this.host,B,this.focusInput.bind(this))}removeInputFocusObserver(){C.removeUniqueObserverFromNode(this.host,B)}focusInput(){this.inputRef.focus()}}vt([u()],xt.prototype,"host",void 0),vt([u()],xt.prototype,"value",void 0),vt([u()],xt.prototype,"disabled",void 0),vt([u()],xt.prototype,"type",void 0),vt([u()],xt.prototype,"label",void 0),vt([u()],xt.prototype,"name",void 0),vt([u()],xt.prototype,"autocomplete",void 0),vt([u()],xt.prototype,"inputmode",void 0),vt([u()],xt.prototype,"placeholder",void 0),vt([u()],xt.prototype,"minLength",void 0),vt([u()],xt.prototype,"maxLength",void 0),vt([u()],xt.prototype,"isPasswordDisplay",void 0),vt([u()],xt.prototype,"valueUpdateTrigger",void 0),vt([u()],xt.prototype,"focusEventEmitter",void 0),vt([u()],xt.prototype,"blurEventEmitter",void 0),vt([u()],xt.prototype,"pasteEventEmitter",void 0),vt([u()],xt.prototype,"copyPasteController",void 0),vt([u()],xt.prototype,"nativeInputChangeEventEmitter",void 0),vt([g("connectedCallback")],xt.prototype,"connectedCallback",null),vt([g("disconnectedCallback")],xt.prototype,"disconnectedCallback",null),vt([g("doFocus")],xt.prototype,"doFocus",null),vt([g("doBlur")],xt.prototype,"doBlur",null);var mt=function(t,e,i,n){var s,o=arguments.length,a=o<3?e:null===n?n=Object.getOwnPropertyDescriptor(e,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(t,e,i,n);else for(var r=t.length-1;r>=0;r--)(s=t[r])&&(a=(o<3?s(a):o>3?s(e,i,a):s(e,i))||a);return o>3&&a&&Object.defineProperty(e,i,a),a};class bt extends f{constructor(){super(...arguments),this.handleLabelButtonClick=()=>{this.labelButtonClickEventEmitter.emit()},this.handleLabelClick=()=>{q.notify(k.getSubject(this.host,B),{})}}render(){return t("div",{class:"vega-input",part:"container-wrapper"},this.renderLabelDom(),this.renderInputContainer(),this.renderHintDom())}renderInputContainer(){return this.renderModeController.isSource()||this.renderModeController.isTemplate()?this.inputSuggestionsRenderer.render(this.inputContainerRenderer.render()):this.inputContainerRenderer.render()}renderLabelDom(){return t("vega-field-label",{"is-field-required":this.required,disabled:this.disabled,label:this.label,suffixButtonProps:this.labelSuffixButtonProps,suffixButtonConfig:this.labelSuffixButtonConfig,ref:t=>{C.addUniqueObserverToNode(t,I,this.handleLabelButtonClick),C.addUniqueObserverToNode(t,j,this.handleLabelClick)}})}renderHintDom(){return""!==this.hint?t("div",{class:"vega-hint"},t("label",null,this.hint)):null}}mt([u()],bt.prototype,"host",void 0),mt([u()],bt.prototype,"disabled",void 0),mt([u()],bt.prototype,"required",void 0),mt([u()],bt.prototype,"label",void 0),mt([u()],bt.prototype,"hint",void 0),mt([u()],bt.prototype,"labelSuffixButtonProps",void 0),mt([u()],bt.prototype,"labelSuffixButtonConfig",void 0),mt([u()],bt.prototype,"labelButtonClickEventEmitter",void 0),mt([u()],bt.prototype,"inputContainerRenderer",void 0),mt([u()],bt.prototype,"inputSuggestionsRenderer",void 0),mt([u()],bt.prototype,"renderModeController",void 0);var wt=function(t,e,i,n){var s,o=arguments.length,a=o<3?e:null===n?n=Object.getOwnPropertyDescriptor(e,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(t,e,i,n);else for(var r=t.length-1;r>=0;r--)(s=t[r])&&(a=(o<3?s(a):o>3?s(e,i,a):s(e,i))||a);return o>3&&a&&Object.defineProperty(e,i,a),a};class yt extends f{connectedCallback(){this.initValueUpdateObserver()}disconnectedCallback(){this.removeValueUpdateObserver()}watchValue(t){this.changeEventEmitter.emit(t);const e=this.inputRenderer.getInputRef();e.value!==this.value&&(e.value=this.value),q.notify(G,{host:this.host,detail:this.value})}initValueUpdateObserver(){C.addUniqueObserverToNode(this.host,$,this.setValue.bind(this))}removeValueUpdateObserver(){C.removeUniqueObserverFromNode(this.host,$)}setValue(t){this.value=t}}wt([u()],yt.prototype,"host",void 0),wt([u({writable:!0})],yt.prototype,"value",void 0),wt([u()],yt.prototype,"changeEventEmitter",void 0),wt([u()],yt.prototype,"inputRenderer",void 0),wt([g("connectedCallback")],yt.prototype,"connectedCallback",null),wt([g("disconnectedCallback")],yt.prototype,"disconnectedCallback",null),wt([g("watchValue")],yt.prototype,"watchValue",null);var Ct=function(t,e,i,n){var s,o=arguments.length,a=o<3?e:null===n?n=Object.getOwnPropertyDescriptor(e,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(t,e,i,n);else for(var r=t.length-1;r>=0;r--)(s=t[r])&&(a=(o<3?s(a):o>3?s(e,i,a):s(e,i))||a);return o>3&&a&&Object.defineProperty(e,i,a),a};class jt extends f{constructor(){super(...arguments),this.templateItems=[],this.onDropdownItemClick=async t=>{const e=this.renderModeController.isTemplate()?this.templateItems:this.suggestionsDropdownSource,i=this.findItem(e,t.detail);if(i){const t=this.suggestionItemClickEventEmitter.emit(i);q.notify(k.getSubject(this.host,$),t.defaultPrevented?this.value:i.label)}}}appendHostItemsToDropdown(){this.renderModeController.isTemplate()&&this.itemsSlotRef&&this.dropdownRef&&(this.itemsSlotRef.remove(),this.dropdownRef.append(this.host.querySelector("[slot=items]")))}async showSuggestionsDropdown(t={}){this.suggestionsDropdownConfig=t,await this.showSuggestions()}async hideSuggestionsDropdown(){await this.dropdownRef.hide()}async watchValue(){await this.searchSuggestions()}async watchSuggestionsDropdownSource(){await this.searchSuggestions()}render(e){return t("vega-dropdown",Object.assign({},this.suggestionsDropdownConfig,{source:this.suggestionsDropdownSource,trigger:new J,matchTargetWidth:!0,searchable:!1,placement:["top","bottom"],translocation:{X:0,Y:6},ref:t=>{this.dropdownRef=t,this.addDropdownObserver(t)},style:{display:"block"}}),e,this.renderItemsSlot())}renderItemsSlot(){return this.renderModeController.isTemplate()&&t("div",{slot:"items",ref:t=>{this.itemsSlotRef=t}})}addDropdownObserver(t){C.addUniqueObserverToNode(t,S,this.onDropdownItemClick.bind(this)),C.addUniqueObserverToNode(t,_,(t=>{this.templateItems=Array.from(t).map((t=>({key:t.itemKey,label:t.label})))}))}findItem(t,e){for(const i of t){if(i.children&&i.children.length>0){const t=this.findItem(i.children,e);if(t)return t}if(i.key.toString()===e)return i}return null}async showSuggestions(){(this.renderModeController.isSource()||this.renderModeController.isTemplate())&&await this.dropdownRef.show()}async searchSuggestions(){this.renderModeController.isSource()&&this.suggestionsDropdownSource.length>0&&await this.dropdownRef.search(this.value)}}Ct([u()],jt.prototype,"host",void 0),Ct([u()],jt.prototype,"value",void 0),Ct([u({writable:!0})],jt.prototype,"suggestionsDropdownConfig",void 0),Ct([u()],jt.prototype,"suggestionsDropdownSource",void 0),Ct([u()],jt.prototype,"renderModeController",void 0),Ct([u()],jt.prototype,"suggestionItemClickEventEmitter",void 0),Ct([g("componentDidLoad")],jt.prototype,"appendHostItemsToDropdown",null),Ct([g("showSuggestionsDropdown")],jt.prototype,"showSuggestionsDropdown",null),Ct([g("hideSuggestionsDropdown")],jt.prototype,"hideSuggestionsDropdown",null),Ct([g("watchValue")],jt.prototype,"watchValue",null),Ct([g("watchSuggestionsDropdownSource")],jt.prototype,"watchSuggestionsDropdownSource",null);var kt=function(t,e,i,n){var s,o=arguments.length,a=o<3?e:null===n?n=Object.getOwnPropertyDescriptor(e,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(t,e,i,n);else for(var r=t.length-1;r>=0;r--)(s=t[r])&&(a=(o<3?s(a):o>3?s(e,i,a):s(e,i))||a);return o>3&&a&&Object.defineProperty(e,i,a),a};class It extends f{constructor(){super(...arguments),this.hasItemsSlot=!1,this.hasDropdownSource=!1}connectedCallback(){this.setRenderMode()}isSource(){return this.hasDropdownSource}isTemplate(){return this.hasItemsSlot}setRenderMode(){this.hasItemsSlot=!!this.host.querySelector("[slot=items]"),this.hasDropdownSource=Array.isArray(this.suggestionsDropdownSource)}}kt([u()],It.prototype,"host",void 0),kt([u()],It.prototype,"suggestionsDropdownSource",void 0),kt([g("connectedCallback")],It.prototype,"connectedCallback",null);var St=function(t,e,i,n){var s,o=arguments.length,a=o<3?e:null===n?n=Object.getOwnPropertyDescriptor(e,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(t,e,i,n);else for(var r=t.length-1;r>=0;r--)(s=t[r])&&(a=(o<3?s(a):o>3?s(e,i,a):s(e,i))||a);return o>3&&a&&Object.defineProperty(e,i,a),a};const Rt=class{constructor(t){e(this,t),this.vegaChange=i(this,"vegaChange",7),this.change=i(this,"change",7),this.vegaNativeInputChange=i(this,"vegaNativeInputChange",7),this.nativeInputChange=i(this,"nativeInputChange",7),this.vegaBlur=i(this,"vegaBlur",7),this.blur=i(this,"blur",7),this.vegaFocus=i(this,"vegaFocus",7),this.focus=i(this,"focus",7),this.vegaLabelButtonClick=i(this,"vegaLabelButtonClick",7),this.labelButtonClick=i(this,"labelButtonClick",7),this.vegaPaste=i(this,"vegaPaste",7),this.paste=i(this,"paste",7),this.vegaSuggestionItemClick=i(this,"vegaSuggestionItemClick",7),this.suggestionItemClick=i(this,"suggestionItemClick",7),this.globalSlimmers={},this.formFieldController=new w({propertyRules:[{propertyName:"required",ruleFactory:t=>t?new c:null},{propertyName:"min",ruleFactory:t=>"number"==typeof t?new a({minValue:t}):null},{propertyName:"max",ruleFactory:t=>"number"==typeof t?new r({maxValue:t}):null},{propertyName:"minLength",ruleFactory:t=>t?new l({minStrLength:t}):null},{propertyName:"maxLength",ruleFactory:t=>t?new p({maxStrLength:t}):null},{propertyName:"email",ruleFactory:t=>t?new Y:null},{propertyName:"type",ruleFactory:t=>"email"===t?new Y:null}],validationRulesName:"validationRules",defaultValue:"",attributeGetter:t=>this[t],inputContainerGetter:()=>this.inputContainerRenderer.getInputContainerRef(),touchableAreaGetter:()=>[this.inputRenderer.getInputRef()]}),this.pageResizeObserverSlimmer=new U({callback:()=>this.compactWidthController.setInputAutoWidth()}),this.renderModeController=new It,this.copyPasteController=new Q,this.compactWidthController=new pt,this.stateController=new ht,this.maskConfigController=new at,this.valueController=new yt,this.prefixSlotRenderer=new tt,this.renderer=new bt,this.inputContainerRenderer=new gt,this.inputRenderer=new xt,this.inputSuggestionsRenderer=new jt,this.changeEventEmitter=y(Rt,R),this.nativeInputChangeEventEmitter=y(Rt,z),this.focusEventEmitter=y(Rt,E),this.blurEventEmitter=y(Rt,O),this.labelButtonClickEventEmitter=y(Rt,I),this.suggestionItemClickEventEmitter=y(Rt,D),this.pasteEventEmitter=y(Rt,T),this.vegaComponentUsageRuntimeMetricsSlimmer=new m(rt),this.passwordEyeRenderer=new ut,this.label="",this.labelSuffixButtonProps=null,this.labelSuffixButtonConfig=null,this.value="",this.valueUpdateTrigger="input",this.type="text",this.name="",this.autocomplete="off",this.email=!1,this.required=!1,this.min=null,this.max=null,this.minLength=null,this.maxLength=null,this.showClearIcon=!0,this.isValid=null,this.autoValidation=!0,this.validationRules=[],this.size="default",this.disabled=!1,this.hint="",this.disableCopyPaste=!1}watchSuffixText(){}watchValue(t){}watchTypeChange(t,e){}watchValidationRules(){}watchMaskChange(t,e){}watchSuggestionsDropdownSource(){}async doFocus(){}async doBlur(){}async showSuggestionsDropdown(t){}async hideSuggestionsDropdown(){}render(){return x(t("slot",null)),h(t(n,{class:"hidden"===this.type?"vega-input-hidden":"vega-input-inline-block"},this.renderer.render()),this.host)}get host(){return s(this)}static get watchers(){return{suffixText:["watchSuffixText"],value:["watchValue"],type:["watchTypeChange"],validationRules:["watchValidationRules"],maskConfig:["watchMaskChange"],suggestionsDropdownSource:["watchSuggestionsDropdownSource"]}}};St([b()],Rt.prototype,"globalSlimmers",void 0),St([v()],Rt.prototype,"formFieldController",void 0),St([v()],Rt.prototype,"pageResizeObserverSlimmer",void 0),St([v()],Rt.prototype,"renderModeController",void 0),St([v()],Rt.prototype,"copyPasteController",void 0),St([v()],Rt.prototype,"compactWidthController",void 0),St([v()],Rt.prototype,"stateController",void 0),St([v()],Rt.prototype,"maskConfigController",void 0),St([v()],Rt.prototype,"valueController",void 0),St([v()],Rt.prototype,"prefixSlotRenderer",void 0),St([v()],Rt.prototype,"renderer",void 0),St([v()],Rt.prototype,"inputContainerRenderer",void 0),St([v()],Rt.prototype,"inputRenderer",void 0),St([v()],Rt.prototype,"inputSuggestionsRenderer",void 0),St([v()],Rt.prototype,"changeEventEmitter",void 0),St([v()],Rt.prototype,"nativeInputChangeEventEmitter",void 0),St([v()],Rt.prototype,"focusEventEmitter",void 0),St([v()],Rt.prototype,"blurEventEmitter",void 0),St([v()],Rt.prototype,"labelButtonClickEventEmitter",void 0),St([v()],Rt.prototype,"suggestionItemClickEventEmitter",void 0),St([v()],Rt.prototype,"pasteEventEmitter",void 0),St([v()],Rt.prototype,"vegaComponentUsageRuntimeMetricsSlimmer",void 0),St([v()],Rt.prototype,"passwordEyeRenderer",void 0),St([d()],Rt.prototype,"watchMaskChange",null),Rt.style=':host{cursor:text;display:block;text-align:left;line-height:normal}:host(.vega-input-inline-block){display:inline-block;width:100%}:host(.vega-input-hidden){display:none}vega-field-label{margin-bottom:8px}.vega-input-container{display:flex;align-items:center;border-radius:8px;gap:8px;background-color:rgba(var(--v-bg-primary, 252, 252, 252, 1));border:1px solid rgba(var(--v-border-input-field, 171, 198, 216, 1))}.vega-input-container:hover{border:1px solid rgba(var(--v-border-input-field-hover, 115, 160, 190, 1))}.vega-input-container.vega-input-disabled{background-color:rgba(var(--v-bg-secondary, 245, 247, 247, 1));border:1px solid rgba(var(--v-border-input-field-disabled, 222, 225, 227, 1))}.vega-input-container.vega-input-disabled:hover{border:1px solid rgba(var(--v-border-input-field-disabled, 222, 225, 227, 1))}.vega-input-container.vega-input-disabled input{color:rgba(var(--v-text-input-disabled, 107, 116, 125, 1))}.vega-input-container.with-value{border-width:1px;border-style:solid;border-radius:8px}.vega-input-container:not(.no-focus):focus-within{outline:2px solid rgba(var(--v-border-color-action, 19, 98, 226, 1));outline-offset:3px;border:1px solid rgba(var(--v-border-color-input-field-focus, 19, 98, 226, 1))}.vega-input-container.error{border:1px solid rgba(var(--v-border-input-field-danger, 230, 50, 87, 1))}.vega-input-container.error:hover{border:1px solid rgba(var(--v-border-input-field-danger-hover, 255, 87, 114, 1))}.vega-input-container.error:not(.no-focus):focus-within{outline:2px solid rgba(var(--v-border-color-danger, 230, 50, 87, 1));outline-offset:3px;border:1px solid rgba(var(--v-border-color-input-field-danger-focus, 233, 71, 104, 1))}.vega-input-container.error .vega-input-clear-icon:focus-within{outline:2px solid rgba(var(--v-border-color-danger, 230, 50, 87, 1));outline-offset:2px}.vega-input-prefix{text-align:center;color:rgba(var(--v-text-secondary, 107, 116, 125, 1));font-size:0px}.vega-input-prefix.vega-input-prefix-slot{height:24px;overflow:hidden}.vega-input-input{flex:1 1 0%;position:relative}.vega-input-input input{width:100%;outline:2px solid transparent;outline-offset:2px;border-style:none;height:24px;box-sizing:border-box;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;font-family:"Inter", sans-serif;font-size:16px;font-weight:400;line-height:24px;letter-spacing:0px;color:rgba(var(--v-text-primary, 32, 54, 69, 1));background-color:rgba(var(--v-bg-primary, 252, 252, 252, 1))}@media screen and (min-width: 768px) and (max-width: 1023px){.vega-input-input input{font-family:"Inter", sans-serif;font-size:16px;font-weight:400;line-height:24px;letter-spacing:0px}}@media screen and (min-width: 1024px) and (max-width: 1439px){.vega-input-input input{font-family:"Inter", sans-serif;font-size:16px;font-weight:400;line-height:24px;letter-spacing:0px}}@media screen and (min-width: 1440px) and (max-width: 9999px){.vega-input-input input{font-family:"Inter", sans-serif;font-size:16px;font-weight:400;line-height:24px;letter-spacing:0px}}.vega-input-input input::placeholder{color:rgba(var(--v-text-input-placeholder, 176, 180, 181, 1))}.vega-input-size-small{padding-top:8px;padding-right:12px;padding-bottom:8px;padding-left:12px}.vega-input-size-default{padding-top:12px;padding-right:16px;padding-bottom:12px;padding-left:16px}.vega-input-input input:disabled{background-color:rgba(var(--v-bg-secondary, 245, 247, 247, 1))}.vega-hint{padding-top:12px;padding-right:8px;padding-left:8px}.vega-hint>label{font-family:"Inter", sans-serif;font-size:14px;font-weight:400;line-height:18px;letter-spacing:0px;color:rgba(var(--v-text-secondary, 107, 116, 125, 1))}@media screen and (min-width: 768px) and (max-width: 1023px){.vega-hint>label{font-family:"Inter", sans-serif;font-size:14px;font-weight:400;line-height:18px;letter-spacing:0px}}@media screen and (min-width: 1024px) and (max-width: 1439px){.vega-hint>label{font-family:"Inter", sans-serif;font-size:14px;font-weight:400;line-height:18px;letter-spacing:0px}}@media screen and (min-width: 1440px) and (max-width: 9999px){.vega-hint>label{font-family:"Inter", sans-serif;font-size:14px;font-weight:400;line-height:18px;letter-spacing:0px}}.vega-error{font-family:"Inter", sans-serif;font-size:14px;font-weight:400;line-height:18px;letter-spacing:0px;color:rgba(var(--v-text-error, 189, 41, 71, 1));display:block;padding-top:12px;padding-right:8px;padding-left:8px}@media screen and (min-width: 768px) and (max-width: 1023px){.vega-error{font-family:"Inter", sans-serif;font-size:14px;font-weight:400;line-height:18px;letter-spacing:0px}}@media screen and (min-width: 1024px) and (max-width: 1439px){.vega-error{font-family:"Inter", sans-serif;font-size:14px;font-weight:400;line-height:18px;letter-spacing:0px}}@media screen and (min-width: 1440px) and (max-width: 9999px){.vega-error{font-family:"Inter", sans-serif;font-size:14px;font-weight:400;line-height:18px;letter-spacing:0px}}.vega-hidden{display:none}.vega-input-clear-icon{width:16px;height:16px;cursor:pointer;color:rgba(var(--v-text-secondary, 107, 116, 125, 1))}.vega-input-clear-icon:focus-within{outline:2px solid rgba(var(--v-border-color-action, 19, 98, 226, 1));outline-offset:2px;border-radius:4px;padding:2px}.vega-input-clear-icon.invisible{visibility:hidden}.vega-input-clear-icon vega-icon{min-width:-webkit-min-content;min-width:-moz-min-content;min-width:min-content;flex-shrink:0}input[type=number]::-webkit-outer-spin-button,input[type=number]::-webkit-inner-spin-button{-webkit-appearance:none;margin:0}input[type=number]{-moz-appearance:textfield}input[type=password]::-ms-reveal{display:none}.vega-input-container.compact-input-width{gap:0px}.vega-input-container.compact-input-width .vega-input-prefix{margin-right:8px}.vega-input-container.compact-input-width .prefix-text,.vega-input-container.compact-input-width .suffix-text{margin-right:2px}.vega-input-container.compact-input-width .vega-input-clear-icon{margin-left:2px}.vega-input-container.compact-input-width .vega-input-input input{padding:0px;min-width:1px}.vega-input-container.compact-input-width.auto-width .vega-input-input{flex-grow:0}.vega-input-container.compact-input-width.auto-width .suffix-text{flex-grow:1}.vega-input-container .prefix-text,.vega-input-container .suffix-text{font-family:"Inter", sans-serif;font-size:16px;font-weight:400;line-height:24px;letter-spacing:0px;color:rgba(var(--v-text-secondary, 107, 116, 125, 1));min-width:-webkit-min-content;min-width:-moz-min-content;min-width:min-content;flex-shrink:0;flex-grow:0}@media screen and (min-width: 768px) and (max-width: 1023px){.vega-input-container .prefix-text,.vega-input-container .suffix-text{font-family:"Inter", sans-serif;font-size:16px;font-weight:400;line-height:24px;letter-spacing:0px}}@media screen and (min-width: 1024px) and (max-width: 1439px){.vega-input-container .prefix-text,.vega-input-container .suffix-text{font-family:"Inter", sans-serif;font-size:16px;font-weight:400;line-height:24px;letter-spacing:0px}}@media screen and (min-width: 1440px) and (max-width: 9999px){.vega-input-container .prefix-text,.vega-input-container .suffix-text{font-family:"Inter", sans-serif;font-size:16px;font-weight:400;line-height:24px;letter-spacing:0px}}.v-font-field-value{font-family:"Inter", sans-serif;font-size:16px;font-weight:400;line-height:24px;letter-spacing:0px}@media screen and (min-width: 768px) and (max-width: 1023px){.v-font-field-value{font-family:"Inter", sans-serif;font-size:16px;font-weight:400;line-height:24px;letter-spacing:0px}}@media screen and (min-width: 1024px) and (max-width: 1439px){.v-font-field-value{font-family:"Inter", sans-serif;font-size:16px;font-weight:400;line-height:24px;letter-spacing:0px}}@media screen and (min-width: 1440px) and (max-width: 9999px){.v-font-field-value{font-family:"Inter", sans-serif;font-size:16px;font-weight:400;line-height:24px;letter-spacing:0px}}.vega-input-container .password-eye-button{width:16px;height:16px}.vega-input-container .password-eye-button::part(button){width:16px;height:16px;padding:0px}.vega-input-container .password-eye-button::part(button):hover{background-color:rgba(var(--v-bg-transparent, 0, 0, 0, 0))}@supports (-webkit-touch-callout: none){:host([data-vega-form=pageSelectorMobile_goTo]) .vega-input-container input{box-sizing:border-box;padding-left:0px;padding-right:0px}}';export{Rt as vega_input}