@zanichelli/albe-web-components 18.7.7 → 18.8.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/CHANGELOG.md +13 -0
- package/dist/cjs/index-96af6326.js +4 -0
- package/dist/cjs/loader.cjs.js +1 -1
- package/dist/cjs/web-components-library.cjs.js +1 -1
- package/dist/cjs/z-alert.cjs.entry.js +1 -1
- package/dist/cjs/z-app-header_12.cjs.entry.js +6 -6
- package/dist/cjs/z-book-card.cjs.entry.js +15 -14
- package/dist/cjs/z-book-card.cjs.entry.js.map +1 -1
- package/dist/{components/placeholder-cover.js → cjs/z-book-cover.cjs.entry.js} +26 -2
- package/dist/cjs/z-book-cover.cjs.entry.js.map +1 -0
- package/dist/cjs/z-breadcrumb.cjs.entry.js +2 -2
- package/dist/cjs/z-button-sort.cjs.entry.js +1 -1
- package/dist/cjs/z-chip.cjs.entry.js +2 -2
- package/dist/cjs/z-combobox.cjs.entry.js +1 -1
- package/dist/cjs/z-cover-hero.cjs.entry.js +2 -2
- package/dist/cjs/z-dragdrop-area_2.cjs.entry.js +4 -4
- package/dist/cjs/z-ghost-loading.cjs.entry.js +1 -1
- package/dist/cjs/z-info-box.cjs.entry.js +1 -1
- package/dist/cjs/z-info-reveal.cjs.entry.js +1 -1
- package/dist/cjs/z-logo.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-sections.cjs.entry.js +1 -1
- package/dist/cjs/z-myz-card-footer.cjs.entry.js +1 -1
- package/dist/cjs/z-myz-card-icon.cjs.entry.js +1 -1
- package/dist/cjs/z-myz-card-info.cjs.entry.js +1 -1
- package/dist/cjs/z-myz-card-list.cjs.entry.js +1 -1
- package/dist/cjs/z-myz-card_4.cjs.entry.js +4 -4
- package/dist/cjs/z-myz-list-item.cjs.entry.js +1 -1
- package/dist/cjs/z-myz-list.cjs.entry.js +1 -1
- package/dist/cjs/z-navigation-tabs.cjs.entry.js +2 -2
- package/dist/cjs/z-notification.cjs.entry.js +1 -1
- package/dist/cjs/z-otp.cjs.entry.js +2 -2
- package/dist/cjs/z-panel-elem.cjs.entry.js +2 -2
- package/dist/cjs/z-popover.cjs.entry.js +1 -1
- package/dist/cjs/z-result-card.cjs.entry.js +6 -14
- package/dist/cjs/z-result-card.cjs.entry.js.map +1 -1
- package/dist/cjs/z-select.cjs.entry.js +1 -1
- package/dist/cjs/z-skip-to-content.cjs.entry.js +1 -1
- package/dist/cjs/z-stepper-item.cjs.entry.js +1 -1
- package/dist/cjs/z-stepper.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-button.cjs.entry.js +2 -2
- package/dist/cjs/z-toggle-switch.cjs.entry.js +3 -3
- package/dist/cjs/z-tooltip.cjs.entry.js +1 -1
- package/dist/collection/collection-manifest.json +2 -1
- package/dist/collection/components/book-card/z-book-card/index.js +66 -29
- package/dist/collection/components/book-card/z-book-card/index.js.map +1 -1
- package/dist/collection/components/book-card/z-book-card/index.stories.js +11 -13
- package/dist/collection/components/book-card/z-book-card/index.stories.js.map +1 -1
- package/dist/collection/components/book-card/z-book-card/styles.css +35 -67
- package/dist/collection/components/z-book-cover/index.js +113 -0
- package/dist/collection/components/z-book-cover/index.js.map +1 -0
- package/dist/collection/components/z-book-cover/index.stories.js +31 -0
- package/dist/collection/components/z-book-cover/index.stories.js.map +1 -0
- package/dist/collection/components/z-book-cover/styles.css +95 -0
- package/dist/collection/components/z-breadcrumb/index.js +2 -2
- package/dist/collection/components/z-button-sort/index.js +1 -1
- package/dist/collection/components/z-chip/index.js +2 -2
- package/dist/collection/components/z-combobox/index.js +1 -1
- package/dist/collection/components/z-cover-hero/index.js +2 -2
- package/dist/collection/components/z-divider/index.js +1 -1
- package/dist/collection/components/z-ghost-loading/index.js +1 -1
- package/dist/collection/components/z-info-box/index.js +1 -1
- package/dist/collection/components/z-info-reveal/index.js +1 -1
- package/dist/collection/components/z-input/index.js +1 -1
- package/dist/collection/components/z-input-message/index.js +1 -1
- package/dist/collection/components/z-logo/index.js +1 -1
- package/dist/collection/components/z-modal/index.js +4 -4
- package/dist/collection/components/z-navigation-tabs/index.js +2 -2
- package/dist/collection/components/z-notification/index.js +1 -1
- package/dist/collection/components/z-offcanvas/index.js +2 -2
- package/dist/collection/components/z-panel-elem/index.js +2 -2
- package/dist/collection/components/z-popover/index.js +1 -1
- package/dist/collection/components/{result-card/z-result-card → z-result-card}/index.js +10 -18
- package/dist/collection/components/z-result-card/index.js.map +1 -0
- package/dist/collection/components/{result-card/z-result-card → z-result-card}/styles.css +39 -108
- package/dist/collection/components/z-result-card/z-result-card.stories.js.map +1 -0
- package/dist/collection/components/z-searchbar/index.js +1 -1
- package/dist/collection/components/z-select/index.js +1 -1
- package/dist/collection/components/z-skip-to-content/index.js +1 -1
- package/dist/collection/components/z-stepper/index.js +1 -1
- package/dist/collection/components/z-stepper-item/index.js +1 -1
- package/dist/collection/components/z-toast-notification/index.js +1 -1
- package/dist/collection/components/z-toast-notification-list/index.js +1 -1
- package/dist/collection/components/z-toggle-button/index.js +2 -2
- package/dist/collection/components/z-toggle-switch/index.js +3 -3
- package/dist/collection/components/z-tooltip/index.js +1 -1
- package/dist/collection/snowflakes/myz/card/z-myz-card/index.js +1 -1
- package/dist/collection/snowflakes/myz/card/z-myz-card-alert/index.js +1 -1
- package/dist/collection/snowflakes/myz/card/z-myz-card-body/index.js +1 -1
- package/dist/collection/snowflakes/myz/card/z-myz-card-cover/index.js +1 -1
- package/dist/collection/snowflakes/myz/card/z-myz-card-dictionary/index.js +1 -1
- package/dist/collection/snowflakes/myz/card/z-myz-card-footer/index.js +1 -1
- package/dist/collection/snowflakes/myz/card/z-myz-card-footer-sections/index.js +1 -1
- package/dist/collection/snowflakes/myz/card/z-myz-card-header/index.js +1 -1
- package/dist/collection/snowflakes/myz/card/z-myz-card-icon/index.js +1 -1
- package/dist/collection/snowflakes/myz/card/z-myz-card-info/index.js +1 -1
- package/dist/collection/snowflakes/myz/card/z-myz-card-list/index.js +1 -1
- package/dist/collection/snowflakes/myz/list/z-myz-list/index.js +1 -1
- package/dist/collection/snowflakes/myz/list/z-myz-list-item/index.js +1 -1
- package/dist/collection/snowflakes/myz/z-alert/index.js +1 -1
- package/dist/collection/snowflakes/myz/z-otp/index.js +2 -2
- package/dist/components/index.d.ts +3 -1
- package/dist/components/index.js +1 -0
- package/dist/components/index.js.map +1 -1
- package/dist/components/index10.js +24 -65
- package/dist/components/index10.js.map +1 -1
- package/dist/components/index11.js +58 -306
- package/dist/components/index11.js.map +1 -1
- package/dist/components/index12.js +311 -37
- package/dist/components/index12.js.map +1 -1
- package/dist/components/index13.js +40 -27
- package/dist/components/index13.js.map +1 -1
- package/dist/components/index14.js +23 -151
- package/dist/components/index14.js.map +1 -1
- package/dist/components/index15.js +144 -37
- package/dist/components/index15.js.map +1 -1
- package/dist/components/index16.js +42 -1008
- package/dist/components/index16.js.map +1 -1
- package/dist/components/index17.js +1012 -37
- package/dist/components/index17.js.map +1 -1
- package/dist/components/index18.js +42 -10
- package/dist/components/index18.js.map +1 -1
- package/dist/components/index19.js +10 -22
- package/dist/components/index19.js.map +1 -1
- package/dist/components/index20.js +16 -33
- package/dist/components/index20.js.map +1 -1
- package/dist/components/index21.js +39 -43
- package/dist/components/index21.js.map +1 -1
- package/dist/components/index22.js +44 -84
- package/dist/components/index22.js.map +1 -1
- package/dist/components/index23.js +60 -430
- package/dist/components/index23.js.map +1 -1
- package/dist/components/index24.js +415 -341
- package/dist/components/index24.js.map +1 -1
- package/dist/components/index25.js +376 -19
- package/dist/components/index25.js.map +1 -1
- package/dist/components/index26.js +45 -0
- package/dist/components/index26.js.map +1 -0
- package/dist/components/index3.js +1 -1
- package/dist/components/index4.js +23 -60
- package/dist/components/index4.js.map +1 -1
- package/dist/components/index5.js +53 -27
- package/dist/components/index5.js.map +1 -1
- package/dist/components/index6.js +34 -18
- package/dist/components/index6.js.map +1 -1
- package/dist/components/index7.js +18 -41
- package/dist/components/index7.js.map +1 -1
- package/dist/components/index8.js +41 -11
- package/dist/components/index8.js.map +1 -1
- package/dist/components/index9.js +10 -28
- package/dist/components/index9.js.map +1 -1
- package/dist/components/z-accordion.js +1 -1
- package/dist/components/z-anchor-navigation.js +2 -2
- package/dist/components/z-app-header-deprecated.js +11 -11
- package/dist/components/z-app-header.js +11 -11
- package/dist/components/z-book-card-app.js +2 -2
- package/dist/components/z-book-card-deprecated.js +1 -1
- package/dist/components/z-book-card.js +26 -17
- package/dist/components/z-book-card.js.map +1 -1
- package/dist/components/z-book-cover.d.ts +11 -0
- package/dist/components/z-book-cover.js +8 -0
- package/dist/components/z-book-cover.js.map +1 -0
- package/dist/components/z-breadcrumb.js +8 -8
- package/dist/components/z-button-sort.js +2 -2
- package/dist/components/z-button.js +1 -1
- package/dist/components/z-card.js +1 -1
- package/dist/components/z-carousel.js +3 -3
- package/dist/components/z-chip.js +1 -1
- package/dist/components/z-combobox.js +7 -7
- package/dist/components/z-cover-hero.js +2 -2
- package/dist/components/z-date-picker.js +3 -3
- package/dist/components/z-divider.js +1 -1
- package/dist/components/z-dragdrop-area.js +1 -1
- package/dist/components/z-file-upload.js +4 -4
- package/dist/components/z-file.js +3 -3
- package/dist/components/z-ghost-loading.js +1 -1
- package/dist/components/z-icon.js +1 -1
- package/dist/components/z-info-box.js +2 -2
- package/dist/components/z-info-reveal.js +1 -1
- package/dist/components/z-input-message.js +1 -1
- package/dist/components/z-input.js +1 -1
- package/dist/components/z-list-element.js +1 -1
- package/dist/components/z-list-group.js +1 -1
- package/dist/components/z-list.js +1 -1
- package/dist/components/z-logo.js +1 -1
- package/dist/components/z-menu-deprecated.js +1 -1
- package/dist/components/z-menu-section-deprecated.js +1 -1
- package/dist/components/z-menu-section.js +1 -1
- package/dist/components/z-menu.js +1 -1
- package/dist/components/z-modal.js +1 -1
- package/dist/components/z-myz-card-alert.js +2 -2
- package/dist/components/z-myz-card-body.js +1 -1
- package/dist/components/z-myz-card-cover.js +1 -1
- package/dist/components/z-myz-card-dictionary.js +7 -7
- package/dist/components/z-myz-card-footer-sections.js +1 -1
- package/dist/components/z-myz-card-footer.js +1 -1
- package/dist/components/z-myz-card-header.js +1 -1
- package/dist/components/z-myz-card-icon.js +2 -2
- package/dist/components/z-myz-card-info.js +3 -3
- package/dist/components/z-myz-card-list.js +1 -1
- package/dist/components/z-myz-card.js +1 -1
- package/dist/components/z-myz-list-item.js +1 -1
- package/dist/components/z-myz-list.js +3 -3
- package/dist/components/z-navigation-tabs.js +3 -3
- package/dist/components/z-notification.js +2 -2
- package/dist/components/z-offcanvas.js +1 -1
- package/dist/components/z-otp.js +4 -4
- package/dist/components/z-pagination.js +4 -4
- package/dist/components/z-panel-elem.js +3 -3
- package/dist/components/z-popover.js +1 -1
- package/dist/components/z-range-picker.js +3 -3
- package/dist/components/z-result-card.js +14 -16
- package/dist/components/z-result-card.js.map +1 -1
- package/dist/components/z-searchbar.js +1 -1
- package/dist/components/z-section-title.js +1 -1
- package/dist/components/z-select.js +9 -9
- package/dist/components/z-skip-to-content.js +1 -1
- package/dist/components/z-slideshow.js +1 -1
- package/dist/components/z-stepper-item.js +2 -2
- package/dist/components/z-stepper.js +1 -1
- package/dist/components/z-table.js +1 -1
- package/dist/components/z-tag.js +1 -1
- package/dist/components/z-td.js +3 -3
- package/dist/components/z-th.js +3 -3
- package/dist/components/z-toast-notification-list.js +1 -1
- package/dist/components/z-toast-notification.js +2 -2
- package/dist/components/z-toggle-button.js +3 -3
- package/dist/components/z-toggle-switch.js +4 -4
- package/dist/components/z-tooltip.js +2 -2
- package/dist/components/z-tr.js +2 -2
- package/dist/components/z-tree-list.js +4 -4
- package/dist/esm/index-c8ceadeb.js +4 -0
- package/dist/esm/loader.js +1 -1
- package/dist/esm/web-components-library.js +1 -1
- package/dist/esm/z-alert.entry.js +1 -1
- package/dist/esm/z-app-header_12.entry.js +6 -6
- package/dist/esm/z-book-card.entry.js +15 -14
- package/dist/esm/z-book-card.entry.js.map +1 -1
- package/dist/{cjs/placeholder-cover-b679e768.js → esm/z-book-cover.entry.js} +21 -3
- package/dist/esm/z-book-cover.entry.js.map +1 -0
- package/dist/esm/z-breadcrumb.entry.js +2 -2
- package/dist/esm/z-button-sort.entry.js +1 -1
- package/dist/esm/z-chip.entry.js +2 -2
- package/dist/esm/z-combobox.entry.js +1 -1
- package/dist/esm/z-cover-hero.entry.js +2 -2
- package/dist/esm/z-dragdrop-area_2.entry.js +4 -4
- package/dist/esm/z-ghost-loading.entry.js +1 -1
- package/dist/esm/z-info-box.entry.js +1 -1
- package/dist/esm/z-info-reveal.entry.js +1 -1
- package/dist/esm/z-logo.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-sections.entry.js +1 -1
- package/dist/esm/z-myz-card-footer.entry.js +1 -1
- package/dist/esm/z-myz-card-icon.entry.js +1 -1
- package/dist/esm/z-myz-card-info.entry.js +1 -1
- package/dist/esm/z-myz-card-list.entry.js +1 -1
- package/dist/esm/z-myz-card_4.entry.js +4 -4
- package/dist/esm/z-myz-list-item.entry.js +1 -1
- package/dist/esm/z-myz-list.entry.js +1 -1
- package/dist/esm/z-navigation-tabs.entry.js +2 -2
- package/dist/esm/z-notification.entry.js +1 -1
- package/dist/esm/z-otp.entry.js +2 -2
- package/dist/esm/z-panel-elem.entry.js +2 -2
- package/dist/esm/z-popover.entry.js +1 -1
- package/dist/esm/z-result-card.entry.js +6 -14
- package/dist/esm/z-result-card.entry.js.map +1 -1
- package/dist/esm/z-select.entry.js +1 -1
- package/dist/esm/z-skip-to-content.entry.js +1 -1
- package/dist/esm/z-stepper-item.entry.js +1 -1
- package/dist/esm/z-stepper.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-button.entry.js +2 -2
- package/dist/esm/z-toggle-switch.entry.js +3 -3
- package/dist/esm/z-tooltip.entry.js +1 -1
- package/dist/types/components/book-card/z-book-card/index.d.ts +20 -16
- package/dist/types/components/book-card/z-book-card/index.stories.d.ts +2 -35
- package/dist/types/components/z-book-cover/index.d.ts +23 -0
- package/dist/types/components/z-book-cover/index.stories.d.ts +21 -0
- package/dist/types/components/{result-card/z-result-card → z-result-card}/index.d.ts +8 -26
- package/dist/types/components.d.ts +145 -44
- package/dist/web-components-library/{p-17259f80.entry.js → p-01f941c2.entry.js} +2 -2
- package/{www/build/p-a4e26cad.entry.js → dist/web-components-library/p-028dd72a.entry.js} +2 -2
- package/{www/build/p-fef12692.entry.js → dist/web-components-library/p-0990d475.entry.js} +2 -2
- package/dist/web-components-library/{p-fa9c35b7.entry.js → p-0a49dd1c.entry.js} +2 -2
- package/dist/web-components-library/{p-7faf6680.entry.js → p-240de9aa.entry.js} +2 -2
- package/dist/web-components-library/p-28534fb5.entry.js +2 -0
- package/dist/web-components-library/{p-755e5bb3.entry.js → p-28d83c86.entry.js} +2 -2
- package/dist/web-components-library/{p-04f578d3.entry.js → p-2ffdfbb1.entry.js} +2 -2
- package/dist/web-components-library/p-31bd2a1c.entry.js +2 -0
- package/dist/web-components-library/p-31bd2a1c.entry.js.map +1 -0
- package/dist/web-components-library/{p-da6ba08a.entry.js → p-460b2068.entry.js} +2 -2
- package/dist/web-components-library/{p-bfa7b528.entry.js → p-46ea0b2e.entry.js} +2 -2
- package/{www/build/p-add09050.entry.js → dist/web-components-library/p-4a257653.entry.js} +2 -2
- package/{www/build/p-d3a51980.entry.js → dist/web-components-library/p-4aaf0172.entry.js} +2 -2
- package/dist/web-components-library/{p-22056263.entry.js → p-4affbb99.entry.js} +2 -2
- package/dist/web-components-library/{p-9f516be2.entry.js → p-5989465b.entry.js} +2 -2
- package/dist/web-components-library/{p-1775f79b.entry.js → p-5a1f98a2.entry.js} +2 -2
- package/dist/web-components-library/{p-a25c7fdb.entry.js → p-5c5882c6.entry.js} +2 -2
- package/dist/web-components-library/{p-a80faa78.entry.js → p-5f94986f.entry.js} +2 -2
- package/dist/web-components-library/p-6cff173f.entry.js +2 -0
- package/dist/web-components-library/p-6cffbabc.entry.js +2 -0
- package/{www/build/p-5f231799.entry.js.map → dist/web-components-library/p-6cffbabc.entry.js.map} +1 -1
- package/dist/web-components-library/{p-9e3116b0.entry.js → p-7194003a.entry.js} +2 -2
- package/{www/build/p-9de4915b.entry.js → dist/web-components-library/p-78146cef.entry.js} +2 -2
- package/dist/web-components-library/{p-f39f6ee8.entry.js → p-7a4f6a5b.entry.js} +2 -2
- package/dist/web-components-library/{p-945928ff.entry.js → p-7ceddb7a.entry.js} +2 -2
- package/dist/web-components-library/{p-50b800e6.entry.js → p-86160fe3.entry.js} +2 -2
- package/dist/web-components-library/{p-2105d5ec.entry.js → p-863fd1c4.entry.js} +2 -2
- package/dist/web-components-library/p-8fc213c2.entry.js +2 -0
- package/{www/build/p-b0f80e50.entry.js.map → dist/web-components-library/p-8fc213c2.entry.js.map} +1 -1
- package/dist/web-components-library/{p-70aa0b22.entry.js → p-943db3a8.entry.js} +2 -2
- package/dist/web-components-library/{p-6d2a6434.entry.js → p-94916bdf.entry.js} +2 -2
- package/dist/web-components-library/{p-8e5bc362.entry.js → p-a2e87cec.entry.js} +2 -2
- package/dist/web-components-library/{p-fe663393.entry.js → p-ac477ae7.entry.js} +2 -2
- package/dist/web-components-library/p-af5e8524.entry.js +2 -0
- package/dist/web-components-library/{p-fb78c343.entry.js → p-b3f1b5c1.entry.js} +2 -2
- package/dist/web-components-library/{p-6ebaa41d.entry.js → p-d60684d5.entry.js} +2 -2
- package/dist/web-components-library/{p-2264883d.entry.js → p-dc086eb5.entry.js} +2 -2
- package/dist/web-components-library/{p-f3287280.entry.js → p-e0b88075.entry.js} +2 -2
- package/dist/web-components-library/p-e4bb1256.entry.js +2 -0
- package/dist/web-components-library/p-e4bb1256.entry.js.map +1 -0
- package/dist/web-components-library/{p-7eb0e121.entry.js → p-f487290e.entry.js} +2 -2
- package/dist/web-components-library/p-f4bac89b.entry.js +2 -0
- package/dist/web-components-library/p-f4bac89b.entry.js.map +1 -0
- package/dist/web-components-library/web-components-library.esm.js +1 -1
- package/dist/web-components-library/web-components-library.esm.js.map +1 -1
- package/package.json +1 -1
- package/react/components.d.ts +1 -0
- package/react/components.js +3 -2
- package/react/components.js.map +1 -1
- package/www/build/{p-17259f80.entry.js → p-01f941c2.entry.js} +2 -2
- package/{dist/web-components-library/p-a4e26cad.entry.js → www/build/p-028dd72a.entry.js} +2 -2
- package/{dist/web-components-library/p-fef12692.entry.js → www/build/p-0990d475.entry.js} +2 -2
- package/www/build/{p-fa9c35b7.entry.js → p-0a49dd1c.entry.js} +2 -2
- package/www/build/{p-7faf6680.entry.js → p-240de9aa.entry.js} +2 -2
- package/www/build/p-28534fb5.entry.js +2 -0
- package/www/build/{p-755e5bb3.entry.js → p-28d83c86.entry.js} +2 -2
- package/www/build/{p-04f578d3.entry.js → p-2ffdfbb1.entry.js} +2 -2
- package/www/build/p-31bd2a1c.entry.js +2 -0
- package/www/build/p-31bd2a1c.entry.js.map +1 -0
- package/www/build/{p-da6ba08a.entry.js → p-460b2068.entry.js} +2 -2
- package/www/build/{p-bfa7b528.entry.js → p-46ea0b2e.entry.js} +2 -2
- package/{dist/web-components-library/p-add09050.entry.js → www/build/p-4a257653.entry.js} +2 -2
- package/{dist/web-components-library/p-d3a51980.entry.js → www/build/p-4aaf0172.entry.js} +2 -2
- package/www/build/{p-22056263.entry.js → p-4affbb99.entry.js} +2 -2
- package/www/build/{p-9f516be2.entry.js → p-5989465b.entry.js} +2 -2
- package/www/build/{p-1775f79b.entry.js → p-5a1f98a2.entry.js} +2 -2
- package/www/build/{p-a25c7fdb.entry.js → p-5c5882c6.entry.js} +2 -2
- package/www/build/{p-a80faa78.entry.js → p-5f94986f.entry.js} +2 -2
- package/www/build/p-6cff173f.entry.js +2 -0
- package/www/build/p-6cffbabc.entry.js +2 -0
- package/{dist/web-components-library/p-5f231799.entry.js.map → www/build/p-6cffbabc.entry.js.map} +1 -1
- package/www/build/{p-9e3116b0.entry.js → p-7194003a.entry.js} +2 -2
- package/{dist/web-components-library/p-9de4915b.entry.js → www/build/p-78146cef.entry.js} +2 -2
- package/www/build/{p-f39f6ee8.entry.js → p-7a4f6a5b.entry.js} +2 -2
- package/www/build/{p-945928ff.entry.js → p-7ceddb7a.entry.js} +2 -2
- package/www/build/{p-50b800e6.entry.js → p-86160fe3.entry.js} +2 -2
- package/www/build/{p-2105d5ec.entry.js → p-863fd1c4.entry.js} +2 -2
- package/www/build/p-8fc213c2.entry.js +2 -0
- package/{dist/web-components-library/p-b0f80e50.entry.js.map → www/build/p-8fc213c2.entry.js.map} +1 -1
- package/www/build/{p-70aa0b22.entry.js → p-943db3a8.entry.js} +2 -2
- package/www/build/{p-6d2a6434.entry.js → p-94916bdf.entry.js} +2 -2
- package/www/build/{p-8e5bc362.entry.js → p-a2e87cec.entry.js} +2 -2
- package/www/build/{p-fe663393.entry.js → p-ac477ae7.entry.js} +2 -2
- package/www/build/p-af5e8524.entry.js +2 -0
- package/www/build/{p-fb78c343.entry.js → p-b3f1b5c1.entry.js} +2 -2
- package/www/build/p-b716b49c.js +2 -0
- package/www/build/{p-6ebaa41d.entry.js → p-d60684d5.entry.js} +2 -2
- package/www/build/{p-2264883d.entry.js → p-dc086eb5.entry.js} +2 -2
- package/www/build/{p-f3287280.entry.js → p-e0b88075.entry.js} +2 -2
- package/www/build/p-e4bb1256.entry.js +2 -0
- package/www/build/p-e4bb1256.entry.js.map +1 -0
- package/www/build/{p-7eb0e121.entry.js → p-f487290e.entry.js} +2 -2
- package/www/build/p-f4bac89b.entry.js +2 -0
- package/www/build/p-f4bac89b.entry.js.map +1 -0
- package/www/build/web-components-library.esm.js +1 -1
- package/www/build/web-components-library.esm.js.map +1 -1
- package/www/index.html +1 -1
- package/dist/cjs/placeholder-cover-b679e768.js.map +0 -1
- package/dist/collection/components/result-card/z-result-card/index.js.map +0 -1
- package/dist/collection/components/result-card/z-result-card/z-result-card.stories.js.map +0 -1
- package/dist/components/placeholder-cover.js.map +0 -1
- package/dist/esm/placeholder-cover-9346be8f.js +0 -5
- package/dist/esm/placeholder-cover-9346be8f.js.map +0 -1
- package/dist/web-components-library/p-165d5acc.entry.js +0 -2
- package/dist/web-components-library/p-165d5acc.entry.js.map +0 -1
- package/dist/web-components-library/p-5f231799.entry.js +0 -2
- package/dist/web-components-library/p-75d50d5f.entry.js +0 -2
- package/dist/web-components-library/p-8d923a1d.js +0 -2
- package/dist/web-components-library/p-8d923a1d.js.map +0 -1
- package/dist/web-components-library/p-970de597.entry.js +0 -2
- package/dist/web-components-library/p-abd17b10.entry.js +0 -2
- package/dist/web-components-library/p-abd17b10.entry.js.map +0 -1
- package/dist/web-components-library/p-b0f80e50.entry.js +0 -2
- package/dist/web-components-library/p-e0320349.entry.js +0 -2
- package/www/build/p-165d5acc.entry.js +0 -2
- package/www/build/p-165d5acc.entry.js.map +0 -1
- package/www/build/p-29dcbeae.js +0 -2
- package/www/build/p-5f231799.entry.js +0 -2
- package/www/build/p-75d50d5f.entry.js +0 -2
- package/www/build/p-8d923a1d.js +0 -2
- package/www/build/p-8d923a1d.js.map +0 -1
- package/www/build/p-970de597.entry.js +0 -2
- package/www/build/p-abd17b10.entry.js +0 -2
- package/www/build/p-abd17b10.entry.js.map +0 -1
- package/www/build/p-b0f80e50.entry.js +0 -2
- package/www/build/p-e0320349.entry.js +0 -2
- /package/dist/collection/components/{result-card/z-result-card → z-result-card}/z-result-card.stories.js +0 -0
- /package/dist/types/components/{result-card/z-result-card → z-result-card}/z-result-card.stories.d.ts +0 -0
- /package/dist/web-components-library/{p-17259f80.entry.js.map → p-01f941c2.entry.js.map} +0 -0
- /package/dist/web-components-library/{p-a4e26cad.entry.js.map → p-028dd72a.entry.js.map} +0 -0
- /package/dist/web-components-library/{p-fef12692.entry.js.map → p-0990d475.entry.js.map} +0 -0
- /package/dist/web-components-library/{p-fa9c35b7.entry.js.map → p-0a49dd1c.entry.js.map} +0 -0
- /package/dist/web-components-library/{p-7faf6680.entry.js.map → p-240de9aa.entry.js.map} +0 -0
- /package/dist/web-components-library/{p-970de597.entry.js.map → p-28534fb5.entry.js.map} +0 -0
- /package/dist/web-components-library/{p-755e5bb3.entry.js.map → p-28d83c86.entry.js.map} +0 -0
- /package/dist/web-components-library/{p-04f578d3.entry.js.map → p-2ffdfbb1.entry.js.map} +0 -0
- /package/dist/web-components-library/{p-da6ba08a.entry.js.map → p-460b2068.entry.js.map} +0 -0
- /package/dist/web-components-library/{p-bfa7b528.entry.js.map → p-46ea0b2e.entry.js.map} +0 -0
- /package/dist/web-components-library/{p-add09050.entry.js.map → p-4a257653.entry.js.map} +0 -0
- /package/dist/web-components-library/{p-d3a51980.entry.js.map → p-4aaf0172.entry.js.map} +0 -0
- /package/dist/web-components-library/{p-22056263.entry.js.map → p-4affbb99.entry.js.map} +0 -0
- /package/dist/web-components-library/{p-9f516be2.entry.js.map → p-5989465b.entry.js.map} +0 -0
- /package/dist/web-components-library/{p-1775f79b.entry.js.map → p-5a1f98a2.entry.js.map} +0 -0
- /package/dist/web-components-library/{p-a25c7fdb.entry.js.map → p-5c5882c6.entry.js.map} +0 -0
- /package/dist/web-components-library/{p-a80faa78.entry.js.map → p-5f94986f.entry.js.map} +0 -0
- /package/dist/web-components-library/{p-e0320349.entry.js.map → p-6cff173f.entry.js.map} +0 -0
- /package/dist/web-components-library/{p-9e3116b0.entry.js.map → p-7194003a.entry.js.map} +0 -0
- /package/dist/web-components-library/{p-9de4915b.entry.js.map → p-78146cef.entry.js.map} +0 -0
- /package/dist/web-components-library/{p-f39f6ee8.entry.js.map → p-7a4f6a5b.entry.js.map} +0 -0
- /package/dist/web-components-library/{p-945928ff.entry.js.map → p-7ceddb7a.entry.js.map} +0 -0
- /package/dist/web-components-library/{p-50b800e6.entry.js.map → p-86160fe3.entry.js.map} +0 -0
- /package/dist/web-components-library/{p-2105d5ec.entry.js.map → p-863fd1c4.entry.js.map} +0 -0
- /package/dist/web-components-library/{p-70aa0b22.entry.js.map → p-943db3a8.entry.js.map} +0 -0
- /package/dist/web-components-library/{p-6d2a6434.entry.js.map → p-94916bdf.entry.js.map} +0 -0
- /package/dist/web-components-library/{p-8e5bc362.entry.js.map → p-a2e87cec.entry.js.map} +0 -0
- /package/dist/web-components-library/{p-fe663393.entry.js.map → p-ac477ae7.entry.js.map} +0 -0
- /package/dist/web-components-library/{p-75d50d5f.entry.js.map → p-af5e8524.entry.js.map} +0 -0
- /package/dist/web-components-library/{p-fb78c343.entry.js.map → p-b3f1b5c1.entry.js.map} +0 -0
- /package/dist/web-components-library/{p-6ebaa41d.entry.js.map → p-d60684d5.entry.js.map} +0 -0
- /package/dist/web-components-library/{p-2264883d.entry.js.map → p-dc086eb5.entry.js.map} +0 -0
- /package/dist/web-components-library/{p-f3287280.entry.js.map → p-e0b88075.entry.js.map} +0 -0
- /package/dist/web-components-library/{p-7eb0e121.entry.js.map → p-f487290e.entry.js.map} +0 -0
- /package/www/build/{p-17259f80.entry.js.map → p-01f941c2.entry.js.map} +0 -0
- /package/www/build/{p-a4e26cad.entry.js.map → p-028dd72a.entry.js.map} +0 -0
- /package/www/build/{p-fef12692.entry.js.map → p-0990d475.entry.js.map} +0 -0
- /package/www/build/{p-fa9c35b7.entry.js.map → p-0a49dd1c.entry.js.map} +0 -0
- /package/www/build/{p-7faf6680.entry.js.map → p-240de9aa.entry.js.map} +0 -0
- /package/www/build/{p-970de597.entry.js.map → p-28534fb5.entry.js.map} +0 -0
- /package/www/build/{p-755e5bb3.entry.js.map → p-28d83c86.entry.js.map} +0 -0
- /package/www/build/{p-04f578d3.entry.js.map → p-2ffdfbb1.entry.js.map} +0 -0
- /package/www/build/{p-da6ba08a.entry.js.map → p-460b2068.entry.js.map} +0 -0
- /package/www/build/{p-bfa7b528.entry.js.map → p-46ea0b2e.entry.js.map} +0 -0
- /package/www/build/{p-add09050.entry.js.map → p-4a257653.entry.js.map} +0 -0
- /package/www/build/{p-d3a51980.entry.js.map → p-4aaf0172.entry.js.map} +0 -0
- /package/www/build/{p-22056263.entry.js.map → p-4affbb99.entry.js.map} +0 -0
- /package/www/build/{p-9f516be2.entry.js.map → p-5989465b.entry.js.map} +0 -0
- /package/www/build/{p-1775f79b.entry.js.map → p-5a1f98a2.entry.js.map} +0 -0
- /package/www/build/{p-a25c7fdb.entry.js.map → p-5c5882c6.entry.js.map} +0 -0
- /package/www/build/{p-a80faa78.entry.js.map → p-5f94986f.entry.js.map} +0 -0
- /package/www/build/{p-e0320349.entry.js.map → p-6cff173f.entry.js.map} +0 -0
- /package/www/build/{p-9e3116b0.entry.js.map → p-7194003a.entry.js.map} +0 -0
- /package/www/build/{p-9de4915b.entry.js.map → p-78146cef.entry.js.map} +0 -0
- /package/www/build/{p-f39f6ee8.entry.js.map → p-7a4f6a5b.entry.js.map} +0 -0
- /package/www/build/{p-945928ff.entry.js.map → p-7ceddb7a.entry.js.map} +0 -0
- /package/www/build/{p-50b800e6.entry.js.map → p-86160fe3.entry.js.map} +0 -0
- /package/www/build/{p-2105d5ec.entry.js.map → p-863fd1c4.entry.js.map} +0 -0
- /package/www/build/{p-70aa0b22.entry.js.map → p-943db3a8.entry.js.map} +0 -0
- /package/www/build/{p-6d2a6434.entry.js.map → p-94916bdf.entry.js.map} +0 -0
- /package/www/build/{p-8e5bc362.entry.js.map → p-a2e87cec.entry.js.map} +0 -0
- /package/www/build/{p-fe663393.entry.js.map → p-ac477ae7.entry.js.map} +0 -0
- /package/www/build/{p-75d50d5f.entry.js.map → p-af5e8524.entry.js.map} +0 -0
- /package/www/build/{p-fb78c343.entry.js.map → p-b3f1b5c1.entry.js.map} +0 -0
- /package/www/build/{p-6ebaa41d.entry.js.map → p-d60684d5.entry.js.map} +0 -0
- /package/www/build/{p-2264883d.entry.js.map → p-dc086eb5.entry.js.map} +0 -0
- /package/www/build/{p-f3287280.entry.js.map → p-e0b88075.entry.js.map} +0 -0
- /package/www/build/{p-7eb0e121.entry.js.map → p-f487290e.entry.js.map} +0 -0
|
@@ -1,333 +1,85 @@
|
|
|
1
|
-
import { proxyCustomElement, HTMLElement,
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
import { d as defineCustomElement$2 } from './index9.js';
|
|
5
|
-
import { d as defineCustomElement$1 } from './index12.js';
|
|
1
|
+
import { proxyCustomElement, HTMLElement, h, Host } from '@stencil/core/internal/client';
|
|
2
|
+
import { H as InfoRevealPosition, e as ControlSize } from './index2.js';
|
|
3
|
+
import { d as defineCustomElement$1 } from './index10.js';
|
|
6
4
|
|
|
7
|
-
const stylesCss = ".sc-z-input-h{display:inline-block;width:inherit}.sc-z-input-h *.sc-z-input{box-sizing:border-box}input.sc-z-input::-ms-clear,input.sc-z-input::-ms-reveal{display:none}.sc-z-input-h input.sc-z-input::-ms-clear,.sc-z-input-h input.sc-z-input::-ms-reveal{display:none}input.sc-z-input,textarea.sc-z-input{background:var(--color-form-background);fill:var(--color-form-default-icon);font-family:var(--font-family-sans);font-size:var(--font-size-3);font-weight:var(--font-rg);outline:none}input.sc-z-input,.textarea-wrapper.sc-z-input{border:var(--border-size-small) solid var(--color-form-surface04);border-radius:var(--border-radius-small);color:var(--color-form-default-text)}[size=\"small\"].sc-z-input-h input.sc-z-input,[size=\"small\"].sc-z-input-h textarea.sc-z-input,[size=\"x-small\"].sc-z-input-h input.sc-z-input,[size=\"x-small\"].sc-z-input-h textarea.sc-z-input{font-size:var(--font-size-2)}.cursor-select.sc-z-input-h input.sc-z-input{cursor:pointer}input.sc-z-input:not([readonly]):hover,.textarea-wrapper.sc-z-input:not(.readonly):hover{outline:var(--border-size-medium) solid var(--color-surface04);outline-offset:-2px}.sc-z-input-h:not(.active-select) input.sc-z-input:focus:focus-visible,.sc-z-input-h:not([readonly=\"true\"]) .textarea-wrapper.sc-z-input:focus-within{border-color:var(--color-form-active-primary);box-shadow:var(--shadow-focus-primary);color:var(--color-form-active-primary)}.sc-z-input-h input.sc-z-input:focus:focus-visible:hover,.textarea-wrapper.sc-z-input:not(.readonly):focus-within:hover{outline-color:var(--color-form-active-primary)}.sc-z-input-h input.sc-z-input:focus:focus-visible+.icons-wrapper.sc-z-input{fill:var(--color-form-active-primary)}.active-select.sc-z-input-h input.sc-z-input{border:var(--border-size-small) solid var(--color-form-active-primary)}.cursor-select.sc-z-input-h input.sc-z-input:focus:focus-visible{box-shadow:var(--shadow-focus-primary)}.sc-z-input-h input[readonly].sc-z-input:focus:focus-visible{border-color:var(--color-form-surface03);box-shadow:none}.input-success.sc-z-input{border-color:var(--color-form-success01);background:var(--color-form-inverse-success)}.input-success.sc-z-input:focus:focus-visible+.icons-wrapper.sc-z-input,.input-success.sc-z-input+.icons-wrapper.sc-z-input{fill:var(--color-form-success01)}.input-error.sc-z-input{border-color:var(--color-form-hover-error);background:var(--color-form-inverse-error)}.input-error.sc-z-input:focus:focus-visible+.icons-wrapper.sc-z-input,.input-error.sc-z-input+.icons-wrapper.sc-z-input{fill:var(--color-form-hover-error)}.input-warning.sc-z-input{border-color:var(--color-form-hover-warning);background:var(--color-form-inverse-warning)}.input-warning.sc-z-input:focus:focus-visible+.icons-wrapper.sc-z-input,.input-warning.sc-z-input+.icons-wrapper.sc-z-input{fill:var(--color-form-hover-warning)}.sc-z-input:is(.input-success,.input-error.sc-z-input,.input-warning).sc-z-input:focus:focus-visible{color:var(--color-form-default-text)}.sc-z-input-h:not(.active-select) input[readonly].sc-z-input,.textarea-wrapper.readonly.sc-z-input{border-color:var(--color-form-surface03);fill:var(--color-form-disabled01-icon);pointer-events:none}[disabled].sc-z-input-h:not([disabled=\"false\"]) input.sc-z-input,[disabled].sc-z-input-h:not([disabled=\"false\"]) .textarea-wrapper.sc-z-input,[disabled].sc-z-input-h:not([disabled=\"false\"]) z-icon.sc-z-input{border-color:var(--color-form-disabled03);box-shadow:none;color:var(--color-form-disabled-text);fill:var(--color-form-disabled01-icon);pointer-events:none}[disabled].sc-z-input-h:not([disabled=\"false\"]) input.sc-z-input:hover{border-width:var(--border-size-small)}input.sc-z-input::placeholder,textarea.sc-z-input::placeholder{color:var(--color-form-placeholder-text)}.sc-z-input::-webkit-textarea-placeholder{color:var(--color-form-placeholder-text)}.sc-z-input:-ms-textarea-placeholder{color:var(--color-form-placeholder-text)}.sc-z-input::placeholder{color:var(--color-form-placeholder-text)}[disabled].sc-z-input-h:not([disabled=\"false\"]) label.z-label.sc-z-input{color:var(--color-disabled03)}.text-wrapper.sc-z-input>div.sc-z-input{position:relative;z-index:1;fill:var(--color-form-default-icon)}.text-wrapper.sc-z-input>div.sc-z-input>input.sc-z-input{width:100%;height:calc(var(--space-unit) * 5.5);box-sizing:border-box;padding:0 calc(var(--space-unit) * 1.5);margin:0}[size=\"small\"].sc-z-input-h .text-wrapper.sc-z-input>div.sc-z-input>input.sc-z-input{height:calc(var(--space-unit) * 4.5)}[size=\"x-small\"].sc-z-input-h .text-wrapper.sc-z-input>div.sc-z-input>input.sc-z-input{height:calc(var(--space-unit) * 4)}.text-wrapper.sc-z-input>div.sc-z-input>input.has-icon.sc-z-input,.text-wrapper.sc-z-input>div.sc-z-input>input.has-clear-icon.sc-z-input{padding-right:calc(var(--space-unit) * 5.25)}.text-wrapper.sc-z-input>div.sc-z-input>input.has-icon.has-clear-icon.sc-z-input{padding-right:calc(var(--space-unit) * 8)}.text-wrapper.sc-z-input .icons-wrapper.sc-z-input{position:absolute;z-index:2;top:50%;right:calc(var(--space-unit) * 1.5);display:flex;pointer-events:none;transform:translateY(-50%)}.text-wrapper.sc-z-input .icons-wrapper.sc-z-input>button.input-icon.sc-z-input{display:flex;padding:0;border:0;background:none;color:inherit;font:inherit;pointer-events:initial}.text-wrapper.sc-z-input .icons-wrapper.sc-z-input>.input-icon.sc-z-input+.input-icon.sc-z-input{margin-left:calc(var(--space-unit) * 0.5)}.text-wrapper.sc-z-input .icons-wrapper.sc-z-input>button.input-icon.hidden.sc-z-input{display:none}.text-wrapper.sc-z-input .icons-wrapper.sc-z-input>button.reset-icon.sc-z-input,.text-wrapper.sc-z-input .icons-wrapper.sc-z-input>button.toggle-password-icon.sc-z-input{cursor:pointer}.text-wrapper.sc-z-input .icons-wrapper.sc-z-input>.input-icon.sc-z-input{--z-icon-width:18px;--z-icon-height:18px;display:block}.text-wrapper.sc-z-input .icons-wrapper.sc-z-input>.input-icon.small.sc-z-input,.text-wrapper.sc-z-input .icons-wrapper.sc-z-input>.input-icon.x-small.sc-z-input{--z-icon-width:16px;--z-icon-height:16px}.text-wrapper.sc-z-input .icons-wrapper.sc-z-input>button.input-icon.sc-z-input:focus{box-shadow:var(--shadow-focus-primary);outline:none !important}.text-wrapper.sc-z-input>div.sc-z-input>input.sc-z-input:-webkit-autofill{-webkit-box-shadow:0 0 0 1000px #fff inset;-webkit-text-fill-color:currentcolor}.textarea-wrapper.sc-z-input{width:100%;height:100%;padding:calc(var(--space-unit) * 1.5)}.textarea-wrapper.sc-z-input:not(.input-error,.input-success.sc-z-input,.input-warning).sc-z-input{background-color:var(--color-form-background)}textarea.sc-z-input{width:100%;min-height:132px;padding:0;border:none;margin:0;color:currentcolor;resize:none}.radio-wrapper.sc-z-input,.checkbox-wrapper.sc-z-input{position:relative;display:inline-flex;flex-direction:row;align-items:center;color:var(--color-default-text);fill:var(--color-primary01);font-family:var(--font-family-sans)}.radio-wrapper.sc-z-input:hover,.checkbox-wrapper.sc-z-input:hover{color:var(--color-hover-primary);fill:var(--color-hover-primary-icon)}.radio-wrapper.sc-z-input>input.sc-z-input,.checkbox-wrapper.sc-z-input>input.sc-z-input{position:absolute;z-index:-1;opacity:0;pointer-events:none}.radio-wrapper.sc-z-input .radio-label.sc-z-input,.checkbox-wrapper.sc-z-input .checkbox-label.sc-z-input{display:inline-flex;align-items:center;margin:0;color:inherit;font-family:inherit;font-size:inherit;font-weight:inherit;line-height:1;text-transform:inherit}.radio-wrapper.sc-z-input input.sc-z-input:not(:disabled)+.radio-label.sc-z-input,.checkbox-wrapper.sc-z-input input.sc-z-input:not(:disabled)+.checkbox-label.sc-z-input{cursor:pointer}.radio-wrapper.sc-z-input .radio-label.sc-z-input z-icon.sc-z-input,.checkbox-wrapper.sc-z-input .checkbox-label.sc-z-input z-icon.sc-z-input{cursor:pointer;fill:inherit}[size=\"small\"].sc-z-input-h .radio-wrapper.sc-z-input .radio-label.sc-z-input z-icon.sc-z-input,[size=\"small\"].sc-z-input-h .checkbox-wrapper.sc-z-input .checkbox-label.sc-z-input z-icon.sc-z-input{--z-icon-width:16px;--z-icon-height:16px}[size=\"small\"].sc-z-input-h .radio-wrapper.sc-z-input .radio-label.sc-z-input,[size=\"small\"].sc-z-input-h .checkbox-wrapper.sc-z-input .checkbox-label.sc-z-input{font-size:var(--font-size-2)}[size=\"x-small\"].sc-z-input-h .radio-wrapper.sc-z-input .radio-label.sc-z-input z-icon.sc-z-input,[size=\"x-small\"].sc-z-input-h .checkbox-wrapper.sc-z-input .checkbox-label.sc-z-input z-icon.sc-z-input{--z-icon-width:14px;--z-icon-height:14px}[size=\"x-small\"].sc-z-input-h .radio-wrapper.sc-z-input .radio-label.sc-z-input,[size=\"x-small\"].sc-z-input-h .checkbox-wrapper.sc-z-input .checkbox-label.sc-z-input{font-size:var(--font-size-1)}.radio-wrapper.sc-z-input .radio-label.after.sc-z-input,.checkbox-wrapper.sc-z-input .checkbox-label.after.sc-z-input{flex-direction:row}.radio-wrapper.sc-z-input .radio-label.before.sc-z-input,.checkbox-wrapper.sc-z-input .checkbox-label.before.sc-z-input{flex-direction:row-reverse}.radio-wrapper.sc-z-input .radio-label.after.sc-z-input>span.sc-z-input,.checkbox-wrapper.sc-z-input .checkbox-label.after.sc-z-input>span.sc-z-input{margin-left:var(--space-unit)}.radio-wrapper.sc-z-input .radio-label.before.sc-z-input>span.sc-z-input,.checkbox-wrapper.sc-z-input .checkbox-label.before.sc-z-input>span.sc-z-input{margin-right:var(--space-unit)}[size=\"small\"].sc-z-input-h .radio-wrapper.sc-z-input .radio-label.after.sc-z-input>span.sc-z-input,[size=\"small\"].sc-z-input-h .checkbox-wrapper.sc-z-input .checkbox-label.after.sc-z-input>span.sc-z-input,[size=\"x-small\"].sc-z-input-h .radio-wrapper.sc-z-input .radio-label.after.sc-z-input>span.sc-z-input,[size=\"x-small\"].sc-z-input-h .checkbox-wrapper.sc-z-input .checkbox-label.after.sc-z-input>span.sc-z-input{margin-left:calc(var(--space-unit) * 0.5)}[size=\"small\"].sc-z-input-h .radio-wrapper.sc-z-input .radio-label.before.sc-z-input>span.sc-z-input,[size=\"small\"].sc-z-input-h .checkbox-wrapper.sc-z-input .checkbox-label.before.sc-z-input>span.sc-z-input,[size=\"x-small\"].sc-z-input-h .radio-wrapper.sc-z-input .radio-label.before.sc-z-input>span.sc-z-input,[size=\"x-small\"].sc-z-input-h .checkbox-wrapper.sc-z-input .checkbox-label.before.sc-z-input>span.sc-z-input{margin-right:calc(var(--space-unit) * 0.5)}.radio-wrapper.sc-z-input>input.sc-z-input:focus:focus-visible+.radio-label.sc-z-input>z-icon.sc-z-input{border-radius:50%}.checkbox-wrapper.sc-z-input>input.sc-z-input:focus:focus-visible+.checkbox-label.sc-z-input>z-icon.sc-z-input{border-radius:var(--border-radius-small)}.radio-wrapper.sc-z-input>input.sc-z-input:focus:focus-visible+.radio-label.sc-z-input>z-icon.sc-z-input,.checkbox-wrapper.sc-z-input>input.sc-z-input:focus:focus-visible+.checkbox-label.sc-z-input>z-icon.sc-z-input{box-shadow:var(--shadow-focus-primary)}.radio-wrapper.sc-z-input>input.sc-z-input:disabled+.radio-label.sc-z-input,.checkbox-wrapper.sc-z-input>input.sc-z-input:disabled+.checkbox-label.sc-z-input{color:var(--color-disabled03)}.radio-wrapper.sc-z-input>input.sc-z-input:disabled+.radio-label.sc-z-input>z-icon.sc-z-input,.checkbox-wrapper.sc-z-input>input.sc-z-input:disabled+.checkbox-label.sc-z-input>z-icon.sc-z-input{cursor:default;fill:var(--color-disabled01)}";
|
|
8
|
-
const
|
|
5
|
+
const stylesCss = ":host{--z-info-reveal-panel-width:384px;--trigger-size:44px;position:relative}:host *{box-sizing:border-box}button{--trigger-icon-size:calc(var(--trigger-size) / 2);display:flex;align-items:center;justify-content:center;padding:0;border:none;background-color:transparent;cursor:pointer;font-family:inherit;letter-spacing:inherit}button:focus:focus-visible{box-shadow:var(--shadow-focus-primary);outline:none}.z-info-reveal-trigger{min-width:var(--trigger-size);height:var(--trigger-size);padding:calc((var(--trigger-size) - var(--trigger-icon-size)) / 2);background-color:var(--color-surface05);border-radius:var(--border-radius);color:var(--color-text-inverse);column-gap:var(--space-unit);font-weight:var(--font-sb);line-height:1rem}:host([size=\"big\"]) .z-info-reveal-trigger{font-size:var(--font-size-2)}:host([size=\"small\"]) .z-info-reveal-trigger{--trigger-size:36px;font-size:var(--font-size-2)}:host([size=\"x-small\"]) .z-info-reveal-trigger{--trigger-size:32px;padding:var(--space-unit);font-size:var(--font-size-1)}:host>.z-info-reveal-trigger z-icon{--z-icon-width:var(--trigger-icon-size);--z-icon-height:var(--trigger-icon-size);display:flex;fill:var(--color-inverse-icon)}:host([size=\"small\"])>.z-info-reveal-trigger z-icon{--trigger-icon-size:var(--trigger-icon-size-small, 18px)}:host([size=\"x-small\"])>.z-info-reveal-trigger z-icon{--trigger-icon-size:var(--trigger-icon-size-x-small, 16px)}.z-info-reveal-panel{position:absolute;z-index:19;display:flex;width:var(--z-info-reveal-panel-width);height:fit-content;align-items:flex-start;padding:calc(var(--space-unit) * 1.5);background-color:var(--color-surface05);border-radius:var(--border-radius);box-shadow:var(--shadow-4);color:var(--color-text-inverse);column-gap:var(--space-unit)}.z-info-reveal-panel[hidden]{display:none}:host([position=\"top_left\"]) .z-info-reveal-panel,:host([position=\"top_right\"]) .z-info-reveal-panel{top:0}:host([position=\"bottom_left\"]) .z-info-reveal-panel,:host([position=\"bottom_right\"]) .z-info-reveal-panel{bottom:0}:host([position=\"top_right\"]) .z-info-reveal-panel,:host([position=\"bottom_right\"]) .z-info-reveal-panel{right:0}:host([position=\"top_left\"]) .z-info-reveal-panel,:host([position=\"bottom_left\"]) .z-info-reveal-panel{left:0}.z-info-reveal-panel .z-info-reveal-close{margin-left:auto}.z-info-reveal-panel z-icon{fill:var(--color-inverse-icon)}@media (max-width: 767px){.z-info-reveal-panel{top:auto !important;bottom:auto !important;width:calc(var(--z-info-reveal-panel-width) - (var(--grid-margin) * 4)) !important;margin-top:calc(var(--trigger-size) * -1)}}";
|
|
6
|
+
const ZInfoRevealStyle0 = stylesCss;
|
|
9
7
|
|
|
10
|
-
const
|
|
8
|
+
const ZInfoReveal = /*@__PURE__*/ proxyCustomElement(class ZInfoReveal extends HTMLElement {
|
|
11
9
|
constructor() {
|
|
12
10
|
super();
|
|
13
11
|
this.__registerHost();
|
|
14
|
-
this.
|
|
15
|
-
this.
|
|
16
|
-
this.
|
|
17
|
-
this.inputCheck = createEvent(this, "inputCheck", 7);
|
|
18
|
-
this.inputFocus = createEvent(this, "inputFocus", 7);
|
|
19
|
-
this.inputBlur = createEvent(this, "inputBlur", 7);
|
|
20
|
-
this.typingtimeout = 300;
|
|
21
|
-
this.htmlid = `id-${randomId()}`;
|
|
22
|
-
this.type = undefined;
|
|
23
|
-
this.name = undefined;
|
|
12
|
+
this.__attachShadow();
|
|
13
|
+
this.icon = "informationsource";
|
|
14
|
+
this.position = InfoRevealPosition.BOTTOM_RIGHT;
|
|
24
15
|
this.label = undefined;
|
|
25
|
-
this.ariaLabel = "";
|
|
26
|
-
this.ariaExpanded = "";
|
|
27
|
-
this.ariaControls = undefined;
|
|
28
|
-
this.ariaAutocomplete = undefined;
|
|
29
|
-
this.ariaActivedescendant = undefined;
|
|
30
|
-
this.value = undefined;
|
|
31
|
-
this.disabled = false;
|
|
32
|
-
this.readonly = false;
|
|
33
|
-
this.required = false;
|
|
34
|
-
this.checked = false;
|
|
35
|
-
this.placeholder = undefined;
|
|
36
|
-
this.htmltitle = undefined;
|
|
37
|
-
this.status = undefined;
|
|
38
|
-
this.message = true;
|
|
39
|
-
this.labelPosition = LabelPosition.RIGHT;
|
|
40
|
-
this.autocomplete = undefined;
|
|
41
|
-
this.role = "";
|
|
42
|
-
this.hasclearicon = true;
|
|
43
|
-
this.icon = undefined;
|
|
44
|
-
this.min = undefined;
|
|
45
|
-
this.minlength = undefined;
|
|
46
|
-
this.max = undefined;
|
|
47
|
-
this.maxlength = undefined;
|
|
48
|
-
this.step = undefined;
|
|
49
|
-
this.pattern = undefined;
|
|
16
|
+
this.ariaLabel = "Apri pannello informazioni";
|
|
50
17
|
this.size = ControlSize.BIG;
|
|
51
|
-
this.
|
|
52
|
-
this.passwordHidden = true;
|
|
18
|
+
this.open = false;
|
|
53
19
|
}
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
this.checked = false;
|
|
60
|
-
}
|
|
61
|
-
break;
|
|
62
|
-
}
|
|
63
|
-
}
|
|
64
|
-
/** get checked status */
|
|
65
|
-
async isChecked() {
|
|
66
|
-
switch (this.type) {
|
|
67
|
-
case InputType.CHECKBOX:
|
|
68
|
-
case InputType.RADIO:
|
|
69
|
-
return this.checked;
|
|
70
|
-
default:
|
|
71
|
-
console.warn("`isChecked` method is only available for type `checkbox` and `radio`");
|
|
72
|
-
return false;
|
|
73
|
-
}
|
|
74
|
-
}
|
|
75
|
-
emitInputChange(value) {
|
|
76
|
-
if (!this.isTyping) {
|
|
77
|
-
this.emitStartTyping();
|
|
78
|
-
}
|
|
79
|
-
let validity;
|
|
80
|
-
if (this.type === InputType.TEXTAREA) {
|
|
81
|
-
validity = this.getValidity("textarea");
|
|
82
|
-
}
|
|
83
|
-
else {
|
|
84
|
-
validity = this.getValidity("input");
|
|
85
|
-
}
|
|
86
|
-
this.value = value;
|
|
87
|
-
this.inputChange.emit({ value, validity });
|
|
88
|
-
clearTimeout(this.timer);
|
|
89
|
-
this.timer = setTimeout(() => {
|
|
90
|
-
this.emitStopTyping(this.value, validity);
|
|
91
|
-
}, this.typingtimeout);
|
|
92
|
-
}
|
|
93
|
-
emitStartTyping() {
|
|
94
|
-
this.isTyping = true;
|
|
95
|
-
this.startTyping.emit();
|
|
96
|
-
}
|
|
97
|
-
emitStopTyping(value, validity) {
|
|
98
|
-
this.isTyping = false;
|
|
99
|
-
this.stopTyping.emit({
|
|
100
|
-
value: value,
|
|
101
|
-
validity: validity,
|
|
102
|
-
});
|
|
103
|
-
}
|
|
104
|
-
emitInputCheck(checked) {
|
|
105
|
-
this.inputCheck.emit({
|
|
106
|
-
id: this.htmlid,
|
|
107
|
-
checked: checked,
|
|
108
|
-
type: this.type,
|
|
109
|
-
name: this.name,
|
|
110
|
-
value: this.value,
|
|
111
|
-
validity: this.getValidity("input"),
|
|
112
|
-
});
|
|
113
|
-
}
|
|
114
|
-
emitInputFocus() {
|
|
115
|
-
this.inputFocus.emit({ id: this.htmlid });
|
|
116
|
-
}
|
|
117
|
-
emitInputBlur() {
|
|
118
|
-
this.inputBlur.emit({ id: this.htmlid });
|
|
119
|
-
}
|
|
120
|
-
getValidity(type) {
|
|
121
|
-
const input = this.hostElement.querySelector(type);
|
|
122
|
-
return input.validity;
|
|
123
|
-
}
|
|
124
|
-
/* START text/password/email/number */
|
|
125
|
-
getTextAttributes() {
|
|
126
|
-
return {
|
|
127
|
-
id: this.htmlid,
|
|
128
|
-
name: this.name,
|
|
129
|
-
placeholder: this.placeholder,
|
|
130
|
-
value: this.value,
|
|
131
|
-
disabled: this.disabled,
|
|
132
|
-
readonly: this.readonly,
|
|
133
|
-
required: this.required,
|
|
134
|
-
title: this.htmltitle,
|
|
135
|
-
minlength: this.minlength,
|
|
136
|
-
maxlength: this.maxlength,
|
|
137
|
-
class: {
|
|
138
|
-
[`input-${this.status}`]: !!this.status,
|
|
139
|
-
},
|
|
140
|
-
autocomplete: this.autocomplete,
|
|
141
|
-
onInput: (e) => this.emitInputChange(e.target.value),
|
|
142
|
-
};
|
|
143
|
-
}
|
|
144
|
-
getNumberAttributes(type) {
|
|
145
|
-
if (type != InputType.NUMBER) {
|
|
146
|
-
return;
|
|
147
|
-
}
|
|
148
|
-
return {
|
|
149
|
-
min: this.min,
|
|
150
|
-
max: this.max,
|
|
151
|
-
step: this.step,
|
|
152
|
-
};
|
|
153
|
-
}
|
|
154
|
-
getPatternAttribute(type) {
|
|
155
|
-
if (type != InputType.PASSWORD &&
|
|
156
|
-
type != InputType.TEXT &&
|
|
157
|
-
type != InputType.TEL &&
|
|
158
|
-
type != InputType.SEARCH &&
|
|
159
|
-
type != InputType.URL &&
|
|
160
|
-
type != InputType.EMAIL) {
|
|
161
|
-
return;
|
|
162
|
-
}
|
|
163
|
-
return {
|
|
164
|
-
pattern: this.pattern,
|
|
165
|
-
};
|
|
166
|
-
}
|
|
167
|
-
getRoleAttribute() {
|
|
168
|
-
return this.role ? { role: this.role } : {};
|
|
169
|
-
}
|
|
170
|
-
getAriaAttrubutes() {
|
|
171
|
-
const expanded = this.ariaExpanded ? { "aria-expanded": this.ariaExpanded } : {};
|
|
172
|
-
const controls = this.ariaControls ? { "aria-controls": this.ariaControls } : {};
|
|
173
|
-
const autocomplete = this.ariaAutocomplete ? { "aria-autocomplete": this.ariaAutocomplete } : {};
|
|
174
|
-
const activedescendant = this.ariaActivedescendant ? { "aria-activedescendant": this.ariaActivedescendant } : {};
|
|
175
|
-
return Object.assign(Object.assign(Object.assign(Object.assign({}, expanded), controls), autocomplete), activedescendant);
|
|
176
|
-
}
|
|
177
|
-
getFocusBlurAttributes() {
|
|
178
|
-
return {
|
|
179
|
-
onFocus: () => this.emitInputFocus(),
|
|
180
|
-
onBlur: () => this.emitInputBlur(),
|
|
181
|
-
};
|
|
182
|
-
}
|
|
183
|
-
renderInputText(type = InputType.TEXT) {
|
|
184
|
-
const ariaLabel = this.ariaLabel ? { "aria-label": this.ariaLabel } : {};
|
|
185
|
-
const attr = Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({}, this.getTextAttributes()), this.getNumberAttributes(type)), this.getPatternAttribute(type)), ariaLabel), this.getRoleAttribute()), this.getAriaAttrubutes()), this.getFocusBlurAttributes());
|
|
186
|
-
if (this.icon || type === InputType.PASSWORD) {
|
|
187
|
-
Object.assign(attr.class, { "has-icon": true });
|
|
188
|
-
}
|
|
189
|
-
if (this.hasclearicon && type != InputType.NUMBER) {
|
|
190
|
-
Object.assign(attr.class, { "has-clear-icon": true });
|
|
191
|
-
}
|
|
192
|
-
return (h("div", { class: "text-wrapper" }, this.renderLabel(), h("div", null, h("input", Object.assign({ type: type === InputType.PASSWORD && !this.passwordHidden ? InputType.TEXT : type }, attr, { ref: (el) => (this.inputRef = el) })), this.renderIcons()), this.renderMessage()));
|
|
193
|
-
}
|
|
194
|
-
renderLabel() {
|
|
195
|
-
if (!this.label) {
|
|
196
|
-
return;
|
|
197
|
-
}
|
|
198
|
-
return (h("label", { class: "z-label body-5-sb", id: `${this.htmlid}_label`, htmlFor: this.htmlid }, this.label));
|
|
199
|
-
}
|
|
200
|
-
renderIcons() {
|
|
201
|
-
return (h("span", { class: "icons-wrapper" }, this.renderResetIcon(), this.renderIcon()));
|
|
202
|
-
}
|
|
203
|
-
renderIcon() {
|
|
204
|
-
if (this.type === InputType.PASSWORD) {
|
|
205
|
-
return this.renderShowHidePassword();
|
|
206
|
-
}
|
|
207
|
-
if (!this.icon) {
|
|
20
|
+
/**
|
|
21
|
+
* Adjust the position of the info panel to prevent exiting the viewport.
|
|
22
|
+
*/
|
|
23
|
+
adjustPanelPosition() {
|
|
24
|
+
if (!this.open || !this.panel) {
|
|
208
25
|
return;
|
|
209
26
|
}
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
|
|
27
|
+
const rect = this.host.getBoundingClientRect();
|
|
28
|
+
const gridMargin = parseInt(getComputedStyle(document.documentElement).getPropertyValue("--grid-margin"), 10);
|
|
29
|
+
const pageWidth = document.documentElement.offsetWidth;
|
|
30
|
+
// Available space for the info panel to grow towards the edge of the page, based on the `position` prop.
|
|
31
|
+
const availableSpace = Math.round((this.position.includes("left") ? pageWidth - rect.left : rect.right) - gridMargin);
|
|
32
|
+
this.panel.style.maxWidth = `${availableSpace}px`;
|
|
33
|
+
}
|
|
34
|
+
/**
|
|
35
|
+
* Toggle the open state of the info panel.
|
|
36
|
+
*/
|
|
37
|
+
togglePanel() {
|
|
38
|
+
this.open = !this.open;
|
|
39
|
+
}
|
|
40
|
+
/**
|
|
41
|
+
* Close the info panel.
|
|
42
|
+
*/
|
|
43
|
+
closePanel() {
|
|
44
|
+
this.open = false;
|
|
45
|
+
}
|
|
46
|
+
handleEscapeKey(event) {
|
|
47
|
+
if (event.key === "Escape" && this.open) {
|
|
48
|
+
this.closePanel();
|
|
228
49
|
}
|
|
229
|
-
return (h("z-input-message", { message: boolean(this.message) === true ? undefined : this.message, status: this.status, class: this.size, disabled: this.disabled }));
|
|
230
|
-
}
|
|
231
|
-
/* END text/password/email/number */
|
|
232
|
-
/* START textarea */
|
|
233
|
-
renderTextarea() {
|
|
234
|
-
const attributes = this.getTextAttributes();
|
|
235
|
-
return (h(Fragment, null, this.renderLabel(), h("div", { class: Object.assign(Object.assign({}, attributes.class), { "textarea-wrapper": true, "readonly": !!attributes.readonly }) }, h("textarea", Object.assign({}, attributes, { class: Object.assign(Object.assign({}, attributes.class), { "z-scrollbar": true }), "aria-label": this.ariaLabel || undefined }, this.getRoleAttribute()))), this.renderMessage()));
|
|
236
|
-
}
|
|
237
|
-
/* END textarea */
|
|
238
|
-
handleCheck(ev) {
|
|
239
|
-
this.checked = ev.target.checked;
|
|
240
|
-
this.emitInputCheck(this.checked);
|
|
241
50
|
}
|
|
242
|
-
/* START checkbox */
|
|
243
|
-
renderCheckbox() {
|
|
244
|
-
return (h("div", { class: "checkbox-wrapper" }, h("input", Object.assign({ id: this.htmlid, type: "checkbox", name: this.name, checked: this.checked, disabled: this.disabled, readonly: this.readonly, required: this.required, onChange: this.handleCheck.bind(this), value: this.value }, this.getRoleAttribute(), this.getFocusBlurAttributes())), h("label", { htmlFor: this.htmlid, class: {
|
|
245
|
-
"checkbox-label": true,
|
|
246
|
-
"after": this.labelPosition === LabelPosition.RIGHT,
|
|
247
|
-
"before": this.labelPosition === LabelPosition.LEFT,
|
|
248
|
-
} }, h("z-icon", { name: this.checked ? "checkbox-checked" : "checkbox", class: this.size }), this.label && h("span", { innerHTML: this.label }))));
|
|
249
|
-
}
|
|
250
|
-
/* END checkbox */
|
|
251
|
-
/* START radio */
|
|
252
|
-
renderRadio() {
|
|
253
|
-
return (h("div", { class: "radio-wrapper" }, h("input", Object.assign({ id: this.htmlid, type: "radio", name: this.name, checked: this.checked, disabled: this.disabled, readonly: this.readonly, onChange: this.handleCheck.bind(this), value: this.value }, this.getRoleAttribute(), this.getFocusBlurAttributes())), h("label", { htmlFor: this.htmlid, class: {
|
|
254
|
-
"radio-label": true,
|
|
255
|
-
"after": this.labelPosition === LabelPosition.RIGHT,
|
|
256
|
-
"before": this.labelPosition === LabelPosition.LEFT,
|
|
257
|
-
} }, h("z-icon", { name: this.checked ? "radio-button-checked" : "radio-button", class: this.size }), this.label && h("span", { innerHTML: this.label }))));
|
|
258
|
-
}
|
|
259
|
-
/* END radio */
|
|
260
51
|
render() {
|
|
261
|
-
|
|
262
|
-
|
|
263
|
-
|
|
264
|
-
|
|
265
|
-
|
|
266
|
-
|
|
267
|
-
|
|
268
|
-
|
|
269
|
-
|
|
270
|
-
|
|
271
|
-
|
|
272
|
-
default:
|
|
273
|
-
input = this.renderInputText(this.type);
|
|
274
|
-
}
|
|
275
|
-
return h(Host, { key: 'e08828cc7a88abce456ce3c898e37f994825118f' }, input);
|
|
276
|
-
}
|
|
277
|
-
get hostElement() { return this; }
|
|
278
|
-
static get style() { return ZInputStyle0; }
|
|
279
|
-
}, [2, "z-input", {
|
|
280
|
-
"htmlid": [1],
|
|
281
|
-
"type": [1],
|
|
282
|
-
"name": [1],
|
|
52
|
+
return (h(Host, { key: '250676e5bde8cb158ff19dd85c5b65aba329ab6d', open: this.open }, h("button", { key: 'ae9bd0a7a96c781ebc6e68f70b0553d9d08b8c4d', class: "z-info-reveal-trigger", type: "button", onClick: this.togglePanel.bind(this), "aria-label": !this.label ? this.ariaLabel : undefined, "aria-expanded": this.open ? "true" : "false", "aria-controls": "z-info-reveal-panel" }, this.icon && h("z-icon", { key: 'cda367464294fcdb6e87b7dd8804470fc600a196', name: this.icon }), this.label && h("span", { key: '33ee450958960b0eed18c6b630655c87d34d4b0f', class: "z-info-reveal-label" }, this.label)), h("div", { key: '717f241bbbd1034b8f7117d0875a859a27ecc3d0', class: "z-info-reveal-panel", id: "z-info-reveal-panel", ref: (el) => (this.panel = el), hidden: !this.open }, h("slot", { key: 'f44d74a6183fdda5560fe8ced2e07ef12748b4b9' }), h("button", { key: '5071effe3449b8fe0285c080a0d9cb14be2b033c', class: "z-info-reveal-close", type: "button", onClick: this.closePanel.bind(this), "aria-label": "Chiudi pannello informazioni" }, h("z-icon", { key: '9f3088b1e5398bea476ea2da203cb8e2e106ea89', name: "multiply" })))));
|
|
53
|
+
}
|
|
54
|
+
get host() { return this; }
|
|
55
|
+
static get watchers() { return {
|
|
56
|
+
"position": ["adjustPanelPosition"],
|
|
57
|
+
"open": ["adjustPanelPosition"]
|
|
58
|
+
}; }
|
|
59
|
+
static get style() { return ZInfoRevealStyle0; }
|
|
60
|
+
}, [1, "z-info-reveal", {
|
|
61
|
+
"icon": [1],
|
|
62
|
+
"position": [513],
|
|
283
63
|
"label": [1],
|
|
284
64
|
"ariaLabel": [1, "aria-label"],
|
|
285
|
-
"ariaExpanded": [1, "aria-expanded"],
|
|
286
|
-
"ariaControls": [1, "aria-controls"],
|
|
287
|
-
"ariaAutocomplete": [1, "aria-autocomplete"],
|
|
288
|
-
"ariaActivedescendant": [1, "aria-activedescendant"],
|
|
289
|
-
"value": [1025],
|
|
290
|
-
"disabled": [516],
|
|
291
|
-
"readonly": [4],
|
|
292
|
-
"required": [4],
|
|
293
|
-
"checked": [1028],
|
|
294
|
-
"placeholder": [1],
|
|
295
|
-
"htmltitle": [1],
|
|
296
|
-
"status": [1],
|
|
297
|
-
"message": [8],
|
|
298
|
-
"labelPosition": [1, "label-position"],
|
|
299
|
-
"autocomplete": [1],
|
|
300
|
-
"role": [1],
|
|
301
|
-
"hasclearicon": [4],
|
|
302
|
-
"icon": [1],
|
|
303
|
-
"min": [2],
|
|
304
|
-
"minlength": [2],
|
|
305
|
-
"max": [2],
|
|
306
|
-
"maxlength": [2],
|
|
307
|
-
"step": [2],
|
|
308
|
-
"pattern": [1],
|
|
309
65
|
"size": [513],
|
|
310
|
-
"
|
|
311
|
-
|
|
312
|
-
"
|
|
313
|
-
|
|
66
|
+
"open": [32]
|
|
67
|
+
}, [[9, "resize", "adjustPanelPosition"], [10, "keydown", "handleEscapeKey"]], {
|
|
68
|
+
"position": ["adjustPanelPosition"],
|
|
69
|
+
"open": ["adjustPanelPosition"]
|
|
70
|
+
}]);
|
|
314
71
|
function defineCustomElement() {
|
|
315
72
|
if (typeof customElements === "undefined") {
|
|
316
73
|
return;
|
|
317
74
|
}
|
|
318
|
-
const components = ["z-
|
|
75
|
+
const components = ["z-info-reveal", "z-icon"];
|
|
319
76
|
components.forEach(tagName => { switch (tagName) {
|
|
320
|
-
case "z-
|
|
77
|
+
case "z-info-reveal":
|
|
321
78
|
if (!customElements.get(tagName)) {
|
|
322
|
-
customElements.define(tagName,
|
|
79
|
+
customElements.define(tagName, ZInfoReveal);
|
|
323
80
|
}
|
|
324
81
|
break;
|
|
325
82
|
case "z-icon":
|
|
326
|
-
if (!customElements.get(tagName)) {
|
|
327
|
-
defineCustomElement$2();
|
|
328
|
-
}
|
|
329
|
-
break;
|
|
330
|
-
case "z-input-message":
|
|
331
83
|
if (!customElements.get(tagName)) {
|
|
332
84
|
defineCustomElement$1();
|
|
333
85
|
}
|
|
@@ -335,6 +87,6 @@ function defineCustomElement() {
|
|
|
335
87
|
} });
|
|
336
88
|
}
|
|
337
89
|
|
|
338
|
-
export {
|
|
90
|
+
export { ZInfoReveal as Z, defineCustomElement as d };
|
|
339
91
|
|
|
340
92
|
//# sourceMappingURL=index11.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"file":"index11.js","mappings":";;;;;;AAAA,MAAM,SAAS,GAAG,g/VAAg/V,CAAC;AACngW,qBAAe,SAAS;;MCUX,MAAM;;;;;;;;;;QAmIT,kBAAa,GAAG,GAAG,CAAC;sBA9HnB,MAAM,QAAQ,EAAE,EAAE;;;;yBAgBf,EAAE;4BAIC,EAAE;;;;;wBAoBI,KAAK;wBAIL,KAAK;wBAIL,KAAK;uBAIN,KAAK;;;;uBAgBI,IAAI;6BAID,aAAa,CAAC,KAAK;;oBAQ5C,EAAE;4BAIgB,IAAI;;;;;;;;oBAgCR,WAAW,CAAC,GAAG;wBAGzB,KAAK;8BAGC,IAAI;;IASrB,kBAAkB,CAAC,CAAc;QAC/B,MAAM,IAAI,GAAG,CAAC,CAAC,MAAM,CAAC;QACtB,QAAQ,IAAI,CAAC,IAAI;YACf,KAAK,SAAS,CAAC,KAAK;gBAClB,IAAI,IAAI,CAAC,IAAI,KAAK,SAAS,CAAC,KAAK,IAAI,IAAI,CAAC,IAAI,KAAK,IAAI,CAAC,IAAI,IAAI,IAAI,CAAC,EAAE,KAAK,IAAI,CAAC,MAAM,EAAE;oBACvF,IAAI,CAAC,OAAO,GAAG,KAAK,CAAC;iBACtB;gBACD,MAAM;SACT;KACF;;IAID,MAAM,SAAS;QACb,QAAQ,IAAI,CAAC,IAAI;YACf,KAAK,SAAS,CAAC,QAAQ,CAAC;YACxB,KAAK,SAAS,CAAC,KAAK;gBAClB,OAAO,IAAI,CAAC,OAAO,CAAC;YACtB;gBACE,OAAO,C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AQ,EACvB,QAAQ,EAAE,IAAI,CAAC,WAAW,CAAC,IAAI,CAAC,IAAI,CAAC,EACrC,KAAK,EAAE,IAAI,CAAC,KAAK,IACb,IAAI,CAAC,gBAAgB,EAAE,EACvB,IAAI,CAAC,sBAAsB,EAAE,EACjC,EAEF,aACE,OAAO,EAAE,IAAI,CAAC,MAAM,EACpB,KAAK,EAAE;gBACL,aAAa,EAAE,IAAI;gBACnB,OAAO,EAAE,IAAI,CAAC,aAAa,KAAK,aAAa,CAAC,KAAK;gBACnD,QAAQ,EAAE,IAAI,CAAC,aAAa,KAAK,aAAa,CAAC,IAAI;aACpD,IAED,cACE,IAAI,EAAE,IAAI,CAAC,OAAO,GAAG,sBAAsB,GAAG,cAAc,EAC5D,KAAK,EAAE,IAAI,CAAC,IAAI,GAChB,EACD,IAAI,CAAC,KAAK,IAAI,YAAM,SAAS,EAAE,IAAI,CAAC,KAAK,GAAI,CACxC,CACJ,EACN;KACH;;IAGD,MAAM;QACJ,IAAI,KAAK,CAAC;QACV,QAAQ,IAAI,CAAC,IAAI;YACf,KAAK,SAAS,CAAC,QAAQ;gBACrB,KAAK,GAAG,IAAI,CAAC,cAAc,EAAE,CAAC;gBAC9B,MAAM;YACR,KAAK,SAAS,CAAC,QAAQ;gBACrB,KAAK,GAAG,IAAI,CAAC,cAAc,EAAE,CAAC;gBAC9B,MAAM;YACR,KAAK,SAAS,CAAC,KAAK;gBAClB,KAAK,GAAG,IAAI,CAAC,WAAW,EAAE,CAAC;gBAC3B,MAAM;YACR;gBACE,KAAK,GAAG,IAAI,CAAC,eAAe,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;SAC3C;QAED,OAAO,EAAC,IAAI,uDAAE,KAAK,CAAQ,CAAC;KAC7B;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","names":[],"sources":["src/components/z-input/styles.css?tag=z-input&encapsulation=scoped","src/components/z-input/index.tsx"],"sourcesContent":["@import \"styles-general.css\";\n@import \"styles-text.css\";\n@import \"styles-textarea.css\";\n@import \"styles-checkbox-radio.css\";\n","import {Component, Element, Event, EventEmitter, Listen, Method, Prop, State, h} from \"@stencil/core\";\nimport {Fragment, Host, JSXBase} from \"@stencil/core/internal\";\nimport {ControlSize, InputStatus, InputType, LabelPosition} from \"../../beans\";\nimport {boolean, randomId} from \"../../utils/utils\";\n\n@Component({\n tag: \"z-input\",\n styleUrl: \"styles.css\",\n shadow: false,\n scoped: true,\n})\nexport class ZInput {\n @Element() hostElement: HTMLZInputElement;\n\n /** the id of the input element */\n @Prop()\n htmlid = `id-${randomId()}`;\n\n /** input types */\n @Prop()\n type: InputType;\n\n /** the input name */\n @Prop()\n name?: string;\n\n /** the input label */\n @Prop()\n label?: string;\n\n /** the input aria-label */\n @Prop()\n ariaLabel = \"\";\n\n /** the input aria-expaded: available for text, password, number, email */\n @Prop()\n ariaExpanded = \"\";\n\n /** the input aria-controls (optional): available for text, password, number, email */\n @Prop()\n ariaControls?: string;\n\n /** the input aria-autocomplete (optional): available for text, password, number, email */\n @Prop()\n ariaAutocomplete?: string;\n\n /** the input aria-activedescendant (optional): available for text, password, number, email */\n @Prop()\n ariaActivedescendant?: string;\n\n /** the input value */\n @Prop({mutable: true})\n value?: string;\n\n /** the input is disabled */\n @Prop({reflect: true})\n disabled?: boolean = false;\n\n /** the input is readonly */\n @Prop()\n readonly?: boolean = false;\n\n /** the input is required (optional): available for text, password, number, email, textarea, checkbox */\n @Prop()\n required?: boolean = false;\n\n /** checked: available for checkbox, radio */\n @Prop({mutable: true})\n checked?: boolean = false;\n\n /** the input placeholder (optional) */\n @Prop()\n placeholder?: string;\n\n /** the input html title (optional) */\n @Prop()\n htmltitle?: string;\n\n /** the input status (optional): available for text, password, number, email, textarea */\n @Prop()\n status?: InputStatus;\n\n /** input helper message (optional): available for text, password, number, email, textarea - if set to `false` message won't be displayed */\n @Prop()\n message?: string | boolean = true;\n\n /** the input label position: available for checkbox, radio */\n @Prop()\n labelPosition?: LabelPosition = LabelPosition.RIGHT;\n\n /** the input has autocomplete option (optional): available for text, password, number, email */\n @Prop()\n autocomplete?: string;\n\n /** the input role */\n @Prop()\n role = \"\";\n\n /** render clear icon when typing (optional): available for text */\n @Prop()\n hasclearicon?: boolean = true;\n\n /** render icon (optional): available for text */\n @Prop()\n icon?: string;\n\n /** min number value (optional): available for number */\n @Prop()\n min?: number;\n\n /** Min length value (optional): available for text */\n @Prop()\n minlength?: number;\n\n /** max number value (optional): available for number */\n @Prop()\n max?: number;\n\n /** Max length value (optional): available for text */\n @Prop()\n maxlength?: number;\n\n /** step number value (optional): available for number */\n @Prop()\n step?: number;\n\n /** pattern value (optional): available for tel, text, search, url, email, password*/\n @Prop()\n pattern?: string;\n\n /** Available sizes: `big`, `small` and `x-small`. Defaults to `big`. */\n @Prop({reflect: true})\n size?: ControlSize = ControlSize.BIG;\n\n @State()\n isTyping = false;\n\n @State()\n passwordHidden = true;\n\n private timer;\n\n private typingtimeout = 300;\n\n private inputRef: HTMLInputElement;\n\n @Listen(\"inputCheck\", {target: \"document\"})\n inputCheckListener(e: CustomEvent): void {\n const data = e.detail;\n switch (this.type) {\n case InputType.RADIO:\n if (data.type === InputType.RADIO && data.name === this.name && data.id !== this.htmlid) {\n this.checked = false;\n }\n break;\n }\n }\n\n /** get checked status */\n @Method()\n async isChecked(): Promise<boolean> {\n switch (this.type) {\n case InputType.CHECKBOX:\n case InputType.RADIO:\n return this.checked;\n default:\n console.warn(\"`isChecked` method is only available for type `checkbox` and `radio`\");\n\n return false;\n }\n }\n\n /** Emitted on input value change, returns value, validity */\n @Event()\n inputChange: EventEmitter;\n\n private emitInputChange(value: string): void {\n if (!this.isTyping) {\n this.emitStartTyping();\n }\n\n let validity: ValidityState;\n if (this.type === InputType.TEXTAREA) {\n validity = this.getValidity(\"textarea\");\n } else {\n validity = this.getValidity(\"input\");\n }\n this.value = value;\n this.inputChange.emit({value, validity});\n\n clearTimeout(this.timer);\n this.timer = setTimeout(() => {\n this.emitStopTyping(this.value, validity);\n }, this.typingtimeout);\n }\n\n /** Emitted when user starts typing */\n @Event()\n startTyping: EventEmitter;\n\n private emitStartTyping(): void {\n this.isTyping = true;\n this.startTyping.emit();\n }\n\n /** Emitted when user stops typing, returns value, validity */\n @Event()\n stopTyping: EventEmitter;\n\n private emitStopTyping(value: string, validity: ValidityState): void {\n this.isTyping = false;\n this.stopTyping.emit({\n value: value,\n validity: validity,\n });\n }\n\n /** Emitted on checkbox check/uncheck, returns id, checked, type, name, value, validity */\n @Event()\n inputCheck: EventEmitter;\n\n private emitInputCheck(checked: boolean): void {\n this.inputCheck.emit({\n id: this.htmlid,\n checked: checked,\n type: this.type,\n name: this.name,\n value: this.value,\n validity: this.getValidity(\"input\"),\n });\n }\n\n /** Emitted on input focus */\n @Event()\n inputFocus: EventEmitter;\n\n private emitInputFocus(): void {\n this.inputFocus.emit({id: this.htmlid});\n }\n\n /** Emitted on input blur */\n @Event()\n inputBlur: EventEmitter;\n\n private emitInputBlur(): void {\n this.inputBlur.emit({id: this.htmlid});\n }\n\n private getValidity(type: string): ValidityState {\n const input = this.hostElement.querySelector(type) as HTMLInputElement;\n\n return input.validity;\n }\n\n /* START text/password/email/number */\n\n private getTextAttributes(): JSXBase.InputHTMLAttributes<HTMLInputElement | HTMLTextAreaElement> {\n return {\n id: this.htmlid,\n name: this.name,\n placeholder: this.placeholder,\n value: this.value,\n disabled: this.disabled,\n readonly: this.readonly,\n required: this.required,\n title: this.htmltitle,\n minlength: this.minlength,\n maxlength: this.maxlength,\n class: {\n [`input-${this.status}`]: !!this.status,\n },\n autocomplete: this.autocomplete,\n onInput: (e: InputEvent) => this.emitInputChange((e.target as HTMLInputElement).value),\n };\n }\n\n private getNumberAttributes(type: InputType): JSXBase.InputHTMLAttributes<HTMLInputElement> {\n if (type != InputType.NUMBER) {\n return;\n }\n\n return {\n min: this.min,\n max: this.max,\n step: this.step,\n };\n }\n\n private getPatternAttribute(type: InputType): JSXBase.InputHTMLAttributes<HTMLInputElement> {\n if (\n type != InputType.PASSWORD &&\n type != InputType.TEXT &&\n type != InputType.TEL &&\n type != InputType.SEARCH &&\n type != InputType.URL &&\n type != InputType.EMAIL\n ) {\n return;\n }\n\n return {\n pattern: this.pattern,\n };\n }\n\n private getRoleAttribute(): JSXBase.InputHTMLAttributes<HTMLInputElement | HTMLTextAreaElement> {\n return this.role ? {role: this.role} : {};\n }\n\n private getAriaAttrubutes(): Record<string, unknown> {\n const expanded = this.ariaExpanded ? {\"aria-expanded\": this.ariaExpanded} : {};\n const controls = this.ariaControls ? {\"aria-controls\": this.ariaControls} : {};\n const autocomplete = this.ariaAutocomplete ? {\"aria-autocomplete\": this.ariaAutocomplete} : {};\n const activedescendant = this.ariaActivedescendant ? {\"aria-activedescendant\": this.ariaActivedescendant} : {};\n\n return {\n ...expanded,\n ...controls,\n ...autocomplete,\n ...activedescendant,\n };\n }\n\n private getFocusBlurAttributes(): JSXBase.InputHTMLAttributes<HTMLInputElement | HTMLTextAreaElement> {\n return {\n onFocus: () => this.emitInputFocus(),\n onBlur: () => this.emitInputBlur(),\n };\n }\n\n private renderInputText(type: InputType = InputType.TEXT): HTMLDivElement {\n const ariaLabel = this.ariaLabel ? {\"aria-label\": this.ariaLabel} : {};\n const attr = {\n ...this.getTextAttributes(),\n ...this.getNumberAttributes(type),\n ...this.getPatternAttribute(type),\n ...ariaLabel,\n ...this.getRoleAttribute(),\n ...this.getAriaAttrubutes(),\n ...this.getFocusBlurAttributes(),\n };\n if (this.icon || type === InputType.PASSWORD) {\n Object.assign(attr.class, {\"has-icon\": true});\n }\n if (this.hasclearicon && type != InputType.NUMBER) {\n Object.assign(attr.class, {\"has-clear-icon\": true});\n }\n\n return (\n <div class=\"text-wrapper\">\n {this.renderLabel()}\n <div>\n <input\n type={type === InputType.PASSWORD && !this.passwordHidden ? InputType.TEXT : type}\n {...attr}\n ref={(el) => (this.inputRef = el)}\n />\n {this.renderIcons()}\n </div>\n {this.renderMessage()}\n </div>\n );\n }\n\n private renderLabel(): HTMLLabelElement {\n if (!this.label) {\n return;\n }\n\n return (\n <label\n class=\"z-label body-5-sb\"\n id={`${this.htmlid}_label`}\n htmlFor={this.htmlid}\n >\n {this.label}\n </label>\n );\n }\n\n private renderIcons(): HTMLSpanElement {\n return (\n <span class=\"icons-wrapper\">\n {this.renderResetIcon()}\n {this.renderIcon()}\n </span>\n );\n }\n\n private renderIcon(): HTMLButtonElement {\n if (this.type === InputType.PASSWORD) {\n return this.renderShowHidePassword();\n }\n\n if (!this.icon) {\n return;\n }\n\n return (\n <z-icon\n name={this.icon}\n class={{[this.size]: true, \"input-icon\": true}}\n />\n );\n }\n\n private renderResetIcon(): HTMLButtonElement {\n let hidden = false;\n if (!this.hasclearicon || !this.value || this.disabled || this.readonly || this.type == InputType.NUMBER) {\n hidden = true;\n }\n\n return (\n <button\n type=\"button\"\n class={{\"reset-icon\": true, \"input-icon\": true, hidden}}\n aria-label=\"cancella il contenuto dell'input\"\n onClick={() => {\n this.inputRef.value = \"\";\n this.emitInputChange(\"\");\n }}\n >\n <z-icon\n name=\"multiply\"\n class={this.size}\n />\n </button>\n );\n }\n\n private renderShowHidePassword(): HTMLButtonElement {\n return (\n <button\n type=\"button\"\n class=\"input-icon toggle-password-icon\"\n disabled={this.disabled}\n aria-label={this.passwordHidden ? \"mostra password\" : \"nascondi password\"}\n onClick={() => (this.passwordHidden = !this.passwordHidden)}\n >\n <z-icon\n name={this.passwordHidden ? \"view-filled\" : \"view-off-filled\"}\n class={this.size}\n />\n </button>\n );\n }\n\n private renderMessage(): HTMLZInputMessageElement {\n if (boolean(this.message) === false) {\n return;\n }\n\n return (\n <z-input-message\n message={boolean(this.message) === true ? undefined : (this.message as string)}\n status={this.status}\n class={this.size}\n disabled={this.disabled}\n />\n );\n }\n\n /* END text/password/email/number */\n\n /* START textarea */\n\n private renderTextarea(): HTMLDivElement {\n const attributes = this.getTextAttributes();\n\n return (\n <Fragment>\n {this.renderLabel()}\n <div\n class={{\n ...(attributes.class as {[className: string]: boolean}),\n \"textarea-wrapper\": true,\n \"readonly\": !!attributes.readonly,\n }}\n >\n <textarea\n {...attributes}\n class={{\n ...(attributes.class as {[className: string]: boolean}),\n \"z-scrollbar\": true,\n }}\n aria-label={this.ariaLabel || undefined}\n {...this.getRoleAttribute()}\n ></textarea>\n </div>\n {this.renderMessage()}\n </Fragment>\n );\n }\n\n /* END textarea */\n\n private handleCheck(ev: Event): void {\n this.checked = (ev.target as HTMLInputElement).checked;\n this.emitInputCheck(this.checked);\n }\n\n /* START checkbox */\n private renderCheckbox(): HTMLDivElement {\n return (\n <div class=\"checkbox-wrapper\">\n <input\n id={this.htmlid}\n type=\"checkbox\"\n name={this.name}\n checked={this.checked}\n disabled={this.disabled}\n readonly={this.readonly}\n required={this.required}\n onChange={this.handleCheck.bind(this)}\n value={this.value}\n {...this.getRoleAttribute()}\n {...this.getFocusBlurAttributes()}\n />\n\n <label\n htmlFor={this.htmlid}\n class={{\n \"checkbox-label\": true,\n \"after\": this.labelPosition === LabelPosition.RIGHT,\n \"before\": this.labelPosition === LabelPosition.LEFT,\n }}\n >\n <z-icon\n name={this.checked ? \"checkbox-checked\" : \"checkbox\"}\n class={this.size}\n />\n {this.label && <span innerHTML={this.label}></span>}\n </label>\n </div>\n );\n }\n\n /* END checkbox */\n\n /* START radio */\n private renderRadio(): HTMLDivElement {\n return (\n <div class=\"radio-wrapper\">\n <input\n id={this.htmlid}\n type=\"radio\"\n name={this.name}\n checked={this.checked}\n disabled={this.disabled}\n readonly={this.readonly}\n onChange={this.handleCheck.bind(this)}\n value={this.value}\n {...this.getRoleAttribute()}\n {...this.getFocusBlurAttributes()}\n />\n\n <label\n htmlFor={this.htmlid}\n class={{\n \"radio-label\": true,\n \"after\": this.labelPosition === LabelPosition.RIGHT,\n \"before\": this.labelPosition === LabelPosition.LEFT,\n }}\n >\n <z-icon\n name={this.checked ? \"radio-button-checked\" : \"radio-button\"}\n class={this.size}\n />\n {this.label && <span innerHTML={this.label} />}\n </label>\n </div>\n );\n }\n /* END radio */\n\n render(): HTMLInputElement | HTMLDivElement {\n let input;\n switch (this.type) {\n case InputType.TEXTAREA:\n input = this.renderTextarea();\n break;\n case InputType.CHECKBOX:\n input = this.renderCheckbox();\n break;\n case InputType.RADIO:\n input = this.renderRadio();\n break;\n default:\n input = this.renderInputText(this.type);\n }\n\n return <Host>{input}</Host>;\n }\n}\n"],"version":3}
|
|
1
|
+
{"file":"index11.js","mappings":";;;;AAAA,MAAM,SAAS,GAAG,yiFAAyiF,CAAC;AAC5jF,0BAAe,SAAS;;MCgBX,WAAW;;;;;oBAGd,mBAAmB;wBAQK,kBAAkB,CAAC,YAAY;;yBAQnD,4BAA4B;oBAInB,WAAW,CAAC,GAAG;oBAI7B,KAAK;;;;;IAYZ,mBAAmB;QACjB,IAAI,CAAC,IAAI,CAAC,IAAI,IAAI,CAAC,IAAI,CAAC,KAAK,EAAE;YAC7B,OAAO;SACR;QAED,MAAM,IAAI,GAAG,IAAI,CAAC,IAAI,CAAC,qBAAqB,EAAE,CAAC;QAC/C,MAAM,UAAU,GAAG,QAAQ,CAAC,gBAAgB,CAAC,QAAQ,CAAC,eAAe,CAAC,CAAC,gBAAgB,CAAC,eAAe,CAAC,EAAE,EAAE,CAAC,CAAC;QAC9G,MAAM,SAAS,GAAG,QAAQ,CAAC,eAAe,CAAC,WAAW,CAAC;;QAEvD,MAAM,cAAc,GAAG,IAAI,CAAC,KAAK,CAC/B,CAAC,IAAI,CAAC,QAAQ,CAAC,QAAQ,CAAC,MAAM,CAAC,GAAG,SAAS,GAAG,IAAI,CAAC,IAAI,GAAG,IAAI,CAAC,KAAK,IAAI,UAAU,CACnF,CAAC;QACF,IAAI,CAAC,KAAK,CAAC,KAAK,CAAC,QAAQ,GAAG,GAAG,cAAc,IAAI,CAAC;KACnD;;;;IAKO,WAAW;QACjB,IAAI,CAAC,IAAI,GAAG,CAAC,IAAI,CAAC,IAAI,CAAC;KACxB;;;;IAKO,UAAU;QAChB,IAAI,CAAC,IAAI,GAAG,KAAK,CAAC;KACnB;IAGD,eAAe,CAAC,KAAoB;QAClC,IAAI,KAAK,CAAC,GAAG,KAAK,QAAQ,IAAI,IAAI,CAAC,IAAI,EAAE;YACvC,IAAI,CAAC,UAAU,EAAE,CAAC;SACnB;KACF;IAED,MAAM;QACJ,QACE,EAAC,IAAI,qDAAC,IAAI,EAAE,IAAI,CAAC,IAAI,IACnB,+DACE,KAAK,EAAC,uBAAuB,EAC7B,IAAI,EAAC,QAAQ,EACb,OAAO,EAAE,IAAI,CAAC,WAAW,CAAC,IAAI,CAAC,IAAI,CAAC,gBACxB,CAAC,IAAI,CAAC,KAAK,GAAG,IAAI,CAAC,SAAS,GAAG,SAAS,mBACrC,IAAI,CAAC,IAAI,GAAG,MAAM,GAAG,OAAO,mBAC7B,qBAAqB,IAElC,IAAI,CAAC,IAAI,IAAI,+DAAQ,IAAI,EAAE,IAAI,CAAC,IAAI,GAAI,EACxC,IAAI,CAAC,KAAK,IAAI,6DAAM,KAAK,EAAC,qBAAqB,IAAE,IAAI,CAAC,KAAK,CAAQ,CAC7D,EACT,4DACE,KAAK,EAAC,qBAAqB,EAC3B,EAAE,EAAC,qBAAqB,EACxB,GAAG,EAAE,CAAC,EAAE,MAAM,IAAI,CAAC,KAAK,GAAG,EAAE,CAAC,EAC9B,MAAM,EAAE,CAAC,IAAI,CAAC,IAAI,IAElB,8DAAa,EACb,+DACE,KAAK,EAAC,qBAAqB,EAC3B,IAAI,EAAC,QAAQ,EACb,OAAO,EAAE,IAAI,CAAC,UAAU,CAAC,IAAI,CAAC,IAAI,CAAC,gBACxB,8BAA8B,IAEzC,+DAAQ,IAAI,EAAC,UAAU,GAAG,CACnB,CACL,CACD,EACP;KACH;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","names":[],"sources":["src/components/z-info-reveal/styles.css?tag=z-info-reveal&encapsulation=shadow","src/components/z-info-reveal/index.tsx"],"sourcesContent":[":host {\n --z-info-reveal-panel-width: 384px; /* defaults half the size of the mobile breakpoint */\n --trigger-size: 44px;\n\n position: relative;\n}\n\n:host * {\n box-sizing: border-box;\n}\n\nbutton {\n --trigger-icon-size: calc(var(--trigger-size) / 2);\n\n display: flex;\n align-items: center;\n justify-content: center;\n padding: 0;\n border: none;\n background-color: transparent;\n cursor: pointer;\n font-family: inherit;\n letter-spacing: inherit;\n}\n\nbutton:focus:focus-visible {\n box-shadow: var(--shadow-focus-primary);\n outline: none;\n}\n\n.z-info-reveal-trigger {\n min-width: var(--trigger-size);\n height: var(--trigger-size);\n padding: calc((var(--trigger-size) - var(--trigger-icon-size)) / 2);\n background-color: var(--color-surface05);\n border-radius: var(--border-radius);\n color: var(--color-text-inverse);\n column-gap: var(--space-unit);\n font-weight: var(--font-sb);\n line-height: 1rem;\n}\n\n:host([size=\"big\"]) .z-info-reveal-trigger {\n font-size: var(--font-size-2);\n}\n\n:host([size=\"small\"]) .z-info-reveal-trigger {\n --trigger-size: 36px;\n\n font-size: var(--font-size-2);\n}\n\n:host([size=\"x-small\"]) .z-info-reveal-trigger {\n --trigger-size: 32px;\n\n padding: var(--space-unit);\n font-size: var(--font-size-1);\n}\n\n:host > .z-info-reveal-trigger z-icon {\n --z-icon-width: var(--trigger-icon-size);\n --z-icon-height: var(--trigger-icon-size);\n\n display: flex;\n fill: var(--color-inverse-icon);\n}\n\n:host([size=\"small\"]) > .z-info-reveal-trigger z-icon {\n --trigger-icon-size: var(--trigger-icon-size-small, 18px);\n}\n\n:host([size=\"x-small\"]) > .z-info-reveal-trigger z-icon {\n --trigger-icon-size: var(--trigger-icon-size-x-small, 16px);\n}\n\n.z-info-reveal-panel {\n position: absolute;\n z-index: 19;\n display: flex;\n width: var(--z-info-reveal-panel-width);\n height: fit-content;\n align-items: flex-start;\n padding: calc(var(--space-unit) * 1.5);\n background-color: var(--color-surface05);\n border-radius: var(--border-radius);\n box-shadow: var(--shadow-4);\n color: var(--color-text-inverse);\n column-gap: var(--space-unit);\n}\n\n.z-info-reveal-panel[hidden] {\n display: none;\n}\n\n:host([position=\"top_left\"]) .z-info-reveal-panel,\n:host([position=\"top_right\"]) .z-info-reveal-panel {\n top: 0;\n}\n\n:host([position=\"bottom_left\"]) .z-info-reveal-panel,\n:host([position=\"bottom_right\"]) .z-info-reveal-panel {\n bottom: 0;\n}\n\n:host([position=\"top_right\"]) .z-info-reveal-panel,\n:host([position=\"bottom_right\"]) .z-info-reveal-panel {\n right: 0;\n}\n\n:host([position=\"top_left\"]) .z-info-reveal-panel,\n:host([position=\"bottom_left\"]) .z-info-reveal-panel {\n left: 0;\n}\n\n.z-info-reveal-panel .z-info-reveal-close {\n margin-left: auto;\n}\n\n.z-info-reveal-panel z-icon {\n fill: var(--color-inverse-icon);\n}\n\n@media (max-width: 767px) {\n .z-info-reveal-panel {\n top: auto !important;\n bottom: auto !important;\n width: calc(var(--z-info-reveal-panel-width) - (var(--grid-margin) * 4)) !important;\n margin-top: calc(var(--trigger-size) * -1);\n }\n}\n","import {Component, Element, Host, Listen, Prop, State, Watch, h} from \"@stencil/core\";\nimport {ControlSize, InfoRevealPosition} from \"../../beans\";\n\n/**\n * Info reveal component.\n *\n * @slot - content of the info panel.\n * @cssprop --z-info-reveal-panel-width - Width of the info panel.\n * @cssprop --trigger-icon-size - Size of the trigger icon for big size.\n * @cssprop --trigger-icon-size-small - Size of the trigger icon for small size.\n * @cssprop --trigger-icon-size-x-small - Size of the trigger icon for x-small size.\n */\n@Component({\n tag: \"z-info-reveal\",\n styleUrl: \"styles.css\",\n shadow: true,\n})\nexport class ZInfoReveal {\n /** Name of the icon for the trigger button */\n @Prop()\n icon? = \"informationsource\";\n\n /**\n * The position of the z-info-reveal in the page. This helps to correctly place the info panel.\n * The panel will grow in the opposite direction of the position.\n * For example, with the default position `BOTTOM_RIGHT`, the panel will grow vertically upwards and horizontally to the left.\n */\n @Prop({reflect: true})\n position?: InfoRevealPosition = InfoRevealPosition.BOTTOM_RIGHT;\n\n /** Label of the trigger button. */\n @Prop()\n label?: string;\n\n /** Aria label of the trigger button. It will be only used when `label` prop is empty. */\n @Prop()\n ariaLabel = \"Apri pannello informazioni\";\n\n /** Size of the trigger button */\n @Prop({reflect: true})\n size?: ControlSize = ControlSize.BIG;\n\n /** Whether the info panel is open. */\n @State()\n open = false;\n\n @Element() host: HTMLZInfoRevealElement;\n\n private panel: HTMLDivElement;\n\n /**\n * Adjust the position of the info panel to prevent exiting the viewport.\n */\n @Watch(\"position\")\n @Watch(\"open\")\n @Listen(\"resize\", {target: \"window\", passive: true})\n adjustPanelPosition(): void {\n if (!this.open || !this.panel) {\n return;\n }\n\n const rect = this.host.getBoundingClientRect();\n const gridMargin = parseInt(getComputedStyle(document.documentElement).getPropertyValue(\"--grid-margin\"), 10);\n const pageWidth = document.documentElement.offsetWidth;\n // Available space for the info panel to grow towards the edge of the page, based on the `position` prop.\n const availableSpace = Math.round(\n (this.position.includes(\"left\") ? pageWidth - rect.left : rect.right) - gridMargin\n );\n this.panel.style.maxWidth = `${availableSpace}px`;\n }\n\n /**\n * Toggle the open state of the info panel.\n */\n private togglePanel(): void {\n this.open = !this.open;\n }\n\n /**\n * Close the info panel.\n */\n private closePanel(): void {\n this.open = false;\n }\n\n @Listen(\"keydown\", {target: \"window\", capture: true})\n handleEscapeKey(event: KeyboardEvent): void {\n if (event.key === \"Escape\" && this.open) {\n this.closePanel();\n }\n }\n\n render(): HTMLZInfoRevealElement {\n return (\n <Host open={this.open}>\n <button\n class=\"z-info-reveal-trigger\"\n type=\"button\"\n onClick={this.togglePanel.bind(this)}\n aria-label={!this.label ? this.ariaLabel : undefined}\n aria-expanded={this.open ? \"true\" : \"false\"}\n aria-controls=\"z-info-reveal-panel\"\n >\n {this.icon && <z-icon name={this.icon} />}\n {this.label && <span class=\"z-info-reveal-label\">{this.label}</span>}\n </button>\n <div\n class=\"z-info-reveal-panel\"\n id=\"z-info-reveal-panel\"\n ref={(el) => (this.panel = el)}\n hidden={!this.open}\n >\n <slot></slot>\n <button\n class=\"z-info-reveal-close\"\n type=\"button\"\n onClick={this.closePanel.bind(this)}\n aria-label=\"Chiudi pannello informazioni\"\n >\n <z-icon name=\"multiply\" />\n </button>\n </div>\n </Host>\n );\n }\n}\n"],"version":3}
|