@heartlandone/vega 2.63.1 → 2.64.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (351) hide show
  1. package/dist/cjs/{app-globals-2d0b157e.js → app-globals-a190cd2d.js} +9 -9
  2. package/dist/cjs/{brand-switch-state-controller-slimmer-b83a4596.js → brand-switch-state-controller-slimmer-5efa1b24.js} +1 -1
  3. package/dist/cjs/{code-block-cc740807.js → code-block-417a131b.js} +11 -15
  4. package/dist/cjs/{component-value-history-controller-slimmer.abstract-0bb81172.js → component-value-history-controller-slimmer.abstract-0c4d1453.js} +3 -3
  5. package/dist/cjs/{dark-mode-state-controller-slimmer-17022f93.js → dark-mode-state-controller-slimmer-add5d8a8.js} +1 -1
  6. package/dist/cjs/{dark-mode-style-controller-b1e9ec82.js → dark-mode-style-controller-41c94aac.js} +1 -1
  7. package/dist/cjs/{design-token-bf913c86.js → design-token-ae0de304.js} +1 -1
  8. package/dist/cjs/{dto-renderer-manager-424c5031.js → dto-renderer-manager-6d338e46.js} +9 -4
  9. package/dist/cjs/{element-appender-slimmer-1d035b1f.js → element-appender-slimmer-5a23e722.js} +4 -4
  10. package/dist/cjs/{form-field-controller-slimmer-cc6e53a4.js → form-field-controller-slimmer-cceb5c79.js} +4 -4
  11. package/dist/cjs/{image-annotation-action-f831e09b.js → image-annotation-action-9785bc59.js} +4 -4
  12. package/dist/cjs/{index-00ba6623.js → index-58ea899e.js} +1 -0
  13. package/dist/cjs/{index-5505e8dd.js → index-9a92abce.js} +1 -1
  14. package/dist/cjs/index.cjs.js +13 -13
  15. package/dist/cjs/{language-extension-cfe0eabd.js → language-extension-abbc251a.js} +2 -2
  16. package/dist/cjs/loader.cjs.js +12 -12
  17. package/dist/cjs/{public-rules-7e9b633d.js → public-rules-ffc5db13.js} +6 -6
  18. package/dist/cjs/{range-44f08955.js → range-37161c00.js} +1 -1
  19. package/dist/cjs/{responsive-format-facade-a7fbefc4.js → responsive-format-facade-b20dad44.js} +4 -4
  20. package/dist/cjs/{rich-text-editor-required-rule-a0618c85.js → rich-text-editor-required-rule-604ea2b9.js} +1 -1
  21. package/dist/cjs/{static-subject-title-85732e0f.js → static-subject-title-7e7d791a.js} +0 -2
  22. package/dist/cjs/{string-input-formatter-slimmer-f6c7a255.js → string-input-formatter-slimmer-8445abc9.js} +2 -2
  23. package/dist/cjs/{style-formatter-795451f2.js → style-formatter-56751462.js} +1 -1
  24. package/dist/cjs/{sub-state-notify-slimmer-bb64fcfc.js → sub-state-notify-slimmer-52fa23af.js} +1 -1
  25. package/dist/cjs/{sub-state-observer-slimmer-84175d61.js → sub-state-observer-slimmer-90c26113.js} +1 -1
  26. package/dist/cjs/{token-extension-4764d5f3.js → token-extension-46821c19.js} +3 -3
  27. package/dist/cjs/{translation-cde4dce3.js → translation-ecfc704a.js} +1 -1
  28. package/dist/cjs/{translation-slimmer-af399096.js → translation-slimmer-40a3536d.js} +1 -1
  29. package/dist/cjs/vega-accordion.cjs.entry.js +10 -10
  30. package/dist/cjs/vega-app-footer.cjs.entry.js +4 -4
  31. package/dist/cjs/vega-app-header-button.cjs.entry.js +10 -10
  32. package/dist/cjs/vega-backdrop.cjs.entry.js +1 -1
  33. package/dist/cjs/vega-banner.cjs.entry.js +1 -1
  34. package/dist/cjs/vega-bar-chart.cjs.entry.js +1 -1
  35. package/dist/cjs/vega-box.cjs.entry.js +11 -11
  36. package/dist/cjs/vega-brand-logo.cjs.entry.js +4 -4
  37. package/dist/cjs/vega-breadcrumb.cjs.entry.js +1 -1
  38. package/dist/cjs/vega-button-circle.cjs.entry.js +10 -10
  39. package/dist/cjs/vega-button-group_2.cjs.entry.js +4 -4
  40. package/dist/cjs/vega-button-link.cjs.entry.js +1 -1
  41. package/dist/cjs/vega-button.cjs.entry.js +9 -9
  42. package/dist/cjs/vega-calendar_4.cjs.entry.js +29 -21
  43. package/dist/cjs/vega-card.cjs.entry.js +10 -10
  44. package/dist/cjs/vega-carousel.cjs.entry.js +9 -9
  45. package/dist/cjs/vega-checkbox_2.cjs.entry.js +6 -6
  46. package/dist/cjs/vega-chip.cjs.entry.js +10 -10
  47. package/dist/cjs/vega-code-block.cjs.entry.js +9 -9
  48. package/dist/cjs/vega-color-picker.cjs.entry.js +6 -6
  49. package/dist/cjs/vega-combo-box.cjs.entry.js +6 -6
  50. package/dist/cjs/vega-counter-badge.cjs.entry.js +1 -1
  51. package/dist/cjs/vega-date-picker_2.cjs.entry.js +15 -15
  52. package/dist/cjs/vega-dialog_2.cjs.entry.js +10 -10
  53. package/dist/cjs/vega-divider.cjs.entry.js +10 -10
  54. package/dist/cjs/vega-dropdown_5.cjs.entry.js +13 -13
  55. package/dist/cjs/vega-env-manager-23b8b23c.js +2 -2
  56. package/dist/cjs/vega-field-error.cjs.entry.js +2 -2
  57. package/dist/cjs/vega-field-label.cjs.entry.js +1 -1
  58. package/dist/cjs/vega-file-uploader.cjs.entry.js +7 -7
  59. package/dist/cjs/vega-flag-icon.cjs.entry.js +10 -10
  60. package/dist/cjs/vega-flex.cjs.entry.js +11 -11
  61. package/dist/cjs/vega-font.cjs.entry.js +10 -10
  62. package/dist/cjs/vega-form.cjs.entry.js +90 -16
  63. package/dist/cjs/vega-grid.cjs.entry.js +10 -10
  64. package/dist/cjs/vega-hint.cjs.entry.js +1 -1
  65. package/dist/cjs/vega-icon.cjs.entry.js +10 -10
  66. package/dist/cjs/vega-image-uploader.cjs.entry.js +13 -13
  67. package/dist/cjs/vega-input-credit-card.cjs.entry.js +6 -6
  68. package/dist/cjs/vega-input-numeric.cjs.entry.js +7 -7
  69. package/dist/cjs/vega-input-phone-number.cjs.entry.js +10 -10
  70. package/dist/cjs/vega-input-range.cjs.entry.js +7 -7
  71. package/dist/cjs/vega-input-select.cjs.entry.js +12 -12
  72. package/dist/cjs/vega-input.cjs.entry.js +8 -8
  73. package/dist/cjs/{vega-internal-event-id-9647aaf8.js → vega-internal-event-id-dfd8b802.js} +2 -0
  74. package/dist/cjs/vega-item-toggle.cjs.entry.js +1 -1
  75. package/dist/cjs/vega-left-nav_5.cjs.entry.js +13 -13
  76. package/dist/cjs/vega-line-chart.cjs.entry.js +1 -1
  77. package/dist/cjs/vega-loader-wrapper_2.cjs.entry.js +9 -9
  78. package/dist/cjs/vega-page-notification_2.cjs.entry.js +1 -1
  79. package/dist/cjs/vega-pagination-page-selector-mobile.cjs.entry.js +2 -2
  80. package/dist/cjs/vega-pagination-page-size-selector-mobile.cjs.entry.js +5 -5
  81. package/dist/cjs/vega-pagination.cjs.entry.js +10 -10
  82. package/dist/cjs/vega-pie-chart.cjs.entry.js +1 -1
  83. package/dist/cjs/vega-popover_2.cjs.entry.js +11 -11
  84. package/dist/cjs/vega-progress-tracker.cjs.entry.js +1 -1
  85. package/dist/cjs/vega-radio_2.cjs.entry.js +6 -6
  86. package/dist/cjs/vega-rich-text-content.cjs.entry.js +9 -9
  87. package/dist/cjs/vega-rich-text-editor_4.cjs.entry.js +18 -22
  88. package/dist/cjs/vega-section-title.cjs.entry.js +1 -1
  89. package/dist/cjs/vega-segment-control.cjs.entry.js +1 -1
  90. package/dist/cjs/vega-selection-chip_2.cjs.entry.js +12 -12
  91. package/dist/cjs/vega-selection-tile_2.cjs.entry.js +7 -7
  92. package/dist/cjs/vega-sidenav_3.cjs.entry.js +11 -11
  93. package/dist/cjs/vega-signature-capture.cjs.entry.js +13 -13
  94. package/dist/cjs/vega-skeleton.cjs.entry.js +1 -1
  95. package/dist/cjs/vega-slot-container.cjs.entry.js +1 -1
  96. package/dist/cjs/vega-stepper.cjs.entry.js +6 -6
  97. package/dist/cjs/vega-tab-group_2.cjs.entry.js +2 -2
  98. package/dist/cjs/vega-table_8.cjs.entry.js +12 -12
  99. package/dist/cjs/vega-text.cjs.entry.js +1 -1
  100. package/dist/cjs/vega-textarea.cjs.entry.js +6 -6
  101. package/dist/cjs/vega-time-picker_2.cjs.entry.js +13 -13
  102. package/dist/cjs/vega-toggle-switch.cjs.entry.js +6 -6
  103. package/dist/cjs/vega-tooltip_2.cjs.entry.js +10 -10
  104. package/dist/cjs/vega.cjs.js +12 -12
  105. package/dist/collection/components/vega-calendar/slimmers/common/renderers/vega-calendar-event-preview-popover-renderer.js +7 -6
  106. package/dist/collection/components/vega-calendar/slimmers/month-view/renderers/vega-calendar-month-event-renderer.js +6 -7
  107. package/dist/collection/components/vega-calendar/vega-calendar-event-preview/slimmers/renderers/vega-calendar-event-preview-detail-renderer.js +15 -5
  108. package/dist/collection/components/vega-form/slimmers/renderers/native-form-renderer.js +30 -0
  109. package/dist/collection/components/vega-form/vega-form.js +111 -3
  110. package/dist/collection/components/vega-rich-text-editor/dto/annotations/link-annotation.js +1 -1
  111. package/dist/collection/components/vega-rich-text-editor/dto/annotations/link-group-annotation.js +5 -7
  112. package/dist/collection/components/vega-rich-text-editor/dto/blocks/text-block.js +3 -5
  113. package/dist/collection/components/vega-rich-text-editor/dto/content-state.js +7 -2
  114. package/dist/collection/components/vega-rich-text-editor/slimmers/renderers/vega-rich-text-editor-renderer.js +1 -5
  115. package/dist/collection/components/vega-rich-text-editor/test/dto/annotations.test.js +9 -1
  116. package/dist/collection/components/vega-rich-text-editor/test/dto/blocks/text-block.test.js +1 -1
  117. package/dist/collection/components/vega-rich-text-editor/test/dto/content-state.test.js +51 -40
  118. package/dist/collection/helpers/change-manager/subject/static-subject/static-subject-title.js +0 -1
  119. package/dist/collection/helpers/event-manager/event-id/vega-internal-event-id.js +1 -0
  120. package/dist/esm/{app-globals-2623304e.js → app-globals-b074e012.js} +9 -9
  121. package/dist/esm/{brand-switch-state-controller-slimmer-d6e4d217.js → brand-switch-state-controller-slimmer-05c85e6d.js} +1 -1
  122. package/dist/esm/{code-block-23e7f8d0.js → code-block-a6c78bbb.js} +11 -15
  123. package/dist/esm/{component-value-history-controller-slimmer.abstract-df25e4a1.js → component-value-history-controller-slimmer.abstract-d37d2df7.js} +3 -3
  124. package/dist/esm/{dark-mode-state-controller-slimmer-0c7d1c77.js → dark-mode-state-controller-slimmer-f1c2c299.js} +1 -1
  125. package/dist/esm/{dark-mode-style-controller-972e1f06.js → dark-mode-style-controller-5cf1c482.js} +1 -1
  126. package/dist/esm/{design-token-0f439510.js → design-token-6f9e70c4.js} +1 -1
  127. package/dist/esm/{dto-renderer-manager-65b7b1b1.js → dto-renderer-manager-5b036e47.js} +9 -4
  128. package/dist/esm/{element-appender-slimmer-bf5ca501.js → element-appender-slimmer-1d6c2960.js} +4 -4
  129. package/dist/esm/{form-field-controller-slimmer-f7e8845b.js → form-field-controller-slimmer-c29b345f.js} +4 -4
  130. package/dist/esm/{image-annotation-action-af21ea8f.js → image-annotation-action-f6308cf4.js} +4 -4
  131. package/dist/esm/{index-057d0f70.js → index-090d31ca.js} +1 -0
  132. package/dist/esm/{index-7fe93427.js → index-4f26bbd0.js} +1 -1
  133. package/dist/esm/index.js +13 -13
  134. package/dist/esm/{language-extension-d355f9aa.js → language-extension-962c427a.js} +2 -2
  135. package/dist/esm/loader.js +12 -12
  136. package/dist/esm/{public-rules-1a5da7bf.js → public-rules-6fa7533f.js} +6 -6
  137. package/dist/esm/{range-fac2962c.js → range-4d7aa0fd.js} +1 -1
  138. package/dist/esm/{responsive-format-facade-2904b456.js → responsive-format-facade-b594fc72.js} +4 -4
  139. package/dist/esm/{rich-text-editor-required-rule-bb94d680.js → rich-text-editor-required-rule-a72374cd.js} +1 -1
  140. package/dist/esm/{static-subject-title-633b3474.js → static-subject-title-ca83d6b6.js} +1 -2
  141. package/dist/esm/{string-input-formatter-slimmer-69117deb.js → string-input-formatter-slimmer-75256a17.js} +2 -2
  142. package/dist/esm/{style-formatter-a724e38d.js → style-formatter-56074ede.js} +1 -1
  143. package/dist/esm/{sub-state-notify-slimmer-4252a90e.js → sub-state-notify-slimmer-85c658b7.js} +1 -1
  144. package/dist/esm/{sub-state-observer-slimmer-baa8853a.js → sub-state-observer-slimmer-e58a2485.js} +1 -1
  145. package/dist/esm/{token-extension-89eeef74.js → token-extension-3c198013.js} +3 -3
  146. package/dist/esm/{translation-833d9ef4.js → translation-3d35961b.js} +1 -1
  147. package/dist/esm/{translation-slimmer-c83b52c1.js → translation-slimmer-d5b0d292.js} +1 -1
  148. package/dist/esm/vega-accordion.entry.js +10 -10
  149. package/dist/esm/vega-app-footer.entry.js +4 -4
  150. package/dist/esm/vega-app-header-button.entry.js +10 -10
  151. package/dist/esm/vega-backdrop.entry.js +1 -1
  152. package/dist/esm/vega-banner.entry.js +1 -1
  153. package/dist/esm/vega-bar-chart.entry.js +1 -1
  154. package/dist/esm/vega-box.entry.js +11 -11
  155. package/dist/esm/vega-brand-logo.entry.js +4 -4
  156. package/dist/esm/vega-breadcrumb.entry.js +1 -1
  157. package/dist/esm/vega-button-circle.entry.js +10 -10
  158. package/dist/esm/vega-button-group_2.entry.js +4 -4
  159. package/dist/esm/vega-button-link.entry.js +1 -1
  160. package/dist/esm/vega-button.entry.js +9 -9
  161. package/dist/esm/vega-calendar_4.entry.js +30 -22
  162. package/dist/esm/vega-card.entry.js +10 -10
  163. package/dist/esm/vega-carousel.entry.js +9 -9
  164. package/dist/esm/vega-checkbox_2.entry.js +6 -6
  165. package/dist/esm/vega-chip.entry.js +10 -10
  166. package/dist/esm/vega-code-block.entry.js +9 -9
  167. package/dist/esm/vega-color-picker.entry.js +6 -6
  168. package/dist/esm/vega-combo-box.entry.js +6 -6
  169. package/dist/esm/vega-counter-badge.entry.js +1 -1
  170. package/dist/esm/vega-date-picker_2.entry.js +15 -15
  171. package/dist/esm/vega-dialog_2.entry.js +10 -10
  172. package/dist/esm/vega-divider.entry.js +10 -10
  173. package/dist/esm/vega-dropdown_5.entry.js +13 -13
  174. package/dist/esm/vega-env-manager-8f8dc473.js +2 -2
  175. package/dist/esm/vega-field-error.entry.js +2 -2
  176. package/dist/esm/vega-field-label.entry.js +1 -1
  177. package/dist/esm/vega-file-uploader.entry.js +7 -7
  178. package/dist/esm/vega-flag-icon.entry.js +10 -10
  179. package/dist/esm/vega-flex.entry.js +11 -11
  180. package/dist/esm/vega-font.entry.js +10 -10
  181. package/dist/esm/vega-form.entry.js +90 -16
  182. package/dist/esm/vega-grid.entry.js +10 -10
  183. package/dist/esm/vega-hint.entry.js +1 -1
  184. package/dist/esm/vega-icon.entry.js +10 -10
  185. package/dist/esm/vega-image-uploader.entry.js +13 -13
  186. package/dist/esm/vega-input-credit-card.entry.js +6 -6
  187. package/dist/esm/vega-input-numeric.entry.js +7 -7
  188. package/dist/esm/vega-input-phone-number.entry.js +10 -10
  189. package/dist/esm/vega-input-range.entry.js +7 -7
  190. package/dist/esm/vega-input-select.entry.js +12 -12
  191. package/dist/esm/vega-input.entry.js +8 -8
  192. package/dist/esm/{vega-internal-event-id-5a143cd2.js → vega-internal-event-id-bee7946b.js} +2 -1
  193. package/dist/esm/vega-item-toggle.entry.js +1 -1
  194. package/dist/esm/vega-left-nav_5.entry.js +13 -13
  195. package/dist/esm/vega-line-chart.entry.js +1 -1
  196. package/dist/esm/vega-loader-wrapper_2.entry.js +9 -9
  197. package/dist/esm/vega-page-notification_2.entry.js +1 -1
  198. package/dist/esm/vega-pagination-page-selector-mobile.entry.js +2 -2
  199. package/dist/esm/vega-pagination-page-size-selector-mobile.entry.js +5 -5
  200. package/dist/esm/vega-pagination.entry.js +10 -10
  201. package/dist/esm/vega-pie-chart.entry.js +1 -1
  202. package/dist/esm/vega-popover_2.entry.js +11 -11
  203. package/dist/esm/vega-progress-tracker.entry.js +1 -1
  204. package/dist/esm/vega-radio_2.entry.js +6 -6
  205. package/dist/esm/vega-rich-text-content.entry.js +9 -9
  206. package/dist/esm/vega-rich-text-editor_4.entry.js +18 -22
  207. package/dist/esm/vega-section-title.entry.js +1 -1
  208. package/dist/esm/vega-segment-control.entry.js +1 -1
  209. package/dist/esm/vega-selection-chip_2.entry.js +12 -12
  210. package/dist/esm/vega-selection-tile_2.entry.js +7 -7
  211. package/dist/esm/vega-sidenav_3.entry.js +11 -11
  212. package/dist/esm/vega-signature-capture.entry.js +13 -13
  213. package/dist/esm/vega-skeleton.entry.js +1 -1
  214. package/dist/esm/vega-slot-container.entry.js +1 -1
  215. package/dist/esm/vega-stepper.entry.js +6 -6
  216. package/dist/esm/vega-tab-group_2.entry.js +2 -2
  217. package/dist/esm/vega-table_8.entry.js +12 -12
  218. package/dist/esm/vega-text.entry.js +1 -1
  219. package/dist/esm/vega-textarea.entry.js +6 -6
  220. package/dist/esm/vega-time-picker_2.entry.js +13 -13
  221. package/dist/esm/vega-toggle-switch.entry.js +6 -6
  222. package/dist/esm/vega-tooltip_2.entry.js +10 -10
  223. package/dist/esm/vega.js +12 -12
  224. package/dist/types/components/vega-calendar/vega-calendar-event-preview/slimmers/renderers/vega-calendar-event-preview-detail-renderer.d.ts +3 -0
  225. package/dist/types/components/vega-form/slimmers/renderers/native-form-renderer.d.ts +12 -0
  226. package/dist/types/components/vega-form/vega-form.d.ts +35 -0
  227. package/dist/types/components/vega-rich-text-editor/dto/annotations/link-group-annotation.d.ts +0 -1
  228. package/dist/types/components/vega-rich-text-editor/dto/blocks/text-block.d.ts +1 -2
  229. package/dist/types/components/vega-rich-text-editor/dto/content-state.d.ts +2 -1
  230. package/dist/types/components.d.ts +30 -0
  231. package/dist/types/helpers/change-manager/subject/static-subject/static-subject-title.d.ts +1 -2
  232. package/dist/types/helpers/event-manager/event-id/vega-internal-event-id.d.ts +1 -0
  233. package/dist/vega/index.esm.js +1 -1
  234. package/dist/vega/{p-81765b4b.entry.js → p-04158119.entry.js} +1 -1
  235. package/dist/vega/{p-66199d68.js → p-06b624e6.js} +1 -1
  236. package/dist/vega/p-06e6be0e.js +1 -0
  237. package/dist/vega/{p-476cc642.entry.js → p-0b38a01f.entry.js} +1 -1
  238. package/dist/vega/p-0b92b15b.entry.js +1 -0
  239. package/dist/vega/{p-5e4fb663.entry.js → p-0bb3be0b.entry.js} +1 -1
  240. package/dist/vega/{p-c61f8ca6.entry.js → p-0f2c83a1.entry.js} +1 -1
  241. package/dist/vega/{p-427b2b55.entry.js → p-1110b422.entry.js} +1 -1
  242. package/dist/vega/{p-5397648b.entry.js → p-119430db.entry.js} +1 -1
  243. package/dist/vega/{p-6585cfd5.entry.js → p-15766433.entry.js} +1 -1
  244. package/dist/vega/{p-320cccc5.entry.js → p-159fda34.entry.js} +1 -1
  245. package/dist/vega/{p-0ec14fbc.entry.js → p-1655b920.entry.js} +1 -1
  246. package/dist/vega/{p-25c831a4.entry.js → p-179693f1.entry.js} +1 -1
  247. package/dist/vega/p-1aba48bc.js +1 -0
  248. package/dist/vega/{p-4f21faf1.js → p-1be68fba.js} +1 -1
  249. package/dist/vega/{p-e0729c4d.entry.js → p-1cb87bad.entry.js} +1 -1
  250. package/dist/vega/{p-6180c1af.entry.js → p-1d3a7be6.entry.js} +1 -1
  251. package/dist/vega/{p-5313d0bc.js → p-2044aa2c.js} +1 -1
  252. package/dist/vega/{p-2591f217.entry.js → p-21a480b0.entry.js} +1 -1
  253. package/dist/vega/{p-614e450a.entry.js → p-3176804b.entry.js} +1 -1
  254. package/dist/vega/{p-648134d2.entry.js → p-32058dbd.entry.js} +1 -1
  255. package/dist/vega/{p-5970369e.entry.js → p-32655cfc.entry.js} +1 -1
  256. package/dist/vega/{p-c2377afa.js → p-3354f5a7.js} +1 -1
  257. package/dist/vega/p-3355ec0f.js +1 -0
  258. package/dist/vega/{p-02b29c18.js → p-3674db0f.js} +1 -1
  259. package/dist/vega/p-36f331bf.entry.js +1 -0
  260. package/dist/vega/p-3709b0e0.js +1 -0
  261. package/dist/vega/{p-e513f041.js → p-37fd7a80.js} +1 -1
  262. package/dist/vega/{p-0717073b.entry.js → p-3a0b9e66.entry.js} +1 -1
  263. package/dist/vega/{p-dcae53cf.entry.js → p-3a455ac3.entry.js} +1 -1
  264. package/dist/vega/{p-7cd2fac8.entry.js → p-3a9aa6eb.entry.js} +1 -1
  265. package/dist/vega/{p-89d2cf34.js → p-3af81271.js} +1 -1
  266. package/dist/vega/{p-b110b7bd.entry.js → p-3eaa6cce.entry.js} +1 -1
  267. package/dist/vega/{p-40924882.entry.js → p-4082fa22.entry.js} +1 -1
  268. package/dist/vega/{p-9b2d8516.entry.js → p-459efe39.entry.js} +1 -1
  269. package/dist/vega/p-465a6660.entry.js +1 -0
  270. package/dist/vega/{p-2a1b3108.entry.js → p-4669ce11.entry.js} +1 -1
  271. package/dist/vega/{p-3ab20f9e.entry.js → p-4ae3eebf.entry.js} +1 -1
  272. package/dist/vega/{p-8a484812.entry.js → p-4b57bb12.entry.js} +1 -1
  273. package/dist/vega/{p-cc5a3a1b.entry.js → p-4dd6554e.entry.js} +1 -1
  274. package/dist/vega/p-4e503e23.entry.js +1 -0
  275. package/dist/vega/{p-2f88ba36.entry.js → p-4faa7bab.entry.js} +1 -1
  276. package/dist/vega/{p-9c309b85.entry.js → p-52b0abb5.entry.js} +1 -1
  277. package/dist/vega/{p-6244b0ad.entry.js → p-5443d614.entry.js} +1 -1
  278. package/dist/vega/{p-f92fc49b.entry.js → p-55c26035.entry.js} +1 -1
  279. package/dist/vega/{p-76c7538a.entry.js → p-56b8ffd5.entry.js} +1 -1
  280. package/dist/vega/p-5773a9a3.js +1 -0
  281. package/dist/vega/{p-de1ee131.entry.js → p-57c42c30.entry.js} +1 -1
  282. package/dist/vega/{p-57257de0.entry.js → p-5910be31.entry.js} +1 -1
  283. package/dist/vega/p-5f377954.js +1 -1
  284. package/dist/vega/p-6163818f.js +1 -0
  285. package/dist/vega/{p-09cb98f3.entry.js → p-61966868.entry.js} +1 -1
  286. package/dist/vega/p-641fbb48.entry.js +1 -0
  287. package/dist/vega/{p-7bad6577.entry.js → p-64e949fa.entry.js} +1 -1
  288. package/dist/vega/{p-2d58cf34.entry.js → p-684391a4.entry.js} +1 -1
  289. package/dist/vega/{p-ab29f968.js → p-697acd40.js} +1 -1
  290. package/dist/vega/p-6be16084.js +1 -0
  291. package/dist/vega/{p-b6c51409.entry.js → p-6c85c1f3.entry.js} +1 -1
  292. package/dist/vega/{p-56ff8559.entry.js → p-6ed663d5.entry.js} +1 -1
  293. package/dist/vega/{p-3be7bfee.entry.js → p-7aae9252.entry.js} +1 -1
  294. package/dist/vega/{p-b32f7aac.entry.js → p-7c75ce6c.entry.js} +1 -1
  295. package/dist/vega/{p-d87c3058.entry.js → p-84eabbec.entry.js} +1 -1
  296. package/dist/vega/{p-02a4732a.js → p-8938b5c4.js} +1 -1
  297. package/dist/vega/{p-846ae5fb.js → p-904d1b43.js} +1 -1
  298. package/dist/vega/{p-20223e8e.entry.js → p-92ec4fac.entry.js} +1 -1
  299. package/dist/vega/{p-b4d88fce.entry.js → p-956a5899.entry.js} +1 -1
  300. package/dist/vega/{p-0e954b9b.js → p-96bda7ca.js} +1 -1
  301. package/dist/vega/{p-bc0ae89a.entry.js → p-9819dda9.entry.js} +1 -1
  302. package/dist/vega/{p-942fc9b9.js → p-a1cf29a9.js} +1 -1
  303. package/dist/vega/{p-bdd9ef3b.js → p-a30ebdf5.js} +1 -1
  304. package/dist/vega/{p-c7726252.js → p-a3d77013.js} +1 -1
  305. package/dist/vega/{p-cfb2af9c.entry.js → p-a9e3058e.entry.js} +1 -1
  306. package/dist/vega/{p-8175d8de.entry.js → p-ad2055f4.entry.js} +1 -1
  307. package/dist/vega/{p-460429da.entry.js → p-ae963cb3.entry.js} +1 -1
  308. package/dist/vega/{p-92469fa1.entry.js → p-b3cd1992.entry.js} +1 -1
  309. package/dist/vega/{p-da6369d4.entry.js → p-b9e8c6bf.entry.js} +1 -1
  310. package/dist/vega/{p-351405f2.entry.js → p-bb58a7cf.entry.js} +1 -1
  311. package/dist/vega/{p-bb61f015.js → p-be539a54.js} +1 -1
  312. package/dist/vega/{p-589b7ea3.entry.js → p-bf8d2978.entry.js} +1 -1
  313. package/dist/vega/{p-dadc6ab3.js → p-c7f68d74.js} +1 -1
  314. package/dist/vega/p-c8789df1.entry.js +1 -0
  315. package/dist/vega/p-d20ab09f.entry.js +1 -0
  316. package/dist/vega/{p-bf0ced3c.js → p-d3bf55e9.js} +1 -1
  317. package/dist/vega/{p-26ef2066.entry.js → p-db29b9f9.entry.js} +1 -1
  318. package/dist/vega/{p-e74c275a.entry.js → p-df31307b.entry.js} +1 -1
  319. package/dist/vega/{p-4c3075ef.js → p-e27802fb.js} +1 -1
  320. package/dist/vega/{p-134ed822.entry.js → p-e41931d4.entry.js} +1 -1
  321. package/dist/vega/{p-3fba9e77.entry.js → p-e4acac0a.entry.js} +1 -1
  322. package/dist/vega/{p-d15e70d7.entry.js → p-e4b0606a.entry.js} +1 -1
  323. package/dist/vega/{p-36ae2dd3.entry.js → p-e5af5a4d.entry.js} +1 -1
  324. package/dist/vega/{p-10454aa5.entry.js → p-e6158a33.entry.js} +1 -1
  325. package/dist/vega/{p-d72abacd.entry.js → p-e9b86dac.entry.js} +1 -1
  326. package/dist/vega/{p-969066d3.entry.js → p-eb5f99db.entry.js} +1 -1
  327. package/dist/vega/{p-d85b0bfa.entry.js → p-ed0f000b.entry.js} +1 -1
  328. package/dist/vega/p-f37558c1.js +1 -0
  329. package/dist/vega/{p-81fbf18f.entry.js → p-f4877bee.entry.js} +1 -1
  330. package/dist/vega/{p-64c281ec.entry.js → p-f81f2071.entry.js} +1 -1
  331. package/dist/vega/{p-4f5a2b0c.entry.js → p-fd2d02ea.entry.js} +1 -1
  332. package/dist/vega/{p-0bc93777.entry.js → p-ffc2ef90.entry.js} +1 -1
  333. package/dist/vega/{p-b73532c0.entry.js → p-fff13ed1.entry.js} +1 -1
  334. package/dist/vega/vega.esm.js +1 -1
  335. package/package.json +1 -1
  336. package/dist/vega/p-079f5d94.entry.js +0 -1
  337. package/dist/vega/p-0b36f4ce.js +0 -1
  338. package/dist/vega/p-0e3cd270.entry.js +0 -1
  339. package/dist/vega/p-258f9603.js +0 -1
  340. package/dist/vega/p-2b90fae6.js +0 -1
  341. package/dist/vega/p-51d40b0d.entry.js +0 -1
  342. package/dist/vega/p-521ace2d.js +0 -1
  343. package/dist/vega/p-657446a3.entry.js +0 -1
  344. package/dist/vega/p-6908117a.js +0 -1
  345. package/dist/vega/p-893d5dfa.js +0 -1
  346. package/dist/vega/p-8a6b820a.entry.js +0 -1
  347. package/dist/vega/p-8a877e12.js +0 -1
  348. package/dist/vega/p-9ffd2a96.entry.js +0 -1
  349. package/dist/vega/p-b1054e18.entry.js +0 -1
  350. package/dist/vega/p-e5cd6521.js +0 -1
  351. /package/dist/vega/{p-48a58baf.js → p-6b2342e0.js} +0 -0
@@ -1 +0,0 @@
1
- import{h as e,F as t,f as i,r as n,c as r,H as o,g as a}from"./p-48a58baf.js";import{s}from"./p-519a7d55.js";import{c as l,V as d,M as c,L as h,I as v}from"./p-6e1ab235.js";import{V as p,I as f}from"./p-d849e0f5.js";import{D as w,a as u,f as m,V as g,Q as b,d as x,g as y,h as k,i as C,j as R}from"./p-2ee4def0.js";import{a as j}from"./p-8c9ea6f4.js";import{c as D}from"./p-86194314.js";import{p as E}from"./p-08835909.js";import{c as z}from"./p-3cdbee7e.js";import{V as O}from"./p-bf0ced3c.js";import{s as M}from"./p-824a06ba.js";import{q as P}from"./p-b1faebe0.js";import{C as S}from"./p-1da54ff3.js";import{w as I,x as $,y as T}from"./p-0e954b9b.js";import{O as V}from"./p-331a62d5.js";import{C as L}from"./p-2d0d575f.js";import{m as B}from"./p-8a877e12.js";import{f as A}from"./p-d27ae9ff.js";import{g as N}from"./p-a4670e23.js";import{P as F}from"./p-7d9cd9c8.js";import{d as W}from"./p-1bc5b3bc.js";import{c as H}from"./p-bb61f015.js";import{T as _}from"./p-02b29c18.js";import{s as U}from"./p-6bd5c49b.js";import{v as Y}from"./p-54ae02db.js";import{S as K}from"./p-bdd9ef3b.js";import{b as q}from"./p-0c667d6a.js";import"./p-575235c8.js";import"./p-6a334573.js";import"./p-f1436035.js";import"./p-b75ee3ba.js";import"./p-ed45b3b6.js";import"./p-74168615.js";import"./p-d884c644.js";import"./p-5f377954.js";import"./p-e77a83e4.js";import"./p-db8cdba6.js";import"./p-112455b1.js";import"./p-262ec334.js";var X=function(e,t,i,n){var r,o=arguments.length,a=o<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,i,n);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,i,a):r(t,i))||a);return o>3&&a&&Object.defineProperty(t,i,a),a};class Z extends d{getEventPreviewRef(){return this.eventPreviewRef}render(){return e(t,null,this.switchPanelRenderer.render(),this.viewRenderer.render(),e("vega-calendar-event-preview",{ref:e=>{this.eventPreviewRef=e}}))}}X([l()],Z.prototype,"host",void 0),X([l()],Z.prototype,"switchPanelRenderer",void 0),X([l()],Z.prototype,"viewRenderer",void 0);var G=function(e,t,i,n){var r,o=arguments.length,a=o<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,i,n);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,i,a):r(t,i))||a);return o>3&&a&&Object.defineProperty(t,i,a),a};class Q extends d{constructor(){super(...arguments),this.handleViewChange=e=>{this.currentPeriodController.updateCalendarPeriod(e.detail,this.postOperationDate)},this.todayButtonClick=()=>{this.currentPeriodController.setCurrentPeriod(this.currentPeriod.now())},this.nextButtonClick=()=>{this.currentPeriodController.setCurrentPeriod(this.currentPeriod.next())},this.prevButtonClick=()=>{this.currentPeriodController.setCurrentPeriod(this.currentPeriod.previous())},this.moreActionMenuClick=e=>{this.moreActionClickEmitter.emit(e.detail)}}getSwitchPanelRef(){return this.switchPanelRef}render(){return e("vega-flex",{direction:"row",gap:"size-16",justifyContent:"space-between",alignItems:"center",class:"calendar-switch-panel",ref:e=>this.switchPanelRef=e},this.renderDateSwitch(),e("div",{class:"calendar-view-switch-container"},this.showSwitchView?this.renderViewSwitch():null,this.renderMoreActionMenu()))}renderDateSwitch(){return e("div",{class:"calendar-date-switch-container"},e("vega-button",{variant:"secondary",size:"small",ref:e=>{w.addUniqueObserverToNode(e,u,this.todayButtonClick)},label:this.translationSlimmer.t("Today")}),e("vega-button-circle",{variant:"secondary",size:"small",icon:j.getIconKey("chevron-left"),label:"previous",showTooltip:!1,ref:e=>{w.addUniqueObserverToNode(e,u,this.prevButtonClick)}}),e("vega-button-circle",{variant:"secondary",size:"small",icon:j.getIconKey("chevron-right"),label:"next",showTooltip:!1,ref:e=>{w.addUniqueObserverToNode(e,u,this.nextButtonClick)}}),this.renderCurrentPeriod())}renderCurrentPeriod(){return e("vega-font",{class:"calendar-current-date",variant:"font-field-label",color:"text-primary"},this.getViewDateSummary())}renderViewSwitch(){return e("vega-segment-control",{segments:Q.views.map((e=>Object.assign(Object.assign({},e),{text:this.translationSlimmer.t(e.text)}))),size:"small",variant:"text-only",selected:this.viewMode,ref:e=>{w.addUniqueObserverToNode(e,m,this.handleViewChange)}})}renderMoreActionMenu(){var t,i;if(null===(i=null===(t=this.moreActionDropdownProps)||void 0===t?void 0:t.source)||void 0===i?void 0:i.length)return e("vega-dropdown",Object.assign({alignment:"end",trigger:"click"},this.moreActionDropdownProps,{ref:e=>{w.addUniqueObserverToNode(e,g,this.moreActionMenuClick)}}),e("vega-button-circle",{size:"small",icon:j.getIconKey("ellipsis-vertical"),variant:"icon-only"}))}getViewDateSummary(){const e=this.currentPeriod.current;let t="";switch(this.viewMode){case"day":{const i=this.translationSlimmer.t(e.getMonthName());t=`${e.date} ${i}, ${e.year}`;break}case"week":{const e=this.calendarView.dateItems[0],i=e[0],n=e[e.length-1],[r,o]=[i,n].map((e=>this.translationSlimmer.t(e.getMonthName())));t=`${i.date} ${r}${i.year===n.year?"":", "+i.year} - ${n.date} ${o}, ${n.year}`;break}case"month":t=`${this.translationSlimmer.t(e.getMonthName())}, ${e.year}`}return t}}j.register({"chevron-right":{icon:'<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 320 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="M310.6 233.4c12.5 12.5 12.5 32.8 0 45.3l-192 192c-12.5 12.5-32.8 12.5-45.3 0s-12.5-32.8 0-45.3L242.7 256 73.4 86.6c-12.5-12.5-12.5-32.8 0-45.3s32.8-12.5 45.3 0l192 192z"/></svg>'},"chevron-left":{icon:'<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 320 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="M9.4 233.4c-12.5 12.5-12.5 32.8 0 45.3l192 192c12.5 12.5 32.8 12.5 45.3 0s12.5-32.8 0-45.3L77.3 256 246.6 86.6c12.5-12.5 12.5-32.8 0-45.3s-32.8-12.5-45.3 0l-192 192z"/></svg>'},"ellipsis-vertical":{icon:'<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 128 512">\x3c!--! Font Awesome Pro 6.3.0 by @fontawesome - https://fontawesome.com License - https://fontawesome.com/license (Commercial License) Copyright 2023 Fonticons, Inc. --\x3e<path fill="currentColor" d="M48 464a48 48 0 1 1 0-96 48 48 0 1 1 0 96zm0-160a48 48 0 1 1 0-96 48 48 0 1 1 0 96zM0 96a48 48 0 1 1 96 0A48 48 0 1 1 0 96z"/></svg>'}}),Q.views=[{text:"Day",key:"day"},{text:"Week",key:"week"},{text:"Month",key:"month"}],G([l()],Q.prototype,"viewMode",void 0),G([l()],Q.prototype,"calendarView",void 0),G([l()],Q.prototype,"currentPeriod",void 0),G([l()],Q.prototype,"moreActionDropdownProps",void 0),G([l()],Q.prototype,"moreActionClickEmitter",void 0),G([l()],Q.prototype,"currentPeriodController",void 0),G([l()],Q.prototype,"calendarViewController",void 0),G([l()],Q.prototype,"translationSlimmer",void 0),G([l()],Q.prototype,"postOperationDate",void 0),G([l()],Q.prototype,"showSwitchView",void 0);var J=function(e,t,i,n){var r,o=arguments.length,a=o<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,i,n);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,i,a):r(t,i))||a);return o>3&&a&&Object.defineProperty(t,i,a),a};class ee extends d{getCalendarViewElementRef(){return this.calendarViewElementRef}render(){return e("div",{class:`calendar-view calendar-view-${this.viewMode} ${!1===this.showWeekends?"calendar-hide-weekends":""}`,ref:e=>this.calendarViewElementRef=e},"month"===this.viewMode?this.monthViewRenderer.render():this.viewWithTimeRenderer.render())}}J([l()],ee.prototype,"viewMode",void 0),J([l()],ee.prototype,"showWeekends",void 0),J([l()],ee.prototype,"monthViewRenderer",void 0),J([l()],ee.prototype,"viewWithTimeRenderer",void 0);var te=function(e,t,i,n){var r,o=arguments.length,a=o<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,i,n);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,i,a):r(t,i))||a);return o>3&&a&&Object.defineProperty(t,i,a),a};class ie extends d{emit(e,t){this.shouldHandleClickEvent(e)?this.dateClickEmitter.emit(t):this.shouldHandleDblClickEvent(e)&&this.dateDblClickEmitter.emit(t)}shouldHandleClickEvent(e){return!0===this.enableDateClick&&"click"===e.type}shouldHandleDblClickEvent(e){return!0!==this.enableDateClick&&"dblclick"===e.type}generateDateBlockRenderProps(e,t,i){const n={};return e||(this.enableDateClick?(n.tabIndex=0,n.role="button",n.onClick=e=>{this.handleDateBlockClick(e,t,i)},n.onKeyDown=D()):n.onDblClick=e=>{this.handleDateBlockClick(e,t,i)}),n}}te([l()],ie.prototype,"enableDateClick",void 0),te([l()],ie.prototype,"dateClickEmitter",void 0),te([l()],ie.prototype,"dateDblClickEmitter",void 0);var ne=function(e,t,i,n){var r,o=arguments.length,a=o<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,i,n);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,i,a):r(t,i))||a);return o>3&&a&&Object.defineProperty(t,i,a),a};class re extends ie{render(){return e("div",{class:"calendar-view-month-container"},e("div",{class:"calendar-view-row calendar-view-title border-divider-bottom"},this.calendarView.weekdays.map((t=>e("div",{key:t},this.translationSlimmer.t(t))))),this.renderMonthViewContent())}handleDateBlockClick(e,t){const{target:i,clientX:n,clientY:r}=e;if(this.isMonthBlockBlankArea(i)){const{year:i,month:o,date:a}=t;this.emit(e,{year:i,month:o,date:a,hour:0,mouseEventInfo:{clientX:n,clientY:r}})}}renderMonthViewContent(){const t=this.currentPeriod.current;return this.calendarView.dateItems.map(((i,n)=>{const r=this.monthEventRenderer.getCurrentRowEvents(i),o=this.monthEventRenderer.filterRowDisplayEvents(r);return e("div",{key:n,class:"calendar-view-row border-divider-bottom"},i.map(((i,n)=>{var a;const s=null===(a=this.isDateDisabled)||void 0===a?void 0:a.call(this,i.toDate()),l=this.generateDateBlockRenderProps(s,i);return e("div",Object.assign({class:{"row-cell border-divider-right":!0,"current-month-day":i.compare(t).inMonth,active:i.isToday(),disabled:s},key:`${i.month}-${i.date}`},l),this.renderDateBlock(i),this.monthEventRenderer.render(i,r[n],o[n],n))})))}))}renderDateBlock(t){return e("div",{class:"date"},1===t.date&&e("div",{class:"month-block"},t.getMonthName(!0)),e("div",{role:"button",tabIndex:0,class:"grid-col",onDblClick:e=>{this.handleDateLabelClick(e,t)},onClick:e=>{this.handleDateLabelClick(e,t)},onKeyDown:D()},t.date))}goToCurrentDayView(e){this.currentPeriodController.updateCalendarPeriod("day",e)}handleDateLabelClick(e,t){e.stopPropagation(),this.showSwitchView&&(this.shouldHandleClickEvent(e)||this.shouldHandleDblClickEvent(e))&&this.goToCurrentDayView(t)}isMonthBlockBlankArea(e){return!e.classList.contains("more-button")&&"VEGA-CALENDAR-EVENT"!==e.tagName}}ne([l()],re.prototype,"viewMode",void 0),ne([l()],re.prototype,"calendarView",void 0),ne([l()],re.prototype,"currentPeriod",void 0),ne([l()],re.prototype,"currentPeriodController",void 0),ne([l()],re.prototype,"monthEventRenderer",void 0),ne([l()],re.prototype,"translationSlimmer",void 0),ne([l()],re.prototype,"isDateDisabled",void 0),ne([l()],re.prototype,"showSwitchView",void 0);var oe=function(e,t,i,n){var r,o=arguments.length,a=o<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,i,n);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,i,a):r(t,i))||a);return o>3&&a&&Object.defineProperty(t,i,a),a};class ae extends ie{render(){return e("div",{class:"calendar-view-container"},this.renderViewTitle(),this.renderViewContent())}handleDateBlockClick(e,t,i){const{year:n,month:r,date:o}=t,{clientX:a,clientY:s}=e;this.emit(e,{year:n,month:r,date:o,hour:i,mouseEventInfo:{clientX:a,clientY:s}})}renderViewTitle(){const t=this.calendarView.dateItems[0],i=this.calendarView.weekdays;return e("div",{class:"calendar-view-title-container"},e("div",{class:"calendar-view-row"},e("div",{class:"time-line-empty"}),e("div",{class:"calendar-view-title"},t.map(((t,n)=>e("div",{key:t.date,class:{active:t.isToday()}},e("div",null,this.translationSlimmer.t(i[n])),e("div",{class:"week-day"},t.date)))))),e("div",{class:"calendar-view-row calendar-view-event-all-container border-divider-bottom"},e("div",{class:"time-line-all"},this.translationSlimmer.t("All Day")),this.dayViewFullDayEventRenderer.render()))}renderViewContent(){const t=this.calendarView.dateItems[0];return e("div",{class:"calendar-view-row calendar-view-day-container"},this.timeLineRenderer.render(),e("div",{class:"calendar-view-content-container"},e("div",{class:"calendar-view-content"},t.map((t=>{var i;const n=null===(i=this.isDateDisabled)||void 0===i?void 0:i.call(this,t.toDate());return e("div",{class:{"grid-col border-divider-left":!0,disabled:n},key:t.date},e("div",{class:"hour-empty border-divider-top"}),this.renderHourBlock(t,n))}))),this.dayViewTimedEventRenderer.render(),this.timeMarkerRenderer.render(t)))}renderHourBlock(t,i){return Array(24).fill("").map(((n,r)=>{var o;let a=!1;if(!i){const e=new Date(t.toDate().setHours(r));a=null===(o=this.isDateDisabled)||void 0===o?void 0:o.call(this,e)}const s=this.generateDateBlockRenderProps(i||a,t,r);return e("div",Object.assign({key:r,class:{"grid-cell border-divider-top":!0,disabled:i||a}},s))}))}}oe([l()],ae.prototype,"viewMode",void 0),oe([l()],ae.prototype,"timeLineRenderer",void 0),oe([l()],ae.prototype,"timeMarkerRenderer",void 0),oe([l()],ae.prototype,"dayViewTimedEventRenderer",void 0),oe([l()],ae.prototype,"dayViewFullDayEventRenderer",void 0),oe([l()],ae.prototype,"calendarView",void 0),oe([l()],ae.prototype,"translationSlimmer",void 0),oe([l()],ae.prototype,"isDateDisabled",void 0),oe([l()],ae.prototype,"enableDateClick",void 0);class se extends d{render(){const t=this.getTimeLineTitles();return e("div",{class:"time-line"},e("div",{class:"hour-empty"}),t.map(((t,i)=>e("div",{key:t},e("div",{class:"time-text","data-time":0===i?24:i},t)))))}getTimeLineTitles(){const e=[];if("12-hour"===this.timeFormat){e.push("12 AM");for(let t=1;t<12;t++)e.push(`${t} AM`);e.push("12 PM");for(let t=1;t<12;t++)e.push(`${t} PM`)}else for(let t=0;t<24;t++)e.push(`${E(t)}`);return e}}!function(e,t,i,n){var r,o=arguments.length,a=o<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,i,n);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,i,a):r(t,i))||a);o>3&&a&&Object.defineProperty(t,i,a)}([l()],se.prototype,"timeFormat",void 0);const le=(e=0)=>{const t=[0,1,2,3,4,5,6];return t.concat(t).slice(e,e+7)};var de;!function(e){e.sun="Sunday",e.mon="Monday",e.tue="Tuesday",e.wed="Wednesday",e.thu="Thursday",e.fri="Friday",e.sat="Saturday"}(de||(de={}));const ce=(e,t)=>{const[i,n]=t.split(":");if("24-hour"===e)return`${i.padStart(2,"0")}:${n.padStart(2,"0")}`;{const e=Number(i),t=e>=12?"pm":"am",r=n.padStart(2,"0");return e>12?`${e-12}:${r} ${O.t("pm")}`:0===e?`12:${r} ${O.t("am")}`:`${e}:${r} ${O.t(t)}`}};class he{constructor(){this.WEEKDAYS_SHORT=["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],this.weekdays=le()}getWeekdayNames(){return this.WEEKDAYS_SHORT}generateDates(e){const t=e.startDate.toDate(),i=[];for(let n=0;n<e.count;n++)i.push(new Date(t)),t.setDate(t.getDate()+1);return i}generateWeekHead(){return this.weekdays.map((e=>this.getWeekdayNames()[e]))}}class ve{constructor(e,t){this._weekdays=e,this._dateItems=t}get weekdays(){return this._weekdays}get dateItems(){return this._dateItems}}class pe extends he{generate(e){return new ve([this.generateWeekHead()[e.current.toDate().getDay()]],[[e.current]])}}class fe{constructor(e,t,i){this._date=i,this._month=t,this._year=e}static from(e){return new fe(e.getFullYear(),e.getMonth()+1,e.getDate())}get year(){return this._year}set year(e){this._year=e}get month(){return this._month}set month(e){this._month=e}get date(){return this._date}set date(e){this._date=e}isToday(){const e=new Date;return e.getFullYear()===this.year&&e.getMonth()+1===this.month&&e.getDate()===this.date}toDate(){return new Date(this.year,this.month-1,this.date)}compare(e){const{year:t,month:i}=e,n={isPreviousMonth:!1,inMonth:!1,isNextMonth:!1};return this.year===t?this.month<i?n.isPreviousMonth=!0:this.month>i?n.isNextMonth=!0:n.inMonth=!0:this.year>t?n.isNextMonth=!0:n.isPreviousMonth=!0,n}equal(e){const{year:t,month:i,date:n}=e;return this._year===t&&this._month===i&&this._date===n}getMonthName(e=!1){return O.t(this.toDate().toLocaleDateString("en-US",{month:e?"short":"long"}))}}class we extends he{generate(e){const t=this.generateDates(e),i=e.showWeekends;let n=this.generateWeekHead(),r=[t.map(fe.from)];return!1===i&&(n=n.slice(1,6),r=r.map((e=>e.slice(1,6)))),new ve(n,r)}}class ue extends he{generate(e){const t=e.showWeekends;let i=[],n=[];this.generateDates(e).forEach(((e,t)=>{t%7||(i[t/7]=n=[]);const r=fe.from(e);n.push(r)}));let r=this.generateWeekHead();return!1===t&&(r=r.slice(1,6),i=i.map((e=>e.slice(1,6)))),new ve(r,i)}}class me{constructor(e,t){this._count=e,this._current=t||fe.from(new Date),this.calculatePeriod(this._current)}get current(){return this._current}get startDate(){return this._startDate}get endDate(){return this._endDate}get count(){return this._count}get type(){return this._type}get showWeekends(){return this._showWeekends}goTo(e){return this.createBy(e)}now(){return this.createBy(fe.from(new Date))}calculatePeriod(e){const t=e.toDate();this.count>1&&t.setDate(t.getDate()-le().indexOf(t.getDay())),this._startDate=fe.from(t),t.setDate(t.getDate()+this.count-1),this._endDate=fe.from(t)}}var ge;function be(e,t=15){const[i,n]=e.split(":");return Math.round((60*Number(i)+Number(n))/t)}function xe(e){return"vega-calendar-event-slot-"+e}function ye(e,t=ge.NEXT){const i=e.toDate().getDay();if(0===i||6===i){let n=0===i?1:2;return t===ge.PREVIOUS&&(n=0===i?-2:-1),fe.from(new Date(e.year,e.month-1,e.date+n))}return e}function ke(e="bg-accent6-primary"){return P(e)?`.event-bg-color{${M.formatToken(e)}}`:`.event-bg-color{background-color:${e}}`}!function(e){e.PREVIOUS="-1",e.NEXT="1"}(ge||(ge={}));class Ce extends me{constructor(e,t){super(Ce.DISPLAY_DATE_COUNT,e),this._type="day",this._showWeekends=!0,this._showWeekends=!1!==t}next(){const e=this.current.toDate();e.setDate(e.getDate()+1);let t=fe.from(e);return!1===this._showWeekends&&(t=ye(t)),this.createBy(t)}previous(){const e=this.current.toDate();e.setDate(e.getDate()-1);let t=fe.from(e);return!1===this._showWeekends&&(t=ye(t,ge.PREVIOUS)),this.createBy(t)}now(){let e=fe.from(new Date);return!1===this._showWeekends&&(e=ye(e)),this.createBy(e)}createBy(e){return new Ce(e,this._showWeekends)}}Ce.DISPLAY_DATE_COUNT=1;class Re extends me{constructor(e,t){super(Re.DISPLAY_DATE_COUNT,e),this._type="week",this._showWeekends=!0,this._showWeekends=!1!==t}next(){const e=this.current.toDate();return e.setDate(e.getDate()+7),this.createBy(fe.from(e))}previous(){const e=this.current.toDate();return e.setDate(e.getDate()-7),this.createBy(fe.from(e))}createBy(e){return new Re(e,this._showWeekends)}}Re.DISPLAY_DATE_COUNT=7;class je extends me{constructor(e,t){super(je.DISPLAY_DATE_COUNT,e),this._type="month",this._showWeekends=!0,this._showWeekends=!1!==t}static getMonthFirstDay(e){const t=e||fe.from(new Date);return new fe(t.year,t.month,1)}calculatePeriod(e){const t=je.getMonthFirstDay(e).toDate();t.setDate(t.getDate()-le().indexOf(t.getDay())),this._startDate=fe.from(t),t.setDate(t.getDate()+this.count-1),this._endDate=fe.from(t)}next(){const e=this.current.toDate();return e.setMonth(e.getMonth()+1),this.createBy(fe.from(e))}previous(){const e=this.current.toDate();return e.setMonth(e.getMonth()-1),this.createBy(fe.from(e))}createBy(e){return new je(e,this._showWeekends)}}je.DISPLAY_DATE_COUNT=42;var De=function(e,t,i,n){var r,o=arguments.length,a=o<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,i,n);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,i,a):r(t,i))||a);return o>3&&a&&Object.defineProperty(t,i,a),a};class Ee extends d{constructor(){super(...arguments),this.monthViewGenerator=new ue,this.weekViewGenerator=new we,this.dayViewGenerator=new pe}initialCalendarView(){this.setCalendarView(this.getCalendarViewByPeriod(this.currentPeriod))}generateCalendarView(e){this.setCalendarView(this.getCalendarViewByPeriod(e))}getCalendarViewByPeriod(e){switch(e.type){case"week":return this.weekViewGenerator.generate(e);case"day":return this.dayViewGenerator.generate(e);default:return this.monthViewGenerator.generate(e)}}setCalendarView(e){this.calendarView=e}}De([l({writable:!0})],Ee.prototype,"calendarView",void 0),De([l()],Ee.prototype,"currentPeriod",void 0),De([l()],Ee.prototype,"showWeekends",void 0),De([l()],Ee.prototype,"currentPeriodController",void 0),De([c("componentWillLoad")],Ee.prototype,"initialCalendarView",null),De([c("watchCurrentPeriodChange")],Ee.prototype,"generateCalendarView",null);var ze=function(e,t,i,n){var r,o=arguments.length,a=o<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,i,n);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,i,a):r(t,i))||a);return o>3&&a&&Object.defineProperty(t,i,a),a};class Oe extends d{setCurrentPeriod(e){this.currentPeriod=e}updateCalendarPeriod(e,t){switch(e){case"month":this.setCurrentPeriod(new je(t,this.showWeekends));break;case"week":this.setCurrentPeriod(new Re(t,this.showWeekends));break;case"day":t=!1===this.showWeekends?ye(t):t,this.setCurrentPeriod(new Ce(t,this.showWeekends))}}initialCurrentPeriod(){this.updateCalendarPeriod(this.viewMode,fe.from(new Date))}emitChangeEvent(e,t){e&&t&&e.startDate.equal(t.startDate)&&e.endDate.equal(t.endDate)||(e&&e.type!==this.viewMode&&(this.viewMode=e.type),this.changeEventEmitter.emit({viewMode:e.type,currentPeriod:this.getCurrentPeriodSummary()}))}updateCurrentPeriodByViewMode(e){this.currentPeriod&&e!==this.currentPeriod.type&&this.updateCalendarPeriod(e,this.currentPeriod.current)}updateCurrentPeriodAfterHideWeekEndsChange(){this.updateCalendarPeriod(this.viewMode,this.currentPeriod.current)}getCurrentPeriodSummary(){const{current:e,startDate:t,endDate:i}=this.currentPeriod;return{year:e.year,month:e.month,startDate:{date:t.date,month:t.month,year:t.year},endDate:{date:i.date,month:i.month,year:i.year}}}}ze([l({writable:!0})],Oe.prototype,"currentPeriod",void 0),ze([l()],Oe.prototype,"changeEventEmitter",void 0),ze([l({writable:!0})],Oe.prototype,"viewMode",void 0),ze([l()],Oe.prototype,"showWeekends",void 0),ze([c("componentWillLoad")],Oe.prototype,"initialCurrentPeriod",null),ze([c("watchCurrentPeriodChange")],Oe.prototype,"emitChangeEvent",null),ze([c("watchViewModeChange")],Oe.prototype,"updateCurrentPeriodByViewMode",null),ze([c("watchShowWeekendsChange")],Oe.prototype,"updateCurrentPeriodAfterHideWeekEndsChange",null);var Me=function(e,t,i,n){var r,o=arguments.length,a=o<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,i,n);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,i,a):r(t,i))||a);return o>3&&a&&Object.defineProperty(t,i,a),a};class Pe extends d{constructor(){super(...arguments),this.maxMonthDisplayEventsCount=2,this.popoverHideObserver=null}getCurrentRowEvents(e){const t=[];return e.forEach((e=>{const i=this.calendarEventController.getCurrentDateEvents(e);t.push(i)})),this.fullDayEventLayoutRenderer.sortLongEvents(t)}filterRowDisplayEvents(e){const t=[];return e.forEach((e=>{const i=e.length>this.maxMonthDisplayEventsCount?e.slice(0,this.maxMonthDisplayEventsCount-1):e;t.push(i)})),this.hideTheCutOffEvents(e,t)}getMonthEventContainerRef(){return this.eventContainerRef}render(t,i,n,r){const o=i.slice(n.length).filter((e=>e)).length;return e("div",{class:"events-container",ref:e=>this.eventContainerRef=e},e("div",{class:"event-list"},this.fullDayEventLayoutRenderer.render(n,r,t)),this.renderMoreButton(i,o,t))}addMaxDisplayCountChange(){w.addUniqueObserverToNode(this.host,I,(e=>{this.maxMonthDisplayEventsCount=e.detail,"month"===this.viewMode&&i(this.host)}))}renderMoreButton(t,i,n){if(i){const r=t.filter((e=>e&&(e.isAllDayEvent||e.isGroupEvent()))),o=t.filter((e=>e&&!e.isAllDayEvent&&!e.isGroupEvent()));return e("div",{class:"month-event-more"},e("vega-popover",{trigger:"click",placement:"right",padding:"0",ref:e=>{this.setPopoverHideObserver(e,t)},isScreenPosition:!0},e("div",{tabIndex:0,slot:"popover-content",role:"button",class:"more-button",onKeyDown:D()},`${i} More`),e("vega-flex",{slot:"popover"},e("vega-box",{padding:"size-12",width:256},e("vega-flex",{direction:"col",gap:"0",class:"group-events"},e("vega-font",{textAlign:"center",variant:"font-field-label",color:"text-primary",style:{padding:"4px 0",marginBottom:"8px"}},`${n.date} ${n.getMonthName()} ${n.year}`),e("vega-box",{maxHeight:"calc(60vh - 6px)",style:{overflowY:"auto"},padding:"size-4"},e("vega-flex",{direction:"col",gap:"size-4",style:{paddingBottom:o.length?"4px":"0px"}},r.map((e=>this.eventItemRenderer.render(e,{"month-event":!0,"calendar-event-large-size":!0,"calendar-event-in-popover":!0},n,!0)))),o.map((e=>this.eventItemRenderer.render(e,{"month-event":!0,"calendar-event-large-size":!0,"calendar-event-in-popover":!0},n,!0)))))),e("div",{class:"preview-container",ref:e=>{e?this.eventPreviewPopoverController.setEventPreviewContainerMap(t,n,e):this.eventPreviewPopoverController.deleteEventPreviewContainer(t,n)}}))))}}hideTheCutOffEvents(e,t){const i=[],n=[],r=t.map((e=>e[e.length-1])).filter((e=>e&&e.isGroupEvent()));return r.length&&r.forEach((i=>{e.filter((e=>e.includes(i))).length>t.filter((e=>e.includes(i))).length&&n.push(i)})),n.length?(t.forEach((e=>{e.length&&e[e.length-1]&&n.includes(e[e.length-1])?i.push(e.slice(0,e.length-1)):i.push(e)})),i):t}setPopoverHideObserver(e,t){e?(this.popoverHideObserver=new V((e=>t.includes(e)),(async()=>await e.hide())),L.register(B,this.popoverHideObserver)):this.popoverHideObserver&&L.unregister(B,this.popoverHideObserver),e&&w.addUniqueObserverToNode(e,b,(()=>{L.notify(x.getSubject(this.renderer.getEventPreviewRef(),$),{})}))}}Me([l()],Pe.prototype,"viewMode",void 0),Me([l()],Pe.prototype,"host",void 0),Me([l()],Pe.prototype,"calendarEventController",void 0),Me([l()],Pe.prototype,"eventItemRenderer",void 0),Me([l()],Pe.prototype,"fullDayEventLayoutRenderer",void 0),Me([l()],Pe.prototype,"eventPreviewPopoverRenderer",void 0),Me([l()],Pe.prototype,"renderer",void 0),Me([l()],Pe.prototype,"eventPreviewPopoverController",void 0),Me([c("componentWillLoad")],Pe.prototype,"addMaxDisplayCountChange",null);class Se{constructor(e,t,i,n){this.repeatStartDate=e,this.interval=t,this.count=i,this.until=n}getRepeatSeries(e,t=1){return this.generateRepeatDateCacheUntilEndDate(e.endDate),this.cache.filter((i=>this.isSeriesInPeriod(i,t,e)))}isSeriesInPeriod(e,t,i){const n=e.toDate(),r=new Date(e.year,e.month-1,e.date+t-1),{startDate:o,endDate:a}=i,s=o.toDate(),l=a.toDate();return n>=s&&n<=l||r>=s&&r<=l||n<=s&&r>=l}generateRepeatEndsString(){return this.until?` ${O.t("until {0}",`${this.until.getMonthName()} ${this.until.date}, ${this.until.year}`)}`:this.count?` ${O.t("after {0} occurrences",this.count)}`:""}}Se.daySeconds=864e5;class Ie extends Se{constructor(e,t,i,n){super(e,t,i,n),this.initCache()}generateRepeatString(){return(this.interval>1?O.t("Repeat every {0} days",this.interval):O.t("Repeat daily"))+this.generateRepeatEndsString()}generateRepeatDateCacheUntilEndDate(e){const t=this.cache[this.cache.length-1];if(t.toDate()<e.toDate()&&(!this.count||"number"==typeof this.count&&this.cache.length<this.count)){let i=this.getNextRepeatStartDate(t);for(;i&&i.toDate()<e.toDate();){const e=this.getNextRepeatStartDate(i);if(e&&e.toDate()<=i.toDate()){this.cache.pop();break}if(i=e,"number"==typeof this.count&&this.cache.length>=this.count)break}}}initCache(){this.cache=[this.repeatStartDate]}getNextRepeatStartDate(e){const t=new Date(e.year,e.month-1,e.date+this.interval),i=fe.from(t);return this.until&&t>this.until.toDate()||"number"==typeof this.count&&this.cache.length>=this.count?null:(this.cache.push(i),i)}}class $e extends Se{constructor(e,t,i,n){super(e,t,i,n),this.byMonthDay=this.repeatStartDate.date,this.initCache()}generateRepeatString(){return(this.interval>1?O.t("Repeat every {0} months on day {1}",this.interval,this.byMonthDay):O.t("Repeat monthly on day {0}",this.byMonthDay))+this.generateRepeatEndsString()}generateRepeatDateCacheUntilEndDate(e){const t=this.cache[this.cache.length-1];if(t.toDate()<e.toDate()&&(!this.count||"number"==typeof this.count&&this.cache.length<this.count)){let i=this.getNextRepeatStartDate(t);for(;i&&i.toDate()<e.toDate();){const e=this.getNextRepeatStartDate(i);if(e&&e.toDate()<=i.toDate()){this.cache.pop();break}if(i=e,"number"==typeof this.count&&this.cache.length>=this.count)break}}}initCache(){this.cache=[this.repeatStartDate]}getNextRepeatStartDate(e){const t=this.getNextStartDate(e.year,e.month-1+this.interval),i=fe.from(t);return this.until&&t>this.until.toDate()||"number"==typeof this.count&&this.cache.length>=this.count?null:(this.cache.push(i),i)}getNextStartDate(e,t){const i=new Date(e,t,this.byMonthDay);return i.getDate()===this.byMonthDay?i:this.getNextStartDate(e,t+1)}}class Te extends Se{constructor(e,t,i,n,r){super(e,t,i,n),this.byWeekDay=this.sortWeekDay(r),this.initCache()}getRepeatSeries(e,t=1){return this.generateRepeatDateCacheUntilEndDate(e.endDate),this.getValidCache().filter((i=>this.isSeriesInPeriod(i,t,e)))}generateRepeatString(){const e=this.byWeekDay.map((e=>O.t(de[e])));return(this.interval>1?O.t("Repeat every {0} weeks on {1}",this.interval,e.join(", ")):O.t("Repeat weekly on {0}",e.join(", ")))+this.generateRepeatEndsString()}generateRepeatDateCacheUntilEndDate(e){const t=this.cache[this.cache.length-1];if(t[0].toDate()<e.toDate()&&(!this.count||"number"==typeof this.count&&this.cache.length<this.count)){let i=this.getNextRepeatStartDate(t);for(;i&&i[0].toDate()<e.toDate();){const e=this.getNextRepeatStartDate(i);if(e&&e[0]&&e[0].toDate()<=i[0].toDate()){this.cache.pop();break}if(i=e,"number"==typeof this.count&&this.getValidCache().length>=this.count)break}}}getNextRepeatStartDate(e){const t=this.getNextStartDates(e);if(0===t.length||"number"==typeof this.count&&this.getValidCache().length>=this.count)return null;{const e=t.map((e=>fe.from(e)));return this.cache.push(e),e}}getNextStartDates(e){return e.map((e=>new Date(e.year,e.month-1,e.date+7*this.interval))).filter((e=>!this.until||e<=this.until.toDate()))}initCache(){const e=[],t=this.getCurrentDayIndex(this.repeatStartDate);this.byWeekDay.forEach((i=>{const n=Te.weekDay.indexOf(i)-t,{year:r,month:o,date:a}=this.repeatStartDate,s=fe.from(new Date(r,o-1,a+n));e.push(s)})),this.cache=[e]}sortWeekDay(e){return e&&e.length?e.map((e=>e.toLocaleLowerCase())).sort(((e,t)=>Te.weekDay.indexOf(e)-Te.weekDay.indexOf(t))):[Te.weekDay[this.getCurrentDayIndex(this.repeatStartDate)]]}getCurrentDayIndex(e){return e.toDate().getDay()}getValidCache(){const e=A(this.cache.slice(1));return this.cache[0].filter((e=>e.toDate()>=this.repeatStartDate.toDate())).concat(e).slice(0,"number"==typeof this.count?this.count:void 0)}}Te.weekDay=["Sun","Mon","Tue","Wed","Thu","Fri","Sat"].map((e=>e.toLowerCase()));class Ve extends Se{constructor(e,t,i,n){super(e,t,i,n),this.matchDay=this.repeatStartDate.date,this.matchMonth=this.repeatStartDate.month,this.initCache()}generateRepeatString(){const e=O.t(this.repeatStartDate.getMonthName());return(this.interval>1?O.t("Repeat every {0} years on {1} {2}",this.interval,e,this.matchDay):O.t("Repeat yearly on {0} {1}",e,this.matchDay))+this.generateRepeatEndsString()}generateRepeatDateCacheUntilEndDate(e){const t=this.cache[this.cache.length-1];if(t.toDate()<e.toDate()&&(!this.count||"number"==typeof this.count&&this.cache.length<this.count)){let i=this.getNextRepeatStartDate(t);for(;i&&i.toDate()<e.toDate();){const e=this.getNextRepeatStartDate(i);if(e&&e.toDate()<=i.toDate()){this.cache.pop();break}if(i=e,"number"==typeof this.count&&this.cache.length>=this.count)break}}}getNextRepeatStartDate(e){const t=this.getNextStartDate(e.year+this.interval),i=fe.from(t);return this.until&&t>this.until.toDate()||"number"==typeof this.count&&this.cache.length>=this.count?null:(this.cache.push(i),i)}getNextStartDate(e){const t=new Date(e,this.matchMonth-1,this.matchDay);return t.getDate()===this.matchDay&&t.getMonth()+1===this.matchMonth?t:this.getNextStartDate(e+1)}initCache(){this.cache=[this.repeatStartDate]}}const Le=new class{getPattern(e,t){const i=fe.from(e),{frequency:n,interval:r=1,byWeekDay:o,until:a,count:s}=t,l=this.initDate(a);return this.initRepeatPattern(n,i,r<1?1:r,s,l,o)}initDate(e){if(e&&"object"==typeof e)return fe.from(e);if(e&&"string"==typeof e){const[t,i,n]=e.split("/");return new fe(Number(n),Number(t),Number(i))}}initRepeatPattern(e,t,i,n,r,o){switch(e){case"daily":return new Ie(t,i,n,r);case"weekly":return new Te(t,i,n,r,o);case"monthly":return new $e(t,i,n,r);default:return new Ve(t,i,n,r)}}},Be=/^\d{1,2}\/\d{1,2}\/\d{4}/,Ae=/^\d{1,2}:\d{1,2}/;class Ne{constructor(e,t){this._eventSpansDays=1,this.repeatPattern=null,this._event=e,this._eventKey=t||N(),this.checkEventRequireField(e),this.initDate(e),this.initEventSpansDays(),this.initRepeatPattern()}get event(){return this._event}get eventKey(){return this._eventKey}get title(){return this._event.title}get disabled(){return!!this._event.disabled}get variant(){return this._event.variant}get color(){return this._event.color}get isAllDayEvent(){return!!this._event.isAllDay}get isRepeatEvent(){return null!==this.repeatPattern}get startDate(){return this._startDate}get endDate(){return this._endDate}get startTime(){return this._startTime}get endTime(){return this._endTime}get eventSpansDays(){return this._eventSpansDays}copyTo(e,t){const i=this._eventSpansDays>1?new Date(t.year,t.month-1,t.date+(this._eventSpansDays-1)):t.toDate();return new Ne(Object.assign(Object.assign({},this._event),{startDate:t.toDate(),endDate:i,startTime:this.startTime,endTime:this.endTime}),e)}isGroupEvent(){return this._eventSpansDays>1}isCurrentDayEvent(e){const{startDate:t,endDate:i}=this,n=fe.from(t),r=fe.from(new Date(i.getFullYear(),i.getMonth(),i.getDate()+1)),o=e.toDate();return n.toDate()<=o&&r.toDate()>o}generateRepeatString(){var e;return(null===(e=this.repeatPattern)||void 0===e?void 0:e.generateRepeatString())||""}generateDateTimeString(e,t){const i=O.t(Object.values(de)[e.toDate().getDay()]),n=ce(t,this.startTime),r=ce(t,this.endTime);return`${i}, ${e.date} ${e.getMonthName(!0)} ${e.year} ${n} - ${r}`}getEventDuration(){const[e,t]=this.startTime.split(":"),[i,n]=this.endTime.split(":"),r=fe.from(new Date),o=new Date(r.year,r.month,r.date,Number(e),Number(t));return(new Date(r.year,r.month,r.date,0===Number(i)&&0!==Number(e)?24:Number(i),Number(n)).valueOf()-o.valueOf())/6e4}getRepeatSeries(e){return this.repeatPattern?this.repeatPattern.getRepeatSeries(e,this._eventSpansDays):[]}convertTimeTo24Hour(e){if((e=e.toLocaleLowerCase()).indexOf("am")>0||e.indexOf("pm")>0){if(e.indexOf("am")>0){e=e.replace("am","").trim();const[t,i]=e.split(":");return`${"12"===t?"00":t}:${i}`}{e=e.replace("pm","").trim();const[t,i]=e.split(":");return`${"12"===t?"12":Number(t)+12}:${i}`}}return e}checkEventRequireField(e){const{title:t,startDate:i,endDate:n,startTime:r,endTime:o}=e;if(i&&"string"==typeof i&&!Be.test(i)||n&&"string"==typeof n&&!Be.test(n))throw new Error("Invalid calendar event item, the date format should be MM/DD/YYYY!");if(r&&"string"==typeof r&&!Ae.test(r)||o&&"string"==typeof o&&!Ae.test(o))throw new Error("Invalid calendar event item, the time format should be HH:mm!");if(!t||!i||!n&&!o)throw new Error("Invalid calendar event item, the required field should not empty!")}initDate(e){const{startDate:t,startTime:i,endDate:n,endTime:r}=e;if(t&&"object"==typeof t)this._startDate=t;else if(t&&"string"==typeof t){const[e,i,n]=t.split("/");this._startDate=new Date(Number(n),Number(e)-1,Number(i))}if(this._startTime=i?this.convertTimeTo24Hour(i):`${this._startDate.getHours()}:${this._startDate.getMinutes()}`,n&&"object"==typeof n)this._endDate=n;else if(n&&"string"==typeof n){const[e,t,i]=n.split("/");this._endDate=new Date(Number(i),Number(e)-1,Number(t),23,59,59)}else this._endDate=new Date(this._startDate.getFullYear(),this._startDate.getMonth(),this._startDate.getDate(),23,59,59);this._endTime=r?this.convertTimeTo24Hour(r):`${this._endDate.getHours()}:${this._endDate.getMinutes()}`}initRepeatPattern(){this._event.repeatOptions&&this._event.repeatOptions.frequency&&(this.repeatPattern=Le.getPattern(this._startDate,this._event.repeatOptions))}initEventSpansDays(){const e=fe.from(this.startDate),t=fe.from(this.endDate);this._eventSpansDays=(t.toDate().valueOf()-e.toDate().valueOf())/864e5+1}}var Fe=function(e,t,i,n){var r,o=arguments.length,a=o<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,i,n);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,i,a):r(t,i))||a);return o>3&&a&&Object.defineProperty(t,i,a),a};class We extends d{constructor(){super(...arguments),this.repeatEventMap=new Map}getCurrentDateEvents(e){return this.createRepeatEvents().filter((t=>t.isCurrentDayEvent(e)))}updateAfterEventChange(e){this.initCalendarEvents(e),this.repeatEventMap.clear()}updateWhenComponentWillLoad(){this.initCalendarEvents(this.events)}initCalendarEvents(e){const t=[];e&&e.forEach((e=>{try{const i=new Ne(e);t.push(i)}catch(t){h.warn("Invalid calendar event item:",e)}})),this.calendarEvents=t}createRepeatEvents(){const e=[],t=[];return this.calendarEvents.forEach((i=>{i.isRepeatEvent?i.getRepeatSeries(this.currentPeriod).forEach((e=>{t.push(this.generateCalendarEventByRepeatSeries(i,e))})):e.push(i)})),t.concat(e)}generateCalendarEventByRepeatSeries(e,t){const i=`${e.eventKey}-${t.year}${t.month}${t.date}`;if(this.repeatEventMap.has(i))return this.repeatEventMap.get(i);{const n=e.copyTo(i,t);return this.repeatEventMap.set(i,n),n}}}Fe([l()],We.prototype,"host",void 0),Fe([l({writable:!0})],We.prototype,"calendarEvents",void 0),Fe([l()],We.prototype,"currentPeriod",void 0),Fe([l()],We.prototype,"events",void 0),Fe([c("watchEventsChange")],We.prototype,"updateAfterEventChange",null),Fe([c("componentWillLoad")],We.prototype,"updateWhenComponentWillLoad",null);var He=function(e,t,i,n){var r,o=arguments.length,a=o<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,i,n);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,i,a):r(t,i))||a);return o>3&&a&&Object.defineProperty(t,i,a),a};class _e extends d{render(t,i,n,r=!1){return e("vega-calendar-event",{"data-calendar-ref":this.host,key:t.eventKey,calendarEvent:t,class:i,onKeyDown:D(),onClick:()=>{this.handleEventClick(t),this.enabledEventPreview&&this.setupPreviewContainer(t,n,r)}},!t.isRepeatEvent&&e("slot",{name:xe(t.event.key)}))}handleEventClick(e){this.eventClickEmitter.emit({rawEvent:e.event})}setupPreviewContainer(e,t,i){const n=this.eventPreviewPopoverController.getEventPreviewContainer(e,t,i);if(n){const r=this.renderer.getEventPreviewRef();i?(r.classList.remove("single-event-preview"),r.classList.add("group-event-preview")):(r.classList.remove("group-event-preview"),r.classList.add("single-event-preview")),L.notify(x.getSubject(r,T),{event:e,targetCalendarViewDate:t,timeFormat:this.timeFormat});const o=this.host.querySelector("[slot=event-preview-additional-fields]");o&&r.append(o);const a=xe(e.event.key),s=this.host.querySelector(`[slot=${a}]`),l=r.querySelector(`[slot=${a}]`);s&&!l&&r.append(s.cloneNode(!0)),n.append(r)}}}_e.backgroundColorModeEventHeight=18,He([l()],_e.prototype,"host",void 0),He([l()],_e.prototype,"calendarView",void 0),He([l()],_e.prototype,"eventClickEmitter",void 0),He([l()],_e.prototype,"timeFormat",void 0),He([l()],_e.prototype,"enabledEventPreview",void 0),He([l()],_e.prototype,"renderer",void 0),He([l()],_e.prototype,"eventPreviewPopoverController",void 0);var Ue=function(e,t,i,n){var r,o=arguments.length,a=o<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,i,n);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,i,a):r(t,i))||a);return o>3&&a&&Object.defineProperty(t,i,a),a};class Ye extends F{constructor(){super({target:()=>this.host,callback:()=>this.updateMaxDisplayCountWithDebounce()}),this.updateMaxDisplayCountWithDebounce=W(this.updateMaxDisplayCount,500,this)}updateMaxDisplayCount(){try{const e=this.monthEventRenderer.getMonthEventContainerRef();if("month"===this.viewMode&&e&&e.parentElement){const t=e.parentElement.getBoundingClientRect().height,i=Math.floor((t-Ye.monthDateTitleHeight)/_e.backgroundColorModeEventHeight);L.notify(x.getSubject(this.host,I),{host:this.host,detail:i})}}catch(e){}}updateMaxDisplayCountAfterSwitchToMonthView(e){"month"===e&&this.updateMaxDisplayCountWithDebounce()}}Ye.monthDateTitleHeight=26,Ue([l()],Ye.prototype,"host",void 0),Ue([l()],Ye.prototype,"monthEventRenderer",void 0),Ue([l()],Ye.prototype,"viewMode",void 0),Ue([c("componentDidLoad")],Ye.prototype,"updateMaxDisplayCount",null),Ue([c("watchViewModeChange")],Ye.prototype,"updateMaxDisplayCountAfterSwitchToMonthView",null);var Ke=function(e,t,i,n){var r,o=arguments.length,a=o<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,i,n);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,i,a):r(t,i))||a);return o>3&&a&&Object.defineProperty(t,i,a),a};class qe extends d{render(){const t=this.calendarView.dateItems[0],i=t.map((e=>this.calendarEventController.getCurrentDateEvents(e).filter((e=>e.isAllDayEvent||e.isGroupEvent())))),n=this.fullDayEventLayoutRenderer.sortLongEvents(i),r=this.filterDisplayEvents(n);return e("div",{class:"calendar-view-event-all"},t.map(((t,i)=>e("div",{class:"event-all-col border-divider-left",key:t.date},this.renderCurrentFullDayEvents(r[i],i,n[i],t)))))}renderCurrentFullDayEvents(i,n,r,o){const a=i.length*_e.backgroundColorModeEventHeight-2,s=r.slice(i.length).filter(Boolean).length;return e(t,null,e("div",{class:"placeholder-block",style:{height:a+"px"}},e("span",null,i.length," events")),this.fullDayEventLayoutRenderer.render(i,n,o),s>0&&this.dayViewFullDayEventMoreButtonRenderer.render(s))}filterDisplayEvents(e){if(this.showAllEventsInDayOrWeekView)return e;{const t=[],i=qe.maxDisplayEventLength;return e.forEach((e=>{const n=e.length>i?e.slice(0,i):e;t.push(n)})),t}}}qe.maxDisplayEventLength=2,Ke([l()],qe.prototype,"calendarView",void 0),Ke([l()],qe.prototype,"calendarEventController",void 0),Ke([l()],qe.prototype,"eventItemRenderer",void 0),Ke([l()],qe.prototype,"fullDayEventLayoutRenderer",void 0),Ke([l()],qe.prototype,"showAllEventsInDayOrWeekView",void 0),Ke([l()],qe.prototype,"dayViewFullDayEventMoreButtonRenderer",void 0);var Xe=function(e,t,i,n){var r,o=arguments.length,a=o<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,i,n);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,i,a):r(t,i))||a);return o>3&&a&&Object.defineProperty(t,i,a),a};class Ze extends d{render(t,i){const n=[];return t.eventLayoutCells.forEach(((r,o)=>{let a=r.getEventBySlotIndex(0),s=0;for(let l=0;l<Ze.totalNumberOfCells;l++){const d=r.getEventBySlotIndex(l);d!==a&&(a&&n.push(e("div",{key:o,class:"time-event-block",style:this.getTimeEventStyle(s,l,o,t.getEventColumnsSpannedCount(a))},this.eventPreviewPopoverRenderer.render(a,i,{"day-event":!0,"bg-shadow":o>0}))),a=d,s=l)}})),n}getTimeEventStyle(e,t,i,n){const r=i*(1/n);return{position:"absolute",left:100*r+"%",top:100/Ze.totalNumberOfCells*e+"%",width:`calc(100% - ${100*r}%)`,height:100/Ze.totalNumberOfCells*(t-e)+"%",zIndex:i>0?`${i}`:void 0}}}Ze.totalNumberOfCells=96,Xe([l()],Ze.prototype,"eventItemRenderer",void 0),Xe([l()],Ze.prototype,"eventPreviewPopoverRenderer",void 0);class Ge{addCurrentEventToLayout(e,t){let i=e.find((e=>!e.hasOverlapEvent(t)));i?i.updateSlots(t):(i=this.createNewLayoutCell(),i.updateSlots(t),e.push(i))}}class Qe{get eventLayoutCells(){return this.cells}}class Je extends Qe{constructor(e){super(),this.cells=e}getEventColumnsSpannedCount(e){const t=this.cells.findIndex((t=>t.getEventStartIndex(e)>=0));let i=t+1;return t<this.cells.length-1&&this.cells.slice(t+1).forEach((t=>{t.hasOverlapEvent(e)&&i++})),i}}class et{getEventBySlotIndex(e){return this.slots[e]}getEventStartIndex(e){return this.slots.findIndex((t=>t===e))}getEventEndIndex(e){const t=this.getEventStartIndex(e);let i=t;if(t>=0)for(let n=t+1;n<this.slots.length;n++){if(this.slots[n]!==e){i=n-1;break}n===this.slots.length-1&&(i=n)}return i}}class tt extends et{constructor(){super(...arguments),this.slots=tt.defaultSlots}hasOverlapEvent(e){const[t,i]=this.getIndexRangeFromEvent(e);let n=!1;for(let e=t;e<i;e++)if(this.slots[e]){n=!0;break}return n}updateSlots(e){const[t,i]=this.getIndexRangeFromEvent(e);i>t&&(this.slots=this.slots.slice(0,t).concat(Array(i-t).fill(e),this.slots.slice(i)))}getIndexRangeFromEvent(e){const{startTime:t,endTime:i}=e;return[be(t),be(i)]}}tt.defaultSlots=Array(96).fill(null);class it extends Ge{generate(e){const t=[new tt];return e.forEach((e=>{this.addCurrentEventToLayout(t,e)})),new Je(t)}createNewLayoutCell(){return new tt}}class nt{sort(e,t,i){const n=[],r=[],o=[];for(let t=0;t<e.length;t++){const i=e[t];i&&(i.isGroupEvent()?r.push(i):i.isAllDayEvent?n.push(i):o.push(i))}let a=n.concat(this.sortCalendarEventByTime(o)),s=i.getEventsByIndex(t);const l=s.filter((e=>e));if(a=r.filter((e=>l.findIndex((t=>t===e))<0)).concat(a),s.length>l.length){const e=a.slice(0,s.length-l.length);a=a.slice(s.length-l.length),s=this.insertEventsToEmptyPosition(s,e)}return a=s.concat(a),a}sortCalendarEventByTime(e){return e.sort(((e,t)=>{const i=be(e.startTime),n=be(t.startTime);return i===n?be(t.endTime)-be(e.endTime):i-n}))}insertEventsToEmptyPosition(e,t){return e.map((e=>{if(t.length&&!e){const e=t[0];return t=t.slice(1),e}return e}))}}var rt=function(e,t,i,n){var r,o=arguments.length,a=o<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,i,n);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,i,a):r(t,i))||a);return o>3&&a&&Object.defineProperty(t,i,a),a};class ot extends d{constructor(){super(...arguments),this.calendarEventSorter=new nt,this.dayViewTimedEventLayoutGenerator=new it}render(){return e("div",{class:"day-event-container"},this.calendarView.dateItems[0].map((t=>e("div",{key:`${t.month}-${t.date}`,class:"day-event-col"},this.renderTimedEvents(t)))))}renderTimedEvents(e){const t=this.calendarEventController.getCurrentDateEvents(e).filter((e=>!e.isAllDayEvent&&!e.isGroupEvent())),i=this.calendarEventSorter.sortCalendarEventByTime(t),n=this.dayViewTimedEventLayoutGenerator.generate(i);return this.dayViewEventLayoutRenderer.render(n,e)}}rt([l()],ot.prototype,"calendarView",void 0),rt([l()],ot.prototype,"calendarEventController",void 0),rt([l()],ot.prototype,"dayViewEventLayoutRenderer",void 0);class at extends Qe{constructor(e){super(),this.cells=e}getEventRowsIndex(e){return this.cells.findIndex((t=>t.getEventStartIndex(e)>=0))}getEventsByIndex(e){const t=[];let i=0;return this.cells.forEach(((n,r)=>{const o=n.getEventBySlotIndex(e);t.push(o),o&&(i=r)})),t.slice(0,i+1)}}class st extends et{constructor(){super(...arguments),this.slots=st.defaultSlots}updateSlots(e){const{start:t,end:i}=e;this.slots=this.slots.slice(0,t).concat(Array(i-t+1).fill(e.event),this.slots.slice(i+1))}hasOverlapEvent(e){const{start:t,end:i}=e;let n=!1;for(let e=t;e<i+1;e++)if(this.slots[e]){n=!0;break}return n}}st.defaultSlots=Array(7).fill(null);class lt extends Ge{generate(e){const t=this.collectAllShouldOrderLongEvents(e),i=[this.createNewLayoutCell()];return t.forEach((e=>{this.addCurrentEventToLayout(i,e)})),new at(i)}createNewLayoutCell(){return new st}collectAllShouldOrderLongEvents(e){const t={};e.forEach(((e,i)=>{e.filter((e=>e&&e.isGroupEvent())).forEach((e=>{t[e.eventKey]=t[e.eventKey]?Object.assign(Object.assign({},t[e.eventKey]),{end:i,start:i-t[e.eventKey].end!=1?i:t[e.eventKey].start}):{start:i,end:i,event:e}}))}));const i=Object.values(t);return this.sortLongEventViews(i)}sortLongEventViews(e){return e.sort(((e,t)=>{const{startDate:i,endDate:n}=e.event,{startDate:r,endDate:o}=t.event;i.setHours(0,0,0),r.setHours(0,0,0),n.setHours(23,59,59),o.setHours(23,59,59);const a=o.valueOf()-r.valueOf()-(n.valueOf()-i.valueOf());return i.valueOf()!==r.valueOf()?i.valueOf()-r.valueOf():a}))}}var dt=function(e,t,i,n){var r,o=arguments.length,a=o<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,i,n);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,i,a):r(t,i))||a);return o>3&&a&&Object.defineProperty(t,i,a),a};class ct extends d{constructor(){super(...arguments),this.longEventLayoutGenerator=new lt,this.calendarEventSorter=new nt}sortLongEvents(e){return this.fullDayEventLayout=this.longEventLayoutGenerator.generate(e),e.map(((e,t)=>this.calendarEventSorter.sort(e,t,this.fullDayEventLayout)))}render(t,i,n){return t.map(((t,r)=>{if(t)return e("div",{key:t.eventKey,class:"month"===this.viewMode?"month-event-block":"day-event-block",style:this.getEventStyle(t,i,r,"month"===this.viewMode?ct.monthViewEventOffsetTop:0)},this.eventPreviewPopoverRenderer.render(t,n,{"month-event":"month"===this.viewMode,"day-event":"month"!==this.viewMode}))}))}getEventStyle(e,t,i,n){const r=this.calendarView.weekdays.length,o=t;let a=t+1;const s=i;let l=!0;const d=this.fullDayEventLayout.getEventRowsIndex(e);if(d>=0){const i=this.fullDayEventLayout.eventLayoutCells[d].getEventStartIndex(e),n=this.fullDayEventLayout.eventLayoutCells[d].getEventEndIndex(e);i===t?a=n+1:l=!1}return{position:"absolute",left:100/r*o+"%",top:`${s*_e.backgroundColorModeEventHeight+n}px`,width:100/r*(a-o)+"%",opacity:l?"1":"0"}}}ct.monthViewEventOffsetTop=26,dt([l()],ct.prototype,"eventItemRenderer",void 0),dt([l()],ct.prototype,"viewMode",void 0),dt([l()],ct.prototype,"calendarView",void 0),dt([l()],ct.prototype,"eventPreviewPopoverRenderer",void 0);var ht=function(e,t,i,n){var r,o=arguments.length,a=o<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,i,n);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,i,a):r(t,i))||a);return o>3&&a&&Object.defineProperty(t,i,a),a};class vt extends d{constructor(){super(...arguments),this.updateShowAllFlag=e=>{e.stopPropagation(),this.showAllEventsInDayOrWeekView=!0}}render(t){if(!this.showAllEventsInDayOrWeekView)return e("div",{tabIndex:0,role:"button",class:"more-button",onKeyDown:D(),onClick:this.updateShowAllFlag},`${t} More`)}resetShowAllFlag(){this.showAllEventsInDayOrWeekView=!1}}ht([l({writable:!0})],vt.prototype,"showAllEventsInDayOrWeekView",void 0),ht([c("watchViewModeChange")],vt.prototype,"resetShowAllFlag",null);var pt=function(e,t,i,n){var r,o=arguments.length,a=o<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,i,n);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,i,a):r(t,i))||a);return o>3&&a&&Object.defineProperty(t,i,a),a};class ft extends d{render(t){const i=t.findIndex((e=>e.isToday()))>=0;return e("div",{class:{"time-marker-container":!0,hidden:!i}},e("div",{class:"time-marker",style:{top:this.getTimeMarkerPosition()},ref:e=>this.timeMarkerRef=e},t.map((t=>e("div",{key:t.date,class:{active:t.isToday()}})))))}updateTimeLine(e){this.scrollToTargetTimeBlock(e),this.syncTimeMarkerPosition(e)}clearTimer(){clearInterval(this.timeMarkerPositionTimer)}updateTimeLineIfComponentAddBack(){this.syncTimeMarkerPosition(this.viewMode)}displayCurrentTimeBlockByDefault(){this.scrollToTargetTimeBlock(this.viewMode)}getTimeMarkerPosition(){const e=new Date;return(60*e.getHours()+e.getMinutes())/1440*100+"%"}syncTimeMarkerPosition(e){clearInterval(this.timeMarkerPositionTimer),"month"!==e&&(this.timeMarkerPositionTimer=setInterval((()=>{this.timeMarkerRef&&(this.timeMarkerRef.style.top=this.getTimeMarkerPosition())}),6e4))}scrollToTargetTimeBlock(e){"month"!==e&&setTimeout((()=>{const e=this.viewRenderer.getCalendarViewElementRef(),t=Math.max(0,this.getViewCenterPosition());e&&t&&e.scrollTo({top:t})}),16)}getViewCenterPosition(){const e=this.viewRenderer.getCalendarViewElementRef();if(e){const t=e.querySelector(".calendar-view-title-container").offsetHeight,i=Math.max(e.offsetHeight-t,0)/2,n=e.scrollHeight,r=16,o=Number(this.getTimeMarkerPosition().replace("%",""))/100*Math.max(n-r-t,0);if(!isNaN(i)&&o&&o>i)return o-i+r}return 0}}pt([l()],ft.prototype,"viewMode",void 0),pt([l()],ft.prototype,"viewRenderer",void 0),pt([c("watchViewModeChange")],ft.prototype,"updateTimeLine",null),pt([c("disconnectedCallback")],ft.prototype,"clearTimer",null),pt([c("connectedCallback")],ft.prototype,"updateTimeLineIfComponentAddBack",null),pt([c("componentDidLoad")],ft.prototype,"displayCurrentTimeBlockByDefault",null);var wt=function(e,t,i,n){var r,o=arguments.length,a=o<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,i,n);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,i,a):r(t,i))||a);return o>3&&a&&Object.defineProperty(t,i,a),a};class ut extends d{setPostOperationDate(e){this.postOperationDate=e}setDate(e,t){if(e.current!==this.postOperationDate)if(this.shouldSetCurrentDateToFirstDayOfMonth(e,t)){const t=e.current.toDate();t&&(t.setDate(1),this.setPostOperationDate(fe.from(t)))}else this.setPostOperationDate(fe.from(e.current.toDate()))}shouldSetCurrentDateToFirstDayOfMonth(e,t){return"month"===e.type&&"month"===(null==t?void 0:t.type)&&!e.current.equal(fe.from(new Date))}}wt([l({writable:!0})],ut.prototype,"postOperationDate",void 0),wt([c("watchCurrentPeriodChange")],ut.prototype,"setDate",null);var mt=function(e,t,i,n){var r,o=arguments.length,a=o<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,i,n);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,i,a):r(t,i))||a);return o>3&&a&&Object.defineProperty(t,i,a),a};class gt extends d{constructor(){super(...arguments),this.popoverHideObserver=null}render(e,t,i){return this.enabledEventPreview?this.renderPreviewPopover(e,i,t):this.eventItemRenderer.render(e,i,t)}renderPreviewPopover(t,i,n){return e("vega-popover",{placement:"day"===this.viewMode?"top":"right",alignment:"center",class:{"event-preview-popover":!0,block:!0},padding:"0",size:gt.SINGLE_EVENT_PREVIEW_WIDTH,ref:e=>{this.setPopoverHideObserver(e,t)}},e("div",{slot:"popover-content",class:"event-preview-popover-content"},this.eventItemRenderer.render(t,i,n)),e("div",{slot:"popover"},e("div",{class:"preview-container",ref:e=>{e?this.eventPreviewPopoverController.setEventPreviewContainerMap(t,n,e):this.eventPreviewPopoverController.deleteEventPreviewContainer(t,n)}})))}setPopoverHideObserver(e,t){e?(this.popoverHideObserver=new V((e=>t===e),(async()=>await e.hide())),L.register(B,this.popoverHideObserver)):this.popoverHideObserver&&L.unregister(B,this.popoverHideObserver)}}gt.SINGLE_EVENT_PREVIEW_WIDTH=400,mt([l()],gt.prototype,"host",void 0),mt([l()],gt.prototype,"renderer",void 0),mt([l()],gt.prototype,"viewMode",void 0),mt([l()],gt.prototype,"timeFormat",void 0),mt([l()],gt.prototype,"eventItemRenderer",void 0),mt([l()],gt.prototype,"enabledEventPreview",void 0),mt([l()],gt.prototype,"eventPreviewPopoverController",void 0);class bt extends d{constructor(){super(...arguments),this.singleEventPreviewContainerMap=new Map,this.groupEventsPreviewContainerMap=new Map}setEventPreviewContainerMap(e,t,i){(Array.isArray(e)?this.groupEventsPreviewContainerMap:this.singleEventPreviewContainerMap).set(this.generateMapKey(e,t),i)}deleteEventPreviewContainer(e,t){(Array.isArray(e)?this.groupEventsPreviewContainerMap:this.singleEventPreviewContainerMap).delete(this.generateMapKey(e,t))}getEventPreviewContainer(e,t,i){const n=i?this.groupEventsPreviewContainerMap:this.singleEventPreviewContainerMap,r=this.generateMapKey(e,t);if(n.has(r))return n.get(r);{const i=this.getDateString(t),r=Array.from(n.keys()).find((t=>t.includes(e.eventKey)&&t.endsWith(i)));if(r)return n.get(r)}}generateMapKey(e,t){const i=this.getDateString(t);return Array.isArray(e)?e.filter((e=>e)).map((e=>e.eventKey)).join("-")+i:e.eventKey+i}getDateString(e){return`-${e.year}-${e.month}-${e.date}`}}var xt=function(e,t,i,n){var r,o=arguments.length,a=o<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,i,n);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,i,a):r(t,i))||a);return o>3&&a&&Object.defineProperty(t,i,a),a};const yt=class{constructor(e){n(this,e),this.vegaChange=r(this,"vegaChange",7),this.change=r(this,"change",7),this.vegaEventClick=r(this,"vegaEventClick",7),this.eventClick=r(this,"eventClick",7),this.vegaDateDblClick=r(this,"vegaDateDblClick",7),this.dateDblClick=r(this,"dateDblClick",7),this.vegaDateClick=r(this,"vegaDateClick",7),this.dateClick=r(this,"dateClick",7),this.vegaMoreActionClick=r(this,"vegaMoreActionClick",7),this.moreActionClick=r(this,"moreActionClick",7),this.globalSlimmer={},this.translationSlimmer=new _,this.vegaComponentUsageRuntimeMetricsSlimmer=new p,this.renderer=new Z,this.switchPanelRenderer=new Q,this.viewRenderer=new ee,this.monthViewRenderer=new re,this.viewWithTimeRenderer=new ae,this.timeLineRenderer=new se,this.timeMarkerRenderer=new ft,this.monthEventRenderer=new Pe,this.currentPeriodController=new Oe,this.calendarViewController=new Ee,this.postOperationDateController=new ut,this.dayViewFullDayEventRenderer=new qe,this.eventPreviewPopoverController=new bt,this.dayViewFullDayEventMoreButtonRenderer=new vt,this.dayViewTimedEventRenderer=new ot,this.eventItemRenderer=new _e,this.dayViewEventLayoutRenderer=new Ze,this.fullDayEventLayoutRenderer=new ct,this.eventPreviewPopoverRenderer=new gt,this.calendarEventController=new We,this.eventResponsiveController=new Ye,this.changeEventEmitter=z(yt,m),this.eventClickEmitter=z(yt,y),this.dateDblClickEmitter=z(yt,k),this.moreActionClickEmitter=z(yt,C),this.dateClickEmitter=z(yt,R),this.changeEventPrevent=new S([m],(()=>this.switchPanelRenderer.getSwitchPanelRef())),this.timeFormatNotifySlimmer=H(yt,"timeFormat","watchTimeFormat"),this.showEventColorBarNotifySlimmer=H(yt,"showEventColorBar","watchShowEventColorBar"),this.postOperationDate=fe.from(new Date),this.showAllEventsInDayOrWeekView=!1,this.calendarEvents=[],this.viewMode="month",this.timeFormat="24-hour",this.isDateDisabled=()=>!1,this.showEventColorBar=!0,this.showSwitchView=!0,this.enableDateClick=!1,this.showWeekends=!0,this.enabledEventPreview=!0}watchCurrentPeriodChange(e,t){}watchViewModeChange(e){}watchEventsChange(e){}watchTimeFormat(e){}watchShowEventColorBar(e){}watchShowWeekendsChange(){}render(){return s(e(o,null,this.renderer.render()),this.host)}get host(){return a(this)}static get watchers(){return{currentPeriod:["watchCurrentPeriodChange"],viewMode:["watchViewModeChange"],events:["watchEventsChange"],timeFormat:["watchTimeFormat"],showEventColorBar:["watchShowEventColorBar"],showWeekends:["watchShowWeekendsChange"]}}};xt([f()],yt.prototype,"globalSlimmer",void 0),xt([v()],yt.prototype,"translationSlimmer",void 0),xt([v()],yt.prototype,"vegaComponentUsageRuntimeMetricsSlimmer",void 0),xt([v()],yt.prototype,"renderer",void 0),xt([v()],yt.prototype,"switchPanelRenderer",void 0),xt([v()],yt.prototype,"viewRenderer",void 0),xt([v()],yt.prototype,"monthViewRenderer",void 0),xt([v()],yt.prototype,"viewWithTimeRenderer",void 0),xt([v()],yt.prototype,"timeLineRenderer",void 0),xt([v()],yt.prototype,"timeMarkerRenderer",void 0),xt([v()],yt.prototype,"monthEventRenderer",void 0),xt([v()],yt.prototype,"currentPeriodController",void 0),xt([v()],yt.prototype,"calendarViewController",void 0),xt([v()],yt.prototype,"postOperationDateController",void 0),xt([v()],yt.prototype,"dayViewFullDayEventRenderer",void 0),xt([v()],yt.prototype,"eventPreviewPopoverController",void 0),xt([v()],yt.prototype,"dayViewFullDayEventMoreButtonRenderer",void 0),xt([v()],yt.prototype,"dayViewTimedEventRenderer",void 0),xt([v()],yt.prototype,"eventItemRenderer",void 0),xt([v()],yt.prototype,"dayViewEventLayoutRenderer",void 0),xt([v()],yt.prototype,"fullDayEventLayoutRenderer",void 0),xt([v()],yt.prototype,"eventPreviewPopoverRenderer",void 0),xt([v()],yt.prototype,"calendarEventController",void 0),xt([v()],yt.prototype,"eventResponsiveController",void 0),xt([v()],yt.prototype,"changeEventEmitter",void 0),xt([v()],yt.prototype,"eventClickEmitter",void 0),xt([v()],yt.prototype,"dateDblClickEmitter",void 0),xt([v()],yt.prototype,"moreActionClickEmitter",void 0),xt([v()],yt.prototype,"dateClickEmitter",void 0),xt([v()],yt.prototype,"changeEventPrevent",void 0),xt([v()],yt.prototype,"timeFormatNotifySlimmer",void 0),xt([v()],yt.prototype,"showEventColorBarNotifySlimmer",void 0),yt.style='.border-divider-top{border:1px solid rgba(var(--v-border-divider-secondary, 199, 217, 229, 1));border-left-width:0px;border-right-width:0px;border-bottom-width:0px}.border-divider-top.disabled{background-color:rgba(var(--v-bg-secondary, 245, 247, 247, 1))}.border-divider-left{border:1px solid rgba(var(--v-border-divider-secondary, 199, 217, 229, 1));border-top-width:0px;border-right-width:0px;border-bottom-width:0px}.border-divider-left.disabled{background-color:rgba(var(--v-bg-secondary, 245, 247, 247, 1))}.border-divider-right{border:1px solid rgba(var(--v-border-divider-secondary, 199, 217, 229, 1));border-top-width:0px;border-left-width:0px;border-bottom-width:0px}.border-divider-bottom{border:1px solid rgba(var(--v-border-divider-secondary, 199, 217, 229, 1));border-top-width:0px;border-left-width:0px;border-right-width:0px}:host{display:flex;flex-direction:column;border-radius:12px;border:1px solid rgba(var(--v-border-divider, 171, 198, 216, 1));background-color:rgba(var(--v-bg-primary, 252, 252, 252, 1));overflow:hidden;width:100%;height:100%;box-sizing:border-box;max-height:1966px}.calendar-switch-panel{padding:24px;border-bottom-width:1px;border-top-width:0px;border-left-width:0px;border-right-width:0px;border-style:solid;border-color:rgba(var(--v-border-color-divider, 171, 198, 216, 1));flex-shrink:0;width:100%;box-sizing:border-box}.calendar-switch-panel .calendar-date-switch-container{display:flex;gap:8px;align-items:center;flex-direction:row}.calendar-switch-panel .calendar-view-switch-container{display:flex;gap:16px;align-items:center;flex-direction:row}.calendar-switch-panel .calendar-current-date{padding-left:8px}.calendar-view{width:100%;position:relative;flex-grow:1;overflow-y:auto;overflow-x:hidden;--calendar-weekday-columns:7}.calendar-view.calendar-hide-weekends{--calendar-weekday-columns:5}.calendar-view-month .calendar-view-month-container{width:100%;display:grid;min-height:100%;grid-template-rows:43px repeat(6, minmax(64px, 1fr))}.calendar-view-month .calendar-view-title{background-color:rgba(var(--v-bg-primary, 252, 252, 252, 1));top:0;left:0;z-index:62}.calendar-view-month .calendar-view-title div{padding-top:12px;padding-bottom:12px;color:rgba(var(--v-text-secondary, 107, 116, 125, 1));font-family:"Inter", sans-serif;font-size:14px;font-weight:700;line-height:18px;text-align:center}@media screen and (min-width: 768px) and (max-width: 1023px){.calendar-view-month .calendar-view-title div{font-family:"Inter", sans-serif;font-size:14px;font-weight:700;line-height:18px}}@media screen and (min-width: 1024px) and (max-width: 1439px){.calendar-view-month .calendar-view-title div{font-family:"Inter", sans-serif;font-size:14px;font-weight:700;line-height:18px}}@media screen and (min-width: 1440px) and (max-width: 9999px){.calendar-view-month .calendar-view-title div{font-family:"Inter", sans-serif;font-size:14px;font-weight:700;line-height:18px}}.calendar-view-month .calendar-view-row{position:relative;display:grid;grid-template-rows:1fr;grid-template-columns:repeat(var(--calendar-weekday-columns), minmax(64px, 1fr))}.calendar-view-month .calendar-view-row.calendar-view-title{position:sticky}.calendar-view-month .calendar-view-row:last-child{border-bottom-width:0px}.calendar-view-month .calendar-view-row .row-cell{overflow:hidden;display:flex;flex-direction:column;justify-content:space-between}.calendar-view-month .calendar-view-row .row-cell:last-child{border-right-width:0px}.calendar-view-month .calendar-view-row .row-cell .date{padding-top:4px;padding-bottom:4px;padding-right:12px;padding-left:8px}.calendar-view-month .calendar-view-row .row-cell .date>div{display:inline-block;color:rgba(var(--v-text-secondary, 107, 116, 125, 1));font-family:"Inter", sans-serif;font-size:14px;font-weight:400;line-height:18px}@media screen and (min-width: 768px) and (max-width: 1023px){.calendar-view-month .calendar-view-row .row-cell .date>div{font-family:"Inter", sans-serif;font-size:14px;font-weight:400;line-height:18px}}@media screen and (min-width: 1024px) and (max-width: 1439px){.calendar-view-month .calendar-view-row .row-cell .date>div{font-family:"Inter", sans-serif;font-size:14px;font-weight:400;line-height:18px}}@media screen and (min-width: 1440px) and (max-width: 9999px){.calendar-view-month .calendar-view-row .row-cell .date>div{font-family:"Inter", sans-serif;font-size:14px;font-weight:400;line-height:18px}}.calendar-view-month .calendar-view-row .row-cell .date .month-block{margin-right:2px}.calendar-view-month .calendar-view-row .row-cell .date .grid-col{text-align:center;border-top-left-radius:9999px;border-bottom-left-radius:9999px;border-top-right-radius:9999px;border-bottom-right-radius:9999px;cursor:pointer;width:18px;height:18px;line-height:18px}.calendar-view-month .calendar-view-row .row-cell .date .grid-col:hover{background-color:rgba(var(--v-bg-action-secondary-hover, 4, 112, 236, 0.1))}.calendar-view-month .calendar-view-row .row-cell .date .grid-col:active{background-color:rgba(var(--v-bg-action-secondary-active, 29, 65, 195, 0.1))}.calendar-view-month .calendar-view-row .row-cell .date .grid-col:focus-visible{outline:2px solid rgba(var(--v-border-color-action, 19, 98, 226, 1));outline-offset:2px}.calendar-view-month .calendar-view-row .row-cell.current-month-day .date>div{color:rgba(var(--v-text-primary, 32, 54, 69, 1))}.calendar-view-month .calendar-view-row .row-cell.disabled{background-color:rgba(var(--v-bg-secondary, 245, 247, 247, 1))}.calendar-view-month .calendar-view-row .row-cell.disabled .date>div{color:rgba(var(--v-text-disabled, 176, 180, 181, 1))}.calendar-view-month .calendar-view-row .row-cell.active .date .grid-col{background-color:rgba(var(--v-bg-action, 19, 98, 226, 1));border-top-left-radius:9999px;border-bottom-left-radius:9999px;color:rgba(var(--v-text-on-action, 252, 252, 252, 1))}.calendar-view-month .calendar-view-row .row-cell.active .date .grid-col:hover{background-color:rgba(var(--v-bg-action-hover, 4, 112, 236, 1))}.calendar-view-month .calendar-view-row .row-cell.active .date .grid-col:active{background-color:rgba(var(--v-bg-action-active, 29, 65, 195, 1))}.calendar-view-month .calendar-view-row .row-cell.active .date .grid-col:focus-visible{outline:2px solid rgba(var(--v-border-color-action, 19, 98, 226, 1));outline-offset:2px}.calendar-view-container{width:100%}.calendar-view-container .calendar-view-title-container{background-color:rgba(var(--v-bg-primary, 252, 252, 252, 1));position:sticky;top:0;left:0;z-index:62}.calendar-view-container .calendar-view-row{box-sizing:border-box;width:100%;display:flex;flex-direction:row}.calendar-view-container .calendar-view-row .time-line,.calendar-view-container .calendar-view-row .time-line-empty,.calendar-view-container .calendar-view-row .time-line-all{width:72px;text-align:right;padding-right:8px;box-sizing:border-box;font-family:"Inter", sans-serif;font-size:14px;font-weight:400;line-height:18px;color:rgba(var(--v-text-primary, 32, 54, 69, 1));flex-shrink:0}@media screen and (min-width: 768px) and (max-width: 1023px){.calendar-view-container .calendar-view-row .time-line,.calendar-view-container .calendar-view-row .time-line-empty,.calendar-view-container .calendar-view-row .time-line-all{font-family:"Inter", sans-serif;font-size:14px;font-weight:400;line-height:18px}}@media screen and (min-width: 1024px) and (max-width: 1439px){.calendar-view-container .calendar-view-row .time-line,.calendar-view-container .calendar-view-row .time-line-empty,.calendar-view-container .calendar-view-row .time-line-all{font-family:"Inter", sans-serif;font-size:14px;font-weight:400;line-height:18px}}@media screen and (min-width: 1440px) and (max-width: 9999px){.calendar-view-container .calendar-view-row .time-line,.calendar-view-container .calendar-view-row .time-line-empty,.calendar-view-container .calendar-view-row .time-line-all{font-family:"Inter", sans-serif;font-size:14px;font-weight:400;line-height:18px}}.calendar-view-container .calendar-view-title{width:100%}.calendar-view-container .calendar-view-title>div{padding:12px;padding-bottom:8px;color:rgba(var(--v-text-secondary, 107, 116, 125, 1));font-family:"Inter", sans-serif;font-size:14px;font-weight:700;line-height:18px;text-align:center;display:flex;flex-direction:column;gap:8px}@media screen and (min-width: 768px) and (max-width: 1023px){.calendar-view-container .calendar-view-title>div{font-family:"Inter", sans-serif;font-size:14px;font-weight:700;line-height:18px}}@media screen and (min-width: 1024px) and (max-width: 1439px){.calendar-view-container .calendar-view-title>div{font-family:"Inter", sans-serif;font-size:14px;font-weight:700;line-height:18px}}@media screen and (min-width: 1440px) and (max-width: 9999px){.calendar-view-container .calendar-view-title>div{font-family:"Inter", sans-serif;font-size:14px;font-weight:700;line-height:18px}}.calendar-view-container .calendar-view-title .week-day{color:rgba(var(--v-text-primary, 32, 54, 69, 1));font-family:"Inter", sans-serif;font-size:20px;font-weight:500;line-height:24px;letter-spacing:0px}@media screen and (min-width: 768px) and (max-width: 1023px){.calendar-view-container .calendar-view-title .week-day{font-family:"Inter", sans-serif;font-size:20px;font-weight:500;line-height:24px;letter-spacing:0px}}@media screen and (min-width: 1024px) and (max-width: 1439px){.calendar-view-container .calendar-view-title .week-day{font-family:"Inter", sans-serif;font-size:20px;font-weight:500;line-height:24px;letter-spacing:0px}}@media screen and (min-width: 1440px) and (max-width: 9999px){.calendar-view-container .calendar-view-title .week-day{font-family:"Inter", sans-serif;font-size:20px;font-weight:500;line-height:24px;letter-spacing:0px}}.calendar-view-container .calendar-view-title .active div{color:rgba(var(--v-text-link, 19, 98, 226, 1))}.calendar-view-container .calendar-view-event-all-container{align-items:center}.calendar-view-container .calendar-view-event-all{display:grid;grid-template-rows:1fr;flex-grow:1;min-height:18px}.calendar-view-container .calendar-view-day-container .time-line{display:grid;grid-template-rows:16px repeat(24, minmax(74px, 1fr))}.calendar-view-container .calendar-view-day-container .time-line .time-text{margin-top:-9px}.calendar-view-container .calendar-view-day-container .calendar-view-content{width:100%}.calendar-view-container .calendar-view-day-container .calendar-view-content .grid-col{display:grid;grid-template-rows:16px repeat(24, minmax(74px, 1fr));grid-template-columns:minmax(64px, 1fr)}.calendar-view-container .calendar-view-day-container .calendar-view-content .grid-col>.border-divider-top:first-child{border-top-width:0px}.calendar-view-container .calendar-view-content-container{width:100%;position:relative}.calendar-view-week .calendar-view-container{min-height:100%}.calendar-view-week .calendar-view-container .calendar-view-title{display:grid;grid-template-rows:1fr;grid-template-columns:repeat(var(--calendar-weekday-columns), minmax(64px, 1fr))}.calendar-view-week .calendar-view-container .calendar-view-event-all{grid-template-columns:repeat(var(--calendar-weekday-columns), minmax(64px, 1fr))}.calendar-view-week .calendar-view-container .calendar-view-day-container .calendar-view-content{display:grid;grid-template-columns:repeat(var(--calendar-weekday-columns), minmax(64px, 1fr))}.calendar-view-week .time-marker-container .time-marker{display:grid;grid-template-columns:repeat(var(--calendar-weekday-columns), minmax(64px, 1fr))}.calendar-view-week .day-event-container{display:grid;grid-template-columns:repeat(var(--calendar-weekday-columns), minmax(64px, 1fr))}.calendar-view-day .calendar-view-container{min-height:100%}.time-marker-container{position:absolute;min-width:100%;left:0;top:16px;height:calc(100% - 16px);pointer-events:none}.time-marker-container.hidden{display:none}.time-marker-container .time-marker{position:absolute;height:2px;display:grid;min-width:100%;left:0;top:0;z-index:61}.time-marker-container .time-marker div{width:100%;height:2px;background-color:rgba(var(--v-bg-status-error, 255, 110, 139, 1));opacity:0.3}.time-marker-container .time-marker div.active{opacity:1;position:relative}.time-marker-container .time-marker div.active::before{content:"";display:block;border-top-left-radius:9999px;border-bottom-left-radius:9999px;border-top-right-radius:9999px;border-bottom-right-radius:9999px;position:absolute;width:8px;height:8px;background-color:rgba(var(--v-bg-status-error, 255, 110, 139, 1));top:-3px;left:-4px}.day-event-container{position:absolute;min-width:100%;left:0;top:16px;height:calc(100% - 16px);pointer-events:none}.day-event-container .day-event-col{height:100%;overflow:hidden}.day-event-container vega-calendar-event{pointer-events:auto;height:100%}.calendar-view-month .month-event-row{position:absolute;width:100%;overflow:hidden;height:calc(100% - 26px);left:0;bottom:0}.calendar-view-month .events-container{width:100%;box-sizing:border-box;overflow:hidden;padding:2px;display:flex;flex-direction:column;gap:2px;justify-content:space-between;flex-grow:1}.calendar-view-month .events-container .event-list{display:flex;flex-direction:column;gap:2px;flex-grow:1}.calendar-view-month .events-container .event-list .month-event-block{box-sizing:border-box;padding-left:2px;padding-right:3px}.calendar-view-month .events-container .month-event-more .more-button{display:inline-block;height:16px;font-family:"Inter", sans-serif;font-size:12px;font-weight:700;line-height:16px;letter-spacing:0px;color:rgba(var(--v-text-link, 19, 98, 226, 1));cursor:pointer;border-radius:2px}@media screen and (min-width: 768px) and (max-width: 1023px){.calendar-view-month .events-container .month-event-more .more-button{font-family:"Inter", sans-serif;font-size:12px;font-weight:700;line-height:16px;letter-spacing:0px}}@media screen and (min-width: 1024px) and (max-width: 1439px){.calendar-view-month .events-container .month-event-more .more-button{font-family:"Inter", sans-serif;font-size:12px;font-weight:700;line-height:16px;letter-spacing:0px}}@media screen and (min-width: 1440px) and (max-width: 9999px){.calendar-view-month .events-container .month-event-more .more-button{font-family:"Inter", sans-serif;font-size:12px;font-weight:700;line-height:16px;letter-spacing:0px}}.calendar-view-month .events-container .month-event-more .more-button:focus-visible{outline:2px solid rgba(var(--v-border-color-action, 19, 98, 226, 1));outline-offset:0px}.calendar-view-container .calendar-view-event-all{position:relative}.calendar-view-container .calendar-view-event-all .placeholder-block{padding-top:2px;padding-bottom:2px;box-sizing:content-box}.calendar-view-container .calendar-view-event-all .placeholder-block span{display:none}.calendar-view-container .calendar-view-event-all .day-event-block{padding-top:2px;padding-right:2px;box-sizing:border-box;padding-left:3px}.calendar-view-container .calendar-view-event-all .more-button{display:inline-block;height:16px;font-family:"Inter", sans-serif;font-size:12px;font-weight:700;line-height:16px;letter-spacing:0px;color:rgba(var(--v-text-link, 19, 98, 226, 1));cursor:pointer;border-radius:2px;margin-left:2px;padding:2px}@media screen and (min-width: 768px) and (max-width: 1023px){.calendar-view-container .calendar-view-event-all .more-button{font-family:"Inter", sans-serif;font-size:12px;font-weight:700;line-height:16px;letter-spacing:0px}}@media screen and (min-width: 1024px) and (max-width: 1439px){.calendar-view-container .calendar-view-event-all .more-button{font-family:"Inter", sans-serif;font-size:12px;font-weight:700;line-height:16px;letter-spacing:0px}}@media screen and (min-width: 1440px) and (max-width: 9999px){.calendar-view-container .calendar-view-event-all .more-button{font-family:"Inter", sans-serif;font-size:12px;font-weight:700;line-height:16px;letter-spacing:0px}}.calendar-view-container .calendar-view-event-all .more-button:focus-visible{outline:2px solid rgba(var(--v-border-color-action, 19, 98, 226, 1));outline-offset:0px}.calendar-view-container .calendar-view-event-all .event-all-col{display:flex;flex-direction:column;justify-content:space-between;align-items:flex-start}.calendar-view-container .day-event-col{position:relative}.calendar-view-container .day-event-col .time-event-block{box-sizing:border-box;padding-right:8px;padding-bottom:2px;padding-top:3px}.calendar-view-container .day-event-col .time-event-block vega-calendar-event.bg-shadow::part(event-container):not(:focus){outline:2px solid rgba(var(--v-bg-primary, 252, 252, 252, 1))}.calendar-view-container .day-event-col .time-event-block:focus-within{z-index:60 !important}.calendar-event-slot-container{display:none}.event-preview-popover{height:100%}.event-preview-popover.block{display:block}.event-preview-popover .event-preview-popover-content{height:100%}';var kt=function(e,t,i,n){var r,o=arguments.length,a=o<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,i,n);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,i,a):r(t,i))||a);return o>3&&a&&Object.defineProperty(t,i,a),a};class Ct extends d{getEventTitleContainerRef(){return this.eventTitleContainerRef}getSlotContainerRef(){return this.slotContainerRef}render(){return e(t,null,this.injectBackgroundColorStyle(),this.calendarEventRender())}calendarEventRender(){return this.calendarEvent.isAllDayEvent||this.calendarEvent.isGroupEvent()?this.renderBackgroundModeEvent():this.renderNormalEvent()}renderBackgroundModeEvent(){const t=this.calendarEvent.disabled;return e("div",{role:"button",tabIndex:0,class:{"slot-container":this.slotMode,"background-color-mode":!0,"event-bg-color":!t,"bg-disabled":t},ref:e=>this.slotContainerRef=e},this.slotMode?this.getSlotElement():this.calendarEvent.title)}renderNormalEvent(){const{variant:t,disabled:i}=this.calendarEvent,n=t||"primary",r=!this.host.classList.contains("day-event"),o={"slot-container":this.slotMode,"event-container":!0,disabled:i,[n]:!0};if(r)return e("div",{role:"button",tabIndex:0,class:o,ref:e=>this.slotContainerRef=e},!this.slotMode&&this.renderEventStatus(),this.slotMode?this.getSlotElement():this.defaultNormalMonthEventContentRender());{const t=this.calendarEvent.getEventDuration();return e("div",{part:"event-container",class:Object.assign(Object.assign({},o),{vertical:t>30,"duration-half-an-hour":30===t,"event-bg-color":!i,"bg-disabled":i}),role:"button",tabIndex:0,ref:e=>this.slotContainerRef=e},!this.slotMode&&this.renderEventStatus(),e("div",{class:"cover-block"}),this.slotMode?this.getSlotElement():this.defaultNormalTimedEventContentRender(t))}}renderEventStatus(){if(this.showColorBar){const t=this.calendarEvent.disabled;return e("div",{class:{"event-status":!0,"event-bg-color":!t,"bg-disabled":t}},e("span",{class:{stripe:"secondary"===this.calendarEvent.variant}}))}}defaultNormalMonthEventContentRender(){const{startTime:t,title:i}=this.calendarEvent;return e("div",{class:"event-title"},`${ce(this.timeFormat,t)} ${i}`)}defaultNormalTimedEventContentRender(t){const{startTime:i,endTime:n,title:r}=this.calendarEvent;return e("div",{class:"event-content"},e("div",{class:{"event-title":!0,"title-word-wrap":t>30},ref:e=>this.eventTitleContainerRef=e},r),e("div",{class:"event-time"},e("vega-icon",{size:"size-12",icon:j.getIconKey("clock-three")}),e("span",null,`${ce(this.timeFormat,i)} - ${ce(this.timeFormat,n)}`)))}getSlotElement(){if(!this.calendarEvent.isRepeatEvent)return e("slot",null)}injectBackgroundColorStyle(){return e("style",{nonce:Y.nonce},ke(this.calendarEvent.color))}}j.register({"clock-three":{icon:'<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 512 512">\x3c!--! Font Awesome Pro 6.3.0 by @fontawesome - https://fontawesome.com License - https://fontawesome.com/license (Commercial License) Copyright 2023 Fonticons, Inc. --\x3e<path fill="currentColor" d="M464 256A208 208 0 1 1 48 256a208 208 0 1 1 416 0zM0 256a256 256 0 1 0 512 0A256 256 0 1 0 0 256zM232 120V256c0 13.3 10.7 24 24 24H360c13.3 0 24-10.7 24-24s-10.7-24-24-24H280V120c0-13.3-10.7-24-24-24s-24 10.7-24 24z"/></svg>'}}),kt([l()],Ct.prototype,"host",void 0),kt([l()],Ct.prototype,"timeFormat",void 0),kt([l()],Ct.prototype,"calendarEvent",void 0),kt([l()],Ct.prototype,"slotMode",void 0),kt([l()],Ct.prototype,"showColorBar",void 0);var Rt=function(e,t,i,n){var r,o=arguments.length,a=o<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,i,n);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,i,a):r(t,i))||a);return o>3&&a&&Object.defineProperty(t,i,a),a};class jt extends K{constructor(){super({parent:()=>this.host["data-calendar-ref"],subStates:[{subStateName:"timeFormat",parentStateName:"timeFormat"},{subStateName:"showColorBar",parentStateName:"showEventColorBar"}]})}}Rt([l({writable:!0})],jt.prototype,"timeFormat",void 0),Rt([l({writable:!0})],jt.prototype,"showColorBar",void 0);class Dt extends d{setVerticalTitleMaxHeight(){const e=this.renderer.getEventTitleContainerRef();if(e&&e.classList.contains("title-word-wrap")){const t=window.getComputedStyle(e),i=q(t.height),n=q(t.lineHeight),r=Math.max(Math.floor(i/n),1);e.style.maxHeight=r*n+"px"}}}!function(e,t,i,n){var r,o=arguments.length,a=o<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,i,n);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,i,a):r(t,i))||a);o>3&&a&&Object.defineProperty(t,i,a)}([l()],Dt.prototype,"renderer",void 0);var Et=function(e,t,i,n){var r,o=arguments.length,a=o<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,i,n);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,i,a):r(t,i))||a);return o>3&&a&&Object.defineProperty(t,i,a),a};class zt extends d{findTheCalendarEventSlot(){if(this.calendarEvent){const{event:e}=this.calendarEvent,t=this.getParentCalendarElement();if(t){const i=t.querySelector(`vega-calendar-event-slot[event-key='${e.key}']`);i&&(this.slotMode=!0,this.matchSlotElement=i)}}}appendTheRepeatEventSlotToContainer(){const e=this.renderer.getSlotContainerRef();if(this.slotMode&&e&&this.matchSlotElement&&(this.calendarEvent.isRepeatEvent||this.isPopoverContent())){const t=this.matchSlotElement.cloneNode(!0);t.removeAttribute("slot"),e.querySelector("vega-calendar-event-slot")||e.appendChild(t)}}getParentCalendarElement(){return this.host["data-calendar-ref"]}isPopoverContent(){return this.host.classList.contains("calendar-event-in-popover")}}Et([l()],zt.prototype,"host",void 0),Et([l()],zt.prototype,"calendarEvent",void 0),Et([l({writable:!0})],zt.prototype,"slotMode",void 0),Et([l()],zt.prototype,"renderer",void 0),Et([c("componentWillLoad")],zt.prototype,"findTheCalendarEventSlot",null),Et([c("componentDidLoad")],zt.prototype,"appendTheRepeatEventSlotToContainer",null);var Ot=function(e,t,i,n){var r,o=arguments.length,a=o<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,i,n);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,i,a):r(t,i))||a);return o>3&&a&&Object.defineProperty(t,i,a),a};const Mt=class{constructor(e){n(this,e),this.globalSlimmer={},this.pageResizeObserverSlimmer=new F({target:()=>this.host,callback:()=>this.titleMaxHeightController.setVerticalTitleMaxHeight()}),this.vegaComponentUsageRuntimeMetricsSlimmer=new p,this.renderer=new Ct,this.slotController=new zt,this.subStateController=new jt,this.titleMaxHeightController=new Dt,this.timeFormat="24-hour",this.slotMode=!1,this.showColorBar=!0}render(){return U(e("slot",null)),s(e(o,null,this.calendarEvent?this.renderer.render():null),this.host)}get host(){return a(this)}};Ot([f()],Mt.prototype,"globalSlimmer",void 0),Ot([v()],Mt.prototype,"pageResizeObserverSlimmer",void 0),Ot([v()],Mt.prototype,"vegaComponentUsageRuntimeMetricsSlimmer",void 0),Ot([v()],Mt.prototype,"renderer",void 0),Ot([v()],Mt.prototype,"slotController",void 0),Ot([v()],Mt.prototype,"subStateController",void 0),Ot([v()],Mt.prototype,"titleMaxHeightController",void 0),Mt.style='.bg-disabled{background-color:rgba(var(--v-bg-disabled, 176, 180, 181, 1))}:host{display:block;box-sizing:border-box;width:100%}:host .background-color-mode{border-radius:2px;color:rgba(var(--v-text-black, 32, 54, 69, 1));font-family:"Inter", sans-serif;font-size:12px;font-weight:700;line-height:16px;letter-spacing:0px;cursor:pointer;overflow:hidden;white-space:nowrap}@media screen and (min-width: 768px) and (max-width: 1023px){:host .background-color-mode{font-family:"Inter", sans-serif;font-size:12px;font-weight:700;line-height:16px;letter-spacing:0px}}@media screen and (min-width: 1024px) and (max-width: 1439px){:host .background-color-mode{font-family:"Inter", sans-serif;font-size:12px;font-weight:700;line-height:16px;letter-spacing:0px}}@media screen and (min-width: 1440px) and (max-width: 9999px){:host .background-color-mode{font-family:"Inter", sans-serif;font-size:12px;font-weight:700;line-height:16px;letter-spacing:0px}}:host .background-color-mode:not(.slot-container){padding-left:8px;padding-right:8px}:host .background-color-mode:focus{outline:2px solid rgba(var(--v-border-color-action, 19, 98, 226, 1));outline-offset:0px}:host .event-container{display:block;width:100%;border-radius:4px;cursor:pointer;box-sizing:border-box;overflow:hidden}:host .background-color-mode.slot-container{height:16px;line-height:16px}:host ::slotted(vega-calendar-event-slot){position:relative;pointer-events:none}:host(.month-event) .event-container{display:flex;flex-direction:row;gap:4px;align-items:center;min-height:16px}:host(.month-event) .event-container:not(.slot-container){padding-left:2px;padding-right:2px}:host(.month-event) .event-container .event-status{width:8px;height:8px;box-sizing:border-box;border-top-left-radius:9999px;border-bottom-left-radius:9999px;border-top-right-radius:9999px;border-bottom-right-radius:9999px;margin-left:2px;flex-shrink:0}:host(.month-event) .event-container .event-status span{display:none;width:100%;height:100%;border-top-left-radius:9999px;border-bottom-left-radius:9999px;border-top-right-radius:9999px;border-bottom-right-radius:9999px}:host(.month-event) .event-container .event-title{font-family:"Inter", sans-serif;font-size:12px;font-weight:400;line-height:16px;color:rgba(var(--v-text-primary, 32, 54, 69, 1));flex-grow:1;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}@media screen and (min-width: 768px) and (max-width: 1023px){:host(.month-event) .event-container .event-title{font-family:"Inter", sans-serif;font-size:12px;font-weight:400;line-height:16px}}@media screen and (min-width: 1024px) and (max-width: 1439px){:host(.month-event) .event-container .event-title{font-family:"Inter", sans-serif;font-size:12px;font-weight:400;line-height:16px}}@media screen and (min-width: 1440px) and (max-width: 9999px){:host(.month-event) .event-container .event-title{font-family:"Inter", sans-serif;font-size:12px;font-weight:400;line-height:16px}}:host(.month-event) .event-container.secondary .event-status span{display:block;background-size:4px 4px;opacity:0.8}:host(.month-event) .event-container.tertiary .event-status{padding:1px}:host(.month-event) .event-container.tertiary .event-status span{display:block;background-color:rgba(var(--v-bg-primary, 252, 252, 252, 1))}:host(.month-event) .event-container.disabled .event-status{background-color:rgba(var(--v-bg-disabled, 176, 180, 181, 1))}:host(.month-event) .event-container:hover{background-color:rgba(var(--v-bg-action-secondary-hover, 4, 112, 236, 0.1))}:host(.month-event) .event-container:active{background-color:rgba(var(--v-bg-action-secondary-active, 29, 65, 195, 0.1))}:host(.month-event) .event-container:focus{outline:2px solid rgba(var(--v-border-color-action, 19, 98, 226, 1));outline-offset:0px}:host(.day-event) .event-container{position:relative}:host(.day-event) .event-container:not(.slot-container){padding-left:8px;padding-right:8px}:host(.day-event) .event-container .event-status{position:absolute;width:4px;height:100%;left:0;top:0;z-index:1}:host(.day-event) .event-container .event-status span{display:none}:host(.day-event) .event-container .cover-block{position:absolute;height:100%;width:100%;background-color:rgba(var(--v-bg-primary, 252, 252, 252, 1));border-radius:4px;left:0;top:0;opacity:0.7}:host(.day-event) .event-container .event-content,:host(.day-event) .event-container .event-time{display:flex;flex-direction:row;align-items:center}:host(.day-event) .event-container .event-content{gap:8px;position:relative;height:100%;box-sizing:border-box}:host(.day-event) .event-container .event-time{gap:4px;color:rgba(var(--v-text-primary, 32, 54, 69, 1));font-family:"Inter", sans-serif;font-size:12px;font-weight:400;line-height:16px}@media screen and (min-width: 768px) and (max-width: 1023px){:host(.day-event) .event-container .event-time{font-family:"Inter", sans-serif;font-size:12px;font-weight:400;line-height:16px}}@media screen and (min-width: 1024px) and (max-width: 1439px){:host(.day-event) .event-container .event-time{font-family:"Inter", sans-serif;font-size:12px;font-weight:400;line-height:16px}}@media screen and (min-width: 1440px) and (max-width: 9999px){:host(.day-event) .event-container .event-time{font-family:"Inter", sans-serif;font-size:12px;font-weight:400;line-height:16px}}:host(.day-event) .event-container .event-time vega-icon{flex-shrink:0}:host(.day-event) .event-container .event-time span{white-space:nowrap}:host(.day-event) .event-container .event-title{color:rgba(var(--v-text-primary, 32, 54, 69, 1));font-family:"Inter", sans-serif;font-size:12px;font-weight:700;line-height:16px;letter-spacing:0px}@media screen and (min-width: 768px) and (max-width: 1023px){:host(.day-event) .event-container .event-title{font-family:"Inter", sans-serif;font-size:12px;font-weight:700;line-height:16px;letter-spacing:0px}}@media screen and (min-width: 1024px) and (max-width: 1439px){:host(.day-event) .event-container .event-title{font-family:"Inter", sans-serif;font-size:12px;font-weight:700;line-height:16px;letter-spacing:0px}}@media screen and (min-width: 1440px) and (max-width: 9999px){:host(.day-event) .event-container .event-title{font-family:"Inter", sans-serif;font-size:12px;font-weight:700;line-height:16px;letter-spacing:0px}}:host(.day-event) .event-container .event-title.title-word-wrap{overflow:hidden}:host(.day-event) .event-container .event-title:not(.title-word-wrap){white-space:nowrap}:host(.day-event) .event-container.duration-half-an-hour{padding-top:8px;padding-bottom:8px}:host(.day-event) .event-container.vertical{height:100%}:host(.day-event) .event-container.vertical .event-content{flex-direction:column;align-items:flex-start;gap:4px;padding-top:8px;padding-bottom:8px}:host(.day-event) .event-container.secondary .event-status span,:host(.day-event) .event-container.tertiary .event-status span{display:block;position:absolute;border-top-left-radius:4px;border-bottom-left-radius:4px}:host(.day-event) .event-container.secondary .cover-block,:host(.day-event) .event-container.tertiary .cover-block{width:calc(100% - 2px);height:calc(100% - 2px);top:1px;left:1px}:host(.day-event) .event-container.secondary .event-status span{width:100%;height:100%;top:0px;left:0px;background-size:4px 4px;opacity:0.8}:host(.day-event) .event-container.secondary .cover-block{opacity:0.9}:host(.day-event) .event-container.tertiary .event-status span{background-color:rgba(var(--v-bg-primary, 252, 252, 252, 1));width:2px;height:calc(100% - 2px);top:1px;left:1px}:host(.day-event) .event-container.tertiary .cover-block{opacity:1}:host(.day-event) .event-container.disabled{background-color:rgba(var(--v-bg-disabled, 176, 180, 181, 1))}:host(.day-event) .event-container.disabled .event-status{background-color:rgba(var(--v-bg-disabled, 176, 180, 181, 1))}:host(.day-event) .event-container:focus{outline:2px solid rgba(var(--v-border-color-action, 19, 98, 226, 1));outline-offset:0px}:host(.day-event) .slot-container{min-height:16px}:host(.month-event.calendar-event-large-size) .background-color-mode{border-radius:4px}:host(.month-event.calendar-event-large-size) .background-color-mode:not(.slot-container){padding-top:4px;padding-bottom:4px}:host(.month-event.calendar-event-large-size) .event-container:not(.slot-container){padding-top:4px;padding-bottom:4px}:host(.month-event.calendar-event-large-size) .slot-container{height:24px;display:flex;align-items:center;line-height:24px}.stripe{background-image:linear-gradient(-45deg, transparent 25%, rgba(var(--v-bg-primary, 252, 252, 252, 1)) 25% 50%, transparent 50% 75%, rgba(var(--v-bg-primary, 252, 252, 252, 1)) 75% 100%)}';var Pt=function(e,t,i,n){var r,o=arguments.length,a=o<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,i,n);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,i,a):r(t,i))||a);return o>3&&a&&Object.defineProperty(t,i,a),a};class St extends d{registerEventPreviewUpdateObserver(){w.addUniqueObserverToNode(this.host,T,(e=>{this.previewPayload=e,this.currentEvent=e.event})),w.addUniqueObserverToNode(this.host,$,(()=>{this.currentEvent=null}))}unregisterEventPreviewUpdateObserver(){w.removeUniqueObserverFromNode(this.host,T),w.removeUniqueObserverFromNode(this.host,$)}}Pt([l()],St.prototype,"host",void 0),Pt([l({writable:!0})],St.prototype,"currentEvent",void 0),Pt([l({writable:!0})],St.prototype,"previewPayload",void 0),Pt([c("connectedCallback")],St.prototype,"registerEventPreviewUpdateObserver",null),Pt([c("disconnectedCallback")],St.prototype,"unregisterEventPreviewUpdateObserver",null);var It=function(e,t,i,n){var r,o=arguments.length,a=o<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,i,n);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,i,a):r(t,i))||a);return o>3&&a&&Object.defineProperty(t,i,a),a};class $t extends d{render(){return this.currentEvent&&e("vega-box",{class:"event-preview"},this.injectBackgroundColorStyle(),this.renderActions(),e("vega-box",{class:"preview-content"},e("vega-flex",{gap:"size-16",direction:"col"},this.renderBasicFields(),this.renderDivider(),e("slot",{name:"event-preview-additional-fields"}))))}renderActions(){return e("vega-flex",{justifyContent:"end",class:"preview-actions"},e("vega-button-circle",{icon:j.getIconKey("close"),color:"text-primary",variant:"icon-only",onVegaClick:()=>{L.notify(B,this.currentEvent)}}))}renderBasicFields(){const i=this.currentEvent;return e(t,null,e("vega-flex",{alignItems:"start",gap:"size-16"},this.renderEventTitle()),e("vega-flex",{alignItems:"start",gap:"size-12"},e("vega-icon",{icon:j.getIconKey("clock"),color:"text-secondary"}),e("vega-flex",{direction:"col",gap:"size-4"},e("vega-font",{variant:"font-footnote1-long",color:"text-primary"},i.generateDateTimeString(this.previewPayload.targetCalendarViewDate,this.previewPayload.timeFormat)),i.isRepeatEvent&&e("vega-font",{variant:"font-footnote1-long",color:"text-primary"},i.generateRepeatString()))))}renderEventTitle(){const i=this.currentEvent,n=xe(i.event.key);return this.host.querySelector(`[slot=${n}]`)?e("slot",{name:n}):e(t,null,e("vega-box",{corners:"rounded-full",class:{"event-bg-color":!0,"event-bg-disabled":i.disabled},flexShrink:0},e("span",{class:{[`event-color-dot-${i.variant}`]:!0}})),e("vega-font",{variant:"font-h5",color:"text-primary"},i.title))}renderDivider(){return this.host.querySelector("[slot=event-preview-additional-fields]")&&e("vega-box",null,e("vega-divider",null))}injectBackgroundColorStyle(){return e("style",{nonce:Y.nonce},ke(this.currentEvent.color))}}j.register({close:{icon:'<svg width="17" height="16" viewBox="0 0 17 16" fill="currentColor" xmlns="http://www.w3.org/2000/svg"><g clip-path="url(#clip0_80261_51160)"><path d="M13.9604 1.29376C14.3511 0.903137 14.9854 0.903137 15.3761 1.29376C15.7667 1.68439 15.7667 2.31876 15.3761 2.70939L10.0823 8.00001L15.3729 13.2938C15.7636 13.6844 15.7636 14.3188 15.3729 14.7094C14.9823 15.1 14.3479 15.1 13.9573 14.7094L8.66668 9.41564L3.37293 14.7063C2.98231 15.0969 2.34793 15.0969 1.95731 14.7063C1.56668 14.3156 1.56668 13.6813 1.95731 13.2906L7.25106 8.00001L1.96043 2.70626C1.56981 2.31564 1.56981 1.68439 1.96043 1.29376C2.35106 0.903137 2.98543 0.903137 3.37606 1.29376L8.66668 6.58439L13.9604 1.29376Z" fill="currentColor" fill-opacity="0.95"/></g><defs><clipPath id="clip0_80261_51160"><rect width="14" height="16" fill="currentColor" transform="translate(1.66669)"/></clipPath></defs></svg>'},clock:{icon:'<svg width="17" height="16" viewBox="0 0 17 16" fill="currentColor" xmlns="http://www.w3.org/2000/svg"><g clip-path="url(#clip0_80261_52574)"><path d="M7.91669 3.75C7.91669 3.33437 8.25106 3 8.66669 3C9.08231 3 9.41669 3.33437 9.41669 3.75V7.6L12.0823 9.375C12.4261 9.60625 12.5198 10.0719 12.2636 10.4156C12.0604 10.7594 11.5948 10.8531 11.2511 10.5969L8.25106 8.59688C8.04169 8.48438 7.91669 8.25 7.91669 7.97188V3.75ZM8.66669 0C13.0854 0 16.6667 3.58125 16.6667 8C16.6667 12.4187 13.0854 16 8.66669 16C4.24794 16 0.666687 12.4187 0.666687 8C0.666687 3.58125 4.24794 0 8.66669 0ZM2.16669 8C2.16669 11.5906 5.07606 14.5 8.66669 14.5C12.2573 14.5 15.1667 11.5906 15.1667 8C15.1667 4.40938 12.2573 1.5 8.66669 1.5C5.07606 1.5 2.16669 4.40938 2.16669 8Z" fill="currentColor" fill-opacity="0.64"/></g><defs><clipPath id="clip0_80261_52574"><rect width="16" height="16" fill="currentColor" transform="translate(0.666687)"/></defs></svg>'}}),It([l()],$t.prototype,"host",void 0),It([l()],$t.prototype,"previewPayload",void 0),It([l()],$t.prototype,"currentEvent",void 0);var Tt=function(e,t,i,n){var r,o=arguments.length,a=o<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,i,n);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,i,a):r(t,i))||a);return o>3&&a&&Object.defineProperty(t,i,a),a};const Vt=class{constructor(e){n(this,e),this.detailRenderer=new $t,this.stateController=new St,this.translationSlimmer=new _,this.globalSlimmer={},this.vegaComponentUsageRuntimeMetricsSlimmer=new p}render(){return s(e(o,null,this.previewPayload&&this.detailRenderer.render()),this.host)}get host(){return a(this)}};Tt([v()],Vt.prototype,"detailRenderer",void 0),Tt([v()],Vt.prototype,"stateController",void 0),Tt([v()],Vt.prototype,"translationSlimmer",void 0),Tt([f()],Vt.prototype,"globalSlimmer",void 0),Tt([v()],Vt.prototype,"vegaComponentUsageRuntimeMetricsSlimmer",void 0),Vt.style=":host(.single-event-preview) .event-preview{width:398px;box-sizing:border-box}:host(.single-event-preview) .preview-actions{padding-top:4px;padding-left:4px;padding-right:4px}:host(.single-event-preview) .preview-content{margin-bottom:24px;margin-left:12px;margin-right:12px;padding-left:12px;padding-right:12px}:host(.group-event-preview) .event-preview{width:320px;box-sizing:border-box;height:100%}:host(.group-event-preview) .event-preview{border:1px solid rgba(var(--v-border-divider, 171, 198, 216, 1));border-right-width:0px;border-top-width:0px;border-bottom-width:0px;border-left-width:1px;border-left-style:solid}:host(.group-event-preview) .preview-actions{padding-top:4px;padding-left:4px;padding-right:4px}:host(.group-event-preview) .preview-content{margin-bottom:16px;margin-left:12px;margin-right:12px;padding-left:4px;padding-right:4px}:host .preview-content{max-height:60vh;overflow-y:auto}:host .event-bg-color{width:12px;height:12px;margin-top:8px;position:relative}:host .event-bg-color.event-bg-disabled{background-color:rgba(var(--v-bg-disabled, 176, 180, 181, 1))}:host .event-bg-color span{display:block;position:absolute;top:0px;left:0px;opacity:0.8}:host .event-bg-color span.event-color-dot-secondary{width:100%;height:100%;background-size:4px 4px;background-image:linear-gradient(-45deg, transparent 25%, rgba(var(--v-bg-primary, 252, 252, 252, 1)) 25% 50%, transparent 50% 75%, rgba(var(--v-bg-primary, 252, 252, 252, 1)) 75% 100%)}:host .event-bg-color span.event-color-dot-tertiary{width:calc(100% - 2px);height:calc(100% - 2px);top:1px;left:1px;border-top-left-radius:9999px;border-bottom-left-radius:9999px;border-top-right-radius:9999px;border-bottom-right-radius:9999px;background-color:rgba(var(--v-bg-primary, 252, 252, 252, 1));opacity:1}";var Lt=function(e,t,i,n){var r,o=arguments.length,a=o<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,i,n);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,i,a):r(t,i))||a);return o>3&&a&&Object.defineProperty(t,i,a),a};const Bt=class{constructor(e){n(this,e),this.globalSlimmer={},this.vegaComponentUsageRuntimeMetricsSlimmer=new p}render(){return s(e(o,{slot:xe(this.eventKey)},e("slot",null)),this.host)}get host(){return a(this)}};Lt([f()],Bt.prototype,"globalSlimmer",void 0),Lt([v()],Bt.prototype,"vegaComponentUsageRuntimeMetricsSlimmer",void 0),Bt.style=":host{width:100%;height:100%;position:relative}";export{yt as vega_calendar,Mt as vega_calendar_event,Vt as vega_calendar_event_preview,Bt as vega_calendar_event_slot}
@@ -1 +0,0 @@
1
- import{i as f}from"./p-b1faebe0.js";import{R as o}from"./p-e513f041.js";function e(e,i,r,s){return f(e)?{flex:`${o.formatCustom(e)}`}:{flexGrow:f(i)?`${o.formatCustom(i)}`:void 0,flexShrink:f(r)?`${o.formatCustom(r)}`:void 0,flexBasis:f(s)?`${o.formatCustom(s)}`:void 0}}export{e as f}
@@ -1 +0,0 @@
1
- import{W as s}from"./p-5d676a94.js";import{O as o}from"./p-331a62d5.js";import{C as a}from"./p-2d0d575f.js";import{d as r}from"./p-2ee4def0.js";import{V as m}from"./p-0e954b9b.js";const p=async()=>s.handle(),e=async s=>new Promise((p=>{const e=new o(n.bind(null),(()=>{a.unregister(r.getSubject(s,m),e),p(null)}));a.register(r.getSubject(s,m),e)})),n=()=>!0;export{e as a,p as w}
@@ -1 +0,0 @@
1
- import{r as t,c as e,h as o,H as r,g as i}from"./p-48a58baf.js";import{s as a}from"./p-519a7d55.js";import{c as s,M as n,V as l,I as p}from"./p-6e1ab235.js";import{V as u,I as d}from"./p-d849e0f5.js";import{c as b}from"./p-bb61f015.js";import{c as h}from"./p-3cdbee7e.js";import{D as c,a as g,V as v,d as f}from"./p-2ee4def0.js";import{C as m}from"./p-1da54ff3.js";import{u as x}from"./p-0e954b9b.js";import{S as y}from"./p-bdd9ef3b.js";import{C as w}from"./p-2d0d575f.js";import{f as j}from"./p-575235c8.js";import"./p-6a334573.js";import"./p-331a62d5.js";import"./p-f1436035.js";import"./p-b75ee3ba.js";import"./p-5f377954.js";import"./p-e77a83e4.js";import"./p-db8cdba6.js";import"./p-112455b1.js";var S=function(t,e,o,r){var i,a=arguments.length,s=a<3?e:null===r?r=Object.getOwnPropertyDescriptor(e,o):r;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(t,e,o,r);else for(var n=t.length-1;n>=0;n--)(i=t[n])&&(s=(a<3?i(s):a>3?i(e,o,s):i(e,o))||s);return a>3&&s&&Object.defineProperty(e,o,s),s};class R extends l{registerGroupClickObserver(){c.addUniqueObserverToNode(this.host,x,(t=>{this.clickEventEmitter.emit(t.detail)}))}unregisterGroupClickObserver(){c.removeUniqueObserverFromNode(this.host,x)}}S([s()],R.prototype,"host",void 0),S([s()],R.prototype,"clickEventEmitter",void 0),S([n("connectedCallback")],R.prototype,"registerGroupClickObserver",null),S([n("disconnectedCallback")],R.prototype,"unregisterGroupClickObserver",null);const k=[{payloadKey:"VARIANT_IS_PRIMARY",payloadDescription:"Specifies the visual style and prominence of the button group. It determines how the button group will be presented to the user.",payloadValue:t=>"primary"===t.variant},{payloadKey:"VARIANT_IS_SECONDARY",payloadDescription:"Specifies the visual style and prominence of the button group. It determines how the button group will be presented to the user.",payloadValue:t=>"secondary"===t.variant},{payloadKey:"VARIANT_IS_TERTIARY",payloadDescription:"Specifies the visual style and prominence of the button group. It determines how the button group will be presented to the user.",payloadValue:t=>"tertiary"===t.variant}];var A=function(t,e,o,r){var i,a=arguments.length,s=a<3?e:null===r?r=Object.getOwnPropertyDescriptor(e,o):r;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(t,e,o,r);else for(var n=t.length-1;n>=0;n--)(i=t[n])&&(s=(a<3?i(s):a>3?i(e,o,s):i(e,o))||s);return a>3&&s&&Object.defineProperty(e,o,s),s};const I=class{constructor(o){t(this,o),this.vegaClick=e(this,"vegaClick",7),this.click=e(this,"click",7),this.globalSlimmers={},this.clickEventEmitter=h(I,g),this.clickEventPrevent=new m([g],(()=>this.flexContainer)),this.buttonGroupClickController=new R,this.variantNotifySlimmer=b(I,"variant","watchVariant"),this.sizeNotifySlimmer=b(I,"size","watchSize"),this.iconAlignNotifySlimmer=b(I,"iconAlign","watchIconAlign"),this.vegaComponentUsageRuntimeMetricsSlimmer=new u(k),this.variant="primary",this.size="default",this.iconAlign="left"}watchVariant(){}watchSize(){}watchIconAlign(){}render(){return a(o(r,null,o("vega-flex",{class:`vega-button-group-container vega-button-group-${this.variant}`,direction:"row",alignItems:"tertiary"===this.variant?"center":"stretch",gap:"tertiary"!==this.variant?"size-2":"0",ref:t=>this.flexContainer=t},o("slot",null))),this.host)}get host(){return i(this)}static get watchers(){return{variant:["watchVariant"],size:["watchSize"],iconAlign:["watchIconAlign"]}}};A([d()],I.prototype,"globalSlimmers",void 0),A([p()],I.prototype,"clickEventEmitter",void 0),A([p()],I.prototype,"clickEventPrevent",void 0),A([p()],I.prototype,"buttonGroupClickController",void 0),A([p()],I.prototype,"variantNotifySlimmer",void 0),A([p()],I.prototype,"sizeNotifySlimmer",void 0),A([p()],I.prototype,"iconAlignNotifySlimmer",void 0),A([p()],I.prototype,"vegaComponentUsageRuntimeMetricsSlimmer",void 0),I.style=":host{display:inline-block;border-radius:9999px}.vega-button-group-primary{gap:6px}.vega-button-group-container:not(.vega-button-group-tertiary){border-radius:9999px}.vega-button-group-container:not(.vega-button-group-tertiary)>::slotted(.vega-button-group-item:first-child){border-top-left-radius:9999px;border-bottom-left-radius:9999px}.vega-button-group-container:not(.vega-button-group-tertiary)>::slotted(.vega-button-group-item:last-child){border-top-right-radius:9999px;border-bottom-right-radius:9999px}.vega-button-group-tertiary>::slotted(.vega-button-group-item){border-color:rgba(var(--v-border-color-divider-secondary, 199, 217, 229, 1));border-left-width:1px;border-top-width:0px;border-bottom-width:0px;border-right-width:0px;border-style:solid}.vega-button-group-tertiary>::slotted(.vega-button-group-item:first-child){border-left-width:0px}";var O=function(t,e,o,r){var i,a=arguments.length,s=a<3?e:null===r?r=Object.getOwnPropertyDescriptor(e,o):r;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(t,e,o,r);else for(var n=t.length-1;n>=0;n--)(i=t[n])&&(s=(a<3?i(s):a>3?i(e,o,s):i(e,o))||s);return a>3&&s&&Object.defineProperty(e,o,s),s};class z extends y{constructor(){super({parent:"vega-button-group",subStates:[{subStateName:"variant",parentStateName:"variant"},{subStateName:"size",parentStateName:"size"},{subStateName:"iconAlign",parentStateName:"iconAlign"}]})}}O([s({writable:!0})],z.prototype,"size",void 0),O([s({writable:!0})],z.prototype,"variant",void 0),O([s({writable:!0})],z.prototype,"iconAlign",void 0);var C=function(t,e,o,r){var i,a=arguments.length,s=a<3?e:null===r?r=Object.getOwnPropertyDescriptor(e,o):r;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(t,e,o,r);else for(var n=t.length-1;n>=0;n--)(i=t[n])&&(s=(a<3?i(s):a>3?i(e,o,s):i(e,o))||s);return a>3&&s&&Object.defineProperty(e,o,s),s};class N extends l{constructor(){super(...arguments),this.buttonItemClickHandle=()=>{this.notifyParentGroup(this.itemKey)},this.moreDropdownItemClickHandle=t=>{this.notifyParentGroup(t.detail)}}render(){return this.dropdownSource&&this.dropdownSource.length?o("vega-dropdown",Object.assign({source:this.dropdownSource,trigger:"click"},this.dropdownProps,{ref:t=>{c.addUniqueObserverToNode(t,v,this.moreDropdownItemClickHandle)}}),this.renderButtonItemWithTooltip()):this.renderButtonItemWithTooltip()}renderButtonItemWithTooltip(){return this.iconOnly&&this.label?o("vega-tooltip",{placement:"top",text:this.label},this.renderButtonItem()):this.renderButtonItem()}renderButtonItem(){const t=this.getButtonProps();return"tertiary"===this.variant?o("vega-button-link",Object.assign({},t)):o("vega-button",Object.assign({class:`button-group-item-button-${this.variant}`,variant:this.variant},t))}notifyParentGroup(t){const e=j(this.host,"vega-button-group");e&&w.notify(f.getSubject(e,x),{host:this.host,detail:t})}getButtonProps(){return{size:this.size,icon:this.icon,label:this.iconOnly?"":this.getDefaultLabel(),iconAlign:this.iconAlign,ref:t=>{c.addUniqueObserverToNode(t,g,this.buttonItemClickHandle)}}}getDefaultLabel(){return!this.icon&&!this.label&&this.dropdownSource&&this.dropdownSource.length?"More":this.label}}C([s()],N.prototype,"host",void 0),C([s()],N.prototype,"size",void 0),C([s()],N.prototype,"icon",void 0),C([s()],N.prototype,"label",void 0),C([s()],N.prototype,"iconAlign",void 0),C([s()],N.prototype,"iconOnly",void 0),C([s()],N.prototype,"variant",void 0),C([s()],N.prototype,"itemKey",void 0),C([s()],N.prototype,"dropdownSource",void 0),C([s()],N.prototype,"dropdownProps",void 0);var V=function(t,e,o,r){var i,a=arguments.length,s=a<3?e:null===r?r=Object.getOwnPropertyDescriptor(e,o):r;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(t,e,o,r);else for(var n=t.length-1;n>=0;n--)(i=t[n])&&(s=(a<3?i(s):a>3?i(e,o,s):i(e,o))||s);return a>3&&s&&Object.defineProperty(e,o,s),s};const _=class{constructor(e){t(this,e),this.globalSlimmers={},this.subStateObserverSlimmer=new z,this.buttonGroupItemRenderer=new N,this.vegaComponentUsageRuntimeMetricsSlimmer=new u,this.variant="primary",this.size="default",this.iconAlign="left",this.iconOnly=!1}render(){return a(o(r,{class:"vega-button-group-item"},this.buttonGroupItemRenderer.render()),this.host)}get host(){return i(this)}};V([d()],_.prototype,"globalSlimmers",void 0),V([p()],_.prototype,"subStateObserverSlimmer",void 0),V([p()],_.prototype,"buttonGroupItemRenderer",void 0),V([p()],_.prototype,"vegaComponentUsageRuntimeMetricsSlimmer",void 0),_.style=":host{display:inline-block}:host>vega-tooltip,:host>vega-dropdown{height:100%}:host>vega-tooltip>vega-tooltip,:host>vega-dropdown>vega-tooltip{height:100%}:host vega-button{height:100%}:host vega-button::part(button):focus-visible{position:relative;outline:2px solid rgba(var(--v-border-color-action, 19, 98, 226, 1));outline-offset:2px;border-radius:4px;box-shadow:0px 0px 0px 6px rgba(var(--v-bg-primary, 252, 252, 252, 1));z-index:1}:host vega-button-link::part(link){padding-left:12px;padding-right:12px;box-sizing:border-box}:host vega-button-link::part(link):focus-visible{outline:2px solid rgba(var(--v-border-color-action, 19, 98, 226, 1));outline-offset:0px;border-top-left-radius:4px;border-bottom-left-radius:4px;border-top-right-radius:4px;border-bottom-right-radius:4px;color:rgba(var(--v-text-link, 19, 98, 226, 1))}:host vega-button-link::part(label-container){text-decoration:none}:host vega-button-link:hover::part(label-container){text-decoration:underline}:host vega-button::part(button){margin-right:-4px}:host(:first-child) vega-tooltip:has(vega-button),:host(:first-child) vega-dropdown:has(vega-button){border-top-left-radius:9999px;border-bottom-left-radius:9999px}:host(:first-child) vega-button::part(button){border-top-left-radius:9999px;border-bottom-left-radius:9999px}:host(:first-child) vega-button::part(button):focus-visible{margin-left:0}:host(:last-child) vega-tooltip:has(vega-button),:host(:last-child) vega-dropdown:has(vega-button){border-top-right-radius:9999px;border-bottom-right-radius:9999px}:host(:last-child) vega-button::part(button){border-top-right-radius:9999px;border-bottom-right-radius:9999px}:host(:last-child) vega-button::part(button){margin-right:0}vega-button::part(button){border-top-left-radius:0px;border-bottom-left-radius:0px;border-top-right-radius:0px;border-bottom-right-radius:0px;height:100%}";export{I as vega_button_group,_ as vega_button_group_item}
@@ -1 +0,0 @@
1
- class E{constructor(E){this.title=E}getDescription(){return this.title}}const _=new E("SIDENAV_LINK_SELECTED_TOPIC"),A=new E("LEFT_NAV_LINK_SELECTED_TOPIC"),O=new E("ACCORDION_EXPAND_TOPIC"),L=new E("FORM_RESET_OPERATION_TRIGGERED"),N=new E("FORM_FIELD_ELEMENT_DISCONNECTED"),D=new E("FORM_SUBMIT"),R=new E("FORM_RESET"),s=new E("RADIO_GROUP_DISABLED_CHANGE"),C=new E("CHECKBOX_GROUP_DISABLED_CHANGE"),T=new E("FORM_FIELD_PENDING_VALID_CHANGE"),e=new E("TAB_PANEL_ADD_OR_DEL_TO_GROUP"),n=new E("TABLE_EXPAND_ROW"),I=new E("TABLE_ROW_SELECTION"),a=new E("TABLE_ROW_SELECTION_ALL"),w=new E("TABLE_ROW_CLICK"),G=new E("FIELD_ERROR_MESSAGE_CHANGE"),S=new E("DROPDOWN_ITEM_CLICK"),P=new E("CHECKBOX_VALUE_CHANGE"),M=new E("RADIO_VALUE_CHANGE"),H=new E("FORM_ELEMENT_VALUE_CHANGE"),F=new E("FORM_EMEMENT_VALIDATE"),B=new E("SELECTION_TILE_VALUE_CHANGE"),V=new E("UPDATE_TRANSLATION"),U=new E("DARK_MODE_CHANGE"),t=new E("SHADOW_ROOT_ELEMENT_SCROLLING"),r=new E("FLAG_ICON_LOADED"),K=new E("GP_BRAND_CHANGE"),W=new E("CALENDAR_EVENT_PREVIEW_POPOVER_HIDE");export{O as A,P as C,U as D,D as F,K as G,A as L,M as R,t as S,e as T,V as U,R as a,H as b,T as c,N as d,L as e,G as f,F as g,r as h,C as i,s as j,B as k,_ as l,W as m,S as n,n as o,I as p,a as q,w as r}
@@ -1 +0,0 @@
1
- import{h as e,H as t,r as i,c as o,g as r}from"./p-48a58baf.js";import{s}from"./p-519a7d55.js";import{c as a,M as l,V as n,I as d,L as c}from"./p-6e1ab235.js";import{V as h,I as p}from"./p-d849e0f5.js";import{R as v}from"./p-e513f041.js";import{c as g}from"./p-86194314.js";import{S as b}from"./p-bdd9ef3b.js";import{O as f}from"./p-331a62d5.js";import{d as m,f as u}from"./p-2ee4def0.js";import{d as x}from"./p-0e954b9b.js";import{f as w}from"./p-575235c8.js";import{C as j}from"./p-2d0d575f.js";import{P as y,g as k}from"./p-7d9cd9c8.js";import{c as C}from"./p-3cdbee7e.js";import{b as R}from"./p-8a877e12.js";import{M as z}from"./p-78a57a17.js";import{a as S}from"./p-52b8f2d2.js";import{i as O}from"./p-d27ae9ff.js";import{c as E}from"./p-bb61f015.js";import{C as T}from"./p-1da54ff3.js";import{F as I}from"./p-c7726252.js";import{R as V}from"./p-280cbcdb.js";import"./p-b1faebe0.js";import"./p-ed45b3b6.js";import"./p-74168615.js";import"./p-d884c644.js";import"./p-262ec334.js";import"./p-0c667d6a.js";import"./p-5f377954.js";import"./p-89d2cf34.js";import"./p-a4670e23.js";import"./p-6a334573.js";import"./p-02a4732a.js";import"./p-112455b1.js";import"./p-54ae02db.js";import"./p-b75ee3ba.js";import"./p-f1436035.js";import"./p-e5cd6521.js";import"./p-258f9603.js";import"./p-02841589.js";import"./p-bf19682d.js";import"./p-a7b5f497.js";import"./p-8c9ea6f4.js";import"./p-e77a83e4.js";import"./p-db8cdba6.js";import"./p-5d676a94.js";import"./p-bf0ced3c.js";import"./p-abd7aeaa.js";var N=function(e,t,i,o){var r,s=arguments.length,a=s<3?t:null===o?o=Object.getOwnPropertyDescriptor(t,i):o;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,i,o);else for(var l=e.length-1;l>=0;l--)(r=e[l])&&(a=(s<3?r(a):s>3?r(t,i,a):r(t,i))||a);return s>3&&a&&Object.defineProperty(t,i,a),a};class L extends n{componentWillRender(){this.currentSize=v.formatCustom(this.size)}render(){return e(t,{class:{block:this.block}},this.renderTooltip())}renderTooltip(){return e("vega-tooltip",Object.assign({trigger:this.disabled&&this.disabledTooltip?"hover":"none",alignment:"center"},this.disabledTooltip),this.renderSelectionChip())}renderSelectionChip(){return e("vega-box",{corners:"rounded-full",class:{"vega-selection-chip":!0,[`size-${this.currentSize}`]:!0,[`variant-${this.variant||"text"}`]:!0,checked:this.checked,error:this.showError,disabled:this.disabled},"aria-label":this.label||"No label defined",onClick:()=>{"radio"===this.selectType&&this.checked||this.checkedController.onCheck(!this.checked)},onKeyDown:g(),tabIndex:this.disabled?-1:0},this.renderContent())}renderContent(){return e("vega-flex",{gap:L.gapSizeMap[this.currentSize],"align-items":"center","justify-content":"text"===this.variant?"center":"start"},"swatch"===this.variant&&this.renderSwatch(),this.renderLabel())}renderLabel(){return e("vega-font",{color:"text-primary",class:"label vega-flex-grow",variant:L.labelFontMap[this.currentSize]},this.label)}renderSwatch(){return e("vega-box",{"background-color":"bg-primary",corners:"rounded-full",class:"swatch vega-flex-shrink-0"},e("vega-box",{"background-color":this.swatchColor,corners:"rounded-full"}))}}L.gapSizeMap={"extra-small":"size-4",small:"size-4",medium:"size-8",large:"size-8"},L.labelFontMap={"extra-small":"font-field-label-xs",small:"font-field-label-sm",medium:"font-field-label",large:"font-field-label-lg"},N([a()],L.prototype,"host",void 0),N([a()],L.prototype,"label",void 0),N([a()],L.prototype,"block",void 0),N([a()],L.prototype,"size",void 0),N([a()],L.prototype,"variant",void 0),N([a()],L.prototype,"swatchColor",void 0),N([a()],L.prototype,"disabledTooltip",void 0),N([a()],L.prototype,"disabled",void 0),N([a()],L.prototype,"selectType",void 0),N([a()],L.prototype,"checked",void 0),N([a()],L.prototype,"checkedController",void 0),N([a()],L.prototype,"showError",void 0),N([l("componentWillRender")],L.prototype,"componentWillRender",null);var A=function(e,t,i,o){var r,s=arguments.length,a=s<3?t:null===o?o=Object.getOwnPropertyDescriptor(t,i):o;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,i,o);else for(var l=e.length-1;l>=0;l--)(r=e[l])&&(a=(s<3?r(a):s>3?r(t,i,a):r(t,i))||a);return s>3&&a&&Object.defineProperty(t,i,a),a};class F extends n{setChecked(e){this.checked=e}onCheck(e){const t=e?this.value:"";this.setChecked(e),this.changeEventEmitter.emit(t)}}A([a()],F.prototype,"host",void 0),A([a({writable:!0})],F.prototype,"checked",void 0),A([a()],F.prototype,"changeEventEmitter",void 0),A([a()],F.prototype,"value",void 0);var D=function(e,t,i,o){var r,s=arguments.length,a=s<3?t:null===o?o=Object.getOwnPropertyDescriptor(t,i):o;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,i,o);else for(var l=e.length-1;l>=0;l--)(r=e[l])&&(a=(s<3?r(a):s>3?r(t,i,a):r(t,i))||a);return s>3&&a&&Object.defineProperty(t,i,a),a};class G extends b{constructor(){super({parent:"vega-selection-chip-group",subStates:[{subStateName:"disabled",parentStateName:"disabled",callback:e=>{"boolean"==typeof e&&(this.disabled=e)}},{subStateName:"selectType",parentStateName:"selectType",callback:e=>{this.selectType="checkbox"===e?"checkbox":"radio"}},{subStateName:"checked",parentStateName:"value",callback:e=>{this.checkedController.setChecked(Array.isArray(e)?e.includes(this.value):e===this.value)}}]})}}D([a()],G.prototype,"host",void 0),D([a({writable:!0})],G.prototype,"disabled",void 0),D([a({writable:!0})],G.prototype,"selectType",void 0),D([a()],G.prototype,"value",void 0),D([a()],G.prototype,"checkedController",void 0);var W=function(e,t,i,o){var r,s=arguments.length,a=s<3?t:null===o?o=Object.getOwnPropertyDescriptor(t,i):o;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,i,o);else for(var l=e.length-1;l>=0;l--)(r=e[l])&&(a=(s<3?r(a):s>3?r(t,i,a):r(t,i))||a);return s>3&&a&&Object.defineProperty(t,i,a),a};class M extends n{connectedCallback(){this.selectionChipGroup=w(this.host,"vega-selection-chip-group"),this.selectionChipGroup&&(this.fieldErrorObserver=new f(this.canAcceptFieldErrorObserver.bind(this),this.fieldErrorObserverListener.bind(this)),j.register(m.getSubject(this.selectionChipGroup,x),this.fieldErrorObserver))}disconnectedCallback(){this.selectionChipGroup&&j.unregister(m.getSubject(this.selectionChipGroup,x),this.fieldErrorObserver)}canAcceptFieldErrorObserver(){return!0}fieldErrorObserverListener(e){this.showError=e.showError}}W([a({writable:!0})],M.prototype,"showError",void 0),W([a()],M.prototype,"host",void 0),W([l("connectedCallback")],M.prototype,"connectedCallback",null),W([l("disconnectedCallback")],M.prototype,"disconnectedCallback",null);var _=function(e,t,i,o){var r,s=arguments.length,a=s<3?t:null===o?o=Object.getOwnPropertyDescriptor(t,i):o;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,i,o);else for(var l=e.length-1;l>=0;l--)(r=e[l])&&(a=(s<3?r(a):s>3?r(t,i,a):r(t,i))||a);return s>3&&a&&Object.defineProperty(t,i,a),a};const H=class{constructor(e){i(this,e),this.vegaChange=o(this,"vegaChange",7),this.change=o(this,"change",7),this.globalSlimmers={},this.renderer=new L,this.checkedController=new F,this.stateController=new G,this.showErrorController=new M,this.pageResizeObserverSlimmer=new y,this.vegaComponentUsageRuntimeMetricsSlimmer=new h,this.changeEventEmitter=C(H,u),this.showError=!1,this.currentBreakpoint=k(),this.label="",this.size="medium",this.variant="text",this.disabled=!1,this.block=!1,this.swatchColor="bg-status-info"}watchSize(){}componentWillRender(){}render(){return s(this.renderer.render(),this.host)}get host(){return r(this)}static get watchers(){return{size:["watchSize"]}}};_([p()],H.prototype,"globalSlimmers",void 0),_([d()],H.prototype,"renderer",void 0),_([d()],H.prototype,"checkedController",void 0),_([d()],H.prototype,"stateController",void 0),_([d()],H.prototype,"showErrorController",void 0),_([d()],H.prototype,"pageResizeObserverSlimmer",void 0),_([d()],H.prototype,"vegaComponentUsageRuntimeMetricsSlimmer",void 0),_([d()],H.prototype,"changeEventEmitter",void 0),H.style=":host(.block){display:block}:host(.block) vega-tooltip{display:block}:host{max-width:100%;display:inline-block;vertical-align:middle;line-height:0}:host vega-tooltip{max-width:100%}:host .swatch{margin:2px;padding:1px;box-sizing:border-box}:host .swatch vega-box{width:100%;height:100%}:host .label{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}:host .vega-selection-chip{background-color:rgba(var(--v-bg-tile, 252, 252, 252, 1));cursor:pointer;margin:1px}:host .variant-text .label{text-align:center}:host .size-extra-small.variant-swatch.vega-selection-chip{padding-top:2px;padding-bottom:2px;padding-left:2px;padding-right:12px}:host .size-extra-small.variant-text.vega-selection-chip{padding-left:12px;padding-right:12px;padding-top:2px;padding-bottom:2px}:host .size-extra-small vega-flex{height:16px}:host .size-extra-small .swatch{width:12px;height:12px}:host .size-small.variant-swatch.vega-selection-chip{padding-top:4px;padding-bottom:4px;padding-left:4px;padding-right:12px}:host .size-small.variant-text.vega-selection-chip{padding-left:12px;padding-right:12px;padding-top:4px;padding-bottom:4px}:host .size-small vega-flex{height:24px}:host .size-small .swatch{width:20px;height:20px}:host .size-medium.variant-swatch.vega-selection-chip{padding-top:4px;padding-bottom:4px;padding-left:4px;padding-right:16px}:host .size-medium.variant-text.vega-selection-chip{padding-left:16px;padding-right:16px;padding-top:4px;padding-bottom:4px}:host .size-medium vega-flex{height:32px}:host .size-medium .swatch{width:28px;height:28px}:host .size-large.variant-swatch.vega-selection-chip{padding-top:4px;padding-bottom:4px;padding-left:4px;padding-right:20px}:host .size-large.variant-text.vega-selection-chip{padding-left:20px;padding-right:20px;padding-top:4px;padding-bottom:4px}:host .size-large vega-flex{height:40px}:host .size-large .swatch{width:36px;height:36px}:host .vega-selection-chip:not(.disabled){background-color:rgba(var(--v-bg-tile, 252, 252, 252, 1));border:1px solid rgba(var(--v-border-tile, 171, 198, 216, 1))}:host .vega-selection-chip:not(.disabled):hover{background-color:rgba(var(--v-bg-tile-hover, 245, 247, 247, 1));border:1px solid rgba(var(--v-border-tile-hover, 115, 160, 190, 1))}:host .vega-selection-chip:not(.disabled):focus-visible{background-color:rgba(var(--v-bg-tile, 252, 252, 252, 1));outline:2px solid rgba(var(--v-border-color-action, 19, 98, 226, 1));outline-offset:2px;border:1px solid rgba(var(--v-border-tile-focus, 19, 98, 226, 1))}:host .vega-selection-chip:not(.disabled).checked{background-color:rgba(var(--v-bg-tile-selected, 242, 247, 255, 1));border:2px solid rgba(var(--v-border-tile-selected, 19, 98, 226, 1));margin:0px}:host .vega-selection-chip:not(.disabled).checked:hover{background-color:rgba(var(--v-bg-tile-selected-hover, 229, 239, 255, 1));border:2px solid rgba(var(--v-border-tile-selected-hover, 4, 112, 236, 1))}:host .vega-selection-chip:not(.disabled).checked:focus-visible{background-color:rgba(var(--v-bg-tile-selected, 242, 247, 255, 1));border:2px solid rgba(var(--v-border-tile-selected-focus, 19, 98, 226, 1))}:host .vega-selection-chip:not(.disabled).error{background-color:rgba(var(--v-bg-tile, 252, 252, 252, 1));border:1px solid rgba(var(--v-border-input-field-danger, 230, 50, 87, 1))}:host .vega-selection-chip:not(.disabled).error:hover{background-color:rgba(var(--v-bg-tile-hover, 245, 247, 247, 1));border:1px solid rgba(var(--v-border-input-field-danger-hover, 255, 87, 114, 1))}:host .vega-selection-chip:not(.disabled).error:focus-visible{background-color:rgba(var(--v-bg-tile, 252, 252, 252, 1));outline:2px solid rgba(var(--v-border-color-danger, 230, 50, 87, 1));outline-offset:2px;border:1px solid rgba(var(--v-border-input-field-danger-focus, 233, 71, 104, 1))}:host .vega-selection-chip.disabled{background-color:rgba(var(--v-bg-tile, 252, 252, 252, 1));border:1px solid rgba(var(--v-border-input-field-disabled, 222, 225, 227, 1));pointer-events:none;color:rgba(var(--v-text-disabled, 176, 180, 181, 1))}:host .vega-selection-chip.disabled:focus-visible{outline:none}:host .vega-selection-chip.disabled vega-font{color:rgba(var(--v-text-disabled, 176, 180, 181, 1))}:host .vega-selection-chip.disabled .swatch{opacity:0.5}";var P=function(e,t,i,o){var r,s=arguments.length,a=s<3?t:null===o?o=Object.getOwnPropertyDescriptor(t,i):o;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,i,o);else for(var l=e.length-1;l>=0;l--)(r=e[l])&&(a=(s<3?r(a):s>3?r(t,i,a):r(t,i))||a);return s>3&&a&&Object.defineProperty(t,i,a),a};class $ extends n{getGroupContainerRef(){return this.groupContainerRef}render(){return e("div",null,this.renderLabel(),this.renderContainer(),this.renderHint())}renderLabel(){return e("vega-field-label",{"is-field-required":this.required,disabled:this.disabled,label:this.label})}renderContainer(){return e("div",{class:"container",ref:e=>this.groupContainerRef=e},e("slot",null))}renderHint(){return this.hint&&e("div",{class:"vega-hint"},e("label",null,this.hint))}}P([a()],$.prototype,"host",void 0),P([a()],$.prototype,"label",void 0),P([a()],$.prototype,"required",void 0),P([a()],$.prototype,"hint",void 0),P([a()],$.prototype,"disabled",void 0);var q=function(e,t,i,o){var r,s=arguments.length,a=s<3?t:null===o?o=Object.getOwnPropertyDescriptor(t,i):o;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,i,o);else for(var l=e.length-1;l>=0;l--)(r=e[l])&&(a=(s<3?r(a):s>3?r(t,i,a):r(t,i))||a);return s>3&&a&&Object.defineProperty(t,i,a),a};class U extends n{watchValue(){this.changeEventEmitter.emit(this.value),j.notify(R,{host:this.host,detail:this.value})}setValue(e){this.valueGuard(e)&&(this.value=e)}valueGuard(e){switch(this.selectType){case"radio":return"string"==typeof e;case"checkbox":return Array.isArray(e)&&e.every((e=>"string"==typeof e));default:return c.warn(`Invalid selection chip group value ${e} for ${this.selectType} mode`),!1}}}q([a()],U.prototype,"host",void 0),q([a({writable:!0})],U.prototype,"value",void 0),q([a()],U.prototype,"changeEventEmitter",void 0),q([a()],U.prototype,"selectType",void 0),q([l("watchValue")],U.prototype,"watchValue",null);var K=function(e,t,i,o){var r,s=arguments.length,a=s<3?t:null===o?o=Object.getOwnPropertyDescriptor(t,i):o;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,i,o);else for(var l=e.length-1;l>=0;l--)(r=e[l])&&(a=(s<3?r(a):s>3?r(t,i,a):r(t,i))||a);return s>3&&a&&Object.defineProperty(t,i,a),a};class B extends n{constructor(){super(...arguments),this.mutationObserver=new z({target:()=>this.host,options:{childList:!0,subtree:!0,attributes:!0,attributeFilter:["checked"]},mutationFilter:S("VEGA-SELECTION-CHIP"),callback:this.syncChipArrayAndValue.bind(this)}),this.selectionChipArray=[]}disconnectedCallback(){}componentWillLoad(){this.value&&0!==this.value.length||this.syncChipArrayAndValue()}componentDidLoad(){}watchSelectType(){this.syncChipArrayAndValue()}getSelectionChipArray(){return this.selectionChipArray}syncChipArrayAndValue(e){this.selectionChipArray=Array.from(this.host.querySelectorAll("vega-selection-chip")),"checkbox"===this.selectType?this.setValueFromCheckboxItems():this.setValueFromRadioItems(e)}setValueFromCheckboxItems(){const e=this.selectionChipArray.filter((e=>e.checked)).map((e=>e.value));O(this.value,e,!0)||this.valueController.setValue(e)}setValueFromRadioItems(e){const t=this.findAttributeMutation(e);if(t){const e=this.getCurrentChip(t);e&&e.checked&&this.valueController.setValue(e.value)}else{const e=this.getFirstCheckedChip();this.valueController.setValue(e?e.value:"")}}findAttributeMutation(e){return e&&e.find((e=>e.attributeName))}getCurrentChip(e){if(e&&"VEGA-SELECTION-CHIP"===e.target.tagName&&"checked"===e.attributeName)return e.target}getFirstCheckedChip(){return this.selectionChipArray.find((e=>e.checked))}}K([a()],B.prototype,"host",void 0),K([a()],B.prototype,"selectType",void 0),K([a()],B.prototype,"valueController",void 0),K([a()],B.prototype,"value",void 0),K([d()],B.prototype,"mutationObserver",void 0),K([l("disconnectedCallback")],B.prototype,"disconnectedCallback",null),K([l("componentWillLoad")],B.prototype,"componentWillLoad",null),K([l("componentDidLoad")],B.prototype,"componentDidLoad",null),K([l("watchSelectType")],B.prototype,"watchSelectType",null);var J=function(e,t,i,o){var r,s=arguments.length,a=s<3?t:null===o?o=Object.getOwnPropertyDescriptor(t,i):o;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,i,o);else for(var l=e.length-1;l>=0;l--)(r=e[l])&&(a=(s<3?r(a):s>3?r(t,i,a):r(t,i))||a);return s>3&&a&&Object.defineProperty(t,i,a),a};const Q=class{constructor(e){i(this,e),this.vegaChange=o(this,"vegaChange",7),this.change=o(this,"change",7),this.globalSlimmers={},this.renderer=new $,this.itemsController=new B,this.valueController=new U,this.formFieldController=new I({propertyRules:[{propertyName:"required",ruleFactory:e=>e?new V:null}],validationRulesName:"validationRules",inputContainerGetter:()=>this.renderer.getGroupContainerRef(),touchableAreaGetter:()=>this.itemsController.getSelectionChipArray(),defaultValue:e=>"checkbox"===e.selectType?[]:"",attributeGetter:e=>this[e]}),this.vegaComponentUsageRuntimeMetricsSlimmer=new h,this.changeEventEmitter=C(Q,u),this.valueNotifySlimmer=E(Q,"value","watchValue"),this.disabledNotifySlimmer=E(Q,"disabled","watchDisabled"),this.selectTypeNotifySlimmer=E(Q,"selectType","watchSelectType"),this.changeEventPrevent=new T([u],(()=>this.host),!0),this.label="",this.selectType="radio",this.value="checkbox"===this.selectType?[]:"",this.validationRules=[],this.isValid=null}watchSelectType(){}watchValue(){}watchDisabled(){}watchValidationRules(){}render(){return s(e(t,null,this.renderer.render()),this.host)}get host(){return r(this)}static get watchers(){return{selectType:["watchSelectType"],value:["watchValue"],disabled:["watchDisabled"],validationRules:["watchValidationRules"]}}};J([p()],Q.prototype,"globalSlimmers",void 0),J([d()],Q.prototype,"renderer",void 0),J([d()],Q.prototype,"itemsController",void 0),J([d()],Q.prototype,"valueController",void 0),J([d()],Q.prototype,"formFieldController",void 0),J([d()],Q.prototype,"vegaComponentUsageRuntimeMetricsSlimmer",void 0),J([d()],Q.prototype,"changeEventEmitter",void 0),J([d()],Q.prototype,"valueNotifySlimmer",void 0),J([d()],Q.prototype,"disabledNotifySlimmer",void 0),J([d()],Q.prototype,"selectTypeNotifySlimmer",void 0),J([d()],Q.prototype,"changeEventPrevent",void 0),Q.style=':host{display:block}:host vega-field-label{margin-bottom:8px}:host .vega-hint{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));padding-top:4px;padding-left:8px;padding-right:8px}@media screen and (min-width: 768px) and (max-width: 1023px){:host .vega-hint{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){:host .vega-hint{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){:host .vega-hint{font-family:"Inter", sans-serif;font-size:14px;font-weight:400;line-height:18px;letter-spacing:0px}}:host .vega-error{display:block;margin-top:12px;margin-left:8px;margin-right:8px;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))}@media screen and (min-width: 768px) and (max-width: 1023px){:host .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){:host .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){:host .vega-error{font-family:"Inter", sans-serif;font-size:14px;font-weight:400;line-height:18px;letter-spacing:0px}}:host .vega-hidden{display:none}';export{H as vega_selection_chip,Q as vega_selection_chip_group}
@@ -1 +0,0 @@
1
- import{h as t,r as e,c as i,H as s,g as o}from"./p-48a58baf.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,f as m,E as u}from"./p-2ee4def0.js";import{n as d,c as v,b}from"./p-262ec334.js";import{C as j}from"./p-1da54ff3.js";import{c as w}from"./p-3cdbee7e.js";import{b as x}from"./p-8a877e12.js";import{C as y}from"./p-2d0d575f.js";import{K as R}from"./p-743c5baf.js";import{F as C}from"./p-c7726252.js";import{R as g}from"./p-280cbcdb.js";import{c as I}from"./p-bb61f015.js";import{M as V,a as N}from"./p-f0ff4463.js";import"./p-331a62d5.js";import"./p-575235c8.js";import"./p-f1436035.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-2608b9fe.js";import"./p-b1faebe0.js";import"./p-ed45b3b6.js";import"./p-74168615.js";import"./p-d884c644.js";import"./p-02841589.js";import"./p-a4670e23.js";import"./p-0e954b9b.js";import"./p-bf0ced3c.js";import"./p-7d9cd9c8.js";import"./p-abd7aeaa.js";import"./p-78a57a17.js";import"./p-52b8f2d2.js";import"./p-d27ae9ff.js";import"./p-bdd9ef3b.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 M=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 F=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(F,m),this.inputEventPrevent=new j([m],(()=>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(F,"prefixText","watchPrefixText"),this.suffixTextNotifySlimmer=I(F,"suffixText","watchSuffixText"),this.isCompactInputWidthNotifySlimmer=I(F,"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"]}}};M([c()],F.prototype,"globalSlimmers",void 0),M([l()],F.prototype,"valueController",void 0),M([l()],F.prototype,"keyboardController",void 0),M([l()],F.prototype,"renderer",void 0),M([l()],F.prototype,"changeEventEmitter",void 0),M([l()],F.prototype,"inputEventPrevent",void 0),M([l()],F.prototype,"formFieldController",void 0),M([l()],F.prototype,"prefixTextNotifySlimmer",void 0),M([l()],F.prototype,"suffixTextNotifySlimmer",void 0),M([l()],F.prototype,"isCompactInputWidthNotifySlimmer",void 0),M([l()],F.prototype,"vegaComponentUsageRuntimeMetricsSlimmer",void 0),F.style=":host{display:inline-block;width:100%}";export{F as vega_input_numeric}
@@ -1 +0,0 @@
1
- import{c as t,d as e,a as n,e as s,A as r,b as o,B as i,f as a,g as l,h as c,i as d,I as u,j as h,S as m,k as T,l as w,m as E,n as g,C as p,o as R,p as k,q as f,r as B,t as I,s as x,N as b,u as O,v as L,w as y,x as A,y as N,z as C,M as j,D as H,H as S,E as v,R as D,F as M,U as P,G as V}from"./p-258f9603.js";import{g as F}from"./p-a4670e23.js";import{i as U}from"./p-b1faebe0.js";import{d as z}from"./p-02841589.js";import{r as $,i as G}from"./p-575235c8.js";import{C as J}from"./p-2d0d575f.js";import{d as W}from"./p-2ee4def0.js";import{a as K}from"./p-0e954b9b.js";import{c as X}from"./p-bf19682d.js";class RTEListItemBlock extends e{constructor(t,e,n){super(t,"list-item",n),this.nestList=[],this.nestList=e}static from(t,e={autoMatchFormat:!0}){const s=new RTEListItemBlock(t.id,void 0,e);s.children=t.nodes.map((t=>n.from(t,s,e))),t.children&&(s.nestList=t.children.map((t=>{const e=RTEListBlock.from(t);return e.parent=s,e})));const{annotations:r}=t;return r&&Object.entries(r).forEach((([t,e])=>{const n=this.createAnnotationEntity(t,e);U(n)&&s.annotationMap.set(...n)})),s}toJSON(){var t;return Object.assign(Object.assign({},super.toJSON()),{type:"list-item",children:null===(t=this.nestList)||void 0===t?void 0:t.map((t=>t.toJSON()))})}toHtml(){return[`<li${super.generateAttributeString()}>`,this.children.map((t=>t.toHtml())).join(""),"</li>"].join("")}cloneWithNodes(t){const e=new RTEListItemBlock(F());return e.children=[],e.apply(new s(t)),e}getLastNode(){return this.nestList&&this.nestList.length>0?this.nestList[this.nestList.length-1].getLastNode():super.getLastNode()}createNewListItem(){return new RTEListItemBlock(F())}clone(){var t;const e=new RTEListItemBlock(this.id);return e.children=this.children.map((t=>{const n=t.clone();return n.parent=e,n})),e.annotationMap=super.cloneAnnotations(),e.nestList=null===(t=this.nestList)||void 0===t?void 0:t.map((t=>{const n=t.clone();return n.parent=e,n})),e.parent=this.parent,e}}r.register(o.LINE_BREAK_SINGLE_BLOCK,RTEListItemBlock.name,new i),r.register(o.LINE_BREAK_MULTIPLE_BLOCKS,RTEListItemBlock.name,new a),r.register(o.DELETE_NEST_LIST,RTEListItemBlock.name,new class extends t{handleAction(t,e){e.nestList&&(e.nestList=e.nestList.length>1?e.nestList.filter((e=>e!==t.nestListBlockToBeRemoved)):void 0)}}),r.register(o.SPLIT_BLOCK_WITH_NODE,RTEListItemBlock.name,new l),r.register(o.REPLACE_CHILD_NODES,RTEListItemBlock.name,new c),r.register(o.REPLACE_NEST_LIST,RTEListItemBlock.name,new class extends t{handleAction(t,e){t.newList.forEach((t=>{t.parent=e})),e.nestList=t.newList}}),r.register(o.MERGE_TWO_BLOCKS_NODES,RTEListItemBlock.name,new d),r.register(o.INSERT_IMAGE_TO_BLOCK,RTEListItemBlock.name,new class extends t{handleAction(t,e){e.parent.apply(t)}});class Y extends w{constructor(){super(...arguments),this.type=E.LIST}renderStyle(t){return(null==t?void 0:t.standalone)?{paddingLeft:"8px",marginLeft:"16px"}:null}renderClass(t){return(null==t?void 0:t.standalone)?null:"v-rte--list"}clone(){return new Y}toJSON(){}}class RTEListBlock extends g{constructor(t,e,n){super(t),this.type="bullet-list",this.children=[],this.type=e;const{autoMatchFormat:s}=n||{autoMatchFormat:!0};s&&this.annotationMap.set(E.LIST,new Y)}static from(t,e={autoMatchFormat:!0}){const n=new RTEListBlock(t.id,t.type,e),{annotations:s}=t;return s&&Object.entries(s).forEach((([t,e])=>{const s=this.createAnnotationEntity(t,e);U(s)&&n.annotationMap.set(...s)})),n.children=t.blocks.map((t=>{const s=RTEListItemBlock.from(t,e);return s.parent=n,s})),n}static createAnnotationEntity(t,e){switch(t){case"customAttribute":return k.from(e);case"customClass":return R.from(e);case"customStyle":return p.from(e)}}toJSON(){return Object.assign(Object.assign({},super.toJSON()),{id:this.id,type:this.type,blocks:this.children.map((t=>t.toJSON()))})}toHtml(){const t=this.getBlockTag();return[`<${t}${super.generateAttributeString()}>`,this.children.map((t=>t.toHtml())).join(""),`</${t}>`].join("")}isNotEmpty(){return this.children.length>0}getLastNode(){return this.children[this.children.length-1].getLastNode()}clone(){const t=new RTEListBlock(this.id,this.type);return t.children=this.children.map((e=>{const n=e.clone();return n.parent=t,n})),t.annotationMap=super.cloneAnnotations(),t.parent=this.parent,t}getBlockTag(){return"number-list"===this.type?"ol":"ul"}}r.register(o.TRANSFORM_LIST_BLOCK,RTEListBlock.name,new class extends t{handleAction(t,e){const n=t.selectedBlocks,r=e.parent.createList(t.listType);if(n.every((t=>t.parent===e)))r.apply(new s(e.children)),e.parent.apply(new u(e,r)),e.parent.apply(new h(e)),n.forEach((t=>t.children.map((t=>t.apply(new m)))));else{const n=t.selectedBlocks.map((t=>e.parent.toListItem(t)));r.apply(new s(n)),e.parent.apply(new u(e,r)),t.selectedBlocks.forEach((t=>{t.parent.apply(new h(t))})),0===e.children.length&&e.parent.apply(new h(e))}}}),r.register(o.TRANSFORM_PARAGRAPH_BLOCK,RTEListBlock.name,new class extends t{handleAction(t,e){let n=!1,r=!1;const o=t.selectedBlocks,i=o.map((t=>(t.children.map((t=>t.apply(new m))),t===e.children[0]&&(n=!0),t===e.children[e.children.length-1]&&(r=!0),this.toParagraph(t))));if(n)e.parent.apply(new T(e,...i));else if(r)e.parent.apply(new u(e,...i));else{const t=e.children.indexOf(o[0]),n=e.children.indexOf(o[o.length-1]),r=e.parent.createList(e.type);r.apply(new s(e.children.slice(0,t)));const a=e.parent.createList(e.type);a.apply(new s(e.children.slice(n+1))),e.parent.apply(new T(e,r,...i,a)),e.parent.apply(new h(e))}o.map((t=>{e.apply(new h(t))})),0===e.children.length&&e.parent.apply(new h(e))}toParagraph(t){const n=new e(F(),"paragraph");return n.apply(new s(t.children)),n.annotationMap=t.annotationMap,n}}),r.register(o.INSERT_IMAGE_TO_BLOCK,RTEListBlock.name,new class extends t{handleAction(t,e){e.parent.apply("list-item"!==e.parent.type?new u(e,t.imageBlockToBeInserted):t)}});class Z{}class _ extends Z{canHandle(t){return"RTETextNode"===t.name}handle(t,e={}){return this.isBold(t)||e.bold?{bold:!0}:{}}isBold(t){return"STRONG"===t.nodeName||"B"===t.nodeName||"bold"===t.style.fontWeight||"700"===t.style.fontWeight||t.classList.contains("v-rte--bold")}}class Q extends Z{canHandle(t,e){return!e.skipCustomAnnotations&&!!t}handle(t){const e=this.getAttributes(t);return Object.keys(e).length>0?{customAttribute:e}:{}}getAttributes(t){return t.getAttributeNames().filter((t=>"style"!==t&&"class"!==t&&this.isValidAttr(t))).reduce(((e,n)=>(e[n]=t.getAttribute(n),e)),{})}isValidAttr(t){return/^[a-zA-Z_][\w-]*$/.test(t)}}class q extends Z{canHandle(t,e){return!e.skipCustomAnnotations&&!!t}handle(t){const e=this.getCustomClass(t);return e.length>0?{customClass:e}:{}}getCustomClass(t){return t.classList.toString().split(" ").filter((t=>!t.includes("v-rte")&&""!==t))}}class tt extends Z{canHandle(t,e){return!e.skipCustomAnnotations&&!!t}handle(t){const e=this.generateCustomStyleAnnotations(t);return Object.keys(e).length>0?{customStyle:e}:{}}generateCustomStyleAnnotations(t){const e=t.getAttribute("style");return e?e.split(";").filter(Boolean).filter((t=>" "!==t)).map((t=>{const e=t.replace(/(['"])(.*?)\1/g,"$2").split(":");return{[z(e[0].trim())]:e[1].trim().replace(";","")}})).reduce(((t,e)=>Object.assign(Object.assign({},t),e)),{}):{}}}class et extends Z{canHandle(t){return["RTETextBlock","RTEListItemBlock","RTEListBlock"].includes(t.name)}handle(t){const e=this.getIndent(t);return e?{indent:e}:{}}getIndent(t){const e=t.style;let n;if(e.marginLeft)n=e.marginLeft;else{if(!e.margin)return null;{const t=e.margin.split(" ");switch(t.length){case 4:n=t[3];break;case 2:case 3:n=t[1];break;default:n=t[0]}}}const s=Number(n.replace("px",""));return s&&s>=0?Math.floor(s/16):null}}class nt extends Z{canHandle(t){return["RTETextBlock","RTEListItemBlock","RTEListBlock"].includes(t.name)}handle(t){const e=this.getTextAlign(t);return e?{textAlign:e}:{}}getTextAlign(t){const e=t.classList;if(e.contains("v-rte--horizontal-alignment-left"))return"left";if(e.contains("v-rte--horizontal-alignment-center"))return"center";if(e.contains("v-rte--horizontal-alignment-right"))return"right";if(e.contains("v-rte--horizontal-alignment-justify"))return"justify";switch(t.style.textAlign){case"center":return"center";case"right":return"right";case"justify":return"justify";case"left":return"left";default:return null}}}class st extends Z{canHandle(t){return"RTETextNode"===t.name}handle(t,e={}){return this.isCode(t)||e.code?{code:!0}:{}}isCode(t){return t.classList.contains("v-rte--code")||"CODE"===t.nodeName||"PRE"===t.nodeName||"monospace"===t.style.fontFamily||"Roboto Mono"===t.style.fontFamily.replace(/["']/g,"")}}class rt extends Z{canHandle(t){return"RTETextNode"===t.name}handle(t,e={}){const n=this.getColor(t)||e.textColor;return n?{textColor:n}:{}}getColor(t){var e;const n=null===(e=$(t.style.color))||void 0===e?void 0:e.toUpperCase();if(n){const t=B.filter((t=>t.key!==I.key)).find((t=>t.light===n||t.dark===n));return t?t.key:null}for(const e of B)if(t.style.color.includes(e.key))return e.key;return null}}class ot extends Z{canHandle(t){return"RTETextNode"===t.name}handle(t,e={}){return this.isItalic(t)||e.italic?{italic:!0}:{}}isItalic(t){return"I"===t.nodeName||"italic"===t.style.fontStyle||"EM"===t.nodeName||t.classList.contains("v-rte--italic")}}class it extends Z{constructor(){super(...arguments),this.handlers=[new Q,new q,new tt]}canHandle(t){return"RTETextNode"===t.name}handle(t,e={}){return e.link?{link:e.link}:"A"===t.tagName?{link:this.generateLinkAnnotations(t)}:{}}generateLinkAnnotations(t){const e={href:t.getAttribute("href")||"",groupKey:F()};return this.handlers.forEach((n=>{Object.assign(e,n.handle(t))})),e}}class at extends Z{canHandle(t){return"RTETextNode"===t.name}handle(t,e={}){return this.isStrikethrough(t)||e.strikethrough?{strikethrough:!0}:{}}isStrikethrough(t){return t.style.textDecoration.includes("line-through")||"S"===t.nodeName||"DEL"===t.nodeName||t.classList.contains("v-rte--strikethrough")}}class lt extends Z{canHandle(t){return"RTETextNode"===t.name}handle(t,e={}){return this.isUnderline(t)||e.underline?{underline:!0}:{}}isUnderline(t){return t.style.textDecoration.includes("underline")||"U"===t.nodeName||"INS"===t.nodeName||t.classList.contains("v-rte--underline")}}class ct extends Z{canHandle(t,e){return!!e.autoMatchFormat&&"RTETextBlock"===t.name}handle(t){const e=this.getTextStyle(t);return e?{textStyle:e}:{}}getTextStyle(t){const e=this.getElementTypeByDataType(t);if(e)return e;const n=this.getElementTypeByNodeName(t);if(n)return n;const s=this.getElementTypeByFontSize(t);if(s)return s;return this.getElementTypeByClassName(t)||null}getElementTypeByDataType(t){return t.nodeType!==Node.TEXT_NODE&&t.hasAttribute("data-type")?t.getAttribute("data-type"):null}getElementTypeByFontSize(t){var e;switch(null===(e=t.style)||void 0===e?void 0:e.fontSize){case"36px":return"title";case"28px":return"subtitle";case"22px":return"heading-1";case"20px":return"heading-2";case"18px":return"heading-3";default:return null}}getElementTypeByNodeName(t){switch(t.nodeName){case"H1":return"heading-1";case"H2":return"heading-2";case"H3":return"heading-3";case"H4":return"heading-4";case"H5":return"heading-5";case"H6":return"heading-6";default:return null}}getElementTypeByClassName(t){if(t.className){const e=/\bv-rte--text-style-(title|subtitle|heading-1|heading-2|heading-3|paragraph)\b/.exec(t.className);if(e)return e[1]}return null}}class dt extends Z{canHandle(t){return"RTEImageNode"===t.name}handle(t){const e=this.getImageSize(t);return e?{size:e}:{}}getImageSize(t){return t.getAttribute("data-size")?t.getAttribute("data-size"):null}}class ut extends Z{canHandle(t){return"RTEImageNode"===t.name}handle(t){return t.hasAttribute("alt")?{alt:t.getAttribute("alt")}:{}}}class ht extends Z{constructor(){super(...arguments),this.customAttributeHandler=new Q,this.customStyleAnnotationHandler=new tt,this.customClassAnnotationHandler=new q}canHandle(t,e){return"RTETextNode"===t.name&&!1===e.autoMatchFormat}handle(t,e){if(ht.canHandleTags.includes(t.nodeName)){const n=this.generateInlineHtmlAnnotation(t,Object.assign({},e));if(n)return{inlineHtml:n}}return{}}generateInlineHtmlAnnotation(t,e){let{inlineHtml:s}=e;if(!n.supportsHtmlTag(t.nodeName.toLowerCase())||1===t.childNodes.length&&t.childNodes[0].nodeType!==Node.TEXT_NODE){const e={htmlTag:t.nodeName.toLowerCase(),customAttribute:this.customAttributeHandler.handle(t).customAttribute,customStyle:this.customStyleAnnotationHandler.handle(t).customStyle,customClass:this.customClassAnnotationHandler.handle(t).customClass};if(s){let n=s;for(;n.child&&t.parentNode&&n.child.htmlTag===t.parentNode.nodeName.toLowerCase();)n=n.child;n.child=e}else s=e}return s?Object.assign({},s):null}}ht.canHandleTags=["A","ABBR","AUDIO","B","BDI","BDO","CITE","CODE","DEL","DFN","EMBED","EM","I","INS","KBD","MARK","METER","OUTPUT","PROGRESS","Q","S","SMALL","SPAN","STRONG","SUB","SUP","TIME","U","VAR","VIDEO"];const mt=new class{constructor(){this.handlers=[new nt,new et,new _,new ot,new lt,new at,new rt,new it,new st,new dt,new ut,new Q,new q,new tt,new it,new ct,new ht]}generate(t,e,n={autoMatchFormat:!0}){const s="A"===e.tagName;return this.handlers.filter((t=>!(!n.autoMatchFormat&&s)||t instanceof it)).filter((r=>e.nodeType!==Node.TEXT_NODE&&r.canHandle(t,{skipCustomAnnotations:n.skipCustomAnnotations||s,autoMatchFormat:n.autoMatchFormat}))).reduce(((t,s)=>{const r=s.handle(e,n.parentAnnotations);return Object.assign(Object.assign({},t),r)}),{})}};class Tt{generateTextStyleAnnotations(t,e){return mt.generate(n,t,e)}}class wt{constructor(t,e){this.childrenOutput=[],this.currentStrategy=t,this.currentElements=e}setChildrenOutput(t){this.childrenOutput=t}toDto(t={autoMatchFormat:!0,skipCustomAnnotations:!0}){const e=this.currentStrategy.handle(this.currentElements,t);return this.childrenOutput.length>0&&e&&this.currentStrategy.appendChildBlocks(e,this.childrenOutput.map((e=>e.toDto(t))).filter(U)),e}}const Et=new class{constructor(){this.elementToBlockStrategies=[],this.elementToNodeStrategies=[]}registerElementToBlockStrategy(t){this.hasDuplicateStrategy(t,this.elementToBlockStrategies)||this.elementToBlockStrategies.unshift(t)}registerElementToNodeStrategy(t){this.hasDuplicateStrategy(t,this.elementToNodeStrategies)||this.elementToNodeStrategies.unshift(t)}getElementToBlockStrategies(){return this.elementToBlockStrategies}getElementToNodeStrategies(){return this.elementToNodeStrategies}hasDuplicateStrategy(t,e){return e.includes(t)}},gt=new class{process(t,e={autoMatchFormat:!0,skipCustomAnnotations:!0}){const n=this.getElementToBlockStrategies(),s=[];for(let r=0;r<t.length;r++){if(this.isInvalidElement(t[r]))continue;let o=0;for(const i of n)if(o=i.canHandle(t,r,e),o>0){const n=t.slice(r,r+o),a=new wt(i,n);1===o&&i.shouldProceedToElementChildren()&&a.setChildrenOutput(this.process(Array.from(n[0].childNodes),e)),s.push(a),r+=o-1;break}if(0===o&&r<t.length){const n=Array.from(t[r].childNodes),o=this.process(Array.from(n),e);o.length>0&&s.push(...o)}}return s}isInvalidElement(t){return t.nodeType===Node.COMMENT_NODE||["META","STYLE"].includes(t.nodeName)}getElementToBlockStrategies(){return Et.getElementToBlockStrategies()}};class pt extends t{handleAction(t,e){const n=t.entityToBeAppended;e.children&&(n.forEach((t=>{t.parent=e})),e.children=e.children.concat(n))}}class Rt extends t{handleAction(t,e){this.replaceElementWithElements(e,t.referChildren,[...t.childrenToBeInserted,t.referChildren])}replaceElementWithElements(t,e,n){t.children&&(n.forEach((e=>{e.parent=t})),t.children=t.children.flatMap((t=>t===e?n:t)))}}class kt extends Rt{handleAction(t,e){this.replaceElementWithElements(e,t.referChildren,[t.referChildren,...t.childrenToBeInserted])}}class ft extends b{constructor(t,e){super(),this.type=O.IMAGE,this.size=t,this.alt=e}static from(t,e){return[O.IMAGE,new ft(t,e)]}toJSON(){return U(this.alt)?{size:this.size,alt:this.alt}:{size:this.size}}clone(){return new ft(this.size,this.alt)}renderClass(t){return(null==t?void 0:t.standalone)?null:this.size?`v-rte--image-size-${this.size}`:null}renderStyle(t){if(!(null==t?void 0:t.standalone))return null;const e={verticalAlign:"bottom"};switch(this.size){case"sm":return Object.assign(Object.assign({},e),{width:"25%"});case"md":return Object.assign(Object.assign({},e),{width:"50%"});case"lg":return Object.assign(Object.assign({},e),{width:"100%"})}}}class RTEImageNode extends L{constructor(t,e,n,s){super(t,s),this.type=y.IMAGE,this.url=e,this.parent=n}static from(t,e,n={autoMatchFormat:!0}){const s=new RTEImageNode(t.id,t.url,e),r=!!n.autoMatchFormat,o=Object.assign({},t.annotations),{size:i}=o,a=function(t,e){var n={};for(var s in t)Object.prototype.hasOwnProperty.call(t,s)&&e.indexOf(s)<0&&(n[s]=t[s]);if(null!=t&&"function"==typeof Object.getOwnPropertySymbols){var r=0;for(s=Object.getOwnPropertySymbols(t);r<s.length;r++)e.indexOf(s[r])<0&&Object.prototype.propertyIsEnumerable.call(t,s[r])&&(n[s[r]]=t[s[r]])}return n}(o,["size"]),l=Object.assign(Object.assign({},a),{size:null!=i?i:r?"md":void 0});return s.annotationMap=new Map(Object.keys(l).map((t=>"size"===t||"alt"===t?ft.from(l.size,l.alt):this.createAnnotationEntity(t,l[t]))).filter(U)),s}toJSON(){const t=Array.from(this.annotationMap.values()).filter((t=>t instanceof ft||t instanceof A)).reduce(((t,e)=>Object.assign(Object.assign({},t),e.toJSON())),{});return""==t.alt&&delete t.alt,Object.assign(Object.assign({id:this.id},Object.keys(t).length>0?{annotations:t}:{}),{type:"image",url:this.url})}clone(){return new RTEImageNode(this.id,this.url,this.parent,super.cloneAnnotations())}toHtml(){const t=this.getAnnotationByType(O.IMAGE);return`<img${super.generateAttributeString(...[t&&t.alt?`alt="${t.alt}"`:null,`src="${this.url}"`,t&&t.size?`data-size="${t.size}"`:null].filter(U))}>`}doAnnotationActionApply(t){const e=r.get(N.name,RTEImageNode.name);e&&e.execute(t,this)}doModifyActionApply(t){r.executeTheStrategy(t,this)}}r.register(o.UPDATE_IMAGE_NODE_URL,RTEImageNode.name,new class extends t{handleAction(t,e){e.url=t.url}}),r.register(N.name,RTEImageNode.name,new class extends t{handleAction(t,e){const n=t.toAnnotation();e.annotationMap.set(n.type,n)}});class Bt extends j{constructor(t,e){super(),this.type=o.INSERT_NEW_PARAGRAPH,this.startContainerNode=t,this.startOffset=e}}class RTEImageBlock extends g{constructor(t){super(t),this.type="image",this.children=[]}static from(t,e={autoMatchFormat:!0}){const n=new RTEImageBlock(t.id),{annotations:s}=t;return n.children=t.nodes.map((t=>RTEImageNode.from(t,n,e))),s&&super.convertAnnotationsToMap(n.annotationMap,s),n}toJSON(){return Object.assign(Object.assign({},super.toJSON()),{type:"image",nodes:this.children.map((t=>t.toJSON()))})}toHtml(){const t=super.generateAttributeString(),e=this.children.map((t=>t.toHtml())).join("");return super.shouldRenderAsInternalWrapper()?e:[`<div${t}>`,e,"</div>"].join("")}isNotEmpty(){return this.children.length>0&&this.children.some((t=>t.url.length>0))}getLastNode(){return this.children[this.children.length-1]}createNewImageBlock(){return new RTEImageBlock(F())}clone(){const t=new RTEImageBlock(this.id);return t.children=this.children.map((e=>{const n=e.clone();return n.parent=t,n})),t.annotationMap=super.cloneAnnotations(),t.parent=this.parent,t}}r.register(o.MERGE_TWO_BLOCKS_NODES,RTEImageBlock.name,new d),r.register(o.REPLACE_CHILD_NODES,RTEImageBlock.name,new c),r.register(o.SPLIT_BLOCK_WITH_NODE,RTEImageBlock.name,new class extends t{handleAction(t,e){t.newBlock=this.splitImageNodes(t.splitPointNode,t.startOffsetOfNode,e)}splitImageNodes(t,e,n){const s=n.children.indexOf(t);if(s>-1){const t=n.children.slice(0,s+e),r=n.children.slice(s+e);n.apply(new C(t));const o=this.cloneWithNodes(r,n);return n.parent.apply(new u(n,o)),o}}cloneWithNodes(t,e){const n=e.createNewImageBlock();return n.children=[],n.apply(new s(t)),n}}),r.register(o.LINE_BREAK_SINGLE_BLOCK,RTEImageBlock.name,new class extends t{handleAction(t,e){const n=new Bt(t.startContainerNode,t.startOffset);e.apply(n);const s=n.newBlock;s&&(t.lineBreakNode=s.children[0])}}),r.register(o.LINE_BREAK_MULTIPLE_BLOCKS,RTEImageBlock.name,new class extends t{handleAction(t,e){t.lineBreakNode=this.lineBreakMultipleBlocks(t.selectedBlocks,e)}lineBreakMultipleBlocks(t,r){const o=e.from({id:F(),type:"paragraph",nodes:[{id:F(),type:"text",text:"\n"}]});r.parent.apply(new u(r,o));const i=this.concatBlocksNodes(t.slice(1));return(0===i.length||i[0]&&""===i[0].text)&&i.push(new n(F(),"\n",o)),o.apply(new s(i)),o.children[0]}concatBlocksNodes(t){const e=[];return t.map((t=>{"image"!==t.type&&(e.push(...t.children),t.parent.apply(new h(t)))})),e}}),r.register(o.INSERT_IMAGE_TO_BLOCK,RTEImageBlock.name,new class extends t{handleAction(t,e){const n=t.splitPointNode,r=t.startOffsetOfNode,o=t.imageBlockToBeInserted;e.children.length<1?e.apply(new s(o.children)):this.isCaretPositionAtBlockEnd(e,n,r)?e.parent.apply(new u(e,o)):this.isCaretPositionAtBlockStart(e,n,r)?e.parent.apply(new T(e,o)):(e.apply(new H(n,r)),e.parent.apply(new u(e,o)))}}),r.register(S.name,RTEImageBlock.name,new v);class RTEHtmlBlock extends g{constructor(t,e){super(t),this.type="html-block",this.children=[],this.htmlTag=e}static from(t,e){const n=new RTEHtmlBlock(t.id,t.htmlTag),{annotations:s}=t;return s&&super.convertAnnotationsToMap(n.annotationMap,s),n.children=t.children.map((t=>{const s=D.getRTEBlockClass(t.type);if(s){const r=s.from(t,e);return r.parent=n,r}})).filter(U),n}clone(){const t=new RTEHtmlBlock(this.id,this.htmlTag);return t.children=this.children.map((t=>t.clone())),t.annotationMap=super.cloneAnnotations(),t}getLastNode(){return this.children[this.children.length-1].getLastNode()}isNotEmpty(){return this.children.length>0}toHtml(){const t=this.htmlTag;return[`<${t}${super.generateAttributeString()}>`,this.children.map((t=>t.toHtml())).join(""),`</${t}>`].join("")}toJSON(){return Object.assign(Object.assign({},super.toJSON()),{id:this.id,type:this.type,htmlTag:this.htmlTag,children:this.children.map((t=>t.toJSON()))})}}class It extends j{constructor(t){super(),this.type=o.MERGE_TWO_BLOCKS_NODES,this.blockNeedToBeMerged=t}}class xt extends M{handleAction(t,e){const{startContainerNode:n}=t;n.isContentEditable()?n.isTextNode()&&this.deleteTextNodeContent(t,e):this.deleteDecoratorNodeContent(t,e);const s=e.parent;s&&e.isListItemBlock()&&0===s.children.length&&s.parent.apply(new h(s))}deleteTextNodeContent(t,e){const n=t.startContainerNode,s=t.startOffset;if(0!==s&&!n.isEmpty()){const r=n.text.slice(0,s-1)+n.text.slice(s);if(n.apply(new P(r)),r)return void(t.previousNode=n);{const s=this.getPreviousNode(n);return s&&s.parent===e&&"\n"===s.text||1===e.children.length?void(t.previousNode=n):(e.apply(new h(n)),void(t.previousNode=s))}}{let s=this.getPreviousNode(n),r=null;const o=n.isEmpty();if(e.children.length&&s&&s.parent!==e)o&&e.apply(new h(n)),e.type===s.parent.type&&s.parent.apply(new It(e));else if(this.isContentFirstNode(n)&&o&&(r=this.getNextNode(n)),o&&e.apply(new h(n)),s&&s.isTextNode()&&(s.isEmpty()||!s.isContentEditable()&&s.parent===e)){const t=s;s=this.getPreviousNode(s),t.parent.apply(new h(t)),s||o||(r=n)}0===e.children.length&&e.parent.apply(new h(e)),s?t.previousNode=s:r&&(t.nextNode=r)}}deleteDecoratorNodeContent(t,e){const n=t.startContainerNode,s=t.startOffset;let r=this.getPreviousNode(n),o=null;if(0!==s){const t=e;this.isContentFirstNode(n)&&(o=this.getNextNode(n)),1===t.children.length?t.parent.apply(new h(t)):t.apply(new h(n))}else{const e=r;e&&!e.isContentEditable()&&(r=this.getPreviousNode(e),e.parent.apply(new h(e)),r||(t.nextNode=n))}r?t.previousNode=r:o&&(t.nextNode=o)}}class bt extends t{handleAction(t,e){const{startContainerNode:n}=t;t.newBlock=this.breakSingleBlock(n,t.startOffset,e)}breakSingleBlock(t,e,n){const s=this.getNewParagraph(t);if(s){if(this.isCaretPositionAtBlockEnd(n,t,e))n.parent.apply(new u(n,s));else{if(!this.isCaretPositionAtBlockStart(n,t,e)){const s=new H(t,e);return n.apply(s),s.newBlock}n.parent.apply(new T(n,s))}return s}}getNewParagraph(t){const e=this.createNewParagraph("");if(e){let n=e.children[0];return t.isTextNode()&&t.isContentEditable()&&(e.children=[],n=t.cloneWithText(""),n.annotationMap.delete(O.LINK),e.apply(new s([n]))),e}}}class Ot extends j{constructor(t,e,n=!1){super(),this.type=o.UPDATE_CURSOR_POSITION,this.immediatelyRun=!1,this.nextFocusNode=t,this.offset=e,this.immediatelyRun=n}}class Lt extends t{handleAction(t,e){const{rteRange:n,nodeToBeInserted:s}=t,{startNode:r,startOffset:o}=n;if(r){const t=e;if(r.isContentEditable()&&r.isTextNode())if("\n"!==r.text&&r.text&&0!==o){const e=r.text.substring(0,o),n=r.text.substring(o),i=r.cloneWithText(e),a=r.cloneWithText(n),l=[i,s];n&&l.push(a),t.apply(new T(r,...l)),t.apply(new h(r))}else t.apply(new T(r,s));else t.apply(0!==o?new u(r,s):new T(r,s));this.updateCursorPosition(s)}}updateCursorPosition(t){const e=this.getRootContent(t.parent);e&&e.apply(new Ot(t))}}class yt extends t{handleAction(t,e){const{text:n,offset:s,decoratorNode:r}=t,o=this.createNewParagraph(n);if(o){const t=o.children[0];e.apply(0!==s?new u(r,t):new T(r,t)),this.setTheCursorPosition(t)}}setTheCursorPosition(t){const e=this.getRootContent(t.parent);e&&e.apply(new Ot(t))}}class At extends t{handleAction(t,e){t.newBlock=this.breakSingleListItemBlock(t.startContainerNode,t.startOffset,e)}breakSingleListItemBlock(t,e,n){const r=n.createNewListItem(),o=this.copyInlineStyleToNewNode(t);if(r.apply(new s([o])),this.isCaretPositionAtBlockEnd(n,t,e))return this.breakListItemAtEnd(r,n);if(!this.isCaretPositionAtBlockStart(n,t,e)){const s=new H(t,e);return n.apply(s),s.newBlock}return n.parent.apply(new T(n,r)),r}breakListItemAtEnd(t,n){const r=n.parent.children[n.parent.children.length-1],o=1===n.children.length&&n.children[0].isEmpty();if(n===r&&o){const r=n.parent.parent;if("list-item"!==r.type){const o=e.from({id:F(),type:"paragraph",nodes:[]});return o.apply(new s(t.children)),r.apply(new u(n.parent,o)),n.parent.apply(new h(n)),o}r.parent.apply(new u(r,t)),n.parent.apply(new h(n))}else n.parent.apply(new u(n,t));return t}copyInlineStyleToNewNode(t){const e=t.cloneWithText("");return e.annotationMap.delete(O.LINK),e}}class Nt extends j{constructor(t){super(),this.type=o.DELETE_NEST_LIST,this.nestListBlockToBeRemoved=t}}class Ct extends V{handleAction(t,e){super.handleAction(t,e);const n=e.parent;0===e.children.length&&n&&n.apply("list-item"===n.type?new Nt(e):new h(e))}}const jt=new class{registerBlockBasicStrategies(t){r.register(o.DELETE_CHILDREN,t,t===RTEListBlock.name?new Ct:new V),r.register(o.APPEND_CHILDREN,t,new pt),r.register(o.INSERT_CHILDREN_BEFORE,t,new Rt),r.register(o.INSERT_CHILDREN_AFTER,t,new kt),r.register(o.DELETE_BLOCK_CONTENT,t,new xt),r.register(o.INSERT_NEW_PARAGRAPH,t,t===RTEListItemBlock.name?new At:new bt),r.register(o.INSERT_TEXT_TO_DECORATOR_NODE,t,new yt),r.register(o.INSERT_NODE_TO_NEAREST_ROOT,t,new Lt)}};class Ht extends Tt{constructor(){super(...arguments),this.annotationHandler=new ct}generateChildNodes(t,e,s){const r=[],o=!(!s||!1!==s.autoMatchFormat),i=Object.assign({},e);return t.forEach((t=>{const a=Et.getElementToNodeStrategies().find((e=>e.canHandle([t],0,s)>0));let l=null;if(a&&(l=a.handle([t],s,i)),l)r.push(l);else if(G(t)&&t.childNodes.length>0){const a=mt.generate(n,t,Object.assign({parentAnnotations:o?{inlineHtml:i.inlineHtml,link:i.link,code:i.code}:e},s));r.push(...this.generateChildNodes(Array.from(t.childNodes),a,s))}})),r}matchTextBlockType(t){var e;return null!==(e=this.annotationHandler.handle(t).textStyle)&&void 0!==e?e:"paragraph"}}class St extends Ht{canHandle(t,e,n){const s=t[e];return!n.autoMatchFormat&&("DIV"!==s.nodeName||s.childNodes.length>0&&"IMG"!==s.childNodes[0].nodeName)&&St.canHandleTags.includes(t[e].nodeName)?1:0}handle(t,e){return RTEHtmlBlock.from(this.generateHtmlBlock(t[0],e),e)}appendChildBlocks(t,e){t.children=e.map((e=>(e.parent=t,e)))}shouldProceedToElementChildren(){return!0}generateHtmlBlock(t,e){return{id:F(),type:"html-block",htmlTag:t.nodeName.toLowerCase(),annotations:mt.generate(RTEHtmlBlock,t,e),children:[]}}}St.canHandleTags=["ADDRESS","ARTICLE","ASIDE","BLOCKQUOTE","BUTTON","CAPTION","COL","COLGROUP","DIV","DD","DETAILS","DL","DT","FIELDSET","FIGCAPTION","FIGURE","FOOTER","FORM","HEADER","HR","HX","INPUT","LEGEND","MAIN","NAV","PRE","SECTION","SUMMARY","TABLE","TBODY","TD","TFOOT","TH","THEAD","TR"];class vt extends Ht{canHandle(t,e){return"PRE"!==t[e].tagName&&"CODE"!==t[e].tagName||!t[e].hasAttribute("data-language")?0:1}handle(t){const e=t[0];if(e){const t=e.textContent,n=e.dataset.language;return f.from({id:F(),type:"code-block",content:t,language:n})}}appendChildBlocks(){}shouldProceedToElementChildren(){return!1}}class Dt extends Ht{createRTEImageBlock(t,e){const n=!(e&&e.autoMatchFormat||!t.parentNode||"DIV"===t.parentNode.nodeName);return RTEImageBlock.from({id:F(),type:"image",nodes:[{id:F(),type:"image",url:t.src,annotations:mt.generate(RTEImageNode,t,e)}],annotations:Object.assign(Object.assign({},mt.generate(RTEImageBlock,t.parentElement,e)),{internalWrapper:n})},e)}}class Mt extends Ht{canHandle(t,e){let n=0;for(let s=e;s<t.length;s++){const e=t[s];if(e.nodeType!==Node.TEXT_NODE&&(!Mt.canHandleTags.includes(e.nodeName)||""===e.textContent&&e.querySelector("IMG")))break;n++}return n}handle(t,s){const r=t[0].parentElement,o=s&&s.autoMatchFormat,i=this.generateChildNodes(t,o?mt.generate(n,r,Object.assign(Object.assign({},s),{skipCustomAnnotations:!0})):{},s),a=o?super.matchTextBlockType(r):this.matchTextBlockTypeByTagName(r),l=!o&&!a;return e.from(Object.assign({id:F(),type:a||"paragraph",nodes:i},l?{annotations:{internalWrapper:l}}:{annotations:mt.generate(e,r,s)}),s)}appendChildBlocks(){}shouldProceedToElementChildren(){return!1}matchTextBlockTypeByTagName(t){switch(t.nodeName){case"P":return"paragraph";default:return null}}}Mt.canHandleTags=[...ht.canHandleTags,"CODE","A","VEGA-RICH-TEXT-LINK-EDITOR","BR"];class Pt extends Tt{shouldProceedToElementChildren(){return!1}appendChildBlocks(){}generateTextNode(t,e){return{id:F(),type:"text",text:t,annotations:e}}}D.registerRTEDTOClass("paragraph",e),D.registerRTEDTOClass("title",e),D.registerRTEDTOClass("subtitle",e),D.registerRTEDTOClass("heading-1",e),D.registerRTEDTOClass("heading-2",e),D.registerRTEDTOClass("heading-3",e),D.registerRTEDTOClass("heading-4",e),D.registerRTEDTOClass("heading-5",e),D.registerRTEDTOClass("heading-6",e),D.registerRTEDTOClass("heading-6",e),D.registerRTEDTOClass("list-item",RTEListItemBlock),D.registerRTEDTOClass("bullet-list",RTEListBlock),D.registerRTEDTOClass("number-list",RTEListBlock),D.registerRTEDTOClass("image",RTEImageBlock),D.registerRTEDTOClass("code-block",f),D.registerRTEDTOClass("html-block",RTEHtmlBlock),D.registerRTEDTOClass("text",n),D.registerRTEDTOClass("image",RTEImageNode),jt.registerBlockBasicStrategies(e.name),jt.registerBlockBasicStrategies(RTEListBlock.name),jt.registerBlockBasicStrategies(RTEListItemBlock.name),jt.registerBlockBasicStrategies(RTEImageBlock.name),jt.registerBlockBasicStrategies(RTEHtmlBlock.name),Et.registerElementToBlockStrategy(new Mt),Et.registerElementToBlockStrategy(new class extends Dt{canHandle(t,e){const n=t[e];return n.nodeType===Node.ELEMENT_NODE&&""===n.textContent&&n.querySelector("img")?1:0}handle(t,e){const n=t[0].querySelector("img");return this.createRTEImageBlock(n,e)}appendChildBlocks(){}shouldProceedToElementChildren(){return!1}}),Et.registerElementToBlockStrategy(new class extends Dt{canHandle(t,e){return"VEGA-RICH-TEXT-IMAGE-EDITOR"===t[e].tagName?1:0}handle(t,e){const n=t[0],s=n.querySelector("img");if(U(s))return RTEImageBlock.from({id:F(),type:"image",nodes:[{id:F(),type:"image",url:s.src,annotations:mt.generate(RTEImageNode,n,e)}],annotations:mt.generate(RTEImageBlock,n.parentElement,e)},e)}appendChildBlocks(){}shouldProceedToElementChildren(){return!1}}),Et.registerElementToBlockStrategy(new class extends Dt{canHandle(t,e){return"IMG"===t[e].tagName?1:0}handle(t,e){return this.createRTEImageBlock(t[0],e)}appendChildBlocks(){}shouldProceedToElementChildren(){return!1}}),Et.registerElementToBlockStrategy(new class extends Ht{canHandle(t,e){return["heading-1","heading-2","heading-3","heading-4","heading-5","heading-6","title","subtitle"].includes(super.matchTextBlockType(t[e]))?1:0}handle(t,n){const s=this.generateChildNodes(Array.from(t[0].childNodes),{},n);return 0===s.length?null:e.from({id:F(),type:super.matchTextBlockType(t[0]),nodes:s,annotations:mt.generate(e,t[0],n)},n)}appendChildBlocks(){}shouldProceedToElementChildren(){return!1}}),Et.registerElementToBlockStrategy(new vt),Et.registerElementToBlockStrategy(new class extends vt{canHandle(t,e){return"VEGA-CODE-BLOCK"===t[e].tagName&&0==!!t[e].querySelector("vega-code-block")||this.isCodeBlockContainer(t[e])?1:0}handle(t){const e=this.isCodeBlockContainer(t[0])?t[0].querySelector("vega-code-block"):t[0],n=e.querySelector("code");if(n)return super.handle([n]);if(e.hasAttribute("data-content")){const t=document.createElement("code");return t.textContent=e.dataset.content,t.dataset.language=e.dataset.language,super.handle([t])}}appendChildBlocks(){}shouldProceedToElementChildren(){return!1}isCodeBlockContainer(t){return"PRE"===t.tagName&&t.classList.contains("code-block-container")&&1===t.querySelectorAll("vega-code-block").length}}),Et.registerElementToBlockStrategy(new class extends Ht{canHandle(t,e){if(!["UL","OL"].includes(t[e].parentElement.nodeName)&&t.some((t=>"LI"===t.nodeName))){let n=0;for(let s=e;s<t.length&&"LI"===t[s].nodeName;s++)n++;return n}return"LI"===t[e].tagName?1:0}handle(t,e){const n=t[0];return["UL","OL"].includes(n.parentElement.nodeName)?RTEListItemBlock.from(this.generateListItemBlockDTO(n,e),e):this.generateWithListBlock(t,e)}appendChildBlocks(t,e){t.nestList=e.filter((t=>["bullet-list","number-list"].includes(t.type)))}shouldProceedToElementChildren(){return!0}generateWithListBlock(t,e){return RTEListBlock.from({id:F(),type:"bullet-list",blocks:t.map((t=>this.generateListItemBlockDTO(t,e)))},e)}generateListItemBlockDTO(t,e){return{id:F(),type:"list-item",annotations:mt.generate(RTEListItemBlock,t,e),nodes:this.generateChildNodes(Array.from(t.childNodes.length?t.childNodes:[t]).filter((t=>!["UL","OL"].includes(t.nodeName))),mt.generate(n,t,Object.assign(Object.assign({},e),{skipCustomAnnotations:!0})),e)}}}),Et.registerElementToBlockStrategy(new class extends Ht{canHandle(t,e){const n=t[e],s=n.parentElement,r="LI"!==n.nodeName,o=n.nodeType===Node.TEXT_NODE&&""===n.textContent.trim(),i=U(s)&&["UL","OL"].includes(s.nodeName);return r&&!o&&i?1:0}handle(t,e){const n=this.generateChildNodes(t,{},e);return RTEListItemBlock.from({id:F(),type:"list-item",nodes:n,annotations:{}},e)}appendChildBlocks(){}shouldProceedToElementChildren(){return!1}}),Et.registerElementToBlockStrategy(new class extends Ht{canHandle(t,e){return"OL"===t[e].tagName?1:0}handle(t,e){return 0===t[0].childNodes.length?null:RTEListBlock.from({id:F(),type:"number-list",blocks:[],annotations:mt.generate(RTEListBlock,t[0],e)},e)}appendChildBlocks(t,e){t.children=e.filter((t=>t instanceof RTEListItemBlock)),e.forEach((e=>e.parent=t))}shouldProceedToElementChildren(){return!0}}),Et.registerElementToBlockStrategy(new class extends Ht{canHandle(t,e){return"UL"===t[e].tagName?1:0}handle(t,e){return 0===t[0].childNodes.length?null:RTEListBlock.from({id:F(),type:"bullet-list",blocks:[],annotations:mt.generate(RTEListBlock,t[0],e)},e)}appendChildBlocks(t,e){t.children=e.filter((t=>t instanceof RTEListItemBlock)),e.forEach((e=>e.parent=t))}shouldProceedToElementChildren(){return!0}}),Et.registerElementToBlockStrategy(new St),Et.registerElementToNodeStrategy(new class extends Pt{canHandle(t,e){const n=t[e];return!G(n)||"BR"!==n.nodeName&&0!==n.childNodes.length?0:1}handle(t,e,s){const r=!(!e||!1!==e.autoMatchFormat),o=Object.assign({},s),i=t[0],a=mt.generate(n,i,Object.assign({parentAnnotations:r?{inlineHtml:o.inlineHtml,link:o.link,code:o.code}:s},e));if("BR"===i.nodeName)return this.generateTextNode("\n",a);if(0===i.childNodes.length){const t=r?X(Object.assign(Object.assign({},n.supportsHtmlTag(i.nodeName.toLowerCase())?a:{}),{inlineHtml:a.inlineHtml,plainText:U(a.inlineHtml)})):a;return Object.assign({},this.generateTextNode("",t))}}}),Et.registerElementToNodeStrategy(new class extends Pt{canHandle(t,e){return t[e].nodeType===Node.TEXT_NODE?1:0}handle(t,e,s){const r=Object.assign({},s),o=!(!e||!1!==e.autoMatchFormat),i=t[0],a=i.parentNode.nodeName.toLowerCase(),l=o&&!n.supportsHtmlTag(a),c=this.generateTextNode(String(i.textContent),o?X(Object.assign(Object.assign({},"span"===a?r:{link:r.link,code:"code"===a?r.code:void 0}),{inlineHtml:r.inlineHtml,plainText:l||void 0})):r);return Object.assign({},c)}});class Vt{static preserve(t){const e=t.replace(/\s+style=/g," data-style=");return new Ft(e)}}class Ft{constructor(t){this.processedHtml=t}getProcessedHtml(){return this.processedHtml}restore(t){this.walkNodes(t)}walkNodes(t){t.forEach((t=>{if(G(t)){const e=t.getAttribute("data-style");e&&(t.style.cssText=e,t.removeAttribute("data-style")),t.children.length>0&&this.walkNodes(Array.from(t.children))}}))}}class VegaRTEContent{constructor(t){t.forEach((t=>{t.parent=this})),this.children=t}static fromJSON(t,e={autoMatchFormat:!0}){const n=t.map((t=>{const n=D.getRTEBlockClass(t.type);if(n)return n.from(t,e);throw new Error(`[Vega] Unknown block type: ${t.type}`)}));return new VegaRTEContent(n)}static createEmptyContent(){return VegaRTEContent.fromJSON([{id:F(),type:"paragraph",nodes:[{id:F(),type:"text",text:""}]}])}static fromHtml(t,e={autoMatchFormat:!0,skipCustomAnnotations:!1}){const n=t.replace(/>\s+<\/?/g,(t=>t.endsWith("</")?t:"><")).replace(/(>)[\n\t]+(?=[a-zA-Z0-9_\W])/g,"$1").replace(/([a-zA-Z0-9_\W])[\n\t]+(?=<)/g,"$1"),s=Vt.preserve(n),r=s.getProcessedHtml(),o=(new DOMParser).parseFromString(r,"text/html").body,i=Array.from(o.childNodes);s.restore(i);const a=gt.process(i,e).filter(U).map((t=>t.toDto(e))).filter(U);return new VegaRTEContent(a)}clone(t=!1){return new VegaRTEContent(t?this.children.map((t=>t.clone())):[...this.children])}toJSON(){return this.children.map((t=>t.toJSON()))}toHtml(t){return this.children.map((e=>e.toHtml(t))).join("")}apply(t){r.executeTheStrategy(t,this)}getLastNode(){return 0===this.children.length?null:this.children[this.children.length-1].getLastNode()}toListItem(t){t.children.map((t=>t.apply(new m)));const e=new RTEListItemBlock(F());return e.apply(new s(t.children)),e.annotationMap=t.annotationMap,e}createList(t){return new RTEListBlock(F(),t)}findNodeById(t){return this.findNodeInBlocksById(t,this.children)}findNodeInBlocksById(t,e){for(const n of e){if("children"in n)for(const e of n.children)if(e.id===t)return e;if(n instanceof RTEListItemBlock&&n.nestList)for(const e of n.nestList){const n=this.findNodeInBlocksById(t,e.children);if(n)return n}if(n instanceof RTEListBlock&&n.children){const e=this.findNodeInBlocksById(t,n.children);if(e)return e}}return null}}r.register(o.DELETE_CHILDREN,VegaRTEContent.name,new V),r.register(o.APPEND_CHILDREN,VegaRTEContent.name,new pt),r.register(o.INSERT_CHILDREN_BEFORE,VegaRTEContent.name,new Rt),r.register(o.INSERT_CHILDREN_AFTER,VegaRTEContent.name,new kt),r.register(o.TRANSFORM_TO_CODE_BLOCK,VegaRTEContent.name,new class extends t{handleAction(t,e){const n=t.selectedBlocks,s=new f(F(),this.getCodeContent(n),"plainText");e.apply(new T(n[0],s)),t.newCodeBlock=s,this.removeSelectBlocks(n,e)}getCodeContent(t){return t.filter((t=>"image"!==t.type&&"list-item"!==t.type)).map((t=>t.children.map((t=>t.text)).join(""))).join("\n")}removeSelectBlocks(t,e){for(let n=0;n<t.length;n++)e.apply(new h(t[n]))}}),r.register(o.UPDATE_CURSOR_POSITION,VegaRTEContent.name,new class extends t{handleAction(t,e){const{offset:n,nextFocusNode:s,immediatelyRun:r}=t,o=x.getDOMByEntity(e);o&&J.notify(W.getSubject(o,K),{node:s,offset:n,updateDirectly:r})}});const Ut=new class{constructor(){this.RTE_DTO_RENDERER_MAP=new Map,this.RTE_TOOLBAR_BUTTON_RENDERER_MAP=new Map}registerRTEDTORenderer(t,e){const n=this.RTE_DTO_RENDERER_MAP.get(t);if(e&&n&&n.constructor.name!==e.constructor.name)throw new Error(`Renderer for type ${t} is already registered with a different class(${n.constructor.name}).`);this.RTE_DTO_RENDERER_MAP.set(t,e)}registerRTEToolbarButtonRenderer(t,e){this.RTE_TOOLBAR_BUTTON_RENDERER_MAP.set(t,e)}getRTERenderer(t){return this.RTE_DTO_RENDERER_MAP.get(t)}getRTEToolbarButtonRenderer(t){return this.RTE_TOOLBAR_BUTTON_RENDERER_MAP.get(t)}};export{Et as E,ft as I,It as M,Ut as R,Vt as S,Ot as U,VegaRTEContent as V,jt as a,Tt as b,RTEListItemBlock as c,RTEImageBlock as d,RTEListBlock as e,RTEImageNode as f,Bt as g,gt as h}
File without changes