@esri/calcite-components 1.0.0-beta.72 → 1.0.0-beta.73
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/calcite/assets/calcite-icon/explore16.json +1 -0
- package/dist/calcite/assets/calcite-icon/explore24.json +1 -0
- package/dist/calcite/assets/calcite-icon/explore32.json +1 -0
- package/dist/calcite/assets/calcite-icon/partlyCloudy16.json +1 -0
- package/dist/calcite/assets/calcite-icon/partlyCloudy24.json +1 -0
- package/dist/calcite/assets/calcite-icon/partlyCloudy32.json +1 -0
- package/dist/calcite/assets/calcite-icon/rightAlign16.json +1 -0
- package/dist/calcite/assets/calcite-icon/rightAlign24.json +1 -0
- package/dist/calcite/assets/calcite-icon/rightAlign32.json +1 -0
- package/dist/calcite/assets/calcite-icon/screenshotMode16.json +1 -0
- package/dist/calcite/assets/calcite-icon/screenshotMode24.json +1 -0
- package/dist/calcite/assets/calcite-icon/screenshotMode32.json +1 -0
- package/dist/calcite/calcite.css +1 -1
- package/dist/calcite/calcite.esm.js +1 -1
- package/dist/calcite/calcite.js +1 -1
- package/dist/calcite/{p-a4a12ffb.system.entry.js → p-0134e87c.system.entry.js} +2 -2
- package/dist/calcite/p-02856c5a.system.entry.js +5 -0
- package/dist/calcite/p-04bf9bca.system.entry.js +5 -0
- package/dist/calcite/p-07284a52.system.js +5 -0
- package/dist/calcite/p-082c3059.system.entry.js +5 -0
- package/dist/calcite/p-0ac72794.system.entry.js +5 -0
- package/dist/calcite/p-0b187e6a.system.entry.js +5 -0
- package/dist/calcite/p-0d9a5d78.entry.js +5 -0
- package/dist/calcite/p-12c57970.js +5 -0
- package/dist/calcite/p-141c978b.system.entry.js +5 -0
- package/dist/calcite/p-1509da0f.system.entry.js +5 -0
- package/dist/calcite/p-15a38242.system.entry.js +5 -0
- package/dist/calcite/{p-2151c991.entry.js → p-18c9da83.entry.js} +1 -1
- package/dist/calcite/p-1ae01548.system.js +5 -0
- package/dist/calcite/p-1d26d522.system.entry.js +5 -0
- package/dist/calcite/p-2015299a.entry.js +5 -0
- package/dist/calcite/{p-27d9be53.entry.js → p-209f2049.entry.js} +1 -1
- package/dist/calcite/p-20d2db84.entry.js +5 -0
- package/dist/calcite/{p-a4784cf3.system.entry.js → p-227da2a5.system.entry.js} +1 -1
- package/dist/calcite/p-26481e18.js +5 -0
- package/dist/calcite/{p-0f2b51bf.system.js → p-26755e82.system.js} +1 -1
- package/dist/calcite/{p-f9e7371d.entry.js → p-2c278864.entry.js} +1 -1
- package/dist/calcite/p-2c3bbbb4.system.entry.js +5 -0
- package/dist/calcite/p-3366ef60.entry.js +5 -0
- package/dist/calcite/p-3baf4001.system.entry.js +5 -0
- package/dist/calcite/p-3c14f089.system.entry.js +5 -0
- package/dist/calcite/{p-66fda99e.entry.js → p-3c1841bd.entry.js} +1 -1
- package/dist/calcite/p-3c34f20d.system.js +5 -0
- package/dist/calcite/p-3e8cf990.entry.js +5 -0
- package/dist/calcite/p-3f51ac4b.system.entry.js +5 -0
- package/dist/calcite/p-4364e76a.system.js +5 -0
- package/dist/calcite/{p-fd255a24.entry.js → p-475b5015.entry.js} +1 -1
- package/dist/calcite/{p-eebd2bb0.entry.js → p-481366ac.entry.js} +1 -1
- package/dist/calcite/p-4aa28569.entry.js +5 -0
- package/dist/calcite/{p-d3bd900e.js → p-4f9b0b0f.js} +1 -1
- package/dist/calcite/p-4fee156d.system.entry.js +5 -0
- package/dist/calcite/{p-d3db2b58.system.entry.js → p-513bc44f.system.entry.js} +1 -1
- package/dist/calcite/p-54e07c75.entry.js +5 -0
- package/dist/calcite/p-557f31e6.system.entry.js +5 -0
- package/dist/calcite/{p-f4a7fa43.entry.js → p-55e6b0b2.entry.js} +1 -1
- package/dist/calcite/p-57555baa.system.entry.js +5 -0
- package/dist/calcite/p-59222393.entry.js +5 -0
- package/dist/calcite/{p-40e16f41.entry.js → p-5cce1e8b.entry.js} +1 -1
- package/dist/calcite/p-5d9fe852.entry.js +5 -0
- package/dist/calcite/p-5dcd2088.system.entry.js +5 -0
- package/dist/calcite/p-6173cf08.system.js +5 -0
- package/dist/calcite/{p-fc9025a2.entry.js → p-66ca7309.entry.js} +1 -1
- package/dist/calcite/{p-30036f23.system.entry.js → p-6c453fd0.system.entry.js} +1 -1
- package/dist/calcite/p-6cd93563.entry.js +5 -0
- package/dist/calcite/p-6dbcd698.system.entry.js +5 -0
- package/dist/calcite/p-6e0fd056.entry.js +5 -0
- package/dist/calcite/p-6f0c4739.system.entry.js +5 -0
- package/dist/calcite/p-6fb2082b.entry.js +5 -0
- package/dist/calcite/{p-ce704ece.js → p-7017ca05.js} +1 -1
- package/dist/calcite/p-70566b09.system.entry.js +5 -0
- package/dist/calcite/p-732a0005.system.entry.js +5 -0
- package/dist/calcite/p-74365957.system.entry.js +5 -0
- package/dist/calcite/p-748c198c.system.entry.js +5 -0
- package/dist/calcite/p-765d6b57.system.entry.js +5 -0
- package/dist/calcite/{p-444ecda9.entry.js → p-770c1d6b.entry.js} +1 -1
- package/dist/calcite/p-7a2142c2.system.entry.js +5 -0
- package/dist/calcite/p-7a28e833.system.entry.js +5 -0
- package/dist/calcite/p-7bd71ff0.system.entry.js +5 -0
- package/dist/calcite/{p-8ebc2d51.entry.js → p-805c94b9.entry.js} +1 -1
- package/dist/calcite/p-83d41684.entry.js +5 -0
- package/dist/calcite/{p-8c4b6059.system.entry.js → p-84738edb.system.entry.js} +1 -1
- package/dist/calcite/p-869eb8f9.entry.js +5 -0
- package/dist/calcite/{p-04cc8259.entry.js → p-8e1945e3.entry.js} +1 -1
- package/dist/calcite/p-90f7c357.system.entry.js +5 -0
- package/dist/calcite/p-917e53a2.system.entry.js +5 -0
- package/dist/calcite/p-92ad7d95.entry.js +5 -0
- package/dist/calcite/p-94398466.system.entry.js +5 -0
- package/dist/calcite/{p-18d9a261.system.js → p-99d32fc3.system.js} +1 -1
- package/dist/calcite/p-9acd0a18.entry.js +5 -0
- package/dist/calcite/p-a348ffb1.system.entry.js +5 -0
- package/dist/calcite/p-a57bd5e6.entry.js +5 -0
- package/dist/calcite/p-a76aa7d2.system.entry.js +5 -0
- package/dist/calcite/{p-0b45733b.entry.js → p-a7f8b343.entry.js} +1 -1
- package/dist/calcite/p-a88d8075.entry.js +5 -0
- package/dist/calcite/p-ac234622.system.entry.js +5 -0
- package/dist/calcite/p-ae224016.system.entry.js +5 -0
- package/dist/calcite/p-afa72097.system.entry.js +5 -0
- package/dist/calcite/p-b01c3a89.system.entry.js +5 -0
- package/dist/calcite/{p-d8039e8a.system.entry.js → p-b1a43a5f.system.entry.js} +1 -1
- package/dist/calcite/p-b55fa7bc.entry.js +5 -0
- package/dist/calcite/p-b5bb4618.system.entry.js +5 -0
- package/dist/calcite/p-b63dfa63.entry.js +5 -0
- package/dist/calcite/p-bb4dcd31.js +5 -0
- package/dist/calcite/{p-f25f139a.entry.js → p-bc85a791.entry.js} +1 -1
- package/dist/calcite/{p-e0b1e90c.entry.js → p-bccf787f.entry.js} +1 -1
- package/dist/calcite/{p-9a8f3883.entry.js → p-bfd9f64a.entry.js} +1 -1
- package/dist/calcite/p-c077d664.entry.js +5 -0
- package/dist/calcite/p-c3124245.system.entry.js +5 -0
- package/dist/calcite/p-c5761666.entry.js +5 -0
- package/dist/calcite/p-c7b8a068.entry.js +5 -0
- package/dist/calcite/{p-523bc291.system.js → p-cbea8bac.system.js} +1 -1
- package/dist/calcite/p-cc63f8f9.entry.js +5 -0
- package/dist/calcite/p-cd54c8d0.system.entry.js +5 -0
- package/dist/calcite/{p-bca0b34f.entry.js → p-cfcb2161.entry.js} +1 -1
- package/dist/calcite/p-d00fbd1e.entry.js +5 -0
- package/dist/calcite/{p-4f7ebefc.system.js → p-d4bafc77.system.js} +1 -1
- package/dist/calcite/p-d5b221b1.entry.js +5 -0
- package/dist/calcite/p-d6bfa9b1.entry.js +5 -0
- package/dist/calcite/{p-7ff5e336.entry.js → p-d6e8d643.entry.js} +1 -1
- package/dist/calcite/p-d8653ba3.entry.js +5 -0
- package/dist/calcite/p-db85eed9.entry.js +5 -0
- package/dist/calcite/{p-b437a8eb.system.entry.js → p-dba7c714.system.entry.js} +1 -1
- package/dist/calcite/p-dd9f2e61.js +5 -0
- package/dist/calcite/p-e2094dff.system.entry.js +5 -0
- package/dist/calcite/p-e426746f.system.entry.js +5 -0
- package/dist/calcite/p-e5130ebf.system.entry.js +5 -0
- package/dist/calcite/p-e62edb4d.system.entry.js +5 -0
- package/dist/calcite/{p-f72c037c.entry.js → p-e63f0806.entry.js} +1 -1
- package/dist/calcite/p-e7103edc.entry.js +5 -0
- package/dist/calcite/p-e8270c76.system.entry.js +5 -0
- package/dist/calcite/p-eca26cba.system.entry.js +5 -0
- package/dist/calcite/p-ef6f8370.entry.js +5 -0
- package/dist/calcite/{p-87327c2f.system.entry.js → p-f26cad61.system.entry.js} +1 -1
- package/dist/calcite/p-f3b489d9.js +5 -0
- package/dist/calcite/p-f3d02833.js +5 -0
- package/dist/calcite/{p-f39dc5fd.entry.js → p-f5739197.entry.js} +1 -1
- package/dist/calcite/p-f63b9411.entry.js +5 -0
- package/dist/calcite/p-f70f5521.system.entry.js +5 -0
- package/dist/calcite/{p-d9414082.system.entry.js → p-f763b1e7.system.entry.js} +1 -1
- package/dist/calcite/p-f87c1273.js +5 -0
- package/dist/calcite/p-f8c99ef3.system.entry.js +5 -0
- package/dist/calcite/p-f8f128a2.entry.js +5 -0
- package/dist/calcite/{p-f1f65708.entry.js → p-f95fb85f.entry.js} +1 -1
- package/dist/calcite/{p-a2a22cbc.entry.js → p-fc3c1e91.entry.js} +1 -1
- package/dist/calcite/p-fcde21ce.system.js +5 -0
- package/dist/calcite/p-fdd3ea5e.entry.js +5 -0
- package/dist/calcite/{p-06ddf228.entry.js → p-fe3fff79.entry.js} +1 -1
- package/dist/calcite/p-fee9511c.system.entry.js +5 -0
- package/dist/cjs/{CalciteExpandToggle-d654421a.js → CalciteExpandToggle-38ca208f.js} +1 -1
- package/dist/cjs/calcite-accordion_2.cjs.entry.js +3 -3
- package/dist/cjs/calcite-action-bar.cjs.entry.js +3 -3
- package/dist/cjs/calcite-action-group.cjs.entry.js +2 -2
- package/dist/cjs/calcite-action-menu.cjs.entry.js +2 -2
- package/dist/cjs/calcite-action-pad.cjs.entry.js +3 -3
- package/dist/cjs/calcite-action.cjs.entry.js +1 -1
- package/dist/cjs/calcite-alert.cjs.entry.js +3 -3
- package/dist/cjs/calcite-avatar.cjs.entry.js +2 -2
- package/dist/cjs/calcite-block_2.cjs.entry.js +3 -3
- package/dist/cjs/calcite-button.cjs.entry.js +3 -3
- package/dist/cjs/calcite-card.cjs.entry.js +1 -1
- package/dist/cjs/calcite-checkbox.cjs.entry.js +5 -5
- package/dist/cjs/calcite-chip.cjs.entry.js +2 -2
- package/dist/cjs/calcite-color-picker_3.cjs.entry.js +4 -4
- package/dist/cjs/calcite-combobox_3.cjs.entry.js +7 -7
- package/dist/cjs/calcite-date-picker_4.cjs.entry.js +15 -14
- package/dist/cjs/calcite-dropdown_3.cjs.entry.js +5 -5
- package/dist/cjs/calcite-fab.cjs.entry.js +2 -2
- package/dist/cjs/calcite-filter.cjs.entry.js +2 -2
- package/dist/cjs/calcite-flow.cjs.entry.js +1 -1
- package/dist/cjs/calcite-graph_2.cjs.entry.js +5 -5
- package/dist/cjs/calcite-handle.cjs.entry.js +1 -1
- package/dist/cjs/calcite-icon.cjs.entry.js +2 -2
- package/dist/cjs/calcite-inline-editable.cjs.entry.js +3 -3
- package/dist/cjs/calcite-input-date-picker.cjs.entry.js +9 -9
- package/dist/cjs/calcite-input-message.cjs.entry.js +2 -2
- package/dist/cjs/calcite-input-time-picker_2.cjs.entry.js +9 -9
- package/dist/cjs/calcite-input.cjs.entry.js +28 -18
- package/dist/cjs/calcite-label.cjs.entry.js +1 -1
- package/dist/cjs/calcite-link.cjs.entry.js +2 -2
- package/dist/cjs/calcite-list_3.cjs.entry.js +4 -4
- package/dist/cjs/calcite-loader.cjs.entry.js +1 -1
- package/dist/cjs/calcite-modal.cjs.entry.js +2 -2
- package/dist/cjs/calcite-notice.cjs.entry.js +2 -2
- package/dist/cjs/calcite-option_3.cjs.entry.js +6 -6
- package/dist/cjs/calcite-pagination.cjs.entry.js +1 -1
- package/dist/cjs/calcite-panel.cjs.entry.js +2 -2
- package/dist/cjs/calcite-pick-list_3.cjs.entry.js +6 -5
- package/dist/cjs/calcite-popover_2.cjs.entry.js +6 -6
- package/dist/cjs/calcite-progress.cjs.entry.js +1 -1
- package/dist/cjs/calcite-radio-button-group.cjs.entry.js +1 -1
- package/dist/cjs/calcite-radio-button.cjs.entry.js +20 -9
- package/dist/cjs/calcite-radio-group_2.cjs.entry.js +5 -50
- package/dist/cjs/calcite-rating.cjs.entry.js +4 -4
- package/dist/cjs/calcite-scrim.cjs.entry.js +1 -1
- package/dist/cjs/calcite-shell_3.cjs.entry.js +4 -4
- package/dist/cjs/calcite-sortable-list.cjs.entry.js +1 -1
- package/dist/cjs/calcite-split-button.cjs.entry.js +1 -1
- package/dist/cjs/calcite-stepper_2.cjs.entry.js +3 -3
- package/dist/cjs/calcite-switch.cjs.entry.js +4 -4
- package/dist/cjs/calcite-tab_4.cjs.entry.js +5 -5
- package/dist/cjs/calcite-tile-select_2.cjs.entry.js +38 -3
- package/dist/cjs/calcite-tile.cjs.entry.js +2 -2
- package/dist/cjs/calcite-tip_3.cjs.entry.js +4 -4
- package/dist/cjs/calcite-tooltip_2.cjs.entry.js +6 -6
- package/dist/cjs/calcite-tree_2.cjs.entry.js +3 -3
- package/dist/cjs/calcite-value-list_2.cjs.entry.js +13 -6
- package/dist/cjs/calcite.cjs.js +1 -1
- package/dist/cjs/{dom-19822169.js → dom-db7722f2.js} +25 -8
- package/dist/cjs/{form-a5b44a1f.js → form-ad18d4fc.js} +1 -1
- package/dist/cjs/{label-8e3552b2.js → label-4776bb0e.js} +5 -2
- package/dist/cjs/loader.cjs.js +1 -1
- package/dist/cjs/locale-b9b153dd.js +127 -0
- package/dist/cjs/number-e813e801.js +84 -0
- package/dist/cjs/{popper-a7580aca.js → popper-adfdc032.js} +29 -10
- package/dist/cjs/{resources-6c4b32ef.js → resources-8273cb31.js} +13 -2
- package/dist/cjs/{resources-16974e48.js → resources-c524c005.js} +1 -1
- package/dist/collection/collection-manifest.json +1 -1
- package/dist/collection/components/calcite-accordion/calcite-accordion.css +3 -13
- package/dist/collection/components/calcite-accordion/calcite-accordion.js +1 -1
- package/dist/collection/components/calcite-accordion-item/calcite-accordion-item.css +31 -61
- package/dist/collection/components/calcite-accordion-item/calcite-accordion-item.js +1 -1
- package/dist/collection/components/calcite-action/calcite-action.css +46 -91
- package/dist/collection/components/calcite-action-bar/calcite-action-bar.css +7 -18
- package/dist/collection/components/calcite-action-group/calcite-action-group.css +5 -18
- package/dist/collection/components/calcite-action-menu/calcite-action-menu.css +11 -23
- package/dist/collection/components/calcite-action-pad/calcite-action-pad.css +26 -25
- package/dist/collection/components/calcite-alert/calcite-alert.css +56 -104
- package/dist/collection/components/calcite-alert/calcite-alert.js +1 -1
- package/dist/collection/components/calcite-avatar/calcite-avatar.css +8 -20
- package/dist/collection/components/calcite-block/calcite-block.css +43 -53
- package/dist/collection/components/calcite-block-section/calcite-block-section.css +25 -41
- package/dist/collection/components/calcite-button/calcite-button.css +83 -226
- package/dist/collection/components/calcite-card/calcite-card.css +49 -60
- package/dist/collection/components/calcite-checkbox/calcite-checkbox.css +11 -24
- package/dist/collection/components/calcite-checkbox/calcite-checkbox.js +1 -1
- package/dist/collection/components/calcite-chip/calcite-chip.css +18 -41
- package/dist/collection/components/calcite-color-picker/calcite-color-picker.css +11 -41
- package/dist/collection/components/calcite-color-picker-hex-input/calcite-color-picker-hex-input.css +7 -17
- package/dist/collection/components/calcite-color-picker-swatch/calcite-color-picker-swatch.css +7 -18
- package/dist/collection/components/calcite-combobox/calcite-combobox.css +28 -47
- package/dist/collection/components/calcite-combobox-item/calcite-combobox-item.css +34 -41
- package/dist/collection/components/calcite-combobox-item-group/calcite-combobox-item-group.css +8 -19
- package/dist/collection/components/calcite-date-picker/calcite-date-picker.css +4 -14
- package/dist/collection/components/calcite-date-picker/calcite-date-picker.js +7 -6
- package/dist/collection/components/calcite-date-picker-day/calcite-date-picker-day.css +37 -59
- package/dist/collection/components/calcite-date-picker-month/calcite-date-picker-month.css +21 -31
- package/dist/collection/components/calcite-date-picker-month-header/calcite-date-picker-month-header.css +34 -56
- package/dist/collection/components/calcite-dropdown/calcite-dropdown.css +3 -20
- package/dist/collection/components/calcite-dropdown-group/calcite-dropdown-group.css +10 -20
- package/dist/collection/components/calcite-dropdown-item/calcite-dropdown-item.css +48 -59
- package/dist/collection/components/calcite-fab/calcite-fab.css +10 -16
- package/dist/collection/components/calcite-filter/calcite-filter.css +20 -34
- package/dist/collection/components/calcite-flow/calcite-flow.css +22 -34
- package/dist/collection/components/calcite-graph/calcite-graph.css +3 -14
- package/dist/collection/components/calcite-handle/calcite-handle.css +4 -18
- package/dist/collection/components/calcite-icon/assets/calcite-icon/explore16.json +1 -0
- package/dist/collection/components/calcite-icon/assets/calcite-icon/explore24.json +1 -0
- package/dist/collection/components/calcite-icon/assets/calcite-icon/explore32.json +1 -0
- package/dist/collection/components/calcite-icon/assets/calcite-icon/partlyCloudy16.json +1 -0
- package/dist/collection/components/calcite-icon/assets/calcite-icon/partlyCloudy24.json +1 -0
- package/dist/collection/components/calcite-icon/assets/calcite-icon/partlyCloudy32.json +1 -0
- package/dist/collection/components/calcite-icon/assets/calcite-icon/rightAlign16.json +1 -0
- package/dist/collection/components/calcite-icon/assets/calcite-icon/rightAlign24.json +1 -0
- package/dist/collection/components/calcite-icon/assets/calcite-icon/rightAlign32.json +1 -0
- package/dist/collection/components/calcite-icon/assets/calcite-icon/screenshotMode16.json +1 -0
- package/dist/collection/components/calcite-icon/assets/calcite-icon/screenshotMode24.json +1 -0
- package/dist/collection/components/calcite-icon/assets/calcite-icon/screenshotMode32.json +1 -0
- package/dist/collection/components/calcite-icon/calcite-icon.css +12 -14
- package/dist/collection/components/calcite-inline-editable/calcite-inline-editable.css +5 -12
- package/dist/collection/components/calcite-input/calcite-input.css +94 -156
- package/dist/collection/components/calcite-input/calcite-input.js +22 -12
- package/dist/collection/components/calcite-input-date-picker/calcite-input-date-picker.css +28 -46
- package/dist/collection/components/calcite-input-date-picker/calcite-input-date-picker.js +1 -1
- package/dist/collection/components/calcite-input-message/calcite-input-message.css +12 -23
- package/dist/collection/components/calcite-input-time-picker/calcite-input-time-picker.css +1 -11
- package/dist/collection/components/calcite-input-time-picker/calcite-input-time-picker.js +2 -2
- package/dist/collection/components/calcite-label/calcite-label.css +19 -34
- package/dist/collection/components/calcite-link/calcite-link.css +16 -33
- package/dist/collection/components/calcite-list/calcite-list.css +9 -16
- package/dist/collection/components/calcite-list-item/calcite-list-item.css +23 -46
- package/dist/collection/components/calcite-list-item-group/calcite-list-item-group.css +7 -17
- package/dist/collection/components/calcite-loader/calcite-loader.css +37 -62
- package/dist/collection/components/calcite-modal/calcite-modal.css +95 -102
- package/dist/collection/components/calcite-notice/calcite-notice.css +43 -81
- package/dist/collection/components/calcite-option/calcite-option.css +1 -11
- package/dist/collection/components/calcite-option-group/calcite-option-group.css +1 -11
- package/dist/collection/components/calcite-pagination/calcite-pagination.css +20 -54
- package/dist/collection/components/calcite-panel/calcite-panel.css +50 -73
- package/dist/collection/components/calcite-pick-list/calcite-pick-list.css +16 -26
- package/dist/collection/components/calcite-pick-list/calcite-pick-list.js +12 -4
- package/dist/collection/components/calcite-pick-list/resources.js +1 -1
- package/dist/collection/components/calcite-pick-list/shared-list-logic.js +10 -0
- package/dist/collection/components/calcite-pick-list-group/calcite-pick-list-group.css +14 -27
- package/dist/collection/components/calcite-pick-list-item/calcite-pick-list-item.css +43 -60
- package/dist/collection/components/calcite-popover/calcite-popover.css +24 -34
- package/dist/collection/components/calcite-popover/calcite-popover.js +1 -1
- package/dist/collection/components/calcite-popover-manager/calcite-popover-manager.css +1 -11
- package/dist/collection/components/calcite-popover-manager/calcite-popover-manager.js +1 -1
- package/dist/collection/components/calcite-progress/calcite-progress.css +7 -20
- package/dist/collection/components/calcite-radio-button/calcite-radio-button.css +8 -21
- package/dist/collection/components/calcite-radio-button/calcite-radio-button.js +16 -5
- package/dist/collection/components/calcite-radio-button-group/calcite-radio-button-group.css +1 -14
- package/dist/collection/components/calcite-radio-group/calcite-radio-group.css +3 -15
- package/dist/collection/components/calcite-radio-group-item/calcite-radio-group-item.css +17 -28
- package/dist/collection/components/calcite-radio-group-item/calcite-radio-group-item.js +0 -45
- package/dist/collection/components/calcite-rating/calcite-rating.css +10 -24
- package/dist/collection/components/calcite-scrim/calcite-scrim.css +17 -29
- package/dist/collection/components/calcite-select/calcite-select.css +23 -39
- package/dist/collection/components/calcite-shell/calcite-shell.css +43 -43
- package/dist/collection/components/calcite-shell-center-row/calcite-shell-center-row.css +26 -21
- package/dist/collection/components/calcite-shell-panel/calcite-shell-panel.css +33 -52
- package/dist/collection/components/calcite-slider/calcite-slider.css +45 -93
- package/dist/collection/components/calcite-sortable-list/calcite-sortable-list.css +1 -11
- package/dist/collection/components/calcite-split-button/calcite-split-button.css +7 -27
- package/dist/collection/components/calcite-stepper/calcite-stepper.css +8 -18
- package/dist/collection/components/calcite-stepper-item/calcite-stepper-item.css +38 -72
- package/dist/collection/components/calcite-switch/calcite-switch.css +24 -47
- package/dist/collection/components/calcite-tab/calcite-tab.css +10 -20
- package/dist/collection/components/calcite-tab-nav/calcite-tab-nav.css +13 -23
- package/dist/collection/components/calcite-tab-title/calcite-tab-title.css +40 -65
- package/dist/collection/components/calcite-tabs/calcite-tabs.css +3 -13
- package/dist/collection/components/calcite-tile/calcite-tile.css +52 -85
- package/dist/collection/components/calcite-tile-select/calcite-tile-select.css +52 -87
- package/dist/collection/components/calcite-tile-select/calcite-tile-select.js +21 -2
- package/dist/collection/components/calcite-tile-select/resources.js +20 -0
- package/dist/collection/components/calcite-tile-select-group/calcite-tile-select-group.css +1 -12
- package/dist/collection/components/calcite-time-picker/calcite-time-picker.css +15 -47
- package/dist/collection/components/calcite-time-picker/calcite-time-picker.js +4 -4
- package/dist/collection/components/calcite-tip/calcite-tip.css +20 -36
- package/dist/collection/components/calcite-tip-group/calcite-tip-group.css +4 -14
- package/dist/collection/components/calcite-tip-manager/calcite-tip-manager.css +34 -49
- package/dist/collection/components/calcite-tooltip/calcite-tooltip.css +12 -20
- package/dist/collection/components/calcite-tooltip/calcite-tooltip.js +1 -1
- package/dist/collection/components/calcite-tooltip-manager/calcite-tooltip-manager.css +1 -11
- package/dist/collection/components/calcite-tooltip-manager/calcite-tooltip-manager.js +1 -1
- package/dist/collection/components/calcite-tree/calcite-tree.css +1 -11
- package/dist/collection/components/calcite-tree-item/calcite-tree-item.css +22 -58
- package/dist/collection/components/calcite-value-list/calcite-value-list.css +17 -25
- package/dist/collection/components/calcite-value-list/calcite-value-list.js +22 -8
- package/dist/collection/components/calcite-value-list-item/calcite-value-list-item.css +22 -33
- package/dist/collection/utils/dom.js +25 -8
- package/dist/collection/utils/label.js +4 -1
- package/dist/collection/utils/locale.js +42 -38
- package/dist/collection/utils/number.js +48 -23
- package/dist/components/calcite-accordion-item.js +1 -1
- package/dist/components/calcite-accordion.js +1 -1
- package/dist/components/calcite-action-bar.js +1 -1
- package/dist/components/calcite-action-group2.js +1 -1
- package/dist/components/calcite-action-menu2.js +1 -1
- package/dist/components/calcite-action-pad.js +1 -1
- package/dist/components/calcite-action2.js +1 -1
- package/dist/components/calcite-alert.js +2 -2
- 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-button2.js +1 -1
- package/dist/components/calcite-card.js +1 -1
- package/dist/components/calcite-checkbox2.js +2 -2
- package/dist/components/calcite-chip2.js +1 -1
- package/dist/components/calcite-color-picker-hex-input2.js +1 -1
- package/dist/components/calcite-color-picker-swatch2.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-day2.js +1 -1
- package/dist/components/calcite-date-picker-month-header2.js +1 -1
- package/dist/components/calcite-date-picker-month2.js +1 -1
- package/dist/components/calcite-date-picker2.js +8 -7
- package/dist/components/calcite-dropdown-group.js +1 -1
- package/dist/components/calcite-dropdown-item.js +1 -1
- package/dist/components/calcite-dropdown2.js +1 -1
- package/dist/components/calcite-fab.js +1 -1
- package/dist/components/calcite-filter2.js +1 -1
- package/dist/components/calcite-flow.js +1 -1
- package/dist/components/calcite-graph2.js +1 -1
- package/dist/components/calcite-handle2.js +1 -1
- package/dist/components/calcite-icon2.js +1 -1
- package/dist/components/calcite-inline-editable.js +1 -1
- package/dist/components/calcite-input-date-picker.js +2 -2
- package/dist/components/calcite-input-message.js +1 -1
- package/dist/components/calcite-input-time-picker.js +2 -2
- package/dist/components/calcite-input2.js +23 -13
- package/dist/components/calcite-label2.js +1 -1
- package/dist/components/calcite-link2.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-loader2.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-item2.js +1 -1
- package/dist/components/calcite-pick-list.js +3 -2
- package/dist/components/calcite-popover-manager.js +2 -2
- package/dist/components/calcite-popover2.js +2 -2
- package/dist/components/calcite-progress2.js +1 -1
- package/dist/components/calcite-radio-button-group.js +1 -1
- package/dist/components/calcite-radio-button.js +17 -6
- package/dist/components/calcite-radio-group-item.js +1 -46
- package/dist/components/calcite-radio-group.js +1 -1
- package/dist/components/calcite-rating.js +1 -1
- package/dist/components/calcite-scrim2.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-switch2.js +1 -1
- package/dist/components/calcite-tab-nav2.js +1 -1
- package/dist/components/calcite-tab-title2.js +1 -1
- package/dist/components/calcite-tab2.js +1 -1
- package/dist/components/calcite-tabs2.js +1 -1
- package/dist/components/calcite-tile-select-group.js +1 -1
- package/dist/components/calcite-tile-select.js +37 -2
- package/dist/components/calcite-tile2.js +1 -1
- package/dist/components/calcite-time-picker2.js +4 -4
- 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-manager2.js +2 -2
- package/dist/components/calcite-tooltip.js +2 -2
- 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 +11 -4
- package/dist/components/dom.js +25 -8
- package/dist/components/label.js +4 -1
- package/dist/components/locale.js +42 -38
- package/dist/components/number.js +49 -24
- package/dist/components/popper.js +28 -9
- package/dist/components/resources3.js +1 -1
- package/dist/components/shared-list-render.js +11 -1
- package/dist/custom-elements/index.js +603 -504
- package/dist/esm/{CalciteExpandToggle-c33bd6fd.js → CalciteExpandToggle-1b1bf600.js} +1 -1
- package/dist/esm/calcite-accordion_2.entry.js +3 -3
- package/dist/esm/calcite-action-bar.entry.js +3 -3
- package/dist/esm/calcite-action-group.entry.js +2 -2
- package/dist/esm/calcite-action-menu.entry.js +2 -2
- package/dist/esm/calcite-action-pad.entry.js +3 -3
- package/dist/esm/calcite-action.entry.js +1 -1
- package/dist/esm/calcite-alert.entry.js +3 -3
- package/dist/esm/calcite-avatar.entry.js +2 -2
- package/dist/esm/calcite-block_2.entry.js +3 -3
- package/dist/esm/calcite-button.entry.js +3 -3
- package/dist/esm/calcite-card.entry.js +1 -1
- package/dist/esm/calcite-checkbox.entry.js +5 -5
- package/dist/esm/calcite-chip.entry.js +2 -2
- package/dist/esm/calcite-color-picker_3.entry.js +4 -4
- package/dist/esm/calcite-combobox_3.entry.js +7 -7
- package/dist/esm/calcite-date-picker_4.entry.js +15 -14
- package/dist/esm/calcite-dropdown_3.entry.js +5 -5
- package/dist/esm/calcite-fab.entry.js +2 -2
- package/dist/esm/calcite-filter.entry.js +2 -2
- package/dist/esm/calcite-flow.entry.js +1 -1
- package/dist/esm/calcite-graph_2.entry.js +5 -5
- package/dist/esm/calcite-handle.entry.js +1 -1
- package/dist/esm/calcite-icon.entry.js +2 -2
- package/dist/esm/calcite-inline-editable.entry.js +3 -3
- package/dist/esm/calcite-input-date-picker.entry.js +9 -9
- package/dist/esm/calcite-input-message.entry.js +2 -2
- package/dist/esm/calcite-input-time-picker_2.entry.js +9 -9
- package/dist/esm/calcite-input.entry.js +28 -18
- package/dist/esm/calcite-label.entry.js +1 -1
- package/dist/esm/calcite-link.entry.js +2 -2
- package/dist/esm/calcite-list_3.entry.js +4 -4
- package/dist/esm/calcite-loader.entry.js +1 -1
- package/dist/esm/calcite-modal.entry.js +2 -2
- package/dist/esm/calcite-notice.entry.js +2 -2
- package/dist/esm/calcite-option_3.entry.js +6 -6
- package/dist/esm/calcite-pagination.entry.js +1 -1
- package/dist/esm/calcite-panel.entry.js +2 -2
- package/dist/esm/calcite-pick-list_3.entry.js +6 -5
- package/dist/esm/calcite-popover_2.entry.js +6 -6
- package/dist/esm/calcite-progress.entry.js +1 -1
- package/dist/esm/calcite-radio-button-group.entry.js +1 -1
- package/dist/esm/calcite-radio-button.entry.js +20 -9
- package/dist/esm/calcite-radio-group_2.entry.js +5 -50
- package/dist/esm/calcite-rating.entry.js +4 -4
- package/dist/esm/calcite-scrim.entry.js +1 -1
- package/dist/esm/calcite-shell_3.entry.js +4 -4
- package/dist/esm/calcite-sortable-list.entry.js +1 -1
- package/dist/esm/calcite-split-button.entry.js +1 -1
- package/dist/esm/calcite-stepper_2.entry.js +3 -3
- package/dist/esm/calcite-switch.entry.js +4 -4
- package/dist/esm/calcite-tab_4.entry.js +5 -5
- package/dist/esm/calcite-tile-select_2.entry.js +38 -3
- package/dist/esm/calcite-tile.entry.js +2 -2
- package/dist/esm/calcite-tip_3.entry.js +4 -4
- package/dist/esm/calcite-tooltip_2.entry.js +6 -6
- package/dist/esm/calcite-tree_2.entry.js +3 -3
- package/dist/esm/calcite-value-list_2.entry.js +13 -6
- package/dist/esm/calcite.js +1 -1
- package/dist/esm/{dom-f24e866c.js → dom-e55f9eaf.js} +25 -8
- package/dist/esm/{form-160b0fb5.js → form-147bc6d7.js} +1 -1
- package/dist/esm/{label-5559055d.js → label-240ef148.js} +5 -2
- package/dist/esm/loader.js +1 -1
- package/dist/esm/locale-1b48f64f.js +122 -0
- package/dist/esm/number-8779395f.js +76 -0
- package/dist/esm/{popper-f5caedc4.js → popper-1814b3c1.js} +29 -10
- package/dist/esm/{resources-b4eee1d4.js → resources-74c807b4.js} +1 -1
- package/dist/esm/{resources-35c1823f.js → resources-a6abee37.js} +13 -3
- package/dist/esm-es5/{CalciteExpandToggle-c33bd6fd.js → CalciteExpandToggle-1b1bf600.js} +1 -1
- package/dist/esm-es5/calcite-accordion_2.entry.js +1 -1
- package/dist/esm-es5/calcite-action-bar.entry.js +1 -1
- package/dist/esm-es5/calcite-action-group.entry.js +1 -1
- package/dist/esm-es5/calcite-action-menu.entry.js +1 -1
- package/dist/esm-es5/calcite-action-pad.entry.js +1 -1
- package/dist/esm-es5/calcite-action.entry.js +1 -1
- package/dist/esm-es5/calcite-alert.entry.js +1 -1
- package/dist/esm-es5/calcite-avatar.entry.js +1 -1
- package/dist/esm-es5/calcite-block_2.entry.js +1 -1
- package/dist/esm-es5/calcite-button.entry.js +1 -1
- package/dist/esm-es5/calcite-card.entry.js +1 -1
- package/dist/esm-es5/calcite-checkbox.entry.js +2 -2
- package/dist/esm-es5/calcite-chip.entry.js +2 -2
- package/dist/esm-es5/calcite-color-picker_3.entry.js +1 -1
- package/dist/esm-es5/calcite-combobox_3.entry.js +2 -2
- package/dist/esm-es5/calcite-date-picker_4.entry.js +2 -2
- package/dist/esm-es5/calcite-dropdown_3.entry.js +1 -1
- package/dist/esm-es5/calcite-fab.entry.js +2 -2
- package/dist/esm-es5/calcite-filter.entry.js +2 -2
- package/dist/esm-es5/calcite-flow.entry.js +2 -2
- package/dist/esm-es5/calcite-graph_2.entry.js +1 -1
- package/dist/esm-es5/calcite-handle.entry.js +2 -2
- package/dist/esm-es5/calcite-icon.entry.js +1 -1
- package/dist/esm-es5/calcite-inline-editable.entry.js +1 -1
- package/dist/esm-es5/calcite-input-date-picker.entry.js +1 -1
- package/dist/esm-es5/calcite-input-message.entry.js +1 -1
- package/dist/esm-es5/calcite-input-time-picker_2.entry.js +1 -1
- package/dist/esm-es5/calcite-input.entry.js +1 -1
- package/dist/esm-es5/calcite-label.entry.js +1 -1
- package/dist/esm-es5/calcite-link.entry.js +1 -1
- package/dist/esm-es5/calcite-list_3.entry.js +2 -2
- package/dist/esm-es5/calcite-loader.entry.js +1 -1
- package/dist/esm-es5/calcite-modal.entry.js +2 -2
- package/dist/esm-es5/calcite-notice.entry.js +2 -2
- package/dist/esm-es5/calcite-option_3.entry.js +1 -1
- package/dist/esm-es5/calcite-pagination.entry.js +1 -1
- package/dist/esm-es5/calcite-panel.entry.js +2 -2
- package/dist/esm-es5/calcite-pick-list_3.entry.js +1 -1
- package/dist/esm-es5/calcite-popover_2.entry.js +2 -2
- package/dist/esm-es5/calcite-progress.entry.js +1 -1
- package/dist/esm-es5/calcite-radio-button-group.entry.js +1 -1
- package/dist/esm-es5/calcite-radio-button.entry.js +1 -1
- package/dist/esm-es5/calcite-radio-group_2.entry.js +1 -1
- package/dist/esm-es5/calcite-rating.entry.js +2 -2
- package/dist/esm-es5/calcite-scrim.entry.js +1 -1
- package/dist/esm-es5/calcite-shell_3.entry.js +1 -1
- package/dist/esm-es5/calcite-sortable-list.entry.js +1 -1
- package/dist/esm-es5/calcite-split-button.entry.js +1 -1
- package/dist/esm-es5/calcite-stepper_2.entry.js +2 -2
- package/dist/esm-es5/calcite-switch.entry.js +2 -2
- package/dist/esm-es5/calcite-tab_4.entry.js +1 -1
- package/dist/esm-es5/calcite-tile-select_2.entry.js +2 -2
- package/dist/esm-es5/calcite-tile.entry.js +1 -1
- package/dist/esm-es5/calcite-tip_3.entry.js +1 -1
- package/dist/esm-es5/calcite-tooltip_2.entry.js +1 -1
- package/dist/esm-es5/calcite-tree_2.entry.js +1 -1
- package/dist/esm-es5/calcite-value-list_2.entry.js +1 -1
- package/dist/esm-es5/dom-e55f9eaf.js +5 -0
- package/dist/esm-es5/{form-160b0fb5.js → form-147bc6d7.js} +1 -1
- package/dist/esm-es5/label-240ef148.js +5 -0
- package/dist/esm-es5/locale-1b48f64f.js +5 -0
- package/dist/esm-es5/number-8779395f.js +5 -0
- package/dist/esm-es5/popper-1814b3c1.js +5 -0
- package/dist/esm-es5/{resources-b4eee1d4.js → resources-74c807b4.js} +1 -1
- package/dist/esm-es5/resources-a6abee37.js +5 -0
- package/dist/extras/docs-json.json +19 -13
- package/dist/types/components/calcite-tile-select/resources.d.ts +16 -0
- package/dist/types/components.d.ts +9 -9
- package/dist/types/stencil-public-runtime.d.ts +6 -4
- package/dist/types/utils/dom.d.ts +18 -3
- package/dist/types/utils/number.d.ts +2 -1
- package/hydrate/index.js +606 -507
- package/package.json +24 -24
- package/readme.md +2 -2
- package/dist/calcite/p-0229a408.js +0 -5
- package/dist/calcite/p-057197f8.entry.js +0 -5
- package/dist/calcite/p-05c10c53.entry.js +0 -5
- package/dist/calcite/p-05edaadf.system.entry.js +0 -5
- package/dist/calcite/p-112f20e6.system.entry.js +0 -5
- package/dist/calcite/p-11f01c0a.entry.js +0 -5
- package/dist/calcite/p-1942876c.js +0 -5
- package/dist/calcite/p-288899b9.entry.js +0 -5
- package/dist/calcite/p-2b294f8e.system.entry.js +0 -5
- package/dist/calcite/p-2be1e8ee.entry.js +0 -5
- package/dist/calcite/p-2d939f9e.system.entry.js +0 -5
- package/dist/calcite/p-2fbd50f3.system.entry.js +0 -5
- package/dist/calcite/p-35a5c74c.system.js +0 -5
- package/dist/calcite/p-3739338a.system.entry.js +0 -5
- package/dist/calcite/p-3c25cb72.system.entry.js +0 -5
- package/dist/calcite/p-3d8ee39d.system.entry.js +0 -5
- package/dist/calcite/p-3dae9da3.js +0 -5
- package/dist/calcite/p-3e9c6068.entry.js +0 -5
- package/dist/calcite/p-3f8527a3.entry.js +0 -5
- package/dist/calcite/p-40991717.entry.js +0 -5
- package/dist/calcite/p-4278fb57.entry.js +0 -5
- package/dist/calcite/p-44cce7a3.system.entry.js +0 -5
- package/dist/calcite/p-4d02c6c0.system.entry.js +0 -5
- package/dist/calcite/p-4e9d072a.system.js +0 -5
- package/dist/calcite/p-4f1f716a.system.entry.js +0 -5
- package/dist/calcite/p-52cc870b.js +0 -5
- package/dist/calcite/p-55f68e28.entry.js +0 -5
- package/dist/calcite/p-57169a74.entry.js +0 -5
- package/dist/calcite/p-5c9d89ce.system.entry.js +0 -5
- package/dist/calcite/p-62f3d4df.system.js +0 -5
- package/dist/calcite/p-63b9f804.entry.js +0 -5
- package/dist/calcite/p-689790cb.system.entry.js +0 -5
- package/dist/calcite/p-69bd1f5f.system.entry.js +0 -5
- package/dist/calcite/p-6a87d7b2.entry.js +0 -5
- package/dist/calcite/p-6cc23c39.system.js +0 -5
- package/dist/calcite/p-6faaa8af.system.entry.js +0 -5
- package/dist/calcite/p-6fb63fc1.entry.js +0 -5
- package/dist/calcite/p-72a60528.system.entry.js +0 -5
- package/dist/calcite/p-763479d6.system.entry.js +0 -5
- package/dist/calcite/p-768018df.entry.js +0 -5
- package/dist/calcite/p-76eda40b.entry.js +0 -5
- package/dist/calcite/p-7ac9f860.entry.js +0 -5
- package/dist/calcite/p-83744979.system.js +0 -5
- package/dist/calcite/p-88296be9.system.entry.js +0 -5
- package/dist/calcite/p-88b31760.system.entry.js +0 -5
- package/dist/calcite/p-8a8982ab.system.entry.js +0 -5
- package/dist/calcite/p-9180be05.system.entry.js +0 -5
- package/dist/calcite/p-93a189be.entry.js +0 -5
- package/dist/calcite/p-97117a5d.entry.js +0 -5
- package/dist/calcite/p-97efd284.system.entry.js +0 -5
- package/dist/calcite/p-998829cb.system.entry.js +0 -5
- package/dist/calcite/p-9a1ffbad.system.entry.js +0 -5
- package/dist/calcite/p-9b979692.entry.js +0 -5
- package/dist/calcite/p-9fc14d49.entry.js +0 -5
- package/dist/calcite/p-9feb0f5a.system.entry.js +0 -5
- package/dist/calcite/p-a3c498de.entry.js +0 -5
- package/dist/calcite/p-a6f99f79.entry.js +0 -5
- package/dist/calcite/p-a98344e2.system.entry.js +0 -5
- package/dist/calcite/p-a9f596be.system.entry.js +0 -5
- package/dist/calcite/p-adf4699d.system.entry.js +0 -5
- package/dist/calcite/p-b180d943.system.entry.js +0 -5
- package/dist/calcite/p-b2f0596f.entry.js +0 -5
- package/dist/calcite/p-b43e699c.system.entry.js +0 -5
- package/dist/calcite/p-ba7c0f01.system.entry.js +0 -5
- package/dist/calcite/p-bd091b49.system.entry.js +0 -5
- package/dist/calcite/p-bdca5372.entry.js +0 -5
- package/dist/calcite/p-bfa6bd72.entry.js +0 -5
- package/dist/calcite/p-c00b1d26.js +0 -5
- package/dist/calcite/p-c2bfd7f9.system.entry.js +0 -5
- package/dist/calcite/p-c2fcf603.system.entry.js +0 -5
- package/dist/calcite/p-c34c4414.system.js +0 -5
- package/dist/calcite/p-c70bacc8.system.entry.js +0 -5
- package/dist/calcite/p-c8c6323c.entry.js +0 -5
- package/dist/calcite/p-cb660e54.entry.js +0 -5
- package/dist/calcite/p-cd5d5756.system.entry.js +0 -5
- package/dist/calcite/p-cf499949.entry.js +0 -5
- package/dist/calcite/p-d17cfab3.entry.js +0 -5
- package/dist/calcite/p-d4d5665a.system.entry.js +0 -5
- package/dist/calcite/p-dc7124e9.entry.js +0 -5
- package/dist/calcite/p-dc777403.system.entry.js +0 -5
- package/dist/calcite/p-dda22c7e.system.entry.js +0 -5
- package/dist/calcite/p-de67ba93.system.entry.js +0 -5
- package/dist/calcite/p-e09bac0d.system.entry.js +0 -5
- package/dist/calcite/p-e35b29f5.system.entry.js +0 -5
- package/dist/calcite/p-e54784a8.system.entry.js +0 -5
- package/dist/calcite/p-e63c6a55.system.entry.js +0 -5
- package/dist/calcite/p-e697ab57.system.entry.js +0 -5
- package/dist/calcite/p-e7801f1d.entry.js +0 -5
- package/dist/calcite/p-e7f7b0f8.js +0 -5
- package/dist/calcite/p-f2340d02.system.entry.js +0 -5
- package/dist/calcite/p-f28d8e9e.system.entry.js +0 -5
- package/dist/calcite/p-f2f2ad57.entry.js +0 -5
- package/dist/calcite/p-f595d924.js +0 -5
- package/dist/calcite/p-fc265aaf.entry.js +0 -5
- package/dist/calcite/p-fd94e88d.system.entry.js +0 -5
- package/dist/cjs/locale-33c458dc.js +0 -123
- package/dist/cjs/number-73f7b474.js +0 -58
- package/dist/esm/locale-4c38cf6d.js +0 -118
- package/dist/esm/number-06e8500e.js +0 -51
- package/dist/esm-es5/dom-f24e866c.js +0 -5
- package/dist/esm-es5/label-5559055d.js +0 -5
- package/dist/esm-es5/locale-4c38cf6d.js +0 -5
- package/dist/esm-es5/number-06e8500e.js +0 -5
- package/dist/esm-es5/popper-f5caedc4.js +0 -5
- package/dist/esm-es5/resources-35c1823f.js +0 -5
|
@@ -2,4 +2,4 @@ var __awaiter=this&&this.__awaiter||function(t,e,a,i){function o(t){return t ins
|
|
|
2
2
|
/*!
|
|
3
3
|
* All material copyright ESRI, All Rights Reserved, unless otherwise specified.
|
|
4
4
|
* See https://github.com/Esri/calcite-components/blob/master/LICENSE.md for details.
|
|
5
|
-
*/import{r as registerInstance,h,H as Host,g as getElement}from"./index-9de00868.js";import{g as guid}from"./guid-196bd5ea.js";import{d as defaultOffsetDistance,u as updatePopper,c as createPopper,C as CSS$1}from"./popper-f5caedc4.js";import{q as queryElementRoots}from"./dom-f24e866c.js";var CSS={container:"container",arrow:"arrow"};var TOOLTIP_DELAY_MS=500;var TOOLTIP_REFERENCE="data-calcite-tooltip-reference";var ARIA_DESCRIBED_BY="aria-describedby";var calciteTooltipCss='@-webkit-keyframes in{0%{opacity:0}100%{opacity:1}}@keyframes in{0%{opacity:0}100%{opacity:1}}@-webkit-keyframes in-down{0%{opacity:0;-webkit-transform:translate3D(0, -5px, 0);transform:translate3D(0, -5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@keyframes in-down{0%{opacity:0;-webkit-transform:translate3D(0, -5px, 0);transform:translate3D(0, -5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@-webkit-keyframes in-up{0%{opacity:0;-webkit-transform:translate3D(0, 5px, 0);transform:translate3D(0, 5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@keyframes in-up{0%{opacity:0;-webkit-transform:translate3D(0, 5px, 0);transform:translate3D(0, 5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@-webkit-keyframes in-scale{0%{opacity:0;-webkit-transform:scale3D(0.95, 0.95, 1);transform:scale3D(0.95, 0.95, 1)}100%{opacity:1;-webkit-transform:scale3D(1, 1, 1);transform:scale3D(1, 1, 1)}}@keyframes in-scale{0%{opacity:0;-webkit-transform:scale3D(0.95, 0.95, 1);transform:scale3D(0.95, 0.95, 1)}100%{opacity:1;-webkit-transform:scale3D(1, 1, 1);transform:scale3D(1, 1, 1)}}:root{--calcite-animation-timing:calc(150ms * var(--calcite-internal-duration-factor));--calcite-internal-duration-factor:var(--calcite-duration-factor, 1);--calcite-internal-animation-timing-fast:calc(100ms * var(--calcite-internal-duration-factor));--calcite-internal-animation-timing-medium:calc(200ms * var(--calcite-internal-duration-factor));--calcite-internal-animation-timing-slow:calc(300ms * var(--calcite-internal-duration-factor))}.calcite-animate{opacity:0;-webkit-animation-fill-mode:both;animation-fill-mode:both;-webkit-animation-duration:var(--calcite-animation-timing);animation-duration:var(--calcite-animation-timing)}.calcite-animate__in{-webkit-animation-name:in;animation-name:in}.calcite-animate__in-down{-webkit-animation-name:in-down;animation-name:in-down}.calcite-animate__in-up{-webkit-animation-name:in-up;animation-name:in-up}.calcite-animate__in-scale{-webkit-animation-name:in-scale;animation-name:in-scale}:root{--calcite-popper-transition:150ms ease-in-out}:host([hidden]){display:none}:host{display:block;position:absolute;z-index:999;-webkit-transform:scale(0);transform:scale(0)}.calcite-popper-anim{position:relative;z-index:1;-webkit-transition:var(--calcite-popper-transition);transition:var(--calcite-popper-transition);visibility:hidden;-webkit-transition-property:visibility, opacity, -webkit-transform;transition-property:visibility, opacity, -webkit-transform;transition-property:transform, visibility, opacity;transition-property:transform, visibility, opacity, -webkit-transform;opacity:0;-webkit-box-shadow:0 0 16px 0 rgba(0, 0, 0, 0.16);box-shadow:0 0 16px 0 rgba(0, 0, 0, 0.16);border-radius:0.25rem}:host([data-popper-placement^=bottom]) .calcite-popper-anim{-webkit-transform:translateY(-5px);transform:translateY(-5px)}:host([data-popper-placement^=top]) .calcite-popper-anim{-webkit-transform:translateY(5px);transform:translateY(5px)}:host([data-popper-placement^=left]) .calcite-popper-anim{-webkit-transform:translateX(5px);transform:translateX(5px)}:host([data-popper-placement^=right]) .calcite-popper-anim{-webkit-transform:translateX(-5px);transform:translateX(-5px)}:host([data-popper-placement]) .calcite-popper-anim--active{opacity:1;visibility:visible;-webkit-transform:translate(0);transform:translate(0)}.arrow,.arrow::before{position:absolute;width:8px;height:8px;z-index:-1}.arrow::before{content:"";-webkit-box-shadow:0 4px 8px -1px rgba(0, 0, 0, 0.08), 0 2px 4px -1px rgba(0, 0, 0, 0.04);box-shadow:0 4px 8px -1px rgba(0, 0, 0, 0.08), 0 2px 4px -1px rgba(0, 0, 0, 0.04);-webkit-transform:rotate(45deg);transform:rotate(45deg);background:var(--calcite-ui-foreground-1)}:host([data-popper-placement^=top]) .arrow{bottom:-4px}:host([data-popper-placement^=bottom]) .arrow{top:-4px}:host([data-popper-placement^=left]) .arrow{right:-4px}:host([data-popper-placement^=right]) .arrow{left:-4px}.container{position:relative;background-color:var(--calcite-ui-foreground-1);display:-ms-flexbox;display:flex;-ms-flex-pack:start;justify-content:flex-start;-ms-flex-direction:column;flex-direction:column;font-weight:var(--calcite-font-weight-medium);color:var(--calcite-ui-text-1);padding-top:0.75rem;padding-bottom:0.75rem;padding-left:1rem;padding-right:1rem;overflow:hidden;font-size:var(--calcite-font-size--2);line-height:1.375;border-radius:0.25rem;max-width:20rem;max-height:20rem}.calcite-popper-anim{background-color:var(--calcite-ui-foreground-1);border-width:1px;border-style:solid;border-color:var(--calcite-ui-border-3);border-radius:0.25rem}.arrow::before{outline:1px solid var(--calcite-ui-border-3)}';var CalciteTooltip=function(){function t(t){var e=this;registerInstance(this,t);this.offsetDistance=defaultOffsetDistance;this.offsetSkidding=0;this.open=false;this.overlayPositioning="absolute";this.placement="auto";this.guid="calcite-tooltip-"+guid();this.setUpReferenceElement=function(){e.removeReferences();e.effectiveReferenceElement=e.getReferenceElement();var t=e,a=t.el,i=t.referenceElement,o=t.effectiveReferenceElement;if(i&&!o){console.warn(a.tagName+': reference-element id "'+i+'" was not found.',{el:a})}e.addReferences();e.createPopper()};this.getId=function(){return e.el.id||e.guid};this.addReferences=function(){var t=e.effectiveReferenceElement;if(!t){return}var a=e.getId();t.setAttribute(TOOLTIP_REFERENCE,a);t.setAttribute(ARIA_DESCRIBED_BY,a)};this.removeReferences=function(){var t=e.effectiveReferenceElement;if(!t){return}t.removeAttribute(TOOLTIP_REFERENCE);t.removeAttribute(ARIA_DESCRIBED_BY)};this.show=function(){e.open=true};this.hide=function(){e.open=false}}t.prototype.offsetDistanceOffsetHandler=function(){this.reposition()};t.prototype.offsetSkiddingHandler=function(){this.reposition()};t.prototype.openHandler=function(){this.reposition()};t.prototype.placementHandler=function(){this.reposition()};t.prototype.referenceElementHandler=function(){this.setUpReferenceElement()};t.prototype.componentWillLoad=function(){this.setUpReferenceElement()};t.prototype.componentDidLoad=function(){this.reposition()};t.prototype.disconnectedCallback=function(){this.removeReferences();this.destroyPopper()};t.prototype.reposition=function(){return __awaiter(this,void 0,void 0,(function(){var t,e,a,i,o,r;return __generator(this,(function(n){switch(n.label){case 0:t=this,e=t.popper,a=t.el,i=t.placement;o=this.getModifiers();if(!e)return[3,2];return[4,updatePopper({el:a,modifiers:o,placement:i,popper:e})];case 1:r=n.sent();return[3,3];case 2:r=this.createPopper();n.label=3;case 3:r;return[2]}}))}))};t.prototype.getReferenceElement=function(){var t=this,e=t.referenceElement,a=t.el;return(typeof e==="string"?queryElementRoots(a,"#"+e):e)||null};t.prototype.getModifiers=function(){var t=this,e=t.arrowEl,a=t.offsetDistance,i=t.offsetSkidding;var o={name:"arrow",enabled:true,options:{element:e}};var r={name:"offset",enabled:true,options:{offset:[i,a]}};return[o,r]};t.prototype.createPopper=function(){this.destroyPopper();var t=this,e=t.el,a=t.placement,i=t.effectiveReferenceElement,o=t.overlayPositioning;var r=this.getModifiers();this.popper=createPopper({el:e,modifiers:r,placement:a,overlayPositioning:o,referenceEl:i})};t.prototype.destroyPopper=function(){var t=this.popper;if(t){t.destroy()}this.popper=null};t.prototype.render=function(){var t;var e=this;var a=this,i=a.effectiveReferenceElement,o=a.label,r=a.open;var n=i&&r;var s=!n;return h(Host,{"aria-hidden":s.toString(),"aria-label":o,"calcite-hydrated-hidden":s,id:this.getId(),role:"tooltip"},h("div",{class:(t={},t[CSS$1.animation]=true,t[CSS$1.animationActive]=n,t)},h("div",{class:CSS.arrow,ref:function(t){return e.arrowEl=t}}),h("div",{class:CSS.container},h("slot",null))))};Object.defineProperty(t.prototype,"el",{get:function(){return getElement(this)},enumerable:false,configurable:true});Object.defineProperty(t,"watchers",{get:function(){return{offsetDistance:["offsetDistanceOffsetHandler"],offsetSkidding:["offsetSkiddingHandler"],open:["openHandler"],placement:["placementHandler"],referenceElement:["referenceElementHandler"]}},enumerable:false,configurable:true});return t}();CalciteTooltip.style=calciteTooltipCss;var calciteTooltipManagerCss="@-webkit-keyframes in{0%{opacity:0}100%{opacity:1}}@keyframes in{0%{opacity:0}100%{opacity:1}}@-webkit-keyframes in-down{0%{opacity:0;-webkit-transform:translate3D(0, -5px, 0);transform:translate3D(0, -5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@keyframes in-down{0%{opacity:0;-webkit-transform:translate3D(0, -5px, 0);transform:translate3D(0, -5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@-webkit-keyframes in-up{0%{opacity:0;-webkit-transform:translate3D(0, 5px, 0);transform:translate3D(0, 5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@keyframes in-up{0%{opacity:0;-webkit-transform:translate3D(0, 5px, 0);transform:translate3D(0, 5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@-webkit-keyframes in-scale{0%{opacity:0;-webkit-transform:scale3D(0.95, 0.95, 1);transform:scale3D(0.95, 0.95, 1)}100%{opacity:1;-webkit-transform:scale3D(1, 1, 1);transform:scale3D(1, 1, 1)}}@keyframes in-scale{0%{opacity:0;-webkit-transform:scale3D(0.95, 0.95, 1);transform:scale3D(0.95, 0.95, 1)}100%{opacity:1;-webkit-transform:scale3D(1, 1, 1);transform:scale3D(1, 1, 1)}}:root{--calcite-animation-timing:calc(150ms * var(--calcite-internal-duration-factor));--calcite-internal-duration-factor:var(--calcite-duration-factor, 1);--calcite-internal-animation-timing-fast:calc(100ms * var(--calcite-internal-duration-factor));--calcite-internal-animation-timing-medium:calc(200ms * var(--calcite-internal-duration-factor));--calcite-internal-animation-timing-slow:calc(300ms * var(--calcite-internal-duration-factor))}.calcite-animate{opacity:0;-webkit-animation-fill-mode:both;animation-fill-mode:both;-webkit-animation-duration:var(--calcite-animation-timing);animation-duration:var(--calcite-animation-timing)}.calcite-animate__in{-webkit-animation-name:in;animation-name:in}.calcite-animate__in-down{-webkit-animation-name:in-down;animation-name:in-down}.calcite-animate__in-up{-webkit-animation-name:in-up;animation-name:in-up}.calcite-animate__in-scale{-webkit-animation-name:in-scale;animation-name:in-scale}:root{--calcite-popper-transition:150ms ease-in-out}:host([hidden]){display:none}:host{display:block}";var CalciteTooltipManager=function(){function t(t){var e=this;registerInstance(this,t);this.hoverTimeouts=new WeakMap;this.selector="["+TOOLTIP_REFERENCE+"]";this.queryTooltip=function(t){var a;var i=e,o=i.selector,r=i.el;var n=(a=t.closest(o))===null||a===void 0?void 0:a.getAttribute(TOOLTIP_REFERENCE);return queryElementRoots(r,"#"+n)};this.clearHoverTimeout=function(t){var a=e.hoverTimeouts;if(a.has(t)){window.clearTimeout(a.get(t));a.delete(t)}};this.closeExistingTooltip=function(){var t=e.tooltipEl;if(t){e.toggleTooltip(t,false)}};this.focusTooltip=function(t){var a=t.tooltip,i=t.value;e.closeExistingTooltip();if(i){e.clearHoverTimeout(a)}e.toggleTooltip(a,i)};this.toggleTooltip=function(t,a){t.open=a;if(a){e.tooltipEl=t}};this.hoverToggle=function(t){var a=t.tooltip,i=t.value;var o=e.hoverTimeouts;o.delete(a);if(i){e.closeExistingTooltip()}e.toggleTooltip(a,i)};this.hoverTooltip=function(t){var a=t.tooltip,i=t.value;e.clearHoverTimeout(a);var o=e.hoverTimeouts;var r=window.setTimeout((function(){return e.hoverToggle({tooltip:a,value:i})}),TOOLTIP_DELAY_MS);o.set(a,r)};this.activeTooltipHover=function(t){var a=e,i=a.tooltipEl,o=a.hoverTimeouts;var r=t.type;if(!i){return}if(r==="mouseover"&&t.composedPath().includes(i)){e.clearHoverTimeout(i)}else if(r==="mouseout"&&!o.has(i)){e.hoverTooltip({tooltip:i,value:false})}};this.hoverEvent=function(t,a){var i=e.queryTooltip(t.target);e.activeTooltipHover(t);if(!i){return}e.hoverTooltip({tooltip:i,value:a})};this.focusEvent=function(t,a){var i=e.queryTooltip(t.target);if(!i||i===e.clickedTooltip){e.clickedTooltip=null;return}e.focusTooltip({tooltip:i,value:a})}}t.prototype.render=function(){return h("slot",null)};t.prototype.keyUpHandler=function(t){if(t.key==="Escape"){var e=this.tooltipEl;if(e){this.clearHoverTimeout(e);this.toggleTooltip(e,false)}}};t.prototype.mouseEnterShow=function(t){this.hoverEvent(t,true)};t.prototype.mouseLeaveHide=function(t){this.hoverEvent(t,false)};t.prototype.clickHandler=function(t){var e=this.queryTooltip(t.target);this.clickedTooltip=e;if(e){this.toggleTooltip(e,false)}};t.prototype.focusShow=function(t){this.focusEvent(t,true)};t.prototype.blurHide=function(t){this.focusEvent(t,false)};Object.defineProperty(t.prototype,"el",{get:function(){return getElement(this)},enumerable:false,configurable:true});return t}();CalciteTooltipManager.style=calciteTooltipManagerCss;export{CalciteTooltip as calcite_tooltip,CalciteTooltipManager as calcite_tooltip_manager};
|
|
5
|
+
*/import{r as registerInstance,h,H as Host,g as getElement}from"./index-9de00868.js";import{g as guid}from"./guid-196bd5ea.js";import{d as defaultOffsetDistance,u as updatePopper,c as createPopper,C as CSS$1}from"./popper-1814b3c1.js";import{q as queryElementRoots}from"./dom-e55f9eaf.js";var CSS={container:"container",arrow:"arrow"};var TOOLTIP_DELAY_MS=500;var TOOLTIP_REFERENCE="data-calcite-tooltip-reference";var ARIA_DESCRIBED_BY="aria-describedby";var calciteTooltipCss='@-webkit-keyframes in{0%{opacity:0}100%{opacity:1}}@keyframes in{0%{opacity:0}100%{opacity:1}}@-webkit-keyframes in-down{0%{opacity:0;-webkit-transform:translate3D(0, -5px, 0);transform:translate3D(0, -5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@keyframes in-down{0%{opacity:0;-webkit-transform:translate3D(0, -5px, 0);transform:translate3D(0, -5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@-webkit-keyframes in-up{0%{opacity:0;-webkit-transform:translate3D(0, 5px, 0);transform:translate3D(0, 5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@keyframes in-up{0%{opacity:0;-webkit-transform:translate3D(0, 5px, 0);transform:translate3D(0, 5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@-webkit-keyframes in-scale{0%{opacity:0;-webkit-transform:scale3D(0.95, 0.95, 1);transform:scale3D(0.95, 0.95, 1)}100%{opacity:1;-webkit-transform:scale3D(1, 1, 1);transform:scale3D(1, 1, 1)}}@keyframes in-scale{0%{opacity:0;-webkit-transform:scale3D(0.95, 0.95, 1);transform:scale3D(0.95, 0.95, 1)}100%{opacity:1;-webkit-transform:scale3D(1, 1, 1);transform:scale3D(1, 1, 1)}}:root{--calcite-animation-timing:calc(150ms * var(--calcite-internal-duration-factor));--calcite-internal-duration-factor:var(--calcite-duration-factor, 1);--calcite-internal-animation-timing-fast:calc(100ms * var(--calcite-internal-duration-factor));--calcite-internal-animation-timing-medium:calc(200ms * var(--calcite-internal-duration-factor));--calcite-internal-animation-timing-slow:calc(300ms * var(--calcite-internal-duration-factor))}.calcite-animate{opacity:0;-webkit-animation-fill-mode:both;animation-fill-mode:both;-webkit-animation-duration:var(--calcite-animation-timing);animation-duration:var(--calcite-animation-timing)}.calcite-animate__in{-webkit-animation-name:in;animation-name:in}.calcite-animate__in-down{-webkit-animation-name:in-down;animation-name:in-down}.calcite-animate__in-up{-webkit-animation-name:in-up;animation-name:in-up}.calcite-animate__in-scale{-webkit-animation-name:in-scale;animation-name:in-scale}:root{--calcite-popper-transition:var(--calcite-animation-timing)}:host([hidden]){display:none}:host{display:block;position:absolute;z-index:999;-webkit-transform:scale(0);transform:scale(0)}.calcite-popper-anim{position:relative;z-index:1;-webkit-transition:var(--calcite-popper-transition);transition:var(--calcite-popper-transition);visibility:hidden;-webkit-transition-property:visibility, opacity, -webkit-transform;transition-property:visibility, opacity, -webkit-transform;transition-property:transform, visibility, opacity;transition-property:transform, visibility, opacity, -webkit-transform;opacity:0;-webkit-box-shadow:0 0 16px 0 rgba(0, 0, 0, 0.16);box-shadow:0 0 16px 0 rgba(0, 0, 0, 0.16);border-radius:0.25rem}:host([data-popper-placement^=bottom]) .calcite-popper-anim{-webkit-transform:translateY(-5px);transform:translateY(-5px)}:host([data-popper-placement^=top]) .calcite-popper-anim{-webkit-transform:translateY(5px);transform:translateY(5px)}:host([data-popper-placement^=left]) .calcite-popper-anim{-webkit-transform:translateX(5px);transform:translateX(5px)}:host([data-popper-placement^=right]) .calcite-popper-anim{-webkit-transform:translateX(-5px);transform:translateX(-5px)}:host([data-popper-placement]) .calcite-popper-anim--active{opacity:1;visibility:visible;-webkit-transform:translate(0);transform:translate(0)}.arrow,.arrow::before{position:absolute;width:8px;height:8px;z-index:-1}.arrow::before{content:"";--tw-shadow:0 4px 8px -1px rgba(0, 0, 0, 0.08), 0 2px 4px -1px rgba(0, 0, 0, 0.04);--tw-shadow-colored:0 4px 8px -1px var(--tw-shadow-color), 0 2px 4px -1px var(--tw-shadow-color);-webkit-box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow);-webkit-transform:rotate(45deg);transform:rotate(45deg);background:var(--calcite-ui-foreground-1)}:host([data-popper-placement^=top]) .arrow{bottom:-4px}:host([data-popper-placement^=bottom]) .arrow{top:-4px}:host([data-popper-placement^=left]) .arrow{right:-4px}:host([data-popper-placement^=right]) .arrow{left:-4px}.container{position:relative;display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;-ms-flex-pack:start;justify-content:flex-start;border-radius:0.25rem;background-color:var(--calcite-ui-foreground-1);padding-top:0.75rem;padding-bottom:0.75rem;padding-left:1rem;padding-right:1rem;font-size:var(--calcite-font-size--2);line-height:1.375;font-weight:var(--calcite-font-weight-medium);color:var(--calcite-ui-text-1);overflow:hidden;max-width:20rem;max-height:20rem}.calcite-popper-anim{border-radius:0.25rem;border-width:1px;border-style:solid;border-color:var(--calcite-ui-border-3);background-color:var(--calcite-ui-foreground-1)}.arrow::before{outline:1px solid var(--calcite-ui-border-3)}';var CalciteTooltip=function(){function t(t){var e=this;registerInstance(this,t);this.offsetDistance=defaultOffsetDistance;this.offsetSkidding=0;this.open=false;this.overlayPositioning="absolute";this.placement="auto";this.guid="calcite-tooltip-"+guid();this.setUpReferenceElement=function(){e.removeReferences();e.effectiveReferenceElement=e.getReferenceElement();var t=e,a=t.el,i=t.referenceElement,o=t.effectiveReferenceElement;if(i&&!o){console.warn(a.tagName+': reference-element id "'+i+'" was not found.',{el:a})}e.addReferences();e.createPopper()};this.getId=function(){return e.el.id||e.guid};this.addReferences=function(){var t=e.effectiveReferenceElement;if(!t){return}var a=e.getId();t.setAttribute(TOOLTIP_REFERENCE,a);t.setAttribute(ARIA_DESCRIBED_BY,a)};this.removeReferences=function(){var t=e.effectiveReferenceElement;if(!t){return}t.removeAttribute(TOOLTIP_REFERENCE);t.removeAttribute(ARIA_DESCRIBED_BY)};this.show=function(){e.open=true};this.hide=function(){e.open=false}}t.prototype.offsetDistanceOffsetHandler=function(){this.reposition()};t.prototype.offsetSkiddingHandler=function(){this.reposition()};t.prototype.openHandler=function(){this.reposition()};t.prototype.placementHandler=function(){this.reposition()};t.prototype.referenceElementHandler=function(){this.setUpReferenceElement()};t.prototype.componentWillLoad=function(){this.setUpReferenceElement()};t.prototype.componentDidLoad=function(){this.reposition()};t.prototype.disconnectedCallback=function(){this.removeReferences();this.destroyPopper()};t.prototype.reposition=function(){return __awaiter(this,void 0,void 0,(function(){var t,e,a,i,o,r;return __generator(this,(function(n){switch(n.label){case 0:t=this,e=t.popper,a=t.el,i=t.placement;o=this.getModifiers();if(!e)return[3,2];return[4,updatePopper({el:a,modifiers:o,placement:i,popper:e})];case 1:r=n.sent();return[3,3];case 2:r=this.createPopper();n.label=3;case 3:r;return[2]}}))}))};t.prototype.getReferenceElement=function(){var t=this,e=t.referenceElement,a=t.el;return(typeof e==="string"?queryElementRoots(a,{id:e}):e)||null};t.prototype.getModifiers=function(){var t=this,e=t.arrowEl,a=t.offsetDistance,i=t.offsetSkidding;var o={name:"arrow",enabled:true,options:{element:e}};var r={name:"offset",enabled:true,options:{offset:[i,a]}};return[o,r]};t.prototype.createPopper=function(){this.destroyPopper();var t=this,e=t.el,a=t.placement,i=t.effectiveReferenceElement,o=t.overlayPositioning;var r=this.getModifiers();this.popper=createPopper({el:e,modifiers:r,placement:a,overlayPositioning:o,referenceEl:i})};t.prototype.destroyPopper=function(){var t=this.popper;if(t){t.destroy()}this.popper=null};t.prototype.render=function(){var t;var e=this;var a=this,i=a.effectiveReferenceElement,o=a.label,r=a.open;var n=i&&r;var s=!n;return h(Host,{"aria-hidden":s.toString(),"aria-label":o,"calcite-hydrated-hidden":s,id:this.getId(),role:"tooltip"},h("div",{class:(t={},t[CSS$1.animation]=true,t[CSS$1.animationActive]=n,t)},h("div",{class:CSS.arrow,ref:function(t){return e.arrowEl=t}}),h("div",{class:CSS.container},h("slot",null))))};Object.defineProperty(t.prototype,"el",{get:function(){return getElement(this)},enumerable:false,configurable:true});Object.defineProperty(t,"watchers",{get:function(){return{offsetDistance:["offsetDistanceOffsetHandler"],offsetSkidding:["offsetSkiddingHandler"],open:["openHandler"],placement:["placementHandler"],referenceElement:["referenceElementHandler"]}},enumerable:false,configurable:true});return t}();CalciteTooltip.style=calciteTooltipCss;var calciteTooltipManagerCss="@-webkit-keyframes in{0%{opacity:0}100%{opacity:1}}@keyframes in{0%{opacity:0}100%{opacity:1}}@-webkit-keyframes in-down{0%{opacity:0;-webkit-transform:translate3D(0, -5px, 0);transform:translate3D(0, -5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@keyframes in-down{0%{opacity:0;-webkit-transform:translate3D(0, -5px, 0);transform:translate3D(0, -5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@-webkit-keyframes in-up{0%{opacity:0;-webkit-transform:translate3D(0, 5px, 0);transform:translate3D(0, 5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@keyframes in-up{0%{opacity:0;-webkit-transform:translate3D(0, 5px, 0);transform:translate3D(0, 5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@-webkit-keyframes in-scale{0%{opacity:0;-webkit-transform:scale3D(0.95, 0.95, 1);transform:scale3D(0.95, 0.95, 1)}100%{opacity:1;-webkit-transform:scale3D(1, 1, 1);transform:scale3D(1, 1, 1)}}@keyframes in-scale{0%{opacity:0;-webkit-transform:scale3D(0.95, 0.95, 1);transform:scale3D(0.95, 0.95, 1)}100%{opacity:1;-webkit-transform:scale3D(1, 1, 1);transform:scale3D(1, 1, 1)}}:root{--calcite-animation-timing:calc(150ms * var(--calcite-internal-duration-factor));--calcite-internal-duration-factor:var(--calcite-duration-factor, 1);--calcite-internal-animation-timing-fast:calc(100ms * var(--calcite-internal-duration-factor));--calcite-internal-animation-timing-medium:calc(200ms * var(--calcite-internal-duration-factor));--calcite-internal-animation-timing-slow:calc(300ms * var(--calcite-internal-duration-factor))}.calcite-animate{opacity:0;-webkit-animation-fill-mode:both;animation-fill-mode:both;-webkit-animation-duration:var(--calcite-animation-timing);animation-duration:var(--calcite-animation-timing)}.calcite-animate__in{-webkit-animation-name:in;animation-name:in}.calcite-animate__in-down{-webkit-animation-name:in-down;animation-name:in-down}.calcite-animate__in-up{-webkit-animation-name:in-up;animation-name:in-up}.calcite-animate__in-scale{-webkit-animation-name:in-scale;animation-name:in-scale}:root{--calcite-popper-transition:var(--calcite-animation-timing)}:host([hidden]){display:none}:host{display:block}";var CalciteTooltipManager=function(){function t(t){var e=this;registerInstance(this,t);this.hoverTimeouts=new WeakMap;this.selector="["+TOOLTIP_REFERENCE+"]";this.queryTooltip=function(t){var a;var i=e,o=i.selector,r=i.el;var n=(a=t.closest(o))===null||a===void 0?void 0:a.getAttribute(TOOLTIP_REFERENCE);return queryElementRoots(r,{id:n})};this.clearHoverTimeout=function(t){var a=e.hoverTimeouts;if(a.has(t)){window.clearTimeout(a.get(t));a.delete(t)}};this.closeExistingTooltip=function(){var t=e.tooltipEl;if(t){e.toggleTooltip(t,false)}};this.focusTooltip=function(t){var a=t.tooltip,i=t.value;e.closeExistingTooltip();if(i){e.clearHoverTimeout(a)}e.toggleTooltip(a,i)};this.toggleTooltip=function(t,a){t.open=a;if(a){e.tooltipEl=t}};this.hoverToggle=function(t){var a=t.tooltip,i=t.value;var o=e.hoverTimeouts;o.delete(a);if(i){e.closeExistingTooltip()}e.toggleTooltip(a,i)};this.hoverTooltip=function(t){var a=t.tooltip,i=t.value;e.clearHoverTimeout(a);var o=e.hoverTimeouts;var r=window.setTimeout((function(){return e.hoverToggle({tooltip:a,value:i})}),TOOLTIP_DELAY_MS);o.set(a,r)};this.activeTooltipHover=function(t){var a=e,i=a.tooltipEl,o=a.hoverTimeouts;var r=t.type;if(!i){return}if(r==="mouseover"&&t.composedPath().includes(i)){e.clearHoverTimeout(i)}else if(r==="mouseout"&&!o.has(i)){e.hoverTooltip({tooltip:i,value:false})}};this.hoverEvent=function(t,a){var i=e.queryTooltip(t.target);e.activeTooltipHover(t);if(!i){return}e.hoverTooltip({tooltip:i,value:a})};this.focusEvent=function(t,a){var i=e.queryTooltip(t.target);if(!i||i===e.clickedTooltip){e.clickedTooltip=null;return}e.focusTooltip({tooltip:i,value:a})}}t.prototype.render=function(){return h("slot",null)};t.prototype.keyUpHandler=function(t){if(t.key==="Escape"){var e=this.tooltipEl;if(e){this.clearHoverTimeout(e);this.toggleTooltip(e,false)}}};t.prototype.mouseEnterShow=function(t){this.hoverEvent(t,true)};t.prototype.mouseLeaveHide=function(t){this.hoverEvent(t,false)};t.prototype.clickHandler=function(t){var e=this.queryTooltip(t.target);this.clickedTooltip=e;if(e){this.toggleTooltip(e,false)}};t.prototype.focusShow=function(t){this.focusEvent(t,true)};t.prototype.blurHide=function(t){this.focusEvent(t,false)};Object.defineProperty(t.prototype,"el",{get:function(){return getElement(this)},enumerable:false,configurable:true});return t}();CalciteTooltipManager.style=calciteTooltipManagerCss;export{CalciteTooltip as calcite_tooltip,CalciteTooltipManager as calcite_tooltip_manager};
|
|
@@ -2,4 +2,4 @@
|
|
|
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
4
|
*/
|
|
5
|
-
import{r as registerInstance,c as createEvent,h,H as Host,g as getElement}from"./index-9de00868.js";import{f as focusElement,n as nodeListToArray,g as getSlotted,a as getElementDir,C as CSS_UTILITY,k as filterDirectChildren}from"./dom-f24e866c.js";import"./guid-196bd5ea.js";var TreeSelectionMode;(function(e){e["Single"]="single";e["Multi"]="multi";e["Children"]="children";e["MultiChildren"]="multi-children";e["Ancestors"]="ancestors"})(TreeSelectionMode||(TreeSelectionMode={}));var calciteTreeCss="@-webkit-keyframes in{0%{opacity:0}100%{opacity:1}}@keyframes in{0%{opacity:0}100%{opacity:1}}@-webkit-keyframes in-down{0%{opacity:0;-webkit-transform:translate3D(0, -5px, 0);transform:translate3D(0, -5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@keyframes in-down{0%{opacity:0;-webkit-transform:translate3D(0, -5px, 0);transform:translate3D(0, -5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@-webkit-keyframes in-up{0%{opacity:0;-webkit-transform:translate3D(0, 5px, 0);transform:translate3D(0, 5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@keyframes in-up{0%{opacity:0;-webkit-transform:translate3D(0, 5px, 0);transform:translate3D(0, 5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@-webkit-keyframes in-scale{0%{opacity:0;-webkit-transform:scale3D(0.95, 0.95, 1);transform:scale3D(0.95, 0.95, 1)}100%{opacity:1;-webkit-transform:scale3D(1, 1, 1);transform:scale3D(1, 1, 1)}}@keyframes in-scale{0%{opacity:0;-webkit-transform:scale3D(0.95, 0.95, 1);transform:scale3D(0.95, 0.95, 1)}100%{opacity:1;-webkit-transform:scale3D(1, 1, 1);transform:scale3D(1, 1, 1)}}:root{--calcite-animation-timing:calc(150ms * var(--calcite-internal-duration-factor));--calcite-internal-duration-factor:var(--calcite-duration-factor, 1);--calcite-internal-animation-timing-fast:calc(100ms * var(--calcite-internal-duration-factor));--calcite-internal-animation-timing-medium:calc(200ms * var(--calcite-internal-duration-factor));--calcite-internal-animation-timing-slow:calc(300ms * var(--calcite-internal-duration-factor))}.calcite-animate{opacity:0;-webkit-animation-fill-mode:both;animation-fill-mode:both;-webkit-animation-duration:var(--calcite-animation-timing);animation-duration:var(--calcite-animation-timing)}.calcite-animate__in{-webkit-animation-name:in;animation-name:in}.calcite-animate__in-down{-webkit-animation-name:in-down;animation-name:in-down}.calcite-animate__in-up{-webkit-animation-name:in-up;animation-name:in-up}.calcite-animate__in-scale{-webkit-animation-name:in-scale;animation-name:in-scale}:root{--calcite-popper-transition:150ms ease-in-out}:host([hidden]){display:none}:host{display:block;outline:2px solid transparent;outline-offset:2px}";var CalciteTree=function(){function e(e){registerInstance(this,e);this.calciteTreeSelect=createEvent(this,"calciteTreeSelect",7);this.lines=false;this.inputEnabled=false;this.scale="m";this.selectionMode=TreeSelectionMode.Single}e.prototype.componentWillRender=function(){var e=this.el.parentElement.closest("calcite-tree");this.lines=e?e.lines:this.lines;this.scale=e?e.scale:this.scale;this.selectionMode=e?e.selectionMode:this.selectionMode;this.child=!!e};e.prototype.render=function(){return h(Host,{"aria-multiselectable":(this.selectionMode===TreeSelectionMode.Multi||this.selectionMode===TreeSelectionMode.MultiChildren).toString(),role:!this.child?"tree":undefined,tabIndex:this.getRootTabIndex()},h("slot",null))};e.prototype.onFocus=function(){if(!this.child){var e=this.el.querySelector("calcite-tree-item[selected]")||this.el.querySelector("calcite-tree-item");focusElement(e)}};e.prototype.onFocusIn=function(e){var t=e.relatedTarget===this.el||!this.el.contains(e.relatedTarget);if(t){this.el.tabIndex=-1}};e.prototype.onFocusOut=function(e){var t=!this.el.contains(e.relatedTarget);if(t){this.el.tabIndex=this.getRootTabIndex()}};e.prototype.onClick=function(e){var t=e.target;var i=nodeListToArray(t.querySelectorAll("calcite-tree-item"));if(this.child){return}if(!this.child){e.preventDefault();e.stopPropagation()}if(this.selectionMode===TreeSelectionMode.Ancestors&&!this.child){this.updateAncestorTree(e);return}var n=this.selectionMode!==null&&(!t.hasChildren||t.hasChildren&&(this.selectionMode===TreeSelectionMode.Children||this.selectionMode===TreeSelectionMode.MultiChildren));var a=e.detail.modifyCurrentSelection&&(this.selectionMode===TreeSelectionMode.Multi||this.selectionMode===TreeSelectionMode.MultiChildren);var r=this.selectionMode===TreeSelectionMode.MultiChildren||this.selectionMode===TreeSelectionMode.Children;var o=!a&&((this.selectionMode===TreeSelectionMode.Single||this.selectionMode===TreeSelectionMode.Multi)&&i.length<=0||this.selectionMode===TreeSelectionMode.Children||this.selectionMode===TreeSelectionMode.MultiChildren);var c=this.selectionMode===TreeSelectionMode.Children||this.selectionMode===TreeSelectionMode.MultiChildren;if(!this.child){var l=[];if(n){l.push(t)}if(r){i.forEach((function(e){l.push(e)}))}if(o){var s=nodeListToArray(this.el.querySelectorAll("calcite-tree-item[selected]"));s.forEach((function(e){if(!l.includes(e)){e.selected=false}}))}if(c&&!e.detail.forceToggle){t.expanded=true}if(a){window.getSelection().removeAllRanges()}if(a&&t.selected||r&&e.detail.forceToggle){l.forEach((function(e){e.selected=false}))}else{l.forEach((function(e){e.selected=true}))}}this.calciteTreeSelect.emit({selected:nodeListToArray(this.el.querySelectorAll("calcite-tree-item")).filter((function(e){return e.selected}))})};e.prototype.updateAncestorTree=function(e){var t=e.target;var i=t.querySelectorAll("calcite-tree-item");var n=[];var a=t.parentElement.closest("calcite-tree-item");while(a){n.push(a);a=a.parentElement.closest("calcite-tree-item")}t.selected=!t.selected;t.indeterminate=false;if(i===null||i===void 0?void 0:i.length){i.forEach((function(e){e.selected=t.selected;e.indeterminate=false}))}if(n){n.forEach((function(e){var t=nodeListToArray(e.querySelectorAll("calcite-tree-item"));var i=t.filter((function(e){return e.selected}));if(i.length===0){e.selected=false;e.indeterminate=false;return}var n=i.length<t.length;e.indeterminate=n;e.selected=!n}))}this.calciteTreeSelect.emit({selected:nodeListToArray(this.el.querySelectorAll("calcite-tree-item")).filter((function(e){return e.selected}))})};e.prototype.getRootTabIndex=function(){return!this.child?0:-1};Object.defineProperty(e.prototype,"el",{get:function(){return getElement(this)},enumerable:false,configurable:true});return e}();CalciteTree.style=calciteTreeCss;var CSS={checkboxLabel:"checkbox-label",checkbox:"checkbox",chevron:"chevron",nodeContainer:"node-container",childrenContainer:"children-container",bulletPointIcon:"bullet-point",checkmarkIcon:"checkmark"};var SLOTS={children:"children"};var ICONS={bulletPoint:"bullet-point",checkmark:"check",chevronRight:"chevron-right"};var calciteTreeItemCss='@-webkit-keyframes in{0%{opacity:0}100%{opacity:1}}@keyframes in{0%{opacity:0}100%{opacity:1}}@-webkit-keyframes in-down{0%{opacity:0;-webkit-transform:translate3D(0, -5px, 0);transform:translate3D(0, -5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@keyframes in-down{0%{opacity:0;-webkit-transform:translate3D(0, -5px, 0);transform:translate3D(0, -5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@-webkit-keyframes in-up{0%{opacity:0;-webkit-transform:translate3D(0, 5px, 0);transform:translate3D(0, 5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@keyframes in-up{0%{opacity:0;-webkit-transform:translate3D(0, 5px, 0);transform:translate3D(0, 5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@-webkit-keyframes in-scale{0%{opacity:0;-webkit-transform:scale3D(0.95, 0.95, 1);transform:scale3D(0.95, 0.95, 1)}100%{opacity:1;-webkit-transform:scale3D(1, 1, 1);transform:scale3D(1, 1, 1)}}@keyframes in-scale{0%{opacity:0;-webkit-transform:scale3D(0.95, 0.95, 1);transform:scale3D(0.95, 0.95, 1)}100%{opacity:1;-webkit-transform:scale3D(1, 1, 1);transform:scale3D(1, 1, 1)}}:root{--calcite-animation-timing:calc(150ms * var(--calcite-internal-duration-factor));--calcite-internal-duration-factor:var(--calcite-duration-factor, 1);--calcite-internal-animation-timing-fast:calc(100ms * var(--calcite-internal-duration-factor));--calcite-internal-animation-timing-medium:calc(200ms * var(--calcite-internal-duration-factor));--calcite-internal-animation-timing-slow:calc(300ms * var(--calcite-internal-duration-factor))}.calcite-animate{opacity:0;-webkit-animation-fill-mode:both;animation-fill-mode:both;-webkit-animation-duration:var(--calcite-animation-timing);animation-duration:var(--calcite-animation-timing)}.calcite-animate__in{-webkit-animation-name:in;animation-name:in}.calcite-animate__in-down{-webkit-animation-name:in-down;animation-name:in-down}.calcite-animate__in-up{-webkit-animation-name:in-up;animation-name:in-up}.calcite-animate__in-scale{-webkit-animation-name:in-scale;animation-name:in-scale}:root{--calcite-popper-transition:150ms ease-in-out}:host([hidden]){display:none}:host{display:block;cursor:pointer;outline:2px solid transparent;outline-offset:2px;max-width:100%;color:var(--calcite-ui-text-3)}:host([scale=s]){font-size:var(--calcite-font-size--2);line-height:1rem}:host([scale=s]) .node-container{--calcite-tree-padding-y:0.25rem}:host([scale=s]) .node-container .checkbox,:host([scale=s]) .node-container .chevron,:host([scale=s]) .node-container .checkmark,:host([scale=s]) .node-container .bullet-point{margin-inline:0.25rem}:host([scale=m]){font-size:var(--calcite-font-size--1);line-height:1rem}:host([scale=m]) .node-container{--calcite-tree-padding-y:0.5rem}:host([scale=m]) .node-container .checkbox,:host([scale=m]) .node-container .chevron,:host([scale=m]) .node-container .checkmark,:host([scale=m]) .node-container .bullet-point{margin-inline:0.5rem}:host([scale=l]){font-size:var(--calcite-font-size-0);line-height:1.25rem}:host([scale=l]) .node-container{--calcite-tree-padding-y:0.75rem}:host([scale=l]) .node-container .checkbox,:host([scale=l]) .node-container .chevron,:host([scale=l]) .node-container .checkmark,:host([scale=l]) .node-container .bullet-point{margin-inline:0.75rem}:host([lines]) .children-container:after{-webkit-transition-property:all;transition-property:all;-webkit-transition-duration:var(--calcite-animation-timing);transition-duration:var(--calcite-animation-timing);-webkit-transition-timing-function:ease-in-out;transition-timing-function:ease-in-out;-webkit-transition-delay:0s;transition-delay:0s;-webkit-transition-property:background-color, border-color, color, fill, stroke;transition-property:background-color, border-color, color, fill, stroke;top:0;position:absolute;width:1px;height:96%;content:"";background-color:var(--calcite-ui-border-2);z-index:-1}:host(:not([lines])) .node-container:after{display:none}::slotted(*){word-wrap:break-word;overflow-wrap:break-word;min-width:0;max-width:100%;color:inherit;text-decoration:none !important}::slotted(*):hover{text-decoration:none !important}::slotted(a){width:100%;text-decoration:none}:host{outline-offset:0;outline-color:transparent;-webkit-transition:outline-offset 100ms ease-in-out, outline-color 100ms ease-in-out;transition:outline-offset 100ms ease-in-out, outline-color 100ms ease-in-out}:host(:focus){outline:2px solid var(--calcite-ui-brand);outline-offset:-2px}.checkbox{outline:2px solid transparent;outline-offset:2px;line-height:0}.checkbox-label{display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;pointer-events:none}.children-container{position:relative;overflow:hidden;height:0;-webkit-margin-start:1.25rem;margin-inline-start:1.25rem;-webkit-transform:scaleY(0);transform:scaleY(0);opacity:0;-webkit-transition:var(--calcite-animation-timing) cubic-bezier(0.215, 0.44, 0.42, 0.88), opacity var(--calcite-animation-timing) cubic-bezier(0.215, 0.44, 0.42, 0.88), all var(--calcite-animation-timing) ease-in-out;transition:var(--calcite-animation-timing) cubic-bezier(0.215, 0.44, 0.42, 0.88), opacity var(--calcite-animation-timing) cubic-bezier(0.215, 0.44, 0.42, 0.88), all var(--calcite-animation-timing) ease-in-out;-webkit-transform-origin:top;transform-origin:top}:host([expanded])>.children-container{-webkit-transform:scaleY(1);transform:scaleY(1);opacity:1;height:auto}.node-container{display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;position:relative;padding:var(--calcite-tree-padding-y) 0}.node-container .checkmark,.node-container .bullet-point{-webkit-transition-property:all;transition-property:all;-webkit-transition-duration:var(--calcite-animation-timing);transition-duration:var(--calcite-animation-timing);-webkit-transition-timing-function:ease-in-out;transition-timing-function:ease-in-out;-webkit-transition-delay:0s;transition-delay:0s;opacity:0;color:var(--calcite-ui-border-1)}.node-container:hover .checkmark,.node-container:hover .bullet-point,:host([selected]) .node-container:hover .checkmark,:host([selected]) .node-container:hover .bullet-point,:host(:focus) .node-container .checkmark,:host(:focus) .node-container .bullet-point{opacity:1}:host([selected])>.node-container,:host([selected])>.node-container:hover{font-weight:var(--calcite-font-weight-medium);color:var(--calcite-ui-text-1)}:host([selected])>.node-container .bullet-point,:host([selected])>.node-container .checkmark,:host([selected])>.node-container:hover .bullet-point,:host([selected])>.node-container:hover .checkmark{opacity:1;color:var(--calcite-ui-brand)}:host(:not([has-children])):host([scale=s])>.node-container[data-selection-mode=ancestors] .checkbox{-webkit-padding-start:1.25rem;padding-inline-start:1.25rem}:host(:not([has-children])):host([scale=m])>.node-container[data-selection-mode=ancestors] .checkbox{-webkit-padding-start:1.5rem;padding-inline-start:1.5rem}:host(:not([has-children])):host([scale=l])>.node-container[data-selection-mode=ancestors] .checkbox{-webkit-padding-start:1.75rem;padding-inline-start:1.75rem}:host([has-children])>.node-container[data-selection-mode=ancestors] .checkbox{-webkit-margin-start:0;margin-inline-start:0}:host([has-children])>.node-container .bullet-point,:host([has-children])>.node-container .checkmark{display:none}:host([has-children][expanded]:not([selected]))>.node-container ::slotted(*){font-weight:var(--calcite-font-weight-medium);color:var(--calcite-ui-text-1)}:host([has-children][selected])>.node-container[data-selection-mode=children],:host([has-children][selected])>.node-container[data-selection-mode=multi-children]{color:var(--calcite-ui-brand)}.chevron{-webkit-transition-property:all;transition-property:all;-webkit-transition-duration:var(--calcite-animation-timing);transition-duration:var(--calcite-animation-timing);-webkit-transition-timing-function:ease-in-out;transition-timing-function:ease-in-out;-webkit-transition-delay:0s;transition-delay:0s;position:relative;-ms-flex-item-align:center;align-self:center;color:var(--calcite-ui-text-3);-ms-flex:0 0 auto;flex:0 0 auto;-webkit-transform:rotate(0deg);transform:rotate(0deg)}.calcite--rtl .chevron{-webkit-transform:rotate(180deg);transform:rotate(180deg)}:host([expanded])>.node-container>.chevron{-webkit-transform:rotate(90deg);transform:rotate(90deg)}:host([selected]) .checkmark,:host([selected]) .bullet-point{color:var(--calcite-ui-brand)}';var CalciteTreeItem=function(){function e(e){var t=this;registerInstance(this,e);this.calciteTreeItemSelect=createEvent(this,"calciteTreeItemSelect",7);this.selected=false;this.expanded=false;this.parentExpanded=false;this.depth=-1;this.hasChildren=null;this.iconClickHandler=function(e){e.stopPropagation();t.expanded=!t.expanded;if(t.selectionMode!==TreeSelectionMode.Ancestors){t.calciteTreeItemSelect.emit({modifyCurrentSelection:e.shiftKey,forceToggle:true})}};this.childrenClickHandler=function(e){return e.stopPropagation()};this.updateParentIsExpanded=function(e,t){var i=getSlotted(e,SLOTS.children,{all:true,selector:"calcite-tree-item"});i.forEach((function(e){return e.parentExpanded=t}))};this.updateAncestorTree=function(){if(t.selected&&t.selectionMode===TreeSelectionMode.Ancestors){var e=[];var i=t.parentTreeItem;while(i){e.push(i);i=i.parentElement.closest("calcite-tree-item")}e.forEach((function(e){return e.indeterminate=true}));return}}}e.prototype.expandedHandler=function(e){this.updateParentIsExpanded(this.el,e)};e.prototype.connectedCallback=function(){this.parentTreeItem=this.el.parentElement.closest("calcite-tree-item");if(this.parentTreeItem){var e=this.parentTreeItem.expanded;this.updateParentIsExpanded(this.parentTreeItem,e)}};e.prototype.componentWillRender=function(){this.hasChildren=!!this.el.querySelector("calcite-tree");this.depth=0;var e=this.el.closest("calcite-tree");if(!e){return}this.selectionMode=e.selectionMode;this.scale=e.scale||"m";this.lines=e.lines;var t;while(e){t=e.parentElement.closest("calcite-tree");if(t===e){break}else{e=t;this.depth=this.depth+1}}};e.prototype.componentDidLoad=function(){this.updateAncestorTree()};e.prototype.render=function(){var e,t,i,n;var a=this;var r=getElementDir(this.el)==="rtl";var o=this.selectionMode===TreeSelectionMode.Single||this.selectionMode===TreeSelectionMode.Children;var c=this.selectionMode===TreeSelectionMode.Multi||this.selectionMode===TreeSelectionMode.MultiChildren;var l=this.hasChildren?h("calcite-icon",{class:(e={},e[CSS.chevron]=true,e[CSS_UTILITY.rtl]=r,e),"data-test-id":"icon",icon:ICONS.chevronRight,onClick:this.iconClickHandler,scale:"s"}):null;var s=this.selectionMode===TreeSelectionMode.Ancestors?h("label",{class:CSS.checkboxLabel},h("calcite-checkbox",{checked:this.selected,class:CSS.checkbox,"data-test-id":"checkbox",indeterminate:this.hasChildren&&this.indeterminate,scale:this.scale,tabIndex:-1}),h("slot",null)):null;var d=o?ICONS.bulletPoint:c?ICONS.checkmark:null;var m=d?h("calcite-icon",{class:(t={},t[CSS.bulletPointIcon]=d===ICONS.bulletPoint,t[CSS.checkmarkIcon]=d===ICONS.checkmark,t[CSS_UTILITY.rtl]=r,t),icon:d,scale:"s"}):null;var f=!(this.parentExpanded||this.depth===1);return h(Host,{"aria-expanded":this.hasChildren?this.expanded.toString():undefined,"aria-hidden":f.toString(),"aria-selected":this.selected?"true":c?"false":undefined,"calcite-hydrated-hidden":f,role:"treeitem",tabindex:this.parentExpanded||this.depth===1?"0":"-1"},h("div",{class:(i={},i[CSS.nodeContainer]=true,i[CSS_UTILITY.rtl]=r,i),"data-selection-mode":this.selectionMode,ref:function(e){return a.defaultSlotWrapper=e}},l,m,s?s:h("slot",null)),h("div",{class:(n={},n[CSS.childrenContainer]=true,n[CSS_UTILITY.rtl]=r,n),"data-test-id":"calcite-tree-children",onClick:this.childrenClickHandler,ref:function(e){return a.childrenSlotWrapper=e},role:this.hasChildren?"group":undefined},h("slot",{name:SLOTS.children})))};e.prototype.onClick=function(e){var t=filterDirectChildren(this.el,"a")[0];if(t&&e.composedPath()[0].tagName.toLowerCase()!=="a"){var i=t.target===""?"_self":t.target;window.open(t.href,i)}this.expanded=!this.expanded;this.calciteTreeItemSelect.emit({modifyCurrentSelection:e.shiftKey||this.selectionMode===TreeSelectionMode.Ancestors,forceToggle:false})};e.prototype.keyDownHandler=function(e){var t;switch(e.key){case" ":this.calciteTreeItemSelect.emit({modifyCurrentSelection:e.shiftKey,forceToggle:false});e.preventDefault();e.stopPropagation();break;case"Enter":var i=nodeListToArray(this.el.children).find((function(e){return e.matches("a")}));if(i){i.click();this.selected=true}else{this.calciteTreeItemSelect.emit({modifyCurrentSelection:e.shiftKey,forceToggle:false})}e.preventDefault();e.stopPropagation();break;case"ArrowLeft":if(this.hasChildren&&this.expanded){this.expanded=false;e.preventDefault();e.stopPropagation();break}var n=this.parentTreeItem;if(n&&(!this.hasChildren||this.expanded===false)){n.focus();e.preventDefault();e.stopPropagation();break}break;case"ArrowRight":if(this.hasChildren&&this.expanded===false){this.expanded=true;e.preventDefault();e.stopPropagation();break}if(this.hasChildren&&this.expanded){this.el.querySelector("calcite-tree-item").focus();break}break;case"ArrowUp":var a=this.el.previousElementSibling;if(a&&a.matches("calcite-tree-item")){a.focus()}break;case"ArrowDown":var r=this.el.nextElementSibling;if(r&&r.matches("calcite-tree-item")){r.focus()}break;case"Home":t=this.el.closest("calcite-tree:not([child])");var o=t.querySelector("calcite-tree-item");o.focus();break;case"End":t=this.el.closest("calcite-tree:not([child])");var c=t.children[t.children.length-1];var l=nodeListToArray(c.children).find((function(e){return e.matches("calcite-tree")}));while(l){c=l.children[t.children.length-1];l=nodeListToArray(c.children).find((function(e){return e.matches("calcite-tree")}))}c.focus();break}};Object.defineProperty(e.prototype,"el",{get:function(){return getElement(this)},enumerable:false,configurable:true});Object.defineProperty(e,"watchers",{get:function(){return{expanded:["expandedHandler"]}},enumerable:false,configurable:true});return e}();CalciteTreeItem.style=calciteTreeItemCss;export{CalciteTree as calcite_tree,CalciteTreeItem as calcite_tree_item};
|
|
5
|
+
import{r as registerInstance,c as createEvent,h,H as Host,g as getElement}from"./index-9de00868.js";import{f as focusElement,n as nodeListToArray,g as getSlotted,a as getElementDir,C as CSS_UTILITY,k as filterDirectChildren}from"./dom-e55f9eaf.js";import"./guid-196bd5ea.js";var TreeSelectionMode;(function(e){e["Single"]="single";e["Multi"]="multi";e["Children"]="children";e["MultiChildren"]="multi-children";e["Ancestors"]="ancestors"})(TreeSelectionMode||(TreeSelectionMode={}));var calciteTreeCss="@-webkit-keyframes in{0%{opacity:0}100%{opacity:1}}@keyframes in{0%{opacity:0}100%{opacity:1}}@-webkit-keyframes in-down{0%{opacity:0;-webkit-transform:translate3D(0, -5px, 0);transform:translate3D(0, -5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@keyframes in-down{0%{opacity:0;-webkit-transform:translate3D(0, -5px, 0);transform:translate3D(0, -5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@-webkit-keyframes in-up{0%{opacity:0;-webkit-transform:translate3D(0, 5px, 0);transform:translate3D(0, 5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@keyframes in-up{0%{opacity:0;-webkit-transform:translate3D(0, 5px, 0);transform:translate3D(0, 5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@-webkit-keyframes in-scale{0%{opacity:0;-webkit-transform:scale3D(0.95, 0.95, 1);transform:scale3D(0.95, 0.95, 1)}100%{opacity:1;-webkit-transform:scale3D(1, 1, 1);transform:scale3D(1, 1, 1)}}@keyframes in-scale{0%{opacity:0;-webkit-transform:scale3D(0.95, 0.95, 1);transform:scale3D(0.95, 0.95, 1)}100%{opacity:1;-webkit-transform:scale3D(1, 1, 1);transform:scale3D(1, 1, 1)}}:root{--calcite-animation-timing:calc(150ms * var(--calcite-internal-duration-factor));--calcite-internal-duration-factor:var(--calcite-duration-factor, 1);--calcite-internal-animation-timing-fast:calc(100ms * var(--calcite-internal-duration-factor));--calcite-internal-animation-timing-medium:calc(200ms * var(--calcite-internal-duration-factor));--calcite-internal-animation-timing-slow:calc(300ms * var(--calcite-internal-duration-factor))}.calcite-animate{opacity:0;-webkit-animation-fill-mode:both;animation-fill-mode:both;-webkit-animation-duration:var(--calcite-animation-timing);animation-duration:var(--calcite-animation-timing)}.calcite-animate__in{-webkit-animation-name:in;animation-name:in}.calcite-animate__in-down{-webkit-animation-name:in-down;animation-name:in-down}.calcite-animate__in-up{-webkit-animation-name:in-up;animation-name:in-up}.calcite-animate__in-scale{-webkit-animation-name:in-scale;animation-name:in-scale}:root{--calcite-popper-transition:var(--calcite-animation-timing)}:host([hidden]){display:none}:host{display:block;outline:2px solid transparent;outline-offset:2px}";var CalciteTree=function(){function e(e){registerInstance(this,e);this.calciteTreeSelect=createEvent(this,"calciteTreeSelect",7);this.lines=false;this.inputEnabled=false;this.scale="m";this.selectionMode=TreeSelectionMode.Single}e.prototype.componentWillRender=function(){var e=this.el.parentElement.closest("calcite-tree");this.lines=e?e.lines:this.lines;this.scale=e?e.scale:this.scale;this.selectionMode=e?e.selectionMode:this.selectionMode;this.child=!!e};e.prototype.render=function(){return h(Host,{"aria-multiselectable":(this.selectionMode===TreeSelectionMode.Multi||this.selectionMode===TreeSelectionMode.MultiChildren).toString(),role:!this.child?"tree":undefined,tabIndex:this.getRootTabIndex()},h("slot",null))};e.prototype.onFocus=function(){if(!this.child){var e=this.el.querySelector("calcite-tree-item[selected]")||this.el.querySelector("calcite-tree-item");focusElement(e)}};e.prototype.onFocusIn=function(e){var t=e.relatedTarget===this.el||!this.el.contains(e.relatedTarget);if(t){this.el.tabIndex=-1}};e.prototype.onFocusOut=function(e){var t=!this.el.contains(e.relatedTarget);if(t){this.el.tabIndex=this.getRootTabIndex()}};e.prototype.onClick=function(e){var t=e.target;var i=nodeListToArray(t.querySelectorAll("calcite-tree-item"));if(this.child){return}if(!this.child){e.preventDefault();e.stopPropagation()}if(this.selectionMode===TreeSelectionMode.Ancestors&&!this.child){this.updateAncestorTree(e);return}var n=this.selectionMode!==null&&(!t.hasChildren||t.hasChildren&&(this.selectionMode===TreeSelectionMode.Children||this.selectionMode===TreeSelectionMode.MultiChildren));var a=e.detail.modifyCurrentSelection&&(this.selectionMode===TreeSelectionMode.Multi||this.selectionMode===TreeSelectionMode.MultiChildren);var r=this.selectionMode===TreeSelectionMode.MultiChildren||this.selectionMode===TreeSelectionMode.Children;var o=!a&&((this.selectionMode===TreeSelectionMode.Single||this.selectionMode===TreeSelectionMode.Multi)&&i.length<=0||this.selectionMode===TreeSelectionMode.Children||this.selectionMode===TreeSelectionMode.MultiChildren);var c=this.selectionMode===TreeSelectionMode.Children||this.selectionMode===TreeSelectionMode.MultiChildren;if(!this.child){var l=[];if(n){l.push(t)}if(r){i.forEach((function(e){l.push(e)}))}if(o){var s=nodeListToArray(this.el.querySelectorAll("calcite-tree-item[selected]"));s.forEach((function(e){if(!l.includes(e)){e.selected=false}}))}if(c&&!e.detail.forceToggle){t.expanded=true}if(a){window.getSelection().removeAllRanges()}if(a&&t.selected||r&&e.detail.forceToggle){l.forEach((function(e){e.selected=false}))}else{l.forEach((function(e){e.selected=true}))}}this.calciteTreeSelect.emit({selected:nodeListToArray(this.el.querySelectorAll("calcite-tree-item")).filter((function(e){return e.selected}))})};e.prototype.updateAncestorTree=function(e){var t=e.target;var i=t.querySelectorAll("calcite-tree-item");var n=[];var a=t.parentElement.closest("calcite-tree-item");while(a){n.push(a);a=a.parentElement.closest("calcite-tree-item")}t.selected=!t.selected;t.indeterminate=false;if(i===null||i===void 0?void 0:i.length){i.forEach((function(e){e.selected=t.selected;e.indeterminate=false}))}if(n){n.forEach((function(e){var t=nodeListToArray(e.querySelectorAll("calcite-tree-item"));var i=t.filter((function(e){return e.selected}));if(i.length===0){e.selected=false;e.indeterminate=false;return}var n=i.length<t.length;e.indeterminate=n;e.selected=!n}))}this.calciteTreeSelect.emit({selected:nodeListToArray(this.el.querySelectorAll("calcite-tree-item")).filter((function(e){return e.selected}))})};e.prototype.getRootTabIndex=function(){return!this.child?0:-1};Object.defineProperty(e.prototype,"el",{get:function(){return getElement(this)},enumerable:false,configurable:true});return e}();CalciteTree.style=calciteTreeCss;var CSS={checkboxLabel:"checkbox-label",checkbox:"checkbox",chevron:"chevron",nodeContainer:"node-container",childrenContainer:"children-container",bulletPointIcon:"bullet-point",checkmarkIcon:"checkmark"};var SLOTS={children:"children"};var ICONS={bulletPoint:"bullet-point",checkmark:"check",chevronRight:"chevron-right"};var calciteTreeItemCss='@-webkit-keyframes in{0%{opacity:0}100%{opacity:1}}@keyframes in{0%{opacity:0}100%{opacity:1}}@-webkit-keyframes in-down{0%{opacity:0;-webkit-transform:translate3D(0, -5px, 0);transform:translate3D(0, -5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@keyframes in-down{0%{opacity:0;-webkit-transform:translate3D(0, -5px, 0);transform:translate3D(0, -5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@-webkit-keyframes in-up{0%{opacity:0;-webkit-transform:translate3D(0, 5px, 0);transform:translate3D(0, 5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@keyframes in-up{0%{opacity:0;-webkit-transform:translate3D(0, 5px, 0);transform:translate3D(0, 5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@-webkit-keyframes in-scale{0%{opacity:0;-webkit-transform:scale3D(0.95, 0.95, 1);transform:scale3D(0.95, 0.95, 1)}100%{opacity:1;-webkit-transform:scale3D(1, 1, 1);transform:scale3D(1, 1, 1)}}@keyframes in-scale{0%{opacity:0;-webkit-transform:scale3D(0.95, 0.95, 1);transform:scale3D(0.95, 0.95, 1)}100%{opacity:1;-webkit-transform:scale3D(1, 1, 1);transform:scale3D(1, 1, 1)}}:root{--calcite-animation-timing:calc(150ms * var(--calcite-internal-duration-factor));--calcite-internal-duration-factor:var(--calcite-duration-factor, 1);--calcite-internal-animation-timing-fast:calc(100ms * var(--calcite-internal-duration-factor));--calcite-internal-animation-timing-medium:calc(200ms * var(--calcite-internal-duration-factor));--calcite-internal-animation-timing-slow:calc(300ms * var(--calcite-internal-duration-factor))}.calcite-animate{opacity:0;-webkit-animation-fill-mode:both;animation-fill-mode:both;-webkit-animation-duration:var(--calcite-animation-timing);animation-duration:var(--calcite-animation-timing)}.calcite-animate__in{-webkit-animation-name:in;animation-name:in}.calcite-animate__in-down{-webkit-animation-name:in-down;animation-name:in-down}.calcite-animate__in-up{-webkit-animation-name:in-up;animation-name:in-up}.calcite-animate__in-scale{-webkit-animation-name:in-scale;animation-name:in-scale}:root{--calcite-popper-transition:var(--calcite-animation-timing)}:host([hidden]){display:none}:host{display:block;max-width:100%;cursor:pointer;color:var(--calcite-ui-text-3);outline:2px solid transparent;outline-offset:2px}:host([scale=s]){font-size:var(--calcite-font-size--2);line-height:1rem}:host([scale=s]) .node-container{--calcite-tree-padding-y:0.25rem}:host([scale=s]) .node-container .checkbox,:host([scale=s]) .node-container .chevron,:host([scale=s]) .node-container .checkmark,:host([scale=s]) .node-container .bullet-point{margin-inline:0.25rem}:host([scale=m]){font-size:var(--calcite-font-size--1);line-height:1rem}:host([scale=m]) .node-container{--calcite-tree-padding-y:0.5rem}:host([scale=m]) .node-container .checkbox,:host([scale=m]) .node-container .chevron,:host([scale=m]) .node-container .checkmark,:host([scale=m]) .node-container .bullet-point{margin-inline:0.5rem}:host([scale=l]){font-size:var(--calcite-font-size-0);line-height:1.25rem}:host([scale=l]) .node-container{--calcite-tree-padding-y:0.75rem}:host([scale=l]) .node-container .checkbox,:host([scale=l]) .node-container .chevron,:host([scale=l]) .node-container .checkmark,:host([scale=l]) .node-container .bullet-point{margin-inline:0.75rem}:host([lines]) .children-container:after{position:absolute;top:0px;width:1px;-webkit-transition-property:all;transition-property:all;-webkit-transition-duration:var(--calcite-animation-timing);transition-duration:var(--calcite-animation-timing);-webkit-transition-timing-function:ease-in-out;transition-timing-function:ease-in-out;-webkit-transition-delay:0s;transition-delay:0s;height:96%;content:"";background-color:var(--calcite-ui-border-2);z-index:-1}:host(:not([lines])) .node-container:after{display:none}::slotted(*){min-width:0px;max-width:100%;overflow-wrap:break-word;color:inherit;text-decoration:none !important}::slotted(*):hover{text-decoration:none !important}::slotted(a){width:100%;-webkit-text-decoration-line:none;text-decoration-line:none}:host{outline-offset:0;outline-color:transparent;-webkit-transition:outline-offset 100ms ease-in-out, outline-color 100ms ease-in-out;transition:outline-offset 100ms ease-in-out, outline-color 100ms ease-in-out}:host(:focus){outline:2px solid var(--calcite-ui-brand);outline-offset:-2px}.checkbox{outline:2px solid transparent;outline-offset:2px;line-height:0}.checkbox-label{pointer-events:none;display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center}.children-container{position:relative;height:0px;overflow:hidden;-webkit-margin-start:1.25rem;margin-inline-start:1.25rem;-webkit-transform:scaleY(0);transform:scaleY(0);opacity:0;-webkit-transition:var(--calcite-animation-timing) cubic-bezier(0.215, 0.44, 0.42, 0.88), opacity var(--calcite-animation-timing) cubic-bezier(0.215, 0.44, 0.42, 0.88), all var(--calcite-animation-timing) ease-in-out;transition:var(--calcite-animation-timing) cubic-bezier(0.215, 0.44, 0.42, 0.88), opacity var(--calcite-animation-timing) cubic-bezier(0.215, 0.44, 0.42, 0.88), all var(--calcite-animation-timing) ease-in-out;-webkit-transform-origin:top;transform-origin:top}:host([expanded])>.children-container{-webkit-transform:scaleY(1);transform:scaleY(1);opacity:1;height:auto}.node-container{position:relative;display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;padding:var(--calcite-tree-padding-y) 0}.node-container .checkmark,.node-container .bullet-point{opacity:0;-webkit-transition-property:all;transition-property:all;-webkit-transition-duration:var(--calcite-animation-timing);transition-duration:var(--calcite-animation-timing);-webkit-transition-timing-function:ease-in-out;transition-timing-function:ease-in-out;-webkit-transition-delay:0s;transition-delay:0s;color:var(--calcite-ui-border-1)}.node-container:hover .checkmark,.node-container:hover .bullet-point,:host([selected]) .node-container:hover .checkmark,:host([selected]) .node-container:hover .bullet-point,:host(:focus) .node-container .checkmark,:host(:focus) .node-container .bullet-point{opacity:1}:host([selected])>.node-container,:host([selected])>.node-container:hover{font-weight:var(--calcite-font-weight-medium);color:var(--calcite-ui-text-1)}:host([selected])>.node-container .bullet-point,:host([selected])>.node-container .checkmark,:host([selected])>.node-container:hover .bullet-point,:host([selected])>.node-container:hover .checkmark{opacity:1;color:var(--calcite-ui-brand)}:host(:not([has-children])):host([scale=s])>.node-container[data-selection-mode=ancestors] .checkbox{-webkit-padding-start:1.25rem;padding-inline-start:1.25rem}:host(:not([has-children])):host([scale=m])>.node-container[data-selection-mode=ancestors] .checkbox{-webkit-padding-start:1.5rem;padding-inline-start:1.5rem}:host(:not([has-children])):host([scale=l])>.node-container[data-selection-mode=ancestors] .checkbox{-webkit-padding-start:1.75rem;padding-inline-start:1.75rem}:host([has-children])>.node-container[data-selection-mode=ancestors] .checkbox{-webkit-margin-start:0;margin-inline-start:0}:host([has-children])>.node-container .bullet-point,:host([has-children])>.node-container .checkmark{display:none}:host([has-children][expanded]:not([selected]))>.node-container ::slotted(*){font-weight:var(--calcite-font-weight-medium);color:var(--calcite-ui-text-1)}:host([has-children][selected])>.node-container[data-selection-mode=children],:host([has-children][selected])>.node-container[data-selection-mode=multi-children]{color:var(--calcite-ui-brand)}.chevron{position:relative;-ms-flex-item-align:center;align-self:center;color:var(--calcite-ui-text-3);-webkit-transition-property:all;transition-property:all;-webkit-transition-duration:var(--calcite-animation-timing);transition-duration:var(--calcite-animation-timing);-webkit-transition-timing-function:ease-in-out;transition-timing-function:ease-in-out;-webkit-transition-delay:0s;transition-delay:0s;-ms-flex:0 0 auto;flex:0 0 auto;-webkit-transform:rotate(0deg);transform:rotate(0deg)}.calcite--rtl .chevron{-webkit-transform:rotate(180deg);transform:rotate(180deg)}:host([expanded])>.node-container>.chevron{-webkit-transform:rotate(90deg);transform:rotate(90deg)}:host([selected]) .checkmark,:host([selected]) .bullet-point{color:var(--calcite-ui-brand)}';var CalciteTreeItem=function(){function e(e){var t=this;registerInstance(this,e);this.calciteTreeItemSelect=createEvent(this,"calciteTreeItemSelect",7);this.selected=false;this.expanded=false;this.parentExpanded=false;this.depth=-1;this.hasChildren=null;this.iconClickHandler=function(e){e.stopPropagation();t.expanded=!t.expanded;if(t.selectionMode!==TreeSelectionMode.Ancestors){t.calciteTreeItemSelect.emit({modifyCurrentSelection:e.shiftKey,forceToggle:true})}};this.childrenClickHandler=function(e){return e.stopPropagation()};this.updateParentIsExpanded=function(e,t){var i=getSlotted(e,SLOTS.children,{all:true,selector:"calcite-tree-item"});i.forEach((function(e){return e.parentExpanded=t}))};this.updateAncestorTree=function(){if(t.selected&&t.selectionMode===TreeSelectionMode.Ancestors){var e=[];var i=t.parentTreeItem;while(i){e.push(i);i=i.parentElement.closest("calcite-tree-item")}e.forEach((function(e){return e.indeterminate=true}));return}}}e.prototype.expandedHandler=function(e){this.updateParentIsExpanded(this.el,e)};e.prototype.connectedCallback=function(){this.parentTreeItem=this.el.parentElement.closest("calcite-tree-item");if(this.parentTreeItem){var e=this.parentTreeItem.expanded;this.updateParentIsExpanded(this.parentTreeItem,e)}};e.prototype.componentWillRender=function(){this.hasChildren=!!this.el.querySelector("calcite-tree");this.depth=0;var e=this.el.closest("calcite-tree");if(!e){return}this.selectionMode=e.selectionMode;this.scale=e.scale||"m";this.lines=e.lines;var t;while(e){t=e.parentElement.closest("calcite-tree");if(t===e){break}else{e=t;this.depth=this.depth+1}}};e.prototype.componentDidLoad=function(){this.updateAncestorTree()};e.prototype.render=function(){var e,t,i,n;var a=this;var r=getElementDir(this.el)==="rtl";var o=this.selectionMode===TreeSelectionMode.Single||this.selectionMode===TreeSelectionMode.Children;var c=this.selectionMode===TreeSelectionMode.Multi||this.selectionMode===TreeSelectionMode.MultiChildren;var l=this.hasChildren?h("calcite-icon",{class:(e={},e[CSS.chevron]=true,e[CSS_UTILITY.rtl]=r,e),"data-test-id":"icon",icon:ICONS.chevronRight,onClick:this.iconClickHandler,scale:"s"}):null;var s=this.selectionMode===TreeSelectionMode.Ancestors?h("label",{class:CSS.checkboxLabel},h("calcite-checkbox",{checked:this.selected,class:CSS.checkbox,"data-test-id":"checkbox",indeterminate:this.hasChildren&&this.indeterminate,scale:this.scale,tabIndex:-1}),h("slot",null)):null;var d=o?ICONS.bulletPoint:c?ICONS.checkmark:null;var m=d?h("calcite-icon",{class:(t={},t[CSS.bulletPointIcon]=d===ICONS.bulletPoint,t[CSS.checkmarkIcon]=d===ICONS.checkmark,t[CSS_UTILITY.rtl]=r,t),icon:d,scale:"s"}):null;var f=!(this.parentExpanded||this.depth===1);return h(Host,{"aria-expanded":this.hasChildren?this.expanded.toString():undefined,"aria-hidden":f.toString(),"aria-selected":this.selected?"true":c?"false":undefined,"calcite-hydrated-hidden":f,role:"treeitem",tabindex:this.parentExpanded||this.depth===1?"0":"-1"},h("div",{class:(i={},i[CSS.nodeContainer]=true,i[CSS_UTILITY.rtl]=r,i),"data-selection-mode":this.selectionMode,ref:function(e){return a.defaultSlotWrapper=e}},l,m,s?s:h("slot",null)),h("div",{class:(n={},n[CSS.childrenContainer]=true,n[CSS_UTILITY.rtl]=r,n),"data-test-id":"calcite-tree-children",onClick:this.childrenClickHandler,ref:function(e){return a.childrenSlotWrapper=e},role:this.hasChildren?"group":undefined},h("slot",{name:SLOTS.children})))};e.prototype.onClick=function(e){var t=filterDirectChildren(this.el,"a")[0];if(t&&e.composedPath()[0].tagName.toLowerCase()!=="a"){var i=t.target===""?"_self":t.target;window.open(t.href,i)}this.expanded=!this.expanded;this.calciteTreeItemSelect.emit({modifyCurrentSelection:e.shiftKey||this.selectionMode===TreeSelectionMode.Ancestors,forceToggle:false})};e.prototype.keyDownHandler=function(e){var t;switch(e.key){case" ":this.calciteTreeItemSelect.emit({modifyCurrentSelection:e.shiftKey,forceToggle:false});e.preventDefault();e.stopPropagation();break;case"Enter":var i=nodeListToArray(this.el.children).find((function(e){return e.matches("a")}));if(i){i.click();this.selected=true}else{this.calciteTreeItemSelect.emit({modifyCurrentSelection:e.shiftKey,forceToggle:false})}e.preventDefault();e.stopPropagation();break;case"ArrowLeft":if(this.hasChildren&&this.expanded){this.expanded=false;e.preventDefault();e.stopPropagation();break}var n=this.parentTreeItem;if(n&&(!this.hasChildren||this.expanded===false)){n.focus();e.preventDefault();e.stopPropagation();break}break;case"ArrowRight":if(this.hasChildren&&this.expanded===false){this.expanded=true;e.preventDefault();e.stopPropagation();break}if(this.hasChildren&&this.expanded){this.el.querySelector("calcite-tree-item").focus();break}break;case"ArrowUp":var a=this.el.previousElementSibling;if(a&&a.matches("calcite-tree-item")){a.focus()}break;case"ArrowDown":var r=this.el.nextElementSibling;if(r&&r.matches("calcite-tree-item")){r.focus()}break;case"Home":t=this.el.closest("calcite-tree:not([child])");var o=t.querySelector("calcite-tree-item");o.focus();break;case"End":t=this.el.closest("calcite-tree:not([child])");var c=t.children[t.children.length-1];var l=nodeListToArray(c.children).find((function(e){return e.matches("calcite-tree")}));while(l){c=l.children[t.children.length-1];l=nodeListToArray(c.children).find((function(e){return e.matches("calcite-tree")}))}c.focus();break}};Object.defineProperty(e.prototype,"el",{get:function(){return getElement(this)},enumerable:false,configurable:true});Object.defineProperty(e,"watchers",{get:function(){return{expanded:["expandedHandler"]}},enumerable:false,configurable:true});return e}();CalciteTreeItem.style=calciteTreeItemCss;export{CalciteTree as calcite_tree,CalciteTreeItem as calcite_tree_item};
|
|
@@ -2,4 +2,4 @@ var __awaiter=this&&this.__awaiter||function(t,e,a,i){function n(t){return t ins
|
|
|
2
2
|
/*!
|
|
3
3
|
* All material copyright ESRI, All Rights Reserved, unless otherwise specified.
|
|
4
4
|
* See https://github.com/Esri/calcite-components/blob/master/LICENSE.md for details.
|
|
5
|
-
*/import{r as registerInstance,c as createEvent,h,g as getElement,H as Host}from"./index-9de00868.js";import{S as Sortable}from"./sortable.esm-04824d33.js";import{m as mutationObserverCallback,d as deselectSiblingItems,s as selectSiblings,h as handleFilter,g as getItemData,k as keyDownHandler,i as initialize,a as initializeObserver,c as cleanUpObserver,r as removeItem,b as calciteListItemChangeHandler,e as calciteListItemValueChangeHandler,f as setUpItems,j as setFocus,L as List,I as ICON_TYPES$1,C as CSS$1,S as SLOTS$1}from"./resources-35c1823f.js";import{g as getRoundRobinIndex}from"./array-91a648e2.js";import{c as createObserver}from"./observers-8f0bc419.js";import{g as guid}from"./guid-196bd5ea.js";import{g as getSlotted}from"./dom-f24e866c.js";import"./debounce-79648d42.js";var CSS={container:"container",handle:"handle"};var ICON_TYPES;(function(t){t["grip"]="grip"})(ICON_TYPES||(ICON_TYPES={}));var calciteValueListCss="@-webkit-keyframes in{0%{opacity:0}100%{opacity:1}}@keyframes in{0%{opacity:0}100%{opacity:1}}@-webkit-keyframes in-down{0%{opacity:0;-webkit-transform:translate3D(0, -5px, 0);transform:translate3D(0, -5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@keyframes in-down{0%{opacity:0;-webkit-transform:translate3D(0, -5px, 0);transform:translate3D(0, -5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@-webkit-keyframes in-up{0%{opacity:0;-webkit-transform:translate3D(0, 5px, 0);transform:translate3D(0, 5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@keyframes in-up{0%{opacity:0;-webkit-transform:translate3D(0, 5px, 0);transform:translate3D(0, 5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@-webkit-keyframes in-scale{0%{opacity:0;-webkit-transform:scale3D(0.95, 0.95, 1);transform:scale3D(0.95, 0.95, 1)}100%{opacity:1;-webkit-transform:scale3D(1, 1, 1);transform:scale3D(1, 1, 1)}}@keyframes in-scale{0%{opacity:0;-webkit-transform:scale3D(0.95, 0.95, 1);transform:scale3D(0.95, 0.95, 1)}100%{opacity:1;-webkit-transform:scale3D(1, 1, 1);transform:scale3D(1, 1, 1)}}:root{--calcite-animation-timing:calc(150ms * var(--calcite-internal-duration-factor));--calcite-internal-duration-factor:var(--calcite-duration-factor, 1);--calcite-internal-animation-timing-fast:calc(100ms * var(--calcite-internal-duration-factor));--calcite-internal-animation-timing-medium:calc(200ms * var(--calcite-internal-duration-factor));--calcite-internal-animation-timing-slow:calc(300ms * var(--calcite-internal-duration-factor))}.calcite-animate{opacity:0;-webkit-animation-fill-mode:both;animation-fill-mode:both;-webkit-animation-duration:var(--calcite-animation-timing);animation-duration:var(--calcite-animation-timing)}.calcite-animate__in{-webkit-animation-name:in;animation-name:in}.calcite-animate__in-down{-webkit-animation-name:in-down;animation-name:in-down}.calcite-animate__in-up{-webkit-animation-name:in-up;animation-name:in-up}.calcite-animate__in-scale{-webkit-animation-name:in-scale;animation-name:in-scale}:root{--calcite-popper-transition:150ms ease-in-out}:host([hidden]){display:none}:host{-ms-flex-align:stretch;align-items:stretch;-webkit-box-sizing:border-box;box-sizing:border-box;background-color:transparent;display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;position:relative;-ms-flex-negative:0;flex-shrink:0;-ms-flex-positive:0;flex-grow:0;color:var(--calcite-ui-text-2);font-size:var(--calcite-font-size--1)}:host *{-webkit-box-sizing:border-box;box-sizing:border-box}calcite-value-list-item:last-of-type{-webkit-box-shadow:none;box-shadow:none}:host([filter-enabled]) header{background-color:var(--calcite-ui-foreground-1);display:-ms-flexbox;display:flex;-ms-flex-pack:end;justify-content:flex-end;-ms-flex-align:center;align-items:center;margin-bottom:0.25rem;-webkit-box-shadow:0 1px 0 var(--calcite-ui-border-3);box-shadow:0 1px 0 var(--calcite-ui-border-3)}:host([filter-enabled]) header.sticky{position:-webkit-sticky;position:sticky;top:0;z-index:10}calcite-filter{margin-bottom:1px}";var CalciteValueList=function(){function t(t){var e=this;registerInstance(this,t);this.calciteListChange=createEvent(this,"calciteListChange",7);this.calciteListOrderChange=createEvent(this,"calciteListOrderChange",7);this.disabled=false;this.dragEnabled=false;this.filterEnabled=false;this.loading=false;this.multiple=false;this.selectionFollowsFocus=false;this.selectedValues=new Map;this.dataForFilter=[];this.lastSelectedItem=null;this.mutationObserver=createObserver("mutation",mutationObserverCallback.bind(this));this.setFilterEl=function(t){e.filterEl=t};this.deselectSiblingItems=deselectSiblingItems.bind(this);this.selectSiblings=selectSiblings.bind(this);this.handleFilter=handleFilter.bind(this);this.getItemData=getItemData.bind(this);this.keyDownHandler=function(t){var a=t.composedPath().find((function(t){var e;return((e=t.dataset)===null||e===void 0?void 0:e.jsHandle)!==undefined}));var i=t.composedPath().find((function(t){var e;return((e=t.tagName)===null||e===void 0?void 0:e.toLowerCase())==="calcite-value-list-item"}));if(!a||!i.handleActivated){keyDownHandler.call(e,t);return}if(t.key!=="ArrowUp"&&t.key!=="ArrowDown"){return}t.preventDefault();var n=e,r=n.el,o=n.items;var s=t.key==="ArrowDown"?1:-1;var l=o.indexOf(i);var c=getRoundRobinIndex(l+s,o.length);if(c===o.length-1){r.appendChild(i)}else{var d=r.children[c];var m=d===i.nextElementSibling?d.nextElementSibling:d;r.insertBefore(i,m)}requestAnimationFrame((function(){return a.focus()}));i.handleActivated=true}}t.prototype.connectedCallback=function(){initialize.call(this);initializeObserver.call(this)};t.prototype.componentDidLoad=function(){this.setUpDragAndDrop()};t.prototype.disconnectedCallback=function(){cleanUpObserver.call(this);this.cleanUpDragAndDrop()};t.prototype.calciteListItemRemoveHandler=function(t){removeItem.call(this,t)};t.prototype.calciteListItemChangeHandler=function(t){calciteListItemChangeHandler.call(this,t)};t.prototype.calciteListItemPropsChangeHandler=function(t){t.stopPropagation();this.setUpFilter()};t.prototype.calciteListItemValueChangeHandler=function(t){calciteListItemValueChangeHandler.call(this,t)};t.prototype.setUpItems=function(){setUpItems.call(this,"calcite-value-list-item")};t.prototype.setUpFilter=function(){if(this.filterEnabled){this.dataForFilter=this.getItemData()}};t.prototype.setUpDragAndDrop=function(){var t=this;this.cleanUpDragAndDrop();if(!this.dragEnabled){return}this.sortable=Sortable.create(this.el,{dataIdAttr:"id",handle:"."+CSS.handle,draggable:"calcite-value-list-item",group:this.group,onSort:function(){t.items=Array.from(t.el.querySelectorAll("calcite-value-list-item"));var e=t.items.map((function(t){return t.value}));t.calciteListOrderChange.emit(e)}})};t.prototype.cleanUpDragAndDrop=function(){var t;(t=this.sortable)===null||t===void 0?void 0:t.destroy();this.sortable=null};t.prototype.getSelectedItems=function(){return __awaiter(this,void 0,void 0,(function(){return __generator(this,(function(t){return[2,this.selectedValues]}))}))};t.prototype.setFocus=function(t){return __awaiter(this,void 0,void 0,(function(){return __generator(this,(function(e){return[2,setFocus.call(this,t)]}))}))};t.prototype.getIconType=function(){var t=null;if(this.dragEnabled){t=ICON_TYPES.grip}return t};t.prototype.render=function(){return h(List,{onKeyDown:this.keyDownHandler,props:this})};Object.defineProperty(t.prototype,"el",{get:function(){return getElement(this)},enumerable:false,configurable:true});return t}();CalciteValueList.style=calciteValueListCss;var ICONS={drag:"drag"};var SLOTS={actionsEnd:"actions-end",actionsStart:"actions-start"};var calciteValueListItemCss="@-webkit-keyframes in{0%{opacity:0}100%{opacity:1}}@keyframes in{0%{opacity:0}100%{opacity:1}}@-webkit-keyframes in-down{0%{opacity:0;-webkit-transform:translate3D(0, -5px, 0);transform:translate3D(0, -5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@keyframes in-down{0%{opacity:0;-webkit-transform:translate3D(0, -5px, 0);transform:translate3D(0, -5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@-webkit-keyframes in-up{0%{opacity:0;-webkit-transform:translate3D(0, 5px, 0);transform:translate3D(0, 5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@keyframes in-up{0%{opacity:0;-webkit-transform:translate3D(0, 5px, 0);transform:translate3D(0, 5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@-webkit-keyframes in-scale{0%{opacity:0;-webkit-transform:scale3D(0.95, 0.95, 1);transform:scale3D(0.95, 0.95, 1)}100%{opacity:1;-webkit-transform:scale3D(1, 1, 1);transform:scale3D(1, 1, 1)}}@keyframes in-scale{0%{opacity:0;-webkit-transform:scale3D(0.95, 0.95, 1);transform:scale3D(0.95, 0.95, 1)}100%{opacity:1;-webkit-transform:scale3D(1, 1, 1);transform:scale3D(1, 1, 1)}}:root{--calcite-animation-timing:calc(150ms * var(--calcite-internal-duration-factor));--calcite-internal-duration-factor:var(--calcite-duration-factor, 1);--calcite-internal-animation-timing-fast:calc(100ms * var(--calcite-internal-duration-factor));--calcite-internal-animation-timing-medium:calc(200ms * var(--calcite-internal-duration-factor));--calcite-internal-animation-timing-slow:calc(300ms * var(--calcite-internal-duration-factor))}.calcite-animate{opacity:0;-webkit-animation-fill-mode:both;animation-fill-mode:both;-webkit-animation-duration:var(--calcite-animation-timing);animation-duration:var(--calcite-animation-timing)}.calcite-animate__in{-webkit-animation-name:in;animation-name:in}.calcite-animate__in-down{-webkit-animation-name:in-down;animation-name:in-down}.calcite-animate__in-up{-webkit-animation-name:in-up;animation-name:in-up}.calcite-animate__in-scale{-webkit-animation-name:in-scale;animation-name:in-scale}:root{--calcite-popper-transition:150ms ease-in-out}:host([hidden]){display:none}:host{-webkit-box-sizing:border-box;box-sizing:border-box;background-color:var(--calcite-ui-foreground-1);color:var(--calcite-ui-text-2);font-size:var(--calcite-font-size--1);margin-bottom:1px;display:-ms-flexbox;display:flex;-webkit-box-shadow:0 1px 0 var(--calcite-ui-border-3);box-shadow:0 1px 0 var(--calcite-ui-border-3);-webkit-transition:background-color 150ms ease-in-out, -webkit-box-shadow 150ms ease-in-out;transition:background-color 150ms ease-in-out, -webkit-box-shadow 150ms ease-in-out;transition:background-color 150ms ease-in-out, box-shadow 150ms ease-in-out;transition:background-color 150ms ease-in-out, box-shadow 150ms ease-in-out, -webkit-box-shadow 150ms ease-in-out}:host *{-webkit-box-sizing:border-box;box-sizing:border-box}calcite-pick-list-item{-webkit-box-shadow:none;box-shadow:none;-ms-flex-positive:1;flex-grow:1;position:relative;margin:0}:host([active]),:host([selected]){-webkit-box-shadow:0 0 0 1px var(--calcite-ui-brand);box-shadow:0 0 0 1px var(--calcite-ui-brand)}.handle{display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;-ms-flex-pack:center;justify-content:center;padding-top:0;padding-bottom:0;padding-left:0.25rem;padding-right:0.25rem;background-color:transparent;border-style:none;color:var(--calcite-ui-text-1);cursor:move;color:var(--calcite-ui-border-1);outline-offset:0;outline-color:transparent;-webkit-transition:outline-offset 100ms ease-in-out, outline-color 100ms ease-in-out;transition:outline-offset 100ms ease-in-out, outline-color 100ms ease-in-out}.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}";var CalciteValueListItem=function(){function t(t){var e=this;registerInstance(this,t);this.calciteListItemRemove=createEvent(this,"calciteListItemRemove",7);this.disabled=false;this.disableDeselect=false;this.nonInteractive=false;this.handleActivated=false;this.icon=null;this.removable=false;this.selected=false;this.pickListItem=null;this.guid="calcite-value-list-item-"+guid();this.getPickListRef=function(t){return e.pickListItem=t};this.handleKeyDown=function(t){if(t.key===" "){e.handleActivated=!e.handleActivated}};this.handleBlur=function(){e.handleActivated=false};this.handleSelectChange=function(t){e.selected=t.detail.selected}}t.prototype.toggleSelected=function(t){return __awaiter(this,void 0,void 0,(function(){return __generator(this,(function(e){this.pickListItem.toggleSelected(t);return[2]}))}))};t.prototype.setFocus=function(){return __awaiter(this,void 0,void 0,(function(){var t;return __generator(this,(function(e){(t=this.pickListItem)===null||t===void 0?void 0:t.setFocus();return[2]}))}))};t.prototype.calciteListItemChangeHandler=function(t){t.detail.item=this.el};t.prototype.renderActionsEnd=function(){var t=this.el;var e=getSlotted(t,SLOTS.actionsEnd);return e?h("slot",{name:SLOTS.actionsEnd,slot:SLOTS$1.actionsEnd}):null};t.prototype.renderActionsStart=function(){var t=this.el;var e=getSlotted(t,SLOTS.actionsStart);return e?h("slot",{name:SLOTS.actionsStart,slot:SLOTS$1.actionsStart}):null};t.prototype.renderHandle=function(){var t;var e=this.icon;if(e===ICON_TYPES$1.grip){return h("span",{"aria-pressed":this.handleActivated.toString(),class:(t={},t[CSS$1.handle]=true,t[CSS$1.handleActivated]=this.handleActivated,t),"data-js-handle":true,onBlur:this.handleBlur,onKeyDown:this.handleKeyDown,role:"button",tabindex:"0"},h("calcite-icon",{icon:ICONS.drag,scale:"s"}))}};t.prototype.render=function(){return h(Host,{id:this.el.id||this.guid},this.renderHandle(),h("calcite-pick-list-item",{description:this.description,disableDeselect:this.disableDeselect,disabled:this.disabled,label:this.label,metadata:this.metadata,nonInteractive:this.nonInteractive,onCalciteListItemChange:this.handleSelectChange,ref:this.getPickListRef,removable:this.removable,selected:this.selected,value:this.value},this.renderActionsStart(),this.renderActionsEnd()))};Object.defineProperty(t.prototype,"el",{get:function(){return getElement(this)},enumerable:false,configurable:true});return t}();CalciteValueListItem.style=calciteValueListItemCss;export{CalciteValueList as calcite_value_list,CalciteValueListItem as calcite_value_list_item};
|
|
5
|
+
*/import{r as registerInstance,c as createEvent,h,g as getElement,H as Host}from"./index-9de00868.js";import{S as Sortable}from"./sortable.esm-04824d33.js";import{m as mutationObserverCallback,d as deselectRemovedItems,a as deselectSiblingItems,s as selectSiblings,h as handleFilter,g as getItemData,k as keyDownHandler,i as initialize,b as initializeObserver,c as cleanUpObserver,r as removeItem,e as calciteListItemChangeHandler,f as calciteListItemValueChangeHandler,j as setUpItems,l as setFocus,L as List,I as ICON_TYPES$1,C as CSS$1,S as SLOTS$1}from"./resources-a6abee37.js";import{g as getRoundRobinIndex}from"./array-91a648e2.js";import{c as createObserver}from"./observers-8f0bc419.js";import{g as guid}from"./guid-196bd5ea.js";import{g as getSlotted}from"./dom-e55f9eaf.js";import"./debounce-79648d42.js";var CSS={container:"container",handle:"handle"};var ICON_TYPES;(function(t){t["grip"]="grip"})(ICON_TYPES||(ICON_TYPES={}));var calciteValueListCss="@-webkit-keyframes in{0%{opacity:0}100%{opacity:1}}@keyframes in{0%{opacity:0}100%{opacity:1}}@-webkit-keyframes in-down{0%{opacity:0;-webkit-transform:translate3D(0, -5px, 0);transform:translate3D(0, -5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@keyframes in-down{0%{opacity:0;-webkit-transform:translate3D(0, -5px, 0);transform:translate3D(0, -5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@-webkit-keyframes in-up{0%{opacity:0;-webkit-transform:translate3D(0, 5px, 0);transform:translate3D(0, 5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@keyframes in-up{0%{opacity:0;-webkit-transform:translate3D(0, 5px, 0);transform:translate3D(0, 5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@-webkit-keyframes in-scale{0%{opacity:0;-webkit-transform:scale3D(0.95, 0.95, 1);transform:scale3D(0.95, 0.95, 1)}100%{opacity:1;-webkit-transform:scale3D(1, 1, 1);transform:scale3D(1, 1, 1)}}@keyframes in-scale{0%{opacity:0;-webkit-transform:scale3D(0.95, 0.95, 1);transform:scale3D(0.95, 0.95, 1)}100%{opacity:1;-webkit-transform:scale3D(1, 1, 1);transform:scale3D(1, 1, 1)}}:root{--calcite-animation-timing:calc(150ms * var(--calcite-internal-duration-factor));--calcite-internal-duration-factor:var(--calcite-duration-factor, 1);--calcite-internal-animation-timing-fast:calc(100ms * var(--calcite-internal-duration-factor));--calcite-internal-animation-timing-medium:calc(200ms * var(--calcite-internal-duration-factor));--calcite-internal-animation-timing-slow:calc(300ms * var(--calcite-internal-duration-factor))}.calcite-animate{opacity:0;-webkit-animation-fill-mode:both;animation-fill-mode:both;-webkit-animation-duration:var(--calcite-animation-timing);animation-duration:var(--calcite-animation-timing)}.calcite-animate__in{-webkit-animation-name:in;animation-name:in}.calcite-animate__in-down{-webkit-animation-name:in-down;animation-name:in-down}.calcite-animate__in-up{-webkit-animation-name:in-up;animation-name:in-up}.calcite-animate__in-scale{-webkit-animation-name:in-scale;animation-name:in-scale}:root{--calcite-popper-transition:var(--calcite-animation-timing)}:host([hidden]){display:none}:host{position:relative;-webkit-box-sizing:border-box;box-sizing:border-box;display:-ms-flexbox;display:flex;-ms-flex-negative:0;flex-shrink:0;-ms-flex-positive:0;flex-grow:0;-ms-flex-direction:column;flex-direction:column;-ms-flex-align:stretch;align-items:stretch;background-color:transparent;font-size:var(--calcite-font-size--1);color:var(--calcite-ui-text-2)}:host *{-webkit-box-sizing:border-box;box-sizing:border-box}calcite-value-list-item:last-of-type{--tw-shadow:0 0 #0000;--tw-shadow-colored:0 0 #0000;-webkit-box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow)}:host([filter-enabled]) header{margin-bottom:0.25rem;display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;-ms-flex-pack:end;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);-webkit-box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow)}:host([filter-enabled]) header.sticky-pos{position:-webkit-sticky;position:sticky;top:0px;z-index:10}calcite-filter{margin-bottom:1px}";var CalciteValueList=function(){function t(t){var e=this;registerInstance(this,t);this.calciteListChange=createEvent(this,"calciteListChange",7);this.calciteListOrderChange=createEvent(this,"calciteListOrderChange",7);this.disabled=false;this.dragEnabled=false;this.filterEnabled=false;this.loading=false;this.multiple=false;this.selectionFollowsFocus=false;this.selectedValues=new Map;this.dataForFilter=[];this.lastSelectedItem=null;this.mutationObserver=createObserver("mutation",mutationObserverCallback.bind(this));this.setFilterEl=function(t){e.filterEl=t};this.deselectRemovedItems=deselectRemovedItems.bind(this);this.deselectSiblingItems=deselectSiblingItems.bind(this);this.selectSiblings=selectSiblings.bind(this);this.handleFilter=handleFilter.bind(this);this.getItemData=getItemData.bind(this);this.keyDownHandler=function(t){var a=t.composedPath().find((function(t){var e;return((e=t.dataset)===null||e===void 0?void 0:e.jsHandle)!==undefined}));var i=t.composedPath().find((function(t){var e;return((e=t.tagName)===null||e===void 0?void 0:e.toLowerCase())==="calcite-value-list-item"}));if(!a||!i.handleActivated){keyDownHandler.call(e,t);return}var n=e.items;if(t.key!=="ArrowUp"&&t.key!=="ArrowDown"||n.length<=1){return}t.preventDefault();var r=e.el;var o=t.key==="ArrowDown"?1:-1;var s=n.indexOf(i);var l=getRoundRobinIndex(s+o,n.length);if(l===n.length-1){r.appendChild(i)}else{var c=r.children[l];var d=c===i.nextElementSibling?c.nextElementSibling:c;r.insertBefore(i,d)}e.items=e.getItems();e.calciteListOrderChange.emit(e.items.map((function(t){var e=t.value;return e})));requestAnimationFrame((function(){return a.focus()}));i.handleActivated=true}}t.prototype.connectedCallback=function(){initialize.call(this);initializeObserver.call(this)};t.prototype.componentDidLoad=function(){this.setUpDragAndDrop()};t.prototype.disconnectedCallback=function(){cleanUpObserver.call(this);this.cleanUpDragAndDrop()};t.prototype.calciteListItemRemoveHandler=function(t){removeItem.call(this,t)};t.prototype.calciteListItemChangeHandler=function(t){calciteListItemChangeHandler.call(this,t)};t.prototype.calciteListItemPropsChangeHandler=function(t){t.stopPropagation();this.setUpFilter()};t.prototype.calciteListItemValueChangeHandler=function(t){calciteListItemValueChangeHandler.call(this,t)};t.prototype.getItems=function(){return Array.from(this.el.querySelectorAll("calcite-value-list-item"))};t.prototype.setUpItems=function(){setUpItems.call(this,"calcite-value-list-item")};t.prototype.setUpFilter=function(){if(this.filterEnabled){this.dataForFilter=this.getItemData()}};t.prototype.setUpDragAndDrop=function(){var t=this;this.cleanUpDragAndDrop();if(!this.dragEnabled){return}this.sortable=Sortable.create(this.el,{dataIdAttr:"id",handle:"."+CSS.handle,draggable:"calcite-value-list-item",group:this.group,onSort:function(){t.items=Array.from(t.el.querySelectorAll("calcite-value-list-item"));var e=t.items.map((function(t){return t.value}));t.calciteListOrderChange.emit(e)}})};t.prototype.cleanUpDragAndDrop=function(){var t;(t=this.sortable)===null||t===void 0?void 0:t.destroy();this.sortable=null};t.prototype.getSelectedItems=function(){return __awaiter(this,void 0,void 0,(function(){return __generator(this,(function(t){return[2,this.selectedValues]}))}))};t.prototype.setFocus=function(t){return __awaiter(this,void 0,void 0,(function(){return __generator(this,(function(e){return[2,setFocus.call(this,t)]}))}))};t.prototype.getIconType=function(){var t=null;if(this.dragEnabled){t=ICON_TYPES.grip}return t};t.prototype.render=function(){return h(List,{onKeyDown:this.keyDownHandler,props:this})};Object.defineProperty(t.prototype,"el",{get:function(){return getElement(this)},enumerable:false,configurable:true});return t}();CalciteValueList.style=calciteValueListCss;var ICONS={drag:"drag"};var SLOTS={actionsEnd:"actions-end",actionsStart:"actions-start"};var calciteValueListItemCss="@-webkit-keyframes in{0%{opacity:0}100%{opacity:1}}@keyframes in{0%{opacity:0}100%{opacity:1}}@-webkit-keyframes in-down{0%{opacity:0;-webkit-transform:translate3D(0, -5px, 0);transform:translate3D(0, -5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@keyframes in-down{0%{opacity:0;-webkit-transform:translate3D(0, -5px, 0);transform:translate3D(0, -5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@-webkit-keyframes in-up{0%{opacity:0;-webkit-transform:translate3D(0, 5px, 0);transform:translate3D(0, 5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@keyframes in-up{0%{opacity:0;-webkit-transform:translate3D(0, 5px, 0);transform:translate3D(0, 5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@-webkit-keyframes in-scale{0%{opacity:0;-webkit-transform:scale3D(0.95, 0.95, 1);transform:scale3D(0.95, 0.95, 1)}100%{opacity:1;-webkit-transform:scale3D(1, 1, 1);transform:scale3D(1, 1, 1)}}@keyframes in-scale{0%{opacity:0;-webkit-transform:scale3D(0.95, 0.95, 1);transform:scale3D(0.95, 0.95, 1)}100%{opacity:1;-webkit-transform:scale3D(1, 1, 1);transform:scale3D(1, 1, 1)}}:root{--calcite-animation-timing:calc(150ms * var(--calcite-internal-duration-factor));--calcite-internal-duration-factor:var(--calcite-duration-factor, 1);--calcite-internal-animation-timing-fast:calc(100ms * var(--calcite-internal-duration-factor));--calcite-internal-animation-timing-medium:calc(200ms * var(--calcite-internal-duration-factor));--calcite-internal-animation-timing-slow:calc(300ms * var(--calcite-internal-duration-factor))}.calcite-animate{opacity:0;-webkit-animation-fill-mode:both;animation-fill-mode:both;-webkit-animation-duration:var(--calcite-animation-timing);animation-duration:var(--calcite-animation-timing)}.calcite-animate__in{-webkit-animation-name:in;animation-name:in}.calcite-animate__in-down{-webkit-animation-name:in-down;animation-name:in-down}.calcite-animate__in-up{-webkit-animation-name:in-up;animation-name:in-up}.calcite-animate__in-scale{-webkit-animation-name:in-scale;animation-name:in-scale}:root{--calcite-popper-transition:var(--calcite-animation-timing)}:host([hidden]){display:none}:host{margin-bottom:1px;-webkit-box-sizing:border-box;box-sizing:border-box;display:-ms-flexbox;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);-webkit-box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow);-webkit-transition:background-color var(--calcite-animation-timing), -webkit-box-shadow var(--calcite-animation-timing);transition:background-color var(--calcite-animation-timing), -webkit-box-shadow var(--calcite-animation-timing);transition:background-color var(--calcite-animation-timing), box-shadow var(--calcite-animation-timing);transition:background-color var(--calcite-animation-timing), box-shadow var(--calcite-animation-timing), -webkit-box-shadow var(--calcite-animation-timing)}:host *{-webkit-box-sizing:border-box;box-sizing:border-box}calcite-pick-list-item{position:relative;margin:0px;-ms-flex-positive:1;flex-grow:1;--tw-shadow:0 0 #0000;--tw-shadow-colored:0 0 #0000;-webkit-box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow)}:host([active]),:host([selected]){--tw-ring-offset-shadow:var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);--tw-ring-shadow:var(--tw-ring-inset) 0 0 0 calc(3px + var(--tw-ring-offset-width)) var(--tw-ring-color);-webkit-box-shadow:var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow, 0 0 #0000);box-shadow:var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow, 0 0 #0000)}.handle{display:-ms-flexbox;display:flex;cursor:move;-ms-flex-align:center;align-items:center;-ms-flex-pack:center;justify-content:center;border-style:none;background-color:transparent;padding-top:0px;padding-bottom:0px;padding-left:0.25rem;padding-right:0.25rem;color:var(--calcite-ui-border-1);outline-offset:0;outline-color:transparent;-webkit-transition:outline-offset 100ms ease-in-out, outline-color 100ms ease-in-out;transition:outline-offset 100ms ease-in-out, outline-color 100ms ease-in-out}.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}";var CalciteValueListItem=function(){function t(t){var e=this;registerInstance(this,t);this.calciteListItemRemove=createEvent(this,"calciteListItemRemove",7);this.disabled=false;this.disableDeselect=false;this.nonInteractive=false;this.handleActivated=false;this.icon=null;this.removable=false;this.selected=false;this.pickListItem=null;this.guid="calcite-value-list-item-"+guid();this.getPickListRef=function(t){return e.pickListItem=t};this.handleKeyDown=function(t){if(t.key===" "){e.handleActivated=!e.handleActivated}};this.handleBlur=function(){e.handleActivated=false};this.handleSelectChange=function(t){e.selected=t.detail.selected}}t.prototype.toggleSelected=function(t){return __awaiter(this,void 0,void 0,(function(){return __generator(this,(function(e){this.pickListItem.toggleSelected(t);return[2]}))}))};t.prototype.setFocus=function(){return __awaiter(this,void 0,void 0,(function(){var t;return __generator(this,(function(e){(t=this.pickListItem)===null||t===void 0?void 0:t.setFocus();return[2]}))}))};t.prototype.calciteListItemChangeHandler=function(t){t.detail.item=this.el};t.prototype.renderActionsEnd=function(){var t=this.el;var e=getSlotted(t,SLOTS.actionsEnd);return e?h("slot",{name:SLOTS.actionsEnd,slot:SLOTS$1.actionsEnd}):null};t.prototype.renderActionsStart=function(){var t=this.el;var e=getSlotted(t,SLOTS.actionsStart);return e?h("slot",{name:SLOTS.actionsStart,slot:SLOTS$1.actionsStart}):null};t.prototype.renderHandle=function(){var t;var e=this.icon;if(e===ICON_TYPES$1.grip){return h("span",{"aria-pressed":this.handleActivated.toString(),class:(t={},t[CSS$1.handle]=true,t[CSS$1.handleActivated]=this.handleActivated,t),"data-js-handle":true,onBlur:this.handleBlur,onKeyDown:this.handleKeyDown,role:"button",tabindex:"0"},h("calcite-icon",{icon:ICONS.drag,scale:"s"}))}};t.prototype.render=function(){return h(Host,{id:this.el.id||this.guid},this.renderHandle(),h("calcite-pick-list-item",{description:this.description,disableDeselect:this.disableDeselect,disabled:this.disabled,label:this.label,metadata:this.metadata,nonInteractive:this.nonInteractive,onCalciteListItemChange:this.handleSelectChange,ref:this.getPickListRef,removable:this.removable,selected:this.selected,value:this.value},this.renderActionsStart(),this.renderActionsEnd()))};Object.defineProperty(t.prototype,"el",{get:function(){return getElement(this)},enumerable:false,configurable:true});return t}();CalciteValueListItem.style=calciteValueListItemCss;export{CalciteValueList as calcite_value_list,CalciteValueListItem as calcite_value_list_item};
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
var __awaiter=this&&this.__awaiter||function(e,t,r,n){function o(e){return e instanceof r?e:new r((function(t){t(e)}))}return new(r||(r=Promise))((function(r,i){function a(e){try{l(n.next(e))}catch(e){i(e)}}function u(e){try{l(n["throw"](e))}catch(e){i(e)}}function l(e){e.done?r(e.value):o(e.value).then(a,u)}l((n=n.apply(e,t||[])).next())}))};var __generator=this&&this.__generator||function(e,t){var r={label:0,sent:function(){if(i[0]&1)throw i[1];return i[1]},trys:[],ops:[]},n,o,i,a;return a={next:u(0),throw:u(1),return:u(2)},typeof Symbol==="function"&&(a[Symbol.iterator]=function(){return this}),a;function u(e){return function(t){return l([e,t])}}function l(a){if(n)throw new TypeError("Generator is already executing.");while(r)try{if(n=1,o&&(i=a[0]&2?o["return"]:a[0]?o["throw"]||((i=o["return"])&&i.call(o),0):o.next)&&!(i=i.call(o,a[1])).done)return i;if(o=0,i)a=[a[0]&2,i.value];switch(a[0]){case 0:case 1:i=a;break;case 4:r.label++;return{value:a[1],done:false};case 5:r.label++;o=a[1];a=[0];continue;case 7:a=r.ops.pop();r.trys.pop();continue;default:if(!(i=r.trys,i=i.length>0&&i[i.length-1])&&(a[0]===6||a[0]===2)){r=0;continue}if(a[0]===3&&(!i||a[1]>i[0]&&a[1]<i[3])){r.label=a[1];break}if(a[0]===6&&r.label<i[1]){r.label=i[1];i=a;break}if(i&&r.label<i[2]){r.label=i[2];r.ops.push(a);break}if(i[2])r.ops.pop();r.trys.pop();continue}a=t.call(e,r)}catch(e){a=[6,e];o=0}finally{n=i=0}if(a[0]&5)throw a[1];return{value:a[0]?a[1]:void 0,done:true}}};var __spreadArray=this&&this.__spreadArray||function(e,t){for(var r=0,n=t.length,o=e.length;r<n;r++,o++)e[o]=t[r];return e};
|
|
2
|
+
/*!
|
|
3
|
+
* All material copyright ESRI, All Rights Reserved, unless otherwise specified.
|
|
4
|
+
* See https://github.com/Esri/calcite-components/blob/master/LICENSE.md for details.
|
|
5
|
+
*/import{g as guid}from"./guid-196bd5ea.js";var autoTheme="calcite-theme-auto";var darkTheme="calcite-theme-dark";var lightTheme="calcite-theme-light";var CSS_UTILITY={autoTheme:autoTheme,darkTheme:darkTheme,lightTheme:lightTheme,rtl:"calcite--rtl"};var TEXT={loading:"Loading"};function ensureId(e){if(!e){return""}return e.id=e.id||e.tagName.toLowerCase()+"-"+guid()}function nodeListToArray(e){return Array.isArray(e)?e:Array.from(e)}function getThemeName(e){var t=closestElementCrossShadowBoundary(e,"."+CSS_UTILITY.darkTheme+", ."+CSS_UTILITY.lightTheme);return(t===null||t===void 0?void 0:t.classList.contains("calcite-theme-dark"))?"dark":"light"}function getElementDir(e){var t="dir";var r="["+t+"]";var n=closestElementCrossShadowBoundary(e,r);return n?n.getAttribute(t):"ltr"}function getElementProp(e,t,r){var n="["+t+"]";var o=e.closest(n);return o?o.getAttribute(t):r}function getRootNode(e){return e.getRootNode()}function getHost(e){return e.host||null}function queryElementsRoots(e,t){function r(e,n){if(!e){return n}if(e.assignedSlot){e=e.assignedSlot}var o=getRootNode(e);var i=Array.from(o.querySelectorAll(t));var a=i.filter((function(e){return!n.includes(e)}));n=__spreadArray(__spreadArray([],n),a);var u=getHost(o);return u?r(u,n):n}return r(e,[])}function queryElementRoots(e,t){var r=t.selector,n=t.id;function o(e){if(!e){return null}if(e.assignedSlot){e=e.assignedSlot}var t=getRootNode(e);var i=n?t.getElementById(n):r?t.querySelector(r):null;var a=getHost(t);return i?i:a?o(a):null}return o(e)}function closestElementCrossShadowBoundary(e,t){function r(e){return e?e.closest(t)||r(getHost(getRootNode(e))):null}return r(e)}function isCalciteFocusable(e){return typeof(e===null||e===void 0?void 0:e.setFocus)==="function"}function focusElement(e){return __awaiter(this,void 0,void 0,(function(){return __generator(this,(function(t){if(!e){return[2]}return[2,isCalciteFocusable(e)?e.setFocus():e.focus()]}))}))}function getSlotted(e,t,r){var n=Array.isArray(t)?t.map((function(e){return'[slot="'+e+'"]'})).join(","):'[slot="'+t+'"]';if(r===null||r===void 0?void 0:r.all){return queryMultiple(e,n,r)}return querySingle(e,n,r)}function queryMultiple(e,t,r){var n=Array.from(e.querySelectorAll(t));n=r&&r.direct===false?n:n.filter((function(t){return t.parentElement===e}));var o=r===null||r===void 0?void 0:r.selector;return o?n.map((function(e){return Array.from(e.querySelectorAll(o))})).reduce((function(e,t){return __spreadArray(__spreadArray([],e),t)}),[]).filter((function(e){return!!e})):n}function querySingle(e,t,r){var n=e.querySelector(t);n=r&&r.direct===false?n:(n===null||n===void 0?void 0:n.parentElement)===e?n:null;var o=r===null||r===void 0?void 0:r.selector;return o?n.querySelector(o):n}function filterDirectChildren(e,t){return Array.from(e.children).filter((function(e){return e.matches(t)}))}function setRequestedIcon(e,t,r){if(typeof t==="string"&&t!==""){return t}else if(t===""){return e[r]}}function intersects(e,t){return!(t.left>e.right||t.right<e.left||t.top>e.bottom||t.bottom<e.top)}export{CSS_UTILITY as C,TEXT as T,getElementDir as a,getThemeName as b,closestElementCrossShadowBoundary as c,getElementProp as d,ensureId as e,focusElement as f,getSlotted as g,queryElementsRoots as h,isCalciteFocusable as i,intersects as j,filterDirectChildren as k,nodeListToArray as n,queryElementRoots as q,setRequestedIcon as s};
|
|
@@ -2,4 +2,4 @@
|
|
|
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
4
|
*/
|
|
5
|
-
import{c as closestElementCrossShadowBoundary}from"./dom-
|
|
5
|
+
import{c as closestElementCrossShadowBoundary}from"./dom-e55f9eaf.js";import{h}from"./index-9de00868.js";var hiddenFormInputSlotName="hidden-form-input";function isCheckable(e){return"checked"in e}var onFormResetMap=new WeakMap;var formComponentSet=new WeakSet;function hasRegisteredFormComponentParent(e,n){var t="calciteInternalFormComponentRegister";var r=false;e.addEventListener(t,(function(e){r=e.composedPath().some((function(e){return formComponentSet.has(e)}));e.stopPropagation()}),{once:true});n.dispatchEvent(new CustomEvent(t,{bubbles:true,composed:true}));return r}function connectForm(e){var n=e.el,t=e.value;var r=closestElementCrossShadowBoundary(n,"form");if(!r||hasRegisteredFormComponentParent(r,n)){return}e.formEl=r;e.defaultValue=t;if(isCheckable(e)){e.defaultChecked=e.checked}var o=(e.onFormReset||onFormReset).bind(e);r.addEventListener("reset",o);formComponentSet.add(n)}function onFormReset(){if(isCheckable(this)){this.checked=this.defaultChecked;return}this.value=this.defaultValue}function disconnectForm(e){var n=e.el,t=e.formEl;if(!t){return}var r=onFormResetMap.get(n);t.removeEventListener("reset",r);onFormResetMap.delete(n);e.formEl=null;formComponentSet.delete(n)}function afterConnectDefaultValueSet(e,n){e.defaultValue=n}function syncHiddenFormInput(e){var n=e.el,t=e.formEl,r=e.name,o=e.value;var a=n.ownerDocument;var d=n.querySelectorAll('input[slot="'+hiddenFormInputSlotName+'"]');if(!t||!r){d.forEach((function(e){return e.remove()}));return}var u=Array.isArray(o)?o:[o];var i=[];var l=new Set;d.forEach((function(n){var t=u.find((function(e){return e==n.value}));if(t!=null){l.add(t);defaultSyncHiddenFormInput(e,n,t)}else{i.push(n)}}));var c;u.forEach((function(n){if(l.has(n)){return}var t=i.pop();if(!t){t=a.createElement("input");t.slot=hiddenFormInputSlotName}if(!c){c=a.createDocumentFragment()}c.append(t);defaultSyncHiddenFormInput(e,t,n)}));if(c){n.append(c)}i.forEach((function(e){return e.remove()}))}function defaultSyncHiddenFormInput(e,n,t){var r;var o=e.defaultValue,a=e.disabled,d=e.name,u=e.required;n.defaultValue=o;n.disabled=a;n.name=d;n.required=u;n.tabIndex=-1;if(isCheckable(e)){n.defaultChecked=e.defaultChecked;n.value=e.checked?t||"on":"";if(!a&&!e.checked){n.disabled=true}}else{n.value=t||""}(r=e.syncHiddenFormInput)===null||r===void 0?void 0:r.call(e,n)}var HiddenFormInputSlot=function(e){var n=e.component;syncHiddenFormInput(n);return h("slot",{name:hiddenFormInputSlotName})};export{HiddenFormInputSlot as H,afterConnectDefaultValueSet as a,connectForm as c,disconnectForm as d};
|
|
@@ -0,0 +1,5 @@
|
|
|
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
|
+
*/
|
|
5
|
+
import{q as queryElementRoots,c as closestElementCrossShadowBoundary}from"./dom-e55f9eaf.js";var labelClickEvent="calciteInternalLabelClick";var labelTagName="calcite-label";var onLabelClickMap=new WeakMap;var findLabelForComponent=function(e){var l=e.id;var n=l&&queryElementRoots(e,{selector:labelTagName+'[for="'+l+'"]'});if(n){return n}var t=closestElementCrossShadowBoundary(e,labelTagName);if(!t||hasAncestorCustomElements(t,e)){return null}return t};function hasAncestorCustomElements(e,l){var n;var t="custom-element-ancestor-check";var a=function(t){t.stopImmediatePropagation();var a=t.composedPath();n=a.slice(a.indexOf(l),a.indexOf(e))};e.addEventListener(t,a,{once:true});l.dispatchEvent(new CustomEvent(t,{composed:true,bubbles:true}));e.removeEventListener(t,a);var r=n.filter((function(n){return n!==l&&n!==e})).filter((function(e){var l;return(l=e.tagName)===null||l===void 0?void 0:l.includes("-")}));return r.length>0}function connectLabel(e){var l=findLabelForComponent(e.el);if(!l||onLabelClickMap.has(l)){return}e.labelEl=l;var n=onLabelClick.bind(e);onLabelClickMap.set(e.labelEl,n);e.labelEl.addEventListener(labelClickEvent,n)}function disconnectLabel(e){if(!e.labelEl){return}var l=onLabelClickMap.get(e.labelEl);e.labelEl.removeEventListener(labelClickEvent,l);onLabelClickMap.delete(e.labelEl)}function getLabelText(e){var l,n;return e.label||((n=(l=e.labelEl)===null||l===void 0?void 0:l.textContent)===null||n===void 0?void 0:n.trim())||""}function onLabelClick(e){if(this.disabled){return}var l=this.el.contains(e.detail.sourceEvent.target);if(l){return}this.onLabelClick(e)}export{connectLabel as c,disconnectLabel as d,getLabelText as g};
|
|
@@ -0,0 +1,5 @@
|
|
|
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
|
+
*/
|
|
5
|
+
import{a as sanitizeExponentialNumberString,b as sanitizeDecimalString}from"./number-8779395f.js";var locales=["ar","bs","ca","cs","da","de","de-CH","el","en","en-AU","en-CA","en-GB","es","es-MX","et","fi","fr","fr-CH","he","hi","hr","hu","id","it","it-CH","ja","ko","lt","lv","mk","nb","nl","pl","pt","pt-PT","ro","ru","sk","sl","sr","sv","th","tr","uk","vi","zh-CN","zh-HK","zh-TW"];function createLocaleNumberFormatter(r){return new Intl.NumberFormat(r,{minimumFractionDigits:0,maximumFractionDigits:20})}function delocalizeNumberString(r,e){return sanitizeExponentialNumberString(r,(function(r){if(r){var t=getGroupSeparator(e);var a=getDecimalSeparator(e);var n=r.split("");var i=n.lastIndexOf(a);var u=n.map((function(r,e){if(r===t||r===a&&e!==i){return""}return r})).reduce((function(r,e){return r+e})).replace(a,".");return isNaN(Number(u))?r:u}return r}))}function getGroupSeparator(r){var e=createLocaleNumberFormatter(r);var t=e.formatToParts(1234567.8);var a=t.find((function(r){return r.type==="group"})).value;return a.trim().length===0?" ":a}function getDecimalSeparator(r){var e=createLocaleNumberFormatter(r);var t=e.formatToParts(1234567.8);var a=t.find((function(r){return r.type==="decimal"})).value;return a.trim().length===0?" ":a}function localizeNumberString(r,e,t){if(t===void 0){t=false}return sanitizeExponentialNumberString(r,(function(r){if(r){var a=Number(sanitizeDecimalString(r));if(!isNaN(a)){var n=createLocaleNumberFormatter(e);var i=n.formatToParts(a);var u=i.map((function(r){var a=r.type,n=r.value;switch(a){case"group":return t?getGroupSeparator(e):"";case"decimal":return getDecimalSeparator(e);default:return n}})).reduce((function(r,e){return r+e}));return u}return r}}))}export{locales as a,delocalizeNumberString as d,getDecimalSeparator as g,localizeNumberString as l};
|
|
@@ -0,0 +1,5 @@
|
|
|
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
|
+
*/
|
|
5
|
+
function isActivationKey(e){return e==="Enter"||e===" "}var numberKeys=["0","1","2","3","4","5","6","7","8","9"];function isValidNumber(e){return!(!e||isNaN(Number(e)))}function parseNumberString(e){if(!e||!stringContainsNumbers(e)){return""}return sanitizeExponentialNumberString(e,(function(e){var n=false;var r=e.split("").filter((function(e,r){if(e.match(/\./g)&&!n){n=true;return true}if(e.match(/\-/g)&&r===0){return true}return numberKeys.includes(e)})).reduce((function(e,n){return e+n}));return isValidNumber(r)?Number(r).toString():null}))}function sanitizeDecimalString(e){var n=/(?!^\.)\.$/;return e.replace(n,"")}function sanitizeNegativeString(e){var n=/(?!^-)-/g;return e.replace(n,"")}function sanitizeLeadingZeroString(e){var n=/^([-0])0+(?=\d)/;return e.replace(n,"$1")}function sanitizeNumberString(e){return sanitizeExponentialNumberString(e,(function(e){var n=sanitizeNegativeString(sanitizeDecimalString(sanitizeLeadingZeroString(e)));var r=/^-\b0\b\.?0*$/;return isValidNumber(n)?r.test(n)?n:Number(n).toString():e}))}function sanitizeExponentialNumberString(e,n){if(!e){return e}var r=e.toLowerCase().indexOf("e")+1;return e.replace(/[eE]*$/g,"").substring(0,r).concat(e.slice(r).replace(/[eE]/g,"")).split(/[eE]/).map((function(e,r){return r===1?n(e.replace(/\./g,"")):n(e)})).join("e").replace(/^e/,"1e")}function stringContainsNumbers(e){return numberKeys.some((function(n){return e.includes(n)}))}export{sanitizeExponentialNumberString as a,sanitizeDecimalString as b,isActivationKey as c,isValidNumber as i,numberKeys as n,parseNumberString as p,sanitizeNumberString as s};
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
var __awaiter=this&&this.__awaiter||function(e,t,r,n){function a(e){return e instanceof r?e:new r((function(t){t(e)}))}return new(r||(r=Promise))((function(r,i){function o(e){try{f(n.next(e))}catch(e){i(e)}}function s(e){try{f(n["throw"](e))}catch(e){i(e)}}function f(e){e.done?r(e.value):a(e.value).then(o,s)}f((n=n.apply(e,t||[])).next())}))};var __generator=this&&this.__generator||function(e,t){var r={label:0,sent:function(){if(i[0]&1)throw i[1];return i[1]},trys:[],ops:[]},n,a,i,o;return o={next:s(0),throw:s(1),return:s(2)},typeof Symbol==="function"&&(o[Symbol.iterator]=function(){return this}),o;function s(e){return function(t){return f([e,t])}}function f(o){if(n)throw new TypeError("Generator is already executing.");while(r)try{if(n=1,a&&(i=o[0]&2?a["return"]:o[0]?a["throw"]||((i=a["return"])&&i.call(a),0):a.next)&&!(i=i.call(a,o[1])).done)return i;if(a=0,i)o=[o[0]&2,i.value];switch(o[0]){case 0:case 1:i=o;break;case 4:r.label++;return{value:o[1],done:false};case 5:r.label++;a=o[1];o=[0];continue;case 7:o=r.ops.pop();r.trys.pop();continue;default:if(!(i=r.trys,i=i.length>0&&i[i.length-1])&&(o[0]===6||o[0]===2)){r=0;continue}if(o[0]===3&&(!i||o[1]>i[0]&&o[1]<i[3])){r.label=o[1];break}if(o[0]===6&&r.label<i[1]){r.label=i[1];i=o;break}if(i&&r.label<i[2]){r.label=i[2];r.ops.push(o);break}if(i[2])r.ops.pop();r.trys.pop();continue}o=t.call(e,r)}catch(e){o=[6,e];a=0}finally{n=i=0}if(o[0]&5)throw o[1];return{value:o[0]?o[1]:void 0,done:true}}};
|
|
2
|
+
/*!
|
|
3
|
+
* All material copyright ESRI, All Rights Reserved, unless otherwise specified.
|
|
4
|
+
* See https://github.com/Esri/calcite-components/blob/master/LICENSE.md for details.
|
|
5
|
+
*/import{a as getElementDir}from"./dom-e55f9eaf.js";var top="top";var bottom="bottom";var right="right";var left="left";var auto="auto";var basePlacements=[top,bottom,right,left];var start="start";var end="end";var clippingParents="clippingParents";var viewport="viewport";var popper="popper";var reference="reference";var variationPlacements=basePlacements.reduce((function(e,t){return e.concat([t+"-"+start,t+"-"+end])}),[]);var placements=[].concat(basePlacements,[auto]).reduce((function(e,t){return e.concat([t,t+"-"+start,t+"-"+end])}),[]);var beforeRead="beforeRead";var read="read";var afterRead="afterRead";var beforeMain="beforeMain";var main="main";var afterMain="afterMain";var beforeWrite="beforeWrite";var write="write";var afterWrite="afterWrite";var modifierPhases=[beforeRead,read,afterRead,beforeMain,main,afterMain,beforeWrite,write,afterWrite];function getNodeName(e){return e?(e.nodeName||"").toLowerCase():null}function getWindow(e){if(e==null){return window}if(e.toString()!=="[object Window]"){var t=e.ownerDocument;return t?t.defaultView||window:window}return e}function isElement(e){var t=getWindow(e).Element;return e instanceof t||e instanceof Element}function isHTMLElement(e){var t=getWindow(e).HTMLElement;return e instanceof t||e instanceof HTMLElement}function isShadowRoot(e){if(typeof ShadowRoot==="undefined"){return false}var t=getWindow(e).ShadowRoot;return e instanceof t||e instanceof ShadowRoot}function applyStyles(e){var t=e.state;Object.keys(t.elements).forEach((function(e){var r=t.styles[e]||{};var n=t.attributes[e]||{};var a=t.elements[e];if(!isHTMLElement(a)||!getNodeName(a)){return}Object.assign(a.style,r);Object.keys(n).forEach((function(e){var t=n[e];if(t===false){a.removeAttribute(e)}else{a.setAttribute(e,t===true?"":t)}}))}))}function effect$2(e){var t=e.state;var r={popper:{position:t.options.strategy,left:"0",top:"0",margin:"0"},arrow:{position:"absolute"},reference:{}};Object.assign(t.elements.popper.style,r.popper);t.styles=r;if(t.elements.arrow){Object.assign(t.elements.arrow.style,r.arrow)}return function(){Object.keys(t.elements).forEach((function(e){var n=t.elements[e];var a=t.attributes[e]||{};var i=Object.keys(t.styles.hasOwnProperty(e)?t.styles[e]:r[e]);var o=i.reduce((function(e,t){e[t]="";return e}),{});if(!isHTMLElement(n)||!getNodeName(n)){return}Object.assign(n.style,o);Object.keys(a).forEach((function(e){n.removeAttribute(e)}))}))}}var applyStyles$1={name:"applyStyles",enabled:true,phase:"write",fn:applyStyles,effect:effect$2,requires:["computeStyles"]};function getBasePlacement(e){return e.split("-")[0]}var max=Math.max;var min=Math.min;var round=Math.round;function getBoundingClientRect(e,t){if(t===void 0){t=false}var r=e.getBoundingClientRect();var n=1;var a=1;if(isHTMLElement(e)&&t){var i=e.offsetHeight;var o=e.offsetWidth;if(o>0){n=round(r.width)/o||1}if(i>0){a=round(r.height)/i||1}}return{width:r.width/n,height:r.height/a,top:r.top/a,right:r.right/n,bottom:r.bottom/a,left:r.left/n,x:r.left/n,y:r.top/a}}function getLayoutRect(e){var t=getBoundingClientRect(e);var r=e.offsetWidth;var n=e.offsetHeight;if(Math.abs(t.width-r)<=1){r=t.width}if(Math.abs(t.height-n)<=1){n=t.height}return{x:e.offsetLeft,y:e.offsetTop,width:r,height:n}}function contains(e,t){var r=t.getRootNode&&t.getRootNode();if(e.contains(t)){return true}else if(r&&isShadowRoot(r)){var n=t;do{if(n&&e.isSameNode(n)){return true}n=n.parentNode||n.host}while(n)}return false}function getComputedStyle(e){return getWindow(e).getComputedStyle(e)}function isTableElement(e){return["table","td","th"].indexOf(getNodeName(e))>=0}function getDocumentElement(e){return((isElement(e)?e.ownerDocument:e.document)||window.document).documentElement}function getParentNode(e){if(getNodeName(e)==="html"){return e}return e.assignedSlot||e.parentNode||(isShadowRoot(e)?e.host:null)||getDocumentElement(e)}function getTrueOffsetParent(e){if(!isHTMLElement(e)||getComputedStyle(e).position==="fixed"){return null}return e.offsetParent}function getContainingBlock(e){var t=navigator.userAgent.toLowerCase().indexOf("firefox")!==-1;var r=navigator.userAgent.indexOf("Trident")!==-1;if(r&&isHTMLElement(e)){var n=getComputedStyle(e);if(n.position==="fixed"){return null}}var a=getParentNode(e);while(isHTMLElement(a)&&["html","body"].indexOf(getNodeName(a))<0){var i=getComputedStyle(a);if(i.transform!=="none"||i.perspective!=="none"||i.contain==="paint"||["transform","perspective"].indexOf(i.willChange)!==-1||t&&i.willChange==="filter"||t&&i.filter&&i.filter!=="none"){return a}else{a=a.parentNode}}return null}function getOffsetParent(e){var t=getWindow(e);var r=getTrueOffsetParent(e);while(r&&isTableElement(r)&&getComputedStyle(r).position==="static"){r=getTrueOffsetParent(r)}if(r&&(getNodeName(r)==="html"||getNodeName(r)==="body"&&getComputedStyle(r).position==="static")){return t}return r||getContainingBlock(e)||t}function getMainAxisFromPlacement(e){return["top","bottom"].indexOf(e)>=0?"x":"y"}function within(e,t,r){return max(e,min(t,r))}function withinMaxClamp(e,t,r){var n=within(e,t,r);return n>r?r:n}function getFreshSideObject(){return{top:0,right:0,bottom:0,left:0}}function mergePaddingObject(e){return Object.assign({},getFreshSideObject(),e)}function expandToHashMap(e,t){return t.reduce((function(t,r){t[r]=e;return t}),{})}var toPaddingObject=function e(t,r){t=typeof t==="function"?t(Object.assign({},r.rects,{placement:r.placement})):t;return mergePaddingObject(typeof t!=="number"?t:expandToHashMap(t,basePlacements))};function arrow(e){var t;var r=e.state,n=e.name,a=e.options;var i=r.elements.arrow;var o=r.modifiersData.popperOffsets;var s=getBasePlacement(r.placement);var f=getMainAxisFromPlacement(s);var l=[left,right].indexOf(s)>=0;var c=l?"height":"width";if(!i||!o){return}var p=toPaddingObject(a.padding,r);var u=getLayoutRect(i);var d=f==="y"?top:left;var v=f==="y"?bottom:right;var m=r.rects.reference[c]+r.rects.reference[f]-o[f]-r.rects.popper[c];var g=o[f]-r.rects.reference[f];var h=getOffsetParent(i);var y=h?f==="y"?h.clientHeight||0:h.clientWidth||0:0;var b=m/2-g/2;var w=p[d];var O=y-u[c]-p[v];var x=y/2-u[c]/2+b;var P=within(w,x,O);var S=f;r.modifiersData[n]=(t={},t[S]=P,t.centerOffset=P-x,t)}function effect$1(e){var t=e.state,r=e.options;var n=r.element,a=n===void 0?"[data-popper-arrow]":n;if(a==null){return}if(typeof a==="string"){a=t.elements.popper.querySelector(a);if(!a){return}}if(!contains(t.elements.popper,a)){return}t.elements.arrow=a}var arrow$1={name:"arrow",enabled:true,phase:"main",fn:arrow,effect:effect$1,requires:["popperOffsets"],requiresIfExists:["preventOverflow"]};function getVariation(e){return e.split("-")[1]}var unsetSides={top:"auto",right:"auto",bottom:"auto",left:"auto"};function roundOffsetsByDPR(e){var t=e.x,r=e.y;var n=window;var a=n.devicePixelRatio||1;return{x:round(t*a)/a||0,y:round(r*a)/a||0}}function mapToStyles(e){var t;var r=e.popper,n=e.popperRect,a=e.placement,i=e.variation,o=e.offsets,s=e.position,f=e.gpuAcceleration,l=e.adaptive,c=e.roundOffsets,p=e.isFixed;var u=o.x,d=u===void 0?0:u,v=o.y,m=v===void 0?0:v;var g=typeof c==="function"?c({x:d,y:m}):{x:d,y:m};d=g.x;m=g.y;var h=o.hasOwnProperty("x");var y=o.hasOwnProperty("y");var b=left;var w=top;var O=window;if(l){var x=getOffsetParent(r);var P="clientHeight";var S="clientWidth";if(x===getWindow(r)){x=getDocumentElement(r);if(getComputedStyle(x).position!=="static"&&s==="absolute"){P="scrollHeight";S="scrollWidth"}}x=x;if(a===top||(a===left||a===right)&&i===end){w=bottom;var E=p&&O.visualViewport?O.visualViewport.height:x[P];m-=E-n.height;m*=f?1:-1}if(a===left||(a===top||a===bottom)&&i===end){b=right;var M=p&&O.visualViewport?O.visualViewport.width:x[S];d-=M-n.width;d*=f?1:-1}}var T=Object.assign({position:s},l&&unsetSides);var C=c===true?roundOffsetsByDPR({x:d,y:m}):{x:d,y:m};d=C.x;m=C.y;if(f){var R;return Object.assign({},T,(R={},R[w]=y?"0":"",R[b]=h?"0":"",R.transform=(O.devicePixelRatio||1)<=1?"translate("+d+"px, "+m+"px)":"translate3d("+d+"px, "+m+"px, 0)",R))}return Object.assign({},T,(t={},t[w]=y?m+"px":"",t[b]=h?d+"px":"",t.transform="",t))}function computeStyles(e){var t=e.state,r=e.options;var n=r.gpuAcceleration,a=n===void 0?true:n,i=r.adaptive,o=i===void 0?true:i,s=r.roundOffsets,f=s===void 0?true:s;var l={placement:getBasePlacement(t.placement),variation:getVariation(t.placement),popper:t.elements.popper,popperRect:t.rects.popper,gpuAcceleration:a,isFixed:t.options.strategy==="fixed"};if(t.modifiersData.popperOffsets!=null){t.styles.popper=Object.assign({},t.styles.popper,mapToStyles(Object.assign({},l,{offsets:t.modifiersData.popperOffsets,position:t.options.strategy,adaptive:o,roundOffsets:f})))}if(t.modifiersData.arrow!=null){t.styles.arrow=Object.assign({},t.styles.arrow,mapToStyles(Object.assign({},l,{offsets:t.modifiersData.arrow,position:"absolute",adaptive:false,roundOffsets:f})))}t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-placement":t.placement})}var computeStyles$1={name:"computeStyles",enabled:true,phase:"beforeWrite",fn:computeStyles,data:{}};var passive={passive:true};function effect(e){var t=e.state,r=e.instance,n=e.options;var a=n.scroll,i=a===void 0?true:a,o=n.resize,s=o===void 0?true:o;var f=getWindow(t.elements.popper);var l=[].concat(t.scrollParents.reference,t.scrollParents.popper);if(i){l.forEach((function(e){e.addEventListener("scroll",r.update,passive)}))}if(s){f.addEventListener("resize",r.update,passive)}return function(){if(i){l.forEach((function(e){e.removeEventListener("scroll",r.update,passive)}))}if(s){f.removeEventListener("resize",r.update,passive)}}}var eventListeners={name:"eventListeners",enabled:true,phase:"write",fn:function e(){},effect:effect,data:{}};var hash$1={left:"right",right:"left",bottom:"top",top:"bottom"};function getOppositePlacement(e){return e.replace(/left|right|bottom|top/g,(function(e){return hash$1[e]}))}var hash={start:"end",end:"start"};function getOppositeVariationPlacement(e){return e.replace(/start|end/g,(function(e){return hash[e]}))}function getWindowScroll(e){var t=getWindow(e);var r=t.pageXOffset;var n=t.pageYOffset;return{scrollLeft:r,scrollTop:n}}function getWindowScrollBarX(e){return getBoundingClientRect(getDocumentElement(e)).left+getWindowScroll(e).scrollLeft}function getViewportRect(e){var t=getWindow(e);var r=getDocumentElement(e);var n=t.visualViewport;var a=r.clientWidth;var i=r.clientHeight;var o=0;var s=0;if(n){a=n.width;i=n.height;if(!/^((?!chrome|android).)*safari/i.test(navigator.userAgent)){o=n.offsetLeft;s=n.offsetTop}}return{width:a,height:i,x:o+getWindowScrollBarX(e),y:s}}function getDocumentRect(e){var t;var r=getDocumentElement(e);var n=getWindowScroll(e);var a=(t=e.ownerDocument)==null?void 0:t.body;var i=max(r.scrollWidth,r.clientWidth,a?a.scrollWidth:0,a?a.clientWidth:0);var o=max(r.scrollHeight,r.clientHeight,a?a.scrollHeight:0,a?a.clientHeight:0);var s=-n.scrollLeft+getWindowScrollBarX(e);var f=-n.scrollTop;if(getComputedStyle(a||r).direction==="rtl"){s+=max(r.clientWidth,a?a.clientWidth:0)-i}return{width:i,height:o,x:s,y:f}}function isScrollParent(e){var t=getComputedStyle(e),r=t.overflow,n=t.overflowX,a=t.overflowY;return/auto|scroll|overlay|hidden/.test(r+a+n)}function getScrollParent(e){if(["html","body","#document"].indexOf(getNodeName(e))>=0){return e.ownerDocument.body}if(isHTMLElement(e)&&isScrollParent(e)){return e}return getScrollParent(getParentNode(e))}function listScrollParents(e,t){var r;if(t===void 0){t=[]}var n=getScrollParent(e);var a=n===((r=e.ownerDocument)==null?void 0:r.body);var i=getWindow(n);var o=a?[i].concat(i.visualViewport||[],isScrollParent(n)?n:[]):n;var s=t.concat(o);return a?s:s.concat(listScrollParents(getParentNode(o)))}function rectToClientRect(e){return Object.assign({},e,{left:e.x,top:e.y,right:e.x+e.width,bottom:e.y+e.height})}function getInnerBoundingClientRect(e){var t=getBoundingClientRect(e);t.top=t.top+e.clientTop;t.left=t.left+e.clientLeft;t.bottom=t.top+e.clientHeight;t.right=t.left+e.clientWidth;t.width=e.clientWidth;t.height=e.clientHeight;t.x=t.left;t.y=t.top;return t}function getClientRectFromMixedType(e,t){return t===viewport?rectToClientRect(getViewportRect(e)):isElement(t)?getInnerBoundingClientRect(t):rectToClientRect(getDocumentRect(getDocumentElement(e)))}function getClippingParents(e){var t=listScrollParents(getParentNode(e));var r=["absolute","fixed"].indexOf(getComputedStyle(e).position)>=0;var n=r&&isHTMLElement(e)?getOffsetParent(e):e;if(!isElement(n)){return[]}return t.filter((function(e){return isElement(e)&&contains(e,n)&&getNodeName(e)!=="body"}))}function getClippingRect(e,t,r){var n=t==="clippingParents"?getClippingParents(e):[].concat(t);var a=[].concat(n,[r]);var i=a[0];var o=a.reduce((function(t,r){var n=getClientRectFromMixedType(e,r);t.top=max(n.top,t.top);t.right=min(n.right,t.right);t.bottom=min(n.bottom,t.bottom);t.left=max(n.left,t.left);return t}),getClientRectFromMixedType(e,i));o.width=o.right-o.left;o.height=o.bottom-o.top;o.x=o.left;o.y=o.top;return o}function computeOffsets(e){var t=e.reference,r=e.element,n=e.placement;var a=n?getBasePlacement(n):null;var i=n?getVariation(n):null;var o=t.x+t.width/2-r.width/2;var s=t.y+t.height/2-r.height/2;var f;switch(a){case top:f={x:o,y:t.y-r.height};break;case bottom:f={x:o,y:t.y+t.height};break;case right:f={x:t.x+t.width,y:s};break;case left:f={x:t.x-r.width,y:s};break;default:f={x:t.x,y:t.y}}var l=a?getMainAxisFromPlacement(a):null;if(l!=null){var c=l==="y"?"height":"width";switch(i){case start:f[l]=f[l]-(t[c]/2-r[c]/2);break;case end:f[l]=f[l]+(t[c]/2-r[c]/2);break}}return f}function detectOverflow(e,t){if(t===void 0){t={}}var r=t,n=r.placement,a=n===void 0?e.placement:n,i=r.boundary,o=i===void 0?clippingParents:i,s=r.rootBoundary,f=s===void 0?viewport:s,l=r.elementContext,c=l===void 0?popper:l,p=r.altBoundary,u=p===void 0?false:p,d=r.padding,v=d===void 0?0:d;var m=mergePaddingObject(typeof v!=="number"?v:expandToHashMap(v,basePlacements));var g=c===popper?reference:popper;var h=e.rects.popper;var y=e.elements[u?g:c];var b=getClippingRect(isElement(y)?y:y.contextElement||getDocumentElement(e.elements.popper),o,f);var w=getBoundingClientRect(e.elements.reference);var O=computeOffsets({reference:w,element:h,strategy:"absolute",placement:a});var x=rectToClientRect(Object.assign({},h,O));var P=c===popper?x:w;var S={top:b.top-P.top+m.top,bottom:P.bottom-b.bottom+m.bottom,left:b.left-P.left+m.left,right:P.right-b.right+m.right};var E=e.modifiersData.offset;if(c===popper&&E){var M=E[a];Object.keys(S).forEach((function(e){var t=[right,bottom].indexOf(e)>=0?1:-1;var r=[top,bottom].indexOf(e)>=0?"y":"x";S[e]+=M[r]*t}))}return S}function computeAutoPlacement(e,t){if(t===void 0){t={}}var r=t,n=r.placement,a=r.boundary,i=r.rootBoundary,o=r.padding,s=r.flipVariations,f=r.allowedAutoPlacements,l=f===void 0?placements:f;var c=getVariation(n);var p=c?s?variationPlacements:variationPlacements.filter((function(e){return getVariation(e)===c})):basePlacements;var u=p.filter((function(e){return l.indexOf(e)>=0}));if(u.length===0){u=p}var d=u.reduce((function(t,r){t[r]=detectOverflow(e,{placement:r,boundary:a,rootBoundary:i,padding:o})[getBasePlacement(r)];return t}),{});return Object.keys(d).sort((function(e,t){return d[e]-d[t]}))}function getExpandedFallbackPlacements(e){if(getBasePlacement(e)===auto){return[]}var t=getOppositePlacement(e);return[getOppositeVariationPlacement(e),t,getOppositeVariationPlacement(t)]}function flip(e){var t=e.state,r=e.options,n=e.name;if(t.modifiersData[n]._skip){return}var a=r.mainAxis,i=a===void 0?true:a,o=r.altAxis,s=o===void 0?true:o,f=r.fallbackPlacements,l=r.padding,c=r.boundary,p=r.rootBoundary,u=r.altBoundary,d=r.flipVariations,v=d===void 0?true:d,m=r.allowedAutoPlacements;var g=t.options.placement;var h=getBasePlacement(g);var y=h===g;var b=f||(y||!v?[getOppositePlacement(g)]:getExpandedFallbackPlacements(g));var w=[g].concat(b).reduce((function(e,r){return e.concat(getBasePlacement(r)===auto?computeAutoPlacement(t,{placement:r,boundary:c,rootBoundary:p,padding:l,flipVariations:v,allowedAutoPlacements:m}):r)}),[]);var O=t.rects.reference;var x=t.rects.popper;var P=new Map;var S=true;var E=w[0];for(var M=0;M<w.length;M++){var T=w[M];var C=getBasePlacement(T);var R=getVariation(T)===start;var D=[top,bottom].indexOf(C)>=0;var B=D?"width":"height";var A=detectOverflow(t,{placement:T,boundary:c,rootBoundary:p,altBoundary:u,padding:l});var L=D?R?right:left:R?bottom:top;if(O[B]>x[B]){L=getOppositePlacement(L)}var j=getOppositePlacement(L);var W=[];if(i){W.push(A[C]<=0)}if(s){W.push(A[L]<=0,A[j]<=0)}if(W.every((function(e){return e}))){E=T;S=false;break}P.set(T,W)}if(S){var N=v?3:1;var H=function e(t){var r=w.find((function(e){var r=P.get(e);if(r){return r.slice(0,t).every((function(e){return e}))}}));if(r){E=r;return"break"}};for(var k=N;k>0;k--){var V=H(k);if(V==="break")break}}if(t.placement!==E){t.modifiersData[n]._skip=true;t.placement=E;t.reset=true}}var flip$1={name:"flip",enabled:true,phase:"main",fn:flip,requiresIfExists:["offset"],data:{_skip:false}};function getSideOffsets(e,t,r){if(r===void 0){r={x:0,y:0}}return{top:e.top-t.height-r.y,right:e.right-t.width+r.x,bottom:e.bottom-t.height+r.y,left:e.left-t.width-r.x}}function isAnySideFullyClipped(e){return[top,right,bottom,left].some((function(t){return e[t]>=0}))}function hide(e){var t=e.state,r=e.name;var n=t.rects.reference;var a=t.rects.popper;var i=t.modifiersData.preventOverflow;var o=detectOverflow(t,{elementContext:"reference"});var s=detectOverflow(t,{altBoundary:true});var f=getSideOffsets(o,n);var l=getSideOffsets(s,a,i);var c=isAnySideFullyClipped(f);var p=isAnySideFullyClipped(l);t.modifiersData[r]={referenceClippingOffsets:f,popperEscapeOffsets:l,isReferenceHidden:c,hasPopperEscaped:p};t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-reference-hidden":c,"data-popper-escaped":p})}var hide$1={name:"hide",enabled:true,phase:"main",requiresIfExists:["preventOverflow"],fn:hide};function distanceAndSkiddingToXY(e,t,r){var n=getBasePlacement(e);var a=[left,top].indexOf(n)>=0?-1:1;var i=typeof r==="function"?r(Object.assign({},t,{placement:e})):r,o=i[0],s=i[1];o=o||0;s=(s||0)*a;return[left,right].indexOf(n)>=0?{x:s,y:o}:{x:o,y:s}}function offset(e){var t=e.state,r=e.options,n=e.name;var a=r.offset,i=a===void 0?[0,0]:a;var o=placements.reduce((function(e,r){e[r]=distanceAndSkiddingToXY(r,t.rects,i);return e}),{});var s=o[t.placement],f=s.x,l=s.y;if(t.modifiersData.popperOffsets!=null){t.modifiersData.popperOffsets.x+=f;t.modifiersData.popperOffsets.y+=l}t.modifiersData[n]=o}var offset$1={name:"offset",enabled:true,phase:"main",requires:["popperOffsets"],fn:offset};function popperOffsets(e){var t=e.state,r=e.name;t.modifiersData[r]=computeOffsets({reference:t.rects.reference,element:t.rects.popper,strategy:"absolute",placement:t.placement})}var popperOffsets$1={name:"popperOffsets",enabled:true,phase:"read",fn:popperOffsets,data:{}};function getAltAxis(e){return e==="x"?"y":"x"}function preventOverflow(e){var t=e.state,r=e.options,n=e.name;var a=r.mainAxis,i=a===void 0?true:a,o=r.altAxis,s=o===void 0?false:o,f=r.boundary,l=r.rootBoundary,c=r.altBoundary,p=r.padding,u=r.tether,d=u===void 0?true:u,v=r.tetherOffset,m=v===void 0?0:v;var g=detectOverflow(t,{boundary:f,rootBoundary:l,padding:p,altBoundary:c});var h=getBasePlacement(t.placement);var y=getVariation(t.placement);var b=!y;var w=getMainAxisFromPlacement(h);var O=getAltAxis(w);var x=t.modifiersData.popperOffsets;var P=t.rects.reference;var S=t.rects.popper;var E=typeof m==="function"?m(Object.assign({},t.rects,{placement:t.placement})):m;var M=typeof E==="number"?{mainAxis:E,altAxis:E}:Object.assign({mainAxis:0,altAxis:0},E);var T=t.modifiersData.offset?t.modifiersData.offset[t.placement]:null;var C={x:0,y:0};if(!x){return}if(i){var R;var D=w==="y"?top:left;var B=w==="y"?bottom:right;var A=w==="y"?"height":"width";var L=x[w];var j=L+g[D];var W=L-g[B];var N=d?-S[A]/2:0;var H=y===start?P[A]:S[A];var k=y===start?-S[A]:-P[A];var V=t.elements.arrow;var $=d&&V?getLayoutRect(V):{width:0,height:0};var F=t.modifiersData["arrow#persistent"]?t.modifiersData["arrow#persistent"].padding:getFreshSideObject();var _=F[D];var q=F[B];var I=within(0,P[A],$[A]);var X=b?P[A]/2-N-I-_-M.mainAxis:H-I-_-M.mainAxis;var U=b?-P[A]/2+N+I+q+M.mainAxis:k+I+q+M.mainAxis;var z=t.elements.arrow&&getOffsetParent(t.elements.arrow);var Y=z?w==="y"?z.clientTop||0:z.clientLeft||0:0;var G=(R=T==null?void 0:T[w])!=null?R:0;var J=L+X-G-Y;var K=L+U-G;var Q=within(d?min(j,J):j,L,d?max(W,K):W);x[w]=Q;C[w]=Q-L}if(s){var Z;var ee=w==="x"?top:left;var te=w==="x"?bottom:right;var re=x[O];var ne=O==="y"?"height":"width";var ae=re+g[ee];var ie=re-g[te];var oe=[top,left].indexOf(h)!==-1;var se=(Z=T==null?void 0:T[O])!=null?Z:0;var fe=oe?ae:re-P[ne]-S[ne]-se+M.altAxis;var le=oe?re+P[ne]+S[ne]-se-M.altAxis:ie;var ce=d&&oe?withinMaxClamp(fe,re,le):within(d?fe:ae,re,d?le:ie);x[O]=ce;C[O]=ce-re}t.modifiersData[n]=C}var preventOverflow$1={name:"preventOverflow",enabled:true,phase:"main",fn:preventOverflow,requiresIfExists:["offset"]};function getHTMLElementScroll(e){return{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}}function getNodeScroll(e){if(e===getWindow(e)||!isHTMLElement(e)){return getWindowScroll(e)}else{return getHTMLElementScroll(e)}}function isElementScaled(e){var t=e.getBoundingClientRect();var r=round(t.width)/e.offsetWidth||1;var n=round(t.height)/e.offsetHeight||1;return r!==1||n!==1}function getCompositeRect(e,t,r){if(r===void 0){r=false}var n=isHTMLElement(t);var a=isHTMLElement(t)&&isElementScaled(t);var i=getDocumentElement(t);var o=getBoundingClientRect(e,a);var s={scrollLeft:0,scrollTop:0};var f={x:0,y:0};if(n||!n&&!r){if(getNodeName(t)!=="body"||isScrollParent(i)){s=getNodeScroll(t)}if(isHTMLElement(t)){f=getBoundingClientRect(t,true);f.x+=t.clientLeft;f.y+=t.clientTop}else if(i){f.x=getWindowScrollBarX(i)}}return{x:o.left+s.scrollLeft-f.x,y:o.top+s.scrollTop-f.y,width:o.width,height:o.height}}function order(e){var t=new Map;var r=new Set;var n=[];e.forEach((function(e){t.set(e.name,e)}));function a(e){r.add(e.name);var i=[].concat(e.requires||[],e.requiresIfExists||[]);i.forEach((function(e){if(!r.has(e)){var n=t.get(e);if(n){a(n)}}}));n.push(e)}e.forEach((function(e){if(!r.has(e.name)){a(e)}}));return n}function orderModifiers(e){var t=order(e);return modifierPhases.reduce((function(e,r){return e.concat(t.filter((function(e){return e.phase===r})))}),[])}function debounce(e){var t;return function(){if(!t){t=new Promise((function(r){Promise.resolve().then((function(){t=undefined;r(e())}))}))}return t}}function mergeByName(e){var t=e.reduce((function(e,t){var r=e[t.name];e[t.name]=r?Object.assign({},r,t,{options:Object.assign({},r.options,t.options),data:Object.assign({},r.data,t.data)}):t;return e}),{});return Object.keys(t).map((function(e){return t[e]}))}var DEFAULT_OPTIONS={placement:"bottom",modifiers:[],strategy:"absolute"};function areValidElements(){for(var e=arguments.length,t=new Array(e),r=0;r<e;r++){t[r]=arguments[r]}return!t.some((function(e){return!(e&&typeof e.getBoundingClientRect==="function")}))}function popperGenerator(e){if(e===void 0){e={}}var t=e,r=t.defaultModifiers,n=r===void 0?[]:r,a=t.defaultOptions,i=a===void 0?DEFAULT_OPTIONS:a;return function e(t,r,a){if(a===void 0){a=i}var o={placement:"bottom",orderedModifiers:[],options:Object.assign({},DEFAULT_OPTIONS,i),modifiersData:{},elements:{reference:t,popper:r},attributes:{},styles:{}};var s=[];var f=false;var l={state:o,setOptions:function e(a){var s=typeof a==="function"?a(o.options):a;p();o.options=Object.assign({},i,o.options,s);o.scrollParents={reference:isElement(t)?listScrollParents(t):t.contextElement?listScrollParents(t.contextElement):[],popper:listScrollParents(r)};var f=orderModifiers(mergeByName([].concat(n,o.options.modifiers)));o.orderedModifiers=f.filter((function(e){return e.enabled}));c();return l.update()},forceUpdate:function e(){if(f){return}var t=o.elements,r=t.reference,n=t.popper;if(!areValidElements(r,n)){return}o.rects={reference:getCompositeRect(r,getOffsetParent(n),o.options.strategy==="fixed"),popper:getLayoutRect(n)};o.reset=false;o.placement=o.options.placement;o.orderedModifiers.forEach((function(e){return o.modifiersData[e.name]=Object.assign({},e.data)}));for(var a=0;a<o.orderedModifiers.length;a++){if(o.reset===true){o.reset=false;a=-1;continue}var i=o.orderedModifiers[a],s=i.fn,c=i.options,p=c===void 0?{}:c,u=i.name;if(typeof s==="function"){o=s({state:o,options:p,name:u,instance:l})||o}}},update:debounce((function(){return new Promise((function(e){l.forceUpdate();e(o)}))})),destroy:function e(){p();f=true}};if(!areValidElements(t,r)){return l}l.setOptions(a).then((function(e){if(!f&&a.onFirstUpdate){a.onFirstUpdate(e)}}));function c(){o.orderedModifiers.forEach((function(e){var t=e.name,r=e.options,n=r===void 0?{}:r,a=e.effect;if(typeof a==="function"){var i=a({state:o,name:t,instance:l,options:n});var f=function e(){};s.push(i||f)}}))}function p(){s.forEach((function(e){return e()}));s=[]}return l}}var defaultModifiers=[eventListeners,popperOffsets$1,computeStyles$1,applyStyles$1,offset$1,flip$1,preventOverflow$1,arrow$1,hide$1];var createPopper$1=popperGenerator({defaultModifiers:defaultModifiers});var CSS={animation:"calcite-popper-anim",animationActive:"calcite-popper-anim--active"};function getPlacement(e,t){var r=["left","right"];var n=["start","end"];if(getElementDir(e)==="rtl"){r.reverse();n.reverse()}return t.replace(/-leading/gi,"-"+n[0]).replace(/-trailing/gi,"-"+n[1]).replace(/leading/gi,r[0]).replace(/trailing/gi,r[1])}function createPopper(e){var t=e.referenceEl,r=e.el,n=e.placement,a=e.overlayPositioning,i=a===void 0?"absolute":a,o=e.modifiers;if(!t){return null}return createPopper$1(t,r,{strategy:i,placement:getPlacement(r,n),modifiers:o})}function updatePopper(e){var t=e.el,r=e.modifiers,n=e.placement,a=e.popper;return __awaiter(this,void 0,void 0,(function(){var e;return __generator(this,(function(i){switch(i.label){case 0:e=getPlacement(t,n);return[4,a.setOptions({modifiers:r,placement:e})];case 1:i.sent();return[2]}}))}))}function hypotenuse(e,t){return Math.sqrt(Math.pow(e,2)+Math.pow(t,2))}var visiblePointerSize=4;var defaultOffsetDistance=Math.ceil(hypotenuse(visiblePointerSize,visiblePointerSize));export{CSS as C,createPopper as c,defaultOffsetDistance as d,updatePopper as u};
|
|
@@ -2,4 +2,4 @@ var __awaiter=this&&this.__awaiter||function(e,t,n,r){function a(e){return e ins
|
|
|
2
2
|
/*!
|
|
3
3
|
* All material copyright ESRI, All Rights Reserved, unless otherwise specified.
|
|
4
4
|
* See https://github.com/Esri/calcite-components/blob/master/LICENSE.md for details.
|
|
5
|
-
*/import{a as getAssetPath}from"./index-9de00868.js";import{a as locales}from"./locale-
|
|
5
|
+
*/import{a as getAssetPath}from"./index-9de00868.js";import{a as locales}from"./locale-1b48f64f.js";function getSupportedLocale(e){if(e===void 0){e=""}if(locales.indexOf(e)>-1){return e}else{var t=e.split("-")[0];return locales.indexOf(t)>-1?t:"en"}}var translationCache={};var requestCache={};function getLocaleData(e){return __awaiter(this,void 0,void 0,(function(){var t,n;return __generator(this,(function(r){switch(r.label){case 0:t=getSupportedLocale(e);if(translationCache[t]){return[2,translationCache[t]]}if(!requestCache[t]){requestCache[t]=fetch(getAssetPath("./assets/calcite-date-picker/nls/"+t+".json")).then((function(e){return e.json()})).catch((function(){console.error('Translations for "'+t+'" not found or invalid, falling back to english');return getLocaleData("en")}))}return[4,requestCache[t]];case 1:n=r.sent();translationCache[t]=n;return[2,n]}}))}))}function inRange(e,t,n){var r=e.getTime();var a=!(t instanceof Date)||r>=t.getTime();var i=!(n instanceof Date)||r<=n.getTime();return a&&i}function dateFromRange(e,t,n){if(!(e instanceof Date)){return null}var r=e.getTime();var a=t instanceof Date&&r<t.getTime();var i=n instanceof Date&&r>n.getTime();if(a){return t}if(i){return n}return e}function dateFromISO(e){if(e instanceof Date){return e}if(!e||typeof e!=="string"){return null}var t=e.split(/[: T-]/).map(parseFloat);var n=new Date(t[0],(t[1]||1)-1,t[2]||1);n.setFullYear(t[0]);if(isNaN(n.getTime())){throw new Error('Invalid ISO 8601 date: "'+e+'"')}return n}function dateToISO(e){if(typeof e==="string"){return e}if(e instanceof Date){return new Date(e.getTime()-e.getTimezoneOffset()*6e4).toISOString().split("T")[0]}return""}function sameDate(e,t){return e instanceof Date&&t instanceof Date&&e.getDate()===t.getDate()&&e.getMonth()===t.getMonth()&&e.getFullYear()===t.getFullYear()}function prevMonth(e){var t=e.getMonth();var n=new Date(e);n.setMonth(t-1);if(t===n.getMonth()){return new Date(e.getFullYear(),t,0)}return n}function nextMonth(e){var t=e.getMonth();var n=new Date(e);n.setMonth(t+1);if((t+2)%7===n.getMonth()%7){return new Date(e.getFullYear(),t+2,0)}return n}function localizeNumber(e,t){return String(e).split("").map((function(e){return t.numerals[e]})).join("")}function parseNumber(e,t){var n="0123456789";return parseInt(e.split("").map((function(e){return n[t.numerals.indexOf(e)]})).filter((function(e){return e})).join(""))}function parseDateString(e,t){var n=t.separator,r=t.unitOrder;var a=getOrder(r);var i=replaceArabicNumerals(e).split(n);return{day:parseInt(i[a.indexOf("d")]),month:parseInt(i[a.indexOf("m")])-1,year:parseInt(i[a.indexOf("y")])}}function replaceArabicNumerals(e){if(e===void 0){e=""}return e.replace(/[\u0660-\u0669]/g,(function(e){return e.charCodeAt(0)-1632})).replace(/[\u06f0-\u06f9]/g,(function(e){return e.charCodeAt(0)-1776}))}function getOrder(e){var t=["d","m","y"];var n=e.toLowerCase();return t.sort((function(e,t){return n.indexOf(e)-n.indexOf(t)}))}function getDaysDiff(e,t){var n=e.getTime();var r=t.getTime();return(n-r)/(1e3*3600*24)}var HEADING_LEVEL=2;var TEXT={nextMonth:"Next month",prevMonth:"Previous month",year:"Year"};export{HEADING_LEVEL as H,TEXT as T,dateFromISO as a,dateFromRange as b,getDaysDiff as c,dateToISO as d,getOrder as e,prevMonth as f,getLocaleData as g,parseNumber as h,inRange as i,localizeNumber as l,nextMonth as n,parseDateString as p,sameDate as s};
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
var __awaiter=this&&this.__awaiter||function(e,t,i,n){function a(e){return e instanceof i?e:new i((function(t){t(e)}))}return new(i||(i=Promise))((function(i,r){function l(e){try{o(n.next(e))}catch(e){r(e)}}function s(e){try{o(n["throw"](e))}catch(e){r(e)}}function o(e){e.done?i(e.value):a(e.value).then(l,s)}o((n=n.apply(e,t||[])).next())}))};var __generator=this&&this.__generator||function(e,t){var i={label:0,sent:function(){if(r[0]&1)throw r[1];return r[1]},trys:[],ops:[]},n,a,r,l;return l={next:s(0),throw:s(1),return:s(2)},typeof Symbol==="function"&&(l[Symbol.iterator]=function(){return this}),l;function s(e){return function(t){return o([e,t])}}function o(l){if(n)throw new TypeError("Generator is already executing.");while(i)try{if(n=1,a&&(r=l[0]&2?a["return"]:l[0]?a["throw"]||((r=a["return"])&&r.call(a),0):a.next)&&!(r=r.call(a,l[1])).done)return r;if(a=0,r)l=[l[0]&2,r.value];switch(l[0]){case 0:case 1:r=l;break;case 4:i.label++;return{value:l[1],done:false};case 5:i.label++;a=l[1];l=[0];continue;case 7:l=i.ops.pop();i.trys.pop();continue;default:if(!(r=i.trys,r=r.length>0&&r[r.length-1])&&(l[0]===6||l[0]===2)){i=0;continue}if(l[0]===3&&(!r||l[1]>r[0]&&l[1]<r[3])){i.label=l[1];break}if(l[0]===6&&i.label<r[1]){i.label=r[1];r=l;break}if(r&&i.label<r[2]){i.label=r[2];i.ops.push(l);break}if(r[2])i.ops.pop();i.trys.pop();continue}l=t.call(e,i)}catch(e){l=[6,e];a=0}finally{n=r=0}if(l[0]&5)throw l[1];return{value:l[0]?l[1]:void 0,done:true}}};
|
|
2
|
+
/*!
|
|
3
|
+
* All material copyright ESRI, All Rights Reserved, unless otherwise specified.
|
|
4
|
+
* See https://github.com/Esri/calcite-components/blob/master/LICENSE.md for details.
|
|
5
|
+
*/import{f as focusElement,g as getSlotted}from"./dom-e55f9eaf.js";import{g as getRoundRobinIndex}from"./array-91a648e2.js";import{d as debounce}from"./debounce-79648d42.js";import{h,H as Host}from"./index-9de00868.js";function mutationObserverCallback(){this.setUpItems();this.setUpFilter();this.deselectRemovedItems()}var SUPPORTED_ARROW_KEYS=["ArrowUp","ArrowDown"];function initialize(){this.setUpItems();this.setUpFilter();this.emitCalciteListChange=debounce(internalCalciteListChangeEvent.bind(this),0)}function initializeObserver(){var e;(e=this.mutationObserver)===null||e===void 0?void 0:e.observe(this.el,{childList:true,subtree:true})}function cleanUpObserver(){var e;(e=this.mutationObserver)===null||e===void 0?void 0:e.disconnect()}function calciteListItemChangeHandler(e){var t=this.selectedValues;var i=e.detail,n=i.item,a=i.value,r=i.selected,l=i.shiftPressed;if(r){if(this.multiple&&l){this.selectSiblings(n)}if(!this.multiple){this.deselectSiblingItems(n)}t.set(a,n)}else{t.delete(a);if(this.multiple&&l){this.selectSiblings(n,true)}}if(!this.multiple){toggleSingleSelectItemTabbing(n,r);if(r){focusElement(n)}}this.lastSelectedItem=n;this.emitCalciteListChange()}function calciteListItemValueChangeHandler(e){e.stopPropagation();var t=e.detail.oldValue;var i=this.selectedValues;if(i.has(t)){var n=i.get(t);i.delete(t);i.set(e.detail.newValue,n)}}function isValidNavigationKey(e){return!!SUPPORTED_ARROW_KEYS.find((function(t){return t===e}))}function calciteListFocusOutHandler(e){var t=this,i=t.el,n=t.items,a=t.multiple,r=t.selectedValues;if(a){return}var l=!!i.contains(e.relatedTarget);if(l){toggleSingleSelectItemTabbing(e.target,false);return}n.forEach((function(t){return toggleSingleSelectItemTabbing(t,r.size===0?e.target===t:t.selected)}))}function keyDownHandler(e){var t=e.key,i=e.target;if(!isValidNavigationKey(t)){return}var n=this,a=n.items,r=n.multiple,l=n.selectionFollowsFocus;var s=a.length;var o=a.indexOf(i);if(!s||o===-1){return}e.preventDefault();var c=getRoundRobinIndex(o+(t==="ArrowUp"?-1:1),s);var u=a[c];a.forEach((function(e){return toggleSingleSelectItemTabbing(e,e===u)}));if(!r&&l){u.selected=true}focusElement(u)}function internalCalciteListChangeEvent(){this.calciteListChange.emit(this.selectedValues)}function removeItem(e){if(e.defaultPrevented){return}var t=e.target;var i=this.selectedValues;if(t.parentElement.tagName==="CALCITE-PICK-LIST-GROUP"){t.parentElement.remove();Array.from(t.parentElement.children).forEach((function(e){return i.delete(e.value)}))}else{t.remove();i.delete(t.value)}this.emitCalciteListChange()}function toggleSingleSelectItemTabbing(e,t){if(t){e.removeAttribute("tabindex")}else{e.setAttribute("tabindex","-1")}}function setFocus(e){return __awaiter(this,void 0,void 0,(function(){var t,i,n,a,r;return __generator(this,(function(l){switch(l.label){case 0:if(!(this.filterEnabled&&e==="filter"))return[3,2];return[4,focusElement(this.filterEl)];case 1:l.sent();return[2];case 2:t=this,i=t.items,n=t.multiple,a=t.selectionFollowsFocus;if(i.length===0){return[2]}if(n){return[2,i[0].setFocus()]}r=i.find((function(e){return e.selected}))||i[0];if(a){r.selected=true}return[2,r.setFocus()]}}))}))}function setUpItems(e){var t=this;this.items=Array.from(this.el.querySelectorAll(e));var i=false;var n=this.items;n.forEach((function(e){e.icon=t.getIconType();if(!t.multiple){e.disableDeselect=true;toggleSingleSelectItemTabbing(e,false)}if(e.selected){i=true;toggleSingleSelectItemTabbing(e,true);t.selectedValues.set(e.value,e)}}));var a=n[0];if(!i&&a){toggleSingleSelectItemTabbing(a,true)}}function deselectRemovedItems(){var e=this;var t=this.selectedValues;var i=this.items.map((function(e){var t=e.value;return t}));t.forEach((function(t){if(!i.includes(t.value)){e.selectedValues.delete(t.value)}}))}function deselectSiblingItems(e){var t=this;this.items.forEach((function(i){if(i.value!==e.value){i.toggleSelected(false);if(t.selectedValues.has(i.value)){t.selectedValues.delete(i.value)}}}))}function selectSiblings(e,t){var i=this;if(t===void 0){t=false}if(!this.lastSelectedItem){return}var n=this.items;var a=n.findIndex((function(e){return e.value===i.lastSelectedItem.value}));var r=n.findIndex((function(t){return t.value===e.value}));n.slice(Math.min(a,r),Math.max(a,r)).forEach((function(e){e.toggleSelected(!t);if(!t){i.selectedValues.set(e.value,e)}else{i.selectedValues.delete(e.value)}}))}var groups;function handleFilter(e){var t=e.currentTarget.filteredItems;var i=t.map((function(e){return e.value}));var n=false;if(!groups){groups=new Set}var a=this.items.filter((function(e){var t=e.parentElement;var a=t.matches("calcite-pick-list-group");if(a){groups.add(t)}var r=i.includes(e.value);e.hidden=!r;if(!n){n=r&&e.selected}return r}));groups.forEach((function(e){var t=a.some((function(t){return e.contains(t)}));e.hidden=!t;if(!t){return}var i=getSlotted(e,"parent-item");if(i){i.hidden=false;if(a.includes(i)){Array.from(e.children).forEach((function(e){return e.hidden=false}))}}}));groups.clear();if(a.length>0&&!n&&!this.multiple){toggleSingleSelectItemTabbing(a[0],true)}}function getItemData(){return this.items.map((function(e){return{label:e.label,description:e.description,metadata:e.metadata,value:e.value}}))}var CSS$1={sticky:"sticky-pos"};var ICON_TYPES;(function(e){e["circle"]="circle";e["square"]="square";e["grip"]="grip"})(ICON_TYPES||(ICON_TYPES={}));var SLOTS$1={menuActions:"menu-actions"};var __rest=undefined&&undefined.__rest||function(e,t){var i={};for(var n in e)if(Object.prototype.hasOwnProperty.call(e,n)&&t.indexOf(n)<0)i[n]=e[n];if(e!=null&&typeof Object.getOwnPropertySymbols==="function")for(var a=0,n=Object.getOwnPropertySymbols(e);a<n.length;a++){if(t.indexOf(n[a])<0&&Object.prototype.propertyIsEnumerable.call(e,n[a]))i[n[a]]=e[n[a]]}return i};var List=function(e){var t;var i=e.props,n=i.disabled,a=i.loading,r=i.filterEnabled,l=i.dataForFilter,s=i.handleFilter,o=i.filterPlaceholder,c=i.setFilterEl,u=__rest(e,["props"]);var f=h("slot",null);return h(Host,Object.assign({"aria-busy":a.toString(),"aria-disabled":n.toString(),role:"menu"},u),h("section",null,h("header",{class:(t={},t[CSS$1.sticky]=true,t)},r?h("calcite-filter",{"aria-label":o,disabled:a||n,items:l,onCalciteFilterChange:s,placeholder:o,ref:c}):null,h("slot",{name:SLOTS$1.menuActions})),a||n?h("calcite-scrim",{loading:a}):null,f))};var CSS={actions:"actions",actionsEnd:"actions--end",actionsStart:"actions--start",description:"description",handle:"handle",handleActivated:"handle--activated",highlight:"highlight",icon:"icon",iconDot:"icon-dot",label:"label",remove:"remove",title:"title",textContainer:"text-container"};var ICONS={checked:"check",remove:"x"};var SLOTS={actionsEnd:"actions-end",actionsStart:"actions-start"};var TEXT={remove:"Remove"};export{CSS as C,ICON_TYPES as I,List as L,SLOTS as S,TEXT as T,deselectSiblingItems as a,initializeObserver as b,cleanUpObserver as c,deselectRemovedItems as d,calciteListItemChangeHandler as e,calciteListItemValueChangeHandler as f,getItemData as g,handleFilter as h,initialize as i,setUpItems as j,keyDownHandler as k,setFocus as l,mutationObserverCallback as m,calciteListFocusOutHandler as n,ICONS as o,removeItem as r,selectSiblings as s};
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
{
|
|
2
|
-
"timestamp": "
|
|
2
|
+
"timestamp": "2022-01-04T23:59:03",
|
|
3
3
|
"compiler": {
|
|
4
4
|
"name": "@stencil/core",
|
|
5
|
-
"version": "2.12.
|
|
5
|
+
"version": "2.12.1",
|
|
6
6
|
"typescriptVersion": "4.3.5"
|
|
7
7
|
},
|
|
8
8
|
"components": [
|
|
@@ -15,7 +15,7 @@
|
|
|
15
15
|
"docsTags": [
|
|
16
16
|
{
|
|
17
17
|
"name": "slot",
|
|
18
|
-
"text": "- A slot for adding `calcite-accordion-item`s."
|
|
18
|
+
"text": "- A slot for adding `calcite-accordion-item`s. `calcite-accordion` cannot be nested, however calcite-accordion-item`s can."
|
|
19
19
|
}
|
|
20
20
|
],
|
|
21
21
|
"usage": {
|
|
@@ -172,7 +172,7 @@
|
|
|
172
172
|
"slots": [
|
|
173
173
|
{
|
|
174
174
|
"name": "",
|
|
175
|
-
"docs": "A slot for adding `calcite-accordion-item`s."
|
|
175
|
+
"docs": "A slot for adding `calcite-accordion-item`s. `calcite-accordion` cannot be nested, however calcite-accordion-item`s can."
|
|
176
176
|
}
|
|
177
177
|
],
|
|
178
178
|
"parts": [],
|
|
@@ -189,7 +189,7 @@
|
|
|
189
189
|
"docsTags": [
|
|
190
190
|
{
|
|
191
191
|
"name": "slot",
|
|
192
|
-
"text": "- A slot for adding custom content."
|
|
192
|
+
"text": "- A slot for adding custom content, including nested `calcite-accordion-item`s."
|
|
193
193
|
}
|
|
194
194
|
],
|
|
195
195
|
"usage": {},
|
|
@@ -279,7 +279,7 @@
|
|
|
279
279
|
"slots": [
|
|
280
280
|
{
|
|
281
281
|
"name": "",
|
|
282
|
-
"docs": "A slot for adding custom content."
|
|
282
|
+
"docs": "A slot for adding custom content, including nested `calcite-accordion-item`s."
|
|
283
283
|
}
|
|
284
284
|
],
|
|
285
285
|
"parts": [],
|
|
@@ -7871,7 +7871,13 @@
|
|
|
7871
7871
|
"methods": [],
|
|
7872
7872
|
"events": [],
|
|
7873
7873
|
"listeners": [],
|
|
7874
|
-
"styles": [
|
|
7874
|
+
"styles": [
|
|
7875
|
+
{
|
|
7876
|
+
"name": "--calcite-ui-icon-color",
|
|
7877
|
+
"annotation": "prop",
|
|
7878
|
+
"docs": "the color of the icon. Defaults to 'currentColor'."
|
|
7879
|
+
}
|
|
7880
|
+
],
|
|
7875
7881
|
"slots": [],
|
|
7876
7882
|
"parts": [],
|
|
7877
7883
|
"dependents": [
|
|
@@ -9951,7 +9957,7 @@
|
|
|
9951
9957
|
"mutable": true,
|
|
9952
9958
|
"attr": "value",
|
|
9953
9959
|
"reflectToAttr": false,
|
|
9954
|
-
"docs": "The selected time (always 24-hour format)",
|
|
9960
|
+
"docs": "The selected time in UTC (always 24-hour format)",
|
|
9955
9961
|
"docsTags": [],
|
|
9956
9962
|
"default": "null",
|
|
9957
9963
|
"values": [
|
|
@@ -12619,7 +12625,7 @@
|
|
|
12619
12625
|
"events": [
|
|
12620
12626
|
{
|
|
12621
12627
|
"event": "calciteListChange",
|
|
12622
|
-
"detail": "any",
|
|
12628
|
+
"detail": "Map<string, any>",
|
|
12623
12629
|
"bubbles": true,
|
|
12624
12630
|
"cancelable": true,
|
|
12625
12631
|
"composed": true,
|
|
@@ -18285,7 +18291,7 @@
|
|
|
18285
18291
|
"mutable": false,
|
|
18286
18292
|
"attr": "step",
|
|
18287
18293
|
"reflectToAttr": false,
|
|
18288
|
-
"docs": "number that specifies the granularity that the value must adhere to",
|
|
18294
|
+
"docs": "number (seconds) that specifies the granularity that the value must adhere to",
|
|
18289
18295
|
"docsTags": [],
|
|
18290
18296
|
"default": "60",
|
|
18291
18297
|
"values": [
|
|
@@ -18302,7 +18308,7 @@
|
|
|
18302
18308
|
"mutable": true,
|
|
18303
18309
|
"attr": "value",
|
|
18304
18310
|
"reflectToAttr": false,
|
|
18305
|
-
"docs": "The selected time in UTC",
|
|
18311
|
+
"docs": "The selected time in UTC (always 24-hour format)",
|
|
18306
18312
|
"docsTags": [],
|
|
18307
18313
|
"default": "null",
|
|
18308
18314
|
"values": [
|
|
@@ -19541,7 +19547,7 @@
|
|
|
19541
19547
|
"events": [
|
|
19542
19548
|
{
|
|
19543
19549
|
"event": "calciteListChange",
|
|
19544
|
-
"detail": "any",
|
|
19550
|
+
"detail": "Map<string, any>",
|
|
19545
19551
|
"bubbles": true,
|
|
19546
19552
|
"cancelable": true,
|
|
19547
19553
|
"composed": true,
|
|
@@ -19550,7 +19556,7 @@
|
|
|
19550
19556
|
},
|
|
19551
19557
|
{
|
|
19552
19558
|
"event": "calciteListOrderChange",
|
|
19553
|
-
"detail": "any",
|
|
19559
|
+
"detail": "any[]",
|
|
19554
19560
|
"bubbles": true,
|
|
19555
19561
|
"cancelable": true,
|
|
19556
19562
|
"composed": true,
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
export declare const CSS: {
|
|
2
|
+
checked: string;
|
|
3
|
+
description: string;
|
|
4
|
+
descriptionOnly: string;
|
|
5
|
+
disabled: string;
|
|
6
|
+
heading: string;
|
|
7
|
+
headingOnly: string;
|
|
8
|
+
icon: string;
|
|
9
|
+
iconOnly: string;
|
|
10
|
+
inputAlignmentEnd: string;
|
|
11
|
+
inputAlignmentStart: string;
|
|
12
|
+
inputEnabled: string;
|
|
13
|
+
largeVisual: string;
|
|
14
|
+
widthAuto: string;
|
|
15
|
+
widthFull: string;
|
|
16
|
+
};
|