@zanichelli/albe-web-components 4.2.0 → 5.1.0
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/{index-0e75c8cc.js → index-bc9a5c2b.js} +53 -13
- package/dist/cjs/index.cjs.js +2 -2
- package/dist/cjs/loader.cjs.js +1 -1
- package/dist/cjs/{utils-97262bbd.js → utils-2fa62b67.js} +1 -1
- package/dist/cjs/{utils-155eec04.js → utils-40bb75b1.js} +1 -2
- package/dist/cjs/web-components-library.cjs.js +1 -1
- package/dist/cjs/z-app-switcher_9.cjs.entry.js +3 -3
- package/dist/cjs/z-aria-alert.cjs.entry.js +1 -1
- package/dist/cjs/z-avatar.cjs.entry.js +1 -1
- package/dist/cjs/z-button-deprecated.cjs.entry.js +1 -1
- package/dist/cjs/z-button.cjs.entry.js +4 -6
- package/dist/cjs/z-card.cjs.entry.js +1 -1
- package/dist/cjs/z-chip.cjs.entry.js +2 -2
- package/dist/cjs/z-combobox.cjs.entry.js +2 -2
- package/dist/cjs/z-contextual-menu.cjs.entry.js +3 -3
- package/dist/cjs/z-cookiebar.cjs.entry.js +1 -1
- package/dist/cjs/z-date-picker.cjs.entry.js +2 -2
- package/dist/cjs/z-file-upload.cjs.entry.js +2 -2
- package/dist/cjs/z-file.cjs.entry.js +2 -2
- package/dist/cjs/z-footer.cjs.entry.js +1 -1
- package/dist/cjs/z-info-reveal.cjs.entry.js +64 -0
- package/dist/cjs/z-input-deprecated.cjs.entry.js +2 -2
- package/dist/cjs/z-input-label_2.cjs.entry.js +2 -2
- package/dist/cjs/z-list-group.cjs.entry.js +1 -1
- package/dist/cjs/z-list_2.cjs.entry.js +1 -1
- package/dist/cjs/z-menu-dropdown_2.cjs.entry.js +2 -2
- package/dist/cjs/z-messages-pocket.cjs.entry.js +1 -1
- package/dist/cjs/z-modal-login.cjs.entry.js +1 -1
- package/dist/cjs/z-myz-card-alert.cjs.entry.js +1 -1
- package/dist/cjs/z-myz-card-dictionary.cjs.entry.js +1 -1
- package/dist/cjs/z-myz-card-footer.cjs.entry.js +1 -1
- package/dist/cjs/z-myz-card-info.cjs.entry.js +3 -3
- package/dist/cjs/z-myz-card_4.cjs.entry.js +1 -1
- package/dist/cjs/z-myz-list-item.cjs.entry.js +2 -2
- package/dist/cjs/z-myz-topbar.cjs.entry.js +1 -1
- package/dist/cjs/z-navigation-tab-link.cjs.entry.js +1 -1
- package/dist/cjs/z-navigation-tab.cjs.entry.js +1 -1
- package/dist/cjs/z-navigation-tabs.cjs.entry.js +1 -1
- package/dist/cjs/z-offcanvas.cjs.entry.js +1 -1
- package/dist/cjs/z-otp.cjs.entry.js +1 -1
- package/dist/cjs/z-pagination-bar.cjs.entry.js +2 -2
- package/dist/cjs/z-pocket_3.cjs.entry.js +2 -2
- package/dist/cjs/z-popover-deprecated.cjs.entry.js +97 -303
- package/dist/cjs/z-popover.cjs.entry.js +26 -29
- package/dist/cjs/z-section-title.cjs.entry.js +1 -1
- package/dist/cjs/z-skip-to-content.cjs.entry.js +2 -2
- package/dist/cjs/z-slideshow.cjs.entry.js +2 -2
- package/dist/cjs/z-status-tag.cjs.entry.js +1 -1
- package/dist/cjs/z-table-cell.cjs.entry.js +1 -1
- package/dist/cjs/z-table-header.cjs.entry.js +3 -3
- package/dist/cjs/z-table-row.cjs.entry.js +1 -1
- package/dist/cjs/z-table.cjs.entry.js +1 -1
- package/dist/cjs/z-toast-notification-list.cjs.entry.js +1 -1
- package/dist/cjs/z-toast-notification.cjs.entry.js +1 -1
- package/dist/cjs/z-toggle-switch.cjs.entry.js +2 -2
- package/dist/cjs/z-tooltip-deprecated.cjs.entry.js +26 -26
- package/dist/cjs/z-tooltip.cjs.entry.js +2 -2
- package/dist/collection/beans/index.js +53 -13
- package/dist/collection/collection-manifest.json +1 -0
- package/dist/collection/components/buttons/z-button/index.js +5 -7
- package/dist/collection/components/buttons/z-button/styles.css +23 -23
- package/dist/collection/components/file-upload/z-file/index.js +1 -1
- package/dist/collection/components/notification/z-tooltip/index.js +3 -3
- package/dist/collection/components/z-contextual-menu/index.js +3 -3
- package/dist/collection/components/z-contextual-menu/styles.css +5 -1
- package/dist/collection/components/z-info-reveal/index.js +143 -0
- package/dist/collection/components/z-info-reveal/styles.css +97 -0
- package/dist/collection/components/z-popover/index.js +30 -32
- package/dist/collection/components/z-table/z-table-header/index.js +1 -1
- package/dist/collection/deprecated/z-popover-deprecated/index.js +173 -368
- package/dist/collection/deprecated/z-popover-deprecated/styles.css +188 -86
- package/dist/collection/deprecated/z-tooltip-deprecated/index.js +27 -27
- package/dist/collection/snowflakes/myz/card/z-myz-card-info/index.js +1 -1
- package/dist/esm/{index-c1ce8cab.js → index-e3640537.js} +54 -14
- package/dist/esm/index.js +2 -2
- package/dist/esm/loader.js +1 -1
- package/dist/esm/{utils-fa9f38ec.js → utils-c1f651ae.js} +1 -2
- package/dist/esm/{utils-99c70c57.js → utils-f3d44cb3.js} +1 -1
- package/dist/esm/web-components-library.js +1 -1
- package/dist/esm/z-app-switcher_9.entry.js +3 -3
- package/dist/esm/z-aria-alert.entry.js +1 -1
- package/dist/esm/z-avatar.entry.js +1 -1
- package/dist/esm/z-button-deprecated.entry.js +1 -1
- package/dist/esm/z-button.entry.js +4 -6
- package/dist/esm/z-card.entry.js +1 -1
- package/dist/esm/z-chip.entry.js +2 -2
- package/dist/esm/z-combobox.entry.js +2 -2
- package/dist/esm/z-contextual-menu.entry.js +3 -3
- package/dist/esm/z-cookiebar.entry.js +1 -1
- package/dist/esm/z-date-picker.entry.js +2 -2
- package/dist/esm/z-file-upload.entry.js +2 -2
- package/dist/esm/z-file.entry.js +2 -2
- package/dist/esm/z-footer.entry.js +1 -1
- package/dist/esm/z-info-reveal.entry.js +60 -0
- package/dist/esm/z-input-deprecated.entry.js +2 -2
- package/dist/esm/z-input-label_2.entry.js +2 -2
- package/dist/esm/z-list-group.entry.js +1 -1
- package/dist/esm/z-list_2.entry.js +1 -1
- package/dist/esm/z-menu-dropdown_2.entry.js +2 -2
- package/dist/esm/z-messages-pocket.entry.js +1 -1
- package/dist/esm/z-modal-login.entry.js +1 -1
- package/dist/esm/z-myz-card-alert.entry.js +1 -1
- package/dist/esm/z-myz-card-dictionary.entry.js +1 -1
- package/dist/esm/z-myz-card-footer.entry.js +1 -1
- package/dist/esm/z-myz-card-info.entry.js +3 -3
- package/dist/esm/z-myz-card_4.entry.js +1 -1
- package/dist/esm/z-myz-list-item.entry.js +2 -2
- package/dist/esm/z-myz-topbar.entry.js +1 -1
- package/dist/esm/z-navigation-tab-link.entry.js +1 -1
- package/dist/esm/z-navigation-tab.entry.js +1 -1
- package/dist/esm/z-navigation-tabs.entry.js +1 -1
- package/dist/esm/z-offcanvas.entry.js +1 -1
- package/dist/esm/z-otp.entry.js +1 -1
- package/dist/esm/z-pagination-bar.entry.js +2 -2
- package/dist/esm/z-pocket_3.entry.js +2 -2
- package/dist/esm/z-popover-deprecated.entry.js +98 -304
- package/dist/esm/z-popover.entry.js +26 -29
- package/dist/esm/z-section-title.entry.js +1 -1
- package/dist/esm/z-skip-to-content.entry.js +2 -2
- package/dist/esm/z-slideshow.entry.js +2 -2
- package/dist/esm/z-status-tag.entry.js +1 -1
- package/dist/esm/z-table-cell.entry.js +1 -1
- package/dist/esm/z-table-header.entry.js +3 -3
- package/dist/esm/z-table-row.entry.js +1 -1
- package/dist/esm/z-table.entry.js +1 -1
- package/dist/esm/z-toast-notification-list.entry.js +1 -1
- package/dist/esm/z-toast-notification.entry.js +1 -1
- package/dist/esm/z-toggle-switch.entry.js +2 -2
- package/dist/esm/z-tooltip-deprecated.entry.js +26 -26
- package/dist/esm/z-tooltip.entry.js +2 -2
- package/dist/types/beans/index.d.ts +50 -13
- package/dist/types/components/buttons/z-button/index.d.ts +2 -3
- package/dist/types/components/z-info-reveal/index.d.ts +28 -0
- package/dist/types/components/z-popover/index.d.ts +3 -3
- package/dist/types/components.d.ts +61 -26
- package/dist/types/deprecated/z-popover-deprecated/index.d.ts +27 -51
- package/dist/web-components-library/index.esm.js +1 -1
- package/{www/build/p-78df5dbf.entry.js → dist/web-components-library/p-057981fe.entry.js} +1 -1
- package/dist/web-components-library/p-07949b90.entry.js +1 -0
- package/dist/web-components-library/p-0c37f467.entry.js +1 -0
- package/{www/build/p-cd88cead.entry.js → dist/web-components-library/p-0f185eb0.entry.js} +1 -1
- package/dist/web-components-library/{p-b9cc2dfc.entry.js → p-12125ca9.entry.js} +1 -1
- package/dist/web-components-library/{p-4be52491.entry.js → p-139b5241.entry.js} +1 -1
- package/dist/web-components-library/p-20d02305.js +1 -0
- package/dist/web-components-library/{p-8ddbbe24.entry.js → p-242501d5.entry.js} +1 -1
- package/dist/web-components-library/{p-1b1717c9.entry.js → p-26e314bc.entry.js} +1 -1
- package/dist/web-components-library/{p-b359a3b4.entry.js → p-28ecb1ae.entry.js} +1 -1
- package/{www/build/p-dd0efdbf.entry.js → dist/web-components-library/p-2931f7bc.entry.js} +1 -1
- package/dist/web-components-library/p-2954396f.entry.js +1 -0
- package/dist/web-components-library/{p-0f6edb58.entry.js → p-2c17e016.entry.js} +1 -1
- package/dist/web-components-library/{p-1eb357e8.entry.js → p-3496bd33.entry.js} +1 -1
- package/dist/web-components-library/{p-897f9491.entry.js → p-38716520.entry.js} +1 -1
- package/{www/build/p-870dabdc.entry.js → dist/web-components-library/p-3ab957bb.entry.js} +1 -1
- package/dist/web-components-library/p-3e564afc.entry.js +1 -0
- package/{www/build/p-55f09348.entry.js → dist/web-components-library/p-45810268.entry.js} +1 -1
- package/dist/web-components-library/{p-1d5aa37b.entry.js → p-46f58c91.entry.js} +1 -1
- package/{www/build/p-1a76a57d.entry.js → dist/web-components-library/p-4c857706.entry.js} +1 -1
- package/dist/web-components-library/{p-53dade4b.entry.js → p-5332ba48.entry.js} +1 -1
- package/{www/build/p-91ec5eb4.entry.js → dist/web-components-library/p-57888e02.entry.js} +1 -1
- package/dist/web-components-library/{p-99a562cb.entry.js → p-57f2ceae.entry.js} +1 -1
- package/dist/web-components-library/{p-fdd91263.entry.js → p-5889ec85.entry.js} +1 -1
- package/dist/web-components-library/{p-970bd07c.entry.js → p-598f6761.entry.js} +1 -1
- package/dist/web-components-library/{p-46aecb12.entry.js → p-6f731dfa.entry.js} +1 -1
- package/dist/web-components-library/{p-28e4abc4.entry.js → p-7a3cdf12.entry.js} +1 -1
- package/dist/web-components-library/{p-c042e745.entry.js → p-7aa19a55.entry.js} +1 -1
- package/dist/web-components-library/{p-805af37b.entry.js → p-7dfe73cf.entry.js} +1 -1
- package/dist/web-components-library/{p-d04f3cb6.entry.js → p-83f0796d.entry.js} +1 -1
- package/dist/web-components-library/{p-10be0462.entry.js → p-85bd1ff2.entry.js} +1 -1
- package/dist/web-components-library/{p-7f1cc90f.js → p-8c4c18e1.js} +1 -1
- package/dist/web-components-library/{p-15fa8ca4.entry.js → p-90a4883b.entry.js} +1 -1
- package/dist/web-components-library/p-967401ab.js +1 -0
- package/dist/web-components-library/{p-f78d6123.entry.js → p-969652eb.entry.js} +1 -1
- package/dist/web-components-library/{p-8ce4b2c4.entry.js → p-98298391.entry.js} +1 -1
- package/dist/web-components-library/p-a2e54d19.entry.js +1 -0
- package/dist/web-components-library/{p-bfc78a89.entry.js → p-adbca438.entry.js} +1 -1
- package/dist/web-components-library/{p-659fc25e.entry.js → p-b3e7dfbd.entry.js} +1 -1
- package/dist/web-components-library/{p-6bbd53ec.entry.js → p-b43e7b60.entry.js} +1 -1
- package/{www/build/p-eca4cb15.entry.js → dist/web-components-library/p-b4c75519.entry.js} +1 -1
- package/dist/web-components-library/{p-990b8236.entry.js → p-b8e8220f.entry.js} +1 -1
- package/{www/build/p-4d6f2f01.entry.js → dist/web-components-library/p-c07bcbd3.entry.js} +1 -1
- package/dist/web-components-library/{p-41f33f7b.entry.js → p-c1ebd436.entry.js} +1 -1
- package/{www/build/p-fbfaa699.entry.js → dist/web-components-library/p-c4892336.entry.js} +1 -1
- package/dist/web-components-library/{p-caa21a6f.entry.js → p-d09b89da.entry.js} +1 -1
- package/dist/web-components-library/{p-c8383456.entry.js → p-d5844db1.entry.js} +1 -1
- package/dist/web-components-library/{p-5dcbba4e.entry.js → p-d641ea46.entry.js} +1 -1
- package/dist/web-components-library/{p-6c52ed1b.entry.js → p-dad7bc20.entry.js} +1 -1
- package/dist/web-components-library/{p-e74b3fd9.entry.js → p-e3840215.entry.js} +1 -1
- package/{www/build/p-d6361790.entry.js → dist/web-components-library/p-e768fe51.entry.js} +1 -1
- package/dist/web-components-library/{p-053846df.entry.js → p-e815e82b.entry.js} +1 -1
- package/dist/web-components-library/{p-ff4a0f6f.entry.js → p-fde7105a.entry.js} +1 -1
- package/dist/web-components-library/{p-92895bce.entry.js → p-fed999af.entry.js} +1 -1
- package/dist/web-components-library/web-components-library.css +1 -1
- package/dist/web-components-library/web-components-library.esm.js +1 -1
- package/package.json +2 -2
- package/react/components.d.ts +1 -0
- package/react/components.js +4 -3
- package/react/components.js.map +1 -1
- package/www/build/index.esm.js +1 -1
- package/{dist/web-components-library/p-78df5dbf.entry.js → www/build/p-057981fe.entry.js} +1 -1
- package/www/build/p-07949b90.entry.js +1 -0
- package/www/build/p-0c37f467.entry.js +1 -0
- package/{dist/web-components-library/p-cd88cead.entry.js → www/build/p-0f185eb0.entry.js} +1 -1
- package/www/build/{p-b9cc2dfc.entry.js → p-12125ca9.entry.js} +1 -1
- package/www/build/{p-4be52491.entry.js → p-139b5241.entry.js} +1 -1
- package/www/build/p-20d02305.js +1 -0
- package/www/build/{p-8ddbbe24.entry.js → p-242501d5.entry.js} +1 -1
- package/www/build/{p-1b1717c9.entry.js → p-26e314bc.entry.js} +1 -1
- package/www/build/{p-b359a3b4.entry.js → p-28ecb1ae.entry.js} +1 -1
- package/{dist/web-components-library/p-dd0efdbf.entry.js → www/build/p-2931f7bc.entry.js} +1 -1
- package/www/build/p-2954396f.entry.js +1 -0
- package/www/build/{p-0f6edb58.entry.js → p-2c17e016.entry.js} +1 -1
- package/www/build/{p-1eb357e8.entry.js → p-3496bd33.entry.js} +1 -1
- package/www/build/{p-897f9491.entry.js → p-38716520.entry.js} +1 -1
- package/{dist/web-components-library/p-870dabdc.entry.js → www/build/p-3ab957bb.entry.js} +1 -1
- package/www/build/p-3e564afc.entry.js +1 -0
- package/www/build/p-418e5795.js +1 -0
- package/{dist/web-components-library/p-55f09348.entry.js → www/build/p-45810268.entry.js} +1 -1
- package/www/build/{p-1d5aa37b.entry.js → p-46f58c91.entry.js} +1 -1
- package/{dist/web-components-library/p-1a76a57d.entry.js → www/build/p-4c857706.entry.js} +1 -1
- package/www/build/p-4c9c83c0.css +1 -0
- package/www/build/{p-53dade4b.entry.js → p-5332ba48.entry.js} +1 -1
- package/{dist/web-components-library/p-91ec5eb4.entry.js → www/build/p-57888e02.entry.js} +1 -1
- package/www/build/{p-99a562cb.entry.js → p-57f2ceae.entry.js} +1 -1
- package/www/build/{p-fdd91263.entry.js → p-5889ec85.entry.js} +1 -1
- package/www/build/{p-970bd07c.entry.js → p-598f6761.entry.js} +1 -1
- package/www/build/{p-46aecb12.entry.js → p-6f731dfa.entry.js} +1 -1
- package/www/build/{p-28e4abc4.entry.js → p-7a3cdf12.entry.js} +1 -1
- package/www/build/{p-c042e745.entry.js → p-7aa19a55.entry.js} +1 -1
- package/www/build/{p-805af37b.entry.js → p-7dfe73cf.entry.js} +1 -1
- package/www/build/{p-d04f3cb6.entry.js → p-83f0796d.entry.js} +1 -1
- package/www/build/{p-10be0462.entry.js → p-85bd1ff2.entry.js} +1 -1
- package/www/build/{p-7f1cc90f.js → p-8c4c18e1.js} +1 -1
- package/www/build/{p-15fa8ca4.entry.js → p-90a4883b.entry.js} +1 -1
- package/www/build/p-967401ab.js +1 -0
- package/www/build/{p-f78d6123.entry.js → p-969652eb.entry.js} +1 -1
- package/www/build/{p-8ce4b2c4.entry.js → p-98298391.entry.js} +1 -1
- package/www/build/p-a2e54d19.entry.js +1 -0
- package/www/build/{p-bfc78a89.entry.js → p-adbca438.entry.js} +1 -1
- package/www/build/{p-659fc25e.entry.js → p-b3e7dfbd.entry.js} +1 -1
- package/www/build/{p-6bbd53ec.entry.js → p-b43e7b60.entry.js} +1 -1
- package/{dist/web-components-library/p-eca4cb15.entry.js → www/build/p-b4c75519.entry.js} +1 -1
- package/www/build/{p-990b8236.entry.js → p-b8e8220f.entry.js} +1 -1
- package/{dist/web-components-library/p-4d6f2f01.entry.js → www/build/p-c07bcbd3.entry.js} +1 -1
- package/www/build/{p-41f33f7b.entry.js → p-c1ebd436.entry.js} +1 -1
- package/{dist/web-components-library/p-fbfaa699.entry.js → www/build/p-c4892336.entry.js} +1 -1
- package/www/build/{p-caa21a6f.entry.js → p-d09b89da.entry.js} +1 -1
- package/www/build/{p-c8383456.entry.js → p-d5844db1.entry.js} +1 -1
- package/www/build/{p-5dcbba4e.entry.js → p-d641ea46.entry.js} +1 -1
- package/www/build/{p-6c52ed1b.entry.js → p-dad7bc20.entry.js} +1 -1
- package/www/build/{p-e74b3fd9.entry.js → p-e3840215.entry.js} +1 -1
- package/{dist/web-components-library/p-d6361790.entry.js → www/build/p-e768fe51.entry.js} +1 -1
- package/www/build/{p-053846df.entry.js → p-e815e82b.entry.js} +1 -1
- package/www/build/{p-ff4a0f6f.entry.js → p-fde7105a.entry.js} +1 -1
- package/www/build/{p-92895bce.entry.js → p-fed999af.entry.js} +1 -1
- package/www/build/web-components-library.css +1 -1
- package/www/build/web-components-library.esm.js +1 -1
- package/www/index.html +1 -1
- package/CHANGELOG.md +0 -1788
- package/dist/web-components-library/p-514719d2.entry.js +0 -1
- package/dist/web-components-library/p-b6cd034b.js +0 -1
- package/dist/web-components-library/p-e007cd0b.entry.js +0 -1
- package/dist/web-components-library/p-ed1cd6b1.js +0 -1
- package/dist/web-components-library/p-f26251dd.entry.js +0 -1
- package/dist/web-components-library/p-f61fd81e.entry.js +0 -1
- package/src-react/index.ts +0 -1
- package/www/build/p-514719d2.entry.js +0 -1
- package/www/build/p-975e9d42.js +0 -129
- package/www/build/p-b6cd034b.js +0 -1
- package/www/build/p-e007cd0b.entry.js +0 -1
- package/www/build/p-ed1cd6b1.js +0 -1
- package/www/build/p-f26251dd.entry.js +0 -1
- package/www/build/p-f61fd81e.entry.js +0 -1
- package/www/build/p-fcff1237.css +0 -812
|
@@ -3,335 +3,129 @@
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
5
|
const index = require('./index-84b7063a.js');
|
|
6
|
-
const index$
|
|
7
|
-
const
|
|
6
|
+
const index$2 = require('./index-1fda0714.js');
|
|
7
|
+
const index$1 = require('./index-bc9a5c2b.js');
|
|
8
|
+
const utils = require('./utils-2fa62b67.js');
|
|
9
|
+
require('./_commonjsHelpers-537d719a.js');
|
|
8
10
|
require('./breakpoints-88c4fd6c.js');
|
|
9
11
|
|
|
10
|
-
const stylesCss = "
|
|
12
|
+
const stylesCss = ".sc-z-popover-deprecated-h{font-family:var(--dashboard-font);font-weight:var(--font-rg);position:relative;display:inline-block;--shadow-arrow-color:rgba(66, 69, 72, 0.2);--shadow-arrow-below-color:rgba(66, 69, 72, 0.1)}.popover-content-container.sc-z-popover-deprecated{box-sizing:border-box;visibility:hidden;position:absolute;min-width:64px;min-height:32px;z-index:999}.popover-content-container.visible.sc-z-popover-deprecated{visibility:visible}.popover-content-container.border-radius-none.sc-z-popover-deprecated{border-radius:0}.popover-content-container.border-radius-small.sc-z-popover-deprecated{border-radius:var(--border-radius-small)}.popover-content-container.border-radius-medium.sc-z-popover-deprecated{border-radius:var(--border-radius)}.popover-content-container.shadow-1.sc-z-popover-deprecated{box-shadow:var(--shadow-1)}.popover-content-container.shadow-2.sc-z-popover-deprecated{box-shadow:var(--shadow-2)}.popover-content-container.shadow-3.sc-z-popover-deprecated{box-shadow:var(--shadow-3)}.popover-content-container.shadow-4.sc-z-popover-deprecated{box-shadow:var(--shadow-4)}.popover-content-container.shadow-6.sc-z-popover-deprecated{box-shadow:var(--shadow-6)}.popover-content-container.shadow-8.sc-z-popover-deprecated{box-shadow:var(--shadow-8)}.popover-content-container.shadow-12.sc-z-popover-deprecated{box-shadow:var(--shadow-12)}.popover-content-container.shadow-16.sc-z-popover-deprecated{box-shadow:var(--shadow-16)}.popover-content-container.shadow-24.sc-z-popover-deprecated{box-shadow:var(--shadow-24)}.popover-content-container.after-down.sc-z-popover-deprecated{top:0;left:calc(100% + var(--space-unit))}.popover-content-container.after-center.sc-z-popover-deprecated{top:50%;left:calc(100% + var(--space-unit));transform:translateY(-50%)}.popover-content-container.after-up.sc-z-popover-deprecated{bottom:0;left:calc(100% + var(--space-unit))}.popover-content-container.below-right.sc-z-popover-deprecated{left:0;top:calc(100% + var(--space-unit))}.popover-content-container.below-center.sc-z-popover-deprecated{left:50%;top:calc(100% + var(--space-unit));transform:translateX(-50%)}.popover-content-container.below-left.sc-z-popover-deprecated{right:0;top:calc(100% + var(--space-unit))}.popover-content-container.before-down.sc-z-popover-deprecated{top:0;right:calc(100% + var(--space-unit))}.popover-content-container.before-center.sc-z-popover-deprecated{top:50%;right:calc(100% + var(--space-unit));transform:translateY(-50%)}.popover-content-container.before-up.sc-z-popover-deprecated{bottom:0;right:calc(100% + var(--space-unit))}.popover-content-container.above-right.sc-z-popover-deprecated{left:0;bottom:calc(100% + var(--space-unit))}.popover-content-container.above-center.sc-z-popover-deprecated{left:50%;bottom:calc(100% + var(--space-unit));transform:translateX(-50%)}.popover-content-container.above-left.sc-z-popover-deprecated{right:0;bottom:calc(100% + var(--space-unit))}.popover-content-container.sc-z-popover-deprecated:before{display:none;position:absolute;content:\"\";width:8px;height:8px;z-index:-1;background-color:inherit;transform:rotate(45deg)}.popover-content-container.after-down.sc-z-popover-deprecated:before{top:12px;left:-4px;box-shadow:-1px 1px 1.5px var(--shadow-arrow-color)}.popover-content-container.after-center.sc-z-popover-deprecated:before{top:calc(50% - 4px);left:-4px;box-shadow:-1px 1px 1.5px var(--shadow-arrow-color)}.popover-content-container.after-up.sc-z-popover-deprecated:before{bottom:12px;left:-4px;box-shadow:-1px 1px 1.5px var(--shadow-arrow-color)}.popover-content-container.below-right.sc-z-popover-deprecated:before{left:12px;top:-4px;box-shadow:-1px -1px 2px var(--shadow-arrow-below-color)}.popover-content-container.below-center.sc-z-popover-deprecated:before{left:calc(50% - 4px);top:-4px;box-shadow:-1px -1px 2px var(--shadow-arrow-below-color)}.popover-content-container.below-left.sc-z-popover-deprecated:before{right:12px;top:-4px;box-shadow:-1px -1px 2px var(--shadow-arrow-below-color)}.popover-content-container.before-down.sc-z-popover-deprecated:before{top:12px;right:-4px;box-shadow:1px -1px 1.5px var(--shadow-arrow-color)}.popover-content-container.before-center.sc-z-popover-deprecated:before{top:calc(50% - 4px);right:-4px;box-shadow:1px -1px 1.5px var(--shadow-arrow-color)}.popover-content-container.before-up.sc-z-popover-deprecated:before{bottom:12px;right:-4px;box-shadow:1px -1px 1.5px var(--shadow-arrow-color)}.popover-content-container.above-right.sc-z-popover-deprecated:before{left:12px;bottom:-4px;box-shadow:1px 1px 1.5px var(--shadow-arrow-color)}.popover-content-container.above-center.sc-z-popover-deprecated:before{left:calc(50% - 4px);bottom:-4px;box-shadow:1px 1px 1.5px var(--shadow-arrow-color)}.popover-content-container.above-left.sc-z-popover-deprecated:before{right:12px;bottom:-4px;box-shadow:1px 1px 1.5px var(--shadow-arrow-color)}.popover-content-container.show-arrow.sc-z-popover-deprecated:before{display:block}";
|
|
11
13
|
|
|
12
|
-
const documentElement = document.documentElement;
|
|
13
|
-
function getParentElement(element) {
|
|
14
|
-
if (element.parentNode.host) {
|
|
15
|
-
return element.parentNode.host;
|
|
16
|
-
}
|
|
17
|
-
return element.parentNode;
|
|
18
|
-
}
|
|
19
|
-
/**
|
|
20
|
-
* Find the closest scrollable parent of a node.
|
|
21
|
-
*
|
|
22
|
-
* @param {Element} element The node
|
|
23
|
-
*/
|
|
24
|
-
function findScrollableParent(element) {
|
|
25
|
-
let parent = getParentElement(element);
|
|
26
|
-
while (parent && parent !== documentElement) {
|
|
27
|
-
const { overflow, overflowX, overflowY } = window.getComputedStyle(parent);
|
|
28
|
-
if (overflow === "hidden" ||
|
|
29
|
-
overflowY === "hidden" ||
|
|
30
|
-
overflowX === "hidden") {
|
|
31
|
-
return parent;
|
|
32
|
-
}
|
|
33
|
-
if ((parent.scrollHeight > parent.clientHeight &&
|
|
34
|
-
overflow !== "visible" &&
|
|
35
|
-
overflowY !== "visible") ||
|
|
36
|
-
(parent.scrollWidth > parent.clientWidth &&
|
|
37
|
-
overflow !== "visible" &&
|
|
38
|
-
overflowX !== "visible")) {
|
|
39
|
-
return parent;
|
|
40
|
-
}
|
|
41
|
-
parent = getParentElement(parent);
|
|
42
|
-
}
|
|
43
|
-
return documentElement;
|
|
44
|
-
}
|
|
45
|
-
/**
|
|
46
|
-
* Calculate computed offset.
|
|
47
|
-
* It includes matrix transformations.
|
|
48
|
-
* @param element The target element.
|
|
49
|
-
* @param targetParentOffset The relative offset parent.
|
|
50
|
-
* @return A client rect object.
|
|
51
|
-
*/
|
|
52
|
-
function computeOffset(element, targetParentOffset) {
|
|
53
|
-
const rect = element.getBoundingClientRect();
|
|
54
|
-
const width = rect.width;
|
|
55
|
-
const height = rect.height;
|
|
56
|
-
let top = 0;
|
|
57
|
-
let left = 0;
|
|
58
|
-
let offsetParent = element;
|
|
59
|
-
while (offsetParent && offsetParent != targetParentOffset) {
|
|
60
|
-
left += offsetParent.offsetLeft;
|
|
61
|
-
// document.body sometimes has offsetTop == 0 but still has an
|
|
62
|
-
// offset because of children margins!
|
|
63
|
-
if (offsetParent === document.body) {
|
|
64
|
-
top += offsetParent.getBoundingClientRect().top + window.scrollY;
|
|
65
|
-
}
|
|
66
|
-
else {
|
|
67
|
-
top += offsetParent.offsetTop;
|
|
68
|
-
}
|
|
69
|
-
if (window.DOMMatrix) {
|
|
70
|
-
const style = window.getComputedStyle(offsetParent);
|
|
71
|
-
const transform = style.transform || style.webkitTransform;
|
|
72
|
-
const domMatrix = new DOMMatrix(transform);
|
|
73
|
-
if (domMatrix) {
|
|
74
|
-
left += domMatrix.m41;
|
|
75
|
-
if (offsetParent !== document.body) {
|
|
76
|
-
top += domMatrix.m42;
|
|
77
|
-
}
|
|
78
|
-
}
|
|
79
|
-
}
|
|
80
|
-
if (!offsetParent.offsetParent) {
|
|
81
|
-
break;
|
|
82
|
-
}
|
|
83
|
-
offsetParent = offsetParent.offsetParent;
|
|
84
|
-
}
|
|
85
|
-
let parentWidth;
|
|
86
|
-
let parentHeight;
|
|
87
|
-
if (offsetParent === document.body) {
|
|
88
|
-
parentWidth = window.innerWidth;
|
|
89
|
-
parentHeight = window.innerHeight;
|
|
90
|
-
}
|
|
91
|
-
else {
|
|
92
|
-
parentWidth = offsetParent.offsetWidth;
|
|
93
|
-
parentHeight = offsetParent.offsetHeight;
|
|
94
|
-
}
|
|
95
|
-
const right = parentWidth - left - rect.width;
|
|
96
|
-
const bottom = parentHeight - top - rect.height;
|
|
97
|
-
return { top, right, bottom, left, width, height };
|
|
98
|
-
}
|
|
99
14
|
const ZPopoverDeprecated = class {
|
|
15
|
+
/**
|
|
16
|
+
* Constructor.
|
|
17
|
+
*/
|
|
100
18
|
constructor(hostRef) {
|
|
101
19
|
index.registerInstance(this, hostRef);
|
|
102
|
-
this.
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
*/
|
|
20
|
+
this.triggerClick = index.createEvent(this, "triggerClick", 7);
|
|
21
|
+
/** [optional] Popover position */
|
|
22
|
+
this.position = index$1.PopoverPosition["after-up"];
|
|
23
|
+
/** [optional] Background color token for popover */
|
|
24
|
+
this.backgroundColor = "color-white";
|
|
25
|
+
/** [optional] Border radius token for popover */
|
|
26
|
+
this.borderRadius = index$1.PopoverBorderRadius.small;
|
|
27
|
+
/** [optional] Box shadow token for popover */
|
|
28
|
+
this.boxShadow = index$1.PopoverShadow["shadow-1"];
|
|
29
|
+
/** [optional] Show or hide arrow */
|
|
113
30
|
this.showArrow = false;
|
|
114
|
-
/**
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
this.
|
|
31
|
+
/** [optional] Sets padding for Popover container */
|
|
32
|
+
this.padding = "8px";
|
|
33
|
+
this.isVisible = false;
|
|
34
|
+
this.popoverPosition = this.position;
|
|
35
|
+
this.handleKeyDown = this.handleKeyDown.bind(this);
|
|
118
36
|
}
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
this.
|
|
122
|
-
}
|
|
123
|
-
}
|
|
124
|
-
handleOutsideClick(e) {
|
|
125
|
-
const tree = utils.getElementTree(e.target);
|
|
126
|
-
const parent = tree.find((elem) => elem.nodeName.toLowerCase() === "z-popover");
|
|
127
|
-
if (!parent) {
|
|
128
|
-
this.open = false;
|
|
129
|
-
this.positionChange.emit({ position: this.currentPosition });
|
|
130
|
-
}
|
|
37
|
+
emitTriggerClick() {
|
|
38
|
+
this.triggerClick.emit({
|
|
39
|
+
isVisible: this.isVisible,
|
|
40
|
+
});
|
|
131
41
|
}
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
const setPosition = () => {
|
|
147
|
-
if (this.open) {
|
|
148
|
-
this.setPosition();
|
|
149
|
-
this.animationFrameRequestId = requestAnimationFrame(setPosition);
|
|
150
|
-
}
|
|
151
|
-
};
|
|
152
|
-
setPosition();
|
|
153
|
-
}
|
|
154
|
-
else {
|
|
155
|
-
const style = this.host.style;
|
|
156
|
-
style.removeProperty("top");
|
|
157
|
-
style.removeProperty("right");
|
|
158
|
-
style.removeProperty("bottom");
|
|
159
|
-
style.removeProperty("left");
|
|
160
|
-
style.removeProperty("max-width");
|
|
161
|
-
style.removeProperty("max-height");
|
|
162
|
-
this.currentPosition = undefined;
|
|
163
|
-
}
|
|
164
|
-
this.openChange.emit({ open: this.open });
|
|
165
|
-
}
|
|
166
|
-
disconnectedCallback() {
|
|
167
|
-
cancelAnimationFrame(this.animationFrameRequestId);
|
|
168
|
-
}
|
|
169
|
-
/**
|
|
170
|
-
* Set the position of the popover.
|
|
171
|
-
*/
|
|
172
|
-
setPosition() {
|
|
173
|
-
let element;
|
|
174
|
-
if (typeof this.bindTo === "string") {
|
|
175
|
-
element = this.host.ownerDocument.querySelector(this.bindTo);
|
|
176
|
-
}
|
|
177
|
-
else if (this.bindTo) {
|
|
178
|
-
element = this.bindTo;
|
|
179
|
-
}
|
|
180
|
-
else {
|
|
181
|
-
element = this.host.parentElement;
|
|
182
|
-
}
|
|
183
|
-
if (!element) {
|
|
184
|
-
return;
|
|
185
|
-
}
|
|
186
|
-
const scrollContainer = findScrollableParent(element);
|
|
187
|
-
const scrollingBoundingRect = scrollContainer.getBoundingClientRect();
|
|
188
|
-
const offsetContainer = this.host.offsetParent;
|
|
189
|
-
const relativeBoundingRect = offsetContainer
|
|
190
|
-
? computeOffset(offsetContainer, scrollContainer)
|
|
191
|
-
: { top: 0, right: 0, bottom: 0, left: 0 };
|
|
192
|
-
const boundingRect = computeOffset(element, scrollContainer);
|
|
193
|
-
const top = boundingRect.top - scrollContainer.scrollTop;
|
|
194
|
-
const bottom = scrollingBoundingRect.height -
|
|
195
|
-
(boundingRect.top + boundingRect.height) +
|
|
196
|
-
scrollContainer.scrollTop;
|
|
197
|
-
const left = boundingRect.left - scrollContainer.scrollLeft;
|
|
198
|
-
const right = scrollingBoundingRect.width -
|
|
199
|
-
(boundingRect.left + boundingRect.width) +
|
|
200
|
-
scrollContainer.scrollLeft;
|
|
201
|
-
const overflowBottom = Math.max(0, scrollingBoundingRect.top +
|
|
202
|
-
scrollingBoundingRect.height -
|
|
203
|
-
window.innerHeight);
|
|
204
|
-
const overflowRight = Math.max(0, scrollingBoundingRect.left +
|
|
205
|
-
scrollingBoundingRect.width -
|
|
206
|
-
window.innerWidth);
|
|
207
|
-
const availableTop = Math.min(top, top + scrollingBoundingRect.top);
|
|
208
|
-
const availableBottom = Math.min(bottom, bottom - overflowBottom);
|
|
209
|
-
const availableLeft = Math.min(left, left + scrollingBoundingRect.left);
|
|
210
|
-
const availableRight = Math.min(right, right - overflowRight);
|
|
211
|
-
const availableHeight = availableTop + availableBottom + boundingRect.height;
|
|
212
|
-
const availableWidth = availableLeft + availableRight + boundingRect.width;
|
|
213
|
-
let position = this.currentPosition;
|
|
214
|
-
const positions = [];
|
|
215
|
-
if (this.position === index$1.PopoverPositions.AUTO) {
|
|
216
|
-
/**
|
|
217
|
-
* The `AUTO` position tries to place the popover in the 'safest' area,
|
|
218
|
-
* where there's more space available.
|
|
219
|
-
*/
|
|
220
|
-
if (availableLeft / availableWidth > 0.6) {
|
|
221
|
-
positions.push(index$1.PopoverPositions.LEFT);
|
|
42
|
+
openPopover() {
|
|
43
|
+
const width = document.body.clientWidth;
|
|
44
|
+
const height = window.innerHeight;
|
|
45
|
+
const rect = this.popoverElem.getBoundingClientRect();
|
|
46
|
+
const l = rect.left;
|
|
47
|
+
const r = rect.right;
|
|
48
|
+
const t = rect.top;
|
|
49
|
+
const b = rect.bottom;
|
|
50
|
+
let firstSide = this.position.split("-")[0];
|
|
51
|
+
let secondSide = this.position.split("-")[1];
|
|
52
|
+
// If top is outside viewport
|
|
53
|
+
if (t < 0) {
|
|
54
|
+
if (this.position.startsWith("above")) {
|
|
55
|
+
firstSide = "below";
|
|
222
56
|
}
|
|
223
|
-
else
|
|
224
|
-
|
|
57
|
+
else {
|
|
58
|
+
secondSide = "down";
|
|
225
59
|
}
|
|
226
|
-
|
|
227
|
-
|
|
60
|
+
}
|
|
61
|
+
// If bottom is outside viewport
|
|
62
|
+
if (b > height) {
|
|
63
|
+
if (this.position.startsWith("below")) {
|
|
64
|
+
firstSide = "above";
|
|
228
65
|
}
|
|
229
|
-
else
|
|
230
|
-
|
|
66
|
+
else {
|
|
67
|
+
secondSide = "up";
|
|
231
68
|
}
|
|
232
|
-
|
|
233
|
-
|
|
69
|
+
}
|
|
70
|
+
// If right is outside viewport
|
|
71
|
+
if (r > width) {
|
|
72
|
+
if (this.position.startsWith("above") ||
|
|
73
|
+
this.position.startsWith("below")) {
|
|
74
|
+
secondSide = "left";
|
|
234
75
|
}
|
|
235
76
|
else {
|
|
236
|
-
|
|
77
|
+
firstSide = "before";
|
|
237
78
|
}
|
|
238
|
-
position = positions.join("_");
|
|
239
79
|
}
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
const offsetLeft = boundingRect.left - relativeBoundingRect.left;
|
|
246
|
-
const offsetModifier = this.center ? 0.5 : 0;
|
|
247
|
-
const sizeModifier = this.center ? 0.5 : 0;
|
|
248
|
-
if (position === index$1.PopoverPositions.TOP ||
|
|
249
|
-
position === index$1.PopoverPositions.TOP_RIGHT) {
|
|
250
|
-
style.top = "auto";
|
|
251
|
-
style.right = "auto";
|
|
252
|
-
style.bottom = `${offsetBottom + boundingRect.height}px`;
|
|
253
|
-
style.left = `${offsetLeft + boundingRect.width * offsetModifier}px`;
|
|
254
|
-
style.maxHeight = `${availableTop}px`;
|
|
255
|
-
if (position === index$1.PopoverPositions.TOP_RIGHT) {
|
|
256
|
-
style.maxWidth = `${availableRight + boundingRect.width * sizeModifier}px`;
|
|
80
|
+
// If left is outside viewport
|
|
81
|
+
if (l < 0) {
|
|
82
|
+
if (this.position.startsWith("above") ||
|
|
83
|
+
this.position.startsWith("below")) {
|
|
84
|
+
secondSide = "right";
|
|
257
85
|
}
|
|
258
|
-
|
|
259
|
-
|
|
260
|
-
style.top = "auto";
|
|
261
|
-
style.right = `${offsetRight + boundingRect.width * offsetModifier}px`;
|
|
262
|
-
style.bottom = `${offsetBottom + boundingRect.height}px`;
|
|
263
|
-
style.left = "auto";
|
|
264
|
-
style.maxWidth = `${availableLeft}px`;
|
|
265
|
-
style.maxHeight = `${availableTop}px`;
|
|
266
|
-
}
|
|
267
|
-
else if (position === index$1.PopoverPositions.BOTTOM ||
|
|
268
|
-
position === index$1.PopoverPositions.BOTTOM_RIGHT) {
|
|
269
|
-
style.top = `${offsetTop + boundingRect.height}px`;
|
|
270
|
-
style.right = "auto";
|
|
271
|
-
style.bottom = "auto";
|
|
272
|
-
style.left = `${offsetLeft + boundingRect.width * offsetModifier}px`;
|
|
273
|
-
style.maxHeight = `${availableBottom}px`;
|
|
274
|
-
if (position === index$1.PopoverPositions.BOTTOM_RIGHT) {
|
|
275
|
-
style.maxWidth = `${availableRight + boundingRect.width * sizeModifier}px`;
|
|
86
|
+
else {
|
|
87
|
+
firstSide = "after";
|
|
276
88
|
}
|
|
277
89
|
}
|
|
278
|
-
|
|
279
|
-
|
|
280
|
-
|
|
281
|
-
|
|
282
|
-
|
|
283
|
-
|
|
284
|
-
|
|
285
|
-
|
|
286
|
-
|
|
287
|
-
|
|
288
|
-
style.top = `${offsetTop + boundingRect.height * offsetModifier}px`;
|
|
289
|
-
style.right = "auto";
|
|
290
|
-
style.bottom = "auto";
|
|
291
|
-
style.left = `${offsetLeft + boundingRect.width}px`;
|
|
292
|
-
style.maxWidth = `${availableRight}px`;
|
|
293
|
-
style.maxHeight = `${availableBottom + boundingRect.height * sizeModifier}px`;
|
|
294
|
-
}
|
|
295
|
-
else if (position === index$1.PopoverPositions.RIGHT_TOP) {
|
|
296
|
-
style.top = "auto";
|
|
297
|
-
style.right = "auto";
|
|
298
|
-
style.bottom = `${offsetBottom + boundingRect.height * offsetModifier}px`;
|
|
299
|
-
style.left = `${offsetLeft + boundingRect.width}px`;
|
|
300
|
-
style.maxWidth = `${availableRight}px`;
|
|
301
|
-
style.maxHeight = `${availableTop + boundingRect.height * sizeModifier}px`;
|
|
302
|
-
}
|
|
303
|
-
else if (position === index$1.PopoverPositions.LEFT ||
|
|
304
|
-
position === index$1.PopoverPositions.LEFT_BOTTOM) {
|
|
305
|
-
style.top = `${offsetTop + boundingRect.height * offsetModifier}px`;
|
|
306
|
-
style.right = `${offsetRight + boundingRect.width}px`;
|
|
307
|
-
style.bottom = "auto";
|
|
308
|
-
style.left = "auto";
|
|
309
|
-
style.maxWidth = `${availableLeft}px`;
|
|
310
|
-
style.maxHeight = `${availableBottom + boundingRect.height * sizeModifier}px`;
|
|
90
|
+
this.popoverPosition = index$1.PopoverPosition[`${firstSide}-${secondSide}`];
|
|
91
|
+
this.isVisible = true;
|
|
92
|
+
}
|
|
93
|
+
closePopover() {
|
|
94
|
+
this.popoverPosition = this.position;
|
|
95
|
+
this.isVisible = false;
|
|
96
|
+
}
|
|
97
|
+
closePopoverWithKeyboard(e) {
|
|
98
|
+
if (e.key === index$1.KeyboardKeys.ESC) {
|
|
99
|
+
this.closePopover();
|
|
311
100
|
}
|
|
312
|
-
|
|
313
|
-
|
|
314
|
-
|
|
315
|
-
|
|
316
|
-
|
|
317
|
-
|
|
318
|
-
|
|
101
|
+
}
|
|
102
|
+
handleClick(event) {
|
|
103
|
+
this.isVisible ? this.closePopover() : this.openPopover();
|
|
104
|
+
this.emitTriggerClick();
|
|
105
|
+
event.stopPropagation();
|
|
106
|
+
}
|
|
107
|
+
handleKeyDown(event) {
|
|
108
|
+
if (event.code === index$1.KeyboardKeys.ENTER) {
|
|
109
|
+
this.isVisible ? this.closePopover() : this.openPopover();
|
|
319
110
|
}
|
|
320
|
-
this.currentPosition = position || this.position;
|
|
321
|
-
this.host.setAttribute('current-position', this.currentPosition);
|
|
322
111
|
}
|
|
323
|
-
|
|
324
|
-
|
|
325
|
-
|
|
112
|
+
handleOutsideClick(e) {
|
|
113
|
+
const tree = utils.getElementTree(e.target);
|
|
114
|
+
const parent = tree.find((elem) => elem.nodeName.toLowerCase() === "z-popover-deprecated");
|
|
115
|
+
if (!parent) {
|
|
116
|
+
this.closePopover();
|
|
117
|
+
}
|
|
326
118
|
}
|
|
327
119
|
render() {
|
|
328
|
-
return index.h("
|
|
120
|
+
return (index.h(index.Host, { onKeyDown: this.handleKeyDown }, index.h("div", { tabindex: "0", onClick: (event) => this.handleClick(event), onKeyDown: (event) => {
|
|
121
|
+
if (event.key === index$1.KeyboardKeys.ENTER) {
|
|
122
|
+
this.handleClick(event);
|
|
123
|
+
}
|
|
124
|
+
} }, index.h("slot", { name: "trigger" })), index.h("div", { ref: (e) => (this.popoverElem = e), class: index$2.classnames("popover-content-container", this.popoverPosition, `border-radius-${this.borderRadius}`, this.boxShadow, { "show-arrow": this.showArrow }, { visible: this.isVisible }), style: {
|
|
125
|
+
backgroundColor: `var(--${this.backgroundColor})`,
|
|
126
|
+
padding: this.padding,
|
|
127
|
+
} }, index.h("slot", { name: "popover" }))));
|
|
329
128
|
}
|
|
330
|
-
get host() { return index.getElement(this); }
|
|
331
|
-
static get watchers() { return {
|
|
332
|
-
"position": ["validatePosition"],
|
|
333
|
-
"open": ["onOpen"]
|
|
334
|
-
}; }
|
|
335
129
|
};
|
|
336
130
|
ZPopoverDeprecated.style = stylesCss;
|
|
337
131
|
|
|
@@ -3,9 +3,7 @@
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
5
|
const index = require('./index-84b7063a.js');
|
|
6
|
-
const index$1 = require('./index-
|
|
7
|
-
const utils = require('./utils-97262bbd.js');
|
|
8
|
-
require('./breakpoints-88c4fd6c.js');
|
|
6
|
+
const index$1 = require('./index-bc9a5c2b.js');
|
|
9
7
|
|
|
10
8
|
const stylesCss = ":host{--z-popover-theme--surface:var(--color-surface01);--z-popover-theme--text:var(--color-text01);--z-popover-padding:0;--z-popover-shadow-filter:drop-shadow(0 1px 2px var(--shadow-color-base));position:relative;display:none;align-items:center;justify-content:center;padding:var(--z-popover-padding);min-width:calc(var(--space-unit) * 8);min-height:calc(var(--space-unit) * 4);color:var(--z-popover-theme--text);fill:currentColor;font-family:var(--font-family-sans);text-align:center;border-radius:var(--border-radius-small);background:var(--z-popover-theme--surface);filter:var(--z-popover-shadow-filter)}:host([open][current-position]),:host([open=\"true\"][current-position]){display:flex}:host([center][current-position=\"top\"]),:host([center][current-position=\"bottom\"]){transform:translateX(-50%)}:host([center][current-position=\"right\"]),:host([center][current-position=\"left\"]){transform:translateY(-50%)}:host([current-position^=\"top\"]){margin:0 0 var(--space-unit)}:host([current-position^=\"bottom\"]){margin:var(--space-unit) 0 0}:host([current-position^=\"left\"]){margin:0 var(--space-unit) 0 0}:host([current-position^=\"right\"]){margin:0 0 0 var(--space-unit)}:host([current-position])::before{--arrow-size:6px;--arrow-edge-offset:calc(100% - var(--space-unit) - (var(--arrow-size) / 2));--arrow-center-x-offset:calc(50% - (var(--arrow-size) / 2));--arrow-center-y-offset:calc(100% - (var(--arrow-size) / 2));display:block;content:\"\";position:absolute;width:var(--arrow-size);height:var(--arrow-size);background:var(--z-popover-theme--surface);transform:rotate(45deg)}:host([show-arrow=\"false\"])::before,:host(:not([show-arrow]))::before{display:none}:host([current-position^=\"top\"])::before{top:var(--arrow-center-y-offset)}:host([current-position^=\"bottom\"])::before{bottom:var(--arrow-center-y-offset)}:host([current-position=\"top\"])::before,:host([current-position=\"bottom\"])::before{right:var(--arrow-edge-offset)}:host([current-position=\"right\"])::before,:host([current-position=\"left\"])::before{bottom:var(--arrow-edge-offset)}:host([current-position=\"right\"])::before{right:var(--arrow-center-y-offset)}:host([current-position=\"left\"])::before{left:var(--arrow-center-y-offset)}:host([current-position=\"top_right\"])::before,:host([current-position=\"bottom_right\"])::before{right:var(--arrow-edge-offset)}:host([current-position=\"top_left\"])::before,:host([current-position=\"bottom_left\"])::before{left:var(--arrow-edge-offset)}:host([current-position=\"right_top\"])::before,:host([current-position=\"left_top\"])::before{top:var(--arrow-edge-offset)}:host([current-position=\"right_top\"])::before,:host([current-position=\"right_bottom\"])::before{right:var(--arrow-center-y-offset)}:host([current-position=\"left_top\"])::before,:host([current-position=\"left_bottom\"])::before{left:var(--arrow-center-y-offset)}:host([current-position=\"right_bottom\"])::before,:host([current-position=\"left_bottom\"])::before{bottom:var(--arrow-edge-offset)}:host([center][current-position=\"top\"])::before,:host([center][current-position=\"bottom\"])::before{right:auto;left:var(--arrow-center-x-offset)}:host([center][current-position=\"right\"])::before,:host([center][current-position=\"left\"])::before{top:var(--arrow-center-x-offset);bottom:auto}::slotted(*){flex:1 auto;overflow:auto}";
|
|
11
9
|
|
|
@@ -102,7 +100,7 @@ const ZPopover = class {
|
|
|
102
100
|
this.positionChange = index.createEvent(this, "positionChange", 7);
|
|
103
101
|
this.openChange = index.createEvent(this, "openChange", 7);
|
|
104
102
|
/** Popover position. */
|
|
105
|
-
this.position = index$1.PopoverPositions.
|
|
103
|
+
this.position = index$1.PopoverPositions.auto;
|
|
106
104
|
/**
|
|
107
105
|
* The open state of the popover.
|
|
108
106
|
*/
|
|
@@ -129,8 +127,7 @@ const ZPopover = class {
|
|
|
129
127
|
if (!this.closable) {
|
|
130
128
|
return;
|
|
131
129
|
}
|
|
132
|
-
const
|
|
133
|
-
const parent = tree.find((elem) => elem.nodeName.toLowerCase() === "z-popover");
|
|
130
|
+
const parent = e.path.find((elem) => elem === this.host);
|
|
134
131
|
if (!parent) {
|
|
135
132
|
this.open = false;
|
|
136
133
|
this.positionChange.emit({ position: this.currentPosition });
|
|
@@ -138,8 +135,8 @@ const ZPopover = class {
|
|
|
138
135
|
}
|
|
139
136
|
validatePosition(newValue) {
|
|
140
137
|
if (newValue &&
|
|
141
|
-
Object.values(index$1.PopoverPositions).
|
|
142
|
-
this.position = index$1.PopoverPositions.
|
|
138
|
+
!Object.values(index$1.PopoverPositions).includes(newValue)) {
|
|
139
|
+
this.position = index$1.PopoverPositions.auto;
|
|
143
140
|
}
|
|
144
141
|
this.currentPosition = this.position;
|
|
145
142
|
this.positionChange.emit({ position: this.currentPosition });
|
|
@@ -213,28 +210,28 @@ const ZPopover = class {
|
|
|
213
210
|
const availableWidth = availableLeft + availableRight + boundingRect.width;
|
|
214
211
|
let position = this.currentPosition;
|
|
215
212
|
const positions = [];
|
|
216
|
-
if (this.position === index$1.PopoverPositions.
|
|
213
|
+
if (this.position === index$1.PopoverPositions.auto) {
|
|
217
214
|
/**
|
|
218
215
|
* The `AUTO` position tries to place the popover in the 'safest' area,
|
|
219
216
|
* where there's more space available.
|
|
220
217
|
*/
|
|
221
218
|
if (availableLeft / availableWidth > 0.6) {
|
|
222
|
-
positions.push(index$1.PopoverPositions.
|
|
219
|
+
positions.push(index$1.PopoverPositions.left);
|
|
223
220
|
}
|
|
224
221
|
else if (availableLeft / availableWidth < 0.4) {
|
|
225
|
-
positions.push(index$1.PopoverPositions.
|
|
222
|
+
positions.push(index$1.PopoverPositions.right);
|
|
226
223
|
}
|
|
227
224
|
if (availableTop / availableHeight > 0.9) {
|
|
228
|
-
positions.unshift(index$1.PopoverPositions.
|
|
225
|
+
positions.unshift(index$1.PopoverPositions.top);
|
|
229
226
|
}
|
|
230
227
|
else if (availableTop / availableHeight > 0.6) {
|
|
231
|
-
positions.push(index$1.PopoverPositions.
|
|
228
|
+
positions.push(index$1.PopoverPositions.top);
|
|
232
229
|
}
|
|
233
230
|
else if (availableTop / availableHeight < 0.1) {
|
|
234
|
-
positions.unshift(index$1.PopoverPositions.
|
|
231
|
+
positions.unshift(index$1.PopoverPositions.bottom);
|
|
235
232
|
}
|
|
236
233
|
else {
|
|
237
|
-
positions.push(index$1.PopoverPositions.
|
|
234
|
+
positions.push(index$1.PopoverPositions.bottom);
|
|
238
235
|
}
|
|
239
236
|
position = positions.join("_");
|
|
240
237
|
}
|
|
@@ -246,18 +243,18 @@ const ZPopover = class {
|
|
|
246
243
|
const offsetLeft = boundingRect.left - relativeBoundingRect.left;
|
|
247
244
|
const offsetModifier = this.center ? 0.5 : 0;
|
|
248
245
|
const sizeModifier = this.center ? 0.5 : 0;
|
|
249
|
-
if (position === index$1.PopoverPositions.
|
|
250
|
-
position === index$1.PopoverPositions.
|
|
246
|
+
if (position === index$1.PopoverPositions.top ||
|
|
247
|
+
position === index$1.PopoverPositions.top_right) {
|
|
251
248
|
style.top = "auto";
|
|
252
249
|
style.right = "auto";
|
|
253
250
|
style.bottom = `${offsetBottom + boundingRect.height}px`;
|
|
254
251
|
style.left = `${offsetLeft + boundingRect.width * offsetModifier}px`;
|
|
255
252
|
style.maxHeight = `${availableTop}px`;
|
|
256
|
-
if (position === index$1.PopoverPositions.
|
|
253
|
+
if (position === index$1.PopoverPositions.top_right) {
|
|
257
254
|
style.maxWidth = `${availableRight + boundingRect.width * sizeModifier}px`;
|
|
258
255
|
}
|
|
259
256
|
}
|
|
260
|
-
else if (position === index$1.PopoverPositions.
|
|
257
|
+
else if (position === index$1.PopoverPositions.top_left) {
|
|
261
258
|
style.top = "auto";
|
|
262
259
|
style.right = `${offsetRight + boundingRect.width * offsetModifier}px`;
|
|
263
260
|
style.bottom = `${offsetBottom + boundingRect.height}px`;
|
|
@@ -265,18 +262,18 @@ const ZPopover = class {
|
|
|
265
262
|
style.maxWidth = `${availableLeft}px`;
|
|
266
263
|
style.maxHeight = `${availableTop}px`;
|
|
267
264
|
}
|
|
268
|
-
else if (position === index$1.PopoverPositions.
|
|
269
|
-
position === index$1.PopoverPositions.
|
|
265
|
+
else if (position === index$1.PopoverPositions.bottom ||
|
|
266
|
+
position === index$1.PopoverPositions.bottom_right) {
|
|
270
267
|
style.top = `${offsetTop + boundingRect.height}px`;
|
|
271
268
|
style.right = "auto";
|
|
272
269
|
style.bottom = "auto";
|
|
273
270
|
style.left = `${offsetLeft + boundingRect.width * offsetModifier}px`;
|
|
274
271
|
style.maxHeight = `${availableBottom}px`;
|
|
275
|
-
if (position === index$1.PopoverPositions.
|
|
272
|
+
if (position === index$1.PopoverPositions.bottom_right) {
|
|
276
273
|
style.maxWidth = `${availableRight + boundingRect.width * sizeModifier}px`;
|
|
277
274
|
}
|
|
278
275
|
}
|
|
279
|
-
else if (position === index$1.PopoverPositions.
|
|
276
|
+
else if (position === index$1.PopoverPositions.bottom_left) {
|
|
280
277
|
style.top = `${offsetTop + boundingRect.height}px`;
|
|
281
278
|
style.right = `${offsetRight + boundingRect.width * offsetModifier}px`;
|
|
282
279
|
style.bottom = "auto";
|
|
@@ -284,8 +281,8 @@ const ZPopover = class {
|
|
|
284
281
|
style.maxWidth = `${availableLeft}px`;
|
|
285
282
|
style.maxHeight = `${availableBottom}px`;
|
|
286
283
|
}
|
|
287
|
-
else if (position === index$1.PopoverPositions.
|
|
288
|
-
position === index$1.PopoverPositions.
|
|
284
|
+
else if (position === index$1.PopoverPositions.right ||
|
|
285
|
+
position === index$1.PopoverPositions.right_bottom) {
|
|
289
286
|
style.top = `${offsetTop + boundingRect.height * offsetModifier}px`;
|
|
290
287
|
style.right = "auto";
|
|
291
288
|
style.bottom = "auto";
|
|
@@ -293,7 +290,7 @@ const ZPopover = class {
|
|
|
293
290
|
style.maxWidth = `${availableRight}px`;
|
|
294
291
|
style.maxHeight = `${availableBottom + boundingRect.height * sizeModifier}px`;
|
|
295
292
|
}
|
|
296
|
-
else if (position === index$1.PopoverPositions.
|
|
293
|
+
else if (position === index$1.PopoverPositions.right_top) {
|
|
297
294
|
style.top = "auto";
|
|
298
295
|
style.right = "auto";
|
|
299
296
|
style.bottom = `${offsetBottom + boundingRect.height * offsetModifier}px`;
|
|
@@ -301,8 +298,8 @@ const ZPopover = class {
|
|
|
301
298
|
style.maxWidth = `${availableRight}px`;
|
|
302
299
|
style.maxHeight = `${availableTop + boundingRect.height * sizeModifier}px`;
|
|
303
300
|
}
|
|
304
|
-
else if (position === index$1.PopoverPositions.
|
|
305
|
-
position === index$1.PopoverPositions.
|
|
301
|
+
else if (position === index$1.PopoverPositions.left ||
|
|
302
|
+
position === index$1.PopoverPositions.left_bottom) {
|
|
306
303
|
style.top = `${offsetTop + boundingRect.height * offsetModifier}px`;
|
|
307
304
|
style.right = `${offsetRight + boundingRect.width}px`;
|
|
308
305
|
style.bottom = "auto";
|
|
@@ -310,7 +307,7 @@ const ZPopover = class {
|
|
|
310
307
|
style.maxWidth = `${availableLeft}px`;
|
|
311
308
|
style.maxHeight = `${availableBottom + boundingRect.height * sizeModifier}px`;
|
|
312
309
|
}
|
|
313
|
-
else if (position === index$1.PopoverPositions.
|
|
310
|
+
else if (position === index$1.PopoverPositions.left_top) {
|
|
314
311
|
style.top = "auto";
|
|
315
312
|
style.right = `${offsetRight + boundingRect.width}px`;
|
|
316
313
|
style.bottom = `${offsetBottom + boundingRect.height * offsetModifier}px`;
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
5
|
const index = require('./index-84b7063a.js');
|
|
6
|
-
const index$1 = require('./index-
|
|
6
|
+
const index$1 = require('./index-bc9a5c2b.js');
|
|
7
7
|
|
|
8
8
|
const stylesCss = ":host{--z-section-title--divider-color:var(--red500);display:flex;flex-direction:column;align-items:flex-start;width:fit-content;font-family:var(--font-family-sans);font-weight:var(--font-rg)}:host,:host ::slotted(*){box-sizing:border-box}::slotted(*){margin:0}::slotted([slot=\"secondary-title\"]){padding-bottom:calc(var(--space-unit) / 2);border-bottom:var(--border-size-large) solid var(--z-section-title--divider-color);text-transform:uppercase;font-size:var(--font-size-3);line-height:1.5rem}::slotted([slot=\"primary-title\"]){font-size:var(--font-size-6);line-height:2rem}:host([uppercase]) ::slotted([slot=\"primary-title\"]){text-transform:uppercase}@media (min-width: 1152px){::slotted([slot=\"primary-title\"]){font-size:var(--font-size-7);line-height:2.25rem}}";
|
|
9
9
|
|
|
@@ -3,8 +3,8 @@
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
5
|
const index = require('./index-84b7063a.js');
|
|
6
|
-
const utils = require('./utils-
|
|
7
|
-
const index$1 = require('./index-
|
|
6
|
+
const utils = require('./utils-2fa62b67.js');
|
|
7
|
+
const index$1 = require('./index-bc9a5c2b.js');
|
|
8
8
|
require('./breakpoints-88c4fd6c.js');
|
|
9
9
|
|
|
10
10
|
const stylesCss = ".sc-z-skip-to-content-h{font-family:var(--font-family-sans);font-weight:var(--font-rg);position:absolute;left:-100%;background-color:#24f4ff;padding:calc(var(--space-unit) * 1.25) calc(var(--space-unit) * 3);height:60px;box-sizing:border-box}.skip-to-content-visible.sc-z-skip-to-content-h,.sc-z-skip-to-content-h:focus{position:static;display:block}.sc-z-skip-to-content-h>z-link.sc-z-skip-to-content{display:block;text-align:center}.sc-z-skip-to-content-h>z-link.link-invisible.sc-z-skip-to-content{height:0;width:0;overflow:hidden}.sc-z-skip-to-content-h>z-link.link-visible.sc-z-skip-to-content{height:initial;width:initial}.dark.sc-z-skip-to-content-h{background-color:var(--bg-grey-800);color:var(--color-white)}.light.sc-z-skip-to-content-h{background-color:var(--bg-white);color:var(--text-grey-800);border:2px solid var(--text-grey-800)}@media (min-width: 768px){.sc-z-skip-to-content-h>z-link.sc-z-skip-to-content{text-align:left}}@media (min-width: 1152px){.sc-z-skip-to-content-h>z-link.sc-z-skip-to-content{display:inline-block;padding:0 calc(var(--space-unit) * 3);border-right:1px solid var(--bg-grey-800)}.sc-z-skip-to-content-h>z-link.link-invisible.sc-z-skip-to-content{height:initial;width:initial;overflow:initial}.sc-z-skip-to-content-h>z-link.sc-z-skip-to-content:first-child{padding-left:0}.sc-z-skip-to-content-h>z-link.sc-z-skip-to-content:last-child,.dark.sc-z-skip-to-content-h>z-link.sc-z-skip-to-content:last-child,.light.sc-z-skip-to-content-h>z-link.sc-z-skip-to-content:last-child{border-right:none;padding-right:0}.dark.sc-z-skip-to-content-h>z-link.sc-z-skip-to-content{border-right:1px solid var(--bg-white)}}";
|