@esri/calcite-components 1.0.0-beta.72 → 1.0.0-beta.76
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/calcite/assets/calcite-date-picker/nls/bg.json +31 -0
- package/dist/calcite/assets/calcite-date-picker/nls/pt-BR.json +31 -0
- package/dist/calcite/assets/calcite-date-picker/nls/pt-PT.json +3 -3
- package/dist/calcite/assets/calcite-icon/clipboard16.json +1 -0
- package/dist/calcite/assets/calcite-icon/clipboard24.json +1 -0
- package/dist/calcite/assets/calcite-icon/clipboard32.json +1 -0
- package/dist/calcite/assets/calcite-icon/explore16.json +1 -0
- package/dist/calcite/assets/calcite-icon/explore24.json +1 -0
- package/dist/calcite/assets/calcite-icon/explore32.json +1 -0
- package/dist/calcite/assets/calcite-icon/folders16.json +1 -0
- package/dist/calcite/assets/calcite-icon/folders24.json +1 -0
- package/dist/calcite/assets/calcite-icon/folders32.json +1 -0
- package/dist/calcite/assets/calcite-icon/initiative16.json +1 -0
- package/dist/calcite/assets/calcite-icon/initiative24.json +1 -0
- package/dist/calcite/assets/calcite-icon/initiative32.json +1 -0
- package/dist/calcite/assets/calcite-icon/initiativeTemplate16.json +1 -0
- package/dist/calcite/assets/calcite-icon/initiativeTemplate24.json +1 -0
- package/dist/calcite/assets/calcite-icon/initiativeTemplate32.json +1 -0
- package/dist/calcite/assets/calcite-icon/multipleVariables16.json +1 -0
- package/dist/calcite/assets/calcite-icon/multipleVariables24.json +1 -0
- package/dist/calcite/assets/calcite-icon/multipleVariables32.json +1 -0
- package/dist/calcite/assets/calcite-icon/paletteCheck16.json +1 -0
- package/dist/calcite/assets/calcite-icon/paletteCheck24.json +1 -0
- package/dist/calcite/assets/calcite-icon/paletteCheck32.json +1 -0
- package/dist/calcite/assets/calcite-icon/partlyCloudy16.json +1 -0
- package/dist/calcite/assets/calcite-icon/partlyCloudy24.json +1 -0
- package/dist/calcite/assets/calcite-icon/partlyCloudy32.json +1 -0
- package/dist/calcite/assets/calcite-icon/pentagon16.json +1 -0
- package/dist/calcite/assets/calcite-icon/pentagon24.json +1 -0
- package/dist/calcite/assets/calcite-icon/pentagon32.json +1 -0
- package/dist/calcite/assets/calcite-icon/puzzlePiece16.json +1 -0
- package/dist/calcite/assets/calcite-icon/puzzlePiece24.json +1 -0
- package/dist/calcite/assets/calcite-icon/puzzlePiece32.json +1 -0
- package/dist/calcite/assets/calcite-icon/ribbonRosette16.json +1 -0
- package/dist/calcite/assets/calcite-icon/ribbonRosette24.json +1 -0
- package/dist/calcite/assets/calcite-icon/ribbonRosette32.json +1 -0
- package/dist/calcite/assets/calcite-icon/rightAlign16.json +1 -0
- package/dist/calcite/assets/calcite-icon/rightAlign24.json +1 -0
- package/dist/calcite/assets/calcite-icon/rightAlign32.json +1 -0
- package/dist/calcite/assets/calcite-icon/screenshotMode16.json +1 -0
- package/dist/calcite/assets/calcite-icon/screenshotMode24.json +1 -0
- package/dist/calcite/assets/calcite-icon/screenshotMode32.json +1 -0
- package/dist/calcite/assets/calcite-icon/speechBubbleExclamation16.json +1 -0
- package/dist/calcite/assets/calcite-icon/speechBubbleExclamation24.json +1 -0
- package/dist/calcite/assets/calcite-icon/speechBubbleExclamation32.json +1 -0
- package/dist/calcite/assets/calcite-icon/survey16.json +1 -0
- package/dist/calcite/assets/calcite-icon/survey24.json +1 -0
- package/dist/calcite/assets/calcite-icon/survey32.json +1 -0
- package/dist/calcite/calcite.css +1 -1
- package/dist/calcite/calcite.esm.js +1 -1
- package/dist/calcite/calcite.js +1 -1
- package/dist/calcite/p-010b6b91.system.entry.js +5 -0
- package/dist/calcite/p-015d6a24.entry.js +5 -0
- package/dist/calcite/p-0459ae3e.system.entry.js +5 -0
- package/dist/calcite/p-07603601.system.entry.js +5 -0
- package/dist/calcite/p-0926320c.system.entry.js +5 -0
- package/dist/calcite/{p-444ecda9.entry.js → p-09bd0204.entry.js} +1 -1
- package/dist/calcite/p-0a5d059d.js +5 -0
- package/dist/calcite/p-0c20a4e3.entry.js +5 -0
- package/dist/calcite/p-0d61e540.system.entry.js +5 -0
- package/dist/calcite/{p-0f2b51bf.system.js → p-10e3f599.system.js} +1 -1
- package/dist/calcite/p-1199ec78.entry.js +5 -0
- package/dist/calcite/p-13f9119c.js +5 -0
- package/dist/calcite/p-150e45ec.entry.js +5 -0
- package/dist/calcite/{p-a4a12ffb.system.entry.js → p-15eebdf8.system.entry.js} +2 -2
- package/dist/calcite/p-16a27151.entry.js +5 -0
- package/dist/calcite/p-18259377.entry.js +5 -0
- package/dist/calcite/p-1a3a366d.system.js +5 -0
- package/dist/calcite/p-1a907c90.entry.js +5 -0
- package/dist/calcite/p-1ce851da.js +5 -0
- package/dist/calcite/p-21e8e1e9.system.entry.js +5 -0
- package/dist/calcite/{p-66fda99e.entry.js → p-2328c2ec.entry.js} +1 -1
- package/dist/calcite/p-24765b5e.entry.js +5 -0
- package/dist/calcite/{p-a2a22cbc.entry.js → p-2718a51a.entry.js} +1 -1
- package/dist/calcite/{p-04cc8259.entry.js → p-2be7746c.entry.js} +1 -1
- package/dist/calcite/p-2d88c0ba.entry.js +5 -0
- package/dist/calcite/p-353015b6.system.entry.js +5 -0
- package/dist/calcite/p-385f6cb9.entry.js +5 -0
- package/dist/calcite/p-3c34f20d.system.js +5 -0
- package/dist/calcite/{p-d8039e8a.system.entry.js → p-3e59c8ef.system.entry.js} +1 -1
- package/dist/calcite/p-3f6a6851.system.entry.js +5 -0
- package/dist/calcite/p-3f792e3d.system.entry.js +5 -0
- package/dist/calcite/p-408408d6.entry.js +5 -0
- package/dist/calcite/p-42ac867a.entry.js +5 -0
- package/dist/calcite/p-4340f6ed.entry.js +5 -0
- package/dist/calcite/{p-523bc291.system.js → p-48fae9a9.system.js} +1 -1
- package/dist/calcite/{p-f1f65708.entry.js → p-4b7ff039.entry.js} +1 -1
- package/dist/calcite/{p-fc9025a2.entry.js → p-4edc43c1.entry.js} +1 -1
- package/dist/calcite/p-4fc8341b.system.entry.js +5 -0
- package/dist/calcite/p-510ef2b7.system.entry.js +5 -0
- package/dist/calcite/{p-8c4b6059.system.entry.js → p-5248d5fb.system.entry.js} +1 -1
- package/dist/calcite/p-54c3ea44.system.entry.js +5 -0
- package/dist/calcite/p-55c884ba.entry.js +5 -0
- package/dist/calcite/p-5660811e.entry.js +5 -0
- package/dist/calcite/p-5833a3af.entry.js +5 -0
- package/dist/calcite/p-59c6c9a0.entry.js +5 -0
- package/dist/calcite/p-5cd2ff4e.system.entry.js +5 -0
- package/dist/calcite/p-5f129d47.entry.js +5 -0
- package/dist/calcite/{p-e0b1e90c.entry.js → p-635594b8.entry.js} +1 -1
- package/dist/calcite/p-65ba6a8f.entry.js +5 -0
- package/dist/calcite/p-672ec03a.entry.js +5 -0
- package/dist/calcite/p-67cd9e12.system.entry.js +5 -0
- package/dist/calcite/p-6a5a4922.system.entry.js +5 -0
- package/dist/calcite/p-6a797e80.entry.js +5 -0
- package/dist/calcite/p-6b529df3.system.entry.js +5 -0
- package/dist/calcite/p-6c4eb127.system.entry.js +5 -0
- package/dist/calcite/p-6d5c2fce.system.entry.js +5 -0
- package/dist/calcite/{p-27d9be53.entry.js → p-6ee036b3.entry.js} +1 -1
- package/dist/calcite/p-71b6bc4c.system.entry.js +5 -0
- package/dist/calcite/p-7266c359.system.entry.js +5 -0
- package/dist/calcite/p-72951ce3.system.entry.js +5 -0
- package/dist/calcite/p-75cda5de.system.entry.js +5 -0
- package/dist/calcite/p-75df0e8f.entry.js +5 -0
- package/dist/calcite/p-79ba0ff5.js +5 -0
- package/dist/calcite/p-7b2f2117.system.entry.js +5 -0
- package/dist/calcite/{p-bca0b34f.entry.js → p-7b341154.entry.js} +1 -1
- package/dist/calcite/p-7e9189e8.system.entry.js +5 -0
- package/dist/calcite/p-80e56ba6.system.entry.js +5 -0
- package/dist/calcite/p-8124f6cc.system.entry.js +5 -0
- package/dist/calcite/p-81dc55fa.entry.js +5 -0
- package/dist/calcite/p-82e0b30e.entry.js +5 -0
- package/dist/calcite/p-8446d974.system.entry.js +5 -0
- package/dist/calcite/p-852a718f.entry.js +5 -0
- package/dist/calcite/p-8647d09e.entry.js +5 -0
- package/dist/calcite/p-888ce316.system.entry.js +5 -0
- package/dist/calcite/p-8bfa00bc.js +5 -0
- package/dist/calcite/p-8d1564c5.system.entry.js +5 -0
- package/dist/calcite/{p-fd255a24.entry.js → p-8d437ca2.entry.js} +1 -1
- package/dist/calcite/p-8f3a3e4e.js +5 -0
- package/dist/calcite/p-8f6aac19.entry.js +5 -0
- package/dist/calcite/p-903c016f.entry.js +5 -0
- package/dist/calcite/p-9217d4ef.system.js +5 -0
- package/dist/calcite/p-92901db9.entry.js +5 -0
- package/dist/calcite/{p-34e5baa7.system.js → p-94cfc34a.system.js} +1 -1
- package/dist/calcite/p-95810140.system.js +5 -0
- package/dist/calcite/p-95a3bcff.system.entry.js +5 -0
- package/dist/calcite/p-95b7c39a.system.entry.js +5 -0
- package/dist/calcite/p-983287ce.system.js +5 -0
- package/dist/calcite/p-9a7c4812.js +5 -0
- package/dist/calcite/p-9ef989e2.entry.js +5 -0
- package/dist/calcite/p-9f1c59ec.entry.js +5 -0
- package/dist/calcite/p-a37ecb59.entry.js +5 -0
- package/dist/calcite/p-a468d651.system.entry.js +5 -0
- package/dist/calcite/p-a77a8427.entry.js +5 -0
- package/dist/calcite/p-a7dfed2f.entry.js +5 -0
- package/dist/calcite/p-a809abbd.system.entry.js +5 -0
- package/dist/calcite/p-a859ccd4.system.js +5 -0
- package/dist/calcite/p-abf93e8f.system.js +5 -0
- package/dist/calcite/{p-db10485b.system.js → p-ac4aec20.system.js} +1 -1
- package/dist/calcite/p-ac8c0493.entry.js +5 -0
- package/dist/calcite/p-ad2fd769.system.entry.js +5 -0
- package/dist/calcite/p-af5e11c9.system.entry.js +5 -0
- package/dist/calcite/p-af75a72b.js +5 -0
- package/dist/calcite/p-b0ab09d3.system.entry.js +5 -0
- package/dist/calcite/p-b4a80f18.system.entry.js +5 -0
- package/dist/calcite/p-b519a98e.system.entry.js +5 -0
- package/dist/calcite/p-b5781bda.entry.js +5 -0
- package/dist/calcite/p-b8a670cc.entry.js +5 -0
- package/dist/calcite/p-ba6b0f09.entry.js +5 -0
- package/dist/calcite/p-bb401f25.system.js +5 -0
- package/dist/calcite/p-bd289892.entry.js +5 -0
- package/dist/calcite/p-c36161b9.system.entry.js +5 -0
- package/dist/calcite/p-c525d974.system.entry.js +5 -0
- package/dist/calcite/{p-d3db2b58.system.entry.js → p-c5e8d437.system.entry.js} +1 -1
- package/dist/calcite/p-cb02295b.system.entry.js +5 -0
- package/dist/calcite/p-d2931c8e.system.entry.js +5 -0
- package/dist/calcite/p-d2ebedc0.entry.js +5 -0
- package/dist/calcite/p-d3316626.system.entry.js +5 -0
- package/dist/calcite/p-da987587.system.entry.js +5 -0
- package/dist/calcite/p-dadb1104.system.entry.js +5 -0
- package/dist/calcite/p-dae2daf0.entry.js +5 -0
- package/dist/calcite/{p-f39dc5fd.entry.js → p-dc24f809.entry.js} +1 -1
- package/dist/calcite/p-dd9f2e61.js +5 -0
- package/dist/calcite/p-de10a37b.entry.js +5 -0
- package/dist/calcite/p-e2047621.system.js +5 -0
- package/dist/calcite/{p-06ddf228.entry.js → p-e54a3620.entry.js} +1 -1
- package/dist/calcite/p-e93a418e.system.entry.js +5 -0
- package/dist/calcite/p-ea2b09ba.entry.js +5 -0
- package/dist/calcite/{p-40e16f41.entry.js → p-ebd8eef3.entry.js} +1 -1
- package/dist/calcite/p-ec2d6c5f.system.entry.js +5 -0
- package/dist/calcite/p-ec9bab33.system.js +5 -0
- package/dist/calcite/p-eeb91710.js +5 -0
- package/dist/calcite/p-ef6b4184.js +5 -0
- package/dist/calcite/{p-87327c2f.system.entry.js → p-ef779e80.system.entry.js} +1 -1
- package/dist/calcite/p-f2508455.system.entry.js +5 -0
- package/dist/calcite/p-f45eae85.entry.js +5 -0
- package/dist/calcite/{p-2e29554c.js → p-fb3f5251.js} +1 -1
- package/dist/calcite/p-fbf74b6d.js +5 -0
- package/dist/calcite/p-fc04e52b.system.entry.js +5 -0
- package/dist/calcite/p-fc2f135e.system.entry.js +5 -0
- package/dist/calcite/p-fe28891b.system.entry.js +5 -0
- package/dist/calcite/p-feacdfdf.system.entry.js +5 -0
- package/dist/cjs/{CalciteExpandToggle-d654421a.js → CalciteExpandToggle-f1e05027.js} +2 -2
- package/dist/cjs/{CalciteHeading-112c19f9.js → CalciteHeading-d797719f.js} +1 -1
- package/dist/cjs/calcite-accordion_2.cjs.entry.js +8 -5
- package/dist/cjs/calcite-action-bar.cjs.entry.js +8 -29
- package/dist/cjs/calcite-action-group.cjs.entry.js +16 -3
- package/dist/cjs/calcite-action-menu.cjs.entry.js +8 -8
- package/dist/cjs/calcite-action-pad.cjs.entry.js +12 -4
- package/dist/cjs/calcite-action.cjs.entry.js +3 -3
- package/dist/cjs/calcite-alert.cjs.entry.js +29 -22
- package/dist/cjs/calcite-avatar.cjs.entry.js +3 -3
- package/dist/cjs/calcite-block_2.cjs.entry.js +19 -6
- package/dist/cjs/calcite-button.cjs.entry.js +5 -5
- package/dist/cjs/calcite-card.cjs.entry.js +19 -8
- package/dist/cjs/calcite-checkbox.cjs.entry.js +6 -6
- package/dist/cjs/calcite-chip.cjs.entry.js +17 -4
- package/dist/cjs/calcite-color-picker_3.cjs.entry.js +21 -6
- package/dist/cjs/calcite-combobox_3.cjs.entry.js +39 -25
- package/dist/cjs/calcite-date-picker_4.cjs.entry.js +19 -17
- package/dist/cjs/calcite-dropdown_3.cjs.entry.js +32 -26
- package/dist/cjs/calcite-fab.cjs.entry.js +3 -3
- package/dist/cjs/calcite-filter.cjs.entry.js +3 -3
- package/dist/cjs/calcite-flow.cjs.entry.js +3 -3
- package/dist/cjs/calcite-graph_2.cjs.entry.js +28 -17
- package/dist/cjs/calcite-handle.cjs.entry.js +2 -2
- package/dist/cjs/calcite-icon.cjs.entry.js +4 -4
- package/dist/cjs/calcite-inline-editable.cjs.entry.js +47 -22
- package/dist/cjs/calcite-input-date-picker.cjs.entry.js +15 -10
- package/dist/cjs/calcite-input-message.cjs.entry.js +3 -3
- package/dist/cjs/calcite-input-time-picker_2.cjs.entry.js +11 -11
- package/dist/cjs/calcite-input.cjs.entry.js +135 -63
- package/dist/cjs/calcite-label.cjs.entry.js +6 -3
- package/dist/cjs/calcite-link.cjs.entry.js +16 -5
- package/dist/cjs/calcite-list_3.cjs.entry.js +19 -6
- package/dist/cjs/calcite-loader.cjs.entry.js +2 -2
- package/dist/cjs/calcite-modal.cjs.entry.js +10 -7
- package/dist/cjs/calcite-notice.cjs.entry.js +15 -9
- package/dist/cjs/calcite-option_3.cjs.entry.js +8 -8
- package/dist/cjs/calcite-pagination.cjs.entry.js +2 -2
- package/dist/cjs/calcite-panel.cjs.entry.js +39 -17
- package/dist/cjs/calcite-pick-list_3.cjs.entry.js +32 -8
- package/dist/cjs/calcite-popover_2.cjs.entry.js +8 -8
- package/dist/cjs/calcite-progress.cjs.entry.js +2 -2
- package/dist/cjs/calcite-radio-button-group.cjs.entry.js +15 -2
- package/dist/cjs/calcite-radio-button.cjs.entry.js +21 -14
- package/dist/cjs/calcite-radio-group_2.cjs.entry.js +6 -51
- package/dist/cjs/calcite-rating.cjs.entry.js +5 -5
- package/dist/cjs/calcite-scrim.cjs.entry.js +2 -2
- package/dist/cjs/calcite-shell_3.cjs.entry.js +47 -16
- package/dist/cjs/calcite-sortable-list.cjs.entry.js +3 -3
- package/dist/cjs/calcite-split-button.cjs.entry.js +2 -2
- package/dist/cjs/calcite-stepper_2.cjs.entry.js +4 -4
- package/dist/cjs/calcite-switch.cjs.entry.js +5 -5
- package/dist/cjs/calcite-tab_4.cjs.entry.js +7 -7
- package/dist/cjs/calcite-tile-select_2.cjs.entry.js +39 -4
- package/dist/cjs/calcite-tile.cjs.entry.js +16 -3
- package/dist/cjs/calcite-tip_3.cjs.entry.js +20 -8
- package/dist/cjs/calcite-tooltip_2.cjs.entry.js +9 -9
- package/dist/cjs/calcite-tree_2.cjs.entry.js +26 -13
- package/dist/cjs/calcite-value-list_2.cjs.entry.js +27 -8
- package/dist/cjs/calcite.cjs.js +3 -3
- package/dist/cjs/conditionalSlot-20745612.js +43 -0
- package/dist/cjs/{dom-19822169.js → dom-f3df220d.js} +44 -11
- package/dist/cjs/{form-a5b44a1f.js → form-55a71663.js} +2 -2
- package/dist/cjs/{index-6b5d2de5.js → index-8b0d388b.js} +0 -5
- package/dist/cjs/{label-8e3552b2.js → label-6b18ca08.js} +5 -2
- package/dist/cjs/loader.cjs.js +3 -3
- package/dist/cjs/locale-02462821.js +128 -0
- package/dist/cjs/number-e813e801.js +84 -0
- package/dist/cjs/{observers-41837607.js → observers-79bfb8bc.js} +5 -1
- package/dist/cjs/{popper-a7580aca.js → popper-13a2bb46.js} +29 -10
- package/dist/cjs/{resources-16974e48.js → resources-6af71952.js} +9 -5
- package/dist/cjs/{resources-6c4b32ef.js → resources-f6847c67.js} +14 -3
- package/dist/collection/collection-manifest.json +4 -4
- package/dist/collection/components/accordion/interfaces.js +1 -0
- package/dist/collection/components/alert/interfaces.js +7 -0
- package/dist/collection/components/block-section/interfaces.js +1 -0
- package/dist/collection/components/button/interfaces.js +1 -0
- package/dist/collection/components/calcite-accordion/calcite-accordion.css +8 -18
- package/dist/collection/components/calcite-accordion/calcite-accordion.js +6 -2
- package/dist/collection/components/calcite-accordion-item/calcite-accordion-item.css +33 -77
- package/dist/collection/components/calcite-accordion-item/calcite-accordion-item.js +1 -1
- package/dist/collection/components/calcite-action/calcite-action.css +49 -91
- package/dist/collection/components/calcite-action-bar/calcite-action-bar.css +7 -18
- package/dist/collection/components/calcite-action-group/calcite-action-group.css +5 -18
- package/dist/collection/components/calcite-action-group/calcite-action-group.js +12 -0
- package/dist/collection/components/calcite-action-menu/calcite-action-menu.css +11 -23
- package/dist/collection/components/calcite-action-menu/calcite-action-menu.js +4 -4
- package/dist/collection/components/calcite-action-pad/calcite-action-pad.css +26 -25
- package/dist/collection/components/calcite-action-pad/calcite-action-pad.js +7 -0
- package/dist/collection/components/calcite-alert/calcite-alert.css +81 -106
- package/dist/collection/components/calcite-alert/calcite-alert.js +54 -21
- package/dist/collection/components/calcite-avatar/calcite-avatar.css +8 -20
- package/dist/collection/components/calcite-block/calcite-block.css +44 -53
- package/dist/collection/components/calcite-block/calcite-block.js +13 -1
- package/dist/collection/components/calcite-block-section/calcite-block-section.css +25 -41
- package/dist/collection/components/calcite-button/calcite-button.css +83 -226
- package/dist/collection/components/calcite-card/calcite-card.css +49 -60
- package/dist/collection/components/calcite-card/calcite-card.js +15 -6
- package/dist/collection/components/calcite-checkbox/calcite-checkbox.css +11 -24
- package/dist/collection/components/calcite-checkbox/calcite-checkbox.js +1 -1
- package/dist/collection/components/calcite-chip/calcite-chip.css +19 -41
- package/dist/collection/components/calcite-chip/calcite-chip.js +13 -1
- package/dist/collection/components/calcite-color-picker/calcite-color-picker.css +11 -40
- package/dist/collection/components/calcite-color-picker-hex-input/calcite-color-picker-hex-input.css +7 -17
- package/dist/collection/components/calcite-color-picker-swatch/calcite-color-picker-swatch.css +7 -18
- package/dist/collection/components/calcite-color-picker-swatch/resources.js +1 -1
- package/dist/collection/components/calcite-combobox/calcite-combobox.css +29 -48
- package/dist/collection/components/calcite-combobox/calcite-combobox.js +46 -16
- package/dist/collection/components/calcite-combobox/resources.js +3 -0
- package/dist/collection/components/calcite-combobox-item/calcite-combobox-item.css +34 -41
- package/dist/collection/components/calcite-combobox-item/calcite-combobox-item.js +10 -8
- package/dist/collection/components/calcite-combobox-item-group/calcite-combobox-item-group.css +8 -19
- package/dist/collection/components/calcite-combobox-item-group/calcite-combobox-item-group.js +1 -1
- package/dist/collection/components/calcite-date-picker/assets/calcite-date-picker/nls/bg.json +31 -0
- package/dist/collection/components/calcite-date-picker/assets/calcite-date-picker/nls/pt-BR.json +31 -0
- package/dist/collection/components/calcite-date-picker/assets/calcite-date-picker/nls/pt-PT.json +3 -3
- package/dist/collection/components/calcite-date-picker/calcite-date-picker.css +4 -14
- package/dist/collection/components/calcite-date-picker/calcite-date-picker.js +9 -7
- package/dist/collection/components/calcite-date-picker/utils.js +7 -3
- package/dist/collection/components/calcite-date-picker-day/calcite-date-picker-day.css +37 -58
- package/dist/collection/components/calcite-date-picker-month/calcite-date-picker-month.css +21 -31
- package/dist/collection/components/calcite-date-picker-month-header/calcite-date-picker-month-header.css +35 -56
- package/dist/collection/components/calcite-dropdown/calcite-dropdown.css +5 -21
- package/dist/collection/components/calcite-dropdown/calcite-dropdown.js +28 -21
- package/dist/collection/components/calcite-dropdown-group/calcite-dropdown-group.css +10 -20
- package/dist/collection/components/calcite-dropdown-item/calcite-dropdown-item.css +48 -59
- package/dist/collection/components/calcite-fab/calcite-fab.css +10 -16
- package/dist/collection/components/calcite-filter/calcite-filter.css +20 -34
- package/dist/collection/components/calcite-flow/calcite-flow.css +22 -34
- package/dist/collection/components/calcite-flow/calcite-flow.js +1 -1
- package/dist/collection/components/calcite-graph/calcite-graph.css +5 -18
- package/dist/collection/components/calcite-graph/calcite-graph.js +13 -42
- package/dist/collection/components/calcite-handle/calcite-handle.css +4 -18
- package/dist/collection/components/calcite-icon/assets/calcite-icon/clipboard16.json +1 -0
- package/dist/collection/components/calcite-icon/assets/calcite-icon/clipboard24.json +1 -0
- package/dist/collection/components/calcite-icon/assets/calcite-icon/clipboard32.json +1 -0
- package/dist/collection/components/calcite-icon/assets/calcite-icon/explore16.json +1 -0
- package/dist/collection/components/calcite-icon/assets/calcite-icon/explore24.json +1 -0
- package/dist/collection/components/calcite-icon/assets/calcite-icon/explore32.json +1 -0
- package/dist/collection/components/calcite-icon/assets/calcite-icon/folders16.json +1 -0
- package/dist/collection/components/calcite-icon/assets/calcite-icon/folders24.json +1 -0
- package/dist/collection/components/calcite-icon/assets/calcite-icon/folders32.json +1 -0
- package/dist/collection/components/calcite-icon/assets/calcite-icon/initiative16.json +1 -0
- package/dist/collection/components/calcite-icon/assets/calcite-icon/initiative24.json +1 -0
- package/dist/collection/components/calcite-icon/assets/calcite-icon/initiative32.json +1 -0
- package/dist/collection/components/calcite-icon/assets/calcite-icon/initiativeTemplate16.json +1 -0
- package/dist/collection/components/calcite-icon/assets/calcite-icon/initiativeTemplate24.json +1 -0
- package/dist/collection/components/calcite-icon/assets/calcite-icon/initiativeTemplate32.json +1 -0
- package/dist/collection/components/calcite-icon/assets/calcite-icon/multipleVariables16.json +1 -0
- package/dist/collection/components/calcite-icon/assets/calcite-icon/multipleVariables24.json +1 -0
- package/dist/collection/components/calcite-icon/assets/calcite-icon/multipleVariables32.json +1 -0
- package/dist/collection/components/calcite-icon/assets/calcite-icon/paletteCheck16.json +1 -0
- package/dist/collection/components/calcite-icon/assets/calcite-icon/paletteCheck24.json +1 -0
- package/dist/collection/components/calcite-icon/assets/calcite-icon/paletteCheck32.json +1 -0
- package/dist/collection/components/calcite-icon/assets/calcite-icon/partlyCloudy16.json +1 -0
- package/dist/collection/components/calcite-icon/assets/calcite-icon/partlyCloudy24.json +1 -0
- package/dist/collection/components/calcite-icon/assets/calcite-icon/partlyCloudy32.json +1 -0
- package/dist/collection/components/calcite-icon/assets/calcite-icon/pentagon16.json +1 -0
- package/dist/collection/components/calcite-icon/assets/calcite-icon/pentagon24.json +1 -0
- package/dist/collection/components/calcite-icon/assets/calcite-icon/pentagon32.json +1 -0
- package/dist/collection/components/calcite-icon/assets/calcite-icon/puzzlePiece16.json +1 -0
- package/dist/collection/components/calcite-icon/assets/calcite-icon/puzzlePiece24.json +1 -0
- package/dist/collection/components/calcite-icon/assets/calcite-icon/puzzlePiece32.json +1 -0
- package/dist/collection/components/calcite-icon/assets/calcite-icon/ribbonRosette16.json +1 -0
- package/dist/collection/components/calcite-icon/assets/calcite-icon/ribbonRosette24.json +1 -0
- package/dist/collection/components/calcite-icon/assets/calcite-icon/ribbonRosette32.json +1 -0
- package/dist/collection/components/calcite-icon/assets/calcite-icon/rightAlign16.json +1 -0
- package/dist/collection/components/calcite-icon/assets/calcite-icon/rightAlign24.json +1 -0
- package/dist/collection/components/calcite-icon/assets/calcite-icon/rightAlign32.json +1 -0
- package/dist/collection/components/calcite-icon/assets/calcite-icon/screenshotMode16.json +1 -0
- package/dist/collection/components/calcite-icon/assets/calcite-icon/screenshotMode24.json +1 -0
- package/dist/collection/components/calcite-icon/assets/calcite-icon/screenshotMode32.json +1 -0
- package/dist/collection/components/calcite-icon/assets/calcite-icon/speechBubbleExclamation16.json +1 -0
- package/dist/collection/components/calcite-icon/assets/calcite-icon/speechBubbleExclamation24.json +1 -0
- package/dist/collection/components/calcite-icon/assets/calcite-icon/speechBubbleExclamation32.json +1 -0
- package/dist/collection/components/calcite-icon/assets/calcite-icon/survey16.json +1 -0
- package/dist/collection/components/calcite-icon/assets/calcite-icon/survey24.json +1 -0
- package/dist/collection/components/calcite-icon/assets/calcite-icon/survey32.json +1 -0
- package/dist/collection/components/calcite-icon/calcite-icon.css +12 -14
- package/dist/collection/components/calcite-inline-editable/calcite-inline-editable.css +5 -12
- package/dist/collection/components/calcite-inline-editable/calcite-inline-editable.js +54 -35
- package/dist/collection/components/calcite-input/calcite-input.css +94 -156
- package/dist/collection/components/calcite-input/calcite-input.js +129 -57
- package/dist/collection/components/calcite-input-date-picker/calcite-input-date-picker.css +28 -46
- package/dist/collection/components/calcite-input-date-picker/calcite-input-date-picker.js +39 -2
- package/dist/collection/components/calcite-input-message/calcite-input-message.css +12 -23
- package/dist/collection/components/calcite-input-time-picker/calcite-input-time-picker.css +1 -11
- package/dist/collection/components/calcite-input-time-picker/calcite-input-time-picker.js +2 -2
- package/dist/collection/components/calcite-label/calcite-label.css +19 -34
- package/dist/collection/components/calcite-label/calcite-label.js +8 -2
- package/dist/collection/components/calcite-link/calcite-link.css +16 -33
- package/dist/collection/components/calcite-link/calcite-link.js +31 -2
- package/dist/collection/components/calcite-list/calcite-list.css +9 -16
- package/dist/collection/components/calcite-list-item/calcite-list-item.css +23 -46
- package/dist/collection/components/calcite-list-item/calcite-list-item.js +12 -0
- package/dist/collection/components/calcite-list-item-group/calcite-list-item-group.css +7 -17
- package/dist/collection/components/calcite-loader/calcite-loader.css +37 -62
- package/dist/collection/components/calcite-modal/calcite-modal.css +95 -102
- package/dist/collection/components/calcite-modal/calcite-modal.js +6 -3
- package/dist/collection/components/calcite-notice/calcite-notice.css +43 -80
- package/dist/collection/components/calcite-notice/calcite-notice.js +11 -6
- package/dist/collection/components/calcite-option/calcite-option.css +1 -11
- package/dist/collection/components/calcite-option-group/calcite-option-group.css +1 -11
- package/dist/collection/components/calcite-pagination/calcite-pagination.css +20 -54
- package/dist/collection/components/calcite-panel/calcite-panel.css +51 -73
- package/dist/collection/components/calcite-panel/calcite-panel.js +60 -19
- package/dist/collection/components/calcite-pick-list/calcite-pick-list.css +16 -26
- package/dist/collection/components/calcite-pick-list/calcite-pick-list.js +13 -5
- package/dist/collection/components/calcite-pick-list/resources.js +1 -1
- package/dist/collection/components/calcite-pick-list/shared-list-logic.js +10 -0
- package/dist/collection/components/calcite-pick-list-group/calcite-pick-list-group.css +14 -27
- package/dist/collection/components/calcite-pick-list-group/calcite-pick-list-group.js +12 -0
- package/dist/collection/components/calcite-pick-list-item/calcite-pick-list-item.css +43 -60
- package/dist/collection/components/calcite-pick-list-item/calcite-pick-list-item.js +13 -1
- package/dist/collection/components/calcite-popover/calcite-popover.css +24 -34
- package/dist/collection/components/calcite-popover/calcite-popover.js +1 -1
- package/dist/collection/components/calcite-popover-manager/calcite-popover-manager.css +1 -11
- package/dist/collection/components/calcite-popover-manager/calcite-popover-manager.js +1 -1
- package/dist/collection/components/calcite-progress/calcite-progress.css +7 -20
- package/dist/collection/components/calcite-radio-button/calcite-radio-button.css +18 -21
- package/dist/collection/components/calcite-radio-button/calcite-radio-button.js +16 -9
- package/dist/collection/components/calcite-radio-button-group/calcite-radio-button-group.css +1 -14
- package/dist/collection/components/calcite-radio-button-group/calcite-radio-button-group.js +13 -0
- package/dist/collection/components/calcite-radio-group/calcite-radio-group.css +3 -15
- package/dist/collection/components/calcite-radio-group/calcite-radio-group.js +3 -5
- package/dist/collection/components/calcite-radio-group-item/calcite-radio-group-item.css +17 -28
- package/dist/collection/components/calcite-radio-group-item/calcite-radio-group-item.js +0 -45
- package/dist/collection/components/calcite-rating/calcite-rating.css +10 -23
- package/dist/collection/components/calcite-scrim/calcite-scrim.css +17 -29
- package/dist/collection/components/calcite-select/calcite-select.css +23 -39
- package/dist/collection/components/calcite-select/calcite-select.js +3 -5
- package/dist/collection/components/calcite-shell/calcite-shell.css +43 -43
- package/dist/collection/components/calcite-shell/calcite-shell.js +23 -9
- package/dist/collection/components/calcite-shell-center-row/calcite-shell-center-row.css +26 -21
- package/dist/collection/components/calcite-shell-center-row/calcite-shell-center-row.js +13 -1
- package/dist/collection/components/calcite-shell-panel/calcite-shell-panel.css +33 -52
- package/dist/collection/components/calcite-shell-panel/calcite-shell-panel.js +9 -4
- package/dist/collection/components/calcite-slider/calcite-slider.css +50 -93
- package/dist/collection/components/calcite-slider/calcite-slider.js +10 -7
- package/dist/collection/components/calcite-sortable-list/calcite-sortable-list.css +1 -11
- package/dist/collection/components/calcite-split-button/calcite-split-button.css +7 -27
- package/dist/collection/components/calcite-stepper/calcite-stepper.css +8 -18
- package/dist/collection/components/calcite-stepper-item/calcite-stepper-item.css +38 -72
- package/dist/collection/components/calcite-switch/calcite-switch.css +29 -47
- package/dist/collection/components/calcite-tab/calcite-tab.css +10 -20
- package/dist/collection/components/calcite-tab-nav/calcite-tab-nav.css +14 -23
- package/dist/collection/components/calcite-tab-title/calcite-tab-title.css +40 -65
- package/dist/collection/components/calcite-tabs/calcite-tabs.css +3 -13
- package/dist/collection/components/calcite-tile/calcite-tile.css +52 -85
- package/dist/collection/components/calcite-tile/calcite-tile.js +12 -0
- package/dist/collection/components/calcite-tile-select/calcite-tile-select.css +52 -87
- package/dist/collection/components/calcite-tile-select/calcite-tile-select.js +21 -2
- package/dist/collection/components/calcite-tile-select/resources.js +20 -0
- package/dist/collection/components/calcite-tile-select-group/calcite-tile-select-group.css +1 -12
- package/dist/collection/components/calcite-time-picker/calcite-time-picker.css +15 -47
- package/dist/collection/components/calcite-time-picker/calcite-time-picker.js +5 -5
- package/dist/collection/components/calcite-tip/calcite-tip.css +20 -36
- package/dist/collection/components/calcite-tip/calcite-tip.js +13 -1
- package/dist/collection/components/calcite-tip-group/calcite-tip-group.css +4 -14
- package/dist/collection/components/calcite-tip-manager/calcite-tip-manager.css +34 -49
- package/dist/collection/components/calcite-tooltip/calcite-tooltip.css +12 -20
- package/dist/collection/components/calcite-tooltip/calcite-tooltip.js +5 -5
- package/dist/collection/components/calcite-tooltip-manager/calcite-tooltip-manager.css +1 -11
- package/dist/collection/components/calcite-tooltip-manager/calcite-tooltip-manager.js +1 -1
- package/dist/collection/components/calcite-tree/calcite-tree.css +1 -11
- package/dist/collection/components/calcite-tree/calcite-tree.js +2 -1
- package/dist/collection/components/calcite-tree-item/calcite-tree-item.css +27 -58
- package/dist/collection/components/calcite-tree-item/calcite-tree-item.js +21 -8
- package/dist/collection/components/calcite-value-list/calcite-value-list.css +17 -25
- package/dist/collection/components/calcite-value-list/calcite-value-list.js +23 -9
- package/dist/collection/components/calcite-value-list-item/calcite-value-list-item.css +22 -32
- package/dist/collection/components/calcite-value-list-item/calcite-value-list-item.js +12 -0
- package/dist/collection/components/chip/interfaces.js +1 -0
- package/dist/collection/components/color-picker/interfaces.js +1 -0
- package/dist/collection/components/color-picker/utils.js +107 -0
- package/dist/collection/components/combobox/interfaces.js +1 -0
- package/dist/collection/components/date-picker/interfaces.js +1 -0
- package/dist/collection/components/date-picker/utils.js +53 -0
- package/dist/collection/components/dropdown/interfaces.js +1 -0
- package/dist/collection/components/dropdown-group/interfaces.js +1 -0
- package/dist/collection/components/functional/Heading.js +9 -0
- package/dist/collection/components/graph/interfaces.js +1 -0
- package/dist/collection/components/input/interfaces.js +1 -0
- package/dist/collection/components/modal/interfaces.js +1 -0
- package/dist/collection/components/pagination/pagination.js +201 -0
- package/dist/collection/components/pagination/resources.js +14 -0
- package/dist/collection/components/pick-list/pick-list.js +192 -0
- package/dist/collection/components/pick-list/resources.js +15 -0
- package/dist/collection/components/pick-list/shared-list-logic.js +269 -0
- package/dist/collection/components/pick-list/shared-list-render.js +25 -0
- package/dist/collection/components/radio-group/interfaces.js +1 -0
- package/dist/collection/components/tab/interfaces.js +1 -0
- package/dist/collection/components/tabs/interfaces.js +1 -0
- package/dist/collection/components/tile-select/interfaces.js +1 -0
- package/dist/collection/components/tile-select-group/interfaces.js +1 -0
- package/dist/collection/components/tree/interfaces.js +8 -0
- package/dist/collection/components/tree-item/interfaces.js +1 -0
- package/dist/collection/components/value-list/resources.js +11 -0
- package/dist/collection/components/value-list/value-list.js +266 -0
- package/dist/collection/utils/conditionalSlot.js +22 -11
- package/dist/collection/utils/dom.js +44 -11
- package/dist/collection/utils/globalAttributes.js +59 -0
- package/dist/collection/utils/label.js +4 -1
- package/dist/collection/utils/locale.js +43 -38
- package/dist/collection/utils/number.js +48 -23
- package/dist/collection/utils/observers.js +5 -1
- package/dist/components/calcite-accordion-item.js +1 -1
- package/dist/components/calcite-accordion.js +5 -2
- package/dist/components/calcite-action-bar.js +3 -24
- package/dist/components/calcite-action-group2.js +13 -1
- package/dist/components/calcite-action-menu2.js +5 -5
- package/dist/components/calcite-action-pad.js +8 -1
- package/dist/components/calcite-action2.js +1 -1
- package/dist/components/calcite-alert.js +29 -21
- package/dist/components/calcite-avatar.js +1 -1
- package/dist/components/calcite-block-section.js +1 -1
- package/dist/components/calcite-block.js +14 -2
- package/dist/components/calcite-button2.js +1 -1
- package/dist/components/calcite-card.js +16 -7
- package/dist/components/calcite-checkbox2.js +2 -2
- package/dist/components/calcite-chip2.js +14 -2
- package/dist/components/calcite-color-picker-hex-input2.js +1 -1
- package/dist/components/calcite-color-picker-swatch2.js +17 -2
- package/dist/components/calcite-color-picker.js +1 -1
- package/dist/components/calcite-combobox-item-group.js +1 -1
- package/dist/components/calcite-combobox-item.js +9 -7
- package/dist/components/calcite-combobox.js +23 -13
- package/dist/components/calcite-date-picker-day2.js +1 -1
- package/dist/components/calcite-date-picker-month-header2.js +1 -1
- package/dist/components/calcite-date-picker-month2.js +1 -1
- package/dist/components/calcite-date-picker2.js +17 -11
- package/dist/components/calcite-dropdown-group.js +1 -1
- package/dist/components/calcite-dropdown-item.js +1 -1
- package/dist/components/calcite-dropdown2.js +27 -21
- package/dist/components/calcite-fab.js +1 -1
- package/dist/components/calcite-filter2.js +1 -1
- package/dist/components/calcite-flow.js +1 -1
- package/dist/components/calcite-graph2.js +14 -9
- package/dist/components/calcite-handle2.js +1 -1
- package/dist/components/calcite-icon2.js +1 -1
- package/dist/components/calcite-inline-editable.js +45 -20
- package/dist/components/calcite-input-date-picker.js +8 -3
- package/dist/components/calcite-input-message.js +1 -1
- package/dist/components/calcite-input-time-picker.js +2 -2
- package/dist/components/calcite-input2.js +130 -58
- package/dist/components/calcite-label2.js +5 -2
- package/dist/components/calcite-link2.js +15 -3
- package/dist/components/calcite-list-item-group.js +1 -1
- package/dist/components/calcite-list-item.js +13 -1
- package/dist/components/calcite-list.js +1 -1
- package/dist/components/calcite-loader2.js +1 -1
- package/dist/components/calcite-modal.js +7 -4
- package/dist/components/calcite-notice.js +12 -7
- package/dist/components/calcite-option-group.js +1 -1
- package/dist/components/calcite-option.js +1 -1
- package/dist/components/calcite-pagination.js +1 -1
- package/dist/components/calcite-panel.js +37 -15
- package/dist/components/calcite-pick-list-group.js +13 -1
- package/dist/components/calcite-pick-list-item2.js +13 -1
- package/dist/components/calcite-pick-list.js +3 -2
- package/dist/components/calcite-popover-manager.js +2 -2
- package/dist/components/calcite-popover2.js +2 -2
- package/dist/components/calcite-progress2.js +1 -1
- package/dist/components/calcite-radio-button-group.js +14 -1
- package/dist/components/calcite-radio-button.js +17 -10
- package/dist/components/calcite-radio-group-item.js +1 -46
- package/dist/components/calcite-radio-group.js +2 -2
- package/dist/components/calcite-rating.js +1 -1
- package/dist/components/calcite-scrim2.js +1 -1
- package/dist/components/calcite-select.js +2 -2
- package/dist/components/calcite-shell-center-row.js +14 -2
- package/dist/components/calcite-shell-panel.js +10 -5
- package/dist/components/calcite-shell.js +22 -7
- package/dist/components/calcite-slider.js +11 -7
- package/dist/components/calcite-sortable-list.js +1 -1
- package/dist/components/calcite-split-button.js +1 -1
- package/dist/components/calcite-stepper-item.js +1 -1
- package/dist/components/calcite-stepper.js +1 -1
- package/dist/components/calcite-switch2.js +1 -1
- package/dist/components/calcite-tab-nav2.js +1 -1
- package/dist/components/calcite-tab-title2.js +1 -1
- package/dist/components/calcite-tab2.js +1 -1
- package/dist/components/calcite-tabs2.js +1 -1
- package/dist/components/calcite-tile-select-group.js +1 -1
- package/dist/components/calcite-tile-select.js +37 -2
- package/dist/components/calcite-tile2.js +13 -1
- package/dist/components/calcite-time-picker2.js +5 -5
- package/dist/components/calcite-tip-group.js +1 -1
- package/dist/components/calcite-tip-manager.js +1 -1
- package/dist/components/calcite-tip.js +14 -2
- package/dist/components/calcite-tooltip-manager2.js +2 -2
- package/dist/components/calcite-tooltip.js +4 -4
- package/dist/components/calcite-tree-item.js +20 -9
- package/dist/components/calcite-tree.js +3 -2
- package/dist/components/calcite-value-list-item.js +13 -1
- package/dist/components/calcite-value-list.js +11 -4
- package/dist/components/conditionalSlot.js +40 -0
- package/dist/components/dom.js +44 -11
- package/dist/components/label.js +4 -1
- package/dist/components/locale.js +43 -38
- package/dist/components/number.js +49 -24
- package/dist/components/observers.js +5 -1
- package/dist/components/popper.js +28 -9
- package/dist/components/resources3.js +1 -1
- package/dist/components/shared-list-render.js +11 -1
- package/dist/components/utils2.js +4 -1
- package/dist/custom-elements/index.js +1236 -758
- package/dist/esm/{CalciteExpandToggle-c33bd6fd.js → CalciteExpandToggle-3ebdb3a6.js} +2 -2
- package/dist/esm/{CalciteHeading-1d6cd311.js → CalciteHeading-fa0da825.js} +1 -1
- package/dist/esm/calcite-accordion_2.entry.js +8 -5
- package/dist/esm/calcite-action-bar.entry.js +6 -27
- package/dist/esm/calcite-action-group.entry.js +16 -3
- package/dist/esm/calcite-action-menu.entry.js +8 -8
- package/dist/esm/calcite-action-pad.entry.js +12 -4
- package/dist/esm/calcite-action.entry.js +3 -3
- package/dist/esm/calcite-alert.entry.js +29 -22
- package/dist/esm/calcite-avatar.entry.js +3 -3
- package/dist/esm/calcite-block_2.entry.js +19 -6
- package/dist/esm/calcite-button.entry.js +5 -5
- package/dist/esm/calcite-card.entry.js +19 -8
- package/dist/esm/calcite-checkbox.entry.js +6 -6
- package/dist/esm/calcite-chip.entry.js +17 -4
- package/dist/esm/calcite-color-picker_3.entry.js +21 -6
- package/dist/esm/calcite-combobox_3.entry.js +39 -25
- package/dist/esm/calcite-date-picker_4.entry.js +19 -17
- package/dist/esm/calcite-dropdown_3.entry.js +32 -26
- package/dist/esm/calcite-fab.entry.js +3 -3
- package/dist/esm/calcite-filter.entry.js +3 -3
- package/dist/esm/calcite-flow.entry.js +3 -3
- package/dist/esm/calcite-graph_2.entry.js +28 -17
- package/dist/esm/calcite-handle.entry.js +2 -2
- package/dist/esm/calcite-icon.entry.js +4 -4
- package/dist/esm/calcite-inline-editable.entry.js +47 -22
- package/dist/esm/calcite-input-date-picker.entry.js +15 -10
- package/dist/esm/calcite-input-message.entry.js +3 -3
- package/dist/esm/calcite-input-time-picker_2.entry.js +11 -11
- package/dist/esm/calcite-input.entry.js +135 -63
- package/dist/esm/calcite-label.entry.js +6 -3
- package/dist/esm/calcite-link.entry.js +16 -5
- package/dist/esm/calcite-list_3.entry.js +19 -6
- package/dist/esm/calcite-loader.entry.js +2 -2
- package/dist/esm/calcite-modal.entry.js +10 -7
- package/dist/esm/calcite-notice.entry.js +15 -9
- package/dist/esm/calcite-option_3.entry.js +8 -8
- package/dist/esm/calcite-pagination.entry.js +2 -2
- package/dist/esm/calcite-panel.entry.js +39 -17
- package/dist/esm/calcite-pick-list_3.entry.js +32 -8
- package/dist/esm/calcite-popover_2.entry.js +8 -8
- package/dist/esm/calcite-progress.entry.js +2 -2
- package/dist/esm/calcite-radio-button-group.entry.js +15 -2
- package/dist/esm/calcite-radio-button.entry.js +21 -14
- package/dist/esm/calcite-radio-group_2.entry.js +6 -51
- package/dist/esm/calcite-rating.entry.js +5 -5
- package/dist/esm/calcite-scrim.entry.js +2 -2
- package/dist/esm/calcite-shell_3.entry.js +47 -16
- package/dist/esm/calcite-sortable-list.entry.js +3 -3
- package/dist/esm/calcite-split-button.entry.js +2 -2
- package/dist/esm/calcite-stepper_2.entry.js +4 -4
- package/dist/esm/calcite-switch.entry.js +5 -5
- package/dist/esm/calcite-tab_4.entry.js +7 -7
- package/dist/esm/calcite-tile-select_2.entry.js +39 -4
- package/dist/esm/calcite-tile.entry.js +16 -3
- package/dist/esm/calcite-tip_3.entry.js +20 -8
- package/dist/esm/calcite-tooltip_2.entry.js +9 -9
- package/dist/esm/calcite-tree_2.entry.js +26 -13
- package/dist/esm/calcite-value-list_2.entry.js +27 -8
- package/dist/esm/calcite.js +3 -3
- package/dist/esm/conditionalSlot-0e575a09.js +40 -0
- package/dist/esm/{dom-f24e866c.js → dom-e7fa77b9.js} +44 -11
- package/dist/esm/{form-160b0fb5.js → form-42bda668.js} +2 -2
- package/dist/esm/{index-9de00868.js → index-c4b90cce.js} +0 -5
- package/dist/esm/{label-5559055d.js → label-2bffc9f4.js} +5 -2
- package/dist/esm/loader.js +3 -3
- package/dist/esm/locale-fc850b7c.js +123 -0
- package/dist/esm/number-8779395f.js +76 -0
- package/dist/esm/{observers-8f0bc419.js → observers-46118290.js} +5 -1
- package/dist/esm/{popper-f5caedc4.js → popper-ae231554.js} +29 -10
- package/dist/esm/{resources-35c1823f.js → resources-3c05dd64.js} +14 -4
- package/dist/esm/{resources-b4eee1d4.js → resources-704f6b2d.js} +9 -5
- package/dist/esm-es5/{CalciteExpandToggle-c33bd6fd.js → CalciteExpandToggle-3ebdb3a6.js} +1 -1
- package/dist/esm-es5/{CalciteHeading-1d6cd311.js → CalciteHeading-fa0da825.js} +1 -1
- package/dist/esm-es5/calcite-accordion_2.entry.js +1 -1
- package/dist/esm-es5/calcite-action-bar.entry.js +2 -2
- package/dist/esm-es5/calcite-action-group.entry.js +1 -1
- package/dist/esm-es5/calcite-action-menu.entry.js +2 -2
- package/dist/esm-es5/calcite-action-pad.entry.js +2 -2
- package/dist/esm-es5/calcite-action.entry.js +1 -1
- package/dist/esm-es5/calcite-alert.entry.js +1 -1
- package/dist/esm-es5/calcite-avatar.entry.js +1 -1
- package/dist/esm-es5/calcite-block_2.entry.js +1 -1
- package/dist/esm-es5/calcite-button.entry.js +1 -1
- package/dist/esm-es5/calcite-card.entry.js +1 -1
- package/dist/esm-es5/calcite-checkbox.entry.js +2 -2
- package/dist/esm-es5/calcite-chip.entry.js +2 -2
- package/dist/esm-es5/calcite-color-picker_3.entry.js +1 -1
- package/dist/esm-es5/calcite-combobox_3.entry.js +1 -1
- package/dist/esm-es5/calcite-date-picker_4.entry.js +1 -1
- package/dist/esm-es5/calcite-dropdown_3.entry.js +1 -1
- package/dist/esm-es5/calcite-fab.entry.js +2 -2
- package/dist/esm-es5/calcite-filter.entry.js +2 -2
- package/dist/esm-es5/calcite-flow.entry.js +2 -2
- package/dist/esm-es5/calcite-graph_2.entry.js +1 -1
- package/dist/esm-es5/calcite-handle.entry.js +2 -2
- package/dist/esm-es5/calcite-icon.entry.js +1 -1
- package/dist/esm-es5/calcite-inline-editable.entry.js +2 -2
- package/dist/esm-es5/calcite-input-date-picker.entry.js +1 -1
- package/dist/esm-es5/calcite-input-message.entry.js +1 -1
- package/dist/esm-es5/calcite-input-time-picker_2.entry.js +1 -1
- package/dist/esm-es5/calcite-input.entry.js +1 -1
- package/dist/esm-es5/calcite-label.entry.js +1 -1
- package/dist/esm-es5/calcite-link.entry.js +2 -2
- package/dist/esm-es5/calcite-list_3.entry.js +2 -2
- package/dist/esm-es5/calcite-loader.entry.js +1 -1
- package/dist/esm-es5/calcite-modal.entry.js +2 -2
- package/dist/esm-es5/calcite-notice.entry.js +2 -2
- package/dist/esm-es5/calcite-option_3.entry.js +1 -1
- package/dist/esm-es5/calcite-pagination.entry.js +1 -1
- package/dist/esm-es5/calcite-panel.entry.js +1 -1
- package/dist/esm-es5/calcite-pick-list_3.entry.js +1 -1
- package/dist/esm-es5/calcite-popover_2.entry.js +2 -2
- package/dist/esm-es5/calcite-progress.entry.js +1 -1
- package/dist/esm-es5/calcite-radio-button-group.entry.js +1 -1
- package/dist/esm-es5/calcite-radio-button.entry.js +1 -1
- package/dist/esm-es5/calcite-radio-group_2.entry.js +1 -1
- package/dist/esm-es5/calcite-rating.entry.js +2 -2
- package/dist/esm-es5/calcite-scrim.entry.js +1 -1
- package/dist/esm-es5/calcite-shell_3.entry.js +1 -1
- package/dist/esm-es5/calcite-sortable-list.entry.js +1 -1
- package/dist/esm-es5/calcite-split-button.entry.js +1 -1
- package/dist/esm-es5/calcite-stepper_2.entry.js +2 -2
- package/dist/esm-es5/calcite-switch.entry.js +2 -2
- package/dist/esm-es5/calcite-tab_4.entry.js +1 -1
- package/dist/esm-es5/calcite-tile-select_2.entry.js +2 -2
- package/dist/esm-es5/calcite-tile.entry.js +1 -1
- package/dist/esm-es5/calcite-tip_3.entry.js +1 -1
- package/dist/esm-es5/calcite-tooltip_2.entry.js +1 -1
- package/dist/esm-es5/calcite-tree_2.entry.js +1 -1
- package/dist/esm-es5/calcite-value-list_2.entry.js +1 -1
- package/dist/esm-es5/calcite.js +1 -1
- package/dist/esm-es5/conditionalSlot-0e575a09.js +5 -0
- package/dist/esm-es5/dom-e7fa77b9.js +5 -0
- package/dist/esm-es5/{form-160b0fb5.js → form-42bda668.js} +1 -1
- package/dist/esm-es5/{index-9de00868.js → index-c4b90cce.js} +1 -1
- package/dist/esm-es5/label-2bffc9f4.js +5 -0
- package/dist/esm-es5/loader.js +1 -1
- package/dist/esm-es5/locale-fc850b7c.js +5 -0
- package/dist/esm-es5/number-8779395f.js +5 -0
- package/dist/esm-es5/{observers-8f0bc419.js → observers-46118290.js} +1 -1
- package/dist/esm-es5/popper-ae231554.js +5 -0
- package/dist/esm-es5/resources-3c05dd64.js +5 -0
- package/dist/esm-es5/resources-704f6b2d.js +5 -0
- package/dist/extras/docs-json.json +189 -73
- package/dist/types/components/calcite-accordion/calcite-accordion.d.ts +42 -0
- package/dist/types/components/calcite-accordion-item/calcite-accordion-item.d.ts +53 -0
- package/dist/types/components/calcite-action/calcite-action.d.ts +73 -0
- package/dist/types/components/calcite-action-bar/calcite-action-bar.d.ts +69 -0
- package/dist/types/components/calcite-action-group/calcite-action-group.d.ts +42 -0
- package/dist/types/components/calcite-action-menu/calcite-action-menu.d.ts +83 -0
- package/dist/types/components/calcite-action-pad/calcite-action-pad.d.ts +55 -0
- package/dist/types/components/calcite-alert/calcite-alert.d.ts +83 -0
- package/dist/types/components/calcite-alert/interfaces.d.ts +1 -0
- package/dist/types/components/calcite-avatar/calcite-avatar.d.ts +26 -0
- package/dist/types/components/calcite-block/calcite-block.d.ts +76 -0
- package/dist/types/components/calcite-block-section/calcite-block-section.d.ts +43 -0
- package/dist/types/components/calcite-button/calcite-button.d.ts +81 -0
- package/dist/types/components/calcite-card/calcite-card.d.ts +46 -0
- package/dist/types/components/calcite-checkbox/calcite-checkbox.d.ts +73 -0
- package/dist/types/components/calcite-chip/calcite-chip.d.ts +40 -0
- package/dist/types/components/calcite-color-picker/calcite-color-picker.d.ts +224 -0
- package/dist/types/components/calcite-color-picker-hex-input/calcite-color-picker-hex-input.d.ts +51 -0
- package/dist/types/components/calcite-color-picker-swatch/calcite-color-picker-swatch.d.ts +23 -0
- package/dist/types/components/calcite-combobox/calcite-combobox.d.ts +181 -0
- package/dist/types/components/calcite-combobox/interfaces.d.ts +6 -0
- package/dist/types/components/calcite-combobox/resources.d.ts +3 -0
- package/dist/types/components/calcite-combobox/utils.d.ts +6 -0
- package/dist/types/components/calcite-combobox-item/calcite-combobox-item.d.ts +46 -0
- package/dist/types/components/calcite-combobox-item-group/calcite-combobox-item-group.d.ts +17 -0
- package/dist/types/components/calcite-date-picker/calcite-date-picker.d.ts +132 -0
- package/dist/types/components/calcite-date-picker-day/calcite-date-picker-day.d.ts +45 -0
- package/dist/types/components/calcite-date-picker-month/calcite-date-picker-month.d.ts +97 -0
- package/dist/types/components/calcite-date-picker-month-header/calcite-date-picker-month-header.d.ts +57 -0
- package/dist/types/components/calcite-dropdown/calcite-dropdown.d.ts +99 -0
- package/dist/types/components/calcite-dropdown-group/calcite-dropdown-group.d.ts +32 -0
- package/dist/types/components/calcite-dropdown-item/calcite-dropdown-item.d.ts +52 -0
- package/dist/types/components/calcite-fab/calcite-fab.d.ts +47 -0
- package/dist/types/components/calcite-filter/calcite-filter.d.ts +53 -0
- package/dist/types/components/calcite-flow/calcite-flow.d.ts +22 -0
- package/dist/types/components/calcite-graph/calcite-graph.d.ts +28 -0
- package/dist/types/components/calcite-handle/calcite-handle.d.ts +22 -0
- package/dist/types/components/calcite-icon/calcite-icon.d.ts +32 -0
- package/dist/types/components/calcite-inline-editable/calcite-inline-editable.d.ts +71 -0
- package/dist/types/components/calcite-input/calcite-input.d.ts +168 -0
- package/dist/types/components/calcite-input-date-picker/calcite-input-date-picker.d.ts +179 -0
- package/dist/types/components/calcite-input-message/calcite-input-message.d.ts +27 -0
- package/dist/types/components/calcite-input-time-picker/calcite-input-time-picker.d.ts +90 -0
- package/dist/types/components/calcite-label/calcite-label.d.ts +33 -0
- package/dist/types/components/calcite-link/calcite-link.d.ts +38 -0
- package/dist/types/components/calcite-list/calcite-list.d.ts +16 -0
- package/dist/types/components/calcite-list-item/calcite-list-item.d.ts +40 -0
- package/dist/types/components/calcite-list-item-group/calcite-list-item-group.d.ts +18 -0
- package/dist/types/components/calcite-loader/calcite-loader.d.ts +27 -0
- package/dist/types/components/calcite-modal/calcite-modal.d.ts +89 -0
- package/dist/types/components/calcite-notice/calcite-notice.d.ts +51 -0
- package/dist/types/components/calcite-pagination/calcite-pagination.d.ts +51 -0
- package/dist/types/components/calcite-panel/calcite-panel.d.ts +130 -0
- package/dist/types/components/calcite-pick-list/calcite-pick-list.d.ts +75 -0
- package/dist/types/components/calcite-pick-list/shared-list-logic.d.ts +31 -0
- package/dist/types/components/calcite-pick-list/shared-list-render.d.ts +18 -0
- package/dist/types/components/calcite-pick-list-group/calcite-pick-list-group.d.ts +21 -0
- package/dist/types/components/calcite-pick-list-item/calcite-pick-list-item.d.ts +106 -0
- package/dist/types/components/calcite-popover/calcite-popover.d.ts +107 -0
- package/dist/types/components/calcite-popover-manager/calcite-popover-manager.d.ts +19 -0
- package/dist/types/components/calcite-progress/calcite-progress.d.ts +15 -0
- package/dist/types/components/calcite-radio-button/calcite-radio-button.d.ts +92 -0
- package/dist/types/components/calcite-radio-button-group/calcite-radio-button-group.d.ts +34 -0
- package/dist/types/components/calcite-radio-group/calcite-radio-group.d.ts +56 -0
- package/dist/types/components/calcite-radio-group-item/calcite-radio-group-item.d.ts +24 -0
- package/dist/types/components/calcite-rating/calcite-rating.d.ts +60 -0
- package/dist/types/components/calcite-scrim/calcite-scrim.d.ts +17 -0
- package/dist/types/components/calcite-select/calcite-select.d.ts +75 -0
- package/dist/types/components/calcite-shell/calcite-shell.d.ts +24 -0
- package/dist/types/components/calcite-shell-center-row/calcite-shell-center-row.d.ts +25 -0
- package/dist/types/components/calcite-shell-panel/calcite-shell-panel.d.ts +69 -0
- package/dist/types/components/calcite-slider/calcite-slider.d.ts +193 -0
- package/dist/types/components/calcite-sortable-list/calcite-sortable-list.d.ts +50 -0
- package/dist/types/components/calcite-split-button/calcite-split-button.d.ts +52 -0
- package/dist/types/components/calcite-stepper/calcite-stepper.d.ts +58 -0
- package/dist/types/components/calcite-stepper-item/calcite-stepper-item.d.ts +65 -0
- package/dist/types/components/calcite-switch/calcite-switch.d.ts +46 -0
- package/dist/types/components/calcite-tab/calcite-tab.d.ts +42 -0
- package/dist/types/components/calcite-tab-nav/calcite-tab-nav.d.ts +74 -0
- package/dist/types/components/calcite-tab-title/calcite-tab-title.d.ts +92 -0
- package/dist/types/components/calcite-tabs/calcite-tabs.d.ts +65 -0
- package/dist/types/components/calcite-tile/calcite-tile.d.ts +36 -0
- package/dist/types/components/calcite-tile-select/calcite-tile-select.d.ts +57 -0
- package/dist/types/components/calcite-tile-select/resources.d.ts +16 -0
- package/dist/types/components/calcite-time-picker/calcite-time-picker.d.ts +135 -0
- package/dist/types/components/calcite-tip/calcite-tip.d.ts +47 -0
- package/dist/types/components/calcite-tip-manager/calcite-tip-manager.d.ts +65 -0
- package/dist/types/components/calcite-tooltip/calcite-tooltip.d.ts +60 -0
- package/dist/types/components/calcite-tooltip-manager/calcite-tooltip-manager.d.ts +41 -0
- package/dist/types/components/calcite-tree/calcite-tree.d.ts +38 -0
- package/dist/types/components/calcite-tree/interfaces.d.ts +10 -0
- package/dist/types/components/calcite-tree-item/calcite-tree-item.d.ts +60 -0
- package/dist/types/components/calcite-value-list/calcite-value-list.d.ts +89 -0
- package/dist/types/components/calcite-value-list-item/calcite-value-list-item.d.ts +79 -0
- package/dist/types/components/functional/CalciteExpandToggle.d.ts +19 -0
- package/dist/types/components.d.ts +62 -32
- package/dist/types/preact.d.ts +5 -4
- package/dist/types/stencil-public-runtime.d.ts +6 -4
- package/dist/types/utils/dom.d.ts +21 -3
- package/dist/types/utils/globalAttributes.d.ts +35 -0
- package/dist/types/utils/label.d.ts +39 -0
- package/dist/types/utils/number.d.ts +2 -1
- package/hydrate/index.js +1244 -759
- package/package.json +35 -32
- package/readme.md +2 -36
- package/dist/calcite/p-0229a408.js +0 -5
- package/dist/calcite/p-057197f8.entry.js +0 -5
- package/dist/calcite/p-05c10c53.entry.js +0 -5
- package/dist/calcite/p-05edaadf.system.entry.js +0 -5
- package/dist/calcite/p-0b45733b.entry.js +0 -5
- package/dist/calcite/p-112f20e6.system.entry.js +0 -5
- package/dist/calcite/p-11f01c0a.entry.js +0 -5
- package/dist/calcite/p-18d9a261.system.js +0 -5
- package/dist/calcite/p-1942876c.js +0 -5
- package/dist/calcite/p-2151c991.entry.js +0 -5
- package/dist/calcite/p-288899b9.entry.js +0 -5
- package/dist/calcite/p-288bc438.system.js +0 -5
- package/dist/calcite/p-2b294f8e.system.entry.js +0 -5
- package/dist/calcite/p-2be1e8ee.entry.js +0 -5
- package/dist/calcite/p-2d939f9e.system.entry.js +0 -5
- package/dist/calcite/p-2fbd50f3.system.entry.js +0 -5
- package/dist/calcite/p-30036f23.system.entry.js +0 -5
- package/dist/calcite/p-35a5c74c.system.js +0 -5
- package/dist/calcite/p-3739338a.system.entry.js +0 -5
- package/dist/calcite/p-3c25cb72.system.entry.js +0 -5
- package/dist/calcite/p-3d8ee39d.system.entry.js +0 -5
- package/dist/calcite/p-3dae9da3.js +0 -5
- package/dist/calcite/p-3e9c6068.entry.js +0 -5
- package/dist/calcite/p-3f8527a3.entry.js +0 -5
- package/dist/calcite/p-40991717.entry.js +0 -5
- package/dist/calcite/p-4278fb57.entry.js +0 -5
- package/dist/calcite/p-44cce7a3.system.entry.js +0 -5
- package/dist/calcite/p-4d02c6c0.system.entry.js +0 -5
- package/dist/calcite/p-4e9d072a.system.js +0 -5
- package/dist/calcite/p-4f1f716a.system.entry.js +0 -5
- package/dist/calcite/p-4f7ebefc.system.js +0 -5
- package/dist/calcite/p-52cc870b.js +0 -5
- package/dist/calcite/p-55f68e28.entry.js +0 -5
- package/dist/calcite/p-57169a74.entry.js +0 -5
- package/dist/calcite/p-5c9d89ce.system.entry.js +0 -5
- package/dist/calcite/p-62f3d4df.system.js +0 -5
- package/dist/calcite/p-63b9f804.entry.js +0 -5
- package/dist/calcite/p-689790cb.system.entry.js +0 -5
- package/dist/calcite/p-69bd1f5f.system.entry.js +0 -5
- package/dist/calcite/p-6a87d7b2.entry.js +0 -5
- package/dist/calcite/p-6cc23c39.system.js +0 -5
- package/dist/calcite/p-6faaa8af.system.entry.js +0 -5
- package/dist/calcite/p-6fb63fc1.entry.js +0 -5
- package/dist/calcite/p-72a60528.system.entry.js +0 -5
- package/dist/calcite/p-763479d6.system.entry.js +0 -5
- package/dist/calcite/p-768018df.entry.js +0 -5
- package/dist/calcite/p-76eda40b.entry.js +0 -5
- package/dist/calcite/p-7ac9f860.entry.js +0 -5
- package/dist/calcite/p-7ff5e336.entry.js +0 -5
- package/dist/calcite/p-8340b572.js +0 -5
- package/dist/calcite/p-83744979.system.js +0 -5
- package/dist/calcite/p-88296be9.system.entry.js +0 -5
- package/dist/calcite/p-88b31760.system.entry.js +0 -5
- package/dist/calcite/p-8a8982ab.system.entry.js +0 -5
- package/dist/calcite/p-8ebc2d51.entry.js +0 -5
- package/dist/calcite/p-9180be05.system.entry.js +0 -5
- package/dist/calcite/p-93a189be.entry.js +0 -5
- package/dist/calcite/p-97117a5d.entry.js +0 -5
- package/dist/calcite/p-97efd284.system.entry.js +0 -5
- package/dist/calcite/p-998829cb.system.entry.js +0 -5
- package/dist/calcite/p-9a1ffbad.system.entry.js +0 -5
- package/dist/calcite/p-9a8f3883.entry.js +0 -5
- package/dist/calcite/p-9b979692.entry.js +0 -5
- package/dist/calcite/p-9fc14d49.entry.js +0 -5
- package/dist/calcite/p-9feb0f5a.system.entry.js +0 -5
- package/dist/calcite/p-a3c498de.entry.js +0 -5
- package/dist/calcite/p-a4784cf3.system.entry.js +0 -5
- package/dist/calcite/p-a6f99f79.entry.js +0 -5
- package/dist/calcite/p-a98344e2.system.entry.js +0 -5
- package/dist/calcite/p-a9f596be.system.entry.js +0 -5
- package/dist/calcite/p-adf4699d.system.entry.js +0 -5
- package/dist/calcite/p-b180d943.system.entry.js +0 -5
- package/dist/calcite/p-b2f0596f.entry.js +0 -5
- package/dist/calcite/p-b437a8eb.system.entry.js +0 -5
- package/dist/calcite/p-b43e699c.system.entry.js +0 -5
- package/dist/calcite/p-ba7c0f01.system.entry.js +0 -5
- package/dist/calcite/p-bd091b49.system.entry.js +0 -5
- package/dist/calcite/p-bdca5372.entry.js +0 -5
- package/dist/calcite/p-bfa6bd72.entry.js +0 -5
- package/dist/calcite/p-c00b1d26.js +0 -5
- package/dist/calcite/p-c2bfd7f9.system.entry.js +0 -5
- package/dist/calcite/p-c2fcf603.system.entry.js +0 -5
- package/dist/calcite/p-c34c4414.system.js +0 -5
- package/dist/calcite/p-c70bacc8.system.entry.js +0 -5
- package/dist/calcite/p-c8c6323c.entry.js +0 -5
- package/dist/calcite/p-cb660e54.entry.js +0 -5
- package/dist/calcite/p-cd5d5756.system.entry.js +0 -5
- package/dist/calcite/p-ce704ece.js +0 -5
- package/dist/calcite/p-cf499949.entry.js +0 -5
- package/dist/calcite/p-d17cfab3.entry.js +0 -5
- package/dist/calcite/p-d3bd900e.js +0 -5
- package/dist/calcite/p-d4d5665a.system.entry.js +0 -5
- package/dist/calcite/p-d9414082.system.entry.js +0 -5
- package/dist/calcite/p-dc7124e9.entry.js +0 -5
- package/dist/calcite/p-dc777403.system.entry.js +0 -5
- package/dist/calcite/p-dda22c7e.system.entry.js +0 -5
- package/dist/calcite/p-de67ba93.system.entry.js +0 -5
- package/dist/calcite/p-e09bac0d.system.entry.js +0 -5
- package/dist/calcite/p-e35b29f5.system.entry.js +0 -5
- package/dist/calcite/p-e4acb5a8.js +0 -5
- package/dist/calcite/p-e54784a8.system.entry.js +0 -5
- package/dist/calcite/p-e63c6a55.system.entry.js +0 -5
- package/dist/calcite/p-e697ab57.system.entry.js +0 -5
- package/dist/calcite/p-e7801f1d.entry.js +0 -5
- package/dist/calcite/p-e7f7b0f8.js +0 -5
- package/dist/calcite/p-eebd2bb0.entry.js +0 -5
- package/dist/calcite/p-f2340d02.system.entry.js +0 -5
- package/dist/calcite/p-f25f139a.entry.js +0 -5
- package/dist/calcite/p-f28d8e9e.system.entry.js +0 -5
- package/dist/calcite/p-f2f2ad57.entry.js +0 -5
- package/dist/calcite/p-f4a7fa43.entry.js +0 -5
- package/dist/calcite/p-f595d924.js +0 -5
- package/dist/calcite/p-f72c037c.entry.js +0 -5
- package/dist/calcite/p-f9e7371d.entry.js +0 -5
- package/dist/calcite/p-fc265aaf.entry.js +0 -5
- package/dist/calcite/p-fd94e88d.system.entry.js +0 -5
- package/dist/cjs/locale-33c458dc.js +0 -123
- package/dist/cjs/number-73f7b474.js +0 -58
- package/dist/esm/locale-4c38cf6d.js +0 -118
- package/dist/esm/number-06e8500e.js +0 -51
- package/dist/esm-es5/dom-f24e866c.js +0 -5
- package/dist/esm-es5/label-5559055d.js +0 -5
- package/dist/esm-es5/locale-4c38cf6d.js +0 -5
- package/dist/esm-es5/number-06e8500e.js +0 -5
- package/dist/esm-es5/popper-f5caedc4.js +0 -5
- package/dist/esm-es5/resources-35c1823f.js +0 -5
- package/dist/esm-es5/resources-b4eee1d4.js +0 -5
|
@@ -2,4 +2,4 @@ var __awaiter=this&&this.__awaiter||function(e,r,t,a){function n(e){return e ins
|
|
|
2
2
|
/*!
|
|
3
3
|
* All material copyright ESRI, All Rights Reserved, unless otherwise specified.
|
|
4
4
|
* See https://github.com/Esri/calcite-components/blob/master/LICENSE.md for details.
|
|
5
|
-
*/import{r as registerInstance,c as createEvent,h,g as getElement}from"./index-9de00868.js";import{f as focusElement,b as getThemeName}from"./dom-f24e866c.js";import{n as normalizeHex,C as CSSColorMode,p as parseMode,c as colorEqual,i as isValidHex,a as isLonghandHex,r as rgbToHex,h as hexToRGB,b as hexChar}from"./utils-6beb0662.js";import{c as clamp}from"./math-456207f5.js";import{d as debounce,i as isObject}from"./debounce-79648d42.js";import"./guid-196bd5ea.js";var FUNC_ERROR_TEXT="Expected a function";function throttle(e,r,t){var a=true,n=true;if(typeof e!="function"){throw new TypeError(FUNC_ERROR_TEXT)}if(isObject(t)){a="leading"in t?!!t.leading:a;n="trailing"in t?!!t.trailing:n}return debounce(e,r,{leading:a,maxWait:r,trailing:n})}function createCommonjsModule(e,r,t){return t={path:r,exports:{},require:function(e,r){return commonjsRequire()}},e(t,t.exports),t.exports}function commonjsRequire(){throw new Error("Dynamic requires are not currently supported by @rollup/plugin-commonjs")}var colorName$1={aliceblue:[240,248,255],antiquewhite:[250,235,215],aqua:[0,255,255],aquamarine:[127,255,212],azure:[240,255,255],beige:[245,245,220],bisque:[255,228,196],black:[0,0,0],blanchedalmond:[255,235,205],blue:[0,0,255],blueviolet:[138,43,226],brown:[165,42,42],burlywood:[222,184,135],cadetblue:[95,158,160],chartreuse:[127,255,0],chocolate:[210,105,30],coral:[255,127,80],cornflowerblue:[100,149,237],cornsilk:[255,248,220],crimson:[220,20,60],cyan:[0,255,255],darkblue:[0,0,139],darkcyan:[0,139,139],darkgoldenrod:[184,134,11],darkgray:[169,169,169],darkgreen:[0,100,0],darkgrey:[169,169,169],darkkhaki:[189,183,107],darkmagenta:[139,0,139],darkolivegreen:[85,107,47],darkorange:[255,140,0],darkorchid:[153,50,204],darkred:[139,0,0],darksalmon:[233,150,122],darkseagreen:[143,188,143],darkslateblue:[72,61,139],darkslategray:[47,79,79],darkslategrey:[47,79,79],darkturquoise:[0,206,209],darkviolet:[148,0,211],deeppink:[255,20,147],deepskyblue:[0,191,255],dimgray:[105,105,105],dimgrey:[105,105,105],dodgerblue:[30,144,255],firebrick:[178,34,34],floralwhite:[255,250,240],forestgreen:[34,139,34],fuchsia:[255,0,255],gainsboro:[220,220,220],ghostwhite:[248,248,255],gold:[255,215,0],goldenrod:[218,165,32],gray:[128,128,128],green:[0,128,0],greenyellow:[173,255,47],grey:[128,128,128],honeydew:[240,255,240],hotpink:[255,105,180],indianred:[205,92,92],indigo:[75,0,130],ivory:[255,255,240],khaki:[240,230,140],lavender:[230,230,250],lavenderblush:[255,240,245],lawngreen:[124,252,0],lemonchiffon:[255,250,205],lightblue:[173,216,230],lightcoral:[240,128,128],lightcyan:[224,255,255],lightgoldenrodyellow:[250,250,210],lightgray:[211,211,211],lightgreen:[144,238,144],lightgrey:[211,211,211],lightpink:[255,182,193],lightsalmon:[255,160,122],lightseagreen:[32,178,170],lightskyblue:[135,206,250],lightslategray:[119,136,153],lightslategrey:[119,136,153],lightsteelblue:[176,196,222],lightyellow:[255,255,224],lime:[0,255,0],limegreen:[50,205,50],linen:[250,240,230],magenta:[255,0,255],maroon:[128,0,0],mediumaquamarine:[102,205,170],mediumblue:[0,0,205],mediumorchid:[186,85,211],mediumpurple:[147,112,219],mediumseagreen:[60,179,113],mediumslateblue:[123,104,238],mediumspringgreen:[0,250,154],mediumturquoise:[72,209,204],mediumvioletred:[199,21,133],midnightblue:[25,25,112],mintcream:[245,255,250],mistyrose:[255,228,225],moccasin:[255,228,181],navajowhite:[255,222,173],navy:[0,0,128],oldlace:[253,245,230],olive:[128,128,0],olivedrab:[107,142,35],orange:[255,165,0],orangered:[255,69,0],orchid:[218,112,214],palegoldenrod:[238,232,170],palegreen:[152,251,152],paleturquoise:[175,238,238],palevioletred:[219,112,147],papayawhip:[255,239,213],peachpuff:[255,218,185],peru:[205,133,63],pink:[255,192,203],plum:[221,160,221],powderblue:[176,224,230],purple:[128,0,128],rebeccapurple:[102,51,153],red:[255,0,0],rosybrown:[188,143,143],royalblue:[65,105,225],saddlebrown:[139,69,19],salmon:[250,128,114],sandybrown:[244,164,96],seagreen:[46,139,87],seashell:[255,245,238],sienna:[160,82,45],silver:[192,192,192],skyblue:[135,206,235],slateblue:[106,90,205],slategray:[112,128,144],slategrey:[112,128,144],snow:[255,250,250],springgreen:[0,255,127],steelblue:[70,130,180],tan:[210,180,140],teal:[0,128,128],thistle:[216,191,216],tomato:[255,99,71],turquoise:[64,224,208],violet:[238,130,238],wheat:[245,222,179],white:[255,255,255],whitesmoke:[245,245,245],yellow:[255,255,0],yellowgreen:[154,205,50]};var isArrayish=function e(r){if(!r||typeof r==="string"){return false}return r instanceof Array||Array.isArray(r)||r.length>=0&&(r.splice instanceof Function||Object.getOwnPropertyDescriptor(r,r.length-1)&&r.constructor.name!=="String")};var simpleSwizzle=createCommonjsModule((function(e){var r=Array.prototype.concat;var t=Array.prototype.slice;var a=e.exports=function e(a){var n=[];for(var o=0,i=a.length;o<i;o++){var l=a[o];if(isArrayish(l)){n=r.call(n,t.call(l))}else{n.push(l)}}return n};a.wrap=function(e){return function(){return e(a(arguments))}}}));var colorString=createCommonjsModule((function(e){var r=Object.hasOwnProperty;var t={};for(var a in colorName$1){if(r.call(colorName$1,a)){t[colorName$1[a]]=a}}var n=e.exports={to:{},get:{}};n.get=function(e){var r=e.substring(0,3).toLowerCase();var t;var a;switch(r){case"hsl":t=n.get.hsl(e);a="hsl";break;case"hwb":t=n.get.hwb(e);a="hwb";break;default:t=n.get.rgb(e);a="rgb";break}if(!t){return null}return{model:a,value:t}};n.get.rgb=function(e){if(!e){return null}var t=/^#([a-f0-9]{3,4})$/i;var a=/^#([a-f0-9]{6})([a-f0-9]{2})?$/i;var n=/^rgba?\(\s*([+-]?\d+)(?=[\s,])\s*(?:,\s*)?([+-]?\d+)(?=[\s,])\s*(?:,\s*)?([+-]?\d+)\s*(?:[,|\/]\s*([+-]?[\d\.]+)(%?)\s*)?\)$/;var i=/^rgba?\(\s*([+-]?[\d\.]+)\%\s*,?\s*([+-]?[\d\.]+)\%\s*,?\s*([+-]?[\d\.]+)\%\s*(?:[,|\/]\s*([+-]?[\d\.]+)(%?)\s*)?\)$/;var l=/^(\w+)$/;var s=[0,0,0,1];var c;var h;var u;if(c=e.match(a)){u=c[2];c=c[1];for(h=0;h<3;h++){var d=h*2;s[h]=parseInt(c.slice(d,d+2),16)}if(u){s[3]=parseInt(u,16)/255}}else if(c=e.match(t)){c=c[1];u=c[3];for(h=0;h<3;h++){s[h]=parseInt(c[h]+c[h],16)}if(u){s[3]=parseInt(u+u,16)/255}}else if(c=e.match(n)){for(h=0;h<3;h++){s[h]=parseInt(c[h+1],0)}if(c[4]){if(c[5]){s[3]=parseFloat(c[4])*.01}else{s[3]=parseFloat(c[4])}}}else if(c=e.match(i)){for(h=0;h<3;h++){s[h]=Math.round(parseFloat(c[h+1])*2.55)}if(c[4]){if(c[5]){s[3]=parseFloat(c[4])*.01}else{s[3]=parseFloat(c[4])}}}else if(c=e.match(l)){if(c[1]==="transparent"){return[0,0,0,0]}if(!r.call(colorName$1,c[1])){return null}s=colorName$1[c[1]];s[3]=1;return s}else{return null}for(h=0;h<3;h++){s[h]=o(s[h],0,255)}s[3]=o(s[3],0,1);return s};n.get.hsl=function(e){if(!e){return null}var r=/^hsla?\(\s*([+-]?(?:\d{0,3}\.)?\d+)(?:deg)?\s*,?\s*([+-]?[\d\.]+)%\s*,?\s*([+-]?[\d\.]+)%\s*(?:[,|\/]\s*([+-]?(?=\.\d|\d)(?:0|[1-9]\d*)?(?:\.\d*)?(?:[eE][+-]?\d+)?)\s*)?\)$/;var t=e.match(r);if(t){var a=parseFloat(t[4]);var n=(parseFloat(t[1])%360+360)%360;var i=o(parseFloat(t[2]),0,100);var l=o(parseFloat(t[3]),0,100);var s=o(isNaN(a)?1:a,0,1);return[n,i,l,s]}return null};n.get.hwb=function(e){if(!e){return null}var r=/^hwb\(\s*([+-]?\d{0,3}(?:\.\d+)?)(?:deg)?\s*,\s*([+-]?[\d\.]+)%\s*,\s*([+-]?[\d\.]+)%\s*(?:,\s*([+-]?(?=\.\d|\d)(?:0|[1-9]\d*)?(?:\.\d*)?(?:[eE][+-]?\d+)?)\s*)?\)$/;var t=e.match(r);if(t){var a=parseFloat(t[4]);var n=(parseFloat(t[1])%360+360)%360;var i=o(parseFloat(t[2]),0,100);var l=o(parseFloat(t[3]),0,100);var s=o(isNaN(a)?1:a,0,1);return[n,i,l,s]}return null};n.to.hex=function(){var e=simpleSwizzle(arguments);return"#"+i(e[0])+i(e[1])+i(e[2])+(e[3]<1?i(Math.round(e[3]*255)):"")};n.to.rgb=function(){var e=simpleSwizzle(arguments);return e.length<4||e[3]===1?"rgb("+Math.round(e[0])+", "+Math.round(e[1])+", "+Math.round(e[2])+")":"rgba("+Math.round(e[0])+", "+Math.round(e[1])+", "+Math.round(e[2])+", "+e[3]+")"};n.to.rgb.percent=function(){var e=simpleSwizzle(arguments);var r=Math.round(e[0]/255*100);var t=Math.round(e[1]/255*100);var a=Math.round(e[2]/255*100);return e.length<4||e[3]===1?"rgb("+r+"%, "+t+"%, "+a+"%)":"rgba("+r+"%, "+t+"%, "+a+"%, "+e[3]+")"};n.to.hsl=function(){var e=simpleSwizzle(arguments);return e.length<4||e[3]===1?"hsl("+e[0]+", "+e[1]+"%, "+e[2]+"%)":"hsla("+e[0]+", "+e[1]+"%, "+e[2]+"%, "+e[3]+")"};n.to.hwb=function(){var e=simpleSwizzle(arguments);var r="";if(e.length>=4&&e[3]!==1){r=", "+e[3]}return"hwb("+e[0]+", "+e[1]+"%, "+e[2]+"%"+r+")"};n.to.keyword=function(e){return t[e.slice(0,3)]};function o(e,r,t){return Math.min(Math.max(r,e),t)}function i(e){var r=Math.round(e).toString(16).toUpperCase();return r.length<2?"0"+r:r}}));var colorName={aliceblue:[240,248,255],antiquewhite:[250,235,215],aqua:[0,255,255],aquamarine:[127,255,212],azure:[240,255,255],beige:[245,245,220],bisque:[255,228,196],black:[0,0,0],blanchedalmond:[255,235,205],blue:[0,0,255],blueviolet:[138,43,226],brown:[165,42,42],burlywood:[222,184,135],cadetblue:[95,158,160],chartreuse:[127,255,0],chocolate:[210,105,30],coral:[255,127,80],cornflowerblue:[100,149,237],cornsilk:[255,248,220],crimson:[220,20,60],cyan:[0,255,255],darkblue:[0,0,139],darkcyan:[0,139,139],darkgoldenrod:[184,134,11],darkgray:[169,169,169],darkgreen:[0,100,0],darkgrey:[169,169,169],darkkhaki:[189,183,107],darkmagenta:[139,0,139],darkolivegreen:[85,107,47],darkorange:[255,140,0],darkorchid:[153,50,204],darkred:[139,0,0],darksalmon:[233,150,122],darkseagreen:[143,188,143],darkslateblue:[72,61,139],darkslategray:[47,79,79],darkslategrey:[47,79,79],darkturquoise:[0,206,209],darkviolet:[148,0,211],deeppink:[255,20,147],deepskyblue:[0,191,255],dimgray:[105,105,105],dimgrey:[105,105,105],dodgerblue:[30,144,255],firebrick:[178,34,34],floralwhite:[255,250,240],forestgreen:[34,139,34],fuchsia:[255,0,255],gainsboro:[220,220,220],ghostwhite:[248,248,255],gold:[255,215,0],goldenrod:[218,165,32],gray:[128,128,128],green:[0,128,0],greenyellow:[173,255,47],grey:[128,128,128],honeydew:[240,255,240],hotpink:[255,105,180],indianred:[205,92,92],indigo:[75,0,130],ivory:[255,255,240],khaki:[240,230,140],lavender:[230,230,250],lavenderblush:[255,240,245],lawngreen:[124,252,0],lemonchiffon:[255,250,205],lightblue:[173,216,230],lightcoral:[240,128,128],lightcyan:[224,255,255],lightgoldenrodyellow:[250,250,210],lightgray:[211,211,211],lightgreen:[144,238,144],lightgrey:[211,211,211],lightpink:[255,182,193],lightsalmon:[255,160,122],lightseagreen:[32,178,170],lightskyblue:[135,206,250],lightslategray:[119,136,153],lightslategrey:[119,136,153],lightsteelblue:[176,196,222],lightyellow:[255,255,224],lime:[0,255,0],limegreen:[50,205,50],linen:[250,240,230],magenta:[255,0,255],maroon:[128,0,0],mediumaquamarine:[102,205,170],mediumblue:[0,0,205],mediumorchid:[186,85,211],mediumpurple:[147,112,219],mediumseagreen:[60,179,113],mediumslateblue:[123,104,238],mediumspringgreen:[0,250,154],mediumturquoise:[72,209,204],mediumvioletred:[199,21,133],midnightblue:[25,25,112],mintcream:[245,255,250],mistyrose:[255,228,225],moccasin:[255,228,181],navajowhite:[255,222,173],navy:[0,0,128],oldlace:[253,245,230],olive:[128,128,0],olivedrab:[107,142,35],orange:[255,165,0],orangered:[255,69,0],orchid:[218,112,214],palegoldenrod:[238,232,170],palegreen:[152,251,152],paleturquoise:[175,238,238],palevioletred:[219,112,147],papayawhip:[255,239,213],peachpuff:[255,218,185],peru:[205,133,63],pink:[255,192,203],plum:[221,160,221],powderblue:[176,224,230],purple:[128,0,128],rebeccapurple:[102,51,153],red:[255,0,0],rosybrown:[188,143,143],royalblue:[65,105,225],saddlebrown:[139,69,19],salmon:[250,128,114],sandybrown:[244,164,96],seagreen:[46,139,87],seashell:[255,245,238],sienna:[160,82,45],silver:[192,192,192],skyblue:[135,206,235],slateblue:[106,90,205],slategray:[112,128,144],slategrey:[112,128,144],snow:[255,250,250],springgreen:[0,255,127],steelblue:[70,130,180],tan:[210,180,140],teal:[0,128,128],thistle:[216,191,216],tomato:[255,99,71],turquoise:[64,224,208],violet:[238,130,238],wheat:[245,222,179],white:[255,255,255],whitesmoke:[245,245,245],yellow:[255,255,0],yellowgreen:[154,205,50]};var reverseKeywords={};for(var _i=0,_b=Object.keys(colorName);_i<_b.length;_i++){var key=_b[_i];reverseKeywords[colorName[key]]=key}var convert$1={rgb:{channels:3,labels:"rgb"},hsl:{channels:3,labels:"hsl"},hsv:{channels:3,labels:"hsv"},hwb:{channels:3,labels:"hwb"},cmyk:{channels:4,labels:"cmyk"},xyz:{channels:3,labels:"xyz"},lab:{channels:3,labels:"lab"},lch:{channels:3,labels:"lch"},hex:{channels:1,labels:["hex"]},keyword:{channels:1,labels:["keyword"]},ansi16:{channels:1,labels:["ansi16"]},ansi256:{channels:1,labels:["ansi256"]},hcg:{channels:3,labels:["h","c","g"]},apple:{channels:3,labels:["r16","g16","b16"]},gray:{channels:1,labels:["gray"]}};var conversions=convert$1;for(var _c=0,_d=Object.keys(convert$1);_c<_d.length;_c++){var model=_d[_c];if(!("channels"in convert$1[model])){throw new Error("missing channels property: "+model)}if(!("labels"in convert$1[model])){throw new Error("missing channel labels property: "+model)}if(convert$1[model].labels.length!==convert$1[model].channels){throw new Error("channel and label counts mismatch: "+model)}var _e=convert$1[model],channels=_e.channels,labels=_e.labels;delete convert$1[model].channels;delete convert$1[model].labels;Object.defineProperty(convert$1[model],"channels",{value:channels});Object.defineProperty(convert$1[model],"labels",{value:labels})}convert$1.rgb.hsl=function(e){var r=e[0]/255;var t=e[1]/255;var a=e[2]/255;var n=Math.min(r,t,a);var o=Math.max(r,t,a);var i=o-n;var l;var s;if(o===n){l=0}else if(r===o){l=(t-a)/i}else if(t===o){l=2+(a-r)/i}else if(a===o){l=4+(r-t)/i}l=Math.min(l*60,360);if(l<0){l+=360}var c=(n+o)/2;if(o===n){s=0}else if(c<=.5){s=i/(o+n)}else{s=i/(2-o-n)}return[l,s*100,c*100]};convert$1.rgb.hsv=function(e){var r;var t;var a;var n;var o;var i=e[0]/255;var l=e[1]/255;var s=e[2]/255;var c=Math.max(i,l,s);var h=c-Math.min(i,l,s);var u=function(e){return(c-e)/6/h+1/2};if(h===0){n=0;o=0}else{o=h/c;r=u(i);t=u(l);a=u(s);if(i===c){n=a-t}else if(l===c){n=1/3+r-a}else if(s===c){n=2/3+t-r}if(n<0){n+=1}else if(n>1){n-=1}}return[n*360,o*100,c*100]};convert$1.rgb.hwb=function(e){var r=e[0];var t=e[1];var a=e[2];var n=convert$1.rgb.hsl(e)[0];var o=1/255*Math.min(r,Math.min(t,a));a=1-1/255*Math.max(r,Math.max(t,a));return[n,o*100,a*100]};convert$1.rgb.cmyk=function(e){var r=e[0]/255;var t=e[1]/255;var a=e[2]/255;var n=Math.min(1-r,1-t,1-a);var o=(1-r-n)/(1-n)||0;var i=(1-t-n)/(1-n)||0;var l=(1-a-n)/(1-n)||0;return[o*100,i*100,l*100,n*100]};function comparativeDistance(e,r){return Math.pow(e[0]-r[0],2)+Math.pow(e[1]-r[1],2)+Math.pow(e[2]-r[2],2)}convert$1.rgb.keyword=function(e){var r=reverseKeywords[e];if(r){return r}var t=Infinity;var a;for(var n=0,o=Object.keys(colorName);n<o.length;n++){var i=o[n];var l=colorName[i];var s=comparativeDistance(e,l);if(s<t){t=s;a=i}}return a};convert$1.keyword.rgb=function(e){return colorName[e]};convert$1.rgb.xyz=function(e){var r=e[0]/255;var t=e[1]/255;var a=e[2]/255;r=r>.04045?Math.pow((r+.055)/1.055,2.4):r/12.92;t=t>.04045?Math.pow((t+.055)/1.055,2.4):t/12.92;a=a>.04045?Math.pow((a+.055)/1.055,2.4):a/12.92;var n=r*.4124+t*.3576+a*.1805;var o=r*.2126+t*.7152+a*.0722;var i=r*.0193+t*.1192+a*.9505;return[n*100,o*100,i*100]};convert$1.rgb.lab=function(e){var r=convert$1.rgb.xyz(e);var t=r[0];var a=r[1];var n=r[2];t/=95.047;a/=100;n/=108.883;t=t>.008856?Math.pow(t,1/3):7.787*t+16/116;a=a>.008856?Math.pow(a,1/3):7.787*a+16/116;n=n>.008856?Math.pow(n,1/3):7.787*n+16/116;var o=116*a-16;var i=500*(t-a);var l=200*(a-n);return[o,i,l]};convert$1.hsl.rgb=function(e){var r=e[0]/360;var t=e[1]/100;var a=e[2]/100;var n;var o;var i;if(t===0){i=a*255;return[i,i,i]}if(a<.5){n=a*(1+t)}else{n=a+t-a*t}var l=2*a-n;var s=[0,0,0];for(var c=0;c<3;c++){o=r+1/3*-(c-1);if(o<0){o++}if(o>1){o--}if(6*o<1){i=l+(n-l)*6*o}else if(2*o<1){i=n}else if(3*o<2){i=l+(n-l)*(2/3-o)*6}else{i=l}s[c]=i*255}return s};convert$1.hsl.hsv=function(e){var r=e[0];var t=e[1]/100;var a=e[2]/100;var n=t;var o=Math.max(a,.01);a*=2;t*=a<=1?a:2-a;n*=o<=1?o:2-o;var i=(a+t)/2;var l=a===0?2*n/(o+n):2*t/(a+t);return[r,l*100,i*100]};convert$1.hsv.rgb=function(e){var r=e[0]/60;var t=e[1]/100;var a=e[2]/100;var n=Math.floor(r)%6;var o=r-Math.floor(r);var i=255*a*(1-t);var l=255*a*(1-t*o);var s=255*a*(1-t*(1-o));a*=255;switch(n){case 0:return[a,s,i];case 1:return[l,a,i];case 2:return[i,a,s];case 3:return[i,l,a];case 4:return[s,i,a];case 5:return[a,i,l]}};convert$1.hsv.hsl=function(e){var r=e[0];var t=e[1]/100;var a=e[2]/100;var n=Math.max(a,.01);var o;var i;i=(2-t)*a;var l=(2-t)*n;o=t*n;o/=l<=1?l:2-l;o=o||0;i/=2;return[r,o*100,i*100]};convert$1.hwb.rgb=function(e){var r=e[0]/360;var t=e[1]/100;var a=e[2]/100;var n=t+a;var o;if(n>1){t/=n;a/=n}var i=Math.floor(6*r);var l=1-a;o=6*r-i;if((i&1)!==0){o=1-o}var s=t+o*(l-t);var c;var h;var u;switch(i){default:case 6:case 0:c=l;h=s;u=t;break;case 1:c=s;h=l;u=t;break;case 2:c=t;h=l;u=s;break;case 3:c=t;h=s;u=l;break;case 4:c=s;h=t;u=l;break;case 5:c=l;h=t;u=s;break}return[c*255,h*255,u*255]};convert$1.cmyk.rgb=function(e){var r=e[0]/100;var t=e[1]/100;var a=e[2]/100;var n=e[3]/100;var o=1-Math.min(1,r*(1-n)+n);var i=1-Math.min(1,t*(1-n)+n);var l=1-Math.min(1,a*(1-n)+n);return[o*255,i*255,l*255]};convert$1.xyz.rgb=function(e){var r=e[0]/100;var t=e[1]/100;var a=e[2]/100;var n;var o;var i;n=r*3.2406+t*-1.5372+a*-.4986;o=r*-.9689+t*1.8758+a*.0415;i=r*.0557+t*-.204+a*1.057;n=n>.0031308?1.055*Math.pow(n,1/2.4)-.055:n*12.92;o=o>.0031308?1.055*Math.pow(o,1/2.4)-.055:o*12.92;i=i>.0031308?1.055*Math.pow(i,1/2.4)-.055:i*12.92;n=Math.min(Math.max(0,n),1);o=Math.min(Math.max(0,o),1);i=Math.min(Math.max(0,i),1);return[n*255,o*255,i*255]};convert$1.xyz.lab=function(e){var r=e[0];var t=e[1];var a=e[2];r/=95.047;t/=100;a/=108.883;r=r>.008856?Math.pow(r,1/3):7.787*r+16/116;t=t>.008856?Math.pow(t,1/3):7.787*t+16/116;a=a>.008856?Math.pow(a,1/3):7.787*a+16/116;var n=116*t-16;var o=500*(r-t);var i=200*(t-a);return[n,o,i]};convert$1.lab.xyz=function(e){var r=e[0];var t=e[1];var a=e[2];var n;var o;var i;o=(r+16)/116;n=t/500+o;i=o-a/200;var l=Math.pow(o,3);var s=Math.pow(n,3);var c=Math.pow(i,3);o=l>.008856?l:(o-16/116)/7.787;n=s>.008856?s:(n-16/116)/7.787;i=c>.008856?c:(i-16/116)/7.787;n*=95.047;o*=100;i*=108.883;return[n,o,i]};convert$1.lab.lch=function(e){var r=e[0];var t=e[1];var a=e[2];var n;var o=Math.atan2(a,t);n=o*360/2/Math.PI;if(n<0){n+=360}var i=Math.sqrt(t*t+a*a);return[r,i,n]};convert$1.lch.lab=function(e){var r=e[0];var t=e[1];var a=e[2];var n=a/360*2*Math.PI;var o=t*Math.cos(n);var i=t*Math.sin(n);return[r,o,i]};convert$1.rgb.ansi16=function(e,r){if(r===void 0){r=null}var t=e[0],a=e[1],n=e[2];var o=r===null?convert$1.rgb.hsv(e)[2]:r;o=Math.round(o/50);if(o===0){return 30}var i=30+(Math.round(n/255)<<2|Math.round(a/255)<<1|Math.round(t/255));if(o===2){i+=60}return i};convert$1.hsv.ansi16=function(e){return convert$1.rgb.ansi16(convert$1.hsv.rgb(e),e[2])};convert$1.rgb.ansi256=function(e){var r=e[0];var t=e[1];var a=e[2];if(r===t&&t===a){if(r<8){return 16}if(r>248){return 231}return Math.round((r-8)/247*24)+232}var n=16+36*Math.round(r/255*5)+6*Math.round(t/255*5)+Math.round(a/255*5);return n};convert$1.ansi16.rgb=function(e){var r=e%10;if(r===0||r===7){if(e>50){r+=3.5}r=r/10.5*255;return[r,r,r]}var t=(~~(e>50)+1)*.5;var a=(r&1)*t*255;var n=(r>>1&1)*t*255;var o=(r>>2&1)*t*255;return[a,n,o]};convert$1.ansi256.rgb=function(e){if(e>=232){var r=(e-232)*10+8;return[r,r,r]}e-=16;var t;var a=Math.floor(e/36)/5*255;var n=Math.floor((t=e%36)/6)/5*255;var o=t%6/5*255;return[a,n,o]};convert$1.rgb.hex=function(e){var r=((Math.round(e[0])&255)<<16)+((Math.round(e[1])&255)<<8)+(Math.round(e[2])&255);var t=r.toString(16).toUpperCase();return"000000".substring(t.length)+t};convert$1.hex.rgb=function(e){var r=e.toString(16).match(/[a-f0-9]{6}|[a-f0-9]{3}/i);if(!r){return[0,0,0]}var t=r[0];if(r[0].length===3){t=t.split("").map((function(e){return e+e})).join("")}var a=parseInt(t,16);var n=a>>16&255;var o=a>>8&255;var i=a&255;return[n,o,i]};convert$1.rgb.hcg=function(e){var r=e[0]/255;var t=e[1]/255;var a=e[2]/255;var n=Math.max(Math.max(r,t),a);var o=Math.min(Math.min(r,t),a);var i=n-o;var l;var s;if(i<1){l=o/(1-i)}else{l=0}if(i<=0){s=0}else if(n===r){s=(t-a)/i%6}else if(n===t){s=2+(a-r)/i}else{s=4+(r-t)/i}s/=6;s%=1;return[s*360,i*100,l*100]};convert$1.hsl.hcg=function(e){var r=e[1]/100;var t=e[2]/100;var a=t<.5?2*r*t:2*r*(1-t);var n=0;if(a<1){n=(t-.5*a)/(1-a)}return[e[0],a*100,n*100]};convert$1.hsv.hcg=function(e){var r=e[1]/100;var t=e[2]/100;var a=r*t;var n=0;if(a<1){n=(t-a)/(1-a)}return[e[0],a*100,n*100]};convert$1.hcg.rgb=function(e){var r=e[0]/360;var t=e[1]/100;var a=e[2]/100;if(t===0){return[a*255,a*255,a*255]}var n=[0,0,0];var o=r%1*6;var i=o%1;var l=1-i;var s=0;switch(Math.floor(o)){case 0:n[0]=1;n[1]=i;n[2]=0;break;case 1:n[0]=l;n[1]=1;n[2]=0;break;case 2:n[0]=0;n[1]=1;n[2]=i;break;case 3:n[0]=0;n[1]=l;n[2]=1;break;case 4:n[0]=i;n[1]=0;n[2]=1;break;default:n[0]=1;n[1]=0;n[2]=l}s=(1-t)*a;return[(t*n[0]+s)*255,(t*n[1]+s)*255,(t*n[2]+s)*255]};convert$1.hcg.hsv=function(e){var r=e[1]/100;var t=e[2]/100;var a=r+t*(1-r);var n=0;if(a>0){n=r/a}return[e[0],n*100,a*100]};convert$1.hcg.hsl=function(e){var r=e[1]/100;var t=e[2]/100;var a=t*(1-r)+.5*r;var n=0;if(a>0&&a<.5){n=r/(2*a)}else if(a>=.5&&a<1){n=r/(2*(1-a))}return[e[0],n*100,a*100]};convert$1.hcg.hwb=function(e){var r=e[1]/100;var t=e[2]/100;var a=r+t*(1-r);return[e[0],(a-r)*100,(1-a)*100]};convert$1.hwb.hcg=function(e){var r=e[1]/100;var t=e[2]/100;var a=1-t;var n=a-r;var o=0;if(n<1){o=(a-n)/(1-n)}return[e[0],n*100,o*100]};convert$1.apple.rgb=function(e){return[e[0]/65535*255,e[1]/65535*255,e[2]/65535*255]};convert$1.rgb.apple=function(e){return[e[0]/255*65535,e[1]/255*65535,e[2]/255*65535]};convert$1.gray.rgb=function(e){return[e[0]/100*255,e[0]/100*255,e[0]/100*255]};convert$1.gray.hsl=function(e){return[0,0,e[0]]};convert$1.gray.hsv=convert$1.gray.hsl;convert$1.gray.hwb=function(e){return[0,100,e[0]]};convert$1.gray.cmyk=function(e){return[0,0,0,e[0]]};convert$1.gray.lab=function(e){return[e[0],0,0]};convert$1.gray.hex=function(e){var r=Math.round(e[0]/100*255)&255;var t=(r<<16)+(r<<8)+r;var a=t.toString(16).toUpperCase();return"000000".substring(a.length)+a};convert$1.rgb.gray=function(e){var r=(e[0]+e[1]+e[2])/3;return[r/255*100]};function buildGraph(){var e={};var r=Object.keys(conversions);for(var t=r.length,a=0;a<t;a++){e[r[a]]={distance:-1,parent:null}}return e}function deriveBFS(e){var r=buildGraph();var t=[e];r[e].distance=0;while(t.length){var a=t.pop();var n=Object.keys(conversions[a]);for(var o=n.length,i=0;i<o;i++){var l=n[i];var s=r[l];if(s.distance===-1){s.distance=r[a].distance+1;s.parent=a;t.unshift(l)}}}return r}function link(e,r){return function(t){return r(e(t))}}function wrapConversion(e,r){var t=[r[e].parent,e];var a=conversions[r[e].parent][e];var n=r[e].parent;while(r[n].parent){t.unshift(r[n].parent);a=link(conversions[r[n].parent][n],a);n=r[n].parent}a.conversion=t;return a}var route=function(e){var r=deriveBFS(e);var t={};var a=Object.keys(r);for(var n=a.length,o=0;o<n;o++){var i=a[o];var l=r[i];if(l.parent===null){continue}t[i]=wrapConversion(i,r)}return t};var convert={};var models=Object.keys(conversions);function wrapRaw(e){var r=function(){var r=[];for(var t=0;t<arguments.length;t++){r[t]=arguments[t]}var a=r[0];if(a===undefined||a===null){return a}if(a.length>1){r=a}return e(r)};if("conversion"in e){r.conversion=e.conversion}return r}function wrapRounded(e){var r=function(){var r=[];for(var t=0;t<arguments.length;t++){r[t]=arguments[t]}var a=r[0];if(a===undefined||a===null){return a}if(a.length>1){r=a}var n=e(r);if(typeof n==="object"){for(var o=n.length,i=0;i<o;i++){n[i]=Math.round(n[i])}}return n};if("conversion"in e){r.conversion=e.conversion}return r}models.forEach((function(e){convert[e]={};Object.defineProperty(convert[e],"channels",{value:conversions[e].channels});Object.defineProperty(convert[e],"labels",{value:conversions[e].labels});var r=route(e);var t=Object.keys(r);t.forEach((function(t){var a=r[t];convert[e][t]=wrapRounded(a);convert[e][t].raw=wrapRaw(a)}))}));var colorConvert=convert;var _slice=[].slice;var skippedModels=["keyword","gray","hex"];var hashedModelKeys={};for(var _f=0,_g=Object.keys(colorConvert);_f<_g.length;_f++){var model=_g[_f];hashedModelKeys[_slice.call(colorConvert[model].labels).sort().join("")]=model}var limiters={};function Color(e,r){if(!(this instanceof Color)){return new Color(e,r)}if(r&&r in skippedModels){r=null}if(r&&!(r in colorConvert)){throw new Error("Unknown model: "+r)}var t;var a;if(e==null){this.model="rgb";this.color=[0,0,0];this.valpha=1}else if(e instanceof Color){this.model=e.model;this.color=e.color.slice();this.valpha=e.valpha}else if(typeof e==="string"){var n=colorString.get(e);if(n===null){throw new Error("Unable to parse color from string: "+e)}this.model=n.model;a=colorConvert[this.model].channels;this.color=n.value.slice(0,a);this.valpha=typeof n.value[a]==="number"?n.value[a]:1}else if(e.length>0){this.model=r||"rgb";a=colorConvert[this.model].channels;var o=_slice.call(e,0,a);this.color=zeroArray(o,a);this.valpha=typeof e[a]==="number"?e[a]:1}else if(typeof e==="number"){this.model="rgb";this.color=[e>>16&255,e>>8&255,e&255];this.valpha=1}else{this.valpha=1;var i=Object.keys(e);if("alpha"in e){i.splice(i.indexOf("alpha"),1);this.valpha=typeof e.alpha==="number"?e.alpha:0}var l=i.sort().join("");if(!(l in hashedModelKeys)){throw new Error("Unable to parse color from object: "+JSON.stringify(e))}this.model=hashedModelKeys[l];var s=colorConvert[this.model].labels;var c=[];for(t=0;t<s.length;t++){c.push(e[s[t]])}this.color=zeroArray(c)}if(limiters[this.model]){a=colorConvert[this.model].channels;for(t=0;t<a;t++){var h=limiters[this.model][t];if(h){this.color[t]=h(this.color[t])}}}this.valpha=Math.max(0,Math.min(1,this.valpha));if(Object.freeze){Object.freeze(this)}}Color.prototype={toString:function(){return this.string()},toJSON:function(){return this[this.model]()},string:function(e){var r=this.model in colorString.to?this:this.rgb();r=r.round(typeof e==="number"?e:1);var t=r.valpha===1?r.color:r.color.concat(this.valpha);return colorString.to[r.model](t)},percentString:function(e){var r=this.rgb().round(typeof e==="number"?e:1);var t=r.valpha===1?r.color:r.color.concat(this.valpha);return colorString.to.rgb.percent(t)},array:function(){return this.valpha===1?this.color.slice():this.color.concat(this.valpha)},object:function(){var e={};var r=colorConvert[this.model].channels;var t=colorConvert[this.model].labels;for(var a=0;a<r;a++){e[t[a]]=this.color[a]}if(this.valpha!==1){e.alpha=this.valpha}return e},unitArray:function(){var e=this.rgb().color;e[0]/=255;e[1]/=255;e[2]/=255;if(this.valpha!==1){e.push(this.valpha)}return e},unitObject:function(){var e=this.rgb().object();e.r/=255;e.g/=255;e.b/=255;if(this.valpha!==1){e.alpha=this.valpha}return e},round:function(e){e=Math.max(e||0,0);return new Color(this.color.map(roundToPlace(e)).concat(this.valpha),this.model)},alpha:function(e){if(arguments.length>0){return new Color(this.color.concat(Math.max(0,Math.min(1,e))),this.model)}return this.valpha},red:getset("rgb",0,maxfn(255)),green:getset("rgb",1,maxfn(255)),blue:getset("rgb",2,maxfn(255)),hue:getset(["hsl","hsv","hsl","hwb","hcg"],0,(function(e){return(e%360+360)%360})),saturationl:getset("hsl",1,maxfn(100)),lightness:getset("hsl",2,maxfn(100)),saturationv:getset("hsv",1,maxfn(100)),value:getset("hsv",2,maxfn(100)),chroma:getset("hcg",1,maxfn(100)),gray:getset("hcg",2,maxfn(100)),white:getset("hwb",1,maxfn(100)),wblack:getset("hwb",2,maxfn(100)),cyan:getset("cmyk",0,maxfn(100)),magenta:getset("cmyk",1,maxfn(100)),yellow:getset("cmyk",2,maxfn(100)),black:getset("cmyk",3,maxfn(100)),x:getset("xyz",0,maxfn(100)),y:getset("xyz",1,maxfn(100)),z:getset("xyz",2,maxfn(100)),l:getset("lab",0,maxfn(100)),a:getset("lab",1),b:getset("lab",2),keyword:function(e){if(arguments.length>0){return new Color(e)}return colorConvert[this.model].keyword(this.color)},hex:function(e){if(arguments.length>0){return new Color(e)}return colorString.to.hex(this.rgb().round().color)},rgbNumber:function(){var e=this.rgb().color;return(e[0]&255)<<16|(e[1]&255)<<8|e[2]&255},luminosity:function(){var e=this.rgb().color;var r=[];for(var t=0,a=e.entries();t<a.length;t++){var n=a[t],o=n[0],i=n[1];var l=i/255;r[o]=l<=.03928?l/12.92:Math.pow((l+.055)/1.055,2.4)}return.2126*r[0]+.7152*r[1]+.0722*r[2]},contrast:function(e){var r=this.luminosity();var t=e.luminosity();if(r>t){return(r+.05)/(t+.05)}return(t+.05)/(r+.05)},level:function(e){var r=this.contrast(e);if(r>=7.1){return"AAA"}return r>=4.5?"AA":""},isDark:function(){var e=this.rgb().color;var r=(e[0]*299+e[1]*587+e[2]*114)/1e3;return r<128},isLight:function(){return!this.isDark()},negate:function(){var e=this.rgb();for(var r=0;r<3;r++){e.color[r]=255-e.color[r]}return e},lighten:function(e){var r=this.hsl();r.color[2]+=r.color[2]*e;return r},darken:function(e){var r=this.hsl();r.color[2]-=r.color[2]*e;return r},saturate:function(e){var r=this.hsl();r.color[1]+=r.color[1]*e;return r},desaturate:function(e){var r=this.hsl();r.color[1]-=r.color[1]*e;return r},whiten:function(e){var r=this.hwb();r.color[1]+=r.color[1]*e;return r},blacken:function(e){var r=this.hwb();r.color[2]+=r.color[2]*e;return r},grayscale:function(){var e=this.rgb().color;var r=e[0]*.3+e[1]*.59+e[2]*.11;return Color.rgb(r,r,r)},fade:function(e){return this.alpha(this.valpha-this.valpha*e)},opaquer:function(e){return this.alpha(this.valpha+this.valpha*e)},rotate:function(e){var r=this.hsl();var t=r.color[0];t=(t+e)%360;t=t<0?360+t:t;r.color[0]=t;return r},mix:function(e,r){if(!e||!e.rgb){throw new Error('Argument to "mix" was not a Color instance, but rather an instance of '+typeof e)}var t=e.rgb();var a=this.rgb();var n=r===undefined?.5:r;var o=2*n-1;var i=t.alpha()-a.alpha();var l=((o*i===-1?o:(o+i)/(1+o*i))+1)/2;var s=1-l;return Color.rgb(l*t.red()+s*a.red(),l*t.green()+s*a.green(),l*t.blue()+s*a.blue(),t.alpha()*n+a.alpha()*(1-n))}};var _loop_1=function(e){if(skippedModels.includes(e)){return"continue"}var r=colorConvert[e].channels;Color.prototype[e]=function(){if(this.model===e){return new Color(this)}if(arguments.length>0){return new Color(arguments,e)}var t=typeof arguments[r]==="number"?r:this.valpha;return new Color(assertArray(colorConvert[this.model][e].raw(this.color)).concat(t),e)};Color[e]=function(t){if(typeof t==="number"){t=zeroArray(_slice.call(arguments),r)}return new Color(t,e)}};for(var _h=0,_j=Object.keys(colorConvert);_h<_j.length;_h++){var model=_j[_h];_loop_1(model)}function roundTo(e,r){return Number(e.toFixed(r))}function roundToPlace(e){return function(r){return roundTo(r,e)}}function getset(e,r,t){e=Array.isArray(e)?e:[e];for(var a=0,n=e;a<n.length;a++){var o=n[a];(limiters[o]||(limiters[o]=[]))[r]=t}e=e[0];return function(a){var n;if(arguments.length>0){if(t){a=t(a)}n=this[e]();n.color[r]=a;return n}n=this[e]().color[r];if(t){n=t(n)}return n}}function maxfn(e){return function(r){return Math.max(0,Math.min(e,r))}}function assertArray(e){return Array.isArray(e)?e:[e]}function zeroArray(e,r){for(var t=0;t<r;t++){if(typeof e[t]!=="number"){e[t]=0}}return e}var color=Color;var CSS$2={container:"container",controlSection:"control-section",hexOptions:"color-hex-options",section:"section",header:"header",control:"control",splitSection:"section--split",colorModeContainer:"color-mode-container",colorMode:"color-mode",channels:"channels",channel:"channel",savedColors:"saved-colors",savedColorsSection:"saved-colors-section",saveColor:"save-color",deleteColor:"delete-color",savedColorsButtons:"saved-colors-buttons",headerHex:"header--hex",colorFieldAndSlider:"color-field-and-slider",colorFieldAndSliderInteractive:"color-field-and-slider--interactive",colorFieldAndSliderWrap:"color-field-and-slider-wrap",scope:"scope",hueScope:"scope--hue",colorFieldScope:"scope--color-field",savedColor:"saved-color"};var DEFAULT_COLOR$1=color("#007AC2");var DEFAULT_STORAGE_KEY_PREFIX="calcite-color-";var RGB_LIMITS={r:255,g:255,b:255};var HSV_LIMITS={h:360,s:100,v:100};var TEXT={b:"B",blue:"Blue",deleteColor:"Delete color",g:"G",green:"Green",h:"H",hsv:"HSV",hex:"Hex",hue:"Hue",noColor:"No color",r:"R",red:"Red",rgb:"RGB",s:"S",saturation:"Saturation",saveColor:"Save color",saved:"Saved",v:"V",value:"Value"};var DIMENSIONS={s:{slider:{height:10,width:160},colorField:{height:80,width:160},thumb:{radius:8}},m:{slider:{height:14,width:272},colorField:{height:150,width:272},thumb:{radius:10}},l:{slider:{height:16,width:464},colorField:{height:200,width:464},thumb:{radius:12}}};var calciteColorPickerCss="@-webkit-keyframes in{0%{opacity:0}100%{opacity:1}}@keyframes in{0%{opacity:0}100%{opacity:1}}@-webkit-keyframes in-down{0%{opacity:0;-webkit-transform:translate3D(0, -5px, 0);transform:translate3D(0, -5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@keyframes in-down{0%{opacity:0;-webkit-transform:translate3D(0, -5px, 0);transform:translate3D(0, -5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@-webkit-keyframes in-up{0%{opacity:0;-webkit-transform:translate3D(0, 5px, 0);transform:translate3D(0, 5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@keyframes in-up{0%{opacity:0;-webkit-transform:translate3D(0, 5px, 0);transform:translate3D(0, 5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@-webkit-keyframes in-scale{0%{opacity:0;-webkit-transform:scale3D(0.95, 0.95, 1);transform:scale3D(0.95, 0.95, 1)}100%{opacity:1;-webkit-transform:scale3D(1, 1, 1);transform:scale3D(1, 1, 1)}}@keyframes in-scale{0%{opacity:0;-webkit-transform:scale3D(0.95, 0.95, 1);transform:scale3D(0.95, 0.95, 1)}100%{opacity:1;-webkit-transform:scale3D(1, 1, 1);transform:scale3D(1, 1, 1)}}:root{--calcite-animation-timing:calc(150ms * var(--calcite-internal-duration-factor));--calcite-internal-duration-factor:var(--calcite-duration-factor, 1);--calcite-internal-animation-timing-fast:calc(100ms * var(--calcite-internal-duration-factor));--calcite-internal-animation-timing-medium:calc(200ms * var(--calcite-internal-duration-factor));--calcite-internal-animation-timing-slow:calc(300ms * var(--calcite-internal-duration-factor))}.calcite-animate{opacity:0;-webkit-animation-fill-mode:both;animation-fill-mode:both;-webkit-animation-duration:var(--calcite-animation-timing);animation-duration:var(--calcite-animation-timing)}.calcite-animate__in{-webkit-animation-name:in;animation-name:in}.calcite-animate__in-down{-webkit-animation-name:in-down;animation-name:in-down}.calcite-animate__in-up{-webkit-animation-name:in-up;animation-name:in-up}.calcite-animate__in-scale{-webkit-animation-name:in-scale;animation-name:in-scale}:root{--calcite-popper-transition:150ms ease-in-out}:host([hidden]){display:none}:host{display:inline-block;font-size:var(--calcite-font-size--2);line-height:1rem;font-weight:var(--calcite-font-weight-normal)}:host([scale=s]) .container{width:160px}:host([scale=s]) .saved-colors{grid-template-columns:repeat(auto-fill, minmax(20px, 1fr))}:host([scale=s]) .channels{-ms-flex-direction:column;flex-direction:column}:host([scale=s]) .channel{width:100%;margin-bottom:4px}:host([scale=s]) .channel:last-child{margin-bottom:0}:host([scale=m]) .container{width:272px}:host([scale=l]) .header{padding-bottom:0}:host([scale=l]){font-size:var(--calcite-font-size--1);line-height:1rem}:host([scale=l]) .container{width:464px}:host([scale=l]) .color-field-and-slider{margin-bottom:-20px}:host([scale=l]) .section{padding:0 16px 16px}:host([scale=l]) .section:first-of-type{padding-top:16px}:host([scale=l]) .saved-colors{grid-template-columns:repeat(auto-fill, minmax(28px, 1fr));grid-gap:12px;padding-top:16px}:host([scale=l]) .control-section{-ms-flex-wrap:nowrap;flex-wrap:nowrap;-ms-flex-align:baseline;align-items:baseline}:host([scale=l]) .control-section>:nth-child(2){-webkit-margin-start:12px;margin-inline-start:12px}:host([scale=l]) .color-hex-options{-ms-flex-negative:1;flex-shrink:1;display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;-ms-flex-pack:distribute;justify-content:space-around;min-height:98px;width:160px}:host([scale=l]) .color-mode-container{-ms-flex-negative:3;flex-shrink:3}:host([appearance=minimal]) .container{border:none}.container{background-color:var(--calcite-ui-foreground-1);display:inline-block;border:1px solid var(--calcite-ui-border-1)}.color-field-and-slider-wrap{position:relative}.scope{font-size:var(--calcite-font-size--1);padding:0;margin-bottom:0;margin-right:0;outline-offset:0;outline-color:transparent;-webkit-transition:outline-offset 100ms ease-in-out, outline-color 100ms ease-in-out;transition:outline-offset 100ms ease-in-out, outline-color 100ms ease-in-out;width:0.5rem;height:0.5rem;position:absolute;pointer-events:none;margin-top:-0.25rem;margin-left:-0.25rem;outline-offset:10px}.scope:focus{outline:2px solid var(--calcite-ui-brand);outline-offset:2px;outline-offset:12px}.color-field-and-slider{margin-bottom:-16px}.color-field-and-slider--interactive{cursor:pointer}.control-section{display:-ms-flexbox;display:flex;-ms-flex-direction:row;flex-direction:row;-ms-flex-wrap:wrap;flex-wrap:wrap}.section{padding:0 12px 12px}.section:first-of-type{padding-top:12px}.color-hex-options,.section--split{-ms-flex-positive:1;flex-grow:1}.header{display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;-ms-flex-pack:justify;justify-content:space-between;color:var(--calcite-ui-text-1);padding-bottom:0.25rem}.header--hex,.color-mode-container{padding-top:12px}.channels{display:-ms-flexbox;display:flex;-ms-flex-pack:justify;justify-content:space-between}.channel{width:31%}.saved-colors{padding-top:12px;display:grid;grid-template-columns:repeat(auto-fill, minmax(24px, 1fr));grid-gap:8px;width:100%}.saved-colors-buttons{display:-ms-flexbox;display:flex}.saved-color{outline-offset:0;outline-color:transparent;-webkit-transition:outline-offset 100ms ease-in-out, outline-color 100ms ease-in-out;transition:outline-offset 100ms ease-in-out, outline-color 100ms ease-in-out;cursor:pointer}.saved-color:focus{outline:2px solid var(--calcite-ui-brand);outline-offset:2px}.saved-color:hover{-webkit-transition:outline-color var(--calcite-internal-animation-timing-fast) ease-in-out;transition:outline-color var(--calcite-internal-animation-timing-fast) ease-in-out;outline:2px solid var(--calcite-ui-border-2);outline-offset:2px}";var throttleFor60FpsInMs=16;var defaultValue=normalizeHex(DEFAULT_COLOR$1.hex());var defaultFormat="auto";var CalciteColorPicker=function(){function e(e){var r=this;registerInstance(this,e);this.calciteColorPickerChange=createEvent(this,"calciteColorPickerChange",7);this.calciteColorPickerInput=createEvent(this,"calciteColorPickerInput",7);this.allowEmpty=false;this.appearance="default";this.color=DEFAULT_COLOR$1;this.format=defaultFormat;this.hideHex=false;this.hideChannels=false;this.hideSaved=false;this.intlB=TEXT.b;this.intlBlue=TEXT.blue;this.intlDeleteColor=TEXT.deleteColor;this.intlG=TEXT.g;this.intlGreen=TEXT.green;this.intlH=TEXT.h;this.intlHsv=TEXT.hsv;this.intlHex=TEXT.hex;this.intlHue=TEXT.hue;this.intlNoColor=TEXT.noColor;this.intlR=TEXT.r;this.intlRed=TEXT.red;this.intlRgb=TEXT.rgb;this.intlS=TEXT.s;this.intlSaturation=TEXT.saturation;this.intlSaveColor=TEXT.saveColor;this.intlSaved=TEXT.saved;this.intlV=TEXT.v;this.intlValue=TEXT.value;this.scale="m";this.value=defaultValue;this.colorFieldAndSliderHovered=false;this.hueThumbState="idle";this.internalColorUpdateContext=null;this.mode=CSSColorMode.HEX;this.shiftKeyChannelAdjustment=0;this.sliderThumbState="idle";this.colorFieldAndSliderInteractive=false;this.channelMode="rgb";this.channels=this.toChannels(DEFAULT_COLOR$1);this.dimensions=DIMENSIONS.m;this.savedColors=[];this.handleTabActivate=function(e){r.channelMode=e.currentTarget.getAttribute("data-color-mode");r.updateChannelsFromColor(r.color)};this.handleColorFieldScopeKeyDown=function(e){var t=e.key;var a={ArrowUp:{x:0,y:-10},ArrowRight:{x:10,y:0},ArrowDown:{x:0,y:10},ArrowLeft:{x:-10,y:0}};if(a[t]){e.preventDefault();r.scopeOrientation=t==="ArrowDown"||t==="ArrowUp"?"vertical":"horizontal";r.captureColorFieldColor(r.colorFieldScopeLeft+a[t].x||0,r.colorFieldScopeTop+a[t].y||0,false)}};this.handleHueScopeKeyDown=function(e){var t=e.shiftKey?10:1;var a=e.key;var n={ArrowUp:1,ArrowRight:1,ArrowDown:-1,ArrowLeft:-1};if(n[a]){e.preventDefault();var o=n[a]*t;var i=r.baseColorFieldColor.hue();var l=r.baseColorFieldColor.hue(i+o);r.internalColorSet(l,false)}};this.handleHexInputChange=function(e){e.stopPropagation();var t=r,a=t.allowEmpty,n=t.color;var o=e.target;var i=o.value;if(a&&!i){r.internalColorSet(null);return}var l=n&&normalizeHex(n.hex());if(i!==l){r.internalColorSet(color(i))}};this.handleSavedColorSelect=function(e){var t=e.currentTarget;r.internalColorSet(color(t.color))};this.handleChannelInput=function(e){var t=e.currentTarget;var a=e.detail.nativeEvent.target;var n=Number(t.getAttribute("data-channel-index"));var o=r.channelMode==="rgb"?RGB_LIMITS[Object.keys(RGB_LIMITS)[n]]:HSV_LIMITS[Object.keys(HSV_LIMITS)[n]];var i;if(r.allowEmpty&&!t.value){i=""}else{var l=Number(t.value)+r.shiftKeyChannelAdjustment;var s=clamp(l,0,o);i=s.toString()}t.value=i;a.value=i};this.handleChannelChange=function(e){var t=e.currentTarget;var a=Number(t.getAttribute("data-channel-index"));var n=__spreadArray([],r.channels);var o=r.allowEmpty&&!t.value;if(o){r.channels=[null,null,null];r.internalColorSet(null);return}n[a]=Number(t.value);r.updateColorFromChannels(n)};this.handleSavedColorKeyDown=function(e){if(e.key===" "||e.key==="Enter"){e.preventDefault();e.stopPropagation();r.handleSavedColorSelect(e)}};this.handleColorFieldAndSliderMouseLeave=function(){r.colorFieldAndSliderInteractive=false;r.colorFieldAndSliderHovered=false;if(r.sliderThumbState!=="drag"&&r.hueThumbState!=="drag"){r.hueThumbState="idle";r.sliderThumbState="idle";r.drawColorFieldAndSlider()}};this.handleColorFieldAndSliderMouseDown=function(e){var t=e.offsetX,a=e.offsetY;var n=r.getCanvasRegion(a);if(n==="color-field"){r.hueThumbState="drag";r.captureColorFieldColor(t,a)}else if(n==="slider"){r.sliderThumbState="drag";r.captureHueSliderColor(t)}e.preventDefault();document.addEventListener("mousemove",r.globalMouseMoveHandler);document.addEventListener("mouseup",r.globalMouseUpHandler,{once:true});r.activeColorFieldAndSliderRect=r.fieldAndSliderRenderingContext.canvas.getBoundingClientRect()};this.globalMouseUpHandler=function(){var e=r.sliderThumbState==="drag"||r.hueThumbState==="drag";r.hueThumbState="idle";r.sliderThumbState="idle";r.activeColorFieldAndSliderRect=null;r.drawColorFieldAndSlider();if(e){r.calciteColorPickerChange.emit()}};this.globalMouseMoveHandler=function(e){var t=r,a=t.el,n=t.dimensions;var o=r.sliderThumbState==="drag";var i=r.hueThumbState==="drag";if(!a.isConnected||!o&&!i){return}var l;var s;var c=r.activeColorFieldAndSliderRect;var h=e.clientX,u=e.clientY;if(r.colorFieldAndSliderHovered){l=h-c.x;s=u-c.y}else{var d=n.colorField.width;var v=n.colorField.height;var f=n.slider.height;if(h<c.x+d&&h>c.x){l=h-c.x}else if(h<c.x){l=0}else{l=d}if(u<c.y+v+f&&u>c.y){s=u-c.y}else if(u<c.y){s=0}else{s=v+f}}if(i){r.captureColorFieldColor(l,s,false)}else{r.captureHueSliderColor(l)}};this.handleColorFieldAndSliderMouseEnterOrMove=function(e){var t=e.offsetX,a=e.offsetY;var n=r.dimensions,o=n.colorField,i=n.slider,l=n.thumb;r.colorFieldAndSliderInteractive=a<=o.height+i.height;r.colorFieldAndSliderHovered=true;var s=r.getCanvasRegion(a);if(s==="color-field"){var c=r.hueThumbState;var h=r.baseColorFieldColor.hsv();var u=Math.round(h.saturationv()/(HSV_LIMITS.s/o.width));var d=Math.round(o.height-h.value()/(HSV_LIMITS.v/o.height));var v=r.containsPoint(t,a,u,d,l.radius);var f=false;if(c==="idle"&&v){r.hueThumbState="hover";f=true}else if(c==="hover"&&!v){r.hueThumbState="idle";f=true}if(r.hueThumbState!=="drag"){if(f){r.drawColorFieldAndSlider()}}}else if(s==="slider"){var p=r.baseColorFieldColor.hsv().saturationv(100).value(100);var m=r.sliderThumbState;var g=Math.round(p.hue()/(360/i.width));var b=Math.round((i.height+r.getSliderCapSpacing())/2)+o.height;var y=r.containsPoint(t,a,g,b,l.radius);var w=false;if(m==="idle"&&y){r.sliderThumbState="hover";w=true}else if(m==="hover"&&!y){r.sliderThumbState="idle";w=true}if(r.sliderThumbState!=="drag"){if(w){r.drawColorFieldAndSlider()}}}};this.storeColorFieldScope=function(e){r.colorFieldScopeNode=e};this.renderChannelsTabTitle=function(e){var t=r,a=t.channelMode,n=t.intlRgb,o=t.intlHsv;var i=e===a;var l=e==="rgb"?n:o;return h("calcite-tab-title",{active:i,class:CSS$2.colorMode,"data-color-mode":e,key:e,onCalciteTabsActivate:r.handleTabActivate},l)};this.renderChannelsTab=function(e){var t=r,a=t.channelMode,n=t.channels,o=t.intlB,i=t.intlBlue,l=t.intlG,s=t.intlGreen,c=t.intlH,u=t.intlHue,d=t.intlR,v=t.intlRed,f=t.intlS,p=t.intlSaturation,m=t.intlV,g=t.intlValue;var b=e===a;var y=e==="rgb";var w=y?[d,l,o]:[c,f,m];var C=y?[v,s,i]:[u,p,g];return h("calcite-tab",{active:b,class:CSS$2.control,key:e},h("div",{class:CSS$2.channels},n.map((function(e,t){return r.renderChannel(e,t,w[t],C[t])}))))};this.renderChannel=function(e,t,a,n){return h("calcite-input",{class:CSS$2.channel,"data-channel-index":t,label:n,numberButtonType:"none",onCalciteInputChange:r.handleChannelChange,onCalciteInputInput:r.handleChannelInput,prefixText:a,scale:r.scale==="l"?"m":"s",type:"number",value:e===null||e===void 0?void 0:e.toString()})};this.deleteColor=function(){var e=r.color.hex();var t=r.savedColors.indexOf(e)>-1;if(!t){return}var a=r.savedColors.filter((function(r){return r!==e}));r.savedColors=a;var n=""+DEFAULT_STORAGE_KEY_PREFIX+r.storageId;if(r.storageId){localStorage.setItem(n,JSON.stringify(a))}};this.saveColor=function(){var e=r.color.hex();var t=r.savedColors.indexOf(e)>-1;if(t){return}var a=__spreadArray(__spreadArray([],r.savedColors),[e]);r.savedColors=a;var n=""+DEFAULT_STORAGE_KEY_PREFIX+r.storageId;if(r.storageId){localStorage.setItem(n,JSON.stringify(a))}};this.drawColorFieldAndSlider=throttle((function(){if(!r.fieldAndSliderRenderingContext){return}r.drawColorField();r.drawHueSlider()}),throttleFor60FpsInMs);this.captureColorFieldColor=function(e,t,a){if(a===void 0){a=true}var n=r.dimensions.colorField,o=n.height,i=n.width;var l=Math.round(HSV_LIMITS.s/i*e);var s=Math.round(HSV_LIMITS.v/o*(o-t));r.internalColorSet(r.baseColorFieldColor.hsv().saturationv(l).value(s),a)};this.initColorFieldAndSlider=function(e){r.fieldAndSliderRenderingContext=e.getContext("2d");r.setCanvasContextSize(e,{width:r.dimensions.colorField.width,height:r.dimensions.colorField.height+r.dimensions.slider.height+r.getSliderCapSpacing()*2});r.drawColorFieldAndSlider()}}e.prototype.handleColorChange=function(e,r){this.drawColorFieldAndSlider();this.updateChannelsFromColor(e);this.previousColor=r;if(this.internalColorUpdateContext){return}this.value=this.toValue(e)};e.prototype.handleFormatChange=function(e){this.setMode(e);this.value=this.toValue(this.color)};e.prototype.handleScaleChange=function(e){if(e===void 0){e="m"}this.updateDimensions(e)};e.prototype.handleValueChange=function(e,r){var t=this,a=t.allowEmpty,n=t.format;var o=!a||e;var i=false;if(o){var l=parseMode(e);if(!l||n!=="auto"&&l!==n){this.showIncompatibleColorWarning(e,n);this.value=r;return}i=this.mode!==l;this.setMode(l)}var s=this.sliderThumbState==="drag"||this.hueThumbState==="drag";if(this.internalColorUpdateContext){if(this.internalColorUpdateContext==="initial"){return}this.calciteColorPickerInput.emit();if(!s){this.calciteColorPickerChange.emit()}return}var c=a&&!e?null:color(e);var h=!colorEqual(c,this.color);if(i||h){this.color=c;this.calciteColorPickerInput.emit();if(!s){this.calciteColorPickerChange.emit()}}};Object.defineProperty(e.prototype,"baseColorFieldColor",{get:function(){return this.color||this.previousColor||DEFAULT_COLOR$1},enumerable:false,configurable:true});e.prototype.handleChannelKeyUpOrDown=function(e){this.shiftKeyChannelAdjustment=0;var r=e.key;if(r!=="ArrowUp"&&r!=="ArrowDown"||!e.composedPath().some((function(e){var r;return(r=e.classList)===null||r===void 0?void 0:r.contains(CSS$2.channel)}))){return}var t=e.shiftKey;e.preventDefault();if(!this.color){this.internalColorSet(this.previousColor);e.stopPropagation();return}var a=9;this.shiftKeyChannelAdjustment=r==="ArrowUp"&&t?a:r==="ArrowDown"&&t?-a:0};e.prototype.setFocus=function(){return __awaiter(this,void 0,void 0,(function(){return __generator(this,(function(e){return[2,focusElement(this.colorFieldScopeNode)]}))}))};e.prototype.componentWillLoad=function(){var e=this,r=e.allowEmpty,t=e.color,a=e.format,n=e.value;var o=r&&!n;var i=parseMode(n);var l=o||a==="auto"&&i||a===i;var s=o?null:l?color(n):t;if(!l){this.showIncompatibleColorWarning(n,a)}this.setMode(a);this.internalColorSet(s,false,"initial");this.updateDimensions(this.scale);var c=""+DEFAULT_STORAGE_KEY_PREFIX+this.storageId;if(this.storageId&&localStorage.getItem(c)){this.savedColors=JSON.parse(localStorage.getItem(c))}};e.prototype.disconnectedCallback=function(){document.removeEventListener("mousemove",this.globalMouseMoveHandler);document.removeEventListener("mouseup",this.globalMouseUpHandler)};e.prototype.render=function(){var e,r,t,a,n,o,i;var l=this;var s=this,c=s.allowEmpty,u=s.color,d=s.intlDeleteColor,v=s.hideHex,f=s.hideChannels,p=s.hideSaved,m=s.intlHex,g=s.intlSaved,b=s.intlSaveColor,y=s.savedColors,w=s.scale;var C=u?u.hex():null;var S=w==="l"?"m":"s";var x=this,k=x.colorFieldAndSliderInteractive,M=x.colorFieldScopeTop,T=x.colorFieldScopeLeft,_=x.hueScopeLeft,F=x.hueScopeTop,D=x.scopeOrientation,A=x.dimensions,I=A.colorField,$=I.height,E=I.width,O=A.slider.height;var H=F!==null&&F!==void 0?F:O/2+$;var R=_!==null&&_!==void 0?_:E*DEFAULT_COLOR$1.hue()/HSV_LIMITS.h;var L=u===null;var j=D==="vertical";return h("div",{class:CSS$2.container},h("div",{class:CSS$2.colorFieldAndSliderWrap},h("canvas",{class:(e={},e[CSS$2.colorFieldAndSlider]=true,e[CSS$2.colorFieldAndSliderInteractive]=k,e),onMouseDown:this.handleColorFieldAndSliderMouseDown,onMouseEnter:this.handleColorFieldAndSliderMouseEnterOrMove,onMouseLeave:this.handleColorFieldAndSliderMouseLeave,onMouseMove:this.handleColorFieldAndSliderMouseEnterOrMove,ref:this.initColorFieldAndSlider}),h("div",{"aria-label":j?this.intlValue:this.intlSaturation,"aria-valuemax":j?HSV_LIMITS.v:HSV_LIMITS.s,"aria-valuemin":"0","aria-valuenow":(j?u===null||u===void 0?void 0:u.saturationv():u===null||u===void 0?void 0:u.value())||"0",class:(r={},r[CSS$2.scope]=true,r[CSS$2.colorFieldScope]=true,r),onKeyDown:this.handleColorFieldScopeKeyDown,ref:this.storeColorFieldScope,role:"slider",style:{top:(M||0)+"px",left:(T||0)+"px"},tabindex:"0"}),h("div",{"aria-label":this.intlHue,"aria-valuemax":HSV_LIMITS.h,"aria-valuemin":"0","aria-valuenow":(u===null||u===void 0?void 0:u.round().hue())||DEFAULT_COLOR$1.round().hue(),class:(t={},t[CSS$2.scope]=true,t[CSS$2.hueScope]=true,t),onKeyDown:this.handleHueScopeKeyDown,role:"slider",style:{top:H+"px",left:R+"px"},tabindex:"0"})),v&&f?null:h("div",{class:(a={},a[CSS$2.controlSection]=true,a[CSS$2.section]=true,a)},v?null:h("div",{class:CSS$2.hexOptions},h("span",{class:(n={},n[CSS$2.header]=true,n[CSS$2.headerHex]=true,n)},m),h("calcite-color-picker-hex-input",{allowEmpty:c,class:CSS$2.control,onCalciteColorPickerHexInputChange:this.handleHexInputChange,scale:S,value:C})),f?null:h("calcite-tabs",{class:(o={},o[CSS$2.colorModeContainer]=true,o[CSS$2.splitSection]=true,o),scale:S},h("calcite-tab-nav",{slot:"tab-nav"},this.renderChannelsTabTitle("rgb"),this.renderChannelsTabTitle("hsv")),this.renderChannelsTab("rgb"),this.renderChannelsTab("hsv"))),p?null:h("div",{class:(i={},i[CSS$2.savedColorsSection]=true,i[CSS$2.section]=true,i)},h("div",{class:CSS$2.header},h("label",null,g),h("div",{class:CSS$2.savedColorsButtons},h("calcite-button",{appearance:"transparent",class:CSS$2.deleteColor,color:"neutral",disabled:L,iconStart:"minus",label:d,onClick:this.deleteColor,scale:S}),h("calcite-button",{appearance:"transparent",class:CSS$2.saveColor,color:"neutral",disabled:L,iconStart:"plus",label:b,onClick:this.saveColor,scale:S}))),y.length>0?h("div",{class:CSS$2.savedColors},__spreadArray([],y.map((function(e){return h("calcite-color-picker-swatch",{active:C===e,class:CSS$2.savedColor,color:e,key:e,onClick:l.handleSavedColorSelect,onKeyDown:l.handleSavedColorKeyDown,scale:w,tabIndex:0})})))):null))};e.prototype.showIncompatibleColorWarning=function(e,r){console.warn("ignoring color value ("+e+") as it is not compatible with the current format ("+r+")")};e.prototype.setMode=function(e){this.mode=e==="auto"?this.mode:e};e.prototype.captureHueSliderColor=function(e){var r=this.dimensions.slider.width;var t=360/r*e;this.internalColorSet(this.baseColorFieldColor.hue(t),false)};e.prototype.getCanvasRegion=function(e){var r=this.dimensions,t=r.colorField.height,a=r.slider.height;if(e<=t){return"color-field"}if(e<=t+a){return"slider"}return"none"};e.prototype.internalColorSet=function(e,r,t){if(r===void 0){r=true}if(t===void 0){t="internal"}if(r&&colorEqual(e,this.color)){return}this.internalColorUpdateContext=t;this.color=e;this.value=this.toValue(e);this.internalColorUpdateContext=null};e.prototype.toValue=function(e,r){if(r===void 0){r=this.mode}if(!e){return null}var t="hex";if(r.includes(t)){return normalizeHex(e.round()[t]())}if(r.includes("-css")){return e[r.replace("-css","").replace("a","")]().round().string()}var a=e[r]().round().object();if(r.endsWith("a")){a.a=a.alpha;delete a.alpha}return a};e.prototype.getSliderCapSpacing=function(){var e=this.dimensions,r=e.slider.height,t=e.thumb.radius;return t*2-r};e.prototype.updateDimensions=function(e){if(e===void 0){e="m"}this.dimensions=DIMENSIONS[e]};e.prototype.drawColorField=function(){var e=this.fieldAndSliderRenderingContext;var r=this.dimensions.colorField,t=r.height,a=r.width;e.fillStyle=this.baseColorFieldColor.hsv().saturationv(100).value(100).string();e.fillRect(0,0,a,t);var n=e.createLinearGradient(0,0,a,0);n.addColorStop(0,"rgba(255,255,255,1)");n.addColorStop(1,"rgba(255,255,255,0)");e.fillStyle=n;e.fillRect(0,0,a,t);var o=e.createLinearGradient(0,0,0,t);o.addColorStop(0,"rgba(0,0,0,0)");o.addColorStop(1,"rgba(0,0,0,1)");e.fillStyle=o;e.fillRect(0,0,a,t);this.drawActiveColorFieldColor()};e.prototype.setCanvasContextSize=function(e,r){var t=r.height,a=r.width;var n=window.devicePixelRatio||1;e.width=a*n;e.height=t*n;e.style.height=t+"px";e.style.width=a+"px";var o=e.getContext("2d");o.scale(n,n)};e.prototype.containsPoint=function(e,r,t,a,n){return Math.pow(e-t,2)+Math.pow(r-a,2)<=Math.pow(n,2)};e.prototype.drawActiveColorFieldColor=function(){var e=this;var r=this.color;if(!r){return}var t=r.hsv();var a=this.dimensions,n=a.colorField,o=n.height,i=n.width,l=a.thumb.radius;var s=t.saturationv()/(HSV_LIMITS.s/i);var c=o-t.value()/(HSV_LIMITS.v/o);requestAnimationFrame((function(){e.colorFieldScopeLeft=s;e.colorFieldScopeTop=c}));this.drawThumb(this.fieldAndSliderRenderingContext,l,s,c,t,this.hueThumbState)};e.prototype.drawThumb=function(e,r,t,a,n,o){var i=0;var l=2*Math.PI;e.beginPath();e.arc(t,a,r,i,l);e.shadowBlur=o==="hover"?32:16;e.shadowColor="rgba(0, 0, 0, "+(o==="drag"?.32:.16)+")";e.fillStyle="#fff";e.fill();e.beginPath();e.arc(t,a,r-3,i,l);e.shadowBlur=0;e.shadowColor="transparent";e.fillStyle=n.rgb().string();e.fill()};e.prototype.drawActiveHueSliderColor=function(){var e=this;var r=this.color;if(!r){return}var t=r.hsv().saturationv(100).value(100);var a=this.dimensions,n=a.colorField.height,o=a.slider,i=o.height,l=o.width,s=a.thumb.radius;var c=t.hue()/(360/l);var h=i/2+n;requestAnimationFrame((function(){e.hueScopeLeft=c;e.hueScopeTop=h}));this.drawThumb(this.fieldAndSliderRenderingContext,s,c,h,t,this.sliderThumbState)};e.prototype.drawHueSlider=function(){var e=this.fieldAndSliderRenderingContext;var r=this.dimensions,t=r.colorField.height,a=r.slider,n=a.height,o=a.width;var i=e.createLinearGradient(0,0,o,0);var l=["red","yellow","lime","cyan","blue","magenta","red"];var s=1/(l.length-1);var c=0;l.forEach((function(e){i.addColorStop(c,color(e).string());c+=s}));e.fillStyle=i;e.clearRect(0,t,o,n+this.getSliderCapSpacing()*2);e.fillRect(0,t,o,n);this.drawActiveHueSliderColor()};e.prototype.updateColorFromChannels=function(e){this.internalColorSet(color(e,this.channelMode))};e.prototype.updateChannelsFromColor=function(e){this.channels=e?this.toChannels(e):[null,null,null]};e.prototype.toChannels=function(e){var r=this.channelMode;return e[r]().array().map((function(e){return Math.floor(e)}))};Object.defineProperty(e.prototype,"el",{get:function(){return getElement(this)},enumerable:false,configurable:true});Object.defineProperty(e,"watchers",{get:function(){return{color:["handleColorChange"],format:["handleFormatChange"],scale:["handleScaleChange"],value:["handleValueChange"]}},enumerable:false,configurable:true});return e}();CalciteColorPicker.style=calciteColorPickerCss;var CSS$1={container:"container",preview:"preview",input:"input"};var calciteColorPickerHexInputCss="@-webkit-keyframes in{0%{opacity:0}100%{opacity:1}}@keyframes in{0%{opacity:0}100%{opacity:1}}@-webkit-keyframes in-down{0%{opacity:0;-webkit-transform:translate3D(0, -5px, 0);transform:translate3D(0, -5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@keyframes in-down{0%{opacity:0;-webkit-transform:translate3D(0, -5px, 0);transform:translate3D(0, -5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@-webkit-keyframes in-up{0%{opacity:0;-webkit-transform:translate3D(0, 5px, 0);transform:translate3D(0, 5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@keyframes in-up{0%{opacity:0;-webkit-transform:translate3D(0, 5px, 0);transform:translate3D(0, 5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@-webkit-keyframes in-scale{0%{opacity:0;-webkit-transform:scale3D(0.95, 0.95, 1);transform:scale3D(0.95, 0.95, 1)}100%{opacity:1;-webkit-transform:scale3D(1, 1, 1);transform:scale3D(1, 1, 1)}}@keyframes in-scale{0%{opacity:0;-webkit-transform:scale3D(0.95, 0.95, 1);transform:scale3D(0.95, 0.95, 1)}100%{opacity:1;-webkit-transform:scale3D(1, 1, 1);transform:scale3D(1, 1, 1)}}:root{--calcite-animation-timing:calc(150ms * var(--calcite-internal-duration-factor));--calcite-internal-duration-factor:var(--calcite-duration-factor, 1);--calcite-internal-animation-timing-fast:calc(100ms * var(--calcite-internal-duration-factor));--calcite-internal-animation-timing-medium:calc(200ms * var(--calcite-internal-duration-factor));--calcite-internal-animation-timing-slow:calc(300ms * var(--calcite-internal-duration-factor))}.calcite-animate{opacity:0;-webkit-animation-fill-mode:both;animation-fill-mode:both;-webkit-animation-duration:var(--calcite-animation-timing);animation-duration:var(--calcite-animation-timing)}.calcite-animate__in{-webkit-animation-name:in;animation-name:in}.calcite-animate__in-down{-webkit-animation-name:in-down;animation-name:in-down}.calcite-animate__in-up{-webkit-animation-name:in-up;animation-name:in-up}.calcite-animate__in-scale{-webkit-animation-name:in-scale;animation-name:in-scale}:root{--calcite-popper-transition:150ms ease-in-out}:host([hidden]){display:none}:host{display:block}.container{width:100%;display:inline-grid;-ms-flex-align:center;align-items:center;grid-template-columns:1fr auto}.preview{grid-column:2/3;display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;pointer-events:none;margin-top:0;margin-bottom:0;margin-left:0.25rem;margin-right:0.25rem;z-index:1}.preview,.input{grid-row:1}.input{grid-column:1/3;text-transform:uppercase;width:100%}";var DEFAULT_COLOR=color();var CalciteColorPickerHexInput=function(){function e(e){var r=this;registerInstance(this,e);this.calciteColorPickerHexInputChange=createEvent(this,"calciteColorPickerHexInputChange",7);this.allowEmpty=false;this.intlHex=TEXT.hex;this.intlNoColor=TEXT.noColor;this.scale="m";this.value=normalizeHex(DEFAULT_COLOR.hex());this.onCalciteInputBlur=function(){var e=r.inputNode;var t=e.value;var a="#"+t;var n=r.allowEmpty&&!t;if(n||isValidHex(a)&&isLonghandHex(a)){return}e.value=r.allowEmpty&&!r.internalColor?"":r.formatForInternalInput(rgbToHex(r.internalColor.object()))};this.onInputChange=function(){var e=r.inputNode.value;var t;if(e){var a=e;var n=hexToRGB("#"+a);if(!n){return}t=normalizeHex(a)}else if(r.allowEmpty){t=null}r.value=t;r.calciteColorPickerHexInputChange.emit()};this.internalColor=DEFAULT_COLOR;this.previousNonNullValue=this.value;this.storeInputRef=function(e){r.inputNode=e}}e.prototype.connectedCallback=function(){var e=this,r=e.allowEmpty,t=e.value;if(t){var a=normalizeHex(t);if(isValidHex(a)){this.internalColor=color(a);this.value=a}return}if(r){this.internalColor=null;this.value=null}};e.prototype.handleValueChange=function(e,r){if(e){var t=normalizeHex(e);if(isValidHex(t)){var a=this.internalColor;var n=!a||t!==normalizeHex(a.hex());this.internalColor=color(t);this.previousNonNullValue=t;this.value=t;if(n){this.calciteColorPickerHexInputChange.emit()}return}}else if(this.allowEmpty){this.internalColor=null;this.value=null;this.calciteColorPickerHexInputChange.emit();return}this.value=r};e.prototype.onInputKeyDown=function(e){var r=e.altKey,t=e.ctrlKey,a=e.metaKey,n=e.shiftKey;var o=this,i=o.internalColor,l=o.value;var s=e.key;if(s==="Tab"||s==="Enter"){this.onInputChange();return}var c=s==="ArrowDown"||s==="ArrowUp";if(c){if(!l){this.value=this.previousNonNullValue;e.preventDefault();return}var h=s==="ArrowUp"?1:-1;var u=n?10:1;this.value=normalizeHex(this.nudgeRGBChannels(i,u*h).hex());e.preventDefault();return}var d=r||t||a;var v=s.length===1;var f=hexChar.test(s);if(v&&!d&&!f){e.preventDefault()}};e.prototype.render=function(){var e=this,r=e.intlHex,t=e.value;var a=this.formatForInternalInput(t);return h("div",{class:CSS$1.container},h("calcite-input",{class:CSS$1.input,label:r,maxLength:6,onCalciteInputBlur:this.onCalciteInputBlur,onCalciteInputChange:this.onInputChange,prefixText:"#",ref:this.storeInputRef,scale:this.scale,value:a}),a?h("calcite-color-picker-swatch",{active:true,class:CSS$1.preview,color:"#"+a,scale:this.scale}):null)};e.prototype.setFocus=function(){return __awaiter(this,void 0,void 0,(function(){return __generator(this,(function(e){focusElement(this.inputNode);return[2]}))}))};e.prototype.formatForInternalInput=function(e){return e?e.replace("#",""):""};e.prototype.nudgeRGBChannels=function(e,r){return color.rgb(e.array().map((function(e){return e+r})))};Object.defineProperty(e.prototype,"el",{get:function(){return getElement(this)},enumerable:false,configurable:true});Object.defineProperty(e,"watchers",{get:function(){return{value:["handleValueChange"]}},enumerable:false,configurable:true});return e}();CalciteColorPickerHexInput.style=calciteColorPickerHexInputCss;var CSS={swatch:"swatch",noColorIcon:"no-color-icon"};var COLORS={borderLight:"rgba(0, 0, 0, 0.15)",borderDark:"rgba(255, 255, 255, 0.15)"};var calciteColorPickerSwatchCss="@-webkit-keyframes in{0%{opacity:0}100%{opacity:1}}@keyframes in{0%{opacity:0}100%{opacity:1}}@-webkit-keyframes in-down{0%{opacity:0;-webkit-transform:translate3D(0, -5px, 0);transform:translate3D(0, -5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@keyframes in-down{0%{opacity:0;-webkit-transform:translate3D(0, -5px, 0);transform:translate3D(0, -5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@-webkit-keyframes in-up{0%{opacity:0;-webkit-transform:translate3D(0, 5px, 0);transform:translate3D(0, 5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@keyframes in-up{0%{opacity:0;-webkit-transform:translate3D(0, 5px, 0);transform:translate3D(0, 5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@-webkit-keyframes in-scale{0%{opacity:0;-webkit-transform:scale3D(0.95, 0.95, 1);transform:scale3D(0.95, 0.95, 1)}100%{opacity:1;-webkit-transform:scale3D(1, 1, 1);transform:scale3D(1, 1, 1)}}@keyframes in-scale{0%{opacity:0;-webkit-transform:scale3D(0.95, 0.95, 1);transform:scale3D(0.95, 0.95, 1)}100%{opacity:1;-webkit-transform:scale3D(1, 1, 1);transform:scale3D(1, 1, 1)}}:root{--calcite-animation-timing:calc(150ms * var(--calcite-internal-duration-factor));--calcite-internal-duration-factor:var(--calcite-duration-factor, 1);--calcite-internal-animation-timing-fast:calc(100ms * var(--calcite-internal-duration-factor));--calcite-internal-animation-timing-medium:calc(200ms * var(--calcite-internal-duration-factor));--calcite-internal-animation-timing-slow:calc(300ms * var(--calcite-internal-duration-factor))}.calcite-animate{opacity:0;-webkit-animation-fill-mode:both;animation-fill-mode:both;-webkit-animation-duration:var(--calcite-animation-timing);animation-duration:var(--calcite-animation-timing)}.calcite-animate__in{-webkit-animation-name:in;animation-name:in}.calcite-animate__in-down{-webkit-animation-name:in-down;animation-name:in-down}.calcite-animate__in-up{-webkit-animation-name:in-up;animation-name:in-up}.calcite-animate__in-scale{-webkit-animation-name:in-scale;animation-name:in-scale}:root{--calcite-popper-transition:150ms ease-in-out}:host([hidden]){display:none}:host{display:-ms-inline-flexbox;display:inline-flex;position:relative}:host([scale=s]){height:1.25rem;width:1.25rem}:host([scale=m]){height:1.5rem;width:1.5rem}:host([scale=l]){height:2rem;width:2rem}.swatch{overflow:visible;height:inherit;width:inherit}.swatch rect{-webkit-transition-property:all;transition-property:all;-webkit-transition-duration:150ms;transition-duration:150ms;-webkit-transition-timing-function:cubic-bezier(0.4, 0, 0.2, 1);transition-timing-function:cubic-bezier(0.4, 0, 0.2, 1)}.no-color-icon{height:100%;width:100%;top:0;right:0;bottom:0;left:0;position:absolute}";var CalciteColorPickerSwatch=function(){function e(e){registerInstance(this,e);this.active=false;this.scale="m"}e.prototype.handleColorChange=function(e){this.internalColor=color(e)};e.prototype.componentWillLoad=function(){this.handleColorChange(this.color)};e.prototype.render=function(){var e=this,r=e.active,t=e.el,a=e.internalColor;var n=r?"100%":"0";var o=a.hex();var i=getThemeName(t);var l=i==="light"?COLORS.borderLight:COLORS.borderDark;return h("svg",{class:CSS.swatch,xmlns:"http://www.w3.org/2000/svg"},h("title",null,o),h("rect",{fill:o,height:"100%",id:"swatch",rx:n,stroke:l,"stroke-width":"2",style:{"clip-path":"inset(0 round "+n+")"},width:"100%"}))};Object.defineProperty(e.prototype,"el",{get:function(){return getElement(this)},enumerable:false,configurable:true});Object.defineProperty(e,"watchers",{get:function(){return{color:["handleColorChange"]}},enumerable:false,configurable:true});return e}();CalciteColorPickerSwatch.style=calciteColorPickerSwatchCss;export{CalciteColorPicker as calcite_color_picker,CalciteColorPickerHexInput as calcite_color_picker_hex_input,CalciteColorPickerSwatch as calcite_color_picker_swatch};
|
|
5
|
+
*/import{r as registerInstance,c as createEvent,h,g as getElement}from"./index-c4b90cce.js";import{f as focusElement,b as getThemeName}from"./dom-e7fa77b9.js";import{n as normalizeHex,C as CSSColorMode,p as parseMode,c as colorEqual,i as isValidHex,a as isLonghandHex,r as rgbToHex,h as hexToRGB,b as hexChar}from"./utils-6beb0662.js";import{c as clamp}from"./math-456207f5.js";import{d as debounce,i as isObject}from"./debounce-79648d42.js";import"./guid-196bd5ea.js";var FUNC_ERROR_TEXT="Expected a function";function throttle(e,r,t){var a=true,n=true;if(typeof e!="function"){throw new TypeError(FUNC_ERROR_TEXT)}if(isObject(t)){a="leading"in t?!!t.leading:a;n="trailing"in t?!!t.trailing:n}return debounce(e,r,{leading:a,maxWait:r,trailing:n})}function createCommonjsModule(e,r,t){return t={path:r,exports:{},require:function(e,r){return commonjsRequire()}},e(t,t.exports),t.exports}function commonjsRequire(){throw new Error("Dynamic requires are not currently supported by @rollup/plugin-commonjs")}var colorName$1={aliceblue:[240,248,255],antiquewhite:[250,235,215],aqua:[0,255,255],aquamarine:[127,255,212],azure:[240,255,255],beige:[245,245,220],bisque:[255,228,196],black:[0,0,0],blanchedalmond:[255,235,205],blue:[0,0,255],blueviolet:[138,43,226],brown:[165,42,42],burlywood:[222,184,135],cadetblue:[95,158,160],chartreuse:[127,255,0],chocolate:[210,105,30],coral:[255,127,80],cornflowerblue:[100,149,237],cornsilk:[255,248,220],crimson:[220,20,60],cyan:[0,255,255],darkblue:[0,0,139],darkcyan:[0,139,139],darkgoldenrod:[184,134,11],darkgray:[169,169,169],darkgreen:[0,100,0],darkgrey:[169,169,169],darkkhaki:[189,183,107],darkmagenta:[139,0,139],darkolivegreen:[85,107,47],darkorange:[255,140,0],darkorchid:[153,50,204],darkred:[139,0,0],darksalmon:[233,150,122],darkseagreen:[143,188,143],darkslateblue:[72,61,139],darkslategray:[47,79,79],darkslategrey:[47,79,79],darkturquoise:[0,206,209],darkviolet:[148,0,211],deeppink:[255,20,147],deepskyblue:[0,191,255],dimgray:[105,105,105],dimgrey:[105,105,105],dodgerblue:[30,144,255],firebrick:[178,34,34],floralwhite:[255,250,240],forestgreen:[34,139,34],fuchsia:[255,0,255],gainsboro:[220,220,220],ghostwhite:[248,248,255],gold:[255,215,0],goldenrod:[218,165,32],gray:[128,128,128],green:[0,128,0],greenyellow:[173,255,47],grey:[128,128,128],honeydew:[240,255,240],hotpink:[255,105,180],indianred:[205,92,92],indigo:[75,0,130],ivory:[255,255,240],khaki:[240,230,140],lavender:[230,230,250],lavenderblush:[255,240,245],lawngreen:[124,252,0],lemonchiffon:[255,250,205],lightblue:[173,216,230],lightcoral:[240,128,128],lightcyan:[224,255,255],lightgoldenrodyellow:[250,250,210],lightgray:[211,211,211],lightgreen:[144,238,144],lightgrey:[211,211,211],lightpink:[255,182,193],lightsalmon:[255,160,122],lightseagreen:[32,178,170],lightskyblue:[135,206,250],lightslategray:[119,136,153],lightslategrey:[119,136,153],lightsteelblue:[176,196,222],lightyellow:[255,255,224],lime:[0,255,0],limegreen:[50,205,50],linen:[250,240,230],magenta:[255,0,255],maroon:[128,0,0],mediumaquamarine:[102,205,170],mediumblue:[0,0,205],mediumorchid:[186,85,211],mediumpurple:[147,112,219],mediumseagreen:[60,179,113],mediumslateblue:[123,104,238],mediumspringgreen:[0,250,154],mediumturquoise:[72,209,204],mediumvioletred:[199,21,133],midnightblue:[25,25,112],mintcream:[245,255,250],mistyrose:[255,228,225],moccasin:[255,228,181],navajowhite:[255,222,173],navy:[0,0,128],oldlace:[253,245,230],olive:[128,128,0],olivedrab:[107,142,35],orange:[255,165,0],orangered:[255,69,0],orchid:[218,112,214],palegoldenrod:[238,232,170],palegreen:[152,251,152],paleturquoise:[175,238,238],palevioletred:[219,112,147],papayawhip:[255,239,213],peachpuff:[255,218,185],peru:[205,133,63],pink:[255,192,203],plum:[221,160,221],powderblue:[176,224,230],purple:[128,0,128],rebeccapurple:[102,51,153],red:[255,0,0],rosybrown:[188,143,143],royalblue:[65,105,225],saddlebrown:[139,69,19],salmon:[250,128,114],sandybrown:[244,164,96],seagreen:[46,139,87],seashell:[255,245,238],sienna:[160,82,45],silver:[192,192,192],skyblue:[135,206,235],slateblue:[106,90,205],slategray:[112,128,144],slategrey:[112,128,144],snow:[255,250,250],springgreen:[0,255,127],steelblue:[70,130,180],tan:[210,180,140],teal:[0,128,128],thistle:[216,191,216],tomato:[255,99,71],turquoise:[64,224,208],violet:[238,130,238],wheat:[245,222,179],white:[255,255,255],whitesmoke:[245,245,245],yellow:[255,255,0],yellowgreen:[154,205,50]};var isArrayish=function e(r){if(!r||typeof r==="string"){return false}return r instanceof Array||Array.isArray(r)||r.length>=0&&(r.splice instanceof Function||Object.getOwnPropertyDescriptor(r,r.length-1)&&r.constructor.name!=="String")};var simpleSwizzle=createCommonjsModule((function(e){var r=Array.prototype.concat;var t=Array.prototype.slice;var a=e.exports=function e(a){var n=[];for(var o=0,i=a.length;o<i;o++){var l=a[o];if(isArrayish(l)){n=r.call(n,t.call(l))}else{n.push(l)}}return n};a.wrap=function(e){return function(){return e(a(arguments))}}}));var colorString=createCommonjsModule((function(e){var r=Object.hasOwnProperty;var t={};for(var a in colorName$1){if(r.call(colorName$1,a)){t[colorName$1[a]]=a}}var n=e.exports={to:{},get:{}};n.get=function(e){var r=e.substring(0,3).toLowerCase();var t;var a;switch(r){case"hsl":t=n.get.hsl(e);a="hsl";break;case"hwb":t=n.get.hwb(e);a="hwb";break;default:t=n.get.rgb(e);a="rgb";break}if(!t){return null}return{model:a,value:t}};n.get.rgb=function(e){if(!e){return null}var t=/^#([a-f0-9]{3,4})$/i;var a=/^#([a-f0-9]{6})([a-f0-9]{2})?$/i;var n=/^rgba?\(\s*([+-]?\d+)(?=[\s,])\s*(?:,\s*)?([+-]?\d+)(?=[\s,])\s*(?:,\s*)?([+-]?\d+)\s*(?:[,|\/]\s*([+-]?[\d\.]+)(%?)\s*)?\)$/;var i=/^rgba?\(\s*([+-]?[\d\.]+)\%\s*,?\s*([+-]?[\d\.]+)\%\s*,?\s*([+-]?[\d\.]+)\%\s*(?:[,|\/]\s*([+-]?[\d\.]+)(%?)\s*)?\)$/;var l=/^(\w+)$/;var s=[0,0,0,1];var c;var h;var u;if(c=e.match(a)){u=c[2];c=c[1];for(h=0;h<3;h++){var d=h*2;s[h]=parseInt(c.slice(d,d+2),16)}if(u){s[3]=parseInt(u,16)/255}}else if(c=e.match(t)){c=c[1];u=c[3];for(h=0;h<3;h++){s[h]=parseInt(c[h]+c[h],16)}if(u){s[3]=parseInt(u+u,16)/255}}else if(c=e.match(n)){for(h=0;h<3;h++){s[h]=parseInt(c[h+1],0)}if(c[4]){if(c[5]){s[3]=parseFloat(c[4])*.01}else{s[3]=parseFloat(c[4])}}}else if(c=e.match(i)){for(h=0;h<3;h++){s[h]=Math.round(parseFloat(c[h+1])*2.55)}if(c[4]){if(c[5]){s[3]=parseFloat(c[4])*.01}else{s[3]=parseFloat(c[4])}}}else if(c=e.match(l)){if(c[1]==="transparent"){return[0,0,0,0]}if(!r.call(colorName$1,c[1])){return null}s=colorName$1[c[1]];s[3]=1;return s}else{return null}for(h=0;h<3;h++){s[h]=o(s[h],0,255)}s[3]=o(s[3],0,1);return s};n.get.hsl=function(e){if(!e){return null}var r=/^hsla?\(\s*([+-]?(?:\d{0,3}\.)?\d+)(?:deg)?\s*,?\s*([+-]?[\d\.]+)%\s*,?\s*([+-]?[\d\.]+)%\s*(?:[,|\/]\s*([+-]?(?=\.\d|\d)(?:0|[1-9]\d*)?(?:\.\d*)?(?:[eE][+-]?\d+)?)\s*)?\)$/;var t=e.match(r);if(t){var a=parseFloat(t[4]);var n=(parseFloat(t[1])%360+360)%360;var i=o(parseFloat(t[2]),0,100);var l=o(parseFloat(t[3]),0,100);var s=o(isNaN(a)?1:a,0,1);return[n,i,l,s]}return null};n.get.hwb=function(e){if(!e){return null}var r=/^hwb\(\s*([+-]?\d{0,3}(?:\.\d+)?)(?:deg)?\s*,\s*([+-]?[\d\.]+)%\s*,\s*([+-]?[\d\.]+)%\s*(?:,\s*([+-]?(?=\.\d|\d)(?:0|[1-9]\d*)?(?:\.\d*)?(?:[eE][+-]?\d+)?)\s*)?\)$/;var t=e.match(r);if(t){var a=parseFloat(t[4]);var n=(parseFloat(t[1])%360+360)%360;var i=o(parseFloat(t[2]),0,100);var l=o(parseFloat(t[3]),0,100);var s=o(isNaN(a)?1:a,0,1);return[n,i,l,s]}return null};n.to.hex=function(){var e=simpleSwizzle(arguments);return"#"+i(e[0])+i(e[1])+i(e[2])+(e[3]<1?i(Math.round(e[3]*255)):"")};n.to.rgb=function(){var e=simpleSwizzle(arguments);return e.length<4||e[3]===1?"rgb("+Math.round(e[0])+", "+Math.round(e[1])+", "+Math.round(e[2])+")":"rgba("+Math.round(e[0])+", "+Math.round(e[1])+", "+Math.round(e[2])+", "+e[3]+")"};n.to.rgb.percent=function(){var e=simpleSwizzle(arguments);var r=Math.round(e[0]/255*100);var t=Math.round(e[1]/255*100);var a=Math.round(e[2]/255*100);return e.length<4||e[3]===1?"rgb("+r+"%, "+t+"%, "+a+"%)":"rgba("+r+"%, "+t+"%, "+a+"%, "+e[3]+")"};n.to.hsl=function(){var e=simpleSwizzle(arguments);return e.length<4||e[3]===1?"hsl("+e[0]+", "+e[1]+"%, "+e[2]+"%)":"hsla("+e[0]+", "+e[1]+"%, "+e[2]+"%, "+e[3]+")"};n.to.hwb=function(){var e=simpleSwizzle(arguments);var r="";if(e.length>=4&&e[3]!==1){r=", "+e[3]}return"hwb("+e[0]+", "+e[1]+"%, "+e[2]+"%"+r+")"};n.to.keyword=function(e){return t[e.slice(0,3)]};function o(e,r,t){return Math.min(Math.max(r,e),t)}function i(e){var r=Math.round(e).toString(16).toUpperCase();return r.length<2?"0"+r:r}}));var colorName={aliceblue:[240,248,255],antiquewhite:[250,235,215],aqua:[0,255,255],aquamarine:[127,255,212],azure:[240,255,255],beige:[245,245,220],bisque:[255,228,196],black:[0,0,0],blanchedalmond:[255,235,205],blue:[0,0,255],blueviolet:[138,43,226],brown:[165,42,42],burlywood:[222,184,135],cadetblue:[95,158,160],chartreuse:[127,255,0],chocolate:[210,105,30],coral:[255,127,80],cornflowerblue:[100,149,237],cornsilk:[255,248,220],crimson:[220,20,60],cyan:[0,255,255],darkblue:[0,0,139],darkcyan:[0,139,139],darkgoldenrod:[184,134,11],darkgray:[169,169,169],darkgreen:[0,100,0],darkgrey:[169,169,169],darkkhaki:[189,183,107],darkmagenta:[139,0,139],darkolivegreen:[85,107,47],darkorange:[255,140,0],darkorchid:[153,50,204],darkred:[139,0,0],darksalmon:[233,150,122],darkseagreen:[143,188,143],darkslateblue:[72,61,139],darkslategray:[47,79,79],darkslategrey:[47,79,79],darkturquoise:[0,206,209],darkviolet:[148,0,211],deeppink:[255,20,147],deepskyblue:[0,191,255],dimgray:[105,105,105],dimgrey:[105,105,105],dodgerblue:[30,144,255],firebrick:[178,34,34],floralwhite:[255,250,240],forestgreen:[34,139,34],fuchsia:[255,0,255],gainsboro:[220,220,220],ghostwhite:[248,248,255],gold:[255,215,0],goldenrod:[218,165,32],gray:[128,128,128],green:[0,128,0],greenyellow:[173,255,47],grey:[128,128,128],honeydew:[240,255,240],hotpink:[255,105,180],indianred:[205,92,92],indigo:[75,0,130],ivory:[255,255,240],khaki:[240,230,140],lavender:[230,230,250],lavenderblush:[255,240,245],lawngreen:[124,252,0],lemonchiffon:[255,250,205],lightblue:[173,216,230],lightcoral:[240,128,128],lightcyan:[224,255,255],lightgoldenrodyellow:[250,250,210],lightgray:[211,211,211],lightgreen:[144,238,144],lightgrey:[211,211,211],lightpink:[255,182,193],lightsalmon:[255,160,122],lightseagreen:[32,178,170],lightskyblue:[135,206,250],lightslategray:[119,136,153],lightslategrey:[119,136,153],lightsteelblue:[176,196,222],lightyellow:[255,255,224],lime:[0,255,0],limegreen:[50,205,50],linen:[250,240,230],magenta:[255,0,255],maroon:[128,0,0],mediumaquamarine:[102,205,170],mediumblue:[0,0,205],mediumorchid:[186,85,211],mediumpurple:[147,112,219],mediumseagreen:[60,179,113],mediumslateblue:[123,104,238],mediumspringgreen:[0,250,154],mediumturquoise:[72,209,204],mediumvioletred:[199,21,133],midnightblue:[25,25,112],mintcream:[245,255,250],mistyrose:[255,228,225],moccasin:[255,228,181],navajowhite:[255,222,173],navy:[0,0,128],oldlace:[253,245,230],olive:[128,128,0],olivedrab:[107,142,35],orange:[255,165,0],orangered:[255,69,0],orchid:[218,112,214],palegoldenrod:[238,232,170],palegreen:[152,251,152],paleturquoise:[175,238,238],palevioletred:[219,112,147],papayawhip:[255,239,213],peachpuff:[255,218,185],peru:[205,133,63],pink:[255,192,203],plum:[221,160,221],powderblue:[176,224,230],purple:[128,0,128],rebeccapurple:[102,51,153],red:[255,0,0],rosybrown:[188,143,143],royalblue:[65,105,225],saddlebrown:[139,69,19],salmon:[250,128,114],sandybrown:[244,164,96],seagreen:[46,139,87],seashell:[255,245,238],sienna:[160,82,45],silver:[192,192,192],skyblue:[135,206,235],slateblue:[106,90,205],slategray:[112,128,144],slategrey:[112,128,144],snow:[255,250,250],springgreen:[0,255,127],steelblue:[70,130,180],tan:[210,180,140],teal:[0,128,128],thistle:[216,191,216],tomato:[255,99,71],turquoise:[64,224,208],violet:[238,130,238],wheat:[245,222,179],white:[255,255,255],whitesmoke:[245,245,245],yellow:[255,255,0],yellowgreen:[154,205,50]};var reverseKeywords={};for(var _i=0,_b=Object.keys(colorName);_i<_b.length;_i++){var key=_b[_i];reverseKeywords[colorName[key]]=key}var convert$1={rgb:{channels:3,labels:"rgb"},hsl:{channels:3,labels:"hsl"},hsv:{channels:3,labels:"hsv"},hwb:{channels:3,labels:"hwb"},cmyk:{channels:4,labels:"cmyk"},xyz:{channels:3,labels:"xyz"},lab:{channels:3,labels:"lab"},lch:{channels:3,labels:"lch"},hex:{channels:1,labels:["hex"]},keyword:{channels:1,labels:["keyword"]},ansi16:{channels:1,labels:["ansi16"]},ansi256:{channels:1,labels:["ansi256"]},hcg:{channels:3,labels:["h","c","g"]},apple:{channels:3,labels:["r16","g16","b16"]},gray:{channels:1,labels:["gray"]}};var conversions=convert$1;for(var _c=0,_d=Object.keys(convert$1);_c<_d.length;_c++){var model=_d[_c];if(!("channels"in convert$1[model])){throw new Error("missing channels property: "+model)}if(!("labels"in convert$1[model])){throw new Error("missing channel labels property: "+model)}if(convert$1[model].labels.length!==convert$1[model].channels){throw new Error("channel and label counts mismatch: "+model)}var _e=convert$1[model],channels=_e.channels,labels=_e.labels;delete convert$1[model].channels;delete convert$1[model].labels;Object.defineProperty(convert$1[model],"channels",{value:channels});Object.defineProperty(convert$1[model],"labels",{value:labels})}convert$1.rgb.hsl=function(e){var r=e[0]/255;var t=e[1]/255;var a=e[2]/255;var n=Math.min(r,t,a);var o=Math.max(r,t,a);var i=o-n;var l;var s;if(o===n){l=0}else if(r===o){l=(t-a)/i}else if(t===o){l=2+(a-r)/i}else if(a===o){l=4+(r-t)/i}l=Math.min(l*60,360);if(l<0){l+=360}var c=(n+o)/2;if(o===n){s=0}else if(c<=.5){s=i/(o+n)}else{s=i/(2-o-n)}return[l,s*100,c*100]};convert$1.rgb.hsv=function(e){var r;var t;var a;var n;var o;var i=e[0]/255;var l=e[1]/255;var s=e[2]/255;var c=Math.max(i,l,s);var h=c-Math.min(i,l,s);var u=function(e){return(c-e)/6/h+1/2};if(h===0){n=0;o=0}else{o=h/c;r=u(i);t=u(l);a=u(s);if(i===c){n=a-t}else if(l===c){n=1/3+r-a}else if(s===c){n=2/3+t-r}if(n<0){n+=1}else if(n>1){n-=1}}return[n*360,o*100,c*100]};convert$1.rgb.hwb=function(e){var r=e[0];var t=e[1];var a=e[2];var n=convert$1.rgb.hsl(e)[0];var o=1/255*Math.min(r,Math.min(t,a));a=1-1/255*Math.max(r,Math.max(t,a));return[n,o*100,a*100]};convert$1.rgb.cmyk=function(e){var r=e[0]/255;var t=e[1]/255;var a=e[2]/255;var n=Math.min(1-r,1-t,1-a);var o=(1-r-n)/(1-n)||0;var i=(1-t-n)/(1-n)||0;var l=(1-a-n)/(1-n)||0;return[o*100,i*100,l*100,n*100]};function comparativeDistance(e,r){return Math.pow(e[0]-r[0],2)+Math.pow(e[1]-r[1],2)+Math.pow(e[2]-r[2],2)}convert$1.rgb.keyword=function(e){var r=reverseKeywords[e];if(r){return r}var t=Infinity;var a;for(var n=0,o=Object.keys(colorName);n<o.length;n++){var i=o[n];var l=colorName[i];var s=comparativeDistance(e,l);if(s<t){t=s;a=i}}return a};convert$1.keyword.rgb=function(e){return colorName[e]};convert$1.rgb.xyz=function(e){var r=e[0]/255;var t=e[1]/255;var a=e[2]/255;r=r>.04045?Math.pow((r+.055)/1.055,2.4):r/12.92;t=t>.04045?Math.pow((t+.055)/1.055,2.4):t/12.92;a=a>.04045?Math.pow((a+.055)/1.055,2.4):a/12.92;var n=r*.4124+t*.3576+a*.1805;var o=r*.2126+t*.7152+a*.0722;var i=r*.0193+t*.1192+a*.9505;return[n*100,o*100,i*100]};convert$1.rgb.lab=function(e){var r=convert$1.rgb.xyz(e);var t=r[0];var a=r[1];var n=r[2];t/=95.047;a/=100;n/=108.883;t=t>.008856?Math.pow(t,1/3):7.787*t+16/116;a=a>.008856?Math.pow(a,1/3):7.787*a+16/116;n=n>.008856?Math.pow(n,1/3):7.787*n+16/116;var o=116*a-16;var i=500*(t-a);var l=200*(a-n);return[o,i,l]};convert$1.hsl.rgb=function(e){var r=e[0]/360;var t=e[1]/100;var a=e[2]/100;var n;var o;var i;if(t===0){i=a*255;return[i,i,i]}if(a<.5){n=a*(1+t)}else{n=a+t-a*t}var l=2*a-n;var s=[0,0,0];for(var c=0;c<3;c++){o=r+1/3*-(c-1);if(o<0){o++}if(o>1){o--}if(6*o<1){i=l+(n-l)*6*o}else if(2*o<1){i=n}else if(3*o<2){i=l+(n-l)*(2/3-o)*6}else{i=l}s[c]=i*255}return s};convert$1.hsl.hsv=function(e){var r=e[0];var t=e[1]/100;var a=e[2]/100;var n=t;var o=Math.max(a,.01);a*=2;t*=a<=1?a:2-a;n*=o<=1?o:2-o;var i=(a+t)/2;var l=a===0?2*n/(o+n):2*t/(a+t);return[r,l*100,i*100]};convert$1.hsv.rgb=function(e){var r=e[0]/60;var t=e[1]/100;var a=e[2]/100;var n=Math.floor(r)%6;var o=r-Math.floor(r);var i=255*a*(1-t);var l=255*a*(1-t*o);var s=255*a*(1-t*(1-o));a*=255;switch(n){case 0:return[a,s,i];case 1:return[l,a,i];case 2:return[i,a,s];case 3:return[i,l,a];case 4:return[s,i,a];case 5:return[a,i,l]}};convert$1.hsv.hsl=function(e){var r=e[0];var t=e[1]/100;var a=e[2]/100;var n=Math.max(a,.01);var o;var i;i=(2-t)*a;var l=(2-t)*n;o=t*n;o/=l<=1?l:2-l;o=o||0;i/=2;return[r,o*100,i*100]};convert$1.hwb.rgb=function(e){var r=e[0]/360;var t=e[1]/100;var a=e[2]/100;var n=t+a;var o;if(n>1){t/=n;a/=n}var i=Math.floor(6*r);var l=1-a;o=6*r-i;if((i&1)!==0){o=1-o}var s=t+o*(l-t);var c;var h;var u;switch(i){default:case 6:case 0:c=l;h=s;u=t;break;case 1:c=s;h=l;u=t;break;case 2:c=t;h=l;u=s;break;case 3:c=t;h=s;u=l;break;case 4:c=s;h=t;u=l;break;case 5:c=l;h=t;u=s;break}return[c*255,h*255,u*255]};convert$1.cmyk.rgb=function(e){var r=e[0]/100;var t=e[1]/100;var a=e[2]/100;var n=e[3]/100;var o=1-Math.min(1,r*(1-n)+n);var i=1-Math.min(1,t*(1-n)+n);var l=1-Math.min(1,a*(1-n)+n);return[o*255,i*255,l*255]};convert$1.xyz.rgb=function(e){var r=e[0]/100;var t=e[1]/100;var a=e[2]/100;var n;var o;var i;n=r*3.2406+t*-1.5372+a*-.4986;o=r*-.9689+t*1.8758+a*.0415;i=r*.0557+t*-.204+a*1.057;n=n>.0031308?1.055*Math.pow(n,1/2.4)-.055:n*12.92;o=o>.0031308?1.055*Math.pow(o,1/2.4)-.055:o*12.92;i=i>.0031308?1.055*Math.pow(i,1/2.4)-.055:i*12.92;n=Math.min(Math.max(0,n),1);o=Math.min(Math.max(0,o),1);i=Math.min(Math.max(0,i),1);return[n*255,o*255,i*255]};convert$1.xyz.lab=function(e){var r=e[0];var t=e[1];var a=e[2];r/=95.047;t/=100;a/=108.883;r=r>.008856?Math.pow(r,1/3):7.787*r+16/116;t=t>.008856?Math.pow(t,1/3):7.787*t+16/116;a=a>.008856?Math.pow(a,1/3):7.787*a+16/116;var n=116*t-16;var o=500*(r-t);var i=200*(t-a);return[n,o,i]};convert$1.lab.xyz=function(e){var r=e[0];var t=e[1];var a=e[2];var n;var o;var i;o=(r+16)/116;n=t/500+o;i=o-a/200;var l=Math.pow(o,3);var s=Math.pow(n,3);var c=Math.pow(i,3);o=l>.008856?l:(o-16/116)/7.787;n=s>.008856?s:(n-16/116)/7.787;i=c>.008856?c:(i-16/116)/7.787;n*=95.047;o*=100;i*=108.883;return[n,o,i]};convert$1.lab.lch=function(e){var r=e[0];var t=e[1];var a=e[2];var n;var o=Math.atan2(a,t);n=o*360/2/Math.PI;if(n<0){n+=360}var i=Math.sqrt(t*t+a*a);return[r,i,n]};convert$1.lch.lab=function(e){var r=e[0];var t=e[1];var a=e[2];var n=a/360*2*Math.PI;var o=t*Math.cos(n);var i=t*Math.sin(n);return[r,o,i]};convert$1.rgb.ansi16=function(e,r){if(r===void 0){r=null}var t=e[0],a=e[1],n=e[2];var o=r===null?convert$1.rgb.hsv(e)[2]:r;o=Math.round(o/50);if(o===0){return 30}var i=30+(Math.round(n/255)<<2|Math.round(a/255)<<1|Math.round(t/255));if(o===2){i+=60}return i};convert$1.hsv.ansi16=function(e){return convert$1.rgb.ansi16(convert$1.hsv.rgb(e),e[2])};convert$1.rgb.ansi256=function(e){var r=e[0];var t=e[1];var a=e[2];if(r===t&&t===a){if(r<8){return 16}if(r>248){return 231}return Math.round((r-8)/247*24)+232}var n=16+36*Math.round(r/255*5)+6*Math.round(t/255*5)+Math.round(a/255*5);return n};convert$1.ansi16.rgb=function(e){var r=e%10;if(r===0||r===7){if(e>50){r+=3.5}r=r/10.5*255;return[r,r,r]}var t=(~~(e>50)+1)*.5;var a=(r&1)*t*255;var n=(r>>1&1)*t*255;var o=(r>>2&1)*t*255;return[a,n,o]};convert$1.ansi256.rgb=function(e){if(e>=232){var r=(e-232)*10+8;return[r,r,r]}e-=16;var t;var a=Math.floor(e/36)/5*255;var n=Math.floor((t=e%36)/6)/5*255;var o=t%6/5*255;return[a,n,o]};convert$1.rgb.hex=function(e){var r=((Math.round(e[0])&255)<<16)+((Math.round(e[1])&255)<<8)+(Math.round(e[2])&255);var t=r.toString(16).toUpperCase();return"000000".substring(t.length)+t};convert$1.hex.rgb=function(e){var r=e.toString(16).match(/[a-f0-9]{6}|[a-f0-9]{3}/i);if(!r){return[0,0,0]}var t=r[0];if(r[0].length===3){t=t.split("").map((function(e){return e+e})).join("")}var a=parseInt(t,16);var n=a>>16&255;var o=a>>8&255;var i=a&255;return[n,o,i]};convert$1.rgb.hcg=function(e){var r=e[0]/255;var t=e[1]/255;var a=e[2]/255;var n=Math.max(Math.max(r,t),a);var o=Math.min(Math.min(r,t),a);var i=n-o;var l;var s;if(i<1){l=o/(1-i)}else{l=0}if(i<=0){s=0}else if(n===r){s=(t-a)/i%6}else if(n===t){s=2+(a-r)/i}else{s=4+(r-t)/i}s/=6;s%=1;return[s*360,i*100,l*100]};convert$1.hsl.hcg=function(e){var r=e[1]/100;var t=e[2]/100;var a=t<.5?2*r*t:2*r*(1-t);var n=0;if(a<1){n=(t-.5*a)/(1-a)}return[e[0],a*100,n*100]};convert$1.hsv.hcg=function(e){var r=e[1]/100;var t=e[2]/100;var a=r*t;var n=0;if(a<1){n=(t-a)/(1-a)}return[e[0],a*100,n*100]};convert$1.hcg.rgb=function(e){var r=e[0]/360;var t=e[1]/100;var a=e[2]/100;if(t===0){return[a*255,a*255,a*255]}var n=[0,0,0];var o=r%1*6;var i=o%1;var l=1-i;var s=0;switch(Math.floor(o)){case 0:n[0]=1;n[1]=i;n[2]=0;break;case 1:n[0]=l;n[1]=1;n[2]=0;break;case 2:n[0]=0;n[1]=1;n[2]=i;break;case 3:n[0]=0;n[1]=l;n[2]=1;break;case 4:n[0]=i;n[1]=0;n[2]=1;break;default:n[0]=1;n[1]=0;n[2]=l}s=(1-t)*a;return[(t*n[0]+s)*255,(t*n[1]+s)*255,(t*n[2]+s)*255]};convert$1.hcg.hsv=function(e){var r=e[1]/100;var t=e[2]/100;var a=r+t*(1-r);var n=0;if(a>0){n=r/a}return[e[0],n*100,a*100]};convert$1.hcg.hsl=function(e){var r=e[1]/100;var t=e[2]/100;var a=t*(1-r)+.5*r;var n=0;if(a>0&&a<.5){n=r/(2*a)}else if(a>=.5&&a<1){n=r/(2*(1-a))}return[e[0],n*100,a*100]};convert$1.hcg.hwb=function(e){var r=e[1]/100;var t=e[2]/100;var a=r+t*(1-r);return[e[0],(a-r)*100,(1-a)*100]};convert$1.hwb.hcg=function(e){var r=e[1]/100;var t=e[2]/100;var a=1-t;var n=a-r;var o=0;if(n<1){o=(a-n)/(1-n)}return[e[0],n*100,o*100]};convert$1.apple.rgb=function(e){return[e[0]/65535*255,e[1]/65535*255,e[2]/65535*255]};convert$1.rgb.apple=function(e){return[e[0]/255*65535,e[1]/255*65535,e[2]/255*65535]};convert$1.gray.rgb=function(e){return[e[0]/100*255,e[0]/100*255,e[0]/100*255]};convert$1.gray.hsl=function(e){return[0,0,e[0]]};convert$1.gray.hsv=convert$1.gray.hsl;convert$1.gray.hwb=function(e){return[0,100,e[0]]};convert$1.gray.cmyk=function(e){return[0,0,0,e[0]]};convert$1.gray.lab=function(e){return[e[0],0,0]};convert$1.gray.hex=function(e){var r=Math.round(e[0]/100*255)&255;var t=(r<<16)+(r<<8)+r;var a=t.toString(16).toUpperCase();return"000000".substring(a.length)+a};convert$1.rgb.gray=function(e){var r=(e[0]+e[1]+e[2])/3;return[r/255*100]};function buildGraph(){var e={};var r=Object.keys(conversions);for(var t=r.length,a=0;a<t;a++){e[r[a]]={distance:-1,parent:null}}return e}function deriveBFS(e){var r=buildGraph();var t=[e];r[e].distance=0;while(t.length){var a=t.pop();var n=Object.keys(conversions[a]);for(var o=n.length,i=0;i<o;i++){var l=n[i];var s=r[l];if(s.distance===-1){s.distance=r[a].distance+1;s.parent=a;t.unshift(l)}}}return r}function link(e,r){return function(t){return r(e(t))}}function wrapConversion(e,r){var t=[r[e].parent,e];var a=conversions[r[e].parent][e];var n=r[e].parent;while(r[n].parent){t.unshift(r[n].parent);a=link(conversions[r[n].parent][n],a);n=r[n].parent}a.conversion=t;return a}var route=function(e){var r=deriveBFS(e);var t={};var a=Object.keys(r);for(var n=a.length,o=0;o<n;o++){var i=a[o];var l=r[i];if(l.parent===null){continue}t[i]=wrapConversion(i,r)}return t};var convert={};var models=Object.keys(conversions);function wrapRaw(e){var r=function(){var r=[];for(var t=0;t<arguments.length;t++){r[t]=arguments[t]}var a=r[0];if(a===undefined||a===null){return a}if(a.length>1){r=a}return e(r)};if("conversion"in e){r.conversion=e.conversion}return r}function wrapRounded(e){var r=function(){var r=[];for(var t=0;t<arguments.length;t++){r[t]=arguments[t]}var a=r[0];if(a===undefined||a===null){return a}if(a.length>1){r=a}var n=e(r);if(typeof n==="object"){for(var o=n.length,i=0;i<o;i++){n[i]=Math.round(n[i])}}return n};if("conversion"in e){r.conversion=e.conversion}return r}models.forEach((function(e){convert[e]={};Object.defineProperty(convert[e],"channels",{value:conversions[e].channels});Object.defineProperty(convert[e],"labels",{value:conversions[e].labels});var r=route(e);var t=Object.keys(r);t.forEach((function(t){var a=r[t];convert[e][t]=wrapRounded(a);convert[e][t].raw=wrapRaw(a)}))}));var colorConvert=convert;var _slice=[].slice;var skippedModels=["keyword","gray","hex"];var hashedModelKeys={};for(var _f=0,_g=Object.keys(colorConvert);_f<_g.length;_f++){var model=_g[_f];hashedModelKeys[_slice.call(colorConvert[model].labels).sort().join("")]=model}var limiters={};function Color(e,r){if(!(this instanceof Color)){return new Color(e,r)}if(r&&r in skippedModels){r=null}if(r&&!(r in colorConvert)){throw new Error("Unknown model: "+r)}var t;var a;if(e==null){this.model="rgb";this.color=[0,0,0];this.valpha=1}else if(e instanceof Color){this.model=e.model;this.color=e.color.slice();this.valpha=e.valpha}else if(typeof e==="string"){var n=colorString.get(e);if(n===null){throw new Error("Unable to parse color from string: "+e)}this.model=n.model;a=colorConvert[this.model].channels;this.color=n.value.slice(0,a);this.valpha=typeof n.value[a]==="number"?n.value[a]:1}else if(e.length>0){this.model=r||"rgb";a=colorConvert[this.model].channels;var o=_slice.call(e,0,a);this.color=zeroArray(o,a);this.valpha=typeof e[a]==="number"?e[a]:1}else if(typeof e==="number"){this.model="rgb";this.color=[e>>16&255,e>>8&255,e&255];this.valpha=1}else{this.valpha=1;var i=Object.keys(e);if("alpha"in e){i.splice(i.indexOf("alpha"),1);this.valpha=typeof e.alpha==="number"?e.alpha:0}var l=i.sort().join("");if(!(l in hashedModelKeys)){throw new Error("Unable to parse color from object: "+JSON.stringify(e))}this.model=hashedModelKeys[l];var s=colorConvert[this.model].labels;var c=[];for(t=0;t<s.length;t++){c.push(e[s[t]])}this.color=zeroArray(c)}if(limiters[this.model]){a=colorConvert[this.model].channels;for(t=0;t<a;t++){var h=limiters[this.model][t];if(h){this.color[t]=h(this.color[t])}}}this.valpha=Math.max(0,Math.min(1,this.valpha));if(Object.freeze){Object.freeze(this)}}Color.prototype={toString:function(){return this.string()},toJSON:function(){return this[this.model]()},string:function(e){var r=this.model in colorString.to?this:this.rgb();r=r.round(typeof e==="number"?e:1);var t=r.valpha===1?r.color:r.color.concat(this.valpha);return colorString.to[r.model](t)},percentString:function(e){var r=this.rgb().round(typeof e==="number"?e:1);var t=r.valpha===1?r.color:r.color.concat(this.valpha);return colorString.to.rgb.percent(t)},array:function(){return this.valpha===1?this.color.slice():this.color.concat(this.valpha)},object:function(){var e={};var r=colorConvert[this.model].channels;var t=colorConvert[this.model].labels;for(var a=0;a<r;a++){e[t[a]]=this.color[a]}if(this.valpha!==1){e.alpha=this.valpha}return e},unitArray:function(){var e=this.rgb().color;e[0]/=255;e[1]/=255;e[2]/=255;if(this.valpha!==1){e.push(this.valpha)}return e},unitObject:function(){var e=this.rgb().object();e.r/=255;e.g/=255;e.b/=255;if(this.valpha!==1){e.alpha=this.valpha}return e},round:function(e){e=Math.max(e||0,0);return new Color(this.color.map(roundToPlace(e)).concat(this.valpha),this.model)},alpha:function(e){if(arguments.length>0){return new Color(this.color.concat(Math.max(0,Math.min(1,e))),this.model)}return this.valpha},red:getset("rgb",0,maxfn(255)),green:getset("rgb",1,maxfn(255)),blue:getset("rgb",2,maxfn(255)),hue:getset(["hsl","hsv","hsl","hwb","hcg"],0,(function(e){return(e%360+360)%360})),saturationl:getset("hsl",1,maxfn(100)),lightness:getset("hsl",2,maxfn(100)),saturationv:getset("hsv",1,maxfn(100)),value:getset("hsv",2,maxfn(100)),chroma:getset("hcg",1,maxfn(100)),gray:getset("hcg",2,maxfn(100)),white:getset("hwb",1,maxfn(100)),wblack:getset("hwb",2,maxfn(100)),cyan:getset("cmyk",0,maxfn(100)),magenta:getset("cmyk",1,maxfn(100)),yellow:getset("cmyk",2,maxfn(100)),black:getset("cmyk",3,maxfn(100)),x:getset("xyz",0,maxfn(100)),y:getset("xyz",1,maxfn(100)),z:getset("xyz",2,maxfn(100)),l:getset("lab",0,maxfn(100)),a:getset("lab",1),b:getset("lab",2),keyword:function(e){if(arguments.length>0){return new Color(e)}return colorConvert[this.model].keyword(this.color)},hex:function(e){if(arguments.length>0){return new Color(e)}return colorString.to.hex(this.rgb().round().color)},hexa:function(e){if(arguments.length>0){return new Color(e)}var r=this.rgb().round().color;var t=Math.round(this.valpha*255).toString(16).toUpperCase();if(t.length===1){t="0"+t}return colorString.to.hex(r)+t},rgbNumber:function(){var e=this.rgb().color;return(e[0]&255)<<16|(e[1]&255)<<8|e[2]&255},luminosity:function(){var e=this.rgb().color;var r=[];for(var t=0,a=e.entries();t<a.length;t++){var n=a[t],o=n[0],i=n[1];var l=i/255;r[o]=l<=.03928?l/12.92:Math.pow((l+.055)/1.055,2.4)}return.2126*r[0]+.7152*r[1]+.0722*r[2]},contrast:function(e){var r=this.luminosity();var t=e.luminosity();if(r>t){return(r+.05)/(t+.05)}return(t+.05)/(r+.05)},level:function(e){var r=this.contrast(e);if(r>=7.1){return"AAA"}return r>=4.5?"AA":""},isDark:function(){var e=this.rgb().color;var r=(e[0]*299+e[1]*587+e[2]*114)/1e3;return r<128},isLight:function(){return!this.isDark()},negate:function(){var e=this.rgb();for(var r=0;r<3;r++){e.color[r]=255-e.color[r]}return e},lighten:function(e){var r=this.hsl();r.color[2]+=r.color[2]*e;return r},darken:function(e){var r=this.hsl();r.color[2]-=r.color[2]*e;return r},saturate:function(e){var r=this.hsl();r.color[1]+=r.color[1]*e;return r},desaturate:function(e){var r=this.hsl();r.color[1]-=r.color[1]*e;return r},whiten:function(e){var r=this.hwb();r.color[1]+=r.color[1]*e;return r},blacken:function(e){var r=this.hwb();r.color[2]+=r.color[2]*e;return r},grayscale:function(){var e=this.rgb().color;var r=e[0]*.3+e[1]*.59+e[2]*.11;return Color.rgb(r,r,r)},fade:function(e){return this.alpha(this.valpha-this.valpha*e)},opaquer:function(e){return this.alpha(this.valpha+this.valpha*e)},rotate:function(e){var r=this.hsl();var t=r.color[0];t=(t+e)%360;t=t<0?360+t:t;r.color[0]=t;return r},mix:function(e,r){if(!e||!e.rgb){throw new Error('Argument to "mix" was not a Color instance, but rather an instance of '+typeof e)}var t=e.rgb();var a=this.rgb();var n=r===undefined?.5:r;var o=2*n-1;var i=t.alpha()-a.alpha();var l=((o*i===-1?o:(o+i)/(1+o*i))+1)/2;var s=1-l;return Color.rgb(l*t.red()+s*a.red(),l*t.green()+s*a.green(),l*t.blue()+s*a.blue(),t.alpha()*n+a.alpha()*(1-n))}};var _loop_1=function(e){if(skippedModels.includes(e)){return"continue"}var r=colorConvert[e].channels;Color.prototype[e]=function(){if(this.model===e){return new Color(this)}if(arguments.length>0){return new Color(arguments,e)}var t=typeof arguments[r]==="number"?r:this.valpha;return new Color(assertArray(colorConvert[this.model][e].raw(this.color)).concat(t),e)};Color[e]=function(t){if(typeof t==="number"){t=zeroArray(_slice.call(arguments),r)}return new Color(t,e)}};for(var _h=0,_j=Object.keys(colorConvert);_h<_j.length;_h++){var model=_j[_h];_loop_1(model)}function roundTo(e,r){return Number(e.toFixed(r))}function roundToPlace(e){return function(r){return roundTo(r,e)}}function getset(e,r,t){e=Array.isArray(e)?e:[e];for(var a=0,n=e;a<n.length;a++){var o=n[a];(limiters[o]||(limiters[o]=[]))[r]=t}e=e[0];return function(a){var n;if(arguments.length>0){if(t){a=t(a)}n=this[e]();n.color[r]=a;return n}n=this[e]().color[r];if(t){n=t(n)}return n}}function maxfn(e){return function(r){return Math.max(0,Math.min(e,r))}}function assertArray(e){return Array.isArray(e)?e:[e]}function zeroArray(e,r){for(var t=0;t<r;t++){if(typeof e[t]!=="number"){e[t]=0}}return e}var color=Color;var CSS$2={container:"container",controlSection:"control-section",hexOptions:"color-hex-options",section:"section",header:"header",control:"control",splitSection:"section--split",colorModeContainer:"color-mode-container",colorMode:"color-mode",channels:"channels",channel:"channel",savedColors:"saved-colors",savedColorsSection:"saved-colors-section",saveColor:"save-color",deleteColor:"delete-color",savedColorsButtons:"saved-colors-buttons",headerHex:"header--hex",colorFieldAndSlider:"color-field-and-slider",colorFieldAndSliderInteractive:"color-field-and-slider--interactive",colorFieldAndSliderWrap:"color-field-and-slider-wrap",scope:"scope",hueScope:"scope--hue",colorFieldScope:"scope--color-field",savedColor:"saved-color"};var DEFAULT_COLOR$1=color("#007AC2");var DEFAULT_STORAGE_KEY_PREFIX="calcite-color-";var RGB_LIMITS={r:255,g:255,b:255};var HSV_LIMITS={h:360,s:100,v:100};var TEXT={b:"B",blue:"Blue",deleteColor:"Delete color",g:"G",green:"Green",h:"H",hsv:"HSV",hex:"Hex",hue:"Hue",noColor:"No color",r:"R",red:"Red",rgb:"RGB",s:"S",saturation:"Saturation",saveColor:"Save color",saved:"Saved",v:"V",value:"Value"};var DIMENSIONS={s:{slider:{height:10,width:160},colorField:{height:80,width:160},thumb:{radius:8}},m:{slider:{height:14,width:272},colorField:{height:150,width:272},thumb:{radius:10}},l:{slider:{height:16,width:464},colorField:{height:200,width:464},thumb:{radius:12}}};var calciteColorPickerCss="@-webkit-keyframes in{0%{opacity:0}100%{opacity:1}}@keyframes in{0%{opacity:0}100%{opacity:1}}@-webkit-keyframes in-down{0%{opacity:0;-webkit-transform:translate3D(0, -5px, 0);transform:translate3D(0, -5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@keyframes in-down{0%{opacity:0;-webkit-transform:translate3D(0, -5px, 0);transform:translate3D(0, -5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@-webkit-keyframes in-up{0%{opacity:0;-webkit-transform:translate3D(0, 5px, 0);transform:translate3D(0, 5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@keyframes in-up{0%{opacity:0;-webkit-transform:translate3D(0, 5px, 0);transform:translate3D(0, 5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@-webkit-keyframes in-scale{0%{opacity:0;-webkit-transform:scale3D(0.95, 0.95, 1);transform:scale3D(0.95, 0.95, 1)}100%{opacity:1;-webkit-transform:scale3D(1, 1, 1);transform:scale3D(1, 1, 1)}}@keyframes in-scale{0%{opacity:0;-webkit-transform:scale3D(0.95, 0.95, 1);transform:scale3D(0.95, 0.95, 1)}100%{opacity:1;-webkit-transform:scale3D(1, 1, 1);transform:scale3D(1, 1, 1)}}:root{--calcite-animation-timing:calc(150ms * var(--calcite-internal-duration-factor));--calcite-internal-duration-factor:var(--calcite-duration-factor, 1);--calcite-internal-animation-timing-fast:calc(100ms * var(--calcite-internal-duration-factor));--calcite-internal-animation-timing-medium:calc(200ms * var(--calcite-internal-duration-factor));--calcite-internal-animation-timing-slow:calc(300ms * var(--calcite-internal-duration-factor))}.calcite-animate{opacity:0;-webkit-animation-fill-mode:both;animation-fill-mode:both;-webkit-animation-duration:var(--calcite-animation-timing);animation-duration:var(--calcite-animation-timing)}.calcite-animate__in{-webkit-animation-name:in;animation-name:in}.calcite-animate__in-down{-webkit-animation-name:in-down;animation-name:in-down}.calcite-animate__in-up{-webkit-animation-name:in-up;animation-name:in-up}.calcite-animate__in-scale{-webkit-animation-name:in-scale;animation-name:in-scale}:root{--calcite-popper-transition:var(--calcite-animation-timing)}:host([hidden]){display:none}:host{display:inline-block;font-size:var(--calcite-font-size--2);line-height:1rem;font-weight:var(--calcite-font-weight-normal)}:host([scale=s]) .container{width:160px}:host([scale=s]) .saved-colors{grid-template-columns:repeat(auto-fill, minmax(20px, 1fr))}:host([scale=s]) .channels{-ms-flex-direction:column;flex-direction:column}:host([scale=s]) .channel{width:100%;margin-bottom:4px}:host([scale=s]) .channel:last-child{margin-bottom:0}:host([scale=m]) .container{width:272px}:host([scale=l]) .header{padding-bottom:0px}:host([scale=l]){font-size:var(--calcite-font-size--1);line-height:1rem}:host([scale=l]) .container{width:464px}:host([scale=l]) .color-field-and-slider{margin-bottom:-20px}:host([scale=l]) .section{padding:0 16px 16px}:host([scale=l]) .section:first-of-type{padding-top:16px}:host([scale=l]) .saved-colors{grid-template-columns:repeat(auto-fill, minmax(28px, 1fr));grid-gap:12px;padding-top:16px}:host([scale=l]) .control-section{-ms-flex-wrap:nowrap;flex-wrap:nowrap;-ms-flex-align:baseline;align-items:baseline}:host([scale=l]) .control-section>:nth-child(2){-webkit-margin-start:12px;margin-inline-start:12px}:host([scale=l]) .color-hex-options{display:-ms-flexbox;display:flex;-ms-flex-negative:1;flex-shrink:1;-ms-flex-direction:column;flex-direction:column;-ms-flex-pack:distribute;justify-content:space-around;min-height:98px;width:160px}:host([scale=l]) .color-mode-container{-ms-flex-negative:3;flex-shrink:3}:host([appearance=minimal]) .container{border:none}.container{background-color:var(--calcite-ui-foreground-1);display:inline-block;border:1px solid var(--calcite-ui-border-1)}.color-field-and-slider-wrap{position:relative}.scope{pointer-events:none;position:absolute;margin-bottom:0px;margin-right:0px;height:0.5rem;width:0.5rem;padding:0px;font-size:var(--calcite-font-size--1);outline-offset:0;outline-color:transparent;-webkit-transition:outline-offset 100ms ease-in-out, outline-color 100ms ease-in-out;transition:outline-offset 100ms ease-in-out, outline-color 100ms ease-in-out;margin-top:-0.25rem;margin-left:-0.25rem;outline-offset:10px}.scope:focus{outline:2px solid var(--calcite-ui-brand);outline-offset:12px}.color-field-and-slider{margin-bottom:-16px}.color-field-and-slider--interactive{cursor:pointer}.control-section{display:-ms-flexbox;display:flex;-ms-flex-direction:row;flex-direction:row;-ms-flex-wrap:wrap;flex-wrap:wrap}.section{padding:0 12px 12px}.section:first-of-type{padding-top:12px}.color-hex-options,.section--split{-ms-flex-positive:1;flex-grow:1}.header{display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;-ms-flex-pack:justify;justify-content:space-between;padding-bottom:0.25rem;color:var(--calcite-ui-text-1)}.header--hex,.color-mode-container{padding-top:12px}.channels{display:-ms-flexbox;display:flex;-ms-flex-pack:justify;justify-content:space-between}.channel{width:31%}.saved-colors{padding-top:12px;display:grid;grid-template-columns:repeat(auto-fill, minmax(24px, 1fr));grid-gap:8px;width:100%}.saved-colors-buttons{display:-ms-flexbox;display:flex}.saved-color{outline-offset:0;outline-color:transparent;-webkit-transition:outline-offset 100ms ease-in-out, outline-color 100ms ease-in-out;transition:outline-offset 100ms ease-in-out, outline-color 100ms ease-in-out;cursor:pointer}.saved-color:focus{outline:2px solid var(--calcite-ui-brand);outline-offset:2px}.saved-color:hover{-webkit-transition:outline-color var(--calcite-internal-animation-timing-fast) ease-in-out;transition:outline-color var(--calcite-internal-animation-timing-fast) ease-in-out;outline:2px solid var(--calcite-ui-border-2);outline-offset:2px}";var throttleFor60FpsInMs=16;var defaultValue=normalizeHex(DEFAULT_COLOR$1.hex());var defaultFormat="auto";var CalciteColorPicker=function(){function e(e){var r=this;registerInstance(this,e);this.calciteColorPickerChange=createEvent(this,"calciteColorPickerChange",7);this.calciteColorPickerInput=createEvent(this,"calciteColorPickerInput",7);this.allowEmpty=false;this.appearance="default";this.color=DEFAULT_COLOR$1;this.format=defaultFormat;this.hideHex=false;this.hideChannels=false;this.hideSaved=false;this.intlB=TEXT.b;this.intlBlue=TEXT.blue;this.intlDeleteColor=TEXT.deleteColor;this.intlG=TEXT.g;this.intlGreen=TEXT.green;this.intlH=TEXT.h;this.intlHsv=TEXT.hsv;this.intlHex=TEXT.hex;this.intlHue=TEXT.hue;this.intlNoColor=TEXT.noColor;this.intlR=TEXT.r;this.intlRed=TEXT.red;this.intlRgb=TEXT.rgb;this.intlS=TEXT.s;this.intlSaturation=TEXT.saturation;this.intlSaveColor=TEXT.saveColor;this.intlSaved=TEXT.saved;this.intlV=TEXT.v;this.intlValue=TEXT.value;this.scale="m";this.value=defaultValue;this.colorFieldAndSliderHovered=false;this.hueThumbState="idle";this.internalColorUpdateContext=null;this.mode=CSSColorMode.HEX;this.shiftKeyChannelAdjustment=0;this.sliderThumbState="idle";this.colorFieldAndSliderInteractive=false;this.channelMode="rgb";this.channels=this.toChannels(DEFAULT_COLOR$1);this.dimensions=DIMENSIONS.m;this.savedColors=[];this.handleTabActivate=function(e){r.channelMode=e.currentTarget.getAttribute("data-color-mode");r.updateChannelsFromColor(r.color)};this.handleColorFieldScopeKeyDown=function(e){var t=e.key;var a={ArrowUp:{x:0,y:-10},ArrowRight:{x:10,y:0},ArrowDown:{x:0,y:10},ArrowLeft:{x:-10,y:0}};if(a[t]){e.preventDefault();r.scopeOrientation=t==="ArrowDown"||t==="ArrowUp"?"vertical":"horizontal";r.captureColorFieldColor(r.colorFieldScopeLeft+a[t].x||0,r.colorFieldScopeTop+a[t].y||0,false)}};this.handleHueScopeKeyDown=function(e){var t=e.shiftKey?10:1;var a=e.key;var n={ArrowUp:1,ArrowRight:1,ArrowDown:-1,ArrowLeft:-1};if(n[a]){e.preventDefault();var o=n[a]*t;var i=r.baseColorFieldColor.hue();var l=r.baseColorFieldColor.hue(i+o);r.internalColorSet(l,false)}};this.handleHexInputChange=function(e){e.stopPropagation();var t=r,a=t.allowEmpty,n=t.color;var o=e.target;var i=o.value;if(a&&!i){r.internalColorSet(null);return}var l=n&&normalizeHex(n.hex());if(i!==l){r.internalColorSet(color(i))}};this.handleSavedColorSelect=function(e){var t=e.currentTarget;r.internalColorSet(color(t.color))};this.handleChannelInput=function(e){var t=e.currentTarget;var a=e.detail.nativeEvent.target;var n=Number(t.getAttribute("data-channel-index"));var o=r.channelMode==="rgb"?RGB_LIMITS[Object.keys(RGB_LIMITS)[n]]:HSV_LIMITS[Object.keys(HSV_LIMITS)[n]];var i;if(r.allowEmpty&&!t.value){i=""}else{var l=Number(t.value)+r.shiftKeyChannelAdjustment;var s=clamp(l,0,o);i=s.toString()}t.value=i;a.value=i};this.handleChannelChange=function(e){var t=e.currentTarget;var a=Number(t.getAttribute("data-channel-index"));var n=__spreadArray([],r.channels);var o=r.allowEmpty&&!t.value;if(o){r.channels=[null,null,null];r.internalColorSet(null);return}n[a]=Number(t.value);r.updateColorFromChannels(n)};this.handleSavedColorKeyDown=function(e){if(e.key===" "||e.key==="Enter"){e.preventDefault();e.stopPropagation();r.handleSavedColorSelect(e)}};this.handleColorFieldAndSliderMouseLeave=function(){r.colorFieldAndSliderInteractive=false;r.colorFieldAndSliderHovered=false;if(r.sliderThumbState!=="drag"&&r.hueThumbState!=="drag"){r.hueThumbState="idle";r.sliderThumbState="idle";r.drawColorFieldAndSlider()}};this.handleColorFieldAndSliderMouseDown=function(e){var t=e.offsetX,a=e.offsetY;var n=r.getCanvasRegion(a);if(n==="color-field"){r.hueThumbState="drag";r.captureColorFieldColor(t,a)}else if(n==="slider"){r.sliderThumbState="drag";r.captureHueSliderColor(t)}e.preventDefault();document.addEventListener("mousemove",r.globalMouseMoveHandler);document.addEventListener("mouseup",r.globalMouseUpHandler,{once:true});r.activeColorFieldAndSliderRect=r.fieldAndSliderRenderingContext.canvas.getBoundingClientRect()};this.globalMouseUpHandler=function(){var e=r.sliderThumbState==="drag"||r.hueThumbState==="drag";r.hueThumbState="idle";r.sliderThumbState="idle";r.activeColorFieldAndSliderRect=null;r.drawColorFieldAndSlider();if(e){r.calciteColorPickerChange.emit()}};this.globalMouseMoveHandler=function(e){var t=r,a=t.el,n=t.dimensions;var o=r.sliderThumbState==="drag";var i=r.hueThumbState==="drag";if(!a.isConnected||!o&&!i){return}var l;var s;var c=r.activeColorFieldAndSliderRect;var h=e.clientX,u=e.clientY;if(r.colorFieldAndSliderHovered){l=h-c.x;s=u-c.y}else{var d=n.colorField.width;var v=n.colorField.height;var f=n.slider.height;if(h<c.x+d&&h>c.x){l=h-c.x}else if(h<c.x){l=0}else{l=d}if(u<c.y+v+f&&u>c.y){s=u-c.y}else if(u<c.y){s=0}else{s=v+f}}if(i){r.captureColorFieldColor(l,s,false)}else{r.captureHueSliderColor(l)}};this.handleColorFieldAndSliderMouseEnterOrMove=function(e){var t=e.offsetX,a=e.offsetY;var n=r.dimensions,o=n.colorField,i=n.slider,l=n.thumb;r.colorFieldAndSliderInteractive=a<=o.height+i.height;r.colorFieldAndSliderHovered=true;var s=r.getCanvasRegion(a);if(s==="color-field"){var c=r.hueThumbState;var h=r.baseColorFieldColor.hsv();var u=Math.round(h.saturationv()/(HSV_LIMITS.s/o.width));var d=Math.round(o.height-h.value()/(HSV_LIMITS.v/o.height));var v=r.containsPoint(t,a,u,d,l.radius);var f=false;if(c==="idle"&&v){r.hueThumbState="hover";f=true}else if(c==="hover"&&!v){r.hueThumbState="idle";f=true}if(r.hueThumbState!=="drag"){if(f){r.drawColorFieldAndSlider()}}}else if(s==="slider"){var p=r.baseColorFieldColor.hsv().saturationv(100).value(100);var m=r.sliderThumbState;var g=Math.round(p.hue()/(360/i.width));var b=Math.round((i.height+r.getSliderCapSpacing())/2)+o.height;var y=r.containsPoint(t,a,g,b,l.radius);var w=false;if(m==="idle"&&y){r.sliderThumbState="hover";w=true}else if(m==="hover"&&!y){r.sliderThumbState="idle";w=true}if(r.sliderThumbState!=="drag"){if(w){r.drawColorFieldAndSlider()}}}};this.storeColorFieldScope=function(e){r.colorFieldScopeNode=e};this.renderChannelsTabTitle=function(e){var t=r,a=t.channelMode,n=t.intlRgb,o=t.intlHsv;var i=e===a;var l=e==="rgb"?n:o;return h("calcite-tab-title",{active:i,class:CSS$2.colorMode,"data-color-mode":e,key:e,onCalciteTabsActivate:r.handleTabActivate},l)};this.renderChannelsTab=function(e){var t=r,a=t.channelMode,n=t.channels,o=t.intlB,i=t.intlBlue,l=t.intlG,s=t.intlGreen,c=t.intlH,u=t.intlHue,d=t.intlR,v=t.intlRed,f=t.intlS,p=t.intlSaturation,m=t.intlV,g=t.intlValue;var b=e===a;var y=e==="rgb";var w=y?[d,l,o]:[c,f,m];var C=y?[v,s,i]:[u,p,g];return h("calcite-tab",{active:b,class:CSS$2.control,key:e},h("div",{class:CSS$2.channels},n.map((function(e,t){return r.renderChannel(e,t,w[t],C[t])}))))};this.renderChannel=function(e,t,a,n){return h("calcite-input",{class:CSS$2.channel,"data-channel-index":t,label:n,numberButtonType:"none",onCalciteInputChange:r.handleChannelChange,onCalciteInputInput:r.handleChannelInput,prefixText:a,scale:r.scale==="l"?"m":"s",type:"number",value:e===null||e===void 0?void 0:e.toString()})};this.deleteColor=function(){var e=r.color.hex();var t=r.savedColors.indexOf(e)>-1;if(!t){return}var a=r.savedColors.filter((function(r){return r!==e}));r.savedColors=a;var n=""+DEFAULT_STORAGE_KEY_PREFIX+r.storageId;if(r.storageId){localStorage.setItem(n,JSON.stringify(a))}};this.saveColor=function(){var e=r.color.hex();var t=r.savedColors.indexOf(e)>-1;if(t){return}var a=__spreadArray(__spreadArray([],r.savedColors),[e]);r.savedColors=a;var n=""+DEFAULT_STORAGE_KEY_PREFIX+r.storageId;if(r.storageId){localStorage.setItem(n,JSON.stringify(a))}};this.drawColorFieldAndSlider=throttle((function(){if(!r.fieldAndSliderRenderingContext){return}r.drawColorField();r.drawHueSlider()}),throttleFor60FpsInMs);this.captureColorFieldColor=function(e,t,a){if(a===void 0){a=true}var n=r.dimensions.colorField,o=n.height,i=n.width;var l=Math.round(HSV_LIMITS.s/i*e);var s=Math.round(HSV_LIMITS.v/o*(o-t));r.internalColorSet(r.baseColorFieldColor.hsv().saturationv(l).value(s),a)};this.initColorFieldAndSlider=function(e){r.fieldAndSliderRenderingContext=e.getContext("2d");r.setCanvasContextSize(e,{width:r.dimensions.colorField.width,height:r.dimensions.colorField.height+r.dimensions.slider.height+r.getSliderCapSpacing()*2});r.drawColorFieldAndSlider()}}e.prototype.handleColorChange=function(e,r){this.drawColorFieldAndSlider();this.updateChannelsFromColor(e);this.previousColor=r;if(this.internalColorUpdateContext){return}this.value=this.toValue(e)};e.prototype.handleFormatChange=function(e){this.setMode(e);this.value=this.toValue(this.color)};e.prototype.handleScaleChange=function(e){if(e===void 0){e="m"}this.updateDimensions(e)};e.prototype.handleValueChange=function(e,r){var t=this,a=t.allowEmpty,n=t.format;var o=!a||e;var i=false;if(o){var l=parseMode(e);if(!l||n!=="auto"&&l!==n){this.showIncompatibleColorWarning(e,n);this.value=r;return}i=this.mode!==l;this.setMode(l)}var s=this.sliderThumbState==="drag"||this.hueThumbState==="drag";if(this.internalColorUpdateContext){if(this.internalColorUpdateContext==="initial"){return}this.calciteColorPickerInput.emit();if(!s){this.calciteColorPickerChange.emit()}return}var c=a&&!e?null:color(e);var h=!colorEqual(c,this.color);if(i||h){this.color=c;this.calciteColorPickerInput.emit();if(!s){this.calciteColorPickerChange.emit()}}};Object.defineProperty(e.prototype,"baseColorFieldColor",{get:function(){return this.color||this.previousColor||DEFAULT_COLOR$1},enumerable:false,configurable:true});e.prototype.handleChannelKeyUpOrDown=function(e){this.shiftKeyChannelAdjustment=0;var r=e.key;if(r!=="ArrowUp"&&r!=="ArrowDown"||!e.composedPath().some((function(e){var r;return(r=e.classList)===null||r===void 0?void 0:r.contains(CSS$2.channel)}))){return}var t=e.shiftKey;e.preventDefault();if(!this.color){this.internalColorSet(this.previousColor);e.stopPropagation();return}var a=9;this.shiftKeyChannelAdjustment=r==="ArrowUp"&&t?a:r==="ArrowDown"&&t?-a:0};e.prototype.setFocus=function(){return __awaiter(this,void 0,void 0,(function(){return __generator(this,(function(e){return[2,focusElement(this.colorFieldScopeNode)]}))}))};e.prototype.componentWillLoad=function(){var e=this,r=e.allowEmpty,t=e.color,a=e.format,n=e.value;var o=r&&!n;var i=parseMode(n);var l=o||a==="auto"&&i||a===i;var s=o?null:l?color(n):t;if(!l){this.showIncompatibleColorWarning(n,a)}this.setMode(a);this.internalColorSet(s,false,"initial");this.updateDimensions(this.scale);var c=""+DEFAULT_STORAGE_KEY_PREFIX+this.storageId;if(this.storageId&&localStorage.getItem(c)){this.savedColors=JSON.parse(localStorage.getItem(c))}};e.prototype.disconnectedCallback=function(){document.removeEventListener("mousemove",this.globalMouseMoveHandler);document.removeEventListener("mouseup",this.globalMouseUpHandler)};e.prototype.render=function(){var e,r,t,a,n,o,i;var l=this;var s=this,c=s.allowEmpty,u=s.color,d=s.intlDeleteColor,v=s.hideHex,f=s.hideChannels,p=s.hideSaved,m=s.intlHex,g=s.intlSaved,b=s.intlSaveColor,y=s.savedColors,w=s.scale;var C=u?u.hex():null;var S=w==="l"?"m":"s";var x=this,k=x.colorFieldAndSliderInteractive,M=x.colorFieldScopeTop,T=x.colorFieldScopeLeft,_=x.hueScopeLeft,F=x.hueScopeTop,D=x.scopeOrientation,A=x.dimensions,I=A.colorField,$=I.height,E=I.width,O=A.slider.height;var H=F!==null&&F!==void 0?F:O/2+$;var R=_!==null&&_!==void 0?_:E*DEFAULT_COLOR$1.hue()/HSV_LIMITS.h;var L=u===null;var j=D==="vertical";return h("div",{class:CSS$2.container},h("div",{class:CSS$2.colorFieldAndSliderWrap},h("canvas",{class:(e={},e[CSS$2.colorFieldAndSlider]=true,e[CSS$2.colorFieldAndSliderInteractive]=k,e),onMouseDown:this.handleColorFieldAndSliderMouseDown,onMouseEnter:this.handleColorFieldAndSliderMouseEnterOrMove,onMouseLeave:this.handleColorFieldAndSliderMouseLeave,onMouseMove:this.handleColorFieldAndSliderMouseEnterOrMove,ref:this.initColorFieldAndSlider}),h("div",{"aria-label":j?this.intlValue:this.intlSaturation,"aria-valuemax":j?HSV_LIMITS.v:HSV_LIMITS.s,"aria-valuemin":"0","aria-valuenow":(j?u===null||u===void 0?void 0:u.saturationv():u===null||u===void 0?void 0:u.value())||"0",class:(r={},r[CSS$2.scope]=true,r[CSS$2.colorFieldScope]=true,r),onKeyDown:this.handleColorFieldScopeKeyDown,ref:this.storeColorFieldScope,role:"slider",style:{top:(M||0)+"px",left:(T||0)+"px"},tabindex:"0"}),h("div",{"aria-label":this.intlHue,"aria-valuemax":HSV_LIMITS.h,"aria-valuemin":"0","aria-valuenow":(u===null||u===void 0?void 0:u.round().hue())||DEFAULT_COLOR$1.round().hue(),class:(t={},t[CSS$2.scope]=true,t[CSS$2.hueScope]=true,t),onKeyDown:this.handleHueScopeKeyDown,role:"slider",style:{top:H+"px",left:R+"px"},tabindex:"0"})),v&&f?null:h("div",{class:(a={},a[CSS$2.controlSection]=true,a[CSS$2.section]=true,a)},v?null:h("div",{class:CSS$2.hexOptions},h("span",{class:(n={},n[CSS$2.header]=true,n[CSS$2.headerHex]=true,n)},m),h("calcite-color-picker-hex-input",{allowEmpty:c,class:CSS$2.control,onCalciteColorPickerHexInputChange:this.handleHexInputChange,scale:S,value:C})),f?null:h("calcite-tabs",{class:(o={},o[CSS$2.colorModeContainer]=true,o[CSS$2.splitSection]=true,o),scale:S},h("calcite-tab-nav",{slot:"tab-nav"},this.renderChannelsTabTitle("rgb"),this.renderChannelsTabTitle("hsv")),this.renderChannelsTab("rgb"),this.renderChannelsTab("hsv"))),p?null:h("div",{class:(i={},i[CSS$2.savedColorsSection]=true,i[CSS$2.section]=true,i)},h("div",{class:CSS$2.header},h("label",null,g),h("div",{class:CSS$2.savedColorsButtons},h("calcite-button",{appearance:"transparent",class:CSS$2.deleteColor,color:"neutral",disabled:L,iconStart:"minus",label:d,onClick:this.deleteColor,scale:S}),h("calcite-button",{appearance:"transparent",class:CSS$2.saveColor,color:"neutral",disabled:L,iconStart:"plus",label:b,onClick:this.saveColor,scale:S}))),y.length>0?h("div",{class:CSS$2.savedColors},__spreadArray([],y.map((function(e){return h("calcite-color-picker-swatch",{active:C===e,class:CSS$2.savedColor,color:e,key:e,onClick:l.handleSavedColorSelect,onKeyDown:l.handleSavedColorKeyDown,scale:w,tabIndex:0})})))):null))};e.prototype.showIncompatibleColorWarning=function(e,r){console.warn("ignoring color value ("+e+") as it is not compatible with the current format ("+r+")")};e.prototype.setMode=function(e){this.mode=e==="auto"?this.mode:e};e.prototype.captureHueSliderColor=function(e){var r=this.dimensions.slider.width;var t=360/r*e;this.internalColorSet(this.baseColorFieldColor.hue(t),false)};e.prototype.getCanvasRegion=function(e){var r=this.dimensions,t=r.colorField.height,a=r.slider.height;if(e<=t){return"color-field"}if(e<=t+a){return"slider"}return"none"};e.prototype.internalColorSet=function(e,r,t){if(r===void 0){r=true}if(t===void 0){t="internal"}if(r&&colorEqual(e,this.color)){return}this.internalColorUpdateContext=t;this.color=e;this.value=this.toValue(e);this.internalColorUpdateContext=null};e.prototype.toValue=function(e,r){if(r===void 0){r=this.mode}if(!e){return null}var t="hex";if(r.includes(t)){return normalizeHex(e.round()[t]())}if(r.includes("-css")){return e[r.replace("-css","").replace("a","")]().round().string()}var a=e[r]().round().object();if(r.endsWith("a")){a.a=a.alpha;delete a.alpha}return a};e.prototype.getSliderCapSpacing=function(){var e=this.dimensions,r=e.slider.height,t=e.thumb.radius;return t*2-r};e.prototype.updateDimensions=function(e){if(e===void 0){e="m"}this.dimensions=DIMENSIONS[e]};e.prototype.drawColorField=function(){var e=this.fieldAndSliderRenderingContext;var r=this.dimensions.colorField,t=r.height,a=r.width;e.fillStyle=this.baseColorFieldColor.hsv().saturationv(100).value(100).string();e.fillRect(0,0,a,t);var n=e.createLinearGradient(0,0,a,0);n.addColorStop(0,"rgba(255,255,255,1)");n.addColorStop(1,"rgba(255,255,255,0)");e.fillStyle=n;e.fillRect(0,0,a,t);var o=e.createLinearGradient(0,0,0,t);o.addColorStop(0,"rgba(0,0,0,0)");o.addColorStop(1,"rgba(0,0,0,1)");e.fillStyle=o;e.fillRect(0,0,a,t);this.drawActiveColorFieldColor()};e.prototype.setCanvasContextSize=function(e,r){var t=r.height,a=r.width;var n=window.devicePixelRatio||1;e.width=a*n;e.height=t*n;e.style.height=t+"px";e.style.width=a+"px";var o=e.getContext("2d");o.scale(n,n)};e.prototype.containsPoint=function(e,r,t,a,n){return Math.pow(e-t,2)+Math.pow(r-a,2)<=Math.pow(n,2)};e.prototype.drawActiveColorFieldColor=function(){var e=this;var r=this.color;if(!r){return}var t=r.hsv();var a=this.dimensions,n=a.colorField,o=n.height,i=n.width,l=a.thumb.radius;var s=t.saturationv()/(HSV_LIMITS.s/i);var c=o-t.value()/(HSV_LIMITS.v/o);requestAnimationFrame((function(){e.colorFieldScopeLeft=s;e.colorFieldScopeTop=c}));this.drawThumb(this.fieldAndSliderRenderingContext,l,s,c,t,this.hueThumbState)};e.prototype.drawThumb=function(e,r,t,a,n,o){var i=0;var l=2*Math.PI;e.beginPath();e.arc(t,a,r,i,l);e.shadowBlur=o==="hover"?32:16;e.shadowColor="rgba(0, 0, 0, "+(o==="drag"?.32:.16)+")";e.fillStyle="#fff";e.fill();e.beginPath();e.arc(t,a,r-3,i,l);e.shadowBlur=0;e.shadowColor="transparent";e.fillStyle=n.rgb().string();e.fill()};e.prototype.drawActiveHueSliderColor=function(){var e=this;var r=this.color;if(!r){return}var t=r.hsv().saturationv(100).value(100);var a=this.dimensions,n=a.colorField.height,o=a.slider,i=o.height,l=o.width,s=a.thumb.radius;var c=t.hue()/(360/l);var h=i/2+n;requestAnimationFrame((function(){e.hueScopeLeft=c;e.hueScopeTop=h}));this.drawThumb(this.fieldAndSliderRenderingContext,s,c,h,t,this.sliderThumbState)};e.prototype.drawHueSlider=function(){var e=this.fieldAndSliderRenderingContext;var r=this.dimensions,t=r.colorField.height,a=r.slider,n=a.height,o=a.width;var i=e.createLinearGradient(0,0,o,0);var l=["red","yellow","lime","cyan","blue","magenta","red"];var s=1/(l.length-1);var c=0;l.forEach((function(e){i.addColorStop(c,color(e).string());c+=s}));e.fillStyle=i;e.clearRect(0,t,o,n+this.getSliderCapSpacing()*2);e.fillRect(0,t,o,n);this.drawActiveHueSliderColor()};e.prototype.updateColorFromChannels=function(e){this.internalColorSet(color(e,this.channelMode))};e.prototype.updateChannelsFromColor=function(e){this.channels=e?this.toChannels(e):[null,null,null]};e.prototype.toChannels=function(e){var r=this.channelMode;return e[r]().array().map((function(e){return Math.floor(e)}))};Object.defineProperty(e.prototype,"el",{get:function(){return getElement(this)},enumerable:false,configurable:true});Object.defineProperty(e,"watchers",{get:function(){return{color:["handleColorChange"],format:["handleFormatChange"],scale:["handleScaleChange"],value:["handleValueChange"]}},enumerable:false,configurable:true});return e}();CalciteColorPicker.style=calciteColorPickerCss;var CSS$1={container:"container",preview:"preview",input:"input"};var calciteColorPickerHexInputCss="@-webkit-keyframes in{0%{opacity:0}100%{opacity:1}}@keyframes in{0%{opacity:0}100%{opacity:1}}@-webkit-keyframes in-down{0%{opacity:0;-webkit-transform:translate3D(0, -5px, 0);transform:translate3D(0, -5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@keyframes in-down{0%{opacity:0;-webkit-transform:translate3D(0, -5px, 0);transform:translate3D(0, -5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@-webkit-keyframes in-up{0%{opacity:0;-webkit-transform:translate3D(0, 5px, 0);transform:translate3D(0, 5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@keyframes in-up{0%{opacity:0;-webkit-transform:translate3D(0, 5px, 0);transform:translate3D(0, 5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@-webkit-keyframes in-scale{0%{opacity:0;-webkit-transform:scale3D(0.95, 0.95, 1);transform:scale3D(0.95, 0.95, 1)}100%{opacity:1;-webkit-transform:scale3D(1, 1, 1);transform:scale3D(1, 1, 1)}}@keyframes in-scale{0%{opacity:0;-webkit-transform:scale3D(0.95, 0.95, 1);transform:scale3D(0.95, 0.95, 1)}100%{opacity:1;-webkit-transform:scale3D(1, 1, 1);transform:scale3D(1, 1, 1)}}:root{--calcite-animation-timing:calc(150ms * var(--calcite-internal-duration-factor));--calcite-internal-duration-factor:var(--calcite-duration-factor, 1);--calcite-internal-animation-timing-fast:calc(100ms * var(--calcite-internal-duration-factor));--calcite-internal-animation-timing-medium:calc(200ms * var(--calcite-internal-duration-factor));--calcite-internal-animation-timing-slow:calc(300ms * var(--calcite-internal-duration-factor))}.calcite-animate{opacity:0;-webkit-animation-fill-mode:both;animation-fill-mode:both;-webkit-animation-duration:var(--calcite-animation-timing);animation-duration:var(--calcite-animation-timing)}.calcite-animate__in{-webkit-animation-name:in;animation-name:in}.calcite-animate__in-down{-webkit-animation-name:in-down;animation-name:in-down}.calcite-animate__in-up{-webkit-animation-name:in-up;animation-name:in-up}.calcite-animate__in-scale{-webkit-animation-name:in-scale;animation-name:in-scale}:root{--calcite-popper-transition:var(--calcite-animation-timing)}:host([hidden]){display:none}:host{display:block}.container{display:inline-grid;width:100%;-ms-flex-align:center;align-items:center;grid-template-columns:1fr auto}.preview{grid-column:2/3;pointer-events:none;margin-top:0px;margin-bottom:0px;margin-left:0.25rem;margin-right:0.25rem;display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;z-index:1}.preview,.input{grid-row:1}.input{grid-column:1/3;width:100%;text-transform:uppercase}";var DEFAULT_COLOR=color();var CalciteColorPickerHexInput=function(){function e(e){var r=this;registerInstance(this,e);this.calciteColorPickerHexInputChange=createEvent(this,"calciteColorPickerHexInputChange",7);this.allowEmpty=false;this.intlHex=TEXT.hex;this.intlNoColor=TEXT.noColor;this.scale="m";this.value=normalizeHex(DEFAULT_COLOR.hex());this.onCalciteInputBlur=function(){var e=r.inputNode;var t=e.value;var a="#"+t;var n=r.allowEmpty&&!t;if(n||isValidHex(a)&&isLonghandHex(a)){return}e.value=r.allowEmpty&&!r.internalColor?"":r.formatForInternalInput(rgbToHex(r.internalColor.object()))};this.onInputChange=function(){var e=r.inputNode.value;var t;if(e){var a=e;var n=hexToRGB("#"+a);if(!n){return}t=normalizeHex(a)}else if(r.allowEmpty){t=null}r.value=t;r.calciteColorPickerHexInputChange.emit()};this.internalColor=DEFAULT_COLOR;this.previousNonNullValue=this.value;this.storeInputRef=function(e){r.inputNode=e}}e.prototype.connectedCallback=function(){var e=this,r=e.allowEmpty,t=e.value;if(t){var a=normalizeHex(t);if(isValidHex(a)){this.internalColor=color(a);this.value=a}return}if(r){this.internalColor=null;this.value=null}};e.prototype.handleValueChange=function(e,r){if(e){var t=normalizeHex(e);if(isValidHex(t)){var a=this.internalColor;var n=!a||t!==normalizeHex(a.hex());this.internalColor=color(t);this.previousNonNullValue=t;this.value=t;if(n){this.calciteColorPickerHexInputChange.emit()}return}}else if(this.allowEmpty){this.internalColor=null;this.value=null;this.calciteColorPickerHexInputChange.emit();return}this.value=r};e.prototype.onInputKeyDown=function(e){var r=e.altKey,t=e.ctrlKey,a=e.metaKey,n=e.shiftKey;var o=this,i=o.internalColor,l=o.value;var s=e.key;if(s==="Tab"||s==="Enter"){this.onInputChange();return}var c=s==="ArrowDown"||s==="ArrowUp";if(c){if(!l){this.value=this.previousNonNullValue;e.preventDefault();return}var h=s==="ArrowUp"?1:-1;var u=n?10:1;this.value=normalizeHex(this.nudgeRGBChannels(i,u*h).hex());e.preventDefault();return}var d=r||t||a;var v=s.length===1;var f=hexChar.test(s);if(v&&!d&&!f){e.preventDefault()}};e.prototype.render=function(){var e=this,r=e.intlHex,t=e.value;var a=this.formatForInternalInput(t);return h("div",{class:CSS$1.container},h("calcite-input",{class:CSS$1.input,label:r,maxLength:6,onCalciteInputBlur:this.onCalciteInputBlur,onCalciteInputChange:this.onInputChange,prefixText:"#",ref:this.storeInputRef,scale:this.scale,value:a}),a?h("calcite-color-picker-swatch",{active:true,class:CSS$1.preview,color:"#"+a,scale:this.scale}):null)};e.prototype.setFocus=function(){return __awaiter(this,void 0,void 0,(function(){return __generator(this,(function(e){focusElement(this.inputNode);return[2]}))}))};e.prototype.formatForInternalInput=function(e){return e?e.replace("#",""):""};e.prototype.nudgeRGBChannels=function(e,r){return color.rgb(e.array().map((function(e){return e+r})))};Object.defineProperty(e.prototype,"el",{get:function(){return getElement(this)},enumerable:false,configurable:true});Object.defineProperty(e,"watchers",{get:function(){return{value:["handleValueChange"]}},enumerable:false,configurable:true});return e}();CalciteColorPickerHexInput.style=calciteColorPickerHexInputCss;var CSS={swatch:"swatch",noColorIcon:"no-color-icon"};var COLORS={borderLight:"rgba(0, 0, 0, 0.3)",borderDark:"rgba(255, 255, 255, 0.15)"};var calciteColorPickerSwatchCss="@-webkit-keyframes in{0%{opacity:0}100%{opacity:1}}@keyframes in{0%{opacity:0}100%{opacity:1}}@-webkit-keyframes in-down{0%{opacity:0;-webkit-transform:translate3D(0, -5px, 0);transform:translate3D(0, -5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@keyframes in-down{0%{opacity:0;-webkit-transform:translate3D(0, -5px, 0);transform:translate3D(0, -5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@-webkit-keyframes in-up{0%{opacity:0;-webkit-transform:translate3D(0, 5px, 0);transform:translate3D(0, 5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@keyframes in-up{0%{opacity:0;-webkit-transform:translate3D(0, 5px, 0);transform:translate3D(0, 5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@-webkit-keyframes in-scale{0%{opacity:0;-webkit-transform:scale3D(0.95, 0.95, 1);transform:scale3D(0.95, 0.95, 1)}100%{opacity:1;-webkit-transform:scale3D(1, 1, 1);transform:scale3D(1, 1, 1)}}@keyframes in-scale{0%{opacity:0;-webkit-transform:scale3D(0.95, 0.95, 1);transform:scale3D(0.95, 0.95, 1)}100%{opacity:1;-webkit-transform:scale3D(1, 1, 1);transform:scale3D(1, 1, 1)}}:root{--calcite-animation-timing:calc(150ms * var(--calcite-internal-duration-factor));--calcite-internal-duration-factor:var(--calcite-duration-factor, 1);--calcite-internal-animation-timing-fast:calc(100ms * var(--calcite-internal-duration-factor));--calcite-internal-animation-timing-medium:calc(200ms * var(--calcite-internal-duration-factor));--calcite-internal-animation-timing-slow:calc(300ms * var(--calcite-internal-duration-factor))}.calcite-animate{opacity:0;-webkit-animation-fill-mode:both;animation-fill-mode:both;-webkit-animation-duration:var(--calcite-animation-timing);animation-duration:var(--calcite-animation-timing)}.calcite-animate__in{-webkit-animation-name:in;animation-name:in}.calcite-animate__in-down{-webkit-animation-name:in-down;animation-name:in-down}.calcite-animate__in-up{-webkit-animation-name:in-up;animation-name:in-up}.calcite-animate__in-scale{-webkit-animation-name:in-scale;animation-name:in-scale}:root{--calcite-popper-transition:var(--calcite-animation-timing)}:host([hidden]){display:none}:host{position:relative;display:-ms-inline-flexbox;display:inline-flex}:host([scale=s]){height:1.25rem;width:1.25rem}:host([scale=m]){height:1.5rem;width:1.5rem}:host([scale=l]){height:2rem;width:2rem}.swatch{overflow:visible;height:inherit;width:inherit}.swatch rect{-webkit-transition-property:all;transition-property:all;-webkit-transition-duration:150ms;transition-duration:150ms;-webkit-transition-timing-function:cubic-bezier(0.4, 0, 0.2, 1);transition-timing-function:cubic-bezier(0.4, 0, 0.2, 1)}.no-color-icon{position:absolute;top:0px;right:0px;bottom:0px;left:0px;height:100%;width:100%}";var CalciteColorPickerSwatch=function(){function e(e){registerInstance(this,e);this.active=false;this.scale="m"}e.prototype.handleColorChange=function(e){this.internalColor=color(e)};e.prototype.componentWillLoad=function(){this.handleColorChange(this.color)};e.prototype.render=function(){var e=this,r=e.active,t=e.el,a=e.internalColor;var n=r?"100%":"0";var o=a.hex();var i=getThemeName(t);var l=i==="light"?COLORS.borderLight:COLORS.borderDark;return h("svg",{class:CSS.swatch,xmlns:"http://www.w3.org/2000/svg"},h("title",null,o),h("rect",{fill:o,height:"100%",id:"swatch",rx:n,stroke:l,"stroke-width":"2",style:{"clip-path":"inset(0 round "+n+")"},width:"100%"}))};Object.defineProperty(e.prototype,"el",{get:function(){return getElement(this)},enumerable:false,configurable:true});Object.defineProperty(e,"watchers",{get:function(){return{color:["handleColorChange"]}},enumerable:false,configurable:true});return e}();CalciteColorPickerSwatch.style=calciteColorPickerSwatchCss;export{CalciteColorPicker as calcite_color_picker,CalciteColorPickerHexInput as calcite_color_picker_hex_input,CalciteColorPickerSwatch as calcite_color_picker_swatch};
|
|
@@ -2,4 +2,4 @@ var __awaiter=this&&this.__awaiter||function(e,t,i,n){function a(e){return e ins
|
|
|
2
2
|
/*!
|
|
3
3
|
* All material copyright ESRI, All Rights Reserved, unless otherwise specified.
|
|
4
4
|
* See https://github.com/Esri/calcite-components/blob/master/LICENSE.md for details.
|
|
5
|
-
*/import{r as registerInstance,c as createEvent,h,H as Host,g as getElement}from"./index-9de00868.js";import{a as isSymbol,S as Symbol,d as debounce}from"./debounce-79648d42.js";import{i as isArray,f as forIn}from"./forIn-48d8fb84.js";import{u as updatePopper,c as createPopper,C as CSS$2}from"./popper-f5caedc4.js";import{g as guid}from"./guid-196bd5ea.js";import{n as nodeListToArray,d as getElementProp}from"./dom-f24e866c.js";import{c as connectLabel,d as disconnectLabel,g as getLabelText}from"./label-5559055d.js";import{c as connectForm,a as afterConnectDefaultValueSet,d as disconnectForm,H as HiddenFormInputSlot}from"./form-160b0fb5.js";import{c as createObserver}from"./observers-8f0bc419.js";function arrayMap(e,t){var i=-1,n=e==null?0:e.length,a=Array(n);while(++i<n){a[i]=t(e[i],i,e)}return a}var INFINITY=1/0;var symbolProto=Symbol?Symbol.prototype:undefined,symbolToString=symbolProto?symbolProto.toString:undefined;function baseToString(e){if(typeof e=="string"){return e}if(isArray(e)){return arrayMap(e,baseToString)+""}if(isSymbol(e)){return symbolToString?symbolToString.call(e):""}var t=e+"";return t=="0"&&1/e==-INFINITY?"-0":t}function toString(e){return e==null?"":baseToString(e)}var reRegExpChar=/[\\^$.*+?()[\]{}|]/g,reHasRegExpChar=RegExp(reRegExpChar.source);function escapeRegExp(e){e=toString(e);return e&&reHasRegExpChar.test(e)?e.replace(reRegExpChar,"\\$&"):e}var filter=function(e,t){var i=escapeRegExp(t);var n=new RegExp(i,"i");if(e.length===0){console.warn("No data was passed to the filter function.\n The data argument should be an array of objects")}var a=function(e,t){var i;if((i=e)===null||i===void 0?void 0:i.constant){return true}var n=false;forIn(e,(function(e){if(typeof e==="function"){return}if(Array.isArray(e)||typeof e==="object"&&e!==null){if(a(e,t)){n=true}}else if(t.test(e)){n=true}}));return n};var o=e.filter((function(e){return a(e,n)}));return o};var ComboboxItem="CALCITE-COMBOBOX-ITEM";var ComboboxItemGroup="CALCITE-COMBOBOX-ITEM-GROUP";var ComboboxChildSelector=ComboboxItem+", "+ComboboxItemGroup;var ComboboxDefaultPlacement="bottom-leading";function getAncestors(e){var t,i;var n=(t=e.parentElement)===null||t===void 0?void 0:t.closest(ComboboxChildSelector);var a=(i=n===null||n===void 0?void 0:n.parentElement)===null||i===void 0?void 0:i.closest(ComboboxChildSelector);return[n,a].filter((function(e){return e}))}function getItemAncestors(e){var t;return((t=e.ancestors)===null||t===void 0?void 0:t.filter((function(e){return e.nodeName==="CALCITE-COMBOBOX-ITEM"})))||[]}function getItemChildren(e){return nodeListToArray(e.querySelectorAll("calcite-combobox-item"))}function hasActiveChildren(e){var t=nodeListToArray(e.querySelectorAll("calcite-combobox-item"));return t.filter((function(e){return e.selected})).length>0}function getDepth(e){var t=document.evaluate("ancestor::calcite-combobox-item | ancestor::calcite-combobox-item-group",e,null,XPathResult.UNORDERED_NODE_SNAPSHOT_TYPE,null);return t.snapshotLength}var calciteComboboxCss="@-webkit-keyframes in{0%{opacity:0}100%{opacity:1}}@keyframes in{0%{opacity:0}100%{opacity:1}}@-webkit-keyframes in-down{0%{opacity:0;-webkit-transform:translate3D(0, -5px, 0);transform:translate3D(0, -5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@keyframes in-down{0%{opacity:0;-webkit-transform:translate3D(0, -5px, 0);transform:translate3D(0, -5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@-webkit-keyframes in-up{0%{opacity:0;-webkit-transform:translate3D(0, 5px, 0);transform:translate3D(0, 5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@keyframes in-up{0%{opacity:0;-webkit-transform:translate3D(0, 5px, 0);transform:translate3D(0, 5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@-webkit-keyframes in-scale{0%{opacity:0;-webkit-transform:scale3D(0.95, 0.95, 1);transform:scale3D(0.95, 0.95, 1)}100%{opacity:1;-webkit-transform:scale3D(1, 1, 1);transform:scale3D(1, 1, 1)}}@keyframes in-scale{0%{opacity:0;-webkit-transform:scale3D(0.95, 0.95, 1);transform:scale3D(0.95, 0.95, 1)}100%{opacity:1;-webkit-transform:scale3D(1, 1, 1);transform:scale3D(1, 1, 1)}}:root{--calcite-animation-timing:calc(150ms * var(--calcite-internal-duration-factor));--calcite-internal-duration-factor:var(--calcite-duration-factor, 1);--calcite-internal-animation-timing-fast:calc(100ms * var(--calcite-internal-duration-factor));--calcite-internal-animation-timing-medium:calc(200ms * var(--calcite-internal-duration-factor));--calcite-internal-animation-timing-slow:calc(300ms * var(--calcite-internal-duration-factor))}.calcite-animate{opacity:0;-webkit-animation-fill-mode:both;animation-fill-mode:both;-webkit-animation-duration:var(--calcite-animation-timing);animation-duration:var(--calcite-animation-timing)}.calcite-animate__in{-webkit-animation-name:in;animation-name:in}.calcite-animate__in-down{-webkit-animation-name:in-down;animation-name:in-down}.calcite-animate__in-up{-webkit-animation-name:in-up;animation-name:in-up}.calcite-animate__in-scale{-webkit-animation-name:in-scale;animation-name:in-scale}:root{--calcite-popper-transition:150ms ease-in-out}:host([hidden]){display:none}:host{display:block;position:relative}:host([disabled]){pointer-events:none;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;opacity:0.5}:host([scale=s]){font-size:var(--calcite-font-size--2);--calcite-combobox-item-spacing-unit-l:0.5rem;--calcite-combobox-item-spacing-unit-s:0.25rem;--calcite-combobox-input-height:1.5rem}:host([scale=m]){font-size:var(--calcite-font-size--1);--calcite-combobox-item-spacing-unit-l:0.75rem;--calcite-combobox-item-spacing-unit-s:0.5rem;--calcite-combobox-input-height:2rem}:host([scale=l]){font-size:var(--calcite-font-size-0);--calcite-combobox-item-spacing-unit-l:1rem;--calcite-combobox-item-spacing-unit-s:0.75rem;--calcite-combobox-input-height:2.75rem}.wrapper{display:-ms-flexbox;display:flex;background-color:var(--calcite-ui-foreground-1);color:var(--calcite-ui-text-1);outline-offset:0;outline-color:transparent;-webkit-transition:outline-offset 100ms ease-in-out, outline-color 100ms ease-in-out;transition:outline-offset 100ms ease-in-out, outline-color 100ms ease-in-out;-webkit-box-shadow:inset 0 0 0 1px var(--calcite-ui-border-input);box-shadow:inset 0 0 0 1px var(--calcite-ui-border-input);padding:0 var(--calcite-combobox-item-spacing-unit-l) 0 var(--calcite-combobox-item-spacing-unit-l)}:host(:focus-within) .wrapper,.wrapper--active{outline:2px solid var(--calcite-ui-brand);outline-offset:-2px}.wrapper--single{padding:0 var(--calcite-combobox-item-spacing-unit-l);cursor:pointer;-ms-flex-wrap:nowrap;flex-wrap:nowrap}.grid-input{display:-ms-flexbox;display:flex;-ms-flex-positive:1;flex-grow:1;-ms-flex-wrap:wrap;flex-wrap:wrap;-ms-flex-align:center;align-items:center;padding:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.input{-ms-flex-positive:1;flex-grow:1;font-family:inherit;padding:0;background-color:transparent;border-style:none;color:var(--calcite-ui-text-1);-webkit-appearance:none;-moz-appearance:none;appearance:none;font-size:inherit;height:var(--calcite-combobox-input-height);line-height:var(--calcite-combobox-input-height);min-width:120px;margin-bottom:var(--calcite-combobox-item-spacing-unit-s)}.input:focus{outline:2px solid transparent;outline-offset:2px}.input--transparent{opacity:0}.input--single{margin-bottom:0;margin-top:0;padding:0}.wrapper--active .input-single{cursor:text}.input--hidden{width:0;min-width:0;opacity:0;pointer-events:none}.input--icon{padding:0 var(--calcite-combobox-item-spacing-unit-l)}.input-wrap{display:-ms-flexbox;display:flex;-ms-flex-positive:1;flex-grow:1}.input-wrap--single{-ms-flex:1 1 auto;flex:1 1 auto;overflow:hidden}.label{padding:0;display:-ms-flexbox;display:flex;font-weight:var(--calcite-font-weight-normal);-ms-flex:1 1 auto;flex:1 1 auto;pointer-events:none;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;max-width:100%;height:var(--calcite-combobox-input-height);line-height:var(--calcite-combobox-input-height)}.label--spaced{padding-top:0;padding-bottom:0;padding-left:var(--calcite-combobox-item-spacing-unit-l);padding-right:var(--calcite-combobox-item-spacing-unit-l)}.icon-end,.icon-start{cursor:pointer;display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;width:1rem}.icon-end{-ms-flex:none;flex:none}.popper-container{width:100%;display:block;position:absolute;z-index:900;-webkit-transform:scale(0);transform:scale(0);visibility:hidden;pointer-events:none}.popper-container .calcite-popper-anim{position:relative;z-index:1;-webkit-transition:var(--calcite-popper-transition);transition:var(--calcite-popper-transition);visibility:hidden;-webkit-transition-property:visibility, opacity, -webkit-transform;transition-property:visibility, opacity, -webkit-transform;transition-property:transform, visibility, opacity;transition-property:transform, visibility, opacity, -webkit-transform;opacity:0;-webkit-box-shadow:0 0 16px 0 rgba(0, 0, 0, 0.16);box-shadow:0 0 16px 0 rgba(0, 0, 0, 0.16);border-radius:0.25rem}.popper-container[data-popper-placement^=bottom] .calcite-popper-anim{-webkit-transform:translateY(-5px);transform:translateY(-5px)}.popper-container[data-popper-placement^=top] .calcite-popper-anim{-webkit-transform:translateY(5px);transform:translateY(5px)}.popper-container[data-popper-placement^=left] .calcite-popper-anim{-webkit-transform:translateX(5px);transform:translateX(5px)}.popper-container[data-popper-placement^=right] .calcite-popper-anim{-webkit-transform:translateX(-5px);transform:translateX(-5px)}.popper-container[data-popper-placement] .calcite-popper-anim--active{opacity:1;visibility:visible;-webkit-transform:translate(0);transform:translate(0)}.popper-container--active{pointer-events:initial;visibility:visible}.screen-readers-only{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0, 0, 0, 0);white-space:nowrap;border-width:0}.list-container{overflow-y:auto;max-height:100vh;background-color:var(--calcite-ui-foreground-1);width:var(--calcite-dropdown-width)}.list{display:block;margin:0;padding:0}.list--hide{height:0;overflow:hidden}.chip{margin-block:calc(var(--calcite-combobox-item-spacing-unit-s) / 2) 0;margin-inline:0 var(--calcite-combobox-item-spacing-unit-s);max-width:100%}.chip--active{background-color:var(--calcite-ui-foreground-3)}.chip:last-of-type{-webkit-margin-end:0;margin-inline-end:0}.item{display:block}::slotted(input[slot=hidden-form-input]){bottom:0 !important;left:0 !important;margin:0 !important;opacity:0 !important;outline:none !important;padding:0 !important;position:absolute !important;right:0 !important;top:0 !important;-webkit-transform:none !important;transform:none !important;-webkit-appearance:none !important;z-index:-1 !important}";var isGroup=function(e){return e.tagName===ComboboxItemGroup};var CalciteCombobox=function(){function e(e){var t=this;registerInstance(this,e);this.calciteLookupChange=createEvent(this,"calciteLookupChange",7);this.calciteComboboxChange=createEvent(this,"calciteComboboxChange",7);this.calciteComboboxFilterChange=createEvent(this,"calciteComboboxFilterChange",7);this.calciteComboboxChipDismiss=createEvent(this,"calciteComboboxChipDismiss",7);this.calciteComboboxOpen=createEvent(this,"calciteComboboxOpen",7);this.calciteComboboxClose=createEvent(this,"calciteComboboxClose",7);this.active=false;this.disabled=false;this.maxItems=0;this.overlayPositioning="absolute";this.required=false;this.selectionMode="multi";this.scale="m";this.value=null;this.internalValueChangeFlag=false;this.items=[];this.groupItems=[];this.selectedItems=[];this.visibleItems=[];this.hideList=!this.active;this.activeItemIndex=-1;this.activeChipIndex=-1;this.activeDescendant="";this.text="";this.open=this.active;this.maxScrollerHeight=0;this.textInput=null;this.mutationObserver=createObserver("mutation",(function(){return t.updateItems()}));this.guid=guid();this.inputHeight=0;this.ignoreSelectedEventsFlag=false;this.activeTransitionProp="opacity";this.getValue=function(){var e=t.selectedItems.map((function(e){return e===null||e===void 0?void 0:e.value.toString()}));return(e===null||e===void 0?void 0:e.length)?e.length>1?e:e[0]:""};this.onLabelClick=function(){t.setFocus()};this.keydownHandler=function(e){var i=e.key;switch(i){case"Tab":t.activeChipIndex=-1;t.activeItemIndex=-1;if(t.allowCustomValues&&t.text){t.addCustomChip(t.text,true);e.preventDefault()}else{t.active=false}break;case"ArrowLeft":t.previousChip();break;case"ArrowRight":t.nextChip();break;case"ArrowUp":e.preventDefault();t.active=true;t.shiftActiveItemIndex(-1);break;case"ArrowDown":e.preventDefault();t.active=true;t.shiftActiveItemIndex(1);break;case"Home":t.active=true;t.updateActiveItemIndex(0);break;case"End":t.active=true;t.updateActiveItemIndex(t.visibleItems.length-1);break;case"Escape":t.active=false;break;case"Enter":if(t.activeItemIndex>-1){t.toggleSelection(t.visibleItems[t.activeItemIndex])}else if(t.activeChipIndex>-1){t.removeActiveChip()}else if(t.allowCustomValues&&t.text){t.addCustomChip(t.text,true)}break;case"Delete":case"Backspace":if(t.activeChipIndex>-1){t.removeActiveChip()}else if(!t.text&&t.isMulti()){t.removeLastChip()}break;default:if(!t.active){t.setFocus()}break}};this.toggleCloseEnd=function(){t.hideList=true;t.el.removeEventListener("calciteComboboxClose",t.toggleCloseEnd)};this.toggleOpenEnd=function(){t.hideList=false;t.el.removeEventListener("calciteComboboxOpen",t.toggleOpenEnd)};this.transitionEnd=function(e){if(e.propertyName===t.activeTransitionProp){t.active?t.calciteComboboxOpen.emit():t.calciteComboboxClose.emit()}};this.setMaxScrollerHeight=function(){if(t.active){t.maxScrollerHeight=t.getMaxScrollerHeight(t.getCombinedItems())}};this.calciteChipDismissHandler=function(e,i){t.active=false;var n=t.items.find((function(e){return e===i}));if(n){t.toggleSelection(n,false)}t.calciteComboboxChipDismiss.emit(e.detail)};this.setFocusClick=function(e){if(e.composedPath().some((function(e){return e.tagName==="CALCITE-CHIP"}))){return}t.setFocus()};this.setInactiveIfNotContained=function(e){var i=e.composedPath();if(!t.active&&!t.open||i.includes(t.el)||i.includes(t.referenceEl)){return}if(t.allowCustomValues&&t.text){t.addCustomChip(t.text)}if(t.selectionMode==="single"){if(t.textInput){t.textInput.value=""}t.text="";t.filterItems("");t.updateActiveItemIndex(-1)}t.active=false;t.open=false};this.setMenuEl=function(e){t.menuEl=e};this.setListContainerEl=function(e){t.listContainerEl=e};this.setReferenceEl=function(e){t.referenceEl=e};this.inputHandler=function(e){var i=e.target.value;t.text=i;t.filterItems(i);if(i){t.activeChipIndex=-1}};this.filterItems=function(){var e=function(e,t){return e&&t.some((function(t){var i=t.label,n=t.value;if(isGroup(e)){return n===e.label||n===e.label}return n===e.textLabel||n===e.value||i===e.textLabel||i===e.value}))};return debounce((function(i){var n=filter(t.data,i);var a=t.getCombinedItems();a.forEach((function(t){var i=!e(t,n);t.hidden=i;var a=t.ancestors,o=a[0],r=a[1];if(e(o,n)||e(r,n)){t.hidden=false}if(!i){t.ancestors.forEach((function(e){return e.hidden=false}))}}));t.visibleItems=t.getVisibleItems();t.calciteComboboxFilterChange.emit({visibleItems:__spreadArray([],t.visibleItems),text:i})}),100)}();this.internalCalciteLookupChangeEvent=function(){t.calciteLookupChange.emit(t.selectedItems)};this.emitCalciteLookupChange=debounce(this.internalCalciteLookupChangeEvent,0);this.internalComboboxChangeEvent=function(){var e=t.selectedItems;t.calciteComboboxChange.emit({selectedItems:e})};this.emitComboboxChange=debounce(this.internalComboboxChangeEvent,0);this.updateItems=function(){t.items=t.getItems();t.groupItems=t.getGroupItems();t.data=t.getData();t.selectedItems=t.getSelectedItems();t.visibleItems=t.getVisibleItems();t.needsIcon=t.getNeedsIcon();if(!t.allowCustomValues){t.setMaxScrollerHeight()}};this.comboboxFocusHandler=function(){var e;t.active=true;(e=t.textInput)===null||e===void 0?void 0:e.focus()};this.comboboxBlurHandler=function(e){t.setInactiveIfNotContained(e)}}e.prototype.activeHandler=function(e,t){var i=this;if(t&&!e){this.el.addEventListener("calciteComboboxClose",this.toggleCloseEnd);this.open=false}else if(!t&&e){this.el.addEventListener("calciteComboboxOpen",this.toggleOpenEnd);requestAnimationFrame((function(){i.reposition();i.setMaxScrollerHeight();i.open=true}))}this.reposition();this.setMaxScrollerHeight()};e.prototype.maxItemsHandler=function(){this.setMaxScrollerHeight()};e.prototype.valueHandler=function(e){if(!this.internalValueChangeFlag){var t=this.getItems();if(Array.isArray(e)){t.forEach((function(t){return t.selected=e.includes(t.value)}))}else if(e){t.forEach((function(t){return t.selected=e===t.value}))}else{t.forEach((function(e){return e.selected=false}))}this.updateItems()}};e.prototype.documentClickHandler=function(e){this.setInactiveIfNotContained(e)};e.prototype.calciteComboboxItemChangeHandler=function(e){if(this.ignoreSelectedEventsFlag){return}var t=e.target;this.toggleSelection(t,t.selected)};e.prototype.reposition=function(){return __awaiter(this,void 0,void 0,(function(){var e,t,i,n,a;return __generator(this,(function(o){switch(o.label){case 0:e=this,t=e.popper,i=e.menuEl;n=this.getModifiers();if(!t)return[3,2];return[4,updatePopper({el:i,modifiers:n,placement:ComboboxDefaultPlacement,popper:t})];case 1:a=o.sent();return[3,3];case 2:a=this.createPopper();o.label=3;case 3:a;return[2]}}))}))};e.prototype.setFocus=function(){return __awaiter(this,void 0,void 0,(function(){var e;return __generator(this,(function(t){this.active=true;(e=this.textInput)===null||e===void 0?void 0:e.focus();this.activeChipIndex=-1;this.activeItemIndex=-1;return[2]}))}))};e.prototype.connectedCallback=function(){var e;this.internalValueChangeFlag=true;this.value=this.getValue();this.internalValueChangeFlag=false;(e=this.mutationObserver)===null||e===void 0?void 0:e.observe(this.el,{childList:true,subtree:true});this.createPopper();connectLabel(this);connectForm(this)};e.prototype.componentWillLoad=function(){this.updateItems()};e.prototype.componentDidLoad=function(){afterConnectDefaultValueSet(this,this.getValue())};e.prototype.componentDidRender=function(){if(this.el.offsetHeight!==this.inputHeight){this.reposition();this.inputHeight=this.el.offsetHeight}};e.prototype.disconnectedCallback=function(){var e;(e=this.mutationObserver)===null||e===void 0?void 0:e.disconnect();this.destroyPopper();disconnectLabel(this);disconnectForm(this)};e.prototype.selectedItemsHandler=function(){this.internalValueChangeFlag=true;this.value=this.getValue();this.internalValueChangeFlag=false};e.prototype.textHandler=function(){this.updateActiveItemIndex(-1)};e.prototype.getModifiers=function(){var e={name:"flip",enabled:true};e.options={fallbackPlacements:["top-start","top","top-end","bottom-start","bottom","bottom-end"]};return[e]};e.prototype.createPopper=function(){this.destroyPopper();var e=this,t=e.menuEl,i=e.referenceEl,n=e.overlayPositioning;var a=this.getModifiers();this.popper=createPopper({el:t,modifiers:a,overlayPositioning:n,placement:ComboboxDefaultPlacement,referenceEl:i})};e.prototype.destroyPopper=function(){var e=this.popper;if(e){e.destroy()}this.popper=null};e.prototype.getMaxScrollerHeight=function(e){var t=this;var i=this.maxItems;var n=0;var a=0;e.forEach((function(e){if(n<i&&i>0){var o=t.calculateSingleItemHeight(e);if(o>0){a+=o;n++}}}));return a};e.prototype.calculateSingleItemHeight=function(e){var t=e.offsetHeight;var i=Array.from(e.querySelectorAll(ComboboxChildSelector));i.map((function(e){return e===null||e===void 0?void 0:e.offsetHeight})).forEach((function(e){t-=e}));return t};e.prototype.getCombinedItems=function(){return __spreadArray(__spreadArray([],this.groupItems),this.items)};e.prototype.toggleSelection=function(e,t){if(t===void 0){t=!e.selected}if(!e){return}if(this.isMulti()){e.selected=t;this.updateAncestors(e);this.selectedItems=this.getSelectedItems();this.emitCalciteLookupChange();this.emitComboboxChange();this.resetText();this.filterItems("")}else{this.ignoreSelectedEventsFlag=true;this.items.forEach((function(i){return i.selected=i===e?t:false}));this.ignoreSelectedEventsFlag=false;this.selectedItems=this.getSelectedItems();this.emitComboboxChange();if(this.textInput){this.textInput.value=e.textLabel}this.active=false;this.updateActiveItemIndex(-1);this.resetText();this.filterItems("")}};e.prototype.updateAncestors=function(e){if(this.selectionMode!=="ancestors"){return}var t=getItemAncestors(e);var i=getItemChildren(e);if(e.selected){t.forEach((function(e){e.selected=true}))}else{i.forEach((function(e){return e.selected=false}));__spreadArray([],t).forEach((function(e){if(!hasActiveChildren(e)){e.selected=false}}))}};e.prototype.getVisibleItems=function(){return this.items.filter((function(e){return!e.hidden}))};e.prototype.getSelectedItems=function(){var e=this;return!this.isMulti()?[this.items.find((function(e){return e.selected}))]:this.items.filter((function(t){return t.selected&&(e.selectionMode!=="ancestors"||!hasActiveChildren(t))})).sort((function(t,i){var n=e.selectedItems.indexOf(t);var a=e.selectedItems.indexOf(i);if(n>-1&&a>-1){return n-a}return a-n}))};e.prototype.getData=function(){return this.items.map((function(e){return{constant:e.constant,value:e.value,label:e.textLabel,guid:e.guid}}))};e.prototype.getNeedsIcon=function(){return this.selectionMode==="single"&&this.items.some((function(e){return e.icon}))};e.prototype.resetText=function(){if(this.textInput){this.textInput.value=""}this.text=""};e.prototype.getItems=function(){var e=Array.from(this.el.querySelectorAll(ComboboxItem));return e.filter((function(e){return!e.disabled}))};e.prototype.getGroupItems=function(){return Array.from(this.el.querySelectorAll(ComboboxItemGroup))};e.prototype.addCustomChip=function(e,t){var i=this.items.find((function(t){return t.textLabel===e}));if(i){this.toggleSelection(i,true)}else{var n=document.createElement(ComboboxItem);n.value=e;n.textLabel=e;n.guid=guid();n.selected=true;this.el.appendChild(n);this.resetText();if(t){this.setFocus()}this.updateItems();this.filterItems("");this.emitCalciteLookupChange();this.emitComboboxChange()}};e.prototype.removeActiveChip=function(){this.toggleSelection(this.selectedItems[this.activeChipIndex],false);this.setFocus()};e.prototype.removeLastChip=function(){this.toggleSelection(this.selectedItems[this.selectedItems.length-1],false);this.setFocus()};e.prototype.previousChip=function(){if(this.text){return}var e=this.selectedItems.length-1;var t=this.activeChipIndex;this.activeChipIndex=t===-1?e:Math.max(t-1,0);this.updateActiveItemIndex(-1);this.focusChip()};e.prototype.nextChip=function(){if(this.text||this.activeChipIndex===-1){return}var e=this.selectedItems.length-1;var t=this.activeChipIndex+1;if(t>e){this.activeChipIndex=-1;this.setFocus()}else{this.activeChipIndex=t;this.focusChip()}this.updateActiveItemIndex(-1)};e.prototype.focusChip=function(){var e;var t=(e=this.selectedItems[this.activeChipIndex])===null||e===void 0?void 0:e.guid;var i=this.referenceEl.querySelector("#chip-"+t);i===null||i===void 0?void 0:i.setFocus()};e.prototype.shiftActiveItemIndex=function(e){var t=this.visibleItems.length;var i=(this.activeItemIndex+t+e)%t;this.updateActiveItemIndex(i);var n=this.visibleItems[this.activeItemIndex];var a=this.calculateSingleItemHeight(n);var o=this.listContainerEl,r=o.offsetHeight,s=o.scrollTop;if(r+s<n.offsetTop+a){this.listContainerEl.scrollTop=n.offsetTop-r+a}else if(n.offsetTop<s){this.listContainerEl.scrollTop=n.offsetTop}};e.prototype.updateActiveItemIndex=function(e){var t;this.activeItemIndex=e;var i=null;this.visibleItems.forEach((function(t,n){if(n===e){t.active=true;i=t.guid}else{t.active=false}}));this.activeDescendant=i;if(this.activeItemIndex>-1){this.activeChipIndex=-1;(t=this.textInput)===null||t===void 0?void 0:t.focus()}};e.prototype.isMulti=function(){return this.selectionMode!=="single"};e.prototype.renderChips=function(){var e=this;var t=this,i=t.activeChipIndex,n=t.scale,a=t.selectionMode;return this.selectedItems.map((function(t,o){var r={chip:true,"chip--active":i===o};var s=__spreadArray([],getItemAncestors(t)).reverse();var c=__spreadArray(__spreadArray([],s),[t]).map((function(e){return e.textLabel}));var l=a!=="ancestors"?t.textLabel:c.join(" / ");return h("calcite-chip",{"aria-label":l,class:r,dismissLabel:"remove tag",dismissible:true,icon:t.icon,id:"chip-"+t.guid,key:t.textLabel,onCalciteChipDismiss:function(i){return e.calciteChipDismissHandler(i,t)},scale:n,title:l,value:t.value},l)}))};e.prototype.renderInput=function(){var e=this;var t=this,i=t.active,n=t.disabled,a=t.placeholder,o=t.selectionMode,r=t.needsIcon,s=t.selectedItems;var c=o==="single";var l=s[0];var m=!i&&c&&!!l;return h("span",{class:{"input-wrap":true,"input-wrap--single":c}},m&&h("span",{class:{label:true,"label--spaced":r},key:"label",onFocus:this.comboboxFocusHandler,tabindex:"0"},l.textLabel),h("input",{"aria-activedescendant":this.activeDescendant,"aria-autocomplete":"list","aria-controls":guid,"aria-label":getLabelText(this),class:{input:true,"input--single":true,"input--transparent":this.activeChipIndex>-1,"input--hidden":m,"input--icon":c&&r},disabled:n,id:guid+"-input",key:"input",onBlur:this.comboboxBlurHandler,onFocus:this.comboboxFocusHandler,onInput:this.inputHandler,placeholder:a,ref:function(t){return e.textInput=t},type:"text"}))};e.prototype.renderListBoxOptions=function(){return this.visibleItems.map((function(e){return h("li",{"aria-selected":(!!e.selected).toString(),id:e.guid,role:"option",tabindex:"-1"},e.textLabel)}))};e.prototype.renderPopperContainer=function(){var e;var t=this,i=t.active,n=t.maxScrollerHeight,a=t.setMenuEl,o=t.setListContainerEl,r=t.hideList,s=t.open;var c=(e={"list-container":true},e[CSS$2.animation]=true,e[CSS$2.animationActive]=i,e);var l={maxHeight:n>0?n+"px":""};return h("div",{"aria-hidden":"true",class:{"popper-container":true,"popper-container--active":s},ref:a},h("div",{class:c,onTransitionEnd:this.transitionEnd,ref:o,style:l},h("ul",{class:{list:true,"list--hide":r}},h("slot",null))))};e.prototype.renderIconStart=function(){var e=this,t=e.selectionMode,i=e.needsIcon,n=e.selectedItems;var a=n[0];return t==="single"&&i&&h("span",{class:"icon-start"},(a===null||a===void 0?void 0:a.icon)&&h("calcite-icon",{class:"selected-icon",icon:a.icon,scale:"s"}))};e.prototype.renderIconEnd=function(){return h("span",{class:"icon-end"},h("calcite-icon",{icon:"chevron-down",scale:"s"}))};e.prototype.render=function(){var e=this,t=e.guid,i=e.open,n=e.label;var a=this.selectionMode==="single";var o=t+"-label";return h(Host,{onKeyDown:this.keydownHandler},h("div",{"aria-autocomplete":"list","aria-expanded":i.toString(),"aria-haspopup":"listbox","aria-labelledby":o,"aria-owns":t,class:{wrapper:true,"wrapper--single":a||!this.selectedItems.length,"wrapper--active":i},onClick:this.setFocusClick,ref:this.setReferenceEl,role:"combobox"},h("div",{class:"grid-input"},this.renderIconStart(),!a&&this.renderChips(),h("label",{class:"screen-readers-only",htmlFor:t+"-input",id:o},n),this.renderInput()),this.renderIconEnd()),h("ul",{"aria-labelledby":o,"aria-multiselectable":"true",class:"screen-readers-only",id:t,role:"listbox",tabIndex:-1},this.renderListBoxOptions()),this.renderPopperContainer(),h(HiddenFormInputSlot,{component:this}))};Object.defineProperty(e.prototype,"el",{get:function(){return getElement(this)},enumerable:false,configurable:true});Object.defineProperty(e,"watchers",{get:function(){return{active:["activeHandler"],maxItems:["maxItemsHandler"],value:["valueHandler"],selectedItems:["selectedItemsHandler"],text:["textHandler"]}},enumerable:false,configurable:true});return e}();CalciteCombobox.style=calciteComboboxCss;var CSS$1={icon:"icon",iconActive:"icon--active",custom:"icon--custom",dot:"icon--dot",single:"label--single",label:"label",active:"label--active",selected:"label--selected",title:"title",textContainer:"text-container"};var calciteComboboxItemCss='@charset "UTF-8";@-webkit-keyframes in{0%{opacity:0}100%{opacity:1}}@keyframes in{0%{opacity:0}100%{opacity:1}}@-webkit-keyframes in-down{0%{opacity:0;-webkit-transform:translate3D(0, -5px, 0);transform:translate3D(0, -5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@keyframes in-down{0%{opacity:0;-webkit-transform:translate3D(0, -5px, 0);transform:translate3D(0, -5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@-webkit-keyframes in-up{0%{opacity:0;-webkit-transform:translate3D(0, 5px, 0);transform:translate3D(0, 5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@keyframes in-up{0%{opacity:0;-webkit-transform:translate3D(0, 5px, 0);transform:translate3D(0, 5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@-webkit-keyframes in-scale{0%{opacity:0;-webkit-transform:scale3D(0.95, 0.95, 1);transform:scale3D(0.95, 0.95, 1)}100%{opacity:1;-webkit-transform:scale3D(1, 1, 1);transform:scale3D(1, 1, 1)}}@keyframes in-scale{0%{opacity:0;-webkit-transform:scale3D(0.95, 0.95, 1);transform:scale3D(0.95, 0.95, 1)}100%{opacity:1;-webkit-transform:scale3D(1, 1, 1);transform:scale3D(1, 1, 1)}}:root{--calcite-animation-timing:calc(150ms * var(--calcite-internal-duration-factor));--calcite-internal-duration-factor:var(--calcite-duration-factor, 1);--calcite-internal-animation-timing-fast:calc(100ms * var(--calcite-internal-duration-factor));--calcite-internal-animation-timing-medium:calc(200ms * var(--calcite-internal-duration-factor));--calcite-internal-animation-timing-slow:calc(300ms * var(--calcite-internal-duration-factor))}.calcite-animate{opacity:0;-webkit-animation-fill-mode:both;animation-fill-mode:both;-webkit-animation-duration:var(--calcite-animation-timing);animation-duration:var(--calcite-animation-timing)}.calcite-animate__in{-webkit-animation-name:in;animation-name:in}.calcite-animate__in-down{-webkit-animation-name:in-down;animation-name:in-down}.calcite-animate__in-up{-webkit-animation-name:in-up;animation-name:in-up}.calcite-animate__in-scale{-webkit-animation-name:in-scale;animation-name:in-scale}:root{--calcite-popper-transition:150ms ease-in-out}:host([hidden]){display:none}.scale--s{font-size:var(--calcite-font-size--2);line-height:1rem;--calcite-combobox-item-spacing-unit-l:0.5rem;--calcite-combobox-item-spacing-unit-s:0.25rem;--calcite-combobox-item-spacing-indent:0.5rem}.scale--m{font-size:var(--calcite-font-size--1);line-height:1rem;--calcite-combobox-item-spacing-unit-l:0.75rem;--calcite-combobox-item-spacing-unit-s:0.5rem;--calcite-combobox-item-spacing-indent:0.75rem}.scale--l{font-size:var(--calcite-font-size-0);line-height:1.25rem;--calcite-combobox-item-spacing-unit-l:1rem;--calcite-combobox-item-spacing-unit-s:0.75rem;--calcite-combobox-item-spacing-indent:1rem}.container{--calcite-combobox-item-indent-value:calc(\n var(--calcite-combobox-item-spacing-indent) * var(--calcite-combobox-item-spacing-indent-multiplier)\n )}:host(:focus){-webkit-box-shadow:none;box-shadow:none}:host,ul{display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;margin:0;padding:0;outline:2px solid transparent;outline-offset:2px}.label{display:-ms-flexbox;display:flex;-webkit-box-sizing:border-box;box-sizing:border-box;width:100%;min-width:100%;-ms-flex-align:center;align-items:center;color:var(--calcite-ui-text-3);cursor:pointer;position:relative;-webkit-transition-duration:150ms;transition-duration:150ms;-webkit-transition-timing-function:cubic-bezier(0.4, 0, 0.2, 1);transition-timing-function:cubic-bezier(0.4, 0, 0.2, 1);outline-offset:0;outline-color:transparent;-webkit-transition:outline-offset 100ms ease-in-out, outline-color 100ms ease-in-out;transition:outline-offset 100ms ease-in-out, outline-color 100ms ease-in-out;text-decoration:none;padding:var(--calcite-combobox-item-spacing-unit-s) var(--calcite-combobox-item-spacing-unit-l)}:host([disabled]) .label{cursor:default}.label--selected{color:var(--calcite-ui-text-1);font-weight:var(--calcite-font-weight-medium)}.label--active{outline:2px solid var(--calcite-ui-brand);outline-offset:-2px}.label:hover,.label:active{color:var(--calcite-ui-text-1);background-color:var(--calcite-ui-foreground-2);-webkit-box-shadow:none;box-shadow:none;text-decoration:none}.title{padding:0 var(--calcite-combobox-item-spacing-unit-l)}.icon{display:-ms-inline-flexbox;display:inline-flex;opacity:0;-webkit-transition-duration:150ms;transition-duration:150ms;-webkit-transition-timing-function:cubic-bezier(0.4, 0, 0.2, 1);transition-timing-function:cubic-bezier(0.4, 0, 0.2, 1);color:var(--calcite-ui-border-1)}.icon--indent{-webkit-padding-start:var(--calcite-combobox-item-indent-value);padding-inline-start:var(--calcite-combobox-item-indent-value)}.icon--custom{margin-top:-1px;color:var(--calcite-ui-text-3)}.icon--active{color:var(--calcite-ui-text-1)}.icon--dot{display:-ms-flexbox;display:flex;-ms-flex-pack:end;justify-content:flex-end;width:var(--calcite-combobox-item-spacing-unit-l)}.icon--dot:before{text-align:start;content:"•"}.label--active .icon{opacity:1}.label--selected .icon{opacity:1;color:var(--calcite-ui-brand)}:host(:hover[disabled]) .icon{opacity:1}';var CalciteComboboxItem=function(){function e(e){var t=this;registerInstance(this,e);this.calciteComboboxItemChange=createEvent(this,"calciteComboboxItemChange",7);this.disabled=false;this.selected=false;this.active=false;this.guid=guid();this.scale="m";this.itemClickHandler=function(e){e.preventDefault();if(t.disabled){return}t.selected=!t.selected}}e.prototype.selectedWatchHandler=function(){this.calciteComboboxItemChange.emit(this.el)};e.prototype.connectedCallback=function(){this.ancestors=getAncestors(this.el);this.scale=getElementProp(this.el,"scale",this.scale)};e.prototype.componentWillLoad=function(){this.hasDefaultSlot=this.el.querySelector(":not([slot])")!==null};e.prototype.toggleSelected=function(e){return __awaiter(this,void 0,void 0,(function(){return __generator(this,(function(t){if(this.disabled){return[2]}this.selected=typeof e==="boolean"?e:!this.selected;return[2]}))}))};e.prototype.renderIcon=function(e){var t,i;var n=this,a=n.icon,o=n.disabled,r=n.selected;var s=CSS$1.icon+"--indent";var c=e?"dot":"check";var l=o?"circle-disallowed":c;var m=e&&!a&&!o;return m?h("span",{class:(t={},t[CSS$1.icon]=true,t[CSS$1.dot]=true,t[s]=true,t)}):h("calcite-icon",{class:(i={},i[CSS$1.icon]=!a,i[CSS$1.custom]=!!a,i[CSS$1.iconActive]=a&&r,i[s]=true,i),icon:a||l,scale:"s"})};e.prototype.renderChildren=function(){if(!this.hasDefaultSlot){return null}return h("ul",null,h("slot",null))};e.prototype.render=function(){var e;var t=getElementProp(this.el,"selection-mode","multi")==="single";var i=(e={},e[CSS$1.label]=true,e[CSS$1.selected]=this.selected,e[CSS$1.active]=this.active,e[CSS$1.single]=t,e);var n=getDepth(this.el);return h(Host,{"aria-hidden":"true"},h("div",{class:"container scale--"+this.scale,style:{"--calcite-combobox-item-spacing-indent-multiplier":""+n}},h("li",{class:i,id:this.guid,onClick:this.itemClickHandler},this.renderIcon(t),h("span",{class:CSS$1.title},this.textLabel)),this.renderChildren()))};Object.defineProperty(e.prototype,"el",{get:function(){return getElement(this)},enumerable:false,configurable:true});Object.defineProperty(e,"watchers",{get:function(){return{selected:["selectedWatchHandler"]}},enumerable:false,configurable:true});return e}();CalciteComboboxItem.style=calciteComboboxItemCss;var CSS={list:"list",label:"label",title:"title"};var calciteComboboxItemGroupCss="@-webkit-keyframes in{0%{opacity:0}100%{opacity:1}}@keyframes in{0%{opacity:0}100%{opacity:1}}@-webkit-keyframes in-down{0%{opacity:0;-webkit-transform:translate3D(0, -5px, 0);transform:translate3D(0, -5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@keyframes in-down{0%{opacity:0;-webkit-transform:translate3D(0, -5px, 0);transform:translate3D(0, -5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@-webkit-keyframes in-up{0%{opacity:0;-webkit-transform:translate3D(0, 5px, 0);transform:translate3D(0, 5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@keyframes in-up{0%{opacity:0;-webkit-transform:translate3D(0, 5px, 0);transform:translate3D(0, 5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@-webkit-keyframes in-scale{0%{opacity:0;-webkit-transform:scale3D(0.95, 0.95, 1);transform:scale3D(0.95, 0.95, 1)}100%{opacity:1;-webkit-transform:scale3D(1, 1, 1);transform:scale3D(1, 1, 1)}}@keyframes in-scale{0%{opacity:0;-webkit-transform:scale3D(0.95, 0.95, 1);transform:scale3D(0.95, 0.95, 1)}100%{opacity:1;-webkit-transform:scale3D(1, 1, 1);transform:scale3D(1, 1, 1)}}:root{--calcite-animation-timing:calc(150ms * var(--calcite-internal-duration-factor));--calcite-internal-duration-factor:var(--calcite-duration-factor, 1);--calcite-internal-animation-timing-fast:calc(100ms * var(--calcite-internal-duration-factor));--calcite-internal-animation-timing-medium:calc(200ms * var(--calcite-internal-duration-factor));--calcite-internal-animation-timing-slow:calc(300ms * var(--calcite-internal-duration-factor))}.calcite-animate{opacity:0;-webkit-animation-fill-mode:both;animation-fill-mode:both;-webkit-animation-duration:var(--calcite-animation-timing);animation-duration:var(--calcite-animation-timing)}.calcite-animate__in{-webkit-animation-name:in;animation-name:in}.calcite-animate__in-down{-webkit-animation-name:in-down;animation-name:in-down}.calcite-animate__in-up{-webkit-animation-name:in-up;animation-name:in-up}.calcite-animate__in-scale{-webkit-animation-name:in-scale;animation-name:in-scale}:root{--calcite-popper-transition:150ms ease-in-out}:host([hidden]){display:none}.scale--s{font-size:var(--calcite-font-size--2);line-height:1rem;--calcite-combobox-item-spacing-unit-l:0.5rem;--calcite-combobox-item-spacing-unit-s:0.25rem;--calcite-combobox-item-spacing-indent-1:0.5rem;--calcite-combobox-item-spacing-indent-2:1rem}.scale--m{font-size:var(--calcite-font-size--1);line-height:1rem;--calcite-combobox-item-spacing-unit-l:0.75rem;--calcite-combobox-item-spacing-unit-s:0.5rem;--calcite-combobox-item-spacing-indent-1:0.75rem;--calcite-combobox-item-spacing-indent-2:1.5rem}.scale--l{font-size:var(--calcite-font-size-0);line-height:1.25rem;--calcite-combobox-item-spacing-unit-l:1rem;--calcite-combobox-item-spacing-unit-s:0.75rem;--calcite-combobox-item-spacing-indent-1:1rem;--calcite-combobox-item-spacing-indent-2:2rem}:host,.list{display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;margin:0;padding:0;outline:2px solid transparent;outline-offset:2px}.label{-webkit-box-sizing:border-box;box-sizing:border-box;width:100%;max-width:100%;min-width:0;color:var(--calcite-ui-text-3);display:-ms-flexbox;display:flex}.label--indent-1{-webkit-padding-start:var(--calcite-combobox-item-spacing-indent-1);padding-inline-start:var(--calcite-combobox-item-spacing-indent-1)}.label--indent-2{-webkit-padding-start:var(--calcite-combobox-item-spacing-indent-2);padding-inline-start:var(--calcite-combobox-item-spacing-indent-2)}.title{border:0 solid;display:block;-ms-flex:1 1 0%;flex:1 1 0%;border-bottom-color:var(--calcite-ui-border-3);border-bottom-width:1px;color:var(--calcite-ui-text-2);font-weight:var(--calcite-font-weight-bold);word-wrap:break-word;word-break:break-word;padding:var(--calcite-combobox-item-spacing-unit-l) 0;margin-left:var(--calcite-combobox-item-spacing-unit-s);margin-right:var(--calcite-combobox-item-spacing-unit-s)}";var CalciteComboboxItemGroup=function(){function e(e){registerInstance(this,e);this.guid=guid();this.scale="m"}e.prototype.connectedCallback=function(){this.ancestors=getAncestors(this.el);this.scale=getElementProp(this.el,"scale",this.scale)};e.prototype.render=function(){var e,t;var i=this,n=i.el,a=i.scale;var o=CSS.label+"--indent-"+getDepth(n);return h("ul",{"aria-labelledby":this.guid,class:(e={},e[CSS.list]=true,e["scale--"+a]=true,e),role:"group"},h("li",{class:(t={},t[CSS.label]=true,t[o]=true,t),id:this.guid,role:"presentation"},h("span",{class:CSS.title},this.label)),h("slot",null))};Object.defineProperty(e.prototype,"el",{get:function(){return getElement(this)},enumerable:false,configurable:true});return e}();CalciteComboboxItemGroup.style=calciteComboboxItemGroupCss;export{CalciteCombobox as calcite_combobox,CalciteComboboxItem as calcite_combobox_item,CalciteComboboxItemGroup as calcite_combobox_item_group};
|
|
5
|
+
*/import{r as registerInstance,c as createEvent,h,H as Host,g as getElement}from"./index-c4b90cce.js";import{a as isSymbol,S as Symbol,d as debounce}from"./debounce-79648d42.js";import{i as isArray,f as forIn}from"./forIn-48d8fb84.js";import{u as updatePopper,c as createPopper,C as CSS$2}from"./popper-ae231554.js";import{g as guid}from"./guid-196bd5ea.js";import{n as nodeListToArray,d as getElementProp,g as getSlotted}from"./dom-e7fa77b9.js";import{c as connectLabel,d as disconnectLabel,g as getLabelText}from"./label-2bffc9f4.js";import{c as connectForm,a as afterConnectDefaultValueSet,d as disconnectForm,H as HiddenFormInputSlot}from"./form-42bda668.js";import{c as createObserver}from"./observers-46118290.js";import{c as connectConditionalSlotComponent,d as disconnectConditionalSlotComponent}from"./conditionalSlot-0e575a09.js";function arrayMap(e,t){var i=-1,n=e==null?0:e.length,a=Array(n);while(++i<n){a[i]=t(e[i],i,e)}return a}var INFINITY=1/0;var symbolProto=Symbol?Symbol.prototype:undefined,symbolToString=symbolProto?symbolProto.toString:undefined;function baseToString(e){if(typeof e=="string"){return e}if(isArray(e)){return arrayMap(e,baseToString)+""}if(isSymbol(e)){return symbolToString?symbolToString.call(e):""}var t=e+"";return t=="0"&&1/e==-INFINITY?"-0":t}function toString(e){return e==null?"":baseToString(e)}var reRegExpChar=/[\\^$.*+?()[\]{}|]/g,reHasRegExpChar=RegExp(reRegExpChar.source);function escapeRegExp(e){e=toString(e);return e&&reHasRegExpChar.test(e)?e.replace(reRegExpChar,"\\$&"):e}var filter=function(e,t){var i=escapeRegExp(t);var n=new RegExp(i,"i");if(e.length===0){console.warn("No data was passed to the filter function.\n The data argument should be an array of objects")}var a=function(e,t){var i;if((i=e)===null||i===void 0?void 0:i.constant){return true}var n=false;forIn(e,(function(e){if(typeof e==="function"){return}if(Array.isArray(e)||typeof e==="object"&&e!==null){if(a(e,t)){n=true}}else if(t.test(e)){n=true}}));return n};var o=e.filter((function(e){return a(e,n)}));return o};var ComboboxItem="CALCITE-COMBOBOX-ITEM";var ComboboxItemGroup="CALCITE-COMBOBOX-ITEM-GROUP";var ComboboxChildSelector=ComboboxItem+", "+ComboboxItemGroup;var ComboboxDefaultPlacement="bottom-leading";var TEXT={removeTag:"Remove tag"};function getAncestors(e){var t,i;var n=(t=e.parentElement)===null||t===void 0?void 0:t.closest(ComboboxChildSelector);var a=(i=n===null||n===void 0?void 0:n.parentElement)===null||i===void 0?void 0:i.closest(ComboboxChildSelector);return[n,a].filter((function(e){return e}))}function getItemAncestors(e){var t;return((t=e.ancestors)===null||t===void 0?void 0:t.filter((function(e){return e.nodeName==="CALCITE-COMBOBOX-ITEM"})))||[]}function getItemChildren(e){return nodeListToArray(e.querySelectorAll("calcite-combobox-item"))}function hasActiveChildren(e){var t=nodeListToArray(e.querySelectorAll("calcite-combobox-item"));return t.filter((function(e){return e.selected})).length>0}function getDepth(e){var t=document.evaluate("ancestor::calcite-combobox-item | ancestor::calcite-combobox-item-group",e,null,XPathResult.UNORDERED_NODE_SNAPSHOT_TYPE,null);return t.snapshotLength}var calciteComboboxCss="@-webkit-keyframes in{0%{opacity:0}100%{opacity:1}}@keyframes in{0%{opacity:0}100%{opacity:1}}@-webkit-keyframes in-down{0%{opacity:0;-webkit-transform:translate3D(0, -5px, 0);transform:translate3D(0, -5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@keyframes in-down{0%{opacity:0;-webkit-transform:translate3D(0, -5px, 0);transform:translate3D(0, -5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@-webkit-keyframes in-up{0%{opacity:0;-webkit-transform:translate3D(0, 5px, 0);transform:translate3D(0, 5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@keyframes in-up{0%{opacity:0;-webkit-transform:translate3D(0, 5px, 0);transform:translate3D(0, 5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@-webkit-keyframes in-scale{0%{opacity:0;-webkit-transform:scale3D(0.95, 0.95, 1);transform:scale3D(0.95, 0.95, 1)}100%{opacity:1;-webkit-transform:scale3D(1, 1, 1);transform:scale3D(1, 1, 1)}}@keyframes in-scale{0%{opacity:0;-webkit-transform:scale3D(0.95, 0.95, 1);transform:scale3D(0.95, 0.95, 1)}100%{opacity:1;-webkit-transform:scale3D(1, 1, 1);transform:scale3D(1, 1, 1)}}:root{--calcite-animation-timing:calc(150ms * var(--calcite-internal-duration-factor));--calcite-internal-duration-factor:var(--calcite-duration-factor, 1);--calcite-internal-animation-timing-fast:calc(100ms * var(--calcite-internal-duration-factor));--calcite-internal-animation-timing-medium:calc(200ms * var(--calcite-internal-duration-factor));--calcite-internal-animation-timing-slow:calc(300ms * var(--calcite-internal-duration-factor))}.calcite-animate{opacity:0;-webkit-animation-fill-mode:both;animation-fill-mode:both;-webkit-animation-duration:var(--calcite-animation-timing);animation-duration:var(--calcite-animation-timing)}.calcite-animate__in{-webkit-animation-name:in;animation-name:in}.calcite-animate__in-down{-webkit-animation-name:in-down;animation-name:in-down}.calcite-animate__in-up{-webkit-animation-name:in-up;animation-name:in-up}.calcite-animate__in-scale{-webkit-animation-name:in-scale;animation-name:in-scale}:root{--calcite-popper-transition:var(--calcite-animation-timing)}:host([hidden]){display:none}:host{position:relative;display:block}:host([disabled]){pointer-events:none;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;opacity:0.5}:host([scale=s]){font-size:var(--calcite-font-size--2);--calcite-combobox-item-spacing-unit-l:0.5rem;--calcite-combobox-item-spacing-unit-s:0.25rem;--calcite-combobox-input-height:1.5rem}:host([scale=m]){font-size:var(--calcite-font-size--1);--calcite-combobox-item-spacing-unit-l:0.75rem;--calcite-combobox-item-spacing-unit-s:0.5rem;--calcite-combobox-input-height:2rem}:host([scale=l]){font-size:var(--calcite-font-size-0);--calcite-combobox-item-spacing-unit-l:1rem;--calcite-combobox-item-spacing-unit-s:0.75rem;--calcite-combobox-input-height:2.75rem}.wrapper{display:-ms-flexbox;display:flex;background-color:var(--calcite-ui-foreground-1);color:var(--calcite-ui-text-1);outline-offset:0;outline-color:transparent;-webkit-transition:outline-offset 100ms ease-in-out, outline-color 100ms ease-in-out;transition:outline-offset 100ms ease-in-out, outline-color 100ms ease-in-out;-webkit-box-shadow:inset 0 0 0 1px var(--calcite-ui-border-input);box-shadow:inset 0 0 0 1px var(--calcite-ui-border-input);padding:0 var(--calcite-combobox-item-spacing-unit-l) 0 var(--calcite-combobox-item-spacing-unit-l)}:host(:focus-within) .wrapper,.wrapper--active{outline:2px solid var(--calcite-ui-brand);outline-offset:-2px}.wrapper--single{padding:0 var(--calcite-combobox-item-spacing-unit-l);cursor:pointer;-ms-flex-wrap:nowrap;flex-wrap:nowrap}.grid-input{display:-ms-flexbox;display:flex;-ms-flex-positive:1;flex-grow:1;-ms-flex-wrap:wrap;flex-wrap:wrap;-ms-flex-align:center;align-items:center;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;padding:0px}.input{-ms-flex-positive:1;flex-grow:1;-webkit-appearance:none;-moz-appearance:none;appearance:none;border-style:none;background-color:transparent;padding:0px;font-family:inherit;color:var(--calcite-ui-text-1);font-size:inherit;height:var(--calcite-combobox-input-height);line-height:var(--calcite-combobox-input-height);min-width:120px;margin-bottom:var(--calcite-combobox-item-spacing-unit-s)}.input:focus{outline:2px solid transparent;outline-offset:2px}.input--transparent{opacity:0}.input--single{margin-bottom:0px;margin-top:0px;padding:0px}.wrapper--active .input-single{cursor:text}.input--hidden{pointer-events:none;width:0px;min-width:0px;opacity:0}.input--icon{padding:0 var(--calcite-combobox-item-spacing-unit-l)}.input-wrap{display:-ms-flexbox;display:flex;-ms-flex-positive:1;flex-grow:1}.input-wrap--single{-ms-flex:1 1 0%;flex:1 1 0%;overflow:hidden}.label{pointer-events:none;display:-ms-flexbox;display:flex;max-width:100%;-ms-flex:1 1 auto;flex:1 1 auto;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;padding:0px;font-weight:var(--calcite-font-weight-normal);height:var(--calcite-combobox-input-height);line-height:var(--calcite-combobox-input-height)}.label--spaced{padding-top:0px;padding-bottom:0px;padding-left:var(--calcite-combobox-item-spacing-unit-l);padding-right:var(--calcite-combobox-item-spacing-unit-l)}.icon-end,.icon-start{display:-ms-flexbox;display:flex;width:1rem;cursor:pointer;-ms-flex-align:center;align-items:center}.icon-end{-ms-flex:none;flex:none}.popper-container{width:100%;display:block;position:absolute;z-index:900;-webkit-transform:scale(0);transform:scale(0);visibility:hidden;pointer-events:none}.popper-container .calcite-popper-anim{position:relative;z-index:1;-webkit-transition:var(--calcite-popper-transition);transition:var(--calcite-popper-transition);visibility:hidden;-webkit-transition-property:visibility, opacity, -webkit-transform;transition-property:visibility, opacity, -webkit-transform;transition-property:transform, visibility, opacity;transition-property:transform, visibility, opacity, -webkit-transform;opacity:0;-webkit-box-shadow:0 0 16px 0 rgba(0, 0, 0, 0.16);box-shadow:0 0 16px 0 rgba(0, 0, 0, 0.16);border-radius:0.25rem}.popper-container[data-popper-placement^=bottom] .calcite-popper-anim{-webkit-transform:translateY(-5px);transform:translateY(-5px)}.popper-container[data-popper-placement^=top] .calcite-popper-anim{-webkit-transform:translateY(5px);transform:translateY(5px)}.popper-container[data-popper-placement^=left] .calcite-popper-anim{-webkit-transform:translateX(5px);transform:translateX(5px)}.popper-container[data-popper-placement^=right] .calcite-popper-anim{-webkit-transform:translateX(-5px);transform:translateX(-5px)}.popper-container[data-popper-placement] .calcite-popper-anim--active{opacity:1;visibility:visible;-webkit-transform:translate(0);transform:translate(0)}.popper-container--active{pointer-events:initial;visibility:visible}.screen-readers-only{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0, 0, 0, 0);white-space:nowrap;border-width:0}.list-container{max-height:100vh;overflow-y:auto;background-color:var(--calcite-ui-foreground-1);width:var(--calcite-dropdown-width)}.list{margin:0px;display:block;padding:0px}.list--hide{height:0px;overflow:hidden}.chip{margin-block:calc(var(--calcite-combobox-item-spacing-unit-s) / 2) 0;margin-inline:0 var(--calcite-combobox-item-spacing-unit-s);max-width:100%}.chip--active{background-color:var(--calcite-ui-foreground-3)}.chip:last-of-type{-webkit-margin-end:0;margin-inline-end:0}.item{display:block}::slotted(input[slot=hidden-form-input]){bottom:0 !important;left:0 !important;margin:0 !important;opacity:0 !important;outline:none !important;padding:0 !important;position:absolute !important;right:0 !important;top:0 !important;-webkit-transform:none !important;transform:none !important;-webkit-appearance:none !important;z-index:-1 !important}";var isGroup=function(e){return e.tagName===ComboboxItemGroup};var itemUidPrefix="combobox-item-";var chipUidPrefix="combobox-chip-";var labelUidPrefix="combobox-label-";var listboxUidPrefix="combobox-listbox-";var inputUidPrefix="combobox-input-";var CalciteCombobox=function(){function e(e){var t=this;registerInstance(this,e);this.calciteLookupChange=createEvent(this,"calciteLookupChange",7);this.calciteComboboxChange=createEvent(this,"calciteComboboxChange",7);this.calciteComboboxFilterChange=createEvent(this,"calciteComboboxFilterChange",7);this.calciteComboboxChipDismiss=createEvent(this,"calciteComboboxChipDismiss",7);this.calciteComboboxOpen=createEvent(this,"calciteComboboxOpen",7);this.calciteComboboxClose=createEvent(this,"calciteComboboxClose",7);this.active=false;this.disabled=false;this.maxItems=0;this.overlayPositioning="absolute";this.required=false;this.selectionMode="multi";this.scale="m";this.value=null;this.intlRemoveTag=TEXT.removeTag;this.internalValueChangeFlag=false;this.items=[];this.groupItems=[];this.selectedItems=[];this.visibleItems=[];this.hideList=!this.active;this.activeItemIndex=-1;this.activeChipIndex=-1;this.activeDescendant="";this.text="";this.open=this.active;this.maxScrollerHeight=0;this.textInput=null;this.mutationObserver=createObserver("mutation",(function(){return t.updateItems()}));this.guid=guid();this.inputHeight=0;this.ignoreSelectedEventsFlag=false;this.activeTransitionProp="opacity";this.getValue=function(){var e=t.selectedItems.map((function(e){return e===null||e===void 0?void 0:e.value.toString()}));return(e===null||e===void 0?void 0:e.length)?e.length>1?e:e[0]:""};this.onLabelClick=function(){t.setFocus()};this.keydownHandler=function(e){var i=e.key;switch(i){case"Tab":t.activeChipIndex=-1;t.activeItemIndex=-1;if(t.allowCustomValues&&t.text){t.addCustomChip(t.text,true);e.preventDefault()}else{t.active=false}break;case"ArrowLeft":t.previousChip();break;case"ArrowRight":t.nextChip();break;case"ArrowUp":e.preventDefault();t.active=true;t.shiftActiveItemIndex(-1);break;case"ArrowDown":e.preventDefault();t.active=true;t.shiftActiveItemIndex(1);break;case"Home":t.active=true;t.updateActiveItemIndex(0);break;case"End":t.active=true;t.updateActiveItemIndex(t.visibleItems.length-1);break;case"Escape":t.active=false;break;case"Enter":if(t.activeItemIndex>-1){t.toggleSelection(t.visibleItems[t.activeItemIndex])}else if(t.activeChipIndex>-1){t.removeActiveChip()}else if(t.allowCustomValues&&t.text){t.addCustomChip(t.text,true)}break;case"Delete":case"Backspace":if(t.activeChipIndex>-1){t.removeActiveChip()}else if(!t.text&&t.isMulti()){t.removeLastChip()}break;default:if(!t.active){t.setFocus()}break}};this.toggleCloseEnd=function(){t.hideList=true;t.el.removeEventListener("calciteComboboxClose",t.toggleCloseEnd)};this.toggleOpenEnd=function(){t.hideList=false;t.el.removeEventListener("calciteComboboxOpen",t.toggleOpenEnd)};this.transitionEnd=function(e){if(e.propertyName===t.activeTransitionProp){t.active?t.calciteComboboxOpen.emit():t.calciteComboboxClose.emit()}};this.setMaxScrollerHeight=function(){if(t.active){t.maxScrollerHeight=t.getMaxScrollerHeight(t.getCombinedItems())}};this.calciteChipDismissHandler=function(e,i){t.active=false;var n=t.items.find((function(e){return e===i}));if(n){t.toggleSelection(n,false)}t.calciteComboboxChipDismiss.emit(e.detail)};this.setFocusClick=function(e){if(e.composedPath().some((function(e){return e.tagName==="CALCITE-CHIP"}))){return}t.setFocus()};this.setInactiveIfNotContained=function(e){var i=e.composedPath();if(!t.active&&!t.open||i.includes(t.el)||i.includes(t.referenceEl)){return}if(t.allowCustomValues&&t.text){t.addCustomChip(t.text)}if(t.selectionMode==="single"){if(t.textInput){t.textInput.value=""}t.text="";t.filterItems("");t.updateActiveItemIndex(-1)}t.active=false;t.open=false};this.setMenuEl=function(e){t.menuEl=e};this.setListContainerEl=function(e){t.listContainerEl=e};this.setReferenceEl=function(e){t.referenceEl=e};this.inputHandler=function(e){var i=e.target.value;t.text=i;t.filterItems(i);if(i){t.activeChipIndex=-1}};this.filterItems=function(){var e=function(e,t){return e&&t.some((function(t){var i=t.label,n=t.value;if(isGroup(e)){return n===e.label||n===e.label}return n===e.textLabel||n===e.value||i===e.textLabel||i===e.value}))};return debounce((function(i){var n=filter(t.data,i);var a=t.getCombinedItems();a.forEach((function(t){var i=!e(t,n);t.hidden=i;var a=t.ancestors,o=a[0],r=a[1];if(e(o,n)||e(r,n)){t.hidden=false}if(!i){t.ancestors.forEach((function(e){return e.hidden=false}))}}));t.visibleItems=t.getVisibleItems();t.calciteComboboxFilterChange.emit({visibleItems:__spreadArray([],t.visibleItems),text:i})}),100)}();this.internalCalciteLookupChangeEvent=function(){t.calciteLookupChange.emit(t.selectedItems)};this.emitCalciteLookupChange=debounce(this.internalCalciteLookupChangeEvent,0);this.internalComboboxChangeEvent=function(){var e=t.selectedItems;t.calciteComboboxChange.emit({selectedItems:e})};this.emitComboboxChange=debounce(this.internalComboboxChangeEvent,0);this.updateItems=function(){t.items=t.getItems();t.groupItems=t.getGroupItems();t.data=t.getData();t.selectedItems=t.getSelectedItems();t.visibleItems=t.getVisibleItems();t.needsIcon=t.getNeedsIcon();if(!t.allowCustomValues){t.setMaxScrollerHeight()}};this.comboboxFocusHandler=function(){var e;t.active=true;(e=t.textInput)===null||e===void 0?void 0:e.focus()};this.comboboxBlurHandler=function(e){t.setInactiveIfNotContained(e)}}e.prototype.activeHandler=function(e,t){var i=this;if(t&&!e){this.el.addEventListener("calciteComboboxClose",this.toggleCloseEnd);this.open=false}else if(!t&&e){this.el.addEventListener("calciteComboboxOpen",this.toggleOpenEnd);requestAnimationFrame((function(){i.reposition();i.setMaxScrollerHeight();i.open=true}))}this.reposition();this.setMaxScrollerHeight()};e.prototype.maxItemsHandler=function(){this.setMaxScrollerHeight()};e.prototype.valueHandler=function(e){if(!this.internalValueChangeFlag){var t=this.getItems();if(Array.isArray(e)){t.forEach((function(t){return t.selected=e.includes(t.value)}))}else if(e){t.forEach((function(t){return t.selected=e===t.value}))}else{t.forEach((function(e){return e.selected=false}))}this.updateItems()}};e.prototype.documentClickHandler=function(e){this.setInactiveIfNotContained(e)};e.prototype.calciteComboboxItemChangeHandler=function(e){if(this.ignoreSelectedEventsFlag){return}var t=e.target;this.toggleSelection(t,t.selected)};e.prototype.reposition=function(){return __awaiter(this,void 0,void 0,(function(){var e,t,i,n,a;return __generator(this,(function(o){switch(o.label){case 0:e=this,t=e.popper,i=e.menuEl;n=this.getModifiers();if(!t)return[3,2];return[4,updatePopper({el:i,modifiers:n,placement:ComboboxDefaultPlacement,popper:t})];case 1:a=o.sent();return[3,3];case 2:a=this.createPopper();o.label=3;case 3:a;return[2]}}))}))};e.prototype.setFocus=function(){return __awaiter(this,void 0,void 0,(function(){var e;return __generator(this,(function(t){this.active=true;(e=this.textInput)===null||e===void 0?void 0:e.focus();this.activeChipIndex=-1;this.activeItemIndex=-1;return[2]}))}))};e.prototype.connectedCallback=function(){var e;this.internalValueChangeFlag=true;this.value=this.getValue();this.internalValueChangeFlag=false;(e=this.mutationObserver)===null||e===void 0?void 0:e.observe(this.el,{childList:true,subtree:true});this.createPopper();connectLabel(this);connectForm(this)};e.prototype.componentWillLoad=function(){this.updateItems()};e.prototype.componentDidLoad=function(){afterConnectDefaultValueSet(this,this.getValue())};e.prototype.componentDidRender=function(){if(this.el.offsetHeight!==this.inputHeight){this.reposition();this.inputHeight=this.el.offsetHeight}};e.prototype.disconnectedCallback=function(){var e;(e=this.mutationObserver)===null||e===void 0?void 0:e.disconnect();this.destroyPopper();disconnectLabel(this);disconnectForm(this)};e.prototype.selectedItemsHandler=function(){this.internalValueChangeFlag=true;this.value=this.getValue();this.internalValueChangeFlag=false};e.prototype.textHandler=function(){this.updateActiveItemIndex(-1)};e.prototype.getModifiers=function(){var e={name:"flip",enabled:true};e.options={fallbackPlacements:["top-start","top","top-end","bottom-start","bottom","bottom-end"]};return[e]};e.prototype.createPopper=function(){this.destroyPopper();var e=this,t=e.menuEl,i=e.referenceEl,n=e.overlayPositioning;var a=this.getModifiers();this.popper=createPopper({el:t,modifiers:a,overlayPositioning:n,placement:ComboboxDefaultPlacement,referenceEl:i})};e.prototype.destroyPopper=function(){var e=this.popper;if(e){e.destroy()}this.popper=null};e.prototype.getMaxScrollerHeight=function(e){var t=this;var i=this.maxItems;var n=0;var a=0;e.forEach((function(e){if(n<i&&i>0){var o=t.calculateSingleItemHeight(e);if(o>0){a+=o;n++}}}));return a};e.prototype.calculateSingleItemHeight=function(e){var t=e.offsetHeight;var i=Array.from(e.querySelectorAll(ComboboxChildSelector));i.map((function(e){return e===null||e===void 0?void 0:e.offsetHeight})).forEach((function(e){t-=e}));return t};e.prototype.getCombinedItems=function(){return __spreadArray(__spreadArray([],this.groupItems),this.items)};e.prototype.toggleSelection=function(e,t){if(t===void 0){t=!e.selected}if(!e){return}if(this.isMulti()){e.selected=t;this.updateAncestors(e);this.selectedItems=this.getSelectedItems();this.emitCalciteLookupChange();this.emitComboboxChange();this.resetText();this.filterItems("")}else{this.ignoreSelectedEventsFlag=true;this.items.forEach((function(i){return i.selected=i===e?t:false}));this.ignoreSelectedEventsFlag=false;this.selectedItems=this.getSelectedItems();this.emitComboboxChange();if(this.textInput){this.textInput.value=e.textLabel}this.active=false;this.updateActiveItemIndex(-1);this.resetText();this.filterItems("")}};e.prototype.updateAncestors=function(e){if(this.selectionMode!=="ancestors"){return}var t=getItemAncestors(e);var i=getItemChildren(e);if(e.selected){t.forEach((function(e){e.selected=true}))}else{i.forEach((function(e){return e.selected=false}));__spreadArray([],t).forEach((function(e){if(!hasActiveChildren(e)){e.selected=false}}))}};e.prototype.getVisibleItems=function(){return this.items.filter((function(e){return!e.hidden}))};e.prototype.getSelectedItems=function(){var e=this;return!this.isMulti()?[this.items.find((function(e){return e.selected}))]:this.items.filter((function(t){return t.selected&&(e.selectionMode!=="ancestors"||!hasActiveChildren(t))})).sort((function(t,i){var n=e.selectedItems.indexOf(t);var a=e.selectedItems.indexOf(i);if(n>-1&&a>-1){return n-a}return a-n}))};e.prototype.getData=function(){return this.items.map((function(e){return{constant:e.constant,value:e.value,label:e.textLabel,guid:e.guid}}))};e.prototype.getNeedsIcon=function(){return this.selectionMode==="single"&&this.items.some((function(e){return e.icon}))};e.prototype.resetText=function(){if(this.textInput){this.textInput.value=""}this.text=""};e.prototype.getItems=function(){var e=Array.from(this.el.querySelectorAll(ComboboxItem));return e.filter((function(e){return!e.disabled}))};e.prototype.getGroupItems=function(){return Array.from(this.el.querySelectorAll(ComboboxItemGroup))};e.prototype.addCustomChip=function(e,t){var i=this.items.find((function(t){return t.textLabel===e}));if(i){this.toggleSelection(i,true)}else{var n=document.createElement(ComboboxItem);n.value=e;n.textLabel=e;n.selected=true;this.el.appendChild(n);this.resetText();if(t){this.setFocus()}this.updateItems();this.filterItems("");this.emitCalciteLookupChange();this.emitComboboxChange()}};e.prototype.removeActiveChip=function(){this.toggleSelection(this.selectedItems[this.activeChipIndex],false);this.setFocus()};e.prototype.removeLastChip=function(){this.toggleSelection(this.selectedItems[this.selectedItems.length-1],false);this.setFocus()};e.prototype.previousChip=function(){if(this.text){return}var e=this.selectedItems.length-1;var t=this.activeChipIndex;this.activeChipIndex=t===-1?e:Math.max(t-1,0);this.updateActiveItemIndex(-1);this.focusChip()};e.prototype.nextChip=function(){if(this.text||this.activeChipIndex===-1){return}var e=this.selectedItems.length-1;var t=this.activeChipIndex+1;if(t>e){this.activeChipIndex=-1;this.setFocus()}else{this.activeChipIndex=t;this.focusChip()}this.updateActiveItemIndex(-1)};e.prototype.focusChip=function(){var e;var t=(e=this.selectedItems[this.activeChipIndex])===null||e===void 0?void 0:e.guid;var i=t?this.referenceEl.querySelector("#"+chipUidPrefix+t):null;i===null||i===void 0?void 0:i.setFocus()};e.prototype.shiftActiveItemIndex=function(e){var t=this.visibleItems.length;var i=(this.activeItemIndex+t+e)%t;this.updateActiveItemIndex(i);var n=this.visibleItems[this.activeItemIndex];var a=this.calculateSingleItemHeight(n);var o=this.listContainerEl,r=o.offsetHeight,s=o.scrollTop;if(r+s<n.offsetTop+a){this.listContainerEl.scrollTop=n.offsetTop-r+a}else if(n.offsetTop<s){this.listContainerEl.scrollTop=n.offsetTop}};e.prototype.updateActiveItemIndex=function(e){var t;this.activeItemIndex=e;var i=null;this.visibleItems.forEach((function(t,n){if(n===e){t.active=true;i=t.guid}else{t.active=false}}));this.activeDescendant=i;if(this.activeItemIndex>-1){this.activeChipIndex=-1;(t=this.textInput)===null||t===void 0?void 0:t.focus()}};e.prototype.isMulti=function(){return this.selectionMode!=="single"};e.prototype.renderChips=function(){var e=this;var t=this,i=t.activeChipIndex,n=t.scale,a=t.selectionMode,o=t.intlRemoveTag;return this.selectedItems.map((function(t,r){var s={chip:true,"chip--active":i===r};var c=__spreadArray([],getItemAncestors(t)).reverse();var l=__spreadArray(__spreadArray([],c),[t]).map((function(e){return e.textLabel}));var m=a!=="ancestors"?t.textLabel:l.join(" / ");return h("calcite-chip",{class:s,dismissLabel:o,dismissible:true,icon:t.icon,id:t.guid?""+chipUidPrefix+t.guid:null,key:t.textLabel,onCalciteChipDismiss:function(i){return e.calciteChipDismissHandler(i,t)},scale:n,title:m,value:t.value},m)}))};e.prototype.renderInput=function(){var e=this;var t=this,i=t.guid,n=t.active,a=t.disabled,o=t.placeholder,r=t.selectionMode,s=t.needsIcon,c=t.selectedItems;var l=r==="single";var m=c[0];var p=!n&&l&&!!m;return h("span",{class:{"input-wrap":true,"input-wrap--single":l}},p&&h("span",{class:{label:true,"label--spaced":s},key:"label",onFocus:this.comboboxFocusHandler,tabindex:"0"},m.textLabel),h("input",{"aria-activedescendant":this.activeDescendant,"aria-autocomplete":"list","aria-controls":""+listboxUidPrefix+i,"aria-label":getLabelText(this),class:{input:true,"input--single":true,"input--transparent":this.activeChipIndex>-1,"input--hidden":p,"input--icon":l&&s},disabled:a,id:""+inputUidPrefix+i,key:"input",onBlur:this.comboboxBlurHandler,onFocus:this.comboboxFocusHandler,onInput:this.inputHandler,placeholder:o,ref:function(t){return e.textInput=t},type:"text"}))};e.prototype.renderListBoxOptions=function(){return this.visibleItems.map((function(e){return h("li",{"aria-selected":(!!e.selected).toString(),id:e.guid?""+itemUidPrefix+e.guid:null,role:"option",tabindex:"-1"},e.textLabel)}))};e.prototype.renderPopperContainer=function(){var e;var t=this,i=t.active,n=t.maxScrollerHeight,a=t.setMenuEl,o=t.setListContainerEl,r=t.hideList,s=t.open;var c=(e={"list-container":true},e[CSS$2.animation]=true,e[CSS$2.animationActive]=i,e);var l={maxHeight:n>0?n+"px":""};return h("div",{"aria-hidden":"true",class:{"popper-container":true,"popper-container--active":s},ref:a},h("div",{class:c,onTransitionEnd:this.transitionEnd,ref:o,style:l},h("ul",{class:{list:true,"list--hide":r}},h("slot",null))))};e.prototype.renderIconStart=function(){var e=this,t=e.selectionMode,i=e.needsIcon,n=e.selectedItems;var a=n[0];return t==="single"&&i&&h("span",{class:"icon-start"},(a===null||a===void 0?void 0:a.icon)&&h("calcite-icon",{class:"selected-icon",icon:a.icon,scale:"s"}))};e.prototype.renderIconEnd=function(){return h("span",{class:"icon-end"},h("calcite-icon",{icon:"chevron-down",scale:"s"}))};e.prototype.render=function(){var e=this,t=e.guid,i=e.open,n=e.label;var a=this.selectionMode==="single";return h(Host,{onKeyDown:this.keydownHandler},h("div",{"aria-autocomplete":"list","aria-expanded":i.toString(),"aria-haspopup":"listbox","aria-labelledby":""+labelUidPrefix+t,"aria-owns":""+listboxUidPrefix+t,class:{wrapper:true,"wrapper--single":a||!this.selectedItems.length,"wrapper--active":i},onClick:this.setFocusClick,ref:this.setReferenceEl,role:"combobox"},h("div",{class:"grid-input"},this.renderIconStart(),!a&&this.renderChips(),h("label",{class:"screen-readers-only",htmlFor:""+inputUidPrefix+t,id:""+labelUidPrefix+t},n),this.renderInput()),this.renderIconEnd()),h("ul",{"aria-labelledby":""+labelUidPrefix+t,"aria-multiselectable":"true",class:"screen-readers-only",id:""+listboxUidPrefix+t,role:"listbox",tabIndex:-1},this.renderListBoxOptions()),this.renderPopperContainer(),h(HiddenFormInputSlot,{component:this}))};Object.defineProperty(e.prototype,"el",{get:function(){return getElement(this)},enumerable:false,configurable:true});Object.defineProperty(e,"watchers",{get:function(){return{active:["activeHandler"],maxItems:["maxItemsHandler"],value:["valueHandler"],selectedItems:["selectedItemsHandler"],text:["textHandler"]}},enumerable:false,configurable:true});return e}();CalciteCombobox.style=calciteComboboxCss;var CSS$1={icon:"icon",iconActive:"icon--active",custom:"icon--custom",dot:"icon--dot",single:"label--single",label:"label",active:"label--active",selected:"label--selected",title:"title",textContainer:"text-container"};var calciteComboboxItemCss='@charset "UTF-8";@-webkit-keyframes in{0%{opacity:0}100%{opacity:1}}@keyframes in{0%{opacity:0}100%{opacity:1}}@-webkit-keyframes in-down{0%{opacity:0;-webkit-transform:translate3D(0, -5px, 0);transform:translate3D(0, -5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@keyframes in-down{0%{opacity:0;-webkit-transform:translate3D(0, -5px, 0);transform:translate3D(0, -5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@-webkit-keyframes in-up{0%{opacity:0;-webkit-transform:translate3D(0, 5px, 0);transform:translate3D(0, 5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@keyframes in-up{0%{opacity:0;-webkit-transform:translate3D(0, 5px, 0);transform:translate3D(0, 5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@-webkit-keyframes in-scale{0%{opacity:0;-webkit-transform:scale3D(0.95, 0.95, 1);transform:scale3D(0.95, 0.95, 1)}100%{opacity:1;-webkit-transform:scale3D(1, 1, 1);transform:scale3D(1, 1, 1)}}@keyframes in-scale{0%{opacity:0;-webkit-transform:scale3D(0.95, 0.95, 1);transform:scale3D(0.95, 0.95, 1)}100%{opacity:1;-webkit-transform:scale3D(1, 1, 1);transform:scale3D(1, 1, 1)}}:root{--calcite-animation-timing:calc(150ms * var(--calcite-internal-duration-factor));--calcite-internal-duration-factor:var(--calcite-duration-factor, 1);--calcite-internal-animation-timing-fast:calc(100ms * var(--calcite-internal-duration-factor));--calcite-internal-animation-timing-medium:calc(200ms * var(--calcite-internal-duration-factor));--calcite-internal-animation-timing-slow:calc(300ms * var(--calcite-internal-duration-factor))}.calcite-animate{opacity:0;-webkit-animation-fill-mode:both;animation-fill-mode:both;-webkit-animation-duration:var(--calcite-animation-timing);animation-duration:var(--calcite-animation-timing)}.calcite-animate__in{-webkit-animation-name:in;animation-name:in}.calcite-animate__in-down{-webkit-animation-name:in-down;animation-name:in-down}.calcite-animate__in-up{-webkit-animation-name:in-up;animation-name:in-up}.calcite-animate__in-scale{-webkit-animation-name:in-scale;animation-name:in-scale}:root{--calcite-popper-transition:var(--calcite-animation-timing)}:host([hidden]){display:none}.scale--s{font-size:var(--calcite-font-size--2);line-height:1rem;--calcite-combobox-item-spacing-unit-l:0.5rem;--calcite-combobox-item-spacing-unit-s:0.25rem;--calcite-combobox-item-spacing-indent:0.5rem}.scale--m{font-size:var(--calcite-font-size--1);line-height:1rem;--calcite-combobox-item-spacing-unit-l:0.75rem;--calcite-combobox-item-spacing-unit-s:0.5rem;--calcite-combobox-item-spacing-indent:0.75rem}.scale--l{font-size:var(--calcite-font-size-0);line-height:1.25rem;--calcite-combobox-item-spacing-unit-l:1rem;--calcite-combobox-item-spacing-unit-s:0.75rem;--calcite-combobox-item-spacing-indent:1rem}.container{--calcite-combobox-item-indent-value:calc(\n var(--calcite-combobox-item-spacing-indent) * var(--calcite-combobox-item-spacing-indent-multiplier)\n )}:host(:focus){--tw-shadow:0 0 #0000;--tw-shadow-colored:0 0 #0000;-webkit-box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow)}:host,ul{margin:0px;display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;padding:0px;outline:2px solid transparent;outline-offset:2px}.label{position:relative;-webkit-box-sizing:border-box;box-sizing:border-box;display:-ms-flexbox;display:flex;width:100%;min-width:100%;cursor:pointer;-ms-flex-align:center;align-items:center;color:var(--calcite-ui-text-3);-webkit-text-decoration-line:none;text-decoration-line:none;-webkit-transition-duration:150ms;transition-duration:150ms;-webkit-transition-timing-function:cubic-bezier(0.4, 0, 0.2, 1);transition-timing-function:cubic-bezier(0.4, 0, 0.2, 1);outline-offset:0;outline-color:transparent;-webkit-transition:outline-offset 100ms ease-in-out, outline-color 100ms ease-in-out;transition:outline-offset 100ms ease-in-out, outline-color 100ms ease-in-out;padding:var(--calcite-combobox-item-spacing-unit-s) var(--calcite-combobox-item-spacing-unit-l)}:host([disabled]) .label{cursor:default}.label--selected{font-weight:var(--calcite-font-weight-medium);color:var(--calcite-ui-text-1)}.label--active{outline:2px solid var(--calcite-ui-brand);outline-offset:-2px}.label:hover,.label:active{background-color:var(--calcite-ui-foreground-2);color:var(--calcite-ui-text-1);-webkit-text-decoration-line:none;text-decoration-line:none;--tw-shadow:0 0 #0000;--tw-shadow-colored:0 0 #0000;-webkit-box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow)}.title{padding:0 var(--calcite-combobox-item-spacing-unit-l)}.icon{display:-ms-inline-flexbox;display:inline-flex;opacity:0;-webkit-transition-duration:150ms;transition-duration:150ms;-webkit-transition-timing-function:cubic-bezier(0.4, 0, 0.2, 1);transition-timing-function:cubic-bezier(0.4, 0, 0.2, 1);color:var(--calcite-ui-border-1)}.icon--indent{-webkit-padding-start:var(--calcite-combobox-item-indent-value);padding-inline-start:var(--calcite-combobox-item-indent-value)}.icon--custom{margin-top:-1px;color:var(--calcite-ui-text-3)}.icon--active{color:var(--calcite-ui-text-1)}.icon--dot{display:-ms-flexbox;display:flex;-ms-flex-pack:end;justify-content:flex-end;width:var(--calcite-combobox-item-spacing-unit-l)}.icon--dot:before{text-align:start;content:"•"}.label--active .icon{opacity:1}.label--selected .icon{opacity:1;color:var(--calcite-ui-brand)}:host(:hover[disabled]) .icon{opacity:1}';var CalciteComboboxItem=function(){function e(e){var t=this;registerInstance(this,e);this.calciteComboboxItemChange=createEvent(this,"calciteComboboxItemChange",7);this.disabled=false;this.selected=false;this.active=false;this.guid=guid();this.scale="m";this.itemClickHandler=function(e){e.preventDefault();if(t.disabled){return}t.selected=!t.selected}}e.prototype.selectedWatchHandler=function(){this.calciteComboboxItemChange.emit(this.el)};e.prototype.connectedCallback=function(){this.ancestors=getAncestors(this.el);this.scale=getElementProp(this.el,"scale",this.scale);connectConditionalSlotComponent(this)};e.prototype.disconnectedCallback=function(){disconnectConditionalSlotComponent(this)};e.prototype.toggleSelected=function(e){return __awaiter(this,void 0,void 0,(function(){return __generator(this,(function(t){if(this.disabled){return[2]}this.selected=typeof e==="boolean"?e:!this.selected;return[2]}))}))};e.prototype.renderIcon=function(e){var t,i;var n=this,a=n.icon,o=n.disabled,r=n.selected;var s=CSS$1.icon+"--indent";var c=e?"dot":"check";var l=o?"circle-disallowed":c;var m=e&&!a&&!o;return m?h("span",{class:(t={},t[CSS$1.icon]=true,t[CSS$1.dot]=true,t[s]=true,t)}):h("calcite-icon",{class:(i={},i[CSS$1.icon]=!a,i[CSS$1.custom]=!!a,i[CSS$1.iconActive]=a&&r,i[s]=true,i),icon:a||l,scale:"s"})};e.prototype.renderChildren=function(){if(getSlotted(this.el)){return h("ul",{key:"default-slot-container"},h("slot",null))}return null};e.prototype.render=function(){var e;var t=getElementProp(this.el,"selection-mode","multi")==="single";var i=(e={},e[CSS$1.label]=true,e[CSS$1.selected]=this.selected,e[CSS$1.active]=this.active,e[CSS$1.single]=t,e);var n=getDepth(this.el);return h(Host,{"aria-hidden":"true"},h("div",{class:"container scale--"+this.scale,style:{"--calcite-combobox-item-spacing-indent-multiplier":""+n}},h("li",{class:i,id:this.guid,onClick:this.itemClickHandler},this.renderIcon(t),h("span",{class:CSS$1.title},this.textLabel)),this.renderChildren()))};Object.defineProperty(e.prototype,"el",{get:function(){return getElement(this)},enumerable:false,configurable:true});Object.defineProperty(e,"watchers",{get:function(){return{selected:["selectedWatchHandler"]}},enumerable:false,configurable:true});return e}();CalciteComboboxItem.style=calciteComboboxItemCss;var CSS={list:"list",label:"label",title:"title"};var calciteComboboxItemGroupCss="@-webkit-keyframes in{0%{opacity:0}100%{opacity:1}}@keyframes in{0%{opacity:0}100%{opacity:1}}@-webkit-keyframes in-down{0%{opacity:0;-webkit-transform:translate3D(0, -5px, 0);transform:translate3D(0, -5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@keyframes in-down{0%{opacity:0;-webkit-transform:translate3D(0, -5px, 0);transform:translate3D(0, -5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@-webkit-keyframes in-up{0%{opacity:0;-webkit-transform:translate3D(0, 5px, 0);transform:translate3D(0, 5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@keyframes in-up{0%{opacity:0;-webkit-transform:translate3D(0, 5px, 0);transform:translate3D(0, 5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@-webkit-keyframes in-scale{0%{opacity:0;-webkit-transform:scale3D(0.95, 0.95, 1);transform:scale3D(0.95, 0.95, 1)}100%{opacity:1;-webkit-transform:scale3D(1, 1, 1);transform:scale3D(1, 1, 1)}}@keyframes in-scale{0%{opacity:0;-webkit-transform:scale3D(0.95, 0.95, 1);transform:scale3D(0.95, 0.95, 1)}100%{opacity:1;-webkit-transform:scale3D(1, 1, 1);transform:scale3D(1, 1, 1)}}:root{--calcite-animation-timing:calc(150ms * var(--calcite-internal-duration-factor));--calcite-internal-duration-factor:var(--calcite-duration-factor, 1);--calcite-internal-animation-timing-fast:calc(100ms * var(--calcite-internal-duration-factor));--calcite-internal-animation-timing-medium:calc(200ms * var(--calcite-internal-duration-factor));--calcite-internal-animation-timing-slow:calc(300ms * var(--calcite-internal-duration-factor))}.calcite-animate{opacity:0;-webkit-animation-fill-mode:both;animation-fill-mode:both;-webkit-animation-duration:var(--calcite-animation-timing);animation-duration:var(--calcite-animation-timing)}.calcite-animate__in{-webkit-animation-name:in;animation-name:in}.calcite-animate__in-down{-webkit-animation-name:in-down;animation-name:in-down}.calcite-animate__in-up{-webkit-animation-name:in-up;animation-name:in-up}.calcite-animate__in-scale{-webkit-animation-name:in-scale;animation-name:in-scale}:root{--calcite-popper-transition:var(--calcite-animation-timing)}:host([hidden]){display:none}.scale--s{font-size:var(--calcite-font-size--2);line-height:1rem;--calcite-combobox-item-spacing-unit-l:0.5rem;--calcite-combobox-item-spacing-unit-s:0.25rem;--calcite-combobox-item-spacing-indent-1:0.5rem;--calcite-combobox-item-spacing-indent-2:1rem}.scale--m{font-size:var(--calcite-font-size--1);line-height:1rem;--calcite-combobox-item-spacing-unit-l:0.75rem;--calcite-combobox-item-spacing-unit-s:0.5rem;--calcite-combobox-item-spacing-indent-1:0.75rem;--calcite-combobox-item-spacing-indent-2:1.5rem}.scale--l{font-size:var(--calcite-font-size-0);line-height:1.25rem;--calcite-combobox-item-spacing-unit-l:1rem;--calcite-combobox-item-spacing-unit-s:0.75rem;--calcite-combobox-item-spacing-indent-1:1rem;--calcite-combobox-item-spacing-indent-2:2rem}:host,.list{margin:0px;display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;padding:0px;outline:2px solid transparent;outline-offset:2px}.label{-webkit-box-sizing:border-box;box-sizing:border-box;display:-ms-flexbox;display:flex;width:100%;min-width:0px;max-width:100%;color:var(--calcite-ui-text-3)}.label--indent-1{-webkit-padding-start:var(--calcite-combobox-item-spacing-indent-1);padding-inline-start:var(--calcite-combobox-item-spacing-indent-1)}.label--indent-2{-webkit-padding-start:var(--calcite-combobox-item-spacing-indent-2);padding-inline-start:var(--calcite-combobox-item-spacing-indent-2)}.title{border:0 solid;display:block;-ms-flex:1 1 0%;flex:1 1 0%;border-bottom-width:1px;font-weight:var(--calcite-font-weight-bold);color:var(--calcite-ui-text-2);word-wrap:break-word;word-break:break-word;border-bottom-color:var(--calcite-ui-border-3);padding:var(--calcite-combobox-item-spacing-unit-l) 0;margin-left:var(--calcite-combobox-item-spacing-unit-s);margin-right:var(--calcite-combobox-item-spacing-unit-s)}";var CalciteComboboxItemGroup=function(){function e(e){registerInstance(this,e);this.guid=guid();this.scale="m"}e.prototype.connectedCallback=function(){this.ancestors=getAncestors(this.el);this.scale=getElementProp(this.el,"scale",this.scale)};e.prototype.render=function(){var e,t;var i=this,n=i.el,a=i.scale;var o=CSS.label+"--indent-"+getDepth(n);return h("ul",{"aria-labelledby":this.guid,class:(e={},e[CSS.list]=true,e["scale--"+a]=true,e),role:"group"},h("li",{class:(t={},t[CSS.label]=true,t[o]=true,t),id:this.guid,role:"presentation"},h("span",{class:CSS.title},this.label)),h("slot",null))};Object.defineProperty(e.prototype,"el",{get:function(){return getElement(this)},enumerable:false,configurable:true});return e}();CalciteComboboxItemGroup.style=calciteComboboxItemGroupCss;export{CalciteCombobox as calcite_combobox,CalciteComboboxItem as calcite_combobox_item,CalciteComboboxItemGroup as calcite_combobox_item_group};
|