@zanichelli/albe-web-components 2.40.1 → 2.42.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 +79 -0
- package/dist/cjs/{index-dee3e21d.js → index-84b7063a.js} +182 -88
- package/dist/cjs/{index-6b11e272.js → index-ef6dc2ee.js} +10 -0
- package/dist/cjs/index.cjs.js +2 -2
- package/dist/cjs/loader.cjs.js +3 -3
- package/dist/cjs/{utils-428c57eb.js → utils-d3a23e75.js} +3 -3
- package/dist/cjs/web-components-library.cjs.js +3 -3
- package/dist/cjs/z-alert.cjs.entry.js +1 -1
- package/dist/cjs/z-app-header.cjs.entry.js +1 -1
- package/dist/cjs/z-app-switcher_10.cjs.entry.js +2 -2
- package/dist/cjs/z-aria-alert.cjs.entry.js +2 -2
- package/dist/cjs/z-avatar.cjs.entry.js +2 -2
- package/dist/cjs/z-body_2.cjs.entry.js +1 -1
- package/dist/cjs/z-button-filter_5.cjs.entry.js +3 -3
- package/dist/cjs/z-button-sort.cjs.entry.js +1 -1
- package/dist/cjs/z-candybar.cjs.entry.js +1 -1
- package/dist/cjs/z-chip.cjs.entry.js +2 -2
- package/dist/cjs/z-combobox.cjs.entry.js +3 -3
- package/dist/cjs/z-contextual-menu.cjs.entry.js +2 -2
- package/dist/cjs/z-cookiebar.cjs.entry.js +2 -2
- package/dist/cjs/z-dragdrop-area_2.cjs.entry.js +49 -0
- package/dist/cjs/z-file-upload.cjs.entry.js +169 -0
- package/dist/cjs/z-file.cjs.entry.js +53 -0
- package/dist/cjs/z-footer-link_3.cjs.entry.js +1 -1
- package/dist/cjs/z-footer.cjs.entry.js +2 -2
- package/dist/cjs/z-ghost-loading.cjs.entry.js +1 -1
- package/dist/cjs/z-icon-package.cjs.entry.js +1 -1
- package/dist/cjs/z-info-box.cjs.entry.js +1 -1
- package/dist/cjs/z-list_3.cjs.entry.js +2 -2
- package/dist/cjs/z-menu-dropdown_2.cjs.entry.js +3 -3
- package/dist/cjs/z-menu-section.cjs.entry.js +1 -1
- package/dist/cjs/z-menu.cjs.entry.js +1 -1
- package/dist/cjs/z-messages-pocket.cjs.entry.js +2 -2
- package/dist/cjs/z-modal-login.cjs.entry.js +2 -2
- package/dist/cjs/z-modal.cjs.entry.js +1 -1
- package/dist/cjs/z-myz-card-alert.cjs.entry.js +2 -2
- package/dist/cjs/z-myz-card-dictionary.cjs.entry.js +2 -2
- package/dist/cjs/z-myz-card-footer-sections.cjs.entry.js +1 -1
- package/dist/cjs/z-myz-card-footer.cjs.entry.js +2 -2
- package/dist/cjs/z-myz-card-icon.cjs.entry.js +1 -1
- package/dist/cjs/z-myz-card-info.cjs.entry.js +3 -3
- package/dist/cjs/z-myz-card-list.cjs.entry.js +1 -1
- package/dist/cjs/z-myz-card_4.cjs.entry.js +2 -2
- package/dist/cjs/z-myz-list-item.cjs.entry.js +3 -3
- package/dist/cjs/z-myz-topbar.cjs.entry.js +2 -2
- package/dist/cjs/z-navigation-tab.cjs.entry.js +1 -1
- package/dist/cjs/z-navigation-tabs.cjs.entry.js +2 -2
- package/dist/cjs/z-notification.cjs.entry.js +2 -2
- package/dist/cjs/z-otp.cjs.entry.js +2 -2
- package/dist/cjs/z-pagination-bar.cjs.entry.js +3 -3
- package/dist/cjs/z-pagination-page.cjs.entry.js +1 -1
- package/dist/cjs/z-panel-elem.cjs.entry.js +1 -1
- package/dist/cjs/z-pocket-message.cjs.entry.js +1 -1
- package/dist/cjs/z-pocket_3.cjs.entry.js +3 -3
- package/dist/cjs/z-popover.cjs.entry.js +3 -3
- package/dist/cjs/z-slideshow.cjs.entry.js +3 -3
- package/dist/cjs/z-status-tag.cjs.entry.js +2 -2
- 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-table-body.cjs.entry.js +1 -1
- package/dist/cjs/z-table-cell.cjs.entry.js +2 -2
- package/dist/cjs/z-table-empty-box.cjs.entry.js +1 -1
- package/dist/cjs/z-table-expanded-row.cjs.entry.js +1 -1
- package/dist/cjs/z-table-footer.cjs.entry.js +1 -1
- package/dist/cjs/z-table-head.cjs.entry.js +1 -1
- package/dist/cjs/z-table-header-row.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 +2 -2
- package/dist/cjs/z-table-sticky-footer.cjs.entry.js +1 -1
- package/dist/cjs/z-table.cjs.entry.js +2 -2
- package/dist/cjs/z-toast-notification-list.cjs.entry.js +2 -2
- package/dist/cjs/z-toast-notification.cjs.entry.js +2 -2
- package/dist/cjs/z-toggle-button.cjs.entry.js +1 -1
- package/dist/cjs/z-toggle-switch.cjs.entry.js +49 -0
- package/dist/cjs/z-tooltip.cjs.entry.js +2 -2
- package/dist/cjs/z-user-dropdown.cjs.entry.js +1 -1
- package/dist/cjs/z-visually-hidden.cjs.entry.js +1 -1
- package/dist/collection/beans/index.js +10 -0
- package/dist/collection/collection-manifest.json +6 -2
- package/dist/collection/components/buttons/z-button/index.js +2 -2
- package/dist/collection/components/buttons/z-toggle-switch/index.js +143 -0
- package/dist/collection/components/buttons/z-toggle-switch/styles.css +106 -0
- package/dist/collection/components/file-upload/z-dragdrop-area/index.js +52 -0
- package/dist/collection/components/file-upload/z-dragdrop-area/styles.css +62 -0
- package/dist/collection/components/file-upload/z-file/index.js +109 -0
- package/dist/collection/components/file-upload/z-file/styles.css +61 -0
- package/dist/collection/components/file-upload/z-file-upload/index.js +329 -0
- package/dist/collection/components/file-upload/z-file-upload/styles.css +87 -0
- package/dist/collection/components/navigation/z-menu/index.js +4 -4
- package/dist/collection/components/notification/z-tooltip/index.js +2 -2
- package/dist/collection/utils/utils.js +2 -2
- package/dist/esm/{index-fa9e549c.js → index-90e18641.js} +182 -88
- package/dist/esm/{index-9d70864c.js → index-cda2110a.js} +11 -1
- package/dist/esm/index.js +2 -2
- package/dist/esm/loader.js +3 -3
- package/dist/esm/polyfills/css-shim.js +1 -1
- package/dist/esm/{utils-347de6f5.js → utils-436360f5.js} +3 -3
- package/dist/esm/web-components-library.js +3 -3
- package/dist/esm/z-alert.entry.js +1 -1
- package/dist/esm/z-app-header.entry.js +1 -1
- package/dist/esm/z-app-switcher_10.entry.js +2 -2
- package/dist/esm/z-aria-alert.entry.js +2 -2
- package/dist/esm/z-avatar.entry.js +2 -2
- package/dist/esm/z-body_2.entry.js +1 -1
- package/dist/esm/z-button-filter_5.entry.js +3 -3
- package/dist/esm/z-button-sort.entry.js +1 -1
- package/dist/esm/z-candybar.entry.js +1 -1
- package/dist/esm/z-chip.entry.js +2 -2
- package/dist/esm/z-combobox.entry.js +3 -3
- package/dist/esm/z-contextual-menu.entry.js +2 -2
- package/dist/esm/z-cookiebar.entry.js +2 -2
- package/dist/esm/z-dragdrop-area_2.entry.js +44 -0
- package/dist/esm/z-file-upload.entry.js +165 -0
- package/dist/esm/z-file.entry.js +49 -0
- package/dist/esm/z-footer-link_3.entry.js +1 -1
- package/dist/esm/z-footer.entry.js +2 -2
- package/dist/esm/z-ghost-loading.entry.js +1 -1
- package/dist/esm/z-icon-package.entry.js +1 -1
- package/dist/esm/z-info-box.entry.js +1 -1
- package/dist/esm/z-list_3.entry.js +2 -2
- package/dist/esm/z-menu-dropdown_2.entry.js +3 -3
- package/dist/esm/z-menu-section.entry.js +1 -1
- package/dist/esm/z-menu.entry.js +1 -1
- package/dist/esm/z-messages-pocket.entry.js +2 -2
- package/dist/esm/z-modal-login.entry.js +2 -2
- package/dist/esm/z-modal.entry.js +1 -1
- package/dist/esm/z-myz-card-alert.entry.js +2 -2
- package/dist/esm/z-myz-card-dictionary.entry.js +2 -2
- package/dist/esm/z-myz-card-footer-sections.entry.js +1 -1
- package/dist/esm/z-myz-card-footer.entry.js +2 -2
- package/dist/esm/z-myz-card-icon.entry.js +1 -1
- package/dist/esm/z-myz-card-info.entry.js +3 -3
- package/dist/esm/z-myz-card-list.entry.js +1 -1
- package/dist/esm/z-myz-card_4.entry.js +2 -2
- package/dist/esm/z-myz-list-item.entry.js +3 -3
- package/dist/esm/z-myz-topbar.entry.js +2 -2
- package/dist/esm/z-navigation-tab.entry.js +1 -1
- package/dist/esm/z-navigation-tabs.entry.js +2 -2
- package/dist/esm/z-notification.entry.js +2 -2
- package/dist/esm/z-otp.entry.js +2 -2
- package/dist/esm/z-pagination-bar.entry.js +3 -3
- package/dist/esm/z-pagination-page.entry.js +1 -1
- package/dist/esm/z-panel-elem.entry.js +1 -1
- package/dist/esm/z-pocket-message.entry.js +1 -1
- package/dist/esm/z-pocket_3.entry.js +3 -3
- package/dist/esm/z-popover.entry.js +3 -3
- package/dist/esm/z-slideshow.entry.js +3 -3
- package/dist/esm/z-status-tag.entry.js +2 -2
- package/dist/esm/z-stepper-item.entry.js +1 -1
- package/dist/esm/z-stepper.entry.js +1 -1
- package/dist/esm/z-table-body.entry.js +1 -1
- package/dist/esm/z-table-cell.entry.js +2 -2
- package/dist/esm/z-table-empty-box.entry.js +1 -1
- package/dist/esm/z-table-expanded-row.entry.js +1 -1
- package/dist/esm/z-table-footer.entry.js +1 -1
- package/dist/esm/z-table-head.entry.js +1 -1
- package/dist/esm/z-table-header-row.entry.js +1 -1
- package/dist/esm/z-table-header.entry.js +3 -3
- package/dist/esm/z-table-row.entry.js +2 -2
- package/dist/esm/z-table-sticky-footer.entry.js +1 -1
- package/dist/esm/z-table.entry.js +2 -2
- package/dist/esm/z-toast-notification-list.entry.js +2 -2
- package/dist/esm/z-toast-notification.entry.js +2 -2
- package/dist/esm/z-toggle-button.entry.js +1 -1
- package/dist/esm/z-toggle-switch.entry.js +45 -0
- package/dist/esm/z-tooltip.entry.js +2 -2
- package/dist/esm/z-user-dropdown.entry.js +1 -1
- package/dist/esm/z-visually-hidden.entry.js +1 -1
- package/dist/types/beans/index.d.ts +8 -0
- package/dist/types/components/buttons/z-toggle-switch/index.d.ts +12 -0
- package/dist/types/components/file-upload/z-dragdrop-area/index.d.ts +9 -0
- package/dist/types/components/file-upload/z-file/index.d.ts +18 -0
- package/dist/types/components/file-upload/z-file-upload/index.d.ts +49 -0
- package/dist/types/components.d.ts +124 -1
- package/dist/types/stencil-public-runtime.d.ts +189 -186
- package/dist/web-components-library/index.esm.js +1 -1
- package/dist/web-components-library/{p-cf914ea7.entry.js → p-02474663.entry.js} +1 -1
- package/{www/build/p-4a414eb2.entry.js → dist/web-components-library/p-104b70e5.entry.js} +1 -1
- package/dist/web-components-library/{p-8deddec7.entry.js → p-105b82a6.entry.js} +1 -1
- package/dist/web-components-library/{p-3552098c.entry.js → p-21a85d4f.entry.js} +1 -1
- package/dist/web-components-library/{p-29df410a.entry.js → p-24d62d5d.entry.js} +1 -1
- package/{www/build/p-74200866.entry.js → dist/web-components-library/p-26286e79.entry.js} +1 -1
- package/dist/web-components-library/{p-9af1322d.entry.js → p-2c836d42.entry.js} +1 -1
- package/dist/web-components-library/{p-698e18cf.entry.js → p-2c8e542b.entry.js} +1 -1
- package/dist/web-components-library/{p-f1cc3489.entry.js → p-2d74660a.entry.js} +1 -1
- package/{www/build/p-ca136ef7.entry.js → dist/web-components-library/p-2edeb36b.entry.js} +1 -1
- package/dist/web-components-library/{p-a025a565.entry.js → p-32fbc96b.entry.js} +1 -1
- package/dist/web-components-library/{p-d9917511.entry.js → p-3371604c.entry.js} +1 -1
- package/dist/web-components-library/{p-e1f1f39e.entry.js → p-3fc438b7.entry.js} +1 -1
- package/dist/web-components-library/{p-cfebc80e.entry.js → p-41c5beec.entry.js} +1 -1
- package/dist/web-components-library/{p-8ef035ce.entry.js → p-49fd1045.entry.js} +1 -1
- package/dist/web-components-library/{p-4a1404e2.entry.js → p-4aaf3433.entry.js} +1 -1
- package/dist/web-components-library/{p-4665d79f.entry.js → p-4d9667dc.entry.js} +1 -1
- package/{www/build/p-c2dfaef9.entry.js → dist/web-components-library/p-5590d187.entry.js} +1 -1
- package/dist/web-components-library/p-5651167f.entry.js +1 -0
- package/dist/web-components-library/{p-15b45bd6.entry.js → p-5683fb4a.entry.js} +1 -1
- package/dist/web-components-library/{p-ebcad010.entry.js → p-5789bbe7.entry.js} +1 -1
- package/dist/web-components-library/{p-140cc18f.entry.js → p-578a5ad1.entry.js} +1 -1
- package/{www/build/p-45a41bff.entry.js → dist/web-components-library/p-5dfad268.entry.js} +1 -1
- package/dist/web-components-library/{p-f113a03a.entry.js → p-5e41c6c2.entry.js} +1 -1
- package/dist/web-components-library/{p-6583cbec.entry.js → p-6375f662.entry.js} +1 -1
- package/dist/web-components-library/{p-01a920d1.entry.js → p-654c1830.entry.js} +1 -1
- package/dist/web-components-library/{p-4c1dc891.entry.js → p-6baa8e33.entry.js} +1 -1
- package/dist/web-components-library/{p-1094e4de.entry.js → p-6bb8de3e.entry.js} +1 -1
- package/dist/web-components-library/{p-250926fe.entry.js → p-71e8c2af.entry.js} +1 -1
- package/dist/web-components-library/{p-bbbdb48a.entry.js → p-729a98ab.entry.js} +1 -1
- package/dist/web-components-library/{p-71cc7ed0.entry.js → p-78e26102.entry.js} +1 -1
- package/dist/web-components-library/{p-3c5e84f2.entry.js → p-7a3c0d01.entry.js} +1 -1
- package/dist/web-components-library/{p-b78fb152.entry.js → p-7ebb03d8.entry.js} +1 -1
- package/dist/web-components-library/{p-aa0f7169.entry.js → p-7f2fa336.entry.js} +1 -1
- package/dist/web-components-library/{p-5c860beb.entry.js → p-83dda293.entry.js} +1 -1
- package/dist/web-components-library/{p-1231efbf.entry.js → p-8537e37d.entry.js} +1 -1
- package/dist/web-components-library/{p-be15a83a.entry.js → p-889bcfab.entry.js} +1 -1
- package/dist/web-components-library/{p-fa0e0402.entry.js → p-8ddeda29.entry.js} +1 -1
- package/dist/web-components-library/{p-0ce6293a.entry.js → p-9260abad.entry.js} +1 -1
- package/dist/web-components-library/{p-ac3bc4c2.entry.js → p-9352da73.entry.js} +1 -1
- package/dist/web-components-library/{p-b52459fd.entry.js → p-9409540b.entry.js} +1 -1
- package/dist/web-components-library/{p-2df6d015.entry.js → p-96da0513.entry.js} +1 -1
- package/dist/web-components-library/p-98268a57.js +1 -0
- package/{www/build/p-017ddee6.entry.js → dist/web-components-library/p-98e15cf2.entry.js} +1 -1
- package/{www/build/p-a7733104.entry.js → dist/web-components-library/p-9c7cf598.entry.js} +1 -1
- package/dist/web-components-library/p-9dc8fdb1.entry.js +1 -0
- package/dist/web-components-library/{p-1879f46c.entry.js → p-a61ee49c.entry.js} +1 -1
- package/dist/web-components-library/{p-c7af96eb.entry.js → p-a759ab46.entry.js} +1 -1
- package/dist/web-components-library/p-a785ff38.entry.js +1 -0
- package/dist/web-components-library/p-a90d876c.entry.js +1 -0
- package/dist/web-components-library/{p-db5863cf.entry.js → p-a9eea65b.entry.js} +1 -1
- package/dist/web-components-library/{p-9cb6848c.entry.js → p-b359a48a.entry.js} +1 -1
- package/dist/web-components-library/{p-9d3ea635.entry.js → p-b48105a4.entry.js} +1 -1
- package/dist/web-components-library/{p-f34a707c.entry.js → p-b68c2b06.entry.js} +1 -1
- package/dist/web-components-library/{p-eadaf008.entry.js → p-bc4df198.entry.js} +1 -1
- package/dist/web-components-library/{p-24a2786b.js → p-c17b64f1.js} +1 -1
- package/dist/web-components-library/{p-1c72783c.entry.js → p-c284139b.entry.js} +1 -1
- package/dist/web-components-library/p-c9c7071f.entry.js +1 -0
- package/dist/web-components-library/{p-f7f9db16.entry.js → p-caa452fc.entry.js} +1 -1
- package/dist/web-components-library/{p-5bbbc979.entry.js → p-cb13d050.entry.js} +1 -1
- package/dist/web-components-library/{p-fa1e086f.entry.js → p-cf00f379.entry.js} +1 -1
- package/dist/web-components-library/{p-fdfca9b7.entry.js → p-d39c0372.entry.js} +1 -1
- package/dist/web-components-library/{p-8edb6b65.entry.js → p-d4927410.entry.js} +1 -1
- package/dist/web-components-library/{p-5aff6913.entry.js → p-d59d1090.entry.js} +1 -1
- package/dist/web-components-library/p-d64c6f56.entry.js +1 -0
- package/dist/web-components-library/{p-6847ed50.entry.js → p-d97dd15a.entry.js} +1 -1
- package/dist/web-components-library/{p-74fb3d69.entry.js → p-e2560604.entry.js} +1 -1
- package/dist/web-components-library/p-e5602e1b.js +1 -0
- package/dist/web-components-library/p-f6a11970.entry.js +1 -0
- package/dist/web-components-library/{p-4e896ed8.entry.js → p-fc2043f7.entry.js} +1 -1
- package/{www/build/p-b171474c.entry.js → dist/web-components-library/p-fc5bb8d5.entry.js} +1 -1
- package/{www/build/p-f333967e.entry.js → dist/web-components-library/p-fd167bfb.entry.js} +1 -1
- package/dist/web-components-library/p-febe0261.entry.js +1 -0
- package/dist/web-components-library/web-components-library.css +1 -1
- package/dist/web-components-library/web-components-library.esm.js +1 -1
- package/loader/index.d.ts +0 -1
- package/package.json +2 -2
- package/react/components.d.ts +4 -0
- package/react/components.js +6 -2
- package/react/components.js.map +1 -1
- package/react/react-component-lib/createComponent.d.ts +1 -1
- package/react/react-component-lib/createComponent.js +42 -10
- package/react/react-component-lib/createComponent.js.map +1 -1
- package/react/react-component-lib/createOverlayComponent.d.ts +5 -4
- package/react/react-component-lib/createOverlayComponent.js +28 -8
- package/react/react-component-lib/createOverlayComponent.js.map +1 -1
- package/react/react-component-lib/utils/attachProps.d.ts +1 -1
- package/react/react-component-lib/utils/attachProps.js +14 -12
- package/react/react-component-lib/utils/attachProps.js.map +1 -1
- package/react/react-component-lib/utils/index.d.ts +4 -1
- package/react/react-component-lib/utils/index.js +20 -5
- package/react/react-component-lib/utils/index.js.map +1 -1
- package/www/build/index.esm.js +1 -1
- package/www/build/{p-cf914ea7.entry.js → p-02474663.entry.js} +1 -1
- package/{dist/web-components-library/p-4a414eb2.entry.js → www/build/p-104b70e5.entry.js} +1 -1
- package/www/build/{p-8deddec7.entry.js → p-105b82a6.entry.js} +1 -1
- package/www/build/{p-3552098c.entry.js → p-21a85d4f.entry.js} +1 -1
- package/www/build/{p-29df410a.entry.js → p-24d62d5d.entry.js} +1 -1
- package/{dist/web-components-library/p-74200866.entry.js → www/build/p-26286e79.entry.js} +1 -1
- package/www/build/{p-9af1322d.entry.js → p-2c836d42.entry.js} +1 -1
- package/www/build/{p-698e18cf.entry.js → p-2c8e542b.entry.js} +1 -1
- package/www/build/{p-f1cc3489.entry.js → p-2d74660a.entry.js} +1 -1
- package/{dist/web-components-library/p-ca136ef7.entry.js → www/build/p-2edeb36b.entry.js} +1 -1
- package/www/build/{p-a025a565.entry.js → p-32fbc96b.entry.js} +1 -1
- package/www/build/{p-d9917511.entry.js → p-3371604c.entry.js} +1 -1
- package/www/build/{p-e1f1f39e.entry.js → p-3fc438b7.entry.js} +1 -1
- package/www/build/{p-cfebc80e.entry.js → p-41c5beec.entry.js} +1 -1
- package/www/build/{p-8ef035ce.entry.js → p-49fd1045.entry.js} +1 -1
- package/www/build/{p-4a1404e2.entry.js → p-4aaf3433.entry.js} +1 -1
- package/www/build/{p-4665d79f.entry.js → p-4d9667dc.entry.js} +1 -1
- package/{dist/web-components-library/p-c2dfaef9.entry.js → www/build/p-5590d187.entry.js} +1 -1
- package/www/build/p-5651167f.entry.js +1 -0
- package/www/build/{p-15b45bd6.entry.js → p-5683fb4a.entry.js} +1 -1
- package/www/build/{p-ebcad010.entry.js → p-5789bbe7.entry.js} +1 -1
- package/www/build/{p-140cc18f.entry.js → p-578a5ad1.entry.js} +1 -1
- package/{dist/web-components-library/p-45a41bff.entry.js → www/build/p-5dfad268.entry.js} +1 -1
- package/www/build/{p-f113a03a.entry.js → p-5e41c6c2.entry.js} +1 -1
- package/www/build/{p-6583cbec.entry.js → p-6375f662.entry.js} +1 -1
- package/www/build/{p-01a920d1.entry.js → p-654c1830.entry.js} +1 -1
- package/www/build/{p-4c1dc891.entry.js → p-6baa8e33.entry.js} +1 -1
- package/www/build/{p-1094e4de.entry.js → p-6bb8de3e.entry.js} +1 -1
- package/www/build/{p-250926fe.entry.js → p-71e8c2af.entry.js} +1 -1
- package/www/build/{p-bbbdb48a.entry.js → p-729a98ab.entry.js} +1 -1
- package/www/build/{p-71cc7ed0.entry.js → p-78e26102.entry.js} +1 -1
- package/www/build/{p-3c5e84f2.entry.js → p-7a3c0d01.entry.js} +1 -1
- package/www/build/{p-b78fb152.entry.js → p-7ebb03d8.entry.js} +1 -1
- package/www/build/{p-aa0f7169.entry.js → p-7f2fa336.entry.js} +1 -1
- package/www/build/{p-5c860beb.entry.js → p-83dda293.entry.js} +1 -1
- package/www/build/{p-1231efbf.entry.js → p-8537e37d.entry.js} +1 -1
- package/www/build/{p-be15a83a.entry.js → p-889bcfab.entry.js} +1 -1
- package/www/build/{p-fa0e0402.entry.js → p-8ddeda29.entry.js} +1 -1
- package/www/build/{p-0ce6293a.entry.js → p-9260abad.entry.js} +1 -1
- package/www/build/{p-ac3bc4c2.entry.js → p-9352da73.entry.js} +1 -1
- package/www/build/{p-b52459fd.entry.js → p-9409540b.entry.js} +1 -1
- package/www/build/{p-2df6d015.entry.js → p-96da0513.entry.js} +1 -1
- package/www/build/p-98268a57.js +1 -0
- package/{dist/web-components-library/p-017ddee6.entry.js → www/build/p-98e15cf2.entry.js} +1 -1
- package/{dist/web-components-library/p-a7733104.entry.js → www/build/p-9c7cf598.entry.js} +1 -1
- package/www/build/p-9dc8fdb1.entry.js +1 -0
- package/www/build/{p-1879f46c.entry.js → p-a61ee49c.entry.js} +1 -1
- package/www/build/{p-c7af96eb.entry.js → p-a759ab46.entry.js} +1 -1
- package/www/build/p-a785ff38.entry.js +1 -0
- package/www/build/p-a90d876c.entry.js +1 -0
- package/www/build/{p-db5863cf.entry.js → p-a9eea65b.entry.js} +1 -1
- package/www/build/{p-9cb6848c.entry.js → p-b359a48a.entry.js} +1 -1
- package/www/build/{p-9d3ea635.entry.js → p-b48105a4.entry.js} +1 -1
- package/www/build/{p-f34a707c.entry.js → p-b68c2b06.entry.js} +1 -1
- package/www/build/{p-eadaf008.entry.js → p-bc4df198.entry.js} +1 -1
- package/www/build/{p-24a2786b.js → p-c17b64f1.js} +1 -1
- package/www/build/{p-1c72783c.entry.js → p-c284139b.entry.js} +1 -1
- package/www/build/p-c9c7071f.entry.js +1 -0
- package/www/build/{p-f7f9db16.entry.js → p-caa452fc.entry.js} +1 -1
- package/www/build/{p-5bbbc979.entry.js → p-cb13d050.entry.js} +1 -1
- package/www/build/{p-fa1e086f.entry.js → p-cf00f379.entry.js} +1 -1
- package/www/build/{p-fdfca9b7.entry.js → p-d39c0372.entry.js} +1 -1
- package/www/build/{p-8edb6b65.entry.js → p-d4927410.entry.js} +1 -1
- package/www/build/{p-5aff6913.entry.js → p-d59d1090.entry.js} +1 -1
- package/www/build/p-d64c6f56.entry.js +1 -0
- package/www/build/{p-6847ed50.entry.js → p-d97dd15a.entry.js} +1 -1
- package/www/build/{p-74fb3d69.entry.js → p-e2560604.entry.js} +1 -1
- package/www/build/p-e5602e1b.js +1 -0
- package/www/build/p-f6a11970.entry.js +1 -0
- package/www/build/{p-4e896ed8.entry.js → p-fc2043f7.entry.js} +1 -1
- package/{dist/web-components-library/p-b171474c.entry.js → www/build/p-fc5bb8d5.entry.js} +1 -1
- package/www/build/p-fcff1237.css +812 -0
- package/{dist/web-components-library/p-f333967e.entry.js → www/build/p-fd167bfb.entry.js} +1 -1
- package/www/build/p-fe32c7fa.js +129 -0
- package/www/build/p-febe0261.entry.js +1 -0
- package/www/build/web-components-library.css +1 -1
- package/www/build/web-components-library.esm.js +1 -1
- package/www/build/web-components-library.js +1 -1
- package/www/index.html +1 -1
- package/www/pages/file-upload.html +236 -0
- package/dist/cjs/z-heading.cjs.entry.js +0 -17
- package/dist/esm/z-heading.entry.js +0 -13
- package/dist/web-components-library/p-3b3cd128.js +0 -1
- package/dist/web-components-library/p-483d10ba.entry.js +0 -1
- package/dist/web-components-library/p-48e0a763.entry.js +0 -1
- package/dist/web-components-library/p-8a061b5b.entry.js +0 -1
- package/dist/web-components-library/p-904a85e4.js +0 -1
- package/dist/web-components-library/p-a1bb6af2.entry.js +0 -1
- package/dist/web-components-library/p-e60c2a06.entry.js +0 -1
- package/www/build/p-3b3cd128.js +0 -1
- package/www/build/p-483d10ba.entry.js +0 -1
- package/www/build/p-48e0a763.entry.js +0 -1
- package/www/build/p-8a061b5b.entry.js +0 -1
- package/www/build/p-8af945c2.js +0 -1
- package/www/build/p-904a85e4.js +0 -1
- package/www/build/p-a1bb6af2.entry.js +0 -1
- package/www/build/p-e60c2a06.entry.js +0 -1
- package/www/build/p-ea943cbd.css +0 -1
|
@@ -0,0 +1,329 @@
|
|
|
1
|
+
import { Component, Prop, h, Event, State, Listen, Element, } from "@stencil/core";
|
|
2
|
+
import { DeviceEnum, DividerSize, ZFileUploadTypeEnum, } from "../../../beans";
|
|
3
|
+
import { getDevice } from "../../../utils/utils";
|
|
4
|
+
export class ZFileUpload {
|
|
5
|
+
constructor() {
|
|
6
|
+
/** Prop indicating the file upload type - can be default or dragdrop */
|
|
7
|
+
this.type = ZFileUploadTypeEnum.default;
|
|
8
|
+
/** Number of files added by the user */
|
|
9
|
+
this.filesNumber = 0;
|
|
10
|
+
this.inputAttributes = {
|
|
11
|
+
type: "file",
|
|
12
|
+
id: "fileElem",
|
|
13
|
+
multiple: true,
|
|
14
|
+
};
|
|
15
|
+
}
|
|
16
|
+
/** Listen removeFile event sent from z-file component */
|
|
17
|
+
removeFileListener() {
|
|
18
|
+
this.filesNumber--;
|
|
19
|
+
}
|
|
20
|
+
/** Listen fileDropped event sent from z-dragdrop-area component */
|
|
21
|
+
fileDroppedListener(e) {
|
|
22
|
+
this.input.files = e.detail;
|
|
23
|
+
this.fileInputHandler();
|
|
24
|
+
}
|
|
25
|
+
componentDidUpdate() {
|
|
26
|
+
this.handleAccessibility();
|
|
27
|
+
this.invalidFiles.size && this.errorModal.focus();
|
|
28
|
+
}
|
|
29
|
+
componentWillLoad() {
|
|
30
|
+
this.invalidFiles = new Map();
|
|
31
|
+
if (this.type === ZFileUploadTypeEnum.dragdrop &&
|
|
32
|
+
getDevice() !== DeviceEnum.desktop)
|
|
33
|
+
this.type = ZFileUploadTypeEnum.default;
|
|
34
|
+
}
|
|
35
|
+
fileInputHandler() {
|
|
36
|
+
if (this.input.files.length) {
|
|
37
|
+
this.invalidFiles = this.checkFiles(Array.from(this.input.files));
|
|
38
|
+
}
|
|
39
|
+
}
|
|
40
|
+
handleAccessibility() {
|
|
41
|
+
if (this.filesNumber > 0) {
|
|
42
|
+
this.el.querySelector('z-file:last-child > z-chip').shadowRoot.querySelector('button').focus();
|
|
43
|
+
}
|
|
44
|
+
else {
|
|
45
|
+
this.type === ZFileUploadTypeEnum.default ? this.button.shadowRoot.querySelector('button').focus() : this.uploadLink.focus();
|
|
46
|
+
}
|
|
47
|
+
}
|
|
48
|
+
checkFiles(files) {
|
|
49
|
+
let errors = new Map();
|
|
50
|
+
const sizeErrorString = `supera i ${this.fileMaxSize}MB`;
|
|
51
|
+
const formatErrorString = " ha un'estensione non prevista";
|
|
52
|
+
files.forEach((file) => {
|
|
53
|
+
const fileSize = file.size / 1024 / 1024;
|
|
54
|
+
const fileFormatOk = this.acceptedFormat
|
|
55
|
+
.split(",")
|
|
56
|
+
.some((ext) => file.name.toLowerCase().endsWith(ext.trim()));
|
|
57
|
+
const fileSizeOk = fileSize <= this.fileMaxSize;
|
|
58
|
+
if (fileSizeOk && fileFormatOk) {
|
|
59
|
+
this.fileInput.emit(file);
|
|
60
|
+
this.filesNumber++;
|
|
61
|
+
this.input.value = "";
|
|
62
|
+
return;
|
|
63
|
+
}
|
|
64
|
+
errors.set(file.name, []);
|
|
65
|
+
if (!fileSizeOk) {
|
|
66
|
+
errors.get(file.name).push(sizeErrorString);
|
|
67
|
+
}
|
|
68
|
+
if (!fileFormatOk) {
|
|
69
|
+
errors.get(file.name).push(formatErrorString);
|
|
70
|
+
}
|
|
71
|
+
});
|
|
72
|
+
return errors;
|
|
73
|
+
}
|
|
74
|
+
renderTitle() {
|
|
75
|
+
return (h("z-heading", { id: "title", variant: "semibold", level: 2 }, this.mainTitle));
|
|
76
|
+
}
|
|
77
|
+
renderDescription(variant, level) {
|
|
78
|
+
return (h("z-body", { variant: variant, level: level }, this.description));
|
|
79
|
+
}
|
|
80
|
+
renderAllowedFileExtensions() {
|
|
81
|
+
let fileFormatString = "";
|
|
82
|
+
let fileWeightString = "";
|
|
83
|
+
if (this.acceptedFormat) {
|
|
84
|
+
const fileFormat = this.acceptedFormat.split(', ')
|
|
85
|
+
.map((string) => string.substring(1).toUpperCase())
|
|
86
|
+
.join(', ');
|
|
87
|
+
fileFormatString = ` nei formati ${fileFormat}`;
|
|
88
|
+
}
|
|
89
|
+
if (this.fileMaxSize) {
|
|
90
|
+
fileWeightString = ` per un massimo di ${this.fileMaxSize}MB di peso`;
|
|
91
|
+
}
|
|
92
|
+
const finalString = `Puoi allegare file${fileFormatString}${fileWeightString}.`;
|
|
93
|
+
return (h("z-body", { level: 3 }, fileFormatString || fileWeightString ? finalString : null));
|
|
94
|
+
}
|
|
95
|
+
renderFileSection() {
|
|
96
|
+
return (this.filesNumber > 0 && (h("section", { class: "files-container" },
|
|
97
|
+
h("z-heading", { variant: "semibold", level: 4 }, "File appena caricati"),
|
|
98
|
+
h("div", { class: "files" },
|
|
99
|
+
h("slot", { name: "files" })),
|
|
100
|
+
h("z-divider", { size: DividerSize.medium }))));
|
|
101
|
+
}
|
|
102
|
+
renderInput() {
|
|
103
|
+
return (h("input", Object.assign({}, this.inputAttributes, { onChange: () => this.fileInputHandler(), accept: this.acceptedFormat, ref: (val) => (this.input = val) })));
|
|
104
|
+
}
|
|
105
|
+
renderUploadButton() {
|
|
106
|
+
return [
|
|
107
|
+
this.renderInput(),
|
|
108
|
+
h("z-button", { onClick: () => this.input.click(), onKeyPress: (e) => {
|
|
109
|
+
if (e.code == 'Space' || e.code == 'Enter') {
|
|
110
|
+
e.preventDefault();
|
|
111
|
+
this.input.click();
|
|
112
|
+
}
|
|
113
|
+
}, id: "fileSelect", variant: this.buttonVariant, icon: "upload", ref: (val) => this.button = val }, "Allega"),
|
|
114
|
+
];
|
|
115
|
+
}
|
|
116
|
+
renderUploadLink() {
|
|
117
|
+
return [
|
|
118
|
+
this.renderInput(),
|
|
119
|
+
h("z-body", { class: "upload-link-text", variant: "regular", level: 1 },
|
|
120
|
+
"Trascinalo qui o",
|
|
121
|
+
" ",
|
|
122
|
+
h("z-body", { tabIndex: 0, class: "upload-link", onClick: () => this.input.click(), onKeyPress: (e) => {
|
|
123
|
+
if (e.code == 'Space' || e.code == 'Enter') {
|
|
124
|
+
e.preventDefault();
|
|
125
|
+
this.input.click();
|
|
126
|
+
}
|
|
127
|
+
}, variant: "semibold", level: 1, ref: (val) => this.uploadLink = val }, "caricalo"),
|
|
128
|
+
" ",
|
|
129
|
+
"dal tuo computer"),
|
|
130
|
+
];
|
|
131
|
+
}
|
|
132
|
+
renderDefaultMode() {
|
|
133
|
+
return [
|
|
134
|
+
this.renderDescription("semibold", 3),
|
|
135
|
+
this.renderAllowedFileExtensions(),
|
|
136
|
+
this.renderFileSection(),
|
|
137
|
+
this.renderUploadButton(),
|
|
138
|
+
];
|
|
139
|
+
}
|
|
140
|
+
renderDragDropMode() {
|
|
141
|
+
return [
|
|
142
|
+
this.renderFileSection(),
|
|
143
|
+
h("z-dragdrop-area", null,
|
|
144
|
+
h("div", { class: "text-container" },
|
|
145
|
+
this.renderDescription("regular", 1),
|
|
146
|
+
this.renderUploadLink(),
|
|
147
|
+
this.renderAllowedFileExtensions())),
|
|
148
|
+
];
|
|
149
|
+
}
|
|
150
|
+
formatErrorString(key, value) {
|
|
151
|
+
var _a, _b;
|
|
152
|
+
const bothErrors = value[0] && value[1] ? ", " : "";
|
|
153
|
+
return `Il file ${key} ${(_a = value[0]) !== null && _a !== void 0 ? _a : ""}${bothErrors} ${(_b = value[1]) !== null && _b !== void 0 ? _b : ""} e non può quindi essere caricato.`;
|
|
154
|
+
}
|
|
155
|
+
handleErrorModalContent() {
|
|
156
|
+
return (h("div", { slot: "modalContent" },
|
|
157
|
+
h("div", { class: "modalWrapper" },
|
|
158
|
+
h("div", { class: "files" }, Array.from(this.invalidFiles).map(([key, value]) => {
|
|
159
|
+
return (h("z-body", { variant: "regular", level: 3 }, this.formatErrorString(key, value)));
|
|
160
|
+
})))));
|
|
161
|
+
}
|
|
162
|
+
render() {
|
|
163
|
+
return [
|
|
164
|
+
h("div", { tabIndex: 0, class: `container ${this.type}` },
|
|
165
|
+
this.renderTitle(),
|
|
166
|
+
this.type == ZFileUploadTypeEnum.default
|
|
167
|
+
? this.renderDefaultMode()
|
|
168
|
+
: this.renderDragDropMode()),
|
|
169
|
+
!!this.invalidFiles.size && (h("z-modal", { tabIndex: 0, ref: (val) => this.errorModal = val, modaltitle: "Attenzione", onModalClose: () => this.invalidFiles = new Map(), onModalBackgroundClick: () => this.invalidFiles = new Map() }, this.handleErrorModalContent()))
|
|
170
|
+
];
|
|
171
|
+
}
|
|
172
|
+
static get is() { return "z-file-upload"; }
|
|
173
|
+
static get encapsulation() { return "scoped"; }
|
|
174
|
+
static get originalStyleUrls() { return {
|
|
175
|
+
"$": ["styles.css"]
|
|
176
|
+
}; }
|
|
177
|
+
static get styleUrls() { return {
|
|
178
|
+
"$": ["styles.css"]
|
|
179
|
+
}; }
|
|
180
|
+
static get properties() { return {
|
|
181
|
+
"type": {
|
|
182
|
+
"type": "string",
|
|
183
|
+
"mutable": true,
|
|
184
|
+
"complexType": {
|
|
185
|
+
"original": "ZFileUploadTypeEnum",
|
|
186
|
+
"resolved": "ZFileUploadTypeEnum.default | ZFileUploadTypeEnum.dragdrop",
|
|
187
|
+
"references": {
|
|
188
|
+
"ZFileUploadTypeEnum": {
|
|
189
|
+
"location": "import",
|
|
190
|
+
"path": "../../../beans"
|
|
191
|
+
}
|
|
192
|
+
}
|
|
193
|
+
},
|
|
194
|
+
"required": false,
|
|
195
|
+
"optional": false,
|
|
196
|
+
"docs": {
|
|
197
|
+
"tags": [],
|
|
198
|
+
"text": "Prop indicating the file upload type - can be default or dragdrop"
|
|
199
|
+
},
|
|
200
|
+
"attribute": "type",
|
|
201
|
+
"reflect": true,
|
|
202
|
+
"defaultValue": "ZFileUploadTypeEnum.default"
|
|
203
|
+
},
|
|
204
|
+
"buttonVariant": {
|
|
205
|
+
"type": "string",
|
|
206
|
+
"mutable": false,
|
|
207
|
+
"complexType": {
|
|
208
|
+
"original": "ButtonVariantEnum",
|
|
209
|
+
"resolved": "ButtonVariantEnum.primary | ButtonVariantEnum.secondary | ButtonVariantEnum.tertiary | typeof ButtonVariantEnum[\"dark-bg\"]",
|
|
210
|
+
"references": {
|
|
211
|
+
"ButtonVariantEnum": {
|
|
212
|
+
"location": "import",
|
|
213
|
+
"path": "../../../beans"
|
|
214
|
+
}
|
|
215
|
+
}
|
|
216
|
+
},
|
|
217
|
+
"required": false,
|
|
218
|
+
"optional": true,
|
|
219
|
+
"docs": {
|
|
220
|
+
"tags": [],
|
|
221
|
+
"text": "Prop indicating the button variant"
|
|
222
|
+
},
|
|
223
|
+
"attribute": "button-variant",
|
|
224
|
+
"reflect": false
|
|
225
|
+
},
|
|
226
|
+
"acceptedFormat": {
|
|
227
|
+
"type": "string",
|
|
228
|
+
"mutable": false,
|
|
229
|
+
"complexType": {
|
|
230
|
+
"original": "string",
|
|
231
|
+
"resolved": "string",
|
|
232
|
+
"references": {}
|
|
233
|
+
},
|
|
234
|
+
"required": false,
|
|
235
|
+
"optional": true,
|
|
236
|
+
"docs": {
|
|
237
|
+
"tags": [],
|
|
238
|
+
"text": "Prop indicating the accepted file type: ex \".pdf, .doc, .jpg\""
|
|
239
|
+
},
|
|
240
|
+
"attribute": "accepted-format",
|
|
241
|
+
"reflect": false
|
|
242
|
+
},
|
|
243
|
+
"fileMaxSize": {
|
|
244
|
+
"type": "number",
|
|
245
|
+
"mutable": false,
|
|
246
|
+
"complexType": {
|
|
247
|
+
"original": "number",
|
|
248
|
+
"resolved": "number",
|
|
249
|
+
"references": {}
|
|
250
|
+
},
|
|
251
|
+
"required": false,
|
|
252
|
+
"optional": true,
|
|
253
|
+
"docs": {
|
|
254
|
+
"tags": [],
|
|
255
|
+
"text": "Max file dimension in Megabyte"
|
|
256
|
+
},
|
|
257
|
+
"attribute": "file-max-size",
|
|
258
|
+
"reflect": false
|
|
259
|
+
},
|
|
260
|
+
"mainTitle": {
|
|
261
|
+
"type": "string",
|
|
262
|
+
"mutable": false,
|
|
263
|
+
"complexType": {
|
|
264
|
+
"original": "string",
|
|
265
|
+
"resolved": "string",
|
|
266
|
+
"references": {}
|
|
267
|
+
},
|
|
268
|
+
"required": false,
|
|
269
|
+
"optional": true,
|
|
270
|
+
"docs": {
|
|
271
|
+
"tags": [],
|
|
272
|
+
"text": "Title"
|
|
273
|
+
},
|
|
274
|
+
"attribute": "main-title",
|
|
275
|
+
"reflect": false
|
|
276
|
+
},
|
|
277
|
+
"description": {
|
|
278
|
+
"type": "string",
|
|
279
|
+
"mutable": false,
|
|
280
|
+
"complexType": {
|
|
281
|
+
"original": "string",
|
|
282
|
+
"resolved": "string",
|
|
283
|
+
"references": {}
|
|
284
|
+
},
|
|
285
|
+
"required": false,
|
|
286
|
+
"optional": true,
|
|
287
|
+
"docs": {
|
|
288
|
+
"tags": [],
|
|
289
|
+
"text": "Description"
|
|
290
|
+
},
|
|
291
|
+
"attribute": "description",
|
|
292
|
+
"reflect": false
|
|
293
|
+
}
|
|
294
|
+
}; }
|
|
295
|
+
static get states() { return {
|
|
296
|
+
"filesNumber": {},
|
|
297
|
+
"invalidFiles": {}
|
|
298
|
+
}; }
|
|
299
|
+
static get events() { return [{
|
|
300
|
+
"method": "fileInput",
|
|
301
|
+
"name": "fileInput",
|
|
302
|
+
"bubbles": true,
|
|
303
|
+
"cancelable": true,
|
|
304
|
+
"composed": true,
|
|
305
|
+
"docs": {
|
|
306
|
+
"tags": [],
|
|
307
|
+
"text": "Emitted when user select one or more files"
|
|
308
|
+
},
|
|
309
|
+
"complexType": {
|
|
310
|
+
"original": "any",
|
|
311
|
+
"resolved": "any",
|
|
312
|
+
"references": {}
|
|
313
|
+
}
|
|
314
|
+
}]; }
|
|
315
|
+
static get elementRef() { return "el"; }
|
|
316
|
+
static get listeners() { return [{
|
|
317
|
+
"name": "removeFile",
|
|
318
|
+
"method": "removeFileListener",
|
|
319
|
+
"target": undefined,
|
|
320
|
+
"capture": false,
|
|
321
|
+
"passive": false
|
|
322
|
+
}, {
|
|
323
|
+
"name": "fileDropped",
|
|
324
|
+
"method": "fileDroppedListener",
|
|
325
|
+
"target": undefined,
|
|
326
|
+
"capture": false,
|
|
327
|
+
"passive": false
|
|
328
|
+
}]; }
|
|
329
|
+
}
|
|
@@ -0,0 +1,87 @@
|
|
|
1
|
+
:host {
|
|
2
|
+
font-family: var(--font-family-sans);
|
|
3
|
+
font-weight: var(--font-rg);
|
|
4
|
+
color: var(--color-text01);
|
|
5
|
+
}
|
|
6
|
+
|
|
7
|
+
:host > .container {
|
|
8
|
+
display: flex;
|
|
9
|
+
flex-direction: column;
|
|
10
|
+
}
|
|
11
|
+
|
|
12
|
+
:host .modalWrapper {
|
|
13
|
+
display: flex;
|
|
14
|
+
justify-content: center;
|
|
15
|
+
align-items: center;
|
|
16
|
+
}
|
|
17
|
+
|
|
18
|
+
:host .modalWrapper > .files {
|
|
19
|
+
margin: calc(var(--space-unit) * 4);
|
|
20
|
+
display: flex;
|
|
21
|
+
flex-direction: column;
|
|
22
|
+
gap: var(--space-unit);
|
|
23
|
+
}
|
|
24
|
+
|
|
25
|
+
:host .text-container {
|
|
26
|
+
display: flex;
|
|
27
|
+
flex-direction: column;
|
|
28
|
+
margin: auto;
|
|
29
|
+
}
|
|
30
|
+
|
|
31
|
+
:host .text-container z-body {
|
|
32
|
+
text-align: center;
|
|
33
|
+
}
|
|
34
|
+
|
|
35
|
+
:host .text-container .upload-link {
|
|
36
|
+
color: var(--color-link-primary);
|
|
37
|
+
cursor: pointer;
|
|
38
|
+
}
|
|
39
|
+
|
|
40
|
+
:host .text-container .upload-link-text {
|
|
41
|
+
margin-bottom: var(--space-unit);
|
|
42
|
+
}
|
|
43
|
+
|
|
44
|
+
input#fileElem {
|
|
45
|
+
display: none;
|
|
46
|
+
}
|
|
47
|
+
|
|
48
|
+
#title {
|
|
49
|
+
display: inline-block;
|
|
50
|
+
margin-bottom: var(--space-unit);
|
|
51
|
+
}
|
|
52
|
+
|
|
53
|
+
:host > .container > z-button {
|
|
54
|
+
display: inline-block;
|
|
55
|
+
margin-top: calc(var(--space-unit) * 3);
|
|
56
|
+
}
|
|
57
|
+
|
|
58
|
+
:host > .container > .files-container > z-heading {
|
|
59
|
+
display: inline-block;
|
|
60
|
+
margin: calc(var(--space-unit) * 3) 0;
|
|
61
|
+
}
|
|
62
|
+
|
|
63
|
+
:host > .container > .files-container > .files {
|
|
64
|
+
display: flex;
|
|
65
|
+
flex-wrap: wrap;
|
|
66
|
+
row-gap: calc(var(--space-unit) * 2);
|
|
67
|
+
column-gap: calc(var(--space-unit) * 2);
|
|
68
|
+
}
|
|
69
|
+
:host > .container > .files-container > z-divider {
|
|
70
|
+
margin-top: calc(var(--space-unit) * 3);
|
|
71
|
+
margin-bottom: 0;
|
|
72
|
+
}
|
|
73
|
+
|
|
74
|
+
/* Tablet breakpoint */
|
|
75
|
+
@media only screen and (min-width: 768px) {
|
|
76
|
+
:host > .container > z-button {
|
|
77
|
+
align-self: flex-start;
|
|
78
|
+
}
|
|
79
|
+
}
|
|
80
|
+
|
|
81
|
+
/* Desktop breakpoint */
|
|
82
|
+
@media only screen and (min-width: 1152px) {
|
|
83
|
+
}
|
|
84
|
+
|
|
85
|
+
/* Wide breakpoint */
|
|
86
|
+
@media only screen and (min-width: 1366px) {
|
|
87
|
+
}
|
|
@@ -142,8 +142,8 @@ export class ZMenu {
|
|
|
142
142
|
"optional": true,
|
|
143
143
|
"docs": {
|
|
144
144
|
"tags": [{
|
|
145
|
-
"
|
|
146
|
-
"
|
|
145
|
+
"name": "default",
|
|
146
|
+
"text": "false"
|
|
147
147
|
}],
|
|
148
148
|
"text": "Flag to set the display mode of the list.\nIf true, the list will be absolutely positioned under the menu label,\nstacked beneath it otherwise."
|
|
149
149
|
},
|
|
@@ -163,8 +163,8 @@ export class ZMenu {
|
|
|
163
163
|
"optional": false,
|
|
164
164
|
"docs": {
|
|
165
165
|
"tags": [{
|
|
166
|
-
"
|
|
167
|
-
"
|
|
166
|
+
"name": "default",
|
|
167
|
+
"text": "false"
|
|
168
168
|
}],
|
|
169
169
|
"text": "The opening state of the menu."
|
|
170
170
|
},
|
|
@@ -69,7 +69,7 @@ export function convertJson(data) {
|
|
|
69
69
|
return false;
|
|
70
70
|
}
|
|
71
71
|
}
|
|
72
|
-
const prefix =
|
|
72
|
+
const prefix = "avatar-C"; // prefix for color vars name
|
|
73
73
|
const colorsCount = 19; // available colors
|
|
74
74
|
export function colorFromId(id) {
|
|
75
75
|
const seed = Math.ceil(2 ** 31 - 1) * parseFloat(`0.${id}`);
|
|
@@ -78,5 +78,5 @@ export function colorFromId(id) {
|
|
|
78
78
|
// es.: 3895229
|
|
79
79
|
if (color === 0)
|
|
80
80
|
color = 1;
|
|
81
|
-
return `${prefix}${color.toString().padStart(2,
|
|
81
|
+
return `${prefix}${color.toString().padStart(2, "0")}`;
|
|
82
82
|
}
|