@globalpayments/vega 2.59.0 → 2.60.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cjs/{app-globals-a8f5e755.js → app-globals-8a3536ba.js} +3 -3
- package/dist/cjs/{code-block-4bfae76d.js → code-block-7d901dfc.js} +1 -1
- package/dist/cjs/{component-value-history-controller-slimmer.abstract-34f4577a.js → component-value-history-controller-slimmer.abstract-d61e5129.js} +2 -2
- package/dist/cjs/{content-state-0da174e0.js → content-state-2096aa5a.js} +3 -3
- package/dist/cjs/{design-token-deb195e9.js → design-token-52f9da81.js} +3 -3
- package/dist/cjs/{element-appender-slimmer-299039f1.js → element-appender-slimmer-2a3e1e51.js} +2 -2
- package/dist/cjs/{image-annotation-action-117fee1f.js → image-annotation-action-8c1ecc99.js} +2 -2
- package/dist/cjs/index.cjs.js +8 -9
- package/dist/cjs/{inject-keyboard-manager-70382bae.js → inject-keyboard-manager-ad865c95.js} +1 -1
- package/dist/cjs/{keyboard-manager-6858915b.js → keyboard-manager-7f4e1f43.js} +1 -1
- package/dist/cjs/{keyboard-manager-slimmer-faca2038.js → keyboard-manager-slimmer-138a90e5.js} +1 -1
- package/dist/cjs/loader.cjs.js +6 -7
- package/dist/cjs/{public-rules-d1f7a352.js → public-rules-c711fae3.js} +4 -5
- package/dist/cjs/{responsive-format-facade-20c63e07.js → responsive-format-facade-3ab3b18c.js} +2 -2
- package/dist/cjs/{rich-text-editor-required-rule-fbf8cbab.js → rich-text-editor-required-rule-4d92437f.js} +1 -1
- package/dist/cjs/{state-background-color-formatter-c57409ea.js → state-background-color-formatter-aa5570f6.js} +1 -1
- package/dist/cjs/string-format-strategy.abstract-07a95352.js +60 -0
- package/dist/cjs/{string-input-formatter-slimmer-1b757bad.js → string-input-formatter-slimmer-941eaec2.js} +1 -224
- package/dist/cjs/string-mask-strategy-6bdad95e.js +172 -0
- package/dist/cjs/{style-formatter-e08163fd.js → style-formatter-dcb443fb.js} +2 -2
- package/dist/cjs/{type-guard-aa8fdeaf.js → type-guard-f12b5bae.js} +13 -3
- package/dist/cjs/{valid-credit-card-number-rule-4a1b00b8.js → valid-credit-card-number-rule-ce5c9147.js} +9 -9
- package/dist/cjs/vega-accordion.cjs.entry.js +6 -7
- package/dist/cjs/vega-app-header-button.cjs.entry.js +6 -7
- package/dist/cjs/vega-box.cjs.entry.js +7 -8
- package/dist/cjs/vega-button-circle.cjs.entry.js +6 -7
- package/dist/cjs/vega-button.cjs.entry.js +4 -5
- package/dist/cjs/vega-calendar_4.cjs.entry.js +14 -4
- package/dist/cjs/vega-card.cjs.entry.js +6 -7
- package/dist/cjs/vega-carousel.cjs.entry.js +4 -5
- package/dist/cjs/vega-chip.cjs.entry.js +6 -7
- package/dist/cjs/vega-code-block.cjs.entry.js +5 -6
- package/dist/cjs/vega-combo-box.cjs.entry.js +3 -4
- package/dist/cjs/vega-date-picker_2.cjs.entry.js +36 -11
- package/dist/cjs/vega-dialog_2.cjs.entry.js +6 -7
- package/dist/cjs/vega-divider.cjs.entry.js +6 -7
- package/dist/cjs/vega-dropdown_5.cjs.entry.js +7 -8
- package/dist/cjs/vega-env-manager-23b8b23c.js +2 -2
- package/dist/cjs/vega-flag-icon.cjs.entry.js +6 -7
- package/dist/cjs/vega-flex.cjs.entry.js +7 -8
- package/dist/cjs/vega-font.cjs.entry.js +6 -7
- package/dist/cjs/vega-grid.cjs.entry.js +6 -7
- package/dist/cjs/vega-icon.cjs.entry.js +6 -7
- package/dist/cjs/vega-image-uploader.cjs.entry.js +4 -5
- package/dist/cjs/vega-input-credit-card.cjs.entry.js +241 -12
- package/dist/cjs/vega-input-numeric.cjs.entry.js +3 -4
- package/dist/cjs/vega-input-phone-number.cjs.entry.js +110 -21
- package/dist/cjs/vega-input-select.cjs.entry.js +4 -5
- package/dist/cjs/vega-input.cjs.entry.js +16 -191
- package/dist/cjs/vega-left-nav_5.cjs.entry.js +6 -7
- package/dist/cjs/vega-loader-wrapper_2.cjs.entry.js +4 -5
- package/dist/cjs/vega-pagination.cjs.entry.js +4 -5
- package/dist/cjs/vega-popover_2.cjs.entry.js +9 -10
- package/dist/cjs/vega-radio_2.cjs.entry.js +3 -4
- package/dist/cjs/vega-rich-text-content.cjs.entry.js +4 -5
- package/dist/cjs/vega-rich-text-editor_4.cjs.entry.js +8 -9
- package/dist/cjs/vega-selection-chip_2.cjs.entry.js +4 -5
- package/dist/cjs/vega-sidenav_3.cjs.entry.js +4 -5
- package/dist/cjs/vega-signature-capture.cjs.entry.js +6 -7
- package/dist/cjs/vega-table_8.cjs.entry.js +4 -5
- package/dist/cjs/vega-time-picker_2.cjs.entry.js +7 -8
- package/dist/cjs/vega-tooltip_2.cjs.entry.js +7 -8
- package/dist/cjs/vega.cjs.js +6 -7
- package/dist/collection/components/vega-calendar/slimmers/month-view/renderers/vega-calendar-month-view-renderer.js +12 -1
- package/dist/collection/components/vega-date-picker/slimmers/renderers/vega-date-picker-calendar-renderer.js +11 -0
- package/dist/collection/components/vega-date-picker/vega-date-picker-calendar/vega-date-picker-calendar.css +4 -0
- package/dist/collection/components/vega-date-picker/vega-date-picker.js +43 -0
- package/dist/collection/components/vega-input/slimmers/controllers/vega-input-mask-config-controller.js +4 -11
- package/dist/collection/components/vega-input/vega-input.js +1 -1
- package/dist/collection/components/vega-input-credit-card/vega-input-credit-card.js +6 -3
- package/dist/collection/components/vega-input-phone-number/slimmers/renderers/phone-number-input-renderer.js +3 -16
- package/dist/collection/components/vega-rich-text-editor/slimmers/controllers/helper/element-to-dto-strategy/annotation-handler/link-annotation-handler.js +1 -1
- package/dist/collection/constants/card-config.js +4 -4
- package/dist/collection/helpers/formatter/string-formatter/credit-card-blur-mask-strategy.js +1 -1
- package/dist/collection/helpers/formatter/string-formatter/vega-phone-number-input-strategy.js +104 -0
- package/dist/collection/helpers/formatter/test/string-formatter/vega-phone-number-input-strategy.test.js +43 -0
- package/dist/esm/{app-globals-eec29b87.js → app-globals-c7699395.js} +3 -3
- package/dist/esm/{code-block-3d519665.js → code-block-055cae13.js} +1 -1
- package/dist/esm/{component-value-history-controller-slimmer.abstract-8b5be007.js → component-value-history-controller-slimmer.abstract-7a64c05a.js} +2 -2
- package/dist/esm/{content-state-100d1efd.js → content-state-460f6254.js} +3 -3
- package/dist/esm/{design-token-80dd7d60.js → design-token-e1821e4a.js} +3 -3
- package/dist/esm/{element-appender-slimmer-e2d3e79a.js → element-appender-slimmer-4260c020.js} +2 -2
- package/dist/esm/{image-annotation-action-215f92d6.js → image-annotation-action-95cc9118.js} +2 -2
- package/dist/esm/index.js +8 -9
- package/dist/esm/{inject-keyboard-manager-a28dfee4.js → inject-keyboard-manager-109817bf.js} +1 -1
- package/dist/esm/{keyboard-manager-fa6355cb.js → keyboard-manager-ab521d22.js} +1 -1
- package/dist/esm/{keyboard-manager-slimmer-818050ee.js → keyboard-manager-slimmer-cae3a002.js} +1 -1
- package/dist/esm/loader.js +6 -7
- package/dist/esm/{public-rules-1016ce0c.js → public-rules-71e1883d.js} +4 -5
- package/dist/esm/{responsive-format-facade-4bf60125.js → responsive-format-facade-dbeffcd6.js} +2 -2
- package/dist/esm/{rich-text-editor-required-rule-423c3c83.js → rich-text-editor-required-rule-6cfdcaaf.js} +1 -1
- package/dist/esm/{state-background-color-formatter-da5e76e8.js → state-background-color-formatter-0f01d27a.js} +1 -1
- package/dist/esm/string-format-strategy.abstract-452f4398.js +58 -0
- package/dist/esm/{string-input-formatter-slimmer-b144e8d7.js → string-input-formatter-slimmer-6d99bb4f.js} +2 -223
- package/dist/esm/string-mask-strategy-6232a1c1.js +170 -0
- package/dist/esm/{style-formatter-184752b5.js → style-formatter-41ca4df2.js} +2 -2
- package/dist/esm/{type-guard-84b1f192.js → type-guard-12f7654b.js} +8 -2
- package/dist/esm/{valid-credit-card-number-rule-cc497bec.js → valid-credit-card-number-rule-81443274.js} +1 -1
- package/dist/esm/vega-accordion.entry.js +6 -7
- package/dist/esm/vega-app-header-button.entry.js +6 -7
- package/dist/esm/vega-box.entry.js +7 -8
- package/dist/esm/vega-button-circle.entry.js +6 -7
- package/dist/esm/vega-button.entry.js +4 -5
- package/dist/esm/vega-calendar_4.entry.js +14 -4
- package/dist/esm/vega-card.entry.js +6 -7
- package/dist/esm/vega-carousel.entry.js +4 -5
- package/dist/esm/vega-chip.entry.js +6 -7
- package/dist/esm/vega-code-block.entry.js +5 -6
- package/dist/esm/vega-combo-box.entry.js +3 -4
- package/dist/esm/vega-date-picker_2.entry.js +35 -10
- package/dist/esm/vega-dialog_2.entry.js +6 -7
- package/dist/esm/vega-divider.entry.js +6 -7
- package/dist/esm/vega-dropdown_5.entry.js +7 -8
- package/dist/esm/vega-env-manager-8f8dc473.js +2 -2
- package/dist/esm/vega-flag-icon.entry.js +6 -7
- package/dist/esm/vega-flex.entry.js +7 -8
- package/dist/esm/vega-font.entry.js +6 -7
- package/dist/esm/vega-grid.entry.js +6 -7
- package/dist/esm/vega-icon.entry.js +6 -7
- package/dist/esm/vega-image-uploader.entry.js +4 -5
- package/dist/esm/vega-input-credit-card.entry.js +240 -11
- package/dist/esm/vega-input-numeric.entry.js +3 -4
- package/dist/esm/vega-input-phone-number.entry.js +110 -21
- package/dist/esm/vega-input-select.entry.js +4 -5
- package/dist/esm/vega-input.entry.js +10 -185
- package/dist/esm/vega-left-nav_5.entry.js +6 -7
- package/dist/esm/vega-loader-wrapper_2.entry.js +4 -5
- package/dist/esm/vega-pagination.entry.js +4 -5
- package/dist/esm/vega-popover_2.entry.js +9 -10
- package/dist/esm/vega-radio_2.entry.js +3 -4
- package/dist/esm/vega-rich-text-content.entry.js +4 -5
- package/dist/esm/vega-rich-text-editor_4.entry.js +8 -9
- package/dist/esm/vega-selection-chip_2.entry.js +4 -5
- package/dist/esm/vega-sidenav_3.entry.js +4 -5
- package/dist/esm/vega-signature-capture.entry.js +6 -7
- package/dist/esm/vega-table_8.entry.js +4 -5
- package/dist/esm/vega-time-picker_2.entry.js +7 -8
- package/dist/esm/vega-tooltip_2.entry.js +7 -8
- package/dist/esm/vega.js +6 -7
- package/dist/types/components/vega-calendar/slimmers/month-view/renderers/vega-calendar-month-view-renderer.d.ts +1 -0
- package/dist/types/components/vega-date-picker/slimmers/renderers/vega-date-picker-calendar-renderer.d.ts +1 -0
- package/dist/types/components/vega-date-picker/vega-date-picker.d.ts +14 -0
- package/dist/types/components/vega-input/types.d.ts +3 -10
- package/dist/types/components.d.ts +14 -0
- package/dist/types/helpers/formatter/string-formatter/vega-phone-number-input-strategy.d.ts +49 -0
- package/dist/types/helpers/formatter/test/string-formatter/vega-phone-number-input-strategy.test.d.ts +1 -0
- package/dist/vega/index.esm.js +1 -1
- package/dist/vega/p-0dcec258.js +1 -0
- package/dist/vega/p-10063072.entry.js +1 -0
- package/dist/vega/p-1152850b.entry.js +1 -0
- package/dist/vega/p-165054fb.entry.js +1 -0
- package/dist/vega/p-1652cfc6.entry.js +1 -0
- package/dist/vega/p-16c6c22f.entry.js +1 -0
- package/dist/vega/p-1852ca80.entry.js +1 -0
- package/dist/vega/p-1b222c94.entry.js +1 -0
- package/dist/vega/p-1b91a882.js +1 -0
- package/dist/vega/{p-86f17433.js → p-1cabeb33.js} +1 -1
- package/dist/vega/p-1f8c46c4.entry.js +1 -0
- package/dist/vega/p-1fdf0f74.entry.js +1 -0
- package/dist/vega/{p-7934c09c.js → p-200ba358.js} +1 -1
- package/dist/vega/p-20b8b626.entry.js +1 -0
- package/dist/vega/{p-0fce930c.js → p-21873037.js} +1 -1
- package/dist/vega/{p-b40adb9e.js → p-2608b9fe.js} +1 -1
- package/dist/vega/{p-0f0baac3.js → p-27dfa896.js} +1 -1
- package/dist/vega/p-2e4bc8aa.entry.js +1 -0
- package/dist/vega/p-334e31a3.entry.js +1 -0
- package/dist/vega/p-394dfa02.entry.js +1 -0
- package/dist/vega/p-433ea113.entry.js +1 -0
- package/dist/vega/p-460bbd22.entry.js +1 -0
- package/dist/vega/p-46973cf9.entry.js +1 -0
- package/dist/vega/p-52c1dde9.entry.js +1 -0
- package/dist/vega/p-594ecdab.js +1 -0
- package/dist/vega/p-5f377954.js +1 -1
- package/dist/vega/p-62898294.entry.js +1 -0
- package/dist/vega/p-636f7b17.entry.js +1 -0
- package/dist/vega/p-68eae19d.entry.js +1 -0
- package/dist/vega/p-69119f58.entry.js +1 -0
- package/dist/vega/p-6b71d5d1.entry.js +1 -0
- package/dist/vega/p-71f9c4d4.js +1 -0
- package/dist/vega/{p-59e990c7.entry.js → p-741a8b61.entry.js} +1 -1
- package/dist/vega/{p-436f7e27.js → p-743c5baf.js} +1 -1
- package/dist/vega/{p-09d63c0c.js → p-7e4fdccb.js} +1 -1
- package/dist/vega/p-824a06ba.js +1 -0
- package/dist/vega/{p-a6dacccd.js → p-8539e05e.js} +1 -1
- package/dist/vega/p-867a4970.js +1 -0
- package/dist/vega/{p-7bb74931.js → p-95ac7c7e.js} +1 -1
- package/dist/vega/p-95c30aed.entry.js +1 -0
- package/dist/vega/{p-6f90d444.js → p-9ce249a9.js} +1 -1
- package/dist/vega/{p-16ec4633.js → p-a433fef4.js} +1 -1
- package/dist/vega/p-af2de012.entry.js +1 -0
- package/dist/vega/p-b1faebe0.js +1 -0
- package/dist/vega/p-b56e2c89.entry.js +1 -0
- package/dist/vega/p-b8f50c69.entry.js +1 -0
- package/dist/vega/p-b9821a7f.entry.js +1 -0
- package/dist/vega/p-c883bce1.entry.js +1 -0
- package/dist/vega/p-cc2ceaa8.entry.js +1 -0
- package/dist/vega/{p-7f087c8b.js → p-d1ebec08.js} +1 -1
- package/dist/vega/{p-fc8badd3.entry.js → p-d35243c8.entry.js} +1 -1
- package/dist/vega/p-dbe5daa7.js +1 -0
- package/dist/vega/p-dd6a4ea6.entry.js +1 -0
- package/dist/vega/p-e3bb1cce.entry.js +13 -0
- package/dist/vega/p-e45f8a67.entry.js +1 -0
- package/dist/vega/p-e4fbd2b7.entry.js +1 -0
- package/dist/vega/p-eaa43f31.entry.js +1 -0
- package/dist/vega/p-ed50233f.entry.js +1 -0
- package/dist/vega/p-f1a2658b.entry.js +1 -0
- package/dist/vega/p-fc4c5265.entry.js +1 -0
- package/dist/vega/vega.esm.js +1 -1
- package/package.json +4 -3
- package/dist/cjs/card-config-2ee5505e.js +0 -65
- package/dist/cjs/regex-c1f70fd4.js +0 -15
- package/dist/esm/card-config-d2ad484e.js +0 -63
- package/dist/esm/regex-dfe11abf.js +0 -8
- package/dist/vega/p-0a2ff1e2.js +0 -1
- package/dist/vega/p-0b2fef0d.entry.js +0 -1
- package/dist/vega/p-11663b1c.js +0 -1
- package/dist/vega/p-18711f87.entry.js +0 -1
- package/dist/vega/p-19aa2dbe.entry.js +0 -1
- package/dist/vega/p-23f0dfeb.entry.js +0 -1
- package/dist/vega/p-2cc8e5f0.entry.js +0 -1
- package/dist/vega/p-323d2af0.entry.js +0 -1
- package/dist/vega/p-33f45d1b.entry.js +0 -1
- package/dist/vega/p-35a3c0e5.entry.js +0 -1
- package/dist/vega/p-3a0a4d15.js +0 -1
- package/dist/vega/p-3ce966b2.entry.js +0 -1
- package/dist/vega/p-42632023.entry.js +0 -1
- package/dist/vega/p-4452e085.js +0 -1
- package/dist/vega/p-49fd1009.js +0 -1
- package/dist/vega/p-4ca12302.entry.js +0 -13
- package/dist/vega/p-4ee21459.entry.js +0 -1
- package/dist/vega/p-4fb159d5.js +0 -1
- package/dist/vega/p-53d67971.entry.js +0 -1
- package/dist/vega/p-55b4b6ff.entry.js +0 -1
- package/dist/vega/p-56290b7e.entry.js +0 -1
- package/dist/vega/p-57ea996e.entry.js +0 -1
- package/dist/vega/p-5b7d347a.js +0 -1
- package/dist/vega/p-5e2c9e69.js +0 -1
- package/dist/vega/p-6a24c2d9.entry.js +0 -1
- package/dist/vega/p-6e42d500.entry.js +0 -1
- package/dist/vega/p-778b1d71.entry.js +0 -1
- package/dist/vega/p-7b1bb372.entry.js +0 -1
- package/dist/vega/p-7b365345.entry.js +0 -1
- package/dist/vega/p-801cb489.entry.js +0 -1
- package/dist/vega/p-80aac6eb.entry.js +0 -1
- package/dist/vega/p-966a9940.entry.js +0 -1
- package/dist/vega/p-a0954e7c.entry.js +0 -1
- package/dist/vega/p-aeea4154.entry.js +0 -1
- package/dist/vega/p-b6f78c1e.entry.js +0 -1
- package/dist/vega/p-c131544b.entry.js +0 -1
- package/dist/vega/p-cc20f01f.entry.js +0 -1
- package/dist/vega/p-d590402d.entry.js +0 -1
- package/dist/vega/p-d7558ed7.entry.js +0 -1
- package/dist/vega/p-d8566958.entry.js +0 -1
- package/dist/vega/p-e4674c00.entry.js +0 -1
- package/dist/vega/p-e9d2e0dc.entry.js +0 -1
- package/dist/vega/p-ee1e7389.entry.js +0 -1
- package/dist/vega/p-f993bcca.entry.js +0 -1
- package/dist/vega/p-ffaee583.entry.js +0 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
import{h as e,F as t,f as n,r as i,c as r,H as o,g as a}from"./p-48a58baf.js";import{s}from"./p-519a7d55.js";import{c as l,V as d,M as c,L as h,I as v}from"./p-6e1ab235.js";import{V as p,I as f}from"./p-d849e0f5.js";import{D as w}from"./p-0cd89fb6.js";import{a as m,f as u,b as g,N as b,d as x,g as y,h as k,i as C}from"./p-b5822a21.js";import{V as R}from"./p-f08a4adf.js";import{p as j}from"./p-08835909.js";import{c as D}from"./p-4474bc63.js";import{V as E}from"./p-bf0ced3c.js";import{s as z}from"./p-49fd1009.js";import{q as M}from"./p-5e2c9e69.js";import{C as O}from"./p-bbb96a13.js";import{v as P,w as I,x as S}from"./p-b5bef48a.js";import{c as $}from"./p-86194314.js";import{O as T}from"./p-331a62d5.js";import{C as V}from"./p-2d0d575f.js";import{m as L}from"./p-8a877e12.js";import{f as B}from"./p-d27ae9ff.js";import{g as N}from"./p-a4670e23.js";import{P as A}from"./p-7d9cd9c8.js";import{d as F}from"./p-1bc5b3bc.js";import{c as W}from"./p-9773c913.js";import{T as _}from"./p-02b29c18.js";import{s as H}from"./p-6bd5c49b.js";import{S as U}from"./p-1bd516c5.js";import{b as Y}from"./p-0c667d6a.js";import"./p-575235c8.js";import"./p-8c46e116.js";import"./p-6a334573.js";import"./p-af464251.js";import"./p-b75ee3ba.js";import"./p-ed45b3b6.js";import"./p-74168615.js";import"./p-3a0a4d15.js";import"./p-d884c644.js";import"./p-5f377954.js";import"./p-e77a83e4.js";import"./p-db8cdba6.js";import"./p-112455b1.js";import"./p-262ec334.js";var q=function(e,t,n,i){var r,o=arguments.length,a=o<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,n,i);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,n,a):r(t,n))||a);return o>3&&a&&Object.defineProperty(t,n,a),a};class K extends d{getEventPreviewRef(){return this.eventPreviewRef}render(){return e(t,null,this.switchPanelRenderer.render(),this.viewRenderer.render(),e("vega-calendar-event-preview",{ref:e=>{this.eventPreviewRef=e}}))}}q([l()],K.prototype,"host",void 0),q([l()],K.prototype,"switchPanelRenderer",void 0),q([l()],K.prototype,"viewRenderer",void 0);var X=function(e,t,n,i){var r,o=arguments.length,a=o<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,n,i);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,n,a):r(t,n))||a);return o>3&&a&&Object.defineProperty(t,n,a),a};class Z extends d{constructor(){super(...arguments),this.handleViewChange=e=>{this.currentPeriodController.updateCalendarPeriod(e.detail,this.postOperationDate)},this.todayButtonClick=()=>{this.currentPeriodController.setCurrentPeriod(this.currentPeriod.now())},this.nextButtonClick=()=>{this.currentPeriodController.setCurrentPeriod(this.currentPeriod.next())},this.prevButtonClick=()=>{this.currentPeriodController.setCurrentPeriod(this.currentPeriod.previous())},this.moreActionMenuClick=e=>{this.moreActionClickEmitter.emit(e.detail)}}getSwitchPanelRef(){return this.switchPanelRef}render(){return e("vega-flex",{direction:"row",gap:"size-16",justifyContent:"space-between",alignItems:"center",class:"calendar-switch-panel",ref:e=>this.switchPanelRef=e},this.renderDateSwitch(),e("div",{class:"calendar-view-switch-container"},this.showSwitchView?this.renderViewSwitch():null,this.renderMoreActionMenu()))}renderDateSwitch(){return e("div",{class:"calendar-date-switch-container"},e("vega-button",{variant:"secondary",size:"small",ref:e=>{w.addUniqueObserverToNode(e,m,this.todayButtonClick)},label:this.translationSlimmer.t("Today")}),e("vega-button-circle",{variant:"secondary",size:"small",icon:R.getIconKey("chevron-left"),label:"previous",showTooltip:!1,ref:e=>{w.addUniqueObserverToNode(e,m,this.prevButtonClick)}}),e("vega-button-circle",{variant:"secondary",size:"small",icon:R.getIconKey("chevron-right"),label:"next",showTooltip:!1,ref:e=>{w.addUniqueObserverToNode(e,m,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:Z.views.map((e=>Object.assign(Object.assign({},e),{text:this.translationSlimmer.t(e.text)}))),size:"small",variant:"text-only",selected:this.viewMode,ref:e=>{w.addUniqueObserverToNode(e,u,this.handleViewChange)}})}renderMoreActionMenu(){var t,n;if(null===(n=null===(t=this.moreActionDropdownProps)||void 0===t?void 0:t.source)||void 0===n?void 0:n.length)return e("vega-dropdown",Object.assign({alignment:"end",trigger:"click"},this.moreActionDropdownProps,{ref:e=>{w.addUniqueObserverToNode(e,g,this.moreActionMenuClick)}}),e("vega-button-circle",{size:"small",icon:R.getIconKey("ellipsis-vertical"),variant:"icon-only"}))}getViewDateSummary(){const e=this.currentPeriod.current;let t="";switch(this.viewMode){case"day":{const n=this.translationSlimmer.t(e.getMonthName());t=`${e.date} ${n}, ${e.year}`;break}case"week":{const e=this.calendarView.dateItems[0],n=e[0],i=e[e.length-1],[r,o]=[n,i].map((e=>this.translationSlimmer.t(e.getMonthName())));t=`${n.date} ${r}${n.year===i.year?"":", "+n.year} - ${i.date} ${o}, ${i.year}`;break}case"month":t=`${this.translationSlimmer.t(e.getMonthName())}, ${e.year}`}return t}}R.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>'}}),Z.views=[{text:"Day",key:"day"},{text:"Week",key:"week"},{text:"Month",key:"month"}],X([l()],Z.prototype,"viewMode",void 0),X([l()],Z.prototype,"calendarView",void 0),X([l()],Z.prototype,"currentPeriod",void 0),X([l()],Z.prototype,"moreActionDropdownProps",void 0),X([l()],Z.prototype,"moreActionClickEmitter",void 0),X([l()],Z.prototype,"currentPeriodController",void 0),X([l()],Z.prototype,"calendarViewController",void 0),X([l()],Z.prototype,"translationSlimmer",void 0),X([l()],Z.prototype,"postOperationDate",void 0),X([l()],Z.prototype,"showSwitchView",void 0);var G=function(e,t,n,i){var r,o=arguments.length,a=o<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,n,i);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,n,a):r(t,n))||a);return o>3&&a&&Object.defineProperty(t,n,a),a};class J extends d{getCalendarViewElementRef(){return this.calendarViewElementRef}render(){return e("div",{class:`calendar-view calendar-view-${this.viewMode} ${!1===this.showWeekends?"calendar-hide-weekends":""}`,ref:e=>this.calendarViewElementRef=e},"month"===this.viewMode?this.monthViewRenderer.render():this.viewWithTimeRenderer.render())}}G([l()],J.prototype,"viewMode",void 0),G([l()],J.prototype,"showWeekends",void 0),G([l()],J.prototype,"monthViewRenderer",void 0),G([l()],J.prototype,"viewWithTimeRenderer",void 0);var Q=function(e,t,n,i){var r,o=arguments.length,a=o<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,n,i);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,n,a):r(t,n))||a);return o>3&&a&&Object.defineProperty(t,n,a),a};class ee extends d{render(){return e("div",{class:"calendar-view-month-container"},e("div",{class:"calendar-view-row calendar-view-title border-divider-bottom"},this.calendarView.weekdays.map((t=>e("div",{key:t},this.translationSlimmer.t(t))))),this.renderMonthViewContent())}renderMonthViewContent(){const t=this.currentPeriod.current;return this.calendarView.dateItems.map(((n,i)=>{const r=this.monthEventRenderer.getCurrentRowEvents(n),o=this.monthEventRenderer.filterRowDisplayEvents(r);return e("div",{key:i,class:"calendar-view-row border-divider-bottom"},n.map(((n,i)=>{var a;const s=null===(a=this.isDateDisabled)||void 0===a?void 0:a.call(this,n.toDate());return e("div",{class:{"row-cell border-divider-right":!0,"current-month-day":n.compare(t).inMonth,active:n.isToday(),disabled:s},key:`${n.month}-${n.date}`,onDblClick:s?void 0:e=>{this.handleDateBlockClick(e,n)}},this.renderDateBlock(n),this.monthEventRenderer.render(n,r[i],o[i],i))})))}))}renderDateBlock(t){return e("div",{class:"date"},1===t.date&&e("div",{class:"month-block"},t.getMonthName(!0)),e("div",{role:"button",tabIndex:0,class:"grid-col",onDblClick:e=>this.goToCurrentDayView(e,t)},t.date))}goToCurrentDayView(e,t){e.stopPropagation(),this.currentPeriodController.updateCalendarPeriod("day",t)}handleDateBlockClick(e,t){const{target:n,clientX:i,clientY:r}=e;if(this.isMonthBlockBlankArea(n)){const{year:e,month:n,date:o}=t;this.dateDblClickEmitter.emit({year:e,month:n,date:o,hour:0,mouseEventInfo:{clientX:i,clientY:r}})}}isMonthBlockBlankArea(e){return!e.classList.contains("more-button")&&"VEGA-CALENDAR-EVENT"!==e.tagName}}Q([l()],ee.prototype,"viewMode",void 0),Q([l()],ee.prototype,"calendarView",void 0),Q([l()],ee.prototype,"currentPeriod",void 0),Q([l()],ee.prototype,"currentPeriodController",void 0),Q([l()],ee.prototype,"monthEventRenderer",void 0),Q([l()],ee.prototype,"dateDblClickEmitter",void 0),Q([l()],ee.prototype,"translationSlimmer",void 0),Q([l()],ee.prototype,"isDateDisabled",void 0);var te=function(e,t,n,i){var r,o=arguments.length,a=o<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,n,i);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,n,a):r(t,n))||a);return o>3&&a&&Object.defineProperty(t,n,a),a};class ne extends d{render(){return e("div",{class:"calendar-view-container"},this.renderViewTitle(),this.renderViewContent())}renderViewTitle(){const t=this.calendarView.dateItems[0],n=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,i)=>e("div",{key:t.date,class:{active:t.isToday()}},e("div",null,this.translationSlimmer.t(n[i])),e("div",{class:"week-day"},t.date)))))),e("div",{class:"calendar-view-row calendar-view-event-all-container border-divider-bottom"},e("div",{class:"time-line-all"},this.translationSlimmer.t("All Day")),this.dayViewFullDayEventRenderer.render()))}renderViewContent(){const t=this.calendarView.dateItems[0];return e("div",{class:"calendar-view-row calendar-view-day-container"},this.timeLineRenderer.render(),e("div",{class:"calendar-view-content-container"},e("div",{class:"calendar-view-content"},t.map((t=>{var n;const i=null===(n=this.isDateDisabled)||void 0===n?void 0:n.call(this,t.toDate());return e("div",{class:{"grid-col border-divider-left":!0,disabled:i},key:t.date},e("div",{class:"hour-empty border-divider-top"}),this.renderHourBlock(t,i))}))),this.dayViewTimedEventRenderer.render(),this.timeMarkerRenderer.render(t)))}renderHourBlock(t,n){return Array(24).fill("").map(((i,r)=>{var o;let a=!1;if(!n){const e=new Date(t.toDate().setHours(r));a=null===(o=this.isDateDisabled)||void 0===o?void 0:o.call(this,e)}return e("div",{class:{"grid-cell border-divider-top":!0,disabled:n||a},onDblClick:n||a?void 0:e=>this.handleDateBlockClick(t,r,e)})}))}handleDateBlockClick(e,t,n){const{year:i,month:r,date:o}=e,{clientX:a,clientY:s}=n;this.dateDblClickEmitter.emit({year:i,month:r,date:o,hour:t,mouseEventInfo:{clientX:a,clientY:s}})}}te([l()],ne.prototype,"viewMode",void 0),te([l()],ne.prototype,"timeLineRenderer",void 0),te([l()],ne.prototype,"timeMarkerRenderer",void 0),te([l()],ne.prototype,"dayViewTimedEventRenderer",void 0),te([l()],ne.prototype,"dayViewFullDayEventRenderer",void 0),te([l()],ne.prototype,"calendarView",void 0),te([l()],ne.prototype,"dateDblClickEmitter",void 0),te([l()],ne.prototype,"translationSlimmer",void 0),te([l()],ne.prototype,"isDateDisabled",void 0);class ie extends d{render(){const t=this.getTimeLineTitles();return e("div",{class:"time-line"},e("div",{class:"hour-empty"}),t.map(((t,n)=>e("div",{key:t},e("div",{class:"time-text","data-time":0===n?24:n},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(`${j(t)}`);return e}}!function(e,t,n,i){var r,o=arguments.length,a=o<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,n,i);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,n,a):r(t,n))||a);o>3&&a&&Object.defineProperty(t,n,a)}([l()],ie.prototype,"timeFormat",void 0);const re=(e=0)=>{const t=[0,1,2,3,4,5,6];return t.concat(t).slice(e,e+7)};var oe;!function(e){e.sun="Sunday",e.mon="Monday",e.tue="Tuesday",e.wed="Wednesday",e.thu="Thursday",e.fri="Friday",e.sat="Saturday"}(oe||(oe={}));const ae=(e,t)=>{const[n,i]=t.split(":");if("24-hour"===e)return`${n.padStart(2,"0")}:${i.padStart(2,"0")}`;{const e=Number(n),t=e>=12?"pm":"am",r=i.padStart(2,"0");return e>12?`${e-12}:${r} ${E.t("pm")}`:0===e?`12:${r} ${E.t("am")}`:`${e}:${r} ${E.t(t)}`}};class se{constructor(){this.WEEKDAYS_SHORT=["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],this.weekdays=re()}getWeekdayNames(){return this.WEEKDAYS_SHORT}generateDates(e){const t=e.startDate.toDate(),n=[];for(let i=0;i<e.count;i++)n.push(new Date(t)),t.setDate(t.getDate()+1);return n}generateWeekHead(){return this.weekdays.map((e=>this.getWeekdayNames()[e]))}}class le{constructor(e,t){this._weekdays=e,this._dateItems=t}get weekdays(){return this._weekdays}get dateItems(){return this._dateItems}}class de extends se{generate(e){return new le([this.generateWeekHead()[e.current.toDate().getDay()]],[[e.current]])}}class ce{constructor(e,t,n){this._date=n,this._month=t,this._year=e}static from(e){return new ce(e.getFullYear(),e.getMonth()+1,e.getDate())}get year(){return this._year}set year(e){this._year=e}get month(){return this._month}set month(e){this._month=e}get date(){return this._date}set date(e){this._date=e}isToday(){const e=new Date;return e.getFullYear()===this.year&&e.getMonth()+1===this.month&&e.getDate()===this.date}toDate(){return new Date(this.year,this.month-1,this.date)}compare(e){const{year:t,month:n}=e,i={isPreviousMonth:!1,inMonth:!1,isNextMonth:!1};return this.year===t?this.month<n?i.isPreviousMonth=!0:this.month>n?i.isNextMonth=!0:i.inMonth=!0:this.year>t?i.isNextMonth=!0:i.isPreviousMonth=!0,i}equal(e){const{year:t,month:n,date:i}=e;return this._year===t&&this._month===n&&this._date===i}getMonthName(e=!1){return E.t(this.toDate().toLocaleDateString("en-US",{month:e?"short":"long"}))}}class he extends se{generate(e){const t=this.generateDates(e),n=e.showWeekends;let i=this.generateWeekHead(),r=[t.map(ce.from)];return!1===n&&(i=i.slice(1,6),r=r.map((e=>e.slice(1,6)))),new le(i,r)}}class ve extends se{generate(e){const t=e.showWeekends;let n=[],i=[];this.generateDates(e).forEach(((e,t)=>{t%7||(n[t/7]=i=[]);const r=ce.from(e);i.push(r)}));let r=this.generateWeekHead();return!1===t&&(r=r.slice(1,6),n=n.map((e=>e.slice(1,6)))),new le(r,n)}}class pe{constructor(e,t){this._count=e,this._current=t||ce.from(new Date),this.calculatePeriod(this._current)}get current(){return this._current}get startDate(){return this._startDate}get endDate(){return this._endDate}get count(){return this._count}get type(){return this._type}get showWeekends(){return this._showWeekends}goTo(e){return this.createBy(e)}now(){return this.createBy(ce.from(new Date))}calculatePeriod(e){const t=e.toDate();this.count>1&&t.setDate(t.getDate()-re().indexOf(t.getDay())),this._startDate=ce.from(t),t.setDate(t.getDate()+this.count-1),this._endDate=ce.from(t)}}var fe;function we(e,t=15){const[n,i]=e.split(":");return Math.round((60*Number(n)+Number(i))/t)}function me(e){return"vega-calendar-event-slot-"+e}function ue(e,t=fe.NEXT){const n=e.toDate().getDay();if(0===n||6===n){let i=0===n?1:2;return t===fe.PREVIOUS&&(i=0===n?-2:-1),ce.from(new Date(e.year,e.month-1,e.date+i))}return e}function ge(e="bg-accent6-primary"){return M(e)?`.event-bg-color{${z.formatToken(e)}}`:`.event-bg-color{background-color:${e}}`}!function(e){e.PREVIOUS="-1",e.NEXT="1"}(fe||(fe={}));class be extends pe{constructor(e,t){super(be.DISPLAY_DATE_COUNT,e),this._type="day",this._showWeekends=!0,this._showWeekends=!1!==t}next(){const e=this.current.toDate();e.setDate(e.getDate()+1);let t=ce.from(e);return!1===this._showWeekends&&(t=ue(t)),this.createBy(t)}previous(){const e=this.current.toDate();e.setDate(e.getDate()-1);let t=ce.from(e);return!1===this._showWeekends&&(t=ue(t,fe.PREVIOUS)),this.createBy(t)}now(){let e=ce.from(new Date);return!1===this._showWeekends&&(e=ue(e)),this.createBy(e)}createBy(e){return new be(e,this._showWeekends)}}be.DISPLAY_DATE_COUNT=1;class xe extends pe{constructor(e,t){super(xe.DISPLAY_DATE_COUNT,e),this._type="week",this._showWeekends=!0,this._showWeekends=!1!==t}next(){const e=this.current.toDate();return e.setDate(e.getDate()+7),this.createBy(ce.from(e))}previous(){const e=this.current.toDate();return e.setDate(e.getDate()-7),this.createBy(ce.from(e))}createBy(e){return new xe(e,this._showWeekends)}}xe.DISPLAY_DATE_COUNT=7;class ye extends pe{constructor(e,t){super(ye.DISPLAY_DATE_COUNT,e),this._type="month",this._showWeekends=!0,this._showWeekends=!1!==t}static getMonthFirstDay(e){const t=e||ce.from(new Date);return new ce(t.year,t.month,1)}calculatePeriod(e){const t=ye.getMonthFirstDay(e).toDate();t.setDate(t.getDate()-re().indexOf(t.getDay())),this._startDate=ce.from(t),t.setDate(t.getDate()+this.count-1),this._endDate=ce.from(t)}next(){const e=this.current.toDate();return e.setMonth(e.getMonth()+1),this.createBy(ce.from(e))}previous(){const e=this.current.toDate();return e.setMonth(e.getMonth()-1),this.createBy(ce.from(e))}createBy(e){return new ye(e,this._showWeekends)}}ye.DISPLAY_DATE_COUNT=42;var ke=function(e,t,n,i){var r,o=arguments.length,a=o<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,n,i);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,n,a):r(t,n))||a);return o>3&&a&&Object.defineProperty(t,n,a),a};class Ce extends d{constructor(){super(...arguments),this.monthViewGenerator=new ve,this.weekViewGenerator=new he,this.dayViewGenerator=new de}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}}ke([l({writable:!0})],Ce.prototype,"calendarView",void 0),ke([l()],Ce.prototype,"currentPeriod",void 0),ke([l()],Ce.prototype,"showWeekends",void 0),ke([l()],Ce.prototype,"currentPeriodController",void 0),ke([c("componentWillLoad")],Ce.prototype,"initialCalendarView",null),ke([c("watchCurrentPeriodChange")],Ce.prototype,"generateCalendarView",null);var Re=function(e,t,n,i){var r,o=arguments.length,a=o<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,n,i);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,n,a):r(t,n))||a);return o>3&&a&&Object.defineProperty(t,n,a),a};class je extends d{setCurrentPeriod(e){this.currentPeriod=e}updateCalendarPeriod(e,t){switch(e){case"month":this.setCurrentPeriod(new ye(t,this.showWeekends));break;case"week":this.setCurrentPeriod(new xe(t,this.showWeekends));break;case"day":t=!1===this.showWeekends?ue(t):t,this.setCurrentPeriod(new be(t,this.showWeekends))}}initialCurrentPeriod(){this.updateCalendarPeriod(this.viewMode,ce.from(new Date))}emitChangeEvent(e,t){e&&t&&e.startDate.equal(t.startDate)&&e.endDate.equal(t.endDate)||(e&&e.type!==this.viewMode&&(this.viewMode=e.type),this.changeEventEmitter.emit({viewMode:e.type,currentPeriod:this.getCurrentPeriodSummary()}))}updateCurrentPeriodByViewMode(e){this.currentPeriod&&e!==this.currentPeriod.type&&this.updateCalendarPeriod(e,this.currentPeriod.current)}updateCurrentPeriodAfterHideWeekEndsChange(){this.updateCalendarPeriod(this.viewMode,this.currentPeriod.current)}getCurrentPeriodSummary(){const{current:e,startDate:t,endDate:n}=this.currentPeriod;return{year:e.year,month:e.month,startDate:{date:t.date,month:t.month,year:t.year},endDate:{date:n.date,month:n.month,year:n.year}}}}Re([l({writable:!0})],je.prototype,"currentPeriod",void 0),Re([l()],je.prototype,"changeEventEmitter",void 0),Re([l({writable:!0})],je.prototype,"viewMode",void 0),Re([l()],je.prototype,"showWeekends",void 0),Re([c("componentWillLoad")],je.prototype,"initialCurrentPeriod",null),Re([c("watchCurrentPeriodChange")],je.prototype,"emitChangeEvent",null),Re([c("watchViewModeChange")],je.prototype,"updateCurrentPeriodByViewMode",null),Re([c("watchShowWeekendsChange")],je.prototype,"updateCurrentPeriodAfterHideWeekEndsChange",null);var De=function(e,t,n,i){var r,o=arguments.length,a=o<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,n,i);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,n,a):r(t,n))||a);return o>3&&a&&Object.defineProperty(t,n,a),a};class Ee extends d{constructor(){super(...arguments),this.maxMonthDisplayEventsCount=2,this.popoverHideObserver=null}getCurrentRowEvents(e){const t=[];return e.forEach((e=>{const n=this.calendarEventController.getCurrentDateEvents(e);t.push(n)})),this.fullDayEventLayoutRenderer.sortLongEvents(t)}filterRowDisplayEvents(e){const t=[];return e.forEach((e=>{const n=e.length>this.maxMonthDisplayEventsCount?e.slice(0,this.maxMonthDisplayEventsCount-1):e;t.push(n)})),this.hideTheCutOffEvents(e,t)}getMonthEventContainerRef(){return this.eventContainerRef}render(t,n,i,r){const o=n.slice(i.length).filter((e=>e)).length;return e("div",{class:"events-container",ref:e=>this.eventContainerRef=e},e("div",{class:"event-list"},this.fullDayEventLayoutRenderer.render(i,r,t)),this.renderMoreButton(n,o,t))}addMaxDisplayCountChange(){w.addUniqueObserverToNode(this.host,P,(e=>{this.maxMonthDisplayEventsCount=e.detail,"month"===this.viewMode&&n(this.host)}))}renderMoreButton(t,n,i){if(n){const r=t.filter((e=>e&&(e.isAllDayEvent||e.isGroupEvent()))),o=t.filter((e=>e&&!e.isAllDayEvent&&!e.isGroupEvent()));return e("div",{class:"month-event-more"},e("vega-popover",{trigger:"click",placement:"right",padding:"0",ref:e=>{this.setPopoverHideObserver(e,t)},isScreenPosition:!0},e("div",{tabIndex:0,slot:"popover-content",role:"button",class:"more-button",onKeyDown:$()},`${n} 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"}},`${i.date} ${i.getMonthName()} ${i.year}`),e("vega-box",{maxHeight:"calc(60vh - 6px)",style:{overflowY:"auto"},padding:"size-4"},e("vega-flex",{direction:"col",gap:"size-4",style:{paddingBottom:o.length?"4px":"0px"}},r.map((e=>this.eventItemRenderer.render(e,{"month-event":!0,"calendar-event-large-size":!0,"calendar-event-in-popover":!0},i,!0)))),o.map((e=>this.eventItemRenderer.render(e,{"month-event":!0,"calendar-event-large-size":!0,"calendar-event-in-popover":!0},i,!0)))))),e("div",{class:"preview-container",ref:e=>{e?this.eventPreviewPopoverController.setEventPreviewContainerMap(t,i,e):this.eventPreviewPopoverController.deleteEventPreviewContainer(t,i)}}))))}}hideTheCutOffEvents(e,t){const n=[],i=[],r=t.map((e=>e[e.length-1])).filter((e=>e&&e.isGroupEvent()));return r.length&&r.forEach((n=>{e.filter((e=>e.includes(n))).length>t.filter((e=>e.includes(n))).length&&i.push(n)})),i.length?(t.forEach((e=>{e.length&&e[e.length-1]&&i.includes(e[e.length-1])?n.push(e.slice(0,e.length-1)):n.push(e)})),n):t}setPopoverHideObserver(e,t){e?(this.popoverHideObserver=new T((e=>t.includes(e)),(async()=>await e.hide())),V.register(L,this.popoverHideObserver)):this.popoverHideObserver&&V.unregister(L,this.popoverHideObserver),e&&w.addUniqueObserverToNode(e,b,(()=>{V.notify(x.getSubject(this.renderer.getEventPreviewRef(),I),{})}))}}De([l()],Ee.prototype,"viewMode",void 0),De([l()],Ee.prototype,"host",void 0),De([l()],Ee.prototype,"calendarEventController",void 0),De([l()],Ee.prototype,"eventItemRenderer",void 0),De([l()],Ee.prototype,"fullDayEventLayoutRenderer",void 0),De([l()],Ee.prototype,"eventPreviewPopoverRenderer",void 0),De([l()],Ee.prototype,"renderer",void 0),De([l()],Ee.prototype,"eventPreviewPopoverController",void 0),De([c("componentWillLoad")],Ee.prototype,"addMaxDisplayCountChange",null);class ze{constructor(e,t,n,i){this.repeatStartDate=e,this.interval=t,this.count=n,this.until=i}getRepeatSeries(e,t=1){return this.generateRepeatDateCacheUntilEndDate(e.endDate),this.cache.filter((n=>this.isSeriesInPeriod(n,t,e)))}isSeriesInPeriod(e,t,n){const i=e.toDate(),r=new Date(e.year,e.month-1,e.date+t-1),{startDate:o,endDate:a}=n,s=o.toDate(),l=a.toDate();return i>=s&&i<=l||r>=s&&r<=l||i<=s&&r>=l}generateRepeatEndsString(){return this.until?` ${E.t("until {0}",`${this.until.getMonthName()} ${this.until.date}, ${this.until.year}`)}`:this.count?` ${E.t("after {0} occurrences",this.count)}`:""}}ze.daySeconds=864e5;class Me extends ze{constructor(e,t,n,i){super(e,t,n,i),this.initCache()}generateRepeatString(){return(this.interval>1?E.t("Repeat every {0} days",this.interval):E.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 n=this.getNextRepeatStartDate(t);for(;n&&n.toDate()<e.toDate();){const e=this.getNextRepeatStartDate(n);if(e&&e.toDate()<=n.toDate()){this.cache.pop();break}if(n=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),n=ce.from(t);return this.until&&t>this.until.toDate()||"number"==typeof this.count&&this.cache.length>=this.count?null:(this.cache.push(n),n)}}class Oe extends ze{constructor(e,t,n,i){super(e,t,n,i),this.byMonthDay=this.repeatStartDate.date,this.initCache()}generateRepeatString(){return(this.interval>1?E.t("Repeat every {0} months on day {1}",this.interval,this.byMonthDay):E.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 n=this.getNextRepeatStartDate(t);for(;n&&n.toDate()<e.toDate();){const e=this.getNextRepeatStartDate(n);if(e&&e.toDate()<=n.toDate()){this.cache.pop();break}if(n=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),n=ce.from(t);return this.until&&t>this.until.toDate()||"number"==typeof this.count&&this.cache.length>=this.count?null:(this.cache.push(n),n)}getNextStartDate(e,t){const n=new Date(e,t,this.byMonthDay);return n.getDate()===this.byMonthDay?n:this.getNextStartDate(e,t+1)}}class Pe extends ze{constructor(e,t,n,i,r){super(e,t,n,i),this.byWeekDay=this.sortWeekDay(r),this.initCache()}getRepeatSeries(e,t=1){return this.generateRepeatDateCacheUntilEndDate(e.endDate),this.getValidCache().filter((n=>this.isSeriesInPeriod(n,t,e)))}generateRepeatString(){const e=this.byWeekDay.map((e=>E.t(oe[e])));return(this.interval>1?E.t("Repeat every {0} weeks on {1}",this.interval,e.join(", ")):E.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 n=this.getNextRepeatStartDate(t);for(;n&&n[0].toDate()<e.toDate();){const e=this.getNextRepeatStartDate(n);if(e&&e[0]&&e[0].toDate()<=n[0].toDate()){this.cache.pop();break}if(n=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=>ce.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((n=>{const i=Pe.weekDay.indexOf(n)-t,{year:r,month:o,date:a}=this.repeatStartDate,s=ce.from(new Date(r,o-1,a+i));e.push(s)})),this.cache=[e]}sortWeekDay(e){return e&&e.length?e.map((e=>e.toLocaleLowerCase())).sort(((e,t)=>Pe.weekDay.indexOf(e)-Pe.weekDay.indexOf(t))):[Pe.weekDay[this.getCurrentDayIndex(this.repeatStartDate)]]}getCurrentDayIndex(e){return e.toDate().getDay()}getValidCache(){const e=B(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)}}Pe.weekDay=["Sun","Mon","Tue","Wed","Thu","Fri","Sat"].map((e=>e.toLowerCase()));class Ie extends ze{constructor(e,t,n,i){super(e,t,n,i),this.matchDay=this.repeatStartDate.date,this.matchMonth=this.repeatStartDate.month,this.initCache()}generateRepeatString(){const e=E.t(this.repeatStartDate.getMonthName());return(this.interval>1?E.t("Repeat every {0} years on {1} {2}",this.interval,e,this.matchDay):E.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 n=this.getNextRepeatStartDate(t);for(;n&&n.toDate()<e.toDate();){const e=this.getNextRepeatStartDate(n);if(e&&e.toDate()<=n.toDate()){this.cache.pop();break}if(n=e,"number"==typeof this.count&&this.cache.length>=this.count)break}}}getNextRepeatStartDate(e){const t=this.getNextStartDate(e.year+this.interval),n=ce.from(t);return this.until&&t>this.until.toDate()||"number"==typeof this.count&&this.cache.length>=this.count?null:(this.cache.push(n),n)}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 Se=new class{getPattern(e,t){const n=ce.from(e),{frequency:i,interval:r=1,byWeekDay:o,until:a,count:s}=t,l=this.initDate(a);return this.initRepeatPattern(i,n,r<1?1:r,s,l,o)}initDate(e){if(e&&"object"==typeof e)return ce.from(e);if(e&&"string"==typeof e){const[t,n,i]=e.split("/");return new ce(Number(i),Number(t),Number(n))}}initRepeatPattern(e,t,n,i,r,o){switch(e){case"daily":return new Me(t,n,i,r);case"weekly":return new Pe(t,n,i,r,o);case"monthly":return new Oe(t,n,i,r);default:return new Ie(t,n,i,r)}}},$e=/^\d{1,2}\/\d{1,2}\/\d{4}/,Te=/^\d{1,2}:\d{1,2}/;class Ve{constructor(e,t){this._eventSpansDays=1,this.repeatPattern=null,this._event=e,this._eventKey=t||N(),this.checkEventRequireField(e),this.initDate(e),this.initEventSpansDays(),this.initRepeatPattern()}get event(){return this._event}get eventKey(){return this._eventKey}get title(){return this._event.title}get disabled(){return!!this._event.disabled}get variant(){return this._event.variant}get color(){return this._event.color}get isAllDayEvent(){return!!this._event.isAllDay}get isRepeatEvent(){return null!==this.repeatPattern}get startDate(){return this._startDate}get endDate(){return this._endDate}get startTime(){return this._startTime}get endTime(){return this._endTime}get eventSpansDays(){return this._eventSpansDays}copyTo(e,t){const n=this._eventSpansDays>1?new Date(t.year,t.month-1,t.date+(this._eventSpansDays-1)):t.toDate();return new Ve(Object.assign(Object.assign({},this._event),{startDate:t.toDate(),endDate:n,startTime:this.startTime,endTime:this.endTime}),e)}isGroupEvent(){return this._eventSpansDays>1}isCurrentDayEvent(e){const{startDate:t,endDate:n}=this,i=ce.from(t),r=ce.from(new Date(n.getFullYear(),n.getMonth(),n.getDate()+1)),o=e.toDate();return i.toDate()<=o&&r.toDate()>o}generateRepeatString(){var e;return(null===(e=this.repeatPattern)||void 0===e?void 0:e.generateRepeatString())||""}generateDateTimeString(e,t){const n=E.t(Object.values(oe)[e.toDate().getDay()]),i=ae(t,this.startTime),r=ae(t,this.endTime);return`${n}, ${e.date} ${e.getMonthName(!0)} ${e.year} ${i} - ${r}`}getEventDuration(){const[e,t]=this.startTime.split(":"),[n,i]=this.endTime.split(":"),r=ce.from(new Date),o=new Date(r.year,r.month,r.date,Number(e),Number(t));return(new Date(r.year,r.month,r.date,0===Number(n)&&0!==Number(e)?24:Number(n),Number(i)).valueOf()-o.valueOf())/6e4}getRepeatSeries(e){return this.repeatPattern?this.repeatPattern.getRepeatSeries(e,this._eventSpansDays):[]}convertTimeTo24Hour(e){if((e=e.toLocaleLowerCase()).indexOf("am")>0||e.indexOf("pm")>0){if(e.indexOf("am")>0){e=e.replace("am","").trim();const[t,n]=e.split(":");return`${"12"===t?"00":t}:${n}`}{e=e.replace("pm","").trim();const[t,n]=e.split(":");return`${"12"===t?"12":Number(t)+12}:${n}`}}return e}checkEventRequireField(e){const{title:t,startDate:n,endDate:i,startTime:r,endTime:o}=e;if(n&&"string"==typeof n&&!$e.test(n)||i&&"string"==typeof i&&!$e.test(i))throw new Error("Invalid calendar event item, the date format should be MM/DD/YYYY!");if(r&&"string"==typeof r&&!Te.test(r)||o&&"string"==typeof o&&!Te.test(o))throw new Error("Invalid calendar event item, the time format should be HH:mm!");if(!t||!n||!i&&!o)throw new Error("Invalid calendar event item, the required field should not empty!")}initDate(e){const{startDate:t,startTime:n,endDate:i,endTime:r}=e;if(t&&"object"==typeof t)this._startDate=t;else if(t&&"string"==typeof t){const[e,n,i]=t.split("/");this._startDate=new Date(Number(i),Number(e)-1,Number(n))}if(this._startTime=n?this.convertTimeTo24Hour(n):`${this._startDate.getHours()}:${this._startDate.getMinutes()}`,i&&"object"==typeof i)this._endDate=i;else if(i&&"string"==typeof i){const[e,t,n]=i.split("/");this._endDate=new Date(Number(n),Number(e)-1,Number(t),23,59,59)}else this._endDate=new Date(this._startDate.getFullYear(),this._startDate.getMonth(),this._startDate.getDate(),23,59,59);this._endTime=r?this.convertTimeTo24Hour(r):`${this._endDate.getHours()}:${this._endDate.getMinutes()}`}initRepeatPattern(){this._event.repeatOptions&&this._event.repeatOptions.frequency&&(this.repeatPattern=Se.getPattern(this._startDate,this._event.repeatOptions))}initEventSpansDays(){const e=ce.from(this.startDate),t=ce.from(this.endDate);this._eventSpansDays=(t.toDate().valueOf()-e.toDate().valueOf())/864e5+1}}var Le=function(e,t,n,i){var r,o=arguments.length,a=o<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,n,i);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,n,a):r(t,n))||a);return o>3&&a&&Object.defineProperty(t,n,a),a};class Be extends d{constructor(){super(...arguments),this.repeatEventMap=new Map}getCurrentDateEvents(e){return this.createRepeatEvents().filter((t=>t.isCurrentDayEvent(e)))}updateAfterEventChange(e){this.initCalendarEvents(e),this.repeatEventMap.clear()}updateWhenComponentWillLoad(){this.initCalendarEvents(this.events)}initCalendarEvents(e){const t=[];e&&e.forEach((e=>{try{const n=new Ve(e);t.push(n)}catch(t){h.warn("Invalid calendar event item:",e)}})),this.calendarEvents=t}createRepeatEvents(){const e=[],t=[];return this.calendarEvents.forEach((n=>{n.isRepeatEvent?n.getRepeatSeries(this.currentPeriod).forEach((e=>{t.push(this.generateCalendarEventByRepeatSeries(n,e))})):e.push(n)})),t.concat(e)}generateCalendarEventByRepeatSeries(e,t){const n=`${e.eventKey}-${t.year}${t.month}${t.date}`;if(this.repeatEventMap.has(n))return this.repeatEventMap.get(n);{const i=e.copyTo(n,t);return this.repeatEventMap.set(n,i),i}}}Le([l()],Be.prototype,"host",void 0),Le([l({writable:!0})],Be.prototype,"calendarEvents",void 0),Le([l()],Be.prototype,"currentPeriod",void 0),Le([l()],Be.prototype,"events",void 0),Le([c("watchEventsChange")],Be.prototype,"updateAfterEventChange",null),Le([c("componentWillLoad")],Be.prototype,"updateWhenComponentWillLoad",null);var Ne=function(e,t,n,i){var r,o=arguments.length,a=o<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,n,i);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,n,a):r(t,n))||a);return o>3&&a&&Object.defineProperty(t,n,a),a};class Ae extends d{render(t,n,i,r=!1){return e("vega-calendar-event",{"data-calendar-ref":this.host,key:t.eventKey,calendarEvent:t,class:n,onKeyDown:$(),onClick:()=>{this.handleEventClick(t),this.enabledEventPreview&&this.setupPreviewContainer(t,i,r)}},!t.isRepeatEvent&&e("slot",{name:me(t.event.key)}))}handleEventClick(e){this.eventClickEmitter.emit({rawEvent:e.event})}setupPreviewContainer(e,t,n){const i=this.eventPreviewPopoverController.getEventPreviewContainer(e,t,n);if(i){const r=this.renderer.getEventPreviewRef();n?(r.classList.remove("single-event-preview"),r.classList.add("group-event-preview")):(r.classList.remove("group-event-preview"),r.classList.add("single-event-preview")),V.notify(x.getSubject(r,S),{event:e,targetCalendarViewDate:t,timeFormat:this.timeFormat});const o=this.host.querySelector("[slot=event-preview-additional-fields]");o&&r.append(o);const a=me(e.event.key),s=this.host.querySelector(`[slot=${a}]`),l=r.querySelector(`[slot=${a}]`);s&&!l&&r.append(s.cloneNode(!0)),i.append(r)}}}Ae.backgroundColorModeEventHeight=18,Ne([l()],Ae.prototype,"host",void 0),Ne([l()],Ae.prototype,"calendarView",void 0),Ne([l()],Ae.prototype,"eventClickEmitter",void 0),Ne([l()],Ae.prototype,"timeFormat",void 0),Ne([l()],Ae.prototype,"enabledEventPreview",void 0),Ne([l()],Ae.prototype,"renderer",void 0),Ne([l()],Ae.prototype,"eventPreviewPopoverController",void 0);var Fe=function(e,t,n,i){var r,o=arguments.length,a=o<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,n,i);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,n,a):r(t,n))||a);return o>3&&a&&Object.defineProperty(t,n,a),a};class We extends A{constructor(){super({target:()=>this.host,callback:()=>this.updateMaxDisplayCountWithDebounce()}),this.updateMaxDisplayCountWithDebounce=F(this.updateMaxDisplayCount,500,this)}updateMaxDisplayCount(){try{const e=this.monthEventRenderer.getMonthEventContainerRef();if("month"===this.viewMode&&e&&e.parentElement){const t=e.parentElement.getBoundingClientRect().height,n=Math.floor((t-We.monthDateTitleHeight)/Ae.backgroundColorModeEventHeight);V.notify(x.getSubject(this.host,P),{host:this.host,detail:n})}}catch(e){}}updateMaxDisplayCountAfterSwitchToMonthView(e){"month"===e&&this.updateMaxDisplayCountWithDebounce()}}We.monthDateTitleHeight=26,Fe([l()],We.prototype,"host",void 0),Fe([l()],We.prototype,"monthEventRenderer",void 0),Fe([l()],We.prototype,"viewMode",void 0),Fe([c("componentDidLoad")],We.prototype,"updateMaxDisplayCount",null),Fe([c("watchViewModeChange")],We.prototype,"updateMaxDisplayCountAfterSwitchToMonthView",null);var _e=function(e,t,n,i){var r,o=arguments.length,a=o<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,n,i);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,n,a):r(t,n))||a);return o>3&&a&&Object.defineProperty(t,n,a),a};class He extends d{render(){const t=this.calendarView.dateItems[0],n=t.map((e=>this.calendarEventController.getCurrentDateEvents(e).filter((e=>e.isAllDayEvent||e.isGroupEvent())))),i=this.fullDayEventLayoutRenderer.sortLongEvents(n),r=this.filterDisplayEvents(i);return e("div",{class:"calendar-view-event-all"},t.map(((t,n)=>e("div",{class:"event-all-col border-divider-left",key:t.date},this.renderCurrentFullDayEvents(r[n],n,i[n],t)))))}renderCurrentFullDayEvents(n,i,r,o){const a=n.length*Ae.backgroundColorModeEventHeight-2,s=r.slice(n.length).filter(Boolean).length;return e(t,null,e("div",{class:"placeholder-block",style:{height:a+"px"}},e("span",null,n.length," events")),this.fullDayEventLayoutRenderer.render(n,i,o),s>0&&this.dayViewFullDayEventMoreButtonRenderer.render(s))}filterDisplayEvents(e){if(this.showAllEventsInDayOrWeekView)return e;{const t=[],n=He.maxDisplayEventLength;return e.forEach((e=>{const i=e.length>n?e.slice(0,n):e;t.push(i)})),t}}}He.maxDisplayEventLength=2,_e([l()],He.prototype,"calendarView",void 0),_e([l()],He.prototype,"calendarEventController",void 0),_e([l()],He.prototype,"eventItemRenderer",void 0),_e([l()],He.prototype,"fullDayEventLayoutRenderer",void 0),_e([l()],He.prototype,"showAllEventsInDayOrWeekView",void 0),_e([l()],He.prototype,"dayViewFullDayEventMoreButtonRenderer",void 0);var Ue=function(e,t,n,i){var r,o=arguments.length,a=o<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,n,i);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,n,a):r(t,n))||a);return o>3&&a&&Object.defineProperty(t,n,a),a};class Ye extends d{render(t,n){const i=[];return t.eventLayoutCells.forEach(((r,o)=>{let a=r.getEventBySlotIndex(0),s=0;for(let l=0;l<Ye.totalNumberOfCells;l++){const d=r.getEventBySlotIndex(l);d!==a&&(a&&i.push(e("div",{key:o,class:"time-event-block",style:this.getTimeEventStyle(s,l,o,t.getEventColumnsSpannedCount(a))},this.eventPreviewPopoverRenderer.render(a,n,{"day-event":!0,"bg-shadow":o>0}))),a=d,s=l)}})),i}getTimeEventStyle(e,t,n,i){const r=n*(1/i);return{position:"absolute",left:100*r+"%",top:100/Ye.totalNumberOfCells*e+"%",width:`calc(100% - ${100*r}%)`,height:100/Ye.totalNumberOfCells*(t-e)+"%",zIndex:n>0?`${n}`:void 0}}}Ye.totalNumberOfCells=96,Ue([l()],Ye.prototype,"eventItemRenderer",void 0),Ue([l()],Ye.prototype,"eventPreviewPopoverRenderer",void 0);class qe{addCurrentEventToLayout(e,t){let n=e.find((e=>!e.hasOverlapEvent(t)));n?n.updateSlots(t):(n=this.createNewLayoutCell(),n.updateSlots(t),e.push(n))}}class Ke{get eventLayoutCells(){return this.cells}}class Xe extends Ke{constructor(e){super(),this.cells=e}getEventColumnsSpannedCount(e){const t=this.cells.findIndex((t=>t.getEventStartIndex(e)>=0));let n=t+1;return t<this.cells.length-1&&this.cells.slice(t+1).forEach((t=>{t.hasOverlapEvent(e)&&n++})),n}}class Ze{getEventBySlotIndex(e){return this.slots[e]}getEventStartIndex(e){return this.slots.findIndex((t=>t===e))}getEventEndIndex(e){const t=this.getEventStartIndex(e);let n=t;if(t>=0)for(let i=t+1;i<this.slots.length;i++){if(this.slots[i]!==e){n=i-1;break}i===this.slots.length-1&&(n=i)}return n}}class Ge extends Ze{constructor(){super(...arguments),this.slots=Ge.defaultSlots}hasOverlapEvent(e){const[t,n]=this.getIndexRangeFromEvent(e);let i=!1;for(let e=t;e<n;e++)if(this.slots[e]){i=!0;break}return i}updateSlots(e){const[t,n]=this.getIndexRangeFromEvent(e);n>t&&(this.slots=this.slots.slice(0,t).concat(Array(n-t).fill(e),this.slots.slice(n)))}getIndexRangeFromEvent(e){const{startTime:t,endTime:n}=e;return[we(t),we(n)]}}Ge.defaultSlots=Array(96).fill(null);class Je extends qe{generate(e){const t=[new Ge];return e.forEach((e=>{this.addCurrentEventToLayout(t,e)})),new Xe(t)}createNewLayoutCell(){return new Ge}}class Qe{sort(e,t,n){const i=[],r=[],o=[];for(let t=0;t<e.length;t++){const n=e[t];n&&(n.isGroupEvent()?r.push(n):n.isAllDayEvent?i.push(n):o.push(n))}let a=i.concat(this.sortCalendarEventByTime(o)),s=n.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 n=we(e.startTime),i=we(t.startTime);return n===i?we(t.endTime)-we(e.endTime):n-i}))}insertEventsToEmptyPosition(e,t){return e.map((e=>{if(t.length&&!e){const e=t[0];return t=t.slice(1),e}return e}))}}var et=function(e,t,n,i){var r,o=arguments.length,a=o<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,n,i);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,n,a):r(t,n))||a);return o>3&&a&&Object.defineProperty(t,n,a),a};class tt extends d{constructor(){super(...arguments),this.calendarEventSorter=new Qe,this.dayViewTimedEventLayoutGenerator=new Je}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())),n=this.calendarEventSorter.sortCalendarEventByTime(t),i=this.dayViewTimedEventLayoutGenerator.generate(n);return this.dayViewEventLayoutRenderer.render(i,e)}}et([l()],tt.prototype,"calendarView",void 0),et([l()],tt.prototype,"calendarEventController",void 0),et([l()],tt.prototype,"dayViewEventLayoutRenderer",void 0);class nt extends Ke{constructor(e){super(),this.cells=e}getEventRowsIndex(e){return this.cells.findIndex((t=>t.getEventStartIndex(e)>=0))}getEventsByIndex(e){const t=[];let n=0;return this.cells.forEach(((i,r)=>{const o=i.getEventBySlotIndex(e);t.push(o),o&&(n=r)})),t.slice(0,n+1)}}class it extends Ze{constructor(){super(...arguments),this.slots=it.defaultSlots}updateSlots(e){const{start:t,end:n}=e;this.slots=this.slots.slice(0,t).concat(Array(n-t+1).fill(e.event),this.slots.slice(n+1))}hasOverlapEvent(e){const{start:t,end:n}=e;let i=!1;for(let e=t;e<n+1;e++)if(this.slots[e]){i=!0;break}return i}}it.defaultSlots=Array(7).fill(null);class rt extends qe{generate(e){const t=this.collectAllShouldOrderLongEvents(e),n=[this.createNewLayoutCell()];return t.forEach((e=>{this.addCurrentEventToLayout(n,e)})),new nt(n)}createNewLayoutCell(){return new it}collectAllShouldOrderLongEvents(e){const t={};e.forEach(((e,n)=>{e.filter((e=>e&&e.isGroupEvent())).forEach((e=>{t[e.eventKey]=t[e.eventKey]?Object.assign(Object.assign({},t[e.eventKey]),{end:n,start:n-t[e.eventKey].end!=1?n:t[e.eventKey].start}):{start:n,end:n,event:e}}))}));const n=Object.values(t);return this.sortLongEventViews(n)}sortLongEventViews(e){return e.sort(((e,t)=>{const{startDate:n,endDate:i}=e.event,{startDate:r,endDate:o}=t.event;n.setHours(0,0,0),r.setHours(0,0,0),i.setHours(23,59,59),o.setHours(23,59,59);const a=o.valueOf()-r.valueOf()-(i.valueOf()-n.valueOf());return n.valueOf()!==r.valueOf()?n.valueOf()-r.valueOf():a}))}}var ot=function(e,t,n,i){var r,o=arguments.length,a=o<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,n,i);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,n,a):r(t,n))||a);return o>3&&a&&Object.defineProperty(t,n,a),a};class at extends d{constructor(){super(...arguments),this.longEventLayoutGenerator=new rt,this.calendarEventSorter=new Qe}sortLongEvents(e){return this.fullDayEventLayout=this.longEventLayoutGenerator.generate(e),e.map(((e,t)=>this.calendarEventSorter.sort(e,t,this.fullDayEventLayout)))}render(t,n,i){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,n,r,"month"===this.viewMode?at.monthViewEventOffsetTop:0)},this.eventPreviewPopoverRenderer.render(t,i,{"month-event":"month"===this.viewMode,"day-event":"month"!==this.viewMode}))}))}getEventStyle(e,t,n,i){const r=this.calendarView.weekdays.length,o=t;let a=t+1;const s=n;let l=!0;const d=this.fullDayEventLayout.getEventRowsIndex(e);if(d>=0){const n=this.fullDayEventLayout.eventLayoutCells[d].getEventStartIndex(e),i=this.fullDayEventLayout.eventLayoutCells[d].getEventEndIndex(e);n===t?a=i+1:l=!1}return{position:"absolute",left:100/r*o+"%",top:`${s*Ae.backgroundColorModeEventHeight+i}px`,width:100/r*(a-o)+"%",opacity:l?"1":"0"}}}at.monthViewEventOffsetTop=26,ot([l()],at.prototype,"eventItemRenderer",void 0),ot([l()],at.prototype,"viewMode",void 0),ot([l()],at.prototype,"calendarView",void 0),ot([l()],at.prototype,"eventPreviewPopoverRenderer",void 0);var st=function(e,t,n,i){var r,o=arguments.length,a=o<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,n,i);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,n,a):r(t,n))||a);return o>3&&a&&Object.defineProperty(t,n,a),a};class lt extends d{constructor(){super(...arguments),this.updateShowAllFlag=e=>{e.stopPropagation(),this.showAllEventsInDayOrWeekView=!0}}render(t){if(!this.showAllEventsInDayOrWeekView)return e("div",{tabIndex:0,role:"button",class:"more-button",onKeyDown:$(),onClick:this.updateShowAllFlag},`${t} More`)}resetShowAllFlag(){this.showAllEventsInDayOrWeekView=!1}}st([l({writable:!0})],lt.prototype,"showAllEventsInDayOrWeekView",void 0),st([c("watchViewModeChange")],lt.prototype,"resetShowAllFlag",null);var dt=function(e,t,n,i){var r,o=arguments.length,a=o<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,n,i);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,n,a):r(t,n))||a);return o>3&&a&&Object.defineProperty(t,n,a),a};class ct extends d{render(t){const n=t.findIndex((e=>e.isToday()))>=0;return e("div",{class:{"time-marker-container":!0,hidden:!n}},e("div",{class:"time-marker",style:{top:this.getTimeMarkerPosition()},ref:e=>this.timeMarkerRef=e},t.map((t=>e("div",{key:t.date,class:{active:t.isToday()}})))))}updateTimeLine(e){this.scrollToTargetTimeBlock(e),this.syncTimeMarkerPosition(e)}clearTimer(){clearInterval(this.timeMarkerPositionTimer)}updateTimeLineIfComponentAddBack(){this.syncTimeMarkerPosition(this.viewMode)}displayCurrentTimeBlockByDefault(){this.scrollToTargetTimeBlock(this.viewMode)}getTimeMarkerPosition(){const e=new Date;return(60*e.getHours()+e.getMinutes())/1440*100+"%"}syncTimeMarkerPosition(e){clearInterval(this.timeMarkerPositionTimer),"month"!==e&&(this.timeMarkerPositionTimer=setInterval((()=>{this.timeMarkerRef&&(this.timeMarkerRef.style.top=this.getTimeMarkerPosition())}),6e4))}scrollToTargetTimeBlock(e){"month"!==e&&setTimeout((()=>{const e=this.viewRenderer.getCalendarViewElementRef(),t=Math.max(0,this.getViewCenterPosition());e&&t&&e.scrollTo({top:t})}),16)}getViewCenterPosition(){const e=this.viewRenderer.getCalendarViewElementRef();if(e){const t=e.querySelector(".calendar-view-title-container").offsetHeight,n=Math.max(e.offsetHeight-t,0)/2,i=e.scrollHeight,r=16,o=Number(this.getTimeMarkerPosition().replace("%",""))/100*Math.max(i-r-t,0);if(!isNaN(n)&&o&&o>n)return o-n+r}return 0}}dt([l()],ct.prototype,"viewMode",void 0),dt([l()],ct.prototype,"viewRenderer",void 0),dt([c("watchViewModeChange")],ct.prototype,"updateTimeLine",null),dt([c("disconnectedCallback")],ct.prototype,"clearTimer",null),dt([c("connectedCallback")],ct.prototype,"updateTimeLineIfComponentAddBack",null),dt([c("componentDidLoad")],ct.prototype,"displayCurrentTimeBlockByDefault",null);var ht=function(e,t,n,i){var r,o=arguments.length,a=o<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,n,i);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,n,a):r(t,n))||a);return o>3&&a&&Object.defineProperty(t,n,a),a};class vt extends d{setPostOperationDate(e){this.postOperationDate=e}setDate(e,t){if(e.current!==this.postOperationDate)if(this.shouldSetCurrentDateToFirstDayOfMonth(e,t)){const t=e.current.toDate();t&&(t.setDate(1),this.setPostOperationDate(ce.from(t)))}else this.setPostOperationDate(ce.from(e.current.toDate()))}shouldSetCurrentDateToFirstDayOfMonth(e,t){return"month"===e.type&&"month"===(null==t?void 0:t.type)&&!e.current.equal(ce.from(new Date))}}ht([l({writable:!0})],vt.prototype,"postOperationDate",void 0),ht([c("watchCurrentPeriodChange")],vt.prototype,"setDate",null);var pt=function(e,t,n,i){var r,o=arguments.length,a=o<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,n,i);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,n,a):r(t,n))||a);return o>3&&a&&Object.defineProperty(t,n,a),a};class ft extends d{constructor(){super(...arguments),this.popoverHideObserver=null}render(e,t,n){return this.enabledEventPreview?this.renderPreviewPopover(e,n,t):this.eventItemRenderer.render(e,n,t)}renderPreviewPopover(t,n,i){return e("vega-popover",{placement:"day"===this.viewMode?"top":"right",alignment:"center",class:{"event-preview-popover":!0,block:!0},padding:"0",size:ft.SINGLE_EVENT_PREVIEW_WIDTH,ref:e=>{this.setPopoverHideObserver(e,t)}},e("div",{slot:"popover-content",class:"event-preview-popover-content"},this.eventItemRenderer.render(t,n,i)),e("div",{slot:"popover"},e("div",{class:"preview-container",ref:e=>{e?this.eventPreviewPopoverController.setEventPreviewContainerMap(t,i,e):this.eventPreviewPopoverController.deleteEventPreviewContainer(t,i)}})))}setPopoverHideObserver(e,t){e?(this.popoverHideObserver=new T((e=>t===e),(async()=>await e.hide())),V.register(L,this.popoverHideObserver)):this.popoverHideObserver&&V.unregister(L,this.popoverHideObserver)}}ft.SINGLE_EVENT_PREVIEW_WIDTH=400,pt([l()],ft.prototype,"host",void 0),pt([l()],ft.prototype,"renderer",void 0),pt([l()],ft.prototype,"viewMode",void 0),pt([l()],ft.prototype,"timeFormat",void 0),pt([l()],ft.prototype,"eventItemRenderer",void 0),pt([l()],ft.prototype,"enabledEventPreview",void 0),pt([l()],ft.prototype,"eventPreviewPopoverController",void 0);class wt extends d{constructor(){super(...arguments),this.singleEventPreviewContainerMap=new Map,this.groupEventsPreviewContainerMap=new Map}setEventPreviewContainerMap(e,t,n){(Array.isArray(e)?this.groupEventsPreviewContainerMap:this.singleEventPreviewContainerMap).set(this.generateMapKey(e,t),n)}deleteEventPreviewContainer(e,t){(Array.isArray(e)?this.groupEventsPreviewContainerMap:this.singleEventPreviewContainerMap).delete(this.generateMapKey(e,t))}getEventPreviewContainer(e,t,n){const i=n?this.groupEventsPreviewContainerMap:this.singleEventPreviewContainerMap,r=this.generateMapKey(e,t);if(i.has(r))return i.get(r);{const n=this.getDateString(t),r=Array.from(i.keys()).find((t=>t.includes(e.eventKey)&&t.endsWith(n)));if(r)return i.get(r)}}generateMapKey(e,t){const n=this.getDateString(t);return Array.isArray(e)?e.filter((e=>e)).map((e=>e.eventKey)).join("-")+n:e.eventKey+n}getDateString(e){return`-${e.year}-${e.month}-${e.date}`}}var mt=function(e,t,n,i){var r,o=arguments.length,a=o<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,n,i);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,n,a):r(t,n))||a);return o>3&&a&&Object.defineProperty(t,n,a),a};const ut=class{constructor(e){i(this,e),this.vegaChange=r(this,"vegaChange",7),this.change=r(this,"change",7),this.vegaEventClick=r(this,"vegaEventClick",7),this.eventClick=r(this,"eventClick",7),this.vegaDateDblClick=r(this,"vegaDateDblClick",7),this.dateDblClick=r(this,"dateDblClick",7),this.vegaMoreActionClick=r(this,"vegaMoreActionClick",7),this.moreActionClick=r(this,"moreActionClick",7),this.globalSlimmer={},this.translationSlimmer=new _,this.vegaComponentUsageRuntimeMetricsSlimmer=new p,this.renderer=new K,this.switchPanelRenderer=new Z,this.viewRenderer=new J,this.monthViewRenderer=new ee,this.viewWithTimeRenderer=new ne,this.timeLineRenderer=new ie,this.timeMarkerRenderer=new ct,this.monthEventRenderer=new Ee,this.currentPeriodController=new je,this.calendarViewController=new Ce,this.postOperationDateController=new vt,this.dayViewFullDayEventRenderer=new He,this.eventPreviewPopoverController=new wt,this.dayViewFullDayEventMoreButtonRenderer=new lt,this.dayViewTimedEventRenderer=new tt,this.eventItemRenderer=new Ae,this.dayViewEventLayoutRenderer=new Ye,this.fullDayEventLayoutRenderer=new at,this.eventPreviewPopoverRenderer=new ft,this.calendarEventController=new Be,this.eventResponsiveController=new We,this.changeEventEmitter=D(ut,u),this.eventClickEmitter=D(ut,y),this.dateDblClickEmitter=D(ut,k),this.moreActionClickEmitter=D(ut,C),this.changeEventPrevent=new O([u],(()=>this.switchPanelRenderer.getSwitchPanelRef())),this.timeFormatNotifySlimmer=W(ut,"timeFormat","watchTimeFormat"),this.showEventColorBarNotifySlimmer=W(ut,"showEventColorBar","watchShowEventColorBar"),this.postOperationDate=ce.from(new Date),this.showAllEventsInDayOrWeekView=!1,this.calendarEvents=[],this.viewMode="month",this.timeFormat="24-hour",this.isDateDisabled=()=>!1,this.showEventColorBar=!0,this.showSwitchView=!0,this.showWeekends=!0,this.enabledEventPreview=!0}watchCurrentPeriodChange(e,t){}watchViewModeChange(e){}watchEventsChange(e){}watchTimeFormat(e){}watchShowEventColorBar(e){}watchShowWeekendsChange(){}render(){return s(e(o,null,this.renderer.render()),this.host)}get host(){return a(this)}static get watchers(){return{currentPeriod:["watchCurrentPeriodChange"],viewMode:["watchViewModeChange"],events:["watchEventsChange"],timeFormat:["watchTimeFormat"],showEventColorBar:["watchShowEventColorBar"],showWeekends:["watchShowWeekendsChange"]}}};mt([f()],ut.prototype,"globalSlimmer",void 0),mt([v()],ut.prototype,"translationSlimmer",void 0),mt([v()],ut.prototype,"vegaComponentUsageRuntimeMetricsSlimmer",void 0),mt([v()],ut.prototype,"renderer",void 0),mt([v()],ut.prototype,"switchPanelRenderer",void 0),mt([v()],ut.prototype,"viewRenderer",void 0),mt([v()],ut.prototype,"monthViewRenderer",void 0),mt([v()],ut.prototype,"viewWithTimeRenderer",void 0),mt([v()],ut.prototype,"timeLineRenderer",void 0),mt([v()],ut.prototype,"timeMarkerRenderer",void 0),mt([v()],ut.prototype,"monthEventRenderer",void 0),mt([v()],ut.prototype,"currentPeriodController",void 0),mt([v()],ut.prototype,"calendarViewController",void 0),mt([v()],ut.prototype,"postOperationDateController",void 0),mt([v()],ut.prototype,"dayViewFullDayEventRenderer",void 0),mt([v()],ut.prototype,"eventPreviewPopoverController",void 0),mt([v()],ut.prototype,"dayViewFullDayEventMoreButtonRenderer",void 0),mt([v()],ut.prototype,"dayViewTimedEventRenderer",void 0),mt([v()],ut.prototype,"eventItemRenderer",void 0),mt([v()],ut.prototype,"dayViewEventLayoutRenderer",void 0),mt([v()],ut.prototype,"fullDayEventLayoutRenderer",void 0),mt([v()],ut.prototype,"eventPreviewPopoverRenderer",void 0),mt([v()],ut.prototype,"calendarEventController",void 0),mt([v()],ut.prototype,"eventResponsiveController",void 0),mt([v()],ut.prototype,"changeEventEmitter",void 0),mt([v()],ut.prototype,"eventClickEmitter",void 0),mt([v()],ut.prototype,"dateDblClickEmitter",void 0),mt([v()],ut.prototype,"moreActionClickEmitter",void 0),mt([v()],ut.prototype,"changeEventPrevent",void 0),mt([v()],ut.prototype,"timeFormatNotifySlimmer",void 0),mt([v()],ut.prototype,"showEventColorBarNotifySlimmer",void 0),ut.style='.border-divider-top{border:1px solid rgba(var(--v-border-divider-secondary, 199, 217, 229, 1));border-left-width:0px;border-right-width:0px;border-bottom-width:0px}.border-divider-top.disabled{background-color:rgba(var(--v-bg-secondary, 245, 247, 247, 1))}.border-divider-left{border:1px solid rgba(var(--v-border-divider-secondary, 199, 217, 229, 1));border-top-width:0px;border-right-width:0px;border-bottom-width:0px}.border-divider-left.disabled{background-color:rgba(var(--v-bg-secondary, 245, 247, 247, 1))}.border-divider-right{border:1px solid rgba(var(--v-border-divider-secondary, 199, 217, 229, 1));border-top-width:0px;border-left-width:0px;border-bottom-width:0px}.border-divider-bottom{border:1px solid rgba(var(--v-border-divider-secondary, 199, 217, 229, 1));border-top-width:0px;border-left-width:0px;border-right-width:0px}:host{display:flex;flex-direction:column;border-radius:12px;border:1px solid rgba(var(--v-border-divider, 171, 198, 216, 1));background-color:rgba(var(--v-bg-primary, 252, 252, 252, 1));overflow:hidden;width:100%;height:100%;box-sizing:border-box;max-height:1966px}.calendar-switch-panel{padding:24px;border-bottom-width:1px;border-top-width:0px;border-left-width:0px;border-right-width:0px;border-style:solid;border-color:rgba(var(--v-border-color-divider, 171, 198, 216, 1));flex-shrink:0;width:100%;box-sizing:border-box}.calendar-switch-panel .calendar-date-switch-container{display:flex;gap:8px;align-items:center;flex-direction:row}.calendar-switch-panel .calendar-view-switch-container{display:flex;gap:16px;align-items:center;flex-direction:row}.calendar-switch-panel .calendar-current-date{padding-left:8px}.calendar-view{width:100%;position:relative;flex-grow:1;overflow-y:auto;overflow-x:hidden;--calendar-weekday-columns:7}.calendar-view.calendar-hide-weekends{--calendar-weekday-columns:5}.calendar-view-month .calendar-view-month-container{width:100%;display:grid;min-height:100%;grid-template-rows:43px repeat(6, minmax(64px, 1fr))}.calendar-view-month .calendar-view-title{background-color:rgba(var(--v-bg-primary, 252, 252, 252, 1));top:0;left:0;z-index:62}.calendar-view-month .calendar-view-title div{padding-top:12px;padding-bottom:12px;color:rgba(var(--v-text-secondary, 107, 116, 125, 1));font-family:"Inter", sans-serif;font-size:14px;font-weight:700;line-height:18px;text-align:center}@media screen and (min-width: 768px) and (max-width: 1023px){.calendar-view-month .calendar-view-title div{font-family:"Inter", sans-serif;font-size:14px;font-weight:700;line-height:18px}}@media screen and (min-width: 1024px) and (max-width: 1439px){.calendar-view-month .calendar-view-title div{font-family:"Inter", sans-serif;font-size:14px;font-weight:700;line-height:18px}}@media screen and (min-width: 1440px) and (max-width: 9999px){.calendar-view-month .calendar-view-title div{font-family:"Inter", sans-serif;font-size:14px;font-weight:700;line-height:18px}}.calendar-view-month .calendar-view-row{position:relative;display:grid;grid-template-rows:1fr;grid-template-columns:repeat(var(--calendar-weekday-columns), minmax(64px, 1fr))}.calendar-view-month .calendar-view-row.calendar-view-title{position:sticky}.calendar-view-month .calendar-view-row:last-child{border-bottom-width:0px}.calendar-view-month .calendar-view-row .row-cell{overflow:hidden;display:flex;flex-direction:column;justify-content:space-between}.calendar-view-month .calendar-view-row .row-cell:last-child{border-right-width:0px}.calendar-view-month .calendar-view-row .row-cell .date{padding-top:4px;padding-bottom:4px;padding-right:12px;padding-left:8px}.calendar-view-month .calendar-view-row .row-cell .date>div{display:inline-block;color:rgba(var(--v-text-secondary, 107, 116, 125, 1));font-family:"Inter", sans-serif;font-size:14px;font-weight:400;line-height:18px}@media screen and (min-width: 768px) and (max-width: 1023px){.calendar-view-month .calendar-view-row .row-cell .date>div{font-family:"Inter", sans-serif;font-size:14px;font-weight:400;line-height:18px}}@media screen and (min-width: 1024px) and (max-width: 1439px){.calendar-view-month .calendar-view-row .row-cell .date>div{font-family:"Inter", sans-serif;font-size:14px;font-weight:400;line-height:18px}}@media screen and (min-width: 1440px) and (max-width: 9999px){.calendar-view-month .calendar-view-row .row-cell .date>div{font-family:"Inter", sans-serif;font-size:14px;font-weight:400;line-height:18px}}.calendar-view-month .calendar-view-row .row-cell .date .month-block{margin-right:2px}.calendar-view-month .calendar-view-row .row-cell .date .grid-col{text-align:center;border-top-left-radius:9999px;border-bottom-left-radius:9999px;border-top-right-radius:9999px;border-bottom-right-radius:9999px;cursor:pointer;width:18px;height:18px;line-height:18px}.calendar-view-month .calendar-view-row .row-cell .date .grid-col:hover{background-color:rgba(var(--v-bg-action-secondary-hover, 4, 112, 236, 0.1))}.calendar-view-month .calendar-view-row .row-cell .date .grid-col:active{background-color:rgba(var(--v-bg-action-secondary-active, 29, 65, 195, 0.1))}.calendar-view-month .calendar-view-row .row-cell .date .grid-col:focus-visible{outline:2px solid rgba(var(--v-border-color-action, 19, 98, 226, 1));outline-offset:2px}.calendar-view-month .calendar-view-row .row-cell.current-month-day .date>div{color:rgba(var(--v-text-primary, 32, 54, 69, 1))}.calendar-view-month .calendar-view-row .row-cell.disabled{background-color:rgba(var(--v-bg-secondary, 245, 247, 247, 1))}.calendar-view-month .calendar-view-row .row-cell.disabled .date>div{color:rgba(var(--v-text-disabled, 176, 180, 181, 1))}.calendar-view-month .calendar-view-row .row-cell.active .date .grid-col{background-color:rgba(var(--v-bg-action, 19, 98, 226, 1));border-top-left-radius:9999px;border-bottom-left-radius:9999px;color:rgba(var(--v-text-on-action, 252, 252, 252, 1))}.calendar-view-month .calendar-view-row .row-cell.active .date .grid-col:hover{background-color:rgba(var(--v-bg-action-hover, 4, 112, 236, 1))}.calendar-view-month .calendar-view-row .row-cell.active .date .grid-col:active{background-color:rgba(var(--v-bg-action-active, 29, 65, 195, 1))}.calendar-view-month .calendar-view-row .row-cell.active .date .grid-col:focus-visible{outline:2px solid rgba(var(--v-border-color-action, 19, 98, 226, 1));outline-offset:2px}.calendar-view-container{width:100%}.calendar-view-container .calendar-view-title-container{background-color:rgba(var(--v-bg-primary, 252, 252, 252, 1));position:sticky;top:0;left:0;z-index:62}.calendar-view-container .calendar-view-row{box-sizing:border-box;width:100%;display:flex;flex-direction:row}.calendar-view-container .calendar-view-row .time-line,.calendar-view-container .calendar-view-row .time-line-empty,.calendar-view-container .calendar-view-row .time-line-all{width:72px;text-align:right;padding-right:8px;box-sizing:border-box;font-family:"Inter", sans-serif;font-size:14px;font-weight:400;line-height:18px;color:rgba(var(--v-text-primary, 32, 54, 69, 1));flex-shrink:0}@media screen and (min-width: 768px) and (max-width: 1023px){.calendar-view-container .calendar-view-row .time-line,.calendar-view-container .calendar-view-row .time-line-empty,.calendar-view-container .calendar-view-row .time-line-all{font-family:"Inter", sans-serif;font-size:14px;font-weight:400;line-height:18px}}@media screen and (min-width: 1024px) and (max-width: 1439px){.calendar-view-container .calendar-view-row .time-line,.calendar-view-container .calendar-view-row .time-line-empty,.calendar-view-container .calendar-view-row .time-line-all{font-family:"Inter", sans-serif;font-size:14px;font-weight:400;line-height:18px}}@media screen and (min-width: 1440px) and (max-width: 9999px){.calendar-view-container .calendar-view-row .time-line,.calendar-view-container .calendar-view-row .time-line-empty,.calendar-view-container .calendar-view-row .time-line-all{font-family:"Inter", sans-serif;font-size:14px;font-weight:400;line-height:18px}}.calendar-view-container .calendar-view-title{width:100%}.calendar-view-container .calendar-view-title>div{padding:12px;padding-bottom:8px;color:rgba(var(--v-text-secondary, 107, 116, 125, 1));font-family:"Inter", sans-serif;font-size:14px;font-weight:700;line-height:18px;text-align:center;display:flex;flex-direction:column;gap:8px}@media screen and (min-width: 768px) and (max-width: 1023px){.calendar-view-container .calendar-view-title>div{font-family:"Inter", sans-serif;font-size:14px;font-weight:700;line-height:18px}}@media screen and (min-width: 1024px) and (max-width: 1439px){.calendar-view-container .calendar-view-title>div{font-family:"Inter", sans-serif;font-size:14px;font-weight:700;line-height:18px}}@media screen and (min-width: 1440px) and (max-width: 9999px){.calendar-view-container .calendar-view-title>div{font-family:"Inter", sans-serif;font-size:14px;font-weight:700;line-height:18px}}.calendar-view-container .calendar-view-title .week-day{color:rgba(var(--v-text-primary, 32, 54, 69, 1));font-family:"Inter", sans-serif;font-size:20px;font-weight:500;line-height:24px;letter-spacing:0px}@media screen and (min-width: 768px) and (max-width: 1023px){.calendar-view-container .calendar-view-title .week-day{font-family:"Inter", sans-serif;font-size:20px;font-weight:500;line-height:24px;letter-spacing:0px}}@media screen and (min-width: 1024px) and (max-width: 1439px){.calendar-view-container .calendar-view-title .week-day{font-family:"Inter", sans-serif;font-size:20px;font-weight:500;line-height:24px;letter-spacing:0px}}@media screen and (min-width: 1440px) and (max-width: 9999px){.calendar-view-container .calendar-view-title .week-day{font-family:"Inter", sans-serif;font-size:20px;font-weight:500;line-height:24px;letter-spacing:0px}}.calendar-view-container .calendar-view-title .active div{color:rgba(var(--v-text-link, 19, 98, 226, 1))}.calendar-view-container .calendar-view-event-all-container{align-items:center}.calendar-view-container .calendar-view-event-all{display:grid;grid-template-rows:1fr;flex-grow:1;min-height:18px}.calendar-view-container .calendar-view-day-container .time-line{display:grid;grid-template-rows:16px repeat(24, minmax(74px, 1fr))}.calendar-view-container .calendar-view-day-container .time-line .time-text{margin-top:-9px}.calendar-view-container .calendar-view-day-container .calendar-view-content{width:100%}.calendar-view-container .calendar-view-day-container .calendar-view-content .grid-col{display:grid;grid-template-rows:16px repeat(24, minmax(74px, 1fr));grid-template-columns:minmax(64px, 1fr)}.calendar-view-container .calendar-view-day-container .calendar-view-content .grid-col>.border-divider-top:first-child{border-top-width:0px}.calendar-view-container .calendar-view-content-container{width:100%;position:relative}.calendar-view-week .calendar-view-container{min-height:100%}.calendar-view-week .calendar-view-container .calendar-view-title{display:grid;grid-template-rows:1fr;grid-template-columns:repeat(var(--calendar-weekday-columns), minmax(64px, 1fr))}.calendar-view-week .calendar-view-container .calendar-view-event-all{grid-template-columns:repeat(var(--calendar-weekday-columns), minmax(64px, 1fr))}.calendar-view-week .calendar-view-container .calendar-view-day-container .calendar-view-content{display:grid;grid-template-columns:repeat(var(--calendar-weekday-columns), minmax(64px, 1fr))}.calendar-view-week .time-marker-container .time-marker{display:grid;grid-template-columns:repeat(var(--calendar-weekday-columns), minmax(64px, 1fr))}.calendar-view-week .day-event-container{display:grid;grid-template-columns:repeat(var(--calendar-weekday-columns), minmax(64px, 1fr))}.calendar-view-day .calendar-view-container{min-height:100%}.time-marker-container{position:absolute;min-width:100%;left:0;top:16px;height:calc(100% - 16px);pointer-events:none}.time-marker-container.hidden{display:none}.time-marker-container .time-marker{position:absolute;height:2px;display:grid;min-width:100%;left:0;top:0;z-index:61}.time-marker-container .time-marker div{width:100%;height:2px;background-color:rgba(var(--v-bg-status-error, 255, 110, 139, 1));opacity:0.3}.time-marker-container .time-marker div.active{opacity:1;position:relative}.time-marker-container .time-marker div.active::before{content:"";display:block;border-top-left-radius:9999px;border-bottom-left-radius:9999px;border-top-right-radius:9999px;border-bottom-right-radius:9999px;position:absolute;width:8px;height:8px;background-color:rgba(var(--v-bg-status-error, 255, 110, 139, 1));top:-3px;left:-4px}.day-event-container{position:absolute;min-width:100%;left:0;top:16px;height:calc(100% - 16px);pointer-events:none}.day-event-container .day-event-col{height:100%;overflow:hidden}.day-event-container vega-calendar-event{pointer-events:auto;height:100%}.calendar-view-month .month-event-row{position:absolute;width:100%;overflow:hidden;height:calc(100% - 26px);left:0;bottom:0}.calendar-view-month .events-container{width:100%;box-sizing:border-box;overflow:hidden;padding:2px;display:flex;flex-direction:column;gap:2px;justify-content:space-between;flex-grow:1}.calendar-view-month .events-container .event-list{display:flex;flex-direction:column;gap:2px;flex-grow:1}.calendar-view-month .events-container .event-list .month-event-block{box-sizing:border-box;padding-left:2px;padding-right:3px}.calendar-view-month .events-container .month-event-more .more-button{display:inline-block;height:16px;font-family:"Inter", sans-serif;font-size:12px;font-weight:700;line-height:16px;letter-spacing:0px;color:rgba(var(--v-text-link, 19, 98, 226, 1));cursor:pointer;border-radius:2px}@media screen and (min-width: 768px) and (max-width: 1023px){.calendar-view-month .events-container .month-event-more .more-button{font-family:"Inter", sans-serif;font-size:12px;font-weight:700;line-height:16px;letter-spacing:0px}}@media screen and (min-width: 1024px) and (max-width: 1439px){.calendar-view-month .events-container .month-event-more .more-button{font-family:"Inter", sans-serif;font-size:12px;font-weight:700;line-height:16px;letter-spacing:0px}}@media screen and (min-width: 1440px) and (max-width: 9999px){.calendar-view-month .events-container .month-event-more .more-button{font-family:"Inter", sans-serif;font-size:12px;font-weight:700;line-height:16px;letter-spacing:0px}}.calendar-view-month .events-container .month-event-more .more-button:focus-visible{outline:2px solid rgba(var(--v-border-color-action, 19, 98, 226, 1));outline-offset:0px}.calendar-view-container .calendar-view-event-all{position:relative}.calendar-view-container .calendar-view-event-all .placeholder-block{padding-top:2px;padding-bottom:2px;box-sizing:content-box}.calendar-view-container .calendar-view-event-all .placeholder-block span{display:none}.calendar-view-container .calendar-view-event-all .day-event-block{padding-top:2px;padding-right:2px;box-sizing:border-box;padding-left:3px}.calendar-view-container .calendar-view-event-all .more-button{display:inline-block;height:16px;font-family:"Inter", sans-serif;font-size:12px;font-weight:700;line-height:16px;letter-spacing:0px;color:rgba(var(--v-text-link, 19, 98, 226, 1));cursor:pointer;border-radius:2px;margin-left:2px;padding:2px}@media screen and (min-width: 768px) and (max-width: 1023px){.calendar-view-container .calendar-view-event-all .more-button{font-family:"Inter", sans-serif;font-size:12px;font-weight:700;line-height:16px;letter-spacing:0px}}@media screen and (min-width: 1024px) and (max-width: 1439px){.calendar-view-container .calendar-view-event-all .more-button{font-family:"Inter", sans-serif;font-size:12px;font-weight:700;line-height:16px;letter-spacing:0px}}@media screen and (min-width: 1440px) and (max-width: 9999px){.calendar-view-container .calendar-view-event-all .more-button{font-family:"Inter", sans-serif;font-size:12px;font-weight:700;line-height:16px;letter-spacing:0px}}.calendar-view-container .calendar-view-event-all .more-button:focus-visible{outline:2px solid rgba(var(--v-border-color-action, 19, 98, 226, 1));outline-offset:0px}.calendar-view-container .calendar-view-event-all .event-all-col{display:flex;flex-direction:column;justify-content:space-between;align-items:flex-start}.calendar-view-container .day-event-col{position:relative}.calendar-view-container .day-event-col .time-event-block{box-sizing:border-box;padding-right:8px;padding-bottom:2px;padding-top:3px}.calendar-view-container .day-event-col .time-event-block vega-calendar-event.bg-shadow::part(event-container):not(:focus){outline:2px solid rgba(var(--v-bg-primary, 252, 252, 252, 1))}.calendar-view-container .day-event-col .time-event-block:focus-within{z-index:60 !important}.calendar-event-slot-container{display:none}.event-preview-popover{height:100%}.event-preview-popover.block{display:block}.event-preview-popover .event-preview-popover-content{height:100%}';var gt=function(e,t,n,i){var r,o=arguments.length,a=o<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,n,i);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,n,a):r(t,n))||a);return o>3&&a&&Object.defineProperty(t,n,a),a};class bt extends d{getEventTitleContainerRef(){return this.eventTitleContainerRef}getSlotContainerRef(){return this.slotContainerRef}render(){return e(t,null,this.injectBackgroundColorStyle(),this.calendarEventRender())}calendarEventRender(){return this.calendarEvent.isAllDayEvent||this.calendarEvent.isGroupEvent()?this.renderBackgroundModeEvent():this.renderNormalEvent()}renderBackgroundModeEvent(){const t=this.calendarEvent.disabled;return e("div",{role:"button",tabIndex:0,class:{"slot-container":this.slotMode,"background-color-mode":!0,"event-bg-color":!t,"bg-disabled":t},ref:e=>this.slotContainerRef=e},this.slotMode?this.getSlotElement():this.calendarEvent.title)}renderNormalEvent(){const{variant:t,disabled:n}=this.calendarEvent,i=t||"primary",r=!this.host.classList.contains("day-event"),o={"slot-container":this.slotMode,"event-container":!0,disabled:n,[i]:!0};if(r)return e("div",{role:"button",tabIndex:0,class:o,ref:e=>this.slotContainerRef=e},!this.slotMode&&this.renderEventStatus(),this.slotMode?this.getSlotElement():this.defaultNormalMonthEventContentRender());{const t=this.calendarEvent.getEventDuration();return e("div",{part:"event-container",class:Object.assign(Object.assign({},o),{vertical:t>30,"duration-half-an-hour":30===t,"event-bg-color":!n,"bg-disabled":n}),role:"button",tabIndex:0,ref:e=>this.slotContainerRef=e},!this.slotMode&&this.renderEventStatus(),e("div",{class:"cover-block"}),this.slotMode?this.getSlotElement():this.defaultNormalTimedEventContentRender(t))}}renderEventStatus(){if(this.showColorBar){const t=this.calendarEvent.disabled;return e("div",{class:{"event-status":!0,"event-bg-color":!t,"bg-disabled":t}},e("span",{class:{stripe:"secondary"===this.calendarEvent.variant}}))}}defaultNormalMonthEventContentRender(){const{startTime:t,title:n}=this.calendarEvent;return e("div",{class:"event-title"},`${ae(this.timeFormat,t)} ${n}`)}defaultNormalTimedEventContentRender(t){const{startTime:n,endTime:i,title:r}=this.calendarEvent;return e("div",{class:"event-content"},e("div",{class:{"event-title":!0,"title-word-wrap":t>30},ref:e=>this.eventTitleContainerRef=e},r),e("div",{class:"event-time"},e("vega-icon",{size:"size-12",icon:R.getIconKey("clock-three")}),e("span",null,`${ae(this.timeFormat,n)} - ${ae(this.timeFormat,i)}`)))}getSlotElement(){if(!this.calendarEvent.isRepeatEvent)return e("slot",null)}injectBackgroundColorStyle(){return e("style",null,ge(this.calendarEvent.color))}}R.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>'}}),gt([l()],bt.prototype,"host",void 0),gt([l()],bt.prototype,"timeFormat",void 0),gt([l()],bt.prototype,"calendarEvent",void 0),gt([l()],bt.prototype,"slotMode",void 0),gt([l()],bt.prototype,"showColorBar",void 0);var xt=function(e,t,n,i){var r,o=arguments.length,a=o<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,n,i);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,n,a):r(t,n))||a);return o>3&&a&&Object.defineProperty(t,n,a),a};class yt extends U{constructor(){super({parent:()=>this.host["data-calendar-ref"],subStates:[{subStateName:"timeFormat",parentStateName:"timeFormat"},{subStateName:"showColorBar",parentStateName:"showEventColorBar"}]})}}xt([l({writable:!0})],yt.prototype,"timeFormat",void 0),xt([l({writable:!0})],yt.prototype,"showColorBar",void 0);class kt extends d{setVerticalTitleMaxHeight(){const e=this.renderer.getEventTitleContainerRef();if(e&&e.classList.contains("title-word-wrap")){const t=window.getComputedStyle(e),n=Y(t.height),i=Y(t.lineHeight),r=Math.max(Math.floor(n/i),1);e.style.maxHeight=r*i+"px"}}}!function(e,t,n,i){var r,o=arguments.length,a=o<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,n,i);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,n,a):r(t,n))||a);o>3&&a&&Object.defineProperty(t,n,a)}([l()],kt.prototype,"renderer",void 0);var Ct=function(e,t,n,i){var r,o=arguments.length,a=o<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,n,i);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,n,a):r(t,n))||a);return o>3&&a&&Object.defineProperty(t,n,a),a};class Rt extends d{findTheCalendarEventSlot(){if(this.calendarEvent){const{event:e}=this.calendarEvent,t=this.getParentCalendarElement();if(t){const n=t.querySelector(`vega-calendar-event-slot[event-key='${e.key}']`);n&&(this.slotMode=!0,this.matchSlotElement=n)}}}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")}}Ct([l()],Rt.prototype,"host",void 0),Ct([l()],Rt.prototype,"calendarEvent",void 0),Ct([l({writable:!0})],Rt.prototype,"slotMode",void 0),Ct([l()],Rt.prototype,"renderer",void 0),Ct([c("componentWillLoad")],Rt.prototype,"findTheCalendarEventSlot",null),Ct([c("componentDidLoad")],Rt.prototype,"appendTheRepeatEventSlotToContainer",null);var jt=function(e,t,n,i){var r,o=arguments.length,a=o<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,n,i);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,n,a):r(t,n))||a);return o>3&&a&&Object.defineProperty(t,n,a),a};const Dt=class{constructor(e){i(this,e),this.globalSlimmer={},this.pageResizeObserverSlimmer=new A({target:()=>this.host,callback:()=>this.titleMaxHeightController.setVerticalTitleMaxHeight()}),this.vegaComponentUsageRuntimeMetricsSlimmer=new p,this.renderer=new bt,this.slotController=new Rt,this.subStateController=new yt,this.titleMaxHeightController=new kt,this.timeFormat="24-hour",this.slotMode=!1,this.showColorBar=!0}render(){return H(e("slot",null)),s(e(o,null,this.calendarEvent?this.renderer.render():null),this.host)}get host(){return a(this)}};jt([f()],Dt.prototype,"globalSlimmer",void 0),jt([v()],Dt.prototype,"pageResizeObserverSlimmer",void 0),jt([v()],Dt.prototype,"vegaComponentUsageRuntimeMetricsSlimmer",void 0),jt([v()],Dt.prototype,"renderer",void 0),jt([v()],Dt.prototype,"slotController",void 0),jt([v()],Dt.prototype,"subStateController",void 0),jt([v()],Dt.prototype,"titleMaxHeightController",void 0),Dt.style='.bg-disabled{background-color:rgba(var(--v-bg-disabled, 176, 180, 181, 1))}:host{display:block;box-sizing:border-box;width:100%}:host .background-color-mode{border-radius:2px;color:rgba(var(--v-text-black, 32, 54, 69, 1));font-family:"Inter", sans-serif;font-size:12px;font-weight:700;line-height:16px;letter-spacing:0px;cursor:pointer;overflow:hidden;white-space:nowrap}@media screen and (min-width: 768px) and (max-width: 1023px){:host .background-color-mode{font-family:"Inter", sans-serif;font-size:12px;font-weight:700;line-height:16px;letter-spacing:0px}}@media screen and (min-width: 1024px) and (max-width: 1439px){:host .background-color-mode{font-family:"Inter", sans-serif;font-size:12px;font-weight:700;line-height:16px;letter-spacing:0px}}@media screen and (min-width: 1440px) and (max-width: 9999px){:host .background-color-mode{font-family:"Inter", sans-serif;font-size:12px;font-weight:700;line-height:16px;letter-spacing:0px}}:host .background-color-mode:not(.slot-container){padding-left:8px;padding-right:8px}:host .background-color-mode:focus{outline:2px solid rgba(var(--v-border-color-action, 19, 98, 226, 1));outline-offset:0px}:host .event-container{display:block;width:100%;border-radius:4px;cursor:pointer;box-sizing:border-box;overflow:hidden}:host .background-color-mode.slot-container{height:16px;line-height:16px}:host ::slotted(vega-calendar-event-slot){position:relative;pointer-events:none}:host(.month-event) .event-container{display:flex;flex-direction:row;gap:4px;align-items:center;min-height:16px}:host(.month-event) .event-container:not(.slot-container){padding-left:2px;padding-right:2px}:host(.month-event) .event-container .event-status{width:8px;height:8px;box-sizing:border-box;border-top-left-radius:9999px;border-bottom-left-radius:9999px;border-top-right-radius:9999px;border-bottom-right-radius:9999px;margin-left:2px;flex-shrink:0}:host(.month-event) .event-container .event-status span{display:none;width:100%;height:100%;border-top-left-radius:9999px;border-bottom-left-radius:9999px;border-top-right-radius:9999px;border-bottom-right-radius:9999px}:host(.month-event) .event-container .event-title{font-family:"Inter", sans-serif;font-size:12px;font-weight:400;line-height:16px;color:rgba(var(--v-text-primary, 32, 54, 69, 1));flex-grow:1;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}@media screen and (min-width: 768px) and (max-width: 1023px){:host(.month-event) .event-container .event-title{font-family:"Inter", sans-serif;font-size:12px;font-weight:400;line-height:16px}}@media screen and (min-width: 1024px) and (max-width: 1439px){:host(.month-event) .event-container .event-title{font-family:"Inter", sans-serif;font-size:12px;font-weight:400;line-height:16px}}@media screen and (min-width: 1440px) and (max-width: 9999px){:host(.month-event) .event-container .event-title{font-family:"Inter", sans-serif;font-size:12px;font-weight:400;line-height:16px}}:host(.month-event) .event-container.secondary .event-status span{display:block;background-size:4px 4px;opacity:0.8}:host(.month-event) .event-container.tertiary .event-status{padding:1px}:host(.month-event) .event-container.tertiary .event-status span{display:block;background-color:rgba(var(--v-bg-primary, 252, 252, 252, 1))}:host(.month-event) .event-container.disabled .event-status{background-color:rgba(var(--v-bg-disabled, 176, 180, 181, 1))}:host(.month-event) .event-container:hover{background-color:rgba(var(--v-bg-action-secondary-hover, 4, 112, 236, 0.1))}:host(.month-event) .event-container:active{background-color:rgba(var(--v-bg-action-secondary-active, 29, 65, 195, 0.1))}:host(.month-event) .event-container:focus{outline:2px solid rgba(var(--v-border-color-action, 19, 98, 226, 1));outline-offset:0px}:host(.day-event) .event-container{position:relative}:host(.day-event) .event-container:not(.slot-container){padding-left:8px;padding-right:8px}:host(.day-event) .event-container .event-status{position:absolute;width:4px;height:100%;left:0;top:0;z-index:1}:host(.day-event) .event-container .event-status span{display:none}:host(.day-event) .event-container .cover-block{position:absolute;height:100%;width:100%;background-color:rgba(var(--v-bg-primary, 252, 252, 252, 1));border-radius:4px;left:0;top:0;opacity:0.7}:host(.day-event) .event-container .event-content,:host(.day-event) .event-container .event-time{display:flex;flex-direction:row;align-items:center}:host(.day-event) .event-container .event-content{gap:8px;position:relative;height:100%;box-sizing:border-box}:host(.day-event) .event-container .event-time{gap:4px;color:rgba(var(--v-text-primary, 32, 54, 69, 1));font-family:"Inter", sans-serif;font-size:12px;font-weight:400;line-height:16px}@media screen and (min-width: 768px) and (max-width: 1023px){:host(.day-event) .event-container .event-time{font-family:"Inter", sans-serif;font-size:12px;font-weight:400;line-height:16px}}@media screen and (min-width: 1024px) and (max-width: 1439px){:host(.day-event) .event-container .event-time{font-family:"Inter", sans-serif;font-size:12px;font-weight:400;line-height:16px}}@media screen and (min-width: 1440px) and (max-width: 9999px){:host(.day-event) .event-container .event-time{font-family:"Inter", sans-serif;font-size:12px;font-weight:400;line-height:16px}}:host(.day-event) .event-container .event-time vega-icon{flex-shrink:0}:host(.day-event) .event-container .event-time span{white-space:nowrap}:host(.day-event) .event-container .event-title{color:rgba(var(--v-text-primary, 32, 54, 69, 1));font-family:"Inter", sans-serif;font-size:12px;font-weight:700;line-height:16px;letter-spacing:0px}@media screen and (min-width: 768px) and (max-width: 1023px){:host(.day-event) .event-container .event-title{font-family:"Inter", sans-serif;font-size:12px;font-weight:700;line-height:16px;letter-spacing:0px}}@media screen and (min-width: 1024px) and (max-width: 1439px){:host(.day-event) .event-container .event-title{font-family:"Inter", sans-serif;font-size:12px;font-weight:700;line-height:16px;letter-spacing:0px}}@media screen and (min-width: 1440px) and (max-width: 9999px){:host(.day-event) .event-container .event-title{font-family:"Inter", sans-serif;font-size:12px;font-weight:700;line-height:16px;letter-spacing:0px}}:host(.day-event) .event-container .event-title.title-word-wrap{overflow:hidden}:host(.day-event) .event-container .event-title:not(.title-word-wrap){white-space:nowrap}:host(.day-event) .event-container.duration-half-an-hour{padding-top:8px;padding-bottom:8px}:host(.day-event) .event-container.vertical{height:100%}:host(.day-event) .event-container.vertical .event-content{flex-direction:column;align-items:flex-start;gap:4px;padding-top:8px;padding-bottom:8px}:host(.day-event) .event-container.secondary .event-status span,:host(.day-event) .event-container.tertiary .event-status span{display:block;position:absolute;border-top-left-radius:4px;border-bottom-left-radius:4px}:host(.day-event) .event-container.secondary .cover-block,:host(.day-event) .event-container.tertiary .cover-block{width:calc(100% - 2px);height:calc(100% - 2px);top:1px;left:1px}:host(.day-event) .event-container.secondary .event-status span{width:100%;height:100%;top:0px;left:0px;background-size:4px 4px;opacity:0.8}:host(.day-event) .event-container.secondary .cover-block{opacity:0.9}:host(.day-event) .event-container.tertiary .event-status span{background-color:rgba(var(--v-bg-primary, 252, 252, 252, 1));width:2px;height:calc(100% - 2px);top:1px;left:1px}:host(.day-event) .event-container.tertiary .cover-block{opacity:1}:host(.day-event) .event-container.disabled{background-color:rgba(var(--v-bg-disabled, 176, 180, 181, 1))}:host(.day-event) .event-container.disabled .event-status{background-color:rgba(var(--v-bg-disabled, 176, 180, 181, 1))}:host(.day-event) .event-container:focus{outline:2px solid rgba(var(--v-border-color-action, 19, 98, 226, 1));outline-offset:0px}:host(.day-event) .slot-container{min-height:16px}:host(.month-event.calendar-event-large-size) .background-color-mode{border-radius:4px}:host(.month-event.calendar-event-large-size) .background-color-mode:not(.slot-container){padding-top:4px;padding-bottom:4px}:host(.month-event.calendar-event-large-size) .event-container:not(.slot-container){padding-top:4px;padding-bottom:4px}:host(.month-event.calendar-event-large-size) .slot-container{height:24px;display:flex;align-items:center;line-height:24px}.stripe{background-image:linear-gradient(-45deg, transparent 25%, rgba(var(--v-bg-primary, 252, 252, 252, 1)) 25% 50%, transparent 50% 75%, rgba(var(--v-bg-primary, 252, 252, 252, 1)) 75% 100%)}';var Et=function(e,t,n,i){var r,o=arguments.length,a=o<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,n,i);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,n,a):r(t,n))||a);return o>3&&a&&Object.defineProperty(t,n,a),a};class zt extends d{registerEventPreviewUpdateObserver(){w.addUniqueObserverToNode(this.host,S,(e=>{this.previewPayload=e,this.currentEvent=e.event})),w.addUniqueObserverToNode(this.host,I,(()=>{this.currentEvent=null}))}unregisterEventPreviewUpdateObserver(){w.removeUniqueObserverFromNode(this.host,S),w.removeUniqueObserverFromNode(this.host,I)}}Et([l()],zt.prototype,"host",void 0),Et([l({writable:!0})],zt.prototype,"currentEvent",void 0),Et([l({writable:!0})],zt.prototype,"previewPayload",void 0),Et([c("connectedCallback")],zt.prototype,"registerEventPreviewUpdateObserver",null),Et([c("disconnectedCallback")],zt.prototype,"unregisterEventPreviewUpdateObserver",null);var Mt=function(e,t,n,i){var r,o=arguments.length,a=o<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,n,i);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,n,a):r(t,n))||a);return o>3&&a&&Object.defineProperty(t,n,a),a};class Ot extends d{render(){return this.currentEvent&&e("vega-box",{class:"event-preview"},this.injectBackgroundColorStyle(),this.renderActions(),e("vega-box",{class:"preview-content"},e("vega-flex",{gap:"size-16",direction:"col"},this.renderBasicFields(),this.renderDivider(),e("slot",{name:"event-preview-additional-fields"}))))}renderActions(){return e("vega-flex",{justifyContent:"end",class:"preview-actions"},e("vega-button-circle",{icon:R.getIconKey("close"),color:"text-primary",variant:"icon-only",onVegaClick:()=>{V.notify(L,this.currentEvent)}}))}renderBasicFields(){const n=this.currentEvent;return e(t,null,e("vega-flex",{alignItems:"start",gap:"size-16"},this.renderEventTitle()),e("vega-flex",{alignItems:"start",gap:"size-12"},e("vega-icon",{icon:R.getIconKey("clock"),color:"text-secondary"}),e("vega-flex",{direction:"col",gap:"size-4"},e("vega-font",{variant:"font-footnote1-long",color:"text-primary"},n.generateDateTimeString(this.previewPayload.targetCalendarViewDate,this.previewPayload.timeFormat)),n.isRepeatEvent&&e("vega-font",{variant:"font-footnote1-long",color:"text-primary"},n.generateRepeatString()))))}renderEventTitle(){const n=this.currentEvent,i=me(n.event.key);return this.host.querySelector(`[slot=${i}]`)?e("slot",{name:i}):e(t,null,e("vega-box",{corners:"rounded-full",class:{"event-bg-color":!0,"event-bg-disabled":n.disabled},flexShrink:0},e("span",{class:{[`event-color-dot-${n.variant}`]:!0}})),e("vega-font",{variant:"font-h5",color:"text-primary"},n.title))}renderDivider(){return this.host.querySelector("[slot=event-preview-additional-fields]")&&e("vega-box",null,e("vega-divider",null))}injectBackgroundColorStyle(){return e("style",null,ge(this.currentEvent.color))}}R.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>'}}),Mt([l()],Ot.prototype,"host",void 0),Mt([l()],Ot.prototype,"previewPayload",void 0),Mt([l()],Ot.prototype,"currentEvent",void 0);var Pt=function(e,t,n,i){var r,o=arguments.length,a=o<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,n,i);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,n,a):r(t,n))||a);return o>3&&a&&Object.defineProperty(t,n,a),a};const It=class{constructor(e){i(this,e),this.detailRenderer=new Ot,this.stateController=new zt,this.translationSlimmer=new _,this.globalSlimmer={},this.vegaComponentUsageRuntimeMetricsSlimmer=new p}render(){return s(e(o,null,this.previewPayload&&this.detailRenderer.render()),this.host)}get host(){return a(this)}};Pt([v()],It.prototype,"detailRenderer",void 0),Pt([v()],It.prototype,"stateController",void 0),Pt([v()],It.prototype,"translationSlimmer",void 0),Pt([f()],It.prototype,"globalSlimmer",void 0),Pt([v()],It.prototype,"vegaComponentUsageRuntimeMetricsSlimmer",void 0),It.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 St=function(e,t,n,i){var r,o=arguments.length,a=o<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,n,i);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,n,a):r(t,n))||a);return o>3&&a&&Object.defineProperty(t,n,a),a};const $t=class{constructor(e){i(this,e),this.globalSlimmer={},this.vegaComponentUsageRuntimeMetricsSlimmer=new p}render(){return s(e(o,{slot:me(this.eventKey)},e("slot",null)),this.host)}get host(){return a(this)}};St([f()],$t.prototype,"globalSlimmer",void 0),St([v()],$t.prototype,"vegaComponentUsageRuntimeMetricsSlimmer",void 0),$t.style=":host{width:100%;height:100%;position:relative}";export{ut as vega_calendar,Dt as vega_calendar_event,It as vega_calendar_event_preview,$t as vega_calendar_event_slot}
|
|
1
|
+
import{h as e,F as t,f as n,r as i,c as r,H as o,g as a}from"./p-48a58baf.js";import{s}from"./p-519a7d55.js";import{c as l,V as d,M as c,L as h,I as v}from"./p-6e1ab235.js";import{V as p,I as f}from"./p-d849e0f5.js";import{D as w}from"./p-0cd89fb6.js";import{a as u,f as m,b as g,N as b,d as x,g as y,h as k,i as C}from"./p-b5822a21.js";import{V as R}from"./p-f08a4adf.js";import{p as j}from"./p-08835909.js";import{c as D}from"./p-4474bc63.js";import{V as E}from"./p-bf0ced3c.js";import{s as z}from"./p-824a06ba.js";import{q as M}from"./p-b1faebe0.js";import{C as O}from"./p-bbb96a13.js";import{v as P,w as S,x as I}from"./p-b5bef48a.js";import{c as $}from"./p-86194314.js";import{O as T}from"./p-331a62d5.js";import{C as V}from"./p-2d0d575f.js";import{m as L}from"./p-8a877e12.js";import{f as B}from"./p-d27ae9ff.js";import{g as N}from"./p-a4670e23.js";import{P as A}from"./p-7d9cd9c8.js";import{d as F}from"./p-1bc5b3bc.js";import{c as W}from"./p-9773c913.js";import{T as _}from"./p-02b29c18.js";import{s as H}from"./p-6bd5c49b.js";import{S as U}from"./p-1bd516c5.js";import{b as Y}from"./p-0c667d6a.js";import"./p-575235c8.js";import"./p-8c46e116.js";import"./p-6a334573.js";import"./p-af464251.js";import"./p-b75ee3ba.js";import"./p-ed45b3b6.js";import"./p-74168615.js";import"./p-d884c644.js";import"./p-5f377954.js";import"./p-e77a83e4.js";import"./p-db8cdba6.js";import"./p-112455b1.js";import"./p-262ec334.js";var q=function(e,t,n,i){var r,o=arguments.length,a=o<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,n,i);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,n,a):r(t,n))||a);return o>3&&a&&Object.defineProperty(t,n,a),a};class K extends d{getEventPreviewRef(){return this.eventPreviewRef}render(){return e(t,null,this.switchPanelRenderer.render(),this.viewRenderer.render(),e("vega-calendar-event-preview",{ref:e=>{this.eventPreviewRef=e}}))}}q([l()],K.prototype,"host",void 0),q([l()],K.prototype,"switchPanelRenderer",void 0),q([l()],K.prototype,"viewRenderer",void 0);var X=function(e,t,n,i){var r,o=arguments.length,a=o<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,n,i);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,n,a):r(t,n))||a);return o>3&&a&&Object.defineProperty(t,n,a),a};class Z extends d{constructor(){super(...arguments),this.handleViewChange=e=>{this.currentPeriodController.updateCalendarPeriod(e.detail,this.postOperationDate)},this.todayButtonClick=()=>{this.currentPeriodController.setCurrentPeriod(this.currentPeriod.now())},this.nextButtonClick=()=>{this.currentPeriodController.setCurrentPeriod(this.currentPeriod.next())},this.prevButtonClick=()=>{this.currentPeriodController.setCurrentPeriod(this.currentPeriod.previous())},this.moreActionMenuClick=e=>{this.moreActionClickEmitter.emit(e.detail)}}getSwitchPanelRef(){return this.switchPanelRef}render(){return e("vega-flex",{direction:"row",gap:"size-16",justifyContent:"space-between",alignItems:"center",class:"calendar-switch-panel",ref:e=>this.switchPanelRef=e},this.renderDateSwitch(),e("div",{class:"calendar-view-switch-container"},this.showSwitchView?this.renderViewSwitch():null,this.renderMoreActionMenu()))}renderDateSwitch(){return e("div",{class:"calendar-date-switch-container"},e("vega-button",{variant:"secondary",size:"small",ref:e=>{w.addUniqueObserverToNode(e,u,this.todayButtonClick)},label:this.translationSlimmer.t("Today")}),e("vega-button-circle",{variant:"secondary",size:"small",icon:R.getIconKey("chevron-left"),label:"previous",showTooltip:!1,ref:e=>{w.addUniqueObserverToNode(e,u,this.prevButtonClick)}}),e("vega-button-circle",{variant:"secondary",size:"small",icon:R.getIconKey("chevron-right"),label:"next",showTooltip:!1,ref:e=>{w.addUniqueObserverToNode(e,u,this.nextButtonClick)}}),this.renderCurrentPeriod())}renderCurrentPeriod(){return e("vega-font",{class:"calendar-current-date",variant:"font-field-label",color:"text-primary"},this.getViewDateSummary())}renderViewSwitch(){return e("vega-segment-control",{segments:Z.views.map((e=>Object.assign(Object.assign({},e),{text:this.translationSlimmer.t(e.text)}))),size:"small",variant:"text-only",selected:this.viewMode,ref:e=>{w.addUniqueObserverToNode(e,m,this.handleViewChange)}})}renderMoreActionMenu(){var t,n;if(null===(n=null===(t=this.moreActionDropdownProps)||void 0===t?void 0:t.source)||void 0===n?void 0:n.length)return e("vega-dropdown",Object.assign({alignment:"end",trigger:"click"},this.moreActionDropdownProps,{ref:e=>{w.addUniqueObserverToNode(e,g,this.moreActionMenuClick)}}),e("vega-button-circle",{size:"small",icon:R.getIconKey("ellipsis-vertical"),variant:"icon-only"}))}getViewDateSummary(){const e=this.currentPeriod.current;let t="";switch(this.viewMode){case"day":{const n=this.translationSlimmer.t(e.getMonthName());t=`${e.date} ${n}, ${e.year}`;break}case"week":{const e=this.calendarView.dateItems[0],n=e[0],i=e[e.length-1],[r,o]=[n,i].map((e=>this.translationSlimmer.t(e.getMonthName())));t=`${n.date} ${r}${n.year===i.year?"":", "+n.year} - ${i.date} ${o}, ${i.year}`;break}case"month":t=`${this.translationSlimmer.t(e.getMonthName())}, ${e.year}`}return t}}R.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>'}}),Z.views=[{text:"Day",key:"day"},{text:"Week",key:"week"},{text:"Month",key:"month"}],X([l()],Z.prototype,"viewMode",void 0),X([l()],Z.prototype,"calendarView",void 0),X([l()],Z.prototype,"currentPeriod",void 0),X([l()],Z.prototype,"moreActionDropdownProps",void 0),X([l()],Z.prototype,"moreActionClickEmitter",void 0),X([l()],Z.prototype,"currentPeriodController",void 0),X([l()],Z.prototype,"calendarViewController",void 0),X([l()],Z.prototype,"translationSlimmer",void 0),X([l()],Z.prototype,"postOperationDate",void 0),X([l()],Z.prototype,"showSwitchView",void 0);var G=function(e,t,n,i){var r,o=arguments.length,a=o<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,n,i);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,n,a):r(t,n))||a);return o>3&&a&&Object.defineProperty(t,n,a),a};class J extends d{getCalendarViewElementRef(){return this.calendarViewElementRef}render(){return e("div",{class:`calendar-view calendar-view-${this.viewMode} ${!1===this.showWeekends?"calendar-hide-weekends":""}`,ref:e=>this.calendarViewElementRef=e},"month"===this.viewMode?this.monthViewRenderer.render():this.viewWithTimeRenderer.render())}}G([l()],J.prototype,"viewMode",void 0),G([l()],J.prototype,"showWeekends",void 0),G([l()],J.prototype,"monthViewRenderer",void 0),G([l()],J.prototype,"viewWithTimeRenderer",void 0);var Q=function(e,t,n,i){var r,o=arguments.length,a=o<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,n,i);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,n,a):r(t,n))||a);return o>3&&a&&Object.defineProperty(t,n,a),a};class ee extends d{render(){return e("div",{class:"calendar-view-month-container"},e("div",{class:"calendar-view-row calendar-view-title border-divider-bottom"},this.calendarView.weekdays.map((t=>e("div",{key:t},this.translationSlimmer.t(t))))),this.renderMonthViewContent())}renderMonthViewContent(){const t=this.currentPeriod.current;return this.calendarView.dateItems.map(((n,i)=>{const r=this.monthEventRenderer.getCurrentRowEvents(n),o=this.monthEventRenderer.filterRowDisplayEvents(r);return e("div",{key:i,class:"calendar-view-row border-divider-bottom"},n.map(((n,i)=>{var a;const s=null===(a=this.isDateDisabled)||void 0===a?void 0:a.call(this,n.toDate());return e("div",{class:{"row-cell border-divider-right":!0,"current-month-day":n.compare(t).inMonth,active:n.isToday(),disabled:s},key:`${n.month}-${n.date}`,onDblClick:s?void 0:e=>{this.handleDateBlockClick(e,n)}},this.renderDateBlock(n),this.monthEventRenderer.render(n,r[i],o[i],i))})))}))}renderDateBlock(t){return e("div",{class:"date"},1===t.date&&e("div",{class:"month-block"},t.getMonthName(!0)),e("div",{role:"button",tabIndex:0,class:"grid-col",onDblClick:e=>{this.showSwitchView?this.goToCurrentDayView(e,t):e.stopPropagation()}},t.date))}goToCurrentDayView(e,t){e.stopPropagation(),this.currentPeriodController.updateCalendarPeriod("day",t)}handleDateBlockClick(e,t){const{target:n,clientX:i,clientY:r}=e;if(this.isMonthBlockBlankArea(n)){const{year:e,month:n,date:o}=t;this.dateDblClickEmitter.emit({year:e,month:n,date:o,hour:0,mouseEventInfo:{clientX:i,clientY:r}})}}isMonthBlockBlankArea(e){return!e.classList.contains("more-button")&&"VEGA-CALENDAR-EVENT"!==e.tagName}}Q([l()],ee.prototype,"viewMode",void 0),Q([l()],ee.prototype,"calendarView",void 0),Q([l()],ee.prototype,"currentPeriod",void 0),Q([l()],ee.prototype,"currentPeriodController",void 0),Q([l()],ee.prototype,"monthEventRenderer",void 0),Q([l()],ee.prototype,"dateDblClickEmitter",void 0),Q([l()],ee.prototype,"translationSlimmer",void 0),Q([l()],ee.prototype,"isDateDisabled",void 0),Q([l()],ee.prototype,"showSwitchView",void 0);var te=function(e,t,n,i){var r,o=arguments.length,a=o<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,n,i);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,n,a):r(t,n))||a);return o>3&&a&&Object.defineProperty(t,n,a),a};class ne extends d{render(){return e("div",{class:"calendar-view-container"},this.renderViewTitle(),this.renderViewContent())}renderViewTitle(){const t=this.calendarView.dateItems[0],n=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,i)=>e("div",{key:t.date,class:{active:t.isToday()}},e("div",null,this.translationSlimmer.t(n[i])),e("div",{class:"week-day"},t.date)))))),e("div",{class:"calendar-view-row calendar-view-event-all-container border-divider-bottom"},e("div",{class:"time-line-all"},this.translationSlimmer.t("All Day")),this.dayViewFullDayEventRenderer.render()))}renderViewContent(){const t=this.calendarView.dateItems[0];return e("div",{class:"calendar-view-row calendar-view-day-container"},this.timeLineRenderer.render(),e("div",{class:"calendar-view-content-container"},e("div",{class:"calendar-view-content"},t.map((t=>{var n;const i=null===(n=this.isDateDisabled)||void 0===n?void 0:n.call(this,t.toDate());return e("div",{class:{"grid-col border-divider-left":!0,disabled:i},key:t.date},e("div",{class:"hour-empty border-divider-top"}),this.renderHourBlock(t,i))}))),this.dayViewTimedEventRenderer.render(),this.timeMarkerRenderer.render(t)))}renderHourBlock(t,n){return Array(24).fill("").map(((i,r)=>{var o;let a=!1;if(!n){const e=new Date(t.toDate().setHours(r));a=null===(o=this.isDateDisabled)||void 0===o?void 0:o.call(this,e)}return e("div",{class:{"grid-cell border-divider-top":!0,disabled:n||a},onDblClick:n||a?void 0:e=>this.handleDateBlockClick(t,r,e)})}))}handleDateBlockClick(e,t,n){const{year:i,month:r,date:o}=e,{clientX:a,clientY:s}=n;this.dateDblClickEmitter.emit({year:i,month:r,date:o,hour:t,mouseEventInfo:{clientX:a,clientY:s}})}}te([l()],ne.prototype,"viewMode",void 0),te([l()],ne.prototype,"timeLineRenderer",void 0),te([l()],ne.prototype,"timeMarkerRenderer",void 0),te([l()],ne.prototype,"dayViewTimedEventRenderer",void 0),te([l()],ne.prototype,"dayViewFullDayEventRenderer",void 0),te([l()],ne.prototype,"calendarView",void 0),te([l()],ne.prototype,"dateDblClickEmitter",void 0),te([l()],ne.prototype,"translationSlimmer",void 0),te([l()],ne.prototype,"isDateDisabled",void 0);class ie extends d{render(){const t=this.getTimeLineTitles();return e("div",{class:"time-line"},e("div",{class:"hour-empty"}),t.map(((t,n)=>e("div",{key:t},e("div",{class:"time-text","data-time":0===n?24:n},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(`${j(t)}`);return e}}!function(e,t,n,i){var r,o=arguments.length,a=o<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,n,i);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,n,a):r(t,n))||a);o>3&&a&&Object.defineProperty(t,n,a)}([l()],ie.prototype,"timeFormat",void 0);const re=(e=0)=>{const t=[0,1,2,3,4,5,6];return t.concat(t).slice(e,e+7)};var oe;!function(e){e.sun="Sunday",e.mon="Monday",e.tue="Tuesday",e.wed="Wednesday",e.thu="Thursday",e.fri="Friday",e.sat="Saturday"}(oe||(oe={}));const ae=(e,t)=>{const[n,i]=t.split(":");if("24-hour"===e)return`${n.padStart(2,"0")}:${i.padStart(2,"0")}`;{const e=Number(n),t=e>=12?"pm":"am",r=i.padStart(2,"0");return e>12?`${e-12}:${r} ${E.t("pm")}`:0===e?`12:${r} ${E.t("am")}`:`${e}:${r} ${E.t(t)}`}};class se{constructor(){this.WEEKDAYS_SHORT=["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],this.weekdays=re()}getWeekdayNames(){return this.WEEKDAYS_SHORT}generateDates(e){const t=e.startDate.toDate(),n=[];for(let i=0;i<e.count;i++)n.push(new Date(t)),t.setDate(t.getDate()+1);return n}generateWeekHead(){return this.weekdays.map((e=>this.getWeekdayNames()[e]))}}class le{constructor(e,t){this._weekdays=e,this._dateItems=t}get weekdays(){return this._weekdays}get dateItems(){return this._dateItems}}class de extends se{generate(e){return new le([this.generateWeekHead()[e.current.toDate().getDay()]],[[e.current]])}}class ce{constructor(e,t,n){this._date=n,this._month=t,this._year=e}static from(e){return new ce(e.getFullYear(),e.getMonth()+1,e.getDate())}get year(){return this._year}set year(e){this._year=e}get month(){return this._month}set month(e){this._month=e}get date(){return this._date}set date(e){this._date=e}isToday(){const e=new Date;return e.getFullYear()===this.year&&e.getMonth()+1===this.month&&e.getDate()===this.date}toDate(){return new Date(this.year,this.month-1,this.date)}compare(e){const{year:t,month:n}=e,i={isPreviousMonth:!1,inMonth:!1,isNextMonth:!1};return this.year===t?this.month<n?i.isPreviousMonth=!0:this.month>n?i.isNextMonth=!0:i.inMonth=!0:this.year>t?i.isNextMonth=!0:i.isPreviousMonth=!0,i}equal(e){const{year:t,month:n,date:i}=e;return this._year===t&&this._month===n&&this._date===i}getMonthName(e=!1){return E.t(this.toDate().toLocaleDateString("en-US",{month:e?"short":"long"}))}}class he extends se{generate(e){const t=this.generateDates(e),n=e.showWeekends;let i=this.generateWeekHead(),r=[t.map(ce.from)];return!1===n&&(i=i.slice(1,6),r=r.map((e=>e.slice(1,6)))),new le(i,r)}}class ve extends se{generate(e){const t=e.showWeekends;let n=[],i=[];this.generateDates(e).forEach(((e,t)=>{t%7||(n[t/7]=i=[]);const r=ce.from(e);i.push(r)}));let r=this.generateWeekHead();return!1===t&&(r=r.slice(1,6),n=n.map((e=>e.slice(1,6)))),new le(r,n)}}class pe{constructor(e,t){this._count=e,this._current=t||ce.from(new Date),this.calculatePeriod(this._current)}get current(){return this._current}get startDate(){return this._startDate}get endDate(){return this._endDate}get count(){return this._count}get type(){return this._type}get showWeekends(){return this._showWeekends}goTo(e){return this.createBy(e)}now(){return this.createBy(ce.from(new Date))}calculatePeriod(e){const t=e.toDate();this.count>1&&t.setDate(t.getDate()-re().indexOf(t.getDay())),this._startDate=ce.from(t),t.setDate(t.getDate()+this.count-1),this._endDate=ce.from(t)}}var fe;function we(e,t=15){const[n,i]=e.split(":");return Math.round((60*Number(n)+Number(i))/t)}function ue(e){return"vega-calendar-event-slot-"+e}function me(e,t=fe.NEXT){const n=e.toDate().getDay();if(0===n||6===n){let i=0===n?1:2;return t===fe.PREVIOUS&&(i=0===n?-2:-1),ce.from(new Date(e.year,e.month-1,e.date+i))}return e}function ge(e="bg-accent6-primary"){return M(e)?`.event-bg-color{${z.formatToken(e)}}`:`.event-bg-color{background-color:${e}}`}!function(e){e.PREVIOUS="-1",e.NEXT="1"}(fe||(fe={}));class be extends pe{constructor(e,t){super(be.DISPLAY_DATE_COUNT,e),this._type="day",this._showWeekends=!0,this._showWeekends=!1!==t}next(){const e=this.current.toDate();e.setDate(e.getDate()+1);let t=ce.from(e);return!1===this._showWeekends&&(t=me(t)),this.createBy(t)}previous(){const e=this.current.toDate();e.setDate(e.getDate()-1);let t=ce.from(e);return!1===this._showWeekends&&(t=me(t,fe.PREVIOUS)),this.createBy(t)}now(){let e=ce.from(new Date);return!1===this._showWeekends&&(e=me(e)),this.createBy(e)}createBy(e){return new be(e,this._showWeekends)}}be.DISPLAY_DATE_COUNT=1;class xe extends pe{constructor(e,t){super(xe.DISPLAY_DATE_COUNT,e),this._type="week",this._showWeekends=!0,this._showWeekends=!1!==t}next(){const e=this.current.toDate();return e.setDate(e.getDate()+7),this.createBy(ce.from(e))}previous(){const e=this.current.toDate();return e.setDate(e.getDate()-7),this.createBy(ce.from(e))}createBy(e){return new xe(e,this._showWeekends)}}xe.DISPLAY_DATE_COUNT=7;class ye extends pe{constructor(e,t){super(ye.DISPLAY_DATE_COUNT,e),this._type="month",this._showWeekends=!0,this._showWeekends=!1!==t}static getMonthFirstDay(e){const t=e||ce.from(new Date);return new ce(t.year,t.month,1)}calculatePeriod(e){const t=ye.getMonthFirstDay(e).toDate();t.setDate(t.getDate()-re().indexOf(t.getDay())),this._startDate=ce.from(t),t.setDate(t.getDate()+this.count-1),this._endDate=ce.from(t)}next(){const e=this.current.toDate();return e.setMonth(e.getMonth()+1),this.createBy(ce.from(e))}previous(){const e=this.current.toDate();return e.setMonth(e.getMonth()-1),this.createBy(ce.from(e))}createBy(e){return new ye(e,this._showWeekends)}}ye.DISPLAY_DATE_COUNT=42;var ke=function(e,t,n,i){var r,o=arguments.length,a=o<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,n,i);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,n,a):r(t,n))||a);return o>3&&a&&Object.defineProperty(t,n,a),a};class Ce extends d{constructor(){super(...arguments),this.monthViewGenerator=new ve,this.weekViewGenerator=new he,this.dayViewGenerator=new de}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}}ke([l({writable:!0})],Ce.prototype,"calendarView",void 0),ke([l()],Ce.prototype,"currentPeriod",void 0),ke([l()],Ce.prototype,"showWeekends",void 0),ke([l()],Ce.prototype,"currentPeriodController",void 0),ke([c("componentWillLoad")],Ce.prototype,"initialCalendarView",null),ke([c("watchCurrentPeriodChange")],Ce.prototype,"generateCalendarView",null);var Re=function(e,t,n,i){var r,o=arguments.length,a=o<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,n,i);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,n,a):r(t,n))||a);return o>3&&a&&Object.defineProperty(t,n,a),a};class je extends d{setCurrentPeriod(e){this.currentPeriod=e}updateCalendarPeriod(e,t){switch(e){case"month":this.setCurrentPeriod(new ye(t,this.showWeekends));break;case"week":this.setCurrentPeriod(new xe(t,this.showWeekends));break;case"day":t=!1===this.showWeekends?me(t):t,this.setCurrentPeriod(new be(t,this.showWeekends))}}initialCurrentPeriod(){this.updateCalendarPeriod(this.viewMode,ce.from(new Date))}emitChangeEvent(e,t){e&&t&&e.startDate.equal(t.startDate)&&e.endDate.equal(t.endDate)||(e&&e.type!==this.viewMode&&(this.viewMode=e.type),this.changeEventEmitter.emit({viewMode:e.type,currentPeriod:this.getCurrentPeriodSummary()}))}updateCurrentPeriodByViewMode(e){this.currentPeriod&&e!==this.currentPeriod.type&&this.updateCalendarPeriod(e,this.currentPeriod.current)}updateCurrentPeriodAfterHideWeekEndsChange(){this.updateCalendarPeriod(this.viewMode,this.currentPeriod.current)}getCurrentPeriodSummary(){const{current:e,startDate:t,endDate:n}=this.currentPeriod;return{year:e.year,month:e.month,startDate:{date:t.date,month:t.month,year:t.year},endDate:{date:n.date,month:n.month,year:n.year}}}}Re([l({writable:!0})],je.prototype,"currentPeriod",void 0),Re([l()],je.prototype,"changeEventEmitter",void 0),Re([l({writable:!0})],je.prototype,"viewMode",void 0),Re([l()],je.prototype,"showWeekends",void 0),Re([c("componentWillLoad")],je.prototype,"initialCurrentPeriod",null),Re([c("watchCurrentPeriodChange")],je.prototype,"emitChangeEvent",null),Re([c("watchViewModeChange")],je.prototype,"updateCurrentPeriodByViewMode",null),Re([c("watchShowWeekendsChange")],je.prototype,"updateCurrentPeriodAfterHideWeekEndsChange",null);var De=function(e,t,n,i){var r,o=arguments.length,a=o<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,n,i);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,n,a):r(t,n))||a);return o>3&&a&&Object.defineProperty(t,n,a),a};class Ee extends d{constructor(){super(...arguments),this.maxMonthDisplayEventsCount=2,this.popoverHideObserver=null}getCurrentRowEvents(e){const t=[];return e.forEach((e=>{const n=this.calendarEventController.getCurrentDateEvents(e);t.push(n)})),this.fullDayEventLayoutRenderer.sortLongEvents(t)}filterRowDisplayEvents(e){const t=[];return e.forEach((e=>{const n=e.length>this.maxMonthDisplayEventsCount?e.slice(0,this.maxMonthDisplayEventsCount-1):e;t.push(n)})),this.hideTheCutOffEvents(e,t)}getMonthEventContainerRef(){return this.eventContainerRef}render(t,n,i,r){const o=n.slice(i.length).filter((e=>e)).length;return e("div",{class:"events-container",ref:e=>this.eventContainerRef=e},e("div",{class:"event-list"},this.fullDayEventLayoutRenderer.render(i,r,t)),this.renderMoreButton(n,o,t))}addMaxDisplayCountChange(){w.addUniqueObserverToNode(this.host,P,(e=>{this.maxMonthDisplayEventsCount=e.detail,"month"===this.viewMode&&n(this.host)}))}renderMoreButton(t,n,i){if(n){const r=t.filter((e=>e&&(e.isAllDayEvent||e.isGroupEvent()))),o=t.filter((e=>e&&!e.isAllDayEvent&&!e.isGroupEvent()));return e("div",{class:"month-event-more"},e("vega-popover",{trigger:"click",placement:"right",padding:"0",ref:e=>{this.setPopoverHideObserver(e,t)},isScreenPosition:!0},e("div",{tabIndex:0,slot:"popover-content",role:"button",class:"more-button",onKeyDown:$()},`${n} 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"}},`${i.date} ${i.getMonthName()} ${i.year}`),e("vega-box",{maxHeight:"calc(60vh - 6px)",style:{overflowY:"auto"},padding:"size-4"},e("vega-flex",{direction:"col",gap:"size-4",style:{paddingBottom:o.length?"4px":"0px"}},r.map((e=>this.eventItemRenderer.render(e,{"month-event":!0,"calendar-event-large-size":!0,"calendar-event-in-popover":!0},i,!0)))),o.map((e=>this.eventItemRenderer.render(e,{"month-event":!0,"calendar-event-large-size":!0,"calendar-event-in-popover":!0},i,!0)))))),e("div",{class:"preview-container",ref:e=>{e?this.eventPreviewPopoverController.setEventPreviewContainerMap(t,i,e):this.eventPreviewPopoverController.deleteEventPreviewContainer(t,i)}}))))}}hideTheCutOffEvents(e,t){const n=[],i=[],r=t.map((e=>e[e.length-1])).filter((e=>e&&e.isGroupEvent()));return r.length&&r.forEach((n=>{e.filter((e=>e.includes(n))).length>t.filter((e=>e.includes(n))).length&&i.push(n)})),i.length?(t.forEach((e=>{e.length&&e[e.length-1]&&i.includes(e[e.length-1])?n.push(e.slice(0,e.length-1)):n.push(e)})),n):t}setPopoverHideObserver(e,t){e?(this.popoverHideObserver=new T((e=>t.includes(e)),(async()=>await e.hide())),V.register(L,this.popoverHideObserver)):this.popoverHideObserver&&V.unregister(L,this.popoverHideObserver),e&&w.addUniqueObserverToNode(e,b,(()=>{V.notify(x.getSubject(this.renderer.getEventPreviewRef(),S),{})}))}}De([l()],Ee.prototype,"viewMode",void 0),De([l()],Ee.prototype,"host",void 0),De([l()],Ee.prototype,"calendarEventController",void 0),De([l()],Ee.prototype,"eventItemRenderer",void 0),De([l()],Ee.prototype,"fullDayEventLayoutRenderer",void 0),De([l()],Ee.prototype,"eventPreviewPopoverRenderer",void 0),De([l()],Ee.prototype,"renderer",void 0),De([l()],Ee.prototype,"eventPreviewPopoverController",void 0),De([c("componentWillLoad")],Ee.prototype,"addMaxDisplayCountChange",null);class ze{constructor(e,t,n,i){this.repeatStartDate=e,this.interval=t,this.count=n,this.until=i}getRepeatSeries(e,t=1){return this.generateRepeatDateCacheUntilEndDate(e.endDate),this.cache.filter((n=>this.isSeriesInPeriod(n,t,e)))}isSeriesInPeriod(e,t,n){const i=e.toDate(),r=new Date(e.year,e.month-1,e.date+t-1),{startDate:o,endDate:a}=n,s=o.toDate(),l=a.toDate();return i>=s&&i<=l||r>=s&&r<=l||i<=s&&r>=l}generateRepeatEndsString(){return this.until?` ${E.t("until {0}",`${this.until.getMonthName()} ${this.until.date}, ${this.until.year}`)}`:this.count?` ${E.t("after {0} occurrences",this.count)}`:""}}ze.daySeconds=864e5;class Me extends ze{constructor(e,t,n,i){super(e,t,n,i),this.initCache()}generateRepeatString(){return(this.interval>1?E.t("Repeat every {0} days",this.interval):E.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 n=this.getNextRepeatStartDate(t);for(;n&&n.toDate()<e.toDate();){const e=this.getNextRepeatStartDate(n);if(e&&e.toDate()<=n.toDate()){this.cache.pop();break}if(n=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),n=ce.from(t);return this.until&&t>this.until.toDate()||"number"==typeof this.count&&this.cache.length>=this.count?null:(this.cache.push(n),n)}}class Oe extends ze{constructor(e,t,n,i){super(e,t,n,i),this.byMonthDay=this.repeatStartDate.date,this.initCache()}generateRepeatString(){return(this.interval>1?E.t("Repeat every {0} months on day {1}",this.interval,this.byMonthDay):E.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 n=this.getNextRepeatStartDate(t);for(;n&&n.toDate()<e.toDate();){const e=this.getNextRepeatStartDate(n);if(e&&e.toDate()<=n.toDate()){this.cache.pop();break}if(n=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),n=ce.from(t);return this.until&&t>this.until.toDate()||"number"==typeof this.count&&this.cache.length>=this.count?null:(this.cache.push(n),n)}getNextStartDate(e,t){const n=new Date(e,t,this.byMonthDay);return n.getDate()===this.byMonthDay?n:this.getNextStartDate(e,t+1)}}class Pe extends ze{constructor(e,t,n,i,r){super(e,t,n,i),this.byWeekDay=this.sortWeekDay(r),this.initCache()}getRepeatSeries(e,t=1){return this.generateRepeatDateCacheUntilEndDate(e.endDate),this.getValidCache().filter((n=>this.isSeriesInPeriod(n,t,e)))}generateRepeatString(){const e=this.byWeekDay.map((e=>E.t(oe[e])));return(this.interval>1?E.t("Repeat every {0} weeks on {1}",this.interval,e.join(", ")):E.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 n=this.getNextRepeatStartDate(t);for(;n&&n[0].toDate()<e.toDate();){const e=this.getNextRepeatStartDate(n);if(e&&e[0]&&e[0].toDate()<=n[0].toDate()){this.cache.pop();break}if(n=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=>ce.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((n=>{const i=Pe.weekDay.indexOf(n)-t,{year:r,month:o,date:a}=this.repeatStartDate,s=ce.from(new Date(r,o-1,a+i));e.push(s)})),this.cache=[e]}sortWeekDay(e){return e&&e.length?e.map((e=>e.toLocaleLowerCase())).sort(((e,t)=>Pe.weekDay.indexOf(e)-Pe.weekDay.indexOf(t))):[Pe.weekDay[this.getCurrentDayIndex(this.repeatStartDate)]]}getCurrentDayIndex(e){return e.toDate().getDay()}getValidCache(){const e=B(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)}}Pe.weekDay=["Sun","Mon","Tue","Wed","Thu","Fri","Sat"].map((e=>e.toLowerCase()));class Se extends ze{constructor(e,t,n,i){super(e,t,n,i),this.matchDay=this.repeatStartDate.date,this.matchMonth=this.repeatStartDate.month,this.initCache()}generateRepeatString(){const e=E.t(this.repeatStartDate.getMonthName());return(this.interval>1?E.t("Repeat every {0} years on {1} {2}",this.interval,e,this.matchDay):E.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 n=this.getNextRepeatStartDate(t);for(;n&&n.toDate()<e.toDate();){const e=this.getNextRepeatStartDate(n);if(e&&e.toDate()<=n.toDate()){this.cache.pop();break}if(n=e,"number"==typeof this.count&&this.cache.length>=this.count)break}}}getNextRepeatStartDate(e){const t=this.getNextStartDate(e.year+this.interval),n=ce.from(t);return this.until&&t>this.until.toDate()||"number"==typeof this.count&&this.cache.length>=this.count?null:(this.cache.push(n),n)}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 Ie=new class{getPattern(e,t){const n=ce.from(e),{frequency:i,interval:r=1,byWeekDay:o,until:a,count:s}=t,l=this.initDate(a);return this.initRepeatPattern(i,n,r<1?1:r,s,l,o)}initDate(e){if(e&&"object"==typeof e)return ce.from(e);if(e&&"string"==typeof e){const[t,n,i]=e.split("/");return new ce(Number(i),Number(t),Number(n))}}initRepeatPattern(e,t,n,i,r,o){switch(e){case"daily":return new Me(t,n,i,r);case"weekly":return new Pe(t,n,i,r,o);case"monthly":return new Oe(t,n,i,r);default:return new Se(t,n,i,r)}}},$e=/^\d{1,2}\/\d{1,2}\/\d{4}/,Te=/^\d{1,2}:\d{1,2}/;class Ve{constructor(e,t){this._eventSpansDays=1,this.repeatPattern=null,this._event=e,this._eventKey=t||N(),this.checkEventRequireField(e),this.initDate(e),this.initEventSpansDays(),this.initRepeatPattern()}get event(){return this._event}get eventKey(){return this._eventKey}get title(){return this._event.title}get disabled(){return!!this._event.disabled}get variant(){return this._event.variant}get color(){return this._event.color}get isAllDayEvent(){return!!this._event.isAllDay}get isRepeatEvent(){return null!==this.repeatPattern}get startDate(){return this._startDate}get endDate(){return this._endDate}get startTime(){return this._startTime}get endTime(){return this._endTime}get eventSpansDays(){return this._eventSpansDays}copyTo(e,t){const n=this._eventSpansDays>1?new Date(t.year,t.month-1,t.date+(this._eventSpansDays-1)):t.toDate();return new Ve(Object.assign(Object.assign({},this._event),{startDate:t.toDate(),endDate:n,startTime:this.startTime,endTime:this.endTime}),e)}isGroupEvent(){return this._eventSpansDays>1}isCurrentDayEvent(e){const{startDate:t,endDate:n}=this,i=ce.from(t),r=ce.from(new Date(n.getFullYear(),n.getMonth(),n.getDate()+1)),o=e.toDate();return i.toDate()<=o&&r.toDate()>o}generateRepeatString(){var e;return(null===(e=this.repeatPattern)||void 0===e?void 0:e.generateRepeatString())||""}generateDateTimeString(e,t){const n=E.t(Object.values(oe)[e.toDate().getDay()]),i=ae(t,this.startTime),r=ae(t,this.endTime);return`${n}, ${e.date} ${e.getMonthName(!0)} ${e.year} ${i} - ${r}`}getEventDuration(){const[e,t]=this.startTime.split(":"),[n,i]=this.endTime.split(":"),r=ce.from(new Date),o=new Date(r.year,r.month,r.date,Number(e),Number(t));return(new Date(r.year,r.month,r.date,0===Number(n)&&0!==Number(e)?24:Number(n),Number(i)).valueOf()-o.valueOf())/6e4}getRepeatSeries(e){return this.repeatPattern?this.repeatPattern.getRepeatSeries(e,this._eventSpansDays):[]}convertTimeTo24Hour(e){if((e=e.toLocaleLowerCase()).indexOf("am")>0||e.indexOf("pm")>0){if(e.indexOf("am")>0){e=e.replace("am","").trim();const[t,n]=e.split(":");return`${"12"===t?"00":t}:${n}`}{e=e.replace("pm","").trim();const[t,n]=e.split(":");return`${"12"===t?"12":Number(t)+12}:${n}`}}return e}checkEventRequireField(e){const{title:t,startDate:n,endDate:i,startTime:r,endTime:o}=e;if(n&&"string"==typeof n&&!$e.test(n)||i&&"string"==typeof i&&!$e.test(i))throw new Error("Invalid calendar event item, the date format should be MM/DD/YYYY!");if(r&&"string"==typeof r&&!Te.test(r)||o&&"string"==typeof o&&!Te.test(o))throw new Error("Invalid calendar event item, the time format should be HH:mm!");if(!t||!n||!i&&!o)throw new Error("Invalid calendar event item, the required field should not empty!")}initDate(e){const{startDate:t,startTime:n,endDate:i,endTime:r}=e;if(t&&"object"==typeof t)this._startDate=t;else if(t&&"string"==typeof t){const[e,n,i]=t.split("/");this._startDate=new Date(Number(i),Number(e)-1,Number(n))}if(this._startTime=n?this.convertTimeTo24Hour(n):`${this._startDate.getHours()}:${this._startDate.getMinutes()}`,i&&"object"==typeof i)this._endDate=i;else if(i&&"string"==typeof i){const[e,t,n]=i.split("/");this._endDate=new Date(Number(n),Number(e)-1,Number(t),23,59,59)}else this._endDate=new Date(this._startDate.getFullYear(),this._startDate.getMonth(),this._startDate.getDate(),23,59,59);this._endTime=r?this.convertTimeTo24Hour(r):`${this._endDate.getHours()}:${this._endDate.getMinutes()}`}initRepeatPattern(){this._event.repeatOptions&&this._event.repeatOptions.frequency&&(this.repeatPattern=Ie.getPattern(this._startDate,this._event.repeatOptions))}initEventSpansDays(){const e=ce.from(this.startDate),t=ce.from(this.endDate);this._eventSpansDays=(t.toDate().valueOf()-e.toDate().valueOf())/864e5+1}}var Le=function(e,t,n,i){var r,o=arguments.length,a=o<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,n,i);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,n,a):r(t,n))||a);return o>3&&a&&Object.defineProperty(t,n,a),a};class Be extends d{constructor(){super(...arguments),this.repeatEventMap=new Map}getCurrentDateEvents(e){return this.createRepeatEvents().filter((t=>t.isCurrentDayEvent(e)))}updateAfterEventChange(e){this.initCalendarEvents(e),this.repeatEventMap.clear()}updateWhenComponentWillLoad(){this.initCalendarEvents(this.events)}initCalendarEvents(e){const t=[];e&&e.forEach((e=>{try{const n=new Ve(e);t.push(n)}catch(t){h.warn("Invalid calendar event item:",e)}})),this.calendarEvents=t}createRepeatEvents(){const e=[],t=[];return this.calendarEvents.forEach((n=>{n.isRepeatEvent?n.getRepeatSeries(this.currentPeriod).forEach((e=>{t.push(this.generateCalendarEventByRepeatSeries(n,e))})):e.push(n)})),t.concat(e)}generateCalendarEventByRepeatSeries(e,t){const n=`${e.eventKey}-${t.year}${t.month}${t.date}`;if(this.repeatEventMap.has(n))return this.repeatEventMap.get(n);{const i=e.copyTo(n,t);return this.repeatEventMap.set(n,i),i}}}Le([l()],Be.prototype,"host",void 0),Le([l({writable:!0})],Be.prototype,"calendarEvents",void 0),Le([l()],Be.prototype,"currentPeriod",void 0),Le([l()],Be.prototype,"events",void 0),Le([c("watchEventsChange")],Be.prototype,"updateAfterEventChange",null),Le([c("componentWillLoad")],Be.prototype,"updateWhenComponentWillLoad",null);var Ne=function(e,t,n,i){var r,o=arguments.length,a=o<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,n,i);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,n,a):r(t,n))||a);return o>3&&a&&Object.defineProperty(t,n,a),a};class Ae extends d{render(t,n,i,r=!1){return e("vega-calendar-event",{"data-calendar-ref":this.host,key:t.eventKey,calendarEvent:t,class:n,onKeyDown:$(),onClick:()=>{this.handleEventClick(t),this.enabledEventPreview&&this.setupPreviewContainer(t,i,r)}},!t.isRepeatEvent&&e("slot",{name:ue(t.event.key)}))}handleEventClick(e){this.eventClickEmitter.emit({rawEvent:e.event})}setupPreviewContainer(e,t,n){const i=this.eventPreviewPopoverController.getEventPreviewContainer(e,t,n);if(i){const r=this.renderer.getEventPreviewRef();n?(r.classList.remove("single-event-preview"),r.classList.add("group-event-preview")):(r.classList.remove("group-event-preview"),r.classList.add("single-event-preview")),V.notify(x.getSubject(r,I),{event:e,targetCalendarViewDate:t,timeFormat:this.timeFormat});const o=this.host.querySelector("[slot=event-preview-additional-fields]");o&&r.append(o);const a=ue(e.event.key),s=this.host.querySelector(`[slot=${a}]`),l=r.querySelector(`[slot=${a}]`);s&&!l&&r.append(s.cloneNode(!0)),i.append(r)}}}Ae.backgroundColorModeEventHeight=18,Ne([l()],Ae.prototype,"host",void 0),Ne([l()],Ae.prototype,"calendarView",void 0),Ne([l()],Ae.prototype,"eventClickEmitter",void 0),Ne([l()],Ae.prototype,"timeFormat",void 0),Ne([l()],Ae.prototype,"enabledEventPreview",void 0),Ne([l()],Ae.prototype,"renderer",void 0),Ne([l()],Ae.prototype,"eventPreviewPopoverController",void 0);var Fe=function(e,t,n,i){var r,o=arguments.length,a=o<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,n,i);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,n,a):r(t,n))||a);return o>3&&a&&Object.defineProperty(t,n,a),a};class We extends A{constructor(){super({target:()=>this.host,callback:()=>this.updateMaxDisplayCountWithDebounce()}),this.updateMaxDisplayCountWithDebounce=F(this.updateMaxDisplayCount,500,this)}updateMaxDisplayCount(){try{const e=this.monthEventRenderer.getMonthEventContainerRef();if("month"===this.viewMode&&e&&e.parentElement){const t=e.parentElement.getBoundingClientRect().height,n=Math.floor((t-We.monthDateTitleHeight)/Ae.backgroundColorModeEventHeight);V.notify(x.getSubject(this.host,P),{host:this.host,detail:n})}}catch(e){}}updateMaxDisplayCountAfterSwitchToMonthView(e){"month"===e&&this.updateMaxDisplayCountWithDebounce()}}We.monthDateTitleHeight=26,Fe([l()],We.prototype,"host",void 0),Fe([l()],We.prototype,"monthEventRenderer",void 0),Fe([l()],We.prototype,"viewMode",void 0),Fe([c("componentDidLoad")],We.prototype,"updateMaxDisplayCount",null),Fe([c("watchViewModeChange")],We.prototype,"updateMaxDisplayCountAfterSwitchToMonthView",null);var _e=function(e,t,n,i){var r,o=arguments.length,a=o<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,n,i);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,n,a):r(t,n))||a);return o>3&&a&&Object.defineProperty(t,n,a),a};class He extends d{render(){const t=this.calendarView.dateItems[0],n=t.map((e=>this.calendarEventController.getCurrentDateEvents(e).filter((e=>e.isAllDayEvent||e.isGroupEvent())))),i=this.fullDayEventLayoutRenderer.sortLongEvents(n),r=this.filterDisplayEvents(i);return e("div",{class:"calendar-view-event-all"},t.map(((t,n)=>e("div",{class:"event-all-col border-divider-left",key:t.date},this.renderCurrentFullDayEvents(r[n],n,i[n],t)))))}renderCurrentFullDayEvents(n,i,r,o){const a=n.length*Ae.backgroundColorModeEventHeight-2,s=r.slice(n.length).filter(Boolean).length;return e(t,null,e("div",{class:"placeholder-block",style:{height:a+"px"}},e("span",null,n.length," events")),this.fullDayEventLayoutRenderer.render(n,i,o),s>0&&this.dayViewFullDayEventMoreButtonRenderer.render(s))}filterDisplayEvents(e){if(this.showAllEventsInDayOrWeekView)return e;{const t=[],n=He.maxDisplayEventLength;return e.forEach((e=>{const i=e.length>n?e.slice(0,n):e;t.push(i)})),t}}}He.maxDisplayEventLength=2,_e([l()],He.prototype,"calendarView",void 0),_e([l()],He.prototype,"calendarEventController",void 0),_e([l()],He.prototype,"eventItemRenderer",void 0),_e([l()],He.prototype,"fullDayEventLayoutRenderer",void 0),_e([l()],He.prototype,"showAllEventsInDayOrWeekView",void 0),_e([l()],He.prototype,"dayViewFullDayEventMoreButtonRenderer",void 0);var Ue=function(e,t,n,i){var r,o=arguments.length,a=o<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,n,i);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,n,a):r(t,n))||a);return o>3&&a&&Object.defineProperty(t,n,a),a};class Ye extends d{render(t,n){const i=[];return t.eventLayoutCells.forEach(((r,o)=>{let a=r.getEventBySlotIndex(0),s=0;for(let l=0;l<Ye.totalNumberOfCells;l++){const d=r.getEventBySlotIndex(l);d!==a&&(a&&i.push(e("div",{key:o,class:"time-event-block",style:this.getTimeEventStyle(s,l,o,t.getEventColumnsSpannedCount(a))},this.eventPreviewPopoverRenderer.render(a,n,{"day-event":!0,"bg-shadow":o>0}))),a=d,s=l)}})),i}getTimeEventStyle(e,t,n,i){const r=n*(1/i);return{position:"absolute",left:100*r+"%",top:100/Ye.totalNumberOfCells*e+"%",width:`calc(100% - ${100*r}%)`,height:100/Ye.totalNumberOfCells*(t-e)+"%",zIndex:n>0?`${n}`:void 0}}}Ye.totalNumberOfCells=96,Ue([l()],Ye.prototype,"eventItemRenderer",void 0),Ue([l()],Ye.prototype,"eventPreviewPopoverRenderer",void 0);class qe{addCurrentEventToLayout(e,t){let n=e.find((e=>!e.hasOverlapEvent(t)));n?n.updateSlots(t):(n=this.createNewLayoutCell(),n.updateSlots(t),e.push(n))}}class Ke{get eventLayoutCells(){return this.cells}}class Xe extends Ke{constructor(e){super(),this.cells=e}getEventColumnsSpannedCount(e){const t=this.cells.findIndex((t=>t.getEventStartIndex(e)>=0));let n=t+1;return t<this.cells.length-1&&this.cells.slice(t+1).forEach((t=>{t.hasOverlapEvent(e)&&n++})),n}}class Ze{getEventBySlotIndex(e){return this.slots[e]}getEventStartIndex(e){return this.slots.findIndex((t=>t===e))}getEventEndIndex(e){const t=this.getEventStartIndex(e);let n=t;if(t>=0)for(let i=t+1;i<this.slots.length;i++){if(this.slots[i]!==e){n=i-1;break}i===this.slots.length-1&&(n=i)}return n}}class Ge extends Ze{constructor(){super(...arguments),this.slots=Ge.defaultSlots}hasOverlapEvent(e){const[t,n]=this.getIndexRangeFromEvent(e);let i=!1;for(let e=t;e<n;e++)if(this.slots[e]){i=!0;break}return i}updateSlots(e){const[t,n]=this.getIndexRangeFromEvent(e);n>t&&(this.slots=this.slots.slice(0,t).concat(Array(n-t).fill(e),this.slots.slice(n)))}getIndexRangeFromEvent(e){const{startTime:t,endTime:n}=e;return[we(t),we(n)]}}Ge.defaultSlots=Array(96).fill(null);class Je extends qe{generate(e){const t=[new Ge];return e.forEach((e=>{this.addCurrentEventToLayout(t,e)})),new Xe(t)}createNewLayoutCell(){return new Ge}}class Qe{sort(e,t,n){const i=[],r=[],o=[];for(let t=0;t<e.length;t++){const n=e[t];n&&(n.isGroupEvent()?r.push(n):n.isAllDayEvent?i.push(n):o.push(n))}let a=i.concat(this.sortCalendarEventByTime(o)),s=n.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 n=we(e.startTime),i=we(t.startTime);return n===i?we(t.endTime)-we(e.endTime):n-i}))}insertEventsToEmptyPosition(e,t){return e.map((e=>{if(t.length&&!e){const e=t[0];return t=t.slice(1),e}return e}))}}var et=function(e,t,n,i){var r,o=arguments.length,a=o<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,n,i);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,n,a):r(t,n))||a);return o>3&&a&&Object.defineProperty(t,n,a),a};class tt extends d{constructor(){super(...arguments),this.calendarEventSorter=new Qe,this.dayViewTimedEventLayoutGenerator=new Je}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())),n=this.calendarEventSorter.sortCalendarEventByTime(t),i=this.dayViewTimedEventLayoutGenerator.generate(n);return this.dayViewEventLayoutRenderer.render(i,e)}}et([l()],tt.prototype,"calendarView",void 0),et([l()],tt.prototype,"calendarEventController",void 0),et([l()],tt.prototype,"dayViewEventLayoutRenderer",void 0);class nt extends Ke{constructor(e){super(),this.cells=e}getEventRowsIndex(e){return this.cells.findIndex((t=>t.getEventStartIndex(e)>=0))}getEventsByIndex(e){const t=[];let n=0;return this.cells.forEach(((i,r)=>{const o=i.getEventBySlotIndex(e);t.push(o),o&&(n=r)})),t.slice(0,n+1)}}class it extends Ze{constructor(){super(...arguments),this.slots=it.defaultSlots}updateSlots(e){const{start:t,end:n}=e;this.slots=this.slots.slice(0,t).concat(Array(n-t+1).fill(e.event),this.slots.slice(n+1))}hasOverlapEvent(e){const{start:t,end:n}=e;let i=!1;for(let e=t;e<n+1;e++)if(this.slots[e]){i=!0;break}return i}}it.defaultSlots=Array(7).fill(null);class rt extends qe{generate(e){const t=this.collectAllShouldOrderLongEvents(e),n=[this.createNewLayoutCell()];return t.forEach((e=>{this.addCurrentEventToLayout(n,e)})),new nt(n)}createNewLayoutCell(){return new it}collectAllShouldOrderLongEvents(e){const t={};e.forEach(((e,n)=>{e.filter((e=>e&&e.isGroupEvent())).forEach((e=>{t[e.eventKey]=t[e.eventKey]?Object.assign(Object.assign({},t[e.eventKey]),{end:n,start:n-t[e.eventKey].end!=1?n:t[e.eventKey].start}):{start:n,end:n,event:e}}))}));const n=Object.values(t);return this.sortLongEventViews(n)}sortLongEventViews(e){return e.sort(((e,t)=>{const{startDate:n,endDate:i}=e.event,{startDate:r,endDate:o}=t.event;n.setHours(0,0,0),r.setHours(0,0,0),i.setHours(23,59,59),o.setHours(23,59,59);const a=o.valueOf()-r.valueOf()-(i.valueOf()-n.valueOf());return n.valueOf()!==r.valueOf()?n.valueOf()-r.valueOf():a}))}}var ot=function(e,t,n,i){var r,o=arguments.length,a=o<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,n,i);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,n,a):r(t,n))||a);return o>3&&a&&Object.defineProperty(t,n,a),a};class at extends d{constructor(){super(...arguments),this.longEventLayoutGenerator=new rt,this.calendarEventSorter=new Qe}sortLongEvents(e){return this.fullDayEventLayout=this.longEventLayoutGenerator.generate(e),e.map(((e,t)=>this.calendarEventSorter.sort(e,t,this.fullDayEventLayout)))}render(t,n,i){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,n,r,"month"===this.viewMode?at.monthViewEventOffsetTop:0)},this.eventPreviewPopoverRenderer.render(t,i,{"month-event":"month"===this.viewMode,"day-event":"month"!==this.viewMode}))}))}getEventStyle(e,t,n,i){const r=this.calendarView.weekdays.length,o=t;let a=t+1;const s=n;let l=!0;const d=this.fullDayEventLayout.getEventRowsIndex(e);if(d>=0){const n=this.fullDayEventLayout.eventLayoutCells[d].getEventStartIndex(e),i=this.fullDayEventLayout.eventLayoutCells[d].getEventEndIndex(e);n===t?a=i+1:l=!1}return{position:"absolute",left:100/r*o+"%",top:`${s*Ae.backgroundColorModeEventHeight+i}px`,width:100/r*(a-o)+"%",opacity:l?"1":"0"}}}at.monthViewEventOffsetTop=26,ot([l()],at.prototype,"eventItemRenderer",void 0),ot([l()],at.prototype,"viewMode",void 0),ot([l()],at.prototype,"calendarView",void 0),ot([l()],at.prototype,"eventPreviewPopoverRenderer",void 0);var st=function(e,t,n,i){var r,o=arguments.length,a=o<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,n,i);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,n,a):r(t,n))||a);return o>3&&a&&Object.defineProperty(t,n,a),a};class lt extends d{constructor(){super(...arguments),this.updateShowAllFlag=e=>{e.stopPropagation(),this.showAllEventsInDayOrWeekView=!0}}render(t){if(!this.showAllEventsInDayOrWeekView)return e("div",{tabIndex:0,role:"button",class:"more-button",onKeyDown:$(),onClick:this.updateShowAllFlag},`${t} More`)}resetShowAllFlag(){this.showAllEventsInDayOrWeekView=!1}}st([l({writable:!0})],lt.prototype,"showAllEventsInDayOrWeekView",void 0),st([c("watchViewModeChange")],lt.prototype,"resetShowAllFlag",null);var dt=function(e,t,n,i){var r,o=arguments.length,a=o<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,n,i);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,n,a):r(t,n))||a);return o>3&&a&&Object.defineProperty(t,n,a),a};class ct extends d{render(t){const n=t.findIndex((e=>e.isToday()))>=0;return e("div",{class:{"time-marker-container":!0,hidden:!n}},e("div",{class:"time-marker",style:{top:this.getTimeMarkerPosition()},ref:e=>this.timeMarkerRef=e},t.map((t=>e("div",{key:t.date,class:{active:t.isToday()}})))))}updateTimeLine(e){this.scrollToTargetTimeBlock(e),this.syncTimeMarkerPosition(e)}clearTimer(){clearInterval(this.timeMarkerPositionTimer)}updateTimeLineIfComponentAddBack(){this.syncTimeMarkerPosition(this.viewMode)}displayCurrentTimeBlockByDefault(){this.scrollToTargetTimeBlock(this.viewMode)}getTimeMarkerPosition(){const e=new Date;return(60*e.getHours()+e.getMinutes())/1440*100+"%"}syncTimeMarkerPosition(e){clearInterval(this.timeMarkerPositionTimer),"month"!==e&&(this.timeMarkerPositionTimer=setInterval((()=>{this.timeMarkerRef&&(this.timeMarkerRef.style.top=this.getTimeMarkerPosition())}),6e4))}scrollToTargetTimeBlock(e){"month"!==e&&setTimeout((()=>{const e=this.viewRenderer.getCalendarViewElementRef(),t=Math.max(0,this.getViewCenterPosition());e&&t&&e.scrollTo({top:t})}),16)}getViewCenterPosition(){const e=this.viewRenderer.getCalendarViewElementRef();if(e){const t=e.querySelector(".calendar-view-title-container").offsetHeight,n=Math.max(e.offsetHeight-t,0)/2,i=e.scrollHeight,r=16,o=Number(this.getTimeMarkerPosition().replace("%",""))/100*Math.max(i-r-t,0);if(!isNaN(n)&&o&&o>n)return o-n+r}return 0}}dt([l()],ct.prototype,"viewMode",void 0),dt([l()],ct.prototype,"viewRenderer",void 0),dt([c("watchViewModeChange")],ct.prototype,"updateTimeLine",null),dt([c("disconnectedCallback")],ct.prototype,"clearTimer",null),dt([c("connectedCallback")],ct.prototype,"updateTimeLineIfComponentAddBack",null),dt([c("componentDidLoad")],ct.prototype,"displayCurrentTimeBlockByDefault",null);var ht=function(e,t,n,i){var r,o=arguments.length,a=o<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,n,i);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,n,a):r(t,n))||a);return o>3&&a&&Object.defineProperty(t,n,a),a};class vt extends d{setPostOperationDate(e){this.postOperationDate=e}setDate(e,t){if(e.current!==this.postOperationDate)if(this.shouldSetCurrentDateToFirstDayOfMonth(e,t)){const t=e.current.toDate();t&&(t.setDate(1),this.setPostOperationDate(ce.from(t)))}else this.setPostOperationDate(ce.from(e.current.toDate()))}shouldSetCurrentDateToFirstDayOfMonth(e,t){return"month"===e.type&&"month"===(null==t?void 0:t.type)&&!e.current.equal(ce.from(new Date))}}ht([l({writable:!0})],vt.prototype,"postOperationDate",void 0),ht([c("watchCurrentPeriodChange")],vt.prototype,"setDate",null);var pt=function(e,t,n,i){var r,o=arguments.length,a=o<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,n,i);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,n,a):r(t,n))||a);return o>3&&a&&Object.defineProperty(t,n,a),a};class ft extends d{constructor(){super(...arguments),this.popoverHideObserver=null}render(e,t,n){return this.enabledEventPreview?this.renderPreviewPopover(e,n,t):this.eventItemRenderer.render(e,n,t)}renderPreviewPopover(t,n,i){return e("vega-popover",{placement:"day"===this.viewMode?"top":"right",alignment:"center",class:{"event-preview-popover":!0,block:!0},padding:"0",size:ft.SINGLE_EVENT_PREVIEW_WIDTH,ref:e=>{this.setPopoverHideObserver(e,t)}},e("div",{slot:"popover-content",class:"event-preview-popover-content"},this.eventItemRenderer.render(t,n,i)),e("div",{slot:"popover"},e("div",{class:"preview-container",ref:e=>{e?this.eventPreviewPopoverController.setEventPreviewContainerMap(t,i,e):this.eventPreviewPopoverController.deleteEventPreviewContainer(t,i)}})))}setPopoverHideObserver(e,t){e?(this.popoverHideObserver=new T((e=>t===e),(async()=>await e.hide())),V.register(L,this.popoverHideObserver)):this.popoverHideObserver&&V.unregister(L,this.popoverHideObserver)}}ft.SINGLE_EVENT_PREVIEW_WIDTH=400,pt([l()],ft.prototype,"host",void 0),pt([l()],ft.prototype,"renderer",void 0),pt([l()],ft.prototype,"viewMode",void 0),pt([l()],ft.prototype,"timeFormat",void 0),pt([l()],ft.prototype,"eventItemRenderer",void 0),pt([l()],ft.prototype,"enabledEventPreview",void 0),pt([l()],ft.prototype,"eventPreviewPopoverController",void 0);class wt extends d{constructor(){super(...arguments),this.singleEventPreviewContainerMap=new Map,this.groupEventsPreviewContainerMap=new Map}setEventPreviewContainerMap(e,t,n){(Array.isArray(e)?this.groupEventsPreviewContainerMap:this.singleEventPreviewContainerMap).set(this.generateMapKey(e,t),n)}deleteEventPreviewContainer(e,t){(Array.isArray(e)?this.groupEventsPreviewContainerMap:this.singleEventPreviewContainerMap).delete(this.generateMapKey(e,t))}getEventPreviewContainer(e,t,n){const i=n?this.groupEventsPreviewContainerMap:this.singleEventPreviewContainerMap,r=this.generateMapKey(e,t);if(i.has(r))return i.get(r);{const n=this.getDateString(t),r=Array.from(i.keys()).find((t=>t.includes(e.eventKey)&&t.endsWith(n)));if(r)return i.get(r)}}generateMapKey(e,t){const n=this.getDateString(t);return Array.isArray(e)?e.filter((e=>e)).map((e=>e.eventKey)).join("-")+n:e.eventKey+n}getDateString(e){return`-${e.year}-${e.month}-${e.date}`}}var ut=function(e,t,n,i){var r,o=arguments.length,a=o<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,n,i);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,n,a):r(t,n))||a);return o>3&&a&&Object.defineProperty(t,n,a),a};const mt=class{constructor(e){i(this,e),this.vegaChange=r(this,"vegaChange",7),this.change=r(this,"change",7),this.vegaEventClick=r(this,"vegaEventClick",7),this.eventClick=r(this,"eventClick",7),this.vegaDateDblClick=r(this,"vegaDateDblClick",7),this.dateDblClick=r(this,"dateDblClick",7),this.vegaMoreActionClick=r(this,"vegaMoreActionClick",7),this.moreActionClick=r(this,"moreActionClick",7),this.globalSlimmer={},this.translationSlimmer=new _,this.vegaComponentUsageRuntimeMetricsSlimmer=new p,this.renderer=new K,this.switchPanelRenderer=new Z,this.viewRenderer=new J,this.monthViewRenderer=new ee,this.viewWithTimeRenderer=new ne,this.timeLineRenderer=new ie,this.timeMarkerRenderer=new ct,this.monthEventRenderer=new Ee,this.currentPeriodController=new je,this.calendarViewController=new Ce,this.postOperationDateController=new vt,this.dayViewFullDayEventRenderer=new He,this.eventPreviewPopoverController=new wt,this.dayViewFullDayEventMoreButtonRenderer=new lt,this.dayViewTimedEventRenderer=new tt,this.eventItemRenderer=new Ae,this.dayViewEventLayoutRenderer=new Ye,this.fullDayEventLayoutRenderer=new at,this.eventPreviewPopoverRenderer=new ft,this.calendarEventController=new Be,this.eventResponsiveController=new We,this.changeEventEmitter=D(mt,m),this.eventClickEmitter=D(mt,y),this.dateDblClickEmitter=D(mt,k),this.moreActionClickEmitter=D(mt,C),this.changeEventPrevent=new O([m],(()=>this.switchPanelRenderer.getSwitchPanelRef())),this.timeFormatNotifySlimmer=W(mt,"timeFormat","watchTimeFormat"),this.showEventColorBarNotifySlimmer=W(mt,"showEventColorBar","watchShowEventColorBar"),this.postOperationDate=ce.from(new Date),this.showAllEventsInDayOrWeekView=!1,this.calendarEvents=[],this.viewMode="month",this.timeFormat="24-hour",this.isDateDisabled=()=>!1,this.showEventColorBar=!0,this.showSwitchView=!0,this.showWeekends=!0,this.enabledEventPreview=!0}watchCurrentPeriodChange(e,t){}watchViewModeChange(e){}watchEventsChange(e){}watchTimeFormat(e){}watchShowEventColorBar(e){}watchShowWeekendsChange(){}render(){return s(e(o,null,this.renderer.render()),this.host)}get host(){return a(this)}static get watchers(){return{currentPeriod:["watchCurrentPeriodChange"],viewMode:["watchViewModeChange"],events:["watchEventsChange"],timeFormat:["watchTimeFormat"],showEventColorBar:["watchShowEventColorBar"],showWeekends:["watchShowWeekendsChange"]}}};ut([f()],mt.prototype,"globalSlimmer",void 0),ut([v()],mt.prototype,"translationSlimmer",void 0),ut([v()],mt.prototype,"vegaComponentUsageRuntimeMetricsSlimmer",void 0),ut([v()],mt.prototype,"renderer",void 0),ut([v()],mt.prototype,"switchPanelRenderer",void 0),ut([v()],mt.prototype,"viewRenderer",void 0),ut([v()],mt.prototype,"monthViewRenderer",void 0),ut([v()],mt.prototype,"viewWithTimeRenderer",void 0),ut([v()],mt.prototype,"timeLineRenderer",void 0),ut([v()],mt.prototype,"timeMarkerRenderer",void 0),ut([v()],mt.prototype,"monthEventRenderer",void 0),ut([v()],mt.prototype,"currentPeriodController",void 0),ut([v()],mt.prototype,"calendarViewController",void 0),ut([v()],mt.prototype,"postOperationDateController",void 0),ut([v()],mt.prototype,"dayViewFullDayEventRenderer",void 0),ut([v()],mt.prototype,"eventPreviewPopoverController",void 0),ut([v()],mt.prototype,"dayViewFullDayEventMoreButtonRenderer",void 0),ut([v()],mt.prototype,"dayViewTimedEventRenderer",void 0),ut([v()],mt.prototype,"eventItemRenderer",void 0),ut([v()],mt.prototype,"dayViewEventLayoutRenderer",void 0),ut([v()],mt.prototype,"fullDayEventLayoutRenderer",void 0),ut([v()],mt.prototype,"eventPreviewPopoverRenderer",void 0),ut([v()],mt.prototype,"calendarEventController",void 0),ut([v()],mt.prototype,"eventResponsiveController",void 0),ut([v()],mt.prototype,"changeEventEmitter",void 0),ut([v()],mt.prototype,"eventClickEmitter",void 0),ut([v()],mt.prototype,"dateDblClickEmitter",void 0),ut([v()],mt.prototype,"moreActionClickEmitter",void 0),ut([v()],mt.prototype,"changeEventPrevent",void 0),ut([v()],mt.prototype,"timeFormatNotifySlimmer",void 0),ut([v()],mt.prototype,"showEventColorBarNotifySlimmer",void 0),mt.style='.border-divider-top{border:1px solid rgba(var(--v-border-divider-secondary, 199, 217, 229, 1));border-left-width:0px;border-right-width:0px;border-bottom-width:0px}.border-divider-top.disabled{background-color:rgba(var(--v-bg-secondary, 245, 247, 247, 1))}.border-divider-left{border:1px solid rgba(var(--v-border-divider-secondary, 199, 217, 229, 1));border-top-width:0px;border-right-width:0px;border-bottom-width:0px}.border-divider-left.disabled{background-color:rgba(var(--v-bg-secondary, 245, 247, 247, 1))}.border-divider-right{border:1px solid rgba(var(--v-border-divider-secondary, 199, 217, 229, 1));border-top-width:0px;border-left-width:0px;border-bottom-width:0px}.border-divider-bottom{border:1px solid rgba(var(--v-border-divider-secondary, 199, 217, 229, 1));border-top-width:0px;border-left-width:0px;border-right-width:0px}:host{display:flex;flex-direction:column;border-radius:12px;border:1px solid rgba(var(--v-border-divider, 171, 198, 216, 1));background-color:rgba(var(--v-bg-primary, 252, 252, 252, 1));overflow:hidden;width:100%;height:100%;box-sizing:border-box;max-height:1966px}.calendar-switch-panel{padding:24px;border-bottom-width:1px;border-top-width:0px;border-left-width:0px;border-right-width:0px;border-style:solid;border-color:rgba(var(--v-border-color-divider, 171, 198, 216, 1));flex-shrink:0;width:100%;box-sizing:border-box}.calendar-switch-panel .calendar-date-switch-container{display:flex;gap:8px;align-items:center;flex-direction:row}.calendar-switch-panel .calendar-view-switch-container{display:flex;gap:16px;align-items:center;flex-direction:row}.calendar-switch-panel .calendar-current-date{padding-left:8px}.calendar-view{width:100%;position:relative;flex-grow:1;overflow-y:auto;overflow-x:hidden;--calendar-weekday-columns:7}.calendar-view.calendar-hide-weekends{--calendar-weekday-columns:5}.calendar-view-month .calendar-view-month-container{width:100%;display:grid;min-height:100%;grid-template-rows:43px repeat(6, minmax(64px, 1fr))}.calendar-view-month .calendar-view-title{background-color:rgba(var(--v-bg-primary, 252, 252, 252, 1));top:0;left:0;z-index:62}.calendar-view-month .calendar-view-title div{padding-top:12px;padding-bottom:12px;color:rgba(var(--v-text-secondary, 107, 116, 125, 1));font-family:"Inter", sans-serif;font-size:14px;font-weight:700;line-height:18px;text-align:center}@media screen and (min-width: 768px) and (max-width: 1023px){.calendar-view-month .calendar-view-title div{font-family:"Inter", sans-serif;font-size:14px;font-weight:700;line-height:18px}}@media screen and (min-width: 1024px) and (max-width: 1439px){.calendar-view-month .calendar-view-title div{font-family:"Inter", sans-serif;font-size:14px;font-weight:700;line-height:18px}}@media screen and (min-width: 1440px) and (max-width: 9999px){.calendar-view-month .calendar-view-title div{font-family:"Inter", sans-serif;font-size:14px;font-weight:700;line-height:18px}}.calendar-view-month .calendar-view-row{position:relative;display:grid;grid-template-rows:1fr;grid-template-columns:repeat(var(--calendar-weekday-columns), minmax(64px, 1fr))}.calendar-view-month .calendar-view-row.calendar-view-title{position:sticky}.calendar-view-month .calendar-view-row:last-child{border-bottom-width:0px}.calendar-view-month .calendar-view-row .row-cell{overflow:hidden;display:flex;flex-direction:column;justify-content:space-between}.calendar-view-month .calendar-view-row .row-cell:last-child{border-right-width:0px}.calendar-view-month .calendar-view-row .row-cell .date{padding-top:4px;padding-bottom:4px;padding-right:12px;padding-left:8px}.calendar-view-month .calendar-view-row .row-cell .date>div{display:inline-block;color:rgba(var(--v-text-secondary, 107, 116, 125, 1));font-family:"Inter", sans-serif;font-size:14px;font-weight:400;line-height:18px}@media screen and (min-width: 768px) and (max-width: 1023px){.calendar-view-month .calendar-view-row .row-cell .date>div{font-family:"Inter", sans-serif;font-size:14px;font-weight:400;line-height:18px}}@media screen and (min-width: 1024px) and (max-width: 1439px){.calendar-view-month .calendar-view-row .row-cell .date>div{font-family:"Inter", sans-serif;font-size:14px;font-weight:400;line-height:18px}}@media screen and (min-width: 1440px) and (max-width: 9999px){.calendar-view-month .calendar-view-row .row-cell .date>div{font-family:"Inter", sans-serif;font-size:14px;font-weight:400;line-height:18px}}.calendar-view-month .calendar-view-row .row-cell .date .month-block{margin-right:2px}.calendar-view-month .calendar-view-row .row-cell .date .grid-col{text-align:center;border-top-left-radius:9999px;border-bottom-left-radius:9999px;border-top-right-radius:9999px;border-bottom-right-radius:9999px;cursor:pointer;width:18px;height:18px;line-height:18px}.calendar-view-month .calendar-view-row .row-cell .date .grid-col:hover{background-color:rgba(var(--v-bg-action-secondary-hover, 4, 112, 236, 0.1))}.calendar-view-month .calendar-view-row .row-cell .date .grid-col:active{background-color:rgba(var(--v-bg-action-secondary-active, 29, 65, 195, 0.1))}.calendar-view-month .calendar-view-row .row-cell .date .grid-col:focus-visible{outline:2px solid rgba(var(--v-border-color-action, 19, 98, 226, 1));outline-offset:2px}.calendar-view-month .calendar-view-row .row-cell.current-month-day .date>div{color:rgba(var(--v-text-primary, 32, 54, 69, 1))}.calendar-view-month .calendar-view-row .row-cell.disabled{background-color:rgba(var(--v-bg-secondary, 245, 247, 247, 1))}.calendar-view-month .calendar-view-row .row-cell.disabled .date>div{color:rgba(var(--v-text-disabled, 176, 180, 181, 1))}.calendar-view-month .calendar-view-row .row-cell.active .date .grid-col{background-color:rgba(var(--v-bg-action, 19, 98, 226, 1));border-top-left-radius:9999px;border-bottom-left-radius:9999px;color:rgba(var(--v-text-on-action, 252, 252, 252, 1))}.calendar-view-month .calendar-view-row .row-cell.active .date .grid-col:hover{background-color:rgba(var(--v-bg-action-hover, 4, 112, 236, 1))}.calendar-view-month .calendar-view-row .row-cell.active .date .grid-col:active{background-color:rgba(var(--v-bg-action-active, 29, 65, 195, 1))}.calendar-view-month .calendar-view-row .row-cell.active .date .grid-col:focus-visible{outline:2px solid rgba(var(--v-border-color-action, 19, 98, 226, 1));outline-offset:2px}.calendar-view-container{width:100%}.calendar-view-container .calendar-view-title-container{background-color:rgba(var(--v-bg-primary, 252, 252, 252, 1));position:sticky;top:0;left:0;z-index:62}.calendar-view-container .calendar-view-row{box-sizing:border-box;width:100%;display:flex;flex-direction:row}.calendar-view-container .calendar-view-row .time-line,.calendar-view-container .calendar-view-row .time-line-empty,.calendar-view-container .calendar-view-row .time-line-all{width:72px;text-align:right;padding-right:8px;box-sizing:border-box;font-family:"Inter", sans-serif;font-size:14px;font-weight:400;line-height:18px;color:rgba(var(--v-text-primary, 32, 54, 69, 1));flex-shrink:0}@media screen and (min-width: 768px) and (max-width: 1023px){.calendar-view-container .calendar-view-row .time-line,.calendar-view-container .calendar-view-row .time-line-empty,.calendar-view-container .calendar-view-row .time-line-all{font-family:"Inter", sans-serif;font-size:14px;font-weight:400;line-height:18px}}@media screen and (min-width: 1024px) and (max-width: 1439px){.calendar-view-container .calendar-view-row .time-line,.calendar-view-container .calendar-view-row .time-line-empty,.calendar-view-container .calendar-view-row .time-line-all{font-family:"Inter", sans-serif;font-size:14px;font-weight:400;line-height:18px}}@media screen and (min-width: 1440px) and (max-width: 9999px){.calendar-view-container .calendar-view-row .time-line,.calendar-view-container .calendar-view-row .time-line-empty,.calendar-view-container .calendar-view-row .time-line-all{font-family:"Inter", sans-serif;font-size:14px;font-weight:400;line-height:18px}}.calendar-view-container .calendar-view-title{width:100%}.calendar-view-container .calendar-view-title>div{padding:12px;padding-bottom:8px;color:rgba(var(--v-text-secondary, 107, 116, 125, 1));font-family:"Inter", sans-serif;font-size:14px;font-weight:700;line-height:18px;text-align:center;display:flex;flex-direction:column;gap:8px}@media screen and (min-width: 768px) and (max-width: 1023px){.calendar-view-container .calendar-view-title>div{font-family:"Inter", sans-serif;font-size:14px;font-weight:700;line-height:18px}}@media screen and (min-width: 1024px) and (max-width: 1439px){.calendar-view-container .calendar-view-title>div{font-family:"Inter", sans-serif;font-size:14px;font-weight:700;line-height:18px}}@media screen and (min-width: 1440px) and (max-width: 9999px){.calendar-view-container .calendar-view-title>div{font-family:"Inter", sans-serif;font-size:14px;font-weight:700;line-height:18px}}.calendar-view-container .calendar-view-title .week-day{color:rgba(var(--v-text-primary, 32, 54, 69, 1));font-family:"Inter", sans-serif;font-size:20px;font-weight:500;line-height:24px;letter-spacing:0px}@media screen and (min-width: 768px) and (max-width: 1023px){.calendar-view-container .calendar-view-title .week-day{font-family:"Inter", sans-serif;font-size:20px;font-weight:500;line-height:24px;letter-spacing:0px}}@media screen and (min-width: 1024px) and (max-width: 1439px){.calendar-view-container .calendar-view-title .week-day{font-family:"Inter", sans-serif;font-size:20px;font-weight:500;line-height:24px;letter-spacing:0px}}@media screen and (min-width: 1440px) and (max-width: 9999px){.calendar-view-container .calendar-view-title .week-day{font-family:"Inter", sans-serif;font-size:20px;font-weight:500;line-height:24px;letter-spacing:0px}}.calendar-view-container .calendar-view-title .active div{color:rgba(var(--v-text-link, 19, 98, 226, 1))}.calendar-view-container .calendar-view-event-all-container{align-items:center}.calendar-view-container .calendar-view-event-all{display:grid;grid-template-rows:1fr;flex-grow:1;min-height:18px}.calendar-view-container .calendar-view-day-container .time-line{display:grid;grid-template-rows:16px repeat(24, minmax(74px, 1fr))}.calendar-view-container .calendar-view-day-container .time-line .time-text{margin-top:-9px}.calendar-view-container .calendar-view-day-container .calendar-view-content{width:100%}.calendar-view-container .calendar-view-day-container .calendar-view-content .grid-col{display:grid;grid-template-rows:16px repeat(24, minmax(74px, 1fr));grid-template-columns:minmax(64px, 1fr)}.calendar-view-container .calendar-view-day-container .calendar-view-content .grid-col>.border-divider-top:first-child{border-top-width:0px}.calendar-view-container .calendar-view-content-container{width:100%;position:relative}.calendar-view-week .calendar-view-container{min-height:100%}.calendar-view-week .calendar-view-container .calendar-view-title{display:grid;grid-template-rows:1fr;grid-template-columns:repeat(var(--calendar-weekday-columns), minmax(64px, 1fr))}.calendar-view-week .calendar-view-container .calendar-view-event-all{grid-template-columns:repeat(var(--calendar-weekday-columns), minmax(64px, 1fr))}.calendar-view-week .calendar-view-container .calendar-view-day-container .calendar-view-content{display:grid;grid-template-columns:repeat(var(--calendar-weekday-columns), minmax(64px, 1fr))}.calendar-view-week .time-marker-container .time-marker{display:grid;grid-template-columns:repeat(var(--calendar-weekday-columns), minmax(64px, 1fr))}.calendar-view-week .day-event-container{display:grid;grid-template-columns:repeat(var(--calendar-weekday-columns), minmax(64px, 1fr))}.calendar-view-day .calendar-view-container{min-height:100%}.time-marker-container{position:absolute;min-width:100%;left:0;top:16px;height:calc(100% - 16px);pointer-events:none}.time-marker-container.hidden{display:none}.time-marker-container .time-marker{position:absolute;height:2px;display:grid;min-width:100%;left:0;top:0;z-index:61}.time-marker-container .time-marker div{width:100%;height:2px;background-color:rgba(var(--v-bg-status-error, 255, 110, 139, 1));opacity:0.3}.time-marker-container .time-marker div.active{opacity:1;position:relative}.time-marker-container .time-marker div.active::before{content:"";display:block;border-top-left-radius:9999px;border-bottom-left-radius:9999px;border-top-right-radius:9999px;border-bottom-right-radius:9999px;position:absolute;width:8px;height:8px;background-color:rgba(var(--v-bg-status-error, 255, 110, 139, 1));top:-3px;left:-4px}.day-event-container{position:absolute;min-width:100%;left:0;top:16px;height:calc(100% - 16px);pointer-events:none}.day-event-container .day-event-col{height:100%;overflow:hidden}.day-event-container vega-calendar-event{pointer-events:auto;height:100%}.calendar-view-month .month-event-row{position:absolute;width:100%;overflow:hidden;height:calc(100% - 26px);left:0;bottom:0}.calendar-view-month .events-container{width:100%;box-sizing:border-box;overflow:hidden;padding:2px;display:flex;flex-direction:column;gap:2px;justify-content:space-between;flex-grow:1}.calendar-view-month .events-container .event-list{display:flex;flex-direction:column;gap:2px;flex-grow:1}.calendar-view-month .events-container .event-list .month-event-block{box-sizing:border-box;padding-left:2px;padding-right:3px}.calendar-view-month .events-container .month-event-more .more-button{display:inline-block;height:16px;font-family:"Inter", sans-serif;font-size:12px;font-weight:700;line-height:16px;letter-spacing:0px;color:rgba(var(--v-text-link, 19, 98, 226, 1));cursor:pointer;border-radius:2px}@media screen and (min-width: 768px) and (max-width: 1023px){.calendar-view-month .events-container .month-event-more .more-button{font-family:"Inter", sans-serif;font-size:12px;font-weight:700;line-height:16px;letter-spacing:0px}}@media screen and (min-width: 1024px) and (max-width: 1439px){.calendar-view-month .events-container .month-event-more .more-button{font-family:"Inter", sans-serif;font-size:12px;font-weight:700;line-height:16px;letter-spacing:0px}}@media screen and (min-width: 1440px) and (max-width: 9999px){.calendar-view-month .events-container .month-event-more .more-button{font-family:"Inter", sans-serif;font-size:12px;font-weight:700;line-height:16px;letter-spacing:0px}}.calendar-view-month .events-container .month-event-more .more-button:focus-visible{outline:2px solid rgba(var(--v-border-color-action, 19, 98, 226, 1));outline-offset:0px}.calendar-view-container .calendar-view-event-all{position:relative}.calendar-view-container .calendar-view-event-all .placeholder-block{padding-top:2px;padding-bottom:2px;box-sizing:content-box}.calendar-view-container .calendar-view-event-all .placeholder-block span{display:none}.calendar-view-container .calendar-view-event-all .day-event-block{padding-top:2px;padding-right:2px;box-sizing:border-box;padding-left:3px}.calendar-view-container .calendar-view-event-all .more-button{display:inline-block;height:16px;font-family:"Inter", sans-serif;font-size:12px;font-weight:700;line-height:16px;letter-spacing:0px;color:rgba(var(--v-text-link, 19, 98, 226, 1));cursor:pointer;border-radius:2px;margin-left:2px;padding:2px}@media screen and (min-width: 768px) and (max-width: 1023px){.calendar-view-container .calendar-view-event-all .more-button{font-family:"Inter", sans-serif;font-size:12px;font-weight:700;line-height:16px;letter-spacing:0px}}@media screen and (min-width: 1024px) and (max-width: 1439px){.calendar-view-container .calendar-view-event-all .more-button{font-family:"Inter", sans-serif;font-size:12px;font-weight:700;line-height:16px;letter-spacing:0px}}@media screen and (min-width: 1440px) and (max-width: 9999px){.calendar-view-container .calendar-view-event-all .more-button{font-family:"Inter", sans-serif;font-size:12px;font-weight:700;line-height:16px;letter-spacing:0px}}.calendar-view-container .calendar-view-event-all .more-button:focus-visible{outline:2px solid rgba(var(--v-border-color-action, 19, 98, 226, 1));outline-offset:0px}.calendar-view-container .calendar-view-event-all .event-all-col{display:flex;flex-direction:column;justify-content:space-between;align-items:flex-start}.calendar-view-container .day-event-col{position:relative}.calendar-view-container .day-event-col .time-event-block{box-sizing:border-box;padding-right:8px;padding-bottom:2px;padding-top:3px}.calendar-view-container .day-event-col .time-event-block vega-calendar-event.bg-shadow::part(event-container):not(:focus){outline:2px solid rgba(var(--v-bg-primary, 252, 252, 252, 1))}.calendar-view-container .day-event-col .time-event-block:focus-within{z-index:60 !important}.calendar-event-slot-container{display:none}.event-preview-popover{height:100%}.event-preview-popover.block{display:block}.event-preview-popover .event-preview-popover-content{height:100%}';var gt=function(e,t,n,i){var r,o=arguments.length,a=o<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,n,i);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,n,a):r(t,n))||a);return o>3&&a&&Object.defineProperty(t,n,a),a};class bt extends d{getEventTitleContainerRef(){return this.eventTitleContainerRef}getSlotContainerRef(){return this.slotContainerRef}render(){return e(t,null,this.injectBackgroundColorStyle(),this.calendarEventRender())}calendarEventRender(){return this.calendarEvent.isAllDayEvent||this.calendarEvent.isGroupEvent()?this.renderBackgroundModeEvent():this.renderNormalEvent()}renderBackgroundModeEvent(){const t=this.calendarEvent.disabled;return e("div",{role:"button",tabIndex:0,class:{"slot-container":this.slotMode,"background-color-mode":!0,"event-bg-color":!t,"bg-disabled":t},ref:e=>this.slotContainerRef=e},this.slotMode?this.getSlotElement():this.calendarEvent.title)}renderNormalEvent(){const{variant:t,disabled:n}=this.calendarEvent,i=t||"primary",r=!this.host.classList.contains("day-event"),o={"slot-container":this.slotMode,"event-container":!0,disabled:n,[i]:!0};if(r)return e("div",{role:"button",tabIndex:0,class:o,ref:e=>this.slotContainerRef=e},!this.slotMode&&this.renderEventStatus(),this.slotMode?this.getSlotElement():this.defaultNormalMonthEventContentRender());{const t=this.calendarEvent.getEventDuration();return e("div",{part:"event-container",class:Object.assign(Object.assign({},o),{vertical:t>30,"duration-half-an-hour":30===t,"event-bg-color":!n,"bg-disabled":n}),role:"button",tabIndex:0,ref:e=>this.slotContainerRef=e},!this.slotMode&&this.renderEventStatus(),e("div",{class:"cover-block"}),this.slotMode?this.getSlotElement():this.defaultNormalTimedEventContentRender(t))}}renderEventStatus(){if(this.showColorBar){const t=this.calendarEvent.disabled;return e("div",{class:{"event-status":!0,"event-bg-color":!t,"bg-disabled":t}},e("span",{class:{stripe:"secondary"===this.calendarEvent.variant}}))}}defaultNormalMonthEventContentRender(){const{startTime:t,title:n}=this.calendarEvent;return e("div",{class:"event-title"},`${ae(this.timeFormat,t)} ${n}`)}defaultNormalTimedEventContentRender(t){const{startTime:n,endTime:i,title:r}=this.calendarEvent;return e("div",{class:"event-content"},e("div",{class:{"event-title":!0,"title-word-wrap":t>30},ref:e=>this.eventTitleContainerRef=e},r),e("div",{class:"event-time"},e("vega-icon",{size:"size-12",icon:R.getIconKey("clock-three")}),e("span",null,`${ae(this.timeFormat,n)} - ${ae(this.timeFormat,i)}`)))}getSlotElement(){if(!this.calendarEvent.isRepeatEvent)return e("slot",null)}injectBackgroundColorStyle(){return e("style",null,ge(this.calendarEvent.color))}}R.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>'}}),gt([l()],bt.prototype,"host",void 0),gt([l()],bt.prototype,"timeFormat",void 0),gt([l()],bt.prototype,"calendarEvent",void 0),gt([l()],bt.prototype,"slotMode",void 0),gt([l()],bt.prototype,"showColorBar",void 0);var xt=function(e,t,n,i){var r,o=arguments.length,a=o<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,n,i);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,n,a):r(t,n))||a);return o>3&&a&&Object.defineProperty(t,n,a),a};class yt extends U{constructor(){super({parent:()=>this.host["data-calendar-ref"],subStates:[{subStateName:"timeFormat",parentStateName:"timeFormat"},{subStateName:"showColorBar",parentStateName:"showEventColorBar"}]})}}xt([l({writable:!0})],yt.prototype,"timeFormat",void 0),xt([l({writable:!0})],yt.prototype,"showColorBar",void 0);class kt extends d{setVerticalTitleMaxHeight(){const e=this.renderer.getEventTitleContainerRef();if(e&&e.classList.contains("title-word-wrap")){const t=window.getComputedStyle(e),n=Y(t.height),i=Y(t.lineHeight),r=Math.max(Math.floor(n/i),1);e.style.maxHeight=r*i+"px"}}}!function(e,t,n,i){var r,o=arguments.length,a=o<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,n,i);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,n,a):r(t,n))||a);o>3&&a&&Object.defineProperty(t,n,a)}([l()],kt.prototype,"renderer",void 0);var Ct=function(e,t,n,i){var r,o=arguments.length,a=o<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,n,i);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,n,a):r(t,n))||a);return o>3&&a&&Object.defineProperty(t,n,a),a};class Rt extends d{findTheCalendarEventSlot(){if(this.calendarEvent){const{event:e}=this.calendarEvent,t=this.getParentCalendarElement();if(t){const n=t.querySelector(`vega-calendar-event-slot[event-key='${e.key}']`);n&&(this.slotMode=!0,this.matchSlotElement=n)}}}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")}}Ct([l()],Rt.prototype,"host",void 0),Ct([l()],Rt.prototype,"calendarEvent",void 0),Ct([l({writable:!0})],Rt.prototype,"slotMode",void 0),Ct([l()],Rt.prototype,"renderer",void 0),Ct([c("componentWillLoad")],Rt.prototype,"findTheCalendarEventSlot",null),Ct([c("componentDidLoad")],Rt.prototype,"appendTheRepeatEventSlotToContainer",null);var jt=function(e,t,n,i){var r,o=arguments.length,a=o<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,n,i);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,n,a):r(t,n))||a);return o>3&&a&&Object.defineProperty(t,n,a),a};const Dt=class{constructor(e){i(this,e),this.globalSlimmer={},this.pageResizeObserverSlimmer=new A({target:()=>this.host,callback:()=>this.titleMaxHeightController.setVerticalTitleMaxHeight()}),this.vegaComponentUsageRuntimeMetricsSlimmer=new p,this.renderer=new bt,this.slotController=new Rt,this.subStateController=new yt,this.titleMaxHeightController=new kt,this.timeFormat="24-hour",this.slotMode=!1,this.showColorBar=!0}render(){return H(e("slot",null)),s(e(o,null,this.calendarEvent?this.renderer.render():null),this.host)}get host(){return a(this)}};jt([f()],Dt.prototype,"globalSlimmer",void 0),jt([v()],Dt.prototype,"pageResizeObserverSlimmer",void 0),jt([v()],Dt.prototype,"vegaComponentUsageRuntimeMetricsSlimmer",void 0),jt([v()],Dt.prototype,"renderer",void 0),jt([v()],Dt.prototype,"slotController",void 0),jt([v()],Dt.prototype,"subStateController",void 0),jt([v()],Dt.prototype,"titleMaxHeightController",void 0),Dt.style='.bg-disabled{background-color:rgba(var(--v-bg-disabled, 176, 180, 181, 1))}:host{display:block;box-sizing:border-box;width:100%}:host .background-color-mode{border-radius:2px;color:rgba(var(--v-text-black, 32, 54, 69, 1));font-family:"Inter", sans-serif;font-size:12px;font-weight:700;line-height:16px;letter-spacing:0px;cursor:pointer;overflow:hidden;white-space:nowrap}@media screen and (min-width: 768px) and (max-width: 1023px){:host .background-color-mode{font-family:"Inter", sans-serif;font-size:12px;font-weight:700;line-height:16px;letter-spacing:0px}}@media screen and (min-width: 1024px) and (max-width: 1439px){:host .background-color-mode{font-family:"Inter", sans-serif;font-size:12px;font-weight:700;line-height:16px;letter-spacing:0px}}@media screen and (min-width: 1440px) and (max-width: 9999px){:host .background-color-mode{font-family:"Inter", sans-serif;font-size:12px;font-weight:700;line-height:16px;letter-spacing:0px}}:host .background-color-mode:not(.slot-container){padding-left:8px;padding-right:8px}:host .background-color-mode:focus{outline:2px solid rgba(var(--v-border-color-action, 19, 98, 226, 1));outline-offset:0px}:host .event-container{display:block;width:100%;border-radius:4px;cursor:pointer;box-sizing:border-box;overflow:hidden}:host .background-color-mode.slot-container{height:16px;line-height:16px}:host ::slotted(vega-calendar-event-slot){position:relative;pointer-events:none}:host(.month-event) .event-container{display:flex;flex-direction:row;gap:4px;align-items:center;min-height:16px}:host(.month-event) .event-container:not(.slot-container){padding-left:2px;padding-right:2px}:host(.month-event) .event-container .event-status{width:8px;height:8px;box-sizing:border-box;border-top-left-radius:9999px;border-bottom-left-radius:9999px;border-top-right-radius:9999px;border-bottom-right-radius:9999px;margin-left:2px;flex-shrink:0}:host(.month-event) .event-container .event-status span{display:none;width:100%;height:100%;border-top-left-radius:9999px;border-bottom-left-radius:9999px;border-top-right-radius:9999px;border-bottom-right-radius:9999px}:host(.month-event) .event-container .event-title{font-family:"Inter", sans-serif;font-size:12px;font-weight:400;line-height:16px;color:rgba(var(--v-text-primary, 32, 54, 69, 1));flex-grow:1;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}@media screen and (min-width: 768px) and (max-width: 1023px){:host(.month-event) .event-container .event-title{font-family:"Inter", sans-serif;font-size:12px;font-weight:400;line-height:16px}}@media screen and (min-width: 1024px) and (max-width: 1439px){:host(.month-event) .event-container .event-title{font-family:"Inter", sans-serif;font-size:12px;font-weight:400;line-height:16px}}@media screen and (min-width: 1440px) and (max-width: 9999px){:host(.month-event) .event-container .event-title{font-family:"Inter", sans-serif;font-size:12px;font-weight:400;line-height:16px}}:host(.month-event) .event-container.secondary .event-status span{display:block;background-size:4px 4px;opacity:0.8}:host(.month-event) .event-container.tertiary .event-status{padding:1px}:host(.month-event) .event-container.tertiary .event-status span{display:block;background-color:rgba(var(--v-bg-primary, 252, 252, 252, 1))}:host(.month-event) .event-container.disabled .event-status{background-color:rgba(var(--v-bg-disabled, 176, 180, 181, 1))}:host(.month-event) .event-container:hover{background-color:rgba(var(--v-bg-action-secondary-hover, 4, 112, 236, 0.1))}:host(.month-event) .event-container:active{background-color:rgba(var(--v-bg-action-secondary-active, 29, 65, 195, 0.1))}:host(.month-event) .event-container:focus{outline:2px solid rgba(var(--v-border-color-action, 19, 98, 226, 1));outline-offset:0px}:host(.day-event) .event-container{position:relative}:host(.day-event) .event-container:not(.slot-container){padding-left:8px;padding-right:8px}:host(.day-event) .event-container .event-status{position:absolute;width:4px;height:100%;left:0;top:0;z-index:1}:host(.day-event) .event-container .event-status span{display:none}:host(.day-event) .event-container .cover-block{position:absolute;height:100%;width:100%;background-color:rgba(var(--v-bg-primary, 252, 252, 252, 1));border-radius:4px;left:0;top:0;opacity:0.7}:host(.day-event) .event-container .event-content,:host(.day-event) .event-container .event-time{display:flex;flex-direction:row;align-items:center}:host(.day-event) .event-container .event-content{gap:8px;position:relative;height:100%;box-sizing:border-box}:host(.day-event) .event-container .event-time{gap:4px;color:rgba(var(--v-text-primary, 32, 54, 69, 1));font-family:"Inter", sans-serif;font-size:12px;font-weight:400;line-height:16px}@media screen and (min-width: 768px) and (max-width: 1023px){:host(.day-event) .event-container .event-time{font-family:"Inter", sans-serif;font-size:12px;font-weight:400;line-height:16px}}@media screen and (min-width: 1024px) and (max-width: 1439px){:host(.day-event) .event-container .event-time{font-family:"Inter", sans-serif;font-size:12px;font-weight:400;line-height:16px}}@media screen and (min-width: 1440px) and (max-width: 9999px){:host(.day-event) .event-container .event-time{font-family:"Inter", sans-serif;font-size:12px;font-weight:400;line-height:16px}}:host(.day-event) .event-container .event-time vega-icon{flex-shrink:0}:host(.day-event) .event-container .event-time span{white-space:nowrap}:host(.day-event) .event-container .event-title{color:rgba(var(--v-text-primary, 32, 54, 69, 1));font-family:"Inter", sans-serif;font-size:12px;font-weight:700;line-height:16px;letter-spacing:0px}@media screen and (min-width: 768px) and (max-width: 1023px){:host(.day-event) .event-container .event-title{font-family:"Inter", sans-serif;font-size:12px;font-weight:700;line-height:16px;letter-spacing:0px}}@media screen and (min-width: 1024px) and (max-width: 1439px){:host(.day-event) .event-container .event-title{font-family:"Inter", sans-serif;font-size:12px;font-weight:700;line-height:16px;letter-spacing:0px}}@media screen and (min-width: 1440px) and (max-width: 9999px){:host(.day-event) .event-container .event-title{font-family:"Inter", sans-serif;font-size:12px;font-weight:700;line-height:16px;letter-spacing:0px}}:host(.day-event) .event-container .event-title.title-word-wrap{overflow:hidden}:host(.day-event) .event-container .event-title:not(.title-word-wrap){white-space:nowrap}:host(.day-event) .event-container.duration-half-an-hour{padding-top:8px;padding-bottom:8px}:host(.day-event) .event-container.vertical{height:100%}:host(.day-event) .event-container.vertical .event-content{flex-direction:column;align-items:flex-start;gap:4px;padding-top:8px;padding-bottom:8px}:host(.day-event) .event-container.secondary .event-status span,:host(.day-event) .event-container.tertiary .event-status span{display:block;position:absolute;border-top-left-radius:4px;border-bottom-left-radius:4px}:host(.day-event) .event-container.secondary .cover-block,:host(.day-event) .event-container.tertiary .cover-block{width:calc(100% - 2px);height:calc(100% - 2px);top:1px;left:1px}:host(.day-event) .event-container.secondary .event-status span{width:100%;height:100%;top:0px;left:0px;background-size:4px 4px;opacity:0.8}:host(.day-event) .event-container.secondary .cover-block{opacity:0.9}:host(.day-event) .event-container.tertiary .event-status span{background-color:rgba(var(--v-bg-primary, 252, 252, 252, 1));width:2px;height:calc(100% - 2px);top:1px;left:1px}:host(.day-event) .event-container.tertiary .cover-block{opacity:1}:host(.day-event) .event-container.disabled{background-color:rgba(var(--v-bg-disabled, 176, 180, 181, 1))}:host(.day-event) .event-container.disabled .event-status{background-color:rgba(var(--v-bg-disabled, 176, 180, 181, 1))}:host(.day-event) .event-container:focus{outline:2px solid rgba(var(--v-border-color-action, 19, 98, 226, 1));outline-offset:0px}:host(.day-event) .slot-container{min-height:16px}:host(.month-event.calendar-event-large-size) .background-color-mode{border-radius:4px}:host(.month-event.calendar-event-large-size) .background-color-mode:not(.slot-container){padding-top:4px;padding-bottom:4px}:host(.month-event.calendar-event-large-size) .event-container:not(.slot-container){padding-top:4px;padding-bottom:4px}:host(.month-event.calendar-event-large-size) .slot-container{height:24px;display:flex;align-items:center;line-height:24px}.stripe{background-image:linear-gradient(-45deg, transparent 25%, rgba(var(--v-bg-primary, 252, 252, 252, 1)) 25% 50%, transparent 50% 75%, rgba(var(--v-bg-primary, 252, 252, 252, 1)) 75% 100%)}';var Et=function(e,t,n,i){var r,o=arguments.length,a=o<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,n,i);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,n,a):r(t,n))||a);return o>3&&a&&Object.defineProperty(t,n,a),a};class zt extends d{registerEventPreviewUpdateObserver(){w.addUniqueObserverToNode(this.host,I,(e=>{this.previewPayload=e,this.currentEvent=e.event})),w.addUniqueObserverToNode(this.host,S,(()=>{this.currentEvent=null}))}unregisterEventPreviewUpdateObserver(){w.removeUniqueObserverFromNode(this.host,I),w.removeUniqueObserverFromNode(this.host,S)}}Et([l()],zt.prototype,"host",void 0),Et([l({writable:!0})],zt.prototype,"currentEvent",void 0),Et([l({writable:!0})],zt.prototype,"previewPayload",void 0),Et([c("connectedCallback")],zt.prototype,"registerEventPreviewUpdateObserver",null),Et([c("disconnectedCallback")],zt.prototype,"unregisterEventPreviewUpdateObserver",null);var Mt=function(e,t,n,i){var r,o=arguments.length,a=o<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,n,i);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,n,a):r(t,n))||a);return o>3&&a&&Object.defineProperty(t,n,a),a};class Ot extends d{render(){return this.currentEvent&&e("vega-box",{class:"event-preview"},this.injectBackgroundColorStyle(),this.renderActions(),e("vega-box",{class:"preview-content"},e("vega-flex",{gap:"size-16",direction:"col"},this.renderBasicFields(),this.renderDivider(),e("slot",{name:"event-preview-additional-fields"}))))}renderActions(){return e("vega-flex",{justifyContent:"end",class:"preview-actions"},e("vega-button-circle",{icon:R.getIconKey("close"),color:"text-primary",variant:"icon-only",onVegaClick:()=>{V.notify(L,this.currentEvent)}}))}renderBasicFields(){const n=this.currentEvent;return e(t,null,e("vega-flex",{alignItems:"start",gap:"size-16"},this.renderEventTitle()),e("vega-flex",{alignItems:"start",gap:"size-12"},e("vega-icon",{icon:R.getIconKey("clock"),color:"text-secondary"}),e("vega-flex",{direction:"col",gap:"size-4"},e("vega-font",{variant:"font-footnote1-long",color:"text-primary"},n.generateDateTimeString(this.previewPayload.targetCalendarViewDate,this.previewPayload.timeFormat)),n.isRepeatEvent&&e("vega-font",{variant:"font-footnote1-long",color:"text-primary"},n.generateRepeatString()))))}renderEventTitle(){const n=this.currentEvent,i=ue(n.event.key);return this.host.querySelector(`[slot=${i}]`)?e("slot",{name:i}):e(t,null,e("vega-box",{corners:"rounded-full",class:{"event-bg-color":!0,"event-bg-disabled":n.disabled},flexShrink:0},e("span",{class:{[`event-color-dot-${n.variant}`]:!0}})),e("vega-font",{variant:"font-h5",color:"text-primary"},n.title))}renderDivider(){return this.host.querySelector("[slot=event-preview-additional-fields]")&&e("vega-box",null,e("vega-divider",null))}injectBackgroundColorStyle(){return e("style",null,ge(this.currentEvent.color))}}R.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>'}}),Mt([l()],Ot.prototype,"host",void 0),Mt([l()],Ot.prototype,"previewPayload",void 0),Mt([l()],Ot.prototype,"currentEvent",void 0);var Pt=function(e,t,n,i){var r,o=arguments.length,a=o<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,n,i);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,n,a):r(t,n))||a);return o>3&&a&&Object.defineProperty(t,n,a),a};const St=class{constructor(e){i(this,e),this.detailRenderer=new Ot,this.stateController=new zt,this.translationSlimmer=new _,this.globalSlimmer={},this.vegaComponentUsageRuntimeMetricsSlimmer=new p}render(){return s(e(o,null,this.previewPayload&&this.detailRenderer.render()),this.host)}get host(){return a(this)}};Pt([v()],St.prototype,"detailRenderer",void 0),Pt([v()],St.prototype,"stateController",void 0),Pt([v()],St.prototype,"translationSlimmer",void 0),Pt([f()],St.prototype,"globalSlimmer",void 0),Pt([v()],St.prototype,"vegaComponentUsageRuntimeMetricsSlimmer",void 0),St.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 It=function(e,t,n,i){var r,o=arguments.length,a=o<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,n,i);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,n,a):r(t,n))||a);return o>3&&a&&Object.defineProperty(t,n,a),a};const $t=class{constructor(e){i(this,e),this.globalSlimmer={},this.vegaComponentUsageRuntimeMetricsSlimmer=new p}render(){return s(e(o,{slot:ue(this.eventKey)},e("slot",null)),this.host)}get host(){return a(this)}};It([f()],$t.prototype,"globalSlimmer",void 0),It([v()],$t.prototype,"vegaComponentUsageRuntimeMetricsSlimmer",void 0),$t.style=":host{width:100%;height:100%;position:relative}";export{mt as vega_calendar,Dt as vega_calendar_event,St as vega_calendar_event_preview,$t as vega_calendar_event_slot}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{M as e,V as t}from"./p-6e1ab235.js";import{K as c}from"./p-
|
|
1
|
+
import{M as e,V as t}from"./p-6e1ab235.js";import{K as c}from"./p-2608b9fe.js";var n=function(e,t,c,n){var o,l=arguments.length,a=l<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,c):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,c,n);else for(var s=e.length-1;s>=0;s--)(o=e[s])&&(a=(l<3?o(a):l>3?o(t,c,a):o(t,c))||a);return l>3&&a&&Object.defineProperty(t,c,a),a};class o extends t{constructor(e){super(),this.keyboardEventListeners=[],this.listenersRetriever=e}connectedCallback(){c.register(this.keyboardEventListeners)}disconnectedCallback(){c.deregister(this.keyboardEventListeners)}componentDidLoad(){this.keyboardEventListeners=this.listenersRetriever(this),c.register(this.keyboardEventListeners)}}n([e("connectedCallback")],o.prototype,"connectedCallback",null),n([e("disconnectedCallback")],o.prototype,"disconnectedCallback",null),n([e("componentDidLoad")],o.prototype,"componentDidLoad",null);export{o as K}
|