@heartlandone/vega 2.86.0 → 2.87.0-beta.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cjs/{accessibility-a5ef2038.js → accessibility-88f8af84.js} +16 -1
- package/dist/cjs/{app-globals-3080f55a.js → app-globals-885090b1.js} +11 -11
- package/dist/cjs/{aria-dialog-focusable-trap-slimmer-5507f917.js → aria-dialog-focusable-trap-slimmer-c2ca46db.js} +3 -3
- package/dist/cjs/{child-nodes-event-prevent-slimmer-f3979a03.js → child-nodes-event-prevent-slimmer-b7498e5a.js} +2 -2
- package/dist/cjs/{child-nodes-notify-observer-slimmer-2631c381.js → child-nodes-notify-observer-slimmer-34a606b3.js} +1 -1
- package/dist/cjs/{code-block-c6c70464.js → code-block-15411c14.js} +13 -4
- package/dist/cjs/{component-usage-runtime-metrics-4572c5b7.js → component-usage-runtime-metrics-389d1548.js} +1 -1
- package/dist/cjs/{component-value-history-controller-slimmer.abstract-a523b747.js → component-value-history-controller-slimmer.abstract-5218e4b3.js} +6 -6
- package/dist/cjs/{content-state-efd3b1a7.js → content-state-a69d99b4.js} +5 -5
- package/dist/cjs/{create-public-api-runtime-metrics-slimmer-9cb09fb2.js → create-public-api-runtime-metrics-slimmer-122350c3.js} +1 -1
- package/dist/cjs/{date-required-rule-0dd83683.js → date-required-rule-d65727c5.js} +1 -1
- package/dist/cjs/{design-token-4b3509dd.js → design-token-3bc36220.js} +3 -3
- package/dist/cjs/{dom-node-subject-observer-factory-9110cb94.js → dom-node-subject-observer-factory-ba6a95f3.js} +1 -1
- package/dist/cjs/{element-appender-slimmer-2b4e0a62.js → element-appender-slimmer-f86e6811.js} +6 -6
- package/dist/cjs/{event-emit-slimmer-80e1c8ca.js → event-emit-slimmer-73c42d7e.js} +2 -2
- package/dist/cjs/{feature-flag-controller-9129ef52.js → feature-flag-controller-5fa21654.js} +1 -1
- package/dist/cjs/{form-field-controller-slimmer-a07e3de0.js → form-field-controller-slimmer-44091874.js} +5 -5
- package/dist/cjs/{icon-manager-c12c6ea9.js → icon-manager-e855446d.js} +1 -1
- package/dist/cjs/{image-annotation-action-93bace08.js → image-annotation-action-aad07357.js} +5 -5
- package/dist/cjs/index.cjs.js +26 -25
- package/dist/cjs/{inject-keyboard-manager-ff8735b8.js → inject-keyboard-manager-d06b337e.js} +1 -1
- package/dist/cjs/{internal-icon-manager-c989189a.js → internal-icon-manager-66c48800.js} +1 -1
- package/dist/cjs/{internal-translation-controller-8360a89c.js → internal-translation-controller-f0da24b2.js} +5 -0
- package/dist/cjs/{internal-vega-event-manager-7e0d966d.js → internal-vega-event-manager-063c17cb.js} +5 -2
- package/dist/cjs/{keyboard-manager-cc446230.js → keyboard-manager-1e045791.js} +2 -2
- package/dist/cjs/{keyboard-manager-slimmer-a10b7d6f.js → keyboard-manager-slimmer-861d991f.js} +1 -1
- package/dist/cjs/loader.cjs.js +20 -20
- package/dist/cjs/{month-view-generator-41b6c6b6.js → month-view-generator-8ed9818e.js} +1 -1
- package/dist/cjs/{public-rules-3cd0f182.js → public-rules-c7726702.js} +10 -10
- package/dist/cjs/{range-c9bde0b4.js → range-d6fb50a4.js} +2 -2
- package/dist/cjs/{responsive-format-facade-5f6cd211.js → responsive-format-facade-9647775d.js} +2 -2
- package/dist/cjs/{rich-text-editor-required-rule-d1f0509c.js → rich-text-editor-required-rule-a1a070ce.js} +1 -1
- package/dist/cjs/{split-cell-operation-6a59c9b0.js → split-cell-operation-39b19943.js} +5 -5
- package/dist/cjs/{state-border-formatter-d1c80c1d.js → state-border-formatter-1a483a9b.js} +1 -1
- package/dist/cjs/{string-format-strategy.abstract-b39da0dd.js → string-format-strategy.abstract-2aec209d.js} +1 -1
- package/dist/cjs/{string-input-formatter-slimmer-127cf2b8.js → string-input-formatter-slimmer-e061bd10.js} +4 -4
- package/dist/cjs/{string-mask-strategy-524d0f69.js → string-mask-strategy-4bc07c00.js} +2 -2
- package/dist/cjs/{style-formatter-c201e7d0.js → style-formatter-263d5eb6.js} +2 -2
- package/dist/cjs/{sub-state-notify-slimmer-b33171b0.js → sub-state-notify-slimmer-757e3a76.js} +2 -2
- package/dist/cjs/{sub-state-observer-slimmer-b8f6f27b.js → sub-state-observer-slimmer-aa93ab4f.js} +3 -3
- package/dist/cjs/{time-required-rule-ecb45905.js → time-required-rule-f9a7e897.js} +1 -1
- package/dist/cjs/{token-extension-d7d2ead6.js → token-extension-927062b9.js} +12 -12
- package/dist/cjs/{translation-slimmer-3cd7d3b2.js → translation-slimmer-a4a7f0eb.js} +1 -1
- package/dist/cjs/{type-guard-2e97fc56.js → type-guard-c1195e50.js} +1 -1
- package/dist/cjs/{ui-ae4ee13d.js → ui-3727d685.js} +13 -0
- package/dist/cjs/{valid-credit-card-number-rule-2d7d20ce.js → valid-credit-card-number-rule-22f3e6cf.js} +1 -1
- package/dist/cjs/vega-accordion.cjs.entry.js +35 -17
- package/dist/cjs/vega-app-footer.cjs.entry.js +1 -1
- package/dist/cjs/vega-app-header-button.cjs.entry.js +17 -17
- package/dist/cjs/vega-backdrop.cjs.entry.js +2 -2
- package/dist/cjs/vega-banner.cjs.entry.js +12 -12
- package/dist/cjs/vega-bar-chart.cjs.entry.js +1 -1
- package/dist/cjs/vega-box.cjs.entry.js +10 -10
- package/dist/cjs/vega-brand-logo.cjs.entry.js +4 -4
- package/dist/cjs/vega-breadcrumb.cjs.entry.js +9 -9
- package/dist/cjs/vega-button-circle.cjs.entry.js +15 -15
- package/dist/cjs/vega-button-group_2.cjs.entry.js +12 -12
- package/dist/cjs/vega-button-link.cjs.entry.js +9 -9
- package/dist/cjs/vega-button.cjs.entry.js +13 -13
- package/dist/cjs/vega-calendar_4.cjs.entry.js +665 -344
- package/dist/cjs/vega-card.cjs.entry.js +9 -9
- package/dist/cjs/vega-carousel.cjs.entry.js +12 -12
- package/dist/cjs/vega-checkbox_2.cjs.entry.js +28 -16
- package/dist/cjs/vega-chip.cjs.entry.js +15 -15
- package/dist/cjs/vega-code-block.cjs.entry.js +21 -21
- package/dist/cjs/vega-color-picker.cjs.entry.js +11 -11
- package/dist/cjs/vega-color-swatch-picker.cjs.entry.js +17 -17
- package/dist/cjs/vega-color-swatch.cjs.entry.js +9 -9
- package/dist/cjs/vega-combo-box.cjs.entry.js +17 -17
- package/dist/cjs/vega-counter-badge.cjs.entry.js +1 -1
- package/dist/cjs/vega-date-picker_2.cjs.entry.js +30 -30
- package/dist/cjs/{vega-dialog-controller-03ef4d9a.js → vega-dialog-controller-6df7825e.js} +1 -1
- package/dist/cjs/vega-dialog_2.cjs.entry.js +15 -15
- package/dist/cjs/vega-divider.cjs.entry.js +8 -8
- package/dist/cjs/vega-dropdown_5.cjs.entry.js +23 -23
- package/dist/cjs/vega-env-manager-23b8b23c.js +2 -2
- package/dist/cjs/{vega-event-id-d9994eb3.js → vega-event-id-f95480b7.js} +2 -0
- package/dist/cjs/vega-field-error.cjs.entry.js +1 -1
- package/dist/cjs/vega-field-label.cjs.entry.js +7 -7
- package/dist/cjs/vega-file-uploader.cjs.entry.js +15 -15
- package/dist/cjs/vega-flag-icon.cjs.entry.js +11 -11
- package/dist/cjs/vega-flex.cjs.entry.js +10 -10
- package/dist/cjs/vega-font.cjs.entry.js +9 -9
- package/dist/cjs/vega-form.cjs.entry.js +16 -16
- package/dist/cjs/vega-grid.cjs.entry.js +9 -9
- package/dist/cjs/vega-hint.cjs.entry.js +1 -1
- package/dist/cjs/vega-icon.cjs.entry.js +11 -11
- package/dist/cjs/vega-image-uploader.cjs.entry.js +19 -19
- package/dist/cjs/vega-input-credit-card.cjs.entry.js +20 -20
- package/dist/cjs/vega-input-numeric.cjs.entry.js +17 -17
- package/dist/cjs/vega-input-passcode.cjs.entry.js +16 -16
- package/dist/cjs/vega-input-phone-number.cjs.entry.js +18 -18
- package/dist/cjs/vega-input-range.cjs.entry.js +15 -15
- package/dist/cjs/vega-input-select.cjs.entry.js +20 -20
- package/dist/cjs/vega-input.cjs.entry.js +19 -19
- package/dist/cjs/{vega-internal-event-id-87014e4f.js → vega-internal-event-id-e138d4d6.js} +2 -0
- package/dist/cjs/vega-item-toggle.cjs.entry.js +6 -6
- package/dist/cjs/vega-left-nav_5.cjs.entry.js +21 -21
- package/dist/cjs/vega-line-chart.cjs.entry.js +2 -2
- package/dist/cjs/vega-loader-wrapper_2.cjs.entry.js +7 -7
- package/dist/cjs/vega-page-notification_2.cjs.entry.js +5 -5
- package/dist/cjs/vega-pagination-page-selector-mobile.cjs.entry.js +9 -9
- package/dist/cjs/vega-pagination-page-size-selector-mobile.cjs.entry.js +7 -7
- package/dist/cjs/vega-pagination.cjs.entry.js +14 -14
- package/dist/cjs/vega-pie-chart.cjs.entry.js +1 -1
- package/dist/cjs/vega-popover_2.cjs.entry.js +18 -18
- package/dist/cjs/vega-progress-tracker_2.cjs.entry.js +15 -15
- package/dist/cjs/vega-radio_2.cjs.entry.js +18 -18
- package/dist/cjs/vega-rich-text-content.cjs.entry.js +16 -16
- package/dist/cjs/vega-rich-text-editor_4.cjs.entry.js +30 -37
- package/dist/cjs/vega-rich-text-table-properties_3.cjs.entry.js +21 -21
- package/dist/cjs/vega-section-title.cjs.entry.js +1 -1
- package/dist/cjs/vega-segment-control.cjs.entry.js +6 -6
- package/dist/cjs/vega-selection-chip_2.cjs.entry.js +17 -17
- package/dist/cjs/vega-selection-tile_2.cjs.entry.js +15 -15
- package/dist/cjs/vega-sidenav_3.cjs.entry.js +18 -18
- package/dist/cjs/vega-signature-capture.cjs.entry.js +20 -20
- package/dist/cjs/vega-skeleton.cjs.entry.js +1 -1
- package/dist/cjs/vega-slot-container.cjs.entry.js +1 -1
- package/dist/cjs/vega-stepper.cjs.entry.js +13 -13
- package/dist/cjs/vega-tab-group_2.cjs.entry.js +156 -70
- package/dist/cjs/vega-table_11.cjs.entry.js +20 -20
- package/dist/cjs/vega-text.cjs.entry.js +2 -2
- package/dist/cjs/vega-textarea.cjs.entry.js +13 -13
- package/dist/cjs/vega-time-picker_2.cjs.entry.js +21 -21
- package/dist/cjs/vega-toggle-switch.cjs.entry.js +11 -11
- package/dist/cjs/vega-tooltip_2.cjs.entry.js +12 -12
- package/dist/cjs/vega.cjs.js +20 -20
- package/dist/cjs/{wait-for-component-did-render-16863a21.js → wait-for-component-did-render-a13f7eb9.js} +2 -2
- package/dist/collection/collection-manifest.json +1 -1
- package/dist/collection/components/vega-accordion/slimmers/vega-accordion-renderer.js +14 -1
- package/dist/collection/components/vega-accordion/vega-accordion.js +5 -0
- package/dist/collection/components/vega-calendar/slimmers/common/controllers/vega-calendar-event-preview-actions-controller.js +83 -0
- package/dist/collection/components/vega-calendar/slimmers/common/controllers/vega-calendar-keyboard-controller.js +154 -0
- package/dist/collection/components/vega-calendar/slimmers/common/renderers/vega-calendar-event-item-renderer.js +4 -0
- package/dist/collection/components/vega-calendar/slimmers/month-view/renderers/vega-calendar-month-event-renderer.js +10 -1
- package/dist/collection/components/vega-calendar/slimmers/month-view/renderers/vega-calendar-month-view-renderer.js +22 -3
- package/dist/collection/components/vega-calendar/vega-calendar-event-preview/assets/pen.js +3 -0
- package/dist/collection/components/vega-calendar/vega-calendar-event-preview/slimmers/controllers/vega-calendar-event-preview-state-controller.js +4 -0
- package/dist/collection/components/vega-calendar/vega-calendar-event-preview/slimmers/renderers/vega-calendar-event-preview-detail-renderer.js +37 -4
- package/dist/collection/components/vega-calendar/vega-calendar-event-preview/vega-calendar-event-preview.js +3 -1
- package/dist/collection/components/vega-calendar/vega-calendar.js +115 -1
- package/dist/collection/components/vega-checkbox/vega-checkbox.js +14 -2
- package/dist/collection/components/vega-dropdown/vega-dropdown-item/slimmers/renderers/vega-dropdown-item-renderer.js +1 -1
- package/dist/collection/components/vega-rich-text-editor/constants/constant.js +8 -0
- package/dist/collection/components/vega-rich-text-editor/public-api.js +1 -1
- package/dist/collection/components/vega-rich-text-editor/vega-rich-text-editor.js +3 -10
- package/dist/collection/components/vega-tab-group/slimmers/vega-tab-group/controllers/vega-tab-group-panel-controller.js +14 -1
- package/dist/collection/components/vega-tab-group/slimmers/vega-tab-group/controllers/vega-tab-group-voice-over-focus-controller.js +45 -0
- package/dist/collection/components/vega-tab-group/slimmers/vega-tab-group/renderers/vega-tab-group-close-button-renderer.js +15 -1
- package/dist/collection/components/vega-tab-group/slimmers/vega-tab-group/renderers/vega-tab-group-direction-button-renderer.js +1 -1
- package/dist/collection/components/vega-tab-group/slimmers/vega-tab-group/renderers/vega-tab-group-tab-list-renderer.js +16 -4
- package/dist/collection/components/vega-tab-group/vega-tab-group.js +5 -0
- package/dist/collection/constants/ui.js +1 -0
- package/dist/collection/helpers/event-manager/event-id/component-event-id-map.js +5 -2
- package/dist/collection/helpers/event-manager/event-id/vega-event-id.js +1 -0
- package/dist/collection/helpers/event-manager/event-id/vega-internal-event-id.js +1 -0
- package/dist/collection/helpers/translation/locales/en.js +5 -0
- package/dist/collection/polyfill/d3/d3-time-format-polyfill.js +1 -1
- package/dist/collection/utils/accessibility.js +16 -1
- package/dist/collection/utils/ui.js +12 -0
- package/dist/esm/{accessibility-524cabd2.js → accessibility-6af5cf2e.js} +16 -1
- package/dist/esm/{app-globals-37536ac9.js → app-globals-be458779.js} +11 -11
- package/dist/esm/{aria-dialog-focusable-trap-slimmer-6eb79723.js → aria-dialog-focusable-trap-slimmer-7d9a9f5a.js} +3 -3
- package/dist/esm/{child-nodes-event-prevent-slimmer-75f93d85.js → child-nodes-event-prevent-slimmer-0a406a71.js} +2 -2
- package/dist/esm/{child-nodes-notify-observer-slimmer-a8cb19cf.js → child-nodes-notify-observer-slimmer-8822d0d0.js} +1 -1
- package/dist/esm/{code-block-10be3916.js → code-block-ff52d912.js} +13 -5
- package/dist/esm/{component-usage-runtime-metrics-46020a03.js → component-usage-runtime-metrics-4b1afd04.js} +1 -1
- package/dist/esm/{component-value-history-controller-slimmer.abstract-82d51b7a.js → component-value-history-controller-slimmer.abstract-ad5f29cd.js} +6 -6
- package/dist/esm/{content-state-afeb700d.js → content-state-6fccd284.js} +5 -5
- package/dist/esm/{create-public-api-runtime-metrics-slimmer-aaadaa08.js → create-public-api-runtime-metrics-slimmer-da6615bf.js} +1 -1
- package/dist/esm/{date-required-rule-a84c21d4.js → date-required-rule-70324452.js} +1 -1
- package/dist/esm/{design-token-57de4f4f.js → design-token-0e6fb2c4.js} +3 -3
- package/dist/esm/{dom-node-subject-observer-factory-aca0116e.js → dom-node-subject-observer-factory-3897e95b.js} +1 -1
- package/dist/esm/{element-appender-slimmer-05f487d7.js → element-appender-slimmer-afe5a638.js} +6 -6
- package/dist/esm/{event-emit-slimmer-1c57093d.js → event-emit-slimmer-697ad0b7.js} +2 -2
- package/dist/esm/{feature-flag-controller-30f7b625.js → feature-flag-controller-5ebc0cec.js} +1 -1
- package/dist/esm/{form-field-controller-slimmer-ae8478b5.js → form-field-controller-slimmer-9e70a18d.js} +5 -5
- package/dist/esm/{icon-manager-539d7cf7.js → icon-manager-691c8682.js} +1 -1
- package/dist/esm/{image-annotation-action-bad7c565.js → image-annotation-action-245eaa54.js} +5 -5
- package/dist/esm/index.js +25 -25
- package/dist/esm/{inject-keyboard-manager-1ceb9ee0.js → inject-keyboard-manager-05d5db90.js} +1 -1
- package/dist/esm/{internal-icon-manager-bd80b3bb.js → internal-icon-manager-276f968f.js} +1 -1
- package/dist/esm/{internal-translation-controller-d7dee4a0.js → internal-translation-controller-d8217d93.js} +5 -0
- package/dist/esm/{internal-vega-event-manager-7cdf3c28.js → internal-vega-event-manager-1ac5ee9a.js} +5 -2
- package/dist/esm/{keyboard-manager-50a1d90e.js → keyboard-manager-26e2fc32.js} +2 -2
- package/dist/esm/{keyboard-manager-slimmer-3891ee20.js → keyboard-manager-slimmer-012a9a9b.js} +1 -1
- package/dist/esm/loader.js +20 -20
- package/dist/esm/{month-view-generator-70c597a6.js → month-view-generator-918f1f88.js} +1 -1
- package/dist/esm/polyfills/core-js.js +0 -0
- package/dist/esm/polyfills/dom.js +0 -0
- package/dist/esm/polyfills/es5-html-element.js +0 -0
- package/dist/esm/polyfills/index.js +0 -0
- package/dist/esm/polyfills/system.js +0 -0
- package/dist/esm/{public-rules-f54e6f39.js → public-rules-22320bdf.js} +10 -10
- package/dist/esm/{range-f32f9185.js → range-76f8e7dd.js} +2 -2
- package/dist/esm/{responsive-format-facade-456a9f16.js → responsive-format-facade-2a1d6398.js} +2 -2
- package/dist/esm/{rich-text-editor-required-rule-627fd7e4.js → rich-text-editor-required-rule-6eb90840.js} +1 -1
- package/dist/esm/{split-cell-operation-90c30861.js → split-cell-operation-7652e813.js} +5 -5
- package/dist/esm/{state-border-formatter-afac8d33.js → state-border-formatter-a243f3fc.js} +1 -1
- package/dist/esm/{string-format-strategy.abstract-f9907969.js → string-format-strategy.abstract-f6625ed7.js} +1 -1
- package/dist/esm/{string-input-formatter-slimmer-4059080b.js → string-input-formatter-slimmer-e801bd7e.js} +4 -4
- package/dist/esm/{string-mask-strategy-5f655300.js → string-mask-strategy-53cb9b33.js} +2 -2
- package/dist/esm/{style-formatter-ee52d8d0.js → style-formatter-a622a045.js} +2 -2
- package/dist/esm/{sub-state-notify-slimmer-63ecb465.js → sub-state-notify-slimmer-80ac7dee.js} +2 -2
- package/dist/esm/{sub-state-observer-slimmer-2adbbe00.js → sub-state-observer-slimmer-81538a8c.js} +3 -3
- package/dist/esm/{time-required-rule-db873c19.js → time-required-rule-2fd8df50.js} +1 -1
- package/dist/esm/{token-extension-728c0678.js → token-extension-5838c71b.js} +12 -12
- package/dist/esm/{translation-slimmer-5e2bff5f.js → translation-slimmer-32353a1c.js} +1 -1
- package/dist/esm/{type-guard-adc244fd.js → type-guard-ed1004cc.js} +1 -1
- package/dist/esm/{ui-b7600a48.js → ui-64815a12.js} +13 -1
- package/dist/esm/{valid-credit-card-number-rule-a826dd49.js → valid-credit-card-number-rule-7c9d6808.js} +1 -1
- package/dist/esm/vega-accordion.entry.js +35 -17
- package/dist/esm/vega-app-footer.entry.js +1 -1
- package/dist/esm/vega-app-header-button.entry.js +17 -17
- package/dist/esm/vega-backdrop.entry.js +2 -2
- package/dist/esm/vega-banner.entry.js +12 -12
- package/dist/esm/vega-bar-chart.entry.js +1 -1
- package/dist/esm/vega-box.entry.js +10 -10
- package/dist/esm/vega-brand-logo.entry.js +4 -4
- package/dist/esm/vega-breadcrumb.entry.js +9 -9
- package/dist/esm/vega-button-circle.entry.js +15 -15
- package/dist/esm/vega-button-group_2.entry.js +12 -12
- package/dist/esm/vega-button-link.entry.js +9 -9
- package/dist/esm/vega-button.entry.js +13 -13
- package/dist/esm/vega-calendar_4.entry.js +666 -345
- package/dist/esm/vega-card.entry.js +9 -9
- package/dist/esm/vega-carousel.entry.js +12 -12
- package/dist/esm/vega-checkbox_2.entry.js +28 -16
- package/dist/esm/vega-chip.entry.js +15 -15
- package/dist/esm/vega-code-block.entry.js +21 -21
- package/dist/esm/vega-color-picker.entry.js +11 -11
- package/dist/esm/vega-color-swatch-picker.entry.js +17 -17
- package/dist/esm/vega-color-swatch.entry.js +9 -9
- package/dist/esm/vega-combo-box.entry.js +17 -17
- package/dist/esm/vega-counter-badge.entry.js +1 -1
- package/dist/esm/vega-date-picker_2.entry.js +30 -30
- package/dist/esm/{vega-dialog-controller-bbb2fc52.js → vega-dialog-controller-389e7f7c.js} +1 -1
- package/dist/esm/vega-dialog_2.entry.js +15 -15
- package/dist/esm/vega-divider.entry.js +8 -8
- package/dist/esm/vega-dropdown_5.entry.js +23 -23
- package/dist/esm/vega-env-manager-8f8dc473.js +2 -2
- package/dist/esm/{vega-event-id-a6ccca66.js → vega-event-id-578c6c6d.js} +2 -1
- package/dist/esm/vega-field-error.entry.js +1 -1
- package/dist/esm/vega-field-label.entry.js +7 -7
- package/dist/esm/vega-file-uploader.entry.js +15 -15
- package/dist/esm/vega-flag-icon.entry.js +11 -11
- package/dist/esm/vega-flex.entry.js +10 -10
- package/dist/esm/vega-font.entry.js +9 -9
- package/dist/esm/vega-form.entry.js +16 -16
- package/dist/esm/vega-grid.entry.js +9 -9
- package/dist/esm/vega-hint.entry.js +1 -1
- package/dist/esm/vega-icon.entry.js +11 -11
- package/dist/esm/vega-image-uploader.entry.js +19 -19
- package/dist/esm/vega-input-credit-card.entry.js +20 -20
- package/dist/esm/vega-input-numeric.entry.js +17 -17
- package/dist/esm/vega-input-passcode.entry.js +16 -16
- package/dist/esm/vega-input-phone-number.entry.js +18 -18
- package/dist/esm/vega-input-range.entry.js +15 -15
- package/dist/esm/vega-input-select.entry.js +20 -20
- package/dist/esm/vega-input.entry.js +19 -19
- package/dist/esm/{vega-internal-event-id-db974a0d.js → vega-internal-event-id-913e8be6.js} +2 -1
- package/dist/esm/vega-item-toggle.entry.js +6 -6
- package/dist/esm/vega-left-nav_5.entry.js +21 -21
- package/dist/esm/vega-line-chart.entry.js +2 -2
- package/dist/esm/vega-loader-wrapper_2.entry.js +7 -7
- package/dist/esm/vega-page-notification_2.entry.js +5 -5
- package/dist/esm/vega-pagination-page-selector-mobile.entry.js +9 -9
- package/dist/esm/vega-pagination-page-size-selector-mobile.entry.js +7 -7
- package/dist/esm/vega-pagination.entry.js +14 -14
- package/dist/esm/vega-pie-chart.entry.js +1 -1
- package/dist/esm/vega-popover_2.entry.js +18 -18
- package/dist/esm/vega-progress-tracker_2.entry.js +15 -15
- package/dist/esm/vega-radio_2.entry.js +18 -18
- package/dist/esm/vega-rich-text-content.entry.js +16 -16
- package/dist/esm/vega-rich-text-editor_4.entry.js +30 -37
- package/dist/esm/vega-rich-text-table-properties_3.entry.js +21 -21
- package/dist/esm/vega-section-title.entry.js +1 -1
- package/dist/esm/vega-segment-control.entry.js +6 -6
- package/dist/esm/vega-selection-chip_2.entry.js +17 -17
- package/dist/esm/vega-selection-tile_2.entry.js +15 -15
- package/dist/esm/vega-sidenav_3.entry.js +18 -18
- package/dist/esm/vega-signature-capture.entry.js +20 -20
- package/dist/esm/vega-skeleton.entry.js +1 -1
- package/dist/esm/vega-slot-container.entry.js +1 -1
- package/dist/esm/vega-stepper.entry.js +13 -13
- package/dist/esm/vega-tab-group_2.entry.js +156 -70
- package/dist/esm/vega-table_11.entry.js +20 -20
- package/dist/esm/vega-text.entry.js +2 -2
- package/dist/esm/vega-textarea.entry.js +13 -13
- package/dist/esm/vega-time-picker_2.entry.js +21 -21
- package/dist/esm/vega-toggle-switch.entry.js +11 -11
- package/dist/esm/vega-tooltip_2.entry.js +12 -12
- package/dist/esm/vega.js +20 -20
- package/dist/esm/{wait-for-component-did-render-9a83d343.js → wait-for-component-did-render-4069cbea.js} +2 -2
- package/dist/sri/vega-sri-manifest.json +426 -426
- package/dist/types/components/vega-accordion/slimmers/vega-accordion-renderer.d.ts +2 -0
- package/dist/types/components/vega-accordion/vega-accordion.d.ts +2 -0
- package/dist/types/components/vega-calendar/slimmers/common/controllers/vega-calendar-event-preview-actions-controller.d.ts +36 -0
- package/dist/types/components/vega-calendar/slimmers/common/controllers/vega-calendar-keyboard-controller.d.ts +35 -0
- package/dist/types/components/vega-calendar/slimmers/common/renderers/vega-calendar-event-item-renderer.d.ts +1 -0
- package/dist/types/components/vega-calendar/slimmers/month-view/renderers/vega-calendar-month-event-renderer.d.ts +7 -0
- package/dist/types/components/vega-calendar/slimmers/month-view/renderers/vega-calendar-month-view-renderer.d.ts +16 -0
- package/dist/types/components/vega-calendar/types.d.ts +32 -0
- package/dist/types/components/vega-calendar/vega-calendar-event-preview/assets/pen.d.ts +3 -0
- package/dist/types/components/vega-calendar/vega-calendar-event-preview/slimmers/controllers/vega-calendar-event-preview-state-controller.d.ts +1 -0
- package/dist/types/components/vega-calendar/vega-calendar-event-preview/slimmers/renderers/vega-calendar-event-preview-detail-renderer.d.ts +6 -0
- package/dist/types/components/vega-calendar/vega-calendar-event-preview/types.d.ts +6 -0
- package/dist/types/components/vega-calendar/vega-calendar-event-preview/vega-calendar-event-preview.d.ts +2 -0
- package/dist/types/components/vega-calendar/vega-calendar.d.ts +34 -1
- package/dist/types/components/vega-checkbox/vega-checkbox.d.ts +2 -0
- package/dist/types/components/vega-rich-text-editor/constants/constant.d.ts +2 -1
- package/dist/types/components/vega-rich-text-editor/public-api.d.ts +1 -1
- package/dist/types/components/vega-tab-group/slimmers/vega-tab-group/controllers/vega-tab-group-voice-over-focus-controller.d.ts +23 -0
- package/dist/types/components/vega-tab-group/slimmers/vega-tab-group/renderers/vega-tab-group-close-button-renderer.d.ts +1 -0
- package/dist/types/components/vega-tab-group/slimmers/vega-tab-group/renderers/vega-tab-group-tab-list-renderer.d.ts +2 -0
- package/dist/types/components/vega-tab-group/vega-tab-group.d.ts +2 -0
- package/dist/types/components.d.ts +32 -1
- package/dist/types/constants/ui.d.ts +1 -1
- package/dist/types/helpers/event-manager/event-id/vega-event-id.d.ts +1 -0
- package/dist/types/helpers/event-manager/event-id/vega-internal-event-id.d.ts +1 -0
- package/dist/types/helpers/translation/interface.d.ts +5 -0
- package/dist/types/types/components.type.d.ts +2 -0
- package/dist/types/utils/accessibility.d.ts +1 -0
- package/dist/types/utils/ui.d.ts +9 -0
- package/dist/vega/index.esm.js +1 -1
- package/dist/vega/{p-d8180e42.entry.js → p-018756ad.entry.js} +1 -1
- package/dist/vega/{p-7702a906.entry.js → p-01a54c29.entry.js} +1 -1
- package/dist/vega/p-042933f1.js +1 -0
- package/dist/vega/{p-6b5cb920.js → p-04a65b3f.js} +1 -1
- package/dist/vega/{p-423762ae.entry.js → p-07225567.entry.js} +1 -1
- package/dist/vega/{p-6817b9bd.js → p-09076646.js} +1 -1
- package/dist/vega/{p-3b791b5d.js → p-0a261b66.js} +1 -1
- package/dist/vega/p-0a322971.entry.js +1 -0
- package/dist/vega/{p-59c6dcf7.entry.js → p-0b41b49a.entry.js} +1 -1
- package/dist/vega/{p-51b2b3de.js → p-0d97dcb9.js} +1 -1
- package/dist/vega/{p-af5cb9bc.js → p-10fa27d2.js} +1 -1
- package/dist/vega/{p-f28a6074.js → p-11e2dcf5.js} +1 -1
- package/dist/vega/{p-2c1a85dd.entry.js → p-1250b1ab.entry.js} +1 -1
- package/dist/vega/{p-33234385.js → p-154cc614.js} +1 -1
- package/dist/vega/p-15b4f1ce.entry.js +1 -0
- package/dist/vega/{p-e6adf829.js → p-1704ff25.js} +1 -1
- package/dist/vega/p-186df871.entry.js +1 -0
- package/dist/vega/{p-c95dbf11.js → p-189d36ec.js} +1 -1
- package/dist/vega/{p-c85e743d.js → p-19adf714.js} +1 -1
- package/dist/vega/{p-c2388937.entry.js → p-19df2831.entry.js} +1 -1
- package/dist/vega/{p-a46e977b.entry.js → p-1be90bab.entry.js} +1 -1
- package/dist/vega/{p-69c11b7b.entry.js → p-1da42a63.entry.js} +1 -1
- package/dist/vega/{p-096d186d.entry.js → p-255a7387.entry.js} +1 -1
- package/dist/vega/{p-1a869f0e.js → p-281fa1e0.js} +1 -1
- package/dist/vega/{p-9af0e2e7.js → p-2927b7a1.js} +1 -1
- package/dist/vega/{p-2edc066c.entry.js → p-294cff20.entry.js} +1 -1
- package/dist/vega/{p-a87cb7ac.js → p-296c5e52.js} +1 -1
- package/dist/vega/{p-dba16739.js → p-2b2fefc6.js} +1 -1
- package/dist/vega/{p-c347e08a.js → p-2d694684.js} +1 -1
- package/dist/vega/{p-9eb00537.entry.js → p-2e0bdc53.entry.js} +1 -1
- package/dist/vega/{p-b7721666.js → p-31ebace1.js} +1 -1
- package/dist/vega/{p-818da356.js → p-32a0f887.js} +1 -1
- package/dist/vega/{p-c31a32f4.js → p-341d5e4e.js} +1 -1
- package/dist/vega/{p-e7a4b760.entry.js → p-3967fa98.entry.js} +1 -1
- package/dist/vega/{p-7f74cd41.entry.js → p-3a3720c7.entry.js} +1 -1
- package/dist/vega/p-3a620268.js +1 -0
- package/dist/vega/{p-6c43d54a.js → p-3a93730e.js} +1 -1
- package/dist/vega/{p-98a6cd8e.entry.js → p-3bf3c8bb.entry.js} +1 -1
- package/dist/vega/{p-6fadee27.entry.js → p-49341532.entry.js} +1 -1
- package/dist/vega/{p-e95cb28f.entry.js → p-4a6f241d.entry.js} +1 -1
- package/dist/vega/{p-3e64fa38.entry.js → p-4a954d9d.entry.js} +1 -1
- package/dist/vega/{p-9fc8bd1f.entry.js → p-4a9c8ec0.entry.js} +1 -1
- package/dist/vega/{p-8d48940d.js → p-4c91b13d.js} +1 -1
- package/dist/vega/p-4dd02704.js +1 -0
- package/dist/vega/p-50fb936f.entry.js +1 -0
- package/dist/vega/{p-da8bb883.entry.js → p-52645382.entry.js} +1 -1
- package/dist/vega/{p-73c6669e.entry.js → p-5b43a303.entry.js} +1 -1
- package/dist/vega/{p-cf2838c7.entry.js → p-5df7ab03.entry.js} +1 -1
- package/dist/vega/p-5f377954.js +1 -1
- package/dist/vega/p-612808ce.entry.js +1 -0
- package/dist/vega/{p-ecbb63a5.entry.js → p-636d890e.entry.js} +1 -1
- package/dist/vega/p-6399b5ed.js +1 -0
- package/dist/vega/{p-4afafeb3.entry.js → p-648be36d.entry.js} +1 -1
- package/dist/vega/{p-a9f34735.entry.js → p-686e0b6b.entry.js} +1 -1
- package/dist/vega/{p-d4e519a0.js → p-6d4faebc.js} +1 -1
- package/dist/vega/{p-2fb26f4f.entry.js → p-70ae9157.entry.js} +1 -1
- package/dist/vega/{p-e1fbfd20.js → p-724df1f5.js} +1 -1
- package/dist/vega/{p-e1709e59.js → p-72e2a587.js} +1 -1
- package/dist/vega/{p-1deedff2.entry.js → p-740f3325.entry.js} +1 -1
- package/dist/vega/{p-a050c24d.entry.js → p-74a1a82a.entry.js} +1 -1
- package/dist/vega/{p-264b3309.entry.js → p-76075a1c.entry.js} +1 -1
- package/dist/vega/{p-76063dcb.js → p-77fb5d5c.js} +1 -1
- package/dist/vega/{p-e4c4ea35.js → p-78ba7ca9.js} +1 -1
- package/dist/vega/{p-a49c25c2.entry.js → p-79bb216e.entry.js} +1 -1
- package/dist/vega/{p-d37636a5.entry.js → p-7e7e2f85.entry.js} +1 -1
- package/dist/vega/{p-4c90d013.entry.js → p-7ffe8081.entry.js} +1 -1
- package/dist/vega/{p-4cefd7fe.js → p-8077b117.js} +1 -1
- package/dist/vega/{p-5bf3ab33.js → p-858ec529.js} +1 -1
- package/dist/vega/{p-0b5b0fd2.entry.js → p-879d3cc9.entry.js} +1 -1
- package/dist/vega/{p-ae1aa4df.js → p-891815d6.js} +1 -1
- package/dist/vega/p-8ce9e214.js +1 -0
- package/dist/vega/p-8d36afcc.entry.js +1 -0
- package/dist/vega/{p-a9e10a64.js → p-919de162.js} +1 -1
- package/dist/vega/{p-effb285f.entry.js → p-931dac8c.entry.js} +1 -1
- package/dist/vega/{p-c601b331.entry.js → p-979a5e91.entry.js} +1 -1
- package/dist/vega/{p-d402eb7b.entry.js → p-98dad153.entry.js} +1 -1
- package/dist/vega/p-9a6bd32c.js +1 -0
- package/dist/vega/p-9e0f8b46.entry.js +1 -0
- package/dist/vega/{p-3d0ba2c6.entry.js → p-a03341d8.entry.js} +1 -1
- package/dist/vega/{p-e1d2c60d.js → p-a0dd08b1.js} +1 -1
- package/dist/vega/p-a2b8d49d.js +1 -0
- package/dist/vega/p-a6565e02.js +1 -0
- package/dist/vega/{p-afd1b519.entry.js → p-a67d52ce.entry.js} +1 -1
- package/dist/vega/{p-411ea209.entry.js → p-aa4e9a4b.entry.js} +1 -1
- package/dist/vega/{p-fa91805b.entry.js → p-aa8f4713.entry.js} +1 -1
- package/dist/vega/{p-e27626f6.js → p-ab04eff6.js} +1 -1
- package/dist/vega/p-ab4c307b.js +1 -0
- package/dist/vega/{p-e47b2c4c.entry.js → p-ac26924d.entry.js} +1 -1
- package/dist/vega/{p-7f46cc1e.entry.js → p-adc64ff6.entry.js} +1 -1
- package/dist/vega/{p-031c0cf7.js → p-b02b985d.js} +1 -1
- package/dist/vega/{p-0bb0b521.entry.js → p-b69755c7.entry.js} +1 -1
- package/dist/vega/{p-c801c85d.js → p-b6be1f33.js} +1 -1
- package/dist/vega/{p-25572ea7.entry.js → p-bd47d8a7.entry.js} +1 -1
- package/dist/vega/{p-0b4880bd.entry.js → p-be783294.entry.js} +1 -1
- package/dist/vega/{p-79c12a64.entry.js → p-bee5dfb0.entry.js} +1 -1
- package/dist/vega/{p-45aaaef6.entry.js → p-c19132c9.entry.js} +1 -1
- package/dist/vega/p-c41b42eb.entry.js +1 -0
- package/dist/vega/{p-3d92d2af.entry.js → p-c45acdc3.entry.js} +1 -1
- package/dist/vega/{p-571a6d15.entry.js → p-ce034372.entry.js} +1 -1
- package/dist/vega/{p-bc74d7e7.entry.js → p-ce2d9efe.entry.js} +1 -1
- package/dist/vega/{p-ce61d23f.entry.js → p-d05915af.entry.js} +1 -1
- package/dist/vega/{p-c8fe46fd.entry.js → p-d1a6e126.entry.js} +1 -1
- package/dist/vega/{p-9297f4a9.entry.js → p-d286da1d.entry.js} +1 -1
- package/dist/vega/{p-3c456e91.entry.js → p-d4262f06.entry.js} +1 -1
- package/dist/vega/{p-23b38467.entry.js → p-d5aad9f0.entry.js} +1 -1
- package/dist/vega/{p-35d77c9c.entry.js → p-d97974be.entry.js} +1 -1
- package/dist/vega/{p-9e2b7718.entry.js → p-d9d4bdbf.entry.js} +1 -1
- package/dist/vega/{p-18e8d9b7.js → p-dcf162e9.js} +1 -1
- package/dist/vega/p-e46a23fc.entry.js +1 -0
- package/dist/vega/p-e5226de6.entry.js +1 -0
- package/dist/vega/{p-f604f2c9.entry.js → p-e7c930d9.entry.js} +1 -1
- package/dist/vega/p-e85497ec.entry.js +1 -0
- package/dist/vega/{p-34964a53.js → p-e8de9535.js} +1 -1
- package/dist/vega/{p-f5f5a0d9.js → p-e8ea3b16.js} +1 -1
- package/dist/vega/{p-268e84e0.entry.js → p-ea0e922f.entry.js} +1 -1
- package/dist/vega/p-ea48decc.js +1 -0
- package/dist/vega/{p-82039afd.entry.js → p-eb78a2f2.entry.js} +1 -1
- package/dist/vega/p-ec2333f7.entry.js +1 -0
- package/dist/vega/{p-6e70d3cc.js → p-ec2a1d4c.js} +1 -1
- package/dist/vega/{p-9f064488.entry.js → p-ec663f00.entry.js} +1 -1
- package/dist/vega/p-ed2b0e01.entry.js +1 -0
- package/dist/vega/p-ef13b346.js +1 -0
- package/dist/vega/{p-78099a83.entry.js → p-f5ae99b4.entry.js} +1 -1
- package/dist/vega/{p-d10ae46a.entry.js → p-fdb97cb7.entry.js} +1 -1
- package/dist/vega/{p-295326ca.entry.js → p-fe220f3a.entry.js} +1 -1
- package/dist/vega/{p-115d6053.entry.js → p-ff5208f5.entry.js} +1 -1
- package/dist/vega/vega.esm.js +1 -1
- package/package.json +6 -6
- package/dist/vega/p-13e7f906.entry.js +0 -1
- package/dist/vega/p-358b4a06.entry.js +0 -1
- package/dist/vega/p-4415ad28.js +0 -1
- package/dist/vega/p-4530f0e1.entry.js +0 -1
- package/dist/vega/p-5087fa1e.entry.js +0 -1
- package/dist/vega/p-51fcb07f.entry.js +0 -1
- package/dist/vega/p-5657f768.js +0 -1
- package/dist/vega/p-57f220b5.js +0 -1
- package/dist/vega/p-593e0f80.js +0 -1
- package/dist/vega/p-5e50dbb9.js +0 -1
- package/dist/vega/p-606d7113.entry.js +0 -1
- package/dist/vega/p-6ac8e655.js +0 -1
- package/dist/vega/p-7730bace.js +0 -1
- package/dist/vega/p-84eb3b9c.js +0 -1
- package/dist/vega/p-93afdfc3.js +0 -1
- package/dist/vega/p-9f36abf9.entry.js +0 -1
- package/dist/vega/p-9f728e0b.js +0 -1
- package/dist/vega/p-a9528dbd.entry.js +0 -1
- package/dist/vega/p-aaf44879.entry.js +0 -1
- package/dist/vega/p-af00e6e2.entry.js +0 -1
- package/dist/vega/p-c51ebb14.entry.js +0 -1
- package/dist/vega/p-dffbbc3d.entry.js +0 -1
- package/dist/vega/p-ed26f4c8.entry.js +0 -1
- package/dist/vega/p-f1c672e4.js +0 -1
- /package/dist/cjs/{index-f054eb5d.js → index-3ca118c4.js} +0 -0
- /package/dist/esm/{index-bfc6dfa2.js → index-9c9865c0.js} +0 -0
- /package/dist/vega/{p-5a25014f.js → p-982747ef.js} +0 -0
|
@@ -0,0 +1 @@
|
|
|
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-6b2342e0.js";import{g as s,s as l}from"./p-519a7d55.js";import{c as d,V as c,M as h,L as v,I as p}from"./p-6e1ab235.js";import{V as f,I as w}from"./p-8ce9e214.js";import{D as m,d as u}from"./p-11e2dcf5.js";import{a as g,i as b,V as x,b as y,j as k,k as C,l as R,m as j,n as E}from"./p-2927b7a1.js";import{V as D}from"./p-724df1f5.js";import{a3 as z,ae as O,ac as P,af as I,ag as M,ah as S,a5 as T,ai as A,aj as V,ak as $,al as L,am as B,an as F}from"./p-78ba7ca9.js";import{c as W}from"./p-3a620268.js";import{l as N,f as H}from"./p-ec2a1d4c.js";import{c as _}from"./p-04a65b3f.js";import{V as U}from"./p-0a261b66.js";import{C as K,a as Y,M as Z}from"./p-2b2fefc6.js";import{C as X}from"./p-ab04eff6.js";import{G as q,H as G,I as J,J as Q,K as ee,C as te}from"./p-3a93730e.js";import{O as ie}from"./p-331a62d5.js";import{C as ne}from"./p-2d0d575f.js";import{f as re}from"./p-d27ae9ff.js";import{g as oe}from"./p-8b5d3a52.js";import{P as ae}from"./p-81dd00d0.js";import{d as se}from"./p-1bc5b3bc.js";import{c as le}from"./p-341d5e4e.js";import{T as de}from"./p-a6565e02.js";import{A as ce}from"./p-4d65756f.js";import{v as he}from"./p-4866e390.js";import{K as ve}from"./p-296c5e52.js";import{t as pe}from"./p-b75ee3ba.js";import{s as fe}from"./p-6bd5c49b.js";import{S as we}from"./p-10fa27d2.js";import{b as me}from"./p-0c667d6a.js";import"./p-1704ff25.js";import"./p-9a6bd32c.js";import"./p-6a334573.js";import"./p-ed45b3b6.js";import"./p-d4ea8e22.js";import"./p-d884c644.js";import"./p-4dd02704.js";import"./p-a528714c.js";import"./p-5f377954.js";import"./p-dcf162e9.js";import"./p-982747ef.js";import"./p-262ec334.js";import"./p-49a2e141.js";import"./p-1fb56e14.js";import"./p-8077b117.js";class ue extends K{generate(e){return new Y([this.generateWeekHead()[e.current.toDate().getDay()]],[[e.current]])}}class ge extends K{generate(e){const t=this.generateDates(e),i=e.showWeekends;let n=this.generateWeekHead(),r=[t.map((e=>z.from(e)))];return!1===i&&(n=n.slice(1,6),r=r.map((e=>e.slice(1,6)))),new Y(n,r)}}var be=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 xe extends c{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}}))}}be([d()],xe.prototype,"host",void 0),be([d()],xe.prototype,"switchPanelRenderer",void 0),be([d()],xe.prototype,"viewRenderer",void 0);var ye=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 ke extends c{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=>{m.addUniqueObserverToNode(e,g,this.todayButtonClick)},label:this.translationSlimmer.t("Today")}),e("vega-button-circle",{variant:"secondary",size:"small",icon:D.getIconKey("chevron-left"),label:"previous",showTooltip:!1,ref:e=>{m.addUniqueObserverToNode(e,g,this.prevButtonClick)}}),e("vega-button-circle",{variant:"secondary",size:"small",icon:D.getIconKey("chevron-right"),label:"next",showTooltip:!1,ref:e=>{m.addUniqueObserverToNode(e,g,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:ke.views.map((e=>Object.assign(Object.assign({},e),{text:this.translationSlimmer.t(e.text)}))),size:"small",variant:"text-only",selected:this.viewMode,ref:e=>{m.addUniqueObserverToNode(e,b,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=>{m.addUniqueObserverToNode(e,x,this.moreActionMenuClick)}}),e("vega-button-circle",{"data-aria-label":this.translationSlimmer.t("More actions"),size:"small",icon:D.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}}D.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>'}}),ke.views=[{text:"Day",key:"day"},{text:"Week",key:"week"},{text:"Month",key:"month"}],ye([d()],ke.prototype,"viewMode",void 0),ye([d()],ke.prototype,"calendarView",void 0),ye([d()],ke.prototype,"currentPeriod",void 0),ye([d()],ke.prototype,"moreActionDropdownProps",void 0),ye([d()],ke.prototype,"moreActionClickEmitter",void 0),ye([d()],ke.prototype,"currentPeriodController",void 0),ye([d()],ke.prototype,"calendarViewController",void 0),ye([d()],ke.prototype,"translationSlimmer",void 0),ye([d()],ke.prototype,"postOperationDate",void 0),ye([d()],ke.prototype,"showSwitchView",void 0);var Ce=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 c{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())}}Ce([d()],Re.prototype,"viewMode",void 0),Ce([d()],Re.prototype,"showWeekends",void 0),Ce([d()],Re.prototype,"monthViewRenderer",void 0),Ce([d()],Re.prototype,"viewWithTimeRenderer",void 0);var je=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 c{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=W()):n.onDblClick=e=>{this.handleDateBlockClick(e,t,i)}),n}}je([d()],Ee.prototype,"enableDateClick",void 0),je([d()],Ee.prototype,"dateClickEmitter",void 0),je([d()],Ee.prototype,"dateDblClickEmitter",void 0);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 ze extends Ee{getMonthContainerRef(){return this.monthContainerRef}onDayItemKeyDown(e,t){this.goToCurrentDayView(t,e)}render(){return e("div",{class:"calendar-view-month-container",ref:e=>this.monthContainerRef=e},e("div",{class:"calendar-view-row calendar-view-title border-divider-bottom"},this.calendarView.weekdays.map((t=>e("div",{key:t,role:"group",tabIndex:-1,"aria-label":this.translationSlimmer.t(O[t.toLowerCase()])},e("span",{"aria-hidden":"true"},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),d=`${i.getMonthName()} ${i.date} ${i.year}`;return e("div",Object.assign({class:{"row-cell border-divider-right":!0,"current-month-day":i.compare(t).inMonth,active:i.isToday(this.timezone),disabled:s},key:`${i.month}-${i.date}`},l,{tabindex:this.enableDateClick?0:void 0,role:this.enableDateClick?"button":void 0,"aria-disabled":s?"true":void 0,"aria-label":this.enableDateClick?d:void 0}),this.renderDateBlock(i),this.monthEventRenderer.render(i,r[n],o[n],n))})))}))}renderDateBlock(t){const i=1===t.date,n=this.showSwitchView&&this.enableDateClick,r=`${t.getMonthName()} ${t.date} ${t.year}`;return e("div",{class:"date"},i&&e("div",{role:"group","aria-label":t.getMonthName(),class:"month-block"},t.getMonthName(!0)),e("div",{"aria-label":this.enableDateClick?void 0:r,role:n?"button":"group","aria-disabled":n?"false":void 0,tabIndex:0,"data-date":t.toString(),class:"grid-col",onDblClick:e=>{this.handleDateLabelClick(e,t)},onClick:e=>{this.handleDateLabelClick(e,t)},onKeyDown:W()},t.date))}goToCurrentDayView(e,t){this.currentPeriodController.updateCalendarPeriod("day",e),(t instanceof KeyboardEvent||N(t))&&this.dayViewFocusSlimmer.scheduleFocus()}handleDateLabelClick(e,t){e.stopPropagation(),this.showSwitchView&&(this.shouldHandleClickEvent(e)||this.shouldHandleDblClickEvent(e))&&this.goToCurrentDayView(t,e)}isMonthBlockBlankArea(e){return!e.classList.contains("more-button")&&"VEGA-CALENDAR-EVENT"!==e.tagName}}De([d()],ze.prototype,"viewMode",void 0),De([d()],ze.prototype,"calendarView",void 0),De([d()],ze.prototype,"currentPeriod",void 0),De([d()],ze.prototype,"currentPeriodController",void 0),De([d()],ze.prototype,"monthEventRenderer",void 0),De([d()],ze.prototype,"translationSlimmer",void 0),De([d()],ze.prototype,"isDateDisabled",void 0),De([d()],ze.prototype,"showSwitchView",void 0),De([d()],ze.prototype,"timezone",void 0),De([d()],ze.prototype,"host",void 0),De([d()],ze.prototype,"dayViewFocusSlimmer",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 Pe extends Ee{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(this.timezone)},role:"group",tabIndex:-1,"aria-label":`${this.translationSlimmer.t(O[i[n].toLowerCase()])}, ${t.getMonthName()} ${t.date} ${t.year}`},e("div",{"aria-hidden":"true"},this.translationSlimmer.t(i[n])),e("div",{class:"week-day","aria-hidden":"true"},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([d()],Pe.prototype,"viewMode",void 0),Oe([d()],Pe.prototype,"timeLineRenderer",void 0),Oe([d()],Pe.prototype,"timeMarkerRenderer",void 0),Oe([d()],Pe.prototype,"dayViewTimedEventRenderer",void 0),Oe([d()],Pe.prototype,"dayViewFullDayEventRenderer",void 0),Oe([d()],Pe.prototype,"calendarView",void 0),Oe([d()],Pe.prototype,"translationSlimmer",void 0),Oe([d()],Pe.prototype,"isDateDisabled",void 0),Oe([d()],Pe.prototype,"enableDateClick",void 0),Oe([d()],Pe.prototype,"timezone",void 0);class Ie extends c{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(`${P(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)}([d()],Ie.prototype,"timeFormat",void 0);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 Se extends c{constructor(){super(...arguments),this.monthViewGenerator=new Z,this.weekViewGenerator=new ge,this.dayViewGenerator=new ue}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}}Me([d({writable:!0})],Se.prototype,"calendarView",void 0),Me([d()],Se.prototype,"currentPeriod",void 0),Me([d()],Se.prototype,"showWeekends",void 0),Me([d()],Se.prototype,"currentPeriodController",void 0),Me([h("componentWillLoad")],Se.prototype,"initialCalendarView",null),Me([h("watchCurrentPeriodChange")],Se.prototype,"generateCalendarView",null);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 Ae extends c{setCurrentPeriod(e){this.currentPeriod=e}updateCalendarPeriod(e,t){switch(e){case"month":this.setCurrentPeriod(new T(t,this.showWeekends,this.timezone));break;case"week":this.setCurrentPeriod(new S(t,this.showWeekends,this.timezone));break;case"day":t=!1===this.showWeekends?I(t):t,this.setCurrentPeriod(new M(t,this.showWeekends,this.timezone))}}initialCurrentPeriod(){this.updateCalendarPeriod(this.viewMode,z.from(new Date,this.timezone))}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}}}}Te([d({writable:!0})],Ae.prototype,"currentPeriod",void 0),Te([d()],Ae.prototype,"changeEventEmitter",void 0),Te([d({writable:!0})],Ae.prototype,"viewMode",void 0),Te([d()],Ae.prototype,"showWeekends",void 0),Te([d()],Ae.prototype,"timezone",void 0),Te([h("componentWillLoad")],Ae.prototype,"initialCurrentPeriod",null),Te([h("watchCurrentPeriodChange")],Ae.prototype,"emitChangeEvent",null),Te([h("watchViewModeChange")],Ae.prototype,"updateCurrentPeriodByViewMode",null),Te([h("watchShowWeekendsChange")],Ae.prototype,"updateCurrentPeriodAfterHideWeekEndsChange",null);var Ve=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 c{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}getMoreEventsBoxRef(){return this.moreEventsBoxRef}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(){m.addUniqueObserverToNode(this.host,q,(e=>{this.maxMonthDisplayEventsCount!==e.detail&&(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)},isScreenPosition:!0},e("div",{tabIndex:0,slot:"popover-content",role:"button",class:"more-button",onKeyDown:W()},`${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",ref:e=>this.moreEventsBoxRef=e},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){e?(this.popoverHideObserver=new ie((()=>!0),(async()=>await e.hide())),ne.register(u.getSubject(this.host,G),this.popoverHideObserver)):this.popoverHideObserver&&ne.unregister(u.getSubject(this.host,G),this.popoverHideObserver),e&&m.addUniqueObserverToNode(e,y,(()=>{ne.notify(u.getSubject(this.renderer.getEventPreviewRef(),J),{})}))}}Ve([d()],$e.prototype,"viewMode",void 0),Ve([d()],$e.prototype,"host",void 0),Ve([d()],$e.prototype,"calendarEventController",void 0),Ve([d()],$e.prototype,"eventItemRenderer",void 0),Ve([d()],$e.prototype,"fullDayEventLayoutRenderer",void 0),Ve([d()],$e.prototype,"eventPreviewPopoverRenderer",void 0),Ve([d()],$e.prototype,"renderer",void 0),Ve([d()],$e.prototype,"eventPreviewPopoverController",void 0),Ve([h("componentWillLoad")],$e.prototype,"addMaxDisplayCountChange",null);class Le{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?` ${U.t("until {0}",`${this.until.getMonthName()} ${this.until.date}, ${this.until.year}`)}`:this.count?` ${U.t("after {0} occurrences",this.count)}`:""}}Le.daySeconds=864e5;class Be extends Le{constructor(e,t,i,n){super(e,t,i,n),this.initCache()}generateRepeatString(){return(this.interval>1?U.t("Repeat every {0} days",this.interval):U.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=z.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 Fe extends Le{constructor(e,t,i,n){super(e,t,i,n),this.byMonthDay=this.repeatStartDate.date,this.initCache()}generateRepeatString(){return(this.interval>1?U.t("Repeat every {0} months on day {1}",this.interval,this.byMonthDay):U.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=z.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 We extends Le{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=>U.t(O[e])));return(this.interval>1?U.t("Repeat every {0} weeks on {1}",this.interval,e.join(", ")):U.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=>z.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=We.weekDay.indexOf(i)-t,{year:r,month:o,date:a}=this.repeatStartDate,s=z.from(new Date(r,o-1,a+n));(!this.until||s.toDate()<=this.until.toDate())&&e.push(s)})),this.cache=[e]}sortWeekDay(e){return e&&e.length?e.map((e=>e.toLocaleLowerCase())).sort(((e,t)=>We.weekDay.indexOf(e)-We.weekDay.indexOf(t))):[We.weekDay[this.getCurrentDayIndex(this.repeatStartDate)]]}getCurrentDayIndex(e){return e.toDate().getDay()}getValidCache(){const e=re(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)}}We.weekDay=["Sun","Mon","Tue","Wed","Thu","Fri","Sat"].map((e=>e.toLowerCase()));class Ne extends Le{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=U.t(this.repeatStartDate.getMonthName());return(this.interval>1?U.t("Repeat every {0} years on {1} {2}",this.interval,e,this.matchDay):U.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=z.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 He=new class{getPattern(e,t,i=A()){const n=z.from(e),{frequency:r,interval:o=1,byWeekDay:a,until:s,count:l}=t,d=this.initDate(s,i);return this.initRepeatPattern(r,n,o<1?1:o,l,d,a)}initDate(e,t){if(e)return z.from(new Date(e),t)}initRepeatPattern(e,t,i,n,r,o){switch(e){case"daily":return new Be(t,i,n,r);case"weekly":return new We(t,i,n,r,o);case"monthly":return new Fe(t,i,n,r);default:return new Ne(t,i,n,r)}}},_e=/^\d{1,2}\/\d{1,2}\/\d{4}/,Ue=/^\d{1,2}:\d{1,2}/;class Ke{constructor(e,t,i){this._eventSpansDays=1,this.repeatPattern=null,this._event=e,this._eventKey=t||oe(),this._timezone=i||A(),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._startDateTime.toDate()}get endDate(){return this._endDateTime.toDate()}get startTime(){return this._startDateTime.calendarTime}get endTime(){return this._endDateTime.calendarTime}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 Ke(Object.assign(Object.assign({},this._event),{startDate:t.toDate(),endDate:i,startTime:this.startTime.toString(),endTime:this.endTime.toString()}),e)}isGroupEvent(){return this._eventSpansDays>1}isCurrentDayEvent(e){const{startDate:t,endDate:i}=this,n=z.from(t),r=z.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=U.t(Object.values(O)[e.toDate().getDay()]),n=this.startTime.toString(t),r=this.endTime.toString(t);return`${i}, ${e.date} ${e.getMonthName(!0)} ${e.year} ${n} - ${r}`}getEventMinutes(){return V.calculateDuration(this.startTime,this.endTime,"minutes")}getRepeatSeries(e){return this.repeatPattern?this.repeatPattern.getRepeatSeries(e,this._eventSpansDays):[]}updateTimezone(e){this._timezone=e,this._startDateTime.setTimezone(e),this._endDateTime.setTimezone(e)}checkEventRequireField(e){const{title:t,startDate:i,endDate:n,startTime:r,endTime:o}=e;if(i&&"string"==typeof i&&!_e.test(i)||n&&"string"==typeof n&&!_e.test(n))throw new Error("Invalid calendar event item, the date format should be MM/DD/YYYY!");if(r&&"string"==typeof r&&!Ue.test(r)||o&&"string"==typeof o&&!Ue.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;this.processStartDate(t,i),this.processEndDate(n,r,t)}processStartDate(e,t){this._startDateTime=$.fromInitDataSource(e,{timezone:this._timezone,time:t})}processEndDate(e,t,i){this._endDateTime=$.fromInitDataSource(e||i,{timezone:this._timezone,time:t,endTimeMissing:!t&&!e})}initRepeatPattern(){this._event.repeatOptions&&this._event.repeatOptions.frequency&&(this.repeatPattern=He.getPattern(this.startDate,this._event.repeatOptions,this._timezone))}initEventSpansDays(){const e=z.from(this.startDate),t=z.from(this.endDate);this._eventSpansDays=(t.toDate().valueOf()-e.toDate().valueOf())/864e5+1}}var Ye=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 c{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)}updateAfterTimezoneChange(){this.calendarEvents.length>0&&this.calendarEvents.forEach((e=>e.updateTimezone(this.timezone))),ne.notify(u.getSubject(this.host,G),{}),this.repeatEventMap.clear()}initCalendarEvents(e){const t=[];e&&e.forEach((e=>{try{const i=new Ke(e,void 0,this.timezone);t.push(i)}catch(t){v.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}}}Ye([d()],Ze.prototype,"host",void 0),Ye([d({writable:!0})],Ze.prototype,"calendarEvents",void 0),Ye([d()],Ze.prototype,"currentPeriod",void 0),Ye([d()],Ze.prototype,"events",void 0),Ye([d()],Ze.prototype,"timezone",void 0),Ye([h("watchEventsChange")],Ze.prototype,"updateAfterEventChange",null),Ye([h("componentWillLoad")],Ze.prototype,"updateWhenComponentWillLoad",null),Ye([h("watchTimezoneChange")],Ze.prototype,"updateAfterTimezoneChange",null);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 qe extends c{render(t,i,n,r=!1){return e("vega-calendar-event",{"data-calendar-ref":this.host,key:`${t.eventKey}-${t.startTime.toString()}-${t.endTime.toString()}`,calendarEvent:t,class:i,onKeyDown:W(),onClick:()=>{this.handleEventClick(t),this.enabledEventPreview&&this.setupPreviewContainer(t,n,r)}},!t.isRepeatEvent&&e("slot",{name:L(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")),ne.notify(u.getSubject(r,Q),{event:e,targetCalendarViewDate:t,timeFormat:this.timeFormat,eventActions:this.eventPreviewActionsController.retrieveActionsVisibility(e,t)});const o=this.host.querySelector("[slot=event-preview-additional-fields]");o&&r.append(o);const a=L(e.event.key),s=this.host.querySelector(`[slot=${a}]`),l=r.querySelector(`[slot=${a}]`);s&&!l&&r.append(s.cloneNode(!0)),n.append(r)}}}qe.backgroundColorModeEventHeight=18,Xe([d()],qe.prototype,"host",void 0),Xe([d()],qe.prototype,"calendarView",void 0),Xe([d()],qe.prototype,"eventClickEmitter",void 0),Xe([d()],qe.prototype,"timeFormat",void 0),Xe([d()],qe.prototype,"enabledEventPreview",void 0),Xe([d()],qe.prototype,"renderer",void 0),Xe([d()],qe.prototype,"eventPreviewPopoverController",void 0),Xe([d()],qe.prototype,"eventPreviewActionsController",void 0);var Ge=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 Je extends ae{constructor(){super({target:()=>this.host,callback:()=>this.updateMaxDisplayCountWithDebounce()}),this.updateMaxDisplayCountWithDebounce=se(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-Je.monthDateTitleHeight)/qe.backgroundColorModeEventHeight);ne.notify(u.getSubject(this.host,q),{host:this.host,detail:i})}}catch(e){}}updateMaxDisplayCountAfterSwitchToMonthView(e){"month"===e&&this.updateMaxDisplayCountWithDebounce()}}Je.monthDateTitleHeight=26,Ge([d()],Je.prototype,"host",void 0),Ge([d()],Je.prototype,"monthEventRenderer",void 0),Ge([d()],Je.prototype,"viewMode",void 0),Ge([h("componentDidLoad")],Je.prototype,"updateMaxDisplayCount",null),Ge([h("watchViewModeChange")],Je.prototype,"updateMaxDisplayCountAfterSwitchToMonthView",null);var Qe=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 et extends c{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*qe.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=et.maxDisplayEventLength;return e.forEach((e=>{const n=e.length>i?e.slice(0,i):e;t.push(n)})),t}}}et.maxDisplayEventLength=2,Qe([d()],et.prototype,"calendarView",void 0),Qe([d()],et.prototype,"calendarEventController",void 0),Qe([d()],et.prototype,"eventItemRenderer",void 0),Qe([d()],et.prototype,"fullDayEventLayoutRenderer",void 0),Qe([d()],et.prototype,"showAllEventsInDayOrWeekView",void 0),Qe([d()],et.prototype,"dayViewFullDayEventMoreButtonRenderer",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};class it extends c{render(t,i){const n=[];return t.eventLayoutCells.forEach(((r,o)=>{let a=r.getEventBySlotIndex(0),s=0;for(let l=0;l<=it.TOTAL_NUMBER_OF_CELLS;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/it.TOTAL_NUMBER_OF_CELLS*e+"%",width:`calc(100% - ${100*r}%)`,height:100/it.TOTAL_NUMBER_OF_CELLS*(t-e)+"%",zIndex:i>0?`${i}`:void 0}}}it.TOTAL_NUMBER_OF_CELLS=96,tt([d()],it.prototype,"eventItemRenderer",void 0),tt([d()],it.prototype,"eventPreviewPopoverRenderer",void 0);class nt{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 rt{get eventLayoutCells(){return this.cells}}class ot extends rt{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 at{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 st extends at{constructor(){super(...arguments),this.slots=st.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,n=B(t.toString()),r=B(i.toString());return[n,Math.max(r,n+1)]}}st.defaultSlots=Array(96).fill(null);class lt extends nt{generate(e){const t=[new st];return e.forEach((e=>{this.addCurrentEventToLayout(t,e)})),new ot(t)}createNewLayoutCell(){return new st}}class dt{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=B(e.startTime.toString()),n=B(t.startTime.toString());return i===n?B(t.endTime.toString())-B(e.endTime.toString()):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 ct=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 ht extends c{constructor(){super(...arguments),this.calendarEventSorter=new dt,this.dayViewTimedEventLayoutGenerator=new lt}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)}}ct([d()],ht.prototype,"calendarView",void 0),ct([d()],ht.prototype,"calendarEventController",void 0),ct([d()],ht.prototype,"dayViewEventLayoutRenderer",void 0);class vt extends rt{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 pt extends at{constructor(){super(...arguments),this.slots=pt.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}}pt.defaultSlots=Array(7).fill(null);class ft extends nt{generate(e){const t=this.collectAllShouldOrderLongEvents(e),i=[this.createNewLayoutCell()];return t.forEach((e=>{this.addCurrentEventToLayout(i,e)})),new vt(i)}createNewLayoutCell(){return new pt}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 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 mt extends c{constructor(){super(...arguments),this.longEventLayoutGenerator=new ft,this.calendarEventSorter=new dt}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?mt.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*qe.backgroundColorModeEventHeight+n}px`,width:100/r*(a-o)+"%",opacity:l?"1":"0"}}}mt.monthViewEventOffsetTop=26,wt([d()],mt.prototype,"eventItemRenderer",void 0),wt([d()],mt.prototype,"viewMode",void 0),wt([d()],mt.prototype,"calendarView",void 0),wt([d()],mt.prototype,"eventPreviewPopoverRenderer",void 0);var ut=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 c{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:W(),onClick:this.updateShowAllFlag},`${t} More`)}resetShowAllFlag(){this.showAllEventsInDayOrWeekView=!1}}ut([d({writable:!0})],gt.prototype,"showAllEventsInDayOrWeekView",void 0),ut([h("watchViewModeChange")],gt.prototype,"resetShowAllFlag",null);var bt=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 xt extends c{render(t){const i=t.findIndex((e=>e.isToday(this.timezone)))>=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(this.timezone)}})))))}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;if(this.timezone&&this.timezone!==A())try{const t=new Intl.DateTimeFormat([],{timeZone:this.timezone,hour:"2-digit",minute:"2-digit",hour12:!1}).formatToParts(e),i=t.find((e=>"hour"===e.type)),n=t.find((e=>"minute"===e.type));if(void 0!==i&&void 0!==n){return(60*parseInt(i.value,10)+parseInt(n.value,10))/1440*100+"%"}}catch(e){v.warn("Invalid timezone:",this.timezone)}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"),i=t?t.offsetHeight:0,n=Math.max(("number"==typeof e.offsetHeight?e.offsetHeight:0)-i,0)/2,r="number"==typeof e.scrollHeight?e.scrollHeight:0,o=16,a=Number(this.getTimeMarkerPosition().replace("%",""))/100*Math.max(r-o-i,0);if(!isNaN(n)&&a&&a>n)return a-n+o}return 0}}bt([d()],xt.prototype,"viewMode",void 0),bt([d()],xt.prototype,"viewRenderer",void 0),bt([d()],xt.prototype,"timezone",void 0),bt([h("watchViewModeChange")],xt.prototype,"updateTimeLine",null),bt([h("disconnectedCallback")],xt.prototype,"clearTimer",null),bt([h("connectedCallback")],xt.prototype,"updateTimeLineIfComponentAddBack",null),bt([h("componentDidLoad")],xt.prototype,"displayCurrentTimeBlockByDefault",null);var yt=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 kt extends c{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(z.from(t)))}else this.setPostOperationDate(z.from(e.current.toDate()))}updateAfterTimezoneChange(){this.postOperationDate=z.from(new Date,this.timezone)}shouldSetCurrentDateToFirstDayOfMonth(e,t){return"month"===e.type&&"month"===(null==t?void 0:t.type)&&!e.current.equal(z.from(new Date,this.timezone))}}yt([d({writable:!0})],kt.prototype,"postOperationDate",void 0),yt([d()],kt.prototype,"timezone",void 0),yt([h("watchCurrentPeriodChange")],kt.prototype,"setDate",null),yt([h("watchTimezoneChange")],kt.prototype,"updateAfterTimezoneChange",null);var Ct=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 Rt extends c{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",{isScreenPosition:!0,placement:"day"===this.viewMode?"top":"right",alignment:"center",class:{"event-preview-popover":!0,block:!0},padding:"0",size:Rt.SINGLE_EVENT_PREVIEW_WIDTH,ref:e=>{this.setPopoverHideObserver(e)}},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){e?(this.popoverHideObserver=new ie((()=>!0),(async()=>await e.hide())),ne.register(u.getSubject(this.host,G),this.popoverHideObserver)):this.popoverHideObserver&&ne.unregister(u.getSubject(this.host,G),this.popoverHideObserver)}}Rt.SINGLE_EVENT_PREVIEW_WIDTH=400,Ct([d()],Rt.prototype,"host",void 0),Ct([d()],Rt.prototype,"renderer",void 0),Ct([d()],Rt.prototype,"viewMode",void 0),Ct([d()],Rt.prototype,"timeFormat",void 0),Ct([d()],Rt.prototype,"eventItemRenderer",void 0),Ct([d()],Rt.prototype,"enabledEventPreview",void 0),Ct([d()],Rt.prototype,"eventPreviewPopoverController",void 0);class jt extends c{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)}}clearAllPreviewContainers(){this.singleEventPreviewContainerMap.clear(),this.groupEventsPreviewContainerMap.clear()}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}`}}!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)}([h("watchTimezoneChange")],jt.prototype,"clearAllPreviewContainers",null);class Et extends ce{scheduleFocus(){super.enqueueTheTaskIntoQueue()}async doTask(){if(await Promise.resolve(),this.host.shadowRoot){const e=this.host.shadowRoot.querySelector(".calendar-view-day .calendar-view-title > div");e&&e.focus()}}}!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)}([d()],Et.prototype,"host",void 0);var Dt,zt=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};!function(e){e.Edit="Edit",e.Close="Close"}(Dt||(Dt={}));class Ot extends c{constructor(){super(...arguments),this.handleActionButtonClick=e=>{if(e){const t=e.dataset.actionType;m.addUniqueObserverToNode(e,g,(()=>{this.onHidePopover(),t!==Dt.Close&&this.calendarRef&&ne.notify(u.getSubject(this.calendarRef,ee),{detail:{event:this.currentEvent,date:this.previewPayload.targetCalendarViewDate,actionType:t}})}))}}}componentWillLoad(){this.calendarRef=H(this.host,"vega-calendar")}componentDidRender(){const e=H(this.host,"vega-popover-content-box");this.currentEvent&&e&&!e.classList.contains("vega-force-hidden")&&ne.notify(u.getSubject(e,te),{})}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(){const{showEditButton:t}=this.eventActions||{};return e("vega-flex",{justifyContent:"end",class:"preview-actions"},t&&e("vega-button-circle",{"data-aria-label":U.t("Edit event"),icon:D.getIconKey("pen"),color:"text-primary",variant:"icon-only","data-action-type":Dt.Edit,ref:this.handleActionButtonClick}),e("vega-button-circle",{"data-aria-label":U.t("Close event preview detail"),icon:D.getIconKey("close"),color:"text-primary",variant:"icon-only","data-action-type":Dt.Close,ref:this.handleActionButtonClick}))}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",{"aria-hidden":"true",icon:D.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()))))}onHidePopover(){this.calendarRef&&ne.notify(u.getSubject(this.calendarRef,G),{})}renderEventTitle(){const i=this.currentEvent,n=L(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:he.nonce},F(this.currentEvent.color))}}D.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>'},pen:{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="M36.4 360.9L13.4 439 1 481.2C-1.5 489.7 .8 498.8 7 505s15.3 8.5 23.7 6.1L73 498.6l78.1-23c12.4-3.6 23.7-9.9 33.4-18.4c1.4-1.2 2.7-2.5 4-3.8L492.7 149.3c21.9-21.9 24.6-55.6 8.2-80.5c-2.3-3.5-5.1-6.9-8.2-10L453.3 19.3c-25-25-65.5-25-90.5 0L58.6 323.5c-10.4 10.4-18 23.3-22.2 37.4zm46 13.5c1.7-5.6 4.5-10.8 8.4-15.2c.6-.6 1.1-1.2 1.7-1.8L321 129 383 191 154.6 419.5c-4.7 4.7-10.6 8.2-17 10.1l-23.4 6.9L59.4 452.6l16.1-54.8 6.9-23.4z"/></svg>'}}),zt([d()],Ot.prototype,"host",void 0),zt([d()],Ot.prototype,"previewPayload",void 0),zt([d()],Ot.prototype,"currentEvent",void 0),zt([d()],Ot.prototype,"eventActions",void 0),zt([d()],Ot.prototype,"translationSlimmer",void 0),zt([h("componentWillLoad")],Ot.prototype,"componentWillLoad",null),zt([h("componentDidRender")],Ot.prototype,"componentDidRender",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 It extends c{constructor(){super(...arguments),this.handlePreviewActionButtonClick=e=>{if(e&&e.detail){const{event:t,date:i,actionType:n}=e.detail;n===Dt.Edit&&this.eventEditEmitter.emit({rawEvent:t.event,date:{year:i.year,month:i.month,date:i.date}})}}}retrieveActionsVisibility(e,t){let i={};if(this.eventEditable&&"function"==typeof this.getEventPreviewActions){const{date:n,month:r,year:o}=t;i=this.getEventPreviewActions(e.event,{date:n,month:r,year:o})}return i}registerPreviewActionButtonEvent(){m.addUniqueObserverToNode(this.host,ee,this.handlePreviewActionButtonClick)}unregisterPreviewActionButtonEvent(){m.removeUniqueObserverFromNode(this.host,ee)}}Pt([d()],It.prototype,"host",void 0),Pt([d()],It.prototype,"eventEditable",void 0),Pt([d()],It.prototype,"getEventPreviewActions",void 0),Pt([d()],It.prototype,"eventEditEmitter",void 0),Pt([h("connectedCallback")],It.prototype,"registerPreviewActionButtonEvent",null),Pt([h("disconnectedCallback")],It.prototype,"unregisterPreviewActionButtonEvent",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 St extends ve{constructor(){super((e=>[{keyCode:["ArrowLeft","ArrowRight","ArrowUp","ArrowDown"],activeElementInScope:()=>[e.monthViewRenderer.getMonthContainerRef()],callback:t=>e.onDaysDirectionKeyDown(t)},{keyCode:["ArrowUp","ArrowDown"],activeElementInScope:()=>[e.monthEventRenderer.getMoreEventsBoxRef()],callback:t=>e.onEventsDirectionKeyDown(t)},{keyCode:["Enter"],activeElementInScope:()=>[e.monthViewRenderer.getMonthContainerRef()],eventName:"keydown",callback:t=>e.onDayEnter(t)}]))}onDayEnter(e){const t=e.composedPath()[0];if(t.classList.contains("grid-col")&&t.dataset.date&&this.showSwitchView){const i=z.fromString(t.dataset.date);i&&this.monthViewRenderer.onDayItemKeyDown(e,i)}}onEventsDirectionKeyDown(e){const t=pe(),i=null==t?void 0:t.activeElement;if(!i)return;const n=this.monthEventRenderer.getMoreEventsBoxRef();if(!n)return;const r=Array.from(n.querySelectorAll("vega-calendar-event")),o=r.findIndex((e=>e===i)),a="ArrowDown"===e.code?o+1:o-1;a>=0&&a<r.length&&r[a].focus()}onDaysDirectionKeyDown(e){const t=s(this.host.shadowRoot);if(!t)return;const i=H(t,".row-cell");if(!i)return;const n=this.monthViewRenderer.getMonthContainerRef();if(!n)return;const r=Array.from(n.querySelectorAll(".row-cell")),o=r.findIndex((e=>e===i));let a=-1;const l=this.showWeekends?7:5;switch(e.code){case"ArrowRight":a=o+1;break;case"ArrowLeft":a=o-1;break;case"ArrowDown":a=o+l;break;case"ArrowUp":a=o-l}a>=0&&a<r.length&&r[a].querySelector(".grid-col").focus()}}Mt([d()],St.prototype,"host",void 0),Mt([d()],St.prototype,"showWeekends",void 0),Mt([d()],St.prototype,"monthViewRenderer",void 0),Mt([d()],St.prototype,"monthEventRenderer",void 0),Mt([d()],St.prototype,"showSwitchView",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 At=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.vegaEventEdit=r(this,"vegaEventEdit",7),this.eventEdit=r(this,"eventEdit",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 de,this.vegaComponentUsageRuntimeMetricsSlimmer=new f,this.renderer=new xe,this.switchPanelRenderer=new ke,this.dayViewFocusSlimmer=new Et,this.viewRenderer=new Re,this.monthViewRenderer=new ze,this.viewWithTimeRenderer=new Pe,this.timeLineRenderer=new Ie,this.timeMarkerRenderer=new xt,this.monthEventRenderer=new $e,this.currentPeriodController=new Ae,this.keyboardController=new St,this.calendarViewController=new Se,this.postOperationDateController=new kt,this.dayViewFullDayEventRenderer=new et,this.eventPreviewPopoverController=new jt,this.dayViewFullDayEventMoreButtonRenderer=new gt,this.dayViewTimedEventRenderer=new ht,this.eventItemRenderer=new qe,this.dayViewEventLayoutRenderer=new it,this.fullDayEventLayoutRenderer=new mt,this.eventPreviewPopoverRenderer=new Rt,this.calendarEventController=new Ze,this.eventPreviewActionsController=new It,this.eventResponsiveController=new Je,this.changeEventEmitter=_(At,b),this.eventClickEmitter=_(At,k),this.dateDblClickEmitter=_(At,C),this.moreActionClickEmitter=_(At,R),this.dateClickEmitter=_(At,j),this.eventEditEmitter=_(At,E),this.changeEventPrevent=new X([b],(()=>this.switchPanelRenderer.getSwitchPanelRef())),this.timeFormatNotifySlimmer=le(At,"timeFormat","watchTimeFormat"),this.showEventColorBarNotifySlimmer=le(At,"showEventColorBar","watchShowEventColorBar"),this.postOperationDate=this.getInitialPostOperationDate(),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,this.timezone=A(),this.eventEditable=!0}watchCurrentPeriodChange(e,t){}watchViewModeChange(e){}watchEventsChange(e){}watchTimeFormat(e){}watchShowEventColorBar(e){}watchShowWeekendsChange(){}watchTimezoneChange(){}render(){return l(e(o,null,this.renderer.render()),this.host)}getInitialPostOperationDate(){return z.from(new Date,this.timezone)}get host(){return a(this)}static get watchers(){return{currentPeriod:["watchCurrentPeriodChange"],viewMode:["watchViewModeChange"],events:["watchEventsChange"],timeFormat:["watchTimeFormat"],showEventColorBar:["watchShowEventColorBar"],showWeekends:["watchShowWeekendsChange"],timezone:["watchTimezoneChange"]}}};Tt([w()],At.prototype,"globalSlimmer",void 0),Tt([p()],At.prototype,"translationSlimmer",void 0),Tt([p()],At.prototype,"vegaComponentUsageRuntimeMetricsSlimmer",void 0),Tt([p()],At.prototype,"renderer",void 0),Tt([p()],At.prototype,"switchPanelRenderer",void 0),Tt([p()],At.prototype,"dayViewFocusSlimmer",void 0),Tt([p()],At.prototype,"viewRenderer",void 0),Tt([p()],At.prototype,"monthViewRenderer",void 0),Tt([p()],At.prototype,"viewWithTimeRenderer",void 0),Tt([p()],At.prototype,"timeLineRenderer",void 0),Tt([p()],At.prototype,"timeMarkerRenderer",void 0),Tt([p()],At.prototype,"monthEventRenderer",void 0),Tt([p()],At.prototype,"currentPeriodController",void 0),Tt([p()],At.prototype,"keyboardController",void 0),Tt([p()],At.prototype,"calendarViewController",void 0),Tt([p()],At.prototype,"postOperationDateController",void 0),Tt([p()],At.prototype,"dayViewFullDayEventRenderer",void 0),Tt([p()],At.prototype,"eventPreviewPopoverController",void 0),Tt([p()],At.prototype,"dayViewFullDayEventMoreButtonRenderer",void 0),Tt([p()],At.prototype,"dayViewTimedEventRenderer",void 0),Tt([p()],At.prototype,"eventItemRenderer",void 0),Tt([p()],At.prototype,"dayViewEventLayoutRenderer",void 0),Tt([p()],At.prototype,"fullDayEventLayoutRenderer",void 0),Tt([p()],At.prototype,"eventPreviewPopoverRenderer",void 0),Tt([p()],At.prototype,"calendarEventController",void 0),Tt([p()],At.prototype,"eventPreviewActionsController",void 0),Tt([p()],At.prototype,"eventResponsiveController",void 0),Tt([p()],At.prototype,"changeEventEmitter",void 0),Tt([p()],At.prototype,"eventClickEmitter",void 0),Tt([p()],At.prototype,"dateDblClickEmitter",void 0),Tt([p()],At.prototype,"moreActionClickEmitter",void 0),Tt([p()],At.prototype,"dateClickEmitter",void 0),Tt([p()],At.prototype,"eventEditEmitter",void 0),Tt([p()],At.prototype,"changeEventPrevent",void 0),Tt([p()],At.prototype,"timeFormatNotifySlimmer",void 0),Tt([p()],At.prototype,"showEventColorBarNotifySlimmer",void 0),At.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:not(:focus)::part(event-container){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 Vt=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 c{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",{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",{class:o,ref:e=>this.slotContainerRef=e},!this.slotMode&&this.renderEventStatus(),this.slotMode?this.getSlotElement():this.defaultNormalMonthEventContentRender());{const t=this.calendarEvent.getEventMinutes();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}),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"},`${t.toString(this.timeFormat)} ${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","aria-hidden":"true",icon:D.getIconKey("clock-three")}),e("span",null,`${i.toString(this.timeFormat)} - ${n.toString(this.timeFormat)}`)))}getSlotElement(){if(!this.calendarEvent.isRepeatEvent)return e("slot",null)}injectBackgroundColorStyle(){return e("style",{nonce:he.nonce},F(this.calendarEvent.color))}}D.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>'}}),Vt([d()],$t.prototype,"host",void 0),Vt([d()],$t.prototype,"timeFormat",void 0),Vt([d()],$t.prototype,"calendarEvent",void 0),Vt([d()],$t.prototype,"slotMode",void 0),Vt([d()],$t.prototype,"showColorBar",void 0);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};class Bt extends we{constructor(){super({parent:()=>this.host["data-calendar-ref"],subStates:[{subStateName:"timeFormat",parentStateName:"timeFormat"},{subStateName:"showColorBar",parentStateName:"showEventColorBar"}]})}}Lt([d({writable:!0})],Bt.prototype,"timeFormat",void 0),Lt([d({writable:!0})],Bt.prototype,"showColorBar",void 0);class Ft extends c{setVerticalTitleMaxHeight(){const e=this.renderer.getEventTitleContainerRef();if(e&&e.classList.contains("title-word-wrap")){const t=window.getComputedStyle(e),i=me(t.height),n=me(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)}([d()],Ft.prototype,"renderer",void 0);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 Nt extends c{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")}}Wt([d()],Nt.prototype,"host",void 0),Wt([d()],Nt.prototype,"calendarEvent",void 0),Wt([d({writable:!0})],Nt.prototype,"slotMode",void 0),Wt([d()],Nt.prototype,"renderer",void 0),Wt([h("componentWillLoad")],Nt.prototype,"findTheCalendarEventSlot",null),Wt([h("componentDidLoad")],Nt.prototype,"appendTheRepeatEventSlotToContainer",null);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};const _t=class{constructor(e){n(this,e),this.globalSlimmer={},this.pageResizeObserverSlimmer=new ae({target:()=>this.host,callback:()=>this.titleMaxHeightController.setVerticalTitleMaxHeight()}),this.vegaComponentUsageRuntimeMetricsSlimmer=new f,this.renderer=new $t,this.slotController=new Nt,this.subStateController=new Bt,this.titleMaxHeightController=new Ft,this.timeFormat="24-hour",this.slotMode=!1,this.showColorBar=!0}render(){return fe(e("slot",null)),l(e(o,{role:this.calendarEvent?"button":void 0,tabindex:this.calendarEvent?0:void 0},this.calendarEvent?this.renderer.render():null),this.host)}get host(){return a(this)}};Ht([w()],_t.prototype,"globalSlimmer",void 0),Ht([p()],_t.prototype,"pageResizeObserverSlimmer",void 0),Ht([p()],_t.prototype,"vegaComponentUsageRuntimeMetricsSlimmer",void 0),Ht([p()],_t.prototype,"renderer",void 0),Ht([p()],_t.prototype,"slotController",void 0),Ht([p()],_t.prototype,"subStateController",void 0),Ht([p()],_t.prototype,"titleMaxHeightController",void 0),_t.style='.bg-disabled{background-color:rgba(var(--v-bg-disabled, 176, 180, 181, 1))}:host{display:block;box-sizing:border-box;width:100%;outline:none}: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 .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(.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) .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}:host(:focus) .background-color-mode,:host(:focus-visible) .background-color-mode{outline:2px solid rgba(var(--v-border-color-action, 19, 98, 226, 1));outline-offset:0px}:host(.month-event:focus) .event-container,:host(.month-event:focus-visible) .event-container,:host(.day-event:focus) .event-container,:host(.day-event:focus-visible) .event-container{outline:2px solid rgba(var(--v-border-color-action, 19, 98, 226, 1));outline-offset:0px}.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 Ut=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 Kt extends c{registerEventPreviewUpdateObserver(){m.addUniqueObserverToNode(this.host,Q,(e=>{this.previewPayload=e,this.currentEvent=e.event,this.eventActions=e.eventActions})),m.addUniqueObserverToNode(this.host,J,(()=>{this.currentEvent=null}))}unregisterEventPreviewUpdateObserver(){m.removeUniqueObserverFromNode(this.host,Q),m.removeUniqueObserverFromNode(this.host,J)}}Ut([d()],Kt.prototype,"host",void 0),Ut([d({writable:!0})],Kt.prototype,"currentEvent",void 0),Ut([d({writable:!0})],Kt.prototype,"previewPayload",void 0),Ut([d({writable:!0})],Kt.prototype,"eventActions",void 0),Ut([h("connectedCallback")],Kt.prototype,"registerEventPreviewUpdateObserver",null),Ut([h("disconnectedCallback")],Kt.prototype,"unregisterEventPreviewUpdateObserver",null);var Yt=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 Zt=class{constructor(e){n(this,e),this.detailRenderer=new Ot,this.stateController=new Kt,this.translationSlimmer=new de,this.globalSlimmer={},this.vegaComponentUsageRuntimeMetricsSlimmer=new f,this.eventActions={}}render(){return l(e(o,null,this.previewPayload&&this.detailRenderer.render()),this.host)}get host(){return a(this)}};Yt([p()],Zt.prototype,"detailRenderer",void 0),Yt([p()],Zt.prototype,"stateController",void 0),Yt([p()],Zt.prototype,"translationSlimmer",void 0),Yt([w()],Zt.prototype,"globalSlimmer",void 0),Yt([p()],Zt.prototype,"vegaComponentUsageRuntimeMetricsSlimmer",void 0),Zt.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 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 qt=class{constructor(e){n(this,e),this.globalSlimmer={},this.vegaComponentUsageRuntimeMetricsSlimmer=new f}render(){return l(e(o,{slot:L(this.eventKey)},e("slot",null)),this.host)}get host(){return a(this)}};Xt([w()],qt.prototype,"globalSlimmer",void 0),Xt([p()],qt.prototype,"vegaComponentUsageRuntimeMetricsSlimmer",void 0),qt.style=":host{width:100%;height:100%;position:relative}";export{At as vega_calendar,_t as vega_calendar_event,Zt as vega_calendar_event_preview,qt as vega_calendar_event_slot}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{h as e,H as t,r as i,c as s,g as o}from"./p-6b2342e0.js";import{R as r}from"./p-280cbcdb.js";import{s as n}from"./p-519a7d55.js";import{g as a}from"./p-49a2e141.js";import{c as l,V as p,M as d,L as h,I as c}from"./p-6e1ab235.js";import{a as v}from"./p-6e70d3cc.js";import{R as u}from"./p-031c0cf7.js";import{D as f,d as g}from"./p-f28a6074.js";import{x as m,u as x,v as b,V as w,f as y,w as j,e as I,i as S,q as R,M as T,N as C}from"./p-9af0e2e7.js";import{V as D,I as O}from"./p-4415ad28.js";import{l as E,m as L,n as V}from"./p-6c43d54a.js";import{i as z}from"./p-d27ae9ff.js";import{C as k}from"./p-2d0d575f.js";import{F as P}from"./p-a528714c.js";import{c as A}from"./p-6ac8e655.js";import{c as _}from"./p-1ec763ab.js";import{c as N}from"./p-613ddaab.js";import{V as B}from"./p-e1fbfd20.js";import{h as F,l as M}from"./p-f0e828d8.js";import{F as U}from"./p-c347e08a.js";import{P as G}from"./p-81dd00d0.js";import{c as K}from"./p-6b5cb920.js";import{C as W}from"./p-e27626f6.js";import{Z as $,$ as q}from"./p-e4c4ea35.js";import{M as H}from"./p-78a57a17.js";import{T as J}from"./p-52b8f2d2.js";import{T as Z}from"./p-57f220b5.js";import{r as Q}from"./p-77e64f26.js";import{I as X}from"./p-abd7aeaa.js";import{V as Y}from"./p-3b791b5d.js";import"./p-d4ea8e22.js";import"./p-ed45b3b6.js";import"./p-262ec334.js";import"./p-0c667d6a.js";import"./p-18e8d9b7.js";import"./p-5a25014f.js";import"./p-331a62d5.js";import"./p-e6adf829.js";import"./p-593e0f80.js";import"./p-6a334573.js";import"./p-8b5d3a52.js";import"./p-b75ee3ba.js";import"./p-02841589.js";import"./p-af5cb9bc.js";import"./p-f1c672e4.js";import"./p-5f377954.js";import"./p-d884c644.js";var ee=function(e,t,i,s){var o,r=arguments.length,n=r<3?t:null===s?s=Object.getOwnPropertyDescriptor(t,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(e,t,i,s);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(n=(r<3?o(n):r>3?o(t,i,n):o(t,i))||n);return r>3&&n&&Object.defineProperty(t,i,n),n};class te extends p{constructor(){super(...arguments),this.renderErrorMessage=()=>e("div",{class:"vega-input-select-error-message"}),this.renderHelpMessage=()=>e("div",{class:"vega-input-select-hint"},this.hint),this.handleLabelButtonClick=()=>{this.labelButtonClickEventEmitter.emit()}}render(){return e(t,{class:v([this.disabled?"vega-input-select-disabled":"",u.formatCustom(this.size)])},this.renderLabel(),this.dropdownRenderer.render(),this.renderErrorMessage(),this.hint&&this.renderHelpMessage())}renderLabel(){return this.label&&e("vega-field-label",{"is-field-required":this.required,disabled:this.disabled,label:this.label,suffixButtonConfig:this.labelSuffixButtonConfig,ref:e=>{f.addUniqueObserverToNode(e,m,this.handleLabelButtonClick)}})}}ee([l()],te.prototype,"disabled",void 0),ee([l()],te.prototype,"size",void 0),ee([l()],te.prototype,"hint",void 0),ee([l()],te.prototype,"label",void 0),ee([l()],te.prototype,"required",void 0),ee([l()],te.prototype,"labelSuffixButtonConfig",void 0),ee([l()],te.prototype,"labelButtonClickEventEmitter",void 0),ee([l({componentFieldName:"vegaInputSelectDropdownRenderer"})],te.prototype,"dropdownRenderer",void 0);var ie=function(e,t,i,s){var o,r=arguments.length,n=r<3?t:null===s?s=Object.getOwnPropertyDescriptor(t,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(e,t,i,s);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(n=(r<3?o(n):r>3?o(t,i,n):o(t,i))||n);return r>3&&n&&Object.defineProperty(t,i,n),n};class se extends p{constructor(){super(...arguments),this.onDropdownShow=()=>{this.isDropdownShow=!0},this.onDropdownHide=()=>{this.isDropdownShow=!1}}addDropdownObserver(e){f.addUniqueObserverToNode(e,x,(e=>{this.onDropdownShow(),this.showEventEmitter.emit(e.detail)})),f.addUniqueObserverToNode(e,b,(e=>{this.onDropdownHide(),this.hideEventEmitter.emit(e.detail)})),f.addUniqueObserverToNode(e,w,(async e=>{this.vegaInputSelectValueController.setValue(await e.host.getSelection())})),f.addUniqueObserverToNode(e,y,(e=>{this.searchEventEmitter.emit(e.detail)})),f.addUniqueObserverToNode(e,j,(e=>{this.searchTriggerEventEmitter.emit(e.detail)})),f.addUniqueObserverToNode(e,E,(e=>{const t=Array.from(e).filter((e=>!this.source.find((t=>t.id===e.itemKey)))).map((e=>({id:e.itemKey,displayName:e.label})));this.sourceController.appendSourceItems(t)})),f.addUniqueObserverToNode(e,I,(async()=>{this.vegaInputSelectValueController.setValue("multiple"===this.selectType?[]:"")}))}}ie([l({writable:!0})],se.prototype,"isDropdownShow",void 0),ie([l()],se.prototype,"vegaSearch",void 0),ie([l()],se.prototype,"searchEventEmitter",void 0),ie([l()],se.prototype,"searchTriggerEventEmitter",void 0),ie([l()],se.prototype,"vegaInputSelectValueController",void 0),ie([l()],se.prototype,"sourceController",void 0),ie([l()],se.prototype,"source",void 0),ie([l()],se.prototype,"showEventEmitter",void 0),ie([l()],se.prototype,"hideEventEmitter",void 0),ie([l()],se.prototype,"selectType",void 0);var oe=function(e,t,i,s){var o,r=arguments.length,n=r<3?t:null===s?s=Object.getOwnPropertyDescriptor(t,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(e,t,i,s);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(n=(r<3?o(n):r>3?o(t,i,n):o(t,i))||n);return r>3&&n&&Object.defineProperty(t,i,n),n};class re extends p{constructor(){super(...arguments),this.handleValueChange=(e,t)=>{if("multiple"===this.selectType){let i;t=t,i=(e=e)?this.vegaDropdownProps.preserveValueIfNotInSource?e:e.filter((e=>this.sourceController.getItem(e))):[],z(i,t,!0)?z(i,e,!0)||this.setValue(i):(this.setValue(i),this.changeEventEmitter.emit(i),k.notify(P,{host:this.host,detail:i}))}else if(e!==t){const t=this.sourceController.getItem(e);this.setValue(this.vegaDropdownProps.preserveValueIfNotInSource?e:t?t.id:""),this.changeEventEmitter.emit(this.value),k.notify(P,{host:this.host,detail:this.value})}}}setValue(e){this.valueGuard(e)&&(this.value=e,this.vegaInputSelectItemController.setSelectedItem())}valueGuard(e){switch(this.selectType){case"single":return null===e||"string"==typeof e;case"multiple":return Array.isArray(e)&&e.every((e=>"string"==typeof e));default:return h.warn(`Invalid input select value ${e} for ${this.selectType} mode`),!1}}}oe([l({writable:!0})],re.prototype,"value",void 0),oe([l()],re.prototype,"selectType",void 0),oe([l()],re.prototype,"changeEventEmitter",void 0),oe([l()],re.prototype,"host",void 0),oe([l()],re.prototype,"sourceController",void 0),oe([l()],re.prototype,"vegaInputSelectItemController",void 0),oe([l()],re.prototype,"vegaDropdownProps",void 0),oe([d("watchValue")],re.prototype,"handleValueChange",void 0);var ne=function(e,t,i,s){var o,r=arguments.length,n=r<3?t:null===s?s=Object.getOwnPropertyDescriptor(t,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(e,t,i,s);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(n=(r<3?o(n):r>3?o(t,i,n):o(t,i))||n);return r>3&&n&&Object.defineProperty(t,i,n),n};class ae extends p{componentWillLoad(){this.setSelectedItem()}watchSelectType(){"multiple"===this.selectType?(this.selectedItem=[],this.vegaInputSelectValueController.setValue([])):(this.selectedItem=null,this.vegaInputSelectValueController.setValue(""))}setSelectedItem(){var e;if("multiple"===this.selectType){const e=this.value.map((e=>this.sourceController.getItem(e))),t=this.selectedItem?this.selectedItem.filter((e=>this.value.includes(null==e?void 0:e.id))):[];this.selectedItem=this.updateSelectedItemUnderMultiple(t,e)}else{const t=this.sourceController.getItem(this.value);this.value&&this.value===(null===(e=this.selectedItem)||void 0===e?void 0:e.id)||(this.selectedItem=null),t&&(this.selectedItem=t)}}updateSelectedItemUnderMultiple(e,t){const i=new Map(e.map((e=>[e.id,e])));return t.forEach((e=>{i.set(null==e?void 0:e.id,e)})),Array.from(i.values())}}ne([l()],ae.prototype,"value",void 0),ne([l()],ae.prototype,"selectType",void 0),ne([l({writable:!0})],ae.prototype,"selectedItem",void 0),ne([l()],ae.prototype,"sourceController",void 0),ne([l()],ae.prototype,"vegaInputSelectValueController",void 0),ne([d("componentWillLoad")],ae.prototype,"componentWillLoad",null),ne([d("watchSelectType")],ae.prototype,"watchSelectType",null);var le=function(e,t,i,s){var o,r=arguments.length,n=r<3?t:null===s?s=Object.getOwnPropertyDescriptor(t,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(e,t,i,s);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(n=(r<3?o(n):r>3?o(t,i,n):o(t,i))||n);return r>3&&n&&Object.defineProperty(t,i,n),n};class pe extends p{constructor(){super(...arguments),this.renderContainer=()=>e("div",{role:"button",class:"vega-input-select-container",ref:e=>this.inputSelectContainer=e,tabIndex:0,"aria-disabled":`${this.disabled}`,onKeyDown:A(),onBlur:this.preventBlur,part:"select-container"},this.renderPrefixIcon(),this.renderSelectContainer(),this.renderToggleIcon()),this.renderPrefixIcon=()=>this.vegaInputSelectPrefixIconRenderer.render(),this.renderToggleIcon=()=>e("div",{class:"vega-input-select-toggle-icon",part:"toggle-icon-container"},e("vega-icon",{part:"toggle-icon",icon:B.getIconKey(this.isDropdownShow?"chevron-up":"chevron-down")})),this.renderSelectContainer=()=>{var t,i;return"function"!=typeof this.selectedLabel&&((null===(t=this.selectedLabel)||void 0===t?void 0:t.single)||(this.selectedLabel.single=(e,t)=>t.displayName),(null===(i=this.selectedLabel)||void 0===i?void 0:i.multiple)||(this.selectedLabel.multiple=e=>`${e.length} Selected`)),e("div",{class:"vega-input-select-select-container"},e("div",{class:"vega-input-select-selected-box"},"multiple"===this.selectType?this.renderMultipleSelected():this.renderSingleSelected()))},this.renderMultipleSelected=()=>{if(this.value.length>0){const t="function"==typeof this.selectedLabel?this.selectedLabel(this.value):this.selectedLabel.multiple(this.value,this.selectedItem);return e("span",{class:"vega-input-select-selected"},e("vega-text",{overflow:"ellipsis",tooltip:this.getSelectedLabelTooltipProps(),key:t},t))}return e("div",{class:"vega-input-select-placeholder"},this.translationSlimmer.t(this.placeholder))},this.renderSingleSelected=()=>{var t,i;const s=this.selectedItem;(null==s?void 0:s.displayName)&&(s.displayName=F.sanitize(s.displayName,M));const o=null===(i=(t=this.selectedLabel).single)||void 0===i?void 0:i.call(t,this.value,s);return"function"==typeof this.selectedLabel&&this.selectedItem||"function"!=typeof this.selectedLabel&&o?e("span",{class:"vega-input-select-selected",part:"selected-box"},"function"==typeof this.selectedLabel?e("vega-text",{overflow:"ellipsis",tooltip:this.getSelectedLabelTooltipProps(),key:s.displayName},s.displayName):e("vega-text",{overflow:"ellipsis",tooltip:this.getSelectedLabelTooltipProps(),key:o},o)):e("div",{class:"vega-input-select-placeholder",part:"placeholder"},this.translationSlimmer.t(this.placeholder))},this.getVegaDropdownProperties=()=>{const e=Object.assign({searchable:!0,caseSensitive:!1},this.vegaDropdownProps);return this.dropdownItemTooltipProps&&Object.keys(this.dropdownItemTooltipProps).length>0&&(e.itemTooltipProps=this.dropdownItemTooltipProps),e},this.getSelectedLabelTooltipProps=()=>Object.assign({placement:"bottom"},this.selectedLabelTooltipProps)}watchVegaDropdownProps(){this.vegaDropdownProps&&void 0!==this.vegaDropdownProps.preserveValueIfNotInSource&&(this.dropdown.preserveValueIfNotInSource=this.vegaDropdownProps.preserveValueIfNotInSource,this.dropdown.selectedSourceKey=this.value)}show(){return this.dropdown.show()}hide(){return this.dropdown.hide()}getDropdownRef(){return this.dropdown}getInputSelectContainerRef(){return this.inputSelectContainer}getItemsSlotRef(){return this.itemsSlotRef}render(){return e("vega-dropdown",Object.assign({trigger:"click",source:this.getDropdownSource(),selectType:this.selectType,selectedSourceKey:this.value,matchTargetWidth:!0},this.getVegaDropdownProperties(),{ref:e=>{this.dropdown=e,this.vegaInputSelectDropdownController.addDropdownObserver(e)},isLazyLoading:this.isLazyLoading}),this.renderContainer(),this.renderItemsSlot())}renderItemsSlot(){return this.host.querySelector("[slot=items]")&&e("div",{slot:"items",ref:e=>{this.itemsSlotRef=e}})}preventBlur(e){e.stopImmediatePropagation()}getDropdownSource(){return this.source.map((e=>({key:e.id,label:e.displayName})))}}B.register({"chevron-up":_,"chevron-down":N}),le([l()],pe.prototype,"value",void 0),le([l()],pe.prototype,"source",void 0),le([l()],pe.prototype,"host",void 0),le([l()],pe.prototype,"selectType",void 0),le([l()],pe.prototype,"isDropdownShow",void 0),le([l()],pe.prototype,"vegaDropdownProps",void 0),le([l()],pe.prototype,"placeholder",void 0),le([l()],pe.prototype,"selectedLabel",void 0),le([l()],pe.prototype,"isLazyLoading",void 0),le([l()],pe.prototype,"vegaInputSelectDropdownController",void 0),le([l()],pe.prototype,"vegaInputSelectPrefixIconRenderer",void 0),le([l()],pe.prototype,"translationSlimmer",void 0),le([l()],pe.prototype,"disabled",void 0),le([l()],pe.prototype,"selectedItem",void 0),le([l()],pe.prototype,"selectedLabelTooltipProps",void 0),le([l()],pe.prototype,"dropdownItemTooltipProps",void 0),le([d("watchVegaDropdownProps")],pe.prototype,"watchVegaDropdownProps",null);var de=function(e,t,i,s){var o,r=arguments.length,n=r<3?t:null===s?s=Object.getOwnPropertyDescriptor(t,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(e,t,i,s);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(n=(r<3?o(n):r>3?o(t,i,n):o(t,i))||n);return r>3&&n&&Object.defineProperty(t,i,n),n};class he extends p{constructor(){super(...arguments),this.hasMore=!0}componentDidLoad(){const e=this.getVirtualScroll();e&&f.addUniqueObserverToNode(e,L,this.onScrollToBottom.bind(this))}getVirtualScroll(){var e,t,i;return null===(i=null===(t=null===(e=this.vegaInputSelectDropdownRenderer.getDropdownRef().shadowRoot)||void 0===e?void 0:e.querySelector("vega-dropdown-content-box"))||void 0===t?void 0:t.shadowRoot)||void 0===i?void 0:i.querySelector("vega-virtual-scroll")}async onScrollToBottom(e){if(this.sourceLazyLoadCallback&&this.hasMore){this.isLazyLoading=!0;const t=await this.sourceLazyLoadCallback(e.endIndex);this.hasMore=t.hasMore,t.items.length>0&&this.sourceController.appendSourceItems(t.items),this.isLazyLoading=!1}}}de([l()],he.prototype,"sourceLazyLoadCallback",void 0),de([l({writable:!0})],he.prototype,"isLazyLoading",void 0),de([l()],he.prototype,"sourceController",void 0),de([l()],he.prototype,"vegaInputSelectDropdownRenderer",void 0),de([d("componentDidLoad")],he.prototype,"componentDidLoad",null);const ce=[{payloadKey:"AUTO_VALIDATION_IS_TRUE",payloadDescription:"Specifies whether the system should automatically carry out validation checks on the user's selection in real-time, ensuring that the input adheres to predefined criteria before submission or proceeding further",payloadValue:e=>!0===e.autoValidation},{payloadKey:"AUTO_VALIDATION_IS_FALSE",payloadDescription:"Specifies whether the system should automatically carry out validation checks on the user's selection in real-time, ensuring that the input adheres to predefined criteria before submission or proceeding further",payloadValue:e=>!1===e.autoValidation},{payloadKey:"IS_USING_TEMPLATE",payloadDescription:"Contains the data records to be rendered and displayed within the input select",payloadValue:e=>0===e.source.length},{payloadKey:"IS_USING_DATA_SOURCE",payloadDescription:"Contains the data records to be rendered and displayed within the input select",payloadValue:e=>e.source.length>0}];var ve=function(e,t,i,s){var o,r=arguments.length,n=r<3?t:null===s?s=Object.getOwnPropertyDescriptor(t,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(e,t,i,s);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(n=(r<3?o(n):r>3?o(t,i,n):o(t,i))||n);return r>3&&n&&Object.defineProperty(t,i,n),n};class ue extends p{constructor(){super(...arguments),this.handleSourceChange=()=>{this.host.dataset.source=JSON.stringify(this.source),this.source=$(this.source,q)?this.source:[],this.vegaInputSelectItemController.setSelectedItem()}}appendSourceItems(e){this.source=[...this.source,...e]}getItem(e){return this.source.find((t=>t.id===e))}}ve([l()],ue.prototype,"host",void 0),ve([l({writable:!0})],ue.prototype,"source",void 0),ve([l()],ue.prototype,"vegaInputSelectItemController",void 0),ve([d("watchSource")],ue.prototype,"handleSourceChange",void 0);var fe=function(e,t,i,s){var o,r=arguments.length,n=r<3?t:null===s?s=Object.getOwnPropertyDescriptor(t,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(e,t,i,s);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(n=(r<3?o(n):r>3?o(t,i,n):o(t,i))||n);return r>3&&n&&Object.defineProperty(t,i,n),n};class ge extends p{constructor(){super(...arguments),this.mutationObserver=new H({mutationFilter:J("VEGA-DROPDOWN-ITEM"),options:{childList:!0,subtree:!0},callback:()=>this.appendHostItemsToDropdown()})}componentDidLoad(){this.appendHostItemsToDropdown()}appendHostItemsToDropdown(){const e=this.host.querySelector("[slot=items]"),t=this.vegaInputSelectDropdownRenderer.getItemsSlotRef();e&&t&&(t.remove(),this.vegaInputSelectDropdownRenderer.getDropdownRef().append(e))}}fe([c()],ge.prototype,"mutationObserver",void 0),fe([l()],ge.prototype,"host",void 0),fe([l()],ge.prototype,"vegaInputSelectDropdownRenderer",void 0),fe([d("componentDidLoad")],ge.prototype,"componentDidLoad",null);var me=function(e,t,i,s){var o,r=arguments.length,n=r<3?t:null===s?s=Object.getOwnPropertyDescriptor(t,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(e,t,i,s);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(n=(r<3?o(n):r>3?o(t,i,n):o(t,i))||n);return r>3&&n&&Object.defineProperty(t,i,n),n};class xe extends p{connectedCallback(){this.remotePhoneNumberPrefixIconRenderSubject=g.getSubjectFromParentNodeByEventId(this.host,V)}callRemotePrefixIconRender(...e){if(this.remotePhoneNumberPrefixIconRenderSubject){const t=Q.call(this.remotePhoneNumberPrefixIconRenderSubject,...e);if(t)return t}return null}render(){const t=this.callRemotePrefixIconRender(this.prefixIcon);return this.prefixIcon&&e("div",{class:"vega-input-select-prefix-icon"},t||e("vega-icon",{icon:this.prefixIcon,size:"size-16"}))}}me([l()],xe.prototype,"host",void 0),me([l()],xe.prototype,"prefixIcon",void 0),me([d("connectedCallback")],xe.prototype,"connectedCallback",null);class be extends X{constructor(e){super(),this.inputSelectSourceGetter=e,this.invalidResult=e=>({isValid:!1,message:e}),this.validResult=()=>({isValid:!0,message:""})}canEvaluate(e,t){return t?this.isAcceptedInputType(e)&&!t.disabled&&t.visible:this.isAcceptedInputType(e)}evaluate(e){return"string"!=typeof e||this.inputSelectSourceGetter().find((t=>t.id===e))?Array.isArray(e)&&!e.every((e=>this.inputSelectSourceGetter().find((t=>t.id===e))))?this.invalidResult("There are values that do not exist in the source"):this.validResult():this.invalidResult("The value does not exist in the source")}shouldShowError(e){return!e.disabled&&e.visible&&(e.touched||e.modified)}isAcceptedInputType(e){return("string"==typeof e||Array.isArray(e)&&e.every((e=>"string"==typeof e)))&&e.length>0}}var we=function(e,t,i,s){var o,r=arguments.length,n=r<3?t:null===s?s=Object.getOwnPropertyDescriptor(t,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(e,t,i,s);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(n=(r<3?o(n):r>3?o(t,i,n):o(t,i))||n);return r>3&&n&&Object.defineProperty(t,i,n),n};const ye=class{constructor(e){i(this,e),this.vegaChange=s(this,"vegaChange",7),this.change=s(this,"change",7),this.vegaSearch=s(this,"vegaSearch",7),this.search=s(this,"search",7),this.vegaSearchTrigger=s(this,"vegaSearchTrigger",7),this.searchTrigger=s(this,"searchTrigger",7),this.vegaShow=s(this,"vegaShow",7),this.vegaHide=s(this,"vegaHide",7),this.vegaLabelButtonClick=s(this,"vegaLabelButtonClick",7),this.labelButtonClick=s(this,"labelButtonClick",7),this.globalSlimmers={},this.translationSlimmer=new Z,this.sourceController=new ue,this.vegaInputSelectRenderer=new te,this.vegaInputSelectPrefixIconRenderer=new xe,this.vegaInputSelectDropdownController=new se,this.vegaInputSelectValueController=new re,this.vegaInputSelectDropdownRenderer=new pe,this.vegaInputSelectItemsSlotController=new ge,this.vegaInputSelectItemController=new ae,this.formFieldControllerSlimmer=new U({propertyRules:[{propertyName:"required",ruleFactory:e=>e?new r:null},{propertyName:"data-source",ruleFactory:()=>new be((()=>this.source))}],validationRulesName:"validationRules",defaultValue:e=>"multiple"===e.selectType?[]:"",attributeGetter:e=>this[e],inputContainerGetter:()=>this.vegaInputSelectDropdownRenderer.getDropdownRef(),touchableAreaGetter:()=>[this.vegaInputSelectDropdownRenderer.getInputSelectContainerRef()]}),this.pageResizeObserverSlimmer=new G,this.lazyLoadController=new he,this.changeEventEmitter=K(ye,S),this.searchEventEmitter=K(ye,R),this.searchTriggerEventEmitter=K(ye,j),this.showEventEmitter=K(ye,T),this.hideEventEmitter=K(ye,C),this.labelButtonClickEventEmitter=K(ye,m),this.eventPrevent=new W([R,j,T,C],(()=>this.host),!0),this.vegaComponentUsageRuntimeMetricsSlimmer=new D(ce),this.isDropdownShow=!1,this.currentBreakpoint=a(),this.isLazyLoading=!1,this.label="",this.labelSuffixButtonConfig=null,this.required=!1,this.selectedLabel=e=>Y.t("{0} Selected",e.length),this.selectType="single",this.source=[],this.value="multiple"===this.selectType?[]:"",this.isValid=null,this.autoValidation=!0,this.validationRules=[],this.disabled=!1,this.placeholder="Please select",this.vegaDropdownProps={},this.selectedLabelTooltipProps={},this.dropdownItemTooltipProps={},this.size="default"}watchSelectType(){}watchSource(){}watchValue(e,t){}watchValidationRules(){}watchVegaDropdownProps(){}watchSelectedLabelTooltipProps(){}watchDropdownItemTooltipProps(){}componentWillLoad(){}async doClose(){await this.vegaInputSelectDropdownRenderer.hide()}async doOpen(){await this.vegaInputSelectDropdownRenderer.show()}async doChange(e){this.vegaInputSelectValueController.setValue(e)}render(){return n(this.vegaInputSelectRenderer.render(),this.host)}get host(){return o(this)}static get watchers(){return{selectType:["watchSelectType"],source:["watchSource"],value:["watchValue"],validationRules:["watchValidationRules"],vegaDropdownProps:["watchVegaDropdownProps"],selectedLabelTooltipProps:["watchSelectedLabelTooltipProps"],dropdownItemTooltipProps:["watchDropdownItemTooltipProps"]}}};we([O()],ye.prototype,"globalSlimmers",void 0),we([c()],ye.prototype,"translationSlimmer",void 0),we([c()],ye.prototype,"sourceController",void 0),we([c()],ye.prototype,"vegaInputSelectRenderer",void 0),we([c()],ye.prototype,"vegaInputSelectPrefixIconRenderer",void 0),we([c()],ye.prototype,"vegaInputSelectDropdownController",void 0),we([c()],ye.prototype,"vegaInputSelectValueController",void 0),we([c()],ye.prototype,"vegaInputSelectDropdownRenderer",void 0),we([c()],ye.prototype,"vegaInputSelectItemsSlotController",void 0),we([c()],ye.prototype,"vegaInputSelectItemController",void 0),we([c()],ye.prototype,"formFieldControllerSlimmer",void 0),we([c()],ye.prototype,"pageResizeObserverSlimmer",void 0),we([c()],ye.prototype,"lazyLoadController",void 0),we([c()],ye.prototype,"changeEventEmitter",void 0),we([c()],ye.prototype,"searchEventEmitter",void 0),we([c()],ye.prototype,"searchTriggerEventEmitter",void 0),we([c()],ye.prototype,"showEventEmitter",void 0),we([c()],ye.prototype,"hideEventEmitter",void 0),we([c()],ye.prototype,"labelButtonClickEventEmitter",void 0),we([c()],ye.prototype,"eventPrevent",void 0),we([c()],ye.prototype,"vegaComponentUsageRuntimeMetricsSlimmer",void 0),ye.style=':host{display:inline-block;width:100%;min-width:0px;text-align:left;line-height:normal}:host(.default) .vega-input-select-container{padding-left:16px;padding-right:16px;padding-top:12px;padding-bottom:12px}:host(.small) .vega-input-select-container{padding-left:12px;padding-right:12px;padding-top:8px;padding-bottom:8px}vega-field-label{margin-bottom:8px}:host .vega-input-select-container{border:1px solid rgba(var(--v-border-input-field, 171, 198, 216, 1));background-color:rgba(var(--v-bg-primary, 252, 252, 252, 1));border-radius:8px;gap:8px;display:block;display:flex;align-items:center;cursor:pointer}:host .vega-input-select-container:hover{border:1px solid rgba(var(--v-border-input-field-hover, 115, 160, 190, 1))}:host .vega-input-select-container:focus{outline:2px solid rgba(var(--v-border-color-action, 19, 98, 226, 1));outline-offset:3px;border:1px solid rgba(var(--v-border-color-input-field-focus, 19, 98, 226, 1))}:host .error .vega-input-select-container{border:1px solid rgba(var(--v-border-input-field-danger, 230, 50, 87, 1))}:host .error .vega-input-select-container:hover{border:1px solid rgba(var(--v-border-input-field-danger-hover, 255, 87, 114, 1))}:host .error .vega-input-select-container:focus{outline:2px solid rgba(var(--v-border-color-danger, 230, 50, 87, 1));outline-offset:3px;border:1px solid rgba(var(--v-border-color-input-field-danger-focus, 233, 71, 104, 1))}:host(.vega-input-select-disabled) vega-dropdown{pointer-events:none}:host(.vega-input-select-disabled) .vega-input-select-container{border:1px solid rgba(var(--v-border-input-field-disabled, 222, 225, 227, 1));background-color:rgba(var(--v-bg-secondary, 245, 247, 247, 1));--tw-shadow:0 0 #0000;box-shadow:rgba(0, 0, 0, 0) 0px 0px 0px 0px, rgba(0, 0, 0, 0) 0px 0px 0px 0px, rgba(0, 0, 0, 0) 0px 0px 0px 0px}:host(.vega-input-select-disabled) .vega-input-select-container:hover{border:1px solid rgba(var(--v-border-input-field-disabled, 222, 225, 227, 1))}:host(.vega-input-select-disabled) vega-icon{color:rgba(var(--v-text-disabled, 176, 180, 181, 1))}:host .vega-input-select-select-container{flex-grow:1;min-width:0px}:host .vega-input-select-selected{font-family:"Inter", sans-serif;font-size:16px;font-weight:400;line-height:24px;letter-spacing:0px;color:rgba(var(--v-text-primary, 32, 54, 69, 1));display:block;min-height:24px}@media screen and (min-width: 768px) and (max-width: 1023px){:host .vega-input-select-selected{font-family:"Inter", sans-serif;font-size:16px;font-weight:400;line-height:24px;letter-spacing:0px}}@media screen and (min-width: 1024px) and (max-width: 1439px){:host .vega-input-select-selected{font-family:"Inter", sans-serif;font-size:16px;font-weight:400;line-height:24px;letter-spacing:0px}}@media screen and (min-width: 1440px) and (max-width: 9999px){:host .vega-input-select-selected{font-family:"Inter", sans-serif;font-size:16px;font-weight:400;line-height:24px;letter-spacing:0px}}:host(.vega-input-select-disabled) .vega-input-select-selected{color:rgba(var(--v-text-input-disabled, 107, 116, 125, 1))}:host .vega-input-select-placeholder{font-family:"Inter", sans-serif;font-size:16px;font-weight:400;line-height:24px;letter-spacing:0px;color:rgba(var(--v-text-input-placeholder, 176, 180, 181, 1));overflow:hidden;text-overflow:ellipsis;white-space:nowrap;min-height:24px}@media screen and (min-width: 768px) and (max-width: 1023px){:host .vega-input-select-placeholder{font-family:"Inter", sans-serif;font-size:16px;font-weight:400;line-height:24px;letter-spacing:0px}}@media screen and (min-width: 1024px) and (max-width: 1439px){:host .vega-input-select-placeholder{font-family:"Inter", sans-serif;font-size:16px;font-weight:400;line-height:24px;letter-spacing:0px}}@media screen and (min-width: 1440px) and (max-width: 9999px){:host .vega-input-select-placeholder{font-family:"Inter", sans-serif;font-size:16px;font-weight:400;line-height:24px;letter-spacing:0px}}:host .vega-input-select-prefix-icon{text-align:center;color:rgba(var(--v-text-secondary, 107, 116, 125, 1));font-size:0px}:host .vega-input-select-toggle-icon{width:16px;height:16px;color:rgba(var(--v-text-link, 19, 98, 226, 1))}:host .vega-error{display:inline-block;padding-left:8px;padding-right:8px;padding-top:12px;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}:host .vega-input-select-hint{padding-left:8px;padding-right:8px;padding-top:12px;font-family:"Inter", sans-serif;font-size:14px;font-weight:400;line-height:18px;letter-spacing:0px;color:rgba(var(--v-text-secondary, 107, 116, 125, 1))}@media screen and (min-width: 768px) and (max-width: 1023px){:host .vega-input-select-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-input-select-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-input-select-hint{font-family:"Inter", sans-serif;font-size:14px;font-weight:400;line-height:18px;letter-spacing:0px}}:host vega-dropdown{display:block}';export{ye as vega_input_select}
|
|
1
|
+
import{h as e,H as t,r as i,c as s,g as o}from"./p-6b2342e0.js";import{R as r}from"./p-280cbcdb.js";import{s as n}from"./p-519a7d55.js";import{g as a}from"./p-49a2e141.js";import{c as l,V as p,M as d,L as h,I as c}from"./p-6e1ab235.js";import{a as v}from"./p-ec2a1d4c.js";import{R as u}from"./p-b02b985d.js";import{D as f,d as g}from"./p-11e2dcf5.js";import{y as m,v as x,w as b,V as w,f as y,x as j,e as I,i as S,r as R,N as T,O as C}from"./p-2927b7a1.js";import{V as D,I as O}from"./p-8ce9e214.js";import{l as E,m as L,n as V}from"./p-3a93730e.js";import{i as z}from"./p-d27ae9ff.js";import{C as k}from"./p-2d0d575f.js";import{F as P}from"./p-a528714c.js";import{c as A}from"./p-3a620268.js";import{c as _}from"./p-1ec763ab.js";import{c as N}from"./p-613ddaab.js";import{V as B}from"./p-724df1f5.js";import{h as F,l as U}from"./p-f0e828d8.js";import{F as G}from"./p-2d694684.js";import{P as M}from"./p-81dd00d0.js";import{c as K}from"./p-04a65b3f.js";import{C as W}from"./p-ab04eff6.js";import{Z as $,$ as q}from"./p-78ba7ca9.js";import{M as H}from"./p-78a57a17.js";import{T as J}from"./p-52b8f2d2.js";import{T as Z}from"./p-a6565e02.js";import{r as Q}from"./p-77e64f26.js";import{I as X}from"./p-abd7aeaa.js";import{V as Y}from"./p-0a261b66.js";import"./p-d4ea8e22.js";import"./p-ed45b3b6.js";import"./p-262ec334.js";import"./p-0c667d6a.js";import"./p-dcf162e9.js";import"./p-982747ef.js";import"./p-331a62d5.js";import"./p-1704ff25.js";import"./p-9a6bd32c.js";import"./p-6a334573.js";import"./p-8b5d3a52.js";import"./p-b75ee3ba.js";import"./p-02841589.js";import"./p-10fa27d2.js";import"./p-4dd02704.js";import"./p-5f377954.js";import"./p-d884c644.js";var ee=function(e,t,i,s){var o,r=arguments.length,n=r<3?t:null===s?s=Object.getOwnPropertyDescriptor(t,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(e,t,i,s);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(n=(r<3?o(n):r>3?o(t,i,n):o(t,i))||n);return r>3&&n&&Object.defineProperty(t,i,n),n};class te extends p{constructor(){super(...arguments),this.renderErrorMessage=()=>e("div",{class:"vega-input-select-error-message"}),this.renderHelpMessage=()=>e("div",{class:"vega-input-select-hint"},this.hint),this.handleLabelButtonClick=()=>{this.labelButtonClickEventEmitter.emit()}}render(){return e(t,{class:v([this.disabled?"vega-input-select-disabled":"",u.formatCustom(this.size)])},this.renderLabel(),this.dropdownRenderer.render(),this.renderErrorMessage(),this.hint&&this.renderHelpMessage())}renderLabel(){return this.label&&e("vega-field-label",{"is-field-required":this.required,disabled:this.disabled,label:this.label,suffixButtonConfig:this.labelSuffixButtonConfig,ref:e=>{f.addUniqueObserverToNode(e,m,this.handleLabelButtonClick)}})}}ee([l()],te.prototype,"disabled",void 0),ee([l()],te.prototype,"size",void 0),ee([l()],te.prototype,"hint",void 0),ee([l()],te.prototype,"label",void 0),ee([l()],te.prototype,"required",void 0),ee([l()],te.prototype,"labelSuffixButtonConfig",void 0),ee([l()],te.prototype,"labelButtonClickEventEmitter",void 0),ee([l({componentFieldName:"vegaInputSelectDropdownRenderer"})],te.prototype,"dropdownRenderer",void 0);var ie=function(e,t,i,s){var o,r=arguments.length,n=r<3?t:null===s?s=Object.getOwnPropertyDescriptor(t,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(e,t,i,s);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(n=(r<3?o(n):r>3?o(t,i,n):o(t,i))||n);return r>3&&n&&Object.defineProperty(t,i,n),n};class se extends p{constructor(){super(...arguments),this.onDropdownShow=()=>{this.isDropdownShow=!0},this.onDropdownHide=()=>{this.isDropdownShow=!1}}addDropdownObserver(e){f.addUniqueObserverToNode(e,x,(e=>{this.onDropdownShow(),this.showEventEmitter.emit(e.detail)})),f.addUniqueObserverToNode(e,b,(e=>{this.onDropdownHide(),this.hideEventEmitter.emit(e.detail)})),f.addUniqueObserverToNode(e,w,(async e=>{this.vegaInputSelectValueController.setValue(await e.host.getSelection())})),f.addUniqueObserverToNode(e,y,(e=>{this.searchEventEmitter.emit(e.detail)})),f.addUniqueObserverToNode(e,j,(e=>{this.searchTriggerEventEmitter.emit(e.detail)})),f.addUniqueObserverToNode(e,E,(e=>{const t=Array.from(e).filter((e=>!this.source.find((t=>t.id===e.itemKey)))).map((e=>({id:e.itemKey,displayName:e.label})));this.sourceController.appendSourceItems(t)})),f.addUniqueObserverToNode(e,I,(async()=>{this.vegaInputSelectValueController.setValue("multiple"===this.selectType?[]:"")}))}}ie([l({writable:!0})],se.prototype,"isDropdownShow",void 0),ie([l()],se.prototype,"vegaSearch",void 0),ie([l()],se.prototype,"searchEventEmitter",void 0),ie([l()],se.prototype,"searchTriggerEventEmitter",void 0),ie([l()],se.prototype,"vegaInputSelectValueController",void 0),ie([l()],se.prototype,"sourceController",void 0),ie([l()],se.prototype,"source",void 0),ie([l()],se.prototype,"showEventEmitter",void 0),ie([l()],se.prototype,"hideEventEmitter",void 0),ie([l()],se.prototype,"selectType",void 0);var oe=function(e,t,i,s){var o,r=arguments.length,n=r<3?t:null===s?s=Object.getOwnPropertyDescriptor(t,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(e,t,i,s);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(n=(r<3?o(n):r>3?o(t,i,n):o(t,i))||n);return r>3&&n&&Object.defineProperty(t,i,n),n};class re extends p{constructor(){super(...arguments),this.handleValueChange=(e,t)=>{if("multiple"===this.selectType){let i;t=t,i=(e=e)?this.vegaDropdownProps.preserveValueIfNotInSource?e:e.filter((e=>this.sourceController.getItem(e))):[],z(i,t,!0)?z(i,e,!0)||this.setValue(i):(this.setValue(i),this.changeEventEmitter.emit(i),k.notify(P,{host:this.host,detail:i}))}else if(e!==t){const t=this.sourceController.getItem(e);this.setValue(this.vegaDropdownProps.preserveValueIfNotInSource?e:t?t.id:""),this.changeEventEmitter.emit(this.value),k.notify(P,{host:this.host,detail:this.value})}}}setValue(e){this.valueGuard(e)&&(this.value=e,this.vegaInputSelectItemController.setSelectedItem())}valueGuard(e){switch(this.selectType){case"single":return null===e||"string"==typeof e;case"multiple":return Array.isArray(e)&&e.every((e=>"string"==typeof e));default:return h.warn(`Invalid input select value ${e} for ${this.selectType} mode`),!1}}}oe([l({writable:!0})],re.prototype,"value",void 0),oe([l()],re.prototype,"selectType",void 0),oe([l()],re.prototype,"changeEventEmitter",void 0),oe([l()],re.prototype,"host",void 0),oe([l()],re.prototype,"sourceController",void 0),oe([l()],re.prototype,"vegaInputSelectItemController",void 0),oe([l()],re.prototype,"vegaDropdownProps",void 0),oe([d("watchValue")],re.prototype,"handleValueChange",void 0);var ne=function(e,t,i,s){var o,r=arguments.length,n=r<3?t:null===s?s=Object.getOwnPropertyDescriptor(t,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(e,t,i,s);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(n=(r<3?o(n):r>3?o(t,i,n):o(t,i))||n);return r>3&&n&&Object.defineProperty(t,i,n),n};class ae extends p{componentWillLoad(){this.setSelectedItem()}watchSelectType(){"multiple"===this.selectType?(this.selectedItem=[],this.vegaInputSelectValueController.setValue([])):(this.selectedItem=null,this.vegaInputSelectValueController.setValue(""))}setSelectedItem(){var e;if("multiple"===this.selectType){const e=this.value.map((e=>this.sourceController.getItem(e))),t=this.selectedItem?this.selectedItem.filter((e=>this.value.includes(null==e?void 0:e.id))):[];this.selectedItem=this.updateSelectedItemUnderMultiple(t,e)}else{const t=this.sourceController.getItem(this.value);this.value&&this.value===(null===(e=this.selectedItem)||void 0===e?void 0:e.id)||(this.selectedItem=null),t&&(this.selectedItem=t)}}updateSelectedItemUnderMultiple(e,t){const i=new Map(e.map((e=>[e.id,e])));return t.forEach((e=>{i.set(null==e?void 0:e.id,e)})),Array.from(i.values())}}ne([l()],ae.prototype,"value",void 0),ne([l()],ae.prototype,"selectType",void 0),ne([l({writable:!0})],ae.prototype,"selectedItem",void 0),ne([l()],ae.prototype,"sourceController",void 0),ne([l()],ae.prototype,"vegaInputSelectValueController",void 0),ne([d("componentWillLoad")],ae.prototype,"componentWillLoad",null),ne([d("watchSelectType")],ae.prototype,"watchSelectType",null);var le=function(e,t,i,s){var o,r=arguments.length,n=r<3?t:null===s?s=Object.getOwnPropertyDescriptor(t,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(e,t,i,s);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(n=(r<3?o(n):r>3?o(t,i,n):o(t,i))||n);return r>3&&n&&Object.defineProperty(t,i,n),n};class pe extends p{constructor(){super(...arguments),this.renderContainer=()=>e("div",{role:"button",class:"vega-input-select-container",ref:e=>this.inputSelectContainer=e,tabIndex:0,"aria-disabled":`${this.disabled}`,onKeyDown:A(),onBlur:this.preventBlur,part:"select-container"},this.renderPrefixIcon(),this.renderSelectContainer(),this.renderToggleIcon()),this.renderPrefixIcon=()=>this.vegaInputSelectPrefixIconRenderer.render(),this.renderToggleIcon=()=>e("div",{class:"vega-input-select-toggle-icon",part:"toggle-icon-container"},e("vega-icon",{part:"toggle-icon",icon:B.getIconKey(this.isDropdownShow?"chevron-up":"chevron-down")})),this.renderSelectContainer=()=>{var t,i;return"function"!=typeof this.selectedLabel&&((null===(t=this.selectedLabel)||void 0===t?void 0:t.single)||(this.selectedLabel.single=(e,t)=>t.displayName),(null===(i=this.selectedLabel)||void 0===i?void 0:i.multiple)||(this.selectedLabel.multiple=e=>`${e.length} Selected`)),e("div",{class:"vega-input-select-select-container"},e("div",{class:"vega-input-select-selected-box"},"multiple"===this.selectType?this.renderMultipleSelected():this.renderSingleSelected()))},this.renderMultipleSelected=()=>{if(this.value.length>0){const t="function"==typeof this.selectedLabel?this.selectedLabel(this.value):this.selectedLabel.multiple(this.value,this.selectedItem);return e("span",{class:"vega-input-select-selected"},e("vega-text",{overflow:"ellipsis",tooltip:this.getSelectedLabelTooltipProps(),key:t},t))}return e("div",{class:"vega-input-select-placeholder"},this.translationSlimmer.t(this.placeholder))},this.renderSingleSelected=()=>{var t,i;const s=this.selectedItem;(null==s?void 0:s.displayName)&&(s.displayName=F.sanitize(s.displayName,U));const o=null===(i=(t=this.selectedLabel).single)||void 0===i?void 0:i.call(t,this.value,s);return"function"==typeof this.selectedLabel&&this.selectedItem||"function"!=typeof this.selectedLabel&&o?e("span",{class:"vega-input-select-selected",part:"selected-box"},"function"==typeof this.selectedLabel?e("vega-text",{overflow:"ellipsis",tooltip:this.getSelectedLabelTooltipProps(),key:s.displayName},s.displayName):e("vega-text",{overflow:"ellipsis",tooltip:this.getSelectedLabelTooltipProps(),key:o},o)):e("div",{class:"vega-input-select-placeholder",part:"placeholder"},this.translationSlimmer.t(this.placeholder))},this.getVegaDropdownProperties=()=>{const e=Object.assign({searchable:!0,caseSensitive:!1},this.vegaDropdownProps);return this.dropdownItemTooltipProps&&Object.keys(this.dropdownItemTooltipProps).length>0&&(e.itemTooltipProps=this.dropdownItemTooltipProps),e},this.getSelectedLabelTooltipProps=()=>Object.assign({placement:"bottom"},this.selectedLabelTooltipProps)}watchVegaDropdownProps(){this.vegaDropdownProps&&void 0!==this.vegaDropdownProps.preserveValueIfNotInSource&&(this.dropdown.preserveValueIfNotInSource=this.vegaDropdownProps.preserveValueIfNotInSource,this.dropdown.selectedSourceKey=this.value)}show(){return this.dropdown.show()}hide(){return this.dropdown.hide()}getDropdownRef(){return this.dropdown}getInputSelectContainerRef(){return this.inputSelectContainer}getItemsSlotRef(){return this.itemsSlotRef}render(){return e("vega-dropdown",Object.assign({trigger:"click",source:this.getDropdownSource(),selectType:this.selectType,selectedSourceKey:this.value,matchTargetWidth:!0},this.getVegaDropdownProperties(),{ref:e=>{this.dropdown=e,this.vegaInputSelectDropdownController.addDropdownObserver(e)},isLazyLoading:this.isLazyLoading}),this.renderContainer(),this.renderItemsSlot())}renderItemsSlot(){return this.host.querySelector("[slot=items]")&&e("div",{slot:"items",ref:e=>{this.itemsSlotRef=e}})}preventBlur(e){e.stopImmediatePropagation()}getDropdownSource(){return this.source.map((e=>({key:e.id,label:e.displayName})))}}B.register({"chevron-up":_,"chevron-down":N}),le([l()],pe.prototype,"value",void 0),le([l()],pe.prototype,"source",void 0),le([l()],pe.prototype,"host",void 0),le([l()],pe.prototype,"selectType",void 0),le([l()],pe.prototype,"isDropdownShow",void 0),le([l()],pe.prototype,"vegaDropdownProps",void 0),le([l()],pe.prototype,"placeholder",void 0),le([l()],pe.prototype,"selectedLabel",void 0),le([l()],pe.prototype,"isLazyLoading",void 0),le([l()],pe.prototype,"vegaInputSelectDropdownController",void 0),le([l()],pe.prototype,"vegaInputSelectPrefixIconRenderer",void 0),le([l()],pe.prototype,"translationSlimmer",void 0),le([l()],pe.prototype,"disabled",void 0),le([l()],pe.prototype,"selectedItem",void 0),le([l()],pe.prototype,"selectedLabelTooltipProps",void 0),le([l()],pe.prototype,"dropdownItemTooltipProps",void 0),le([d("watchVegaDropdownProps")],pe.prototype,"watchVegaDropdownProps",null);var de=function(e,t,i,s){var o,r=arguments.length,n=r<3?t:null===s?s=Object.getOwnPropertyDescriptor(t,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(e,t,i,s);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(n=(r<3?o(n):r>3?o(t,i,n):o(t,i))||n);return r>3&&n&&Object.defineProperty(t,i,n),n};class he extends p{constructor(){super(...arguments),this.hasMore=!0}componentDidLoad(){const e=this.getVirtualScroll();e&&f.addUniqueObserverToNode(e,L,this.onScrollToBottom.bind(this))}getVirtualScroll(){var e,t,i;return null===(i=null===(t=null===(e=this.vegaInputSelectDropdownRenderer.getDropdownRef().shadowRoot)||void 0===e?void 0:e.querySelector("vega-dropdown-content-box"))||void 0===t?void 0:t.shadowRoot)||void 0===i?void 0:i.querySelector("vega-virtual-scroll")}async onScrollToBottom(e){if(this.sourceLazyLoadCallback&&this.hasMore){this.isLazyLoading=!0;const t=await this.sourceLazyLoadCallback(e.endIndex);this.hasMore=t.hasMore,t.items.length>0&&this.sourceController.appendSourceItems(t.items),this.isLazyLoading=!1}}}de([l()],he.prototype,"sourceLazyLoadCallback",void 0),de([l({writable:!0})],he.prototype,"isLazyLoading",void 0),de([l()],he.prototype,"sourceController",void 0),de([l()],he.prototype,"vegaInputSelectDropdownRenderer",void 0),de([d("componentDidLoad")],he.prototype,"componentDidLoad",null);const ce=[{payloadKey:"AUTO_VALIDATION_IS_TRUE",payloadDescription:"Specifies whether the system should automatically carry out validation checks on the user's selection in real-time, ensuring that the input adheres to predefined criteria before submission or proceeding further",payloadValue:e=>!0===e.autoValidation},{payloadKey:"AUTO_VALIDATION_IS_FALSE",payloadDescription:"Specifies whether the system should automatically carry out validation checks on the user's selection in real-time, ensuring that the input adheres to predefined criteria before submission or proceeding further",payloadValue:e=>!1===e.autoValidation},{payloadKey:"IS_USING_TEMPLATE",payloadDescription:"Contains the data records to be rendered and displayed within the input select",payloadValue:e=>0===e.source.length},{payloadKey:"IS_USING_DATA_SOURCE",payloadDescription:"Contains the data records to be rendered and displayed within the input select",payloadValue:e=>e.source.length>0}];var ve=function(e,t,i,s){var o,r=arguments.length,n=r<3?t:null===s?s=Object.getOwnPropertyDescriptor(t,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(e,t,i,s);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(n=(r<3?o(n):r>3?o(t,i,n):o(t,i))||n);return r>3&&n&&Object.defineProperty(t,i,n),n};class ue extends p{constructor(){super(...arguments),this.handleSourceChange=()=>{this.host.dataset.source=JSON.stringify(this.source),this.source=$(this.source,q)?this.source:[],this.vegaInputSelectItemController.setSelectedItem()}}appendSourceItems(e){this.source=[...this.source,...e]}getItem(e){return this.source.find((t=>t.id===e))}}ve([l()],ue.prototype,"host",void 0),ve([l({writable:!0})],ue.prototype,"source",void 0),ve([l()],ue.prototype,"vegaInputSelectItemController",void 0),ve([d("watchSource")],ue.prototype,"handleSourceChange",void 0);var fe=function(e,t,i,s){var o,r=arguments.length,n=r<3?t:null===s?s=Object.getOwnPropertyDescriptor(t,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(e,t,i,s);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(n=(r<3?o(n):r>3?o(t,i,n):o(t,i))||n);return r>3&&n&&Object.defineProperty(t,i,n),n};class ge extends p{constructor(){super(...arguments),this.mutationObserver=new H({mutationFilter:J("VEGA-DROPDOWN-ITEM"),options:{childList:!0,subtree:!0},callback:()=>this.appendHostItemsToDropdown()})}componentDidLoad(){this.appendHostItemsToDropdown()}appendHostItemsToDropdown(){const e=this.host.querySelector("[slot=items]"),t=this.vegaInputSelectDropdownRenderer.getItemsSlotRef();e&&t&&(t.remove(),this.vegaInputSelectDropdownRenderer.getDropdownRef().append(e))}}fe([c()],ge.prototype,"mutationObserver",void 0),fe([l()],ge.prototype,"host",void 0),fe([l()],ge.prototype,"vegaInputSelectDropdownRenderer",void 0),fe([d("componentDidLoad")],ge.prototype,"componentDidLoad",null);var me=function(e,t,i,s){var o,r=arguments.length,n=r<3?t:null===s?s=Object.getOwnPropertyDescriptor(t,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(e,t,i,s);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(n=(r<3?o(n):r>3?o(t,i,n):o(t,i))||n);return r>3&&n&&Object.defineProperty(t,i,n),n};class xe extends p{connectedCallback(){this.remotePhoneNumberPrefixIconRenderSubject=g.getSubjectFromParentNodeByEventId(this.host,V)}callRemotePrefixIconRender(...e){if(this.remotePhoneNumberPrefixIconRenderSubject){const t=Q.call(this.remotePhoneNumberPrefixIconRenderSubject,...e);if(t)return t}return null}render(){const t=this.callRemotePrefixIconRender(this.prefixIcon);return this.prefixIcon&&e("div",{class:"vega-input-select-prefix-icon"},t||e("vega-icon",{icon:this.prefixIcon,size:"size-16"}))}}me([l()],xe.prototype,"host",void 0),me([l()],xe.prototype,"prefixIcon",void 0),me([d("connectedCallback")],xe.prototype,"connectedCallback",null);class be extends X{constructor(e){super(),this.inputSelectSourceGetter=e,this.invalidResult=e=>({isValid:!1,message:e}),this.validResult=()=>({isValid:!0,message:""})}canEvaluate(e,t){return t?this.isAcceptedInputType(e)&&!t.disabled&&t.visible:this.isAcceptedInputType(e)}evaluate(e){return"string"!=typeof e||this.inputSelectSourceGetter().find((t=>t.id===e))?Array.isArray(e)&&!e.every((e=>this.inputSelectSourceGetter().find((t=>t.id===e))))?this.invalidResult("There are values that do not exist in the source"):this.validResult():this.invalidResult("The value does not exist in the source")}shouldShowError(e){return!e.disabled&&e.visible&&(e.touched||e.modified)}isAcceptedInputType(e){return("string"==typeof e||Array.isArray(e)&&e.every((e=>"string"==typeof e)))&&e.length>0}}var we=function(e,t,i,s){var o,r=arguments.length,n=r<3?t:null===s?s=Object.getOwnPropertyDescriptor(t,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(e,t,i,s);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(n=(r<3?o(n):r>3?o(t,i,n):o(t,i))||n);return r>3&&n&&Object.defineProperty(t,i,n),n};const ye=class{constructor(e){i(this,e),this.vegaChange=s(this,"vegaChange",7),this.change=s(this,"change",7),this.vegaSearch=s(this,"vegaSearch",7),this.search=s(this,"search",7),this.vegaSearchTrigger=s(this,"vegaSearchTrigger",7),this.searchTrigger=s(this,"searchTrigger",7),this.vegaShow=s(this,"vegaShow",7),this.vegaHide=s(this,"vegaHide",7),this.vegaLabelButtonClick=s(this,"vegaLabelButtonClick",7),this.labelButtonClick=s(this,"labelButtonClick",7),this.globalSlimmers={},this.translationSlimmer=new Z,this.sourceController=new ue,this.vegaInputSelectRenderer=new te,this.vegaInputSelectPrefixIconRenderer=new xe,this.vegaInputSelectDropdownController=new se,this.vegaInputSelectValueController=new re,this.vegaInputSelectDropdownRenderer=new pe,this.vegaInputSelectItemsSlotController=new ge,this.vegaInputSelectItemController=new ae,this.formFieldControllerSlimmer=new G({propertyRules:[{propertyName:"required",ruleFactory:e=>e?new r:null},{propertyName:"data-source",ruleFactory:()=>new be((()=>this.source))}],validationRulesName:"validationRules",defaultValue:e=>"multiple"===e.selectType?[]:"",attributeGetter:e=>this[e],inputContainerGetter:()=>this.vegaInputSelectDropdownRenderer.getDropdownRef(),touchableAreaGetter:()=>[this.vegaInputSelectDropdownRenderer.getInputSelectContainerRef()]}),this.pageResizeObserverSlimmer=new M,this.lazyLoadController=new he,this.changeEventEmitter=K(ye,S),this.searchEventEmitter=K(ye,R),this.searchTriggerEventEmitter=K(ye,j),this.showEventEmitter=K(ye,T),this.hideEventEmitter=K(ye,C),this.labelButtonClickEventEmitter=K(ye,m),this.eventPrevent=new W([R,j,T,C],(()=>this.host),!0),this.vegaComponentUsageRuntimeMetricsSlimmer=new D(ce),this.isDropdownShow=!1,this.currentBreakpoint=a(),this.isLazyLoading=!1,this.label="",this.labelSuffixButtonConfig=null,this.required=!1,this.selectedLabel=e=>Y.t("{0} Selected",e.length),this.selectType="single",this.source=[],this.value="multiple"===this.selectType?[]:"",this.isValid=null,this.autoValidation=!0,this.validationRules=[],this.disabled=!1,this.placeholder="Please select",this.vegaDropdownProps={},this.selectedLabelTooltipProps={},this.dropdownItemTooltipProps={},this.size="default"}watchSelectType(){}watchSource(){}watchValue(e,t){}watchValidationRules(){}watchVegaDropdownProps(){}watchSelectedLabelTooltipProps(){}watchDropdownItemTooltipProps(){}componentWillLoad(){}async doClose(){await this.vegaInputSelectDropdownRenderer.hide()}async doOpen(){await this.vegaInputSelectDropdownRenderer.show()}async doChange(e){this.vegaInputSelectValueController.setValue(e)}render(){return n(this.vegaInputSelectRenderer.render(),this.host)}get host(){return o(this)}static get watchers(){return{selectType:["watchSelectType"],source:["watchSource"],value:["watchValue"],validationRules:["watchValidationRules"],vegaDropdownProps:["watchVegaDropdownProps"],selectedLabelTooltipProps:["watchSelectedLabelTooltipProps"],dropdownItemTooltipProps:["watchDropdownItemTooltipProps"]}}};we([O()],ye.prototype,"globalSlimmers",void 0),we([c()],ye.prototype,"translationSlimmer",void 0),we([c()],ye.prototype,"sourceController",void 0),we([c()],ye.prototype,"vegaInputSelectRenderer",void 0),we([c()],ye.prototype,"vegaInputSelectPrefixIconRenderer",void 0),we([c()],ye.prototype,"vegaInputSelectDropdownController",void 0),we([c()],ye.prototype,"vegaInputSelectValueController",void 0),we([c()],ye.prototype,"vegaInputSelectDropdownRenderer",void 0),we([c()],ye.prototype,"vegaInputSelectItemsSlotController",void 0),we([c()],ye.prototype,"vegaInputSelectItemController",void 0),we([c()],ye.prototype,"formFieldControllerSlimmer",void 0),we([c()],ye.prototype,"pageResizeObserverSlimmer",void 0),we([c()],ye.prototype,"lazyLoadController",void 0),we([c()],ye.prototype,"changeEventEmitter",void 0),we([c()],ye.prototype,"searchEventEmitter",void 0),we([c()],ye.prototype,"searchTriggerEventEmitter",void 0),we([c()],ye.prototype,"showEventEmitter",void 0),we([c()],ye.prototype,"hideEventEmitter",void 0),we([c()],ye.prototype,"labelButtonClickEventEmitter",void 0),we([c()],ye.prototype,"eventPrevent",void 0),we([c()],ye.prototype,"vegaComponentUsageRuntimeMetricsSlimmer",void 0),ye.style=':host{display:inline-block;width:100%;min-width:0px;text-align:left;line-height:normal}:host(.default) .vega-input-select-container{padding-left:16px;padding-right:16px;padding-top:12px;padding-bottom:12px}:host(.small) .vega-input-select-container{padding-left:12px;padding-right:12px;padding-top:8px;padding-bottom:8px}vega-field-label{margin-bottom:8px}:host .vega-input-select-container{border:1px solid rgba(var(--v-border-input-field, 171, 198, 216, 1));background-color:rgba(var(--v-bg-primary, 252, 252, 252, 1));border-radius:8px;gap:8px;display:block;display:flex;align-items:center;cursor:pointer}:host .vega-input-select-container:hover{border:1px solid rgba(var(--v-border-input-field-hover, 115, 160, 190, 1))}:host .vega-input-select-container:focus{outline:2px solid rgba(var(--v-border-color-action, 19, 98, 226, 1));outline-offset:3px;border:1px solid rgba(var(--v-border-color-input-field-focus, 19, 98, 226, 1))}:host .error .vega-input-select-container{border:1px solid rgba(var(--v-border-input-field-danger, 230, 50, 87, 1))}:host .error .vega-input-select-container:hover{border:1px solid rgba(var(--v-border-input-field-danger-hover, 255, 87, 114, 1))}:host .error .vega-input-select-container:focus{outline:2px solid rgba(var(--v-border-color-danger, 230, 50, 87, 1));outline-offset:3px;border:1px solid rgba(var(--v-border-color-input-field-danger-focus, 233, 71, 104, 1))}:host(.vega-input-select-disabled) vega-dropdown{pointer-events:none}:host(.vega-input-select-disabled) .vega-input-select-container{border:1px solid rgba(var(--v-border-input-field-disabled, 222, 225, 227, 1));background-color:rgba(var(--v-bg-secondary, 245, 247, 247, 1));--tw-shadow:0 0 #0000;box-shadow:rgba(0, 0, 0, 0) 0px 0px 0px 0px, rgba(0, 0, 0, 0) 0px 0px 0px 0px, rgba(0, 0, 0, 0) 0px 0px 0px 0px}:host(.vega-input-select-disabled) .vega-input-select-container:hover{border:1px solid rgba(var(--v-border-input-field-disabled, 222, 225, 227, 1))}:host(.vega-input-select-disabled) vega-icon{color:rgba(var(--v-text-disabled, 176, 180, 181, 1))}:host .vega-input-select-select-container{flex-grow:1;min-width:0px}:host .vega-input-select-selected{font-family:"Inter", sans-serif;font-size:16px;font-weight:400;line-height:24px;letter-spacing:0px;color:rgba(var(--v-text-primary, 32, 54, 69, 1));display:block;min-height:24px}@media screen and (min-width: 768px) and (max-width: 1023px){:host .vega-input-select-selected{font-family:"Inter", sans-serif;font-size:16px;font-weight:400;line-height:24px;letter-spacing:0px}}@media screen and (min-width: 1024px) and (max-width: 1439px){:host .vega-input-select-selected{font-family:"Inter", sans-serif;font-size:16px;font-weight:400;line-height:24px;letter-spacing:0px}}@media screen and (min-width: 1440px) and (max-width: 9999px){:host .vega-input-select-selected{font-family:"Inter", sans-serif;font-size:16px;font-weight:400;line-height:24px;letter-spacing:0px}}:host(.vega-input-select-disabled) .vega-input-select-selected{color:rgba(var(--v-text-input-disabled, 107, 116, 125, 1))}:host .vega-input-select-placeholder{font-family:"Inter", sans-serif;font-size:16px;font-weight:400;line-height:24px;letter-spacing:0px;color:rgba(var(--v-text-input-placeholder, 176, 180, 181, 1));overflow:hidden;text-overflow:ellipsis;white-space:nowrap;min-height:24px}@media screen and (min-width: 768px) and (max-width: 1023px){:host .vega-input-select-placeholder{font-family:"Inter", sans-serif;font-size:16px;font-weight:400;line-height:24px;letter-spacing:0px}}@media screen and (min-width: 1024px) and (max-width: 1439px){:host .vega-input-select-placeholder{font-family:"Inter", sans-serif;font-size:16px;font-weight:400;line-height:24px;letter-spacing:0px}}@media screen and (min-width: 1440px) and (max-width: 9999px){:host .vega-input-select-placeholder{font-family:"Inter", sans-serif;font-size:16px;font-weight:400;line-height:24px;letter-spacing:0px}}:host .vega-input-select-prefix-icon{text-align:center;color:rgba(var(--v-text-secondary, 107, 116, 125, 1));font-size:0px}:host .vega-input-select-toggle-icon{width:16px;height:16px;color:rgba(var(--v-text-link, 19, 98, 226, 1))}:host .vega-error{display:inline-block;padding-left:8px;padding-right:8px;padding-top:12px;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}:host .vega-input-select-hint{padding-left:8px;padding-right:8px;padding-top:12px;font-family:"Inter", sans-serif;font-size:14px;font-weight:400;line-height:18px;letter-spacing:0px;color:rgba(var(--v-text-secondary, 107, 116, 125, 1))}@media screen and (min-width: 768px) and (max-width: 1023px){:host .vega-input-select-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-input-select-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-input-select-hint{font-family:"Inter", sans-serif;font-size:14px;font-weight:400;line-height:18px;letter-spacing:0px}}:host vega-dropdown{display:block}';export{ye as vega_input_select}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{B as t,d as e,M as s,C as n,o as r,i as o,g as i}from"./p-84eb3b9c.js";import{c as a}from"./p-a841cf13.js";import{V as l}from"./p-8aee6b74.js";import"./p-6e1ab235.js";import{I as c,c as h}from"./p-593e0f80.js";import{r as u}from"./p-6e70d3cc.js";import{i as d}from"./p-e4c4ea35.js";import{g as E}from"./p-8b5d3a52.js";import{U as T,V as p}from"./p-f5f5a0d9.js";const b=[{payloadKey:"IS_OVERRIDECOLORS_METHOD_CALLED",payloadDescription:"Indicate if the method overrideColors of public API ThemeManager is called",canAccept:(t,e)=>"ThemeManager"===t&&"overrideColors"===e,payloadValue:()=>!0},{payloadKey:"IS_RESET_METHOD_CALLED",payloadDescription:"Indicate if the method reset of public API ThemeManager is called",canAccept:(t,e)=>"ThemeManager"===t&&"reset"===e,payloadValue:()=>!0},{payloadKey:"IS_TOGGLEDARKMODE_METHOD_CALLED",payloadDescription:"Indicate if the method toggleDarkMode of public API ThemeManager is called",canAccept:(t,e)=>"ThemeManager"===t&&"toggleDarkMode"===e,payloadValue:()=>!0},{payloadKey:"IS_ISDARKMODE_METHOD_CALLED",payloadDescription:"Indicate if the method isDarkMode of public API ThemeManager is called",canAccept:(t,e)=>"ThemeManager"===t&&"isDarkMode"===e,payloadValue:()=>!0},{payloadKey:"IS_APPLY_BRANDING_METHOD_CALLED",payloadDescription:"Indicate if the method applyBranding of public API ThemeManager is called",canAccept:(t,e)=>"ThemeManager"===t&&"applyBranding"===e,payloadValue:()=>!0}];class f{constructor(){this.vegaPublicAPIRuntimeMetricsSlimmer=h(f,["overrideColors","reset","toggleDarkMode","isDarkMode","applyBranding"],b)}async overrideColors(t){l.overrideColors(t)}async reset(){l.reset()}toggleDarkMode(t){l.toggleDarkMode(t)}isDarkMode(){return l.isDarkMode()}applyBranding(t){l.applyBranding(t)}}!function(t,e,s,n){var r,o=arguments.length,i=o<3?e:null===n?n=Object.getOwnPropertyDescriptor(e,s):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)i=Reflect.decorate(t,e,s,n);else for(var a=t.length-1;a>=0;a--)(r=t[a])&&(i=(o<3?r(i):o>3?r(e,s,i):r(e,s))||i);o>3&&i&&Object.defineProperty(e,s,i)}([c()],f.prototype,"vegaPublicAPIRuntimeMetricsSlimmer",void 0);const C=new f,L=["none","solid","dashed","dotted","double","groove","ridge","inset","outset"],g=[{key:"white",dark:"#04041C",light:"#FCFCFC"},{key:"red",dark:"#AA091C",light:"#FF4C61"},{key:"orange",dark:"#974502",light:"#FDAB68"},{key:"yellow",dark:"#735C00",light:"#FFDC4C"},{key:"green",dark:"#2E6D18",light:"#7BDA58"},{key:"teal",dark:"#287171",light:"#7BD1D1"},{key:"gray",dark:"#595959",light:"#999999"},{key:"black",dark:"#FCFCFC",light:"#04041C"}],R={key:"default-head-bg",dark:"#181830",light:"#F0F3F7"};class _{static getTableColors(){return _.TABLE_COLORS}static setTableColors(t){_.TABLE_COLORS=t}static getColorKey(t,e=!1){var s;let n=null;const r=_.TABLE_COLORS,o=e?[...r,R]:r;if(o){const e=null===(s=u(t))||void 0===s?void 0:s.toUpperCase();if(e)n=o.find((t=>C.isDarkMode()?t.dark===e:t.light===e));else for(const e of o)if(e.key===t){n=e;break}}return n?n.key:""}}_.TABLE_COLORS=g;class O extends t{constructor(t){super(),this.type=m.COLOR,this.colorKey=t,t&&(this.color=this.formatColor(t))}renderStyle(){return{color:this.color?l.isDarkMode()?this.color.dark:this.color.light:this.colorKey||""}}renderClass(){return null}toJSON(){var t;return{color:(null===(t=this.color)||void 0===t?void 0:t.key)||this.colorKey||""}}clone(){return new O(this.colorKey)}formatColor(t){return _.getTableColors().find((e=>e.key===t))}}var m,k;!function(t){t.TABLE="EXTENSION_TABLE",t.CELL="EXTENSION_TABLE_CELL",t.CAPTION="EXTENSION_TABLE_CAPTION",t.COLOR="EXTENSION_TABLE_COLOR"}(m||(m={}));class A extends t{constructor({backgroundColor:t,border:e,width:s,height:n,alignment:r,borderCollapse:o}={},i=!0){super(),this.type=m.TABLE,this.useInternalStyle=i,this.backgroundColor=t,this.border=e,this.width=s,this.height=n,this.alignment=i&&void 0===r?A.DEFAULT_ALIGNMENT:r,this.backgroundColorAnnotation=new O(t),this.borderColorAnnotation=new O(null==e?void 0:e.color),this.borderCollapse=i&&void 0===o?A.DEFAULT_BORDER_COLLAPSE:o}static from(t,e=!0){return[m.TABLE,new A(t,e)]}static getDefaultStyles(){return{borderCollapse:A.DEFAULT_BORDER_COLLAPSE,margin:A.DEFAULT_ALIGNMENT_STYLE_VALUE}}get borderStr(){return this.border?`${this.border.style} ${this.border.width} ${this.borderColorAnnotation.renderStyle().color}`.trim():null}clone(){return new A({backgroundColor:this.backgroundColor,border:this.border,width:this.width,height:this.height,alignment:this.alignment,borderCollapse:this.borderCollapse},this.useInternalStyle)}toJSON(){return{table:a({backgroundColor:this.backgroundColor,border:this.border,width:this.width,height:this.height,alignment:this.alignment,borderCollapse:this.borderCollapse})}}renderStyle(){const t=this.backgroundColorAnnotation.renderStyle().color,e=Object.assign({border:this.borderStr,width:this.width,height:this.height,borderCollapse:this.borderCollapse},this.renderAlignmentStyle());return t&&(e.backgroundColor=t),a(e)}renderClass(){return"v-rte--extension-table"}renderAlignmentStyle(){return this.alignment?{margin:"center"===this.alignment?A.DEFAULT_ALIGNMENT_STYLE_VALUE:"left"===this.alignment?"0":"0 0 0 auto"}:{}}}A.DEFAULT_BORDER_COLLAPSE="collapse",A.DEFAULT_ALIGNMENT="center",A.DEFAULT_ALIGNMENT_STYLE_VALUE="0 auto";class RTETableBlock extends e{constructor(t,e){super(t),this.type="table-block",this.children=[];const{autoMatchFormat:s}=e||{autoMatchFormat:!0};s&&this.annotationMap.set(m.TABLE,new A)}static from(t,e){var s;const n=new RTETableBlock(t.id,e);return super.convertAnnotationsToMap(n.annotationMap,Object.assign({},t.annotations)),n.children=super.generateBlockChildren(t.children,e,n),(null===(s=t.annotations)||void 0===s?void 0:s.table)&&n.annotationMap.set(...A.from(t.annotations.table,null==e?void 0:e.autoMatchFormat)),n}clone(t){const e=new RTETableBlock(this.id);return e.children=this.children.map((t=>t.clone(e))),e.parent=t,e.annotationMap=super.cloneAnnotations(),e}getLastNode(){return this.children[this.children.length-1].getLastNode()}getFirstNode(){return this.hasCaption()?this.children[0].children[0].getLastNode():this.children[0].children[0].children[0].getLastNode()}isNotEmpty(){return this.children.length>0}toHtml(t){const e=this.children.map((e=>e.toHtml(t))).join("");return`<table${super.generateAttributeString(t)}>${e}</table>`}toJSON(){return Object.assign(Object.assign({},super.toJSON()),{type:this.type,children:this.children.map((t=>t.toJSON()))})}getCaption(){const t=this.children.find((t=>"table-caption"===t.type));return null!=t?t:null}setCaption(t){const e=this.children.findIndex((t=>"table-caption"===t.type));t?(t.parent=this,e>=0?this.children[e]=t:this.children.unshift(t)):e>=0&&this.children.splice(e,1)}hasCaption(){return d(this.getCaption())}}!function(t){t.ROW="ROW",t.CAPTION="CAPTION",t.COLUMN="COLUMN",t.MERGE_CELLS="MERGE_CELLS",t.TABLE="TABLE",t.CELL="CELL",t.SPLIT_CELL="SPLIT_CELL"}(k||(k={}));class B{syncCursorPosition(t,e){const s=this.findRootContent(t);if(e&&s){const t=e.getRangeEndOffset();s.apply(new T(e,t))}}findRootContent(t){let e=t.parent;for(;e;){if(e instanceof p)return e;e=e.parent}}}const w="DELETE_TABLE_ROW";class S extends s{constructor(t){super(),this.isFlushable=!0,this.type="DELETE_TABLE_ROW",this.rowsToBeRemoved=t}}const y="INSERT_TABLE_ROW_INTO_DIFFERENT_SECTION";class N extends s{constructor(t,e=[]){super(),this.isFlushable=!0,this.type="INSERT_TABLE_ROW_INTO_DIFFERENT_SECTION",this.selectedRows=[],this.insertDirection=t,this.selectedRows=e}}const M="INSERT_TABLE_ROW_INTO_SAME_SECTION";var D;!function(t){t.ABOVE="ABOVE",t.BELOW="BELOW"}(D||(D={}));class v extends s{constructor(t,e=[]){super(),this.isFlushable=!0,this.type="INSERT_TABLE_ROW_INTO_SAME_SECTION",this.selectedRows=[],this.insertDirection=t,this.selectedRows=e}}const I="TOGGLE_HEADER_ROW";class x extends s{constructor(t){super(),this.isFlushable=!0,this.type="TOGGLE_HEADER_ROW",this.selectedRows=t}}class RTETableBodyBlock extends e{constructor(t){super(t),this.type="table-body",this.children=[]}static from(t,e){const s=new RTETableBodyBlock(t.id);return super.convertAnnotationsToMap(s.annotationMap,Object.assign({},t.annotations)),s.children=super.generateBlockChildren(t.children,e,s),s}clone(t){const e=new RTETableBodyBlock(this.id);return e.children=this.children.map((t=>t.clone(e))),e.parent=t,e.annotationMap=super.cloneAnnotations(),e}getLastNode(){return this.children[this.children.length-1].getLastNode()}isNotEmpty(){return this.children.length>0}toHtml(t){const e=this.children.map((e=>e.toHtml(t))).join("");return`<tbody${super.generateAttributeString(t)}>${e}</tbody>`}toJSON(){return Object.assign(Object.assign({},super.toJSON()),{type:this.type,children:this.children.map((t=>t.toJSON()))})}}class RTETableHeadBlock extends e{constructor(t){super(t),this.type="table-head",this.children=[]}static from(t,e){const s=new RTETableHeadBlock(t.id);return super.convertAnnotationsToMap(s.annotationMap,Object.assign({},t.annotations)),s.children=super.generateBlockChildren(t.children,e,s),s}clone(t){const e=new RTETableHeadBlock(this.id);return e.children=this.children.map((t=>t.clone(e))),e.parent=t,e.annotationMap=super.cloneAnnotations(),e}getLastNode(){return this.children[this.children.length-1].getLastNode()}isNotEmpty(){return this.children.length>0}toHtml(t){const e=this.children.map((e=>e.toHtml(t))).join("");return`<thead${super.generateAttributeString(t)}>${e}</thead>`}toJSON(){return Object.assign(Object.assign({},super.toJSON()),{type:this.type,children:this.children.map((t=>t.toJSON()))})}}class RTETableRowBlock extends e{constructor(t){super(t),this.type="table-row",this.children=[]}static from(t,e){const s=new RTETableRowBlock(t.id);return super.convertAnnotationsToMap(s.annotationMap,Object.assign({},t.annotations)),s.children=super.generateBlockChildren(t.children,e,s),s}clone(t){const e=new RTETableRowBlock(this.id);return e.children=this.children.map((t=>t.clone(e))),e.parent=t,e.annotationMap=super.cloneAnnotations(),e}getLastNode(){return this.children[this.children.length-1].getLastNode()}isNotEmpty(){return this.children.length>0}toHtml(t){const e=this.children.map((e=>e.toHtml(t))).join("");return`<tr${super.generateAttributeString(t)}>${e}</tr>`}toJSON(){return Object.assign(Object.assign({},super.toJSON()),{type:this.type,children:this.children.map((t=>t.toJSON()))})}}class H extends t{constructor({backgroundColor:t,padding:e,border:s,width:n,height:r,textAlign:o,verticalAlign:i,minWidth:a,boxSizing:l}={},c=!0){super(),this.type=m.CELL,this.useInternalStyle=c,this.backgroundColor=t,this.width=n,this.height=r,this.border=c&&void 0===s?H.DEFAULT_BORDER:s,this.padding=c&&void 0===e?H.DEFAULT_PADDING:e,this.textAlign=c&&void 0===o?H.DEFAULT_HORIZONTAL_TEXT_ALIGN:o,this.verticalAlign=c&&void 0===i?H.DEFAULT_VERTICAL_TEXT_ALIGN:i,this.minWidth=c&&void 0===a?H.DEFAULT_CELL_MIN_WIDTH:a,this.boxSizing=c&&void 0===l?H.DEFAULT_BOX_SIZING:l}static from(t,e){return[m.CELL,new H(t,e)]}static getDefaultStyles(t=!0){return{padding:H.DEFAULT_PADDING,textAlign:H.DEFAULT_HORIZONTAL_TEXT_ALIGN,verticalAlign:H.DEFAULT_VERTICAL_TEXT_ALIGN,minWidth:H.DEFAULT_CELL_MIN_WIDTH,boxSizing:H.DEFAULT_BOX_SIZING,border:`${H.DEFAULT_BORDER.style} ${H.DEFAULT_BORDER.width} ${t?H.DEFAULT_BORDER.color:H.DEFAULT_BORDER_RGB_COLOR}`}}get borderStr(){return this.border?`${this.border.style||""} ${this.border.width||""} ${this.borderColorAnnotation.renderStyle().color}`.trim():null}set backgroundColor(t){this._backgroundColor=t,this.backgroundColorAnnotation=new O(t)}get backgroundColor(){return this._backgroundColor}set border(t){this._border=t,this.borderColorAnnotation=new O(null==t?void 0:t.color)}get border(){return this._border}clone(){return new H({backgroundColor:this.backgroundColor,padding:this.padding,border:this.border,width:this.width,height:this.height,textAlign:this.textAlign,verticalAlign:this.verticalAlign,minWidth:this.minWidth,boxSizing:this.boxSizing},this.useInternalStyle)}toJSON(){return{tableCell:a({backgroundColor:this.backgroundColor,padding:this.padding,border:this.border,width:this.width,height:this.height,textAlign:this.textAlign,verticalAlign:this.verticalAlign,minWidth:this.minWidth,boxSizing:this.boxSizing})}}renderStyle(t){const e=this.backgroundColorAnnotation.renderStyle().color,s={padding:this.padding,border:this.borderStr,width:this.width,height:this.height,textAlign:this.textAlign,verticalAlign:this.verticalAlign,minWidth:this.minWidth,boxSizing:this.boxSizing};return e&&(s.backgroundColor=e),a((null==t?void 0:t.standalone)?s:this.removeDefaultValues(s),{cleanEmptyString:!0})}renderClass(){return null}removeDefaultValues(t){const e=Object.assign({},t);return e.padding===H.DEFAULT_PADDING&&delete e.padding,e.border===`${H.DEFAULT_BORDER.style} ${H.DEFAULT_BORDER.width} ${H.DEFAULT_BORDER.color}`&&delete e.border,e.textAlign===H.DEFAULT_HORIZONTAL_TEXT_ALIGN&&delete e.textAlign,e.verticalAlign===H.DEFAULT_VERTICAL_TEXT_ALIGN&&delete e.verticalAlign,e.minWidth===H.DEFAULT_CELL_MIN_WIDTH&&delete e.minWidth,e.boxSizing===H.DEFAULT_BOX_SIZING&&delete e.boxSizing,e}}H.DEFAULT_PADDING="12px",H.DEFAULT_BORDER={style:"solid",width:"1px",color:"#ddd"},H.DEFAULT_BORDER_RGB_COLOR="rgb(221, 221, 221)",H.DEFAULT_HORIZONTAL_TEXT_ALIGN="left",H.DEFAULT_VERTICAL_TEXT_ALIGN="middle",H.DEFAULT_CELL_MIN_WIDTH="55px",H.DEFAULT_BOX_SIZING="border-box";class RTETableCellBlock extends e{constructor(t,e){super(t),this.type="table-cell",this.children=[];const{autoMatchFormat:s}=e||{autoMatchFormat:!0};s&&this.annotationMap.set(m.CELL,new H)}static from(t,e){var s;const n=new RTETableCellBlock(t.id,e);return super.convertAnnotationsToMap(n.annotationMap,Object.assign({},t.annotations)),(null===(s=t.annotations)||void 0===s?void 0:s.tableCell)&&n.annotationMap.set(...H.from(t.annotations.tableCell,null==e?void 0:e.autoMatchFormat)),n.children=super.generateBlockChildren(t.children,e,n),n}clone(t){const e=new RTETableCellBlock(this.id);return e.children=this.children.map((t=>t.clone(e))),e.parent=t,e.annotationMap=super.cloneAnnotations(),e}getLastNode(){return this.children[this.children.length-1].getLastNode()}isNotEmpty(){return this.children.length>0}get rowSpan(){const t=this.getCustomAttributeByName("rowspan");return isNaN(Number(t))?1:Math.max(Number(t),1)}get colSpan(){const t=this.getCustomAttributeByName("colspan");return isNaN(Number(t))?1:Math.max(Number(t),1)}toHtml(t){const e=this.children.map((e=>e.toHtml(t))).join("");return`<td${super.generateAttributeString(t)}>${e}</td>`}toJSON(){return Object.assign(Object.assign({},super.toJSON()),{type:this.type,children:this.children.map((t=>t.toJSON()))})}getCustomAttributeByName(t){const e=this.getCustomAttributesAnnotation();if(e)return(e.toJSON().customAttribute||{})[t]}}class j extends H{constructor(t={},e=!0){super(t,e)}static from(t,e){return[m.CELL,new j(t,e)]}static getDefaultBackgroundColor(){return l.isDarkMode()?R.dark:R.light}clone(){return new j({backgroundColor:this.backgroundColor,padding:this.padding,border:this.border,width:this.width,height:this.height,textAlign:this.textAlign,verticalAlign:this.verticalAlign,minWidth:this.minWidth,boxSizing:this.boxSizing},this.useInternalStyle)}renderStyle(t){var e;const s=super.renderStyle(t);return a(Object.assign(Object.assign({},s),{backgroundColor:null!==(e=s.backgroundColor)&&void 0!==e?e:j.getDefaultBackgroundColor()}))}}class RTETableHeadCellBlock extends RTETableCellBlock{constructor(t,e){super(t,e),this.type="table-head-cell";const{autoMatchFormat:s}=e||{autoMatchFormat:!0};s&&this.annotationMap.set(m.CELL,new j)}static from(t,e){var s;const n=new RTETableHeadCellBlock(t.id,e);return super.convertAnnotationsToMap(n.annotationMap,Object.assign({},t.annotations)),(null===(s=t.annotations)||void 0===s?void 0:s.tableCell)&&n.annotationMap.set(...j.from(t.annotations.tableCell,null==e?void 0:e.autoMatchFormat)),n.children=super.generateBlockChildren(t.children,e,n),n}clone(t){const e=new RTETableHeadCellBlock(this.id);return e.children=this.children.map((t=>t.clone(e))),e.parent=t,e.annotationMap=super.cloneAnnotations(),e}toHtml(t){const e=this.children.map((e=>e.toHtml(t))).join("");return`<th${super.generateAttributeString(t)}>${e}</th>`}toJSON(){return Object.assign(Object.assign({},super.toJSON()),{type:this.type,children:this.children.map((t=>t.toJSON()))})}}const F="MERGE_CELLS";class $ extends s{constructor(t,e,s,n,r){super(),this.type="MERGE_CELLS",this.isFlushable=!0,this.targetCell=t,this.mergeCells=e,this.colSpan=s,this.rowSpan=n,this.direction=r}}var P,W;!function(t){t.MERGE_CELLS="MERGE_CELLS",t.MERGE_CELL_UP="MERGE_CELL_UP",t.MERGE_CELL_RIGHT="MERGE_CELL_RIGHT",t.MERGE_CELL_DOWN="MERGE_CELL_DOWN",t.MERGE_CELL_LEFT="MERGE_CELL_LEFT"}(P||(P={}));class G extends B{canHandle(t){return t[0]===k.MERGE_CELLS}execute(t,e){const s=e.tableSelection.getSelectedCells(),n=t[1];switch(n){case P.MERGE_CELL_UP:case P.MERGE_CELL_RIGHT:case P.MERGE_CELL_DOWN:case P.MERGE_CELL_LEFT:{const t=this.getDirectionMergeCells(n,s[0]);this.handleMergeCells(t,n)}break;default:s.length>1&&this.handleMergeCells(s,P.MERGE_CELLS)}}getDirectionMergeCells(t,e){const s=Q(e,t);if(!s)return[e];switch(t){case P.MERGE_CELL_UP:return[s,e];case P.MERGE_CELL_DOWN:return[e,s];case P.MERGE_CELL_LEFT:return[s,e];default:return[e,s]}}handleMergeCells(t,e){if(t.length<2)return;const s=tt(t),{minRow:n,maxRow:r,minCol:o,maxCol:i,targetCell:a}=s,l=new $(a,t,i-o+1,r-n+1,e);this.applyActionOnTable(l,a)}applyActionOnTable(t,e){const s=U(e,RTETableBlock);s&&s.apply(t)}}function U(t,e){return t?t instanceof e?t:U(t.parent,e):null}function V(t,e){return{id:E(),type:"table-body",children:Array.from({length:t},(()=>function(t){return{id:E(),type:"table-row",children:Array.from({length:t},(()=>Y("table-cell")))}}(e)))}}function J(t){return t.children.filter((t=>t instanceof RTETableBodyBlock||t instanceof RTETableHeadBlock)).flatMap((t=>t.children))}function K(t){if(!t||!t.children||!t.children[0])return null;const e=t.children[0];return e instanceof o?e:K(e)}function z(t,e){for(const s of t){const t=s.children.find((t=>t.id===e));if(t)return t}return null}function Y(t){const e=E();return{id:e,type:t,children:[{id:`${e}-p`,type:"paragraph",nodes:[{id:`${e}-p-t`,type:"text",text:""}]}]}}function X(t){return{colSpan:t.colSpan,rowSpan:t.rowSpan}}function Z(t,e,s){const n=null!=s?s:q(e);for(let e=0;e<n.length;e++){const s=n[e];for(let e=0;e<s.length;e++)if(s[e]===t.id)return e}return-1}function q(t){const e=[];return t.forEach(((t,s)=>{e[s]||(e[s]=[]);let n=0;t.children.forEach((t=>{const{colSpan:r,rowSpan:o}=X(t);for(;void 0!==e[s][n];)n++;for(let i=0;i<o;i++)for(let o=0;o<r;o++)e[s+i]||(e[s+i]=[]),e[s+i][n+o]=t.id;n+=r}))})),e}function Q(t,e){if(!t)return null;const s=t.parent,n=s.parent.children,r=n.indexOf(s),{colSpan:o,rowSpan:i}=X(t),a=Z(t,n);let l=r,c=a;switch(e){case P.MERGE_CELL_LEFT:c=a-1;break;case P.MERGE_CELL_RIGHT:c=a+o;break;case P.MERGE_CELL_UP:l=r-1;break;default:l=r+i}return function(t,e,s){const n=q(t);for(let r=0;r<t.length;r++){const o=t[r];for(const i of o.children){const{colSpan:o,rowSpan:a}=X(i),l=Z(i,t,n),c=r+a-1,h=l+o-1,u=s>=l&&s<=h;if(e>=r&&e<=c&&u)return i}}return null}(n,l,c)}function tt(t){const e=t[0].parent.parent.children,s=q(e);let n=Number.POSITIVE_INFINITY,r=-1,o=Number.POSITIVE_INFINITY,i=-1;const a=new Set;return t.forEach((t=>{const l=e.indexOf(t.parent),c=Z(t,e,s),{colSpan:h,rowSpan:u}=X(t),d=l,E=l+u-1,T=c,p=c+h-1;for(let t=d;t<=E;t++)for(let e=T;e<=p;e++)a.add(`${t},${e}`);n=Math.min(n,d),r=Math.max(r,E),o=Math.min(o,T),i=Math.max(i,p)})),{minRow:n,maxRow:r,minCol:o,maxCol:i,targetCell:t[0],coveredPositions:a}}function et(t){let e=0;const s=J(t)[0];for(const t of s.children){const{colSpan:s}=X(t);e+=s}return e}function st(t){if(1===t.length)return!0;const e=tt(t),{minRow:s,maxRow:n,minCol:r,maxCol:o,coveredPositions:i}=e;return i.size===(n-s+1)*(o-r+1)}function nt(t,e,s,o,i){const a=t.annotationMap.get(n.CUSTOM_ATTRIBUTE),l=a?Object.assign({},a.customAttribute):{};delete l.colspan,delete l.rowspan,e>1&&(l.colspan=String(e));const c=et(o)+(i?1:0);if(s>1&&e!==c&&(l.rowspan=String(s)),Object.keys(l).length>0){const e=new r(l);t.annotationMap.set(n.CUSTOM_ATTRIBUTE,e)}else t.annotationMap.delete(n.CUSTOM_ATTRIBUTE)}function rt(t){const e=Y(t);return"table-head-cell"===t?RTETableHeadCellBlock.from(e):RTETableCellBlock.from(e)}function ot(t,e,s){for(let n=0;n<s;n++){const s=t[n],r=e.children.find((t=>t.id===s));if(r&&!(r instanceof RTETableHeadCellBlock))return n}return-1}function it(t){const e=new Map;return t.forEach((t=>{for(let s=0;s<t.length;s++){const n=t[s];n&&!e.has(n)&&e.set(n,s)}})),e}function at(t,e,s,n){if(0===t.length)return[0,-1];const r=s||J(e),o=null!=n?n:q(r);let i=Number.POSITIVE_INFINITY,a=Number.NEGATIVE_INFINITY;return t.forEach((t=>{const e=Z(t,r,o);i=Math.min(i,e),a=Math.max(a,e)})),[i,a]}!function(t){t.HEADER_ROW="HEADER_ROW",t.ADD_ROW_ABOVE="ADD_ROW_ABOVE",t.ADD_ROW_BELOW="ADD_ROW_BELOW",t.DELETE_ROW="DELETE_ROW",t.SELECT_ROW="SELECT_ROW"}(W||(W={}));class lt extends B{canHandle(t){return t[0]===k.ROW}execute(t,e){const s=t[1];switch(s){case W.ADD_ROW_ABOVE:case W.ADD_ROW_BELOW:this.handleInsertRow(s,e);break;case W.DELETE_ROW:this.handleDeleteRow(e);break;case W.HEADER_ROW:this.handleToggleHeader(e);break;case W.SELECT_ROW:this.handleSelectRow(e)}}handleInsertRow(t,e){const s=this.getAllSelectedRows(e);if(s.length>0){const e=t===W.ADD_ROW_ABOVE?D.ABOVE:D.BELOW,n=e===D.ABOVE?s[0]:s[s.length-1],r=n.parent instanceof RTETableBodyBlock,o=this.shouldInsertHeaderRow(n,e)||r?new v(e,s):new N(e,s);this.applyActionToTable(s[0],o)}}shouldInsertHeaderRow(t,e){if(e===D.ABOVE)return t.parent instanceof RTETableHeadBlock;{const e=t.parent;return e instanceof RTETableHeadBlock&&e.children[e.children.length-1]!==t}}handleDeleteRow(t){const e=this.getAllSelectedRows(t);if(e.length){const t=new S(e);this.applyActionToTable(e[0],t)}}handleToggleHeader(t){const e=this.getAllSelectedRows(t);if(e.length>0){const t=new x(e);this.applyActionToTable(e[0],t)}}handleSelectRow(t){const e=this.getAllSelectedRows(t);if(e.length>0&&t&&t.tableSelection){const s=e.flatMap((t=>t.children));t.tableSelection.setSelectedCells(s)}}getAllSelectedRows(t){const e=new Set;if(t&&t.tableSelection){const{tableSelection:s}=t;s.getSelectedCells().forEach((t=>{const s=U(t,RTETableRowBlock);s&&e.add(s)}))}return Array.from(e)}applyActionToTable(t,e){const s=U(t,RTETableBlock);s&&s.apply(e)}}const ct="REPLACE_TABLE_CELL";class ht extends s{constructor(t){super(),this.isFlushable=!0,this.type="REPLACE_TABLE_CELL",this.payload=t}}const ut="SPLIT_TABLE_CELL";class dt extends s{constructor(t){super(),this.isFlushable=!0,this.type="SPLIT_TABLE_CELL",this.payload=t}}class Et extends i{getBoundaryCellColumnRange(t,e,s){let n=Number.POSITIVE_INFINITY,r=Number.NEGATIVE_INFINITY;return t.forEach((t=>{const o=Z(t,e,s);n=Math.min(n,o),r=Math.max(r,o)})),[n,r]}}class Tt extends Et{static isFullHeaderSelection(t){if(0===t.length)return!1;const e=U(t[0],RTETableBlock);if(e){const s=J(e),n=q(s),r=new Map;s.forEach((t=>{t.children.forEach((t=>r.set(t.id,t)))}));const[o,i]=at(t,e,s,n);for(const t of n)for(let e=o;e<=i;e++){const s=r.get(t[e]);if(s&&!(s instanceof RTETableHeadCellBlock))return!1}return!0}return!1}handleAction(t,e){const s=t.headerOn,n=J(e),r=q(n),[o,i]=this.getBoundaryCellColumnRange(t.tableCellHeaderRange,n,r);(s||!s&&o>0)&&this.toggleHeadRows(e,n,r,s,i,o),this.toggleBodyRows(e,n,r,s,o,i);const a=this.getRootContent(e);if(a&&t.tableCellHeaderRange[0].parent){const e=t.tableCellHeaderRange[0].parent.getFirstNode();e&&a.apply(new T(e,0))}}toggleHeadRows(t,e,s,n,r,o){var i;const a=((null===(i=t.children.find((t=>t instanceof RTETableHeadBlock)))||void 0===i?void 0:i.children)||[]).length;for(let i=0;i<a;i++)this.toggleCellType(t,e[i],s[i],0,n?r:o-1,(()=>!0),(t=>RTETableHeadCellBlock.from(t.toJSON())))}toggleBodyRows(t,e,s,n,r,o){var i;const a=s[0].length,l=(null===(i=t.children.find((t=>t instanceof RTETableBodyBlock)))||void 0===i?void 0:i.children)||[],c=e.length-l.length;for(let i=0;i<l.length;i++){const l=i+c,h=e[l],u=s[l],d=ot(u,h,a);n?d>-1&&this.toggleCellType(t,h,u,d,o,(t=>!(t instanceof RTETableHeadCellBlock)),(t=>RTETableHeadCellBlock.from(t.toJSON()))):this.toggleCellType(t,h,u,r,-1===d?a-1:d-1,(t=>t instanceof RTETableHeadCellBlock),(t=>RTETableCellBlock.from(t.toJSON())))}}toggleCellType(t,e,s,n,r,o,i){for(let a=n;a<=r;a++){const n=s[a],l=e.children.find((t=>t.id===n));if(l&&o(l)){const o=s.indexOf(n),c={table:t,cell:l,col:a,cellStartCol:o,endCol:r,targetCellType:i(l).type},h=o+l.colSpan-1;if(h>r||o<a){if(e.apply(new dt(c)),h>r)return;a=h;continue}e.apply(new ht(c))}l&&(a+=l.colSpan-1)}}}const pt="DELETE_TABLE_COLUMN";class bt extends s{constructor(t){super(),this.isFlushable=!0,this.type="DELETE_TABLE_COLUMN",this.tableCellDeleteRange=t}}const ft="INSERT_TABLE_COLUMN";var Ct;!function(t){t.LEFT="LEFT",t.RIGHT="RIGHT"}(Ct||(Ct={}));class Lt extends s{constructor(t,e){super(),this.isFlushable=!0,this.type="INSERT_TABLE_COLUMN",this.tableCellInsertRange=e,this.insertDirection=t}}const gt="SELECT_TABLE_COLUMN";class Rt extends s{constructor(t,e){super(),this.type="SELECT_TABLE_COLUMN",this.tableCellSelectRange=t,this.selectCellCallback=e}}const _t="TOGGLE_HEADER_TABLE_COLUMN";class Ot extends s{constructor(t,e){super(),this.isFlushable=!0,this.type="TOGGLE_HEADER_TABLE_COLUMN",this.headerOn=!1,this.tableCellHeaderRange=t,this.headerOn=e}}var mt;!function(t){t.HEADER_COLUMN="HEADER_COLUMN",t.ADD_COLUMN_LEFT="ADD_COLUMN_LEFT",t.ADD_COLUMN_RIGHT="ADD_COLUMN_RIGHT",t.DELETE_COLUMN="DELETE_COLUMN",t.SELECT_COLUMN="SELECT_COLUMN"}(mt||(mt={}));class kt extends B{canHandle(t){return t[0]===k.COLUMN}execute(t,e){const s=e.tableSelection.getSelectedCells();if(!s||0===s.length)return;const n=t[1];switch(n){case mt.ADD_COLUMN_LEFT:case mt.ADD_COLUMN_RIGHT:this.handleInsertColumn(n,s);break;case mt.DELETE_COLUMN:this.handleDeleteColumn(s);break;case mt.SELECT_COLUMN:this.handleSelectColumn(s,e);break;case mt.HEADER_COLUMN:this.handleToggleHeaderColumn(s)}}handleInsertColumn(t,e){const s=new Lt(t===mt.ADD_COLUMN_LEFT?Ct.LEFT:Ct.RIGHT,e);this.applyActionOnTable(s,e[0])}handleDeleteColumn(t){const e=new bt(t);this.applyActionOnTable(e,t[0])}handleSelectColumn(t,e){const s=new Rt(t,(t=>{e.tableSelection.setSelectedCells(t)}));this.applyActionOnTable(s,t[0])}handleToggleHeaderColumn(t){const e=!Tt.isFullHeaderSelection(t),s=new Ot(t,e);this.applyActionOnTable(s,t[0])}applyActionOnTable(t,e){const s=U(e,RTETableBlock);s&&s.apply(t)}}const At="SPLIT_CELL_HORIZONTALLY";class Bt extends s{constructor(){super(),this.isFlushable=!0,this.type="SPLIT_CELL_HORIZONTALLY"}}const wt="SPLIT_CELL_VERTICALLY";class St extends s{constructor(){super(),this.isFlushable=!0,this.type="SPLIT_CELL_VERTICALLY"}}var yt;!function(t){t.SPLIT_CELL_HORIZONTALLY="SPLIT_CELL_HORIZONTALLY",t.SPLIT_CELL_VERTICALLY="SPLIT_CELL_VERTICALLY"}(yt||(yt={}));class Nt extends B{canHandle(t){return t[0]===k.SPLIT_CELL}execute(t,e){const s=e.tableSelection.getSelectedCells();if(s&&1===s.length){const e=s[0];switch(t[1]){case yt.SPLIT_CELL_HORIZONTALLY:this.handleSplitCellHorizontally(e);break;case yt.SPLIT_CELL_VERTICALLY:this.handleSplitCellVertically(e)}}}handleSplitCellHorizontally(t){const e=new Bt;t.apply(e)}handleSplitCellVertically(t){const e=new St;t.apply(e)}}export{at as $,RTETableRowBlock as A,Z as B,kt as C,D,g as E,y as F,M as G,w as H,Ct as I,I as J,ft as K,pt as L,G as M,_t as N,Tt as O,ut as P,ct as Q,m as R,B as S,k as T,At as U,C as V,wt as W,gt as X,F as Y,L as Z,mt as _,R as a,W as a0,yt as a1,st as a2,Q as a3,A as b,H as c,RTETableHeadCellBlock as d,lt as e,Nt as f,_ as g,RTETableBlock as h,V as i,RTETableCellBlock as j,RTETableHeadBlock as k,RTETableBodyBlock as l,U as m,j as n,Et as o,J as p,q,z as r,nt as s,Y as t,it as u,et as v,K as w,X as x,rt as y,P as z}
|
|
1
|
+
import{B as t,d as e,M as s,C as n,o as r,i as o,g as i}from"./p-a2b8d49d.js";import{c as a}from"./p-a841cf13.js";import{V as l}from"./p-8aee6b74.js";import"./p-6e1ab235.js";import{I as c,c as h}from"./p-9a6bd32c.js";import{r as u}from"./p-ec2a1d4c.js";import{i as d}from"./p-78ba7ca9.js";import{g as E}from"./p-8b5d3a52.js";import{U as T,V as p}from"./p-e8ea3b16.js";const b=[{payloadKey:"IS_OVERRIDECOLORS_METHOD_CALLED",payloadDescription:"Indicate if the method overrideColors of public API ThemeManager is called",canAccept:(t,e)=>"ThemeManager"===t&&"overrideColors"===e,payloadValue:()=>!0},{payloadKey:"IS_RESET_METHOD_CALLED",payloadDescription:"Indicate if the method reset of public API ThemeManager is called",canAccept:(t,e)=>"ThemeManager"===t&&"reset"===e,payloadValue:()=>!0},{payloadKey:"IS_TOGGLEDARKMODE_METHOD_CALLED",payloadDescription:"Indicate if the method toggleDarkMode of public API ThemeManager is called",canAccept:(t,e)=>"ThemeManager"===t&&"toggleDarkMode"===e,payloadValue:()=>!0},{payloadKey:"IS_ISDARKMODE_METHOD_CALLED",payloadDescription:"Indicate if the method isDarkMode of public API ThemeManager is called",canAccept:(t,e)=>"ThemeManager"===t&&"isDarkMode"===e,payloadValue:()=>!0},{payloadKey:"IS_APPLY_BRANDING_METHOD_CALLED",payloadDescription:"Indicate if the method applyBranding of public API ThemeManager is called",canAccept:(t,e)=>"ThemeManager"===t&&"applyBranding"===e,payloadValue:()=>!0}];class f{constructor(){this.vegaPublicAPIRuntimeMetricsSlimmer=h(f,["overrideColors","reset","toggleDarkMode","isDarkMode","applyBranding"],b)}async overrideColors(t){l.overrideColors(t)}async reset(){l.reset()}toggleDarkMode(t){l.toggleDarkMode(t)}isDarkMode(){return l.isDarkMode()}applyBranding(t){l.applyBranding(t)}}!function(t,e,s,n){var r,o=arguments.length,i=o<3?e:null===n?n=Object.getOwnPropertyDescriptor(e,s):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)i=Reflect.decorate(t,e,s,n);else for(var a=t.length-1;a>=0;a--)(r=t[a])&&(i=(o<3?r(i):o>3?r(e,s,i):r(e,s))||i);o>3&&i&&Object.defineProperty(e,s,i)}([c()],f.prototype,"vegaPublicAPIRuntimeMetricsSlimmer",void 0);const C=new f,L=["none","solid","dashed","dotted","double","groove","ridge","inset","outset"],g=[{key:"white",dark:"#04041C",light:"#FCFCFC"},{key:"red",dark:"#AA091C",light:"#FF4C61"},{key:"orange",dark:"#974502",light:"#FDAB68"},{key:"yellow",dark:"#735C00",light:"#FFDC4C"},{key:"green",dark:"#2E6D18",light:"#7BDA58"},{key:"teal",dark:"#287171",light:"#7BD1D1"},{key:"gray",dark:"#595959",light:"#999999"},{key:"black",dark:"#FCFCFC",light:"#04041C"}],R={key:"default-head-bg",dark:"#181830",light:"#F0F3F7"};class _{static getTableColors(){return _.TABLE_COLORS}static setTableColors(t){_.TABLE_COLORS=t}static getColorKey(t,e=!1){var s;let n=null;const r=_.TABLE_COLORS,o=e?[...r,R]:r;if(o){const e=null===(s=u(t))||void 0===s?void 0:s.toUpperCase();if(e)n=o.find((t=>C.isDarkMode()?t.dark===e:t.light===e));else for(const e of o)if(e.key===t){n=e;break}}return n?n.key:""}}_.TABLE_COLORS=g;class O extends t{constructor(t){super(),this.type=m.COLOR,this.colorKey=t,t&&(this.color=this.formatColor(t))}renderStyle(){return{color:this.color?l.isDarkMode()?this.color.dark:this.color.light:this.colorKey||""}}renderClass(){return null}toJSON(){var t;return{color:(null===(t=this.color)||void 0===t?void 0:t.key)||this.colorKey||""}}clone(){return new O(this.colorKey)}formatColor(t){return _.getTableColors().find((e=>e.key===t))}}var m,k;!function(t){t.TABLE="EXTENSION_TABLE",t.CELL="EXTENSION_TABLE_CELL",t.CAPTION="EXTENSION_TABLE_CAPTION",t.COLOR="EXTENSION_TABLE_COLOR"}(m||(m={}));class A extends t{constructor({backgroundColor:t,border:e,width:s,height:n,alignment:r,borderCollapse:o}={},i=!0){super(),this.type=m.TABLE,this.useInternalStyle=i,this.backgroundColor=t,this.border=e,this.width=s,this.height=n,this.alignment=i&&void 0===r?A.DEFAULT_ALIGNMENT:r,this.backgroundColorAnnotation=new O(t),this.borderColorAnnotation=new O(null==e?void 0:e.color),this.borderCollapse=i&&void 0===o?A.DEFAULT_BORDER_COLLAPSE:o}static from(t,e=!0){return[m.TABLE,new A(t,e)]}static getDefaultStyles(){return{borderCollapse:A.DEFAULT_BORDER_COLLAPSE,margin:A.DEFAULT_ALIGNMENT_STYLE_VALUE}}get borderStr(){return this.border?`${this.border.style} ${this.border.width} ${this.borderColorAnnotation.renderStyle().color}`.trim():null}clone(){return new A({backgroundColor:this.backgroundColor,border:this.border,width:this.width,height:this.height,alignment:this.alignment,borderCollapse:this.borderCollapse},this.useInternalStyle)}toJSON(){return{table:a({backgroundColor:this.backgroundColor,border:this.border,width:this.width,height:this.height,alignment:this.alignment,borderCollapse:this.borderCollapse})}}renderStyle(){const t=this.backgroundColorAnnotation.renderStyle().color,e=Object.assign({border:this.borderStr,width:this.width,height:this.height,borderCollapse:this.borderCollapse},this.renderAlignmentStyle());return t&&(e.backgroundColor=t),a(e)}renderClass(){return"v-rte--extension-table"}renderAlignmentStyle(){return this.alignment?{margin:"center"===this.alignment?A.DEFAULT_ALIGNMENT_STYLE_VALUE:"left"===this.alignment?"0":"0 0 0 auto"}:{}}}A.DEFAULT_BORDER_COLLAPSE="collapse",A.DEFAULT_ALIGNMENT="center",A.DEFAULT_ALIGNMENT_STYLE_VALUE="0 auto";class RTETableBlock extends e{constructor(t,e){super(t),this.type="table-block",this.children=[];const{autoMatchFormat:s}=e||{autoMatchFormat:!0};s&&this.annotationMap.set(m.TABLE,new A)}static from(t,e){var s;const n=new RTETableBlock(t.id,e);return super.convertAnnotationsToMap(n.annotationMap,Object.assign({},t.annotations)),n.children=super.generateBlockChildren(t.children,e,n),(null===(s=t.annotations)||void 0===s?void 0:s.table)&&n.annotationMap.set(...A.from(t.annotations.table,null==e?void 0:e.autoMatchFormat)),n}clone(t){const e=new RTETableBlock(this.id);return e.children=this.children.map((t=>t.clone(e))),e.parent=t,e.annotationMap=super.cloneAnnotations(),e}getLastNode(){return this.children[this.children.length-1].getLastNode()}getFirstNode(){return this.hasCaption()?this.children[0].children[0].getLastNode():this.children[0].children[0].children[0].getLastNode()}isNotEmpty(){return this.children.length>0}toHtml(t){const e=this.children.map((e=>e.toHtml(t))).join("");return`<table${super.generateAttributeString(t)}>${e}</table>`}toJSON(){return Object.assign(Object.assign({},super.toJSON()),{type:this.type,children:this.children.map((t=>t.toJSON()))})}getCaption(){const t=this.children.find((t=>"table-caption"===t.type));return null!=t?t:null}setCaption(t){const e=this.children.findIndex((t=>"table-caption"===t.type));t?(t.parent=this,e>=0?this.children[e]=t:this.children.unshift(t)):e>=0&&this.children.splice(e,1)}hasCaption(){return d(this.getCaption())}}!function(t){t.ROW="ROW",t.CAPTION="CAPTION",t.COLUMN="COLUMN",t.MERGE_CELLS="MERGE_CELLS",t.TABLE="TABLE",t.CELL="CELL",t.SPLIT_CELL="SPLIT_CELL"}(k||(k={}));class B{syncCursorPosition(t,e){const s=this.findRootContent(t);if(e&&s){const t=e.getRangeEndOffset();s.apply(new T(e,t))}}findRootContent(t){let e=t.parent;for(;e;){if(e instanceof p)return e;e=e.parent}}}const w="DELETE_TABLE_ROW";class S extends s{constructor(t){super(),this.isFlushable=!0,this.type="DELETE_TABLE_ROW",this.rowsToBeRemoved=t}}const y="INSERT_TABLE_ROW_INTO_DIFFERENT_SECTION";class N extends s{constructor(t,e=[]){super(),this.isFlushable=!0,this.type="INSERT_TABLE_ROW_INTO_DIFFERENT_SECTION",this.selectedRows=[],this.insertDirection=t,this.selectedRows=e}}const M="INSERT_TABLE_ROW_INTO_SAME_SECTION";var D;!function(t){t.ABOVE="ABOVE",t.BELOW="BELOW"}(D||(D={}));class v extends s{constructor(t,e=[]){super(),this.isFlushable=!0,this.type="INSERT_TABLE_ROW_INTO_SAME_SECTION",this.selectedRows=[],this.insertDirection=t,this.selectedRows=e}}const I="TOGGLE_HEADER_ROW";class x extends s{constructor(t){super(),this.isFlushable=!0,this.type="TOGGLE_HEADER_ROW",this.selectedRows=t}}class RTETableBodyBlock extends e{constructor(t){super(t),this.type="table-body",this.children=[]}static from(t,e){const s=new RTETableBodyBlock(t.id);return super.convertAnnotationsToMap(s.annotationMap,Object.assign({},t.annotations)),s.children=super.generateBlockChildren(t.children,e,s),s}clone(t){const e=new RTETableBodyBlock(this.id);return e.children=this.children.map((t=>t.clone(e))),e.parent=t,e.annotationMap=super.cloneAnnotations(),e}getLastNode(){return this.children[this.children.length-1].getLastNode()}isNotEmpty(){return this.children.length>0}toHtml(t){const e=this.children.map((e=>e.toHtml(t))).join("");return`<tbody${super.generateAttributeString(t)}>${e}</tbody>`}toJSON(){return Object.assign(Object.assign({},super.toJSON()),{type:this.type,children:this.children.map((t=>t.toJSON()))})}}class RTETableHeadBlock extends e{constructor(t){super(t),this.type="table-head",this.children=[]}static from(t,e){const s=new RTETableHeadBlock(t.id);return super.convertAnnotationsToMap(s.annotationMap,Object.assign({},t.annotations)),s.children=super.generateBlockChildren(t.children,e,s),s}clone(t){const e=new RTETableHeadBlock(this.id);return e.children=this.children.map((t=>t.clone(e))),e.parent=t,e.annotationMap=super.cloneAnnotations(),e}getLastNode(){return this.children[this.children.length-1].getLastNode()}isNotEmpty(){return this.children.length>0}toHtml(t){const e=this.children.map((e=>e.toHtml(t))).join("");return`<thead${super.generateAttributeString(t)}>${e}</thead>`}toJSON(){return Object.assign(Object.assign({},super.toJSON()),{type:this.type,children:this.children.map((t=>t.toJSON()))})}}class RTETableRowBlock extends e{constructor(t){super(t),this.type="table-row",this.children=[]}static from(t,e){const s=new RTETableRowBlock(t.id);return super.convertAnnotationsToMap(s.annotationMap,Object.assign({},t.annotations)),s.children=super.generateBlockChildren(t.children,e,s),s}clone(t){const e=new RTETableRowBlock(this.id);return e.children=this.children.map((t=>t.clone(e))),e.parent=t,e.annotationMap=super.cloneAnnotations(),e}getLastNode(){return this.children[this.children.length-1].getLastNode()}isNotEmpty(){return this.children.length>0}toHtml(t){const e=this.children.map((e=>e.toHtml(t))).join("");return`<tr${super.generateAttributeString(t)}>${e}</tr>`}toJSON(){return Object.assign(Object.assign({},super.toJSON()),{type:this.type,children:this.children.map((t=>t.toJSON()))})}}class H extends t{constructor({backgroundColor:t,padding:e,border:s,width:n,height:r,textAlign:o,verticalAlign:i,minWidth:a,boxSizing:l}={},c=!0){super(),this.type=m.CELL,this.useInternalStyle=c,this.backgroundColor=t,this.width=n,this.height=r,this.border=c&&void 0===s?H.DEFAULT_BORDER:s,this.padding=c&&void 0===e?H.DEFAULT_PADDING:e,this.textAlign=c&&void 0===o?H.DEFAULT_HORIZONTAL_TEXT_ALIGN:o,this.verticalAlign=c&&void 0===i?H.DEFAULT_VERTICAL_TEXT_ALIGN:i,this.minWidth=c&&void 0===a?H.DEFAULT_CELL_MIN_WIDTH:a,this.boxSizing=c&&void 0===l?H.DEFAULT_BOX_SIZING:l}static from(t,e){return[m.CELL,new H(t,e)]}static getDefaultStyles(t=!0){return{padding:H.DEFAULT_PADDING,textAlign:H.DEFAULT_HORIZONTAL_TEXT_ALIGN,verticalAlign:H.DEFAULT_VERTICAL_TEXT_ALIGN,minWidth:H.DEFAULT_CELL_MIN_WIDTH,boxSizing:H.DEFAULT_BOX_SIZING,border:`${H.DEFAULT_BORDER.style} ${H.DEFAULT_BORDER.width} ${t?H.DEFAULT_BORDER.color:H.DEFAULT_BORDER_RGB_COLOR}`}}get borderStr(){return this.border?`${this.border.style||""} ${this.border.width||""} ${this.borderColorAnnotation.renderStyle().color}`.trim():null}set backgroundColor(t){this._backgroundColor=t,this.backgroundColorAnnotation=new O(t)}get backgroundColor(){return this._backgroundColor}set border(t){this._border=t,this.borderColorAnnotation=new O(null==t?void 0:t.color)}get border(){return this._border}clone(){return new H({backgroundColor:this.backgroundColor,padding:this.padding,border:this.border,width:this.width,height:this.height,textAlign:this.textAlign,verticalAlign:this.verticalAlign,minWidth:this.minWidth,boxSizing:this.boxSizing},this.useInternalStyle)}toJSON(){return{tableCell:a({backgroundColor:this.backgroundColor,padding:this.padding,border:this.border,width:this.width,height:this.height,textAlign:this.textAlign,verticalAlign:this.verticalAlign,minWidth:this.minWidth,boxSizing:this.boxSizing})}}renderStyle(t){const e=this.backgroundColorAnnotation.renderStyle().color,s={padding:this.padding,border:this.borderStr,width:this.width,height:this.height,textAlign:this.textAlign,verticalAlign:this.verticalAlign,minWidth:this.minWidth,boxSizing:this.boxSizing};return e&&(s.backgroundColor=e),a((null==t?void 0:t.standalone)?s:this.removeDefaultValues(s),{cleanEmptyString:!0})}renderClass(){return null}removeDefaultValues(t){const e=Object.assign({},t);return e.padding===H.DEFAULT_PADDING&&delete e.padding,e.border===`${H.DEFAULT_BORDER.style} ${H.DEFAULT_BORDER.width} ${H.DEFAULT_BORDER.color}`&&delete e.border,e.textAlign===H.DEFAULT_HORIZONTAL_TEXT_ALIGN&&delete e.textAlign,e.verticalAlign===H.DEFAULT_VERTICAL_TEXT_ALIGN&&delete e.verticalAlign,e.minWidth===H.DEFAULT_CELL_MIN_WIDTH&&delete e.minWidth,e.boxSizing===H.DEFAULT_BOX_SIZING&&delete e.boxSizing,e}}H.DEFAULT_PADDING="12px",H.DEFAULT_BORDER={style:"solid",width:"1px",color:"#ddd"},H.DEFAULT_BORDER_RGB_COLOR="rgb(221, 221, 221)",H.DEFAULT_HORIZONTAL_TEXT_ALIGN="left",H.DEFAULT_VERTICAL_TEXT_ALIGN="middle",H.DEFAULT_CELL_MIN_WIDTH="55px",H.DEFAULT_BOX_SIZING="border-box";class RTETableCellBlock extends e{constructor(t,e){super(t),this.type="table-cell",this.children=[];const{autoMatchFormat:s}=e||{autoMatchFormat:!0};s&&this.annotationMap.set(m.CELL,new H)}static from(t,e){var s;const n=new RTETableCellBlock(t.id,e);return super.convertAnnotationsToMap(n.annotationMap,Object.assign({},t.annotations)),(null===(s=t.annotations)||void 0===s?void 0:s.tableCell)&&n.annotationMap.set(...H.from(t.annotations.tableCell,null==e?void 0:e.autoMatchFormat)),n.children=super.generateBlockChildren(t.children,e,n),n}clone(t){const e=new RTETableCellBlock(this.id);return e.children=this.children.map((t=>t.clone(e))),e.parent=t,e.annotationMap=super.cloneAnnotations(),e}getLastNode(){return this.children[this.children.length-1].getLastNode()}isNotEmpty(){return this.children.length>0}get rowSpan(){const t=this.getCustomAttributeByName("rowspan");return isNaN(Number(t))?1:Math.max(Number(t),1)}get colSpan(){const t=this.getCustomAttributeByName("colspan");return isNaN(Number(t))?1:Math.max(Number(t),1)}toHtml(t){const e=this.children.map((e=>e.toHtml(t))).join("");return`<td${super.generateAttributeString(t)}>${e}</td>`}toJSON(){return Object.assign(Object.assign({},super.toJSON()),{type:this.type,children:this.children.map((t=>t.toJSON()))})}getCustomAttributeByName(t){const e=this.getCustomAttributesAnnotation();if(e)return(e.toJSON().customAttribute||{})[t]}}class j extends H{constructor(t={},e=!0){super(t,e)}static from(t,e){return[m.CELL,new j(t,e)]}static getDefaultBackgroundColor(){return l.isDarkMode()?R.dark:R.light}clone(){return new j({backgroundColor:this.backgroundColor,padding:this.padding,border:this.border,width:this.width,height:this.height,textAlign:this.textAlign,verticalAlign:this.verticalAlign,minWidth:this.minWidth,boxSizing:this.boxSizing},this.useInternalStyle)}renderStyle(t){var e;const s=super.renderStyle(t);return a(Object.assign(Object.assign({},s),{backgroundColor:null!==(e=s.backgroundColor)&&void 0!==e?e:j.getDefaultBackgroundColor()}))}}class RTETableHeadCellBlock extends RTETableCellBlock{constructor(t,e){super(t,e),this.type="table-head-cell";const{autoMatchFormat:s}=e||{autoMatchFormat:!0};s&&this.annotationMap.set(m.CELL,new j)}static from(t,e){var s;const n=new RTETableHeadCellBlock(t.id,e);return super.convertAnnotationsToMap(n.annotationMap,Object.assign({},t.annotations)),(null===(s=t.annotations)||void 0===s?void 0:s.tableCell)&&n.annotationMap.set(...j.from(t.annotations.tableCell,null==e?void 0:e.autoMatchFormat)),n.children=super.generateBlockChildren(t.children,e,n),n}clone(t){const e=new RTETableHeadCellBlock(this.id);return e.children=this.children.map((t=>t.clone(e))),e.parent=t,e.annotationMap=super.cloneAnnotations(),e}toHtml(t){const e=this.children.map((e=>e.toHtml(t))).join("");return`<th${super.generateAttributeString(t)}>${e}</th>`}toJSON(){return Object.assign(Object.assign({},super.toJSON()),{type:this.type,children:this.children.map((t=>t.toJSON()))})}}const F="MERGE_CELLS";class $ extends s{constructor(t,e,s,n,r){super(),this.type="MERGE_CELLS",this.isFlushable=!0,this.targetCell=t,this.mergeCells=e,this.colSpan=s,this.rowSpan=n,this.direction=r}}var P,W;!function(t){t.MERGE_CELLS="MERGE_CELLS",t.MERGE_CELL_UP="MERGE_CELL_UP",t.MERGE_CELL_RIGHT="MERGE_CELL_RIGHT",t.MERGE_CELL_DOWN="MERGE_CELL_DOWN",t.MERGE_CELL_LEFT="MERGE_CELL_LEFT"}(P||(P={}));class G extends B{canHandle(t){return t[0]===k.MERGE_CELLS}execute(t,e){const s=e.tableSelection.getSelectedCells(),n=t[1];switch(n){case P.MERGE_CELL_UP:case P.MERGE_CELL_RIGHT:case P.MERGE_CELL_DOWN:case P.MERGE_CELL_LEFT:{const t=this.getDirectionMergeCells(n,s[0]);this.handleMergeCells(t,n)}break;default:s.length>1&&this.handleMergeCells(s,P.MERGE_CELLS)}}getDirectionMergeCells(t,e){const s=Q(e,t);if(!s)return[e];switch(t){case P.MERGE_CELL_UP:return[s,e];case P.MERGE_CELL_DOWN:return[e,s];case P.MERGE_CELL_LEFT:return[s,e];default:return[e,s]}}handleMergeCells(t,e){if(t.length<2)return;const s=tt(t),{minRow:n,maxRow:r,minCol:o,maxCol:i,targetCell:a}=s,l=new $(a,t,i-o+1,r-n+1,e);this.applyActionOnTable(l,a)}applyActionOnTable(t,e){const s=U(e,RTETableBlock);s&&s.apply(t)}}function U(t,e){return t?t instanceof e?t:U(t.parent,e):null}function V(t,e){return{id:E(),type:"table-body",children:Array.from({length:t},(()=>function(t){return{id:E(),type:"table-row",children:Array.from({length:t},(()=>Y("table-cell")))}}(e)))}}function J(t){return t.children.filter((t=>t instanceof RTETableBodyBlock||t instanceof RTETableHeadBlock)).flatMap((t=>t.children))}function K(t){if(!t||!t.children||!t.children[0])return null;const e=t.children[0];return e instanceof o?e:K(e)}function z(t,e){for(const s of t){const t=s.children.find((t=>t.id===e));if(t)return t}return null}function Y(t){const e=E();return{id:e,type:t,children:[{id:`${e}-p`,type:"paragraph",nodes:[{id:`${e}-p-t`,type:"text",text:""}]}]}}function X(t){return{colSpan:t.colSpan,rowSpan:t.rowSpan}}function Z(t,e,s){const n=null!=s?s:q(e);for(let e=0;e<n.length;e++){const s=n[e];for(let e=0;e<s.length;e++)if(s[e]===t.id)return e}return-1}function q(t){const e=[];return t.forEach(((t,s)=>{e[s]||(e[s]=[]);let n=0;t.children.forEach((t=>{const{colSpan:r,rowSpan:o}=X(t);for(;void 0!==e[s][n];)n++;for(let i=0;i<o;i++)for(let o=0;o<r;o++)e[s+i]||(e[s+i]=[]),e[s+i][n+o]=t.id;n+=r}))})),e}function Q(t,e){if(!t)return null;const s=t.parent,n=s.parent.children,r=n.indexOf(s),{colSpan:o,rowSpan:i}=X(t),a=Z(t,n);let l=r,c=a;switch(e){case P.MERGE_CELL_LEFT:c=a-1;break;case P.MERGE_CELL_RIGHT:c=a+o;break;case P.MERGE_CELL_UP:l=r-1;break;default:l=r+i}return function(t,e,s){const n=q(t);for(let r=0;r<t.length;r++){const o=t[r];for(const i of o.children){const{colSpan:o,rowSpan:a}=X(i),l=Z(i,t,n),c=r+a-1,h=l+o-1,u=s>=l&&s<=h;if(e>=r&&e<=c&&u)return i}}return null}(n,l,c)}function tt(t){const e=t[0].parent.parent.children,s=q(e);let n=Number.POSITIVE_INFINITY,r=-1,o=Number.POSITIVE_INFINITY,i=-1;const a=new Set;return t.forEach((t=>{const l=e.indexOf(t.parent),c=Z(t,e,s),{colSpan:h,rowSpan:u}=X(t),d=l,E=l+u-1,T=c,p=c+h-1;for(let t=d;t<=E;t++)for(let e=T;e<=p;e++)a.add(`${t},${e}`);n=Math.min(n,d),r=Math.max(r,E),o=Math.min(o,T),i=Math.max(i,p)})),{minRow:n,maxRow:r,minCol:o,maxCol:i,targetCell:t[0],coveredPositions:a}}function et(t){let e=0;const s=J(t)[0];for(const t of s.children){const{colSpan:s}=X(t);e+=s}return e}function st(t){if(1===t.length)return!0;const e=tt(t),{minRow:s,maxRow:n,minCol:r,maxCol:o,coveredPositions:i}=e;return i.size===(n-s+1)*(o-r+1)}function nt(t,e,s,o,i){const a=t.annotationMap.get(n.CUSTOM_ATTRIBUTE),l=a?Object.assign({},a.customAttribute):{};delete l.colspan,delete l.rowspan,e>1&&(l.colspan=String(e));const c=et(o)+(i?1:0);if(s>1&&e!==c&&(l.rowspan=String(s)),Object.keys(l).length>0){const e=new r(l);t.annotationMap.set(n.CUSTOM_ATTRIBUTE,e)}else t.annotationMap.delete(n.CUSTOM_ATTRIBUTE)}function rt(t){const e=Y(t);return"table-head-cell"===t?RTETableHeadCellBlock.from(e):RTETableCellBlock.from(e)}function ot(t,e,s){for(let n=0;n<s;n++){const s=t[n],r=e.children.find((t=>t.id===s));if(r&&!(r instanceof RTETableHeadCellBlock))return n}return-1}function it(t){const e=new Map;return t.forEach((t=>{for(let s=0;s<t.length;s++){const n=t[s];n&&!e.has(n)&&e.set(n,s)}})),e}function at(t,e,s,n){if(0===t.length)return[0,-1];const r=s||J(e),o=null!=n?n:q(r);let i=Number.POSITIVE_INFINITY,a=Number.NEGATIVE_INFINITY;return t.forEach((t=>{const e=Z(t,r,o);i=Math.min(i,e),a=Math.max(a,e)})),[i,a]}!function(t){t.HEADER_ROW="HEADER_ROW",t.ADD_ROW_ABOVE="ADD_ROW_ABOVE",t.ADD_ROW_BELOW="ADD_ROW_BELOW",t.DELETE_ROW="DELETE_ROW",t.SELECT_ROW="SELECT_ROW"}(W||(W={}));class lt extends B{canHandle(t){return t[0]===k.ROW}execute(t,e){const s=t[1];switch(s){case W.ADD_ROW_ABOVE:case W.ADD_ROW_BELOW:this.handleInsertRow(s,e);break;case W.DELETE_ROW:this.handleDeleteRow(e);break;case W.HEADER_ROW:this.handleToggleHeader(e);break;case W.SELECT_ROW:this.handleSelectRow(e)}}handleInsertRow(t,e){const s=this.getAllSelectedRows(e);if(s.length>0){const e=t===W.ADD_ROW_ABOVE?D.ABOVE:D.BELOW,n=e===D.ABOVE?s[0]:s[s.length-1],r=n.parent instanceof RTETableBodyBlock,o=this.shouldInsertHeaderRow(n,e)||r?new v(e,s):new N(e,s);this.applyActionToTable(s[0],o)}}shouldInsertHeaderRow(t,e){if(e===D.ABOVE)return t.parent instanceof RTETableHeadBlock;{const e=t.parent;return e instanceof RTETableHeadBlock&&e.children[e.children.length-1]!==t}}handleDeleteRow(t){const e=this.getAllSelectedRows(t);if(e.length){const t=new S(e);this.applyActionToTable(e[0],t)}}handleToggleHeader(t){const e=this.getAllSelectedRows(t);if(e.length>0){const t=new x(e);this.applyActionToTable(e[0],t)}}handleSelectRow(t){const e=this.getAllSelectedRows(t);if(e.length>0&&t&&t.tableSelection){const s=e.flatMap((t=>t.children));t.tableSelection.setSelectedCells(s)}}getAllSelectedRows(t){const e=new Set;if(t&&t.tableSelection){const{tableSelection:s}=t;s.getSelectedCells().forEach((t=>{const s=U(t,RTETableRowBlock);s&&e.add(s)}))}return Array.from(e)}applyActionToTable(t,e){const s=U(t,RTETableBlock);s&&s.apply(e)}}const ct="REPLACE_TABLE_CELL";class ht extends s{constructor(t){super(),this.isFlushable=!0,this.type="REPLACE_TABLE_CELL",this.payload=t}}const ut="SPLIT_TABLE_CELL";class dt extends s{constructor(t){super(),this.isFlushable=!0,this.type="SPLIT_TABLE_CELL",this.payload=t}}class Et extends i{getBoundaryCellColumnRange(t,e,s){let n=Number.POSITIVE_INFINITY,r=Number.NEGATIVE_INFINITY;return t.forEach((t=>{const o=Z(t,e,s);n=Math.min(n,o),r=Math.max(r,o)})),[n,r]}}class Tt extends Et{static isFullHeaderSelection(t){if(0===t.length)return!1;const e=U(t[0],RTETableBlock);if(e){const s=J(e),n=q(s),r=new Map;s.forEach((t=>{t.children.forEach((t=>r.set(t.id,t)))}));const[o,i]=at(t,e,s,n);for(const t of n)for(let e=o;e<=i;e++){const s=r.get(t[e]);if(s&&!(s instanceof RTETableHeadCellBlock))return!1}return!0}return!1}handleAction(t,e){const s=t.headerOn,n=J(e),r=q(n),[o,i]=this.getBoundaryCellColumnRange(t.tableCellHeaderRange,n,r);(s||!s&&o>0)&&this.toggleHeadRows(e,n,r,s,i,o),this.toggleBodyRows(e,n,r,s,o,i);const a=this.getRootContent(e);if(a&&t.tableCellHeaderRange[0].parent){const e=t.tableCellHeaderRange[0].parent.getFirstNode();e&&a.apply(new T(e,0))}}toggleHeadRows(t,e,s,n,r,o){var i;const a=((null===(i=t.children.find((t=>t instanceof RTETableHeadBlock)))||void 0===i?void 0:i.children)||[]).length;for(let i=0;i<a;i++)this.toggleCellType(t,e[i],s[i],0,n?r:o-1,(()=>!0),(t=>RTETableHeadCellBlock.from(t.toJSON())))}toggleBodyRows(t,e,s,n,r,o){var i;const a=s[0].length,l=(null===(i=t.children.find((t=>t instanceof RTETableBodyBlock)))||void 0===i?void 0:i.children)||[],c=e.length-l.length;for(let i=0;i<l.length;i++){const l=i+c,h=e[l],u=s[l],d=ot(u,h,a);n?d>-1&&this.toggleCellType(t,h,u,d,o,(t=>!(t instanceof RTETableHeadCellBlock)),(t=>RTETableHeadCellBlock.from(t.toJSON()))):this.toggleCellType(t,h,u,r,-1===d?a-1:d-1,(t=>t instanceof RTETableHeadCellBlock),(t=>RTETableCellBlock.from(t.toJSON())))}}toggleCellType(t,e,s,n,r,o,i){for(let a=n;a<=r;a++){const n=s[a],l=e.children.find((t=>t.id===n));if(l&&o(l)){const o=s.indexOf(n),c={table:t,cell:l,col:a,cellStartCol:o,endCol:r,targetCellType:i(l).type},h=o+l.colSpan-1;if(h>r||o<a){if(e.apply(new dt(c)),h>r)return;a=h;continue}e.apply(new ht(c))}l&&(a+=l.colSpan-1)}}}const pt="DELETE_TABLE_COLUMN";class bt extends s{constructor(t){super(),this.isFlushable=!0,this.type="DELETE_TABLE_COLUMN",this.tableCellDeleteRange=t}}const ft="INSERT_TABLE_COLUMN";var Ct;!function(t){t.LEFT="LEFT",t.RIGHT="RIGHT"}(Ct||(Ct={}));class Lt extends s{constructor(t,e){super(),this.isFlushable=!0,this.type="INSERT_TABLE_COLUMN",this.tableCellInsertRange=e,this.insertDirection=t}}const gt="SELECT_TABLE_COLUMN";class Rt extends s{constructor(t,e){super(),this.type="SELECT_TABLE_COLUMN",this.tableCellSelectRange=t,this.selectCellCallback=e}}const _t="TOGGLE_HEADER_TABLE_COLUMN";class Ot extends s{constructor(t,e){super(),this.isFlushable=!0,this.type="TOGGLE_HEADER_TABLE_COLUMN",this.headerOn=!1,this.tableCellHeaderRange=t,this.headerOn=e}}var mt;!function(t){t.HEADER_COLUMN="HEADER_COLUMN",t.ADD_COLUMN_LEFT="ADD_COLUMN_LEFT",t.ADD_COLUMN_RIGHT="ADD_COLUMN_RIGHT",t.DELETE_COLUMN="DELETE_COLUMN",t.SELECT_COLUMN="SELECT_COLUMN"}(mt||(mt={}));class kt extends B{canHandle(t){return t[0]===k.COLUMN}execute(t,e){const s=e.tableSelection.getSelectedCells();if(!s||0===s.length)return;const n=t[1];switch(n){case mt.ADD_COLUMN_LEFT:case mt.ADD_COLUMN_RIGHT:this.handleInsertColumn(n,s);break;case mt.DELETE_COLUMN:this.handleDeleteColumn(s);break;case mt.SELECT_COLUMN:this.handleSelectColumn(s,e);break;case mt.HEADER_COLUMN:this.handleToggleHeaderColumn(s)}}handleInsertColumn(t,e){const s=new Lt(t===mt.ADD_COLUMN_LEFT?Ct.LEFT:Ct.RIGHT,e);this.applyActionOnTable(s,e[0])}handleDeleteColumn(t){const e=new bt(t);this.applyActionOnTable(e,t[0])}handleSelectColumn(t,e){const s=new Rt(t,(t=>{e.tableSelection.setSelectedCells(t)}));this.applyActionOnTable(s,t[0])}handleToggleHeaderColumn(t){const e=!Tt.isFullHeaderSelection(t),s=new Ot(t,e);this.applyActionOnTable(s,t[0])}applyActionOnTable(t,e){const s=U(e,RTETableBlock);s&&s.apply(t)}}const At="SPLIT_CELL_HORIZONTALLY";class Bt extends s{constructor(){super(),this.isFlushable=!0,this.type="SPLIT_CELL_HORIZONTALLY"}}const wt="SPLIT_CELL_VERTICALLY";class St extends s{constructor(){super(),this.isFlushable=!0,this.type="SPLIT_CELL_VERTICALLY"}}var yt;!function(t){t.SPLIT_CELL_HORIZONTALLY="SPLIT_CELL_HORIZONTALLY",t.SPLIT_CELL_VERTICALLY="SPLIT_CELL_VERTICALLY"}(yt||(yt={}));class Nt extends B{canHandle(t){return t[0]===k.SPLIT_CELL}execute(t,e){const s=e.tableSelection.getSelectedCells();if(s&&1===s.length){const e=s[0];switch(t[1]){case yt.SPLIT_CELL_HORIZONTALLY:this.handleSplitCellHorizontally(e);break;case yt.SPLIT_CELL_VERTICALLY:this.handleSplitCellVertically(e)}}}handleSplitCellHorizontally(t){const e=new Bt;t.apply(e)}handleSplitCellVertically(t){const e=new St;t.apply(e)}}export{at as $,RTETableRowBlock as A,Z as B,kt as C,D,g as E,y as F,M as G,w as H,Ct as I,I as J,ft as K,pt as L,G as M,_t as N,Tt as O,ut as P,ct as Q,m as R,B as S,k as T,At as U,C as V,wt as W,gt as X,F as Y,L as Z,mt as _,R as a,W as a0,yt as a1,st as a2,Q as a3,A as b,H as c,RTETableHeadCellBlock as d,lt as e,Nt as f,_ as g,RTETableBlock as h,V as i,RTETableCellBlock as j,RTETableHeadBlock as k,RTETableBodyBlock as l,U as m,j as n,Et as o,J as p,q,z as r,nt as s,Y as t,it as u,et as v,K as w,X as x,rt as y,P as z}
|