@six-group/ui-library 0.0.0-insider.fe4db17 → 0.0.0-insider.fea784d
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/cjs/animation-ZgWV0fC6.js +54 -0
- package/dist/cjs/animation-ZgWV0fC6.js.map +1 -0
- package/dist/cjs/{form-control-Ditp8yHw.js → form-control-CX8QRq9v.js} +3 -3
- package/dist/cjs/{form-control-Ditp8yHw.js.map → form-control-CX8QRq9v.js.map} +1 -1
- package/dist/cjs/{index-BKTrCUjx.js → index-C8rK7OAe.js} +3 -3
- package/dist/{esm/index-D0Go1Zjj.js.map → cjs/index-C8rK7OAe.js.map} +1 -1
- package/dist/cjs/loader.cjs.js +1 -1
- package/dist/cjs/six-alert.cjs.entry.js +1 -1
- package/dist/cjs/six-avatar.cjs.entry.js +3 -3
- package/dist/cjs/six-badge.cjs.entry.js +3 -3
- package/dist/cjs/six-button.cjs.entry.js +3 -3
- package/dist/cjs/six-card.cjs.entry.js +2 -2
- package/dist/cjs/six-checkbox_2.cjs.entry.js +4 -4
- package/dist/cjs/six-date.cjs.entry.js +3 -3
- package/dist/cjs/six-datepicker.cjs.entry.js +1 -1
- package/dist/cjs/six-details.cjs.entry.js +4 -4
- package/dist/cjs/six-dialog.cjs.entry.js +16 -10
- package/dist/cjs/six-dialog.cjs.entry.js.map +1 -1
- package/dist/cjs/six-dialog.entry.cjs.js.map +1 -1
- package/dist/cjs/six-drawer.cjs.entry.js +16 -10
- package/dist/cjs/six-drawer.cjs.entry.js.map +1 -1
- package/dist/cjs/six-drawer.entry.cjs.js.map +1 -1
- package/dist/cjs/six-dropdown_2.cjs.entry.js +8 -8
- package/dist/cjs/six-error-page.cjs.entry.js +1 -1
- package/dist/cjs/six-error.cjs.entry.js +1 -1
- package/dist/cjs/six-file-list-item.cjs.entry.js +3 -3
- package/dist/cjs/six-file-list.cjs.entry.js +1 -1
- package/dist/cjs/six-file-upload.cjs.entry.js +5 -5
- package/dist/cjs/six-footer.cjs.entry.js +1 -1
- package/dist/cjs/six-group-label.cjs.entry.js +2 -2
- package/dist/cjs/six-header-dropdown-item.cjs.entry.js +1 -1
- package/dist/cjs/six-header-item.cjs.entry.js +1 -1
- package/dist/cjs/six-header-menu-button.cjs.entry.js +1 -1
- package/dist/cjs/six-header.cjs.entry.js +1 -1
- package/dist/cjs/six-icon-button.cjs.entry.js +1 -1
- package/dist/cjs/six-icon.cjs.entry.js +1 -1
- package/dist/cjs/six-input.cjs.entry.js +5 -5
- package/dist/cjs/six-item-picker.cjs.entry.js +1 -1
- package/dist/cjs/six-language-switcher.cjs.entry.js +2 -2
- package/dist/cjs/six-layout-grid.cjs.entry.js +1 -1
- package/dist/cjs/six-logo.cjs.entry.js +1 -1
- package/dist/cjs/six-main-container.cjs.entry.js +1 -1
- package/dist/cjs/six-menu-divider.cjs.entry.js +1 -1
- package/dist/cjs/six-menu-label.cjs.entry.js +1 -1
- package/dist/cjs/six-picto.cjs.entry.js +1 -1
- package/dist/cjs/six-progress-bar.cjs.entry.js +1 -1
- package/dist/cjs/six-progress-ring.cjs.entry.js +1 -1
- package/dist/cjs/six-radio.cjs.entry.js +1 -1
- package/dist/cjs/six-range.cjs.entry.js +2 -2
- package/dist/cjs/six-root.cjs.entry.js +1 -1
- package/dist/cjs/six-search-field.cjs.entry.js +2 -2
- package/dist/cjs/six-select.cjs.entry.js +8 -8
- package/dist/cjs/six-sidebar-item-group.cjs.entry.js +1 -1
- package/dist/cjs/six-sidebar-item.cjs.entry.js +1 -1
- package/dist/cjs/six-sidebar.cjs.entry.js +1 -1
- package/dist/cjs/six-spinner.cjs.entry.js +1 -1
- package/dist/cjs/six-stage-indicator.cjs.entry.js +1 -1
- package/dist/cjs/six-switch.cjs.entry.js +2 -2
- package/dist/cjs/six-tab-group.cjs.entry.js +5 -38
- package/dist/cjs/six-tab-group.cjs.entry.js.map +1 -1
- package/dist/cjs/six-tab-group.entry.cjs.js.map +1 -1
- package/dist/cjs/six-tab-panel.cjs.entry.js +1 -1
- package/dist/cjs/six-tab.cjs.entry.js +4 -4
- package/dist/cjs/six-tab.cjs.entry.js.map +1 -1
- package/dist/cjs/six-tab.entry.cjs.js.map +1 -1
- package/dist/cjs/six-tag.cjs.entry.js +1 -1
- package/dist/cjs/six-textarea.cjs.entry.js +2 -2
- package/dist/cjs/six-tile.cjs.entry.js +1 -1
- package/dist/cjs/six-timepicker.cjs.entry.js +1 -1
- package/dist/cjs/six-tooltip.cjs.entry.js +1 -1
- package/dist/cjs/ui-library.cjs.js +2 -2
- package/dist/cjs/ui-library.cjs.js.map +1 -1
- package/dist/collection/collection-manifest.json +3 -3
- package/dist/collection/components/six-avatar/six-avatar.js +2 -2
- package/dist/collection/components/six-badge/six-badge.js +2 -2
- package/dist/collection/components/six-button/six-button.js +2 -2
- package/dist/collection/components/six-card/six-card.js +1 -1
- package/dist/collection/components/six-checkbox/six-checkbox.js +2 -2
- package/dist/collection/components/six-date/six-date.js +2 -2
- package/dist/collection/components/six-details/six-details.js +3 -3
- package/dist/collection/components/six-dialog/six-dialog.js +23 -17
- package/dist/collection/components/six-dialog/six-dialog.js.map +1 -1
- package/dist/collection/components/six-drawer/six-drawer.js +23 -17
- package/dist/collection/components/six-drawer/six-drawer.js.map +1 -1
- package/dist/collection/components/six-dropdown/six-dropdown.js +5 -5
- package/dist/collection/components/six-file-list-item/six-file-list-item.js +2 -2
- package/dist/collection/components/six-file-upload/six-file-upload.js +4 -4
- package/dist/collection/components/six-input/six-input.js +3 -3
- package/dist/collection/components/six-language-switcher/six-language-switcher.js +1 -1
- package/dist/collection/components/six-menu/six-menu.js +2 -2
- package/dist/collection/components/six-search-field/six-search-field.js +1 -1
- package/dist/collection/components/six-select/six-select.js +6 -6
- package/dist/collection/components/six-tab/six-tab.css +12 -0
- package/dist/collection/components/six-tab/six-tab.js +2 -2
- package/dist/collection/components/six-tab/six-tab.js.map +1 -1
- package/dist/collection/components/six-tab-group/six-tab-group.js +2 -2
- package/dist/collection/utils/animation.js +13 -0
- package/dist/collection/utils/animation.js.map +1 -1
- package/dist/components/index.js +1 -1
- package/dist/components/{p-NtUDAuW7.js → p-9aUb96SZ.js} +14 -14
- package/dist/components/{p-NtUDAuW7.js.map → p-9aUb96SZ.js.map} +1 -1
- package/dist/components/{p-DV46ui1Q.js → p-BB2rei7y.js} +3 -3
- package/dist/components/{p-DV46ui1Q.js.map → p-BB2rei7y.js.map} +1 -1
- package/dist/components/{p-CpcN3YG9.js → p-BR2t7cws.js} +4 -4
- package/dist/components/{p-CpcN3YG9.js.map → p-BR2t7cws.js.map} +1 -1
- package/dist/components/{p-Mse5vRUS.js → p-BSHZAiyG.js} +3 -3
- package/dist/components/{p-Mse5vRUS.js.map → p-BSHZAiyG.js.map} +1 -1
- package/dist/components/{p-Cemjz04k.js → p-BUN8hFmL.js} +6 -6
- package/dist/components/{p-Cemjz04k.js.map → p-BUN8hFmL.js.map} +1 -1
- package/dist/components/{p-6HRX2kde.js → p-C28WDWgL.js} +6 -6
- package/dist/components/{p-6HRX2kde.js.map → p-C28WDWgL.js.map} +1 -1
- package/dist/components/{p-BPRt5Z5f.js → p-CSL17OWk.js} +9 -9
- package/dist/components/{p-BPRt5Z5f.js.map → p-CSL17OWk.js.map} +1 -1
- package/dist/components/{p-Cr6sHYme.js → p-CWKq6Dyt.js} +3 -3
- package/dist/components/{p-Cr6sHYme.js.map → p-CWKq6Dyt.js.map} +1 -1
- package/dist/components/{p-D45ehsSM.js → p-Cfyrva2T.js} +7 -7
- package/dist/components/{p-D45ehsSM.js.map → p-Cfyrva2T.js.map} +1 -1
- package/dist/components/{p-eW-dQ-wI.js → p-Cosz73fX.js} +4 -4
- package/dist/components/{p-eW-dQ-wI.js.map → p-Cosz73fX.js.map} +1 -1
- package/dist/components/{p-DT1sZALq.js → p-Cs1jspzx.js} +7 -7
- package/dist/components/{p-DT1sZALq.js.map → p-Cs1jspzx.js.map} +1 -1
- package/dist/components/{p-CYrYPnLQ.js → p-Cs6mMfx-.js} +3 -3
- package/dist/components/{p-CYrYPnLQ.js.map → p-Cs6mMfx-.js.map} +1 -1
- package/dist/components/{p-BtF2Ym6T.js → p-D512q9rn.js} +17 -4
- package/dist/components/p-D512q9rn.js.map +1 -0
- package/dist/components/{p-BmW8cpEG.js → p-DIkvCBxr.js} +3 -3
- package/dist/components/{p-BmW8cpEG.js.map → p-DIkvCBxr.js.map} +1 -1
- package/dist/components/{p-DXhOme6Y.js → p-DYlDF9Rw.js} +3 -3
- package/dist/components/{p-DXhOme6Y.js.map → p-DYlDF9Rw.js.map} +1 -1
- package/dist/components/{p-BkQKlScF.js → p-DnLdSdN5.js} +7 -7
- package/dist/components/{p-BkQKlScF.js.map → p-DnLdSdN5.js.map} +1 -1
- package/dist/components/{p-Dl9jKaw7.js → p-DsGIkEDB.js} +9 -9
- package/dist/components/{p-Dl9jKaw7.js.map → p-DsGIkEDB.js.map} +1 -1
- package/dist/components/{p-CLtU4Br-.js → p-DyYwMIDQ.js} +4 -4
- package/dist/components/{p-CLtU4Br-.js.map → p-DyYwMIDQ.js.map} +1 -1
- package/dist/components/p-SLlDVtvF.js +51 -0
- package/dist/components/p-SLlDVtvF.js.map +1 -0
- package/dist/components/six-alert.js +3 -3
- package/dist/components/six-avatar.js +4 -4
- package/dist/components/six-badge.js +3 -3
- package/dist/components/six-button.js +1 -1
- package/dist/components/six-card.js +2 -2
- package/dist/components/six-checkbox.js +1 -1
- package/dist/components/six-date.js +7 -7
- package/dist/components/six-datepicker.js +6 -6
- package/dist/components/six-details.js +1 -1
- package/dist/components/six-dialog.js +18 -12
- package/dist/components/six-dialog.js.map +1 -1
- package/dist/components/six-drawer.js +18 -12
- package/dist/components/six-drawer.js.map +1 -1
- package/dist/components/six-dropdown.js +1 -1
- package/dist/components/six-error-page.js +2 -2
- package/dist/components/six-error.js +1 -1
- package/dist/components/six-file-list-item.js +4 -4
- package/dist/components/six-file-list.js +1 -1
- package/dist/components/six-file-upload.js +8 -8
- package/dist/components/six-footer.js +1 -1
- package/dist/components/six-group-label.js +3 -3
- package/dist/components/six-header-dropdown-item.js +8 -8
- package/dist/components/six-header-item.js +1 -1
- package/dist/components/six-header-menu-button.js +3 -3
- package/dist/components/six-header.js +1 -1
- package/dist/components/six-icon-button.js +1 -1
- package/dist/components/six-icon.js +1 -1
- package/dist/components/six-input.js +1 -1
- package/dist/components/six-item-picker.js +1 -1
- package/dist/components/six-language-switcher.js +2 -2
- package/dist/components/six-layout-grid.js +1 -1
- package/dist/components/six-logo.js +1 -1
- package/dist/components/six-main-container.js +1 -1
- package/dist/components/six-menu-divider.js +1 -1
- package/dist/components/six-menu-item.js +1 -1
- package/dist/components/six-menu-label.js +1 -1
- package/dist/components/six-menu.js +1 -1
- package/dist/components/six-picto.js +1 -1
- package/dist/components/six-progress-bar.js +1 -1
- package/dist/components/six-progress-ring.js +1 -1
- package/dist/components/six-radio.js +1 -1
- package/dist/components/six-range.js +3 -3
- package/dist/components/six-root.js +3 -3
- package/dist/components/six-search-field.js +5 -5
- package/dist/components/six-select.js +18 -18
- package/dist/components/six-sidebar-item-group.js +3 -3
- package/dist/components/six-sidebar-item.js +2 -2
- package/dist/components/six-sidebar.js +1 -1
- package/dist/components/six-spinner.js +1 -1
- package/dist/components/six-stage-indicator.js +1 -1
- package/dist/components/six-switch.js +3 -3
- package/dist/components/six-tab-group.js +6 -39
- package/dist/components/six-tab-group.js.map +1 -1
- package/dist/components/six-tab-panel.js +1 -1
- package/dist/components/six-tab.js +6 -6
- package/dist/components/six-tab.js.map +1 -1
- package/dist/components/six-tag.js +4 -4
- package/dist/components/six-textarea.js +3 -3
- package/dist/components/six-tile.js +4 -4
- package/dist/components/six-timepicker.js +1 -1
- package/dist/components/six-tooltip.js +1 -1
- package/dist/components.json +1860 -325
- package/dist/esm/animation-SLlDVtvF.js +51 -0
- package/dist/esm/animation-SLlDVtvF.js.map +1 -0
- package/dist/esm/{form-control-D_uS8E6o.js → form-control-DI6V1ZhR.js} +3 -3
- package/dist/esm/{form-control-D_uS8E6o.js.map → form-control-DI6V1ZhR.js.map} +1 -1
- package/dist/esm/{index-D0Go1Zjj.js → index-JoG9I7EO.js} +3 -3
- package/dist/{cjs/index-BKTrCUjx.js.map → esm/index-JoG9I7EO.js.map} +1 -1
- package/dist/esm/loader.js +2 -2
- package/dist/esm/six-alert.entry.js +1 -1
- package/dist/esm/six-avatar.entry.js +3 -3
- package/dist/esm/six-badge.entry.js +3 -3
- package/dist/esm/six-button.entry.js +3 -3
- package/dist/esm/six-card.entry.js +2 -2
- package/dist/esm/six-checkbox_2.entry.js +4 -4
- package/dist/esm/six-date.entry.js +3 -3
- package/dist/esm/six-datepicker.entry.js +1 -1
- package/dist/esm/six-details.entry.js +4 -4
- package/dist/esm/six-dialog.entry.js +16 -10
- package/dist/esm/six-dialog.entry.js.map +1 -1
- package/dist/esm/six-drawer.entry.js +16 -10
- package/dist/esm/six-drawer.entry.js.map +1 -1
- package/dist/esm/six-dropdown_2.entry.js +8 -8
- package/dist/esm/six-error-page.entry.js +1 -1
- package/dist/esm/six-error.entry.js +1 -1
- package/dist/esm/six-file-list-item.entry.js +3 -3
- package/dist/esm/six-file-list.entry.js +1 -1
- package/dist/esm/six-file-upload.entry.js +5 -5
- package/dist/esm/six-footer.entry.js +1 -1
- package/dist/esm/six-group-label.entry.js +2 -2
- package/dist/esm/six-header-dropdown-item.entry.js +1 -1
- package/dist/esm/six-header-item.entry.js +1 -1
- package/dist/esm/six-header-menu-button.entry.js +1 -1
- package/dist/esm/six-header.entry.js +1 -1
- package/dist/esm/six-icon-button.entry.js +1 -1
- package/dist/esm/six-icon.entry.js +1 -1
- package/dist/esm/six-input.entry.js +5 -5
- package/dist/esm/six-item-picker.entry.js +1 -1
- package/dist/esm/six-language-switcher.entry.js +2 -2
- package/dist/esm/six-layout-grid.entry.js +1 -1
- package/dist/esm/six-logo.entry.js +1 -1
- package/dist/esm/six-main-container.entry.js +1 -1
- package/dist/esm/six-menu-divider.entry.js +1 -1
- package/dist/esm/six-menu-label.entry.js +1 -1
- package/dist/esm/six-picto.entry.js +1 -1
- package/dist/esm/six-progress-bar.entry.js +1 -1
- package/dist/esm/six-progress-ring.entry.js +1 -1
- package/dist/esm/six-radio.entry.js +1 -1
- package/dist/esm/six-range.entry.js +2 -2
- package/dist/esm/six-root.entry.js +1 -1
- package/dist/esm/six-search-field.entry.js +2 -2
- package/dist/esm/six-select.entry.js +8 -8
- package/dist/esm/six-sidebar-item-group.entry.js +1 -1
- package/dist/esm/six-sidebar-item.entry.js +1 -1
- package/dist/esm/six-sidebar.entry.js +1 -1
- package/dist/esm/six-spinner.entry.js +1 -1
- package/dist/esm/six-stage-indicator.entry.js +1 -1
- package/dist/esm/six-switch.entry.js +2 -2
- package/dist/esm/six-tab-group.entry.js +4 -37
- package/dist/esm/six-tab-group.entry.js.map +1 -1
- package/dist/esm/six-tab-panel.entry.js +1 -1
- package/dist/esm/six-tab.entry.js +4 -4
- package/dist/esm/six-tab.entry.js.map +1 -1
- package/dist/esm/six-tag.entry.js +1 -1
- package/dist/esm/six-textarea.entry.js +2 -2
- package/dist/esm/six-tile.entry.js +1 -1
- package/dist/esm/six-timepicker.entry.js +1 -1
- package/dist/esm/six-tooltip.entry.js +1 -1
- package/dist/esm/ui-library.js +3 -3
- package/dist/esm/ui-library.js.map +1 -1
- package/dist/types/components/six-dialog/six-dialog.d.ts +10 -2
- package/dist/types/components/six-drawer/six-drawer.d.ts +10 -2
- package/dist/types/components.d.ts +620 -6
- package/dist/types/stencil-public-runtime.d.ts +19 -0
- package/dist/types/utils/animation.d.ts +4 -0
- package/dist/ui-library/p-01243b2e.entry.js +2 -0
- package/dist/ui-library/p-01243b2e.entry.js.map +1 -0
- package/dist/ui-library/{p-79a79513.entry.js → p-09de2bda.entry.js} +2 -2
- package/dist/ui-library/{p-0ae9215f.entry.js → p-0eb90caf.entry.js} +2 -2
- package/dist/ui-library/{p-22ad5b1e.entry.js → p-14f79bfc.entry.js} +2 -2
- package/dist/ui-library/{p-baf698e1.entry.js → p-174dd242.entry.js} +2 -2
- package/dist/ui-library/{p-a1f7be27.entry.js → p-18e755bc.entry.js} +2 -2
- package/dist/ui-library/{p-6990e5ed.entry.js → p-194037e9.entry.js} +2 -2
- package/dist/ui-library/{p-81af96f2.entry.js → p-1cfa2df4.entry.js} +2 -2
- package/dist/ui-library/{p-e91aa04b.entry.js → p-22ad3353.entry.js} +2 -2
- package/dist/ui-library/{p-ba68b30c.entry.js → p-25ff87fe.entry.js} +2 -2
- package/dist/ui-library/{p-df05b23b.entry.js → p-285666de.entry.js} +2 -2
- package/dist/ui-library/{p-a534a4bc.entry.js → p-29d79fe3.entry.js} +2 -2
- package/dist/ui-library/{p-1e4d1252.entry.js → p-2a245a37.entry.js} +2 -2
- package/dist/ui-library/{p-f585a5ab.entry.js → p-2a82de6c.entry.js} +2 -2
- package/dist/ui-library/{p-5e70085d.entry.js → p-2fb16281.entry.js} +2 -2
- package/dist/ui-library/{p-695e450e.entry.js → p-31c5f8fa.entry.js} +2 -2
- package/dist/ui-library/{p-1323f2cb.entry.js → p-336610a9.entry.js} +2 -2
- package/dist/ui-library/{p-830ed202.entry.js → p-362ff192.entry.js} +2 -2
- package/dist/ui-library/{p-36a316e0.entry.js → p-371ef302.entry.js} +2 -2
- package/dist/ui-library/p-39109b96.entry.js +2 -0
- package/dist/ui-library/p-39109b96.entry.js.map +1 -0
- package/dist/ui-library/{p-b8db5638.entry.js → p-3d49deae.entry.js} +2 -2
- package/dist/ui-library/{p-5e5bd309.entry.js → p-3dc98466.entry.js} +2 -2
- package/dist/ui-library/{p-82f5b61f.entry.js → p-4152b371.entry.js} +2 -2
- package/dist/ui-library/{p-6d212bc0.entry.js → p-494546c8.entry.js} +2 -2
- package/dist/ui-library/{p-9b1c8a24.entry.js → p-4f52c56f.entry.js} +2 -2
- package/dist/ui-library/{p-d7616f27.entry.js → p-54490d28.entry.js} +2 -2
- package/dist/ui-library/p-56e172e0.entry.js +2 -0
- package/dist/ui-library/p-56e172e0.entry.js.map +1 -0
- package/dist/ui-library/{p-8fe7ecdd.entry.js → p-5b52d097.entry.js} +2 -2
- package/dist/ui-library/{p-9f0ed997.entry.js → p-65e53a1b.entry.js} +2 -2
- package/dist/ui-library/{p-ae8d75aa.entry.js → p-6607d03a.entry.js} +2 -2
- package/dist/ui-library/{p-85aacb7c.entry.js → p-6dd3f54c.entry.js} +2 -2
- package/dist/ui-library/{p-5ed5842b.entry.js → p-811ce2a0.entry.js} +2 -2
- package/dist/ui-library/p-83d5fa7c.entry.js +2 -0
- package/dist/ui-library/p-83d5fa7c.entry.js.map +1 -0
- package/dist/ui-library/{p-4a4a0751.entry.js → p-850aff56.entry.js} +2 -2
- package/dist/ui-library/{p-01306147.entry.js → p-8884a48b.entry.js} +2 -2
- package/dist/ui-library/{p-b09e3895.entry.js → p-91c195d3.entry.js} +2 -2
- package/dist/ui-library/{p-537a8953.entry.js → p-9ec79195.entry.js} +2 -2
- package/dist/ui-library/{p-IBmarOIS.js → p-Dg9366Gk.js} +2 -2
- package/dist/ui-library/{p-IBmarOIS.js.map → p-Dg9366Gk.js.map} +1 -1
- package/dist/ui-library/{p-D0Go1Zjj.js → p-JoG9I7EO.js} +1 -1
- package/dist/ui-library/{p-D0Go1Zjj.js.map → p-JoG9I7EO.js.map} +1 -1
- package/dist/ui-library/p-SLlDVtvF.js +2 -0
- package/dist/ui-library/p-SLlDVtvF.js.map +1 -0
- package/dist/ui-library/{p-73b64625.entry.js → p-a43843d6.entry.js} +2 -2
- package/dist/ui-library/{p-071ed780.entry.js → p-a4b523ed.entry.js} +2 -2
- package/dist/ui-library/{p-c2ec443c.entry.js → p-ab043a8c.entry.js} +2 -2
- package/dist/ui-library/{p-1e67ac05.entry.js → p-b37d9771.entry.js} +2 -2
- package/dist/ui-library/{p-97b78889.entry.js → p-b6244904.entry.js} +2 -2
- package/dist/ui-library/{p-243965b4.entry.js → p-c47f11e4.entry.js} +2 -2
- package/dist/ui-library/{p-f4e2ddfc.entry.js → p-c90a59fc.entry.js} +2 -2
- package/dist/ui-library/{p-f52715e8.entry.js → p-cea7f777.entry.js} +2 -2
- package/dist/ui-library/{p-868fab98.entry.js → p-d36ec323.entry.js} +2 -2
- package/dist/ui-library/{p-5ad81261.entry.js → p-dc2109d2.entry.js} +2 -2
- package/dist/ui-library/{p-0d97e592.entry.js → p-e85be7d2.entry.js} +2 -2
- package/dist/ui-library/{p-68c50fb7.entry.js → p-e92df84a.entry.js} +2 -2
- package/dist/ui-library/{p-679f1e08.entry.js → p-ea61b009.entry.js} +2 -2
- package/dist/ui-library/{p-8d60c1fd.entry.js → p-ed6625e6.entry.js} +2 -2
- package/dist/ui-library/{p-9713ecff.entry.js → p-ee980a0f.entry.js} +2 -2
- package/dist/ui-library/{p-cc44af70.entry.js → p-f4dd7b57.entry.js} +2 -2
- package/dist/ui-library/{p-84964501.entry.js → p-f6423fca.entry.js} +2 -2
- package/dist/ui-library/{p-16028bce.entry.js → p-fe7d3665.entry.js} +2 -2
- package/dist/ui-library/six-dialog.entry.esm.js.map +1 -1
- package/dist/ui-library/six-drawer.entry.esm.js.map +1 -1
- package/dist/ui-library/six-tab-group.entry.esm.js.map +1 -1
- package/dist/ui-library/six-tab.entry.esm.js.map +1 -1
- package/dist/ui-library/ui-library.esm.js +1 -1
- package/dist/ui-library/ui-library.esm.js.map +1 -1
- package/package.json +7 -8
- package/dist/components/p-BtF2Ym6T.js.map +0 -1
- package/dist/ui-library/p-0b438d5a.entry.js +0 -2
- package/dist/ui-library/p-0b438d5a.entry.js.map +0 -1
- package/dist/ui-library/p-798fb03a.entry.js +0 -2
- package/dist/ui-library/p-798fb03a.entry.js.map +0 -1
- package/dist/ui-library/p-d1bd67af.entry.js +0 -2
- package/dist/ui-library/p-d1bd67af.entry.js.map +0 -1
- package/dist/ui-library/p-f0c10d20.entry.js +0 -2
- package/dist/ui-library/p-f0c10d20.entry.js.map +0 -1
- /package/dist/ui-library/{p-79a79513.entry.js.map → p-09de2bda.entry.js.map} +0 -0
- /package/dist/ui-library/{p-0ae9215f.entry.js.map → p-0eb90caf.entry.js.map} +0 -0
- /package/dist/ui-library/{p-22ad5b1e.entry.js.map → p-14f79bfc.entry.js.map} +0 -0
- /package/dist/ui-library/{p-baf698e1.entry.js.map → p-174dd242.entry.js.map} +0 -0
- /package/dist/ui-library/{p-a1f7be27.entry.js.map → p-18e755bc.entry.js.map} +0 -0
- /package/dist/ui-library/{p-6990e5ed.entry.js.map → p-194037e9.entry.js.map} +0 -0
- /package/dist/ui-library/{p-81af96f2.entry.js.map → p-1cfa2df4.entry.js.map} +0 -0
- /package/dist/ui-library/{p-e91aa04b.entry.js.map → p-22ad3353.entry.js.map} +0 -0
- /package/dist/ui-library/{p-ba68b30c.entry.js.map → p-25ff87fe.entry.js.map} +0 -0
- /package/dist/ui-library/{p-df05b23b.entry.js.map → p-285666de.entry.js.map} +0 -0
- /package/dist/ui-library/{p-a534a4bc.entry.js.map → p-29d79fe3.entry.js.map} +0 -0
- /package/dist/ui-library/{p-1e4d1252.entry.js.map → p-2a245a37.entry.js.map} +0 -0
- /package/dist/ui-library/{p-f585a5ab.entry.js.map → p-2a82de6c.entry.js.map} +0 -0
- /package/dist/ui-library/{p-5e70085d.entry.js.map → p-2fb16281.entry.js.map} +0 -0
- /package/dist/ui-library/{p-695e450e.entry.js.map → p-31c5f8fa.entry.js.map} +0 -0
- /package/dist/ui-library/{p-1323f2cb.entry.js.map → p-336610a9.entry.js.map} +0 -0
- /package/dist/ui-library/{p-830ed202.entry.js.map → p-362ff192.entry.js.map} +0 -0
- /package/dist/ui-library/{p-36a316e0.entry.js.map → p-371ef302.entry.js.map} +0 -0
- /package/dist/ui-library/{p-b8db5638.entry.js.map → p-3d49deae.entry.js.map} +0 -0
- /package/dist/ui-library/{p-5e5bd309.entry.js.map → p-3dc98466.entry.js.map} +0 -0
- /package/dist/ui-library/{p-82f5b61f.entry.js.map → p-4152b371.entry.js.map} +0 -0
- /package/dist/ui-library/{p-6d212bc0.entry.js.map → p-494546c8.entry.js.map} +0 -0
- /package/dist/ui-library/{p-9b1c8a24.entry.js.map → p-4f52c56f.entry.js.map} +0 -0
- /package/dist/ui-library/{p-d7616f27.entry.js.map → p-54490d28.entry.js.map} +0 -0
- /package/dist/ui-library/{p-8fe7ecdd.entry.js.map → p-5b52d097.entry.js.map} +0 -0
- /package/dist/ui-library/{p-9f0ed997.entry.js.map → p-65e53a1b.entry.js.map} +0 -0
- /package/dist/ui-library/{p-ae8d75aa.entry.js.map → p-6607d03a.entry.js.map} +0 -0
- /package/dist/ui-library/{p-85aacb7c.entry.js.map → p-6dd3f54c.entry.js.map} +0 -0
- /package/dist/ui-library/{p-5ed5842b.entry.js.map → p-811ce2a0.entry.js.map} +0 -0
- /package/dist/ui-library/{p-4a4a0751.entry.js.map → p-850aff56.entry.js.map} +0 -0
- /package/dist/ui-library/{p-01306147.entry.js.map → p-8884a48b.entry.js.map} +0 -0
- /package/dist/ui-library/{p-b09e3895.entry.js.map → p-91c195d3.entry.js.map} +0 -0
- /package/dist/ui-library/{p-537a8953.entry.js.map → p-9ec79195.entry.js.map} +0 -0
- /package/dist/ui-library/{p-73b64625.entry.js.map → p-a43843d6.entry.js.map} +0 -0
- /package/dist/ui-library/{p-071ed780.entry.js.map → p-a4b523ed.entry.js.map} +0 -0
- /package/dist/ui-library/{p-c2ec443c.entry.js.map → p-ab043a8c.entry.js.map} +0 -0
- /package/dist/ui-library/{p-1e67ac05.entry.js.map → p-b37d9771.entry.js.map} +0 -0
- /package/dist/ui-library/{p-97b78889.entry.js.map → p-b6244904.entry.js.map} +0 -0
- /package/dist/ui-library/{p-243965b4.entry.js.map → p-c47f11e4.entry.js.map} +0 -0
- /package/dist/ui-library/{p-f4e2ddfc.entry.js.map → p-c90a59fc.entry.js.map} +0 -0
- /package/dist/ui-library/{p-f52715e8.entry.js.map → p-cea7f777.entry.js.map} +0 -0
- /package/dist/ui-library/{p-868fab98.entry.js.map → p-d36ec323.entry.js.map} +0 -0
- /package/dist/ui-library/{p-5ad81261.entry.js.map → p-dc2109d2.entry.js.map} +0 -0
- /package/dist/ui-library/{p-0d97e592.entry.js.map → p-e85be7d2.entry.js.map} +0 -0
- /package/dist/ui-library/{p-68c50fb7.entry.js.map → p-e92df84a.entry.js.map} +0 -0
- /package/dist/ui-library/{p-679f1e08.entry.js.map → p-ea61b009.entry.js.map} +0 -0
- /package/dist/ui-library/{p-8d60c1fd.entry.js.map → p-ed6625e6.entry.js.map} +0 -0
- /package/dist/ui-library/{p-9713ecff.entry.js.map → p-ee980a0f.entry.js.map} +0 -0
- /package/dist/ui-library/{p-cc44af70.entry.js.map → p-f4dd7b57.entry.js.map} +0 -0
- /package/dist/ui-library/{p-84964501.entry.js.map → p-f6423fca.entry.js.map} +0 -0
- /package/dist/ui-library/{p-16028bce.entry.js.map → p-fe7d3665.entry.js.map} +0 -0
|
@@ -2,6 +2,7 @@ import { h } from "@stencil/core";
|
|
|
2
2
|
import { lockBodyScrolling, unlockBodyScrolling } from "../../utils/scroll";
|
|
3
3
|
import { hasSlot } from "../../utils/slot";
|
|
4
4
|
import Modal from "../../utils/modal";
|
|
5
|
+
import { animateTo } from "../../utils/animation";
|
|
5
6
|
let id = 0;
|
|
6
7
|
/**
|
|
7
8
|
* @since 1.0
|
|
@@ -49,18 +50,15 @@ export class SixDrawer {
|
|
|
49
50
|
*/
|
|
50
51
|
this.noHeader = false;
|
|
51
52
|
this.handleCloseClick = () => {
|
|
52
|
-
this.
|
|
53
|
+
this.preventClose('close-button');
|
|
53
54
|
};
|
|
54
55
|
this.handleKeyDown = (event) => {
|
|
55
56
|
if (event.key === 'Escape') {
|
|
56
|
-
this.
|
|
57
|
+
this.preventClose('keyboard');
|
|
57
58
|
}
|
|
58
59
|
};
|
|
59
60
|
this.handleOverlayClick = () => {
|
|
60
|
-
|
|
61
|
-
if (!sixOverlayDismiss.defaultPrevented) {
|
|
62
|
-
this.hide();
|
|
63
|
-
}
|
|
61
|
+
this.preventClose('overlay');
|
|
64
62
|
};
|
|
65
63
|
this.handleSlotChange = () => {
|
|
66
64
|
this.hasFooter = hasSlot(this.host, 'footer');
|
|
@@ -138,6 +136,14 @@ export class SixDrawer {
|
|
|
138
136
|
this.modal.deactivate();
|
|
139
137
|
unlockBodyScrolling(this.host);
|
|
140
138
|
}
|
|
139
|
+
preventClose(source) {
|
|
140
|
+
const sixRequestClose = this.sixRequestClose.emit({ source });
|
|
141
|
+
if (sixRequestClose.defaultPrevented && this.panel) {
|
|
142
|
+
animateTo(this.panel, [{ scale: 1 }, { scale: 1.01 }, { scale: 1 }], { duration: 250 });
|
|
143
|
+
return;
|
|
144
|
+
}
|
|
145
|
+
this.hide();
|
|
146
|
+
}
|
|
141
147
|
resetTransitionVariables() {
|
|
142
148
|
this.isVisible = this.open;
|
|
143
149
|
this.willShow = false;
|
|
@@ -145,7 +151,7 @@ export class SixDrawer {
|
|
|
145
151
|
this.open ? this.sixAfterShow.emit() : this.sixAfterHide.emit();
|
|
146
152
|
}
|
|
147
153
|
render() {
|
|
148
|
-
return (h("div", { key: '
|
|
154
|
+
return (h("div", { key: '17d045e1a06aa424bc59f7316525df73ae031227', ref: (el) => (this.drawer = el), part: "base", class: {
|
|
149
155
|
drawer: true,
|
|
150
156
|
'drawer--open': this.open,
|
|
151
157
|
'drawer--visible': this.isVisible,
|
|
@@ -156,7 +162,7 @@ export class SixDrawer {
|
|
|
156
162
|
'drawer--contained': this.contained,
|
|
157
163
|
'drawer--fixed': !this.contained,
|
|
158
164
|
'drawer--has-footer': this.hasFooter,
|
|
159
|
-
}, onKeyDown: this.handleKeyDown, onTransitionEnd: this.handleTransitionEnd }, h("div", { key: '
|
|
165
|
+
}, onKeyDown: this.handleKeyDown, onTransitionEnd: this.handleTransitionEnd }, h("div", { key: '804fcb75cc49156bfcb6af8958a40c33c20f8202', part: "overlay", class: "drawer__overlay", onClick: this.handleOverlayClick, tabIndex: -1 }), h("div", { key: 'e5095b200d370fe98163b3f0fa2bbf42ece7fa5f', ref: (el) => (this.panel = el), part: "panel", class: "drawer__panel", role: "dialog", "aria-modal": "true", "aria-hidden": this.open ? 'false' : 'true', "aria-label": this.noHeader ? this.label : null, "aria-labelledby": !this.noHeader ? `${this.componentId}-title` : null, tabIndex: 0 }, !this.noHeader && (h("header", { key: 'c479cfa062277a6f1cf0f7433cff73e94139faea', part: "header", class: "drawer__header" }, h("span", { key: '8d60e0eb1cecc9c8f2091b5b8c9aefaa2aac3c91', part: "title", class: "drawer__title", id: `${this.componentId}-title` }, h("slot", { key: '26c5fb0feb42c9db7625e98f10cd5cbd0acfd742', name: "label" }, this.label || String.fromCharCode(65279))), h("six-icon-button", { key: '454ee7cea511b470ae224c6559ee99f10e9cf095', exportparts: "base:close-button", class: "drawer__close", name: "close", onClick: this.handleCloseClick }))), h("div", { key: '4f07be9128e7d2a292298b3e22ec0e5105adc3f3', part: "body", class: "drawer__body" }, h("slot", { key: '856a4bd2ee8dacc8b6124d87d8e501a8bd8c3f23' })), h("footer", { key: '721ca11e6b5470d2170d9bc929ba2d973faf9117', part: "footer", class: "drawer__footer" }, h("slot", { key: 'afb8d35c7fee0fa3e9833ea1b381c2d81f8cb5b0', name: "footer", onSlotchange: this.handleSlotChange })))));
|
|
160
166
|
}
|
|
161
167
|
static get is() { return "six-drawer"; }
|
|
162
168
|
static get encapsulation() { return "shadow"; }
|
|
@@ -387,23 +393,23 @@ export class SixDrawer {
|
|
|
387
393
|
}
|
|
388
394
|
}
|
|
389
395
|
}, {
|
|
390
|
-
"method": "
|
|
391
|
-
"name": "six-drawer-
|
|
396
|
+
"method": "sixRequestClose",
|
|
397
|
+
"name": "six-drawer-request-close",
|
|
392
398
|
"bubbles": true,
|
|
393
399
|
"cancelable": true,
|
|
394
400
|
"composed": true,
|
|
395
401
|
"docs": {
|
|
396
402
|
"tags": [],
|
|
397
|
-
"text": "Emitted when the overlay
|
|
403
|
+
"text": "Emitted when the user attempts to close the drawer by clicking the close button, clicking the overlay, or\npressing escape. Calling `event.preventDefault()` will keep the drawer open. Avoid using this unless closing\nthe drawer will result in destructive behavior such as data loss."
|
|
398
404
|
},
|
|
399
405
|
"complexType": {
|
|
400
|
-
"original": "
|
|
401
|
-
"resolved": "
|
|
406
|
+
"original": "SixDrawerRequestClose",
|
|
407
|
+
"resolved": "SixDrawerRequestClose",
|
|
402
408
|
"references": {
|
|
403
|
-
"
|
|
404
|
-
"location": "
|
|
405
|
-
"path": "
|
|
406
|
-
"id": "src/
|
|
409
|
+
"SixDrawerRequestClose": {
|
|
410
|
+
"location": "local",
|
|
411
|
+
"path": "/home/runner/work/six-webcomponents/six-webcomponents/libraries/ui-library/src/components/six-drawer/six-drawer.tsx",
|
|
412
|
+
"id": "src/components/six-drawer/six-drawer.tsx::SixDrawerRequestClose"
|
|
407
413
|
}
|
|
408
414
|
}
|
|
409
415
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"six-drawer.js","sourceRoot":"","sources":["../../../src/components/six-drawer/six-drawer.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,OAAO,EAAE,KAAK,EAAgB,CAAC,EAAE,MAAM,EAAE,IAAI,EAAE,KAAK,EAAE,KAAK,EAAE,MAAM,eAAe,CAAC;AACvG,OAAO,EAAE,iBAAiB,EAAE,mBAAmB,EAAE,MAAM,oBAAoB,CAAC;AAC5E,OAAO,EAAE,OAAO,EAAE,MAAM,kBAAkB,CAAC;AAC3C,OAAO,KAAK,MAAM,mBAAmB,CAAC;AAGtC,IAAI,EAAE,GAAG,CAAC,CAAC;AAEX;;;;;;;;;;;;;;;;;;GAkBG;AAOH,MAAM,OAAO,SAAS;IALtB;QAMU,gBAAW,GAAG,UAAU,EAAE,EAAE,EAAE,CAAC;QAI/B,aAAQ,GAAG,KAAK,CAAC;QACjB,aAAQ,GAAG,KAAK,CAAC;QAIhB,cAAS,GAAG,KAAK,CAAC;QAClB,cAAS,GAAG,KAAK,CAAC;QAE3B,+FAA+F;QACvD,SAAI,GAAG,KAAK,CAAC;QAErD;;;WAGG;QACK,UAAK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AQ,CAAC,CAAC,CAAC,IAAI,EACpE,QAAQ,EAAE,CAAC;gBAEV,CAAC,IAAI,CAAC,QAAQ,IAAI,CACjB,+DAAQ,IAAI,EAAC,QAAQ,EAAC,KAAK,EAAC,gBAAgB;oBAC1C,6DAAM,IAAI,EAAC,OAAO,EAAC,KAAK,EAAC,eAAe,EAAC,EAAE,EAAE,GAAG,IAAI,CAAC,WAAW,QAAQ;wBACtE,6DAAM,IAAI,EAAC,OAAO,IAEf,IAAI,CAAC,KAAK,IAAI,MAAM,CAAC,YAAY,CAAC,KAAK,CAAC,CACpC,CACF;oBACP,wEACE,WAAW,EAAC,mBAAmB,EAC/B,KAAK,EAAC,eAAe,EACrB,IAAI,EAAC,OAAO,EACZ,OAAO,EAAE,IAAI,CAAC,gBAAgB,GAC9B,CACK,CACV;gBAED,4DAAK,IAAI,EAAC,MAAM,EAAC,KAAK,EAAC,cAAc;oBACnC,8DAAQ,CACJ;gBAEN,+DAAQ,IAAI,EAAC,QAAQ,EAAC,KAAK,EAAC,gBAAgB;oBAC1C,6DAAM,IAAI,EAAC,QAAQ,EAAC,YAAY,EAAE,IAAI,CAAC,gBAAgB,GAAI,CACpD,CACL,CACF,CACP,CAAC;IACJ,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CACF","sourcesContent":["import { Component, Element, Event, EventEmitter, h, Method, Prop, State, Watch } from '@stencil/core';\nimport { lockBodyScrolling, unlockBodyScrolling } from '../../utils/scroll';\nimport { hasSlot } from '../../utils/slot';\nimport Modal from '../../utils/modal';\nimport { EmptyPayload } from '../../utils/types';\n\nlet id = 0;\n\n/**\n * @since 1.0\n * @status stable\n *\n * Forked from https://github.com/shoelace-style/shoelace version v2.0.0-beta27.\n *\n * @slot - The drawer's content.\n * @slot label - The drawer's label. Alternatively, you can use the label prop.\n * @slot footer - The drawer's footer, usually one or more buttons representing various options.\n *\n * @part base - The component's base wrapper.\n * @part overlay - The overlay.\n * @part panel - The drawer panel (where the drawer and its content is rendered).\n * @part header - The drawer header.\n * @part title - The drawer title.\n * @part close-button - The close button.\n * @part body - The drawer body.\n * @part footer - The drawer footer.\n */\n\n@Component({\n tag: 'six-drawer',\n styleUrl: 'six-drawer.scss',\n shadow: true,\n})\nexport class SixDrawer {\n private componentId = `drawer-${++id}`;\n private drawer?: HTMLElement;\n private modal?: Modal;\n private panel?: HTMLElement;\n private willShow = false;\n private willHide = false;\n\n @Element() host!: HTMLSixDrawerElement;\n\n @State() hasFooter = false;\n @State() isVisible = false;\n\n /** Indicates whether the drawer is open. You can use this in lieu of the show/hide methods. */\n @Prop({ mutable: true, reflect: true }) open = false;\n\n /**\n * The drawer's label as displayed in the header. You should always include a relevant label even when using\n * `no-header`, as it is required for proper accessibility.\n */\n @Prop() label = '';\n\n /** The direction from which the drawer will open. */\n @Prop() placement: 'top' | 'right' | 'bottom' | 'left' = 'right';\n\n /**\n * By default, the drawer slides out of its containing block (usually the viewport). To make the drawer slide out of\n * its parent element, set this prop and add `position: relative` to the parent.\n */\n @Prop() contained = false;\n\n /**\n * Removes the header. This will also remove the default close button, so please ensure you provide an easy,\n * accessible way for users to dismiss the drawer.\n */\n @Prop() noHeader = false;\n\n @Watch('open')\n handleOpenChange() {\n this.open ? this.show() : this.hide();\n }\n\n /** Emitted when the drawer opens. Calling `event.preventDefault()` will prevent it from being opened. */\n @Event({ eventName: 'six-drawer-show' }) sixShow!: EventEmitter<EmptyPayload>;\n\n /** Emitted after the drawer opens and all transitions are complete. */\n @Event({ eventName: 'six-drawer-after-show' }) sixAfterShow!: EventEmitter<EmptyPayload>;\n\n /** Emitted when the drawer closes. Calling `event.preventDefault()` will prevent it from being closed. */\n @Event({ eventName: 'six-drawer-hide' }) sixHide!: EventEmitter<EmptyPayload>;\n\n /** Emitted after the drawer closes and all transitions are complete. */\n @Event({ eventName: 'six-drawer-after-hide' }) sixAfterHide!: EventEmitter<EmptyPayload>;\n\n /**\n * Emitted when the drawer opens and the panel gains focus. Calling `event.preventDefault()` will prevent focus and\n * allow you to set it on a different element in the drawer, such as an input or button.\n */\n @Event({ eventName: 'six-drawer-initial-focus' }) sixInitialFocus!: EventEmitter<EmptyPayload>;\n\n /** Emitted when the overlay is clicked. Calling `event.preventDefault()` will prevent the drawer from closing. */\n @Event({ eventName: 'six-drawer-overlay-dismiss' }) sixOverlayDismiss!: EventEmitter<EmptyPayload>;\n\n connectedCallback() {\n this.modal = new Modal(this.host, {\n onFocusOut: () => (this.contained ? null : this.panel?.focus()),\n });\n }\n\n componentWillLoad() {\n this.handleSlotChange();\n\n // Show on init if open\n if (this.open) {\n this.show();\n // if the sidebar is open by default we need to manually reset the\n // transition variables since there will be no transition event\n this.resetTransitionVariables();\n }\n }\n\n disconnectedCallback() {\n unlockBodyScrolling(this.host);\n }\n\n /** Shows the drawer */\n @Method()\n async show() {\n if (this.willShow || this.modal == null || this.panel == null || this.drawer == null) {\n return;\n }\n const panel = this.panel;\n\n const sixShow = this.sixShow.emit();\n if (sixShow.defaultPrevented) {\n this.open = false;\n return;\n }\n\n this.willShow = true;\n this.isVisible = true;\n this.open = true;\n\n // Lock body scrolling only if the drawer isn't contained\n if (!this.contained) {\n this.modal.activate();\n lockBodyScrolling(this.host);\n }\n\n if (this.open) {\n // Wait for the next frame before setting initial focus so the dialog is technically visible\n requestAnimationFrame(() => {\n const sixInitialFocus = this.sixInitialFocus.emit();\n if (!sixInitialFocus.defaultPrevented) {\n panel.focus({ preventScroll: true });\n }\n });\n }\n }\n\n /** Hides the drawer */\n @Method()\n async hide() {\n if (this.willHide || this.modal == null) {\n return;\n }\n\n const sixHide = this.sixHide.emit();\n if (sixHide.defaultPrevented) {\n this.open = true;\n return;\n }\n\n this.willHide = true;\n this.open = false;\n this.modal.deactivate();\n\n unlockBodyScrolling(this.host);\n }\n\n private handleCloseClick = () => {\n this.hide();\n };\n\n private handleKeyDown = (event: KeyboardEvent) => {\n if (event.key === 'Escape') {\n this.hide();\n }\n };\n\n private handleOverlayClick = () => {\n const sixOverlayDismiss = this.sixOverlayDismiss.emit();\n\n if (!sixOverlayDismiss.defaultPrevented) {\n this.hide();\n }\n };\n\n private handleSlotChange = () => {\n this.hasFooter = hasSlot(this.host, 'footer');\n };\n\n private handleTransitionEnd = (event: TransitionEvent) => {\n const target = event.target as HTMLElement;\n\n // Ensure we only emit one event when the target element is no longer visible\n if (event.propertyName === 'transform' && target.classList.contains('drawer__panel')) {\n this.resetTransitionVariables();\n }\n };\n\n private resetTransitionVariables() {\n this.isVisible = this.open;\n this.willShow = false;\n this.willHide = false;\n this.open ? this.sixAfterShow.emit() : this.sixAfterHide.emit();\n }\n\n render() {\n return (\n <div\n ref={(el) => (this.drawer = el)}\n part=\"base\"\n class={{\n drawer: true,\n 'drawer--open': this.open,\n 'drawer--visible': this.isVisible,\n 'drawer--top': this.placement === 'top',\n 'drawer--right': this.placement === 'right',\n 'drawer--bottom': this.placement === 'bottom',\n 'drawer--left': this.placement === 'left',\n 'drawer--contained': this.contained,\n 'drawer--fixed': !this.contained,\n 'drawer--has-footer': this.hasFooter,\n }}\n onKeyDown={this.handleKeyDown}\n onTransitionEnd={this.handleTransitionEnd}\n >\n <div part=\"overlay\" class=\"drawer__overlay\" onClick={this.handleOverlayClick} tabIndex={-1} />\n\n <div\n ref={(el) => (this.panel = el)}\n part=\"panel\"\n class=\"drawer__panel\"\n role=\"dialog\"\n aria-modal=\"true\"\n aria-hidden={this.open ? 'false' : 'true'}\n aria-label={this.noHeader ? this.label : null}\n aria-labelledby={!this.noHeader ? `${this.componentId}-title` : null}\n tabIndex={0}\n >\n {!this.noHeader && (\n <header part=\"header\" class=\"drawer__header\">\n <span part=\"title\" class=\"drawer__title\" id={`${this.componentId}-title`}>\n <slot name=\"label\">\n {/* If there's no label, use an invisible character to prevent the heading from collapsing */}\n {this.label || String.fromCharCode(65279)}\n </slot>\n </span>\n <six-icon-button\n exportparts=\"base:close-button\"\n class=\"drawer__close\"\n name=\"close\"\n onClick={this.handleCloseClick}\n />\n </header>\n )}\n\n <div part=\"body\" class=\"drawer__body\">\n <slot />\n </div>\n\n <footer part=\"footer\" class=\"drawer__footer\">\n <slot name=\"footer\" onSlotchange={this.handleSlotChange} />\n </footer>\n </div>\n </div>\n );\n }\n}\n"]}
|
|
1
|
+
{"version":3,"file":"six-drawer.js","sourceRoot":"","sources":["../../../src/components/six-drawer/six-drawer.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,OAAO,EAAE,KAAK,EAAgB,CAAC,EAAE,MAAM,EAAE,IAAI,EAAE,KAAK,EAAE,KAAK,EAAE,MAAM,eAAe,CAAC;AACvG,OAAO,EAAE,iBAAiB,EAAE,mBAAmB,EAAE,MAAM,oBAAoB,CAAC;AAC5E,OAAO,EAAE,OAAO,EAAE,MAAM,kBAAkB,CAAC;AAC3C,OAAO,KAAK,MAAM,mBAAmB,CAAC;AAEtC,OAAO,EAAE,SAAS,EAAE,MAAM,uBAAuB,CAAC;AAMlD,IAAI,EAAE,GAAG,CAAC,CAAC;AAEX;;;;;;;;;;;;;;;;;;GAkBG;AAOH,MAAM,OAAO,SAAS;IALtB;QAMU,gBAAW,GAAG,UAAU,EAAE,EAAE,EAAE,CAAC;QAI/B,aAAQ,GAAG,KAAK,CAAC;QACjB,aAAQ,GAAG,KAAK,CAAC;QAIhB,cAAS,GAAG,KAAK,CAAC;QAClB,cAAS,GAAG,KAAK,CAAC;QAE3B,+FAA+F;QACvD,SAAI,GAAG,KAAK,CAAC;QAErD;;;WAGG;QACK,UAAK,GAAG,EAAE,CA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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CACF","sourcesContent":["import { Component, Element, Event, EventEmitter, h, Method, Prop, State, Watch } from '@stencil/core';\nimport { lockBodyScrolling, unlockBodyScrolling } from '../../utils/scroll';\nimport { hasSlot } from '../../utils/slot';\nimport Modal from '../../utils/modal';\nimport { EmptyPayload } from '../../utils/types';\nimport { animateTo } from '../../utils/animation';\n\nexport interface SixDrawerRequestClose {\n source: 'close-button' | 'keyboard' | 'overlay';\n}\n\nlet id = 0;\n\n/**\n * @since 1.0\n * @status stable\n *\n * Forked from https://github.com/shoelace-style/shoelace version v2.0.0-beta27.\n *\n * @slot - The drawer's content.\n * @slot label - The drawer's label. Alternatively, you can use the label prop.\n * @slot footer - The drawer's footer, usually one or more buttons representing various options.\n *\n * @part base - The component's base wrapper.\n * @part overlay - The overlay.\n * @part panel - The drawer panel (where the drawer and its content is rendered).\n * @part header - The drawer header.\n * @part title - The drawer title.\n * @part close-button - The close button.\n * @part body - The drawer body.\n * @part footer - The drawer footer.\n */\n\n@Component({\n tag: 'six-drawer',\n styleUrl: 'six-drawer.scss',\n shadow: true,\n})\nexport class SixDrawer {\n private componentId = `drawer-${++id}`;\n private drawer?: HTMLElement;\n private modal?: Modal;\n private panel?: HTMLElement;\n private willShow = false;\n private willHide = false;\n\n @Element() host!: HTMLSixDrawerElement;\n\n @State() hasFooter = false;\n @State() isVisible = false;\n\n /** Indicates whether the drawer is open. You can use this in lieu of the show/hide methods. */\n @Prop({ mutable: true, reflect: true }) open = false;\n\n /**\n * The drawer's label as displayed in the header. You should always include a relevant label even when using\n * `no-header`, as it is required for proper accessibility.\n */\n @Prop() label = '';\n\n /** The direction from which the drawer will open. */\n @Prop() placement: 'top' | 'right' | 'bottom' | 'left' = 'right';\n\n /**\n * By default, the drawer slides out of its containing block (usually the viewport). To make the drawer slide out of\n * its parent element, set this prop and add `position: relative` to the parent.\n */\n @Prop() contained = false;\n\n /**\n * Removes the header. This will also remove the default close button, so please ensure you provide an easy,\n * accessible way for users to dismiss the drawer.\n */\n @Prop() noHeader = false;\n\n @Watch('open')\n handleOpenChange() {\n this.open ? this.show() : this.hide();\n }\n\n /** Emitted when the drawer opens. Calling `event.preventDefault()` will prevent it from being opened. */\n @Event({ eventName: 'six-drawer-show' }) sixShow!: EventEmitter<EmptyPayload>;\n\n /** Emitted after the drawer opens and all transitions are complete. */\n @Event({ eventName: 'six-drawer-after-show' }) sixAfterShow!: EventEmitter<EmptyPayload>;\n\n /** Emitted when the drawer closes. Calling `event.preventDefault()` will prevent it from being closed. */\n @Event({ eventName: 'six-drawer-hide' }) sixHide!: EventEmitter<EmptyPayload>;\n\n /** Emitted after the drawer closes and all transitions are complete. */\n @Event({ eventName: 'six-drawer-after-hide' }) sixAfterHide!: EventEmitter<EmptyPayload>;\n\n /**\n * Emitted when the drawer opens and the panel gains focus. Calling `event.preventDefault()` will prevent focus and\n * allow you to set it on a different element in the drawer, such as an input or button.\n */\n @Event({ eventName: 'six-drawer-initial-focus' }) sixInitialFocus!: EventEmitter<EmptyPayload>;\n\n /**\n * Emitted when the user attempts to close the drawer by clicking the close button, clicking the overlay, or\n * pressing escape. Calling `event.preventDefault()` will keep the drawer open. Avoid using this unless closing\n * the drawer will result in destructive behavior such as data loss.\n */\n @Event({ eventName: 'six-drawer-request-close' }) sixRequestClose!: EventEmitter<SixDrawerRequestClose>;\n\n connectedCallback() {\n this.modal = new Modal(this.host, {\n onFocusOut: () => (this.contained ? null : this.panel?.focus()),\n });\n }\n\n componentWillLoad() {\n this.handleSlotChange();\n\n // Show on init if open\n if (this.open) {\n this.show();\n // if the sidebar is open by default we need to manually reset the\n // transition variables since there will be no transition event\n this.resetTransitionVariables();\n }\n }\n\n disconnectedCallback() {\n unlockBodyScrolling(this.host);\n }\n\n /** Shows the drawer */\n @Method()\n async show() {\n if (this.willShow || this.modal == null || this.panel == null || this.drawer == null) {\n return;\n }\n const panel = this.panel;\n\n const sixShow = this.sixShow.emit();\n if (sixShow.defaultPrevented) {\n this.open = false;\n return;\n }\n\n this.willShow = true;\n this.isVisible = true;\n this.open = true;\n\n // Lock body scrolling only if the drawer isn't contained\n if (!this.contained) {\n this.modal.activate();\n lockBodyScrolling(this.host);\n }\n\n if (this.open) {\n // Wait for the next frame before setting initial focus so the dialog is technically visible\n requestAnimationFrame(() => {\n const sixInitialFocus = this.sixInitialFocus.emit();\n if (!sixInitialFocus.defaultPrevented) {\n panel.focus({ preventScroll: true });\n }\n });\n }\n }\n\n /** Hides the drawer */\n @Method()\n async hide() {\n if (this.willHide || this.modal == null) {\n return;\n }\n\n const sixHide = this.sixHide.emit();\n if (sixHide.defaultPrevented) {\n this.open = true;\n return;\n }\n\n this.willHide = true;\n this.open = false;\n this.modal.deactivate();\n\n unlockBodyScrolling(this.host);\n }\n\n private handleCloseClick = () => {\n this.preventClose('close-button');\n };\n\n private handleKeyDown = (event: KeyboardEvent) => {\n if (event.key === 'Escape') {\n this.preventClose('keyboard');\n }\n };\n\n private handleOverlayClick = () => {\n this.preventClose('overlay');\n };\n\n private preventClose(source: 'close-button' | 'keyboard' | 'overlay') {\n const sixRequestClose = this.sixRequestClose.emit({ source });\n\n if (sixRequestClose.defaultPrevented && this.panel) {\n animateTo(this.panel, [{ scale: 1 }, { scale: 1.01 }, { scale: 1 }], { duration: 250 });\n return;\n }\n\n this.hide();\n }\n\n private handleSlotChange = () => {\n this.hasFooter = hasSlot(this.host, 'footer');\n };\n\n private handleTransitionEnd = (event: TransitionEvent) => {\n const target = event.target as HTMLElement;\n\n // Ensure we only emit one event when the target element is no longer visible\n if (event.propertyName === 'transform' && target.classList.contains('drawer__panel')) {\n this.resetTransitionVariables();\n }\n };\n\n private resetTransitionVariables() {\n this.isVisible = this.open;\n this.willShow = false;\n this.willHide = false;\n this.open ? this.sixAfterShow.emit() : this.sixAfterHide.emit();\n }\n\n render() {\n return (\n <div\n ref={(el) => (this.drawer = el)}\n part=\"base\"\n class={{\n drawer: true,\n 'drawer--open': this.open,\n 'drawer--visible': this.isVisible,\n 'drawer--top': this.placement === 'top',\n 'drawer--right': this.placement === 'right',\n 'drawer--bottom': this.placement === 'bottom',\n 'drawer--left': this.placement === 'left',\n 'drawer--contained': this.contained,\n 'drawer--fixed': !this.contained,\n 'drawer--has-footer': this.hasFooter,\n }}\n onKeyDown={this.handleKeyDown}\n onTransitionEnd={this.handleTransitionEnd}\n >\n <div part=\"overlay\" class=\"drawer__overlay\" onClick={this.handleOverlayClick} tabIndex={-1} />\n\n <div\n ref={(el) => (this.panel = el)}\n part=\"panel\"\n class=\"drawer__panel\"\n role=\"dialog\"\n aria-modal=\"true\"\n aria-hidden={this.open ? 'false' : 'true'}\n aria-label={this.noHeader ? this.label : null}\n aria-labelledby={!this.noHeader ? `${this.componentId}-title` : null}\n tabIndex={0}\n >\n {!this.noHeader && (\n <header part=\"header\" class=\"drawer__header\">\n <span part=\"title\" class=\"drawer__title\" id={`${this.componentId}-title`}>\n <slot name=\"label\">\n {/* If there's no label, use an invisible character to prevent the heading from collapsing */}\n {this.label || String.fromCharCode(65279)}\n </slot>\n </span>\n <six-icon-button\n exportparts=\"base:close-button\"\n class=\"drawer__close\"\n name=\"close\"\n onClick={this.handleCloseClick}\n />\n </header>\n )}\n\n <div part=\"body\" class=\"drawer__body\">\n <slot />\n </div>\n\n <footer part=\"footer\" class=\"drawer__footer\">\n <slot name=\"footer\" onSlotchange={this.handleSlotChange} />\n </footer>\n </div>\n </div>\n );\n }\n}\n"]}
|
|
@@ -482,19 +482,19 @@ export class SixDropdown {
|
|
|
482
482
|
}
|
|
483
483
|
}
|
|
484
484
|
render() {
|
|
485
|
-
return (h("div", { key: '
|
|
485
|
+
return (h("div", { key: '46305375a199fb17ae66ca3b6678634844d0b8a2', part: "base", id: this.componentId, class: {
|
|
486
486
|
dropdown: true,
|
|
487
487
|
'dropdown--open': this.open,
|
|
488
|
-
} }, h("span", { key: '
|
|
488
|
+
} }, h("span", { key: '2a53d2cf2b75607614f39675cabfe1362b297e70', part: "trigger", class: "dropdown__trigger", ref: (el) => (this.trigger = el), onClick: this.handleTriggerClick, onKeyDown: this.handleTriggerKeyDown, onKeyUp: this.handleTriggerKeyUp }, h("slot", { key: 'd8abcd455c768fded48df4c18b8191e365db4ab1', name: "trigger", ref: (el) => (this.triggerSlot = el), onSlotchange: this.handleTriggerSlotChange })), h("div", { key: 'fd0e0352800daebdc9843442901cad9769d3199a', ref: (el) => (this.positioner = el), class: {
|
|
489
489
|
dropdown__positioner: true,
|
|
490
490
|
dropdown__positioner__filtered: (this.filter || this.asyncFilter) && !this.hoist,
|
|
491
|
-
} }, h("div", { key: '
|
|
491
|
+
} }, h("div", { key: '2d72ca0ba1a5cbb480727e325048f7a171fb7af8', ref: (el) => (this.panel = el), part: "panel", class: "dropdown__panel", role: "menu", "aria-hidden": this.open ? 'false' : 'true', "aria-labelledby": this.componentId }, this.filterEnabled && (h("six-input", { key: 'a22263fb924be51081598579391774c82a09852f', class: {
|
|
492
492
|
filter: true,
|
|
493
493
|
'filter-hidden': !this.open,
|
|
494
|
-
}, "dropdown-search": true, "aria-hidden": this.open ? 'false' : 'true', ref: (el) => (this.filterInputElement = el), placeholder: this.filterPlaceholder }, h("six-icon", { key: '
|
|
494
|
+
}, "dropdown-search": true, "aria-hidden": this.open ? 'false' : 'true', ref: (el) => (this.filterInputElement = el), placeholder: this.filterPlaceholder }, h("six-icon", { key: '7a8fc9e25e7e209b5b0aa05af5dcefca87e3b9d5', class: "filter__icon", slot: "suffix", size: "small" }, "search"))), h("div", { key: 'bedcab39d656be8ce064852ef9344b4fbbf60b17', class: {
|
|
495
495
|
dropdown__panel__scroll: true,
|
|
496
496
|
'dropdown__panel__scroll--virtual': this.virtualScroll,
|
|
497
|
-
}, onScroll: this.handleDropdownScroll, ref: (el) => (this.scrollPanel = el) }, h("slot", { key: '
|
|
497
|
+
}, onScroll: this.handleDropdownScroll, ref: (el) => (this.scrollPanel = el) }, h("slot", { key: '21acba56de1fba98afdfda60e8b09816a70ac057', ref: (el) => (this.panelSlot = el) }), this.options.length > 0 && (h("six-menu", { key: 'd7d429d062bf111ffdaf667ada0efe640136871a', part: "menu", items: this.renderedOptions, virtualScroll: this.virtualScroll }))), h("slot", { key: 'e23be3aa659ed7fa4a513d82c982733b58a6e9db', name: "dropdown-footer" })))));
|
|
498
498
|
}
|
|
499
499
|
static get is() { return "six-dropdown"; }
|
|
500
500
|
static get encapsulation() { return "shadow"; }
|
|
@@ -30,10 +30,10 @@ export class SixFileListItem {
|
|
|
30
30
|
};
|
|
31
31
|
}
|
|
32
32
|
render() {
|
|
33
|
-
return (h("div", { key: '
|
|
33
|
+
return (h("div", { key: '31722bec6e2a0956f4d1b14c7ee26330cae7e8cc', class: "six-files-list-item" }, h("span", { key: 'dfa90db55fd78720884ac4f67e5579b0eb184d40', class: {
|
|
34
34
|
'six-files-list-item__name': true,
|
|
35
35
|
'six-files-list-item__name--disabled': this.nodownload,
|
|
36
|
-
}, onClick: this.downloadFile }, this.name), h("span", { key: '
|
|
36
|
+
}, onClick: this.downloadFile }, this.name), h("span", { key: '401f4ef61bd59467c074dcdd1b1393724b56b30f', class: "six-files-list-item__date" }, this.date), this.size != null && h("span", { key: 'c9a2df206e02dfe5187f072c59e2c9d4cb59bf19', class: "six-files-list-item__size" }, Math.round(this.size / 1024), " KB"), h("six-icon", { key: '85857613cb52b6cc117e983573dfa27cd6e78c15', class: {
|
|
37
37
|
'six-files-list-item__icon': true,
|
|
38
38
|
'six-files-list-item__icon--disabled': this.nodelete,
|
|
39
39
|
}, size: "small", onClick: this.removeFile }, "delete")));
|
|
@@ -121,17 +121,17 @@ export class SixFileUpload {
|
|
|
121
121
|
render() {
|
|
122
122
|
const Container = this.compact ? 'six-button' : 'six-card';
|
|
123
123
|
const errorMessages = (Array.isArray(this.errorText) ? this.errorText : [this.errorText]).filter((text) => text != null && text.trim() !== '');
|
|
124
|
-
return (h("div", { key: '
|
|
124
|
+
return (h("div", { key: '5e0eadc451195cb2c4d5c4f383e1a27b19a80dc4', class: {
|
|
125
125
|
'six-file-upload': true,
|
|
126
126
|
'six-file-upload--disabled': this.disabled || this.uploading,
|
|
127
|
-
} }, h(Container, { key: '
|
|
127
|
+
} }, h(Container, { key: '16c443d8a887a3098cc04956bc607577ac3630b0', disabled: this.disabled || this.uploading, "aria-invalid": this.invalid ? 'true' : 'false', class: {
|
|
128
128
|
'six-file-upload__container--compact': this.compact,
|
|
129
129
|
'six-file-upload__container--full': !this.compact,
|
|
130
|
-
} }, this.compact && !this.uploading && h("six-icon", { key: '
|
|
130
|
+
} }, this.compact && !this.uploading && h("six-icon", { key: '9fe02f54c63e61928f0c1f5886982f568b926d0d', slot: "prefix" }, "arrow_circle_up"), h("div", { key: '45350fcd292a61ddc6997019448b41d4bc94d5c8', class: {
|
|
131
131
|
'six-file-upload__drop-zone': true,
|
|
132
132
|
'six-file-upload__drop-zone--hover': this.isOver,
|
|
133
133
|
'six-file-upload__drop-zone--compact': this.compact,
|
|
134
|
-
} }, this.uploading ? (h("span", { class: "six-file-upload__drop-zone__spinner-container" }, h("six-spinner", null), " Uploading...")) : (h("div", null, h("span", null, this.renderLabel()), h("input", { class: "six-file-upload__input", type: "file", name: "resume", disabled: this.disabled, accept: this.accept, multiple: this.multiple, onChange: this.onChange, ref: (el) => (this.fileInput = el) }))))), h("div", { key: '
|
|
134
|
+
} }, this.uploading ? (h("span", { class: "six-file-upload__drop-zone__spinner-container" }, h("six-spinner", null), " Uploading...")) : (h("div", null, h("span", null, this.renderLabel()), h("input", { class: "six-file-upload__input", type: "file", name: "resume", disabled: this.disabled, accept: this.accept, multiple: this.multiple, onChange: this.onChange, ref: (el) => (this.fileInput = el) }))))), h("div", { key: 'f5aa7f521d1ef6b2af5c23b697fa1014c87e1827', "aria-hidden": this.invalid ? 'false' : 'true' }, h("slot", { key: 'ab2f2bf8bf27b3c67304b61c491e5ab73e76398f', name: "error-text" }, errorMessages.map((text) => (h("six-error", null, h("div", { class: "six-file-upload__error-text" }, text))))))));
|
|
135
135
|
}
|
|
136
136
|
static get is() { return "six-file-upload"; }
|
|
137
137
|
static get encapsulation() { return "scoped"; }
|
|
@@ -213,7 +213,7 @@ export class SixInput {
|
|
|
213
213
|
return ((_a = this.value) !== null && _a !== void 0 ? _a : '').toString();
|
|
214
214
|
}
|
|
215
215
|
render() {
|
|
216
|
-
return (h(FormControl, { key: '
|
|
216
|
+
return (h(FormControl, { key: 'b88afe1aa2622eee58a8d66257cc5a0983354b25', inputId: this.inputId, label: this.label, labelId: this.labelId, hasLabelSlot: this.hasLabelSlot, helpTextId: this.helpTextId, helpText: this.helpText, hasHelpTextSlot: this.hasHelpTextSlot, errorTextId: this.errorTextId, errorText: this.errorText, errorTextCount: this.errorTextCount, hasErrorTextSlot: this.hasErrorSlot, size: this.size, disabled: this.disabled, required: this.required, displayError: this.invalid }, h("div", { key: 'b07352c5f2d4480a4b2919854e154faeac2d9f0f', part: "base", class: {
|
|
217
217
|
input: true,
|
|
218
218
|
// Sizes
|
|
219
219
|
'input--small': this.size === 'small',
|
|
@@ -227,10 +227,10 @@ export class SixInput {
|
|
|
227
227
|
'input--focused': this.hasFocus,
|
|
228
228
|
'input--empty': this.getValue().length === 0,
|
|
229
229
|
'input--invalid': this.invalid,
|
|
230
|
-
} }, h("span", { key: '
|
|
230
|
+
} }, h("span", { key: '37acf6498894ed16984dc35615387a9d7cb634d3', part: "prefix", class: "input__prefix" }, h("slot", { key: '88e70802193d8925f03d58ea964a0bb9034a74ab', name: "prefix" })), h("input", { key: 'bdeabe4cc23fc68a3a9c25307cf37ca2d77d6a5f', part: "input", ref: (el) => (this.nativeInput = el), id: this.inputId, size: 1, class: {
|
|
231
231
|
input__control: true,
|
|
232
232
|
input__control__prefix: hasSlot(this.host, 'prefix'),
|
|
233
|
-
}, type: this.type === 'password' && this.isPasswordVisible ? 'text' : this.type, name: this.name, placeholder: this.placeholder, disabled: this.disabled, readonly: this.readonly, minLength: this.minlength, maxLength: this.maxlength, min: this.min, max: this.max, step: this.step, value: this.getValue(), autoCapitalize: this.autocapitalize, autoComplete: this.autocomplete, autoCorrect: this.autocorrect, autoFocus: this.autofocus, spellcheck: this.spellcheck, pattern: this.pattern, required: this.required, inputMode: this.inputmode, "aria-labelledby": this.labelId, "aria-describedby": this.helpTextId, "aria-invalid": this.invalid ? 'true' : 'false', onChange: this.handleChange, onInput: this.handleInput, onFocus: this.handleFocus, onBlur: this.handleBlur, onKeyDown: this.handleKeyDown, "data-testid": "input-control" }), this.clearable && !this.disabled && (h("button", { key: '
|
|
233
|
+
}, type: this.type === 'password' && this.isPasswordVisible ? 'text' : this.type, name: this.name, placeholder: this.placeholder, disabled: this.disabled, readonly: this.readonly, minLength: this.minlength, maxLength: this.maxlength, min: this.min, max: this.max, step: this.step, value: this.getValue(), autoCapitalize: this.autocapitalize, autoComplete: this.autocomplete, autoCorrect: this.autocorrect, autoFocus: this.autofocus, spellcheck: this.spellcheck, pattern: this.pattern, required: this.required, inputMode: this.inputmode, "aria-labelledby": this.labelId, "aria-describedby": this.helpTextId, "aria-invalid": this.invalid ? 'true' : 'false', onChange: this.handleChange, onInput: this.handleInput, onFocus: this.handleFocus, onBlur: this.handleBlur, onKeyDown: this.handleKeyDown, "data-testid": "input-control" }), this.clearable && !this.disabled && (h("button", { key: 'e7f5713eec0bf5bd6b69335f60793071309770dc', part: "clear-button", class: "input__clear", type: "button", onClick: this.handleClearClick, tabindex: "-1", "data-testid": "input-clear-button" }, h("slot", { key: '9cef48b67afbb2a833a7dff0ffa3b8ce153c11b2', name: "clear-icon" }, h("six-icon", { key: 'fa08350fb58063c871ef9f64d3d3d5a9dd8fbdec', size: ICON_SIZES[this.size] }, "clear")))), this.togglePassword && (h("button", { key: 'aacef765fcbc09b9479737d620568a5f78a884e5', part: "password-toggle-button", class: "input__password-toggle", type: "button", onClick: this.handlePasswordToggle, tabindex: "-1" }, this.isPasswordVisible ? (h("slot", { name: "show-password-icon" }, h("six-icon", { size: ICON_SIZES[this.size] }, "visibility_off"))) : (h("slot", { name: "hide-password-icon" }, h("six-icon", { size: ICON_SIZES[this.size] }, "visibility"))))), h("span", { key: '0e8461e5897ab4380f67e207d1c1f3d9065b00b7', part: "suffix", class: "input__suffix" }, h("slot", { key: 'a7634ecf343884a7197b2edb82a55863af8faf5b', name: "suffix" })))));
|
|
234
234
|
}
|
|
235
235
|
static get is() { return "six-input"; }
|
|
236
236
|
static get encapsulation() { return "shadow"; }
|
|
@@ -44,7 +44,7 @@ export class SixLanguageSwitcher {
|
|
|
44
44
|
}
|
|
45
45
|
}
|
|
46
46
|
render() {
|
|
47
|
-
return (h("div", { key: '
|
|
47
|
+
return (h("div", { key: '4e324d4503e9d65278e4b3c55025363a685d9a69', part: "container", class: "language-switcher__container" }, this.languages.map((lang, index) => {
|
|
48
48
|
const language = typeof lang === 'string' ? lang : lang.key;
|
|
49
49
|
return (h("div", { onClick: this.handleLanguageSwitching(language, typeof lang === 'string' ? lang : lang.value), onKeyDown: (e) => {
|
|
50
50
|
if (e.key === 'Enter' || e.key === ' ') {
|
|
@@ -245,10 +245,10 @@ export class SixMenu {
|
|
|
245
245
|
.map(({ value, label }) => (h("six-menu-item", { checkType: "check", key: value, value: value }, label)));
|
|
246
246
|
}
|
|
247
247
|
render() {
|
|
248
|
-
return (h("div", { key: '
|
|
248
|
+
return (h("div", { key: '64f48c7033d88a86327d7c1134c0b07d7d86a7c9', ref: (el) => (this.menuWrapper = el), style: this.getMenuWrapperStyle(), part: "wrapper", class: {
|
|
249
249
|
menu: true,
|
|
250
250
|
'.no-shadow': this.removeBoxShadow,
|
|
251
|
-
} }, h("div", { key: '
|
|
251
|
+
} }, h("div", { key: '8cfbdca4fce2dd79c5c44485c441415984c889f3', ref: (el) => (this.menu = el), part: "base", role: "menu", onClick: this.handleClick, onKeyDown: this.handleKeyDown, tabIndex: 0, style: this.getMenuContainerStyle() }, h("slot", { key: '02465176c43a16b3b4801cca8d0e2b1f928eda22' }), this.renderItems()), this.virtualScroll && h("div", { key: 'fdfb7c58a92cc3d922aba5e7f47a94a861e47c7b', style: this.getScrollbarGhostStyle() })));
|
|
252
252
|
}
|
|
253
253
|
static get is() { return "six-menu"; }
|
|
254
254
|
static get encapsulation() { return "shadow"; }
|
|
@@ -45,7 +45,7 @@ export class SixSearchField {
|
|
|
45
45
|
this.eventListeners.removeAll();
|
|
46
46
|
}
|
|
47
47
|
render() {
|
|
48
|
-
return (h("div", { key: '
|
|
48
|
+
return (h("div", { key: '9172dbb88cc35be7390727842483a74241e1330f', class: "search-box" }, h("six-input", { key: '44c1d20960202129a19cb412bb67823ac927ad98', ref: (el) => (this.inputElement = el), placeholder: this.placeholder, value: this.value, disabled: this.disabled, clearable: this.clearable }, h("six-icon", { key: 'af8431bd85223a37fee7e17d51288313c4494fed', class: "search-box__icon", slot: "prefix", size: "small", onClick: this.handleInputChange }, "search")), h("slot", { key: '5d4f9bf280fc5fe215c268818b641753bb786869' })));
|
|
49
49
|
}
|
|
50
50
|
static get is() { return "six-search-field"; }
|
|
51
51
|
static get encapsulation() { return "shadow"; }
|
|
@@ -450,7 +450,7 @@ export class SixSelect {
|
|
|
450
450
|
showClear = true;
|
|
451
451
|
showExpand = false;
|
|
452
452
|
}
|
|
453
|
-
return (h(FormControl, { key: '
|
|
453
|
+
return (h(FormControl, { key: '9312ec8e2cedbb88f1404d6ddb2f8e67a952f6da', inputId: this.inputId, label: this.label, labelId: this.labelId, hasLabelSlot: this.hasLabelSlot, helpTextId: this.helpTextId, helpText: this.helpText, hasHelpTextSlot: this.hasHelpTextSlot, errorTextId: this.errorTextId, errorText: this.errorText, errorTextCount: this.errorTextCount, hasErrorTextSlot: this.hasErrorTextSlot, size: this.size, onLabelClick: this.handleLabelClick, disabled: this.disabled, required: this.required, displayError: this.invalid }, h("six-dropdown", { key: '77887d36593e973b83d80aec7fcb51c9f85d9d0c', part: "base", ref: (el) => (this.dropdown = el), hoist: this.hoist, matchTriggerWidth: true, closeOnSelect: !this.multiple, containingElement: this.host, disableHideOnEnterAndSpace: this.autocomplete, class: {
|
|
454
454
|
select: true,
|
|
455
455
|
'select--open': this.isOpen,
|
|
456
456
|
'select--empty': ((_a = this.value) === null || _a === void 0 ? void 0 : _a.length) === 0,
|
|
@@ -465,20 +465,20 @@ export class SixSelect {
|
|
|
465
465
|
'select--large': this.size === 'large',
|
|
466
466
|
'select--pill': this.pill,
|
|
467
467
|
'select--invalid': this.invalid,
|
|
468
|
-
}, onKeyDown: this.handleKeyDown, "onSix-dropdown-show": this.handleMenuShow, "onSix-dropdown-hide": this.handleMenuHide, filterPlaceholder: this.filterPlaceholder, filterDebounce: this.filterDebounce, filter: this.filter, asyncFilter: this.asyncFilter, virtualScroll: this.virtualScroll }, h("div", { key: '
|
|
468
|
+
}, onKeyDown: this.handleKeyDown, "onSix-dropdown-show": this.handleMenuShow, "onSix-dropdown-hide": this.handleMenuHide, filterPlaceholder: this.filterPlaceholder, filterDebounce: this.filterDebounce, filter: this.filter, asyncFilter: this.asyncFilter, virtualScroll: this.virtualScroll }, h("div", { key: 'afddffa7f575127a3c53b2bd23f996809adb9844', slot: "trigger", ref: (el) => (this.box = el), id: this.inputId, class: {
|
|
469
469
|
select__box: true,
|
|
470
470
|
'select__box--line': this.line,
|
|
471
471
|
'select__box--autocomplete': this.autocomplete,
|
|
472
|
-
}, role: "combobox", "aria-labelledby": this.labelId, "aria-describedby": this.helpTextId, "aria-haspopup": "true", "aria-expanded": this.isOpen ? 'true' : 'false', tabIndex: this.disabled ? -1 : 0, onBlur: this.handleBlur, onFocus: this.handleFocus }, h("div", { key: '
|
|
472
|
+
}, role: "combobox", "aria-labelledby": this.labelId, "aria-describedby": this.helpTextId, "aria-haspopup": "true", "aria-expanded": this.isOpen ? 'true' : 'false', tabIndex: this.disabled ? -1 : 0, onBlur: this.handleBlur, onFocus: this.handleFocus }, h("div", { key: '21b0e4ccb4535037e197b7dbd9a23f0bc37cf5f8', class: "display__values", ref: (el) => (this.displayValuesContainer = el) }, this.displayedValues.length > 0 ? (h("span", { class: "display__values-and-counter" }, h("span", { class: "display__values-values" }, this.displayedValues.map((value) => (h("span", { key: value, class: "display-value" }, value, h("span", { class: { separator: true } }, ", "))))), h("span", { ref: (el) => (this.overflowCount = el), class: "overflow-count" }, "+10"))) : (h("span", { class: "placeholder" }, this.placeholder))), showClear && (h("six-icon-button", { key: '4dfa510d19ed31997002b1eefff2e467a34b5fd0', exportparts: "base:clear-button", class: "select__clear", name: "clear", size: "small", onClick: this.handleClearClick, tabindex: "-1" })), showExpand && (h("span", { key: 'f03b60a3935c809d9f98342ad7b27698abaf537c', part: "icon", class: "select__icon" }, h("six-icon", { key: '271b8b90377be367a38abe77df0b5ae60960b9a8', size: "medium" }, "expand_more"))), h("six-input", { key: '0a8a3e663dd316f38e0d62625cd6c824022b0fd1', ref: (el) => (this.autocompleteInput = el), class: {
|
|
473
473
|
select__input: true,
|
|
474
474
|
'sr-only': !this.autocomplete,
|
|
475
|
-
}, "aria-hidden": "true", required: this.required, onFocus: this.handleFocus, clearable: this.clearable, placeholder: this.placeholder, pill: this.pill, disabled: this.disabled, size: this.size, tabIndex: -1 })), h("div", { key: '
|
|
475
|
+
}, "aria-hidden": "true", required: this.required, onFocus: this.handleFocus, clearable: this.clearable, placeholder: this.placeholder, pill: this.pill, disabled: this.disabled, size: this.size, tabIndex: -1 })), h("div", { key: 'a5fe2da3ed21d2e8cacbeb84ada7538f960b182e', class: {
|
|
476
476
|
'selection-container': true,
|
|
477
477
|
'selection-container--border': this.selectionContainerItems.length > 0 && items.length !== this.selectionContainerItems.length,
|
|
478
|
-
} }, this.selectionContainerItems), h("six-menu", { key: '
|
|
478
|
+
} }, this.selectionContainerItems), h("six-menu", { key: 'ba0c95940b5af32bdd1a8f5f65e4ea6f81ee5bb1', ref: (el) => (this.menu = el), part: "menu", class: {
|
|
479
479
|
select__menu: true,
|
|
480
480
|
'select__menu--hidden': !hasMenuItems,
|
|
481
|
-
}, "onSix-menu-item-selected": this.handleMenuSelect, items: this.options, virtualScroll: this.virtualScroll, "remove-box-shadow": true, "disable-keyboard-handling": true }, h("slot", { key: '
|
|
481
|
+
}, "onSix-menu-item-selected": this.handleMenuSelect, items: this.options, virtualScroll: this.virtualScroll, "remove-box-shadow": true, "disable-keyboard-handling": true }, h("slot", { key: 'f6be5fd5f9070395df4e165f0f912d274ffcc4b5', onSlotchange: this.handleSlotChange })), this.multiple && this.selectAllButton && (h("div", { key: 'bc6fe23ff6e09d9cb1c9709dc78199600d08cb3f', class: "select-all", slot: "dropdown-footer" }, h("six-button", { key: '4ac03af8a7233ed46ac2d9e4ed515a79387a2d2b', type: "link", onClick: () => this.selectAll() }, this.selectAllText == null ? selectAllDefaultText(hasDeselectedOptions) : this.selectAllText))))));
|
|
482
482
|
}
|
|
483
483
|
hasSelection() {
|
|
484
484
|
return this.multiple ? this.value.length > 0 : this.value !== '';
|
|
@@ -55,6 +55,18 @@
|
|
|
55
55
|
.tab:hover:not(.tab--disabled) {
|
|
56
56
|
color: var(--six-tab-color-hover);
|
|
57
57
|
}
|
|
58
|
+
.tab.tab--left, .tab.tab--right {
|
|
59
|
+
display: inline-block;
|
|
60
|
+
text-align: left;
|
|
61
|
+
}
|
|
62
|
+
.tab.tab--left::before, .tab.tab--right::before {
|
|
63
|
+
display: block;
|
|
64
|
+
font-weight: var(--six-font-weight-bold);
|
|
65
|
+
content: attr(title);
|
|
66
|
+
height: 0;
|
|
67
|
+
overflow: hidden;
|
|
68
|
+
visibility: hidden;
|
|
69
|
+
}
|
|
58
70
|
|
|
59
71
|
.tab__close-button {
|
|
60
72
|
font-size: var(--six-font-size-large);
|
|
@@ -45,7 +45,7 @@ export class SixTab {
|
|
|
45
45
|
const placement = (_a = tabGroup === null || tabGroup === void 0 ? void 0 : tabGroup.placement) !== null && _a !== void 0 ? _a : 'top';
|
|
46
46
|
return (
|
|
47
47
|
// If the user didn't provide an ID, we'll set one, so we can link tabs and tab panels with aria labels
|
|
48
|
-
h(Host, { key: '6b59af3a0794c9ea26b362fa1ea1c0d7513babea', id: this.host.id || this.componentId }, h("div", { key: '
|
|
48
|
+
h(Host, { key: '6b59af3a0794c9ea26b362fa1ea1c0d7513babea', id: this.host.id || this.componentId }, h("div", { key: '145b15cdb916d93ecb67a966fd558e37500db17c', part: "base", ref: (el) => (this.tab = el), class: {
|
|
49
49
|
tab: true,
|
|
50
50
|
// Placements
|
|
51
51
|
'tab--top': placement === 'top',
|
|
@@ -56,7 +56,7 @@ export class SixTab {
|
|
|
56
56
|
'tab--active': this.active,
|
|
57
57
|
'tab--closable': this.closable,
|
|
58
58
|
'tab--disabled': this.disabled,
|
|
59
|
-
}, role: "tab", "aria-disabled": this.disabled ? 'true' : 'false', "aria-selected": this.active ? 'true' : 'false', tabindex: this.disabled || !this.active ? '-1' : '0' }, h("slot", { key: '
|
|
59
|
+
}, role: "tab", "aria-disabled": this.disabled ? 'true' : 'false', "aria-selected": this.active ? 'true' : 'false', tabindex: this.disabled || !this.active ? '-1' : '0', title: this.host.innerHTML }, h("slot", { key: '2a63428f882a98381746e578c98421cf7d065a16' }), this.closable && (h("six-icon-button", { key: 'dc0dbb47462d86dfae7b6806b667d6af69094f31', name: "close", size: "xSmall", exportparts: "base:close-button", class: "tab__close-button", onClick: this.handleCloseClick, tabIndex: -1, "aria-hidden": "true" }))), h("div", { key: '62bb67bb6a95d732e0961f349ada6f7d78a2e3a1', part: this.active ? 'active-tab-indicator' : '', class: {
|
|
60
60
|
tab__indicator: true,
|
|
61
61
|
'tab__indicator--active': this.active,
|
|
62
62
|
// Placements
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"six-tab.js","sourceRoot":"","sources":["../../../src/components/six-tab/six-tab.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,OAAO,EAAE,KAAK,EA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IAAI,CAAC,SAAS;gBAE1B,8DAAQ;gBACP,IAAI,CAAC,QAAQ,IAAI,CAChB,wEACE,IAAI,EAAC,OAAO,EACZ,IAAI,EAAC,QAAQ,EACb,WAAW,EAAC,mBAAmB,EAC/B,KAAK,EAAC,mBAAmB,EACzB,OAAO,EAAE,IAAI,CAAC,gBAAgB,EAC9B,QAAQ,EAAE,CAAC,CAAC,iBACA,MAAM,GAClB,CACH,CACG;YACN,4DACE,IAAI,EAAE,IAAI,CAAC,MAAM,CAAC,CAAC,CAAC,sBAAsB,CAAC,CAAC,CAAC,EAAE,EAC/C,KAAK,EAAE;oBACL,cAAc,EAAE,IAAI;oBACpB,wBAAwB,EAAE,IAAI,CAAC,MAAM;oBAErC,aAAa;oBACb,qBAAqB,EAAE,SAAS,KAAK,KAAK;oBAC1C,wBAAwB,EAAE,SAAS,KAAK,QAAQ;oBAChD,sBAAsB,EAAE,SAAS,KAAK,MAAM;oBAC5C,uBAAuB,EAAE,SAAS,KAAK,OAAO;iBAC/C,GACI,CACF,CACR,CAAC;IACJ,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CACF","sourcesContent":["import { Component, Element, Event, EventEmitter, h, Host, Method, Prop } from '@stencil/core';\nimport { EmptyPayload } from '../../utils/types';\n\nlet id = 0;\n\n/**\n * @since 1.0\n * @status stable\n *\n * Forked from https://github.com/shoelace-style/shoelace version v2.0.0-beta27.\n *\n * @slot - The tab's label.\n *\n * @part base - The component's base wrapper.\n * @part close-button - The close button, which is the icon button's base wrapper.\n */\n\n@Component({\n tag: 'six-tab',\n styleUrl: 'six-tab.scss',\n shadow: true,\n})\nexport class SixTab {\n private componentId = `tab-${++id}`;\n private tab?: HTMLElement;\n\n @Element() host!: HTMLSixTabElement;\n\n /** The name of the tab panel the tab will control. The panel must be located in the same tab group. */\n @Prop({ reflect: true }) panel = '';\n\n /** Set to true to draw the tab in an active state. */\n @Prop({ reflect: true }) active = false;\n\n /** When true, the tab will be rendered with a close icon. */\n @Prop() closable = false;\n\n /** Set to true to draw the tab in a disabled state. */\n @Prop({ reflect: true }) disabled = false;\n\n /** Emitted when the tab is closable and the close button is activated. */\n @Event({ eventName: 'six-tab-close' }) sixClose!: EventEmitter<EmptyPayload>;\n\n connectedCallback() {\n this.handleCloseClick = this.handleCloseClick.bind(this);\n }\n\n /** Sets focus to the tab. */\n @Method()\n async setFocus(options?: FocusOptions) {\n this.tab?.focus(options);\n }\n\n /** Removes focus from the tab. */\n @Method()\n async removeFocus() {\n this.tab?.blur();\n }\n\n private handleCloseClick() {\n this.sixClose.emit();\n }\n\n render() {\n const tabGroup: HTMLSixTabGroupElement | null = this.host.closest('six-tab-group');\n const placement = tabGroup?.placement ?? 'top';\n return (\n // If the user didn't provide an ID, we'll set one, so we can link tabs and tab panels with aria labels\n <Host id={this.host.id || this.componentId}>\n <div\n part=\"base\"\n ref={(el) => (this.tab = el)}\n class={{\n tab: true,\n\n // Placements\n 'tab--top': placement === 'top',\n 'tab--bottom': placement === 'bottom',\n 'tab--left': placement === 'left',\n 'tab--right': placement === 'right',\n\n // States\n 'tab--active': this.active,\n 'tab--closable': this.closable,\n 'tab--disabled': this.disabled,\n }}\n role=\"tab\"\n aria-disabled={this.disabled ? 'true' : 'false'}\n aria-selected={this.active ? 'true' : 'false'}\n tabindex={this.disabled || !this.active ? '-1' : '0'}\n title={this.host.innerHTML}\n >\n <slot />\n {this.closable && (\n <six-icon-button\n name=\"close\"\n size=\"xSmall\"\n exportparts=\"base:close-button\"\n class=\"tab__close-button\"\n onClick={this.handleCloseClick}\n tabIndex={-1}\n aria-hidden=\"true\"\n />\n )}\n </div>\n <div\n part={this.active ? 'active-tab-indicator' : ''}\n class={{\n tab__indicator: true,\n 'tab__indicator--active': this.active,\n\n // Placements\n 'tab__indicator--top': placement === 'top',\n 'tab__indicator--bottom': placement === 'bottom',\n 'tab__indicator--left': placement === 'left',\n 'tab__indicator--right': placement === 'right',\n }}\n ></div>\n </Host>\n );\n }\n}\n"]}
|
|
@@ -228,7 +228,7 @@ export class SixTabGroup {
|
|
|
228
228
|
});
|
|
229
229
|
}
|
|
230
230
|
render() {
|
|
231
|
-
return (h("div", { key: '
|
|
231
|
+
return (h("div", { key: '56aaa11f3101ba44544017ee7f881ec20d779b40', part: "base", ref: (el) => (this.tabGroup = el), class: {
|
|
232
232
|
'tab-group': true,
|
|
233
233
|
// Placements
|
|
234
234
|
'tab-group--top': this.placement === 'top',
|
|
@@ -236,7 +236,7 @@ export class SixTabGroup {
|
|
|
236
236
|
'tab-group--left': this.placement === 'left',
|
|
237
237
|
'tab-group--right': this.placement === 'right',
|
|
238
238
|
'tab-group--has-scroll-controls': this.hasRightControl || this.hasLeftControl,
|
|
239
|
-
}, onClick: this.handleClick, onKeyDown: this.handleKeyDown }, h("div", { key: '
|
|
239
|
+
}, onClick: this.handleClick, onKeyDown: this.handleKeyDown }, h("div", { key: '439df915243867dc2b8b6fa6b508d99f5dbed623', class: "tab-group__nav-container" }, this.hasLeftControl && (h("six-icon-button", { key: '4921d96aea14fc6ee904b5f56c115fc9dd00c6fa', class: "tab-group__scroll-button tab-group__scroll-button--left", exportparts: "base:scroll-button", name: "chevron_left", onClick: this.handleScrollLeft })), h("div", { ref: (el) => (this.nav = el), key: "nav", part: "nav", class: "tab-group__nav" }, h("div", { key: '078cf88dd7be97d186f70f16055b22d5a2a2047b', ref: (el) => (this.tabs = el), part: "tabs", class: "tab-group__tabs", role: "tablist" }, h("slot", { key: 'b65782fdf2f18b7a59912227293e49c2d3cba83d', name: "nav" }))), this.hasRightControl && (h("six-icon-button", { key: '8273dadfbfb6de487b10b0b7a8e5d6eb3dfa1b81', class: "tab-group__scroll-button tab-group__scroll-button--right", exportparts: "base:scroll-button", name: "chevron_right", onClick: this.handleScrollRight }))), h("div", { key: '014ba8c47b65d967dc3eb547f9b282fab8270a58', ref: (el) => (this.body = el), part: "body", class: "tab-group__body" }, h("slot", { key: '488a5b56b66451f1f17802bd0421d4c2d70a773c' }))));
|
|
240
240
|
}
|
|
241
241
|
static get is() { return "six-tab-group"; }
|
|
242
242
|
static get encapsulation() { return "shadow"; }
|
|
@@ -31,4 +31,17 @@ export function flipAnimate(element, fromElement, options = {
|
|
|
31
31
|
},
|
|
32
32
|
], options);
|
|
33
33
|
}
|
|
34
|
+
/**
|
|
35
|
+
* Animates an element using keyframes. Returns a promise that resolves after the animation completes or gets canceled.
|
|
36
|
+
*/
|
|
37
|
+
export function animateTo(el, keyframes, options) {
|
|
38
|
+
return new Promise((resolve) => {
|
|
39
|
+
if ((options === null || options === void 0 ? void 0 : options.duration) === Infinity) {
|
|
40
|
+
throw new Error('Promise-based animations must be finite.');
|
|
41
|
+
}
|
|
42
|
+
const animation = el.animate(keyframes, Object.assign(Object.assign({}, options), { duration: options.duration }));
|
|
43
|
+
animation.addEventListener('cancel', resolve, { once: true });
|
|
44
|
+
animation.addEventListener('finish', resolve, { once: true });
|
|
45
|
+
});
|
|
46
|
+
}
|
|
34
47
|
//# sourceMappingURL=animation.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"animation.js","sourceRoot":"","sources":["../../src/utils/animation.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;GAUG;AACH,MAAM,UAAU,WAAW,CACzB,OAAgB,EAChB,WAAoB,EACpB,UAAoC;IAClC,QAAQ,EAAE,GAAG;IACb,MAAM,EAAE,MAAM;IACd,IAAI,EAAE,MAAM;CACb;IAED,MAAM,YAAY,GAAG,WAAW,CAAC,qBAAqB,EAAE,CAAC;IACzD,MAAM,cAAc,GAAG,OAAO,CAAC,qBAAqB,EAAE,CAAC;IAEvD,MAAM,MAAM,GAAG,YAAY,CAAC,IAAI,GAAG,cAAc,CAAC,IAAI,CAAC;IACvD,MAAM,MAAM,GAAG,YAAY,CAAC,GAAG,GAAG,cAAc,CAAC,GAAG,CAAC;IACrD,MAAM,MAAM,GAAG,YAAY,CAAC,KAAK,GAAG,cAAc,CAAC,KAAK,CAAC;IACzD,MAAM,MAAM,GAAG,YAAY,CAAC,MAAM,GAAG,cAAc,CAAC,MAAM,CAAC;IAE3D,OAAO,CAAC,OAAO,CACb;QACE;YACE,eAAe,EAAE,UAAU;YAC3B,SAAS,EAAE,aAAa,MAAM,OAAO,MAAM,aAAa,MAAM,KAAK,MAAM,GAAG;SAC7E;QACD;YACE,eAAe,EAAE,UAAU;YAC3B,SAAS,EAAE,MAAM;SAClB;KACF,EACD,OAAO,CACR,CAAC;AACJ,CAAC","sourcesContent":["/**\n * Animates a given `element` from the position and dimension of `fromElement` to\n * its current position and dimension. Can be useful to implement the FLIP animation technique.\n *\n * @see {@link https://css-tricks.com/animating-layouts-with-the-flip-technique/} for details on the FLIP technique.\n *\n * @param {Element} element - The element to animate.\n * @param {Element} fromElement - The element representing the initial position and dimensions.\n * @param {KeyframeAnimationOptions} [options={ duration: 150, easing: 'ease', fill: 'both' }] - Optional animation parameters.\n *\n */\nexport function flipAnimate(\n element: Element,\n fromElement: Element,\n options: KeyframeAnimationOptions = {\n duration: 150,\n easing: 'ease',\n fill: 'both',\n }\n) {\n const dimensionsTo = fromElement.getBoundingClientRect();\n const dimensionsFrom = element.getBoundingClientRect();\n\n const deltaX = dimensionsTo.left - dimensionsFrom.left;\n const deltaY = dimensionsTo.top - dimensionsFrom.top;\n const deltaW = dimensionsTo.width / dimensionsFrom.width;\n const deltaH = dimensionsTo.height / dimensionsFrom.height;\n\n element.animate(\n [\n {\n transformOrigin: 'top left',\n transform: `translate(${deltaX}px, ${deltaY}px) scale(${deltaW}, ${deltaH})`,\n },\n {\n transformOrigin: 'top left',\n transform: 'none',\n },\n ],\n options\n );\n}\n"]}
|
|
1
|
+
{"version":3,"file":"animation.js","sourceRoot":"","sources":["../../src/utils/animation.ts"],"names":[],"mappings":"AA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,EAAE,OAAO,EAAE,EAAE,IAAI,EAAE,IAAI,EAAE,CAAC,CAAC;QAC9D,SAAS,CAAC,gBAAgB,CAAC,QAAQ,EAAE,OAAO,EAAE,EAAE,IAAI,EAAE,IAAI,EAAE,CAAC,CAAC;IAChE,CAAC,CAAC,CAAC;AACL,CAAC","sourcesContent":["/**\n * Animates a given `element` from the position and dimension of `fromElement` to\n * its current position and dimension. Can be useful to implement the FLIP animation technique.\n *\n * @see {@link https://css-tricks.com/animating-layouts-with-the-flip-technique/} for details on the FLIP technique.\n *\n * @param {Element} element - The element to animate.\n * @param {Element} fromElement - The element representing the initial position and dimensions.\n * @param {KeyframeAnimationOptions} [options={ duration: 150, easing: 'ease', fill: 'both' }] - Optional animation parameters.\n *\n */\nexport function flipAnimate(\n element: Element,\n fromElement: Element,\n options: KeyframeAnimationOptions = {\n duration: 150,\n easing: 'ease',\n fill: 'both',\n }\n) {\n const dimensionsTo = fromElement.getBoundingClientRect();\n const dimensionsFrom = element.getBoundingClientRect();\n\n const deltaX = dimensionsTo.left - dimensionsFrom.left;\n const deltaY = dimensionsTo.top - dimensionsFrom.top;\n const deltaW = dimensionsTo.width / dimensionsFrom.width;\n const deltaH = dimensionsTo.height / dimensionsFrom.height;\n\n element.animate(\n [\n {\n transformOrigin: 'top left',\n transform: `translate(${deltaX}px, ${deltaY}px) scale(${deltaW}, ${deltaH})`,\n },\n {\n transformOrigin: 'top left',\n transform: 'none',\n },\n ],\n options\n );\n}\n\n/**\n * Animates an element using keyframes. Returns a promise that resolves after the animation completes or gets canceled.\n */\nexport function animateTo(el: HTMLElement, keyframes: Keyframe[], options?: KeyframeAnimationOptions) {\n return new Promise((resolve) => {\n if (options?.duration === Infinity) {\n throw new Error('Promise-based animations must be finite.');\n }\n\n const animation = el.animate(keyframes, {\n ...options,\n duration: options!.duration,\n });\n\n animation.addEventListener('cancel', resolve, { once: true });\n animation.addEventListener('finish', resolve, { once: true });\n });\n}\n"]}
|
package/dist/components/index.js
CHANGED
|
@@ -56,7 +56,7 @@ import { SixTextarea } from './six-textarea.js';
|
|
|
56
56
|
import { SixTile } from './six-tile.js';
|
|
57
57
|
import { SixTimepicker } from './six-timepicker.js';
|
|
58
58
|
import { SixTooltip } from './six-tooltip.js';
|
|
59
|
-
export { g as getAssetPath, s as setAssetPath, a as setNonce, b as setPlatformOptions } from './p-
|
|
59
|
+
export { g as getAssetPath, r as render, s as setAssetPath, a as setNonce, b as setPlatformOptions } from './p-D512q9rn.js';
|
|
60
60
|
|
|
61
61
|
/**
|
|
62
62
|
* Displays an alert on the toast stack with a specified message and optional configuration.
|
|
@@ -1,13 +1,13 @@
|
|
|
1
|
-
import { p as proxyCustomElement, H, c as createEvent, h } from './p-
|
|
1
|
+
import { p as proxyCustomElement, H, c as createEvent, h } from './p-D512q9rn.js';
|
|
2
2
|
import { P as Popover } from './p-kHci8ddv.js';
|
|
3
3
|
import { E as EventListeners } from './p-C4h4qpGl.js';
|
|
4
4
|
import { a as debounce, D as DEFAULT_DEBOUNCE_FAST } from './p-CKhg9ibv.js';
|
|
5
|
-
import { d as defineCustomElement$6 } from './p-
|
|
6
|
-
import { d as defineCustomElement$5 } from './p-
|
|
7
|
-
import { d as defineCustomElement$4 } from './p-
|
|
8
|
-
import { d as defineCustomElement$3 } from './p-
|
|
9
|
-
import { d as defineCustomElement$2 } from './p-
|
|
10
|
-
import { d as defineCustomElement$1 } from './p-
|
|
5
|
+
import { d as defineCustomElement$6 } from './p-Cfyrva2T.js';
|
|
6
|
+
import { d as defineCustomElement$5 } from './p-CWKq6Dyt.js';
|
|
7
|
+
import { d as defineCustomElement$4 } from './p-BSHZAiyG.js';
|
|
8
|
+
import { d as defineCustomElement$3 } from './p-DsGIkEDB.js';
|
|
9
|
+
import { d as defineCustomElement$2 } from './p-CSL17OWk.js';
|
|
10
|
+
import { d as defineCustomElement$1 } from './p-C28WDWgL.js';
|
|
11
11
|
|
|
12
12
|
function isTabbable(el) {
|
|
13
13
|
const tabIndex = el.tabIndex;
|
|
@@ -509,19 +509,19 @@ const SixDropdown = /*@__PURE__*/ proxyCustomElement(class SixDropdown extends H
|
|
|
509
509
|
}
|
|
510
510
|
}
|
|
511
511
|
render() {
|
|
512
|
-
return (h("div", { key: '
|
|
512
|
+
return (h("div", { key: '46305375a199fb17ae66ca3b6678634844d0b8a2', part: "base", id: this.componentId, class: {
|
|
513
513
|
dropdown: true,
|
|
514
514
|
'dropdown--open': this.open,
|
|
515
|
-
} }, h("span", { key: '
|
|
515
|
+
} }, h("span", { key: '2a53d2cf2b75607614f39675cabfe1362b297e70', part: "trigger", class: "dropdown__trigger", ref: (el) => (this.trigger = el), onClick: this.handleTriggerClick, onKeyDown: this.handleTriggerKeyDown, onKeyUp: this.handleTriggerKeyUp }, h("slot", { key: 'd8abcd455c768fded48df4c18b8191e365db4ab1', name: "trigger", ref: (el) => (this.triggerSlot = el), onSlotchange: this.handleTriggerSlotChange })), h("div", { key: 'fd0e0352800daebdc9843442901cad9769d3199a', ref: (el) => (this.positioner = el), class: {
|
|
516
516
|
dropdown__positioner: true,
|
|
517
517
|
dropdown__positioner__filtered: (this.filter || this.asyncFilter) && !this.hoist,
|
|
518
|
-
} }, h("div", { key: '
|
|
518
|
+
} }, h("div", { key: '2d72ca0ba1a5cbb480727e325048f7a171fb7af8', ref: (el) => (this.panel = el), part: "panel", class: "dropdown__panel", role: "menu", "aria-hidden": this.open ? 'false' : 'true', "aria-labelledby": this.componentId }, this.filterEnabled && (h("six-input", { key: 'a22263fb924be51081598579391774c82a09852f', class: {
|
|
519
519
|
filter: true,
|
|
520
520
|
'filter-hidden': !this.open,
|
|
521
|
-
}, "dropdown-search": true, "aria-hidden": this.open ? 'false' : 'true', ref: (el) => (this.filterInputElement = el), placeholder: this.filterPlaceholder }, h("six-icon", { key: '
|
|
521
|
+
}, "dropdown-search": true, "aria-hidden": this.open ? 'false' : 'true', ref: (el) => (this.filterInputElement = el), placeholder: this.filterPlaceholder }, h("six-icon", { key: '7a8fc9e25e7e209b5b0aa05af5dcefca87e3b9d5', class: "filter__icon", slot: "suffix", size: "small" }, "search"))), h("div", { key: 'bedcab39d656be8ce064852ef9344b4fbbf60b17', class: {
|
|
522
522
|
dropdown__panel__scroll: true,
|
|
523
523
|
'dropdown__panel__scroll--virtual': this.virtualScroll,
|
|
524
|
-
}, onScroll: this.handleDropdownScroll, ref: (el) => (this.scrollPanel = el) }, h("slot", { key: '
|
|
524
|
+
}, onScroll: this.handleDropdownScroll, ref: (el) => (this.scrollPanel = el) }, h("slot", { key: '21acba56de1fba98afdfda60e8b09816a70ac057', ref: (el) => (this.panelSlot = el) }), this.options.length > 0 && (h("six-menu", { key: 'd7d429d062bf111ffdaf667ada0efe640136871a', part: "menu", items: this.renderedOptions, virtualScroll: this.virtualScroll }))), h("slot", { key: 'e23be3aa659ed7fa4a513d82c982733b58a6e9db', name: "dropdown-footer" })))));
|
|
525
525
|
}
|
|
526
526
|
get host() { return this; }
|
|
527
527
|
static get watchers() { return {
|
|
@@ -622,6 +622,6 @@ function defineCustomElement() {
|
|
|
622
622
|
}
|
|
623
623
|
|
|
624
624
|
export { SixDropdown as S, defineCustomElement as d };
|
|
625
|
-
//# sourceMappingURL=p-
|
|
625
|
+
//# sourceMappingURL=p-9aUb96SZ.js.map
|
|
626
626
|
|
|
627
|
-
//# sourceMappingURL=p-
|
|
627
|
+
//# sourceMappingURL=p-9aUb96SZ.js.map
|