@esri/calcite-components 1.1.0 → 1.1.1-next.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/calcite/calcite.esm.js +2 -2
- package/dist/calcite/index.esm.js +1 -1
- package/dist/calcite/p-067c6cbe.entry.js +6 -0
- package/dist/calcite/p-0bbe6a3f.entry.js +6 -0
- package/dist/calcite/{p-bb1240f3.js → p-0e573040.js} +1 -1
- package/dist/calcite/{p-e370cd2d.entry.js → p-104568ad.entry.js} +2 -2
- package/dist/calcite/{p-721d4a15.entry.js → p-10bb5f12.entry.js} +2 -2
- package/dist/calcite/{p-45aba393.entry.js → p-133e4307.entry.js} +2 -2
- package/dist/calcite/p-139f6eb1.entry.js +6 -0
- package/dist/calcite/p-1514dfff.entry.js +6 -0
- package/dist/calcite/{p-1e3db270.entry.js → p-1842016b.entry.js} +2 -2
- package/dist/calcite/{p-c097b143.js → p-1e3ad5b6.js} +1 -1
- package/dist/calcite/p-1e8e8583.entry.js +6 -0
- package/dist/calcite/{p-b3a9a53c.entry.js → p-1f0fe3f5.entry.js} +2 -2
- package/dist/calcite/{p-f27daa9e.entry.js → p-1fa03249.entry.js} +2 -2
- package/dist/calcite/p-23c7e19d.entry.js +6 -0
- package/dist/calcite/p-25b59b64.entry.js +6 -0
- package/dist/calcite/p-25d10f33.js +6 -0
- package/dist/calcite/{p-7e570f52.entry.js → p-26bef7a5.entry.js} +2 -2
- package/dist/calcite/{p-145b7cdc.js → p-2c2c6832.js} +2 -2
- package/dist/calcite/{p-443e7495.js → p-32e6bbaa.js} +1 -1
- package/dist/calcite/{p-92c57358.entry.js → p-3495b764.entry.js} +2 -2
- package/dist/calcite/p-37f940cd.entry.js +6 -0
- package/dist/calcite/{p-a5d23ef8.js → p-39379a0e.js} +2 -2
- package/dist/calcite/p-3aed468d.entry.js +6 -0
- package/dist/calcite/p-3ffb9150.entry.js +6 -0
- package/dist/calcite/{p-0a7542f8.entry.js → p-43004a5b.entry.js} +2 -2
- package/dist/calcite/{p-28ee997e.entry.js → p-4472eec9.entry.js} +2 -2
- package/dist/calcite/{p-b4f3b351.js → p-460c2796.js} +2 -2
- package/dist/calcite/{p-0743cc15.entry.js → p-47c49085.entry.js} +2 -2
- package/dist/calcite/{p-5738ec05.entry.js → p-49660b47.entry.js} +2 -2
- package/dist/calcite/p-4cf4fcda.entry.js +6 -0
- package/dist/calcite/{p-6ebb0713.entry.js → p-4e032aba.entry.js} +2 -2
- package/dist/calcite/{p-81a8751c.entry.js → p-5167e5bd.entry.js} +2 -2
- package/dist/calcite/p-53515d24.js +6 -0
- package/dist/calcite/{p-6293ed16.js → p-53f86dbe.js} +1 -1
- package/dist/calcite/{p-cc1203c0.entry.js → p-560b83a5.entry.js} +2 -2
- package/dist/calcite/p-5cc1689c.entry.js +6 -0
- package/dist/calcite/{p-291b75d5.entry.js → p-5e51a007.entry.js} +2 -2
- package/dist/calcite/p-630c919b.entry.js +6 -0
- package/dist/calcite/p-64797899.entry.js +6 -0
- package/dist/calcite/p-66e10f50.entry.js +6 -0
- package/dist/calcite/p-67c4a675.entry.js +6 -0
- package/dist/calcite/{p-e5e67c4b.entry.js → p-67c57a3e.entry.js} +2 -2
- package/dist/calcite/{p-f91b9012.entry.js → p-6d384c72.entry.js} +2 -2
- package/dist/calcite/{p-7aee1b7a.js → p-6e2469fa.js} +1 -1
- package/dist/calcite/p-6ead2a0a.entry.js +6 -0
- package/dist/calcite/{p-ba3e198d.entry.js → p-70d1240e.entry.js} +2 -2
- package/dist/calcite/p-734c9ad7.entry.js +6 -0
- package/dist/calcite/{p-8190fef7.entry.js → p-7745ec84.entry.js} +2 -2
- package/dist/calcite/{p-75651de9.js → p-775bed66.js} +2 -2
- package/dist/calcite/{p-9a811534.js → p-7deb0edd.js} +2 -2
- package/dist/calcite/{p-5e822482.js → p-80344704.js} +1 -1
- package/dist/calcite/{p-941bc30e.entry.js → p-80370275.entry.js} +2 -2
- package/dist/calcite/p-82347c12.entry.js +6 -0
- package/dist/calcite/{p-32d3d2c6.js → p-83b37109.js} +1 -1
- package/dist/calcite/{p-7d37e5a3.entry.js → p-8749d63f.entry.js} +2 -2
- package/dist/calcite/{p-e683cacc.entry.js → p-8b5dbdcb.entry.js} +2 -2
- package/dist/calcite/p-941fee1b.js +6 -0
- package/dist/calcite/{p-d841eb93.entry.js → p-94a96a85.entry.js} +2 -2
- package/dist/calcite/p-95829133.js +6 -0
- package/dist/calcite/{p-0df568c3.entry.js → p-962be3b6.entry.js} +2 -2
- package/dist/calcite/p-983244bc.js +7 -0
- package/dist/calcite/{p-0534cef5.js → p-9d18f5bb.js} +1 -1
- package/dist/calcite/{p-b90df3dd.js → p-9f094be8.js} +1 -1
- package/dist/calcite/{p-09b4dbc1.entry.js → p-ad65a76c.entry.js} +2 -2
- package/dist/calcite/{p-adef0422.js → p-aeb9de45.js} +1 -1
- package/dist/calcite/{p-eaad3707.entry.js → p-b1b90aed.entry.js} +2 -2
- package/dist/calcite/p-b3bbd12b.entry.js +6 -0
- package/dist/calcite/p-b8b075fd.js +6 -0
- package/dist/calcite/{p-041d0f9f.entry.js → p-bab02490.entry.js} +2 -2
- package/dist/calcite/p-c415f7b2.entry.js +6 -0
- package/dist/calcite/{p-9e7d290a.entry.js → p-c92eb528.entry.js} +2 -2
- package/dist/calcite/{p-b2fd4072.entry.js → p-cf386d4e.entry.js} +2 -2
- package/dist/calcite/{p-b4c2f2ce.js → p-cff554c3.js} +3 -3
- package/dist/calcite/{p-5e2b13eb.js → p-d26a147b.js} +2 -2
- package/dist/calcite/p-d70da26b.js +6 -0
- package/dist/calcite/{p-df405411.entry.js → p-db86773b.entry.js} +2 -2
- package/dist/calcite/{p-747d2b6e.entry.js → p-db9aa481.entry.js} +2 -2
- package/dist/calcite/{p-6cc03406.js → p-e2ca6e76.js} +1 -1
- package/dist/calcite/{p-f44952aa.js → p-e37654ca.js} +2 -2
- package/dist/calcite/{p-3abc3397.entry.js → p-e47bbde3.entry.js} +2 -2
- package/dist/calcite/p-e4f9071c.entry.js +6 -0
- package/dist/calcite/p-e8d4a499.js +10 -0
- package/dist/calcite/p-ebd84c48.js +6 -0
- package/dist/calcite/p-ec5edf75.js +12 -0
- package/dist/calcite/{p-ce6a7f8c.js → p-eca57069.js} +2 -2
- package/dist/calcite/p-eeddb289.entry.js +6 -0
- package/dist/calcite/{p-b9421f54.entry.js → p-effb2cc1.entry.js} +2 -2
- package/dist/calcite/{p-de571c36.entry.js → p-f7a52b3e.entry.js} +2 -2
- package/dist/calcite/{p-6f9b73aa.js → p-f8020b13.js} +1 -1
- package/dist/calcite/{p-4a902f71.entry.js → p-f9e67ecd.entry.js} +2 -2
- package/dist/calcite/{p-fda34bfd.js → p-fa1fa6dd.js} +1 -1
- package/dist/calcite/{p-8a48ce07.entry.js → p-fd14d3a1.entry.js} +2 -2
- package/dist/cjs/{ExpandToggle-a335cfb1.js → ExpandToggle-0e681d38.js} +5 -5
- package/dist/cjs/{Heading-d361823f.js → Heading-7929d895.js} +2 -2
- package/dist/cjs/{app-globals-a113245f.js → app-globals-de4fc983.js} +2 -2
- package/dist/cjs/{array-2d1e4569.js → array-243ae59e.js} +1 -1
- package/dist/cjs/calcite-accordion_2.cjs.entry.js +8 -8
- package/dist/cjs/calcite-action-bar.cjs.entry.js +15 -15
- package/dist/cjs/calcite-action-group.cjs.entry.js +12 -12
- package/dist/cjs/calcite-action-menu.cjs.entry.js +9 -9
- package/dist/cjs/calcite-action-pad.cjs.entry.js +14 -14
- package/dist/cjs/calcite-action.cjs.entry.js +11 -11
- package/dist/cjs/calcite-alert.cjs.entry.js +12 -12
- package/dist/cjs/calcite-avatar.cjs.entry.js +6 -6
- package/dist/cjs/calcite-block_2.cjs.entry.js +12 -12
- package/dist/cjs/calcite-button.cjs.entry.js +13 -41
- package/dist/cjs/calcite-card.cjs.entry.js +10 -10
- package/dist/cjs/calcite-checkbox.cjs.entry.js +10 -10
- package/dist/cjs/calcite-chip.cjs.entry.js +11 -11
- package/dist/cjs/calcite-color-picker_3.cjs.entry.js +14 -14
- package/dist/cjs/calcite-combobox_3.cjs.entry.js +18 -18
- package/dist/cjs/calcite-date-picker_4.cjs.entry.js +12 -12
- package/dist/cjs/calcite-dropdown_3.cjs.entry.js +12 -12
- package/dist/cjs/calcite-fab.cjs.entry.js +7 -7
- package/dist/cjs/calcite-filter.cjs.entry.js +13 -13
- package/dist/cjs/calcite-flow-item.cjs.entry.js +12 -12
- package/dist/cjs/calcite-flow.cjs.entry.js +3 -3
- package/dist/cjs/calcite-graph_2.cjs.entry.js +13 -13
- package/dist/cjs/calcite-handle.cjs.entry.js +10 -10
- package/dist/cjs/calcite-icon.cjs.entry.js +6 -6
- package/dist/cjs/calcite-inline-editable.cjs.entry.js +12 -12
- package/dist/cjs/calcite-input-date-picker.cjs.entry.js +16 -16
- package/dist/cjs/calcite-input-message.cjs.entry.js +5 -5
- package/dist/cjs/calcite-input-number.cjs.entry.js +13 -13
- package/dist/cjs/calcite-input-text.cjs.entry.js +13 -13
- package/dist/cjs/calcite-input-time-picker_2.cjs.entry.js +13 -13
- package/dist/cjs/calcite-input.cjs.entry.js +13 -13
- package/dist/cjs/calcite-label.cjs.entry.js +6 -6
- package/dist/cjs/calcite-link.cjs.entry.js +7 -7
- package/dist/cjs/calcite-list_3.cjs.entry.js +9 -9
- package/dist/cjs/calcite-loader.cjs.entry.js +3 -3
- package/dist/cjs/calcite-modal.cjs.entry.js +13 -13
- package/dist/cjs/calcite-notice.cjs.entry.js +12 -12
- package/dist/cjs/calcite-option_3.cjs.entry.js +10 -10
- package/dist/cjs/calcite-pagination.cjs.entry.js +9 -9
- package/dist/cjs/calcite-panel.cjs.entry.js +14 -14
- package/dist/cjs/calcite-pick-list_3.cjs.entry.js +16 -16
- package/dist/cjs/calcite-popover.cjs.entry.js +15 -15
- package/dist/cjs/calcite-progress.cjs.entry.js +2 -2
- package/dist/cjs/calcite-radio-button-group.cjs.entry.js +3 -3
- package/dist/cjs/calcite-radio-button.cjs.entry.js +10 -10
- package/dist/cjs/calcite-rating.cjs.entry.js +13 -13
- package/dist/cjs/calcite-scrim.cjs.entry.js +9 -9
- package/dist/cjs/calcite-segmented-control_2.cjs.entry.js +9 -9
- package/dist/cjs/calcite-shell_3.cjs.entry.js +11 -11
- package/dist/cjs/calcite-sortable-list.cjs.entry.js +5 -5
- package/dist/cjs/calcite-split-button.cjs.entry.js +3 -3
- package/dist/cjs/calcite-stepper_2.cjs.entry.js +10 -10
- package/dist/cjs/calcite-switch.cjs.entry.js +10 -10
- package/dist/cjs/calcite-tab_4.cjs.entry.js +7 -7
- package/dist/cjs/calcite-tile-select_2.cjs.entry.js +5 -5
- package/dist/cjs/calcite-tile.cjs.entry.js +8 -8
- package/dist/cjs/calcite-tip_3.cjs.entry.js +11 -11
- package/dist/cjs/calcite-tooltip.cjs.entry.js +8 -8
- package/dist/cjs/calcite-tree_2.cjs.entry.js +9 -9
- package/dist/cjs/calcite-value-list_2.cjs.entry.js +16 -16
- package/dist/cjs/calcite.cjs.js +10 -6
- package/dist/cjs/{conditionalSlot-3a4fe2dc.js → conditionalSlot-19a6d3cb.js} +3 -3
- package/dist/cjs/{debounce-408eb927.js → debounce-3cc57c75.js} +1 -1
- package/dist/cjs/{dom-553866e5.js → dom-e0a2d0ae.js} +3 -3
- package/dist/cjs/{filter-501e11ad.js → filter-079fefb4.js} +2 -2
- package/dist/cjs/{floating-ui-54f4c5a9.js → floating-ui-4daec94e.js} +4 -4
- package/dist/cjs/{focusTrapComponent-5bcf753e.js → focusTrapComponent-f253c50b.js} +2 -2
- package/dist/cjs/{form-bffda67a.js → form-9a7669e1.js} +32 -4
- package/dist/cjs/{guid-6bebe20b.js → guid-fde5f7dd.js} +1 -1
- package/dist/cjs/{index-16b54251.js → index-c29fa197.js} +112 -3
- package/dist/cjs/index.cjs.js +1 -1
- package/dist/cjs/{interactive-9a753e3b.js → interactive-3f517a3e.js} +1 -1
- package/dist/cjs/{key-b11206cb.js → key-39bacf88.js} +1 -1
- package/dist/cjs/{label-06c122f9.js → label-f9e570e2.js} +2 -2
- package/dist/cjs/{loadable-03215740.js → loadable-40964a10.js} +1 -1
- package/dist/cjs/loader.cjs.js +7 -6
- package/dist/cjs/{locale-8539ef25.js → locale-d3df84e5.js} +4 -4
- package/dist/cjs/{math-acfe02f4.js → math-f7554e54.js} +1 -1
- package/dist/cjs/{observers-ef9e3899.js → observers-151ad03f.js} +1 -1
- package/dist/cjs/{openCloseComponent-ce345b01.js → openCloseComponent-cbd1cf92.js} +2 -2
- package/dist/cjs/{resources-379e317d.js → resources-29d69c62.js} +1 -1
- package/dist/cjs/{resources-305406be.js → resources-4e7a2c85.js} +1 -1
- package/dist/cjs/{resources-b829d4a6.js → resources-87806253.js} +5 -5
- package/dist/cjs/{resources-bd729e69.js → resources-a49039d3.js} +1 -1
- package/dist/cjs/{resources-d4657a03.js → resources-b3485589.js} +1 -1
- package/dist/cjs/{resources-9f12de5f.js → resources-c5ad9882.js} +1 -1
- package/dist/cjs/{sortable.esm-6dea5d6e.js → sortable.esm-1f85cd7b.js} +1 -1
- package/dist/cjs/{t9n-64e84ec9.js → t9n-96cbfc9b.js} +3 -3
- package/dist/cjs/{utils-6539bbb0.js → utils-2a0cb4f5.js} +1 -1
- package/dist/cjs/{utils-4aac28db.js → utils-2eab20f9.js} +3 -3
- package/dist/cjs/{utils-9af7bb5a.js → utils-8224563b.js} +1 -1
- package/dist/collection/collection-manifest.json +2 -2
- package/dist/collection/components/accordion/accordion.js +1 -1
- package/dist/collection/components/accordion-item/accordion-item.css +2 -0
- package/dist/collection/components/accordion-item/accordion-item.js +1 -1
- package/dist/collection/components/accordion-item/resources.js +1 -1
- package/dist/collection/components/action/action.js +1 -1
- package/dist/collection/components/action/resources.js +1 -1
- package/dist/collection/components/action-bar/action-bar.js +1 -1
- package/dist/collection/components/action-bar/resources.js +1 -1
- package/dist/collection/components/action-bar/utils.js +1 -1
- package/dist/collection/components/action-group/action-group.js +1 -1
- package/dist/collection/components/action-group/resources.js +1 -1
- package/dist/collection/components/action-menu/action-menu.js +1 -1
- package/dist/collection/components/action-menu/resources.js +1 -1
- package/dist/collection/components/action-pad/action-pad.js +1 -1
- package/dist/collection/components/action-pad/resources.js +1 -1
- package/dist/collection/components/alert/alert.js +1 -1
- package/dist/collection/components/alert/resources.js +1 -1
- package/dist/collection/components/avatar/avatar.js +1 -1
- package/dist/collection/components/avatar/utils.js +1 -1
- package/dist/collection/components/block/block.js +1 -1
- package/dist/collection/components/block/resources.js +1 -1
- package/dist/collection/components/block-section/block-section.js +1 -1
- package/dist/collection/components/block-section/resources.js +1 -1
- package/dist/collection/components/button/button.js +2 -3
- package/dist/collection/components/button/resources.js +1 -1
- package/dist/collection/components/card/card.js +1 -1
- package/dist/collection/components/card/resources.js +1 -1
- package/dist/collection/components/checkbox/checkbox.js +2 -2
- package/dist/collection/components/chip/chip.js +2 -2
- package/dist/collection/components/chip/resources.js +1 -1
- package/dist/collection/components/color-picker/color-picker.js +1 -1
- package/dist/collection/components/color-picker/resources.js +1 -1
- package/dist/collection/components/color-picker/utils.js +1 -1
- package/dist/collection/components/color-picker-hex-input/color-picker-hex-input.js +1 -1
- package/dist/collection/components/color-picker-hex-input/resources.js +1 -1
- package/dist/collection/components/color-picker-swatch/color-picker-swatch.js +1 -1
- package/dist/collection/components/color-picker-swatch/resources.js +1 -1
- package/dist/collection/components/combobox/combobox.js +1 -1
- package/dist/collection/components/combobox/resources.js +1 -1
- package/dist/collection/components/combobox/utils.js +1 -1
- package/dist/collection/components/combobox-item/combobox-item.js +1 -1
- package/dist/collection/components/combobox-item/resources.js +1 -1
- package/dist/collection/components/combobox-item-group/combobox-item-group.js +1 -1
- package/dist/collection/components/combobox-item-group/resources.js +1 -1
- package/dist/collection/components/date-picker/date-picker.js +3 -3
- package/dist/collection/components/date-picker/resources.js +1 -1
- package/dist/collection/components/date-picker/utils.js +1 -1
- package/dist/collection/components/date-picker-day/date-picker-day.js +1 -1
- package/dist/collection/components/date-picker-month/date-picker-month.js +1 -1
- package/dist/collection/components/date-picker-month-header/date-picker-month-header.js +1 -1
- package/dist/collection/components/date-picker-month-header/resources.js +1 -1
- package/dist/collection/components/dropdown/dropdown.js +1 -1
- package/dist/collection/components/dropdown/resources.js +1 -1
- package/dist/collection/components/dropdown-group/dropdown-group.js +1 -1
- package/dist/collection/components/dropdown-group/resources.js +1 -1
- package/dist/collection/components/dropdown-item/dropdown-item.js +1 -1
- package/dist/collection/components/dropdown-item/resources.js +1 -1
- package/dist/collection/components/fab/fab.js +1 -1
- package/dist/collection/components/fab/resources.js +1 -1
- package/dist/collection/components/filter/filter.js +2 -2
- package/dist/collection/components/filter/resources.js +1 -1
- package/dist/collection/components/flow/flow.js +1 -1
- package/dist/collection/components/flow/resources.js +1 -1
- package/dist/collection/components/flow-item/flow-item.js +3 -3
- package/dist/collection/components/flow-item/resources.js +1 -1
- package/dist/collection/components/functional/ExpandToggle.js +1 -1
- package/dist/collection/components/functional/Heading.js +1 -1
- package/dist/collection/components/graph/graph.js +1 -1
- package/dist/collection/components/graph/util.js +1 -1
- package/dist/collection/components/handle/handle.js +1 -1
- package/dist/collection/components/handle/resources.js +1 -1
- package/dist/collection/components/icon/icon.js +1 -1
- package/dist/collection/components/icon/resources.js +1 -1
- package/dist/collection/components/icon/utils.js +1 -1
- package/dist/collection/components/inline-editable/inline-editable.js +1 -1
- package/dist/collection/components/inline-editable/resources.js +1 -1
- package/dist/collection/components/input/input.js +1 -1
- package/dist/collection/components/input/resources.js +1 -1
- package/dist/collection/components/input-date-picker/input-date-picker.js +3 -3
- package/dist/collection/components/input-date-picker/resources.js +1 -1
- package/dist/collection/components/input-message/input-message.js +2 -2
- package/dist/collection/components/input-message/interfaces.js +1 -1
- package/dist/collection/components/input-number/input-number.js +2 -2
- package/dist/collection/components/input-number/resources.js +1 -1
- package/dist/collection/components/input-text/input-text.js +2 -2
- package/dist/collection/components/input-text/resources.js +1 -1
- package/dist/collection/components/input-time-picker/input-time-picker.js +1 -1
- package/dist/collection/components/label/label.js +1 -1
- package/dist/collection/components/label/resources.js +1 -1
- package/dist/collection/components/link/link.js +1 -1
- package/dist/collection/components/list/list.js +1 -1
- package/dist/collection/components/list/resources.js +1 -1
- package/dist/collection/components/list-item/list-item.js +1 -1
- package/dist/collection/components/list-item/resources.js +1 -1
- package/dist/collection/components/list-item/utils.js +1 -1
- package/dist/collection/components/list-item-group/list-item-group.js +1 -1
- package/dist/collection/components/list-item-group/resources.js +1 -1
- package/dist/collection/components/loader/loader.js +1 -1
- package/dist/collection/components/modal/modal.js +1 -1
- package/dist/collection/components/modal/resources.js +1 -1
- package/dist/collection/components/notice/notice.js +1 -1
- package/dist/collection/components/notice/resources.js +1 -1
- package/dist/collection/components/option/option.js +1 -1
- package/dist/collection/components/option-group/option-group.js +1 -1
- package/dist/collection/components/pagination/pagination.js +1 -1
- package/dist/collection/components/pagination/resources.js +1 -1
- package/dist/collection/components/panel/panel.js +2 -2
- package/dist/collection/components/panel/resources.js +1 -1
- package/dist/collection/components/pick-list/pick-list.js +1 -1
- package/dist/collection/components/pick-list/resources.js +1 -1
- package/dist/collection/components/pick-list/shared-list-logic.js +1 -1
- package/dist/collection/components/pick-list/shared-list-render.js +1 -1
- package/dist/collection/components/pick-list-group/pick-list-group.js +1 -1
- package/dist/collection/components/pick-list-group/resources.js +1 -1
- package/dist/collection/components/pick-list-item/pick-list-item.js +1 -1
- package/dist/collection/components/pick-list-item/resources.js +1 -1
- package/dist/collection/components/popover/PopoverManager.js +1 -1
- package/dist/collection/components/popover/popover.js +2 -2
- package/dist/collection/components/popover/resources.js +1 -1
- package/dist/collection/components/progress/progress.js +1 -1
- package/dist/collection/components/radio-button/radio-button.js +1 -1
- package/dist/collection/components/radio-button/resources.js +1 -1
- package/dist/collection/components/radio-button-group/radio-button-group.js +1 -1
- package/dist/collection/components/rating/function/star.js +1 -1
- package/dist/collection/components/rating/rating.js +1 -1
- package/dist/collection/components/resources.js +1 -1
- package/dist/collection/components/scrim/resources.js +1 -1
- package/dist/collection/components/scrim/scrim.js +1 -1
- package/dist/collection/components/segmented-control/segmented-control.js +1 -1
- package/dist/collection/components/segmented-control-item/resources.js +1 -1
- package/dist/collection/components/segmented-control-item/segmented-control-item.js +1 -1
- package/dist/collection/components/select/resources.js +1 -1
- package/dist/collection/components/select/select.js +1 -1
- package/dist/collection/components/shell/resources.js +1 -1
- package/dist/collection/components/shell/shell.js +1 -1
- package/dist/collection/components/shell-center-row/resources.js +1 -1
- package/dist/collection/components/shell-center-row/shell-center-row.js +1 -1
- package/dist/collection/components/shell-panel/resources.js +1 -1
- package/dist/collection/components/shell-panel/shell-panel.js +1 -1
- package/dist/collection/components/slider/resources.js +1 -1
- package/dist/collection/components/slider/slider.js +1 -1
- package/dist/collection/components/sortable-list/resources.js +1 -1
- package/dist/collection/components/sortable-list/sortable-list.js +1 -1
- package/dist/collection/components/split-button/resources.js +1 -1
- package/dist/collection/components/split-button/split-button.js +1 -1
- package/dist/collection/components/stepper/stepper.js +1 -1
- package/dist/collection/components/stepper-item/stepper-item.js +1 -1
- package/dist/collection/components/switch/switch.js +1 -1
- package/dist/collection/components/tab/tab.js +1 -1
- package/dist/collection/components/tab-nav/tab-nav.js +1 -1
- package/dist/collection/components/tab-title/resources.js +1 -1
- package/dist/collection/components/tab-title/tab-title.js +1 -1
- package/dist/collection/components/tabs/resources.js +1 -1
- package/dist/collection/components/tabs/tabs.js +3 -3
- package/dist/collection/components/tile/resources.js +1 -1
- package/dist/collection/components/tile/tile.js +1 -1
- package/dist/collection/components/tile-select/resources.js +1 -1
- package/dist/collection/components/tile-select/tile-select.js +1 -1
- package/dist/collection/components/tile-select-group/tile-select-group.js +1 -1
- package/dist/collection/components/time-picker/resources.js +1 -1
- package/dist/collection/components/time-picker/time-picker.js +1 -1
- package/dist/collection/components/tip/resources.js +1 -1
- package/dist/collection/components/tip/tip.js +1 -1
- package/dist/collection/components/tip-group/tip-group.js +1 -1
- package/dist/collection/components/tip-manager/resources.js +1 -1
- package/dist/collection/components/tip-manager/tip-manager.js +1 -1
- package/dist/collection/components/tooltip/TooltipManager.js +1 -1
- package/dist/collection/components/tooltip/resources.js +1 -1
- package/dist/collection/components/tooltip/tooltip.js +1 -1
- package/dist/collection/components/tooltip/utils.js +1 -1
- package/dist/collection/components/tree/tree.js +1 -1
- package/dist/collection/components/tree/utils.js +1 -1
- package/dist/collection/components/tree-item/resources.js +1 -1
- package/dist/collection/components/tree-item/tree-item.js +1 -1
- package/dist/collection/components/value-list/resources.js +1 -1
- package/dist/collection/components/value-list/utils.js +1 -1
- package/dist/collection/components/value-list/value-list.js +1 -1
- package/dist/collection/components/value-list-item/resources.js +1 -1
- package/dist/collection/components/value-list-item/value-list-item.js +1 -1
- package/dist/collection/utils/array.js +1 -1
- package/dist/collection/utils/conditionalSlot.js +1 -1
- package/dist/collection/utils/config.js +1 -1
- package/dist/collection/utils/date.js +1 -1
- package/dist/collection/utils/dom.js +1 -1
- package/dist/collection/utils/filter.js +1 -1
- package/dist/collection/utils/floating-ui/utils.js +1 -1
- package/dist/collection/utils/floating-ui.js +1 -1
- package/dist/collection/utils/focusTrapComponent.js +1 -1
- package/dist/collection/utils/form.js +3 -2
- package/dist/collection/utils/globalAttributes.js +1 -1
- package/dist/collection/utils/globalScript.js +1 -1
- package/dist/collection/utils/guid.js +1 -1
- package/dist/collection/utils/interactive.js +1 -1
- package/dist/collection/utils/key.js +1 -1
- package/dist/collection/utils/label.js +1 -1
- package/dist/collection/utils/loadable.js +1 -1
- package/dist/collection/utils/locale.js +1 -1
- package/dist/collection/utils/math.js +1 -1
- package/dist/collection/utils/mode.js +1 -1
- package/dist/collection/utils/number.js +1 -1
- package/dist/collection/utils/observers.js +1 -1
- package/dist/collection/utils/openCloseComponent.js +1 -1
- package/dist/collection/utils/resources.js +1 -1
- package/dist/collection/utils/t9n.js +1 -1
- package/dist/collection/utils/time.js +1 -1
- package/dist/components/ExpandToggle.js +1 -1
- package/dist/components/Heading.js +1 -1
- package/dist/components/action-group.js +1 -1
- package/dist/components/action-menu.js +1 -1
- package/dist/components/action.js +1 -1
- package/dist/components/array.js +1 -1
- package/dist/components/button.js +4 -32
- package/dist/components/calcite-accordion-item.js +2 -2
- package/dist/components/calcite-accordion.js +1 -1
- package/dist/components/calcite-action-bar.js +1 -1
- package/dist/components/calcite-action-group.js +1 -1
- package/dist/components/calcite-action-menu.js +1 -1
- package/dist/components/calcite-action-pad.js +1 -1
- package/dist/components/calcite-action.js +1 -1
- package/dist/components/calcite-alert.js +1 -1
- package/dist/components/calcite-avatar.js +1 -1
- package/dist/components/calcite-block-section.js +1 -1
- package/dist/components/calcite-block.js +1 -1
- package/dist/components/calcite-button.js +1 -1
- package/dist/components/calcite-card.js +1 -1
- package/dist/components/calcite-checkbox.js +1 -1
- package/dist/components/calcite-chip.js +1 -1
- package/dist/components/calcite-color-picker-hex-input.js +1 -1
- package/dist/components/calcite-color-picker-swatch.js +1 -1
- 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 +1 -1
- package/dist/components/calcite-combobox.js +1 -1
- package/dist/components/calcite-date-picker-day.js +1 -1
- package/dist/components/calcite-date-picker-month-header.js +1 -1
- package/dist/components/calcite-date-picker-month.js +1 -1
- package/dist/components/calcite-date-picker.js +1 -1
- package/dist/components/calcite-dropdown-group.js +1 -1
- package/dist/components/calcite-dropdown-item.js +1 -1
- package/dist/components/calcite-dropdown.js +1 -1
- package/dist/components/calcite-fab.js +1 -1
- package/dist/components/calcite-filter.js +1 -1
- package/dist/components/calcite-flow-item.js +3 -3
- package/dist/components/calcite-flow.js +1 -1
- package/dist/components/calcite-graph.js +1 -1
- package/dist/components/calcite-handle.js +1 -1
- package/dist/components/calcite-icon.js +1 -1
- package/dist/components/calcite-inline-editable.js +1 -1
- package/dist/components/calcite-input-date-picker.js +3 -3
- package/dist/components/calcite-input-message.js +2 -2
- package/dist/components/calcite-input-number.js +2 -2
- package/dist/components/calcite-input-text.js +2 -2
- package/dist/components/calcite-input-time-picker.js +1 -1
- package/dist/components/calcite-input.js +1 -1
- package/dist/components/calcite-label.js +1 -1
- package/dist/components/calcite-link.js +1 -1
- package/dist/components/calcite-list-item-group.js +1 -1
- package/dist/components/calcite-list-item.js +1 -1
- package/dist/components/calcite-list.js +1 -1
- package/dist/components/calcite-loader.js +1 -1
- package/dist/components/calcite-modal.js +1 -1
- package/dist/components/calcite-notice.js +1 -1
- 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 +1 -1
- package/dist/components/calcite-pick-list-group.js +1 -1
- package/dist/components/calcite-pick-list-item.js +1 -1
- package/dist/components/calcite-pick-list.js +1 -1
- package/dist/components/calcite-popover.js +1 -1
- package/dist/components/calcite-progress.js +1 -1
- package/dist/components/calcite-radio-button-group.js +1 -1
- package/dist/components/calcite-radio-button.js +1 -1
- package/dist/components/calcite-rating.js +1 -1
- package/dist/components/calcite-scrim.js +1 -1
- package/dist/components/calcite-segmented-control-item.js +1 -1
- package/dist/components/calcite-segmented-control.js +1 -1
- package/dist/components/calcite-select.js +1 -1
- package/dist/components/calcite-shell-center-row.js +1 -1
- package/dist/components/calcite-shell-panel.js +1 -1
- package/dist/components/calcite-shell.js +1 -1
- package/dist/components/calcite-slider.js +1 -1
- 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-switch.js +1 -1
- package/dist/components/calcite-tab-nav.js +1 -1
- package/dist/components/calcite-tab-title.js +1 -1
- package/dist/components/calcite-tab.js +1 -1
- package/dist/components/calcite-tabs.js +1 -1
- package/dist/components/calcite-tile-select-group.js +1 -1
- package/dist/components/calcite-tile-select.js +1 -1
- package/dist/components/calcite-tile.js +1 -1
- package/dist/components/calcite-time-picker.js +1 -1
- package/dist/components/calcite-tip-group.js +1 -1
- package/dist/components/calcite-tip-manager.js +1 -1
- package/dist/components/calcite-tip.js +1 -1
- package/dist/components/calcite-tooltip.js +1 -1
- package/dist/components/calcite-tree-item.js +1 -1
- package/dist/components/calcite-tree.js +1 -1
- package/dist/components/calcite-value-list-item.js +1 -1
- package/dist/components/calcite-value-list.js +1 -1
- package/dist/components/checkbox.js +2 -2
- package/dist/components/chip.js +2 -2
- package/dist/components/color-picker-hex-input.js +1 -1
- package/dist/components/color-picker-swatch.js +1 -1
- package/dist/components/conditionalSlot.js +1 -1
- package/dist/components/date-picker-day.js +1 -1
- package/dist/components/date-picker-month-header.js +1 -1
- package/dist/components/date-picker-month.js +1 -1
- package/dist/components/date-picker.js +3 -3
- package/dist/components/date.js +1 -1
- package/dist/components/debounce.js +1 -1
- package/dist/components/dom.js +1 -1
- package/dist/components/dropdown.js +1 -1
- package/dist/components/filter.js +2 -2
- package/dist/components/filter2.js +1 -1
- package/dist/components/floating-ui.js +1 -1
- package/dist/components/focusTrapComponent.js +1 -1
- package/dist/components/form.js +30 -2
- package/dist/components/graph.js +1 -1
- package/dist/components/guid.js +1 -1
- package/dist/components/handle.js +1 -1
- package/dist/components/icon.js +1 -1
- package/dist/components/index.d.ts +9 -0
- package/dist/components/index.js +2 -2
- package/dist/components/input.js +1 -1
- package/dist/components/interactive.js +1 -1
- package/dist/components/key.js +1 -1
- package/dist/components/label.js +1 -1
- package/dist/components/label2.js +1 -1
- package/dist/components/link.js +1 -1
- package/dist/components/loadable.js +1 -1
- package/dist/components/loader.js +1 -1
- package/dist/components/locale.js +1 -1
- package/dist/components/math.js +1 -1
- package/dist/components/observers.js +1 -1
- package/dist/components/openCloseComponent.js +1 -1
- package/dist/components/panel.js +2 -2
- package/dist/components/pick-list-item.js +1 -1
- package/dist/components/popover.js +2 -2
- package/dist/components/progress.js +1 -1
- package/dist/components/resources.js +1 -1
- package/dist/components/resources2.js +1 -1
- package/dist/components/resources3.js +1 -1
- package/dist/components/scrim.js +1 -1
- package/dist/components/shared-list-render.js +1 -1
- package/dist/components/sortable.esm.js +1 -1
- package/dist/components/switch.js +1 -1
- package/dist/components/t9n.js +1 -1
- package/dist/components/tab-nav.js +1 -1
- package/dist/components/tab-title.js +1 -1
- package/dist/components/tab.js +1 -1
- package/dist/components/tabs.js +2 -2
- package/dist/components/tile.js +1 -1
- package/dist/components/time-picker.js +1 -1
- package/dist/components/tooltip.js +1 -1
- package/dist/components/utils.js +1 -1
- package/dist/components/utils2.js +1 -1
- package/dist/components/utils3.js +1 -1
- package/dist/components/utils4.js +1 -1
- package/dist/esm/{ExpandToggle-4727adf8.js → ExpandToggle-0b23ee7e.js} +5 -5
- package/dist/esm/{Heading-3bac0cfa.js → Heading-d0c45231.js} +2 -2
- package/dist/esm/{app-globals-74d44d89.js → app-globals-825395ce.js} +2 -2
- package/dist/esm/{array-6fd99808.js → array-2f43016e.js} +1 -1
- package/dist/esm/calcite-accordion_2.entry.js +8 -8
- package/dist/esm/calcite-action-bar.entry.js +15 -15
- package/dist/esm/calcite-action-group.entry.js +12 -12
- package/dist/esm/calcite-action-menu.entry.js +9 -9
- package/dist/esm/calcite-action-pad.entry.js +14 -14
- package/dist/esm/calcite-action.entry.js +11 -11
- package/dist/esm/calcite-alert.entry.js +12 -12
- package/dist/esm/calcite-avatar.entry.js +6 -6
- package/dist/esm/calcite-block_2.entry.js +12 -12
- package/dist/esm/calcite-button.entry.js +13 -41
- package/dist/esm/calcite-card.entry.js +10 -10
- package/dist/esm/calcite-checkbox.entry.js +10 -10
- package/dist/esm/calcite-chip.entry.js +11 -11
- package/dist/esm/calcite-color-picker_3.entry.js +14 -14
- package/dist/esm/calcite-combobox_3.entry.js +18 -18
- package/dist/esm/calcite-date-picker_4.entry.js +12 -12
- package/dist/esm/calcite-dropdown_3.entry.js +12 -12
- package/dist/esm/calcite-fab.entry.js +7 -7
- package/dist/esm/calcite-filter.entry.js +13 -13
- package/dist/esm/calcite-flow-item.entry.js +12 -12
- package/dist/esm/calcite-flow.entry.js +3 -3
- package/dist/esm/calcite-graph_2.entry.js +13 -13
- package/dist/esm/calcite-handle.entry.js +10 -10
- package/dist/esm/calcite-icon.entry.js +6 -6
- package/dist/esm/calcite-inline-editable.entry.js +12 -12
- package/dist/esm/calcite-input-date-picker.entry.js +16 -16
- package/dist/esm/calcite-input-message.entry.js +5 -5
- package/dist/esm/calcite-input-number.entry.js +13 -13
- package/dist/esm/calcite-input-text.entry.js +13 -13
- package/dist/esm/calcite-input-time-picker_2.entry.js +13 -13
- package/dist/esm/calcite-input.entry.js +13 -13
- package/dist/esm/calcite-label.entry.js +6 -6
- package/dist/esm/calcite-link.entry.js +7 -7
- package/dist/esm/calcite-list_3.entry.js +9 -9
- package/dist/esm/calcite-loader.entry.js +3 -3
- package/dist/esm/calcite-modal.entry.js +13 -13
- package/dist/esm/calcite-notice.entry.js +12 -12
- package/dist/esm/calcite-option_3.entry.js +10 -10
- package/dist/esm/calcite-pagination.entry.js +9 -9
- package/dist/esm/calcite-panel.entry.js +14 -14
- package/dist/esm/calcite-pick-list_3.entry.js +16 -16
- package/dist/esm/calcite-popover.entry.js +15 -15
- package/dist/esm/calcite-progress.entry.js +2 -2
- package/dist/esm/calcite-radio-button-group.entry.js +3 -3
- package/dist/esm/calcite-radio-button.entry.js +10 -10
- package/dist/esm/calcite-rating.entry.js +13 -13
- package/dist/esm/calcite-scrim.entry.js +9 -9
- package/dist/esm/calcite-segmented-control_2.entry.js +9 -9
- package/dist/esm/calcite-shell_3.entry.js +11 -11
- package/dist/esm/calcite-sortable-list.entry.js +5 -5
- package/dist/esm/calcite-split-button.entry.js +3 -3
- package/dist/esm/calcite-stepper_2.entry.js +10 -10
- package/dist/esm/calcite-switch.entry.js +10 -10
- package/dist/esm/calcite-tab_4.entry.js +7 -7
- package/dist/esm/calcite-tile-select_2.entry.js +5 -5
- package/dist/esm/calcite-tile.entry.js +8 -8
- package/dist/esm/calcite-tip_3.entry.js +11 -11
- package/dist/esm/calcite-tooltip.entry.js +8 -8
- package/dist/esm/calcite-tree_2.entry.js +9 -9
- package/dist/esm/calcite-value-list_2.entry.js +16 -16
- package/dist/esm/calcite.js +7 -6
- package/dist/esm/{conditionalSlot-03f34e10.js → conditionalSlot-a7cd2d70.js} +3 -3
- package/dist/esm/{debounce-f893dc12.js → debounce-bdaf6a6a.js} +1 -1
- package/dist/esm/{dom-13d14bf1.js → dom-4e09c515.js} +3 -3
- package/dist/esm/{filter-e9b22c1c.js → filter-93b11013.js} +2 -2
- package/dist/esm/{floating-ui-1d9078ac.js → floating-ui-c779980e.js} +4 -4
- package/dist/esm/{focusTrapComponent-d8df0d61.js → focusTrapComponent-9f7096e0.js} +2 -2
- package/dist/esm/{form-948b3633.js → form-c63168b7.js} +32 -4
- package/dist/esm/{guid-7a9e307b.js → guid-594c089d.js} +1 -1
- package/dist/esm/{index-b8735a76.js → index-1d43719b.js} +112 -4
- package/dist/esm/index.js +1 -1
- package/dist/esm/{interactive-7c601b75.js → interactive-239e7533.js} +1 -1
- package/dist/esm/{key-4f8ab7a0.js → key-f55db1a4.js} +1 -1
- package/dist/esm/{label-84c0027e.js → label-4844ccb0.js} +2 -2
- package/dist/esm/{loadable-eacac1b0.js → loadable-d5431086.js} +1 -1
- package/dist/esm/loader.js +7 -6
- package/dist/esm/{locale-e71d40b1.js → locale-e888461a.js} +4 -4
- package/dist/esm/{math-bad59c37.js → math-e0a398f4.js} +1 -1
- package/dist/esm/{observers-f268ee68.js → observers-7f2cd5c5.js} +1 -1
- package/dist/esm/{openCloseComponent-ec590820.js → openCloseComponent-90e125eb.js} +2 -2
- package/dist/esm/polyfills/css-shim.js +1 -1
- package/dist/esm/{resources-8ee51466.js → resources-0f21b5ed.js} +1 -1
- package/dist/esm/{resources-8032eb01.js → resources-6174169f.js} +1 -1
- package/dist/esm/{resources-2537ff53.js → resources-7318af67.js} +1 -1
- package/dist/esm/{resources-455d50da.js → resources-c01b718a.js} +5 -5
- package/dist/esm/{resources-4c7e12d7.js → resources-cf158a59.js} +1 -1
- package/dist/esm/{resources-6efb094b.js → resources-d32a86e2.js} +1 -1
- package/dist/esm/{sortable.esm-ad7263e5.js → sortable.esm-1e4e060d.js} +1 -1
- package/dist/esm/{t9n-df463c97.js → t9n-c8fcbb64.js} +3 -3
- package/dist/esm/{utils-e9181006.js → utils-52cfa1ba.js} +1 -1
- package/dist/esm/{utils-4755b12f.js → utils-c87abc70.js} +3 -3
- package/dist/esm/{utils-9b472a57.js → utils-faa18b31.js} +1 -1
- package/dist/extras/docs-json.json +19 -19
- package/dist/loader/cdn.js +1 -1
- package/dist/loader/index.cjs.js +1 -1
- package/dist/loader/index.d.ts +9 -0
- package/dist/loader/index.es2017.js +1 -1
- package/dist/loader/index.js +1 -1
- package/dist/types/components/alert/interfaces.d.ts +1 -1
- package/dist/types/components/block-section/interfaces.d.ts +1 -1
- package/dist/types/components/button/button.d.ts +0 -1
- package/dist/types/components/button/interfaces.d.ts +2 -2
- package/dist/types/components/color-picker/interfaces.d.ts +6 -6
- package/dist/types/components/color-picker/utils.d.ts +5 -5
- package/dist/types/components/combobox/interfaces.d.ts +1 -1
- package/dist/types/components/flow/interfaces.d.ts +1 -1
- package/dist/types/components/functional/Heading.d.ts +1 -1
- package/dist/types/components/graph/interfaces.d.ts +3 -3
- package/dist/types/components/input/interfaces.d.ts +3 -3
- package/dist/types/components/interfaces.d.ts +14 -14
- package/dist/types/components/list/resources.d.ts +1 -1
- package/dist/types/components/pick-list/shared-list-logic.d.ts +5 -5
- package/dist/types/components/tabs/interfaces.d.ts +3 -3
- package/dist/types/components/tile-select/interfaces.d.ts +1 -1
- package/dist/types/components/tile-select-group/interfaces.d.ts +1 -1
- package/dist/types/components/value-list/interfaces.d.ts +1 -1
- package/dist/types/components.d.ts +72 -0
- package/dist/types/stencil-public-runtime.d.ts +59 -3
- package/dist/types/utils/date.d.ts +1 -1
- package/dist/types/utils/dom.d.ts +2 -2
- package/dist/types/utils/floating-ui.d.ts +6 -6
- package/dist/types/utils/focusTrapComponent.d.ts +1 -1
- package/dist/types/utils/form.d.ts +1 -0
- package/dist/types/utils/globalAttributes.d.ts +2 -2
- package/dist/types/utils/interactive.d.ts +1 -1
- package/dist/types/utils/locale.d.ts +2 -2
- package/dist/types/utils/observers.d.ts +4 -4
- package/dist/types/utils/t9n.d.ts +1 -1
- package/dist/types/utils/time.d.ts +4 -4
- package/hydrate/index.js +47 -40
- package/package.json +7 -7
- package/dist/calcite/p-07cddbf9.entry.js +0 -6
- package/dist/calcite/p-0824c673.entry.js +0 -6
- package/dist/calcite/p-0edfedfc.entry.js +0 -6
- package/dist/calcite/p-1d322131.entry.js +0 -6
- package/dist/calcite/p-299618f6.entry.js +0 -6
- package/dist/calcite/p-2afe300d.js +0 -6
- package/dist/calcite/p-31cf383e.js +0 -6
- package/dist/calcite/p-3449e5c5.entry.js +0 -6
- package/dist/calcite/p-3b712fa3.entry.js +0 -6
- package/dist/calcite/p-3bd84462.js +0 -10
- package/dist/calcite/p-43215088.js +0 -6
- package/dist/calcite/p-44e65dab.js +0 -6
- package/dist/calcite/p-4b8aad63.entry.js +0 -6
- package/dist/calcite/p-586f2188.entry.js +0 -6
- package/dist/calcite/p-681f5bcd.entry.js +0 -6
- package/dist/calcite/p-72e0a2c6.js +0 -12
- package/dist/calcite/p-7beda7c9.entry.js +0 -6
- package/dist/calcite/p-7f1192e2.js +0 -6
- package/dist/calcite/p-88552502.entry.js +0 -6
- package/dist/calcite/p-8880449d.entry.js +0 -6
- package/dist/calcite/p-95affd38.js +0 -7
- package/dist/calcite/p-98c10ed9.entry.js +0 -6
- package/dist/calcite/p-9b383655.entry.js +0 -6
- package/dist/calcite/p-a0699bed.entry.js +0 -6
- package/dist/calcite/p-a82b983d.entry.js +0 -6
- package/dist/calcite/p-aea382ce.entry.js +0 -6
- package/dist/calcite/p-b33dc129.js +0 -6
- package/dist/calcite/p-b5a392d6.entry.js +0 -6
- package/dist/calcite/p-c4d076eb.entry.js +0 -6
- package/dist/calcite/p-d438c49f.entry.js +0 -6
- package/dist/calcite/p-de99d897.entry.js +0 -6
- package/dist/calcite/p-e4e7c6c0.entry.js +0 -6
- package/dist/calcite/p-f510244b.js +0 -6
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/*!
|
|
2
2
|
* All material copyright ESRI, All Rights Reserved, unless otherwise specified.
|
|
3
3
|
* See https://github.com/Esri/calcite-components/blob/master/LICENSE.md for details.
|
|
4
|
-
* v1.1.
|
|
4
|
+
* v1.1.1-next.1
|
|
5
5
|
*/
|
|
6
|
-
import{r as i,c as t,h as e,g as n}from"./p-95affd38.js";import{c as a,d as o}from"./p-31cf383e.js";import{s as c}from"./p-b4c2f2ce.js";import{g as r}from"./p-c097b143.js";import{a as s,s as l,c as d}from"./p-bb1240f3.js";import{c as h,d as p}from"./p-b33dc129.js";import{c as m}from"./p-f510244b.js";import{u,c as b,d as g,s as v}from"./p-145b7cdc.js";import"./p-44e65dab.js";import"./p-32d3d2c6.js";const f=class{constructor(e){i(this,e),this.calciteChipClose=t(this,"calciteChipClose",6),this.closeClickHandler=i=>{i.preventDefault(),this.calciteChipClose.emit(),this.closed=!0},this.handleSlotImageChange=i=>{this.hasImage=c(i)},this.mutationObserver=m("mutation",(()=>this.updateHasContent())),this.guid=r(),this.appearance="solid",this.kind="neutral",this.closable=!1,this.icon=void 0,this.iconFlipRtl=!1,this.scale="m",this.value=void 0,this.closed=!1,this.messageOverrides=void 0,this.messages=void 0,this.defaultMessages=void 0,this.effectiveLocale=void 0,this.hasContent=!1,this.hasImage=!1}onMessagesChange(){}effectiveLocaleChange(){u(this,this.effectiveLocale)}connectedCallback(){a(this),h(this),b(this),this.setupTextContentObserver()}componentDidLoad(){s(this)}disconnectedCallback(){o(this),p(this),g(this)}async componentWillLoad(){l(this),await v(this),this.updateHasContent()}async setFocus(){await d(this),this.closeButton?.focus()}updateHasContent(){const i=this.el.textContent.trim().length>0||this.el.childNodes.length>0;this.hasContent=this.el.childNodes.length>0&&"#text"===this.el.childNodes[0]?.nodeName?this.el.textContent?.trim().length>0:i}setupTextContentObserver(){this.mutationObserver?.observe(this.el,{childList:!0,subtree:!0})}renderChipImage(){return e("div",{class:"image-container",key:"image"},e("slot",{name:"image",onSlotchange:this.handleSlotImageChange}))}render(){const i=e("calcite-icon",{class:"chip-icon",flipRtl:this.iconFlipRtl,icon:this.icon,scale:"l"===this.scale?"m":"s"}),t=e("button",{"aria-describedby":this.guid,"aria-label":this.messages.dismissLabel,class:"close",onClick:this.closeClickHandler,ref:i=>this.closeButton=i},e("calcite-icon",{class:"close-icon",icon:"x",scale:"l"===this.scale?"m":"s"}));return e("div",{class:{container:!0,"content--slotted":this.hasContent,"image--slotted":this.hasImage}},this.renderChipImage(),this.icon?i:null,e("span",{class:"title",id:this.guid},e("slot",null)),this.closable?t:null)}static get assetsDirs(){return["assets"]}get el(){return n(this)}static get watchers(){return{messageOverrides:["onMessagesChange"],effectiveLocale:["effectiveLocaleChange"]}}};f.style="@keyframes in{0%{opacity:0}100%{opacity:1}}@keyframes in-down{0%{opacity:0;transform:translate3D(0, -5px, 0)}100%{opacity:1;transform:translate3D(0, 0, 0)}}@keyframes in-up{0%{opacity:0;transform:translate3D(0, 5px, 0)}100%{opacity:1;transform:translate3D(0, 0, 0)}}@keyframes in-scale{0%{opacity:0;transform:scale3D(0.95, 0.95, 1)}100%{opacity: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;animation-fill-mode:both;animation-duration:var(--calcite-animation-timing)}.calcite-animate__in{animation-name:in}.calcite-animate__in-down{animation-name:in-down}.calcite-animate__in-up{animation-name:in-up}.calcite-animate__in-scale{animation-name:in-scale}@media (prefers-reduced-motion: reduce){:root{--calcite-internal-duration-factor:0.01}}:root{--calcite-floating-ui-transition:var(--calcite-animation-timing);--calcite-floating-ui-z-index:600}:host([hidden]){display:none}:host([scale=s]){block-size:1.5rem;font-size:var(--calcite-font-size--2);--calcite-chip-spacing-unit-l:0.5rem;--calcite-chip-spacing-unit-s:0.25rem}:host([scale=s]) .image-container{block-size:1.25rem;inline-size:1.25rem;padding-inline-start:0.125rem}:host([scale=m]){block-size:2rem;font-size:var(--calcite-font-size--1);--calcite-chip-spacing-unit-l:0.75rem;--calcite-chip-spacing-unit-s:calc(0.75rem / 2)}:host([scale=m]) .image-container{block-size:1.5rem;inline-size:1.5rem;padding-inline-start:0.25rem}:host([scale=l]){block-size:2.75rem;font-size:var(--calcite-font-size-0);--calcite-chip-spacing-unit-l:1rem;--calcite-chip-spacing-unit-s:0.5rem}:host([scale=l]) .image-container{block-size:2rem;inline-size:2rem;padding-inline-start:0.5rem}:host{box-sizing:border-box;display:inline-flex;cursor:default;align-items:center;border-radius:9999px;border-width:1px;border-style:solid;border-color:var(--calcite-ui-border-1);font-weight:var(--calcite-font-weight-medium);color:var(--calcite-ui-text-1)}.container{display:inline-flex;block-size:100%;max-inline-size:100%;align-items:center}.title{overflow:hidden;text-overflow:ellipsis;white-space:nowrap;padding-block:0}.content--slotted .title{padding-inline:var(--calcite-chip-spacing-unit-l)}:host([closable][icon]) .container:not(.content--slotted) .title{padding-inline:0 var(--calcite-chip-spacing-unit-s)}:host(:not([closable])) .container:not(.content--slotted) .chip-icon{margin-inline:auto}.container:not(.image--slotted) .image-container{display:none}:host([scale=s][closable]) .container:not(.content--slotted) .image-container{margin-inline-end:0.125rem}:host([scale=m][closable]) .container:not(.content--slotted) .image-container{margin-inline-end:0.25rem}:host([scale=l][closable]) .container:not(.content--slotted) .image-container{margin-inline-end:0.5rem}:host([scale=s]:not([closable])) .container:not(.content--slotted){block-size:1.5rem;inline-size:1.5rem}:host([scale=s]:not([closable])) .container:not(.content--slotted) .image-container{padding-inline:0.125rem}:host([scale=m]:not([closable])) .container:not(.content--slotted){block-size:2rem;inline-size:2rem}:host([scale=m]:not([closable])) .container:not(.content--slotted) .image-container{padding-inline:0.25rem}:host([scale=l]:not([closable])) .container:not(.content--slotted){block-size:2.75rem;inline-size:2.75rem}:host([scale=l]:not([closable])) .container:not(.content--slotted) .image-container{padding-inline:calc(0.75rem / 2)}:host([closable]) .content--slotted .title{padding-inline:var(--calcite-chip-spacing-unit-l) var(--calcite-chip-spacing-unit-s)}:host([scale=s]) button{inline-size:1rem;block-size:1rem;margin-inline-end:0.125rem}:host([scale=m]) button{inline-size:1.5rem;block-size:1.5rem;margin-inline-end:0.25rem}:host([scale=l]) button{inline-size:2rem;block-size:2rem;margin-inline-end:0.5rem}button{margin:0px;cursor:pointer;align-items:center;border-style:none;background-color:transparent;color:var(--calcite-ui-text-1);outline-color:transparent;transition:all var(--calcite-animation-timing) ease-in-out 0s, outline 0s, outline-offset 0s;-webkit-appearance:none;display:flex;border-radius:50%;padding-inline:var(--calcite-chip-spacing-unit-s);color:inherit;align-content:center;justify-content:center;--calcite-chip-transparent-hover:var(--calcite-button-transparent-hover);--calcite-chip-transparent-press:var(--calcite-button-transparent-press)}button:hover{background-color:var(--calcite-chip-transparent-hover)}button:focus{background-color:var(--calcite-chip-transparent-hover);outline:2px solid var(--calcite-ui-brand);outline-offset:-2px}button:active{background-color:var(--calcite-chip-transparent-press)}.image-container{display:inline-flex;overflow:hidden}slot[name=image]::slotted(*){display:flex;block-size:100%;inline-size:100%;overflow:hidden;border-radius:50%}.chip-icon{position:relative;margin-block:0px;display:inline-flex;transition-duration:150ms;transition-timing-function:cubic-bezier(0.4, 0, 0.2, 1);margin-inline-end:0;margin-inline-start:var(--calcite-chip-spacing-unit-l)}:host([kind=neutral]){border-color:transparent;background-color:var(--calcite-ui-foreground-2);color:var(--calcite-ui-text-1)}:host([kind=neutral]) button,:host([kind=neutral]) .close-icon{color:var(--calcite-ui-text-3)}:host([kind=neutral]) .chip-icon{color:var(--calcite-ui-icon-color, var(--calcite-ui-text-3))}:host([kind=inverse]){border-color:transparent;background-color:var(--calcite-ui-inverse);color:var(--calcite-ui-text-inverse)}:host([kind=inverse]) button,:host([kind=inverse]) .close-icon{color:var(--calcite-ui-text-inverse)}:host([kind=inverse]) .chip-icon{color:var(--calcite-ui-icon-color, var(--calcite-ui-text-inverse))}:host([kind=brand]){border-color:transparent;background-color:var(--calcite-ui-brand);color:var(--calcite-ui-text-inverse)}:host([kind=brand]) button,:host([kind=brand]) .close-icon{color:var(--calcite-ui-text-inverse)}:host([kind=brand]) .chip-icon{color:var(--calcite-ui-icon-color, var(--calcite-ui-text-inverse))}:host([appearance=outline-fill]),:host([appearance=outline]){background-color:var(--calcite-ui-foreground-1);color:var(--calcite-ui-text-1)}:host([appearance=outline-fill]) button,:host([appearance=outline-fill]) .close-icon,:host([appearance=outline]) button,:host([appearance=outline]) .close-icon{color:var(--calcite-ui-text-3)}:host([appearance=outline-fill]) .chip-icon,:host([appearance=outline]) .chip-icon{color:var(--calcite-ui-icon-color, var(--calcite-ui-text-3))}:host([appearance=outline-fill]){background-color:var(--calcite-ui-foreground-1)}:host([appearance=outline]){background-color:transparent}:host([kind=neutral][appearance=outline-fill]),:host([kind=neutral][appearance=outline]){border-color:var(--calcite-ui-border-1)}:host([kind=inverse][appearance=outline-fill]),:host([kind=inverse][appearance=outline]){border-color:var(--calcite-ui-border-inverse)}:host([kind=brand][appearance=outline-fill]),:host([kind=brand][appearance=outline]){border-color:var(--calcite-ui-brand)}:host([kind=brand][appearance=solid]) button,:host([kind=inverse][appearance=solid]) button{outline-color:var(--calcite-ui-text-inverse)}:host([closed]){display:none}";export{f as calcite_chip}
|
|
6
|
+
import{r as i,c as t,h as e,g as n}from"./p-983244bc.js";import{c as a,d as o}from"./p-25d10f33.js";import{s as c}from"./p-cff554c3.js";import{g as r}from"./p-1e3ad5b6.js";import{a as s,s as l,c as d}from"./p-0e573040.js";import{c as h,d as p}from"./p-d70da26b.js";import{c as m}from"./p-53515d24.js";import{u,c as b,d as g,s as v}from"./p-2c2c6832.js";import"./p-ebd84c48.js";import"./p-83b37109.js";const f=class{constructor(e){i(this,e),this.calciteChipClose=t(this,"calciteChipClose",6),this.closeClickHandler=i=>{i.preventDefault(),this.calciteChipClose.emit(),this.closed=!0},this.handleSlotImageChange=i=>{this.hasImage=c(i)},this.mutationObserver=m("mutation",(()=>this.updateHasContent())),this.guid=r(),this.appearance="solid",this.kind="neutral",this.closable=!1,this.icon=void 0,this.iconFlipRtl=!1,this.scale="m",this.value=void 0,this.closed=!1,this.messageOverrides=void 0,this.messages=void 0,this.defaultMessages=void 0,this.effectiveLocale=void 0,this.hasContent=!1,this.hasImage=!1}onMessagesChange(){}effectiveLocaleChange(){u(this,this.effectiveLocale)}connectedCallback(){a(this),h(this),b(this),this.setupTextContentObserver()}componentDidLoad(){s(this)}disconnectedCallback(){o(this),p(this),g(this)}async componentWillLoad(){l(this),await v(this),this.updateHasContent()}async setFocus(){await d(this),this.closeButton?.focus()}updateHasContent(){const i=this.el.textContent.trim().length>0||this.el.childNodes.length>0;this.hasContent=this.el.childNodes.length>0&&"#text"===this.el.childNodes[0]?.nodeName?this.el.textContent?.trim().length>0:i}setupTextContentObserver(){this.mutationObserver?.observe(this.el,{childList:!0,subtree:!0})}renderChipImage(){return e("div",{class:"image-container",key:"image"},e("slot",{name:"image",onSlotchange:this.handleSlotImageChange}))}render(){const i=e("calcite-icon",{class:"chip-icon",flipRtl:this.iconFlipRtl,icon:this.icon,scale:"l"===this.scale?"m":"s"}),t=e("button",{"aria-describedby":this.guid,"aria-label":this.messages.dismissLabel,class:"close",onClick:this.closeClickHandler,ref:i=>this.closeButton=i},e("calcite-icon",{class:"close-icon",icon:"x",scale:"l"===this.scale?"m":"s"}));return e("div",{class:{container:!0,"content--slotted":this.hasContent,"image--slotted":this.hasImage}},this.renderChipImage(),this.icon?i:null,e("span",{class:"title",id:this.guid},e("slot",null)),this.closable?t:null)}static get assetsDirs(){return["assets"]}get el(){return n(this)}static get watchers(){return{messageOverrides:["onMessagesChange"],effectiveLocale:["effectiveLocaleChange"]}}};f.style="@keyframes in{0%{opacity:0}100%{opacity:1}}@keyframes in-down{0%{opacity:0;transform:translate3D(0, -5px, 0)}100%{opacity:1;transform:translate3D(0, 0, 0)}}@keyframes in-up{0%{opacity:0;transform:translate3D(0, 5px, 0)}100%{opacity:1;transform:translate3D(0, 0, 0)}}@keyframes in-scale{0%{opacity:0;transform:scale3D(0.95, 0.95, 1)}100%{opacity: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;animation-fill-mode:both;animation-duration:var(--calcite-animation-timing)}.calcite-animate__in{animation-name:in}.calcite-animate__in-down{animation-name:in-down}.calcite-animate__in-up{animation-name:in-up}.calcite-animate__in-scale{animation-name:in-scale}@media (prefers-reduced-motion: reduce){:root{--calcite-internal-duration-factor:0.01}}:root{--calcite-floating-ui-transition:var(--calcite-animation-timing);--calcite-floating-ui-z-index:600}:host([hidden]){display:none}:host([scale=s]){block-size:1.5rem;font-size:var(--calcite-font-size--2);--calcite-chip-spacing-unit-l:0.5rem;--calcite-chip-spacing-unit-s:0.25rem}:host([scale=s]) .image-container{block-size:1.25rem;inline-size:1.25rem;padding-inline-start:0.125rem}:host([scale=m]){block-size:2rem;font-size:var(--calcite-font-size--1);--calcite-chip-spacing-unit-l:0.75rem;--calcite-chip-spacing-unit-s:calc(0.75rem / 2)}:host([scale=m]) .image-container{block-size:1.5rem;inline-size:1.5rem;padding-inline-start:0.25rem}:host([scale=l]){block-size:2.75rem;font-size:var(--calcite-font-size-0);--calcite-chip-spacing-unit-l:1rem;--calcite-chip-spacing-unit-s:0.5rem}:host([scale=l]) .image-container{block-size:2rem;inline-size:2rem;padding-inline-start:0.5rem}:host{box-sizing:border-box;display:inline-flex;cursor:default;align-items:center;border-radius:9999px;border-width:1px;border-style:solid;border-color:var(--calcite-ui-border-1);font-weight:var(--calcite-font-weight-medium);color:var(--calcite-ui-text-1)}.container{display:inline-flex;block-size:100%;max-inline-size:100%;align-items:center}.title{overflow:hidden;text-overflow:ellipsis;white-space:nowrap;padding-block:0}.content--slotted .title{padding-inline:var(--calcite-chip-spacing-unit-l)}:host([closable][icon]) .container:not(.content--slotted) .title{padding-inline:0 var(--calcite-chip-spacing-unit-s)}:host(:not([closable])) .container:not(.content--slotted) .chip-icon{margin-inline:auto}.container:not(.image--slotted) .image-container{display:none}:host([scale=s][closable]) .container:not(.content--slotted) .image-container{margin-inline-end:0.125rem}:host([scale=m][closable]) .container:not(.content--slotted) .image-container{margin-inline-end:0.25rem}:host([scale=l][closable]) .container:not(.content--slotted) .image-container{margin-inline-end:0.5rem}:host([scale=s]:not([closable])) .container:not(.content--slotted){block-size:1.5rem;inline-size:1.5rem}:host([scale=s]:not([closable])) .container:not(.content--slotted) .image-container{padding-inline:0.125rem}:host([scale=m]:not([closable])) .container:not(.content--slotted){block-size:2rem;inline-size:2rem}:host([scale=m]:not([closable])) .container:not(.content--slotted) .image-container{padding-inline:0.25rem}:host([scale=l]:not([closable])) .container:not(.content--slotted){block-size:2.75rem;inline-size:2.75rem}:host([scale=l]:not([closable])) .container:not(.content--slotted) .image-container{padding-inline:calc(0.75rem / 2)}:host([closable]) .content--slotted .title{padding-inline:var(--calcite-chip-spacing-unit-l) var(--calcite-chip-spacing-unit-s)}:host([scale=s]) button{inline-size:1rem;block-size:1rem;margin-inline-end:0.125rem}:host([scale=m]) button{inline-size:1.5rem;block-size:1.5rem;margin-inline-end:0.25rem}:host([scale=l]) button{inline-size:2rem;block-size:2rem;margin-inline-end:0.5rem}button{margin:0px;cursor:pointer;align-items:center;border-style:none;background-color:transparent;color:var(--calcite-ui-text-1);outline-color:transparent;transition:all var(--calcite-animation-timing) ease-in-out 0s, outline 0s, outline-offset 0s;-webkit-appearance:none;display:flex;border-radius:50%;padding-inline:var(--calcite-chip-spacing-unit-s);color:inherit;align-content:center;justify-content:center;--calcite-chip-transparent-hover:var(--calcite-button-transparent-hover);--calcite-chip-transparent-press:var(--calcite-button-transparent-press)}button:hover{background-color:var(--calcite-chip-transparent-hover)}button:focus{background-color:var(--calcite-chip-transparent-hover);outline:2px solid var(--calcite-ui-brand);outline-offset:-2px}button:active{background-color:var(--calcite-chip-transparent-press)}.image-container{display:inline-flex;overflow:hidden}slot[name=image]::slotted(*){display:flex;block-size:100%;inline-size:100%;overflow:hidden;border-radius:50%}.chip-icon{position:relative;margin-block:0px;display:inline-flex;transition-duration:150ms;transition-timing-function:cubic-bezier(0.4, 0, 0.2, 1);margin-inline-end:0;margin-inline-start:var(--calcite-chip-spacing-unit-l)}:host([kind=neutral]){border-color:transparent;background-color:var(--calcite-ui-foreground-2);color:var(--calcite-ui-text-1)}:host([kind=neutral]) button,:host([kind=neutral]) .close-icon{color:var(--calcite-ui-text-3)}:host([kind=neutral]) .chip-icon{color:var(--calcite-ui-icon-color, var(--calcite-ui-text-3))}:host([kind=inverse]){border-color:transparent;background-color:var(--calcite-ui-inverse);color:var(--calcite-ui-text-inverse)}:host([kind=inverse]) button,:host([kind=inverse]) .close-icon{color:var(--calcite-ui-text-inverse)}:host([kind=inverse]) .chip-icon{color:var(--calcite-ui-icon-color, var(--calcite-ui-text-inverse))}:host([kind=brand]){border-color:transparent;background-color:var(--calcite-ui-brand);color:var(--calcite-ui-text-inverse)}:host([kind=brand]) button,:host([kind=brand]) .close-icon{color:var(--calcite-ui-text-inverse)}:host([kind=brand]) .chip-icon{color:var(--calcite-ui-icon-color, var(--calcite-ui-text-inverse))}:host([appearance=outline-fill]),:host([appearance=outline]){background-color:var(--calcite-ui-foreground-1);color:var(--calcite-ui-text-1)}:host([appearance=outline-fill]) button,:host([appearance=outline-fill]) .close-icon,:host([appearance=outline]) button,:host([appearance=outline]) .close-icon{color:var(--calcite-ui-text-3)}:host([appearance=outline-fill]) .chip-icon,:host([appearance=outline]) .chip-icon{color:var(--calcite-ui-icon-color, var(--calcite-ui-text-3))}:host([appearance=outline-fill]){background-color:var(--calcite-ui-foreground-1)}:host([appearance=outline]){background-color:transparent}:host([kind=neutral][appearance=outline-fill]),:host([kind=neutral][appearance=outline]){border-color:var(--calcite-ui-border-1)}:host([kind=inverse][appearance=outline-fill]),:host([kind=inverse][appearance=outline]){border-color:var(--calcite-ui-border-inverse)}:host([kind=brand][appearance=outline-fill]),:host([kind=brand][appearance=outline]){border-color:var(--calcite-ui-brand)}:host([kind=brand][appearance=solid]) button,:host([kind=inverse][appearance=solid]) button{outline-color:var(--calcite-ui-text-inverse)}:host([closed]){display:none}";export{f as calcite_chip}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/*!
|
|
2
2
|
* All material copyright ESRI, All Rights Reserved, unless otherwise specified.
|
|
3
3
|
* See https://github.com/Esri/calcite-components/blob/master/LICENSE.md for details.
|
|
4
|
-
* v1.1.
|
|
4
|
+
* v1.1.1-next.1
|
|
5
5
|
*/
|
|
6
6
|
const t=()=>[2,1,1,1,3].map((t=>{let e="";for(let r=0;r<t;r++)e+=(65536*(1+Math.random())|0).toString(16).substring(1);return e})).join("-");export{t as g}
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
/*!
|
|
2
|
+
* All material copyright ESRI, All Rights Reserved, unless otherwise specified.
|
|
3
|
+
* See https://github.com/Esri/calcite-components/blob/master/LICENSE.md for details.
|
|
4
|
+
* v1.1.1-next.1
|
|
5
|
+
*/
|
|
6
|
+
import{r as t,h as a,g as e}from"./p-983244bc.js";import{c as n}from"./p-cff554c3.js";import{s as o,r as i}from"./p-941fee1b.js";import{u as r}from"./p-9f094be8.js";import{c,d as l,g as s}from"./p-b8b075fd.js";import{s as d,a as u,c as p}from"./p-0e573040.js";import{c as h,d as b}from"./p-d70da26b.js";import{c as v}from"./p-53515d24.js";import{c as g,d as k,s as m,u as f}from"./p-2c2c6832.js";import"./p-1e3ad5b6.js";import"./p-ebd84c48.js";import"./p-83b37109.js";const x="icon",w=class{constructor(a){t(this,a),this.mutationObserver=v("mutation",(()=>this.updateHasContent())),this.handleClick=()=>{const{type:t}=this;this.href||("submit"===t?o(this):"reset"===t&&i(this))},this.alignment="center",this.appearance="solid",this.label=void 0,this.kind="brand",this.disabled=!1,this.href=void 0,this.iconEnd=void 0,this.iconFlipRtl=void 0,this.iconStart=void 0,this.loading=!1,this.name=void 0,this.rel=void 0,this.round=!1,this.scale="m",this.splitChild=!1,this.target=void 0,this.type="button",this.width="auto",this.messages=void 0,this.messageOverrides=void 0,this.hasContent=!1,this.hasLoader=!1,this.effectiveLocale="",this.defaultMessages=void 0}loadingChanged(t,a){t&&!a&&(this.hasLoader=!0),!t&&a&&window.setTimeout((()=>{this.hasLoader=!1}),300)}onMessagesChange(){}async connectedCallback(){h(this),g(this),this.hasLoader=this.loading,this.setupTextContentObserver(),c(this),this.formEl=n(this.el,"form")}disconnectedCallback(){this.mutationObserver?.disconnect(),l(this),b(this),k(this),this.formEl=null}async componentWillLoad(){d(this),this.updateHasContent(),await m(this)}componentDidLoad(){u(this)}componentDidRender(){r(this)}render(){const t=this.href?"a":"button",e=t,n=this.hasLoader?a("div",{class:"calcite-button--loader"},a("calcite-loader",{class:this.loading?"loading-in":"loading-out",inline:!0,label:this.messages.loading,scale:"l"===this.scale?"m":"s"})):null,o=!this.iconStart&&!this.iconEnd,i=a("calcite-icon",{class:{[x]:!0,"icon--start":!0},flipRtl:"start"===this.iconFlipRtl||"both"===this.iconFlipRtl,icon:this.iconStart,scale:"l"===this.scale?"m":"s"}),r=a("calcite-icon",{class:{[x]:!0,"icon--end":!0},flipRtl:"end"===this.iconFlipRtl||"both"===this.iconFlipRtl,icon:this.iconEnd,scale:"l"===this.scale?"m":"s"}),c=a("span",{class:"content"},a("slot",null));return a(e,{"aria-label":s(this),class:{"button-padding":o,"button-padding--shrunk":!o,"content--slotted":this.hasContent,"icon-start-empty":!this.iconStart,"icon-end-empty":!this.iconEnd},disabled:this.disabled||this.loading,href:"a"===t&&this.href,name:"button"===t&&this.name,onClick:this.handleClick,rel:"a"===t&&this.rel,tabIndex:this.disabled||this.loading?-1:null,target:"a"===t&&this.target,type:"button"===t&&this.type,ref:t=>this.childEl=t},n,this.iconStart?i:null,this.hasContent?c:null,this.iconEnd?r:null)}async setFocus(){await p(this),this.childEl?.focus()}effectiveLocaleChange(){f(this,this.effectiveLocale)}updateHasContent(){const t=this.el.textContent.trim().length>0||this.el.childNodes.length>0;this.hasContent=1===this.el.childNodes.length&&"#text"===this.el.childNodes[0]?.nodeName?this.el.textContent?.trim().length>0:t}setupTextContentObserver(){this.mutationObserver?.observe(this.el,{childList:!0,subtree:!0})}onLabelClick(){this.handleClick(),this.setFocus()}static get assetsDirs(){return["assets"]}get el(){return e(this)}static get watchers(){return{loading:["loadingChanged"],messageOverrides:["onMessagesChange"],effectiveLocale:["effectiveLocaleChange"]}}};w.style="@keyframes in{0%{opacity:0}100%{opacity:1}}@keyframes in-down{0%{opacity:0;transform:translate3D(0, -5px, 0)}100%{opacity:1;transform:translate3D(0, 0, 0)}}@keyframes in-up{0%{opacity:0;transform:translate3D(0, 5px, 0)}100%{opacity:1;transform:translate3D(0, 0, 0)}}@keyframes in-scale{0%{opacity:0;transform:scale3D(0.95, 0.95, 1)}100%{opacity: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;animation-fill-mode:both;animation-duration:var(--calcite-animation-timing)}.calcite-animate__in{animation-name:in}.calcite-animate__in-down{animation-name:in-down}.calcite-animate__in-up{animation-name:in-up}.calcite-animate__in-scale{animation-name:in-scale}@media (prefers-reduced-motion: reduce){:root{--calcite-internal-duration-factor:0.01}}:root{--calcite-floating-ui-transition:var(--calcite-animation-timing);--calcite-floating-ui-z-index:600}:host([hidden]){display:none}:host([disabled]){pointer-events:none;cursor:default;-webkit-user-select:none;user-select:none;opacity:var(--calcite-ui-opacity-disabled)}:host{display:inline-block;inline-size:auto;vertical-align:middle}:host([round]){border-radius:50px}:host([round]) a,:host([round]) button{border-radius:50px}:host button,:host a{outline-color:transparent}:host button:focus,:host a:focus{outline:2px solid var(--calcite-ui-brand);outline-offset:2px}:host button,:host a{--calcite-button-content-margin-internal:0.5rem;--calcite-button-padding-x-internal:7px;--calcite-button-padding-y-internal:3px;padding-block:var(--calcite-button-padding-y-internal);padding-inline:var(--calcite-button-padding-x-internal);position:relative;box-sizing:border-box;display:flex;block-size:100%;inline-size:100%;cursor:pointer;-webkit-user-select:none;user-select:none;-webkit-appearance:none;appearance:none;align-items:center;justify-content:center;border-radius:0px;border-style:none;text-align:center;font-family:inherit;font-weight:var(--calcite-font-weight-normal);text-decoration-line:none;transition:color var(--calcite-animation-timing) ease-in-out, background-color var(--calcite-animation-timing) ease-in-out, box-shadow var(--calcite-animation-timing) ease-in-out, outline-color var(--calcite-internal-animation-timing-fast) ease-in-out}:host button:hover,:host a:hover{text-decoration-line:none}.content{display:flex;flex-basis:auto;margin-inline:var(--calcite-button-content-margin-internal)}.icon-start-empty .content{margin-inline-start:unset}.icon-end-empty .content{margin-inline-end:unset}:host([scale=m]) button,:host([scale=m]) a{--calcite-button-content-margin-internal:0.75rem}:host([scale=l]) button,:host([scale=l]) a{--calcite-button-content-margin-internal:1rem}:host([width=auto]){inline-size:auto}:host([width=half]){inline-size:50%}:host([width=full]){inline-size:100%}:host([alignment=center]:not([width=auto])) a,:host([alignment=center]:not([width=auto])) button{justify-content:center}:host([alignment=start]:not([width=auto])) a,:host([alignment=start]:not([width=auto])) button{justify-content:flex-start}:host([alignment=end]:not([width=auto])) a,:host([alignment=end]:not([width=auto])) button{justify-content:flex-end}:host([alignment*=space-between]:not([width=auto])) a,:host([alignment*=space-between]:not([width=auto])) button{justify-content:space-between}:host([alignment=icon-start-space-between]:not([width=auto])) .icon--start{margin-inline-end:auto}:host([alignment=icon-start-space-between]:not([width=auto])) a,:host([alignment=icon-start-space-between]:not([width=auto])) button{text-align:unset}:host([alignment=icon-end-space-between]:not([width=auto])) .icon--end{margin-inline-start:auto}:host([alignment=icon-end-space-between]:not([width=auto])) a,:host([alignment=icon-end-space-between]:not([width=auto])) button{text-align:unset}:host([alignment=center]) a:not(.content--slotted) .icon--start+.icon--end,:host([alignment=center]) button:not(.content--slotted) .icon--start+.icon--end{margin-inline-start:var(--calcite-button-content-margin-internal)}.icon{position:relative;margin:0px;display:inline-flex;font-weight:var(--calcite-font-weight-normal);line-height:inherit}:host([disabled]) ::slotted([calcite-hydrated][disabled]),:host([disabled]) [calcite-hydrated][disabled]{opacity:1}:host([loading]){pointer-events:none}:host([loading]) button,:host([loading]) a{pointer-events:none;opacity:var(--calcite-ui-opacity-disabled)}@keyframes loader-in{0%{inline-size:0;opacity:0;transform:scale(0.5)}100%{inline-size:1em;opacity:1;transform:scale(1)}}@keyframes loader-out{0%{inline-size:1em;opacity:1;transform:scale(1)}100%{inline-size:0;opacity:0;transform:scale(0.5)}}.calcite-button--loader{display:flex}.calcite-button--loader calcite-loader{margin:0px;transition:inline-size var(--calcite-internal-animation-timing-slow) ease-in-out, opacity var(--calcite-internal-animation-timing-slow) ease-in-out, transform var(--calcite-internal-animation-timing-slow) ease-in-out}.calcite-button--loader calcite-loader.loading-in{animation-name:loader-in;animation-duration:var(--calcite-internal-animation-timing-slow)}.calcite-button--loader calcite-loader.loading-out{animation-name:loader-out;animation-duration:var(--calcite-internal-animation-timing-slow)}:host([loading]) button.content--slotted .calcite-button--loader calcite-loader,:host([loading]) a.content--slotted .calcite-button--loader calcite-loader{margin-inline-end:var(--calcite-button-content-margin-internal)}:host([loading]) button:not(.content--slotted) .icon--start,:host([loading]) button:not(.content--slotted) .icon--end,:host([loading]) a:not(.content--slotted) .icon--start,:host([loading]) a:not(.content--slotted) .icon--end{display:none}:host([appearance]) button,:host([appearance]) a{border-width:1px;border-style:solid;border-color:transparent}:host([kind=brand]) button,:host([kind=brand]) a{background-color:var(--calcite-ui-brand);color:var(--calcite-ui-text-inverse)}:host([kind=brand]) button:hover,:host([kind=brand]) button:focus,:host([kind=brand]) a:hover,:host([kind=brand]) a:focus{background-color:var(--calcite-ui-brand-hover)}:host([kind=brand]) button:active,:host([kind=brand]) a:active{background-color:var(--calcite-ui-brand-press)}:host([kind=brand]) button calcite-loader,:host([kind=brand]) a calcite-loader{color:var(--calcite-ui-text-inverse)}:host([kind=danger]) button,:host([kind=danger]) a{background-color:var(--calcite-ui-danger);color:var(--calcite-ui-text-inverse)}:host([kind=danger]) button:hover,:host([kind=danger]) button:focus,:host([kind=danger]) a:hover,:host([kind=danger]) a:focus{background-color:var(--calcite-ui-danger-hover)}:host([kind=danger]) button:active,:host([kind=danger]) a:active{background-color:var(--calcite-ui-danger-press)}:host([kind=danger]) button calcite-loader,:host([kind=danger]) a calcite-loader{color:var(--calcite-ui-text-inverse)}:host([kind=neutral]) button,:host([kind=neutral]) a{background-color:var(--calcite-ui-foreground-3);color:var(--calcite-ui-text-1)}:host([kind=neutral]) button:hover,:host([kind=neutral]) button:focus,:host([kind=neutral]) a:hover,:host([kind=neutral]) a:focus{background-color:var(--calcite-ui-foreground-2)}:host([kind=neutral]) button:active,:host([kind=neutral]) a:active{background-color:var(--calcite-ui-foreground-1)}:host([kind=neutral]) button calcite-loader,:host([kind=neutral]) a calcite-loader{color:var(--calcite-ui-text-1)}:host([kind=inverse]) button,:host([kind=inverse]) a{color:var(--calcite-ui-text-inverse);background-color:var(--calcite-ui-inverse)}:host([kind=inverse]) button:hover,:host([kind=inverse]) button:focus,:host([kind=inverse]) a:hover,:host([kind=inverse]) a:focus{background-color:var(--calcite-ui-inverse-hover)}:host([kind=inverse]) button:active,:host([kind=inverse]) a:active{background-color:var(--calcite-ui-inverse-press)}:host([kind=inverse]) button calcite-loader,:host([kind=inverse]) a calcite-loader{color:var(--calcite-ui-text-inverse)}:host([appearance=outline-fill]) button,:host([appearance=outline-fill]) a{border-width:1px;border-style:solid;background-color:var(--calcite-ui-foreground-1);box-shadow:inset 0 0 0 1px transparent}:host([appearance=outline-fill][kind=brand]) button,:host([appearance=outline-fill][kind=brand]) a{border-color:var(--calcite-ui-brand);background-color:var(--calcite-ui-foreground-1);color:var(--calcite-ui-brand)}:host([appearance=outline-fill][kind=brand]) button:hover,:host([appearance=outline-fill][kind=brand]) a:hover{border-color:var(--calcite-ui-brand-hover);color:var(--calcite-ui-brand-hover);box-shadow:inset 0 0 0 1px var(--calcite-ui-brand-hover)}:host([appearance=outline-fill][kind=brand]) button:focus,:host([appearance=outline-fill][kind=brand]) a:focus{border-color:var(--calcite-ui-brand);color:var(--calcite-ui-brand);box-shadow:inset 0 0 0 2px var(--calcite-ui-brand)}:host([appearance=outline-fill][kind=brand]) button:active,:host([appearance=outline-fill][kind=brand]) a:active{border-color:var(--calcite-ui-brand-press);color:var(--calcite-ui-brand-press);box-shadow:inset 0 0 0 2px var(--calcite-ui-brand-press)}:host([appearance=outline-fill][kind=brand]) button calcite-loader,:host([appearance=outline-fill][kind=brand]) a calcite-loader{color:var(--calcite-ui-brand)}:host([appearance=outline-fill][kind=danger]) button,:host([appearance=outline-fill][kind=danger]) a{border-color:var(--calcite-ui-danger);background-color:var(--calcite-ui-foreground-1);color:var(--calcite-ui-danger)}:host([appearance=outline-fill][kind=danger]) button:hover,:host([appearance=outline-fill][kind=danger]) a:hover{border-color:var(--calcite-ui-danger-hover);color:var(--calcite-ui-danger-hover);box-shadow:inset 0 0 0 1px var(--calcite-ui-danger-hover)}:host([appearance=outline-fill][kind=danger]) button:focus,:host([appearance=outline-fill][kind=danger]) a:focus{border-color:var(--calcite-ui-danger);color:var(--calcite-ui-danger);box-shadow:inset 0 0 0 2px var(--calcite-ui-danger)}:host([appearance=outline-fill][kind=danger]) button:active,:host([appearance=outline-fill][kind=danger]) a:active{border-color:var(--calcite-ui-danger-press);color:var(--calcite-ui-danger-press);box-shadow:inset 0 0 0 2px var(--calcite-ui-danger-press)}:host([appearance=outline-fill][kind=danger]) button calcite-loader,:host([appearance=outline-fill][kind=danger]) a calcite-loader{color:var(--calcite-ui-danger)}:host([appearance=outline-fill][kind=neutral]) button,:host([appearance=outline-fill][kind=neutral]) a{background-color:var(--calcite-ui-foreground-1);color:var(--calcite-ui-text-1);border-color:var(--calcite-ui-foreground-3)}:host([appearance=outline-fill][kind=neutral]) button:hover,:host([appearance=outline-fill][kind=neutral]) a:hover{box-shadow:inset 0 0 0 1px var(--calcite-ui-foreground-3)}:host([appearance=outline-fill][kind=neutral]) button:focus,:host([appearance=outline-fill][kind=neutral]) a:focus{box-shadow:inset 0 0 0 2px var(--calcite-ui-foreground-3)}:host([appearance=outline-fill][kind=neutral]) button:active,:host([appearance=outline-fill][kind=neutral]) a:active{box-shadow:inset 0 0 0 2px var(--calcite-ui-foreground-3)}:host([appearance=outline-fill][kind=neutral]) button calcite-loader,:host([appearance=outline-fill][kind=neutral]) a calcite-loader{color:var(--calcite-ui-text-1)}:host([appearance=outline-fill][kind=inverse]) button,:host([appearance=outline-fill][kind=inverse]) a{background-color:var(--calcite-ui-foreground-1);color:var(--calcite-ui-text-1);border-color:var(--calcite-ui-inverse)}:host([appearance=outline-fill][kind=inverse]) button:hover,:host([appearance=outline-fill][kind=inverse]) a:hover{border-color:var(--calcite-ui-inverse-hover);box-shadow:inset 0 0 0 1px var(--calcite-ui-inverse-hover)}:host([appearance=outline-fill][kind=inverse]) button:focus,:host([appearance=outline-fill][kind=inverse]) a:focus{border-color:var(--calcite-ui-inverse);box-shadow:inset 0 0 0 2px var(--calcite-ui-inverse)}:host([appearance=outline-fill][kind=inverse]) button:active,:host([appearance=outline-fill][kind=inverse]) a:active{border-color:var(--calcite-ui-inverse-press);box-shadow:inset 0 0 0 2px var(--calcite-ui-inverse-press)}:host([appearance=outline-fill][kind=inverse]) button calcite-loader,:host([appearance=outline-fill][kind=inverse]) a calcite-loader{color:var(--calcite-ui-text-1)}:host([appearance=outline]) button,:host([appearance=outline]) a{border-width:1px;border-style:solid;background-color:transparent;box-shadow:inset 0 0 0 1px transparent}:host([appearance=outline][kind=brand]) button,:host([appearance=outline][kind=brand]) a{border-color:var(--calcite-ui-brand);background-color:transparent;color:var(--calcite-ui-brand)}:host([appearance=outline][kind=brand]) button:hover,:host([appearance=outline][kind=brand]) a:hover{border-color:var(--calcite-ui-brand-hover);color:var(--calcite-ui-brand-hover);box-shadow:inset 0 0 0 1px var(--calcite-ui-brand-hover)}:host([appearance=outline][kind=brand]) button:focus,:host([appearance=outline][kind=brand]) a:focus{border-color:var(--calcite-ui-brand);color:var(--calcite-ui-brand);box-shadow:inset 0 0 0 2px var(--calcite-ui-brand)}:host([appearance=outline][kind=brand]) button:active,:host([appearance=outline][kind=brand]) a:active{border-color:var(--calcite-ui-brand-press);color:var(--calcite-ui-brand-press);box-shadow:inset 0 0 0 2px var(--calcite-ui-brand-press)}:host([appearance=outline][kind=brand]) button calcite-loader,:host([appearance=outline][kind=brand]) a calcite-loader{color:var(--calcite-ui-brand)}:host([appearance=outline][kind=danger]) button,:host([appearance=outline][kind=danger]) a{border-color:var(--calcite-ui-danger);background-color:transparent;color:var(--calcite-ui-danger)}:host([appearance=outline][kind=danger]) button:hover,:host([appearance=outline][kind=danger]) a:hover{border-color:var(--calcite-ui-danger-hover);color:var(--calcite-ui-danger-hover);box-shadow:inset 0 0 0 1px var(--calcite-ui-danger-hover)}:host([appearance=outline][kind=danger]) button:focus,:host([appearance=outline][kind=danger]) a:focus{border-color:var(--calcite-ui-danger);color:var(--calcite-ui-danger);box-shadow:inset 0 0 0 2px var(--calcite-ui-danger)}:host([appearance=outline][kind=danger]) button:active,:host([appearance=outline][kind=danger]) a:active{border-color:var(--calcite-ui-danger-press);color:var(--calcite-ui-danger-press);box-shadow:inset 0 0 0 2px var(--calcite-ui-danger-press)}:host([appearance=outline][kind=danger]) button calcite-loader,:host([appearance=outline][kind=danger]) a calcite-loader{color:var(--calcite-ui-danger)}:host([appearance=outline][kind=neutral]) button,:host([appearance=outline][kind=neutral]) a{background-color:transparent;color:var(--calcite-ui-text-1);border-color:var(--calcite-ui-border-1)}:host([appearance=outline][kind=neutral]) button:hover,:host([appearance=outline][kind=neutral]) a:hover{box-shadow:inset 0 0 0 1px var(--calcite-ui-foreground-3)}:host([appearance=outline][kind=neutral]) button:focus,:host([appearance=outline][kind=neutral]) a:focus{box-shadow:inset 0 0 0 2px var(--calcite-ui-foreground-3)}:host([appearance=outline][kind=neutral]) button:active,:host([appearance=outline][kind=neutral]) a:active{box-shadow:inset 0 0 0 2px var(--calcite-ui-foreground-3)}:host([appearance=outline][kind=neutral]) button calcite-loader,:host([appearance=outline][kind=neutral]) a calcite-loader{color:var(--calcite-ui-text-1)}:host([appearance=outline][kind=inverse]) button,:host([appearance=outline][kind=inverse]) a{background-color:transparent;color:var(--calcite-ui-text-1);border-color:var(--calcite-ui-inverse)}:host([appearance=outline][kind=inverse]) button:hover,:host([appearance=outline][kind=inverse]) a:hover{border-color:var(--calcite-ui-inverse-hover);box-shadow:inset 0 0 0 1px var(--calcite-ui-inverse-hover)}:host([appearance=outline][kind=inverse]) button:focus,:host([appearance=outline][kind=inverse]) a:focus{border-color:var(--calcite-ui-inverse);box-shadow:inset 0 0 0 2px var(--calcite-ui-inverse)}:host([appearance=outline][kind=inverse]) button:active,:host([appearance=outline][kind=inverse]) a:active{border-color:var(--calcite-ui-inverse-press);box-shadow:inset 0 0 0 2px var(--calcite-ui-inverse-press)}:host([appearance=outline][kind=inverse]) button calcite-loader,:host([appearance=outline][kind=inverse]) a calcite-loader{color:var(--calcite-ui-text-1)}:host([appearance=outline-fill][split-child=primary]) button,:host([appearance=outline][split-child=primary]) button{border-inline-end-width:0;border-inline-start-width:1px}:host([appearance=outline-fill][split-child=secondary]) button,:host([appearance=outline][split-child=secondary]) button{border-inline-start-width:0;border-inline-end-width:1px}:host([appearance=transparent]:not(.enable-editing-button)) button,:host([appearance=transparent]:not(.enable-editing-button)) a{background-color:transparent}:host([appearance=transparent]:not(.enable-editing-button)) button:hover,:host([appearance=transparent]:not(.enable-editing-button)) button:focus,:host([appearance=transparent]:not(.enable-editing-button)) a:hover,:host([appearance=transparent]:not(.enable-editing-button)) a:focus{background-color:var(--calcite-button-transparent-hover)}:host([appearance=transparent]:not(.enable-editing-button)) button:active,:host([appearance=transparent]:not(.enable-editing-button)) a:active{background-color:var(--calcite-button-transparent-press)}:host([appearance=transparent][kind=brand]) button,:host([appearance=transparent][kind=brand]) a{color:var(--calcite-ui-brand)}:host([appearance=transparent][kind=brand]) button:hover,:host([appearance=transparent][kind=brand]) a:hover{color:var(--calcite-ui-brand-hover)}:host([appearance=transparent][kind=brand]) button:focus,:host([appearance=transparent][kind=brand]) a:focus{color:var(--calcite-ui-brand)}:host([appearance=transparent][kind=brand]) button:active,:host([appearance=transparent][kind=brand]) a:active{color:var(--calcite-ui-brand-press)}:host([appearance=transparent][kind=brand]) button calcite-loader,:host([appearance=transparent][kind=brand]) a calcite-loader{color:var(--calcite-ui-brand)}:host([appearance=transparent][kind=danger]) button,:host([appearance=transparent][kind=danger]) a{color:var(--calcite-ui-danger)}:host([appearance=transparent][kind=danger]) button:hover,:host([appearance=transparent][kind=danger]) a:hover{color:var(--calcite-ui-danger-hover)}:host([appearance=transparent][kind=danger]) button:focus,:host([appearance=transparent][kind=danger]) a:focus{color:var(--calcite-ui-danger)}:host([appearance=transparent][kind=danger]) button:active,:host([appearance=transparent][kind=danger]) a:active{color:var(--calcite-ui-danger-press)}:host([appearance=transparent][kind=danger]) button calcite-loader,:host([appearance=transparent][kind=danger]) a calcite-loader{color:var(--calcite-ui-danger)}:host([appearance=transparent][kind=neutral]:not(.cancel-editing-button)) button,:host([appearance=transparent][kind=neutral]:not(.cancel-editing-button)) a,:host([appearance=transparent][kind=neutral]:not(.cancel-editing-button)) calcite-loader{color:var(--calcite-ui-text-1)}:host([appearance=transparent][kind=neutral].cancel-editing-button) button{border-block-start-width:1px;border-block-end-width:1px;color:var(--calcite-ui-text-3);border-block-start-color:var(--calcite-ui-border-input);border-block-end-color:var(--calcite-ui-border-input);border-block-style:solid}:host([appearance=transparent][kind=neutral].cancel-editing-button) button:not(.content--slotted){--calcite-button-padding-y-internal:0}:host([appearance=transparent][kind=neutral].cancel-editing-button) button:hover{color:var(--calcite-ui-text-1)}:host([appearance=transparent][kind=neutral].enable-editing-button) button{background-color:transparent}:host(.confirm-changes-button) button:focus,:host(.cancel-editing-button) button:focus,:host(.enable-editing-button) button:focus{outline-offset:-2px}:host([appearance=transparent][kind=inverse]) button,:host([appearance=transparent][kind=inverse]) a,:host([appearance=transparent][kind=inverse]) calcite-loader{color:var(--calcite-ui-text-inverse)}:host([scale=s]) button.content--slotted,:host([scale=s]) a.content--slotted{font-size:var(--calcite-font-size--2);line-height:1rem}:host([scale=s][appearance=transparent]) button.content--slotted,:host([scale=s][appearance=transparent]) a.content--slotted{--calcite-button-padding-x-internal:0.5rem}:host([scale=s]) button,:host([scale=s]) a{--calcite-button-padding-y-internal:3px}:host([scale=m]) button.content--slotted,:host([scale=m]) a.content--slotted{--calcite-button-padding-x-internal:11px;font-size:var(--calcite-font-size--1);line-height:1rem}:host([scale=m]) button,:host([scale=m]) a{--calcite-button-padding-y-internal:7px}:host([scale=m][appearance=transparent]) button.content--slotted,:host([scale=m][appearance=transparent]) a.content--slotted{--calcite-button-padding-x-internal:0.75rem}:host([scale=l]) button.content--slotted,:host([scale=l]) a.content--slotted{--calcite-button-padding-x-internal:15px;font-size:var(--calcite-font-size-0);line-height:1.25rem}:host([scale=l]) .button-padding{--calcite-button-padding-x-internal:1rem;--calcite-button-padding-y-internal:11px}:host([scale=l]) .button-padding--shrunk{--calcite-button-padding-y-internal:9px}:host([scale=s]) button:not(.content--slotted),:host([scale=s]) a:not(.content--slotted){--calcite-button-padding-x-internal:0.125rem;--calcite-button-padding-y-internal:3px;inline-size:1.5rem;font-size:var(--calcite-font-size-0);line-height:1.25rem;min-block-size:1.5rem}:host([scale=m]) button:not(.content--slotted),:host([scale=m]) a:not(.content--slotted){--calcite-button-padding-x-internal:0.125rem;--calcite-button-padding-y-internal:7px;inline-size:2rem;font-size:var(--calcite-font-size-0);line-height:1.25rem;min-block-size:2rem}:host([scale=l]) button:not(.content--slotted),:host([scale=l]) a:not(.content--slotted){--calcite-button-padding-x-internal:0.125rem;--calcite-button-padding-y-internal:9px;inline-size:2.75rem;font-size:var(--calcite-font-size-0);line-height:1.25rem;min-block-size:2.75rem}:host([scale=l][appearance=transparent]) button:not(.content--slotted),:host([scale=l][appearance=transparent]) a:not(.content--slotted){--calcite-button-padding-y-internal:0.625rem}:host([scale=s][icon-start][icon-end]) button:not(.content--slotted),:host([scale=s][icon-start][icon-end]) a:not(.content--slotted){--calcite-button-padding-x-internal:23px;block-size:1.5rem;font-size:var(--calcite-font-size-0);line-height:1.25rem}:host([scale=s][icon-start][icon-end][appearance=transparent]) button:not(.content--slotted),:host([scale=s][icon-start][icon-end][appearance=transparent]) a:not(.content--slotted){--calcite-button-padding-x-internal:1.5rem}:host([scale=m][icon-start][icon-end]) button:not(.content--slotted),:host([scale=m][icon-start][icon-end]) a:not(.content--slotted){--calcite-button-padding-x-internal:2rem;block-size:2rem;font-size:var(--calcite-font-size-0);line-height:1.25rem}:host([scale=m][icon-start][icon-end][appearance=transparent]) button:not(.content--slotted),:host([scale=m][icon-start][icon-end][appearance=transparent]) a:not(.content--slotted){--calcite-button-padding-x-internal:33px}:host([scale=l][icon-start][icon-end]) button:not(.content--slotted),:host([scale=l][icon-start][icon-end]) a:not(.content--slotted){--calcite-button-padding-x-internal:43px;block-size:2.75rem;font-size:var(--calcite-font-size-0);line-height:1.25rem}:host([scale=l][icon-start][icon-end]) button:not(.content--slotted) .icon--start+.icon--end,:host([scale=l][icon-start][icon-end]) a:not(.content--slotted) .icon--start+.icon--end{margin-inline-start:1rem}:host([scale=l][icon-start][icon-end][appearance=transparent]) button:not(.content--slotted),:host([scale=l][icon-start][icon-end][appearance=transparent]) a:not(.content--slotted){--calcite-button-padding-x-internal:2.75rem}";export{w as calcite_button}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/*!
|
|
2
2
|
* All material copyright ESRI, All Rights Reserved, unless otherwise specified.
|
|
3
3
|
* See https://github.com/Esri/calcite-components/blob/master/LICENSE.md for details.
|
|
4
|
-
* v1.1.
|
|
4
|
+
* v1.1.1-next.1
|
|
5
5
|
*/
|
|
6
|
-
import{h as i,r as t,c as s,H as a,g as e}from"./p-
|
|
6
|
+
import{h as i,r as t,c as s,H as a,g as e}from"./p-983244bc.js";import{c as n,d as o,H as c}from"./p-941fee1b.js";import{g as r}from"./p-1e3ad5b6.js";import{u as l}from"./p-9f094be8.js";import{c as h,d}from"./p-b8b075fd.js";import{s as m,a as p,c as u}from"./p-0e573040.js";import{c as f,d as v}from"./p-d70da26b.js";import{u as g,c as b,s as y,d as w}from"./p-2c2c6832.js";import"./p-cff554c3.js";import"./p-ebd84c48.js";import"./p-83b37109.js";import"./p-53515d24.js";const k=({full:t,scale:s,partial:a})=>i("calcite-icon",{class:a?void 0:"icon",icon:t?"star-f":"star",scale:s}),x=class{constructor(i){t(this,i),this.calciteRatingChange=s(this,"calciteRatingChange",6),this.handleRatingPointerOver=()=>{this.isKeyboardInteraction=!1},this.handleRatingPointerOut=()=>{this.isKeyboardInteraction=!0,this.hoverValue=null,this.focusValue=null,this.hasFocus=!1},this.handleRatingFocusIn=()=>{const i=this.inputRefs[this.value>0?this.value-1:0],t=Number(i.value);i.select(),this.focusValue=t,this.hoverValue=t,this.hasFocus=!0},this.handleRatingFocusLeave=()=>{this.focusValue=null,this.hoverValue=null,this.hasFocus=!1},this.handleHostKeyDown=()=>{this.isKeyboardInteraction=!0},this.handleInputKeyDown=i=>{const t=Number(i.currentTarget.value),s=i.key,a=" "==s?void 0:Number(s);if(this.emit=!0,isNaN(a))switch(s){case"Enter":case" ":this.value=this.required||this.value!==t?t:0;break;case"ArrowLeft":this.value=t-1;break;case"ArrowRight":this.value=t+1;break;case"Tab":this.hasFocus&&(this.hasFocus=!1,this.focusValue=null,this.hoverValue=null)}else(!this.required&&a>=0&&a<=this.max||this.required&&a>0&&a<=this.max)&&(this.value=a)},this.handleInputChange=i=>{if(!0===this.isKeyboardInteraction){const t=Number(i.target.value);this.focusValue=t,this.hoverValue=t,this.value=t}},this.handleLabelPointerOver=i=>{const t=Number(i.currentTarget.firstChild.value||0);this.hoverValue=t,this.focusValue=null},this.handleLabelPointerDown=i=>{const t=Number(i.currentTarget.firstChild.value||0);this.focusValue=null,this.hoverValue=null,this.emit=!0,this.value=this.required||this.value!==t?t:0},this.emit=!1,this.guid=`calcite-ratings-${r()}`,this.isKeyboardInteraction=!0,this.max=5,this.average=void 0,this.count=void 0,this.disabled=!1,this.messages=void 0,this.messageOverrides=void 0,this.name=void 0,this.readOnly=!1,this.required=!1,this.scale="m",this.showChip=!1,this.value=0,this.effectiveLocale="",this.defaultMessages=void 0,this.hoverValue=void 0,this.focusValue=void 0,this.hasFocus=void 0}onMessagesChange(){}handleValueUpdate(i){this.hoverValue=i,this.focusValue=i,this.emit&&this.calciteRatingChange.emit(),this.emit=!1}effectiveLocaleChange(){g(this,this.effectiveLocale)}connectedCallback(){f(this),b(this),h(this),n(this)}async componentWillLoad(){await y(this),m(this),this.inputRefs=Array(this.max)}componentWillRender(){this.starsMap=Array.from({length:this.max},((i,t)=>{const s=t+1,a=this.average&&this.average+1-s,e=s<=this.hoverValue;return{average:!this.focusValue&&!this.hoverValue&&this.average&&!this.value&&s<=this.average,checked:s===this.value,focused:this.isKeyboardInteraction&&this.hasFocus&&this.focusValue===s,fraction:a,hovered:e,id:`${this.guid}-${s}`,idx:t,partial:!this.focusValue&&!this.hoverValue&&!this.value&&!e&&a>0&&a<1,selected:this.value>=s,value:s}}))}componentDidLoad(){p(this)}disconnectedCallback(){v(this),w(this),d(this),o(this)}componentDidRender(){l(this)}render(){return i(a,{onBlur:this.handleRatingFocusLeave,onFocus:this.handleRatingFocusIn,onKeyDown:this.handleHostKeyDown,onPointerOut:this.handleRatingPointerOut,onPointerOver:this.handleRatingPointerOver},i("span",{class:"wrapper"},i("fieldset",{class:"fieldset",disabled:this.disabled},i("legend",{class:"visually-hidden"},this.messages.rating),this.starsMap.map((({average:t,checked:s,focused:a,fraction:e,hovered:n,id:o,idx:c,partial:r,selected:l,value:h})=>i("label",{class:{star:!0,focused:a,selected:l,hovered:n,average:t,partial:r},htmlFor:o,onPointerDown:this.handleLabelPointerDown,onPointerOver:this.handleLabelPointerOver},i("input",{checked:s,class:"visually-hidden",disabled:this.disabled||this.readOnly,id:o,name:this.guid,onChange:this.handleInputChange,onKeyDown:this.handleInputKeyDown,type:"radio",value:h,ref:i=>(this.inputRefs[c]=i,(1===h||h===this.value)&&(this.inputFocusRef=i))}),i(k,{full:l||t,scale:this.scale}),r&&i("div",{class:"fraction",style:{width:100*e+"%"}},i(k,{full:!0,partial:!0,scale:this.scale})),i("span",{class:"visually-hidden"},this.messages.stars.replace("${num}",`${h}`))))),(this.count||this.average)&&this.showChip?i("calcite-chip",{scale:this.scale,value:this.count?.toString()},!!this.average&&i("span",{class:"number--average"},this.average.toString()),!!this.count&&i("span",{class:"number--count"},"(",this.count?.toString(),")")):null),i(c,{component:this})))}onLabelClick(){this.setFocus()}async setFocus(){await u(this),this.inputFocusRef?.focus()}static get assetsDirs(){return["assets"]}get el(){return e(this)}static get watchers(){return{messageOverrides:["onMessagesChange"],value:["handleValueUpdate"],effectiveLocale:["effectiveLocaleChange"]}}};x.style="@keyframes in{0%{opacity:0}100%{opacity:1}}@keyframes in-down{0%{opacity:0;transform:translate3D(0, -5px, 0)}100%{opacity:1;transform:translate3D(0, 0, 0)}}@keyframes in-up{0%{opacity:0;transform:translate3D(0, 5px, 0)}100%{opacity:1;transform:translate3D(0, 0, 0)}}@keyframes in-scale{0%{opacity:0;transform:scale3D(0.95, 0.95, 1)}100%{opacity: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;animation-fill-mode:both;animation-duration:var(--calcite-animation-timing)}.calcite-animate__in{animation-name:in}.calcite-animate__in-down{animation-name:in-down}.calcite-animate__in-up{animation-name:in-up}.calcite-animate__in-scale{animation-name:in-scale}@media (prefers-reduced-motion: reduce){:root{--calcite-internal-duration-factor:0.01}}:root{--calcite-floating-ui-transition:var(--calcite-animation-timing);--calcite-floating-ui-z-index:600}:host([hidden]){display:none}:host([disabled]){pointer-events:none;cursor:default;-webkit-user-select:none;user-select:none;opacity:var(--calcite-ui-opacity-disabled)}:host{position:relative;display:flex;align-items:center;inline-size:-moz-fit-content;inline-size:fit-content}:host([disabled]) ::slotted([calcite-hydrated][disabled]),:host([disabled]) [calcite-hydrated][disabled]{opacity:1}:host([scale=s]){block-size:1.5rem;--calcite-rating-spacing-unit:0.25rem}:host([scale=m]){block-size:2rem;--calcite-rating-spacing-unit:0.5rem}:host([scale=l]){block-size:2.75rem;--calcite-rating-spacing-unit:0.75rem}:host([read-only]){pointer-events:none}.fieldset{margin:0;display:flex;border-width:0;padding:0;align-items:center;gap:var(--calcite-rating-spacing-unit)}.wrapper{display:inline-block}.star{transition:all var(--calcite-animation-timing) ease-in-out 0s, outline 0s, outline-offset 0s;position:relative;display:flex;flex-direction:column;cursor:pointer;color:var(--calcite-ui-border-input)}.focused{outline:2px solid var(--calcite-ui-brand);outline-offset:2px}.average,.fraction{color:var(--calcite-ui-warning)}.hovered,.selected{color:var(--calcite-ui-brand)}.fraction{transition:all var(--calcite-animation-timing) ease-in-out 0s, outline 0s, outline-offset 0s;position:absolute;pointer-events:none;inset-block-start:0;overflow:hidden;inset-inline-start:0}calcite-chip{pointer-events:none;cursor:default}.number--average{font-weight:bold}.number--count{color:var(--calcite-ui-text-2);font-style:italic}.number--count:not(:first-child){margin-inline-start:var(--calcite-rating-spacing-unit)}.visually-hidden{position:absolute;inline-size:1px;block-size:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0, 0, 0, 0);white-space:nowrap;border-width:0}::slotted(input[slot=hidden-form-input]){margin:0 !important;opacity:0 !important;outline:none !important;padding:0 !important;position:absolute !important;inset:0 !important;transform:none !important;-webkit-appearance:none !important;z-index:-1 !important}";export{x as calcite_rating}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/*!
|
|
2
2
|
* All material copyright ESRI, All Rights Reserved, unless otherwise specified.
|
|
3
3
|
* See https://github.com/Esri/calcite-components/blob/master/LICENSE.md for details.
|
|
4
|
-
* v1.1.
|
|
4
|
+
* v1.1.1-next.1
|
|
5
5
|
*/
|
|
6
|
-
import{r as t,c as e,h as i,F as n,g as a}from"./p-95affd38.js";import{j as s,t as o}from"./p-b4c2f2ce.js";import{u as c}from"./p-b90df3dd.js";import{s as r,a as l,c as d}from"./p-bb1240f3.js";import{c as h}from"./p-f510244b.js";import{S as m}from"./p-0534cef5.js";import{H as p}from"./p-2afe300d.js";import{S as f,C as u,I as g}from"./p-adef0422.js";import{c as b,d as x}from"./p-b33dc129.js";import{c as y,s as v,d as k,u as w}from"./p-145b7cdc.js";import"./p-c097b143.js";import"./p-44e65dab.js";import"./p-32d3d2c6.js";const z=class{constructor(i){t(this,i),this.calcitePanelClose=e(this,"calcitePanelClose",6),this.calcitePanelScroll=e(this,"calcitePanelScroll",6),this.resizeObserver=h("resize",(()=>this.resizeHandler())),this.resizeHandler=()=>{const{panelScrollEl:t}=this;t&&"number"==typeof t.scrollHeight&&"number"==typeof t.offsetHeight&&(t.tabIndex=t.scrollHeight>t.offsetHeight?0:-1)},this.setContainerRef=t=>{this.containerEl=t},this.setCloseRef=t=>{this.closeButtonEl=t},this.setBackRef=t=>{this.backButtonEl=t},this.panelKeyDownHandler=t=>{this.closable&&"Escape"===t.key&&!t.defaultPrevented&&(this.close(),t.preventDefault())},this.close=()=>{this.closed=!0,this.calcitePanelClose.emit()},this.panelScrollHandler=()=>{this.calcitePanelScroll.emit()},this.handleHeaderActionsStartSlotChange=t=>{const e=t.target.assignedElements({flatten:!0});this.hasStartActions=!!e.length},this.handleHeaderActionsEndSlotChange=t=>{const e=t.target.assignedElements({flatten:!0});this.hasEndActions=!!e.length},this.handleHeaderMenuActionsSlotChange=t=>{const e=t.target.assignedElements({flatten:!0});this.hasMenuItems=!!e.length},this.handleHeaderContentSlotChange=t=>{const e=t.target.assignedElements({flatten:!0});this.hasHeaderContent=!!e.length},this.handleFooterSlotChange=t=>{const e=t.target.assignedElements({flatten:!0});this.hasFooterContent=!!e.length},this.handleFooterActionsSlotChange=t=>{const e=t.target.assignedElements({flatten:!0});this.hasFooterActions=!!e.length},this.handleFabSlotChange=t=>{const e=t.target.assignedElements({flatten:!0});this.hasFab=!!e.length},this.setPanelScrollEl=t=>{this.panelScrollEl=t,this.resizeObserver?.disconnect(),t&&(this.resizeObserver?.observe(t),this.resizeHandler())},this.closed=!1,this.disabled=!1,this.closable=!1,this.headingLevel=void 0,this.loading=!1,this.heading=void 0,this.description=void 0,this.menuOpen=!1,this.messageOverrides=void 0,this.messages=void 0,this.hasStartActions=!1,this.hasEndActions=!1,this.hasMenuItems=!1,this.hasHeaderContent=!1,this.hasFooterContent=!1,this.hasFooterActions=!1,this.hasFab=!1,this.defaultMessages=void 0,this.effectiveLocale=""}onMessagesChange(){}connectedCallback(){b(this),y(this)}async componentWillLoad(){r(this),await v(this)}componentDidLoad(){l(this)}componentDidRender(){c(this)}disconnectedCallback(){x(this),k(this),this.resizeObserver?.disconnect()}effectiveLocaleChange(){w(this,this.effectiveLocale)}async setFocus(){await d(this),s(this.containerEl)}async scrollContentTo(t){this.panelScrollEl?.scrollTo(t)}renderHeaderContent(){const{heading:t,headingLevel:e,description:n,hasHeaderContent:a}=this,s=t?i(p,{class:u.heading,level:e},t):null,o=n?i("span",{class:u.description},n):null;return a||!s&&!o?null:i("div",{class:u.headerContent,key:"header-content"},s,o)}renderHeaderSlottedContent(){return i("div",{class:u.headerContent,hidden:!this.hasHeaderContent,key:"slotted-header-content"},i("slot",{name:f.headerContent,onSlotchange:this.handleHeaderContentSlotChange}))}renderHeaderStartActions(){const{hasStartActions:t}=this;return i("div",{class:{[u.headerActionsStart]:!0,[u.headerActions]:!0},hidden:!t,key:"header-actions-start"},i("slot",{name:f.headerActionsStart,onSlotchange:this.handleHeaderActionsStartSlotChange}))}renderHeaderActionsEnd(){const{close:t,hasEndActions:e,messages:n,closable:a}=this,s=n.close,o=a?i("calcite-action",{"aria-label":s,icon:g.close,onClick:t,text:s,ref:this.setCloseRef}):null,c=i("slot",{name:f.headerActionsEnd,onSlotchange:this.handleHeaderActionsEndSlotChange});return i("div",{class:{[u.headerActionsEnd]:!0,[u.headerActions]:!0},hidden:!(e||o),key:"header-actions-end"},c,o)}renderMenu(){const{hasMenuItems:t,messages:e,menuOpen:n}=this;return i("calcite-action-menu",{flipPlacements:["top","bottom"],hidden:!t,key:"menu",label:e.options,open:n,placement:"bottom-end"},i("calcite-action",{icon:g.menu,slot:m.trigger,text:e.options}),i("slot",{name:f.headerMenuActions,onSlotchange:this.handleHeaderMenuActionsSlotChange}))}renderHeaderNode(){const{hasHeaderContent:t,hasStartActions:e,hasEndActions:n,closable:a,hasMenuItems:s}=this,o=this.renderHeaderContent();return i("header",{class:u.header,hidden:!(t||o||e||n||a||s)},this.renderHeaderStartActions(),this.renderHeaderSlottedContent(),o,this.renderHeaderActionsEnd(),this.renderMenu())}renderFooterNode(){const{hasFooterContent:t,hasFooterActions:e}=this;return i("footer",{class:u.footer,hidden:!(t||e)},i("slot",{key:"footer-slot",name:f.footer,onSlotchange:this.handleFooterSlotChange}),i("slot",{key:"footer-actions-slot",name:f.footerActions,onSlotchange:this.handleFooterActionsSlotChange}))}renderContent(){const{hasFab:t}=this,e=i("slot",{key:"default-slot"}),n=t?i("section",{class:u.contentContainer},e):e;return i("div",{class:{[u.contentWrapper]:!0,[u.contentContainer]:!t,[u.contentHeight]:t},onScroll:this.panelScrollHandler,ref:this.setPanelScrollEl},n,this.renderFab())}renderFab(){return i("div",{class:u.fabContainer,hidden:!this.hasFab},i("slot",{name:f.fab,onSlotchange:this.handleFabSlotChange}))}render(){const{loading:t,panelKeyDownHandler:e,closed:a,closable:s}=this,c=i("article",{"aria-busy":o(t),class:u.container,hidden:a,onKeyDown:e,tabIndex:s?0:-1,ref:this.setContainerRef},this.renderHeaderNode(),this.renderContent(),this.renderFooterNode());return i(n,null,t?i("calcite-scrim",{loading:t}):null,c)}static get assetsDirs(){return["assets"]}get el(){return a(this)}static get watchers(){return{messageOverrides:["onMessagesChange"],effectiveLocale:["effectiveLocaleChange"]}}};z.style="@keyframes in{0%{opacity:0}100%{opacity:1}}@keyframes in-down{0%{opacity:0;transform:translate3D(0, -5px, 0)}100%{opacity:1;transform:translate3D(0, 0, 0)}}@keyframes in-up{0%{opacity:0;transform:translate3D(0, 5px, 0)}100%{opacity:1;transform:translate3D(0, 0, 0)}}@keyframes in-scale{0%{opacity:0;transform:scale3D(0.95, 0.95, 1)}100%{opacity: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;animation-fill-mode:both;animation-duration:var(--calcite-animation-timing)}.calcite-animate__in{animation-name:in}.calcite-animate__in-down{animation-name:in-down}.calcite-animate__in-up{animation-name:in-up}.calcite-animate__in-scale{animation-name:in-scale}@media (prefers-reduced-motion: reduce){:root{--calcite-internal-duration-factor:0.01}}:host{box-sizing:border-box;background-color:var(--calcite-ui-foreground-1);color:var(--calcite-ui-text-2);font-size:var(--calcite-font-size--1)}:host *{box-sizing:border-box}:root{--calcite-floating-ui-transition:var(--calcite-animation-timing);--calcite-floating-ui-z-index:600}:host([hidden]){display:none}:host([disabled]){pointer-events:none;cursor:default;-webkit-user-select:none;user-select:none;opacity:var(--calcite-ui-opacity-disabled)}:host{position:relative;display:flex;block-size:100%;inline-size:100%;flex:1 1 auto;overflow:hidden;--calcite-min-header-height:calc(var(--calcite-icon-size) * 3)}:host([disabled]) ::slotted([calcite-hydrated][disabled]),:host([disabled]) [calcite-hydrated][disabled]{opacity:1}.header{margin:0px;display:flex;align-content:space-between;align-items:center;fill:var(--calcite-ui-text-2);color:var(--calcite-ui-text-2)}.heading{margin:0px;padding:0px;font-weight:var(--calcite-font-weight-medium)}.header .heading{flex:1 1 auto;padding:0.5rem}.container{margin:0px;display:flex;inline-size:100%;flex:1 1 auto;flex-direction:column;align-items:stretch;background-color:var(--calcite-ui-background);padding:0px;transition:max-block-size var(--calcite-animation-timing), inline-size var(--calcite-animation-timing)}.container[hidden]{display:none}.header{border-block-end:1px solid;position:sticky;inset-block-start:0px;z-index:400;inline-size:100%;align-items:stretch;justify-content:flex-start;background-color:var(--calcite-ui-foreground-1);border-block-end-color:var(--calcite-ui-border-3);flex:0 0 auto}.header-content{display:flex;flex-direction:column;overflow:hidden;padding-inline:0.75rem;padding-block:0.875rem;margin-inline-end:auto}.header-content .heading,.header-content .description{display:block;overflow-wrap:break-word;padding:0px}.header-content .heading{margin-inline:0px;margin-block:0px 0.25rem;font-size:var(--calcite-font-size-0);line-height:1.25rem;font-weight:var(--calcite-font-weight-medium)}.header-content .heading:only-child{margin-block-end:0px}.header-content .description{font-size:var(--calcite-font-size--1);line-height:1rem;color:var(--calcite-ui-text-2)}.back-button{border-width:0px;border-style:solid;border-color:var(--calcite-ui-border-3);border-inline-end-width:1px}.header-actions{display:flex;flex-direction:row;flex-wrap:nowrap;align-items:stretch}.header-actions--end{margin-inline-start:auto}.content-wrapper{overflow:auto}.content-height{block-size:100%}.content-container{display:flex;flex:1 1 auto;flex-direction:column;flex-wrap:nowrap;align-items:stretch;background-color:var(--calcite-ui-background)}.footer{border-block-start:1px solid;position:sticky;inset-block-end:0px;display:flex;inline-size:100%;justify-content:space-evenly;background-color:var(--calcite-ui-foreground-1);border-block-start-color:var(--calcite-ui-border-3);flex:0 0 auto;min-block-size:3rem;padding:0.5rem}.fab-container{position:sticky;inset-block-end:0px;z-index:300;margin-block:0px;margin-inline:auto;display:block;padding:0.5rem;inset-inline:0;inline-size:-moz-fit-content;inline-size:fit-content}[hidden]{display:none}";export{z as calcite_panel}
|
|
6
|
+
import{r as t,c as e,h as i,F as n,g as a}from"./p-983244bc.js";import{j as s,t as o}from"./p-cff554c3.js";import{u as c}from"./p-9f094be8.js";import{s as r,a as l,c as d}from"./p-0e573040.js";import{c as h}from"./p-53515d24.js";import{S as m}from"./p-9d18f5bb.js";import{H as p}from"./p-95829133.js";import{S as f,C as u,I as g}from"./p-aeb9de45.js";import{c as b,d as x}from"./p-d70da26b.js";import{c as y,s as v,d as k,u as w}from"./p-2c2c6832.js";import"./p-1e3ad5b6.js";import"./p-ebd84c48.js";import"./p-83b37109.js";const z=class{constructor(i){t(this,i),this.calcitePanelClose=e(this,"calcitePanelClose",6),this.calcitePanelScroll=e(this,"calcitePanelScroll",6),this.resizeObserver=h("resize",(()=>this.resizeHandler())),this.resizeHandler=()=>{const{panelScrollEl:t}=this;t&&"number"==typeof t.scrollHeight&&"number"==typeof t.offsetHeight&&(t.tabIndex=t.scrollHeight>t.offsetHeight?0:-1)},this.setContainerRef=t=>{this.containerEl=t},this.setCloseRef=t=>{this.closeButtonEl=t},this.setBackRef=t=>{this.backButtonEl=t},this.panelKeyDownHandler=t=>{this.closable&&"Escape"===t.key&&!t.defaultPrevented&&(this.close(),t.preventDefault())},this.close=()=>{this.closed=!0,this.calcitePanelClose.emit()},this.panelScrollHandler=()=>{this.calcitePanelScroll.emit()},this.handleHeaderActionsStartSlotChange=t=>{const e=t.target.assignedElements({flatten:!0});this.hasStartActions=!!e.length},this.handleHeaderActionsEndSlotChange=t=>{const e=t.target.assignedElements({flatten:!0});this.hasEndActions=!!e.length},this.handleHeaderMenuActionsSlotChange=t=>{const e=t.target.assignedElements({flatten:!0});this.hasMenuItems=!!e.length},this.handleHeaderContentSlotChange=t=>{const e=t.target.assignedElements({flatten:!0});this.hasHeaderContent=!!e.length},this.handleFooterSlotChange=t=>{const e=t.target.assignedElements({flatten:!0});this.hasFooterContent=!!e.length},this.handleFooterActionsSlotChange=t=>{const e=t.target.assignedElements({flatten:!0});this.hasFooterActions=!!e.length},this.handleFabSlotChange=t=>{const e=t.target.assignedElements({flatten:!0});this.hasFab=!!e.length},this.setPanelScrollEl=t=>{this.panelScrollEl=t,this.resizeObserver?.disconnect(),t&&(this.resizeObserver?.observe(t),this.resizeHandler())},this.closed=!1,this.disabled=!1,this.closable=!1,this.headingLevel=void 0,this.loading=!1,this.heading=void 0,this.description=void 0,this.menuOpen=!1,this.messageOverrides=void 0,this.messages=void 0,this.hasStartActions=!1,this.hasEndActions=!1,this.hasMenuItems=!1,this.hasHeaderContent=!1,this.hasFooterContent=!1,this.hasFooterActions=!1,this.hasFab=!1,this.defaultMessages=void 0,this.effectiveLocale=""}onMessagesChange(){}connectedCallback(){b(this),y(this)}async componentWillLoad(){r(this),await v(this)}componentDidLoad(){l(this)}componentDidRender(){c(this)}disconnectedCallback(){x(this),k(this),this.resizeObserver?.disconnect()}effectiveLocaleChange(){w(this,this.effectiveLocale)}async setFocus(){await d(this),s(this.containerEl)}async scrollContentTo(t){this.panelScrollEl?.scrollTo(t)}renderHeaderContent(){const{heading:t,headingLevel:e,description:n,hasHeaderContent:a}=this,s=t?i(p,{class:u.heading,level:e},t):null,o=n?i("span",{class:u.description},n):null;return a||!s&&!o?null:i("div",{class:u.headerContent,key:"header-content"},s,o)}renderHeaderSlottedContent(){return i("div",{class:u.headerContent,hidden:!this.hasHeaderContent,key:"slotted-header-content"},i("slot",{name:f.headerContent,onSlotchange:this.handleHeaderContentSlotChange}))}renderHeaderStartActions(){const{hasStartActions:t}=this;return i("div",{class:{[u.headerActionsStart]:!0,[u.headerActions]:!0},hidden:!t,key:"header-actions-start"},i("slot",{name:f.headerActionsStart,onSlotchange:this.handleHeaderActionsStartSlotChange}))}renderHeaderActionsEnd(){const{close:t,hasEndActions:e,messages:n,closable:a}=this,s=n.close,o=a?i("calcite-action",{"aria-label":s,icon:g.close,onClick:t,text:s,ref:this.setCloseRef}):null,c=i("slot",{name:f.headerActionsEnd,onSlotchange:this.handleHeaderActionsEndSlotChange});return i("div",{class:{[u.headerActionsEnd]:!0,[u.headerActions]:!0},hidden:!(e||o),key:"header-actions-end"},c,o)}renderMenu(){const{hasMenuItems:t,messages:e,menuOpen:n}=this;return i("calcite-action-menu",{flipPlacements:["top","bottom"],hidden:!t,key:"menu",label:e.options,open:n,placement:"bottom-end"},i("calcite-action",{icon:g.menu,slot:m.trigger,text:e.options}),i("slot",{name:f.headerMenuActions,onSlotchange:this.handleHeaderMenuActionsSlotChange}))}renderHeaderNode(){const{hasHeaderContent:t,hasStartActions:e,hasEndActions:n,closable:a,hasMenuItems:s}=this,o=this.renderHeaderContent();return i("header",{class:u.header,hidden:!(t||o||e||n||a||s)},this.renderHeaderStartActions(),this.renderHeaderSlottedContent(),o,this.renderHeaderActionsEnd(),this.renderMenu())}renderFooterNode(){const{hasFooterContent:t,hasFooterActions:e}=this;return i("footer",{class:u.footer,hidden:!(t||e)},i("slot",{key:"footer-slot",name:f.footer,onSlotchange:this.handleFooterSlotChange}),i("slot",{key:"footer-actions-slot",name:f.footerActions,onSlotchange:this.handleFooterActionsSlotChange}))}renderContent(){const{hasFab:t}=this,e=i("slot",{key:"default-slot"}),n=t?i("section",{class:u.contentContainer},e):e;return i("div",{class:{[u.contentWrapper]:!0,[u.contentContainer]:!t,[u.contentHeight]:t},onScroll:this.panelScrollHandler,ref:this.setPanelScrollEl},n,this.renderFab())}renderFab(){return i("div",{class:u.fabContainer,hidden:!this.hasFab},i("slot",{name:f.fab,onSlotchange:this.handleFabSlotChange}))}render(){const{loading:t,panelKeyDownHandler:e,closed:a,closable:s}=this,c=i("article",{"aria-busy":o(t),class:u.container,hidden:a,onKeyDown:e,tabIndex:s?0:-1,ref:this.setContainerRef},this.renderHeaderNode(),this.renderContent(),this.renderFooterNode());return i(n,null,t?i("calcite-scrim",{loading:t}):null,c)}static get assetsDirs(){return["assets"]}get el(){return a(this)}static get watchers(){return{messageOverrides:["onMessagesChange"],effectiveLocale:["effectiveLocaleChange"]}}};z.style="@keyframes in{0%{opacity:0}100%{opacity:1}}@keyframes in-down{0%{opacity:0;transform:translate3D(0, -5px, 0)}100%{opacity:1;transform:translate3D(0, 0, 0)}}@keyframes in-up{0%{opacity:0;transform:translate3D(0, 5px, 0)}100%{opacity:1;transform:translate3D(0, 0, 0)}}@keyframes in-scale{0%{opacity:0;transform:scale3D(0.95, 0.95, 1)}100%{opacity: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;animation-fill-mode:both;animation-duration:var(--calcite-animation-timing)}.calcite-animate__in{animation-name:in}.calcite-animate__in-down{animation-name:in-down}.calcite-animate__in-up{animation-name:in-up}.calcite-animate__in-scale{animation-name:in-scale}@media (prefers-reduced-motion: reduce){:root{--calcite-internal-duration-factor:0.01}}:host{box-sizing:border-box;background-color:var(--calcite-ui-foreground-1);color:var(--calcite-ui-text-2);font-size:var(--calcite-font-size--1)}:host *{box-sizing:border-box}:root{--calcite-floating-ui-transition:var(--calcite-animation-timing);--calcite-floating-ui-z-index:600}:host([hidden]){display:none}:host([disabled]){pointer-events:none;cursor:default;-webkit-user-select:none;user-select:none;opacity:var(--calcite-ui-opacity-disabled)}:host{position:relative;display:flex;block-size:100%;inline-size:100%;flex:1 1 auto;overflow:hidden;--calcite-min-header-height:calc(var(--calcite-icon-size) * 3)}:host([disabled]) ::slotted([calcite-hydrated][disabled]),:host([disabled]) [calcite-hydrated][disabled]{opacity:1}.header{margin:0px;display:flex;align-content:space-between;align-items:center;fill:var(--calcite-ui-text-2);color:var(--calcite-ui-text-2)}.heading{margin:0px;padding:0px;font-weight:var(--calcite-font-weight-medium)}.header .heading{flex:1 1 auto;padding:0.5rem}.container{margin:0px;display:flex;inline-size:100%;flex:1 1 auto;flex-direction:column;align-items:stretch;background-color:var(--calcite-ui-background);padding:0px;transition:max-block-size var(--calcite-animation-timing), inline-size var(--calcite-animation-timing)}.container[hidden]{display:none}.header{border-block-end:1px solid;position:sticky;inset-block-start:0px;z-index:400;inline-size:100%;align-items:stretch;justify-content:flex-start;background-color:var(--calcite-ui-foreground-1);border-block-end-color:var(--calcite-ui-border-3);flex:0 0 auto}.header-content{display:flex;flex-direction:column;overflow:hidden;padding-inline:0.75rem;padding-block:0.875rem;margin-inline-end:auto}.header-content .heading,.header-content .description{display:block;overflow-wrap:break-word;padding:0px}.header-content .heading{margin-inline:0px;margin-block:0px 0.25rem;font-size:var(--calcite-font-size-0);line-height:1.25rem;font-weight:var(--calcite-font-weight-medium)}.header-content .heading:only-child{margin-block-end:0px}.header-content .description{font-size:var(--calcite-font-size--1);line-height:1rem;color:var(--calcite-ui-text-2)}.back-button{border-width:0px;border-style:solid;border-color:var(--calcite-ui-border-3);border-inline-end-width:1px}.header-actions{display:flex;flex-direction:row;flex-wrap:nowrap;align-items:stretch}.header-actions--end{margin-inline-start:auto}.content-wrapper{overflow:auto}.content-height{block-size:100%}.content-container{display:flex;flex:1 1 auto;flex-direction:column;flex-wrap:nowrap;align-items:stretch;background-color:var(--calcite-ui-background)}.footer{border-block-start:1px solid;position:sticky;inset-block-end:0px;display:flex;inline-size:100%;justify-content:space-evenly;background-color:var(--calcite-ui-foreground-1);border-block-start-color:var(--calcite-ui-border-3);flex:0 0 auto;min-block-size:3rem;padding:0.5rem}.fab-container{position:sticky;inset-block-end:0px;z-index:300;margin-block:0px;margin-inline:auto;display:block;padding:0.5rem;inset-inline:0;inline-size:-moz-fit-content;inline-size:fit-content}[hidden]{display:none}";export{z as calcite_panel}
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
/*!
|
|
2
|
+
* All material copyright ESRI, All Rights Reserved, unless otherwise specified.
|
|
3
|
+
* See https://github.com/Esri/calcite-components/blob/master/LICENSE.md for details.
|
|
4
|
+
* v1.1.1-next.1
|
|
5
|
+
*/
|
|
6
|
+
import{r as t,c as e,h as i,g as n}from"./p-983244bc.js";import{i as a,b as s,f as r,e as o}from"./p-cff554c3.js";import{n as l,C as c,p as h,c as u,i as d,a as m,r as f,b as p}from"./p-e2ca6e76.js";import{u as g}from"./p-9f094be8.js";import{i as b}from"./p-83b37109.js";import{c as y,s as v,a as w}from"./p-0e573040.js";import{c as k,d as x}from"./p-d70da26b.js";import{c as M}from"./p-32e6bbaa.js";import{u as C,s as j,c as z,d as D}from"./p-2c2c6832.js";import{d as F,i as A}from"./p-53f86dbe.js";import"./p-1e3ad5b6.js";import"./p-ebd84c48.js";import"./p-53515d24.js";function S(t,e,i){return t(i={path:e,exports:{},require:function(){return function(){throw new Error("Dynamic requires are not currently supported by @rollup/plugin-commonjs")}()}},i.exports),i.exports}var _={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]},O=S((function(t){var e=Array.prototype.concat,i=Array.prototype.slice,n=t.exports=function(t){for(var n,a=[],s=0,r=t.length;s<r;s++){var o=t[s];(n=o)&&"string"!=typeof n&&(n instanceof Array||Array.isArray(n)||n.length>=0&&(n.splice instanceof Function||Object.getOwnPropertyDescriptor(n,n.length-1)&&"String"!==n.constructor.name))?a=e.call(a,i.call(o)):a.push(o)}return a};n.wrap=function(t){return function(){return t(n(arguments))}}})),$=S((function(t){var e=Object.hasOwnProperty,i={};for(var n in _)e.call(_,n)&&(i[_[n]]=n);var a=t.exports={to:{},get:{}};function s(t,e,i){return Math.min(Math.max(e,t),i)}function r(t){var e=Math.round(t).toString(16).toUpperCase();return e.length<2?"0"+e:e}a.get=function(t){var e,i;switch(t.substring(0,3).toLowerCase()){case"hsl":e=a.get.hsl(t),i="hsl";break;case"hwb":e=a.get.hwb(t),i="hwb";break;default:e=a.get.rgb(t),i="rgb"}return e?{model:i,value:e}:null},a.get.rgb=function(t){if(!t)return null;var i,n,a,r=[0,0,0,1];if(i=t.match(/^#([a-f0-9]{6})([a-f0-9]{2})?$/i)){for(a=i[2],i=i[1],n=0;n<3;n++){var o=2*n;r[n]=parseInt(i.slice(o,o+2),16)}a&&(r[3]=parseInt(a,16)/255)}else if(i=t.match(/^#([a-f0-9]{3,4})$/i)){for(a=(i=i[1])[3],n=0;n<3;n++)r[n]=parseInt(i[n]+i[n],16);a&&(r[3]=parseInt(a+a,16)/255)}else if(i=t.match(/^rgba?\(\s*([+-]?\d+)(?=[\s,])\s*(?:,\s*)?([+-]?\d+)(?=[\s,])\s*(?:,\s*)?([+-]?\d+)\s*(?:[,|\/]\s*([+-]?[\d\.]+)(%?)\s*)?\)$/)){for(n=0;n<3;n++)r[n]=parseInt(i[n+1],0);i[4]&&(r[3]=i[5]?.01*parseFloat(i[4]):parseFloat(i[4]))}else{if(!(i=t.match(/^rgba?\(\s*([+-]?[\d\.]+)\%\s*,?\s*([+-]?[\d\.]+)\%\s*,?\s*([+-]?[\d\.]+)\%\s*(?:[,|\/]\s*([+-]?[\d\.]+)(%?)\s*)?\)$/)))return(i=t.match(/^(\w+)$/))?"transparent"===i[1]?[0,0,0,0]:e.call(_,i[1])?((r=_[i[1]])[3]=1,r):null:null;for(n=0;n<3;n++)r[n]=Math.round(2.55*parseFloat(i[n+1]));i[4]&&(r[3]=i[5]?.01*parseFloat(i[4]):parseFloat(i[4]))}for(n=0;n<3;n++)r[n]=s(r[n],0,255);return r[3]=s(r[3],0,1),r},a.get.hsl=function(t){if(!t)return null;var e=t.match(/^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*)?\)$/);if(e){var i=parseFloat(e[4]);return[(parseFloat(e[1])%360+360)%360,s(parseFloat(e[2]),0,100),s(parseFloat(e[3]),0,100),s(isNaN(i)?1:i,0,1)]}return null},a.get.hwb=function(t){if(!t)return null;var e=t.match(/^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*)?\)$/);if(e){var i=parseFloat(e[4]);return[(parseFloat(e[1])%360+360)%360,s(parseFloat(e[2]),0,100),s(parseFloat(e[3]),0,100),s(isNaN(i)?1:i,0,1)]}return null},a.to.hex=function(){var t=O(arguments);return"#"+r(t[0])+r(t[1])+r(t[2])+(t[3]<1?r(Math.round(255*t[3])):"")},a.to.rgb=function(){var t=O(arguments);return t.length<4||1===t[3]?"rgb("+Math.round(t[0])+", "+Math.round(t[1])+", "+Math.round(t[2])+")":"rgba("+Math.round(t[0])+", "+Math.round(t[1])+", "+Math.round(t[2])+", "+t[3]+")"},a.to.rgb.percent=function(){var t=O(arguments),e=Math.round(t[0]/255*100),i=Math.round(t[1]/255*100),n=Math.round(t[2]/255*100);return t.length<4||1===t[3]?"rgb("+e+"%, "+i+"%, "+n+"%)":"rgba("+e+"%, "+i+"%, "+n+"%, "+t[3]+")"},a.to.hsl=function(){var t=O(arguments);return t.length<4||1===t[3]?"hsl("+t[0]+", "+t[1]+"%, "+t[2]+"%)":"hsla("+t[0]+", "+t[1]+"%, "+t[2]+"%, "+t[3]+")"},a.to.hwb=function(){var t=O(arguments),e="";return t.length>=4&&1!==t[3]&&(e=", "+t[3]),"hwb("+t[0]+", "+t[1]+"%, "+t[2]+"%"+e+")"},a.to.keyword=function(t){return i[t.slice(0,3)]}})),q={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]};const I={};for(const t of Object.keys(q))I[q[t]]=t;const E={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 L=E;for(const t of Object.keys(E)){if(!("channels"in E[t]))throw new Error("missing channels property: "+t);if(!("labels"in E[t]))throw new Error("missing channel labels property: "+t);if(E[t].labels.length!==E[t].channels)throw new Error("channel and label counts mismatch: "+t);const{channels:e,labels:i}=E[t];delete E[t].channels,delete E[t].labels,Object.defineProperty(E[t],"channels",{value:e}),Object.defineProperty(E[t],"labels",{value:i})}function N(t,e){return function(i){return e(t(i))}}function K(t,e){const i=[e[t].parent,t];let n=L[e[t].parent][t],a=e[t].parent;for(;e[a].parent;)i.unshift(e[a].parent),n=N(L[e[a].parent][a],n),a=e[a].parent;return n.conversion=i,n}E.rgb.hsl=function(t){const e=t[0]/255,i=t[1]/255,n=t[2]/255,a=Math.min(e,i,n),s=Math.max(e,i,n),r=s-a;let o,l;s===a?o=0:e===s?o=(i-n)/r:i===s?o=2+(n-e)/r:n===s&&(o=4+(e-i)/r),o=Math.min(60*o,360),o<0&&(o+=360);const c=(a+s)/2;return l=s===a?0:c<=.5?r/(s+a):r/(2-s-a),[o,100*l,100*c]},E.rgb.hsv=function(t){let e,i,n,a,s;const r=t[0]/255,o=t[1]/255,l=t[2]/255,c=Math.max(r,o,l),h=c-Math.min(r,o,l),u=function(t){return(c-t)/6/h+.5};return 0===h?(a=0,s=0):(s=h/c,e=u(r),i=u(o),n=u(l),r===c?a=n-i:o===c?a=1/3+e-n:l===c&&(a=2/3+i-e),a<0?a+=1:a>1&&(a-=1)),[360*a,100*s,100*c]},E.rgb.hwb=function(t){const e=t[0],i=t[1];let n=t[2];const a=E.rgb.hsl(t)[0],s=1/255*Math.min(e,Math.min(i,n));return n=1-1/255*Math.max(e,Math.max(i,n)),[a,100*s,100*n]},E.rgb.cmyk=function(t){const e=t[0]/255,i=t[1]/255,n=t[2]/255,a=Math.min(1-e,1-i,1-n);return[100*((1-e-a)/(1-a)||0),100*((1-i-a)/(1-a)||0),100*((1-n-a)/(1-a)||0),100*a]},E.rgb.keyword=function(t){const e=I[t];if(e)return e;let i,n=1/0;for(const e of Object.keys(q)){const r=((a=t)[0]-(s=q[e])[0])**2+(a[1]-s[1])**2+(a[2]-s[2])**2;r<n&&(n=r,i=e)}var a,s;return i},E.keyword.rgb=function(t){return q[t]},E.rgb.xyz=function(t){let e=t[0]/255,i=t[1]/255,n=t[2]/255;return e=e>.04045?((e+.055)/1.055)**2.4:e/12.92,i=i>.04045?((i+.055)/1.055)**2.4:i/12.92,n=n>.04045?((n+.055)/1.055)**2.4:n/12.92,[100*(.4124*e+.3576*i+.1805*n),100*(.2126*e+.7152*i+.0722*n),100*(.0193*e+.1192*i+.9505*n)]},E.rgb.lab=function(t){const e=E.rgb.xyz(t);let i=e[0],n=e[1],a=e[2];return i/=95.047,n/=100,a/=108.883,i=i>.008856?i**(1/3):7.787*i+16/116,n=n>.008856?n**(1/3):7.787*n+16/116,a=a>.008856?a**(1/3):7.787*a+16/116,[116*n-16,500*(i-n),200*(n-a)]},E.hsl.rgb=function(t){const e=t[0]/360,i=t[1]/100,n=t[2]/100;let a,s,r;if(0===i)return r=255*n,[r,r,r];a=n<.5?n*(1+i):n+i-n*i;const o=2*n-a,l=[0,0,0];for(let t=0;t<3;t++)s=e+1/3*-(t-1),s<0&&s++,s>1&&s--,r=6*s<1?o+6*(a-o)*s:2*s<1?a:3*s<2?o+(a-o)*(2/3-s)*6:o,l[t]=255*r;return l},E.hsl.hsv=function(t){const e=t[0];let i=t[1]/100,n=t[2]/100,a=i;const s=Math.max(n,.01);return n*=2,i*=n<=1?n:2-n,a*=s<=1?s:2-s,[e,100*(0===n?2*a/(s+a):2*i/(n+i)),(n+i)/2*100]},E.hsv.rgb=function(t){const e=t[0]/60,i=t[1]/100;let n=t[2]/100;const a=Math.floor(e)%6,s=e-Math.floor(e),r=255*n*(1-i),o=255*n*(1-i*s),l=255*n*(1-i*(1-s));switch(n*=255,a){case 0:return[n,l,r];case 1:return[o,n,r];case 2:return[r,n,l];case 3:return[r,o,n];case 4:return[l,r,n];case 5:return[n,r,o]}},E.hsv.hsl=function(t){const e=t[0],i=t[1]/100,n=t[2]/100,a=Math.max(n,.01);let s,r;r=(2-i)*n;const o=(2-i)*a;return s=i*a,s/=o<=1?o:2-o,s=s||0,r/=2,[e,100*s,100*r]},E.hwb.rgb=function(t){const e=t[0]/360;let i=t[1]/100,n=t[2]/100;const a=i+n;let s;a>1&&(i/=a,n/=a);const r=Math.floor(6*e),o=1-n;s=6*e-r,0!=(1&r)&&(s=1-s);const l=i+s*(o-i);let c,h,u;switch(r){default:case 6:case 0:c=o,h=l,u=i;break;case 1:c=l,h=o,u=i;break;case 2:c=i,h=o,u=l;break;case 3:c=i,h=l,u=o;break;case 4:c=l,h=i,u=o;break;case 5:c=o,h=i,u=l}return[255*c,255*h,255*u]},E.cmyk.rgb=function(t){const e=t[1]/100,i=t[2]/100,n=t[3]/100;return[255*(1-Math.min(1,t[0]/100*(1-n)+n)),255*(1-Math.min(1,e*(1-n)+n)),255*(1-Math.min(1,i*(1-n)+n))]},E.xyz.rgb=function(t){const e=t[0]/100,i=t[1]/100,n=t[2]/100;let a,s,r;return a=3.2406*e+-1.5372*i+-.4986*n,s=-.9689*e+1.8758*i+.0415*n,r=.0557*e+-.204*i+1.057*n,a=a>.0031308?1.055*a**(1/2.4)-.055:12.92*a,s=s>.0031308?1.055*s**(1/2.4)-.055:12.92*s,r=r>.0031308?1.055*r**(1/2.4)-.055:12.92*r,a=Math.min(Math.max(0,a),1),s=Math.min(Math.max(0,s),1),r=Math.min(Math.max(0,r),1),[255*a,255*s,255*r]},E.xyz.lab=function(t){let e=t[0],i=t[1],n=t[2];return e/=95.047,i/=100,n/=108.883,e=e>.008856?e**(1/3):7.787*e+16/116,i=i>.008856?i**(1/3):7.787*i+16/116,n=n>.008856?n**(1/3):7.787*n+16/116,[116*i-16,500*(e-i),200*(i-n)]},E.lab.xyz=function(t){let e,i,n;i=(t[0]+16)/116,e=t[1]/500+i,n=i-t[2]/200;const a=i**3,s=e**3,r=n**3;return i=a>.008856?a:(i-16/116)/7.787,e=s>.008856?s:(e-16/116)/7.787,n=r>.008856?r:(n-16/116)/7.787,e*=95.047,i*=100,n*=108.883,[e,i,n]},E.lab.lch=function(t){const e=t[0],i=t[1],n=t[2];let a;return a=360*Math.atan2(n,i)/2/Math.PI,a<0&&(a+=360),[e,Math.sqrt(i*i+n*n),a]},E.lch.lab=function(t){const e=t[1],i=t[2]/360*2*Math.PI;return[t[0],e*Math.cos(i),e*Math.sin(i)]},E.rgb.ansi16=function(t,e=null){const[i,n,a]=t;let s=null===e?E.rgb.hsv(t)[2]:e;if(s=Math.round(s/50),0===s)return 30;let r=30+(Math.round(a/255)<<2|Math.round(n/255)<<1|Math.round(i/255));return 2===s&&(r+=60),r},E.hsv.ansi16=function(t){return E.rgb.ansi16(E.hsv.rgb(t),t[2])},E.rgb.ansi256=function(t){const e=t[0],i=t[1],n=t[2];return e===i&&i===n?e<8?16:e>248?231:Math.round((e-8)/247*24)+232:16+36*Math.round(e/255*5)+6*Math.round(i/255*5)+Math.round(n/255*5)},E.ansi16.rgb=function(t){let e=t%10;if(0===e||7===e)return t>50&&(e+=3.5),e=e/10.5*255,[e,e,e];const i=.5*(1+~~(t>50));return[(1&e)*i*255,(e>>1&1)*i*255,(e>>2&1)*i*255]},E.ansi256.rgb=function(t){if(t>=232){const e=10*(t-232)+8;return[e,e,e]}let e;return t-=16,[Math.floor(t/36)/5*255,Math.floor((e=t%36)/6)/5*255,e%6/5*255]},E.rgb.hex=function(t){const e=(((255&Math.round(t[0]))<<16)+((255&Math.round(t[1]))<<8)+(255&Math.round(t[2]))).toString(16).toUpperCase();return"000000".substring(e.length)+e},E.hex.rgb=function(t){const e=t.toString(16).match(/[a-f0-9]{6}|[a-f0-9]{3}/i);if(!e)return[0,0,0];let i=e[0];3===e[0].length&&(i=i.split("").map((t=>t+t)).join(""));const n=parseInt(i,16);return[n>>16&255,n>>8&255,255&n]},E.rgb.hcg=function(t){const e=t[0]/255,i=t[1]/255,n=t[2]/255,a=Math.max(Math.max(e,i),n),s=Math.min(Math.min(e,i),n),r=a-s;let o,l;return o=r<1?s/(1-r):0,l=r<=0?0:a===e?(i-n)/r%6:a===i?2+(n-e)/r:4+(e-i)/r,l/=6,l%=1,[360*l,100*r,100*o]},E.hsl.hcg=function(t){const e=t[1]/100,i=t[2]/100,n=i<.5?2*e*i:2*e*(1-i);let a=0;return n<1&&(a=(i-.5*n)/(1-n)),[t[0],100*n,100*a]},E.hsv.hcg=function(t){const e=t[2]/100,i=t[1]/100*e;let n=0;return i<1&&(n=(e-i)/(1-i)),[t[0],100*i,100*n]},E.hcg.rgb=function(t){const e=t[1]/100,i=t[2]/100;if(0===e)return[255*i,255*i,255*i];const n=[0,0,0],a=t[0]/360%1*6,s=a%1,r=1-s;let o=0;switch(Math.floor(a)){case 0:n[0]=1,n[1]=s,n[2]=0;break;case 1:n[0]=r,n[1]=1,n[2]=0;break;case 2:n[0]=0,n[1]=1,n[2]=s;break;case 3:n[0]=0,n[1]=r,n[2]=1;break;case 4:n[0]=s,n[1]=0,n[2]=1;break;default:n[0]=1,n[1]=0,n[2]=r}return o=(1-e)*i,[255*(e*n[0]+o),255*(e*n[1]+o),255*(e*n[2]+o)]},E.hcg.hsv=function(t){const e=t[1]/100,i=e+t[2]/100*(1-e);let n=0;return i>0&&(n=e/i),[t[0],100*n,100*i]},E.hcg.hsl=function(t){const e=t[1]/100,i=t[2]/100*(1-e)+.5*e;let n=0;return i>0&&i<.5?n=e/(2*i):i>=.5&&i<1&&(n=e/(2*(1-i))),[t[0],100*n,100*i]},E.hcg.hwb=function(t){const e=t[1]/100,i=e+t[2]/100*(1-e);return[t[0],100*(i-e),100*(1-i)]},E.hwb.hcg=function(t){const e=1-t[2]/100,i=e-t[1]/100;let n=0;return i<1&&(n=(e-i)/(1-i)),[t[0],100*i,100*n]},E.apple.rgb=function(t){return[t[0]/65535*255,t[1]/65535*255,t[2]/65535*255]},E.rgb.apple=function(t){return[t[0]/255*65535,t[1]/255*65535,t[2]/255*65535]},E.gray.rgb=function(t){return[t[0]/100*255,t[0]/100*255,t[0]/100*255]},E.gray.hsl=function(t){return[0,0,t[0]]},E.gray.hsv=E.gray.hsl,E.gray.hwb=function(t){return[0,100,t[0]]},E.gray.cmyk=function(t){return[0,0,0,t[0]]},E.gray.lab=function(t){return[t[0],0,0]},E.gray.hex=function(t){const e=255&Math.round(t[0]/100*255),i=((e<<16)+(e<<8)+e).toString(16).toUpperCase();return"000000".substring(i.length)+i},E.rgb.gray=function(t){return[(t[0]+t[1]+t[2])/3/255*100]};const P={};Object.keys(L).forEach((t=>{P[t]={},Object.defineProperty(P[t],"channels",{value:L[t].channels}),Object.defineProperty(P[t],"labels",{value:L[t].labels});const e=function(t){const e=function(t){const e=function(){const t={},e=Object.keys(L);for(let i=e.length,n=0;n<i;n++)t[e[n]]={distance:-1,parent:null};return t}(),i=[t];for(e[t].distance=0;i.length;){const t=i.pop(),n=Object.keys(L[t]);for(let a=n.length,s=0;s<a;s++){const a=n[s],r=e[a];-1===r.distance&&(r.distance=e[t].distance+1,r.parent=t,i.unshift(a))}}return e}(t),i={},n=Object.keys(e);for(let t=n.length,a=0;a<t;a++){const t=n[a];null!==e[t].parent&&(i[t]=K(t,e))}return i}(t);Object.keys(e).forEach((i=>{const n=e[i];P[t][i]=function(t){const e=function(...e){const i=e[0];if(null==i)return i;i.length>1&&(e=i);const n=t(e);if("object"==typeof n)for(let t=n.length,e=0;e<t;e++)n[e]=Math.round(n[e]);return n};return"conversion"in t&&(e.conversion=t.conversion),e}(n),P[t][i].raw=function(t){const e=function(...e){const i=e[0];return null==i?i:(i.length>1&&(e=i),t(e))};return"conversion"in t&&(e.conversion=t.conversion),e}(n)}))}));var U=P;const T=["keyword","gray","hex"],H={};for(const t of Object.keys(U))H[[...U[t].labels].sort().join("")]=t;const V={};function J(t,e){if(!(this instanceof J))return new J(t,e);if(e&&e in T&&(e=null),e&&!(e in U))throw new Error("Unknown model: "+e);let i,n;if(null==t)this.model="rgb",this.color=[0,0,0],this.valpha=1;else if(t instanceof J)this.model=t.model,this.color=[...t.color],this.valpha=t.valpha;else if("string"==typeof t){const e=$.get(t);if(null===e)throw new Error("Unable to parse color from string: "+t);this.model=e.model,n=U[this.model].channels,this.color=e.value.slice(0,n),this.valpha="number"==typeof e.value[n]?e.value[n]:1}else if(t.length>0){this.model=e||"rgb",n=U[this.model].channels;const i=Array.prototype.slice.call(t,0,n);this.color=X(i,n),this.valpha="number"==typeof t[n]?t[n]:1}else if("number"==typeof t)this.model="rgb",this.color=[t>>16&255,t>>8&255,255&t],this.valpha=1;else{this.valpha=1;const e=Object.keys(t);"alpha"in t&&(e.splice(e.indexOf("alpha"),1),this.valpha="number"==typeof t.alpha?t.alpha:0);const n=e.sort().join("");if(!(n in H))throw new Error("Unable to parse color from object: "+JSON.stringify(t));this.model=H[n];const{labels:a}=U[this.model],s=[];for(i=0;i<a.length;i++)s.push(t[a[i]]);this.color=X(s)}if(V[this.model])for(n=U[this.model].channels,i=0;i<n;i++){const t=V[this.model][i];t&&(this.color[i]=t(this.color[i]))}this.valpha=Math.max(0,Math.min(1,this.valpha)),Object.freeze&&Object.freeze(this)}J.prototype={toString(){return this.string()},toJSON(){return this[this.model]()},string(t){let e=this.model in $.to?this:this.rgb();e=e.round("number"==typeof t?t:1);const i=1===e.valpha?e.color:[...e.color,this.valpha];return $.to[e.model](i)},percentString(t){const e=this.rgb().round("number"==typeof t?t:1),i=1===e.valpha?e.color:[...e.color,this.valpha];return $.to.rgb.percent(i)},array(){return 1===this.valpha?[...this.color]:[...this.color,this.valpha]},object(){const t={},{channels:e}=U[this.model],{labels:i}=U[this.model];for(let n=0;n<e;n++)t[i[n]]=this.color[n];return 1!==this.valpha&&(t.alpha=this.valpha),t},unitArray(){const t=this.rgb().color;return t[0]/=255,t[1]/=255,t[2]/=255,1!==this.valpha&&t.push(this.valpha),t},unitObject(){const t=this.rgb().object();return t.r/=255,t.g/=255,t.b/=255,1!==this.valpha&&(t.alpha=this.valpha),t},round(t){return t=Math.max(t||0,0),new J([...this.color.map(R(t)),this.valpha],this.model)},alpha(t){return void 0!==t?new J([...this.color,Math.max(0,Math.min(1,t))],this.model):this.valpha},red:W("rgb",0,B(255)),green:W("rgb",1,B(255)),blue:W("rgb",2,B(255)),hue:W(["hsl","hsv","hsl","hwb","hcg"],0,(t=>(t%360+360)%360)),saturationl:W("hsl",1,B(100)),lightness:W("hsl",2,B(100)),saturationv:W("hsv",1,B(100)),value:W("hsv",2,B(100)),chroma:W("hcg",1,B(100)),gray:W("hcg",2,B(100)),white:W("hwb",1,B(100)),wblack:W("hwb",2,B(100)),cyan:W("cmyk",0,B(100)),magenta:W("cmyk",1,B(100)),yellow:W("cmyk",2,B(100)),black:W("cmyk",3,B(100)),x:W("xyz",0,B(95.047)),y:W("xyz",1,B(100)),z:W("xyz",2,B(108.833)),l:W("lab",0,B(100)),a:W("lab",1),b:W("lab",2),keyword(t){return void 0!==t?new J(t):U[this.model].keyword(this.color)},hex(t){return void 0!==t?new J(t):$.to.hex(this.rgb().round().color)},hexa(t){if(void 0!==t)return new J(t);const e=this.rgb().round().color;let i=Math.round(255*this.valpha).toString(16).toUpperCase();return 1===i.length&&(i="0"+i),$.to.hex(e)+i},rgbNumber(){const t=this.rgb().color;return(255&t[0])<<16|(255&t[1])<<8|255&t[2]},luminosity(){const t=this.rgb().color,e=[];for(const[i,n]of t.entries()){const t=n/255;e[i]=t<=.04045?t/12.92:((t+.055)/1.055)**2.4}return.2126*e[0]+.7152*e[1]+.0722*e[2]},contrast(t){const e=this.luminosity(),i=t.luminosity();return e>i?(e+.05)/(i+.05):(i+.05)/(e+.05)},level(t){const e=this.contrast(t);return e>=7?"AAA":e>=4.5?"AA":""},isDark(){const t=this.rgb().color;return(2126*t[0]+7152*t[1]+722*t[2])/1e4<128},isLight(){return!this.isDark()},negate(){const t=this.rgb();for(let e=0;e<3;e++)t.color[e]=255-t.color[e];return t},lighten(t){const e=this.hsl();return e.color[2]+=e.color[2]*t,e},darken(t){const e=this.hsl();return e.color[2]-=e.color[2]*t,e},saturate(t){const e=this.hsl();return e.color[1]+=e.color[1]*t,e},desaturate(t){const e=this.hsl();return e.color[1]-=e.color[1]*t,e},whiten(t){const e=this.hwb();return e.color[1]+=e.color[1]*t,e},blacken(t){const e=this.hwb();return e.color[2]+=e.color[2]*t,e},grayscale(){const t=this.rgb().color,e=.3*t[0]+.59*t[1]+.11*t[2];return J.rgb(e,e,e)},fade(t){return this.alpha(this.valpha-this.valpha*t)},opaquer(t){return this.alpha(this.valpha+this.valpha*t)},rotate(t){const e=this.hsl();let i=e.color[0];return i=(i+t)%360,i=i<0?360+i:i,e.color[0]=i,e},mix(t,e){if(!t||!t.rgb)throw new Error('Argument to "mix" was not a Color instance, but rather an instance of '+typeof t);const i=t.rgb(),n=this.rgb(),a=void 0===e?.5:e,s=2*a-1,r=i.alpha()-n.alpha(),o=((s*r==-1?s:(s+r)/(1+s*r))+1)/2,l=1-o;return J.rgb(o*i.red()+l*n.red(),o*i.green()+l*n.green(),o*i.blue()+l*n.blue(),i.alpha()*a+n.alpha()*(1-a))}};for(const t of Object.keys(U)){if(T.includes(t))continue;const{channels:e}=U[t];J.prototype[t]=function(...e){return this.model===t?new J(this):new J(e.length>0?e:[...(i=U[this.model][t].raw(this.color),Array.isArray(i)?i:[i]),this.valpha],t);var i},J[t]=function(...i){let n=i[0];return"number"==typeof n&&(n=X(i,e)),new J(n,t)}}function R(t){return function(e){return function(t,e){return Number(t.toFixed(e))}(e,t)}}function W(t,e,i){t=Array.isArray(t)?t:[t];for(const n of t)(V[n]||(V[n]=[]))[e]=i;return t=t[0],function(n){let a;return void 0!==n?(i&&(n=i(n)),a=this[t](),a.color[e]=n,a):(a=this[t]().color[e],i&&(a=i(a)),a)}}function B(t){return function(e){return Math.max(0,Math.min(t,e))}}function X(t,e){for(let i=0;i<e;i++)"number"!=typeof t[i]&&(t[i]=0);return t}var Y=J;const G="section",Q="header",Z="control",tt="channel",et="scope",it=Y("#007AC2"),nt="calcite-color-",at={r:255,g:255,b:255},st={h:360,s:100,v:100},rt={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}}},ot=l(it.hex()),lt=class{constructor(n){var r,o,h,u;t(this,n),this.calciteColorPickerChange=e(this,"calciteColorPickerChange",6),this.calciteColorPickerInput=e(this,"calciteColorPickerInput",6),this.colorFieldAndSliderHovered=!1,this.hueThumbState="idle",this.internalColorUpdateContext=null,this.mode=c.HEX,this.shiftKeyChannelAdjustment=0,this.sliderThumbState="idle",this.handleTabActivate=t=>{this.channelMode=t.currentTarget.getAttribute("data-color-mode"),this.updateChannelsFromColor(this.color)},this.handleColorFieldScopeKeyDown=t=>{const{key:e}=t,i={ArrowUp:{x:0,y:-10},ArrowRight:{x:10,y:0},ArrowDown:{x:0,y:10},ArrowLeft:{x:-10,y:0}};i[e]&&(t.preventDefault(),this.scopeOrientation="ArrowDown"===e||"ArrowUp"===e?"vertical":"horizontal",this.captureColorFieldColor(this.colorFieldScopeLeft+i[e].x||0,this.colorFieldScopeTop+i[e].y||0,!1))},this.handleHueScopeKeyDown=t=>{const e=t.shiftKey?10:1,{key:i}=t,n={ArrowUp:1,ArrowRight:1,ArrowDown:-1,ArrowLeft:-1};if(n[i]){t.preventDefault();const a=n[i]*e,s=this.baseColorFieldColor.hue(),r=this.baseColorFieldColor.hue(s+a);this.internalColorSet(r,!1)}},this.handleHexInputChange=t=>{t.stopPropagation();const{allowEmpty:e,color:i}=this,n=t.target.value;!e||n?n!==(i&&l(i.hex()))&&this.internalColorSet(Y(n)):this.internalColorSet(null)},this.handleSavedColorSelect=t=>{this.internalColorSet(Y(t.currentTarget.color))},this.handleChannelInput=t=>{const e=t.currentTarget,i=Number(e.getAttribute("data-channel-index")),n="rgb"===this.channelMode?at[Object.keys(at)[i]]:st[Object.keys(st)[i]];let a;if(this.allowEmpty&&!e.value)a="";else{const t=Number(e.value)+this.shiftKeyChannelAdjustment;a=M(t,0,n).toString()}e.value=a,e.internalSyncChildElValue()},this.handleChannelChange=t=>{const e=t.currentTarget,i=Number(e.getAttribute("data-channel-index")),n=[...this.channels];if(this.allowEmpty&&!e.value)return this.channels=[null,null,null],void this.internalColorSet(null);n[i]=Number(e.value),this.updateColorFromChannels(n)},this.handleSavedColorKeyDown=t=>{b(t.key)&&(t.preventDefault(),this.handleSavedColorSelect(t))},this.handleColorFieldAndSliderPointerLeave=()=>{this.colorFieldAndSliderInteractive=!1,this.colorFieldAndSliderHovered=!1,"drag"!==this.sliderThumbState&&"drag"!==this.hueThumbState&&(this.hueThumbState="idle",this.sliderThumbState="idle",this.drawColorFieldAndSlider())},this.handleColorFieldAndSliderPointerDown=t=>{if(!a(t))return;const{offsetX:e,offsetY:i}=t,n=this.getCanvasRegion(i);"color-field"===n?(this.hueThumbState="drag",this.captureColorFieldColor(e,i),this.colorFieldScopeNode?.focus()):"slider"===n&&(this.sliderThumbState="drag",this.captureHueSliderColor(e),this.hueScopeNode?.focus()),t.preventDefault(),document.addEventListener("pointermove",this.globalPointerMoveHandler),document.addEventListener("pointerup",this.globalPointerUpHandler,{once:!0}),this.activeColorFieldAndSliderRect=this.fieldAndSliderRenderingContext.canvas.getBoundingClientRect()},this.globalPointerUpHandler=t=>{if(!a(t))return;const e="drag"===this.sliderThumbState||"drag"===this.hueThumbState;this.hueThumbState="idle",this.sliderThumbState="idle",this.activeColorFieldAndSliderRect=null,this.drawColorFieldAndSlider(),e&&this.calciteColorPickerChange.emit()},this.globalPointerMoveHandler=t=>{const{el:e,dimensions:i}=this,n="drag"===this.hueThumbState;if(!e.isConnected||"drag"!==this.sliderThumbState&&!n)return;let a,s;const r=this.activeColorFieldAndSliderRect,{clientX:o,clientY:l}=t;if(this.colorFieldAndSliderHovered)a=o-r.x,s=l-r.y;else{const t=i.colorField.width,e=i.colorField.height,n=i.slider.height;a=o<r.x+t&&o>r.x?o-r.x:o<r.x?0:t-1,s=l<r.y+e+n&&l>r.y?l-r.y:l<r.y?0:e+n}n?this.captureColorFieldColor(a,s,!1):this.captureHueSliderColor(a)},this.handleColorFieldAndSliderPointerEnterOrMove=({offsetX:t,offsetY:e})=>{const{dimensions:{colorField:i,slider:n,thumb:a}}=this;this.colorFieldAndSliderInteractive=e<=i.height+n.height,this.colorFieldAndSliderHovered=!0;const s=this.getCanvasRegion(e);if("color-field"===s){const n=this.hueThumbState,s=this.baseColorFieldColor.hsv(),r=Math.round(s.saturationv()/(st.s/i.width)),o=Math.round(i.height-s.value()/(st.v/i.height)),l=this.containsPoint(t,e,r,o,a.radius);let c=!1;"idle"===n&&l?(this.hueThumbState="hover",c=!0):"hover"!==n||l||(this.hueThumbState="idle",c=!0),"drag"!==this.hueThumbState&&c&&this.drawColorFieldAndSlider()}else if("slider"===s){const s=this.baseColorFieldColor.hsv().saturationv(100).value(100),r=this.sliderThumbState,o=Math.round(s.hue()/(360/n.width)),l=Math.round((n.height+this.getSliderCapSpacing())/2)+i.height,c=this.containsPoint(t,e,o,l,a.radius);let h=!1;"idle"===r&&c?(this.sliderThumbState="hover",h=!0):"hover"!==r||c||(this.sliderThumbState="idle",h=!0),"drag"!==this.sliderThumbState&&h&&this.drawColorFieldAndSlider()}},this.storeColorFieldScope=t=>{this.colorFieldScopeNode=t},this.storeHueScope=t=>{this.hueScopeNode=t},this.renderChannelsTabTitle=t=>{const{channelMode:e,messages:n}=this;return i("calcite-tab-title",{class:"color-mode","data-color-mode":t,key:t,onCalciteTabsActivate:this.handleTabActivate,selected:t===e},"rgb"===t?n.rgb:n.hsv)},this.renderChannelsTab=t=>{const{channelMode:e,channels:n,messages:a}=this,r=t===e,o="rgb"===t,l=o?[a.r,a.g,a.b]:[a.h,a.s,a.v],c=o?[a.red,a.green,a.blue]:[a.hue,a.saturation,a.value],h=s(this.el);return i("calcite-tab",{class:Z,key:t,selected:r},i("div",{class:"channels",dir:"ltr"},n.map(((t,e)=>this.renderChannel(t,e,l[e],c[e],h)))))},this.renderChannel=(t,e,n,a,s)=>i("calcite-input",{class:tt,"data-channel-index":e,dir:s,label:a,lang:this.effectiveLocale,numberButtonType:"none",numberingSystem:this.numberingSystem,onCalciteInputChange:this.handleChannelChange,onCalciteInputInput:this.handleChannelInput,onKeyDown:this.handleKeyDown,prefixText:n,scale:"l"===this.scale?"m":"s",type:"number",value:t?.toString()}),this.deleteColor=()=>{const t=this.color.hex();if(!(this.savedColors.indexOf(t)>-1))return;const e=this.savedColors.filter((e=>e!==t));this.savedColors=e,this.storageId&&localStorage.setItem(`${nt}${this.storageId}`,JSON.stringify(e))},this.saveColor=()=>{const t=this.color.hex();if(this.savedColors.indexOf(t)>-1)return;const e=[...this.savedColors,t];this.savedColors=e,this.storageId&&localStorage.setItem(`${nt}${this.storageId}`,JSON.stringify(e))},this.drawColorFieldAndSlider=(r=()=>{this.fieldAndSliderRenderingContext&&(this.drawColorField(),this.drawHueSlider())},h=!0,u=!0,A(o)&&(h="leading"in o?!!o.leading:h,u="trailing"in o?!!o.trailing:u),F(r,16,{leading:h,maxWait:16,trailing:u})),this.captureColorFieldColor=(t,e,i=!0)=>{const{dimensions:{colorField:{height:n,width:a}}}=this,s=Math.round(st.s/a*t),r=Math.round(st.v/n*(n-e));this.internalColorSet(this.baseColorFieldColor.hsv().saturationv(s).value(r),i)},this.initColorFieldAndSlider=t=>{this.fieldAndSliderRenderingContext=t.getContext("2d"),this.updateCanvasSize(t)},this.allowEmpty=!1,this.color=it,this.disabled=!1,this.format="auto",this.hideHex=!1,this.hideChannels=!1,this.hideSaved=!1,this.scale="m",this.storageId=void 0,this.messageOverrides=void 0,this.numberingSystem=void 0,this.value=ot,this.defaultMessages=void 0,this.colorFieldAndSliderInteractive=!1,this.channelMode="rgb",this.channels=this.toChannels(it),this.dimensions=rt.m,this.effectiveLocale="",this.messages=void 0,this.savedColors=[],this.colorFieldScopeTop=void 0,this.colorFieldScopeLeft=void 0,this.scopeOrientation=void 0,this.hueScopeLeft=void 0,this.hueScopeTop=void 0}handleColorChange(t,e){this.drawColorFieldAndSlider(),this.updateChannelsFromColor(t),this.previousColor=e}handleFormatChange(t){this.setMode(t),this.internalColorSet(this.color,!1,"internal")}handleScaleChange(t="m"){this.updateDimensions(t),this.updateCanvasSize(this.fieldAndSliderRenderingContext?.canvas)}onMessagesChange(){}handleValueChange(t,e){const{allowEmpty:i,format:n}=this;let a=!1;if(!i||t){const i=h(t);if(!i||"auto"!==n&&i!==n)return this.showIncompatibleColorWarning(t,n),void(this.value=e);a=this.mode!==i,this.setMode(i)}const s="drag"===this.sliderThumbState||"drag"===this.hueThumbState;if("initial"===this.internalColorUpdateContext)return;if("user-interaction"===this.internalColorUpdateContext)return this.calciteColorPickerInput.emit(),void(s||this.calciteColorPickerChange.emit());const r=i&&!t?null:Y(t),o=!u(r,this.color);(a||o)&&this.internalColorSet(r,!0,"internal")}get baseColorFieldColor(){return this.color||this.previousColor||it}effectiveLocaleChange(){C(this,this.effectiveLocale)}handleChannelKeyUpOrDown(t){this.shiftKeyChannelAdjustment=0;const{key:e}=t;if("ArrowUp"!==e&&"ArrowDown"!==e||!t.composedPath().some((t=>t.classList?.contains(tt))))return;const{shiftKey:i}=t;if(t.preventDefault(),!this.color)return this.internalColorSet(this.previousColor),void t.stopPropagation();this.shiftKeyChannelAdjustment="ArrowUp"===e&&i?9:"ArrowDown"===e&&i?-9:0}async setFocus(){await y(this),this.el.focus()}async componentWillLoad(){v(this);const{allowEmpty:t,color:e,format:i,value:n}=this,a=t&&!n,s=h(n),r=a||"auto"===i&&s||i===s,o=a?null:r?Y(n):e;r||this.showIncompatibleColorWarning(n,i),this.setMode(i),this.internalColorSet(o,!1,"initial"),this.updateDimensions(this.scale);const l=`${nt}${this.storageId}`;this.storageId&&localStorage.getItem(l)&&(this.savedColors=JSON.parse(localStorage.getItem(l))),await j(this)}connectedCallback(){k(this),z(this)}componentDidLoad(){w(this)}disconnectedCallback(){document.removeEventListener("pointermove",this.globalPointerMoveHandler),document.removeEventListener("pointerup",this.globalPointerUpHandler),x(this),D(this)}componentDidRender(){g(this)}render(){const{allowEmpty:t,color:e,messages:n,hideHex:a,hideChannels:s,hideSaved:r,savedColors:o,scale:l}=this,c=e?e.hex():null,h="l"===l?"m":"s",{colorFieldAndSliderInteractive:u,colorFieldScopeTop:d,colorFieldScopeLeft:m,hueScopeLeft:f,hueScopeTop:p,scopeOrientation:g,dimensions:{colorField:{height:b,width:y},slider:{height:v}}}=this,w=p??v/2+b,k=f??y*it.hue()/st.h,x=null===e,M="vertical"===g;return i("div",{class:"container"},i("div",{class:"color-field-and-slider-wrap"},i("canvas",{class:{"color-field-and-slider":!0,"color-field-and-slider--interactive":u},onPointerDown:this.handleColorFieldAndSliderPointerDown,onPointerEnter:this.handleColorFieldAndSliderPointerEnterOrMove,onPointerLeave:this.handleColorFieldAndSliderPointerLeave,onPointerMove:this.handleColorFieldAndSliderPointerEnterOrMove,ref:this.initColorFieldAndSlider}),i("div",{"aria-label":M?n.value:n.saturation,"aria-valuemax":M?st.v:st.s,"aria-valuemin":"0","aria-valuenow":(M?e?.saturationv():e?.value())||"0",class:{[et]:!0,"scope--color-field":!0},onKeyDown:this.handleColorFieldScopeKeyDown,role:"slider",style:{top:`${d||0}px`,left:`${m||0}px`},tabindex:"0",ref:this.storeColorFieldScope}),i("div",{"aria-label":n.hue,"aria-valuemax":st.h,"aria-valuemin":"0","aria-valuenow":e?.round().hue()||it.round().hue(),class:{[et]:!0,"scope--hue":!0},onKeyDown:this.handleHueScopeKeyDown,role:"slider",style:{top:`${w}px`,left:`${k}px`},tabindex:"0",ref:this.storeHueScope})),a&&s?null:i("div",{class:{"control-section":!0,[G]:!0}},a?null:i("div",{class:"color-hex-options"},i("span",{class:{[Q]:!0,"header--hex":!0}},n.hex),i("calcite-color-picker-hex-input",{allowEmpty:t,class:Z,hexLabel:n.hex,numberingSystem:this.numberingSystem,onCalciteColorPickerHexInputChange:this.handleHexInputChange,scale:h,value:c})),s?null:i("calcite-tabs",{class:{"color-mode-container":!0,"section--split":!0},scale:h},i("calcite-tab-nav",{slot:"title-group"},this.renderChannelsTabTitle("rgb"),this.renderChannelsTabTitle("hsv")),this.renderChannelsTab("rgb"),this.renderChannelsTab("hsv"))),r?null:i("div",{class:{"saved-colors-section":!0,[G]:!0}},i("div",{class:Q},i("label",null,n.saved),i("div",{class:"saved-colors-buttons"},i("calcite-button",{appearance:"transparent",class:"delete-color",disabled:x,iconStart:"minus",kind:"neutral",label:n.deleteColor,onClick:this.deleteColor,scale:h,type:"button"}),i("calcite-button",{appearance:"transparent",class:"save-color",disabled:x,iconStart:"plus",kind:"neutral",label:n.saveColor,onClick:this.saveColor,scale:h,type:"button"}))),o.length>0?i("div",{class:"saved-colors"},[...o.map((t=>i("calcite-color-picker-swatch",{active:c===t,class:"saved-color",color:t,key:t,onClick:this.handleSavedColorSelect,onKeyDown:this.handleSavedColorKeyDown,scale:l,tabIndex:0})))]):null))}handleKeyDown(t){"Enter"===t.key&&t.preventDefault()}showIncompatibleColorWarning(t,e){console.warn(`ignoring color value (${t}) as it is not compatible with the current format (${e})`)}setMode(t){this.mode="auto"===t?this.mode:t}captureHueSliderColor(t){const{dimensions:{slider:{width:e}}}=this;this.internalColorSet(this.baseColorFieldColor.hue(360/e*t),!1)}getCanvasRegion(t){const{dimensions:{colorField:{height:e},slider:{height:i}}}=this;return t<=e?"color-field":t<=e+i?"slider":"none"}internalColorSet(t,e=!0,i="user-interaction"){e&&u(t,this.color)||(this.internalColorUpdateContext=i,this.color=t,this.value=this.toValue(t),this.internalColorUpdateContext=null)}toValue(t,e=this.mode){if(!t)return null;if(e.includes("hex"))return l(t.round().hex());if(e.includes("-css"))return t[e.replace("-css","").replace("a","")]().round().string();const i=t[e]().round().object();return e.endsWith("a")&&(i.a=i.alpha,delete i.alpha),i}getSliderCapSpacing(){const{dimensions:{slider:{height:t},thumb:{radius:e}}}=this;return 2*e-t}updateDimensions(t="m"){this.dimensions=rt[t]}drawColorField(){const t=this.fieldAndSliderRenderingContext,{dimensions:{colorField:{height:e,width:i}}}=this;t.fillStyle=this.baseColorFieldColor.hsv().saturationv(100).value(100).string(),t.fillRect(0,0,i,e);const n=t.createLinearGradient(0,0,i,0);n.addColorStop(0,"rgba(255,255,255,1)"),n.addColorStop(1,"rgba(255,255,255,0)"),t.fillStyle=n,t.fillRect(0,0,i,e);const a=t.createLinearGradient(0,0,0,e);a.addColorStop(0,"rgba(0,0,0,0)"),a.addColorStop(1,"rgba(0,0,0,1)"),t.fillStyle=a,t.fillRect(0,0,i,e),this.drawActiveColorFieldColor()}setCanvasContextSize(t,{height:e,width:i}){const n=window.devicePixelRatio||1;t.width=i*n,t.height=e*n,t.style.height=`${e}px`,t.style.width=`${i}px`,t.getContext("2d").scale(n,n)}updateCanvasSize(t){t&&(this.setCanvasContextSize(t,{width:this.dimensions.colorField.width,height:this.dimensions.colorField.height+this.dimensions.slider.height+2*this.getSliderCapSpacing()}),this.drawColorFieldAndSlider())}containsPoint(t,e,i,n,a){return Math.pow(t-i,2)+Math.pow(e-n,2)<=Math.pow(a,2)}drawActiveColorFieldColor(){const{color:t}=this;if(!t)return;const e=t.hsv(),{dimensions:{colorField:{height:i,width:n},thumb:{radius:a}}}=this,s=e.saturationv()/(st.s/n),r=i-e.value()/(st.v/i);requestAnimationFrame((()=>{this.colorFieldScopeLeft=s,this.colorFieldScopeTop=r})),this.drawThumb(this.fieldAndSliderRenderingContext,a,s,r,e,this.hueThumbState)}drawThumb(t,e,i,n,a,s){const r=2*Math.PI;t.beginPath(),t.arc(i,n,e,0,r),t.shadowBlur="hover"===s?32:16,t.shadowColor=`rgba(0, 0, 0, ${"drag"===s?.32:.16})`,t.fillStyle="#fff",t.fill(),t.beginPath(),t.arc(i,n,e-3,0,r),t.shadowBlur=0,t.shadowColor="transparent",t.fillStyle=a.rgb().string(),t.fill()}drawActiveHueSliderColor(){const{color:t}=this;if(!t)return;const e=t.hsv().saturationv(100).value(100),{dimensions:{colorField:{height:i},slider:{height:n,width:a},thumb:{radius:s}}}=this,r=e.hue()/(360/a),o=n/2+i;requestAnimationFrame((()=>{this.hueScopeLeft=r,this.hueScopeTop=o})),this.drawThumb(this.fieldAndSliderRenderingContext,s,r,o,e,this.sliderThumbState)}drawHueSlider(){const t=this.fieldAndSliderRenderingContext,{dimensions:{colorField:{height:e},slider:{height:i,width:n}}}=this,a=t.createLinearGradient(0,0,n,0),s=["red","yellow","lime","cyan","blue","magenta","red"],r=1/(s.length-1);let o=0;s.forEach((t=>{a.addColorStop(o,Y(t).string()),o+=r})),t.fillStyle=a,t.clearRect(0,e,n,i+2*this.getSliderCapSpacing()),t.fillRect(0,e,n,i),this.drawActiveHueSliderColor()}updateColorFromChannels(t){this.internalColorSet(Y(t,this.channelMode))}updateChannelsFromColor(t){this.channels=t?this.toChannels(t):[null,null,null]}toChannels(t){const{channelMode:e}=this;return t[e]().array().map((t=>Math.floor(t)))}static get delegatesFocus(){return!0}static get assetsDirs(){return["assets"]}get el(){return n(this)}static get watchers(){return{color:["handleColorChange"],format:["handleFormatChange"],scale:["handleScaleChange"],messageOverrides:["onMessagesChange"],value:["handleValueChange"],effectiveLocale:["effectiveLocaleChange"]}}};lt.style="@keyframes in{0%{opacity:0}100%{opacity:1}}@keyframes in-down{0%{opacity:0;transform:translate3D(0, -5px, 0)}100%{opacity:1;transform:translate3D(0, 0, 0)}}@keyframes in-up{0%{opacity:0;transform:translate3D(0, 5px, 0)}100%{opacity:1;transform:translate3D(0, 0, 0)}}@keyframes in-scale{0%{opacity:0;transform:scale3D(0.95, 0.95, 1)}100%{opacity: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;animation-fill-mode:both;animation-duration:var(--calcite-animation-timing)}.calcite-animate__in{animation-name:in}.calcite-animate__in-down{animation-name:in-down}.calcite-animate__in-up{animation-name:in-up}.calcite-animate__in-scale{animation-name:in-scale}@media (prefers-reduced-motion: reduce){:root{--calcite-internal-duration-factor:0.01}}:root{--calcite-floating-ui-transition:var(--calcite-animation-timing);--calcite-floating-ui-z-index:600}:host([hidden]){display:none}:host([disabled]){pointer-events:none;cursor:default;-webkit-user-select:none;user-select:none;opacity:var(--calcite-ui-opacity-disabled)}:host{display:inline-block;font-size:var(--calcite-font-size--2);line-height:1rem;font-weight:var(--calcite-font-weight-normal)}:host([disabled]) ::slotted([calcite-hydrated][disabled]),:host([disabled]) [calcite-hydrated][disabled]{opacity:1}:host([scale=s]) .container{inline-size:160px}:host([scale=s]) .saved-colors{grid-template-columns:repeat(auto-fill, minmax(20px, 1fr))}:host([scale=s]) .channels{flex-direction:column}:host([scale=s]) .channel{inline-size:100%;margin-block-end:4px}:host([scale=s]) .channel:last-child{margin-block-end:0}:host([scale=m]) .container{inline-size:272px}:host([scale=l]) .header{padding-block-end:0px}:host([scale=l]){font-size:var(--calcite-font-size--1);line-height:1rem}:host([scale=l]) .container{inline-size:464px}:host([scale=l]) .color-field-and-slider{margin-block-end:-20px}:host([scale=l]) .section{padding-block:0 16px;padding-inline:16px}:host([scale=l]) .section:first-of-type{padding-block-start:16px}:host([scale=l]) .saved-colors{grid-template-columns:repeat(auto-fill, minmax(28px, 1fr));grid-gap:12px;padding-block-start:16px}:host([scale=l]) .control-section{flex-wrap:nowrap;align-items:baseline}:host([scale=l]) .control-section>:nth-child(2){margin-inline-start:12px}:host([scale=l]) .color-hex-options{display:flex;flex-shrink:1;flex-direction:column;justify-content:space-around;min-block-size:98px;inline-size:160px}:host([scale=l]) .color-mode-container{flex-shrink:3}.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;font-size:var(--calcite-font-size--1);outline-color:transparent;outline-offset:14px}.scope:focus{outline:2px solid var(--calcite-ui-brand);outline-offset:16px}.color-field-and-slider{margin-block-end:-16px;touch-action:none}.color-field-and-slider--interactive{cursor:pointer}.control-section{display:flex;flex-direction:row;flex-wrap:wrap}.section{padding-block:0 12px;padding-inline:12px}.section:first-of-type{padding-block-start:12px}.color-hex-options,.section--split{flex-grow:1}.header{display:flex;align-items:center;justify-content:space-between;padding-block-end:0.25rem;color:var(--calcite-ui-text-1)}.header--hex,.color-mode-container{padding-block-start:12px}.channels{display:flex;justify-content:space-between}.channel{inline-size:31%}.saved-colors{padding-block-start:12px;display:grid;grid-template-columns:repeat(auto-fill, minmax(24px, 1fr));grid-gap:8px;inline-size:100%}.saved-colors-buttons{display:flex}.saved-color{outline-offset:0;outline-color:transparent;cursor:pointer}.saved-color:focus{outline:2px solid var(--calcite-ui-brand);outline-offset:2px}.saved-color:hover{transition:outline-color var(--calcite-internal-animation-timing-fast) ease-in-out;outline:2px solid var(--calcite-ui-border-2);outline-offset:2px}";const ct=Y(),ht=class{constructor(i){t(this,i),this.calciteColorPickerHexInputChange=e(this,"calciteColorPickerHexInputChange",6),this.onCalciteInternalInputBlur=()=>{const t=this.inputNode,e=t.value,i=`#${e}`;this.allowEmpty&&!e||d(i)&&m(i)||(t.value=this.allowEmpty&&!this.internalColor?"":this.formatForInternalInput(f(this.internalColor.object())))},this.onInputChange=()=>{this.internalSetValue(this.inputNode.value,this.value)},this.previousNonNullValue=this.value,this.storeInputRef=t=>{this.inputNode=t},this.hexLabel="Hex",this.allowEmpty=!1,this.scale="m",this.value=l(ct.hex()),this.numberingSystem=void 0,this.internalColor=ct}connectedCallback(){const{allowEmpty:t,value:e}=this;if(e){const t=l(e);d(t)&&this.internalSetValue(t,t,!1)}else t&&this.internalSetValue(null,null,!1)}componentWillLoad(){v(this)}componentDidLoad(){w(this)}handleValueChange(t,e){this.internalSetValue(t,e,!1)}onInputKeyDown(t){const{altKey:e,ctrlKey:i,metaKey:n,shiftKey:a}=t,{internalColor:s,value:r}=this,{key:o}=t;if("Tab"===o||"Enter"===o)return void this.onInputChange();const c=this.value;if("ArrowDown"===o||"ArrowUp"===o)return r?(this.internalSetValue(l(this.nudgeRGBChannels(s,(a?10:1)*("ArrowUp"===o?1:-1)).hex()),c),void t.preventDefault()):(this.internalSetValue(this.previousNonNullValue,c),void t.preventDefault());const h=e||i||n,u=1===o.length,d=p.test(o);!u||h||d||t.preventDefault()}onPaste(t){const e=t.clipboardData.getData("text");d(e)&&(t.preventDefault(),this.inputNode.value=e.slice(1))}render(){const{value:t}=this,e=this.formatForInternalInput(t);return i("div",{class:"container"},i("calcite-input",{class:"input",label:this.hexLabel,maxLength:6,numberingSystem:this.numberingSystem,onCalciteInputChange:this.onInputChange,onCalciteInternalInputBlur:this.onCalciteInternalInputBlur,onKeyDown:this.handleKeyDown,onPaste:this.onPaste,prefixText:"#",scale:this.scale,value:e,ref:this.storeInputRef}),e?i("calcite-color-picker-swatch",{active:!0,class:"preview",color:`#${e}`,scale:this.scale}):null)}async setFocus(){await y(this),r(this.inputNode)}internalSetValue(t,e,i=!0){if(t){const e=l(t);if(d(e)){const{internalColor:t}=this,n=!t||e!==l(t.hex());return this.internalColor=Y(e),this.previousNonNullValue=e,this.value=e,void(n&&i&&this.calciteColorPickerHexInputChange.emit())}}else if(this.allowEmpty)return this.internalColor=null,this.value=null,void(i&&this.calciteColorPickerHexInputChange.emit());this.value=e}formatForInternalInput(t){return t?t.replace("#",""):""}nudgeRGBChannels(t,e){return Y.rgb(t.array().map((t=>t+e)))}handleKeyDown(t){"Enter"===t.key&&t.preventDefault()}get el(){return n(this)}static get watchers(){return{value:["handleValueChange"]}}};ht.style="@keyframes in{0%{opacity:0}100%{opacity:1}}@keyframes in-down{0%{opacity:0;transform:translate3D(0, -5px, 0)}100%{opacity:1;transform:translate3D(0, 0, 0)}}@keyframes in-up{0%{opacity:0;transform:translate3D(0, 5px, 0)}100%{opacity:1;transform:translate3D(0, 0, 0)}}@keyframes in-scale{0%{opacity:0;transform:scale3D(0.95, 0.95, 1)}100%{opacity: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;animation-fill-mode:both;animation-duration:var(--calcite-animation-timing)}.calcite-animate__in{animation-name:in}.calcite-animate__in-down{animation-name:in-down}.calcite-animate__in-up{animation-name:in-up}.calcite-animate__in-scale{animation-name:in-scale}@media (prefers-reduced-motion: reduce){:root{--calcite-internal-duration-factor:0.01}}:root{--calcite-floating-ui-transition:var(--calcite-animation-timing);--calcite-floating-ui-z-index:600}:host([hidden]){display:none}:host{display:block}.container{display:inline-grid;inline-size:100%;align-items:center;grid-template-columns:1fr auto}.preview{grid-column:2/3;pointer-events:none;margin-block:0px;margin-inline:0.25rem;display:flex;align-items:center}.preview,.input{grid-row:1}.input{grid-column:1/3;inline-size:100%;text-transform:uppercase}";const ut=class{constructor(e){t(this,e),this.active=!1,this.color=void 0,this.scale="m"}handleColorChange(t){this.internalColor=Y(t)}componentWillLoad(){this.handleColorChange(this.color)}render(){const{active:t,el:e,internalColor:n}=this,a=t?"100%":"0",s=n.hex(),r="light"===o(e)?"rgba(0, 0, 0, 0.3)":"rgba(255, 255, 255, 0.15)";return i("svg",{class:"swatch",xmlns:"http://www.w3.org/2000/svg"},i("title",null,s),i("rect",{fill:s,height:"100%",id:"swatch",rx:a,stroke:r,"stroke-width":"2",style:{"clip-path":`inset(0 round ${a})`},width:"100%"}))}get el(){return n(this)}static get watchers(){return{color:["handleColorChange"]}}};ut.style="@keyframes in{0%{opacity:0}100%{opacity:1}}@keyframes in-down{0%{opacity:0;transform:translate3D(0, -5px, 0)}100%{opacity:1;transform:translate3D(0, 0, 0)}}@keyframes in-up{0%{opacity:0;transform:translate3D(0, 5px, 0)}100%{opacity:1;transform:translate3D(0, 0, 0)}}@keyframes in-scale{0%{opacity:0;transform:scale3D(0.95, 0.95, 1)}100%{opacity: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;animation-fill-mode:both;animation-duration:var(--calcite-animation-timing)}.calcite-animate__in{animation-name:in}.calcite-animate__in-down{animation-name:in-down}.calcite-animate__in-up{animation-name:in-up}.calcite-animate__in-scale{animation-name:in-scale}@media (prefers-reduced-motion: reduce){:root{--calcite-internal-duration-factor:0.01}}:root{--calcite-floating-ui-transition:var(--calcite-animation-timing);--calcite-floating-ui-z-index:600}:host([hidden]){display:none}:host{position:relative;display:inline-flex}:host([scale=s]){block-size:1.25rem;inline-size:1.25rem}:host([scale=m]){block-size:1.5rem;inline-size:1.5rem}:host([scale=l]){block-size:2rem;inline-size:2rem}.swatch{overflow:visible;block-size:inherit;inline-size:inherit}.swatch rect{transition-property:all;transition-duration:150ms;transition-timing-function:cubic-bezier(0.4, 0, 0.2, 1)}.no-color-icon{position:absolute;inset:0px;block-size:100%;inline-size:100%}";export{lt as calcite_color_picker,ht as calcite_color_picker_hex_input,ut as calcite_color_picker_swatch}
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
/*!
|
|
2
|
+
* All material copyright ESRI, All Rights Reserved, unless otherwise specified.
|
|
3
|
+
* See https://github.com/Esri/calcite-components/blob/master/LICENSE.md for details.
|
|
4
|
+
* v1.1.1-next.1
|
|
5
|
+
*/
|
|
6
|
+
import{r as i,c as t,h as a,F as e,g as n}from"./p-983244bc.js";import{c,d as o}from"./p-25d10f33.js";import{g as r,b as s,t as l}from"./p-cff554c3.js";import{c as d,d as m}from"./p-d70da26b.js";import{u as h,c as p,s as g,d as f}from"./p-2c2c6832.js";import{H as u,c as v}from"./p-95829133.js";import{c as x}from"./p-53515d24.js";import"./p-1e3ad5b6.js";import"./p-ebd84c48.js";import"./p-83b37109.js";const y="thumbnail",b=class{constructor(a){i(this,a),this.calciteTipDismiss=t(this,"calciteTipDismiss",6),this.hideTip=()=>{this.closed=!0,this.calciteTipDismiss.emit()},this.closed=!1,this.closeDisabled=!1,this.heading=void 0,this.headingLevel=void 0,this.selected=!1,this.messages=void 0,this.messageOverrides=void 0,this.defaultMessages=void 0,this.effectiveLocale=""}onMessagesChange(){}effectiveLocaleChange(){h(this,this.effectiveLocale)}connectedCallback(){c(this),d(this),p(this)}async componentWillLoad(){await g(this)}disconnectedCallback(){o(this),m(this),f(this)}renderHeader(){const{heading:i,headingLevel:t,el:e}=this,n=e.closest("calcite-tip-manager")?.headingLevel,c=n?v(n+1):null;return i?a("header",{class:"header"},a(u,{class:"heading",level:t||c},i)):null}renderDismissButton(){const{closeDisabled:i,hideTip:t}=this;return i?null:a("calcite-action",{class:"close",icon:"x",onClick:t,scale:"l",text:this.messages.close})}renderImageFrame(){const{el:i}=this;return r(i,y)?a("div",{class:"image-frame",key:"thumbnail"},a("slot",{name:y})):null}renderInfoNode(){return a("div",{class:"info"},a("slot",null))}renderContent(){return a("div",{class:"content"},this.renderImageFrame(),this.renderInfoNode())}render(){return a(e,null,a("article",{class:"container"},this.renderHeader(),this.renderContent()),this.renderDismissButton())}static get assetsDirs(){return["assets"]}get el(){return n(this)}static get watchers(){return{messageOverrides:["onMessagesChange"],effectiveLocale:["effectiveLocaleChange"]}}};b.style="@keyframes in{0%{opacity:0}100%{opacity:1}}@keyframes in-down{0%{opacity:0;transform:translate3D(0, -5px, 0)}100%{opacity:1;transform:translate3D(0, 0, 0)}}@keyframes in-up{0%{opacity:0;transform:translate3D(0, 5px, 0)}100%{opacity:1;transform:translate3D(0, 0, 0)}}@keyframes in-scale{0%{opacity:0;transform:scale3D(0.95, 0.95, 1)}100%{opacity: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;animation-fill-mode:both;animation-duration:var(--calcite-animation-timing)}.calcite-animate__in{animation-name:in}.calcite-animate__in-down{animation-name:in-down}.calcite-animate__in-up{animation-name:in-up}.calcite-animate__in-scale{animation-name:in-scale}@media (prefers-reduced-motion: reduce){:root{--calcite-internal-duration-factor:0.01}}:root{--calcite-floating-ui-transition:var(--calcite-animation-timing);--calcite-floating-ui-z-index:600}:host([hidden]){display:none}:host{position:relative;margin:1rem;box-sizing:border-box;display:flex;flex-direction:row;border-width:1px;border-style:solid;border-color:var(--calcite-ui-border-2);background-color:var(--calcite-ui-foreground-1);font-size:var(--calcite-font-size--1);line-height:1rem;color:var(--calcite-ui-text-2)}:host *{box-sizing:border-box}.container{inline-size:100%;padding:1rem}:host([closed]),:host([closed]) .container{display:none}:host([selected]) .container{margin:0px;border-style:none;padding:0px}.header{margin:0px;display:flex;align-content:space-between;align-items:center;fill:var(--calcite-ui-text-2);color:var(--calcite-ui-text-2)}.heading{margin:0px;padding:0px;font-weight:var(--calcite-font-weight-medium)}.header .heading{flex:1 1 auto;padding:0.5rem}.header{margin-block-end:0.5rem}.header .heading{padding:0px;font-size:var(--calcite-font-size-0);line-height:1.25rem;color:var(--calcite-ui-text-1)}.container[hidden]{display:none}.content{display:flex}.info{padding-block:0px;padding-inline:1rem;inline-size:70%}.info:only-child{inline-size:100%;padding-inline:0px}::slotted(p){margin-block-start:0px}::slotted(a){outline-color:transparent;color:var(--calcite-ui-brand)}::slotted(a:focus){outline:2px solid var(--calcite-ui-brand);outline-offset:2px}.image-frame{inline-size:25%}.image-frame img{max-inline-size:100%}::slotted(img){max-inline-size:100%}";const k=class{constructor(t){i(this,t),this.groupTitle=void 0}render(){return a("slot",null)}};k.style="@keyframes in{0%{opacity:0}100%{opacity:1}}@keyframes in-down{0%{opacity:0;transform:translate3D(0, -5px, 0)}100%{opacity:1;transform:translate3D(0, 0, 0)}}@keyframes in-up{0%{opacity:0;transform:translate3D(0, 5px, 0)}100%{opacity:1;transform:translate3D(0, 0, 0)}}@keyframes in-scale{0%{opacity:0;transform:scale3D(0.95, 0.95, 1)}100%{opacity: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;animation-fill-mode:both;animation-duration:var(--calcite-animation-timing)}.calcite-animate__in{animation-name:in}.calcite-animate__in-down{animation-name:in-down}.calcite-animate__in-up{animation-name:in-up}.calcite-animate__in-scale{animation-name:in-scale}@media (prefers-reduced-motion: reduce){:root{--calcite-internal-duration-factor:0.01}}:root{--calcite-floating-ui-transition:var(--calcite-animation-timing);--calcite-floating-ui-z-index:600}:host([hidden]){display:none}:host{box-sizing:border-box;display:block;background-color:var(--calcite-ui-foreground-1);font-size:var(--calcite-font-size--1);line-height:1rem;color:var(--calcite-ui-text-2)}::slotted(calcite-tip){margin:0px;border-style:none}:host-context(calcite-tip-manager){margin-block:0.75rem}:host-context(calcite-tip-manager) ::slotted(calcite-tip){padding:1rem}";const w="chevron-left",z="chevron-right",_=class{constructor(a){i(this,a),this.calciteTipManagerClose=t(this,"calciteTipManagerClose",6),this.mutationObserver=x("mutation",(()=>this.setUpTips())),this.hideTipManager=()=>{this.closed=!0,this.calciteTipManagerClose.emit()},this.previousClicked=()=>{this.previousTip()},this.nextClicked=()=>{this.nextTip()},this.tipManagerKeyDownHandler=i=>{if(i.target===this.container)switch(i.key){case"ArrowRight":i.preventDefault(),this.nextTip();break;case"ArrowLeft":i.preventDefault(),this.previousTip();break;case"Home":i.preventDefault(),this.selectedIndex=0;break;case"End":i.preventDefault(),this.selectedIndex=this.total-1}},this.storeContainerRef=i=>{this.container=i},this.closed=!1,this.headingLevel=void 0,this.messages=void 0,this.messageOverrides=void 0,this.selectedIndex=void 0,this.tips=void 0,this.total=void 0,this.direction=void 0,this.groupTitle=void 0,this.defaultMessages=void 0,this.effectiveLocale=""}closedChangeHandler(){this.direction=null}onMessagesChange(){}selectedChangeHandler(){this.showSelectedTip(),this.updateGroupTitle()}async effectiveLocaleChange(){await h(this,this.effectiveLocale),this.updateGroupTitle()}connectedCallback(){d(this),p(this),this.setUpTips(),this.mutationObserver?.observe(this.el,{childList:!0,subtree:!0})}async componentWillLoad(){await g(this),this.updateGroupTitle()}disconnectedCallback(){this.mutationObserver?.disconnect(),m(this),f(this)}async nextTip(){this.direction="advancing",this.selectedIndex=(this.selectedIndex+1+this.total)%this.total}async previousTip(){this.direction="retreating",this.selectedIndex=(this.selectedIndex-1+this.total)%this.total}setUpTips(){const i=Array.from(this.el.querySelectorAll("calcite-tip"));if(this.total=i.length,0===this.total)return;const t=this.el.querySelector("calcite-tip[selected]");this.tips=i,this.selectedIndex=t?i.indexOf(t):0,i.forEach((i=>{i.closeDisabled=!0})),this.showSelectedTip()}showSelectedTip(){this.tips.forEach(((i,t)=>{const a=this.selectedIndex===t;i.selected=a,i.hidden=!a}))}updateGroupTitle(){if(this.tips){const i=this.tips[this.selectedIndex].closest("calcite-tip-group");this.groupTitle=i?.groupTitle||this.messages?.defaultGroupTitle}}renderPagination(){const i=s(this.el),{selectedIndex:t,tips:e,total:n,messages:c}=this,o=c.next,r=c.defaultPaginationLabel;return e.length>1?a("footer",{class:"pagination"},a("calcite-action",{class:"page-previous",icon:"ltr"===i?w:z,onClick:this.previousClicked,scale:"m",text:c.previous}),a("span",{class:"page-position"},`${r} ${t+1}/${n}`),a("calcite-action",{class:"page-next",icon:"ltr"===i?z:w,onClick:this.nextClicked,scale:"m",text:o})):null}render(){const{closed:i,direction:t,headingLevel:e,groupTitle:n,selectedIndex:c,messages:o,total:r}=this,s=o.close;return 0===r?null:a("section",{"aria-hidden":l(i),class:"container",hidden:i,onKeyDown:this.tipManagerKeyDownHandler,tabIndex:0,ref:this.storeContainerRef},a("header",{class:"header"},a(u,{class:"heading",level:e},n),a("calcite-action",{class:"close",onClick:this.hideTipManager,scale:"m",text:s},a("calcite-icon",{icon:"x",scale:"m"}))),a("div",{class:{"tip-container":!0,"tip-container--advancing":!i&&"advancing"===t,"tip-container--retreating":!i&&"retreating"===t},key:c,tabIndex:0},a("slot",null)),this.renderPagination())}static get assetsDirs(){return["assets"]}get el(){return n(this)}static get watchers(){return{closed:["closedChangeHandler"],messageOverrides:["onMessagesChange"],selectedIndex:["selectedChangeHandler"],effectiveLocale:["effectiveLocaleChange"]}}};_.style="@keyframes in{0%{opacity:0}100%{opacity:1}}@keyframes in-down{0%{opacity:0;transform:translate3D(0, -5px, 0)}100%{opacity:1;transform:translate3D(0, 0, 0)}}@keyframes in-up{0%{opacity:0;transform:translate3D(0, 5px, 0)}100%{opacity:1;transform:translate3D(0, 0, 0)}}@keyframes in-scale{0%{opacity:0;transform:scale3D(0.95, 0.95, 1)}100%{opacity: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;animation-fill-mode:both;animation-duration:var(--calcite-animation-timing)}.calcite-animate__in{animation-name:in}.calcite-animate__in-down{animation-name:in-down}.calcite-animate__in-up{animation-name:in-up}.calcite-animate__in-scale{animation-name:in-scale}@media (prefers-reduced-motion: reduce){:root{--calcite-internal-duration-factor:0.01}}:root{--calcite-floating-ui-transition:var(--calcite-animation-timing);--calcite-floating-ui-z-index:600}:host([hidden]){display:none}:host{box-sizing:border-box;display:block;background-color:var(--calcite-ui-foreground-1);font-size:var(--calcite-font-size--1);line-height:1rem;color:var(--calcite-ui-text-2);--calcite-tip-manager-height:19vh}:host *{box-sizing:border-box}:host([closed]){display:none}.header{margin:0px;display:flex;align-content:space-between;align-items:center;fill:var(--calcite-ui-text-2);color:var(--calcite-ui-text-2)}.heading{margin:0px;padding:0px;font-weight:var(--calcite-font-weight-medium)}.header .heading{flex:1 1 auto;padding:0.5rem}.header{border-width:0px;border-block-end-width:1px;border-style:solid;border-color:var(--calcite-ui-border-3);padding-block:0px;padding-inline-end:0px;padding-inline-start:1rem}.header .heading{padding:0px;font-size:var(--calcite-font-size-1);line-height:1.5rem;font-weight:var(--calcite-font-weight-bold);color:var(--calcite-ui-text-1)}.container{position:relative;overflow:hidden;outline-color:transparent;min-block-size:150px}.container:focus{outline:2px solid var(--calcite-ui-brand);outline-offset:2px}.tip-container{margin-block-start:1px;display:flex;align-items:flex-start;justify-content:center;overflow:auto;outline-color:transparent;animation-name:none;animation-duration:var(--calcite-animation-timing);block-size:var(--calcite-tip-manager-height)}.tip-container:focus{outline:2px solid var(--calcite-ui-brand);outline-offset:2px}::slotted(calcite-tip){border-style:none;padding:0.75rem;max-inline-size:var(--calcite-tip-max-width)}.tip-container--advancing{animation-name:tip-advance}.tip-container--retreating{animation-name:tip-retreat}.pagination{display:flex;align-items:center;justify-content:center;padding-inline:0px;padding-block:0.75rem 0.5rem}.page-position{margin-block:0px;margin-inline:0.5rem;font-size:var(--calcite-font-size--2);line-height:1rem}@keyframes tip-advance{0%{opacity:0;transform:translate3d(50px, 0, 0) scale(0.99)}100%{opacity:1;transform:translate3d(0, 0, 0) scale(1)}}@keyframes tip-retreat{0%{opacity:0;transform:translate3d(-50px, 0, 0) scale(0.99)}100%{opacity:1;transform:translate3d(0, 0, 0) scale(1)}}";export{b as calcite_tip,k as calcite_tip_group,_ as calcite_tip_manager}
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
/*!
|
|
2
|
+
* All material copyright ESRI, All Rights Reserved, unless otherwise specified.
|
|
3
|
+
* See https://github.com/Esri/calcite-components/blob/master/LICENSE.md for details.
|
|
4
|
+
* v1.1.1-next.1
|
|
5
|
+
*/
|
|
6
|
+
import{f as t}from"./p-983244bc.js";import{c as o}from"./p-53515d24.js";const n=new Set;let c;const s={childList:!0};function f(t){c||(c=o("mutation",r)),c.observe(t.el,s)}function i(t){n.delete(t.el),r(c.takeRecords()),c.disconnect();for(const[t]of n.entries())c.observe(t,s)}function r(o){o.forEach((({target:o})=>{t(o)}))}export{f as c,i as d}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/*!
|
|
2
2
|
* All material copyright ESRI, All Rights Reserved, unless otherwise specified.
|
|
3
3
|
* See https://github.com/Esri/calcite-components/blob/master/LICENSE.md for details.
|
|
4
|
-
* v1.1.
|
|
4
|
+
* v1.1.1-next.1
|
|
5
5
|
*/
|
|
6
|
-
import{r as t,c as i,h as a,g as e,H as s}from"./p-95affd38.js";import{S as n}from"./p-72e0a2c6.js";import{u as o}from"./p-b90df3dd.js";import{s as r,a as c,c as l}from"./p-bb1240f3.js";import{c as h,d}from"./p-b33dc129.js";import{c as m}from"./p-f510244b.js";import{u,c as p,s as f,d as v}from"./p-145b7cdc.js";import{g,m as w,d as b,a as y,s as x,h as k,b as D,c as L,k as _,e as j,i as I,f as C,j as z,l as A,n as H,r as F,o as R,p as S,q as U,t as B,L as $,I as M,C as O,S as V}from"./p-b4f3b351.js";import{c as q,d as K}from"./p-31cf383e.js";import{g as T}from"./p-b4c2f2ce.js";import{g as W}from"./p-c097b143.js";import"./p-32d3d2c6.js";import"./p-fda34bfd.js";import"./p-6293ed16.js";import"./p-44e65dab.js";var E;function P(t,i,a){const{items:e,messages:s}=a,n=e.length,o=g(a,t)+1;return function(t,i,a,e){return t.replace("${position}",a.toString()).replace("${itemLabel}",i).replace("${total}",e.toString())}("idle"===i?s.dragHandleIdle:"active"===i?s.dragHandleActive:"change"===i?s.dragHandleChange:s.dragHandleCommit,t.label,o,n)}function G(t){return{handle:t.composedPath().find((t=>void 0!==t.dataset?.jsHandle)),item:t.composedPath().find((t=>"calcite-value-list-item"===t.tagName?.toLowerCase()))}}!function(t){t.grip="grip"}(E||(E={}));const J=class{constructor(a){t(this,a),this.calciteListChange=i(this,"calciteListChange",6),this.calciteListOrderChange=i(this,"calciteListOrderChange",6),this.calciteListFilter=i(this,"calciteListFilter",6),this.lastSelectedItem=null,this.mutationObserver=m("mutation",w.bind(this)),this.setFilterEl=t=>{this.filterEl=t},this.setFilteredItems=t=>{this.filteredItems=t},this.deselectRemovedItems=b.bind(this),this.deselectSiblingItems=y.bind(this),this.selectSiblings=x.bind(this),this.handleFilter=k.bind(this),this.handleFilterEvent=D.bind(this),this.getItemData=L.bind(this),this.keyDownHandler=t=>{if(t.defaultPrevented)return;const{handle:i,item:a}=G(t);if(i&&!a.handleActivated&&" "===t.key&&this.updateScreenReaderText(P(a,"commit",this)),!i||!a.handleActivated)return void _.call(this,t);t.preventDefault();const{items:e}=this;if(" "===t.key&&this.updateScreenReaderText(P(a,"active",this)),"ArrowUp"!==t.key&&"ArrowDown"!==t.key||e.length<=1)return;const{el:s}=this,n=j(this,a,"ArrowUp"===t.key?"up":"down");if(n===e.length-1)s.appendChild(a);else{const t=s.children[n];s.insertBefore(a,t===a.nextElementSibling?t.nextElementSibling:t)}this.items=this.getItems(),this.calciteListOrderChange.emit(this.items.map((({value:t})=>t))),requestAnimationFrame((()=>i?.focus())),a.handleActivated=!0,this.updateHandleAriaLabel(i,P(a,"change",this))},this.storeAssistiveEl=t=>{this.assistiveTextEl=t},this.handleFocusIn=t=>{const{handle:i,item:a}=G(t);!a?.handleActivated&&a&&i&&this.updateHandleAriaLabel(i,P(a,"idle",this))},this.disabled=!1,this.dragEnabled=!1,this.filteredItems=[],this.filteredData=[],this.filterEnabled=!1,this.filterPlaceholder=void 0,this.filterText=void 0,this.group=void 0,this.loading=!1,this.multiple=!1,this.selectionFollowsFocus=!1,this.messageOverrides=void 0,this.messages=void 0,this.dataForFilter=[],this.defaultMessages=void 0,this.effectiveLocale="",this.selectedValues=new Map}onMessagesChange(){}effectiveLocaleChange(){u(this,this.effectiveLocale)}connectedCallback(){h(this),p(this),I.call(this),C.call(this)}async componentWillLoad(){r(this),await f(this)}componentDidLoad(){c(this),this.setUpDragAndDrop(),z.call(this)}componentDidRender(){o(this)}disconnectedCallback(){d(this),v(this),A.call(this),this.cleanUpDragAndDrop()}calciteListFocusOutHandler(t){H.call(this,t)}calciteListItemRemoveHandler(t){F.call(this,t)}calciteListItemChangeHandler(t){R.call(this,t)}calciteInternalListItemPropsChangeHandler(t){t.stopPropagation(),this.setUpFilter()}calciteInternalListItemValueChangeHandler(t){S.call(this,t),t.stopPropagation()}getItems(){return Array.from(this.el.querySelectorAll("calcite-value-list-item"))}setUpItems(){U.call(this,"calcite-value-list-item")}setUpFilter(){this.filterEnabled&&(this.dataForFilter=this.getItemData())}setUpDragAndDrop(){this.cleanUpDragAndDrop(),this.dragEnabled&&(this.sortable=n.create(this.el,{dataIdAttr:"id",handle:".handle",draggable:"calcite-value-list-item",group:this.group,onSort:()=>{this.items=Array.from(this.el.querySelectorAll("calcite-value-list-item"));const t=this.items.map((t=>t.value));this.calciteListOrderChange.emit(t)}}))}cleanUpDragAndDrop(){this.sortable?.destroy(),this.sortable=null}handleBlur(){this.dragEnabled&&this.updateScreenReaderText("")}async getSelectedItems(){return this.selectedValues}async setFocus(t){return await l(this),B.call(this,t)}getIconType(){let t=null;return this.dragEnabled&&(t=E.grip),t}updateScreenReaderText(t){this.assistiveTextEl.textContent=t}updateHandleAriaLabel(t,i){t.ariaLabel=i}handleValueListItemBlur(t){const{item:i,handle:a}=t.detail;!i?.handleActivated&&i&&this.updateHandleAriaLabel(a,P(i,"idle",this)),t.stopPropagation()}render(){return a($,{onBlur:this.handleBlur,onFocusin:this.handleFocusIn,onKeyDown:this.keyDownHandler,props:this})}static get assetsDirs(){return["assets"]}get el(){return e(this)}static get watchers(){return{messageOverrides:["onMessagesChange"],effectiveLocale:["effectiveLocaleChange"]}}};J.style="@keyframes in{0%{opacity:0}100%{opacity:1}}@keyframes in-down{0%{opacity:0;transform:translate3D(0, -5px, 0)}100%{opacity:1;transform:translate3D(0, 0, 0)}}@keyframes in-up{0%{opacity:0;transform:translate3D(0, 5px, 0)}100%{opacity:1;transform:translate3D(0, 0, 0)}}@keyframes in-scale{0%{opacity:0;transform:scale3D(0.95, 0.95, 1)}100%{opacity: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;animation-fill-mode:both;animation-duration:var(--calcite-animation-timing)}.calcite-animate__in{animation-name:in}.calcite-animate__in-down{animation-name:in-down}.calcite-animate__in-up{animation-name:in-up}.calcite-animate__in-scale{animation-name:in-scale}@media (prefers-reduced-motion: reduce){:root{--calcite-internal-duration-factor:0.01}}:root{--calcite-floating-ui-transition:var(--calcite-animation-timing);--calcite-floating-ui-z-index:600}:host([hidden]){display:none}:host([disabled]){pointer-events:none;cursor:default;-webkit-user-select:none;user-select:none;opacity:var(--calcite-ui-opacity-disabled)}:host{position:relative;box-sizing:border-box;display:flex;flex-shrink:0;flex-grow:0;flex-direction:column;align-items:stretch;background-color:transparent;font-size:var(--calcite-font-size--1);color:var(--calcite-ui-text-2)}:host *{box-sizing:border-box}:host([disabled]) ::slotted([calcite-hydrated][disabled]),:host([disabled]) [calcite-hydrated][disabled]{opacity:1}calcite-value-list-item:last-of-type{--tw-shadow:0 0 #0000;--tw-shadow-colored:0 0 #0000;box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow)}:host([filter-enabled]) header{margin-block-end:0.25rem;display:flex;align-items:center;justify-content:flex-end;background-color:var(--calcite-ui-foreground-1);--tw-shadow:0 1px 0 var(--calcite-ui-border-3);--tw-shadow-colored:0 1px 0 var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow)}:host([filter-enabled]) header.sticky-pos{position:sticky;inset-block-start:0px;z-index:300}calcite-filter{margin-block-end:1px}.assistive-text{position:absolute;inline-size:1px;block-size:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0, 0, 0, 0);white-space:nowrap;border-width:0}";const N=class{constructor(a){t(this,a),this.calciteListItemRemove=i(this,"calciteListItemRemove",7),this.calciteValueListItemDragHandleBlur=i(this,"calciteValueListItemDragHandleBlur",6),this.pickListItem=null,this.guid=`calcite-value-list-item-${W()}`,this.getPickListRef=t=>this.pickListItem=t,this.handleKeyDown=t=>{" "===t.key&&(this.handleActivated=!this.handleActivated)},this.handleBlur=()=>{this.handleActivated=!1,this.calciteValueListItemDragHandleBlur.emit({item:this.el,handle:this.handleEl})},this.handleSelectChange=t=>{this.selected=t.detail.selected},this.description=void 0,this.disabled=!1,this.deselectDisabled=!1,this.nonInteractive=!1,this.handleActivated=!1,this.icon=null,this.iconFlipRtl=!1,this.label=void 0,this.metadata=void 0,this.removable=!1,this.selected=!1,this.value=void 0}connectedCallback(){q(this)}disconnectedCallback(){K(this)}componentWillLoad(){r(this)}componentDidLoad(){c(this)}componentDidRender(){o(this,!!this.el.closest("calcite-value-list")&&"managed")}async toggleSelected(t){this.pickListItem.toggleSelected(t)}async setFocus(){await l(this),this.pickListItem?.setFocus()}calciteListItemChangeHandler(t){t.detail.item=this.el}renderActionsEnd(){const{el:t}=this;return T(t,"actions-end")?a("slot",{name:"actions-end",slot:V.actionsEnd}):null}renderActionsStart(){const{el:t}=this;return T(t,"actions-start")?a("slot",{name:"actions-start",slot:V.actionsStart}):null}renderHandle(){const{icon:t,iconFlipRtl:i}=this;if(t===M.grip)return a("span",{class:{[O.handle]:!0,[O.handleActivated]:this.handleActivated},"data-js-handle":!0,onBlur:this.handleBlur,onKeyDown:this.handleKeyDown,ref:t=>this.handleEl=t,role:"button",tabindex:"0"},a("calcite-icon",{flipRtl:i,icon:"drag",scale:"s"}))}render(){return a(s,{id:this.el.id||this.guid},this.renderHandle(),a("calcite-pick-list-item",{description:this.description,deselectDisabled:this.deselectDisabled,disabled:this.disabled,label:this.label,metadata:this.metadata,nonInteractive:this.nonInteractive,onCalciteListItemChange:this.handleSelectChange,removable:this.removable,selected:this.selected,value:this.value,ref:this.getPickListRef},this.renderActionsStart(),this.renderActionsEnd()))}get el(){return e(this)}};N.style="@keyframes in{0%{opacity:0}100%{opacity:1}}@keyframes in-down{0%{opacity:0;transform:translate3D(0, -5px, 0)}100%{opacity:1;transform:translate3D(0, 0, 0)}}@keyframes in-up{0%{opacity:0;transform:translate3D(0, 5px, 0)}100%{opacity:1;transform:translate3D(0, 0, 0)}}@keyframes in-scale{0%{opacity:0;transform:scale3D(0.95, 0.95, 1)}100%{opacity: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;animation-fill-mode:both;animation-duration:var(--calcite-animation-timing)}.calcite-animate__in{animation-name:in}.calcite-animate__in-down{animation-name:in-down}.calcite-animate__in-up{animation-name:in-up}.calcite-animate__in-scale{animation-name:in-scale}@media (prefers-reduced-motion: reduce){:root{--calcite-internal-duration-factor:0.01}}:root{--calcite-floating-ui-transition:var(--calcite-animation-timing);--calcite-floating-ui-z-index:600}:host([hidden]){display:none}:host([disabled]){pointer-events:none;cursor:default;-webkit-user-select:none;user-select:none;opacity:var(--calcite-ui-opacity-disabled)}:host{margin-block-end:1px;box-sizing:border-box;display:flex;background-color:var(--calcite-ui-foreground-1);font-size:var(--calcite-font-size--1);color:var(--calcite-ui-text-2);--tw-shadow:0 1px 0 var(--calcite-ui-border-3);--tw-shadow-colored:0 1px 0 var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow);transition:background-color var(--calcite-animation-timing), box-shadow var(--calcite-animation-timing)}:host *{box-sizing:border-box}calcite-pick-list-item{position:relative;margin:0px;flex-grow:1;--tw-shadow:0 0 #0000;--tw-shadow-colored:0 0 #0000;box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow)}:host([active]),:host([selected]){--tw-shadow:0 0 0 1px var(--calcite-ui-brand);--tw-shadow-colored:0 0 0 1px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow)}.handle{display:flex;cursor:move;align-items:center;justify-content:center;border-style:none;background-color:transparent;padding-block:0px;padding-inline:0.25rem;color:var(--calcite-ui-border-input);outline-color:transparent}.handle:hover{background-color:var(--calcite-ui-foreground-2);color:var(--calcite-ui-text-1)}.handle:focus{outline:2px solid var(--calcite-ui-brand);outline-offset:-2px}.handle--activated{background-color:var(--calcite-ui-foreground-3);color:var(--calcite-ui-text-1)}.handle calcite-icon{color:inherit}:host([disabled]) ::slotted([calcite-hydrated][disabled]),:host([disabled]) [calcite-hydrated][disabled]{opacity:1}";export{J as calcite_value_list,N as calcite_value_list_item}
|
|
6
|
+
import{r as t,c as i,h as a,g as e,H as s}from"./p-983244bc.js";import{S as n}from"./p-ec5edf75.js";import{u as o}from"./p-9f094be8.js";import{s as r,a as c,c as l}from"./p-0e573040.js";import{c as h,d}from"./p-d70da26b.js";import{c as m}from"./p-53515d24.js";import{u,c as p,s as f,d as v}from"./p-2c2c6832.js";import{g,m as w,d as b,a as y,s as x,h as k,b as D,c as L,k as _,e as j,i as I,f as C,j as z,l as A,n as H,r as F,o as R,p as S,q as U,t as B,L as $,I as M,C as O,S as V}from"./p-460c2796.js";import{c as q,d as K}from"./p-25d10f33.js";import{g as T}from"./p-cff554c3.js";import{g as W}from"./p-1e3ad5b6.js";import"./p-83b37109.js";import"./p-fa1fa6dd.js";import"./p-53f86dbe.js";import"./p-ebd84c48.js";var E;function P(t,i,a){const{items:e,messages:s}=a,n=e.length,o=g(a,t)+1;return function(t,i,a,e){return t.replace("${position}",a.toString()).replace("${itemLabel}",i).replace("${total}",e.toString())}("idle"===i?s.dragHandleIdle:"active"===i?s.dragHandleActive:"change"===i?s.dragHandleChange:s.dragHandleCommit,t.label,o,n)}function G(t){return{handle:t.composedPath().find((t=>void 0!==t.dataset?.jsHandle)),item:t.composedPath().find((t=>"calcite-value-list-item"===t.tagName?.toLowerCase()))}}!function(t){t.grip="grip"}(E||(E={}));const J=class{constructor(a){t(this,a),this.calciteListChange=i(this,"calciteListChange",6),this.calciteListOrderChange=i(this,"calciteListOrderChange",6),this.calciteListFilter=i(this,"calciteListFilter",6),this.lastSelectedItem=null,this.mutationObserver=m("mutation",w.bind(this)),this.setFilterEl=t=>{this.filterEl=t},this.setFilteredItems=t=>{this.filteredItems=t},this.deselectRemovedItems=b.bind(this),this.deselectSiblingItems=y.bind(this),this.selectSiblings=x.bind(this),this.handleFilter=k.bind(this),this.handleFilterEvent=D.bind(this),this.getItemData=L.bind(this),this.keyDownHandler=t=>{if(t.defaultPrevented)return;const{handle:i,item:a}=G(t);if(i&&!a.handleActivated&&" "===t.key&&this.updateScreenReaderText(P(a,"commit",this)),!i||!a.handleActivated)return void _.call(this,t);t.preventDefault();const{items:e}=this;if(" "===t.key&&this.updateScreenReaderText(P(a,"active",this)),"ArrowUp"!==t.key&&"ArrowDown"!==t.key||e.length<=1)return;const{el:s}=this,n=j(this,a,"ArrowUp"===t.key?"up":"down");if(n===e.length-1)s.appendChild(a);else{const t=s.children[n];s.insertBefore(a,t===a.nextElementSibling?t.nextElementSibling:t)}this.items=this.getItems(),this.calciteListOrderChange.emit(this.items.map((({value:t})=>t))),requestAnimationFrame((()=>i?.focus())),a.handleActivated=!0,this.updateHandleAriaLabel(i,P(a,"change",this))},this.storeAssistiveEl=t=>{this.assistiveTextEl=t},this.handleFocusIn=t=>{const{handle:i,item:a}=G(t);!a?.handleActivated&&a&&i&&this.updateHandleAriaLabel(i,P(a,"idle",this))},this.disabled=!1,this.dragEnabled=!1,this.filteredItems=[],this.filteredData=[],this.filterEnabled=!1,this.filterPlaceholder=void 0,this.filterText=void 0,this.group=void 0,this.loading=!1,this.multiple=!1,this.selectionFollowsFocus=!1,this.messageOverrides=void 0,this.messages=void 0,this.dataForFilter=[],this.defaultMessages=void 0,this.effectiveLocale="",this.selectedValues=new Map}onMessagesChange(){}effectiveLocaleChange(){u(this,this.effectiveLocale)}connectedCallback(){h(this),p(this),I.call(this),C.call(this)}async componentWillLoad(){r(this),await f(this)}componentDidLoad(){c(this),this.setUpDragAndDrop(),z.call(this)}componentDidRender(){o(this)}disconnectedCallback(){d(this),v(this),A.call(this),this.cleanUpDragAndDrop()}calciteListFocusOutHandler(t){H.call(this,t)}calciteListItemRemoveHandler(t){F.call(this,t)}calciteListItemChangeHandler(t){R.call(this,t)}calciteInternalListItemPropsChangeHandler(t){t.stopPropagation(),this.setUpFilter()}calciteInternalListItemValueChangeHandler(t){S.call(this,t),t.stopPropagation()}getItems(){return Array.from(this.el.querySelectorAll("calcite-value-list-item"))}setUpItems(){U.call(this,"calcite-value-list-item")}setUpFilter(){this.filterEnabled&&(this.dataForFilter=this.getItemData())}setUpDragAndDrop(){this.cleanUpDragAndDrop(),this.dragEnabled&&(this.sortable=n.create(this.el,{dataIdAttr:"id",handle:".handle",draggable:"calcite-value-list-item",group:this.group,onSort:()=>{this.items=Array.from(this.el.querySelectorAll("calcite-value-list-item"));const t=this.items.map((t=>t.value));this.calciteListOrderChange.emit(t)}}))}cleanUpDragAndDrop(){this.sortable?.destroy(),this.sortable=null}handleBlur(){this.dragEnabled&&this.updateScreenReaderText("")}async getSelectedItems(){return this.selectedValues}async setFocus(t){return await l(this),B.call(this,t)}getIconType(){let t=null;return this.dragEnabled&&(t=E.grip),t}updateScreenReaderText(t){this.assistiveTextEl.textContent=t}updateHandleAriaLabel(t,i){t.ariaLabel=i}handleValueListItemBlur(t){const{item:i,handle:a}=t.detail;!i?.handleActivated&&i&&this.updateHandleAriaLabel(a,P(i,"idle",this)),t.stopPropagation()}render(){return a($,{onBlur:this.handleBlur,onFocusin:this.handleFocusIn,onKeyDown:this.keyDownHandler,props:this})}static get assetsDirs(){return["assets"]}get el(){return e(this)}static get watchers(){return{messageOverrides:["onMessagesChange"],effectiveLocale:["effectiveLocaleChange"]}}};J.style="@keyframes in{0%{opacity:0}100%{opacity:1}}@keyframes in-down{0%{opacity:0;transform:translate3D(0, -5px, 0)}100%{opacity:1;transform:translate3D(0, 0, 0)}}@keyframes in-up{0%{opacity:0;transform:translate3D(0, 5px, 0)}100%{opacity:1;transform:translate3D(0, 0, 0)}}@keyframes in-scale{0%{opacity:0;transform:scale3D(0.95, 0.95, 1)}100%{opacity: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;animation-fill-mode:both;animation-duration:var(--calcite-animation-timing)}.calcite-animate__in{animation-name:in}.calcite-animate__in-down{animation-name:in-down}.calcite-animate__in-up{animation-name:in-up}.calcite-animate__in-scale{animation-name:in-scale}@media (prefers-reduced-motion: reduce){:root{--calcite-internal-duration-factor:0.01}}:root{--calcite-floating-ui-transition:var(--calcite-animation-timing);--calcite-floating-ui-z-index:600}:host([hidden]){display:none}:host([disabled]){pointer-events:none;cursor:default;-webkit-user-select:none;user-select:none;opacity:var(--calcite-ui-opacity-disabled)}:host{position:relative;box-sizing:border-box;display:flex;flex-shrink:0;flex-grow:0;flex-direction:column;align-items:stretch;background-color:transparent;font-size:var(--calcite-font-size--1);color:var(--calcite-ui-text-2)}:host *{box-sizing:border-box}:host([disabled]) ::slotted([calcite-hydrated][disabled]),:host([disabled]) [calcite-hydrated][disabled]{opacity:1}calcite-value-list-item:last-of-type{--tw-shadow:0 0 #0000;--tw-shadow-colored:0 0 #0000;box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow)}:host([filter-enabled]) header{margin-block-end:0.25rem;display:flex;align-items:center;justify-content:flex-end;background-color:var(--calcite-ui-foreground-1);--tw-shadow:0 1px 0 var(--calcite-ui-border-3);--tw-shadow-colored:0 1px 0 var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow)}:host([filter-enabled]) header.sticky-pos{position:sticky;inset-block-start:0px;z-index:300}calcite-filter{margin-block-end:1px}.assistive-text{position:absolute;inline-size:1px;block-size:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0, 0, 0, 0);white-space:nowrap;border-width:0}";const N="actions-end",Q="actions-start",X=class{constructor(a){t(this,a),this.calciteListItemRemove=i(this,"calciteListItemRemove",7),this.calciteValueListItemDragHandleBlur=i(this,"calciteValueListItemDragHandleBlur",6),this.pickListItem=null,this.guid=`calcite-value-list-item-${W()}`,this.getPickListRef=t=>this.pickListItem=t,this.handleKeyDown=t=>{" "===t.key&&(this.handleActivated=!this.handleActivated)},this.handleBlur=()=>{this.handleActivated=!1,this.calciteValueListItemDragHandleBlur.emit({item:this.el,handle:this.handleEl})},this.handleSelectChange=t=>{this.selected=t.detail.selected},this.description=void 0,this.disabled=!1,this.deselectDisabled=!1,this.nonInteractive=!1,this.handleActivated=!1,this.icon=null,this.iconFlipRtl=!1,this.label=void 0,this.metadata=void 0,this.removable=!1,this.selected=!1,this.value=void 0}connectedCallback(){q(this)}disconnectedCallback(){K(this)}componentWillLoad(){r(this)}componentDidLoad(){c(this)}componentDidRender(){o(this,!!this.el.closest("calcite-value-list")&&"managed")}async toggleSelected(t){this.pickListItem.toggleSelected(t)}async setFocus(){await l(this),this.pickListItem?.setFocus()}calciteListItemChangeHandler(t){t.detail.item=this.el}renderActionsEnd(){const{el:t}=this;return T(t,N)?a("slot",{name:N,slot:V.actionsEnd}):null}renderActionsStart(){const{el:t}=this;return T(t,Q)?a("slot",{name:Q,slot:V.actionsStart}):null}renderHandle(){const{icon:t,iconFlipRtl:i}=this;if(t===M.grip)return a("span",{class:{[O.handle]:!0,[O.handleActivated]:this.handleActivated},"data-js-handle":!0,onBlur:this.handleBlur,onKeyDown:this.handleKeyDown,ref:t=>this.handleEl=t,role:"button",tabindex:"0"},a("calcite-icon",{flipRtl:i,icon:"drag",scale:"s"}))}render(){return a(s,{id:this.el.id||this.guid},this.renderHandle(),a("calcite-pick-list-item",{description:this.description,deselectDisabled:this.deselectDisabled,disabled:this.disabled,label:this.label,metadata:this.metadata,nonInteractive:this.nonInteractive,onCalciteListItemChange:this.handleSelectChange,removable:this.removable,selected:this.selected,value:this.value,ref:this.getPickListRef},this.renderActionsStart(),this.renderActionsEnd()))}get el(){return e(this)}};X.style="@keyframes in{0%{opacity:0}100%{opacity:1}}@keyframes in-down{0%{opacity:0;transform:translate3D(0, -5px, 0)}100%{opacity:1;transform:translate3D(0, 0, 0)}}@keyframes in-up{0%{opacity:0;transform:translate3D(0, 5px, 0)}100%{opacity:1;transform:translate3D(0, 0, 0)}}@keyframes in-scale{0%{opacity:0;transform:scale3D(0.95, 0.95, 1)}100%{opacity: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;animation-fill-mode:both;animation-duration:var(--calcite-animation-timing)}.calcite-animate__in{animation-name:in}.calcite-animate__in-down{animation-name:in-down}.calcite-animate__in-up{animation-name:in-up}.calcite-animate__in-scale{animation-name:in-scale}@media (prefers-reduced-motion: reduce){:root{--calcite-internal-duration-factor:0.01}}:root{--calcite-floating-ui-transition:var(--calcite-animation-timing);--calcite-floating-ui-z-index:600}:host([hidden]){display:none}:host([disabled]){pointer-events:none;cursor:default;-webkit-user-select:none;user-select:none;opacity:var(--calcite-ui-opacity-disabled)}:host{margin-block-end:1px;box-sizing:border-box;display:flex;background-color:var(--calcite-ui-foreground-1);font-size:var(--calcite-font-size--1);color:var(--calcite-ui-text-2);--tw-shadow:0 1px 0 var(--calcite-ui-border-3);--tw-shadow-colored:0 1px 0 var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow);transition:background-color var(--calcite-animation-timing), box-shadow var(--calcite-animation-timing)}:host *{box-sizing:border-box}calcite-pick-list-item{position:relative;margin:0px;flex-grow:1;--tw-shadow:0 0 #0000;--tw-shadow-colored:0 0 #0000;box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow)}:host([active]),:host([selected]){--tw-shadow:0 0 0 1px var(--calcite-ui-brand);--tw-shadow-colored:0 0 0 1px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow)}.handle{display:flex;cursor:move;align-items:center;justify-content:center;border-style:none;background-color:transparent;padding-block:0px;padding-inline:0.25rem;color:var(--calcite-ui-border-input);outline-color:transparent}.handle:hover{background-color:var(--calcite-ui-foreground-2);color:var(--calcite-ui-text-1)}.handle:focus{outline:2px solid var(--calcite-ui-brand);outline-offset:-2px}.handle--activated{background-color:var(--calcite-ui-foreground-3);color:var(--calcite-ui-text-1)}.handle calcite-icon{color:inherit}:host([disabled]) ::slotted([calcite-hydrated][disabled]),:host([disabled]) [calcite-hydrated][disabled]{opacity:1}";export{J as calcite_value_list,X as calcite_value_list_item}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/*!
|
|
2
2
|
* All material copyright ESRI, All Rights Reserved, unless otherwise specified.
|
|
3
3
|
* See https://github.com/Esri/calcite-components/blob/master/LICENSE.md for details.
|
|
4
|
-
* v1.1.
|
|
4
|
+
* v1.1.1-next.1
|
|
5
5
|
*/
|
|
6
|
-
import{a as n}from"./p-
|
|
6
|
+
import{a as n}from"./p-983244bc.js";import{g as t}from"./p-d70da26b.js";const s={};function o(){throw new Error("could not fetch component message bundle")}function c(n){n.messages={...n.defaultMessages,...n.messageOverrides}}async function a(n){n.defaultMessages=await i(n,n.effectiveLocale),c(n)}async function i(c,a){const{el:i}=c,e=i.tagName.toLowerCase().replace("calcite-","");return async function(t,c){const a=`${c}_${t}`;return s[a]||(s[a]=fetch(n(`./assets/${c}/t9n/messages_${t}.json`)).then((n=>(n.ok||o(),n.json()))).catch((()=>o()))),s[a]}(t(a,"t9n"),e)}async function e(n,t){n.defaultMessages=await i(n,t),c(n)}function u(n){n.onMessagesChange=r}function f(n){n.onMessagesChange=void 0}function r(){c(this)}export{u as c,f as d,a as s,e as u}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/*!
|
|
2
2
|
* All material copyright ESRI, All Rights Reserved, unless otherwise specified.
|
|
3
3
|
* See https://github.com/Esri/calcite-components/blob/master/LICENSE.md for details.
|
|
4
|
-
* v1.1.
|
|
4
|
+
* v1.1.1-next.1
|
|
5
5
|
*/
|
|
6
6
|
const t=(t,a,e)=>Math.max(a,Math.min(t,e)),a=new RegExp(/(?:\.(\d+))?(?:[eE]([+-]?\d+))?$/),e=t=>{const e=(""+t).match(a);return e?Math.max(0,(e[1]?e[1].length:0)-(e[2]?+e[2]:0)):0};export{t as c,e as d}
|