@esri/calcite-components 1.0.0-next.294 → 1.0.0-next.298
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/checkExtent16.json +1 -0
- package/dist/calcite/assets/calcite-icon/checkExtent24.json +1 -0
- package/dist/calcite/assets/calcite-icon/checkExtent32.json +1 -0
- package/dist/calcite/assets/calcite-icon/driveTime16.json +1 -0
- package/dist/calcite/assets/calcite-icon/driveTime24.json +1 -0
- package/dist/calcite/assets/calcite-icon/driveTime32.json +1 -0
- package/dist/calcite/assets/calcite-icon/driveTimeLargest16.json +1 -0
- package/dist/calcite/assets/calcite-icon/driveTimeLargest24.json +1 -0
- package/dist/calcite/assets/calcite-icon/driveTimeLargest32.json +1 -0
- package/dist/calcite/assets/calcite-icon/driveTimeSmallest16.json +1 -0
- package/dist/calcite/assets/calcite-icon/driveTimeSmallest24.json +1 -0
- package/dist/calcite/assets/calcite-icon/driveTimeSmallest32.json +1 -0
- package/dist/calcite/assets/calcite-icon/driveTimeXBar16.json +1 -0
- package/dist/calcite/assets/calcite-icon/driveTimeXBar24.json +1 -0
- package/dist/calcite/assets/calcite-icon/driveTimeXBar32.json +1 -0
- package/dist/calcite/assets/calcite-icon/groupItems16.json +1 -0
- package/dist/calcite/assets/calcite-icon/groupItems24.json +1 -0
- package/dist/calcite/assets/calcite-icon/groupItems32.json +1 -0
- package/dist/calcite/assets/calcite-icon/groupLayoutElements16.json +1 -0
- package/dist/calcite/assets/calcite-icon/groupLayoutElements24.json +1 -0
- package/dist/calcite/assets/calcite-icon/groupLayoutElements32.json +1 -0
- package/dist/calcite/assets/calcite-icon/ringsLargest16.json +1 -0
- package/dist/calcite/assets/calcite-icon/ringsLargest24.json +1 -0
- package/dist/calcite/assets/calcite-icon/ringsLargest32.json +1 -0
- package/dist/calcite/assets/calcite-icon/ringsSmallest16.json +1 -0
- package/dist/calcite/assets/calcite-icon/ringsSmallest24.json +1 -0
- package/dist/calcite/assets/calcite-icon/ringsSmallest32.json +1 -0
- package/dist/calcite/assets/calcite-icon/ringsXBar16.json +1 -0
- package/dist/calcite/assets/calcite-icon/ringsXBar24.json +1 -0
- package/dist/calcite/assets/calcite-icon/ringsXBar32.json +1 -0
- package/dist/calcite/assets/calcite-icon/ungroupItems16.json +1 -0
- package/dist/calcite/assets/calcite-icon/ungroupItems24.json +1 -0
- package/dist/calcite/assets/calcite-icon/ungroupItems32.json +1 -0
- package/dist/calcite/assets/calcite-icon/ungroupLayoutElements16.json +1 -0
- package/dist/calcite/assets/calcite-icon/ungroupLayoutElements24.json +1 -0
- package/dist/calcite/assets/calcite-icon/ungroupLayoutElements32.json +1 -0
- package/dist/calcite/calcite.esm.js +1 -1
- package/dist/calcite/calcite.js +1 -1
- package/dist/calcite/{p-dc99bb00.system.entry.js → p-00716aa8.system.entry.js} +1 -1
- package/dist/calcite/{p-413b4857.system.entry.js → p-044d603d.system.entry.js} +1 -1
- package/dist/calcite/{p-6621aee1.entry.js → p-05da7439.entry.js} +1 -1
- package/dist/calcite/{p-7c37ca39.entry.js → p-08d707c4.entry.js} +1 -1
- package/dist/calcite/{p-fba65e4a.system.entry.js → p-10708f87.system.entry.js} +1 -1
- package/dist/calcite/p-109049e6.system.entry.js +5 -0
- package/dist/calcite/{p-58e98b2d.system.entry.js → p-127e3513.system.entry.js} +1 -1
- package/dist/calcite/p-1434e37e.entry.js +5 -0
- package/dist/calcite/{p-c8e4117c.system.entry.js → p-15f3a0d7.system.entry.js} +1 -1
- package/dist/calcite/{p-de3a04c2.system.entry.js → p-16bb48f6.system.entry.js} +1 -1
- package/dist/calcite/{p-c99d8f9e.system.entry.js → p-16f2d814.system.entry.js} +1 -1
- package/dist/calcite/p-1942876c.js +5 -0
- package/dist/calcite/{p-cca94491.system.entry.js → p-1a1e9057.system.entry.js} +1 -1
- package/dist/calcite/p-1a962bdd.js +5 -0
- package/dist/calcite/p-1aa89347.system.entry.js +5 -0
- package/dist/calcite/{p-a8569c55.system.entry.js → p-1c8fe17f.system.entry.js} +1 -1
- package/dist/calcite/{p-6988c6b7.system.entry.js → p-1dd440e6.system.entry.js} +1 -1
- package/dist/calcite/{p-7a6c6382.entry.js → p-21c8ac06.entry.js} +1 -1
- package/dist/calcite/{p-6c8a562f.system.entry.js → p-243d95ab.system.entry.js} +1 -1
- package/dist/calcite/{p-3f1d1bad.entry.js → p-2451da5b.entry.js} +1 -1
- package/dist/calcite/p-288bc438.system.js +5 -0
- package/dist/calcite/{p-4185db77.entry.js → p-289bc56f.entry.js} +1 -1
- package/dist/calcite/{p-9affee61.entry.js → p-29771742.entry.js} +1 -1
- package/dist/calcite/{p-8953f712.entry.js → p-2aa3007a.entry.js} +1 -1
- package/dist/calcite/p-2d09cc25.js +5 -0
- package/dist/calcite/p-2e29554c.js +5 -0
- package/dist/calcite/{p-3962cd38.entry.js → p-33802886.entry.js} +1 -1
- package/dist/calcite/{p-25a31861.system.js → p-34e5baa7.system.js} +1 -1
- package/dist/calcite/p-3a592bf3.system.entry.js +5 -0
- package/dist/calcite/p-3dae9da3.js +5 -0
- package/dist/calcite/{p-bf8b70a8.entry.js → p-3e6fcede.entry.js} +1 -1
- package/dist/calcite/p-3eb1dc0f.entry.js +5 -0
- package/dist/calcite/{p-c9ecea64.entry.js → p-48f03121.entry.js} +1 -1
- package/dist/calcite/{p-83302e1c.entry.js → p-4acfb654.entry.js} +1 -1
- package/dist/calcite/{p-bf25e278.system.entry.js → p-4d11efdb.system.entry.js} +1 -1
- package/dist/calcite/{p-b8d040e5.system.entry.js → p-4e16515a.system.entry.js} +1 -1
- package/dist/calcite/{p-c60e3a71.entry.js → p-4f1f83d2.entry.js} +1 -1
- package/dist/calcite/{p-1e875199.entry.js → p-502ea583.entry.js} +1 -1
- package/dist/calcite/p-523bc291.system.js +5 -0
- package/dist/calcite/p-54394dfe.system.entry.js +5 -0
- package/dist/calcite/p-578509a8.entry.js +5 -0
- package/dist/calcite/p-592da79d.system.entry.js +5 -0
- package/dist/calcite/p-5c0c29bc.entry.js +5 -0
- package/dist/calcite/p-5eee672a.system.entry.js +5 -0
- package/dist/calcite/{p-ba1322e6.system.entry.js → p-5f2a9710.system.entry.js} +1 -1
- package/dist/calcite/{p-36e5db45.entry.js → p-5f817b79.entry.js} +1 -1
- package/dist/calcite/{p-e638ff0e.entry.js → p-6296644b.entry.js} +1 -1
- package/dist/calcite/p-63e60894.entry.js +5 -0
- package/dist/calcite/{p-daa110fe.system.entry.js → p-6484ffb7.system.entry.js} +1 -1
- package/dist/calcite/{p-28261aae.entry.js → p-659898bf.entry.js} +1 -1
- package/dist/calcite/{p-d11ad046.system.js → p-6d44b7d9.system.js} +1 -1
- package/dist/calcite/p-6f1cca21.system.js +5 -0
- package/dist/calcite/{p-e7819705.entry.js → p-714ae4f6.entry.js} +1 -1
- package/dist/calcite/{p-3bb30b44.system.entry.js → p-74f390e1.system.entry.js} +1 -1
- package/dist/calcite/{p-d4059426.entry.js → p-75264173.entry.js} +1 -1
- package/dist/calcite/{p-76ccd204.entry.js → p-765fb8ed.entry.js} +1 -1
- package/dist/calcite/p-784e414b.entry.js +5 -0
- package/dist/calcite/{p-cacca548.entry.js → p-78d0db7b.entry.js} +1 -1
- package/dist/calcite/{p-98789055.system.entry.js → p-7ba971b5.system.entry.js} +1 -1
- package/dist/calcite/{p-f281f1e9.entry.js → p-7bb94bfa.entry.js} +1 -1
- package/dist/calcite/{p-502736d8.system.entry.js → p-81538774.system.entry.js} +1 -1
- package/dist/calcite/p-81ab443c.entry.js +5 -0
- package/dist/calcite/p-82139130.entry.js +5 -0
- package/dist/calcite/{p-7b869bc5.entry.js → p-82c6cd9a.entry.js} +1 -1
- package/dist/calcite/{p-45257edb.js → p-8340b572.js} +1 -1
- package/dist/calcite/{p-58716826.system.entry.js → p-840f2937.system.entry.js} +2 -2
- package/dist/calcite/p-85032edc.system.entry.js +5 -0
- package/dist/calcite/{p-b41deed0.system.entry.js → p-8b2ead09.system.entry.js} +1 -1
- package/dist/calcite/p-8baa9ba4.entry.js +5 -0
- package/dist/calcite/{p-7ade2294.system.entry.js → p-8fef13ca.system.entry.js} +1 -1
- package/dist/calcite/{p-75f714c9.entry.js → p-9338b0bc.entry.js} +1 -1
- package/dist/calcite/p-9577dfd9.entry.js +5 -0
- package/dist/calcite/{p-c48b4b7e.system.entry.js → p-95b9a0f2.system.entry.js} +1 -1
- package/dist/calcite/p-968ea270.entry.js +5 -0
- package/dist/calcite/p-99a1c131.entry.js +5 -0
- package/dist/calcite/{p-83ccefba.system.entry.js → p-9abbbcbd.system.entry.js} +1 -1
- package/dist/calcite/p-9be6633a.entry.js +5 -0
- package/dist/calcite/{p-9fc0dc2c.system.entry.js → p-9f240615.system.entry.js} +1 -1
- package/dist/calcite/{p-f6f4648e.system.entry.js → p-a5269f14.system.entry.js} +1 -1
- package/dist/calcite/{p-684ccd4e.system.entry.js → p-a8dc2982.system.entry.js} +1 -1
- package/dist/calcite/{p-0100aeb0.entry.js → p-ace12b8d.entry.js} +1 -1
- package/dist/calcite/{p-7dd5c4e4.entry.js → p-aced5f01.entry.js} +1 -1
- package/dist/calcite/{p-f32e61bb.system.entry.js → p-aec398f3.system.entry.js} +1 -1
- package/dist/calcite/{p-eed43a57.system.entry.js → p-b1351c3e.system.entry.js} +1 -1
- package/dist/calcite/p-b1a96c72.system.entry.js +5 -0
- package/dist/calcite/{p-8007a0b4.system.entry.js → p-b2bbac37.system.entry.js} +1 -1
- package/dist/calcite/{p-3cf93a58.system.entry.js → p-b4b1081f.system.entry.js} +1 -1
- package/dist/calcite/p-b94bf8ac.system.entry.js +5 -0
- package/dist/calcite/p-c0e35328.entry.js +5 -0
- package/dist/calcite/p-c34c4414.system.js +5 -0
- package/dist/calcite/{p-a09634e2.entry.js → p-c3ba61ea.entry.js} +1 -1
- package/dist/calcite/{p-fe16f05e.system.entry.js → p-c4cb4fab.system.entry.js} +1 -1
- package/dist/calcite/p-c87c04a9.entry.js +5 -0
- package/dist/calcite/p-ca3bb147.entry.js +5 -0
- package/dist/calcite/{p-527146c8.system.entry.js → p-cbe9f1a2.system.entry.js} +1 -1
- package/dist/calcite/{p-a7ba0292.system.js → p-cbf6bb04.system.js} +1 -1
- package/dist/calcite/p-cc2085c7.system.entry.js +5 -0
- package/dist/calcite/{p-507b2cc4.entry.js → p-cc788d2e.entry.js} +1 -1
- package/dist/calcite/p-cced5508.system.entry.js +5 -0
- package/dist/calcite/{p-dcf30b00.system.entry.js → p-cf03b144.system.entry.js} +1 -1
- package/dist/calcite/{p-b018fbbd.entry.js → p-d550ee4d.entry.js} +1 -1
- package/dist/calcite/{p-72fa390e.entry.js → p-d6e30c54.entry.js} +1 -1
- package/dist/calcite/{p-79cbbf2d.js → p-d6f20229.js} +1 -1
- package/dist/calcite/{p-3e438b5b.system.entry.js → p-dabb63b5.system.entry.js} +1 -1
- package/dist/calcite/{p-9fa024e6.system.entry.js → p-dd464e44.system.entry.js} +1 -1
- package/dist/calcite/{p-38ee7306.system.entry.js → p-deb36fde.system.entry.js} +1 -1
- package/dist/calcite/{p-b4e7b593.system.entry.js → p-defcee80.system.entry.js} +1 -1
- package/dist/calcite/{p-e35e7216.system.js → p-dff7dc90.system.js} +1 -1
- package/dist/calcite/{p-aad45edf.system.js → p-e095517f.system.js} +1 -1
- package/dist/calcite/{p-09da1c54.system.entry.js → p-e33fe285.system.entry.js} +1 -1
- package/dist/calcite/p-e52495d3.system.entry.js +5 -0
- package/dist/calcite/p-e5932886.system.entry.js +5 -0
- package/dist/calcite/{p-9fa5e356.entry.js → p-e5e3b591.entry.js} +1 -1
- package/dist/calcite/p-e62a9b1d.system.entry.js +5 -0
- package/dist/calcite/p-e6c84e63.entry.js +5 -0
- package/dist/calcite/{p-a5bfc29d.system.entry.js → p-e6d05ad6.system.entry.js} +1 -1
- package/dist/calcite/{p-49d5ee42.system.entry.js → p-e70cb594.system.entry.js} +1 -1
- package/dist/calcite/{p-809ddb6a.js → p-e956e279.js} +1 -1
- package/dist/calcite/{p-c399cfce.entry.js → p-eada9cef.entry.js} +1 -1
- package/dist/calcite/{p-b244a00c.entry.js → p-ecc00ef0.entry.js} +1 -1
- package/dist/calcite/p-ed15771f.system.entry.js +5 -0
- package/dist/calcite/p-ed453bfb.entry.js +5 -0
- package/dist/calcite/{p-f93a7fce.entry.js → p-ef39847e.entry.js} +1 -1
- package/dist/calcite/{p-cd41629f.entry.js → p-efb2169a.entry.js} +1 -1
- package/dist/calcite/{p-06646eed.system.entry.js → p-f0338acf.system.entry.js} +1 -1
- package/dist/calcite/{p-3383d9b4.entry.js → p-f1c5e7cf.entry.js} +1 -1
- package/dist/calcite/{p-58eca102.entry.js → p-f278dd53.entry.js} +1 -1
- package/dist/calcite/p-f44e01bf.entry.js +5 -0
- package/dist/calcite/{p-5efd7297.entry.js → p-f9c46578.entry.js} +1 -1
- package/dist/calcite/{p-10de63d7.system.entry.js → p-fc47547f.system.entry.js} +1 -1
- package/dist/calcite/p-fc643963.entry.js +5 -0
- package/dist/cjs/{CalciteExpandToggle-6a9f9858.js → CalciteExpandToggle-5f60c98b.js} +1 -1
- package/dist/cjs/{CalciteHeading-363b0525.js → CalciteHeading-112c19f9.js} +1 -1
- package/dist/cjs/calcite-accordion_2.cjs.entry.js +1 -1
- package/dist/cjs/calcite-action-bar.cjs.entry.js +2 -2
- package/dist/cjs/calcite-action-group.cjs.entry.js +1 -1
- package/dist/cjs/calcite-action-menu.cjs.entry.js +1 -1
- package/dist/cjs/calcite-action-pad.cjs.entry.js +2 -2
- package/dist/cjs/calcite-action.cjs.entry.js +1 -1
- package/dist/cjs/calcite-alert.cjs.entry.js +1 -1
- package/dist/cjs/calcite-avatar.cjs.entry.js +1 -1
- package/dist/cjs/calcite-block_2.cjs.entry.js +2 -2
- 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 +36 -85
- package/dist/cjs/calcite-chip.cjs.entry.js +1 -1
- package/dist/cjs/calcite-color-picker_3.cjs.entry.js +26 -27
- package/dist/cjs/calcite-combobox_3.cjs.entry.js +81 -22
- package/dist/cjs/calcite-date-picker_4.cjs.entry.js +28 -10
- package/dist/cjs/calcite-dropdown_3.cjs.entry.js +1 -1
- package/dist/cjs/calcite-fab.cjs.entry.js +1 -1
- package/dist/cjs/calcite-filter.cjs.entry.js +34 -8
- package/dist/cjs/calcite-flow.cjs.entry.js +1 -1
- package/dist/cjs/calcite-graph_2.cjs.entry.js +13 -5
- package/dist/cjs/calcite-handle.cjs.entry.js +1 -1
- package/dist/cjs/calcite-icon.cjs.entry.js +1 -1
- package/dist/cjs/calcite-inline-editable.cjs.entry.js +51 -42
- package/dist/cjs/calcite-input-date-picker.cjs.entry.js +68 -15
- package/dist/cjs/calcite-input-message.cjs.entry.js +1 -1
- package/dist/cjs/calcite-input-time-picker_2.cjs.entry.js +13 -4
- package/dist/cjs/calcite-input.cjs.entry.js +78 -58
- package/dist/cjs/calcite-label.cjs.entry.js +1 -1
- package/dist/cjs/calcite-link.cjs.entry.js +1 -1
- package/dist/cjs/calcite-list_3.cjs.entry.js +3 -3
- package/dist/cjs/calcite-loader.cjs.entry.js +1 -1
- package/dist/cjs/calcite-modal.cjs.entry.js +1 -1
- package/dist/cjs/calcite-notice.cjs.entry.js +1 -1
- package/dist/cjs/calcite-option_3.cjs.entry.js +31 -5
- package/dist/cjs/calcite-pagination.cjs.entry.js +1 -1
- package/dist/cjs/calcite-panel.cjs.entry.js +5 -4
- package/dist/cjs/calcite-pick-list_3.cjs.entry.js +3 -3
- package/dist/cjs/calcite-popover_2.cjs.entry.js +3 -3
- 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-group_2.cjs.entry.js +20 -24
- package/dist/cjs/calcite-radio_2.cjs.entry.js +81 -75
- package/dist/cjs/calcite-rating.cjs.entry.js +13 -4
- package/dist/cjs/calcite-scrim.cjs.entry.js +1 -1
- package/dist/cjs/calcite-shell_3.cjs.entry.js +5 -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 +1 -1
- package/dist/cjs/calcite-switch.cjs.entry.js +25 -49
- package/dist/cjs/calcite-tab_4.cjs.entry.js +1 -1
- package/dist/cjs/calcite-tile-select_2.cjs.entry.js +1 -3
- package/dist/cjs/calcite-tile.cjs.entry.js +1 -1
- package/dist/cjs/calcite-tip_3.cjs.entry.js +2 -2
- package/dist/cjs/calcite-tooltip_2.cjs.entry.js +1 -1
- package/dist/cjs/calcite-tree_2.cjs.entry.js +16 -9
- package/dist/cjs/calcite-value-list_2.cjs.entry.js +2 -2
- package/dist/cjs/calcite.cjs.js +2 -2
- package/dist/cjs/form-a5b44a1f.js +179 -0
- package/dist/cjs/{index-cee0daa9.js → index-6b5d2de5.js} +8 -365
- package/dist/cjs/{label-549c3d9d.js → label-8e3552b2.js} +33 -4
- package/dist/cjs/loader.cjs.js +2 -2
- package/dist/cjs/math-145c80e2.js +21 -0
- package/dist/cjs/{resources-38563593.js → resources-3f7b51c8.js} +1 -1
- package/dist/cjs/{resources-f9c141d2.js → resources-cd25dbae.js} +1 -1
- package/dist/collection/components/calcite-button/calcite-button.css +20 -14
- package/dist/collection/components/calcite-checkbox/calcite-checkbox.css +22 -11
- package/dist/collection/components/calcite-checkbox/calcite-checkbox.js +63 -112
- package/dist/collection/components/calcite-color-picker/calcite-color-picker.js +13 -10
- package/dist/collection/components/calcite-color-picker-hex-input/calcite-color-picker-hex-input.js +11 -15
- package/dist/collection/components/calcite-combobox/calcite-combobox.css +15 -0
- package/dist/collection/components/calcite-combobox/calcite-combobox.js +139 -19
- package/dist/collection/components/calcite-date-picker/calcite-date-picker.js +45 -15
- package/dist/collection/components/calcite-filter/calcite-filter.js +79 -8
- package/dist/collection/components/calcite-icon/assets/calcite-icon/checkExtent16.json +1 -0
- package/dist/collection/components/calcite-icon/assets/calcite-icon/checkExtent24.json +1 -0
- package/dist/collection/components/calcite-icon/assets/calcite-icon/checkExtent32.json +1 -0
- package/dist/collection/components/calcite-icon/assets/calcite-icon/driveTime16.json +1 -0
- package/dist/collection/components/calcite-icon/assets/calcite-icon/driveTime24.json +1 -0
- package/dist/collection/components/calcite-icon/assets/calcite-icon/driveTime32.json +1 -0
- package/dist/collection/components/calcite-icon/assets/calcite-icon/driveTimeLargest16.json +1 -0
- package/dist/collection/components/calcite-icon/assets/calcite-icon/driveTimeLargest24.json +1 -0
- package/dist/collection/components/calcite-icon/assets/calcite-icon/driveTimeLargest32.json +1 -0
- package/dist/collection/components/calcite-icon/assets/calcite-icon/driveTimeSmallest16.json +1 -0
- package/dist/collection/components/calcite-icon/assets/calcite-icon/driveTimeSmallest24.json +1 -0
- package/dist/collection/components/calcite-icon/assets/calcite-icon/driveTimeSmallest32.json +1 -0
- package/dist/collection/components/calcite-icon/assets/calcite-icon/driveTimeXBar16.json +1 -0
- package/dist/collection/components/calcite-icon/assets/calcite-icon/driveTimeXBar24.json +1 -0
- package/dist/collection/components/calcite-icon/assets/calcite-icon/driveTimeXBar32.json +1 -0
- package/dist/collection/components/calcite-icon/assets/calcite-icon/groupItems16.json +1 -0
- package/dist/collection/components/calcite-icon/assets/calcite-icon/groupItems24.json +1 -0
- package/dist/collection/components/calcite-icon/assets/calcite-icon/groupItems32.json +1 -0
- package/dist/collection/components/calcite-icon/assets/calcite-icon/groupLayoutElements16.json +1 -0
- package/dist/collection/components/calcite-icon/assets/calcite-icon/groupLayoutElements24.json +1 -0
- package/dist/collection/components/calcite-icon/assets/calcite-icon/groupLayoutElements32.json +1 -0
- package/dist/collection/components/calcite-icon/assets/calcite-icon/ringsLargest16.json +1 -0
- package/dist/collection/components/calcite-icon/assets/calcite-icon/ringsLargest24.json +1 -0
- package/dist/collection/components/calcite-icon/assets/calcite-icon/ringsLargest32.json +1 -0
- package/dist/collection/components/calcite-icon/assets/calcite-icon/ringsSmallest16.json +1 -0
- package/dist/collection/components/calcite-icon/assets/calcite-icon/ringsSmallest24.json +1 -0
- package/dist/collection/components/calcite-icon/assets/calcite-icon/ringsSmallest32.json +1 -0
- package/dist/collection/components/calcite-icon/assets/calcite-icon/ringsXBar16.json +1 -0
- package/dist/collection/components/calcite-icon/assets/calcite-icon/ringsXBar24.json +1 -0
- package/dist/collection/components/calcite-icon/assets/calcite-icon/ringsXBar32.json +1 -0
- package/dist/collection/components/calcite-icon/assets/calcite-icon/ungroupItems16.json +1 -0
- package/dist/collection/components/calcite-icon/assets/calcite-icon/ungroupItems24.json +1 -0
- package/dist/collection/components/calcite-icon/assets/calcite-icon/ungroupItems32.json +1 -0
- package/dist/collection/components/calcite-icon/assets/calcite-icon/ungroupLayoutElements16.json +1 -0
- package/dist/collection/components/calcite-icon/assets/calcite-icon/ungroupLayoutElements24.json +1 -0
- package/dist/collection/components/calcite-icon/assets/calcite-icon/ungroupLayoutElements32.json +1 -0
- package/dist/collection/components/calcite-inline-editable/calcite-inline-editable.css +8 -54
- package/dist/collection/components/calcite-inline-editable/calcite-inline-editable.js +43 -32
- package/dist/collection/components/calcite-inline-editable/resources.js +7 -7
- package/dist/collection/components/calcite-input/calcite-input.css +102 -68
- package/dist/collection/components/calcite-input/calcite-input.js +107 -56
- package/dist/collection/components/calcite-input/resources.js +14 -12
- package/dist/collection/components/calcite-input-date-picker/calcite-input-date-picker.css +15 -0
- package/dist/collection/components/calcite-input-date-picker/calcite-input-date-picker.js +163 -40
- package/dist/collection/components/calcite-input-time-picker/calcite-input-time-picker.css +15 -0
- package/dist/collection/components/calcite-input-time-picker/calcite-input-time-picker.js +34 -3
- package/dist/collection/components/calcite-list-item/calcite-list-item.css +7 -0
- package/dist/collection/components/calcite-panel/calcite-panel.css +10 -4
- package/dist/collection/components/calcite-panel/calcite-panel.js +3 -2
- package/dist/collection/components/calcite-panel/resources.js +1 -0
- package/dist/collection/components/calcite-popover/calcite-popover.css +1 -0
- package/dist/collection/components/calcite-radio-button/calcite-radio-button.css +18 -1
- package/dist/collection/components/calcite-radio-button/calcite-radio-button.js +83 -84
- package/dist/collection/components/calcite-radio-button/resources.js +1 -1
- package/dist/collection/components/calcite-radio-group/calcite-radio-group.css +15 -0
- package/dist/collection/components/calcite-radio-group/calcite-radio-group.js +58 -22
- package/dist/collection/components/calcite-rating/calcite-rating.css +15 -0
- package/dist/collection/components/calcite-rating/calcite-rating.js +49 -1
- package/dist/collection/components/calcite-select/calcite-select.css +15 -0
- package/dist/collection/components/calcite-select/calcite-select.js +89 -3
- package/dist/collection/components/calcite-shell/calcite-shell.css +11 -11
- package/dist/collection/components/calcite-shell-panel/calcite-shell-panel.css +38 -21
- package/dist/collection/components/calcite-shell-panel/calcite-shell-panel.js +2 -2
- package/dist/collection/components/calcite-shell-panel/resources.js +1 -0
- package/dist/collection/components/calcite-slider/calcite-slider.css +15 -0
- package/dist/collection/components/calcite-slider/calcite-slider.js +45 -1
- package/dist/collection/components/calcite-switch/calcite-switch.css +15 -0
- package/dist/collection/components/calcite-switch/calcite-switch.js +28 -64
- package/dist/collection/components/calcite-tile-select/calcite-tile-select.js +4 -7
- package/dist/collection/components/calcite-tree-item/calcite-tree-item.js +15 -8
- package/dist/collection/utils/form.js +167 -14
- package/dist/collection/utils/label.js +33 -4
- package/dist/collection/utils/math.js +11 -0
- package/dist/components/calcite-button2.js +1 -1
- package/dist/components/calcite-checkbox2.js +37 -87
- package/dist/components/calcite-color-picker-hex-input2.js +11 -15
- package/dist/components/calcite-color-picker.js +13 -10
- package/dist/components/calcite-combobox.js +82 -20
- package/dist/components/calcite-date-picker2.js +25 -7
- package/dist/components/calcite-filter2.js +35 -7
- package/dist/components/calcite-inline-editable.js +52 -42
- package/dist/components/calcite-input-date-picker.js +68 -12
- package/dist/components/calcite-input-time-picker.js +12 -2
- package/dist/components/calcite-input2.js +82 -59
- package/dist/components/calcite-list-item.js +1 -1
- package/dist/components/calcite-panel.js +3 -2
- package/dist/components/calcite-popover2.js +1 -1
- package/dist/components/calcite-radio-button.js +83 -76
- package/dist/components/calcite-radio-group.js +20 -22
- package/dist/components/calcite-rating.js +13 -2
- package/dist/components/calcite-select.js +32 -3
- package/dist/components/calcite-shell-panel.js +4 -3
- package/dist/components/calcite-shell.js +1 -1
- package/dist/components/calcite-slider.js +12 -2
- package/dist/components/calcite-switch2.js +25 -51
- package/dist/components/calcite-tile-select.js +1 -3
- package/dist/components/calcite-tree-item.js +15 -8
- package/dist/components/form.js +169 -15
- package/dist/components/label.js +33 -4
- package/dist/components/math.js +12 -1
- package/dist/custom-elements/index.js +801 -445
- package/dist/esm/{CalciteExpandToggle-235a6bfd.js → CalciteExpandToggle-677f2f8b.js} +1 -1
- package/dist/esm/{CalciteHeading-dea3bd05.js → CalciteHeading-1d6cd311.js} +1 -1
- package/dist/esm/calcite-accordion_2.entry.js +1 -1
- package/dist/esm/calcite-action-bar.entry.js +2 -2
- package/dist/esm/calcite-action-group.entry.js +1 -1
- package/dist/esm/calcite-action-menu.entry.js +1 -1
- package/dist/esm/calcite-action-pad.entry.js +2 -2
- package/dist/esm/calcite-action.entry.js +1 -1
- package/dist/esm/calcite-alert.entry.js +1 -1
- package/dist/esm/calcite-avatar.entry.js +1 -1
- package/dist/esm/calcite-block_2.entry.js +2 -2
- 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 +36 -85
- package/dist/esm/calcite-chip.entry.js +1 -1
- package/dist/esm/calcite-color-picker_3.entry.js +26 -27
- package/dist/esm/calcite-combobox_3.entry.js +81 -22
- package/dist/esm/calcite-date-picker_4.entry.js +28 -10
- package/dist/esm/calcite-dropdown_3.entry.js +1 -1
- package/dist/esm/calcite-fab.entry.js +1 -1
- package/dist/esm/calcite-filter.entry.js +34 -8
- package/dist/esm/calcite-flow.entry.js +1 -1
- package/dist/esm/calcite-graph_2.entry.js +13 -5
- package/dist/esm/calcite-handle.entry.js +1 -1
- package/dist/esm/calcite-icon.entry.js +1 -1
- package/dist/esm/calcite-inline-editable.entry.js +51 -42
- package/dist/esm/calcite-input-date-picker.entry.js +68 -15
- package/dist/esm/calcite-input-message.entry.js +1 -1
- package/dist/esm/calcite-input-time-picker_2.entry.js +13 -4
- package/dist/esm/calcite-input.entry.js +79 -59
- package/dist/esm/calcite-label.entry.js +1 -1
- package/dist/esm/calcite-link.entry.js +1 -1
- package/dist/esm/calcite-list_3.entry.js +3 -3
- package/dist/esm/calcite-loader.entry.js +1 -1
- package/dist/esm/calcite-modal.entry.js +1 -1
- package/dist/esm/calcite-notice.entry.js +1 -1
- package/dist/esm/calcite-option_3.entry.js +31 -5
- package/dist/esm/calcite-pagination.entry.js +1 -1
- package/dist/esm/calcite-panel.entry.js +5 -4
- package/dist/esm/calcite-pick-list_3.entry.js +3 -3
- package/dist/esm/calcite-popover_2.entry.js +3 -3
- 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-group_2.entry.js +20 -24
- package/dist/esm/calcite-radio_2.entry.js +82 -76
- package/dist/esm/calcite-rating.entry.js +13 -4
- package/dist/esm/calcite-scrim.entry.js +1 -1
- package/dist/esm/calcite-shell_3.entry.js +5 -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 +1 -1
- package/dist/esm/calcite-switch.entry.js +26 -50
- package/dist/esm/calcite-tab_4.entry.js +1 -1
- package/dist/esm/calcite-tile-select_2.entry.js +1 -3
- package/dist/esm/calcite-tile.entry.js +1 -1
- package/dist/esm/calcite-tip_3.entry.js +2 -2
- package/dist/esm/calcite-tooltip_2.entry.js +1 -1
- package/dist/esm/calcite-tree_2.entry.js +16 -9
- package/dist/esm/calcite-value-list_2.entry.js +2 -2
- package/dist/esm/calcite.js +2 -2
- package/dist/esm/form-160b0fb5.js +174 -0
- package/dist/esm/{index-66803519.js → index-9de00868.js} +8 -365
- package/dist/esm/{label-bb61bdef.js → label-5559055d.js} +33 -4
- package/dist/esm/loader.js +2 -2
- package/dist/esm/math-456207f5.js +18 -0
- package/dist/esm/{resources-8dd80c84.js → resources-16a2a25a.js} +1 -1
- package/dist/esm/{resources-c59a1a15.js → resources-bece7a88.js} +1 -1
- package/dist/esm-es5/{CalciteExpandToggle-235a6bfd.js → CalciteExpandToggle-677f2f8b.js} +1 -1
- package/dist/esm-es5/{CalciteHeading-dea3bd05.js → CalciteHeading-1d6cd311.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 +1 -1
- package/dist/esm-es5/calcite-color-picker_3.entry.js +1 -1
- package/dist/esm-es5/calcite-combobox_3.entry.js +1 -1
- package/dist/esm-es5/calcite-date-picker_4.entry.js +1 -1
- package/dist/esm-es5/calcite-dropdown_3.entry.js +1 -1
- package/dist/esm-es5/calcite-fab.entry.js +1 -1
- package/dist/esm-es5/calcite-filter.entry.js +2 -2
- package/dist/esm-es5/calcite-flow.entry.js +1 -1
- package/dist/esm-es5/calcite-graph_2.entry.js +1 -1
- package/dist/esm-es5/calcite-handle.entry.js +1 -1
- package/dist/esm-es5/calcite-icon.entry.js +1 -1
- package/dist/esm-es5/calcite-inline-editable.entry.js +2 -2
- package/dist/esm-es5/calcite-input-date-picker.entry.js +2 -2
- 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 +2 -2
- 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 +1 -1
- package/dist/esm-es5/calcite-notice.entry.js +1 -1
- package/dist/esm-es5/calcite-option_3.entry.js +2 -2
- 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 +1 -1
- 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-group_2.entry.js +1 -1
- package/dist/esm-es5/calcite-radio_2.entry.js +2 -2
- package/dist/esm-es5/calcite-rating.entry.js +1 -1
- 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 +1 -1
- 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 +1 -1
- package/dist/esm-es5/calcite-tile.entry.js +1 -1
- package/dist/esm-es5/calcite-tip_3.entry.js +1 -1
- package/dist/esm-es5/calcite-tooltip_2.entry.js +1 -1
- package/dist/esm-es5/calcite-tree_2.entry.js +1 -1
- package/dist/esm-es5/calcite-value-list_2.entry.js +1 -1
- package/dist/esm-es5/calcite.js +1 -1
- package/dist/esm-es5/form-160b0fb5.js +5 -0
- package/dist/esm-es5/index-9de00868.js +5 -0
- package/dist/esm-es5/label-5559055d.js +5 -0
- package/dist/esm-es5/loader.js +1 -1
- package/dist/esm-es5/math-456207f5.js +5 -0
- package/dist/esm-es5/{resources-8dd80c84.js → resources-16a2a25a.js} +1 -1
- package/dist/esm-es5/{resources-c59a1a15.js → resources-bece7a88.js} +1 -1
- package/dist/extras/docs-json.json +320 -59
- package/dist/types/components/calcite-checkbox/calcite-checkbox.d.ts +22 -23
- package/dist/types/components/calcite-color-picker/calcite-color-picker.d.ts +1 -1
- package/dist/types/components/calcite-combobox/calcite-combobox.d.ts +21 -3
- package/dist/types/components/calcite-date-picker/calcite-date-picker.d.ts +20 -8
- package/dist/types/components/calcite-filter/calcite-filter.d.ts +19 -0
- package/dist/types/components/calcite-inline-editable/calcite-inline-editable.d.ts +5 -6
- package/dist/types/components/calcite-input/calcite-input.d.ts +14 -8
- package/dist/types/components/calcite-input/resources.d.ts +2 -0
- package/dist/types/components/calcite-input-date-picker/calcite-input-date-picker.d.ts +37 -8
- package/dist/types/components/calcite-input-time-picker/calcite-input-time-picker.d.ts +11 -2
- package/dist/types/components/calcite-panel/resources.d.ts +1 -0
- package/dist/types/components/calcite-radio-button/calcite-radio-button.d.ts +14 -15
- package/dist/types/components/calcite-radio-group/calcite-radio-group.d.ts +13 -4
- package/dist/types/components/calcite-rating/calcite-rating.d.ts +12 -1
- package/dist/types/components/calcite-select/calcite-select.d.ts +19 -1
- package/dist/types/components/calcite-shell-panel/resources.d.ts +1 -0
- package/dist/types/components/calcite-slider/calcite-slider.d.ts +10 -1
- package/dist/types/components/calcite-switch/calcite-switch.d.ts +10 -9
- package/dist/types/components/calcite-tile-select/calcite-tile-select.d.ts +1 -1
- package/dist/types/components/calcite-tree-item/calcite-tree-item.d.ts +2 -0
- package/dist/types/components.d.ts +171 -18
- package/dist/types/utils/form.d.ts +112 -1
- package/dist/types/utils/label.d.ts +5 -0
- package/dist/types/utils/math.d.ts +1 -0
- package/hydrate/index.js +827 -455
- package/package.json +8 -9
- package/readme.md +2 -2
- package/CHANGELOG.md +0 -1506
- package/dist/calcite/p-05107123.entry.js +0 -5
- package/dist/calcite/p-05d1dfc6.js +0 -5
- package/dist/calcite/p-0d4e82ab.system.entry.js +0 -5
- package/dist/calcite/p-10759c71.system.entry.js +0 -5
- package/dist/calcite/p-11113310.entry.js +0 -5
- package/dist/calcite/p-12e1c83f.system.entry.js +0 -5
- package/dist/calcite/p-1421e818.entry.js +0 -5
- package/dist/calcite/p-157d05ce.js +0 -5
- package/dist/calcite/p-17e666d6.system.entry.js +0 -5
- package/dist/calcite/p-22ecf6df.entry.js +0 -5
- package/dist/calcite/p-2418cceb.entry.js +0 -5
- package/dist/calcite/p-2ba00b89.js +0 -5
- package/dist/calcite/p-2ecafa35.system.entry.js +0 -5
- package/dist/calcite/p-329e1831.system.entry.js +0 -5
- package/dist/calcite/p-3994ac99.system.entry.js +0 -5
- package/dist/calcite/p-42128a12.entry.js +0 -5
- package/dist/calcite/p-47313747.system.js +0 -5
- package/dist/calcite/p-4c7e3915.system.entry.js +0 -5
- package/dist/calcite/p-4ecd0331.entry.js +0 -5
- package/dist/calcite/p-5322b333.system.entry.js +0 -5
- package/dist/calcite/p-5e6d76dc.entry.js +0 -5
- package/dist/calcite/p-777c833f.system.entry.js +0 -5
- package/dist/calcite/p-8711a0ae.system.entry.js +0 -5
- package/dist/calcite/p-89cdfa96.system.js +0 -5
- package/dist/calcite/p-8bc3e126.entry.js +0 -5
- package/dist/calcite/p-948aca0d.system.entry.js +0 -5
- package/dist/calcite/p-99ff3a2f.entry.js +0 -5
- package/dist/calcite/p-9fe349b9.entry.js +0 -5
- package/dist/calcite/p-a2cc027e.entry.js +0 -5
- package/dist/calcite/p-b42d730f.entry.js +0 -5
- package/dist/calcite/p-b4960d06.system.js +0 -5
- package/dist/calcite/p-bbe2337b.system.entry.js +0 -5
- package/dist/calcite/p-bbedf98c.entry.js +0 -5
- package/dist/calcite/p-be52c734.entry.js +0 -5
- package/dist/calcite/p-cb7b6425.entry.js +0 -5
- package/dist/calcite/p-d35e423d.js +0 -5
- package/dist/calcite/p-df9b4b76.entry.js +0 -5
- package/dist/calcite/p-e24b6c4a.system.entry.js +0 -5
- package/dist/calcite/p-e382c4e9.entry.js +0 -5
- package/dist/calcite/p-e40dd6fe.system.entry.js +0 -5
- package/dist/calcite/p-e5805bf1.entry.js +0 -5
- package/dist/calcite/p-eccb140e.entry.js +0 -5
- package/dist/calcite/p-f5bb39bb.js +0 -5
- package/dist/calcite/p-fb1da0f5.system.js +0 -5
- package/dist/cjs/form-00fb301c.js +0 -22
- package/dist/cjs/math-9d44163f.js +0 -9
- package/dist/esm/form-cee9f632.js +0 -20
- package/dist/esm/math-250d4476.js +0 -7
- package/dist/esm-es5/form-cee9f632.js +0 -5
- package/dist/esm-es5/index-66803519.js +0 -5
- package/dist/esm-es5/label-bb61bdef.js +0 -5
- package/dist/esm-es5/math-250d4476.js +0 -5
|
@@ -5,11 +5,7 @@
|
|
|
5
5
|
const NAMESPACE = 'calcite';
|
|
6
6
|
|
|
7
7
|
let scopeId;
|
|
8
|
-
let contentRef;
|
|
9
8
|
let hostTagName;
|
|
10
|
-
let useNativeShadowDom = false;
|
|
11
|
-
let checkSlotFallbackVisibility = false;
|
|
12
|
-
let checkSlotRelocate = false;
|
|
13
9
|
let isSvgMode = false;
|
|
14
10
|
let queuePending = false;
|
|
15
11
|
const win = typeof window !== 'undefined' ? window : {};
|
|
@@ -161,9 +157,6 @@ const attachStyles = (hostRef) => {
|
|
|
161
157
|
// DOM WRITE!!
|
|
162
158
|
elm['s-sc'] = scopeId;
|
|
163
159
|
elm.classList.add(scopeId + '-h');
|
|
164
|
-
if (flags & 2 /* scopedCssEncapsulation */) {
|
|
165
|
-
elm.classList.add(scopeId + '-s');
|
|
166
|
-
}
|
|
167
160
|
}
|
|
168
161
|
endAttachStyles();
|
|
169
162
|
};
|
|
@@ -202,7 +195,6 @@ const isComplexType = (o) => {
|
|
|
202
195
|
const h = (nodeName, vnodeData, ...children) => {
|
|
203
196
|
let child = null;
|
|
204
197
|
let key = null;
|
|
205
|
-
let slotName = null;
|
|
206
198
|
let simple = false;
|
|
207
199
|
let lastSimple = false;
|
|
208
200
|
let vNodeChildren = [];
|
|
@@ -234,9 +226,6 @@ const h = (nodeName, vnodeData, ...children) => {
|
|
|
234
226
|
if (vnodeData.key) {
|
|
235
227
|
key = vnodeData.key;
|
|
236
228
|
}
|
|
237
|
-
if (vnodeData.name) {
|
|
238
|
-
slotName = vnodeData.name;
|
|
239
|
-
}
|
|
240
229
|
{
|
|
241
230
|
const classData = vnodeData.className || vnodeData.class;
|
|
242
231
|
if (classData) {
|
|
@@ -261,9 +250,6 @@ const h = (nodeName, vnodeData, ...children) => {
|
|
|
261
250
|
{
|
|
262
251
|
vnode.$key$ = key;
|
|
263
252
|
}
|
|
264
|
-
{
|
|
265
|
-
vnode.$name$ = slotName;
|
|
266
|
-
}
|
|
267
253
|
return vnode;
|
|
268
254
|
};
|
|
269
255
|
const newVNode = (tag, text) => {
|
|
@@ -280,9 +266,6 @@ const newVNode = (tag, text) => {
|
|
|
280
266
|
{
|
|
281
267
|
vnode.$key$ = null;
|
|
282
268
|
}
|
|
283
|
-
{
|
|
284
|
-
vnode.$name$ = null;
|
|
285
|
-
}
|
|
286
269
|
return vnode;
|
|
287
270
|
};
|
|
288
271
|
const Host = {};
|
|
@@ -495,39 +478,16 @@ const createElm = (oldParentVNode, newParentVNode, childIndex, parentElm) => {
|
|
|
495
478
|
let i = 0;
|
|
496
479
|
let elm;
|
|
497
480
|
let childNode;
|
|
498
|
-
let oldVNode;
|
|
499
|
-
if (!useNativeShadowDom) {
|
|
500
|
-
// remember for later we need to check to relocate nodes
|
|
501
|
-
checkSlotRelocate = true;
|
|
502
|
-
if (newVNode.$tag$ === 'slot') {
|
|
503
|
-
if (scopeId) {
|
|
504
|
-
// scoped css needs to add its scoped id to the parent element
|
|
505
|
-
parentElm.classList.add(scopeId + '-s');
|
|
506
|
-
}
|
|
507
|
-
newVNode.$flags$ |= newVNode.$children$
|
|
508
|
-
? // slot element has fallback content
|
|
509
|
-
2 /* isSlotFallback */
|
|
510
|
-
: // slot element does not have fallback content
|
|
511
|
-
1 /* isSlotReference */;
|
|
512
|
-
}
|
|
513
|
-
}
|
|
514
481
|
if (newVNode.$text$ !== null) {
|
|
515
482
|
// create text node
|
|
516
483
|
elm = newVNode.$elm$ = doc.createTextNode(newVNode.$text$);
|
|
517
484
|
}
|
|
518
|
-
else if (newVNode.$flags$ & 1 /* isSlotReference */) {
|
|
519
|
-
// create a slot reference node
|
|
520
|
-
elm = newVNode.$elm$ =
|
|
521
|
-
doc.createTextNode('');
|
|
522
|
-
}
|
|
523
485
|
else {
|
|
524
486
|
if (!isSvgMode) {
|
|
525
487
|
isSvgMode = newVNode.$tag$ === 'svg';
|
|
526
488
|
}
|
|
527
489
|
// create element
|
|
528
|
-
elm = newVNode.$elm$ = (doc.createElementNS(isSvgMode ? SVG_NS : HTML_NS, newVNode.$
|
|
529
|
-
? 'slot-fb'
|
|
530
|
-
: newVNode.$tag$)
|
|
490
|
+
elm = newVNode.$elm$ = (doc.createElementNS(isSvgMode ? SVG_NS : HTML_NS, newVNode.$tag$)
|
|
531
491
|
);
|
|
532
492
|
if (isSvgMode && newVNode.$tag$ === 'foreignObject') {
|
|
533
493
|
isSvgMode = false;
|
|
@@ -544,7 +504,7 @@ const createElm = (oldParentVNode, newParentVNode, childIndex, parentElm) => {
|
|
|
544
504
|
if (newVNode.$children$) {
|
|
545
505
|
for (i = 0; i < newVNode.$children$.length; ++i) {
|
|
546
506
|
// create the node
|
|
547
|
-
childNode = createElm(oldParentVNode, newVNode, i
|
|
507
|
+
childNode = createElm(oldParentVNode, newVNode, i);
|
|
548
508
|
// return node could have been null
|
|
549
509
|
if (childNode) {
|
|
550
510
|
// append our new node
|
|
@@ -563,62 +523,20 @@ const createElm = (oldParentVNode, newParentVNode, childIndex, parentElm) => {
|
|
|
563
523
|
}
|
|
564
524
|
}
|
|
565
525
|
}
|
|
566
|
-
{
|
|
567
|
-
elm['s-hn'] = hostTagName;
|
|
568
|
-
if (newVNode.$flags$ & (2 /* isSlotFallback */ | 1 /* isSlotReference */)) {
|
|
569
|
-
// remember the content reference comment
|
|
570
|
-
elm['s-sr'] = true;
|
|
571
|
-
// remember the content reference comment
|
|
572
|
-
elm['s-cr'] = contentRef;
|
|
573
|
-
// remember the slot name, or empty string for default slot
|
|
574
|
-
elm['s-sn'] = newVNode.$name$ || '';
|
|
575
|
-
// check if we've got an old vnode for this slot
|
|
576
|
-
oldVNode = oldParentVNode && oldParentVNode.$children$ && oldParentVNode.$children$[childIndex];
|
|
577
|
-
if (oldVNode && oldVNode.$tag$ === newVNode.$tag$ && oldParentVNode.$elm$) {
|
|
578
|
-
// we've got an old slot vnode and the wrapper is being replaced
|
|
579
|
-
// so let's move the old slot content back to it's original location
|
|
580
|
-
putBackInOriginalLocation(oldParentVNode.$elm$, false);
|
|
581
|
-
}
|
|
582
|
-
}
|
|
583
|
-
}
|
|
584
526
|
return elm;
|
|
585
527
|
};
|
|
586
|
-
const putBackInOriginalLocation = (parentElm, recursive) => {
|
|
587
|
-
plt.$flags$ |= 1 /* isTmpDisconnected */;
|
|
588
|
-
const oldSlotChildNodes = parentElm.childNodes;
|
|
589
|
-
for (let i = oldSlotChildNodes.length - 1; i >= 0; i--) {
|
|
590
|
-
const childNode = oldSlotChildNodes[i];
|
|
591
|
-
if (childNode['s-hn'] !== hostTagName && childNode['s-ol']) {
|
|
592
|
-
// // this child node in the old element is from another component
|
|
593
|
-
// // remove this node from the old slot's parent
|
|
594
|
-
// childNode.remove();
|
|
595
|
-
// and relocate it back to it's original location
|
|
596
|
-
parentReferenceNode(childNode).insertBefore(childNode, referenceNode(childNode));
|
|
597
|
-
// remove the old original location comment entirely
|
|
598
|
-
// later on the patch function will know what to do
|
|
599
|
-
// and move this to the correct spot in need be
|
|
600
|
-
childNode['s-ol'].remove();
|
|
601
|
-
childNode['s-ol'] = undefined;
|
|
602
|
-
checkSlotRelocate = true;
|
|
603
|
-
}
|
|
604
|
-
if (recursive) {
|
|
605
|
-
putBackInOriginalLocation(childNode, recursive);
|
|
606
|
-
}
|
|
607
|
-
}
|
|
608
|
-
plt.$flags$ &= ~1 /* isTmpDisconnected */;
|
|
609
|
-
};
|
|
610
528
|
const addVnodes = (parentElm, before, parentVNode, vnodes, startIdx, endIdx) => {
|
|
611
|
-
let containerElm = (
|
|
529
|
+
let containerElm = (parentElm);
|
|
612
530
|
let childNode;
|
|
613
531
|
if (containerElm.shadowRoot && containerElm.tagName === hostTagName) {
|
|
614
532
|
containerElm = containerElm.shadowRoot;
|
|
615
533
|
}
|
|
616
534
|
for (; startIdx <= endIdx; ++startIdx) {
|
|
617
535
|
if (vnodes[startIdx]) {
|
|
618
|
-
childNode = createElm(null, parentVNode, startIdx
|
|
536
|
+
childNode = createElm(null, parentVNode, startIdx);
|
|
619
537
|
if (childNode) {
|
|
620
538
|
vnodes[startIdx].$elm$ = childNode;
|
|
621
|
-
containerElm.insertBefore(childNode,
|
|
539
|
+
containerElm.insertBefore(childNode, before);
|
|
622
540
|
}
|
|
623
541
|
}
|
|
624
542
|
}
|
|
@@ -628,20 +546,6 @@ const removeVnodes = (vnodes, startIdx, endIdx, vnode, elm) => {
|
|
|
628
546
|
if ((vnode = vnodes[startIdx])) {
|
|
629
547
|
elm = vnode.$elm$;
|
|
630
548
|
callNodeRefs(vnode);
|
|
631
|
-
{
|
|
632
|
-
// we're removing this element
|
|
633
|
-
// so it's possible we need to show slot fallback content now
|
|
634
|
-
checkSlotFallbackVisibility = true;
|
|
635
|
-
if (elm['s-ol']) {
|
|
636
|
-
// remove the original location comment
|
|
637
|
-
elm['s-ol'].remove();
|
|
638
|
-
}
|
|
639
|
-
else {
|
|
640
|
-
// it's possible that child nodes of the node
|
|
641
|
-
// that's being removed are slot nodes
|
|
642
|
-
putBackInOriginalLocation(elm, true);
|
|
643
|
-
}
|
|
644
|
-
}
|
|
645
549
|
// remove the vnode's element from the dom
|
|
646
550
|
elm.remove();
|
|
647
551
|
}
|
|
@@ -685,20 +589,12 @@ const updateChildren = (parentElm, oldCh, newVNode, newCh) => {
|
|
|
685
589
|
newEndVnode = newCh[--newEndIdx];
|
|
686
590
|
}
|
|
687
591
|
else if (isSameVnode(oldStartVnode, newEndVnode)) {
|
|
688
|
-
// Vnode moved right
|
|
689
|
-
if ((oldStartVnode.$tag$ === 'slot' || newEndVnode.$tag$ === 'slot')) {
|
|
690
|
-
putBackInOriginalLocation(oldStartVnode.$elm$.parentNode, false);
|
|
691
|
-
}
|
|
692
592
|
patch(oldStartVnode, newEndVnode);
|
|
693
593
|
parentElm.insertBefore(oldStartVnode.$elm$, oldEndVnode.$elm$.nextSibling);
|
|
694
594
|
oldStartVnode = oldCh[++oldStartIdx];
|
|
695
595
|
newEndVnode = newCh[--newEndIdx];
|
|
696
596
|
}
|
|
697
597
|
else if (isSameVnode(oldEndVnode, newStartVnode)) {
|
|
698
|
-
// Vnode moved left
|
|
699
|
-
if ((oldStartVnode.$tag$ === 'slot' || newEndVnode.$tag$ === 'slot')) {
|
|
700
|
-
putBackInOriginalLocation(oldEndVnode.$elm$.parentNode, false);
|
|
701
|
-
}
|
|
702
598
|
patch(oldEndVnode, newStartVnode);
|
|
703
599
|
parentElm.insertBefore(oldEndVnode.$elm$, oldStartVnode.$elm$);
|
|
704
600
|
oldEndVnode = oldCh[--oldEndIdx];
|
|
@@ -718,7 +614,7 @@ const updateChildren = (parentElm, oldCh, newVNode, newCh) => {
|
|
|
718
614
|
if (idxInOld >= 0) {
|
|
719
615
|
elmToMove = oldCh[idxInOld];
|
|
720
616
|
if (elmToMove.$tag$ !== newStartVnode.$tag$) {
|
|
721
|
-
node = createElm(oldCh && oldCh[newStartIdx], newVNode, idxInOld
|
|
617
|
+
node = createElm(oldCh && oldCh[newStartIdx], newVNode, idxInOld);
|
|
722
618
|
}
|
|
723
619
|
else {
|
|
724
620
|
patch(elmToMove, newStartVnode);
|
|
@@ -729,12 +625,12 @@ const updateChildren = (parentElm, oldCh, newVNode, newCh) => {
|
|
|
729
625
|
}
|
|
730
626
|
else {
|
|
731
627
|
// new element
|
|
732
|
-
node = createElm(oldCh && oldCh[newStartIdx], newVNode, newStartIdx
|
|
628
|
+
node = createElm(oldCh && oldCh[newStartIdx], newVNode, newStartIdx);
|
|
733
629
|
newStartVnode = newCh[++newStartIdx];
|
|
734
630
|
}
|
|
735
631
|
if (node) {
|
|
736
632
|
{
|
|
737
|
-
|
|
633
|
+
oldStartVnode.$elm$.parentNode.insertBefore(node, oldStartVnode.$elm$);
|
|
738
634
|
}
|
|
739
635
|
}
|
|
740
636
|
}
|
|
@@ -750,30 +646,18 @@ const isSameVnode = (vnode1, vnode2) => {
|
|
|
750
646
|
// compare if two vnode to see if they're "technically" the same
|
|
751
647
|
// need to have the same element tag, and same key to be the same
|
|
752
648
|
if (vnode1.$tag$ === vnode2.$tag$) {
|
|
753
|
-
if (vnode1.$tag$ === 'slot') {
|
|
754
|
-
return vnode1.$name$ === vnode2.$name$;
|
|
755
|
-
}
|
|
756
649
|
{
|
|
757
650
|
return vnode1.$key$ === vnode2.$key$;
|
|
758
651
|
}
|
|
759
652
|
}
|
|
760
653
|
return false;
|
|
761
654
|
};
|
|
762
|
-
const referenceNode = (node) => {
|
|
763
|
-
// this node was relocated to a new location in the dom
|
|
764
|
-
// because of some other component's slot
|
|
765
|
-
// but we still have an html comment in place of where
|
|
766
|
-
// it's original location was according to it's original vdom
|
|
767
|
-
return (node && node['s-ol']) || node;
|
|
768
|
-
};
|
|
769
|
-
const parentReferenceNode = (node) => (node['s-ol'] ? node['s-ol'] : node).parentNode;
|
|
770
655
|
const patch = (oldVNode, newVNode) => {
|
|
771
656
|
const elm = (newVNode.$elm$ = oldVNode.$elm$);
|
|
772
657
|
const oldChildren = oldVNode.$children$;
|
|
773
658
|
const newChildren = newVNode.$children$;
|
|
774
659
|
const tag = newVNode.$tag$;
|
|
775
660
|
const text = newVNode.$text$;
|
|
776
|
-
let defaultHolder;
|
|
777
661
|
if (text === null) {
|
|
778
662
|
{
|
|
779
663
|
// test if we're rendering an svg element, or still rendering nodes inside of one
|
|
@@ -812,147 +696,12 @@ const patch = (oldVNode, newVNode) => {
|
|
|
812
696
|
isSvgMode = false;
|
|
813
697
|
}
|
|
814
698
|
}
|
|
815
|
-
else if ((defaultHolder = elm['s-cr'])) {
|
|
816
|
-
// this element has slotted content
|
|
817
|
-
defaultHolder.parentNode.textContent = text;
|
|
818
|
-
}
|
|
819
699
|
else if (oldVNode.$text$ !== text) {
|
|
820
700
|
// update the text content for the text only vnode
|
|
821
701
|
// and also only if the text is different than before
|
|
822
702
|
elm.data = text;
|
|
823
703
|
}
|
|
824
704
|
};
|
|
825
|
-
const updateFallbackSlotVisibility = (elm) => {
|
|
826
|
-
// tslint:disable-next-line: prefer-const
|
|
827
|
-
let childNodes = elm.childNodes;
|
|
828
|
-
let childNode;
|
|
829
|
-
let i;
|
|
830
|
-
let ilen;
|
|
831
|
-
let j;
|
|
832
|
-
let slotNameAttr;
|
|
833
|
-
let nodeType;
|
|
834
|
-
for (i = 0, ilen = childNodes.length; i < ilen; i++) {
|
|
835
|
-
childNode = childNodes[i];
|
|
836
|
-
if (childNode.nodeType === 1 /* ElementNode */) {
|
|
837
|
-
if (childNode['s-sr']) {
|
|
838
|
-
// this is a slot fallback node
|
|
839
|
-
// get the slot name for this slot reference node
|
|
840
|
-
slotNameAttr = childNode['s-sn'];
|
|
841
|
-
// by default always show a fallback slot node
|
|
842
|
-
// then hide it if there are other slots in the light dom
|
|
843
|
-
childNode.hidden = false;
|
|
844
|
-
for (j = 0; j < ilen; j++) {
|
|
845
|
-
nodeType = childNodes[j].nodeType;
|
|
846
|
-
if (childNodes[j]['s-hn'] !== childNode['s-hn'] || slotNameAttr !== '') {
|
|
847
|
-
// this sibling node is from a different component OR is a named fallback slot node
|
|
848
|
-
if (nodeType === 1 /* ElementNode */ && slotNameAttr === childNodes[j].getAttribute('slot')) {
|
|
849
|
-
childNode.hidden = true;
|
|
850
|
-
break;
|
|
851
|
-
}
|
|
852
|
-
}
|
|
853
|
-
else {
|
|
854
|
-
// this is a default fallback slot node
|
|
855
|
-
// any element or text node (with content)
|
|
856
|
-
// should hide the default fallback slot node
|
|
857
|
-
if (nodeType === 1 /* ElementNode */ ||
|
|
858
|
-
(nodeType === 3 /* TextNode */ && childNodes[j].textContent.trim() !== '')) {
|
|
859
|
-
childNode.hidden = true;
|
|
860
|
-
break;
|
|
861
|
-
}
|
|
862
|
-
}
|
|
863
|
-
}
|
|
864
|
-
}
|
|
865
|
-
// keep drilling down
|
|
866
|
-
updateFallbackSlotVisibility(childNode);
|
|
867
|
-
}
|
|
868
|
-
}
|
|
869
|
-
};
|
|
870
|
-
const relocateNodes = [];
|
|
871
|
-
const relocateSlotContent = (elm) => {
|
|
872
|
-
// tslint:disable-next-line: prefer-const
|
|
873
|
-
let childNode;
|
|
874
|
-
let node;
|
|
875
|
-
let hostContentNodes;
|
|
876
|
-
let slotNameAttr;
|
|
877
|
-
let relocateNodeData;
|
|
878
|
-
let j;
|
|
879
|
-
let i = 0;
|
|
880
|
-
let childNodes = elm.childNodes;
|
|
881
|
-
let ilen = childNodes.length;
|
|
882
|
-
for (; i < ilen; i++) {
|
|
883
|
-
childNode = childNodes[i];
|
|
884
|
-
if (childNode['s-sr'] && (node = childNode['s-cr']) && node.parentNode) {
|
|
885
|
-
// first got the content reference comment node
|
|
886
|
-
// then we got it's parent, which is where all the host content is in now
|
|
887
|
-
hostContentNodes = node.parentNode.childNodes;
|
|
888
|
-
slotNameAttr = childNode['s-sn'];
|
|
889
|
-
for (j = hostContentNodes.length - 1; j >= 0; j--) {
|
|
890
|
-
node = hostContentNodes[j];
|
|
891
|
-
if (!node['s-cn'] && !node['s-nr'] && node['s-hn'] !== childNode['s-hn']) {
|
|
892
|
-
// let's do some relocating to its new home
|
|
893
|
-
// but never relocate a content reference node
|
|
894
|
-
// that is suppose to always represent the original content location
|
|
895
|
-
if (isNodeLocatedInSlot(node, slotNameAttr)) {
|
|
896
|
-
// it's possible we've already decided to relocate this node
|
|
897
|
-
relocateNodeData = relocateNodes.find((r) => r.$nodeToRelocate$ === node);
|
|
898
|
-
// made some changes to slots
|
|
899
|
-
// let's make sure we also double check
|
|
900
|
-
// fallbacks are correctly hidden or shown
|
|
901
|
-
checkSlotFallbackVisibility = true;
|
|
902
|
-
node['s-sn'] = node['s-sn'] || slotNameAttr;
|
|
903
|
-
if (relocateNodeData) {
|
|
904
|
-
// previously we never found a slot home for this node
|
|
905
|
-
// but turns out we did, so let's remember it now
|
|
906
|
-
relocateNodeData.$slotRefNode$ = childNode;
|
|
907
|
-
}
|
|
908
|
-
else {
|
|
909
|
-
// add to our list of nodes to relocate
|
|
910
|
-
relocateNodes.push({
|
|
911
|
-
$slotRefNode$: childNode,
|
|
912
|
-
$nodeToRelocate$: node,
|
|
913
|
-
});
|
|
914
|
-
}
|
|
915
|
-
if (node['s-sr']) {
|
|
916
|
-
relocateNodes.map((relocateNode) => {
|
|
917
|
-
if (isNodeLocatedInSlot(relocateNode.$nodeToRelocate$, node['s-sn'])) {
|
|
918
|
-
relocateNodeData = relocateNodes.find((r) => r.$nodeToRelocate$ === node);
|
|
919
|
-
if (relocateNodeData && !relocateNode.$slotRefNode$) {
|
|
920
|
-
relocateNode.$slotRefNode$ = relocateNodeData.$slotRefNode$;
|
|
921
|
-
}
|
|
922
|
-
}
|
|
923
|
-
});
|
|
924
|
-
}
|
|
925
|
-
}
|
|
926
|
-
else if (!relocateNodes.some((r) => r.$nodeToRelocate$ === node)) {
|
|
927
|
-
// so far this element does not have a slot home, not setting slotRefNode on purpose
|
|
928
|
-
// if we never find a home for this element then we'll need to hide it
|
|
929
|
-
relocateNodes.push({
|
|
930
|
-
$nodeToRelocate$: node,
|
|
931
|
-
});
|
|
932
|
-
}
|
|
933
|
-
}
|
|
934
|
-
}
|
|
935
|
-
}
|
|
936
|
-
if (childNode.nodeType === 1 /* ElementNode */) {
|
|
937
|
-
relocateSlotContent(childNode);
|
|
938
|
-
}
|
|
939
|
-
}
|
|
940
|
-
};
|
|
941
|
-
const isNodeLocatedInSlot = (nodeToRelocate, slotNameAttr) => {
|
|
942
|
-
if (nodeToRelocate.nodeType === 1 /* ElementNode */) {
|
|
943
|
-
if (nodeToRelocate.getAttribute('slot') === null && slotNameAttr === '') {
|
|
944
|
-
return true;
|
|
945
|
-
}
|
|
946
|
-
if (nodeToRelocate.getAttribute('slot') === slotNameAttr) {
|
|
947
|
-
return true;
|
|
948
|
-
}
|
|
949
|
-
return false;
|
|
950
|
-
}
|
|
951
|
-
if (nodeToRelocate['s-sn'] === slotNameAttr) {
|
|
952
|
-
return true;
|
|
953
|
-
}
|
|
954
|
-
return slotNameAttr === '';
|
|
955
|
-
};
|
|
956
705
|
const callNodeRefs = (vNode) => {
|
|
957
706
|
{
|
|
958
707
|
vNode.$attrs$ && vNode.$attrs$.ref && vNode.$attrs$.ref(null);
|
|
@@ -976,90 +725,8 @@ const renderVdom = (hostRef, renderFnResults) => {
|
|
|
976
725
|
{
|
|
977
726
|
scopeId = hostElm['s-sc'];
|
|
978
727
|
}
|
|
979
|
-
{
|
|
980
|
-
contentRef = hostElm['s-cr'];
|
|
981
|
-
useNativeShadowDom = (cmpMeta.$flags$ & 1 /* shadowDomEncapsulation */) !== 0;
|
|
982
|
-
// always reset
|
|
983
|
-
checkSlotFallbackVisibility = false;
|
|
984
|
-
}
|
|
985
728
|
// synchronous patch
|
|
986
729
|
patch(oldVNode, rootVnode);
|
|
987
|
-
{
|
|
988
|
-
// while we're moving nodes around existing nodes, temporarily disable
|
|
989
|
-
// the disconnectCallback from working
|
|
990
|
-
plt.$flags$ |= 1 /* isTmpDisconnected */;
|
|
991
|
-
if (checkSlotRelocate) {
|
|
992
|
-
relocateSlotContent(rootVnode.$elm$);
|
|
993
|
-
let relocateData;
|
|
994
|
-
let nodeToRelocate;
|
|
995
|
-
let orgLocationNode;
|
|
996
|
-
let parentNodeRef;
|
|
997
|
-
let insertBeforeNode;
|
|
998
|
-
let refNode;
|
|
999
|
-
let i = 0;
|
|
1000
|
-
for (; i < relocateNodes.length; i++) {
|
|
1001
|
-
relocateData = relocateNodes[i];
|
|
1002
|
-
nodeToRelocate = relocateData.$nodeToRelocate$;
|
|
1003
|
-
if (!nodeToRelocate['s-ol']) {
|
|
1004
|
-
// add a reference node marking this node's original location
|
|
1005
|
-
// keep a reference to this node for later lookups
|
|
1006
|
-
orgLocationNode =
|
|
1007
|
-
doc.createTextNode('');
|
|
1008
|
-
orgLocationNode['s-nr'] = nodeToRelocate;
|
|
1009
|
-
nodeToRelocate.parentNode.insertBefore((nodeToRelocate['s-ol'] = orgLocationNode), nodeToRelocate);
|
|
1010
|
-
}
|
|
1011
|
-
}
|
|
1012
|
-
for (i = 0; i < relocateNodes.length; i++) {
|
|
1013
|
-
relocateData = relocateNodes[i];
|
|
1014
|
-
nodeToRelocate = relocateData.$nodeToRelocate$;
|
|
1015
|
-
if (relocateData.$slotRefNode$) {
|
|
1016
|
-
// by default we're just going to insert it directly
|
|
1017
|
-
// after the slot reference node
|
|
1018
|
-
parentNodeRef = relocateData.$slotRefNode$.parentNode;
|
|
1019
|
-
insertBeforeNode = relocateData.$slotRefNode$.nextSibling;
|
|
1020
|
-
orgLocationNode = nodeToRelocate['s-ol'];
|
|
1021
|
-
while ((orgLocationNode = orgLocationNode.previousSibling)) {
|
|
1022
|
-
refNode = orgLocationNode['s-nr'];
|
|
1023
|
-
if (refNode && refNode['s-sn'] === nodeToRelocate['s-sn'] && parentNodeRef === refNode.parentNode) {
|
|
1024
|
-
refNode = refNode.nextSibling;
|
|
1025
|
-
if (!refNode || !refNode['s-nr']) {
|
|
1026
|
-
insertBeforeNode = refNode;
|
|
1027
|
-
break;
|
|
1028
|
-
}
|
|
1029
|
-
}
|
|
1030
|
-
}
|
|
1031
|
-
if ((!insertBeforeNode && parentNodeRef !== nodeToRelocate.parentNode) ||
|
|
1032
|
-
nodeToRelocate.nextSibling !== insertBeforeNode) {
|
|
1033
|
-
// we've checked that it's worth while to relocate
|
|
1034
|
-
// since that the node to relocate
|
|
1035
|
-
// has a different next sibling or parent relocated
|
|
1036
|
-
if (nodeToRelocate !== insertBeforeNode) {
|
|
1037
|
-
if (!nodeToRelocate['s-hn'] && nodeToRelocate['s-ol']) {
|
|
1038
|
-
// probably a component in the index.html that doesn't have it's hostname set
|
|
1039
|
-
nodeToRelocate['s-hn'] = nodeToRelocate['s-ol'].parentNode.nodeName;
|
|
1040
|
-
}
|
|
1041
|
-
// add it back to the dom but in its new home
|
|
1042
|
-
parentNodeRef.insertBefore(nodeToRelocate, insertBeforeNode);
|
|
1043
|
-
}
|
|
1044
|
-
}
|
|
1045
|
-
}
|
|
1046
|
-
else {
|
|
1047
|
-
// this node doesn't have a slot home to go to, so let's hide it
|
|
1048
|
-
if (nodeToRelocate.nodeType === 1 /* ElementNode */) {
|
|
1049
|
-
nodeToRelocate.hidden = true;
|
|
1050
|
-
}
|
|
1051
|
-
}
|
|
1052
|
-
}
|
|
1053
|
-
}
|
|
1054
|
-
if (checkSlotFallbackVisibility) {
|
|
1055
|
-
updateFallbackSlotVisibility(rootVnode.$elm$);
|
|
1056
|
-
}
|
|
1057
|
-
// done moving nodes around
|
|
1058
|
-
// allow the disconnect callback to work again
|
|
1059
|
-
plt.$flags$ &= ~1 /* isTmpDisconnected */;
|
|
1060
|
-
// always reset
|
|
1061
|
-
relocateNodes.length = 0;
|
|
1062
|
-
}
|
|
1063
730
|
};
|
|
1064
731
|
const getElement = (ref) => (getHostRef(ref).$hostElement$ );
|
|
1065
732
|
const createEvent = (ref, name, flags) => {
|
|
@@ -1443,10 +1110,6 @@ const clientHydrate = (parentVNode, childRenderNodes, slotNodes, shadowRootNodes
|
|
|
1443
1110
|
// remove the content ref comment since it's not needed for shadow
|
|
1444
1111
|
node.remove();
|
|
1445
1112
|
}
|
|
1446
|
-
else {
|
|
1447
|
-
hostElm['s-cr'] = node;
|
|
1448
|
-
node['s-cn'] = true;
|
|
1449
|
-
}
|
|
1450
1113
|
}
|
|
1451
1114
|
}
|
|
1452
1115
|
}
|
|
@@ -1758,15 +1421,6 @@ const connectedCallback = (elm) => {
|
|
|
1758
1421
|
initializeClientHydrate(elm, cmpMeta.$tagName$, hostId, hostRef);
|
|
1759
1422
|
}
|
|
1760
1423
|
}
|
|
1761
|
-
if (!hostId) {
|
|
1762
|
-
// initUpdate
|
|
1763
|
-
// if the slot polyfill is required we'll need to put some nodes
|
|
1764
|
-
// in here to act as original content anchors as we move nodes around
|
|
1765
|
-
// host element has been connected to the DOM
|
|
1766
|
-
if ((cmpMeta.$flags$ & (4 /* hasSlotRelocation */ | 8 /* needsShadowDomShim */))) {
|
|
1767
|
-
setContentReference(elm);
|
|
1768
|
-
}
|
|
1769
|
-
}
|
|
1770
1424
|
{
|
|
1771
1425
|
// find the first ancestor component (if there is one) and register
|
|
1772
1426
|
// this component as one of the actively loading child components for its ancestor
|
|
@@ -1811,17 +1465,6 @@ const connectedCallback = (elm) => {
|
|
|
1811
1465
|
endConnected();
|
|
1812
1466
|
}
|
|
1813
1467
|
};
|
|
1814
|
-
const setContentReference = (elm) => {
|
|
1815
|
-
// only required when we're NOT using native shadow dom (slot)
|
|
1816
|
-
// or this browser doesn't support native shadow dom
|
|
1817
|
-
// and this host element was NOT created with SSR
|
|
1818
|
-
// let's pick out the inner content for slot projection
|
|
1819
|
-
// create a node to represent where the original
|
|
1820
|
-
// content was first placed, which is useful later on
|
|
1821
|
-
const contentRefElm = (elm['s-cr'] = doc.createComment(''));
|
|
1822
|
-
contentRefElm['s-cn'] = true;
|
|
1823
|
-
elm.insertBefore(contentRefElm, elm.firstChild);
|
|
1824
|
-
};
|
|
1825
1468
|
const disconnectedCallback = (elm) => {
|
|
1826
1469
|
if ((plt.$flags$ & 1 /* isTmpDisconnected */) === 0) {
|
|
1827
1470
|
const hostRef = getHostRef(elm);
|
|
@@ -4,14 +4,43 @@
|
|
|
4
4
|
*/
|
|
5
5
|
import { q as queryElementRoots, c as closestElementCrossShadowBoundary } from './dom-f24e866c.js';
|
|
6
6
|
|
|
7
|
-
|
|
7
|
+
/**
|
|
8
|
+
* Exported for testing purposes only
|
|
9
|
+
* @internal
|
|
10
|
+
*/
|
|
8
11
|
const labelClickEvent = "calciteInternalLabelClick";
|
|
12
|
+
const labelTagName = "calcite-label";
|
|
9
13
|
const onLabelClickMap = new WeakMap();
|
|
10
14
|
const findLabelForComponent = (componentEl) => {
|
|
11
|
-
const id = componentEl
|
|
12
|
-
|
|
13
|
-
|
|
15
|
+
const { id } = componentEl;
|
|
16
|
+
const forLabel = id && queryElementRoots(componentEl, `${labelTagName}[for="${id}"]`);
|
|
17
|
+
if (forLabel) {
|
|
18
|
+
return forLabel;
|
|
19
|
+
}
|
|
20
|
+
const parentLabel = closestElementCrossShadowBoundary(componentEl, labelTagName);
|
|
21
|
+
if (!parentLabel ||
|
|
22
|
+
// labelable components within other custom elements are not considered labelable
|
|
23
|
+
hasAncestorCustomElements(parentLabel, componentEl)) {
|
|
24
|
+
return null;
|
|
25
|
+
}
|
|
26
|
+
return parentLabel;
|
|
14
27
|
};
|
|
28
|
+
function hasAncestorCustomElements(label, componentEl) {
|
|
29
|
+
let traversedElements;
|
|
30
|
+
const customElementAncestorCheckEventType = "custom-element-ancestor-check";
|
|
31
|
+
const listener = (event) => {
|
|
32
|
+
event.stopImmediatePropagation();
|
|
33
|
+
const composedPath = event.composedPath();
|
|
34
|
+
traversedElements = composedPath.slice(composedPath.indexOf(componentEl), composedPath.indexOf(label));
|
|
35
|
+
};
|
|
36
|
+
label.addEventListener(customElementAncestorCheckEventType, listener, { once: true });
|
|
37
|
+
componentEl.dispatchEvent(new CustomEvent(customElementAncestorCheckEventType, { composed: true, bubbles: true }));
|
|
38
|
+
label.removeEventListener(customElementAncestorCheckEventType, listener);
|
|
39
|
+
const ancestorCustomElements = traversedElements
|
|
40
|
+
.filter((el) => el !== componentEl && el !== label)
|
|
41
|
+
.filter((el) => { var _a; return (_a = el.tagName) === null || _a === void 0 ? void 0 : _a.includes("-"); });
|
|
42
|
+
return ancestorCustomElements.length > 0;
|
|
43
|
+
}
|
|
15
44
|
/**
|
|
16
45
|
* Helper to set up label interactions on connectedCallback.
|
|
17
46
|
*/
|