@spteck/react-controls-v2 2.0.18 → 2.2.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +1 -1
- package/README.md +143 -387
- package/dist/LocalizationProvider-BLjmybBa.cjs +2 -0
- package/dist/LocalizationProvider-BSlUf0tp.js +497 -0
- package/dist/_arrayEach-CnIMt1eB.js +61 -0
- package/dist/_arrayEach-vx8gLv03.cjs +2 -0
- package/dist/abstractions/ILocalizationProvider.d.ts +52 -0
- package/dist/abstractions/index.d.ts +1 -0
- package/dist/abstractions/providers/DefaultLocalizationProvider.d.ts +52 -0
- package/dist/abstractions/providers/LocalizationProvider.d.ts +47 -0
- package/dist/abstractions/providers/index.d.ts +3 -1
- package/dist/ar-C1pLt8fa.js +219 -0
- package/dist/ar-Jzw7PLrc.cjs +2 -0
- package/dist/arc-DPTV8xm_.js +132 -0
- package/dist/arc-fdHOvWdS.cjs +2 -0
- package/dist/architecture-7HQA4BMR-BAUhgjE2.js +6 -0
- package/dist/architecture-7HQA4BMR-DwCjpO72.cjs +2 -0
- package/dist/architectureDiagram-VXUJARFQ-B5yGOjRk.js +8680 -0
- package/dist/architectureDiagram-VXUJARFQ-C7K57uon.cjs +2 -0
- package/dist/az-C0Ow5Hxa.cjs +2 -0
- package/dist/az-C3-F9ybX.js +219 -0
- package/dist/bg-YB0TmpRF.cjs +2 -0
- package/dist/bg-w2e_udiK.js +219 -0
- package/dist/blockDiagram-VD42YOAC-B9MtQVc8.js +3756 -0
- package/dist/blockDiagram-VD42YOAC-CXUX1_9K.cjs +2 -0
- package/dist/bs-BoW04lRb.cjs +2 -0
- package/dist/bs-CEe_gjEx.js +219 -0
- package/dist/c4Diagram-YG6GDRKO-0rSYap-S.cjs +2 -0
- package/dist/c4Diagram-YG6GDRKO-CKFTKCbq.js +2483 -0
- package/dist/ca-Bsy2Y5pS.cjs +2 -0
- package/dist/ca-CKpd72XI.js +219 -0
- package/dist/channel-CJ2FoHig.js +8 -0
- package/dist/channel-DjKs64mj.cjs +2 -0
- package/dist/chunk-4BX2VUAB-DJlF8TIZ.cjs +2 -0
- package/dist/chunk-4BX2VUAB-ghaW5jSQ.js +18 -0
- package/dist/chunk-55IACEB6-9B1z6QHL.cjs +2 -0
- package/dist/chunk-55IACEB6-__yJgpDO.js +14 -0
- package/dist/chunk-B4BG7PRW-Dbzu88Oo.cjs +2 -0
- package/dist/chunk-B4BG7PRW-NVucxzRs.js +1828 -0
- package/dist/chunk-DI55MBZ5-Bun58OTZ.js +1928 -0
- package/dist/chunk-DI55MBZ5-e__JA50C.cjs +2 -0
- package/dist/chunk-FMBD7UC4-DulgQOWY.js +20 -0
- package/dist/chunk-FMBD7UC4-Pi8Fs7F6.cjs +2 -0
- package/dist/chunk-QN33PNHL-DA_6jplh.js +26 -0
- package/dist/chunk-QN33PNHL-DcHwlyDo.cjs +2 -0
- package/dist/chunk-QZHKN3VN-BfGBK4_s.cjs +2 -0
- package/dist/chunk-QZHKN3VN-C5x9oEL1.js +18 -0
- package/dist/chunk-TZMSLE5B-BCBp8EeB.cjs +2 -0
- package/dist/chunk-TZMSLE5B-Bj2-6aT8.js +109 -0
- package/dist/classDiagram-2ON5EDUG-BGUaVc1W.cjs +2 -0
- package/dist/classDiagram-2ON5EDUG-BcR1HP9z.js +20 -0
- package/dist/classDiagram-v2-WZHVMYZB-BGUaVc1W.cjs +2 -0
- package/dist/classDiagram-v2-WZHVMYZB-BcR1HP9z.js +20 -0
- package/dist/components/AISearchControl/index.d.ts +1 -0
- package/dist/components/Card/index.d.ts +0 -1
- package/dist/components/Carousel/index.d.ts +0 -3
- package/dist/components/Container/Container.d.ts +1 -9
- package/dist/components/Container/IContainerProps.d.ts +10 -4
- package/dist/components/Container/index.d.ts +1 -1
- package/dist/components/ContentRenderer/ContentRenderer.d.ts +1 -37
- package/dist/components/ContentRenderer/IContentRendererProps.d.ts +45 -0
- package/dist/components/ContentRenderer/index.d.ts +1 -1
- package/dist/components/DataGridV2/DataGridHandle.d.ts +14 -0
- package/dist/components/DataGridV2/DataGridV2.d.ts +2 -36
- package/dist/components/DataGridV2/IDataGridV2ExtraProps.d.ts +25 -0
- package/dist/components/DataGridV2/index.d.ts +1 -0
- package/dist/components/Grid/useGridStyles.d.ts +1 -1
- package/dist/components/ItemPicker/IItemPickerOption.d.ts +14 -0
- package/dist/components/ItemPicker/IItemPickerPagingInfo.d.ts +9 -0
- package/dist/components/ItemPicker/IItemPickerProps.d.ts +54 -0
- package/dist/components/ItemPicker/ItemPicker.d.ts +4 -0
- package/dist/components/ItemPicker/index.d.ts +5 -0
- package/dist/components/ItemPicker/useItemPickerStyles.d.ts +10 -0
- package/dist/components/KPIControl/IKpiCardData.d.ts +19 -0
- package/dist/components/KPIControl/IKpiCardProps.d.ts +6 -0
- package/dist/components/KPIControl/KpiCard.d.ts +4 -0
- package/dist/components/KPIControl/KpiCardCompact.d.ts +4 -0
- package/dist/components/KPIControl/KpiCardSkeleton.d.ts +8 -0
- package/dist/components/KPIControl/Kpis.d.ts +7 -0
- package/dist/components/KPIControl/NoKpisCard.d.ts +8 -0
- package/dist/components/KPIControl/index.d.ts +8 -0
- package/dist/components/KPIControl/useKpiStyles.d.ts +33 -0
- package/dist/components/ListToolbar/FlatItem.d.ts +8 -0
- package/dist/components/ListToolbar/IListToolbarProps.d.ts +27 -0
- package/dist/components/ListToolbar/IToolbarItem.d.ts +37 -0
- package/dist/components/ListToolbar/IToolbarItemRendererProps.d.ts +13 -0
- package/dist/components/ListToolbar/ListToolbar.d.ts +5 -0
- package/dist/components/ListToolbar/ToolbarItemRenderer.d.ts +7 -0
- package/dist/components/ListToolbar/helpers.d.ts +6 -0
- package/dist/components/ListToolbar/index.d.ts +4 -0
- package/dist/components/ListToolbar/useListToolbarStyles.d.ts +16 -0
- package/dist/components/ListToolbar/useOverflowIndex.d.ts +18 -0
- package/dist/components/MarkdownRenderer/MarkdownRenderer.d.ts +1 -1
- package/dist/components/MarkdownRenderer/useMarkdownStyles.d.ts +4 -0
- package/dist/components/MermaidDiagram/IMermaidDiagramProps.d.ts +31 -0
- package/dist/components/MermaidDiagram/MermaidDiagram.d.ts +4 -0
- package/dist/components/MermaidDiagram/index.d.ts +4 -0
- package/dist/components/MermaidDiagram/useMermaidDiagramStyles.d.ts +9 -0
- package/dist/components/Navigation/INavigationProps.d.ts +141 -0
- package/dist/components/Navigation/Navigation.d.ts +27 -0
- package/dist/components/Navigation/index.d.ts +4 -0
- package/dist/components/Navigation/useNavigationStyles.d.ts +13 -0
- package/dist/components/SelectTime/IOptionTimeProps.d.ts +23 -0
- package/dist/components/SelectTime/ISelectTimeProps.d.ts +25 -0
- package/dist/components/SelectTime/OptionTime.d.ts +16 -0
- package/dist/components/SelectTime/SelectTime.d.ts +4 -0
- package/dist/components/SelectTime/index.d.ts +7 -0
- package/dist/components/SelectTime/useOptionTimeStyles.d.ts +6 -0
- package/dist/components/SelectTime/useSelectTimeStyles.d.ts +7 -0
- package/dist/components/SplitPane/ISplitPaneProps.d.ts +28 -0
- package/dist/components/SplitPane/SplitPane.d.ts +10 -0
- package/dist/components/SplitPane/index.d.ts +4 -0
- package/dist/components/SplitPane/useSplitPaneStyles.d.ts +13 -0
- package/dist/components/adaptiveCardHost/AdaptiveCardHost.Utilities.d.ts +1 -1
- package/dist/components/adaptiveCardHost/fluentUI/renderCompat.d.ts +7 -0
- package/dist/components/aiAssistant/index.d.ts +1 -0
- package/dist/components/appDashboard/IAppDashboardProps.d.ts +2 -2
- package/dist/components/breadcrumb/IBreadcrumProps.d.ts +1 -1
- package/dist/components/breadcrumb/index.d.ts +1 -0
- package/dist/components/customControlBar/CustomControlBar.d.ts +1 -13
- package/dist/components/customControlBar/IControlItem.d.ts +6 -0
- package/dist/components/customControlBar/ICustomControlBarProps.d.ts +11 -0
- package/dist/components/customControlBar/index.d.ts +2 -0
- package/dist/components/dropDownField/useDropdownFieldStyles.d.ts +5 -0
- package/dist/components/index.d.ts +7 -0
- package/dist/components/inputField/IInputFieldProps.d.ts +22 -0
- package/dist/components/inputField/InputField.d.ts +4 -0
- package/dist/components/inputField/index.d.ts +3 -0
- package/dist/components/inputField/useInputFieldStyles.d.ts +5 -0
- package/dist/components/renderDrawer/RenderDrawer.d.ts +1 -4
- package/dist/components/renderHeader/index.d.ts +1 -0
- package/dist/components/searchControl/ISearchControlProps.d.ts +14 -0
- package/dist/components/searchControl/SearchControl.d.ts +5 -0
- package/dist/components/searchControl/index.d.ts +3 -0
- package/dist/components/searchControl/useSearchControlStyles.d.ts +13 -0
- package/dist/components/stackv2/StackV2.d.ts +1 -1
- package/dist/components/worldMap/index.d.ts +2 -0
- package/dist/components/worldMap/useContentToolTipStyles.d.ts +2 -8
- package/dist/cose-bilkent-S5V4N54A-BcLbJZT7.cjs +2 -0
- package/dist/cose-bilkent-S5V4N54A-CtEV3dGx.js +4934 -0
- package/dist/cs-D-801PIR.cjs +2 -0
- package/dist/cs-DQvRPciB.js +219 -0
- package/dist/cy-BxyJCM05.js +219 -0
- package/dist/cy-aUPUcn-S.cjs +2 -0
- package/dist/cytoscape.esm-BS1owLay.js +30250 -0
- package/dist/cytoscape.esm-BxB3woZB.cjs +10 -0
- package/dist/da-B05ad5Iq.js +219 -0
- package/dist/da-CTiLOqut.cjs +2 -0
- package/dist/dagre-6UL2VRFP-BZ9apxkx.js +696 -0
- package/dist/dagre-6UL2VRFP-FmOJGmX_.cjs +2 -0
- package/dist/de-DJ5iwpd7.js +219 -0
- package/dist/de-Dm204UMA.cjs +2 -0
- package/dist/defaultLocale-7NeEK7SF.cjs +2 -0
- package/dist/defaultLocale-DVr69WTU.js +207 -0
- package/dist/diagram-PSM6KHXK-BZxXJahR.cjs +2 -0
- package/dist/diagram-PSM6KHXK-_wkJk__z.js +848 -0
- package/dist/diagram-QEK2KX5R-NQiK3YZe.cjs +2 -0
- package/dist/diagram-QEK2KX5R-YQAU79Lo.js +305 -0
- package/dist/diagram-S2PKOQOG-Cob2HIrt.cjs +2 -0
- package/dist/diagram-S2PKOQOG-D8jaJbP8.js +212 -0
- package/dist/el-CBS9mHS3.js +219 -0
- package/dist/el-DbtZj-ph.cjs +2 -0
- package/dist/erDiagram-Q2GNP2WA-DAzex-RZ.cjs +2 -0
- package/dist/erDiagram-Q2GNP2WA-syuB6Tgc.js +1160 -0
- package/dist/es-Bo08apQr.js +219 -0
- package/dist/es-Cc-4Vqf7.cjs +2 -0
- package/dist/et-D5pQ66eY.cjs +2 -0
- package/dist/et-pRL0Tmle.js +219 -0
- package/dist/eu-Br68gaf7.js +219 -0
- package/dist/eu-RZ-27koK.cjs +2 -0
- package/dist/fi-BCXB-k_X.js +219 -0
- package/dist/fi-Dqa9mgnW.cjs +2 -0
- package/dist/flowDiagram-NV44I4VS-CXJA5Xu7.js +2339 -0
- package/dist/flowDiagram-NV44I4VS-DOcXDmk8.cjs +2 -0
- package/dist/fr-B7fhkle4.cjs +2 -0
- package/dist/fr-gKE1SSIF.js +219 -0
- package/dist/ga-4Hf7vKvr.cjs +2 -0
- package/dist/ga-C1SpITZy.js +219 -0
- package/dist/ganttDiagram-JELNMOA3-BodaBsjX.js +3652 -0
- package/dist/ganttDiagram-JELNMOA3-oeOE4Au1.cjs +2 -0
- package/dist/gitGraph-G5XIXVHT-BAoUh2t9.js +6 -0
- package/dist/gitGraph-G5XIXVHT-bEuOx0_B.cjs +2 -0
- package/dist/gitGraphDiagram-V2S2FVAM-B5dByD3_.js +1215 -0
- package/dist/gitGraphDiagram-V2S2FVAM-D4G2FRg-.cjs +2 -0
- package/dist/gl-COSpsMSK.cjs +2 -0
- package/dist/gl-CSzCeu2L.js +219 -0
- package/dist/graph-C7xixGrW.cjs +2 -0
- package/dist/graph-DH3cnEko.js +421 -0
- package/dist/he-BrkfqoIm.js +219 -0
- package/dist/he-C7Wi6-EL.cjs +2 -0
- package/dist/hi-C1RGDPzn.js +219 -0
- package/dist/hi-ojklJj-a.cjs +2 -0
- package/dist/hooks/index.d.ts +1 -0
- package/dist/hooks/useLocalizationStrings.d.ts +71 -0
- package/dist/hr-CsO_h2VT.js +219 -0
- package/dist/hr-DkEwOCGU.cjs +2 -0
- package/dist/hu-CVtbM-V2.js +219 -0
- package/dist/hu-D8uAAzvN.cjs +2 -0
- package/dist/id-18yPGK2f.cjs +2 -0
- package/dist/id-CARSN0W8.js +219 -0
- package/dist/index-CP55uT1-.js +55270 -0
- package/dist/index-DkoeCnje.cjs +428 -0
- package/dist/index.cjs +2 -0
- package/dist/index.d.ts +14 -0
- package/dist/index.js +165 -200
- package/dist/info-VBDWY6EO-CCtIeR-l.js +6 -0
- package/dist/info-VBDWY6EO-CIQZzC1h.cjs +2 -0
- package/dist/infoDiagram-HS3SLOUP-BCGLBWdb.js +32 -0
- package/dist/infoDiagram-HS3SLOUP-l61UBAGu.cjs +2 -0
- package/dist/init-DZ96s0AS.cjs +2 -0
- package/dist/init-ZxktEp_H.js +17 -0
- package/dist/it-BVq911RW.cjs +2 -0
- package/dist/it-ClWGK7XT.js +219 -0
- package/dist/ja-BgcKuKZ4.cjs +2 -0
- package/dist/ja-DGL12HwE.js +219 -0
- package/dist/journeyDiagram-XKPGCS4Q-CngaMpvw.js +1255 -0
- package/dist/journeyDiagram-XKPGCS4Q-DDFQr_sf.cjs +2 -0
- package/dist/kanban-definition-3W4ZIXB7-DE64tG2k.js +1049 -0
- package/dist/kanban-definition-3W4ZIXB7-Yh2cXBd5.cjs +2 -0
- package/dist/katex-DPu4QpBP.cjs +2 -0
- package/dist/katex-Dd1-wdX2.js +14523 -0
- package/dist/kk-CkKXbKso.js +219 -0
- package/dist/kk-Dn3FBkOR.cjs +2 -0
- package/dist/ko-CKAbV25b.cjs +2 -0
- package/dist/ko-QYvDV2aw.js +219 -0
- package/dist/layout-D6yO7DzL.cjs +2 -0
- package/dist/layout-bxkZz7Cm.js +1919 -0
- package/dist/linear-CytTXQM2.cjs +2 -0
- package/dist/linear-R5bATomY.js +341 -0
- package/dist/localization/ILibraryStrings.d.ts +299 -0
- package/dist/localization/defaults/ar.d.ts +8 -0
- package/dist/localization/defaults/az.d.ts +8 -0
- package/dist/localization/defaults/bg.d.ts +8 -0
- package/dist/localization/defaults/bs.d.ts +8 -0
- package/dist/localization/defaults/ca.d.ts +8 -0
- package/dist/localization/defaults/cs.d.ts +8 -0
- package/dist/localization/defaults/cy.d.ts +8 -0
- package/dist/localization/defaults/da.d.ts +8 -0
- package/dist/localization/defaults/de.d.ts +8 -0
- package/dist/localization/defaults/el.d.ts +8 -0
- package/dist/localization/defaults/en.d.ts +8 -0
- package/dist/localization/defaults/es.d.ts +8 -0
- package/dist/localization/defaults/et.d.ts +8 -0
- package/dist/localization/defaults/eu.d.ts +8 -0
- package/dist/localization/defaults/fi.d.ts +8 -0
- package/dist/localization/defaults/fr.d.ts +8 -0
- package/dist/localization/defaults/ga.d.ts +8 -0
- package/dist/localization/defaults/gl.d.ts +8 -0
- package/dist/localization/defaults/he.d.ts +8 -0
- package/dist/localization/defaults/hi.d.ts +8 -0
- package/dist/localization/defaults/hr.d.ts +8 -0
- package/dist/localization/defaults/hu.d.ts +8 -0
- package/dist/localization/defaults/id.d.ts +8 -0
- package/dist/localization/defaults/index.d.ts +47 -0
- package/dist/localization/defaults/it.d.ts +8 -0
- package/dist/localization/defaults/ja.d.ts +8 -0
- package/dist/localization/defaults/kk.d.ts +8 -0
- package/dist/localization/defaults/ko.d.ts +8 -0
- package/dist/localization/defaults/lt.d.ts +8 -0
- package/dist/localization/defaults/lv.d.ts +8 -0
- package/dist/localization/defaults/mk.d.ts +8 -0
- package/dist/localization/defaults/ms.d.ts +8 -0
- package/dist/localization/defaults/nb.d.ts +8 -0
- package/dist/localization/defaults/nl.d.ts +8 -0
- package/dist/localization/defaults/pl.d.ts +8 -0
- package/dist/localization/defaults/pt.d.ts +8 -0
- package/dist/localization/defaults/ro.d.ts +8 -0
- package/dist/localization/defaults/ru.d.ts +8 -0
- package/dist/localization/defaults/sk.d.ts +8 -0
- package/dist/localization/defaults/sl.d.ts +8 -0
- package/dist/localization/defaults/sr.d.ts +8 -0
- package/dist/localization/defaults/sv.d.ts +8 -0
- package/dist/localization/defaults/th.d.ts +8 -0
- package/dist/localization/defaults/tr.d.ts +8 -0
- package/dist/localization/defaults/uk.d.ts +8 -0
- package/dist/localization/defaults/vi.d.ts +8 -0
- package/dist/localization/defaults/zh.d.ts +8 -0
- package/dist/localization/index.d.ts +8 -0
- package/dist/localization/utils.d.ts +10 -0
- package/dist/lt-BKnFyiLV.js +219 -0
- package/dist/lt-BnGNEsIS.cjs +2 -0
- package/dist/lv-Clqo0Ogm.js +219 -0
- package/dist/lv-D3rJQRhc.cjs +2 -0
- package/dist/maplibre-gl-D9TSGNCf.cjs +6 -0
- package/dist/maplibre-gl-DwyiD0x9.js +23511 -0
- package/dist/mermaid-parser.core-BbdofhA6.js +23791 -0
- package/dist/mermaid-parser.core-C4ChZJz4.cjs +2 -0
- package/dist/mindmap-definition-VGOIOE7T-BonbrEly.cjs +2 -0
- package/dist/mindmap-definition-VGOIOE7T-C8FL7caj.js +1129 -0
- package/dist/mk-EhcD0RzW.js +219 -0
- package/dist/mk-hVxJgrE0.cjs +2 -0
- package/dist/ms-CJACwjo7.js +219 -0
- package/dist/ms-D0txYckK.cjs +2 -0
- package/dist/nb-BfKRl99z.cjs +2 -0
- package/dist/nb-NCgnP0Pu.js +219 -0
- package/dist/nl-EgsNCunP.js +219 -0
- package/dist/nl-ZXiLkBj_.cjs +2 -0
- package/dist/ordinal-BZdahNih.cjs +2 -0
- package/dist/ordinal-DSZU4PqD.js +77 -0
- package/dist/packet-DYOGHKS2-64UpspMA.cjs +2 -0
- package/dist/packet-DYOGHKS2-DCndr5Wp.js +6 -0
- package/dist/pie-VRWISCQL-B_5_SIgL.cjs +2 -0
- package/dist/pie-VRWISCQL-BbSFz_Jh.js +6 -0
- package/dist/pieDiagram-ADFJNKIX-C8b4kPLp.cjs +2 -0
- package/dist/pieDiagram-ADFJNKIX-CQjh4P80.js +238 -0
- package/dist/pl-H28GVtiG.js +219 -0
- package/dist/pl-tVjdYTB9.cjs +2 -0
- package/dist/providers.cjs +2 -0
- package/dist/providers.js +252 -1
- package/dist/pt-1k62N9F3.cjs +2 -0
- package/dist/pt-BSPZhWKl.js +211 -0
- package/dist/quadrantDiagram-AYHSOK5B-Bb99yQJL.cjs +2 -0
- package/dist/quadrantDiagram-AYHSOK5B-BiLBDCHf.js +1338 -0
- package/dist/radar-ZZBFDIW7-DC8bA3_e.cjs +2 -0
- package/dist/radar-ZZBFDIW7-DpGZ3D_F.js +6 -0
- package/dist/requirementDiagram-UZGBJVZJ-BeLfR5tA.cjs +2 -0
- package/dist/requirementDiagram-UZGBJVZJ-D6hcN5kf.js +1164 -0
- package/dist/ro-9Qt1qDDA.cjs +2 -0
- package/dist/ro-BpaZLre_.js +219 -0
- package/dist/ru-4WxRouIU.cjs +2 -0
- package/dist/ru-CUZzD-Tx.js +219 -0
- package/dist/sankeyDiagram-TZEHDZUN-7K2pggbF.js +1194 -0
- package/dist/sankeyDiagram-TZEHDZUN-T1lqY3ke.cjs +2 -0
- package/dist/sequenceDiagram-WL72ISMW-CaSRrEHR.cjs +2 -0
- package/dist/sequenceDiagram-WL72ISMW-DymCRly8.js +3882 -0
- package/dist/sk-CoQ6XiCY.js +219 -0
- package/dist/sk-uWukDQab.cjs +2 -0
- package/dist/sl-B6DVbKg6.cjs +2 -0
- package/dist/sl-CHW-ZGol.js +219 -0
- package/dist/sr-BOD8Tc-D.cjs +2 -0
- package/dist/sr-EQGjIBJE.js +219 -0
- package/dist/stateDiagram-FKZM4ZOC-B3uhYYpW.js +449 -0
- package/dist/stateDiagram-FKZM4ZOC-BETxyYxX.cjs +2 -0
- package/dist/stateDiagram-v2-4FDKWEC3-B4AjT1wB.cjs +2 -0
- package/dist/stateDiagram-v2-4FDKWEC3-BuiA8K0X.js +20 -0
- package/dist/style.css +1 -0
- package/dist/sv-B6nLuQr7.cjs +2 -0
- package/dist/sv-DTxWN6ED.js +219 -0
- package/dist/th-BVPzHvBf.js +219 -0
- package/dist/th-DmULV6uT.cjs +2 -0
- package/dist/timeline-definition-IT6M3QCI-CsJvwNrg.cjs +2 -0
- package/dist/timeline-definition-IT6M3QCI-DNROY61n.js +1227 -0
- package/dist/tr-BE5geTUC.cjs +2 -0
- package/dist/tr-BHR1QA-D.js +219 -0
- package/dist/treemap-GDKQZRPO-DbPXSmw-.js +6 -0
- package/dist/treemap-GDKQZRPO-Dj3L_VQH.cjs +2 -0
- package/dist/uk-Bc5TwelE.js +219 -0
- package/dist/uk-DS5ukB_-.cjs +2 -0
- package/dist/vi-D9FF4kkG.cjs +2 -0
- package/dist/vi-DC0eQZb7.js +219 -0
- package/dist/xychartDiagram-PRI3JC2R-CXT2FhOm.cjs +2 -0
- package/dist/xychartDiagram-PRI3JC2R-D7UaoGaC.js +1887 -0
- package/dist/zh-CGcOiJ3s.cjs +2 -0
- package/dist/zh-GsCLn8OE.js +219 -0
- package/package.json +95 -92
- package/dist/ILoggingProvider-C4FFlnQ0.js +0 -2
- package/dist/ILoggingProvider-C4FFlnQ0.js.map +0 -1
- package/dist/ILoggingProvider-CYYYCGLY.mjs +0 -18
- package/dist/ILoggingProvider-CYYYCGLY.mjs.map +0 -1
- package/dist/abstractions/IApplicationContext.d.ts.map +0 -1
- package/dist/abstractions/IAuthenticationProvider.d.ts.map +0 -1
- package/dist/abstractions/IGraphProvider.d.ts.map +0 -1
- package/dist/abstractions/ILoggingProvider.d.ts.map +0 -1
- package/dist/abstractions/IPageContext.d.ts.map +0 -1
- package/dist/abstractions/IStorageProvider.d.ts.map +0 -1
- package/dist/abstractions/index.d.ts.map +0 -1
- package/dist/abstractions/providers/ConsoleLoggingProvider.d.ts.map +0 -1
- package/dist/abstractions/providers/DefaultGraphClient.d.ts.map +0 -1
- package/dist/abstractions/providers/LocalStorageProvider.d.ts.map +0 -1
- package/dist/abstractions/providers/index.d.ts.map +0 -1
- package/dist/components/AISearchControl/AISearchControl.d.ts.map +0 -1
- package/dist/components/AISearchControl/AISearchIcon.d.ts.map +0 -1
- package/dist/components/AISearchControl/AISearchIconExample.d.ts.map +0 -1
- package/dist/components/AISearchControl/index.d.ts.map +0 -1
- package/dist/components/AISearchControl/useAISearchControlStyles.d.ts.map +0 -1
- package/dist/components/AspectRatio/AspectRatio.d.ts.map +0 -1
- package/dist/components/AspectRatio/IAspectRationProps.d.ts.map +0 -1
- package/dist/components/AspectRatio/index.d.ts.map +0 -1
- package/dist/components/AspectRatio/useAspectRatioStyles.d.ts.map +0 -1
- package/dist/components/Card/Card.d.ts.map +0 -1
- package/dist/components/Card/ICardProps.d.ts.map +0 -1
- package/dist/components/Card/index.d.ts.map +0 -1
- package/dist/components/Card/useCardStyles.d.ts.map +0 -1
- package/dist/components/Carousel/Carousel.d.ts.map +0 -1
- package/dist/components/Carousel/ICarouselProps.d.ts.map +0 -1
- package/dist/components/Carousel/index.d.ts.map +0 -1
- package/dist/components/Carousel/useCarouselButton.d.ts.map +0 -1
- package/dist/components/Carousel/useCarouselStyles.d.ts.map +0 -1
- package/dist/components/Carousel/useCarouselStylesMain.d.ts.map +0 -1
- package/dist/components/Center/Center.d.ts.map +0 -1
- package/dist/components/Center/ICenterProps.d.ts.map +0 -1
- package/dist/components/Center/index.d.ts.map +0 -1
- package/dist/components/Center/useCenterStyles.d.ts.map +0 -1
- package/dist/components/Container/Container.d.ts.map +0 -1
- package/dist/components/Container/IContainerProps.d.ts.map +0 -1
- package/dist/components/Container/index.d.ts.map +0 -1
- package/dist/components/Container/useContainerStyles.d.ts.map +0 -1
- package/dist/components/ContentRenderer/ContentRenderer.d.ts.map +0 -1
- package/dist/components/ContentRenderer/index.d.ts.map +0 -1
- package/dist/components/DataGridV2/DataGridV2.d.ts.map +0 -1
- package/dist/components/DataGridV2/index.d.ts.map +0 -1
- package/dist/components/DataGridV2/useDataGridV2Styles.d.ts.map +0 -1
- package/dist/components/Grid/Grid.d.ts.map +0 -1
- package/dist/components/Grid/IGridProps.d.ts.map +0 -1
- package/dist/components/Grid/index.d.ts.map +0 -1
- package/dist/components/Grid/useGridStyles.d.ts.map +0 -1
- package/dist/components/Layout/ILayoutProps.d.ts.map +0 -1
- package/dist/components/Layout/Layout.d.ts.map +0 -1
- package/dist/components/Layout/LayoutItem.d.ts.map +0 -1
- package/dist/components/Layout/index.d.ts.map +0 -1
- package/dist/components/Layout/useLayoutStyles.d.ts.map +0 -1
- package/dist/components/ListItemActivityMessage/IAction.d.ts.map +0 -1
- package/dist/components/ListItemActivityMessage/IActivity.d.ts.map +0 -1
- package/dist/components/ListItemActivityMessage/IActivityMessageProps.d.ts.map +0 -1
- package/dist/components/ListItemActivityMessage/IActor.d.ts.map +0 -1
- package/dist/components/ListItemActivityMessage/IUserActor.d.ts.map +0 -1
- package/dist/components/ListItemActivityMessage/ListItemActivityMessage.d.ts.map +0 -1
- package/dist/components/ListItemActivityMessage/index.d.ts.map +0 -1
- package/dist/components/ListItemActivityMessage/useSharePointActivities.d.ts.map +0 -1
- package/dist/components/LivePersona/ILivePersonaProps.d.ts.map +0 -1
- package/dist/components/LivePersona/LivePersona.d.ts.map +0 -1
- package/dist/components/LivePersona/index.d.ts.map +0 -1
- package/dist/components/MarkdownRenderer/MarkdownRenderer.d.ts.map +0 -1
- package/dist/components/MarkdownRenderer/index.d.ts.map +0 -1
- package/dist/components/Popup/Popup.d.ts.map +0 -1
- package/dist/components/Popup/index.d.ts.map +0 -1
- package/dist/components/Provider/UniversalProvider.d.ts.map +0 -1
- package/dist/components/Provider/index.d.ts.map +0 -1
- package/dist/components/RenderLabel/RenderLabel.d.ts.map +0 -1
- package/dist/components/RenderLabel/index.d.ts.map +0 -1
- package/dist/components/RenderLabel/useRenderLabelStylesStyles.d.ts.map +0 -1
- package/dist/components/RenderSpninner/RenderSpinner.d.ts.map +0 -1
- package/dist/components/RenderSpninner/index.d.ts.map +0 -1
- package/dist/components/Space/ISpaceProps.d.ts.map +0 -1
- package/dist/components/Space/SPace.d.ts.map +0 -1
- package/dist/components/Space/index.d.ts.map +0 -1
- package/dist/components/Space/useSpaceStyles.d.ts.map +0 -1
- package/dist/components/Stack/IStackProps.d.ts.map +0 -1
- package/dist/components/Stack/Stack.d.ts.map +0 -1
- package/dist/components/Stack/StackItem.d.ts.map +0 -1
- package/dist/components/Stack/index.d.ts.map +0 -1
- package/dist/components/Stack/useStackStyles.d.ts.map +0 -1
- package/dist/components/StackedUsers/IStackedUsersProps.d.ts.map +0 -1
- package/dist/components/StackedUsers/StackedUsers.d.ts.map +0 -1
- package/dist/components/StackedUsers/index.d.ts.map +0 -1
- package/dist/components/StackedUsers/useStackedUsersStyles.d.ts.map +0 -1
- package/dist/components/adaptiveCardHost/AdaptiveCardHost.Exports.d.ts.map +0 -1
- package/dist/components/adaptiveCardHost/AdaptiveCardHost.HostConfig.d.ts.map +0 -1
- package/dist/components/adaptiveCardHost/AdaptiveCardHost.Utilities.d.ts.map +0 -1
- package/dist/components/adaptiveCardHost/AdaptiveCardHost.d.ts.map +0 -1
- package/dist/components/adaptiveCardHost/IAdaptiveCardHostProps.d.ts.map +0 -1
- package/dist/components/adaptiveCardHost/fluentUI/Actions.d.ts.map +0 -1
- package/dist/components/adaptiveCardHost/fluentUI/Elements.d.ts.map +0 -1
- package/dist/components/adaptiveCardHost/fluentUI/FluentUIChoiceSetInput.d.ts.map +0 -1
- package/dist/components/adaptiveCardHost/fluentUI/FluentUIDateInput.d.ts.map +0 -1
- package/dist/components/adaptiveCardHost/fluentUI/FluentUINumberInput.d.ts.map +0 -1
- package/dist/components/adaptiveCardHost/fluentUI/FluentUITextInput.d.ts.map +0 -1
- package/dist/components/adaptiveCardHost/fluentUI/FluentUITimeInput.d.ts.map +0 -1
- package/dist/components/adaptiveCardHost/fluentUI/FluentUIToggleInput.d.ts.map +0 -1
- package/dist/components/adaptiveCardHost/fluentUI/HostCapability.d.ts.map +0 -1
- package/dist/components/adaptiveCardHost/fluentUI/HostConfig.d.ts.map +0 -1
- package/dist/components/adaptiveCardHost/fluentUI/IconButton.d.ts.map +0 -1
- package/dist/components/adaptiveCardHost/fluentUI/Styles.d.ts.map +0 -1
- package/dist/components/adaptiveCardHost/fluentUI/index.d.ts.map +0 -1
- package/dist/components/adaptiveCardHost/fluentUI/inlineButtonRootStyle.d.ts.map +0 -1
- package/dist/components/adaptiveCardHost/fluentUI/internalRender.d.ts.map +0 -1
- package/dist/components/adaptiveCardHost/index.d.ts.map +0 -1
- package/dist/components/adaptiveCardHost/models/AdaptiveCardHostThemeType.d.ts.map +0 -1
- package/dist/components/adaptiveCardHost/models/IAadInfo.d.ts.map +0 -1
- package/dist/components/adaptiveCardHost/models/IAdaptiveCardHostActionResult.d.ts.map +0 -1
- package/dist/components/adaptiveCardHost/models/IAdaptiveCardHostConfigResult.d.ts.map +0 -1
- package/dist/components/adaptiveCardHost/models/IAdaptiveCardHostEvaluationContext.d.ts.map +0 -1
- package/dist/components/adaptiveCardHost/models/ICultureInfo.d.ts.map +0 -1
- package/dist/components/adaptiveCardHost/models/ISPListInfo.d.ts.map +0 -1
- package/dist/components/adaptiveCardHost/models/ISPListItemInfo.d.ts.map +0 -1
- package/dist/components/adaptiveCardHost/models/ISPSiteInfo.d.ts.map +0 -1
- package/dist/components/adaptiveCardHost/models/ISPWebInfo.d.ts.map +0 -1
- package/dist/components/adaptiveCardHost/models/IUserInfo.d.ts.map +0 -1
- package/dist/components/adaptiveCardHost/models/index.d.ts.map +0 -1
- package/dist/components/aiAssistant/AIAssistant.d.ts.map +0 -1
- package/dist/components/aiAssistant/ChatAction.d.ts.map +0 -1
- package/dist/components/aiAssistant/ChatInput.d.ts.map +0 -1
- package/dist/components/aiAssistant/ChatInputProps.d.ts.map +0 -1
- package/dist/components/aiAssistant/ChatInputWithMensions.d.ts.map +0 -1
- package/dist/components/aiAssistant/ChatInputWithMensionsProps.d.ts.map +0 -1
- package/dist/components/aiAssistant/ChatInputWithMensionsV1.d.ts.map +0 -1
- package/dist/components/aiAssistant/ChatInputWithMensionsV2.d.ts.map +0 -1
- package/dist/components/aiAssistant/ChatList.d.ts.map +0 -1
- package/dist/components/aiAssistant/ChatState.d.ts.map +0 -1
- package/dist/components/aiAssistant/IAIAssistantProps.d.ts.map +0 -1
- package/dist/components/aiAssistant/IChatItem.d.ts.map +0 -1
- package/dist/components/aiAssistant/IResponse.d.ts.map +0 -1
- package/dist/components/aiAssistant/LoadingDots.d.ts.map +0 -1
- package/dist/components/aiAssistant/chatReducer.d.ts.map +0 -1
- package/dist/components/aiAssistant/index.d.ts.map +0 -1
- package/dist/components/aiAssistant/useAIAssistantStyles.d.ts.map +0 -1
- package/dist/components/aiAssistant/useChatInputStyles.d.ts.map +0 -1
- package/dist/components/aiAssistant/useChatInputWithMensionsStyles.d.ts.map +0 -1
- package/dist/components/aiAssistant/useLoadingDotsStyles.d.ts.map +0 -1
- package/dist/components/aiAssistant/useStreamRequest.d.ts.map +0 -1
- package/dist/components/aiAssistant/useStyles.d.ts.map +0 -1
- package/dist/components/appDashboard/AppDashboard.d.ts.map +0 -1
- package/dist/components/appDashboard/IAppDashboardProps.d.ts.map +0 -1
- package/dist/components/appDashboard/NoDashboards.d.ts.map +0 -1
- package/dist/components/appDashboard/index.d.ts.map +0 -1
- package/dist/components/appDashboard/selectZoom/SelectZoom.d.ts.map +0 -1
- package/dist/components/appDashboard/useDashboardStyles.d.ts.map +0 -1
- package/dist/components/baseComponentProps/IBaseProps.d.ts.map +0 -1
- package/dist/components/breadcrumb/Breadcrumb.d.ts.map +0 -1
- package/dist/components/breadcrumb/IBreadcrumItem.d.ts.map +0 -1
- package/dist/components/breadcrumb/IBreadcrumProps.d.ts.map +0 -1
- package/dist/components/breadcrumb/OverflowMenu.d.ts.map +0 -1
- package/dist/components/breadcrumb/index.d.ts.map +0 -1
- package/dist/components/breadcrumb/useBreadcrumStyles.d.ts.map +0 -1
- package/dist/components/buttonMenu/ButtonMenu.d.ts.map +0 -1
- package/dist/components/buttonMenu/IButtonMenuOption.d.ts.map +0 -1
- package/dist/components/buttonMenu/index.d.ts.map +0 -1
- package/dist/components/calendarControl/CalendarControl.d.ts.map +0 -1
- package/dist/components/calendarControl/Day.d.ts.map +0 -1
- package/dist/components/calendarControl/DayView.d.ts.map +0 -1
- package/dist/components/calendarControl/EventDetailsPopover.d.ts.map +0 -1
- package/dist/components/calendarControl/EventPopoverCard.d.ts.map +0 -1
- package/dist/components/calendarControl/EventRender.d.ts.map +0 -1
- package/dist/components/calendarControl/RenderEventToDayOfMonth.d.ts.map +0 -1
- package/dist/components/calendarControl/SelectCalendarView.d.ts.map +0 -1
- package/dist/components/calendarControl/Toolbar.d.ts.map +0 -1
- package/dist/components/calendarControl/WeekView.d.ts.map +0 -1
- package/dist/components/calendarControl/hooks/index.d.ts.map +0 -1
- package/dist/components/calendarControl/hooks/useCalendar.d.ts.map +0 -1
- package/dist/components/calendarControl/hooks/useCalendarStyles.d.ts.map +0 -1
- package/dist/components/calendarControl/hooks/useDayViewStyles.d.ts.map +0 -1
- package/dist/components/calendarControl/hooks/useUtils.d.ts.map +0 -1
- package/dist/components/calendarControl/hooks/useWeekViewStyles.d.ts.map +0 -1
- package/dist/components/calendarControl/index.d.ts.map +0 -1
- package/dist/components/calendarControl/models/ECalendarViews.d.ts.map +0 -1
- package/dist/components/calendarControl/models/IAttendee.d.ts.map +0 -1
- package/dist/components/calendarControl/models/ICalendarControlProps.d.ts.map +0 -1
- package/dist/components/calendarControl/models/ICalendarDay.d.ts.map +0 -1
- package/dist/components/calendarControl/models/IEventColors.d.ts.map +0 -1
- package/dist/components/calendarControl/models/IEvents.d.ts.map +0 -1
- package/dist/components/calendarControl/models/IStrings.d.ts.map +0 -1
- package/dist/components/calendarControl/models/index.d.ts.map +0 -1
- package/dist/components/customControlBar/CustomControlBar.d.ts.map +0 -1
- package/dist/components/customControlBar/index.d.ts.map +0 -1
- package/dist/components/dataGrid/DataGrid.d.ts.map +0 -1
- package/dist/components/dataGrid/IColumnConfig.d.ts.map +0 -1
- package/dist/components/dataGrid/IDataGridProps.d.ts.map +0 -1
- package/dist/components/dataGrid/ISortState.d.ts.map +0 -1
- package/dist/components/dataGrid/index.d.ts.map +0 -1
- package/dist/components/dataGrid/stack/IStackProps.d.ts.map +0 -1
- package/dist/components/dataGrid/stack/Stack.d.ts.map +0 -1
- package/dist/components/dataGrid/useDataGridStyles.d.ts.map +0 -1
- package/dist/components/dropDownField/DropDownField.d.ts.map +0 -1
- package/dist/components/dropDownField/IDropDownFieldProps.d.ts.map +0 -1
- package/dist/components/dropDownField/IOption.d.ts.map +0 -1
- package/dist/components/dropDownField/index.d.ts.map +0 -1
- package/dist/components/genericOverFlowMenu/GenericOverFlowMenu.d.ts.map +0 -1
- package/dist/components/genericOverFlowMenu/index.d.ts.map +0 -1
- package/dist/components/genericOverFlowMenu/useOverflowMenuStyles.d.ts.map +0 -1
- package/dist/components/iconButton/IconButton.d.ts.map +0 -1
- package/dist/components/iconButton/IconButtonProps.d.ts.map +0 -1
- package/dist/components/iconButton/index.d.ts.map +0 -1
- package/dist/components/index.d.ts.map +0 -1
- package/dist/components/mensions/IMensionsProps.d.ts.map +0 -1
- package/dist/components/mensions/Mensions.d.ts.map +0 -1
- package/dist/components/mensions/MensionsExample.d.ts.map +0 -1
- package/dist/components/mensions/index.d.ts.map +0 -1
- package/dist/components/mensions/useMensionsStyles.d.ts.map +0 -1
- package/dist/components/renderAdaptiveCard/RenderAdaptiveCard.d.ts.map +0 -1
- package/dist/components/renderAdaptiveCard/index.d.ts.map +0 -1
- package/dist/components/renderDialog/RenderDialog.d.ts.map +0 -1
- package/dist/components/renderDialog/index.d.ts.map +0 -1
- package/dist/components/renderDrawer/RenderDrawer.d.ts.map +0 -1
- package/dist/components/renderDrawer/index.d.ts.map +0 -1
- package/dist/components/renderHeader/IRenderHeaderProps.d.ts.map +0 -1
- package/dist/components/renderHeader/RenderHeader.d.ts.map +0 -1
- package/dist/components/renderHeader/index.d.ts.map +0 -1
- package/dist/components/renderHeader/useRenderHeaderStyles.d.ts.map +0 -1
- package/dist/components/selectDay/SelectDay.d.ts.map +0 -1
- package/dist/components/selectDay/index.d.ts.map +0 -1
- package/dist/components/selectMonth/CalendarMonth.d.ts.map +0 -1
- package/dist/components/selectMonth/SelectMonth.d.ts.map +0 -1
- package/dist/components/selectMonth/index.d.ts.map +0 -1
- package/dist/components/selectView/SelectView.d.ts.map +0 -1
- package/dist/components/selectView/index.d.ts.map +0 -1
- package/dist/components/selectWeek/SelectWeek.d.ts.map +0 -1
- package/dist/components/selectWeek/index.d.ts.map +0 -1
- package/dist/components/shareDialog/ShareDialog.d.ts.map +0 -1
- package/dist/components/shareDialog/index.d.ts.map +0 -1
- package/dist/components/showError/IErrorDisplayProps.d.ts.map +0 -1
- package/dist/components/showError/ShowError.d.ts.map +0 -1
- package/dist/components/showError/index.d.ts.map +0 -1
- package/dist/components/showError/useShowErrorStyles.d.ts.map +0 -1
- package/dist/components/showMessage/IShowMessage.d.ts.map +0 -1
- package/dist/components/showMessage/ShowMessage.d.ts.map +0 -1
- package/dist/components/showMessage/index.d.ts.map +0 -1
- package/dist/components/showMessage/useShowMessageStyles.d.ts.map +0 -1
- package/dist/components/stackv2/IStackV2Props.d.ts.map +0 -1
- package/dist/components/stackv2/StackV2.d.ts.map +0 -1
- package/dist/components/stackv2/index.d.ts.map +0 -1
- package/dist/components/svgImages/BusinessReportIcon.d.ts.map +0 -1
- package/dist/components/typographyControl/ITypographyControlProps.d.ts.map +0 -1
- package/dist/components/typographyControl/TypographyControl.d.ts.map +0 -1
- package/dist/components/typographyControl/index.d.ts.map +0 -1
- package/dist/components/userCard/IUserCardProps.d.ts.map +0 -1
- package/dist/components/userCard/IUserInfo.d.ts.map +0 -1
- package/dist/components/userCard/UserCard.d.ts.map +0 -1
- package/dist/components/userCard/constants.d.ts.map +0 -1
- package/dist/components/userCard/index.d.ts.map +0 -1
- package/dist/components/userCard/useUserCardStyles.d.ts.map +0 -1
- package/dist/components/userCard/useUserProfile.d.ts.map +0 -1
- package/dist/components/videoPlayer/VideoPlayer.d.ts.map +0 -1
- package/dist/components/videoPlayer/index.d.ts.map +0 -1
- package/dist/components/videoPlayer/useVideoStyles.d.ts.map +0 -1
- package/dist/components/worldMap/IWorldMapProps.d.ts.map +0 -1
- package/dist/components/worldMap/MapNavigation.d.ts.map +0 -1
- package/dist/components/worldMap/MaplibreWorldMapProps.d.ts.map +0 -1
- package/dist/components/worldMap/TooltipContent.d.ts.map +0 -1
- package/dist/components/worldMap/WorldMap.d.ts.map +0 -1
- package/dist/components/worldMap/WorldMapControl.d.ts.map +0 -1
- package/dist/components/worldMap/data.d.ts.map +0 -1
- package/dist/components/worldMap/index.d.ts.map +0 -1
- package/dist/components/worldMap/marker.d.ts.map +0 -1
- package/dist/components/worldMap/useCleanMapStyle.d.ts.map +0 -1
- package/dist/components/worldMap/useContentToolTipStyles.d.ts.map +0 -1
- package/dist/components/worldMap/useGeocodedCountries.d.ts.map +0 -1
- package/dist/constants/EBreakPoints.d.ts.map +0 -1
- package/dist/constants/EMessageTypes.d.ts.map +0 -1
- package/dist/constants/index.d.ts.map +0 -1
- package/dist/hooks/index.d.ts.map +0 -1
- package/dist/hooks/useAIAssistant.d.ts.map +0 -1
- package/dist/hooks/useAIAssistantParser.d.ts.map +0 -1
- package/dist/hooks/useGraphAPI.d.ts.map +0 -1
- package/dist/hooks/useIndexedDB.d.ts.map +0 -1
- package/dist/hooks/useLogging.d.ts.map +0 -1
- package/dist/hooks/usePolling.d.ts.map +0 -1
- package/dist/hooks/useTimeZone.d.ts.map +0 -1
- package/dist/hooks/useTimeZoneHelper.d.ts.map +0 -1
- package/dist/index.d.ts.map +0 -1
- package/dist/index.js.map +0 -1
- package/dist/index.mjs +0 -27983
- package/dist/index.mjs.map +0 -1
- package/dist/models/IAppCardContainer.d.ts.map +0 -1
- package/dist/models/index.d.ts.map +0 -1
- package/dist/providers.js.map +0 -1
- package/dist/providers.mjs +0 -250
- package/dist/providers.mjs.map +0 -1
- package/dist/types/TBaseSpacing.d.ts.map +0 -1
- package/dist/types/THorizontalSpacing.d.ts.map +0 -1
- package/dist/types/THorizontalSpacingBreakPoints.d.ts.map +0 -1
- package/dist/types/TLayoutBreakPoints.d.ts.map +0 -1
- package/dist/types/TPaddingBreakPoints.d.ts.map +0 -1
- package/dist/types/TPading.d.ts.map +0 -1
- package/dist/types/TVerticalSpacing.d.ts.map +0 -1
- package/dist/types/TVerticalSpacingBreakPoints.d.ts.map +0 -1
- package/dist/types/index.d.ts.map +0 -1
- package/dist/utils/contentDetector.d.ts.map +0 -1
- package/dist/utils/index.d.ts.map +0 -1
- package/dist/utils/lodash.d.ts.map +0 -1
- package/dist/utils/useComponentsUtils.d.ts.map +0 -1
- package/dist/utils/useDateUtils.d.ts.map +0 -1
- package/dist/utils/useImageUtils.d.ts.map +0 -1
|
@@ -0,0 +1,428 @@
|
|
|
1
|
+
"use strict";var e,t,r,n,i,o,a,s,l,c,u,h,d,p,f,g,m=Object.defineProperty,y=(e,t,r)=>((e,t,r)=>t in e?m(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r)(e,"symbol"!=typeof t?t+"":t,r);const x=require("./LocalizationProvider-BLjmybBa.cjs"),b=require("react/jsx-runtime"),v=require("react"),C=require("date-fns-tz"),w=require("@fluentui/react-components"),k=require("date-fns"),S=require("lodash"),_=require("@juggle/resize-observer"),T=require("@emotion/css"),A=require("embla-carousel-react"),P=require("@fluentui/react-icons"),E=require("react-dom"),M=require("@iconify/react"),I=require("@fluentui/react-calendar-compat"),B=require("@fluentui-contrib/react-data-grid-react-window"),L=require("react-player"),j=require("adaptivecards"),N=require("nano-css"),D=require("markdown-it"),O=require("@fluentui/react-datepicker-compat"),F=require("@fluentui/react-timepicker-compat"),R=require("adaptivecards-templating"),$=require("textarea-caret"),z=require("@fluentui-contrib/react-chat"),V=require("@fluentui/react-motion-components-preview");function W(e){const t=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e)for(const r in e)if("default"!==r){const n=Object.getOwnPropertyDescriptor(e,r);Object.defineProperty(t,r,n.get?n:{enumerable:!0,get:()=>e[r]})}return t.default=e,Object.freeze(t)}const H=W(b),q=W(v),U=W(E),G=W(j),X=W(D);var J=(e=>(e[e.XXXLarge=1900]="XXXLarge",e[e.ExtraExtraLarge=1400]="ExtraExtraLarge",e[e.ExtraLarge=1200]="ExtraLarge",e[e.Large=992]="Large",e[e.Medium=768]="Medium",e[e.Small=576]="Small",e[e.ExtraSmall=320]="ExtraSmall",e))(J||{}),Y=(e=>(e.INFO="info",e.ERROR="error",e.SUCCESS="success",e))(Y||{});const Z=v.createContext(void 0),K=()=>v.useContext(Z),Q=()=>{const e=K(),t=null==e?void 0:e.loggingProvider;return{log:(e,r=x.LogLevel.Info,n)=>{t?t.log(e,r,n):console.log(e,n)},error:(e,r,n)=>{t?t.error(e,r,n):console.error(e,r,n)},warn:(e,r)=>{t?t.warn(e,r):console.warn(e,r)},info:(e,r)=>{t?t.info(e,r):console.info(e,r)},verbose:(e,r)=>{t?t.verbose(e,r):console.debug(e,r)},LogLevel:x.LogLevel,ErrorType:x.ErrorType}},ee=()=>{const e=K(),t=null==e?void 0:e.storageProvider,{warn:r,error:n}=Q();return{getCachedData:v.useCallback(async e=>{if(t)try{return await t.get(e)}catch(i){return void n("Error reading from cache:",i instanceof Error?i:void 0)}else r("Storage provider not available")},[t]),setCachedData:v.useCallback(async(e,i,o)=>{if(t)try{await t.set(e,i,o)}catch(a){n("Error writing to cache:",a instanceof Error?a:void 0)}else r("Storage provider not available")},[t]),removeCachedData:v.useCallback(async e=>{if(t)try{await t.remove(e)}catch(i){n("Error removing from cache:",i instanceof Error?i:void 0)}else r("Storage provider not available")},[t]),clearCache:v.useCallback(async()=>{if(t)try{await t.clear()}catch(e){n("Error clearing cache:",e instanceof Error?e:void 0)}else r("Storage provider not available")},[t])}},te=(e,t,r=!0)=>{const[n,i]=v.useState(!1),o=v.useRef(null),a=v.useRef(e);v.useEffect(()=>{a.current=e},[e]);const s=v.useCallback(()=>{o.current||(i(!0),r&&a.current(),o.current=setInterval(()=>{a.current()},t))},[t,r]),l=v.useCallback(()=>{o.current&&(clearInterval(o.current),o.current=null,i(!1))},[]);return v.useEffect(()=>()=>{l()},[l]),{startPolling:s,stopPolling:l,isPolling:n}},re=e=>{const[t,r]=v.useState(""),[n,i]=v.useState(!1),[o,a]=v.useState(null),s=v.useRef(null),{parseSSEResponse:l}=(()=>{const{verbose:e,error:t}=Q();return{parseSSEResponse:v.useCallback((r,n={})=>{const{stripMarkdown:i=!0,debug:a=!1}=n;if(!r||"string"!=typeof r)return{data:void 0,rawText:"",isJson:!1,error:"Invalid input: rawResponse must be a non-empty string"};try{a&&(e("[useAIAssistantParser] Raw SSE input (full):",r),e("[useAIAssistantParser] Raw SSE length:",r.length));const t=r.split("\n"),n=[];let o,l=!1,c="",u=!1;for(let r=0;r<t.length;r++){const i=t[r];if(a&&r<20&&e(`[useAIAssistantParser] Line ${r}:`,JSON.stringify(i)),i.startsWith("event: done")){c.trim()&&(n.push(c.trim()),c="");break}if(!i.startsWith("event:")||i.startsWith("event: done"))if(i.startsWith("data: ")){const e=i.substring(6);l=!0,u&&c?c+="\n"+e:(c=e,u=!0)}else{if(""===i.trim()&&!u)continue;if(u&&""!==i.trim())c+="\n"+i;else if(""===i.trim()&&u){const e=r+1;if(e<t.length){const r=t[e];r.startsWith("event:")||e===t.length-1?(c.trim()&&(n.push(c.trim()),c=""),u=!1):""!==r.trim()?c+="\n":(c.trim()&&(n.push(c.trim()),c=""),u=!1)}}}else c.trim()&&(n.push(c.trim()),c=""),u=!1}c.trim()&&n.push(c.trim()),a&&(e(`[useAIAssistantParser] Found ${n.length} data blocks`),n.forEach((t,r)=>{e(`[useAIAssistantParser] Block ${r} (length: ${t.length}):`,t)}));let h=[];for(const r of n){let t=r.trim();i&&(t=t.replace(/^```json\s*/i,"").replace(/```\s*$/,""),t=t.trim());try{const r=JSON.parse(t);if("object"==typeof r&&null!==r){const n=Object.keys(r),i=["status","requestId","tokenCount","durationMs"];if(n.length>0&&n.every(e=>i.includes(e))){a&&e("[useAIAssistantParser] Skipping metadata/status-only JSON block:",t);continue}}o=r,a&&e("[useAIAssistantParser] Successfully parsed data block as JSON")}catch(s){t.match(/^\s*\{\s*["']?status["']?\s*:\s*["']?\w+["']?\s*\}\s*$/)?a&&e("[useAIAssistantParser] Skipping status-like text block:",t):(h.push(t),a&&e("[useAIAssistantParser] Data block is text, adding to text blocks"))}}const d=h.filter(e=>e.trim().length>0).join("\n");return a&&(e("[useAIAssistantParser] Text blocks collected:",h.length),e("[useAIAssistantParser] Filtered text blocks:",h.filter(e=>e.trim().length>0).length),e("[useAIAssistantParser] Final combined text length:",d.length),e("[useAIAssistantParser] Final combined text:",d)),l&&0!==n.length?void 0!==o?(a&&e("[useAIAssistantParser] Returning last valid JSON"),{data:o,rawText:d,isJson:!0}):d?(a&&e("[useAIAssistantParser] No valid JSON found, returning as text"),{data:void 0,rawText:d,isJson:!1}):{data:void 0,rawText:n.join("\n"),isJson:!1,error:"Could not parse any data blocks as valid JSON"}:{data:void 0,rawText:"",isJson:!1,error:"No data found in SSE response. The server may have returned only status messages without actual data."}}catch(o){return a&&t("[useAIAssistantParser] SSE parsing error:",o instanceof Error?o:void 0),{data:void 0,rawText:r,isJson:!1,error:o instanceof Error?o.message:"Failed to parse SSE response"}}},[])}})(),{warn:c}=Q(),u=v.useRef(e.conversationId||crypto.randomUUID());return{response:t,isLoading:n,error:o,sendMessage:v.useCallback(async(t,n)=>{var o;r(""),a(null),i(!0);const h=new AbortController;s.current=h;let d=e.endpoint||"http://localhost:7071/api/EventAssistant";d.endsWith("/")&&(d=d.slice(0,-1));try{let i=t.input;if(t.history&&t.history.length>0){i=`${t.history.join("\n\n")}\n\n${t.input}`}const a={input:i,instructions:t.instructions,mode:void 0,conversationId:u.current,mcpServers:t.mcpServers||e.mcpServers},s=await fetch(d,{method:"POST",headers:{"Content-Type":"application/json",Accept:"text/event-stream",...e.requestHeaders&&Object.keys(e.requestHeaders).length>0?e.requestHeaders:{}},body:JSON.stringify(a),signal:h.signal});if(!s.ok){let e="";try{const t=await s.text();t&&(e=` - ${t}`)}catch{}throw new Error(`HTTP error! status: ${s.status}${e}`)}const p=null==(o=s.body)?void 0:o.getReader();if(!p)throw new Error("No response body");const f=new TextDecoder("utf-8");let g=!1,m="";for(;!g;){const{value:e,done:t}=await p.read();if(g=t,e){m+=f.decode(e,{stream:!0})}}const y=l(m),x=y.rawText||"";return r(x),n&&n(x),y.error&&c("[useAIAssistant] Parser warning:",y.error),x}catch(p){let e="Error occurred while processing your request.";throw p instanceof Error&&(e="AbortError"===p.name?"Request was cancelled.":p.message.includes("Rate limit")||p.message.includes("429")?"Rate limit exceeded. Please wait a moment before sending another message.":p.message.includes("quota")?"API quota exceeded. Please try again later.":p.message),a(e),new Error(e)}finally{i(!1)}},[e.endpoint,e.mcpServers,l]),cancelRequest:v.useCallback(()=>{s.current&&s.current.abort()},[]),resetConversation:v.useCallback(()=>{u.current=crypto.randomUUID(),r(""),a(null)},[]),conversationId:u.current}},ne=()=>{const e=q.useCallback((e,t)=>`${e}${t}`,[]),t=q.useCallback(e=>{if(!e)return!1;try{return!!new URL(e)}catch(t){return!1}},[]),r=e=>"/"===e.charAt(0)&&"/"===e.charAt(1)?e.substring(1,e.length):e,n=q.useCallback(e=>{const t=new RegExp(/^[{]?[0-9a-fA-F]{8}-([0-9a-fA-F]{4}-){3}[0-9a-fA-F]{12}[}]?$/);return!!e&&!0===t.test(e)},[]),i=q.useCallback(e=>{if(!e)return"";const t=e.split("/");return t[t.length-1]},[]),o=q.useCallback(e=>{const t=window.location.hostname,r=`https://${t}`;if(e.indexOf(`${r}/sites/`)>-1||e.indexOf(`${r}/teams/`)>-1){const n=e.split(t)[1].split("/")[2];let i=`https://${t}/sites/${n}`;return e.indexOf(`${r}/teams/`)>-1&&(i=`https://${t}/teams/${n}`),i}return r},[]),a=q.useCallback(e=>{let t=e.split(window.location.hostname)[1];return t=r(t),t},[]),s=q.useCallback(e=>encodeURIComponent(e.replace(/[%]/g,"%25")).replace(/[']/g,"%27%27").replace(/[&]/g,"%26").replace(/[#]/g,"%23").replace(/[?]/g,"%3F").replace(/[/]/g,"%2F").replace(/[+]/g,"%2B"),[]),l=q.useCallback(e=>null!=e&&(Object.prototype.hasOwnProperty.call(e,"extraSmall")||Object.prototype.hasOwnProperty.call(e,"small")||Object.prototype.hasOwnProperty.call(e,"medium")||Object.prototype.hasOwnProperty.call(e,"large")||Object.prototype.hasOwnProperty.call(e,"extraLarge")),[]),c=q.useCallback((e,t)=>e[t.toString().toLowerCase()],[]),u=q.useCallback(e=>e>=J.XXXLarge?"XXXLarge":e>=J.ExtraExtraLarge?"ExtraExtraLarge":e>=J.ExtraLarge?"ExtraLarge":e>=Number(J.Large)?"Large":e>=Number(J.Medium)?"Medium":e>=Number(J.Small)?"Small":"ExtraSmall",[]),h=q.useCallback((e,t)=>{const r=u(t),n={ExtraSmall:"xs",Small:"s",Medium:"m",Large:"l",ExtraLarge:"xl",ExtraExtraLarge:"xxl"};let i=e;return l(e)&&(i=c(e,r??"Medium")||n[r]),i},[u,l,c]),d=q.useCallback((e,t,r)=>{if(!e)return"none";if("string"==typeof e&&(/^\d+px$/.test(e)||/^\d+%$/.test(e)))return e;const n=r,i={padding:"spacingHorizontal",vertical:"spacingVertical",horizontal:"spacingHorizontal"};switch(h(e,t)){case"none":return w.tokens[`${i[n]}None`];case"xxs":return w.tokens[`${i[n]}XXS`];case"xs":return w.tokens[`${i[n]}XS`];case"sNudge":return w.tokens[`${i[n]}SNudge`];case"s":return w.tokens[`${i[n]}S`];case"mNudge":return w.tokens[`${i[n]}MNudge`];case"m":default:return w.tokens[`${i[n]}M`];case"l":return w.tokens[`${i[n]}L`];case"xl":return w.tokens[`${i[n]}XL`];case"xxl":return w.tokens[`${i[n]}XXL`];case"xxxl":return w.tokens[`${i[n]}XXXL`]}},[h]),p=q.useCallback((e,t,r)=>{const{verticalSpacing:n,horizontalSpacing:i,paddingLeft:o,paddingRight:a,paddingBottom:s,background:l,width:c,maxWidth:u,height:h,maxHeight:p,marginLeft:f,marginRight:g,marginTop:m,marginBottom:y,paddingTop:x,padding:b,margin:v,styles:C}=e;let w=d(x,t,"padding"),k=d(o,t,"padding"),S=d(a,t,"padding"),_=d(s,t,"padding");const T=d(b,t,"padding");let A=d(f,t,"padding"),P=d(g,t,"padding"),E=d(m,t,"padding"),M=d(y,t,"padding");const I=d(v,t,"padding");T&&(w="none"===w?T:w,k="none"===k?T:k,S="none"===S?T:S,_="none"===_?T:_),I&&(A="none"===A?I:A,P="none"===P?I:P,E="none"===E?I:E,M="none"===M?I:M);const B=`${d(n,t,"vertical")} ${d(i,t,"horizontal")}`,{padding:L,margin:j,paddingTop:N,paddingLeft:D,paddingRight:O,paddingBottom:F,marginTop:R,marginLeft:$,marginRight:z,marginBottom:V,...W}=C??{};return{...W,gap:B,paddingTop:w,paddingLeft:k,paddingRight:S,paddingBottom:_,marginLeft:A,marginRight:P,marginTop:E,marginBottom:M,background:l,width:c??void 0,height:h??void 0,maxWidth:u??void 0,maxHeight:p??void 0,overflow:"auto"}},[d]),f=q.useCallback((e,t)=>{const r=u(t);let n=e;return l(e)&&(n=c(e,r??"Medium")||""),n},[u,l,c]);return{getCacheKey:e,validateUrl:t,trimBeginDoubleSlash:r,isValidGUID:n,getPageNameFromUrl:i,getSPSiteAbsoluteUrl:o,getFileServerRelativeUrlFromAbsoluteUrl:a,encodeRestUrl:s,getSpacing:d,getCurrentDevice:u,getBaseStyles:p,getLayoutBreakPoint:f}};function ie(e){return function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},r=t.width?String(t.width):e.defaultWidth;return e.formats[r]||e.formats[e.defaultWidth]}}function oe(e){return function(t,r){var n;if("formatting"===(null!=r&&r.context?String(r.context):"standalone")&&e.formattingValues){var i=e.defaultFormattingWidth||e.defaultWidth,o=null!=r&&r.width?String(r.width):i;n=e.formattingValues[o]||e.formattingValues[i]}else{var a=e.defaultWidth,s=null!=r&&r.width?String(r.width):e.defaultWidth;n=e.values[s]||e.values[a]}return n[e.argumentCallback?e.argumentCallback(t):t]}}function ae(e){return function(t){var r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=r.width,i=n&&e.matchPatterns[n]||e.matchPatterns[e.defaultMatchWidth],o=t.match(i);if(!o)return null;var a,s=o[0],l=n&&e.parsePatterns[n]||e.parsePatterns[e.defaultParseWidth],c=Array.isArray(l)?function(e,t){for(var r=0;r<e.length;r++)if(t(e[r]))return r;return}(l,function(e){return e.test(s)}):function(e,t){for(var r in e)if(e.hasOwnProperty(r)&&t(e[r]))return r;return}(l,function(e){return e.test(s)});return a=e.valueCallback?e.valueCallback(c):c,{value:a=r.valueCallback?r.valueCallback(a):a,rest:t.slice(s.length)}}}function se(e){return function(t){var r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=t.match(e.matchPattern);if(!n)return null;var i=n[0],o=t.match(e.parsePattern);if(!o)return null;var a=e.valueCallback?e.valueCallback(o[0]):o[0];return{value:a=r.valueCallback?r.valueCallback(a):a,rest:t.slice(i.length)}}}function le(e){return(le="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function ce(e,t){if(t.length<e)throw new TypeError(e+" argument"+(e>1?"s":"")+" required, but only "+t.length+" present")}var ue={};function he(e,t){var r,n,i,o,a,s,l,c;ce(1,arguments);var u=ue,h=function(e){if(null===e||!0===e||!1===e)return NaN;var t=Number(e);return isNaN(t)?t:t<0?Math.ceil(t):Math.floor(t)}(null!==(r=null!==(n=null!==(i=null!==(o=null==t?void 0:t.weekStartsOn)&&void 0!==o?o:null==t||null===(a=t.locale)||void 0===a||null===(s=a.options)||void 0===s?void 0:s.weekStartsOn)&&void 0!==i?i:u.weekStartsOn)&&void 0!==n?n:null===(l=u.locale)||void 0===l||null===(c=l.options)||void 0===c?void 0:c.weekStartsOn)&&void 0!==r?r:0);if(!(h>=0&&h<=6))throw new RangeError("weekStartsOn must be between 0 and 6 inclusively");var d=function(e){ce(1,arguments);var t=Object.prototype.toString.call(e);return e instanceof Date||"object"===le(e)&&"[object Date]"===t?new Date(e.getTime()):"number"==typeof e||"[object Number]"===t?new Date(e):("string"!=typeof e&&"[object String]"!==t||"undefined"==typeof console||(console.warn("Starting with v2.0.0-beta.1 date-fns doesn't accept strings as date arguments. Please use `parseISO` to parse strings. See: https://github.com/date-fns/date-fns/blob/master/docs/upgradeGuide.md#string-arguments"),console.warn((new Error).stack)),new Date(NaN))}(e),p=d.getUTCDay(),f=(p<h?7:0)+p-h;return d.setUTCDate(d.getUTCDate()-f),d.setUTCHours(0,0,0,0),d}var de={lessThanXSeconds:{one:"less than a second",other:"less than {{count}} seconds"},xSeconds:{one:"1 second",other:"{{count}} seconds"},halfAMinute:"half a minute",lessThanXMinutes:{one:"less than a minute",other:"less than {{count}} minutes"},xMinutes:{one:"1 minute",other:"{{count}} minutes"},aboutXHours:{one:"about 1 hour",other:"about {{count}} hours"},xHours:{one:"1 hour",other:"{{count}} hours"},xDays:{one:"1 day",other:"{{count}} days"},aboutXWeeks:{one:"about 1 week",other:"about {{count}} weeks"},xWeeks:{one:"1 week",other:"{{count}} weeks"},aboutXMonths:{one:"about 1 month",other:"about {{count}} months"},xMonths:{one:"1 month",other:"{{count}} months"},aboutXYears:{one:"about 1 year",other:"about {{count}} years"},xYears:{one:"1 year",other:"{{count}} years"},overXYears:{one:"over 1 year",other:"over {{count}} years"},almostXYears:{one:"almost 1 year",other:"almost {{count}} years"}},pe={date:ie({formats:{full:"EEEE, MMMM do, y",long:"MMMM do, y",medium:"MMM d, y",short:"MM/dd/yyyy"},defaultWidth:"full"}),time:ie({formats:{full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},defaultWidth:"full"}),dateTime:ie({formats:{full:"{{date}} 'at' {{time}}",long:"{{date}} 'at' {{time}}",medium:"{{date}}, {{time}}",short:"{{date}}, {{time}}"},defaultWidth:"full"})},fe={lastWeek:"'last' eeee 'at' p",yesterday:"'yesterday at' p",today:"'today at' p",tomorrow:"'tomorrow at' p",nextWeek:"eeee 'at' p",other:"P"},ge={code:"en-US",formatDistance:function(e,t,r){var n,i=de[e];return n="string"==typeof i?i:1===t?i.one:i.other.replace("{{count}}",t.toString()),null!=r&&r.addSuffix?r.comparison&&r.comparison>0?"in "+n:n+" ago":n},formatLong:pe,formatRelative:function(e,t,r,n){return fe[e]},localize:{ordinalNumber:function(e,t){var r=Number(e),n=r%100;if(n>20||n<10)switch(n%10){case 1:return r+"st";case 2:return r+"nd";case 3:return r+"rd"}return r+"th"},era:oe({values:{narrow:["B","A"],abbreviated:["BC","AD"],wide:["Before Christ","Anno Domini"]},defaultWidth:"wide"}),quarter:oe({values:{narrow:["1","2","3","4"],abbreviated:["Q1","Q2","Q3","Q4"],wide:["1st quarter","2nd quarter","3rd quarter","4th quarter"]},defaultWidth:"wide",argumentCallback:function(e){return e-1}}),month:oe({values:{narrow:["J","F","M","A","M","J","J","A","S","O","N","D"],abbreviated:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],wide:["January","February","March","April","May","June","July","August","September","October","November","December"]},defaultWidth:"wide"}),day:oe({values:{narrow:["S","M","T","W","T","F","S"],short:["Su","Mo","Tu","We","Th","Fr","Sa"],abbreviated:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],wide:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"]},defaultWidth:"wide"}),dayPeriod:oe({values:{narrow:{am:"a",pm:"p",midnight:"mi",noon:"n",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},abbreviated:{am:"AM",pm:"PM",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},wide:{am:"a.m.",pm:"p.m.",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"}},defaultWidth:"wide",formattingValues:{narrow:{am:"a",pm:"p",midnight:"mi",noon:"n",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"},abbreviated:{am:"AM",pm:"PM",midnight:"midnight",noon:"noon",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"},wide:{am:"a.m.",pm:"p.m.",midnight:"midnight",noon:"noon",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"}},defaultFormattingWidth:"wide"})},match:{ordinalNumber:se({matchPattern:/^(\d+)(th|st|nd|rd)?/i,parsePattern:/\d+/i,valueCallback:function(e){return parseInt(e,10)}}),era:ae({matchPatterns:{narrow:/^(b|a)/i,abbreviated:/^(b\.?\s?c\.?|b\.?\s?c\.?\s?e\.?|a\.?\s?d\.?|c\.?\s?e\.?)/i,wide:/^(before christ|before common era|anno domini|common era)/i},defaultMatchWidth:"wide",parsePatterns:{any:[/^b/i,/^(a|c)/i]},defaultParseWidth:"any"}),quarter:ae({matchPatterns:{narrow:/^[1234]/i,abbreviated:/^q[1234]/i,wide:/^[1234](th|st|nd|rd)? quarter/i},defaultMatchWidth:"wide",parsePatterns:{any:[/1/i,/2/i,/3/i,/4/i]},defaultParseWidth:"any",valueCallback:function(e){return e+1}}),month:ae({matchPatterns:{narrow:/^[jfmasond]/i,abbreviated:/^(jan|feb|mar|apr|may|jun|jul|aug|sep|oct|nov|dec)/i,wide:/^(january|february|march|april|may|june|july|august|september|october|november|december)/i},defaultMatchWidth:"wide",parsePatterns:{narrow:[/^j/i,/^f/i,/^m/i,/^a/i,/^m/i,/^j/i,/^j/i,/^a/i,/^s/i,/^o/i,/^n/i,/^d/i],any:[/^ja/i,/^f/i,/^mar/i,/^ap/i,/^may/i,/^jun/i,/^jul/i,/^au/i,/^s/i,/^o/i,/^n/i,/^d/i]},defaultParseWidth:"any"}),day:ae({matchPatterns:{narrow:/^[smtwf]/i,short:/^(su|mo|tu|we|th|fr|sa)/i,abbreviated:/^(sun|mon|tue|wed|thu|fri|sat)/i,wide:/^(sunday|monday|tuesday|wednesday|thursday|friday|saturday)/i},defaultMatchWidth:"wide",parsePatterns:{narrow:[/^s/i,/^m/i,/^t/i,/^w/i,/^t/i,/^f/i,/^s/i],any:[/^su/i,/^m/i,/^tu/i,/^w/i,/^th/i,/^f/i,/^sa/i]},defaultParseWidth:"any"}),dayPeriod:ae({matchPatterns:{narrow:/^(a|p|mi|n|(in the|at) (morning|afternoon|evening|night))/i,any:/^([ap]\.?\s?m\.?|midnight|noon|(in the|at) (morning|afternoon|evening|night))/i},defaultMatchWidth:"any",parsePatterns:{any:{am:/^a/i,pm:/^p/i,midnight:/^mi/i,noon:/^no/i,morning:/morning/i,afternoon:/afternoon/i,evening:/evening/i,night:/night/i}},defaultParseWidth:"any"})},options:{weekStartsOn:0,firstWeekContainsDate:1}};function me(e,t,r){ce(2,arguments);var n=he(e,r),i=he(t,r);return n.getTime()===i.getTime()}var ye={lessThanXSeconds:{standalone:{one:"weniger als 1 Sekunde",other:"weniger als {{count}} Sekunden"},withPreposition:{one:"weniger als 1 Sekunde",other:"weniger als {{count}} Sekunden"}},xSeconds:{standalone:{one:"1 Sekunde",other:"{{count}} Sekunden"},withPreposition:{one:"1 Sekunde",other:"{{count}} Sekunden"}},halfAMinute:{standalone:"halbe Minute",withPreposition:"halben Minute"},lessThanXMinutes:{standalone:{one:"weniger als 1 Minute",other:"weniger als {{count}} Minuten"},withPreposition:{one:"weniger als 1 Minute",other:"weniger als {{count}} Minuten"}},xMinutes:{standalone:{one:"1 Minute",other:"{{count}} Minuten"},withPreposition:{one:"1 Minute",other:"{{count}} Minuten"}},aboutXHours:{standalone:{one:"etwa 1 Stunde",other:"etwa {{count}} Stunden"},withPreposition:{one:"etwa 1 Stunde",other:"etwa {{count}} Stunden"}},xHours:{standalone:{one:"1 Stunde",other:"{{count}} Stunden"},withPreposition:{one:"1 Stunde",other:"{{count}} Stunden"}},xDays:{standalone:{one:"1 Tag",other:"{{count}} Tage"},withPreposition:{one:"1 Tag",other:"{{count}} Tagen"}},aboutXWeeks:{standalone:{one:"etwa 1 Woche",other:"etwa {{count}} Wochen"},withPreposition:{one:"etwa 1 Woche",other:"etwa {{count}} Wochen"}},xWeeks:{standalone:{one:"1 Woche",other:"{{count}} Wochen"},withPreposition:{one:"1 Woche",other:"{{count}} Wochen"}},aboutXMonths:{standalone:{one:"etwa 1 Monat",other:"etwa {{count}} Monate"},withPreposition:{one:"etwa 1 Monat",other:"etwa {{count}} Monaten"}},xMonths:{standalone:{one:"1 Monat",other:"{{count}} Monate"},withPreposition:{one:"1 Monat",other:"{{count}} Monaten"}},aboutXYears:{standalone:{one:"etwa 1 Jahr",other:"etwa {{count}} Jahre"},withPreposition:{one:"etwa 1 Jahr",other:"etwa {{count}} Jahren"}},xYears:{standalone:{one:"1 Jahr",other:"{{count}} Jahre"},withPreposition:{one:"1 Jahr",other:"{{count}} Jahren"}},overXYears:{standalone:{one:"mehr als 1 Jahr",other:"mehr als {{count}} Jahre"},withPreposition:{one:"mehr als 1 Jahr",other:"mehr als {{count}} Jahren"}},almostXYears:{standalone:{one:"fast 1 Jahr",other:"fast {{count}} Jahre"},withPreposition:{one:"fast 1 Jahr",other:"fast {{count}} Jahren"}}},xe={date:ie({formats:{full:"EEEE, do MMMM y",long:"do MMMM y",medium:"do MMM y",short:"dd.MM.y"},defaultWidth:"full"}),time:ie({formats:{full:"HH:mm:ss zzzz",long:"HH:mm:ss z",medium:"HH:mm:ss",short:"HH:mm"},defaultWidth:"full"}),dateTime:ie({formats:{full:"{{date}} 'um' {{time}}",long:"{{date}} 'um' {{time}}",medium:"{{date}} {{time}}",short:"{{date}} {{time}}"},defaultWidth:"full"})},be={lastWeek:"'letzten' eeee 'um' p",yesterday:"'gestern um' p",today:"'heute um' p",tomorrow:"'morgen um' p",nextWeek:"eeee 'um' p",other:"P"},ve={narrow:["J","F","M","A","M","J","J","A","S","O","N","D"],abbreviated:["Jan","Feb","Mär","Apr","Mai","Jun","Jul","Aug","Sep","Okt","Nov","Dez"],wide:["Januar","Februar","März","April","Mai","Juni","Juli","August","September","Oktober","November","Dezember"]},Ce={narrow:ve.narrow,abbreviated:["Jan.","Feb.","März","Apr.","Mai","Juni","Juli","Aug.","Sep.","Okt.","Nov.","Dez."],wide:ve.wide},we={code:"de",formatDistance:function(e,t,r){var n,i=null!=r&&r.addSuffix?ye[e].withPreposition:ye[e].standalone;return n="string"==typeof i?i:1===t?i.one:i.other.replace("{{count}}",String(t)),null!=r&&r.addSuffix?r.comparison&&r.comparison>0?"in "+n:"vor "+n:n},formatLong:xe,formatRelative:function(e,t,r,n){return be[e]},localize:{ordinalNumber:function(e){return Number(e)+"."},era:oe({values:{narrow:["v.Chr.","n.Chr."],abbreviated:["v.Chr.","n.Chr."],wide:["vor Christus","nach Christus"]},defaultWidth:"wide"}),quarter:oe({values:{narrow:["1","2","3","4"],abbreviated:["Q1","Q2","Q3","Q4"],wide:["1. Quartal","2. Quartal","3. Quartal","4. Quartal"]},defaultWidth:"wide",argumentCallback:function(e){return e-1}}),month:oe({values:ve,formattingValues:Ce,defaultWidth:"wide"}),day:oe({values:{narrow:["S","M","D","M","D","F","S"],short:["So","Mo","Di","Mi","Do","Fr","Sa"],abbreviated:["So.","Mo.","Di.","Mi.","Do.","Fr.","Sa."],wide:["Sonntag","Montag","Dienstag","Mittwoch","Donnerstag","Freitag","Samstag"]},defaultWidth:"wide"}),dayPeriod:oe({values:{narrow:{am:"vm.",pm:"nm.",midnight:"Mitternacht",noon:"Mittag",morning:"Morgen",afternoon:"Nachm.",evening:"Abend",night:"Nacht"},abbreviated:{am:"vorm.",pm:"nachm.",midnight:"Mitternacht",noon:"Mittag",morning:"Morgen",afternoon:"Nachmittag",evening:"Abend",night:"Nacht"},wide:{am:"vormittags",pm:"nachmittags",midnight:"Mitternacht",noon:"Mittag",morning:"Morgen",afternoon:"Nachmittag",evening:"Abend",night:"Nacht"}},defaultWidth:"wide",formattingValues:{narrow:{am:"vm.",pm:"nm.",midnight:"Mitternacht",noon:"Mittag",morning:"morgens",afternoon:"nachm.",evening:"abends",night:"nachts"},abbreviated:{am:"vorm.",pm:"nachm.",midnight:"Mitternacht",noon:"Mittag",morning:"morgens",afternoon:"nachmittags",evening:"abends",night:"nachts"},wide:{am:"vormittags",pm:"nachmittags",midnight:"Mitternacht",noon:"Mittag",morning:"morgens",afternoon:"nachmittags",evening:"abends",night:"nachts"}},defaultFormattingWidth:"wide"})},match:{ordinalNumber:se({matchPattern:/^(\d+)(\.)?/i,parsePattern:/\d+/i,valueCallback:function(e){return parseInt(e)}}),era:ae({matchPatterns:{narrow:/^(v\.? ?Chr\.?|n\.? ?Chr\.?)/i,abbreviated:/^(v\.? ?Chr\.?|n\.? ?Chr\.?)/i,wide:/^(vor Christus|vor unserer Zeitrechnung|nach Christus|unserer Zeitrechnung)/i},defaultMatchWidth:"wide",parsePatterns:{any:[/^v/i,/^n/i]},defaultParseWidth:"any"}),quarter:ae({matchPatterns:{narrow:/^[1234]/i,abbreviated:/^q[1234]/i,wide:/^[1234](\.)? Quartal/i},defaultMatchWidth:"wide",parsePatterns:{any:[/1/i,/2/i,/3/i,/4/i]},defaultParseWidth:"any",valueCallback:function(e){return e+1}}),month:ae({matchPatterns:{narrow:/^[jfmasond]/i,abbreviated:/^(j[aä]n|feb|mär[z]?|apr|mai|jun[i]?|jul[i]?|aug|sep|okt|nov|dez)\.?/i,wide:/^(januar|februar|märz|april|mai|juni|juli|august|september|oktober|november|dezember)/i},defaultMatchWidth:"wide",parsePatterns:{narrow:[/^j/i,/^f/i,/^m/i,/^a/i,/^m/i,/^j/i,/^j/i,/^a/i,/^s/i,/^o/i,/^n/i,/^d/i],any:[/^j[aä]/i,/^f/i,/^mär/i,/^ap/i,/^mai/i,/^jun/i,/^jul/i,/^au/i,/^s/i,/^o/i,/^n/i,/^d/i]},defaultParseWidth:"any"}),day:ae({matchPatterns:{narrow:/^[smdmf]/i,short:/^(so|mo|di|mi|do|fr|sa)/i,abbreviated:/^(son?|mon?|die?|mit?|don?|fre?|sam?)\.?/i,wide:/^(sonntag|montag|dienstag|mittwoch|donnerstag|freitag|samstag)/i},defaultMatchWidth:"wide",parsePatterns:{any:[/^so/i,/^mo/i,/^di/i,/^mi/i,/^do/i,/^f/i,/^sa/i]},defaultParseWidth:"any"}),dayPeriod:ae({matchPatterns:{narrow:/^(vm\.?|nm\.?|Mitternacht|Mittag|morgens|nachm\.?|abends|nachts)/i,abbreviated:/^(vorm\.?|nachm\.?|Mitternacht|Mittag|morgens|nachm\.?|abends|nachts)/i,wide:/^(vormittags|nachmittags|Mitternacht|Mittag|morgens|nachmittags|abends|nachts)/i},defaultMatchWidth:"wide",parsePatterns:{any:{am:/^v/i,pm:/^n/i,midnight:/^Mitte/i,noon:/^Mitta/i,morning:/morgens/i,afternoon:/nachmittags/i,evening:/abends/i,night:/nachts/i}},defaultParseWidth:"any"})},options:{weekStartsOn:1,firstWeekContainsDate:4}},ke={lessThanXSeconds:{one:"menos de un segundo",other:"menos de {{count}} segundos"},xSeconds:{one:"1 segundo",other:"{{count}} segundos"},halfAMinute:"medio minuto",lessThanXMinutes:{one:"menos de un minuto",other:"menos de {{count}} minutos"},xMinutes:{one:"1 minuto",other:"{{count}} minutos"},aboutXHours:{one:"alrededor de 1 hora",other:"alrededor de {{count}} horas"},xHours:{one:"1 hora",other:"{{count}} horas"},xDays:{one:"1 día",other:"{{count}} días"},aboutXWeeks:{one:"alrededor de 1 semana",other:"alrededor de {{count}} semanas"},xWeeks:{one:"1 semana",other:"{{count}} semanas"},aboutXMonths:{one:"alrededor de 1 mes",other:"alrededor de {{count}} meses"},xMonths:{one:"1 mes",other:"{{count}} meses"},aboutXYears:{one:"alrededor de 1 año",other:"alrededor de {{count}} años"},xYears:{one:"1 año",other:"{{count}} años"},overXYears:{one:"más de 1 año",other:"más de {{count}} años"},almostXYears:{one:"casi 1 año",other:"casi {{count}} años"}},Se={date:ie({formats:{full:"EEEE, d 'de' MMMM 'de' y",long:"d 'de' MMMM 'de' y",medium:"d MMM y",short:"dd/MM/y"},defaultWidth:"full"}),time:ie({formats:{full:"HH:mm:ss zzzz",long:"HH:mm:ss z",medium:"HH:mm:ss",short:"HH:mm"},defaultWidth:"full"}),dateTime:ie({formats:{full:"{{date}} 'a las' {{time}}",long:"{{date}} 'a las' {{time}}",medium:"{{date}}, {{time}}",short:"{{date}}, {{time}}"},defaultWidth:"full"})},_e={lastWeek:"'el' eeee 'pasado a la' p",yesterday:"'ayer a la' p",today:"'hoy a la' p",tomorrow:"'mañana a la' p",nextWeek:"eeee 'a la' p",other:"P"},Te={lastWeek:"'el' eeee 'pasado a las' p",yesterday:"'ayer a las' p",today:"'hoy a las' p",tomorrow:"'mañana a las' p",nextWeek:"eeee 'a las' p",other:"P"},Ae={code:"es",formatDistance:function(e,t,r){var n,i=ke[e];return n="string"==typeof i?i:1===t?i.one:i.other.replace("{{count}}",t.toString()),null!=r&&r.addSuffix?r.comparison&&r.comparison>0?"en "+n:"hace "+n:n},formatLong:Se,formatRelative:function(e,t,r,n){return 1!==t.getUTCHours()?Te[e]:_e[e]},localize:{ordinalNumber:function(e,t){return Number(e)+"º"},era:oe({values:{narrow:["AC","DC"],abbreviated:["AC","DC"],wide:["antes de cristo","después de cristo"]},defaultWidth:"wide"}),quarter:oe({values:{narrow:["1","2","3","4"],abbreviated:["T1","T2","T3","T4"],wide:["1º trimestre","2º trimestre","3º trimestre","4º trimestre"]},defaultWidth:"wide",argumentCallback:function(e){return Number(e)-1}}),month:oe({values:{narrow:["e","f","m","a","m","j","j","a","s","o","n","d"],abbreviated:["ene","feb","mar","abr","may","jun","jul","ago","sep","oct","nov","dic"],wide:["enero","febrero","marzo","abril","mayo","junio","julio","agosto","septiembre","octubre","noviembre","diciembre"]},defaultWidth:"wide"}),day:oe({values:{narrow:["d","l","m","m","j","v","s"],short:["do","lu","ma","mi","ju","vi","sá"],abbreviated:["dom","lun","mar","mié","jue","vie","sáb"],wide:["domingo","lunes","martes","miércoles","jueves","viernes","sábado"]},defaultWidth:"wide"}),dayPeriod:oe({values:{narrow:{am:"a",pm:"p",midnight:"mn",noon:"md",morning:"mañana",afternoon:"tarde",evening:"tarde",night:"noche"},abbreviated:{am:"AM",pm:"PM",midnight:"medianoche",noon:"mediodia",morning:"mañana",afternoon:"tarde",evening:"tarde",night:"noche"},wide:{am:"a.m.",pm:"p.m.",midnight:"medianoche",noon:"mediodia",morning:"mañana",afternoon:"tarde",evening:"tarde",night:"noche"}},defaultWidth:"wide",formattingValues:{narrow:{am:"a",pm:"p",midnight:"mn",noon:"md",morning:"de la mañana",afternoon:"de la tarde",evening:"de la tarde",night:"de la noche"},abbreviated:{am:"AM",pm:"PM",midnight:"medianoche",noon:"mediodia",morning:"de la mañana",afternoon:"de la tarde",evening:"de la tarde",night:"de la noche"},wide:{am:"a.m.",pm:"p.m.",midnight:"medianoche",noon:"mediodia",morning:"de la mañana",afternoon:"de la tarde",evening:"de la tarde",night:"de la noche"}},defaultFormattingWidth:"wide"})},match:{ordinalNumber:se({matchPattern:/^(\d+)(º)?/i,parsePattern:/\d+/i,valueCallback:function(e){return parseInt(e,10)}}),era:ae({matchPatterns:{narrow:/^(ac|dc|a|d)/i,abbreviated:/^(a\.?\s?c\.?|a\.?\s?e\.?\s?c\.?|d\.?\s?c\.?|e\.?\s?c\.?)/i,wide:/^(antes de cristo|antes de la era com[uú]n|despu[eé]s de cristo|era com[uú]n)/i},defaultMatchWidth:"wide",parsePatterns:{any:[/^ac/i,/^dc/i],wide:[/^(antes de cristo|antes de la era com[uú]n)/i,/^(despu[eé]s de cristo|era com[uú]n)/i]},defaultParseWidth:"any"}),quarter:ae({matchPatterns:{narrow:/^[1234]/i,abbreviated:/^T[1234]/i,wide:/^[1234](º)? trimestre/i},defaultMatchWidth:"wide",parsePatterns:{any:[/1/i,/2/i,/3/i,/4/i]},defaultParseWidth:"any",valueCallback:function(e){return e+1}}),month:ae({matchPatterns:{narrow:/^[efmajsond]/i,abbreviated:/^(ene|feb|mar|abr|may|jun|jul|ago|sep|oct|nov|dic)/i,wide:/^(enero|febrero|marzo|abril|mayo|junio|julio|agosto|septiembre|octubre|noviembre|diciembre)/i},defaultMatchWidth:"wide",parsePatterns:{narrow:[/^e/i,/^f/i,/^m/i,/^a/i,/^m/i,/^j/i,/^j/i,/^a/i,/^s/i,/^o/i,/^n/i,/^d/i],any:[/^en/i,/^feb/i,/^mar/i,/^abr/i,/^may/i,/^jun/i,/^jul/i,/^ago/i,/^sep/i,/^oct/i,/^nov/i,/^dic/i]},defaultParseWidth:"any"}),day:ae({matchPatterns:{narrow:/^[dlmjvs]/i,short:/^(do|lu|ma|mi|ju|vi|s[áa])/i,abbreviated:/^(dom|lun|mar|mi[ée]|jue|vie|s[áa]b)/i,wide:/^(domingo|lunes|martes|mi[ée]rcoles|jueves|viernes|s[áa]bado)/i},defaultMatchWidth:"wide",parsePatterns:{narrow:[/^d/i,/^l/i,/^m/i,/^m/i,/^j/i,/^v/i,/^s/i],any:[/^do/i,/^lu/i,/^ma/i,/^mi/i,/^ju/i,/^vi/i,/^sa/i]},defaultParseWidth:"any"}),dayPeriod:ae({matchPatterns:{narrow:/^(a|p|mn|md|(de la|a las) (mañana|tarde|noche))/i,any:/^([ap]\.?\s?m\.?|medianoche|mediodia|(de la|a las) (mañana|tarde|noche))/i},defaultMatchWidth:"any",parsePatterns:{any:{am:/^a/i,pm:/^p/i,midnight:/^mn/i,noon:/^md/i,morning:/mañana/i,afternoon:/tarde/i,evening:/tarde/i,night:/noche/i}},defaultParseWidth:"any"})},options:{weekStartsOn:1,firstWeekContainsDate:1}},Pe={lessThanXSeconds:{one:"moins d’une seconde",other:"moins de {{count}} secondes"},xSeconds:{one:"1 seconde",other:"{{count}} secondes"},halfAMinute:"30 secondes",lessThanXMinutes:{one:"moins d’une minute",other:"moins de {{count}} minutes"},xMinutes:{one:"1 minute",other:"{{count}} minutes"},aboutXHours:{one:"environ 1 heure",other:"environ {{count}} heures"},xHours:{one:"1 heure",other:"{{count}} heures"},xDays:{one:"1 jour",other:"{{count}} jours"},aboutXWeeks:{one:"environ 1 semaine",other:"environ {{count}} semaines"},xWeeks:{one:"1 semaine",other:"{{count}} semaines"},aboutXMonths:{one:"environ 1 mois",other:"environ {{count}} mois"},xMonths:{one:"1 mois",other:"{{count}} mois"},aboutXYears:{one:"environ 1 an",other:"environ {{count}} ans"},xYears:{one:"1 an",other:"{{count}} ans"},overXYears:{one:"plus d’un an",other:"plus de {{count}} ans"},almostXYears:{one:"presqu’un an",other:"presque {{count}} ans"}},Ee={date:ie({formats:{full:"EEEE d MMMM y",long:"d MMMM y",medium:"d MMM y",short:"dd/MM/y"},defaultWidth:"full"}),time:ie({formats:{full:"HH:mm:ss zzzz",long:"HH:mm:ss z",medium:"HH:mm:ss",short:"HH:mm"},defaultWidth:"full"}),dateTime:ie({formats:{full:"{{date}} 'à' {{time}}",long:"{{date}} 'à' {{time}}",medium:"{{date}}, {{time}}",short:"{{date}}, {{time}}"},defaultWidth:"full"})},Me={lastWeek:"eeee 'dernier à' p",yesterday:"'hier à' p",today:"'aujourd’hui à' p",tomorrow:"'demain à' p'",nextWeek:"eeee 'prochain à' p",other:"P"},Ie={code:"fr",formatDistance:function(e,t,r){var n,i=Pe[e];return n="string"==typeof i?i:1===t?i.one:i.other.replace("{{count}}",String(t)),null!=r&&r.addSuffix?r.comparison&&r.comparison>0?"dans "+n:"il y a "+n:n},formatLong:Ee,formatRelative:function(e,t,r,n){return Me[e]},localize:{ordinalNumber:function(e,t){var r=Number(e),n=null==t?void 0:t.unit;if(0===r)return"0";return r+(1===r?n&&["year","week","hour","minute","second"].includes(n)?"ère":"er":"ème")},era:oe({values:{narrow:["av. J.-C","ap. J.-C"],abbreviated:["av. J.-C","ap. J.-C"],wide:["avant Jésus-Christ","après Jésus-Christ"]},defaultWidth:"wide"}),quarter:oe({values:{narrow:["T1","T2","T3","T4"],abbreviated:["1er trim.","2ème trim.","3ème trim.","4ème trim."],wide:["1er trimestre","2ème trimestre","3ème trimestre","4ème trimestre"]},defaultWidth:"wide",argumentCallback:function(e){return e-1}}),month:oe({values:{narrow:["J","F","M","A","M","J","J","A","S","O","N","D"],abbreviated:["janv.","févr.","mars","avr.","mai","juin","juil.","août","sept.","oct.","nov.","déc."],wide:["janvier","février","mars","avril","mai","juin","juillet","août","septembre","octobre","novembre","décembre"]},defaultWidth:"wide"}),day:oe({values:{narrow:["D","L","M","M","J","V","S"],short:["di","lu","ma","me","je","ve","sa"],abbreviated:["dim.","lun.","mar.","mer.","jeu.","ven.","sam."],wide:["dimanche","lundi","mardi","mercredi","jeudi","vendredi","samedi"]},defaultWidth:"wide"}),dayPeriod:oe({values:{narrow:{am:"AM",pm:"PM",midnight:"minuit",noon:"midi",morning:"mat.",afternoon:"ap.m.",evening:"soir",night:"mat."},abbreviated:{am:"AM",pm:"PM",midnight:"minuit",noon:"midi",morning:"matin",afternoon:"après-midi",evening:"soir",night:"matin"},wide:{am:"AM",pm:"PM",midnight:"minuit",noon:"midi",morning:"du matin",afternoon:"de l’après-midi",evening:"du soir",night:"du matin"}},defaultWidth:"wide"})},match:{ordinalNumber:se({matchPattern:/^(\d+)(ième|ère|ème|er|e)?/i,parsePattern:/\d+/i,valueCallback:function(e){return parseInt(e)}}),era:ae({matchPatterns:{narrow:/^(av\.J\.C|ap\.J\.C|ap\.J\.-C)/i,abbreviated:/^(av\.J\.-C|av\.J-C|apr\.J\.-C|apr\.J-C|ap\.J-C)/i,wide:/^(avant Jésus-Christ|après Jésus-Christ)/i},defaultMatchWidth:"wide",parsePatterns:{any:[/^av/i,/^ap/i]},defaultParseWidth:"any"}),quarter:ae({matchPatterns:{narrow:/^T?[1234]/i,abbreviated:/^[1234](er|ème|e)? trim\.?/i,wide:/^[1234](er|ème|e)? trimestre/i},defaultMatchWidth:"wide",parsePatterns:{any:[/1/i,/2/i,/3/i,/4/i]},defaultParseWidth:"any",valueCallback:function(e){return e+1}}),month:ae({matchPatterns:{narrow:/^[jfmasond]/i,abbreviated:/^(janv|févr|mars|avr|mai|juin|juill|juil|août|sept|oct|nov|déc)\.?/i,wide:/^(janvier|février|mars|avril|mai|juin|juillet|août|septembre|octobre|novembre|décembre)/i},defaultMatchWidth:"wide",parsePatterns:{narrow:[/^j/i,/^f/i,/^m/i,/^a/i,/^m/i,/^j/i,/^j/i,/^a/i,/^s/i,/^o/i,/^n/i,/^d/i],any:[/^ja/i,/^f/i,/^mar/i,/^av/i,/^ma/i,/^juin/i,/^juil/i,/^ao/i,/^s/i,/^o/i,/^n/i,/^d/i]},defaultParseWidth:"any"}),day:ae({matchPatterns:{narrow:/^[lmjvsd]/i,short:/^(di|lu|ma|me|je|ve|sa)/i,abbreviated:/^(dim|lun|mar|mer|jeu|ven|sam)\.?/i,wide:/^(dimanche|lundi|mardi|mercredi|jeudi|vendredi|samedi)/i},defaultMatchWidth:"wide",parsePatterns:{narrow:[/^d/i,/^l/i,/^m/i,/^m/i,/^j/i,/^v/i,/^s/i],any:[/^di/i,/^lu/i,/^ma/i,/^me/i,/^je/i,/^ve/i,/^sa/i]},defaultParseWidth:"any"}),dayPeriod:ae({matchPatterns:{narrow:/^(a|p|minuit|midi|mat\.?|ap\.?m\.?|soir|nuit)/i,any:/^([ap]\.?\s?m\.?|du matin|de l'après[-\s]midi|du soir|de la nuit)/i},defaultMatchWidth:"any",parsePatterns:{any:{am:/^a/i,pm:/^p/i,midnight:/^min/i,noon:/^mid/i,morning:/mat/i,afternoon:/ap/i,evening:/soir/i,night:/nuit/i}},defaultParseWidth:"any"})},options:{weekStartsOn:1,firstWeekContainsDate:4}},Be={lessThanXSeconds:{one:"meno di un secondo",other:"meno di {{count}} secondi"},xSeconds:{one:"un secondo",other:"{{count}} secondi"},halfAMinute:"alcuni secondi",lessThanXMinutes:{one:"meno di un minuto",other:"meno di {{count}} minuti"},xMinutes:{one:"un minuto",other:"{{count}} minuti"},aboutXHours:{one:"circa un'ora",other:"circa {{count}} ore"},xHours:{one:"un'ora",other:"{{count}} ore"},xDays:{one:"un giorno",other:"{{count}} giorni"},aboutXWeeks:{one:"circa una settimana",other:"circa {{count}} settimane"},xWeeks:{one:"una settimana",other:"{{count}} settimane"},aboutXMonths:{one:"circa un mese",other:"circa {{count}} mesi"},xMonths:{one:"un mese",other:"{{count}} mesi"},aboutXYears:{one:"circa un anno",other:"circa {{count}} anni"},xYears:{one:"un anno",other:"{{count}} anni"},overXYears:{one:"più di un anno",other:"più di {{count}} anni"},almostXYears:{one:"quasi un anno",other:"quasi {{count}} anni"}},Le={date:ie({formats:{full:"EEEE d MMMM y",long:"d MMMM y",medium:"d MMM y",short:"dd/MM/y"},defaultWidth:"full"}),time:ie({formats:{full:"HH:mm:ss zzzz",long:"HH:mm:ss z",medium:"HH:mm:ss",short:"HH:mm"},defaultWidth:"full"}),dateTime:ie({formats:{full:"{{date}} {{time}}",long:"{{date}} {{time}}",medium:"{{date}} {{time}}",short:"{{date}} {{time}}"},defaultWidth:"full"})},je=["domenica","lunedì","martedì","mercoledì","giovedì","venerdì","sabato"];function Ne(e){return"'"+je[e]+" alle' p"}var De={lastWeek:function(e,t,r){var n=e.getUTCDay();return me(e,t,r)?Ne(n):function(e){return 0===e?"'domenica scorsa alle' p":"'"+je[e]+" scorso alle' p"}(n)},yesterday:"'ieri alle' p",today:"'oggi alle' p",tomorrow:"'domani alle' p",nextWeek:function(e,t,r){var n=e.getUTCDay();return me(e,t,r)?Ne(n):function(e){return 0===e?"'domenica prossima alle' p":"'"+je[e]+" prossimo alle' p"}(n)},other:"P"},Oe={code:"it",formatDistance:function(e,t,r){var n,i=Be[e];return n="string"==typeof i?i:1===t?i.one:i.other.replace("{{count}}",t.toString()),null!=r&&r.addSuffix?r.comparison&&r.comparison>0?"tra "+n:n+" fa":n},formatLong:Le,formatRelative:function(e,t,r,n){var i=De[e];return"function"==typeof i?i(t,r,n):i},localize:{ordinalNumber:function(e,t){var r=Number(e);return String(r)},era:oe({values:{narrow:["aC","dC"],abbreviated:["a.C.","d.C."],wide:["avanti Cristo","dopo Cristo"]},defaultWidth:"wide"}),quarter:oe({values:{narrow:["1","2","3","4"],abbreviated:["T1","T2","T3","T4"],wide:["1º trimestre","2º trimestre","3º trimestre","4º trimestre"]},defaultWidth:"wide",argumentCallback:function(e){return e-1}}),month:oe({values:{narrow:["G","F","M","A","M","G","L","A","S","O","N","D"],abbreviated:["gen","feb","mar","apr","mag","giu","lug","ago","set","ott","nov","dic"],wide:["gennaio","febbraio","marzo","aprile","maggio","giugno","luglio","agosto","settembre","ottobre","novembre","dicembre"]},defaultWidth:"wide"}),day:oe({values:{narrow:["D","L","M","M","G","V","S"],short:["dom","lun","mar","mer","gio","ven","sab"],abbreviated:["dom","lun","mar","mer","gio","ven","sab"],wide:["domenica","lunedì","martedì","mercoledì","giovedì","venerdì","sabato"]},defaultWidth:"wide"}),dayPeriod:oe({values:{narrow:{am:"m.",pm:"p.",midnight:"mezzanotte",noon:"mezzogiorno",morning:"mattina",afternoon:"pomeriggio",evening:"sera",night:"notte"},abbreviated:{am:"AM",pm:"PM",midnight:"mezzanotte",noon:"mezzogiorno",morning:"mattina",afternoon:"pomeriggio",evening:"sera",night:"notte"},wide:{am:"AM",pm:"PM",midnight:"mezzanotte",noon:"mezzogiorno",morning:"mattina",afternoon:"pomeriggio",evening:"sera",night:"notte"}},defaultWidth:"wide",formattingValues:{narrow:{am:"m.",pm:"p.",midnight:"mezzanotte",noon:"mezzogiorno",morning:"di mattina",afternoon:"del pomeriggio",evening:"di sera",night:"di notte"},abbreviated:{am:"AM",pm:"PM",midnight:"mezzanotte",noon:"mezzogiorno",morning:"di mattina",afternoon:"del pomeriggio",evening:"di sera",night:"di notte"},wide:{am:"AM",pm:"PM",midnight:"mezzanotte",noon:"mezzogiorno",morning:"di mattina",afternoon:"del pomeriggio",evening:"di sera",night:"di notte"}},defaultFormattingWidth:"wide"})},match:{ordinalNumber:se({matchPattern:/^(\d+)(º)?/i,parsePattern:/\d+/i,valueCallback:function(e){return parseInt(e,10)}}),era:ae({matchPatterns:{narrow:/^(aC|dC)/i,abbreviated:/^(a\.?\s?C\.?|a\.?\s?e\.?\s?v\.?|d\.?\s?C\.?|e\.?\s?v\.?)/i,wide:/^(avanti Cristo|avanti Era Volgare|dopo Cristo|Era Volgare)/i},defaultMatchWidth:"wide",parsePatterns:{any:[/^a/i,/^(d|e)/i]},defaultParseWidth:"any"}),quarter:ae({matchPatterns:{narrow:/^[1234]/i,abbreviated:/^t[1234]/i,wide:/^[1234](º)? trimestre/i},defaultMatchWidth:"wide",parsePatterns:{any:[/1/i,/2/i,/3/i,/4/i]},defaultParseWidth:"any",valueCallback:function(e){return e+1}}),month:ae({matchPatterns:{narrow:/^[gfmalsond]/i,abbreviated:/^(gen|feb|mar|apr|mag|giu|lug|ago|set|ott|nov|dic)/i,wide:/^(gennaio|febbraio|marzo|aprile|maggio|giugno|luglio|agosto|settembre|ottobre|novembre|dicembre)/i},defaultMatchWidth:"wide",parsePatterns:{narrow:[/^g/i,/^f/i,/^m/i,/^a/i,/^m/i,/^g/i,/^l/i,/^a/i,/^s/i,/^o/i,/^n/i,/^d/i],any:[/^ge/i,/^f/i,/^mar/i,/^ap/i,/^mag/i,/^gi/i,/^l/i,/^ag/i,/^s/i,/^o/i,/^n/i,/^d/i]},defaultParseWidth:"any"}),day:ae({matchPatterns:{narrow:/^[dlmgvs]/i,short:/^(do|lu|ma|me|gi|ve|sa)/i,abbreviated:/^(dom|lun|mar|mer|gio|ven|sab)/i,wide:/^(domenica|luned[i|ì]|marted[i|ì]|mercoled[i|ì]|gioved[i|ì]|venerd[i|ì]|sabato)/i},defaultMatchWidth:"wide",parsePatterns:{narrow:[/^d/i,/^l/i,/^m/i,/^m/i,/^g/i,/^v/i,/^s/i],any:[/^d/i,/^l/i,/^ma/i,/^me/i,/^g/i,/^v/i,/^s/i]},defaultParseWidth:"any"}),dayPeriod:ae({matchPatterns:{narrow:/^(a|m\.|p|mezzanotte|mezzogiorno|(di|del) (mattina|pomeriggio|sera|notte))/i,any:/^([ap]\.?\s?m\.?|mezzanotte|mezzogiorno|(di|del) (mattina|pomeriggio|sera|notte))/i},defaultMatchWidth:"any",parsePatterns:{any:{am:/^a/i,pm:/^p/i,midnight:/^mezza/i,noon:/^mezzo/i,morning:/mattina/i,afternoon:/pomeriggio/i,evening:/sera/i,night:/notte/i}},defaultParseWidth:"any"})},options:{weekStartsOn:1,firstWeekContainsDate:4}},Fe={lessThanXSeconds:{one:"1秒未満",other:"{{count}}秒未満",oneWithSuffix:"約1秒",otherWithSuffix:"約{{count}}秒"},xSeconds:{one:"1秒",other:"{{count}}秒"},halfAMinute:"30秒",lessThanXMinutes:{one:"1分未満",other:"{{count}}分未満",oneWithSuffix:"約1分",otherWithSuffix:"約{{count}}分"},xMinutes:{one:"1分",other:"{{count}}分"},aboutXHours:{one:"約1時間",other:"約{{count}}時間"},xHours:{one:"1時間",other:"{{count}}時間"},xDays:{one:"1日",other:"{{count}}日"},aboutXWeeks:{one:"約1週間",other:"約{{count}}週間"},xWeeks:{one:"1週間",other:"{{count}}週間"},aboutXMonths:{one:"約1か月",other:"約{{count}}か月"},xMonths:{one:"1か月",other:"{{count}}か月"},aboutXYears:{one:"約1年",other:"約{{count}}年"},xYears:{one:"1年",other:"{{count}}年"},overXYears:{one:"1年以上",other:"{{count}}年以上"},almostXYears:{one:"1年近く",other:"{{count}}年近く"}},Re={date:ie({formats:{full:"y年M月d日EEEE",long:"y年M月d日",medium:"y/MM/dd",short:"y/MM/dd"},defaultWidth:"full"}),time:ie({formats:{full:"H時mm分ss秒 zzzz",long:"H:mm:ss z",medium:"H:mm:ss",short:"H:mm"},defaultWidth:"full"}),dateTime:ie({formats:{full:"{{date}} {{time}}",long:"{{date}} {{time}}",medium:"{{date}} {{time}}",short:"{{date}} {{time}}"},defaultWidth:"full"})},$e={lastWeek:"先週のeeeeのp",yesterday:"昨日のp",today:"今日のp",tomorrow:"明日のp",nextWeek:"翌週のeeeeのp",other:"P"},ze={code:"ja",formatDistance:function(e,t,r){var n;r=r||{};var i=Fe[e];return n="string"==typeof i?i:1===t?r.addSuffix&&i.oneWithSuffix?i.oneWithSuffix:i.one:r.addSuffix&&i.otherWithSuffix?i.otherWithSuffix.replace("{{count}}",String(t)):i.other.replace("{{count}}",String(t)),r.addSuffix?r.comparison&&r.comparison>0?n+"後":n+"前":n},formatLong:Re,formatRelative:function(e,t,r,n){return $e[e]},localize:{ordinalNumber:function(e,t){var r=Number(e);switch(String(null==t?void 0:t.unit)){case"year":return"".concat(r,"年");case"quarter":return"第".concat(r,"四半期");case"month":return"".concat(r,"月");case"week":return"第".concat(r,"週");case"date":return"".concat(r,"日");case"hour":return"".concat(r,"時");case"minute":return"".concat(r,"分");case"second":return"".concat(r,"秒");default:return"".concat(r)}},era:oe({values:{narrow:["BC","AC"],abbreviated:["紀元前","西暦"],wide:["紀元前","西暦"]},defaultWidth:"wide"}),quarter:oe({values:{narrow:["1","2","3","4"],abbreviated:["Q1","Q2","Q3","Q4"],wide:["第1四半期","第2四半期","第3四半期","第4四半期"]},defaultWidth:"wide",argumentCallback:function(e){return Number(e)-1}}),month:oe({values:{narrow:["1","2","3","4","5","6","7","8","9","10","11","12"],abbreviated:["1月","2月","3月","4月","5月","6月","7月","8月","9月","10月","11月","12月"],wide:["1月","2月","3月","4月","5月","6月","7月","8月","9月","10月","11月","12月"]},defaultWidth:"wide"}),day:oe({values:{narrow:["日","月","火","水","木","金","土"],short:["日","月","火","水","木","金","土"],abbreviated:["日","月","火","水","木","金","土"],wide:["日曜日","月曜日","火曜日","水曜日","木曜日","金曜日","土曜日"]},defaultWidth:"wide"}),dayPeriod:oe({values:{narrow:{am:"午前",pm:"午後",midnight:"深夜",noon:"正午",morning:"朝",afternoon:"午後",evening:"夜",night:"深夜"},abbreviated:{am:"午前",pm:"午後",midnight:"深夜",noon:"正午",morning:"朝",afternoon:"午後",evening:"夜",night:"深夜"},wide:{am:"午前",pm:"午後",midnight:"深夜",noon:"正午",morning:"朝",afternoon:"午後",evening:"夜",night:"深夜"}},defaultWidth:"wide",formattingValues:{narrow:{am:"午前",pm:"午後",midnight:"深夜",noon:"正午",morning:"朝",afternoon:"午後",evening:"夜",night:"深夜"},abbreviated:{am:"午前",pm:"午後",midnight:"深夜",noon:"正午",morning:"朝",afternoon:"午後",evening:"夜",night:"深夜"},wide:{am:"午前",pm:"午後",midnight:"深夜",noon:"正午",morning:"朝",afternoon:"午後",evening:"夜",night:"深夜"}},defaultFormattingWidth:"wide"})},match:{ordinalNumber:se({matchPattern:/^第?\d+(年|四半期|月|週|日|時|分|秒)?/i,parsePattern:/\d+/i,valueCallback:function(e){return parseInt(e,10)}}),era:ae({matchPatterns:{narrow:/^(B\.?C\.?|A\.?D\.?)/i,abbreviated:/^(紀元[前後]|西暦)/i,wide:/^(紀元[前後]|西暦)/i},defaultMatchWidth:"wide",parsePatterns:{narrow:[/^B/i,/^A/i],any:[/^(紀元前)/i,/^(西暦|紀元後)/i]},defaultParseWidth:"any"}),quarter:ae({matchPatterns:{narrow:/^[1234]/i,abbreviated:/^Q[1234]/i,wide:/^第[1234一二三四1234]四半期/i},defaultMatchWidth:"wide",parsePatterns:{any:[/(1|一|1)/i,/(2|二|2)/i,/(3|三|3)/i,/(4|四|4)/i]},defaultParseWidth:"any",valueCallback:function(e){return e+1}}),month:ae({matchPatterns:{narrow:/^([123456789]|1[012])/,abbreviated:/^([123456789]|1[012])月/i,wide:/^([123456789]|1[012])月/i},defaultMatchWidth:"wide",parsePatterns:{any:[/^1\D/,/^2/,/^3/,/^4/,/^5/,/^6/,/^7/,/^8/,/^9/,/^10/,/^11/,/^12/]},defaultParseWidth:"any"}),day:ae({matchPatterns:{narrow:/^[日月火水木金土]/,short:/^[日月火水木金土]/,abbreviated:/^[日月火水木金土]/,wide:/^[日月火水木金土]曜日/},defaultMatchWidth:"wide",parsePatterns:{any:[/^日/,/^月/,/^火/,/^水/,/^木/,/^金/,/^土/]},defaultParseWidth:"any"}),dayPeriod:ae({matchPatterns:{any:/^(AM|PM|午前|午後|正午|深夜|真夜中|夜|朝)/i},defaultMatchWidth:"any",parsePatterns:{any:{am:/^(A|午前)/i,pm:/^(P|午後)/i,midnight:/^深夜|真夜中/i,noon:/^正午/i,morning:/^朝/i,afternoon:/^午後/i,evening:/^夜/i,night:/^深夜/i}},defaultParseWidth:"any"})},options:{weekStartsOn:0,firstWeekContainsDate:1}},Ve={lessThanXSeconds:{one:"1초 미만",other:"{{count}}초 미만"},xSeconds:{one:"1초",other:"{{count}}초"},halfAMinute:"30초",lessThanXMinutes:{one:"1분 미만",other:"{{count}}분 미만"},xMinutes:{one:"1분",other:"{{count}}분"},aboutXHours:{one:"약 1시간",other:"약 {{count}}시간"},xHours:{one:"1시간",other:"{{count}}시간"},xDays:{one:"1일",other:"{{count}}일"},aboutXWeeks:{one:"약 1주",other:"약 {{count}}주"},xWeeks:{one:"1주",other:"{{count}}주"},aboutXMonths:{one:"약 1개월",other:"약 {{count}}개월"},xMonths:{one:"1개월",other:"{{count}}개월"},aboutXYears:{one:"약 1년",other:"약 {{count}}년"},xYears:{one:"1년",other:"{{count}}년"},overXYears:{one:"1년 이상",other:"{{count}}년 이상"},almostXYears:{one:"거의 1년",other:"거의 {{count}}년"}},We={date:ie({formats:{full:"y년 M월 d일 EEEE",long:"y년 M월 d일",medium:"y.MM.dd",short:"y.MM.dd"},defaultWidth:"full"}),time:ie({formats:{full:"a H시 mm분 ss초 zzzz",long:"a H:mm:ss z",medium:"HH:mm:ss",short:"HH:mm"},defaultWidth:"full"}),dateTime:ie({formats:{full:"{{date}} {{time}}",long:"{{date}} {{time}}",medium:"{{date}} {{time}}",short:"{{date}} {{time}}"},defaultWidth:"full"})},He={lastWeek:"'지난' eeee p",yesterday:"'어제' p",today:"'오늘' p",tomorrow:"'내일' p",nextWeek:"'다음' eeee p",other:"P"},qe={code:"ko",formatDistance:function(e,t,r){var n,i=Ve[e];return n="string"==typeof i?i:1===t?i.one:i.other.replace("{{count}}",t.toString()),null!=r&&r.addSuffix?r.comparison&&r.comparison>0?n+" 후":n+" 전":n},formatLong:We,formatRelative:function(e,t,r,n){return He[e]},localize:{ordinalNumber:function(e,t){var r=Number(e);switch(String(null==t?void 0:t.unit)){case"minute":case"second":return String(r);case"date":return r+"일";default:return r+"번째"}},era:oe({values:{narrow:["BC","AD"],abbreviated:["BC","AD"],wide:["기원전","서기"]},defaultWidth:"wide"}),quarter:oe({values:{narrow:["1","2","3","4"],abbreviated:["Q1","Q2","Q3","Q4"],wide:["1분기","2분기","3분기","4분기"]},defaultWidth:"wide",argumentCallback:function(e){return e-1}}),month:oe({values:{narrow:["1","2","3","4","5","6","7","8","9","10","11","12"],abbreviated:["1월","2월","3월","4월","5월","6월","7월","8월","9월","10월","11월","12월"],wide:["1월","2월","3월","4월","5월","6월","7월","8월","9월","10월","11월","12월"]},defaultWidth:"wide"}),day:oe({values:{narrow:["일","월","화","수","목","금","토"],short:["일","월","화","수","목","금","토"],abbreviated:["일","월","화","수","목","금","토"],wide:["일요일","월요일","화요일","수요일","목요일","금요일","토요일"]},defaultWidth:"wide"}),dayPeriod:oe({values:{narrow:{am:"오전",pm:"오후",midnight:"자정",noon:"정오",morning:"아침",afternoon:"오후",evening:"저녁",night:"밤"},abbreviated:{am:"오전",pm:"오후",midnight:"자정",noon:"정오",morning:"아침",afternoon:"오후",evening:"저녁",night:"밤"},wide:{am:"오전",pm:"오후",midnight:"자정",noon:"정오",morning:"아침",afternoon:"오후",evening:"저녁",night:"밤"}},defaultWidth:"wide",formattingValues:{narrow:{am:"오전",pm:"오후",midnight:"자정",noon:"정오",morning:"아침",afternoon:"오후",evening:"저녁",night:"밤"},abbreviated:{am:"오전",pm:"오후",midnight:"자정",noon:"정오",morning:"아침",afternoon:"오후",evening:"저녁",night:"밤"},wide:{am:"오전",pm:"오후",midnight:"자정",noon:"정오",morning:"아침",afternoon:"오후",evening:"저녁",night:"밤"}},defaultFormattingWidth:"wide"})},match:{ordinalNumber:se({matchPattern:/^(\d+)(일|번째)?/i,parsePattern:/\d+/i,valueCallback:function(e){return parseInt(e,10)}}),era:ae({matchPatterns:{narrow:/^(b\.?\s?c\.?|b\.?\s?c\.?\s?e\.?|a\.?\s?d\.?|c\.?\s?e\.?)/i,abbreviated:/^(b\.?\s?c\.?|b\.?\s?c\.?\s?e\.?|a\.?\s?d\.?|c\.?\s?e\.?)/i,wide:/^(기원전|서기)/i},defaultMatchWidth:"wide",parsePatterns:{any:[/^(bc|기원전)/i,/^(ad|서기)/i]},defaultParseWidth:"any"}),quarter:ae({matchPatterns:{narrow:/^[1234]/i,abbreviated:/^q[1234]/i,wide:/^[1234]사?분기/i},defaultMatchWidth:"wide",parsePatterns:{any:[/1/i,/2/i,/3/i,/4/i]},defaultParseWidth:"any",valueCallback:function(e){return e+1}}),month:ae({matchPatterns:{narrow:/^(1[012]|[123456789])/,abbreviated:/^(1[012]|[123456789])월/i,wide:/^(1[012]|[123456789])월/i},defaultMatchWidth:"wide",parsePatterns:{any:[/^1월?$/,/^2/,/^3/,/^4/,/^5/,/^6/,/^7/,/^8/,/^9/,/^10/,/^11/,/^12/]},defaultParseWidth:"any"}),day:ae({matchPatterns:{narrow:/^[일월화수목금토]/,short:/^[일월화수목금토]/,abbreviated:/^[일월화수목금토]/,wide:/^[일월화수목금토]요일/},defaultMatchWidth:"wide",parsePatterns:{any:[/^일/,/^월/,/^화/,/^수/,/^목/,/^금/,/^토/]},defaultParseWidth:"any"}),dayPeriod:ae({matchPatterns:{any:/^(am|pm|오전|오후|자정|정오|아침|저녁|밤)/i},defaultMatchWidth:"any",parsePatterns:{any:{am:/^(am|오전)/i,pm:/^(pm|오후)/i,midnight:/^자정/i,noon:/^정오/i,morning:/^아침/i,afternoon:/^오후/i,evening:/^저녁/i,night:/^밤/i}},defaultParseWidth:"any"})},options:{weekStartsOn:0,firstWeekContainsDate:1}},Ue={lessThanXSeconds:{one:"menos de um segundo",other:"menos de {{count}} segundos"},xSeconds:{one:"1 segundo",other:"{{count}} segundos"},halfAMinute:"meio minuto",lessThanXMinutes:{one:"menos de um minuto",other:"menos de {{count}} minutos"},xMinutes:{one:"1 minuto",other:"{{count}} minutos"},aboutXHours:{one:"aproximadamente 1 hora",other:"aproximadamente {{count}} horas"},xHours:{one:"1 hora",other:"{{count}} horas"},xDays:{one:"1 dia",other:"{{count}} dias"},aboutXWeeks:{one:"aproximadamente 1 semana",other:"aproximadamente {{count}} semanas"},xWeeks:{one:"1 semana",other:"{{count}} semanas"},aboutXMonths:{one:"aproximadamente 1 mês",other:"aproximadamente {{count}} meses"},xMonths:{one:"1 mês",other:"{{count}} meses"},aboutXYears:{one:"aproximadamente 1 ano",other:"aproximadamente {{count}} anos"},xYears:{one:"1 ano",other:"{{count}} anos"},overXYears:{one:"mais de 1 ano",other:"mais de {{count}} anos"},almostXYears:{one:"quase 1 ano",other:"quase {{count}} anos"}},Ge={date:ie({formats:{full:"EEEE, d 'de' MMMM 'de' y",long:"d 'de' MMMM 'de' y",medium:"d 'de' MMM 'de' y",short:"dd/MM/y"},defaultWidth:"full"}),time:ie({formats:{full:"HH:mm:ss zzzz",long:"HH:mm:ss z",medium:"HH:mm:ss",short:"HH:mm"},defaultWidth:"full"}),dateTime:ie({formats:{full:"{{date}} 'às' {{time}}",long:"{{date}} 'às' {{time}}",medium:"{{date}}, {{time}}",short:"{{date}}, {{time}}"},defaultWidth:"full"})},Xe={lastWeek:function(e){var t=e.getUTCDay();return"'"+(0===t||6===t?"último":"última")+"' eeee 'às' p"},yesterday:"'ontem às' p",today:"'hoje às' p",tomorrow:"'amanhã às' p",nextWeek:"eeee 'às' p",other:"P"},Je={code:"pt",formatDistance:function(e,t,r){var n,i=Ue[e];return n="string"==typeof i?i:1===t?i.one:i.other.replace("{{count}}",String(t)),null!=r&&r.addSuffix?r.comparison&&r.comparison>0?"daqui a "+n:"há "+n:n},formatLong:Ge,formatRelative:function(e,t,r,n){var i=Xe[e];return"function"==typeof i?i(t):i},localize:{ordinalNumber:function(e,t){return Number(e)+"º"},era:oe({values:{narrow:["aC","dC"],abbreviated:["a.C.","d.C."],wide:["antes de Cristo","depois de Cristo"]},defaultWidth:"wide"}),quarter:oe({values:{narrow:["1","2","3","4"],abbreviated:["T1","T2","T3","T4"],wide:["1º trimestre","2º trimestre","3º trimestre","4º trimestre"]},defaultWidth:"wide",argumentCallback:function(e){return e-1}}),month:oe({values:{narrow:["j","f","m","a","m","j","j","a","s","o","n","d"],abbreviated:["jan","fev","mar","abr","mai","jun","jul","ago","set","out","nov","dez"],wide:["janeiro","fevereiro","março","abril","maio","junho","julho","agosto","setembro","outubro","novembro","dezembro"]},defaultWidth:"wide"}),day:oe({values:{narrow:["d","s","t","q","q","s","s"],short:["dom","seg","ter","qua","qui","sex","sáb"],abbreviated:["dom","seg","ter","qua","qui","sex","sáb"],wide:["domingo","segunda-feira","terça-feira","quarta-feira","quinta-feira","sexta-feira","sábado"]},defaultWidth:"wide"}),dayPeriod:oe({values:{narrow:{am:"AM",pm:"PM",midnight:"meia-noite",noon:"meio-dia",morning:"manhã",afternoon:"tarde",evening:"noite",night:"madrugada"},abbreviated:{am:"AM",pm:"PM",midnight:"meia-noite",noon:"meio-dia",morning:"manhã",afternoon:"tarde",evening:"noite",night:"madrugada"},wide:{am:"AM",pm:"PM",midnight:"meia-noite",noon:"meio-dia",morning:"manhã",afternoon:"tarde",evening:"noite",night:"madrugada"}},defaultWidth:"wide",formattingValues:{narrow:{am:"AM",pm:"PM",midnight:"meia-noite",noon:"meio-dia",morning:"da manhã",afternoon:"da tarde",evening:"da noite",night:"da madrugada"},abbreviated:{am:"AM",pm:"PM",midnight:"meia-noite",noon:"meio-dia",morning:"da manhã",afternoon:"da tarde",evening:"da noite",night:"da madrugada"},wide:{am:"AM",pm:"PM",midnight:"meia-noite",noon:"meio-dia",morning:"da manhã",afternoon:"da tarde",evening:"da noite",night:"da madrugada"}},defaultFormattingWidth:"wide"})},match:{ordinalNumber:se({matchPattern:/^(\d+)(º|ª)?/i,parsePattern:/\d+/i,valueCallback:function(e){return parseInt(e,10)}}),era:ae({matchPatterns:{narrow:/^(ac|dc|a|d)/i,abbreviated:/^(a\.?\s?c\.?|a\.?\s?e\.?\s?c\.?|d\.?\s?c\.?|e\.?\s?c\.?)/i,wide:/^(antes de cristo|antes da era comum|depois de cristo|era comum)/i},defaultMatchWidth:"wide",parsePatterns:{any:[/^ac/i,/^dc/i],wide:[/^(antes de cristo|antes da era comum)/i,/^(depois de cristo|era comum)/i]},defaultParseWidth:"any"}),quarter:ae({matchPatterns:{narrow:/^[1234]/i,abbreviated:/^T[1234]/i,wide:/^[1234](º|ª)? trimestre/i},defaultMatchWidth:"wide",parsePatterns:{any:[/1/i,/2/i,/3/i,/4/i]},defaultParseWidth:"any",valueCallback:function(e){return e+1}}),month:ae({matchPatterns:{narrow:/^[jfmasond]/i,abbreviated:/^(jan|fev|mar|abr|mai|jun|jul|ago|set|out|nov|dez)/i,wide:/^(janeiro|fevereiro|março|abril|maio|junho|julho|agosto|setembro|outubro|novembro|dezembro)/i},defaultMatchWidth:"wide",parsePatterns:{narrow:[/^j/i,/^f/i,/^m/i,/^a/i,/^m/i,/^j/i,/^j/i,/^a/i,/^s/i,/^o/i,/^n/i,/^d/i],any:[/^ja/i,/^f/i,/^mar/i,/^ab/i,/^mai/i,/^jun/i,/^jul/i,/^ag/i,/^s/i,/^o/i,/^n/i,/^d/i]},defaultParseWidth:"any"}),day:ae({matchPatterns:{narrow:/^[dstq]/i,short:/^(dom|seg|ter|qua|qui|sex|s[áa]b)/i,abbreviated:/^(dom|seg|ter|qua|qui|sex|s[áa]b)/i,wide:/^(domingo|segunda-?\s?feira|terça-?\s?feira|quarta-?\s?feira|quinta-?\s?feira|sexta-?\s?feira|s[áa]bado)/i},defaultMatchWidth:"wide",parsePatterns:{narrow:[/^d/i,/^s/i,/^t/i,/^q/i,/^q/i,/^s/i,/^s/i],any:[/^d/i,/^seg/i,/^t/i,/^qua/i,/^qui/i,/^sex/i,/^s[áa]/i]},defaultParseWidth:"any"}),dayPeriod:ae({matchPatterns:{narrow:/^(a|p|meia-?\s?noite|meio-?\s?dia|(da) (manh[ãa]|tarde|noite|madrugada))/i,any:/^([ap]\.?\s?m\.?|meia-?\s?noite|meio-?\s?dia|(da) (manh[ãa]|tarde|noite|madrugada))/i},defaultMatchWidth:"any",parsePatterns:{any:{am:/^a/i,pm:/^p/i,midnight:/^meia/i,noon:/^meio/i,morning:/manh[ãa]/i,afternoon:/tarde/i,evening:/noite/i,night:/madrugada/i}},defaultParseWidth:"any"})},options:{weekStartsOn:1,firstWeekContainsDate:4}},Ye={lessThanXSeconds:{one:"不到 1 秒",other:"不到 {{count}} 秒"},xSeconds:{one:"1 秒",other:"{{count}} 秒"},halfAMinute:"半分钟",lessThanXMinutes:{one:"不到 1 分钟",other:"不到 {{count}} 分钟"},xMinutes:{one:"1 分钟",other:"{{count}} 分钟"},xHours:{one:"1 小时",other:"{{count}} 小时"},aboutXHours:{one:"大约 1 小时",other:"大约 {{count}} 小时"},xDays:{one:"1 天",other:"{{count}} 天"},aboutXWeeks:{one:"大约 1 个星期",other:"大约 {{count}} 个星期"},xWeeks:{one:"1 个星期",other:"{{count}} 个星期"},aboutXMonths:{one:"大约 1 个月",other:"大约 {{count}} 个月"},xMonths:{one:"1 个月",other:"{{count}} 个月"},aboutXYears:{one:"大约 1 年",other:"大约 {{count}} 年"},xYears:{one:"1 年",other:"{{count}} 年"},overXYears:{one:"超过 1 年",other:"超过 {{count}} 年"},almostXYears:{one:"将近 1 年",other:"将近 {{count}} 年"}},Ze={date:ie({formats:{full:"y'年'M'月'd'日' EEEE",long:"y'年'M'月'd'日'",medium:"yyyy-MM-dd",short:"yy-MM-dd"},defaultWidth:"full"}),time:ie({formats:{full:"zzzz a h:mm:ss",long:"z a h:mm:ss",medium:"a h:mm:ss",short:"a h:mm"},defaultWidth:"full"}),dateTime:ie({formats:{full:"{{date}} {{time}}",long:"{{date}} {{time}}",medium:"{{date}} {{time}}",short:"{{date}} {{time}}"},defaultWidth:"full"})};function Ke(e,t,r){var n="eeee p";return me(e,t,r)?n:e.getTime()>t.getTime()?"'下个'"+n:"'上个'"+n}var Qe={lastWeek:Ke,yesterday:"'昨天' p",today:"'今天' p",tomorrow:"'明天' p",nextWeek:Ke,other:"PP p"},et={code:"zh-CN",formatDistance:function(e,t,r){var n,i=Ye[e];return n="string"==typeof i?i:1===t?i.one:i.other.replace("{{count}}",String(t)),null!=r&&r.addSuffix?r.comparison&&r.comparison>0?n+"内":n+"前":n},formatLong:Ze,formatRelative:function(e,t,r,n){var i=Qe[e];return"function"==typeof i?i(t,r,n):i},localize:{ordinalNumber:function(e,t){var r=Number(e);switch(null==t?void 0:t.unit){case"date":return r.toString()+"日";case"hour":return r.toString()+"时";case"minute":return r.toString()+"分";case"second":return r.toString()+"秒";default:return"第 "+r.toString()}},era:oe({values:{narrow:["前","公元"],abbreviated:["前","公元"],wide:["公元前","公元"]},defaultWidth:"wide"}),quarter:oe({values:{narrow:["1","2","3","4"],abbreviated:["第一季","第二季","第三季","第四季"],wide:["第一季度","第二季度","第三季度","第四季度"]},defaultWidth:"wide",argumentCallback:function(e){return e-1}}),month:oe({values:{narrow:["一","二","三","四","五","六","七","八","九","十","十一","十二"],abbreviated:["1月","2月","3月","4月","5月","6月","7月","8月","9月","10月","11月","12月"],wide:["一月","二月","三月","四月","五月","六月","七月","八月","九月","十月","十一月","十二月"]},defaultWidth:"wide"}),day:oe({values:{narrow:["日","一","二","三","四","五","六"],short:["日","一","二","三","四","五","六"],abbreviated:["周日","周一","周二","周三","周四","周五","周六"],wide:["星期日","星期一","星期二","星期三","星期四","星期五","星期六"]},defaultWidth:"wide"}),dayPeriod:oe({values:{narrow:{am:"上",pm:"下",midnight:"凌晨",noon:"午",morning:"早",afternoon:"下午",evening:"晚",night:"夜"},abbreviated:{am:"上午",pm:"下午",midnight:"凌晨",noon:"中午",morning:"早晨",afternoon:"中午",evening:"晚上",night:"夜间"},wide:{am:"上午",pm:"下午",midnight:"凌晨",noon:"中午",morning:"早晨",afternoon:"中午",evening:"晚上",night:"夜间"}},defaultWidth:"wide",formattingValues:{narrow:{am:"上",pm:"下",midnight:"凌晨",noon:"午",morning:"早",afternoon:"下午",evening:"晚",night:"夜"},abbreviated:{am:"上午",pm:"下午",midnight:"凌晨",noon:"中午",morning:"早晨",afternoon:"中午",evening:"晚上",night:"夜间"},wide:{am:"上午",pm:"下午",midnight:"凌晨",noon:"中午",morning:"早晨",afternoon:"中午",evening:"晚上",night:"夜间"}},defaultFormattingWidth:"wide"})},match:{ordinalNumber:se({matchPattern:/^(第\s*)?\d+(日|时|分|秒)?/i,parsePattern:/\d+/i,valueCallback:function(e){return parseInt(e,10)}}),era:ae({matchPatterns:{narrow:/^(前)/i,abbreviated:/^(前)/i,wide:/^(公元前|公元)/i},defaultMatchWidth:"wide",parsePatterns:{any:[/^(前)/i,/^(公元)/i]},defaultParseWidth:"any"}),quarter:ae({matchPatterns:{narrow:/^[1234]/i,abbreviated:/^第[一二三四]刻/i,wide:/^第[一二三四]刻钟/i},defaultMatchWidth:"wide",parsePatterns:{any:[/(1|一)/i,/(2|二)/i,/(3|三)/i,/(4|四)/i]},defaultParseWidth:"any",valueCallback:function(e){return e+1}}),month:ae({matchPatterns:{narrow:/^(一|二|三|四|五|六|七|八|九|十[二一])/i,abbreviated:/^(一|二|三|四|五|六|七|八|九|十[二一]|\d|1[12])月/i,wide:/^(一|二|三|四|五|六|七|八|九|十[二一])月/i},defaultMatchWidth:"wide",parsePatterns:{narrow:[/^一/i,/^二/i,/^三/i,/^四/i,/^五/i,/^六/i,/^七/i,/^八/i,/^九/i,/^十(?!(一|二))/i,/^十一/i,/^十二/i],any:[/^一|1/i,/^二|2/i,/^三|3/i,/^四|4/i,/^五|5/i,/^六|6/i,/^七|7/i,/^八|8/i,/^九|9/i,/^十(?!(一|二))|10/i,/^十一|11/i,/^十二|12/i]},defaultParseWidth:"any"}),day:ae({matchPatterns:{narrow:/^[一二三四五六日]/i,short:/^[一二三四五六日]/i,abbreviated:/^周[一二三四五六日]/i,wide:/^星期[一二三四五六日]/i},defaultMatchWidth:"wide",parsePatterns:{any:[/日/i,/一/i,/二/i,/三/i,/四/i,/五/i,/六/i]},defaultParseWidth:"any"}),dayPeriod:ae({matchPatterns:{any:/^(上午?|下午?|午夜|[中正]午|早上?|下午|晚上?|凌晨|)/i},defaultMatchWidth:"any",parsePatterns:{any:{am:/^上午?/i,pm:/^下午?/i,midnight:/^午夜/i,noon:/^[中正]午/i,morning:/^早上/i,afternoon:/^下午/i,evening:/^晚上?/i,night:/^凌晨/i}},defaultParseWidth:"any"})},options:{weekStartsOn:1,firstWeekContainsDate:4}};const tt={"en-US":ge,"es-ES":Ae,"fr-FR":Ie,"de-DE":we,"it-IT":Oe,"pt-BR":Je,"pt-PT":Je,"ja-JP":ze,"ko-KR":qe,"zh-CN":et},rt=(e,t)=>{const r=t&&tt[t]||ge,{error:n}=Q();return{getFormatRelative:e=>{try{const t="string"==typeof e?k.parseISO(e):e;return k.formatDistanceToNow(t,{addSuffix:!0,locale:r})}catch(t){return n("Error formatting relative time:",t instanceof Error?t:void 0),""}},convertDateToUTC:e=>{try{const t="string"==typeof e?k.parseISO(e):e;return new Date(t.toUTCString())}catch(t){return n("Error converting to UTC:",t instanceof Error?t:void 0),new Date}},formatDate:(e,t="PPpp")=>{try{const n="string"==typeof e?k.parseISO(e):e;return k.format(n,t,{locale:r})}catch(i){return n("Error formatting date:",i instanceof Error?i:void 0),""}},getTimezoneOffset:()=>(new Date).getTimezoneOffset(),convertToTimezone:(r,i)=>{try{const n="string"==typeof r?k.parseISO(r):r,o=i||e||Intl.DateTimeFormat().resolvedOptions().timeZone;return n.toLocaleString(t||"en-US",{timeZone:o})}catch(o){n("Error converting timezone:",o instanceof Error?o:void 0);return("string"==typeof r?new Date(r):r).toString()}}}},nt="production"!==process.env.NODE_ENV;function it(e,t=0){let r=null;return function(...n){const i=this;r&&clearTimeout(r),r=setTimeout(()=>{e.apply(i,n)},t)}}var ot=(e=>(e.HTML="html",e.MARKDOWN="markdown",e.ADAPTIVE_CARD="adaptiveCard",e.PLAIN_TEXT="plainText",e))(ot||{});const at=(e,t,r=!1)=>{const n=t.filter(t=>t.test(e)).length/t.length;return r?1-n:n},st=e=>{var t;if("object"==typeof e&&null!==e){const r=e;if("AdaptiveCard"===r.type||(null==(t=r.$schema)?void 0:t.includes("adaptivecards.io")))return{type:"adaptiveCard",content:e,confidence:1};e=JSON.stringify(e,null,2)}const r=e,n=r.trim();if(!n||n.length<3)return{type:"plainText",content:r,confidence:1};if((e=>{try{const t=JSON.parse(e);return"object"==typeof t&&null!==t}catch{return!1}})(n)&&(e=>{var t;try{const r=JSON.parse(e);return r&&"object"==typeof r&&("AdaptiveCard"===r.type||(null==(t=r.$schema)?void 0:t.includes("adaptivecards.io")))}catch{return!1}})(n))return{type:"adaptiveCard",content:JSON.parse(n),confidence:1};if((e=>{const t=e.trim(),r=/<[^>]+>/.test(t),n=/^<[^>]+>/.test(t),i=(t.match(/<(?!\/)[^>]+>/g)||[]).length;return[/^<!DOCTYPE\s+html/i,/^<html[\s>]/i,/^<\?xml/i,/<(div|span|p|h[1-6]|table|ul|ol|li|a|img|br|hr|strong|em|b|i)[\s>]/i].some(e=>e.test(t))||r&&n&&i>0})(n)){const e=[/^<!DOCTYPE\s+html/i,/^<html[\s>]/i,/<(div|span|p|h[1-6]|table|ul|ol|li)[\s>]/i];return{type:"html",content:r,confidence:Math.max(.7,at(n,e))}}if((e=>{const t=e.trim(),r=[/^#{1,6}\s+.+$/m,/\*\*.*?\*\*/,/\*.*?\*/,/__.*?__/,/_.*?_/,/\[.*?\]\(.*?\)/,/^\s*[-*+]\s+/m,/^\s*\d+\.\s+/m,/`[^`]+`/,/^```/m,/^\|.*\|.*\|$/m,/^>\s+/m,/^\s*---\s*$/m].some(e=>e.test(t)),n=/^<[^>]+>/.test(t);return r&&!n})(n)){const e=[/^#{1,6}\s+.+$/m,/\*\*.*?\*\*/,/\[.*?\]\(.*?\)/,/^\s*[-*+]\s+/m,/`[^`]+`/,/^```/m,/^\|.*\|.*\|$/m];return{type:"markdown",content:r,confidence:Math.max(.6,at(n,e))}}return{type:"plainText",content:r,confidence:.5}},lt=e=>{const{className:t,cardBody:r,cardBodyClassName:n,cardHeader:i,cardHeaderClassName:o,cardHeaderImage:a,cardHeaderAction:s,cardHeaderDescription:l,cardFooterAction:c,cardFooterClassName:u,cardFooterContent:h,cardPreviewImage:d,cardPreviewLogo:p,cardPreviewPosition:f="top"}=e,{cardStyles:g,bodyCardDefaultStyles:m}=(e=>{const{styles:t}=e,{getBaseStyles:r}=ne();return{cardStyles:q.useCallback((n,i)=>({...r(e,n,i),...t}),[r,e,t]),bodyCardDefaultStyles:q.useMemo(()=>({display:"flex",flexDirection:"column",justifyContent:"start",alignItems:"stretch",overflow:"unset"}),[])}})(e),y=q.useRef(null),[x,v]=q.useState(0),[C,k]=q.useState(0);return q.useEffect(()=>{let e;return y.current&&(e=new _.ResizeObserver(e=>{for(const t of e){const{width:e,height:r}=t.contentRect;v(e),k(r)}}),e.observe(y.current)),()=>{e&&e.disconnect()}},[]),b.jsx(b.Fragment,{children:b.jsx("div",{ref:y,children:b.jsxs(w.Card,{className:t,style:g(x,C),...e,children:[d&&"top"===f&&b.jsxs(w.CardPreview,{logo:p,children:[d," "]}),i&&b.jsx(w.CardHeader,{className:o,image:a,header:i,description:l,action:s}),d&&"afterHeader"===f&&b.jsxs(w.CardPreview,{logo:p,children:[d," "]}),r&&b.jsx("div",{className:w.mergeClasses(n),style:m,children:r}),d&&"bottom"===f&&b.jsxs(w.CardPreview,{logo:p,children:[d," "]}),h&&b.jsx(w.CardFooter,{action:c,className:u,children:h})]})})})},ct=e=>{const{cols:t,verticalSpacing:r,horizontalSpacing:n,styles:i,gridItemAutoFlow:o,minItemWidth:a}=e,{getSpacing:s,getCurrentDevice:l,getBaseStyles:c}=ne();return{gridStyles:q.useCallback((u,h)=>{const d=c(e,u,h),p=`${s(r,u,"vertical")} ${s(n,u,"horizontal")}`,f=l(u);let g=`repeat(auto-${o??"fill"}, minmax(min(100%, ${a??250}px), 1fr))`;if(t&&t>0){let e=t??0;switch(f){case"ExtraSmall":e=Math.min(t,1);break;case"Small":e=Math.min(t,2);break;case"Medium":e=Math.min(t,3);break;case"Large":case"ExtraLarge":e=Math.min(t,4);break;case"ExtraExtraLarge":e=Math.min(t,5);break;case"XXXLarge":e=Math.min(t,6);break;default:e=0}g=`repeat(${e}, minmax(auto, 1fr))`}return{...d,display:"grid",gridTemplateColumns:g,gap:p,overflow:"hidden",...i}},[c,e,s,r,n,l,t,i,o,a])}},ut=e=>{const{maxWith:t}=e,{getBaseStyles:r}=ne();return{rootStyles:q.useCallback((n,i)=>({...r(e,n,i),maxWidth:t}),[r,t,e]),layoutGridStyles:T.css({display:"grid",overflow:"hidden"})}},ht={areas:["header header header","sidebar content sidebar","footer footer footer"],columns:"1fr 3fr 1fr",rows:"auto 1fr auto"},dt=e=>{const{verticalSpacing:t,horizontalSpacing:r}=e,{getSpacing:n}=ne();return{spaceStyles:q.useCallback(e=>{if(!e)return{};if(r){return{width:n(r,e,"horizontal")}}if(t){return{height:n(t,e,"vertical")}}return{}},[n,r,t])}},pt=e=>{const{horizontal:t,horizontalAlign:r,verticalAlign:n,verticalFill:i,wrap:o,columnGap:a,RowGap:s}=e,{getBaseStyles:l}=ne();return{stackStyles:q.useCallback((c,u)=>{const h=n||"start",d=t?r:"start",p=t?{flexFlow:o?"row wrap":"row nowrap",height:"100%"}:{height:"100%",maxHeight:"100%"},f=l(e,c,u);return{columnGap:a,rowGap:s,display:"flex",flexDirection:t?"row":"column",alignItems:h,justifyContent:d,...p,height:i?"100%":f.height,...f,...e.styles}},[l,t,r,e,n,i,o])}},ft=e=>{const{children:t,className:r}=e,{stackStyles:n}=pt(e),i=q.useRef(null),[o,a]=q.useState(0),[s,l]=q.useState(0);return q.useEffect(()=>{let e;return i.current&&(e=new _.ResizeObserver(e=>{for(const t of e){const{width:e,height:r}=t.contentRect;a(e),l(r)}}),e.observe(i.current)),()=>{e&&e.disconnect()}},[]),b.jsx(b.Fragment,{children:b.jsx("div",{className:r,style:n(o,s),ref:i,children:t})})},gt=e=>{const{styles:t}=e,{getBaseStyles:r}=ne();return{centerStyles:q.useCallback((n,i)=>({...r(e,n,i),...t,overflow:"hidden",display:"flex",justifyContent:"center",alignItems:"center",width:"100%",height:"100%"}),[r,e,t]),childrenStyles:T.css({justifyContent:"center",textAlign:"center"})}},mt=e=>{const{className:t,children:r}=e,n=q.useRef(null),[i,o]=q.useState(0),[a,s]=q.useState(0),{centerStyles:l}=gt(e);return q.useEffect(()=>{const e=((e,t)=>{let r;return(...n)=>{clearTimeout(r),r=setTimeout(()=>e(...n),t)}})(e=>{for(const t of e){const{width:e,height:r}=t.contentRect;o(e),s(r)}},200),t=new _.ResizeObserver(t=>{e(t)});return n.current&&t.observe(n.current),()=>{t.disconnect()}},[]),b.jsx("div",{id:"center",className:t,style:{...l(i,a),display:"flex",justifyContent:"center",alignItems:"center",height:"100%",width:"100%"},ref:n,children:r})},yt=e=>{const{direction:t="horizontal",resizerSize:r=6}=e,n="horizontal"===t;return{root:T.css({position:"relative",width:"100%",height:"100%"}),pane:e=>{const t=void 0!==e?"number"==typeof e?`${e}px`:e:void 0;return T.css({overflow:"auto",position:"relative",...n?{width:t,height:"100%"}:{height:t,width:"100%"}})},secondaryPane:T.css({flex:1,overflow:"auto",position:"relative",minWidth:0,minHeight:0}),resizer:T.css({flex:"0 0 auto",...n?{width:r,cursor:"col-resize",height:"100%"}:{height:r,cursor:"row-resize",width:"100%"},backgroundColor:w.tokens.colorNeutralStroke1,transition:"background-color 150ms ease",userSelect:"none",zIndex:1}),resizerActive:T.css({backgroundColor:w.tokens.colorBrandStroke1}),resizerGrip:T.css({gap:"2px"}),gripDot:T.css({width:3,height:3,borderRadius:"50%",backgroundColor:w.tokens.colorNeutralForeground3})}},xt={xs:w.tokens.spacingHorizontalXS,s:w.tokens.spacingHorizontalS,m:w.tokens.spacingHorizontalM,l:w.tokens.spacingHorizontalL,xl:w.tokens.spacingHorizontalXL,xxl:w.tokens.spacingHorizontalXXL},bt=v.memo(v.forwardRef(({direction:e="vertical",justifyContent:t="flex-start",alignItems:r="stretch",gap:n,columnGap:i,rowGap:o,margin:a,padding:s,marginTop:l,marginBottom:c,marginLeft:u,marginRight:h,paddingTop:d,paddingBottom:p,paddingLeft:f,paddingRight:g,width:m,height:y,wrap:x=!1,children:v,style:C,className:k,overflow:S,background:_},A)=>{const P=T.css({display:"flex",flexDirection:"horizontal"===e?"row":"column",justifyContent:t,alignItems:r,gap:n&&xt[n]?xt[n]:n,columnGap:i&&xt[i]?xt[i]:i,rowGap:o&&xt[o]?xt[o]:o,margin:a&&xt[a]?xt[a]:a,padding:s&&xt[s]?xt[s]:s,marginTop:l&&xt[l]?xt[l]:l,marginBottom:c&&xt[c]?xt[c]:c,marginLeft:u&&xt[u]?xt[u]:u,marginRight:h&&xt[h]?xt[h]:h,paddingTop:d&&xt[d]?xt[d]:d,paddingBottom:p&&xt[p]?xt[p]:p,paddingLeft:f&&xt[f]?xt[f]:f,paddingRight:g&&xt[g]?xt[g]:g,width:m,height:y,overflow:S,flexWrap:x?"wrap":"nowrap",backgroundColor:_,...C});return b.jsx("div",{ref:A,className:w.mergeClasses(k,P),children:v})})),vt=({anchorPoint:e,isOpen:t,onClose:r,excludeRefs:n,children:i,theme:o})=>{const a=v.useRef(null),[s,l]=v.useState(null);v.useLayoutEffect(()=>{if(t){if(a.current){const t=a.current.getBoundingClientRect();let r=e.left,n=e.top;r+t.width>window.innerWidth&&(r=window.innerWidth-t.width-10),n+t.height>window.innerHeight&&(n=window.innerHeight-t.height-10),l({left:r,top:n})}}else l(null)},[e,t,i]);const c=v.useCallback(e=>{const t=e.target;if(a.current&&!a.current.contains(t)){if(n&&n.some(e=>e.current&&e.current.contains(t)))return;r()}},[r,n]);if(v.useEffect(()=>{if(!t)return;const e=requestAnimationFrame(()=>{document.addEventListener("mousedown",c)}),n=e=>{"Escape"===e.key&&r()};return document.addEventListener("keydown",n),()=>{cancelAnimationFrame(e),document.removeEventListener("mousedown",c),document.removeEventListener("keydown",n)}},[t,c,r]),!t)return null;const u=s||e;return E.createPortal(o?b.jsx(w.FluentProvider,{theme:o,children:b.jsx(w.Card,{ref:a,style:{position:"fixed",zIndex:1e3,top:u.top,left:u.left},children:i})}):b.jsx(w.Card,{ref:a,style:{position:"fixed",zIndex:1e3,top:u.top,left:u.left},children:i}),document.body)},Ct=w.makeStyles({labelContainer:{display:"flex",flexDirection:"row",justifyContent:"flex-start",alignItems:"center",...w.shorthands.gap("6px")},iconStyles:{width:"26px"},item:{paddingLeft:"15px"}}),wt=e=>{const{label:t,icon:r,isRequired:n}=e,i=Ct();return b.jsx(b.Fragment,{children:b.jsxs("div",{className:i.labelContainer,children:[r&&q.isValidElement(r)?r:b.jsx(M.Icon,{icon:r,className:i.iconStyles,width:"20px",height:"20px",color:w.tokens.colorBrandForeground1}),b.jsx(w.Caption1,{style:{color:w.tokens.colorBrandForeground1},children:t}),b.jsx(w.Caption1,{style:{color:w.tokens.colorPaletteRedForeground1},children:n?" *":""})]})})},kt=w.makeStyles({root:{display:"flex",justifyContent:"center",alignItems:"center",height:"100%",width:"100%"},spinner:{width:"100px",height:"100px"}}),St=e=>{const{size:t,label:r,labelPosition:n,style:i,className:o}=e,a=kt();return b.jsx("div",{className:a.root,children:b.jsx(w.Spinner,{style:i,className:w.mergeClasses(a.spinner,o),size:t,label:r,labelPosition:n})})},_t={xs:w.tokens.fontSizeBase200,s:w.tokens.fontSizeBase300,m:w.tokens.fontSizeBase400,l:w.tokens.fontSizeBase500,xl:w.tokens.fontSizeBase600,xxl:w.tokens.fontSizeHero700},Tt={xs:w.tokens.spacingHorizontalXS,s:w.tokens.spacingHorizontalS,m:w.tokens.spacingHorizontalM,l:w.tokens.spacingHorizontalL,xl:w.tokens.spacingHorizontalXL,xxl:w.tokens.spacingHorizontalXXL},At={regular:w.tokens.fontWeightRegular,semibold:w.tokens.fontWeightSemibold,bold:w.tokens.fontWeightBold},Pt=e=>{var t,r;const{onSelected:n,value:i,styles:o,options:a,apparence:s,shape:l,label:c}=e,u=q.useRef(),[h,d]=q.useState(i??a[0]),[p,f]=q.useState({option:[i?null==i?void 0:i.key:null==(t=null==a?void 0:a[0])?void 0:t.key]}),g=q.useRef(null);q.useEffect(()=>{var e;void 0!==i&&(d(i),f({option:[i.key]})),u.current=null==(e=a.find(e=>{var t;return e.key===((null==i?void 0:i.key)??(null==(t=a[0])?void 0:t.key))}))?void 0:e.icon},[i]);const[m,y]=q.useState(!1),x=q.useCallback((e,t)=>{y(t.open)},[]),v=q.useCallback(e=>(null==e?void 0:e.text)??"",[]),C=q.useCallback((e,{name:t,checkedItems:r})=>{var i;if("option"===t){const e=r[0];d(a.find(t=>t.key===e)),f({option:r}),u.current=null==(i=a.find(t=>t.key===e))?void 0:i.icon,n(a.find(t=>t.key===e))}},[a,n]);return b.jsx(b.Fragment,{children:b.jsx(w.Field,{label:c,style:o,ref:g,children:b.jsxs(w.Menu,{open:m,onOpenChange:x,children:[b.jsx(w.MenuTrigger,{disableButtonEnhancement:!0,children:b.jsx(w.MenuButton,{shape:l??"circular",icon:u.current,appearance:s??"secondary",children:v(h)??"No data available"})}),b.jsx(w.MenuPopover,{children:b.jsx(w.MenuList,{onCheckedValueChange:C,checkedValues:p,style:{width:null==(r=g.current)?void 0:r.offsetWidth},children:a.map(e=>b.jsx(w.MenuItemRadio,{name:"option",value:e.key,icon:e.icon,disabled:e.disabled,children:v(e)},e.key))})})]})})})},Et=()=>({styles:{container:T.css({display:"flex",alignItems:"center",alignContent:"center",overflow:"hidden",whiteSpace:"nowrap",padding:"8px",backgroundColor:"transparent"}),breadcrumbItem:T.css({minWidth:"fit-content",padding:0,margin:"0px"}),separator:T.css({marginRight:"8px"})},getStyles:(e,t)=>{const{icon:r}=e;switch(t){case"small":return T.css({fontSize:"12px",padding:"4px",paddingLeft:r?"0px":"4px"});case"medium":default:return T.css({fontSize:"14px",padding:"6px",paddingLeft:r?"0px":"6px"});case"large":return T.css({fontSize:"16px",padding:"8px",paddingLeft:r?"0px":"8px"});case"current":return T.css({fontWeight:w.tokens.fontWeightBold,cursor:"default",display:"-webkit-box","-webkit-line-clamp":"1","-webkit-box-orient":"vertical",overflow:"hidden",textAlign:"start",textOverflow:"ellipsis",wordBreak:"break-word",fontFamily:w.tokens.fontFamilyBase})}}}),Mt=({items:e,theme:t,size:r="medium"})=>{const[n,i]=v.useState(!1),o=v.useRef(null),a=v.useRef(null),[s,l]=v.useState({top:0,left:0,position:"absolute"}),{getStyles:c}=Et();return v.useEffect(()=>{const e=e=>{var t,r;(null==(t=o.current)?void 0:t.contains(e.target))||(null==(r=a.current)?void 0:r.contains(e.target))||!n||i(!1)};return document.addEventListener("mousedown",e),()=>{document.removeEventListener("mousedown",e)}},[n]),b.jsxs(b.Fragment,{children:[b.jsx(w.Button,{ref:o,icon:b.jsx(P.MoreHorizontalRegular,{}),appearance:"transparent",onClick:()=>{var e,t;if(o.current){const r=o.current.getBoundingClientRect(),n=window.innerWidth,s=window.innerHeight,c=(null==(e=a.current)?void 0:e.offsetWidth)||200,u=(null==(t=a.current)?void 0:t.offsetHeight)||100;let h=r.bottom+window.scrollY,d=r.left+window.scrollX;d+c>n&&(d=n-c-10),h+u>s&&(h=r.top+window.scrollY-u),l({top:h,left:d,position:"absolute"}),i(e=>!e)}}}),n&&E.createPortal(t?b.jsx(w.FluentProvider,{theme:t,children:b.jsx(w.Card,{ref:a,style:{...s,zIndex:1e3,padding:"8px",minWidth:"150px"},children:e.map((e,t)=>b.jsx(w.Button,{icon:e.icon?e.icon:null,appearance:"transparent",onClick:()=>{var t;null==(t=e.onClick)||t.call(e),i(!1)},children:b.jsx(w.Text,{className:c(e,r),children:e.label})},`overflow-${t}`))})}):b.jsx(w.Card,{ref:a,style:{...s,zIndex:1e3,padding:"8px",minWidth:"150px"},children:e.map((e,t)=>b.jsx(w.Button,{icon:e.icon?e.icon:null,appearance:"transparent",onClick:()=>{var t;null==(t=e.onClick)||t.call(e),i(!1)},children:b.jsx(w.Text,{className:c(e,r),children:e.label})},`overflow-${t}`))}),document.body)]})},It=({icon:e,hoverIcon:t,imageSrc:r,width:n=24,height:i=24,color:o,hoverColor:a,onClick:s,enabled:l=!0})=>{const c=o||w.tokens.colorBrandBackground,u=a||w.tokens.colorBrandBackgroundHover,h=w.tokens.fontFamilyBase,[d,p]=v.useState(!1),f=v.useCallback(()=>{l&&p(!0)},[l]),g=v.useCallback(()=>{l&&p(!1)},[l]),m=v.useMemo(()=>l&&d&&t?t:e,[d,t,e,l]),y=v.useMemo(()=>({width:n,height:i,color:d?u:c,display:"flex",alignItems:"center",justifyContent:"center",opacity:l?1:.5,fontFamily:h,fontSize:"inherit"}),[n,i,d,u,c,l,h]),x=v.useMemo(()=>({border:"none",background:"none",padding:0,cursor:l?"pointer":"default"}),[l]),C=v.useMemo(()=>({width:n,height:i,objectFit:"contain",opacity:l?1:.5}),[n,i,l]);return b.jsx("button",{onClick:l?s:void 0,onMouseEnter:f,onMouseLeave:g,disabled:!l,style:x,children:r?b.jsx("img",{src:r,alt:"icon",style:C}):v.cloneElement(m,{style:{...m.props.style,...y}})})},Bt=v.memo(It),Lt=()=>({getSpanSlots:q.useCallback((e,t)=>{const r=new Date(e),n=new Date(t),i=2*r.getHours()+(r.getMinutes()>=1?1:0),o=2*n.getHours()+(n.getMinutes()>=1?2:0);return{spanSlots:o-i,startSlot:i,endSlot:o}},[]),generateLightAndHoverColors:q.useCallback((e,t=20,r=10)=>{const n=(e,t,r)=>{const n=t*Math.min(r,100-r)/100,i=t=>{const i=(t+e/30)%12,o=r-n*Math.max(Math.min(i-3,9-i,1),-1);return Math.round(255*o).toString(16).padStart(2,"0")};return`#${i(0)}${i(8)}${i(4)}`},{h:i,s:o,l:a}=(e=>{const t=parseInt(e.slice(1,3),16)/255,r=parseInt(e.slice(3,5),16)/255,n=parseInt(e.slice(5,7),16)/255,i=Math.max(t,r,n),o=Math.min(t,r,n),a=i-o;let s=0,l=0;const c=(i+o)/2;if(0!==a){switch(l=c>.5?a/(2-i-o):a/(i+o),i){case t:s=(r-n)/a+(r<n?6:0);break;case r:s=(n-t)/a+2;break;case n:s=(t-r)/a+4}s/=6}return{h:360*s,s:100*l,l:100*c}})(e);return{lightColor:n(i,o,Math.min(a+t,100)),hoverColor:n(i,o,Math.min(a+r,100))}},[]),getEventColors:q.useCallback(e=>{const t={backgroundColor:w.tokens.colorNeutralBackground3,hoverColor:w.tokens.colorNeutralBackground3Hover};return{"no category":t,meeting:{backgroundColor:w.tokens.colorPaletteBlueBackground2,hoverColor:w.tokens.colorPaletteBlueBorderActive},appointment:{backgroundColor:w.tokens.colorPaletteGreenBackground2,hoverColor:w.tokens.colorPaletteGreenBorderActive},task:{backgroundColor:w.tokens.colorPaletteRedBackground2,hoverColor:w.tokens.colorPaletteRedBorderActive},deadline:{backgroundColor:w.tokens.colorPaletteYellowBackground2,hoverColor:w.tokens.colorPaletteYellowBorderActive},holiday:{backgroundColor:w.tokens.colorPalettePurpleBackground2,hoverColor:w.tokens.colorPalettePurpleBorderActive},celebration:{backgroundColor:w.tokens.colorPaletteDarkOrangeBackground2,hoverColor:w.tokens.colorPaletteDarkOrangeBorderActive},reminder:{backgroundColor:w.tokens.colorPaletteTealBackground2,hoverColor:w.tokens.colorPaletteTealBorderActive},workshop:{backgroundColor:w.tokens.colorPaletteTealBackground2,hoverColor:w.tokens.colorPaletteTealBorderActive},webinar:{backgroundColor:w.tokens.colorPaletteMagentaBackground2,hoverColor:w.tokens.colorPaletteMagentaBorderActive},conference:{backgroundColor:w.tokens.colorPaletteBrownBackground2,hoverColor:w.tokens.colorPaletteBrownBorderActive}}[e.toLowerCase()]||t},[]),generateColor:q.useCallback(e=>{let t=0;for(let n=0;n<e.length;n++)t=e.charCodeAt(n)+((t<<5)-t);const r=(16777215&t).toString(16).toUpperCase();return`#${"00000".substring(0,6-r.length)+r}`},[]),getCalendarColors:q.useCallback(e=>{const t={beige:{backgroundColor:w.tokens.colorPaletteBeigeBackground2,hoverColor:w.tokens.colorPaletteBeigeBorderActive},blue:{backgroundColor:w.tokens.colorPaletteBlueBackground2,hoverColor:w.tokens.colorPaletteBlueBorderActive},brown:{backgroundColor:w.tokens.colorPaletteBrownBackground2,hoverColor:w.tokens.colorPaletteBrownBorderActive},gold:{backgroundColor:w.tokens.colorPaletteGoldBackground2,hoverColor:w.tokens.colorPaletteGoldBorderActive},lavender:{backgroundColor:w.tokens.colorPaletteLavenderBackground2,hoverColor:w.tokens.colorPaletteLavenderBorderActive},magenta:{backgroundColor:w.tokens.colorPaletteMagentaBackground2,hoverColor:w.tokens.colorPaletteMagentaBorderActive},navy:{backgroundColor:w.tokens.colorPaletteNavyBackground2,hoverColor:w.tokens.colorPaletteNavyBorderActive},pink:{backgroundColor:w.tokens.colorPalettePinkBackground2,hoverColor:w.tokens.colorPalettePinkBorderActive},plum:{backgroundColor:w.tokens.colorPalettePlumBackground2,hoverColor:w.tokens.colorPalettePlumBorderActive},purple:{backgroundColor:w.tokens.colorPalettePurpleBackground2,hoverColor:w.tokens.colorPalettePurpleBorderActive},red:{backgroundColor:w.tokens.colorPaletteRedBackground2,hoverColor:w.tokens.colorPaletteRedBorderActive},teal:{backgroundColor:w.tokens.colorPaletteTealBackground2,hoverColor:w.tokens.colorPaletteTealBorderActive},anchor:{backgroundColor:w.tokens.colorPaletteAnchorBackground2,hoverColor:w.tokens.colorPaletteAnchorBorderActive},"dark-red":{backgroundColor:w.tokens.colorPaletteDarkRedBackground2,hoverColor:w.tokens.colorPaletteDarkRedBorderActive},cranberry:{backgroundColor:w.tokens.colorPaletteCranberryBackground2,hoverColor:w.tokens.colorPaletteCranberryBorderActive},pumpkin:{backgroundColor:w.tokens.colorPalettePumpkinBackground2,hoverColor:w.tokens.colorPalettePumpkinBorderActive},peach:{backgroundColor:w.tokens.colorPalettePeachBackground2,hoverColor:w.tokens.colorPalettePeachBorderActive},marigold:{backgroundColor:w.tokens.colorPaletteMarigoldBackground2,hoverColor:w.tokens.colorPaletteMarigoldBorderActive},brass:{backgroundColor:w.tokens.colorPaletteBrassBackground2,hoverColor:w.tokens.colorPaletteBrassBorderActive},forest:{backgroundColor:w.tokens.colorPaletteForestBackground2,hoverColor:w.tokens.colorPaletteForestBorderActive},seafoam:{backgroundColor:w.tokens.colorPaletteSeafoamBackground2,hoverColor:w.tokens.colorPaletteSeafoamBorderActive},"dark-green":{backgroundColor:w.tokens.colorPaletteDarkGreenBackground2,hoverColor:w.tokens.colorPaletteDarkGreenBorderActive},"light-teal":{backgroundColor:w.tokens.colorPaletteLightTealBackground2,hoverColor:w.tokens.colorPaletteLightTealBorderActive},steel:{backgroundColor:w.tokens.colorPaletteSteelBackground2,hoverColor:w.tokens.colorPaletteSteelBorderActive},"royal-blue":{backgroundColor:w.tokens.colorPaletteRoyalBlueBackground2,hoverColor:w.tokens.colorPaletteRoyalBlueBorderActive},cornflower:{backgroundColor:w.tokens.colorPaletteCornflowerBackground2,hoverColor:w.tokens.colorPaletteCornflowerBorderActive},grape:{backgroundColor:w.tokens.colorPaletteGrapeBackground2,hoverColor:w.tokens.colorPaletteGrapeBorderActive},lilac:{backgroundColor:w.tokens.colorPaletteLilacBackground2,hoverColor:w.tokens.colorPaletteLilacBorderActive},mink:{backgroundColor:w.tokens.colorPaletteMinkBackground2,hoverColor:w.tokens.colorPaletteMinkBorderActive},platinum:{backgroundColor:w.tokens.colorPalettePlatinumBackground2,hoverColor:w.tokens.colorPalettePlatinumBorderActive}};return t[e]||t["royal-blue"]},[]),formatDate:q.useCallback((e,t)=>{const r=k.parseISO(e);return k.format(r,t)},[])}),jt={start:"Start",end:"End",location:"Location",attendees:"Attendees",details:"Details"},Nt="32px",Dt=({fieldLabel:e,fieldValue:t,icon:r})=>b.jsxs(ft,{children:[b.jsx(wt,{label:e,icon:r}),b.jsx(ft,{paddingLeft:Nt,children:b.jsx(w.Body1,{children:t})})]}),Ot=e=>{const{event:t,strings:r=jt}=e,{title:n,start:i,end:o,location:a,category:s,attendees:l,weblink:c}=t,{styles:u}={styles:{banner:T.css({display:"flex",justifyContent:"center",alignContent:"center",alignItems:"center",padding:"5px 10px 0px 10px"}),fieldContainer:T.css({paddingLeft:Nt}),title:T.css({lineClamp:2,overflow:"hidden",display:"-webkit-box",WebkitBoxOrient:"vertical",wordBreak:"break-word",WebkitLineClamp:2})}},{formatDate:h}=Lt(),d=h(i,"PPp"),p=h(o,"PPp"),f=w.partitionAvatarGroupItems({items:(null==l?void 0:l.map(e=>e.id))||[]}),g=q.useCallback(e=>(null==l?void 0:l.find(t=>t.id===e))||void 0,[l]),m=q.useCallback(()=>b.jsxs(ft,{children:[b.jsx(wt,{label:r.attendees,icon:"ph:users-three"}),b.jsx(ft,{paddingLeft:Nt,children:b.jsxs(w.AvatarGroup,{layout:"stack",children:[f.inlineItems.map(e=>{var t,r;return b.jsx(w.AvatarGroupItem,{name:null==(t=g(e))?void 0:t.name,image:{src:null==(r=g(e))?void 0:r.imageUrl}},e)}),f.overflowItems&&b.jsx(w.AvatarGroupPopover,{children:f.overflowItems.map(e=>{var t,r;return b.jsx(w.AvatarGroupItem,{name:null==(t=g(e))?void 0:t.name,image:{src:null==(r=g(e))?void 0:r.imageUrl}},e)})})]})})]}),[f,g,r.attendees]);return b.jsx(b.Fragment,{children:b.jsx(lt,{appearance:"subtle",padding:"m",paddingTop:"s",width:"250px",cardBody:b.jsxs(ft,{RowGap:10,children:[b.jsx("div",{className:u.banner,children:b.jsx(w.Subtitle1,{className:u.title,children:n})}),b.jsx(w.Divider,{}),s&&b.jsx(ft,{horizontal:!0,horizontalAlign:"end",width:"100%",children:b.jsx(w.Badge,{appearance:"filled",children:s})}),b.jsx(Dt,{fieldLabel:r.start,fieldValue:d,icon:"mingcute:time-line"}),b.jsx(Dt,{fieldLabel:r.end,fieldValue:p,icon:"mingcute:time-line"}),b.jsx(Dt,{fieldLabel:r.location,fieldValue:a,icon:"mingcute:location-line"}),b.jsx(m,{})]}),cardFooterContent:b.jsx(ft,{horizontal:!0,horizontalAlign:"end",width:"100%",children:b.jsx(w.Button,{appearance:"subtle",onClick:()=>{window.open(c,"_blank")},children:r.details})})})})},Ft=()=>({styles:{calendarWrapper:T.css({padding:"20px",paddingTop:"10px",overflow:"auto",flex:1,display:"grid",gridTemplateColumns:"repeat(7, 1fr)",gridTemplateRows:"auto",gridAutoRows:"minmax(100px, 1fr)",gap:"1px",width:"calc(100% - 40px)"}),header:T.css({display:"flex",justifyContent:"start",gap:"10px",alignItems:"center",padding:"16px"}),dayHeader:T.css({textAlign:"start",padding:"8px",borderBottom:`1px solid ${w.tokens.colorNeutralStroke1}`}),day:T.css({display:"flex",flexDirection:"column",alignItems:"center",justifyContent:"center",border:`1px solid ${w.tokens.colorNeutralStroke1}`,backgroundColor:w.tokens.colorNeutralBackground1,position:"relative"}),otherMonthDay:T.css({color:w.tokens.colorNeutralStroke2,backgroundColor:w.tokens.colorNeutralBackground2}),cardDay:T.css({height:"100%",minHeight:100,borderRadius:0,overflow:"hidden !important",rowGap:5}),cardDayOnHover:T.css({":hover":{backgroundColor:w.tokens.colorNeutralBackground2}}),currentDay:T.css({borderTop:`5px solid ${w.tokens.colorBrandBackground}`}),currentDayLabel:T.css({color:w.tokens.colorBrandBackground,fontWeight:600}),eventCard:T.css({display:"flex",flexDirection:"column",alignItems:"flex-start",zIndex:1}),eventContainer:T.css({display:"flex",flexDirection:"column",overflowY:"auto",paddingTop:"5px",paddingBottom:"5px",paddingLeft:"5px",paddingRight:"5px","::-webkit-scrollbar":{width:"5px",height:"5px"},"::-webkit-scrollbar-track":{background:w.tokens.colorNeutralBackground4,borderRadius:"10px"},"::-webkit-scrollbar-thumb":{background:w.tokens.colorBrandStroke2Hover,borderRadius:"10px"},"::-webkit-scrollbar-thumb:hover":{background:w.tokens.colorNeutralStroke2}}),eventCardWeekView:T.css({backgroundColor:w.tokens.colorBrandBackground,color:w.tokens.colorNeutralForegroundOnBrand,borderRadius:"4px",padding:"4px",margin:"2px",overflow:"hidden",textOverflow:"ellipsis",whiteSpace:"nowrap",height:"100%"}),popoverContent:T.css({padding:0,borderTopWidth:20,borderTopStyle:"solid"}),cardMonthTitle:T.css({display:"-webkit-box","-webkit-line-clamp":"1","-webkit-box-orient":"vertical",textAlign:"start",textOverflow:"ellipsis",paddingLeft:"8px",wordBreak:"break-word",overflow:"hidden"})},applyEventHouverColorClass:(e,t)=>T.css({backgroundColor:e??w.tokens.colorBrandBackground,":hover":{backgroundColor:t??w.tokens.colorBrandBackgroundHover}})}),Rt=e=>{const t=w.useId(),{events:r,date:n,onCardHoverChange:i,columnHeight:o}=e,{styles:a,applyEventHouverColorClass:s}=Ft(),l=q.useRef(null),{getEventColors:c,getCalendarColors:u}=Lt(),h=q.useCallback(e=>{i&&i(!0,e)},[i]),d=q.useCallback(e=>{i&&i(!1,e)},[i]),p=q.useCallback(e=>{var t;null==(t=l.current)||t.setTarget(e)},[l]),f=q.useCallback((e,t,r)=>b.jsx("div",{ref:p,children:b.jsx(lt,{className:w.mergeClasses(a.eventCard,s(r.backgroundColor,r.backgroundColor)),paddingTop:"4px",paddingBottom:"4px",paddingLeft:"8px",paddingRight:"8px",marginTop:0===e?"0px":"5px",cardHeader:b.jsx(w.Caption1,{className:a.cardMonthTitle,children:t.title}),onMouseEnter:()=>h(t.title),onMouseLeave:()=>d(t.title)})},t.id??`card-${e}`),[h,d,s]),g=q.useCallback((e,r,n)=>b.jsxs(w.Popover,{withArrow:!0,mouseLeaveDelay:30,closeOnScroll:!0,closeOnIframeFocus:!0,openOnHover:!0,children:[b.jsx(w.PopoverTrigger,{children:f(r,e,n)}),b.jsx(w.PopoverSurface,{"aria-labelledby":t,className:w.mergeClasses(a.popoverContent),children:b.jsx(Ot,{event:e})})]},r),[f,t,a.popoverContent]);return r&&(null==r?void 0:r.length)?b.jsx("div",{style:{height:o},className:a.eventContainer,children:r.map((e,t)=>{var r;const i=k.startOfDay(new Date(e.start)),o=k.endOfDay(new Date(e.end));if(!k.isWithinInterval(n,{start:i,end:o}))return null;let s;s=e.color?u(e.color):c(e.category);const l=null==(r=e.onRenderInMonthView)?void 0:r.call(e,e),h=e.id??`event-${t}`;return q.isValidElement(l)?q.cloneElement(l,{key:h,className:w.mergeClasses(l.props.className,a.eventCard)}):e.enableOnHouver?g(e,t,s):f(t,e,s)})}):b.jsx(b.Fragment,{children:" "})},$t=e=>{const{day:t,currentMonth:r,events:n,date:i,columnHeight:o,onDayClick:a}=e,{styles:s}=Ft(),l=new Date,[c,u]=q.useState(!1),h=q.useMemo(()=>k.isSameDay(i,l),[i,l]),d=q.useMemo(()=>b.jsx(ft,{horizontal:!0,horizontalAlign:"start",verticalAlign:"center",paddingLeft:"m",paddingRight:"m",children:b.jsxs(w.Body2,{className:s.currentDayLabel,children:[t," ",l.toLocaleString("default",{month:"short"})]})}),[t]),p=q.useCallback(e=>{u(e)},[]);return b.jsx(b.Fragment,{children:b.jsx(lt,{onClick:a?()=>a(i):void 0,className:w.mergeClasses(s.cardDay,r?"":s.otherMonthDay,h?s.currentDay:"",c?"":s.cardDayOnHover),cardHeader:h?d:b.jsx(ft,{horizontal:!0,paddingLeft:"m",paddingRight:"m",children:b.jsx(w.Body2,{children:t})}),paddingTop:"m",paddingBottom:"m",paddingLeft:"0px",paddingRight:"0px",cardBody:b.jsx(Rt,{events:n,date:i,onCardHoverChange:p,columnHeight:o-60})})})},zt=()=>({styles:{container:T.css({display:"flex",flexDirection:"column",width:"calc(100% - 40px)",height:"100vh",overflow:"hidden",padding:"20px"}),header:T.css({display:"flex",justifyContent:"space-between",alignItems:"center",marginBottom:"16px",borderBottom:`1px solid ${w.tokens.colorNeutralStroke1}`}),weekGrid:T.css({display:"grid",gridTemplateColumns:"80px repeat(7, 1fr)",gridTemplateRows:"50px 40px repeat(48, 33px)",height:"fit-content",overflowY:"auto",border:`1px solid ${w.tokens.colorNeutralStroke1}`,maxHeight:"calc(100vh - 100px)",scrollbarWidth:"thin",scrollbarColor:`${w.tokens.colorBrandBackground} ${w.tokens.colorNeutralBackground1}`,"&::-webkit-scrollbar":{width:"8px"},"&::-webkit-scrollbar-track":{background:w.tokens.colorNeutralBackground1},"&::-webkit-scrollbar-thumb":{background:w.tokens.colorBrandBackground,borderRadius:"4px"},"&::-webkit-scrollbar-thumb:hover":{background:w.tokens.colorBrandBackgroundHover}}),blankHeader:T.css({gridColumn:"1",backgroundColor:w.tokens.colorNeutralBackground3,borderBottom:`3px solid ${w.tokens.colorNeutralStroke3}`,position:"sticky",top:0,zIndex:10}),timeColumn:T.css({gridColumn:"1",gridRow:"3 / span 49",display:"flex",flexDirection:"column",backgroundColor:w.tokens.colorNeutralBackground1,borderRight:`1px solid ${w.tokens.colorNeutralStroke1}`}),timeCell:T.css({height:"100%",display:"flex",alignItems:"center",fontSize:"12px",color:w.tokens.colorNeutralForeground3,borderBottom:`1px solid ${w.tokens.colorNeutralStroke1}`,justifyContent:"center"}),fullDayRow:T.css({gridRow:"2",display:"grid",gridTemplateColumns:"80px repeat(7, 1fr)",gap:"0",padding:"0",backgroundColor:w.tokens.colorNeutralBackground2,borderBottom:`3px solid ${w.tokens.colorNeutralStroke2}`}),fullDayLabel:T.css({gridColumn:"1",display:"flex",alignItems:"center",justifyContent:"center",alignContent:"center",color:w.tokens.colorBrandBackground,padding:"5px",borderRight:`1px solid ${w.tokens.colorNeutralStroke1}`,borderBottom:`3px solid ${w.tokens.colorNeutralStroke2}`}),fullDayCell:T.css({borderRight:`1px solid ${w.tokens.colorNeutralStroke1}`,display:"flex",flexDirection:"row",gap:"0px",padding:"4px",borderBottom:`3px solid ${w.tokens.colorNeutralStroke2}`,overflow:"hidden"}),fullDayEvent:T.css({flex:"1 1 auto",minWidth:"24px",height:"24px",padding:"4px 8px",backgroundColor:w.tokens.colorBrandBackground,borderRadius:"4px",overflow:"hidden",display:"flex",alignItems:"center",justifyContent:"center"}),dayHeaderCell:T.css({textAlign:"center",backgroundColor:w.tokens.colorNeutralBackground2,padding:"8px",fontWeight:"bold",borderBottom:`1px solid ${w.tokens.colorNeutralStroke1}`,position:"sticky",top:0,zIndex:10}),todayHeaderCell:T.css({borderTop:`5px solid ${w.tokens.colorBrandBackground}`}),eventCard:T.css({padding:2,alignItems:"center",justifyContent:"center",marginRight:"2px",zIndex:1,position:"absolute",alignContent:"center",overflow:"hidden",":hover":{pointerEvents:"auto",cursor:"pointer"}}),event:T.css({height:"100%",backgroundColor:w.tokens.colorBrandBackground,borderRadius:"4px",textOverflow:"ellipsis",whiteSpace:"nowrap",overflow:"hidden",display:"flex",alignItems:"center",justifyContent:"center",marginRight:"2px",zIndex:1,position:"absolute",alignContent:"center",":hover":{pointerEvents:"auto",cursor:"pointer"}}),dayCell:T.css({borderBottom:`1px solid ${w.tokens.colorNeutralStroke1}`,borderRight:`1px solid ${w.tokens.colorNeutralStroke1}`,position:"relative",overflow:"visible",FlexDirection:"column",gap:"4px"}),currentTimeIndicator:T.css({position:"absolute",left:0,height:"2px",backgroundColor:w.tokens.colorPaletteRedBorderActive,width:"100%",zIndex:1}),currentHalfHourCell:T.css({border:`2px solid ${w.tokens.colorPaletteRedBorderActive}`}),eventTitle:T.css({display:"-webkit-box","-webkit-line-clamp":"1","-webkit-box-orient":"vertical",textAlign:"start",textOverflow:"ellipsis",paddingLeft:"8px",wordBreak:"break-word",overflow:"hidden"}),popoverContent:T.css({padding:0,borderTopWidth:20,borderTopStyle:"solid"})},applyEventHouverColorClass:v.useCallback((e,t)=>T.css({backgroundColor:e??w.tokens.colorBrandBackground,":hover":{backgroundColor:t??w.tokens.colorBrandBackgroundHover}}),[w.tokens.colorBrandBackground,w.tokens.colorBrandBackgroundHover]),appyDynamicStyles:v.useCallback((e,t,r,n)=>T.css({flex:`0 0 calc(100% / ${t})`,height:r*n+"px",left:10*e+"%",width:`calc(${100-10*e}% - 8px)`,margin:4,marginTop:0,marginBottom:0}),[])}),Vt={timeSeparator:" - ",hourSuffix:"H"},Wt=({event:e,colors:t,spanSlots:r,rowHeight:n,eventIndex:i,eventCount:o,strings:a=Vt})=>{const s=w.useId(),{styles:l,applyEventHouverColorClass:c,appyDynamicStyles:u}=zt(),h=q.useRef(null),{formatDate:d}=Lt(),p=q.useMemo(()=>b.jsx("div",{children:b.jsxs(ft,{columnGap:4,verticalAlign:"center",children:[b.jsx(w.Caption1Strong,{className:l.eventTitle,children:e.title}),b.jsxs(ft,{columnGap:4,horizontal:!0,verticalAlign:"center",horizontalAlign:"start",children:[b.jsxs(w.Caption1,{children:[d(e.start,"HH:mm"),a.hourSuffix]}),a.timeSeparator,b.jsxs(w.Caption1,{children:[d(e.end,"HH:mm"),a.hourSuffix]})]})]})}),[e,d,a,l.eventTitle]);return b.jsx(w.Card,{ref:h,className:w.mergeClasses(l.eventCard,c(t.backgroundColor,t.backgroundColor),u(i,o,n,r)),children:e.enableOnHouver?b.jsxs(w.Popover,{withArrow:!0,mouseLeaveDelay:50,closeOnScroll:!0,closeOnIframeFocus:!0,openOnHover:!0,children:[b.jsx(w.PopoverTrigger,{children:p}),b.jsx(w.PopoverSurface,{"aria-labelledby":s,className:w.mergeClasses(l.popoverContent),children:b.jsx(Ot,{event:e})})]}):p},e.id)},Ht=({event:e,eventCount:t,spanSlots:r,rowHeight:n,eventIndex:i,view:o})=>{var a,s;const{styles:l,appyDynamicStyles:c}=zt(),{getEventColors:u,getCalendarColors:h}=Lt(),d=e.color?h(e.color):u(e.category),p="day"===o?null==(a=e.onRenderInDayView)?void 0:a.call(e,e):null==(s=e.onRenderInWeekView)?void 0:s.call(e,e);return q.isValidElement(p)?q.cloneElement(p,{event:e,className:w.mergeClasses(p.props.className,l.eventCard,c(i,t,n,r)),style:{...p.props.style}}):b.jsx(Wt,{event:e,colors:d,spanSlots:r,rowHeight:n,eventIndex:i,eventCount:t},e.id)};for(var qt,Ut=[],Gt=0;Gt<256;++Gt)Ut.push((Gt+256).toString(16).slice(1));var Xt=new Uint8Array(16);function Jt(){if(!qt&&!(qt="undefined"!=typeof crypto&&crypto.getRandomValues&&crypto.getRandomValues.bind(crypto)))throw new Error("crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported");return qt(Xt)}const Yt={randomUUID:"undefined"!=typeof crypto&&crypto.randomUUID&&crypto.randomUUID.bind(crypto)};function Zt(e,t,r){if(Yt.randomUUID&&!e)return Yt.randomUUID();var n=(e=e||{}).random||(e.rng||Jt)();return n[6]=15&n[6]|64,n[8]=63&n[8]|128,function(e,t=0){return(Ut[e[t+0]]+Ut[e[t+1]]+Ut[e[t+2]]+Ut[e[t+3]]+"-"+Ut[e[t+4]]+Ut[e[t+5]]+"-"+Ut[e[t+6]]+Ut[e[t+7]]+"-"+Ut[e[t+8]]+Ut[e[t+9]]+"-"+Ut[e[t+10]]+Ut[e[t+11]]+Ut[e[t+12]]+Ut[e[t+13]]+Ut[e[t+14]]+Ut[e[t+15]]).toLowerCase()}(n)}const Kt=e=>{const t=v.useCallback(e=>e.map(e=>({...e,id:e.id||Zt()})),[]),r=v.useCallback(t=>new Date(new Date(t).toLocaleString(void 0,{timeZone:e})),[e]);return{getMonthCalendar:v.useCallback((e,n,i)=>{const o=t(e),a=new Date(n,i+1,0).getDate(),s={};for(let t=1;t<=a;t++){const e=new Date(n,i,t),r=k.format(e,"yyyy-MM-dd");s[r]=[]}return o.forEach(e=>{const t=r(e.start),n=r(e.end),i=new Date(t);for(;i<=n;){const t=k.format(i,"yyyy-MM-dd");s[t]&&s[t].push(e),i.setDate(i.getDate()+1)}}),s},[r]),getWeekEvents:v.useCallback((e,n)=>{const i=[],o=r(n),a=t(e);for(let t=0;t<7;t++){const e=new Date(o);e.setDate(o.getDate()+t);const n=k.format(e,"yyyy-MM-dd"),s=Array.from({length:48},(e,t)=>({time:`${String(Math.floor(t/2)).padStart(2,"0")}:${t%2==0?"00":"30"}`,events:[]})),l=[];a.forEach(e=>{const t=r(e.start),i=r(e.end);if(e.isFullDay)k.format(t,"yyyy-MM-dd")<=n&&k.format(i,"yyyy-MM-dd")>=n&&l.push(e);else if(k.format(t,"yyyy-MM-dd")<=n&&k.format(i,"yyyy-MM-dd")>=n){const r=new Date(t);for(;r<=i;){if(k.format(r,"yyyy-MM-dd")===n){const t=2*r.getHours()+(r.getMinutes()>=30?1:0);s[t]&&s[t].events.push(e)}r.setMinutes(r.getMinutes()+30)}}}),i.push({date:n,fullDayEvents:l,timeSlots:s})}return i},[r])}},Qt=()=>({styles:{container:T.css({display:"flex",flexDirection:"column",width:"calc(100% - 40px)",height:"100vh",overflow:"hidden",padding:"20px"}),header:T.css({display:"flex",justifyContent:"space-between",alignItems:"center",marginBottom:"16px",borderBottom:`1px solid ${w.tokens.colorNeutralStroke1}`}),dayGrid:T.css({display:"grid",gridTemplateColumns:"80px 1fr",gridTemplateRows:"50px 40px repeat(48, 33px)",height:"calc(100vh - 100px)",overflowY:"auto",border:`1px solid ${w.tokens.colorNeutralStroke1}`,maxHeight:"fit-content",scrollbarWidth:"thin",scrollbarColor:`${w.tokens.colorBrandBackground} ${w.tokens.colorNeutralBackground1}`,"&::-webkit-scrollbar":{width:"8px"},"&::-webkit-scrollbar-track":{background:w.tokens.colorNeutralBackground1},"&::-webkit-scrollbar-thumb":{background:w.tokens.colorBrandBackground,borderRadius:"4px"},"&::-webkit-scrollbar-thumb:hover":{background:w.tokens.colorBrandBackgroundHover}}),blankHeader:T.css({gridColumn:"1",backgroundColor:w.tokens.colorNeutralBackground3,borderBottom:`3px solid ${w.tokens.colorNeutralStroke3}`}),timeColumn:T.css({gridColumn:"1",gridRow:"3 / span 49",display:"flex",flexDirection:"column",backgroundColor:w.tokens.colorNeutralBackground1,borderRight:`1px solid ${w.tokens.colorNeutralStroke1}`}),timeCell:T.css({height:"100%",maxHeight:"32px",minHeight:"32px",display:"flex",alignItems:"center",fontSize:"12px",color:w.tokens.colorNeutralForeground3,borderBottom:`1px solid ${w.tokens.colorNeutralStroke1}`,justifyContent:"center"}),fullDayRow:T.css({gridRow:"2",display:"grid",gridTemplateColumns:"80px 33px",gap:"0",padding:"0",backgroundColor:w.tokens.colorNeutralBackground2,borderBottom:`3px solid ${w.tokens.colorNeutralStroke2}`}),fullDayLabel:T.css({gridColumn:"1",display:"flex",alignItems:"center",justifyContent:"center",alignContent:"center",color:w.tokens.colorBrandBackground,padding:"5px",borderRight:`1px solid ${w.tokens.colorNeutralStroke1}`,borderBottom:`3px solid ${w.tokens.colorNeutralStroke2}`}),fullDayCell:T.css({borderRight:`1px solid ${w.tokens.colorNeutralStroke1}`,display:"flex",flexDirection:"row",gap:"2px",padding:"4px",borderBottom:`3px solid ${w.tokens.colorNeutralStroke2}`,overflow:"hidden"}),fullDayEvent:T.css({flex:"1 1 auto",minWidth:"24px",height:"24px",padding:"4px 8px",backgroundColor:w.tokens.colorBrandBackground,color:w.tokens.colorNeutralForegroundOnBrand,borderRadius:"4px",overflow:"hidden",display:"flex",alignItems:"center",justifyContent:"center"}),dayHeaderCell:T.css({textAlign:"center",backgroundColor:w.tokens.colorNeutralBackground2,padding:"8px",fontWeight:"bold",borderBottom:`1px solid ${w.tokens.colorNeutralStroke1}`}),todayHeaderCell:T.css({borderTop:`5px solid ${w.tokens.colorBrandBackground}`}),eventCard:T.css({alignItems:"center",justifyContent:"center",marginRight:"2px",zIndex:1,position:"absolute",alignContent:"center",overflow:"hidden"}),dayCell:T.css({borderBottom:`1px solid ${w.tokens.colorNeutralStroke1}`,borderRight:`1px solid ${w.tokens.colorNeutralStroke1}`,position:"relative",overflow:"visible",FlexDirection:"column",gap:"4px"}),currentTimeIndicator:T.css({position:"absolute",left:0,height:"2px",backgroundColor:w.tokens.colorPaletteRedBorderActive,width:"100%",zIndex:1}),currentHalfHourCell:T.css({border:`2px solid ${w.tokens.colorPaletteRedBorderActive}`}),eventTitle:T.css({display:"-webkit-box","-webkit-line-clamp":"1","-webkit-box-orient":"vertical",textAlign:"start",textOverflow:"ellipsis",paddingLeft:"8px",wordBreak:"break-word",overflow:"hidden"})},applyEventHouverColorClass:(e,t)=>T.css({backgroundColor:e??w.tokens.colorBrandBackground,":hover":{backgroundColor:t??w.tokens.colorBrandBackgroundHover}})}),er={allDay:"All Day"},tr=e=>{const{events:t,currentDay:r,height:n,strings:i=er}=e,{styles:o}=Qt(),a=v.useRef(null),{getSpanSlots:s,getEventColors:l,getCalendarColors:c}=Lt(),u=Intl.DateTimeFormat().resolvedOptions().timeZone,{getWeekEvents:h}=Kt(u),d=q.useCallback(()=>Array.from({length:24},(e,t)=>b.jsxs(q.Fragment,{children:[b.jsx("div",{className:o.timeCell,children:b.jsxs(w.Body1Strong,{children:[t,":00"]})}),b.jsx("div",{className:o.timeCell})]},t)),[o.timeCell]),p=q.useCallback(()=>b.jsxs(b.Fragment,{children:[b.jsx("div",{className:o.blankHeader}),Array.from({length:1},(e,t)=>{const n=k.addDays(r,t),i=k.isToday(n)?o.todayHeaderCell:"";return b.jsxs("div",{className:w.mergeClasses(o.dayHeaderCell,i),children:[b.jsx(w.Text,{weight:"semibold",size:600,style:{paddingRight:10},children:k.format(n,"dd")}),b.jsx(w.Subtitle1,{children:k.format(n,"LLLL, yyyy")})]},t)})]}),[r,o.blankHeader,o.dayHeaderCell,o.todayHeaderCell]),f=q.useCallback(()=>{const e=h(t,r.toISOString());return b.jsxs(b.Fragment,{children:[b.jsx("div",{className:o.fullDayLabel,children:b.jsx(w.Body1,{children:i.allDay})}),Array.from({length:1},(t,n)=>{const i=k.format(k.addDays(r,n),"yyyy-MM-dd"),a=e.find(e=>e.date===i),s=(null==a?void 0:a.fullDayEvents)||[];return b.jsx("div",{className:o.fullDayCell,children:s.map(e=>b.jsx("div",{className:o.fullDayEvent,style:{gridColumn:`${n+2}`,backgroundColor:e.color?c(e.color).backgroundColor:l(e.category).backgroundColor},children:b.jsx(w.Caption1Strong,{className:o.eventTitle,children:e.title})},e.id))},n)})]})},[r,h,o.fullDayCell,o.fullDayEvent,o.fullDayLabel,o.eventTitle,c,l,t,i.allDay]),g=q.useCallback(()=>{const e=h(t,r.toISOString());return Array.from({length:1},(t,n)=>{const i=k.format(k.addDays(r,n),"yyyy-MM-dd"),a=e.find(e=>e.date===i);return b.jsx(q.Fragment,{children:null==a?void 0:a.timeSlots.map((e,t)=>{const r=e.events.length;return b.jsx("div",{className:o.dayCell,style:{gridRow:t+3},children:e.events.map((e,n)=>{const i=new Date(e.start),o=new Date(e.end),{spanSlots:a,startSlot:l}=s(i,o);return t===l?b.jsx(Ht,{event:e,eventCount:r,spanSlots:a,rowHeight:33,eventIndex:n,view:"day"},e.id):null})},t)})},n)})},[r,s,h,o.dayCell,t]);return b.jsx("div",{className:o.container,style:{height:n},children:b.jsxs("div",{ref:a,className:o.dayGrid,children:[b.jsx("div",{className:o.timeColumn,children:d()}),p(),f(),g()]})})};var rr=(e=>(e.Day="day",e.Week="week",e.Month="month",e))(rr||{});const nr={month:"Month",week:"Week",day:"Day"},ir=e=>{const{onSelected:t,value:r,strings:n=nr}=e,[i,o]=q.useState(r??rr.Month),[a,s]=q.useState({view:[r??rr.Month]}),l=q.useMemo(()=>P.bundleIcon(P.CalendarDayFilled,P.CalendarDayRegular),[]),c=q.useMemo(()=>P.bundleIcon(P.CalendarMonthFilled,P.CalendarMonthRegular),[]),u=q.useMemo(()=>P.bundleIcon(P.CalendarWorkWeekFilled,P.CalendarWorkWeekRegular),[]);q.useEffect(()=>{void 0!==r&&(o(r),s({view:[r]}))},[r]);const[h,d]=q.useState(!1),p=q.useCallback((e,t)=>{d(t.open)},[]),f=q.useCallback(()=>{switch(i){case rr.Month:return b.jsx(c,{});case rr.Week:return b.jsx(u,{});case rr.Day:return b.jsx(l,{});default:return b.jsx(c,{})}},[i]),g=q.useCallback(e=>{switch(e){case rr.Month:return n.month;case rr.Week:return n.week;case rr.Day:return n.day;default:return n.month}},[n]),m=q.useCallback((e,{name:r,checkedItems:n})=>{if("view"===r){const e=n[0];o(e),s({view:n}),t(e)}},[t]);return b.jsx(b.Fragment,{children:b.jsxs(w.Menu,{open:h,onOpenChange:p,children:[b.jsx(w.MenuTrigger,{disableButtonEnhancement:!0,children:b.jsx(w.MenuButton,{shape:"circular",icon:f(),style:{minWidth:"150px"},children:g(i)})}),b.jsx(w.MenuPopover,{children:b.jsxs(w.MenuList,{onCheckedValueChange:m,checkedValues:a,children:[b.jsx(w.MenuItemRadio,{icon:b.jsx(l,{}),name:"view",value:rr.Day,children:n.day}),b.jsx(w.MenuItemRadio,{icon:b.jsx(u,{}),name:"view",value:rr.Week,children:n.week}),b.jsx(w.MenuItemRadio,{icon:b.jsx(c,{}),name:"view",value:rr.Month,children:n.month})]})})]})})},or=q.memo(e=>{const{onSelected:t,value:r}=e,[n,i]=q.useState(r??new Date),[o,a]=q.useState(()=>{const e=r??new Date;return C.format(e,"dd MMM, yyyy")}),[s,l]=q.useState(!1),c=q.useCallback((e,t)=>{l(t.open)},[]),u=q.useMemo(()=>P.bundleIcon(P.CalendarMonthFilled,P.CalendarMonthRegular),[]),h=q.useCallback(e=>{if(e){const r=Intl.DateTimeFormat().resolvedOptions().timeZone,n=C.utcToZonedTime(e,r);i(n),a(C.format(n,"dd MMM, yyyy")),t(n),l(!1)}},[t]);return b.jsxs(w.Menu,{open:s,onOpenChange:c,children:[b.jsx(w.MenuTrigger,{disableButtonEnhancement:!0,children:b.jsx(w.MenuButton,{shape:"circular",icon:b.jsx(u,{}),style:{minWidth:"200px"},children:o})}),b.jsx(w.MenuPopover,{style:{maxWidth:"fit-content"},children:b.jsx(w.MenuList,{children:b.jsx(I.Calendar,{highlightSelectedMonth:!0,showGoToToday:!0,onSelectDate:h,value:n})})})]})}),ar={months:["January","February","March","April","May","June","July","August","September","October","November","December"],shortMonths:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],days:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],shortDays:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],goToToday:"Go to today"},sr=e=>{const{onDateChange:t,defaultSelectedDate:r,onDismiss:n,strings:i=ar}=e,o={root:T.css({outline:"none"})},[a,s]=q.useState(r??new Date),l=q.useCallback((e,r)=>{s(e),t(e),n()},[t,n]);return b.jsx(b.Fragment,{children:b.jsx(I.Calendar,{className:o.root,dateRangeType:I.DateRangeType.Month,highlightSelectedMonth:!0,isDayPickerVisible:!1,onSelectDate:l,value:a,onDismiss:n,showGoToToday:!1,allFocusable:!1,strings:i})})},lr=e=>{const{onSelected:t,value:r}=e,n=P.bundleIcon(P.CalendarMonthFilled,P.CalendarMonthRegular),[i,o]=q.useState(r??new Date);q.useEffect(()=>{t(r??new Date),o(r??new Date)},[r]);const[a,s]=q.useState(!1),l=q.useCallback(e=>{t(e),o(e)},[]);return b.jsx(b.Fragment,{children:b.jsxs(w.Menu,{open:a,onOpenChange:(e,t)=>{s(t.open)},children:[b.jsx(w.MenuTrigger,{disableButtonEnhancement:!0,children:b.jsx(w.MenuButton,{shape:"circular",icon:b.jsx(n,{}),style:{minWidth:"200px"},children:k.format(i,"MMMM yyyy")})}),b.jsx(w.MenuPopover,{children:b.jsx(w.MenuList,{children:b.jsx(sr,{onDateChange:l,defaultSelectedDate:i,onDismiss:()=>{s(!1)}})})})]})})},cr={selectWeekPlaceholder:"Select a week"},ur=e=>{const t=Intl.DateTimeFormat().resolvedOptions().timeZone,r=C.format(e.start,"MMM",{timeZone:t}),n=C.format(e.end,"MMM",{timeZone:t});return C.format(e.start,"yyyy",{timeZone:t})!==C.format(e.end,"yyyy",{timeZone:t})?`${C.format(e.start,"dd MMM yyyy",{timeZone:t})} - ${C.format(e.end,"dd MMM yyyy",{timeZone:t})}`:r!==n?`${C.format(e.start,"dd MMM",{timeZone:t})} - ${C.format(e.end,"dd MMM yyyy",{timeZone:t})}`:`${C.format(e.start,"dd",{timeZone:t})} - ${C.format(e.end,"dd MMM yyyy",{timeZone:t})}`},hr=e=>{const t=Intl.DateTimeFormat().resolvedOptions().timeZone,r=C.utcToZonedTime(e,t),n=new Date(r);n.setDate(r.getDate()-r.getDay());const i=new Date(n);return i.setDate(n.getDate()+6),{start:C.utcToZonedTime(n,t),end:C.utcToZonedTime(i,t)}},dr=q.memo(e=>{const{onSelected:t,value:r,strings:n=cr}=e,i=I.DateRangeType.Week,[o,a]=q.useState(r??new Date),[s,l]=q.useState(()=>{const e=r??new Date;if(e){const t=hr(e);return ur(t)}return n.selectWeekPlaceholder}),[c,u]=q.useState(!1),h=q.useCallback((e,t)=>{u(t.open)},[]),d=q.useMemo(()=>P.bundleIcon(P.CalendarMonthFilled,P.CalendarMonthRegular),[]),p=q.useCallback(e=>{if(e){a(e);const r=hr(e),n=ur(r);l(n),t({startDate:r.start,endDate:r.end}),u(!1)}},[t]),f=q.useMemo(()=>0,[]);return b.jsxs(w.Menu,{open:c,onOpenChange:h,children:[b.jsx(w.MenuTrigger,{disableButtonEnhancement:!0,children:b.jsx(w.MenuButton,{shape:"circular",icon:b.jsx(d,{}),style:{minWidth:"200px"},children:s})}),b.jsx(w.MenuPopover,{style:{maxWidth:"fit-content"},children:b.jsx(w.MenuList,{children:b.jsx(I.Calendar,{dateRangeType:i,highlightSelectedMonth:!0,showGoToToday:!0,onSelectDate:p,value:o,firstDayOfWeek:f})})})]})}),pr={today:"Today",previous:"Previous",next:"Next"},fr=q.memo(({selectedView:e,onSelectedView:t,currentDate:r,setCurrentDate:n,onWeekChange:i,onMonthChange:o,onDayChange:a,strings:s=pr})=>{const l=q.useMemo(()=>P.bundleIcon(P.ArrowDownFilled,P.ArrowDownRegular),[]),c=q.useMemo(()=>P.bundleIcon(P.ArrowUpFilled,P.ArrowUpRegular),[]),u=q.useCallback(e=>{i(e.startDate),n(e.startDate)},[i,n]),h=q.useCallback(e=>{o(e),n(e)},[o,n]),d=q.useCallback(e=>{a(e),n(e)},[a,n]),p=q.useCallback(()=>{switch(e){case rr.Month:return b.jsx(lr,{onSelected:h,value:r});case rr.Week:return b.jsx(dr,{onSelected:u,value:r});case rr.Day:return b.jsx(or,{onSelected:d,value:r});default:return b.jsx(lr,{onSelected:h,value:r})}},[e,h,u,d,r]),f=q.useCallback(()=>b.jsx(w.Tooltip,{content:s.today,relationship:"label",children:b.jsx(w.Button,{shape:"circular",icon:b.jsx(P.CalendarTodayRegular,{}),size:"medium",onClick:()=>a(new Date),children:s.today})}),[a,s.today]),g=q.useCallback(t=>{const s=new Date(r);switch(e){case rr.Month:s.setMonth(s.getMonth()+t),o(s);break;case rr.Week:s.setDate(s.getDate()+7*t),i(s);break;case rr.Day:s.setDate(s.getDate()+t),a(s)}n(s)},[r,e,o,i,a,n]);return b.jsxs(ft,{width:"calc(100% - 40px)",height:"fit-content",horizontal:!0,horizontalAlign:"space-between",verticalAlign:"center",paddingLeft:"20px",paddingRight:"20px",paddingBottom:"10px",paddingTop:"10px",columnGap:10,styles:{overflow:"hidden"},children:[b.jsxs(ft,{horizontal:!0,horizontalAlign:"start",verticalAlign:"center",columnGap:10,children:[b.jsx(f,{}),b.jsx(p,{}),b.jsx(w.Tooltip,{content:s.previous,relationship:"label",children:b.jsx(w.Button,{size:"medium",icon:b.jsx(c,{fontSize:14}),onClick:()=>g(-1)})}),b.jsx(w.Tooltip,{content:s.next,relationship:"label",children:b.jsx(w.Button,{size:"medium",icon:b.jsx(l,{fontSize:14}),onClick:()=>g(1)})})]}),b.jsx(ft,{horizontal:!0,horizontalAlign:"start",verticalAlign:"center",columnGap:10,children:b.jsx(ir,{onSelected:t,value:e})})]})}),gr={allDay:"All Day"},mr=e=>{const{events:t,currentDay:r,height:n,strings:i=gr}=e,{styles:o}=zt(),[a]=v.useState(r),[s,l]=v.useState(32),c=v.useRef(null),{getSpanSlots:u,getEventColors:h,getCalendarColors:d,formatDate:p}=Lt(),f=k.startOfWeek(a,{weekStartsOn:0}),g=Intl.DateTimeFormat().resolvedOptions().timeZone,{getWeekEvents:m}=Kt(g);v.useEffect(()=>{const e=new _.ResizeObserver(()=>{if(c.current){const e=c.current.querySelector(".dayCell");e&&l(e.offsetHeight)}});return c.current&&e.observe(c.current),()=>{e.disconnect()}},[]);const y=q.useCallback(()=>Array.from({length:24},(e,t)=>b.jsxs(q.Fragment,{children:[b.jsx("div",{className:o.timeCell,children:b.jsxs(w.Body1Strong,{children:[t,":00"]})}),b.jsx("div",{className:o.timeCell})]},t)),[o.timeCell]),x=q.useCallback(()=>b.jsxs(b.Fragment,{children:[b.jsx("div",{className:o.blankHeader}),Array.from({length:7},(e,t)=>{const r=k.addDays(f,t),n=k.isToday(r)?o.todayHeaderCell:"";return b.jsxs("div",{className:w.mergeClasses(o.dayHeaderCell,n),children:[b.jsx(w.Text,{weight:"regular",size:600,style:{paddingRight:10},children:p(r.toISOString(),"dd")}),b.jsx(w.Body1,{children:p(r.toISOString(),"EEE")})]},t)})]}),[f,o,p]),C=q.useCallback(()=>{const e=m(t,f.toISOString());return b.jsxs(b.Fragment,{children:[b.jsx("div",{className:o.fullDayLabel,children:b.jsx(w.Body1,{children:i.allDay})}),Array.from({length:7},(t,r)=>{const n=p(k.addDays(f,r).toISOString(),"yyyy-MM-dd"),i=e.find(e=>e.date===n),a=(null==i?void 0:i.fullDayEvents)||[];return b.jsx("div",{className:o.fullDayCell,children:a.map(e=>b.jsx("div",{className:o.fullDayEvent,style:{gridColumn:`${r+2}`,backgroundColor:e.color?d(e.color).backgroundColor:h(e.category).backgroundColor},children:b.jsx(w.Caption1Strong,{className:o.eventTitle,children:e.title})},e.id))},r)})]})},[f,o,m,d,h,t,p,i.allDay]),S=q.useCallback(()=>{const e=m(t,f.toISOString());return Array.from({length:7},(t,r)=>{const n=k.format(k.addDays(f,r),"yyyy-MM-dd"),i=e.find(e=>e.date===n);return b.jsx(b.Fragment,{children:null==i?void 0:i.timeSlots.map((e,t)=>{const r=e.events.length;return b.jsx("div",{className:o.dayCell,style:{gridRow:t+3},children:e.events.map((e,n)=>{const i=new Date(e.start),o=new Date(e.end),{spanSlots:a,startSlot:l}=u(i,o);return t===l?b.jsx(Ht,{event:e,eventCount:r,spanSlots:a,rowHeight:s,eventIndex:n,view:"week"},e.id):null})},t)})})})},[f,o,m,u,s,t]);return b.jsx("div",{className:o.container,style:{height:n},children:b.jsxs("div",{ref:c,className:o.weekGrid,children:[b.jsx("div",{className:o.timeColumn,children:y()}),x(),C(),S()]})})},yr={daysOfWeek:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"]},xr=({currentDate:e,rowHeight:t,getCalendarDays:r,getEventsForDay:n,styles:i,onDaySlotClick:o,height:a,calendarRef:s,strings:l})=>{const c=(null==l?void 0:l.daysOfWeek)||yr.daysOfWeek;return b.jsx(ft,{height:a,width:"100%",verticalAlign:"start",horizontalAlign:"start",children:b.jsxs("div",{className:i.calendarWrapper,ref:s,children:[c.map(e=>b.jsx(w.Body1,{className:i.dayHeader,children:e},e)),r(e).map((e,r)=>{const{day:i,currentMonth:a}=e,s=a?n(e):[];return b.jsx($t,{day:i,date:e.date,currentMonth:e.currentMonth,events:s,columnHeight:t||0,onDayClick:o},r)})]})})},br=q.memo(({events:e,currentDay:t,height:r,strings:n})=>b.jsx(mr,{events:e,currentDay:t,height:r,strings:n})),vr=q.memo(({events:e,currentDay:t,height:r,strings:n})=>b.jsx(tr,{currentDay:t,events:e,height:r,strings:n}));var Cr=function(){function e(e){var t=this;this._insertTag=function(e){var r;r=0===t.tags.length?t.insertionPoint?t.insertionPoint.nextSibling:t.prepend?t.container.firstChild:t.before:t.tags[t.tags.length-1].nextSibling,t.container.insertBefore(e,r),t.tags.push(e)},this.isSpeedy=void 0===e.speedy||e.speedy,this.tags=[],this.ctr=0,this.nonce=e.nonce,this.key=e.key,this.container=e.container,this.prepend=e.prepend,this.insertionPoint=e.insertionPoint,this.before=null}var t=e.prototype;return t.hydrate=function(e){e.forEach(this._insertTag)},t.insert=function(e){this.ctr%(this.isSpeedy?65e3:1)==0&&this._insertTag(function(e){var t=document.createElement("style");return t.setAttribute("data-emotion",e.key),void 0!==e.nonce&&t.setAttribute("nonce",e.nonce),t.appendChild(document.createTextNode("")),t.setAttribute("data-s",""),t}(this));var t=this.tags[this.tags.length-1];if(this.isSpeedy){var r=function(e){if(e.sheet)return e.sheet;for(var t=0;t<document.styleSheets.length;t++)if(document.styleSheets[t].ownerNode===e)return document.styleSheets[t]}(t);try{r.insertRule(e,r.cssRules.length)}catch(n){}}else t.appendChild(document.createTextNode(e));this.ctr++},t.flush=function(){this.tags.forEach(function(e){var t;return null==(t=e.parentNode)?void 0:t.removeChild(e)}),this.tags=[],this.ctr=0},e}(),wr="-ms-",kr="-moz-",Sr="-webkit-",_r="comm",Tr="rule",Ar="decl",Pr="@keyframes",Er=Math.abs,Mr=String.fromCharCode,Ir=Object.assign;function Br(e){return e.trim()}function Lr(e,t,r){return e.replace(t,r)}function jr(e,t){return e.indexOf(t)}function Nr(e,t){return 0|e.charCodeAt(t)}function Dr(e,t,r){return e.slice(t,r)}function Or(e){return e.length}function Fr(e){return e.length}function Rr(e,t){return t.push(e),e}var $r=1,zr=1,Vr=0,Wr=0,Hr=0,qr="";function Ur(e,t,r,n,i,o,a){return{value:e,root:t,parent:r,type:n,props:i,children:o,line:$r,column:zr,length:a,return:""}}function Gr(e,t){return Ir(Ur("",null,null,"",null,null,0),e,{length:-e.length},t)}function Xr(){return Hr=Wr>0?Nr(qr,--Wr):0,zr--,10===Hr&&(zr=1,$r--),Hr}function Jr(){return Hr=Wr<Vr?Nr(qr,Wr++):0,zr++,10===Hr&&(zr=1,$r++),Hr}function Yr(){return Nr(qr,Wr)}function Zr(){return Wr}function Kr(e,t){return Dr(qr,e,t)}function Qr(e){switch(e){case 0:case 9:case 10:case 13:case 32:return 5;case 33:case 43:case 44:case 47:case 62:case 64:case 126:case 59:case 123:case 125:return 4;case 58:return 3;case 34:case 39:case 40:case 91:return 2;case 41:case 93:return 1}return 0}function en(e){return $r=zr=1,Vr=Or(qr=e),Wr=0,[]}function tn(e){return qr="",e}function rn(e){return Br(Kr(Wr-1,an(91===e?e+2:40===e?e+1:e)))}function nn(e){for(;(Hr=Yr())&&Hr<33;)Jr();return Qr(e)>2||Qr(Hr)>3?"":" "}function on(e,t){for(;--t&&Jr()&&!(Hr<48||Hr>102||Hr>57&&Hr<65||Hr>70&&Hr<97););return Kr(e,Zr()+(t<6&&32==Yr()&&32==Jr()))}function an(e){for(;Jr();)switch(Hr){case e:return Wr;case 34:case 39:34!==e&&39!==e&&an(Hr);break;case 40:41===e&&an(e);break;case 92:Jr()}return Wr}function sn(e,t){for(;Jr()&&e+Hr!==57&&(e+Hr!==84||47!==Yr()););return"/*"+Kr(t,Wr-1)+"*"+Mr(47===e?e:Jr())}function ln(e){for(;!Qr(Yr());)Jr();return Kr(e,Wr)}function cn(e){return tn(un("",null,null,null,[""],e=en(e),0,[0],e))}function un(e,t,r,n,i,o,a,s,l){for(var c=0,u=0,h=a,d=0,p=0,f=0,g=1,m=1,y=1,x=0,b="",v=i,C=o,w=n,k=b;m;)switch(f=x,x=Jr()){case 40:if(108!=f&&58==Nr(k,h-1)){-1!=jr(k+=Lr(rn(x),"&","&\f"),"&\f")&&(y=-1);break}case 34:case 39:case 91:k+=rn(x);break;case 9:case 10:case 13:case 32:k+=nn(f);break;case 92:k+=on(Zr()-1,7);continue;case 47:switch(Yr()){case 42:case 47:Rr(dn(sn(Jr(),Zr()),t,r),l);break;default:k+="/"}break;case 123*g:s[c++]=Or(k)*y;case 125*g:case 59:case 0:switch(x){case 0:case 125:m=0;case 59+u:-1==y&&(k=Lr(k,/\f/g,"")),p>0&&Or(k)-h&&Rr(p>32?pn(k+";",n,r,h-1):pn(Lr(k," ","")+";",n,r,h-2),l);break;case 59:k+=";";default:if(Rr(w=hn(k,t,r,c,u,i,s,b,v=[],C=[],h),o),123===x)if(0===u)un(k,t,w,w,v,o,h,s,C);else switch(99===d&&110===Nr(k,3)?100:d){case 100:case 108:case 109:case 115:un(e,w,w,n&&Rr(hn(e,w,w,0,0,i,s,b,i,v=[],h),C),i,C,h,s,n?v:C);break;default:un(k,w,w,w,[""],C,0,s,C)}}c=u=p=0,g=y=1,b=k="",h=a;break;case 58:h=1+Or(k),p=f;default:if(g<1)if(123==x)--g;else if(125==x&&0==g++&&125==Xr())continue;switch(k+=Mr(x),x*g){case 38:y=u>0?1:(k+="\f",-1);break;case 44:s[c++]=(Or(k)-1)*y,y=1;break;case 64:45===Yr()&&(k+=rn(Jr())),d=Yr(),u=h=Or(b=k+=ln(Zr())),x++;break;case 45:45===f&&2==Or(k)&&(g=0)}}return o}function hn(e,t,r,n,i,o,a,s,l,c,u){for(var h=i-1,d=0===i?o:[""],p=Fr(d),f=0,g=0,m=0;f<n;++f)for(var y=0,x=Dr(e,h+1,h=Er(g=a[f])),b=e;y<p;++y)(b=Br(g>0?d[y]+" "+x:Lr(x,/&\f/g,d[y])))&&(l[m++]=b);return Ur(e,t,r,0===i?Tr:s,l,c,u)}function dn(e,t,r){return Ur(e,t,r,_r,Mr(Hr),Dr(e,2,-2),0)}function pn(e,t,r,n){return Ur(e,t,r,Ar,Dr(e,0,n),Dr(e,n+1,-1),n)}function fn(e,t){for(var r="",n=Fr(e),i=0;i<n;i++)r+=t(e[i],i,e,t)||"";return r}function gn(e,t,r,n){switch(e.type){case"@layer":if(e.children.length)break;case"@import":case Ar:return e.return=e.return||e.value;case _r:return"";case Pr:return e.return=e.value+"{"+fn(e.children,n)+"}";case Tr:e.value=e.props.join(",")}return Or(r=fn(e.children,n))?e.return=e.value+"{"+r+"}":""}function mn(e){var t=Object.create(null);return function(r){return void 0===t[r]&&(t[r]=e(r)),t[r]}}var yn=function(e,t,r){for(var n=0,i=0;n=i,i=Yr(),38===n&&12===i&&(t[r]=1),!Qr(i);)Jr();return Kr(e,Wr)},xn=function(e,t){return tn(function(e,t){var r=-1,n=44;do{switch(Qr(n)){case 0:38===n&&12===Yr()&&(t[r]=1),e[r]+=yn(Wr-1,t,r);break;case 2:e[r]+=rn(n);break;case 4:if(44===n){e[++r]=58===Yr()?"&\f":"",t[r]=e[r].length;break}default:e[r]+=Mr(n)}}while(n=Jr());return e}(en(e),t))},bn=new WeakMap,vn=function(e){if("rule"===e.type&&e.parent&&!(e.length<1)){for(var t=e.value,r=e.parent,n=e.column===r.column&&e.line===r.line;"rule"!==r.type;)if(!(r=r.parent))return;if((1!==e.props.length||58===t.charCodeAt(0)||bn.get(r))&&!n){bn.set(e,!0);for(var i=[],o=xn(t,i),a=r.props,s=0,l=0;s<o.length;s++)for(var c=0;c<a.length;c++,l++)e.props[l]=i[s]?o[s].replace(/&\f/g,a[c]):a[c]+" "+o[s]}}},Cn=function(e){if("decl"===e.type){var t=e.value;108===t.charCodeAt(0)&&98===t.charCodeAt(2)&&(e.return="",e.value="")}};function wn(e,t){switch(function(e,t){return 45^Nr(e,0)?(((t<<2^Nr(e,0))<<2^Nr(e,1))<<2^Nr(e,2))<<2^Nr(e,3):0}(e,t)){case 5103:return Sr+"print-"+e+e;case 5737:case 4201:case 3177:case 3433:case 1641:case 4457:case 2921:case 5572:case 6356:case 5844:case 3191:case 6645:case 3005:case 6391:case 5879:case 5623:case 6135:case 4599:case 4855:case 4215:case 6389:case 5109:case 5365:case 5621:case 3829:return Sr+e+e;case 5349:case 4246:case 4810:case 6968:case 2756:return Sr+e+kr+e+wr+e+e;case 6828:case 4268:return Sr+e+wr+e+e;case 6165:return Sr+e+wr+"flex-"+e+e;case 5187:return Sr+e+Lr(e,/(\w+).+(:[^]+)/,Sr+"box-$1$2"+wr+"flex-$1$2")+e;case 5443:return Sr+e+wr+"flex-item-"+Lr(e,/flex-|-self/,"")+e;case 4675:return Sr+e+wr+"flex-line-pack"+Lr(e,/align-content|flex-|-self/,"")+e;case 5548:return Sr+e+wr+Lr(e,"shrink","negative")+e;case 5292:return Sr+e+wr+Lr(e,"basis","preferred-size")+e;case 6060:return Sr+"box-"+Lr(e,"-grow","")+Sr+e+wr+Lr(e,"grow","positive")+e;case 4554:return Sr+Lr(e,/([^-])(transform)/g,"$1"+Sr+"$2")+e;case 6187:return Lr(Lr(Lr(e,/(zoom-|grab)/,Sr+"$1"),/(image-set)/,Sr+"$1"),e,"")+e;case 5495:case 3959:return Lr(e,/(image-set\([^]*)/,Sr+"$1$`$1");case 4968:return Lr(Lr(e,/(.+:)(flex-)?(.*)/,Sr+"box-pack:$3"+wr+"flex-pack:$3"),/s.+-b[^;]+/,"justify")+Sr+e+e;case 4095:case 3583:case 4068:case 2532:return Lr(e,/(.+)-inline(.+)/,Sr+"$1$2")+e;case 8116:case 7059:case 5753:case 5535:case 5445:case 5701:case 4933:case 4677:case 5533:case 5789:case 5021:case 4765:if(Or(e)-1-t>6)switch(Nr(e,t+1)){case 109:if(45!==Nr(e,t+4))break;case 102:return Lr(e,/(.+:)(.+)-([^]+)/,"$1"+Sr+"$2-$3$1"+kr+(108==Nr(e,t+3)?"$3":"$2-$3"))+e;case 115:return~jr(e,"stretch")?wn(Lr(e,"stretch","fill-available"),t)+e:e}break;case 4949:if(115!==Nr(e,t+1))break;case 6444:switch(Nr(e,Or(e)-3-(~jr(e,"!important")&&10))){case 107:return Lr(e,":",":"+Sr)+e;case 101:return Lr(e,/(.+:)([^;!]+)(;|!.+)?/,"$1"+Sr+(45===Nr(e,14)?"inline-":"")+"box$3$1"+Sr+"$2$3$1"+wr+"$2box$3")+e}break;case 5936:switch(Nr(e,t+11)){case 114:return Sr+e+wr+Lr(e,/[svh]\w+-[tblr]{2}/,"tb")+e;case 108:return Sr+e+wr+Lr(e,/[svh]\w+-[tblr]{2}/,"tb-rl")+e;case 45:return Sr+e+wr+Lr(e,/[svh]\w+-[tblr]{2}/,"lr")+e}return Sr+e+wr+e+e}return e}var kn=[function(e,t,r,n){if(e.length>-1&&!e.return)switch(e.type){case Ar:e.return=wn(e.value,e.length);break;case Pr:return fn([Gr(e,{value:Lr(e.value,"@","@"+Sr)})],n);case Tr:if(e.length)return function(e,t){return e.map(t).join("")}(e.props,function(t){switch(function(e,t){return(e=t.exec(e))?e[0]:e}(t,/(::plac\w+|:read-\w+)/)){case":read-only":case":read-write":return fn([Gr(e,{props:[Lr(t,/:(read-\w+)/,":-moz-$1")]})],n);case"::placeholder":return fn([Gr(e,{props:[Lr(t,/:(plac\w+)/,":"+Sr+"input-$1")]}),Gr(e,{props:[Lr(t,/:(plac\w+)/,":-moz-$1")]}),Gr(e,{props:[Lr(t,/:(plac\w+)/,wr+"input-$1")]})],n)}return""})}}],Sn=function(e){var t=e.key;if("css"===t){var r=document.querySelectorAll("style[data-emotion]:not([data-s])");Array.prototype.forEach.call(r,function(e){-1!==e.getAttribute("data-emotion").indexOf(" ")&&(document.head.appendChild(e),e.setAttribute("data-s",""))})}var n,i,o=e.stylisPlugins||kn,a={},s=[];n=e.container||document.head,Array.prototype.forEach.call(document.querySelectorAll('style[data-emotion^="'+t+' "]'),function(e){for(var t=e.getAttribute("data-emotion").split(" "),r=1;r<t.length;r++)a[t[r]]=!0;s.push(e)});var l,c,u,h,d=[gn,(h=function(e){l.insert(e)},function(e){e.root||(e=e.return)&&h(e)})],p=(c=[vn,Cn].concat(o,d),u=Fr(c),function(e,t,r,n){for(var i="",o=0;o<u;o++)i+=c[o](e,t,r,n)||"";return i});i=function(e,t,r,n){l=r,fn(cn(e?e+"{"+t.styles+"}":t.styles),p),n&&(f.inserted[t.name]=!0)};var f={key:t,sheet:new Cr({key:t,container:n,nonce:e.nonce,speedy:e.speedy,prepend:e.prepend,insertionPoint:e.insertionPoint}),nonce:e.nonce,inserted:a,registered:{},insert:i};return f.sheet.hydrate(s),f},_n="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{};function Tn(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var An,Pn={exports:{}},En={};var Mn,In={};
|
|
2
|
+
/** @license React v16.13.1
|
|
3
|
+
* react-is.development.js
|
|
4
|
+
*
|
|
5
|
+
* Copyright (c) Facebook, Inc. and its affiliates.
|
|
6
|
+
*
|
|
7
|
+
* This source code is licensed under the MIT license found in the
|
|
8
|
+
* LICENSE file in the root directory of this source tree.
|
|
9
|
+
*/"production"===process.env.NODE_ENV?Pn.exports=function(){if(An)return En;An=1;var e="function"==typeof Symbol&&Symbol.for,t=e?Symbol.for("react.element"):60103,r=e?Symbol.for("react.portal"):60106,n=e?Symbol.for("react.fragment"):60107,i=e?Symbol.for("react.strict_mode"):60108,o=e?Symbol.for("react.profiler"):60114,a=e?Symbol.for("react.provider"):60109,s=e?Symbol.for("react.context"):60110,l=e?Symbol.for("react.async_mode"):60111,c=e?Symbol.for("react.concurrent_mode"):60111,u=e?Symbol.for("react.forward_ref"):60112,h=e?Symbol.for("react.suspense"):60113,d=e?Symbol.for("react.suspense_list"):60120,p=e?Symbol.for("react.memo"):60115,f=e?Symbol.for("react.lazy"):60116,g=e?Symbol.for("react.block"):60121,m=e?Symbol.for("react.fundamental"):60117,y=e?Symbol.for("react.responder"):60118,x=e?Symbol.for("react.scope"):60119;function b(e){if("object"==typeof e&&null!==e){var d=e.$$typeof;switch(d){case t:switch(e=e.type){case l:case c:case n:case o:case i:case h:return e;default:switch(e=e&&e.$$typeof){case s:case u:case f:case p:case a:return e;default:return d}}case r:return d}}}function v(e){return b(e)===c}return En.AsyncMode=l,En.ConcurrentMode=c,En.ContextConsumer=s,En.ContextProvider=a,En.Element=t,En.ForwardRef=u,En.Fragment=n,En.Lazy=f,En.Memo=p,En.Portal=r,En.Profiler=o,En.StrictMode=i,En.Suspense=h,En.isAsyncMode=function(e){return v(e)||b(e)===l},En.isConcurrentMode=v,En.isContextConsumer=function(e){return b(e)===s},En.isContextProvider=function(e){return b(e)===a},En.isElement=function(e){return"object"==typeof e&&null!==e&&e.$$typeof===t},En.isForwardRef=function(e){return b(e)===u},En.isFragment=function(e){return b(e)===n},En.isLazy=function(e){return b(e)===f},En.isMemo=function(e){return b(e)===p},En.isPortal=function(e){return b(e)===r},En.isProfiler=function(e){return b(e)===o},En.isStrictMode=function(e){return b(e)===i},En.isSuspense=function(e){return b(e)===h},En.isValidElementType=function(e){return"string"==typeof e||"function"==typeof e||e===n||e===c||e===o||e===i||e===h||e===d||"object"==typeof e&&null!==e&&(e.$$typeof===f||e.$$typeof===p||e.$$typeof===a||e.$$typeof===s||e.$$typeof===u||e.$$typeof===m||e.$$typeof===y||e.$$typeof===x||e.$$typeof===g)},En.typeOf=b,En}():Pn.exports=(Mn||(Mn=1,"production"!==process.env.NODE_ENV&&function(){var e="function"==typeof Symbol&&Symbol.for,t=e?Symbol.for("react.element"):60103,r=e?Symbol.for("react.portal"):60106,n=e?Symbol.for("react.fragment"):60107,i=e?Symbol.for("react.strict_mode"):60108,o=e?Symbol.for("react.profiler"):60114,a=e?Symbol.for("react.provider"):60109,s=e?Symbol.for("react.context"):60110,l=e?Symbol.for("react.async_mode"):60111,c=e?Symbol.for("react.concurrent_mode"):60111,u=e?Symbol.for("react.forward_ref"):60112,h=e?Symbol.for("react.suspense"):60113,d=e?Symbol.for("react.suspense_list"):60120,p=e?Symbol.for("react.memo"):60115,f=e?Symbol.for("react.lazy"):60116,g=e?Symbol.for("react.block"):60121,m=e?Symbol.for("react.fundamental"):60117,y=e?Symbol.for("react.responder"):60118,x=e?Symbol.for("react.scope"):60119;function b(e){if("object"==typeof e&&null!==e){var d=e.$$typeof;switch(d){case t:var g=e.type;switch(g){case l:case c:case n:case o:case i:case h:return g;default:var m=g&&g.$$typeof;switch(m){case s:case u:case f:case p:case a:return m;default:return d}}case r:return d}}}var v=l,C=c,w=s,k=a,S=t,_=u,T=n,A=f,P=p,E=r,M=o,I=i,B=h,L=!1;function j(e){return b(e)===c}In.AsyncMode=v,In.ConcurrentMode=C,In.ContextConsumer=w,In.ContextProvider=k,In.Element=S,In.ForwardRef=_,In.Fragment=T,In.Lazy=A,In.Memo=P,In.Portal=E,In.Profiler=M,In.StrictMode=I,In.Suspense=B,In.isAsyncMode=function(e){return L||(L=!0,console.warn("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 17+. Update your code to use ReactIs.isConcurrentMode() instead. It has the exact same API.")),j(e)||b(e)===l},In.isConcurrentMode=j,In.isContextConsumer=function(e){return b(e)===s},In.isContextProvider=function(e){return b(e)===a},In.isElement=function(e){return"object"==typeof e&&null!==e&&e.$$typeof===t},In.isForwardRef=function(e){return b(e)===u},In.isFragment=function(e){return b(e)===n},In.isLazy=function(e){return b(e)===f},In.isMemo=function(e){return b(e)===p},In.isPortal=function(e){return b(e)===r},In.isProfiler=function(e){return b(e)===o},In.isStrictMode=function(e){return b(e)===i},In.isSuspense=function(e){return b(e)===h},In.isValidElementType=function(e){return"string"==typeof e||"function"==typeof e||e===n||e===c||e===o||e===i||e===h||e===d||"object"==typeof e&&null!==e&&(e.$$typeof===f||e.$$typeof===p||e.$$typeof===a||e.$$typeof===s||e.$$typeof===u||e.$$typeof===m||e.$$typeof===y||e.$$typeof===x||e.$$typeof===g)},In.typeOf=b}()),In);var Bn=Pn.exports,Ln={};Ln[Bn.ForwardRef]={$$typeof:!0,render:!0,defaultProps:!0,displayName:!0,propTypes:!0},Ln[Bn.Memo]={$$typeof:!0,compare:!0,defaultProps:!0,displayName:!0,propTypes:!0,type:!0};var jn=function(e,t,r){var n=e.key+"-"+t.name;!1===r&&void 0===e.registered[n]&&(e.registered[n]=t.styles)};var Nn={animationIterationCount:1,aspectRatio:1,borderImageOutset:1,borderImageSlice:1,borderImageWidth:1,boxFlex:1,boxFlexGroup:1,boxOrdinalGroup:1,columnCount:1,columns:1,flex:1,flexGrow:1,flexPositive:1,flexShrink:1,flexNegative:1,flexOrder:1,gridRow:1,gridRowEnd:1,gridRowSpan:1,gridRowStart:1,gridColumn:1,gridColumnEnd:1,gridColumnSpan:1,gridColumnStart:1,msGridRow:1,msGridRowSpan:1,msGridColumn:1,msGridColumnSpan:1,fontWeight:1,lineHeight:1,opacity:1,order:1,orphans:1,scale:1,tabSize:1,widows:1,zIndex:1,zoom:1,WebkitLineClamp:1,fillOpacity:1,floodOpacity:1,stopOpacity:1,strokeDasharray:1,strokeDashoffset:1,strokeMiterlimit:1,strokeOpacity:1,strokeWidth:1},Dn=/[A-Z]|^ms/g,On=/_EMO_([^_]+?)_([^]*?)_EMO_/g,Fn=function(e){return 45===e.charCodeAt(1)},Rn=function(e){return null!=e&&"boolean"!=typeof e},$n=mn(function(e){return Fn(e)?e:e.replace(Dn,"-$&").toLowerCase()}),zn=function(e,t){switch(e){case"animation":case"animationName":if("string"==typeof t)return t.replace(On,function(e,t,r){return Wn={name:t,styles:r,next:Wn},t})}return 1===Nn[e]||Fn(e)||"number"!=typeof t||0===t?t:t+"px"};function Vn(e,t,r){if(null==r)return"";var n=r;if(void 0!==n.__emotion_styles)return n;switch(typeof r){case"boolean":return"";case"object":var i=r;if(1===i.anim)return Wn={name:i.name,styles:i.styles,next:Wn},i.name;var o=r;if(void 0!==o.styles){var a=o.next;if(void 0!==a)for(;void 0!==a;)Wn={name:a.name,styles:a.styles,next:Wn},a=a.next;return o.styles+";"}return function(e,t,r){var n="";if(Array.isArray(r))for(var i=0;i<r.length;i++)n+=Vn(e,t,r[i])+";";else for(var o in r){var a=r[o];if("object"!=typeof a){var s=a;Rn(s)&&(n+=$n(o)+":"+zn(o,s)+";")}else if(Array.isArray(a)&&"string"==typeof a[0]&&null==t)for(var l=0;l<a.length;l++)Rn(a[l])&&(n+=$n(o)+":"+zn(o,a[l])+";");else{var c=Vn(e,t,a);switch(o){case"animation":case"animationName":n+=$n(o)+":"+c+";";break;default:n+=o+"{"+c+"}"}}}return n}(e,t,r);case"function":if(void 0!==e){var s=Wn,l=r(e);return Wn=s,Vn(e,t,l)}}return r}var Wn,Hn=/label:\s*([^\s;{]+)\s*(;|$)/g;function qn(e,t,r){if(1===e.length&&"object"==typeof e[0]&&null!==e[0]&&void 0!==e[0].styles)return e[0];var n=!0,i="";Wn=void 0;var o=e[0];null==o||void 0===o.raw?(n=!1,i+=Vn(r,t,o)):i+=o[0];for(var a=1;a<e.length;a++){if(i+=Vn(r,t,e[a]),n)i+=o[a]}Hn.lastIndex=0;for(var s,l="";null!==(s=Hn.exec(i));)l+="-"+s[1];var c=function(e){for(var t,r=0,n=0,i=e.length;i>=4;++n,i-=4)t=1540483477*(65535&(t=255&e.charCodeAt(n)|(255&e.charCodeAt(++n))<<8|(255&e.charCodeAt(++n))<<16|(255&e.charCodeAt(++n))<<24))+(59797*(t>>>16)<<16),r=1540483477*(65535&(t^=t>>>24))+(59797*(t>>>16)<<16)^1540483477*(65535&r)+(59797*(r>>>16)<<16);switch(i){case 3:r^=(255&e.charCodeAt(n+2))<<16;case 2:r^=(255&e.charCodeAt(n+1))<<8;case 1:r=1540483477*(65535&(r^=255&e.charCodeAt(n)))+(59797*(r>>>16)<<16)}return(((r=1540483477*(65535&(r^=r>>>13))+(59797*(r>>>16)<<16))^r>>>15)>>>0).toString(36)}(i)+l;return{name:c,styles:i,next:Wn}}var Un=!!q.useInsertionEffect&&q.useInsertionEffect||function(e){return e()},Gn=q.createContext("undefined"!=typeof HTMLElement?Sn({key:"css"}):null);Gn.Provider;var Xn,Jn,Yn=function(e){return v.forwardRef(function(t,r){var n=v.useContext(Gn);return e(t,n,r)})},Zn=q.createContext({}),Kn={}.hasOwnProperty,Qn="__EMOTION_TYPE_PLEASE_DO_NOT_USE__",ei=function(e,t){var r={};for(var n in t)Kn.call(t,n)&&(r[n]=t[n]);return r[Qn]=e,r},ti=function(e){var t=e.cache,r=e.serialized,n=e.isStringTag;return jn(t,r,n),Un(function(){return function(e,t,r){jn(e,t,r);var n=e.key+"-"+t.name;if(void 0===e.inserted[t.name]){var i=t;do{e.insert(t===i?"."+n:"",i,e.sheet,!0),i=i.next}while(void 0!==i)}}(t,r,n)}),null},ri=Yn(function(e,t,r){var n=e.css;"string"==typeof n&&void 0!==t.registered[n]&&(n=t.registered[n]);var i=e[Qn],o=[n],a="";"string"==typeof e.className?a=function(e,t,r){var n="";return r.split(" ").forEach(function(r){void 0!==e[r]?t.push(e[r]+";"):r&&(n+=r+" ")}),n}(t.registered,o,e.className):null!=e.className&&(a=e.className+" ");var s=qn(o,void 0,q.useContext(Zn));a+=t.key+"-"+s.name;var l={};for(var c in e)Kn.call(e,c)&&"css"!==c&&c!==Qn&&(l[c]=e[c]);return l.className=a,r&&(l.ref=r),q.createElement(q.Fragment,null,q.createElement(ti,{cache:t,serialized:s,isStringTag:"string"==typeof i}),q.createElement(i,l))}),ni=function(e,t,r){return Kn.call(t,"css")?H.jsx(ri,ei(e,t),r):H.jsx(e,t,r)},ii=function(e,t,r){return Kn.call(t,"css")?H.jsxs(ri,ei(e,t),r):H.jsxs(e,t,r)},oi=function(e,t){var r=arguments;if(null==t||!Kn.call(t,"css"))return q.createElement.apply(void 0,r);var n=r.length,i=new Array(n);i[0]=ri,i[1]=ei(e,t);for(var o=2;o<n;o++)i[o]=r[o];return q.createElement.apply(null,i)};function ai(){for(var e=arguments.length,t=new Array(e),r=0;r<e;r++)t[r]=arguments[r];return qn(t)}Xn=oi||(oi={}),Jn||(Jn=Xn.JSX||(Xn.JSX={}));const si=()=>({menuButton:T.css({minWidth:200}),popover:T.css({padding:w.tokens.spacingVerticalS,minWidth:200}),timePicker:T.css({width:"100%"})}),li=()=>({root:T.css({maxHeight:280,overflowY:"auto",padding:`${w.tokens.spacingVerticalXS} 0`}),item:T.css({cursor:"pointer"})}),ci="time",ui=(e,t,r)=>{const n=new Date(e);return n.setHours(t,r,0,0),n},hi=(e,t,r)=>{const n={hour:"numeric",minute:"2-digit",...r&&{second:"2-digit"},...t&&{hourCycle:t}};return new Intl.DateTimeFormat(void 0,n).format(e)},di=e=>`${String(e.getHours()).padStart(2,"0")}:${String(e.getMinutes()).padStart(2,"0")}`,pi=q.memo(e=>{const{onTimeSelect:t,hourCycle:r,showSeconds:n=!1,startHour:i=0,endHour:o=24,increment:a=30,dateAnchor:s}=e,l=li(),c=q.useMemo(()=>s??new Date,[s]),u=q.useMemo(()=>((e,t,r,n)=>{const i=[],o=60*t;for(let a=60*e;a<o;a+=r){const e=Math.floor(a/60),t=a%60;i.push(ui(n,e,t))}return i})(i,o,a,c),[i,o,a,c]),h=q.useCallback((e,r)=>()=>{t(e,r)},[t]);return b.jsx("div",{className:l.root,children:u.map(e=>{const t=hi(e,r,n),i=di(e);return b.jsx(w.MenuItemRadio,{name:ci,value:i,onClick:h(e,t),icon:b.jsx(P.ClockRegular,{}),className:l.item,children:t},i)})})}),fi=q.memo(e=>{const{onSelected:t,value:r,placeholder:n="Select a time",hourCycle:i,showSeconds:o=!1,startHour:a,endHour:s,increment:l=30,dateAnchor:c}=e,u=si(),h=q.useMemo(()=>((e,t)=>{const r=t?new Date(t):new Date,n=60*r.getHours()+r.getMinutes(),i=Math.ceil(n/e)*e,o=new Date(r);return o.setHours(Math.floor(i/60),i%60,0,0),o})(l,c),[l,c]),d=r??h,[p,f]=q.useState(d),[g,m]=q.useState(()=>hi(d,i,o)),[y,x]=q.useState(!1);q.useEffect(()=>{r&&(f(r),m(hi(r,i,o)))},[r,i,o]);const v=q.useCallback((e,t)=>{x(t.open)},[]),C=q.useMemo(()=>P.bundleIcon(P.ClockFilled,P.ClockRegular),[]),k=q.useMemo(()=>p?{[ci]:[di(p)]}:{[ci]:[]},[p]),S=q.useCallback((e,r)=>{f(e),m(r),t(e),x(!1)},[t]),_=q.useCallback((e,t)=>{},[]);return b.jsxs(w.Menu,{open:y,onOpenChange:v,checkedValues:k,onCheckedValueChange:_,children:[b.jsx(w.MenuTrigger,{disableButtonEnhancement:!0,children:b.jsx(w.MenuButton,{shape:"circular",icon:b.jsx(C,{}),className:u.menuButton,children:g||n})}),b.jsx(w.MenuPopover,{className:u.popover,children:b.jsx(w.MenuList,{children:b.jsx(pi,{value:p,onTimeSelect:S,hourCycle:i,showSeconds:o,startHour:a,endHour:s,increment:l,dateAnchor:c})})})]})}),gi={xs:w.tokens.spacingHorizontalXS,s:w.tokens.spacingHorizontalS,m:w.tokens.spacingHorizontalM,l:w.tokens.spacingHorizontalL,xl:w.tokens.spacingHorizontalXL,xxl:w.tokens.spacingHorizontalXXL},mi=v.memo(({direction:e="vertical",justifyContent:t="flex-start",alignItems:r="stretch",gap:n,columnGap:i,rowGap:o,margin:a,padding:s,marginTop:l,marginBottom:c,marginLeft:u,marginRight:h,paddingTop:d,paddingBottom:p,paddingLeft:f,paddingRight:g,width:m,height:y,wrap:x=!1,children:v,style:C,className:k,overflow:S,background:_})=>{const A=T.css({display:"flex",flexDirection:"horizontal"===e?"row":"column",justifyContent:t,alignItems:r,gap:n&&gi[n]?gi[n]:n,columnGap:i&&gi[i]?gi[i]:i,rowGap:o&&gi[o]?gi[o]:o,margin:a&&gi[a]?gi[a]:a,padding:s&&gi[s]?gi[s]:s,marginTop:l&&gi[l]?gi[l]:l,marginBottom:c&&gi[c]?gi[c]:c,marginLeft:u&&gi[u]?gi[u]:u,marginRight:h&&gi[h]?gi[h]:h,paddingTop:d&&gi[d]?gi[d]:d,paddingBottom:p&&gi[p]?gi[p]:p,paddingLeft:f&&gi[f]?gi[f]:f,paddingRight:g&&gi[g]?gi[g]:g,width:m,height:y,overflow:S,flexWrap:x?"wrap":"nowrap",backgroundColor:_,...C});return b.jsx("div",{className:w.mergeClasses(k,A),children:v})}),yi=e=>({styles:{loadingContainer:T.css({display:"flex",justifyContent:"center",alignItems:"center",height:"100%"}),noItemsMessage:T.css({textAlign:"center",marginTop:20}),rowSelection:T.css({":hover":{cursor:"pointer"}})}}),xi=T.css`
|
|
10
|
+
&::-webkit-scrollbar {
|
|
11
|
+
width: 5px;
|
|
12
|
+
height: 5px;
|
|
13
|
+
}
|
|
14
|
+
&::-webkit-scrollbar-track {
|
|
15
|
+
background: ${w.tokens.colorNeutralBackground4};
|
|
16
|
+
border-radius: ${w.tokens.borderRadiusMedium};
|
|
17
|
+
}
|
|
18
|
+
&::-webkit-scrollbar-thumb {
|
|
19
|
+
background: ${w.tokens.colorBrandBackground};
|
|
20
|
+
border-radius: ${w.tokens.borderRadiusMedium};
|
|
21
|
+
}
|
|
22
|
+
&::-webkit-scrollbar-thumb:hover {
|
|
23
|
+
background: ${w.tokens.colorBrandBackgroundHover};
|
|
24
|
+
}
|
|
25
|
+
`,bi=q.forwardRef((e,t)=>{const{columns:r,items:n,enableSorting:i=!1,enableResizing:o=!1,selectionMode:a="none",onSelectionChange:s,defaultSelectedItems:l=[],defaultSortState:c,onSortChange:u,columnSizingOptions:h,resizableColumnsOptions:d,noItemsMessage:p,isLoadingData:f,isLoadingDataMessage:g,dataGridBodyClassName:m,dataGridBodyStyles:y,refreshData:x,enableInfiniteScroll:v,onLoadMore:C,infiniteScrollPageSize:k,hasNextPage:S,isLoadingMore:_,autoShowLastPage:T=!0,virtualizedHeight:A=600,virtualizedItemSize:P=44,startIndex:E,onRowClick:M}=e,I=q.useMemo(()=>r.map(e=>w.createTableColumn({columnId:e.column,renderHeaderCell:()=>b.jsx(w.Body1Strong,{children:e.header}),renderCell:t=>b.jsx(w.TableCellLayout,{media:e.media?e.media(t):void 0,className:null==e?void 0:e.className,style:null==e?void 0:e.style,children:e.onRender?e.onRender(t):String(t[e.column]??"")}),compare:e.order})),[r]),L=q.useCallback(e=>n.findIndex(t=>t===e),[n]),[j,N]=q.useState(new Set(l.map(e=>L(e)))),[D,O]=q.useState(0);q.useEffect(()=>{l.length&&N(new Set(l.map(e=>L(e))))},[l,n,L]),q.useEffect(()=>{x&&N(new Set)},[x]);const[F,R]=q.useState(null),$=q.useMemo(()=>new Map(n.map((e,t)=>[e,t])),[n]);q.useEffect(()=>{"row"===a&&null!=F&&F>=n.length&&R(null)},[n,F,a]),q.useEffect(()=>{x&&"row"===a&&R(null)},[x,a]);const z=q.useRef(null),V=q.useRef(n.length),W=q.useRef(!1),H=q.useRef(!1),U=q.useRef(!1);q.useImperativeHandle(t,()=>({scrollToIndex:(e,t="auto")=>{const r=z.current;r&&"scrollToItem"in r&&r.scrollToItem(Math.max(0,e),t)},resetGrid:()=>{O(e=>e+1),V.current=0,W.current=!1,H.current=!1,U.current=!1,G.current=-1,N(new Set),R(null)},getSelectedRow:()=>null!==F&&F<n.length?{item:n[F],index:F}:null,setSelectedRow:e=>{const t=n.findIndex(t=>t===e);-1!==t&&(R(t),null==s||s([e]))}})),q.useEffect(()=>{if(!W.current&&"number"==typeof E&&z.current){const e=z.current;"scrollToItem"in e&&e.scrollToItem(Math.min(E,Math.max(n.length-1,0)),"start"),W.current=!0}},[E,n.length]),q.useEffect(()=>{const e=V.current,t=n.length,r=t>e;if(V.current=t,!T||!r||0===e)return;const i=z.current;i&&"scrollToItem"in i&&i.scrollToItem(Math.max(t-1,0),"end")},[n.length,T]);const G=q.useRef(-1),X=q.useCallback(({visibleStopIndex:e})=>{if(!v||!C)return;if(_||U.current)return;if(!H.current)return void(H.current=!0);const t=k??20;if(n.length<t)return;const r=Math.max(5,Math.ceil(t/5));e>=n.length-r&&S&&G.current!==n.length&&(G.current=n.length,U.current=!0,C())},[v,C,S,_,n.length,k]);q.useEffect(()=>{U.current&&n.length>G.current&&(U.current=!1)},[n.length]);const J=q.useMemo(()=>({overflowX:"auto",overflowY:"hidden",position:"relative"}),[]);return b.jsxs("div",{style:J,className:xi,children:[f&&b.jsx("div",{style:{display:"flex",gap:8,alignItems:"center",padding:8},children:q.isValidElement(g)?g:b.jsxs(w.Spinner,{size:"extra-tiny",children:[" ",g??"Loading data..."," "]})}),!f&&n.length?b.jsxs(B.DataGrid,{items:n,columns:I,sortable:i,onSortChange:i?(e,t)=>{u&&u(t)}:void 0,selectionMode:"none"===a||"row"===a?void 0:"multiple"===a?"multiselect":"single"===a?"single":void 0,selectedItems:j,onSelectionChange:(e,t)=>{const r=new Set;t.selectedItems.forEach(e=>{const t=Number(e);isNaN(t)||r.add(t)}),N(r),s&&s(Array.from(r).map(e=>n[e]))},defaultSortState:c,resizableColumns:o,columnSizingOptions:h,resizableColumnsOptions:d,focusMode:"cell",className:m,style:y,children:[b.jsx(B.DataGridHeader,{children:b.jsx(B.DataGridRow,{children:({renderHeaderCell:e})=>b.jsx(B.DataGridHeaderCell,{children:e()})})}),b.jsx(B.DataGridBody,{itemSize:P,height:A,width:"100%",listProps:{onItemsRendered:X},children:(e,t)=>(()=>{const r=e.item,i=$.get(r)??n.indexOf(r),o="row"===a,l=o&&F===i;return b.jsx(B.DataGridRow,{style:{...t,cursor:o?"pointer":void 0,background:l?w.tokens.colorSubtleBackgroundSelected:void 0},onClick:e=>{R(i),null==s||s([r]),null==M||M(r,i)},"aria-selected":l||void 0,children:({renderCell:e})=>b.jsx(B.DataGridCell,{children:e(r)})})})()})]},D):f||n.length?null:b.jsx("div",{children:p})]})});bi.displayName="DataGridV2";const vi=w.makeStyles({dialog:{overflow:"visible"},dialogBody:{overflow:"visible"}}),Ci=e=>{const{isOpen:t,dialogTitle:r,dialogActions:n,children:i,maxWidth:o,className:a,minHeight:s,minWidth:l,maxHeight:c}=e,u=vi();return t?b.jsx(w.Dialog,{open:t,modalType:"modal",children:b.jsxs(w.DialogSurface,{className:w.mergeClasses(u.dialog,a),style:{maxWidth:o??600,minWidth:l??200,...s?{minHeight:s}:{},...c?{maxHeight:c}:{}},children:[b.jsx(w.DialogTitle,{children:r}),b.jsx(w.DialogBody,{className:u.dialogBody,children:b.jsx(w.DialogContent,{children:i})}),b.jsx(w.DialogActions,{fluid:!0,position:"end",children:n})]})}):b.jsx(b.Fragment,{})},wi=()=>({closeButton:T.css({marginLeft:"auto",position:"absolute",top:"10px",right:"10px",zIndex:99999}),divider:T.css({width:"100%",height:"1px",backgroundColor:w.tokens.colorNeutralStroke1,marginTop:"6px"}),renderHeaderContent:T.css({display:"flex",flexDirection:"column",justifyContent:"flex-start",alignItems:"stretch",width:"100%"}),renderHeaderHeader:T.css({display:"flex",flexDirection:"column",justifyContent:"flex-start",padding:"10px",gap:"20px"}),renderHeaderFooter:T.css({display:"flex",flexDirection:"row",justifyContent:"flex-start",padding:"20px",gap:"20px"}),renderHeaderBody:T.css({display:"flex",flexDirection:"column",justifyContent:"flex-start",padding:"20px",gap:"20px"}),renderHeaderTitleContainer:T.css({display:"flex",flexDirection:"row",justifyContent:"flex-start",alignContent:"center",alignItems:"center",width:"100%"}),renderHeaderTitle:T.css({display:"-webkit-box",WebkitLineClamp:"1",WebkitBoxOrient:"vertical",textAlign:"start",textOverflow:"ellipsis",paddingTop:0,wordBreak:"break-word"}),renderHeaderDescription:T.css({display:"-webkit-box",WebkitLineClamp:"4",WebkitBoxOrient:"vertical",textAlign:"start",textOverflow:"ellipsis",wordBreak:"break-word"}),dialogTitleAndDescriptionContainer:T.css({display:"flex",flexDirection:"column",justifyContent:"start",alignItems:"start",paddingLeft:"10px",paddingRight:"20px",width:"100%"})}),ki=()=>v.useMemo(()=>({container:T.css({display:"flex",alignItems:"center",justifyContent:"center",minHeight:"200px",textAlign:"center",backgroundColor:w.tokens.colorNeutralBackground1,border:`1px solid ${w.tokens.colorNeutralStroke2}`,borderRadius:w.tokens.borderRadiusLarge,padding:`${w.tokens.spacingVerticalXXL} ${w.tokens.spacingHorizontalXXL}`,boxShadow:w.tokens.shadow4,maxWidth:"500px",margin:"20px auto"}),icon:T.css({fontSize:"48px",color:w.tokens.colorPaletteRedForeground1,animation:"pulse 2s infinite","@keyframes pulse":{"0%":{transform:"scale(1)"},"50%":{transform:"scale(1.05)"},"100%":{transform:"scale(1)"}}}),title:T.css({color:w.tokens.colorNeutralForeground1,fontWeight:w.tokens.fontWeightSemibold,textAlign:"center"}),message:T.css({color:w.tokens.colorNeutralForeground2,textAlign:"center",lineHeight:w.tokens.lineHeightBase400})}),[]),Si=w.makeStyles({root:{display:"flex",flexDirection:"row",justifyContent:"center",alignItems:"center",...w.shorthands.padding("10px"),gap:"10px"},iconClass:{width:"32px",height:"32px"},errorContainer:{display:"flex",flexDirection:"row",justifyContent:"start",alignItems:"center",gap:"10px",...w.shorthands.padding("10px"),backgroundColor:w.tokens.colorStatusDangerBackground1},errorIcon:{height:"100%"}}),_i=e=>{const{messageType:t,children:r,message:n}=e,i=Si(),[o,a]=q.useState(null),s=q.useCallback(()=>b.jsx(b.Fragment,{children:b.jsxs("div",{className:i.errorContainer,children:[b.jsx("div",{className:i.errorIcon,children:b.jsx(M.Icon,{icon:"fluent:error-circle-12-regular",width:"32",height:"32",color:w.tokens.colorStatusDangerForeground1})}),b.jsx(w.Body1,{children:n})]})}),[n,i.errorContainer,i.errorIcon]);return q.useEffect(()=>{switch(t){case Y.SUCCESS:a(b.jsx(P.CheckmarkCircle32Regular,{primaryFill:w.tokens.colorStatusSuccessForeground1}));break;case Y.INFO:a(b.jsx(P.Info32Regular,{primaryFill:w.tokens.colorStatusWarningForeground1}))}},[t]),t===Y.ERROR?b.jsx(s,{}):b.jsx(b.Fragment,{children:b.jsxs("div",{className:i.root,children:[o,b.jsx(w.Body1Strong,{children:n}),r]})})},Ti=({item:e,onSelectedItem:t})=>w.useIsOverflowItemVisible(e.id)?null:b.jsx(w.MenuItem,{icon:e.icon,onClick:()=>t(e.id),children:b.jsx("div",{children:e.name})},e.id),Ai=({items:e,onSelectedItem:t,theme:r})=>{const{ref:n,overflowCount:i,isOverflowing:o}=w.useOverflowMenu(),a=q.useMemo(()=>P.bundleIcon(P.MoreHorizontalFilled,P.MoreHorizontalRegular),[]);return o?b.jsx(w.IdPrefixProvider,{value:"menu-over-",children:b.jsx(w.FluentProvider,{theme:r,children:b.jsxs(w.Menu,{children:[b.jsx(w.MenuTrigger,{disableButtonEnhancement:!0,children:b.jsx(w.MenuButton,{appearance:"transparent",ref:n,icon:b.jsx(a,{}),"aria-label":`${i} more options`,role:"button"})}),b.jsx(w.MenuPopover,{children:b.jsx(w.MenuList,{children:e.map(e=>b.jsx(Ti,{item:e,onSelectedItem:t},e.id))})})]})})}):null},Pi=({id:e,children:t})=>w.useIsOverflowItemVisible(e)?null:b.jsx(w.MenuItem,{children:t}),Ei=v.memo(({items:e,open:t=!0,defaultOpen:r,drawerType:n="inline",size:i="small",appItem:o,header:a,footer:s,selectedKey:l,defaultSelectedKey:c,selectedCategoryKey:u,onNavigate:h,multiple:d=!0,density:p="medium",defaultOpenCategories:f,openCategories:g,onCategoryToggle:m,className:y,style:x})=>{const C=v.useMemo(()=>{const t=new Map,r=e=>{for(const n of e)t.set(n.key,n),n.children&&r(n.children)};return r(e),t},[e]),k=v.useCallback(e=>t=>{e.href&&t.preventDefault(),null==h||h(e.key,e.href)},[h]),S=v.useCallback((e,t)=>{if(!h)return;const r=C.get(t.value);r&&h(t.value,r.href)},[h,C]),_=v.useCallback((e,t)=>{null==m||m(t.value)},[m]),T=e=>b.jsx(w.NavItem,{value:e.key,href:e.href,icon:e.icon,onClick:k(e),children:e.name},e.key),A=e=>b.jsxs(w.NavCategory,{value:e.key,children:[b.jsx(w.NavCategoryItem,{icon:e.icon,children:e.name}),b.jsx(w.NavSubItemGroup,{children:e.children.map(e=>e.icon?b.jsx(w.NavItem,{value:e.key,href:e.href,icon:e.icon,onClick:k(e),children:e.name},e.key):b.jsx(w.NavSubItem,{value:e.key,href:e.href,onClick:k(e),children:e.name},e.key))})]},e.key),P=v.useMemo(()=>({flexShrink:0,...x}),[x]);return b.jsxs(w.NavDrawer,{open:t,defaultOpen:r,type:n,size:i,className:y,style:P,selectedValue:l,defaultSelectedValue:c,selectedCategoryValue:u,multiple:d,density:p,defaultOpenCategories:f,openCategories:g,onNavItemSelect:S,onNavCategoryItemToggle:_,children:[void 0!==a&&b.jsx(w.NavDrawerHeader,{children:a}),b.jsxs(w.NavDrawerBody,{children:[o&&(o.href?b.jsx(w.AppItem,{icon:o.icon,href:o.href,children:o.name}):b.jsx(w.AppItemStatic,{icon:o.icon,children:o.name})),e.map(e=>e.isSectionHeader&&e.children&&e.children.length>0?(e=>b.jsxs(v.Fragment,{children:[b.jsx(w.NavSectionHeader,{children:e.name}),e.children.map(e=>e.children&&e.children.length>0?A(e):T(e))]},e.key))(e):e.children&&e.children.length>0?A(e):T(e))]}),void 0!==s&&b.jsx(w.NavDrawerFooter,{children:s})]})});Ei.displayName="Navigation";const Mi=e=>({videoPlayerContainer:T.css({position:"relative",width:e.width,height:e.height}),reactPlayer:T.css({position:"absolute",top:0,left:0,width:"100%",height:"100%"}),playButton:T.css({position:"absolute",left:"50%",top:"50%",zIndex:1,userSelect:"none"})}),Ii=q.createContext(null);function Bi(e,t){if(e===t)return!0;if(!e||!t)return!1;if(Array.isArray(e)){if(!Array.isArray(t)||e.length!==t.length)return!1;for(let r=0;r<e.length;r++)if(!Bi(e[r],t[r]))return!1;return!0}if(Array.isArray(t))return!1;if("object"==typeof e&&"object"==typeof t){const r=Object.keys(e),n=Object.keys(t);if(r.length!==n.length)return!1;for(const i of r){if(!t.hasOwnProperty(i))return!1;if(!Bi(e[i],t[i]))return!1}return!0}return!1}function Li(e){return{longitude:e.center.lng,latitude:e.center.lat,zoom:e.zoom,pitch:e.pitch,bearing:e.bearing,padding:e.padding}}function ji(e,t){const r=t.viewState||t,n={};if("longitude"in r&&"latitude"in r&&(r.longitude!==e.center.lng||r.latitude!==e.center.lat)){const t=e.center.constructor;n.center=new t(r.longitude,r.latitude)}return"zoom"in r&&r.zoom!==e.zoom&&(n.zoom=r.zoom),"bearing"in r&&r.bearing!==e.bearing&&(n.bearing=r.bearing),"pitch"in r&&r.pitch!==e.pitch&&(n.pitch=r.pitch),r.padding&&e.padding&&!Bi(r.padding,e.padding)&&(n.padding=r.padding),n}const Ni=["type","source","source-layer","minzoom","maxzoom","filter","layout"];function Di(e){if(!e)return null;if("string"==typeof e)return e;if("toJS"in e&&(e=e.toJS()),!e.layers)return e;const t={};for(const n of e.layers)t[n.id]=n;const r=e.layers.map(e=>{let r=null;"interactive"in e&&(r=Object.assign({},e),delete r.interactive);const n=t[e.ref];if(n){r=r||Object.assign({},e),delete r.ref;for(const e of Ni)e in n&&(r[e]=n[e])}return r||e});return{...e,layers:r}}const Oi={version:8,sources:{},layers:[]},Fi={mousedown:"onMouseDown",mouseup:"onMouseUp",mouseover:"onMouseOver",mousemove:"onMouseMove",click:"onClick",dblclick:"onDblClick",mouseenter:"onMouseEnter",mouseleave:"onMouseLeave",mouseout:"onMouseOut",contextmenu:"onContextMenu",touchstart:"onTouchStart",touchend:"onTouchEnd",touchmove:"onTouchMove",touchcancel:"onTouchCancel"},Ri={movestart:"onMoveStart",move:"onMove",moveend:"onMoveEnd",dragstart:"onDragStart",drag:"onDrag",dragend:"onDragEnd",zoomstart:"onZoomStart",zoom:"onZoom",zoomend:"onZoomEnd",rotatestart:"onRotateStart",rotate:"onRotate",rotateend:"onRotateEnd",pitchstart:"onPitchStart",pitch:"onPitch",pitchend:"onPitchEnd"},$i={wheel:"onWheel",boxzoomstart:"onBoxZoomStart",boxzoomend:"onBoxZoomEnd",boxzoomcancel:"onBoxZoomCancel",resize:"onResize",load:"onLoad",render:"onRender",idle:"onIdle",remove:"onRemove",data:"onData",styledata:"onStyleData",sourcedata:"onSourceData",error:"onError"},zi=["minZoom","maxZoom","minPitch","maxPitch","maxBounds","projection","renderWorldCopies"],Vi=["scrollZoom","boxZoom","dragRotate","dragPan","keyboard","doubleClickZoom","touchZoomRotate","touchPitch"];class Wi{constructor(e,t,r){this._map=null,this._internalUpdate=!1,this._hoveredFeatures=null,this._propsedCameraUpdate=null,this._styleComponents={},this._onEvent=e=>{const t=this.props[$i[e.type]];t?t(e):"error"===e.type&&console.error(e.error)},this._onCameraEvent=e=>{if(this._internalUpdate)return;e.viewState=this._propsedCameraUpdate||Li(this._map.transform);const t=this.props[Ri[e.type]];t&&t(e)},this._onCameraUpdate=e=>this._internalUpdate?e:(this._propsedCameraUpdate=Li(e),ji(e,this.props)),this._onPointerEvent=e=>{"mousemove"!==e.type&&"mouseout"!==e.type||this._updateHover(e);const t=this.props[Fi[e.type]];t&&(this.props.interactiveLayerIds&&"mouseover"!==e.type&&"mouseout"!==e.type&&(e.features=this._hoveredFeatures||this._queryRenderedFeatures(e.point)),t(e),delete e.features)},this._MapClass=e,this.props=t,this._initialize(r)}get map(){return this._map}setProps(e){const t=this.props;this.props=e;const r=this._updateSettings(e,t),n=this._updateSize(e),i=this._updateViewState(e);this._updateStyle(e,t),this._updateStyleComponents(e),this._updateHandlers(e,t),(r||n||i&&!this._map.isMoving())&&this.redraw()}static reuse(e,t){const r=Wi.savedMaps.pop();if(!r)return null;const n=r.map,i=n.getContainer();for(t.className=i.className;i.childNodes.length>0;)t.appendChild(i.childNodes[0]);n._container=t;const o=n._resizeObserver;o&&(o.disconnect(),o.observe(t)),r.setProps({...e,styleDiffing:!1}),n.resize();const{initialViewState:a}=e;return a&&(a.bounds?n.fitBounds(a.bounds,{...a.fitBoundsOptions,duration:0}):r._updateViewState(a)),n.isStyleLoaded()?n.fire("load"):n.once("style.load",()=>n.fire("load")),n._update(),r}_initialize(e){const{props:t}=this,{mapStyle:r=Oi}=t,n={...t,...t.initialViewState,container:e,style:Di(r)},i=n.initialViewState||n.viewState||n;if(Object.assign(n,{center:[i.longitude||0,i.latitude||0],zoom:i.zoom||0,pitch:i.pitch||0,bearing:i.bearing||0}),t.gl){const e=HTMLCanvasElement.prototype.getContext;HTMLCanvasElement.prototype.getContext=()=>(HTMLCanvasElement.prototype.getContext=e,t.gl)}const o=new this._MapClass(n);i.padding&&o.setPadding(i.padding),t.cursor&&(o.getCanvas().style.cursor=t.cursor),o.transformCameraUpdate=this._onCameraUpdate,o.on("style.load",()=>{var e;this._styleComponents={light:o.getLight(),sky:o.getSky(),projection:null==(e=o.getProjection)?void 0:e.call(o),terrain:o.getTerrain()},this._updateStyleComponents(this.props)}),o.on("sourcedata",()=>{this._updateStyleComponents(this.props)});for(const a in Fi)o.on(a,this._onPointerEvent);for(const a in Ri)o.on(a,this._onCameraEvent);for(const a in $i)o.on(a,this._onEvent);this._map=o}recycle(){const e=this.map.getContainer().querySelector("[mapboxgl-children]");null==e||e.remove(),Wi.savedMaps.push(this)}destroy(){this._map.remove()}redraw(){const e=this._map;e.style&&(e._frame&&(e._frame.cancel(),e._frame=null),e._render())}_updateSize(e){const{viewState:t}=e;if(t){const e=this._map;if(t.width!==e.transform.width||t.height!==e.transform.height)return e.resize(),!0}return!1}_updateViewState(e){const t=this._map,r=t.transform;if(!t.isMoving()){const n=ji(r,e);if(Object.keys(n).length>0)return this._internalUpdate=!0,t.jumpTo(n),this._internalUpdate=!1,!0}return!1}_updateSettings(e,t){const r=this._map;let n=!1;for(const i of zi)if(i in e&&!Bi(e[i],t[i])){n=!0;const t=r[`set${i[0].toUpperCase()}${i.slice(1)}`];null==t||t.call(r,e[i])}return n}_updateStyle(e,t){if(e.cursor!==t.cursor&&(this._map.getCanvas().style.cursor=e.cursor||""),e.mapStyle!==t.mapStyle){const{mapStyle:t=Oi,styleDiffing:r=!0}=e,n={diff:r};"localIdeographFontFamily"in e&&(n.localIdeographFontFamily=e.localIdeographFontFamily),this._map.setStyle(Di(t),n)}}_updateStyleComponents({light:e,projection:t,sky:r,terrain:n}){var i,o;const a=this._map,s=this._styleComponents;a.style._loaded&&(e&&!Bi(e,s.light)&&(s.light=e,a.setLight(e)),t&&!Bi(t,s.projection)&&t!==(null==(i=s.projection)?void 0:i.type)&&(s.projection="string"==typeof t?{type:t}:t,null==(o=a.setProjection)||o.call(a,s.projection)),r&&!Bi(r,s.sky)&&(s.sky=r,a.setSky(r)),void 0===n||Bi(n,s.terrain)||n&&!a.getSource(n.source)||(s.terrain=n,a.setTerrain(n)))}_updateHandlers(e,t){const r=this._map;for(const n of Vi){const i=e[n]??!0;Bi(i,t[n]??!0)||(i?r[n].enable(i):r[n].disable())}}_queryRenderedFeatures(e){const t=this._map,{interactiveLayerIds:r=[]}=this.props;try{return t.queryRenderedFeatures(e,{layers:r.filter(t.getLayer.bind(t))})}catch{return[]}}_updateHover(e){var t;const{props:r}=this;if(r.interactiveLayerIds&&(r.onMouseMove||r.onMouseEnter||r.onMouseLeave)){const r=e.type,n=(null==(t=this._hoveredFeatures)?void 0:t.length)>0,i=this._queryRenderedFeatures(e.point),o=i.length>0;!o&&n&&(e.type="mouseleave",this._onPointerEvent(e)),this._hoveredFeatures=i,o&&!n&&(e.type="mouseenter",this._onPointerEvent(e)),e.type=r}else this._hoveredFeatures=null}}Wi.savedMaps=[];const Hi=["setMaxBounds","setMinZoom","setMaxZoom","setMinPitch","setMaxPitch","setRenderWorldCopies","setProjection","setStyle","addSource","removeSource","addLayer","removeLayer","setLayerZoomRange","setFilter","setPaintProperty","setLayoutProperty","setLight","setTerrain","setFog","remove"];function qi(e){if(!e)return null;const t=e.map,r={getMap:()=>t};for(const n of function(e){const t=new Set;let r=e;for(;r;){for(const n of Object.getOwnPropertyNames(r))"_"!==n[0]&&"function"==typeof e[n]&&"fire"!==n&&"setEventedParent"!==n&&t.add(n);r=Object.getPrototypeOf(r)}return Array.from(t)}(t))n in r||Hi.includes(n)||(r[n]=t[n].bind(t));return r}const Ui="undefined"!=typeof document?v.useLayoutEffect:v.useEffect;const Gi=q.createContext(null);const Xi=q.forwardRef(function(e,t){const r=v.useContext(Ii),[n,i]=v.useState(null),o=v.useRef(),{current:a}=v.useRef({mapLib:null,map:null});v.useEffect(()=>{const t=e.mapLib;let n,s=!0;return Promise.resolve(t||Promise.resolve().then(()=>require("./maplibre-gl-D9TSGNCf.cjs")).then(e=>e.maplibreGl)).then(t=>{if(!s)return;if(!t)throw new Error("Invalid mapLib");const l="Map"in t?t:t.default;if(!l.Map)throw new Error("Invalid mapLib");!function(e,t){const{RTLTextPlugin:r,maxParallelImageRequests:n,workerCount:i,workerUrl:o}=t;if(r&&e.getRTLTextPluginStatus&&"unavailable"===e.getRTLTextPluginStatus()){const{pluginUrl:t,lazy:n=!0}="string"==typeof r?{pluginUrl:r}:r;e.setRTLTextPlugin(t,e=>{e&&console.error(e)},n)}void 0!==n&&e.setMaxParallelImageRequests(n),void 0!==i&&e.setWorkerCount(i),void 0!==o&&e.setWorkerUrl(o)}(l,e),e.reuseMaps&&(n=Wi.reuse(e,o.current)),n||(n=new Wi(l.Map,e,o.current)),a.map=qi(n),a.mapLib=l,i(n),null==r||r.onMapMount(a.map,e.id)}).catch(t=>{const{onError:r}=e;r?r({type:"error",target:null,originalEvent:null,error:t}):console.error(t)}),()=>{s=!1,n&&(null==r||r.onMapUnmount(e.id),e.reuseMaps?n.recycle():n.destroy())}},[]),Ui(()=>{n&&n.setProps(e)}),v.useImperativeHandle(t,()=>a.map,[n]);const s=v.useMemo(()=>({position:"relative",width:"100%",height:"100%",...e.style}),[e.style]);return q.createElement("div",{id:e.id,ref:o,style:s},n&&q.createElement(Gi.Provider,{value:a},q.createElement("div",{"mapboxgl-children":"",style:{height:"100%"}},e.children)))}),Ji=/box|flex|grid|column|lineHeight|fontWeight|opacity|order|tabSize|zIndex/;function Yi(e,t){if(!e||!t)return;const r=e.style;for(const n in t){const e=t[n];Number.isFinite(e)&&!Ji.test(n)?r[n]=`${e}px`:r[n]=e}}function Zi(e,t){if(e===t)return null;const r=Ki(e),n=Ki(t),i=[];for(const o of n)r.has(o)||i.push(o);for(const o of r)n.has(o)||i.push(o);return 0===i.length?null:i}function Ki(e){return new Set(e?e.trim().split(/\s+/):[])}const Qi=v.memo(v.forwardRef((e,t)=>{const{map:r,mapLib:n}=v.useContext(Gi),i=v.useRef({props:e}),o=v.useMemo(()=>{let t=!1;q.Children.forEach(e.children,e=>{e&&(t=!0)});const r={...e,element:t?document.createElement("div"):void 0},a=new n.Marker(r);return a.setLngLat([e.longitude,e.latitude]),a.getElement().addEventListener("click",e=>{var t,r;null==(r=(t=i.current.props).onClick)||r.call(t,{type:"click",target:a,originalEvent:e})}),a.on("dragstart",e=>{var t,r;const n=e;n.lngLat=o.getLngLat(),null==(r=(t=i.current.props).onDragStart)||r.call(t,n)}),a.on("drag",e=>{var t,r;const n=e;n.lngLat=o.getLngLat(),null==(r=(t=i.current.props).onDrag)||r.call(t,n)}),a.on("dragend",e=>{var t,r;const n=e;n.lngLat=o.getLngLat(),null==(r=(t=i.current.props).onDragEnd)||r.call(t,n)}),a},[]);v.useEffect(()=>(o.addTo(r.getMap()),()=>{o.remove()}),[]);const{longitude:a,latitude:s,offset:l,style:c,draggable:u=!1,popup:h=null,rotation:d=0,rotationAlignment:p="auto",pitchAlignment:f="auto"}=e;v.useEffect(()=>{Yi(o.getElement(),c)},[c]),v.useImperativeHandle(t,()=>o,[]);const g=i.current.props;o.getLngLat().lng===a&&o.getLngLat().lat===s||o.setLngLat([a,s]),l&&!function(e,t){const r=Array.isArray(e)?e[0]:e?e.x:0,n=Array.isArray(e)?e[1]:e?e.y:0,i=Array.isArray(t)?t[0]:t?t.x:0,o=Array.isArray(t)?t[1]:t?t.y:0;return r===i&&n===o}(o.getOffset(),l)&&o.setOffset(l),o.isDraggable()!==u&&o.setDraggable(u),o.getRotation()!==d&&o.setRotation(d),o.getRotationAlignment()!==p&&o.setRotationAlignment(p),o.getPitchAlignment()!==f&&o.setPitchAlignment(f),o.getPopup()!==h&&o.setPopup(h);const m=Zi(g.className,e.className);if(m)for(const y of m)o.toggleClassName(y);return i.current.props=e,E.createPortal(e.children,o.getElement())}));function eo(e,t,r,n){const i=v.useContext(Gi),o=v.useMemo(()=>e(i),[]);return v.useEffect(()=>{const e=t,r=null,n="function"==typeof t?t:null,{map:a}=i;return a.hasControl(o)||(a.addControl(o,null==e?void 0:e.position),r&&r(i)),()=>{n&&n(i),a.hasControl(o)&&a.removeControl(o)}},[]),o}v.memo(v.forwardRef((e,t)=>{const{map:r,mapLib:n}=v.useContext(Gi),i=v.useMemo(()=>document.createElement("div"),[]),o=v.useRef({props:e}),a=v.useMemo(()=>{const t={...e},r=new n.Popup(t);return r.setLngLat([e.longitude,e.latitude]),r.once("open",e=>{var t,r;null==(r=(t=o.current.props).onOpen)||r.call(t,e)}),r},[]);if(v.useEffect(()=>{const e=e=>{var t,r;null==(r=(t=o.current.props).onClose)||r.call(t,e)};return a.on("close",e),a.setDOMContent(i).addTo(r.getMap()),()=>{a.off("close",e),a.isOpen()&&a.remove()}},[]),v.useEffect(()=>{Yi(a.getElement(),e.style)},[e.style]),v.useImperativeHandle(t,()=>a,[]),a.isOpen()){const t=o.current.props;a.getLngLat().lng===e.longitude&&a.getLngLat().lat===e.latitude||a.setLngLat([e.longitude,e.latitude]),e.offset&&!Bi(t.offset,e.offset)&&a.setOffset(e.offset),t.anchor===e.anchor&&t.maxWidth===e.maxWidth||(a.options.anchor=e.anchor,a.setMaxWidth(e.maxWidth));const r=Zi(t.className,e.className);if(r)for(const e of r)a.toggleClassName(e);o.current.props=e}return E.createPortal(e.children,i)})),v.memo(function(e){const t=eo(({mapLib:t})=>new t.AttributionControl(e),{position:e.position});return v.useEffect(()=>{Yi(t._container,e.style)},[e.style]),null}),v.memo(function(e){const t=eo(({mapLib:t})=>new t.FullscreenControl({container:e.containerId&&document.getElementById(e.containerId)}),{position:e.position});return v.useEffect(()=>{Yi(t._controlContainer,e.style)},[e.style]),null}),v.memo(v.forwardRef(function(e,t){const r=v.useRef({props:e}),n=eo(({mapLib:t})=>{const n=new t.GeolocateControl(e),i=n._setupUI;return n._setupUI=()=>{n._container.hasChildNodes()||i()},n.on("geolocate",e=>{var t,n;null==(n=(t=r.current.props).onGeolocate)||n.call(t,e)}),n.on("error",e=>{var t,n;null==(n=(t=r.current.props).onError)||n.call(t,e)}),n.on("outofmaxbounds",e=>{var t,n;null==(n=(t=r.current.props).onOutOfMaxBounds)||n.call(t,e)}),n.on("trackuserlocationstart",e=>{var t,n;null==(n=(t=r.current.props).onTrackUserLocationStart)||n.call(t,e)}),n.on("trackuserlocationend",e=>{var t,n;null==(n=(t=r.current.props).onTrackUserLocationEnd)||n.call(t,e)}),n},{position:e.position});return r.current.props=e,v.useImperativeHandle(t,()=>n,[]),v.useEffect(()=>{Yi(n._container,e.style)},[e.style]),null})),v.memo(function(e){const t=eo(({mapLib:t})=>new t.NavigationControl(e),{position:e.position});return v.useEffect(()=>{Yi(t._container,e.style)},[e.style]),null}),v.memo(function(e){const t=eo(({mapLib:t})=>new t.ScaleControl(e),{position:e.position}),r=v.useRef(e),n=r.current;r.current=e;const{style:i}=e;return void 0!==e.maxWidth&&e.maxWidth!==n.maxWidth&&(t.options.maxWidth=e.maxWidth),void 0!==e.unit&&e.unit!==n.unit&&t.setUnit(e.unit),v.useEffect(()=>{Yi(t._container,i)},[i]),null}),v.memo(function(e){const t=eo(({mapLib:t})=>new t.TerrainControl(e),{position:e.position});return v.useEffect(()=>{Yi(t._container,e.style)},[e.style]),null}),v.memo(function(e){const t=eo(({mapLib:t})=>new t.LogoControl(e),{position:e.position});return v.useEffect(()=>{Yi(t._container,e.style)},[e.style]),null});const to=T.css`
|
|
26
|
+
position: absolute;
|
|
27
|
+
top: 16px;
|
|
28
|
+
right: 16px;
|
|
29
|
+
z-index: 2;
|
|
30
|
+
background: ${w.tokens.colorNeutralBackground1};
|
|
31
|
+
border-radius: 8px;
|
|
32
|
+
box-shadow: 0 2px 6px rgba(0, 0, 0, 0.12);
|
|
33
|
+
padding: 4px;
|
|
34
|
+
display: flex;
|
|
35
|
+
gap: 8px;
|
|
36
|
+
`,ro=T.css`
|
|
37
|
+
flex-direction: column;
|
|
38
|
+
`,no=T.css`
|
|
39
|
+
min-width: 32px;
|
|
40
|
+
min-height: 32px;
|
|
41
|
+
${w.shorthands.padding("4px")}
|
|
42
|
+
`,io=({mapRef:e,initialViewState:t={longitude:0,latitude:20,zoom:1},vertical:r=!0})=>{const n=q.useCallback(()=>{var t;null==(t=e.current)||t.getMap().zoomIn()},[e]),i=q.useCallback(()=>{var t;null==(t=e.current)||t.getMap().zoomOut()},[e]),o=q.useCallback(()=>{var r;null==(r=e.current)||r.flyTo({center:[t.longitude,t.latitude],zoom:t.zoom,essential:!0})},[e,t]),a=x.useWorldMapStrings();return b.jsxs("div",{className:r?`${to} ${ro}`:to,children:[b.jsx(w.Tooltip,{content:a.zoomIn,relationship:"label",children:b.jsx(w.Button,{appearance:"subtle",icon:b.jsx(P.ZoomIn24Regular,{}),"aria-label":a.zoomIn,className:no,onClick:n})}),b.jsx(w.Tooltip,{content:a.zoomOut,relationship:"label",children:b.jsx(w.Button,{appearance:"subtle",icon:b.jsx(P.ZoomOut24Regular,{}),"aria-label":a.zoomOut,className:no,onClick:i})}),b.jsx(w.Tooltip,{content:a.resetMap,relationship:"label",children:b.jsx(w.Button,{appearance:"subtle",icon:b.jsx(P.ArrowReset24Regular,{}),"aria-label":a.reset,className:no,onClick:o})})]})},oo=T.css`
|
|
43
|
+
width: 32px;
|
|
44
|
+
height: 20px;
|
|
45
|
+
border-radius: 4px;
|
|
46
|
+
box-shadow: 0 2px 6px rgba(0,0,0,0.08);
|
|
47
|
+
border: 1px solid #ddd;
|
|
48
|
+
cursor: pointer;
|
|
49
|
+
display: block;
|
|
50
|
+
margin: 0 auto;
|
|
51
|
+
`,ao=T.css`
|
|
52
|
+
padding: 12px;
|
|
53
|
+
min-width: 120px;
|
|
54
|
+
display: flex;
|
|
55
|
+
flex-direction: column;
|
|
56
|
+
align-items: center;
|
|
57
|
+
gap: 6px;
|
|
58
|
+
`,so=T.css`
|
|
59
|
+
font-weight: 600;
|
|
60
|
+
text-align: center;
|
|
61
|
+
margin-top: 6px;
|
|
62
|
+
`,lo=({data:e,flagClass:t,onClick:r})=>b.jsx(w.Tooltip,{relationship:"label",content:b.jsxs(w.Card,{className:ao,children:[b.jsx("img",{src:e.imageUrl,alt:e.name,className:oo}),b.jsx(w.Text,{className:so,children:e.name})]}),withArrow:!0,positioning:"above",children:b.jsx("img",{src:e.imageUrl,alt:e.name,className:t||oo,onClick:()=>null==r?void 0:r(e)})});var co=(e=>(e[e.SharePoint=0]="SharePoint",e[e.Teams=1]="Teams",e[e.TeamsDark=2]="TeamsDark",e[e.TeamsHighContrast=3]="TeamsHighContrast",e))(co||{});const uo=e=>new j.HostConfig({fontFamily:e.fontFamilyBase,separator:{lineThickness:1,lineColor:e.colorNeutralStroke2},containerStyles:{default:{backgroundColor:e.colorNeutralBackground1,foregroundColors:{default:{default:e.colorNeutralForeground1,subtle:e.colorNeutralForeground2},dark:{default:e.colorNeutralForeground3,subtle:e.colorNeutralForeground4},light:{default:e.colorNeutralForeground1,subtle:e.colorNeutralForeground2},accent:{default:e.colorBrandForeground1,subtle:e.colorBrandForeground2},attention:{default:e.colorPaletteRedBackground3,subtle:e.colorPaletteRedBackground2},good:{default:e.colorPaletteGreenBackground3,subtle:e.colorPaletteGreenBackground2},warning:{default:e.colorPaletteYellowBackground3,subtle:e.colorPaletteYellowBackground2}}},emphasis:{backgroundColor:e.colorNeutralBackground3,foregroundColors:{default:{default:e.colorNeutralForeground1,subtle:e.colorNeutralForeground2},dark:{default:e.colorNeutralForeground3,subtle:e.colorNeutralForeground4},light:{default:e.colorNeutralForeground1,subtle:e.colorNeutralForeground2},accent:{default:e.colorBrandForeground1,subtle:e.colorBrandForeground2},attention:{default:e.colorPaletteRedBackground3,subtle:e.colorPaletteRedBackground2},good:{default:e.colorPaletteGreenBackground3,subtle:e.colorPaletteGreenBackground2},warning:{default:e.colorPaletteYellowBackground3,subtle:e.colorPaletteYellowBackground2}}}},inputs:{label:{requiredInputs:{weight:"bold"},optionalInputs:{weight:"bold"}},errorMessage:{color:"attention",weight:"bold"}},actions:{buttonSpacing:10,actionAlignment:"right"}}),ho="fluentUITheme",po=e=>{let t=e.hostCapabilities.getCustomProperty(ho);return t||(t=w.webLightTheme),t},fo=(e,t)=>{let r;switch(e){case co.SharePoint:r={theme:t,hostConfig:uo(t)};break;case co.Teams:r={theme:w.teamsLightTheme,hostConfig:uo(w.teamsLightTheme)};break;case co.TeamsDark:r={theme:w.teamsDarkTheme,hostConfig:uo(w.teamsDarkTheme)};break;case co.TeamsHighContrast:r={theme:w.teamsHighContrastTheme,hostConfig:uo(w.teamsHighContrastTheme)};break;default:r={theme:t,hostConfig:uo(t)}}var n,i;return r.hostConfig.cssClassNamePrefix=`ach${Math.random().toString().replace(/\./g,"")}`,n=r.hostConfig,i=r.theme,n.hostCapabilities.setCustomProperty(ho,i),((e,t)=>{const r=N.create();r.put(`.${t}-ac-container:focus`,{outline:"none !important"}),r.put(`.${t}-ac-adaptiveCard:focus`,{outline:"none !important"}),r.put(`.${t}-ac-pushButton`,{overflow:"hidden",textOverflow:"ellipsis",textAlign:"center",verticalAlign:"middle",cursor:"pointer",fontFamily:"inherit",fontSize:"14px",fontWeight:"600",padding:"4px 10px 5px 10px",WebkitUserSelect:"none",MozUserSelect:"none",MsUserSelect:"none",userSelect:"none",height:"32px",borderRadius:"2px",border:`1px solid ${e.colorNeutralStrokeAccessible}`,backgroundColor:e.colorNeutralBackground1,color:e.colorNeutralForeground1}),r.put(`.${t}-ac-pushButton:hover`,{border:`1px solid ${e.colorNeutralStrokeAccessible}`,backgroundColor:e.colorNeutralBackground2,color:e.colorNeutralForeground2}),r.put(`.${t}-ac-pushButton:active`,{border:`1px solid ${e.colorNeutralStrokeAccessible}`,backgroundColor:e.colorNeutralBackground3,color:e.colorNeutralForeground3}),r.put(`.${t}-ac-pushButton-disabled`,{overflow:"hidden",textOverflow:"ellipsis",textAlign:"center",verticalAlign:"middle",cursor:"pointer",fontFamily:"inherit",fontSize:"14px",fontWeight:"600",padding:"4px 10px 5px 10px",WebkitUserSelect:"none",MozUserSelect:"none",MsUserSelect:"none",userSelect:"none",height:"32px",borderRadius:"2px",border:`1px solid ${e.colorNeutralStrokeDisabled}`,backgroundColor:e.colorNeutralBackgroundDisabled,color:e.colorNeutralForegroundDisabled}),r.put(`.${t}-ac-ctrl-overlay`,{fontFamily:e.fontFamilyBase,position:"absolute",left:"0",top:"0",zIndex:"10000"}),r.put(`.${t}-ac-ctrl`,{boxSizing:"border-box",fontSize:"14px",fontWeight:"normal"}),r.put(`.${t}-ac-ctrl-popup-container`,{backgroundColor:e.colorNeutralBackground1,position:"absolute",overflowY:"auto",boxShadow:"0px 3.2px 7.2px rgba(0,0,0,0.13), 0px 0.6px 1.8px rgba(0,0,0,0.11)",borderRadius:"2px"}),r.put(`.${t}-ac-ctrl-popup-container:focus`,{outline:"0"}),r.put(`.${t}-ac-ctrl-slide`,{animationDuration:"0.5s",animationTimingFunction:"cubic-bezier(0.1, 0.9, 0.2, 1)"}),r.put(`.${t}-ac-ctrl-slide.${t}-ac-ctrl-slideTopToBottom`,{animationName:"fadeIn, slideTopToBottom"}),r.put(`.${t}-ac-ctrl-slide.${t}-ac-ctrl-slideBottomToTop`,{animationName:"fadeIn, slideBottomToTop"}),r.put(`.${t}-ac-ctrl-slide.${t}-ac-ctrl-slideLeftToRight`,{animationName:"fadeIn, slideLeftToRight"}),r.put(`.${t}-ac-ctrl-slide.${t}-ac-ctrl-slideRightToLeft`,{animationName:"fadeIn, slideRightToLeft"}),r.put(`.${t}-ac-ctrl-dropdown-item`,{width:"100%",textOverflow:"ellipsis",overflow:"hidden",whiteSpace:"nowrap",display:"block",padding:"0px 12px",lineHeight:"30px",cursor:"pointer",backgroundColor:e.colorNeutralBackground1,color:e.colorNeutralForeground1}),r.put(`.${t}-ac-ctrl-dropdown-item:hover`,{backgroundColor:e.colorNeutralBackground2,color:e.colorNeutralForeground2}),r.put(`.${t}-ac-ctrl-dropdown-item:focus`,{outline:"0",backgroundColor:e.colorNeutralBackground3,color:e.colorNeutralForeground3}),r.put(`.${t}-ac-ctrl-dropdown-item-disabled`,{width:"100%",textOverflow:"ellipsis",overflow:"hidden",whiteSpace:"nowrap",display:"block",padding:"0px 12px",lineHeight:"30px",cursor:"pointer",backgroundColor:e.colorNeutralBackgroundDisabled,color:e.colorNeutralForegroundDisabled})})(r.theme,r.hostConfig.cssClassNamePrefix),r};let go;try{const e=["react-dom","client"].join("/"),t=require(e);"function"==typeof t.createRoot&&(go=t.createRoot)}catch{}function mo(e){return go?go(e):{render(t){U.render(t,e)},unmount(){U.unmountComponentAtNode(e)}}}var yo={},xo={};!function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.ActionRole=e.CarouselInteractionEvent=e.LogLevel=e.RefreshMode=e.TypeErrorType=e.ContainerFitStatus=e.ValidationEvent=e.ValidationPhase=e.InputLabelPosition=e.InputTextStyle=e.ActionIconPlacement=e.FillMode=e.Orientation=e.ShowCardActionMode=e.ImageStyle=e.ActionAlignment=e.VerticalAlignment=e.HorizontalAlignment=e.TextColor=e.Spacing=e.FontType=e.TextWeight=e.InputStyle=e.TextSize=e.SizeUnit=e.ImageSetPresentationStyle=e.ImageSize=e.Size=e.ActionMode=e.ActionStyle=e.ContainerStyle=void 0;var t=function(){function e(){}return e.Default="default",e.Emphasis="emphasis",e.Accent="accent",e.Good="good",e.Attention="attention",e.Warning="warning",e}();e.ContainerStyle=t;var r=function(){function e(){}return e.Default="default",e.Positive="positive",e.Destructive="destructive",e}();e.ActionStyle=r;var n,i,o,a,s,l,c,u,h,d,p,f,g,m,y,x,b,v,C,w,k,S,_,T,A,P,E,M,I=function(){function e(){}return e.Primary="primary",e.Secondary="secondary",e}();e.ActionMode=I,(n=e.Size||(e.Size={}))[n.Auto=0]="Auto",n[n.Stretch=1]="Stretch",n[n.Small=2]="Small",n[n.Medium=3]="Medium",n[n.Large=4]="Large",(i=e.ImageSize||(e.ImageSize={}))[i.Small=0]="Small",i[i.Medium=1]="Medium",i[i.Large=2]="Large",(o=e.ImageSetPresentationStyle||(e.ImageSetPresentationStyle={}))[o.Default=0]="Default",o[o.Stacked=1]="Stacked",(a=e.SizeUnit||(e.SizeUnit={}))[a.Weight=0]="Weight",a[a.Pixel=1]="Pixel",(s=e.TextSize||(e.TextSize={}))[s.Small=0]="Small",s[s.Default=1]="Default",s[s.Medium=2]="Medium",s[s.Large=3]="Large",s[s.ExtraLarge=4]="ExtraLarge",(l=e.InputStyle||(e.InputStyle={}))[l.RevealOnHover=0]="RevealOnHover",l[l.Default=1]="Default",(c=e.TextWeight||(e.TextWeight={}))[c.Lighter=0]="Lighter",c[c.Default=1]="Default",c[c.Bolder=2]="Bolder",(u=e.FontType||(e.FontType={}))[u.Default=0]="Default",u[u.Monospace=1]="Monospace",(h=e.Spacing||(e.Spacing={}))[h.None=0]="None",h[h.Small=1]="Small",h[h.Default=2]="Default",h[h.Medium=3]="Medium",h[h.Large=4]="Large",h[h.ExtraLarge=5]="ExtraLarge",h[h.Padding=6]="Padding",(d=e.TextColor||(e.TextColor={}))[d.Default=0]="Default",d[d.Dark=1]="Dark",d[d.Light=2]="Light",d[d.Accent=3]="Accent",d[d.Good=4]="Good",d[d.Warning=5]="Warning",d[d.Attention=6]="Attention",(p=e.HorizontalAlignment||(e.HorizontalAlignment={}))[p.Left=0]="Left",p[p.Center=1]="Center",p[p.Right=2]="Right",(f=e.VerticalAlignment||(e.VerticalAlignment={}))[f.Top=0]="Top",f[f.Center=1]="Center",f[f.Bottom=2]="Bottom",(g=e.ActionAlignment||(e.ActionAlignment={}))[g.Left=0]="Left",g[g.Center=1]="Center",g[g.Right=2]="Right",g[g.Stretch=3]="Stretch",(m=e.ImageStyle||(e.ImageStyle={}))[m.Default=0]="Default",m[m.Person=1]="Person",(y=e.ShowCardActionMode||(e.ShowCardActionMode={}))[y.Inline=0]="Inline",y[y.Popup=1]="Popup",(x=e.Orientation||(e.Orientation={}))[x.Horizontal=0]="Horizontal",x[x.Vertical=1]="Vertical",(b=e.FillMode||(e.FillMode={}))[b.Cover=0]="Cover",b[b.RepeatHorizontally=1]="RepeatHorizontally",b[b.RepeatVertically=2]="RepeatVertically",b[b.Repeat=3]="Repeat",(v=e.ActionIconPlacement||(e.ActionIconPlacement={}))[v.LeftOfTitle=0]="LeftOfTitle",v[v.AboveTitle=1]="AboveTitle",(C=e.InputTextStyle||(e.InputTextStyle={}))[C.Text=0]="Text",C[C.Tel=1]="Tel",C[C.Url=2]="Url",C[C.Email=3]="Email",C[C.Password=4]="Password",(w=e.InputLabelPosition||(e.InputLabelPosition={}))[w.Inline=0]="Inline",w[w.Above=1]="Above",(k=e.ValidationPhase||(e.ValidationPhase={}))[k.Parse=0]="Parse",k[k.ToJSON=1]="ToJSON",k[k.Validation=2]="Validation",(S=e.ValidationEvent||(e.ValidationEvent={}))[S.Hint=0]="Hint",S[S.ActionTypeNotAllowed=1]="ActionTypeNotAllowed",S[S.CollectionCantBeEmpty=2]="CollectionCantBeEmpty",S[S.Deprecated=3]="Deprecated",S[S.ElementTypeNotAllowed=4]="ElementTypeNotAllowed",S[S.InteractivityNotAllowed=5]="InteractivityNotAllowed",S[S.InvalidPropertyValue=6]="InvalidPropertyValue",S[S.MissingCardType=7]="MissingCardType",S[S.PropertyCantBeNull=8]="PropertyCantBeNull",S[S.TooManyActions=9]="TooManyActions",S[S.UnknownActionType=10]="UnknownActionType",S[S.UnknownElementType=11]="UnknownElementType",S[S.UnsupportedCardVersion=12]="UnsupportedCardVersion",S[S.DuplicateId=13]="DuplicateId",S[S.UnsupportedProperty=14]="UnsupportedProperty",S[S.RequiredInputsShouldHaveLabel=15]="RequiredInputsShouldHaveLabel",S[S.RequiredInputsShouldHaveErrorMessage=16]="RequiredInputsShouldHaveErrorMessage",S[S.Other=17]="Other",(_=e.ContainerFitStatus||(e.ContainerFitStatus={}))[_.FullyInContainer=0]="FullyInContainer",_[_.Overflowing=1]="Overflowing",_[_.FullyOutOfContainer=2]="FullyOutOfContainer",(T=e.TypeErrorType||(e.TypeErrorType={}))[T.UnknownType=0]="UnknownType",T[T.ForbiddenType=1]="ForbiddenType",(A=e.RefreshMode||(e.RefreshMode={}))[A.Disabled=0]="Disabled",A[A.Manual=1]="Manual",A[A.Automatic=2]="Automatic",(P=e.LogLevel||(e.LogLevel={}))[P.Info=0]="Info",P[P.Warning=1]="Warning",P[P.Error=2]="Error",(E=e.CarouselInteractionEvent||(e.CarouselInteractionEvent={}))[E.NavigationNext=0]="NavigationNext",E[E.NavigationPrevious=1]="NavigationPrevious",E[E.Pagination=2]="Pagination",E[E.Autoplay=3]="Autoplay",(M=e.ActionRole||(e.ActionRole={}))[M.Button=0]="Button",M[M.Link=1]="Link",M[M.Tab=2]="Tab",M[M.Menu=3]="Menu",M[M.MenuItem=4]="MenuItem"}(xo);var bo={};!function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.UUID=e.SizeAndUnit=e.PaddingDefinition=e.SpacingDefinition=e.StringWithSubstitutions=e.ContentTypes=e.GlobalSettings=void 0;var t=xo,r=function(){function e(){}return e.useAdvancedTextBlockTruncation=!0,e.useAdvancedCardBottomTruncation=!1,e.useMarkdownInRadioButtonAndCheckbox=!0,e.allowMarkForTextHighlighting=!1,e.alwaysBleedSeparators=!1,e.enableFullJsonRoundTrip=!1,e.displayInputValidationErrors=!0,e.allowPreProcessingPropertyValues=!1,e.setTabIndexAtCardRoot=!0,e.enableFallback=!0,e.useWebkitLineClamp=!0,e.allowMoreThanMaxActionsInOverflowMenu=!1,e.removePaddingFromContainersWithBackgroundImage=!1,e.resetInputsDirtyStateAfterActionExecution=!0,e.applets={logEnabled:!0,logLevel:t.LogLevel.Error,maximumRetryAttempts:3,defaultTimeBetweenRetryAttempts:3e3,authPromptWidth:400,authPromptHeight:600,refresh:{mode:t.RefreshMode.Manual,timeBetweenAutomaticRefreshes:3e3,maximumConsecutiveAutomaticRefreshes:3,allowManualRefreshesAfterAutomaticRefreshes:!0}},e}();e.GlobalSettings=r,e.ContentTypes={applicationJson:"application/json",applicationXWwwFormUrlencoded:"application/x-www-form-urlencoded"};var n=function(){function t(){this._isProcessed=!1}return t.prototype.getReferencedInputs=function(e,t){if(!t)throw new Error("The referencedInputs parameter cannot be null.");if(this._original)for(var r=0,n=e;r<n.length;r++){var i=n[r];null!=new RegExp("\\{{2}("+i.id+").value\\}{2}","gi").exec(this._original)&&i.id&&(t[i.id]=i)}},t.prototype.substituteInputValues=function(t,r){if(this._processed=this._original,this._original)for(var n=/\{{2}([a-z0-9_$@]+).value\}{2}/gi,i=void 0;null!==(i=n.exec(this._original))&&this._processed;)for(var o=0,a=Object.keys(t);o<a.length;o++){var s=a[o];if(s.toLowerCase()===i[1].toLowerCase()){var l=t[s],c="";l.value&&(c=l.value),r===e.ContentTypes.applicationJson?c=(c=JSON.stringify(c)).slice(1,-1):r===e.ContentTypes.applicationXWwwFormUrlencoded&&(c=encodeURIComponent(c)),this._processed=this._processed.replace(i[0],c);break}}this._isProcessed=!0},t.prototype.getOriginal=function(){return this._original},t.prototype.get=function(){return this._isProcessed?this._processed:this._original},t.prototype.set=function(e){this._original=e,this._isProcessed=!1},t}();e.StringWithSubstitutions=n;var i=function(){return function(e,t,r,n){void 0===e&&(e=0),void 0===t&&(t=0),void 0===r&&(r=0),void 0===n&&(n=0),this.left=0,this.top=0,this.right=0,this.bottom=0,this.top=e,this.right=t,this.bottom=r,this.left=n}}();e.SpacingDefinition=i;var o=function(){return function(e,r,n,i){void 0===e&&(e=t.Spacing.None),void 0===r&&(r=t.Spacing.None),void 0===n&&(n=t.Spacing.None),void 0===i&&(i=t.Spacing.None),this.top=t.Spacing.None,this.right=t.Spacing.None,this.bottom=t.Spacing.None,this.left=t.Spacing.None,this.top=e,this.right=r,this.bottom=n,this.left=i}}();e.PaddingDefinition=o;var a=function(){function e(e,t){this.physicalSize=e,this.unit=t}return e.parse=function(r,n){void 0===n&&(n=!1);var i=new e(0,t.SizeUnit.Weight);if("number"==typeof r)return i.physicalSize=r,i;if("string"==typeof r){var o=/^([0-9]+)(px|\*)?$/g.exec(r),a=n?3:2;if(o&&o.length>=a)return i.physicalSize=parseInt(o[1]),3===o.length&&"px"===o[2]&&(i.unit=t.SizeUnit.Pixel),i}throw new Error("Invalid size: "+r)},e}();e.SizeAndUnit=a;
|
|
63
|
+
/**
|
|
64
|
+
* Fast UUID generator, RFC4122 version 4 compliant.
|
|
65
|
+
* @author Jeff Ward (jcward.com).
|
|
66
|
+
* @license MIT license
|
|
67
|
+
* @link http://stackoverflow.com/questions/105034/how-to-create-a-guid-uuid-in-javascript/21963136#21963136
|
|
68
|
+
**/
|
|
69
|
+
var s=function(){function e(){}return e.generate=function(){var t=4294967295*Math.random()|0,r=4294967295*Math.random()|0,n=4294967295*Math.random()|0,i=4294967295*Math.random()|0;return e.lut[255&t]+e.lut[t>>8&255]+e.lut[t>>16&255]+e.lut[t>>24&255]+"-"+e.lut[255&r]+e.lut[r>>8&255]+"-"+e.lut[r>>16&15|64]+e.lut[r>>24&255]+"-"+e.lut[63&n|128]+e.lut[n>>8&255]+"-"+e.lut[n>>16&255]+e.lut[n>>24&255]+e.lut[255&i]+e.lut[i>>8&255]+e.lut[i>>16&255]+e.lut[i>>24&255]},e.initialize=function(){for(var t=0;t<256;t++)e.lut[t]=(t<16?"0":"")+t.toString(16)},e.lut=[],e}();e.UUID=s,s.initialize()}(bo);var vo,Co={};Object.defineProperty(Co,"__esModule",{value:!0}),Co.debounce=Co.addCancelSelectActionEventHandler=Co.clearElementChildren=Co.getScrollY=Co.getScrollX=Co.getFitStatus=Co.truncate=Co.truncateText=Co.stringToCssColor=Co.parseEnum=Co.getEnumValueByName=Co.parseBool=Co.parseNumber=Co.parseString=Co.appendChild=Co.generateUniqueId=Co.isMobileOS=Co.isInternetExplorer=void 0;var wo=xo,ko=bo;function So(e,t){for(var r in e){var n=parseInt(r,10);if(n>=0){var i=e[r];if(i&&"string"==typeof i&&i.toLowerCase()===t.toLowerCase())return n}}}function _o(e,t,r,n,i){var o=function(){return t-e.scrollHeight>=-1};if(!o()){for(var a=function(e){var t=[],r=Ao(e,-1);for(;r<e.length;)" "===e[r]&&t.push(r),r=Ao(e,r);return t}(r),s=0,l=a.length,c=0;s<l;){var u=Math.floor((s+l)/2);n(r,a[u]),o()?(c=a[u],s=u+1):l=u}if(n(r,c),i&&t-e.scrollHeight>=i-1){for(var h=Ao(r,c);h<r.length&&(n(r,h),o());)c=h,h=Ao(r,h);n(r,c)}}}Co.isInternetExplorer=function(){return void 0!==window.document.documentMode},Co.isMobileOS=function(){var e=window.navigator.userAgent;return!!e.match(/Android/i)||!!e.match(/iPad/i)||!!e.match(/iPhone/i)},Co.generateUniqueId=function(){return"__ac-"+ko.UUID.generate()},Co.appendChild=function(e,t){t&&e.appendChild(t)},Co.parseString=function(e,t){return"string"==typeof e?e:t},Co.parseNumber=function(e,t){return"number"==typeof e?e:t},Co.parseBool=function(e,t){if("boolean"==typeof e)return e;if("string"==typeof e)switch(e.toLowerCase()){case"true":return!0;case"false":return!1;default:return t}return t},Co.getEnumValueByName=So,Co.parseEnum=function(e,t,r){if(!t)return r;var n=So(e,t);return void 0!==n?n:r},Co.stringToCssColor=function(e){if(e){var t=/#([0-9A-F]{2})([0-9A-F]{2})([0-9A-F]{2})([0-9A-F]{2})?/gi.exec(e);if(t&&t[4]){var r=parseInt(t[1],16)/255;return"rgba("+parseInt(t[2],16)+","+parseInt(t[3],16)+","+parseInt(t[4],16)+","+r+")"}}return e},Co.truncateText=function(e,t,r){_o(e,t,e.innerText,function(t,r){e.innerText=t.substring(0,r)+"..."},r)};var To="undefined"==typeof window||null===(vo=window.trustedTypes)||void 0===vo?void 0:vo.createPolicy("adaptivecards#deprecatedExportedFunctionPolicy",{createHTML:function(e){return e}});function Ao(e,t){for(t+=1;t<e.length&&"<"===e[t];)for(;t<e.length&&">"!==e[t++];);return t}Co.truncate=function(e,t,r){_o(e,t,e.innerHTML,function(t,r){var n,i=t.substring(0,r)+"...",o=null!==(n=null==To?void 0:To.createHTML(i))&&void 0!==n?n:i;e.innerHTML=o},r)},Co.getFitStatus=function(e,t){var r=e.offsetTop;return r+e.clientHeight<=t?wo.ContainerFitStatus.FullyInContainer:r<t?wo.ContainerFitStatus.Overflowing:wo.ContainerFitStatus.FullyOutOfContainer},Co.getScrollX=function(){return window.pageXOffset},Co.getScrollY=function(){return window.pageYOffset},Co.clearElementChildren=function(e){for(;e.firstChild;)e.removeChild(e.firstChild)},Co.addCancelSelectActionEventHandler=function(e){e.onclick=function(e){e.preventDefault(),e.cancelBubble=!0}},Co.debounce=function(e,t){var r;return function(){for(var n=[],i=0;i<arguments.length;i++)n[i]=arguments[i];r&&clearTimeout(r),r=setTimeout(function(){e.apply(void 0,n)},t)}};var Po={},Eo={},Mo={},Io={};Object.defineProperty(Io,"__esModule",{value:!0}),Io.Strings=void 0;var Bo=function(){function e(){}return e.errors={unknownElementType:function(e){return'Unknown element type "'.concat(e,'". Fallback will be used if present.')},unknownActionType:function(e){return'Unknown action type "'.concat(e,'". Fallback will be used if present.')},elementTypeNotAllowed:function(e){return'Element type "'.concat(e,'" is not allowed in this context.')},actionTypeNotAllowed:function(e){return'Action type "'.concat(e,'" is not allowed in this context.')},invalidPropertyValue:function(e,t){return'Invalid value "'.concat(e,'" for property "').concat(t,'".')},showCardMustHaveCard:function(){return'"An Action.ShowCard must have its "card" property set to a valid AdaptiveCard object.'},invalidColumnWidth:function(e){return'Invalid column width "'.concat(e,'" - defaulting to "auto".')},invalidCardVersion:function(e){return'Invalid card version. Defaulting to "'.concat(e,'".')},invalidVersionString:function(e){return'Invalid version string "'.concat(e,'".')},propertyValueNotSupported:function(e,t,r,n){return'Value "'.concat(e,'" for property "').concat(t,'" is supported in version ').concat(r,", but you are using version ").concat(n,".")},propertyNotSupported:function(e,t,r){return'Property "'.concat(e,'" is supported in version ').concat(t,", but you are using version ").concat(r,".")},indexOutOfRange:function(e){return"Index out of range (".concat(e,").")},elementCannotBeUsedAsInline:function(){return"RichTextBlock.addInline: the specified card element cannot be used as a RichTextBlock inline."},inlineAlreadyParented:function(){return"RichTextBlock.addInline: the specified inline already belongs to another RichTextBlock."},interactivityNotAllowed:function(){return"Interactivity is not allowed."},inputsMustHaveUniqueId:function(){return"All inputs must have a unique Id."},choiceSetMustHaveAtLeastOneChoice:function(){return"An Input.ChoiceSet must have at least one choice defined."},choiceSetChoicesMustHaveTitleAndValue:function(){return"All choices in an Input.ChoiceSet must have their title and value properties set."},propertyMustBeSet:function(e){return'Property "'.concat(e,'" must be set.')},actionHttpHeadersMustHaveNameAndValue:function(){return"All headers of an Action.Http must have their name and value properties set."},tooManyActions:function(e){return"Maximum number of actions exceeded (".concat(e,").")},tooLittleTimeDelay:function(e){return"Autoplay Delay is too short (".concat(e,").")},tooManyCarouselPages:function(e){return"Maximum number of Carousel pages exceeded (".concat(e,").")},invalidInitialPageIndex:function(e){return"InitialPage for carousel is invalid (".concat(e,").")},columnAlreadyBelongsToAnotherSet:function(){return"This column already belongs to another ColumnSet."},invalidCardType:function(){return'Invalid or missing card type. Make sure the card\'s type property is set to "AdaptiveCard".'},unsupportedCardVersion:function(e,t){return"The specified card version (".concat(e,") is not supported or still in preview. The latest released card version is ").concat(t,".")},duplicateId:function(e){return'Duplicate Id "'.concat(e,'".')},markdownProcessingNotEnabled:function(){return"Markdown processing isn't enabled. Please see https://www.npmjs.com/package/adaptivecards#supporting-markdown"},processMarkdownEventRemoved:function(){return"The processMarkdown event has been removed. Please update your code and set onProcessMarkdown instead."},elementAlreadyParented:function(){return"The element already belongs to another container."},actionAlreadyParented:function(){return"The action already belongs to another element."},elementTypeNotStandalone:function(e){return"Elements of type ".concat(e," cannot be used as standalone elements.")},invalidInputLabelWidth:function(){return"Invalid input label width. Defaulting to label width from host config."}},e.magicCodeInputCard={tryAgain:function(){return"That didn't work... let's try again."},pleaseLogin:function(){return'Please login in the popup. You will obtain a magic code. Paste that code below and select "Submit"'},enterMagicCode:function(){return"Enter magic code"},pleaseEnterMagicCodeYouReceived:function(){return"Please enter the magic code you received."},submit:function(){return"Submit"},cancel:function(){return"Cancel"},somethingWentWrong:function(){return"Something went wrong. This action can't be handled."},authenticationFailed:function(){return"Authentication failed."}},e.runtime={automaticRefreshPaused:function(){return"Automatic refresh paused."},clckToRestartAutomaticRefresh:function(){return"Click to restart."},refreshThisCard:function(){return"Refresh this card"}},e.hints={dontUseWeightedAndStrecthedColumnsInSameSet:function(){return"It is not recommended to use weighted and stretched columns in the same ColumnSet, because in such a situation stretched columns will always get the minimum amount of space."}},e.defaults={inlineActionTitle:function(){return"Inline Action"},overflowButtonText:function(){return"..."},overflowButtonTooltip:function(){return"More options"},emptyElementText:function(e){return"Empty ".concat(e)},mediaPlayerAriaLabel:function(){return"Media content"},mediaPlayerPlayMedia:function(){return"Play media"},youTubeVideoPlayer:function(){return"YouTube video player"},vimeoVideoPlayer:function(){return"Vimeo video player"},dailymotionVideoPlayer:function(){return"Dailymotion video player"},carouselNavigationPreviousTooltip:function(){return"Previous carousel page"},carouselNavigationNextTooltip:function(){return"Next carousel page"}},e}();Io.Strings=Bo;var Lo=_n&&_n.__extends||function(){var e=function(t,r){return(e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r])})(t,r)};return function(t,r){if("function"!=typeof r&&null!==r)throw new TypeError("Class extends value "+String(r)+" is not a constructor or null");function n(){this.constructor=t}e(t,r),t.prototype=null===r?Object.create(r):(n.prototype=r.prototype,new n)}}();Object.defineProperty(Mo,"__esModule",{value:!0}),Mo.SerializableObject=Mo.property=Mo.SerializableObjectSchema=Mo.CustomProperty=Mo.SerializableObjectCollectionProperty=Mo.SerializableObjectProperty=Mo.EnumProperty=Mo.ValueSetProperty=Mo.StringArrayProperty=Mo.PixelSizeProperty=Mo.NumProperty=Mo.BoolProperty=Mo.StringProperty=Mo.PropertyDefinition=Mo.BaseSerializationContext=Mo.isVersionLessOrEqual=Mo.Versions=Mo.Version=void 0;var jo=bo,No=Co,Do=xo,Oo=Io,Fo=function(){function e(e,t,r){void 0===e&&(e=1),void 0===t&&(t=1),this._isValid=!0,this._major=e,this._minor=t,this._label=r}return e.parse=function(t,r){if(t){var n=new e;n._versionString=t;var i=/(\d+).(\d+)/gi.exec(t);return null!=i&&3===i.length?(n._major=parseInt(i[1]),n._minor=parseInt(i[2])):n._isValid=!1,n._isValid||r.logParseEvent(void 0,Do.ValidationEvent.InvalidPropertyValue,Oo.Strings.errors.invalidVersionString(n._versionString)),n}},e.prototype.toString=function(){return this._isValid?this._major+"."+this._minor:this._versionString},e.prototype.toJSON=function(){return this.toString()},e.prototype.compareTo=function(e){if(!this.isValid||!e.isValid)throw new Error("Cannot compare invalid version.");return this.major>e.major?1:this.major<e.major?-1:this.minor>e.minor?1:this.minor<e.minor?-1:0},Object.defineProperty(e.prototype,"label",{get:function(){return this._label?this._label:this.toString()},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"major",{get:function(){return this._major},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"minor",{get:function(){return this._minor},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"isValid",{get:function(){return this._isValid},enumerable:!1,configurable:!0}),e}();Mo.Version=Fo;var Ro=function(){function e(){}return e.getAllDeclaredVersions=function(){var t=e,r=[];for(var n in t)if(n.match(/^v[0-9_]*$/))try{var i=t[n];i instanceof Fo&&r.push(i)}catch(o){}return r.sort(function(e,t){return e.compareTo(t)})},e.v1_0=new Fo(1,0),e.v1_1=new Fo(1,1),e.v1_2=new Fo(1,2),e.v1_3=new Fo(1,3),e.v1_4=new Fo(1,4),e.v1_5=new Fo(1,5),e.v1_6=new Fo(1,6,"1.6 Preview"),e.latest=e.v1_5,e}();Mo.Versions=Ro,Mo.isVersionLessOrEqual=function(e,t){return!(e instanceof Fo)||(!(t instanceof Fo)||t.compareTo(e)>=0)};var $o=function(){function e(e){void 0===e&&(e=Ro.latest),this._validationEvents=[],this.targetVersion=e}return e.prototype.isTemplateString=function(e){return"string"==typeof e&&e.startsWith("${")},e.prototype.tryDeleteValue=function(e,t){jo.GlobalSettings.enableFullJsonRoundTrip||delete e[t]},e.prototype.tryDeleteDefaultValue=function(e,t){jo.GlobalSettings.enableFullJsonRoundTrip&&this.isTemplateString(e[t])||delete e[t]},e.prototype.serializeValue=function(e,t,r,n,i){void 0===n&&(n=void 0),void 0===i&&(i=!1),null==r?jo.GlobalSettings.enableFullJsonRoundTrip&&!i||delete e[t]:r===n?jo.GlobalSettings.enableFullJsonRoundTrip&&!i&&this.isTemplateString(e[t])||delete e[t]:e[t]=r},e.prototype.serializeString=function(e,t,r,n){null==r?this.tryDeleteValue(e,t):r===n?this.tryDeleteDefaultValue(e,t):e[t]=r},e.prototype.serializeBool=function(e,t,r,n){null==r?this.tryDeleteValue(e,t):r===n?this.tryDeleteDefaultValue(e,t):e[t]=r},e.prototype.serializeNumber=function(e,t,r,n){null==r||isNaN(r)?this.tryDeleteValue(e,t):r===n?this.tryDeleteDefaultValue(e,t):e[t]=r},e.prototype.serializeEnum=function(e,t,r,n,i){void 0===i&&(i=void 0),null==n?this.tryDeleteValue(t,r):n===i?this.tryDeleteDefaultValue(t,r):t[r]=e[n]},e.prototype.serializeArray=function(e,t,r){var n=[];if(r)for(var i=0,o=r;i<o.length;i++){var a=o[i],s=void 0;void 0!==(s=a instanceof ea?a.toJSON(this):a.toJSON?a.toJSON():a)&&n.push(s)}0===n.length?e.hasOwnProperty(t)&&Array.isArray(e[t])&&delete e[t]:this.serializeValue(e,t,n)},e.prototype.clearEvents=function(){this._validationEvents=[]},e.prototype.logEvent=function(e,t,r,n){this._validationEvents.push({source:e,phase:t,event:r,message:n})},e.prototype.logParseEvent=function(e,t,r){this.logEvent(e,Do.ValidationPhase.Parse,t,r)},e.prototype.getEventAt=function(e){return this._validationEvents[e]},Object.defineProperty(e.prototype,"eventCount",{get:function(){return this._validationEvents.length},enumerable:!1,configurable:!0}),e}();Mo.BaseSerializationContext=$o;var zo=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return Lo(t,e),t}($o),Vo=function(){function e(t,r,n,i){this.targetVersion=t,this.name=r,this.defaultValue=n,this.onGetInitialValue=i,this.isSerializationEnabled=!0,this.sequentialNumber=e._sequentialNumber,e._sequentialNumber++}return e.prototype.getInternalName=function(){return this.name},e.prototype.parse=function(e,t,r){return t[this.name]},e.prototype.toJSON=function(e,t,r,n){n.serializeValue(t,this.name,r,this.defaultValue)},e._sequentialNumber=0,e}();Mo.PropertyDefinition=Vo;var Wo=function(e){function t(t,r,n,i,o,a){void 0===n&&(n=!0);var s=e.call(this,t,r,o,a)||this;return s.targetVersion=t,s.name=r,s.treatEmptyAsUndefined=n,s.regEx=i,s.defaultValue=o,s.onGetInitialValue=a,s}return Lo(t,e),t.prototype.parse=function(e,t,r){var n=No.parseString(t[this.name],this.defaultValue);if(!(void 0===n||""===n&&this.treatEmptyAsUndefined)&&void 0!==this.regEx&&!this.regEx.exec(n))return void r.logParseEvent(e,Do.ValidationEvent.InvalidPropertyValue,Oo.Strings.errors.invalidPropertyValue(n,this.name));return n},t.prototype.toJSON=function(e,t,r,n){n.serializeString(t,this.name,""===r&&this.treatEmptyAsUndefined?void 0:r,this.defaultValue)},t}(Vo);Mo.StringProperty=Wo;var Ho=function(e){function t(t,r,n,i){var o=e.call(this,t,r,n,i)||this;return o.targetVersion=t,o.name=r,o.defaultValue=n,o.onGetInitialValue=i,o}return Lo(t,e),t.prototype.parse=function(e,t,r){return No.parseBool(t[this.name],this.defaultValue)},t.prototype.toJSON=function(e,t,r,n){n.serializeBool(t,this.name,r,this.defaultValue)},t}(Vo);Mo.BoolProperty=Ho;var qo=function(e){function t(t,r,n,i){var o=e.call(this,t,r,n,i)||this;return o.targetVersion=t,o.name=r,o.defaultValue=n,o.onGetInitialValue=i,o}return Lo(t,e),t.prototype.parse=function(e,t,r){return No.parseNumber(t[this.name],this.defaultValue)},t.prototype.toJSON=function(e,t,r,n){n.serializeNumber(t,this.name,r,this.defaultValue)},t}(Vo);Mo.NumProperty=qo;var Uo=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return Lo(t,e),t.prototype.parse=function(e,t,r){var n=void 0,i=t[this.name];if("string"==typeof i){var o=!1;try{var a=jo.SizeAndUnit.parse(i,!0);a.unit===Do.SizeUnit.Pixel&&(n=a.physicalSize,o=!0)}catch(s){}o||r.logParseEvent(e,Do.ValidationEvent.InvalidPropertyValue,Oo.Strings.errors.invalidPropertyValue(t[this.name],this.name))}return n},t.prototype.toJSON=function(e,t,r,n){n.serializeValue(t,this.name,"number"!=typeof r||isNaN(r)?void 0:r+"px")},t}(Vo);Mo.PixelSizeProperty=Uo;var Go=function(e){function t(t,r,n,i){var o=e.call(this,t,r,n,i)||this;return o.targetVersion=t,o.name=r,o.defaultValue=n,o.onGetInitialValue=i,o}return Lo(t,e),t.prototype.parse=function(e,t,r){var n=t[this.name];if(void 0===n||!Array.isArray(n))return this.defaultValue;for(var i=[],o=0,a=n;o<a.length;o++){var s=a[o];"string"==typeof s?i.push(s):r.logParseEvent(e,Do.ValidationEvent.InvalidPropertyValue,'Invalid array value "'.concat(JSON.stringify(s),'" of type "').concat(typeof s,'" ignored for "').concat(this.name,'".'))}return i},t.prototype.toJSON=function(e,t,r,n){n.serializeArray(t,this.name,r)},t}(Vo);Mo.StringArrayProperty=Go;var Xo=function(e){function t(t,r,n,i,o){var a=e.call(this,t,r,i,o)||this;return a.targetVersion=t,a.name=r,a.values=n,a.defaultValue=i,a.onGetInitialValue=o,a}return Lo(t,e),t.prototype.isValidValue=function(e,t){for(var r=0,n=this.values;r<n.length;r++){var i=n[r];if(e.toLowerCase()===i.value.toLowerCase())return(i.targetVersion?i.targetVersion:this.targetVersion).compareTo(t.targetVersion)<=0}return!1},t.prototype.parse=function(e,t,r){var n=t[this.name];if(void 0===n)return this.defaultValue;if("string"==typeof n)for(var i=0,o=this.values;i<o.length;i++){var a=o[i];if(n.toLowerCase()===a.value.toLowerCase()){var s=a.targetVersion?a.targetVersion:this.targetVersion;return s.compareTo(r.targetVersion)<=0?a.value:(r.logParseEvent(e,Do.ValidationEvent.InvalidPropertyValue,Oo.Strings.errors.propertyValueNotSupported(n,this.name,s.toString(),r.targetVersion.toString())),this.defaultValue)}}return r.logParseEvent(e,Do.ValidationEvent.InvalidPropertyValue,Oo.Strings.errors.invalidPropertyValue(n,this.name)),this.defaultValue},t.prototype.toJSON=function(e,t,r,n){var i=!1;if(void 0!==r){i=!0;for(var o=0,a=this.values;o<a.length;o++){var s=a[o];if(s.value===r){var l=s.targetVersion?s.targetVersion:this.targetVersion;if(l.compareTo(n.targetVersion)<=0){i=!1;break}n.logEvent(e,Do.ValidationPhase.ToJSON,Do.ValidationEvent.InvalidPropertyValue,Oo.Strings.errors.propertyValueNotSupported(r,this.name,l.toString(),n.targetVersion.toString()))}}}i||n.serializeValue(t,this.name,r,this.defaultValue,!0)},t}(Vo);Mo.ValueSetProperty=Xo;var Jo=function(e){function t(t,r,n,i,o,a){var s=e.call(this,t,r,i,a)||this;if(s.targetVersion=t,s.name=r,s.enumType=n,s.defaultValue=i,s.onGetInitialValue=a,s._values=[],o)s._values=o;else for(var l in n){var c=parseInt(l,10);c>=0&&s._values.push({value:c})}return s}return Lo(t,e),t.prototype.parse=function(e,t,r){var n=t[this.name];if("string"!=typeof n)return this.defaultValue;var i=No.getEnumValueByName(this.enumType,n);if(void 0!==i)for(var o=0,a=this.values;o<a.length;o++){var s=a[o];if(s.value===i){var l=s.targetVersion?s.targetVersion:this.targetVersion;return l.compareTo(r.targetVersion)<=0?i:(r.logParseEvent(e,Do.ValidationEvent.InvalidPropertyValue,Oo.Strings.errors.propertyValueNotSupported(n,this.name,l.toString(),r.targetVersion.toString())),this.defaultValue)}}return r.logParseEvent(e,Do.ValidationEvent.InvalidPropertyValue,Oo.Strings.errors.invalidPropertyValue(n,this.name)),this.defaultValue},t.prototype.toJSON=function(e,t,r,n){var i=!1;if(void 0!==r){i=!0;for(var o=0,a=this.values;o<a.length;o++){var s=a[o];if(s.value===r){if((s.targetVersion?s.targetVersion:this.targetVersion).compareTo(n.targetVersion)<=0){i=!1;break}n.logEvent(e,Do.ValidationPhase.ToJSON,Do.ValidationEvent.InvalidPropertyValue,Oo.Strings.errors.invalidPropertyValue(r,this.name))}}}i||n.serializeEnum(this.enumType,t,this.name,r,this.defaultValue)},Object.defineProperty(t.prototype,"values",{get:function(){return this._values},enumerable:!1,configurable:!0}),t}(Vo);Mo.EnumProperty=Jo;var Yo=function(e){function t(t,r,n,i,o){void 0===i&&(i=!1);var a=e.call(this,t,r,o,function(e){return a.nullable?void 0:new a.objectType})||this;return a.targetVersion=t,a.name=r,a.objectType=n,a.nullable=i,a}return Lo(t,e),t.prototype.parse=function(e,t,r){var n=t[this.name];if(void 0===n)return this.onGetInitialValue?this.onGetInitialValue(e):this.defaultValue;var i=new this.objectType;return i.parse(n,r),i},t.prototype.toJSON=function(e,t,r,n){var i=void 0;void 0===r||r.hasAllDefaultValues()||(i=r.toJSON(n)),"object"==typeof i&&0===Object.keys(i).length&&(i=void 0),n.serializeValue(t,this.name,i,this.defaultValue,!0)},t}(Vo);Mo.SerializableObjectProperty=Yo;var Zo=function(e){function t(t,r,n,i){var o=e.call(this,t,r,void 0,function(e){return[]})||this;return o.targetVersion=t,o.name=r,o.objectType=n,o.onItemAdded=i,o}return Lo(t,e),t.prototype.parse=function(e,t,r){var n=[],i=t[this.name];if(Array.isArray(i))for(var o=0,a=i;o<a.length;o++){var s=a[o],l=new this.objectType;l.parse(s,r),n.push(l),this.onItemAdded&&this.onItemAdded(e,l)}return n.length>0?n:this.onGetInitialValue?this.onGetInitialValue(e):void 0},t.prototype.toJSON=function(e,t,r,n){n.serializeArray(t,this.name,r)},t}(Vo);Mo.SerializableObjectCollectionProperty=Zo;var Ko=function(e){function t(t,r,n,i,o,a){var s=e.call(this,t,r,o,a)||this;if(s.targetVersion=t,s.name=r,s.onParse=n,s.onToJSON=i,s.defaultValue=o,s.onGetInitialValue=a,!s.onParse)throw new Error("CustomPropertyDefinition instances must have an onParse handler.");if(!s.onToJSON)throw new Error("CustomPropertyDefinition instances must have an onToJSON handler.");return s}return Lo(t,e),t.prototype.parse=function(e,t,r){return this.onParse(e,this,t,r)},t.prototype.toJSON=function(e,t,r,n){this.onToJSON(e,this,t,r,n)},t}(Vo);Mo.CustomProperty=Ko;var Qo=function(){function e(){this._properties=[]}return e.prototype.indexOf=function(e){for(var t=0;t<this._properties.length;t++)if(this._properties[t]===e)return t;return-1},e.prototype.add=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];for(var r=0,n=e;r<n.length;r++){var i=n[r];-1===this.indexOf(i)&&this._properties.push(i)}},e.prototype.remove=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];for(var r=0,n=e;r<n.length;r++)for(var i=n[r];;){var o=this.indexOf(i);if(!(o>=0))break;this._properties.splice(o,1)}},e.prototype.getItemAt=function(e){return this._properties[e]},e.prototype.getCount=function(){return this._properties.length},e}();Mo.SerializableObjectSchema=Qo,Mo.property=function(e){return function(t,r){var n=Object.getOwnPropertyDescriptor(t,r)||{};n.get||n.set||(n.get=function(){return this.getValue(e)},n.set=function(t){this.setValue(e,t)},Object.defineProperty(t,r,n))}};var ea=function(){function e(){this._propertyBag={},this._rawProperties={},this.maxVersion=e.defaultMaxVersion;for(var t=this.getSchema(),r=0;r<t.getCount();r++){var n=t.getItemAt(r);n.onGetInitialValue&&this.setValue(n,n.onGetInitialValue(this))}}return e.prototype.getDefaultSerializationContext=function(){return new zo},e.prototype.populateSchema=function(t){var r=this.constructor,n=[];for(var i in r)try{var o=r[i];o instanceof Vo&&n.push(o)}catch(s){}if(n.length>0){var a=n.sort(function(e,t){return e.sequentialNumber>t.sequentialNumber?1:e.sequentialNumber<t.sequentialNumber?-1:0});t.add.apply(t,a)}e.onRegisterCustomProperties&&e.onRegisterCustomProperties(this,t)},e.prototype.getValue=function(e){return this._propertyBag.hasOwnProperty(e.getInternalName())?this._propertyBag[e.getInternalName()]:e.defaultValue},e.prototype.setValue=function(e,t){null==t?delete this._propertyBag[e.getInternalName()]:this._propertyBag[e.getInternalName()]=t},e.prototype.internalParse=function(e,t){if(this._propertyBag={},this._rawProperties=jo.GlobalSettings.enableFullJsonRoundTrip&&e||{},e)for(var r=this.getSchema(),n=0;n<r.getCount();n++){var i=r.getItemAt(n);if(i.isSerializationEnabled){var o=i.onGetInitialValue?i.onGetInitialValue(this):void 0;e.hasOwnProperty(i.name)&&(i.targetVersion.compareTo(t.targetVersion)<=0?o=i.parse(this,e,t):t.logParseEvent(this,Do.ValidationEvent.UnsupportedProperty,Oo.Strings.errors.propertyNotSupported(i.name,i.targetVersion.toString(),t.targetVersion.toString()))),this.setValue(i,o)}}else this.resetDefaultValues()},e.prototype.internalToJSON=function(e,t){for(var r=this.getSchema(),n=[],i=0;i<r.getCount();i++){var o=r.getItemAt(i);o.isSerializationEnabled&&o.targetVersion.compareTo(t.targetVersion)<=0&&-1===n.indexOf(o.name)&&(o.toJSON(this,e,this.getValue(o),t),n.push(o.name))}},e.prototype.shouldSerialize=function(e){return!0},e.prototype.parse=function(e,t){this.internalParse(e,t||new zo)},e.prototype.toJSON=function(e){var t;if(e&&e instanceof $o?t=e:(t=this.getDefaultSerializationContext()).toJSONOriginalParam=e,this.shouldSerialize(t)){var r=void 0;return r=jo.GlobalSettings.enableFullJsonRoundTrip&&this._rawProperties&&"object"==typeof this._rawProperties?this._rawProperties:{},this.internalToJSON(r,t),r}},e.prototype.hasDefaultValue=function(e){return this.getValue(e)===e.defaultValue},e.prototype.hasAllDefaultValues=function(){for(var e=this.getSchema(),t=0;t<e.getCount();t++){var r=e.getItemAt(t);if(!this.hasDefaultValue(r))return!1}return!0},e.prototype.resetDefaultValues=function(){for(var e=this.getSchema(),t=0;t<e.getCount();t++){var r=e.getItemAt(t);this.setValue(r,r.defaultValue)}},e.prototype.setCustomProperty=function(e,t){"string"==typeof t&&!t||null==t?delete this._rawProperties[e]:this._rawProperties[e]=t},e.prototype.getCustomProperty=function(e){return this._rawProperties[e]},e.prototype.getSchema=function(){var t=e._schemaCache[this.getSchemaKey()];return t||(t=new Qo,this.populateSchema(t),e._schemaCache[this.getSchemaKey()]=t),t},e.defaultMaxVersion=Ro.latest,e._schemaCache={},e}();Mo.SerializableObject=ea;var ta=_n&&_n.__extends||function(){var e=function(t,r){return(e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r])})(t,r)};return function(t,r){if("function"!=typeof r&&null!==r)throw new TypeError("Class extends value "+String(r)+" is not a constructor or null");function n(){this.constructor=t}e(t,r),t.prototype=null===r?Object.create(r):(n.prototype=r.prototype,new n)}}();Object.defineProperty(Eo,"__esModule",{value:!0}),Eo.HostCapabilities=void 0;var ra=Mo,na=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t._capabilities={},t}return ta(t,e),t.prototype.getSchemaKey=function(){return"HostCapabilities"},t.prototype.internalParse=function(t,r){if(e.prototype.internalParse.call(this,t,r),t)for(var n in t){var i=t[n];if("string"==typeof i)if("*"===i)this.addCapability(n,"*");else{var o=ra.Version.parse(i,r);(null==o?void 0:o.isValid)&&this.addCapability(n,o)}}},t.prototype.internalToJSON=function(t,r){for(var n in e.prototype.internalToJSON.call(this,t,r),this._capabilities)t[n]=this._capabilities[n]},t.prototype.addCapability=function(e,t){this._capabilities[e]=t},t.prototype.removeCapability=function(e){delete this._capabilities[e]},t.prototype.clear=function(){this._capabilities={}},t.prototype.hasCapability=function(e,t){return!!this._capabilities.hasOwnProperty(e)&&("*"===t||"*"===this._capabilities[e]||t.compareTo(this._capabilities[e])<=0)},t.prototype.areAllMet=function(e){for(var t in this._capabilities)if(!e.hasCapability(t,this._capabilities[t]))return!1;return!0},t}(ra.SerializableObject);Eo.HostCapabilities=na;var ia=_n&&_n.__extends||function(){var e=function(t,r){return(e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r])})(t,r)};return function(t,r){if("function"!=typeof r&&null!==r)throw new TypeError("Class extends value "+String(r)+" is not a constructor or null");function n(){this.constructor=t}e(t,r),t.prototype=null===r?Object.create(r):(n.prototype=r.prototype,new n)}}();Object.defineProperty(Po,"__esModule",{value:!0}),Po.defaultHostConfig=Po.HostConfig=Po.CarouselConfig=Po.FontTypeSet=Po.FontTypeDefinition=Po.ContainerStyleSet=Po.ContainerStyleDefinition=Po.ColorSetDefinition=Po.ActionsConfig=Po.ShowCardActionConfig=Po.FactSetConfig=Po.FactTitleDefinition=Po.FactTextDefinition=Po.InputConfig=Po.InputLabelConfig=Po.RequiredInputLabelTextDefinition=Po.TextBlockConfig=Po.TextStyleSet=Po.TextStyleDefinition=Po.BaseTextDefinition=Po.TableConfig=Po.MediaConfig=Po.ImageSetConfig=Po.AdaptiveCardConfig=Po.TextColorDefinition=Po.ColorDefinition=void 0;var oa=xo,aa=Co,sa=bo,la=Eo;function ca(e,t,r){if("string"==typeof t){var n=aa.parseEnum(e,t,r);return void 0!==n?n:r}return"number"==typeof t?t:r}var ua=function(){function e(e,t){this.default="#000000",this.subtle="#666666",e&&(this.default=e),t&&(this.subtle=t)}return e.prototype.parse=function(e){e&&(this.default=e.default||this.default,this.subtle=e.subtle||this.subtle)},e}();Po.ColorDefinition=ua;var ha=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.highlightColors=new ua("#22000000","#11000000"),t}return ia(t,e),t.prototype.parse=function(t){e.prototype.parse.call(this,t),t&&this.highlightColors.parse(t.highlightColors)},t}(ua);Po.TextColorDefinition=ha;var da=function(){return function(e){this.allowCustomStyle=!1,e&&(this.allowCustomStyle=e.allowCustomStyle||this.allowCustomStyle)}}();Po.AdaptiveCardConfig=da;var pa=function(){function e(e){this.imageSize=oa.Size.Medium,this.maxImageHeight=100,e&&(this.imageSize=null!=e.imageSize?e.imageSize:this.imageSize,this.maxImageHeight=aa.parseNumber(e.maxImageHeight,100))}return e.prototype.toJSON=function(){return{imageSize:oa.Size[this.imageSize],maxImageHeight:this.maxImageHeight}},e}();Po.ImageSetConfig=pa;var fa=function(){function e(e){this.allowInlinePlayback=!0,e&&(this.defaultPoster=e.defaultPoster,this.allowInlinePlayback=e.allowInlinePlayback||this.allowInlinePlayback)}return e.prototype.toJSON=function(){return{defaultPoster:this.defaultPoster,allowInlinePlayback:this.allowInlinePlayback}},e}();Po.MediaConfig=fa;var ga=function(){function e(e){this.cellSpacing=8,e&&(this.cellSpacing=e.cellSpacing&&"number"==typeof e.cellSpacing?e.cellSpacing:this.cellSpacing)}return e.prototype.toJSON=function(){return{cellSpacing:this.cellSpacing}},e}();Po.TableConfig=ga;var ma=function(){function e(e){this.size=oa.TextSize.Default,this.color=oa.TextColor.Default,this.isSubtle=!1,this.weight=oa.TextWeight.Default,this.parse(e)}return e.prototype.parse=function(e){e&&(this.size=ca(oa.TextSize,e.size,this.size),this.color=ca(oa.TextColor,e.color,this.color),this.isSubtle=void 0!==e.isSubtle&&"boolean"==typeof e.isSubtle?e.isSubtle:this.isSubtle,this.weight=ca(oa.TextWeight,e.weight,this.getDefaultWeight()))},e.prototype.getDefaultWeight=function(){return oa.TextWeight.Default},e.prototype.toJSON=function(){return{size:oa.TextSize[this.size],color:oa.TextColor[this.color],isSubtle:this.isSubtle,weight:oa.TextWeight[this.weight]}},e}();Po.BaseTextDefinition=ma;var ya=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.fontType=oa.FontType.Default,t}return ia(t,e),t.prototype.parse=function(t){e.prototype.parse.call(this,t),t&&(this.fontType=ca(oa.FontType,t.fontType,this.fontType))},t}(ma);Po.TextStyleDefinition=ya;var xa=function(){function e(e){this.default=new ya,this.heading=new ya({size:"Large",weight:"Bolder"}),this.columnHeader=new ya({weight:"Bolder"}),e&&(this.heading.parse(e.heading),this.columnHeader.parse(e.columnHeader))}return e.prototype.getStyleByName=function(e){switch(e.toLowerCase()){case"heading":return this.heading;case"columnHeader":return this.columnHeader;default:return this.default}},e}();Po.TextStyleSet=xa;var ba=function(){return function(e){e&&(this.headingLevel=aa.parseNumber(e.headingLevel))}}();Po.TextBlockConfig=ba;var va=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.suffix=" *",t.suffixColor=oa.TextColor.Attention,t}return ia(t,e),t.prototype.parse=function(t){e.prototype.parse.call(this,t),t&&(this.suffix=t.suffix||this.suffix,this.suffixColor=ca(oa.TextColor,t.suffixColor,this.suffixColor))},t.prototype.toJSON=function(){var t=e.prototype.toJSON.call(this);return t.suffix=this.suffix,t.suffixColor=oa.TextColor[this.suffixColor],t},t}(ma);Po.RequiredInputLabelTextDefinition=va;var Ca=function(){return function(e){this.inputSpacing=oa.Spacing.Small,this.width=30,this.requiredInputs=new va,this.optionalInputs=new ma,e&&(this.inputSpacing=ca(oa.Spacing,e.inputSpacing,this.inputSpacing),this.requiredInputs=new va(e.requiredInputs),this.optionalInputs=new ma(e.optionalInputs),this.width=null!=e.width?e.width:this.width)}}();Po.InputLabelConfig=Ca;var wa=function(){return function(e){this.label=new Ca,this.errorMessage=new ma({color:oa.TextColor.Attention}),this.debounceTimeInMilliSeconds=0,this.allowRevealOnHoverStyle=!1,e&&(this.label=new Ca(e.label),this.errorMessage=new ma(e.errorMessage),this.allowRevealOnHoverStyle=e.allowRevealOnHoverStyle||this.allowRevealOnHoverStyle,this.debounceTimeInMilliSeconds=e.debounceTimeInMilliSeconds)}}();Po.InputConfig=wa;var ka=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.wrap=!0,t}return ia(t,e),t.prototype.parse=function(t){e.prototype.parse.call(this,t),t&&(this.wrap=null!=t.wrap?t.wrap:this.wrap)},t.prototype.toJSON=function(){var t=e.prototype.toJSON.call(this);return t.wrap=this.wrap,t},t}(ma);Po.FactTextDefinition=ka;var Sa=function(e){function t(t){var r=e.call(this,t)||this;return r.maxWidth=150,r.weight=oa.TextWeight.Bolder,t&&(r.maxWidth=null!=t.maxWidth?t.maxWidth:r.maxWidth,r.weight=ca(oa.TextWeight,t.weight,oa.TextWeight.Bolder)),r}return ia(t,e),t.prototype.getDefaultWeight=function(){return oa.TextWeight.Bolder},t}(ka);Po.FactTitleDefinition=Sa;var _a=function(){return function(e){this.title=new Sa,this.value=new ka,this.spacing=10,e&&(this.title=new Sa(e.title),this.value=new ka(e.value),this.spacing=e.spacing&&null!=e.spacing?e.spacing&&e.spacing:this.spacing)}}();Po.FactSetConfig=_a;var Ta=function(){function e(e){this.actionMode=oa.ShowCardActionMode.Inline,this.inlineTopMargin=16,this.style=oa.ContainerStyle.Emphasis,e&&(this.actionMode=ca(oa.ShowCardActionMode,e.actionMode,oa.ShowCardActionMode.Inline),this.inlineTopMargin=null!=e.inlineTopMargin?e.inlineTopMargin:this.inlineTopMargin,this.style=e.style&&"string"==typeof e.style?e.style:oa.ContainerStyle.Emphasis)}return e.prototype.toJSON=function(){return{actionMode:oa.ShowCardActionMode[this.actionMode],inlineTopMargin:this.inlineTopMargin,style:this.style}},e}();Po.ShowCardActionConfig=Ta;var Aa=function(){function e(e){if(this.maxActions=5,this.spacing=oa.Spacing.Default,this.buttonSpacing=20,this.showCard=new Ta,this.preExpandSingleShowCardAction=!1,this.actionsOrientation=oa.Orientation.Horizontal,this.actionAlignment=oa.ActionAlignment.Left,this.iconPlacement=oa.ActionIconPlacement.LeftOfTitle,this.allowTitleToWrap=!1,this.iconSize=16,e){this.maxActions=null!=e.maxActions?e.maxActions:this.maxActions,this.spacing=ca(oa.Spacing,e.spacing&&e.spacing,oa.Spacing.Default),this.buttonSpacing=null!=e.buttonSpacing?e.buttonSpacing:this.buttonSpacing,this.showCard=new Ta(e.showCard),this.preExpandSingleShowCardAction=aa.parseBool(e.preExpandSingleShowCardAction,!1),this.actionsOrientation=ca(oa.Orientation,e.actionsOrientation,oa.Orientation.Horizontal),this.actionAlignment=ca(oa.ActionAlignment,e.actionAlignment,oa.ActionAlignment.Left),this.iconPlacement=ca(oa.ActionIconPlacement,e.iconPlacement,oa.ActionIconPlacement.LeftOfTitle),this.allowTitleToWrap=null!=e.allowTitleToWrap?e.allowTitleToWrap:this.allowTitleToWrap;try{var t=sa.SizeAndUnit.parse(e.iconSize);t.unit===oa.SizeUnit.Pixel&&(this.iconSize=t.physicalSize)}catch(r){}}}return e.prototype.toJSON=function(){return{maxActions:this.maxActions,spacing:oa.Spacing[this.spacing],buttonSpacing:this.buttonSpacing,showCard:this.showCard,preExpandSingleShowCardAction:this.preExpandSingleShowCardAction,actionsOrientation:oa.Orientation[this.actionsOrientation],actionAlignment:oa.ActionAlignment[this.actionAlignment]}},e}();Po.ActionsConfig=Aa;var Pa=function(){function e(e){this.default=new ha,this.dark=new ha,this.light=new ha,this.accent=new ha,this.good=new ha,this.warning=new ha,this.attention=new ha,this.parse(e)}return e.prototype.parseSingleColor=function(e,t){e&&this[t].parse(e[t])},e.prototype.parse=function(e){e&&(this.parseSingleColor(e,"default"),this.parseSingleColor(e,"dark"),this.parseSingleColor(e,"light"),this.parseSingleColor(e,"accent"),this.parseSingleColor(e,"good"),this.parseSingleColor(e,"warning"),this.parseSingleColor(e,"attention"))},e}();Po.ColorSetDefinition=Pa;var Ea=function(){function e(e){this.foregroundColors=new Pa({default:{default:"#333333",subtle:"#EE333333"},dark:{default:"#000000",subtle:"#66000000"},light:{default:"#FFFFFF",subtle:"#33000000"},accent:{default:"#2E89FC",subtle:"#882E89FC"},good:{default:"#028A02",subtle:"#DD027502"},warning:{default:"#E69500",subtle:"#DDE69500"},attention:{default:"#CC3300",subtle:"#DDCC3300"}}),this.parse(e)}return e.prototype.parse=function(e){e&&(this.backgroundColor=e.backgroundColor,this.foregroundColors.parse(e.foregroundColors),this.highlightBackgroundColor=e.highlightBackgroundColor,this.highlightForegroundColor=e.highlightForegroundColor,this.borderColor=e.borderColor)},Object.defineProperty(e.prototype,"isBuiltIn",{get:function(){return!1},enumerable:!1,configurable:!0}),e}();Po.ContainerStyleDefinition=Ea;var Ma=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return ia(t,e),Object.defineProperty(t.prototype,"isBuiltIn",{get:function(){return!0},enumerable:!1,configurable:!0}),t}(Ea),Ia=function(){function e(e){if(this._allStyles={},this._allStyles[oa.ContainerStyle.Default]=new Ma,this._allStyles[oa.ContainerStyle.Emphasis]=new Ma,this._allStyles[oa.ContainerStyle.Accent]=new Ma,this._allStyles[oa.ContainerStyle.Good]=new Ma,this._allStyles[oa.ContainerStyle.Attention]=new Ma,this._allStyles[oa.ContainerStyle.Warning]=new Ma,e){this._allStyles[oa.ContainerStyle.Default].parse(e[oa.ContainerStyle.Default]),this._allStyles[oa.ContainerStyle.Emphasis].parse(e[oa.ContainerStyle.Emphasis]),this._allStyles[oa.ContainerStyle.Accent].parse(e[oa.ContainerStyle.Accent]),this._allStyles[oa.ContainerStyle.Good].parse(e[oa.ContainerStyle.Good]),this._allStyles[oa.ContainerStyle.Attention].parse(e[oa.ContainerStyle.Attention]),this._allStyles[oa.ContainerStyle.Warning].parse(e[oa.ContainerStyle.Warning]);var t=e.customStyles;if(t&&Array.isArray(t))for(var r=0,n=t;r<n.length;r++){var i=n[r];if(i){var o=i.name;o&&"string"==typeof o&&(this._allStyles.hasOwnProperty(o)?this._allStyles[o].parse(i.style):this._allStyles[o]=new Ea(i.style))}}}}return e.prototype.toJSON=function(){var e=this,t=[];Object.keys(this._allStyles).forEach(function(r){e._allStyles[r].isBuiltIn||t.push({name:r,style:e._allStyles[r]})});var r={default:this.default,emphasis:this.emphasis};return t.length>0&&(r.customStyles=t),r},e.prototype.getStyleByName=function(e,t){return e&&this._allStyles.hasOwnProperty(e)?this._allStyles[e]:t||this._allStyles[oa.ContainerStyle.Default]},Object.defineProperty(e.prototype,"default",{get:function(){return this._allStyles[oa.ContainerStyle.Default]},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"emphasis",{get:function(){return this._allStyles[oa.ContainerStyle.Emphasis]},enumerable:!1,configurable:!0}),e}();Po.ContainerStyleSet=Ia;var Ba=function(){function e(e){this.fontFamily="Segoe UI,Segoe,Segoe WP,Helvetica Neue,Helvetica,sans-serif",this.fontSizes={small:12,default:14,medium:17,large:21,extraLarge:26},this.fontWeights={lighter:200,default:400,bolder:600},e&&(this.fontFamily=e)}return e.prototype.parse=function(e){this.fontFamily=e.fontFamily||this.fontFamily,this.fontSizes={small:e.fontSizes&&e.fontSizes.small||this.fontSizes.small,default:e.fontSizes&&e.fontSizes.default||this.fontSizes.default,medium:e.fontSizes&&e.fontSizes.medium||this.fontSizes.medium,large:e.fontSizes&&e.fontSizes.large||this.fontSizes.large,extraLarge:e.fontSizes&&e.fontSizes.extraLarge||this.fontSizes.extraLarge},this.fontWeights={lighter:e.fontWeights&&e.fontWeights.lighter||this.fontWeights.lighter,default:e.fontWeights&&e.fontWeights.default||this.fontWeights.default,bolder:e.fontWeights&&e.fontWeights.bolder||this.fontWeights.bolder}},e.monospace=new e("'Courier New', Courier, monospace"),e}();Po.FontTypeDefinition=Ba;var La=function(){function e(e){this.default=new Ba,this.monospace=new Ba("'Courier New', Courier, monospace"),e&&(this.default.parse(e.default),this.monospace.parse(e.monospace))}return e.prototype.getStyleDefinition=function(e){switch(e){case oa.FontType.Monospace:return this.monospace;case oa.FontType.Default:default:return this.default}},e}();Po.FontTypeSet=La;var ja=function(){function e(e){this.maxCarouselPages=10,this.minAutoplayDelay=5e3,e&&(this.maxCarouselPages=null!=e.maxCarouselPages?e.maxCarouselPages:this.maxCarouselPages,this.minAutoplayDelay=null!=e.minAutoplayDelay?e.minAutoplayDelay:this.minAutoplayDelay)}return e.prototype.toJSON=function(){return{maxCarouselPages:this.maxCarouselPages,minAutoplayDelay:this.minAutoplayDelay}},e}();Po.CarouselConfig=ja;var Na=function(){function e(e){this.hostCapabilities=new la.HostCapabilities,this.choiceSetInputValueSeparator=",",this.supportsInteractivity=!0,this.spacing={small:3,default:8,medium:20,large:30,extraLarge:40,padding:15},this.separator={lineThickness:1,lineColor:"#EEEEEE"},this.imageSizes={small:40,medium:80,large:160},this.containerStyles=new Ia,this.inputs=new wa,this.actions=new Aa,this.adaptiveCard=new da,this.imageSet=new pa,this.media=new fa,this.factSet=new _a,this.table=new ga,this.textStyles=new xa,this.textBlock=new ba,this.carousel=new ja,this.alwaysAllowBleed=!1,e&&(("string"==typeof e||e instanceof String)&&(e=JSON.parse(e)),this.choiceSetInputValueSeparator=e&&"string"==typeof e.choiceSetInputValueSeparator?e.choiceSetInputValueSeparator:this.choiceSetInputValueSeparator,this.supportsInteractivity=e&&"boolean"==typeof e.supportsInteractivity?e.supportsInteractivity:this.supportsInteractivity,this._legacyFontType=new Ba,this._legacyFontType.parse(e),e.fontTypes&&(this.fontTypes=new La(e.fontTypes)),e.lineHeights&&(this.lineHeights={small:e.lineHeights.small,default:e.lineHeights.default,medium:e.lineHeights.medium,large:e.lineHeights.large,extraLarge:e.lineHeights.extraLarge}),this.imageSizes={small:e.imageSizes&&e.imageSizes.small||this.imageSizes.small,medium:e.imageSizes&&e.imageSizes.medium||this.imageSizes.medium,large:e.imageSizes&&e.imageSizes.large||this.imageSizes.large},this.containerStyles=new Ia(e.containerStyles),this.spacing={small:e.spacing&&e.spacing.small||this.spacing.small,default:e.spacing&&e.spacing.default||this.spacing.default,medium:e.spacing&&e.spacing.medium||this.spacing.medium,large:e.spacing&&e.spacing.large||this.spacing.large,extraLarge:e.spacing&&e.spacing.extraLarge||this.spacing.extraLarge,padding:e.spacing&&e.spacing.padding||this.spacing.padding},this.separator={lineThickness:e.separator&&e.separator.lineThickness||this.separator.lineThickness,lineColor:e.separator&&e.separator.lineColor||this.separator.lineColor},this.inputs=new wa(e.inputs||this.inputs),this.actions=new Aa(e.actions||this.actions),this.adaptiveCard=new da(e.adaptiveCard||this.adaptiveCard),this.imageSet=new pa(e.imageSet),this.factSet=new _a(e.factSet),this.textStyles=new xa(e.textStyles),this.textBlock=new ba(e.textBlock),this.carousel=new ja(e.carousel))}return e.prototype.getFontTypeDefinition=function(e){return this.fontTypes?this.fontTypes.getStyleDefinition(e):e===oa.FontType.Monospace?Ba.monospace:this._legacyFontType},e.prototype.getEffectiveSpacing=function(e){switch(e){case oa.Spacing.Small:return this.spacing.small;case oa.Spacing.Default:return this.spacing.default;case oa.Spacing.Medium:return this.spacing.medium;case oa.Spacing.Large:return this.spacing.large;case oa.Spacing.ExtraLarge:return this.spacing.extraLarge;case oa.Spacing.Padding:return this.spacing.padding;default:return 0}},e.prototype.paddingDefinitionToSpacingDefinition=function(e){return new sa.SpacingDefinition(this.getEffectiveSpacing(e.top),this.getEffectiveSpacing(e.right),this.getEffectiveSpacing(e.bottom),this.getEffectiveSpacing(e.left))},e.prototype.makeCssClassNames=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];for(var r=[],n=0,i=e;n<i.length;n++){var o=i[n];r.push((this.cssClassNamePrefix?this.cssClassNamePrefix+"-":"")+o)}return r},e.prototype.makeCssClassName=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];var r=this.makeCssClassNames.apply(this,e).join(" ");return r||""},Object.defineProperty(e.prototype,"fontFamily",{get:function(){return this._legacyFontType.fontFamily},set:function(e){this._legacyFontType.fontFamily=e},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"fontSizes",{get:function(){return this._legacyFontType.fontSizes},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"fontWeights",{get:function(){return this._legacyFontType.fontWeights},enumerable:!1,configurable:!0}),e}();Po.HostConfig=Na,Po.defaultHostConfig=new Na({supportsInteractivity:!0,spacing:{small:10,default:20,medium:30,large:40,extraLarge:50,padding:20},separator:{lineThickness:1,lineColor:"#EEEEEE"},fontTypes:{default:{fontFamily:"'Segoe UI', Tahoma, Geneva, Verdana, sans-serif",fontSizes:{small:12,default:14,medium:17,large:21,extraLarge:26},fontWeights:{lighter:200,default:400,bolder:600}},monospace:{fontFamily:"'Courier New', Courier, monospace",fontSizes:{small:12,default:14,medium:17,large:21,extraLarge:26},fontWeights:{lighter:200,default:400,bolder:600}}},imageSizes:{small:40,medium:80,large:160},containerStyles:{default:{backgroundColor:"#FFFFFF",foregroundColors:{default:{default:"#333333",subtle:"#EE333333"},dark:{default:"#000000",subtle:"#66000000"},light:{default:"#FFFFFF",subtle:"#33000000"},accent:{default:"#2E89FC",subtle:"#882E89FC"},attention:{default:"#cc3300",subtle:"#DDcc3300"},good:{default:"#028A02",subtle:"#DD027502"},warning:{default:"#e69500",subtle:"#DDe69500"}}},emphasis:{backgroundColor:"#08000000",foregroundColors:{default:{default:"#333333",subtle:"#EE333333"},dark:{default:"#000000",subtle:"#66000000"},light:{default:"#FFFFFF",subtle:"#33000000"},accent:{default:"#2E89FC",subtle:"#882E89FC"},attention:{default:"#cc3300",subtle:"#DDcc3300"},good:{default:"#028A02",subtle:"#DD027502"},warning:{default:"#e69500",subtle:"#DDe69500"}}},accent:{backgroundColor:"#C7DEF9",foregroundColors:{default:{default:"#333333",subtle:"#EE333333"},dark:{default:"#000000",subtle:"#66000000"},light:{default:"#FFFFFF",subtle:"#33000000"},accent:{default:"#2E89FC",subtle:"#882E89FC"},attention:{default:"#cc3300",subtle:"#DDcc3300"},good:{default:"#028A02",subtle:"#DD027502"},warning:{default:"#e69500",subtle:"#DDe69500"}}},good:{backgroundColor:"#CCFFCC",foregroundColors:{default:{default:"#333333",subtle:"#EE333333"},dark:{default:"#000000",subtle:"#66000000"},light:{default:"#FFFFFF",subtle:"#33000000"},accent:{default:"#2E89FC",subtle:"#882E89FC"},attention:{default:"#cc3300",subtle:"#DDcc3300"},good:{default:"#028A02",subtle:"#DD027502"},warning:{default:"#e69500",subtle:"#DDe69500"}}},attention:{backgroundColor:"#FFC5B2",foregroundColors:{default:{default:"#333333",subtle:"#EE333333"},dark:{default:"#000000",subtle:"#66000000"},light:{default:"#FFFFFF",subtle:"#33000000"},accent:{default:"#2E89FC",subtle:"#882E89FC"},attention:{default:"#cc3300",subtle:"#DDcc3300"},good:{default:"#028A02",subtle:"#DD027502"},warning:{default:"#e69500",subtle:"#DDe69500"}}},warning:{backgroundColor:"#FFE2B2",foregroundColors:{default:{default:"#333333",subtle:"#EE333333"},dark:{default:"#000000",subtle:"#66000000"},light:{default:"#FFFFFF",subtle:"#33000000"},accent:{default:"#2E89FC",subtle:"#882E89FC"},attention:{default:"#cc3300",subtle:"#DDcc3300"},good:{default:"#028A02",subtle:"#DD027502"},warning:{default:"#e69500",subtle:"#DDe69500"}}}},inputs:{label:{requiredInputs:{weight:oa.TextWeight.Bolder,suffix:" *",suffixColor:oa.TextColor.Attention},optionalInputs:{weight:oa.TextWeight.Bolder}},errorMessage:{color:oa.TextColor.Attention,weight:oa.TextWeight.Bolder},debounceTimeInMilliSeconds:250},actions:{maxActions:5,spacing:oa.Spacing.Default,buttonSpacing:10,showCard:{actionMode:oa.ShowCardActionMode.Inline,inlineTopMargin:16},actionsOrientation:oa.Orientation.Horizontal,actionAlignment:oa.ActionAlignment.Left},adaptiveCard:{allowCustomStyle:!1},imageSet:{imageSize:oa.Size.Medium,maxImageHeight:100},factSet:{title:{color:oa.TextColor.Default,size:oa.TextSize.Default,isSubtle:!1,weight:oa.TextWeight.Bolder,wrap:!0,maxWidth:150},value:{color:oa.TextColor.Default,size:oa.TextSize.Default,isSubtle:!1,weight:oa.TextWeight.Default,wrap:!0},spacing:10},carousel:{maxCarouselPages:10,minAutoplayDuration:5e3},textBlock:{headingLevel:2}});var Da={},Oa=_n&&_n.__extends||function(){var e=function(t,r){return(e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r])})(t,r)};return function(t,r){if("function"!=typeof r&&null!==r)throw new TypeError("Class extends value "+String(r)+" is not a constructor or null");function n(){this.constructor=t}e(t,r),t.prototype=null===r?Object.create(r):(n.prototype=r.prototype,new n)}}();Object.defineProperty(Da,"__esModule",{value:!0}),Da.formatText=void 0;var Fa=function(){function e(e){this._regularExpression=e}return e.prototype.format=function(e,t){var r;if(t){for(var n=t;null!=(r=this._regularExpression.exec(t));)n=n.replace(r[0],this.internalFormat(e,r));return n}return t},e}(),Ra=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return Oa(t,e),t.prototype.internalFormat=function(e,t){var r=new Date(Date.parse(t[1])),n=void 0!==t[2]?t[2].toLowerCase():"compact";return"compact"!==n?r.toLocaleDateString(e,{day:"numeric",weekday:n,month:n,year:"numeric"}):r.toLocaleDateString()},t}(Fa),$a=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return Oa(t,e),t.prototype.internalFormat=function(e,t){return new Date(Date.parse(t[1])).toLocaleTimeString(e,{hour:"numeric",minute:"2-digit"})},t}(Fa);Da.formatText=function(e,t){for(var r=t,n=0,i=[new Ra(/\{{2}DATE\((\d{4}-\d{2}-\d{2}T\d{2}:\d{2}:\d{2}(?:Z|(?:(?:-|\+)\d{2}:\d{2})))(?:, ?(COMPACT|LONG|SHORT))?\)\}{2}/g),new $a(/\{{2}TIME\((\d{4}-\d{2}-\d{2}T\d{2}:\d{2}:\d{2}(?:Z|(?:(?:-|\+)\d{2}:\d{2})))\)\}{2}/g)];n<i.length;n++){r=i[n].format(e,r)}return r};var za={},Va=_n&&_n.__extends||function(){var e=function(t,r){return(e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r])})(t,r)};return function(t,r){if("function"!=typeof r&&null!==r)throw new TypeError("Class extends value "+String(r)+" is not a constructor or null");function n(){this.constructor=t}e(t,r),t.prototype=null===r?Object.create(r):(n.prototype=r.prototype,new n)}}(),Wa=_n&&_n.__decorate||function(e,t,r,n){var i,o=arguments.length,a=o<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,r):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,r,n);else for(var s=e.length-1;s>=0;s--)(i=e[s])&&(a=(o<3?i(a):o>3?i(t,r,a):i(t,r))||a);return o>3&&a&&Object.defineProperty(t,r,a),a};Object.defineProperty(za,"__esModule",{value:!0}),za.CardObject=za.ValidationResults=void 0;var Ha=xo,qa=Io,Ua=bo,Ga=Eo,Xa=Mo,Ja=function(){function e(){this.allIds={},this.validationEvents=[]}return e.prototype.addFailure=function(e,t,r){this.validationEvents.push({phase:Ha.ValidationPhase.Validation,source:e,event:t,message:r})},e}();za.ValidationResults=Ja;var Ya=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t._shouldFallback=!1,t}return Va(t,e),t.prototype.getSchemaKey=function(){return this.getJsonTypeName()},Object.defineProperty(t.prototype,"requires",{get:function(){return this.getValue(t.requiresProperty)},enumerable:!1,configurable:!0}),t.prototype.contains=function(e){return!!this._renderedElement&&this._renderedElement.contains(e)},t.prototype.preProcessPropertyValue=function(e,t){var r=void 0===t?this.getValue(e):t;if(Ua.GlobalSettings.allowPreProcessingPropertyValues){for(var n=this;n&&!n.onPreProcessPropertyValue;)n=n.parent;if(n&&n.onPreProcessPropertyValue)return n.onPreProcessPropertyValue(this,e,r)}return r},t.prototype.setParent=function(e){this._parent=e},t.prototype.setShouldFallback=function(e){this._shouldFallback=e},t.prototype.shouldFallback=function(){return this._shouldFallback||!this.requires.areAllMet(this.hostConfig.hostCapabilities)},t.prototype.getRootObject=function(){for(var e=this;e.parent;)e=e.parent;return e},t.prototype.internalValidateProperties=function(e){this.id&&(e.allIds.hasOwnProperty(this.id)?(1===e.allIds[this.id]&&e.addFailure(this,Ha.ValidationEvent.DuplicateId,qa.Strings.errors.duplicateId(this.id)),e.allIds[this.id]+=1):e.allIds[this.id]=1)},t.prototype.validateProperties=function(){var e=new Ja;return this.internalValidateProperties(e),e},t.prototype.findDOMNodeOwner=function(e){return this.contains(e)?this:void 0},t.prototype.releaseDOMResources=function(){},Object.defineProperty(t.prototype,"parent",{get:function(){return this._parent},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"renderedElement",{get:function(){return this._renderedElement},enumerable:!1,configurable:!0}),t.typeNameProperty=new Xa.StringProperty(Xa.Versions.v1_0,"type",void 0,void 0,void 0,function(e){return e.getJsonTypeName()}),t.idProperty=new Xa.StringProperty(Xa.Versions.v1_0,"id"),t.requiresProperty=new Xa.SerializableObjectProperty(Xa.Versions.v1_2,"requires",Ga.HostCapabilities,!1,new Ga.HostCapabilities),Wa([(0,Xa.property)(t.idProperty)],t.prototype,"id",void 0),Wa([(0,Xa.property)(t.requiresProperty)],t.prototype,"requires",null),t}(Xa.SerializableObject);za.CardObject=Ya;var Za={};Object.defineProperty(Za,"__esModule",{value:!0}),Za.GlobalRegistry=Za.CardObjectRegistry=void 0;var Ka=Mo,Qa=function(){function e(){this._items={}}return e.prototype.findByName=function(e){return this._items.hasOwnProperty(e)?this._items[e]:void 0},e.prototype.clear=function(){this._items={}},e.prototype.copyTo=function(e){for(var t=0,r=Object.keys(this._items);t<r.length;t++){var n=r[t],i=this._items[n];e.register(i.typeName,i.objectType,i.schemaVersion)}},e.prototype.register=function(e,t,r){void 0===r&&(r=Ka.Versions.v1_0);var n=this.findByName(e);void 0!==n?n.objectType=t:n={typeName:e,objectType:t,schemaVersion:r},this._items[e]=n},e.prototype.unregister=function(e){delete this._items[e]},e.prototype.createInstance=function(e,t){var r=this.findByName(e);return r&&r.schemaVersion.compareTo(t)<=0?new r.objectType:void 0},e.prototype.getItemCount=function(){return Object.keys(this._items).length},e.prototype.getItemAt=function(e){var t=this;return Object.keys(this._items).map(function(e){return t._items[e]})[e]},e}();Za.CardObjectRegistry=Qa;var es=function(){function e(){}return e.populateWithDefaultElements=function(t){t.clear(),e.defaultElements.copyTo(t)},e.populateWithDefaultActions=function(t){t.clear(),e.defaultActions.copyTo(t)},Object.defineProperty(e,"elements",{get:function(){return e._elements||(e._elements=new Qa,e.populateWithDefaultElements(e._elements)),e._elements},enumerable:!1,configurable:!0}),Object.defineProperty(e,"actions",{get:function(){return e._actions||(e._actions=new Qa,e.populateWithDefaultActions(e._actions)),e._actions},enumerable:!1,configurable:!0}),e.reset=function(){e._elements=void 0,e._actions=void 0},e.defaultElements=new Qa,e.defaultActions=new Qa,e}();Za.GlobalRegistry=es;var ts={},rs={},ns={};Object.defineProperty(ns,"__esModule",{value:!0}),ns.Constants=void 0;var is=function(){function e(){}return e.keys={tab:"Tab",enter:"Enter",escape:"Escape",space:" ",up:"ArrowUp",down:"ArrowDown",delete:"Delete"},e}();ns.Constants=is,Object.defineProperty(rs,"__esModule",{value:!0}),rs.MenuItem=void 0;var os=Po,as=ns,ss=function(){function e(e,t){this._isEnabled=!0,this.key=e,this._value=t}return e.prototype.click=function(){this.isEnabled&&this.onClick&&this.onClick(this)},e.prototype.updateCssClasses=function(){if(this._element){var e=this._hostConfig?this._hostConfig:os.defaultHostConfig;this._element.className=e.makeCssClassName("ac-ctrl"),this._element.classList.add(e.makeCssClassName(this.isEnabled?"ac-ctrl-dropdown-item":"ac-ctrl-dropdown-item-disabled")),this.isEnabled||this._element.classList.add(e.makeCssClassName("ac-disabled"))}},e.prototype.toString=function(){return this.value},e.prototype.render=function(e){var t=this;return this._hostConfig=e,this._element||(this._element=document.createElement("span"),this._element.innerText=this.value,this._element.setAttribute("role","menuitem"),this.isEnabled||this._element.setAttribute("aria-disabled","true"),this._element.setAttribute("aria-current","false"),this._element.onmouseup=function(e){t.click()},this._element.onkeydown=function(e){e.key===as.Constants.keys.enter&&(e.cancelBubble=!0,t.click())},this.updateCssClasses()),this._element},Object.defineProperty(e.prototype,"value",{get:function(){return this._value},set:function(e){this._value=e,this._element&&(this._element.innerText=e)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"isEnabled",{get:function(){return this._isEnabled},set:function(e){this._isEnabled!==e&&(this._isEnabled=e,this.updateCssClasses())},enumerable:!1,configurable:!0}),e}();rs.MenuItem=ss;var ls={},cs={};Object.defineProperty(cs,"__esModule",{value:!0}),cs.Collection=void 0;var us=function(){function e(){this._items=[]}return e.prototype.get=function(e){return this._items[e]},e.prototype.add=function(e){this._items.push(e),this.onItemAdded&&this.onItemAdded(e)},e.prototype.remove=function(e){var t=this._items.indexOf(e);t>=0&&(this._items=this._items.splice(t,1),this.onItemRemoved&&this.onItemRemoved(e))},e.prototype.indexOf=function(e){return this._items.indexOf(e)},Object.defineProperty(e.prototype,"length",{get:function(){return this._items.length},enumerable:!1,configurable:!0}),e}();cs.Collection=us;var hs={};Object.defineProperty(hs,"__esModule",{value:!0}),hs.PopupControl=void 0;var ds=ns,ps=Co,fs=Po,gs=function(){function e(){this._isOpen=!1}return e.prototype.keyDown=function(e){if(e.key===ds.Constants.keys.escape)this.closePopup(!0)},e.prototype.render=function(e){var t=this,r=document.createElement("div");return r.tabIndex=0,r.className=this.hostConfig.makeCssClassName("ac-ctrl","ac-ctrl-popup-container"),r.setAttribute("role","dialog"),r.setAttribute("aria-modal","true"),r.onkeydown=function(e){return t.keyDown(e),!e.cancelBubble},r.appendChild(this.renderContent()),r},e.prototype.focus=function(){this._popupElement&&this._popupElement.firstElementChild.focus()},e.prototype.popup=function(e){var t,r,n,i,o,a=this;if(!this._isOpen){this._overlayElement=document.createElement("div"),this._overlayElement.className=this.hostConfig.makeCssClassName("ac-ctrl-overlay"),this._overlayElement.tabIndex=0,this._overlayElement.style.width=document.documentElement.scrollWidth+"px",this._overlayElement.style.height=document.documentElement.scrollHeight+"px",this._overlayElement.onfocus=function(e){a.closePopup(!0)},document.body.appendChild(this._overlayElement);var s=e.getBoundingClientRect();this._popupElement=this.render(s),(t=this._popupElement.classList).remove.apply(t,this.hostConfig.makeCssClassNames("ac-ctrl-slide","ac-ctrl-slideLeftToRight","ac-ctrl-slideRightToLeft","ac-ctrl-slideTopToBottom","ac-ctrl-slideRightToLeft")),window.addEventListener("resize",function(e){a.closePopup(!0)});var l=e.getAttribute("aria-label");l&&this._popupElement.setAttribute("aria-label",l),this._overlayElement.appendChild(this._popupElement);var c,u=this._popupElement.getBoundingClientRect(),h=window.innerHeight-s.bottom,d=s.top,p=window.innerWidth-s.right,f=s.left,g=s.left+ps.getScrollX();if(d<u.height&&h<u.height){var m=Math.min(u.height,window.innerHeight);if(this._popupElement.style.maxHeight=m+"px",c=m<u.height?ps.getScrollY():ps.getScrollY()+s.top+(s.height-m)/2,f<u.width&&p<u.width){var y=Math.min(u.width,window.innerWidth);this._popupElement.style.maxWidth=y+"px",g=y<u.width?ps.getScrollX():ps.getScrollX()+s.left+(s.width-y)/2}else p>=u.width?(g=ps.getScrollX()+s.right,(r=this._popupElement.classList).add.apply(r,this.hostConfig.makeCssClassNames("ac-ctrl-slide","ac-ctrl-slideLeftToRight"))):(g=ps.getScrollX()+s.left-u.width,(n=this._popupElement.classList).add.apply(n,this.hostConfig.makeCssClassNames("ac-ctrl-slide","ac-ctrl-slideRightToLeft")))}else h>=u.height?(c=ps.getScrollY()+s.bottom,(i=this._popupElement.classList).add.apply(i,this.hostConfig.makeCssClassNames("ac-ctrl-slide","ac-ctrl-slideTopToBottom"))):(c=ps.getScrollY()+s.top-u.height,(o=this._popupElement.classList).add.apply(o,this.hostConfig.makeCssClassNames("ac-ctrl-slide","ac-ctrl-slideBottomToTop"))),p<u.width&&(g=ps.getScrollX()+s.right-u.width);this._popupElement.style.left=g+"px",this._popupElement.style.top=c+"px",this._popupElement.focus(),this._isOpen=!0}},e.prototype.closePopup=function(e){this._isOpen&&(document.body.removeChild(this._overlayElement),this._isOpen=!1,this.onClose&&this.onClose(this,e))},Object.defineProperty(e.prototype,"hostConfig",{get:function(){return this._hostConfig?this._hostConfig:fs.defaultHostConfig},set:function(e){this._hostConfig=e},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"isOpen",{get:function(){return this._isOpen},enumerable:!1,configurable:!0}),e}();hs.PopupControl=gs;var ms=_n&&_n.__extends||function(){var e=function(t,r){return(e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r])})(t,r)};return function(t,r){if("function"!=typeof r&&null!==r)throw new TypeError("Class extends value "+String(r)+" is not a constructor or null");function n(){this.constructor=t}e(t,r),t.prototype=null===r?Object.create(r):(n.prototype=r.prototype,new n)}}();Object.defineProperty(ls,"__esModule",{value:!0}),ls.PopupMenu=void 0;var ys,xs,bs,vs=ns,Cs=cs,ws=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t._items=new Cs.Collection,t._renderedItems=[],t._selectedIndex=-1,t}return ms(t,e),t.prototype.renderContent=function(){var e=document.createElement("div");e.className=this.hostConfig.makeCssClassName("ac-ctrl ac-popup"),e.setAttribute("role","listbox");for(var t=0;t<this._items.length;t++){var r=this._items.get(t).render(this.hostConfig);r.tabIndex=0,e.appendChild(r),t===this.selectedIndex&&r.focus(),this._renderedItems.push(r)}return e},t.prototype.keyDown=function(t){e.prototype.keyDown.call(this,t);var r=this._selectedIndex;switch(t.key){case vs.Constants.keys.tab:this.closePopup(!0);break;case vs.Constants.keys.up:(r<=0||--r<0)&&(r=this._renderedItems.length-1),this.selectedIndex=r,t.cancelBubble=!0;break;case vs.Constants.keys.down:(r<0||++r>=this._renderedItems.length)&&(r=0),this.selectedIndex=r,t.cancelBubble=!0}},Object.defineProperty(t.prototype,"items",{get:function(){return this._items},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"selectedIndex",{get:function(){return this._selectedIndex},set:function(e){e>=0&&e<this._renderedItems.length&&(this._renderedItems[e].focus(),this._selectedIndex=e)},enumerable:!1,configurable:!0}),t}(hs.PopupControl);ls.PopupMenu=ws,ys=ts,xs=_n&&_n.__createBinding||(Object.create?function(e,t,r,n){void 0===n&&(n=r);var i=Object.getOwnPropertyDescriptor(t,r);i&&!("get"in i?!t.__esModule:i.writable||i.configurable)||(i={enumerable:!0,get:function(){return t[r]}}),Object.defineProperty(e,n,i)}:function(e,t,r,n){void 0===n&&(n=r),e[n]=t[r]}),bs=_n&&_n.__exportStar||function(e,t){for(var r in e)"default"===r||Object.prototype.hasOwnProperty.call(t,r)||xs(t,e,r)},Object.defineProperty(ys,"__esModule",{value:!0}),bs(rs,ys),bs(ls,ys);var ks=_n&&_n.__extends||function(){var e=function(t,r){return(e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r])})(t,r)};return function(t,r){if("function"!=typeof r&&null!==r)throw new TypeError("Class extends value "+String(r)+" is not a constructor or null");function n(){this.constructor=t}e(t,r),t.prototype=null===r?Object.create(r):(n.prototype=r.prototype,new n)}}(),Ss=_n&&_n.__decorate||function(e,t,r,n){var i,o=arguments.length,a=o<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,r):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,r,n);else for(var s=e.length-1;s>=0;s--)(i=e[s])&&(a=(o<3?i(a):o>3?i(t,r,a):i(t,r))||a);return o>3&&a&&Object.defineProperty(t,r,a),a},_s=_n&&_n.__awaiter||function(e,t,r,n){return new(r||(r=Promise))(function(i,o){function a(e){try{l(n.next(e))}catch(t){o(t)}}function s(e){try{l(n.throw(e))}catch(t){o(t)}}function l(e){var t;e.done?i(e.value):(t=e.value,t instanceof r?t:new r(function(e){e(t)})).then(a,s)}l((n=n.apply(e,t||[])).next())})},Ts=_n&&_n.__generator||function(e,t){var r,n,i,o,a={label:0,sent:function(){if(1&i[0])throw i[1];return i[1]},trys:[],ops:[]};return o={next:s(0),throw:s(1),return:s(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function s(o){return function(s){return function(o){if(r)throw new TypeError("Generator is already executing.");for(;a;)try{if(r=1,n&&(i=2&o[0]?n.return:o[0]?n.throw||((i=n.return)&&i.call(n),0):n.next)&&!(i=i.call(n,o[1])).done)return i;switch(n=0,i&&(o=[2&o[0],i.value]),o[0]){case 0:case 1:i=o;break;case 4:return a.label++,{value:o[1],done:!1};case 5:a.label++,n=o[1],o=[0];continue;case 7:o=a.ops.pop(),a.trys.pop();continue;default:if(!(i=a.trys,(i=i.length>0&&i[i.length-1])||6!==o[0]&&2!==o[0])){a=0;continue}if(3===o[0]&&(!i||o[1]>i[0]&&o[1]<i[3])){a.label=o[1];break}if(6===o[0]&&a.label<i[1]){a.label=i[1],i=o;break}if(i&&a.label<i[2]){a.label=i[2],a.ops.push(o);break}i[2]&&a.ops.pop(),a.trys.pop();continue}o=t.call(e,a)}catch(s){o=[6,s],n=0}finally{r=i=0}if(5&o[0])throw o[1];return{value:o[0]?o[1]:void 0,done:!0}}([o,s])}}};Object.defineProperty(yo,"__esModule",{value:!0}),yo.BackgroundImage=yo.ContainerBase=yo.StylableCardElementContainer=yo.ContainerStyleProperty=yo.ActionSet=yo.ShowCardAction=yo.HttpAction=yo.HttpHeader=yo.ToggleVisibilityAction=yo.OpenUrlAction=yo.DataQuery=yo.ExecuteAction=yo.UniversalAction=yo.SubmitAction=yo.SubmitActionBase=yo.Action=yo.TimeInput=yo.TimeProperty=yo.DateInput=yo.NumberInput=yo.FilteredChoiceSet=yo.ChoiceSetInput=yo.ChoiceSetInputDataQuery=yo.Choice=yo.ToggleInput=yo.TextInput=yo.Input=yo.Media=yo.YouTubePlayer=yo.DailymotionPlayer=yo.VimeoPlayer=yo.IFrameMediaMediaPlayer=yo.CustomMediaPlayer=yo.HTML5MediaPlayer=yo.MediaPlayer=yo.MediaSource=yo.CaptionSource=yo.ContentSource=yo.ImageSet=yo.CardElementContainer=yo.Image=yo.FactSet=yo.Fact=yo.RichTextBlock=yo.TextRun=yo.TextBlock=yo.BaseTextBlock=yo.ActionProperty=yo.CardElement=yo.renderSeparation=void 0,yo.SerializationContext=yo.AdaptiveCard=yo.Authentication=yo.TokenExchangeResource=yo.AuthCardButton=yo.RefreshDefinition=yo.RefreshActionProperty=yo.ContainerWithActions=yo.ColumnSet=yo.Column=yo.Container=void 0;var As=xo,Ps=bo,Es=Co,Ms=Po,Is=Da,Bs=za,Ls=Mo,js=Za,Ns=Io,Ds=ts;function Os(e){var t,r,n="undefined"==typeof window?"":null!==(r=null===(t=window.trustedTypes)||void 0===t?void 0:t.emptyHTML)&&void 0!==r?r:"";e.innerHTML=n}function Fs(e,t,r){if(t.spacing>0||t.lineThickness&&t.lineThickness>0){var n=document.createElement("div");n.className=e.makeCssClassName("ac-"+(r===As.Orientation.Horizontal?"horizontal":"vertical")+"-separator"),n.setAttribute("aria-hidden","true");var i=t.lineColor?Es.stringToCssColor(t.lineColor):"";return r===As.Orientation.Horizontal?t.lineThickness?(n.style.paddingTop=t.spacing/2+"px",n.style.marginBottom=t.spacing/2+"px",n.style.borderBottom=t.lineThickness+"px solid "+i):n.style.height=t.spacing+"px":t.lineThickness?(n.style.paddingLeft=t.spacing/2+"px",n.style.marginRight=t.spacing/2+"px",n.style.borderRight=t.lineThickness+"px solid "+i):n.style.width=t.spacing+"px",n.style.overflow="hidden",n.style.flex="0 0 auto",n}}yo.renderSeparation=Fs;var Rs=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t._truncatedDueToOverflow=!1,t}return ks(t,e),Object.defineProperty(t.prototype,"lang",{get:function(){var e=this.getValue(t.langProperty);return e||(this.parent?this.parent.lang:void 0)},set:function(e){this.setValue(t.langProperty,e)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"isVisible",{get:function(){return this.getValue(t.isVisibleProperty)},set:function(e){Ps.GlobalSettings.useAdvancedCardBottomTruncation&&!e&&this.undoOverflowTruncation(),this.isVisible!==e&&(this.setValue(t.isVisibleProperty,e),this.updateRenderedElementVisibility(),this._renderedElement&&Ql(this)),this._renderedElement&&this._renderedElement.setAttribute("aria-expanded",e.toString())},enumerable:!1,configurable:!0}),t.prototype.internalRenderSeparator=function(){var e=Fs(this.hostConfig,{spacing:this.hostConfig.getEffectiveSpacing(this.spacing),lineThickness:this.separator?this.hostConfig.separator.lineThickness:void 0,lineColor:this.separator?this.hostConfig.separator.lineColor:void 0},this.separatorOrientation);if(Ps.GlobalSettings.alwaysBleedSeparators&&e&&this.separatorOrientation===As.Orientation.Horizontal){var t=this.getParentContainer();if(t&&t.getEffectivePadding()){var r=this.hostConfig.paddingDefinitionToSpacingDefinition(t.getEffectivePadding());e.style.marginLeft="-"+r.left+"px",e.style.marginRight="-"+r.right+"px"}}return e},t.prototype.updateRenderedElementVisibility=function(){var e=this.isDesignMode()||this.isVisible?this._defaultRenderedElementDisplayMode:"none";this._renderedElement&&(e?this._renderedElement.style.display=e:this._renderedElement.style.removeProperty("display")),this._separatorElement&&(this.parent&&this.parent.isFirstElement(this)?this._separatorElement.style.display="none":e?this._separatorElement.style.display=e:this._separatorElement.style.removeProperty("display"))},t.prototype.hideElementDueToOverflow=function(){this._renderedElement&&this.isVisible&&(this._renderedElement.style.visibility="hidden",this.isVisible=!1,Ql(this,!1))},t.prototype.showElementHiddenDueToOverflow=function(){this._renderedElement&&!this.isVisible&&(this._renderedElement.style.removeProperty("visibility"),this.isVisible=!0,Ql(this,!1))},t.prototype.handleOverflow=function(e){if(this.isVisible||this.isHiddenDueToOverflow()){var t=this.truncateOverflow(e);this._truncatedDueToOverflow=t||this._truncatedDueToOverflow,t?t&&!this.isVisible&&this.showElementHiddenDueToOverflow():this.hideElementDueToOverflow()}},t.prototype.resetOverflow=function(){var e=!1;return this._truncatedDueToOverflow&&(this.undoOverflowTruncation(),this._truncatedDueToOverflow=!1,e=!0),this.isHiddenDueToOverflow()&&this.showElementHiddenDueToOverflow(),e},t.prototype.getDefaultSerializationContext=function(){return new cc},t.prototype.createPlaceholderElement=function(){var e=this.getEffectiveStyleDefinition(),t=Es.stringToCssColor(e.foregroundColors.default.subtle),r=document.createElement("div");return r.style.border="1px dashed "+t,r.style.padding="4px",r.style.minHeight="32px",r.style.fontSize="10px",t&&(r.style.color=t),r.innerText=Ns.Strings.defaults.emptyElementText(this.getJsonTypeName()),r},t.prototype.adjustRenderedElementSize=function(e){"auto"===this.height?e.style.flex="0 0 auto":e.style.flex="1 1 auto"},t.prototype.updateInputsVisualState=function(e){var t=this.getAllInputs(),r=e?cl.MouseEnterOnCard:cl.MouseLeaveOnCard;t.forEach(function(e){return e.updateVisualState(r)})},t.prototype.isDisplayed=function(){return void 0!==this._renderedElement&&this.isVisible&&this._renderedElement.offsetHeight>0},t.prototype.overrideInternalRender=function(){return this.internalRender()},t.prototype.applyPadding=function(){if(this.separatorElement&&this.separatorOrientation===As.Orientation.Horizontal)if(Ps.GlobalSettings.alwaysBleedSeparators&&!this.isBleeding()){var e=new Ps.PaddingDefinition;this.getImmediateSurroundingPadding(e);var t=this.hostConfig.paddingDefinitionToSpacingDefinition(e);this.separatorElement.style.marginLeft="-"+t.left+"px",this.separatorElement.style.marginRight="-"+t.right+"px"}else this.separatorElement.style.marginRight="0",this.separatorElement.style.marginLeft="0"},t.prototype.truncateOverflow=function(e){return!1},t.prototype.undoOverflowTruncation=function(){},t.prototype.getDefaultPadding=function(){return new Ps.PaddingDefinition},t.prototype.getHasBackground=function(e){return!1},t.prototype.getHasBorder=function(){return!1},t.prototype.getPadding=function(){return this._padding},t.prototype.setPadding=function(e){this._padding=e},t.prototype.shouldSerialize=function(e){return void 0!==e.elementRegistry.findByName(this.getJsonTypeName())},Object.defineProperty(t.prototype,"useDefaultSizing",{get:function(){return!0},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"separatorOrientation",{get:function(){return As.Orientation.Horizontal},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"defaultStyle",{get:function(){return As.ContainerStyle.Default},enumerable:!1,configurable:!0}),t.prototype.parse=function(t,r){e.prototype.parse.call(this,t,r||new cc)},t.prototype.asString=function(){return""},t.prototype.isBleeding=function(){return!1},t.prototype.getEffectiveStyle=function(){return this.parent?this.parent.getEffectiveStyle():this.defaultStyle},t.prototype.getEffectiveStyleDefinition=function(){return this.hostConfig.containerStyles.getStyleByName(this.getEffectiveStyle())},t.prototype.getEffectiveTextStyleDefinition=function(){return this.parent?this.parent.getEffectiveTextStyleDefinition():this.hostConfig.textStyles.default},t.prototype.getForbiddenActionTypes=function(){return[]},t.prototype.getImmediateSurroundingPadding=function(e,t,r,n,i){if(void 0===t&&(t=!0),void 0===r&&(r=!0),void 0===n&&(n=!0),void 0===i&&(i=!0),this.parent){var o=t&&this.parent.isTopElement(this),a=r&&this.parent.isRightMostElement(this),s=n&&this.parent.isBottomElement(this),l=i&&this.parent.isLeftMostElement(this),c=this.parent.getEffectivePadding();c&&(o&&c.top!==As.Spacing.None&&(e.top=c.top,o=!1),a&&c.right!==As.Spacing.None&&(e.right=c.right,a=!1),s&&c.bottom!==As.Spacing.None&&(e.bottom=c.bottom,s=!1),l&&c.left!==As.Spacing.None&&(e.left=c.left,l=!1)),(o||a||s||l)&&this.parent.getImmediateSurroundingPadding(e,o,a,s,l)}},t.prototype.getActionCount=function(){return 0},t.prototype.getActionAt=function(e){throw new Error(Ns.Strings.errors.indexOutOfRange(e))},t.prototype.indexOfAction=function(e){for(var t=0;t<this.getActionCount();t++)if(this.getActionAt(t)===e)return t;return-1},t.prototype.remove=function(){return!!(this.parent&&this.parent instanceof Ys)&&this.parent.removeItem(this)},t.prototype.render=function(){return this._renderedElement=this.overrideInternalRender(),this._separatorElement=this.internalRenderSeparator(),this._renderedElement?(this.id&&(this._renderedElement.id=this.id),this.customCssSelector&&this._renderedElement.classList.add(this.customCssSelector),this._renderedElement.style.boxSizing="border-box",this._defaultRenderedElementDisplayMode=this._renderedElement.style.display?this._renderedElement.style.display:void 0,this.adjustRenderedElementSize(this._renderedElement),this.updateLayout(!1)):this.isDesignMode()&&(this._renderedElement=this.createPlaceholderElement()),this._renderedElement},t.prototype.updateLayout=function(e){this.updateRenderedElementVisibility(),this.applyPadding()},t.prototype.updateActionsEnabledState=function(){for(var e=0,t=this.getRootElement().getAllActions();e<t.length;e++){t[e].updateEnabledState()}},t.prototype.indexOf=function(e){return-1},t.prototype.isDesignMode=function(){var e=this.getRootElement();return e instanceof sc&&e.designMode},t.prototype.isFirstElement=function(e){return!0},t.prototype.isLastElement=function(e){return!0},t.prototype.isAtTheVeryLeft=function(){return!this.parent||this.parent.isLeftMostElement(this)&&this.parent.isAtTheVeryLeft()},t.prototype.isAtTheVeryRight=function(){return!this.parent||this.parent.isRightMostElement(this)&&this.parent.isAtTheVeryRight()},t.prototype.isAtTheVeryTop=function(){return!this.parent||this.parent.isFirstElement(this)&&this.parent.isAtTheVeryTop()},t.prototype.isAtTheVeryBottom=function(){return!this.parent||this.parent.isLastElement(this)&&this.parent.isAtTheVeryBottom()},t.prototype.isBleedingAtTop=function(){return!1},t.prototype.isBleedingAtBottom=function(){return!1},t.prototype.isLeftMostElement=function(e){return!0},t.prototype.isRightMostElement=function(e){return!0},t.prototype.isTopElement=function(e){return this.isFirstElement(e)},t.prototype.isBottomElement=function(e){return this.isLastElement(e)},t.prototype.isHiddenDueToOverflow=function(){return void 0!==this._renderedElement&&"hidden"===this._renderedElement.style.visibility},t.prototype.getRootElement=function(){return this.getRootObject()},t.prototype.getParentContainer=function(){for(var e=this.parent;e;){if(e instanceof Gl)return e;e=e.parent}},t.prototype.getAllInputs=function(e){return[]},t.prototype.getAllActions=function(){for(var e=[],t=0;t<this.getActionCount();t++){var r=this.getActionAt(t);r&&e.push(r)}return e},t.prototype.getResourceInformation=function(){return[]},t.prototype.getElementById=function(e){return this.id===e?this:void 0},t.prototype.getActionById=function(e){},t.prototype.getElementByIdFromAction=function(e){for(var t=void 0,r=0;r<this.getActionCount();r++){var n=this.getActionAt(r);if(n instanceof Fl&&(t=n.card.getElementById(e)))break}return t},t.prototype.getEffectivePadding=function(){var e=this.getPadding();return e||this.getDefaultPadding()},t.prototype.getEffectiveHorizontalAlignment=function(){return void 0!==this.horizontalAlignment?this.horizontalAlignment:this.parent?this.parent.getEffectiveHorizontalAlignment():As.HorizontalAlignment.Left},Object.defineProperty(t.prototype,"hostConfig",{get:function(){return this._hostConfig?this._hostConfig:this.parent?this.parent.hostConfig:Ms.defaultHostConfig},set:function(e){this._hostConfig=e},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"index",{get:function(){return this.parent?this.parent.indexOf(this):0},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"isInteractive",{get:function(){return!1},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"isStandalone",{get:function(){return!0},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"isInline",{get:function(){return!1},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"hasVisibleSeparator",{get:function(){return!(!this.parent||!this.separatorElement)&&(!this.parent.isFirstElement(this)&&(this.isVisible||this.isDesignMode()))},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"separatorElement",{get:function(){return this._separatorElement},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"parent",{get:function(){return this._parent},enumerable:!1,configurable:!0}),t.langProperty=new Ls.StringProperty(Ls.Versions.v1_1,"lang",!0,/^[a-z]{2,3}$/gi),t.isVisibleProperty=new Ls.BoolProperty(Ls.Versions.v1_2,"isVisible",!0),t.separatorProperty=new Ls.BoolProperty(Ls.Versions.v1_0,"separator",!1),t.heightProperty=new Ls.ValueSetProperty(Ls.Versions.v1_1,"height",[{value:"auto"},{value:"stretch"}],"auto"),t.horizontalAlignmentProperty=new Ls.EnumProperty(Ls.Versions.v1_0,"horizontalAlignment",As.HorizontalAlignment),t.spacingProperty=new Ls.EnumProperty(Ls.Versions.v1_0,"spacing",As.Spacing,As.Spacing.Default),Ss([(0,Ls.property)(t.horizontalAlignmentProperty)],t.prototype,"horizontalAlignment",void 0),Ss([(0,Ls.property)(t.spacingProperty)],t.prototype,"spacing",void 0),Ss([(0,Ls.property)(t.separatorProperty)],t.prototype,"separator",void 0),Ss([(0,Ls.property)(t.heightProperty)],t.prototype,"height",void 0),Ss([(0,Ls.property)(t.langProperty)],t.prototype,"lang",null),Ss([(0,Ls.property)(t.isVisibleProperty)],t.prototype,"isVisible",null),t}(Bs.CardObject);yo.CardElement=Rs;var $s=function(e){function t(t,r,n){void 0===n&&(n=[]);var i=e.call(this,t,r,void 0)||this;return i.targetVersion=t,i.name=r,i.forbiddenActionTypes=n,i}return ks(t,e),t.prototype.parse=function(e,t,r){var n=e;return r.parseAction(n,t[this.name],this.forbiddenActionTypes,n.isDesignMode())},t.prototype.toJSON=function(e,t,r,n){n.serializeValue(t,this.name,r?r.toJSON(n):void 0,void 0,!0)},t}(Ls.PropertyDefinition);yo.ActionProperty=$s;var zs=function(e){function t(t){var r=e.call(this)||this;return r.ariaHidden=!1,t&&(r.text=t),r}return ks(t,e),t.prototype.populateSchema=function(r){e.prototype.populateSchema.call(this,r),r.remove(t.selectActionProperty)},Object.defineProperty(t.prototype,"text",{get:function(){return this.getValue(t.textProperty)},set:function(e){this.setText(e)},enumerable:!1,configurable:!0}),t.prototype.getFontSize=function(e){switch(this.effectiveSize){case As.TextSize.Small:return e.fontSizes.small;case As.TextSize.Medium:return e.fontSizes.medium;case As.TextSize.Large:return e.fontSizes.large;case As.TextSize.ExtraLarge:return e.fontSizes.extraLarge;default:return e.fontSizes.default}},t.prototype.getColorDefinition=function(e,t){switch(t){case As.TextColor.Accent:return e.accent;case As.TextColor.Dark:return e.dark;case As.TextColor.Light:return e.light;case As.TextColor.Good:return e.good;case As.TextColor.Warning:return e.warning;case As.TextColor.Attention:return e.attention;default:return e.default}},t.prototype.setText=function(e){this.setValue(t.textProperty,e)},t.prototype.init=function(e){this.size=e.size,this.weight=e.weight,this.color=e.color,this.isSubtle=e.isSubtle},t.prototype.asString=function(){return this.text},t.prototype.applyStylesTo=function(e){var t,r=this.hostConfig.getFontTypeDefinition(this.effectiveFontType);switch(r.fontFamily&&(e.style.fontFamily=r.fontFamily),this.effectiveSize){case As.TextSize.Small:t=r.fontSizes.small;break;case As.TextSize.Medium:t=r.fontSizes.medium;break;case As.TextSize.Large:t=r.fontSizes.large;break;case As.TextSize.ExtraLarge:t=r.fontSizes.extraLarge;break;default:t=r.fontSizes.default}e.style.fontSize=t+"px";var n,i=this.getColorDefinition(this.getEffectiveStyleDefinition().foregroundColors,this.effectiveColor),o=Es.stringToCssColor(this.effectiveIsSubtle?i.subtle:i.default);switch(o&&(e.style.color=o),this.effectiveWeight){case As.TextWeight.Lighter:n=r.fontWeights.lighter;break;case As.TextWeight.Bolder:n=r.fontWeights.bolder;break;default:n=r.fontWeights.default}e.style.fontWeight=n.toString(),this.ariaHidden&&e.setAttribute("aria-hidden","true")},t.prototype.getAllActions=function(){var t=e.prototype.getAllActions.call(this);return this.selectAction&&t.push(this.selectAction),t},Object.defineProperty(t.prototype,"effectiveColor",{get:function(){return void 0!==this.color?this.color:this.getEffectiveTextStyleDefinition().color},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"effectiveFontType",{get:function(){return void 0!==this.fontType?this.fontType:this.getEffectiveTextStyleDefinition().fontType},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"effectiveIsSubtle",{get:function(){return void 0!==this.isSubtle?this.isSubtle:this.getEffectiveTextStyleDefinition().isSubtle},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"effectiveSize",{get:function(){return void 0!==this.size?this.size:this.getEffectiveTextStyleDefinition().size},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"effectiveWeight",{get:function(){return void 0!==this.weight?this.weight:this.getEffectiveTextStyleDefinition().weight},enumerable:!1,configurable:!0}),t.textProperty=new Ls.StringProperty(Ls.Versions.v1_0,"text",!0),t.sizeProperty=new Ls.EnumProperty(Ls.Versions.v1_0,"size",As.TextSize),t.weightProperty=new Ls.EnumProperty(Ls.Versions.v1_0,"weight",As.TextWeight),t.colorProperty=new Ls.EnumProperty(Ls.Versions.v1_0,"color",As.TextColor),t.isSubtleProperty=new Ls.BoolProperty(Ls.Versions.v1_0,"isSubtle"),t.fontTypeProperty=new Ls.EnumProperty(Ls.Versions.v1_2,"fontType",As.FontType),t.selectActionProperty=new $s(Ls.Versions.v1_1,"selectAction",["Action.ShowCard"]),Ss([(0,Ls.property)(t.sizeProperty)],t.prototype,"size",void 0),Ss([(0,Ls.property)(t.weightProperty)],t.prototype,"weight",void 0),Ss([(0,Ls.property)(t.colorProperty)],t.prototype,"color",void 0),Ss([(0,Ls.property)(t.fontTypeProperty)],t.prototype,"fontType",void 0),Ss([(0,Ls.property)(t.isSubtleProperty)],t.prototype,"isSubtle",void 0),Ss([(0,Ls.property)(t.textProperty)],t.prototype,"text",null),Ss([(0,Ls.property)(t.selectActionProperty)],t.prototype,"selectAction",void 0),t}(Rs);yo.BaseTextBlock=zs;var Vs=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.wrap=!1,t._treatAsPlainText=!0,t.useMarkdown=!0,t}var r,n;return ks(t,e),t.prototype.restoreOriginalContent=function(){var e,r;if(void 0!==this.renderedElement){this.maxLines&&this.maxLines>0&&(this.renderedElement.style.maxHeight=this._computedLineHeight*this.maxLines+"px");var n=null!==(r=null===(e=t._ttRoundtripPolicy)||void 0===e?void 0:e.createHTML(this._originalInnerHtml))&&void 0!==r?r:this._originalInnerHtml;this.renderedElement.innerHTML=n}},t.prototype.truncateIfSupported=function(e){if(void 0!==this.renderedElement){var t=this.renderedElement.children,r=!t.length;if(r||1===t.length&&"p"===t[0].tagName.toLowerCase()&&!t[0].children.length){var n=r?this.renderedElement:t[0];return Es.truncateText(n,e,this._computedLineHeight),!0}}return!1},t.prototype.setText=function(t){e.prototype.setText.call(this,t),this._processedText=void 0},t.prototype.internalRender=function(){var e,r,n=this;if(this._processedText=void 0,this.text){var i=this.preProcessPropertyValue(zs.textProperty),o=this.hostConfig,a=void 0;if(this.forElementId){var s=document.createElement("label");s.htmlFor=this.forElementId,a=s}else a=document.createElement("div");if(a.classList.add(o.makeCssClassName("ac-textBlock")),a.style.overflow="hidden",this.applyStylesTo(a),"heading"===this.style){a.setAttribute("role","heading");var l=this.hostConfig.textBlock.headingLevel;void 0!==l&&l>0&&a.setAttribute("aria-level",l.toString())}if(this.selectAction&&o.supportsInteractivity&&(a.onclick=function(e){n.selectAction&&n.selectAction.isEffectivelyEnabled()&&(e.preventDefault(),e.cancelBubble=!0,n.selectAction.execute())},this.selectAction.setupElementForAccessibility(a),this.selectAction.isEffectivelyEnabled()&&a.classList.add(o.makeCssClassName("ac-selectable"))),!this._processedText){this._treatAsPlainText=!0;var c=Is.formatText(this.lang,i);if(this.useMarkdown&&c){Ps.GlobalSettings.allowMarkForTextHighlighting&&(c=c.replace(/<mark>/g,"===").replace(/<\/mark>/g,"/==/"));var u=sc.applyMarkdown(c);if(u.didProcess&&u.outputHtml){if(this._processedText=u.outputHtml,this._treatAsPlainText=!1,Ps.GlobalSettings.allowMarkForTextHighlighting&&this._processedText){var h="",d=this.getEffectiveStyleDefinition();d.highlightBackgroundColor&&(h+="background-color: "+d.highlightBackgroundColor+";"),d.highlightForegroundColor&&(h+="color: "+d.highlightForegroundColor+";"),h&&(h='style="'+h+'"'),this._processedText=this._processedText.replace(/===/g,"<mark "+h+">").replace(/\/==\//g,"</mark>")}}else this._processedText=c,this._treatAsPlainText=!0}else this._processedText=c,this._treatAsPlainText=!0}if(this._processedText||(this._processedText=""),this._treatAsPlainText)a.innerText=this._processedText;else{var p=null!==(r=null===(e=t._ttMarkdownPolicy)||void 0===e?void 0:e.createHTML(this._processedText))&&void 0!==r?r:this._processedText;a.innerHTML=p}if(a.firstElementChild instanceof HTMLElement){var f=a.firstElementChild;f.style.marginTop="0px",f.style.width="100%",this.wrap||(f.style.overflow="hidden",f.style.textOverflow="ellipsis")}a.lastElementChild instanceof HTMLElement&&(a.lastElementChild.style.marginBottom="0px");for(var g=a.getElementsByTagName("a"),m=function(e){e.classList.add(o.makeCssClassName("ac-anchor")),e.target="_blank",e.onclick=function(t){Zl(n,e,t)&&(t.preventDefault(),t.cancelBubble=!0)},e.oncontextmenu=function(t){return!Zl(n,e,t)||(t.preventDefault(),t.cancelBubble=!0,!1)}},y=0,x=Array.from(g);y<x.length;y++){m(x[y])}return this.wrap?(a.style.wordWrap="break-word",this.maxLines&&this.maxLines>0&&(a.style.overflow="hidden",Es.isInternetExplorer()||!Ps.GlobalSettings.useWebkitLineClamp?a.style.maxHeight=this._computedLineHeight*this.maxLines+"px":(a.style.removeProperty("line-height"),a.style.display="-webkit-box",a.style.webkitBoxOrient="vertical",a.style.webkitLineClamp=this.maxLines.toString()))):(a.style.whiteSpace="nowrap",a.style.textOverflow="ellipsis"),(Ps.GlobalSettings.useAdvancedTextBlockTruncation||Ps.GlobalSettings.useAdvancedCardBottomTruncation)&&(this._originalInnerHtml=a.innerHTML),a}},t.prototype.truncateOverflow=function(e){return e>=this._computedLineHeight&&this.truncateIfSupported(e)},t.prototype.undoOverflowTruncation=function(){if(this.restoreOriginalContent(),Ps.GlobalSettings.useAdvancedTextBlockTruncation&&this.maxLines){var e=this._computedLineHeight*this.maxLines;this.truncateIfSupported(e)}},t.prototype.applyStylesTo=function(t){switch(e.prototype.applyStylesTo.call(this,t),this.getEffectiveHorizontalAlignment()){case As.HorizontalAlignment.Center:t.style.textAlign="center";break;case As.HorizontalAlignment.Right:t.style.textAlign="end";break;default:t.style.textAlign="start"}var r=this.hostConfig.lineHeights;if(r)switch(this.effectiveSize){case As.TextSize.Small:this._computedLineHeight=r.small;break;case As.TextSize.Medium:this._computedLineHeight=r.medium;break;case As.TextSize.Large:this._computedLineHeight=r.large;break;case As.TextSize.ExtraLarge:this._computedLineHeight=r.extraLarge;break;default:this._computedLineHeight=r.default}else this._computedLineHeight=1.33*this.getFontSize(this.hostConfig.getFontTypeDefinition(this.effectiveFontType));t.style.lineHeight=this._computedLineHeight+"px"},t.prototype.getJsonTypeName=function(){return"TextBlock"},t.prototype.getEffectiveTextStyleDefinition=function(){return this.style?this.hostConfig.textStyles.getStyleByName(this.style):e.prototype.getEffectiveTextStyleDefinition.call(this)},t.prototype.updateLayout=function(t){void 0===t&&(t=!1),e.prototype.updateLayout.call(this,t),Ps.GlobalSettings.useAdvancedTextBlockTruncation&&this.maxLines&&this.isDisplayed()&&(this.restoreOriginalContent(),this.truncateIfSupported(this._computedLineHeight*this.maxLines))},t.wrapProperty=new Ls.BoolProperty(Ls.Versions.v1_0,"wrap",!1),t.maxLinesProperty=new Ls.NumProperty(Ls.Versions.v1_0,"maxLines"),t.styleProperty=new Ls.ValueSetProperty(Ls.Versions.v1_5,"style",[{value:"default"},{value:"columnHeader"},{value:"heading"}]),t._ttMarkdownPolicy="undefined"==typeof window||null===(r=window.trustedTypes)||void 0===r?void 0:r.createPolicy("adaptivecards#markdownPassthroughPolicy",{createHTML:function(e){return e}}),t._ttRoundtripPolicy="undefined"==typeof window||null===(n=window.trustedTypes)||void 0===n?void 0:n.createPolicy("adaptivecards#restoreContentsPolicy",{createHTML:function(e){return e}}),Ss([(0,Ls.property)(t.wrapProperty)],t.prototype,"wrap",void 0),Ss([(0,Ls.property)(t.maxLinesProperty)],t.prototype,"maxLines",void 0),Ss([(0,Ls.property)(t.styleProperty)],t.prototype,"style",void 0),t}(zs);yo.TextBlock=Vs;var Ws=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.italic=!1,t.strikethrough=!1,t.highlight=!1,t.underline=!1,t}return ks(t,e),t.prototype.populateSchema=function(t){e.prototype.populateSchema.call(this,t),t.add(zs.selectActionProperty)},t.prototype.internalRender=function(){var e=this;if(this.text){var t=this.preProcessPropertyValue(zs.textProperty),r=this.hostConfig,n=Is.formatText(this.lang,t);n||(n="");var i=document.createElement("span");if(i.classList.add(r.makeCssClassName("ac-textRun")),this.applyStylesTo(i),this.selectAction&&r.supportsInteractivity){var o=document.createElement("a");o.classList.add(r.makeCssClassName("ac-anchor"));var a=this.selectAction.getHref();o.href=a||"",o.target="_blank",o.onclick=function(t){e.selectAction&&e.selectAction.isEffectivelyEnabled()&&(t.preventDefault(),t.cancelBubble=!0,e.selectAction.execute())},this.selectAction.setupElementForAccessibility(o),o.innerText=n,i.appendChild(o)}else i.innerText=n;return i}},t.prototype.applyStylesTo=function(t){if(e.prototype.applyStylesTo.call(this,t),this.italic&&(t.style.fontStyle="italic"),this.strikethrough&&(t.style.textDecoration="line-through"),this.highlight){var r=this.getColorDefinition(this.getEffectiveStyleDefinition().foregroundColors,this.effectiveColor),n=Es.stringToCssColor(this.effectiveIsSubtle?r.highlightColors.subtle:r.highlightColors.default);n&&(t.style.backgroundColor=n)}this.underline&&(t.style.textDecoration="underline")},t.prototype.getJsonTypeName=function(){return"TextRun"},Object.defineProperty(t.prototype,"isStandalone",{get:function(){return!1},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"isInline",{get:function(){return!0},enumerable:!1,configurable:!0}),t.italicProperty=new Ls.BoolProperty(Ls.Versions.v1_2,"italic",!1),t.strikethroughProperty=new Ls.BoolProperty(Ls.Versions.v1_2,"strikethrough",!1),t.highlightProperty=new Ls.BoolProperty(Ls.Versions.v1_2,"highlight",!1),t.underlineProperty=new Ls.BoolProperty(Ls.Versions.v1_3,"underline",!1),Ss([(0,Ls.property)(t.italicProperty)],t.prototype,"italic",void 0),Ss([(0,Ls.property)(t.strikethroughProperty)],t.prototype,"strikethrough",void 0),Ss([(0,Ls.property)(t.highlightProperty)],t.prototype,"highlight",void 0),Ss([(0,Ls.property)(t.underlineProperty)],t.prototype,"underline",void 0),t}(zs);yo.TextRun=Ws;var Hs=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t._inlines=[],t}return ks(t,e),t.prototype.internalAddInline=function(e,t){if(void 0===t&&(t=!1),!e.isInline)throw new Error(Ns.Strings.errors.elementCannotBeUsedAsInline());if(!(void 0===e.parent||t)&&e.parent!==this)throw new Error(Ns.Strings.errors.inlineAlreadyParented());e.setParent(this),this._inlines.push(e)},t.prototype.internalParse=function(t,r){if(e.prototype.internalParse.call(this,t,r),this._inlines=[],Array.isArray(t.inlines))for(var n=0,i=t.inlines;n<i.length;n++){var o=i[n],a=void 0;if("string"==typeof o){var s=new Ws;s.text=o,a=s}else a=r.parseElement(this,o,[],!1);a&&this.internalAddInline(a,!0)}},t.prototype.internalToJSON=function(t,r){if(e.prototype.internalToJSON.call(this,t,r),this._inlines.length>0){for(var n=[],i=0,o=this._inlines;i<o.length;i++){var a=o[i];n.push(a.toJSON(r))}r.serializeValue(t,"inlines",n)}},t.prototype.internalRender=function(){if(this._inlines.length>0){var e=void 0;if(this.forElementId){var t=document.createElement("label");t.htmlFor=this.forElementId,e=t}else e=document.createElement("div");switch(e.className=this.hostConfig.makeCssClassName("ac-richTextBlock"),this.getEffectiveHorizontalAlignment()){case As.HorizontalAlignment.Center:e.style.textAlign="center";break;case As.HorizontalAlignment.Right:e.style.textAlign="end";break;default:e.style.textAlign="start"}for(var r=0,n=0,i=this._inlines;n<i.length;n++){var o=i[n].render();o&&(e.appendChild(o),r++)}if(r>0)return e}},t.prototype.asString=function(){for(var e="",t=0,r=this._inlines;t<r.length;t++){e+=r[t].asString()}return e},t.prototype.getJsonTypeName=function(){return"RichTextBlock"},t.prototype.getInlineCount=function(){return this._inlines.length},t.prototype.getInlineAt=function(e){if(e>=0&&e<this._inlines.length)return this._inlines[e];throw new Error(Ns.Strings.errors.indexOutOfRange(e))},t.prototype.addInline=function(e){"string"==typeof e?this.internalAddInline(new Ws(e)):this.internalAddInline(e)},t.prototype.removeInline=function(e){var t=this._inlines.indexOf(e);return t>=0&&(this._inlines[t].setParent(void 0),this._inlines.splice(t,1),!0)},t}(Rs);yo.RichTextBlock=Hs;var qs=function(e){function t(t,r){var n=e.call(this)||this;return n.name=t,n.value=r,n}return ks(t,e),t.prototype.getSchemaKey=function(){return"Fact"},t.titleProperty=new Ls.StringProperty(Ls.Versions.v1_0,"title"),t.valueProperty=new Ls.StringProperty(Ls.Versions.v1_0,"value"),Ss([(0,Ls.property)(t.titleProperty)],t.prototype,"name",void 0),Ss([(0,Ls.property)(t.valueProperty)],t.prototype,"value",void 0),t}(Ls.SerializableObject);yo.Fact=qs;var Us=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return ks(t,e),Object.defineProperty(t.prototype,"useDefaultSizing",{get:function(){return!1},enumerable:!1,configurable:!0}),t.prototype.internalRender=function(){var e=void 0,t=this.hostConfig;if(this.facts.length>0){(e=document.createElement("table")).style.borderWidth="0px",e.style.borderSpacing="0px",e.style.borderStyle="none",e.style.borderCollapse="collapse",e.style.display="block",e.style.overflow="hidden",e.classList.add(t.makeCssClassName("ac-factset")),e.setAttribute("role","presentation");for(var r=0;r<this.facts.length;r++){var n=document.createElement("tr");r>0&&(n.style.marginTop=t.factSet.spacing+"px");var i=document.createElement("td");i.style.padding="0",i.classList.add(t.makeCssClassName("ac-fact-title")),t.factSet.title.maxWidth&&(i.style.maxWidth=t.factSet.title.maxWidth+"px"),i.style.verticalAlign="top";var o=new Vs;o.setParent(this),o.text=!this.facts[r].name&&this.isDesignMode()?"Title":this.facts[r].name,o.size=t.factSet.title.size,o.color=t.factSet.title.color,o.isSubtle=t.factSet.title.isSubtle,o.weight=t.factSet.title.weight,o.wrap=t.factSet.title.wrap,o.spacing=As.Spacing.None,Es.appendChild(i,o.render()),Es.appendChild(n,i),(i=document.createElement("td")).style.width="10px",Es.appendChild(n,i),(i=document.createElement("td")).style.padding="0",i.style.verticalAlign="top",i.classList.add(t.makeCssClassName("ac-fact-value")),(o=new Vs).setParent(this),o.text=this.facts[r].value,o.size=t.factSet.value.size,o.color=t.factSet.value.color,o.isSubtle=t.factSet.value.isSubtle,o.weight=t.factSet.value.weight,o.wrap=t.factSet.value.wrap,o.spacing=As.Spacing.None,Es.appendChild(i,o.render()),Es.appendChild(n,i),Es.appendChild(e,n)}}return e},t.prototype.getJsonTypeName=function(){return"FactSet"},t.factsProperty=new Ls.SerializableObjectCollectionProperty(Ls.Versions.v1_0,"facts",qs),Ss([(0,Ls.property)(t.factsProperty)],t.prototype,"facts",void 0),t}(Rs);yo.FactSet=Us;var Gs=function(e){function t(t,r,n,i){var o=e.call(this,t,r)||this;return o.targetVersion=t,o.name=r,o.internalName=n,o.fallbackProperty=i,o}return ks(t,e),t.prototype.getInternalName=function(){return this.internalName},t.prototype.parse=function(e,t,r){var n=void 0,i=t[this.name];if(void 0===i)return this.defaultValue;var o=!1;if("string"==typeof i){try{var a=Ps.SizeAndUnit.parse(i,!0);a.unit===As.SizeUnit.Pixel&&(n=a.physicalSize,o=!0)}catch(s){}!o&&this.fallbackProperty&&(o=this.fallbackProperty.isValidValue(i,r))}return o||r.logParseEvent(e,As.ValidationEvent.InvalidPropertyValue,Ns.Strings.errors.invalidPropertyValue(i,this.name)),n},t.prototype.toJSON=function(e,t,r,n){n.serializeValue(t,this.name,"number"!=typeof r||isNaN(r)?void 0:r+"px")},t}(Ls.PropertyDefinition),Xs=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.size=As.Size.Auto,t.style=As.ImageStyle.Default,t}return ks(t,e),t.prototype.populateSchema=function(t){e.prototype.populateSchema.call(this,t),t.remove(Rs.heightProperty)},t.prototype.applySize=function(e){if(this.pixelWidth||this.pixelHeight)this.pixelWidth&&(e.style.width=this.pixelWidth+"px"),this.pixelHeight&&(e.style.height=this.pixelHeight+"px");else if(this.maxHeight){switch(this.size){case As.Size.Small:e.style.height=this.hostConfig.imageSizes.small+"px";break;case As.Size.Large:e.style.height=this.hostConfig.imageSizes.large+"px";break;default:e.style.height=this.hostConfig.imageSizes.medium+"px"}e.style.maxHeight=this.maxHeight+"px"}else{switch(this.size){case As.Size.Stretch:e.style.width="100%";break;case As.Size.Auto:e.style.maxWidth="100%";break;case As.Size.Small:e.style.width=this.hostConfig.imageSizes.small+"px";break;case As.Size.Large:e.style.width=this.hostConfig.imageSizes.large+"px";break;case As.Size.Medium:e.style.width=this.hostConfig.imageSizes.medium+"px"}e.style.maxHeight="100%"}},Object.defineProperty(t.prototype,"useDefaultSizing",{get:function(){return!1},enumerable:!1,configurable:!0}),t.prototype.internalRender=function(){var e=this,r=void 0;if(this.url){(r=document.createElement("div")).style.display="flex",r.style.alignItems="flex-start";var n=this.hostConfig;switch(this.getEffectiveHorizontalAlignment()){case As.HorizontalAlignment.Center:r.style.justifyContent="center";break;case As.HorizontalAlignment.Right:r.style.justifyContent="flex-end";break;default:r.style.justifyContent="flex-start"}var i=document.createElement("img");this.renderedImageElement=i,i.onload=function(t){Yl(e)},i.onerror=function(t){if(e.renderedElement){var r=e.getRootElement();if(Os(e.renderedElement),r&&r.designMode){var n=document.createElement("div");n.style.display="flex",n.style.alignItems="center",n.style.justifyContent="center",n.style.backgroundColor="#EEEEEE",n.style.color="black",n.innerText=":-(",n.style.padding="10px",e.applySize(n),e.renderedElement.appendChild(n)}}Yl(e)},i.style.minWidth="0",i.classList.add(n.makeCssClassName("ac-image")),this.selectAction&&n.supportsInteractivity&&(i.onkeypress=function(t){e.selectAction&&e.selectAction.isEffectivelyEnabled()&&("Enter"===t.code||"Space"===t.code)&&(t.preventDefault(),t.cancelBubble=!0,e.selectAction.execute())},i.onclick=function(t){e.selectAction&&e.selectAction.isEffectivelyEnabled()&&(t.preventDefault(),t.cancelBubble=!0,e.selectAction.execute())},this.selectAction.setupElementForAccessibility(i),this.selectAction.isEffectivelyEnabled()&&i.classList.add(n.makeCssClassName("ac-selectable"))),this.applySize(i),this.style===As.ImageStyle.Person&&(i.style.borderRadius="50%",i.style.backgroundPosition="50% 50%",i.style.backgroundRepeat="no-repeat");var o=Es.stringToCssColor(this.backgroundColor);o&&(i.style.backgroundColor=o),this.setImageSource(i);var a=this.preProcessPropertyValue(t.altTextProperty);a&&(i.alt=a),r.appendChild(i)}return r},t.prototype.getJsonTypeName=function(){return"Image"},t.prototype.getAllActions=function(){var t=e.prototype.getAllActions.call(this);return this.selectAction&&t.push(this.selectAction),t},t.prototype.getActionById=function(t){var r=e.prototype.getActionById.call(this,t);return!r&&this.selectAction&&(r=this.selectAction.getActionById(t)),r},t.prototype.getResourceInformation=function(){return this.url?[{url:this.url,mimeType:"image"}]:[]},t.prototype.setImageSource=function(e){var r=new Js(this.forceLoad,this.url);r.configureImage(this),e.src=this.preProcessPropertyValue(t.urlProperty),r.resetImage(this)},t.urlProperty=new Ls.StringProperty(Ls.Versions.v1_0,"url"),t.altTextProperty=new Ls.StringProperty(Ls.Versions.v1_0,"altText"),t.backgroundColorProperty=new Ls.StringProperty(Ls.Versions.v1_1,"backgroundColor"),t.styleProperty=new Ls.EnumProperty(Ls.Versions.v1_0,"style",As.ImageStyle,As.ImageStyle.Default),t.sizeProperty=new Ls.EnumProperty(Ls.Versions.v1_0,"size",As.Size,As.Size.Auto),t.pixelWidthProperty=new Gs(Ls.Versions.v1_1,"width","pixelWidth"),t.pixelHeightProperty=new Gs(Ls.Versions.v1_1,"height","pixelHeight",Rs.heightProperty),t.selectActionProperty=new $s(Ls.Versions.v1_1,"selectAction",["Action.ShowCard"]),t.shouldForceLoadProperty=new Ls.BoolProperty(Ls.Versions.v1_6,"forceLoad",!1),Ss([(0,Ls.property)(t.urlProperty)],t.prototype,"url",void 0),Ss([(0,Ls.property)(t.altTextProperty)],t.prototype,"altText",void 0),Ss([(0,Ls.property)(t.backgroundColorProperty)],t.prototype,"backgroundColor",void 0),Ss([(0,Ls.property)(t.sizeProperty)],t.prototype,"size",void 0),Ss([(0,Ls.property)(t.styleProperty)],t.prototype,"style",void 0),Ss([(0,Ls.property)(t.pixelWidthProperty)],t.prototype,"pixelWidth",void 0),Ss([(0,Ls.property)(t.pixelHeightProperty)],t.prototype,"pixelHeight",void 0),Ss([(0,Ls.property)(t.selectActionProperty)],t.prototype,"selectAction",void 0),Ss([(0,Ls.property)(t.shouldForceLoadProperty)],t.prototype,"forceLoad",void 0),t}(Rs);yo.Image=Xs;var Js=function(){function e(e,t){this.doForceLoad=e,this.url=t,t&&t.length&&e&&(this.uniqueHash="?"+Date.now(),this.urlWithForceLoadOption=t+this.uniqueHash)}return e.prototype.configureImage=function(e){this.urlWithForceLoadOption&&this.urlWithForceLoadOption.length&&(e.url=this.urlWithForceLoadOption)},e.prototype.resetImage=function(e){e.url=this.url},e}(),Ys=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.allowVerticalOverflow=!1,t}return ks(t,e),t.prototype.populateSchema=function(r){e.prototype.populateSchema.call(this,r),this.isSelectable||r.remove(t.selectActionProperty)},t.prototype.isElementAllowed=function(e){return this.hostConfig.supportsInteractivity||!e.isInteractive},t.prototype.applyPadding=function(){if(e.prototype.applyPadding.call(this),this.renderedElement){var t=new Ps.SpacingDefinition;this.getEffectivePadding()&&(t=this.hostConfig.paddingDefinitionToSpacingDefinition(this.getEffectivePadding())),this.renderedElement.style.paddingTop=t.top+"px",this.renderedElement.style.paddingRight=t.right+"px",this.renderedElement.style.paddingBottom=t.bottom+"px",this.renderedElement.style.paddingLeft=t.left+"px",this.renderedElement.style.marginRight="0",this.renderedElement.style.marginLeft="0"}},Object.defineProperty(t.prototype,"isSelectable",{get:function(){return!1},enumerable:!1,configurable:!0}),t.prototype.forbiddenChildElements=function(){return[]},t.prototype.releaseDOMResources=function(){e.prototype.releaseDOMResources.call(this);for(var t=0;t<this.getItemCount();t++)this.getItemAt(t).releaseDOMResources()},t.prototype.internalValidateProperties=function(t){e.prototype.internalValidateProperties.call(this,t);for(var r=0;r<this.getItemCount();r++){var n=this.getItemAt(r);!this.hostConfig.supportsInteractivity&&n.isInteractive&&t.addFailure(this,As.ValidationEvent.InteractivityNotAllowed,Ns.Strings.errors.interactivityNotAllowed()),this.isElementAllowed(n)||t.addFailure(this,As.ValidationEvent.InteractivityNotAllowed,Ns.Strings.errors.elementTypeNotAllowed(n.getJsonTypeName())),n.internalValidateProperties(t)}this._selectAction&&this._selectAction.internalValidateProperties(t)},t.prototype.render=function(){var t=this,r=e.prototype.render.call(this);if(r){var n=this.hostConfig;this.allowVerticalOverflow&&(r.style.overflowX="hidden",r.style.overflowY="auto"),r&&this.isSelectable&&this._selectAction&&n.supportsInteractivity&&(r.onclick=function(e){t._selectAction&&t._selectAction.isEffectivelyEnabled()&&(e.preventDefault(),e.cancelBubble=!0,t._selectAction.execute())},r.onkeypress=function(e){t._selectAction&&t._selectAction.isEffectivelyEnabled()&&("Enter"===e.code||"Space"===e.code)&&(e.preventDefault(),e.cancelBubble=!0,t._selectAction.execute())},this._selectAction.setupElementForAccessibility(r),this._selectAction.isEffectivelyEnabled()&&r.classList.add(n.makeCssClassName("ac-selectable")))}return r},t.prototype.updateLayout=function(t){if(void 0===t&&(t=!0),e.prototype.updateLayout.call(this,t),t)for(var r=0;r<this.getItemCount();r++)this.getItemAt(r).updateLayout()},t.prototype.getAllInputs=function(e){void 0===e&&(e=!0);for(var t=[],r=0;r<this.getItemCount();r++)t.push.apply(t,this.getItemAt(r).getAllInputs(e));return t},t.prototype.getAllActions=function(){for(var t=e.prototype.getAllActions.call(this),r=0;r<this.getItemCount();r++)t.push.apply(t,this.getItemAt(r).getAllActions());return this._selectAction&&t.push(this._selectAction),t},t.prototype.getResourceInformation=function(){for(var e=[],t=0;t<this.getItemCount();t++)e.push.apply(e,this.getItemAt(t).getResourceInformation());return e},t.prototype.getElementById=function(t){var r=e.prototype.getElementById.call(this,t);if(!r)for(var n=0;n<this.getItemCount()&&!(r=this.getItemAt(n).getElementById(t));n++);return r},t.prototype.findDOMNodeOwner=function(t){for(var r,n=void 0,i=0;i<this.getItemCount();i++)if(n=this.getItemAt(i).findDOMNodeOwner(t))return n;for(i=0;i<this.getActionCount();i++)if(n=null===(r=this.getActionAt(i))||void 0===r?void 0:r.findDOMNodeOwner(t))return n;return e.prototype.findDOMNodeOwner.call(this,t)},t.selectActionProperty=new $s(Ls.Versions.v1_1,"selectAction",["Action.ShowCard"]),Ss([(0,Ls.property)(t.selectActionProperty)],t.prototype,"_selectAction",void 0),t}(Rs);yo.CardElementContainer=Ys;var Zs=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t._images=[],t.imageSize=As.ImageSize.Medium,t.presentationStyle=As.ImageSetPresentationStyle.Default,t.pixelOffset=0,t}return ks(t,e),t.prototype.internalRender=function(){var e=void 0;if(this._images.length>0){(e=document.createElement("div")).style.display="flex",e.style.flexWrap="wrap";for(var t=0,r=this._images;t<r.length;t++){var n=r[t];switch(this.imageSize){case As.ImageSize.Small:n.size=As.Size.Small;break;case As.ImageSize.Large:n.size=As.Size.Large;break;default:n.size=As.Size.Medium}n.maxHeight=this.hostConfig.imageSet.maxImageHeight;var i=n.render();i&&(i.style.display="inline-flex",i.style.margin="0px",this.presentationStyle==As.ImageSetPresentationStyle.Default&&(i.style.marginRight="10px"),Es.appendChild(e,i))}this.presentationStyle==As.ImageSetPresentationStyle.Stacked&&this.applyStackedPresentationStyle()}return e},t.prototype.applyStackedPresentationStyle=function(){if(this._images[0].renderedImageElement){var e=Ks.parseNumericPixelDimension(this._images[0].renderedImageElement.style.height),t=this.getEffectiveBackgroundColor();if(e)new Ks(this.pixelOffset,e,t).configureImagesArrayAsStackedLayout(this._images)}},t.prototype.getEffectiveBackgroundColor=function(){var e=this.getParentContainer(),t=null==e?void 0:e.getEffectiveStyle(),r=this.hostConfig.containerStyles.getStyleByName(t,this.hostConfig.containerStyles.getStyleByName(this.defaultStyle));return Es.stringToCssColor(r.backgroundColor)},t.prototype.getItemCount=function(){return this._images.length},t.prototype.getItemAt=function(e){return this._images[e]},t.prototype.getFirstVisibleRenderedItem=function(){return this._images&&this._images.length>0?this._images[0]:void 0},t.prototype.getLastVisibleRenderedItem=function(){return this._images&&this._images.length>0?this._images[this._images.length-1]:void 0},t.prototype.removeItem=function(e){if(e instanceof Xs){var t=this._images.indexOf(e);if(t>=0)return this._images.splice(t,1),e.setParent(void 0),this.updateLayout(),!0}return!1},t.prototype.getJsonTypeName=function(){return"ImageSet"},t.prototype.addImage=function(e){if(e.parent)throw new Error("This image already belongs to another ImageSet");this._images.push(e),e.setParent(this)},t.prototype.indexOf=function(e){return e instanceof Xs?this._images.indexOf(e):-1},t.imagesProperty=new Ls.SerializableObjectCollectionProperty(Ls.Versions.v1_0,"images",Xs,function(e,t){t.setParent(e)}),t.imageSizeProperty=new Ls.EnumProperty(Ls.Versions.v1_0,"imageSize",As.ImageSize,As.ImageSize.Medium),t.imagePresentationStyle=new Ls.EnumProperty(Ls.Versions.v1_6,"style",As.ImageSetPresentationStyle,As.ImageSetPresentationStyle.Default),t.pixelOffset=new Ls.NumProperty(Ls.Versions.v1_6,"offset",0,void 0),Ss([(0,Ls.property)(t.imagesProperty)],t.prototype,"_images",void 0),Ss([(0,Ls.property)(t.imageSizeProperty)],t.prototype,"imageSize",void 0),Ss([(0,Ls.property)(t.imagePresentationStyle)],t.prototype,"presentationStyle",void 0),Ss([(0,Ls.property)(t.pixelOffset)],t.prototype,"pixelOffset",void 0),t}(Ys);yo.ImageSet=Zs;var Ks=function(){function e(e,t,r){this.sign45=.7071,this.maxImageCounts=2,this.offset=0,this.normalizationConstant=0,this.border=5,this.dimension=0,this.dimension=t,this.normalizationConstant=2*(t*this.sign45-.5*t),this.offset=this.sign45*(Math.max(e,-t)-this.normalizationConstant),this.style=r||""}return e.prototype.moveImageRight=function(e){e.style.marginLeft=this.offset+"px"},e.prototype.moveImageUp=function(e){e.style.marginBottom=this.offset+this.dimension+"px"},e.prototype.moveImageDown=function(e){e.style.marginTop=this.offset+this.dimension+"px"},e.prototype.makeImageRound=function(e){e.style.borderRadius="50%",e.style.backgroundPosition="50% 50%",e.style.backgroundRepeat="no-repeat"},e.prototype.applyBorder=function(e){e.style.height=this.dimension+2*this.border+"px",e.style.border=this.border+"px solid "+this.style},e.prototype.configureImageForBottomLeft=function(e){this.moveImageDown(e),this.makeImageRound(e),this.applyBorder(e),e.style.zIndex="2"},e.prototype.configureImageForTopRight=function(e){this.moveImageUp(e),this.moveImageRight(e),this.makeImageRound(e),e.style.zIndex="1"},e.prototype.configureImagesArrayAsStackedLayout=function(e){1==e.length?e[0].renderedImageElement&&this.makeImageRound(e[0].renderedImageElement):e.length<=this.maxImageCounts&&e[0].renderedImageElement&&e[1].renderedImageElement&&(this.configureImageForBottomLeft(e[0].renderedImageElement),this.configureImageForTopRight(e[1].renderedImageElement))},e.parseNumericPixelDimension=function(e){if("px"==(null==e?void 0:e.substring(e.length-2)))return parseInt(e.substring(0,e.length-2))},e}(),Qs=function(e){function t(t,r){var n=e.call(this)||this;return n.url=t,n.mimeType=r,n}return ks(t,e),t.prototype.isValid=function(){return!(!this.mimeType||!this.url)},t.mimeTypeProperty=new Ls.StringProperty(Ls.Versions.v1_1,"mimeType"),t.urlProperty=new Ls.StringProperty(Ls.Versions.v1_1,"url"),Ss([(0,Ls.property)(t.mimeTypeProperty)],t.prototype,"mimeType",void 0),Ss([(0,Ls.property)(t.urlProperty)],t.prototype,"url",void 0),t}(Ls.SerializableObject);yo.ContentSource=Qs;var el=function(e){function t(t,r,n){var i=e.call(this,t,r)||this;return i.label=n,i}return ks(t,e),t.prototype.getSchemaKey=function(){return"CaptionSource"},t.prototype.render=function(){var e=void 0;return this.isValid()&&((e=document.createElement("track")).src=this.url,e.kind="captions",e.label=this.label),e},t.labelProperty=new Ls.StringProperty(Ls.Versions.v1_6,"label"),Ss([(0,Ls.property)(t.labelProperty)],t.prototype,"label",void 0),t}(Qs);yo.CaptionSource=el;var tl=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return ks(t,e),t.prototype.getSchemaKey=function(){return"MediaSource"},t.prototype.render=function(){var e=void 0;return this.isValid()&&((e=document.createElement("source")).src=this.url,e.type=this.mimeType),e},t}(Qs);yo.MediaSource=tl;var rl=function(){function e(){}return e.prototype.play=function(){},Object.defineProperty(e.prototype,"posterUrl",{get:function(){return this._posterUrl},set:function(e){this._posterUrl=e},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"selectedMediaType",{get:function(){},enumerable:!1,configurable:!0}),e}();yo.MediaPlayer=rl;var nl=function(e){function t(t){var r=e.call(this)||this;return r.owner=t,r._selectedSources=[],r._captionSources=[],r.processSources(),r}return ks(t,e),t.prototype.processSources=function(){var e;this._selectedSources=[],this._captionSources=[],this._selectedMediaType=void 0;for(var r=0,n=this.owner.sources;r<n.length;r++){var i=n[r],o=i.mimeType?i.mimeType.split("/"):[];if(2===o.length){if(!this._selectedMediaType){var a=t.supportedMediaTypes.indexOf(o[0]);a>=0&&(this._selectedMediaType=t.supportedMediaTypes[a])}o[0]===this._selectedMediaType&&this._selectedSources.push(i)}}(e=this._captionSources).push.apply(e,this.owner.captionSources)},t.prototype.canPlay=function(){return this._selectedSources.length>0},t.prototype.fetchVideoDetails=function(){return _s(this,void 0,void 0,function(){return Ts(this,function(e){return[2]})})},t.prototype.render=function(){"video"===this._selectedMediaType?this._mediaElement=document.createElement("video"):this._mediaElement=document.createElement("audio"),this._mediaElement.setAttribute("aria-label",this.owner.altText?this.owner.altText:Ns.Strings.defaults.mediaPlayerAriaLabel()),this._mediaElement.setAttribute("webkit-playsinline",""),this._mediaElement.setAttribute("playsinline",""),this._mediaElement.setAttribute("crossorigin",""),this._mediaElement.autoplay=!0,this._mediaElement.controls=!0,Es.isMobileOS()&&(this._mediaElement.muted=!0),this._mediaElement.preload="none",this._mediaElement.style.width="100%";for(var e=0,t=this.owner.sources;e<t.length;e++){var r=t[e].render();Es.appendChild(this._mediaElement,r)}for(var n=0,i=this.owner.captionSources;n<i.length;n++){var o=i[n];if("vtt"==o.mimeType){var a=o.render();Es.appendChild(this._mediaElement,a)}}return this._mediaElement},t.prototype.play=function(){this._mediaElement&&this._mediaElement.play()},Object.defineProperty(t.prototype,"selectedMediaType",{get:function(){return this._selectedMediaType},enumerable:!1,configurable:!0}),t.supportedMediaTypes=["audio","video"],t}(rl);yo.HTML5MediaPlayer=nl;var il=function(e){function t(t){return e.call(this)||this}return ks(t,e),t}(rl);yo.CustomMediaPlayer=il;var ol=function(e){function t(t,r){var n=e.call(this,t)||this;return n.iFrameTitle=r,t.length>=2&&(n._videoId=t[1]),n}return ks(t,e),t.prototype.canPlay=function(){return void 0!==this._videoId},t.prototype.render=function(){var e=document.createElement("div");e.style.position="relative",e.style.width="100%",e.style.height="0",e.style.paddingBottom="56.25%";var t=document.createElement("iframe");return t.style.position="absolute",t.style.top="0",t.style.left="0",t.style.width="100%",t.style.height="100%",t.src=this.getEmbedVideoUrl(),t.frameBorder="0",this.iFrameTitle&&(t.title=this.iFrameTitle),t.allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture",t.allowFullscreen=!0,e.appendChild(t),e},Object.defineProperty(t.prototype,"videoId",{get:function(){return this._videoId},enumerable:!1,configurable:!0}),t}(il);yo.IFrameMediaMediaPlayer=ol;var al=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return ks(t,e),t.prototype.fetchVideoDetails=function(){return _s(this,void 0,void 0,function(){var e,t,r;return Ts(this,function(n){switch(n.label){case 0:return e="https://vimeo.com/api/oembed.json?url=".concat(this.getEmbedVideoUrl()),[4,fetch(e)];case 1:return(t=n.sent()).ok?[4,t.json()]:[3,3];case 2:r=n.sent(),this.posterUrl=r.thumbnail_url,n.label=3;case 3:return[2]}})})},t.prototype.getEmbedVideoUrl=function(){return"https://player.vimeo.com/video/".concat(this.videoId,"?autoplay=1")},t}(ol);yo.VimeoPlayer=al;var sl=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return ks(t,e),t.prototype.fetchVideoDetails=function(){return _s(this,void 0,void 0,function(){var e,t,r;return Ts(this,function(n){switch(n.label){case 0:return e="https://api.dailymotion.com/video/".concat(this.videoId,"?fields=thumbnail_720_url"),[4,fetch(e)];case 1:return(t=n.sent()).ok?[4,t.json()]:[3,3];case 2:r=n.sent(),this.posterUrl=r.thumbnail_720_url,n.label=3;case 3:return[2]}})})},t.prototype.getEmbedVideoUrl=function(){return"https://www.dailymotion.com/embed/video/".concat(this.videoId,"?autoplay=1")},t}(ol);yo.DailymotionPlayer=sl;var ll=function(e){function t(t,r){var n=e.call(this,t,r)||this;return n.iFrameTitle=r,t.length>=3&&void 0!==t[2]&&(n._startTimeIndex=parseInt(t[2])),n}return ks(t,e),t.prototype.fetchVideoDetails=function(){return _s(this,void 0,void 0,function(){return Ts(this,function(e){return this.posterUrl=this.videoId?"https://img.youtube.com/vi/".concat(this.videoId,"/maxresdefault.jpg"):void 0,[2]})})},t.prototype.getEmbedVideoUrl=function(){var e="https://www.youtube.com/embed/".concat(this.videoId,"?autoplay=1");return void 0!==this._startTimeIndex&&(e+="&start=".concat(this._startTimeIndex)),e},t}(ol);yo.YouTubePlayer=ll;var cl,ul,hl=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.sources=[],t.captionSources=[],t}return ks(t,e),t.prototype.createMediaPlayer=function(){for(var e=0,r=t.customMediaPlayers;e<r.length;e++)for(var n=r[e],i=0,o=this.sources;i<o.length;i++){var a=o[i];if(a.url)for(var s=0,l=n.urlPatterns;s<l.length;s++){var c=l[s].exec(a.url);if(null!==c)return n.createMediaPlayer(c)}}return new nl(this)},t.prototype.handlePlayButtonInvoke=function(e){if(this.hostConfig.media.allowInlinePlayback){if(e.preventDefault(),e.cancelBubble=!0,this.renderedElement){var r=this._mediaPlayer.render();Os(this.renderedElement),this.renderedElement.appendChild(r),this._mediaPlayer.play(),r.focus()}}else t.onPlay&&(e.preventDefault(),e.cancelBubble=!0,t.onPlay(this))},t.prototype.displayPoster=function(){return _s(this,void 0,void 0,function(){var e,t,r,n,i,o,a=this;return Ts(this,function(s){return this.renderedElement&&((e=document.createElement("div")).className=this.hostConfig.makeCssClassName("ac-media-poster"),e.setAttribute("role","contentinfo"),e.setAttribute("aria-label",this.altText?this.altText:Ns.Strings.defaults.mediaPlayerAriaLabel()),e.style.position="relative",e.style.display="flex",(t=this.poster?this.poster:this._mediaPlayer.posterUrl)||(t=this.hostConfig.media.defaultPoster),t?((r=document.createElement("img")).style.width="100%",r.style.height="100%",r.setAttribute("role","presentation"),r.onerror=function(t){r.parentNode&&r.parentNode.removeChild(r),e.classList.add("empty"),e.style.minHeight="150px"},r.src=t,e.appendChild(r)):(e.classList.add("empty"),e.style.minHeight="150px"),this.hostConfig.supportsInteractivity&&this._mediaPlayer.canPlay()&&((n=document.createElement("div")).tabIndex=0,n.setAttribute("role","button"),n.setAttribute("aria-label",Ns.Strings.defaults.mediaPlayerPlayMedia()),n.className=this.hostConfig.makeCssClassName("ac-media-playButton"),n.style.display="flex",n.style.alignItems="center",n.style.justifyContent="center",n.onclick=function(e){a.handlePlayButtonInvoke(e)},n.onkeypress=function(e){"Enter"!==e.code&&"Space"!==e.code||a.handlePlayButtonInvoke(e)},(i=document.createElement("div")).className=this.hostConfig.makeCssClassName("ac-media-playButton-arrow"),i.style.width="12px",i.style.height="15px",i.style.borderTopWidth="7.5px",i.style.borderBottomWidth="7.5px",i.style.borderLeftWidth="12px",i.style.borderRightWidth="0",i.style.borderStyle="solid",i.style.borderTopColor="transparent",i.style.borderRightColor="transparent",i.style.borderBottomColor="transparent",i.style.transform="translate(1.2px,0px)",n.appendChild(i),(o=document.createElement("div")).style.position="absolute",o.style.left="0",o.style.top="0",o.style.width="100%",o.style.height="100%",o.style.display="flex",o.style.justifyContent="center",o.style.alignItems="center",o.appendChild(n),e.appendChild(o)),Os(this.renderedElement),this.renderedElement.appendChild(e)),[2]})})},t.prototype.internalRender=function(){var e=document.createElement("div");return e.className=this.hostConfig.makeCssClassName("ac-media"),e},t.prototype.render=function(){var t=this,r=e.prototype.render.call(this);return r&&(this._mediaPlayer=this.createMediaPlayer(),this._mediaPlayer.fetchVideoDetails().then(function(){return t.displayPoster()})),r},t.prototype.releaseDOMResources=function(){e.prototype.releaseDOMResources.call(this),this.displayPoster()},t.prototype.getJsonTypeName=function(){return"Media"},t.prototype.getResourceInformation=function(){var e=[];if(this._mediaPlayer){var t=this.poster?this.poster:this.hostConfig.media.defaultPoster;t&&e.push({url:t,mimeType:"image"})}for(var r=0,n=this.sources;r<n.length;r++){var i=n[r];i.isValid()&&e.push({url:i.url,mimeType:i.mimeType})}for(var o=0,a=this.captionSources;o<a.length;o++){var s=a[o];s.isValid()&&e.push({url:s.url,mimeType:s.mimeType})}return e},Object.defineProperty(t.prototype,"selectedMediaType",{get:function(){return this._mediaPlayer.selectedMediaType},enumerable:!1,configurable:!0}),t.customMediaPlayers=[{urlPatterns:[/^(?:https?:\/\/)?(?:www.)?youtube.com\/watch\?(?=.*v=([\w\d-_]+))(?=(?:.*t=(\d+))?).*/gi,/^(?:https?:\/\/)?youtu.be\/([\w\d-_]+)(?:\?t=(\d+))?/gi],createMediaPlayer:function(e){return new ll(e,Ns.Strings.defaults.youTubeVideoPlayer())}},{urlPatterns:[/^(?:https?:\/\/)?vimeo.com\/([\w\d-_]+).*/gi],createMediaPlayer:function(e){return new al(e,Ns.Strings.defaults.vimeoVideoPlayer())}},{urlPatterns:[/^(?:https?:\/\/)?(?:www.)?dailymotion.com\/video\/([\w\d-_]+).*/gi],createMediaPlayer:function(e){return new sl(e,Ns.Strings.defaults.dailymotionVideoPlayer())}}],t.sourcesProperty=new Ls.SerializableObjectCollectionProperty(Ls.Versions.v1_1,"sources",tl),t.captionSourcesProperty=new Ls.SerializableObjectCollectionProperty(Ls.Versions.v1_6,"captionSources",el),t.posterProperty=new Ls.StringProperty(Ls.Versions.v1_1,"poster"),t.altTextProperty=new Ls.StringProperty(Ls.Versions.v1_1,"altText"),Ss([(0,Ls.property)(t.sourcesProperty)],t.prototype,"sources",void 0),Ss([(0,Ls.property)(t.captionSourcesProperty)],t.prototype,"captionSources",void 0),Ss([(0,Ls.property)(t.posterProperty)],t.prototype,"poster",void 0),Ss([(0,Ls.property)(t.altTextProperty)],t.prototype,"altText",void 0),t}(Rs);yo.Media=hl,(ul=cl||(cl={}))[ul.InitialRender=0]="InitialRender",ul[ul.MouseEnterOnCard=1]="MouseEnterOnCard",ul[ul.MouseLeaveOnCard=2]="MouseLeaveOnCard",ul[ul.FocusLeave=3]="FocusLeave";var dl=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.inputStyle=As.InputStyle.Default,t}return ks(t,e),t.prototype.getAllLabelIds=function(){var e=[];return this.labelledBy&&e.push(this.labelledBy),this._renderedLabelElement&&e.push(this._renderedLabelElement.id),this._renderedErrorMessageElement&&e.push(this._renderedErrorMessageElement.id),e},t.prototype.updateInputControlAriaLabelledBy=function(){if(this._renderedInputControlElement){var e=this.getAllLabelIds();e.length>0?this._renderedInputControlElement.setAttribute("aria-labelledby",e.join(" ")):this._renderedInputControlElement.removeAttribute("aria-labelledby")}},Object.defineProperty(t.prototype,"isNullable",{get:function(){return!0},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"renderedInputControlElement",{get:function(){return this._renderedInputControlElement},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"inputControlContainerElement",{get:function(){return this._inputControlContainerElement},enumerable:!1,configurable:!0}),t.prototype.overrideInternalRender=function(){var e=this,t=this.hostConfig;this._outerContainerElement=document.createElement("div"),this._outerContainerElement.style.display="flex",this.labelPosition===As.InputLabelPosition.Inline?this._outerContainerElement.style.flexDirection="row":this._outerContainerElement.style.flexDirection="column";var r=Es.generateUniqueId();if(this.label){var n=new Hs;n.setParent(this),n.forElementId=r;var i=new Ws(this.label);if(n.addInline(i),this.isRequired){i.init(t.inputs.label.requiredInputs);var o=new Ws(t.inputs.label.requiredInputs.suffix);o.color=t.inputs.label.requiredInputs.suffixColor,o.ariaHidden=!0,n.addInline(o)}else i.init(t.inputs.label.optionalInputs);this._renderedLabelElement=n.render(),this._renderedLabelElement&&(this._renderedLabelElement.id=Es.generateUniqueId(),this.labelPosition===As.InputLabelPosition.Inline?this._renderedLabelElement.style.alignSelf="center":this._renderedLabelElement.style.marginBottom=t.getEffectiveSpacing(t.inputs.label.inputSpacing)+"px",this._outerContainerElement.appendChild(this._renderedLabelElement))}if(this._inputControlContainerElement=document.createElement("div"),this._inputControlContainerElement.className=t.makeCssClassName("ac-input-container"),this._inputControlContainerElement.style.display="flex","stretch"===this.height&&(this._inputControlContainerElement.style.alignItems="stretch",this._inputControlContainerElement.style.flex="1 1 auto"),this._renderedInputControlElement=this.internalRender(),this._renderedInputControlElement){if(this._renderedInputControlElement.id=r,this._renderedInputControlElement.style.minWidth="0px",this.isNullable&&this.isRequired&&(this._renderedInputControlElement.setAttribute("aria-required","true"),this._renderedInputControlElement.classList.add(t.makeCssClassName("ac-input-required"))),this._inputControlContainerElement.appendChild(this._renderedInputControlElement),this._outerContainerElement.appendChild(this._inputControlContainerElement),this._renderedLabelElement&&this.labelPosition===As.InputLabelPosition.Inline)if(this.labelWidth){if(this.labelWidth.unit==As.SizeUnit.Weight){var a=this.labelWidth.physicalSize;this._renderedLabelElement.style.width=a.toString()+"%",this._inputControlContainerElement.style.width=(100-a).toString()+"%"}else if(this.labelWidth.unit==As.SizeUnit.Pixel){var s=this.labelWidth.physicalSize;this._renderedLabelElement.style.width=s.toString()+"px"}}else{var l=t.inputs.label.width;this._renderedLabelElement.style.width=l.toString()+"%",this._inputControlContainerElement.style.width=100-l+"%"}return this.updateVisualState(cl.InitialRender),this._renderedInputControlElement&&(this._renderedInputControlElement.onblur=function(t){e.updateVisualState(cl.FocusLeave)}),this.updateInputControlAriaLabelledBy(),this._outerContainerElement}this.resetDirtyState()},t.prototype.valueChanged=function(){var e,t,r;this.getRootElement().updateActionsEnabledState(),this.isValid()&&this.resetValidationFailureCue(),this.onValueChanged&&this.onValueChanged(this),t=(e=this).getRootElement(),(r=t&&t.onInputValueChanged?t.onInputValueChanged:sc.onInputValueChanged)&&r(e)},t.prototype.resetValidationFailureCue=function(){this.renderedInputControlElement&&(this.renderedInputControlElement.classList.remove(this.hostConfig.makeCssClassName("ac-input-validation-failed")),this.updateInputControlAriaLabelledBy(),this._renderedErrorMessageElement&&(this._outerContainerElement.removeChild(this._renderedErrorMessageElement),this._renderedErrorMessageElement=void 0))},t.prototype.showValidationErrorMessage=function(){if(this.renderedElement&&this.errorMessage&&Ps.GlobalSettings.displayInputValidationErrors){var e=new Vs;e.setParent(this),e.text=this.errorMessage,e.wrap=!0,e.init(this.hostConfig.inputs.errorMessage),this._renderedErrorMessageElement=e.render(),this._renderedErrorMessageElement&&(this._renderedErrorMessageElement.id=Es.generateUniqueId(),this._outerContainerElement.appendChild(this._renderedErrorMessageElement),this.updateInputControlAriaLabelledBy())}},Object.defineProperty(t.prototype,"allowRevealOnHoverStyle",{get:function(){return this.hostConfig.inputs&&this.hostConfig.inputs.allowRevealOnHoverStyle},enumerable:!1,configurable:!0}),t.prototype.shouldHideInputAdornersForRevealOnHover=function(e,t){var r=e===document.activeElement,n=this.hostConfig.makeCssClassName("ac-inputStyle-revealOnHover-onhover"),i=e.classList.contains(n);return t===cl.InitialRender||t===cl.FocusLeave&&!i||t===cl.MouseLeaveOnCard&&!r},t.prototype.updateVisualState=function(e){this.allowRevealOnHoverStyle&&this._renderedInputControlElement&&this.inputStyle===As.InputStyle.RevealOnHover&&(e===cl.InitialRender?this._renderedInputControlElement.classList.add(this.hostConfig.makeCssClassName("ac-inputStyle-revealOnHover-onrender")):e===cl.MouseEnterOnCard?this._renderedInputControlElement.classList.add(this.hostConfig.makeCssClassName("ac-inputStyle-revealOnHover-onhover")):e===cl.MouseLeaveOnCard&&this._renderedInputControlElement.classList.remove(this.hostConfig.makeCssClassName("ac-inputStyle-revealOnHover-onhover")))},t.prototype.focus=function(){this._renderedInputControlElement&&this._renderedInputControlElement.focus()},t.prototype.isValid=function(){return!0},t.prototype.isDirty=function(){return this.value!==this._oldValue},t.prototype.resetDirtyState=function(){this._oldValue=this.value},t.prototype.internalValidateProperties=function(t){e.prototype.internalValidateProperties.call(this,t),this.id||t.addFailure(this,As.ValidationEvent.PropertyCantBeNull,Ns.Strings.errors.inputsMustHaveUniqueId()),this.isRequired&&(this.label||t.addFailure(this,As.ValidationEvent.RequiredInputsShouldHaveLabel,"Required inputs should have a label"),this.errorMessage||t.addFailure(this,As.ValidationEvent.RequiredInputsShouldHaveErrorMessage,"Required inputs should have an error message"))},t.prototype.validateValue=function(){this.resetValidationFailureCue();var e=this.isRequired?this.isSet()&&this.isValid():this.isValid();return!e&&this.renderedInputControlElement&&(this.renderedInputControlElement.classList.add(this.hostConfig.makeCssClassName("ac-input-validation-failed")),this.showValidationErrorMessage()),e},t.prototype.getAllInputs=function(e){return[this]},t.prototype.render=function(){var t=e.prototype.render.call(this);return this.resetDirtyState(),t},Object.defineProperty(t.prototype,"isInteractive",{get:function(){return!0},enumerable:!1,configurable:!0}),t.labelProperty=new Ls.StringProperty(Ls.Versions.v1_3,"label",!0),t.isRequiredProperty=new Ls.BoolProperty(Ls.Versions.v1_3,"isRequired",!1),t.errorMessageProperty=new Ls.StringProperty(Ls.Versions.v1_3,"errorMessage",!0),t.inputStyleProperty=new Ls.EnumProperty(Ls.Versions.v1_6,"inputStyle",As.InputStyle,As.InputStyle.Default,[{value:As.InputStyle.RevealOnHover},{value:As.InputStyle.Default}]),t.labelWidthProperty=new Ls.CustomProperty(Ls.Versions.v1_6,"labelWidth",function(e,t,r,n){var i=t.defaultValue,o=r[t.name],a=!1;if("number"!=typeof o||isNaN(o))if("string"==typeof o)try{i=Ps.SizeAndUnit.parse(o)}catch(s){a=!0}else a=!0;else((i=new Ps.SizeAndUnit(o,As.SizeUnit.Weight)).physicalSize<0||i.physicalSize>100)&&(a=!0);return a&&(n.logParseEvent(e,As.ValidationEvent.InvalidPropertyValue,Ns.Strings.errors.invalidInputLabelWidth()),i=void 0),i},function(e,t,r,n,i){n instanceof Ps.SizeAndUnit&&(n.unit===As.SizeUnit.Pixel?i.serializeValue(r,"labelWidth",n.physicalSize+"px"):i.serializeNumber(r,"labelWidth",n.physicalSize))},void 0),t.labelPositionProperty=new Ls.EnumProperty(Ls.Versions.v1_6,"labelPosition",As.InputLabelPosition,As.InputLabelPosition.Above,[{value:As.InputLabelPosition.Inline},{value:As.InputLabelPosition.Above}]),Ss([(0,Ls.property)(t.labelProperty)],t.prototype,"label",void 0),Ss([(0,Ls.property)(t.isRequiredProperty)],t.prototype,"isRequired",void 0),Ss([(0,Ls.property)(t.errorMessageProperty)],t.prototype,"errorMessage",void 0),Ss([(0,Ls.property)(t.inputStyleProperty)],t.prototype,"inputStyle",void 0),Ss([(0,Ls.property)(t.labelWidthProperty)],t.prototype,"labelWidth",void 0),Ss([(0,Ls.property)(t.labelPositionProperty)],t.prototype,"labelPosition",void 0),t}(Rs);yo.Input=dl;var pl=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.isMultiline=!1,t.style=As.InputTextStyle.Text,t}return ks(t,e),t.prototype.setupInput=function(e){var t=this;e.style.flex="1 1 auto",e.tabIndex=this.isDesignMode()?-1:0,this.placeholder&&(e.placeholder=this.placeholder,e.setAttribute("aria-label",this.placeholder)),this.defaultValue&&(e.value=this.defaultValue),this.maxLength&&this.maxLength>0&&(e.maxLength=this.maxLength),e.oninput=function(){t.valueChanged()},e.onkeypress=function(e){e.ctrlKey&&"Enter"===e.code&&t.inlineAction&&t.inlineAction.isEffectivelyEnabled()&&t.inlineAction.execute()}},t.prototype.internalRender=function(){var e;return this.isMultiline&&this.style!==As.InputTextStyle.Password?((e=document.createElement("textarea")).className=this.hostConfig.makeCssClassName("ac-input","ac-textInput","ac-multiline"),"stretch"===this.height&&(e.style.height="initial")):((e=document.createElement("input")).className=this.hostConfig.makeCssClassName("ac-input","ac-textInput"),e.type=As.InputTextStyle[this.style].toLowerCase()),this.setupInput(e),e},t.prototype.overrideInternalRender=function(){var t=this,r=e.prototype.overrideInternalRender.call(this);if(this.inlineAction){var n=document.createElement("button");if(n.className=this.hostConfig.makeCssClassName(this.inlineAction.isEffectivelyEnabled()?"ac-inlineActionButton":"ac-inlineActionButton-disabled"),n.onclick=function(e){t.inlineAction&&t.inlineAction.isEffectivelyEnabled()&&(e.preventDefault(),e.cancelBubble=!0,t.inlineAction.execute())},this.inlineAction.iconUrl){n.classList.add("iconOnly");var i=document.createElement("img");i.style.height="100%",i.setAttribute("role","presentation"),i.style.display="none",i.onload=function(){i.style.removeProperty("display")},i.onerror=function(){n.removeChild(i),n.classList.remove("iconOnly"),n.classList.add("textOnly"),n.textContent=t.inlineAction&&t.inlineAction.title?t.inlineAction.title:Ns.Strings.defaults.inlineActionTitle()},i.src=this.inlineAction.iconUrl,n.appendChild(i),n.title=this.inlineAction.title?this.inlineAction.title:Ns.Strings.defaults.inlineActionTitle()}else n.classList.add("textOnly"),n.textContent=this.inlineAction.title?this.inlineAction.title:Ns.Strings.defaults.inlineActionTitle();this.inlineAction.setupElementForAccessibility(n,!0),n.style.marginLeft="8px",this.inputControlContainerElement.appendChild(n)}return r},t.prototype.updateVisualState=function(t){this.allowRevealOnHoverStyle&&(this.inlineAction||this.isMultiline||e.prototype.updateVisualState.call(this,t))},t.prototype.getJsonTypeName=function(){return"Input.Text"},t.prototype.getAllActions=function(){var t=e.prototype.getAllActions.call(this);return this.inlineAction&&t.push(this.inlineAction),t},t.prototype.getActionById=function(t){var r=e.prototype.getActionById.call(this,t);return!r&&this.inlineAction&&(r=this.inlineAction.getActionById(t)),r},t.prototype.isSet=function(){return!!this.value},t.prototype.isValid=function(){return!this.value||(!this.regex||new RegExp(this.regex,"g").test(this.value))},Object.defineProperty(t.prototype,"value",{get:function(){return this.renderedInputControlElement?(this.isMultiline,this.renderedInputControlElement.value):void 0},enumerable:!1,configurable:!0}),t.valueProperty=new Ls.StringProperty(Ls.Versions.v1_0,"value"),t.maxLengthProperty=new Ls.NumProperty(Ls.Versions.v1_0,"maxLength"),t.isMultilineProperty=new Ls.BoolProperty(Ls.Versions.v1_0,"isMultiline",!1),t.placeholderProperty=new Ls.StringProperty(Ls.Versions.v1_0,"placeholder"),t.styleProperty=new Ls.EnumProperty(Ls.Versions.v1_0,"style",As.InputTextStyle,As.InputTextStyle.Text,[{value:As.InputTextStyle.Text},{value:As.InputTextStyle.Tel},{value:As.InputTextStyle.Url},{value:As.InputTextStyle.Email},{value:As.InputTextStyle.Password,targetVersion:Ls.Versions.v1_5}]),t.inlineActionProperty=new $s(Ls.Versions.v1_0,"inlineAction",["Action.ShowCard"]),t.regexProperty=new Ls.StringProperty(Ls.Versions.v1_3,"regex",!0),Ss([(0,Ls.property)(t.valueProperty)],t.prototype,"defaultValue",void 0),Ss([(0,Ls.property)(t.maxLengthProperty)],t.prototype,"maxLength",void 0),Ss([(0,Ls.property)(t.isMultilineProperty)],t.prototype,"isMultiline",void 0),Ss([(0,Ls.property)(t.placeholderProperty)],t.prototype,"placeholder",void 0),Ss([(0,Ls.property)(t.styleProperty)],t.prototype,"style",void 0),Ss([(0,Ls.property)(t.inlineActionProperty)],t.prototype,"inlineAction",void 0),Ss([(0,Ls.property)(t.regexProperty)],t.prototype,"regex",void 0),t}(dl);yo.TextInput=pl;var fl=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.valueOn="true",t.valueOff="false",t.wrap=!1,t}return ks(t,e),t.prototype.updateInputControlAriaLabelledBy=function(){if(this._checkboxInputElement){var e=this.getAllLabelIds().join(" ");this._checkboxInputLabelElement&&this._checkboxInputLabelElement.id&&(e+=" "+this._checkboxInputLabelElement.id),e?this._checkboxInputElement.setAttribute("aria-labelledby",e):this._checkboxInputElement.removeAttribute("aria-labelledby")}},t.prototype.internalRender=function(){var e=this,t=document.createElement("div");if(t.className=this.hostConfig.makeCssClassName("ac-input","ac-toggleInput"),t.style.width="100%",t.style.display="flex",t.style.alignItems="center",this._checkboxInputElement=document.createElement("input"),this._checkboxInputElement.id=Es.generateUniqueId(),this._checkboxInputElement.type="checkbox",this._checkboxInputElement.style.display="inline-block",this._checkboxInputElement.style.verticalAlign="middle",this._checkboxInputElement.style.margin="0",this._checkboxInputElement.style.flex="0 0 auto",this.title&&this._checkboxInputElement.setAttribute("aria-label",this.title),this.isRequired&&this._checkboxInputElement.setAttribute("aria-required","true"),this._checkboxInputElement.tabIndex=this.isDesignMode()?-1:0,this.defaultValue===this.valueOn&&(this._checkboxInputElement.checked=!0),this._oldCheckboxValue=this._checkboxInputElement.checked,this._checkboxInputElement.onchange=function(){e.valueChanged()},Es.appendChild(t,this._checkboxInputElement),this.title||this.isDesignMode()){var r=new Vs;if(r.setParent(this),r.forElementId=this._checkboxInputElement.id,r.hostConfig=this.hostConfig,r.text=this.title?this.title:this.getJsonTypeName(),r.useMarkdown=Ps.GlobalSettings.useMarkdownInRadioButtonAndCheckbox,r.wrap=this.wrap,this._checkboxInputLabelElement=r.render(),this._checkboxInputLabelElement){this._checkboxInputLabelElement.id=Es.generateUniqueId(),this._checkboxInputLabelElement.style.display="inline-block",this._checkboxInputLabelElement.style.flex="1 1 auto",this._checkboxInputLabelElement.style.marginLeft="6px",this._checkboxInputLabelElement.style.verticalAlign="middle";var n=document.createElement("div");n.style.width="6px",Es.appendChild(t,n),Es.appendChild(t,this._checkboxInputLabelElement)}}return t},Object.defineProperty(t.prototype,"isNullable",{get:function(){return!1},enumerable:!1,configurable:!0}),t.prototype.updateVisualState=function(e){},t.prototype.getJsonTypeName=function(){return"Input.Toggle"},t.prototype.focus=function(){this._checkboxInputElement&&this._checkboxInputElement.focus()},t.prototype.isSet=function(){return this.isRequired?this.value===this.valueOn:!!this.value},t.prototype.isDirty=function(){return!!this._checkboxInputElement&&this._checkboxInputElement.checked!==this._oldCheckboxValue},Object.defineProperty(t.prototype,"value",{get:function(){return this._checkboxInputElement?this._checkboxInputElement.checked?this.valueOn:this.valueOff:void 0},enumerable:!1,configurable:!0}),t.valueProperty=new Ls.StringProperty(Ls.Versions.v1_0,"value"),t.titleProperty=new Ls.StringProperty(Ls.Versions.v1_0,"title"),t.valueOnProperty=new Ls.StringProperty(Ls.Versions.v1_0,"valueOn",!0,void 0,"true",function(e){return"true"}),t.valueOffProperty=new Ls.StringProperty(Ls.Versions.v1_0,"valueOff",!0,void 0,"false",function(e){return"false"}),t.wrapProperty=new Ls.BoolProperty(Ls.Versions.v1_2,"wrap",!1),Ss([(0,Ls.property)(t.valueProperty)],t.prototype,"defaultValue",void 0),Ss([(0,Ls.property)(t.titleProperty)],t.prototype,"title",void 0),Ss([(0,Ls.property)(t.valueOnProperty)],t.prototype,"valueOn",void 0),Ss([(0,Ls.property)(t.valueOffProperty)],t.prototype,"valueOff",void 0),Ss([(0,Ls.property)(t.wrapProperty)],t.prototype,"wrap",void 0),t}(dl);yo.ToggleInput=fl;var gl=function(e){function t(t,r){var n=e.call(this)||this;return n.title=t,n.value=r,n}return ks(t,e),t.prototype.getSchemaKey=function(){return"Choice"},t.titleProperty=new Ls.StringProperty(Ls.Versions.v1_0,"title"),t.valueProperty=new Ls.StringProperty(Ls.Versions.v1_0,"value"),Ss([(0,Ls.property)(t.titleProperty)],t.prototype,"title",void 0),Ss([(0,Ls.property)(t.valueProperty)],t.prototype,"value",void 0),t}(Ls.SerializableObject);yo.Choice=gl;var ml=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return ks(t,e),t.prototype.getSchemaKey=function(){return"choices.data"},t.typeProperty=new Ls.StringProperty(Ls.Versions.v1_6,"type",!0,new RegExp("^Data.Query$")),t.datasetProperty=new Ls.StringProperty(Ls.Versions.v1_6,"dataset"),t.countProperty=new Ls.NumProperty(Ls.Versions.v1_6,"count"),t.skipProperty=new Ls.NumProperty(Ls.Versions.v1_6,"skip"),Ss([(0,Ls.property)(t.typeProperty)],t.prototype,"type",void 0),Ss([(0,Ls.property)(t.datasetProperty)],t.prototype,"dataset",void 0),Ss([(0,Ls.property)(t.countProperty)],t.prototype,"count",void 0),Ss([(0,Ls.property)(t.skipProperty)],t.prototype,"skip",void 0),t}(Ls.SerializableObject);yo.ChoiceSetInputDataQuery=ml;var yl=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.isMultiSelect=!1,t.wrap=!1,t.choices=[],t}return ks(t,e),Object.defineProperty(t.prototype,"isCompact",{get:function(){return!this.style||"compact"===this.style},set:function(e){this.style=e?void 0:"expanded"},enumerable:!1,configurable:!0}),t.getUniqueCategoryName=function(){var e="__ac-category"+t._uniqueCategoryCounter;return t._uniqueCategoryCounter++,e},t.prototype.isDynamicTypeahead=function(){return!!this.choicesData&&!!this.choicesData.dataset&&"Data.Query"===this.choicesData.type},t.prototype.getFilterForDynamicSearch=function(){var e,t;return null===(t=null===(e=this._filteredChoiceSet)||void 0===e?void 0:e.textInput)||void 0===t?void 0:t.value},t.prototype.renderChoices=function(e){var t;null===(t=this._filteredChoiceSet)||void 0===t||t.processResponse(e)},t.prototype.showLoadingIndicator=function(){var e;null===(e=this._filteredChoiceSet)||void 0===e||e.showLoadingIndicator()},t.prototype.removeLoadingIndicator=function(){var e;null===(e=this._filteredChoiceSet)||void 0===e||e.removeLoadingIndicator()},t.prototype.showErrorIndicator=function(e){var t;null===(t=this._filteredChoiceSet)||void 0===t||t.showErrorIndicator(e)},t.prototype.createPlaceholderOptionWhenValueDoesNotExist=function(){if(!this.value){var e=document.createElement("option");return e.selected=!0,e.disabled=!0,e.hidden=!0,e.value="",this.placeholder&&(e.text=this.placeholder),e}},t.prototype.internalApplyAriaCurrent=function(){if(this._selectElement){var e=this._selectElement.options;if(e)for(var t=0,r=Array.from(e);t<r.length;t++){var n=r[t];n.selected?n.setAttribute("aria-current","true"):n.removeAttribute("aria-current")}}},t.prototype.renderCompoundInput=function(e,t,r){var n=this,i=document.createElement("div");i.className=this.hostConfig.makeCssClassName("ac-input",e),i.style.width="100%",i.tabIndex=this.isDesignMode()?-1:0,this._toggleInputs=[],this._labels=[];for(var o=0,a=this.choices;o<a.length;o++){var s=a[o],l=document.createElement("input");l.id=Es.generateUniqueId(),l.type=t,l.style.margin="0",l.style.display="inline-block",l.style.verticalAlign="middle",l.style.flex="0 0 auto",l.name=this.id?this.id:this._uniqueCategoryName,this.isRequired&&l.setAttribute("aria-required","true"),l.tabIndex=this.isDesignMode()?-1:0,s.value&&(l.value=s.value),s.title&&l.setAttribute("aria-label",s.title),r&&s.value&&r.indexOf(s.value)>=0&&(l.checked=!0),l.onchange=function(){n.valueChanged()},this._toggleInputs.push(l);var c=document.createElement("div");c.style.display="flex",c.style.alignItems="center",Es.appendChild(c,l);var u=new Vs;u.setParent(this),u.forElementId=l.id,u.hostConfig=this.hostConfig,u.text=s.title?s.title:"Choice "+this._toggleInputs.length,u.useMarkdown=Ps.GlobalSettings.useMarkdownInRadioButtonAndCheckbox,u.wrap=this.wrap;var h=u.render();if(this._labels.push(h),h){h.id=Es.generateUniqueId(),h.style.display="inline-block",h.style.flex="1 1 auto",h.style.marginLeft="6px",h.style.verticalAlign="middle";var d=document.createElement("div");d.style.width="6px",Es.appendChild(c,d),Es.appendChild(c,h)}Es.appendChild(i,c)}return i},t.prototype.updateInputControlAriaLabelledBy=function(){if((this.isMultiSelect||"expanded"===this.style)&&this._toggleInputs&&this._labels)for(var t=this.getAllLabelIds(),r=0;r<this._toggleInputs.length;r++){var n=t.join(" "),i=this._labels[r];i&&i.id&&(n+=" "+i.id),n?this._toggleInputs[r].setAttribute("aria-labelledby",n):this._toggleInputs[r].removeAttribute("aria-labelledby")}else e.prototype.updateInputControlAriaLabelledBy.call(this)},t.prototype.internalRender=function(){var e=this;if(this._uniqueCategoryName=t.getUniqueCategoryName(),this.isDynamicTypeahead()){var r=new xl(t._uniqueCategoryCounter,this.choices,this.hostConfig);if(r.render(),r.textInput){this._textInput=r.textInput,this.defaultValue&&(this._textInput.value=this.defaultValue),this.placeholder&&!this._textInput.value&&(this._textInput.placeholder=this.placeholder,this._textInput.setAttribute("aria-label",this.placeholder)),this._textInput.tabIndex=this.isDesignMode()?-1:0;var n=Es.debounce(function(){r.processStaticChoices(),e.valueChanged(),e._textInput&&(e.value?(e._textInput.removeAttribute("placeholder"),e._textInput.removeAttribute("aria-label")):e.placeholder&&(e._textInput.placeholder=e.placeholder,e._textInput.setAttribute("aria-label",e.placeholder)))},this.hostConfig.inputs.debounceTimeInMilliSeconds);this._textInput.onclick=n,this._textInput.oninput=n}return r.parent=this,this._filteredChoiceSet=r,r.renderedElement}if(this.isMultiSelect)return this.renderCompoundInput("ac-choiceSetInput-multiSelect","checkbox",this.defaultValue?this.defaultValue.split(this.hostConfig.choiceSetInputValueSeparator):void 0);if("expanded"===this.style)return this.renderCompoundInput("ac-choiceSetInput-expanded","radio",this.defaultValue?[this.defaultValue]:void 0);if("filtered"===this.style){var i=document.createElement("div");i.style.width="100%",this._textInput=document.createElement("input"),this._textInput.className=this.hostConfig.makeCssClassName("ac-input","ac-multichoiceInput","ac-choiceSetInput-filtered"),this._textInput.type="text",this._textInput.style.width="100%",this._textInput.oninput=function(){e.valueChanged(),e._textInput&&(e.value?(e._textInput.removeAttribute("placeholder"),e._textInput.removeAttribute("aria-label")):e.placeholder&&(e._textInput.placeholder=e.placeholder,e._textInput.setAttribute("aria-label",e.placeholder)))},this.defaultValue&&(this._textInput.value=this.defaultValue),this.placeholder&&!this._textInput.value&&(this._textInput.placeholder=this.placeholder,this._textInput.setAttribute("aria-label",this.placeholder)),this._textInput.tabIndex=this.isDesignMode()?-1:0;var o=document.createElement("datalist");o.id=Es.generateUniqueId();for(var a=0,s=this.choices;a<s.length;a++){var l=s[a],c=document.createElement("option");l.title&&(c.value=l.title,c.setAttribute("aria-label",l.title)),c.tabIndex=this.isDesignMode()?-1:0,o.appendChild(c)}return this._textInput.setAttribute("list",o.id),i.append(this._textInput,o),i}this._selectElement=document.createElement("select"),this._selectElement.className=this.hostConfig.makeCssClassName("ac-input","ac-multichoiceInput","ac-choiceSetInput-compact"),this._selectElement.style.width="100%",this._selectElement.tabIndex=this.isDesignMode()?-1:0;var u=this.createPlaceholderOptionWhenValueDoesNotExist();Es.appendChild(this._selectElement,u);for(var h=0,d=this.choices;h<d.length;h++){l=d[h];(c=document.createElement("option")).value=l.value,l.title&&(c.text=l.title,c.setAttribute("aria-label",l.title)),c.tabIndex=this.isDesignMode()?-1:0,l.value===this.defaultValue&&(c.selected=!0),Es.appendChild(this._selectElement,c)}return this._selectElement.onchange=function(){e.internalApplyAriaCurrent(),e.valueChanged()},this.internalApplyAriaCurrent(),this._selectElement},t.prototype.updateVisualState=function(t){this.allowRevealOnHoverStyle&&(!this.isMultiSelect&&this.isCompact&&(e.prototype.updateVisualState.call(this,t),this._selectElement&&this.inputStyle===As.InputStyle.RevealOnHover&&(this.shouldHideInputAdornersForRevealOnHover(this._selectElement,t)?(this._selectElement.style.appearance="none",this._selectElement.classList.remove(this.hostConfig.makeCssClassName("ac-inputStyle-revealOnHover-onfocus"))):(this._selectElement.style.appearance="auto",this._selectElement.classList.add(this.hostConfig.makeCssClassName("ac-inputStyle-revealOnHover-onfocus"))))))},t.prototype.getJsonTypeName=function(){return"Input.ChoiceSet"},t.prototype.focus=function(){this._toggleInputs&&(this.isMultiSelect||"expanded"===this.style)?this._toggleInputs.length>0&&this._toggleInputs[0].focus():this._textInput?this._textInput.focus():e.prototype.focus.call(this)},t.prototype.internalValidateProperties=function(t){e.prototype.internalValidateProperties.call(this,t),0===this.choices.length&&t.addFailure(this,As.ValidationEvent.CollectionCantBeEmpty,Ns.Strings.errors.choiceSetMustHaveAtLeastOneChoice());for(var r=0,n=this.choices;r<n.length;r++){var i=n[r];i.title&&i.value||t.addFailure(this,As.ValidationEvent.PropertyCantBeNull,Ns.Strings.errors.choiceSetChoicesMustHaveTitleAndValue())}},t.prototype.isSet=function(){return!!this.value},t.prototype.isValid=function(){if(this._textInput){if(""===this.value||this.value===this.placeholder)return!0;for(var t=0,r=this.choices;t<r.length;t++){var n=r[t];if(this.value===n.value)return!0}if(this.dynamicChoices)for(var i=0,o=this.dynamicChoices;i<o.length;i++){n=o[i];if(this.value===n)return!0}return!1}return e.prototype.isValid.call(this)},Object.defineProperty(t.prototype,"value",{get:function(){if(this.isMultiSelect){if(!this._toggleInputs||0===this._toggleInputs.length)return;for(var e="",t=0,r=this._toggleInputs;t<r.length;t++){(l=r[t]).checked&&(""!==e&&(e+=this.hostConfig.choiceSetInputValueSeparator),e+=l.value)}return e||void 0}if(this._selectElement)return this._selectElement.selectedIndex>0?this._selectElement.value:void 0;if(this._textInput){for(var n=0,i=this.choices;n<i.length;n++){var o=i[n];if(o.title&&this._textInput.value===o.title)return o.value}return this._textInput.value}if(this._toggleInputs&&this._toggleInputs.length>0)for(var a=0,s=this._toggleInputs;a<s.length;a++){var l;if((l=s[a]).checked)return l.value}},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"dynamicChoices",{get:function(){var e;return null===(e=this._filteredChoiceSet)||void 0===e?void 0:e.dynamicChoices},enumerable:!1,configurable:!0}),t.valueProperty=new Ls.StringProperty(Ls.Versions.v1_0,"value"),t.choicesProperty=new Ls.SerializableObjectCollectionProperty(Ls.Versions.v1_0,"choices",gl),t.choicesDataProperty=new Ls.SerializableObjectProperty(Ls.Versions.v1_6,"choices.data",ml),t.styleProperty=new Ls.ValueSetProperty(Ls.Versions.v1_0,"style",[{value:"compact"},{value:"expanded"},{value:"filtered",targetVersion:Ls.Versions.v1_5}],"compact"),t.isMultiSelectProperty=new Ls.BoolProperty(Ls.Versions.v1_0,"isMultiSelect",!1),t.placeholderProperty=new Ls.StringProperty(Ls.Versions.v1_0,"placeholder"),t.wrapProperty=new Ls.BoolProperty(Ls.Versions.v1_2,"wrap",!1),t._uniqueCategoryCounter=0,Ss([(0,Ls.property)(t.valueProperty)],t.prototype,"defaultValue",void 0),Ss([(0,Ls.property)(t.styleProperty)],t.prototype,"style",void 0),Ss([(0,Ls.property)(t.isMultiSelectProperty)],t.prototype,"isMultiSelect",void 0),Ss([(0,Ls.property)(t.placeholderProperty)],t.prototype,"placeholder",void 0),Ss([(0,Ls.property)(t.wrapProperty)],t.prototype,"wrap",void 0),Ss([(0,Ls.property)(t.choicesProperty)],t.prototype,"choices",void 0),Ss([(0,Ls.property)(t.choicesDataProperty)],t.prototype,"choicesData",void 0),t}(dl);yo.ChoiceSetInput=yl;var xl=function(){function e(e,t,r){this._choiceSetId=e,this._choices=t,this._dynamicChoices=[],this._visibleChoiceCount=0,this._hostConfig=r}return e.prototype.render=function(){var e=this,t=document.createElement("div");t.style.position="relative",t.style.width="100%",this._textInput=document.createElement("input"),this._textInput.className=this.hostConfig.makeCssClassName("ac-input","ac-multichoiceInput","ac-choiceSetInput-filtered"),this._textInput.type="text",this._textInput.style.width="100%",this._textInput.onkeydown=function(t){"ArrowDown"===t.key&&e.focusChoice(0)},this._dropdown=document.createElement("div"),this._dropdown.style.display="none",this._dropdown.className=this.hostConfig.makeCssClassName("ac-input","ac-multichoiceInput","ac-choiceSetInput-filtered-dropdown"),t.append(this._textInput,this._dropdown),document.onclick=function(t){if(e._dropdown){for(var r=e._dropdown.firstChild;r&&t.target!==r;)r=r.nextSibling;(r||t.target!==e._textInput)&&(e._dropdown.style.display="none")}},this._renderedElement=t},e.prototype.createChoice=function(e,t,r){var n=this,i=document.createElement("span");return i.className=this.hostConfig.makeCssClassName("ac-input","ac-choiceSetInput-choice"),i.id="ac-choiceSetInput-".concat(this._choiceSetId,"-choice-").concat(r),i.innerHTML=e.replace(t,"<b>".concat(t,"</b>")),i.tabIndex=-1,i.addEventListener("focusin",function(){i.classList.add("focused")}),i.addEventListener("focusout",function(){i.classList.remove("focused")}),i.onclick=function(){n._textInput&&(n._textInput.value=i.innerText),n._dropdown&&(n._dropdown.style.display="none")},i.onkeydown=function(e){"ArrowDown"===e.key?n.focusChoice(r+1):"ArrowUp"===e.key?n.focusChoice(r-1):"Enter"===e.key&&i.click()},i.onmouseover=function(){n.focusChoice(r)},i},e.prototype.focusChoice=function(e){var t=document.getElementById("ac-choiceSetInput-".concat(this._choiceSetId,"-choice-").concat(e));if(t)t.focus();else if(this._textInput){this._textInput.focus();var r=this._textInput.value.length;this._textInput.setSelectionRange(r,r)}},e.prototype.filterChoices=function(e){var t,r,n=null===(t=this._textInput)||void 0===t?void 0:t.value.toLowerCase();if(n)for(var i=0,o=e?this._dynamicChoices:this._choices;i<o.length;i++){var a=o[i];if(a.title){var s=a.title.toLowerCase().indexOf(n);if(-1!==s){var l=a.title.substring(s,s+n.length),c=this.createChoice(a.title,l,this._visibleChoiceCount++);null===(r=this._dropdown)||void 0===r||r.appendChild(c)}}}},e.prototype.getStatusIndicator=function(e){if(e){if(!this._errorIndicator){var t=document.createElement("div");t.className=this.hostConfig.makeCssClassName("ac-input","ac-choiceSetInput-statusIndicator","ac-choiceSetInput-errorIndicator"),this._errorIndicator=t}return this._errorIndicator.innerText=e,this._errorIndicator}if(!this._loadingIndicator){var r=document.createElement("div");r.className=this.hostConfig.makeCssClassName("ac-input","ac-choiceSetInput-statusIndicator"),this._loadingIndicator=r}return this._loadingIndicator.innerText=0===this._visibleChoiceCount?"Loading...":"Loading more...",this._loadingIndicator},e.prototype.resetDropdown=function(){this._dynamicChoices=[],this._dropdown&&(Es.clearElementChildren(this._dropdown),this._visibleChoiceCount=0)},e.prototype.showDropdown=function(){var e;(null===(e=this._dropdown)||void 0===e?void 0:e.hasChildNodes)&&(this._dropdown.style.display="block")},e.prototype.processStaticChoices=function(){this.resetDropdown(),this.filterChoices(),this.showDropdown()},e.prototype.processResponse=function(e){this._dynamicChoices=e,this.filterChoices(!0),0===this._visibleChoiceCount&&this.showErrorIndicator("No results found.")},e.prototype.showLoadingIndicator=function(){var e,t=this.getStatusIndicator();null===(e=this._dropdown)||void 0===e||e.appendChild(t),this.showDropdown()},e.prototype.removeLoadingIndicator=function(){var e,t;this._loadingIndicator&&(null===(e=this._dropdown)||void 0===e?void 0:e.contains(this._loadingIndicator))&&(null===(t=this._dropdown)||void 0===t||t.removeChild(this._loadingIndicator))},e.prototype.showErrorIndicator=function(e){var t;this.removeLoadingIndicator();var r=this.getStatusIndicator(e);null===(t=this._dropdown)||void 0===t||t.appendChild(r)},Object.defineProperty(e.prototype,"dynamicChoices",{get:function(){var e;return null===(e=this._dynamicChoices)||void 0===e?void 0:e.map(function(e){return e.title})},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"hostConfig",{get:function(){return this._hostConfig?this._hostConfig:this.parent?this.parent.hostConfig:Ms.defaultHostConfig},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"parent",{get:function(){return this._parent},set:function(e){this._parent=e},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"renderedElement",{get:function(){return this._renderedElement},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"textInput",{get:function(){return this._textInput},enumerable:!1,configurable:!0}),e}();yo.FilteredChoiceSet=xl;var bl=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return ks(t,e),t.prototype.internalRender=function(){var e=this;return this._numberInputElement=document.createElement("input"),this._numberInputElement.setAttribute("type","number"),void 0!==this.min&&this._numberInputElement.setAttribute("min",this.min.toString()),void 0!==this.max&&this._numberInputElement.setAttribute("max",this.max.toString()),this._numberInputElement.className=this.hostConfig.makeCssClassName("ac-input","ac-numberInput"),this._numberInputElement.style.width="100%",this._numberInputElement.tabIndex=this.isDesignMode()?-1:0,void 0!==this.defaultValue&&(this._numberInputElement.valueAsNumber=this.defaultValue),this.placeholder&&(this._numberInputElement.placeholder=this.placeholder,this._numberInputElement.setAttribute("aria-label",this.placeholder)),this._numberInputElement.oninput=function(){e.valueChanged()},this._numberInputElement},t.prototype.getJsonTypeName=function(){return"Input.Number"},t.prototype.isSet=function(){return void 0!==this.value&&!isNaN(this.value)},t.prototype.isValid=function(){if(void 0===this.value)return!this.isRequired;var e=!0;return void 0!==this.min&&(e=e&&this.value>=this.min),void 0!==this.max&&(e=e&&this.value<=this.max),e},Object.defineProperty(t.prototype,"value",{get:function(){return this._numberInputElement?this._numberInputElement.valueAsNumber:void 0},set:function(e){e&&this._numberInputElement&&(this._numberInputElement.value=e.toString())},enumerable:!1,configurable:!0}),t.valueProperty=new Ls.NumProperty(Ls.Versions.v1_0,"value"),t.placeholderProperty=new Ls.StringProperty(Ls.Versions.v1_0,"placeholder"),t.minProperty=new Ls.NumProperty(Ls.Versions.v1_0,"min"),t.maxProperty=new Ls.NumProperty(Ls.Versions.v1_0,"max"),Ss([(0,Ls.property)(t.valueProperty)],t.prototype,"defaultValue",void 0),Ss([(0,Ls.property)(t.minProperty)],t.prototype,"min",void 0),Ss([(0,Ls.property)(t.maxProperty)],t.prototype,"max",void 0),Ss([(0,Ls.property)(t.placeholderProperty)],t.prototype,"placeholder",void 0),t}(dl);yo.NumberInput=bl;var vl=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return ks(t,e),t.prototype.internalRender=function(){var e=this;return this._dateInputElement=document.createElement("input"),this._dateInputElement.setAttribute("type","date"),this.min&&this._dateInputElement.setAttribute("min",this.min),this.max&&this._dateInputElement.setAttribute("max",this.max),this.placeholder&&(this._dateInputElement.placeholder=this.placeholder,this._dateInputElement.setAttribute("aria-label",this.placeholder)),this._dateInputElement.tabIndex=this.isDesignMode()?-1:0,this._dateInputElement.className=this.hostConfig.makeCssClassName("ac-input","ac-dateInput"),this._dateInputElement.style.width="100%",this._dateInputElement.oninput=function(){e.valueChanged()},this.defaultValue&&(this._dateInputElement.value=this.defaultValue),this._dateInputElement},t.prototype.updateVisualState=function(t){if(this.allowRevealOnHoverStyle&&(e.prototype.updateVisualState.call(this,t),this._dateInputElement&&this.inputStyle===As.InputStyle.RevealOnHover)){var r=this.shouldHideInputAdornersForRevealOnHover(this._dateInputElement,t);r?this._dateInputElement.classList.remove(this.hostConfig.makeCssClassName("ac-inputStyle-revealOnHover-onfocus")):this._dateInputElement.classList.add(this.hostConfig.makeCssClassName("ac-inputStyle-revealOnHover-onfocus")),ec(this._dateInputElement,r)}},t.prototype.getJsonTypeName=function(){return"Input.Date"},t.prototype.isSet=function(){return!!this.value},t.prototype.isValid=function(){if(!this.value)return!this.isRequired;var e=new Date(this.value),t=!0;if(this.min){var r=new Date(this.min);t=t&&e>=r}if(this.max){var n=new Date(this.max);t=t&&e<=n}return t},Object.defineProperty(t.prototype,"value",{get:function(){return this._dateInputElement?this._dateInputElement.value:void 0},enumerable:!1,configurable:!0}),t.valueProperty=new Ls.StringProperty(Ls.Versions.v1_0,"value"),t.placeholderProperty=new Ls.StringProperty(Ls.Versions.v1_0,"placeholder"),t.minProperty=new Ls.StringProperty(Ls.Versions.v1_0,"min"),t.maxProperty=new Ls.StringProperty(Ls.Versions.v1_0,"max"),Ss([(0,Ls.property)(t.valueProperty)],t.prototype,"defaultValue",void 0),Ss([(0,Ls.property)(t.minProperty)],t.prototype,"min",void 0),Ss([(0,Ls.property)(t.maxProperty)],t.prototype,"max",void 0),Ss([(0,Ls.property)(t.placeholderProperty)],t.prototype,"placeholder",void 0),t}(dl);yo.DateInput=vl;var Cl=function(e){function t(t,r){var n=e.call(this,t,r,function(e,t,r,n){var i=r[t.name];if("string"==typeof i&&i&&/^[0-9]{2}:[0-9]{2}$/.test(i))return i},function(e,t,r,n,i){i.serializeValue(r,t.name,n)})||this;return n.targetVersion=t,n.name=r,n}return ks(t,e),t}(Ls.CustomProperty);yo.TimeProperty=Cl;var wl=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return ks(t,e),t.convertTimeStringToDate=function(e){return new Date("1973-09-04T"+e+":00Z")},t.prototype.internalRender=function(){var e=this;return this._timeInputElement=document.createElement("input"),this._timeInputElement.setAttribute("type","time"),this.min&&this._timeInputElement.setAttribute("min",this.min),this.max&&this._timeInputElement.setAttribute("max",this.max),this._timeInputElement.className=this.hostConfig.makeCssClassName("ac-input","ac-timeInput"),this._timeInputElement.style.width="100%",this._timeInputElement.oninput=function(){e.valueChanged()},this.placeholder&&(this._timeInputElement.placeholder=this.placeholder,this._timeInputElement.setAttribute("aria-label",this.placeholder)),this._timeInputElement.tabIndex=this.isDesignMode()?-1:0,this.defaultValue&&(this._timeInputElement.value=this.defaultValue),this._timeInputElement},t.prototype.updateVisualState=function(t){if(this.allowRevealOnHoverStyle&&(e.prototype.updateVisualState.call(this,t),this._timeInputElement&&this.inputStyle===As.InputStyle.RevealOnHover)){var r=this.shouldHideInputAdornersForRevealOnHover(this._timeInputElement,t);r?this._timeInputElement.classList.remove(this.hostConfig.makeCssClassName("ac-inputStyle-revealOnHover-onfocus")):this._timeInputElement.classList.add(this.hostConfig.makeCssClassName("ac-inputStyle-revealOnHover-onfocus")),ec(this._timeInputElement,r)}},t.prototype.getJsonTypeName=function(){return"Input.Time"},t.prototype.isSet=function(){return!!this.value},t.prototype.isValid=function(){if(!this.value)return!this.isRequired;var e=t.convertTimeStringToDate(this.value),r=!0;if(this.min){var n=t.convertTimeStringToDate(this.min);r=r&&e>=n}if(this.max){var i=t.convertTimeStringToDate(this.max);r=r&&e<=i}return r},Object.defineProperty(t.prototype,"value",{get:function(){return this._timeInputElement?this._timeInputElement.value:void 0},enumerable:!1,configurable:!0}),t.valueProperty=new Cl(Ls.Versions.v1_0,"value"),t.placeholderProperty=new Ls.StringProperty(Ls.Versions.v1_0,"placeholder"),t.minProperty=new Cl(Ls.Versions.v1_0,"min"),t.maxProperty=new Cl(Ls.Versions.v1_0,"max"),Ss([(0,Ls.property)(t.valueProperty)],t.prototype,"defaultValue",void 0),Ss([(0,Ls.property)(t.minProperty)],t.prototype,"min",void 0),Ss([(0,Ls.property)(t.maxProperty)],t.prototype,"max",void 0),Ss([(0,Ls.property)(t.placeholderProperty)],t.prototype,"placeholder",void 0),t}(dl);yo.TimeInput=wl;var kl=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.style=As.ActionStyle.Default,t.mode=As.ActionMode.Primary,t._state=0,t._isFocusable=!0,t}return ks(t,e),t.prototype.renderButtonContent=function(){if(this.renderedElement){var e=this.hostConfig,t=document.createElement("div");if(t.style.overflow="hidden",t.style.textOverflow="ellipsis",e.actions.iconPlacement===As.ActionIconPlacement.AboveTitle||e.actions.allowTitleToWrap||(t.style.whiteSpace="nowrap"),this.title&&(t.innerText=this.title),this.iconUrl){var r=document.createElement("img");r.src=this.iconUrl,r.style.width=e.actions.iconSize+"px",r.style.height=e.actions.iconSize+"px",r.style.flex="0 0 auto",e.actions.iconPlacement===As.ActionIconPlacement.AboveTitle?(this.renderedElement.classList.add("iconAbove"),this.renderedElement.style.flexDirection="column",this.title&&(r.style.marginBottom="6px")):(this.renderedElement.classList.add("iconLeft"),r.style.maxHeight="100%",this.title&&(r.style.marginRight="6px")),this.renderedElement.appendChild(r),this.renderedElement.appendChild(t)}else this.renderedElement.classList.add("noIcon"),this.renderedElement.appendChild(t)}},t.prototype.getParentContainer=function(){return this.parent instanceof Gl?this.parent:this.parent?this.parent.getParentContainer():void 0},t.prototype.isDesignMode=function(){var e=this.getRootObject();return e instanceof Rs&&e.isDesignMode()},t.prototype.updateCssClasses=function(){var e,t;if(this.parent&&this.renderedElement){var r=this.parent.hostConfig;this.renderedElement.className=r.makeCssClassName(this.isEffectivelyEnabled()?"ac-pushButton":"ac-pushButton-disabled");var n=this.getParentContainer();if(n){var i=n.getEffectiveStyle();i&&this.renderedElement.classList.add("style-"+i)}switch(this.renderedElement.tabIndex=!this.isDesignMode()&&this.isFocusable?0:-1,this._state){case 0:break;case 1:this.renderedElement.classList.add(r.makeCssClassName("expanded"));break;case 2:this.renderedElement.classList.add(r.makeCssClassName("subdued"))}this.style&&this.isEffectivelyEnabled()&&(this.style===As.ActionStyle.Positive?(e=this.renderedElement.classList).add.apply(e,r.makeCssClassNames("primary","style-positive")):(t=this.renderedElement.classList).add.apply(t,r.makeCssClassNames("style-"+this.style.toLowerCase())))}},t.prototype.getDefaultSerializationContext=function(){return new cc},t.prototype.internalGetReferencedInputs=function(){return{}},t.prototype.internalPrepareForExecution=function(e){},t.prototype.internalValidateInputs=function(e){var t=[];if(e)for(var r=0,n=Object.keys(e);r<n.length;r++){var i=e[n[r]];i.validateValue()||t.push(i)}return t},t.prototype.shouldSerialize=function(e){return void 0!==e.actionRegistry.findByName(this.getJsonTypeName())},t.prototype.raiseExecuteActionEvent=function(){var e,t,r;this.onExecute&&this.onExecute(this),t=(e=this).parent?e.parent.getRootElement():void 0,r=t&&t.onExecuteAction?t.onExecuteAction:sc.onExecuteAction,e.prepareForExecution()&&r&&r(e)},t.prototype.internalAfterExecute=function(){var e=this.getRootObject();e instanceof Rs&&e.updateActionsEnabledState()},t.prototype.getHref=function(){return""},t.prototype.getAriaRole=function(){var e=this.getAriaRoleFromEnum();return null!=e?e:"button"},t.prototype.getAriaRoleFromEnum=function(){switch(this.role){case As.ActionRole.Button:return"button";case As.ActionRole.Link:return"link";case As.ActionRole.Menu:return"menu";case As.ActionRole.MenuItem:return"menuitem";case As.ActionRole.Tab:return"tab";default:return}},t.prototype.setupElementForAccessibility=function(e,t){void 0===t&&(t=!1),e.tabIndex=this.isEffectivelyEnabled()&&!this.isDesignMode()?0:-1,e.setAttribute("role",this.getAriaRole()),e instanceof HTMLButtonElement&&(e.disabled=!this.isEffectivelyEnabled()),this.isEffectivelyEnabled()?(e.removeAttribute("aria-disabled"),e.classList.add(this.hostConfig.makeCssClassName("ac-selectable"))):e.setAttribute("aria-disabled","true"),this.title?(e.setAttribute("aria-label",this.title),e.title=this.title):(e.removeAttribute("aria-label"),e.removeAttribute("title")),this.tooltip&&(t&&!this.title&&e.setAttribute("aria-label",this.tooltip),e.title=this.tooltip)},t.prototype.parse=function(t,r){return e.prototype.parse.call(this,t,r||new cc)},t.prototype.render=function(){var e=this,t=document.createElement("button");t.type="button",t.style.display="flex",t.style.alignItems="center",t.style.justifyContent="center",t.onclick=function(t){e.isEffectivelyEnabled()&&(t.preventDefault(),t.cancelBubble=!0,e.execute())},this._renderedElement=t,this.renderButtonContent(),this.updateCssClasses(),this.setupElementForAccessibility(t)},t.prototype.execute=function(){this._actionCollection&&this._actionCollection.actionExecuted(this),this.raiseExecuteActionEvent(),this.internalAfterExecute()},t.prototype.prepareForExecution=function(){var e=this.getReferencedInputs(),t=this.internalValidateInputs(e);return t.length>0?(t[0].focus(),!1):(this.internalPrepareForExecution(e),!0)},t.prototype.remove=function(){return!!this._actionCollection&&this._actionCollection.removeAction(this)},t.prototype.getAllInputs=function(e){return[]},t.prototype.getAllActions=function(){return[this]},t.prototype.getResourceInformation=function(){return this.iconUrl?[{url:this.iconUrl,mimeType:"image"}]:[]},t.prototype.getActionById=function(e){return this.id===e?this:void 0},t.prototype.getReferencedInputs=function(){return this.internalGetReferencedInputs()},t.prototype.validateInputs=function(){return this.internalValidateInputs(this.getReferencedInputs())},t.prototype.updateEnabledState=function(){},t.prototype.isEffectivelyEnabled=function(){return this.isEnabled},Object.defineProperty(t.prototype,"isPrimary",{get:function(){return this.style===As.ActionStyle.Positive},set:function(e){e?this.style=As.ActionStyle.Positive:this.style===As.ActionStyle.Positive&&(this.style=As.ActionStyle.Default)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"hostConfig",{get:function(){return this.parent?this.parent.hostConfig:Ms.defaultHostConfig},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"parent",{get:function(){return this._parent},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"state",{get:function(){return this._state},set:function(e){this._state!==e&&(this._state=e,this.updateCssClasses())},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"isFocusable",{get:function(){return this._isFocusable},set:function(e){this._isFocusable!==e&&(this._isFocusable=e,this.updateCssClasses())},enumerable:!1,configurable:!0}),t.titleProperty=new Ls.StringProperty(Ls.Versions.v1_0,"title"),t.iconUrlProperty=new Ls.StringProperty(Ls.Versions.v1_1,"iconUrl"),t.styleProperty=new Ls.ValueSetProperty(Ls.Versions.v1_2,"style",[{value:As.ActionStyle.Default},{value:As.ActionStyle.Positive},{value:As.ActionStyle.Destructive}],As.ActionStyle.Default),t.modeProperty=new Ls.ValueSetProperty(Ls.Versions.v1_5,"mode",[{value:As.ActionMode.Primary},{value:As.ActionMode.Secondary}],As.ActionMode.Primary),t.tooltipProperty=new Ls.StringProperty(Ls.Versions.v1_5,"tooltip"),t.isEnabledProperty=new Ls.BoolProperty(Ls.Versions.v1_5,"isEnabled",!0),t.roleProperty=new Ls.EnumProperty(Ls.Versions.v1_6,"role",As.ActionRole),Ss([(0,Ls.property)(t.titleProperty)],t.prototype,"title",void 0),Ss([(0,Ls.property)(t.iconUrlProperty)],t.prototype,"iconUrl",void 0),Ss([(0,Ls.property)(t.styleProperty)],t.prototype,"style",void 0),Ss([(0,Ls.property)(t.modeProperty)],t.prototype,"mode",void 0),Ss([(0,Ls.property)(t.tooltipProperty)],t.prototype,"tooltip",void 0),Ss([(0,Ls.property)(t.isEnabledProperty)],t.prototype,"isEnabled",void 0),Ss([(0,Ls.property)(t.roleProperty)],t.prototype,"role",void 0),t}(Bs.CardObject);yo.Action=kl;var Sl=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.disabledUnlessAssociatedInputsChange=!1,t._isPrepared=!1,t._areReferencedInputsDirty=!1,t}return ks(t,e),t.prototype.internalGetReferencedInputs=function(){var e={};if("none"!==this.associatedInputs){for(var t=this.parent,r=[];t;)r.push.apply(r,t.getAllInputs(!1)),t=t.parent;for(var n=0,i=r;n<i.length;n++){var o=i[n];o.id&&(e[o.id]=o)}}return e},t.prototype.internalPrepareForExecution=function(e){if(this._originalData?this._processedData=JSON.parse(JSON.stringify(this._originalData)):this._processedData={},this._processedData&&e)for(var t=0,r=Object.keys(e);t<r.length;t++){var n=e[r[t]];n.id&&n.isSet()&&(this._processedData[n.id]="string"==typeof n.value?n.value:n.value.toString())}this._isPrepared=!0},t.prototype.internalAfterExecute=function(){Ps.GlobalSettings.resetInputsDirtyStateAfterActionExecution&&this.resetReferencedInputsDirtyState()},t.prototype.resetReferencedInputsDirtyState=function(){var e=this.getReferencedInputs();if(this._areReferencedInputsDirty=!1,e)for(var t=0,r=Object.keys(e);t<r.length;t++){e[r[t]].resetDirtyState()}},t.prototype.updateEnabledState=function(){this._areReferencedInputsDirty=!1;var e=this.getReferencedInputs();if(e)for(var t=0,r=Object.keys(e);t<r.length;t++){if(e[r[t]].isDirty()){this._areReferencedInputsDirty=!0;break}}this.updateCssClasses(),this._renderedElement&&this.setupElementForAccessibility(this._renderedElement)},t.prototype.isEffectivelyEnabled=function(){var t=e.prototype.isEffectivelyEnabled.call(this);return this.disabledUnlessAssociatedInputsChange?t&&this._areReferencedInputsDirty:t},Object.defineProperty(t.prototype,"data",{get:function(){return this._isPrepared?this._processedData:this._originalData},set:function(e){this._originalData=e,this._isPrepared=!1},enumerable:!1,configurable:!0}),t.dataProperty=new Ls.PropertyDefinition(Ls.Versions.v1_0,"data"),t.associatedInputsProperty=new Ls.CustomProperty(Ls.Versions.v1_3,"associatedInputs",function(e,t,r,n){var i=r[t.name];if(void 0!==i&&"string"==typeof i)return"none"===i.toLowerCase()?"none":"auto"},function(e,t,r,n,i){i.serializeValue(r,t.name,n)}),t.disabledUnlessAssociatedInputsChangeProperty=new Ls.BoolProperty(Ls.Versions.v1_6,"disabledUnlessAssociatedInputsChange",!1),Ss([(0,Ls.property)(t.dataProperty)],t.prototype,"_originalData",void 0),Ss([(0,Ls.property)(t.associatedInputsProperty)],t.prototype,"associatedInputs",void 0),Ss([(0,Ls.property)(t.disabledUnlessAssociatedInputsChangeProperty)],t.prototype,"disabledUnlessAssociatedInputsChange",void 0),t}(kl);yo.SubmitActionBase=Sl;var _l=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return ks(t,e),t.prototype.getJsonTypeName=function(){return t.JsonTypeName},t.JsonTypeName="Action.Submit",t}(Sl),Tl=yo.SubmitAction=_l,Al=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return ks(t,e),t}(Sl);yo.UniversalAction=Al;var Pl=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return ks(t,e),t.prototype.getJsonTypeName=function(){return t.JsonTypeName},t.JsonTypeName="Action.Execute",t.verbProperty=new Ls.StringProperty(Ls.Versions.v1_4,"verb"),Ss([(0,Ls.property)(t.verbProperty)],t.prototype,"verb",void 0),t}(Al),El=yo.ExecuteAction=Pl,Ml=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return ks(t,e),t.prototype.getJsonTypeName=function(){return t.JsonTypeName},Object.defineProperty(t.prototype,"isStandalone",{get:function(){return!1},enumerable:!1,configurable:!0}),t.JsonTypeName="Data.Query",t.datasetProperty=new Ls.StringProperty(Ls.Versions.v1_6,"dataset"),t.filterProperty=new Ls.StringProperty(Ls.Versions.v1_6,"filter"),t.countProperty=new Ls.NumProperty(Ls.Versions.v1_6,"count"),t.skipProperty=new Ls.NumProperty(Ls.Versions.v1_6,"skip"),Ss([(0,Ls.property)(t.datasetProperty)],t.prototype,"dataset",void 0),Ss([(0,Ls.property)(t.filterProperty)],t.prototype,"filter",void 0),Ss([(0,Ls.property)(t.countProperty)],t.prototype,"count",void 0),Ss([(0,Ls.property)(t.skipProperty)],t.prototype,"skip",void 0),t}(Al);yo.DataQuery=Ml;var Il=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return ks(t,e),t.prototype.getJsonTypeName=function(){return t.JsonTypeName},t.prototype.getAriaRole=function(){var e=this.getAriaRoleFromEnum();return null!=e?e:"link"},t.prototype.internalValidateProperties=function(t){e.prototype.internalValidateProperties.call(this,t),this.url||t.addFailure(this,As.ValidationEvent.PropertyCantBeNull,Ns.Strings.errors.propertyMustBeSet("url"))},t.prototype.getHref=function(){return this.url},t.urlProperty=new Ls.StringProperty(Ls.Versions.v1_0,"url"),t.JsonTypeName="Action.OpenUrl",Ss([(0,Ls.property)(t.urlProperty)],t.prototype,"url",void 0),t}(kl),Bl=yo.OpenUrlAction=Il,Ll=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.targetElements={},t}return ks(t,e),t.prototype.updateAriaControlsAttribute=function(){if(this.targetElements){var e=Object.keys(this.targetElements);this._renderedElement&&(e.length>0?this._renderedElement.setAttribute("aria-controls",e.join(" ")):this._renderedElement.removeAttribute("aria-controls"))}},t.prototype.internalValidateProperties=function(t){e.prototype.internalValidateProperties.call(this,t),this.targetElements||t.addFailure(this,As.ValidationEvent.PropertyCantBeNull,Ns.Strings.errors.propertyMustBeSet("targetElements"))},t.prototype.getJsonTypeName=function(){return t.JsonTypeName},t.prototype.render=function(){e.prototype.render.call(this),this.updateAriaControlsAttribute()},t.prototype.execute=function(){if(e.prototype.execute.call(this),this.parent)for(var t=0,r=Object.keys(this.targetElements);t<r.length;t++){var n=r[t],i=this.parent.getRootElement().getElementById(n);i&&("boolean"==typeof this.targetElements[n]?i.isVisible=this.targetElements[n]:i.isVisible=!i.isVisible)}},t.prototype.addTargetElement=function(e,t){void 0===t&&(t=void 0),this.targetElements[e]=t,this.updateAriaControlsAttribute()},t.prototype.removeTargetElement=function(e){delete this.targetElements[e],this.updateAriaControlsAttribute()},t.targetElementsProperty=new Ls.CustomProperty(Ls.Versions.v1_2,"targetElements",function(e,t,r,n){var i={};if(Array.isArray(r[t.name]))for(var o=0,a=r[t.name];o<a.length;o++){var s=a[o];if("string"==typeof s)i[s]=void 0;else if("object"==typeof s){var l=s.elementId;"string"==typeof l&&(i[l]=Es.parseBool(s.isVisible))}}return i},function(e,t,r,n,i){for(var o=[],a=0,s=Object.keys(n);a<s.length;a++){var l=s[a];"boolean"==typeof n[l]?o.push({elementId:l,isVisible:n[l]}):o.push(l)}i.serializeArray(r,t.name,o)},{},function(e){return{}}),t.JsonTypeName="Action.ToggleVisibility",Ss([(0,Ls.property)(t.targetElementsProperty)],t.prototype,"targetElements",void 0),t}(kl),jl=yo.ToggleVisibilityAction=Ll,Nl=function(e){function t(t,r){var n=e.call(this,t,r,void 0,function(){return new Ps.StringWithSubstitutions})||this;return n.targetVersion=t,n.name=r,n}return ks(t,e),t.prototype.parse=function(e,t,r){var n=new Ps.StringWithSubstitutions;return n.set(Es.parseString(t[this.name])),n},t.prototype.toJSON=function(e,t,r,n){n.serializeValue(t,this.name,r.getOriginal())},t}(Ls.PropertyDefinition),Dl=function(e){function t(t,r){void 0===t&&(t=""),void 0===r&&(r="");var n=e.call(this)||this;return n.name=t,n.value=r,n}return ks(t,e),t.prototype.getSchemaKey=function(){return"HttpHeader"},t.prototype.getReferencedInputs=function(e,t){this._value.getReferencedInputs(e,t)},t.prototype.prepareForExecution=function(e){this._value.substituteInputValues(e,Ps.ContentTypes.applicationXWwwFormUrlencoded)},Object.defineProperty(t.prototype,"value",{get:function(){return this._value.get()},set:function(e){this._value.set(e)},enumerable:!1,configurable:!0}),t.nameProperty=new Ls.StringProperty(Ls.Versions.v1_0,"name"),t.valueProperty=new Nl(Ls.Versions.v1_0,"value"),Ss([(0,Ls.property)(t.nameProperty)],t.prototype,"name",void 0),Ss([(0,Ls.property)(t.valueProperty)],t.prototype,"_value",void 0),t}(Ls.SerializableObject);yo.HttpHeader=Dl;var Ol=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t._ignoreInputValidation=!1,t}return ks(t,e),t.prototype.internalGetReferencedInputs=function(){var e=this.parent?this.parent.getRootElement().getAllInputs():[],t={};this._url.getReferencedInputs(e,t);for(var r=0,n=this.headers;r<n.length;r++){n[r].getReferencedInputs(e,t)}return this._body.getReferencedInputs(e,t),t},t.prototype.internalPrepareForExecution=function(e){if(e){this._url.substituteInputValues(e,Ps.ContentTypes.applicationXWwwFormUrlencoded);for(var t=Ps.ContentTypes.applicationJson,r=0,n=this.headers;r<n.length;r++){var i=n[r];i.prepareForExecution(e),i.name&&"content-type"===i.name.toLowerCase()&&(t=i.value)}this._body.substituteInputValues(e,t)}},t.prototype.getJsonTypeName=function(){return t.JsonTypeName},t.prototype.internalValidateProperties=function(t){if(e.prototype.internalValidateProperties.call(this,t),this.url||t.addFailure(this,As.ValidationEvent.PropertyCantBeNull,Ns.Strings.errors.propertyMustBeSet("url")),this.headers.length>0)for(var r=0,n=this.headers;r<n.length;r++){n[r].name||t.addFailure(this,As.ValidationEvent.PropertyCantBeNull,Ns.Strings.errors.actionHttpHeadersMustHaveNameAndValue())}},Object.defineProperty(t.prototype,"ignoreInputValidation",{get:function(){return this._ignoreInputValidation},set:function(e){this._ignoreInputValidation=e},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"url",{get:function(){return this._url.get()},set:function(e){this._url.set(e)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"body",{get:function(){return this._body.get()},set:function(e){this._body.set(e)},enumerable:!1,configurable:!0}),t.urlProperty=new Nl(Ls.Versions.v1_0,"url"),t.bodyProperty=new Nl(Ls.Versions.v1_0,"body"),t.methodProperty=new Ls.StringProperty(Ls.Versions.v1_0,"method"),t.headersProperty=new Ls.SerializableObjectCollectionProperty(Ls.Versions.v1_0,"headers",Dl),t.ignoreInputValidationProperty=new Ls.BoolProperty(Ls.Versions.v1_3,"ignoreInputValidation",!1),t.JsonTypeName="Action.Http",Ss([(0,Ls.property)(t.urlProperty)],t.prototype,"_url",void 0),Ss([(0,Ls.property)(t.bodyProperty)],t.prototype,"_body",void 0),Ss([(0,Ls.property)(t.methodProperty)],t.prototype,"method",void 0),Ss([(0,Ls.property)(t.headersProperty)],t.prototype,"headers",void 0),Ss([(0,Ls.property)(t.ignoreInputValidationProperty)],t.prototype,"_ignoreInputValidation",void 0),t}(kl);yo.HttpAction=Ol;var Fl=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.card=new lc,t}return ks(t,e),t.prototype.updateCssClasses=function(){if(e.prototype.updateCssClasses.call(this),this.renderedElement){var t=this.parent?this.parent.hostConfig:Ms.defaultHostConfig;this.renderedElement.classList.add(t.makeCssClassName("expandable")),this.renderedElement.setAttribute("aria-expanded",(1===this.state).toString())}},t.prototype.internalParse=function(t,r){e.prototype.internalParse.call(this,t,r);var n=t.card;n?this.card.parse(n,r):r.logParseEvent(this,As.ValidationEvent.PropertyCantBeNull,Ns.Strings.errors.showCardMustHaveCard())},t.prototype.internalToJSON=function(t,r){e.prototype.internalToJSON.call(this,t,r),this.card&&r.serializeValue(t,"card",this.card.toJSON(r))},t.prototype.raiseExecuteActionEvent=function(){this.hostConfig.actions.showCard.actionMode===As.ShowCardActionMode.Popup&&e.prototype.raiseExecuteActionEvent.call(this)},t.prototype.releaseDOMResources=function(){e.prototype.releaseDOMResources.call(this),this.card.releaseDOMResources()},t.prototype.getJsonTypeName=function(){return t.JsonTypeName},t.prototype.internalValidateProperties=function(t){e.prototype.internalValidateProperties.call(this,t),this.card.internalValidateProperties(t)},t.prototype.setParent=function(t){e.prototype.setParent.call(this,t),this.card.setParent(t)},t.prototype.getAllInputs=function(e){return void 0===e&&(e=!0),this.card.getAllInputs(e)},t.prototype.getAllActions=function(){var t=e.prototype.getAllActions.call(this);return t.push.apply(t,this.card.getAllActions()),t},t.prototype.getResourceInformation=function(){var t=e.prototype.getResourceInformation.call(this);return t.push.apply(t,this.card.getResourceInformation()),t},t.prototype.getActionById=function(t){var r=e.prototype.getActionById.call(this,t);return r||(r=this.card.getActionById(t)),r},t.JsonTypeName="Action.ShowCard",t}(kl),Rl=yo.ShowCardAction=Fl,$l=function(e){function t(t){var r=e.call(this)||this;return r._actions=t,r.title=Ns.Strings.defaults.overflowButtonText(),r.tooltip=Ns.Strings.defaults.overflowButtonTooltip(),r}return ks(t,e),t.prototype.getActions=function(){return this._actions},t.prototype.getAllActions=function(){var t=e.prototype.getAllActions.call(this);return t.push.apply(t,this._actions),t},t.prototype.getJsonTypeName=function(){return Fl.JsonTypeName},t.prototype.execute=function(){var e,t,r,n,i,o=this;if((t=this,r=this.renderedElement,n=t.parent?t.parent.getRootElement():void 0,!(void 0!==(i=n&&n.onDisplayOverflowActionMenu?n.onDisplayOverflowActionMenu:sc.onDisplayOverflowActionMenu)&&i(t.getActions(),r)))&&this.renderedElement){var a=new Ds.PopupMenu;a.hostConfig=this.hostConfig;for(var s=function(t){var r=new Ds.MenuItem(t.toString(),null!==(e=l._actions[t].title)&&void 0!==e?e:"");r.isEnabled=l._actions[t].isEnabled,r.onClick=function(){var e=o._actions[t];a.closePopup(!1),e.isEnabled&&e.execute()},a.items.add(r)},l=this,c=0;c<this._actions.length;c++)s(c);a.onClose=function(){var e;null===(e=o.renderedElement)||void 0===e||e.setAttribute("aria-expanded","false")},this.renderedElement.setAttribute("aria-expanded","true"),a.popup(this.renderedElement)}},t.prototype.setupElementForAccessibility=function(t,r){void 0===r&&(r=!1),e.prototype.setupElementForAccessibility.call(this,t,r),t.setAttribute("aria-label",Ns.Strings.defaults.overflowButtonTooltip()),t.setAttribute("aria-expanded","false")},t.JsonTypeName="Action.Overflow",t}(kl),zl=function(){function e(e){this._items=[],this._renderedActions=[],this._owner=e}return e.prototype.isActionAllowed=function(e){var t=this._owner.getForbiddenActionTypes();if(t)for(var r=0,n=t;r<n.length;r++){var i=n[r];if(e.constructor===i)return!1}return!0},e.prototype.refreshContainer=function(){if(Os(this._actionCardContainer),this._actionCard){this._actionCardContainer.style.marginTop=this.renderedActionCount>0?this._owner.hostConfig.actions.showCard.inlineTopMargin+"px":"0px";var e=this._owner.getEffectivePadding();this._owner.getImmediateSurroundingPadding(e);var t=this._owner.hostConfig.paddingDefinitionToSpacingDefinition(e);this._actionCard&&(this._actionCard.style.paddingLeft=t.left+"px",this._actionCard.style.paddingRight=t.right+"px",this._actionCard.style.marginLeft="-"+t.left+"px",this._actionCard.style.marginRight="-"+t.right+"px",0===t.bottom||this._owner.isDesignMode()||(this._actionCard.style.paddingBottom=t.bottom+"px",this._actionCard.style.marginBottom="-"+t.bottom+"px"),Es.appendChild(this._actionCardContainer,this._actionCard))}else this._actionCardContainer.style.marginTop="0px"},e.prototype.layoutChanged=function(){this._owner.getRootElement().updateLayout()},e.prototype.showActionCard=function(e,t,r){void 0===t&&(t=!1),void 0===r&&(r=!0),e.card.suppressStyle=t;var n=e.card.renderedElement&&!this._owner.isDesignMode()?e.card.renderedElement:e.card.render();this._actionCard=n,this._expandedAction=e,this.refreshContainer(),r&&(this.layoutChanged(),Kl(e,!0))},e.prototype.collapseExpandedAction=function(){for(var e=0,t=this._renderedActions;e<t.length;e++){t[e].state=0}var r=this._expandedAction;this._expandedAction=void 0,this._actionCard=void 0,this.refreshContainer(),r&&(this.layoutChanged(),Kl(r,!1))},e.prototype.expandShowCardAction=function(e,t){for(var r=this,n=!1,i=0,o=this._renderedActions;i<o.length;i++){var a=o[i];this._owner.hostConfig.actions.actionsOrientation==As.Orientation.Horizontal&&n&&(a.isFocusable=!1),a!==e?a.state=2:(a.state=1,n=!0,a.renderedElement&&(a.renderedElement.onblur=function(e){for(var t=0,n=r._renderedActions;t<n.length;t++){n[t].isFocusable=!0}}))}this.showActionCard(e,!(this._owner.isAtTheVeryLeft()&&this._owner.isAtTheVeryRight()),t)},e.prototype.releaseDOMResources=function(){for(var e=0,t=this._renderedActions;e<t.length;e++){t[e].releaseDOMResources()}},e.prototype.actionExecuted=function(e){e instanceof Fl?e===this._expandedAction?this.collapseExpandedAction():this._owner.hostConfig.actions.showCard.actionMode===As.ShowCardActionMode.Inline&&this.expandShowCardAction(e,!0):this.collapseExpandedAction()},e.prototype.parse=function(e,t){if(this.clear(),Array.isArray(e))for(var r=0,n=e;r<n.length;r++){var i=n[r],o=[];this._owner instanceof tc&&(o=this._owner.getForbiddenActionNames());var a=t.parseAction(this._owner,i,o,!this._owner.isDesignMode());a&&this.addAction(a)}},e.prototype.toJSON=function(e,t,r){r.serializeArray(e,t,this._items)},e.prototype.getActionAt=function(e){return this._items[e]},e.prototype.getActionCount=function(){return this._items.length},e.prototype.getActionById=function(e){for(var t=void 0,r=0,n=this._items;r<n.length;r++){if(t=n[r].getActionById(e))break}return t},e.prototype.validateProperties=function(e){this._owner.hostConfig.actions.maxActions&&this._items.length>this._owner.hostConfig.actions.maxActions&&e.addFailure(this._owner,As.ValidationEvent.TooManyActions,Ns.Strings.errors.tooManyActions(this._owner.hostConfig.actions.maxActions)),this._items.length>0&&!this._owner.hostConfig.supportsInteractivity&&e.addFailure(this._owner,As.ValidationEvent.InteractivityNotAllowed,Ns.Strings.errors.interactivityNotAllowed());for(var t=0,r=this._items;t<r.length;t++){var n=r[t];this.isActionAllowed(n)||e.addFailure(this._owner,As.ValidationEvent.ActionTypeNotAllowed,Ns.Strings.errors.actionTypeNotAllowed(n.getJsonTypeName())),n.internalValidateProperties(e)}},e.prototype.render=function(e){var t=this._owner.hostConfig;if(t.supportsInteractivity){var r=document.createElement("div"),n=t.actions.maxActions?Math.min(t.actions.maxActions,this._items.length):this._items.length;if(this._actionCardContainer=document.createElement("div"),this._renderedActions=[],t.actions.preExpandSingleShowCardAction&&1===n&&this._items[0]instanceof Fl&&this.isActionAllowed(this._items[0]))this.showActionCard(this._items[0],!0),this._renderedActions.push(this._items[0]);else{var i=document.createElement("div");if(i.className=t.makeCssClassName("ac-actionSet"),i.style.display="flex",e===As.Orientation.Horizontal)if(i.style.flexDirection="row",this._owner.horizontalAlignment&&t.actions.actionAlignment!==As.ActionAlignment.Stretch)switch(this._owner.horizontalAlignment){case As.HorizontalAlignment.Center:i.style.justifyContent="center";break;case As.HorizontalAlignment.Right:i.style.justifyContent="flex-end";break;default:i.style.justifyContent="flex-start"}else switch(t.actions.actionAlignment){case As.ActionAlignment.Center:i.style.justifyContent="center";break;case As.ActionAlignment.Right:i.style.justifyContent="flex-end";break;default:i.style.justifyContent="flex-start"}else if(i.style.flexDirection="column",this._owner.horizontalAlignment&&t.actions.actionAlignment!==As.ActionAlignment.Stretch)switch(this._owner.horizontalAlignment){case As.HorizontalAlignment.Center:i.style.alignItems="center";break;case As.HorizontalAlignment.Right:i.style.alignItems="flex-end";break;default:i.style.alignItems="flex-start"}else switch(t.actions.actionAlignment){case As.ActionAlignment.Center:i.style.alignItems="center";break;case As.ActionAlignment.Right:i.style.alignItems="flex-end";break;case As.ActionAlignment.Stretch:i.style.alignItems="stretch";break;default:i.style.alignItems="flex-start"}var o=this._items.filter(this.isActionAllowed.bind(this)),a=[],s=[];if(this._owner.isDesignMode())a=o;else{o.forEach(function(e){return e.mode===As.ActionMode.Secondary?s.push(e):a.push(e)});var l=a.splice(t.actions.maxActions);Ps.GlobalSettings.allowMoreThanMaxActionsInOverflowMenu&&s.push.apply(s,l);var c=!0;if(s.length>0){this._overflowAction||(this._overflowAction=new $l(s),this._overflowAction.setParent(this._owner),this._overflowAction._actionCollection=this);var u=this._owner instanceof sc&&!this._owner.parent;c=!function(e,t){var r=e.parent?e.parent.getRootElement():void 0,n=r&&r.onRenderOverflowActions?r.onRenderOverflowActions:sc.onRenderOverflowActions;return void 0!==n&&n(e.getActions(),t)}(this._overflowAction,u)}this._overflowAction&&c&&a.push(this._overflowAction)}for(var h=0;h<a.length;h++){var d=a[h];if(d.render(),d.renderedElement&&(t.actions.actionsOrientation===As.Orientation.Horizontal&&t.actions.actionAlignment===As.ActionAlignment.Stretch?d.renderedElement.style.flex="0 1 100%":d.renderedElement.style.flex="0 1 auto",i.appendChild(d.renderedElement),this._renderedActions.push(d),h<a.length-1&&t.actions.buttonSpacing>0)){var p=document.createElement("div");e===As.Orientation.Horizontal?(p.style.flex="0 0 auto",p.style.width=t.actions.buttonSpacing+"px"):p.style.height=t.actions.buttonSpacing+"px",Es.appendChild(i,p)}}var f=document.createElement("div");f.style.overflow="hidden",f.appendChild(i),Es.appendChild(r,f)}Es.appendChild(r,this._actionCardContainer);for(var g=0,m=this._renderedActions;g<m.length;g++){var y=m[g];if(1===y.state){this.expandShowCardAction(y,!1);break}}return this._renderedActions.length>0?r:void 0}},e.prototype.addAction=function(e){if(!e)throw new Error("The action parameter cannot be null.");if(e.parent&&e.parent!==this._owner||!(this._items.indexOf(e)<0))throw new Error(Ns.Strings.errors.actionAlreadyParented());this._items.push(e),e.parent||e.setParent(this._owner),e._actionCollection=this},e.prototype.removeAction=function(e){this.expandedAction&&this._expandedAction===e&&this.collapseExpandedAction();var t=this._items.indexOf(e);if(t>=0){this._items.splice(t,1),e.setParent(void 0),e._actionCollection=void 0;for(var r=0;r<this._renderedActions.length;r++)if(this._renderedActions[r]===e){this._renderedActions.splice(r,1);break}return!0}return!1},e.prototype.clear=function(){this._items=[],this._renderedActions=[],this._expandedAction=void 0},e.prototype.getAllInputs=function(e){void 0===e&&(e=!0);var t=[];if(e)for(var r=0,n=this._items;r<n.length;r++){var i=n[r];t.push.apply(t,i.getAllInputs())}return t},e.prototype.getResourceInformation=function(){for(var e=[],t=0,r=this._items;t<r.length;t++){var n=r[t];e.push.apply(e,n.getResourceInformation())}return e},Object.defineProperty(e.prototype,"renderedActionCount",{get:function(){return this._renderedActions.length},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"expandedAction",{get:function(){return this._expandedAction},enumerable:!1,configurable:!0}),e}(),Vl=function(e){function t(){var t=e.call(this)||this;return t._actionCollection=new zl(t),t}return ks(t,e),t.prototype.internalParse=function(t,r){e.prototype.internalParse.call(this,t,r),this._actionCollection.parse(t.actions,r)},t.prototype.internalToJSON=function(t,r){e.prototype.internalToJSON.call(this,t,r),this._actionCollection.toJSON(t,"actions",r)},t.prototype.internalRender=function(){return this._actionCollection.render(void 0!==this.orientation?this.orientation:this.hostConfig.actions.actionsOrientation)},t.prototype.releaseDOMResources=function(){e.prototype.releaseDOMResources.call(this),this._actionCollection.releaseDOMResources()},t.prototype.isBleedingAtBottom=function(){return 0===this._actionCollection.renderedActionCount?e.prototype.isBleedingAtBottom.call(this):1===this._actionCollection.getActionCount()?void 0!==this._actionCollection.expandedAction&&!this.hostConfig.actions.preExpandSingleShowCardAction:void 0!==this._actionCollection.expandedAction},t.prototype.getJsonTypeName=function(){return"ActionSet"},t.prototype.getActionCount=function(){return this._actionCollection.getActionCount()},t.prototype.getActionAt=function(t){return t>=0&&t<this.getActionCount()?this._actionCollection.getActionAt(t):e.prototype.getActionAt.call(this,t)},t.prototype.getActionById=function(t){var r=this._actionCollection.getActionById(t);return r||e.prototype.getActionById.call(this,t)},t.prototype.getAllActions=function(){for(var t=e.prototype.getAllActions.call(this),r=0;r<this.getActionCount();r++){var n=this.getActionAt(r);n&&t.push(n)}return t},t.prototype.internalValidateProperties=function(t){e.prototype.internalValidateProperties.call(this,t),this._actionCollection.validateProperties(t)},t.prototype.addAction=function(e){this._actionCollection.addAction(e)},t.prototype.getAllInputs=function(e){return void 0===e&&(e=!0),e?this._actionCollection.getAllInputs():[]},t.prototype.getResourceInformation=function(){return this._actionCollection.getResourceInformation()},t.prototype.findDOMNodeOwner=function(t){for(var r=void 0,n=0;n<this.getActionCount();n++){var i=this.getActionAt(n);if(i&&(r=i.findDOMNodeOwner(t)))return r}return e.prototype.findDOMNodeOwner.call(this,t)},t.prototype.getElementById=function(t){var r=e.prototype.getElementById.call(this,t);return r||(r=this.getElementByIdFromAction(t)),r},Object.defineProperty(t.prototype,"isInteractive",{get:function(){return!0},enumerable:!1,configurable:!0}),t.orientationProperty=new Ls.EnumProperty(Ls.Versions.v1_1,"orientation",As.Orientation),Ss([(0,Ls.property)(t.orientationProperty)],t.prototype,"orientation",void 0),t}(Rs);yo.ActionSet=Vl;var Wl=function(e){function t(t,r,n,i){var o=e.call(this,t,r,[{value:As.ContainerStyle.Default},{value:As.ContainerStyle.Emphasis},{targetVersion:Ls.Versions.v1_2,value:As.ContainerStyle.Accent},{targetVersion:Ls.Versions.v1_2,value:As.ContainerStyle.Good},{targetVersion:Ls.Versions.v1_2,value:As.ContainerStyle.Attention},{targetVersion:Ls.Versions.v1_2,value:As.ContainerStyle.Warning}],n,i)||this;return o.targetVersion=t,o.name=r,o.defaultValue=n,o.onGetInitialValue=i,o}return ks(t,e),t}(Ls.ValueSetProperty);yo.ContainerStyleProperty=Wl;var Hl=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return ks(t,e),Object.defineProperty(t.prototype,"style",{get:function(){if(this.allowCustomStyle){var e=this.getValue(t.styleProperty);if(e&&this.hostConfig.containerStyles.getStyleByName(e))return e}},set:function(e){this.setValue(t.styleProperty,e)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"allowCustomStyle",{get:function(){return!0},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"hasExplicitStyle",{get:function(){return void 0!==this.getValue(t.styleProperty)},enumerable:!1,configurable:!0}),t.prototype.applyBorder=function(){},t.prototype.applyBackground=function(){if(this.renderedElement){var e=this.hostConfig.containerStyles.getStyleByName(this.style,this.hostConfig.containerStyles.getStyleByName(this.defaultStyle));if(e.backgroundColor){var t=Es.stringToCssColor(e.backgroundColor);t&&(this.renderedElement.style.backgroundColor=t)}}},t.prototype.applyPadding=function(){if(e.prototype.applyPadding.call(this),this.renderedElement){var t=new Ps.SpacingDefinition;if(this.getEffectivePadding()&&(t=this.hostConfig.paddingDefinitionToSpacingDefinition(this.getEffectivePadding())),this.renderedElement.style.paddingTop=t.top+"px",this.renderedElement.style.paddingRight=t.right+"px",this.renderedElement.style.paddingBottom=t.bottom+"px",this.renderedElement.style.paddingLeft=t.left+"px",this.isBleeding()){var r=new Ps.PaddingDefinition;this.getImmediateSurroundingPadding(r);var n=this.hostConfig.paddingDefinitionToSpacingDefinition(r);this.renderedElement.style.marginRight="-"+n.right+"px",this.renderedElement.style.marginLeft="-"+n.left+"px",this.isDesignMode()||(this.renderedElement.style.marginTop="-"+n.top+"px",this.renderedElement.style.marginBottom="-"+n.bottom+"px"),this.separatorElement&&this.separatorOrientation===As.Orientation.Horizontal&&(this.separatorElement.style.marginLeft="-"+n.left+"px",this.separatorElement.style.marginRight="-"+n.right+"px")}else this.renderedElement.style.marginRight="0",this.renderedElement.style.marginLeft="0",this.renderedElement.style.marginTop="0",this.renderedElement.style.marginBottom="0",this.separatorElement&&this.separatorOrientation===As.Orientation.Horizontal&&(this.separatorElement.style.marginRight="0",this.separatorElement.style.marginLeft="0")}},t.prototype.getHasBackground=function(e){void 0===e&&(e=!1);for(var r=this.parent;r;){var n=!1;if(n=!e&&(r instanceof Gl&&r.backgroundImage.isValid()),r instanceof t&&this.hasExplicitStyle&&(r.getEffectiveStyle()!==this.getEffectiveStyle()||n))return!0;r=r.parent}return!1},t.prototype.getDefaultPadding=function(){return this.getHasBackground()||this.getHasBorder()?new Ps.PaddingDefinition(As.Spacing.Padding,As.Spacing.Padding,As.Spacing.Padding,As.Spacing.Padding):e.prototype.getDefaultPadding.call(this)},t.prototype.internalValidateProperties=function(r){e.prototype.internalValidateProperties.call(this,r);var n=this.getValue(t.styleProperty);void 0!==n&&(this.hostConfig.containerStyles.getStyleByName(n)||r.addFailure(this,As.ValidationEvent.InvalidPropertyValue,Ns.Strings.errors.invalidPropertyValue(n,"style")))},t.prototype.render=function(){var t=e.prototype.render.call(this);return t&&this.getHasBackground()&&this.applyBackground(),this.applyBorder(),t},t.prototype.getEffectiveStyle=function(){var t=this.style;return t||e.prototype.getEffectiveStyle.call(this)},t.styleProperty=new Wl(Ls.Versions.v1_0,"style"),Ss([(0,Ls.property)(t.styleProperty)],t.prototype,"style",null),t}(Ys);yo.StylableCardElementContainer=Hl;var ql=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t._bleed=!1,t}return ks(t,e),t.prototype.adjustRenderedElementSize=function(t){e.prototype.adjustRenderedElementSize.call(this,t),this.minPixelHeight&&(t.style.minHeight=this.minPixelHeight+"px")},t.prototype.getHasExpandedAction=function(){return!1},t.prototype.getBleed=function(){return this._bleed},t.prototype.setBleed=function(e){this._bleed=e},Object.defineProperty(t.prototype,"renderedActionCount",{get:function(){return 0},enumerable:!1,configurable:!0}),t.prototype.isBleeding=function(){return(this.getHasBackground()||this.hostConfig.alwaysAllowBleed)&&this.getBleed()},t.bleedProperty=new Ls.BoolProperty(Ls.Versions.v1_2,"bleed",!1),t.minHeightProperty=new Ls.PixelSizeProperty(Ls.Versions.v1_2,"minHeight"),Ss([(0,Ls.property)(t.bleedProperty)],t.prototype,"_bleed",void 0),Ss([(0,Ls.property)(t.minHeightProperty)],t.prototype,"minPixelHeight",void 0),t}(Hl);yo.ContainerBase=ql;var Ul=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return ks(t,e),t.prototype.getSchemaKey=function(){return"BackgroundImage"},t.prototype.internalParse=function(t,r){if("string"!=typeof t)return e.prototype.internalParse.call(this,t,r);this.resetDefaultValues(),this.url=t},t.prototype.apply=function(e){if(this.url&&e.renderedElement){switch(e.renderedElement.style.backgroundImage="url('"+e.preProcessPropertyValue(t.urlProperty,this.url)+"')",this.fillMode){case As.FillMode.Repeat:e.renderedElement.style.backgroundRepeat="repeat";break;case As.FillMode.RepeatHorizontally:e.renderedElement.style.backgroundRepeat="repeat-x";break;case As.FillMode.RepeatVertically:e.renderedElement.style.backgroundRepeat="repeat-y";break;case As.FillMode.Cover:default:e.renderedElement.style.backgroundRepeat="no-repeat",e.renderedElement.style.backgroundSize="cover"}switch(this.horizontalAlignment){case As.HorizontalAlignment.Left:break;case As.HorizontalAlignment.Center:e.renderedElement.style.backgroundPositionX="center";break;case As.HorizontalAlignment.Right:e.renderedElement.style.backgroundPositionX="right"}switch(this.verticalAlignment){case As.VerticalAlignment.Top:break;case As.VerticalAlignment.Center:e.renderedElement.style.backgroundPositionY="center";break;case As.VerticalAlignment.Bottom:e.renderedElement.style.backgroundPositionY="bottom"}}},t.prototype.isValid=function(){return!!this.url},t.urlProperty=new Ls.StringProperty(Ls.Versions.v1_0,"url"),t.fillModeProperty=new Ls.EnumProperty(Ls.Versions.v1_2,"fillMode",As.FillMode,As.FillMode.Cover),t.horizontalAlignmentProperty=new Ls.EnumProperty(Ls.Versions.v1_2,"horizontalAlignment",As.HorizontalAlignment,As.HorizontalAlignment.Left),t.verticalAlignmentProperty=new Ls.EnumProperty(Ls.Versions.v1_2,"verticalAlignment",As.VerticalAlignment,As.VerticalAlignment.Top),Ss([(0,Ls.property)(t.urlProperty)],t.prototype,"url",void 0),Ss([(0,Ls.property)(t.fillModeProperty)],t.prototype,"fillMode",void 0),Ss([(0,Ls.property)(t.horizontalAlignmentProperty)],t.prototype,"horizontalAlignment",void 0),Ss([(0,Ls.property)(t.verticalAlignmentProperty)],t.prototype,"verticalAlignment",void 0),t}(Ls.SerializableObject);yo.BackgroundImage=Ul;var Gl=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t._items=[],t._renderedItems=[],t}return ks(t,e),Object.defineProperty(t.prototype,"backgroundImage",{get:function(){return this.getValue(t.backgroundImageProperty)},enumerable:!1,configurable:!0}),t.prototype.insertItemAt=function(e,t,r){if(e.parent&&!r)throw new Error(Ns.Strings.errors.elementAlreadyParented());if(!e.isStandalone)throw new Error(Ns.Strings.errors.elementTypeNotStandalone(e.getJsonTypeName()));t<0||t>=this._items.length?this._items.push(e):this._items.splice(t,0,e),e.setParent(this)},t.prototype.getItemsCollectionPropertyName=function(){return"items"},t.prototype.applyBackground=function(){this.backgroundImage.isValid()&&this.renderedElement&&this.backgroundImage.apply(this),e.prototype.applyBackground.call(this)},t.prototype.applyRTL=function(e){void 0!==this.rtl&&(e.dir=this.rtl?"rtl":"ltr")},t.prototype.internalRender=function(){this._renderedItems=[];var e=this.hostConfig,t=document.createElement("div");switch(this.applyRTL(t),t.classList.add(e.makeCssClassName("ac-container")),t.style.display="flex",t.style.flexDirection="column",Ps.GlobalSettings.useAdvancedCardBottomTruncation&&(t.style.minHeight="-webkit-min-content"),this.getEffectiveVerticalContentAlignment()){case As.VerticalAlignment.Center:t.style.justifyContent="center";break;case As.VerticalAlignment.Bottom:t.style.justifyContent="flex-end";break;default:t.style.justifyContent="flex-start"}if(this._items.length>0)for(var r=0,n=this._items;r<n.length;r++){var i=n[r],o=this.isElementAllowed(i)?i.render():void 0;o&&(this._renderedItems.length>0&&i.separatorElement&&(i.separatorElement.style.flex="0 0 auto",Es.appendChild(t,i.separatorElement)),Es.appendChild(t,o),this._renderedItems.push(i))}else if(this.isDesignMode()){var a=this.createPlaceholderElement();a.style.width="100%",a.style.height="100%",t.appendChild(a)}return t},t.prototype.truncateOverflow=function(e){if(this.renderedElement){for(var t=this.renderedElement.offsetTop+e+1,r=function(e){var n=e.renderedElement;if(n)switch(Es.getFitStatus(n,t)){case As.ContainerFitStatus.FullyInContainer:e.resetOverflow()&&r(e);break;case As.ContainerFitStatus.Overflowing:var i=t-n.offsetTop;e.handleOverflow(i);break;case As.ContainerFitStatus.FullyOutOfContainer:e.handleOverflow(0)}},n=0,i=this._items;n<i.length;n++){var o=i[n];r(o)}return!0}return!1},t.prototype.undoOverflowTruncation=function(){for(var e=0,t=this._items;e<t.length;e++){t[e].resetOverflow()}},t.prototype.getHasBackground=function(t){return void 0===t&&(t=!1),!t&&this.backgroundImage.isValid()||e.prototype.getHasBackground.call(this,t)},t.prototype.internalParse=function(t,r){e.prototype.internalParse.call(this,t,r),this.clear(),this.setShouldFallback(!1);var n=t[this.getItemsCollectionPropertyName()];if(Array.isArray(n))for(var i=0,o=n;i<o.length;i++){var a=o[i],s=r.parseElement(this,a,this.forbiddenChildElements(),!this.isDesignMode());s&&this.insertItemAt(s,-1,!0)}},t.prototype.internalToJSON=function(t,r){e.prototype.internalToJSON.call(this,t,r);var n=this.getItemsCollectionPropertyName();r.serializeArray(t,n,this._items)},Object.defineProperty(t.prototype,"isSelectable",{get:function(){return!0},enumerable:!1,configurable:!0}),t.prototype.getEffectivePadding=function(){return Ps.GlobalSettings.removePaddingFromContainersWithBackgroundImage&&!this.getHasBackground(!0)?new Ps.PaddingDefinition:e.prototype.getEffectivePadding.call(this)},t.prototype.getEffectiveVerticalContentAlignment=function(){if(void 0!==this.verticalContentAlignment)return this.verticalContentAlignment;var e=this.getParentContainer();return e?e.getEffectiveVerticalContentAlignment():As.VerticalAlignment.Top},t.prototype.getItemCount=function(){return this._items.length},t.prototype.getItemAt=function(e){return this._items[e]},t.prototype.getFirstVisibleRenderedItem=function(){if(this.renderedElement&&this._renderedItems&&this._renderedItems.length>0)for(var e=0,t=this._renderedItems;e<t.length;e++){var r=t[e];if(r.isVisible)return r}},t.prototype.getLastVisibleRenderedItem=function(){if(this.renderedElement&&this._renderedItems&&this._renderedItems.length>0)for(var e=this._renderedItems.length-1;e>=0;e--)if(this._renderedItems[e].isVisible)return this._renderedItems[e]},t.prototype.getJsonTypeName=function(){return"Container"},t.prototype.isFirstElement=function(e){for(var t=this.isDesignMode(),r=0,n=this._items;r<n.length;r++){var i=n[r];if(i.isVisible||t)return i===e}return!1},t.prototype.isLastElement=function(e){for(var t=this.isDesignMode(),r=this._items.length-1;r>=0;r--)if(this._items[r].isVisible||t)return this._items[r]===e;return!1},t.prototype.isRtl=function(){if(void 0!==this.rtl)return this.rtl;var e=this.getParentContainer();return!!e&&e.isRtl()},t.prototype.isBleedingAtTop=function(){var e=this.getFirstVisibleRenderedItem();return this.isBleeding()||!!e&&e.isBleedingAtTop()},t.prototype.isBleedingAtBottom=function(){var e=this.getLastVisibleRenderedItem();return this.isBleeding()||!!e&&(e.isBleedingAtBottom()&&e.getEffectiveStyle()===this.getEffectiveStyle())},t.prototype.indexOf=function(e){return this._items.indexOf(e)},t.prototype.addItem=function(e){this.insertItemAt(e,-1,!1)},t.prototype.insertItemBefore=function(e,t){this.insertItemAt(e,this._items.indexOf(t),!1)},t.prototype.insertItemAfter=function(e,t){this.insertItemAt(e,this._items.indexOf(t)+1,!1)},t.prototype.removeItem=function(e){var t=this._items.indexOf(e);return t>=0&&(this._items.splice(t,1),e.setParent(void 0),this.updateLayout(),!0)},t.prototype.clear=function(){this._items=[],this._renderedItems=[]},t.prototype.getResourceInformation=function(){var t=e.prototype.getResourceInformation.call(this);return this.backgroundImage.isValid()&&t.push({url:this.backgroundImage.url,mimeType:"image"}),t},t.prototype.getActionById=function(t){var r=e.prototype.getActionById.call(this,t);if(!r&&(this.selectAction&&(r=this.selectAction.getActionById(t)),!r))for(var n=0,i=this._items;n<i.length;n++){if(r=i[n].getActionById(t))break}return r},Object.defineProperty(t.prototype,"padding",{get:function(){return this.getPadding()},set:function(e){this.setPadding(e)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"selectAction",{get:function(){return this._selectAction},set:function(e){this._selectAction=e},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"bleed",{get:function(){return this.getBleed()},set:function(e){this.setBleed(e)},enumerable:!1,configurable:!0}),t.backgroundImageProperty=new Ls.SerializableObjectProperty(Ls.Versions.v1_0,"backgroundImage",Ul),t.verticalContentAlignmentProperty=new Ls.EnumProperty(Ls.Versions.v1_1,"verticalContentAlignment",As.VerticalAlignment),t.rtlProperty=new Ls.BoolProperty(Ls.Versions.v1_0,"rtl"),Ss([(0,Ls.property)(t.backgroundImageProperty)],t.prototype,"backgroundImage",null),Ss([(0,Ls.property)(t.verticalContentAlignmentProperty)],t.prototype,"verticalContentAlignment",void 0),Ss([(0,Ls.property)(t.rtlProperty)],t.prototype,"rtl",void 0),t}(ql);yo.Container=Gl;var Xl=function(e){function t(t){void 0===t&&(t="stretch");var r=e.call(this)||this;return r.width="stretch",r._computedWeight=0,r.width=t,r}return ks(t,e),t.prototype.adjustRenderedElementSize=function(e){this.isDesignMode()?(e.style.minWidth="20px",e.style.minHeight=(this.minPixelHeight?Math.max(this.minPixelHeight,20):20)+"px"):(e.style.minWidth="0",this.minPixelHeight&&(e.style.minHeight=this.minPixelHeight+"px")),"auto"===this.width?e.style.flex="0 1 auto":"stretch"===this.width?e.style.flex="1 1 50px":this.width instanceof Ps.SizeAndUnit&&(this.width.unit===As.SizeUnit.Pixel?(e.style.flex="0 0 auto",e.style.width=this.width.physicalSize+"px"):e.style.flex="1 1 "+(this._computedWeight>0?this._computedWeight:this.width.physicalSize)+"%")},t.prototype.shouldSerialize=function(e){return!0},Object.defineProperty(t.prototype,"separatorOrientation",{get:function(){return As.Orientation.Vertical},enumerable:!1,configurable:!0}),t.prototype.getJsonTypeName=function(){return"Column"},Object.defineProperty(t.prototype,"hasVisibleSeparator",{get:function(){return!!(this.parent&&this.parent instanceof Jl)&&(void 0!==this.separatorElement&&!this.parent.isLeftMostElement(this))},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"isStandalone",{get:function(){return!1},enumerable:!1,configurable:!0}),t.widthProperty=new Ls.CustomProperty(Ls.Versions.v1_0,"width",function(e,t,r,n){var i=t.defaultValue,o=r[t.name],a=!1;if("number"!=typeof o||isNaN(o))if("auto"===o||"stretch"===o)i=o;else if("string"==typeof o)try{(i=Ps.SizeAndUnit.parse(o)).unit===As.SizeUnit.Pixel&&t.targetVersion.compareTo(n.targetVersion)>0&&(a=!0)}catch(s){a=!0}else a=!0;else i=new Ps.SizeAndUnit(o,As.SizeUnit.Weight);return a&&(n.logParseEvent(e,As.ValidationEvent.InvalidPropertyValue,Ns.Strings.errors.invalidColumnWidth(o)),i="auto"),i},function(e,t,r,n,i){n instanceof Ps.SizeAndUnit?n.unit===As.SizeUnit.Pixel?i.serializeValue(r,"width",n.physicalSize+"px"):i.serializeNumber(r,"width",n.physicalSize):i.serializeValue(r,"width",n)},"stretch"),Ss([(0,Ls.property)(t.widthProperty)],t.prototype,"width",void 0),t}(Gl);yo.Column=Xl;var Jl=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t._columns=[],t}return ks(t,e),t.prototype.createColumnInstance=function(e,t){return t.parseCardObject(this,e,[],!this.isDesignMode(),function(e){return e&&"Column"!==e?void 0:new Xl},function(e,r){t.logParseEvent(void 0,As.ValidationEvent.ElementTypeNotAllowed,Ns.Strings.errors.elementTypeNotAllowed(e))})},t.prototype.internalRender=function(){if(this._renderedColumns=[],this._columns.length>0){var e=this.hostConfig,t=document.createElement("div");switch(t.className=e.makeCssClassName("ac-columnSet"),t.style.display="flex",Ps.GlobalSettings.useAdvancedCardBottomTruncation&&(t.style.minHeight="-webkit-min-content"),this.getEffectiveHorizontalAlignment()){case As.HorizontalAlignment.Center:t.style.justifyContent="center";break;case As.HorizontalAlignment.Right:t.style.justifyContent="flex-end";break;default:t.style.justifyContent="flex-start"}for(var r=0,n=0,i=this._columns;n<i.length;n++){(s=i[n]).width instanceof Ps.SizeAndUnit&&s.width.unit===As.SizeUnit.Weight&&(r+=s.width.physicalSize)}for(var o=0,a=this._columns;o<a.length;o++){var s;if((s=a[o]).width instanceof Ps.SizeAndUnit&&s.width.unit===As.SizeUnit.Weight&&r>0){var l=100/r*s.width.physicalSize;s._computedWeight=l}var c=s.render();c&&(this._renderedColumns.length>0&&s.separatorElement&&(s.separatorElement.style.flex="0 0 auto",Es.appendChild(t,s.separatorElement)),Es.appendChild(t,c),this._renderedColumns.push(s))}return this._renderedColumns.length>0?t:void 0}},t.prototype.truncateOverflow=function(e){for(var t=0,r=this._columns;t<r.length;t++){r[t].handleOverflow(e)}return!0},t.prototype.undoOverflowTruncation=function(){for(var e=0,t=this._columns;e<t.length;e++){t[e].resetOverflow()}},Object.defineProperty(t.prototype,"isSelectable",{get:function(){return!0},enumerable:!1,configurable:!0}),t.prototype.internalParse=function(t,r){e.prototype.internalParse.call(this,t,r),this._columns=[],this._renderedColumns=[];var n=t.columns;if(Array.isArray(n))for(var i=0,o=n;i<o.length;i++){var a=o[i],s=this.createColumnInstance(a,r);s&&this._columns.push(s)}},t.prototype.internalToJSON=function(t,r){e.prototype.internalToJSON.call(this,t,r),r.serializeArray(t,"columns",this._columns)},t.prototype.isFirstElement=function(e){for(var t=0,r=this._columns;t<r.length;t++){var n=r[t];if(n.isVisible)return n===e}return!1},t.prototype.isBleedingAtTop=function(){if(this.isBleeding())return!0;if(this._renderedColumns&&this._renderedColumns.length>0)for(var e=0,t=this._columns;e<t.length;e++){if(t[e].isBleedingAtTop())return!0}return!1},t.prototype.isBleedingAtBottom=function(){if(this.isBleeding())return!0;if(this._renderedColumns&&this._renderedColumns.length>0)for(var e=0,t=this._columns;e<t.length;e++){if(t[e].isBleedingAtBottom())return!0}return!1},t.prototype.getItemCount=function(){return this._columns.length},t.prototype.getFirstVisibleRenderedItem=function(){return this.renderedElement&&this._renderedColumns&&this._renderedColumns.length>0?this._renderedColumns[0]:void 0},t.prototype.getLastVisibleRenderedItem=function(){return this.renderedElement&&this._renderedColumns&&this._renderedColumns.length>0?this._renderedColumns[this._renderedColumns.length-1]:void 0},t.prototype.getColumnAt=function(e){return this._columns[e]},t.prototype.getItemAt=function(e){return this.getColumnAt(e)},t.prototype.getJsonTypeName=function(){return"ColumnSet"},t.prototype.internalValidateProperties=function(t){e.prototype.internalValidateProperties.call(this,t);for(var r=0,n=0,i=0,o=this._columns;i<o.length;i++){var a=o[i];"number"==typeof a.width?r++:"stretch"===a.width&&n++}r>0&&n>0&&t.addFailure(this,As.ValidationEvent.Hint,Ns.Strings.hints.dontUseWeightedAndStrecthedColumnsInSameSet())},t.prototype.addColumn=function(e){if(e.parent)throw new Error(Ns.Strings.errors.columnAlreadyBelongsToAnotherSet());this._columns.push(e),e.setParent(this)},t.prototype.removeItem=function(e){if(e instanceof Xl){var t=this._columns.indexOf(e);if(t>=0)return this._columns.splice(t,1),e.setParent(void 0),this.updateLayout(),!0}return!1},t.prototype.indexOf=function(e){return e instanceof Xl?this._columns.indexOf(e):-1},t.prototype.isLeftMostElement=function(e){return 0===this._columns.indexOf(e)},t.prototype.isRightMostElement=function(e){return this._columns.indexOf(e)===this._columns.length-1},t.prototype.isTopElement=function(e){return this._columns.indexOf(e)>=0},t.prototype.isBottomElement=function(e){return this._columns.indexOf(e)>=0},t.prototype.getActionById=function(e){for(var t=void 0,r=0,n=this._columns;r<n.length;r++){if(t=n[r].getActionById(e))break}return t},Object.defineProperty(t.prototype,"bleed",{get:function(){return this.getBleed()},set:function(e){this.setBleed(e)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"padding",{get:function(){return this.getPadding()},set:function(e){this.setPadding(e)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"selectAction",{get:function(){return this._selectAction},set:function(e){this._selectAction=e},enumerable:!1,configurable:!0}),t}(ql);function Yl(e){var t=e.getRootElement(),r=t&&t.onImageLoaded?t.onImageLoaded:sc.onImageLoaded;r&&r(e)}function Zl(e,t,r){var n=e.getRootElement(),i=n&&n.onAnchorClicked?n.onAnchorClicked:sc.onAnchorClicked;return void 0!==i&&i(e,t,r)}function Kl(e,t){var r=e.parent?e.parent.getRootElement():void 0,n=r&&r.onInlineCardExpanded?r.onInlineCardExpanded:sc.onInlineCardExpanded;n&&n(e,t)}function Ql(e,t){void 0===t&&(t=!0);var r=e.getRootElement();t&&r.updateLayout();var n=r,i=n&&n.onElementVisibilityChanged?n.onElementVisibilityChanged:sc.onElementVisibilityChanged;void 0!==i&&i(e)}function ec(e,t){t?(e.readOnly=!0,e.required=!0):(e.readOnly=!1,e.required=!1)}yo.ColumnSet=Jl;var tc=function(e){function t(){var t=e.call(this)||this;return t._actionCollection=new zl(t),t}return ks(t,e),t.prototype.internalParse=function(t,r){e.prototype.internalParse.call(this,t,r),this.parseActions(t,r)},t.prototype.parseActions=function(e,t){this._actionCollection.parse(e.actions,t)},t.prototype.internalToJSON=function(t,r){e.prototype.internalToJSON.call(this,t,r),this._actionCollection.toJSON(t,"actions",r)},t.prototype.internalRender=function(){var t=e.prototype.internalRender.call(this);if(t){var r=this._actionCollection.render(this.hostConfig.actions.actionsOrientation);return r&&(Es.appendChild(t,Fs(this.hostConfig,{spacing:this.hostConfig.getEffectiveSpacing(this.hostConfig.actions.spacing)},As.Orientation.Horizontal)),Es.appendChild(t,r)),this.renderIfEmpty||t.children.length>0?t:void 0}},t.prototype.getHasExpandedAction=function(){return 0!==this.renderedActionCount&&(1===this.renderedActionCount?void 0!==this._actionCollection.expandedAction&&!this.hostConfig.actions.preExpandSingleShowCardAction:void 0!==this._actionCollection.expandedAction)},Object.defineProperty(t.prototype,"renderedActionCount",{get:function(){return this._actionCollection.renderedActionCount},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"renderIfEmpty",{get:function(){return!1},enumerable:!1,configurable:!0}),t.prototype.releaseDOMResources=function(){e.prototype.releaseDOMResources.call(this),this._actionCollection.releaseDOMResources()},t.prototype.getActionCount=function(){return this._actionCollection.getActionCount()},t.prototype.getActionAt=function(t){return t>=0&&t<this.getActionCount()?this._actionCollection.getActionAt(t):e.prototype.getActionAt.call(this,t)},t.prototype.getActionById=function(t){var r=this._actionCollection.getActionById(t);return r||e.prototype.getActionById.call(this,t)},t.prototype.internalValidateProperties=function(t){e.prototype.internalValidateProperties.call(this,t),this._actionCollection&&this._actionCollection.validateProperties(t)},t.prototype.isLastElement=function(t){return e.prototype.isLastElement.call(this,t)&&0===this._actionCollection.getActionCount()},t.prototype.addAction=function(e){this._actionCollection.addAction(e)},t.prototype.clear=function(){e.prototype.clear.call(this),this._actionCollection.clear()},t.prototype.getAllInputs=function(t){void 0===t&&(t=!0);var r=e.prototype.getAllInputs.call(this,t);return t&&r.push.apply(r,this._actionCollection.getAllInputs(t)),r},t.prototype.getResourceInformation=function(){var t=e.prototype.getResourceInformation.call(this);return t.push.apply(t,this._actionCollection.getResourceInformation()),t},t.prototype.isBleedingAtBottom=function(){return 0===this._actionCollection.renderedActionCount?e.prototype.isBleedingAtBottom.call(this):1===this._actionCollection.getActionCount()?void 0!==this._actionCollection.expandedAction&&!this.hostConfig.actions.preExpandSingleShowCardAction:void 0!==this._actionCollection.expandedAction},t.prototype.getForbiddenActionNames=function(){return[]},t.prototype.getElementById=function(t){var r=e.prototype.getElementById.call(this,t);return r||(r=this.getElementByIdFromAction(t)),r},Object.defineProperty(t.prototype,"isStandalone",{get:function(){return!1},enumerable:!1,configurable:!0}),t}(Gl);yo.ContainerWithActions=tc;var rc=function(e){function t(t,r){var n=e.call(this,t,r,void 0)||this;return n.targetVersion=t,n.name=r,n}return ks(t,e),t.prototype.parse=function(e,t,r){var n=r.parseAction(e.parent,t[this.name],[],!1);if(void 0!==n){if(n instanceof Pl)return n;r.logParseEvent(e,As.ValidationEvent.ActionTypeNotAllowed,Ns.Strings.errors.actionTypeNotAllowed(n.getJsonTypeName()))}r.logParseEvent(e,As.ValidationEvent.PropertyCantBeNull,Ns.Strings.errors.propertyMustBeSet("action"))},t.prototype.toJSON=function(e,t,r,n){n.serializeValue(t,this.name,r?r.toJSON(n):void 0,void 0,!0)},t}(Ls.PropertyDefinition);yo.RefreshActionProperty=rc;var nc=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return ks(t,e),Object.defineProperty(t.prototype,"action",{get:function(){return this.getValue(t.actionProperty)},set:function(e){this.setValue(t.actionProperty,e),e&&e.setParent(this.parent)},enumerable:!1,configurable:!0}),t.prototype.getSchemaKey=function(){return"RefreshDefinition"},t.actionProperty=new rc(Ls.Versions.v1_4,"action"),t.userIdsProperty=new Ls.StringArrayProperty(Ls.Versions.v1_4,"userIds"),Ss([(0,Ls.property)(t.actionProperty)],t.prototype,"action",null),Ss([(0,Ls.property)(t.userIdsProperty)],t.prototype,"userIds",void 0),t}(Ls.SerializableObject);yo.RefreshDefinition=nc;var ic=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return ks(t,e),t.prototype.getSchemaKey=function(){return"AuthCardButton"},t.typeProperty=new Ls.StringProperty(Ls.Versions.v1_4,"type"),t.titleProperty=new Ls.StringProperty(Ls.Versions.v1_4,"title"),t.imageProperty=new Ls.StringProperty(Ls.Versions.v1_4,"image"),t.valueProperty=new Ls.StringProperty(Ls.Versions.v1_4,"value"),Ss([(0,Ls.property)(t.typeProperty)],t.prototype,"type",void 0),Ss([(0,Ls.property)(t.titleProperty)],t.prototype,"title",void 0),Ss([(0,Ls.property)(t.imageProperty)],t.prototype,"image",void 0),Ss([(0,Ls.property)(t.valueProperty)],t.prototype,"value",void 0),t}(Ls.SerializableObject);yo.AuthCardButton=ic;var oc=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return ks(t,e),t.prototype.getSchemaKey=function(){return"TokenExchangeResource"},t.idProperty=new Ls.StringProperty(Ls.Versions.v1_4,"id"),t.uriProperty=new Ls.StringProperty(Ls.Versions.v1_4,"uri"),t.providerIdProperty=new Ls.StringProperty(Ls.Versions.v1_4,"providerId"),Ss([(0,Ls.property)(t.idProperty)],t.prototype,"id",void 0),Ss([(0,Ls.property)(t.uriProperty)],t.prototype,"uri",void 0),Ss([(0,Ls.property)(t.providerIdProperty)],t.prototype,"providerId",void 0),t}(Ls.SerializableObject);yo.TokenExchangeResource=oc;var ac=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return ks(t,e),t.prototype.getSchemaKey=function(){return"Authentication"},t.textProperty=new Ls.StringProperty(Ls.Versions.v1_4,"text"),t.connectionNameProperty=new Ls.StringProperty(Ls.Versions.v1_4,"connectionName"),t.buttonsProperty=new Ls.SerializableObjectCollectionProperty(Ls.Versions.v1_4,"buttons",ic),t.tokenExchangeResourceProperty=new Ls.SerializableObjectProperty(Ls.Versions.v1_4,"tokenExchangeResource",oc,!0),Ss([(0,Ls.property)(t.textProperty)],t.prototype,"text",void 0),Ss([(0,Ls.property)(t.connectionNameProperty)],t.prototype,"connectionName",void 0),Ss([(0,Ls.property)(t.buttonsProperty)],t.prototype,"buttons",void 0),Ss([(0,Ls.property)(t.tokenExchangeResourceProperty)],t.prototype,"tokenExchangeResource",void 0),t}(Ls.SerializableObject);yo.Authentication=ac;var sc=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.designMode=!1,t}return ks(t,e),Object.defineProperty(t.prototype,"refresh",{get:function(){return this.getValue(t.refreshProperty)},set:function(e){this.setValue(t.refreshProperty,e),e&&(e.parent=this)},enumerable:!1,configurable:!0}),Object.defineProperty(t,"processMarkdown",{get:function(){throw new Error(Ns.Strings.errors.processMarkdownEventRemoved())},set:function(e){throw new Error(Ns.Strings.errors.processMarkdownEventRemoved())},enumerable:!1,configurable:!0}),t.applyMarkdown=function(e){var r={didProcess:!1};if(t.onProcessMarkdown)t.onProcessMarkdown(e,r);else if(window.markdownit){var n=window.markdownit;r.outputHtml=n().render(e),r.didProcess=!0}else t._haveWarnedAboutNoMarkdownProcessing||(console.warn(Ns.Strings.errors.markdownProcessingNotEnabled),t._haveWarnedAboutNoMarkdownProcessing=!0);return r},t.prototype.isVersionSupported=function(){return!!this.bypassVersionCheck||!(!this.version||!this.version.isValid||this.maxVersion.major<this.version.major||this.maxVersion.major===this.version.major&&this.maxVersion.minor<this.version.minor)},t.prototype.getDefaultSerializationContext=function(){return new cc(this.version)},t.prototype.getItemsCollectionPropertyName=function(){return"body"},t.prototype.internalParse=function(r,n){this._fallbackCard=void 0;var i=n.parseElement(void 0,r.fallback,this.forbiddenChildElements(),!this.isDesignMode());i&&(this._fallbackCard=new t,this._fallbackCard.addItem(i)),e.prototype.internalParse.call(this,r,n)},t.prototype.internalToJSON=function(r,n){this.setValue(t.versionProperty,n.targetVersion),e.prototype.internalToJSON.call(this,r,n)},t.prototype.internalRender=function(){var t=e.prototype.internalRender.call(this);return Ps.GlobalSettings.useAdvancedCardBottomTruncation&&t&&t.style.removeProperty("minHeight"),t},t.prototype.getHasBackground=function(e){return!0},t.prototype.getDefaultPadding=function(){return new Ps.PaddingDefinition(As.Spacing.Padding,As.Spacing.Padding,As.Spacing.Padding,As.Spacing.Padding)},t.prototype.shouldSerialize=function(e){return!0},Object.defineProperty(t.prototype,"renderIfEmpty",{get:function(){return!0},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"bypassVersionCheck",{get:function(){return!1},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"allowCustomStyle",{get:function(){return this.hostConfig.adaptiveCard&&this.hostConfig.adaptiveCard.allowCustomStyle},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"hasBackground",{get:function(){return!0},enumerable:!1,configurable:!0}),t.prototype.getJsonTypeName=function(){return"AdaptiveCard"},t.prototype.internalValidateProperties=function(t){e.prototype.internalValidateProperties.call(this,t),"AdaptiveCard"!==this.getValue(Rs.typeNameProperty)&&t.addFailure(this,As.ValidationEvent.MissingCardType,Ns.Strings.errors.invalidCardType()),this.bypassVersionCheck||this.version?this.isVersionSupported()||t.addFailure(this,As.ValidationEvent.UnsupportedCardVersion,Ns.Strings.errors.unsupportedCardVersion(this.version.toString(),this.maxVersion.toString())):t.addFailure(this,As.ValidationEvent.PropertyCantBeNull,Ns.Strings.errors.propertyMustBeSet("version"))},t.prototype.render=function(t){var r,n=this;return this.shouldFallback()&&this._fallbackCard?(this._fallbackCard.hostConfig=this.hostConfig,r=this._fallbackCard.render()):(r=e.prototype.render.call(this))&&(r.classList.add(this.hostConfig.makeCssClassName("ac-adaptiveCard")),Ps.GlobalSettings.setTabIndexAtCardRoot&&(r.tabIndex=0),this.speak&&r.setAttribute("aria-label",this.speak),r.onmouseenter=function(e){n.updateInputsVisualState(!0)},r.onmouseleave=function(e){n.updateInputsVisualState(!1)},this.getRootElement().updateActionsEnabledState()),t&&(Es.appendChild(t,r),this.updateLayout()),r},t.prototype.updateLayout=function(t){if(void 0===t&&(t=!0),e.prototype.updateLayout.call(this,t),Ps.GlobalSettings.useAdvancedCardBottomTruncation&&this.isDisplayed()){var r=this.hostConfig.getEffectiveSpacing(As.Spacing.Default);this.handleOverflow(this.renderedElement.offsetHeight-r)}},t.prototype.shouldFallback=function(){return e.prototype.shouldFallback.call(this)||!this.isVersionSupported()},Object.defineProperty(t.prototype,"hasVisibleSeparator",{get:function(){return!1},enumerable:!1,configurable:!0}),t.schemaUrl="http://adaptivecards.io/schemas/adaptive-card.json",t.$schemaProperty=new Ls.CustomProperty(Ls.Versions.v1_0,"$schema",function(e,r,n,i){return t.schemaUrl},function(e,r,n,i,o){o.serializeValue(n,r.name,t.schemaUrl)}),t.versionProperty=new Ls.CustomProperty(Ls.Versions.v1_0,"version",function(e,t,r,n){var i=Ls.Version.parse(r[t.name],n);return void 0===i&&(i=Ls.Versions.latest,n.logParseEvent(e,As.ValidationEvent.InvalidPropertyValue,Ns.Strings.errors.invalidCardVersion(i.toString()))),i},function(e,t,r,n,i){void 0!==n&&i.serializeValue(r,t.name,n.toString())},Ls.Versions.v1_0),t.fallbackTextProperty=new Ls.StringProperty(Ls.Versions.v1_0,"fallbackText"),t.speakProperty=new Ls.StringProperty(Ls.Versions.v1_0,"speak"),t.refreshProperty=new Ls.SerializableObjectProperty(Ls.Versions.v1_4,"refresh",nc,!0),t.authenticationProperty=new Ls.SerializableObjectProperty(Ls.Versions.v1_4,"authentication",ac,!0),t._haveWarnedAboutNoMarkdownProcessing=!1,Ss([(0,Ls.property)(t.versionProperty)],t.prototype,"version",void 0),Ss([(0,Ls.property)(t.fallbackTextProperty)],t.prototype,"fallbackText",void 0),Ss([(0,Ls.property)(t.speakProperty)],t.prototype,"speak",void 0),Ss([(0,Ls.property)(t.refreshProperty)],t.prototype,"refresh",null),Ss([(0,Ls.property)(t.authenticationProperty)],t.prototype,"authentication",void 0),t}(tc);yo.AdaptiveCard=sc;var lc=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.suppressStyle=!1,t}return ks(t,e),t.prototype.getSchemaKey=function(){return"InlineAdaptiveCard"},t.prototype.populateSchema=function(t){e.prototype.populateSchema.call(this,t),t.remove(sc.$schemaProperty,sc.versionProperty)},t.prototype.getDefaultPadding=function(){return new Ps.PaddingDefinition(this.suppressStyle?As.Spacing.None:As.Spacing.Padding,As.Spacing.Padding,this.suppressStyle?As.Spacing.None:As.Spacing.Padding,As.Spacing.Padding)},Object.defineProperty(t.prototype,"bypassVersionCheck",{get:function(){return!0},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"defaultStyle",{get:function(){return this.suppressStyle?As.ContainerStyle.Default:this.hostConfig.actions.showCard.style?this.hostConfig.actions.showCard.style:As.ContainerStyle.Emphasis},enumerable:!1,configurable:!0}),t.prototype.render=function(t){var r=e.prototype.render.call(this,t);return r&&(r.setAttribute("aria-live","polite"),r.removeAttribute("tabindex")),r},t}(sc),cc=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t._forbiddenTypes=new Set,t}return ks(t,e),t.prototype.internalParseCardObject=function(e,t,r,n,i,o){var a=this,s=void 0;if(t&&"object"==typeof t){var l=new Set;this._forbiddenTypes.forEach(function(e){l.add(e)}),r.forEach(function(e){a._forbiddenTypes.add(e)});var c=Es.parseString(t.type);if(c&&this._forbiddenTypes.has(c))o(c,As.TypeErrorType.ForbiddenType);else{var u=!1;if((s=i(c))?(s.setParent(e),s.parse(t,this),u=Ps.GlobalSettings.enableFallback&&n&&s.shouldFallback()):(u=Ps.GlobalSettings.enableFallback&&n,o(c,As.TypeErrorType.UnknownType)),u){var h=t.fallback;!h&&e&&e.setShouldFallback(!0),"string"==typeof h&&"drop"===h.toLowerCase()?s=void 0:"object"==typeof h&&(s=this.internalParseCardObject(e,h,r,!0,i,o))}}this._forbiddenTypes=l}return s},t.prototype.cardObjectParsed=function(e,t){e instanceof kl&&this.onParseAction?this.onParseAction(e,t,this):e instanceof Rs&&this.onParseElement&&this.onParseElement(e,t,this)},t.prototype.shouldSerialize=function(e){return e instanceof kl?void 0!==this.actionRegistry.findByName(e.getJsonTypeName()):!(e instanceof Rs)||void 0!==this.elementRegistry.findByName(e.getJsonTypeName())},t.prototype.parseCardObject=function(e,t,r,n,i,o){var a=new Set(r),s=this.internalParseCardObject(e,t,a,n,i,o);return void 0!==s&&this.cardObjectParsed(s,t),s},t.prototype.parseElement=function(e,t,r,n){var i=this;return this.parseCardObject(e,t,r,n,function(e){return i.elementRegistry.createInstance(e,i.targetVersion)},function(e,t){t===As.TypeErrorType.UnknownType?i.logParseEvent(void 0,As.ValidationEvent.UnknownElementType,Ns.Strings.errors.unknownElementType(e)):i.logParseEvent(void 0,As.ValidationEvent.ElementTypeNotAllowed,Ns.Strings.errors.elementTypeNotAllowed(e))})},t.prototype.parseAction=function(e,t,r,n){var i=this;return this.parseCardObject(e,t,r,n,function(e){return i.actionRegistry.createInstance(e,i.targetVersion)},function(e,t){t===As.TypeErrorType.UnknownType?i.logParseEvent(void 0,As.ValidationEvent.UnknownActionType,Ns.Strings.errors.unknownActionType(e)):i.logParseEvent(void 0,As.ValidationEvent.ActionTypeNotAllowed,Ns.Strings.errors.actionTypeNotAllowed(e))})},Object.defineProperty(t.prototype,"elementRegistry",{get:function(){var e;return null!==(e=this._elementRegistry)&&void 0!==e?e:js.GlobalRegistry.elements},enumerable:!1,configurable:!0}),t.prototype.setElementRegistry=function(e){this._elementRegistry=e},Object.defineProperty(t.prototype,"actionRegistry",{get:function(){var e;return null!==(e=this._actionRegistry)&&void 0!==e?e:js.GlobalRegistry.actions},enumerable:!1,configurable:!0}),t.prototype.setActionRegistry=function(e){this._actionRegistry=e},t}(Ls.BaseSerializationContext);yo.SerializationContext=cc,js.GlobalRegistry.defaultElements.register("Container",Gl),js.GlobalRegistry.defaultElements.register("TextBlock",Vs),js.GlobalRegistry.defaultElements.register("RichTextBlock",Hs,Ls.Versions.v1_2),js.GlobalRegistry.defaultElements.register("TextRun",Ws,Ls.Versions.v1_2),js.GlobalRegistry.defaultElements.register("Image",Xs),js.GlobalRegistry.defaultElements.register("ImageSet",Zs),js.GlobalRegistry.defaultElements.register("Media",hl,Ls.Versions.v1_1),js.GlobalRegistry.defaultElements.register("FactSet",Us),js.GlobalRegistry.defaultElements.register("ColumnSet",Jl),js.GlobalRegistry.defaultElements.register("ActionSet",Vl,Ls.Versions.v1_2),js.GlobalRegistry.defaultElements.register("Input.Text",pl),js.GlobalRegistry.defaultElements.register("Input.Date",vl),js.GlobalRegistry.defaultElements.register("Input.Time",wl),js.GlobalRegistry.defaultElements.register("Input.Number",bl),js.GlobalRegistry.defaultElements.register("Input.ChoiceSet",yl),js.GlobalRegistry.defaultElements.register("Input.Toggle",fl),js.GlobalRegistry.defaultActions.register(Il.JsonTypeName,Il),js.GlobalRegistry.defaultActions.register(_l.JsonTypeName,_l),js.GlobalRegistry.defaultActions.register(Fl.JsonTypeName,Fl),js.GlobalRegistry.defaultActions.register(Ll.JsonTypeName,Ll,Ls.Versions.v1_2),js.GlobalRegistry.defaultActions.register(Pl.JsonTypeName,Pl,Ls.Versions.v1_4);const uc=e=>{let t;return t=e.iconUrl?b.jsx(w.Button,{className:e.className,onClick:e.actionClickHandler,appearance:"primary",children:b.jsxs("div",{style:{display:"flex",flexDirection:e.iconPlacement===xo.ActionIconPlacement.LeftOfTitle?"row":"column",justifyContent:"center",alignItems:"center"},children:[b.jsx("img",{src:e.iconUrl,style:{width:e.iconSize,height:e.iconSize,flexShrink:0,marginRight:e.iconPlacement===xo.ActionIconPlacement.LeftOfTitle?4:0,marginBottom:e.iconPlacement!==xo.ActionIconPlacement.LeftOfTitle?4:0},alt:""}),b.jsx("span",{children:e.text})]})}):"positive"===e.style.toLocaleLowerCase().trim()||"destructive"===e.style.toLocaleLowerCase().trim()?b.jsx(w.Button,{className:e.className,onClick:e.actionClickHandler,appearance:"primary",children:e.text}):b.jsx(w.Button,{className:e.className,onClick:e.actionClickHandler,children:e.text}),t},hc=(e,t,r,n,i,o,a,s)=>{const l=document.createElement("div");l.className="fluentUI";const c=mo(l);c.render(b.jsx(w.IdPrefixProvider,{value:j.generateUniqueId(),children:b.jsx(w.FluentProvider,{theme:s,children:b.jsx(uc,{text:e,className:r,iconUrl:t,iconPlacement:n,iconSize:i,actionClickHandler:o,style:a,theme:s})})}));const u=new MutationObserver(e=>{for(const t of e)for(const e of Array.from(t.removedNodes))if(e===l||l.contains(e))return c.unmount(),void u.disconnect()});if(l.parentNode)u.observe(l.parentNode,{childList:!0});else{const e=new MutationObserver(()=>{l.parentNode&&(u.observe(l.parentNode,{childList:!0}),e.disconnect())});e.observe(document.body,{childList:!0,subtree:!0})}return l};class dc extends El{constructor(){super(...arguments),y(this,"actionClickHandler",e=>{e.stopPropagation(),e.preventDefault(),this.execute()})}updateCssClasses(){}render(e){var t,r;const n=this.hostConfig.hostCapabilities.getCustomProperty(ho),i=(null==(r=null==(t=this.parent)?void 0:t.hostConfig)?void 0:r.actions)??{iconPlacement:"left",iconSize:24};this._renderedElement=hc(this.title??"",this.iconUrl||"",e||"",i.iconPlacement,i.iconSize,this.actionClickHandler,this.style,n)}}class pc extends Bl{constructor(){super(...arguments),y(this,"actionClickHandler",e=>{e.stopPropagation(),e.preventDefault(),this.execute()})}updateCssClasses(){}render(e){var t,r;const n=this.hostConfig.hostCapabilities.getCustomProperty(ho),i=(null==(r=null==(t=this.parent)?void 0:t.hostConfig)?void 0:r.actions)??{iconPlacement:"left",iconSize:24};this._renderedElement=hc(this.title??"",this.iconUrl||"",e||"",i.iconPlacement,i.iconSize,this.actionClickHandler,this.style,n)}}class fc extends Rl{constructor(){super(...arguments),y(this,"actionClickHandler",e=>{e.stopPropagation(),e.preventDefault(),this.execute()})}updateCssClasses(){if(this.renderedElement){const e=1===this.state;this.renderedElement.setAttribute("aria-expanded",e.toString())}}render(e){var t,r;const n=(null==(r=null==(t=this.parent)?void 0:t.hostConfig)?void 0:r.actions)??{iconPlacement:"left",iconSize:24};this._renderedElement=hc(this.title||"Default Title",this.iconUrl||"",this.iconUrl??"",n.iconPlacement,n.iconSize,this.actionClickHandler,this.style)}}class gc extends Tl{constructor(){super(...arguments),y(this,"actionClickHandler",e=>{e.stopPropagation(),e.preventDefault(),this.execute()})}updateCssClasses(){}render(e){var t,r;const n=this.hostConfig.hostCapabilities.getCustomProperty(ho),i=(null==(r=null==(t=this.parent)?void 0:t.hostConfig)?void 0:r.actions)??{iconPlacement:"left",iconSize:24};this._renderedElement=hc(this.title??"",this.iconUrl??"",e||"",i.iconPlacement,i.iconSize,this.actionClickHandler,this.style,n)}}class mc extends jl{constructor(){super(...arguments),y(this,"actionClickHandler",e=>{e.stopPropagation(),e.preventDefault(),this.execute()})}updateCssClasses(){if(this.renderedElement){const e=1===this.state;this.renderedElement.setAttribute("aria-expanded",e.toString())}}render(e){var t,r;const n=this.hostConfig.hostCapabilities.getCustomProperty(ho),i=(null==(r=null==(t=this.parent)?void 0:t.hostConfig)?void 0:r.actions)??{iconPlacement:"left",iconSize:24};this._renderedElement=hc(this.title??"",this.iconUrl??"",e||"",i.iconPlacement,i.iconSize,this.actionClickHandler,this.style,n)}}const yc=e=>{const t=document.createElement("div");return mo(t).render(e()),t};var xc=Object.defineProperty,bc=(e,t,r,n)=>{for(var i,o=void 0,a=e.length-1;a>=0;a--)(i=e[a])&&(o=i(t,r,o)||o);return o&&xc(t,r,o),o};const vc=(e=class extends j.Input{constructor(){super(...arguments),y(this,"defaultValue"),y(this,"style"),y(this,"isMultiSelect",!1),y(this,"placeholder"),y(this,"wrap",!1),y(this,"choices",[]),y(this,"element"),y(this,"refControl"),y(this,"selectedValues",[]),y(this,"defaultSelectedValues",[]),y(this,"updateSelectedValues",(e,t,r)=>{t?r?this.selectedValues.includes(e)||this.selectedValues.push(e):this.removeItemFromArray(this.selectedValues,e):this.selectedValues=[e]}),y(this,"removeItemFromArray",(e,t)=>{const r=e.indexOf(t);r>-1&&e.splice(r,1)})}get isCompact(){return!this.style||"compact"===this.style}set isCompact(e){this.style=e?void 0:"expanded"}internalRender(){const e=po(this.hostConfig),t=this.choices?this.choices.map(e=>({key:e.value,text:e.title})):[];this.defaultValue&&(this.defaultSelectedValues=this.defaultValue.split(this.hostConfig.choiceSetInputValueSeparator),this.selectedValues=[...this.defaultSelectedValues]);const r=()=>{var e;const[r,n]=q.useState(this.selectedValues);return q.useEffect(()=>{n(this.selectedValues)},[this.selectedValues.join(this.hostConfig.choiceSetInputValueSeparator)]),b.jsx(w.Combobox,{style:{width:"100%"},placeholder:this.placeholder,multiselect:this.isMultiSelect,value:this.isMultiSelect?r.map(e=>{var r;return null==(r=t.find(t=>t.key===e))?void 0:r.text}).join(this.hostConfig.choiceSetInputValueSeparator):null==(e=t.find(e=>r[0]===e.key))?void 0:e.text,selectedOptions:this.isMultiSelect?r:[r[0]],autoComplete:"filtered"===this.style?"on":"off",onOptionSelect:(e,t)=>{if(this.isMultiSelect)n(t.selectedOptions),this.selectedValues=t.selectedOptions;else{const e=t.optionValue??"";n([e]),this.selectedValues=[e]}this.valueChanged()},ref:e=>{this.refControl=e},children:t.map(e=>b.jsx(w.Option,{value:e.key,children:e.text??""},e.key))})};return this.element=yc(()=>b.jsxs(b.Fragment,{children:[!this.isMultiSelect&&"expanded"===this.style&&b.jsx(w.IdPrefixProvider,{value:j.generateUniqueId(),children:b.jsx(w.FluentProvider,{theme:e,children:b.jsx(w.RadioGroup,{defaultValue:this.defaultValue,onChange:(e,t)=>{this.updateSelectedValues(t.value,this.isMultiSelect,!0),this.valueChanged()},ref:e=>{this.refControl=e},children:this.choices.map((e,t)=>b.jsx(w.Radio,{value:e.value,label:e.title,style:{marginTop:t>0?this.hostConfig.spacing.default:0}},e.value))})})}),this.isMultiSelect&&"expanded"===this.style&&b.jsx("div",{style:{display:"flex",gap:this.hostConfig.spacing.default},children:this.choices.map((t,r)=>{const n=this.defaultSelectedValues.indexOf(t.value??"")>-1;return b.jsx(w.IdPrefixProvider,{value:j.generateUniqueId(),children:b.jsx(w.FluentProvider,{theme:e,children:b.jsx(w.Checkbox,{label:t.title,defaultChecked:n,onChange:(e,r)=>{this.updateSelectedValues(t.value??"",this.isMultiSelect,!!r),this.valueChanged()},ref:e=>{0===r&&(this.refControl=e)}})})},t.value)})}),("compact"===this.style||"filtered"===this.style)&&b.jsx(w.IdPrefixProvider,{value:j.generateUniqueId(),children:b.jsx(w.FluentProvider,{theme:e,children:b.jsx(r,{})})})]})),this.element.style.width="100%",this.element}getJsonTypeName(){return"Input.ChoiceSet"}focus(){this.refControl&&this.refControl.focus&&this.refControl.focus()}internalValidateProperties(e){super.internalValidateProperties(e),0===this.choices.length&&e.addFailure(this,j.ValidationEvent.CollectionCantBeEmpty,j.Strings.errors.choiceSetMustHaveAtLeastOneChoice());for(const t of this.choices)t.title&&t.value||e.addFailure(this,j.ValidationEvent.PropertyCantBeNull,j.Strings.errors.choiceSetChoicesMustHaveTitleAndValue())}isSet(){return!!this.value}isValid(){return!!this.value||!this.isRequired}get value(){if(this.selectedValues)return this.selectedValues.join(this.hostConfig.choiceSetInputValueSeparator)}},y(e,"valueProperty",new j.StringProperty(j.Versions.v1_5,"value")),y(e,"choicesProperty",new j.SerializableObjectCollectionProperty(j.Versions.v1_5,"choices",j.Choice)),y(e,"styleProperty",new j.ValueSetProperty(j.Versions.v1_5,"style",[{value:"compact"},{value:"expanded"},{value:"filtered",targetVersion:j.Versions.v1_5}],"compact")),y(e,"isMultiSelectProperty",new j.BoolProperty(j.Versions.v1_5,"isMultiSelect",!1)),y(e,"placeholderProperty",new j.StringProperty(j.Versions.v1_5,"placeholder")),y(e,"wrapProperty",new j.BoolProperty(j.Versions.v1_5,"wrap",!1)),e);bc([j.property(vc.valueProperty)],vc.prototype,"defaultValue"),bc([j.property(vc.styleProperty)],vc.prototype,"style"),bc([j.property(vc.isMultiSelectProperty)],vc.prototype,"isMultiSelect"),bc([j.property(vc.placeholderProperty)],vc.prototype,"placeholder"),bc([j.property(vc.wrapProperty)],vc.prototype,"wrap"),bc([j.property(vc.choicesProperty)],vc.prototype,"choices");let Cc=vc;var wc=Object.defineProperty,kc=(e,t,r,n)=>{for(var i,o=void 0,a=e.length-1;a>=0;a--)(i=e[a])&&(o=i(t,r,o)||o);return o&&wc(t,r,o),o};const Sc=(t=class extends j.Input{constructor(){super(...arguments),y(this,"defaultValue"),y(this,"min"),y(this,"max"),y(this,"placeholder"),y(this,"_value"),y(this,"refControl"),y(this,"element")}internalRender(){const e=po(this.hostConfig);return this.element=yc(()=>b.jsx(w.IdPrefixProvider,{value:j.generateUniqueId(),children:b.jsx(w.FluentProvider,{theme:e,children:b.jsx(O.DatePicker,{id:this.id,placeholder:this.placeholder,minDate:this.convertStringToDate(this.min),maxDate:this.convertStringToDate(this.max),onSelectDate:e=>{this._value=e??void 0,this.valueChanged()},ref:e=>{this.refControl=e},style:{width:"100%"}})})})),this.element.style.width="100%",this.element}convertStringToDate(e){if(e)try{const t=new Date(e);return isNaN(t.getTime())?void 0:t}catch{return}}getJsonTypeName(){return"Input.Date"}focus(){var e;null==(e=this.refControl)||e.focus()}updateInputControlAriaLabelledBy(){if(this.element){const e=this.getAllLabelIds().join(" ");e?this.element.setAttribute("aria-labelledby",e):this.element.removeAttribute("aria-labelledby")}}isSet(){return!!this.value}isValid(){if(!this.value)return!this.isRequired;const e=new Date(this.value);let t=!0;if(this.min){const r=new Date(this.min);t=t&&e>=r}if(this.max){const r=new Date(this.max);t=t&&e<=r}return t}get value(){if(this._value){const e=this._value.getTimezoneOffset();return new Date(this._value.getTime()-60*e*1e3).toISOString().split("T")[0]}}},y(t,"valueProperty",new j.StringProperty(j.Versions.v1_5,"value")),y(t,"placeholderProperty",new j.StringProperty(j.Versions.v1_5,"placeholder")),y(t,"minProperty",new j.StringProperty(j.Versions.v1_0,"min")),y(t,"maxProperty",new j.StringProperty(j.Versions.v1_0,"max")),t);kc([j.property(Sc.valueProperty)],Sc.prototype,"defaultValue"),kc([j.property(Sc.minProperty)],Sc.prototype,"min"),kc([j.property(Sc.maxProperty)],Sc.prototype,"max"),kc([j.property(Sc.placeholderProperty)],Sc.prototype,"placeholder");let _c=Sc;var Tc=Object.defineProperty,Ac=(e,t,r,n)=>{for(var i,o=void 0,a=e.length-1;a>=0;a--)(i=e[a])&&(o=i(t,r,o)||o);return o&&Tc(t,r,o),o};const Pc=(r=class extends j.Input{constructor(){super(...arguments),y(this,"defaultValue"),y(this,"min"),y(this,"max"),y(this,"placeholder"),y(this,"refControl",null),y(this,"element")}internalRender(){const e=po(this.hostConfig);return this.element=yc(()=>b.jsx(w.IdPrefixProvider,{value:j.generateUniqueId(),children:b.jsx(w.FluentProvider,{theme:e,children:b.jsx(w.SpinButton,{style:{width:"calc(100% - 10px)"},id:this.id,defaultValue:void 0!==this.defaultValue?this.defaultValue:void 0,placeholder:this.placeholder,min:this.min,max:this.max,onChange:()=>{this.valueChanged()},ref:e=>{this.refControl=e}})})})),this.element.style.width="100%",this.element}getJsonTypeName(){return"Input.Number"}focus(){var e;null==(e=this.refControl)||e.focus()}updateInputControlAriaLabelledBy(){if(this.element){const e=this.getAllLabelIds().join(" ");e?this.element.setAttribute("aria-labelledby",e):this.element.removeAttribute("aria-labelledby")}}isSet(){const e=this.value;return void 0!==e&&!isNaN(e)}isValid(){const e=this.value;if(void 0===e)return!this.isRequired;let t=!0;return void 0!==this.min&&(t=t&&e>=this.min),void 0!==this.max&&(t=t&&e<=this.max),t}get value(){return this.refControl?Number(this.refControl.value):void 0}},y(r,"valueProperty",new j.NumProperty(j.Versions.v1_5,"value")),y(r,"placeholderProperty",new j.StringProperty(j.Versions.v1_5,"placeholder")),y(r,"minProperty",new j.NumProperty(j.Versions.v1_0,"min")),y(r,"maxProperty",new j.NumProperty(j.Versions.v1_0,"max")),r);Ac([j.property(Pc.valueProperty)],Pc.prototype,"defaultValue"),Ac([j.property(Pc.minProperty)],Pc.prototype,"min"),Ac([j.property(Pc.maxProperty)],Pc.prototype,"max"),Ac([j.property(Pc.placeholderProperty)],Pc.prototype,"placeholder");let Ec=Pc;const Mc=e=>{const{ariaLabel:t,iconProps:r,styles:n,className:i,onClick:o,...a}=e;return b.jsx(w.Button,{appearance:"transparent","aria-label":t,className:i,onClick:o,style:n,...a,children:b.jsx("img",{src:r.src,alt:t,style:{height:r.height||"100%",width:r.width||"auto"}})})},Ic={marginLeft:8};var Bc=Object.defineProperty,Lc=(e,t,r,n)=>{for(var i,o=void 0,a=e.length-1;a>=0;a--)(i=e[a])&&(o=i(t,r,o)||o);return o&&Bc(t,r,o),o};const jc=(n=class extends j.Input{constructor(){super(...arguments),y(this,"defaultValue"),y(this,"maxLength"),y(this,"isMultiline",!1),y(this,"placeholder"),y(this,"style",j.InputTextStyle.Text),y(this,"inlineAction"),y(this,"regex"),y(this,"refControl",null),y(this,"element"),y(this,"_value",this.defaultValue||""),y(this,"handleKeyDown",e=>{var t;"Enter"===e.key&&this.inlineAction&&(null==(t=this.inlineAction)||t.execute())}),y(this,"buildInlineActionButton",()=>{var e;return yc((null==(e=this.inlineAction)?void 0:e.iconUrl)?this.inlineIconActionButton:this.buildTextOnlyInlineActionActionButton)}),y(this,"inlineActionClickHandler",e=>{var t;e.stopPropagation(),e.preventDefault(),null==(t=this.inlineAction)||t.execute()}),y(this,"inlineIconActionButton",()=>{var e,t;const r=this.hostConfig.hostCapabilities.getCustomProperty(ho);return b.jsx(w.FluentProvider,{theme:r,children:b.jsx(Mc,{ariaLabel:(null==(e=this.inlineAction)?void 0:e.title)||"Inline action",className:this.hostConfig.makeCssClassName("ac-inlineActionButton","iconOnly"),iconProps:{src:(null==(t=this.inlineAction)?void 0:t.iconUrl)??""},onClick:this.inlineActionClickHandler,styles:Ic})})}),y(this,"buildTextOnlyInlineActionActionButton",()=>{var e;const t=this.hostConfig.hostCapabilities.getCustomProperty(ho);return b.jsx(w.IdPrefixProvider,{value:j.generateUniqueId(),children:b.jsx(w.FluentProvider,{theme:t,children:b.jsx(w.Button,{appearance:"primary",className:this.hostConfig.makeCssClassName("ac-inlineActionButton","textOnly"),onClick:this.inlineActionClickHandler,style:Ic,children:(null==(e=this.inlineAction)?void 0:e.title)??""})})})})}internalRender(){const e=po(this.hostConfig);return this.element=yc(()=>b.jsx(w.IdPrefixProvider,{value:j.generateUniqueId(),children:b.jsx(w.FluentProvider,{theme:e,children:this.isMultiline?b.jsx(w.Textarea,{resize:"vertical",style:{width:"100%"},id:this.id,defaultValue:this.defaultValue,placeholder:this.placeholder,maxLength:this.maxLength,onChange:(e,t)=>{this._value=t.value,this.valueChanged()},onKeyDown:this.handleKeyDown,ref:e=>{this.refControl=e}}):b.jsx(w.Input,{id:this.id,style:{width:"100%"},type:j.InputTextStyle[this.style].toLowerCase(),defaultValue:this.defaultValue,placeholder:this.placeholder,maxLength:this.maxLength,onChange:(e,t)=>{this._value=t.value,this.valueChanged()},onKeyDown:this.handleKeyDown,ref:e=>{this.refControl=e?e.inputElement:null}})})})),this.element.style.width="100%",this.element}overrideInternalRender(){const e=super.overrideInternalRender();return this.inlineAction&&this.inputControlContainerElement.appendChild(this.buildInlineActionButton()),e||document.createElement("div")}getJsonTypeName(){return"Input.Text"}focus(){var e;null==(e=this.refControl)||e.focus()}updateInputControlAriaLabelledBy(){if(this.element){const e=this.getAllLabelIds().join(" ");e?this.element.setAttribute("aria-labelledby",e):this.element.removeAttribute("aria-labelledby")}}getActionById(e){let t=super.getActionById(e);if(!t&&this.inlineAction&&(t=this.inlineAction.getActionById(e)),!t)throw new Error(`Action with id '${e}' not found.`);return t}isSet(){return!!this.value}isValid(){return this.value?!this.regex||new RegExp(this.regex,"g").test(this.value):!this.isRequired}get value(){if(this._value)return this._value}},y(n,"valueProperty",new j.StringProperty(j.Versions.v1_0,"value")),y(n,"maxLengthProperty",new j.NumProperty(j.Versions.v1_0,"maxLength")),y(n,"isMultilineProperty",new j.BoolProperty(j.Versions.v1_0,"isMultiline",!1)),y(n,"placeholderProperty",new j.StringProperty(j.Versions.v1_0,"placeholder")),y(n,"styleProperty",new j.EnumProperty(j.Versions.v1_0,"style",j.InputTextStyle,j.InputTextStyle.Text)),y(n,"inlineActionProperty",new j.ActionProperty(j.Versions.v1_0,"inlineAction",["Action.ShowCard"])),y(n,"regexProperty",new j.StringProperty(j.Versions.v1_3,"regex",!0)),n);Lc([j.property(jc.valueProperty)],jc.prototype,"defaultValue"),Lc([j.property(jc.maxLengthProperty)],jc.prototype,"maxLength"),Lc([j.property(jc.isMultilineProperty)],jc.prototype,"isMultiline"),Lc([j.property(jc.placeholderProperty)],jc.prototype,"placeholder"),Lc([j.property(jc.styleProperty)],jc.prototype,"style"),Lc([j.property(jc.inlineActionProperty)],jc.prototype,"inlineAction"),Lc([j.property(jc.regexProperty)],jc.prototype,"regex");let Nc=jc;var Dc=Object.defineProperty,Oc=(e,t,r,n)=>{for(var i,o=void 0,a=e.length-1;a>=0;a--)(i=e[a])&&(o=i(t,r,o)||o);return o&&Dc(t,r,o),o};const Fc=e=>{const{id:t,defaultTime:r,minTime:n,maxTime:i,placeholder:o,theme:a,onTimeChange:s}=e,[l,c]=q.useState(r),[u,h]=q.useState(r?F.formatDateToTimeString(r??new Date):"");return b.jsx(w.IdPrefixProvider,{value:t,children:b.jsx(w.FluentProvider,{theme:a,children:b.jsx(F.TimePicker,{style:{width:"100%"},expandIcon:b.jsx(P.ClockRegular,{}),id:t,freeform:!0,min:n?F.formatDateToTimeString(n):void 0,max:i?F.formatDateToTimeString(i):void 0,placeholder:o,value:l?F.formatDateToTimeString(l):u,onTimeChange:(e,t)=>{const r=t.selectedTime??void 0,n=t.selectedTimeText??"";c(r),h(n),s&&r&&s(r,n)},onInput:e=>{h(e.target.value)}})})})},Rc=(i=class extends j.Input{constructor(){super(...arguments),y(this,"defaultValue"),y(this,"min"),y(this,"max"),y(this,"placeholder"),y(this,"_time"),y(this,"element")}static convertTimeStringToDate(e){return new Date("1973-09-04T"+e+":00Z")}internalRender(){const e=po(this.hostConfig),t=this.defaultValue?i.convertTimeStringToDate(this.defaultValue):void 0,r=this.min?i.convertTimeStringToDate(this.min):void 0,n=this.max?i.convertTimeStringToDate(this.max):void 0;return this.element=yc(()=>b.jsx(Fc,{id:j.generateUniqueId(),defaultTime:t,minTime:r,maxTime:n,placeholder:this.placeholder,theme:e,onTimeChange:e=>{this._time=e,this.valueChanged()}})),this.element.style.width="100%",this.element}getJsonTypeName(){return"Input.Time"}focus(){}updateInputControlAriaLabelledBy(){if(this.element){const e=this.getAllLabelIds().join(" ");e?this.element.setAttribute("aria-labelledby",e):this.element.removeAttribute("aria-labelledby")}}isSet(){return!!this.value}isValid(){if(!this.value)return!this.isRequired;if(!this._time)return!1;let e=!0;if(this.min){const t=i.convertTimeStringToDate(this.min);e=e&&this._time>=t}if(this.max){const t=i.convertTimeStringToDate(this.max);e=e&&this._time<=t}return e}get value(){return this._time?F.formatDateToTimeString(this._time):void 0}},y(i,"valueProperty",new j.TimeProperty(j.Versions.v1_0,"value")),y(i,"placeholderProperty",new j.StringProperty(j.Versions.v1_0,"placeholder")),y(i,"minProperty",new j.TimeProperty(j.Versions.v1_0,"min")),y(i,"maxProperty",new j.TimeProperty(j.Versions.v1_0,"max")),i);Oc([j.property(Rc.valueProperty)],Rc.prototype,"defaultValue"),Oc([j.property(Rc.minProperty)],Rc.prototype,"min"),Oc([j.property(Rc.maxProperty)],Rc.prototype,"max"),Oc([j.property(Rc.placeholderProperty)],Rc.prototype,"placeholder");let $c=Rc;var zc=Object.defineProperty,Vc=(e,t,r,n)=>{for(var i,o=void 0,a=e.length-1;a>=0;a--)(i=e[a])&&(o=i(t,r,o)||o);return o&&zc(t,r,o),o};const Wc=(o=class extends j.Input{constructor(){super(...arguments),y(this,"defaultValue"),y(this,"title"),y(this,"valueOn","true"),y(this,"valueOff","false"),y(this,"wrap",!1),y(this,"_value"),y(this,"refControl",null),y(this,"element")}internalRender(){const e=po(this.hostConfig);return this.element=yc(()=>b.jsx(w.IdPrefixProvider,{value:j.generateUniqueId(),children:b.jsx(w.FluentProvider,{theme:e,style:{backgroundColor:"transparent"},children:b.jsx(w.Switch,{id:this.id,label:this.title,onChange:(e,t)=>{this._value=t.checked,this.valueChanged()},defaultChecked:this.defaultValue===this.valueOn,style:{marginBottom:0,marginTop:0},ref:e=>{this.refControl=e}})})})),this.element.style.width="100%",this.element}get isNullable(){return!1}getJsonTypeName(){return"Input.Toggle"}focus(){var e;null==(e=this.refControl)||e.focus()}updateInputControlAriaLabelledBy(){if(this.element){const e=this.getAllLabelIds().join(" ");e?this.element.setAttribute("aria-labelledby",e):this.element.removeAttribute("aria-labelledby")}}isSet(){return this.isRequired?this.value===this.valueOn:!!this.value}get value(){return null!==this._value&&void 0!==this._value?this._value?this.valueOn:this.valueOff:this.isRequired?void 0:this.valueOff}},y(o,"valueProperty",new j.StringProperty(j.Versions.v1_5,"value")),y(o,"titleProperty",new j.StringProperty(j.Versions.v1_5,"title")),y(o,"valueOnProperty",new j.StringProperty(j.Versions.v1_5,"valueOn",!0,void 0,"true",e=>"true")),y(o,"valueOffProperty",new j.StringProperty(j.Versions.v1_5,"valueOff",!0,void 0,"false",e=>"false")),y(o,"wrapProperty",new j.BoolProperty(j.Versions.v1_2,"wrap",!1)),o);Vc([j.property(Wc.valueProperty)],Wc.prototype,"defaultValue"),Vc([j.property(Wc.titleProperty)],Wc.prototype,"title"),Vc([j.property(Wc.valueOnProperty)],Wc.prototype,"valueOn"),Vc([j.property(Wc.valueOffProperty)],Wc.prototype,"valueOff"),Vc([j.property(Wc.wrapProperty)],Wc.prototype,"wrap");let Hc=Wc;const qc=e=>{switch(e){case co.SharePoint:return w.webLightTheme;case co.Teams:return w.teamsLightTheme;case co.TeamsDark:return w.teamsDarkTheme;case co.TeamsHighContrast:return w.teamsHighContrastTheme;default:return w.webLightTheme}},Uc=e=>{const t=v.useRef(null),{log:r,error:n,LogLevel:i}=Q(),o=v.useRef(null),a=v.useRef(null),s=v.useRef(null);v.useEffect(()=>{var e;e=(e,t)=>n(e,t),j.AdaptiveCard.onProcessMarkdown||(j.AdaptiveCard.onProcessMarkdown=(t,r)=>{r.outputHtml=(new X.default).render(t),r.didProcess=!0;try{r.outputHtml=(new X.default).render(t),r.didProcess=!0}catch(n){e&&e("AdaptiveCardHost: Error parsing Markdown",n instanceof Error?n:void 0),r.didProcess=!1}})},[]),v.useEffect(()=>{o.current=null,o.current=new j.AdaptiveCard,a.current=new j.SerializationContext},[e]);const l=v.useCallback(t=>{if(e.onInvokeAction){let r={type:"",title:""};const n=t.getJsonTypeName();switch(n){case j.OpenUrlAction.JsonTypeName:{const e=t;r={type:n,title:e.title,url:e.url}}break;case j.SubmitAction.JsonTypeName:{const e=t;r={type:n,title:e.title,data:e.data}}break;case j.ExecuteAction.JsonTypeName:{const e=t;r={type:n,title:e.title,data:e.data,verb:e.verb}}break;default:r={type:n,title:"Unknown Action"}}e.onInvokeAction(r)}},[e.onInvokeAction]);return v.useEffect(()=>{let t,n=e.themeType;s.current=null,n||(n=co.SharePoint),t=e.theme?e.theme:qc(n);const a=fo(n,t),l=a.hostConfig;r("hostconfig:",i.Info,l),s.current=t,o.current&&(o.current.hostConfig=a.hostConfig),e.onUpdateHostCapabilities&&e.onUpdateHostCapabilities(l.hostCapabilities)},[e]),v.useEffect(()=>{o.current&&(o.current.onExecuteAction=l)},[e,l]),v.useEffect(()=>{const t=new j.CardObjectRegistry,r=new j.CardObjectRegistry;var n;j.GlobalRegistry.populateWithDefaultElements(t),j.GlobalRegistry.populateWithDefaultActions(r),(n=t).register("Input.Text",Nc),n.register("Input.Number",Ec),n.register("Input.Time",$c),n.register("Input.Date",_c),n.register("Input.Toggle",Hc),n.register("Input.ChoiceSet",Cc),function(e){e.register("Action.Submit",gc),e.register("Action.OpenUrl",pc),e.register("Action.ShowCard",fc),e.register("Action.ToggleVisibility",mc),e.register("Action.Execute",dc)}(r),e.onSetCustomElements&&e.onSetCustomElements(t),e.onSetCustomActions&&e.onSetCustomActions(r);const i=a.current;i&&i.setElementRegistry(t),i&&i.setActionRegistry(r)},[e]),v.useEffect(()=>{for(var r;null==(r=null==t?void 0:t.current)?void 0:r.firstChild;)t.current.lastChild&&t.current.removeChild(t.current.lastChild);const n=t.current;if(!n)return;const i=o.current;try{const t=new R.Template(e.card),r=((e,t,r)=>{var n,i,o,a,s,l,c;let u,h;return h=r?{theme:t,aadInfo:(null==(n=null==r?void 0:r.pageContext)?void 0:n.aadInfo)?{instanceUrl:r.pageContext.aadInfo.instanceUrl||"",tenantId:r.pageContext.aadInfo.tenantId||"",userId:r.pageContext.aadInfo.userId||""}:void 0,cultureInfo:(null==(i=null==r?void 0:r.pageContext)?void 0:i.cultureInfo)?{currentCultureName:r.pageContext.cultureInfo.currentCultureName,currentUICultureName:r.pageContext.cultureInfo.currentUICultureName,isRightToLeft:r.pageContext.cultureInfo.isRightToLeft||!1}:void 0,userInfo:(null==(o=null==r?void 0:r.pageContext)?void 0:o.user)?{displayName:r.pageContext.user.displayName,email:r.pageContext.user.email,isAnonymousGuestUser:r.pageContext.user.isAnonymousGuestUser||!1,isExternalGuestUser:r.pageContext.user.isExternalGuestUser||!1,loginName:r.pageContext.user.loginName,preferUserTimeZone:r.pageContext.user.preferUserTimeZone||!1}:void 0,spListInfo:(null==(a=null==r?void 0:r.pageContext)?void 0:a.list)?{id:r.pageContext.list.id,serverRelativeUrl:r.pageContext.list.serverRelativeUrl||"",title:r.pageContext.list.title}:void 0,spListItemInfo:(null==(s=null==r?void 0:r.pageContext)?void 0:s.listItem)?{id:r.pageContext.listItem.id.toString()}:void 0,spSiteInfo:(null==(l=null==r?void 0:r.pageContext)?void 0:l.site)?{absoluteUrl:r.pageContext.site.absoluteUrl,cdnPrefix:r.pageContext.site.cdnPrefix||"",classification:r.pageContext.site.classification||"",correlationId:r.pageContext.site.correlationId||"",id:r.pageContext.site.id,isNoScriptEnabled:r.pageContext.site.isNoScriptEnabled||!1,recycleBinItemCount:r.pageContext.site.recycleBinItemCount||0,serverRelativeUrl:r.pageContext.site.serverRelativeUrl||"",serverRequestPath:r.pageContext.site.serverRequestPath||"",sitePagesEnabled:r.pageContext.site.sitePagesEnabled||!1}:void 0,spWebInfo:(null==(c=null==r?void 0:r.pageContext)?void 0:c.web)?{absoluteUrl:r.pageContext.web.absoluteUrl,id:r.pageContext.web.id,isAppWeb:r.pageContext.web.isAppWeb||!1,language:r.pageContext.web.language||0,languageName:r.pageContext.web.languageName||"",logoUrl:r.pageContext.web.logoUrl||"",serverRelativeUrl:r.pageContext.web.serverRelativeUrl||"",templateName:r.pageContext.web.templateName||"",title:r.pageContext.web.title,description:r.pageContext.web.description||""}:void 0}:{theme:t},u=e?{$root:{...null==e?void 0:e.$root,"@context":h}}:{$root:{"@context":h}},u})(e.data??{$root:{}},qc(e.themeType??co.SharePoint),e.context),o=t.expand(r);if(i&&i.parse(o,a.current??void 0),i){const e=i.render();e&&e.outerHTML!==n.innerHTML&&e.outerHTML!==n.innerHTML&&(n.innerHTML="",n.appendChild(e))}}catch(s){e.onError&&e.onError(s)}},[e,qc]),b.jsx(w.IdPrefixProvider,{value:"adaptiveCardHost",children:b.jsx(w.FluentProvider,{theme:s.current?s.current:qc(e.themeType??co.SharePoint),children:b.jsx("div",{ref:t,className:`${e.className?e.className:""}`,style:e.style})})})},Gc=ai`
|
|
70
|
+
position: relative;
|
|
71
|
+
display: inline-block;
|
|
72
|
+
line-height: 0;
|
|
73
|
+
|
|
74
|
+
`,Xc=ai`
|
|
75
|
+
display: block;
|
|
76
|
+
`,Jc=ai`
|
|
77
|
+
position: absolute;
|
|
78
|
+
top: -1px;
|
|
79
|
+
right: -6px;
|
|
80
|
+
font-size: 8px;
|
|
81
|
+
font-weight: 700;
|
|
82
|
+
font-family: ${w.tokens.fontFamilyBase};
|
|
83
|
+
color: ${w.tokens.colorNeutralForegroundOnBrand};
|
|
84
|
+
background: ${w.tokens.colorBrandBackground};
|
|
85
|
+
padding: 1px 3px;
|
|
86
|
+
border-radius: ${w.tokens.borderRadiusSmall};
|
|
87
|
+
line-height: 1;
|
|
88
|
+
letter-spacing: 0.2px;
|
|
89
|
+
text-transform: uppercase;
|
|
90
|
+
box-shadow: ${w.tokens.shadow4};
|
|
91
|
+
border: 1px solid ${w.tokens.colorTransparentStroke};
|
|
92
|
+
transform: scale(0.9);
|
|
93
|
+
transition: all 0.2s ease;
|
|
94
|
+
|
|
95
|
+
&:hover {
|
|
96
|
+
transform: scale(1);
|
|
97
|
+
box-shadow: ${w.tokens.shadow8};
|
|
98
|
+
background: ${w.tokens.colorBrandBackgroundHover};
|
|
99
|
+
}
|
|
100
|
+
`,Yc=ai`
|
|
101
|
+
${Jc};
|
|
102
|
+
font-size: 9px;
|
|
103
|
+
padding: 2px 4px;
|
|
104
|
+
border-radius: 8px;
|
|
105
|
+
top: -2px;
|
|
106
|
+
right: -7px;
|
|
107
|
+
`,Zc=ai`
|
|
108
|
+
${Jc};
|
|
109
|
+
font-size: 6px;
|
|
110
|
+
padding: 1px 2px;
|
|
111
|
+
border-radius: 4px;
|
|
112
|
+
top: 0px;
|
|
113
|
+
right: -4px;
|
|
114
|
+
letter-spacing: 0.1px;
|
|
115
|
+
`,Kc=({size:e=20,className:t,color:r,aiIndicatorColor:n})=>{const i=ai`
|
|
116
|
+
${e>=24?Yc:e<=16?Zc:Jc};
|
|
117
|
+
${n?`\n background: ${n};\n border-color: ${n};\n `:""}
|
|
118
|
+
`,o=ai`
|
|
119
|
+
${Xc};
|
|
120
|
+
font-size: ${e}px;
|
|
121
|
+
${r?`color: ${r};`:"color: inherit;"}
|
|
122
|
+
`;return ii("span",{css:[Gc,t&&ai`${t}`],children:[ni(P.SearchRegular,{css:o}),ni("span",{css:i,children:"AI"})]})},Qc=w.makeStyles({container:{display:"flex",flexDirection:"column",gap:"20px",padding:"20px"},section:{display:"flex",flexDirection:"column",gap:"10px"},iconRow:{display:"flex",alignItems:"center",gap:"15px",padding:"10px",border:`1px solid ${w.tokens.colorNeutralStroke2}`,borderRadius:"8px"},label:{minWidth:"150px",fontWeight:600},buttonExample:{display:"flex",alignItems:"center",gap:"8px"},codeBlock:{background:w.tokens.colorNeutralBackground2,padding:"10px",borderRadius:"4px",fontSize:"12px",overflow:"auto",border:`1px solid ${w.tokens.colorNeutralStroke2}`}}),eu=q.forwardRef(({value:e,onChange:t,onSend:r,placeholder:n,isRunning:i,onAbort:o},a)=>{const s={container:T.css({backgroundColor:w.tokens.colorNeutralBackground1,border:"1px solid "+w.tokens.colorNeutralStroke1,borderRadius:w.tokens.borderRadiusLarge,padding:`${w.tokens.spacingVerticalXS} ${w.tokens.spacingHorizontalS}`,minHeight:"40px",":focus-within::after":{borderBottom:`2px solid ${w.tokens.colorBrandStroke1}`}}),textarea:T.css({width:"calc(100% - 5px)",flex:1,border:"none",outline:"none",backgroundColor:"transparent",fontSize:w.tokens.fontSizeBase300,color:w.tokens.colorNeutralForeground1,resize:"none","::placeholder":{color:w.tokens.colorNeutralForegroundDisabled},"::-webkit-scrollbar":{width:"5px",height:"5px"},"::-webkit-scrollbar-track":{background:w.tokens.colorNeutralBackground4,borderRadius:"10px"},"::-webkit-scrollbar-thumb":{background:w.tokens.colorBrandStroke2Hover,borderRadius:"10px"},"::-webkit-scrollbar-thumb:hover":{background:w.tokens.colorNeutralStroke2}}),iconContainer:T.css({display:"flex",alignItems:"center",gap:w.tokens.spacingHorizontalXS,marginLeft:w.tokens.spacingHorizontalXS}),buttonSend:T.css({width:"36px !important",height:"36px !important",maxWidth:"36px !important",maxHeight:"36px !important",minWidth:"36px !important",minHeight:"36px !important"})},l=x.useAIAssistantStrings(),c=n||l.typeAMessage,u=q.useCallback(()=>{const t=e.trim();t.length>0&&r(t)},[e,r]);return b.jsxs(ft,{width:"100%",className:s.container,children:[b.jsx("textarea",{ref:a,className:s.textarea,placeholder:c,value:e,onChange:e=>t(e.target.value),onKeyDown:e=>{"Enter"!==e.key||e.shiftKey||(e.preventDefault(),u())},rows:3}),b.jsx(ft,{horizontal:!0,horizontalAlign:"end",width:"100%",children:i?b.jsx(Bt,{icon:b.jsx(P.RecordStopRegular,{}),hoverIcon:b.jsx(P.RecordStopFilled,{}),width:32,height:32,onClick:o}):b.jsx(Bt,{icon:b.jsx(P.ArrowCircleUp32Regular,{}),hoverIcon:b.jsx(P.ArrowCircleUp32Filled,{}),width:32,height:32,onClick:u,enabled:e.trim().length>0})})]})}),tu=()=>({listContainer:T.css({display:"grid",gridTemplateColumns:"1fr",gap:w.tokens.spacingVerticalXXS,maxHeight:"400px",overflowY:"auto",overflowX:"hidden",padding:w.tokens.spacingVerticalS,minWidth:"280px","::-webkit-scrollbar":{width:"5px",height:"5px"},"::-webkit-scrollbar-track":{background:w.tokens.colorNeutralBackground4,borderRadius:"10px"},"::-webkit-scrollbar-thumb":{background:w.tokens.colorBrandStroke2Hover,borderRadius:"10px"},"::-webkit-scrollbar-thumb:hover":{background:w.tokens.colorNeutralStroke2}}),suggestionsHeader:T.css({color:w.tokens.colorBrandBackground,padding:w.tokens.spacingVerticalXS}),noResults:T.css({padding:w.tokens.spacingVerticalS,textAlign:"center",color:w.tokens.colorNeutralForeground3})}),ru=({context:e,inputValue:t,parentRef:r,mentionChars:n,onUserSelect:i,theme:o,suggestionsHeader:a,maxSuggestions:s=100,userFilter:l})=>{var c,u;const h=K(),d=e||h,p=null==d?void 0:d.graphClient,f=(null==(u=null==(c=null==d?void 0:d.pageContext)?void 0:c.web)?void 0:u.absoluteUrl)||"",g=x.useMensionsStrings(),m=x.useUserCardStrings(),{verbose:y,warn:C,error:k}=Q(),[S,_]=v.useState(!1),[T,A]=v.useState({top:0,left:0}),[P,E]=v.useState([]),[M,I]=v.useState(""),[B,L]=v.useState(""),j=v.useRef({}),N=tu(),D=v.useCallback(async e=>{if(!p)return C("Graph client not available"),[];const t=`${e}_${s}`;if(j.current[t])return j.current[t];try{const r=e&&e.length>0?`startswith(displayName,'${e}') or startswith(givenName,'${e}') or startswith(surname,'${e}')`:"",n=r?`/users?$filter=${r}&$select=id,displayName,mail,userPrincipalName&$top=${s}`:`/users?$select=id,displayName,mail,userPrincipalName&$orderby=displayName&$top=${s}`;y("[fetchUsers]: API query:",n);const i=await p.get(n);y("[fetchUsers]: Graph response:",i);const o=(i.value||[]).map(e=>({id:e.id||"",displayName:e.displayName||e.userPrincipalName||m.unknownUser,mail:e.mail||e.userPrincipalName||"",avatar:f?`${f}/_layouts/15/userphoto.aspx?size=S&accountname=${e.mail||e.userPrincipalName}`:void 0})).filter(e=>e.id&&e.displayName);return y("[fetchUsers]: Processed users:",o),j.current[t]=o,o}catch(r){return k("[fetchUsers]: Error fetching users from Graph:",r instanceof Error?r:void 0),[]}},[p,f,s]),O=v.useCallback(it(async(e,t)=>{y("[debouncedFetch]: Fetching users for query:",e);const r=await D(e),n=l?r.filter(t=>l(t,e)):r;y("[debouncedFetch]: Filtered users:",n),n.sort((e,t)=>e.displayName.localeCompare(t.displayName)),E(n),I(t),L(e),_(!0),y("[debouncedFetch]: Menu should be shown now")},300),[d,s,l,D]),F=e=>{const t=r.current;if(!t)return{top:0,left:0};if("TEXTAREA"===t.tagName){const r=t,n=$(r,e),i=r.getBoundingClientRect();return{top:i.top+n.top+22,left:i.left+n.left+16}}const n=t.getBoundingClientRect();return{top:n.bottom+5,left:n.left}};v.useEffect(()=>{if(!t)return void _(!1);y("[Mensions]: Analyzing input:",t);let e=!1;for(const r of n){const n=t.lastIndexOf(r);if(y("[Mensions]: Checking mention char:",r),-1!==n&&(0===n||" "===t[n-1])){const i=t.slice(n+1);if(y("[Mensions]: Search text:",i),!i.includes(" ")){e=!0;const t=F(n);y("[Mensions]: Menu position:",t),A(t),O(i,r);break}}}e||(y("[Mensions]: No mention found, hiding menu"),_(!1))},[t,n,r,O]);const R=e=>{i(e,M),_(!1),E([])},z=v.useCallback(({users:e})=>b.jsxs("div",{className:N.listContainer,children:[0===e.length&&b.jsxs(w.Caption1,{className:N.noResults,children:[g.noResults,' "',B,'"']}),e.map(e=>b.jsx(w.Card,{appearance:"subtle",onMouseDown:e=>e.preventDefault(),onClick:()=>R(e),children:b.jsx(w.Persona,{name:e.displayName||m.unknownUser,role:"gridcell",secondaryText:e.mail||e.userPrincipalName||"",avatar:{image:{src:e.avatar}}})},e.id))]}),[N,B,R]);return b.jsxs(vt,{theme:o,anchorPoint:T,isOpen:S,onClose:()=>_(!1),excludeRefs:r?[r]:[],children:[b.jsx(w.CardHeader,{header:b.jsx(w.Body1Strong,{className:N.suggestionsHeader,children:a})}),b.jsx(w.Divider,{}),b.jsx(z,{users:P})]})},nu=()=>({inputContainer:T.css({marginTop:"auto",marginLeft:"auto","::after":{content:'""',position:"absolute",bottom:0,left:0,right:0,borderBottom:"2px solid transparent",pointerEvents:"none",borderRadius:w.tokens.borderRadiusMedium}}),listContainer:T.css({maxHeight:"400px",overflowY:"auto",overflowX:"hidden","::-webkit-scrollbar":{width:"5px",height:"5px"},"::-webkit-scrollbar-track":{background:w.tokens.colorNeutralBackground4,borderRadius:"10px"},"::-webkit-scrollbar-thumb":{background:w.tokens.colorBrandStroke2Hover,borderRadius:"10px"},"::-webkit-scrollbar-thumb:hover":{background:w.tokens.colorNeutralStroke2}}),sugestionsHeader:T.css({color:w.tokens.colorBrandBackground})}),iu=({context:e,onChange:t,value:r,placeholder:n,onSend:i,theme:o=w.webLightTheme,isRunning:a,onAbort:s})=>{const[l,c]=v.useState(r||""),u=v.useRef(null),h=nu();v.useEffect(()=>{var e;null==(e=u.current)||e.focus(),c(r||"")},[r]);return b.jsxs(ft,{horizontal:!0,width:"100%",className:h.inputContainer,children:[b.jsx(eu,{ref:u,onSend:i,value:l,onChange:e=>{c(e),t&&t(e)},theme:o,placeholder:n,isRunning:a,onAbort:s}),b.jsx(ru,{context:e,inputValue:l,parentRef:u,mentionChars:["@"],onUserSelect:(e,r)=>{const n=new RegExp(`${r.replace(/[.*+?^${}()|[\]\\]/g,"\\$&")}(\\w*)$`),i=l.replace(n,`${r}${e.mail} `);c(i),t&&t(i),setTimeout(()=>{var e;null==(e=u.current)||e.focus()},0)},theme:o,suggestionsHeader:"Suggestions",maxSuggestions:10})]})},ou=()=>{const e=(()=>{const e=w.tokens.colorBrandBackground,t=T.keyframes`
|
|
123
|
+
0%, 80%, 100% {
|
|
124
|
+
opacity: 0;
|
|
125
|
+
transform: scale(0.8);
|
|
126
|
+
}
|
|
127
|
+
40% {
|
|
128
|
+
opacity: 1;
|
|
129
|
+
transform: scale(1);
|
|
130
|
+
}
|
|
131
|
+
`;return{root:T.css`
|
|
132
|
+
display: flex;
|
|
133
|
+
align-items: start;
|
|
134
|
+
justify-content: start;
|
|
135
|
+
height: fit-content;
|
|
136
|
+
padding: 5px 0;
|
|
137
|
+
`,dot:T.css`
|
|
138
|
+
width: 8px;
|
|
139
|
+
height: 8px;
|
|
140
|
+
margin: 0 4px;
|
|
141
|
+
background-color: ${e};
|
|
142
|
+
border-radius: 50%;
|
|
143
|
+
animation: ${t} 1.4s infinite ease-in-out both;
|
|
144
|
+
`,dot1:T.css`
|
|
145
|
+
animation-delay: 0s;
|
|
146
|
+
`,dot2:T.css`
|
|
147
|
+
animation-delay: 0.2s;
|
|
148
|
+
`,dot3:T.css`
|
|
149
|
+
animation-delay: 0.4s;
|
|
150
|
+
`}})();return b.jsxs("div",{className:e.root,children:[b.jsx("div",{className:`${e.dot} ${e.dot1}`}),b.jsx("div",{className:`${e.dot} ${e.dot2}`}),b.jsx("div",{className:`${e.dot} ${e.dot3}`})]})},au=(e,t)=>{switch(t.type){case"INIT":return{...e,messages:[t.welcomeMessage],isLoading:!1};case"SET_INPUT":return{...e,inputText:t.inputText};case"ADD_USER_MESSAGE":case"ADD_ASSISTANT_MESSAGE":return{...e,messages:[...e.messages,t.message]};case"UPDATE_LAST_ASSISTANT_MESSAGE":{const r=[...e.messages],n=r.length-1;return n>=0&&"Assistant"===r[n].senderName&&(r[n]=t.message),{...e,messages:r}}case"SET_ERROR":return{...e,error:t.error};case"CLEAR_INPUT":return{...e,inputText:""};case"SET_IS_RUNNING":return{...e,isRunning:!e.isRunning};default:return e}},su=({content:e,className:t})=>{const r={markdown:T.css({fontFamily:w.tokens.fontFamilyBase,fontSize:w.tokens.fontSizeBase300,lineHeight:w.tokens.lineHeightBase300,color:w.tokens.colorNeutralForeground1,"& p":{marginTop:"0",marginBottom:w.tokens.spacingVerticalM},"& h1, & h2, & h3, & h4, & h5, & h6":{marginTop:w.tokens.spacingVerticalL,marginBottom:w.tokens.spacingVerticalM,fontWeight:w.tokens.fontWeightSemibold},"& h1":{fontSize:w.tokens.fontSizeBase500},"& h2":{fontSize:w.tokens.fontSizeBase400},"& h3":{fontSize:w.tokens.fontSizeBase300},"& ul, & ol":{marginTop:"0",marginBottom:w.tokens.spacingVerticalM,paddingLeft:w.tokens.spacingHorizontalXXL},"& li":{marginBottom:w.tokens.spacingVerticalXS},"& code":{fontFamily:w.tokens.fontFamilyMonospace,fontSize:w.tokens.fontSizeBase200,backgroundColor:w.tokens.colorNeutralBackground3,padding:"2px 4px",borderRadius:w.tokens.borderRadiusSmall},"& pre":{backgroundColor:w.tokens.colorNeutralBackground3,padding:w.tokens.spacingVerticalM,borderRadius:w.tokens.borderRadiusMedium,overflowX:"auto",marginBottom:w.tokens.spacingVerticalM},"& pre code":{backgroundColor:"transparent",padding:"0"},"& table":{borderCollapse:"collapse",width:"100%",marginBottom:w.tokens.spacingVerticalM,border:`1px solid ${w.tokens.colorNeutralStroke1}`},"& thead":{backgroundColor:w.tokens.colorNeutralBackground3},"& th":{padding:w.tokens.spacingVerticalS+" "+w.tokens.spacingHorizontalM,textAlign:"left",fontWeight:w.tokens.fontWeightSemibold,borderBottom:`2px solid ${w.tokens.colorNeutralStroke1}`,borderRight:`1px solid ${w.tokens.colorNeutralStroke2}`},"& td":{padding:w.tokens.spacingVerticalS+" "+w.tokens.spacingHorizontalM,borderBottom:`1px solid ${w.tokens.colorNeutralStroke2}`,borderRight:`1px solid ${w.tokens.colorNeutralStroke2}`},"& tr:last-child td":{borderBottom:"none"},"& th:last-child, & td:last-child":{borderRight:"none"},"& blockquote":{borderLeft:`4px solid ${w.tokens.colorBrandStroke1}`,paddingLeft:w.tokens.spacingHorizontalM,marginLeft:"0",marginBottom:w.tokens.spacingVerticalM,color:w.tokens.colorNeutralForeground2},"& a":{color:w.tokens.colorBrandForeground1,textDecoration:"none",":hover":{textDecoration:"underline"}},"& hr":{border:"none",borderTop:`1px solid ${w.tokens.colorNeutralStroke2}`,marginTop:w.tokens.spacingVerticalL,marginBottom:w.tokens.spacingVerticalL}})},[n,i]=q.useState("");return q.useEffect(()=>{const t=new D({html:!1,linkify:!0,typographer:!0,breaks:!0}).render(e);i(t)},[e]),b.jsx("div",{className:`${r.markdown} ${t||""}`,dangerouslySetInnerHTML:{__html:n}})},lu=w.makeStyles({plainText:{fontFamily:w.tokens.fontFamilyBase,fontSize:w.tokens.fontSizeBase300,lineHeight:w.tokens.lineHeightBase300,color:w.tokens.colorNeutralForeground1,whiteSpace:"pre-wrap",wordBreak:"break-word"},htmlContent:{fontFamily:w.tokens.fontFamilyBase,fontSize:w.tokens.fontSizeBase300,lineHeight:w.tokens.lineHeightBase300,color:w.tokens.colorNeutralForeground1,"& p":{marginTop:"0",marginBottom:w.tokens.spacingVerticalM},"& h1, & h2, & h3, & h4, & h5, & h6":{marginTop:w.tokens.spacingVerticalL,marginBottom:w.tokens.spacingVerticalM,fontWeight:w.tokens.fontWeightSemibold},"& table":{borderCollapse:"collapse",width:"100%",marginBottom:w.tokens.spacingVerticalM},"& th, & td":{border:`1px solid ${w.tokens.colorNeutralStroke1}`,padding:w.tokens.spacingHorizontalS,textAlign:"left"},"& th":{backgroundColor:w.tokens.colorNeutralBackground3,fontWeight:w.tokens.fontWeightSemibold}},debugBadge:{display:"inline-block",padding:`${w.tokens.spacingVerticalXS} ${w.tokens.spacingHorizontalS}`,marginBottom:w.tokens.spacingVerticalS,backgroundColor:w.tokens.colorNeutralBackground3,borderRadius:w.tokens.borderRadiusSmall,fontSize:w.tokens.fontSizeBase200,fontFamily:w.tokens.fontFamilyMonospace,color:w.tokens.colorNeutralForeground2},adaptiveCardWrapper:{width:"100%"}}),cu=({content:e,forceType:t,onTypeDetected:r,context:n,theme:i=co.SharePoint,fluentTheme:o,onAdaptiveCardAction:a,className:s,debug:l=!1})=>{const c=lu(),{error:u}=Q(),[h,d]=q.useState(null);if(q.useEffect(()=>{if(q.isValidElement(e))return;if("string"!=typeof e&&"object"!=typeof e)return;const t=st(e);d(t),r&&r(t)},[e,r]),q.isValidElement(e))return b.jsx(b.Fragment,{children:e});const p=t||(null==h?void 0:h.type),f=(null==h?void 0:h.content)||e;return b.jsxs(b.Fragment,{children:[l&&h?b.jsxs("div",{className:c.debugBadge,children:["Type: ",h.type," | Confidence: ",(100*h.confidence).toFixed(0),"%"]}):null,(()=>{switch(p){case ot.MARKDOWN:return b.jsx(su,{content:f,className:s});case ot.HTML:return b.jsx("div",{className:`${c.htmlContent} ${s||""}`,dangerouslySetInnerHTML:{__html:f}});case ot.ADAPTIVE_CARD:return b.jsx("div",{className:`${c.adaptiveCardWrapper} ${s||""}`,children:b.jsx(Uc,{card:"string"==typeof f?JSON.parse(f):f,context:n,theme:o,themeType:i,onInvokeAction:a||(()=>{}),onError:e=>u("Adaptive Card Error:",e instanceof Error?e:void 0)})});case ot.PLAIN_TEXT:default:return b.jsx("div",{className:`${c.plainText} ${s||""}`,children:f})}})()]})},uu=q.forwardRef((e,t)=>{const{messages:r,context:n}=e,i=e=>{if(q.isValidElement(e))return e;if("string"==typeof e){return e.replace(/\{"status"\s*:\s*"executing"\}/gi,"").replace(/\{'status'\s*:\s*'executing'\}/gi,"").trim()}return e},o=T.css({flex:"1 1 0",overflowY:"auto",overflowX:"hidden",padding:"16px",paddingRight:"25px","::-webkit-scrollbar":{width:"6px"},"::-webkit-scrollbar-track":{background:w.tokens.colorNeutralBackground4,borderRadius:"10px"},"::-webkit-scrollbar-thumb":{background:w.tokens.colorBrandStroke2Hover,borderRadius:"10px"},"::-webkit-scrollbar-thumb:hover":{background:w.tokens.colorNeutralStroke2}}),a=T.css({display:"flex",flexDirection:"column",gap:"10px",paddingRight:"30px"});return b.jsx("div",{ref:t,className:o,children:b.jsx(z.Chat,{className:a,children:r.map((e,t)=>"User"===e.senderName?b.jsx(z.ChatMyMessage,{status:e.status,author:e.senderName,children:i(e.message)},t):b.jsx(z.ChatMessage,{decoration:"failed"===e.status?"important":void 0,avatar:b.jsx(M.Icon,{icon:"carbon:ibm-consulting-advantage-assistant",width:"32",height:"32",style:{color:w.tokens.colorBrandBackground}}),author:e.senderName,children:b.jsx(cu,{content:i(e.message),context:n})},t))})})});uu.displayName="ChatList";const hu=(e,t)=>{const{getFormatRelative:r}=rt(e,t);return r(new Date)};var du={name:"mermaid",version:"11.12.3",description:"Markdown-ish syntax for generating flowcharts, mindmaps, sequence diagrams, class diagrams, gantt charts, git graphs and more.",type:"module",module:"./dist/mermaid.core.mjs",types:"./dist/mermaid.d.ts",exports:{".":{types:"./dist/mermaid.d.ts",import:"./dist/mermaid.core.mjs",default:"./dist/mermaid.core.mjs"},"./*":"./*"},keywords:["diagram","markdown","flowchart","sequence diagram","gantt","class diagram","git graph","mindmap","packet diagram","c4 diagram","er diagram","pie chart","pie diagram","quadrant chart","requirement diagram","graph"],scripts:{clean:"rimraf dist",dev:"pnpm -w dev","docs:code":"typedoc src/defaultConfig.ts src/config.ts src/mermaid.ts && prettier --write ./src/docs/config/setup","docs:build":"rimraf ../../docs && pnpm docs:code && pnpm docs:spellcheck && tsx scripts/docs.cli.mts","docs:verify":"pnpm docs:code && pnpm docs:spellcheck && tsx scripts/docs.cli.mts --verify","docs:pre:vitepress":"pnpm --filter ./src/docs prefetch && rimraf src/vitepress && pnpm docs:code && tsx scripts/docs.cli.mts --vitepress && pnpm --filter ./src/vitepress install --no-frozen-lockfile --ignore-scripts","docs:build:vitepress":"pnpm docs:pre:vitepress && (cd src/vitepress && pnpm run build) && cpy --flat src/docs/landing/ ./src/vitepress/.vitepress/dist/landing","docs:dev":'pnpm docs:pre:vitepress && concurrently "pnpm --filter ./src/vitepress dev" "tsx scripts/docs.cli.mts --watch --vitepress"',"docs:dev:docker":'pnpm docs:pre:vitepress && concurrently "pnpm --filter ./src/vitepress dev:docker" "tsx scripts/docs.cli.mts --watch --vitepress"',"docs:serve":"pnpm docs:build:vitepress && vitepress serve src/vitepress","docs:spellcheck":'cspell "src/docs/**/*.md"',"docs:release-version":"tsx scripts/update-release-version.mts","docs:verify-version":"tsx scripts/update-release-version.mts --verify","types:build-config":"tsx scripts/create-types-from-json-schema.mts","types:verify-config":"tsx scripts/create-types-from-json-schema.mts --verify",checkCircle:"npx madge --circular ./src",prepublishOnly:"pnpm docs:verify-version"},repository:{type:"git",url:"https://github.com/mermaid-js/mermaid"},author:"Knut Sveidqvist",license:"MIT",standard:{ignore:["**/parser/*.js","dist/**/*.js","cypress/**/*.js"],globals:["page"]},dependencies:{"@braintree/sanitize-url":"^7.1.1","@iconify/utils":"^3.0.1","@mermaid-js/parser":"workspace:^","@types/d3":"^7.4.3",cytoscape:"^3.29.3","cytoscape-cose-bilkent":"^4.1.0","cytoscape-fcose":"^2.2.0",d3:"^7.9.0","d3-sankey":"^0.12.3","dagre-d3-es":"7.0.13",dayjs:"^1.11.18",dompurify:"^3.2.5",katex:"^0.16.22",khroma:"^2.1.0","lodash-es":"^4.17.23",marked:"^16.2.1",roughjs:"^4.6.6",stylis:"^4.3.6","ts-dedent":"^2.2.0",uuid:"^11.1.0"},devDependencies:{"@adobe/jsonschema2md":"^8.0.5","@iconify/types":"^2.0.0","@types/cytoscape":"^3.21.9","@types/cytoscape-fcose":"^2.2.4","@types/d3-sankey":"^0.12.4","@types/d3-scale":"^4.0.9","@types/d3-scale-chromatic":"^3.1.0","@types/d3-selection":"^3.0.11","@types/d3-shape":"^3.1.7","@types/jsdom":"^21.1.7","@types/katex":"^0.16.7","@types/lodash-es":"^4.17.12","@types/micromatch":"^4.0.9","@types/stylis":"^4.2.7","@types/uuid":"^10.0.0",ajv:"^8.17.1",canvas:"^3.1.2",chokidar:"3.6.0",concurrently:"^9.1.2","csstree-validator":"^4.0.1",globby:"^14.1.0",jison:"^0.4.18","js-base64":"^3.7.8",jsdom:"^26.1.0","json-schema-to-typescript":"^15.0.4",micromatch:"^4.0.8","path-browserify":"^1.0.1",prettier:"^3.5.3",remark:"^15.0.1","remark-frontmatter":"^5.0.0","remark-gfm":"^4.0.1",rimraf:"^6.0.1","start-server-and-test":"^2.0.13","type-fest":"^4.35.0",typedoc:"^0.28.12","typedoc-plugin-markdown":"^4.8.1",typescript:"~5.7.3","unist-util-flatmap":"^1.0.0","unist-util-visit":"^5.0.0",vitepress:"^1.6.4","vitepress-plugin-search":"1.0.4-alpha.22"},files:["dist/","README.md"],publishConfig:{access:"public"}},pu={exports:{}};const fu=Tn(pu.exports=function(){var e=1e3,t=6e4,r=36e5,n="millisecond",i="second",o="minute",a="hour",s="day",l="week",c="month",u="quarter",h="year",d="date",p="Invalid Date",f=/^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/,g=/\[([^\]]+)]|Y{1,4}|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g,m={name:"en",weekdays:"Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),months:"January_February_March_April_May_June_July_August_September_October_November_December".split("_"),ordinal:function(e){var t=["th","st","nd","rd"],r=e%100;return"["+e+(t[(r-20)%10]||t[r]||t[0])+"]"}},y=function(e,t,r){var n=String(e);return!n||n.length>=t?e:""+Array(t+1-n.length).join(r)+e},x={s:y,z:function(e){var t=-e.utcOffset(),r=Math.abs(t),n=Math.floor(r/60),i=r%60;return(t<=0?"+":"-")+y(n,2,"0")+":"+y(i,2,"0")},m:function e(t,r){if(t.date()<r.date())return-e(r,t);var n=12*(r.year()-t.year())+(r.month()-t.month()),i=t.clone().add(n,c),o=r-i<0,a=t.clone().add(n+(o?-1:1),c);return+(-(n+(r-i)/(o?i-a:a-i))||0)},a:function(e){return e<0?Math.ceil(e)||0:Math.floor(e)},p:function(e){return{M:c,y:h,w:l,d:s,D:d,h:a,m:o,s:i,ms:n,Q:u}[e]||String(e||"").toLowerCase().replace(/s$/,"")},u:function(e){return void 0===e}},b="en",v={};v[b]=m;var C="$isDayjsObject",w=function(e){return e instanceof T||!(!e||!e[C])},k=function e(t,r,n){var i;if(!t)return b;if("string"==typeof t){var o=t.toLowerCase();v[o]&&(i=o),r&&(v[o]=r,i=o);var a=t.split("-");if(!i&&a.length>1)return e(a[0])}else{var s=t.name;v[s]=t,i=s}return!n&&i&&(b=i),i||!n&&b},S=function(e,t){if(w(e))return e.clone();var r="object"==typeof t?t:{};return r.date=e,r.args=arguments,new T(r)},_=x;_.l=k,_.i=w,_.w=function(e,t){return S(e,{locale:t.$L,utc:t.$u,x:t.$x,$offset:t.$offset})};var T=function(){function m(e){this.$L=k(e.locale,null,!0),this.parse(e),this.$x=this.$x||e.x||{},this[C]=!0}var y=m.prototype;return y.parse=function(e){this.$d=function(e){var t=e.date,r=e.utc;if(null===t)return new Date(NaN);if(_.u(t))return new Date;if(t instanceof Date)return new Date(t);if("string"==typeof t&&!/Z$/i.test(t)){var n=t.match(f);if(n){var i=n[2]-1||0,o=(n[7]||"0").substring(0,3);return r?new Date(Date.UTC(n[1],i,n[3]||1,n[4]||0,n[5]||0,n[6]||0,o)):new Date(n[1],i,n[3]||1,n[4]||0,n[5]||0,n[6]||0,o)}}return new Date(t)}(e),this.init()},y.init=function(){var e=this.$d;this.$y=e.getFullYear(),this.$M=e.getMonth(),this.$D=e.getDate(),this.$W=e.getDay(),this.$H=e.getHours(),this.$m=e.getMinutes(),this.$s=e.getSeconds(),this.$ms=e.getMilliseconds()},y.$utils=function(){return _},y.isValid=function(){return!(this.$d.toString()===p)},y.isSame=function(e,t){var r=S(e);return this.startOf(t)<=r&&r<=this.endOf(t)},y.isAfter=function(e,t){return S(e)<this.startOf(t)},y.isBefore=function(e,t){return this.endOf(t)<S(e)},y.$g=function(e,t,r){return _.u(e)?this[t]:this.set(r,e)},y.unix=function(){return Math.floor(this.valueOf()/1e3)},y.valueOf=function(){return this.$d.getTime()},y.startOf=function(e,t){var r=this,n=!!_.u(t)||t,u=_.p(e),p=function(e,t){var i=_.w(r.$u?Date.UTC(r.$y,t,e):new Date(r.$y,t,e),r);return n?i:i.endOf(s)},f=function(e,t){return _.w(r.toDate()[e].apply(r.toDate("s"),(n?[0,0,0,0]:[23,59,59,999]).slice(t)),r)},g=this.$W,m=this.$M,y=this.$D,x="set"+(this.$u?"UTC":"");switch(u){case h:return n?p(1,0):p(31,11);case c:return n?p(1,m):p(0,m+1);case l:var b=this.$locale().weekStart||0,v=(g<b?g+7:g)-b;return p(n?y-v:y+(6-v),m);case s:case d:return f(x+"Hours",0);case a:return f(x+"Minutes",1);case o:return f(x+"Seconds",2);case i:return f(x+"Milliseconds",3);default:return this.clone()}},y.endOf=function(e){return this.startOf(e,!1)},y.$set=function(e,t){var r,l=_.p(e),u="set"+(this.$u?"UTC":""),p=(r={},r[s]=u+"Date",r[d]=u+"Date",r[c]=u+"Month",r[h]=u+"FullYear",r[a]=u+"Hours",r[o]=u+"Minutes",r[i]=u+"Seconds",r[n]=u+"Milliseconds",r)[l],f=l===s?this.$D+(t-this.$W):t;if(l===c||l===h){var g=this.clone().set(d,1);g.$d[p](f),g.init(),this.$d=g.set(d,Math.min(this.$D,g.daysInMonth())).$d}else p&&this.$d[p](f);return this.init(),this},y.set=function(e,t){return this.clone().$set(e,t)},y.get=function(e){return this[_.p(e)]()},y.add=function(n,u){var d,p=this;n=Number(n);var f=_.p(u),g=function(e){var t=S(p);return _.w(t.date(t.date()+Math.round(e*n)),p)};if(f===c)return this.set(c,this.$M+n);if(f===h)return this.set(h,this.$y+n);if(f===s)return g(1);if(f===l)return g(7);var m=(d={},d[o]=t,d[a]=r,d[i]=e,d)[f]||1,y=this.$d.getTime()+n*m;return _.w(y,this)},y.subtract=function(e,t){return this.add(-1*e,t)},y.format=function(e){var t=this,r=this.$locale();if(!this.isValid())return r.invalidDate||p;var n=e||"YYYY-MM-DDTHH:mm:ssZ",i=_.z(this),o=this.$H,a=this.$m,s=this.$M,l=r.weekdays,c=r.months,u=r.meridiem,h=function(e,r,i,o){return e&&(e[r]||e(t,n))||i[r].slice(0,o)},d=function(e){return _.s(o%12||12,e,"0")},f=u||function(e,t,r){var n=e<12?"AM":"PM";return r?n.toLowerCase():n};return n.replace(g,function(e,n){return n||function(e){switch(e){case"YY":return String(t.$y).slice(-2);case"YYYY":return _.s(t.$y,4,"0");case"M":return s+1;case"MM":return _.s(s+1,2,"0");case"MMM":return h(r.monthsShort,s,c,3);case"MMMM":return h(c,s);case"D":return t.$D;case"DD":return _.s(t.$D,2,"0");case"d":return String(t.$W);case"dd":return h(r.weekdaysMin,t.$W,l,2);case"ddd":return h(r.weekdaysShort,t.$W,l,3);case"dddd":return l[t.$W];case"H":return String(o);case"HH":return _.s(o,2,"0");case"h":return d(1);case"hh":return d(2);case"a":return f(o,a,!0);case"A":return f(o,a,!1);case"m":return String(a);case"mm":return _.s(a,2,"0");case"s":return String(t.$s);case"ss":return _.s(t.$s,2,"0");case"SSS":return _.s(t.$ms,3,"0");case"Z":return i}return null}(e)||i.replace(":","")})},y.utcOffset=function(){return 15*-Math.round(this.$d.getTimezoneOffset()/15)},y.diff=function(n,d,p){var f,g=this,m=_.p(d),y=S(n),x=(y.utcOffset()-this.utcOffset())*t,b=this-y,v=function(){return _.m(g,y)};switch(m){case h:f=v()/12;break;case c:f=v();break;case u:f=v()/3;break;case l:f=(b-x)/6048e5;break;case s:f=(b-x)/864e5;break;case a:f=b/r;break;case o:f=b/t;break;case i:f=b/e;break;default:f=b}return p?f:_.a(f)},y.daysInMonth=function(){return this.endOf(c).$D},y.$locale=function(){return v[this.$L]},y.locale=function(e,t){if(!e)return this.$L;var r=this.clone(),n=k(e,t,!0);return n&&(r.$L=n),r},y.clone=function(){return _.w(this.$d,this)},y.toDate=function(){return new Date(this.valueOf())},y.toJSON=function(){return this.isValid()?this.toISOString():null},y.toISOString=function(){return this.$d.toISOString()},y.toString=function(){return this.$d.toUTCString()},m}(),A=T.prototype;return S.prototype=A,[["$ms",n],["$s",i],["$m",o],["$H",a],["$W",s],["$M",c],["$y",h],["$D",d]].forEach(function(e){A[e[1]]=function(t){return this.$g(t,e[0],e[1])}}),S.extend=function(e,t){return e.$i||(e(t,T,S),e.$i=!0),S},S.locale=k,S.isDayjs=w,S.unix=function(e){return S(1e3*e)},S.en=v[b],S.Ls=v,S.p={},S}());var gu=Object.defineProperty,mu=(e,t)=>gu(e,"name",{value:t,configurable:!0}),yu=(e,t)=>{for(var r in t)gu(e,r,{get:t[r],enumerable:!0})},xu={trace:0,debug:1,info:2,warn:3,error:4,fatal:5},bu={trace:mu((...e)=>{},"trace"),debug:mu((...e)=>{},"debug"),info:mu((...e)=>{},"info"),warn:mu((...e)=>{},"warn"),error:mu((...e)=>{},"error"),fatal:mu((...e)=>{},"fatal")},vu=mu(function(e="fatal"){let t=xu.fatal;"string"==typeof e?e.toLowerCase()in xu&&(t=xu[e]):"number"==typeof e&&(t=e),bu.trace=()=>{},bu.debug=()=>{},bu.info=()=>{},bu.warn=()=>{},bu.error=()=>{},bu.fatal=()=>{},t<=xu.fatal&&(bu.fatal=console.error?console.error.bind(console,Cu("FATAL"),"color: orange"):console.log.bind(console,"[35m",Cu("FATAL"))),t<=xu.error&&(bu.error=console.error?console.error.bind(console,Cu("ERROR"),"color: orange"):console.log.bind(console,"[31m",Cu("ERROR"))),t<=xu.warn&&(bu.warn=console.warn?console.warn.bind(console,Cu("WARN"),"color: orange"):console.log.bind(console,"[33m",Cu("WARN"))),t<=xu.info&&(bu.info=console.info?console.info.bind(console,Cu("INFO"),"color: lightblue"):console.log.bind(console,"[34m",Cu("INFO"))),t<=xu.debug&&(bu.debug=console.debug?console.debug.bind(console,Cu("DEBUG"),"color: lightgreen"):console.log.bind(console,"[32m",Cu("DEBUG"))),t<=xu.trace&&(bu.trace=console.debug?console.debug.bind(console,Cu("TRACE"),"color: lightgreen"):console.log.bind(console,"[32m",Cu("TRACE")))},"setLogLevel"),Cu=mu(e=>`%c${fu().format("ss.SSS")} : ${e} : `,"format");const wu={min:{r:0,g:0,b:0,s:0,l:0,a:0},max:{r:255,g:255,b:255,h:360,s:100,l:100,a:1},clamp:{r:e=>e>=255?255:e<0?0:e,g:e=>e>=255?255:e<0?0:e,b:e=>e>=255?255:e<0?0:e,h:e=>e%360,s:e=>e>=100?100:e<0?0:e,l:e=>e>=100?100:e<0?0:e,a:e=>e>=1?1:e<0?0:e},toLinear:e=>{const t=e/255;return e>.03928?Math.pow((t+.055)/1.055,2.4):t/12.92},hue2rgb:(e,t,r)=>(r<0&&(r+=1),r>1&&(r-=1),r<1/6?e+6*(t-e)*r:r<.5?t:r<2/3?e+(t-e)*(2/3-r)*6:e),hsl2rgb:({h:e,s:t,l:r},n)=>{if(!t)return 2.55*r;e/=360,t/=100;const i=(r/=100)<.5?r*(1+t):r+t-r*t,o=2*r-i;switch(n){case"r":return 255*wu.hue2rgb(o,i,e+1/3);case"g":return 255*wu.hue2rgb(o,i,e);case"b":return 255*wu.hue2rgb(o,i,e-1/3)}},rgb2hsl:({r:e,g:t,b:r},n)=>{e/=255,t/=255,r/=255;const i=Math.max(e,t,r),o=Math.min(e,t,r),a=(i+o)/2;if("l"===n)return 100*a;if(i===o)return 0;const s=i-o;if("s"===n)return 100*(a>.5?s/(2-i-o):s/(i+o));switch(i){case e:return 60*((t-r)/s+(t<r?6:0));case t:return 60*((r-e)/s+2);case r:return 60*((e-t)/s+4);default:return-1}}},ku={channel:wu,lang:{clamp:(e,t,r)=>t>r?Math.min(t,Math.max(r,e)):Math.min(r,Math.max(t,e)),round:e=>Math.round(1e10*e)/1e10},unit:{dec2hex:e=>{const t=Math.round(e).toString(16);return t.length>1?t:`0${t}`}}},Su={};for(let RL=0;RL<=255;RL++)Su[RL]=ku.unit.dec2hex(RL);const _u=0,Tu=1,Au=2;class Pu{constructor(){this.type=_u}get(){return this.type}set(e){if(this.type&&this.type!==e)throw new Error("Cannot change both RGB and HSL channels at the same time");this.type=e}reset(){this.type=_u}is(e){return this.type===e}}const Eu=new class{constructor(e,t){this.color=t,this.changed=!1,this.data=e,this.type=new Pu}set(e,t){return this.color=t,this.changed=!1,this.data=e,this.type.type=_u,this}_ensureHSL(){const e=this.data,{h:t,s:r,l:n}=e;void 0===t&&(e.h=ku.channel.rgb2hsl(e,"h")),void 0===r&&(e.s=ku.channel.rgb2hsl(e,"s")),void 0===n&&(e.l=ku.channel.rgb2hsl(e,"l"))}_ensureRGB(){const e=this.data,{r:t,g:r,b:n}=e;void 0===t&&(e.r=ku.channel.hsl2rgb(e,"r")),void 0===r&&(e.g=ku.channel.hsl2rgb(e,"g")),void 0===n&&(e.b=ku.channel.hsl2rgb(e,"b"))}get r(){const e=this.data,t=e.r;return this.type.is(Au)||void 0===t?(this._ensureHSL(),ku.channel.hsl2rgb(e,"r")):t}get g(){const e=this.data,t=e.g;return this.type.is(Au)||void 0===t?(this._ensureHSL(),ku.channel.hsl2rgb(e,"g")):t}get b(){const e=this.data,t=e.b;return this.type.is(Au)||void 0===t?(this._ensureHSL(),ku.channel.hsl2rgb(e,"b")):t}get h(){const e=this.data,t=e.h;return this.type.is(Tu)||void 0===t?(this._ensureRGB(),ku.channel.rgb2hsl(e,"h")):t}get s(){const e=this.data,t=e.s;return this.type.is(Tu)||void 0===t?(this._ensureRGB(),ku.channel.rgb2hsl(e,"s")):t}get l(){const e=this.data,t=e.l;return this.type.is(Tu)||void 0===t?(this._ensureRGB(),ku.channel.rgb2hsl(e,"l")):t}get a(){return this.data.a}set r(e){this.type.set(Tu),this.changed=!0,this.data.r=e}set g(e){this.type.set(Tu),this.changed=!0,this.data.g=e}set b(e){this.type.set(Tu),this.changed=!0,this.data.b=e}set h(e){this.type.set(Au),this.changed=!0,this.data.h=e}set s(e){this.type.set(Au),this.changed=!0,this.data.s=e}set l(e){this.type.set(Au),this.changed=!0,this.data.l=e}set a(e){this.changed=!0,this.data.a=e}}({r:0,g:0,b:0,a:0},"transparent"),Mu={re:/^#((?:[a-f0-9]{2}){2,4}|[a-f0-9]{3})$/i,parse:e=>{if(35!==e.charCodeAt(0))return;const t=e.match(Mu.re);if(!t)return;const r=t[1],n=parseInt(r,16),i=r.length,o=i%4==0,a=i>4,s=a?1:17,l=a?8:4,c=o?0:-1,u=a?255:15;return Eu.set({r:(n>>l*(c+3)&u)*s,g:(n>>l*(c+2)&u)*s,b:(n>>l*(c+1)&u)*s,a:o?(n&u)*s/255:1},e)},stringify:e=>{const{r:t,g:r,b:n,a:i}=e;return i<1?`#${Su[Math.round(t)]}${Su[Math.round(r)]}${Su[Math.round(n)]}${Su[Math.round(255*i)]}`:`#${Su[Math.round(t)]}${Su[Math.round(r)]}${Su[Math.round(n)]}`}},Iu={re:/^hsla?\(\s*?(-?(?:\d+(?:\.\d+)?|(?:\.\d+))(?:e-?\d+)?(?:deg|grad|rad|turn)?)\s*?(?:,|\s)\s*?(-?(?:\d+(?:\.\d+)?|(?:\.\d+))(?:e-?\d+)?%)\s*?(?:,|\s)\s*?(-?(?:\d+(?:\.\d+)?|(?:\.\d+))(?:e-?\d+)?%)(?:\s*?(?:,|\/)\s*?\+?(-?(?:\d+(?:\.\d+)?|(?:\.\d+))(?:e-?\d+)?(%)?))?\s*?\)$/i,hueRe:/^(.+?)(deg|grad|rad|turn)$/i,_hue2deg:e=>{const t=e.match(Iu.hueRe);if(t){const[,e,r]=t;switch(r){case"grad":return ku.channel.clamp.h(.9*parseFloat(e));case"rad":return ku.channel.clamp.h(180*parseFloat(e)/Math.PI);case"turn":return ku.channel.clamp.h(360*parseFloat(e))}}return ku.channel.clamp.h(parseFloat(e))},parse:e=>{const t=e.charCodeAt(0);if(104!==t&&72!==t)return;const r=e.match(Iu.re);if(!r)return;const[,n,i,o,a,s]=r;return Eu.set({h:Iu._hue2deg(n),s:ku.channel.clamp.s(parseFloat(i)),l:ku.channel.clamp.l(parseFloat(o)),a:a?ku.channel.clamp.a(s?parseFloat(a)/100:parseFloat(a)):1},e)},stringify:e=>{const{h:t,s:r,l:n,a:i}=e;return i<1?`hsla(${ku.lang.round(t)}, ${ku.lang.round(r)}%, ${ku.lang.round(n)}%, ${i})`:`hsl(${ku.lang.round(t)}, ${ku.lang.round(r)}%, ${ku.lang.round(n)}%)`}},Bu={colors:{aliceblue:"#f0f8ff",antiquewhite:"#faebd7",aqua:"#00ffff",aquamarine:"#7fffd4",azure:"#f0ffff",beige:"#f5f5dc",bisque:"#ffe4c4",black:"#000000",blanchedalmond:"#ffebcd",blue:"#0000ff",blueviolet:"#8a2be2",brown:"#a52a2a",burlywood:"#deb887",cadetblue:"#5f9ea0",chartreuse:"#7fff00",chocolate:"#d2691e",coral:"#ff7f50",cornflowerblue:"#6495ed",cornsilk:"#fff8dc",crimson:"#dc143c",cyanaqua:"#00ffff",darkblue:"#00008b",darkcyan:"#008b8b",darkgoldenrod:"#b8860b",darkgray:"#a9a9a9",darkgreen:"#006400",darkgrey:"#a9a9a9",darkkhaki:"#bdb76b",darkmagenta:"#8b008b",darkolivegreen:"#556b2f",darkorange:"#ff8c00",darkorchid:"#9932cc",darkred:"#8b0000",darksalmon:"#e9967a",darkseagreen:"#8fbc8f",darkslateblue:"#483d8b",darkslategray:"#2f4f4f",darkslategrey:"#2f4f4f",darkturquoise:"#00ced1",darkviolet:"#9400d3",deeppink:"#ff1493",deepskyblue:"#00bfff",dimgray:"#696969",dimgrey:"#696969",dodgerblue:"#1e90ff",firebrick:"#b22222",floralwhite:"#fffaf0",forestgreen:"#228b22",fuchsia:"#ff00ff",gainsboro:"#dcdcdc",ghostwhite:"#f8f8ff",gold:"#ffd700",goldenrod:"#daa520",gray:"#808080",green:"#008000",greenyellow:"#adff2f",grey:"#808080",honeydew:"#f0fff0",hotpink:"#ff69b4",indianred:"#cd5c5c",indigo:"#4b0082",ivory:"#fffff0",khaki:"#f0e68c",lavender:"#e6e6fa",lavenderblush:"#fff0f5",lawngreen:"#7cfc00",lemonchiffon:"#fffacd",lightblue:"#add8e6",lightcoral:"#f08080",lightcyan:"#e0ffff",lightgoldenrodyellow:"#fafad2",lightgray:"#d3d3d3",lightgreen:"#90ee90",lightgrey:"#d3d3d3",lightpink:"#ffb6c1",lightsalmon:"#ffa07a",lightseagreen:"#20b2aa",lightskyblue:"#87cefa",lightslategray:"#778899",lightslategrey:"#778899",lightsteelblue:"#b0c4de",lightyellow:"#ffffe0",lime:"#00ff00",limegreen:"#32cd32",linen:"#faf0e6",magenta:"#ff00ff",maroon:"#800000",mediumaquamarine:"#66cdaa",mediumblue:"#0000cd",mediumorchid:"#ba55d3",mediumpurple:"#9370db",mediumseagreen:"#3cb371",mediumslateblue:"#7b68ee",mediumspringgreen:"#00fa9a",mediumturquoise:"#48d1cc",mediumvioletred:"#c71585",midnightblue:"#191970",mintcream:"#f5fffa",mistyrose:"#ffe4e1",moccasin:"#ffe4b5",navajowhite:"#ffdead",navy:"#000080",oldlace:"#fdf5e6",olive:"#808000",olivedrab:"#6b8e23",orange:"#ffa500",orangered:"#ff4500",orchid:"#da70d6",palegoldenrod:"#eee8aa",palegreen:"#98fb98",paleturquoise:"#afeeee",palevioletred:"#db7093",papayawhip:"#ffefd5",peachpuff:"#ffdab9",peru:"#cd853f",pink:"#ffc0cb",plum:"#dda0dd",powderblue:"#b0e0e6",purple:"#800080",rebeccapurple:"#663399",red:"#ff0000",rosybrown:"#bc8f8f",royalblue:"#4169e1",saddlebrown:"#8b4513",salmon:"#fa8072",sandybrown:"#f4a460",seagreen:"#2e8b57",seashell:"#fff5ee",sienna:"#a0522d",silver:"#c0c0c0",skyblue:"#87ceeb",slateblue:"#6a5acd",slategray:"#708090",slategrey:"#708090",snow:"#fffafa",springgreen:"#00ff7f",tan:"#d2b48c",teal:"#008080",thistle:"#d8bfd8",transparent:"#00000000",turquoise:"#40e0d0",violet:"#ee82ee",wheat:"#f5deb3",white:"#ffffff",whitesmoke:"#f5f5f5",yellow:"#ffff00",yellowgreen:"#9acd32"},parse:e=>{e=e.toLowerCase();const t=Bu.colors[e];if(t)return Mu.parse(t)},stringify:e=>{const t=Mu.stringify(e);for(const r in Bu.colors)if(Bu.colors[r]===t)return r}},Lu={re:/^rgba?\(\s*?(-?(?:\d+(?:\.\d+)?|(?:\.\d+))(?:e\d+)?(%?))\s*?(?:,|\s)\s*?(-?(?:\d+(?:\.\d+)?|(?:\.\d+))(?:e\d+)?(%?))\s*?(?:,|\s)\s*?(-?(?:\d+(?:\.\d+)?|(?:\.\d+))(?:e\d+)?(%?))(?:\s*?(?:,|\/)\s*?\+?(-?(?:\d+(?:\.\d+)?|(?:\.\d+))(?:e\d+)?(%?)))?\s*?\)$/i,parse:e=>{const t=e.charCodeAt(0);if(114!==t&&82!==t)return;const r=e.match(Lu.re);if(!r)return;const[,n,i,o,a,s,l,c,u]=r;return Eu.set({r:ku.channel.clamp.r(i?2.55*parseFloat(n):parseFloat(n)),g:ku.channel.clamp.g(a?2.55*parseFloat(o):parseFloat(o)),b:ku.channel.clamp.b(l?2.55*parseFloat(s):parseFloat(s)),a:c?ku.channel.clamp.a(u?parseFloat(c)/100:parseFloat(c)):1},e)},stringify:e=>{const{r:t,g:r,b:n,a:i}=e;return i<1?`rgba(${ku.lang.round(t)}, ${ku.lang.round(r)}, ${ku.lang.round(n)}, ${ku.lang.round(i)})`:`rgb(${ku.lang.round(t)}, ${ku.lang.round(r)}, ${ku.lang.round(n)})`}},ju={format:{keyword:Bu,hex:Mu,rgb:Lu,rgba:Lu,hsl:Iu,hsla:Iu},parse:e=>{if("string"!=typeof e)return e;const t=Mu.parse(e)||Lu.parse(e)||Iu.parse(e)||Bu.parse(e);if(t)return t;throw new Error(`Unsupported color format: "${e}"`)},stringify:e=>!e.changed&&e.color?e.color:e.type.is(Au)||void 0===e.data.r?Iu.stringify(e):e.a<1||!Number.isInteger(e.r)||!Number.isInteger(e.g)||!Number.isInteger(e.b)?Lu.stringify(e):Mu.stringify(e)},Nu=(e,t)=>{const r=ju.parse(e);for(const n in t)r[n]=ku.channel.clamp[n](t[n]);return ju.stringify(r)},Du=(e,t,r=0,n=1)=>{if("number"!=typeof e)return Nu(e,{a:t});const i=Eu.set({r:ku.channel.clamp.r(e),g:ku.channel.clamp.g(t),b:ku.channel.clamp.b(r),a:ku.channel.clamp.a(n)});return ju.stringify(i)},Ou=e=>(e=>{const{r:t,g:r,b:n}=ju.parse(e),i=.2126*ku.channel.toLinear(t)+.7152*ku.channel.toLinear(r)+.0722*ku.channel.toLinear(n);return ku.lang.round(i)})(e)>=.5,Fu=e=>!Ou(e),Ru=(e,t,r)=>{const n=ju.parse(e),i=n[t],o=ku.channel.clamp[t](i+r);return i!==o&&(n[t]=o),ju.stringify(n)},$u=(e,t)=>Ru(e,"l",t),zu=(e,t)=>Ru(e,"l",-t),Vu=(e,t)=>{const r=ju.parse(e),n={};for(const i in t)t[i]&&(n[i]=r[i]+t[i]);return Nu(e,n)},Wu=(e,t=100)=>{const r=ju.parse(e);return r.r=255-r.r,r.g=255-r.g,r.b=255-r.b,((e,t,r=50)=>{const{r:n,g:i,b:o,a:a}=ju.parse(e),{r:s,g:l,b:c,a:u}=ju.parse(t),h=r/100,d=2*h-1,p=a-u,f=((d*p===-1?d:(d+p)/(1+d*p))+1)/2,g=1-f;return Du(n*f+s*g,i*f+l*g,o*f+c*g,a*h+u*(1-h))})(r,e,t)},{entries:Hu,setPrototypeOf:qu,isFrozen:Uu,getPrototypeOf:Gu,getOwnPropertyDescriptor:Xu}=Object;let{freeze:Ju,seal:Yu,create:Zu}=Object,{apply:Ku,construct:Qu}="undefined"!=typeof Reflect&&Reflect;Ju||(Ju=function(e){return e}),Yu||(Yu=function(e){return e}),Ku||(Ku=function(e,t){for(var r=arguments.length,n=new Array(r>2?r-2:0),i=2;i<r;i++)n[i-2]=arguments[i];return e.apply(t,n)}),Qu||(Qu=function(e){for(var t=arguments.length,r=new Array(t>1?t-1:0),n=1;n<t;n++)r[n-1]=arguments[n];return new e(...r)});const eh=gh(Array.prototype.forEach),th=gh(Array.prototype.lastIndexOf),rh=gh(Array.prototype.pop),nh=gh(Array.prototype.push),ih=gh(Array.prototype.splice),oh=gh(String.prototype.toLowerCase),ah=gh(String.prototype.toString),sh=gh(String.prototype.match),lh=gh(String.prototype.replace),ch=gh(String.prototype.indexOf),uh=gh(String.prototype.trim),hh=gh(Object.prototype.hasOwnProperty),dh=gh(RegExp.prototype.test),ph=(fh=TypeError,function(){for(var e=arguments.length,t=new Array(e),r=0;r<e;r++)t[r]=arguments[r];return Qu(fh,t)});var fh;function gh(e){return function(t){t instanceof RegExp&&(t.lastIndex=0);for(var r=arguments.length,n=new Array(r>1?r-1:0),i=1;i<r;i++)n[i-1]=arguments[i];return Ku(e,t,n)}}function mh(e,t){let r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:oh;qu&&qu(e,null);let n=t.length;for(;n--;){let i=t[n];if("string"==typeof i){const e=r(i);e!==i&&(Uu(t)||(t[n]=e),i=e)}e[i]=!0}return e}function yh(e){for(let t=0;t<e.length;t++){hh(e,t)||(e[t]=null)}return e}function xh(e){const t=Zu(null);for(const[r,n]of Hu(e)){hh(e,r)&&(Array.isArray(n)?t[r]=yh(n):n&&"object"==typeof n&&n.constructor===Object?t[r]=xh(n):t[r]=n)}return t}function bh(e,t){for(;null!==e;){const r=Xu(e,t);if(r){if(r.get)return gh(r.get);if("function"==typeof r.value)return gh(r.value)}e=Gu(e)}return function(){return null}}const vh=Ju(["a","abbr","acronym","address","area","article","aside","audio","b","bdi","bdo","big","blink","blockquote","body","br","button","canvas","caption","center","cite","code","col","colgroup","content","data","datalist","dd","decorator","del","details","dfn","dialog","dir","div","dl","dt","element","em","fieldset","figcaption","figure","font","footer","form","h1","h2","h3","h4","h5","h6","head","header","hgroup","hr","html","i","img","input","ins","kbd","label","legend","li","main","map","mark","marquee","menu","menuitem","meter","nav","nobr","ol","optgroup","option","output","p","picture","pre","progress","q","rp","rt","ruby","s","samp","search","section","select","shadow","slot","small","source","spacer","span","strike","strong","style","sub","summary","sup","table","tbody","td","template","textarea","tfoot","th","thead","time","tr","track","tt","u","ul","var","video","wbr"]),Ch=Ju(["svg","a","altglyph","altglyphdef","altglyphitem","animatecolor","animatemotion","animatetransform","circle","clippath","defs","desc","ellipse","enterkeyhint","exportparts","filter","font","g","glyph","glyphref","hkern","image","inputmode","line","lineargradient","marker","mask","metadata","mpath","part","path","pattern","polygon","polyline","radialgradient","rect","stop","style","switch","symbol","text","textpath","title","tref","tspan","view","vkern"]),wh=Ju(["feBlend","feColorMatrix","feComponentTransfer","feComposite","feConvolveMatrix","feDiffuseLighting","feDisplacementMap","feDistantLight","feDropShadow","feFlood","feFuncA","feFuncB","feFuncG","feFuncR","feGaussianBlur","feImage","feMerge","feMergeNode","feMorphology","feOffset","fePointLight","feSpecularLighting","feSpotLight","feTile","feTurbulence"]),kh=Ju(["animate","color-profile","cursor","discard","font-face","font-face-format","font-face-name","font-face-src","font-face-uri","foreignobject","hatch","hatchpath","mesh","meshgradient","meshpatch","meshrow","missing-glyph","script","set","solidcolor","unknown","use"]),Sh=Ju(["math","menclose","merror","mfenced","mfrac","mglyph","mi","mlabeledtr","mmultiscripts","mn","mo","mover","mpadded","mphantom","mroot","mrow","ms","mspace","msqrt","mstyle","msub","msup","msubsup","mtable","mtd","mtext","mtr","munder","munderover","mprescripts"]),_h=Ju(["maction","maligngroup","malignmark","mlongdiv","mscarries","mscarry","msgroup","mstack","msline","msrow","semantics","annotation","annotation-xml","mprescripts","none"]),Th=Ju(["#text"]),Ah=Ju(["accept","action","align","alt","autocapitalize","autocomplete","autopictureinpicture","autoplay","background","bgcolor","border","capture","cellpadding","cellspacing","checked","cite","class","clear","color","cols","colspan","controls","controlslist","coords","crossorigin","datetime","decoding","default","dir","disabled","disablepictureinpicture","disableremoteplayback","download","draggable","enctype","enterkeyhint","exportparts","face","for","headers","height","hidden","high","href","hreflang","id","inert","inputmode","integrity","ismap","kind","label","lang","list","loading","loop","low","max","maxlength","media","method","min","minlength","multiple","muted","name","nonce","noshade","novalidate","nowrap","open","optimum","part","pattern","placeholder","playsinline","popover","popovertarget","popovertargetaction","poster","preload","pubdate","radiogroup","readonly","rel","required","rev","reversed","role","rows","rowspan","spellcheck","scope","selected","shape","size","sizes","slot","span","srclang","start","src","srcset","step","style","summary","tabindex","title","translate","type","usemap","valign","value","width","wrap","xmlns","slot"]),Ph=Ju(["accent-height","accumulate","additive","alignment-baseline","amplitude","ascent","attributename","attributetype","azimuth","basefrequency","baseline-shift","begin","bias","by","class","clip","clippathunits","clip-path","clip-rule","color","color-interpolation","color-interpolation-filters","color-profile","color-rendering","cx","cy","d","dx","dy","diffuseconstant","direction","display","divisor","dur","edgemode","elevation","end","exponent","fill","fill-opacity","fill-rule","filter","filterunits","flood-color","flood-opacity","font-family","font-size","font-size-adjust","font-stretch","font-style","font-variant","font-weight","fx","fy","g1","g2","glyph-name","glyphref","gradientunits","gradienttransform","height","href","id","image-rendering","in","in2","intercept","k","k1","k2","k3","k4","kerning","keypoints","keysplines","keytimes","lang","lengthadjust","letter-spacing","kernelmatrix","kernelunitlength","lighting-color","local","marker-end","marker-mid","marker-start","markerheight","markerunits","markerwidth","maskcontentunits","maskunits","max","mask","mask-type","media","method","mode","min","name","numoctaves","offset","operator","opacity","order","orient","orientation","origin","overflow","paint-order","path","pathlength","patterncontentunits","patterntransform","patternunits","points","preservealpha","preserveaspectratio","primitiveunits","r","rx","ry","radius","refx","refy","repeatcount","repeatdur","restart","result","rotate","scale","seed","shape-rendering","slope","specularconstant","specularexponent","spreadmethod","startoffset","stddeviation","stitchtiles","stop-color","stop-opacity","stroke-dasharray","stroke-dashoffset","stroke-linecap","stroke-linejoin","stroke-miterlimit","stroke-opacity","stroke","stroke-width","style","surfacescale","systemlanguage","tabindex","tablevalues","targetx","targety","transform","transform-origin","text-anchor","text-decoration","text-rendering","textlength","type","u1","u2","unicode","values","viewbox","visibility","version","vert-adv-y","vert-origin-x","vert-origin-y","width","word-spacing","wrap","writing-mode","xchannelselector","ychannelselector","x","x1","x2","xmlns","y","y1","y2","z","zoomandpan"]),Eh=Ju(["accent","accentunder","align","bevelled","close","columnsalign","columnlines","columnspan","denomalign","depth","dir","display","displaystyle","encoding","fence","frame","height","href","id","largeop","length","linethickness","lspace","lquote","mathbackground","mathcolor","mathsize","mathvariant","maxsize","minsize","movablelimits","notation","numalign","open","rowalign","rowlines","rowspacing","rowspan","rspace","rquote","scriptlevel","scriptminsize","scriptsizemultiplier","selection","separator","separators","stretchy","subscriptshift","supscriptshift","symmetric","voffset","width","xmlns"]),Mh=Ju(["xlink:href","xml:id","xlink:title","xml:space","xmlns:xlink"]),Ih=Yu(/\{\{[\w\W]*|[\w\W]*\}\}/gm),Bh=Yu(/<%[\w\W]*|[\w\W]*%>/gm),Lh=Yu(/\$\{[\w\W]*/gm),jh=Yu(/^data-[\-\w.\u00B7-\uFFFF]+$/),Nh=Yu(/^aria-[\-\w]+$/),Dh=Yu(/^(?:(?:(?:f|ht)tps?|mailto|tel|callto|sms|cid|xmpp|matrix):|[^a-z]|[a-z+.\-]+(?:[^a-z+.\-:]|$))/i),Oh=Yu(/^(?:\w+script|data):/i),Fh=Yu(/[\u0000-\u0020\u00A0\u1680\u180E\u2000-\u2029\u205F\u3000]/g),Rh=Yu(/^html$/i),$h=Yu(/^[a-z][.\w]*(-[.\w]+)+$/i);var zh=Object.freeze({__proto__:null,ARIA_ATTR:Nh,ATTR_WHITESPACE:Fh,CUSTOM_ELEMENT:$h,DATA_ATTR:jh,DOCTYPE_NAME:Rh,ERB_EXPR:Bh,IS_ALLOWED_URI:Dh,IS_SCRIPT_OR_DATA:Oh,MUSTACHE_EXPR:Ih,TMPLIT_EXPR:Lh});const Vh=1,Wh=3,Hh=7,qh=8,Uh=9;var Gh,Xh=function e(){let t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"undefined"==typeof window?null:window;const r=t=>e(t);if(r.version="3.3.1",r.removed=[],!t||!t.document||t.document.nodeType!==Uh||!t.Element)return r.isSupported=!1,r;let{document:n}=t;const i=n,o=i.currentScript,{DocumentFragment:a,HTMLTemplateElement:s,Node:l,Element:c,NodeFilter:u,NamedNodeMap:h=t.NamedNodeMap||t.MozNamedAttrMap,HTMLFormElement:d,DOMParser:p,trustedTypes:f}=t,g=c.prototype,m=bh(g,"cloneNode"),y=bh(g,"remove"),x=bh(g,"nextSibling"),b=bh(g,"childNodes"),v=bh(g,"parentNode");if("function"==typeof s){const e=n.createElement("template");e.content&&e.content.ownerDocument&&(n=e.content.ownerDocument)}let C,w="";const{implementation:k,createNodeIterator:S,createDocumentFragment:_,getElementsByTagName:T}=n,{importNode:A}=i;let P={afterSanitizeAttributes:[],afterSanitizeElements:[],afterSanitizeShadowDOM:[],beforeSanitizeAttributes:[],beforeSanitizeElements:[],beforeSanitizeShadowDOM:[],uponSanitizeAttribute:[],uponSanitizeElement:[],uponSanitizeShadowNode:[]};r.isSupported="function"==typeof Hu&&"function"==typeof v&&k&&void 0!==k.createHTMLDocument;const{MUSTACHE_EXPR:E,ERB_EXPR:M,TMPLIT_EXPR:I,DATA_ATTR:B,ARIA_ATTR:L,IS_SCRIPT_OR_DATA:j,ATTR_WHITESPACE:N,CUSTOM_ELEMENT:D}=zh;let{IS_ALLOWED_URI:O}=zh,F=null;const R=mh({},[...vh,...Ch,...wh,...Sh,...Th]);let $=null;const z=mh({},[...Ah,...Ph,...Eh,...Mh]);let V=Object.seal(Zu(null,{tagNameCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},attributeNameCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},allowCustomizedBuiltInElements:{writable:!0,configurable:!1,enumerable:!0,value:!1}})),W=null,H=null;const q=Object.seal(Zu(null,{tagCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},attributeCheck:{writable:!0,configurable:!1,enumerable:!0,value:null}}));let U=!0,G=!0,X=!1,J=!0,Y=!1,Z=!0,K=!1,Q=!1,ee=!1,te=!1,re=!1,ne=!1,ie=!0,oe=!1,ae=!0,se=!1,le={},ce=null;const ue=mh({},["annotation-xml","audio","colgroup","desc","foreignobject","head","iframe","math","mi","mn","mo","ms","mtext","noembed","noframes","noscript","plaintext","script","style","svg","template","thead","title","video","xmp"]);let he=null;const de=mh({},["audio","video","img","source","image","track"]);let pe=null;const fe=mh({},["alt","class","for","id","label","name","pattern","placeholder","role","summary","title","value","style","xmlns"]),ge="http://www.w3.org/1998/Math/MathML",me="http://www.w3.org/2000/svg",ye="http://www.w3.org/1999/xhtml";let xe=ye,be=!1,ve=null;const Ce=mh({},[ge,me,ye],ah);let we=mh({},["mi","mo","mn","ms","mtext"]),ke=mh({},["annotation-xml"]);const Se=mh({},["title","style","font","a","script"]);let _e=null;const Te=["application/xhtml+xml","text/html"];let Ae=null,Pe=null;const Ee=n.createElement("form"),Me=function(e){return e instanceof RegExp||e instanceof Function},Ie=function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};if(!Pe||Pe!==e){if(e&&"object"==typeof e||(e={}),e=xh(e),_e=-1===Te.indexOf(e.PARSER_MEDIA_TYPE)?"text/html":e.PARSER_MEDIA_TYPE,Ae="application/xhtml+xml"===_e?ah:oh,F=hh(e,"ALLOWED_TAGS")?mh({},e.ALLOWED_TAGS,Ae):R,$=hh(e,"ALLOWED_ATTR")?mh({},e.ALLOWED_ATTR,Ae):z,ve=hh(e,"ALLOWED_NAMESPACES")?mh({},e.ALLOWED_NAMESPACES,ah):Ce,pe=hh(e,"ADD_URI_SAFE_ATTR")?mh(xh(fe),e.ADD_URI_SAFE_ATTR,Ae):fe,he=hh(e,"ADD_DATA_URI_TAGS")?mh(xh(de),e.ADD_DATA_URI_TAGS,Ae):de,ce=hh(e,"FORBID_CONTENTS")?mh({},e.FORBID_CONTENTS,Ae):ue,W=hh(e,"FORBID_TAGS")?mh({},e.FORBID_TAGS,Ae):xh({}),H=hh(e,"FORBID_ATTR")?mh({},e.FORBID_ATTR,Ae):xh({}),le=!!hh(e,"USE_PROFILES")&&e.USE_PROFILES,U=!1!==e.ALLOW_ARIA_ATTR,G=!1!==e.ALLOW_DATA_ATTR,X=e.ALLOW_UNKNOWN_PROTOCOLS||!1,J=!1!==e.ALLOW_SELF_CLOSE_IN_ATTR,Y=e.SAFE_FOR_TEMPLATES||!1,Z=!1!==e.SAFE_FOR_XML,K=e.WHOLE_DOCUMENT||!1,te=e.RETURN_DOM||!1,re=e.RETURN_DOM_FRAGMENT||!1,ne=e.RETURN_TRUSTED_TYPE||!1,ee=e.FORCE_BODY||!1,ie=!1!==e.SANITIZE_DOM,oe=e.SANITIZE_NAMED_PROPS||!1,ae=!1!==e.KEEP_CONTENT,se=e.IN_PLACE||!1,O=e.ALLOWED_URI_REGEXP||Dh,xe=e.NAMESPACE||ye,we=e.MATHML_TEXT_INTEGRATION_POINTS||we,ke=e.HTML_INTEGRATION_POINTS||ke,V=e.CUSTOM_ELEMENT_HANDLING||{},e.CUSTOM_ELEMENT_HANDLING&&Me(e.CUSTOM_ELEMENT_HANDLING.tagNameCheck)&&(V.tagNameCheck=e.CUSTOM_ELEMENT_HANDLING.tagNameCheck),e.CUSTOM_ELEMENT_HANDLING&&Me(e.CUSTOM_ELEMENT_HANDLING.attributeNameCheck)&&(V.attributeNameCheck=e.CUSTOM_ELEMENT_HANDLING.attributeNameCheck),e.CUSTOM_ELEMENT_HANDLING&&"boolean"==typeof e.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements&&(V.allowCustomizedBuiltInElements=e.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements),Y&&(G=!1),re&&(te=!0),le&&(F=mh({},Th),$=[],!0===le.html&&(mh(F,vh),mh($,Ah)),!0===le.svg&&(mh(F,Ch),mh($,Ph),mh($,Mh)),!0===le.svgFilters&&(mh(F,wh),mh($,Ph),mh($,Mh)),!0===le.mathMl&&(mh(F,Sh),mh($,Eh),mh($,Mh))),e.ADD_TAGS&&("function"==typeof e.ADD_TAGS?q.tagCheck=e.ADD_TAGS:(F===R&&(F=xh(F)),mh(F,e.ADD_TAGS,Ae))),e.ADD_ATTR&&("function"==typeof e.ADD_ATTR?q.attributeCheck=e.ADD_ATTR:($===z&&($=xh($)),mh($,e.ADD_ATTR,Ae))),e.ADD_URI_SAFE_ATTR&&mh(pe,e.ADD_URI_SAFE_ATTR,Ae),e.FORBID_CONTENTS&&(ce===ue&&(ce=xh(ce)),mh(ce,e.FORBID_CONTENTS,Ae)),e.ADD_FORBID_CONTENTS&&(ce===ue&&(ce=xh(ce)),mh(ce,e.ADD_FORBID_CONTENTS,Ae)),ae&&(F["#text"]=!0),K&&mh(F,["html","head","body"]),F.table&&(mh(F,["tbody"]),delete W.tbody),e.TRUSTED_TYPES_POLICY){if("function"!=typeof e.TRUSTED_TYPES_POLICY.createHTML)throw ph('TRUSTED_TYPES_POLICY configuration option must provide a "createHTML" hook.');if("function"!=typeof e.TRUSTED_TYPES_POLICY.createScriptURL)throw ph('TRUSTED_TYPES_POLICY configuration option must provide a "createScriptURL" hook.');C=e.TRUSTED_TYPES_POLICY,w=C.createHTML("")}else void 0===C&&(C=function(e,t){if("object"!=typeof e||"function"!=typeof e.createPolicy)return null;let r=null;const n="data-tt-policy-suffix";t&&t.hasAttribute(n)&&(r=t.getAttribute(n));const i="dompurify"+(r?"#"+r:"");try{return e.createPolicy(i,{createHTML:e=>e,createScriptURL:e=>e})}catch(o){return console.warn("TrustedTypes policy "+i+" could not be created."),null}}(f,o)),null!==C&&"string"==typeof w&&(w=C.createHTML(""));Ju&&Ju(e),Pe=e}},Be=mh({},[...Ch,...wh,...kh]),Le=mh({},[...Sh,..._h]),je=function(e){nh(r.removed,{element:e});try{v(e).removeChild(e)}catch(t){y(e)}},Ne=function(e,t){try{nh(r.removed,{attribute:t.getAttributeNode(e),from:t})}catch(n){nh(r.removed,{attribute:null,from:t})}if(t.removeAttribute(e),"is"===e)if(te||re)try{je(t)}catch(n){}else try{t.setAttribute(e,"")}catch(n){}},De=function(e){let t=null,r=null;if(ee)e="<remove></remove>"+e;else{const t=sh(e,/^[\r\n\t ]+/);r=t&&t[0]}"application/xhtml+xml"===_e&&xe===ye&&(e='<html xmlns="http://www.w3.org/1999/xhtml"><head></head><body>'+e+"</body></html>");const i=C?C.createHTML(e):e;if(xe===ye)try{t=(new p).parseFromString(i,_e)}catch(a){}if(!t||!t.documentElement){t=k.createDocument(xe,"template",null);try{t.documentElement.innerHTML=be?w:i}catch(a){}}const o=t.body||t.documentElement;return e&&r&&o.insertBefore(n.createTextNode(r),o.childNodes[0]||null),xe===ye?T.call(t,K?"html":"body")[0]:K?t.documentElement:o},Oe=function(e){return S.call(e.ownerDocument||e,e,u.SHOW_ELEMENT|u.SHOW_COMMENT|u.SHOW_TEXT|u.SHOW_PROCESSING_INSTRUCTION|u.SHOW_CDATA_SECTION,null)},Fe=function(e){return e instanceof d&&("string"!=typeof e.nodeName||"string"!=typeof e.textContent||"function"!=typeof e.removeChild||!(e.attributes instanceof h)||"function"!=typeof e.removeAttribute||"function"!=typeof e.setAttribute||"string"!=typeof e.namespaceURI||"function"!=typeof e.insertBefore||"function"!=typeof e.hasChildNodes)},Re=function(e){return"function"==typeof l&&e instanceof l};function $e(e,t,n){eh(e,e=>{e.call(r,t,n,Pe)})}const ze=function(e){let t=null;if($e(P.beforeSanitizeElements,e,null),Fe(e))return je(e),!0;const n=Ae(e.nodeName);if($e(P.uponSanitizeElement,e,{tagName:n,allowedTags:F}),Z&&e.hasChildNodes()&&!Re(e.firstElementChild)&&dh(/<[/\w!]/g,e.innerHTML)&&dh(/<[/\w!]/g,e.textContent))return je(e),!0;if(e.nodeType===Hh)return je(e),!0;if(Z&&e.nodeType===qh&&dh(/<[/\w]/g,e.data))return je(e),!0;if(!(q.tagCheck instanceof Function&&q.tagCheck(n))&&(!F[n]||W[n])){if(!W[n]&&We(n)){if(V.tagNameCheck instanceof RegExp&&dh(V.tagNameCheck,n))return!1;if(V.tagNameCheck instanceof Function&&V.tagNameCheck(n))return!1}if(ae&&!ce[n]){const t=v(e)||e.parentNode,r=b(e)||e.childNodes;if(r&&t){for(let n=r.length-1;n>=0;--n){const i=m(r[n],!0);i.__removalCount=(e.__removalCount||0)+1,t.insertBefore(i,x(e))}}}return je(e),!0}return e instanceof c&&!function(e){let t=v(e);t&&t.tagName||(t={namespaceURI:xe,tagName:"template"});const r=oh(e.tagName),n=oh(t.tagName);return!!ve[e.namespaceURI]&&(e.namespaceURI===me?t.namespaceURI===ye?"svg"===r:t.namespaceURI===ge?"svg"===r&&("annotation-xml"===n||we[n]):Boolean(Be[r]):e.namespaceURI===ge?t.namespaceURI===ye?"math"===r:t.namespaceURI===me?"math"===r&&ke[n]:Boolean(Le[r]):e.namespaceURI===ye?!(t.namespaceURI===me&&!ke[n])&&!(t.namespaceURI===ge&&!we[n])&&!Le[r]&&(Se[r]||!Be[r]):!("application/xhtml+xml"!==_e||!ve[e.namespaceURI]))}(e)?(je(e),!0):"noscript"!==n&&"noembed"!==n&&"noframes"!==n||!dh(/<\/no(script|embed|frames)/i,e.innerHTML)?(Y&&e.nodeType===Wh&&(t=e.textContent,eh([E,M,I],e=>{t=lh(t,e," ")}),e.textContent!==t&&(nh(r.removed,{element:e.cloneNode()}),e.textContent=t)),$e(P.afterSanitizeElements,e,null),!1):(je(e),!0)},Ve=function(e,t,r){if(ie&&("id"===t||"name"===t)&&(r in n||r in Ee))return!1;if(G&&!H[t]&&dh(B,t));else if(U&&dh(L,t));else if(q.attributeCheck instanceof Function&&q.attributeCheck(t,e));else if(!$[t]||H[t]){if(!(We(e)&&(V.tagNameCheck instanceof RegExp&&dh(V.tagNameCheck,e)||V.tagNameCheck instanceof Function&&V.tagNameCheck(e))&&(V.attributeNameCheck instanceof RegExp&&dh(V.attributeNameCheck,t)||V.attributeNameCheck instanceof Function&&V.attributeNameCheck(t,e))||"is"===t&&V.allowCustomizedBuiltInElements&&(V.tagNameCheck instanceof RegExp&&dh(V.tagNameCheck,r)||V.tagNameCheck instanceof Function&&V.tagNameCheck(r))))return!1}else if(pe[t]);else if(dh(O,lh(r,N,"")));else if("src"!==t&&"xlink:href"!==t&&"href"!==t||"script"===e||0!==ch(r,"data:")||!he[e]){if(X&&!dh(j,lh(r,N,"")));else if(r)return!1}else;return!0},We=function(e){return"annotation-xml"!==e&&sh(e,D)},He=function(e){$e(P.beforeSanitizeAttributes,e,null);const{attributes:t}=e;if(!t||Fe(e))return;const n={attrName:"",attrValue:"",keepAttr:!0,allowedAttributes:$,forceKeepAttr:void 0};let i=t.length;for(;i--;){const a=t[i],{name:s,namespaceURI:l,value:c}=a,u=Ae(s),h=c;let d="value"===s?h:uh(h);if(n.attrName=u,n.attrValue=d,n.keepAttr=!0,n.forceKeepAttr=void 0,$e(P.uponSanitizeAttribute,e,n),d=n.attrValue,!oe||"id"!==u&&"name"!==u||(Ne(s,e),d="user-content-"+d),Z&&dh(/((--!?|])>)|<\/(style|title|textarea)/i,d)){Ne(s,e);continue}if("attributename"===u&&sh(d,"href")){Ne(s,e);continue}if(n.forceKeepAttr)continue;if(!n.keepAttr){Ne(s,e);continue}if(!J&&dh(/\/>/i,d)){Ne(s,e);continue}Y&&eh([E,M,I],e=>{d=lh(d,e," ")});const p=Ae(e.nodeName);if(Ve(p,u,d)){if(C&&"object"==typeof f&&"function"==typeof f.getAttributeType)if(l);else switch(f.getAttributeType(p,u)){case"TrustedHTML":d=C.createHTML(d);break;case"TrustedScriptURL":d=C.createScriptURL(d)}if(d!==h)try{l?e.setAttributeNS(l,s,d):e.setAttribute(s,d),Fe(e)?je(e):rh(r.removed)}catch(o){Ne(s,e)}}else Ne(s,e)}$e(P.afterSanitizeAttributes,e,null)},qe=function e(t){let r=null;const n=Oe(t);for($e(P.beforeSanitizeShadowDOM,t,null);r=n.nextNode();)$e(P.uponSanitizeShadowNode,r,null),ze(r),He(r),r.content instanceof a&&e(r.content);$e(P.afterSanitizeShadowDOM,t,null)};return r.sanitize=function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=null,o=null,s=null,c=null;if(be=!e,be&&(e="\x3c!--\x3e"),"string"!=typeof e&&!Re(e)){if("function"!=typeof e.toString)throw ph("toString is not a function");if("string"!=typeof(e=e.toString()))throw ph("dirty is not a string, aborting")}if(!r.isSupported)return e;if(Q||Ie(t),r.removed=[],"string"==typeof e&&(se=!1),se){if(e.nodeName){const t=Ae(e.nodeName);if(!F[t]||W[t])throw ph("root node is forbidden and cannot be sanitized in-place")}}else if(e instanceof l)n=De("\x3c!----\x3e"),o=n.ownerDocument.importNode(e,!0),o.nodeType===Vh&&"BODY"===o.nodeName||"HTML"===o.nodeName?n=o:n.appendChild(o);else{if(!te&&!Y&&!K&&-1===e.indexOf("<"))return C&&ne?C.createHTML(e):e;if(n=De(e),!n)return te?null:ne?w:""}n&&ee&&je(n.firstChild);const u=Oe(se?e:n);for(;s=u.nextNode();)ze(s),He(s),s.content instanceof a&&qe(s.content);if(se)return e;if(te){if(re)for(c=_.call(n.ownerDocument);n.firstChild;)c.appendChild(n.firstChild);else c=n;return($.shadowroot||$.shadowrootmode)&&(c=A.call(i,c,!0)),c}let h=K?n.outerHTML:n.innerHTML;return K&&F["!doctype"]&&n.ownerDocument&&n.ownerDocument.doctype&&n.ownerDocument.doctype.name&&dh(Rh,n.ownerDocument.doctype.name)&&(h="<!DOCTYPE "+n.ownerDocument.doctype.name+">\n"+h),Y&&eh([E,M,I],e=>{h=lh(h,e," ")}),C&&ne?C.createHTML(h):h},r.setConfig=function(){Ie(arguments.length>0&&void 0!==arguments[0]?arguments[0]:{}),Q=!0},r.clearConfig=function(){Pe=null,Q=!1},r.isValidAttribute=function(e,t,r){Pe||Ie({});const n=Ae(e),i=Ae(t);return Ve(n,i,r)},r.addHook=function(e,t){"function"==typeof t&&nh(P[e],t)},r.removeHook=function(e,t){if(void 0!==t){const r=th(P[e],t);return-1===r?void 0:ih(P[e],r,1)[0]}return rh(P[e])},r.removeHooks=function(e){P[e]=[]},r.removeAllHooks=function(){P={afterSanitizeAttributes:[],afterSanitizeElements:[],afterSanitizeShadowDOM:[],beforeSanitizeAttributes:[],beforeSanitizeElements:[],beforeSanitizeShadowDOM:[],uponSanitizeAttribute:[],uponSanitizeElement:[],uponSanitizeShadowNode:[]}},r}(),Jh=/^-{3}\s*[\n\r](.*?)[\n\r]-{3}\s*[\n\r]+/s,Yh=/%{2}{\s*(?:(\w+)\s*:|(\w+))\s*(?:(\w+)|((?:(?!}%{2}).|\r?\n)*))?\s*(?:}%{2})?/gi,Zh=/\s*%%.*\n/gm,Kh=(a=class extends Error{constructor(e){super(e),this.name="UnknownDiagramError"}},mu(a,"UnknownDiagramError"),a),Qh={},ed=mu(function(e,t){e=e.replace(Jh,"").replace(Yh,"").replace(Zh,"\n");for(const[r,{detector:n}]of Object.entries(Qh)){if(n(e,t))return r}throw new Kh(`No diagram type detected matching given configuration for text: ${e}`)},"detectType"),td=mu((...e)=>{for(const{id:t,detector:r,loader:n}of e)rd(t,r,n)},"registerLazyLoadedDiagrams"),rd=mu((e,t,r)=>{Qh[e]&&bu.warn(`Detector with key ${e} already exists. Overwriting.`),Qh[e]={detector:t,loader:r},bu.debug(`Detector with key ${e} added${r?" with loader":""}`)},"addDetector"),nd=mu(e=>Qh[e].loader,"getDiagramLoader"),id=mu((e,t,{depth:r=2,clobber:n=!1}={})=>{const i={depth:r,clobber:n};return Array.isArray(t)&&!Array.isArray(e)?(t.forEach(t=>id(e,t,i)),e):Array.isArray(t)&&Array.isArray(e)?(t.forEach(t=>{e.includes(t)||e.push(t)}),e):void 0===e||r<=0?null!=e&&"object"==typeof e&&"object"==typeof t?Object.assign(e,t):t:(void 0!==t&&"object"==typeof e&&"object"==typeof t&&Object.keys(t).forEach(i=>{"object"!=typeof t[i]||void 0!==e[i]&&"object"!=typeof e[i]?(n||"object"!=typeof e[i]&&"object"!=typeof t[i])&&(e[i]=t[i]):(void 0===e[i]&&(e[i]=Array.isArray(t[i])?[]:{}),e[i]=id(e[i],t[i],{depth:r-1,clobber:n}))}),e)},"assignWithDepth"),od=id,ad="#ffffff",sd="#f2f2f2",ld=mu((e,t)=>Vu(e,t?{s:-40,l:10}:{s:-40,l:-10}),"mkBorder"),cd=(mu(s=class{constructor(){this.background="#f4f4f4",this.primaryColor="#fff4dd",this.noteBkgColor="#fff5ad",this.noteTextColor="#333",this.THEME_COLOR_LIMIT=12,this.fontFamily='"trebuchet ms", verdana, arial, sans-serif',this.fontSize="16px"}updateColors(){var e,t,r,n,i,o,a,s,l,c,u,h,d,p,f,g,m,y,x,b,v;if(this.primaryTextColor=this.primaryTextColor||(this.darkMode?"#eee":"#333"),this.secondaryColor=this.secondaryColor||Vu(this.primaryColor,{h:-120}),this.tertiaryColor=this.tertiaryColor||Vu(this.primaryColor,{h:180,l:5}),this.primaryBorderColor=this.primaryBorderColor||ld(this.primaryColor,this.darkMode),this.secondaryBorderColor=this.secondaryBorderColor||ld(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=this.tertiaryBorderColor||ld(this.tertiaryColor,this.darkMode),this.noteBorderColor=this.noteBorderColor||ld(this.noteBkgColor,this.darkMode),this.noteBkgColor=this.noteBkgColor||"#fff5ad",this.noteTextColor=this.noteTextColor||"#333",this.secondaryTextColor=this.secondaryTextColor||Wu(this.secondaryColor),this.tertiaryTextColor=this.tertiaryTextColor||Wu(this.tertiaryColor),this.lineColor=this.lineColor||Wu(this.background),this.arrowheadColor=this.arrowheadColor||Wu(this.background),this.textColor=this.textColor||this.primaryTextColor,this.border2=this.border2||this.tertiaryBorderColor,this.nodeBkg=this.nodeBkg||this.primaryColor,this.mainBkg=this.mainBkg||this.primaryColor,this.nodeBorder=this.nodeBorder||this.primaryBorderColor,this.clusterBkg=this.clusterBkg||this.tertiaryColor,this.clusterBorder=this.clusterBorder||this.tertiaryBorderColor,this.defaultLinkColor=this.defaultLinkColor||this.lineColor,this.titleColor=this.titleColor||this.tertiaryTextColor,this.edgeLabelBackground=this.edgeLabelBackground||(this.darkMode?zu(this.secondaryColor,30):this.secondaryColor),this.nodeTextColor=this.nodeTextColor||this.primaryTextColor,this.actorBorder=this.actorBorder||this.primaryBorderColor,this.actorBkg=this.actorBkg||this.mainBkg,this.actorTextColor=this.actorTextColor||this.primaryTextColor,this.actorLineColor=this.actorLineColor||this.actorBorder,this.labelBoxBkgColor=this.labelBoxBkgColor||this.actorBkg,this.signalColor=this.signalColor||this.textColor,this.signalTextColor=this.signalTextColor||this.textColor,this.labelBoxBorderColor=this.labelBoxBorderColor||this.actorBorder,this.labelTextColor=this.labelTextColor||this.actorTextColor,this.loopTextColor=this.loopTextColor||this.actorTextColor,this.activationBorderColor=this.activationBorderColor||zu(this.secondaryColor,10),this.activationBkgColor=this.activationBkgColor||this.secondaryColor,this.sequenceNumberColor=this.sequenceNumberColor||Wu(this.lineColor),this.sectionBkgColor=this.sectionBkgColor||this.tertiaryColor,this.altSectionBkgColor=this.altSectionBkgColor||"white",this.sectionBkgColor=this.sectionBkgColor||this.secondaryColor,this.sectionBkgColor2=this.sectionBkgColor2||this.primaryColor,this.excludeBkgColor=this.excludeBkgColor||"#eeeeee",this.taskBorderColor=this.taskBorderColor||this.primaryBorderColor,this.taskBkgColor=this.taskBkgColor||this.primaryColor,this.activeTaskBorderColor=this.activeTaskBorderColor||this.primaryColor,this.activeTaskBkgColor=this.activeTaskBkgColor||$u(this.primaryColor,23),this.gridColor=this.gridColor||"lightgrey",this.doneTaskBkgColor=this.doneTaskBkgColor||"lightgrey",this.doneTaskBorderColor=this.doneTaskBorderColor||"grey",this.critBorderColor=this.critBorderColor||"#ff8888",this.critBkgColor=this.critBkgColor||"red",this.todayLineColor=this.todayLineColor||"red",this.vertLineColor=this.vertLineColor||"navy",this.taskTextColor=this.taskTextColor||this.textColor,this.taskTextOutsideColor=this.taskTextOutsideColor||this.textColor,this.taskTextLightColor=this.taskTextLightColor||this.textColor,this.taskTextColor=this.taskTextColor||this.primaryTextColor,this.taskTextDarkColor=this.taskTextDarkColor||this.textColor,this.taskTextClickableColor=this.taskTextClickableColor||"#003163",this.personBorder=this.personBorder||this.primaryBorderColor,this.personBkg=this.personBkg||this.mainBkg,this.darkMode?(this.rowOdd=this.rowOdd||zu(this.mainBkg,5)||"#ffffff",this.rowEven=this.rowEven||zu(this.mainBkg,10)):(this.rowOdd=this.rowOdd||$u(this.mainBkg,75)||"#ffffff",this.rowEven=this.rowEven||$u(this.mainBkg,5)),this.transitionColor=this.transitionColor||this.lineColor,this.transitionLabelColor=this.transitionLabelColor||this.textColor,this.stateLabelColor=this.stateLabelColor||this.stateBkg||this.primaryTextColor,this.stateBkg=this.stateBkg||this.mainBkg,this.labelBackgroundColor=this.labelBackgroundColor||this.stateBkg,this.compositeBackground=this.compositeBackground||this.background||this.tertiaryColor,this.altBackground=this.altBackground||this.tertiaryColor,this.compositeTitleBackground=this.compositeTitleBackground||this.mainBkg,this.compositeBorder=this.compositeBorder||this.nodeBorder,this.innerEndBackground=this.nodeBorder,this.errorBkgColor=this.errorBkgColor||this.tertiaryColor,this.errorTextColor=this.errorTextColor||this.tertiaryTextColor,this.transitionColor=this.transitionColor||this.lineColor,this.specialStateColor=this.lineColor,this.cScale0=this.cScale0||this.primaryColor,this.cScale1=this.cScale1||this.secondaryColor,this.cScale2=this.cScale2||this.tertiaryColor,this.cScale3=this.cScale3||Vu(this.primaryColor,{h:30}),this.cScale4=this.cScale4||Vu(this.primaryColor,{h:60}),this.cScale5=this.cScale5||Vu(this.primaryColor,{h:90}),this.cScale6=this.cScale6||Vu(this.primaryColor,{h:120}),this.cScale7=this.cScale7||Vu(this.primaryColor,{h:150}),this.cScale8=this.cScale8||Vu(this.primaryColor,{h:210,l:150}),this.cScale9=this.cScale9||Vu(this.primaryColor,{h:270}),this.cScale10=this.cScale10||Vu(this.primaryColor,{h:300}),this.cScale11=this.cScale11||Vu(this.primaryColor,{h:330}),this.darkMode)for(let w=0;w<this.THEME_COLOR_LIMIT;w++)this["cScale"+w]=zu(this["cScale"+w],75);else for(let w=0;w<this.THEME_COLOR_LIMIT;w++)this["cScale"+w]=zu(this["cScale"+w],25);for(let w=0;w<this.THEME_COLOR_LIMIT;w++)this["cScaleInv"+w]=this["cScaleInv"+w]||Wu(this["cScale"+w]);for(let w=0;w<this.THEME_COLOR_LIMIT;w++)this.darkMode?this["cScalePeer"+w]=this["cScalePeer"+w]||$u(this["cScale"+w],10):this["cScalePeer"+w]=this["cScalePeer"+w]||zu(this["cScale"+w],10);this.scaleLabelColor=this.scaleLabelColor||this.labelTextColor;for(let w=0;w<this.THEME_COLOR_LIMIT;w++)this["cScaleLabel"+w]=this["cScaleLabel"+w]||this.scaleLabelColor;const C=this.darkMode?-4:-1;for(let w=0;w<5;w++)this["surface"+w]=this["surface"+w]||Vu(this.mainBkg,{h:180,s:-15,l:C*(5+3*w)}),this["surfacePeer"+w]=this["surfacePeer"+w]||Vu(this.mainBkg,{h:180,s:-15,l:C*(8+3*w)});this.classText=this.classText||this.textColor,this.fillType0=this.fillType0||this.primaryColor,this.fillType1=this.fillType1||this.secondaryColor,this.fillType2=this.fillType2||Vu(this.primaryColor,{h:64}),this.fillType3=this.fillType3||Vu(this.secondaryColor,{h:64}),this.fillType4=this.fillType4||Vu(this.primaryColor,{h:-64}),this.fillType5=this.fillType5||Vu(this.secondaryColor,{h:-64}),this.fillType6=this.fillType6||Vu(this.primaryColor,{h:128}),this.fillType7=this.fillType7||Vu(this.secondaryColor,{h:128}),this.pie1=this.pie1||this.primaryColor,this.pie2=this.pie2||this.secondaryColor,this.pie3=this.pie3||this.tertiaryColor,this.pie4=this.pie4||Vu(this.primaryColor,{l:-10}),this.pie5=this.pie5||Vu(this.secondaryColor,{l:-10}),this.pie6=this.pie6||Vu(this.tertiaryColor,{l:-10}),this.pie7=this.pie7||Vu(this.primaryColor,{h:60,l:-10}),this.pie8=this.pie8||Vu(this.primaryColor,{h:-60,l:-10}),this.pie9=this.pie9||Vu(this.primaryColor,{h:120,l:0}),this.pie10=this.pie10||Vu(this.primaryColor,{h:60,l:-20}),this.pie11=this.pie11||Vu(this.primaryColor,{h:-60,l:-20}),this.pie12=this.pie12||Vu(this.primaryColor,{h:120,l:-10}),this.pieTitleTextSize=this.pieTitleTextSize||"25px",this.pieTitleTextColor=this.pieTitleTextColor||this.taskTextDarkColor,this.pieSectionTextSize=this.pieSectionTextSize||"17px",this.pieSectionTextColor=this.pieSectionTextColor||this.textColor,this.pieLegendTextSize=this.pieLegendTextSize||"17px",this.pieLegendTextColor=this.pieLegendTextColor||this.taskTextDarkColor,this.pieStrokeColor=this.pieStrokeColor||"black",this.pieStrokeWidth=this.pieStrokeWidth||"2px",this.pieOuterStrokeWidth=this.pieOuterStrokeWidth||"2px",this.pieOuterStrokeColor=this.pieOuterStrokeColor||"black",this.pieOpacity=this.pieOpacity||"0.7",this.radar={axisColor:(null==(e=this.radar)?void 0:e.axisColor)||this.lineColor,axisStrokeWidth:(null==(t=this.radar)?void 0:t.axisStrokeWidth)||2,axisLabelFontSize:(null==(r=this.radar)?void 0:r.axisLabelFontSize)||12,curveOpacity:(null==(n=this.radar)?void 0:n.curveOpacity)||.5,curveStrokeWidth:(null==(i=this.radar)?void 0:i.curveStrokeWidth)||2,graticuleColor:(null==(o=this.radar)?void 0:o.graticuleColor)||"#DEDEDE",graticuleStrokeWidth:(null==(a=this.radar)?void 0:a.graticuleStrokeWidth)||1,graticuleOpacity:(null==(s=this.radar)?void 0:s.graticuleOpacity)||.3,legendBoxSize:(null==(l=this.radar)?void 0:l.legendBoxSize)||12,legendFontSize:(null==(c=this.radar)?void 0:c.legendFontSize)||12},this.archEdgeColor=this.archEdgeColor||"#777",this.archEdgeArrowColor=this.archEdgeArrowColor||"#777",this.archEdgeWidth=this.archEdgeWidth||"3",this.archGroupBorderColor=this.archGroupBorderColor||"#000",this.archGroupBorderWidth=this.archGroupBorderWidth||"2px",this.quadrant1Fill=this.quadrant1Fill||this.primaryColor,this.quadrant2Fill=this.quadrant2Fill||Vu(this.primaryColor,{r:5,g:5,b:5}),this.quadrant3Fill=this.quadrant3Fill||Vu(this.primaryColor,{r:10,g:10,b:10}),this.quadrant4Fill=this.quadrant4Fill||Vu(this.primaryColor,{r:15,g:15,b:15}),this.quadrant1TextFill=this.quadrant1TextFill||this.primaryTextColor,this.quadrant2TextFill=this.quadrant2TextFill||Vu(this.primaryTextColor,{r:-5,g:-5,b:-5}),this.quadrant3TextFill=this.quadrant3TextFill||Vu(this.primaryTextColor,{r:-10,g:-10,b:-10}),this.quadrant4TextFill=this.quadrant4TextFill||Vu(this.primaryTextColor,{r:-15,g:-15,b:-15}),this.quadrantPointFill=this.quadrantPointFill||Fu(this.quadrant1Fill)?$u(this.quadrant1Fill):zu(this.quadrant1Fill),this.quadrantPointTextFill=this.quadrantPointTextFill||this.primaryTextColor,this.quadrantXAxisTextFill=this.quadrantXAxisTextFill||this.primaryTextColor,this.quadrantYAxisTextFill=this.quadrantYAxisTextFill||this.primaryTextColor,this.quadrantInternalBorderStrokeFill=this.quadrantInternalBorderStrokeFill||this.primaryBorderColor,this.quadrantExternalBorderStrokeFill=this.quadrantExternalBorderStrokeFill||this.primaryBorderColor,this.quadrantTitleFill=this.quadrantTitleFill||this.primaryTextColor,this.xyChart={backgroundColor:(null==(u=this.xyChart)?void 0:u.backgroundColor)||this.background,titleColor:(null==(h=this.xyChart)?void 0:h.titleColor)||this.primaryTextColor,xAxisTitleColor:(null==(d=this.xyChart)?void 0:d.xAxisTitleColor)||this.primaryTextColor,xAxisLabelColor:(null==(p=this.xyChart)?void 0:p.xAxisLabelColor)||this.primaryTextColor,xAxisTickColor:(null==(f=this.xyChart)?void 0:f.xAxisTickColor)||this.primaryTextColor,xAxisLineColor:(null==(g=this.xyChart)?void 0:g.xAxisLineColor)||this.primaryTextColor,yAxisTitleColor:(null==(m=this.xyChart)?void 0:m.yAxisTitleColor)||this.primaryTextColor,yAxisLabelColor:(null==(y=this.xyChart)?void 0:y.yAxisLabelColor)||this.primaryTextColor,yAxisTickColor:(null==(x=this.xyChart)?void 0:x.yAxisTickColor)||this.primaryTextColor,yAxisLineColor:(null==(b=this.xyChart)?void 0:b.yAxisLineColor)||this.primaryTextColor,plotColorPalette:(null==(v=this.xyChart)?void 0:v.plotColorPalette)||"#FFF4DD,#FFD8B1,#FFA07A,#ECEFF1,#D6DBDF,#C3E0A8,#FFB6A4,#FFD74D,#738FA7,#FFFFF0"},this.requirementBackground=this.requirementBackground||this.primaryColor,this.requirementBorderColor=this.requirementBorderColor||this.primaryBorderColor,this.requirementBorderSize=this.requirementBorderSize||"1",this.requirementTextColor=this.requirementTextColor||this.primaryTextColor,this.relationColor=this.relationColor||this.lineColor,this.relationLabelBackground=this.relationLabelBackground||(this.darkMode?zu(this.secondaryColor,30):this.secondaryColor),this.relationLabelColor=this.relationLabelColor||this.actorTextColor,this.git0=this.git0||this.primaryColor,this.git1=this.git1||this.secondaryColor,this.git2=this.git2||this.tertiaryColor,this.git3=this.git3||Vu(this.primaryColor,{h:-30}),this.git4=this.git4||Vu(this.primaryColor,{h:-60}),this.git5=this.git5||Vu(this.primaryColor,{h:-90}),this.git6=this.git6||Vu(this.primaryColor,{h:60}),this.git7=this.git7||Vu(this.primaryColor,{h:120}),this.darkMode?(this.git0=$u(this.git0,25),this.git1=$u(this.git1,25),this.git2=$u(this.git2,25),this.git3=$u(this.git3,25),this.git4=$u(this.git4,25),this.git5=$u(this.git5,25),this.git6=$u(this.git6,25),this.git7=$u(this.git7,25)):(this.git0=zu(this.git0,25),this.git1=zu(this.git1,25),this.git2=zu(this.git2,25),this.git3=zu(this.git3,25),this.git4=zu(this.git4,25),this.git5=zu(this.git5,25),this.git6=zu(this.git6,25),this.git7=zu(this.git7,25)),this.gitInv0=this.gitInv0||Wu(this.git0),this.gitInv1=this.gitInv1||Wu(this.git1),this.gitInv2=this.gitInv2||Wu(this.git2),this.gitInv3=this.gitInv3||Wu(this.git3),this.gitInv4=this.gitInv4||Wu(this.git4),this.gitInv5=this.gitInv5||Wu(this.git5),this.gitInv6=this.gitInv6||Wu(this.git6),this.gitInv7=this.gitInv7||Wu(this.git7),this.branchLabelColor=this.branchLabelColor||(this.darkMode?"black":this.labelTextColor),this.gitBranchLabel0=this.gitBranchLabel0||this.branchLabelColor,this.gitBranchLabel1=this.gitBranchLabel1||this.branchLabelColor,this.gitBranchLabel2=this.gitBranchLabel2||this.branchLabelColor,this.gitBranchLabel3=this.gitBranchLabel3||this.branchLabelColor,this.gitBranchLabel4=this.gitBranchLabel4||this.branchLabelColor,this.gitBranchLabel5=this.gitBranchLabel5||this.branchLabelColor,this.gitBranchLabel6=this.gitBranchLabel6||this.branchLabelColor,this.gitBranchLabel7=this.gitBranchLabel7||this.branchLabelColor,this.tagLabelColor=this.tagLabelColor||this.primaryTextColor,this.tagLabelBackground=this.tagLabelBackground||this.primaryColor,this.tagLabelBorder=this.tagBorder||this.primaryBorderColor,this.tagLabelFontSize=this.tagLabelFontSize||"10px",this.commitLabelColor=this.commitLabelColor||this.secondaryTextColor,this.commitLabelBackground=this.commitLabelBackground||this.secondaryColor,this.commitLabelFontSize=this.commitLabelFontSize||"10px",this.attributeBackgroundColorOdd=this.attributeBackgroundColorOdd||ad,this.attributeBackgroundColorEven=this.attributeBackgroundColorEven||sd}calculate(e){if("object"!=typeof e)return void this.updateColors();const t=Object.keys(e);t.forEach(t=>{this[t]=e[t]}),this.updateColors(),t.forEach(t=>{this[t]=e[t]})}},"Theme"),s),ud=mu(e=>{const t=new cd;return t.calculate(e),t},"getThemeVariables"),hd=(mu(l=class{constructor(){this.background="#333",this.primaryColor="#1f2020",this.secondaryColor=$u(this.primaryColor,16),this.tertiaryColor=Vu(this.primaryColor,{h:-160}),this.primaryBorderColor=Wu(this.background),this.secondaryBorderColor=ld(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=ld(this.tertiaryColor,this.darkMode),this.primaryTextColor=Wu(this.primaryColor),this.secondaryTextColor=Wu(this.secondaryColor),this.tertiaryTextColor=Wu(this.tertiaryColor),this.lineColor=Wu(this.background),this.textColor=Wu(this.background),this.mainBkg="#1f2020",this.secondBkg="calculated",this.mainContrastColor="lightgrey",this.darkTextColor=$u(Wu("#323D47"),10),this.lineColor="calculated",this.border1="#ccc",this.border2=Du(255,255,255,.25),this.arrowheadColor="calculated",this.fontFamily='"trebuchet ms", verdana, arial, sans-serif',this.fontSize="16px",this.labelBackground="#181818",this.textColor="#ccc",this.THEME_COLOR_LIMIT=12,this.nodeBkg="calculated",this.nodeBorder="calculated",this.clusterBkg="calculated",this.clusterBorder="calculated",this.defaultLinkColor="calculated",this.titleColor="#F9FFFE",this.edgeLabelBackground="calculated",this.actorBorder="calculated",this.actorBkg="calculated",this.actorTextColor="calculated",this.actorLineColor="calculated",this.signalColor="calculated",this.signalTextColor="calculated",this.labelBoxBkgColor="calculated",this.labelBoxBorderColor="calculated",this.labelTextColor="calculated",this.loopTextColor="calculated",this.noteBorderColor="calculated",this.noteBkgColor="#fff5ad",this.noteTextColor="calculated",this.activationBorderColor="calculated",this.activationBkgColor="calculated",this.sequenceNumberColor="black",this.sectionBkgColor=zu("#EAE8D9",30),this.altSectionBkgColor="calculated",this.sectionBkgColor2="#EAE8D9",this.excludeBkgColor=zu(this.sectionBkgColor,10),this.taskBorderColor=Du(255,255,255,70),this.taskBkgColor="calculated",this.taskTextColor="calculated",this.taskTextLightColor="calculated",this.taskTextOutsideColor="calculated",this.taskTextClickableColor="#003163",this.activeTaskBorderColor=Du(255,255,255,50),this.activeTaskBkgColor="#81B1DB",this.gridColor="calculated",this.doneTaskBkgColor="calculated",this.doneTaskBorderColor="grey",this.critBorderColor="#E83737",this.critBkgColor="#E83737",this.taskTextDarkColor="calculated",this.todayLineColor="#DB5757",this.vertLineColor="#00BFFF",this.personBorder=this.primaryBorderColor,this.personBkg=this.mainBkg,this.archEdgeColor="calculated",this.archEdgeArrowColor="calculated",this.archEdgeWidth="3",this.archGroupBorderColor=this.primaryBorderColor,this.archGroupBorderWidth="2px",this.rowOdd=this.rowOdd||$u(this.mainBkg,5)||"#ffffff",this.rowEven=this.rowEven||zu(this.mainBkg,10),this.labelColor="calculated",this.errorBkgColor="#a44141",this.errorTextColor="#ddd"}updateColors(){var e,t,r,n,i,o,a,s,l,c,u,h,d,p,f,g,m,y,x,b,v;this.secondBkg=$u(this.mainBkg,16),this.lineColor=this.mainContrastColor,this.arrowheadColor=this.mainContrastColor,this.nodeBkg=this.mainBkg,this.nodeBorder=this.border1,this.clusterBkg=this.secondBkg,this.clusterBorder=this.border2,this.defaultLinkColor=this.lineColor,this.edgeLabelBackground=$u(this.labelBackground,25),this.actorBorder=this.border1,this.actorBkg=this.mainBkg,this.actorTextColor=this.mainContrastColor,this.actorLineColor=this.actorBorder,this.signalColor=this.mainContrastColor,this.signalTextColor=this.mainContrastColor,this.labelBoxBkgColor=this.actorBkg,this.labelBoxBorderColor=this.actorBorder,this.labelTextColor=this.mainContrastColor,this.loopTextColor=this.mainContrastColor,this.noteBorderColor=this.secondaryBorderColor,this.noteBkgColor=this.secondBkg,this.noteTextColor=this.secondaryTextColor,this.activationBorderColor=this.border1,this.activationBkgColor=this.secondBkg,this.altSectionBkgColor=this.background,this.taskBkgColor=$u(this.mainBkg,23),this.taskTextColor=this.darkTextColor,this.taskTextLightColor=this.mainContrastColor,this.taskTextOutsideColor=this.taskTextLightColor,this.gridColor=this.mainContrastColor,this.doneTaskBkgColor=this.mainContrastColor,this.taskTextDarkColor=this.darkTextColor,this.archEdgeColor=this.lineColor,this.archEdgeArrowColor=this.lineColor,this.transitionColor=this.transitionColor||this.lineColor,this.transitionLabelColor=this.transitionLabelColor||this.textColor,this.stateLabelColor=this.stateLabelColor||this.stateBkg||this.primaryTextColor,this.stateBkg=this.stateBkg||this.mainBkg,this.labelBackgroundColor=this.labelBackgroundColor||this.stateBkg,this.compositeBackground=this.compositeBackground||this.background||this.tertiaryColor,this.altBackground=this.altBackground||"#555",this.compositeTitleBackground=this.compositeTitleBackground||this.mainBkg,this.compositeBorder=this.compositeBorder||this.nodeBorder,this.innerEndBackground=this.primaryBorderColor,this.specialStateColor="#f4f4f4",this.errorBkgColor=this.errorBkgColor||this.tertiaryColor,this.errorTextColor=this.errorTextColor||this.tertiaryTextColor,this.fillType0=this.primaryColor,this.fillType1=this.secondaryColor,this.fillType2=Vu(this.primaryColor,{h:64}),this.fillType3=Vu(this.secondaryColor,{h:64}),this.fillType4=Vu(this.primaryColor,{h:-64}),this.fillType5=Vu(this.secondaryColor,{h:-64}),this.fillType6=Vu(this.primaryColor,{h:128}),this.fillType7=Vu(this.secondaryColor,{h:128}),this.cScale1=this.cScale1||"#0b0000",this.cScale2=this.cScale2||"#4d1037",this.cScale3=this.cScale3||"#3f5258",this.cScale4=this.cScale4||"#4f2f1b",this.cScale5=this.cScale5||"#6e0a0a",this.cScale6=this.cScale6||"#3b0048",this.cScale7=this.cScale7||"#995a01",this.cScale8=this.cScale8||"#154706",this.cScale9=this.cScale9||"#161722",this.cScale10=this.cScale10||"#00296f",this.cScale11=this.cScale11||"#01629c",this.cScale12=this.cScale12||"#010029",this.cScale0=this.cScale0||this.primaryColor,this.cScale1=this.cScale1||this.secondaryColor,this.cScale2=this.cScale2||this.tertiaryColor,this.cScale3=this.cScale3||Vu(this.primaryColor,{h:30}),this.cScale4=this.cScale4||Vu(this.primaryColor,{h:60}),this.cScale5=this.cScale5||Vu(this.primaryColor,{h:90}),this.cScale6=this.cScale6||Vu(this.primaryColor,{h:120}),this.cScale7=this.cScale7||Vu(this.primaryColor,{h:150}),this.cScale8=this.cScale8||Vu(this.primaryColor,{h:210}),this.cScale9=this.cScale9||Vu(this.primaryColor,{h:270}),this.cScale10=this.cScale10||Vu(this.primaryColor,{h:300}),this.cScale11=this.cScale11||Vu(this.primaryColor,{h:330});for(let C=0;C<this.THEME_COLOR_LIMIT;C++)this["cScaleInv"+C]=this["cScaleInv"+C]||Wu(this["cScale"+C]);for(let C=0;C<this.THEME_COLOR_LIMIT;C++)this["cScalePeer"+C]=this["cScalePeer"+C]||$u(this["cScale"+C],10);for(let C=0;C<5;C++)this["surface"+C]=this["surface"+C]||Vu(this.mainBkg,{h:30,s:-30,l:-(4*C-10)}),this["surfacePeer"+C]=this["surfacePeer"+C]||Vu(this.mainBkg,{h:30,s:-30,l:-(4*C-7)});this.scaleLabelColor=this.scaleLabelColor||(this.darkMode?"black":this.labelTextColor);for(let C=0;C<this.THEME_COLOR_LIMIT;C++)this["cScaleLabel"+C]=this["cScaleLabel"+C]||this.scaleLabelColor;for(let C=0;C<this.THEME_COLOR_LIMIT;C++)this["pie"+C]=this["cScale"+C];this.pieTitleTextSize=this.pieTitleTextSize||"25px",this.pieTitleTextColor=this.pieTitleTextColor||this.taskTextDarkColor,this.pieSectionTextSize=this.pieSectionTextSize||"17px",this.pieSectionTextColor=this.pieSectionTextColor||this.textColor,this.pieLegendTextSize=this.pieLegendTextSize||"17px",this.pieLegendTextColor=this.pieLegendTextColor||this.taskTextDarkColor,this.pieStrokeColor=this.pieStrokeColor||"black",this.pieStrokeWidth=this.pieStrokeWidth||"2px",this.pieOuterStrokeWidth=this.pieOuterStrokeWidth||"2px",this.pieOuterStrokeColor=this.pieOuterStrokeColor||"black",this.pieOpacity=this.pieOpacity||"0.7",this.quadrant1Fill=this.quadrant1Fill||this.primaryColor,this.quadrant2Fill=this.quadrant2Fill||Vu(this.primaryColor,{r:5,g:5,b:5}),this.quadrant3Fill=this.quadrant3Fill||Vu(this.primaryColor,{r:10,g:10,b:10}),this.quadrant4Fill=this.quadrant4Fill||Vu(this.primaryColor,{r:15,g:15,b:15}),this.quadrant1TextFill=this.quadrant1TextFill||this.primaryTextColor,this.quadrant2TextFill=this.quadrant2TextFill||Vu(this.primaryTextColor,{r:-5,g:-5,b:-5}),this.quadrant3TextFill=this.quadrant3TextFill||Vu(this.primaryTextColor,{r:-10,g:-10,b:-10}),this.quadrant4TextFill=this.quadrant4TextFill||Vu(this.primaryTextColor,{r:-15,g:-15,b:-15}),this.quadrantPointFill=this.quadrantPointFill||Fu(this.quadrant1Fill)?$u(this.quadrant1Fill):zu(this.quadrant1Fill),this.quadrantPointTextFill=this.quadrantPointTextFill||this.primaryTextColor,this.quadrantXAxisTextFill=this.quadrantXAxisTextFill||this.primaryTextColor,this.quadrantYAxisTextFill=this.quadrantYAxisTextFill||this.primaryTextColor,this.quadrantInternalBorderStrokeFill=this.quadrantInternalBorderStrokeFill||this.primaryBorderColor,this.quadrantExternalBorderStrokeFill=this.quadrantExternalBorderStrokeFill||this.primaryBorderColor,this.quadrantTitleFill=this.quadrantTitleFill||this.primaryTextColor,this.xyChart={backgroundColor:(null==(e=this.xyChart)?void 0:e.backgroundColor)||this.background,titleColor:(null==(t=this.xyChart)?void 0:t.titleColor)||this.primaryTextColor,xAxisTitleColor:(null==(r=this.xyChart)?void 0:r.xAxisTitleColor)||this.primaryTextColor,xAxisLabelColor:(null==(n=this.xyChart)?void 0:n.xAxisLabelColor)||this.primaryTextColor,xAxisTickColor:(null==(i=this.xyChart)?void 0:i.xAxisTickColor)||this.primaryTextColor,xAxisLineColor:(null==(o=this.xyChart)?void 0:o.xAxisLineColor)||this.primaryTextColor,yAxisTitleColor:(null==(a=this.xyChart)?void 0:a.yAxisTitleColor)||this.primaryTextColor,yAxisLabelColor:(null==(s=this.xyChart)?void 0:s.yAxisLabelColor)||this.primaryTextColor,yAxisTickColor:(null==(l=this.xyChart)?void 0:l.yAxisTickColor)||this.primaryTextColor,yAxisLineColor:(null==(c=this.xyChart)?void 0:c.yAxisLineColor)||this.primaryTextColor,plotColorPalette:(null==(u=this.xyChart)?void 0:u.plotColorPalette)||"#3498db,#2ecc71,#e74c3c,#f1c40f,#bdc3c7,#ffffff,#34495e,#9b59b6,#1abc9c,#e67e22"},this.packet={startByteColor:this.primaryTextColor,endByteColor:this.primaryTextColor,labelColor:this.primaryTextColor,titleColor:this.primaryTextColor,blockStrokeColor:this.primaryTextColor,blockFillColor:this.background},this.radar={axisColor:(null==(h=this.radar)?void 0:h.axisColor)||this.lineColor,axisStrokeWidth:(null==(d=this.radar)?void 0:d.axisStrokeWidth)||2,axisLabelFontSize:(null==(p=this.radar)?void 0:p.axisLabelFontSize)||12,curveOpacity:(null==(f=this.radar)?void 0:f.curveOpacity)||.5,curveStrokeWidth:(null==(g=this.radar)?void 0:g.curveStrokeWidth)||2,graticuleColor:(null==(m=this.radar)?void 0:m.graticuleColor)||"#DEDEDE",graticuleStrokeWidth:(null==(y=this.radar)?void 0:y.graticuleStrokeWidth)||1,graticuleOpacity:(null==(x=this.radar)?void 0:x.graticuleOpacity)||.3,legendBoxSize:(null==(b=this.radar)?void 0:b.legendBoxSize)||12,legendFontSize:(null==(v=this.radar)?void 0:v.legendFontSize)||12},this.classText=this.primaryTextColor,this.requirementBackground=this.requirementBackground||this.primaryColor,this.requirementBorderColor=this.requirementBorderColor||this.primaryBorderColor,this.requirementBorderSize=this.requirementBorderSize||"1",this.requirementTextColor=this.requirementTextColor||this.primaryTextColor,this.relationColor=this.relationColor||this.lineColor,this.relationLabelBackground=this.relationLabelBackground||(this.darkMode?zu(this.secondaryColor,30):this.secondaryColor),this.relationLabelColor=this.relationLabelColor||this.actorTextColor,this.git0=$u(this.secondaryColor,20),this.git1=$u(this.pie2||this.secondaryColor,20),this.git2=$u(this.pie3||this.tertiaryColor,20),this.git3=$u(this.pie4||Vu(this.primaryColor,{h:-30}),20),this.git4=$u(this.pie5||Vu(this.primaryColor,{h:-60}),20),this.git5=$u(this.pie6||Vu(this.primaryColor,{h:-90}),10),this.git6=$u(this.pie7||Vu(this.primaryColor,{h:60}),10),this.git7=$u(this.pie8||Vu(this.primaryColor,{h:120}),20),this.gitInv0=this.gitInv0||Wu(this.git0),this.gitInv1=this.gitInv1||Wu(this.git1),this.gitInv2=this.gitInv2||Wu(this.git2),this.gitInv3=this.gitInv3||Wu(this.git3),this.gitInv4=this.gitInv4||Wu(this.git4),this.gitInv5=this.gitInv5||Wu(this.git5),this.gitInv6=this.gitInv6||Wu(this.git6),this.gitInv7=this.gitInv7||Wu(this.git7),this.gitBranchLabel0=this.gitBranchLabel0||Wu(this.labelTextColor),this.gitBranchLabel1=this.gitBranchLabel1||this.labelTextColor,this.gitBranchLabel2=this.gitBranchLabel2||this.labelTextColor,this.gitBranchLabel3=this.gitBranchLabel3||Wu(this.labelTextColor),this.gitBranchLabel4=this.gitBranchLabel4||this.labelTextColor,this.gitBranchLabel5=this.gitBranchLabel5||this.labelTextColor,this.gitBranchLabel6=this.gitBranchLabel6||this.labelTextColor,this.gitBranchLabel7=this.gitBranchLabel7||this.labelTextColor,this.tagLabelColor=this.tagLabelColor||this.primaryTextColor,this.tagLabelBackground=this.tagLabelBackground||this.primaryColor,this.tagLabelBorder=this.tagBorder||this.primaryBorderColor,this.tagLabelFontSize=this.tagLabelFontSize||"10px",this.commitLabelColor=this.commitLabelColor||this.secondaryTextColor,this.commitLabelBackground=this.commitLabelBackground||this.secondaryColor,this.commitLabelFontSize=this.commitLabelFontSize||"10px",this.attributeBackgroundColorOdd=this.attributeBackgroundColorOdd||$u(this.background,12),this.attributeBackgroundColorEven=this.attributeBackgroundColorEven||$u(this.background,2),this.nodeBorder=this.nodeBorder||"#999"}calculate(e){if("object"!=typeof e)return void this.updateColors();const t=Object.keys(e);t.forEach(t=>{this[t]=e[t]}),this.updateColors(),t.forEach(t=>{this[t]=e[t]})}},"Theme"),l),dd=mu(e=>{const t=new hd;return t.calculate(e),t},"getThemeVariables"),pd=(mu(c=class{constructor(){this.background="#f4f4f4",this.primaryColor="#ECECFF",this.secondaryColor=Vu(this.primaryColor,{h:120}),this.secondaryColor="#ffffde",this.tertiaryColor=Vu(this.primaryColor,{h:-160}),this.primaryBorderColor=ld(this.primaryColor,this.darkMode),this.secondaryBorderColor=ld(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=ld(this.tertiaryColor,this.darkMode),this.primaryTextColor=Wu(this.primaryColor),this.secondaryTextColor=Wu(this.secondaryColor),this.tertiaryTextColor=Wu(this.tertiaryColor),this.lineColor=Wu(this.background),this.textColor=Wu(this.background),this.background="white",this.mainBkg="#ECECFF",this.secondBkg="#ffffde",this.lineColor="#333333",this.border1="#9370DB",this.border2="#aaaa33",this.arrowheadColor="#333333",this.fontFamily='"trebuchet ms", verdana, arial, sans-serif',this.fontSize="16px",this.labelBackground="rgba(232,232,232, 0.8)",this.textColor="#333",this.THEME_COLOR_LIMIT=12,this.nodeBkg="calculated",this.nodeBorder="calculated",this.clusterBkg="calculated",this.clusterBorder="calculated",this.defaultLinkColor="calculated",this.titleColor="calculated",this.edgeLabelBackground="calculated",this.actorBorder="calculated",this.actorBkg="calculated",this.actorTextColor="black",this.actorLineColor="calculated",this.signalColor="calculated",this.signalTextColor="calculated",this.labelBoxBkgColor="calculated",this.labelBoxBorderColor="calculated",this.labelTextColor="calculated",this.loopTextColor="calculated",this.noteBorderColor="calculated",this.noteBkgColor="#fff5ad",this.noteTextColor="calculated",this.activationBorderColor="#666",this.activationBkgColor="#f4f4f4",this.sequenceNumberColor="white",this.sectionBkgColor="calculated",this.altSectionBkgColor="calculated",this.sectionBkgColor2="calculated",this.excludeBkgColor="#eeeeee",this.taskBorderColor="calculated",this.taskBkgColor="calculated",this.taskTextLightColor="calculated",this.taskTextColor=this.taskTextLightColor,this.taskTextDarkColor="calculated",this.taskTextOutsideColor=this.taskTextDarkColor,this.taskTextClickableColor="calculated",this.activeTaskBorderColor="calculated",this.activeTaskBkgColor="calculated",this.gridColor="calculated",this.doneTaskBkgColor="calculated",this.doneTaskBorderColor="calculated",this.critBorderColor="calculated",this.critBkgColor="calculated",this.todayLineColor="calculated",this.vertLineColor="calculated",this.sectionBkgColor=Du(102,102,255,.49),this.altSectionBkgColor="white",this.sectionBkgColor2="#fff400",this.taskBorderColor="#534fbc",this.taskBkgColor="#8a90dd",this.taskTextLightColor="white",this.taskTextColor="calculated",this.taskTextDarkColor="black",this.taskTextOutsideColor="calculated",this.taskTextClickableColor="#003163",this.activeTaskBorderColor="#534fbc",this.activeTaskBkgColor="#bfc7ff",this.gridColor="lightgrey",this.doneTaskBkgColor="lightgrey",this.doneTaskBorderColor="grey",this.critBorderColor="#ff8888",this.critBkgColor="red",this.todayLineColor="red",this.vertLineColor="navy",this.personBorder=this.primaryBorderColor,this.personBkg=this.mainBkg,this.archEdgeColor="calculated",this.archEdgeArrowColor="calculated",this.archEdgeWidth="3",this.archGroupBorderColor=this.primaryBorderColor,this.archGroupBorderWidth="2px",this.rowOdd="calculated",this.rowEven="calculated",this.labelColor="black",this.errorBkgColor="#552222",this.errorTextColor="#552222",this.updateColors()}updateColors(){var e,t,r,n,i,o,a,s,l,c,u,h,d,p,f,g,m,y,x,b,v;this.cScale0=this.cScale0||this.primaryColor,this.cScale1=this.cScale1||this.secondaryColor,this.cScale2=this.cScale2||this.tertiaryColor,this.cScale3=this.cScale3||Vu(this.primaryColor,{h:30}),this.cScale4=this.cScale4||Vu(this.primaryColor,{h:60}),this.cScale5=this.cScale5||Vu(this.primaryColor,{h:90}),this.cScale6=this.cScale6||Vu(this.primaryColor,{h:120}),this.cScale7=this.cScale7||Vu(this.primaryColor,{h:150}),this.cScale8=this.cScale8||Vu(this.primaryColor,{h:210}),this.cScale9=this.cScale9||Vu(this.primaryColor,{h:270}),this.cScale10=this.cScale10||Vu(this.primaryColor,{h:300}),this.cScale11=this.cScale11||Vu(this.primaryColor,{h:330}),this.cScalePeer1=this.cScalePeer1||zu(this.secondaryColor,45),this.cScalePeer2=this.cScalePeer2||zu(this.tertiaryColor,40);for(let C=0;C<this.THEME_COLOR_LIMIT;C++)this["cScale"+C]=zu(this["cScale"+C],10),this["cScalePeer"+C]=this["cScalePeer"+C]||zu(this["cScale"+C],25);for(let C=0;C<this.THEME_COLOR_LIMIT;C++)this["cScaleInv"+C]=this["cScaleInv"+C]||Vu(this["cScale"+C],{h:180});for(let C=0;C<5;C++)this["surface"+C]=this["surface"+C]||Vu(this.mainBkg,{h:30,l:-(5+5*C)}),this["surfacePeer"+C]=this["surfacePeer"+C]||Vu(this.mainBkg,{h:30,l:-(7+5*C)});if(this.scaleLabelColor="calculated"!==this.scaleLabelColor&&this.scaleLabelColor?this.scaleLabelColor:this.labelTextColor,"calculated"!==this.labelTextColor){this.cScaleLabel0=this.cScaleLabel0||Wu(this.labelTextColor),this.cScaleLabel3=this.cScaleLabel3||Wu(this.labelTextColor);for(let e=0;e<this.THEME_COLOR_LIMIT;e++)this["cScaleLabel"+e]=this["cScaleLabel"+e]||this.labelTextColor}this.nodeBkg=this.mainBkg,this.nodeBorder=this.border1,this.clusterBkg=this.secondBkg,this.clusterBorder=this.border2,this.defaultLinkColor=this.lineColor,this.titleColor=this.textColor,this.edgeLabelBackground=this.labelBackground,this.actorBorder=$u(this.border1,23),this.actorBkg=this.mainBkg,this.labelBoxBkgColor=this.actorBkg,this.signalColor=this.textColor,this.signalTextColor=this.textColor,this.labelBoxBorderColor=this.actorBorder,this.labelTextColor=this.actorTextColor,this.loopTextColor=this.actorTextColor,this.noteBorderColor=this.border2,this.noteTextColor=this.actorTextColor,this.actorLineColor=this.actorBorder,this.taskTextColor=this.taskTextLightColor,this.taskTextOutsideColor=this.taskTextDarkColor,this.archEdgeColor=this.lineColor,this.archEdgeArrowColor=this.lineColor,this.rowOdd=this.rowOdd||$u(this.primaryColor,75)||"#ffffff",this.rowEven=this.rowEven||$u(this.primaryColor,1),this.transitionColor=this.transitionColor||this.lineColor,this.transitionLabelColor=this.transitionLabelColor||this.textColor,this.stateLabelColor=this.stateLabelColor||this.stateBkg||this.primaryTextColor,this.stateBkg=this.stateBkg||this.mainBkg,this.labelBackgroundColor=this.labelBackgroundColor||this.stateBkg,this.compositeBackground=this.compositeBackground||this.background||this.tertiaryColor,this.altBackground=this.altBackground||"#f0f0f0",this.compositeTitleBackground=this.compositeTitleBackground||this.mainBkg,this.compositeBorder=this.compositeBorder||this.nodeBorder,this.innerEndBackground=this.nodeBorder,this.specialStateColor=this.lineColor,this.errorBkgColor=this.errorBkgColor||this.tertiaryColor,this.errorTextColor=this.errorTextColor||this.tertiaryTextColor,this.transitionColor=this.transitionColor||this.lineColor,this.classText=this.primaryTextColor,this.fillType0=this.primaryColor,this.fillType1=this.secondaryColor,this.fillType2=Vu(this.primaryColor,{h:64}),this.fillType3=Vu(this.secondaryColor,{h:64}),this.fillType4=Vu(this.primaryColor,{h:-64}),this.fillType5=Vu(this.secondaryColor,{h:-64}),this.fillType6=Vu(this.primaryColor,{h:128}),this.fillType7=Vu(this.secondaryColor,{h:128}),this.pie1=this.pie1||this.primaryColor,this.pie2=this.pie2||this.secondaryColor,this.pie3=this.pie3||Vu(this.tertiaryColor,{l:-40}),this.pie4=this.pie4||Vu(this.primaryColor,{l:-10}),this.pie5=this.pie5||Vu(this.secondaryColor,{l:-30}),this.pie6=this.pie6||Vu(this.tertiaryColor,{l:-20}),this.pie7=this.pie7||Vu(this.primaryColor,{h:60,l:-20}),this.pie8=this.pie8||Vu(this.primaryColor,{h:-60,l:-40}),this.pie9=this.pie9||Vu(this.primaryColor,{h:120,l:-40}),this.pie10=this.pie10||Vu(this.primaryColor,{h:60,l:-40}),this.pie11=this.pie11||Vu(this.primaryColor,{h:-90,l:-40}),this.pie12=this.pie12||Vu(this.primaryColor,{h:120,l:-30}),this.pieTitleTextSize=this.pieTitleTextSize||"25px",this.pieTitleTextColor=this.pieTitleTextColor||this.taskTextDarkColor,this.pieSectionTextSize=this.pieSectionTextSize||"17px",this.pieSectionTextColor=this.pieSectionTextColor||this.textColor,this.pieLegendTextSize=this.pieLegendTextSize||"17px",this.pieLegendTextColor=this.pieLegendTextColor||this.taskTextDarkColor,this.pieStrokeColor=this.pieStrokeColor||"black",this.pieStrokeWidth=this.pieStrokeWidth||"2px",this.pieOuterStrokeWidth=this.pieOuterStrokeWidth||"2px",this.pieOuterStrokeColor=this.pieOuterStrokeColor||"black",this.pieOpacity=this.pieOpacity||"0.7",this.quadrant1Fill=this.quadrant1Fill||this.primaryColor,this.quadrant2Fill=this.quadrant2Fill||Vu(this.primaryColor,{r:5,g:5,b:5}),this.quadrant3Fill=this.quadrant3Fill||Vu(this.primaryColor,{r:10,g:10,b:10}),this.quadrant4Fill=this.quadrant4Fill||Vu(this.primaryColor,{r:15,g:15,b:15}),this.quadrant1TextFill=this.quadrant1TextFill||this.primaryTextColor,this.quadrant2TextFill=this.quadrant2TextFill||Vu(this.primaryTextColor,{r:-5,g:-5,b:-5}),this.quadrant3TextFill=this.quadrant3TextFill||Vu(this.primaryTextColor,{r:-10,g:-10,b:-10}),this.quadrant4TextFill=this.quadrant4TextFill||Vu(this.primaryTextColor,{r:-15,g:-15,b:-15}),this.quadrantPointFill=this.quadrantPointFill||Fu(this.quadrant1Fill)?$u(this.quadrant1Fill):zu(this.quadrant1Fill),this.quadrantPointTextFill=this.quadrantPointTextFill||this.primaryTextColor,this.quadrantXAxisTextFill=this.quadrantXAxisTextFill||this.primaryTextColor,this.quadrantYAxisTextFill=this.quadrantYAxisTextFill||this.primaryTextColor,this.quadrantInternalBorderStrokeFill=this.quadrantInternalBorderStrokeFill||this.primaryBorderColor,this.quadrantExternalBorderStrokeFill=this.quadrantExternalBorderStrokeFill||this.primaryBorderColor,this.quadrantTitleFill=this.quadrantTitleFill||this.primaryTextColor,this.radar={axisColor:(null==(e=this.radar)?void 0:e.axisColor)||this.lineColor,axisStrokeWidth:(null==(t=this.radar)?void 0:t.axisStrokeWidth)||2,axisLabelFontSize:(null==(r=this.radar)?void 0:r.axisLabelFontSize)||12,curveOpacity:(null==(n=this.radar)?void 0:n.curveOpacity)||.5,curveStrokeWidth:(null==(i=this.radar)?void 0:i.curveStrokeWidth)||2,graticuleColor:(null==(o=this.radar)?void 0:o.graticuleColor)||"#DEDEDE",graticuleStrokeWidth:(null==(a=this.radar)?void 0:a.graticuleStrokeWidth)||1,graticuleOpacity:(null==(s=this.radar)?void 0:s.graticuleOpacity)||.3,legendBoxSize:(null==(l=this.radar)?void 0:l.legendBoxSize)||12,legendFontSize:(null==(c=this.radar)?void 0:c.legendFontSize)||12},this.xyChart={backgroundColor:(null==(u=this.xyChart)?void 0:u.backgroundColor)||this.background,titleColor:(null==(h=this.xyChart)?void 0:h.titleColor)||this.primaryTextColor,xAxisTitleColor:(null==(d=this.xyChart)?void 0:d.xAxisTitleColor)||this.primaryTextColor,xAxisLabelColor:(null==(p=this.xyChart)?void 0:p.xAxisLabelColor)||this.primaryTextColor,xAxisTickColor:(null==(f=this.xyChart)?void 0:f.xAxisTickColor)||this.primaryTextColor,xAxisLineColor:(null==(g=this.xyChart)?void 0:g.xAxisLineColor)||this.primaryTextColor,yAxisTitleColor:(null==(m=this.xyChart)?void 0:m.yAxisTitleColor)||this.primaryTextColor,yAxisLabelColor:(null==(y=this.xyChart)?void 0:y.yAxisLabelColor)||this.primaryTextColor,yAxisTickColor:(null==(x=this.xyChart)?void 0:x.yAxisTickColor)||this.primaryTextColor,yAxisLineColor:(null==(b=this.xyChart)?void 0:b.yAxisLineColor)||this.primaryTextColor,plotColorPalette:(null==(v=this.xyChart)?void 0:v.plotColorPalette)||"#ECECFF,#8493A6,#FFC3A0,#DCDDE1,#B8E994,#D1A36F,#C3CDE6,#FFB6C1,#496078,#F8F3E3"},this.requirementBackground=this.requirementBackground||this.primaryColor,this.requirementBorderColor=this.requirementBorderColor||this.primaryBorderColor,this.requirementBorderSize=this.requirementBorderSize||"1",this.requirementTextColor=this.requirementTextColor||this.primaryTextColor,this.relationColor=this.relationColor||this.lineColor,this.relationLabelBackground=this.relationLabelBackground||this.labelBackground,this.relationLabelColor=this.relationLabelColor||this.actorTextColor,this.git0=this.git0||this.primaryColor,this.git1=this.git1||this.secondaryColor,this.git2=this.git2||this.tertiaryColor,this.git3=this.git3||Vu(this.primaryColor,{h:-30}),this.git4=this.git4||Vu(this.primaryColor,{h:-60}),this.git5=this.git5||Vu(this.primaryColor,{h:-90}),this.git6=this.git6||Vu(this.primaryColor,{h:60}),this.git7=this.git7||Vu(this.primaryColor,{h:120}),this.darkMode?(this.git0=$u(this.git0,25),this.git1=$u(this.git1,25),this.git2=$u(this.git2,25),this.git3=$u(this.git3,25),this.git4=$u(this.git4,25),this.git5=$u(this.git5,25),this.git6=$u(this.git6,25),this.git7=$u(this.git7,25)):(this.git0=zu(this.git0,25),this.git1=zu(this.git1,25),this.git2=zu(this.git2,25),this.git3=zu(this.git3,25),this.git4=zu(this.git4,25),this.git5=zu(this.git5,25),this.git6=zu(this.git6,25),this.git7=zu(this.git7,25)),this.gitInv0=this.gitInv0||zu(Wu(this.git0),25),this.gitInv1=this.gitInv1||Wu(this.git1),this.gitInv2=this.gitInv2||Wu(this.git2),this.gitInv3=this.gitInv3||Wu(this.git3),this.gitInv4=this.gitInv4||Wu(this.git4),this.gitInv5=this.gitInv5||Wu(this.git5),this.gitInv6=this.gitInv6||Wu(this.git6),this.gitInv7=this.gitInv7||Wu(this.git7),this.gitBranchLabel0=this.gitBranchLabel0||Wu(this.labelTextColor),this.gitBranchLabel1=this.gitBranchLabel1||this.labelTextColor,this.gitBranchLabel2=this.gitBranchLabel2||this.labelTextColor,this.gitBranchLabel3=this.gitBranchLabel3||Wu(this.labelTextColor),this.gitBranchLabel4=this.gitBranchLabel4||this.labelTextColor,this.gitBranchLabel5=this.gitBranchLabel5||this.labelTextColor,this.gitBranchLabel6=this.gitBranchLabel6||this.labelTextColor,this.gitBranchLabel7=this.gitBranchLabel7||this.labelTextColor,this.tagLabelColor=this.tagLabelColor||this.primaryTextColor,this.tagLabelBackground=this.tagLabelBackground||this.primaryColor,this.tagLabelBorder=this.tagBorder||this.primaryBorderColor,this.tagLabelFontSize=this.tagLabelFontSize||"10px",this.commitLabelColor=this.commitLabelColor||this.secondaryTextColor,this.commitLabelBackground=this.commitLabelBackground||this.secondaryColor,this.commitLabelFontSize=this.commitLabelFontSize||"10px",this.attributeBackgroundColorOdd=this.attributeBackgroundColorOdd||ad,this.attributeBackgroundColorEven=this.attributeBackgroundColorEven||sd}calculate(e){if(Object.keys(this).forEach(e=>{"calculated"===this[e]&&(this[e]=void 0)}),"object"!=typeof e)return void this.updateColors();const t=Object.keys(e);t.forEach(t=>{this[t]=e[t]}),this.updateColors(),t.forEach(t=>{this[t]=e[t]})}},"Theme"),c),fd=mu(e=>{const t=new pd;return t.calculate(e),t},"getThemeVariables"),gd=(mu(u=class{constructor(){this.background="#f4f4f4",this.primaryColor="#cde498",this.secondaryColor="#cdffb2",this.background="white",this.mainBkg="#cde498",this.secondBkg="#cdffb2",this.lineColor="green",this.border1="#13540c",this.border2="#6eaa49",this.arrowheadColor="green",this.fontFamily='"trebuchet ms", verdana, arial, sans-serif',this.fontSize="16px",this.tertiaryColor=$u("#cde498",10),this.primaryBorderColor=ld(this.primaryColor,this.darkMode),this.secondaryBorderColor=ld(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=ld(this.tertiaryColor,this.darkMode),this.primaryTextColor=Wu(this.primaryColor),this.secondaryTextColor=Wu(this.secondaryColor),this.tertiaryTextColor=Wu(this.primaryColor),this.lineColor=Wu(this.background),this.textColor=Wu(this.background),this.THEME_COLOR_LIMIT=12,this.nodeBkg="calculated",this.nodeBorder="calculated",this.clusterBkg="calculated",this.clusterBorder="calculated",this.defaultLinkColor="calculated",this.titleColor="#333",this.edgeLabelBackground="#e8e8e8",this.actorBorder="calculated",this.actorBkg="calculated",this.actorTextColor="black",this.actorLineColor="calculated",this.signalColor="#333",this.signalTextColor="#333",this.labelBoxBkgColor="calculated",this.labelBoxBorderColor="#326932",this.labelTextColor="calculated",this.loopTextColor="calculated",this.noteBorderColor="calculated",this.noteBkgColor="#fff5ad",this.noteTextColor="calculated",this.activationBorderColor="#666",this.activationBkgColor="#f4f4f4",this.sequenceNumberColor="white",this.sectionBkgColor="#6eaa49",this.altSectionBkgColor="white",this.sectionBkgColor2="#6eaa49",this.excludeBkgColor="#eeeeee",this.taskBorderColor="calculated",this.taskBkgColor="#487e3a",this.taskTextLightColor="white",this.taskTextColor="calculated",this.taskTextDarkColor="black",this.taskTextOutsideColor="calculated",this.taskTextClickableColor="#003163",this.activeTaskBorderColor="calculated",this.activeTaskBkgColor="calculated",this.gridColor="lightgrey",this.doneTaskBkgColor="lightgrey",this.doneTaskBorderColor="grey",this.critBorderColor="#ff8888",this.critBkgColor="red",this.todayLineColor="red",this.vertLineColor="#00BFFF",this.personBorder=this.primaryBorderColor,this.personBkg=this.mainBkg,this.archEdgeColor="calculated",this.archEdgeArrowColor="calculated",this.archEdgeWidth="3",this.archGroupBorderColor=this.primaryBorderColor,this.archGroupBorderWidth="2px",this.labelColor="black",this.errorBkgColor="#552222",this.errorTextColor="#552222"}updateColors(){var e,t,r,n,i,o,a,s,l,c,u,h,d,p,f,g,m,y,x,b,v;this.actorBorder=zu(this.mainBkg,20),this.actorBkg=this.mainBkg,this.labelBoxBkgColor=this.actorBkg,this.labelTextColor=this.actorTextColor,this.loopTextColor=this.actorTextColor,this.noteBorderColor=this.border2,this.noteTextColor=this.actorTextColor,this.actorLineColor=this.actorBorder,this.cScale0=this.cScale0||this.primaryColor,this.cScale1=this.cScale1||this.secondaryColor,this.cScale2=this.cScale2||this.tertiaryColor,this.cScale3=this.cScale3||Vu(this.primaryColor,{h:30}),this.cScale4=this.cScale4||Vu(this.primaryColor,{h:60}),this.cScale5=this.cScale5||Vu(this.primaryColor,{h:90}),this.cScale6=this.cScale6||Vu(this.primaryColor,{h:120}),this.cScale7=this.cScale7||Vu(this.primaryColor,{h:150}),this.cScale8=this.cScale8||Vu(this.primaryColor,{h:210}),this.cScale9=this.cScale9||Vu(this.primaryColor,{h:270}),this.cScale10=this.cScale10||Vu(this.primaryColor,{h:300}),this.cScale11=this.cScale11||Vu(this.primaryColor,{h:330}),this.cScalePeer1=this.cScalePeer1||zu(this.secondaryColor,45),this.cScalePeer2=this.cScalePeer2||zu(this.tertiaryColor,40);for(let C=0;C<this.THEME_COLOR_LIMIT;C++)this["cScale"+C]=zu(this["cScale"+C],10),this["cScalePeer"+C]=this["cScalePeer"+C]||zu(this["cScale"+C],25);for(let C=0;C<this.THEME_COLOR_LIMIT;C++)this["cScaleInv"+C]=this["cScaleInv"+C]||Vu(this["cScale"+C],{h:180});this.scaleLabelColor="calculated"!==this.scaleLabelColor&&this.scaleLabelColor?this.scaleLabelColor:this.labelTextColor;for(let C=0;C<this.THEME_COLOR_LIMIT;C++)this["cScaleLabel"+C]=this["cScaleLabel"+C]||this.scaleLabelColor;for(let C=0;C<5;C++)this["surface"+C]=this["surface"+C]||Vu(this.mainBkg,{h:30,s:-30,l:-(5+5*C)}),this["surfacePeer"+C]=this["surfacePeer"+C]||Vu(this.mainBkg,{h:30,s:-30,l:-(8+5*C)});this.nodeBkg=this.mainBkg,this.nodeBorder=this.border1,this.clusterBkg=this.secondBkg,this.clusterBorder=this.border2,this.defaultLinkColor=this.lineColor,this.taskBorderColor=this.border1,this.taskTextColor=this.taskTextLightColor,this.taskTextOutsideColor=this.taskTextDarkColor,this.activeTaskBorderColor=this.taskBorderColor,this.activeTaskBkgColor=this.mainBkg,this.archEdgeColor=this.lineColor,this.archEdgeArrowColor=this.lineColor,this.rowOdd=this.rowOdd||$u(this.mainBkg,75)||"#ffffff",this.rowEven=this.rowEven||$u(this.mainBkg,20),this.transitionColor=this.transitionColor||this.lineColor,this.transitionLabelColor=this.transitionLabelColor||this.textColor,this.stateLabelColor=this.stateLabelColor||this.stateBkg||this.primaryTextColor,this.stateBkg=this.stateBkg||this.mainBkg,this.labelBackgroundColor=this.labelBackgroundColor||this.stateBkg,this.compositeBackground=this.compositeBackground||this.background||this.tertiaryColor,this.altBackground=this.altBackground||"#f0f0f0",this.compositeTitleBackground=this.compositeTitleBackground||this.mainBkg,this.compositeBorder=this.compositeBorder||this.nodeBorder,this.innerEndBackground=this.primaryBorderColor,this.specialStateColor=this.lineColor,this.errorBkgColor=this.errorBkgColor||this.tertiaryColor,this.errorTextColor=this.errorTextColor||this.tertiaryTextColor,this.transitionColor=this.transitionColor||this.lineColor,this.classText=this.primaryTextColor,this.fillType0=this.primaryColor,this.fillType1=this.secondaryColor,this.fillType2=Vu(this.primaryColor,{h:64}),this.fillType3=Vu(this.secondaryColor,{h:64}),this.fillType4=Vu(this.primaryColor,{h:-64}),this.fillType5=Vu(this.secondaryColor,{h:-64}),this.fillType6=Vu(this.primaryColor,{h:128}),this.fillType7=Vu(this.secondaryColor,{h:128}),this.pie1=this.pie1||this.primaryColor,this.pie2=this.pie2||this.secondaryColor,this.pie3=this.pie3||this.tertiaryColor,this.pie4=this.pie4||Vu(this.primaryColor,{l:-30}),this.pie5=this.pie5||Vu(this.secondaryColor,{l:-30}),this.pie6=this.pie6||Vu(this.tertiaryColor,{h:40,l:-40}),this.pie7=this.pie7||Vu(this.primaryColor,{h:60,l:-10}),this.pie8=this.pie8||Vu(this.primaryColor,{h:-60,l:-10}),this.pie9=this.pie9||Vu(this.primaryColor,{h:120,l:0}),this.pie10=this.pie10||Vu(this.primaryColor,{h:60,l:-50}),this.pie11=this.pie11||Vu(this.primaryColor,{h:-60,l:-50}),this.pie12=this.pie12||Vu(this.primaryColor,{h:120,l:-50}),this.pieTitleTextSize=this.pieTitleTextSize||"25px",this.pieTitleTextColor=this.pieTitleTextColor||this.taskTextDarkColor,this.pieSectionTextSize=this.pieSectionTextSize||"17px",this.pieSectionTextColor=this.pieSectionTextColor||this.textColor,this.pieLegendTextSize=this.pieLegendTextSize||"17px",this.pieLegendTextColor=this.pieLegendTextColor||this.taskTextDarkColor,this.pieStrokeColor=this.pieStrokeColor||"black",this.pieStrokeWidth=this.pieStrokeWidth||"2px",this.pieOuterStrokeWidth=this.pieOuterStrokeWidth||"2px",this.pieOuterStrokeColor=this.pieOuterStrokeColor||"black",this.pieOpacity=this.pieOpacity||"0.7",this.quadrant1Fill=this.quadrant1Fill||this.primaryColor,this.quadrant2Fill=this.quadrant2Fill||Vu(this.primaryColor,{r:5,g:5,b:5}),this.quadrant3Fill=this.quadrant3Fill||Vu(this.primaryColor,{r:10,g:10,b:10}),this.quadrant4Fill=this.quadrant4Fill||Vu(this.primaryColor,{r:15,g:15,b:15}),this.quadrant1TextFill=this.quadrant1TextFill||this.primaryTextColor,this.quadrant2TextFill=this.quadrant2TextFill||Vu(this.primaryTextColor,{r:-5,g:-5,b:-5}),this.quadrant3TextFill=this.quadrant3TextFill||Vu(this.primaryTextColor,{r:-10,g:-10,b:-10}),this.quadrant4TextFill=this.quadrant4TextFill||Vu(this.primaryTextColor,{r:-15,g:-15,b:-15}),this.quadrantPointFill=this.quadrantPointFill||Fu(this.quadrant1Fill)?$u(this.quadrant1Fill):zu(this.quadrant1Fill),this.quadrantPointTextFill=this.quadrantPointTextFill||this.primaryTextColor,this.quadrantXAxisTextFill=this.quadrantXAxisTextFill||this.primaryTextColor,this.quadrantYAxisTextFill=this.quadrantYAxisTextFill||this.primaryTextColor,this.quadrantInternalBorderStrokeFill=this.quadrantInternalBorderStrokeFill||this.primaryBorderColor,this.quadrantExternalBorderStrokeFill=this.quadrantExternalBorderStrokeFill||this.primaryBorderColor,this.quadrantTitleFill=this.quadrantTitleFill||this.primaryTextColor,this.packet={startByteColor:this.primaryTextColor,endByteColor:this.primaryTextColor,labelColor:this.primaryTextColor,titleColor:this.primaryTextColor,blockStrokeColor:this.primaryTextColor,blockFillColor:this.mainBkg},this.radar={axisColor:(null==(e=this.radar)?void 0:e.axisColor)||this.lineColor,axisStrokeWidth:(null==(t=this.radar)?void 0:t.axisStrokeWidth)||2,axisLabelFontSize:(null==(r=this.radar)?void 0:r.axisLabelFontSize)||12,curveOpacity:(null==(n=this.radar)?void 0:n.curveOpacity)||.5,curveStrokeWidth:(null==(i=this.radar)?void 0:i.curveStrokeWidth)||2,graticuleColor:(null==(o=this.radar)?void 0:o.graticuleColor)||"#DEDEDE",graticuleStrokeWidth:(null==(a=this.radar)?void 0:a.graticuleStrokeWidth)||1,graticuleOpacity:(null==(s=this.radar)?void 0:s.graticuleOpacity)||.3,legendBoxSize:(null==(l=this.radar)?void 0:l.legendBoxSize)||12,legendFontSize:(null==(c=this.radar)?void 0:c.legendFontSize)||12},this.xyChart={backgroundColor:(null==(u=this.xyChart)?void 0:u.backgroundColor)||this.background,titleColor:(null==(h=this.xyChart)?void 0:h.titleColor)||this.primaryTextColor,xAxisTitleColor:(null==(d=this.xyChart)?void 0:d.xAxisTitleColor)||this.primaryTextColor,xAxisLabelColor:(null==(p=this.xyChart)?void 0:p.xAxisLabelColor)||this.primaryTextColor,xAxisTickColor:(null==(f=this.xyChart)?void 0:f.xAxisTickColor)||this.primaryTextColor,xAxisLineColor:(null==(g=this.xyChart)?void 0:g.xAxisLineColor)||this.primaryTextColor,yAxisTitleColor:(null==(m=this.xyChart)?void 0:m.yAxisTitleColor)||this.primaryTextColor,yAxisLabelColor:(null==(y=this.xyChart)?void 0:y.yAxisLabelColor)||this.primaryTextColor,yAxisTickColor:(null==(x=this.xyChart)?void 0:x.yAxisTickColor)||this.primaryTextColor,yAxisLineColor:(null==(b=this.xyChart)?void 0:b.yAxisLineColor)||this.primaryTextColor,plotColorPalette:(null==(v=this.xyChart)?void 0:v.plotColorPalette)||"#CDE498,#FF6B6B,#A0D2DB,#D7BDE2,#F0F0F0,#FFC3A0,#7FD8BE,#FF9A8B,#FAF3E0,#FFF176"},this.requirementBackground=this.requirementBackground||this.primaryColor,this.requirementBorderColor=this.requirementBorderColor||this.primaryBorderColor,this.requirementBorderSize=this.requirementBorderSize||"1",this.requirementTextColor=this.requirementTextColor||this.primaryTextColor,this.relationColor=this.relationColor||this.lineColor,this.relationLabelBackground=this.relationLabelBackground||this.edgeLabelBackground,this.relationLabelColor=this.relationLabelColor||this.actorTextColor,this.git0=this.git0||this.primaryColor,this.git1=this.git1||this.secondaryColor,this.git2=this.git2||this.tertiaryColor,this.git3=this.git3||Vu(this.primaryColor,{h:-30}),this.git4=this.git4||Vu(this.primaryColor,{h:-60}),this.git5=this.git5||Vu(this.primaryColor,{h:-90}),this.git6=this.git6||Vu(this.primaryColor,{h:60}),this.git7=this.git7||Vu(this.primaryColor,{h:120}),this.darkMode?(this.git0=$u(this.git0,25),this.git1=$u(this.git1,25),this.git2=$u(this.git2,25),this.git3=$u(this.git3,25),this.git4=$u(this.git4,25),this.git5=$u(this.git5,25),this.git6=$u(this.git6,25),this.git7=$u(this.git7,25)):(this.git0=zu(this.git0,25),this.git1=zu(this.git1,25),this.git2=zu(this.git2,25),this.git3=zu(this.git3,25),this.git4=zu(this.git4,25),this.git5=zu(this.git5,25),this.git6=zu(this.git6,25),this.git7=zu(this.git7,25)),this.gitInv0=this.gitInv0||Wu(this.git0),this.gitInv1=this.gitInv1||Wu(this.git1),this.gitInv2=this.gitInv2||Wu(this.git2),this.gitInv3=this.gitInv3||Wu(this.git3),this.gitInv4=this.gitInv4||Wu(this.git4),this.gitInv5=this.gitInv5||Wu(this.git5),this.gitInv6=this.gitInv6||Wu(this.git6),this.gitInv7=this.gitInv7||Wu(this.git7),this.gitBranchLabel0=this.gitBranchLabel0||Wu(this.labelTextColor),this.gitBranchLabel1=this.gitBranchLabel1||this.labelTextColor,this.gitBranchLabel2=this.gitBranchLabel2||this.labelTextColor,this.gitBranchLabel3=this.gitBranchLabel3||Wu(this.labelTextColor),this.gitBranchLabel4=this.gitBranchLabel4||this.labelTextColor,this.gitBranchLabel5=this.gitBranchLabel5||this.labelTextColor,this.gitBranchLabel6=this.gitBranchLabel6||this.labelTextColor,this.gitBranchLabel7=this.gitBranchLabel7||this.labelTextColor,this.tagLabelColor=this.tagLabelColor||this.primaryTextColor,this.tagLabelBackground=this.tagLabelBackground||this.primaryColor,this.tagLabelBorder=this.tagBorder||this.primaryBorderColor,this.tagLabelFontSize=this.tagLabelFontSize||"10px",this.commitLabelColor=this.commitLabelColor||this.secondaryTextColor,this.commitLabelBackground=this.commitLabelBackground||this.secondaryColor,this.commitLabelFontSize=this.commitLabelFontSize||"10px",this.attributeBackgroundColorOdd=this.attributeBackgroundColorOdd||ad,this.attributeBackgroundColorEven=this.attributeBackgroundColorEven||sd}calculate(e){if("object"!=typeof e)return void this.updateColors();const t=Object.keys(e);t.forEach(t=>{this[t]=e[t]}),this.updateColors(),t.forEach(t=>{this[t]=e[t]})}},"Theme"),u),md=mu(e=>{const t=new gd;return t.calculate(e),t},"getThemeVariables"),yd=(mu(h=class{constructor(){this.primaryColor="#eee",this.contrast="#707070",this.secondaryColor=$u(this.contrast,55),this.background="#ffffff",this.tertiaryColor=Vu(this.primaryColor,{h:-160}),this.primaryBorderColor=ld(this.primaryColor,this.darkMode),this.secondaryBorderColor=ld(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=ld(this.tertiaryColor,this.darkMode),this.primaryTextColor=Wu(this.primaryColor),this.secondaryTextColor=Wu(this.secondaryColor),this.tertiaryTextColor=Wu(this.tertiaryColor),this.lineColor=Wu(this.background),this.textColor=Wu(this.background),this.mainBkg="#eee",this.secondBkg="calculated",this.lineColor="#666",this.border1="#999",this.border2="calculated",this.note="#ffa",this.text="#333",this.critical="#d42",this.done="#bbb",this.arrowheadColor="#333333",this.fontFamily='"trebuchet ms", verdana, arial, sans-serif',this.fontSize="16px",this.THEME_COLOR_LIMIT=12,this.nodeBkg="calculated",this.nodeBorder="calculated",this.clusterBkg="calculated",this.clusterBorder="calculated",this.defaultLinkColor="calculated",this.titleColor="calculated",this.edgeLabelBackground="white",this.actorBorder="calculated",this.actorBkg="calculated",this.actorTextColor="calculated",this.actorLineColor=this.actorBorder,this.signalColor="calculated",this.signalTextColor="calculated",this.labelBoxBkgColor="calculated",this.labelBoxBorderColor="calculated",this.labelTextColor="calculated",this.loopTextColor="calculated",this.noteBorderColor="calculated",this.noteBkgColor="calculated",this.noteTextColor="calculated",this.activationBorderColor="#666",this.activationBkgColor="#f4f4f4",this.sequenceNumberColor="white",this.sectionBkgColor="calculated",this.altSectionBkgColor="white",this.sectionBkgColor2="calculated",this.excludeBkgColor="#eeeeee",this.taskBorderColor="calculated",this.taskBkgColor="calculated",this.taskTextLightColor="white",this.taskTextColor="calculated",this.taskTextDarkColor="calculated",this.taskTextOutsideColor="calculated",this.taskTextClickableColor="#003163",this.activeTaskBorderColor="calculated",this.activeTaskBkgColor="calculated",this.gridColor="calculated",this.doneTaskBkgColor="calculated",this.doneTaskBorderColor="calculated",this.critBkgColor="calculated",this.critBorderColor="calculated",this.todayLineColor="calculated",this.vertLineColor="calculated",this.personBorder=this.primaryBorderColor,this.personBkg=this.mainBkg,this.archEdgeColor="calculated",this.archEdgeArrowColor="calculated",this.archEdgeWidth="3",this.archGroupBorderColor=this.primaryBorderColor,this.archGroupBorderWidth="2px",this.rowOdd=this.rowOdd||$u(this.mainBkg,75)||"#ffffff",this.rowEven=this.rowEven||"#f4f4f4",this.labelColor="black",this.errorBkgColor="#552222",this.errorTextColor="#552222"}updateColors(){var e,t,r,n,i,o,a,s,l,c,u,h,d,p,f,g,m,y,x,b,v;this.secondBkg=$u(this.contrast,55),this.border2=this.contrast,this.actorBorder=$u(this.border1,23),this.actorBkg=this.mainBkg,this.actorTextColor=this.text,this.actorLineColor=this.actorBorder,this.signalColor=this.text,this.signalTextColor=this.text,this.labelBoxBkgColor=this.actorBkg,this.labelBoxBorderColor=this.actorBorder,this.labelTextColor=this.text,this.loopTextColor=this.text,this.noteBorderColor="#999",this.noteBkgColor="#666",this.noteTextColor="#fff",this.cScale0=this.cScale0||"#555",this.cScale1=this.cScale1||"#F4F4F4",this.cScale2=this.cScale2||"#555",this.cScale3=this.cScale3||"#BBB",this.cScale4=this.cScale4||"#777",this.cScale5=this.cScale5||"#999",this.cScale6=this.cScale6||"#DDD",this.cScale7=this.cScale7||"#FFF",this.cScale8=this.cScale8||"#DDD",this.cScale9=this.cScale9||"#BBB",this.cScale10=this.cScale10||"#999",this.cScale11=this.cScale11||"#777";for(let C=0;C<this.THEME_COLOR_LIMIT;C++)this["cScaleInv"+C]=this["cScaleInv"+C]||Wu(this["cScale"+C]);for(let C=0;C<this.THEME_COLOR_LIMIT;C++)this.darkMode?this["cScalePeer"+C]=this["cScalePeer"+C]||$u(this["cScale"+C],10):this["cScalePeer"+C]=this["cScalePeer"+C]||zu(this["cScale"+C],10);this.scaleLabelColor=this.scaleLabelColor||(this.darkMode?"black":this.labelTextColor),this.cScaleLabel0=this.cScaleLabel0||this.cScale1,this.cScaleLabel2=this.cScaleLabel2||this.cScale1;for(let C=0;C<this.THEME_COLOR_LIMIT;C++)this["cScaleLabel"+C]=this["cScaleLabel"+C]||this.scaleLabelColor;for(let C=0;C<5;C++)this["surface"+C]=this["surface"+C]||Vu(this.mainBkg,{l:-(5+5*C)}),this["surfacePeer"+C]=this["surfacePeer"+C]||Vu(this.mainBkg,{l:-(8+5*C)});this.nodeBkg=this.mainBkg,this.nodeBorder=this.border1,this.clusterBkg=this.secondBkg,this.clusterBorder=this.border2,this.defaultLinkColor=this.lineColor,this.titleColor=this.text,this.sectionBkgColor=$u(this.contrast,30),this.sectionBkgColor2=$u(this.contrast,30),this.taskBorderColor=zu(this.contrast,10),this.taskBkgColor=this.contrast,this.taskTextColor=this.taskTextLightColor,this.taskTextDarkColor=this.text,this.taskTextOutsideColor=this.taskTextDarkColor,this.activeTaskBorderColor=this.taskBorderColor,this.activeTaskBkgColor=this.mainBkg,this.gridColor=$u(this.border1,30),this.doneTaskBkgColor=this.done,this.doneTaskBorderColor=this.lineColor,this.critBkgColor=this.critical,this.critBorderColor=zu(this.critBkgColor,10),this.todayLineColor=this.critBkgColor,this.vertLineColor=this.critBkgColor,this.archEdgeColor=this.lineColor,this.archEdgeArrowColor=this.lineColor,this.transitionColor=this.transitionColor||"#000",this.transitionLabelColor=this.transitionLabelColor||this.textColor,this.stateLabelColor=this.stateLabelColor||this.stateBkg||this.primaryTextColor,this.stateBkg=this.stateBkg||this.mainBkg,this.labelBackgroundColor=this.labelBackgroundColor||this.stateBkg,this.compositeBackground=this.compositeBackground||this.background||this.tertiaryColor,this.altBackground=this.altBackground||"#f4f4f4",this.compositeTitleBackground=this.compositeTitleBackground||this.mainBkg,this.stateBorder=this.stateBorder||"#000",this.innerEndBackground=this.primaryBorderColor,this.specialStateColor="#222",this.errorBkgColor=this.errorBkgColor||this.tertiaryColor,this.errorTextColor=this.errorTextColor||this.tertiaryTextColor,this.classText=this.primaryTextColor,this.fillType0=this.primaryColor,this.fillType1=this.secondaryColor,this.fillType2=Vu(this.primaryColor,{h:64}),this.fillType3=Vu(this.secondaryColor,{h:64}),this.fillType4=Vu(this.primaryColor,{h:-64}),this.fillType5=Vu(this.secondaryColor,{h:-64}),this.fillType6=Vu(this.primaryColor,{h:128}),this.fillType7=Vu(this.secondaryColor,{h:128});for(let C=0;C<this.THEME_COLOR_LIMIT;C++)this["pie"+C]=this["cScale"+C];this.pie12=this.pie0,this.pieTitleTextSize=this.pieTitleTextSize||"25px",this.pieTitleTextColor=this.pieTitleTextColor||this.taskTextDarkColor,this.pieSectionTextSize=this.pieSectionTextSize||"17px",this.pieSectionTextColor=this.pieSectionTextColor||this.textColor,this.pieLegendTextSize=this.pieLegendTextSize||"17px",this.pieLegendTextColor=this.pieLegendTextColor||this.taskTextDarkColor,this.pieStrokeColor=this.pieStrokeColor||"black",this.pieStrokeWidth=this.pieStrokeWidth||"2px",this.pieOuterStrokeWidth=this.pieOuterStrokeWidth||"2px",this.pieOuterStrokeColor=this.pieOuterStrokeColor||"black",this.pieOpacity=this.pieOpacity||"0.7",this.quadrant1Fill=this.quadrant1Fill||this.primaryColor,this.quadrant2Fill=this.quadrant2Fill||Vu(this.primaryColor,{r:5,g:5,b:5}),this.quadrant3Fill=this.quadrant3Fill||Vu(this.primaryColor,{r:10,g:10,b:10}),this.quadrant4Fill=this.quadrant4Fill||Vu(this.primaryColor,{r:15,g:15,b:15}),this.quadrant1TextFill=this.quadrant1TextFill||this.primaryTextColor,this.quadrant2TextFill=this.quadrant2TextFill||Vu(this.primaryTextColor,{r:-5,g:-5,b:-5}),this.quadrant3TextFill=this.quadrant3TextFill||Vu(this.primaryTextColor,{r:-10,g:-10,b:-10}),this.quadrant4TextFill=this.quadrant4TextFill||Vu(this.primaryTextColor,{r:-15,g:-15,b:-15}),this.quadrantPointFill=this.quadrantPointFill||Fu(this.quadrant1Fill)?$u(this.quadrant1Fill):zu(this.quadrant1Fill),this.quadrantPointTextFill=this.quadrantPointTextFill||this.primaryTextColor,this.quadrantXAxisTextFill=this.quadrantXAxisTextFill||this.primaryTextColor,this.quadrantYAxisTextFill=this.quadrantYAxisTextFill||this.primaryTextColor,this.quadrantInternalBorderStrokeFill=this.quadrantInternalBorderStrokeFill||this.primaryBorderColor,this.quadrantExternalBorderStrokeFill=this.quadrantExternalBorderStrokeFill||this.primaryBorderColor,this.quadrantTitleFill=this.quadrantTitleFill||this.primaryTextColor,this.xyChart={backgroundColor:(null==(e=this.xyChart)?void 0:e.backgroundColor)||this.background,titleColor:(null==(t=this.xyChart)?void 0:t.titleColor)||this.primaryTextColor,xAxisTitleColor:(null==(r=this.xyChart)?void 0:r.xAxisTitleColor)||this.primaryTextColor,xAxisLabelColor:(null==(n=this.xyChart)?void 0:n.xAxisLabelColor)||this.primaryTextColor,xAxisTickColor:(null==(i=this.xyChart)?void 0:i.xAxisTickColor)||this.primaryTextColor,xAxisLineColor:(null==(o=this.xyChart)?void 0:o.xAxisLineColor)||this.primaryTextColor,yAxisTitleColor:(null==(a=this.xyChart)?void 0:a.yAxisTitleColor)||this.primaryTextColor,yAxisLabelColor:(null==(s=this.xyChart)?void 0:s.yAxisLabelColor)||this.primaryTextColor,yAxisTickColor:(null==(l=this.xyChart)?void 0:l.yAxisTickColor)||this.primaryTextColor,yAxisLineColor:(null==(c=this.xyChart)?void 0:c.yAxisLineColor)||this.primaryTextColor,plotColorPalette:(null==(u=this.xyChart)?void 0:u.plotColorPalette)||"#EEE,#6BB8E4,#8ACB88,#C7ACD6,#E8DCC2,#FFB2A8,#FFF380,#7E8D91,#FFD8B1,#FAF3E0"},this.radar={axisColor:(null==(h=this.radar)?void 0:h.axisColor)||this.lineColor,axisStrokeWidth:(null==(d=this.radar)?void 0:d.axisStrokeWidth)||2,axisLabelFontSize:(null==(p=this.radar)?void 0:p.axisLabelFontSize)||12,curveOpacity:(null==(f=this.radar)?void 0:f.curveOpacity)||.5,curveStrokeWidth:(null==(g=this.radar)?void 0:g.curveStrokeWidth)||2,graticuleColor:(null==(m=this.radar)?void 0:m.graticuleColor)||"#DEDEDE",graticuleStrokeWidth:(null==(y=this.radar)?void 0:y.graticuleStrokeWidth)||1,graticuleOpacity:(null==(x=this.radar)?void 0:x.graticuleOpacity)||.3,legendBoxSize:(null==(b=this.radar)?void 0:b.legendBoxSize)||12,legendFontSize:(null==(v=this.radar)?void 0:v.legendFontSize)||12},this.requirementBackground=this.requirementBackground||this.primaryColor,this.requirementBorderColor=this.requirementBorderColor||this.primaryBorderColor,this.requirementBorderSize=this.requirementBorderSize||"1",this.requirementTextColor=this.requirementTextColor||this.primaryTextColor,this.relationColor=this.relationColor||this.lineColor,this.relationLabelBackground=this.relationLabelBackground||this.edgeLabelBackground,this.relationLabelColor=this.relationLabelColor||this.actorTextColor,this.git0=zu(this.pie1,25)||this.primaryColor,this.git1=this.pie2||this.secondaryColor,this.git2=this.pie3||this.tertiaryColor,this.git3=this.pie4||Vu(this.primaryColor,{h:-30}),this.git4=this.pie5||Vu(this.primaryColor,{h:-60}),this.git5=this.pie6||Vu(this.primaryColor,{h:-90}),this.git6=this.pie7||Vu(this.primaryColor,{h:60}),this.git7=this.pie8||Vu(this.primaryColor,{h:120}),this.gitInv0=this.gitInv0||Wu(this.git0),this.gitInv1=this.gitInv1||Wu(this.git1),this.gitInv2=this.gitInv2||Wu(this.git2),this.gitInv3=this.gitInv3||Wu(this.git3),this.gitInv4=this.gitInv4||Wu(this.git4),this.gitInv5=this.gitInv5||Wu(this.git5),this.gitInv6=this.gitInv6||Wu(this.git6),this.gitInv7=this.gitInv7||Wu(this.git7),this.branchLabelColor=this.branchLabelColor||this.labelTextColor,this.gitBranchLabel0=this.branchLabelColor,this.gitBranchLabel1="white",this.gitBranchLabel2=this.branchLabelColor,this.gitBranchLabel3="white",this.gitBranchLabel4=this.branchLabelColor,this.gitBranchLabel5=this.branchLabelColor,this.gitBranchLabel6=this.branchLabelColor,this.gitBranchLabel7=this.branchLabelColor,this.tagLabelColor=this.tagLabelColor||this.primaryTextColor,this.tagLabelBackground=this.tagLabelBackground||this.primaryColor,this.tagLabelBorder=this.tagBorder||this.primaryBorderColor,this.tagLabelFontSize=this.tagLabelFontSize||"10px",this.commitLabelColor=this.commitLabelColor||this.secondaryTextColor,this.commitLabelBackground=this.commitLabelBackground||this.secondaryColor,this.commitLabelFontSize=this.commitLabelFontSize||"10px",this.attributeBackgroundColorOdd=this.attributeBackgroundColorOdd||ad,this.attributeBackgroundColorEven=this.attributeBackgroundColorEven||sd}calculate(e){if("object"!=typeof e)return void this.updateColors();const t=Object.keys(e);t.forEach(t=>{this[t]=e[t]}),this.updateColors(),t.forEach(t=>{this[t]=e[t]})}},"Theme"),h),xd={base:{getThemeVariables:ud},dark:{getThemeVariables:dd},default:{getThemeVariables:fd},forest:{getThemeVariables:md},neutral:{getThemeVariables:mu(e=>{const t=new yd;return t.calculate(e),t},"getThemeVariables")}},bd={flowchart:{useMaxWidth:!0,titleTopMargin:25,subGraphTitleMargin:{top:0,bottom:0},diagramPadding:8,htmlLabels:!0,nodeSpacing:50,rankSpacing:50,curve:"basis",padding:15,defaultRenderer:"dagre-wrapper",wrappingWidth:200,inheritDir:!1},sequence:{useMaxWidth:!0,hideUnusedParticipants:!1,activationWidth:10,diagramMarginX:50,diagramMarginY:10,actorMargin:50,width:150,height:65,boxMargin:10,boxTextMargin:5,noteMargin:10,messageMargin:35,messageAlign:"center",mirrorActors:!0,forceMenus:!1,bottomMarginAdj:1,rightAngles:!1,showSequenceNumbers:!1,actorFontSize:14,actorFontFamily:'"Open Sans", sans-serif',actorFontWeight:400,noteFontSize:14,noteFontFamily:'"trebuchet ms", verdana, arial, sans-serif',noteFontWeight:400,noteAlign:"center",messageFontSize:16,messageFontFamily:'"trebuchet ms", verdana, arial, sans-serif',messageFontWeight:400,wrap:!1,wrapPadding:10,labelBoxWidth:50,labelBoxHeight:20},gantt:{useMaxWidth:!0,titleTopMargin:25,barHeight:20,barGap:4,topPadding:50,rightPadding:75,leftPadding:75,gridLineStartPadding:35,fontSize:11,sectionFontSize:11,numberSectionStyles:4,axisFormat:"%Y-%m-%d",topAxis:!1,displayMode:"",weekday:"sunday"},journey:{useMaxWidth:!0,diagramMarginX:50,diagramMarginY:10,leftMargin:150,maxLabelWidth:360,width:150,height:50,boxMargin:10,boxTextMargin:5,noteMargin:10,messageMargin:35,messageAlign:"center",bottomMarginAdj:1,rightAngles:!1,taskFontSize:14,taskFontFamily:'"Open Sans", sans-serif',taskMargin:50,activationWidth:10,textPlacement:"fo",actorColours:["#8FBC8F","#7CFC00","#00FFFF","#20B2AA","#B0E0E6","#FFFFE0"],sectionFills:["#191970","#8B008B","#4B0082","#2F4F4F","#800000","#8B4513","#00008B"],sectionColours:["#fff"],titleColor:"",titleFontFamily:'"trebuchet ms", verdana, arial, sans-serif',titleFontSize:"4ex"},class:{useMaxWidth:!0,titleTopMargin:25,arrowMarkerAbsolute:!1,dividerMargin:10,padding:5,textHeight:10,defaultRenderer:"dagre-wrapper",htmlLabels:!1,hideEmptyMembersBox:!1},state:{useMaxWidth:!0,titleTopMargin:25,dividerMargin:10,sizeUnit:5,padding:8,textHeight:10,titleShift:-15,noteMargin:10,forkWidth:70,forkHeight:7,miniPadding:2,fontSizeFactor:5.02,fontSize:24,labelHeight:16,edgeLengthFactor:"20",compositTitleSize:35,radius:5,defaultRenderer:"dagre-wrapper"},er:{useMaxWidth:!0,titleTopMargin:25,diagramPadding:20,layoutDirection:"TB",minEntityWidth:100,minEntityHeight:75,entityPadding:15,nodeSpacing:140,rankSpacing:80,stroke:"gray",fill:"honeydew",fontSize:12},pie:{useMaxWidth:!0,textPosition:.75},quadrantChart:{useMaxWidth:!0,chartWidth:500,chartHeight:500,titleFontSize:20,titlePadding:10,quadrantPadding:5,xAxisLabelPadding:5,yAxisLabelPadding:5,xAxisLabelFontSize:16,yAxisLabelFontSize:16,quadrantLabelFontSize:16,quadrantTextTopPadding:5,pointTextPadding:5,pointLabelFontSize:12,pointRadius:5,xAxisPosition:"top",yAxisPosition:"left",quadrantInternalBorderStrokeWidth:1,quadrantExternalBorderStrokeWidth:2},xyChart:{useMaxWidth:!0,width:700,height:500,titleFontSize:20,titlePadding:10,showDataLabel:!1,showTitle:!0,xAxis:{$ref:"#/$defs/XYChartAxisConfig",showLabel:!0,labelFontSize:14,labelPadding:5,showTitle:!0,titleFontSize:16,titlePadding:5,showTick:!0,tickLength:5,tickWidth:2,showAxisLine:!0,axisLineWidth:2},yAxis:{$ref:"#/$defs/XYChartAxisConfig",showLabel:!0,labelFontSize:14,labelPadding:5,showTitle:!0,titleFontSize:16,titlePadding:5,showTick:!0,tickLength:5,tickWidth:2,showAxisLine:!0,axisLineWidth:2},chartOrientation:"vertical",plotReservedSpacePercent:50},requirement:{useMaxWidth:!0,rect_fill:"#f9f9f9",text_color:"#333",rect_border_size:"0.5px",rect_border_color:"#bbb",rect_min_width:200,rect_min_height:200,fontSize:14,rect_padding:10,line_height:20},mindmap:{useMaxWidth:!0,padding:10,maxNodeWidth:200,layoutAlgorithm:"cose-bilkent"},kanban:{useMaxWidth:!0,padding:8,sectionWidth:200,ticketBaseUrl:""},timeline:{useMaxWidth:!0,diagramMarginX:50,diagramMarginY:10,leftMargin:150,width:150,height:50,boxMargin:10,boxTextMargin:5,noteMargin:10,messageMargin:35,messageAlign:"center",bottomMarginAdj:1,rightAngles:!1,taskFontSize:14,taskFontFamily:'"Open Sans", sans-serif',taskMargin:50,activationWidth:10,textPlacement:"fo",actorColours:["#8FBC8F","#7CFC00","#00FFFF","#20B2AA","#B0E0E6","#FFFFE0"],sectionFills:["#191970","#8B008B","#4B0082","#2F4F4F","#800000","#8B4513","#00008B"],sectionColours:["#fff"],disableMulticolor:!1},gitGraph:{useMaxWidth:!0,titleTopMargin:25,diagramPadding:8,nodeLabel:{width:75,height:100,x:-25,y:0},mainBranchName:"main",mainBranchOrder:0,showCommitLabel:!0,showBranches:!0,rotateCommitLabel:!0,parallelCommits:!1,arrowMarkerAbsolute:!1},c4:{useMaxWidth:!0,diagramMarginX:50,diagramMarginY:10,c4ShapeMargin:50,c4ShapePadding:20,width:216,height:60,boxMargin:10,c4ShapeInRow:4,nextLinePaddingX:0,c4BoundaryInRow:2,personFontSize:14,personFontFamily:'"Open Sans", sans-serif',personFontWeight:"normal",external_personFontSize:14,external_personFontFamily:'"Open Sans", sans-serif',external_personFontWeight:"normal",systemFontSize:14,systemFontFamily:'"Open Sans", sans-serif',systemFontWeight:"normal",external_systemFontSize:14,external_systemFontFamily:'"Open Sans", sans-serif',external_systemFontWeight:"normal",system_dbFontSize:14,system_dbFontFamily:'"Open Sans", sans-serif',system_dbFontWeight:"normal",external_system_dbFontSize:14,external_system_dbFontFamily:'"Open Sans", sans-serif',external_system_dbFontWeight:"normal",system_queueFontSize:14,system_queueFontFamily:'"Open Sans", sans-serif',system_queueFontWeight:"normal",external_system_queueFontSize:14,external_system_queueFontFamily:'"Open Sans", sans-serif',external_system_queueFontWeight:"normal",boundaryFontSize:14,boundaryFontFamily:'"Open Sans", sans-serif',boundaryFontWeight:"normal",messageFontSize:12,messageFontFamily:'"Open Sans", sans-serif',messageFontWeight:"normal",containerFontSize:14,containerFontFamily:'"Open Sans", sans-serif',containerFontWeight:"normal",external_containerFontSize:14,external_containerFontFamily:'"Open Sans", sans-serif',external_containerFontWeight:"normal",container_dbFontSize:14,container_dbFontFamily:'"Open Sans", sans-serif',container_dbFontWeight:"normal",external_container_dbFontSize:14,external_container_dbFontFamily:'"Open Sans", sans-serif',external_container_dbFontWeight:"normal",container_queueFontSize:14,container_queueFontFamily:'"Open Sans", sans-serif',container_queueFontWeight:"normal",external_container_queueFontSize:14,external_container_queueFontFamily:'"Open Sans", sans-serif',external_container_queueFontWeight:"normal",componentFontSize:14,componentFontFamily:'"Open Sans", sans-serif',componentFontWeight:"normal",external_componentFontSize:14,external_componentFontFamily:'"Open Sans", sans-serif',external_componentFontWeight:"normal",component_dbFontSize:14,component_dbFontFamily:'"Open Sans", sans-serif',component_dbFontWeight:"normal",external_component_dbFontSize:14,external_component_dbFontFamily:'"Open Sans", sans-serif',external_component_dbFontWeight:"normal",component_queueFontSize:14,component_queueFontFamily:'"Open Sans", sans-serif',component_queueFontWeight:"normal",external_component_queueFontSize:14,external_component_queueFontFamily:'"Open Sans", sans-serif',external_component_queueFontWeight:"normal",wrap:!0,wrapPadding:10,person_bg_color:"#08427B",person_border_color:"#073B6F",external_person_bg_color:"#686868",external_person_border_color:"#8A8A8A",system_bg_color:"#1168BD",system_border_color:"#3C7FC0",system_db_bg_color:"#1168BD",system_db_border_color:"#3C7FC0",system_queue_bg_color:"#1168BD",system_queue_border_color:"#3C7FC0",external_system_bg_color:"#999999",external_system_border_color:"#8A8A8A",external_system_db_bg_color:"#999999",external_system_db_border_color:"#8A8A8A",external_system_queue_bg_color:"#999999",external_system_queue_border_color:"#8A8A8A",container_bg_color:"#438DD5",container_border_color:"#3C7FC0",container_db_bg_color:"#438DD5",container_db_border_color:"#3C7FC0",container_queue_bg_color:"#438DD5",container_queue_border_color:"#3C7FC0",external_container_bg_color:"#B3B3B3",external_container_border_color:"#A6A6A6",external_container_db_bg_color:"#B3B3B3",external_container_db_border_color:"#A6A6A6",external_container_queue_bg_color:"#B3B3B3",external_container_queue_border_color:"#A6A6A6",component_bg_color:"#85BBF0",component_border_color:"#78A8D8",component_db_bg_color:"#85BBF0",component_db_border_color:"#78A8D8",component_queue_bg_color:"#85BBF0",component_queue_border_color:"#78A8D8",external_component_bg_color:"#CCCCCC",external_component_border_color:"#BFBFBF",external_component_db_bg_color:"#CCCCCC",external_component_db_border_color:"#BFBFBF",external_component_queue_bg_color:"#CCCCCC",external_component_queue_border_color:"#BFBFBF"},sankey:{useMaxWidth:!0,width:600,height:400,linkColor:"gradient",nodeAlignment:"justify",showValues:!0,prefix:"",suffix:""},block:{useMaxWidth:!0,padding:8},packet:{useMaxWidth:!0,rowHeight:32,bitWidth:32,bitsPerRow:32,showBits:!0,paddingX:5,paddingY:5},architecture:{useMaxWidth:!0,padding:40,iconSize:80,fontSize:16},radar:{useMaxWidth:!0,width:600,height:600,marginTop:50,marginRight:50,marginBottom:50,marginLeft:50,axisScaleFactor:1,axisLabelFactor:1.05,curveTension:.17},theme:"default",look:"classic",handDrawnSeed:0,layout:"dagre",maxTextSize:5e4,maxEdges:500,darkMode:!1,fontFamily:'"trebuchet ms", verdana, arial, sans-serif;',logLevel:5,securityLevel:"strict",startOnLoad:!0,arrowMarkerAbsolute:!1,secure:["secure","securityLevel","startOnLoad","maxTextSize","suppressErrorRendering","maxEdges"],legacyMathML:!1,forceLegacyMathML:!1,deterministicIds:!1,fontSize:16,markdownAutoWrap:!0,suppressErrorRendering:!1},vd={...bd,deterministicIDSeed:void 0,elk:{mergeEdges:!1,nodePlacementStrategy:"BRANDES_KOEPF",forceNodeModelOrder:!1,considerModelOrder:"NODES_AND_EDGES"},themeCSS:void 0,themeVariables:xd.default.getThemeVariables(),sequence:{...bd.sequence,messageFont:mu(function(){return{fontFamily:this.messageFontFamily,fontSize:this.messageFontSize,fontWeight:this.messageFontWeight}},"messageFont"),noteFont:mu(function(){return{fontFamily:this.noteFontFamily,fontSize:this.noteFontSize,fontWeight:this.noteFontWeight}},"noteFont"),actorFont:mu(function(){return{fontFamily:this.actorFontFamily,fontSize:this.actorFontSize,fontWeight:this.actorFontWeight}},"actorFont")},class:{hideEmptyMembersBox:!1},gantt:{...bd.gantt,tickInterval:void 0,useWidth:void 0},c4:{...bd.c4,useWidth:void 0,personFont:mu(function(){return{fontFamily:this.personFontFamily,fontSize:this.personFontSize,fontWeight:this.personFontWeight}},"personFont"),flowchart:{...bd.flowchart,inheritDir:!1},external_personFont:mu(function(){return{fontFamily:this.external_personFontFamily,fontSize:this.external_personFontSize,fontWeight:this.external_personFontWeight}},"external_personFont"),systemFont:mu(function(){return{fontFamily:this.systemFontFamily,fontSize:this.systemFontSize,fontWeight:this.systemFontWeight}},"systemFont"),external_systemFont:mu(function(){return{fontFamily:this.external_systemFontFamily,fontSize:this.external_systemFontSize,fontWeight:this.external_systemFontWeight}},"external_systemFont"),system_dbFont:mu(function(){return{fontFamily:this.system_dbFontFamily,fontSize:this.system_dbFontSize,fontWeight:this.system_dbFontWeight}},"system_dbFont"),external_system_dbFont:mu(function(){return{fontFamily:this.external_system_dbFontFamily,fontSize:this.external_system_dbFontSize,fontWeight:this.external_system_dbFontWeight}},"external_system_dbFont"),system_queueFont:mu(function(){return{fontFamily:this.system_queueFontFamily,fontSize:this.system_queueFontSize,fontWeight:this.system_queueFontWeight}},"system_queueFont"),external_system_queueFont:mu(function(){return{fontFamily:this.external_system_queueFontFamily,fontSize:this.external_system_queueFontSize,fontWeight:this.external_system_queueFontWeight}},"external_system_queueFont"),containerFont:mu(function(){return{fontFamily:this.containerFontFamily,fontSize:this.containerFontSize,fontWeight:this.containerFontWeight}},"containerFont"),external_containerFont:mu(function(){return{fontFamily:this.external_containerFontFamily,fontSize:this.external_containerFontSize,fontWeight:this.external_containerFontWeight}},"external_containerFont"),container_dbFont:mu(function(){return{fontFamily:this.container_dbFontFamily,fontSize:this.container_dbFontSize,fontWeight:this.container_dbFontWeight}},"container_dbFont"),external_container_dbFont:mu(function(){return{fontFamily:this.external_container_dbFontFamily,fontSize:this.external_container_dbFontSize,fontWeight:this.external_container_dbFontWeight}},"external_container_dbFont"),container_queueFont:mu(function(){return{fontFamily:this.container_queueFontFamily,fontSize:this.container_queueFontSize,fontWeight:this.container_queueFontWeight}},"container_queueFont"),external_container_queueFont:mu(function(){return{fontFamily:this.external_container_queueFontFamily,fontSize:this.external_container_queueFontSize,fontWeight:this.external_container_queueFontWeight}},"external_container_queueFont"),componentFont:mu(function(){return{fontFamily:this.componentFontFamily,fontSize:this.componentFontSize,fontWeight:this.componentFontWeight}},"componentFont"),external_componentFont:mu(function(){return{fontFamily:this.external_componentFontFamily,fontSize:this.external_componentFontSize,fontWeight:this.external_componentFontWeight}},"external_componentFont"),component_dbFont:mu(function(){return{fontFamily:this.component_dbFontFamily,fontSize:this.component_dbFontSize,fontWeight:this.component_dbFontWeight}},"component_dbFont"),external_component_dbFont:mu(function(){return{fontFamily:this.external_component_dbFontFamily,fontSize:this.external_component_dbFontSize,fontWeight:this.external_component_dbFontWeight}},"external_component_dbFont"),component_queueFont:mu(function(){return{fontFamily:this.component_queueFontFamily,fontSize:this.component_queueFontSize,fontWeight:this.component_queueFontWeight}},"component_queueFont"),external_component_queueFont:mu(function(){return{fontFamily:this.external_component_queueFontFamily,fontSize:this.external_component_queueFontSize,fontWeight:this.external_component_queueFontWeight}},"external_component_queueFont"),boundaryFont:mu(function(){return{fontFamily:this.boundaryFontFamily,fontSize:this.boundaryFontSize,fontWeight:this.boundaryFontWeight}},"boundaryFont"),messageFont:mu(function(){return{fontFamily:this.messageFontFamily,fontSize:this.messageFontSize,fontWeight:this.messageFontWeight}},"messageFont")},pie:{...bd.pie,useWidth:984},xyChart:{...bd.xyChart,useWidth:void 0},requirement:{...bd.requirement,useWidth:void 0},packet:{...bd.packet},radar:{...bd.radar},treemap:{useMaxWidth:!0,padding:10,diagramPadding:8,showValues:!0,nodeWidth:100,nodeHeight:40,borderWidth:1,valueFontSize:12,labelFontSize:14,valueFormat:","}},Cd=mu((e,t="")=>Object.keys(e).reduce((r,n)=>Array.isArray(e[n])?r:"object"==typeof e[n]&&null!==e[n]?[...r,t+n,...Cd(e[n],"")]:[...r,t+n],[]),"keyify"),wd=new Set(Cd(vd,"")),kd=vd,Sd=mu(e=>{if(bu.debug("sanitizeDirective called with",e),"object"==typeof e&&null!=e)if(Array.isArray(e))e.forEach(e=>Sd(e));else{for(const t of Object.keys(e)){if(bu.debug("Checking key",t),t.startsWith("__")||t.includes("proto")||t.includes("constr")||!wd.has(t)||null==e[t]){bu.debug("sanitize deleting key: ",t),delete e[t];continue}if("object"==typeof e[t]){bu.debug("sanitizing object",t),Sd(e[t]);continue}const r=["themeCSS","fontFamily","altFontFamily"];for(const n of r)t.includes(n)&&(bu.debug("sanitizing css option",t),e[t]=_d(e[t]))}if(e.themeVariables)for(const t of Object.keys(e.themeVariables)){const r=e.themeVariables[t];(null==r?void 0:r.match)&&!r.match(/^[\d "#%(),.;A-Za-z]+$/)&&(e.themeVariables[t]="")}bu.debug("After sanitization",e)}},"sanitizeDirective"),_d=mu(e=>{let t=0,r=0;for(const n of e){if(t<r)return"{ /* ERROR: Unbalanced CSS */ }";"{"===n?t++:"}"===n&&r++}return t!==r?"{ /* ERROR: Unbalanced CSS */ }":e},"sanitizeCss"),Td=Object.freeze(kd),Ad=od({},Td),Pd=[],Ed=od({},Td),Md=mu((e,t)=>{let r=od({},e),n={};for(const i of t)Od(i),n=od(n,i);if(r=od(r,n),n.theme&&n.theme in xd){const e=od({},Gh),t=od(e.themeVariables||{},n.themeVariables);r.theme&&r.theme in xd&&(r.themeVariables=xd[r.theme].getThemeVariables(t))}return Wd(Ed=r),Ed},"updateCurrentConfig"),Id=mu(e=>(Ad=od({},Td),Ad=od(Ad,e),e.theme&&xd[e.theme]&&(Ad.themeVariables=xd[e.theme].getThemeVariables(e.themeVariables)),Md(Ad,Pd),Ad),"setSiteConfig"),Bd=mu(e=>{Gh=od({},e)},"saveConfigFromInitialize"),Ld=mu(e=>(Ad=od(Ad,e),Md(Ad,Pd),Ad),"updateSiteConfig"),jd=mu(()=>od({},Ad),"getSiteConfig"),Nd=mu(e=>(Wd(e),od(Ed,e),Dd()),"setConfig"),Dd=mu(()=>od({},Ed),"getConfig"),Od=mu(e=>{e&&(["secure",...Ad.secure??[]].forEach(t=>{Object.hasOwn(e,t)&&(bu.debug(`Denied attempt to modify a secure key ${t}`,e[t]),delete e[t])}),Object.keys(e).forEach(t=>{t.startsWith("__")&&delete e[t]}),Object.keys(e).forEach(t=>{"string"==typeof e[t]&&(e[t].includes("<")||e[t].includes(">")||e[t].includes("url(data:"))&&delete e[t],"object"==typeof e[t]&&Od(e[t])}))},"sanitize"),Fd=mu(e=>{var t;Sd(e),e.fontFamily&&!(null==(t=e.themeVariables)?void 0:t.fontFamily)&&(e.themeVariables={...e.themeVariables,fontFamily:e.fontFamily}),Pd.push(e),Md(Ad,Pd)},"addDirective"),Rd=mu((e=Ad)=>{Md(e,Pd=[])},"reset"),$d={LAZY_LOAD_DEPRECATED:"The configuration options lazyLoadedDiagrams and loadExternalDiagramsAtStartup are deprecated. Please use registerExternalDiagrams instead."},zd={},Vd=mu(e=>{zd[e]||(bu.warn($d[e]),zd[e]=!0)},"issueWarning"),Wd=mu(e=>{e&&(e.lazyLoadedDiagrams||e.loadExternalDiagramsAtStartup)&&Vd("LAZY_LOAD_DEPRECATED")},"checkConfig"),Hd=mu(()=>{let e={};Gh&&(e=od(e,Gh));for(const t of Pd)e=od(e,t);return e},"getUserDefinedConfig"),qd=/<br\s*\/?>/gi,Ud=mu(e=>{if(!e)return[""];return rp(e).replace(/\\n/g,"#br#").split("#br#")},"getRows"),Gd=(()=>{let e=!1;return()=>{e||(Xd(),e=!0)}})();function Xd(){const e="data-temp-href-target";Xh.addHook("beforeSanitizeAttributes",t=>{"A"===t.tagName&&t.hasAttribute("target")&&t.setAttribute(e,t.getAttribute("target")??"")}),Xh.addHook("afterSanitizeAttributes",t=>{"A"===t.tagName&&t.hasAttribute(e)&&(t.setAttribute("target",t.getAttribute(e)??""),t.removeAttribute(e),"_blank"===t.getAttribute("target")&&t.setAttribute("rel","noopener"))})}mu(Xd,"setupDompurifyHooks");var Jd=mu(e=>{Gd();return Xh.sanitize(e)},"removeScript"),Yd=mu((e,t)=>{var r;if(!1!==(null==(r=t.flowchart)?void 0:r.htmlLabels)){const r=t.securityLevel;"antiscript"===r||"strict"===r?e=Jd(e):"loose"!==r&&(e=(e=(e=rp(e)).replace(/</g,"<").replace(/>/g,">")).replace(/=/g,"="),e=tp(e))}return e},"sanitizeMore"),Zd=mu((e,t)=>e?e=t.dompurifyConfig?Xh.sanitize(Yd(e,t),t.dompurifyConfig).toString():Xh.sanitize(Yd(e,t),{FORBID_TAGS:["style"]}).toString():e,"sanitizeText"),Kd=mu((e,t)=>"string"==typeof e?Zd(e,t):e.flat().map(e=>Zd(e,t)),"sanitizeTextOrArray"),Qd=mu(e=>qd.test(e),"hasBreaks"),ep=mu(e=>e.split(qd),"splitBreaks"),tp=mu(e=>e.replace(/#br#/g,"<br/>"),"placeholderToBreak"),rp=mu(e=>e.replace(qd,"#br#"),"breakToPlaceholder"),np=mu(e=>{let t="";return e&&(t=window.location.protocol+"//"+window.location.host+window.location.pathname+window.location.search,t=CSS.escape(t)),t},"getUrl"),ip=mu(e=>!1!==e&&!["false","null","0"].includes(String(e).trim().toLowerCase()),"evaluate"),op=mu(function(...e){const t=e.filter(e=>!isNaN(e));return Math.max(...t)},"getMax"),ap=mu(function(...e){const t=e.filter(e=>!isNaN(e));return Math.min(...t)},"getMin"),sp=mu(function(e){const t=e.split(/(,)/),r=[];for(let n=0;n<t.length;n++){let e=t[n];if(","===e&&n>0&&n+1<t.length){const i=t[n-1],o=t[n+1];cp(i,o)&&(e=i+","+o,n++,r.pop())}r.push(up(e))}return r.join("")},"parseGenericTypes"),lp=mu((e,t)=>Math.max(0,e.split(t).length-1),"countOccurrence"),cp=mu((e,t)=>{const r=lp(e,"~"),n=lp(t,"~");return 1===r&&1===n},"shouldCombineSets"),up=mu(e=>{const t=lp(e,"~");let r=!1;if(t<=1)return e;t%2!=0&&e.startsWith("~")&&(e=e.substring(1),r=!0);const n=[...e];let i=n.indexOf("~"),o=n.lastIndexOf("~");for(;-1!==i&&-1!==o&&i!==o;)n[i]="<",n[o]=">",i=n.indexOf("~"),o=n.lastIndexOf("~");return r&&n.unshift("~"),n.join("")},"processSet"),hp=mu(()=>void 0!==window.MathMLElement,"isMathMLSupported"),dp=/\$\$(.*)\$\$/g,pp=mu(e=>{var t;return((null==(t=e.match(dp))?void 0:t.length)??0)>0},"hasKatex"),fp=mu(async(e,t)=>{const r=document.createElement("div");r.innerHTML=await mp(e,t),r.id="katex-temp",r.style.visibility="hidden",r.style.position="absolute",r.style.top="0";const n=document.querySelector("body");null==n||n.insertAdjacentElement("beforeend",r);const i={width:r.clientWidth,height:r.clientHeight};return r.remove(),i},"calculateMathMLDimensions"),gp=mu(async(e,t)=>{if(!pp(e))return e;if(!(hp()||t.legacyMathML||t.forceLegacyMathML))return e.replace(dp,"MathML is unsupported in this environment.");{const{default:r}=await Promise.resolve().then(()=>require("./katex-DPu4QpBP.cjs")),n=t.forceLegacyMathML||!hp()&&t.legacyMathML?"htmlAndMathml":"mathml";return e.split(qd).map(e=>pp(e)?`<div style="display: flex; align-items: center; justify-content: center; white-space: nowrap;">${e}</div>`:`<div>${e}</div>`).join("").replace(dp,(e,t)=>r.renderToString(t,{throwOnError:!0,displayMode:!0,output:n}).replace(/\n/g," ").replace(/<annotation.*<\/annotation>/g,""))}},"renderKatexUnsanitized"),mp=mu(async(e,t)=>Zd(await gp(e,t),t),"renderKatexSanitized"),yp={getRows:Ud,sanitizeText:Zd,sanitizeTextOrArray:Kd,hasBreaks:Qd,splitBreaks:ep,lineBreakRegex:qd,removeScript:Jd,getUrl:np,evaluate:ip,getMax:op,getMin:ap},xp=mu(function(e,t){for(let r of t)e.attr(r[0],r[1])},"d3Attrs"),bp=mu(function(e,t,r){let n=new Map;return r?(n.set("width","100%"),n.set("style",`max-width: ${t}px;`)):(n.set("height",e),n.set("width",t)),n},"calculateSvgSizeAttrs"),vp=mu(function(e,t,r,n){const i=bp(t,r,n);xp(e,i)},"configureSvgSize"),Cp=mu(function(e,t,r,n){const i=t.node().getBBox(),o=i.width,a=i.height;bu.info(`SVG bounds: ${o}x${a}`,i);let s=0,l=0;bu.info(`Graph bounds: ${s}x${l}`,e),s=o+2*r,l=a+2*r,bu.info(`Calculated bounds: ${s}x${l}`),vp(t,l,s,n);const c=`${i.x-r} ${i.y-r} ${i.width+2*r} ${i.height+2*r}`;t.attr("viewBox",c)},"setupGraphViewbox"),wp={},kp=mu((e,t,r)=>{let n="";return e in wp&&wp[e]?n=wp[e](r):bu.warn(`No theme found for ${e}`),` & {\n font-family: ${r.fontFamily};\n font-size: ${r.fontSize};\n fill: ${r.textColor}\n }\n @keyframes edge-animation-frame {\n from {\n stroke-dashoffset: 0;\n }\n }\n @keyframes dash {\n to {\n stroke-dashoffset: 0;\n }\n }\n & .edge-animation-slow {\n stroke-dasharray: 9,5 !important;\n stroke-dashoffset: 900;\n animation: dash 50s linear infinite;\n stroke-linecap: round;\n }\n & .edge-animation-fast {\n stroke-dasharray: 9,5 !important;\n stroke-dashoffset: 900;\n animation: dash 20s linear infinite;\n stroke-linecap: round;\n }\n /* Classes common for multiple diagrams */\n\n & .error-icon {\n fill: ${r.errorBkgColor};\n }\n & .error-text {\n fill: ${r.errorTextColor};\n stroke: ${r.errorTextColor};\n }\n\n & .edge-thickness-normal {\n stroke-width: 1px;\n }\n & .edge-thickness-thick {\n stroke-width: 3.5px\n }\n & .edge-pattern-solid {\n stroke-dasharray: 0;\n }\n & .edge-thickness-invisible {\n stroke-width: 0;\n fill: none;\n }\n & .edge-pattern-dashed{\n stroke-dasharray: 3;\n }\n .edge-pattern-dotted {\n stroke-dasharray: 2;\n }\n\n & .marker {\n fill: ${r.lineColor};\n stroke: ${r.lineColor};\n }\n & .marker.cross {\n stroke: ${r.lineColor};\n }\n\n & svg {\n font-family: ${r.fontFamily};\n font-size: ${r.fontSize};\n }\n & p {\n margin: 0\n }\n\n ${n}\n\n ${t}\n`},"getStyles"),Sp=mu((e,t)=>{void 0!==t&&(wp[e]=t)},"addStylesForDiagram"),_p=kp,Tp={};yu(Tp,{clear:()=>Ip,getAccDescription:()=>Np,getAccTitle:()=>Lp,getDiagramTitle:()=>Op,setAccDescription:()=>jp,setAccTitle:()=>Bp,setDiagramTitle:()=>Dp});var Ap="",Pp="",Ep="",Mp=mu(e=>Zd(e,Dd()),"sanitizeText"),Ip=mu(()=>{Ap="",Ep="",Pp=""},"clear"),Bp=mu(e=>{Ap=Mp(e).replace(/^\s+/g,"")},"setAccTitle"),Lp=mu(()=>Ap,"getAccTitle"),jp=mu(e=>{Ep=Mp(e).replace(/\n\s+/g,"\n")},"setAccDescription"),Np=mu(()=>Ep,"getAccDescription"),Dp=mu(e=>{Pp=Mp(e)},"setDiagramTitle"),Op=mu(()=>Pp,"getDiagramTitle"),Fp=bu,Rp=vu,$p=Dd,zp=Nd,Vp=Td,Wp=mu(e=>Zd(e,$p()),"sanitizeText"),Hp=Cp,qp=mu(()=>Tp,"getCommonDb"),Up={},Gp=mu((e,t,r)=>{var n;Up[e]&&Fp.warn(`Diagram with id ${e} already registered. Overwriting.`),Up[e]=t,r&&rd(e,r),Sp(e,t.styles),null==(n=t.injectUtils)||n.call(t,Fp,Rp,$p,Wp,Hp,qp(),()=>{})},"registerDiagram"),Xp=mu(e=>{if(e in Up)return Up[e];throw new Jp(e)},"getDiagram"),Jp=(d=class extends Error{constructor(e){super(`Diagram ${e} not found.`)}},mu(d,"DiagramNotFoundError"),d),Yp={value:()=>{}};function Zp(){for(var e,t=0,r=arguments.length,n={};t<r;++t){if(!(e=arguments[t]+"")||e in n||/[\s.]/.test(e))throw new Error("illegal type: "+e);n[e]=[]}return new Kp(n)}function Kp(e){this._=e}function Qp(e,t){for(var r,n=0,i=e.length;n<i;++n)if((r=e[n]).name===t)return r.value}function ef(e,t,r){for(var n=0,i=e.length;n<i;++n)if(e[n].name===t){e[n]=Yp,e=e.slice(0,n).concat(e.slice(n+1));break}return null!=r&&e.push({name:t,value:r}),e}Kp.prototype=Zp.prototype={constructor:Kp,on:function(e,t){var r,n,i=this._,o=(n=i,(e+"").trim().split(/^|\s+/).map(function(e){var t="",r=e.indexOf(".");if(r>=0&&(t=e.slice(r+1),e=e.slice(0,r)),e&&!n.hasOwnProperty(e))throw new Error("unknown type: "+e);return{type:e,name:t}})),a=-1,s=o.length;if(!(arguments.length<2)){if(null!=t&&"function"!=typeof t)throw new Error("invalid callback: "+t);for(;++a<s;)if(r=(e=o[a]).type)i[r]=ef(i[r],e.name,t);else if(null==t)for(r in i)i[r]=ef(i[r],e.name,null);return this}for(;++a<s;)if((r=(e=o[a]).type)&&(r=Qp(i[r],e.name)))return r},copy:function(){var e={},t=this._;for(var r in t)e[r]=t[r].slice();return new Kp(e)},call:function(e,t){if((r=arguments.length-2)>0)for(var r,n,i=new Array(r),o=0;o<r;++o)i[o]=arguments[o+2];if(!this._.hasOwnProperty(e))throw new Error("unknown type: "+e);for(o=0,r=(n=this._[e]).length;o<r;++o)n[o].value.apply(t,i)},apply:function(e,t,r){if(!this._.hasOwnProperty(e))throw new Error("unknown type: "+e);for(var n=this._[e],i=0,o=n.length;i<o;++i)n[i].value.apply(t,r)}};var tf="http://www.w3.org/1999/xhtml";const rf={svg:"http://www.w3.org/2000/svg",xhtml:tf,xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace",xmlns:"http://www.w3.org/2000/xmlns/"};function nf(e){var t=e+="",r=t.indexOf(":");return r>=0&&"xmlns"!==(t=e.slice(0,r))&&(e=e.slice(r+1)),rf.hasOwnProperty(t)?{space:rf[t],local:e}:e}function of(e){return function(){var t=this.ownerDocument,r=this.namespaceURI;return r===tf&&t.documentElement.namespaceURI===tf?t.createElement(e):t.createElementNS(r,e)}}function af(e){return function(){return this.ownerDocument.createElementNS(e.space,e.local)}}function sf(e){var t=nf(e);return(t.local?af:of)(t)}function lf(){}function cf(e){return null==e?lf:function(){return this.querySelector(e)}}function uf(){return[]}function hf(e){return null==e?uf:function(){return this.querySelectorAll(e)}}function df(e){return function(){return null==(t=e.apply(this,arguments))?[]:Array.isArray(t)?t:Array.from(t);var t}}function pf(e){return function(){return this.matches(e)}}function ff(e){return function(t){return t.matches(e)}}var gf=Array.prototype.find;function mf(){return this.firstElementChild}var yf=Array.prototype.filter;function xf(){return Array.from(this.children)}function bf(e){return new Array(e.length)}function vf(e,t){this.ownerDocument=e.ownerDocument,this.namespaceURI=e.namespaceURI,this._next=null,this._parent=e,this.__data__=t}function Cf(e,t,r,n,i,o){for(var a,s=0,l=t.length,c=o.length;s<c;++s)(a=t[s])?(a.__data__=o[s],n[s]=a):r[s]=new vf(e,o[s]);for(;s<l;++s)(a=t[s])&&(i[s]=a)}function wf(e,t,r,n,i,o,a){var s,l,c,u=new Map,h=t.length,d=o.length,p=new Array(h);for(s=0;s<h;++s)(l=t[s])&&(p[s]=c=a.call(l,l.__data__,s,t)+"",u.has(c)?i[s]=l:u.set(c,l));for(s=0;s<d;++s)c=a.call(e,o[s],s,o)+"",(l=u.get(c))?(n[s]=l,l.__data__=o[s],u.delete(c)):r[s]=new vf(e,o[s]);for(s=0;s<h;++s)(l=t[s])&&u.get(p[s])===l&&(i[s]=l)}function kf(e){return e.__data__}function Sf(e){return"object"==typeof e&&"length"in e?e:Array.from(e)}function _f(e,t){return e<t?-1:e>t?1:e>=t?0:NaN}function Tf(e){return function(){this.removeAttribute(e)}}function Af(e){return function(){this.removeAttributeNS(e.space,e.local)}}function Pf(e,t){return function(){this.setAttribute(e,t)}}function Ef(e,t){return function(){this.setAttributeNS(e.space,e.local,t)}}function Mf(e,t){return function(){var r=t.apply(this,arguments);null==r?this.removeAttribute(e):this.setAttribute(e,r)}}function If(e,t){return function(){var r=t.apply(this,arguments);null==r?this.removeAttributeNS(e.space,e.local):this.setAttributeNS(e.space,e.local,r)}}function Bf(e){return e.ownerDocument&&e.ownerDocument.defaultView||e.document&&e||e.defaultView}function Lf(e){return function(){this.style.removeProperty(e)}}function jf(e,t,r){return function(){this.style.setProperty(e,t,r)}}function Nf(e,t,r){return function(){var n=t.apply(this,arguments);null==n?this.style.removeProperty(e):this.style.setProperty(e,n,r)}}function Df(e,t){return e.style.getPropertyValue(t)||Bf(e).getComputedStyle(e,null).getPropertyValue(t)}function Of(e){return function(){delete this[e]}}function Ff(e,t){return function(){this[e]=t}}function Rf(e,t){return function(){var r=t.apply(this,arguments);null==r?delete this[e]:this[e]=r}}function $f(e){return e.trim().split(/^|\s+/)}function zf(e){return e.classList||new Vf(e)}function Vf(e){this._node=e,this._names=$f(e.getAttribute("class")||"")}function Wf(e,t){for(var r=zf(e),n=-1,i=t.length;++n<i;)r.add(t[n])}function Hf(e,t){for(var r=zf(e),n=-1,i=t.length;++n<i;)r.remove(t[n])}function qf(e){return function(){Wf(this,e)}}function Uf(e){return function(){Hf(this,e)}}function Gf(e,t){return function(){(t.apply(this,arguments)?Wf:Hf)(this,e)}}function Xf(){this.textContent=""}function Jf(e){return function(){this.textContent=e}}function Yf(e){return function(){var t=e.apply(this,arguments);this.textContent=null==t?"":t}}function Zf(){this.innerHTML=""}function Kf(e){return function(){this.innerHTML=e}}function Qf(e){return function(){var t=e.apply(this,arguments);this.innerHTML=null==t?"":t}}function eg(){this.nextSibling&&this.parentNode.appendChild(this)}function tg(){this.previousSibling&&this.parentNode.insertBefore(this,this.parentNode.firstChild)}function rg(){return null}function ng(){var e=this.parentNode;e&&e.removeChild(this)}function ig(){var e=this.cloneNode(!1),t=this.parentNode;return t?t.insertBefore(e,this.nextSibling):e}function og(){var e=this.cloneNode(!0),t=this.parentNode;return t?t.insertBefore(e,this.nextSibling):e}function ag(e){return function(){var t=this.__on;if(t){for(var r,n=0,i=-1,o=t.length;n<o;++n)r=t[n],e.type&&r.type!==e.type||r.name!==e.name?t[++i]=r:this.removeEventListener(r.type,r.listener,r.options);++i?t.length=i:delete this.__on}}}function sg(e,t,r){return function(){var n,i=this.__on,o=function(e){return function(t){e.call(this,t,this.__data__)}}(t);if(i)for(var a=0,s=i.length;a<s;++a)if((n=i[a]).type===e.type&&n.name===e.name)return this.removeEventListener(n.type,n.listener,n.options),this.addEventListener(n.type,n.listener=o,n.options=r),void(n.value=t);this.addEventListener(e.type,o,r),n={type:e.type,name:e.name,value:t,listener:o,options:r},i?i.push(n):this.__on=[n]}}function lg(e,t,r){var n=Bf(e),i=n.CustomEvent;"function"==typeof i?i=new i(t,r):(i=n.document.createEvent("Event"),r?(i.initEvent(t,r.bubbles,r.cancelable),i.detail=r.detail):i.initEvent(t,!1,!1)),e.dispatchEvent(i)}function cg(e,t){return function(){return lg(this,e,t)}}function ug(e,t){return function(){return lg(this,e,t.apply(this,arguments))}}vf.prototype={constructor:vf,appendChild:function(e){return this._parent.insertBefore(e,this._next)},insertBefore:function(e,t){return this._parent.insertBefore(e,t)},querySelector:function(e){return this._parent.querySelector(e)},querySelectorAll:function(e){return this._parent.querySelectorAll(e)}},Vf.prototype={add:function(e){this._names.indexOf(e)<0&&(this._names.push(e),this._node.setAttribute("class",this._names.join(" ")))},remove:function(e){var t=this._names.indexOf(e);t>=0&&(this._names.splice(t,1),this._node.setAttribute("class",this._names.join(" ")))},contains:function(e){return this._names.indexOf(e)>=0}};var hg=[null];function dg(e,t){this._groups=e,this._parents=t}function pg(){return new dg([[document.documentElement]],hg)}function fg(e){return"string"==typeof e?new dg([[document.querySelector(e)]],[document.documentElement]):new dg([[e]],hg)}function gg(e,t,r){e.prototype=t.prototype=r,r.constructor=e}function mg(e,t){var r=Object.create(e.prototype);for(var n in t)r[n]=t[n];return r}function yg(){}dg.prototype=pg.prototype={constructor:dg,select:function(e){"function"!=typeof e&&(e=cf(e));for(var t=this._groups,r=t.length,n=new Array(r),i=0;i<r;++i)for(var o,a,s=t[i],l=s.length,c=n[i]=new Array(l),u=0;u<l;++u)(o=s[u])&&(a=e.call(o,o.__data__,u,s))&&("__data__"in o&&(a.__data__=o.__data__),c[u]=a);return new dg(n,this._parents)},selectAll:function(e){e="function"==typeof e?df(e):hf(e);for(var t=this._groups,r=t.length,n=[],i=[],o=0;o<r;++o)for(var a,s=t[o],l=s.length,c=0;c<l;++c)(a=s[c])&&(n.push(e.call(a,a.__data__,c,s)),i.push(a));return new dg(n,i)},selectChild:function(e){return this.select(null==e?mf:function(e){return function(){return gf.call(this.children,e)}}("function"==typeof e?e:ff(e)))},selectChildren:function(e){return this.selectAll(null==e?xf:function(e){return function(){return yf.call(this.children,e)}}("function"==typeof e?e:ff(e)))},filter:function(e){"function"!=typeof e&&(e=pf(e));for(var t=this._groups,r=t.length,n=new Array(r),i=0;i<r;++i)for(var o,a=t[i],s=a.length,l=n[i]=[],c=0;c<s;++c)(o=a[c])&&e.call(o,o.__data__,c,a)&&l.push(o);return new dg(n,this._parents)},data:function(e,t){if(!arguments.length)return Array.from(this,kf);var r,n=t?wf:Cf,i=this._parents,o=this._groups;"function"!=typeof e&&(r=e,e=function(){return r});for(var a=o.length,s=new Array(a),l=new Array(a),c=new Array(a),u=0;u<a;++u){var h=i[u],d=o[u],p=d.length,f=Sf(e.call(h,h&&h.__data__,u,i)),g=f.length,m=l[u]=new Array(g),y=s[u]=new Array(g);n(h,d,m,y,c[u]=new Array(p),f,t);for(var x,b,v=0,C=0;v<g;++v)if(x=m[v]){for(v>=C&&(C=v+1);!(b=y[C])&&++C<g;);x._next=b||null}}return(s=new dg(s,i))._enter=l,s._exit=c,s},enter:function(){return new dg(this._enter||this._groups.map(bf),this._parents)},exit:function(){return new dg(this._exit||this._groups.map(bf),this._parents)},join:function(e,t,r){var n=this.enter(),i=this,o=this.exit();return"function"==typeof e?(n=e(n))&&(n=n.selection()):n=n.append(e+""),null!=t&&(i=t(i))&&(i=i.selection()),null==r?o.remove():r(o),n&&i?n.merge(i).order():i},merge:function(e){for(var t=e.selection?e.selection():e,r=this._groups,n=t._groups,i=r.length,o=n.length,a=Math.min(i,o),s=new Array(i),l=0;l<a;++l)for(var c,u=r[l],h=n[l],d=u.length,p=s[l]=new Array(d),f=0;f<d;++f)(c=u[f]||h[f])&&(p[f]=c);for(;l<i;++l)s[l]=r[l];return new dg(s,this._parents)},selection:function(){return this},order:function(){for(var e=this._groups,t=-1,r=e.length;++t<r;)for(var n,i=e[t],o=i.length-1,a=i[o];--o>=0;)(n=i[o])&&(a&&4^n.compareDocumentPosition(a)&&a.parentNode.insertBefore(n,a),a=n);return this},sort:function(e){function t(t,r){return t&&r?e(t.__data__,r.__data__):!t-!r}e||(e=_f);for(var r=this._groups,n=r.length,i=new Array(n),o=0;o<n;++o){for(var a,s=r[o],l=s.length,c=i[o]=new Array(l),u=0;u<l;++u)(a=s[u])&&(c[u]=a);c.sort(t)}return new dg(i,this._parents).order()},call:function(){var e=arguments[0];return arguments[0]=this,e.apply(null,arguments),this},nodes:function(){return Array.from(this)},node:function(){for(var e=this._groups,t=0,r=e.length;t<r;++t)for(var n=e[t],i=0,o=n.length;i<o;++i){var a=n[i];if(a)return a}return null},size:function(){let e=0;for(const t of this)++e;return e},empty:function(){return!this.node()},each:function(e){for(var t=this._groups,r=0,n=t.length;r<n;++r)for(var i,o=t[r],a=0,s=o.length;a<s;++a)(i=o[a])&&e.call(i,i.__data__,a,o);return this},attr:function(e,t){var r=nf(e);if(arguments.length<2){var n=this.node();return r.local?n.getAttributeNS(r.space,r.local):n.getAttribute(r)}return this.each((null==t?r.local?Af:Tf:"function"==typeof t?r.local?If:Mf:r.local?Ef:Pf)(r,t))},style:function(e,t,r){return arguments.length>1?this.each((null==t?Lf:"function"==typeof t?Nf:jf)(e,t,null==r?"":r)):Df(this.node(),e)},property:function(e,t){return arguments.length>1?this.each((null==t?Of:"function"==typeof t?Rf:Ff)(e,t)):this.node()[e]},classed:function(e,t){var r=$f(e+"");if(arguments.length<2){for(var n=zf(this.node()),i=-1,o=r.length;++i<o;)if(!n.contains(r[i]))return!1;return!0}return this.each(("function"==typeof t?Gf:t?qf:Uf)(r,t))},text:function(e){return arguments.length?this.each(null==e?Xf:("function"==typeof e?Yf:Jf)(e)):this.node().textContent},html:function(e){return arguments.length?this.each(null==e?Zf:("function"==typeof e?Qf:Kf)(e)):this.node().innerHTML},raise:function(){return this.each(eg)},lower:function(){return this.each(tg)},append:function(e){var t="function"==typeof e?e:sf(e);return this.select(function(){return this.appendChild(t.apply(this,arguments))})},insert:function(e,t){var r="function"==typeof e?e:sf(e),n=null==t?rg:"function"==typeof t?t:cf(t);return this.select(function(){return this.insertBefore(r.apply(this,arguments),n.apply(this,arguments)||null)})},remove:function(){return this.each(ng)},clone:function(e){return this.select(e?og:ig)},datum:function(e){return arguments.length?this.property("__data__",e):this.node().__data__},on:function(e,t,r){var n,i,o=function(e){return e.trim().split(/^|\s+/).map(function(e){var t="",r=e.indexOf(".");return r>=0&&(t=e.slice(r+1),e=e.slice(0,r)),{type:e,name:t}})}(e+""),a=o.length;if(!(arguments.length<2)){for(s=t?sg:ag,n=0;n<a;++n)this.each(s(o[n],t,r));return this}var s=this.node().__on;if(s)for(var l,c=0,u=s.length;c<u;++c)for(n=0,l=s[c];n<a;++n)if((i=o[n]).type===l.type&&i.name===l.name)return l.value},dispatch:function(e,t){return this.each(("function"==typeof t?ug:cg)(e,t))},[Symbol.iterator]:function*(){for(var e=this._groups,t=0,r=e.length;t<r;++t)for(var n,i=e[t],o=0,a=i.length;o<a;++o)(n=i[o])&&(yield n)}};var xg=.7,bg=1/xg,vg="\\s*([+-]?\\d+)\\s*",Cg="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)\\s*",wg="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)%\\s*",kg=/^#([0-9a-f]{3,8})$/,Sg=new RegExp(`^rgb\\(${vg},${vg},${vg}\\)$`),_g=new RegExp(`^rgb\\(${wg},${wg},${wg}\\)$`),Tg=new RegExp(`^rgba\\(${vg},${vg},${vg},${Cg}\\)$`),Ag=new RegExp(`^rgba\\(${wg},${wg},${wg},${Cg}\\)$`),Pg=new RegExp(`^hsl\\(${Cg},${wg},${wg}\\)$`),Eg=new RegExp(`^hsla\\(${Cg},${wg},${wg},${Cg}\\)$`),Mg={aliceblue:15792383,antiquewhite:16444375,aqua:65535,aquamarine:8388564,azure:15794175,beige:16119260,bisque:16770244,black:0,blanchedalmond:16772045,blue:255,blueviolet:9055202,brown:10824234,burlywood:14596231,cadetblue:6266528,chartreuse:8388352,chocolate:13789470,coral:16744272,cornflowerblue:6591981,cornsilk:16775388,crimson:14423100,cyan:65535,darkblue:139,darkcyan:35723,darkgoldenrod:12092939,darkgray:11119017,darkgreen:25600,darkgrey:11119017,darkkhaki:12433259,darkmagenta:9109643,darkolivegreen:5597999,darkorange:16747520,darkorchid:10040012,darkred:9109504,darksalmon:15308410,darkseagreen:9419919,darkslateblue:4734347,darkslategray:3100495,darkslategrey:3100495,darkturquoise:52945,darkviolet:9699539,deeppink:16716947,deepskyblue:49151,dimgray:6908265,dimgrey:6908265,dodgerblue:2003199,firebrick:11674146,floralwhite:16775920,forestgreen:2263842,fuchsia:16711935,gainsboro:14474460,ghostwhite:16316671,gold:16766720,goldenrod:14329120,gray:8421504,green:32768,greenyellow:11403055,grey:8421504,honeydew:15794160,hotpink:16738740,indianred:13458524,indigo:4915330,ivory:16777200,khaki:15787660,lavender:15132410,lavenderblush:16773365,lawngreen:8190976,lemonchiffon:16775885,lightblue:11393254,lightcoral:15761536,lightcyan:14745599,lightgoldenrodyellow:16448210,lightgray:13882323,lightgreen:9498256,lightgrey:13882323,lightpink:16758465,lightsalmon:16752762,lightseagreen:2142890,lightskyblue:8900346,lightslategray:7833753,lightslategrey:7833753,lightsteelblue:11584734,lightyellow:16777184,lime:65280,limegreen:3329330,linen:16445670,magenta:16711935,maroon:8388608,mediumaquamarine:6737322,mediumblue:205,mediumorchid:12211667,mediumpurple:9662683,mediumseagreen:3978097,mediumslateblue:8087790,mediumspringgreen:64154,mediumturquoise:4772300,mediumvioletred:13047173,midnightblue:1644912,mintcream:16121850,mistyrose:16770273,moccasin:16770229,navajowhite:16768685,navy:128,oldlace:16643558,olive:8421376,olivedrab:7048739,orange:16753920,orangered:16729344,orchid:14315734,palegoldenrod:15657130,palegreen:10025880,paleturquoise:11529966,palevioletred:14381203,papayawhip:16773077,peachpuff:16767673,peru:13468991,pink:16761035,plum:14524637,powderblue:11591910,purple:8388736,rebeccapurple:6697881,red:16711680,rosybrown:12357519,royalblue:4286945,saddlebrown:9127187,salmon:16416882,sandybrown:16032864,seagreen:3050327,seashell:16774638,sienna:10506797,silver:12632256,skyblue:8900331,slateblue:6970061,slategray:7372944,slategrey:7372944,snow:16775930,springgreen:65407,steelblue:4620980,tan:13808780,teal:32896,thistle:14204888,tomato:16737095,turquoise:4251856,violet:15631086,wheat:16113331,white:16777215,whitesmoke:16119285,yellow:16776960,yellowgreen:10145074};function Ig(){return this.rgb().formatHex()}function Bg(){return this.rgb().formatRgb()}function Lg(e){var t,r;return e=(e+"").trim().toLowerCase(),(t=kg.exec(e))?(r=t[1].length,t=parseInt(t[1],16),6===r?jg(t):3===r?new Fg(t>>8&15|t>>4&240,t>>4&15|240&t,(15&t)<<4|15&t,1):8===r?Ng(t>>24&255,t>>16&255,t>>8&255,(255&t)/255):4===r?Ng(t>>12&15|t>>8&240,t>>8&15|t>>4&240,t>>4&15|240&t,((15&t)<<4|15&t)/255):null):(t=Sg.exec(e))?new Fg(t[1],t[2],t[3],1):(t=_g.exec(e))?new Fg(255*t[1]/100,255*t[2]/100,255*t[3]/100,1):(t=Tg.exec(e))?Ng(t[1],t[2],t[3],t[4]):(t=Ag.exec(e))?Ng(255*t[1]/100,255*t[2]/100,255*t[3]/100,t[4]):(t=Pg.exec(e))?Hg(t[1],t[2]/100,t[3]/100,1):(t=Eg.exec(e))?Hg(t[1],t[2]/100,t[3]/100,t[4]):Mg.hasOwnProperty(e)?jg(Mg[e]):"transparent"===e?new Fg(NaN,NaN,NaN,0):null}function jg(e){return new Fg(e>>16&255,e>>8&255,255&e,1)}function Ng(e,t,r,n){return n<=0&&(e=t=r=NaN),new Fg(e,t,r,n)}function Dg(e){return e instanceof yg||(e=Lg(e)),e?new Fg((e=e.rgb()).r,e.g,e.b,e.opacity):new Fg}function Og(e,t,r,n){return 1===arguments.length?Dg(e):new Fg(e,t,r,null==n?1:n)}function Fg(e,t,r,n){this.r=+e,this.g=+t,this.b=+r,this.opacity=+n}function Rg(){return`#${Wg(this.r)}${Wg(this.g)}${Wg(this.b)}`}function $g(){const e=zg(this.opacity);return`${1===e?"rgb(":"rgba("}${Vg(this.r)}, ${Vg(this.g)}, ${Vg(this.b)}${1===e?")":`, ${e})`}`}function zg(e){return isNaN(e)?1:Math.max(0,Math.min(1,e))}function Vg(e){return Math.max(0,Math.min(255,Math.round(e)||0))}function Wg(e){return((e=Vg(e))<16?"0":"")+e.toString(16)}function Hg(e,t,r,n){return n<=0?e=t=r=NaN:r<=0||r>=1?e=t=NaN:t<=0&&(e=NaN),new Ug(e,t,r,n)}function qg(e){if(e instanceof Ug)return new Ug(e.h,e.s,e.l,e.opacity);if(e instanceof yg||(e=Lg(e)),!e)return new Ug;if(e instanceof Ug)return e;var t=(e=e.rgb()).r/255,r=e.g/255,n=e.b/255,i=Math.min(t,r,n),o=Math.max(t,r,n),a=NaN,s=o-i,l=(o+i)/2;return s?(a=t===o?(r-n)/s+6*(r<n):r===o?(n-t)/s+2:(t-r)/s+4,s/=l<.5?o+i:2-o-i,a*=60):s=l>0&&l<1?0:a,new Ug(a,s,l,e.opacity)}function Ug(e,t,r,n){this.h=+e,this.s=+t,this.l=+r,this.opacity=+n}function Gg(e){return(e=(e||0)%360)<0?e+360:e}function Xg(e){return Math.max(0,Math.min(1,e||0))}function Jg(e,t,r){return 255*(e<60?t+(r-t)*e/60:e<180?r:e<240?t+(r-t)*(240-e)/60:t)}gg(yg,Lg,{copy(e){return Object.assign(new this.constructor,this,e)},displayable(){return this.rgb().displayable()},hex:Ig,formatHex:Ig,formatHex8:function(){return this.rgb().formatHex8()},formatHsl:function(){return qg(this).formatHsl()},formatRgb:Bg,toString:Bg}),gg(Fg,Og,mg(yg,{brighter(e){return e=null==e?bg:Math.pow(bg,e),new Fg(this.r*e,this.g*e,this.b*e,this.opacity)},darker(e){return e=null==e?xg:Math.pow(xg,e),new Fg(this.r*e,this.g*e,this.b*e,this.opacity)},rgb(){return this},clamp(){return new Fg(Vg(this.r),Vg(this.g),Vg(this.b),zg(this.opacity))},displayable(){return-.5<=this.r&&this.r<255.5&&-.5<=this.g&&this.g<255.5&&-.5<=this.b&&this.b<255.5&&0<=this.opacity&&this.opacity<=1},hex:Rg,formatHex:Rg,formatHex8:function(){return`#${Wg(this.r)}${Wg(this.g)}${Wg(this.b)}${Wg(255*(isNaN(this.opacity)?1:this.opacity))}`},formatRgb:$g,toString:$g})),gg(Ug,function(e,t,r,n){return 1===arguments.length?qg(e):new Ug(e,t,r,null==n?1:n)},mg(yg,{brighter(e){return e=null==e?bg:Math.pow(bg,e),new Ug(this.h,this.s,this.l*e,this.opacity)},darker(e){return e=null==e?xg:Math.pow(xg,e),new Ug(this.h,this.s,this.l*e,this.opacity)},rgb(){var e=this.h%360+360*(this.h<0),t=isNaN(e)||isNaN(this.s)?0:this.s,r=this.l,n=r+(r<.5?r:1-r)*t,i=2*r-n;return new Fg(Jg(e>=240?e-240:e+120,i,n),Jg(e,i,n),Jg(e<120?e+240:e-120,i,n),this.opacity)},clamp(){return new Ug(Gg(this.h),Xg(this.s),Xg(this.l),zg(this.opacity))},displayable(){return(0<=this.s&&this.s<=1||isNaN(this.s))&&0<=this.l&&this.l<=1&&0<=this.opacity&&this.opacity<=1},formatHsl(){const e=zg(this.opacity);return`${1===e?"hsl(":"hsla("}${Gg(this.h)}, ${100*Xg(this.s)}%, ${100*Xg(this.l)}%${1===e?")":`, ${e})`}`}}));const Yg=e=>()=>e;function Zg(e,t){return function(r){return e+r*t}}function Kg(e){return 1===(e=+e)?Qg:function(t,r){return r-t?function(e,t,r){return e=Math.pow(e,r),t=Math.pow(t,r)-e,r=1/r,function(n){return Math.pow(e+n*t,r)}}(t,r,e):Yg(isNaN(t)?r:t)}}function Qg(e,t){var r=t-e;return r?Zg(e,r):Yg(isNaN(e)?t:e)}const em=function e(t){var r=Kg(t);function n(e,t){var n=r((e=Og(e)).r,(t=Og(t)).r),i=r(e.g,t.g),o=r(e.b,t.b),a=Qg(e.opacity,t.opacity);return function(t){return e.r=n(t),e.g=i(t),e.b=o(t),e.opacity=a(t),e+""}}return n.gamma=e,n}(1);function tm(e,t){return e=+e,t=+t,function(r){return e*(1-r)+t*r}}var rm=/[-+]?(?:\d+\.?\d*|\.?\d+)(?:[eE][-+]?\d+)?/g,nm=new RegExp(rm.source,"g");function im(e,t){var r,n,i,o=rm.lastIndex=nm.lastIndex=0,a=-1,s=[],l=[];for(e+="",t+="";(r=rm.exec(e))&&(n=nm.exec(t));)(i=n.index)>o&&(i=t.slice(o,i),s[a]?s[a]+=i:s[++a]=i),(r=r[0])===(n=n[0])?s[a]?s[a]+=n:s[++a]=n:(s[++a]=null,l.push({i:a,x:tm(r,n)})),o=nm.lastIndex;return o<t.length&&(i=t.slice(o),s[a]?s[a]+=i:s[++a]=i),s.length<2?l[0]?function(e){return function(t){return e(t)+""}}(l[0].x):function(e){return function(){return e}}(t):(t=l.length,function(e){for(var r,n=0;n<t;++n)s[(r=l[n]).i]=r.x(e);return s.join("")})}var om,am=180/Math.PI,sm={translateX:0,translateY:0,rotate:0,skewX:0,scaleX:1,scaleY:1};function lm(e,t,r,n,i,o){var a,s,l;return(a=Math.sqrt(e*e+t*t))&&(e/=a,t/=a),(l=e*r+t*n)&&(r-=e*l,n-=t*l),(s=Math.sqrt(r*r+n*n))&&(r/=s,n/=s,l/=s),e*n<t*r&&(e=-e,t=-t,l=-l,a=-a),{translateX:i,translateY:o,rotate:Math.atan2(t,e)*am,skewX:Math.atan(l)*am,scaleX:a,scaleY:s}}function cm(e,t,r,n){function i(e){return e.length?e.pop()+" ":""}return function(o,a){var s=[],l=[];return o=e(o),a=e(a),function(e,n,i,o,a,s){if(e!==i||n!==o){var l=a.push("translate(",null,t,null,r);s.push({i:l-4,x:tm(e,i)},{i:l-2,x:tm(n,o)})}else(i||o)&&a.push("translate("+i+t+o+r)}(o.translateX,o.translateY,a.translateX,a.translateY,s,l),function(e,t,r,o){e!==t?(e-t>180?t+=360:t-e>180&&(e+=360),o.push({i:r.push(i(r)+"rotate(",null,n)-2,x:tm(e,t)})):t&&r.push(i(r)+"rotate("+t+n)}(o.rotate,a.rotate,s,l),function(e,t,r,o){e!==t?o.push({i:r.push(i(r)+"skewX(",null,n)-2,x:tm(e,t)}):t&&r.push(i(r)+"skewX("+t+n)}(o.skewX,a.skewX,s,l),function(e,t,r,n,o,a){if(e!==r||t!==n){var s=o.push(i(o)+"scale(",null,",",null,")");a.push({i:s-4,x:tm(e,r)},{i:s-2,x:tm(t,n)})}else 1===r&&1===n||o.push(i(o)+"scale("+r+","+n+")")}(o.scaleX,o.scaleY,a.scaleX,a.scaleY,s,l),o=a=null,function(e){for(var t,r=-1,n=l.length;++r<n;)s[(t=l[r]).i]=t.x(e);return s.join("")}}}var um,hm,dm=cm(function(e){const t=new("function"==typeof DOMMatrix?DOMMatrix:WebKitCSSMatrix)(e+"");return t.isIdentity?sm:lm(t.a,t.b,t.c,t.d,t.e,t.f)},"px, ","px)","deg)"),pm=cm(function(e){return null==e?sm:(om||(om=document.createElementNS("http://www.w3.org/2000/svg","g")),om.setAttribute("transform",e),(e=om.transform.baseVal.consolidate())?lm((e=e.matrix).a,e.b,e.c,e.d,e.e,e.f):sm)},", ",")",")"),fm=0,gm=0,mm=0,ym=0,xm=0,bm=0,vm="object"==typeof performance&&performance.now?performance:Date,Cm="object"==typeof window&&window.requestAnimationFrame?window.requestAnimationFrame.bind(window):function(e){setTimeout(e,17)};function wm(){return xm||(Cm(km),xm=vm.now()+bm)}function km(){xm=0}function Sm(){this._call=this._time=this._next=null}function _m(e,t,r){var n=new Sm;return n.restart(e,t,r),n}function Tm(){xm=(ym=vm.now())+bm,fm=gm=0;try{!function(){wm(),++fm;for(var e,t=um;t;)(e=xm-t._time)>=0&&t._call.call(void 0,e),t=t._next;--fm}()}finally{fm=0,function(){var e,t,r=um,n=1/0;for(;r;)r._call?(n>r._time&&(n=r._time),e=r,r=r._next):(t=r._next,r._next=null,r=e?e._next=t:um=t);hm=e,Pm(n)}(),xm=0}}function Am(){var e=vm.now(),t=e-ym;t>1e3&&(bm-=t,ym=e)}function Pm(e){fm||(gm&&(gm=clearTimeout(gm)),e-xm>24?(e<1/0&&(gm=setTimeout(Tm,e-vm.now()-bm)),mm&&(mm=clearInterval(mm))):(mm||(ym=vm.now(),mm=setInterval(Am,1e3)),fm=1,Cm(Tm)))}function Em(e,t,r){var n=new Sm;return t=null==t?0:+t,n.restart(r=>{n.stop(),e(r+t)},t,r),n}Sm.prototype=_m.prototype={constructor:Sm,restart:function(e,t,r){if("function"!=typeof e)throw new TypeError("callback is not a function");r=(null==r?wm():+r)+(null==t?0:+t),this._next||hm===this||(hm?hm._next=this:um=this,hm=this),this._call=e,this._time=r,Pm()},stop:function(){this._call&&(this._call=null,this._time=1/0,Pm())}};var Mm=Zp("start","end","cancel","interrupt"),Im=[];function Bm(e,t,r,n,i,o){var a=e.__transition;if(a){if(r in a)return}else e.__transition={};!function(e,t,r){var n,i=e.__transition;function o(e){r.state=1,r.timer.restart(a,r.delay,r.time),r.delay<=e&&a(e-r.delay)}function a(o){var c,u,h,d;if(1!==r.state)return l();for(c in i)if((d=i[c]).name===r.name){if(3===d.state)return Em(a);4===d.state?(d.state=6,d.timer.stop(),d.on.call("interrupt",e,e.__data__,d.index,d.group),delete i[c]):+c<t&&(d.state=6,d.timer.stop(),d.on.call("cancel",e,e.__data__,d.index,d.group),delete i[c])}if(Em(function(){3===r.state&&(r.state=4,r.timer.restart(s,r.delay,r.time),s(o))}),r.state=2,r.on.call("start",e,e.__data__,r.index,r.group),2===r.state){for(r.state=3,n=new Array(h=r.tween.length),c=0,u=-1;c<h;++c)(d=r.tween[c].value.call(e,e.__data__,r.index,r.group))&&(n[++u]=d);n.length=u+1}}function s(t){for(var i=t<r.duration?r.ease.call(null,t/r.duration):(r.timer.restart(l),r.state=5,1),o=-1,a=n.length;++o<a;)n[o].call(e,i);5===r.state&&(r.on.call("end",e,e.__data__,r.index,r.group),l())}function l(){for(var n in r.state=6,r.timer.stop(),delete i[t],i)return;delete e.__transition}i[t]=r,r.timer=_m(o,0,r.time)}(e,r,{name:t,index:n,group:i,on:Mm,tween:Im,time:o.time,delay:o.delay,duration:o.duration,ease:o.ease,timer:null,state:0})}function Lm(e,t){var r=Nm(e,t);if(r.state>0)throw new Error("too late; already scheduled");return r}function jm(e,t){var r=Nm(e,t);if(r.state>3)throw new Error("too late; already running");return r}function Nm(e,t){var r=e.__transition;if(!r||!(r=r[t]))throw new Error("transition not found");return r}function Dm(e,t){var r,n;return function(){var i=jm(this,e),o=i.tween;if(o!==r)for(var a=0,s=(n=r=o).length;a<s;++a)if(n[a].name===t){(n=n.slice()).splice(a,1);break}i.tween=n}}function Om(e,t,r){var n,i;if("function"!=typeof r)throw new Error;return function(){var o=jm(this,e),a=o.tween;if(a!==n){i=(n=a).slice();for(var s={name:t,value:r},l=0,c=i.length;l<c;++l)if(i[l].name===t){i[l]=s;break}l===c&&i.push(s)}o.tween=i}}function Fm(e,t,r){var n=e._id;return e.each(function(){var e=jm(this,n);(e.value||(e.value={}))[t]=r.apply(this,arguments)}),function(e){return Nm(e,n).value[t]}}function Rm(e,t){var r;return("number"==typeof t?tm:t instanceof Lg?em:(r=Lg(t))?(t=r,em):im)(e,t)}function $m(e){return function(){this.removeAttribute(e)}}function zm(e){return function(){this.removeAttributeNS(e.space,e.local)}}function Vm(e,t,r){var n,i,o=r+"";return function(){var a=this.getAttribute(e);return a===o?null:a===n?i:i=t(n=a,r)}}function Wm(e,t,r){var n,i,o=r+"";return function(){var a=this.getAttributeNS(e.space,e.local);return a===o?null:a===n?i:i=t(n=a,r)}}function Hm(e,t,r){var n,i,o;return function(){var a,s,l=r(this);if(null!=l)return(a=this.getAttribute(e))===(s=l+"")?null:a===n&&s===i?o:(i=s,o=t(n=a,l));this.removeAttribute(e)}}function qm(e,t,r){var n,i,o;return function(){var a,s,l=r(this);if(null!=l)return(a=this.getAttributeNS(e.space,e.local))===(s=l+"")?null:a===n&&s===i?o:(i=s,o=t(n=a,l));this.removeAttributeNS(e.space,e.local)}}function Um(e,t){var r,n;function i(){var i=t.apply(this,arguments);return i!==n&&(r=(n=i)&&function(e,t){return function(r){this.setAttributeNS(e.space,e.local,t.call(this,r))}}(e,i)),r}return i._value=t,i}function Gm(e,t){var r,n;function i(){var i=t.apply(this,arguments);return i!==n&&(r=(n=i)&&function(e,t){return function(r){this.setAttribute(e,t.call(this,r))}}(e,i)),r}return i._value=t,i}function Xm(e,t){return function(){Lm(this,e).delay=+t.apply(this,arguments)}}function Jm(e,t){return t=+t,function(){Lm(this,e).delay=t}}function Ym(e,t){return function(){jm(this,e).duration=+t.apply(this,arguments)}}function Zm(e,t){return t=+t,function(){jm(this,e).duration=t}}var Km=pg.prototype.constructor;function Qm(e){return function(){this.style.removeProperty(e)}}var ey=0;function ty(e,t,r,n){this._groups=e,this._parents=t,this._name=r,this._id=n}function ry(){return++ey}var ny=pg.prototype;ty.prototype={constructor:ty,select:function(e){var t=this._name,r=this._id;"function"!=typeof e&&(e=cf(e));for(var n=this._groups,i=n.length,o=new Array(i),a=0;a<i;++a)for(var s,l,c=n[a],u=c.length,h=o[a]=new Array(u),d=0;d<u;++d)(s=c[d])&&(l=e.call(s,s.__data__,d,c))&&("__data__"in s&&(l.__data__=s.__data__),h[d]=l,Bm(h[d],t,r,d,h,Nm(s,r)));return new ty(o,this._parents,t,r)},selectAll:function(e){var t=this._name,r=this._id;"function"!=typeof e&&(e=hf(e));for(var n=this._groups,i=n.length,o=[],a=[],s=0;s<i;++s)for(var l,c=n[s],u=c.length,h=0;h<u;++h)if(l=c[h]){for(var d,p=e.call(l,l.__data__,h,c),f=Nm(l,r),g=0,m=p.length;g<m;++g)(d=p[g])&&Bm(d,t,r,g,p,f);o.push(p),a.push(l)}return new ty(o,a,t,r)},selectChild:ny.selectChild,selectChildren:ny.selectChildren,filter:function(e){"function"!=typeof e&&(e=pf(e));for(var t=this._groups,r=t.length,n=new Array(r),i=0;i<r;++i)for(var o,a=t[i],s=a.length,l=n[i]=[],c=0;c<s;++c)(o=a[c])&&e.call(o,o.__data__,c,a)&&l.push(o);return new ty(n,this._parents,this._name,this._id)},merge:function(e){if(e._id!==this._id)throw new Error;for(var t=this._groups,r=e._groups,n=t.length,i=r.length,o=Math.min(n,i),a=new Array(n),s=0;s<o;++s)for(var l,c=t[s],u=r[s],h=c.length,d=a[s]=new Array(h),p=0;p<h;++p)(l=c[p]||u[p])&&(d[p]=l);for(;s<n;++s)a[s]=t[s];return new ty(a,this._parents,this._name,this._id)},selection:function(){return new Km(this._groups,this._parents)},transition:function(){for(var e=this._name,t=this._id,r=ry(),n=this._groups,i=n.length,o=0;o<i;++o)for(var a,s=n[o],l=s.length,c=0;c<l;++c)if(a=s[c]){var u=Nm(a,t);Bm(a,e,r,c,s,{time:u.time+u.delay+u.duration,delay:0,duration:u.duration,ease:u.ease})}return new ty(n,this._parents,e,r)},call:ny.call,nodes:ny.nodes,node:ny.node,size:ny.size,empty:ny.empty,each:ny.each,on:function(e,t){var r=this._id;return arguments.length<2?Nm(this.node(),r).on.on(e):this.each(function(e,t,r){var n,i,o=function(e){return(e+"").trim().split(/^|\s+/).every(function(e){var t=e.indexOf(".");return t>=0&&(e=e.slice(0,t)),!e||"start"===e})}(t)?Lm:jm;return function(){var a=o(this,e),s=a.on;s!==n&&(i=(n=s).copy()).on(t,r),a.on=i}}(r,e,t))},attr:function(e,t){var r=nf(e),n="transform"===r?pm:Rm;return this.attrTween(e,"function"==typeof t?(r.local?qm:Hm)(r,n,Fm(this,"attr."+e,t)):null==t?(r.local?zm:$m)(r):(r.local?Wm:Vm)(r,n,t))},attrTween:function(e,t){var r="attr."+e;if(arguments.length<2)return(r=this.tween(r))&&r._value;if(null==t)return this.tween(r,null);if("function"!=typeof t)throw new Error;var n=nf(e);return this.tween(r,(n.local?Um:Gm)(n,t))},style:function(e,t,r){var n="transform"==(e+="")?dm:Rm;return null==t?this.styleTween(e,function(e,t){var r,n,i;return function(){var o=Df(this,e),a=(this.style.removeProperty(e),Df(this,e));return o===a?null:o===r&&a===n?i:i=t(r=o,n=a)}}(e,n)).on("end.style."+e,Qm(e)):"function"==typeof t?this.styleTween(e,function(e,t,r){var n,i,o;return function(){var a=Df(this,e),s=r(this),l=s+"";return null==s&&(this.style.removeProperty(e),l=s=Df(this,e)),a===l?null:a===n&&l===i?o:(i=l,o=t(n=a,s))}}(e,n,Fm(this,"style."+e,t))).each(function(e,t){var r,n,i,o,a="style."+t,s="end."+a;return function(){var l=jm(this,e),c=l.on,u=null==l.value[a]?o||(o=Qm(t)):void 0;c===r&&i===u||(n=(r=c).copy()).on(s,i=u),l.on=n}}(this._id,e)):this.styleTween(e,function(e,t,r){var n,i,o=r+"";return function(){var a=Df(this,e);return a===o?null:a===n?i:i=t(n=a,r)}}(e,n,t),r).on("end.style."+e,null)},styleTween:function(e,t,r){var n="style."+(e+="");if(arguments.length<2)return(n=this.tween(n))&&n._value;if(null==t)return this.tween(n,null);if("function"!=typeof t)throw new Error;return this.tween(n,function(e,t,r){var n,i;function o(){var o=t.apply(this,arguments);return o!==i&&(n=(i=o)&&function(e,t,r){return function(n){this.style.setProperty(e,t.call(this,n),r)}}(e,o,r)),n}return o._value=t,o}(e,t,null==r?"":r))},text:function(e){return this.tween("text","function"==typeof e?function(e){return function(){var t=e(this);this.textContent=null==t?"":t}}(Fm(this,"text",e)):function(e){return function(){this.textContent=e}}(null==e?"":e+""))},textTween:function(e){var t="text";if(arguments.length<1)return(t=this.tween(t))&&t._value;if(null==e)return this.tween(t,null);if("function"!=typeof e)throw new Error;return this.tween(t,function(e){var t,r;function n(){var n=e.apply(this,arguments);return n!==r&&(t=(r=n)&&function(e){return function(t){this.textContent=e.call(this,t)}}(n)),t}return n._value=e,n}(e))},remove:function(){return this.on("end.remove",(e=this._id,function(){var t=this.parentNode;for(var r in this.__transition)if(+r!==e)return;t&&t.removeChild(this)}));var e},tween:function(e,t){var r=this._id;if(e+="",arguments.length<2){for(var n,i=Nm(this.node(),r).tween,o=0,a=i.length;o<a;++o)if((n=i[o]).name===e)return n.value;return null}return this.each((null==t?Dm:Om)(r,e,t))},delay:function(e){var t=this._id;return arguments.length?this.each(("function"==typeof e?Xm:Jm)(t,e)):Nm(this.node(),t).delay},duration:function(e){var t=this._id;return arguments.length?this.each(("function"==typeof e?Ym:Zm)(t,e)):Nm(this.node(),t).duration},ease:function(e){var t=this._id;return arguments.length?this.each(function(e,t){if("function"!=typeof t)throw new Error;return function(){jm(this,e).ease=t}}(t,e)):Nm(this.node(),t).ease},easeVarying:function(e){if("function"!=typeof e)throw new Error;return this.each(function(e,t){return function(){var r=t.apply(this,arguments);if("function"!=typeof r)throw new Error;jm(this,e).ease=r}}(this._id,e))},end:function(){var e,t,r=this,n=r._id,i=r.size();return new Promise(function(o,a){var s={value:a},l={value:function(){0===--i&&o()}};r.each(function(){var r=jm(this,n),i=r.on;i!==e&&((t=(e=i).copy())._.cancel.push(s),t._.interrupt.push(s),t._.end.push(l)),r.on=t}),0===i&&o()})},[Symbol.iterator]:ny[Symbol.iterator]};var iy={time:null,delay:0,duration:250,ease:function(e){return((e*=2)<=1?e*e*e:(e-=2)*e*e+2)/2}};function oy(e,t){for(var r;!(r=e.__transition)||!(r=r[t]);)if(!(e=e.parentNode))throw new Error(`transition ${t} not found`);return r}pg.prototype.interrupt=function(e){return this.each(function(){!function(e,t){var r,n,i,o=e.__transition,a=!0;if(o){for(i in t=null==t?null:t+"",o)(r=o[i]).name===t?(n=r.state>2&&r.state<5,r.state=6,r.timer.stop(),r.on.call(n?"interrupt":"cancel",e,e.__data__,r.index,r.group),delete o[i]):a=!1;a&&delete e.__transition}}(this,e)})},pg.prototype.transition=function(e){var t,r;e instanceof ty?(t=e._id,e=e._name):(t=ry(),(r=iy).time=wm(),e=null==e?null:e+"");for(var n=this._groups,i=n.length,o=0;o<i;++o)for(var a,s=n[o],l=s.length,c=0;c<l;++c)(a=s[c])&&Bm(a,e,t,c,s,r||oy(a,t));return new ty(n,this._parents,e,t)};const ay=Math.PI,sy=2*ay,ly=1e-6,cy=sy-ly;function uy(e){this._+=e[0];for(let t=1,r=e.length;t<r;++t)this._+=arguments[t]+e[t]}class hy{constructor(e){this._x0=this._y0=this._x1=this._y1=null,this._="",this._append=null==e?uy:function(e){let t=Math.floor(e);if(!(t>=0))throw new Error(`invalid digits: ${e}`);if(t>15)return uy;const r=10**t;return function(e){this._+=e[0];for(let t=1,n=e.length;t<n;++t)this._+=Math.round(arguments[t]*r)/r+e[t]}}(e)}moveTo(e,t){this._append`M${this._x0=this._x1=+e},${this._y0=this._y1=+t}`}closePath(){null!==this._x1&&(this._x1=this._x0,this._y1=this._y0,this._append`Z`)}lineTo(e,t){this._append`L${this._x1=+e},${this._y1=+t}`}quadraticCurveTo(e,t,r,n){this._append`Q${+e},${+t},${this._x1=+r},${this._y1=+n}`}bezierCurveTo(e,t,r,n,i,o){this._append`C${+e},${+t},${+r},${+n},${this._x1=+i},${this._y1=+o}`}arcTo(e,t,r,n,i){if(e=+e,t=+t,r=+r,n=+n,(i=+i)<0)throw new Error(`negative radius: ${i}`);let o=this._x1,a=this._y1,s=r-e,l=n-t,c=o-e,u=a-t,h=c*c+u*u;if(null===this._x1)this._append`M${this._x1=e},${this._y1=t}`;else if(h>ly)if(Math.abs(u*s-l*c)>ly&&i){let d=r-o,p=n-a,f=s*s+l*l,g=d*d+p*p,m=Math.sqrt(f),y=Math.sqrt(h),x=i*Math.tan((ay-Math.acos((f+h-g)/(2*m*y)))/2),b=x/y,v=x/m;Math.abs(b-1)>ly&&this._append`L${e+b*c},${t+b*u}`,this._append`A${i},${i},0,0,${+(u*d>c*p)},${this._x1=e+v*s},${this._y1=t+v*l}`}else this._append`L${this._x1=e},${this._y1=t}`;else;}arc(e,t,r,n,i,o){if(e=+e,t=+t,o=!!o,(r=+r)<0)throw new Error(`negative radius: ${r}`);let a=r*Math.cos(n),s=r*Math.sin(n),l=e+a,c=t+s,u=1^o,h=o?n-i:i-n;null===this._x1?this._append`M${l},${c}`:(Math.abs(this._x1-l)>ly||Math.abs(this._y1-c)>ly)&&this._append`L${l},${c}`,r&&(h<0&&(h=h%sy+sy),h>cy?this._append`A${r},${r},0,1,${u},${e-a},${t-s}A${r},${r},0,1,${u},${this._x1=l},${this._y1=c}`:h>ly&&this._append`A${r},${r},0,${+(h>=ay)},${u},${this._x1=e+r*Math.cos(i)},${this._y1=t+r*Math.sin(i)}`)}rect(e,t,r,n){this._append`M${this._x0=this._x1=+e},${this._y0=this._y1=+t}h${r=+r}v${+n}h${-r}Z`}toString(){return this._}}function dy(e){return function(){return e}}const py=Math.abs,fy=Math.atan2,gy=Math.cos,my=Math.max,yy=Math.min,xy=Math.sin,by=Math.sqrt,vy=1e-12,Cy=Math.PI,wy=Cy/2,ky=2*Cy;function Sy(e){let t=3;return e.digits=function(r){if(!arguments.length)return t;if(null==r)t=null;else{const e=Math.floor(r);if(!(e>=0))throw new RangeError(`invalid digits: ${r}`);t=e}return e},()=>new hy(t)}function _y(e){return"object"==typeof e&&"length"in e?e:Array.from(e)}function Ty(e){this._context=e}function Ay(e){return new Ty(e)}function Py(e){return e[0]}function Ey(e){return e[1]}function My(e,t){var r=dy(!0),n=null,i=Ay,o=null,a=Sy(s);function s(s){var l,c,u,h=(s=_y(s)).length,d=!1;for(null==n&&(o=i(u=a())),l=0;l<=h;++l)!(l<h&&r(c=s[l],l,s))===d&&((d=!d)?o.lineStart():o.lineEnd()),d&&o.point(+e(c,l,s),+t(c,l,s));if(u)return o=null,u+""||null}return e="function"==typeof e?e:void 0===e?Py:dy(e),t="function"==typeof t?t:void 0===t?Ey:dy(t),s.x=function(t){return arguments.length?(e="function"==typeof t?t:dy(+t),s):e},s.y=function(e){return arguments.length?(t="function"==typeof e?e:dy(+e),s):t},s.defined=function(e){return arguments.length?(r="function"==typeof e?e:dy(!!e),s):r},s.curve=function(e){return arguments.length?(i=e,null!=n&&(o=i(n)),s):i},s.context=function(e){return arguments.length?(null==e?n=o=null:o=i(n=e),s):n},s}Ty.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._point=0},lineEnd:function(){(this._line||0!==this._line&&1===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2;default:this._context.lineTo(e,t)}}};class Iy{constructor(e,t){this._context=e,this._x=t}areaStart(){this._line=0}areaEnd(){this._line=NaN}lineStart(){this._point=0}lineEnd(){(this._line||0!==this._line&&1===this._point)&&this._context.closePath(),this._line=1-this._line}point(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2;default:this._x?this._context.bezierCurveTo(this._x0=(this._x0+e)/2,this._y0,this._x0,t,e,t):this._context.bezierCurveTo(this._x0,this._y0=(this._y0+t)/2,e,this._y0,e,t)}this._x0=e,this._y0=t}}function By(e){return new Iy(e,!0)}function Ly(e){return new Iy(e,!1)}function jy(){}function Ny(e,t,r){e._context.bezierCurveTo((2*e._x0+e._x1)/3,(2*e._y0+e._y1)/3,(e._x0+2*e._x1)/3,(e._y0+2*e._y1)/3,(e._x0+4*e._x1+t)/6,(e._y0+4*e._y1+r)/6)}function Dy(e){this._context=e}function Oy(e){return new Dy(e)}function Fy(e){this._context=e}function Ry(e){this._context=e}function $y(e,t){this._basis=new Dy(e),this._beta=t}Dy.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._y0=this._y1=NaN,this._point=0},lineEnd:function(){switch(this._point){case 3:Ny(this,this._x1,this._y1);case 2:this._context.lineTo(this._x1,this._y1)}(this._line||0!==this._line&&1===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2;break;case 2:this._point=3,this._context.lineTo((5*this._x0+this._x1)/6,(5*this._y0+this._y1)/6);default:Ny(this,e,t)}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}},Fy.prototype={areaStart:jy,areaEnd:jy,lineStart:function(){this._x0=this._x1=this._x2=this._x3=this._x4=this._y0=this._y1=this._y2=this._y3=this._y4=NaN,this._point=0},lineEnd:function(){switch(this._point){case 1:this._context.moveTo(this._x2,this._y2),this._context.closePath();break;case 2:this._context.moveTo((this._x2+2*this._x3)/3,(this._y2+2*this._y3)/3),this._context.lineTo((this._x3+2*this._x2)/3,(this._y3+2*this._y2)/3),this._context.closePath();break;case 3:this.point(this._x2,this._y2),this.point(this._x3,this._y3),this.point(this._x4,this._y4)}},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._x2=e,this._y2=t;break;case 1:this._point=2,this._x3=e,this._y3=t;break;case 2:this._point=3,this._x4=e,this._y4=t,this._context.moveTo((this._x0+4*this._x1+e)/6,(this._y0+4*this._y1+t)/6);break;default:Ny(this,e,t)}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}},Ry.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._y0=this._y1=NaN,this._point=0},lineEnd:function(){(this._line||0!==this._line&&3===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1;break;case 1:this._point=2;break;case 2:this._point=3;var r=(this._x0+4*this._x1+e)/6,n=(this._y0+4*this._y1+t)/6;this._line?this._context.lineTo(r,n):this._context.moveTo(r,n);break;case 3:this._point=4;default:Ny(this,e,t)}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}},$y.prototype={lineStart:function(){this._x=[],this._y=[],this._basis.lineStart()},lineEnd:function(){var e=this._x,t=this._y,r=e.length-1;if(r>0)for(var n,i=e[0],o=t[0],a=e[r]-i,s=t[r]-o,l=-1;++l<=r;)n=l/r,this._basis.point(this._beta*e[l]+(1-this._beta)*(i+n*a),this._beta*t[l]+(1-this._beta)*(o+n*s));this._x=this._y=null,this._basis.lineEnd()},point:function(e,t){this._x.push(+e),this._y.push(+t)}};const zy=function e(t){function r(e){return 1===t?new Dy(e):new $y(e,t)}return r.beta=function(t){return e(+t)},r}(.85);function Vy(e,t,r){e._context.bezierCurveTo(e._x1+e._k*(e._x2-e._x0),e._y1+e._k*(e._y2-e._y0),e._x2+e._k*(e._x1-t),e._y2+e._k*(e._y1-r),e._x2,e._y2)}function Wy(e,t){this._context=e,this._k=(1-t)/6}Wy.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._point=0},lineEnd:function(){switch(this._point){case 2:this._context.lineTo(this._x2,this._y2);break;case 3:Vy(this,this._x1,this._y1)}(this._line||0!==this._line&&1===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2,this._x1=e,this._y1=t;break;case 2:this._point=3;default:Vy(this,e,t)}this._x0=this._x1,this._x1=this._x2,this._x2=e,this._y0=this._y1,this._y1=this._y2,this._y2=t}};const Hy=function e(t){function r(e){return new Wy(e,t)}return r.tension=function(t){return e(+t)},r}(0);function qy(e,t){this._context=e,this._k=(1-t)/6}qy.prototype={areaStart:jy,areaEnd:jy,lineStart:function(){this._x0=this._x1=this._x2=this._x3=this._x4=this._x5=this._y0=this._y1=this._y2=this._y3=this._y4=this._y5=NaN,this._point=0},lineEnd:function(){switch(this._point){case 1:this._context.moveTo(this._x3,this._y3),this._context.closePath();break;case 2:this._context.lineTo(this._x3,this._y3),this._context.closePath();break;case 3:this.point(this._x3,this._y3),this.point(this._x4,this._y4),this.point(this._x5,this._y5)}},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._x3=e,this._y3=t;break;case 1:this._point=2,this._context.moveTo(this._x4=e,this._y4=t);break;case 2:this._point=3,this._x5=e,this._y5=t;break;default:Vy(this,e,t)}this._x0=this._x1,this._x1=this._x2,this._x2=e,this._y0=this._y1,this._y1=this._y2,this._y2=t}};const Uy=function e(t){function r(e){return new qy(e,t)}return r.tension=function(t){return e(+t)},r}(0);function Gy(e,t){this._context=e,this._k=(1-t)/6}Gy.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._point=0},lineEnd:function(){(this._line||0!==this._line&&3===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1;break;case 1:this._point=2;break;case 2:this._point=3,this._line?this._context.lineTo(this._x2,this._y2):this._context.moveTo(this._x2,this._y2);break;case 3:this._point=4;default:Vy(this,e,t)}this._x0=this._x1,this._x1=this._x2,this._x2=e,this._y0=this._y1,this._y1=this._y2,this._y2=t}};const Xy=function e(t){function r(e){return new Gy(e,t)}return r.tension=function(t){return e(+t)},r}(0);function Jy(e,t,r){var n=e._x1,i=e._y1,o=e._x2,a=e._y2;if(e._l01_a>vy){var s=2*e._l01_2a+3*e._l01_a*e._l12_a+e._l12_2a,l=3*e._l01_a*(e._l01_a+e._l12_a);n=(n*s-e._x0*e._l12_2a+e._x2*e._l01_2a)/l,i=(i*s-e._y0*e._l12_2a+e._y2*e._l01_2a)/l}if(e._l23_a>vy){var c=2*e._l23_2a+3*e._l23_a*e._l12_a+e._l12_2a,u=3*e._l23_a*(e._l23_a+e._l12_a);o=(o*c+e._x1*e._l23_2a-t*e._l12_2a)/u,a=(a*c+e._y1*e._l23_2a-r*e._l12_2a)/u}e._context.bezierCurveTo(n,i,o,a,e._x2,e._y2)}function Yy(e,t){this._context=e,this._alpha=t}Yy.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._l01_a=this._l12_a=this._l23_a=this._l01_2a=this._l12_2a=this._l23_2a=this._point=0},lineEnd:function(){switch(this._point){case 2:this._context.lineTo(this._x2,this._y2);break;case 3:this.point(this._x2,this._y2)}(this._line||0!==this._line&&1===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){if(e=+e,t=+t,this._point){var r=this._x2-e,n=this._y2-t;this._l23_a=Math.sqrt(this._l23_2a=Math.pow(r*r+n*n,this._alpha))}switch(this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2;break;case 2:this._point=3;default:Jy(this,e,t)}this._l01_a=this._l12_a,this._l12_a=this._l23_a,this._l01_2a=this._l12_2a,this._l12_2a=this._l23_2a,this._x0=this._x1,this._x1=this._x2,this._x2=e,this._y0=this._y1,this._y1=this._y2,this._y2=t}};const Zy=function e(t){function r(e){return t?new Yy(e,t):new Wy(e,0)}return r.alpha=function(t){return e(+t)},r}(.5);function Ky(e,t){this._context=e,this._alpha=t}Ky.prototype={areaStart:jy,areaEnd:jy,lineStart:function(){this._x0=this._x1=this._x2=this._x3=this._x4=this._x5=this._y0=this._y1=this._y2=this._y3=this._y4=this._y5=NaN,this._l01_a=this._l12_a=this._l23_a=this._l01_2a=this._l12_2a=this._l23_2a=this._point=0},lineEnd:function(){switch(this._point){case 1:this._context.moveTo(this._x3,this._y3),this._context.closePath();break;case 2:this._context.lineTo(this._x3,this._y3),this._context.closePath();break;case 3:this.point(this._x3,this._y3),this.point(this._x4,this._y4),this.point(this._x5,this._y5)}},point:function(e,t){if(e=+e,t=+t,this._point){var r=this._x2-e,n=this._y2-t;this._l23_a=Math.sqrt(this._l23_2a=Math.pow(r*r+n*n,this._alpha))}switch(this._point){case 0:this._point=1,this._x3=e,this._y3=t;break;case 1:this._point=2,this._context.moveTo(this._x4=e,this._y4=t);break;case 2:this._point=3,this._x5=e,this._y5=t;break;default:Jy(this,e,t)}this._l01_a=this._l12_a,this._l12_a=this._l23_a,this._l01_2a=this._l12_2a,this._l12_2a=this._l23_2a,this._x0=this._x1,this._x1=this._x2,this._x2=e,this._y0=this._y1,this._y1=this._y2,this._y2=t}};const Qy=function e(t){function r(e){return t?new Ky(e,t):new qy(e,0)}return r.alpha=function(t){return e(+t)},r}(.5);function ex(e,t){this._context=e,this._alpha=t}ex.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._l01_a=this._l12_a=this._l23_a=this._l01_2a=this._l12_2a=this._l23_2a=this._point=0},lineEnd:function(){(this._line||0!==this._line&&3===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){if(e=+e,t=+t,this._point){var r=this._x2-e,n=this._y2-t;this._l23_a=Math.sqrt(this._l23_2a=Math.pow(r*r+n*n,this._alpha))}switch(this._point){case 0:this._point=1;break;case 1:this._point=2;break;case 2:this._point=3,this._line?this._context.lineTo(this._x2,this._y2):this._context.moveTo(this._x2,this._y2);break;case 3:this._point=4;default:Jy(this,e,t)}this._l01_a=this._l12_a,this._l12_a=this._l23_a,this._l01_2a=this._l12_2a,this._l12_2a=this._l23_2a,this._x0=this._x1,this._x1=this._x2,this._x2=e,this._y0=this._y1,this._y1=this._y2,this._y2=t}};const tx=function e(t){function r(e){return t?new ex(e,t):new Gy(e,0)}return r.alpha=function(t){return e(+t)},r}(.5);function rx(e){this._context=e}function nx(e){return e<0?-1:1}function ix(e,t,r){var n=e._x1-e._x0,i=t-e._x1,o=(e._y1-e._y0)/(n||i<0&&-0),a=(r-e._y1)/(i||n<0&&-0),s=(o*i+a*n)/(n+i);return(nx(o)+nx(a))*Math.min(Math.abs(o),Math.abs(a),.5*Math.abs(s))||0}function ox(e,t){var r=e._x1-e._x0;return r?(3*(e._y1-e._y0)/r-t)/2:t}function ax(e,t,r){var n=e._x0,i=e._y0,o=e._x1,a=e._y1,s=(o-n)/3;e._context.bezierCurveTo(n+s,i+s*t,o-s,a-s*r,o,a)}function sx(e){this._context=e}function lx(e){this._context=new cx(e)}function cx(e){this._context=e}function ux(e){return new sx(e)}function hx(e){return new lx(e)}function dx(e){this._context=e}function px(e){var t,r,n=e.length-1,i=new Array(n),o=new Array(n),a=new Array(n);for(i[0]=0,o[0]=2,a[0]=e[0]+2*e[1],t=1;t<n-1;++t)i[t]=1,o[t]=4,a[t]=4*e[t]+2*e[t+1];for(i[n-1]=2,o[n-1]=7,a[n-1]=8*e[n-1]+e[n],t=1;t<n;++t)r=i[t]/o[t-1],o[t]-=r,a[t]-=r*a[t-1];for(i[n-1]=a[n-1]/o[n-1],t=n-2;t>=0;--t)i[t]=(a[t]-i[t+1])/o[t];for(o[n-1]=(e[n]+i[n-1])/2,t=0;t<n-1;++t)o[t]=2*e[t+1]-i[t+1];return[i,o]}function fx(e){return new dx(e)}function gx(e,t){this._context=e,this._t=t}function mx(e){return new gx(e,.5)}function yx(e){return new gx(e,0)}function xx(e){return new gx(e,1)}function bx(e,t,r){this.k=e,this.x=t,this.y=r}rx.prototype={areaStart:jy,areaEnd:jy,lineStart:function(){this._point=0},lineEnd:function(){this._point&&this._context.closePath()},point:function(e,t){e=+e,t=+t,this._point?this._context.lineTo(e,t):(this._point=1,this._context.moveTo(e,t))}},sx.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._y0=this._y1=this._t0=NaN,this._point=0},lineEnd:function(){switch(this._point){case 2:this._context.lineTo(this._x1,this._y1);break;case 3:ax(this,this._t0,ox(this,this._t0))}(this._line||0!==this._line&&1===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){var r=NaN;if(t=+t,(e=+e)!==this._x1||t!==this._y1){switch(this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2;break;case 2:this._point=3,ax(this,ox(this,r=ix(this,e,t)),r);break;default:ax(this,this._t0,r=ix(this,e,t))}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t,this._t0=r}}},(lx.prototype=Object.create(sx.prototype)).point=function(e,t){sx.prototype.point.call(this,t,e)},cx.prototype={moveTo:function(e,t){this._context.moveTo(t,e)},closePath:function(){this._context.closePath()},lineTo:function(e,t){this._context.lineTo(t,e)},bezierCurveTo:function(e,t,r,n,i,o){this._context.bezierCurveTo(t,e,n,r,o,i)}},dx.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x=[],this._y=[]},lineEnd:function(){var e=this._x,t=this._y,r=e.length;if(r)if(this._line?this._context.lineTo(e[0],t[0]):this._context.moveTo(e[0],t[0]),2===r)this._context.lineTo(e[1],t[1]);else for(var n=px(e),i=px(t),o=0,a=1;a<r;++o,++a)this._context.bezierCurveTo(n[0][o],i[0][o],n[1][o],i[1][o],e[a],t[a]);(this._line||0!==this._line&&1===r)&&this._context.closePath(),this._line=1-this._line,this._x=this._y=null},point:function(e,t){this._x.push(+e),this._y.push(+t)}},gx.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x=this._y=NaN,this._point=0},lineEnd:function(){0<this._t&&this._t<1&&2===this._point&&this._context.lineTo(this._x,this._y),(this._line||0!==this._line&&1===this._point)&&this._context.closePath(),this._line>=0&&(this._t=1-this._t,this._line=1-this._line)},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2;default:if(this._t<=0)this._context.lineTo(this._x,t),this._context.lineTo(e,t);else{var r=this._x*(1-this._t)+e*this._t;this._context.lineTo(r,this._y),this._context.lineTo(r,t)}}this._x=e,this._y=t}},bx.prototype={constructor:bx,scale:function(e){return 1===e?this:new bx(this.k*e,this.x,this.y)},translate:function(e,t){return 0===e&0===t?this:new bx(this.k,this.x+this.k*e,this.y+this.k*t)},apply:function(e){return[e[0]*this.k+this.x,e[1]*this.k+this.y]},applyX:function(e){return e*this.k+this.x},applyY:function(e){return e*this.k+this.y},invert:function(e){return[(e[0]-this.x)/this.k,(e[1]-this.y)/this.k]},invertX:function(e){return(e-this.x)/this.k},invertY:function(e){return(e-this.y)/this.k},rescaleX:function(e){return e.copy().domain(e.range().map(this.invertX,this).map(e.invert,e))},rescaleY:function(e){return e.copy().domain(e.range().map(this.invertY,this).map(e.invert,e))},toString:function(){return"translate("+this.x+","+this.y+") scale("+this.k+")"}},bx.prototype;var vx=mu(e=>{var t;const{securityLevel:r}=$p();let n=fg("body");if("sandbox"===r){const r=fg(`#i${e}`);n=fg(((null==(t=r.node())?void 0:t.contentDocument)??document).body)}return n.select(`#${e}`)},"selectSvgElement");function Cx(e){return null==e}function wx(e){return"object"==typeof e&&null!==e}function kx(e){return Array.isArray(e)?e:Cx(e)?[]:[e]}function Sx(e,t){var r,n,i,o;if(t)for(r=0,n=(o=Object.keys(t)).length;r<n;r+=1)e[i=o[r]]=t[i];return e}function _x(e,t){var r,n="";for(r=0;r<t;r+=1)n+=e;return n}function Tx(e){return 0===e&&Number.NEGATIVE_INFINITY===1/e}mu(Cx,"isNothing"),mu(wx,"isObject"),mu(kx,"toArray"),mu(Sx,"extend"),mu(_x,"repeat"),mu(Tx,"isNegativeZero");var Ax={isNothing:Cx,isObject:wx,toArray:kx,repeat:_x,isNegativeZero:Tx,extend:Sx};function Px(e,t){var r="",n=e.reason||"(unknown reason)";return e.mark?(e.mark.name&&(r+='in "'+e.mark.name+'" '),r+="("+(e.mark.line+1)+":"+(e.mark.column+1)+")",!t&&e.mark.snippet&&(r+="\n\n"+e.mark.snippet),n+" "+r):n}function Ex(e,t){Error.call(this),this.name="YAMLException",this.reason=e,this.mark=t,this.message=Px(this,!1),Error.captureStackTrace?Error.captureStackTrace(this,this.constructor):this.stack=(new Error).stack||""}mu(Px,"formatError"),mu(Ex,"YAMLException$1"),Ex.prototype=Object.create(Error.prototype),Ex.prototype.constructor=Ex,Ex.prototype.toString=mu(function(e){return this.name+": "+Px(this,e)},"toString");var Mx=Ex;function Ix(e,t,r,n,i){var o="",a="",s=Math.floor(i/2)-1;return n-t>s&&(t=n-s+(o=" ... ").length),r-n>s&&(r=n+s-(a=" ...").length),{str:o+e.slice(t,r).replace(/\t/g,"→")+a,pos:n-t+o.length}}function Bx(e,t){return Ax.repeat(" ",t-e.length)+e}function Lx(e,t){if(t=Object.create(t||null),!e.buffer)return null;t.maxLength||(t.maxLength=79),"number"!=typeof t.indent&&(t.indent=1),"number"!=typeof t.linesBefore&&(t.linesBefore=3),"number"!=typeof t.linesAfter&&(t.linesAfter=2);for(var r,n=/\r?\n|\r|\0/g,i=[0],o=[],a=-1;r=n.exec(e.buffer);)o.push(r.index),i.push(r.index+r[0].length),e.position<=r.index&&a<0&&(a=i.length-2);a<0&&(a=i.length-1);var s,l,c="",u=Math.min(e.line+t.linesAfter,o.length).toString().length,h=t.maxLength-(t.indent+u+3);for(s=1;s<=t.linesBefore&&!(a-s<0);s++)l=Ix(e.buffer,i[a-s],o[a-s],e.position-(i[a]-i[a-s]),h),c=Ax.repeat(" ",t.indent)+Bx((e.line-s+1).toString(),u)+" | "+l.str+"\n"+c;for(l=Ix(e.buffer,i[a],o[a],e.position,h),c+=Ax.repeat(" ",t.indent)+Bx((e.line+1).toString(),u)+" | "+l.str+"\n",c+=Ax.repeat("-",t.indent+u+3+l.pos)+"^\n",s=1;s<=t.linesAfter&&!(a+s>=o.length);s++)l=Ix(e.buffer,i[a+s],o[a+s],e.position-(i[a]-i[a+s]),h),c+=Ax.repeat(" ",t.indent)+Bx((e.line+s+1).toString(),u)+" | "+l.str+"\n";return c.replace(/\n$/,"")}mu(Ix,"getLine"),mu(Bx,"padStart"),mu(Lx,"makeSnippet");var jx=Lx,Nx=["kind","multi","resolve","construct","instanceOf","predicate","represent","representName","defaultStyle","styleAliases"],Dx=["scalar","sequence","mapping"];function Ox(e){var t={};return null!==e&&Object.keys(e).forEach(function(r){e[r].forEach(function(e){t[String(e)]=r})}),t}function Fx(e,t){if(t=t||{},Object.keys(t).forEach(function(t){if(-1===Nx.indexOf(t))throw new Mx('Unknown option "'+t+'" is met in definition of "'+e+'" YAML type.')}),this.options=t,this.tag=e,this.kind=t.kind||null,this.resolve=t.resolve||function(){return!0},this.construct=t.construct||function(e){return e},this.instanceOf=t.instanceOf||null,this.predicate=t.predicate||null,this.represent=t.represent||null,this.representName=t.representName||null,this.defaultStyle=t.defaultStyle||null,this.multi=t.multi||!1,this.styleAliases=Ox(t.styleAliases||null),-1===Dx.indexOf(this.kind))throw new Mx('Unknown kind "'+this.kind+'" is specified for "'+e+'" YAML type.')}mu(Ox,"compileStyleAliases"),mu(Fx,"Type$1");var Rx=Fx;function $x(e,t){var r=[];return e[t].forEach(function(e){var t=r.length;r.forEach(function(r,n){r.tag===e.tag&&r.kind===e.kind&&r.multi===e.multi&&(t=n)}),r[t]=e}),r}function zx(){var e,t,r={scalar:{},sequence:{},mapping:{},fallback:{},multi:{scalar:[],sequence:[],mapping:[],fallback:[]}};function n(e){e.multi?(r.multi[e.kind].push(e),r.multi.fallback.push(e)):r[e.kind][e.tag]=r.fallback[e.tag]=e}for(mu(n,"collectType"),e=0,t=arguments.length;e<t;e+=1)arguments[e].forEach(n);return r}function Vx(e){return this.extend(e)}mu($x,"compileList"),mu(zx,"compileMap"),mu(Vx,"Schema$1"),Vx.prototype.extend=mu(function(e){var t=[],r=[];if(e instanceof Rx)r.push(e);else if(Array.isArray(e))r=r.concat(e);else{if(!e||!Array.isArray(e.implicit)&&!Array.isArray(e.explicit))throw new Mx("Schema.extend argument should be a Type, [ Type ], or a schema definition ({ implicit: [...], explicit: [...] })");e.implicit&&(t=t.concat(e.implicit)),e.explicit&&(r=r.concat(e.explicit))}t.forEach(function(e){if(!(e instanceof Rx))throw new Mx("Specified list of YAML types (or a single Type object) contains a non-Type object.");if(e.loadKind&&"scalar"!==e.loadKind)throw new Mx("There is a non-scalar type in the implicit list of a schema. Implicit resolving of such types is not supported.");if(e.multi)throw new Mx("There is a multi type in the implicit list of a schema. Multi tags can only be listed as explicit.")}),r.forEach(function(e){if(!(e instanceof Rx))throw new Mx("Specified list of YAML types (or a single Type object) contains a non-Type object.")});var n=Object.create(Vx.prototype);return n.implicit=(this.implicit||[]).concat(t),n.explicit=(this.explicit||[]).concat(r),n.compiledImplicit=$x(n,"implicit"),n.compiledExplicit=$x(n,"explicit"),n.compiledTypeMap=zx(n.compiledImplicit,n.compiledExplicit),n},"extend");var Wx=new Vx({explicit:[new Rx("tag:yaml.org,2002:str",{kind:"scalar",construct:mu(function(e){return null!==e?e:""},"construct")}),new Rx("tag:yaml.org,2002:seq",{kind:"sequence",construct:mu(function(e){return null!==e?e:[]},"construct")}),new Rx("tag:yaml.org,2002:map",{kind:"mapping",construct:mu(function(e){return null!==e?e:{}},"construct")})]});function Hx(e){if(null===e)return!0;var t=e.length;return 1===t&&"~"===e||4===t&&("null"===e||"Null"===e||"NULL"===e)}function qx(){return null}function Ux(e){return null===e}mu(Hx,"resolveYamlNull"),mu(qx,"constructYamlNull"),mu(Ux,"isNull");var Gx=new Rx("tag:yaml.org,2002:null",{kind:"scalar",resolve:Hx,construct:qx,predicate:Ux,represent:{canonical:mu(function(){return"~"},"canonical"),lowercase:mu(function(){return"null"},"lowercase"),uppercase:mu(function(){return"NULL"},"uppercase"),camelcase:mu(function(){return"Null"},"camelcase"),empty:mu(function(){return""},"empty")},defaultStyle:"lowercase"});function Xx(e){if(null===e)return!1;var t=e.length;return 4===t&&("true"===e||"True"===e||"TRUE"===e)||5===t&&("false"===e||"False"===e||"FALSE"===e)}function Jx(e){return"true"===e||"True"===e||"TRUE"===e}function Yx(e){return"[object Boolean]"===Object.prototype.toString.call(e)}mu(Xx,"resolveYamlBoolean"),mu(Jx,"constructYamlBoolean"),mu(Yx,"isBoolean");var Zx=new Rx("tag:yaml.org,2002:bool",{kind:"scalar",resolve:Xx,construct:Jx,predicate:Yx,represent:{lowercase:mu(function(e){return e?"true":"false"},"lowercase"),uppercase:mu(function(e){return e?"TRUE":"FALSE"},"uppercase"),camelcase:mu(function(e){return e?"True":"False"},"camelcase")},defaultStyle:"lowercase"});function Kx(e){return 48<=e&&e<=57||65<=e&&e<=70||97<=e&&e<=102}function Qx(e){return 48<=e&&e<=55}function eb(e){return 48<=e&&e<=57}function tb(e){if(null===e)return!1;var t,r=e.length,n=0,i=!1;if(!r)return!1;if("-"!==(t=e[n])&&"+"!==t||(t=e[++n]),"0"===t){if(n+1===r)return!0;if("b"===(t=e[++n])){for(n++;n<r;n++)if("_"!==(t=e[n])){if("0"!==t&&"1"!==t)return!1;i=!0}return i&&"_"!==t}if("x"===t){for(n++;n<r;n++)if("_"!==(t=e[n])){if(!Kx(e.charCodeAt(n)))return!1;i=!0}return i&&"_"!==t}if("o"===t){for(n++;n<r;n++)if("_"!==(t=e[n])){if(!Qx(e.charCodeAt(n)))return!1;i=!0}return i&&"_"!==t}}if("_"===t)return!1;for(;n<r;n++)if("_"!==(t=e[n])){if(!eb(e.charCodeAt(n)))return!1;i=!0}return!(!i||"_"===t)}function rb(e){var t,r=e,n=1;if(-1!==r.indexOf("_")&&(r=r.replace(/_/g,"")),"-"!==(t=r[0])&&"+"!==t||("-"===t&&(n=-1),t=(r=r.slice(1))[0]),"0"===r)return 0;if("0"===t){if("b"===r[1])return n*parseInt(r.slice(2),2);if("x"===r[1])return n*parseInt(r.slice(2),16);if("o"===r[1])return n*parseInt(r.slice(2),8)}return n*parseInt(r,10)}function nb(e){return"[object Number]"===Object.prototype.toString.call(e)&&e%1==0&&!Ax.isNegativeZero(e)}mu(Kx,"isHexCode"),mu(Qx,"isOctCode"),mu(eb,"isDecCode"),mu(tb,"resolveYamlInteger"),mu(rb,"constructYamlInteger"),mu(nb,"isInteger");var ib=new Rx("tag:yaml.org,2002:int",{kind:"scalar",resolve:tb,construct:rb,predicate:nb,represent:{binary:mu(function(e){return e>=0?"0b"+e.toString(2):"-0b"+e.toString(2).slice(1)},"binary"),octal:mu(function(e){return e>=0?"0o"+e.toString(8):"-0o"+e.toString(8).slice(1)},"octal"),decimal:mu(function(e){return e.toString(10)},"decimal"),hexadecimal:mu(function(e){return e>=0?"0x"+e.toString(16).toUpperCase():"-0x"+e.toString(16).toUpperCase().slice(1)},"hexadecimal")},defaultStyle:"decimal",styleAliases:{binary:[2,"bin"],octal:[8,"oct"],decimal:[10,"dec"],hexadecimal:[16,"hex"]}}),ob=new RegExp("^(?:[-+]?(?:[0-9][0-9_]*)(?:\\.[0-9_]*)?(?:[eE][-+]?[0-9]+)?|\\.[0-9_]+(?:[eE][-+]?[0-9]+)?|[-+]?\\.(?:inf|Inf|INF)|\\.(?:nan|NaN|NAN))$");function ab(e){return null!==e&&!(!ob.test(e)||"_"===e[e.length-1])}function sb(e){var t,r;return r="-"===(t=e.replace(/_/g,"").toLowerCase())[0]?-1:1,"+-".indexOf(t[0])>=0&&(t=t.slice(1)),".inf"===t?1===r?Number.POSITIVE_INFINITY:Number.NEGATIVE_INFINITY:".nan"===t?NaN:r*parseFloat(t,10)}mu(ab,"resolveYamlFloat"),mu(sb,"constructYamlFloat");var lb=/^[-+]?[0-9]+e/;function cb(e,t){var r;if(isNaN(e))switch(t){case"lowercase":return".nan";case"uppercase":return".NAN";case"camelcase":return".NaN"}else if(Number.POSITIVE_INFINITY===e)switch(t){case"lowercase":return".inf";case"uppercase":return".INF";case"camelcase":return".Inf"}else if(Number.NEGATIVE_INFINITY===e)switch(t){case"lowercase":return"-.inf";case"uppercase":return"-.INF";case"camelcase":return"-.Inf"}else if(Ax.isNegativeZero(e))return"-0.0";return r=e.toString(10),lb.test(r)?r.replace("e",".e"):r}function ub(e){return"[object Number]"===Object.prototype.toString.call(e)&&(e%1!=0||Ax.isNegativeZero(e))}mu(cb,"representYamlFloat"),mu(ub,"isFloat");var hb=new Rx("tag:yaml.org,2002:float",{kind:"scalar",resolve:ab,construct:sb,predicate:ub,represent:cb,defaultStyle:"lowercase"}),db=Wx.extend({implicit:[Gx,Zx,ib,hb]}),pb=db,fb=new RegExp("^([0-9][0-9][0-9][0-9])-([0-9][0-9])-([0-9][0-9])$"),gb=new RegExp("^([0-9][0-9][0-9][0-9])-([0-9][0-9]?)-([0-9][0-9]?)(?:[Tt]|[ \\t]+)([0-9][0-9]?):([0-9][0-9]):([0-9][0-9])(?:\\.([0-9]*))?(?:[ \\t]*(Z|([-+])([0-9][0-9]?)(?::([0-9][0-9]))?))?$");function mb(e){return null!==e&&(null!==fb.exec(e)||null!==gb.exec(e))}function yb(e){var t,r,n,i,o,a,s,l,c=0,u=null;if(null===(t=fb.exec(e))&&(t=gb.exec(e)),null===t)throw new Error("Date resolve error");if(r=+t[1],n=+t[2]-1,i=+t[3],!t[4])return new Date(Date.UTC(r,n,i));if(o=+t[4],a=+t[5],s=+t[6],t[7]){for(c=t[7].slice(0,3);c.length<3;)c+="0";c=+c}return t[9]&&(u=6e4*(60*+t[10]+ +(t[11]||0)),"-"===t[9]&&(u=-u)),l=new Date(Date.UTC(r,n,i,o,a,s,c)),u&&l.setTime(l.getTime()-u),l}function xb(e){return e.toISOString()}mu(mb,"resolveYamlTimestamp"),mu(yb,"constructYamlTimestamp"),mu(xb,"representYamlTimestamp");var bb=new Rx("tag:yaml.org,2002:timestamp",{kind:"scalar",resolve:mb,construct:yb,instanceOf:Date,represent:xb});function vb(e){return"<<"===e||null===e}mu(vb,"resolveYamlMerge");var Cb=new Rx("tag:yaml.org,2002:merge",{kind:"scalar",resolve:vb}),wb="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=\n\r";function kb(e){if(null===e)return!1;var t,r,n=0,i=e.length,o=wb;for(r=0;r<i;r++)if(!((t=o.indexOf(e.charAt(r)))>64)){if(t<0)return!1;n+=6}return n%8==0}function Sb(e){var t,r,n=e.replace(/[\r\n=]/g,""),i=n.length,o=wb,a=0,s=[];for(t=0;t<i;t++)t%4==0&&t&&(s.push(a>>16&255),s.push(a>>8&255),s.push(255&a)),a=a<<6|o.indexOf(n.charAt(t));return 0===(r=i%4*6)?(s.push(a>>16&255),s.push(a>>8&255),s.push(255&a)):18===r?(s.push(a>>10&255),s.push(a>>2&255)):12===r&&s.push(a>>4&255),new Uint8Array(s)}function _b(e){var t,r,n="",i=0,o=e.length,a=wb;for(t=0;t<o;t++)t%3==0&&t&&(n+=a[i>>18&63],n+=a[i>>12&63],n+=a[i>>6&63],n+=a[63&i]),i=(i<<8)+e[t];return 0===(r=o%3)?(n+=a[i>>18&63],n+=a[i>>12&63],n+=a[i>>6&63],n+=a[63&i]):2===r?(n+=a[i>>10&63],n+=a[i>>4&63],n+=a[i<<2&63],n+=a[64]):1===r&&(n+=a[i>>2&63],n+=a[i<<4&63],n+=a[64],n+=a[64]),n}function Tb(e){return"[object Uint8Array]"===Object.prototype.toString.call(e)}mu(kb,"resolveYamlBinary"),mu(Sb,"constructYamlBinary"),mu(_b,"representYamlBinary"),mu(Tb,"isBinary");var Ab=new Rx("tag:yaml.org,2002:binary",{kind:"scalar",resolve:kb,construct:Sb,predicate:Tb,represent:_b}),Pb=Object.prototype.hasOwnProperty,Eb=Object.prototype.toString;function Mb(e){if(null===e)return!0;var t,r,n,i,o,a=[],s=e;for(t=0,r=s.length;t<r;t+=1){if(n=s[t],o=!1,"[object Object]"!==Eb.call(n))return!1;for(i in n)if(Pb.call(n,i)){if(o)return!1;o=!0}if(!o)return!1;if(-1!==a.indexOf(i))return!1;a.push(i)}return!0}function Ib(e){return null!==e?e:[]}mu(Mb,"resolveYamlOmap"),mu(Ib,"constructYamlOmap");var Bb=new Rx("tag:yaml.org,2002:omap",{kind:"sequence",resolve:Mb,construct:Ib}),Lb=Object.prototype.toString;function jb(e){if(null===e)return!0;var t,r,n,i,o,a=e;for(o=new Array(a.length),t=0,r=a.length;t<r;t+=1){if(n=a[t],"[object Object]"!==Lb.call(n))return!1;if(1!==(i=Object.keys(n)).length)return!1;o[t]=[i[0],n[i[0]]]}return!0}function Nb(e){if(null===e)return[];var t,r,n,i,o,a=e;for(o=new Array(a.length),t=0,r=a.length;t<r;t+=1)n=a[t],i=Object.keys(n),o[t]=[i[0],n[i[0]]];return o}mu(jb,"resolveYamlPairs"),mu(Nb,"constructYamlPairs");var Db=new Rx("tag:yaml.org,2002:pairs",{kind:"sequence",resolve:jb,construct:Nb}),Ob=Object.prototype.hasOwnProperty;function Fb(e){if(null===e)return!0;var t,r=e;for(t in r)if(Ob.call(r,t)&&null!==r[t])return!1;return!0}function Rb(e){return null!==e?e:{}}mu(Fb,"resolveYamlSet"),mu(Rb,"constructYamlSet");var $b=new Rx("tag:yaml.org,2002:set",{kind:"mapping",resolve:Fb,construct:Rb}),zb=pb.extend({implicit:[bb,Cb],explicit:[Ab,Bb,Db,$b]}),Vb=Object.prototype.hasOwnProperty,Wb=/[\x00-\x08\x0B\x0C\x0E-\x1F\x7F-\x84\x86-\x9F\uFFFE\uFFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF]/,Hb=/[\x85\u2028\u2029]/,qb=/[,\[\]\{\}]/,Ub=/^(?:!|!!|![a-z\-]+!)$/i,Gb=/^(?:!|[^,\[\]\{\}])(?:%[0-9a-f]{2}|[0-9a-z\-#;\/\?:@&=\+\$,_\.!~\*'\(\)\[\]])*$/i;function Xb(e){return Object.prototype.toString.call(e)}function Jb(e){return 10===e||13===e}function Yb(e){return 9===e||32===e}function Zb(e){return 9===e||32===e||10===e||13===e}function Kb(e){return 44===e||91===e||93===e||123===e||125===e}function Qb(e){var t;return 48<=e&&e<=57?e-48:97<=(t=32|e)&&t<=102?t-97+10:-1}function ev(e){return 120===e?2:117===e?4:85===e?8:0}function tv(e){return 48<=e&&e<=57?e-48:-1}function rv(e){return 48===e?"\0":97===e?"":98===e?"\b":116===e||9===e?"\t":110===e?"\n":118===e?"\v":102===e?"\f":114===e?"\r":101===e?"":32===e?" ":34===e?'"':47===e?"/":92===e?"\\":78===e?"
":95===e?" ":76===e?"\u2028":80===e?"\u2029":""}function nv(e){return e<=65535?String.fromCharCode(e):String.fromCharCode(55296+(e-65536>>10),56320+(e-65536&1023))}mu(Xb,"_class"),mu(Jb,"is_EOL"),mu(Yb,"is_WHITE_SPACE"),mu(Zb,"is_WS_OR_EOL"),mu(Kb,"is_FLOW_INDICATOR"),mu(Qb,"fromHexCode"),mu(ev,"escapedHexLen"),mu(tv,"fromDecimalCode"),mu(rv,"simpleEscapeSequence"),mu(nv,"charFromCodepoint");var iv,ov=new Array(256),av=new Array(256);for(iv=0;iv<256;iv++)ov[iv]=rv(iv)?1:0,av[iv]=rv(iv);function sv(e,t){this.input=e,this.filename=t.filename||null,this.schema=t.schema||zb,this.onWarning=t.onWarning||null,this.legacy=t.legacy||!1,this.json=t.json||!1,this.listener=t.listener||null,this.implicitTypes=this.schema.compiledImplicit,this.typeMap=this.schema.compiledTypeMap,this.length=e.length,this.position=0,this.line=0,this.lineStart=0,this.lineIndent=0,this.firstTabInLine=-1,this.documents=[]}function lv(e,t){var r={name:e.filename,buffer:e.input.slice(0,-1),position:e.position,line:e.line,column:e.position-e.lineStart};return r.snippet=jx(r),new Mx(t,r)}function cv(e,t){throw lv(e,t)}function uv(e,t){e.onWarning&&e.onWarning.call(null,lv(e,t))}mu(sv,"State$1"),mu(lv,"generateError"),mu(cv,"throwError"),mu(uv,"throwWarning");var hv={YAML:mu(function(e,t,r){var n,i,o;null!==e.version&&cv(e,"duplication of %YAML directive"),1!==r.length&&cv(e,"YAML directive accepts exactly one argument"),null===(n=/^([0-9]+)\.([0-9]+)$/.exec(r[0]))&&cv(e,"ill-formed argument of the YAML directive"),i=parseInt(n[1],10),o=parseInt(n[2],10),1!==i&&cv(e,"unacceptable YAML version of the document"),e.version=r[0],e.checkLineBreaks=o<2,1!==o&&2!==o&&uv(e,"unsupported YAML version of the document")},"handleYamlDirective"),TAG:mu(function(e,t,r){var n,i;2!==r.length&&cv(e,"TAG directive accepts exactly two arguments"),n=r[0],i=r[1],Ub.test(n)||cv(e,"ill-formed tag handle (first argument) of the TAG directive"),Vb.call(e.tagMap,n)&&cv(e,'there is a previously declared suffix for "'+n+'" tag handle'),Gb.test(i)||cv(e,"ill-formed tag prefix (second argument) of the TAG directive");try{i=decodeURIComponent(i)}catch(o){cv(e,"tag prefix is malformed: "+i)}e.tagMap[n]=i},"handleTagDirective")};function dv(e,t,r,n){var i,o,a,s;if(t<r){if(s=e.input.slice(t,r),n)for(i=0,o=s.length;i<o;i+=1)9===(a=s.charCodeAt(i))||32<=a&&a<=1114111||cv(e,"expected valid JSON character");else Wb.test(s)&&cv(e,"the stream contains non-printable characters");e.result+=s}}function pv(e,t,r,n){var i,o,a,s;for(Ax.isObject(r)||cv(e,"cannot merge mappings; the provided source object is unacceptable"),a=0,s=(i=Object.keys(r)).length;a<s;a+=1)o=i[a],Vb.call(t,o)||(t[o]=r[o],n[o]=!0)}function fv(e,t,r,n,i,o,a,s,l){var c,u;if(Array.isArray(i))for(c=0,u=(i=Array.prototype.slice.call(i)).length;c<u;c+=1)Array.isArray(i[c])&&cv(e,"nested arrays are not supported inside keys"),"object"==typeof i&&"[object Object]"===Xb(i[c])&&(i[c]="[object Object]");if("object"==typeof i&&"[object Object]"===Xb(i)&&(i="[object Object]"),i=String(i),null===t&&(t={}),"tag:yaml.org,2002:merge"===n)if(Array.isArray(o))for(c=0,u=o.length;c<u;c+=1)pv(e,t,o[c],r);else pv(e,t,o,r);else e.json||Vb.call(r,i)||!Vb.call(t,i)||(e.line=a||e.line,e.lineStart=s||e.lineStart,e.position=l||e.position,cv(e,"duplicated mapping key")),"__proto__"===i?Object.defineProperty(t,i,{configurable:!0,enumerable:!0,writable:!0,value:o}):t[i]=o,delete r[i];return t}function gv(e){var t;10===(t=e.input.charCodeAt(e.position))?e.position++:13===t?(e.position++,10===e.input.charCodeAt(e.position)&&e.position++):cv(e,"a line break is expected"),e.line+=1,e.lineStart=e.position,e.firstTabInLine=-1}function mv(e,t,r){for(var n=0,i=e.input.charCodeAt(e.position);0!==i;){for(;Yb(i);)9===i&&-1===e.firstTabInLine&&(e.firstTabInLine=e.position),i=e.input.charCodeAt(++e.position);if(t&&35===i)do{i=e.input.charCodeAt(++e.position)}while(10!==i&&13!==i&&0!==i);if(!Jb(i))break;for(gv(e),i=e.input.charCodeAt(e.position),n++,e.lineIndent=0;32===i;)e.lineIndent++,i=e.input.charCodeAt(++e.position)}return-1!==r&&0!==n&&e.lineIndent<r&&uv(e,"deficient indentation"),n}function yv(e){var t,r=e.position;return!(45!==(t=e.input.charCodeAt(r))&&46!==t||t!==e.input.charCodeAt(r+1)||t!==e.input.charCodeAt(r+2)||(r+=3,0!==(t=e.input.charCodeAt(r))&&!Zb(t)))}function xv(e,t){1===t?e.result+=" ":t>1&&(e.result+=Ax.repeat("\n",t-1))}function bv(e,t,r){var n,i,o,a,s,l,c,u,h=e.kind,d=e.result;if(Zb(u=e.input.charCodeAt(e.position))||Kb(u)||35===u||38===u||42===u||33===u||124===u||62===u||39===u||34===u||37===u||64===u||96===u)return!1;if((63===u||45===u)&&(Zb(n=e.input.charCodeAt(e.position+1))||r&&Kb(n)))return!1;for(e.kind="scalar",e.result="",i=o=e.position,a=!1;0!==u;){if(58===u){if(Zb(n=e.input.charCodeAt(e.position+1))||r&&Kb(n))break}else if(35===u){if(Zb(e.input.charCodeAt(e.position-1)))break}else{if(e.position===e.lineStart&&yv(e)||r&&Kb(u))break;if(Jb(u)){if(s=e.line,l=e.lineStart,c=e.lineIndent,mv(e,!1,-1),e.lineIndent>=t){a=!0,u=e.input.charCodeAt(e.position);continue}e.position=o,e.line=s,e.lineStart=l,e.lineIndent=c;break}}a&&(dv(e,i,o,!1),xv(e,e.line-s),i=o=e.position,a=!1),Yb(u)||(o=e.position+1),u=e.input.charCodeAt(++e.position)}return dv(e,i,o,!1),!!e.result||(e.kind=h,e.result=d,!1)}function vv(e,t){var r,n,i;if(39!==(r=e.input.charCodeAt(e.position)))return!1;for(e.kind="scalar",e.result="",e.position++,n=i=e.position;0!==(r=e.input.charCodeAt(e.position));)if(39===r){if(dv(e,n,e.position,!0),39!==(r=e.input.charCodeAt(++e.position)))return!0;n=e.position,e.position++,i=e.position}else Jb(r)?(dv(e,n,i,!0),xv(e,mv(e,!1,t)),n=i=e.position):e.position===e.lineStart&&yv(e)?cv(e,"unexpected end of the document within a single quoted scalar"):(e.position++,i=e.position);cv(e,"unexpected end of the stream within a single quoted scalar")}function Cv(e,t){var r,n,i,o,a,s;if(34!==(s=e.input.charCodeAt(e.position)))return!1;for(e.kind="scalar",e.result="",e.position++,r=n=e.position;0!==(s=e.input.charCodeAt(e.position));){if(34===s)return dv(e,r,e.position,!0),e.position++,!0;if(92===s){if(dv(e,r,e.position,!0),Jb(s=e.input.charCodeAt(++e.position)))mv(e,!1,t);else if(s<256&&ov[s])e.result+=av[s],e.position++;else if((a=ev(s))>0){for(i=a,o=0;i>0;i--)(a=Qb(s=e.input.charCodeAt(++e.position)))>=0?o=(o<<4)+a:cv(e,"expected hexadecimal character");e.result+=nv(o),e.position++}else cv(e,"unknown escape sequence");r=n=e.position}else Jb(s)?(dv(e,r,n,!0),xv(e,mv(e,!1,t)),r=n=e.position):e.position===e.lineStart&&yv(e)?cv(e,"unexpected end of the document within a double quoted scalar"):(e.position++,n=e.position)}cv(e,"unexpected end of the stream within a double quoted scalar")}function wv(e,t){var r,n,i,o,a,s,l,c,u,h,d,p,f=!0,g=e.tag,m=e.anchor,y=Object.create(null);if(91===(p=e.input.charCodeAt(e.position)))a=93,c=!1,o=[];else{if(123!==p)return!1;a=125,c=!0,o={}}for(null!==e.anchor&&(e.anchorMap[e.anchor]=o),p=e.input.charCodeAt(++e.position);0!==p;){if(mv(e,!0,t),(p=e.input.charCodeAt(e.position))===a)return e.position++,e.tag=g,e.anchor=m,e.kind=c?"mapping":"sequence",e.result=o,!0;f?44===p&&cv(e,"expected the node content, but found ','"):cv(e,"missed comma between flow collection entries"),d=null,s=l=!1,63===p&&Zb(e.input.charCodeAt(e.position+1))&&(s=l=!0,e.position++,mv(e,!0,t)),r=e.line,n=e.lineStart,i=e.position,Ev(e,t,1,!1,!0),h=e.tag,u=e.result,mv(e,!0,t),p=e.input.charCodeAt(e.position),!l&&e.line!==r||58!==p||(s=!0,p=e.input.charCodeAt(++e.position),mv(e,!0,t),Ev(e,t,1,!1,!0),d=e.result),c?fv(e,o,y,h,u,d,r,n,i):s?o.push(fv(e,null,y,h,u,d,r,n,i)):o.push(u),mv(e,!0,t),44===(p=e.input.charCodeAt(e.position))?(f=!0,p=e.input.charCodeAt(++e.position)):f=!1}cv(e,"unexpected end of the stream within a flow collection")}function kv(e,t){var r,n,i,o,a=1,s=!1,l=!1,c=t,u=0,h=!1;if(124===(o=e.input.charCodeAt(e.position)))n=!1;else{if(62!==o)return!1;n=!0}for(e.kind="scalar",e.result="";0!==o;)if(43===(o=e.input.charCodeAt(++e.position))||45===o)1===a?a=43===o?3:2:cv(e,"repeat of a chomping mode identifier");else{if(!((i=tv(o))>=0))break;0===i?cv(e,"bad explicit indentation width of a block scalar; it cannot be less than one"):l?cv(e,"repeat of an indentation width identifier"):(c=t+i-1,l=!0)}if(Yb(o)){do{o=e.input.charCodeAt(++e.position)}while(Yb(o));if(35===o)do{o=e.input.charCodeAt(++e.position)}while(!Jb(o)&&0!==o)}for(;0!==o;){for(gv(e),e.lineIndent=0,o=e.input.charCodeAt(e.position);(!l||e.lineIndent<c)&&32===o;)e.lineIndent++,o=e.input.charCodeAt(++e.position);if(!l&&e.lineIndent>c&&(c=e.lineIndent),Jb(o))u++;else{if(e.lineIndent<c){3===a?e.result+=Ax.repeat("\n",s?1+u:u):1===a&&s&&(e.result+="\n");break}for(n?Yb(o)?(h=!0,e.result+=Ax.repeat("\n",s?1+u:u)):h?(h=!1,e.result+=Ax.repeat("\n",u+1)):0===u?s&&(e.result+=" "):e.result+=Ax.repeat("\n",u):e.result+=Ax.repeat("\n",s?1+u:u),s=!0,l=!0,u=0,r=e.position;!Jb(o)&&0!==o;)o=e.input.charCodeAt(++e.position);dv(e,r,e.position,!1)}}return!0}function Sv(e,t){var r,n,i=e.tag,o=e.anchor,a=[],s=!1;if(-1!==e.firstTabInLine)return!1;for(null!==e.anchor&&(e.anchorMap[e.anchor]=a),n=e.input.charCodeAt(e.position);0!==n&&(-1!==e.firstTabInLine&&(e.position=e.firstTabInLine,cv(e,"tab characters must not be used in indentation")),45===n)&&Zb(e.input.charCodeAt(e.position+1));)if(s=!0,e.position++,mv(e,!0,-1)&&e.lineIndent<=t)a.push(null),n=e.input.charCodeAt(e.position);else if(r=e.line,Ev(e,t,3,!1,!0),a.push(e.result),mv(e,!0,-1),n=e.input.charCodeAt(e.position),(e.line===r||e.lineIndent>t)&&0!==n)cv(e,"bad indentation of a sequence entry");else if(e.lineIndent<t)break;return!!s&&(e.tag=i,e.anchor=o,e.kind="sequence",e.result=a,!0)}function _v(e,t,r){var n,i,o,a,s,l,c,u=e.tag,h=e.anchor,d={},p=Object.create(null),f=null,g=null,m=null,y=!1,x=!1;if(-1!==e.firstTabInLine)return!1;for(null!==e.anchor&&(e.anchorMap[e.anchor]=d),c=e.input.charCodeAt(e.position);0!==c;){if(y||-1===e.firstTabInLine||(e.position=e.firstTabInLine,cv(e,"tab characters must not be used in indentation")),n=e.input.charCodeAt(e.position+1),o=e.line,63!==c&&58!==c||!Zb(n)){if(a=e.line,s=e.lineStart,l=e.position,!Ev(e,r,2,!1,!0))break;if(e.line===o){for(c=e.input.charCodeAt(e.position);Yb(c);)c=e.input.charCodeAt(++e.position);if(58===c)Zb(c=e.input.charCodeAt(++e.position))||cv(e,"a whitespace character is expected after the key-value separator within a block mapping"),y&&(fv(e,d,p,f,g,null,a,s,l),f=g=m=null),x=!0,y=!1,i=!1,f=e.tag,g=e.result;else{if(!x)return e.tag=u,e.anchor=h,!0;cv(e,"can not read an implicit mapping pair; a colon is missed")}}else{if(!x)return e.tag=u,e.anchor=h,!0;cv(e,"can not read a block mapping entry; a multiline key may not be an implicit key")}}else 63===c?(y&&(fv(e,d,p,f,g,null,a,s,l),f=g=m=null),x=!0,y=!0,i=!0):y?(y=!1,i=!0):cv(e,"incomplete explicit mapping pair; a key node is missed; or followed by a non-tabulated empty line"),e.position+=1,c=n;if((e.line===o||e.lineIndent>t)&&(y&&(a=e.line,s=e.lineStart,l=e.position),Ev(e,t,4,!0,i)&&(y?g=e.result:m=e.result),y||(fv(e,d,p,f,g,m,a,s,l),f=g=m=null),mv(e,!0,-1),c=e.input.charCodeAt(e.position)),(e.line===o||e.lineIndent>t)&&0!==c)cv(e,"bad indentation of a mapping entry");else if(e.lineIndent<t)break}return y&&fv(e,d,p,f,g,null,a,s,l),x&&(e.tag=u,e.anchor=h,e.kind="mapping",e.result=d),x}function Tv(e){var t,r,n,i,o=!1,a=!1;if(33!==(i=e.input.charCodeAt(e.position)))return!1;if(null!==e.tag&&cv(e,"duplication of a tag property"),60===(i=e.input.charCodeAt(++e.position))?(o=!0,i=e.input.charCodeAt(++e.position)):33===i?(a=!0,r="!!",i=e.input.charCodeAt(++e.position)):r="!",t=e.position,o){do{i=e.input.charCodeAt(++e.position)}while(0!==i&&62!==i);e.position<e.length?(n=e.input.slice(t,e.position),i=e.input.charCodeAt(++e.position)):cv(e,"unexpected end of the stream within a verbatim tag")}else{for(;0!==i&&!Zb(i);)33===i&&(a?cv(e,"tag suffix cannot contain exclamation marks"):(r=e.input.slice(t-1,e.position+1),Ub.test(r)||cv(e,"named tag handle cannot contain such characters"),a=!0,t=e.position+1)),i=e.input.charCodeAt(++e.position);n=e.input.slice(t,e.position),qb.test(n)&&cv(e,"tag suffix cannot contain flow indicator characters")}n&&!Gb.test(n)&&cv(e,"tag name cannot contain such characters: "+n);try{n=decodeURIComponent(n)}catch(s){cv(e,"tag name is malformed: "+n)}return o?e.tag=n:Vb.call(e.tagMap,r)?e.tag=e.tagMap[r]+n:"!"===r?e.tag="!"+n:"!!"===r?e.tag="tag:yaml.org,2002:"+n:cv(e,'undeclared tag handle "'+r+'"'),!0}function Av(e){var t,r;if(38!==(r=e.input.charCodeAt(e.position)))return!1;for(null!==e.anchor&&cv(e,"duplication of an anchor property"),r=e.input.charCodeAt(++e.position),t=e.position;0!==r&&!Zb(r)&&!Kb(r);)r=e.input.charCodeAt(++e.position);return e.position===t&&cv(e,"name of an anchor node must contain at least one character"),e.anchor=e.input.slice(t,e.position),!0}function Pv(e){var t,r,n;if(42!==(n=e.input.charCodeAt(e.position)))return!1;for(n=e.input.charCodeAt(++e.position),t=e.position;0!==n&&!Zb(n)&&!Kb(n);)n=e.input.charCodeAt(++e.position);return e.position===t&&cv(e,"name of an alias node must contain at least one character"),r=e.input.slice(t,e.position),Vb.call(e.anchorMap,r)||cv(e,'unidentified alias "'+r+'"'),e.result=e.anchorMap[r],mv(e,!0,-1),!0}function Ev(e,t,r,n,i){var o,a,s,l,c,u,h,d,p,f=1,g=!1,m=!1;if(null!==e.listener&&e.listener("open",e),e.tag=null,e.anchor=null,e.kind=null,e.result=null,o=a=s=4===r||3===r,n&&mv(e,!0,-1)&&(g=!0,e.lineIndent>t?f=1:e.lineIndent===t?f=0:e.lineIndent<t&&(f=-1)),1===f)for(;Tv(e)||Av(e);)mv(e,!0,-1)?(g=!0,s=o,e.lineIndent>t?f=1:e.lineIndent===t?f=0:e.lineIndent<t&&(f=-1)):s=!1;if(s&&(s=g||i),1!==f&&4!==r||(d=1===r||2===r?t:t+1,p=e.position-e.lineStart,1===f?s&&(Sv(e,p)||_v(e,p,d))||wv(e,d)?m=!0:(a&&kv(e,d)||vv(e,d)||Cv(e,d)?m=!0:Pv(e)?(m=!0,null===e.tag&&null===e.anchor||cv(e,"alias node should not have any properties")):bv(e,d,1===r)&&(m=!0,null===e.tag&&(e.tag="?")),null!==e.anchor&&(e.anchorMap[e.anchor]=e.result)):0===f&&(m=s&&Sv(e,p))),null===e.tag)null!==e.anchor&&(e.anchorMap[e.anchor]=e.result);else if("?"===e.tag){for(null!==e.result&&"scalar"!==e.kind&&cv(e,'unacceptable node kind for !<?> tag; it should be "scalar", not "'+e.kind+'"'),l=0,c=e.implicitTypes.length;l<c;l+=1)if((h=e.implicitTypes[l]).resolve(e.result)){e.result=h.construct(e.result),e.tag=h.tag,null!==e.anchor&&(e.anchorMap[e.anchor]=e.result);break}}else if("!"!==e.tag){if(Vb.call(e.typeMap[e.kind||"fallback"],e.tag))h=e.typeMap[e.kind||"fallback"][e.tag];else for(h=null,l=0,c=(u=e.typeMap.multi[e.kind||"fallback"]).length;l<c;l+=1)if(e.tag.slice(0,u[l].tag.length)===u[l].tag){h=u[l];break}h||cv(e,"unknown tag !<"+e.tag+">"),null!==e.result&&h.kind!==e.kind&&cv(e,"unacceptable node kind for !<"+e.tag+'> tag; it should be "'+h.kind+'", not "'+e.kind+'"'),h.resolve(e.result,e.tag)?(e.result=h.construct(e.result,e.tag),null!==e.anchor&&(e.anchorMap[e.anchor]=e.result)):cv(e,"cannot resolve a node with !<"+e.tag+"> explicit tag")}return null!==e.listener&&e.listener("close",e),null!==e.tag||null!==e.anchor||m}function Mv(e){var t,r,n,i,o=e.position,a=!1;for(e.version=null,e.checkLineBreaks=e.legacy,e.tagMap=Object.create(null),e.anchorMap=Object.create(null);0!==(i=e.input.charCodeAt(e.position))&&(mv(e,!0,-1),i=e.input.charCodeAt(e.position),!(e.lineIndent>0||37!==i));){for(a=!0,i=e.input.charCodeAt(++e.position),t=e.position;0!==i&&!Zb(i);)i=e.input.charCodeAt(++e.position);for(n=[],(r=e.input.slice(t,e.position)).length<1&&cv(e,"directive name must not be less than one character in length");0!==i;){for(;Yb(i);)i=e.input.charCodeAt(++e.position);if(35===i){do{i=e.input.charCodeAt(++e.position)}while(0!==i&&!Jb(i));break}if(Jb(i))break;for(t=e.position;0!==i&&!Zb(i);)i=e.input.charCodeAt(++e.position);n.push(e.input.slice(t,e.position))}0!==i&&gv(e),Vb.call(hv,r)?hv[r](e,r,n):uv(e,'unknown document directive "'+r+'"')}mv(e,!0,-1),0===e.lineIndent&&45===e.input.charCodeAt(e.position)&&45===e.input.charCodeAt(e.position+1)&&45===e.input.charCodeAt(e.position+2)?(e.position+=3,mv(e,!0,-1)):a&&cv(e,"directives end mark is expected"),Ev(e,e.lineIndent-1,4,!1,!0),mv(e,!0,-1),e.checkLineBreaks&&Hb.test(e.input.slice(o,e.position))&&uv(e,"non-ASCII line breaks are interpreted as content"),e.documents.push(e.result),e.position===e.lineStart&&yv(e)?46===e.input.charCodeAt(e.position)&&(e.position+=3,mv(e,!0,-1)):e.position<e.length-1&&cv(e,"end of the stream or a document separator is expected")}function Iv(e,t){t=t||{},0!==(e=String(e)).length&&(10!==e.charCodeAt(e.length-1)&&13!==e.charCodeAt(e.length-1)&&(e+="\n"),65279===e.charCodeAt(0)&&(e=e.slice(1)));var r=new sv(e,t),n=e.indexOf("\0");for(-1!==n&&(r.position=n,cv(r,"null byte is not allowed in input")),r.input+="\0";32===r.input.charCodeAt(r.position);)r.lineIndent+=1,r.position+=1;for(;r.position<r.length-1;)Mv(r);return r.documents}function Bv(e,t){var r=Iv(e,t);if(0!==r.length){if(1===r.length)return r[0];throw new Mx("expected a single document in the stream, but found more")}}mu(dv,"captureSegment"),mu(pv,"mergeMappings"),mu(fv,"storeMappingPair"),mu(gv,"readLineBreak"),mu(mv,"skipSeparationSpace"),mu(yv,"testDocumentSeparator"),mu(xv,"writeFoldedLines"),mu(bv,"readPlainScalar"),mu(vv,"readSingleQuotedScalar"),mu(Cv,"readDoubleQuotedScalar"),mu(wv,"readFlowCollection"),mu(kv,"readBlockScalar"),mu(Sv,"readBlockSequence"),mu(_v,"readBlockMapping"),mu(Tv,"readTagProperty"),mu(Av,"readAnchorProperty"),mu(Pv,"readAlias"),mu(Ev,"composeNode"),mu(Mv,"readDocument"),mu(Iv,"loadDocuments"),mu(function(e,t,r){null!==t&&"object"==typeof t&&void 0===r&&(r=t,t=null);var n=Iv(e,r);if("function"!=typeof t)return n;for(var i=0,o=n.length;i<o;i+=1)t(n[i])},"loadAll$1"),mu(Bv,"load$1");var Lv={load:Bv},jv=Object.prototype.toString,Nv=Object.prototype.hasOwnProperty,Dv=65279,Ov={0:"\\0",7:"\\a",8:"\\b",9:"\\t",10:"\\n",11:"\\v",12:"\\f",13:"\\r",27:"\\e",34:'\\"',92:"\\\\",133:"\\N",160:"\\_",8232:"\\L",8233:"\\P"},Fv=["y","Y","yes","Yes","YES","on","On","ON","n","N","no","No","NO","off","Off","OFF"],Rv=/^[-+]?[0-9_]+(?::[0-9_]+)+(?:\.[0-9_]*)?$/;function $v(e,t){var r,n,i,o,a,s,l;if(null===t)return{};for(r={},i=0,o=(n=Object.keys(t)).length;i<o;i+=1)a=n[i],s=String(t[a]),"!!"===a.slice(0,2)&&(a="tag:yaml.org,2002:"+a.slice(2)),(l=e.compiledTypeMap.fallback[a])&&Nv.call(l.styleAliases,s)&&(s=l.styleAliases[s]),r[a]=s;return r}function zv(e){var t,r,n;if(t=e.toString(16).toUpperCase(),e<=255)r="x",n=2;else if(e<=65535)r="u",n=4;else{if(!(e<=4294967295))throw new Mx("code point within a string may not be greater than 0xFFFFFFFF");r="U",n=8}return"\\"+r+Ax.repeat("0",n-t.length)+t}mu($v,"compileStyleMap"),mu(zv,"encodeHex");function Vv(e){this.schema=e.schema||zb,this.indent=Math.max(1,e.indent||2),this.noArrayIndent=e.noArrayIndent||!1,this.skipInvalid=e.skipInvalid||!1,this.flowLevel=Ax.isNothing(e.flowLevel)?-1:e.flowLevel,this.styleMap=$v(this.schema,e.styles||null),this.sortKeys=e.sortKeys||!1,this.lineWidth=e.lineWidth||80,this.noRefs=e.noRefs||!1,this.noCompatMode=e.noCompatMode||!1,this.condenseFlow=e.condenseFlow||!1,this.quotingType='"'===e.quotingType?2:1,this.forceQuotes=e.forceQuotes||!1,this.replacer="function"==typeof e.replacer?e.replacer:null,this.implicitTypes=this.schema.compiledImplicit,this.explicitTypes=this.schema.compiledExplicit,this.tag=null,this.result="",this.duplicates=[],this.usedDuplicates=null}function Wv(e,t){for(var r,n=Ax.repeat(" ",t),i=0,o=-1,a="",s=e.length;i<s;)-1===(o=e.indexOf("\n",i))?(r=e.slice(i),i=s):(r=e.slice(i,o+1),i=o+1),r.length&&"\n"!==r&&(a+=n),a+=r;return a}function Hv(e,t){return"\n"+Ax.repeat(" ",e.indent*t)}function qv(e,t){var r,n;for(r=0,n=e.implicitTypes.length;r<n;r+=1)if(e.implicitTypes[r].resolve(t))return!0;return!1}function Uv(e){return 32===e||9===e}function Gv(e){return 32<=e&&e<=126||161<=e&&e<=55295&&8232!==e&&8233!==e||57344<=e&&e<=65533&&e!==Dv||65536<=e&&e<=1114111}function Xv(e){return Gv(e)&&e!==Dv&&13!==e&&10!==e}function Jv(e,t,r){var n=Xv(e),i=n&&!Uv(e);return(r?n:n&&44!==e&&91!==e&&93!==e&&123!==e&&125!==e)&&35!==e&&!(58===t&&!i)||Xv(t)&&!Uv(t)&&35===e||58===t&&i}function Yv(e){return Gv(e)&&e!==Dv&&!Uv(e)&&45!==e&&63!==e&&58!==e&&44!==e&&91!==e&&93!==e&&123!==e&&125!==e&&35!==e&&38!==e&&42!==e&&33!==e&&124!==e&&61!==e&&62!==e&&39!==e&&34!==e&&37!==e&&64!==e&&96!==e}function Zv(e){return!Uv(e)&&58!==e}function Kv(e,t){var r,n=e.charCodeAt(t);return n>=55296&&n<=56319&&t+1<e.length&&(r=e.charCodeAt(t+1))>=56320&&r<=57343?1024*(n-55296)+r-56320+65536:n}function Qv(e){return/^\n* /.test(e)}mu(Vv,"State"),mu(Wv,"indentString"),mu(Hv,"generateNextLine"),mu(qv,"testImplicitResolving"),mu(Uv,"isWhitespace"),mu(Gv,"isPrintable"),mu(Xv,"isNsCharOrWhitespace"),mu(Jv,"isPlainSafe"),mu(Yv,"isPlainSafeFirst"),mu(Zv,"isPlainSafeLast"),mu(Kv,"codePointAt"),mu(Qv,"needIndentIndicator");function eC(e,t,r,n,i,o,a,s){var l,c=0,u=null,h=!1,d=!1,p=-1!==n,f=-1,g=Yv(Kv(e,0))&&Zv(Kv(e,e.length-1));if(t||a)for(l=0;l<e.length;c>=65536?l+=2:l++){if(!Gv(c=Kv(e,l)))return 5;g=g&&Jv(c,u,s),u=c}else{for(l=0;l<e.length;c>=65536?l+=2:l++){if(10===(c=Kv(e,l)))h=!0,p&&(d=d||l-f-1>n&&" "!==e[f+1],f=l);else if(!Gv(c))return 5;g=g&&Jv(c,u,s),u=c}d=d||p&&l-f-1>n&&" "!==e[f+1]}return h||d?r>9&&Qv(e)?5:a?2===o?5:2:d?4:3:!g||a||i(e)?2===o?5:2:1}function tC(e,t,r,n,i){e.dump=function(){if(0===t.length)return 2===e.quotingType?'""':"''";if(!e.noCompatMode&&(-1!==Fv.indexOf(t)||Rv.test(t)))return 2===e.quotingType?'"'+t+'"':"'"+t+"'";var o=e.indent*Math.max(1,r),a=-1===e.lineWidth?-1:Math.max(Math.min(e.lineWidth,40),e.lineWidth-o),s=n||e.flowLevel>-1&&r>=e.flowLevel;function l(t){return qv(e,t)}switch(mu(l,"testAmbiguity"),eC(t,s,e.indent,a,l,e.quotingType,e.forceQuotes&&!n,i)){case 1:return t;case 2:return"'"+t.replace(/'/g,"''")+"'";case 3:return"|"+rC(t,e.indent)+nC(Wv(t,o));case 4:return">"+rC(t,e.indent)+nC(Wv(iC(t,a),o));case 5:return'"'+aC(t)+'"';default:throw new Mx("impossible error: invalid scalar style")}}()}function rC(e,t){var r=Qv(e)?String(t):"",n="\n"===e[e.length-1];return r+(n&&("\n"===e[e.length-2]||"\n"===e)?"+":n?"":"-")+"\n"}function nC(e){return"\n"===e[e.length-1]?e.slice(0,-1):e}function iC(e,t){for(var r,n,i,o=/(\n+)([^\n]*)/g,a=(r=-1!==(r=e.indexOf("\n"))?r:e.length,o.lastIndex=r,oC(e.slice(0,r),t)),s="\n"===e[0]||" "===e[0];i=o.exec(e);){var l=i[1],c=i[2];n=" "===c[0],a+=l+(s||n||""===c?"":"\n")+oC(c,t),s=n}return a}function oC(e,t){if(""===e||" "===e[0])return e;for(var r,n,i=/ [^ ]/g,o=0,a=0,s=0,l="";r=i.exec(e);)(s=r.index)-o>t&&(n=a>o?a:s,l+="\n"+e.slice(o,n),o=n+1),a=s;return l+="\n",e.length-o>t&&a>o?l+=e.slice(o,a)+"\n"+e.slice(a+1):l+=e.slice(o),l.slice(1)}function aC(e){for(var t,r="",n=0,i=0;i<e.length;n>=65536?i+=2:i++)n=Kv(e,i),!(t=Ov[n])&&Gv(n)?(r+=e[i],n>=65536&&(r+=e[i+1])):r+=t||zv(n);return r}function sC(e,t,r){var n,i,o,a="",s=e.tag;for(n=0,i=r.length;n<i;n+=1)o=r[n],e.replacer&&(o=e.replacer.call(r,String(n),o)),(dC(e,t,o,!1,!1)||void 0===o&&dC(e,t,null,!1,!1))&&(""!==a&&(a+=","+(e.condenseFlow?"":" ")),a+=e.dump);e.tag=s,e.dump="["+a+"]"}function lC(e,t,r,n){var i,o,a,s="",l=e.tag;for(i=0,o=r.length;i<o;i+=1)a=r[i],e.replacer&&(a=e.replacer.call(r,String(i),a)),(dC(e,t+1,a,!0,!0,!1,!0)||void 0===a&&dC(e,t+1,null,!0,!0,!1,!0))&&(n&&""===s||(s+=Hv(e,t)),e.dump&&10===e.dump.charCodeAt(0)?s+="-":s+="- ",s+=e.dump);e.tag=l,e.dump=s||"[]"}function cC(e,t,r){var n,i,o,a,s,l="",c=e.tag,u=Object.keys(r);for(n=0,i=u.length;n<i;n+=1)s="",""!==l&&(s+=", "),e.condenseFlow&&(s+='"'),a=r[o=u[n]],e.replacer&&(a=e.replacer.call(r,o,a)),dC(e,t,o,!1,!1)&&(e.dump.length>1024&&(s+="? "),s+=e.dump+(e.condenseFlow?'"':"")+":"+(e.condenseFlow?"":" "),dC(e,t,a,!1,!1)&&(l+=s+=e.dump));e.tag=c,e.dump="{"+l+"}"}function uC(e,t,r,n){var i,o,a,s,l,c,u="",h=e.tag,d=Object.keys(r);if(!0===e.sortKeys)d.sort();else if("function"==typeof e.sortKeys)d.sort(e.sortKeys);else if(e.sortKeys)throw new Mx("sortKeys must be a boolean or a function");for(i=0,o=d.length;i<o;i+=1)c="",n&&""===u||(c+=Hv(e,t)),s=r[a=d[i]],e.replacer&&(s=e.replacer.call(r,a,s)),dC(e,t+1,a,!0,!0,!0)&&((l=null!==e.tag&&"?"!==e.tag||e.dump&&e.dump.length>1024)&&(e.dump&&10===e.dump.charCodeAt(0)?c+="?":c+="? "),c+=e.dump,l&&(c+=Hv(e,t)),dC(e,t+1,s,!0,l)&&(e.dump&&10===e.dump.charCodeAt(0)?c+=":":c+=": ",u+=c+=e.dump));e.tag=h,e.dump=u||"{}"}function hC(e,t,r){var n,i,o,a,s,l;for(o=0,a=(i=r?e.explicitTypes:e.implicitTypes).length;o<a;o+=1)if(((s=i[o]).instanceOf||s.predicate)&&(!s.instanceOf||"object"==typeof t&&t instanceof s.instanceOf)&&(!s.predicate||s.predicate(t))){if(r?s.multi&&s.representName?e.tag=s.representName(t):e.tag=s.tag:e.tag="?",s.represent){if(l=e.styleMap[s.tag]||s.defaultStyle,"[object Function]"===jv.call(s.represent))n=s.represent(t,l);else{if(!Nv.call(s.represent,l))throw new Mx("!<"+s.tag+'> tag resolver accepts not "'+l+'" style');n=s.represent[l](t,l)}e.dump=n}return!0}return!1}function dC(e,t,r,n,i,o,a){e.tag=null,e.dump=r,hC(e,r,!1)||hC(e,r,!0);var s,l=jv.call(e.dump),c=n;n&&(n=e.flowLevel<0||e.flowLevel>t);var u,h,d="[object Object]"===l||"[object Array]"===l;if(d&&(h=-1!==(u=e.duplicates.indexOf(r))),(null!==e.tag&&"?"!==e.tag||h||2!==e.indent&&t>0)&&(i=!1),h&&e.usedDuplicates[u])e.dump="*ref_"+u;else{if(d&&h&&!e.usedDuplicates[u]&&(e.usedDuplicates[u]=!0),"[object Object]"===l)n&&0!==Object.keys(e.dump).length?(uC(e,t,e.dump,i),h&&(e.dump="&ref_"+u+e.dump)):(cC(e,t,e.dump),h&&(e.dump="&ref_"+u+" "+e.dump));else if("[object Array]"===l)n&&0!==e.dump.length?(e.noArrayIndent&&!a&&t>0?lC(e,t-1,e.dump,i):lC(e,t,e.dump,i),h&&(e.dump="&ref_"+u+e.dump)):(sC(e,t,e.dump),h&&(e.dump="&ref_"+u+" "+e.dump));else{if("[object String]"!==l){if("[object Undefined]"===l)return!1;if(e.skipInvalid)return!1;throw new Mx("unacceptable kind of an object to dump "+l)}"?"!==e.tag&&tC(e,e.dump,t,o,c)}null!==e.tag&&"?"!==e.tag&&(s=encodeURI("!"===e.tag[0]?e.tag.slice(1):e.tag).replace(/!/g,"%21"),s="!"===e.tag[0]?"!"+s:"tag:yaml.org,2002:"===s.slice(0,18)?"!!"+s.slice(18):"!<"+s+">",e.dump=s+" "+e.dump)}return!0}function pC(e,t){var r,n,i=[],o=[];for(fC(e,i,o),r=0,n=o.length;r<n;r+=1)t.duplicates.push(i[o[r]]);t.usedDuplicates=new Array(n)}function fC(e,t,r){var n,i,o;if(null!==e&&"object"==typeof e)if(-1!==(i=t.indexOf(e)))-1===r.indexOf(i)&&r.push(i);else if(t.push(e),Array.isArray(e))for(i=0,o=e.length;i<o;i+=1)fC(e[i],t,r);else for(i=0,o=(n=Object.keys(e)).length;i<o;i+=1)fC(e[n[i]],t,r)}mu(eC,"chooseScalarStyle"),mu(tC,"writeScalar"),mu(rC,"blockHeader"),mu(nC,"dropEndingNewline"),mu(iC,"foldString"),mu(oC,"foldLine"),mu(aC,"escapeString"),mu(sC,"writeFlowSequence"),mu(lC,"writeBlockSequence"),mu(cC,"writeFlowMapping"),mu(uC,"writeBlockMapping"),mu(hC,"detectType"),mu(dC,"writeNode"),mu(pC,"getDuplicateReferences"),mu(fC,"inspectNode"),mu(function(e,t){var r=new Vv(t=t||{});r.noRefs||pC(e,r);var n=e;return r.replacer&&(n=r.replacer.call({"":n},"",n)),dC(r,0,n,!0,!0)?r.dump+"\n":""},"dump$1"),mu(function(e,t){return function(){throw new Error("Function yaml."+e+" is removed in js-yaml 4. Use yaml."+t+" instead, which is now safe by default.")}},"renamed");var gC=db,mC=Lv.load,yC={aggregation:17.25,extension:17.25,composition:17.25,dependency:6,lollipop:13.5,arrow_point:4},xC={arrow_point:9,arrow_cross:12.5,arrow_circle:12.5};function bC(e,t){if(void 0===e||void 0===t)return{angle:0,deltaX:0,deltaY:0};e=vC(e),t=vC(t);const[r,n]=[e.x,e.y],[i,o]=[t.x,t.y],a=i-r,s=o-n;return{angle:Math.atan(s/a),deltaX:a,deltaY:s}}mu(bC,"calculateDeltaAndAngle");var vC=mu(e=>Array.isArray(e)?{x:e[0],y:e[1]}:e,"pointTransformer"),CC=mu(e=>({x:mu(function(t,r,n){let i=0;const o=vC(n[0]).x<vC(n[n.length-1]).x?"left":"right";if(0===r&&Object.hasOwn(yC,e.arrowTypeStart)){const{angle:t,deltaX:r}=bC(n[0],n[1]);i=yC[e.arrowTypeStart]*Math.cos(t)*(r>=0?1:-1)}else if(r===n.length-1&&Object.hasOwn(yC,e.arrowTypeEnd)){const{angle:t,deltaX:r}=bC(n[n.length-1],n[n.length-2]);i=yC[e.arrowTypeEnd]*Math.cos(t)*(r>=0?1:-1)}const a=Math.abs(vC(t).x-vC(n[n.length-1]).x),s=Math.abs(vC(t).y-vC(n[n.length-1]).y),l=Math.abs(vC(t).x-vC(n[0]).x),c=Math.abs(vC(t).y-vC(n[0]).y),u=yC[e.arrowTypeStart],h=yC[e.arrowTypeEnd];if(a<h&&a>0&&s<h){let e=h+1-a;e*="right"===o?-1:1,i-=e}if(l<u&&l>0&&c<u){let e=u+1-l;e*="right"===o?-1:1,i+=e}return vC(t).x+i},"x"),y:mu(function(t,r,n){let i=0;const o=vC(n[0]).y<vC(n[n.length-1]).y?"down":"up";if(0===r&&Object.hasOwn(yC,e.arrowTypeStart)){const{angle:t,deltaY:r}=bC(n[0],n[1]);i=yC[e.arrowTypeStart]*Math.abs(Math.sin(t))*(r>=0?1:-1)}else if(r===n.length-1&&Object.hasOwn(yC,e.arrowTypeEnd)){const{angle:t,deltaY:r}=bC(n[n.length-1],n[n.length-2]);i=yC[e.arrowTypeEnd]*Math.abs(Math.sin(t))*(r>=0?1:-1)}const a=Math.abs(vC(t).y-vC(n[n.length-1]).y),s=Math.abs(vC(t).x-vC(n[n.length-1]).x),l=Math.abs(vC(t).y-vC(n[0]).y),c=Math.abs(vC(t).x-vC(n[0]).x),u=yC[e.arrowTypeStart],h=yC[e.arrowTypeEnd];if(a<h&&a>0&&s<h){let e=h+1-a;e*="up"===o?-1:1,i-=e}if(l<u&&l>0&&c<u){let e=u+1-l;e*="up"===o?-1:1,i+=e}return vC(t).y+i},"y")}),"getLineFunctionsWithOffset"),wC=mu(({flowchart:e})=>{var t,r;const n=(null==(t=null==e?void 0:e.subGraphTitleMargin)?void 0:t.top)??0,i=(null==(r=null==e?void 0:e.subGraphTitleMargin)?void 0:r.bottom)??0;return{subGraphTitleTopMargin:n,subGraphTitleBottomMargin:i,subGraphTitleTotalMargin:n+i}},"getSubGraphTitleMargins"),kC=mu(e=>{const{handDrawnSeed:t}=$p();return{fill:e,hachureAngle:120,hachureGap:4,fillWeight:2,roughness:.7,stroke:e,seed:t}},"solidStateFill"),SC=mu(e=>{const t=_C([...e.cssCompiledStyles||[],...e.cssStyles||[],...e.labelStyle||[]]);return{stylesMap:t,stylesArray:[...t]}},"compileStyles"),_C=mu(e=>{const t=new Map;return e.forEach(e=>{const[r,n]=e.split(":");t.set(r.trim(),null==n?void 0:n.trim())}),t},"styles2Map"),TC=mu(e=>"color"===e||"font-size"===e||"font-family"===e||"font-weight"===e||"font-style"===e||"text-decoration"===e||"text-align"===e||"text-transform"===e||"line-height"===e||"letter-spacing"===e||"word-spacing"===e||"text-shadow"===e||"text-overflow"===e||"white-space"===e||"word-wrap"===e||"word-break"===e||"overflow-wrap"===e||"hyphens"===e,"isLabelStyle"),AC=mu(e=>{const{stylesArray:t}=SC(e),r=[],n=[],i=[],o=[];return t.forEach(e=>{const t=e[0];TC(t)?r.push(e.join(":")+" !important"):(n.push(e.join(":")+" !important"),t.includes("stroke")&&i.push(e.join(":")+" !important"),"fill"===t&&o.push(e.join(":")+" !important"))}),{labelStyles:r.join(";"),nodeStyles:n.join(";"),stylesArray:t,borderStyles:i,backgroundStyles:o}},"styles2String"),PC=mu((e,t)=>{var r;const{themeVariables:n,handDrawnSeed:i}=$p(),{nodeBorder:o,mainBkg:a}=n,{stylesMap:s}=SC(e);return Object.assign({roughness:.7,fill:s.get("fill")||a,fillStyle:"hachure",fillWeight:4,hachureGap:5.2,stroke:s.get("stroke")||o,seed:i,strokeWidth:(null==(r=s.get("stroke-width"))?void 0:r.replace("px",""))||1.3,fillLineDash:[0,0],strokeLineDash:EC(s.get("stroke-dasharray"))},t)},"userNodeOverrides"),EC=mu(e=>{if(!e)return[0,0];const t=e.trim().split(/\s+/).map(Number);if(1===t.length){const e=isNaN(t[0])?0:t[0];return[e,e]}return[isNaN(t[0])?0:t[0],isNaN(t[1])?0:t[1]]},"getStrokeDashArray"),MC={},IC={};Object.defineProperty(IC,"__esModule",{value:!0}),IC.BLANK_URL=IC.relativeFirstCharacters=IC.whitespaceEscapeCharsRegex=IC.urlSchemeRegex=IC.ctrlCharactersRegex=IC.htmlCtrlEntityRegex=IC.htmlEntitiesRegex=IC.invalidProtocolRegex=void 0,IC.invalidProtocolRegex=/^([^\w]*)(javascript|data|vbscript)/im,IC.htmlEntitiesRegex=/&#(\w+)(^\w|;)?/g,IC.htmlCtrlEntityRegex=/&(newline|tab);/gi,IC.ctrlCharactersRegex=/[\u0000-\u001F\u007F-\u009F\u2000-\u200D\uFEFF]/gim,IC.urlSchemeRegex=/^.+(:|:)/gim,IC.whitespaceEscapeCharsRegex=/(\\|%5[cC])((%(6[eE]|72|74))|[nrt])/g,IC.relativeFirstCharacters=[".","/"],IC.BLANK_URL="about:blank",Object.defineProperty(MC,"__esModule",{value:!0});var BC=MC.sanitizeUrl=function(e){if(!e)return LC.BLANK_URL;var t,r=NC(e.trim());do{t=(r=NC(r=jC(r).replace(LC.htmlCtrlEntityRegex,"").replace(LC.ctrlCharactersRegex,"").replace(LC.whitespaceEscapeCharsRegex,"").trim())).match(LC.ctrlCharactersRegex)||r.match(LC.htmlEntitiesRegex)||r.match(LC.htmlCtrlEntityRegex)||r.match(LC.whitespaceEscapeCharsRegex)}while(t&&t.length>0);var n=r;if(!n)return LC.BLANK_URL;if(function(e){return LC.relativeFirstCharacters.indexOf(e[0])>-1}(n))return n;var i=n.trimStart(),o=i.match(LC.urlSchemeRegex);if(!o)return n;var a=o[0].toLowerCase().trim();if(LC.invalidProtocolRegex.test(a))return LC.BLANK_URL;var s=i.replace(/\\/g,"/");if("mailto:"===a||a.includes("://"))return s;if("http:"===a||"https:"===a){if(!function(e){return URL.canParse(e)}(s))return LC.BLANK_URL;var l=new URL(s);return l.protocol=l.protocol.toLowerCase(),l.hostname=l.hostname.toLowerCase(),l.toString()}return s},LC=IC;function jC(e){return e.replace(LC.ctrlCharactersRegex,"").replace(LC.htmlEntitiesRegex,function(e,t){return String.fromCharCode(t)})}function NC(e){try{return decodeURIComponent(e)}catch(t){return e}}var DC="object"==typeof global&&global&&global.Object===Object&&global,OC="object"==typeof self&&self&&self.Object===Object&&self,FC=DC||OC||Function("return this")(),RC=FC.Symbol,$C=Object.prototype,zC=$C.hasOwnProperty,VC=$C.toString,WC=RC?RC.toStringTag:void 0;var HC=Object.prototype.toString;var qC=RC?RC.toStringTag:void 0;function UC(e){return null==e?void 0===e?"[object Undefined]":"[object Null]":qC&&qC in Object(e)?function(e){var t=zC.call(e,WC),r=e[WC];try{e[WC]=void 0;var n=!0}catch(o){}var i=VC.call(e);return n&&(t?e[WC]=r:delete e[WC]),i}(e):function(e){return HC.call(e)}(e)}function GC(e){var t=typeof e;return null!=e&&("object"==t||"function"==t)}function XC(e){if(!GC(e))return!1;var t=UC(e);return"[object Function]"==t||"[object GeneratorFunction]"==t||"[object AsyncFunction]"==t||"[object Proxy]"==t}var JC,YC=FC["__core-js_shared__"],ZC=(JC=/[^.]+$/.exec(YC&&YC.keys&&YC.keys.IE_PROTO||""))?"Symbol(src)_1."+JC:"";var KC=Function.prototype.toString;function QC(e){if(null!=e){try{return KC.call(e)}catch(t){}try{return e+""}catch(t){}}return""}var ew=/^\[object .+?Constructor\]$/,tw=Function.prototype,rw=Object.prototype,nw=tw.toString,iw=rw.hasOwnProperty,ow=RegExp("^"+nw.call(iw).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function aw(e){return!(!GC(e)||(t=e,ZC&&ZC in t))&&(XC(e)?ow:ew).test(QC(e));var t}function sw(e,t){var r=function(e,t){return null==e?void 0:e[t]}(e,t);return aw(r)?r:void 0}var lw=sw(Object,"create");var cw=Object.prototype.hasOwnProperty;var uw=Object.prototype.hasOwnProperty;function hw(e){var t=-1,r=null==e?0:e.length;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}function dw(e,t){return e===t||e!=e&&t!=t}function pw(e,t){for(var r=e.length;r--;)if(dw(e[r][0],t))return r;return-1}hw.prototype.clear=function(){this.__data__=lw?lw(null):{},this.size=0},hw.prototype.delete=function(e){var t=this.has(e)&&delete this.__data__[e];return this.size-=t?1:0,t},hw.prototype.get=function(e){var t=this.__data__;if(lw){var r=t[e];return"__lodash_hash_undefined__"===r?void 0:r}return cw.call(t,e)?t[e]:void 0},hw.prototype.has=function(e){var t=this.__data__;return lw?void 0!==t[e]:uw.call(t,e)},hw.prototype.set=function(e,t){var r=this.__data__;return this.size+=this.has(e)?0:1,r[e]=lw&&void 0===t?"__lodash_hash_undefined__":t,this};var fw=Array.prototype.splice;function gw(e){var t=-1,r=null==e?0:e.length;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}gw.prototype.clear=function(){this.__data__=[],this.size=0},gw.prototype.delete=function(e){var t=this.__data__,r=pw(t,e);return!(r<0)&&(r==t.length-1?t.pop():fw.call(t,r,1),--this.size,!0)},gw.prototype.get=function(e){var t=this.__data__,r=pw(t,e);return r<0?void 0:t[r][1]},gw.prototype.has=function(e){return pw(this.__data__,e)>-1},gw.prototype.set=function(e,t){var r=this.__data__,n=pw(r,e);return n<0?(++this.size,r.push([e,t])):r[n][1]=t,this};var mw=sw(FC,"Map");function yw(e,t){var r,n,i=e.__data__;return("string"==(n=typeof(r=t))||"number"==n||"symbol"==n||"boolean"==n?"__proto__"!==r:null===r)?i["string"==typeof t?"string":"hash"]:i.map}function xw(e){var t=-1,r=null==e?0:e.length;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}xw.prototype.clear=function(){this.size=0,this.__data__={hash:new hw,map:new(mw||gw),string:new hw}},xw.prototype.delete=function(e){var t=yw(this,e).delete(e);return this.size-=t?1:0,t},xw.prototype.get=function(e){return yw(this,e).get(e)},xw.prototype.has=function(e){return yw(this,e).has(e)},xw.prototype.set=function(e,t){var r=yw(this,e),n=r.size;return r.set(e,t),this.size+=r.size==n?0:1,this};function bw(e,t){if("function"!=typeof e||null!=t&&"function"!=typeof t)throw new TypeError("Expected a function");var r=function(){var n=arguments,i=t?t.apply(this,n):n[0],o=r.cache;if(o.has(i))return o.get(i);var a=e.apply(this,n);return r.cache=o.set(i,a)||o,a};return r.cache=new(bw.Cache||xw),r}bw.Cache=xw;function vw(e){var t=this.__data__=new gw(e);this.size=t.size}vw.prototype.clear=function(){this.__data__=new gw,this.size=0},vw.prototype.delete=function(e){var t=this.__data__,r=t.delete(e);return this.size=t.size,r},vw.prototype.get=function(e){return this.__data__.get(e)},vw.prototype.has=function(e){return this.__data__.has(e)},vw.prototype.set=function(e,t){var r=this.__data__;if(r instanceof gw){var n=r.__data__;if(!mw||n.length<199)return n.push([e,t]),this.size=++r.size,this;r=this.__data__=new xw(n)}return r.set(e,t),this.size=r.size,this};var Cw=function(){try{var e=sw(Object,"defineProperty");return e({},"",{}),e}catch(t){}}();function ww(e,t,r){"__proto__"==t&&Cw?Cw(e,t,{configurable:!0,enumerable:!0,value:r,writable:!0}):e[t]=r}function kw(e,t,r){(void 0!==r&&!dw(e[t],r)||void 0===r&&!(t in e))&&ww(e,t,r)}var Sw=function(e,t,r){for(var n=-1,i=Object(e),o=r(e),a=o.length;a--;){var s=o[++n];if(!1===t(i[s],s,i))break}return e},_w="object"==typeof exports&&exports&&!exports.nodeType&&exports,Tw=_w&&"object"==typeof module&&module&&!module.nodeType&&module,Aw=Tw&&Tw.exports===_w?FC.Buffer:void 0,Pw=Aw?Aw.allocUnsafe:void 0;function Ew(e,t){if(t)return e.slice();var r=e.length,n=Pw?Pw(r):new e.constructor(r);return e.copy(n),n}var Mw=FC.Uint8Array;function Iw(e){var t=new e.constructor(e.byteLength);return new Mw(t).set(new Mw(e)),t}function Bw(e,t){var r=t?Iw(e.buffer):e.buffer;return new e.constructor(r,e.byteOffset,e.length)}function Lw(e,t){var r=-1,n=e.length;for(t||(t=Array(n));++r<n;)t[r]=e[r];return t}var jw=Object.create,Nw=function(){function e(){}return function(t){if(!GC(t))return{};if(jw)return jw(t);e.prototype=t;var r=new e;return e.prototype=void 0,r}}();function Dw(e,t){return function(r){return e(t(r))}}var Ow=Dw(Object.getPrototypeOf,Object),Fw=Object.prototype;function Rw(e){var t=e&&e.constructor;return e===("function"==typeof t&&t.prototype||Fw)}function $w(e){return"function"!=typeof e.constructor||Rw(e)?{}:Nw(Ow(e))}function zw(e){return null!=e&&"object"==typeof e}function Vw(e){return zw(e)&&"[object Arguments]"==UC(e)}var Ww=Object.prototype,Hw=Ww.hasOwnProperty,qw=Ww.propertyIsEnumerable,Uw=Vw(function(){return arguments}())?Vw:function(e){return zw(e)&&Hw.call(e,"callee")&&!qw.call(e,"callee")},Gw=Array.isArray;function Xw(e){return"number"==typeof e&&e>-1&&e%1==0&&e<=9007199254740991}function Jw(e){return null!=e&&Xw(e.length)&&!XC(e)}var Yw="object"==typeof exports&&exports&&!exports.nodeType&&exports,Zw=Yw&&"object"==typeof module&&module&&!module.nodeType&&module,Kw=Zw&&Zw.exports===Yw?FC.Buffer:void 0,Qw=(Kw?Kw.isBuffer:void 0)||function(){return!1},ek=Function.prototype,tk=Object.prototype,rk=ek.toString,nk=tk.hasOwnProperty,ik=rk.call(Object);var ok={};function ak(e){return function(t){return e(t)}}ok["[object Float32Array]"]=ok["[object Float64Array]"]=ok["[object Int8Array]"]=ok["[object Int16Array]"]=ok["[object Int32Array]"]=ok["[object Uint8Array]"]=ok["[object Uint8ClampedArray]"]=ok["[object Uint16Array]"]=ok["[object Uint32Array]"]=!0,ok["[object Arguments]"]=ok["[object Array]"]=ok["[object ArrayBuffer]"]=ok["[object Boolean]"]=ok["[object DataView]"]=ok["[object Date]"]=ok["[object Error]"]=ok["[object Function]"]=ok["[object Map]"]=ok["[object Number]"]=ok["[object Object]"]=ok["[object RegExp]"]=ok["[object Set]"]=ok["[object String]"]=ok["[object WeakMap]"]=!1;var sk="object"==typeof exports&&exports&&!exports.nodeType&&exports,lk=sk&&"object"==typeof module&&module&&!module.nodeType&&module,ck=lk&&lk.exports===sk&&DC.process,uk=function(){try{var e=lk&&lk.require&&lk.require("util").types;return e||ck&&ck.binding&&ck.binding("util")}catch(t){}}(),hk=uk&&uk.isTypedArray,dk=hk?ak(hk):function(e){return zw(e)&&Xw(e.length)&&!!ok[UC(e)]};function pk(e,t){if(("constructor"!==t||"function"!=typeof e[t])&&"__proto__"!=t)return e[t]}var fk=Object.prototype.hasOwnProperty;function gk(e,t,r){var n=e[t];fk.call(e,t)&&dw(n,r)&&(void 0!==r||t in e)||ww(e,t,r)}function mk(e,t,r,n){var i=!r;r||(r={});for(var o=-1,a=t.length;++o<a;){var s=t[o],l=void 0;void 0===l&&(l=e[s]),i?ww(r,s,l):gk(r,s,l)}return r}var yk=/^(?:0|[1-9]\d*)$/;function xk(e,t){var r=typeof e;return!!(t=null==t?9007199254740991:t)&&("number"==r||"symbol"!=r&&yk.test(e))&&e>-1&&e%1==0&&e<t}var bk=Object.prototype.hasOwnProperty;function vk(e,t){var r=Gw(e),n=!r&&Uw(e),i=!r&&!n&&Qw(e),o=!r&&!n&&!i&&dk(e),a=r||n||i||o,s=a?function(e,t){for(var r=-1,n=Array(e);++r<e;)n[r]=t(r);return n}(e.length,String):[],l=s.length;for(var c in e)!t&&!bk.call(e,c)||a&&("length"==c||i&&("offset"==c||"parent"==c)||o&&("buffer"==c||"byteLength"==c||"byteOffset"==c)||xk(c,l))||s.push(c);return s}var Ck=Object.prototype.hasOwnProperty;function wk(e){if(!GC(e))return function(e){var t=[];if(null!=e)for(var r in Object(e))t.push(r);return t}(e);var t=Rw(e),r=[];for(var n in e)("constructor"!=n||!t&&Ck.call(e,n))&&r.push(n);return r}function kk(e){return Jw(e)?vk(e,!0):wk(e)}function Sk(e,t,r,n,i,o,a){var s=pk(e,r),l=pk(t,r),c=a.get(l);if(c)kw(e,r,c);else{var u,h=o?o(s,l,r+"",e,t,a):void 0,d=void 0===h;if(d){var p=Gw(l),f=!p&&Qw(l),g=!p&&!f&&dk(l);h=l,p||f||g?Gw(s)?h=s:zw(u=s)&&Jw(u)?h=Lw(s):f?(d=!1,h=Ew(l,!0)):g?(d=!1,h=Bw(l,!0)):h=[]:function(e){if(!zw(e)||"[object Object]"!=UC(e))return!1;var t=Ow(e);if(null===t)return!0;var r=nk.call(t,"constructor")&&t.constructor;return"function"==typeof r&&r instanceof r&&rk.call(r)==ik}(l)||Uw(l)?(h=s,Uw(s)?h=function(e){return mk(e,kk(e))}(s):GC(s)&&!XC(s)||(h=$w(l))):d=!1}d&&(a.set(l,h),i(h,l,n,o,a),a.delete(l)),kw(e,r,h)}}function _k(e,t,r,n,i){e!==t&&Sw(t,function(o,a){if(i||(i=new vw),GC(o))Sk(e,t,a,r,_k,n,i);else{var s=n?n(pk(e,a),o,a+"",e,t,i):void 0;void 0===s&&(s=o),kw(e,a,s)}},kk)}function Tk(e){return e}var Ak=Math.max;var Pk=Cw?function(e,t){return Cw(e,"toString",{configurable:!0,enumerable:!1,value:(r=t,function(){return r}),writable:!0});var r}:Tk,Ek=Date.now;var Mk,Ik,Bk,Lk=(Mk=Pk,Ik=0,Bk=0,function(){var e=Ek(),t=16-(e-Bk);if(Bk=e,t>0){if(++Ik>=800)return arguments[0]}else Ik=0;return Mk.apply(void 0,arguments)});function jk(e,t){return Lk(function(e,t,r){return t=Ak(void 0===t?e.length-1:t,0),function(){for(var n=arguments,i=-1,o=Ak(n.length-t,0),a=Array(o);++i<o;)a[i]=n[t+i];i=-1;for(var s=Array(t+1);++i<t;)s[i]=n[i];return s[t]=r(a),function(e,t,r){switch(r.length){case 0:return e.call(t);case 1:return e.call(t,r[0]);case 2:return e.call(t,r[0],r[1]);case 3:return e.call(t,r[0],r[1],r[2])}return e.apply(t,r)}(e,this,s)}}(e,t,Tk),e+"")}var Nk,Dk=(Nk=function(e,t,r){_k(e,t,r)},jk(function(e,t){var r=-1,n=t.length,i=n>1?t[n-1]:void 0,o=n>2?t[2]:void 0;for(i=Nk.length>3&&"function"==typeof i?(n--,i):void 0,o&&function(e,t,r){if(!GC(r))return!1;var n=typeof t;return!!("number"==n?Jw(r)&&xk(t,r.length):"string"==n&&t in r)&&dw(r[t],e)}(t[0],t[1],o)&&(i=n<3?void 0:i,n=1),e=Object(e);++r<n;){var a=t[r];a&&Nk(e,a,r,i)}return e})),Ok={curveBasis:Oy,curveBasisClosed:function(e){return new Fy(e)},curveBasisOpen:function(e){return new Ry(e)},curveBumpX:By,curveBumpY:Ly,curveBundle:zy,curveCardinalClosed:Uy,curveCardinalOpen:Xy,curveCardinal:Hy,curveCatmullRomClosed:Qy,curveCatmullRomOpen:tx,curveCatmullRom:Zy,curveLinear:Ay,curveLinearClosed:function(e){return new rx(e)},curveMonotoneX:ux,curveMonotoneY:hx,curveNatural:fx,curveStep:mx,curveStepAfter:xx,curveStepBefore:yx},Fk=/\s*(?:(\w+)(?=:):|(\w+))\s*(?:(\w+)|((?:(?!}%{2}).|\r?\n)*))?\s*(?:}%{2})?/gi,Rk=mu(function(e,t){const r=$k(e,/(?:init\b)|(?:initialize\b)/);let n={};if(Array.isArray(r)){const e=r.map(e=>e.args);Sd(e),n=od(n,[...e])}else n=r.args;if(!n)return;let i=ed(e,t);const o="config";return void 0!==n[o]&&("flowchart-v2"===i&&(i="flowchart"),n[i]=n[o],delete n[o]),n},"detectInit"),$k=mu(function(e,t=null){var r,n;try{const i=new RegExp(`[%]{2}(?![{]${Fk.source})(?=[}][%]{2}).*\n`,"ig");let o;e=e.trim().replace(i,"").replace(/'/gm,'"'),bu.debug(`Detecting diagram directive${null!==t?" type:"+t:""} based on the text:${e}`);const a=[];for(;null!==(o=Yh.exec(e));)if(o.index===Yh.lastIndex&&Yh.lastIndex++,o&&!t||t&&(null==(r=o[1])?void 0:r.match(t))||t&&(null==(n=o[2])?void 0:n.match(t))){const e=o[1]?o[1]:o[2],t=o[3]?o[3].trim():o[4]?JSON.parse(o[4].trim()):null;a.push({type:e,args:t})}return 0===a.length?{type:e,args:null}:1===a.length?a[0]:a}catch(i){return bu.error(`ERROR: ${i.message} - Unable to parse directive type: '${t}' based on the text: '${e}'`),{type:void 0,args:null}}},"detectDirective"),zk=mu(function(e){return e.replace(Yh,"")},"removeDirectives"),Vk=mu(function(e,t){for(const[r,n]of t.entries())if(n.match(e))return r;return-1},"isSubstringInArray");function Wk(e,t){if(!e)return t;const r=`curve${e.charAt(0).toUpperCase()+e.slice(1)}`;return Ok[r]??t}function Hk(e,t){const r=e.trim();if(r)return"loose"!==t.securityLevel?BC(r):r}mu(Wk,"interpolateToCurve"),mu(Hk,"formatUrl");var qk=mu((e,...t)=>{const r=e.split("."),n=r.length-1,i=r[n];let o=window;for(let a=0;a<n;a++)if(o=o[r[a]],!o)return void bu.error(`Function name: ${e} not found in window`);o[i](...t)},"runFunc");function Uk(e,t){return e&&t?Math.sqrt(Math.pow(t.x-e.x,2)+Math.pow(t.y-e.y,2)):0}function Gk(e){let t,r=0;e.forEach(e=>{r+=Uk(e,t),t=e});return Yk(e,r/2)}function Xk(e){return 1===e.length?e[0]:Gk(e)}mu(Uk,"distance"),mu(Gk,"traverseEdge"),mu(Xk,"calcLabelPosition");var Jk=mu((e,t=2)=>{const r=Math.pow(10,t);return Math.round(e*r)/r},"roundNumber"),Yk=mu((e,t)=>{let r,n=t;for(const i of e){if(r){const e=Uk(i,r);if(0===e)return r;if(e<n)n-=e;else{const t=n/e;if(t<=0)return r;if(t>=1)return{x:i.x,y:i.y};if(t>0&&t<1)return{x:Jk((1-t)*r.x+t*i.x,5),y:Jk((1-t)*r.y+t*i.y,5)}}}r=i}throw new Error("Could not find a suitable point for the given distance")},"calculatePoint"),Zk=mu((e,t,r)=>{bu.info(`our points ${JSON.stringify(t)}`),t[0]!==r&&(t=t.reverse());const n=Yk(t,25),i=e?10:5,o=Math.atan2(t[0].y-n.y,t[0].x-n.x),a={x:0,y:0};return a.x=Math.sin(o)*i+(t[0].x+n.x)/2,a.y=-Math.cos(o)*i+(t[0].y+n.y)/2,a},"calcCardinalityPosition");function Kk(e,t,r){const n=structuredClone(r);bu.info("our points",n),"start_left"!==t&&"start_right"!==t&&n.reverse();const i=Yk(n,25+e),o=10+.5*e,a=Math.atan2(n[0].y-i.y,n[0].x-i.x),s={x:0,y:0};return"start_left"===t?(s.x=Math.sin(a+Math.PI)*o+(n[0].x+i.x)/2,s.y=-Math.cos(a+Math.PI)*o+(n[0].y+i.y)/2):"end_right"===t?(s.x=Math.sin(a-Math.PI)*o+(n[0].x+i.x)/2-5,s.y=-Math.cos(a-Math.PI)*o+(n[0].y+i.y)/2-5):"end_left"===t?(s.x=Math.sin(a)*o+(n[0].x+i.x)/2-5,s.y=-Math.cos(a)*o+(n[0].y+i.y)/2-5):(s.x=Math.sin(a)*o+(n[0].x+i.x)/2,s.y=-Math.cos(a)*o+(n[0].y+i.y)/2),s}function Qk(e){let t="",r="";for(const n of e)void 0!==n&&(n.startsWith("color:")||n.startsWith("text-align:")?r=r+n+";":t=t+n+";");return{style:t,labelStyle:r}}mu(Kk,"calcTerminalLabelPosition"),mu(Qk,"getStylesFromArray");var eS=0,tS=mu(()=>(eS++,"id-"+Math.random().toString(36).substr(2,12)+"-"+eS),"generateId");function rS(e){let t="";const r="0123456789abcdef";for(let n=0;n<e;n++)t+=r.charAt(Math.floor(16*Math.random()));return t}mu(rS,"makeRandomHex");var nS=mu(e=>rS(e.length),"random"),iS=mu(function(){return{x:0,y:0,fill:void 0,anchor:"start",style:"#666",width:100,height:100,textMargin:0,rx:0,ry:0,valign:void 0,text:""}},"getTextObj"),oS=mu(function(e,t){const r=t.text.replace(yp.lineBreakRegex," "),[,n]=mS(t.fontSize),i=e.append("text");i.attr("x",t.x),i.attr("y",t.y),i.style("text-anchor",t.anchor),i.style("font-family",t.fontFamily),i.style("font-size",n),i.style("font-weight",t.fontWeight),i.attr("fill",t.fill),void 0!==t.class&&i.attr("class",t.class);const o=i.append("tspan");return o.attr("x",t.x+2*t.textMargin),o.attr("fill",t.fill),o.text(r),i},"drawSimpleText"),aS=bw((e,t,r)=>{if(!e)return e;if(r=Object.assign({fontSize:12,fontWeight:400,fontFamily:"Arial",joinWith:"<br/>"},r),yp.lineBreakRegex.test(e))return e;const n=e.split(" ").filter(Boolean),i=[];let o="";return n.forEach((e,a)=>{const s=cS(`${e} `,r),l=cS(o,r);if(s>t){const{hyphenatedStrings:n,remainingWord:a}=sS(e,t,"-",r);i.push(o,...n),o=a}else l+s>=t?(i.push(o),o=e):o=[o,e].filter(Boolean).join(" ");a+1===n.length&&i.push(o)}),i.filter(e=>""!==e).join(r.joinWith)},(e,t,r)=>`${e}${t}${r.fontSize}${r.fontWeight}${r.fontFamily}${r.joinWith}`),sS=bw((e,t,r="-",n)=>{n=Object.assign({fontSize:12,fontWeight:400,fontFamily:"Arial",margin:0},n);const i=[...e],o=[];let a="";return i.forEach((e,s)=>{const l=`${a}${e}`;if(cS(l,n)>=t){const e=s+1,t=i.length===e,n=`${l}${r}`;o.push(t?l:n),a=""}else a=l}),{hyphenatedStrings:o,remainingWord:a}},(e,t,r="-",n)=>`${e}${t}${r}${n.fontSize}${n.fontWeight}${n.fontFamily}`);function lS(e,t){return hS(e,t).height}function cS(e,t){return hS(e,t).width}mu(lS,"calculateTextHeight"),mu(cS,"calculateTextWidth");var uS,hS=bw((e,t)=>{const{fontSize:r=12,fontFamily:n="Arial",fontWeight:i=400}=t;if(!e)return{width:0,height:0};const[,o]=mS(r),a=["sans-serif",n],s=e.split(yp.lineBreakRegex),l=[],c=fg("body");if(!c.remove)return{width:0,height:0,lineHeight:0};const u=c.append("svg");for(const h of a){let e=0;const t={width:0,height:0,lineHeight:0};for(const r of s){const n=iS();n.text=r||"";const a=oS(u,n).style("font-size",o).style("font-weight",i).style("font-family",h),s=(a._groups||a)[0][0].getBBox();if(0===s.width&&0===s.height)throw new Error("svg element not in render tree");t.width=Math.round(Math.max(t.width,s.width)),e=Math.round(s.height),t.height+=e,t.lineHeight=Math.round(Math.max(t.lineHeight,e))}l.push(t)}u.remove();return l[isNaN(l[1].height)||isNaN(l[1].width)||isNaN(l[1].lineHeight)||l[0].height>l[1].height&&l[0].width>l[1].width&&l[0].lineHeight>l[1].lineHeight?0:1]},(e,t)=>`${e}${t.fontSize}${t.fontWeight}${t.fontFamily}`),dS=(mu(p=class{constructor(e=!1,t){this.count=0,this.count=t?t.length:0,this.next=e?()=>this.count++:()=>Date.now()}},"InitIDGenerator"),p),pS=mu(function(e){return uS=uS||document.createElement("div"),e=escape(e).replace(/%26/g,"&").replace(/%23/g,"#").replace(/%3B/g,";"),uS.innerHTML=e,unescape(uS.textContent)},"entityDecode");function fS(e){return"str"in e}mu(fS,"isDetailedError");var gS=mu((e,t,r,n)=>{var i;if(!n)return;const o=null==(i=e.node())?void 0:i.getBBox();o&&e.append("text").text(n).attr("text-anchor","middle").attr("x",o.x+o.width/2).attr("y",-r).attr("class",t)},"insertTitle"),mS=mu(e=>{if("number"==typeof e)return[e,e+"px"];const t=parseInt(e??"",10);return Number.isNaN(t)?[void 0,void 0]:e===String(t)?[t,e+"px"]:[t,e]},"parseFontSize");function yS(e,t){return Dk({},e,t)}mu(yS,"cleanAndMerge");var xS={assignWithDepth:od,wrapLabel:aS,calculateTextHeight:lS,calculateTextWidth:cS,calculateTextDimensions:hS,cleanAndMerge:yS,detectInit:Rk,detectDirective:$k,isSubstringInArray:Vk,interpolateToCurve:Wk,calcLabelPosition:Xk,calcCardinalityPosition:Zk,calcTerminalLabelPosition:Kk,formatUrl:Hk,getStylesFromArray:Qk,generateId:tS,random:nS,runFunc:qk,entityDecode:pS,insertTitle:gS,isLabelCoordinateInPath:kS,parseFontSize:mS,InitIDGenerator:dS},bS=mu(function(e){let t=e;return t=t.replace(/style.*:\S*#.*;/g,function(e){return e.substring(0,e.length-1)}),t=t.replace(/classDef.*:\S*#.*;/g,function(e){return e.substring(0,e.length-1)}),t=t.replace(/#\w+;/g,function(e){const t=e.substring(1,e.length-1);return/^\+?\d+$/.test(t)?"fl°°"+t+"¶ß":"fl°"+t+"¶ß"}),t},"encodeEntities"),vS=mu(function(e){return e.replace(/fl°°/g,"&#").replace(/fl°/g,"&").replace(/¶ß/g,";")},"decodeEntities"),CS=mu((e,t,{counter:r=0,prefix:n,suffix:i},o)=>o||`${n?`${n}_`:""}${e}_${t}_${r}${i?`_${i}`:""}`,"getEdgeId");function wS(e){return e??null}function kS(e,t){const r=Math.round(e.x),n=Math.round(e.y),i=t.replace(/(\d+\.\d+)/g,e=>Math.round(parseFloat(e)).toString());return i.includes(r.toString())||i.includes(n.toString())}mu(wS,"handleUndefinedAttr"),mu(kS,"isLabelCoordinateInPath");const SS=Object.freeze({left:0,top:0,width:16,height:16}),_S=Object.freeze({rotate:0,vFlip:!1,hFlip:!1}),TS=Object.freeze({...SS,..._S}),AS=Object.freeze({...TS,body:"",hidden:!1}),PS=Object.freeze({width:null,height:null}),ES=Object.freeze({...PS,..._S}),MS=(e,t)=>!!e&&!(!(t&&""===e.prefix||e.prefix)||!e.name);function IS(e,t){const r=function(e,t){const r={};!e.hFlip!=!t.hFlip&&(r.hFlip=!0),!e.vFlip!=!t.vFlip&&(r.vFlip=!0);const n=((e.rotate||0)+(t.rotate||0))%4;return n&&(r.rotate=n),r}(e,t);for(const n in AS)n in _S?n in e&&!(n in r)&&(r[n]=_S[n]):n in t?r[n]=t[n]:n in e&&(r[n]=e[n]);return r}function BS(e,t,r){const n=e.icons,i=e.aliases||Object.create(null);let o={};function a(e){o=IS(n[e]||i[e],o)}return a(t),r.forEach(a),IS(e,o)}function LS(e,t){if(e.icons[t])return BS(e,t,[]);const r=function(e,t){const r=e.icons,n=e.aliases||Object.create(null),i=Object.create(null);return(t||Object.keys(r).concat(Object.keys(n))).forEach(function e(t){if(r[t])return i[t]=[];if(!(t in i)){i[t]=null;const r=n[t]&&n[t].parent,o=r&&e(r);o&&(i[t]=[r].concat(o))}return i[t]}),i}(e,[t])[t];return r?BS(e,t,r):null}const jS=/(-?[0-9.]*[0-9]+[0-9.]*)/g,NS=/^-?[0-9.]*[0-9]+[0-9.]*$/g;function DS(e,t,r){if(1===t)return e;if(r=r||100,"number"==typeof e)return Math.ceil(e*t*r)/r;if("string"!=typeof e)return e;const n=e.split(jS);if(null===n||!n.length)return e;const i=[];let o=n.shift(),a=NS.test(o);for(;;){if(a){const e=parseFloat(o);isNaN(e)?i.push(o):i.push(Math.ceil(e*t*r)/r)}else i.push(o);if(o=n.shift(),void 0===o)return i.join("");a=!a}}const OS=/\sid="(\S+)"/g,FS=new Map;function RS(e){const t=[];let r;for(;r=OS.exec(e);)t.push(r[1]);if(!t.length)return e;const n="suffix"+(16777216*Math.random()|Date.now()).toString(16);return t.forEach(t=>{const r=function(e){e=e.replace(/[0-9]+$/,"")||"a";const t=FS.get(e)||0;return FS.set(e,t+1),t?`${e}${t}`:e}(t),i=t.replace(/[.*+?^${}()|[\]\\]/g,"\\$&");e=e.replace(new RegExp('([#;"])('+i+')([")]|\\.[a-z])',"g"),"$1"+r+n+"$3")}),e=e.replace(new RegExp(n,"g"),"")}function $S(){return{async:!1,breaks:!1,extensions:null,gfm:!0,hooks:null,pedantic:!1,renderer:null,silent:!1,tokenizer:null,walkTokens:null}}var zS={async:!1,breaks:!1,extensions:null,gfm:!0,hooks:null,pedantic:!1,renderer:null,silent:!1,tokenizer:null,walkTokens:null};function VS(e){zS=e}var WS={exec:()=>null};function HS(e,t=""){let r="string"==typeof e?e:e.source,n={replace:(e,t)=>{let i="string"==typeof t?t:t.source;return i=i.replace(US.caret,"$1"),r=r.replace(e,i),n},getRegex:()=>new RegExp(r,t)};return n}var qS=(()=>{try{return!!new RegExp("(?<=1)(?<!1)")}catch{return!1}})(),US={codeRemoveIndent:/^(?: {1,4}| {0,3}\t)/gm,outputLinkReplace:/\\([\[\]])/g,indentCodeCompensation:/^(\s+)(?:```)/,beginningSpace:/^\s+/,endingHash:/#$/,startingSpaceChar:/^ /,endingSpaceChar:/ $/,nonSpaceChar:/[^ ]/,newLineCharGlobal:/\n/g,tabCharGlobal:/\t/g,multipleSpaceGlobal:/\s+/g,blankLine:/^[ \t]*$/,doubleBlankLine:/\n[ \t]*\n[ \t]*$/,blockquoteStart:/^ {0,3}>/,blockquoteSetextReplace:/\n {0,3}((?:=+|-+) *)(?=\n|$)/g,blockquoteSetextReplace2:/^ {0,3}>[ \t]?/gm,listReplaceTabs:/^\t+/,listReplaceNesting:/^ {1,4}(?=( {4})*[^ ])/g,listIsTask:/^\[[ xX]\] /,listReplaceTask:/^\[[ xX]\] +/,anyLine:/\n.*\n/,hrefBrackets:/^<(.*)>$/,tableDelimiter:/[:|]/,tableAlignChars:/^\||\| *$/g,tableRowBlankLine:/\n[ \t]*$/,tableAlignRight:/^ *-+: *$/,tableAlignCenter:/^ *:-+: *$/,tableAlignLeft:/^ *:-+ *$/,startATag:/^<a /i,endATag:/^<\/a>/i,startPreScriptTag:/^<(pre|code|kbd|script)(\s|>)/i,endPreScriptTag:/^<\/(pre|code|kbd|script)(\s|>)/i,startAngleBracket:/^</,endAngleBracket:/>$/,pedanticHrefTitle:/^([^'"]*[^\s])\s+(['"])(.*)\2/,unicodeAlphaNumeric:/[\p{L}\p{N}]/u,escapeTest:/[&<>"']/,escapeReplace:/[&<>"']/g,escapeTestNoEncode:/[<>"']|&(?!(#\d{1,7}|#[Xx][a-fA-F0-9]{1,6}|\w+);)/,escapeReplaceNoEncode:/[<>"']|&(?!(#\d{1,7}|#[Xx][a-fA-F0-9]{1,6}|\w+);)/g,unescapeTest:/&(#(?:\d+)|(?:#x[0-9A-Fa-f]+)|(?:\w+));?/gi,caret:/(^|[^\[])\^/g,percentDecode:/%25/g,findPipe:/\|/g,splitPipe:/ \|/,slashPipe:/\\\|/g,carriageReturn:/\r\n|\r/g,spaceLine:/^ +$/gm,notSpaceStart:/^\S*/,endingNewline:/\n$/,listItemRegex:e=>new RegExp(`^( {0,3}${e})((?:[\t ][^\\n]*)?(?:\\n|$))`),nextBulletRegex:e=>new RegExp(`^ {0,${Math.min(3,e-1)}}(?:[*+-]|\\d{1,9}[.)])((?:[ \t][^\\n]*)?(?:\\n|$))`),hrRegex:e=>new RegExp(`^ {0,${Math.min(3,e-1)}}((?:- *){3,}|(?:_ *){3,}|(?:\\* *){3,})(?:\\n+|$)`),fencesBeginRegex:e=>new RegExp(`^ {0,${Math.min(3,e-1)}}(?:\`\`\`|~~~)`),headingBeginRegex:e=>new RegExp(`^ {0,${Math.min(3,e-1)}}#`),htmlBeginRegex:e=>new RegExp(`^ {0,${Math.min(3,e-1)}}<(?:[a-z].*>|!--)`,"i")},GS=/^ {0,3}((?:-[\t ]*){3,}|(?:_[ \t]*){3,}|(?:\*[ \t]*){3,})(?:\n+|$)/,XS=/(?:[*+-]|\d{1,9}[.)])/,JS=/^(?!bull |blockCode|fences|blockquote|heading|html|table)((?:.|\n(?!\s*?\n|bull |blockCode|fences|blockquote|heading|html|table))+?)\n {0,3}(=+|-+) *(?:\n+|$)/,YS=HS(JS).replace(/bull/g,XS).replace(/blockCode/g,/(?: {4}| {0,3}\t)/).replace(/fences/g,/ {0,3}(?:`{3,}|~{3,})/).replace(/blockquote/g,/ {0,3}>/).replace(/heading/g,/ {0,3}#{1,6}/).replace(/html/g,/ {0,3}<[^\n>]+>\n/).replace(/\|table/g,"").getRegex(),ZS=HS(JS).replace(/bull/g,XS).replace(/blockCode/g,/(?: {4}| {0,3}\t)/).replace(/fences/g,/ {0,3}(?:`{3,}|~{3,})/).replace(/blockquote/g,/ {0,3}>/).replace(/heading/g,/ {0,3}#{1,6}/).replace(/html/g,/ {0,3}<[^\n>]+>\n/).replace(/table/g,/ {0,3}\|?(?:[:\- ]*\|)+[\:\- ]*\n/).getRegex(),KS=/^([^\n]+(?:\n(?!hr|heading|lheading|blockquote|fences|list|html|table| +\n)[^\n]+)*)/,QS=/(?!\s*\])(?:\\[\s\S]|[^\[\]\\])+/,e_=HS(/^ {0,3}\[(label)\]: *(?:\n[ \t]*)?([^<\s][^\s]*|<.*?>)(?:(?: +(?:\n[ \t]*)?| *\n[ \t]*)(title))? *(?:\n+|$)/).replace("label",QS).replace("title",/(?:"(?:\\"?|[^"\\])*"|'[^'\n]*(?:\n[^'\n]+)*\n?'|\([^()]*\))/).getRegex(),t_=HS(/^( {0,3}bull)([ \t][^\n]+?)?(?:\n|$)/).replace(/bull/g,XS).getRegex(),r_="address|article|aside|base|basefont|blockquote|body|caption|center|col|colgroup|dd|details|dialog|dir|div|dl|dt|fieldset|figcaption|figure|footer|form|frame|frameset|h[1-6]|head|header|hr|html|iframe|legend|li|link|main|menu|menuitem|meta|nav|noframes|ol|optgroup|option|p|param|search|section|summary|table|tbody|td|tfoot|th|thead|title|tr|track|ul",n_=/<!--(?:-?>|[\s\S]*?(?:-->|$))/,i_=HS("^ {0,3}(?:<(script|pre|style|textarea)[\\s>][\\s\\S]*?(?:</\\1>[^\\n]*\\n+|$)|comment[^\\n]*(\\n+|$)|<\\?[\\s\\S]*?(?:\\?>\\n*|$)|<![A-Z][\\s\\S]*?(?:>\\n*|$)|<!\\[CDATA\\[[\\s\\S]*?(?:\\]\\]>\\n*|$)|</?(tag)(?: +|\\n|/?>)[\\s\\S]*?(?:(?:\\n[ \t]*)+\\n|$)|<(?!script|pre|style|textarea)([a-z][\\w-]*)(?:attribute)*? */?>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n[ \t]*)+\\n|$)|</(?!script|pre|style|textarea)[a-z][\\w-]*\\s*>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n[ \t]*)+\\n|$))","i").replace("comment",n_).replace("tag",r_).replace("attribute",/ +[a-zA-Z:_][\w.:-]*(?: *= *"[^"\n]*"| *= *'[^'\n]*'| *= *[^\s"'=<>`]+)?/).getRegex(),o_=HS(KS).replace("hr",GS).replace("heading"," {0,3}#{1,6}(?:\\s|$)").replace("|lheading","").replace("|table","").replace("blockquote"," {0,3}>").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)]) ").replace("html","</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag",r_).getRegex(),a_={blockquote:HS(/^( {0,3}> ?(paragraph|[^\n]*)(?:\n|$))+/).replace("paragraph",o_).getRegex(),code:/^((?: {4}| {0,3}\t)[^\n]+(?:\n(?:[ \t]*(?:\n|$))*)?)+/,def:e_,fences:/^ {0,3}(`{3,}(?=[^`\n]*(?:\n|$))|~{3,})([^\n]*)(?:\n|$)(?:|([\s\S]*?)(?:\n|$))(?: {0,3}\1[~`]* *(?=\n|$)|$)/,heading:/^ {0,3}(#{1,6})(?=\s|$)(.*)(?:\n+|$)/,hr:GS,html:i_,lheading:YS,list:t_,newline:/^(?:[ \t]*(?:\n|$))+/,paragraph:o_,table:WS,text:/^[^\n]+/},s_=HS("^ *([^\\n ].*)\\n {0,3}((?:\\| *)?:?-+:? *(?:\\| *:?-+:? *)*(?:\\| *)?)(?:\\n((?:(?! *\\n|hr|heading|blockquote|code|fences|list|html).*(?:\\n|$))*)\\n*|$)").replace("hr",GS).replace("heading"," {0,3}#{1,6}(?:\\s|$)").replace("blockquote"," {0,3}>").replace("code","(?: {4}| {0,3}\t)[^\\n]").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)]) ").replace("html","</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag",r_).getRegex(),l_={...a_,lheading:ZS,table:s_,paragraph:HS(KS).replace("hr",GS).replace("heading"," {0,3}#{1,6}(?:\\s|$)").replace("|lheading","").replace("table",s_).replace("blockquote"," {0,3}>").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)]) ").replace("html","</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag",r_).getRegex()},c_={...a_,html:HS("^ *(?:comment *(?:\\n|\\s*$)|<(tag)[\\s\\S]+?</\\1> *(?:\\n{2,}|\\s*$)|<tag(?:\"[^\"]*\"|'[^']*'|\\s[^'\"/>\\s]*)*?/?> *(?:\\n{2,}|\\s*$))").replace("comment",n_).replace(/tag/g,"(?!(?:a|em|strong|small|s|cite|q|dfn|abbr|data|time|code|var|samp|kbd|sub|sup|i|b|u|mark|ruby|rt|rp|bdi|bdo|span|br|wbr|ins|del|img)\\b)\\w+(?!:|[^\\w\\s@]*@)\\b").getRegex(),def:/^ *\[([^\]]+)\]: *<?([^\s>]+)>?(?: +(["(][^\n]+[")]))? *(?:\n+|$)/,heading:/^(#{1,6})(.*)(?:\n+|$)/,fences:WS,lheading:/^(.+?)\n {0,3}(=+|-+) *(?:\n+|$)/,paragraph:HS(KS).replace("hr",GS).replace("heading"," *#{1,6} *[^\n]").replace("lheading",YS).replace("|table","").replace("blockquote"," {0,3}>").replace("|fences","").replace("|list","").replace("|html","").replace("|tag","").getRegex()},u_=/^( {2,}|\\)\n(?!\s*$)/,h_=/[\p{P}\p{S}]/u,d_=/[\s\p{P}\p{S}]/u,p_=/[^\s\p{P}\p{S}]/u,f_=HS(/^((?![*_])punctSpace)/,"u").replace(/punctSpace/g,d_).getRegex(),g_=/(?!~)[\p{P}\p{S}]/u,m_=HS(/link|precode-code|html/,"g").replace("link",/\[(?:[^\[\]`]|(?<a>`+)[^`]+\k<a>(?!`))*?\]\((?:\\[\s\S]|[^\\\(\)]|\((?:\\[\s\S]|[^\\\(\)])*\))*\)/).replace("precode-",qS?"(?<!`)()":"(^^|[^`])").replace("code",/(?<b>`+)[^`]+\k<b>(?!`)/).replace("html",/<(?! )[^<>]*?>/).getRegex(),y_=/^(?:\*+(?:((?!\*)punct)|[^\s*]))|^_+(?:((?!_)punct)|([^\s_]))/,x_=HS(y_,"u").replace(/punct/g,h_).getRegex(),b_=HS(y_,"u").replace(/punct/g,g_).getRegex(),v_="^[^_*]*?__[^_*]*?\\*[^_*]*?(?=__)|[^*]+(?=[^*])|(?!\\*)punct(\\*+)(?=[\\s]|$)|notPunctSpace(\\*+)(?!\\*)(?=punctSpace|$)|(?!\\*)punctSpace(\\*+)(?=notPunctSpace)|[\\s](\\*+)(?!\\*)(?=punct)|(?!\\*)punct(\\*+)(?!\\*)(?=punct)|notPunctSpace(\\*+)(?=notPunctSpace)",C_=HS(v_,"gu").replace(/notPunctSpace/g,p_).replace(/punctSpace/g,d_).replace(/punct/g,h_).getRegex(),w_=HS(v_,"gu").replace(/notPunctSpace/g,/(?:[^\s\p{P}\p{S}]|~)/u).replace(/punctSpace/g,/(?!~)[\s\p{P}\p{S}]/u).replace(/punct/g,g_).getRegex(),k_=HS("^[^_*]*?\\*\\*[^_*]*?_[^_*]*?(?=\\*\\*)|[^_]+(?=[^_])|(?!_)punct(_+)(?=[\\s]|$)|notPunctSpace(_+)(?!_)(?=punctSpace|$)|(?!_)punctSpace(_+)(?=notPunctSpace)|[\\s](_+)(?!_)(?=punct)|(?!_)punct(_+)(?!_)(?=punct)","gu").replace(/notPunctSpace/g,p_).replace(/punctSpace/g,d_).replace(/punct/g,h_).getRegex(),S_=HS(/\\(punct)/,"gu").replace(/punct/g,h_).getRegex(),__=HS(/^<(scheme:[^\s\x00-\x1f<>]*|email)>/).replace("scheme",/[a-zA-Z][a-zA-Z0-9+.-]{1,31}/).replace("email",/[a-zA-Z0-9.!#$%&'*+/=?^_`{|}~-]+(@)[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)+(?![-_])/).getRegex(),T_=HS(n_).replace("(?:--\x3e|$)","--\x3e").getRegex(),A_=HS("^comment|^</[a-zA-Z][\\w:-]*\\s*>|^<[a-zA-Z][\\w-]*(?:attribute)*?\\s*/?>|^<\\?[\\s\\S]*?\\?>|^<![a-zA-Z]+\\s[\\s\\S]*?>|^<!\\[CDATA\\[[\\s\\S]*?\\]\\]>").replace("comment",T_).replace("attribute",/\s+[a-zA-Z:_][\w.:-]*(?:\s*=\s*"[^"]*"|\s*=\s*'[^']*'|\s*=\s*[^\s"'=<>`]+)?/).getRegex(),P_=/(?:\[(?:\\[\s\S]|[^\[\]\\])*\]|\\[\s\S]|`+[^`]*?`+(?!`)|[^\[\]\\`])*?/,E_=HS(/^!?\[(label)\]\(\s*(href)(?:(?:[ \t]*(?:\n[ \t]*)?)(title))?\s*\)/).replace("label",P_).replace("href",/<(?:\\.|[^\n<>\\])+>|[^ \t\n\x00-\x1f]*/).replace("title",/"(?:\\"?|[^"\\])*"|'(?:\\'?|[^'\\])*'|\((?:\\\)?|[^)\\])*\)/).getRegex(),M_=HS(/^!?\[(label)\]\[(ref)\]/).replace("label",P_).replace("ref",QS).getRegex(),I_=HS(/^!?\[(ref)\](?:\[\])?/).replace("ref",QS).getRegex(),B_=/[hH][tT][tT][pP][sS]?|[fF][tT][pP]/,L_={_backpedal:WS,anyPunctuation:S_,autolink:__,blockSkip:m_,br:u_,code:/^(`+)([^`]|[^`][\s\S]*?[^`])\1(?!`)/,del:WS,emStrongLDelim:x_,emStrongRDelimAst:C_,emStrongRDelimUnd:k_,escape:/^\\([!"#$%&'()*+,\-./:;<=>?@\[\]\\^_`{|}~])/,link:E_,nolink:I_,punctuation:f_,reflink:M_,reflinkSearch:HS("reflink|nolink(?!\\()","g").replace("reflink",M_).replace("nolink",I_).getRegex(),tag:A_,text:/^(`+|[^`])(?:(?= {2,}\n)|[\s\S]*?(?:(?=[\\<!\[`*_]|\b_|$)|[^ ](?= {2,}\n)))/,url:WS},j_={...L_,link:HS(/^!?\[(label)\]\((.*?)\)/).replace("label",P_).getRegex(),reflink:HS(/^!?\[(label)\]\s*\[([^\]]*)\]/).replace("label",P_).getRegex()},N_={...L_,emStrongRDelimAst:w_,emStrongLDelim:b_,url:HS(/^((?:protocol):\/\/|www\.)(?:[a-zA-Z0-9\-]+\.?)+[^\s<]*|^email/).replace("protocol",B_).replace("email",/[A-Za-z0-9._+-]+(@)[a-zA-Z0-9-_]+(?:\.[a-zA-Z0-9-_]*[a-zA-Z0-9])+(?![-_])/).getRegex(),_backpedal:/(?:[^?!.,:;*_'"~()&]+|\([^)]*\)|&(?![a-zA-Z0-9]+;$)|[?!.,:;*_'"~)]+(?!$))+/,del:/^(~~?)(?=[^\s~])((?:\\[\s\S]|[^\\])*?(?:\\[\s\S]|[^\s~\\]))\1(?=[^~]|$)/,text:HS(/^([`~]+|[^`~])(?:(?= {2,}\n)|(?=[a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-]+@)|[\s\S]*?(?:(?=[\\<!\[`*~_]|\b_|protocol:\/\/|www\.|$)|[^ ](?= {2,}\n)|[^a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-](?=[a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-]+@)))/).replace("protocol",B_).getRegex()},D_={...N_,br:HS(u_).replace("{2,}","*").getRegex(),text:HS(N_.text).replace("\\b_","\\b_| {2,}\\n").replace(/\{2,\}/g,"*").getRegex()},O_={normal:a_,gfm:l_,pedantic:c_},F_={normal:L_,gfm:N_,breaks:D_,pedantic:j_},R_={"&":"&","<":"<",">":">",'"':""","'":"'"},$_=e=>R_[e];function z_(e,t){if(t){if(US.escapeTest.test(e))return e.replace(US.escapeReplace,$_)}else if(US.escapeTestNoEncode.test(e))return e.replace(US.escapeReplaceNoEncode,$_);return e}function V_(e){try{e=encodeURI(e).replace(US.percentDecode,"%")}catch{return null}return e}function W_(e,t){var r;let n=e.replace(US.findPipe,(e,t,r)=>{let n=!1,i=t;for(;--i>=0&&"\\"===r[i];)n=!n;return n?"|":" |"}).split(US.splitPipe),i=0;if(n[0].trim()||n.shift(),n.length>0&&!(null==(r=n.at(-1))?void 0:r.trim())&&n.pop(),t)if(n.length>t)n.splice(t);else for(;n.length<t;)n.push("");for(;i<n.length;i++)n[i]=n[i].trim().replace(US.slashPipe,"|");return n}function H_(e,t,r){let n=e.length;if(0===n)return"";let i=0;for(;i<n;){if(e.charAt(n-i-1)!==t)break;i++}return e.slice(0,n-i)}function q_(e,t,r,n,i){let o=t.href,a=t.title||null,s=e[1].replace(i.other.outputLinkReplace,"$1");n.state.inLink=!0;let l={type:"!"===e[0].charAt(0)?"image":"link",raw:r,href:o,title:a,text:s,tokens:n.inlineTokens(s)};return n.state.inLink=!1,l}var U_=class{constructor(e){y(this,"options"),y(this,"rules"),y(this,"lexer"),this.options=e||zS}space(e){let t=this.rules.block.newline.exec(e);if(t&&t[0].length>0)return{type:"space",raw:t[0]}}code(e){let t=this.rules.block.code.exec(e);if(t){let e=t[0].replace(this.rules.other.codeRemoveIndent,"");return{type:"code",raw:t[0],codeBlockStyle:"indented",text:this.options.pedantic?e:H_(e,"\n")}}}fences(e){let t=this.rules.block.fences.exec(e);if(t){let e=t[0],r=function(e,t,r){let n=e.match(r.other.indentCodeCompensation);if(null===n)return t;let i=n[1];return t.split("\n").map(e=>{let t=e.match(r.other.beginningSpace);if(null===t)return e;let[n]=t;return n.length>=i.length?e.slice(i.length):e}).join("\n")}(e,t[3]||"",this.rules);return{type:"code",raw:e,lang:t[2]?t[2].trim().replace(this.rules.inline.anyPunctuation,"$1"):t[2],text:r}}}heading(e){let t=this.rules.block.heading.exec(e);if(t){let e=t[2].trim();if(this.rules.other.endingHash.test(e)){let t=H_(e,"#");(this.options.pedantic||!t||this.rules.other.endingSpaceChar.test(t))&&(e=t.trim())}return{type:"heading",raw:t[0],depth:t[1].length,text:e,tokens:this.lexer.inline(e)}}}hr(e){let t=this.rules.block.hr.exec(e);if(t)return{type:"hr",raw:H_(t[0],"\n")}}blockquote(e){let t=this.rules.block.blockquote.exec(e);if(t){let e=H_(t[0],"\n").split("\n"),r="",n="",i=[];for(;e.length>0;){let t,o=!1,a=[];for(t=0;t<e.length;t++)if(this.rules.other.blockquoteStart.test(e[t]))a.push(e[t]),o=!0;else{if(o)break;a.push(e[t])}e=e.slice(t);let s=a.join("\n"),l=s.replace(this.rules.other.blockquoteSetextReplace,"\n $1").replace(this.rules.other.blockquoteSetextReplace2,"");r=r?`${r}\n${s}`:s,n=n?`${n}\n${l}`:l;let c=this.lexer.state.top;if(this.lexer.state.top=!0,this.lexer.blockTokens(l,i,!0),this.lexer.state.top=c,0===e.length)break;let u=i.at(-1);if("code"===(null==u?void 0:u.type))break;if("blockquote"===(null==u?void 0:u.type)){let t=u,o=t.raw+"\n"+e.join("\n"),a=this.blockquote(o);i[i.length-1]=a,r=r.substring(0,r.length-t.raw.length)+a.raw,n=n.substring(0,n.length-t.text.length)+a.text;break}if("list"===(null==u?void 0:u.type)){let t=u,o=t.raw+"\n"+e.join("\n"),a=this.list(o);i[i.length-1]=a,r=r.substring(0,r.length-u.raw.length)+a.raw,n=n.substring(0,n.length-t.raw.length)+a.raw,e=o.substring(i.at(-1).raw.length).split("\n");continue}}return{type:"blockquote",raw:r,tokens:i,text:n}}}list(e){let t=this.rules.block.list.exec(e);if(t){let r=t[1].trim(),n=r.length>1,i={type:"list",raw:"",ordered:n,start:n?+r.slice(0,-1):"",loose:!1,items:[]};r=n?`\\d{1,9}\\${r.slice(-1)}`:`\\${r}`,this.options.pedantic&&(r=n?r:"[*+-]");let o=this.rules.other.listItemRegex(r),a=!1;for(;e;){let r=!1,n="",s="";if(!(t=o.exec(e))||this.rules.block.hr.test(e))break;n=t[0],e=e.substring(n.length);let l=t[2].split("\n",1)[0].replace(this.rules.other.listReplaceTabs,e=>" ".repeat(3*e.length)),c=e.split("\n",1)[0],u=!l.trim(),h=0;if(this.options.pedantic?(h=2,s=l.trimStart()):u?h=t[1].length+1:(h=t[2].search(this.rules.other.nonSpaceChar),h=h>4?1:h,s=l.slice(h),h+=t[1].length),u&&this.rules.other.blankLine.test(c)&&(n+=c+"\n",e=e.substring(c.length+1),r=!0),!r){let t=this.rules.other.nextBulletRegex(h),r=this.rules.other.hrRegex(h),i=this.rules.other.fencesBeginRegex(h),o=this.rules.other.headingBeginRegex(h),a=this.rules.other.htmlBeginRegex(h);for(;e;){let d,p=e.split("\n",1)[0];if(c=p,this.options.pedantic?(c=c.replace(this.rules.other.listReplaceNesting," "),d=c):d=c.replace(this.rules.other.tabCharGlobal," "),i.test(c)||o.test(c)||a.test(c)||t.test(c)||r.test(c))break;if(d.search(this.rules.other.nonSpaceChar)>=h||!c.trim())s+="\n"+d.slice(h);else{if(u||l.replace(this.rules.other.tabCharGlobal," ").search(this.rules.other.nonSpaceChar)>=4||i.test(l)||o.test(l)||r.test(l))break;s+="\n"+c}!u&&!c.trim()&&(u=!0),n+=p+"\n",e=e.substring(p.length+1),l=d.slice(h)}}i.loose||(a?i.loose=!0:this.rules.other.doubleBlankLine.test(n)&&(a=!0));let d,p=null;this.options.gfm&&(p=this.rules.other.listIsTask.exec(s),p&&(d="[ ] "!==p[0],s=s.replace(this.rules.other.listReplaceTask,""))),i.items.push({type:"list_item",raw:n,task:!!p,checked:d,loose:!1,text:s,tokens:[]}),i.raw+=n}let s=i.items.at(-1);if(!s)return;s.raw=s.raw.trimEnd(),s.text=s.text.trimEnd(),i.raw=i.raw.trimEnd();for(let e=0;e<i.items.length;e++)if(this.lexer.state.top=!1,i.items[e].tokens=this.lexer.blockTokens(i.items[e].text,[]),!i.loose){let t=i.items[e].tokens.filter(e=>"space"===e.type),r=t.length>0&&t.some(e=>this.rules.other.anyLine.test(e.raw));i.loose=r}if(i.loose)for(let e=0;e<i.items.length;e++)i.items[e].loose=!0;return i}}html(e){let t=this.rules.block.html.exec(e);if(t)return{type:"html",block:!0,raw:t[0],pre:"pre"===t[1]||"script"===t[1]||"style"===t[1],text:t[0]}}def(e){let t=this.rules.block.def.exec(e);if(t){let e=t[1].toLowerCase().replace(this.rules.other.multipleSpaceGlobal," "),r=t[2]?t[2].replace(this.rules.other.hrefBrackets,"$1").replace(this.rules.inline.anyPunctuation,"$1"):"",n=t[3]?t[3].substring(1,t[3].length-1).replace(this.rules.inline.anyPunctuation,"$1"):t[3];return{type:"def",tag:e,raw:t[0],href:r,title:n}}}table(e){var t;let r=this.rules.block.table.exec(e);if(!r||!this.rules.other.tableDelimiter.test(r[2]))return;let n=W_(r[1]),i=r[2].replace(this.rules.other.tableAlignChars,"").split("|"),o=(null==(t=r[3])?void 0:t.trim())?r[3].replace(this.rules.other.tableRowBlankLine,"").split("\n"):[],a={type:"table",raw:r[0],header:[],align:[],rows:[]};if(n.length===i.length){for(let e of i)this.rules.other.tableAlignRight.test(e)?a.align.push("right"):this.rules.other.tableAlignCenter.test(e)?a.align.push("center"):this.rules.other.tableAlignLeft.test(e)?a.align.push("left"):a.align.push(null);for(let e=0;e<n.length;e++)a.header.push({text:n[e],tokens:this.lexer.inline(n[e]),header:!0,align:a.align[e]});for(let e of o)a.rows.push(W_(e,a.header.length).map((e,t)=>({text:e,tokens:this.lexer.inline(e),header:!1,align:a.align[t]})));return a}}lheading(e){let t=this.rules.block.lheading.exec(e);if(t)return{type:"heading",raw:t[0],depth:"="===t[2].charAt(0)?1:2,text:t[1],tokens:this.lexer.inline(t[1])}}paragraph(e){let t=this.rules.block.paragraph.exec(e);if(t){let e="\n"===t[1].charAt(t[1].length-1)?t[1].slice(0,-1):t[1];return{type:"paragraph",raw:t[0],text:e,tokens:this.lexer.inline(e)}}}text(e){let t=this.rules.block.text.exec(e);if(t)return{type:"text",raw:t[0],text:t[0],tokens:this.lexer.inline(t[0])}}escape(e){let t=this.rules.inline.escape.exec(e);if(t)return{type:"escape",raw:t[0],text:t[1]}}tag(e){let t=this.rules.inline.tag.exec(e);if(t)return!this.lexer.state.inLink&&this.rules.other.startATag.test(t[0])?this.lexer.state.inLink=!0:this.lexer.state.inLink&&this.rules.other.endATag.test(t[0])&&(this.lexer.state.inLink=!1),!this.lexer.state.inRawBlock&&this.rules.other.startPreScriptTag.test(t[0])?this.lexer.state.inRawBlock=!0:this.lexer.state.inRawBlock&&this.rules.other.endPreScriptTag.test(t[0])&&(this.lexer.state.inRawBlock=!1),{type:"html",raw:t[0],inLink:this.lexer.state.inLink,inRawBlock:this.lexer.state.inRawBlock,block:!1,text:t[0]}}link(e){let t=this.rules.inline.link.exec(e);if(t){let e=t[2].trim();if(!this.options.pedantic&&this.rules.other.startAngleBracket.test(e)){if(!this.rules.other.endAngleBracket.test(e))return;let t=H_(e.slice(0,-1),"\\");if((e.length-t.length)%2==0)return}else{let e=function(e,t){if(-1===e.indexOf(t[1]))return-1;let r=0;for(let n=0;n<e.length;n++)if("\\"===e[n])n++;else if(e[n]===t[0])r++;else if(e[n]===t[1]&&(r--,r<0))return n;return r>0?-2:-1}(t[2],"()");if(-2===e)return;if(e>-1){let r=(0===t[0].indexOf("!")?5:4)+t[1].length+e;t[2]=t[2].substring(0,e),t[0]=t[0].substring(0,r).trim(),t[3]=""}}let r=t[2],n="";if(this.options.pedantic){let e=this.rules.other.pedanticHrefTitle.exec(r);e&&(r=e[1],n=e[3])}else n=t[3]?t[3].slice(1,-1):"";return r=r.trim(),this.rules.other.startAngleBracket.test(r)&&(r=this.options.pedantic&&!this.rules.other.endAngleBracket.test(e)?r.slice(1):r.slice(1,-1)),q_(t,{href:r&&r.replace(this.rules.inline.anyPunctuation,"$1"),title:n&&n.replace(this.rules.inline.anyPunctuation,"$1")},t[0],this.lexer,this.rules)}}reflink(e,t){let r;if((r=this.rules.inline.reflink.exec(e))||(r=this.rules.inline.nolink.exec(e))){let e=t[(r[2]||r[1]).replace(this.rules.other.multipleSpaceGlobal," ").toLowerCase()];if(!e){let e=r[0].charAt(0);return{type:"text",raw:e,text:e}}return q_(r,e,r[0],this.lexer,this.rules)}}emStrong(e,t,r=""){let n=this.rules.inline.emStrongLDelim.exec(e);if(!(!n||n[3]&&r.match(this.rules.other.unicodeAlphaNumeric))&&(!n[1]&&!n[2]||!r||this.rules.inline.punctuation.exec(r))){let r,i,o=[...n[0]].length-1,a=o,s=0,l="*"===n[0][0]?this.rules.inline.emStrongRDelimAst:this.rules.inline.emStrongRDelimUnd;for(l.lastIndex=0,t=t.slice(-1*e.length+o);null!=(n=l.exec(t));){if(r=n[1]||n[2]||n[3]||n[4]||n[5]||n[6],!r)continue;if(i=[...r].length,n[3]||n[4]){a+=i;continue}if((n[5]||n[6])&&o%3&&!((o+i)%3)){s+=i;continue}if(a-=i,a>0)continue;i=Math.min(i,i+a+s);let t=[...n[0]][0].length,l=e.slice(0,o+n.index+t+i);if(Math.min(o,i)%2){let e=l.slice(1,-1);return{type:"em",raw:l,text:e,tokens:this.lexer.inlineTokens(e)}}let c=l.slice(2,-2);return{type:"strong",raw:l,text:c,tokens:this.lexer.inlineTokens(c)}}}}codespan(e){let t=this.rules.inline.code.exec(e);if(t){let e=t[2].replace(this.rules.other.newLineCharGlobal," "),r=this.rules.other.nonSpaceChar.test(e),n=this.rules.other.startingSpaceChar.test(e)&&this.rules.other.endingSpaceChar.test(e);return r&&n&&(e=e.substring(1,e.length-1)),{type:"codespan",raw:t[0],text:e}}}br(e){let t=this.rules.inline.br.exec(e);if(t)return{type:"br",raw:t[0]}}del(e){let t=this.rules.inline.del.exec(e);if(t)return{type:"del",raw:t[0],text:t[2],tokens:this.lexer.inlineTokens(t[2])}}autolink(e){let t=this.rules.inline.autolink.exec(e);if(t){let e,r;return"@"===t[2]?(e=t[1],r="mailto:"+e):(e=t[1],r=e),{type:"link",raw:t[0],text:e,href:r,tokens:[{type:"text",raw:e,text:e}]}}}url(e){var t;let r;if(r=this.rules.inline.url.exec(e)){let e,n;if("@"===r[2])e=r[0],n="mailto:"+e;else{let i;do{i=r[0],r[0]=(null==(t=this.rules.inline._backpedal.exec(r[0]))?void 0:t[0])??""}while(i!==r[0]);e=r[0],n="www."===r[1]?"http://"+r[0]:r[0]}return{type:"link",raw:r[0],text:e,href:n,tokens:[{type:"text",raw:e,text:e}]}}}inlineText(e){let t=this.rules.inline.text.exec(e);if(t){let e=this.lexer.state.inRawBlock;return{type:"text",raw:t[0],text:t[0],escaped:e}}}},G_=class e{constructor(e){y(this,"tokens"),y(this,"options"),y(this,"state"),y(this,"tokenizer"),y(this,"inlineQueue"),this.tokens=[],this.tokens.links=Object.create(null),this.options=e||zS,this.options.tokenizer=this.options.tokenizer||new U_,this.tokenizer=this.options.tokenizer,this.tokenizer.options=this.options,this.tokenizer.lexer=this,this.inlineQueue=[],this.state={inLink:!1,inRawBlock:!1,top:!0};let t={other:US,block:O_.normal,inline:F_.normal};this.options.pedantic?(t.block=O_.pedantic,t.inline=F_.pedantic):this.options.gfm&&(t.block=O_.gfm,this.options.breaks?t.inline=F_.breaks:t.inline=F_.gfm),this.tokenizer.rules=t}static get rules(){return{block:O_,inline:F_}}static lex(t,r){return new e(r).lex(t)}static lexInline(t,r){return new e(r).inlineTokens(t)}lex(e){e=e.replace(US.carriageReturn,"\n"),this.blockTokens(e,this.tokens);for(let t=0;t<this.inlineQueue.length;t++){let e=this.inlineQueue[t];this.inlineTokens(e.src,e.tokens)}return this.inlineQueue=[],this.tokens}blockTokens(e,t=[],r=!1){var n,i,o;for(this.options.pedantic&&(e=e.replace(US.tabCharGlobal," ").replace(US.spaceLine,""));e;){let a;if(null==(i=null==(n=this.options.extensions)?void 0:n.block)?void 0:i.some(r=>!!(a=r.call({lexer:this},e,t))&&(e=e.substring(a.raw.length),t.push(a),!0)))continue;if(a=this.tokenizer.space(e)){e=e.substring(a.raw.length);let r=t.at(-1);1===a.raw.length&&void 0!==r?r.raw+="\n":t.push(a);continue}if(a=this.tokenizer.code(e)){e=e.substring(a.raw.length);let r=t.at(-1);"paragraph"===(null==r?void 0:r.type)||"text"===(null==r?void 0:r.type)?(r.raw+=(r.raw.endsWith("\n")?"":"\n")+a.raw,r.text+="\n"+a.text,this.inlineQueue.at(-1).src=r.text):t.push(a);continue}if(a=this.tokenizer.fences(e)){e=e.substring(a.raw.length),t.push(a);continue}if(a=this.tokenizer.heading(e)){e=e.substring(a.raw.length),t.push(a);continue}if(a=this.tokenizer.hr(e)){e=e.substring(a.raw.length),t.push(a);continue}if(a=this.tokenizer.blockquote(e)){e=e.substring(a.raw.length),t.push(a);continue}if(a=this.tokenizer.list(e)){e=e.substring(a.raw.length),t.push(a);continue}if(a=this.tokenizer.html(e)){e=e.substring(a.raw.length),t.push(a);continue}if(a=this.tokenizer.def(e)){e=e.substring(a.raw.length);let r=t.at(-1);"paragraph"===(null==r?void 0:r.type)||"text"===(null==r?void 0:r.type)?(r.raw+=(r.raw.endsWith("\n")?"":"\n")+a.raw,r.text+="\n"+a.raw,this.inlineQueue.at(-1).src=r.text):this.tokens.links[a.tag]||(this.tokens.links[a.tag]={href:a.href,title:a.title},t.push(a));continue}if(a=this.tokenizer.table(e)){e=e.substring(a.raw.length),t.push(a);continue}if(a=this.tokenizer.lheading(e)){e=e.substring(a.raw.length),t.push(a);continue}let s=e;if(null==(o=this.options.extensions)?void 0:o.startBlock){let t,r=1/0,n=e.slice(1);this.options.extensions.startBlock.forEach(e=>{t=e.call({lexer:this},n),"number"==typeof t&&t>=0&&(r=Math.min(r,t))}),r<1/0&&r>=0&&(s=e.substring(0,r+1))}if(this.state.top&&(a=this.tokenizer.paragraph(s))){let n=t.at(-1);r&&"paragraph"===(null==n?void 0:n.type)?(n.raw+=(n.raw.endsWith("\n")?"":"\n")+a.raw,n.text+="\n"+a.text,this.inlineQueue.pop(),this.inlineQueue.at(-1).src=n.text):t.push(a),r=s.length!==e.length,e=e.substring(a.raw.length);continue}if(a=this.tokenizer.text(e)){e=e.substring(a.raw.length);let r=t.at(-1);"text"===(null==r?void 0:r.type)?(r.raw+=(r.raw.endsWith("\n")?"":"\n")+a.raw,r.text+="\n"+a.text,this.inlineQueue.pop(),this.inlineQueue.at(-1).src=r.text):t.push(a);continue}if(e){let t="Infinite loop on byte: "+e.charCodeAt(0);if(this.options.silent){console.error(t);break}throw new Error(t)}}return this.state.top=!0,t}inline(e,t=[]){return this.inlineQueue.push({src:e,tokens:t}),t}inlineTokens(e,t=[]){var r,n,i,o,a;let s,l=e,c=null;if(this.tokens.links){let e=Object.keys(this.tokens.links);if(e.length>0)for(;null!=(c=this.tokenizer.rules.inline.reflinkSearch.exec(l));)e.includes(c[0].slice(c[0].lastIndexOf("[")+1,-1))&&(l=l.slice(0,c.index)+"["+"a".repeat(c[0].length-2)+"]"+l.slice(this.tokenizer.rules.inline.reflinkSearch.lastIndex))}for(;null!=(c=this.tokenizer.rules.inline.anyPunctuation.exec(l));)l=l.slice(0,c.index)+"++"+l.slice(this.tokenizer.rules.inline.anyPunctuation.lastIndex);for(;null!=(c=this.tokenizer.rules.inline.blockSkip.exec(l));)s=c[2]?c[2].length:0,l=l.slice(0,c.index+s)+"["+"a".repeat(c[0].length-s-2)+"]"+l.slice(this.tokenizer.rules.inline.blockSkip.lastIndex);l=(null==(n=null==(r=this.options.hooks)?void 0:r.emStrongMask)?void 0:n.call({lexer:this},l))??l;let u=!1,h="";for(;e;){let r;if(u||(h=""),u=!1,null==(o=null==(i=this.options.extensions)?void 0:i.inline)?void 0:o.some(n=>!!(r=n.call({lexer:this},e,t))&&(e=e.substring(r.raw.length),t.push(r),!0)))continue;if(r=this.tokenizer.escape(e)){e=e.substring(r.raw.length),t.push(r);continue}if(r=this.tokenizer.tag(e)){e=e.substring(r.raw.length),t.push(r);continue}if(r=this.tokenizer.link(e)){e=e.substring(r.raw.length),t.push(r);continue}if(r=this.tokenizer.reflink(e,this.tokens.links)){e=e.substring(r.raw.length);let n=t.at(-1);"text"===r.type&&"text"===(null==n?void 0:n.type)?(n.raw+=r.raw,n.text+=r.text):t.push(r);continue}if(r=this.tokenizer.emStrong(e,l,h)){e=e.substring(r.raw.length),t.push(r);continue}if(r=this.tokenizer.codespan(e)){e=e.substring(r.raw.length),t.push(r);continue}if(r=this.tokenizer.br(e)){e=e.substring(r.raw.length),t.push(r);continue}if(r=this.tokenizer.del(e)){e=e.substring(r.raw.length),t.push(r);continue}if(r=this.tokenizer.autolink(e)){e=e.substring(r.raw.length),t.push(r);continue}if(!this.state.inLink&&(r=this.tokenizer.url(e))){e=e.substring(r.raw.length),t.push(r);continue}let n=e;if(null==(a=this.options.extensions)?void 0:a.startInline){let t,r=1/0,i=e.slice(1);this.options.extensions.startInline.forEach(e=>{t=e.call({lexer:this},i),"number"==typeof t&&t>=0&&(r=Math.min(r,t))}),r<1/0&&r>=0&&(n=e.substring(0,r+1))}if(r=this.tokenizer.inlineText(n)){e=e.substring(r.raw.length),"_"!==r.raw.slice(-1)&&(h=r.raw.slice(-1)),u=!0;let n=t.at(-1);"text"===(null==n?void 0:n.type)?(n.raw+=r.raw,n.text+=r.text):t.push(r);continue}if(e){let t="Infinite loop on byte: "+e.charCodeAt(0);if(this.options.silent){console.error(t);break}throw new Error(t)}}return t}},X_=class{constructor(e){y(this,"options"),y(this,"parser"),this.options=e||zS}space(e){return""}code({text:e,lang:t,escaped:r}){var n;let i=null==(n=(t||"").match(US.notSpaceStart))?void 0:n[0],o=e.replace(US.endingNewline,"")+"\n";return i?'<pre><code class="language-'+z_(i)+'">'+(r?o:z_(o,!0))+"</code></pre>\n":"<pre><code>"+(r?o:z_(o,!0))+"</code></pre>\n"}blockquote({tokens:e}){return`<blockquote>\n${this.parser.parse(e)}</blockquote>\n`}html({text:e}){return e}def(e){return""}heading({tokens:e,depth:t}){return`<h${t}>${this.parser.parseInline(e)}</h${t}>\n`}hr(e){return"<hr>\n"}list(e){let t=e.ordered,r=e.start,n="";for(let o=0;o<e.items.length;o++){let t=e.items[o];n+=this.listitem(t)}let i=t?"ol":"ul";return"<"+i+(t&&1!==r?' start="'+r+'"':"")+">\n"+n+"</"+i+">\n"}listitem(e){var t;let r="";if(e.task){let n=this.checkbox({checked:!!e.checked});e.loose?"paragraph"===(null==(t=e.tokens[0])?void 0:t.type)?(e.tokens[0].text=n+" "+e.tokens[0].text,e.tokens[0].tokens&&e.tokens[0].tokens.length>0&&"text"===e.tokens[0].tokens[0].type&&(e.tokens[0].tokens[0].text=n+" "+z_(e.tokens[0].tokens[0].text),e.tokens[0].tokens[0].escaped=!0)):e.tokens.unshift({type:"text",raw:n+" ",text:n+" ",escaped:!0}):r+=n+" "}return r+=this.parser.parse(e.tokens,!!e.loose),`<li>${r}</li>\n`}checkbox({checked:e}){return"<input "+(e?'checked="" ':"")+'disabled="" type="checkbox">'}paragraph({tokens:e}){return`<p>${this.parser.parseInline(e)}</p>\n`}table(e){let t="",r="";for(let i=0;i<e.header.length;i++)r+=this.tablecell(e.header[i]);t+=this.tablerow({text:r});let n="";for(let i=0;i<e.rows.length;i++){let t=e.rows[i];r="";for(let e=0;e<t.length;e++)r+=this.tablecell(t[e]);n+=this.tablerow({text:r})}return n&&(n=`<tbody>${n}</tbody>`),"<table>\n<thead>\n"+t+"</thead>\n"+n+"</table>\n"}tablerow({text:e}){return`<tr>\n${e}</tr>\n`}tablecell(e){let t=this.parser.parseInline(e.tokens),r=e.header?"th":"td";return(e.align?`<${r} align="${e.align}">`:`<${r}>`)+t+`</${r}>\n`}strong({tokens:e}){return`<strong>${this.parser.parseInline(e)}</strong>`}em({tokens:e}){return`<em>${this.parser.parseInline(e)}</em>`}codespan({text:e}){return`<code>${z_(e,!0)}</code>`}br(e){return"<br>"}del({tokens:e}){return`<del>${this.parser.parseInline(e)}</del>`}link({href:e,title:t,tokens:r}){let n=this.parser.parseInline(r),i=V_(e);if(null===i)return n;let o='<a href="'+(e=i)+'"';return t&&(o+=' title="'+z_(t)+'"'),o+=">"+n+"</a>",o}image({href:e,title:t,text:r,tokens:n}){n&&(r=this.parser.parseInline(n,this.parser.textRenderer));let i=V_(e);if(null===i)return z_(r);let o=`<img src="${e=i}" alt="${r}"`;return t&&(o+=` title="${z_(t)}"`),o+=">",o}text(e){return"tokens"in e&&e.tokens?this.parser.parseInline(e.tokens):"escaped"in e&&e.escaped?e.text:z_(e.text)}},J_=class{strong({text:e}){return e}em({text:e}){return e}codespan({text:e}){return e}del({text:e}){return e}html({text:e}){return e}text({text:e}){return e}link({text:e}){return""+e}image({text:e}){return""+e}br(){return""}},Y_=class e{constructor(e){y(this,"options"),y(this,"renderer"),y(this,"textRenderer"),this.options=e||zS,this.options.renderer=this.options.renderer||new X_,this.renderer=this.options.renderer,this.renderer.options=this.options,this.renderer.parser=this,this.textRenderer=new J_}static parse(t,r){return new e(r).parse(t)}static parseInline(t,r){return new e(r).parseInline(t)}parse(e,t=!0){var r,n;let i="";for(let o=0;o<e.length;o++){let a=e[o];if(null==(n=null==(r=this.options.extensions)?void 0:r.renderers)?void 0:n[a.type]){let e=a,t=this.options.extensions.renderers[e.type].call({parser:this},e);if(!1!==t||!["space","hr","heading","code","table","blockquote","list","html","def","paragraph","text"].includes(e.type)){i+=t||"";continue}}let s=a;switch(s.type){case"space":i+=this.renderer.space(s);continue;case"hr":i+=this.renderer.hr(s);continue;case"heading":i+=this.renderer.heading(s);continue;case"code":i+=this.renderer.code(s);continue;case"table":i+=this.renderer.table(s);continue;case"blockquote":i+=this.renderer.blockquote(s);continue;case"list":i+=this.renderer.list(s);continue;case"html":i+=this.renderer.html(s);continue;case"def":i+=this.renderer.def(s);continue;case"paragraph":i+=this.renderer.paragraph(s);continue;case"text":{let r=s,n=this.renderer.text(r);for(;o+1<e.length&&"text"===e[o+1].type;)r=e[++o],n+="\n"+this.renderer.text(r);i+=t?this.renderer.paragraph({type:"paragraph",raw:n,text:n,tokens:[{type:"text",raw:n,text:n,escaped:!0}]}):n;continue}default:{let e='Token with "'+s.type+'" type was not found.';if(this.options.silent)return console.error(e),"";throw new Error(e)}}}return i}parseInline(e,t=this.renderer){var r,n;let i="";for(let o=0;o<e.length;o++){let a=e[o];if(null==(n=null==(r=this.options.extensions)?void 0:r.renderers)?void 0:n[a.type]){let e=this.options.extensions.renderers[a.type].call({parser:this},a);if(!1!==e||!["escape","html","link","image","strong","em","codespan","br","del","text"].includes(a.type)){i+=e||"";continue}}let s=a;switch(s.type){case"escape":case"text":i+=t.text(s);break;case"html":i+=t.html(s);break;case"link":i+=t.link(s);break;case"image":i+=t.image(s);break;case"strong":i+=t.strong(s);break;case"em":i+=t.em(s);break;case"codespan":i+=t.codespan(s);break;case"br":i+=t.br(s);break;case"del":i+=t.del(s);break;default:{let e='Token with "'+s.type+'" type was not found.';if(this.options.silent)return console.error(e),"";throw new Error(e)}}}return i}},Z_=(f=class{constructor(e){y(this,"options"),y(this,"block"),this.options=e||zS}preprocess(e){return e}postprocess(e){return e}processAllTokens(e){return e}emStrongMask(e){return e}provideLexer(){return this.block?G_.lex:G_.lexInline}provideParser(){return this.block?Y_.parse:Y_.parseInline}},y(f,"passThroughHooks",new Set(["preprocess","postprocess","processAllTokens","emStrongMask"])),y(f,"passThroughHooksRespectAsync",new Set(["preprocess","postprocess","processAllTokens"])),f),K_=new class{constructor(...e){y(this,"defaults",{async:!1,breaks:!1,extensions:null,gfm:!0,hooks:null,pedantic:!1,renderer:null,silent:!1,tokenizer:null,walkTokens:null}),y(this,"options",this.setOptions),y(this,"parse",this.parseMarkdown(!0)),y(this,"parseInline",this.parseMarkdown(!1)),y(this,"Parser",Y_),y(this,"Renderer",X_),y(this,"TextRenderer",J_),y(this,"Lexer",G_),y(this,"Tokenizer",U_),y(this,"Hooks",Z_),this.use(...e)}walkTokens(e,t){var r,n;let i=[];for(let o of e)switch(i=i.concat(t.call(this,o)),o.type){case"table":{let e=o;for(let r of e.header)i=i.concat(this.walkTokens(r.tokens,t));for(let r of e.rows)for(let e of r)i=i.concat(this.walkTokens(e.tokens,t));break}case"list":{let e=o;i=i.concat(this.walkTokens(e.items,t));break}default:{let e=o;(null==(n=null==(r=this.defaults.extensions)?void 0:r.childTokens)?void 0:n[e.type])?this.defaults.extensions.childTokens[e.type].forEach(r=>{let n=e[r].flat(1/0);i=i.concat(this.walkTokens(n,t))}):e.tokens&&(i=i.concat(this.walkTokens(e.tokens,t)))}}return i}use(...e){let t=this.defaults.extensions||{renderers:{},childTokens:{}};return e.forEach(e=>{let r={...e};if(r.async=this.defaults.async||r.async||!1,e.extensions&&(e.extensions.forEach(e=>{if(!e.name)throw new Error("extension name required");if("renderer"in e){let r=t.renderers[e.name];t.renderers[e.name]=r?function(...t){let n=e.renderer.apply(this,t);return!1===n&&(n=r.apply(this,t)),n}:e.renderer}if("tokenizer"in e){if(!e.level||"block"!==e.level&&"inline"!==e.level)throw new Error("extension level must be 'block' or 'inline'");let r=t[e.level];r?r.unshift(e.tokenizer):t[e.level]=[e.tokenizer],e.start&&("block"===e.level?t.startBlock?t.startBlock.push(e.start):t.startBlock=[e.start]:"inline"===e.level&&(t.startInline?t.startInline.push(e.start):t.startInline=[e.start]))}"childTokens"in e&&e.childTokens&&(t.childTokens[e.name]=e.childTokens)}),r.extensions=t),e.renderer){let t=this.defaults.renderer||new X_(this.defaults);for(let r in e.renderer){if(!(r in t))throw new Error(`renderer '${r}' does not exist`);if(["options","parser"].includes(r))continue;let n=r,i=e.renderer[n],o=t[n];t[n]=(...e)=>{let r=i.apply(t,e);return!1===r&&(r=o.apply(t,e)),r||""}}r.renderer=t}if(e.tokenizer){let t=this.defaults.tokenizer||new U_(this.defaults);for(let r in e.tokenizer){if(!(r in t))throw new Error(`tokenizer '${r}' does not exist`);if(["options","rules","lexer"].includes(r))continue;let n=r,i=e.tokenizer[n],o=t[n];t[n]=(...e)=>{let r=i.apply(t,e);return!1===r&&(r=o.apply(t,e)),r}}r.tokenizer=t}if(e.hooks){let t=this.defaults.hooks||new Z_;for(let r in e.hooks){if(!(r in t))throw new Error(`hook '${r}' does not exist`);if(["options","block"].includes(r))continue;let n=r,i=e.hooks[n],o=t[n];Z_.passThroughHooks.has(r)?t[n]=e=>{if(this.defaults.async&&Z_.passThroughHooksRespectAsync.has(r))return(async()=>{let r=await i.call(t,e);return o.call(t,r)})();let n=i.call(t,e);return o.call(t,n)}:t[n]=(...e)=>{if(this.defaults.async)return(async()=>{let r=await i.apply(t,e);return!1===r&&(r=await o.apply(t,e)),r})();let r=i.apply(t,e);return!1===r&&(r=o.apply(t,e)),r}}r.hooks=t}if(e.walkTokens){let t=this.defaults.walkTokens,n=e.walkTokens;r.walkTokens=function(e){let r=[];return r.push(n.call(this,e)),t&&(r=r.concat(t.call(this,e))),r}}this.defaults={...this.defaults,...r}}),this}setOptions(e){return this.defaults={...this.defaults,...e},this}lexer(e,t){return G_.lex(e,t??this.defaults)}parser(e,t){return Y_.parse(e,t??this.defaults)}parseMarkdown(e){return(t,r)=>{let n={...r},i={...this.defaults,...n},o=this.onError(!!i.silent,!!i.async);if(!0===this.defaults.async&&!1===n.async)return o(new Error("marked(): The async option was set to true by an extension. Remove async: false from the parse options object to return a Promise."));if(typeof t>"u"||null===t)return o(new Error("marked(): input parameter is undefined or null"));if("string"!=typeof t)return o(new Error("marked(): input parameter is of type "+Object.prototype.toString.call(t)+", string expected"));if(i.hooks&&(i.hooks.options=i,i.hooks.block=e),i.async)return(async()=>{let r=i.hooks?await i.hooks.preprocess(t):t,n=await(i.hooks?await i.hooks.provideLexer():e?G_.lex:G_.lexInline)(r,i),o=i.hooks?await i.hooks.processAllTokens(n):n;i.walkTokens&&await Promise.all(this.walkTokens(o,i.walkTokens));let a=await(i.hooks?await i.hooks.provideParser():e?Y_.parse:Y_.parseInline)(o,i);return i.hooks?await i.hooks.postprocess(a):a})().catch(o);try{i.hooks&&(t=i.hooks.preprocess(t));let r=(i.hooks?i.hooks.provideLexer():e?G_.lex:G_.lexInline)(t,i);i.hooks&&(r=i.hooks.processAllTokens(r)),i.walkTokens&&this.walkTokens(r,i.walkTokens);let n=(i.hooks?i.hooks.provideParser():e?Y_.parse:Y_.parseInline)(r,i);return i.hooks&&(n=i.hooks.postprocess(n)),n}catch(a){return o(a)}}}onError(e,t){return r=>{if(r.message+="\nPlease report this to https://github.com/markedjs/marked.",e){let e="<p>An error occurred:</p><pre>"+z_(r.message+"",!0)+"</pre>";return t?Promise.resolve(e):e}if(t)return Promise.reject(r);throw r}}};function Q_(e,t){return K_.parse(e,t)}function eT(e){for(var t=[],r=1;r<arguments.length;r++)t[r-1]=arguments[r];var n=Array.from("string"==typeof e?[e]:e);n[n.length-1]=n[n.length-1].replace(/\r?\n([\t ]*)$/,"");var i=n.reduce(function(e,t){var r=t.match(/\n([\t ]+|(?!\s).)/g);return r?e.concat(r.map(function(e){var t,r;return null!==(r=null===(t=e.match(/[\t ]/g))||void 0===t?void 0:t.length)&&void 0!==r?r:0})):e},[]);if(i.length){var o=new RegExp("\n[\t ]{"+Math.min.apply(Math,i)+"}","g");n=n.map(function(e){return e.replace(o,"\n")})}n[0]=n[0].replace(/^\r?\n/,"");var a=n[0];return t.forEach(function(e,t){var r=a.match(/(?:^|\n)( *)$/),i=r?r[1]:"",o=e;"string"==typeof e&&e.includes("\n")&&(o=String(e).split("\n").map(function(e,t){return 0===t?e:""+i+e}).join("\n")),a+=o+n[t+1]}),a}Q_.options=Q_.setOptions=function(e){return K_.setOptions(e),Q_.defaults=K_.defaults,VS(Q_.defaults),Q_},Q_.getDefaults=$S,Q_.defaults=zS,Q_.use=function(...e){return K_.use(...e),Q_.defaults=K_.defaults,VS(Q_.defaults),Q_},Q_.walkTokens=function(e,t){return K_.walkTokens(e,t)},Q_.parseInline=K_.parseInline,Q_.Parser=Y_,Q_.parser=Y_.parse,Q_.Renderer=X_,Q_.TextRenderer=J_,Q_.Lexer=G_,Q_.lexer=G_.lex,Q_.Tokenizer=U_,Q_.Hooks=Z_,Q_.parse=Q_,Q_.options,Q_.setOptions,Q_.use,Q_.walkTokens,Q_.parseInline,Y_.parse,G_.lex;var tT={body:'<g><rect width="80" height="80" style="fill: #087ebf; stroke-width: 0px;"/><text transform="translate(21.16 64.67)" style="fill: #fff; font-family: ArialMT, Arial; font-size: 67.75px;"><tspan x="0" y="0">?</tspan></text></g>',height:80,width:80},rT=new Map,nT=new Map,iT=mu(e=>{for(const t of e){if(!t.name)throw new Error('Invalid icon loader. Must have a "name" property with non-empty string value.');if(bu.debug("Registering icon pack:",t.name),"loader"in t)nT.set(t.name,t.loader);else{if(!("icons"in t))throw bu.error("Invalid icon loader:",t),new Error('Invalid icon loader. Must have either "icons" or "loader" property.');rT.set(t.name,t.icons)}}},"registerIconPacks"),oT=mu(async(e,t)=>{const r=((e,t,r,n="")=>{const i=e.split(":");if("@"===e.slice(0,1)){if(i.length<2||i.length>3)return null;n=i.shift().slice(1)}if(i.length>3||!i.length)return null;if(i.length>1){const e=i.pop(),t=i.pop(),r={provider:i.length>0?i[0]:n,prefix:t,name:e};return MS(r)?r:null}const o=i[0],a=o.split("-");if(a.length>1){const e={provider:n,prefix:a.shift(),name:a.join("-")};return MS(e)?e:null}if(r&&""===n){const e={provider:n,prefix:"",name:o};return MS(e,r)?e:null}return null})(e,0,void 0!==t);if(!r)throw new Error(`Invalid icon name: ${e}`);const n=r.prefix||t;if(!n)throw new Error(`Icon name must contain a prefix: ${e}`);let i=rT.get(n);if(!i){const e=nT.get(n);if(!e)throw new Error(`Icon set not found: ${r.prefix}`);try{i={...await e(),prefix:n},rT.set(n,i)}catch(a){throw bu.error(a),new Error(`Failed to load icon set: ${r.prefix}`)}}const o=LS(i,r.name);if(!o)throw new Error(`Icon not found: ${e}`);return o},"getRegisteredIconData"),aT=mu(async e=>{try{return await oT(e),!0}catch{return!1}},"isIconAvailable"),sT=mu(async(e,t,r)=>{let n;try{n=await oT(e,null==t?void 0:t.fallbackPrefix)}catch(a){bu.error(a),n=tT}const i=function(e,t){const r={...TS,...e},n={...ES,...t},i={left:r.left,top:r.top,width:r.width,height:r.height};let o=r.body;[r,n].forEach(e=>{const t=[],r=e.hFlip,n=e.vFlip;let a,s=e.rotate;switch(r?n?s+=2:(t.push("translate("+(i.width+i.left).toString()+" "+(0-i.top).toString()+")"),t.push("scale(-1 1)"),i.top=i.left=0):n&&(t.push("translate("+(0-i.left).toString()+" "+(i.height+i.top).toString()+")"),t.push("scale(1 -1)"),i.top=i.left=0),s<0&&(s-=4*Math.floor(s/4)),s%=4,s){case 1:a=i.height/2+i.top,t.unshift("rotate(90 "+a.toString()+" "+a.toString()+")");break;case 2:t.unshift("rotate(180 "+(i.width/2+i.left).toString()+" "+(i.height/2+i.top).toString()+")");break;case 3:a=i.width/2+i.left,t.unshift("rotate(-90 "+a.toString()+" "+a.toString()+")")}s%2==1&&(i.left!==i.top&&(a=i.left,i.left=i.top,i.top=a),i.width!==i.height&&(a=i.width,i.width=i.height,i.height=a)),t.length&&(o=function(e,t,r){const n=function(e,t="defs"){let r="";const n=e.indexOf("<"+t);for(;n>=0;){const i=e.indexOf(">",n),o=e.indexOf("</"+t);if(-1===i||-1===o)break;const a=e.indexOf(">",o);if(-1===a)break;r+=e.slice(i+1,o).trim(),e=e.slice(0,n).trim()+e.slice(a+1)}return{defs:r,content:e}}(e);return i=n.defs,o=t+n.content+r,i?"<defs>"+i+"</defs>"+o:o;var i,o}(o,'<g transform="'+t.join(" ")+'">',"</g>"))});const a=n.width,s=n.height,l=i.width,c=i.height;let u,h;null===a?(h=null===s?"1em":"auto"===s?c:s,u=DS(h,l/c)):(u="auto"===a?l:a,h=null===s?DS(u,c/l):"auto"===s?c:s);const d={},p=(e,t)=>{(e=>"unset"===e||"undefined"===e||"none"===e)(t)||(d[e]=t.toString())};p("width",u),p("height",h);const f=[i.left,i.top,l,c];return d.viewBox=f.join(" "),{attributes:d,viewBox:f,body:o}}(n,t),o=function(e,t){let r=-1===e.indexOf("xlink:")?"":' xmlns:xlink="http://www.w3.org/1999/xlink"';for(const n in t)r+=" "+n+'="'+t[n]+'"';return'<svg xmlns="http://www.w3.org/2000/svg"'+r+">"+e+"</svg>"}(RS(i.body),{...i.attributes,...r});return Zd(o,Dd())},"getIconSVG");function lT(e,{markdownAutoWrap:t}){const r=eT(e.replace(/<br\/>/g,"\n").replace(/\n{2,}/g,"\n"));return!1===t?r.replace(/ /g," "):r}function cT(e,t={}){const r=lT(e,t),n=Q_.lexer(r),i=[[]];let o=0;function a(e,t="normal"){if("text"===e.type){e.text.split("\n").forEach((e,r)=>{0!==r&&(o++,i.push([])),e.split(" ").forEach(e=>{(e=e.replace(/'/g,"'"))&&i[o].push({content:e,type:t})})})}else"strong"===e.type||"em"===e.type?e.tokens.forEach(t=>{a(t,e.type)}):"html"===e.type&&i[o].push({content:e.text,type:"normal"})}return mu(a,"processNode"),n.forEach(e=>{var t;"paragraph"===e.type?null==(t=e.tokens)||t.forEach(e=>{a(e)}):"html"===e.type?i[o].push({content:e.text,type:"normal"}):i[o].push({content:e.raw,type:"normal"})}),i}function uT(e,{markdownAutoWrap:t}={}){const r=Q_.lexer(e);function n(e){var r,i,o;return"text"===e.type?!1===t?e.text.replace(/\n */g,"<br/>").replace(/ /g," "):e.text.replace(/\n */g,"<br/>"):"strong"===e.type?`<strong>${null==(r=e.tokens)?void 0:r.map(n).join("")}</strong>`:"em"===e.type?`<em>${null==(i=e.tokens)?void 0:i.map(n).join("")}</em>`:"paragraph"===e.type?`<p>${null==(o=e.tokens)?void 0:o.map(n).join("")}</p>`:"space"===e.type?"":"html"===e.type?`${e.text}`:"escape"===e.type?e.text:(bu.warn(`Unsupported markdown: ${e.type}`),e.raw)}return mu(n,"output"),r.map(n).join("")}function hT(e){return Intl.Segmenter?[...(new Intl.Segmenter).segment(e)].map(e=>e.segment):[...e]}function dT(e,t){return pT(e,[],hT(t.content),t.type)}function pT(e,t,r,n){if(0===r.length)return[{content:t.join(""),type:n},{content:"",type:n}];const[i,...o]=r,a=[...t,i];return e([{content:a.join(""),type:n}])?pT(e,a,o,n):(0===t.length&&i&&(t.push(i),r.shift()),[{content:t.join(""),type:n},{content:r.join(""),type:n}])}function fT(e,t){if(e.some(({content:e})=>e.includes("\n")))throw new Error("splitLineToFitWidth does not support newlines in the line");return gT(e,t)}function gT(e,t,r=[],n=[]){if(0===e.length)return n.length>0&&r.push(n),r.length>0?r:[];let i="";" "===e[0].content&&(i=" ",e.shift());const o=e.shift()??{content:" ",type:"normal"},a=[...n];if(""!==i&&a.push({content:i,type:"normal"}),a.push(o),t(a))return gT(e,t,r,a);if(n.length>0)r.push(n),e.unshift(o);else if(o.content){const[n,i]=dT(t,o);r.push([n]),i.content&&e.unshift(i)}return gT(e,t,r)}function mT(e,t){t&&e.attr("style",t)}async function yT(e,t,r,n,i=!1,o=Dd()){const a=e.append("foreignObject");a.attr("width",10*r+"px"),a.attr("height",10*r+"px");const s=a.append("xhtml:div"),l=pp(t.label)?await mp(t.label.replace(yp.lineBreakRegex,"\n"),o):Zd(t.label,o),c=t.isNode?"nodeLabel":"edgeLabel",u=s.append("span");u.html(l),mT(u,t.labelStyle),u.attr("class",`${c} ${n}`),mT(s,t.labelStyle),s.style("display","table-cell"),s.style("white-space","nowrap"),s.style("line-height","1.5"),s.style("max-width",r+"px"),s.style("text-align","center"),s.attr("xmlns","http://www.w3.org/1999/xhtml"),i&&s.attr("class","labelBkg");let h=s.node().getBoundingClientRect();return h.width===r&&(s.style("display","table"),s.style("white-space","break-spaces"),s.style("width",r+"px"),h=s.node().getBoundingClientRect()),a.node()}function xT(e,t,r){return e.append("tspan").attr("class","text-outer-tspan").attr("x",0).attr("y",t*r-.1+"em").attr("dy",r+"em")}function bT(e,t,r){const n=e.append("text"),i=xT(n,1,t);wT(i,r);const o=i.node().getComputedTextLength();return n.remove(),o}function vT(e,t,r){var n;const i=e.append("text"),o=xT(i,1,t);wT(o,[{content:r,type:"normal"}]);const a=null==(n=o.node())?void 0:n.getBoundingClientRect();return a&&i.remove(),a}function CT(e,t,r,n=!1){const i=t.append("g"),o=i.insert("rect").attr("class","background").attr("style","stroke: none"),a=i.append("text").attr("y","-10.1");let s=0;for(const l of r){const t=mu(t=>bT(i,1.1,t)<=e,"checkWidth"),r=t(l)?[l]:fT(l,t);for(const e of r){wT(xT(a,s,1.1),e),s++}}if(n){const e=a.node().getBBox(),t=2;return o.attr("x",e.x-t).attr("y",e.y-t).attr("width",e.width+2*t).attr("height",e.height+2*t),i.node()}return a.node()}function wT(e,t){e.text(""),t.forEach((t,r)=>{const n=e.append("tspan").attr("font-style","em"===t.type?"italic":"normal").attr("class","text-inner-tspan").attr("font-weight","strong"===t.type?"bold":"normal");0===r?n.text(t.content):n.text(" "+t.content)})}async function kT(e,t={}){const r=[];e.replace(/(fa[bklrs]?):fa-([\w-]+)/g,(e,n,i)=>(r.push((async()=>{const r=`${n}:${i}`;return await aT(r)?await sT(r,void 0,{class:"label-icon"}):`<i class='${Zd(e,t).replace(":"," ")}'></i>`})()),e));const n=await Promise.all(r);return e.replace(/(fa[bklrs]?):fa-([\w-]+)/g,()=>n.shift()??"")}mu(lT,"preprocessMarkdown"),mu(cT,"markdownToLines"),mu(uT,"markdownToHTML"),mu(hT,"splitTextToChars"),mu(dT,"splitWordToFitWidth"),mu(pT,"splitWordToFitWidthRecursion"),mu(fT,"splitLineToFitWidth"),mu(gT,"splitLineToFitWidthRecursion"),mu(mT,"applyStyle"),mu(yT,"addHtmlSpan"),mu(xT,"createTspan"),mu(bT,"computeWidthOfText"),mu(vT,"computeDimensionOfText"),mu(CT,"createFormattedText"),mu(wT,"updateTextContentAndStyles"),mu(kT,"replaceIconSubstring");var ST=mu(async(e,t="",{style:r="",isTitle:n=!1,classes:i="",useHtmlLabels:o=!0,isNode:a=!0,width:s=200,addSvgBackground:l=!1}={},c)=>{if(bu.debug("XYZ createText",t,r,n,i,o,a,"addSvgBackground: ",l),o){const n=uT(t,c),o=await kT(vS(n),c),u=t.replace(/\\\\/g,"\\"),h={isNode:a,label:pp(t)?u:o,labelStyle:r.replace("fill:","color:")};return await yT(e,h,s,i,l,c)}{const n=CT(s,e,cT(t.replace(/<br\s*\/?>/g,"<br/>").replace("<br>","<br/>"),c),!!t&&l);if(a){/stroke:/.exec(r)&&(r=r.replace("stroke:","lineColor:"));const e=r.replace(/stroke:[^;]+;?/g,"").replace(/stroke-width:[^;]+;?/g,"").replace(/fill:[^;]+;?/g,"").replace(/color:/g,"fill:");fg(n).attr("style",e)}else{const e=r.replace(/stroke:[^;]+;?/g,"").replace(/stroke-width:[^;]+;?/g,"").replace(/fill:[^;]+;?/g,"").replace(/background:/g,"fill:");fg(n).select("rect").attr("style",e.replace(/background:/g,"fill:"));const t=r.replace(/stroke:[^;]+;?/g,"").replace(/stroke-width:[^;]+;?/g,"").replace(/fill:[^;]+;?/g,"").replace(/color:/g,"fill:");fg(n).select("text").attr("style",t)}return n}},"createText");function _T(e,t,r){if(e&&e.length){const[n,i]=t,o=Math.PI/180*r,a=Math.cos(o),s=Math.sin(o);for(const t of e){const[e,r]=t;t[0]=(e-n)*a-(r-i)*s+n,t[1]=(e-n)*s+(r-i)*a+i}}}function TT(e,t){return e[0]===t[0]&&e[1]===t[1]}function AT(e,t){var r;const n=t.hachureAngle+90;let i=t.hachureGap;i<0&&(i=4*t.strokeWidth),i=Math.round(Math.max(i,.1));let o=1;return t.roughness>=1&&((null===(r=t.randomizer)||void 0===r?void 0:r.next())||Math.random())>.7&&(o=i),function(e,t,r,n=1){const i=r,o=Math.max(t,.1),a=e[0]&&e[0][0]&&"number"==typeof e[0][0]?[e]:e,s=[0,0];if(i)for(const c of a)_T(c,s,i);const l=function(e,t,r){const n=[];for(const c of e){const e=[...c];TT(e[0],e[e.length-1])||e.push([e[0][0],e[0][1]]),e.length>2&&n.push(e)}const i=[];t=Math.max(t,.1);const o=[];for(const c of n)for(let e=0;e<c.length-1;e++){const t=c[e],r=c[e+1];if(t[1]!==r[1]){const e=Math.min(t[1],r[1]);o.push({ymin:e,ymax:Math.max(t[1],r[1]),x:e===t[1]?t[0]:r[0],islope:(r[0]-t[0])/(r[1]-t[1])})}}if(o.sort((e,t)=>e.ymin<t.ymin?-1:e.ymin>t.ymin?1:e.x<t.x?-1:e.x>t.x?1:e.ymax===t.ymax?0:(e.ymax-t.ymax)/Math.abs(e.ymax-t.ymax)),!o.length)return i;let a=[],s=o[0].ymin,l=0;for(;a.length||o.length;){if(o.length){let e=-1;for(let t=0;t<o.length&&!(o[t].ymin>s);t++)e=t;o.splice(0,e+1).forEach(e=>{a.push({s:s,edge:e})})}if(a=a.filter(e=>!(e.edge.ymax<=s)),a.sort((e,t)=>e.edge.x===t.edge.x?0:(e.edge.x-t.edge.x)/Math.abs(e.edge.x-t.edge.x)),(1!==r||l%t==0)&&a.length>1)for(let e=0;e<a.length;e+=2){const t=e+1;if(t>=a.length)break;const r=a[e].edge,n=a[t].edge;i.push([[Math.round(r.x),s],[Math.round(n.x),s]])}s+=r,a.forEach(e=>{e.edge.x=e.edge.x+r*e.edge.islope}),l++}return i}(a,o,n);if(i){for(const e of a)_T(e,s,-i);!function(e,t,r){const n=[];e.forEach(e=>n.push(...e)),_T(n,t,r)}(l,s,-i)}return l}(e,i,n,o||1)}class PT{constructor(e){this.helper=e}fillPolygons(e,t){return this._fillPolygons(e,t)}_fillPolygons(e,t){const r=AT(e,t);return{type:"fillSketch",ops:this.renderLines(r,t)}}renderLines(e,t){const r=[];for(const n of e)r.push(...this.helper.doubleLineOps(n[0][0],n[0][1],n[1][0],n[1][1],t));return r}}function ET(e){const t=e[0],r=e[1];return Math.sqrt(Math.pow(t[0]-r[0],2)+Math.pow(t[1]-r[1],2))}class MT extends PT{fillPolygons(e,t){let r=t.hachureGap;r<0&&(r=4*t.strokeWidth),r=Math.max(r,.1);const n=AT(e,Object.assign({},t,{hachureGap:r})),i=Math.PI/180*t.hachureAngle,o=[],a=.5*r*Math.cos(i),s=.5*r*Math.sin(i);for(const[l,c]of n)ET([l,c])&&o.push([[l[0]-a,l[1]+s],[...c]],[[l[0]+a,l[1]-s],[...c]]);return{type:"fillSketch",ops:this.renderLines(o,t)}}}class IT extends PT{fillPolygons(e,t){const r=this._fillPolygons(e,t),n=Object.assign({},t,{hachureAngle:t.hachureAngle+90}),i=this._fillPolygons(e,n);return r.ops=r.ops.concat(i.ops),r}}class BT{constructor(e){this.helper=e}fillPolygons(e,t){const r=AT(e,t=Object.assign({},t,{hachureAngle:0}));return this.dotsOnLines(r,t)}dotsOnLines(e,t){const r=[];let n=t.hachureGap;n<0&&(n=4*t.strokeWidth),n=Math.max(n,.1);let i=t.fillWeight;i<0&&(i=t.strokeWidth/2);const o=n/4;for(const a of e){const e=ET(a),s=e/n,l=Math.ceil(s)-1,c=e-l*n,u=(a[0][0]+a[1][0])/2-n/4,h=Math.min(a[0][1],a[1][1]);for(let a=0;a<l;a++){const e=h+c+a*n,s=u-o+2*Math.random()*o,l=e-o+2*Math.random()*o,d=this.helper.ellipse(s,l,i,i,t);r.push(...d.ops)}}return{type:"fillSketch",ops:r}}}class LT{constructor(e){this.helper=e}fillPolygons(e,t){const r=AT(e,t);return{type:"fillSketch",ops:this.dashedLine(r,t)}}dashedLine(e,t){const r=t.dashOffset<0?t.hachureGap<0?4*t.strokeWidth:t.hachureGap:t.dashOffset,n=t.dashGap<0?t.hachureGap<0?4*t.strokeWidth:t.hachureGap:t.dashGap,i=[];return e.forEach(e=>{const o=ET(e),a=Math.floor(o/(r+n)),s=(o+n-a*(r+n))/2;let l=e[0],c=e[1];l[0]>c[0]&&(l=e[1],c=e[0]);const u=Math.atan((c[1]-l[1])/(c[0]-l[0]));for(let h=0;h<a;h++){const e=h*(r+n),o=e+r,a=[l[0]+e*Math.cos(u)+s*Math.cos(u),l[1]+e*Math.sin(u)+s*Math.sin(u)],c=[l[0]+o*Math.cos(u)+s*Math.cos(u),l[1]+o*Math.sin(u)+s*Math.sin(u)];i.push(...this.helper.doubleLineOps(a[0],a[1],c[0],c[1],t))}}),i}}class jT{constructor(e){this.helper=e}fillPolygons(e,t){const r=t.hachureGap<0?4*t.strokeWidth:t.hachureGap,n=t.zigzagOffset<0?r:t.zigzagOffset,i=AT(e,t=Object.assign({},t,{hachureGap:r+n}));return{type:"fillSketch",ops:this.zigzagLines(i,n,t)}}zigzagLines(e,t,r){const n=[];return e.forEach(e=>{const i=ET(e),o=Math.round(i/(2*t));let a=e[0],s=e[1];a[0]>s[0]&&(a=e[1],s=e[0]);const l=Math.atan((s[1]-a[1])/(s[0]-a[0]));for(let c=0;c<o;c++){const e=2*c*t,i=2*(c+1)*t,o=Math.sqrt(2*Math.pow(t,2)),s=[a[0]+e*Math.cos(l),a[1]+e*Math.sin(l)],u=[a[0]+i*Math.cos(l),a[1]+i*Math.sin(l)],h=[s[0]+o*Math.cos(l+Math.PI/4),s[1]+o*Math.sin(l+Math.PI/4)];n.push(...this.helper.doubleLineOps(s[0],s[1],h[0],h[1],r),...this.helper.doubleLineOps(h[0],h[1],u[0],u[1],r))}}),n}}const NT={};class DT{constructor(e){this.seed=e}next(){return this.seed?(2**31-1&(this.seed=Math.imul(48271,this.seed)))/2**31:Math.random()}}const OT={A:7,a:7,C:6,c:6,H:1,h:1,L:2,l:2,M:2,m:2,Q:4,q:4,S:4,s:4,T:2,t:2,V:1,v:1,Z:0,z:0};function FT(e,t){return e.type===t}function RT(e){const t=[],r=function(e){const t=new Array;for(;""!==e;)if(e.match(/^([ \t\r\n,]+)/))e=e.substr(RegExp.$1.length);else if(e.match(/^([aAcChHlLmMqQsStTvVzZ])/))t[t.length]={type:0,text:RegExp.$1},e=e.substr(RegExp.$1.length);else{if(!e.match(/^(([-+]?[0-9]+(\.[0-9]*)?|[-+]?\.[0-9]+)([eE][-+]?[0-9]+)?)/))return[];t[t.length]={type:1,text:`${parseFloat(RegExp.$1)}`},e=e.substr(RegExp.$1.length)}return t[t.length]={type:2,text:""},t}(e);let n="BOD",i=0,o=r[i];for(;!FT(o,2);){let a=0;const s=[];if("BOD"===n){if("M"!==o.text&&"m"!==o.text)return RT("M0,0"+e);i++,a=OT[o.text],n=o.text}else FT(o,1)?a=OT[n]:(i++,a=OT[o.text],n=o.text);if(!(i+a<r.length))throw new Error("Path data ended short");for(let e=i;e<i+a;e++){const t=r[e];if(!FT(t,1))throw new Error("Param not a number: "+n+","+t.text);s[s.length]=+t.text}if("number"!=typeof OT[n])throw new Error("Bad segment: "+n);{const e={key:n,data:s};t.push(e),i+=a,o=r[i],"M"===n&&(n="L"),"m"===n&&(n="l")}}return t}function $T(e){let t=0,r=0,n=0,i=0;const o=[];for(const{key:a,data:s}of e)switch(a){case"M":o.push({key:"M",data:[...s]}),[t,r]=s,[n,i]=s;break;case"m":t+=s[0],r+=s[1],o.push({key:"M",data:[t,r]}),n=t,i=r;break;case"L":o.push({key:"L",data:[...s]}),[t,r]=s;break;case"l":t+=s[0],r+=s[1],o.push({key:"L",data:[t,r]});break;case"C":o.push({key:"C",data:[...s]}),t=s[4],r=s[5];break;case"c":{const e=s.map((e,n)=>n%2?e+r:e+t);o.push({key:"C",data:e}),t=e[4],r=e[5];break}case"Q":o.push({key:"Q",data:[...s]}),t=s[2],r=s[3];break;case"q":{const e=s.map((e,n)=>n%2?e+r:e+t);o.push({key:"Q",data:e}),t=e[2],r=e[3];break}case"A":o.push({key:"A",data:[...s]}),t=s[5],r=s[6];break;case"a":t+=s[5],r+=s[6],o.push({key:"A",data:[s[0],s[1],s[2],s[3],s[4],t,r]});break;case"H":o.push({key:"H",data:[...s]}),t=s[0];break;case"h":t+=s[0],o.push({key:"H",data:[t]});break;case"V":o.push({key:"V",data:[...s]}),r=s[0];break;case"v":r+=s[0],o.push({key:"V",data:[r]});break;case"S":o.push({key:"S",data:[...s]}),t=s[2],r=s[3];break;case"s":{const e=s.map((e,n)=>n%2?e+r:e+t);o.push({key:"S",data:e}),t=e[2],r=e[3];break}case"T":o.push({key:"T",data:[...s]}),t=s[0],r=s[1];break;case"t":t+=s[0],r+=s[1],o.push({key:"T",data:[t,r]});break;case"Z":case"z":o.push({key:"Z",data:[]}),t=n,r=i}return o}function zT(e){const t=[];let r="",n=0,i=0,o=0,a=0,s=0,l=0;for(const{key:c,data:u}of e){switch(c){case"M":t.push({key:"M",data:[...u]}),[n,i]=u,[o,a]=u;break;case"C":t.push({key:"C",data:[...u]}),n=u[4],i=u[5],s=u[2],l=u[3];break;case"L":t.push({key:"L",data:[...u]}),[n,i]=u;break;case"H":n=u[0],t.push({key:"L",data:[n,i]});break;case"V":i=u[0],t.push({key:"L",data:[n,i]});break;case"S":{let e=0,o=0;"C"===r||"S"===r?(e=n+(n-s),o=i+(i-l)):(e=n,o=i),t.push({key:"C",data:[e,o,...u]}),s=u[0],l=u[1],n=u[2],i=u[3];break}case"T":{const[e,o]=u;let a=0,c=0;"Q"===r||"T"===r?(a=n+(n-s),c=i+(i-l)):(a=n,c=i);const h=n+2*(a-n)/3,d=i+2*(c-i)/3,p=e+2*(a-e)/3,f=o+2*(c-o)/3;t.push({key:"C",data:[h,d,p,f,e,o]}),s=a,l=c,n=e,i=o;break}case"Q":{const[e,r,o,a]=u,c=n+2*(e-n)/3,h=i+2*(r-i)/3,d=o+2*(e-o)/3,p=a+2*(r-a)/3;t.push({key:"C",data:[c,h,d,p,o,a]}),s=e,l=r,n=o,i=a;break}case"A":{const e=Math.abs(u[0]),r=Math.abs(u[1]),o=u[2],a=u[3],s=u[4],l=u[5],c=u[6];0===e||0===r?(t.push({key:"C",data:[n,i,l,c,l,c]}),n=l,i=c):n===l&&i===c||(WT(n,i,l,c,e,r,o,a,s).forEach(function(e){t.push({key:"C",data:e})}),n=l,i=c);break}case"Z":t.push({key:"Z",data:[]}),n=o,i=a}r=c}return t}function VT(e,t,r){return[e*Math.cos(r)-t*Math.sin(r),e*Math.sin(r)+t*Math.cos(r)]}function WT(e,t,r,n,i,o,a,s,l,c){const u=(h=a,Math.PI*h/180);var h;let d=[],p=0,f=0,g=0,m=0;if(c)[p,f,g,m]=c;else{[e,t]=VT(e,t,-u),[r,n]=VT(r,n,-u);const a=(e-r)/2,c=(t-n)/2;let h=a*a/(i*i)+c*c/(o*o);h>1&&(h=Math.sqrt(h),i*=h,o*=h);const d=i*i,y=o*o,x=d*y-d*c*c-y*a*a,b=d*c*c+y*a*a,v=(s===l?-1:1)*Math.sqrt(Math.abs(x/b));g=v*i*c/o+(e+r)/2,m=v*-o*a/i+(t+n)/2,p=Math.asin(parseFloat(((t-m)/o).toFixed(9))),f=Math.asin(parseFloat(((n-m)/o).toFixed(9))),e<g&&(p=Math.PI-p),r<g&&(f=Math.PI-f),p<0&&(p=2*Math.PI+p),f<0&&(f=2*Math.PI+f),l&&p>f&&(p-=2*Math.PI),!l&&f>p&&(f-=2*Math.PI)}let y=f-p;if(Math.abs(y)>120*Math.PI/180){const e=f,t=r,s=n;f=l&&f>p?p+120*Math.PI/180*1:p+120*Math.PI/180*-1,d=WT(r=g+i*Math.cos(f),n=m+o*Math.sin(f),t,s,i,o,a,0,l,[f,e,g,m])}y=f-p;const x=Math.cos(p),b=Math.sin(p),v=Math.cos(f),C=Math.sin(f),w=Math.tan(y/4),k=4/3*i*w,S=4/3*o*w,_=[e,t],T=[e+k*b,t-S*x],A=[r+k*C,n-S*v],P=[r,n];if(T[0]=2*_[0]-T[0],T[1]=2*_[1]-T[1],c)return[T,A,P].concat(d);{d=[T,A,P].concat(d);const e=[];for(let t=0;t<d.length;t+=3){const r=VT(d[t][0],d[t][1],u),n=VT(d[t+1][0],d[t+1][1],u),i=VT(d[t+2][0],d[t+2][1],u);e.push([r[0],r[1],n[0],n[1],i[0],i[1]])}return e}}const HT={randOffset:function(e,t){return nA(e,t)},randOffsetWithRange:function(e,t,r){return rA(e,t,r)},ellipse:function(e,t,r,n,i){return JT(e,t,i,XT(r,n,i)).opset},doubleLineOps:function(e,t,r,n,i){return iA(e,t,r,n,i,!0)}};function qT(e,t,r,n,i){return{type:"path",ops:iA(e,t,r,n,i)}}function UT(e,t,r){const n=(e||[]).length;if(n>2){const i=[];for(let t=0;t<n-1;t++)i.push(...iA(e[t][0],e[t][1],e[t+1][0],e[t+1][1],r));return t&&i.push(...iA(e[n-1][0],e[n-1][1],e[0][0],e[0][1],r)),{type:"path",ops:i}}return 2===n?qT(e[0][0],e[0][1],e[1][0],e[1][1],r):{type:"path",ops:[]}}function GT(e,t){if(e.length){const r="number"==typeof e[0][0]?[e]:e,n=aA(r[0],1*(1+.2*t.roughness),t),i=t.disableMultiStroke?[]:aA(r[0],1.5*(1+.22*t.roughness),eA(t));for(let e=1;e<r.length;e++){const o=r[e];if(o.length){const e=aA(o,1*(1+.2*t.roughness),t),r=t.disableMultiStroke?[]:aA(o,1.5*(1+.22*t.roughness),eA(t));for(const t of e)"move"!==t.op&&n.push(t);for(const t of r)"move"!==t.op&&i.push(t)}}return{type:"path",ops:n.concat(i)}}return{type:"path",ops:[]}}function XT(e,t,r){const n=Math.sqrt(2*Math.PI*Math.sqrt((Math.pow(e/2,2)+Math.pow(t/2,2))/2)),i=Math.ceil(Math.max(r.curveStepCount,r.curveStepCount/Math.sqrt(200)*n)),o=2*Math.PI/i;let a=Math.abs(e/2),s=Math.abs(t/2);const l=1-r.curveFitting;return a+=nA(a*l,r),s+=nA(s*l,r),{increment:o,rx:a,ry:s}}function JT(e,t,r,n){const[i,o]=lA(n.increment,e,t,n.rx,n.ry,1,n.increment*rA(.1,rA(.4,1,r),r),r);let a=sA(i,null,r);if(!r.disableMultiStroke&&0!==r.roughness){const[i]=lA(n.increment,e,t,n.rx,n.ry,1.5,0,r),o=sA(i,null,r);a=a.concat(o)}return{estimatedPoints:o,opset:{type:"path",ops:a}}}function YT(e,t,r,n,i,o,a,s,l){const c=e,u=t;let h=Math.abs(r/2),d=Math.abs(n/2);h+=nA(.01*h,l),d+=nA(.01*d,l);let p=i,f=o;for(;p<0;)p+=2*Math.PI,f+=2*Math.PI;f-p>2*Math.PI&&(p=0,f=2*Math.PI);const g=2*Math.PI/l.curveStepCount,m=Math.min(g/2,(f-p)/2),y=cA(m,c,u,h,d,p,f,1,l);if(!l.disableMultiStroke){const e=cA(m,c,u,h,d,p,f,1.5,l);y.push(...e)}return a&&(s?y.push(...iA(c,u,c+h*Math.cos(p),u+d*Math.sin(p),l),...iA(c,u,c+h*Math.cos(f),u+d*Math.sin(f),l)):y.push({op:"lineTo",data:[c,u]},{op:"lineTo",data:[c+h*Math.cos(p),u+d*Math.sin(p)]})),{type:"path",ops:y}}function ZT(e,t){const r=zT($T(RT(e))),n=[];let i=[0,0],o=[0,0];for(const{key:a,data:s}of r)switch(a){case"M":o=[s[0],s[1]],i=[s[0],s[1]];break;case"L":n.push(...iA(o[0],o[1],s[0],s[1],t)),o=[s[0],s[1]];break;case"C":{const[e,r,i,a,l,c]=s;n.push(...uA(e,r,i,a,l,c,o,t)),o=[l,c];break}case"Z":n.push(...iA(o[0],o[1],i[0],i[1],t)),o=[i[0],i[1]]}return{type:"path",ops:n}}function KT(e,t){const r=[];for(const n of e)if(n.length){const e=t.maxRandomnessOffset||0,i=n.length;if(i>2){r.push({op:"move",data:[n[0][0]+nA(e,t),n[0][1]+nA(e,t)]});for(let o=1;o<i;o++)r.push({op:"lineTo",data:[n[o][0]+nA(e,t),n[o][1]+nA(e,t)]})}}return{type:"fillPath",ops:r}}function QT(e,t){return function(e,t){let r=e.fillStyle||"hachure";if(!NT[r])switch(r){case"zigzag":NT[r]||(NT[r]=new MT(t));break;case"cross-hatch":NT[r]||(NT[r]=new IT(t));break;case"dots":NT[r]||(NT[r]=new BT(t));break;case"dashed":NT[r]||(NT[r]=new LT(t));break;case"zigzag-line":NT[r]||(NT[r]=new jT(t));break;default:r="hachure",NT[r]||(NT[r]=new PT(t))}return NT[r]}(t,HT).fillPolygons(e,t)}function eA(e){const t=Object.assign({},e);return t.randomizer=void 0,e.seed&&(t.seed=e.seed+1),t}function tA(e){return e.randomizer||(e.randomizer=new DT(e.seed||0)),e.randomizer.next()}function rA(e,t,r,n=1){return r.roughness*n*(tA(r)*(t-e)+e)}function nA(e,t,r=1){return rA(-e,e,t,r)}function iA(e,t,r,n,i,o=!1){const a=o?i.disableMultiStrokeFill:i.disableMultiStroke,s=oA(e,t,r,n,i,!0,!1);if(a)return s;const l=oA(e,t,r,n,i,!0,!0);return s.concat(l)}function oA(e,t,r,n,i,o,a){const s=Math.pow(e-r,2)+Math.pow(t-n,2),l=Math.sqrt(s);let c=1;c=l<200?1:l>500?.4:-.0016668*l+1.233334;let u=i.maxRandomnessOffset||0;u*u*100>s&&(u=l/10);const h=u/2,d=.2+.2*tA(i);let p=i.bowing*i.maxRandomnessOffset*(n-t)/200,f=i.bowing*i.maxRandomnessOffset*(e-r)/200;p=nA(p,i,c),f=nA(f,i,c);const g=[],m=()=>nA(h,i,c),y=()=>nA(u,i,c),x=i.preserveVertices;return a?g.push({op:"move",data:[e+(x?0:m()),t+(x?0:m())]}):g.push({op:"move",data:[e+(x?0:nA(u,i,c)),t+(x?0:nA(u,i,c))]}),a?g.push({op:"bcurveTo",data:[p+e+(r-e)*d+m(),f+t+(n-t)*d+m(),p+e+2*(r-e)*d+m(),f+t+2*(n-t)*d+m(),r+(x?0:m()),n+(x?0:m())]}):g.push({op:"bcurveTo",data:[p+e+(r-e)*d+y(),f+t+(n-t)*d+y(),p+e+2*(r-e)*d+y(),f+t+2*(n-t)*d+y(),r+(x?0:y()),n+(x?0:y())]}),g}function aA(e,t,r){if(!e.length)return[];const n=[];n.push([e[0][0]+nA(t,r),e[0][1]+nA(t,r)]),n.push([e[0][0]+nA(t,r),e[0][1]+nA(t,r)]);for(let i=1;i<e.length;i++)n.push([e[i][0]+nA(t,r),e[i][1]+nA(t,r)]),i===e.length-1&&n.push([e[i][0]+nA(t,r),e[i][1]+nA(t,r)]);return sA(n,null,r)}function sA(e,t,r){const n=e.length,i=[];if(n>3){const t=[],o=1-r.curveTightness;i.push({op:"move",data:[e[1][0],e[1][1]]});for(let r=1;r+2<n;r++){const n=e[r];t[0]=[n[0],n[1]],t[1]=[n[0]+(o*e[r+1][0]-o*e[r-1][0])/6,n[1]+(o*e[r+1][1]-o*e[r-1][1])/6],t[2]=[e[r+1][0]+(o*e[r][0]-o*e[r+2][0])/6,e[r+1][1]+(o*e[r][1]-o*e[r+2][1])/6],t[3]=[e[r+1][0],e[r+1][1]],i.push({op:"bcurveTo",data:[t[1][0],t[1][1],t[2][0],t[2][1],t[3][0],t[3][1]]})}}else 3===n?(i.push({op:"move",data:[e[1][0],e[1][1]]}),i.push({op:"bcurveTo",data:[e[1][0],e[1][1],e[2][0],e[2][1],e[2][0],e[2][1]]})):2===n&&i.push(...oA(e[0][0],e[0][1],e[1][0],e[1][1],r,0,!0));return i}function lA(e,t,r,n,i,o,a,s){const l=[],c=[];if(0===s.roughness){e/=4,c.push([t+n*Math.cos(-e),r+i*Math.sin(-e)]);for(let o=0;o<=2*Math.PI;o+=e){const e=[t+n*Math.cos(o),r+i*Math.sin(o)];l.push(e),c.push(e)}c.push([t+n*Math.cos(0),r+i*Math.sin(0)]),c.push([t+n*Math.cos(e),r+i*Math.sin(e)])}else{const u=nA(.5,s)-Math.PI/2;c.push([nA(o,s)+t+.9*n*Math.cos(u-e),nA(o,s)+r+.9*i*Math.sin(u-e)]);const h=2*Math.PI+u-.01;for(let a=u;a<h;a+=e){const e=[nA(o,s)+t+n*Math.cos(a),nA(o,s)+r+i*Math.sin(a)];l.push(e),c.push(e)}c.push([nA(o,s)+t+n*Math.cos(u+2*Math.PI+.5*a),nA(o,s)+r+i*Math.sin(u+2*Math.PI+.5*a)]),c.push([nA(o,s)+t+.98*n*Math.cos(u+a),nA(o,s)+r+.98*i*Math.sin(u+a)]),c.push([nA(o,s)+t+.9*n*Math.cos(u+.5*a),nA(o,s)+r+.9*i*Math.sin(u+.5*a)])}return[c,l]}function cA(e,t,r,n,i,o,a,s,l){const c=o+nA(.1,l),u=[];u.push([nA(s,l)+t+.9*n*Math.cos(c-e),nA(s,l)+r+.9*i*Math.sin(c-e)]);for(let h=c;h<=a;h+=e)u.push([nA(s,l)+t+n*Math.cos(h),nA(s,l)+r+i*Math.sin(h)]);return u.push([t+n*Math.cos(a),r+i*Math.sin(a)]),u.push([t+n*Math.cos(a),r+i*Math.sin(a)]),sA(u,0,l)}function uA(e,t,r,n,i,o,a,s){const l=[],c=[s.maxRandomnessOffset||1,(s.maxRandomnessOffset||1)+.3];let u=[0,0];const h=s.disableMultiStroke?1:2,d=s.preserveVertices;for(let p=0;p<h;p++)0===p?l.push({op:"move",data:[a[0],a[1]]}):l.push({op:"move",data:[a[0]+(d?0:nA(c[0],s)),a[1]+(d?0:nA(c[0],s))]}),u=d?[i,o]:[i+nA(c[p],s),o+nA(c[p],s)],l.push({op:"bcurveTo",data:[e+nA(c[p],s),t+nA(c[p],s),r+nA(c[p],s),n+nA(c[p],s),u[0],u[1]]});return l}function hA(e){return[...e]}function dA(e,t=0){const r=e.length;if(r<3)throw new Error("A curve must have at least three points.");const n=[];if(3===r)n.push(hA(e[0]),hA(e[1]),hA(e[2]),hA(e[2]));else{const r=[];r.push(e[0],e[0]);for(let t=1;t<e.length;t++)r.push(e[t]),t===e.length-1&&r.push(e[t]);const i=[],o=1-t;n.push(hA(r[0]));for(let e=1;e+2<r.length;e++){const t=r[e];i[0]=[t[0],t[1]],i[1]=[t[0]+(o*r[e+1][0]-o*r[e-1][0])/6,t[1]+(o*r[e+1][1]-o*r[e-1][1])/6],i[2]=[r[e+1][0]+(o*r[e][0]-o*r[e+2][0])/6,r[e+1][1]+(o*r[e][1]-o*r[e+2][1])/6],i[3]=[r[e+1][0],r[e+1][1]],n.push(i[1],i[2],i[3])}}return n}function pA(e,t){return Math.pow(e[0]-t[0],2)+Math.pow(e[1]-t[1],2)}function fA(e,t,r){const n=pA(t,r);if(0===n)return pA(e,t);let i=((e[0]-t[0])*(r[0]-t[0])+(e[1]-t[1])*(r[1]-t[1]))/n;return i=Math.max(0,Math.min(1,i)),pA(e,gA(t,r,i))}function gA(e,t,r){return[e[0]+(t[0]-e[0])*r,e[1]+(t[1]-e[1])*r]}function mA(e,t,r,n){const i=n||[];if(function(e,t){const r=e[t+0],n=e[t+1],i=e[t+2],o=e[t+3];let a=3*n[0]-2*r[0]-o[0];a*=a;let s=3*n[1]-2*r[1]-o[1];s*=s;let l=3*i[0]-2*o[0]-r[0];l*=l;let c=3*i[1]-2*o[1]-r[1];return c*=c,a<l&&(a=l),s<c&&(s=c),a+s}(e,t)<r){const r=e[t+0];i.length?(o=i[i.length-1],a=r,Math.sqrt(pA(o,a))>1&&i.push(r)):i.push(r),i.push(e[t+3])}else{const n=.5,o=e[t+0],a=e[t+1],s=e[t+2],l=e[t+3],c=gA(o,a,n),u=gA(a,s,n),h=gA(s,l,n),d=gA(c,u,n),p=gA(u,h,n),f=gA(d,p,n);mA([o,c,d,f],0,r,i),mA([f,p,h,l],0,r,i)}var o,a;return i}function yA(e,t){return xA(e,0,e.length,t)}function xA(e,t,r,n,i){const o=i||[],a=e[t],s=e[r-1];let l=0,c=1;for(let u=t+1;u<r-1;++u){const t=fA(e[u],a,s);t>l&&(l=t,c=u)}return Math.sqrt(l)>n?(xA(e,t,c+1,n,o),xA(e,c,r,n,o)):(o.length||o.push(a),o.push(s)),o}function bA(e,t=.15,r){const n=[],i=(e.length-1)/3;for(let o=0;o<i;o++)mA(e,3*o,t,n);return r&&r>0?xA(n,0,n.length,r):n}const vA="none";class CA{constructor(e){this.defaultOptions={maxRandomnessOffset:2,roughness:1,bowing:1,stroke:"#000",strokeWidth:1,curveTightness:0,curveFitting:.95,curveStepCount:9,fillStyle:"hachure",fillWeight:-1,hachureAngle:-41,hachureGap:-1,dashOffset:-1,dashGap:-1,zigzagOffset:-1,seed:0,disableMultiStroke:!1,disableMultiStrokeFill:!1,preserveVertices:!1,fillShapeRoughnessGain:.8},this.config=e||{},this.config.options&&(this.defaultOptions=this._o(this.config.options))}static newSeed(){return Math.floor(Math.random()*2**31)}_o(e){return e?Object.assign({},this.defaultOptions,e):this.defaultOptions}_d(e,t,r){return{shape:e,sets:t||[],options:r||this.defaultOptions}}line(e,t,r,n,i){const o=this._o(i);return this._d("line",[qT(e,t,r,n,o)],o)}rectangle(e,t,r,n,i){const o=this._o(i),a=[],s=function(e,t,r,n,i){return UT([[e,t],[e+r,t],[e+r,t+n],[e,t+n]],!0,i)}(e,t,r,n,o);if(o.fill){const i=[[e,t],[e+r,t],[e+r,t+n],[e,t+n]];"solid"===o.fillStyle?a.push(KT([i],o)):a.push(QT([i],o))}return o.stroke!==vA&&a.push(s),this._d("rectangle",a,o)}ellipse(e,t,r,n,i){const o=this._o(i),a=[],s=XT(r,n,o),l=JT(e,t,o,s);if(o.fill)if("solid"===o.fillStyle){const r=JT(e,t,o,s).opset;r.type="fillPath",a.push(r)}else a.push(QT([l.estimatedPoints],o));return o.stroke!==vA&&a.push(l.opset),this._d("ellipse",a,o)}circle(e,t,r,n){const i=this.ellipse(e,t,r,r,n);return i.shape="circle",i}linearPath(e,t){const r=this._o(t);return this._d("linearPath",[UT(e,!1,r)],r)}arc(e,t,r,n,i,o,a=!1,s){const l=this._o(s),c=[],u=YT(e,t,r,n,i,o,a,!0,l);if(a&&l.fill)if("solid"===l.fillStyle){const a=Object.assign({},l);a.disableMultiStroke=!0;const s=YT(e,t,r,n,i,o,!0,!1,a);s.type="fillPath",c.push(s)}else c.push(function(e,t,r,n,i,o,a){const s=e,l=t;let c=Math.abs(r/2),u=Math.abs(n/2);c+=nA(.01*c,a),u+=nA(.01*u,a);let h=i,d=o;for(;h<0;)h+=2*Math.PI,d+=2*Math.PI;d-h>2*Math.PI&&(h=0,d=2*Math.PI);const p=(d-h)/a.curveStepCount,f=[];for(let g=h;g<=d;g+=p)f.push([s+c*Math.cos(g),l+u*Math.sin(g)]);return f.push([s+c*Math.cos(d),l+u*Math.sin(d)]),f.push([s,l]),QT([f],a)}(e,t,r,n,i,o,l));return l.stroke!==vA&&c.push(u),this._d("arc",c,l)}curve(e,t){const r=this._o(t),n=[],i=GT(e,r);if(r.fill&&r.fill!==vA)if("solid"===r.fillStyle){const t=GT(e,Object.assign(Object.assign({},r),{disableMultiStroke:!0,roughness:r.roughness?r.roughness+r.fillShapeRoughnessGain:0}));n.push({type:"fillPath",ops:this._mergedShape(t.ops)})}else{const t=[],i=e;if(i.length){const e="number"==typeof i[0][0]?[i]:i;for(const n of e)n.length<3?t.push(...n):3===n.length?t.push(...bA(dA([n[0],n[0],n[1],n[2]]),10,(1+r.roughness)/2)):t.push(...bA(dA(n),10,(1+r.roughness)/2))}t.length&&n.push(QT([t],r))}return r.stroke!==vA&&n.push(i),this._d("curve",n,r)}polygon(e,t){const r=this._o(t),n=[],i=UT(e,!0,r);return r.fill&&("solid"===r.fillStyle?n.push(KT([e],r)):n.push(QT([e],r))),r.stroke!==vA&&n.push(i),this._d("polygon",n,r)}path(e,t){const r=this._o(t),n=[];if(!e)return this._d("path",n,r);e=(e||"").replace(/\n/g," ").replace(/(-\s)/g,"-").replace("/(ss)/g"," ");const i=r.fill&&"transparent"!==r.fill&&r.fill!==vA,o=r.stroke!==vA,a=!!(r.simplification&&r.simplification<1),s=function(e,t,r){const n=zT($T(RT(e))),i=[];let o=[],a=[0,0],s=[];const l=()=>{s.length>=4&&o.push(...bA(s,1)),s=[]},c=()=>{l(),o.length&&(i.push(o),o=[])};for(const{key:h,data:d}of n)switch(h){case"M":c(),a=[d[0],d[1]],o.push(a);break;case"L":l(),o.push([d[0],d[1]]);break;case"C":if(!s.length){const e=o.length?o[o.length-1]:a;s.push([e[0],e[1]])}s.push([d[0],d[1]]),s.push([d[2],d[3]]),s.push([d[4],d[5]]);break;case"Z":l(),o.push([a[0],a[1]])}if(c(),!r)return i;const u=[];for(const h of i){const e=yA(h,r);e.length&&u.push(e)}return u}(e,0,a?4-4*(r.simplification||1):(1+r.roughness)/2),l=ZT(e,r);if(i)if("solid"===r.fillStyle)if(1===s.length){const t=ZT(e,Object.assign(Object.assign({},r),{disableMultiStroke:!0,roughness:r.roughness?r.roughness+r.fillShapeRoughnessGain:0}));n.push({type:"fillPath",ops:this._mergedShape(t.ops)})}else n.push(KT(s,r));else n.push(QT(s,r));return o&&(a?s.forEach(e=>{n.push(UT(e,!1,r))}):n.push(l)),this._d("path",n,r)}opsToPath(e,t){let r="";for(const n of e.ops){const e="number"==typeof t&&t>=0?n.data.map(e=>+e.toFixed(t)):n.data;switch(n.op){case"move":r+=`M${e[0]} ${e[1]} `;break;case"bcurveTo":r+=`C${e[0]} ${e[1]}, ${e[2]} ${e[3]}, ${e[4]} ${e[5]} `;break;case"lineTo":r+=`L${e[0]} ${e[1]} `}}return r.trim()}toPaths(e){const t=e.sets||[],r=e.options||this.defaultOptions,n=[];for(const i of t){let e=null;switch(i.type){case"path":e={d:this.opsToPath(i),stroke:r.stroke,strokeWidth:r.strokeWidth,fill:vA};break;case"fillPath":e={d:this.opsToPath(i),stroke:vA,strokeWidth:0,fill:r.fill||vA};break;case"fillSketch":e=this.fillSketch(i,r)}e&&n.push(e)}return n}fillSketch(e,t){let r=t.fillWeight;return r<0&&(r=t.strokeWidth/2),{d:this.opsToPath(e),stroke:t.fill||vA,strokeWidth:r,fill:vA}}_mergedShape(e){return e.filter((e,t)=>0===t||"move"!==e.op)}}const wA="http://www.w3.org/2000/svg";class kA{constructor(e,t){this.svg=e,this.gen=new CA(t)}draw(e){const t=e.sets||[],r=e.options||this.getDefaultOptions(),n=this.svg.ownerDocument||window.document,i=n.createElementNS(wA,"g"),o=e.options.fixedDecimalPlaceDigits;for(const a of t){let t=null;switch(a.type){case"path":t=n.createElementNS(wA,"path"),t.setAttribute("d",this.opsToPath(a,o)),t.setAttribute("stroke",r.stroke),t.setAttribute("stroke-width",r.strokeWidth+""),t.setAttribute("fill","none"),r.strokeLineDash&&t.setAttribute("stroke-dasharray",r.strokeLineDash.join(" ").trim()),r.strokeLineDashOffset&&t.setAttribute("stroke-dashoffset",`${r.strokeLineDashOffset}`);break;case"fillPath":t=n.createElementNS(wA,"path"),t.setAttribute("d",this.opsToPath(a,o)),t.setAttribute("stroke","none"),t.setAttribute("stroke-width","0"),t.setAttribute("fill",r.fill||""),"curve"!==e.shape&&"polygon"!==e.shape||t.setAttribute("fill-rule","evenodd");break;case"fillSketch":t=this.fillSketch(n,a,r)}t&&i.appendChild(t)}return i}fillSketch(e,t,r){let n=r.fillWeight;n<0&&(n=r.strokeWidth/2);const i=e.createElementNS(wA,"path");return i.setAttribute("d",this.opsToPath(t,r.fixedDecimalPlaceDigits)),i.setAttribute("stroke",r.fill||""),i.setAttribute("stroke-width",n+""),i.setAttribute("fill","none"),r.fillLineDash&&i.setAttribute("stroke-dasharray",r.fillLineDash.join(" ").trim()),r.fillLineDashOffset&&i.setAttribute("stroke-dashoffset",`${r.fillLineDashOffset}`),i}get generator(){return this.gen}getDefaultOptions(){return this.gen.defaultOptions}opsToPath(e,t){return this.gen.opsToPath(e,t)}line(e,t,r,n,i){const o=this.gen.line(e,t,r,n,i);return this.draw(o)}rectangle(e,t,r,n,i){const o=this.gen.rectangle(e,t,r,n,i);return this.draw(o)}ellipse(e,t,r,n,i){const o=this.gen.ellipse(e,t,r,n,i);return this.draw(o)}circle(e,t,r,n){const i=this.gen.circle(e,t,r,n);return this.draw(i)}linearPath(e,t){const r=this.gen.linearPath(e,t);return this.draw(r)}polygon(e,t){const r=this.gen.polygon(e,t);return this.draw(r)}arc(e,t,r,n,i,o,a=!1,s){const l=this.gen.arc(e,t,r,n,i,o,a,s);return this.draw(l)}curve(e,t){const r=this.gen.curve(e,t);return this.draw(r)}path(e,t){const r=this.gen.path(e,t);return this.draw(r)}}var SA=(e,t)=>new kA(e,t),_A=mu(async(e,t,r)=>{var n,i;let o;const a=t.useHtmlLabels||ip(null==(n=$p())?void 0:n.htmlLabels);o=r||"node default";const s=e.insert("g").attr("class",o).attr("id",t.domId||t.id),l=s.insert("g").attr("class","label").attr("style",wS(t.labelStyle));let c;c=void 0===t.label?"":"string"==typeof t.label?t.label:t.label[0];const u=await ST(l,Zd(vS(c),$p()),{useHtmlLabels:a,width:t.width||(null==(i=$p().flowchart)?void 0:i.wrappingWidth),cssClasses:"markdown-node-label",style:t.labelStyle,addSvgBackground:!!t.icon||!!t.img});let h=u.getBBox();const d=((null==t?void 0:t.padding)??0)/2;if(a){const e=u.children[0],t=fg(u),r=e.getElementsByTagName("img");if(r){const e=""===c.replace(/<img[^>]*>/g,"").trim();await Promise.all([...r].map(t=>new Promise(r=>{function n(){if(t.style.display="flex",t.style.flexDirection="column",e){const e=$p().fontSize?$p().fontSize:window.getComputedStyle(document.body).fontSize,r=5,[n=kd.fontSize]=mS(e),i=n*r+"px";t.style.minWidth=i,t.style.maxWidth=i}else t.style.width="100%";r(t)}mu(n,"setupImage"),setTimeout(()=>{t.complete&&n()}),t.addEventListener("error",n),t.addEventListener("load",n)})))}h=e.getBoundingClientRect(),t.attr("width",h.width),t.attr("height",h.height)}return a?l.attr("transform","translate("+-h.width/2+", "+-h.height/2+")"):l.attr("transform","translate(0, "+-h.height/2+")"),t.centerLabel&&l.attr("transform","translate("+-h.width/2+", "+-h.height/2+")"),l.insert("rect",":first-child"),{shapeSvg:s,bbox:h,halfPadding:d,label:l}},"labelHelper"),TA=mu(async(e,t,r)=>{var n,i,o,a,s,l;const c=r.useHtmlLabels||ip(null==(i=null==(n=$p())?void 0:n.flowchart)?void 0:i.htmlLabels),u=e.insert("g").attr("class","label").attr("style",r.labelStyle||""),h=await ST(u,Zd(vS(t),$p()),{useHtmlLabels:c,width:r.width||(null==(a=null==(o=$p())?void 0:o.flowchart)?void 0:a.wrappingWidth),style:r.labelStyle,addSvgBackground:!!r.icon||!!r.img});let d=h.getBBox();const p=r.padding/2;if(ip(null==(l=null==(s=$p())?void 0:s.flowchart)?void 0:l.htmlLabels)){const e=h.children[0],t=fg(h);d=e.getBoundingClientRect(),t.attr("width",d.width),t.attr("height",d.height)}return c?u.attr("transform","translate("+-d.width/2+", "+-d.height/2+")"):u.attr("transform","translate(0, "+-d.height/2+")"),r.centerLabel&&u.attr("transform","translate("+-d.width/2+", "+-d.height/2+")"),u.insert("rect",":first-child"),{shapeSvg:e,bbox:d,halfPadding:p,label:u}},"insertLabel"),AA=mu((e,t)=>{const r=t.node().getBBox();e.width=r.width,e.height=r.height},"updateNodeBounds"),PA=mu((e,t)=>("handDrawn"===e.look?"rough-node":"node")+" "+e.cssClasses+" "+(t||""),"getNodeClasses");function EA(e){const t=e.map((e,t)=>`${0===t?"M":"L"}${e.x},${e.y}`);return t.push("Z"),t.join(" ")}function MA(e,t,r,n,i,o){const a=[],s=r-e,l=n-t,c=s/o,u=2*Math.PI/c,h=t+l/2;for(let d=0;d<=50;d++){const t=e+d/50*s,r=h+i*Math.sin(u*(t-e));a.push({x:t,y:r})}return a}function IA(e,t,r,n,i,o){const a=[],s=i*Math.PI/180,l=(o*Math.PI/180-s)/(n-1);for(let c=0;c<n;c++){const n=s+c*l,i=e+r*Math.cos(n),o=t+r*Math.sin(n);a.push({x:-i,y:-o})}return a}mu(EA,"createPathFromPoints"),mu(MA,"generateFullSineWavePoints"),mu(IA,"generateCirclePoints");var BA=mu((e,t)=>{var r,n,i=e.x,o=e.y,a=t.x-i,s=t.y-o,l=e.width/2,c=e.height/2;return Math.abs(s)*l>Math.abs(a)*c?(s<0&&(c=-c),r=0===s?0:c*a/s,n=c):(a<0&&(l=-l),r=l,n=0===a?0:l*s/a),{x:i+r,y:o+n}},"intersectRect");function LA(e,t){t&&e.attr("style",t)}async function jA(e){const t=fg(document.createElementNS("http://www.w3.org/2000/svg","foreignObject")),r=t.append("xhtml:div"),n=$p();let i=e.label;e.label&&pp(e.label)&&(i=await mp(e.label.replace(yp.lineBreakRegex,"\n"),n));const o='<span class="'+(e.isNode?"nodeLabel":"edgeLabel")+'" '+(e.labelStyle?'style="'+e.labelStyle+'"':"")+">"+i+"</span>";return r.html(Zd(o,n)),LA(r,e.labelStyle),r.style("display","inline-block"),r.style("padding-right","1px"),r.style("white-space","nowrap"),r.attr("xmlns","http://www.w3.org/1999/xhtml"),t.node()}mu(LA,"applyStyle"),mu(jA,"addHtmlLabel");var NA=mu(async(e,t,r,n)=>{let i=e||"";if("object"==typeof i&&(i=i[0]),ip($p().flowchart.htmlLabels)){i=i.replace(/\\n|\n/g,"<br />"),bu.info("vertexText"+i);const e={isNode:n,label:vS(i).replace(/fa[blrs]?:fa-[\w-]+/g,e=>`<i class='${e.replace(":"," ")}'></i>`),labelStyle:t?t.replace("fill:","color:"):t};return await jA(e)}{const e=document.createElementNS("http://www.w3.org/2000/svg","text");e.setAttribute("style",t.replace("color:","fill:"));let n=[];n="string"==typeof i?i.split(/\\n|\n|<br\s*\/?>/gi):Array.isArray(i)?i:[];for(const t of n){const n=document.createElementNS("http://www.w3.org/2000/svg","tspan");n.setAttributeNS("http://www.w3.org/XML/1998/namespace","xml:space","preserve"),n.setAttribute("dy","1em"),n.setAttribute("x","0"),r?n.setAttribute("class","title-row"):n.setAttribute("class","row"),n.textContent=t.trim(),e.appendChild(n)}return e}},"createLabel"),DA=mu((e,t,r,n,i)=>["M",e+i,t,"H",e+r-i,"A",i,i,0,0,1,e+r,t+i,"V",t+n-i,"A",i,i,0,0,1,e+r-i,t+n,"H",e+i,"A",i,i,0,0,1,e,t+n-i,"V",t+i,"A",i,i,0,0,1,e+i,t,"Z"].join(" "),"createRoundedRectPathD"),OA=mu(async(e,t)=>{bu.info("Creating subgraph rect for ",t.id,t);const r=$p(),{themeVariables:n,handDrawnSeed:i}=r,{clusterBkg:o,clusterBorder:a}=n,{labelStyles:s,nodeStyles:l,borderStyles:c,backgroundStyles:u}=AC(t),h=e.insert("g").attr("class","cluster "+t.cssClasses).attr("id",t.id).attr("data-look",t.look),d=ip(r.flowchart.htmlLabels),p=h.insert("g").attr("class","cluster-label "),f=await ST(p,t.label,{style:t.labelStyle,useHtmlLabels:d,isNode:!0});let g=f.getBBox();if(ip(r.flowchart.htmlLabels)){const e=f.children[0],t=fg(f);g=e.getBoundingClientRect(),t.attr("width",g.width),t.attr("height",g.height)}const m=t.width<=g.width+t.padding?g.width+t.padding:t.width;t.width<=g.width+t.padding?t.diff=(m-t.width)/2-t.padding:t.diff=-t.padding;const y=t.height,x=t.x-m/2,b=t.y-y/2;let v;if(bu.trace("Data ",t,JSON.stringify(t)),"handDrawn"===t.look){const e=SA(h),r=PC(t,{roughness:.7,fill:o,stroke:a,fillWeight:3,seed:i}),n=e.path(DA(x,b,m,y,0),r);v=h.insert(()=>(bu.debug("Rough node insert CXC",n),n),":first-child"),v.select("path:nth-child(2)").attr("style",c.join(";")),v.select("path").attr("style",u.join(";").replace("fill","stroke"))}else v=h.insert("rect",":first-child"),v.attr("style",l).attr("rx",t.rx).attr("ry",t.ry).attr("x",x).attr("y",b).attr("width",m).attr("height",y);const{subGraphTitleTopMargin:C}=wC(r);if(p.attr("transform",`translate(${t.x-g.width/2}, ${t.y-t.height/2+C})`),s){const e=p.select("span");e&&e.attr("style",s)}const w=v.node().getBBox();return t.offsetX=0,t.width=w.width,t.height=w.height,t.offsetY=g.height-t.padding/2,t.intersect=function(e){return BA(t,e)},{cluster:h,labelBBox:g}},"rect"),FA=mu((e,t)=>{const r=e.insert("g").attr("class","note-cluster").attr("id",t.id),n=r.insert("rect",":first-child"),i=0*t.padding,o=i/2;n.attr("rx",t.rx).attr("ry",t.ry).attr("x",t.x-t.width/2-o).attr("y",t.y-t.height/2-o).attr("width",t.width+i).attr("height",t.height+i).attr("fill","none");const a=n.node().getBBox();return t.width=a.width,t.height=a.height,t.intersect=function(e){return BA(t,e)},{cluster:r,labelBBox:{width:0,height:0}}},"noteGroup"),RA=mu(async(e,t)=>{const r=$p(),{themeVariables:n,handDrawnSeed:i}=r,{altBackground:o,compositeBackground:a,compositeTitleBackground:s,nodeBorder:l}=n,c=e.insert("g").attr("class",t.cssClasses).attr("id",t.id).attr("data-id",t.id).attr("data-look",t.look),u=c.insert("g",":first-child"),h=c.insert("g").attr("class","cluster-label");let d=c.append("rect");const p=h.node().appendChild(await NA(t.label,t.labelStyle,void 0,!0));let f=p.getBBox();if(ip(r.flowchart.htmlLabels)){const e=p.children[0],t=fg(p);f=e.getBoundingClientRect(),t.attr("width",f.width),t.attr("height",f.height)}const g=0*t.padding,m=g/2,y=(t.width<=f.width+t.padding?f.width+t.padding:t.width)+g;t.width<=f.width+t.padding?t.diff=(y-t.width)/2-t.padding:t.diff=-t.padding;const x=t.height+g,b=t.height+g-f.height-6,v=t.x-y/2,C=t.y-x/2;t.width=y;const w=t.y-t.height/2-m+f.height+2;let k;if("handDrawn"===t.look){const e=t.cssClasses.includes("statediagram-cluster-alt"),r=SA(c),n=t.rx||t.ry?r.path(DA(v,C,y,x,10),{roughness:.7,fill:s,fillStyle:"solid",stroke:l,seed:i}):r.rectangle(v,C,y,x,{seed:i});k=c.insert(()=>n,":first-child");const u=r.rectangle(v,w,y,b,{fill:e?o:a,fillStyle:e?"hachure":"solid",stroke:l,seed:i});k=c.insert(()=>n,":first-child"),d=c.insert(()=>u)}else{k=u.insert("rect",":first-child");const e="outer";k.attr("class",e).attr("x",v).attr("y",C).attr("width",y).attr("height",x).attr("data-look",t.look),d.attr("class","inner").attr("x",v).attr("y",w).attr("width",y).attr("height",b)}h.attr("transform",`translate(${t.x-f.width/2}, ${C+1-(ip(r.flowchart.htmlLabels)?0:3)})`);const S=k.node().getBBox();return t.height=S.height,t.offsetX=0,t.offsetY=f.height-t.padding/2,t.labelBBox=f,t.intersect=function(e){return BA(t,e)},{cluster:c,labelBBox:f}},"roundedWithTitle"),$A=mu(async(e,t)=>{bu.info("Creating subgraph rect for ",t.id,t);const r=$p(),{themeVariables:n,handDrawnSeed:i}=r,{clusterBkg:o,clusterBorder:a}=n,{labelStyles:s,nodeStyles:l,borderStyles:c,backgroundStyles:u}=AC(t),h=e.insert("g").attr("class","cluster "+t.cssClasses).attr("id",t.id).attr("data-look",t.look),d=ip(r.flowchart.htmlLabels),p=h.insert("g").attr("class","cluster-label "),f=await ST(p,t.label,{style:t.labelStyle,useHtmlLabels:d,isNode:!0,width:t.width});let g=f.getBBox();if(ip(r.flowchart.htmlLabels)){const e=f.children[0],t=fg(f);g=e.getBoundingClientRect(),t.attr("width",g.width),t.attr("height",g.height)}const m=t.width<=g.width+t.padding?g.width+t.padding:t.width;t.width<=g.width+t.padding?t.diff=(m-t.width)/2-t.padding:t.diff=-t.padding;const y=t.height,x=t.x-m/2,b=t.y-y/2;let v;if(bu.trace("Data ",t,JSON.stringify(t)),"handDrawn"===t.look){const e=SA(h),r=PC(t,{roughness:.7,fill:o,stroke:a,fillWeight:4,seed:i}),n=e.path(DA(x,b,m,y,t.rx),r);v=h.insert(()=>(bu.debug("Rough node insert CXC",n),n),":first-child"),v.select("path:nth-child(2)").attr("style",c.join(";")),v.select("path").attr("style",u.join(";").replace("fill","stroke"))}else v=h.insert("rect",":first-child"),v.attr("style",l).attr("rx",t.rx).attr("ry",t.ry).attr("x",x).attr("y",b).attr("width",m).attr("height",y);const{subGraphTitleTopMargin:C}=wC(r);if(p.attr("transform",`translate(${t.x-g.width/2}, ${t.y-t.height/2+C})`),s){const e=p.select("span");e&&e.attr("style",s)}const w=v.node().getBBox();return t.offsetX=0,t.width=w.width,t.height=w.height,t.offsetY=g.height-t.padding/2,t.intersect=function(e){return BA(t,e)},{cluster:h,labelBBox:g}},"kanbanSection"),zA={rect:OA,squareRect:OA,roundedWithTitle:RA,noteGroup:FA,divider:mu((e,t)=>{const r=$p(),{themeVariables:n,handDrawnSeed:i}=r,{nodeBorder:o}=n,a=e.insert("g").attr("class",t.cssClasses).attr("id",t.id).attr("data-look",t.look),s=a.insert("g",":first-child"),l=0*t.padding,c=t.width+l;t.diff=-t.padding;const u=t.height+l,h=t.x-c/2,d=t.y-u/2;let p;if(t.width=c,"handDrawn"===t.look){const e=SA(a).rectangle(h,d,c,u,{fill:"lightgrey",roughness:.5,strokeLineDash:[5],stroke:o,seed:i});p=a.insert(()=>e,":first-child")}else{p=s.insert("rect",":first-child");const e="divider";p.attr("class",e).attr("x",h).attr("y",d).attr("width",c).attr("height",u).attr("data-look",t.look)}const f=p.node().getBBox();return t.height=f.height,t.offsetX=0,t.offsetY=0,t.intersect=function(e){return BA(t,e)},{cluster:a,labelBBox:{}}},"divider"),kanbanSection:$A},VA=new Map,WA=mu(async(e,t)=>{const r=t.shape||"rect",n=await zA[r](e,t);return VA.set(t.id,n),n},"insertCluster"),HA=mu(()=>{VA=new Map},"clear");function qA(e,t){return e.intersect(t)}mu(qA,"intersectNode");var UA=qA;function GA(e,t,r,n){var i=e.x,o=e.y,a=i-n.x,s=o-n.y,l=Math.sqrt(t*t*s*s+r*r*a*a),c=Math.abs(t*r*a/l);n.x<i&&(c=-c);var u=Math.abs(t*r*s/l);return n.y<o&&(u=-u),{x:i+c,y:o+u}}mu(GA,"intersectEllipse");var XA=GA;function JA(e,t,r){return XA(e,t,t,r)}mu(JA,"intersectCircle");var YA=JA;function ZA(e,t,r,n){{const i=t.y-e.y,o=e.x-t.x,a=t.x*e.y-e.x*t.y,s=i*r.x+o*r.y+a,l=i*n.x+o*n.y+a,c=1e-6;if(0!==s&&0!==l&&KA(s,l))return;const u=n.y-r.y,h=r.x-n.x,d=n.x*r.y-r.x*n.y,p=u*e.x+h*e.y+d,f=u*t.x+h*t.y+d;if(Math.abs(p)<c&&Math.abs(f)<c&&KA(p,f))return;const g=i*h-u*o;if(0===g)return;const m=Math.abs(g/2);let y=o*d-h*a;const x=y<0?(y-m)/g:(y+m)/g;y=u*a-i*d;return{x:x,y:y<0?(y-m)/g:(y+m)/g}}}function KA(e,t){return e*t>0}mu(ZA,"intersectLine"),mu(KA,"sameSign");var QA=ZA;function eP(e,t,r){let n=e.x,i=e.y,o=[],a=Number.POSITIVE_INFINITY,s=Number.POSITIVE_INFINITY;"function"==typeof t.forEach?t.forEach(function(e){a=Math.min(a,e.x),s=Math.min(s,e.y)}):(a=Math.min(a,t.x),s=Math.min(s,t.y));let l=n-e.width/2-a,c=i-e.height/2-s;for(let u=0;u<t.length;u++){let n=t[u],i=t[u<t.length-1?u+1:0],a=QA(e,r,{x:l+n.x,y:c+n.y},{x:l+i.x,y:c+i.y});a&&o.push(a)}return o.length?(o.length>1&&o.sort(function(e,t){let n=e.x-r.x,i=e.y-r.y,o=Math.sqrt(n*n+i*i),a=t.x-r.x,s=t.y-r.y,l=Math.sqrt(a*a+s*s);return o<l?-1:o===l?0:1}),o[0]):e}mu(eP,"intersectPolygon");var tP={node:UA,circle:YA,ellipse:XA,polygon:eP,rect:BA};function rP(e,t){const{labelStyles:r}=AC(t);t.labelStyle=r;const n=PA(t);let i=n;n||(i="anchor");const o=e.insert("g").attr("class",i).attr("id",t.domId||t.id),{cssStyles:a}=t,s=SA(o),l=PC(t,{fill:"black",stroke:"none",fillStyle:"solid"});"handDrawn"!==t.look&&(l.roughness=0);const c=s.circle(0,0,2,l),u=o.insert(()=>c,":first-child");return u.attr("class","anchor").attr("style",wS(a)),AA(t,u),t.intersect=function(e){return bu.info("Circle intersect",t,1,e),tP.circle(t,1,e)},o}function nP(e,t,r,n,i,o,a){const s=(e+r)/2,l=(t+n)/2,c=Math.atan2(n-t,r-e),u=(r-e)/2/i,h=(n-t)/2/o,d=Math.sqrt(u**2+h**2);if(d>1)throw new Error("The given radii are too small to create an arc between the points.");const p=Math.sqrt(1-d**2),f=s+p*o*Math.sin(c)*(a?-1:1),g=l-p*i*Math.cos(c)*(a?-1:1),m=Math.atan2((t-g)/o,(e-f)/i);let y=Math.atan2((n-g)/o,(r-f)/i)-m;a&&y<0&&(y+=2*Math.PI),!a&&y>0&&(y-=2*Math.PI);const x=[];for(let b=0;b<20;b++){const e=m+b/19*y,t=f+i*Math.cos(e),r=g+o*Math.sin(e);x.push({x:t,y:r})}return x}async function iP(e,t){const{labelStyles:r,nodeStyles:n}=AC(t);t.labelStyle=r;const{shapeSvg:i,bbox:o}=await _A(e,t,PA(t)),a=o.width+t.padding+20,s=o.height+t.padding,l=s/2,c=l/(2.5+s/50),{cssStyles:u}=t,h=[{x:a/2,y:-s/2},{x:-a/2,y:-s/2},...nP(-a/2,-s/2,-a/2,s/2,c,l,!1),{x:a/2,y:s/2},...nP(a/2,s/2,a/2,-s/2,c,l,!0)],d=SA(i),p=PC(t,{});"handDrawn"!==t.look&&(p.roughness=0,p.fillStyle="solid");const f=EA(h),g=d.path(f,p),m=i.insert(()=>g,":first-child");return m.attr("class","basic label-container"),u&&"handDrawn"!==t.look&&m.selectAll("path").attr("style",u),n&&"handDrawn"!==t.look&&m.selectAll("path").attr("style",n),m.attr("transform",`translate(${c/2}, 0)`),AA(t,m),t.intersect=function(e){return tP.polygon(t,h,e)},i}function oP(e,t,r,n){return e.insert("polygon",":first-child").attr("points",n.map(function(e){return e.x+","+e.y}).join(" ")).attr("class","label-container").attr("transform","translate("+-t/2+","+r/2+")")}async function aP(e,t){const{labelStyles:r,nodeStyles:n}=AC(t);t.labelStyle=r;const{shapeSvg:i,bbox:o}=await _A(e,t,PA(t)),a=o.height+t.padding,s=o.width+t.padding+12,l=-a,c=[{x:12,y:l},{x:s,y:l},{x:s,y:0},{x:0,y:0},{x:0,y:l+12},{x:12,y:l}];let u;const{cssStyles:h}=t;if("handDrawn"===t.look){const e=SA(i),r=PC(t,{}),n=EA(c),o=e.path(n,r);u=i.insert(()=>o,":first-child").attr("transform",`translate(${-s/2}, ${a/2})`),h&&u.attr("style",h)}else u=oP(i,s,a,c);return n&&u.attr("style",n),AA(t,u),t.intersect=function(e){return tP.polygon(t,c,e)},i}function sP(e,t){const{nodeStyles:r}=AC(t);t.label="";const n=e.insert("g").attr("class",PA(t)).attr("id",t.domId??t.id),{cssStyles:i}=t,o=Math.max(28,t.width??0),a=[{x:0,y:o/2},{x:o/2,y:0},{x:0,y:-o/2},{x:-o/2,y:0}],s=SA(n),l=PC(t,{});"handDrawn"!==t.look&&(l.roughness=0,l.fillStyle="solid");const c=EA(a),u=s.path(c,l),h=n.insert(()=>u,":first-child");return i&&"handDrawn"!==t.look&&h.selectAll("path").attr("style",i),r&&"handDrawn"!==t.look&&h.selectAll("path").attr("style",r),t.width=28,t.height=28,t.intersect=function(e){return tP.polygon(t,a,e)},n}async function lP(e,t,r){const{labelStyles:n,nodeStyles:i}=AC(t);t.labelStyle=n;const{shapeSvg:o,bbox:a,halfPadding:s}=await _A(e,t,PA(t)),l=(null==r?void 0:r.padding)??s,c=a.width/2+l;let u;const{cssStyles:h}=t;if("handDrawn"===t.look){const e=SA(o),r=PC(t,{}),n=e.circle(0,0,2*c,r);u=o.insert(()=>n,":first-child"),u.attr("class","basic label-container").attr("style",wS(h))}else u=o.insert("circle",":first-child").attr("class","basic label-container").attr("style",i).attr("r",c).attr("cx",0).attr("cy",0);return AA(t,u),t.calcIntersect=function(e,t){const r=e.width/2;return tP.circle(e,r,t)},t.intersect=function(e){return bu.info("Circle intersect",t,c,e),tP.circle(t,c,e)},o}function cP(e){const t=Math.cos(Math.PI/4),r=Math.sin(Math.PI/4),n=2*e;return`M ${-n/2*t},${n/2*r} L ${n/2*t},${-n/2*r}\n M ${n/2*t},${n/2*r} L ${-n/2*t},${-n/2*r}`}function uP(e,t){const{labelStyles:r,nodeStyles:n}=AC(t);t.labelStyle=r,t.label="";const i=e.insert("g").attr("class",PA(t)).attr("id",t.domId??t.id),o=Math.max(30,(null==t?void 0:t.width)??0),{cssStyles:a}=t,s=SA(i),l=PC(t,{});"handDrawn"!==t.look&&(l.roughness=0,l.fillStyle="solid");const c=s.circle(0,0,2*o,l),u=cP(o),h=s.path(u,l),d=i.insert(()=>c,":first-child");return d.insert(()=>h),a&&"handDrawn"!==t.look&&d.selectAll("path").attr("style",a),n&&"handDrawn"!==t.look&&d.selectAll("path").attr("style",n),AA(t,d),t.intersect=function(e){bu.info("crossedCircle intersect",t,{radius:o,point:e});return tP.circle(t,o,e)},i}function hP(e,t,r,n=100,i=0,o=180){const a=[],s=i*Math.PI/180,l=(o*Math.PI/180-s)/(n-1);for(let c=0;c<n;c++){const n=s+c*l,i=e+r*Math.cos(n),o=t+r*Math.sin(n);a.push({x:-i,y:-o})}return a}async function dP(e,t){const{labelStyles:r,nodeStyles:n}=AC(t);t.labelStyle=r;const{shapeSvg:i,bbox:o,label:a}=await _A(e,t,PA(t)),s=o.width+(t.padding??0),l=o.height+(t.padding??0),c=Math.max(5,.1*l),{cssStyles:u}=t,h=[...hP(s/2,-l/2,c,30,-90,0),{x:-s/2-c,y:c},...hP(s/2+2*c,-c,c,20,-180,-270),...hP(s/2+2*c,c,c,20,-90,-180),{x:-s/2-c,y:-l/2},...hP(s/2,l/2,c,20,0,90)],d=[{x:s/2,y:-l/2-c},{x:-s/2,y:-l/2-c},...hP(s/2,-l/2,c,20,-90,0),{x:-s/2-c,y:-c},...hP(s/2+.1*s,-c,c,20,-180,-270),...hP(s/2+.1*s,c,c,20,-90,-180),{x:-s/2-c,y:l/2},...hP(s/2,l/2,c,20,0,90),{x:-s/2,y:l/2+c},{x:s/2,y:l/2+c}],p=SA(i),f=PC(t,{fill:"none"});"handDrawn"!==t.look&&(f.roughness=0,f.fillStyle="solid");const g=EA(h).replace("Z",""),m=p.path(g,f),y=EA(d),x=p.path(y,{...f}),b=i.insert("g",":first-child");return b.insert(()=>x,":first-child").attr("stroke-opacity",0),b.insert(()=>m,":first-child"),b.attr("class","text"),u&&"handDrawn"!==t.look&&b.selectAll("path").attr("style",u),n&&"handDrawn"!==t.look&&b.selectAll("path").attr("style",n),b.attr("transform",`translate(${c}, 0)`),a.attr("transform",`translate(${-s/2+c-(o.x-(o.left??0))},${-l/2+(t.padding??0)/2-(o.y-(o.top??0))})`),AA(t,b),t.intersect=function(e){return tP.polygon(t,d,e)},i}function pP(e,t,r,n=100,i=0,o=180){const a=[],s=i*Math.PI/180,l=(o*Math.PI/180-s)/(n-1);for(let c=0;c<n;c++){const n=s+c*l,i=e+r*Math.cos(n),o=t+r*Math.sin(n);a.push({x:i,y:o})}return a}async function fP(e,t){const{labelStyles:r,nodeStyles:n}=AC(t);t.labelStyle=r;const{shapeSvg:i,bbox:o,label:a}=await _A(e,t,PA(t)),s=o.width+(t.padding??0),l=o.height+(t.padding??0),c=Math.max(5,.1*l),{cssStyles:u}=t,h=[...pP(s/2,-l/2,c,20,-90,0),{x:s/2+c,y:-c},...pP(s/2+2*c,-c,c,20,-180,-270),...pP(s/2+2*c,c,c,20,-90,-180),{x:s/2+c,y:l/2},...pP(s/2,l/2,c,20,0,90)],d=[{x:-s/2,y:-l/2-c},{x:s/2,y:-l/2-c},...pP(s/2,-l/2,c,20,-90,0),{x:s/2+c,y:-c},...pP(s/2+2*c,-c,c,20,-180,-270),...pP(s/2+2*c,c,c,20,-90,-180),{x:s/2+c,y:l/2},...pP(s/2,l/2,c,20,0,90),{x:s/2,y:l/2+c},{x:-s/2,y:l/2+c}],p=SA(i),f=PC(t,{fill:"none"});"handDrawn"!==t.look&&(f.roughness=0,f.fillStyle="solid");const g=EA(h).replace("Z",""),m=p.path(g,f),y=EA(d),x=p.path(y,{...f}),b=i.insert("g",":first-child");return b.insert(()=>x,":first-child").attr("stroke-opacity",0),b.insert(()=>m,":first-child"),b.attr("class","text"),u&&"handDrawn"!==t.look&&b.selectAll("path").attr("style",u),n&&"handDrawn"!==t.look&&b.selectAll("path").attr("style",n),b.attr("transform",`translate(${-c}, 0)`),a.attr("transform",`translate(${-s/2+(t.padding??0)/2-(o.x-(o.left??0))},${-l/2+(t.padding??0)/2-(o.y-(o.top??0))})`),AA(t,b),t.intersect=function(e){return tP.polygon(t,d,e)},i}function gP(e,t,r,n=100,i=0,o=180){const a=[],s=i*Math.PI/180,l=(o*Math.PI/180-s)/(n-1);for(let c=0;c<n;c++){const n=s+c*l,i=e+r*Math.cos(n),o=t+r*Math.sin(n);a.push({x:-i,y:-o})}return a}async function mP(e,t){const{labelStyles:r,nodeStyles:n}=AC(t);t.labelStyle=r;const{shapeSvg:i,bbox:o,label:a}=await _A(e,t,PA(t)),s=o.width+(t.padding??0),l=o.height+(t.padding??0),c=Math.max(5,.1*l),{cssStyles:u}=t,h=[...gP(s/2,-l/2,c,30,-90,0),{x:-s/2-c,y:c},...gP(s/2+2*c,-c,c,20,-180,-270),...gP(s/2+2*c,c,c,20,-90,-180),{x:-s/2-c,y:-l/2},...gP(s/2,l/2,c,20,0,90)],d=[...gP(-s/2+c+c/2,-l/2,c,20,-90,-180),{x:s/2-c/2,y:c},...gP(-s/2-c/2,-c,c,20,0,90),...gP(-s/2-c/2,c,c,20,-90,0),{x:s/2-c/2,y:-c},...gP(-s/2+c+c/2,l/2,c,30,-180,-270)],p=[{x:s/2,y:-l/2-c},{x:-s/2,y:-l/2-c},...gP(s/2,-l/2,c,20,-90,0),{x:-s/2-c,y:-c},...gP(s/2+2*c,-c,c,20,-180,-270),...gP(s/2+2*c,c,c,20,-90,-180),{x:-s/2-c,y:l/2},...gP(s/2,l/2,c,20,0,90),{x:-s/2,y:l/2+c},{x:s/2-c-c/2,y:l/2+c},...gP(-s/2+c+c/2,-l/2,c,20,-90,-180),{x:s/2-c/2,y:c},...gP(-s/2-c/2,-c,c,20,0,90),...gP(-s/2-c/2,c,c,20,-90,0),{x:s/2-c/2,y:-c},...gP(-s/2+c+c/2,l/2,c,30,-180,-270)],f=SA(i),g=PC(t,{fill:"none"});"handDrawn"!==t.look&&(g.roughness=0,g.fillStyle="solid");const m=EA(h).replace("Z",""),y=f.path(m,g),x=EA(d).replace("Z",""),b=f.path(x,g),v=EA(p),C=f.path(v,{...g}),w=i.insert("g",":first-child");return w.insert(()=>C,":first-child").attr("stroke-opacity",0),w.insert(()=>y,":first-child"),w.insert(()=>b,":first-child"),w.attr("class","text"),u&&"handDrawn"!==t.look&&w.selectAll("path").attr("style",u),n&&"handDrawn"!==t.look&&w.selectAll("path").attr("style",n),w.attr("transform",`translate(${c-c/4}, 0)`),a.attr("transform",`translate(${-s/2+(t.padding??0)/2-(o.x-(o.left??0))},${-l/2+(t.padding??0)/2-(o.y-(o.top??0))})`),AA(t,w),t.intersect=function(e){return tP.polygon(t,p,e)},i}async function yP(e,t){const{labelStyles:r,nodeStyles:n}=AC(t);t.labelStyle=r;const{shapeSvg:i,bbox:o}=await _A(e,t,PA(t)),a=Math.max(80,1.25*(o.width+2*(t.padding??0)),(null==t?void 0:t.width)??0),s=Math.max(20,o.height+2*(t.padding??0),(null==t?void 0:t.height)??0),l=s/2,{cssStyles:c}=t,u=SA(i),h=PC(t,{});"handDrawn"!==t.look&&(h.roughness=0,h.fillStyle="solid");const d=a-l,p=s/4,f=[{x:d,y:0},{x:p,y:0},{x:0,y:s/2},{x:p,y:s},{x:d,y:s},...IA(-d,-s/2,l,50,270,90)],g=EA(f),m=u.path(g,h),y=i.insert(()=>m,":first-child");return y.attr("class","basic label-container"),c&&"handDrawn"!==t.look&&y.selectChildren("path").attr("style",c),n&&"handDrawn"!==t.look&&y.selectChildren("path").attr("style",n),y.attr("transform",`translate(${-a/2}, ${-s/2})`),AA(t,y),t.intersect=function(e){return tP.polygon(t,f,e)},i}mu(rP,"anchor"),mu(nP,"generateArcPoints"),mu(iP,"bowTieRect"),mu(oP,"insertPolygonShape"),mu(aP,"card"),mu(sP,"choice"),mu(lP,"circle"),mu(cP,"createLine"),mu(uP,"crossedCircle"),mu(hP,"generateCirclePoints"),mu(dP,"curlyBraceLeft"),mu(pP,"generateCirclePoints"),mu(fP,"curlyBraceRight"),mu(gP,"generateCirclePoints"),mu(mP,"curlyBraces"),mu(yP,"curvedTrapezoid");var xP=mu((e,t,r,n,i,o)=>[`M${e},${t+o}`,`a${i},${o} 0,0,0 ${r},0`,`a${i},${o} 0,0,0 ${-r},0`,`l0,${n}`,`a${i},${o} 0,0,0 ${r},0`,"l0,"+-n].join(" "),"createCylinderPathD"),bP=mu((e,t,r,n,i,o)=>[`M${e},${t+o}`,`M${e+r},${t+o}`,`a${i},${o} 0,0,0 ${-r},0`,`l0,${n}`,`a${i},${o} 0,0,0 ${r},0`,"l0,"+-n].join(" "),"createOuterCylinderPathD"),vP=mu((e,t,r,n,i,o)=>[`M${e-r/2},${-n/2}`,`a${i},${o} 0,0,0 ${r},0`].join(" "),"createInnerCylinderPathD");async function CP(e,t){const{labelStyles:r,nodeStyles:n}=AC(t);t.labelStyle=r;const{shapeSvg:i,bbox:o,label:a}=await _A(e,t,PA(t)),s=Math.max(o.width+t.padding,t.width??0),l=s/2,c=l/(2.5+s/50),u=Math.max(o.height+c+t.padding,t.height??0);let h;const{cssStyles:d}=t;if("handDrawn"===t.look){const e=SA(i),r=bP(0,0,s,u,l,c),n=vP(0,c,s,u,l,c),o=e.path(r,PC(t,{})),a=e.path(n,PC(t,{fill:"none"}));h=i.insert(()=>a,":first-child"),h=i.insert(()=>o,":first-child"),h.attr("class","basic label-container"),d&&h.attr("style",d)}else{const e=xP(0,0,s,u,l,c);h=i.insert("path",":first-child").attr("d",e).attr("class","basic label-container").attr("style",wS(d)).attr("style",n)}return h.attr("label-offset-y",c),h.attr("transform",`translate(${-s/2}, ${-(u/2+c)})`),AA(t,h),a.attr("transform",`translate(${-o.width/2-(o.x-(o.left??0))}, ${-o.height/2+(t.padding??0)/1.5-(o.y-(o.top??0))})`),t.intersect=function(e){const r=tP.rect(t,e),n=r.x-(t.x??0);if(0!=l&&(Math.abs(n)<(t.width??0)/2||Math.abs(n)==(t.width??0)/2&&Math.abs(r.y-(t.y??0))>(t.height??0)/2-c)){let i=c*c*(1-n*n/(l*l));i>0&&(i=Math.sqrt(i)),i=c-i,e.y-(t.y??0)>0&&(i=-i),r.y+=i}return r},i}async function wP(e,t){const{labelStyles:r,nodeStyles:n}=AC(t);t.labelStyle=r;const{shapeSvg:i,bbox:o,label:a}=await _A(e,t,PA(t)),s=o.width+t.padding,l=o.height+t.padding,c=.2*l,u=-s/2,h=-l/2-c/2,{cssStyles:d}=t,p=SA(i),f=PC(t,{});"handDrawn"!==t.look&&(f.roughness=0,f.fillStyle="solid");const g=[{x:u,y:h+c},{x:-u,y:h+c},{x:-u,y:-h},{x:u,y:-h},{x:u,y:h},{x:-u,y:h},{x:-u,y:h+c}],m=p.polygon(g.map(e=>[e.x,e.y]),f),y=i.insert(()=>m,":first-child");return y.attr("class","basic label-container"),d&&"handDrawn"!==t.look&&y.selectAll("path").attr("style",d),n&&"handDrawn"!==t.look&&y.selectAll("path").attr("style",n),a.attr("transform",`translate(${u+(t.padding??0)/2-(o.x-(o.left??0))}, ${h+c+(t.padding??0)/2-(o.y-(o.top??0))})`),AA(t,y),t.intersect=function(e){return tP.rect(t,e)},i}async function kP(e,t){var r,n;const{labelStyles:i,nodeStyles:o}=AC(t);t.labelStyle=i;const{shapeSvg:a,bbox:s,halfPadding:l}=await _A(e,t,PA(t)),c=s.width/2+l+5,u=s.width/2+l;let h;const{cssStyles:d}=t;if("handDrawn"===t.look){const e=SA(a),i=PC(t,{roughness:.2,strokeWidth:2.5}),o=PC(t,{roughness:.2,strokeWidth:1.5}),s=e.circle(0,0,2*c,i),l=e.circle(0,0,2*u,o);h=a.insert("g",":first-child"),h.attr("class",wS(t.cssClasses)).attr("style",wS(d)),null==(r=h.node())||r.appendChild(s),null==(n=h.node())||n.appendChild(l)}else{h=a.insert("g",":first-child");const e=h.insert("circle",":first-child"),t=h.insert("circle");h.attr("class","basic label-container").attr("style",o),e.attr("class","outer-circle").attr("style",o).attr("r",c).attr("cx",0).attr("cy",0),t.attr("class","inner-circle").attr("style",o).attr("r",u).attr("cx",0).attr("cy",0)}return AA(t,h),t.intersect=function(e){return bu.info("DoubleCircle intersect",t,c,e),tP.circle(t,c,e)},a}function SP(e,t,{config:{themeVariables:r}}){const{labelStyles:n,nodeStyles:i}=AC(t);t.label="",t.labelStyle=n;const o=e.insert("g").attr("class",PA(t)).attr("id",t.domId??t.id),{cssStyles:a}=t,s=SA(o),{nodeBorder:l}=r,c=PC(t,{fillStyle:"solid"});"handDrawn"!==t.look&&(c.roughness=0);const u=s.circle(0,0,14,c),h=o.insert(()=>u,":first-child");return h.selectAll("path").attr("style",`fill: ${l} !important;`),a&&a.length>0&&"handDrawn"!==t.look&&h.selectAll("path").attr("style",a),i&&"handDrawn"!==t.look&&h.selectAll("path").attr("style",i),AA(t,h),t.intersect=function(e){bu.info("filledCircle intersect",t,{radius:7,point:e});return tP.circle(t,7,e)},o}async function _P(e,t){const{labelStyles:r,nodeStyles:n}=AC(t);t.labelStyle=r;const{shapeSvg:i,bbox:o,label:a}=await _A(e,t,PA(t)),s=o.width+(t.padding??0),l=s+o.height,c=s+o.height,u=[{x:0,y:-l},{x:c,y:-l},{x:c/2,y:0}],{cssStyles:h}=t,d=SA(i),p=PC(t,{});"handDrawn"!==t.look&&(p.roughness=0,p.fillStyle="solid");const f=EA(u),g=d.path(f,p),m=i.insert(()=>g,":first-child").attr("transform",`translate(${-l/2}, ${l/2})`);return h&&"handDrawn"!==t.look&&m.selectChildren("path").attr("style",h),n&&"handDrawn"!==t.look&&m.selectChildren("path").attr("style",n),t.width=s,t.height=l,AA(t,m),a.attr("transform",`translate(${-o.width/2-(o.x-(o.left??0))}, ${-l/2+(t.padding??0)/2+(o.y-(o.top??0))})`),t.intersect=function(e){return bu.info("Triangle intersect",t,u,e),tP.polygon(t,u,e)},i}function TP(e,t,{dir:r,config:{state:n,themeVariables:i}}){const{nodeStyles:o}=AC(t);t.label="";const a=e.insert("g").attr("class",PA(t)).attr("id",t.domId??t.id),{cssStyles:s}=t;let l=Math.max(70,(null==t?void 0:t.width)??0),c=Math.max(10,(null==t?void 0:t.height)??0);"LR"===r&&(l=Math.max(10,(null==t?void 0:t.width)??0),c=Math.max(70,(null==t?void 0:t.height)??0));const u=-1*l/2,h=-1*c/2,d=SA(a),p=PC(t,{stroke:i.lineColor,fill:i.lineColor});"handDrawn"!==t.look&&(p.roughness=0,p.fillStyle="solid");const f=d.rectangle(u,h,l,c,p),g=a.insert(()=>f,":first-child");s&&"handDrawn"!==t.look&&g.selectAll("path").attr("style",s),o&&"handDrawn"!==t.look&&g.selectAll("path").attr("style",o),AA(t,g);const m=(null==n?void 0:n.padding)??0;return t.width&&t.height&&(t.width+=m/2||0,t.height+=m/2||0),t.intersect=function(e){return tP.rect(t,e)},a}async function AP(e,t){const{labelStyles:r,nodeStyles:n}=AC(t);t.labelStyle=r;const{shapeSvg:i,bbox:o}=await _A(e,t,PA(t)),a=Math.max(80,o.width+2*(t.padding??0),(null==t?void 0:t.width)??0),s=Math.max(50,o.height+2*(t.padding??0),(null==t?void 0:t.height)??0),l=s/2,{cssStyles:c}=t,u=SA(i),h=PC(t,{});"handDrawn"!==t.look&&(h.roughness=0,h.fillStyle="solid");const d=[{x:-a/2,y:-s/2},{x:a/2-l,y:-s/2},...IA(-a/2+l,0,l,50,90,270),{x:a/2-l,y:s/2},{x:-a/2,y:s/2}],p=EA(d),f=u.path(p,h),g=i.insert(()=>f,":first-child");return g.attr("class","basic label-container"),c&&"handDrawn"!==t.look&&g.selectChildren("path").attr("style",c),n&&"handDrawn"!==t.look&&g.selectChildren("path").attr("style",n),AA(t,g),t.intersect=function(e){bu.info("Pill intersect",t,{radius:l,point:e});return tP.polygon(t,d,e)},i}async function PP(e,t){const{labelStyles:r,nodeStyles:n}=AC(t);t.labelStyle=r;const{shapeSvg:i,bbox:o}=await _A(e,t,PA(t)),a=o.height+(t.padding??0),s=o.width+2.5*(t.padding??0),{cssStyles:l}=t,c=SA(i),u=PC(t,{});"handDrawn"!==t.look&&(u.roughness=0,u.fillStyle="solid");let h=s/2;h+=h/6;const d=a/2,p=h-d/2,f=[{x:-p,y:-d},{x:0,y:-d},{x:p,y:-d},{x:h,y:0},{x:p,y:d},{x:0,y:d},{x:-p,y:d},{x:-h,y:0}],g=EA(f),m=c.path(g,u),y=i.insert(()=>m,":first-child");return y.attr("class","basic label-container"),l&&"handDrawn"!==t.look&&y.selectChildren("path").attr("style",l),n&&"handDrawn"!==t.look&&y.selectChildren("path").attr("style",n),t.width=s,t.height=a,AA(t,y),t.intersect=function(e){return tP.polygon(t,f,e)},i}async function EP(e,t){const{labelStyles:r,nodeStyles:n}=AC(t);t.label="",t.labelStyle=r;const{shapeSvg:i}=await _A(e,t,PA(t)),o=Math.max(30,(null==t?void 0:t.width)??0),a=Math.max(30,(null==t?void 0:t.height)??0),{cssStyles:s}=t,l=SA(i),c=PC(t,{});"handDrawn"!==t.look&&(c.roughness=0,c.fillStyle="solid");const u=[{x:0,y:0},{x:o,y:0},{x:0,y:a},{x:o,y:a}],h=EA(u),d=l.path(h,c),p=i.insert(()=>d,":first-child");return p.attr("class","basic label-container"),s&&"handDrawn"!==t.look&&p.selectChildren("path").attr("style",s),n&&"handDrawn"!==t.look&&p.selectChildren("path").attr("style",n),p.attr("transform",`translate(${-o/2}, ${-a/2})`),AA(t,p),t.intersect=function(e){bu.info("Pill intersect",t,{points:u});return tP.polygon(t,u,e)},i}async function MP(e,t,{config:{themeVariables:r,flowchart:n}}){const{labelStyles:i}=AC(t);t.labelStyle=i;const o=t.assetHeight??48,a=t.assetWidth??48,s=Math.max(o,a),l=null==n?void 0:n.wrappingWidth;t.width=Math.max(s,l??0);const{shapeSvg:c,bbox:u,label:h}=await _A(e,t,"icon-shape default"),d="t"===t.pos,p=s,f=s,{nodeBorder:g}=r,{stylesMap:m}=SC(t),y=-f/2,x=-p/2,b=t.label?8:0,v=SA(c),C=PC(t,{stroke:"none",fill:"none"});"handDrawn"!==t.look&&(C.roughness=0,C.fillStyle="solid");const w=v.rectangle(y,x,f,p,C),k=Math.max(f,u.width),S=p+u.height+b,_=v.rectangle(-k/2,-S/2,k,S,{...C,fill:"transparent",stroke:"none"}),T=c.insert(()=>w,":first-child"),A=c.insert(()=>_);if(t.icon){const e=c.append("g");e.html(`<g>${await sT(t.icon,{height:s,width:s,fallbackPrefix:""})}</g>`);const r=e.node().getBBox(),n=r.width,i=r.height,o=r.x,a=r.y;e.attr("transform",`translate(${-n/2-o},${d?u.height/2+b/2-i/2-a:-u.height/2-b/2-i/2-a})`),e.attr("style",`color: ${m.get("stroke")??g};`)}return h.attr("transform",`translate(${-u.width/2-(u.x-(u.left??0))},${d?-S/2:S/2-u.height})`),T.attr("transform",`translate(0,${d?u.height/2+b/2:-u.height/2-b/2})`),AA(t,A),t.intersect=function(e){if(bu.info("iconSquare intersect",t,e),!t.label)return tP.rect(t,e);const r=t.x??0,n=t.y??0,i=t.height??0;let o=[];o=d?[{x:r-u.width/2,y:n-i/2},{x:r+u.width/2,y:n-i/2},{x:r+u.width/2,y:n-i/2+u.height+b},{x:r+f/2,y:n-i/2+u.height+b},{x:r+f/2,y:n+i/2},{x:r-f/2,y:n+i/2},{x:r-f/2,y:n-i/2+u.height+b},{x:r-u.width/2,y:n-i/2+u.height+b}]:[{x:r-f/2,y:n-i/2},{x:r+f/2,y:n-i/2},{x:r+f/2,y:n-i/2+p},{x:r+u.width/2,y:n-i/2+p},{x:r+u.width/2/2,y:n+i/2},{x:r-u.width/2,y:n+i/2},{x:r-u.width/2,y:n-i/2+p},{x:r-f/2,y:n-i/2+p}];return tP.polygon(t,o,e)},c}async function IP(e,t,{config:{themeVariables:r,flowchart:n}}){const{labelStyles:i}=AC(t);t.labelStyle=i;const o=t.assetHeight??48,a=t.assetWidth??48,s=Math.max(o,a),l=null==n?void 0:n.wrappingWidth;t.width=Math.max(s,l??0);const{shapeSvg:c,bbox:u,label:h}=await _A(e,t,"icon-shape default"),d=t.label?8:0,p="t"===t.pos,{nodeBorder:f,mainBkg:g}=r,{stylesMap:m}=SC(t),y=SA(c),x=PC(t,{});"handDrawn"!==t.look&&(x.roughness=0,x.fillStyle="solid");const b=m.get("fill");x.stroke=b??g;const v=c.append("g");t.icon&&v.html(`<g>${await sT(t.icon,{height:s,width:s,fallbackPrefix:""})}</g>`);const C=v.node().getBBox(),w=C.width,k=C.height,S=C.x,_=C.y,T=Math.max(w,k)*Math.SQRT2+40,A=y.circle(0,0,T,x),P=Math.max(T,u.width),E=T+u.height+d,M=y.rectangle(-P/2,-E/2,P,E,{...x,fill:"transparent",stroke:"none"}),I=c.insert(()=>A,":first-child"),B=c.insert(()=>M);return v.attr("transform",`translate(${-w/2-S},${p?u.height/2+d/2-k/2-_:-u.height/2-d/2-k/2-_})`),v.attr("style",`color: ${m.get("stroke")??f};`),h.attr("transform",`translate(${-u.width/2-(u.x-(u.left??0))},${p?-E/2:E/2-u.height})`),I.attr("transform",`translate(0,${p?u.height/2+d/2:-u.height/2-d/2})`),AA(t,B),t.intersect=function(e){bu.info("iconSquare intersect",t,e);return tP.rect(t,e)},c}async function BP(e,t,{config:{themeVariables:r,flowchart:n}}){const{labelStyles:i}=AC(t);t.labelStyle=i;const o=t.assetHeight??48,a=t.assetWidth??48,s=Math.max(o,a),l=null==n?void 0:n.wrappingWidth;t.width=Math.max(s,l??0);const{shapeSvg:c,bbox:u,halfPadding:h,label:d}=await _A(e,t,"icon-shape default"),p="t"===t.pos,f=s+2*h,g=s+2*h,{nodeBorder:m,mainBkg:y}=r,{stylesMap:x}=SC(t),b=-g/2,v=-f/2,C=t.label?8:0,w=SA(c),k=PC(t,{});"handDrawn"!==t.look&&(k.roughness=0,k.fillStyle="solid");const S=x.get("fill");k.stroke=S??y;const _=w.path(DA(b,v,g,f,5),k),T=Math.max(g,u.width),A=f+u.height+C,P=w.rectangle(-T/2,-A/2,T,A,{...k,fill:"transparent",stroke:"none"}),E=c.insert(()=>_,":first-child").attr("class","icon-shape2"),M=c.insert(()=>P);if(t.icon){const e=c.append("g");e.html(`<g>${await sT(t.icon,{height:s,width:s,fallbackPrefix:""})}</g>`);const r=e.node().getBBox(),n=r.width,i=r.height,o=r.x,a=r.y;e.attr("transform",`translate(${-n/2-o},${p?u.height/2+C/2-i/2-a:-u.height/2-C/2-i/2-a})`),e.attr("style",`color: ${x.get("stroke")??m};`)}return d.attr("transform",`translate(${-u.width/2-(u.x-(u.left??0))},${p?-A/2:A/2-u.height})`),E.attr("transform",`translate(0,${p?u.height/2+C/2:-u.height/2-C/2})`),AA(t,M),t.intersect=function(e){if(bu.info("iconSquare intersect",t,e),!t.label)return tP.rect(t,e);const r=t.x??0,n=t.y??0,i=t.height??0;let o=[];o=p?[{x:r-u.width/2,y:n-i/2},{x:r+u.width/2,y:n-i/2},{x:r+u.width/2,y:n-i/2+u.height+C},{x:r+g/2,y:n-i/2+u.height+C},{x:r+g/2,y:n+i/2},{x:r-g/2,y:n+i/2},{x:r-g/2,y:n-i/2+u.height+C},{x:r-u.width/2,y:n-i/2+u.height+C}]:[{x:r-g/2,y:n-i/2},{x:r+g/2,y:n-i/2},{x:r+g/2,y:n-i/2+f},{x:r+u.width/2,y:n-i/2+f},{x:r+u.width/2/2,y:n+i/2},{x:r-u.width/2,y:n+i/2},{x:r-u.width/2,y:n-i/2+f},{x:r-g/2,y:n-i/2+f}];return tP.polygon(t,o,e)},c}async function LP(e,t,{config:{themeVariables:r,flowchart:n}}){const{labelStyles:i}=AC(t);t.labelStyle=i;const o=t.assetHeight??48,a=t.assetWidth??48,s=Math.max(o,a),l=null==n?void 0:n.wrappingWidth;t.width=Math.max(s,l??0);const{shapeSvg:c,bbox:u,halfPadding:h,label:d}=await _A(e,t,"icon-shape default"),p="t"===t.pos,f=s+2*h,g=s+2*h,{nodeBorder:m,mainBkg:y}=r,{stylesMap:x}=SC(t),b=-g/2,v=-f/2,C=t.label?8:0,w=SA(c),k=PC(t,{});"handDrawn"!==t.look&&(k.roughness=0,k.fillStyle="solid");const S=x.get("fill");k.stroke=S??y;const _=w.path(DA(b,v,g,f,.1),k),T=Math.max(g,u.width),A=f+u.height+C,P=w.rectangle(-T/2,-A/2,T,A,{...k,fill:"transparent",stroke:"none"}),E=c.insert(()=>_,":first-child"),M=c.insert(()=>P);if(t.icon){const e=c.append("g");e.html(`<g>${await sT(t.icon,{height:s,width:s,fallbackPrefix:""})}</g>`);const r=e.node().getBBox(),n=r.width,i=r.height,o=r.x,a=r.y;e.attr("transform",`translate(${-n/2-o},${p?u.height/2+C/2-i/2-a:-u.height/2-C/2-i/2-a})`),e.attr("style",`color: ${x.get("stroke")??m};`)}return d.attr("transform",`translate(${-u.width/2-(u.x-(u.left??0))},${p?-A/2:A/2-u.height})`),E.attr("transform",`translate(0,${p?u.height/2+C/2:-u.height/2-C/2})`),AA(t,M),t.intersect=function(e){if(bu.info("iconSquare intersect",t,e),!t.label)return tP.rect(t,e);const r=t.x??0,n=t.y??0,i=t.height??0;let o=[];o=p?[{x:r-u.width/2,y:n-i/2},{x:r+u.width/2,y:n-i/2},{x:r+u.width/2,y:n-i/2+u.height+C},{x:r+g/2,y:n-i/2+u.height+C},{x:r+g/2,y:n+i/2},{x:r-g/2,y:n+i/2},{x:r-g/2,y:n-i/2+u.height+C},{x:r-u.width/2,y:n-i/2+u.height+C}]:[{x:r-g/2,y:n-i/2},{x:r+g/2,y:n-i/2},{x:r+g/2,y:n-i/2+f},{x:r+u.width/2,y:n-i/2+f},{x:r+u.width/2/2,y:n+i/2},{x:r-u.width/2,y:n+i/2},{x:r-u.width/2,y:n-i/2+f},{x:r-g/2,y:n-i/2+f}];return tP.polygon(t,o,e)},c}async function jP(e,t,{config:{flowchart:r}}){const n=new Image;n.src=(null==t?void 0:t.img)??"",await n.decode();const i=Number(n.naturalWidth.toString().replace("px","")),o=Number(n.naturalHeight.toString().replace("px",""));t.imageAspectRatio=i/o;const{labelStyles:a}=AC(t);t.labelStyle=a;const s=null==r?void 0:r.wrappingWidth;t.defaultWidth=null==r?void 0:r.wrappingWidth;const l=Math.max(t.label?s??0:0,(null==t?void 0:t.assetWidth)??i),c="on"===t.constraint&&(null==t?void 0:t.assetHeight)?t.assetHeight*t.imageAspectRatio:l,u="on"===t.constraint?c/t.imageAspectRatio:(null==t?void 0:t.assetHeight)??o;t.width=Math.max(c,s??0);const{shapeSvg:h,bbox:d,label:p}=await _A(e,t,"image-shape default"),f="t"===t.pos,g=-c/2,m=-u/2,y=t.label?8:0,x=SA(h),b=PC(t,{});"handDrawn"!==t.look&&(b.roughness=0,b.fillStyle="solid");const v=x.rectangle(g,m,c,u,b),C=Math.max(c,d.width),w=u+d.height+y,k=x.rectangle(-C/2,-w/2,C,w,{...b,fill:"none",stroke:"none"}),S=h.insert(()=>v,":first-child"),_=h.insert(()=>k);if(t.img){const e=h.append("image");e.attr("href",t.img),e.attr("width",c),e.attr("height",u),e.attr("preserveAspectRatio","none"),e.attr("transform",`translate(${-c/2},${f?w/2-u:-w/2})`)}return p.attr("transform",`translate(${-d.width/2-(d.x-(d.left??0))},${f?-u/2-d.height/2-y/2:u/2-d.height/2+y/2})`),S.attr("transform",`translate(0,${f?d.height/2+y/2:-d.height/2-y/2})`),AA(t,_),t.intersect=function(e){if(bu.info("iconSquare intersect",t,e),!t.label)return tP.rect(t,e);const r=t.x??0,n=t.y??0,i=t.height??0;let o=[];o=f?[{x:r-d.width/2,y:n-i/2},{x:r+d.width/2,y:n-i/2},{x:r+d.width/2,y:n-i/2+d.height+y},{x:r+c/2,y:n-i/2+d.height+y},{x:r+c/2,y:n+i/2},{x:r-c/2,y:n+i/2},{x:r-c/2,y:n-i/2+d.height+y},{x:r-d.width/2,y:n-i/2+d.height+y}]:[{x:r-c/2,y:n-i/2},{x:r+c/2,y:n-i/2},{x:r+c/2,y:n-i/2+u},{x:r+d.width/2,y:n-i/2+u},{x:r+d.width/2/2,y:n+i/2},{x:r-d.width/2,y:n+i/2},{x:r-d.width/2,y:n-i/2+u},{x:r-c/2,y:n-i/2+u}];return tP.polygon(t,o,e)},h}async function NP(e,t){const{labelStyles:r,nodeStyles:n}=AC(t);t.labelStyle=r;const{shapeSvg:i,bbox:o}=await _A(e,t,PA(t)),a=Math.max(o.width+2*(t.padding??0),(null==t?void 0:t.width)??0),s=Math.max(o.height+2*(t.padding??0),(null==t?void 0:t.height)??0),l=[{x:0,y:0},{x:a,y:0},{x:a+3*s/6,y:-s},{x:-3*s/6,y:-s}];let c;const{cssStyles:u}=t;if("handDrawn"===t.look){const e=SA(i),r=PC(t,{}),n=EA(l),o=e.path(n,r);c=i.insert(()=>o,":first-child").attr("transform",`translate(${-a/2}, ${s/2})`),u&&c.attr("style",u)}else c=oP(i,a,s,l);return n&&c.attr("style",n),t.width=a,t.height=s,AA(t,c),t.intersect=function(e){return tP.polygon(t,l,e)},i}async function DP(e,t,r){const{labelStyles:n,nodeStyles:i}=AC(t);t.labelStyle=n;const{shapeSvg:o,bbox:a}=await _A(e,t,PA(t)),s=Math.max(a.width+2*r.labelPaddingX,(null==t?void 0:t.width)||0),l=Math.max(a.height+2*r.labelPaddingY,(null==t?void 0:t.height)||0),c=-s/2,u=-l/2;let h,{rx:d,ry:p}=t;const{cssStyles:f}=t;if((null==r?void 0:r.rx)&&r.ry&&(d=r.rx,p=r.ry),"handDrawn"===t.look){const e=SA(o),r=PC(t,{}),n=d||p?e.path(DA(c,u,s,l,d||0),r):e.rectangle(c,u,s,l,r);h=o.insert(()=>n,":first-child"),h.attr("class","basic label-container").attr("style",wS(f))}else h=o.insert("rect",":first-child"),h.attr("class","basic label-container").attr("style",i).attr("rx",wS(d)).attr("ry",wS(p)).attr("x",c).attr("y",u).attr("width",s).attr("height",l);return AA(t,h),t.calcIntersect=function(e,t){return tP.rect(e,t)},t.intersect=function(e){return tP.rect(t,e)},o}async function OP(e,t){const{shapeSvg:r,bbox:n,label:i}=await _A(e,t,"label"),o=r.insert("rect",":first-child");return o.attr("width",.1).attr("height",.1),r.attr("class","label edgeLabel"),i.attr("transform",`translate(${-n.width/2-(n.x-(n.left??0))}, ${-n.height/2-(n.y-(n.top??0))})`),AA(t,o),t.intersect=function(e){return tP.rect(t,e)},r}async function FP(e,t){const{labelStyles:r,nodeStyles:n}=AC(t);t.labelStyle=r;const{shapeSvg:i,bbox:o}=await _A(e,t,PA(t)),a=Math.max(o.width+(t.padding??0),(null==t?void 0:t.width)??0),s=Math.max(o.height+(t.padding??0),(null==t?void 0:t.height)??0),l=[{x:0,y:0},{x:a+3*s/6,y:0},{x:a,y:-s},{x:-3*s/6,y:-s}];let c;const{cssStyles:u}=t;if("handDrawn"===t.look){const e=SA(i),r=PC(t,{}),n=EA(l),o=e.path(n,r);c=i.insert(()=>o,":first-child").attr("transform",`translate(${-a/2}, ${s/2})`),u&&c.attr("style",u)}else c=oP(i,a,s,l);return n&&c.attr("style",n),t.width=a,t.height=s,AA(t,c),t.intersect=function(e){return tP.polygon(t,l,e)},i}async function RP(e,t){const{labelStyles:r,nodeStyles:n}=AC(t);t.labelStyle=r;const{shapeSvg:i,bbox:o}=await _A(e,t,PA(t)),a=Math.max(o.width+(t.padding??0),(null==t?void 0:t.width)??0),s=Math.max(o.height+(t.padding??0),(null==t?void 0:t.height)??0),l=[{x:-3*s/6,y:0},{x:a,y:0},{x:a+3*s/6,y:-s},{x:0,y:-s}];let c;const{cssStyles:u}=t;if("handDrawn"===t.look){const e=SA(i),r=PC(t,{}),n=EA(l),o=e.path(n,r);c=i.insert(()=>o,":first-child").attr("transform",`translate(${-a/2}, ${s/2})`),u&&c.attr("style",u)}else c=oP(i,a,s,l);return n&&c.attr("style",n),t.width=a,t.height=s,AA(t,c),t.intersect=function(e){return tP.polygon(t,l,e)},i}function $P(e,t){const{labelStyles:r,nodeStyles:n}=AC(t);t.label="",t.labelStyle=r;const i=e.insert("g").attr("class",PA(t)).attr("id",t.domId??t.id),{cssStyles:o}=t,a=Math.max(35,(null==t?void 0:t.width)??0),s=Math.max(35,(null==t?void 0:t.height)??0),l=[{x:a,y:0},{x:0,y:s+3.5},{x:a-14,y:s+3.5},{x:0,y:2*s},{x:a,y:s-3.5},{x:14,y:s-3.5}],c=SA(i),u=PC(t,{});"handDrawn"!==t.look&&(u.roughness=0,u.fillStyle="solid");const h=EA(l),d=c.path(h,u),p=i.insert(()=>d,":first-child");return o&&"handDrawn"!==t.look&&p.selectAll("path").attr("style",o),n&&"handDrawn"!==t.look&&p.selectAll("path").attr("style",n),p.attr("transform",`translate(-${a/2},${-s})`),AA(t,p),t.intersect=function(e){bu.info("lightningBolt intersect",t,e);return tP.polygon(t,l,e)},i}mu(CP,"cylinder"),mu(wP,"dividedRectangle"),mu(kP,"doublecircle"),mu(SP,"filledCircle"),mu(_P,"flippedTriangle"),mu(TP,"forkJoin"),mu(AP,"halfRoundedRectangle"),mu(PP,"hexagon"),mu(EP,"hourglass"),mu(MP,"icon"),mu(IP,"iconCircle"),mu(BP,"iconRounded"),mu(LP,"iconSquare"),mu(jP,"imageSquare"),mu(NP,"inv_trapezoid"),mu(DP,"drawRect"),mu(OP,"labelRect"),mu(FP,"lean_left"),mu(RP,"lean_right"),mu($P,"lightningBolt");var zP=mu((e,t,r,n,i,o,a)=>[`M${e},${t+o}`,`a${i},${o} 0,0,0 ${r},0`,`a${i},${o} 0,0,0 ${-r},0`,`l0,${n}`,`a${i},${o} 0,0,0 ${r},0`,"l0,"+-n,`M${e},${t+o+a}`,`a${i},${o} 0,0,0 ${r},0`].join(" "),"createCylinderPathD"),VP=mu((e,t,r,n,i,o,a)=>[`M${e},${t+o}`,`M${e+r},${t+o}`,`a${i},${o} 0,0,0 ${-r},0`,`l0,${n}`,`a${i},${o} 0,0,0 ${r},0`,"l0,"+-n,`M${e},${t+o+a}`,`a${i},${o} 0,0,0 ${r},0`].join(" "),"createOuterCylinderPathD"),WP=mu((e,t,r,n,i,o)=>[`M${e-r/2},${-n/2}`,`a${i},${o} 0,0,0 ${r},0`].join(" "),"createInnerCylinderPathD");async function HP(e,t){const{labelStyles:r,nodeStyles:n}=AC(t);t.labelStyle=r;const{shapeSvg:i,bbox:o,label:a}=await _A(e,t,PA(t)),s=Math.max(o.width+(t.padding??0),t.width??0),l=s/2,c=l/(2.5+s/50),u=Math.max(o.height+c+(t.padding??0),t.height??0),h=.1*u;let d;const{cssStyles:p}=t;if("handDrawn"===t.look){const e=SA(i),r=VP(0,0,s,u,l,c,h),n=WP(0,c,s,u,l,c),o=PC(t,{}),a=e.path(r,o),f=e.path(n,o);i.insert(()=>f,":first-child").attr("class","line"),d=i.insert(()=>a,":first-child"),d.attr("class","basic label-container"),p&&d.attr("style",p)}else{const e=zP(0,0,s,u,l,c,h);d=i.insert("path",":first-child").attr("d",e).attr("class","basic label-container").attr("style",wS(p)).attr("style",n)}return d.attr("label-offset-y",c),d.attr("transform",`translate(${-s/2}, ${-(u/2+c)})`),AA(t,d),a.attr("transform",`translate(${-o.width/2-(o.x-(o.left??0))}, ${-o.height/2+c-(o.y-(o.top??0))})`),t.intersect=function(e){const r=tP.rect(t,e),n=r.x-(t.x??0);if(0!=l&&(Math.abs(n)<(t.width??0)/2||Math.abs(n)==(t.width??0)/2&&Math.abs(r.y-(t.y??0))>(t.height??0)/2-c)){let i=c*c*(1-n*n/(l*l));i>0&&(i=Math.sqrt(i)),i=c-i,e.y-(t.y??0)>0&&(i=-i),r.y+=i}return r},i}async function qP(e,t){const{labelStyles:r,nodeStyles:n}=AC(t);t.labelStyle=r;const{shapeSvg:i,bbox:o,label:a}=await _A(e,t,PA(t)),s=Math.max(o.width+2*(t.padding??0),(null==t?void 0:t.width)??0),l=Math.max(o.height+2*(t.padding??0),(null==t?void 0:t.height)??0),c=l/4,u=l+c,{cssStyles:h}=t,d=SA(i),p=PC(t,{});"handDrawn"!==t.look&&(p.roughness=0,p.fillStyle="solid");const f=[{x:-s/2-s/2*.1,y:-u/2},{x:-s/2-s/2*.1,y:u/2},...MA(-s/2-s/2*.1,u/2,s/2+s/2*.1,u/2,c,.8),{x:s/2+s/2*.1,y:-u/2},{x:-s/2-s/2*.1,y:-u/2},{x:-s/2,y:-u/2},{x:-s/2,y:u/2*1.1},{x:-s/2,y:-u/2}],g=d.polygon(f.map(e=>[e.x,e.y]),p),m=i.insert(()=>g,":first-child");return m.attr("class","basic label-container"),h&&"handDrawn"!==t.look&&m.selectAll("path").attr("style",h),n&&"handDrawn"!==t.look&&m.selectAll("path").attr("style",n),m.attr("transform",`translate(0,${-c/2})`),a.attr("transform",`translate(${-s/2+(t.padding??0)+s/2*.1/2-(o.x-(o.left??0))},${-l/2+(t.padding??0)-c/2-(o.y-(o.top??0))})`),AA(t,m),t.intersect=function(e){return tP.polygon(t,f,e)},i}async function UP(e,t){const{labelStyles:r,nodeStyles:n}=AC(t);t.labelStyle=r;const{shapeSvg:i,bbox:o,label:a}=await _A(e,t,PA(t)),s=Math.max(o.width+2*(t.padding??0),(null==t?void 0:t.width)??0),l=Math.max(o.height+2*(t.padding??0),(null==t?void 0:t.height)??0),c=-s/2,u=-l/2,{cssStyles:h}=t,d=SA(i),p=PC(t,{}),f=[{x:c-5,y:u+5},{x:c-5,y:u+l+5},{x:c+s-5,y:u+l+5},{x:c+s-5,y:u+l},{x:c+s,y:u+l},{x:c+s,y:u+l-5},{x:c+s+5,y:u+l-5},{x:c+s+5,y:u-5},{x:c+5,y:u-5},{x:c+5,y:u},{x:c,y:u},{x:c,y:u+5}],g=[{x:c,y:u+5},{x:c+s-5,y:u+5},{x:c+s-5,y:u+l},{x:c+s,y:u+l},{x:c+s,y:u},{x:c,y:u}];"handDrawn"!==t.look&&(p.roughness=0,p.fillStyle="solid");const m=EA(f),y=d.path(m,p),x=EA(g),b=d.path(x,{...p,fill:"none"}),v=i.insert(()=>b,":first-child");return v.insert(()=>y,":first-child"),v.attr("class","basic label-container"),h&&"handDrawn"!==t.look&&v.selectAll("path").attr("style",h),n&&"handDrawn"!==t.look&&v.selectAll("path").attr("style",n),a.attr("transform",`translate(${-o.width/2-5-(o.x-(o.left??0))}, ${-o.height/2+5-(o.y-(o.top??0))})`),AA(t,v),t.intersect=function(e){return tP.polygon(t,f,e)},i}async function GP(e,t){const{labelStyles:r,nodeStyles:n}=AC(t);t.labelStyle=r;const{shapeSvg:i,bbox:o,label:a}=await _A(e,t,PA(t)),s=Math.max(o.width+2*(t.padding??0),(null==t?void 0:t.width)??0),l=Math.max(o.height+2*(t.padding??0),(null==t?void 0:t.height)??0),c=l/4,u=l+c,h=-s/2,d=-u/2,{cssStyles:p}=t,f=MA(h-5,d+u+5,h+s-5,d+u+5,c,.8),g=null==f?void 0:f[f.length-1],m=[{x:h-5,y:d+5},{x:h-5,y:d+u+5},...f,{x:h+s-5,y:g.y-5},{x:h+s,y:g.y-5},{x:h+s,y:g.y-10},{x:h+s+5,y:g.y-10},{x:h+s+5,y:d-5},{x:h+5,y:d-5},{x:h+5,y:d},{x:h,y:d},{x:h,y:d+5}],y=[{x:h,y:d+5},{x:h+s-5,y:d+5},{x:h+s-5,y:g.y-5},{x:h+s,y:g.y-5},{x:h+s,y:d},{x:h,y:d}],x=SA(i),b=PC(t,{});"handDrawn"!==t.look&&(b.roughness=0,b.fillStyle="solid");const v=EA(m),C=x.path(v,b),w=EA(y),k=x.path(w,b),S=i.insert(()=>C,":first-child");return S.insert(()=>k),S.attr("class","basic label-container"),p&&"handDrawn"!==t.look&&S.selectAll("path").attr("style",p),n&&"handDrawn"!==t.look&&S.selectAll("path").attr("style",n),S.attr("transform",`translate(0,${-c/2})`),a.attr("transform",`translate(${-o.width/2-5-(o.x-(o.left??0))}, ${-o.height/2+5-c/2-(o.y-(o.top??0))})`),AA(t,S),t.intersect=function(e){return tP.polygon(t,m,e)},i}async function XP(e,t,{config:{themeVariables:r}}){var n;const{labelStyles:i,nodeStyles:o}=AC(t);t.labelStyle=i;t.useHtmlLabels||!1!==(null==(n=Dd().flowchart)?void 0:n.htmlLabels)||(t.centerLabel=!0);const{shapeSvg:a,bbox:s,label:l}=await _A(e,t,PA(t)),c=Math.max(s.width+2*(t.padding??0),(null==t?void 0:t.width)??0),u=Math.max(s.height+2*(t.padding??0),(null==t?void 0:t.height)??0),h=-c/2,d=-u/2,{cssStyles:p}=t,f=SA(a),g=PC(t,{fill:r.noteBkgColor,stroke:r.noteBorderColor});"handDrawn"!==t.look&&(g.roughness=0,g.fillStyle="solid");const m=f.rectangle(h,d,c,u,g),y=a.insert(()=>m,":first-child");return y.attr("class","basic label-container"),p&&"handDrawn"!==t.look&&y.selectAll("path").attr("style",p),o&&"handDrawn"!==t.look&&y.selectAll("path").attr("style",o),l.attr("transform",`translate(${-s.width/2-(s.x-(s.left??0))}, ${-s.height/2-(s.y-(s.top??0))})`),AA(t,y),t.intersect=function(e){return tP.rect(t,e)},a}mu(HP,"linedCylinder"),mu(qP,"linedWaveEdgedRect"),mu(UP,"multiRect"),mu(GP,"multiWaveEdgedRectangle"),mu(XP,"note");var JP=mu((e,t,r)=>[`M${e+r/2},${t}`,`L${e+r},${t-r/2}`,`L${e+r/2},${t-r}`,`L${e},${t-r/2}`,"Z"].join(" "),"createDecisionBoxPathD");async function YP(e,t){const{labelStyles:r,nodeStyles:n}=AC(t);t.labelStyle=r;const{shapeSvg:i,bbox:o}=await _A(e,t,PA(t)),a=o.width+t.padding+(o.height+t.padding),s=[{x:a/2,y:0},{x:a,y:-a/2},{x:a/2,y:-a},{x:0,y:-a/2}];let l;const{cssStyles:c}=t;if("handDrawn"===t.look){const e=SA(i),r=PC(t,{}),n=JP(0,0,a),o=e.path(n,r);l=i.insert(()=>o,":first-child").attr("transform",`translate(${-a/2+.5}, ${a/2})`),c&&l.attr("style",c)}else l=oP(i,a,a,s),l.attr("transform",`translate(${-a/2+.5}, ${a/2})`);return n&&l.attr("style",n),AA(t,l),t.calcIntersect=function(e,t){const r=e.width,n=[{x:r/2,y:0},{x:r,y:-r/2},{x:r/2,y:-r},{x:0,y:-r/2}],i=tP.polygon(e,n,t);return{x:i.x-.5,y:i.y-.5}},t.intersect=function(e){return this.calcIntersect(t,e)},i}async function ZP(e,t){const{labelStyles:r,nodeStyles:n}=AC(t);t.labelStyle=r;const{shapeSvg:i,bbox:o,label:a}=await _A(e,t,PA(t)),s=-Math.max(o.width+(t.padding??0),(null==t?void 0:t.width)??0)/2,l=-Math.max(o.height+(t.padding??0),(null==t?void 0:t.height)??0)/2,c=l/2,u=[{x:s+c,y:l},{x:s,y:0},{x:s+c,y:-l},{x:-s,y:-l},{x:-s,y:l}],{cssStyles:h}=t,d=SA(i),p=PC(t,{});"handDrawn"!==t.look&&(p.roughness=0,p.fillStyle="solid");const f=EA(u),g=d.path(f,p),m=i.insert(()=>g,":first-child");return m.attr("class","basic label-container"),h&&"handDrawn"!==t.look&&m.selectAll("path").attr("style",h),n&&"handDrawn"!==t.look&&m.selectAll("path").attr("style",n),m.attr("transform",`translate(${-c/2},0)`),a.attr("transform",`translate(${-c/2-o.width/2-(o.x-(o.left??0))}, ${-o.height/2-(o.y-(o.top??0))})`),AA(t,m),t.intersect=function(e){return tP.polygon(t,u,e)},i}async function KP(e,t){var r,n;const{labelStyles:i,nodeStyles:o}=AC(t);let a;t.labelStyle=i,a=t.cssClasses?"node "+t.cssClasses:"node default";const s=e.insert("g").attr("class",a).attr("id",t.domId||t.id),l=s.insert("g"),c=s.insert("g").attr("class","label").attr("style",o),u=t.description,h=t.label,d=c.node().appendChild(await NA(h,t.labelStyle,!0,!0));let p={width:0,height:0};if(ip(null==(n=null==(r=$p())?void 0:r.flowchart)?void 0:n.htmlLabels)){const e=d.children[0],t=fg(d);p=e.getBoundingClientRect(),t.attr("width",p.width),t.attr("height",p.height)}bu.info("Text 2",u);const f=u||[],g=d.getBBox(),m=c.node().appendChild(await NA(f.join?f.join("<br/>"):f,t.labelStyle,!0,!0)),y=m.children[0],x=fg(m);p=y.getBoundingClientRect(),x.attr("width",p.width),x.attr("height",p.height);const b=(t.padding||0)/2;fg(m).attr("transform","translate( "+(p.width>g.width?0:(g.width-p.width)/2)+", "+(g.height+b+5)+")"),fg(d).attr("transform","translate( "+(p.width<g.width?0:-(g.width-p.width)/2)+", 0)"),p=c.node().getBBox(),c.attr("transform","translate("+-p.width/2+", "+(-p.height/2-b+3)+")");const v=p.width+(t.padding||0),C=p.height+(t.padding||0),w=-p.width/2-b,k=-p.height/2-b;let S,_;if("handDrawn"===t.look){const e=SA(s),r=PC(t,{}),n=e.path(DA(w,k,v,C,t.rx||0),r),i=e.line(-p.width/2-b,-p.height/2-b+g.height+b,p.width/2+b,-p.height/2-b+g.height+b,r);_=s.insert(()=>(bu.debug("Rough node insert CXC",n),i),":first-child"),S=s.insert(()=>(bu.debug("Rough node insert CXC",n),n),":first-child")}else S=l.insert("rect",":first-child"),_=l.insert("line"),S.attr("class","outer title-state").attr("style",o).attr("x",-p.width/2-b).attr("y",-p.height/2-b).attr("width",p.width+(t.padding||0)).attr("height",p.height+(t.padding||0)),_.attr("class","divider").attr("x1",-p.width/2-b).attr("x2",p.width/2+b).attr("y1",-p.height/2-b+g.height+b).attr("y2",-p.height/2-b+g.height+b);return AA(t,S),t.intersect=function(e){return tP.rect(t,e)},s}function QP(e,t,r,n,i,o,a){const s=(e+r)/2,l=(t+n)/2,c=Math.atan2(n-t,r-e),u=(r-e)/2/i,h=(n-t)/2/o,d=Math.sqrt(u**2+h**2);if(d>1)throw new Error("The given radii are too small to create an arc between the points.");const p=Math.sqrt(1-d**2),f=s+p*o*Math.sin(c)*(a?-1:1),g=l-p*i*Math.cos(c)*(a?-1:1),m=Math.atan2((t-g)/o,(e-f)/i);let y=Math.atan2((n-g)/o,(r-f)/i)-m;a&&y<0&&(y+=2*Math.PI),!a&&y>0&&(y-=2*Math.PI);const x=[];for(let b=0;b<20;b++){const e=m+b/19*y,t=f+i*Math.cos(e),r=g+o*Math.sin(e);x.push({x:t,y:r})}return x}async function eE(e,t){const{labelStyles:r,nodeStyles:n}=AC(t);t.labelStyle=r;const{shapeSvg:i,bbox:o}=await _A(e,t,PA(t)),a=(null==t?void 0:t.padding)??0,s=(null==t?void 0:t.padding)??0,l=((null==t?void 0:t.width)?null==t?void 0:t.width:o.width)+2*a,c=((null==t?void 0:t.height)?null==t?void 0:t.height:o.height)+2*s,u=t.radius||5,h=t.taper||5,{cssStyles:d}=t,p=SA(i),f=PC(t,{});t.stroke&&(f.stroke=t.stroke),"handDrawn"!==t.look&&(f.roughness=0,f.fillStyle="solid");const g=[{x:-l/2+h,y:-c/2},{x:l/2-h,y:-c/2},...QP(l/2-h,-c/2,l/2,-c/2+h,u,u,!0),{x:l/2,y:-c/2+h},{x:l/2,y:c/2-h},...QP(l/2,c/2-h,l/2-h,c/2,u,u,!0),{x:l/2-h,y:c/2},{x:-l/2+h,y:c/2},...QP(-l/2+h,c/2,-l/2,c/2-h,u,u,!0),{x:-l/2,y:c/2-h},{x:-l/2,y:-c/2+h},...QP(-l/2,-c/2+h,-l/2+h,-c/2,u,u,!0)],m=EA(g),y=p.path(m,f),x=i.insert(()=>y,":first-child");return x.attr("class","basic label-container outer-path"),d&&"handDrawn"!==t.look&&x.selectChildren("path").attr("style",d),n&&"handDrawn"!==t.look&&x.selectChildren("path").attr("style",n),AA(t,x),t.intersect=function(e){return tP.polygon(t,g,e)},i}async function tE(e,t){const{labelStyles:r,nodeStyles:n}=AC(t);t.labelStyle=r;const{shapeSvg:i,bbox:o,label:a}=await _A(e,t,PA(t)),s=(null==t?void 0:t.padding)??0,l=Math.max(o.width+2*(t.padding??0),(null==t?void 0:t.width)??0),c=Math.max(o.height+2*(t.padding??0),(null==t?void 0:t.height)??0),u=-o.width/2-s,h=-o.height/2-s,{cssStyles:d}=t,p=SA(i),f=PC(t,{});"handDrawn"!==t.look&&(f.roughness=0,f.fillStyle="solid");const g=[{x:u,y:h},{x:u+l+8,y:h},{x:u+l+8,y:h+c},{x:u-8,y:h+c},{x:u-8,y:h},{x:u,y:h},{x:u,y:h+c}],m=p.polygon(g.map(e=>[e.x,e.y]),f),y=i.insert(()=>m,":first-child");return y.attr("class","basic label-container").attr("style",wS(d)),n&&"handDrawn"!==t.look&&y.selectAll("path").attr("style",n),d&&"handDrawn"!==t.look&&y.selectAll("path").attr("style",n),a.attr("transform",`translate(${-l/2+4+(t.padding??0)-(o.x-(o.left??0))},${-c/2+(t.padding??0)-(o.y-(o.top??0))})`),AA(t,y),t.intersect=function(e){return tP.rect(t,e)},i}async function rE(e,t){const{labelStyles:r,nodeStyles:n}=AC(t);t.labelStyle=r;const{shapeSvg:i,bbox:o,label:a}=await _A(e,t,PA(t)),s=Math.max(o.width+2*(t.padding??0),(null==t?void 0:t.width)??0),l=Math.max(o.height+2*(t.padding??0),(null==t?void 0:t.height)??0),c=-s/2,u=-l/2,{cssStyles:h}=t,d=SA(i),p=PC(t,{});"handDrawn"!==t.look&&(p.roughness=0,p.fillStyle="solid");const f=[{x:c,y:u},{x:c,y:u+l},{x:c+s,y:u+l},{x:c+s,y:u-l/2}],g=EA(f),m=d.path(g,p),y=i.insert(()=>m,":first-child");return y.attr("class","basic label-container"),h&&"handDrawn"!==t.look&&y.selectChildren("path").attr("style",h),n&&"handDrawn"!==t.look&&y.selectChildren("path").attr("style",n),y.attr("transform",`translate(0, ${l/4})`),a.attr("transform",`translate(${-s/2+(t.padding??0)-(o.x-(o.left??0))}, ${-l/4+(t.padding??0)-(o.y-(o.top??0))})`),AA(t,y),t.intersect=function(e){return tP.polygon(t,f,e)},i}async function nE(e,t){return DP(e,t,{rx:0,ry:0,labelPaddingX:t.labelPaddingX??2*((null==t?void 0:t.padding)||0),labelPaddingY:1*((null==t?void 0:t.padding)||0)})}async function iE(e,t){const{labelStyles:r,nodeStyles:n}=AC(t);t.labelStyle=r;const{shapeSvg:i,bbox:o}=await _A(e,t,PA(t)),a=o.height+t.padding,s=o.width+a/4+t.padding,l=a/2,{cssStyles:c}=t,u=SA(i),h=PC(t,{});"handDrawn"!==t.look&&(h.roughness=0,h.fillStyle="solid");const d=[{x:-s/2+l,y:-a/2},{x:s/2-l,y:-a/2},...IA(-s/2+l,0,l,50,90,270),{x:s/2-l,y:a/2},...IA(s/2-l,0,l,50,270,450)],p=EA(d),f=u.path(p,h),g=i.insert(()=>f,":first-child");return g.attr("class","basic label-container outer-path"),c&&"handDrawn"!==t.look&&g.selectChildren("path").attr("style",c),n&&"handDrawn"!==t.look&&g.selectChildren("path").attr("style",n),AA(t,g),t.intersect=function(e){return tP.polygon(t,d,e)},i}async function oE(e,t){return DP(e,t,{rx:5,ry:5})}function aE(e,t,{config:{themeVariables:r}}){const{labelStyles:n,nodeStyles:i}=AC(t);t.labelStyle=n;const{cssStyles:o}=t,{lineColor:a,stateBorder:s,nodeBorder:l}=r,c=e.insert("g").attr("class","node default").attr("id",t.domId||t.id),u=SA(c),h=PC(t,{});"handDrawn"!==t.look&&(h.roughness=0,h.fillStyle="solid");const d=u.circle(0,0,14,{...h,stroke:a,strokeWidth:2}),p=s??l,f=u.circle(0,0,5,{...h,fill:p,stroke:p,strokeWidth:2,fillStyle:"solid"}),g=c.insert(()=>d,":first-child");return g.insert(()=>f),o&&g.selectAll("path").attr("style",o),i&&g.selectAll("path").attr("style",i),AA(t,g),t.intersect=function(e){return tP.circle(t,7,e)},c}function sE(e,t,{config:{themeVariables:r}}){const{lineColor:n}=r,i=e.insert("g").attr("class","node default").attr("id",t.domId||t.id);let o;if("handDrawn"===t.look){const e=SA(i).circle(0,0,14,kC(n));o=i.insert(()=>e),o.attr("class","state-start").attr("r",7).attr("width",14).attr("height",14)}else o=i.insert("circle",":first-child"),o.attr("class","state-start").attr("r",7).attr("width",14).attr("height",14);return AA(t,o),t.intersect=function(e){return tP.circle(t,7,e)},i}async function lE(e,t){const{labelStyles:r,nodeStyles:n}=AC(t);t.labelStyle=r;const{shapeSvg:i,bbox:o}=await _A(e,t,PA(t)),a=((null==t?void 0:t.padding)||0)/2,s=o.width+t.padding,l=o.height+t.padding,c=-o.width/2-a,u=-o.height/2-a,h=[{x:0,y:0},{x:s,y:0},{x:s,y:-l},{x:0,y:-l},{x:0,y:0},{x:-8,y:0},{x:s+8,y:0},{x:s+8,y:-l},{x:-8,y:-l},{x:-8,y:0}];if("handDrawn"===t.look){const e=SA(i),r=PC(t,{}),n=e.rectangle(c-8,u,s+16,l,r),o=e.line(c,u,c,u+l,r),a=e.line(c+s,u,c+s,u+l,r);i.insert(()=>o,":first-child"),i.insert(()=>a,":first-child");const h=i.insert(()=>n,":first-child"),{cssStyles:d}=t;h.attr("class","basic label-container").attr("style",wS(d)),AA(t,h)}else{const e=oP(i,s,l,h);n&&e.attr("style",n),AA(t,e)}return t.intersect=function(e){return tP.polygon(t,h,e)},i}async function cE(e,t){const{labelStyles:r,nodeStyles:n}=AC(t);t.labelStyle=r;const{shapeSvg:i,bbox:o}=await _A(e,t,PA(t)),a=Math.max(o.width+2*(t.padding??0),(null==t?void 0:t.width)??0),s=Math.max(o.height+2*(t.padding??0),(null==t?void 0:t.height)??0),l=-a/2,c=-s/2,u=.2*s,h=.2*s,{cssStyles:d}=t,p=SA(i),f=PC(t,{}),g=[{x:l-u/2,y:c},{x:l+a+u/2,y:c},{x:l+a+u/2,y:c+s},{x:l-u/2,y:c+s}],m=[{x:l+a-u/2,y:c+s},{x:l+a+u/2,y:c+s},{x:l+a+u/2,y:c+s-h}];"handDrawn"!==t.look&&(f.roughness=0,f.fillStyle="solid");const y=EA(g),x=p.path(y,f),b=EA(m),v=p.path(b,{...f,fillStyle:"solid"}),C=i.insert(()=>v,":first-child");return C.insert(()=>x,":first-child"),C.attr("class","basic label-container"),d&&"handDrawn"!==t.look&&C.selectAll("path").attr("style",d),n&&"handDrawn"!==t.look&&C.selectAll("path").attr("style",n),AA(t,C),t.intersect=function(e){return tP.polygon(t,g,e)},i}async function uE(e,t){const{labelStyles:r,nodeStyles:n}=AC(t);t.labelStyle=r;const{shapeSvg:i,bbox:o,label:a}=await _A(e,t,PA(t)),s=Math.max(o.width+2*(t.padding??0),(null==t?void 0:t.width)??0),l=Math.max(o.height+2*(t.padding??0),(null==t?void 0:t.height)??0),c=l/4,u=.2*s,h=.2*l,d=l+c,{cssStyles:p}=t,f=SA(i),g=PC(t,{});"handDrawn"!==t.look&&(g.roughness=0,g.fillStyle="solid");const m=[{x:-s/2-s/2*.1,y:d/2},...MA(-s/2-s/2*.1,d/2,s/2+s/2*.1,d/2,c,.8),{x:s/2+s/2*.1,y:-d/2},{x:-s/2-s/2*.1,y:-d/2}],y=-s/2+s/2*.1,x=-d/2-.4*h,b=[{x:y+s-u,y:1.4*(x+l)},{x:y+s,y:x+l-h},{x:y+s,y:.9*(x+l)},...MA(y+s,1.3*(x+l),y+s-u,1.5*(x+l),.03*-l,.5)],v=EA(m),C=f.path(v,g),w=EA(b),k=f.path(w,{...g,fillStyle:"solid"}),S=i.insert(()=>k,":first-child");return S.insert(()=>C,":first-child"),S.attr("class","basic label-container"),p&&"handDrawn"!==t.look&&S.selectAll("path").attr("style",p),n&&"handDrawn"!==t.look&&S.selectAll("path").attr("style",n),S.attr("transform",`translate(0,${-c/2})`),a.attr("transform",`translate(${-s/2+(t.padding??0)-(o.x-(o.left??0))},${-l/2+(t.padding??0)-c/2-(o.y-(o.top??0))})`),AA(t,S),t.intersect=function(e){return tP.polygon(t,m,e)},i}async function hE(e,t){const{labelStyles:r,nodeStyles:n}=AC(t);t.labelStyle=r;const{shapeSvg:i,bbox:o}=await _A(e,t,PA(t)),a=Math.max(o.width+t.padding,(null==t?void 0:t.width)||0),s=Math.max(o.height+t.padding,(null==t?void 0:t.height)||0),l=-a/2,c=-s/2,u=i.insert("rect",":first-child");return u.attr("class","text").attr("style",n).attr("rx",0).attr("ry",0).attr("x",l).attr("y",c).attr("width",a).attr("height",s),AA(t,u),t.intersect=function(e){return tP.rect(t,e)},i}mu(YP,"question"),mu(ZP,"rect_left_inv_arrow"),mu(KP,"rectWithTitle"),mu(QP,"generateArcPoints"),mu(eE,"roundedRect"),mu(tE,"shadedProcess"),mu(rE,"slopedRect"),mu(nE,"squareRect"),mu(iE,"stadium"),mu(oE,"state"),mu(aE,"stateEnd"),mu(sE,"stateStart"),mu(lE,"subroutine"),mu(cE,"taggedRect"),mu(uE,"taggedWaveEdgedRectangle"),mu(hE,"text");var dE=mu((e,t,r,n,i,o)=>`M${e},${t}\n a${i},${o} 0,0,1 0,${-n}\n l${r},0\n a${i},${o} 0,0,1 0,${n}\n M${r},${-n}\n a${i},${o} 0,0,0 0,${n}\n l${-r},0`,"createCylinderPathD"),pE=mu((e,t,r,n,i,o)=>[`M${e},${t}`,`M${e+r},${t}`,`a${i},${o} 0,0,0 0,${-n}`,`l${-r},0`,`a${i},${o} 0,0,0 0,${n}`,`l${r},0`].join(" "),"createOuterCylinderPathD"),fE=mu((e,t,r,n,i,o)=>[`M${e+r/2},${-n/2}`,`a${i},${o} 0,0,0 0,${n}`].join(" "),"createInnerCylinderPathD");async function gE(e,t){const{labelStyles:r,nodeStyles:n}=AC(t);t.labelStyle=r;const{shapeSvg:i,bbox:o,label:a,halfPadding:s}=await _A(e,t,PA(t)),l="neo"===t.look?2*s:s,c=o.height+l,u=c/2,h=u/(2.5+c/50),d=o.width+h+l,{cssStyles:p}=t;let f;if("handDrawn"===t.look){const e=SA(i),r=pE(0,0,d,c,h,u),n=fE(0,0,d,c,h,u),o=e.path(r,PC(t,{})),a=e.path(n,PC(t,{fill:"none"}));f=i.insert(()=>a,":first-child"),f=i.insert(()=>o,":first-child"),f.attr("class","basic label-container"),p&&f.attr("style",p)}else{const e=dE(0,0,d,c,h,u);f=i.insert("path",":first-child").attr("d",e).attr("class","basic label-container").attr("style",wS(p)).attr("style",n),f.attr("class","basic label-container"),p&&f.selectAll("path").attr("style",p),n&&f.selectAll("path").attr("style",n)}return f.attr("label-offset-x",h),f.attr("transform",`translate(${-d/2}, ${c/2} )`),a.attr("transform",`translate(${-o.width/2-h-(o.x-(o.left??0))}, ${-o.height/2-(o.y-(o.top??0))})`),AA(t,f),t.intersect=function(e){const r=tP.rect(t,e),n=r.y-(t.y??0);if(0!=u&&(Math.abs(n)<(t.height??0)/2||Math.abs(n)==(t.height??0)/2&&Math.abs(r.x-(t.x??0))>(t.width??0)/2-h)){let i=h*h*(1-n*n/(u*u));0!=i&&(i=Math.sqrt(Math.abs(i))),i=h-i,e.x-(t.x??0)>0&&(i=-i),r.x+=i}return r},i}async function mE(e,t){const{labelStyles:r,nodeStyles:n}=AC(t);t.labelStyle=r;const{shapeSvg:i,bbox:o}=await _A(e,t,PA(t)),a=o.width+t.padding,s=o.height+t.padding,l=[{x:-3*s/6,y:0},{x:a+3*s/6,y:0},{x:a,y:-s},{x:0,y:-s}];let c;const{cssStyles:u}=t;if("handDrawn"===t.look){const e=SA(i),r=PC(t,{}),n=EA(l),o=e.path(n,r);c=i.insert(()=>o,":first-child").attr("transform",`translate(${-a/2}, ${s/2})`),u&&c.attr("style",u)}else c=oP(i,a,s,l);return n&&c.attr("style",n),t.width=a,t.height=s,AA(t,c),t.intersect=function(e){return tP.polygon(t,l,e)},i}async function yE(e,t){const{labelStyles:r,nodeStyles:n}=AC(t);t.labelStyle=r;const{shapeSvg:i,bbox:o}=await _A(e,t,PA(t)),a=Math.max(60,o.width+2*(t.padding??0),(null==t?void 0:t.width)??0),s=Math.max(20,o.height+2*(t.padding??0),(null==t?void 0:t.height)??0),{cssStyles:l}=t,c=SA(i),u=PC(t,{});"handDrawn"!==t.look&&(u.roughness=0,u.fillStyle="solid");const h=[{x:-a/2*.8,y:-s/2},{x:a/2*.8,y:-s/2},{x:a/2,y:-s/2*.6},{x:a/2,y:s/2},{x:-a/2,y:s/2},{x:-a/2,y:-s/2*.6}],d=EA(h),p=c.path(d,u),f=i.insert(()=>p,":first-child");return f.attr("class","basic label-container"),l&&"handDrawn"!==t.look&&f.selectChildren("path").attr("style",l),n&&"handDrawn"!==t.look&&f.selectChildren("path").attr("style",n),AA(t,f),t.intersect=function(e){return tP.polygon(t,h,e)},i}async function xE(e,t){var r;const{labelStyles:n,nodeStyles:i}=AC(t);t.labelStyle=n;const{shapeSvg:o,bbox:a,label:s}=await _A(e,t,PA(t)),l=ip(null==(r=$p().flowchart)?void 0:r.htmlLabels),c=a.width+(t.padding??0),u=c+a.height,h=c+a.height,d=[{x:0,y:0},{x:h,y:0},{x:h/2,y:-u}],{cssStyles:p}=t,f=SA(o),g=PC(t,{});"handDrawn"!==t.look&&(g.roughness=0,g.fillStyle="solid");const m=EA(d),y=f.path(m,g),x=o.insert(()=>y,":first-child").attr("transform",`translate(${-u/2}, ${u/2})`);return p&&"handDrawn"!==t.look&&x.selectChildren("path").attr("style",p),i&&"handDrawn"!==t.look&&x.selectChildren("path").attr("style",i),t.width=c,t.height=u,AA(t,x),s.attr("transform",`translate(${-a.width/2-(a.x-(a.left??0))}, ${u/2-(a.height+(t.padding??0)/(l?2:1)-(a.y-(a.top??0)))})`),t.intersect=function(e){return bu.info("Triangle intersect",t,d,e),tP.polygon(t,d,e)},o}async function bE(e,t){const{labelStyles:r,nodeStyles:n}=AC(t);t.labelStyle=r;const{shapeSvg:i,bbox:o,label:a}=await _A(e,t,PA(t)),s=Math.max(o.width+2*(t.padding??0),(null==t?void 0:t.width)??0),l=Math.max(o.height+2*(t.padding??0),(null==t?void 0:t.height)??0),c=l/8,u=l+c,{cssStyles:h}=t,d=70-s,p=d>0?d/2:0,f=SA(i),g=PC(t,{});"handDrawn"!==t.look&&(g.roughness=0,g.fillStyle="solid");const m=[{x:-s/2-p,y:u/2},...MA(-s/2-p,u/2,s/2+p,u/2,c,.8),{x:s/2+p,y:-u/2},{x:-s/2-p,y:-u/2}],y=EA(m),x=f.path(y,g),b=i.insert(()=>x,":first-child");return b.attr("class","basic label-container"),h&&"handDrawn"!==t.look&&b.selectAll("path").attr("style",h),n&&"handDrawn"!==t.look&&b.selectAll("path").attr("style",n),b.attr("transform",`translate(0,${-c/2})`),a.attr("transform",`translate(${-s/2+(t.padding??0)-(o.x-(o.left??0))},${-l/2+(t.padding??0)-c-(o.y-(o.top??0))})`),AA(t,b),t.intersect=function(e){return tP.polygon(t,m,e)},i}async function vE(e,t){const{labelStyles:r,nodeStyles:n}=AC(t);t.labelStyle=r;const{shapeSvg:i,bbox:o}=await _A(e,t,PA(t)),a=Math.max(o.width+2*(t.padding??0),(null==t?void 0:t.width)??0),s=Math.max(o.height+2*(t.padding??0),(null==t?void 0:t.height)??0),l=a/s;let c=a,u=s;c>u*l?u=c/l:c=u*l,c=Math.max(c,100),u=Math.max(u,50);const h=Math.min(.2*u,u/4),d=u+2*h,{cssStyles:p}=t,f=SA(i),g=PC(t,{});"handDrawn"!==t.look&&(g.roughness=0,g.fillStyle="solid");const m=[{x:-c/2,y:d/2},...MA(-c/2,d/2,c/2,d/2,h,1),{x:c/2,y:-d/2},...MA(c/2,-d/2,-c/2,-d/2,h,-1)],y=EA(m),x=f.path(y,g),b=i.insert(()=>x,":first-child");return b.attr("class","basic label-container"),p&&"handDrawn"!==t.look&&b.selectAll("path").attr("style",p),n&&"handDrawn"!==t.look&&b.selectAll("path").attr("style",n),AA(t,b),t.intersect=function(e){return tP.polygon(t,m,e)},i}async function CE(e,t){const{labelStyles:r,nodeStyles:n}=AC(t);t.labelStyle=r;const{shapeSvg:i,bbox:o,label:a}=await _A(e,t,PA(t)),s=Math.max(o.width+2*(t.padding??0),(null==t?void 0:t.width)??0),l=Math.max(o.height+2*(t.padding??0),(null==t?void 0:t.height)??0),c=-s/2,u=-l/2,{cssStyles:h}=t,d=SA(i),p=PC(t,{}),f=[{x:c-5,y:u-5},{x:c-5,y:u+l},{x:c+s,y:u+l},{x:c+s,y:u-5}],g=`M${c-5},${u-5} L${c+s},${u-5} L${c+s},${u+l} L${c-5},${u+l} L${c-5},${u-5}\n M${c-5},${u} L${c+s},${u}\n M${c},${u-5} L${c},${u+l}`;"handDrawn"!==t.look&&(p.roughness=0,p.fillStyle="solid");const m=d.path(g,p),y=i.insert(()=>m,":first-child");return y.attr("transform","translate(2.5, 2.5)"),y.attr("class","basic label-container"),h&&"handDrawn"!==t.look&&y.selectAll("path").attr("style",h),n&&"handDrawn"!==t.look&&y.selectAll("path").attr("style",n),a.attr("transform",`translate(${-o.width/2+2.5-(o.x-(o.left??0))}, ${-o.height/2+2.5-(o.y-(o.top??0))})`),AA(t,y),t.intersect=function(e){return tP.polygon(t,f,e)},i}async function wE(e,t){var r,n,i,o;const a=t;if(a.alias&&(t.label=a.alias),"handDrawn"===t.look){const{themeVariables:r}=Dd(),{background:n}=r,i={...t,id:t.id+"-background",look:"default",cssStyles:["stroke: none",`fill: ${n}`]};await wE(e,i)}const s=Dd();t.useHtmlLabels=s.htmlLabels;let l=(null==(r=s.er)?void 0:r.diagramPadding)??10,c=(null==(n=s.er)?void 0:n.entityPadding)??6;const{cssStyles:u}=t,{labelStyles:h,nodeStyles:d}=AC(t);if(0===a.attributes.length&&t.label){const r={rx:0,ry:0,labelPaddingX:l,labelPaddingY:1.5*l};cS(t.label,s)+2*r.labelPaddingX<s.er.minEntityWidth&&(t.width=s.er.minEntityWidth);const n=await DP(e,t,r);if(!ip(s.htmlLabels)){const e=n.select("text"),t=null==(i=e.node())?void 0:i.getBBox();e.attr("transform",`translate(${-t.width/2}, 0)`)}return n}s.htmlLabels||(l*=1.25,c*=1.25);let p=PA(t);p||(p="node default");const f=e.insert("g").attr("class",p).attr("id",t.domId||t.id),g=await kE(f,t.label??"",s,0,0,["name"],h);g.height+=c;let m=0;const y=[],x=[];let b=0,v=0,C=0,w=0,k=!0,S=!0;for(const V of a.attributes){const e=await kE(f,V.type,s,0,m,["attribute-type"],h);b=Math.max(b,e.width+l);const t=await kE(f,V.name,s,0,m,["attribute-name"],h);v=Math.max(v,t.width+l);const r=await kE(f,V.keys.join(),s,0,m,["attribute-keys"],h);C=Math.max(C,r.width+l);const n=await kE(f,V.comment,s,0,m,["attribute-comment"],h);w=Math.max(w,n.width+l);const i=Math.max(e.height,t.height,r.height,n.height)+c;x.push({yOffset:m,rowHeight:i}),m+=i}let _=4;C<=l&&(k=!1,C=0,_--),w<=l&&(S=!1,w=0,_--);const T=f.node().getBBox();if(g.width+2*l-(b+v+C+w)>0){const e=g.width+2*l-(b+v+C+w);b+=e/_,v+=e/_,C>0&&(C+=e/_),w>0&&(w+=e/_)}const A=b+v+C+w,P=SA(f),E=PC(t,{});"handDrawn"!==t.look&&(E.roughness=0,E.fillStyle="solid");let M=0;x.length>0&&(M=x.reduce((e,t)=>e+((null==t?void 0:t.rowHeight)??0),0));const I=Math.max(T.width+2*l,(null==t?void 0:t.width)||0,A),B=Math.max((M??0)+g.height,(null==t?void 0:t.height)||0),L=-I/2,j=-B/2;f.selectAll("g:not(:first-child)").each((e,t,r)=>{const n=fg(r[t]),i=n.attr("transform");let o=0,a=0;if(i){const e=RegExp(/translate\(([^,]+),([^)]+)\)/).exec(i);e&&(o=parseFloat(e[1]),a=parseFloat(e[2]),n.attr("class").includes("attribute-name")?o+=b:n.attr("class").includes("attribute-keys")?o+=b+v:n.attr("class").includes("attribute-comment")&&(o+=b+v+C))}n.attr("transform",`translate(${L+l/2+o}, ${a+j+g.height+c/2})`)}),f.select(".name").attr("transform","translate("+-g.width/2+", "+(j+c/2)+")");const N=P.rectangle(L,j,I,B,E),D=f.insert(()=>N,":first-child").attr("style",u.join("")),{themeVariables:O}=Dd(),{rowEven:F,rowOdd:R,nodeBorder:$}=O;y.push(0);for(const[V,W]of x.entries()){const e=(V+1)%2==0&&0!==W.yOffset,t=P.rectangle(L,g.height+j+(null==W?void 0:W.yOffset),I,null==W?void 0:W.rowHeight,{...E,fill:e?F:R,stroke:$});f.insert(()=>t,"g.label").attr("style",u.join("")).attr("class","row-rect-"+(e?"even":"odd"))}let z=P.line(L,g.height+j,I+L,g.height+j,E);f.insert(()=>z).attr("class","divider"),z=P.line(b+L,g.height+j,b+L,B+j,E),f.insert(()=>z).attr("class","divider"),k&&(z=P.line(b+v+L,g.height+j,b+v+L,B+j,E),f.insert(()=>z).attr("class","divider")),S&&(z=P.line(b+v+C+L,g.height+j,b+v+C+L,B+j,E),f.insert(()=>z).attr("class","divider"));for(const V of y)z=P.line(L,g.height+j+V,I+L,g.height+j+V,E),f.insert(()=>z).attr("class","divider");if(AA(t,D),d&&"handDrawn"!==t.look){const e=d.split(";"),t=null==(o=null==e?void 0:e.filter(e=>e.includes("stroke")))?void 0:o.map(e=>`${e}`).join("; ");f.selectAll("path").attr("style",t??""),f.selectAll(".row-rect-even path").attr("style",d)}return t.intersect=function(e){return tP.rect(t,e)},f}async function kE(e,t,r,n=0,i=0,o=[],a=""){const s=e.insert("g").attr("class",`label ${o.join(" ")}`).attr("transform",`translate(${n}, ${i})`).attr("style",a);t!==sp(t)&&(t=(t=sp(t)).replaceAll("<","<").replaceAll(">",">"));const l=s.node().appendChild(await ST(s,t,{width:cS(t,r)+100,style:a,useHtmlLabels:r.htmlLabels},r));if(t.includes("<")||t.includes(">")){let e=l.children[0];for(e.textContent=e.textContent.replaceAll("<","<").replaceAll(">",">");e.childNodes[0];)e=e.childNodes[0],e.textContent=e.textContent.replaceAll("<","<").replaceAll(">",">")}let c=l.getBBox();if(ip(r.htmlLabels)){const e=l.children[0];e.style.textAlign="start";const t=fg(l);c=e.getBoundingClientRect(),t.attr("width",c.width),t.attr("height",c.height)}return c}async function SE(e,t,r,n,i=r.class.padding??12){const o=n?0:3,a=e.insert("g").attr("class",PA(t)).attr("id",t.domId||t.id);let s=null,l=null,c=null,u=null,h=0,d=0,p=0;if(s=a.insert("g").attr("class","annotation-group text"),t.annotations.length>0){const e=t.annotations[0];await _E(s,{text:`«${e}»`},0);h=s.node().getBBox().height}l=a.insert("g").attr("class","label-group text"),await _E(l,t,0,["font-weight: bolder"]);const f=l.node().getBBox();d=f.height,c=a.insert("g").attr("class","members-group text");let g=0;for(const x of t.members){g+=await _E(c,x,g,[x.parseClassifier()])+o}p=c.node().getBBox().height,p<=0&&(p=i/2),u=a.insert("g").attr("class","methods-group text");let m=0;for(const x of t.methods){m+=await _E(u,x,m,[x.parseClassifier()])+o}let y=a.node().getBBox();if(null!==s){const e=s.node().getBBox();s.attr("transform",`translate(${-e.width/2})`)}return l.attr("transform",`translate(${-f.width/2}, ${h})`),y=a.node().getBBox(),c.attr("transform",`translate(0, ${h+d+2*i})`),y=a.node().getBBox(),u.attr("transform",`translate(0, ${h+d+(p?p+4*i:2*i)})`),y=a.node().getBBox(),{shapeSvg:a,bbox:y}}async function _E(e,t,r,n=[]){const i=e.insert("g").attr("class","label").attr("style",n.join("; ")),o=Dd();let a="useHtmlLabels"in t?t.useHtmlLabels:ip(o.htmlLabels)??!0,s="";s="text"in t?t.text:t.label,!a&&s.startsWith("\\")&&(s=s.substring(1)),pp(s)&&(a=!0);const l=await ST(i,Wp(vS(s)),{width:cS(s,o)+50,classes:"markdown-node-label",useHtmlLabels:a},o);let c,u=1;if(a){const e=l.children[0],t=fg(l);u=e.innerHTML.split("<br>").length,e.innerHTML.includes("</math>")&&(u+=e.innerHTML.split("<mrow>").length-1);const r=e.getElementsByTagName("img");if(r){const e=""===s.replace(/<img[^>]*>/g,"").trim();await Promise.all([...r].map(t=>new Promise(r=>{function n(){var n;if(t.style.display="flex",t.style.flexDirection="column",e){const e=(null==(n=o.fontSize)?void 0:n.toString())??window.getComputedStyle(document.body).fontSize,r=5,i=parseInt(e,10)*r+"px";t.style.minWidth=i,t.style.maxWidth=i}else t.style.width="100%";r(t)}mu(n,"setupImage"),setTimeout(()=>{t.complete&&n()}),t.addEventListener("error",n),t.addEventListener("load",n)})))}c=e.getBoundingClientRect(),t.attr("width",c.width),t.attr("height",c.height)}else{n.includes("font-weight: bolder")&&fg(l).selectAll("tspan").attr("font-weight",""),u=l.children.length;const e=l.children[0];if(""===l.textContent||l.textContent.includes(">")){e.textContent=s[0]+s.substring(1).replaceAll(">",">").replaceAll("<","<").trim();" "===s[1]&&(e.textContent=e.textContent[0]+" "+e.textContent.substring(1))}"undefined"===e.textContent&&(e.textContent=""),c=l.getBBox()}return i.attr("transform","translate(0,"+(-c.height/(2*u)+r)+")"),c.height}async function TE(e,t){var r,n;const i=$p(),o=i.class.padding??12,a=o,s=t.useHtmlLabels??ip(i.htmlLabels)??!0,l=t;l.annotations=l.annotations??[],l.members=l.members??[],l.methods=l.methods??[];const{shapeSvg:c,bbox:u}=await SE(e,t,i,s,a),{labelStyles:h,nodeStyles:d}=AC(t);t.labelStyle=h,t.cssStyles=l.styles||"";const p=(null==(r=l.styles)?void 0:r.join(";"))||d||"";t.cssStyles||(t.cssStyles=p.replaceAll("!important","").split(";"));const f=0===l.members.length&&0===l.methods.length&&!(null==(n=i.class)?void 0:n.hideEmptyMembersBox),g=SA(c),m=PC(t,{});"handDrawn"!==t.look&&(m.roughness=0,m.fillStyle="solid");const y=u.width;let x=u.height;0===l.members.length&&0===l.methods.length?x+=a:l.members.length>0&&0===l.methods.length&&(x+=2*a);const b=-y/2,v=-x/2,C=g.rectangle(b-o,v-o-(f?o:0===l.members.length&&0===l.methods.length?-o/2:0),y+2*o,x+2*o+(f?2*o:0===l.members.length&&0===l.methods.length?-o:0),m),w=c.insert(()=>C,":first-child");w.attr("class","basic label-container");const k=w.node().getBBox();c.selectAll(".text").each((e,t,r)=>{var n;const i=fg(r[t]),a=i.attr("transform");let u=0;if(a){const e=RegExp(/translate\(([^,]+),([^)]+)\)/).exec(a);e&&(u=parseFloat(e[2]))}let h=u+v+o-(f?o:0===l.members.length&&0===l.methods.length?-o/2:0);s||(h-=4);let d=b;(i.attr("class").includes("label-group")||i.attr("class").includes("annotation-group"))&&(d=-(null==(n=i.node())?void 0:n.getBBox().width)/2||0,c.selectAll("text").each(function(e,t,r){"middle"===window.getComputedStyle(r[t]).textAnchor&&(d=0)})),i.attr("transform",`translate(${d}, ${h})`)});const S=c.select(".annotation-group").node().getBBox().height-(f?o/2:0)||0,_=c.select(".label-group").node().getBBox().height-(f?o/2:0)||0,T=c.select(".members-group").node().getBBox().height-(f?o/2:0)||0;if(l.members.length>0||l.methods.length>0||f){const e=g.line(k.x,S+_+v+o,k.x+k.width,S+_+v+o,m);c.insert(()=>e).attr("class","divider").attr("style",p)}if(f||l.members.length>0||l.methods.length>0){const e=g.line(k.x,S+_+T+v+2*a+o,k.x+k.width,S+_+T+v+o+2*a,m);c.insert(()=>e).attr("class","divider").attr("style",p)}if("handDrawn"!==l.look&&c.selectAll("path").attr("style",p),w.select(":nth-child(2)").attr("style",p),c.selectAll(".divider").select("path").attr("style",p),t.labelStyle?c.selectAll("span").attr("style",t.labelStyle):c.selectAll("span").attr("style",p),!s){const e=RegExp(/color\s*:\s*([^;]*)/),t=e.exec(p);if(t){const e=t[0].replace("color","fill");c.selectAll("tspan").attr("style",e)}else if(h){const t=e.exec(h);if(t){const e=t[0].replace("color","fill");c.selectAll("tspan").attr("style",e)}}}return AA(t,w),t.intersect=function(e){return tP.rect(t,e)},c}async function AE(e,t){var r,n;const{labelStyles:i,nodeStyles:o}=AC(t);t.labelStyle=i;const a=t,s=t,l="verifyMethod"in t,c=PA(t),u=e.insert("g").attr("class",c).attr("id",t.domId??t.id);let h;h=l?await PE(u,`<<${a.type}>>`,0,t.labelStyle):await PE(u,"<<Element>>",0,t.labelStyle);let d=h;const p=await PE(u,a.name,d,t.labelStyle+"; font-weight: bold;");if(d+=p+20,l){d+=await PE(u,""+(a.requirementId?`ID: ${a.requirementId}`:""),d,t.labelStyle);d+=await PE(u,""+(a.text?`Text: ${a.text}`:""),d,t.labelStyle);d+=await PE(u,""+(a.risk?`Risk: ${a.risk}`:""),d,t.labelStyle),await PE(u,""+(a.verifyMethod?`Verification: ${a.verifyMethod}`:""),d,t.labelStyle)}else{d+=await PE(u,""+(s.type?`Type: ${s.type}`:""),d,t.labelStyle),await PE(u,""+(s.docRef?`Doc Ref: ${s.docRef}`:""),d,t.labelStyle)}const f=((null==(r=u.node())?void 0:r.getBBox().width)??200)+20,g=((null==(n=u.node())?void 0:n.getBBox().height)??200)+20,m=-f/2,y=-g/2,x=SA(u),b=PC(t,{});"handDrawn"!==t.look&&(b.roughness=0,b.fillStyle="solid");const v=x.rectangle(m,y,f,g,b),C=u.insert(()=>v,":first-child");if(C.attr("class","basic label-container").attr("style",o),u.selectAll(".label").each((e,t,r)=>{const n=fg(r[t]),i=n.attr("transform");let o=0,a=0;if(i){const e=RegExp(/translate\(([^,]+),([^)]+)\)/).exec(i);e&&(o=parseFloat(e[1]),a=parseFloat(e[2]))}const s=a-g/2;let l=m+10;0!==t&&1!==t||(l=o),n.attr("transform",`translate(${l}, ${s+20})`)}),d>h+p+20){const e=x.line(m,y+h+p+20,m+f,y+h+p+20,b);u.insert(()=>e).attr("style",o)}return AA(t,C),t.intersect=function(e){return tP.rect(t,e)},u}async function PE(e,t,r,n=""){if(""===t)return 0;const i=e.insert("g").attr("class","label").attr("style",n),o=$p(),a=o.htmlLabels??!0,s=await ST(i,Wp(vS(t)),{width:cS(t,o)+50,classes:"markdown-node-label",useHtmlLabels:a,style:n},o);let l;if(a){const e=s.children[0],t=fg(s);l=e.getBoundingClientRect(),t.attr("width",l.width),t.attr("height",l.height)}else{const e=s.children[0];for(const t of e.children)t.textContent=t.textContent.replaceAll(">",">").replaceAll("<","<"),n&&t.setAttribute("style",n);l=s.getBBox(),l.height+=6}return i.attr("transform",`translate(${-l.width/2},${-l.height/2+r})`),l.height}mu(gE,"tiltedCylinder"),mu(mE,"trapezoid"),mu(yE,"trapezoidalPentagon"),mu(xE,"triangle"),mu(bE,"waveEdgedRectangle"),mu(vE,"waveRectangle"),mu(CE,"windowPane"),mu(wE,"erBox"),mu(kE,"addText"),mu(SE,"textHelper"),mu(_E,"addText"),mu(TE,"classBox"),mu(AE,"requirementBox"),mu(PE,"addText");var EE=mu(e=>{switch(e){case"Very High":return"red";case"High":return"orange";case"Medium":return null;case"Low":return"blue";case"Very Low":return"lightblue"}},"colorFromPriority");async function ME(e,t,{config:r}){var n,i;const{labelStyles:o,nodeStyles:a}=AC(t);t.labelStyle=o||"";const s=t.width;t.width=(t.width??200)-10;const{shapeSvg:l,bbox:c,label:u}=await _A(e,t,PA(t)),h=t.padding||10;let d,p="";"ticket"in t&&t.ticket&&(null==(n=null==r?void 0:r.kanban)?void 0:n.ticketBaseUrl)&&(p=null==(i=null==r?void 0:r.kanban)?void 0:i.ticketBaseUrl.replace("#TICKET#",t.ticket),d=l.insert("svg:a",":first-child").attr("class","kanban-ticket-link").attr("xlink:href",p).attr("target","_blank"));const f={useHtmlLabels:t.useHtmlLabels,labelStyle:t.labelStyle||"",width:t.width,img:t.img,padding:t.padding||8,centerLabel:!1};let g,m;({label:g,bbox:m}=d?await TA(d,"ticket"in t&&t.ticket||"",f):await TA(l,"ticket"in t&&t.ticket||"",f));const{label:y,bbox:x}=await TA(l,"assigned"in t&&t.assigned||"",f);t.width=s;const b=(null==t?void 0:t.width)||0,v=Math.max(m.height,x.height)/2,C=Math.max(c.height+20,(null==t?void 0:t.height)||0)+v,w=-b/2,k=-C/2;let S;u.attr("transform","translate("+(h-b/2)+", "+(-v-c.height/2)+")"),g.attr("transform","translate("+(h-b/2)+", "+(-v+c.height/2)+")"),y.attr("transform","translate("+(h+b/2-x.width-20)+", "+(-v+c.height/2)+")");const{rx:_,ry:T}=t,{cssStyles:A}=t;if("handDrawn"===t.look){const e=SA(l),r=PC(t,{}),n=_||T?e.path(DA(w,k,b,C,_||0),r):e.rectangle(w,k,b,C,r);S=l.insert(()=>n,":first-child"),S.attr("class","basic label-container").attr("style",A||null)}else{S=l.insert("rect",":first-child"),S.attr("class","basic label-container __APA__").attr("style",a).attr("rx",_??5).attr("ry",T??5).attr("x",w).attr("y",k).attr("width",b).attr("height",C);const e="priority"in t&&t.priority;if(e){const t=l.append("line"),r=w+2,n=k+Math.floor((_??0)/2),i=k+C-Math.floor((_??0)/2);t.attr("x1",r).attr("y1",n).attr("x2",r).attr("y2",i).attr("stroke-width","4").attr("stroke",EE(e))}}return AA(t,S),t.height=C,t.intersect=function(e){return tP.rect(t,e)},l}async function IE(e,t){const{labelStyles:r,nodeStyles:n}=AC(t);t.labelStyle=r;const{shapeSvg:i,bbox:o,halfPadding:a,label:s}=await _A(e,t,PA(t)),l=o.width+10*a,c=o.height+8*a,u=.15*l,{cssStyles:h}=t,d=o.width+20,p=o.height+20,f=Math.max(l,d),g=Math.max(c,p);let m;s.attr("transform",`translate(${-o.width/2}, ${-o.height/2})`);const y=`M0 0 \n a${u},${u} 1 0,0 ${.25*f},${-1*g*.1}\n a${u},${u} 1 0,0 ${.25*f},0\n a${u},${u} 1 0,0 ${.25*f},0\n a${u},${u} 1 0,0 ${.25*f},${.1*g}\n\n a${u},${u} 1 0,0 ${.15*f},${.33*g}\n a${.8*u},${.8*u} 1 0,0 0,${.34*g}\n a${u},${u} 1 0,0 ${-1*f*.15},${.33*g}\n\n a${u},${u} 1 0,0 ${-1*f*.25},${.15*g}\n a${u},${u} 1 0,0 ${-1*f*.25},0\n a${u},${u} 1 0,0 ${-1*f*.25},0\n a${u},${u} 1 0,0 ${-1*f*.25},${-1*g*.15}\n\n a${u},${u} 1 0,0 ${-1*f*.1},${-1*g*.33}\n a${.8*u},${.8*u} 1 0,0 0,${-1*g*.34}\n a${u},${u} 1 0,0 ${.1*f},${-1*g*.33}\n H0 V0 Z`;if("handDrawn"===t.look){const e=SA(i),r=PC(t,{}),n=e.path(y,r);m=i.insert(()=>n,":first-child"),m.attr("class","basic label-container").attr("style",wS(h))}else m=i.insert("path",":first-child").attr("class","basic label-container").attr("style",n).attr("d",y);return m.attr("transform",`translate(${-f/2}, ${-g/2})`),AA(t,m),t.calcIntersect=function(e,t){return tP.rect(e,t)},t.intersect=function(e){return bu.info("Bang intersect",t,e),tP.rect(t,e)},i}async function BE(e,t){const{labelStyles:r,nodeStyles:n}=AC(t);t.labelStyle=r;const{shapeSvg:i,bbox:o,halfPadding:a,label:s}=await _A(e,t,PA(t)),l=o.width+2*a,c=o.height+2*a,u=.15*l,h=.25*l,d=.35*l,p=.2*l,{cssStyles:f}=t;let g;const m=`M0 0 \n a${u},${u} 0 0,1 ${.25*l},${-1*l*.1}\n a${d},${d} 1 0,1 ${.4*l},${-1*l*.1}\n a${h},${h} 1 0,1 ${.35*l},${.2*l}\n\n a${u},${u} 1 0,1 ${.15*l},${.35*c}\n a${p},${p} 1 0,1 ${-1*l*.15},${.65*c}\n\n a${h},${u} 1 0,1 ${-1*l*.25},${.15*l}\n a${d},${d} 1 0,1 ${-1*l*.5},0\n a${u},${u} 1 0,1 ${-1*l*.25},${-1*l*.15}\n\n a${u},${u} 1 0,1 ${-1*l*.1},${-1*c*.35}\n a${p},${p} 1 0,1 ${.1*l},${-1*c*.65}\n H0 V0 Z`;if("handDrawn"===t.look){const e=SA(i),r=PC(t,{}),n=e.path(m,r);g=i.insert(()=>n,":first-child"),g.attr("class","basic label-container").attr("style",wS(f))}else g=i.insert("path",":first-child").attr("class","basic label-container").attr("style",n).attr("d",m);return s.attr("transform",`translate(${-o.width/2}, ${-o.height/2})`),g.attr("transform",`translate(${-l/2}, ${-c/2})`),AA(t,g),t.calcIntersect=function(e,t){return tP.rect(e,t)},t.intersect=function(e){return bu.info("Cloud intersect",t,e),tP.rect(t,e)},i}async function LE(e,t){const{labelStyles:r,nodeStyles:n}=AC(t);t.labelStyle=r;const{shapeSvg:i,bbox:o,halfPadding:a,label:s}=await _A(e,t,PA(t)),l=o.width+8*a,c=o.height+2*a,u=`\n M${-l/2} ${c/2-5}\n v${10-c}\n q0,-5 5,-5\n h${l-10}\n q5,0 5,5\n v${c-10}\n q0,5 -5,5\n h${10-l}\n q-5,0 -5,-5\n Z\n `,h=i.append("path").attr("id","node-"+t.id).attr("class","node-bkg node-"+t.type).attr("style",n).attr("d",u);return i.append("line").attr("class","node-line-").attr("x1",-l/2).attr("y1",c/2).attr("x2",l/2).attr("y2",c/2),s.attr("transform",`translate(${-o.width/2}, ${-o.height/2})`),i.append(()=>s.node()),AA(t,h),t.calcIntersect=function(e,t){return tP.rect(e,t)},t.intersect=function(e){return tP.rect(t,e)},i}async function jE(e,t){return lP(e,t,{padding:t.padding??0})}mu(ME,"kanbanItem"),mu(IE,"bang"),mu(BE,"cloud"),mu(LE,"defaultMindmapNode"),mu(jE,"mindmapCircle");var NE=[{semanticName:"Process",name:"Rectangle",shortName:"rect",description:"Standard process shape",aliases:["proc","process","rectangle"],internalAliases:["squareRect"],handler:nE},{semanticName:"Event",name:"Rounded Rectangle",shortName:"rounded",description:"Represents an event",aliases:["event"],internalAliases:["roundedRect"],handler:eE},{semanticName:"Terminal Point",name:"Stadium",shortName:"stadium",description:"Terminal point",aliases:["terminal","pill"],handler:iE},{semanticName:"Subprocess",name:"Framed Rectangle",shortName:"fr-rect",description:"Subprocess",aliases:["subprocess","subproc","framed-rectangle","subroutine"],handler:lE},{semanticName:"Database",name:"Cylinder",shortName:"cyl",description:"Database storage",aliases:["db","database","cylinder"],handler:CP},{semanticName:"Start",name:"Circle",shortName:"circle",description:"Starting point",aliases:["circ"],handler:lP},{semanticName:"Bang",name:"Bang",shortName:"bang",description:"Bang",aliases:["bang"],handler:IE},{semanticName:"Cloud",name:"Cloud",shortName:"cloud",description:"cloud",aliases:["cloud"],handler:BE},{semanticName:"Decision",name:"Diamond",shortName:"diam",description:"Decision-making step",aliases:["decision","diamond","question"],handler:YP},{semanticName:"Prepare Conditional",name:"Hexagon",shortName:"hex",description:"Preparation or condition step",aliases:["hexagon","prepare"],handler:PP},{semanticName:"Data Input/Output",name:"Lean Right",shortName:"lean-r",description:"Represents input or output",aliases:["lean-right","in-out"],internalAliases:["lean_right"],handler:RP},{semanticName:"Data Input/Output",name:"Lean Left",shortName:"lean-l",description:"Represents output or input",aliases:["lean-left","out-in"],internalAliases:["lean_left"],handler:FP},{semanticName:"Priority Action",name:"Trapezoid Base Bottom",shortName:"trap-b",description:"Priority action",aliases:["priority","trapezoid-bottom","trapezoid"],handler:mE},{semanticName:"Manual Operation",name:"Trapezoid Base Top",shortName:"trap-t",description:"Represents a manual task",aliases:["manual","trapezoid-top","inv-trapezoid"],internalAliases:["inv_trapezoid"],handler:NP},{semanticName:"Stop",name:"Double Circle",shortName:"dbl-circ",description:"Represents a stop point",aliases:["double-circle"],internalAliases:["doublecircle"],handler:kP},{semanticName:"Text Block",name:"Text Block",shortName:"text",description:"Text block",handler:hE},{semanticName:"Card",name:"Notched Rectangle",shortName:"notch-rect",description:"Represents a card",aliases:["card","notched-rectangle"],handler:aP},{semanticName:"Lined/Shaded Process",name:"Lined Rectangle",shortName:"lin-rect",description:"Lined process shape",aliases:["lined-rectangle","lined-process","lin-proc","shaded-process"],handler:tE},{semanticName:"Start",name:"Small Circle",shortName:"sm-circ",description:"Small starting point",aliases:["start","small-circle"],internalAliases:["stateStart"],handler:sE},{semanticName:"Stop",name:"Framed Circle",shortName:"fr-circ",description:"Stop point",aliases:["stop","framed-circle"],internalAliases:["stateEnd"],handler:aE},{semanticName:"Fork/Join",name:"Filled Rectangle",shortName:"fork",description:"Fork or join in process flow",aliases:["join"],internalAliases:["forkJoin"],handler:TP},{semanticName:"Collate",name:"Hourglass",shortName:"hourglass",description:"Represents a collate operation",aliases:["hourglass","collate"],handler:EP},{semanticName:"Comment",name:"Curly Brace",shortName:"brace",description:"Adds a comment",aliases:["comment","brace-l"],handler:dP},{semanticName:"Comment Right",name:"Curly Brace",shortName:"brace-r",description:"Adds a comment",handler:fP},{semanticName:"Comment with braces on both sides",name:"Curly Braces",shortName:"braces",description:"Adds a comment",handler:mP},{semanticName:"Com Link",name:"Lightning Bolt",shortName:"bolt",description:"Communication link",aliases:["com-link","lightning-bolt"],handler:$P},{semanticName:"Document",name:"Document",shortName:"doc",description:"Represents a document",aliases:["doc","document"],handler:bE},{semanticName:"Delay",name:"Half-Rounded Rectangle",shortName:"delay",description:"Represents a delay",aliases:["half-rounded-rectangle"],handler:AP},{semanticName:"Direct Access Storage",name:"Horizontal Cylinder",shortName:"h-cyl",description:"Direct access storage",aliases:["das","horizontal-cylinder"],handler:gE},{semanticName:"Disk Storage",name:"Lined Cylinder",shortName:"lin-cyl",description:"Disk storage",aliases:["disk","lined-cylinder"],handler:HP},{semanticName:"Display",name:"Curved Trapezoid",shortName:"curv-trap",description:"Represents a display",aliases:["curved-trapezoid","display"],handler:yP},{semanticName:"Divided Process",name:"Divided Rectangle",shortName:"div-rect",description:"Divided process shape",aliases:["div-proc","divided-rectangle","divided-process"],handler:wP},{semanticName:"Extract",name:"Triangle",shortName:"tri",description:"Extraction process",aliases:["extract","triangle"],handler:xE},{semanticName:"Internal Storage",name:"Window Pane",shortName:"win-pane",description:"Internal storage",aliases:["internal-storage","window-pane"],handler:CE},{semanticName:"Junction",name:"Filled Circle",shortName:"f-circ",description:"Junction point",aliases:["junction","filled-circle"],handler:SP},{semanticName:"Loop Limit",name:"Trapezoidal Pentagon",shortName:"notch-pent",description:"Loop limit step",aliases:["loop-limit","notched-pentagon"],handler:yE},{semanticName:"Manual File",name:"Flipped Triangle",shortName:"flip-tri",description:"Manual file operation",aliases:["manual-file","flipped-triangle"],handler:_P},{semanticName:"Manual Input",name:"Sloped Rectangle",shortName:"sl-rect",description:"Manual input step",aliases:["manual-input","sloped-rectangle"],handler:rE},{semanticName:"Multi-Document",name:"Stacked Document",shortName:"docs",description:"Multiple documents",aliases:["documents","st-doc","stacked-document"],handler:GP},{semanticName:"Multi-Process",name:"Stacked Rectangle",shortName:"st-rect",description:"Multiple processes",aliases:["procs","processes","stacked-rectangle"],handler:UP},{semanticName:"Stored Data",name:"Bow Tie Rectangle",shortName:"bow-rect",description:"Stored data",aliases:["stored-data","bow-tie-rectangle"],handler:iP},{semanticName:"Summary",name:"Crossed Circle",shortName:"cross-circ",description:"Summary",aliases:["summary","crossed-circle"],handler:uP},{semanticName:"Tagged Document",name:"Tagged Document",shortName:"tag-doc",description:"Tagged document",aliases:["tag-doc","tagged-document"],handler:uE},{semanticName:"Tagged Process",name:"Tagged Rectangle",shortName:"tag-rect",description:"Tagged process",aliases:["tagged-rectangle","tag-proc","tagged-process"],handler:cE},{semanticName:"Paper Tape",name:"Flag",shortName:"flag",description:"Paper tape",aliases:["paper-tape"],handler:vE},{semanticName:"Odd",name:"Odd",shortName:"odd",description:"Odd shape",internalAliases:["rect_left_inv_arrow"],handler:ZP},{semanticName:"Lined Document",name:"Lined Document",shortName:"lin-doc",description:"Lined document",aliases:["lined-document"],handler:qP}],DE=mu(()=>{const e={state:oE,choice:sP,note:XP,rectWithTitle:KP,labelRect:OP,iconSquare:LP,iconCircle:IP,icon:MP,iconRounded:BP,imageSquare:jP,anchor:rP,kanbanItem:ME,mindmapCircle:jE,defaultMindmapNode:LE,classBox:TE,erBox:wE,requirementBox:AE},t=[...Object.entries(e),...NE.flatMap(e=>[e.shortName,..."aliases"in e?e.aliases:[],..."internalAliases"in e?e.internalAliases:[]].map(t=>[t,e.handler]))];return Object.fromEntries(t)},"generateShapeMap")();function OE(e){return e in DE}mu(OE,"isValidShape");var FE=new Map;async function RE(e,t,r){let n,i;"rect"===t.shape&&(t.rx&&t.ry?t.shape="roundedRect":t.shape="squareRect");const o=t.shape?DE[t.shape]:void 0;if(!o)throw new Error(`No such shape: ${t.shape}. Please check your syntax.`);if(t.link){let a;"sandbox"===r.config.securityLevel?a="_top":t.linkTarget&&(a=t.linkTarget||"_blank"),n=e.insert("svg:a").attr("xlink:href",t.link).attr("target",a??null),i=await o(n,t,r)}else i=await o(e,t,r),n=i;return t.tooltip&&i.attr("title",t.tooltip),FE.set(t.id,n),t.haveCallback&&n.attr("class",n.attr("class")+" clickable"),n}mu(RE,"insertNode");var $E=mu((e,t)=>{FE.set(t.id,e)},"setNodeElem"),zE=mu(()=>{FE.clear()},"clear"),VE=mu(e=>{const t=FE.get(e.id);bu.trace("Transforming node",e.diff,e,"translate("+(e.x-e.width/2-5)+", "+e.width/2+")");const r=e.diff||0;return e.clusterNode?t.attr("transform","translate("+(e.x+r-e.width/2)+", "+(e.y-e.height/2-8)+")"):t.attr("transform","translate("+e.x+", "+e.y+")"),r},"positionNode"),WE=mu((e,t,r,n,i,o)=>{t.arrowTypeStart&&qE(e,"start",t.arrowTypeStart,r,n,i,o),t.arrowTypeEnd&&qE(e,"end",t.arrowTypeEnd,r,n,i,o)},"addEdgeMarkers"),HE={arrow_cross:{type:"cross",fill:!1},arrow_point:{type:"point",fill:!0},arrow_barb:{type:"barb",fill:!0},arrow_circle:{type:"circle",fill:!1},aggregation:{type:"aggregation",fill:!1},extension:{type:"extension",fill:!1},composition:{type:"composition",fill:!0},dependency:{type:"dependency",fill:!0},lollipop:{type:"lollipop",fill:!1},only_one:{type:"onlyOne",fill:!1},zero_or_one:{type:"zeroOrOne",fill:!1},one_or_more:{type:"oneOrMore",fill:!1},zero_or_more:{type:"zeroOrMore",fill:!1},requirement_arrow:{type:"requirement_arrow",fill:!1},requirement_contains:{type:"requirement_contains",fill:!1}},qE=mu((e,t,r,n,i,o,a)=>{var s;const l=HE[r];if(!l)return void bu.warn(`Unknown arrow type: ${r}`);const c=`${i}_${o}-${l.type}${"start"===t?"Start":"End"}`;if(a&&""!==a.trim()){const r=`${c}_${a.replace(/[^\dA-Za-z]/g,"_")}`;if(!document.getElementById(r)){const e=document.getElementById(c);if(e){const t=e.cloneNode(!0);t.id=r;t.querySelectorAll("path, circle, line").forEach(e=>{e.setAttribute("stroke",a),l.fill&&e.setAttribute("fill",a)}),null==(s=e.parentNode)||s.appendChild(t)}}e.attr(`marker-${t}`,`url(${n}#${r})`)}else e.attr(`marker-${t}`,`url(${n}#${c})`)},"addEdgeMarker"),UE=new Map,GE=new Map,XE=mu(()=>{UE.clear(),GE.clear()},"clear"),JE=mu(e=>e?e.reduce((e,t)=>e+";"+t,""):"","getLabelStyles"),YE=mu(async(e,t)=>{let r=ip($p().flowchart.htmlLabels);const{labelStyles:n}=AC(t);t.labelStyle=n;const i=await ST(e,t.label,{style:t.labelStyle,useHtmlLabels:r,addSvgBackground:!0,isNode:!1});bu.info("abc82",t,t.labelType);const o=e.insert("g").attr("class","edgeLabel"),a=o.insert("g").attr("class","label").attr("data-id",t.id);a.node().appendChild(i);let s,l=i.getBBox();if(r){const e=i.children[0],t=fg(i);l=e.getBoundingClientRect(),t.attr("width",l.width),t.attr("height",l.height)}if(a.attr("transform","translate("+-l.width/2+", "+-l.height/2+")"),UE.set(t.id,o),t.width=l.width,t.height=l.height,t.startLabelLeft){const r=await NA(t.startLabelLeft,JE(t.labelStyle)),n=e.insert("g").attr("class","edgeTerminals"),i=n.insert("g").attr("class","inner");s=i.node().appendChild(r);const o=r.getBBox();i.attr("transform","translate("+-o.width/2+", "+-o.height/2+")"),GE.get(t.id)||GE.set(t.id,{}),GE.get(t.id).startLeft=n,ZE(s,t.startLabelLeft)}if(t.startLabelRight){const r=await NA(t.startLabelRight,JE(t.labelStyle)),n=e.insert("g").attr("class","edgeTerminals"),i=n.insert("g").attr("class","inner");s=n.node().appendChild(r),i.node().appendChild(r);const o=r.getBBox();i.attr("transform","translate("+-o.width/2+", "+-o.height/2+")"),GE.get(t.id)||GE.set(t.id,{}),GE.get(t.id).startRight=n,ZE(s,t.startLabelRight)}if(t.endLabelLeft){const r=await NA(t.endLabelLeft,JE(t.labelStyle)),n=e.insert("g").attr("class","edgeTerminals"),i=n.insert("g").attr("class","inner");s=i.node().appendChild(r);const o=r.getBBox();i.attr("transform","translate("+-o.width/2+", "+-o.height/2+")"),n.node().appendChild(r),GE.get(t.id)||GE.set(t.id,{}),GE.get(t.id).endLeft=n,ZE(s,t.endLabelLeft)}if(t.endLabelRight){const r=await NA(t.endLabelRight,JE(t.labelStyle)),n=e.insert("g").attr("class","edgeTerminals"),i=n.insert("g").attr("class","inner");s=i.node().appendChild(r);const o=r.getBBox();i.attr("transform","translate("+-o.width/2+", "+-o.height/2+")"),n.node().appendChild(r),GE.get(t.id)||GE.set(t.id,{}),GE.get(t.id).endRight=n,ZE(s,t.endLabelRight)}return i},"insertEdgeLabel");function ZE(e,t){$p().flowchart.htmlLabels&&e&&(e.style.width=9*t.length+"px",e.style.height="12px")}mu(ZE,"setTerminalWidth");var KE=mu((e,t)=>{bu.debug("Moving label abc88 ",e.id,e.label,UE.get(e.id),t);let r=t.updatedPath?t.updatedPath:t.originalPath;const n=$p(),{subGraphTitleTotalMargin:i}=wC(n);if(e.label){const n=UE.get(e.id);let o=e.x,a=e.y;if(r){const n=xS.calcLabelPosition(r);bu.debug("Moving label "+e.label+" from (",o,",",a,") to (",n.x,",",n.y,") abc88"),t.updatedPath&&(o=n.x,a=n.y)}n.attr("transform",`translate(${o}, ${a+i/2})`)}if(e.startLabelLeft){const t=GE.get(e.id).startLeft;let n=e.x,i=e.y;if(r){const t=xS.calcTerminalLabelPosition(e.arrowTypeStart?10:0,"start_left",r);n=t.x,i=t.y}t.attr("transform",`translate(${n}, ${i})`)}if(e.startLabelRight){const t=GE.get(e.id).startRight;let n=e.x,i=e.y;if(r){const t=xS.calcTerminalLabelPosition(e.arrowTypeStart?10:0,"start_right",r);n=t.x,i=t.y}t.attr("transform",`translate(${n}, ${i})`)}if(e.endLabelLeft){const t=GE.get(e.id).endLeft;let n=e.x,i=e.y;if(r){const t=xS.calcTerminalLabelPosition(e.arrowTypeEnd?10:0,"end_left",r);n=t.x,i=t.y}t.attr("transform",`translate(${n}, ${i})`)}if(e.endLabelRight){const t=GE.get(e.id).endRight;let n=e.x,i=e.y;if(r){const t=xS.calcTerminalLabelPosition(e.arrowTypeEnd?10:0,"end_right",r);n=t.x,i=t.y}t.attr("transform",`translate(${n}, ${i})`)}},"positionEdgeLabel"),QE=mu((e,t)=>{const r=e.x,n=e.y,i=Math.abs(t.x-r),o=Math.abs(t.y-n),a=e.width/2,s=e.height/2;return i>=a||o>=s},"outsideNode"),eM=mu((e,t,r)=>{bu.debug(`intersection calc abc89:\n outsidePoint: ${JSON.stringify(t)}\n insidePoint : ${JSON.stringify(r)}\n node : x:${e.x} y:${e.y} w:${e.width} h:${e.height}`);const n=e.x,i=e.y,o=Math.abs(n-r.x),a=e.width/2;let s=r.x<t.x?a-o:a+o;const l=e.height/2,c=Math.abs(t.y-r.y),u=Math.abs(t.x-r.x);if(Math.abs(i-t.y)*a>Math.abs(n-t.x)*l){let e=r.y<t.y?t.y-l-i:i-l-t.y;s=u*e/c;const n={x:r.x<t.x?r.x+s:r.x-u+s,y:r.y<t.y?r.y+c-e:r.y-c+e};return 0===s&&(n.x=t.x,n.y=t.y),0===u&&(n.x=t.x),0===c&&(n.y=t.y),bu.debug(`abc89 top/bottom calc, Q ${c}, q ${e}, R ${u}, r ${s}`,n),n}{s=r.x<t.x?t.x-a-n:n-a-t.x;let e=c*s/u,i=r.x<t.x?r.x+u-s:r.x-u+s,o=r.y<t.y?r.y+e:r.y-e;return bu.debug(`sides calc abc89, Q ${c}, q ${e}, R ${u}, r ${s}`,{_x:i,_y:o}),0===s&&(i=t.x,o=t.y),0===u&&(i=t.x),0===c&&(o=t.y),{x:i,y:o}}},"intersection"),tM=mu((e,t)=>{bu.warn("abc88 cutPathAtIntersect",e,t);let r=[],n=e[0],i=!1;return e.forEach(e=>{if(bu.info("abc88 checking point",e,t),QE(t,e)||i)bu.warn("abc88 outside",e,n),n=e,i||r.push(e);else{const o=eM(t,n,e);bu.debug("abc88 inside",e,n,o),bu.debug("abc88 intersection",o,t);let a=!1;r.forEach(e=>{a=a||e.x===o.x&&e.y===o.y}),r.some(e=>e.x===o.x&&e.y===o.y)?bu.warn("abc88 no intersect",o,r):r.push(o),i=!0}}),bu.debug("returning points",r),r},"cutPathAtIntersect");function rM(e){const t=[],r=[];for(let n=1;n<e.length-1;n++){const i=e[n-1],o=e[n],a=e[n+1];(i.x===o.x&&o.y===a.y&&Math.abs(o.x-a.x)>5&&Math.abs(o.y-i.y)>5||i.y===o.y&&o.x===a.x&&Math.abs(o.x-i.x)>5&&Math.abs(o.y-a.y)>5)&&(t.push(o),r.push(n))}return{cornerPoints:t,cornerPointPositions:r}}mu(rM,"extractCornerPoints");var nM=mu(function(e,t,r){const n=t.x-e.x,i=t.y-e.y,o=r/Math.sqrt(n*n+i*i);return{x:t.x-o*n,y:t.y-o*i}},"findAdjacentPoint"),iM=mu(function(e){const{cornerPointPositions:t}=rM(e),r=[];for(let n=0;n<e.length;n++)if(t.includes(n)){const t=e[n-1],i=e[n+1],o=e[n],a=nM(t,o,5),s=nM(i,o,5),l=s.x-a.x,c=s.y-a.y;r.push(a);const u=2*Math.sqrt(2);let h={x:o.x,y:o.y};if(Math.abs(i.x-t.x)>10&&Math.abs(i.y-t.y)>=10){bu.debug("Corner point fixing",Math.abs(i.x-t.x),Math.abs(i.y-t.y));const e=5;h=o.x===a.x?{x:l<0?a.x-e+u:a.x+e-u,y:c<0?a.y-u:a.y+u}:{x:l<0?a.x-u:a.x+u,y:c<0?a.y-e+u:a.y+e-u}}else bu.debug("Corner point skipping fixing",Math.abs(i.x-t.x),Math.abs(i.y-t.y));r.push(h,s)}else r.push(e[n]);return r},"fixCorners"),oM=mu((e,t,r)=>{const n=e-t-r,i=Math.floor(n/4);return`0 ${t} ${Array(i).fill("2 2").join(" ")} ${r}`},"generateDashArray"),aM=mu(function(e,t,r,n,i,o,a,s=!1){var l;const{handDrawnSeed:c}=$p();let u=t.points,h=!1;const d=i;var p=o;const f=[];for(const M in t.cssCompiledStyles)TC(M)||f.push(t.cssCompiledStyles[M]);bu.debug("UIO intersect check",t.points,p.x,d.x),p.intersect&&d.intersect&&!s&&(u=u.slice(1,t.points.length-1),u.unshift(d.intersect(u[0])),bu.debug("Last point UIO",t.start,"--\x3e",t.end,u[u.length-1],p,p.intersect(u[u.length-1])),u.push(p.intersect(u[u.length-1])));const g=btoa(JSON.stringify(u));t.toCluster&&(bu.info("to cluster abc88",r.get(t.toCluster)),u=tM(t.points,r.get(t.toCluster).node),h=!0),t.fromCluster&&(bu.debug("from cluster abc88",r.get(t.fromCluster),JSON.stringify(u,null,2)),u=tM(u.reverse(),r.get(t.fromCluster).node).reverse(),h=!0);let m=u.filter(e=>!Number.isNaN(e.y));m=iM(m);let y=Oy;switch(y=Ay,t.curve){case"linear":y=Ay;break;case"basis":default:y=Oy;break;case"cardinal":y=Hy;break;case"bumpX":y=By;break;case"bumpY":y=Ly;break;case"catmullRom":y=Zy;break;case"monotoneX":y=ux;break;case"monotoneY":y=hx;break;case"natural":y=fx;break;case"step":y=mx;break;case"stepAfter":y=xx;break;case"stepBefore":y=yx}const{x:x,y:b}=CC(t),v=My().x(x).y(b).curve(y);let C,w;switch(t.thickness){case"normal":default:C="edge-thickness-normal";break;case"thick":C="edge-thickness-thick";break;case"invisible":C="edge-thickness-invisible"}switch(t.pattern){case"solid":default:C+=" edge-pattern-solid";break;case"dotted":C+=" edge-pattern-dotted";break;case"dashed":C+=" edge-pattern-dashed"}let k="rounded"===t.curve?sM(cM(m,t),5):v(m);const S=Array.isArray(t.style)?t.style:[t.style];let _=S.find(e=>null==e?void 0:e.startsWith("stroke:")),T=!1;if("handDrawn"===t.look){const r=SA(e);Object.assign([],m);C+=" transition",w=fg(r.path(k,{roughness:.3,seed:c})).select("path").attr("id",t.id).attr("class"," "+C+(t.classes?" "+t.classes:"")).attr("style",S?S.reduce((e,t)=>e+";"+t,""):"");let n=w.attr("d");w.attr("d",n),e.node().appendChild(w.node())}else{const r=f.join(";"),n=S?S.reduce((e,t)=>e+t+";",""):"";let i="";t.animate&&(i=" edge-animation-fast"),t.animation&&(i=" edge-animation-"+t.animation);const o=(r?r+";"+n+";":n)+";"+(S?S.reduce((e,t)=>e+";"+t,""):"");w=e.append("path").attr("d",k).attr("id",t.id).attr("class"," "+C+(t.classes?" "+t.classes:"")+(i??"")).attr("style",o),_=null==(l=o.match(/stroke:([^;]+)/))?void 0:l[1],T=!0===t.animate||!!t.animation||r.includes("animation");const a=w.node(),s="function"==typeof a.getTotalLength?a.getTotalLength():0,c=xC[t.arrowTypeStart]||0,u=xC[t.arrowTypeEnd]||0;if("neo"===t.look&&!T){const e=`stroke-dasharray: ${"dotted"===t.pattern||"dashed"===t.pattern?oM(s,c,u):`0 ${c} ${s-c-u} ${u}`}; stroke-dashoffset: 0;`;w.attr("style",e+w.attr("style"))}}w.attr("data-edge",!0),w.attr("data-et","edge"),w.attr("data-id",t.id),w.attr("data-points",g),t.showPoints&&m.forEach(t=>{e.append("circle").style("stroke","red").style("fill","red").attr("r",1).attr("cx",t.x).attr("cy",t.y)});let A="";($p().flowchart.arrowMarkerAbsolute||$p().state.arrowMarkerAbsolute)&&(A=window.location.protocol+"//"+window.location.host+window.location.pathname+window.location.search,A=A.replace(/\(/g,"\\(").replace(/\)/g,"\\)")),bu.info("arrowTypeStart",t.arrowTypeStart),bu.info("arrowTypeEnd",t.arrowTypeEnd),WE(w,t,A,a,n,_);const P=u[Math.floor(u.length/2)];xS.isLabelCoordinateInPath(P,w.attr("d"))||(h=!0);let E={};return h&&(E.updatedPath=u),E.originalPath=t.points,E},"insertEdge");function sM(e,t){if(e.length<2)return"";let r="";const n=e.length,i=1e-5;for(let o=0;o<n;o++){const a=e[o],s=e[o-1],l=e[o+1];if(0===o)r+=`M${a.x},${a.y}`;else if(o===n-1)r+=`L${a.x},${a.y}`;else{const e=a.x-s.x,n=a.y-s.y,o=l.x-a.x,c=l.y-a.y,u=Math.hypot(e,n),h=Math.hypot(o,c);if(u<i||h<i){r+=`L${a.x},${a.y}`;continue}const d=e/u,p=n/u,f=o/h,g=c/h,m=d*f+p*g,y=Math.max(-1,Math.min(1,m)),x=Math.acos(y);if(x<i||Math.abs(Math.PI-x)<i){r+=`L${a.x},${a.y}`;continue}const b=Math.min(t/Math.sin(x/2),u/2,h/2),v=a.x-d*b,C=a.y-p*b,w=a.x+f*b,k=a.y+g*b;r+=`L${v},${C}`,r+=`Q${a.x},${a.y} ${w},${k}`}}return r}function lM(e,t){if(!e||!t)return{angle:0,deltaX:0,deltaY:0};const r=t.x-e.x,n=t.y-e.y;return{angle:Math.atan2(n,r),deltaX:r,deltaY:n}}function cM(e,t){const r=e.map(e=>({...e}));if(e.length>=2&&yC[t.arrowTypeStart]){const n=yC[t.arrowTypeStart],i=e[0],o=e[1],{angle:a}=lM(i,o),s=n*Math.cos(a),l=n*Math.sin(a);r[0].x=i.x+s,r[0].y=i.y+l}const n=e.length;if(n>=2&&yC[t.arrowTypeEnd]){const i=yC[t.arrowTypeEnd],o=e[n-1],a=e[n-2],{angle:s}=lM(a,o),l=i*Math.cos(s),c=i*Math.sin(s);r[n-1].x=o.x-l,r[n-1].y=o.y-c}return r}mu(sM,"generateRoundedPath"),mu(lM,"calculateDeltaAndAngle"),mu(cM,"applyMarkerOffsetsToPoints");var uM=mu((e,t,r,n)=>{t.forEach(t=>{hM[t](e,r,n)})},"insertMarkers"),hM={extension:mu((e,t,r)=>{bu.trace("Making markers for ",r),e.append("defs").append("marker").attr("id",r+"_"+t+"-extensionStart").attr("class","marker extension "+t).attr("refX",18).attr("refY",7).attr("markerWidth",190).attr("markerHeight",240).attr("orient","auto").append("path").attr("d","M 1,7 L18,13 V 1 Z"),e.append("defs").append("marker").attr("id",r+"_"+t+"-extensionEnd").attr("class","marker extension "+t).attr("refX",1).attr("refY",7).attr("markerWidth",20).attr("markerHeight",28).attr("orient","auto").append("path").attr("d","M 1,1 V 13 L18,7 Z")},"extension"),composition:mu((e,t,r)=>{e.append("defs").append("marker").attr("id",r+"_"+t+"-compositionStart").attr("class","marker composition "+t).attr("refX",18).attr("refY",7).attr("markerWidth",190).attr("markerHeight",240).attr("orient","auto").append("path").attr("d","M 18,7 L9,13 L1,7 L9,1 Z"),e.append("defs").append("marker").attr("id",r+"_"+t+"-compositionEnd").attr("class","marker composition "+t).attr("refX",1).attr("refY",7).attr("markerWidth",20).attr("markerHeight",28).attr("orient","auto").append("path").attr("d","M 18,7 L9,13 L1,7 L9,1 Z")},"composition"),aggregation:mu((e,t,r)=>{e.append("defs").append("marker").attr("id",r+"_"+t+"-aggregationStart").attr("class","marker aggregation "+t).attr("refX",18).attr("refY",7).attr("markerWidth",190).attr("markerHeight",240).attr("orient","auto").append("path").attr("d","M 18,7 L9,13 L1,7 L9,1 Z"),e.append("defs").append("marker").attr("id",r+"_"+t+"-aggregationEnd").attr("class","marker aggregation "+t).attr("refX",1).attr("refY",7).attr("markerWidth",20).attr("markerHeight",28).attr("orient","auto").append("path").attr("d","M 18,7 L9,13 L1,7 L9,1 Z")},"aggregation"),dependency:mu((e,t,r)=>{e.append("defs").append("marker").attr("id",r+"_"+t+"-dependencyStart").attr("class","marker dependency "+t).attr("refX",6).attr("refY",7).attr("markerWidth",190).attr("markerHeight",240).attr("orient","auto").append("path").attr("d","M 5,7 L9,13 L1,7 L9,1 Z"),e.append("defs").append("marker").attr("id",r+"_"+t+"-dependencyEnd").attr("class","marker dependency "+t).attr("refX",13).attr("refY",7).attr("markerWidth",20).attr("markerHeight",28).attr("orient","auto").append("path").attr("d","M 18,7 L9,13 L14,7 L9,1 Z")},"dependency"),lollipop:mu((e,t,r)=>{e.append("defs").append("marker").attr("id",r+"_"+t+"-lollipopStart").attr("class","marker lollipop "+t).attr("refX",13).attr("refY",7).attr("markerWidth",190).attr("markerHeight",240).attr("orient","auto").append("circle").attr("stroke","black").attr("fill","transparent").attr("cx",7).attr("cy",7).attr("r",6),e.append("defs").append("marker").attr("id",r+"_"+t+"-lollipopEnd").attr("class","marker lollipop "+t).attr("refX",1).attr("refY",7).attr("markerWidth",190).attr("markerHeight",240).attr("orient","auto").append("circle").attr("stroke","black").attr("fill","transparent").attr("cx",7).attr("cy",7).attr("r",6)},"lollipop"),point:mu((e,t,r)=>{e.append("marker").attr("id",r+"_"+t+"-pointEnd").attr("class","marker "+t).attr("viewBox","0 0 10 10").attr("refX",5).attr("refY",5).attr("markerUnits","userSpaceOnUse").attr("markerWidth",8).attr("markerHeight",8).attr("orient","auto").append("path").attr("d","M 0 0 L 10 5 L 0 10 z").attr("class","arrowMarkerPath").style("stroke-width",1).style("stroke-dasharray","1,0"),e.append("marker").attr("id",r+"_"+t+"-pointStart").attr("class","marker "+t).attr("viewBox","0 0 10 10").attr("refX",4.5).attr("refY",5).attr("markerUnits","userSpaceOnUse").attr("markerWidth",8).attr("markerHeight",8).attr("orient","auto").append("path").attr("d","M 0 5 L 10 10 L 10 0 z").attr("class","arrowMarkerPath").style("stroke-width",1).style("stroke-dasharray","1,0")},"point"),circle:mu((e,t,r)=>{e.append("marker").attr("id",r+"_"+t+"-circleEnd").attr("class","marker "+t).attr("viewBox","0 0 10 10").attr("refX",11).attr("refY",5).attr("markerUnits","userSpaceOnUse").attr("markerWidth",11).attr("markerHeight",11).attr("orient","auto").append("circle").attr("cx","5").attr("cy","5").attr("r","5").attr("class","arrowMarkerPath").style("stroke-width",1).style("stroke-dasharray","1,0"),e.append("marker").attr("id",r+"_"+t+"-circleStart").attr("class","marker "+t).attr("viewBox","0 0 10 10").attr("refX",-1).attr("refY",5).attr("markerUnits","userSpaceOnUse").attr("markerWidth",11).attr("markerHeight",11).attr("orient","auto").append("circle").attr("cx","5").attr("cy","5").attr("r","5").attr("class","arrowMarkerPath").style("stroke-width",1).style("stroke-dasharray","1,0")},"circle"),cross:mu((e,t,r)=>{e.append("marker").attr("id",r+"_"+t+"-crossEnd").attr("class","marker cross "+t).attr("viewBox","0 0 11 11").attr("refX",12).attr("refY",5.2).attr("markerUnits","userSpaceOnUse").attr("markerWidth",11).attr("markerHeight",11).attr("orient","auto").append("path").attr("d","M 1,1 l 9,9 M 10,1 l -9,9").attr("class","arrowMarkerPath").style("stroke-width",2).style("stroke-dasharray","1,0"),e.append("marker").attr("id",r+"_"+t+"-crossStart").attr("class","marker cross "+t).attr("viewBox","0 0 11 11").attr("refX",-1).attr("refY",5.2).attr("markerUnits","userSpaceOnUse").attr("markerWidth",11).attr("markerHeight",11).attr("orient","auto").append("path").attr("d","M 1,1 l 9,9 M 10,1 l -9,9").attr("class","arrowMarkerPath").style("stroke-width",2).style("stroke-dasharray","1,0")},"cross"),barb:mu((e,t,r)=>{e.append("defs").append("marker").attr("id",r+"_"+t+"-barbEnd").attr("refX",19).attr("refY",7).attr("markerWidth",20).attr("markerHeight",14).attr("markerUnits","userSpaceOnUse").attr("orient","auto").append("path").attr("d","M 19,7 L9,13 L14,7 L9,1 Z")},"barb"),only_one:mu((e,t,r)=>{e.append("defs").append("marker").attr("id",r+"_"+t+"-onlyOneStart").attr("class","marker onlyOne "+t).attr("refX",0).attr("refY",9).attr("markerWidth",18).attr("markerHeight",18).attr("orient","auto").append("path").attr("d","M9,0 L9,18 M15,0 L15,18"),e.append("defs").append("marker").attr("id",r+"_"+t+"-onlyOneEnd").attr("class","marker onlyOne "+t).attr("refX",18).attr("refY",9).attr("markerWidth",18).attr("markerHeight",18).attr("orient","auto").append("path").attr("d","M3,0 L3,18 M9,0 L9,18")},"only_one"),zero_or_one:mu((e,t,r)=>{const n=e.append("defs").append("marker").attr("id",r+"_"+t+"-zeroOrOneStart").attr("class","marker zeroOrOne "+t).attr("refX",0).attr("refY",9).attr("markerWidth",30).attr("markerHeight",18).attr("orient","auto");n.append("circle").attr("fill","white").attr("cx",21).attr("cy",9).attr("r",6),n.append("path").attr("d","M9,0 L9,18");const i=e.append("defs").append("marker").attr("id",r+"_"+t+"-zeroOrOneEnd").attr("class","marker zeroOrOne "+t).attr("refX",30).attr("refY",9).attr("markerWidth",30).attr("markerHeight",18).attr("orient","auto");i.append("circle").attr("fill","white").attr("cx",9).attr("cy",9).attr("r",6),i.append("path").attr("d","M21,0 L21,18")},"zero_or_one"),one_or_more:mu((e,t,r)=>{e.append("defs").append("marker").attr("id",r+"_"+t+"-oneOrMoreStart").attr("class","marker oneOrMore "+t).attr("refX",18).attr("refY",18).attr("markerWidth",45).attr("markerHeight",36).attr("orient","auto").append("path").attr("d","M0,18 Q 18,0 36,18 Q 18,36 0,18 M42,9 L42,27"),e.append("defs").append("marker").attr("id",r+"_"+t+"-oneOrMoreEnd").attr("class","marker oneOrMore "+t).attr("refX",27).attr("refY",18).attr("markerWidth",45).attr("markerHeight",36).attr("orient","auto").append("path").attr("d","M3,9 L3,27 M9,18 Q27,0 45,18 Q27,36 9,18")},"one_or_more"),zero_or_more:mu((e,t,r)=>{const n=e.append("defs").append("marker").attr("id",r+"_"+t+"-zeroOrMoreStart").attr("class","marker zeroOrMore "+t).attr("refX",18).attr("refY",18).attr("markerWidth",57).attr("markerHeight",36).attr("orient","auto");n.append("circle").attr("fill","white").attr("cx",48).attr("cy",18).attr("r",6),n.append("path").attr("d","M0,18 Q18,0 36,18 Q18,36 0,18");const i=e.append("defs").append("marker").attr("id",r+"_"+t+"-zeroOrMoreEnd").attr("class","marker zeroOrMore "+t).attr("refX",39).attr("refY",18).attr("markerWidth",57).attr("markerHeight",36).attr("orient","auto");i.append("circle").attr("fill","white").attr("cx",9).attr("cy",18).attr("r",6),i.append("path").attr("d","M21,18 Q39,0 57,18 Q39,36 21,18")},"zero_or_more"),requirement_arrow:mu((e,t,r)=>{e.append("defs").append("marker").attr("id",r+"_"+t+"-requirement_arrowEnd").attr("refX",20).attr("refY",10).attr("markerWidth",20).attr("markerHeight",20).attr("orient","auto").append("path").attr("d","M0,0\n L20,10\n M20,10\n L0,20")},"requirement_arrow"),requirement_contains:mu((e,t,r)=>{const n=e.append("defs").append("marker").attr("id",r+"_"+t+"-requirement_containsStart").attr("refX",0).attr("refY",10).attr("markerWidth",20).attr("markerHeight",20).attr("orient","auto").append("g");n.append("circle").attr("cx",10).attr("cy",10).attr("r",9).attr("fill","none"),n.append("line").attr("x1",1).attr("x2",19).attr("y1",10).attr("y2",10),n.append("line").attr("y1",1).attr("y2",19).attr("x1",10).attr("x2",10)},"requirement_contains")},dM=uM,pM={common:yp,getConfig:Dd,insertCluster:WA,insertEdge:aM,insertEdgeLabel:YE,insertMarkers:dM,insertNode:RE,interpolateToCurve:Wk,labelHelper:_A,log:bu,positionEdgeLabel:KE},fM={},gM=mu(e=>{for(const t of e)fM[t.name]=t},"registerLayoutLoaders");mu(()=>{gM([{name:"dagre",loader:mu(async()=>await Promise.resolve().then(()=>require("./dagre-6UL2VRFP-FmOJGmX_.cjs")),"loader")},{name:"cose-bilkent",loader:mu(async()=>await Promise.resolve().then(()=>require("./cose-bilkent-S5V4N54A-BcLbJZT7.cjs")),"loader")}])},"registerDefaultLayoutLoaders")();var mM=mu(async(e,t)=>{if(!(e.layoutAlgorithm in fM))throw new Error(`Unknown layout algorithm: ${e.layoutAlgorithm}`);const r=fM[e.layoutAlgorithm];return(await r.loader()).render(e,t,pM,{algorithm:r.algorithm})},"render"),yM=mu((e="",{fallback:t="dagre"}={})=>{if(e in fM)return e;if(t in fM)return bu.warn(`Layout algorithm ${e} is not registered. Using ${t} as fallback.`),t;throw new Error(`Both layout algorithms ${e} and ${t} are not registered.`)},"getRegisteredLayoutAlgorithm"),xM="comm",bM="rule",vM="decl",CM=Math.abs,wM=String.fromCharCode;function kM(e){return e.trim()}function SM(e,t,r){return e.replace(t,r)}function _M(e,t,r){return e.indexOf(t,r)}function TM(e,t){return 0|e.charCodeAt(t)}function AM(e,t,r){return e.slice(t,r)}function PM(e){return e.length}function EM(e,t){return t.push(e),e}var MM=1,IM=1,BM=0,LM=0,jM=0,NM="";function DM(e,t,r,n,i,o,a,s){return{value:e,root:t,parent:r,type:n,props:i,children:o,line:MM,column:IM,length:a,return:"",siblings:s}}function OM(){return jM=LM>0?TM(NM,--LM):0,IM--,10===jM&&(IM=1,MM--),jM}function FM(){return jM=LM<BM?TM(NM,LM++):0,IM++,10===jM&&(IM=1,MM++),jM}function RM(){return TM(NM,LM)}function $M(){return LM}function zM(e,t){return AM(NM,e,t)}function VM(e){switch(e){case 0:case 9:case 10:case 13:case 32:return 5;case 33:case 43:case 44:case 47:case 62:case 64:case 126:case 59:case 123:case 125:return 4;case 58:return 3;case 34:case 39:case 40:case 91:return 2;case 41:case 93:return 1}return 0}function WM(e){return kM(zM(LM-1,UM(91===e?e+2:40===e?e+1:e)))}function HM(e){for(;(jM=RM())&&jM<33;)FM();return VM(e)>2||VM(jM)>3?"":" "}function qM(e,t){for(;--t&&FM()&&!(jM<48||jM>102||jM>57&&jM<65||jM>70&&jM<97););return zM(e,$M()+(t<6&&32==RM()&&32==FM()))}function UM(e){for(;FM();)switch(jM){case e:return LM;case 34:case 39:34!==e&&39!==e&&UM(jM);break;case 40:41===e&&UM(e);break;case 92:FM()}return LM}function GM(e,t){for(;FM()&&e+jM!==57&&(e+jM!==84||47!==RM()););return"/*"+zM(t,LM-1)+"*"+wM(47===e?e:FM())}function XM(e){for(;!VM(RM());)FM();return zM(e,LM)}function JM(e){return function(e){return NM="",e}(YM("",null,null,null,[""],e=function(e){return MM=IM=1,BM=PM(NM=e),LM=0,[]}(e),0,[0],e))}function YM(e,t,r,n,i,o,a,s,l){for(var c=0,u=0,h=a,d=0,p=0,f=0,g=1,m=1,y=1,x=0,b="",v=i,C=o,w=n,k=b;m;)switch(f=x,x=FM()){case 40:if(108!=f&&58==TM(k,h-1)){-1!=_M(k+=SM(WM(x),"&","&\f"),"&\f",CM(c?s[c-1]:0))&&(y=-1);break}case 34:case 39:case 91:k+=WM(x);break;case 9:case 10:case 13:case 32:k+=HM(f);break;case 92:k+=qM($M()-1,7);continue;case 47:switch(RM()){case 42:case 47:EM(KM(GM(FM(),$M()),t,r,l),l),5!=VM(f||1)&&5!=VM(RM()||1)||!PM(k)||" "===AM(k,-1,void 0)||(k+=" ");break;default:k+="/"}break;case 123*g:s[c++]=PM(k)*y;case 125*g:case 59:case 0:switch(x){case 0:case 125:m=0;case 59+u:-1==y&&(k=SM(k,/\f/g,"")),p>0&&(PM(k)-h||0===g&&47===f)&&EM(p>32?QM(k+";",n,r,h-1,l):QM(SM(k," ","")+";",n,r,h-2,l),l);break;case 59:k+=";";default:if(EM(w=ZM(k,t,r,c,u,i,s,b,v=[],C=[],h,o),o),123===x)if(0===u)YM(k,t,w,w,v,o,h,s,C);else{switch(d){case 99:if(110===TM(k,3))break;case 108:if(97===TM(k,2))break;default:u=0;case 100:case 109:case 115:}u?YM(e,w,w,n&&EM(ZM(e,w,w,0,0,i,s,b,i,v=[],h,C),C),i,C,h,s,n?v:C):YM(k,w,w,w,[""],C,0,s,C)}}c=u=p=0,g=y=1,b=k="",h=a;break;case 58:h=1+PM(k),p=f;default:if(g<1)if(123==x)--g;else if(125==x&&0==g++&&125==OM())continue;switch(k+=wM(x),x*g){case 38:y=u>0?1:(k+="\f",-1);break;case 44:s[c++]=(PM(k)-1)*y,y=1;break;case 64:45===RM()&&(k+=WM(FM())),d=RM(),u=h=PM(b=k+=XM($M())),x++;break;case 45:45===f&&2==PM(k)&&(g=0)}}return o}function ZM(e,t,r,n,i,o,a,s,l,c,u,h){for(var d=i-1,p=0===i?o:[""],f=function(e){return e.length}(p),g=0,m=0,y=0;g<n;++g)for(var x=0,b=AM(e,d+1,d=CM(m=a[g])),v=e;x<f;++x)(v=kM(m>0?p[x]+" "+b:SM(b,/&\f/g,p[x])))&&(l[y++]=v);return DM(e,t,r,0===i?bM:s,l,c,u,h)}function KM(e,t,r,n){return DM(e,t,r,xM,wM(jM),AM(e,2,-2),0,n)}function QM(e,t,r,n,i){return DM(e,t,r,vM,AM(e,0,n),AM(e,n+1,-1),n,i)}function eI(e,t){for(var r="",n=0;n<e.length;n++)r+=t(e[n],n,e,t)||"";return r}function tI(e,t,r,n){switch(e.type){case"@layer":if(e.children.length)break;case"@import":case"@namespace":case vM:return e.return=e.return||e.value;case xM:return"";case"@keyframes":return e.return=e.value+"{"+eI(e.children,n)+"}";case bM:if(!PM(e.value=e.props.join(",")))return""}return PM(r=eI(e.children,n))?e.return=e.value+"{"+r+"}":""}var rI=Dw(Object.keys,Object),nI=Object.prototype.hasOwnProperty;function iI(e){if(!Rw(e))return rI(e);var t=[];for(var r in Object(e))nI.call(e,r)&&"constructor"!=r&&t.push(r);return t}var oI=sw(FC,"DataView"),aI=sw(FC,"Promise"),sI=sw(FC,"Set"),lI=sw(FC,"WeakMap"),cI="[object Map]",uI="[object Promise]",hI="[object Set]",dI="[object WeakMap]",pI="[object DataView]",fI=QC(oI),gI=QC(mw),mI=QC(aI),yI=QC(sI),xI=QC(lI);exports.getTag=UC,(oI&&exports.getTag(new oI(new ArrayBuffer(1)))!=pI||mw&&exports.getTag(new mw)!=cI||aI&&exports.getTag(aI.resolve())!=uI||sI&&exports.getTag(new sI)!=hI||lI&&exports.getTag(new lI)!=dI)&&(exports.getTag=function(e){var t=UC(e),r="[object Object]"==t?e.constructor:void 0,n=r?QC(r):"";if(n)switch(n){case fI:return pI;case gI:return cI;case mI:return uI;case yI:return hI;case xI:return dI}return t});var bI=Object.prototype.hasOwnProperty;function vI(e){if(null==e)return!0;if(Jw(e)&&(Gw(e)||"string"==typeof e||"function"==typeof e.splice||Qw(e)||dk(e)||Uw(e)))return!e.length;var t=exports.getTag(e);if("[object Map]"==t||"[object Set]"==t)return!e.size;if(Rw(e))return!iI(e).length;for(var r in e)if(bI.call(e,r))return!1;return!0}var CI={id:"c4",detector:mu(e=>/^\s*C4Context|C4Container|C4Component|C4Dynamic|C4Deployment/.test(e),"detector"),loader:mu(async()=>{const{diagram:e}=await Promise.resolve().then(()=>require("./c4Diagram-YG6GDRKO-0rSYap-S.cjs"));return{id:"c4",diagram:e}},"loader")},wI="flowchart",kI={id:wI,detector:mu((e,t)=>{var r,n;return"dagre-wrapper"!==(null==(r=null==t?void 0:t.flowchart)?void 0:r.defaultRenderer)&&"elk"!==(null==(n=null==t?void 0:t.flowchart)?void 0:n.defaultRenderer)&&/^\s*graph/.test(e)},"detector"),loader:mu(async()=>{const{diagram:e}=await Promise.resolve().then(()=>require("./flowDiagram-NV44I4VS-DOcXDmk8.cjs"));return{id:wI,diagram:e}},"loader")},SI="flowchart-v2",_I={id:SI,detector:mu((e,t)=>{var r,n,i;return"dagre-d3"!==(null==(r=null==t?void 0:t.flowchart)?void 0:r.defaultRenderer)&&("elk"===(null==(n=null==t?void 0:t.flowchart)?void 0:n.defaultRenderer)&&(t.layout="elk"),!(!/^\s*graph/.test(e)||"dagre-wrapper"!==(null==(i=null==t?void 0:t.flowchart)?void 0:i.defaultRenderer))||/^\s*flowchart/.test(e))},"detector"),loader:mu(async()=>{const{diagram:e}=await Promise.resolve().then(()=>require("./flowDiagram-NV44I4VS-DOcXDmk8.cjs"));return{id:SI,diagram:e}},"loader")},TI={id:"er",detector:mu(e=>/^\s*erDiagram/.test(e),"detector"),loader:mu(async()=>{const{diagram:e}=await Promise.resolve().then(()=>require("./erDiagram-Q2GNP2WA-DAzex-RZ.cjs"));return{id:"er",diagram:e}},"loader")},AI="gitGraph",PI={id:AI,detector:mu(e=>/^\s*gitGraph/.test(e),"detector"),loader:mu(async()=>{const{diagram:e}=await Promise.resolve().then(()=>require("./gitGraphDiagram-V2S2FVAM-D4G2FRg-.cjs"));return{id:AI,diagram:e}},"loader")},EI="gantt",MI={id:EI,detector:mu(e=>/^\s*gantt/.test(e),"detector"),loader:mu(async()=>{const{diagram:e}=await Promise.resolve().then(()=>require("./ganttDiagram-JELNMOA3-oeOE4Au1.cjs"));return{id:EI,diagram:e}},"loader")},II="info",BI={id:II,detector:mu(e=>/^\s*info/.test(e),"detector"),loader:mu(async()=>{const{diagram:e}=await Promise.resolve().then(()=>require("./infoDiagram-HS3SLOUP-l61UBAGu.cjs"));return{id:II,diagram:e}},"loader")},LI={id:"pie",detector:mu(e=>/^\s*pie/.test(e),"detector"),loader:mu(async()=>{const{diagram:e}=await Promise.resolve().then(()=>require("./pieDiagram-ADFJNKIX-C8b4kPLp.cjs"));return{id:"pie",diagram:e}},"loader")},jI="quadrantChart",NI={id:jI,detector:mu(e=>/^\s*quadrantChart/.test(e),"detector"),loader:mu(async()=>{const{diagram:e}=await Promise.resolve().then(()=>require("./quadrantDiagram-AYHSOK5B-Bb99yQJL.cjs"));return{id:jI,diagram:e}},"loader")},DI="xychart",OI={id:DI,detector:mu(e=>/^\s*xychart(-beta)?/.test(e),"detector"),loader:mu(async()=>{const{diagram:e}=await Promise.resolve().then(()=>require("./xychartDiagram-PRI3JC2R-CXT2FhOm.cjs"));return{id:DI,diagram:e}},"loader")},FI="requirement",RI={id:FI,detector:mu(e=>/^\s*requirement(Diagram)?/.test(e),"detector"),loader:mu(async()=>{const{diagram:e}=await Promise.resolve().then(()=>require("./requirementDiagram-UZGBJVZJ-BeLfR5tA.cjs"));return{id:FI,diagram:e}},"loader")},$I="sequence",zI={id:$I,detector:mu(e=>/^\s*sequenceDiagram/.test(e),"detector"),loader:mu(async()=>{const{diagram:e}=await Promise.resolve().then(()=>require("./sequenceDiagram-WL72ISMW-CaSRrEHR.cjs"));return{id:$I,diagram:e}},"loader")},VI="class",WI={id:VI,detector:mu((e,t)=>{var r;return"dagre-wrapper"!==(null==(r=null==t?void 0:t.class)?void 0:r.defaultRenderer)&&/^\s*classDiagram/.test(e)},"detector"),loader:mu(async()=>{const{diagram:e}=await Promise.resolve().then(()=>require("./classDiagram-2ON5EDUG-BGUaVc1W.cjs"));return{id:VI,diagram:e}},"loader")},HI="classDiagram",qI={id:HI,detector:mu((e,t)=>{var r;return!(!/^\s*classDiagram/.test(e)||"dagre-wrapper"!==(null==(r=null==t?void 0:t.class)?void 0:r.defaultRenderer))||/^\s*classDiagram-v2/.test(e)},"detector"),loader:mu(async()=>{const{diagram:e}=await Promise.resolve().then(()=>require("./classDiagram-v2-WZHVMYZB-BGUaVc1W.cjs"));return{id:HI,diagram:e}},"loader")},UI="state",GI={id:UI,detector:mu((e,t)=>{var r;return"dagre-wrapper"!==(null==(r=null==t?void 0:t.state)?void 0:r.defaultRenderer)&&/^\s*stateDiagram/.test(e)},"detector"),loader:mu(async()=>{const{diagram:e}=await Promise.resolve().then(()=>require("./stateDiagram-FKZM4ZOC-BETxyYxX.cjs"));return{id:UI,diagram:e}},"loader")},XI="stateDiagram",JI={id:XI,detector:mu((e,t)=>{var r;return!!/^\s*stateDiagram-v2/.test(e)||!(!/^\s*stateDiagram/.test(e)||"dagre-wrapper"!==(null==(r=null==t?void 0:t.state)?void 0:r.defaultRenderer))},"detector"),loader:mu(async()=>{const{diagram:e}=await Promise.resolve().then(()=>require("./stateDiagram-v2-4FDKWEC3-B4AjT1wB.cjs"));return{id:XI,diagram:e}},"loader")},YI="journey",ZI={id:YI,detector:mu(e=>/^\s*journey/.test(e),"detector"),loader:mu(async()=>{const{diagram:e}=await Promise.resolve().then(()=>require("./journeyDiagram-XKPGCS4Q-DDFQr_sf.cjs"));return{id:YI,diagram:e}},"loader")},KI={draw:mu((e,t,r)=>{bu.debug("rendering svg for syntax error\n");const n=vx(t),i=n.append("g");n.attr("viewBox","0 0 2412 512"),vp(n,100,512,!0),i.append("path").attr("class","error-icon").attr("d","m411.313,123.313c6.25-6.25 6.25-16.375 0-22.625s-16.375-6.25-22.625,0l-32,32-9.375,9.375-20.688-20.688c-12.484-12.5-32.766-12.5-45.25,0l-16,16c-1.261,1.261-2.304,2.648-3.31,4.051-21.739-8.561-45.324-13.426-70.065-13.426-105.867,0-192,86.133-192,192s86.133,192 192,192 192-86.133 192-192c0-24.741-4.864-48.327-13.426-70.065 1.402-1.007 2.79-2.049 4.051-3.31l16-16c12.5-12.492 12.5-32.758 0-45.25l-20.688-20.688 9.375-9.375 32.001-31.999zm-219.313,100.687c-52.938,0-96,43.063-96,96 0,8.836-7.164,16-16,16s-16-7.164-16-16c0-70.578 57.422-128 128-128 8.836,0 16,7.164 16,16s-7.164,16-16,16z"),i.append("path").attr("class","error-icon").attr("d","m459.02,148.98c-6.25-6.25-16.375-6.25-22.625,0s-6.25,16.375 0,22.625l16,16c3.125,3.125 7.219,4.688 11.313,4.688 4.094,0 8.188-1.563 11.313-4.688 6.25-6.25 6.25-16.375 0-22.625l-16.001-16z"),i.append("path").attr("class","error-icon").attr("d","m340.395,75.605c3.125,3.125 7.219,4.688 11.313,4.688 4.094,0 8.188-1.563 11.313-4.688 6.25-6.25 6.25-16.375 0-22.625l-16-16c-6.25-6.25-16.375-6.25-22.625,0s-6.25,16.375 0,22.625l15.999,16z"),i.append("path").attr("class","error-icon").attr("d","m400,64c8.844,0 16-7.164 16-16v-32c0-8.836-7.156-16-16-16-8.844,0-16,7.164-16,16v32c0,8.836 7.156,16 16,16z"),i.append("path").attr("class","error-icon").attr("d","m496,96.586h-32c-8.844,0-16,7.164-16,16 0,8.836 7.156,16 16,16h32c8.844,0 16-7.164 16-16 0-8.836-7.156-16-16-16z"),i.append("path").attr("class","error-icon").attr("d","m436.98,75.605c3.125,3.125 7.219,4.688 11.313,4.688 4.094,0 8.188-1.563 11.313-4.688l32-32c6.25-6.25 6.25-16.375 0-22.625s-16.375-6.25-22.625,0l-32,32c-6.251,6.25-6.251,16.375-0.001,22.625z"),i.append("text").attr("class","error-text").attr("x",1440).attr("y",250).attr("font-size","150px").style("text-anchor","middle").text("Syntax error in text"),i.append("text").attr("class","error-text").attr("x",1250).attr("y",400).attr("font-size","100px").style("text-anchor","middle").text(`mermaid version ${r}`)},"draw")},QI=KI,eB={db:{},renderer:KI,parser:{parse:mu(()=>{},"parse")}},tB="flowchart-elk",rB={id:tB,detector:mu((e,t={})=>{var r;return!!(/^\s*flowchart-elk/.test(e)||/^\s*(flowchart|graph)/.test(e)&&"elk"===(null==(r=null==t?void 0:t.flowchart)?void 0:r.defaultRenderer))&&(t.layout="elk",!0)},"detector"),loader:mu(async()=>{const{diagram:e}=await Promise.resolve().then(()=>require("./flowDiagram-NV44I4VS-DOcXDmk8.cjs"));return{id:tB,diagram:e}},"loader")},nB="timeline",iB={id:nB,detector:mu(e=>/^\s*timeline/.test(e),"detector"),loader:mu(async()=>{const{diagram:e}=await Promise.resolve().then(()=>require("./timeline-definition-IT6M3QCI-CsJvwNrg.cjs"));return{id:nB,diagram:e}},"loader")},oB="mindmap",aB={id:oB,detector:mu(e=>/^\s*mindmap/.test(e),"detector"),loader:mu(async()=>{const{diagram:e}=await Promise.resolve().then(()=>require("./mindmap-definition-VGOIOE7T-BonbrEly.cjs"));return{id:oB,diagram:e}},"loader")},sB="kanban",lB={id:sB,detector:mu(e=>/^\s*kanban/.test(e),"detector"),loader:mu(async()=>{const{diagram:e}=await Promise.resolve().then(()=>require("./kanban-definition-3W4ZIXB7-Yh2cXBd5.cjs"));return{id:sB,diagram:e}},"loader")},cB="sankey",uB={id:cB,detector:mu(e=>/^\s*sankey(-beta)?/.test(e),"detector"),loader:mu(async()=>{const{diagram:e}=await Promise.resolve().then(()=>require("./sankeyDiagram-TZEHDZUN-T1lqY3ke.cjs"));return{id:cB,diagram:e}},"loader")},hB="packet",dB={id:hB,detector:mu(e=>/^\s*packet(-beta)?/.test(e),"detector"),loader:mu(async()=>{const{diagram:e}=await Promise.resolve().then(()=>require("./diagram-S2PKOQOG-Cob2HIrt.cjs"));return{id:hB,diagram:e}},"loader")},pB="radar",fB={id:pB,detector:mu(e=>/^\s*radar-beta/.test(e),"detector"),loader:mu(async()=>{const{diagram:e}=await Promise.resolve().then(()=>require("./diagram-QEK2KX5R-NQiK3YZe.cjs"));return{id:pB,diagram:e}},"loader")},gB="block",mB={id:gB,detector:mu(e=>/^\s*block(-beta)?/.test(e),"detector"),loader:mu(async()=>{const{diagram:e}=await Promise.resolve().then(()=>require("./blockDiagram-VD42YOAC-CXUX1_9K.cjs"));return{id:gB,diagram:e}},"loader")},yB="architecture",xB={id:yB,detector:mu(e=>/^\s*architecture/.test(e),"detector"),loader:mu(async()=>{const{diagram:e}=await Promise.resolve().then(()=>require("./architectureDiagram-VXUJARFQ-C7K57uon.cjs"));return{id:yB,diagram:e}},"loader")},bB="treemap",vB={id:bB,detector:mu(e=>/^\s*treemap/.test(e),"detector"),loader:mu(async()=>{const{diagram:e}=await Promise.resolve().then(()=>require("./diagram-PSM6KHXK-BZxXJahR.cjs"));return{id:bB,diagram:e}},"loader")},CB=!1,wB=mu(()=>{CB||(CB=!0,Gp("error",eB,e=>"error"===e.toLowerCase().trim()),Gp("---",{db:{clear:mu(()=>{},"clear")},styles:{},renderer:{draw:mu(()=>{},"draw")},parser:{parse:mu(()=>{throw new Error("Diagrams beginning with --- are not valid. If you were trying to use a YAML front-matter, please ensure that you've correctly opened and closed the YAML front-matter with un-indented `---` blocks")},"parse")},init:mu(()=>null,"init")},e=>e.toLowerCase().trimStart().startsWith("---")),td(rB,aB,xB),td(CI,lB,qI,WI,TI,MI,BI,LI,RI,zI,_I,kI,iB,PI,JI,GI,ZI,NI,uB,dB,OI,mB,fB,vB))},"addDiagrams"),kB=mu(async()=>{bu.debug("Loading registered diagrams");const e=(await Promise.allSettled(Object.entries(Qh).map(async([e,{detector:t,loader:r}])=>{if(r)try{Xp(e)}catch{try{const{diagram:e,id:n}=await r();Gp(n,e,t)}catch(n){throw bu.error(`Failed to load external diagram with key ${e}. Removing from detectors.`),delete Qh[e],n}}}))).filter(e=>"rejected"===e.status);if(e.length>0){bu.error(`Failed to load ${e.length} external diagrams`);for(const t of e)bu.error(t);throw new Error(`Failed to load ${e.length} external diagrams`)}},"loadRegisteredDiagrams");function SB(e,t){e.attr("role","graphics-document document"),""!==t&&e.attr("aria-roledescription",t)}function _B(e,t,r,n){if(void 0!==e.insert){if(r){const t=`chart-desc-${n}`;e.attr("aria-describedby",t),e.insert("desc",":first-child").attr("id",t).text(r)}if(t){const r=`chart-title-${n}`;e.attr("aria-labelledby",r),e.insert("title",":first-child").attr("id",r).text(t)}}}mu(SB,"setA11yDiagramInfo"),mu(_B,"addSVGa11yTitleDescription");var TB=(mu(g=class{constructor(e,t,r,n,i){this.type=e,this.text=t,this.db=r,this.parser=n,this.renderer=i}static async fromText(e,t={}){var r,n;const i=Dd(),o=ed(e,i);e=bS(e)+"\n";try{Xp(o)}catch{const e=nd(o);if(!e)throw new Kh(`Diagram ${o} not found.`);const{id:t,diagram:r}=await e();Gp(t,r)}const{db:a,parser:s,renderer:l,init:c}=Xp(o);return s.parser&&(s.parser.yy=a),null==(r=a.clear)||r.call(a),null==c||c(i),t.title&&(null==(n=a.setDiagramTitle)||n.call(a,t.title)),await s.parse(e),new g(o,e,a,s,l)}async render(e,t){await this.renderer.draw(this.text,e,t,this)}getParser(){return this.parser}getType(){return this.type}},"Diagram"),g),AB=[],PB=mu(()=>{AB.forEach(e=>{e()}),AB=[]},"attachFunctions"),EB=mu(e=>e.replace(/^\s*%%(?!{)[^\n]+\n?/gm,"").trimStart(),"cleanupComments");function MB(e){const t=e.match(Jh);if(!t)return{text:e,metadata:{}};let r=mC(t[1],{schema:gC})??{};r="object"!=typeof r||Array.isArray(r)?{}:r;const n={};return r.displayMode&&(n.displayMode=r.displayMode.toString()),r.title&&(n.title=r.title.toString()),r.config&&(n.config=r.config),{text:e.slice(t[0].length),metadata:n}}mu(MB,"extractFrontMatter");var IB=mu(e=>e.replace(/\r\n?/g,"\n").replace(/<(\w+)([^>]*)>/g,(e,t,r)=>"<"+t+r.replace(/="([^"]*)"/g,"='$1'")+">"),"cleanupText"),BB=mu(e=>{const{text:t,metadata:r}=MB(e),{displayMode:n,title:i,config:o={}}=r;return n&&(o.gantt||(o.gantt={}),o.gantt.displayMode=n),{title:i,config:o,text:t}},"processFrontmatter"),LB=mu(e=>{const t=xS.detectInit(e)??{},r=xS.detectDirective(e,"wrap");return Array.isArray(r)?t.wrap=r.some(({type:e})=>"wrap"===e):"wrap"===(null==r?void 0:r.type)&&(t.wrap=!0),{text:zk(e),directive:t}},"processDirectives");function jB(e){const t=IB(e),r=BB(t),n=LB(r.text),i=yS(r.config,n.directive);return{code:e=EB(n.text),title:r.title,config:i}}function NB(e){const t=(new TextEncoder).encode(e),r=Array.from(t,e=>String.fromCodePoint(e)).join("");return btoa(r)}mu(jB,"preprocessDiagram"),mu(NB,"toBase64");var DB=["foreignobject"],OB=["dominant-baseline"];function FB(e){const t=jB(e);return Rd(),Fd(t.config??{}),t}async function RB(e,t){wB();try{const{code:t,config:r}=FB(e);return{diagramType:(await YB(t)).type,config:r}}catch(r){if(null==t?void 0:t.suppressErrors)return!1;throw r}}mu(FB,"processAndSetConfigs"),mu(RB,"parse");var $B=mu((e,t,r=[])=>`\n.${e} ${t} { ${r.join(" !important; ")} !important; }`,"cssImportantStyles"),zB=mu((e,t=new Map)=>{var r;let n="";if(void 0!==e.themeCSS&&(n+=`\n${e.themeCSS}`),void 0!==e.fontFamily&&(n+=`\n:root { --mermaid-font-family: ${e.fontFamily}}`),void 0!==e.altFontFamily&&(n+=`\n:root { --mermaid-alt-font-family: ${e.altFontFamily}}`),t instanceof Map){const i=e.htmlLabels??(null==(r=e.flowchart)?void 0:r.htmlLabels)?["> *","span"]:["rect","polygon","ellipse","circle","path"];t.forEach(e=>{vI(e.styles)||i.forEach(t=>{n+=$B(e.id,t,e.styles)}),vI(e.textStyles)||(n+=$B(e.id,"tspan",((null==e?void 0:e.textStyles)||[]).map(e=>e.replace("color","fill"))))})}return n},"createCssStyles"),VB=mu((e,t,r,n)=>{const i=zB(e,r);return eI(JM(`${n}{${_p(t,i,e.themeVariables)}}`),tI)},"createUserStyles"),WB=mu((e="",t,r)=>{let n=e;return r||t||(n=n.replace(/marker-end="url\([\d+./:=?A-Za-z-]*?#/g,'marker-end="url(#')),n=vS(n),n=n.replace(/<br>/g,"<br/>"),n},"cleanUpSvgCode"),HB=mu((e="",t)=>{var r,n;return`<iframe style="width:100%;height:${(null==(n=null==(r=null==t?void 0:t.viewBox)?void 0:r.baseVal)?void 0:n.height)?t.viewBox.baseVal.height+"px":"100%"};border:0;margin:0;" src="data:text/html;charset=UTF-8;base64,${NB(`<body style="margin:0">${e}</body>`)}" sandbox="allow-top-navigation-by-user-activation allow-popups">\n The "iframe" tag is not supported by your browser.\n</iframe>`},"putIntoIFrame"),qB=mu((e,t,r,n,i)=>{const o=e.append("div");o.attr("id",r),n&&o.attr("style",n);const a=o.append("svg").attr("id",t).attr("width","100%").attr("xmlns","http://www.w3.org/2000/svg");return i&&a.attr("xmlns:xlink",i),a.append("g"),e},"appendDivSvgG");function UB(e,t){return e.append("iframe").attr("id",t).attr("style","width: 100%; height: 100%;").attr("sandbox","")}mu(UB,"sandboxedIframe");var GB=mu((e,t,r,n)=>{var i,o,a;null==(i=e.getElementById(t))||i.remove(),null==(o=e.getElementById(r))||o.remove(),null==(a=e.getElementById(n))||a.remove()},"removeExistingElements"),XB=mu(async function(e,t,r){var n,i,o,a,s,l;wB();const c=FB(t);t=c.code;const u=Dd();bu.debug(u),t.length>((null==u?void 0:u.maxTextSize)??5e4)&&(t="graph TB;a[Maximum text size in diagram exceeded];style a fill:#faa");const h="#"+e,d="i"+e,p="#"+d,f="d"+e,g="#"+f,m=mu(()=>{const e=fg(x?p:g).node();e&&"remove"in e&&e.remove()},"removeTempElements");let y=fg("body");const x="sandbox"===u.securityLevel,b="loose"===u.securityLevel,v=u.fontFamily;if(void 0!==r){if(r&&(r.innerHTML=""),x){const e=UB(fg(r),d);y=fg(e.nodes()[0].contentDocument.body),y.node().style.margin=0}else y=fg(r);qB(y,e,f,`font-family: ${v}`,"http://www.w3.org/1999/xlink")}else{if(GB(document,e,f,d),x){const e=UB(fg("body"),d);y=fg(e.nodes()[0].contentDocument.body),y.node().style.margin=0}else y=fg("body");qB(y,e,f)}let C,w;try{C=await TB.fromText(t,{title:c.title})}catch(I){if(u.suppressErrorRendering)throw m(),I;C=await TB.fromText("error"),w=I}const k=y.select(g).node(),S=C.type,_=k.firstChild,T=_.firstChild,A=null==(i=(n=C.renderer).getClasses)?void 0:i.call(n,t,C),P=VB(u,S,A,h),E=document.createElement("style");E.innerHTML=P,_.insertBefore(E,T);try{await C.renderer.draw(t,e,du.version,C)}catch(B){throw u.suppressErrorRendering?m():QI.draw(t,e,du.version),B}ZB(S,y.select(`${g} svg`),null==(a=(o=C.db).getAccTitle)?void 0:a.call(o),null==(l=(s=C.db).getAccDescription)?void 0:l.call(s)),y.select(`[id="${e}"]`).selectAll("foreignobject > *").attr("xmlns","http://www.w3.org/1999/xhtml");let M=y.select(g).node().innerHTML;if(bu.debug("config.arrowMarkerAbsolute",u.arrowMarkerAbsolute),M=WB(M,x,ip(u.arrowMarkerAbsolute)),x){const e=y.select(g+" svg").node();M=HB(M,e)}else b||(M=Xh.sanitize(M,{ADD_TAGS:DB,ADD_ATTR:OB,HTML_INTEGRATION_POINTS:{foreignobject:!0}}));if(PB(),w)throw w;return m(),{diagramType:S,svg:M,bindFunctions:C.db.bindFunctions}},"render");function JB(e={}){var t;const r=od({},e);(null==r?void 0:r.fontFamily)&&!(null==(t=r.themeVariables)?void 0:t.fontFamily)&&(r.themeVariables||(r.themeVariables={}),r.themeVariables.fontFamily=r.fontFamily),Bd(r),(null==r?void 0:r.theme)&&r.theme in xd?r.themeVariables=xd[r.theme].getThemeVariables(r.themeVariables):r&&(r.themeVariables=xd.default.getThemeVariables(r.themeVariables));const n="object"==typeof r?Id(r):jd();vu(n.logLevel),wB()}mu(JB,"initialize");var YB=mu((e,t={})=>{const{code:r}=jB(e);return TB.fromText(r,t)},"getDiagramFromText");function ZB(e,t,r,n){SB(t,e),_B(t,r,n,t.attr("id"))}mu(ZB,"addA11yInfo");var KB=Object.freeze({render:XB,parse:RB,getDiagramFromText:YB,initialize:JB,getConfig:Dd,setConfig:Nd,getSiteConfig:jd,updateSiteConfig:Ld,reset:mu(()=>{Rd()},"reset"),globalReset:mu(()=>{Rd(Td)},"globalReset"),defaultConfig:Td});vu(Dd().logLevel),Rd(Dd());var QB=mu((e,t,r)=>{bu.warn(e),fS(e)?(r&&r(e.str,e.hash),t.push({...e,message:e.str,error:e})):(r&&r(e),e instanceof Error&&t.push({str:e.message,message:e.message,hash:e.name,error:e}))},"handleError"),eL=mu(async function(e={querySelector:".mermaid"}){try{await tL(e)}catch(t){if(fS(t)&&bu.error(t.str),dL.parseError&&dL.parseError(t),!e.suppressErrors)throw bu.error("Use the suppressErrors option to suppress these errors"),t}},"run"),tL=mu(async function({postRenderCallback:e,querySelector:t,nodes:r}={querySelector:".mermaid"}){const n=KB.getConfig();let i;if(bu.debug((e?"":"No ")+"Callback function found"),r)i=r;else{if(!t)throw new Error("Nodes and querySelector are both undefined");i=document.querySelectorAll(t)}bu.debug(`Found ${i.length} diagrams`),void 0!==(null==n?void 0:n.startOnLoad)&&(bu.debug("Start On Load: "+(null==n?void 0:n.startOnLoad)),KB.updateSiteConfig({startOnLoad:null==n?void 0:n.startOnLoad}));const o=new xS.InitIDGenerator(n.deterministicIds,n.deterministicIDSeed);let a;const s=[];for(const c of Array.from(i)){if(bu.info("Rendering diagram: "+c.id),c.getAttribute("data-processed"))continue;c.setAttribute("data-processed","true");const t=`mermaid-${o.next()}`;a=c.innerHTML,a=eT(xS.entityDecode(a)).trim().replace(/<br\s*\/?>/gi,"<br/>");const r=xS.detectInit(a);r&&bu.debug("Detected early reinit: ",r);try{const{svg:r,bindFunctions:n}=await hL(t,a,c);c.innerHTML=r,e&&await e(t),n&&n(c)}catch(l){QB(l,s,dL.parseError)}}if(s.length>0)throw s[0]},"runThrowsErrors"),rL=mu(function(e){KB.initialize(e)},"initialize"),nL=mu(async function(e,t,r){bu.warn("mermaid.init is deprecated. Please use run instead."),e&&rL(e);const n={postRenderCallback:r,querySelector:".mermaid"};"string"==typeof t?n.querySelector=t:t&&(t instanceof HTMLElement?n.nodes=[t]:n.nodes=t),await eL(n)},"init"),iL=mu(async(e,{lazyLoad:t=!0}={})=>{wB(),td(...e),!1===t&&await kB()},"registerExternalDiagrams"),oL=mu(function(){if(dL.startOnLoad){const{startOnLoad:e}=KB.getConfig();e&&dL.run().catch(e=>bu.error("Mermaid failed to initialize",e))}},"contentLoaded");"undefined"!=typeof document&&window.addEventListener("load",oL,!1);var aL=mu(function(e){dL.parseError=e},"setParseErrorHandler"),sL=[],lL=!1,cL=mu(async()=>{if(!lL){for(lL=!0;sL.length>0;){const t=sL.shift();if(t)try{await t()}catch(e){bu.error("Error executing queue",e)}}lL=!1}},"executeQueue"),uL=mu(async(e,t)=>new Promise((r,n)=>{const i=mu(()=>new Promise((i,o)=>{KB.parse(e,t).then(e=>{i(e),r(e)},e=>{var t;bu.error("Error parsing",e),null==(t=dL.parseError)||t.call(dL,e),o(e),n(e)})}),"performCall");sL.push(i),cL().catch(n)}),"parse"),hL=mu((e,t,r)=>new Promise((n,i)=>{const o=mu(()=>new Promise((o,a)=>{KB.render(e,t,r).then(e=>{o(e),n(e)},e=>{var t;bu.error("Error parsing",e),null==(t=dL.parseError)||t.call(dL,e),a(e),i(e)})}),"performCall");sL.push(o),cL().catch(i)}),"render"),dL={startOnLoad:!0,mermaidAPI:KB,parse:uL,render:hL,init:nL,run:eL,registerExternalDiagrams:iL,registerLayoutLoaders:gM,initialize:rL,parseError:void 0,contentLoaded:oL,setParseErrorHandler:aL,detectType:ed,registerIconPacks:iT,getRegisteredDiagramsMetadata:mu(()=>Object.keys(Qh).map(e=>({id:e})),"getRegisteredDiagramsMetadata")},pL=dL;
|
|
151
|
+
/*! Check if previously processed */
|
|
152
|
+
/*!
|
|
153
|
+
* Wait for document loaded before starting the execution
|
|
154
|
+
*/
|
|
155
|
+
const fL=e=>{const{width:t,height:r,zoomable:n=!1}=e;return{root:T.css({position:"relative",borderRadius:w.tokens.borderRadiusMedium,border:`1px solid ${w.tokens.colorNeutralStroke2}`,width:t??"100%",height:r??"auto",...n?{cursor:"grab"}:{}}),svgContainer:T.css({width:"100%"}),loading:T.css({color:w.tokens.colorNeutralForeground3,fontFamily:w.tokens.fontFamilyBase,fontSize:w.tokens.fontSizeBase300})}};let gL=0;const mL=e=>{const{template:t}=e;return b.jsx(b.Fragment,{children:t})},yL=[{minWidth:1280,gap:100},{minWidth:1024,gap:60},{minWidth:768,gap:40},{minWidth:480,gap:24},{minWidth:0,gap:12}];function xL(e,t,r,n,i=48){const[o,a]=q.useState(n);return q.useEffect(()=>{const o=e.current,s=t.current,l=r.current;if(!o||!l)return;const c=()=>{const e=o.offsetWidth;if(0===e)return;const t=getComputedStyle(o),r=parseFloat(t.paddingLeft||"0"),c=parseFloat(t.paddingRight||"0"),u=parseFloat(t.columnGap||t.gap||"0"),h=function(e){for(const t of yL)if(e>t.minWidth)return t.gap;return yL[yL.length-1].gap}(e),d=s?s.offsetWidth:0,p=e-r-c-(d>0?d+h+u:0);if(p<=0)return;const f=Array.from(l.children);if(0===f.length)return void a(n);const g=parseFloat(getComputedStyle(l).columnGap||"0");let m=0;for(const n of f)m+=n.offsetWidth;if(m+=Math.max(0,f.length-1)*g,m<=p)return void a(f.length);const y=p-i;let x=0,b=0;for(let n=0;n<f.length;n++){const e=f[n].offsetWidth,t=n>0?g:0;if(x+t+e>y)break;x+=t+e,b++}a(Math.max(1,b))},u=requestAnimationFrame(c),h=new ResizeObserver(c);return h.observe(o),()=>{cancelAnimationFrame(u),h.disconnect()}},[e,t,r,n,i]),o}const bL=({item:e,isLoading:t,itemClass:r,labelClass:n})=>{if(!1===e.visible)return null;if(e.onRender)return e.onRender();const i=n?b.jsx("span",{className:n,children:e.label}):e.label,o=e.label?b.jsx(w.ToolbarButton,{className:r,"aria-label":e.ariaLabel||e.tooltip||e.label,icon:e.icon,onClick:e.onClick,disabled:e.disabled||t,appearance:e.appearance,children:i}):b.jsx(w.ToolbarButton,{className:r,"aria-label":e.ariaLabel||e.tooltip||e.key,icon:e.icon,onClick:e.onClick,disabled:e.disabled||t,appearance:e.appearance});return e.tooltip?b.jsx(w.Tooltip,{content:e.tooltip,relationship:"label",children:o}):o};function vL(e){const t=new Map;for(const r of e){const e=r.group||"default";t.has(e)||t.set(e,[]),t.get(e).push(r)}return t}const CL=new Map,wL=3e5;setInterval(()=>{const e=Date.now(),t=[];CL.forEach((r,n)=>{e>r.expiresAt&&t.push(n)}),t.forEach(e=>CL.delete(e))},6e5);const kL=v.memo(({userId:e,avatarSize:t=32,showHoverCard:r=!0,context:n,textPosition:i="after",className:o,avatarOnly:a=!1,secondaryText:s,tertiaryText:l,quaternaryText:c})=>{var u,h;const d={root:T.css({display:"flex",flexDirection:"row",justifyContent:"flex-start",alignItems:"flex-start",width:"fit-content",gap:"10px","&[data-fui-focus-within]:focus-within::after":{borderWidth:"0px"}}),personContainer:T.css({display:"flex",flexDirection:"column",justifyContent:"flex-start",alignItems:"flex-start",width:"100%",maxWidth:"100%",overflow:"hidden",paddingBottom:"0px"}),textStyle:T.css({width:"100%",maxWidth:"100%",overflow:"hidden",display:"-webkit-box",WebkitLineClamp:"1",WebkitBoxOrient:"vertical",paddingBottom:"0px",textAlign:"start",wordBreak:"break-all",textOverflow:"ellipsis",textOverlay:"hidden"}),spinnerContainer:T.css({display:"flex",flexDirection:"row",justifyContent:"center",alignItems:"center",width:"100%"})},{user:p}=((e,t)=>{const r=K(),n=t||r,i=null==n?void 0:n.graphClient,{error:o,warn:a,verbose:s}=Q(),[l,c]=v.useState(void 0),[u,h]=v.useState(!0),d=v.useCallback(async e=>{if(!i)return a("Graph client not available"),null;try{return await i.get(`/users/${e}`)}catch(t){return o("Error fetching user:",t instanceof Error?t:void 0),null}},[i]),p=v.useCallback(async e=>{if(!i)return a("Graph client not available"),null;try{return await i.get(`/users/${e}/presence`)}catch(t){return o("Error fetching user presence:",t instanceof Error?t:void 0),null}},[i]),f=v.useCallback(async e=>{if(i)try{const t=await i.getBlob(`/users/${e}/photo/$value`);return t?new Promise((e,r)=>{const n=new FileReader;n.onloadend=()=>e(n.result),n.onerror=r,n.readAsDataURL(t)}):void 0}catch(t){return void s("No photo available for user:",e)}else a("Graph client not available")},[i]),g=v.useCallback(async()=>{var t;if(!e)return void h(!1);const r=CL.get(e),n=Date.now();if(r&&n<r.expiresAt)return c(r.data),void h(!1);try{const r=await d(e);if(!r)return;let a,s={availability:"Offline",activity:"Offline"};try{if(r.id){const e=await p(r.id);e&&(s=e)}}catch(i){(null==(t=null==i?void 0:i.message)?void 0:t.toLowerCase().includes("exceed"))?(o("fetchUser: Exceeded resource error during presence check",i,x.ErrorType.Error),s=r.presence||{availability:"Offline",activity:"Offline"}):o("fetchUser: Error fetching user presence",i,x.ErrorType.Error)}try{r.id&&(a=await f(r.id))}catch(i){o("fetchUser: Error fetching user photo",i,x.ErrorType.Warning)}const l={...r,presence:s,userPhoto:a};CL.set(e,{data:l,timestamp:n,expiresAt:n+wL}),c(l)}catch(i){o("fetchUser: Error fetching user",i,x.ErrorType.Error)}finally{h(!1)}},[e,d,p,f,o]),m=v.useCallback(async()=>{var t;if(!e||!l)return;const r=CL.get(e),n=Date.now();if(!(r&&r.data.presence&&n-r.timestamp<12e4))try{let a={availability:"Offline",activity:"Offline"};try{if(l.id){const e=await p(l.id);e&&(a=e)}}catch(i){(null==(t=i.message)?void 0:t.toLowerCase().includes("exceed"))?(o("checkUserPresence: Exceeded resource error during presence check",i,x.ErrorType.Error),a=l.presence||{availability:"Offline",activity:"Offline"}):o("checkUserPresence: Error fetching user presence",i,x.ErrorType.Error)}const s={...l,presence:a};CL.set(e,{data:s,timestamp:n,expiresAt:(null==r?void 0:r.expiresAt)||n+wL}),c(s)}catch(i){o("checkUserPresence: Error in checkUserPresence",i,x.ErrorType.Error)}},[e,l,p,o]);v.useEffect(()=>{(async()=>{await g()})()},[g]);const{startPolling:y,stopPolling:b}=te(m,l?6e4:12e4,!1);return v.useEffect(()=>(l&&y(),()=>{b()}),[l,y,b]),{user:l,loading:u,refetch:g}})(e,n),f=x.useUserCardStrings(),g=v.useMemo(()=>{var e,t,r,n;const i=null==(t=null==(e=null==p?void 0:p.presence)?void 0:e.availability)?void 0:t.toLowerCase(),o=null==(n=null==(r=null==p?void 0:p.presence)?void 0:r.activity)?void 0:n.toLowerCase();switch(i){case"available":return{status:"available",text:f.available};case"availableidle":return{status:"available",text:f.availableIdle};case"away":return{status:"away",text:f.away};case"busy":return{status:"busy",text:f.busy};case"busyidle":return{status:"busy",text:f.busyIdle};case"donotdisturb":return{status:"do-not-disturb",text:f.doNotDisturb};case"berighback":return{status:"away",text:f.beRightBack};case"invisible":return{status:"offline",text:f.appearOffline};case"presenceunknown":return{status:"unknown",text:f.unknown};case"offline":return{status:"offline",text:"outofoffice"===o?f.outOfOffice:f.offline,outOfOffice:"outofoffice"===o};default:return{status:"offline",text:f.offline,outOfOffice:"outofoffice"===o}}},[null==(u=null==p?void 0:p.presence)?void 0:u.availability,null==(h=null==p?void 0:p.presence)?void 0:h.activity,f]);return b.jsx(mL,{upn:r&&(null==p?void 0:p.mail)||"",template:b.jsx("div",{className:w.mergeClasses(d.root,o),children:a?b.jsx(w.Avatar,{color:"colorful",image:{src:null==p?void 0:p.userPhoto,alt:(null==p?void 0:p.displayName)||f.userAvatar},size:t,name:(null==p?void 0:p.displayName)||e||f.unknownUser,badge:{status:g.status,outOfOffice:g.outOfOffice}}):b.jsx(w.Persona,{primaryText:b.jsxs(w.Body1Strong,{className:d.textStyle,children:[" ",(null==p?void 0:p.displayName)||e||f.unknownUser]}),textPosition:i??"after",presence:{status:g.status,outOfOffice:g.outOfOffice},secondaryText:(null==s?void 0:s.showSecondaryText)?s.text?b.jsx(b.Fragment,{children:b.jsx("span",{className:d.textStyle,children:s.text})}):b.jsx(b.Fragment,{children:b.jsx("span",{className:d.textStyle,children:(null==p?void 0:p.jobTitle)||"Unknown Job Title"})}):void 0,tertiaryText:(null==l?void 0:l.showTertiaryText)?l.text?b.jsx(b.Fragment,{children:b.jsx("span",{className:d.textStyle,children:l.text})}):b.jsx(b.Fragment,{children:b.jsx("span",{className:d.textStyle,children:(null==p?void 0:p.mail)||"Unknown Email"})}):void 0,quaternaryText:(null==c?void 0:c.showQuaternaryText)?c.text?b.jsx(b.Fragment,{children:b.jsx("span",{className:d.textStyle,children:c.text})}):b.jsx(b.Fragment,{children:b.jsx("span",{className:d.textStyle,children:g.text})}):void 0,avatar:{color:"colorful",image:{src:null==p?void 0:p.userPhoto,alt:(null==p?void 0:p.displayName)||f.userAvatar},size:t},textAlignment:"start"})})})},(e,t)=>e.userId===t.userId&&e.avatarSize===t.avatarSize&&e.showHoverCard===t.showHoverCard&&e.textPosition===t.textPosition&&e.avatarOnly===t.avatarOnly&&e.className===t.className&&JSON.stringify(e.secondaryText)===JSON.stringify(t.secondaryText)&&JSON.stringify(e.tertiaryText)===JSON.stringify(t.tertiaryText)&&JSON.stringify(e.quaternaryText)===JSON.stringify(t.quaternaryText)),SL={width:"20px",height:"20px",color:w.tokens.colorBrandBackground},_L=["access","comment","create","delete","edit","mention","move","rename","restore","share","version"],TL=new Map([]),AL=e=>b.jsxs("svg",{width:"100",height:"100",viewBox:"0 0 100 100",fill:"none",xmlns:"http://www.w3.org/2000/svg",...e,children:[b.jsx("rect",{x:"20",y:"30",width:"60",height:"50",fill:"#0078D4",opacity:"0.1"}),b.jsx("rect",{x:"30",y:"50",width:"10",height:"20",fill:"#0078D4"}),b.jsx("rect",{x:"45",y:"40",width:"10",height:"30",fill:"#0078D4"}),b.jsx("rect",{x:"60",y:"35",width:"10",height:"35",fill:"#0078D4"})]}),PL=e=>{const{height:t}=e,r=x.useAppDashboardStrings();return b.jsxs("div",{style:{height:t||"100%",display:"flex",justifyContent:"center",alignItems:"center",flexDirection:"column"},children:[b.jsx(AL,{width:200,height:200}),b.jsx(w.Text,{size:500,weight:"semibold",children:r.noDashboardsAvailable})]})},EL=e=>{const{onChange:t,values:r,maxCols:n,maxRows:i}=e,o=P.bundleIcon(P.Settings20Filled,P.Settings20Regular),a={gridContainer:T.css`
|
|
156
|
+
display: grid;
|
|
157
|
+
gap: 4px;
|
|
158
|
+
padding: 8px;
|
|
159
|
+
justify-content: center;
|
|
160
|
+
`,cell:T.css`
|
|
161
|
+
width: 30px;
|
|
162
|
+
height: 30px;
|
|
163
|
+
border: 1px solid ${w.tokens.colorNeutralStroke1};
|
|
164
|
+
background-color: ${w.tokens.colorNeutralBackground1};
|
|
165
|
+
cursor: pointer;
|
|
166
|
+
transition: background-color 150ms ease, transform 150ms ease;
|
|
167
|
+
will-change: background-color, transform;
|
|
168
|
+
`,hoveredCell:T.css`
|
|
169
|
+
background-color: ${w.tokens.colorNeutralBackground1Hover};
|
|
170
|
+
transform: scale(1.05);
|
|
171
|
+
`,selectedCell:T.css`
|
|
172
|
+
background-color: ${w.tokens.colorNeutralBackground1Selected};
|
|
173
|
+
`,menuPopover:T.css`
|
|
174
|
+
min-width: fit-content;
|
|
175
|
+
`,bottomText:T.css`
|
|
176
|
+
padding-left: 8px;
|
|
177
|
+
padding-right: 8px;
|
|
178
|
+
`,zoomContainer:T.css({display:"flex",flexDirection:"row",alignItems:"center",gap:"6px",width:"100%",boxSizing:"border-box",padding:"8px 0px"})},s=x.useAppDashboardStrings(),[l,c]=q.useState(r),[u,h]=q.useState(null),[d,p]=q.useState(!1);q.useEffect(()=>{c(r)},[r]);const f=(e,r)=>{const n={spanCols:r+1,spanRows:e+1};c(n),null==t||t(n),p(!1)},g=(e,t)=>{h({spanCols:t+1,spanRows:e+1})},m=q.useMemo(()=>30*n+4*(n-1)+32,[n]);return b.jsxs(w.Menu,{open:d,onOpenChange:(e,t)=>{p(t.open),h(null)},children:[b.jsx(w.MenuTrigger,{disableButtonEnhancement:!0,children:b.jsx(w.Tooltip,{content:s.configure,relationship:"label",children:b.jsx(w.MenuButton,{icon:b.jsx(o,{}),size:"small",appearance:"transparent"})})}),b.jsxs(w.MenuPopover,{style:{width:`${m}px`,minWidth:"120px",padding:8},children:[b.jsx("div",{className:a.zoomContainer,children:b.jsx(wt,{label:`Span (${l.spanCols} × ${l.spanRows})`})}),b.jsx("div",{className:a.gridContainer,style:{gridTemplateColumns:`repeat(${n}, 30px)`,gridTemplateRows:`repeat(${i}, 30px)`},onMouseLeave:()=>{h(null)},children:(()=>{const e=[];for(let t=0;t<i;t++)for(let r=0;r<n;r++){const n=t<l.spanRows&&r<l.spanCols,i=u&&t<u.spanRows&&r<u.spanCols;e.push(b.jsx("div",{className:`${a.cell} ${i?a.hoveredCell:""} ${n?a.selectedCell:""}`,onMouseEnter:()=>g(t,r),onClick:()=>f(t,r)},`${t}-${r}`))}return e})()}),b.jsx(w.Caption1,{className:a.bottomText,children:s.clickToSetSpan})]})]})},ML=T.keyframes`
|
|
179
|
+
0%, 100% { transform: translateY(0px); }
|
|
180
|
+
50% { transform: translateY(-8px); }
|
|
181
|
+
`,IL=T.keyframes`
|
|
182
|
+
0% { background-position: -200% center; }
|
|
183
|
+
100% { background-position: 200% center; }
|
|
184
|
+
`,BL=()=>({card:T.css({width:"100%",height:"310px",borderRadius:10,background:w.tokens.colorNeutralBackground1,border:`1px solid ${w.tokens.colorNeutralStroke1}`,boxShadow:w.tokens.shadow8,overflow:"visible",position:"relative",padding:"0px 15px !important",transition:"transform 0.25s ease, box-shadow 0.25s ease","&:hover, &:focus-within":{zIndex:10,transform:"translateY(-2px)",boxShadow:w.tokens.shadow16}}),description:T.css({fontSize:w.tokens.fontSizeBase300,color:w.tokens.colorNeutralForeground4,lineHeight:w.tokens.lineHeightBase400,position:"relative",zIndex:1}),footerMetric:T.css({display:"flex",flexDirection:"column",alignItems:"center",gap:w.tokens.spacingVerticalXXS}),footerIcon:T.css({color:w.tokens.colorNeutralForeground3,fontSize:w.tokens.fontSizeBase300}),footerLabel:T.css({fontSize:`${w.tokens.fontSizeBase100} !important`,color:w.tokens.colorNeutralForeground3,textTransform:"uppercase",letterSpacing:"0.8px",fontWeight:w.tokens.fontWeightMedium,textAlign:"center"}),footerValue:T.css({fontSize:`${w.tokens.fontSizeBase400} !important`,fontWeight:w.tokens.fontWeightSemibold,color:w.tokens.colorNeutralForeground2,textAlign:"center"}),footerDivider:T.css({height:"32px",borderColor:w.tokens.colorNeutralStroke1}),glowBlob:T.css({position:"absolute",top:"-60px",right:"-60px",width:"180px",height:"180px",borderRadius:"50%",pointerEvents:"none",zIndex:0,filter:"blur(40px)"}),glowBlobSuccess:T.css({position:"absolute",top:"-40px",right:"-40px",width:"160px",height:"160px",borderRadius:"50%",pointerEvents:"none",zIndex:0,background:`radial-gradient(circle, ${w.tokens.colorPaletteLightGreenBackground2} 0%, transparent 70%)`,opacity:.7,filter:"blur(20px)"}),glowBlobError:T.css({position:"absolute",top:"-40px",right:"-40px",width:"160px",height:"160px",borderRadius:"50%",pointerEvents:"none",zIndex:0,background:`radial-gradient(circle, ${w.tokens.colorPaletteRedBackground2} 0%, transparent 70%)`,opacity:.6,filter:"blur(20px)"}),headerActionBadge:T.css({minWidth:"32px",height:"32px",borderRadius:"50% !important",background:`${w.tokens.colorNeutralBackground3} !important`,border:"none !important",padding:"0 !important",display:"flex",alignItems:"center",justifyContent:"center"}),kpiContainer:T.css({width:"100%",backgroundColor:w.tokens.colorNeutralBackground2,borderRadius:8,display:"grid",gridTemplateColumns:"repeat(auto-fill, minmax(min(100%, 280px), 1fr))",gap:16,padding:16}),iconContainer:T.css({width:48,height:48,borderRadius:8,display:"grid",placeItems:"center",background:w.tokens.colorNeutralBackgroundInverted}),noKpiCard:T.css({width:280,minHeight:160,display:"flex",alignItems:"center",justifyContent:"center"}),noKpiCardContainer:T.css({width:"100%",minWidth:"280px",minHeight:"280px",borderRadius:"16px",background:`linear-gradient(135deg, ${w.tokens.colorNeutralBackground1} 0%, ${w.tokens.colorNeutralBackground3} 100%)`,border:`1px solid ${w.tokens.colorNeutralStroke1}`,boxShadow:w.tokens.shadow16,overflow:"hidden",position:"relative",padding:"32px",transition:"transform 0.3s ease, box-shadow 0.3s ease","&:hover":{transform:"translateY(-4px)",boxShadow:w.tokens.shadow28}}),noKpiBackgroundOrb1:T.css({position:"absolute",top:"0px",right:"0px",width:"180px",height:"180px",borderRadius:"50%",background:`radial-gradient(circle, ${w.tokens.colorBrandBackground2} 0%, transparent 70%)`,opacity:.8,pointerEvents:"none",filter:"blur(25px)",transform:"translate(30%, -30%)"}),noKpiBackgroundOrb2:T.css({position:"absolute",bottom:"-30px",left:"-30px",width:"120px",height:"120px",borderRadius:"50%",background:`radial-gradient(circle, ${w.tokens.colorPaletteLavenderBackground2} 0%, transparent 70%)`,opacity:.5,pointerEvents:"none",filter:"blur(20px)"}),noKpiIconContainer:T.css({width:"80px",height:"80px",borderRadius:"20px",background:`linear-gradient(135deg, ${w.tokens.colorBrandBackground} 0%, ${w.tokens.colorBrandBackground2} 100%)`,display:"flex",alignItems:"center",justifyContent:"center",boxShadow:`0 8px 24px ${w.tokens.colorBrandBackground}40`,animation:`${ML} 3s ease-in-out infinite`,position:"relative",zIndex:1}),noKpiIcon:T.css({fontSize:"36px",color:w.tokens.colorNeutralForegroundOnBrand}),noKpiSparkle1:T.css({position:"absolute",top:"-8px",right:"-8px",color:w.tokens.colorPaletteYellowForeground1,fontSize:"20px",animation:`${ML} 2s ease-in-out infinite 0.5s`}),noKpiSparkle2:T.css({position:"absolute",bottom:"-4px",left:"-8px",color:w.tokens.colorPaletteLavenderForeground2,fontSize:"16px",animation:`${ML} 2.5s ease-in-out infinite`}),noKpiTitle:T.css({fontSize:"22px",fontWeight:w.tokens.fontWeightSemibold,color:w.tokens.colorNeutralForeground1,marginTop:"24px",textAlign:"center",position:"relative",zIndex:1}),noKpiSubtitle:T.css({fontSize:"14px",color:w.tokens.colorNeutralForeground3,textAlign:"center",lineHeight:"1.6",maxWidth:"320px",marginTop:"8px",position:"relative",zIndex:1}),noKpiHighlight:T.css({background:`linear-gradient(90deg, ${w.tokens.colorBrandForeground1}, ${w.tokens.colorPaletteLavenderForeground2}, ${w.tokens.colorBrandForeground1})`,backgroundSize:"200% auto",WebkitBackgroundClip:"text",WebkitTextFillColor:"transparent",backgroundClip:"text",fontWeight:w.tokens.fontWeightSemibold,animation:`${IL} 3s linear infinite`}),noKpiButtonContainer:T.css({marginTop:"24px",position:"relative",zIndex:1}),noKpiButton:T.css({borderRadius:"10px",padding:"10px 20px",fontWeight:w.tokens.fontWeightSemibold,transition:"transform 0.2s ease","&:hover":{transform:"scale(1.02)"}}),noKpiDecorativeLine:T.css({width:"60px",height:"4px",borderRadius:"2px",background:`linear-gradient(90deg, ${w.tokens.colorBrandBackground}, ${w.tokens.colorPaletteLavenderBackground2})`,marginTop:"16px",position:"relative",zIndex:1}),footerGrid:T.css({width:"100%",display:"grid",gridTemplateColumns:"repeat(auto-fit, minmax(80px, 1fr))",alignItems:"center"})});var LL=(e=>(e[e.LOWER_IS_BETTER=1]="LOWER_IS_BETTER",e[e.HIGHER_IS_BETTER=2]="HIGHER_IS_BETTER",e))(LL||{});const jL=e=>{var t;const{dataCard:r}=e,n=BL(),i=x.useKpiStrings(),[o,a]=q.useState(!1),s=q.useCallback(()=>{a(!1)},[]),l=q.useMemo(()=>r.goalMetric===LL.LOWER_IS_BETTER?r.currentValue<=r.goal:r.currentValue>=r.goal,[r.currentValue,r.goal,r.goalMetric]),c=q.useMemo(()=>l?"success":"error",[l]),u=q.useMemo(()=>r.goal.toLocaleString(),[r.goal]),h=q.useMemo(()=>r.currentValue/r.totalItems*100,[r.currentValue,r.totalItems]),d=q.useMemo(()=>l?w.tokens.colorPaletteLightGreenForeground2:w.tokens.colorPaletteRedForeground2,[l]),p=q.useMemo(()=>l?w.tokens.colorPaletteLightGreenBackground1:w.tokens.colorPaletteRedBackground1,[l]),f=q.useMemo(()=>l?w.tokens.colorPaletteLightGreenBorder1:w.tokens.colorPaletteRedBorder1,[l]),g=q.useMemo(()=>({background:p,border:`1px solid ${f}`,color:d,borderRadius:"20px",padding:"12px 12px",fontSize:w.tokens.fontSizeBase200,fontWeight:w.tokens.fontWeightSemibold,letterSpacing:"0.3px",maxWidth:"fit-content"}),[p,f,d]);return b.jsx(b.Fragment,{children:b.jsxs(w.Card,{className:n.card,onMouseLeave:s,children:[b.jsx("div",{className:l?n.glowBlobSuccess:n.glowBlobError}),b.jsxs(bt,{gap:"m",padding:"m",children:[b.jsx(w.CardHeader,{header:b.jsxs(bt,{direction:"vertical",gap:"2px",children:[b.jsx(bt,{direction:"horizontal",alignItems:"center",gap:"8px",children:b.jsx(w.InfoLabel,{style:{zIndex:99999},infoButton:{popover:{open:o,onOpenChange:(e,t)=>a(t.open)}},info:b.jsx(b.Fragment,{children:b.jsx(w.Text,{size:300,color:"neutralSecondary",children:r.description||i.noDescription})}),children:b.jsx(w.Text,{weight:"bold",size:300,children:(null==(t=r.title)?void 0:t.toUpperCase())||i.defaultTitle})})}),b.jsx(w.Text,{size:200,style:{color:w.tokens.colorNeutralForeground3,fontStyle:"italic"},children:r.goalMetric===LL.LOWER_IS_BETTER?i.lowerIsBetter:i.higherIsBetter})]}),action:b.jsx(w.Tooltip,{content:l?`✓ ${i.withinGoalThreshold}`:`⚠ ${i.exceedsGoalThreshold}`,relationship:"inaccessible",children:b.jsx(w.Badge,{className:n.headerActionBadge,appearance:"ghost",size:"small",icon:l?b.jsx(P.CheckmarkCircleRegular,{style:{color:d,fontSize:"22px"}}):b.jsx(P.AlertFilled,{style:{color:d,fontSize:"22px"}})})})}),b.jsxs(bt,{gap:"s",direction:"horizontal",alignItems:"baseline",paddingTop:"s",children:[b.jsxs(w.Text,{weight:"bold",size:900,children:[r.currentValue," ",b.jsx("br",{})]}),b.jsxs(w.Text,{weight:"semibold",size:300,color:"neutralSecondary",children:["/ ",r.goal," ",i.goal]})]}),b.jsxs(bt,{gap:"s",children:[b.jsxs(bt,{direction:"horizontal",justifyContent:"space-between",children:[b.jsx(w.Text,{size:300,color:"neutralSecondary",children:i.progressGoal}),b.jsxs(w.Text,{size:300,color:"neutralSecondary",weight:"bold",children:[(r.currentValue/r.goal*100).toFixed(2),"%"]})]}),b.jsx(w.ProgressBar,{value:r.currentValue/r.goal,color:c,style:{height:"8px"},shape:"rounded"})]}),b.jsxs(w.CardFooter,{children:[b.jsx(w.Tooltip,{content:i.maxAllowedThreshold,relationship:"inaccessible",children:b.jsxs(bt,{alignItems:"center",gap:w.tokens.spacingVerticalXXS,children:[b.jsx(P.TargetRegular,{className:n.footerIcon}),b.jsx(w.Text,{className:n.footerLabel,children:"Goal"}),b.jsx(w.Text,{className:n.footerValue,children:u})]})}),b.jsx(w.Divider,{vertical:!0,className:n.footerDivider}),b.jsx(w.Tooltip,{content:i.totalItemsInScope,relationship:"inaccessible",children:b.jsxs(bt,{alignItems:"center",gap:w.tokens.spacingVerticalXXS,children:[b.jsx(P.DocumentRegular,{className:n.footerIcon}),b.jsx(w.Text,{className:n.footerLabel,children:i.totalItems}),b.jsx(w.Text,{className:n.footerValue,children:r.totalItems.toLocaleString()})]})}),b.jsx(w.Divider,{vertical:!0,className:n.footerDivider}),b.jsx(w.Tooltip,{content:i.currentValueAsPercent,relationship:"inaccessible",children:b.jsxs(bt,{alignItems:"center",gap:w.tokens.spacingVerticalXXS,children:[b.jsx(P.CalculatorRegular,{className:n.footerIcon}),b.jsx(w.Text,{className:n.footerLabel,children:i.percentOfTotal}),b.jsxs(w.Text,{className:n.footerValue,children:[h.toFixed(2),"%"]})]})})]}),b.jsx(bt,{children:b.jsx(w.Badge,{appearance:"outline",size:"small",style:g,icon:l?b.jsx(P.CheckmarkCircleRegular,{style:{fontSize:"14px"}}):b.jsx(P.AlertFilled,{style:{fontSize:"14px"}}),children:l?i.onTrack:i.exceedGoal})})]})]})})},NL=()=>{const e=BL(),t={headerTitle:T.css({width:"120px",height:"16px"}),headerBadge:T.css({width:"32px",height:"32px",borderRadius:"50%"}),mainValue:T.css({width:"80px",height:"42px"}),goalText:T.css({width:"70px",height:"16px"}),progressLabel:T.css({width:"80px",height:"12px"}),progressValue:T.css({width:"50px",height:"12px"}),progressBar:T.css({width:"100%",height:"8px",borderRadius:"4px"}),footerIcon:T.css({width:"16px",height:"16px",borderRadius:"4px"}),footerLabel:T.css({width:"50px",height:"10px"}),footerValue:T.css({width:"40px",height:"14px"}),badge:T.css({width:"90px",height:"32px",borderRadius:"20px"})};return b.jsx(w.Card,{className:e.card,children:b.jsx(w.Skeleton,{animation:"pulse",children:b.jsxs(bt,{gap:"m",padding:"m",children:[b.jsx(w.CardHeader,{header:b.jsx(bt,{direction:"horizontal",alignItems:"center",gap:"8px",children:b.jsx(w.SkeletonItem,{className:t.headerTitle})}),action:b.jsx(w.SkeletonItem,{className:t.headerBadge,shape:"circle"})}),b.jsxs(bt,{gap:"s",direction:"horizontal",alignItems:"baseline",paddingTop:"s",children:[b.jsx(w.SkeletonItem,{className:t.mainValue}),b.jsx(w.SkeletonItem,{className:t.goalText})]}),b.jsxs(bt,{gap:"s",children:[b.jsxs(bt,{direction:"horizontal",justifyContent:"space-between",children:[b.jsx(w.SkeletonItem,{className:t.progressLabel}),b.jsx(w.SkeletonItem,{className:t.progressValue})]}),b.jsx(w.SkeletonItem,{className:t.progressBar})]}),b.jsxs(w.CardFooter,{children:[b.jsxs(bt,{direction:"vertical",alignItems:"center",gap:"xs",children:[b.jsx(w.SkeletonItem,{className:t.footerIcon}),b.jsx(w.SkeletonItem,{className:t.footerLabel}),b.jsx(w.SkeletonItem,{className:t.footerValue})]}),b.jsx(w.Divider,{vertical:!0,style:{height:"32px",borderColor:w.tokens.colorNeutralStroke1}}),b.jsxs(bt,{direction:"vertical",alignItems:"center",gap:"xs",children:[b.jsx(w.SkeletonItem,{className:t.footerIcon}),b.jsx(w.SkeletonItem,{className:t.footerLabel}),b.jsx(w.SkeletonItem,{className:t.footerValue})]}),b.jsx(w.Divider,{vertical:!0,style:{height:"32px",borderColor:w.tokens.colorNeutralStroke1}}),b.jsxs(bt,{direction:"vertical",alignItems:"center",gap:"xs",children:[b.jsx(w.SkeletonItem,{className:t.footerIcon}),b.jsx(w.SkeletonItem,{className:t.footerLabel}),b.jsx(w.SkeletonItem,{className:t.footerValue})]})]}),b.jsx(bt,{children:b.jsx(w.SkeletonItem,{className:t.badge})})]})})})},DL=()=>{const e=BL(),t=x.useNoKpiStrings(),r="/sites/mock-site/Lists/Directory Status Config",n=q.useCallback(()=>{const e=`${window.location.origin}${r}/AllItems.aspx`;window.open(e,"_blank")},[r]);return b.jsxs(w.Card,{className:e.noKpiCardContainer,children:[b.jsx("div",{className:e.noKpiBackgroundOrb1}),b.jsx("div",{className:e.noKpiBackgroundOrb2}),b.jsxs(bt,{alignItems:"center",justifyContent:"center",gap:"s",children:[b.jsxs("div",{className:e.noKpiIconContainer,children:[b.jsx(P.DataBarVerticalStarRegular,{className:e.noKpiIcon}),b.jsx(P.SparkleRegular,{className:e.noKpiSparkle1}),b.jsx(P.SparkleRegular,{className:e.noKpiSparkle2})]}),b.jsx(w.Text,{className:e.noKpiTitle,children:t.title}),b.jsx("div",{className:e.noKpiDecorativeLine}),b.jsxs(w.Text,{className:e.noKpiSubtitle,children:[t.subtitle.split("{highlight}")[0],b.jsx("span",{className:e.noKpiHighlight,children:t.highlightText}),t.subtitle.split("{highlight}")[1]]}),b.jsx("div",{className:e.noKpiButtonContainer,children:b.jsx(w.Button,{appearance:"outline",icon:b.jsx(P.SettingsRegular,{}),className:e.noKpiButton,onClick:n,children:t.configureButton})})]})]})},OL=e=>{var t;const{dataCard:r}=e,n=BL(),i=x.useKpiStrings(),[o,a]=q.useState(!1),s=q.useCallback(()=>{a(!1)},[]),l=q.useMemo(()=>r.goalMetric===LL.LOWER_IS_BETTER?r.currentValue<=r.goal:r.currentValue>=r.goal,[r.currentValue,r.goal,r.goalMetric]),c=q.useMemo(()=>l?"success":"error",[l]),u=q.useMemo(()=>l?w.tokens.colorPaletteLightGreenForeground2:w.tokens.colorPaletteRedForeground2,[l]);return b.jsx(b.Fragment,{children:b.jsxs(w.Card,{className:n.card,style:{height:"168px"},onMouseLeave:s,children:[b.jsx("div",{className:l?n.glowBlobSuccess:n.glowBlobError}),b.jsxs(bt,{gap:"0px",padding:"m",children:[b.jsx(w.CardHeader,{header:b.jsxs(bt,{direction:"vertical",gap:"2px",children:[b.jsx(bt,{direction:"horizontal",alignItems:"center",gap:"8px",children:b.jsx(w.InfoLabel,{infoButton:{popover:{open:o,onOpenChange:(e,t)=>a(t.open)}},info:b.jsx(b.Fragment,{children:b.jsx(w.Text,{size:300,color:"neutralSecondary",children:r.description||i.noDescription})}),children:b.jsx(w.Text,{weight:"bold",size:300,children:(null==(t=r.title)?void 0:t.toUpperCase())||i.defaultTitle})})}),b.jsx(w.Text,{size:200,style:{color:w.tokens.colorNeutralForeground3,fontStyle:"italic"},children:r.goalMetric===LL.LOWER_IS_BETTER?i.lowerIsBetter:i.higherIsBetter})]}),action:b.jsx(w.Tooltip,{content:l?`✓ ${i.withinGoalThreshold}`:`⚠ ${i.exceedsGoalThreshold}`,relationship:"inaccessible",children:b.jsx(w.Badge,{className:n.headerActionBadge,appearance:"ghost",size:"small",icon:l?b.jsx(P.CheckmarkCircleRegular,{style:{color:u,fontSize:"22px"}}):b.jsx(P.AlertFilled,{style:{color:u,fontSize:"22px"}})})})}),b.jsxs(bt,{gap:"s",direction:"horizontal",alignItems:"baseline",children:[b.jsxs(w.Text,{weight:"bold",size:900,children:[r.currentValue," ",b.jsx("br",{})]}),b.jsxs(w.Text,{weight:"semibold",size:300,color:"neutralSecondary",children:["/ ",r.goal," ",i.goal]})]}),b.jsxs(bt,{gap:"s",children:[b.jsxs(bt,{direction:"horizontal",justifyContent:"space-between",children:[b.jsx(w.Text,{size:300,color:"neutralSecondary",children:i.progressGoal}),b.jsxs(w.Text,{size:300,color:"neutralSecondary",weight:"bold",children:[(r.currentValue/r.goal*100).toFixed(2),"%"]})]}),b.jsx(w.ProgressBar,{value:r.currentValue/r.goal,color:c,style:{height:"3px"},shape:"rounded"})]})]})]})})},FL=[{identifier:"kpi-1",title:"Sales Revenue",currentValue:125,goal:150,totalItems:200,description:"This is a comprehensive description of the Total Sales Revenue KPI for Q1. This metric tracks all revenue generated from product sales, service contracts, and recurring subscriptions across all business units and geographic regions. The goal is set based on historical performance, market conditions, and strategic growth objectives. Performance is evaluated weekly with detailed breakdowns by product category, sales team, and customer segment. This KPI is critical for quarterly business reviews and investor reporting.",goalMetric:2},{identifier:"kpi-2",title:"Customer Satisfaction",currentValue:87,goal:90,totalItems:100,description:"Customer satisfaction score",goalMetric:1},{identifier:"kpi-3",title:"Tasks Completed",currentValue:42,goal:50,totalItems:60,description:"Number of tasks completed this month",goalMetric:2},{identifier:"kpi-4",title:"New Customers",currentValue:156,goal:200,totalItems:250,description:"New customer acquisitions this quarter",goalMetric:1},{identifier:"kpi-5",title:"Response Time",currentValue:2.5,goal:2,totalItems:5,description:"Average response time in hours",goalMetric:2},{identifier:"kpi-6",title:"Employee Engagement",currentValue:78,goal:85,totalItems:100,description:"Employee engagement score percentage",goalMetric:1}];exports.AIAssistant=e=>{const{instrutions:t,timezone:r,locale:n,onResponse:i,openAIConfig:o,theme:a,placeholder:s,context:l}=e,[c,u]=q.useReducer(au,{messages:[],inputText:"",isLoading:!0,error:void 0,isRunning:!1}),{messages:h,inputText:d,isLoading:p,error:f,isRunning:g}=c,m=q.useRef([]),y=q.useRef(null),v={container:T.css({display:"flex",flexDirection:"column",padding:"10px",width:"100%",height:"600px",borderRadius:"8px",boxShadow:"0 2px 10px rgba(0, 0, 0, 0.1)",overflowY:"auto",overflowX:"hidden",position:"relative",zIndex:1e3}),chatList:T.css({display:"flex",flexDirection:"column",gap:"10px",paddingRight:"30px",width:"100%","::-webkit-scrollbar":{width:"5px",height:"5px"},"::-webkit-scrollbar-track":{background:w.tokens.colorNeutralBackground4,borderRadius:"10px"},"::-webkit-scrollbar-thumb":{background:w.tokens.colorBrandStroke2Hover,borderRadius:"10px"},"::-webkit-scrollbar-thumb:hover":{background:w.tokens.colorNeutralStroke2}}),chatAIAssistantRoot:T.css({padding:"10px",display:"flex",flexDirection:"column",position:"relative",height:"calc(100% - 20px)"}),inputContainer:T.css({display:"flex",flexDirection:"row",flex:1,marginTop:"10px",gap:"10px",alignItems:"center"}),input:T.css({width:"100%",fontSize:"14px"}),aiAssistantContainer:T.css({display:"flex",flexDirection:"column",height:"100%",width:"100%",boxSizing:"border-box"}),aiAssistantInputContainer:T.css({flex:"0 0 auto",padding:"16px",paddingBottom:"20px",borderTop:`1px solid ${w.tokens.colorNeutralStroke2}`,backgroundColor:w.tokens.colorNeutralBackground1,boxSizing:"border-box"})},C=x.useAIAssistantStrings(),{error:k}=Q(),{sendMessage:S,cancelRequest:_}=re({endpoint:null==o?void 0:o.endpoint,mcpServers:null==o?void 0:o.mcpServers,requestHeaders:null==o?void 0:o.requestHeaders}),A=q.useCallback(()=>{y.current&&(y.current.scrollTop=y.current.scrollHeight-y.current.clientHeight)},[]);q.useEffect(()=>{const e=setTimeout(()=>{A()},100);return()=>clearTimeout(e)},[h,A]),q.useEffect(()=>{var e,t;const n={message:"Welcome to AI Assistant! How can I help you today?",senderName:"Assistant",timeStamp:hu(r,(null==(t=null==(e=null==l?void 0:l.pageContext)?void 0:e.cultureInfo)?void 0:t.currentUICultureName)||"en-US"),status:"received"};u({type:"INIT",welcomeMessage:n})},[]);const P=q.useCallback(async()=>{var e,a,s,c;if(!d.trim())return;const h={message:d,senderName:"User",timeStamp:hu(r,(null==(a=null==(e=null==l?void 0:l.pageContext)?void 0:e.cultureInfo)?void 0:a.currentUICultureName)||"en-US"),status:"received"},p=d;u({type:"ADD_USER_MESSAGE",message:h}),u({type:"CLEAR_INPUT"}),u({type:"SET_IS_RUNNING"});const f={message:b.jsx(ou,{}),senderName:"Assistant",timeStamp:hu(r,(null==(c=null==(s=null==l?void 0:l.pageContext)?void 0:s.cultureInfo)?void 0:c.currentUICultureName)||"en-US"),status:"sending"};u({type:"ADD_ASSISTANT_MESSAGE",message:f});try{const e=await S({instructions:t,input:p,timezone:r,locale:n,history:m.current,mcpServers:null==o?void 0:o.mcpServers});if(i){const t=await i(e),{message:r,status:n}=t;u({type:"UPDATE_LAST_ASSISTANT_MESSAGE",message:{...f,message:r||e,status:n||"received"}})}else u({type:"UPDATE_LAST_ASSISTANT_MESSAGE",message:{...f,message:e,status:"received"}});u({type:"SET_IS_RUNNING"}),m.current.push(p),m.current.push(e)}catch(g){k("Error during streaming:",g instanceof Error?g:void 0);let e="Error occurred while processing your request.";g instanceof Error&&(e=g.message.includes("Rate limit")||g.message.includes("429")?"Rate limit exceeded. Please wait a moment before sending another message.":g.message.includes("quota")?"API quota exceeded. Please try again later.":g.message.includes("abort")?"Request was cancelled.":g.message),u({type:"UPDATE_LAST_ASSISTANT_MESSAGE",message:{...f,message:e,status:"failed"}}),u({type:"SET_IS_RUNNING"})}},[d,t,n,i,o,r,S,A,l]),E=q.useCallback(e=>{u({type:"SET_INPUT",inputText:e})},[]);return p?b.jsx(w.Spinner,{size:"medium"}):f?b.jsx(_i,{message:C.processingError,messageType:Y.INFO}):b.jsxs("div",{className:v.aiAssistantContainer,children:[b.jsx(uu,{ref:y,messages:h,context:l}),b.jsx("div",{className:v.aiAssistantInputContainer,children:b.jsx(iu,{context:l,value:d,onChange:E,placeholder:s,onSend:P,onAbort:_,theme:a,isRunning:g})})]})},exports.AISearchControl=({systemPromptTemplate:e,azureOpenAIConfig:t,placeholder:r,onSearchQueryGenerated:n,onSearchStart:i,onSearchError:o,disabled:a=!1,className:s,width:l})=>{const{error:c}=Q(),u=x.useAISearchControlStrings(),h=r||u.placeholder,{generateText:d,isConfigured:p}={generateText:async(e,t)=>"Azure OpenAI not configured - please provide configuration",isConfigured:!1},[f,g]=v.useState(!1),[m,y]=v.useState(""),b=v.useRef(null),{searchBoxStyles:C,iconWrapperStyles:k}={searchBoxStyles:ai`
|
|
185
|
+
border: 1px solid ${w.tokens.colorNeutralStroke2};
|
|
186
|
+
border-radius: 50px; /* Fully circular/pill shape */
|
|
187
|
+
background-color: ${w.tokens.colorNeutralBackground1};
|
|
188
|
+
padding: 5px 10px;
|
|
189
|
+
box-shadow: none;
|
|
190
|
+
transition: all 0.2s ease;
|
|
191
|
+
position: relative;
|
|
192
|
+
|
|
193
|
+
/* Remove default FluentUI focus styling */
|
|
194
|
+
&::after {
|
|
195
|
+
display: none !important;
|
|
196
|
+
}
|
|
197
|
+
|
|
198
|
+
&:hover {
|
|
199
|
+
border-color: ${w.tokens.colorBrandStroke1};
|
|
200
|
+
|
|
201
|
+
}
|
|
202
|
+
|
|
203
|
+
&:focus-within {
|
|
204
|
+
outline: none;
|
|
205
|
+
border-color: ${w.tokens.colorBrandStroke1};
|
|
206
|
+
|
|
207
|
+
}
|
|
208
|
+
|
|
209
|
+
&:disabled {
|
|
210
|
+
opacity: 0.6;
|
|
211
|
+
cursor: not-allowed;
|
|
212
|
+
border-color: ${w.tokens.colorNeutralStroke3};
|
|
213
|
+
background-color: ${w.tokens.colorNeutralBackground3};
|
|
214
|
+
}
|
|
215
|
+
|
|
216
|
+
/* Style the input directly */
|
|
217
|
+
input {
|
|
218
|
+
border: none !important;
|
|
219
|
+
outline: none !important;
|
|
220
|
+
background: transparent !important;
|
|
221
|
+
font-size: ${w.tokens.fontSizeBase300};
|
|
222
|
+
color: ${w.tokens.colorNeutralForeground1};
|
|
223
|
+
box-shadow: none !important;
|
|
224
|
+
|
|
225
|
+
&::placeholder {
|
|
226
|
+
color: ${w.tokens.colorNeutralForeground3};
|
|
227
|
+
}
|
|
228
|
+
|
|
229
|
+
&:focus {
|
|
230
|
+
border: none !important;
|
|
231
|
+
outline: none !important;
|
|
232
|
+
box-shadow: none !important;
|
|
233
|
+
}
|
|
234
|
+
}
|
|
235
|
+
|
|
236
|
+
/* Remove any internal focus indicators */
|
|
237
|
+
* {
|
|
238
|
+
&:focus {
|
|
239
|
+
outline: none !important;
|
|
240
|
+
box-shadow: none !important;
|
|
241
|
+
}
|
|
242
|
+
}
|
|
243
|
+
`,iconWrapperStyles:ai`
|
|
244
|
+
display: flex;
|
|
245
|
+
align-items: center;
|
|
246
|
+
padding: 2px;
|
|
247
|
+
margin-right: 8px;
|
|
248
|
+
`},S=v.useCallback(async e=>{if(e.trim()){const t=u.notConfiguredError;return void(null==o||o(t,e.trim()))}},[d,e,n,i,o,c,p]),_=v.useCallback((e,t)=>{y(t.value)},[]),T=v.useCallback(()=>{var e;y(""),null==(e=b.current)||e.blur(),null==n||n("","")},[n]),A=v.useCallback(e=>{var t;"Enter"===e.key&&!f&&m.trim()?S(m).catch(e=>{c("Error in handleAISearch:",e)}):"Escape"===e.key&&(null==(t=b.current)||t.blur(),y(""),null==n||n("",""))},[S,f,m,n]);return ni(w.SearchBox,{ref:b,css:C,className:s,style:{width:l},placeholder:h,value:m,onChange:_,onKeyDown:A,disabled:a||f,contentBefore:ni("span",{css:k,children:ni(Kc,{size:20})}),dismiss:{onClick:T}})},exports.AISearchIcon=Kc,exports.AISearchIconExample=()=>{const e=Qc();return b.jsxs("div",{className:e.container,children:[b.jsx("h2",{children:"AI Search Icon Examples"}),b.jsxs("div",{className:e.section,children:[b.jsx("h3",{children:"Standard AI Search Icon"}),b.jsxs("div",{className:e.iconRow,children:[b.jsx("span",{className:e.label,children:"Small (16px):"}),b.jsx(Kc,{size:16})]}),b.jsxs("div",{className:e.iconRow,children:[b.jsx("span",{className:e.label,children:"Medium (20px):"}),b.jsx(Kc,{size:20})]}),b.jsxs("div",{className:e.iconRow,children:[b.jsx("span",{className:e.label,children:"Large (24px):"}),b.jsx(Kc,{size:24})]}),b.jsxs("div",{className:e.iconRow,children:[b.jsx("span",{className:e.label,children:"Extra Large (32px):"}),b.jsx(Kc,{size:32})]}),b.jsxs("div",{className:e.iconRow,children:[b.jsx("span",{className:e.label,children:"Custom Colors:"}),b.jsx(Kc,{size:24,color:w.tokens.colorPaletteBlueForeground2,aiIndicatorColor:w.tokens.colorPaletteGreenForeground2})]})]}),b.jsxs("div",{className:e.section,children:[b.jsx("h3",{children:"Usage in Buttons"}),b.jsxs("div",{className:e.iconRow,children:[b.jsx("span",{className:e.label,children:"Primary Button:"}),b.jsx(w.Button,{appearance:"primary",icon:b.jsx(Kc,{size:16}),children:"AI Search"})]}),b.jsxs("div",{className:e.iconRow,children:[b.jsx("span",{className:e.label,children:"Secondary Button:"}),b.jsx(w.Button,{appearance:"secondary",icon:b.jsx(Kc,{size:16}),children:"Smart Search"})]}),b.jsxs("div",{className:e.iconRow,children:[b.jsx("span",{className:e.label,children:"Icon Only Button:"}),b.jsx(w.Button,{appearance:"subtle",icon:b.jsx(Kc,{size:20}),title:"AI Search"})]})]}),b.jsxs("div",{className:e.section,children:[b.jsx("h3",{children:"Usage Example Code"}),b.jsx("pre",{className:e.codeBlock,children:"// Basic usage\nimport { AISearchIcon } from './AISearchIcon';\n\n// Standard icon with AI badge\n<AISearchIcon size={20} />\n\n// Icon with custom colors\n<AISearchIcon \n size={24} \n color={tokens.colorPaletteBlueForeground2}\n aiIndicatorColor={tokens.colorPaletteGreenForeground2}\n/>\n\n// In a button\n<Button \n appearance=\"primary\"\n icon={<AISearchIcon size={16} />}\n>\n AI Search\n</Button>"})]})]})},exports.AdaptiveCardHost=Uc,exports.AdaptiveCardHostThemeType=co,exports.AppDashboard=({cards:e,containerWidth:t,containerHeight:r="100%",maxSpanRows:n=4,enableDragAndDrop:i=!0,enableCache:o=!0,cacheKeyPrefix:a="app-dashboard",onCardsReorder:s,onCardResize:l})=>{const{warn:c}=Q(),u={dashboardContainer:T.css({display:"grid",padding:"20px",gap:"16px",backgroundColor:w.tokens.colorNeutralBackground2,gridTemplateColumns:"repeat(auto-fill, minmax(350px, 1fr))",gridAutoRows:"350px",overflowY:"auto",overflowX:"hidden","::-webkit-scrollbar":{width:"5px",height:"5px"},"::-webkit-scrollbar-track":{background:w.tokens.colorNeutralBackground4,borderRadius:"10px"},"::-webkit-scrollbar-thumb":{background:w.tokens.colorBrandStroke2Hover,borderRadius:"10px"},"::-webkit-scrollbar-thumb:hover":{background:w.tokens.colorNeutralStroke2},justifyContent:"center",gridAutoFlow:"dense"}),cardBody:T.css({display:"flex",flexDirection:"column",height:"100%",minHeight:"320px"}),chartContainer:T.css({flex:1,width:"100%",minHeight:"280px"}),cardDescription:T.css({color:`${w.tokens.colorNeutralForeground2}`}),cardWrapper:T.css({position:"relative",height:"100%",minHeight:"300px",borderRadius:w.tokens.borderRadiusMedium,transition:"all 0.2s ease","&:hover":{transform:"translateY(-2px)",boxShadow:`${w.tokens.shadow16}`},"&:active":{transform:"translateY(0)",boxShadow:`${w.tokens.shadow8}`}})},h=`${a}-layout-settings`,d=`${a}-card-order`,{getCachedData:p,setCachedData:f}=ee(),g=v.useCallback(e=>p(e),[p]),m=v.useCallback((e,t)=>f(e,t,43200),[f]),{getCachedData:y,setCachedData:x}=ee(),C=v.useCallback(e=>y(e),[y]),k=v.useCallback((e,t)=>x(e,t,43200),[x]),[S,_]=v.useState([]),[A,P]=v.useState({}),E=v.useRef(null),M=v.useRef(null),I=v.useRef(null);v.useEffect(()=>{(async()=>{try{let t=e;const r={};if(o){const[n,i]=await Promise.all([g(h),C(d)]);if(i&&i.length>0){const r=new Map(e.map(e=>[e.id,e])),n=i.filter(e=>r.has(e)),o=e.filter(e=>!i.includes(e.id));t=[...n.map(e=>r.get(e)),...o]}e.forEach(e=>{var t,i;const o=null==n?void 0:n[e.id];r[e.id]={spanCols:(null==o?void 0:o.spanCols)??(null==(t=e.defaultSpan)?void 0:t.spanCols)??1,spanRows:(null==o?void 0:o.spanRows)??(null==(i=e.defaultSpan)?void 0:i.spanRows)??1}})}else e.forEach(e=>{var t,n;r[e.id]={spanCols:(null==(t=e.defaultSpan)?void 0:t.spanCols)??1,spanRows:(null==(n=e.defaultSpan)?void 0:n.spanRows)??1}});_(t),P(r)}catch(t){c("Failed to load dashboard data from cache:",t),_(e);const r={};e.forEach(e=>{var t,n;r[e.id]={spanCols:(null==(t=e.defaultSpan)?void 0:t.spanCols)??1,spanRows:(null==(n=e.defaultSpan)?void 0:n.spanRows)??1}}),P(r)}})()},[e,o,h,d,g,C]),v.useEffect(()=>{if(!o||0===Object.keys(A).length)return;(async()=>{try{await m(h,A)}catch(e){c("Failed to save dashboard layout to cache:",e)}})()},[A,o,h,m]),v.useEffect(()=>{if(!o||0===S.length)return;(async()=>{try{const e=S.map(e=>e.id);await k(d,e)}catch(e){c("Failed to save dashboard order to cache:",e)}})()},[S,o,d,k]),v.useEffect(()=>{t<=600&&P(()=>{const e={};return S.forEach(t=>{e[t.id]={spanCols:1,spanRows:1}}),e})},[t,S]);const B=v.useMemo(()=>t>600,[t]),{minCardWidth:L,gridGap:j,containerPadding:N}=v.useMemo(()=>({minCardWidth:350,gridGap:16,containerPadding:20}),[]),D=t-2*N,O=v.useMemo(()=>Math.floor((D+j)/(L+j)),[D,j,L]),F=Math.max(O,1),R=v.useCallback(()=>{if(null!==E.current&&null!==M.current&&E.current!==M.current){const e=[...S],[t]=e.splice(E.current,1);e.splice(M.current,0,t),_(e),s&&s(e)}E.current=null,M.current=null},[S,s]),$=v.useCallback((e,t)=>{const r={spanCols:Math.min(Math.max(t.spanCols,1),F),spanRows:Math.min(Math.max(t.spanRows,1),n)};P(t=>({...t,[e]:r})),l&&l(e,r)},[F,n,l]),z=v.useMemo(()=>S.reduce((e,t)=>{var r,n;return e[t.id]={spanCols:Math.min((null==(r=t.defaultSpan)?void 0:r.spanCols)??1,O),spanRows:(null==(n=t.defaultSpan)?void 0:n.spanRows)??1},e},{}),[S,O]),V=v.useMemo(()=>S.map((e,t)=>{var o,a,s,l;const c=!1!==e.showZoom&&B,h=e.headerAction||(c?b.jsx(EL,{values:A[e.id]||z[e.id]||{spanCols:1,spanRows:1},maxCols:F,maxRows:n,IsOpen:!1,onChange:t=>$(e.id,t)}):void 0);return b.jsx("div",{className:u.cardWrapper,draggable:i,onDragStart:()=>i&&(E.current=t),onDragEnter:()=>i&&(M.current=t),onDragOver:e=>i&&e.preventDefault(),onDragEnd:i?R:void 0,style:{gridColumnEnd:(null==(o=A[e.id])?void 0:o.spanCols)?`span ${A[e.id].spanCols}`:`span ${(null==(a=z[e.id])?void 0:a.spanCols)||1}`,gridRowEnd:(null==(s=A[e.id])?void 0:s.spanRows)?`span ${A[e.id].spanRows}`:`span ${(null==(l=z[e.id])?void 0:l.spanRows)||1}`,cursor:i?"grab":"default"},children:b.jsxs(w.Card,{className:`${u.cardBody} ${e.className||""}`,children:[b.jsx(w.CardHeader,{header:b.jsxs(bt,{gap:"0px",children:[b.jsx(w.Text,{weight:"semibold",size:400,children:e.cardTitle}),e.cardDescription&&b.jsx(w.Text,{className:u.cardDescription,size:200,children:e.cardDescription})]}),action:h}),b.jsx("div",{className:u.chartContainer,style:{height:r,...e.style},children:e.content})]})},e.id)}),[S,i,R,A,u.cardBody,u.cardDescription,u.chartContainer,u.cardWrapper,B,F,n,$,r,z]);return 0===S.length?b.jsx(PL,{}):b.jsx("div",{ref:I,className:u.dashboardContainer,style:{height:r},children:V})},exports.AspectRatio=({ratio:e,children:t,maxWidth:r,maxHeight:n,style:i={},...o})=>{const a={position:"relative",width:"100%",paddingTop:100/e+"%",maxWidth:r||"none",maxHeight:n||"none",...i};return b.jsx("div",{style:a,...o,children:b.jsx("div",{style:{position:"absolute",top:0,left:0,width:"100%",height:"100%"},children:t})})},exports.Breadcrumb=({items:e,maxWidth:t="100%",styles:r,theme:n,size:i="medium",currentIndex:o=e.length-1,className:a})=>{const{styles:s,getStyles:l}=Et(),c=v.useRef(null),[u,h]=v.useState([]),[d,p]=v.useState([]);return v.useEffect(()=>{const t=()=>{if(!c.current)return;const t=c.current.offsetWidth;let r=0;const n=[],i=[];e.forEach(e=>{r+80<=t-50?(n.push(e),r+=80):i.push(e)}),h(n),p(i)},r=((e,t)=>{let r;return(...n)=>{clearTimeout(r),r=setTimeout(()=>e(...n),t)}})(t,100),n=new _.ResizeObserver(()=>{r()});return c.current&&n.observe(c.current),t(),()=>{n.disconnect()}},[e]),b.jsx("div",{ref:c,className:w.mergeClasses(s.container,a),style:{maxWidth:t,...r},children:b.jsxs(ft,{horizontal:!0,verticalAlign:"center",horizontalAlign:"start",children:[u.map((e,t)=>b.jsxs(v.Fragment,{children:[t===o?b.jsxs(ft,{horizontal:!0,verticalAlign:"center",horizontalAlign:"start",columnGap:5,styles:{overflow:"hidden"},children:[e.icon?v.cloneElement(e.icon,{style:{fontSize:"large"===i?"20px":"medium"===i?"16px":"12px"}}):null,b.jsx(w.Text,{className:w.mergeClasses(s.breadcrumbItem,l(e,i),l(e,"current")),"aria-current":"page",children:e.label},e.label)]}):b.jsx(w.Button,{icon:e.icon?e.icon:null,appearance:"transparent",className:`${s.breadcrumbItem}`,onClick:e.onClick,children:b.jsx(w.Text,{className:l(e,i),children:e.label})},e.label),t<u.length-1&&b.jsx(P.ChevronRightRegular,{style:{fontSize:"large"===i?"20px":"medium"===i?"16px":"12px"}})]},e.label??`breadcrumb-${t}`)),d.length>0&&b.jsx(Mt,{items:d,theme:n})]})})},exports.ButtonMenu=Pt,exports.CalendarControl=({events:e,height:t=800,theme:r,onDayChange:n,onMonthChange:i,onWeekChange:o,onViewChange:a,onDaySlotClick:s,defaultView:l,strings:c})=>{const{styles:u}=Ft(),h=v.useRef(null),[d,p]=v.useState(null),f=v.useRef(0),[g,m]=v.useState(new Date),[y,x]=v.useState(l??rr.Month),{getMonthCalendar:C}=Kt(Intl.DateTimeFormat().resolvedOptions().timeZone),S=q.useCallback(e=>{const t=e.getMonth(),r=k.startOfMonth(e),n=k.startOfWeek(r);return Array.from({length:42},(e,r)=>{const i=k.addDays(n,r);return{day:i.getDate(),currentMonth:i.getMonth()===t,date:i}})},[42]),T=q.useCallback(e=>{i&&i(e),m(e)},[i]),A=q.useCallback(e=>{n&&n(e),m(e)},[n]),P=q.useCallback(e=>{o&&o(e),m(e)},[o]),E=q.useCallback(e=>{a&&a(e),x(e)},[a]),M=q.useCallback(t=>{var r;const{date:n}=t;return(null==(r=C(e,g.getFullYear(),g.getMonth())[k.format(n,"yyyy-MM-dd")])?void 0:r.flatMap(e=>e))||[]},[g,e]),I=q.useCallback(()=>{h.current&&requestAnimationFrame(()=>{if(h.current){const e=h.current.querySelector(`.${u.calendarWrapper} > div:nth-child(8)`);e&&(p(e.offsetHeight),f.current=e.offsetHeight)}})},[u.calendarWrapper]);v.useEffect(()=>{const e=new _.ResizeObserver(I);return h.current&&e.observe(h.current),I(),window.addEventListener("resize",I),()=>{e.disconnect(),window.removeEventListener("resize",I)}},[I,y]),v.useEffect(()=>{x(l||rr.Month)},[l]);const B=q.useCallback(()=>{switch(y){case rr.Month:return b.jsx(xr,{events:e,currentDate:g,rowHeight:d,getCalendarDays:S,getEventsForDay:M,styles:u,onDaySlotClick:s,height:t,calendarRef:h,strings:null==c?void 0:c.calendarControl});case rr.Week:return b.jsx(br,{events:e,currentDay:g,height:t,strings:null==c?void 0:c.weekView});case rr.Day:return b.jsx(vr,{events:e,currentDay:g,height:t,strings:null==c?void 0:c.dayView});default:return b.jsx(xr,{events:e,currentDate:g,rowHeight:d,getCalendarDays:S,getEventsForDay:M,styles:u,onDaySlotClick:s,height:t,calendarRef:h,strings:null==c?void 0:c.calendarControl})}},[y,e,g,d,S,M,u,s,t]),L=b.jsxs(ft,{height:"100%",verticalAlign:"start",children:[b.jsx(fr,{selectedView:y,onSelectedView:E,currentDate:g,setCurrentDate:m,onWeekChange:P,onMonthChange:T,onDayChange:A,strings:null==c?void 0:c.toolbar}),b.jsx(B,{})]});return b.jsx(w.IdPrefixProvider,{value:"calendarControl-",children:r?b.jsx(w.FluentProvider,{theme:r,applyStylesToPortals:!0,style:{width:"100%"},children:L}):b.jsx("div",{style:{width:"100%"},children:L})})},exports.CalendarMonth=sr,exports.Card=lt,exports.Carousel=e=>{const{className:t,items:r,title:n}=e,i=q.useRef(null),[o,a]=q.useState(0),[s,l]=q.useState(0),{carouselStyles:c}=(e=>{const{styles:t}=e,{getBaseStyles:r}=ne();return{carouselStyles:q.useCallback((n,i)=>({...r(e,n,i),...t}),[r,e,t])}})(e),[u,h]=A(),d={titleStyles:T.css({display:"-webkit-box",overflow:"hidden",textOverflow:"ellipsis",WebkitLineClamp:"1",WebkitBoxOrient:"vertical",textAlign:"start",height:"25px"})},{enableControls:p,embla__slide:f,embla__container:g,embla__viewport:m,embla__buttons:y}=((e,t)=>{const{getCurrentDevice:r}=ne(),n=q.useCallback(()=>{let e="95%";switch(r(t)){case"Medium":e="45%";break;case"Large":e="calc(95% / 4)";break;case"ExtraLarge":e="calc(95% / 5)";break;case"ExtraExtraLarge":e="calc(95% / 6)";break;default:e="95%"}return e},[t,r]),i=q.useCallback(()=>{const e=r(t);let n=w.tokens.spacingVerticalM;switch(e){case"Medium":default:n=w.tokens.spacingVerticalM;break;case"Large":n=w.tokens.spacingVerticalL;break;case"ExtraLarge":n=w.tokens.spacingVerticalXL}return n},[t,r]);return{enableControls:T.css({display:"flex",justifyContent:"space-between",alignItems:"stretch",gap:10,padding:5}),embla__viewport:T.css({overflow:"hidden",paddingTop:"10px",paddingBottom:"20px"}),embla__container:T.css({backfaceVisibility:"hidden",display:"flex",touchAction:"pan-y"}),embla:T.css({".embla":{}}),embla__slide:T.css({minWidth:0,flex:`0 0 ${n()}`,paddingLeft:`${i()}`}),embla__buttons:T.css({display:"grid",gridTemplateColumns:"repeat(2, 1fr)",gap:0,alignItems:"center"})}})(0,o),{prevBtnDisabled:x,nextBtnDisabled:C,onPrevButtonClick:k,onNextButtonClick:S}=(e=>{const[t,r]=v.useState(!0),[n,i]=v.useState(!0),o=v.useCallback(()=>{e&&e.scrollPrev()},[e]),a=v.useCallback(()=>{e&&e.scrollNext()},[e]),s=v.useCallback(e=>{r(!e.canScrollPrev()),i(!e.canScrollNext())},[]);return v.useEffect(()=>{e&&(s(e),e.on("reInit",s),e.on("select",s))},[e,s]),{prevBtnDisabled:t,nextBtnDisabled:n,onPrevButtonClick:o,onNextButtonClick:a}})(h);return q.useEffect(()=>{let e;return i.current&&(e=new _.ResizeObserver(e=>{for(const t of e){const{width:e,height:r}=t.contentRect;a(e),l(r)}}),a(i.current.clientWidth),l(i.current.clientHeight),e.observe(i.current)),()=>{e&&e.disconnect()}},[]),b.jsx(b.Fragment,{children:b.jsxs("div",{id:"-carousel",className:w.mergeClasses(t,"embla"),style:{...c(o,s)},ref:i,children:[b.jsxs("div",{className:p,children:[b.jsx(w.Subtitle2,{className:d.titleStyles,children:n}),b.jsxs("div",{className:y,children:[b.jsx(w.Button,{onClick:k,disabled:x,appearance:"subtle",icon:b.jsx(P.ChevronLeftRegular,{})}),b.jsx(w.Button,{onClick:S,disabled:C,appearance:"subtle",icon:b.jsx(P.ChevronRightRegular,{})})]})]}),b.jsx("div",{className:m,ref:u,children:b.jsx("div",{className:g,children:r.map((e,t)=>b.jsx("div",{className:f,children:e},t))})})]})})},exports.Center=mt,exports.ChatInput=eu,exports.ChatInputWithMensions=iu,exports.ChatInputWithMensionsV1=({context:e,onChange:t,value:r,placeholder:n,onSend:i,theme:o,isRunning:a,onAbort:s})=>{const[l,c]=v.useState(r||""),[u,h]=v.useState(!1),d=v.useRef(null),p=x.useAIAssistantStrings(),[f,g]=v.useState({top:0,left:0}),[m,y]=v.useState([]),C=v.useRef({}),k=nu(),{warn:S,error:_}=Q();v.useEffect(()=>{var e;null==(e=d.current)||e.focus(),c(r||"")},[r]);const T=v.useCallback(it(async t=>{const r=await(async t=>{var r,n;if(C.current[t])return C.current[t];if(!(null==e?void 0:e.graphClient))return S("Graph client not available"),[];try{const i=t&&t.length>0?`/users?$filter=startswith(displayName,'${t}')`:"/users?$orderby=displayName&$top=10",o=await e.graphClient.get(i),a=(null==o?void 0:o.value)||[],s=(null==(n=null==(r=e.pageContext)?void 0:r.web)?void 0:n.absoluteUrl)||"";return a.forEach(e=>{e.avatar=s?`${s}/_layouts/15/userphoto.aspx?size=S&accountname=${e.mail}`:`https://graph.microsoft.com/v1.0/users/${e.id}/photo/$value`}),C.current[t]=a,a}catch(i){return _("Error fetching users from Graph:",i instanceof Error?i:void 0),[]}})(t);r.sort((e,t)=>e.displayName.localeCompare(t.displayName)),y(r),h(!0),setTimeout(()=>{var e;null==(e=d.current)||e.focus()},0)},300),[e]),A=e=>{var r;const n=l.replace(/@(\w*)$/,`@${e} `);c(n),t&&t(n),h(!1),y([]),null==(r=d.current)||r.focus()},P=v.useCallback(({users:e})=>b.jsxs("div",{className:k.listContainer,children:[0===e.length&&b.jsx(w.Caption1,{children:p.noUsersFound}),e.map(e=>b.jsx(w.Card,{size:"small",appearance:"subtle",onMouseDown:e=>e.preventDefault(),onClick:()=>A(e.mail),children:b.jsx(w.Persona,{name:e.displayName,role:"gridcell",secondaryText:e.mail,avatar:{image:{src:e.avatar}}})},e.id))]}),[k.listContainer,A]);return b.jsxs(ft,{horizontal:!0,width:"100%",className:k.inputContainer,children:[b.jsx(eu,{ref:d,onSend:i,value:l,onChange:async e=>{var r;c(e),t&&t(e),null==(r=d.current)||r.focus();const n=e.lastIndexOf("@");if(-1===n||0!==n&&" "!==e[n-1])h(!1);else{const t=e.slice(n+1);await T(t);const r=d.current;if(r){const e=$(r,n),t=r.getBoundingClientRect(),i=t.top+e.top+22,o=t.left+e.left+16;g({top:i,left:o})}}},theme:o,placeholder:n,isRunning:a,onAbort:s}),b.jsxs(vt,{theme:o,anchorPoint:f,isOpen:u,onClose:()=>h(!1),excludeRefs:[d],children:[b.jsx(w.CardHeader,{header:b.jsx(w.Body1Strong,{className:k.sugestionsHeader,children:"Sugestions"})}),b.jsx(w.Divider,{}),b.jsx(P,{users:m})]})]})},exports.ChatList=uu,exports.Color=ju,exports.Color$1=yg,exports.Container=e=>{const{className:t,children:r,style:n,alignItems:i="center",justifyContent:o="center",flexDirection:a="row",centerContent:s=!0}=e,l=q.useRef(null),[c,u]=q.useState(0),[h,d]=q.useState(0),{containerStyles:p}=(e=>{const{maxWidth:t}=e,{getBaseStyles:r}=ne();return{containerStyles:q.useCallback((n,i)=>n&&i?{...r(e,n,i),maxWidth:t}:{},[r,t,e])}})(e),f=q.useMemo(()=>S.debounce(e=>{for(const t of e){const{width:e,height:r}=t.contentRect;u(e),d(r)}},200),[]);q.useEffect(()=>{const e=new _.ResizeObserver(e=>{f(e)});return l.current&&e.observe(l.current),()=>{e.disconnect(),f.cancel()}},[f]);const g=q.useMemo(()=>{if(!n)return;const{padding:e,margin:t,...r}=n;return r},[n]);return b.jsx("div",{id:"container",className:t,style:{...p(c,h),display:"flex",justifyContent:o,alignItems:i,flexDirection:a,...g},ref:l,children:s?b.jsx(mt,{children:r}):r})},exports.ContentRenderer=cu,exports.ContentType=ot,exports.CustomControlBar=({items:e,selectedItemId:t,onSelectedItem:r,renderControl:n,theme:i})=>{const o={container:T.css({display:"flex",flexWrap:"nowrap",minWidth:0,overflow:"hidden",gap:10,marginBottom:20,width:"100%"}),text1LineStyle:T.css({display:"-webkit-box",WebkitLineClamp:1,WebkitBoxOrient:"vertical",overflow:"hidden",textAlign:"start",textOverflow:"ellipsis",wordBreak:"break-word"}),button:T.css({cursor:"pointer",minWidth:107})},a=q.useCallback(e=>{r&&r(e)},[r]);return b.jsx(w.Overflow,{children:b.jsxs(w.FluentProvider,{theme:i,children:[" ",b.jsxs("div",{className:w.mergeClasses(o.container),children:[e.map(e=>{const r=e.id===t;return b.jsx(w.OverflowItem,{id:e.id,priority:r?2:1,children:n(e,r,()=>a(e.id))},e.id)}),b.jsx(Ai,{items:e,onSelectedItem:a,theme:i})," "]})]})})},exports.DataGrid=e=>{const{items:t,columns:r,defaultSelectedItems:n=[],enableSorting:i=!1,selectionMode:o="none",onSelectionChange:a,onSortChange:s,defaultSortState:l,columnSizingOptions:c,enableResizing:u=!1,noItemsMessage:h,isLoadingData:d,isLoadingDataMessage:p,dataGridBodyClassName:f,dataGridBodyStyles:g,refreshData:m}=e,y=e=>t.findIndex(t=>t===e),[x,v]=q.useState(new Set(n.map(e=>y(e)))),C=q.useRef(null),{styles:k}=yi();q.useEffect(()=>{n.length>0&&v(new Set(n.map(e=>y(e))))},[n,t]),q.useEffect(()=>{m&&v(new Set)},[m]);const S=r.map(e=>w.createTableColumn({columnId:e.column,renderHeaderCell:()=>b.jsx(w.Body1Strong,{children:e.header}),renderCell:t=>b.jsx(w.TableCellLayout,{media:e.media?e.media(t):void 0,className:null==e?void 0:e.className,style:null==e?void 0:e.style,children:e.onRender?e.onRender(t):String(t[null==e?void 0:e.column]??"")}),compare:e.order})),_=q.useCallback((e,t)=>{e.stopPropagation(),"row"===o&&a&&a([t])},[o,a]),T=q.useMemo(()=>"row"===o?k.rowSelection:"",[o,k.rowSelection]),A=q.useCallback(()=>b.jsx(w.DataGridBody,{style:g??{},className:f??"",children:({item:e,rowId:t})=>b.jsx(w.DataGridRow,{className:T,onClick:t=>_(t,e),children:({renderCell:t})=>b.jsx(w.DataGridCell,{children:t(e)})},t)}),[_,T,g,f]),P=q.useMemo(()=>t.length&&!d,[t,d]),E=q.useCallback(()=>d?b.jsx(b.Fragment,{children:p??b.jsx(mi,{direction:"vertical",gap:"s",justifyContent:"center",alignItems:"center",style:{height:"100%",minHeight:200,width:"100%"},children:b.jsx(w.Spinner,{})})}):P?b.jsx(A,{}):d||t.length?b.jsx(b.Fragment,{}):b.jsx("div",{children:h}),[P,d,t,h]);return b.jsx("div",{ref:C,children:b.jsxs(w.DataGrid,{as:"div",items:t,onSelectionChange:(e,r)=>{const n=new Set;if(r.selectedItems.forEach(e=>{const t=Number(e);isNaN(t)||n.add(t)}),v(n),a){const e=Array.from(n).map(e=>t[e]);a(e)}},sortable:i,columns:S,selectionMode:"none"===o||"row"===o?void 0:"multiple"===o?"multiselect":"single"===o?"single":void 0,selectedItems:x,defaultSortState:l,onSortChange:(e,t)=>{s&&s(t)},columnSizingOptions:c,resizableColumns:u,resizableColumnsOptions:{autoFitColumns:!1},children:[b.jsx(w.DataGridHeader,{children:b.jsx(w.DataGridRow,{children:({renderHeaderCell:e})=>b.jsx(w.DataGridHeaderCell,{children:e()})})}),b.jsx(E,{})]})})},exports.DataGridV2=bi,exports.DropdownField=({options:e,onChange:t,renderItem:r,validate:n,label:i,placeholder:o,message:a,messageType:s,required:l,size:c,hint:u})=>{const[h,d]=v.useState(""),[p,f]=v.useState(""),[g,m]=v.useState(""),y={tagPickerControl:T.css({border:`1px solid ${w.tokens.colorNeutralStroke2} !important`,borderRadius:"50px !important",backgroundColor:`${w.tokens.colorNeutralBackground1} !important`,padding:"0px 10px",boxShadow:"none",transition:"all 0.2s ease !important","&::after":{display:"none !important"},"&:hover":{borderColor:`${w.tokens.colorBrandStroke1} !important`},"&:focus-within":{borderColor:`${w.tokens.colorBrandStroke1} !important`,boxShadow:`0 0 0 2px ${w.tokens.colorBrandBackground2} !important`}})},x=q.useMemo(()=>g?"error":"warning"===s?"warning":"info"===s?"success":"none",[g,s]),C=q.useMemo(()=>g||a,[g,a]),k=q.useCallback(()=>{switch(x){case"error":return b.jsx(P.ErrorCircle12Filled,{});case"warning":return b.jsx(P.Warning12Filled,{});case"success":return b.jsx(P.CheckmarkCircle12Filled,{});default:return null}},[x]);return b.jsx(w.Field,{label:i,required:l,validationMessage:C,validationMessageIcon:k(),size:c,hint:u,validationState:x,children:b.jsx(w.Dropdown,{placeholder:o,onOptionSelect:(e,r)=>{const i=r.optionValue||"",o=r.optionText||"";d(i),f(o);const a=n?n(i):"";m(a),!a&&t&&t(i)},value:p,selectedOptions:h?[h]:[],className:y.tagPickerControl,children:e.map(e=>b.jsxs(w.Option,{value:e.value,disabled:e.disabled,checkIcon:e.checkIcon,as:e.as,text:e.text||"",children:[r&&r(e)," "]},e.value))})})},exports.EBreakPoints=J,exports.ECalendarViews=rr,exports.EGoalMetric=LL,exports.EMessageType=Y,exports.GenericOverFlowMenu=({items:e,renderItem:t,keyExtractor:r})=>{const{ref:n,overflowCount:i,isOverflowing:o}=w.useOverflowMenu();return o?b.jsxs(w.Menu,{children:[b.jsx(w.MenuTrigger,{disableButtonEnhancement:!0,children:b.jsxs(w.MenuButton,{ref:n,children:["+",i," items"]})}),b.jsx(w.MenuPopover,{children:b.jsx(w.MenuList,{children:e.map(e=>b.jsx(Pi,{id:r(e),children:t(e)},r(e)))})})]}):null},exports.Grid=e=>{const{children:t,className:r}=e,{gridStyles:n}=ct(e),i=q.useRef(null),[o,a]=q.useState(0),[s,l]=q.useState(0);return q.useEffect(()=>{let e;return i.current&&(e=new _.ResizeObserver(e=>{for(const t of e){const{width:e,height:r}=t.contentRect;a(e),l(r)}}),e.observe(i.current)),()=>{e&&e.disconnect()}},[]),b.jsx(b.Fragment,{children:b.jsx("div",{className:r,style:n(o,s),ref:i,children:t})})},exports.IconButton=It,exports.InputField=({value:e,type:t="text",shape:r="normal",onChange:n,validate:i,label:o,placeholder:a,message:s,messageType:l,required:c,size:u,hint:h,disabled:d,readOnly:p,min:f,max:g,step:m,contentBefore:y,contentAfter:C})=>{const[k,S]=v.useState(void 0!==e?String(e):""),[_,A]=v.useState(""),E={inputRoot:T.css({border:`1px solid ${w.tokens.colorNeutralStroke2} !important`,borderBottom:`1px solid ${w.tokens.colorNeutralStroke2} !important`,borderRadius:"50px !important",backgroundColor:`${w.tokens.colorNeutralBackground1} !important`,padding:"0px 10px !important",boxShadow:"none !important",transition:"all 0.2s ease","&::after":{display:"none !important",borderWidth:"0 !important",content:'"none !important"'},"&:hover":{borderColor:`${w.tokens.colorBrandStroke1} !important`},"&:focus-within":{borderColor:`${w.tokens.colorBrandStroke1} !important`,boxShadow:`0 0 0 2px ${w.tokens.colorBrandBackground2} !important`}})},M=x.useInputFieldStrings(),I=void 0!==e,B=I?String(e):k,L=v.useCallback(e=>{if(c&&""===e.trim())return"number"===t?M.numberRequired:M.fieldRequired;if("number"===t&&""!==e.trim()){const t=Number(e);if(isNaN(t))return M.invalidNumber;if(void 0!==f&&t<f)return M.valueMustBeAtLeast.replace("{0}",String(f));if(void 0!==g&&t>g)return M.valueMustBeAtMost.replace("{0}",String(g))}if(i){const r="number"===t&&""!==e.trim()?Number(e):e;return i(r)}return""},[c,t,i,f,g,M]),j=v.useCallback((e,r)=>{const i=r.value;if("number"===t&&""!==i&&!/^-?\d*\.?\d*$/.test(i))return;I||S(i);const o=L(i);if(A(o),!o&&n){const e="number"===t&&""!==i.trim()?Number(i):i;n(e)}},[t,I,L,n]),N=v.useCallback(()=>{const e=L(B);A(e)},[L,B]),D=v.useMemo(()=>_?"error":"warning"===l?"warning":"info"===l?"success":"none",[_,l]),O=v.useMemo(()=>_||s,[_,s]),F=v.useCallback(()=>{switch(D){case"error":return b.jsx(P.ErrorCircle12Filled,{});case"warning":return b.jsx(P.Warning12Filled,{});case"success":return b.jsx(P.CheckmarkCircle12Filled,{});default:return null}},[D]),R="circular"===r?E.inputRoot:void 0;return b.jsx(w.Field,{label:o,required:c,validationMessage:O,validationMessageIcon:F(),size:u,hint:h,validationState:D,children:b.jsx(w.Input,{value:B,placeholder:a,onChange:j,onBlur:N,disabled:d,readOnly:p,type:"text",inputMode:"number"===t?"decimal":"text",step:"number"===t?m:void 0,className:R,contentBefore:y,contentAfter:C})})},exports.ItemPicker=({options:e,selectedOptions:t=[],onSelectionChange:r,onSearchChange:n,onLoadMore:i,pagingInfo:o,placeholder:a,disabled:s=!1,maxSelectedOptions:l,width:c,className:u,noResultsMessage:h,loadingMessage:d,loadingMoreMessage:p,searchDebounceMs:f=300})=>{const g={container:T.css({display:"flex",flexDirection:"column",gap:w.tokens.spacingVerticalS,position:"relative"}),pickerList:T.css({maxHeight:300,overflowY:"auto",backgroundColor:w.tokens.colorNeutralBackground1,border:`1px solid ${w.tokens.colorNeutralStroke2}`,borderRadius:w.tokens.borderRadiusMedium,boxShadow:w.tokens.shadow16,scrollbarColor:`${w.tokens.colorBrandForeground1} ${w.tokens.colorNeutralBackground1}`,scrollbarWidth:"thin","&::-webkit-scrollbar-track":{borderRadius:10,borderWidth:1},"&::-webkit-scrollbar-thumb":{borderRadius:10,borderWidth:1},"&::-webkit-scrollbar":{height:7,width:7}}),optionContent:T.css({display:"flex",flexDirection:"column",gap:w.tokens.spacingVerticalXXS}),optionSecondary:T.css({fontSize:w.tokens.fontSizeBase200,color:w.tokens.colorNeutralForeground3,fontWeight:w.tokens.fontWeightRegular}),tagPickerControl:T.css({}),tagPickerInput:T.css({backgroundColor:"transparent",border:"none",outline:"none",fontSize:w.tokens.fontSizeBase300,"&::placeholder":{color:w.tokens.colorNeutralForeground4},"&:focus":{outline:"none"}})},m=x.useItemPickerStrings(),y=a||m.placeholder,C=h||m.noResultsFound,k=d||m.searching,S=p||m.loadingMore,[_,A]=v.useState(""),P=v.useRef(null),E=v.useRef(null),M=t.map(e=>e.value),I=(null==o?void 0:o.isLoading)??!1,B=(null==o?void 0:o.isLoadingMore)??!1,L=(null==o?void 0:o.hasMore)??!1,j=e.filter(e=>!M.includes(e.value)),N=v.useCallback(e=>{A(e),P.current&&clearTimeout(P.current),P.current=setTimeout(()=>{null==n||n(e)},f)},[n,f]),D=v.useCallback(e=>{if(!L||B)return;const{scrollTop:t,scrollHeight:r,clientHeight:n}=e.currentTarget;t+n>=r-100&&(null==i||i())},[L,B,i]),O=v.useCallback((i,o)=>{if("no-options"===o.value||"loading"===o.value||"loading-more"===o.value)return;const a=o.selectedOptions,s=t.filter(e=>a.includes(e.value));if(a.length>M.length){const r=a.find(e=>!M.includes(e));if(r){const n=e.find(e=>e.value===r);if(n){if(l&&t.length>=l)return;s.push(n)}}A(""),null==n||n("")}null==r||r(s)},[e,t,M,r,n,l]);return v.useEffect(()=>()=>{P.current&&clearTimeout(P.current)},[]),b.jsx("div",{className:`${g.container} ${u||""}`,...c&&{style:{width:c}},children:b.jsxs(w.TagPicker,{onOptionSelect:O,selectedOptions:M,disabled:s,children:[b.jsxs(w.TagPickerControl,{className:g.tagPickerControl,children:[b.jsx(w.TagPickerGroup,{"aria-label":m.selectedItems,children:t.map(e=>b.jsx(w.Tag,{shape:"circular",media:e.tagMedia??e.media,value:e.value,dismissible:!0,disabled:s,style:{minHeight:30},children:e.text},e.value))}),b.jsx(w.TagPickerInput,{className:g.tagPickerInput,"aria-label":m.searchItems,placeholder:y,value:_,onChange:e=>N(e.target.value),disabled:s})]}),b.jsx(w.TagPickerList,{ref:E,onScroll:D,className:g.pickerList,children:I?b.jsx(w.TagPickerOption,{value:"loading",children:k}):j.length>0?b.jsxs(b.Fragment,{children:[j.map(e=>b.jsx(w.TagPickerOption,{value:e.value,text:e.text,media:e.media,children:b.jsxs("div",{className:g.optionContent,children:[b.jsx(w.Text,{weight:"semibold",children:e.text}),e.secondaryText&&b.jsx(w.Text,{size:200,className:g.optionSecondary,children:e.secondaryText})]})},e.value)),B&&b.jsx(w.TagPickerOption,{value:"loading-more",children:S})]}):b.jsx(w.TagPickerOption,{value:"no-options",children:C})})]})})},exports.JSON_SCHEMA=gC,exports.KPICard=jL,exports.KPICardCompact=OL,exports.KPICardSkeleton=NL,exports.Kpis=e=>{const{skeletonCount:t=3,compact:r=!1}=e,n=BL(),i=FL;return q.useCallback(()=>Array.from({length:t}).map((e,t)=>b.jsx(NL,{},`kpi-skeleton-${t}`)),[t]),b.jsx(b.Fragment,{children:b.jsx(bt,{gap:"l",direction:"horizontal",padding:"l",paddingTop:"s",children:b.jsx(b.Fragment,{children:b.jsx("div",{className:n.kpiContainer,children:i.length>0?i.map(e=>r?b.jsx(OL,{dataCard:e},e.identifier):b.jsx(jL,{dataCard:e},e.identifier)):b.jsx(DL,{})})})})})},exports.Layout=e=>{const{className:t,children:r,layoutConfig:n=ht}=e,i=q.useRef(null),[o,a]=q.useState(0),[s,l]=q.useState(0),{rootStyles:c,layoutGridStyles:u}=ut({...e,layoutConfig:n}),h=((e,t)=>{let r;return q.useCallback((...n)=>{clearTimeout(r),r=setTimeout(()=>e(...n),t)},[e,t])})((e,t)=>{a(e),l(t)},200);return q.useEffect(()=>{if(!i.current)return;const e=new _.ResizeObserver(e=>{for(const t of e){const{width:e,height:r}=t.contentRect;h(e,r)}});return e.observe(i.current),()=>e.disconnect()},[h]),b.jsx("div",{id:"-Layout",className:w.mergeClasses(t,u),style:{...c(o,s),gridTemplateAreas:n.areas.join(" "),gridTemplateColumns:n.columns,gridTemplateRows:n.rows},ref:i,children:q.Children.map(r,(e,t)=>{var r;if(q.isValidElement(e)){const n=e;return b.jsx("div",{style:{gridArea:(null==(r=n.props)?void 0:r.area)??`area-${t}`},children:e},t)}return e})})},exports.LayoutItem=e=>{const{area:t,children:r}=e;return b.jsx(b.Fragment,{children:b.jsx("div",{style:{gridArea:t},children:r})})},exports.ListItemActivityMessage=({siteId:e,listId:t,itemId:r,currentUserEmail:n,strings:i,context:o})=>{var a,s,l,c,u,h,d,p,f,g,m;const{getItemActivities:y}=(e=>{const t=K(),r=e||t,n=null==r?void 0:r.graphClient,{warn:i,error:o}=Q();return{getItemActivities:v.useCallback(async(e,t,r)=>{if(!n)return i("Graph client not available for SharePoint activities"),{activities:[]};try{const i=await n.get(`/sites/${e}/lists/${t}/items/${r}/getActivitiesByInterval(startDateTime='',endDateTime='',interval='')`);return i&&i.value?{activities:i.value.map(e=>({action:e.action||{},actor:e.actor||{},times:e.times||{}}))}:{activities:[]}}catch(a){throw o("Error fetching SharePoint activities:",a instanceof Error?a:void 0),a}},[n])}})(o),C=x.useListItemActivityStrings(),{warn:w,error:k}=Q(),S=new Map([["access",{message:(null==i?void 0:i.access)||C.accessed||(null==(a=TL.get("access"))?void 0:a.message)||"",icon:b.jsx(P.OpenRegular,{style:SL})}],["comment",{message:(null==i?void 0:i.comment)||C.commented||(null==(s=TL.get("comment"))?void 0:s.message)||"",icon:b.jsx(P.CommentRegular,{style:SL})}],["create",{message:(null==i?void 0:i.create)||C.created||(null==(l=TL.get("create"))?void 0:l.message)||"",icon:b.jsx(P.AddRegular,{style:SL})}],["delete",{message:(null==i?void 0:i.delete)||C.deleted||(null==(c=TL.get("delete"))?void 0:c.message)||"",icon:b.jsx(P.DeleteRegular,{style:SL})}],["edit",{message:(null==i?void 0:i.edit)||C.edited||(null==(u=TL.get("edit"))?void 0:u.message)||"",icon:b.jsx(P.EditRegular,{style:SL})}],["mention",{message:(null==i?void 0:i.mention)||C.mentioned||(null==(h=TL.get("mention"))?void 0:h.message)||"",icon:b.jsx(P.MentionRegular,{style:SL})}],["move",{message:(null==i?void 0:i.move)||C.moved||(null==(d=TL.get("move"))?void 0:d.message)||"",icon:b.jsx(P.ArrowMoveRegular,{style:SL})}],["rename",{message:(null==i?void 0:i.rename)||C.renamed||(null==(p=TL.get("rename"))?void 0:p.message)||"",icon:b.jsx(P.RenameRegular,{style:SL})}],["restore",{message:(null==i?void 0:i.restore)||C.restored||(null==(f=TL.get("restore"))?void 0:f.message)||"",icon:b.jsx(P.ArrowSyncRegular,{style:SL})}],["share",{message:(null==i?void 0:i.share)||C.shared||(null==(g=TL.get("share"))?void 0:g.message)||"",icon:b.jsx(P.PeopleRegular,{style:SL})}],["version",{message:(null==i?void 0:i.version)||C.versioned||(null==(m=TL.get("version"))?void 0:m.message)||"",icon:b.jsx(P.HistoryRegular,{style:SL})}]]),[_,T]=q.useState({message:"",icon:b.jsx(b.Fragment,{})}),[A,E]=q.useState(!0),M=q.useRef(void 0),I=q.useRef(void 0),[B]=q.useState(30),L=q.useCallback(e=>e.user.email===n,[n]),j=q.useCallback(e=>{if(!e)return{message:"",icon:b.jsx(b.Fragment,{})};const{action:t,actor:r}=e,{displayName:n}=(null==r?void 0:r.user)||{displayName:""},i=_L.find(e=>t[e]);if(i){const e=S.get(i);if(e){return{message:`${L(r)?C.you:n} ${e.message}`,icon:e.icon}}}return{message:"",icon:b.jsx(b.Fragment,{})}},[S,L]);return q.useEffect(()=>{var e;null==(e=I.current)||e.setPlaybackRate(B/100)},[B,A]),q.useEffect(()=>{let n=!1;const i=async(o=1e3)=>{var a;if(e&&t&&r)try{const i=await y(e,t,r);if(n)return;const o=i.activities[0];M.current&&JSON.stringify(M.current)===JSON.stringify(o)||(M.current=o,T(j(o)))}catch(s){if(429===s.status){const e=null==(a=s.headers)?void 0:a.get("Retry-After"),t=e?1e3*parseInt(e,10):o;return w(`Throttled. Retrying after ${t}ms`),void setTimeout(()=>i(2*t),t)}k("Activity Error",s instanceof Error?s:void 0)}finally{n||E(!1)}},o=setTimeout(()=>{i()},1e3);return()=>{clearTimeout(o),n=!0}},[e,t,r,y,j]),b.jsx(V.Fade,{imperativeRef:I,visible:!A,children:b.jsx("div",{children:b.jsxs(ft,{horizontal:!0,verticalAlign:"center",horizontalAlign:"center",RowGap:4,columnGap:4,children:[_.icon," ",_.message]})})})},exports.ListToolbar=({items:e,farItems:t=[],isLoading:r=!1,ariaLabel:n="Toolbar",totalCount:i,className:o,showGroupDividers:a=!0})=>{const s={toolbar:T.css`
|
|
249
|
+
display: flex !important;
|
|
250
|
+
flex-wrap: nowrap !important;
|
|
251
|
+
align-items: center !important;
|
|
252
|
+
padding: ${w.tokens.spacingVerticalS} ${w.tokens.spacingHorizontalM};
|
|
253
|
+
background-color: ${w.tokens.colorNeutralBackground1};
|
|
254
|
+
border-bottom: 1px solid ${w.tokens.colorNeutralStroke2};
|
|
255
|
+
min-height: 48px;
|
|
256
|
+
gap: ${w.tokens.spacingHorizontalXS};
|
|
257
|
+
white-space: nowrap;
|
|
258
|
+
position: relative;
|
|
259
|
+
`,leftSection:T.css`
|
|
260
|
+
display: flex !important;
|
|
261
|
+
flex-wrap: nowrap !important;
|
|
262
|
+
align-items: center !important;
|
|
263
|
+
gap: ${w.tokens.spacingHorizontalXS};
|
|
264
|
+
flex: 0 0 auto !important;
|
|
265
|
+
min-width: 0;
|
|
266
|
+
`,measureSection:T.css`
|
|
267
|
+
display: flex;
|
|
268
|
+
flex-wrap: nowrap;
|
|
269
|
+
align-items: center;
|
|
270
|
+
gap: ${w.tokens.spacingHorizontalXS};
|
|
271
|
+
position: absolute;
|
|
272
|
+
top: 0;
|
|
273
|
+
left: 0;
|
|
274
|
+
visibility: hidden;
|
|
275
|
+
pointer-events: none;
|
|
276
|
+
height: 0;
|
|
277
|
+
overflow: visible;
|
|
278
|
+
z-index: -1;
|
|
279
|
+
`,rightGroup:T.css`
|
|
280
|
+
display: flex !important;
|
|
281
|
+
flex-wrap: nowrap !important;
|
|
282
|
+
align-items: center !important;
|
|
283
|
+
gap: ${w.tokens.spacingHorizontalXS};
|
|
284
|
+
flex: 0 0 auto !important;
|
|
285
|
+
margin-left: auto;
|
|
286
|
+
white-space: nowrap;
|
|
287
|
+
`,farItemsContainer:T.css`
|
|
288
|
+
display: flex;
|
|
289
|
+
flex-wrap: nowrap;
|
|
290
|
+
align-items: center;
|
|
291
|
+
gap: inherit;
|
|
292
|
+
`,toolbarButtonBase:T.css`
|
|
293
|
+
min-width: auto;
|
|
294
|
+
`,overflowButton:T.css`
|
|
295
|
+
flex-shrink: 0;
|
|
296
|
+
`,countBadge:T.css`
|
|
297
|
+
flex-shrink: 0;
|
|
298
|
+
@media (max-width: 768px) {
|
|
299
|
+
display: none;
|
|
300
|
+
}
|
|
301
|
+
`,divider:T.css`
|
|
302
|
+
height: 24px;
|
|
303
|
+
margin: 0 ${w.tokens.spacingHorizontalXS};
|
|
304
|
+
`,toolbarItem:T.css`
|
|
305
|
+
flex-shrink: 0;
|
|
306
|
+
width: fit-content;
|
|
307
|
+
white-space: nowrap;
|
|
308
|
+
`,farItemButton:T.css`
|
|
309
|
+
flex-shrink: 0;
|
|
310
|
+
`,farItemLabel:T.css`
|
|
311
|
+
@media (max-width: 768px) {
|
|
312
|
+
display: none;
|
|
313
|
+
}
|
|
314
|
+
`},l=q.useRef(null),c=q.useRef(null),u=q.useRef(null),h=q.useRef(null),d=q.useMemo(()=>e.filter(e=>!e.isFarItem&&!1!==e.visible),[e]),p=q.useMemo(()=>[...e.filter(e=>e.isFarItem&&!1!==e.visible),...t.filter(e=>!1!==e.visible)],[e,t]),f=q.useMemo(()=>vL(p),[p]),g=q.useMemo(()=>function(e,t){const r=[],n=vL(e),i=Array.from(n.entries());for(let o=0;o<i.length;o++){const[,e]=i[o],n=o===i.length-1;for(const t of e)t.dividerBefore&&r.push({type:"divider",key:`${t.key}-div-before`}),r.push({type:"item",item:t,key:t.key}),t.dividerAfter&&r.push({type:"divider",key:`${t.key}-div-after`});t&&!n&&r.push({type:"divider",key:`group-div-${o}`})}return r}(d,a),[d,a]),m=xL(l,u,h,g.length),y=q.useMemo(()=>{const e=new Set;for(let t=0;t<m&&t<g.length;t++)"item"===g[t].type&&e.add(g[t].key);return e},[g,m]),x=q.useMemo(()=>d.filter(e=>!y.has(e.key)),[d,y]),v=x.length>0;return b.jsxs("div",{ref:l,role:"toolbar","aria-label":n,className:`${s.toolbar} ${o||""}`,children:[b.jsx("div",{ref:h,className:s.measureSection,"aria-hidden":"true",children:g.map(e=>"divider"===e.type?b.jsx(w.ToolbarDivider,{},e.key):b.jsx(bL,{item:e.item,isLoading:r,itemClass:s.toolbarItem},e.key))}),b.jsxs("div",{ref:c,className:s.leftSection,children:[g.map((e,t)=>t>=m?null:"divider"===e.type?b.jsx(w.ToolbarDivider,{},e.key):b.jsx(bL,{item:e.item,isLoading:r,itemClass:s.toolbarItem},e.key)),v&&b.jsxs(w.Menu,{children:[b.jsx(w.MenuTrigger,{disableButtonEnhancement:!0,children:b.jsx(w.Tooltip,{content:`${x.length} more actions`,relationship:"label",children:b.jsx(w.ToolbarButton,{className:s.overflowButton,icon:b.jsx(P.MoreHorizontalRegular,{}),"aria-label":`${x.length} more actions`})})}),b.jsx(w.MenuPopover,{children:b.jsx(w.MenuList,{children:x.map(e=>b.jsx(w.MenuItem,{icon:e.icon,disabled:e.disabled||r,onClick:e.onClick,children:e.label||e.tooltip||e.key},e.key))})})]}),void 0!==i&&i>0&&b.jsx(w.Badge,{appearance:"filled",color:"informative",className:s.countBadge,children:b.jsxs(w.Text,{size:200,children:[i," items"]})})]}),b.jsx("div",{ref:u,className:s.rightGroup,children:p.length>0&&b.jsx("div",{className:s.farItemsContainer,children:Array.from(f.entries()).map(([e,t],n)=>((e,t,n)=>{const i=[];for(const o of e)o.dividerBefore&&i.push(b.jsx(w.ToolbarDivider,{},`${o.key}-divider-before`)),i.push(b.jsx(bL,{item:o,isLoading:r,itemClass:s.farItemButton,labelClass:s.farItemLabel},o.key)),o.dividerAfter&&i.push(b.jsx(w.ToolbarDivider,{},`${o.key}-divider-after`));return a&&!n&&i.push(b.jsx(w.ToolbarDivider,{},`group-divider-${t}`)),i})(t,n,n===f.size-1))})})]})},exports.LivePersona=mL,exports.MapCache=xw,exports.MaplibreWorldMap=({data:e,onClick:t,mapStyleUrl:r="https://api.maptiler.com/maps/topo-v2/style.json?key=fYK99t1qjkKbINH0saMD",style:n,fitPadding:i=20})=>{const o=v.useRef(null),a=(e=>{const[t,r]=v.useState(void 0),{error:n}=Q();return v.useEffect(()=>{let t=!1;return(async()=>{try{const n=await fetch(e),i=await n.json();t||r(i)}catch(i){n("Error loading style:",i instanceof Error?i:void 0)}})(),()=>{t=!0}},[e]),t})(r),s=e,{defaultMapStyles:l,flagClass:c}={defaultMapStyles:v.useMemo(()=>({width:"100%",height:"600px",fontFamily:w.tokens.fontFamilyBase}),[]),flagClass:v.useMemo(()=>T.css({width:"32px",height:"20px",border:`1px solid ${w.tokens.colorNeutralBackground1}`,borderRadius:w.tokens.borderRadiusSmall,boxShadow:w.tokens.shadow4,transition:"transform 0.1s ease"}),[])},u=x.useWorldMapStrings();return v.useEffect(()=>{if(!o.current||0===s.length)return;const e=s.map(e=>e.coordinates[0]),t=s.map(e=>e.coordinates[1]);o.current.getMap().fitBounds([[Math.min(...e),Math.min(...t)],[Math.max(...e),Math.max(...t)]],{padding:i})},[s,i]),a?b.jsxs(Xi,{ref:o,initialViewState:{longitude:0,latitude:20,zoom:1},style:{...n??l},mapStyle:a,pixelRatio:window.devicePixelRatio,children:[b.jsx(io,{mapRef:o,initialViewState:{longitude:0,latitude:20,zoom:1}}),s.map(e=>b.jsx(Qi,{longitude:e.coordinates[0],latitude:e.coordinates[1],anchor:"center",children:b.jsx(lo,{data:e,onClick:t,flagClass:c})},e.id))]}):b.jsx(w.Text,{children:u.loadingMapStyle})},exports.MarkdownRenderer=su,exports.Mensions=ru,exports.MensionsExample=({context:e})=>{const[t,r]=v.useState(""),[n,i]=v.useState(""),o=v.useRef(null),a=v.useRef(null);return b.jsxs(ft,{RowGap:20,children:[b.jsxs("div",{children:[b.jsx("h3",{children:"Input with @ mentions"}),b.jsx(w.Input,{ref:o,value:t,onChange:(e,t)=>r(t.value),placeholder:"Type @ to mention someone..."}),b.jsx(ru,{context:e,inputValue:t,parentRef:o,mentionChars:["@"],onUserSelect:(e,n)=>{const i=new RegExp(`${n.replace(/[.*+?^${}()|[\]\\]/g,"\\$&")}(\\w*)$`),a=t.replace(i,`${n}${e.displayName} `);r(a),setTimeout(()=>{var e;null==(e=o.current)||e.focus()},0)},theme:w.webLightTheme,suggestionsHeader:"Mention User",maxSuggestions:8})]}),b.jsxs("div",{children:[b.jsx("h3",{children:"Textarea with @ and # mentions"}),b.jsx(w.Textarea,{ref:a,value:n,onChange:(e,t)=>i(t.value),placeholder:"Type @ to mention someone or # for tags...",rows:4}),b.jsx(ru,{context:e,inputValue:n,parentRef:a,mentionChars:["@","#"],onUserSelect:(e,t)=>{const r=new RegExp(`${t.replace(/[.*+?^${}()|[\]\\]/g,"\\$&")}(\\w*)$`),o=n.replace(r,`${t}${e.displayName} `);i(o),setTimeout(()=>{var e;null==(e=a.current)||e.focus()},0)},theme:w.webLightTheme,suggestionsHeader:"Select User or Tag",maxSuggestions:10,userFilter:(e,t)=>{var r;return e.displayName.toLowerCase().includes(t.toLowerCase())||((null==(r=e.mail)?void 0:r.toLowerCase().includes(t.toLowerCase()))??!1)}})]})]})},exports.MermaidDiagram=e=>{const{source:t,url:r,theme:n,backgroundColor:i,className:o,styles:a,zoomable:s=!1,onRendered:l,onError:c,loadingContent:u,errorContent:h}=e,d=fL(e),p=q.useRef(null),f=q.useRef(null),g=(e=>{const[t,r]=q.useState(!1);return q.useEffect(()=>{const t=e.current;if(!t)return;const n=getComputedStyle(t).getPropertyValue("--colorNeutralBackground1").trim();if(n&&n.startsWith("#")&&n.length>=7){const e=parseInt(n.substring(1,3),16),t=parseInt(n.substring(3,5),16),i=parseInt(n.substring(5,7),16);r(.299*e+.587*t+.114*i<128)}}),t})(p),m=n??(g?"dark":"default"),[y,v]=q.useState(null),[C,k]=q.useState(null),[S,_]=q.useState(!1),[T,A]=q.useState(null),{loading:P,errorMessage:E,noSource:M}=x.useMermaidDiagramStrings();q.useEffect(()=>{if(t)return A(t),void k(null);if(r){let e=!1;return _(!0),k(null),fetch(r).then(e=>{if(!e.ok)throw new Error(`Failed to fetch ${r}: ${e.status} ${e.statusText}`);return e.text()}).then(t=>{e||(A(t),_(!1))}).catch(t=>{if(!e){const e=t instanceof Error?t:new Error(String(t));k(e),_(!1),null==c||c(e)}}),()=>{e=!0}}A(null)},[t,r,c]),q.useEffect(()=>{if(!T)return void v(null);let e=!1;const t="mermaid-diagram-"+ ++gL;return pL.initialize({startOnLoad:!1,theme:m,securityLevel:"loose",fontFamily:w.tokens.fontFamilyBase,suppressErrorRendering:!0}),pL.render(t,T).then(({svg:t})=>{e||(v(t),k(null),null==l||l(t))}).catch(r=>{if(!e){const e=r instanceof Error?r:new Error(String(r));k(e),v(null),null==c||c(e)}const n=document.getElementById(t);null==n||n.remove()}),()=>{e=!0;const r=document.getElementById(t);null==r||r.remove()}},[T,m,l,c]);const[I,B]=q.useState(1),[L,j]=q.useState({x:0,y:0}),N=q.useRef(!1),D=q.useRef({x:0,y:0});q.useEffect(()=>{const e=p.current;if(!e||!s)return;const t=e=>{e.preventDefault();const t=e.deltaY>0?-.1:.1;B(e=>Math.min(Math.max(e+t,.25),4))},r=e=>{N.current=!0,D.current={x:e.clientX,y:e.clientY}},n=e=>{if(!N.current)return;const t=e.clientX-D.current.x,r=e.clientY-D.current.y;D.current={x:e.clientX,y:e.clientY},j(e=>({x:e.x+t,y:e.y+r}))},i=()=>{N.current=!1};return e.addEventListener("wheel",t,{passive:!1}),e.addEventListener("mousedown",r),e.addEventListener("mousemove",n),e.addEventListener("mouseup",i),e.addEventListener("mouseleave",i),()=>{e.removeEventListener("wheel",t),e.removeEventListener("mousedown",r),e.removeEventListener("mousemove",n),e.removeEventListener("mouseup",i),e.removeEventListener("mouseleave",i)}},[s]),q.useEffect(()=>{B(1),j({x:0,y:0})},[T]),q.useEffect(()=>{const e=f.current;e&&(e.innerHTML=y??"")},[y]);const O=[d.root,o].filter(Boolean).join(" ");if(S)return b.jsx(bt,{className:O,style:a,alignItems:"center",justifyContent:"center",overflow:"hidden",background:i,children:b.jsx(bt,{className:d.loading,alignItems:"center",justifyContent:"center",padding:"xxl",children:u??b.jsx(St,{size:"small",label:P})})});if(C)return b.jsx(bt,{className:O,style:a,alignItems:"center",justifyContent:"center",overflow:"hidden",background:i,children:h?h(C):b.jsx(_i,{message:E,messageType:Y.ERROR})});if(!y)return b.jsx(bt,{className:O,style:a,alignItems:"center",justifyContent:"center",overflow:"hidden",background:i,children:b.jsx(bt,{className:d.loading,alignItems:"center",justifyContent:"center",padding:"xxl",children:b.jsx(w.Text,{children:M})})});const F=s?{transform:`translate(${L.x}px, ${L.y}px) scale(${I})`,transformOrigin:"center center"}:void 0;return b.jsx(bt,{ref:p,className:O,style:a,alignItems:"center",justifyContent:"center",overflow:s?"auto":"hidden",background:i,children:b.jsx(bt,{ref:f,className:d.svgContainer,alignItems:"center",justifyContent:"center",style:F,children:b.jsx(b.Fragment,{})})})},exports.Navigation=Ei,exports.NoKpisCard=DL,exports.OptionTime=pi,exports.Popup=vt,exports.RenderAdaptiveCard=({card:e,data:t})=>{const r=v.useRef(null);return v.useEffect(()=>{if(!r.current)return;r.current.innerHTML="";const n=new R.Template(e).expand({$root:t}),i=new G.AdaptiveCard;null==i||i.parse(n);const o=i.render();o&&r.current.appendChild(o)},[e,t]),b.jsx("div",{ref:r})},exports.RenderDialog=Ci,exports.RenderDrawer=e=>{const{isOpen:t,onOpenChange:r,title:n,headerActions:i,footerActions:o,size:a,separator:s,type:l,style:c,children:u,position:h,classNameHeader:d="",classNameBody:p="",classNameFooter:f=""}=e,g=q.useCallback((e,t)=>{r&&r(t.open)},[r]),m=b.jsxs(b.Fragment,{children:[b.jsx(w.DrawerHeader,{className:d,children:b.jsx(w.DrawerHeaderTitle,{style:{width:"100%"},action:i,children:n})}),b.jsx(w.DrawerBody,{className:p,children:u}),b.jsx(w.DrawerFooter,{className:f,children:o})]});return"inline"===l?b.jsx(w.InlineDrawer,{separator:s,open:t,size:a,style:c,position:h,children:m}):b.jsx(w.OverlayDrawer,{open:t,onOpenChange:g,size:a,style:c,position:h,children:m})},exports.RenderHeader=e=>{const{onDismiss:t,title:r,description:n,icon:i,showCloseButton:o=!0}=e,a=wi();return b.jsx(b.Fragment,{children:b.jsxs("div",{id:"RenderHedaermain",className:a.renderHeaderContent,children:[b.jsxs("div",{className:a.renderHeaderHeader,children:[b.jsx(w.Button,{style:{display:o?"block":"none"},appearance:"subtle",className:a.closeButton,onClick:e=>{e.stopPropagation(),e.preventDefault(),t(!1)},icon:b.jsx(P.Dismiss24Regular,{})}),b.jsxs("div",{className:a.renderHeaderTitleContainer,children:[q.isValidElement(i)?i:b.jsx(M.Icon,{icon:i}),b.jsxs("div",{className:a.dialogTitleAndDescriptionContainer,children:[q.isValidElement(r)?r:b.jsx(w.Subtitle1,{className:a.renderHeaderTitle,children:r}),q.isValidElement(n)?n:b.jsx(w.Caption1,{className:a.renderHeaderDescription,children:n})]})]})]}),b.jsx("div",{className:a.divider})]})})},exports.RenderLabel=wt,exports.RenderSpinner=St,exports.Rgb=Fg,exports.SearchControl=({placeholder:e,onSearch:t,onChange:r,onClear:n,disabled:i=!1,className:o,width:a,value:s,shape:l="circular",contentBefore:c,size:u})=>{const[h,d]=v.useState(""),p=v.useRef(null),{searchBoxStyles:f,searchBoxNormalStyles:g,iconWrapperStyles:m}={searchBoxStyles:ai`
|
|
315
|
+
border: 1px solid ${w.tokens.colorNeutralStroke2};
|
|
316
|
+
border-radius: 50px;
|
|
317
|
+
background-color: ${w.tokens.colorNeutralBackground1};
|
|
318
|
+
padding: 5px 10px;
|
|
319
|
+
box-shadow: none;
|
|
320
|
+
transition: all 0.2s ease;
|
|
321
|
+
position: relative;
|
|
322
|
+
|
|
323
|
+
&::after {
|
|
324
|
+
display: none !important;
|
|
325
|
+
}
|
|
326
|
+
|
|
327
|
+
&:hover {
|
|
328
|
+
border-color: ${w.tokens.colorBrandStroke1};
|
|
329
|
+
}
|
|
330
|
+
|
|
331
|
+
&:focus-within {
|
|
332
|
+
outline: none;
|
|
333
|
+
border-color: ${w.tokens.colorBrandStroke1};
|
|
334
|
+
}
|
|
335
|
+
|
|
336
|
+
&:disabled {
|
|
337
|
+
opacity: 0.6;
|
|
338
|
+
cursor: not-allowed;
|
|
339
|
+
border-color: ${w.tokens.colorNeutralStroke3};
|
|
340
|
+
background-color: ${w.tokens.colorNeutralBackground3};
|
|
341
|
+
}
|
|
342
|
+
|
|
343
|
+
input {
|
|
344
|
+
border: none !important;
|
|
345
|
+
outline: none !important;
|
|
346
|
+
background: transparent !important;
|
|
347
|
+
font-size: ${w.tokens.fontSizeBase300};
|
|
348
|
+
color: ${w.tokens.colorNeutralForeground1};
|
|
349
|
+
box-shadow: none !important;
|
|
350
|
+
|
|
351
|
+
&::placeholder {
|
|
352
|
+
color: ${w.tokens.colorNeutralForeground3};
|
|
353
|
+
}
|
|
354
|
+
|
|
355
|
+
&:focus {
|
|
356
|
+
border: none !important;
|
|
357
|
+
outline: none !important;
|
|
358
|
+
box-shadow: none !important;
|
|
359
|
+
}
|
|
360
|
+
}
|
|
361
|
+
|
|
362
|
+
* {
|
|
363
|
+
&:focus {
|
|
364
|
+
outline: none !important;
|
|
365
|
+
box-shadow: none !important;
|
|
366
|
+
}
|
|
367
|
+
}
|
|
368
|
+
`,searchBoxNormalStyles:ai`
|
|
369
|
+
border: 1px solid ${w.tokens.colorNeutralStroke2};
|
|
370
|
+
border-radius: ${w.tokens.borderRadiusMedium};
|
|
371
|
+
background-color: ${w.tokens.colorNeutralBackground1};
|
|
372
|
+
padding: 5px 10px;
|
|
373
|
+
box-shadow: none;
|
|
374
|
+
transition: all 0.2s ease;
|
|
375
|
+
position: relative;
|
|
376
|
+
|
|
377
|
+
&::after {
|
|
378
|
+
display: none !important;
|
|
379
|
+
}
|
|
380
|
+
|
|
381
|
+
&:hover {
|
|
382
|
+
border-color: ${w.tokens.colorBrandStroke1};
|
|
383
|
+
}
|
|
384
|
+
|
|
385
|
+
&:focus-within {
|
|
386
|
+
outline: none;
|
|
387
|
+
border-color: ${w.tokens.colorBrandStroke1};
|
|
388
|
+
}
|
|
389
|
+
|
|
390
|
+
&:disabled {
|
|
391
|
+
opacity: 0.6;
|
|
392
|
+
cursor: not-allowed;
|
|
393
|
+
border-color: ${w.tokens.colorNeutralStroke3};
|
|
394
|
+
background-color: ${w.tokens.colorNeutralBackground3};
|
|
395
|
+
}
|
|
396
|
+
|
|
397
|
+
input {
|
|
398
|
+
border: none !important;
|
|
399
|
+
outline: none !important;
|
|
400
|
+
background: transparent !important;
|
|
401
|
+
font-size: ${w.tokens.fontSizeBase300};
|
|
402
|
+
color: ${w.tokens.colorNeutralForeground1};
|
|
403
|
+
box-shadow: none !important;
|
|
404
|
+
|
|
405
|
+
&::placeholder {
|
|
406
|
+
color: ${w.tokens.colorNeutralForeground3};
|
|
407
|
+
}
|
|
408
|
+
|
|
409
|
+
&:focus {
|
|
410
|
+
border: none !important;
|
|
411
|
+
outline: none !important;
|
|
412
|
+
box-shadow: none !important;
|
|
413
|
+
}
|
|
414
|
+
}
|
|
415
|
+
|
|
416
|
+
* {
|
|
417
|
+
&:focus {
|
|
418
|
+
outline: none !important;
|
|
419
|
+
box-shadow: none !important;
|
|
420
|
+
}
|
|
421
|
+
}
|
|
422
|
+
`,iconWrapperStyles:ai`
|
|
423
|
+
display: flex;
|
|
424
|
+
align-items: center;
|
|
425
|
+
padding: 2px;
|
|
426
|
+
margin-right: 8px;
|
|
427
|
+
`},y=x.useSearchControlStrings(),b=e||y.placeholder,C=void 0!==s,k=C?s:h,S="circular"===l?f:g,_=v.useCallback((e,t)=>{C||d(t.value),null==r||r(t.value)},[C,r]),T=v.useCallback(()=>{var e;C||d(""),null==(e=p.current)||e.blur(),null==n||n(),null==t||t("")},[C,n,t]),A=v.useCallback(e=>{var r;"Enter"===e.key&&k.trim()?null==t||t(k.trim()):"Escape"===e.key&&(null==(r=p.current)||r.blur(),C||d(""),null==n||n())},[k,C,t,n]),E=c??ni("span",{css:m,children:ni(P.SearchRegular,{})});return ni(w.SearchBox,{ref:p,css:S,className:o,style:{width:a},placeholder:b,value:k,onChange:_,onKeyDown:A,disabled:i,size:u,contentBefore:E,dismiss:{onClick:T}})},exports.SelectDay=or,exports.SelectMonth=lr,exports.SelectTime=fi,exports.SelectView=({onChange:e,defaultKey:t,label:r,options:n=[]})=>{const[i,o]=v.useState(()=>n.map(e=>({...e,selected:e.key===(t??"status")})));v.useEffect(()=>{const t=i.find(e=>e.selected);t&&e(t.key)},[]);const a=v.useCallback(t=>{const r=i.map(e=>({...e,selected:e.key===t.key}));o(r),e(t.key)},[i,e]);return b.jsxs(bt,{gap:"s",alignItems:"center",children:[r&&b.jsx(w.Label,{children:r}),b.jsx(Pt,{options:i,onSelected:a,styles:{width:220}})]})},exports.SelectWeek=dr,exports.Set=sI,exports.ShareDialog=({isOpen:e,options:t,onClose:r})=>{const{log:n}=Q(),[i,o]=v.useState(void 0);n(i||"");const a=v.useRef(null),[s,l]=v.useState(400),{siteUrl:c,listId:u,itemId:h,name:d}=t,p=v.useCallback(()=>{r()},[r]),f=v.useCallback(e=>{if(e.origin!==window.location.origin)return;n("Message from iframe:",e.data);const{name:t,height:r}=JSON.parse(e.data);switch(t){case"share_dismiss":p();break;case"share_resize":l(r)}},[p]);return v.useEffect(()=>(window.addEventListener("message",f),()=>{window.removeEventListener("message",f)}),[f]),v.useEffect(()=>{if(e){const e="sharePoint",t=0,r="",i=(new Date).getTime(),a=!1,s=encodeURIComponent(window.location.origin),l=encodeURIComponent(d),p=`${c}/_layouts/15/sharedialog.aspx?listId=${u}&listItemId=${h}&clientId=${e}&policyTip=${t}&folderColor=${r}&clickTime=${i}&ma=0&fullScreenMode=${a}&itemName= ${l}&channelId=&origin=${s}`;n(p),o(p)}else o(void 0)},[e,c,u,h]),b.jsx(Ci,{isOpen:e,onDismiss:p,maxHeight:"fit-content",children:b.jsx("iframe",{ref:a,src:i||"",style:{width:"100%",height:s,border:"none"},onLoad:()=>n("Iframe loaded")})})},exports.ShowError=({title:e,message:t})=>{const r=ki();return b.jsx(w.Card,{className:r.container,children:b.jsxs(bt,{gap:"l",alignItems:"center",children:[b.jsx(P.ErrorCircleRegular,{className:r.icon}),b.jsxs(bt,{gap:"s",alignItems:"center",children:[b.jsx(w.Title3,{className:r.title,children:e}),b.jsx(w.Body1,{className:r.message,children:t})]})]})})},exports.ShowMessage=_i,exports.Space=e=>{const t=q.useRef(null),[r,n]=q.useState(0),{spaceStyles:i}=dt(e);return q.useEffect(()=>{let e;return t.current&&(e=new _.ResizeObserver(e=>{for(const t of e){const{width:e}=t.contentRect;n(e)}}),e.observe(t.current)),()=>{e&&e.disconnect()}},[]),b.jsx(b.Fragment,{children:b.jsx("div",{id:"-space",style:i(r),ref:t})})},exports.SplitPane=e=>{const{direction:t="horizontal",defaultSize:r="50%",minSize:n=100,maxSize:i=1/0,minSecondarySize:o=100,resizable:a=!0,onResize:s,onResizeEnd:l,primaryContent:c,secondaryContent:u,className:h,styles:d}=e,p=yt(e),f="horizontal"===t,g=q.useRef(null),m=q.useRef(null),[y,x]=q.useState(null),[v,C]=q.useState(!1),[w,k]=q.useState(!1);q.useEffect(()=>{if(null!==y)return;if(!g.current)return;const e=g.current.getBoundingClientRect(),t=f?e.width:e.height;if("number"==typeof r)x(Math.min(Math.max(r,n),i));else if("string"==typeof r&&r.endsWith("%")){const e=parseFloat(r)/100;x(Math.min(Math.max(t*e,n),i))}else x(t/2)},[r,n,i,f,y]);const S=q.useCallback(t=>{if(!g.current)return t;const r=g.current.getBoundingClientRect(),a=(f?r.width:r.height)-(e.resizerSize??6)-o,s=Math.min(i,a);return Math.min(Math.max(t,n),s)},[f,i,n,o,e.resizerSize]),_=q.useCallback(e=>{if(!a)return;e.preventDefault(),C(!0);const t=f?e.clientX:e.clientY,r=y??0,n=e=>{const n=f?e.clientX:e.clientY,i=S(r+(n-t));x(i),null==s||s(i)},i=()=>{if(C(!1),document.removeEventListener("mousemove",n),document.removeEventListener("mouseup",i),m.current){const e=f?m.current.getBoundingClientRect().width:m.current.getBoundingClientRect().height;null==l||l(e)}};document.addEventListener("mousemove",n),document.addEventListener("mouseup",i)},[a,f,y,S,s,l]),T=q.useCallback(e=>{if(!a)return;C(!0);const t=e.touches[0],r=f?t.clientX:t.clientY,n=y??0,i=e=>{const t=e.touches[0],i=f?t.clientX:t.clientY,o=S(n+(i-r));x(o),null==s||s(o)},o=()=>{if(C(!1),document.removeEventListener("touchmove",i),document.removeEventListener("touchend",o),m.current){const e=f?m.current.getBoundingClientRect().width:m.current.getBoundingClientRect().height;null==l||l(e)}};document.addEventListener("touchmove",i,{passive:!1}),document.addEventListener("touchend",o)},[a,f,y,S,s,l]),A=q.useCallback(e=>{if(!a||null===y)return;const t=e.shiftKey?50:10;let r=0;if(f?"ArrowLeft"===e.key?r=-t:"ArrowRight"===e.key&&(r=t):"ArrowUp"===e.key?r=-t:"ArrowDown"===e.key&&(r=t),0!==r){e.preventDefault();const t=S(y+r);x(t),null==s||s(t),null==l||l(t)}},[a,y,f,S,s,l]);q.useEffect(()=>(v?(document.body.style.userSelect="none",document.body.style.cursor=f?"col-resize":"row-resize"):(document.body.style.userSelect="",document.body.style.cursor=""),()=>{document.body.style.userSelect="",document.body.style.cursor=""}),[v,f]);const P=q.useRef(null),E=[p.resizer,w||v?p.resizerActive:""].filter(Boolean).join(" ");return q.useEffect(()=>{if(!a||!P.current)return;const e=P.current,t=e=>_(e),r=e=>T(e),n=e=>A(e),i=()=>k(!0),o=()=>k(!1);return e.addEventListener("mousedown",t),e.addEventListener("touchstart",r),e.addEventListener("keydown",n),e.addEventListener("mouseenter",i),e.addEventListener("mouseleave",o),()=>{e.removeEventListener("mousedown",t),e.removeEventListener("touchstart",r),e.removeEventListener("keydown",n),e.removeEventListener("mouseenter",i),e.removeEventListener("mouseleave",o)}},[a,_,T,A]),b.jsxs(bt,{ref:g,className:[p.root,h].filter(Boolean).join(" "),style:{height:"100%",width:"100%",...d},direction:f?"horizontal":"vertical",overflow:"hidden",children:[b.jsx(bt,{ref:m,className:p.pane(y??void 0),style:{flex:"0 0 auto"},children:c}),a&&b.jsx(bt,{ref:P,className:E,alignItems:"center",justifyContent:"center",style:{flex:"0 0 auto"},children:b.jsxs(bt,{className:p.resizerGrip,direction:f?"vertical":"horizontal",alignItems:"center",justifyContent:"center",children:[b.jsx(bt,{className:p.gripDot,children:""}),b.jsx(bt,{className:p.gripDot,children:""}),b.jsx(bt,{className:p.gripDot,children:""})]})}),b.jsx(bt,{className:p.secondaryPane,style:{flex:1,minWidth:0,minHeight:0},children:u})]})},exports.Stack=vw,exports.Stack$1=ft,exports.StackItem=e=>{const{children:t,grow:r,disableShrink:n,shrink:i,order:o,alignSelf:a,verticalFill:s}=e,{getBaseStyles:l}=ne(),c=q.useRef(null),[u,h]=q.useState(0),[d,p]=q.useState(0),f=l(e,u,d);q.useEffect(()=>{let e;return c.current&&(e=new _.ResizeObserver(e=>{for(const t of e){const{width:e,height:r}=t.contentRect;h(e),p(r)}}),e.observe(c.current)),()=>{e&&e.disconnect()}},[]);const g={...f,alignSelf:a,order:o,height:s?"100%":"auto",flexGrow:r?"boolean"==typeof r?1:r:void 0,flexShrink:n||!r&&!i?0:1,minWidth:0,minHeight:0,width:"auto"};return b.jsx(b.Fragment,{children:b.jsx("div",{ref:c,style:g,children:t})})},exports.StackV2=bt,exports.StackedUsers=({users:e,maxVisible:t=5,avatarSize:r=32,showHoverCard:n=!0,context:i,className:o,layout:a="stack",overflowText:s})=>{const l={container:T.css({display:"flex",alignItems:"center",gap:"4px"}),stackLayout:T.css({"& > *:not(:first-child)":{marginLeft:"-8px"}}),spreadLayout:T.css({display:"flex",flexDirection:"row",gap:"8px","& > *":{marginLeft:"0"}}),userCardWrapper:T.css({position:"relative",zIndex:1,transition:"transform 0.2s ease, z-index 0.2s ease","&:hover":{transform:"scale(1.1)",zIndex:10}}),overflowButton:T.css({backgroundColor:w.tokens.colorNeutralBackground1,border:`2px solid ${w.tokens.colorNeutralStroke1}`,borderRadius:"50%",color:w.tokens.colorNeutralForeground1,cursor:"pointer",display:"flex",alignItems:"center",justifyContent:"center",fontSize:"12px",fontWeight:600,minWidth:"32px",minHeight:"32px",position:"relative",zIndex:1,transition:"all 0.2s ease","&:hover":{backgroundColor:w.tokens.colorNeutralBackground1Hover,zIndex:10}}),popover:T.css({maxWidth:"300px",padding:"12px"}),popoverUserList:T.css({display:"flex",flexDirection:"column",gap:"8px"}),popoverUserCard:T.css({padding:"4px",borderRadius:"4px",transition:"background-color 0.2s ease","&:hover":{backgroundColor:w.tokens.colorNeutralBackground1Hover}})},{warn:c}=Q(),{visibleUsers:u,overflowUsers:h}=v.useMemo(()=>{if(!e||0===e.length)return{visibleUsers:[],overflowUsers:[]};return{visibleUsers:e.slice(0,t),overflowUsers:e.slice(t)}},[e,t]),d=v.useMemo(()=>s||`+${h.length}`,[s,h.length]);return e&&0!==e.length?i?b.jsxs(bt,{direction:"horizontal",alignItems:"start",gap:"stack"===a?"4px":"12px",className:`${"stack"===a?l.stackLayout:l.spreadLayout} ${o||""}`,children:[u.map((e,t)=>b.jsx("div",{className:l.userCardWrapper,children:b.jsx(kL,{userId:e.id,avatarSize:r,showHoverCard:n??!0,context:i,avatarOnly:!0})},`user-${e.id||t}`)),h.length>0&&b.jsxs(w.Popover,{withArrow:!0,children:[b.jsx(w.PopoverTrigger,{disableButtonEnhancement:!0,children:b.jsx(w.Button,{className:l.overflowButton,style:{width:`${r}px`,height:`${r}px`,fontSize:r>40?"14px":"12px"},appearance:"subtle",children:d})}),b.jsx(w.PopoverSurface,{className:l.popover,children:b.jsx("div",{className:l.popoverUserList,children:h.map((e,t)=>b.jsx("div",{className:l.popoverUserCard,children:b.jsx(kL,{userId:e.id,avatarSize:32,showHoverCard:n??!0,context:i,textPosition:"after",avatarOnly:!1})},`overflow-user-${e.id||t}`))})})]})]}):(c("StackedUsers: context is required to display user cards"),null):null},exports.Symbol=RC,exports.TIME_RADIO_GROUP=ci,exports.TypographyControl=e=>{const{fontSize:t,fontWeight:r,numberOfLines:n,as:i,padding:o,paddingTop:a,paddingBottom:s,paddingLeft:l,paddingRight:c,margin:u,marginTop:h,marginBottom:d,marginLeft:p,marginRight:f,children:g,style:m,className:y,color:x,block:v,truncate:C,wrap:k}=e,S=T.css({color:x,padding:o&&Tt[o]?Tt[o]:o,paddingTop:a&&Tt[a]?Tt[a]:a,paddingBottom:s&&Tt[s]?Tt[s]:s,paddingLeft:l&&Tt[l]?Tt[l]:l,paddingRight:c&&Tt[c]?Tt[c]:c,margin:u&&Tt[u]?Tt[u]:u,marginTop:h&&Tt[h]?Tt[h]:h,marginBottom:d&&Tt[d]?Tt[d]:d,marginLeft:p&&Tt[p]?Tt[p]:p,marginRight:f&&Tt[f]?Tt[f]:f}),_={...m,...t?{fontSize:_t[t]?_t[t]:t}:{},...r?{fontWeight:At[r]?At[r]:r}:{},...n?{display:"-webkit-box",WebkitBoxOrient:"vertical",overflow:"hidden",WebkitLineClamp:n}:{}};return b.jsx(w.Text,{as:i,className:w.mergeClasses(y,S),style:_,block:v,truncate:C,wrap:k,children:g})},exports.Uint8Array=Mw,exports.UniversalProvider=({context:e,children:t})=>b.jsx(Z.Provider,{value:e,children:t}),exports.UserCard=kL,exports.Utils=ku,exports.VideoPlayer=e=>{const{url:t,controls:r=!0,width:n="100%",height:i="100%",loop:o=!1,muted:a=!1}=e,[s,l]=v.useState(!1),c=Mi(e);return b.jsx("div",{className:c.videoPlayerContainer,children:b.jsx(L,{url:t,controls:r,width:n,height:i,playing:s,loop:o,muted:a,onPause:()=>l(!1),onPlay:()=>l(!0),className:c.reactPlayer})})},exports.ZERO_WIDTH_SPACE="",exports.__export=yu,exports.__name=mu,exports.abs=py,exports.acos=function(e){return e>1?0:e<-1?Cy:Math.acos(e)},exports.array=_y,exports.arrayLikeKeys=vk,exports.asin=function(e){return e>=1?wy:e<=-1?-wy:Math.asin(e)},exports.assignValue=gk,exports.assignWithDepth_default=od,exports.atan2=fy,exports.baseFor=Sw,exports.baseGetTag=UC,exports.baseKeys=iI,exports.baseUnary=ak,exports.calculateMathMLDimensions=fp,exports.calculateTextHeight=lS,exports.calculateTextWidth=cS,exports.cleanAndMerge=yS,exports.clear=Ip,exports.clear$1=XE,exports.clear$2=HA,exports.clear2=zE,exports.cloneArrayBuffer=Iw,exports.cloneBuffer=Ew,exports.cloneDeep=function e(t){if(null===t||"object"!=typeof t)return t;if(t instanceof Date)return new Date(t.getTime());if(t instanceof Array)return t.map(t=>e(t));if(t instanceof Object){const r={};for(const n in t)t.hasOwnProperty(n)&&(r[n]=e(t[n]));return r}return t},exports.cloneTypedArray=Bw,exports.color=Lg,exports.commonDb_exports=Tp,exports.common_default=yp,exports.commonjsGlobal=_n,exports.computeDimensionOfText=vT,exports.configureSvgSize=vp,exports.constant=dy,exports.constant$1=Yg,exports.copyArray=Lw,exports.copyObject=mk,exports.cos=gy,exports.createText=ST,exports.curveBasis=Oy,exports.darken=zu,exports.dayjs2=fu,exports.debounce=it,exports.decodeEntities=vS,exports.defaultCalendarControlStrings=yr,exports.defaultCalendarMonthStrings=ar,exports.defaultConfig2=Vp,exports.defaultConfig_default=kd,exports.defaultSelectWeekStrings=cr,exports.define=gg,exports.detectContentType=st,exports.epsilon=vy,exports.eq=dw,exports.evaluate=ip,exports.every=function(e,t){return e.every(t)},exports.extend=mg,exports.filter=function(e,t){return e.filter(t)},exports.formatTime=hi,exports.generateId=tS,exports.get=function(e,t,r){const n=Array.isArray(t)?t:t.split(".");let i=e;for(const o of n){if(null==i)return r;i=i[o]}return void 0===i?r:i},exports.getAccDescription=Np,exports.getAccTitle=Lp,exports.getAugmentedNamespace=function(e){if(e.__esModule)return e;var t=e.default;if("function"==typeof t){var r=function e(){return this instanceof e?Reflect.construct(t,arguments,this.constructor):t.apply(this,arguments)};r.prototype=t.prototype}else r={};return Object.defineProperty(r,"__esModule",{value:!0}),Object.keys(e).forEach(function(t){var n=Object.getOwnPropertyDescriptor(e,t);Object.defineProperty(r,t,n.get?n:{enumerable:!0,get:function(){return e[t]}})}),r},exports.getConfig=Dd,exports.getConfig2=$p,exports.getContentType=e=>st(e).type,exports.getDefaultExportFromCjs=Tn,exports.getDiagramTitle=Op,exports.getEdgeId=CS,exports.getIconSVG=sT,exports.getLineFunctionsWithOffset=CC,exports.getRegisteredLayoutAlgorithm=yM,exports.getStylesFromArray=Qk,exports.getSubGraphTitleMargins=wC,exports.getThemeVariables3=fd,exports.getUrl=np,exports.getUserDefinedConfig=Hd,exports.groupBy=function(e,t){return e.reduce((e,r)=>{const n=String(t(r));return e[n]||(e[n]=[]),e[n].push(r),e},{})},exports.halfPi=wy,exports.hasKatex=pp,exports.hue=function(e,t){var r=t-e;return r?Zg(e,r>180||r<-180?r-360*Math.round(r/360):r):Yg(isNaN(e)?t:e)},exports.identity=Tk,exports.initCloneObject=$w,exports.insertCluster=WA,exports.insertEdge=aM,exports.insertEdgeLabel=YE,exports.insertNode=RE,exports.interpolateNumber=tm,exports.interpolateRgb=em,exports.interpolateString=im,exports.isArguments=Uw,exports.isArray=Gw,exports.isArrayLike=Jw,exports.isBuffer=Qw,exports.isDark=Fu,exports.isEmpty=vI,exports.isEmpty$1=function(e){return null==e||("string"==typeof e||Array.isArray(e)?0===e.length:"object"==typeof e&&0===Object.keys(e).length)},exports.isIndex=xk,exports.isLabelStyle=TC,exports.isLength=Xw,exports.isObject=GC,exports.isObjectLike=zw,exports.isTypedArray=dk,exports.isValidShape=OE,exports.lighten=$u,exports.line=My,exports.lineBreakRegex=qd,exports.load=mC,exports.log=bu,exports.map=function(e,t){return e.map(t)},exports.markers_default=dM,exports.max=my,exports.memoize=bw,exports.min=yy,exports.nodeUtil=uk,exports.nogamma=Qg,exports.package_default=du,exports.parseFontSize=mS,exports.parseGenericTypes=sp,exports.pi=Cy,exports.positionEdgeLabel=KE,exports.positionNode=VE,exports.random=nS,exports.registerIconPacks=iT,exports.render=mM,exports.renderKatexSanitized=mp,exports.replaceIconSubstring=kT,exports.rgbConvert=Dg,exports.rgba=Du,exports.sanitizeText=Zd,exports.sanitizeUrl_1=BC,exports.select=fg,exports.selectSvgElement=vx,exports.set=function(e,t,r){const n=Array.isArray(t)?t:t.split("."),i=n.pop();if(!i)return e;let o=e;for(const a of n)a in o&&"object"==typeof o[a]||(o[a]={}),o=o[a];return o[i]=r,e},exports.setAccDescription=jp,exports.setAccTitle=Bp,exports.setConfig2=zp,exports.setDiagramTitle=Dp,exports.setNodeElem=$E,exports.setupGraphViewbox=Cp,exports.setupGraphViewbox2=Hp,exports.sin=xy,exports.some=function(e,t){return e.some(t)},exports.sqrt=by,exports.styles2String=AC,exports.tau=ky,exports.throttle=function(e,t=0){let r=null,n=0;return function(...i){const o=this,a=Date.now();n||(n=a);const s=t-(a-n);s<=0||s>t?(r&&(clearTimeout(r),r=null),n=a,e.apply(o,i)):r||(r=setTimeout(()=>{n=Date.now(),r=null,e.apply(o,i)},s))}},exports.timeKey=di,exports.uniq=function(e){return Array.from(new Set(e))},exports.uniqBy=function(e,t){const r=new Set;return e.filter(e=>{const n=t(e);return!r.has(n)&&(r.add(n),!0)})},exports.unknownIcon=tT,exports.updateNodeBounds=AA,exports.useApplicationContext=K,exports.useAspectRatioStyles=e=>{const{styles:t}=e,{getBaseStyles:r}=ne();return{aspectRatioStyles:q.useCallback((n,i)=>({...r(e,n,i),...t}),[r,e,t])}},exports.useCalendar=Kt,exports.useCalendarStyles=Ft,exports.useCenterStyles=gt,exports.useComponentUtils=ne,exports.useDataGridStyles=yi,exports.useDateUtils=(e,t,r)=>{const{getFormatRelative:n,formatDate:i}=rt(t,e);return{formatUtcDate:(e,t="PP")=>{const r=k.differenceInDays(new Date,k.parseISO(e));let o="";return void 0!==e&&(o=r>7?i(e,t):n(e)),o},formatTime:r=>r.toLocaleTimeString(e,{timeZone:t}),convertDateToUTC:r=>{const n="string"==typeof r?new Date(r):r,i=new Intl.DateTimeFormat(e,{timeZone:t,year:"numeric",month:"2-digit",day:"2-digit",hour:"2-digit",minute:"2-digit",second:"2-digit",hour12:!1}).formatToParts(n);let o,a,s,l,c,u;for(const e of i)switch(e.type){case"year":o=e.value;break;case"month":a=e.value;break;case"day":s=e.value;break;case"hour":l=e.value;break;case"minute":c=e.value;break;case"second":u=e.value}return new Date(`${o}-${a}-${s}T${l}:${c}:${u}Z`)}}},exports.useDayViewStyles=Qt,exports.useGraphAPI=()=>{const e=K(),t=null==e?void 0:e.graphClient,{warn:r,error:n}=Q();return{getUser:v.useCallback(async e=>{if(!t)return r("Graph client not available"),null;try{return await t.get(`/users/${e}`)}catch(i){return n("Error fetching user:",i instanceof Error?i:void 0),null}},[t]),getCurrentUser:v.useCallback(async()=>{if(!t)return r("Graph client not available"),null;try{return await t.get("/me")}catch(e){return n("Error fetching current user:",e instanceof Error?e:void 0),null}},[t]),searchUsers:v.useCallback(async(e,i=10)=>{if(!t)return r("Graph client not available"),[];try{return(await t.get(`/users?$search="displayName:${e}" OR "mail:${e}"&$top=${i}`)).value||[]}catch(o){return n("Error searching users:",o instanceof Error?o:void 0),[]}},[t]),getUserPhoto:v.useCallback(async e=>{if(!t)return r("Graph client not available"),null;try{const r=await t.get(`/users/${e}/photo/$value`);return URL.createObjectURL(r)}catch(i){return n("Error fetching user photo:",i instanceof Error?i:void 0),null}},[t]),graphClient:t}},exports.useGridStyles=ct,exports.useImageUtils=()=>{const{error:e}=Q(),t=v.useCallback(async e=>{const t=await fetch(e).then(e=>e.text());return"data:image/svg+xml;base64,"+btoa(t)},[]),r=v.useCallback(async(t,r,n)=>new Promise((i,o)=>{const a=new Image;a.crossOrigin="anonymous",a.addEventListener("load",()=>{var t;const s=document.createElement("canvas");let l;s.width=r??a.width,s.height=n??a.height,null==(t=null==s?void 0:s.getContext("2d"))||t.drawImage(a,0,0,r??a.width,n??a.height);try{l=s.toDataURL("image/png",1),i(l)}catch(c){nt&&e(`[ImageService.getBase64Image]: Err='${c.message}'`),o(c)}}),a.addEventListener("error",t=>{nt&&e(`[ImageService.getBase64Image]: Image load error='${t.message}'`),o(t)}),a.src=t}),[]),n=v.useCallback(e=>!S.isEmpty(e)&&e.indexOf("data:image/")>=0,[]);return{getBase64ImageFromDOMImg:v.useCallback(t=>{try{const e=document.getElementById(t),r=document.createElement("canvas");r.width=e.width,r.height=e.height;const n=r.getContext("2d");null==n||n.drawImage(e,0,0);return r.toDataURL("image/png")}catch(r){return void(nt&&e(`[getBase64ImageFromDOMImg]: Err='${r.message}'`))}},[]),isBase64Image:n,getImageBase64:r,base64FromSVGUrl:t}},exports.useIndexedDBCache=ee,exports.useLayoutStyles=ut,exports.useLogging=Q,exports.useMensionsStyles=tu,exports.useMermaidDiagramStyles=fL,exports.useNavigationStyles=()=>({root:T.css({width:"100%"}),sectionHeader:T.css({color:w.tokens.colorNeutralForeground3,fontSize:w.tokens.fontSizeBase200,fontWeight:w.tokens.fontWeightSemibold,padding:`${w.tokens.spacingVerticalS} ${w.tokens.spacingHorizontalM}`,textTransform:"uppercase",letterSpacing:"0.5px"})}),exports.useOptionTimeStyles=li,exports.usePolling=te,exports.useRenderHeaderStyles=wi,exports.useSelectTimeStyles=si,exports.useShowErrorStyles=ki,exports.useShowMessageStyles=Si,exports.useSpaceStyles=dt,exports.useSplitPaneStyles=yt,exports.useStackStyles=pt,exports.useStyles=()=>({inputContainer:T.css({marginTop:"auto",marginLeft:"auto","::after":{content:'""',position:"absolute",bottom:0,left:0,right:0,borderBottom:"2px solid transparent",pointerEvents:"none",borderRadius:w.tokens.borderRadiusMedium}}),listContainer:T.css({maxHeight:"400px",overflowY:"auto",overflowX:"hidden","::-webkit-scrollbar":{width:"5px",height:"5px"},"::-webkit-scrollbar-track":{background:w.tokens.colorNeutralBackground4,borderRadius:"10px"},"::-webkit-scrollbar-thumb":{background:w.tokens.colorBrandStroke2Hover,borderRadius:"10px"},"::-webkit-scrollbar-thumb:hover":{background:w.tokens.colorNeutralStroke2}}),sugestionsHeader:T.css({color:w.tokens.colorBrandBackground})}),exports.useTimeZoneHelper=()=>{const e=K(),t=v.useMemo(()=>Intl.DateTimeFormat().resolvedOptions().timeZone,[]);return{timeZone:t,convertToUserTimeZone:(e,r)=>{const n=r||t;return C.toZonedTime(e,n)},convertFromUserTimeZone:(e,r)=>{const n=r||t;return C.fromZonedTime(e,n)},formatInTimeZone:(e,r,n)=>{const i=n||t;return C.format(C.toZonedTime(e,i),r,{timeZone:i})},getUserTimeZone:()=>{var r,n;return null==(n=null==(r=null==e?void 0:e.pageContext)?void 0:r.user)||n.preferUserTimeZone,t}}},exports.useUtils=Lt,exports.useVideoStyles=Mi,exports.useWeekViewStyles=zt,exports.utils_default=xS,exports.withPath=Sy,exports.wrapLabel=aS;
|
|
428
|
+
//# sourceMappingURL=index-DkoeCnje.cjs.map
|