@paperless/core 1.7.0 → 1.7.1
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 +8 -0
- package/dist/build/p-0dc4498e.entry.js +2 -0
- package/dist/build/{p-6e770f95.entry.js.map → p-0dc4498e.entry.js.map} +1 -1
- package/dist/build/p-19205ad5.entry.js +2 -0
- package/dist/build/{p-4843a674.entry.js.map → p-19205ad5.entry.js.map} +1 -1
- package/dist/build/{p-91725831.entry.js → p-25088aea.entry.js} +2 -2
- package/dist/build/{p-91725831.entry.js.map → p-25088aea.entry.js.map} +1 -1
- package/dist/{paperless/p-bb1b6eaa.entry.js → build/p-28b62c4d.entry.js} +2 -2
- package/dist/{paperless/p-bb1b6eaa.entry.js.map → build/p-28b62c4d.entry.js.map} +1 -1
- package/dist/build/p-2a335b81.entry.js +2 -0
- package/dist/{paperless/p-754a5754.entry.js → build/p-2b42b43c.entry.js} +2 -2
- package/dist/build/{p-754a5754.entry.js.map → p-2b42b43c.entry.js.map} +1 -1
- package/dist/{paperless/p-fec204f5.entry.js → build/p-3b353af9.entry.js} +2 -2
- package/dist/build/{p-fec204f5.entry.js.map → p-3b353af9.entry.js.map} +1 -1
- package/dist/{paperless/p-3e1a1224.entry.js → build/p-4dab92ff.entry.js} +2 -2
- package/dist/build/{p-3e1a1224.entry.js.map → p-4dab92ff.entry.js.map} +1 -1
- package/dist/build/{p-30d8c6c4.entry.js → p-6cb21186.entry.js} +2 -2
- package/dist/build/p-72cf864b.entry.js +2 -0
- package/dist/build/{p-bf0eca4f.entry.js → p-72ff59de.entry.js} +2 -2
- package/dist/build/{p-bf0eca4f.entry.js.map → p-72ff59de.entry.js.map} +1 -1
- package/dist/build/p-8332fd7e.entry.js +2 -0
- package/dist/build/{p-5cea1812.entry.js.map → p-8332fd7e.entry.js.map} +1 -1
- package/dist/build/{p-0623f15c.entry.js → p-83bf371c.entry.js} +2 -2
- package/dist/{paperless/p-0623f15c.entry.js.map → build/p-83bf371c.entry.js.map} +1 -1
- package/dist/build/p-a6605507.entry.js +2 -0
- package/dist/{paperless/p-e17560e6.entry.js → build/p-b11dc053.entry.js} +2 -2
- package/dist/build/p-bc89052d.entry.js +2 -0
- package/dist/build/{p-ef36e4dd.entry.js.map → p-bc89052d.entry.js.map} +1 -1
- package/dist/build/p-bcb7d830.entry.js +2 -0
- package/dist/{paperless/p-0e93e831.entry.js → build/p-c4d339a1.entry.js} +2 -2
- package/dist/build/p-d183778e.entry.js +2 -0
- package/dist/{paperless/p-f8828647.entry.js.map → build/p-d183778e.entry.js.map} +1 -1
- package/dist/build/p-d62a0bdf.entry.js +2 -0
- package/dist/build/{p-a989471d.entry.js.map → p-d62a0bdf.entry.js.map} +1 -1
- package/dist/build/p-dc62a55f.entry.js +2 -0
- package/dist/{paperless/p-77a58f71.entry.js.map → build/p-dc62a55f.entry.js.map} +1 -1
- package/dist/build/p-e24dd9f5.entry.js +2 -0
- package/dist/build/{p-b2a3c70f.entry.js.map → p-e24dd9f5.entry.js.map} +1 -1
- package/dist/{paperless/p-62ce84bc.entry.js → build/p-e32689a6.entry.js} +2 -2
- package/dist/{paperless/p-62ce84bc.entry.js.map → build/p-e32689a6.entry.js.map} +1 -1
- package/dist/build/p-e54b9e91.entry.js +2 -0
- package/dist/build/{p-cc901b45.entry.js.map → p-e54b9e91.entry.js.map} +1 -1
- package/dist/build/{p-ce443f5b.entry.js → p-fe4547bd.entry.js} +2 -2
- package/dist/build/paperless.esm.js +1 -1
- package/dist/cjs/p-accordion.cjs.entry.js +1 -1
- package/dist/cjs/p-accordion.cjs.entry.js.map +1 -1
- package/dist/cjs/p-attachment.cjs.entry.js +1 -1
- package/dist/cjs/p-attachment.cjs.entry.js.map +1 -1
- package/dist/cjs/p-backdrop.cjs.entry.js +1 -1
- package/dist/cjs/p-button_3.cjs.entry.js +3 -3
- package/dist/cjs/p-button_3.cjs.entry.js.map +1 -1
- package/dist/cjs/p-calendar.cjs.entry.js +1 -1
- package/dist/cjs/p-card-body.cjs.entry.js +1 -1
- package/dist/cjs/p-card-body.cjs.entry.js.map +1 -1
- package/dist/cjs/p-card-container.cjs.entry.js +1 -1
- package/dist/cjs/p-card-container.cjs.entry.js.map +1 -1
- package/dist/cjs/p-datepicker.cjs.entry.js +1 -1
- package/dist/cjs/p-datepicker.cjs.entry.js.map +1 -1
- package/dist/cjs/p-divider.cjs.entry.js +1 -1
- package/dist/cjs/p-divider.cjs.entry.js.map +1 -1
- package/dist/cjs/p-drawer-body_3.cjs.entry.js +3 -3
- package/dist/cjs/p-drawer.cjs.entry.js +1 -1
- package/dist/cjs/p-dropdown-menu-container.cjs.entry.js +1 -1
- package/dist/cjs/p-dropdown-menu-container.cjs.entry.js.map +1 -1
- package/dist/cjs/p-dropdown_2.cjs.entry.js +2 -2
- package/dist/cjs/p-dropdown_2.cjs.entry.js.map +1 -1
- package/dist/cjs/p-helper_3.cjs.entry.js +2 -2
- package/dist/cjs/p-helper_3.cjs.entry.js.map +1 -1
- package/dist/cjs/p-illustration_6.cjs.entry.js +5 -5
- package/dist/cjs/p-illustration_6.cjs.entry.js.map +1 -1
- package/dist/cjs/p-label_3.cjs.entry.js +3 -3
- package/dist/cjs/p-label_3.cjs.entry.js.map +1 -1
- package/dist/cjs/p-modal-body_4.cjs.entry.js +4 -4
- package/dist/cjs/p-navbar.cjs.entry.js +1 -1
- package/dist/cjs/p-page-size-select_3.cjs.entry.js +2 -2
- package/dist/cjs/p-page-size-select_3.cjs.entry.js.map +1 -1
- package/dist/cjs/p-profile.cjs.entry.js +1 -1
- package/dist/cjs/p-select.cjs.entry.js +1 -1
- package/dist/cjs/p-select.cjs.entry.js.map +1 -1
- package/dist/cjs/p-slider-indicator.cjs.entry.js +1 -1
- package/dist/cjs/p-table.cjs.entry.js +1 -1
- package/dist/cjs/p-table.cjs.entry.js.map +1 -1
- package/dist/cjs/p-toast.cjs.entry.js +1 -1
- package/dist/cjs/p-toast.cjs.entry.js.map +1 -1
- package/dist/cjs/p-tooltip.cjs.entry.js +1 -1
- package/dist/cjs/p-tooltip.cjs.entry.js.map +1 -1
- package/dist/collection/components/atoms/backdrop/backdrop.component.css +1 -1
- package/dist/collection/components/atoms/button/button.component.css +1 -1
- package/dist/collection/components/atoms/card-body/card-body.component.css +1 -1
- package/dist/collection/components/atoms/card-container/card-container.component.css +1 -1
- package/dist/collection/components/atoms/divider/divider.component.css +1 -1
- package/dist/collection/components/atoms/drawer-body/drawer-body.component.css +1 -1
- package/dist/collection/components/atoms/drawer-container/drawer-container.component.css +1 -1
- package/dist/collection/components/atoms/drawer-header/drawer-header.component.css +1 -1
- package/dist/collection/components/atoms/dropdown-menu-container/dropdown-menu-container.component.css +1 -1
- package/dist/collection/components/atoms/dropdown-menu-item/dropdown-menu-item.component.css +1 -1
- package/dist/collection/components/atoms/helper/helper.component.css +1 -1
- package/dist/collection/components/atoms/icon/icon.component.css +1 -1
- package/dist/collection/components/atoms/label/label.component.css +1 -1
- package/dist/collection/components/atoms/loader/loader.component.css +1 -1
- package/dist/collection/components/atoms/modal-body/modal-body.component.css +1 -1
- package/dist/collection/components/atoms/modal-container/modal-container.component.css +1 -1
- package/dist/collection/components/atoms/modal-footer/modal-footer.component.css +1 -1
- package/dist/collection/components/atoms/modal-header/modal-header.component.css +1 -1
- package/dist/collection/components/atoms/pagination-item/pagination-item.component.css +1 -1
- package/dist/collection/components/atoms/segment-container/segment-container.component.css +1 -1
- package/dist/collection/components/atoms/segment-item/segment-item.component.css +1 -1
- package/dist/collection/components/atoms/slider-indicator/slider-indicator.component.css +1 -1
- package/dist/collection/components/atoms/table-container/table-container.component.css +1 -1
- package/dist/collection/components/atoms/tooltip/tooltip.component.css +1 -1
- package/dist/collection/components/molecules/accordion/accordion.component.css +1 -1
- package/dist/collection/components/molecules/attachment/attachment.component.css +1 -1
- package/dist/collection/components/molecules/calendar/calendar.component.css +1 -1
- package/dist/collection/components/molecules/datepicker/datepicker.component.css +1 -1
- package/dist/collection/components/molecules/dropdown/dropdown.component.css +1 -1
- package/dist/collection/components/molecules/input-group/input-group.component.css +1 -1
- package/dist/collection/components/molecules/pagination/pagination.component.css +1 -1
- package/dist/collection/components/molecules/profile/profile.component.css +1 -1
- package/dist/collection/components/molecules/select/select.component.css +1 -1
- package/dist/collection/components/molecules/table-cell/table-cell.component.css +1 -1
- package/dist/collection/components/molecules/table-footer/table-footer.component.css +1 -1
- package/dist/collection/components/molecules/table-header/table-header.component.css +1 -1
- package/dist/collection/components/molecules/table-row/table-row.component.css +1 -1
- package/dist/collection/components/molecules/toast/toast.component.css +1 -1
- package/dist/collection/components/organisms/drawer/drawer.component.css +1 -1
- package/dist/collection/components/organisms/navbar/navbar.component.css +1 -1
- package/dist/collection/components/organisms/table/table.component.css +1 -1
- package/dist/components/backdrop.component.js +1 -1
- package/dist/components/button.component.js +1 -1
- package/dist/components/button.component.js.map +1 -1
- package/dist/components/calendar.component.js +1 -1
- package/dist/components/divider.component.js +1 -1
- package/dist/components/divider.component.js.map +1 -1
- package/dist/components/drawer-body.component.js +1 -1
- package/dist/components/drawer-container.component.js +1 -1
- package/dist/components/drawer-header.component.js +1 -1
- package/dist/components/dropdown-menu-container.component.js +1 -1
- package/dist/components/dropdown-menu-container.component.js.map +1 -1
- package/dist/components/dropdown-menu-item.component.js +1 -1
- package/dist/components/dropdown-menu-item.component.js.map +1 -1
- package/dist/components/dropdown.component.js +1 -1
- package/dist/components/dropdown.component.js.map +1 -1
- package/dist/components/helper.component.js +1 -1
- package/dist/components/helper.component.js.map +1 -1
- package/dist/components/icon.component.js +1 -1
- package/dist/components/icon.component.js.map +1 -1
- package/dist/components/input-group.component.js +1 -1
- package/dist/components/input-group.component.js.map +1 -1
- package/dist/components/label.component.js +1 -1
- package/dist/components/label.component.js.map +1 -1
- package/dist/components/loader.component.js +1 -1
- package/dist/components/loader.component.js.map +1 -1
- package/dist/components/modal-body.component.js +1 -1
- package/dist/components/modal-container.component.js +1 -1
- package/dist/components/modal-footer.component.js +1 -1
- package/dist/components/modal-header.component.js +1 -1
- package/dist/components/p-accordion.js +1 -1
- package/dist/components/p-accordion.js.map +1 -1
- package/dist/components/p-attachment.js +1 -1
- package/dist/components/p-attachment.js.map +1 -1
- package/dist/components/p-card-body.js +1 -1
- package/dist/components/p-card-body.js.map +1 -1
- package/dist/components/p-card-container.js +1 -1
- package/dist/components/p-card-container.js.map +1 -1
- package/dist/components/p-datepicker.js +1 -1
- package/dist/components/p-datepicker.js.map +1 -1
- package/dist/components/p-drawer.js +1 -1
- package/dist/components/p-navbar.js +1 -1
- package/dist/components/p-profile.js +1 -1
- package/dist/components/p-select.js +1 -1
- package/dist/components/p-select.js.map +1 -1
- package/dist/components/p-table.js +1 -1
- package/dist/components/p-table.js.map +1 -1
- package/dist/components/p-toast.js +1 -1
- package/dist/components/p-toast.js.map +1 -1
- package/dist/components/pagination-item.component.js +1 -1
- package/dist/components/pagination-item.component.js.map +1 -1
- package/dist/components/pagination.component.js +1 -1
- package/dist/components/pagination.component.js.map +1 -1
- package/dist/components/segment-container.component.js +1 -1
- package/dist/components/segment-container.component.js.map +1 -1
- package/dist/components/segment-item.component.js +1 -1
- package/dist/components/segment-item.component.js.map +1 -1
- package/dist/components/slider-indicator.component.js +1 -1
- package/dist/components/table-cell.component.js +1 -1
- package/dist/components/table-cell.component.js.map +1 -1
- package/dist/components/table-container.component.js +1 -1
- package/dist/components/table-container.component.js.map +1 -1
- package/dist/components/table-footer.component.js +1 -1
- package/dist/components/table-footer.component.js.map +1 -1
- package/dist/components/table-header.component.js +1 -1
- package/dist/components/table-header.component.js.map +1 -1
- package/dist/components/table-row.component.js +1 -1
- package/dist/components/table-row.component.js.map +1 -1
- package/dist/components/tooltip.component.js +1 -1
- package/dist/components/tooltip.component.js.map +1 -1
- package/dist/esm/p-accordion.entry.js +1 -1
- package/dist/esm/p-accordion.entry.js.map +1 -1
- package/dist/esm/p-attachment.entry.js +1 -1
- package/dist/esm/p-attachment.entry.js.map +1 -1
- package/dist/esm/p-backdrop.entry.js +1 -1
- package/dist/esm/p-button_3.entry.js +3 -3
- package/dist/esm/p-button_3.entry.js.map +1 -1
- package/dist/esm/p-calendar.entry.js +1 -1
- package/dist/esm/p-card-body.entry.js +1 -1
- package/dist/esm/p-card-body.entry.js.map +1 -1
- package/dist/esm/p-card-container.entry.js +1 -1
- package/dist/esm/p-card-container.entry.js.map +1 -1
- package/dist/esm/p-datepicker.entry.js +1 -1
- package/dist/esm/p-datepicker.entry.js.map +1 -1
- package/dist/esm/p-divider.entry.js +1 -1
- package/dist/esm/p-divider.entry.js.map +1 -1
- package/dist/esm/p-drawer-body_3.entry.js +3 -3
- package/dist/esm/p-drawer.entry.js +1 -1
- package/dist/esm/p-dropdown-menu-container.entry.js +1 -1
- package/dist/esm/p-dropdown-menu-container.entry.js.map +1 -1
- package/dist/esm/p-dropdown_2.entry.js +2 -2
- package/dist/esm/p-dropdown_2.entry.js.map +1 -1
- package/dist/esm/p-helper_3.entry.js +2 -2
- package/dist/esm/p-helper_3.entry.js.map +1 -1
- package/dist/esm/p-illustration_6.entry.js +5 -5
- package/dist/esm/p-illustration_6.entry.js.map +1 -1
- package/dist/esm/p-label_3.entry.js +3 -3
- package/dist/esm/p-label_3.entry.js.map +1 -1
- package/dist/esm/p-modal-body_4.entry.js +4 -4
- package/dist/esm/p-navbar.entry.js +1 -1
- package/dist/esm/p-page-size-select_3.entry.js +2 -2
- package/dist/esm/p-page-size-select_3.entry.js.map +1 -1
- package/dist/esm/p-profile.entry.js +1 -1
- package/dist/esm/p-select.entry.js +1 -1
- package/dist/esm/p-select.entry.js.map +1 -1
- package/dist/esm/p-slider-indicator.entry.js +1 -1
- package/dist/esm/p-table.entry.js +1 -1
- package/dist/esm/p-table.entry.js.map +1 -1
- package/dist/esm/p-toast.entry.js +1 -1
- package/dist/esm/p-toast.entry.js.map +1 -1
- package/dist/esm/p-tooltip.entry.js +1 -1
- package/dist/esm/p-tooltip.entry.js.map +1 -1
- package/dist/index.html +1 -1
- package/dist/paperless/p-0dc4498e.entry.js +2 -0
- package/dist/paperless/{p-6e770f95.entry.js.map → p-0dc4498e.entry.js.map} +1 -1
- package/dist/paperless/p-19205ad5.entry.js +2 -0
- package/dist/paperless/{p-4843a674.entry.js.map → p-19205ad5.entry.js.map} +1 -1
- package/dist/paperless/{p-91725831.entry.js → p-25088aea.entry.js} +2 -2
- package/dist/paperless/{p-91725831.entry.js.map → p-25088aea.entry.js.map} +1 -1
- package/dist/{build/p-bb1b6eaa.entry.js → paperless/p-28b62c4d.entry.js} +2 -2
- package/dist/{build/p-bb1b6eaa.entry.js.map → paperless/p-28b62c4d.entry.js.map} +1 -1
- package/dist/paperless/p-2a335b81.entry.js +2 -0
- package/dist/{build/p-754a5754.entry.js → paperless/p-2b42b43c.entry.js} +2 -2
- package/dist/paperless/{p-754a5754.entry.js.map → p-2b42b43c.entry.js.map} +1 -1
- package/dist/{build/p-fec204f5.entry.js → paperless/p-3b353af9.entry.js} +2 -2
- package/dist/paperless/{p-fec204f5.entry.js.map → p-3b353af9.entry.js.map} +1 -1
- package/dist/{build/p-3e1a1224.entry.js → paperless/p-4dab92ff.entry.js} +2 -2
- package/dist/paperless/{p-3e1a1224.entry.js.map → p-4dab92ff.entry.js.map} +1 -1
- package/dist/paperless/{p-30d8c6c4.entry.js → p-6cb21186.entry.js} +2 -2
- package/dist/paperless/p-72cf864b.entry.js +2 -0
- package/dist/paperless/{p-bf0eca4f.entry.js → p-72ff59de.entry.js} +2 -2
- package/dist/paperless/{p-bf0eca4f.entry.js.map → p-72ff59de.entry.js.map} +1 -1
- package/dist/paperless/p-8332fd7e.entry.js +2 -0
- package/dist/paperless/{p-5cea1812.entry.js.map → p-8332fd7e.entry.js.map} +1 -1
- package/dist/paperless/{p-0623f15c.entry.js → p-83bf371c.entry.js} +2 -2
- package/dist/{build/p-0623f15c.entry.js.map → paperless/p-83bf371c.entry.js.map} +1 -1
- package/dist/paperless/p-a6605507.entry.js +2 -0
- package/dist/{build/p-e17560e6.entry.js → paperless/p-b11dc053.entry.js} +2 -2
- package/dist/paperless/p-bc89052d.entry.js +2 -0
- package/dist/paperless/{p-ef36e4dd.entry.js.map → p-bc89052d.entry.js.map} +1 -1
- package/dist/paperless/p-bcb7d830.entry.js +2 -0
- package/dist/{build/p-0e93e831.entry.js → paperless/p-c4d339a1.entry.js} +2 -2
- package/dist/paperless/p-d183778e.entry.js +2 -0
- package/dist/{build/p-f8828647.entry.js.map → paperless/p-d183778e.entry.js.map} +1 -1
- package/dist/paperless/p-d62a0bdf.entry.js +2 -0
- package/dist/paperless/{p-a989471d.entry.js.map → p-d62a0bdf.entry.js.map} +1 -1
- package/dist/paperless/p-dc62a55f.entry.js +2 -0
- package/dist/{build/p-77a58f71.entry.js.map → paperless/p-dc62a55f.entry.js.map} +1 -1
- package/dist/paperless/p-e24dd9f5.entry.js +2 -0
- package/dist/paperless/{p-b2a3c70f.entry.js.map → p-e24dd9f5.entry.js.map} +1 -1
- package/dist/{build/p-62ce84bc.entry.js → paperless/p-e32689a6.entry.js} +2 -2
- package/dist/{build/p-62ce84bc.entry.js.map → paperless/p-e32689a6.entry.js.map} +1 -1
- package/dist/paperless/p-e54b9e91.entry.js +2 -0
- package/dist/paperless/{p-cc901b45.entry.js.map → p-e54b9e91.entry.js.map} +1 -1
- package/dist/paperless/{p-ce443f5b.entry.js → p-fe4547bd.entry.js} +2 -2
- package/dist/paperless/paperless.esm.js +1 -1
- package/dist/sw.js +1 -1
- package/dist/sw.js.map +1 -1
- package/hydrate/index.js +41 -41
- package/package.json +2 -2
- package/dist/build/p-231959ae.entry.js +0 -2
- package/dist/build/p-3774ce4c.entry.js +0 -2
- package/dist/build/p-4843a674.entry.js +0 -2
- package/dist/build/p-5cea1812.entry.js +0 -2
- package/dist/build/p-6a30c500.entry.js +0 -2
- package/dist/build/p-6e770f95.entry.js +0 -2
- package/dist/build/p-77a58f71.entry.js +0 -2
- package/dist/build/p-7caa2463.entry.js +0 -2
- package/dist/build/p-a989471d.entry.js +0 -2
- package/dist/build/p-b2a3c70f.entry.js +0 -2
- package/dist/build/p-cc901b45.entry.js +0 -2
- package/dist/build/p-ef36e4dd.entry.js +0 -2
- package/dist/build/p-f8828647.entry.js +0 -2
- package/dist/paperless/p-231959ae.entry.js +0 -2
- package/dist/paperless/p-3774ce4c.entry.js +0 -2
- package/dist/paperless/p-4843a674.entry.js +0 -2
- package/dist/paperless/p-5cea1812.entry.js +0 -2
- package/dist/paperless/p-6a30c500.entry.js +0 -2
- package/dist/paperless/p-6e770f95.entry.js +0 -2
- package/dist/paperless/p-77a58f71.entry.js +0 -2
- package/dist/paperless/p-7caa2463.entry.js +0 -2
- package/dist/paperless/p-a989471d.entry.js +0 -2
- package/dist/paperless/p-b2a3c70f.entry.js +0 -2
- package/dist/paperless/p-cc901b45.entry.js +0 -2
- package/dist/paperless/p-ef36e4dd.entry.js +0 -2
- package/dist/paperless/p-f8828647.entry.js +0 -2
- /package/dist/build/{p-7caa2463.entry.js.map → p-2a335b81.entry.js.map} +0 -0
- /package/dist/build/{p-30d8c6c4.entry.js.map → p-6cb21186.entry.js.map} +0 -0
- /package/dist/build/{p-3774ce4c.entry.js.map → p-72cf864b.entry.js.map} +0 -0
- /package/dist/build/{p-231959ae.entry.js.map → p-a6605507.entry.js.map} +0 -0
- /package/dist/build/{p-e17560e6.entry.js.map → p-b11dc053.entry.js.map} +0 -0
- /package/dist/build/{p-6a30c500.entry.js.map → p-bcb7d830.entry.js.map} +0 -0
- /package/dist/build/{p-0e93e831.entry.js.map → p-c4d339a1.entry.js.map} +0 -0
- /package/dist/build/{p-ce443f5b.entry.js.map → p-fe4547bd.entry.js.map} +0 -0
- /package/dist/paperless/{p-7caa2463.entry.js.map → p-2a335b81.entry.js.map} +0 -0
- /package/dist/paperless/{p-30d8c6c4.entry.js.map → p-6cb21186.entry.js.map} +0 -0
- /package/dist/paperless/{p-3774ce4c.entry.js.map → p-72cf864b.entry.js.map} +0 -0
- /package/dist/paperless/{p-231959ae.entry.js.map → p-a6605507.entry.js.map} +0 -0
- /package/dist/paperless/{p-e17560e6.entry.js.map → p-b11dc053.entry.js.map} +0 -0
- /package/dist/paperless/{p-6a30c500.entry.js.map → p-bcb7d830.entry.js.map} +0 -0
- /package/dist/paperless/{p-0e93e831.entry.js.map → p-c4d339a1.entry.js.map} +0 -0
- /package/dist/paperless/{p-ce443f5b.entry.js.map → p-fe4547bd.entry.js.map} +0 -0
|
@@ -1 +1 @@
|
|
|
1
|
-
{"file":"p-page-size-select.p-pagination.p-pagination-item.entry.js","mappings":";;;;MAuBa,cAAc;;;;IACf,2BAAsB,GAAiB,CAAC,IAAI,KAChD,iBAAiB,CAAC,IAAI,CAAC,QAAQ,CAAC,IAAI,EAAE,EAAE,IAAI,EAAE,CAAC,CAAC;IAC5C,yBAAoB,GAAiB,CAAC,IAAI,KAC9C,iBAAiB,CAAC,IAAI,CAAC,QAAQ,CAAC,IAAI,EAAE,EAAE,IAAI,EAAE,CAAC,CAAC;gBAIG,WAAW;uBAKlC,kBAAkB;2BAYP,OAAO;sBAKT,OAAO;0BAKT,IAAI,CAAC,sBAAsB;wBAK7B,IAAI,CAAC,oBAAoB;kBAUpC,KAAK;oBAKE,EAAE;;EAEnC,iBAAiB;IACb,IAAI,CAAC,WAAW,EAAE,CAAC;GACtB;EAED,MAAM;IACF,QACI,EAAC,IAAI,IAAC,KAAK,EAAE,sBAAsB,IAAI,CAAC,MAAM,IAAI,QAAQ,EAAE,IACxD,kBACI,SAAS,EAAC,WAAW,EACrB,eAAe,EAAE,IAAI,CAAC,eAAe,EACrC,gBAAgB,EAAC,MAAM,IAEvB,gBACI,OAAO,EAAC,WAAW,EACnB,IAAI,EAAC,SAAS,EACd,IAAI,EAAE,IAAI,CAAC,UAAU,IAEpB,IAAI,CAAC,cAAc;QACd,IAAI,CAAC,cAAc,CAAC,IAAI,CAAC,IAAI,CAAC;QAC9B,IAAI,CAAC,sBAAsB,CAAC,IAAI,CAAC,IAAI,CAAC,CACrC,EACX,YAAM,IAAI,EAAC,OA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AC,IAAI,CAAC,MAAM,CAAC,MAAM,CAAC,CAAC;KACxC;GACJ;EAEO,WAAW,CAAC,CAAU;IAC1B,IAAI,CAAC,CAAC,EAAE;MACJ,OAAO;KACV;IAED,IAAI,CAAC,IAAI,GAAG,CAAC,CAAC;IACd,IAAI,CAAC,UAAU,CAAC,IAAI,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;GACnC;EAEO,cAAc;IAClB,MAAM,YAAY,GAAG,IAAI,CAAC,IAAI,GAAG,CAAC,CAAC;IACnC,IAAI,YAAY,GAAG,IAAI,CAAC,MAAM,CAAC,CAAC,CAAC,EAAE;MAC/B,OAAO;KACV;IAED,IAAI,CAAC,WAAW,CAAC,YAAY,CAAC,CAAC;GAClC;EAaO,cAAc;IAClB,IAAI,CAAC,IAAI,CAAC,KAAK,IAAI,CAAC,IAAI,CAAC,QAAQ,EAAE;MAC/B,OAAO,EAAE,CAAC;KACb;IAED,MAAM,KAAK,GAAG,IAAI,CAAC,IAAI,CAAC,IAAI,CAAC,KAAK,GAAG,IAAI,CAAC,QAAQ,CAAC,CAAC;IACpD,OAAO,IAAI,KAAK,CAAC,KAAK,CAAC,CAAC,IAAI,CAAC,SAAS,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC,EAAE,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC,CAAC;GAChE;;;;;;;;;ACjJL,MAAM,0BAA0B,GAAG,+vWAA+vW;;MCOrxW,cAAc;;;kBAIC,KAAK;;EAE/B,MAAM;IACJ,QACE,EAAC,IAAI,IAAC,KAAK,EAAE,qBAAqB,IAAI,CAAC,MAAM,IAAI,QAAQ,EAAE,IACzD,eAAQ,CACH,EACP;GACH;;;;;;","names":[],"sources":["./src/components/molecules/page-size-select/page-size-select.component.tsx","./src/components/molecules/pagination/pagination.component.scss?tag=p-pagination","./src/components/molecules/pagination/pagination.component.tsx","./src/components/atoms/pagination-item/pagination-item.component.scss?tag=p-pagination-item&encapsulation=shadow","./src/components/atoms/pagination-item/pagination-item.component.tsx"],"sourcesContent":["import {\n Component,\n Element,\n Event,\n EventEmitter,\n h,\n Host,\n Listen,\n Prop,\n State\n} from '@stencil/core';\nimport {\n formatTranslation,\n getLocaleComponentStrings\n} from '../../../utils/localization';\nimport { defaultSize, defaultSizeOptions } from './constants';\n\nexport type templateFunc = (value: number) => string;\n\n@Component({\n tag: 'p-page-size-select',\n shadow: true,\n})\nexport class PageSizeSelect {\n private _defaultButtonTemplate: templateFunc = (size) =>\n formatTranslation(this._locales.item, { size });\n private _defaultItemTemplate: templateFunc = (size) =>\n formatTranslation(this._locales.item, { size });\n /**\n * The current page\n */\n @Prop({ mutable: true, reflect: true }) size: number = defaultSize;\n\n /**\n * The available sizes\n */\n @Prop() sizeOptions: number[] = defaultSizeOptions;\n\n /**\n * Event whenever the size changes\n */\n @Event({\n bubbles: false\n }) sizeChange: EventEmitter<number>;\n\n /**\n * Chevron position\n */\n @Prop() chevronPosition: 'start' | 'end' = 'start';\n\n /**\n * The size of the button\n */\n @Prop() buttonSize: 'small' | 'medium' = 'small';\n\n /**\n * The template for the data view\n */\n @Prop() buttonTemplate: templateFunc = this._defaultButtonTemplate;\n\n /**\n * The template for the data view\n */\n @Prop() itemTemplate: templateFunc = this._defaultItemTemplate;\n\n /**\n * The host element\n */\n @Element() private _el: HTMLElement;\n\n /**\n * Wether to hide when there is only 1 page available\n */\n @Prop() hidden: boolean = false;\n\n /**\n * Locales used for this component\n */\n @State() private _locales: any = {};\n\n componentWillLoad() {\n this._setLocales();\n }\n\n render() {\n return (\n <Host class={`p-page-size-select ${this.hidden && 'hidden'}`}>\n <p-dropdown\n placement=\"top-start\"\n chevronPosition={this.chevronPosition}\n chevronDirection=\"down\"\n >\n <p-button\n variant=\"secondary\"\n slot=\"trigger\"\n size={this.buttonSize}\n >\n {this.buttonTemplate\n ? this.buttonTemplate(this.size)\n : this._defaultButtonTemplate(this.size)}\n </p-button>\n <slot slot=\"items\">\n {this.sizeOptions.map((option) => (\n <p-dropdown-menu-item\n active={option === this.size}\n onClick={() => this._changeSize(option)}\n >\n {this.itemTemplate\n ? this.itemTemplate(option)\n : this._defaultItemTemplate(option)}\n </p-dropdown-menu-item>\n ))}\n </slot>\n </p-dropdown>\n </Host>\n );\n }\n\n @Listen('localeChanged', { target: 'body' })\n private async _setLocales(): Promise<void> {\n this._locales = await getLocaleComponentStrings(this._el);\n }\n\n private _changeSize(s?: number) {\n if (!s) {\n return;\n }\n\n this.size = s;\n this.sizeChange.emit(this.size);\n }\n}\n","p-pagination {\n @apply flex;\n}\n","import {\n Component,\n Event,\n EventEmitter,\n h,\n Host,\n Prop,\n Watch\n} from '@stencil/core';\n\ntype PaginationSetItem = {\n type: string;\n value?: number | Element | JSX.Element | string;\n};\n\n@Component({\n tag: 'p-pagination',\n styleUrl: 'pagination.component.scss',\n})\nexport class Pagination {\n /**\n * The current page\n */\n @Prop({ mutable: true, reflect: true }) page: number = 1;\n\n /**\n * Event whenever the page changes\n */\n @Event({\n bubbles: false\n }) pageChange: EventEmitter<number>;\n\n /**\n * The amount of items per page\n */\n @Prop() pageSize: number = 12;\n\n /**\n * Wether to hide when there is only 1 page available\n */\n @Prop() hideOnSinglePage: boolean = false;\n\n /**\n * The total amount of items\n */\n @Prop() total!: number;\n\n private _pages: number[] = [];\n private _set: PaginationSetItem[] = [];\n\n componentWillRender() {\n this._generate();\n }\n\n render() {\n return (\n <Host\n class={`p-pagination ${\n this.hideOnSinglePage && this._set?.length === 3 && 'hidden'\n }`}\n >\n {this._set?.map((p) => {\n if (p.type === 'previous' || p.type === 'next') {\n return (\n <p-pagination-item\n onClick={() =>\n p.type === 'previous'\n ? this._previousClick()\n : this._nextClick()\n }\n >\n {p.value}\n </p-pagination-item>\n );\n }\n\n if (p.type === 'ellipsis') {\n return <p-pagination-item>...</p-pagination-item>;\n }\n\n return (\n <p-pagination-item\n active={p.value === this.page}\n onClick={() => this._pageClick(p.value as number)}\n >\n {p.value}\n </p-pagination-item>\n );\n })}\n </Host>\n );\n }\n\n @Watch('page')\n @Watch('pageSize')\n @Watch('total')\n protected pageChangeHandler() {\n this._generate();\n }\n\n private _generate() {\n this._pages = this._generatePages();\n this._set = this._generateSet();\n\n if (this.page > this._pages?.length) {\n this._changePage(this._pages.length);\n }\n }\n\n private _changePage(p?: number) {\n if (!p) {\n return;\n }\n\n this.page = p;\n this.pageChange.emit(this.page);\n }\n\n private _previousClick() {\n const previousPage = this.page - 1;\n if (previousPage < this._pages[0]) {\n return;\n }\n\n this._changePage(previousPage);\n }\n\n private _nextClick = () => {\n const nextPage = this.page + 1;\n if (nextPage > this._pages[this._pages.length - 1]) {\n return;\n }\n\n this._changePage(nextPage);\n };\n\n private _pageClick = (p?: number) => this._changePage(p);\n\n private _generatePages() {\n if (!this.total || !this.pageSize) {\n return [];\n }\n\n const pages = Math.ceil(this.total / this.pageSize);\n return new Array(pages).fill(undefined).map((_, i) => i + 1);\n }\n\n private _generateSet = (\n range: number = 1,\n enableBoundaries: boolean = true\n ): PaginationSetItem[] => {\n const totalPages = this._pages.length;\n\n if (!totalPages) {\n return [];\n }\n\n let start = this.page - range;\n let end = this.page + range;\n\n if (end > totalPages) {\n end = totalPages;\n start = totalPages - range * 2;\n start = start < 1 ? 1 : start;\n }\n\n if (start <= 1) {\n start = 1;\n end = Math.min(range * 2 + 1, totalPages);\n }\n\n const set = [];\n\n const previous = {\n type: 'previous',\n value: <p-icon variant=\"chevron\" rotate={90} />,\n };\n\n const next = {\n type: 'next',\n value: <p-icon variant=\"chevron\" rotate={-90} />,\n };\n\n // Disable page range, display all the pages\n if (range === null) {\n const p = this._pages.map((p) => ({\n type: 'page',\n value: p,\n }));\n\n return enableBoundaries ? [previous, ...p, next] : p;\n }\n\n if (enableBoundaries) {\n set.push(previous);\n }\n\n if (start <= 3) {\n for (let i = 1; i < start; i++) {\n set.push({\n type: 'page',\n value: this._pages[i - 1],\n });\n }\n } else {\n set.push({\n type: 'page',\n value: 1,\n });\n\n set.push({\n type: 'ellipsis',\n value: 'ellipsis',\n });\n }\n\n for (let i = start; i <= end; i++) {\n set.push({\n type: 'page',\n value: this._pages[i - 1],\n });\n }\n\n if (end >= totalPages - 2) {\n for (let i = end + 1; i <= totalPages; i++) {\n set.push({\n type: 'page',\n value: this._pages[i - 1],\n });\n }\n } else {\n set.push({\n type: 'ellipsis',\n });\n\n set.push({\n type: 'page',\n value: this._pages[this._pages.length - 1],\n });\n }\n\n if (enableBoundaries) {\n set.push(next);\n }\n\n return set;\n };\n}\n",":host {\n @apply h-8 w-8;\n @apply flex justify-center items-center;\n @apply font-semibold text-storm-medium text-sm;\n @apply rounded;\n @apply cursor-pointer;\n}\n\n:host(:hover),\n:host(:focus) {\n @apply text-storm;\n}\n\n:host(.active) {\n @apply text-indigo bg-indigo-light;\n}\n","import { Component, h, Host, Prop } from '@stencil/core';\n\n@Component({\n tag: 'p-pagination-item',\n styleUrl: 'pagination-item.component.scss',\n shadow: true,\n})\nexport class PaginationItem {\n /**\n * Wether the pagination item is active\n */\n @Prop() active: boolean = false;\n\n render() {\n return (\n <Host class={`p-pagination-item ${this.active && 'active'}`}>\n <slot />\n </Host>\n );\n }\n}\n"],"version":3}
|
|
1
|
+
{"file":"p-page-size-select.p-pagination.p-pagination-item.entry.js","mappings":";;;;MAuBa,cAAc;;;;IACf,2BAAsB,GAAiB,CAAC,IAAI,KAChD,iBAAiB,CAAC,IAAI,CAAC,QAAQ,CAAC,IAAI,EAAE,EAAE,IAAI,EAAE,CAAC,CAAC;IAC5C,yBAAoB,GAAiB,CAAC,IAAI,KAC9C,iBAAiB,CAAC,IAAI,CAAC,QAAQ,CAAC,IAAI,EAAE,EAAE,IAAI,EAAE,CAAC,CAAC;gBAIG,WAAW;uBAKlC,kBAAkB;2BAYP,OAAO;sBAKT,OAAO;0BAKT,IAAI,CAAC,sBAAsB;wBAK7B,IAAI,CAAC,oBAAoB;kBAUpC,KAAK;oBAKE,EAAE;;EAEnC,iBAAiB;IACb,IAAI,CAAC,WAAW,EAAE,CAAC;GACtB;EAED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,KAAK,CAAC,GAAG,CAAC,CAAC,CAAC;GAChE;;;;;;;;;ACjJL,MAAM,0BAA0B,GAAG,o8WAAo8W;;MCO19W,cAAc;;;kBAIC,KAAK;;EAE/B,MAAM;IACJ,QACE,EAAC,IAAI,IAAC,KAAK,EAAE,qBAAqB,IAAI,CAAC,MAAM,IAAI,QAAQ,EAAE,IACzD,eAAQ,CACH,EACP;GACH;;;;;;","names":[],"sources":["./src/components/molecules/page-size-select/page-size-select.component.tsx","./src/components/molecules/pagination/pagination.component.scss?tag=p-pagination","./src/components/molecules/pagination/pagination.component.tsx","./src/components/atoms/pagination-item/pagination-item.component.scss?tag=p-pagination-item&encapsulation=shadow","./src/components/atoms/pagination-item/pagination-item.component.tsx"],"sourcesContent":["import {\n Component,\n Element,\n Event,\n EventEmitter,\n h,\n Host,\n Listen,\n Prop,\n State\n} from '@stencil/core';\nimport {\n formatTranslation,\n getLocaleComponentStrings\n} from '../../../utils/localization';\nimport { defaultSize, defaultSizeOptions } from './constants';\n\nexport type templateFunc = (value: number) => string;\n\n@Component({\n tag: 'p-page-size-select',\n shadow: true,\n})\nexport class PageSizeSelect {\n private _defaultButtonTemplate: templateFunc = (size) =>\n formatTranslation(this._locales.item, { size });\n private _defaultItemTemplate: templateFunc = (size) =>\n formatTranslation(this._locales.item, { size });\n /**\n * The current page\n */\n @Prop({ mutable: true, reflect: true }) size: number = defaultSize;\n\n /**\n * The available sizes\n */\n @Prop() sizeOptions: number[] = defaultSizeOptions;\n\n /**\n * Event whenever the size changes\n */\n @Event({\n bubbles: false\n }) sizeChange: EventEmitter<number>;\n\n /**\n * Chevron position\n */\n @Prop() chevronPosition: 'start' | 'end' = 'start';\n\n /**\n * The size of the button\n */\n @Prop() buttonSize: 'small' | 'medium' = 'small';\n\n /**\n * The template for the data view\n */\n @Prop() buttonTemplate: templateFunc = this._defaultButtonTemplate;\n\n /**\n * The template for the data view\n */\n @Prop() itemTemplate: templateFunc = this._defaultItemTemplate;\n\n /**\n * The host element\n */\n @Element() private _el: HTMLElement;\n\n /**\n * Wether to hide when there is only 1 page available\n */\n @Prop() hidden: boolean = false;\n\n /**\n * Locales used for this component\n */\n @State() private _locales: any = {};\n\n componentWillLoad() {\n this._setLocales();\n }\n\n render() {\n return (\n <Host class={`p-page-size-select ${this.hidden && 'hidden'}`}>\n <p-dropdown\n placement=\"top-start\"\n chevronPosition={this.chevronPosition}\n chevronDirection=\"down\"\n >\n <p-button\n variant=\"secondary\"\n slot=\"trigger\"\n size={this.buttonSize}\n >\n {this.buttonTemplate\n ? this.buttonTemplate(this.size)\n : this._defaultButtonTemplate(this.size)}\n </p-button>\n <slot slot=\"items\">\n {this.sizeOptions.map((option) => (\n <p-dropdown-menu-item\n active={option === this.size}\n onClick={() => this._changeSize(option)}\n >\n {this.itemTemplate\n ? this.itemTemplate(option)\n : this._defaultItemTemplate(option)}\n </p-dropdown-menu-item>\n ))}\n </slot>\n </p-dropdown>\n </Host>\n );\n }\n\n @Listen('localeChanged', { target: 'body' })\n private async _setLocales(): Promise<void> {\n this._locales = await getLocaleComponentStrings(this._el);\n }\n\n private _changeSize(s?: number) {\n if (!s) {\n return;\n }\n\n this.size = s;\n this.sizeChange.emit(this.size);\n }\n}\n","p-pagination {\n @apply flex;\n}\n","import {\n Component,\n Event,\n EventEmitter,\n h,\n Host,\n Prop,\n Watch\n} from '@stencil/core';\n\ntype PaginationSetItem = {\n type: string;\n value?: number | Element | JSX.Element | string;\n};\n\n@Component({\n tag: 'p-pagination',\n styleUrl: 'pagination.component.scss',\n})\nexport class Pagination {\n /**\n * The current page\n */\n @Prop({ mutable: true, reflect: true }) page: number = 1;\n\n /**\n * Event whenever the page changes\n */\n @Event({\n bubbles: false\n }) pageChange: EventEmitter<number>;\n\n /**\n * The amount of items per page\n */\n @Prop() pageSize: number = 12;\n\n /**\n * Wether to hide when there is only 1 page available\n */\n @Prop() hideOnSinglePage: boolean = false;\n\n /**\n * The total amount of items\n */\n @Prop() total!: number;\n\n private _pages: number[] = [];\n private _set: PaginationSetItem[] = [];\n\n componentWillRender() {\n this._generate();\n }\n\n render() {\n return (\n <Host\n class={`p-pagination ${\n this.hideOnSinglePage && this._set?.length === 3 && 'hidden'\n }`}\n >\n {this._set?.map((p) => {\n if (p.type === 'previous' || p.type === 'next') {\n return (\n <p-pagination-item\n onClick={() =>\n p.type === 'previous'\n ? this._previousClick()\n : this._nextClick()\n }\n >\n {p.value}\n </p-pagination-item>\n );\n }\n\n if (p.type === 'ellipsis') {\n return <p-pagination-item>...</p-pagination-item>;\n }\n\n return (\n <p-pagination-item\n active={p.value === this.page}\n onClick={() => this._pageClick(p.value as number)}\n >\n {p.value}\n </p-pagination-item>\n );\n })}\n </Host>\n );\n }\n\n @Watch('page')\n @Watch('pageSize')\n @Watch('total')\n protected pageChangeHandler() {\n this._generate();\n }\n\n private _generate() {\n this._pages = this._generatePages();\n this._set = this._generateSet();\n\n if (this.page > this._pages?.length) {\n this._changePage(this._pages.length);\n }\n }\n\n private _changePage(p?: number) {\n if (!p) {\n return;\n }\n\n this.page = p;\n this.pageChange.emit(this.page);\n }\n\n private _previousClick() {\n const previousPage = this.page - 1;\n if (previousPage < this._pages[0]) {\n return;\n }\n\n this._changePage(previousPage);\n }\n\n private _nextClick = () => {\n const nextPage = this.page + 1;\n if (nextPage > this._pages[this._pages.length - 1]) {\n return;\n }\n\n this._changePage(nextPage);\n };\n\n private _pageClick = (p?: number) => this._changePage(p);\n\n private _generatePages() {\n if (!this.total || !this.pageSize) {\n return [];\n }\n\n const pages = Math.ceil(this.total / this.pageSize);\n return new Array(pages).fill(undefined).map((_, i) => i + 1);\n }\n\n private _generateSet = (\n range: number = 1,\n enableBoundaries: boolean = true\n ): PaginationSetItem[] => {\n const totalPages = this._pages.length;\n\n if (!totalPages) {\n return [];\n }\n\n let start = this.page - range;\n let end = this.page + range;\n\n if (end > totalPages) {\n end = totalPages;\n start = totalPages - range * 2;\n start = start < 1 ? 1 : start;\n }\n\n if (start <= 1) {\n start = 1;\n end = Math.min(range * 2 + 1, totalPages);\n }\n\n const set = [];\n\n const previous = {\n type: 'previous',\n value: <p-icon variant=\"chevron\" rotate={90} />,\n };\n\n const next = {\n type: 'next',\n value: <p-icon variant=\"chevron\" rotate={-90} />,\n };\n\n // Disable page range, display all the pages\n if (range === null) {\n const p = this._pages.map((p) => ({\n type: 'page',\n value: p,\n }));\n\n return enableBoundaries ? [previous, ...p, next] : p;\n }\n\n if (enableBoundaries) {\n set.push(previous);\n }\n\n if (start <= 3) {\n for (let i = 1; i < start; i++) {\n set.push({\n type: 'page',\n value: this._pages[i - 1],\n });\n }\n } else {\n set.push({\n type: 'page',\n value: 1,\n });\n\n set.push({\n type: 'ellipsis',\n value: 'ellipsis',\n });\n }\n\n for (let i = start; i <= end; i++) {\n set.push({\n type: 'page',\n value: this._pages[i - 1],\n });\n }\n\n if (end >= totalPages - 2) {\n for (let i = end + 1; i <= totalPages; i++) {\n set.push({\n type: 'page',\n value: this._pages[i - 1],\n });\n }\n } else {\n set.push({\n type: 'ellipsis',\n });\n\n set.push({\n type: 'page',\n value: this._pages[this._pages.length - 1],\n });\n }\n\n if (enableBoundaries) {\n set.push(next);\n }\n\n return set;\n };\n}\n",":host {\n @apply h-8 w-8;\n @apply flex justify-center items-center;\n @apply font-semibold text-storm-medium text-sm;\n @apply rounded;\n @apply cursor-pointer;\n}\n\n:host(:hover),\n:host(:focus) {\n @apply text-storm;\n}\n\n:host(.active) {\n @apply text-indigo bg-indigo-light;\n}\n","import { Component, h, Host, Prop } from '@stencil/core';\n\n@Component({\n tag: 'p-pagination-item',\n styleUrl: 'pagination-item.component.scss',\n shadow: true,\n})\nexport class PaginationItem {\n /**\n * Wether the pagination item is active\n */\n @Prop() active: boolean = false;\n\n render() {\n return (\n <Host class={`p-pagination-item ${this.active && 'active'}`}>\n <slot />\n </Host>\n );\n }\n}\n"],"version":3}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { r as registerInstance, h, H as Host, g as getElement } from './index-2c1bdb40.js';
|
|
2
2
|
|
|
3
|
-
const profileComponentCss = ".flex{display:flex!important}.h-\\[3\\.125rem\\]{height:3.125rem!important}.h-\\[4\\.125rem\\]{height:4.125rem!important}.flex-col{flex-direction:column!important}.items-center{align-items:center!important}.justify-center{justify-content:center!important}.gap-3{gap:.75rem!important}.overflow-hidden{overflow:hidden!important}.text-ellipsis{text-overflow:ellipsis!important}.rounded{border-radius:.25rem!important}.border{border-width:1px!important}.border-solid{border-style:solid!important}.border-mystic-dark{--tw-border-opacity:1!important;border-color:rgb(218 230 240/var(--tw-border-opacity))!important}.p-2{padding:.5rem!important}.text-sm{font-size:.875rem!important;line-height:1.25rem!important}*{box-sizing:border-box}:host{display:flex}:host .content{align-items:center;display:flex;gap:.75rem;width:100%}:host .content .name{display:flex;flex-direction:column;justify-content:center;overflow:hidden}:host .content .name>:first-child{--tw-text-opacity:1;color:rgb(39 40 56/var(--tw-text-opacity));font-size:.875rem;font-weight:600;line-height:1.25rem}:host .content .name>:nth-child(2){--tw-text-opacity:1;color:rgb(152 154 183/var(--tw-text-opacity));font-size:.875rem;line-height:1.25rem}:host .content .name ::slotted(*){overflow:hidden;text-overflow:ellipsis;white-space:nowrap}:host([size=small]){height:2rem}:host([size=medium]){height:3.125rem}:host([size=large]){height:4rem}:host(.has-dropdown){cursor:pointer}:host(.has-dropdown) .content{--tw-border-opacity:1!important;border-color:rgb(218 230 240/var(--tw-border-opacity))!important;border-radius:.25rem;border-style:solid!important;border-width:1px!important;padding:.5rem}:host(.has-dropdown[size=small]){height:3rem}:host(.has-dropdown[size=medium]){height:4.125rem}:host(.has-dropdown[size=large]){height:5rem}:host(.active) .content,:host(.has-dropdown:hover) .content{--tw-shadow:0px 0.3125rem 1rem rgba(0,24,98,.08),0px 0.0625rem 0.1875rem rgba(0,24,98,.13);--tw-shadow-colored:0px 0.3125rem 1rem var(--tw-shadow-color),0px 0.0625rem 0.1875rem var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow,0 0 #0000),var(--tw-ring-shadow,0 0 #0000),var(--tw-shadow)}:host(.active) .content p-icon{--tw-text-opacity:1;color:rgb(82 138 250/var(--tw-text-opacity))}.
|
|
3
|
+
const profileComponentCss = ".flex{display:flex!important}.h-\\[3\\.125rem\\]{height:3.125rem!important}.h-\\[4\\.125rem\\]{height:4.125rem!important}.flex-col{flex-direction:column!important}.items-center{align-items:center!important}.justify-center{justify-content:center!important}.gap-3{gap:.75rem!important}.overflow-hidden{overflow:hidden!important}.text-ellipsis{text-overflow:ellipsis!important}.rounded{border-radius:.25rem!important}.border{border-width:1px!important}.border-solid{border-style:solid!important}.border-mystic-dark{--tw-border-opacity:1!important;border-color:rgb(218 230 240/var(--tw-border-opacity))!important}.p-2{padding:.5rem!important}.text-sm{font-size:.875rem!important;line-height:1.25rem!important}*{box-sizing:border-box}:host{display:flex}:host .content{align-items:center;display:flex;gap:.75rem;width:100%}:host .content .name{display:flex;flex-direction:column;justify-content:center;overflow:hidden}:host .content .name>:first-child{--tw-text-opacity:1;color:rgb(39 40 56/var(--tw-text-opacity));font-size:.875rem;font-weight:600;line-height:1.25rem}:host .content .name>:nth-child(2){--tw-text-opacity:1;color:rgb(152 154 183/var(--tw-text-opacity));font-size:.875rem;line-height:1.25rem}:host .content .name ::slotted(*){overflow:hidden;text-overflow:ellipsis;white-space:nowrap}:host([size=small]){height:2rem}:host([size=medium]){height:3.125rem}:host([size=large]){height:4rem}:host(.has-dropdown){cursor:pointer}:host(.has-dropdown) .content{--tw-border-opacity:1!important;border-color:rgb(218 230 240/var(--tw-border-opacity))!important;border-radius:.25rem;border-style:solid!important;border-width:1px!important;padding:.5rem}:host(.has-dropdown[size=small]){height:3rem}:host(.has-dropdown[size=medium]){height:4.125rem}:host(.has-dropdown[size=large]){height:5rem}:host(.active) .content,:host(.has-dropdown:hover) .content{--tw-shadow:0px 0.3125rem 1rem rgba(0,24,98,.08),0px 0.0625rem 0.1875rem rgba(0,24,98,.13);--tw-shadow-colored:0px 0.3125rem 1rem var(--tw-shadow-color),0px 0.0625rem 0.1875rem var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow,0 0 #0000),var(--tw-ring-shadow,0 0 #0000),var(--tw-shadow)}:host(.active) .content p-icon{--tw-text-opacity:1;color:rgb(82 138 250/var(--tw-text-opacity))}.absolute{position:absolute!important}.ml-auto{margin-left:auto!important}.w-full{width:100%!important}.min-w-0{min-width:0!important}.static{position:static!important}.-rotate-0{--tw-rotate:-0deg!important}.-rotate-0,.-rotate-135{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))!important}.-rotate-135{--tw-rotate:-135deg!important}.-rotate-180{--tw-rotate:-180deg!important}.-rotate-180,.-rotate-225{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))!important}.-rotate-225{--tw-rotate:-225deg!important}.-rotate-25{--tw-rotate:-25deg!important}.-rotate-25,.-rotate-270{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))!important}.-rotate-270{--tw-rotate:-270deg!important}.-rotate-315{--tw-rotate:-315deg!important}.-rotate-315,.-rotate-45{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))!important}.-rotate-45{--tw-rotate:-45deg!important}.-rotate-90{--tw-rotate:-90deg!important}.-rotate-90,.rotate-0{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))!important}.rotate-0{--tw-rotate:0deg!important}.rotate-135{--tw-rotate:135deg!important}.rotate-135,.rotate-180{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))!important}.rotate-180{--tw-rotate:180deg!important}.rotate-225{--tw-rotate:225deg!important}.rotate-225,.rotate-25{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))!important}.rotate-25{--tw-rotate:25deg!important}.rotate-270{--tw-rotate:270deg!important}.rotate-270,.rotate-315{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))!important}.rotate-315{--tw-rotate:315deg!important}.rotate-45{--tw-rotate:45deg!important}.rotate-45,.rotate-90{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))!important}.rotate-90{--tw-rotate:90deg!important}.scale-x-flip{--tw-scale-x:-1!important}.scale-x-flip,.scale-y-flip{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))!important}.scale-y-flip{--tw-scale-y:-1!important}.transform{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))!important}.text-2xl{font-size:1.5rem!important;line-height:2rem!important}.text-3xl{font-size:1.875rem!important;line-height:2.25rem!important}.text-4xl{font-size:2.25rem!important;line-height:2.5rem!important}.text-5xl{font-size:3rem!important}.text-5xl,.text-6xl{line-height:1!important}.text-6xl{font-size:3.75rem!important}.text-base{font-size:1rem!important;line-height:1.5rem!important}.text-lg{font-size:1.125rem!important}.text-lg,.text-xl{line-height:1.75rem!important}.text-xl{font-size:1.25rem!important}.text-xs{font-size:.75rem!important;line-height:1rem!important}.text-xxs{font-size:.6875rem!important}.visible{visibility:visible!important}";
|
|
4
4
|
|
|
5
5
|
const Profile = class {
|
|
6
6
|
constructor(hostRef) {
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { r as registerInstance, c as createEvent, h, H as Host, g as getElement } from './index-2c1bdb40.js';
|
|
2
2
|
import { c as childOf } from './child-of-90a8c4b5.js';
|
|
3
3
|
|
|
4
|
-
const selectComponentCss = ".flex{display:flex!important}.w-full{width:100%!important}*{box-sizing:border-box}p-select{display:flex;flex-direction:column;width:100%}p-select input.read-only{text-overflow:ellipsis}.static{position:static!important}.h-6{height:1.5rem!important}.cursor-pointer{cursor:pointer!important}.rounded{border-radius:.25rem!important}.filter{filter:var(--tw-blur) var(--tw-brightness) var(--tw-contrast) var(--tw-grayscale) var(--tw-hue-rotate) var(--tw-invert) var(--tw-saturate) var(--tw-sepia) var(--tw-drop-shadow)!important}.
|
|
4
|
+
const selectComponentCss = ".flex{display:flex!important}.w-full{width:100%!important}*{box-sizing:border-box}p-select{display:flex;flex-direction:column;width:100%}p-select input.read-only{text-overflow:ellipsis}.static{position:static!important}.h-6{height:1.5rem!important}.cursor-pointer{cursor:pointer!important}.rounded{border-radius:.25rem!important}.filter{filter:var(--tw-blur) var(--tw-brightness) var(--tw-contrast) var(--tw-grayscale) var(--tw-hue-rotate) var(--tw-invert) var(--tw-saturate) var(--tw-sepia) var(--tw-drop-shadow)!important}.-rotate-0{--tw-rotate:-0deg!important}.-rotate-0,.-rotate-135{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))!important}.-rotate-135{--tw-rotate:-135deg!important}.-rotate-180{--tw-rotate:-180deg!important}.-rotate-180,.-rotate-225{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))!important}.-rotate-225{--tw-rotate:-225deg!important}.-rotate-25{--tw-rotate:-25deg!important}.-rotate-25,.-rotate-270{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))!important}.-rotate-270{--tw-rotate:-270deg!important}.-rotate-315{--tw-rotate:-315deg!important}.-rotate-315,.-rotate-45{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))!important}.-rotate-45{--tw-rotate:-45deg!important}.-rotate-90{--tw-rotate:-90deg!important}.-rotate-90,.rotate-0{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))!important}.rotate-0{--tw-rotate:0deg!important}.rotate-135{--tw-rotate:135deg!important}.rotate-135,.rotate-180{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))!important}.rotate-180{--tw-rotate:180deg!important}.rotate-225{--tw-rotate:225deg!important}.rotate-225,.rotate-25{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))!important}.rotate-25{--tw-rotate:25deg!important}.rotate-270{--tw-rotate:270deg!important}.rotate-270,.rotate-315{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))!important}.rotate-315{--tw-rotate:315deg!important}.rotate-45{--tw-rotate:45deg!important}.rotate-45,.rotate-90{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))!important}.rotate-90{--tw-rotate:90deg!important}.scale-x-flip{--tw-scale-x:-1!important}.scale-x-flip,.scale-y-flip{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))!important}.scale-y-flip{--tw-scale-y:-1!important}.transform{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))!important}.text-2xl{font-size:1.5rem!important;line-height:2rem!important}.text-3xl{font-size:1.875rem!important;line-height:2.25rem!important}.text-4xl{font-size:2.25rem!important;line-height:2.5rem!important}.text-5xl{font-size:3rem!important}.text-5xl,.text-6xl{line-height:1!important}.text-6xl{font-size:3.75rem!important}.text-base{font-size:1rem!important;line-height:1.5rem!important}.text-lg{font-size:1.125rem!important;line-height:1.75rem!important}.text-sm{font-size:.875rem!important;line-height:1.25rem!important}.text-xl{font-size:1.25rem!important;line-height:1.75rem!important}.text-xs{font-size:.75rem!important;line-height:1rem!important}.text-xxs{font-size:.6875rem!important}.visible{visibility:visible!important}.absolute{position:absolute!important}.text-negative{--tw-text-opacity:1!important;color:rgb(185 30 40/var(--tw-text-opacity))!important}.text-negative-light{--tw-text-opacity:1!important;color:rgb(255 204 211/var(--tw-text-opacity))!important}.hover\\:text-negative:hover{--tw-text-opacity:1!important;color:rgb(185 30 40/var(--tw-text-opacity))!important}.inline{display:inline!important}.justify-center{justify-content:center!important}.blur{--tw-blur:blur(8px)!important;filter:var(--tw-blur) var(--tw-brightness) var(--tw-contrast) var(--tw-grayscale) var(--tw-hue-rotate) var(--tw-invert) var(--tw-saturate) var(--tw-sepia) var(--tw-drop-shadow)!important}.ml-1{margin-left:.25rem!important}.ml-2{margin-left:.5rem!important}.items-end{align-items:flex-end!important}.justify-between{justify-content:space-between!important}.rounded-bl-none{border-bottom-left-radius:0!important}.rounded-br-none{border-bottom-right-radius:0!important}.rounded-tl-none{border-top-left-radius:0!important}.rounded-tr-none{border-top-right-radius:0!important}.border-l-0{border-left-width:0!important}.border-r-0{border-right-width:0!important}.pl-0{padding-left:0!important}.pr-0{padding-right:0!important}";
|
|
5
5
|
|
|
6
6
|
const Select = class {
|
|
7
7
|
constructor(hostRef) {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"file":"p-select.entry.js","mappings":";;;AAAA,MAAM,kBAAkB,GAAG,mqBAAmqB;;MCoBjrB,MAAM;;;;;;;;;;;;sBAkCc,MAAM;;;;2BAoBA,IAAI;uBAKR,IAAI;6BAKC,EAAE;8BAKA,IAAI;qBAKb,IAAI;uBAKF,KAAK;mBAKT,KAAK;gBA6BG,QAAQ;;;;;;oBA8BE,KAAK;yBAOZ,KAAK;yBACL,IAAI;6BAEI,KAAK;;EAEnD,IAAI,MAAM;;IACN,IAAI,CAAC,IAAI,CAAC,KAAK,IAAI,IAAI,CAAC,OAAO,EAAE;MAC7B,OAAO,EAAE,CAAC;KACb;IA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AAI,CAAC,EAC9C;GACL;EAEO,SAAS;IACb,OAAO,IAAI,CAAC,MAAM,CAAC,GAAG,CAAC,CAAC,IAAI;;MAAK,QAC7B,4BACI,OAAO,EAAE,MAAM,IAAI,CAAC,YAAY,CAAC,IAAI,CAAC,EACtC,MAAM,EACF,IAAI,CAAC,IAAI,CAAC,cAAc,CAAC;WACzB,MAAA,IAAI,CAAC,aAAa,0CAAG,IAAI,CAAC,cAAc,CAAC,CAAA,IAG5C,IAAI,CAAC,IAAI,CAAC,UAAU,CAAC,CACH,EAC1B;KAAA,CAAC,CAAC;GACN;EAEO,gBAAgB;IACpB,OAAO,CAAC,CAAC,EAAE,CAAC,EAAE,CAAC,CAAC,CAAC,GAAG,CAAC,OACjB,4BAAsB,WAAW,EAAE,KAAK,IACpC,gBAAU,OAAO,EAAC,OAAO,EAAC,KAAK,EAAC,oBAAoB,GAAG,CACpC,CAC1B,CAAC,CAAC;GACN;;;;;;;;;;;;","names":[],"sources":["./src/components/molecules/select/select.component.scss?tag=p-select","./src/components/molecules/select/select.component.tsx"],"sourcesContent":["p-select {\n @apply flex w-full flex-col;\n\n input.read-only {\n @apply text-ellipsis;\n }\n}\n","import {\n Component,\n Element,\n Event,\n EventEmitter,\n h,\n Host,\n Listen,\n Prop,\n State,\n Watch,\n} from '@stencil/core';\nimport { childOf } from '../../../utils';\nimport { IconVariant } from '../../atoms/icon/icon.component';\n\n@Component({\n tag: 'p-select',\n styleUrl: 'select.component.scss',\n shadow: false,\n})\nexport class Select {\n /**\n * The items to show in the dropdown\n */\n @Prop() items: string | any[];\n\n /**\n * Icon of the select box\n */\n @Prop() icon: IconVariant;\n\n /**\n * The current query\n */\n @Prop() query: string;\n\n /**\n * The placeholder of the input\n */\n @Prop() placeholder: string;\n\n /**\n * The placeholder of the input when auto completing\n */\n @Prop() autocompletePlaceholder: string;\n\n /**\n * The current value\n */\n @Prop() value: any;\n\n /**\n * The key of the object to display\n */\n @Prop() displayKey: string = 'text';\n\n /**\n * The key of the object to return\n */\n @Prop() valueKey: string;\n\n /**\n * The key to identify an object\n */\n @Prop() identifierKey: string;\n\n /**\n * The key of the object to display\n */\n @Prop() queryKey?: string;\n\n /**\n * Wether to automatically select the first item\n */\n @Prop() autoSelectFirst: boolean = true;\n\n /**\n * Wether to show the chevron or not\n */\n @Prop() showChevron: boolean = true;\n\n /**\n * The maximum amount of items to display\n */\n @Prop() maxDisplayedItems: number = 10;\n\n /**\n * Wether to enable autocomplete\n */\n @Prop() enableAutocomplete: boolean = true;\n\n /**\n * Wether to keep the query or not\n */\n @Prop() keepQuery: boolean = true;\n\n /**\n * Wether the input uses async filtering\n */\n @Prop() asyncFilter: boolean = false;\n\n /**\n * Wether to show loading items\n */\n @Prop() loading: boolean = false;\n\n /**\n * Event when the query of the autocomplete changes\n */\n @Event({\n bubbles: false,\n })\n queryChange: EventEmitter<string>;\n\n /**\n * Event when the value changes\n */\n @Event({\n bubbles: false,\n })\n valueChange: EventEmitter<any>;\n\n /**\n * Event when the dropdown shows\n */\n @Event({\n bubbles: false,\n })\n dropdownShown: EventEmitter<any>;\n\n /**\n * The size of the input group used by the select\n */\n @Prop() size: 'small' | 'medium' = 'medium';\n\n /**\n * The prefix of the input group used by the select\n */\n @Prop() prefix: string;\n\n /**\n * The label of the input group used by the select\n */\n @Prop() label: string;\n\n /**\n * The helper of the input group used by the select\n */\n @Prop() helper: string;\n\n /**\n * Wether the field is required\n */\n @Prop({ reflect: true }) required: boolean;\n\n /**\n * The helper of the input group used by the select\n */\n @Prop({ reflect: true }) error: string;\n\n /**\n * Wether the input group is disabled used by the select\n */\n @Prop({ reflect: true }) disabled: boolean = false;\n\n /**\n * The host element\n */\n @Element() private _el: HTMLElement;\n\n @State() private _showDropdown: any = false;\n @State() private _selectedItem: any = null;\n\n @State() private _isAutoCompleting: boolean = false;\n\n get _items() {\n if (!this.items || this.loading) {\n return [];\n }\n\n let items =\n typeof this.items === 'string'\n ? JSON.parse(this.items)\n : this.items;\n\n if (typeof items?.[0] === 'string') {\n this.displayKey = 'text';\n this.valueKey = 'value';\n\n items = items.map((str) => ({\n value: str,\n text: str,\n }));\n }\n\n if (\n this._isAutoCompleting &&\n this.query?.length &&\n this.query !== this._selectedItem?.[this.displayKey] &&\n !this.asyncFilter\n ) {\n items = items.filter((item) => {\n if (this.queryKey) {\n return this._checkvalue(this.queryKey, item);\n }\n\n return (\n this._checkvalue(this._identifierKey, item) ||\n this._checkvalue(this.displayKey, item)\n );\n });\n }\n\n return items?.slice(0, this.maxDisplayedItems);\n }\n\n get _displayValue() {\n if (this._isAutoCompleting) {\n return this.query;\n }\n\n return this._selectedItem?.[this.displayKey];\n }\n\n get _placeholder() {\n return this._isAutoCompleting && this.autocompletePlaceholder?.length\n ? this.autocompletePlaceholder\n : this.placeholder;\n }\n\n get _identifierKey() {\n return this.identifierKey ?? this.valueKey ?? 'value';\n }\n\n componentDidLoad() {\n if (!this.valueKey && !this.identifierKey) {\n throw new Error('You must provide a valueKey or identifierKey');\n }\n\n if (this.value) {\n this._valueChange();\n return;\n }\n\n this.itemChanges();\n }\n\n render() {\n return (\n <Host class=\"p-select\">\n {this._showDropdown && (!!this._items.length || this.loading)}\n {this._isAutoCompleting}\n <p-dropdown\n disableTriggerClick={true}\n calculateWidth={true}\n insideClick={true}\n scrollable={true}\n show={\n this._showDropdown &&\n (!!this._items.length || this.loading)\n }\n >\n <p-input-group\n slot=\"trigger\"\n icon={this.icon}\n size={this.size}\n prefix={this.prefix}\n label={this.label}\n helper={this.helper}\n required={this.required}\n error={this.error}\n disabled={this.disabled}\n focused={this._showDropdown}\n focusMethod={\n this.enableAutocomplete ? 'focus' : 'click'\n }\n >\n <input\n slot=\"input\"\n type=\"text\"\n placeholder={this._placeholder}\n value={this._displayValue}\n class={`p-input cursor-pointer ${\n !this._isAutoCompleting && 'read-only'\n }`}\n onFocus={(ev) => this._onFocus(ev)}\n onMouseDown={(ev) => this._onMouseDown(ev)}\n onClick={() => this._onClick()}\n onInput={(ev) => this._onChange(ev)}\n />\n\n {this.showChevron && (\n <p-icon variant=\"chevron\" slot=\"suffix\" />\n )}\n </p-input-group>\n <div slot=\"items\">\n {this.loading\n ? this._getLoadingItems()\n : this._getItems()}\n </div>\n </p-dropdown>\n </Host>\n );\n }\n\n @Listen('click', { target: 'document', capture: true })\n protected documentClickHandler({ target }) {\n if (!this._showDropdown || childOf(target, this._el)) {\n return;\n }\n\n this._showDropdown = false;\n this._isAutoCompleting = false;\n }\n\n @Watch('value')\n private _valueChange() {\n this._preselectItem();\n }\n\n @Watch('items')\n public itemChanges() {\n this._preselectItem();\n }\n\n @Watch('_showDropdown')\n public _showDropdownChanges() {\n this.dropdownShown.emit({\n value: this._showDropdown,\n query: this.query,\n });\n }\n\n private _preselectItem() {\n if (this._isAutoCompleting && this.query?.length) {\n return;\n }\n\n let value = this.value;\n\n if (!this._selectedItem && !value && this.autoSelectFirst) {\n value = this._items[0];\n }\n\n // if (!value) {\n // this._selectValue(null);\n // return;\n // }\n\n const identifier =\n typeof value === 'object' && value !== null\n ? value[this._identifierKey]\n : value;\n const parsedValue =\n typeof identifier === 'string' || typeof identifier === 'number'\n ? identifier\n : JSON.stringify(identifier);\n\n const currentValue = this._selectedItem\n ? this._selectedItem?.[this._identifierKey]\n : null;\n const currentParsedValue =\n typeof currentValue === 'string' || typeof currentValue === 'number'\n ? currentValue\n : JSON.stringify(currentValue);\n\n if (this._selectedItem && currentParsedValue === parsedValue) {\n return;\n }\n\n if (!this._items?.length && value) {\n this._selectValue(value);\n return;\n }\n\n const item = this._items.find((i) => {\n const itemIdentifier = i?.[this._identifierKey];\n const parsedItemIdentifier =\n typeof itemIdentifier === 'string' ||\n typeof itemIdentifier === 'number'\n ? itemIdentifier\n : JSON.stringify(itemIdentifier);\n\n return parsedItemIdentifier === parsedValue;\n });\n\n this._selectValue(!!item ? item : value);\n }\n\n private _selectValue(item) {\n this._selectedItem = item;\n const value =\n !!this.valueKey && this.valueKey !== 'false' && item !== null\n ? item?.[this.valueKey]\n : item;\n\n this.query = this.keepQuery ? item?.[this.displayKey] : null;\n this.value = value;\n this.valueChange.emit(value);\n\n this._onBlur(true);\n }\n\n private _onFocus(ev) {\n if (!this.enableAutocomplete) {\n ev.preventDefault();\n ev.stopPropogation();\n\n if (!this._showDropdown) {\n this._showDropdown = true;\n }\n return;\n }\n\n this._showDropdown = true;\n this._isAutoCompleting = true;\n }\n\n private _onMouseDown(ev) {\n if (this.enableAutocomplete) {\n return;\n }\n\n ev.preventDefault();\n }\n\n private _onClick() {\n if (this.enableAutocomplete) {\n return;\n }\n\n this._showDropdown = !this._showDropdown;\n }\n\n private _onBlur(force = false) {\n if (!this.enableAutocomplete && !force) {\n return;\n }\n\n this._isAutoCompleting = false;\n this._showDropdown = false;\n }\n\n private _onChange(ev) {\n if (!this.enableAutocomplete) {\n return;\n }\n\n if (!this._isAutoCompleting) {\n this._isAutoCompleting = true;\n this._showDropdown = true;\n }\n\n this.query = ev.target.value;\n this.queryChange.emit(ev.target.value);\n }\n\n private _checkvalue(key, item) {\n return (\n item?.[key]\n ?.toString()\n ?.toLowerCase()\n .indexOf(this.query?.toLowerCase()) >= 0\n );\n }\n\n private _getItems() {\n return this._items.map((item) => (\n <p-dropdown-menu-item\n onClick={() => this._selectValue(item)}\n active={\n item[this._identifierKey] ===\n this._selectedItem?.[this._identifierKey]\n }\n >\n {item[this.displayKey]}\n </p-dropdown-menu-item>\n ));\n }\n\n private _getLoadingItems() {\n return [0, 0, 0].map(() => (\n <p-dropdown-menu-item enableHover={false}>\n <p-loader variant=\"ghost\" class=\"h-6 w-full rounded\" />\n </p-dropdown-menu-item>\n ));\n }\n}\n"],"version":3}
|
|
1
|
+
{"file":"p-select.entry.js","mappings":";;;AAAA,MAAM,kBAAkB,GAAG,klLAAklL;;MCoBhmL,MAAM;;;;;;;;;;;;sBAkCc,MAAM;;;;2BAoBA,IAAI;uBAKR,IAAI;6BAKC,EAAE;8BAKA,IAAI;qBAKb,IAAI;uBAKF,KAAK;mBAKT,KAAK;g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EAAE,IAAI;;IACzB,QACI,CAAA,MAAA,MAAA,IAAI,aAAJ,IAAI,uBAAJ,IAAI,CAAG,GAAG,CAAC,0CACL,QAAQ,EAAE,0CACV,WAAW,GACZ,OAAO,CAAC,MAAA,IAAI,CAAC,KAAK,0CAAE,WAAW,EAAE,CAAC,KAAI,CAAC,EAC9C;GACL;EAEO,SAAS;IACb,OAAO,IAAI,CAAC,MAAM,CAAC,GAAG,CAAC,CAAC,IAAI;;MAAK,QAC7B,4BACI,OAAO,EAAE,MAAM,IAAI,CAAC,YAAY,CAAC,IAAI,CAAC,EACtC,MAAM,EACF,IAAI,CAAC,IAAI,CAAC,cAAc,CAAC;WACzB,MAAA,IAAI,CAAC,aAAa,0CAAG,IAAI,CAAC,cAAc,CAAC,CAAA,IAG5C,IAAI,CAAC,IAAI,CAAC,UAAU,CAAC,CACH,EAC1B;KAAA,CAAC,CAAC;GACN;EAEO,gBAAgB;IACpB,OAAO,CAAC,CAAC,EAAE,CAAC,EAAE,CAAC,CAAC,CAAC,GAAG,CAAC,OACjB,4BAAsB,WAAW,EAAE,KAAK,IACpC,gBAAU,OAAO,EAAC,OAAO,EAAC,KAAK,EAAC,oBAAoB,GAAG,CACpC,CAC1B,CAAC,CAAC;GACN;;;;;;;;;;;;","names":[],"sources":["./src/components/molecules/select/select.component.scss?tag=p-select","./src/components/molecules/select/select.component.tsx"],"sourcesContent":["p-select {\n @apply flex w-full flex-col;\n\n input.read-only {\n @apply text-ellipsis;\n }\n}\n","import {\n Component,\n Element,\n Event,\n EventEmitter,\n h,\n Host,\n Listen,\n Prop,\n State,\n Watch,\n} from '@stencil/core';\nimport { childOf } from '../../../utils';\nimport { IconVariant } from '../../atoms/icon/icon.component';\n\n@Component({\n tag: 'p-select',\n styleUrl: 'select.component.scss',\n shadow: false,\n})\nexport class Select {\n /**\n * The items to show in the dropdown\n */\n @Prop() items: string | any[];\n\n /**\n * Icon of the select box\n */\n @Prop() icon: IconVariant;\n\n /**\n * The current query\n */\n @Prop() query: string;\n\n /**\n * The placeholder of the input\n */\n @Prop() placeholder: string;\n\n /**\n * The placeholder of the input when auto completing\n */\n @Prop() autocompletePlaceholder: string;\n\n /**\n * The current value\n */\n @Prop() value: any;\n\n /**\n * The key of the object to display\n */\n @Prop() displayKey: string = 'text';\n\n /**\n * The key of the object to return\n */\n @Prop() valueKey: string;\n\n /**\n * The key to identify an object\n */\n @Prop() identifierKey: string;\n\n /**\n * The key of the object to display\n */\n @Prop() queryKey?: string;\n\n /**\n * Wether to automatically select the first item\n */\n @Prop() autoSelectFirst: boolean = true;\n\n /**\n * Wether to show the chevron or not\n */\n @Prop() showChevron: boolean = true;\n\n /**\n * The maximum amount of items to display\n */\n @Prop() maxDisplayedItems: number = 10;\n\n /**\n * Wether to enable autocomplete\n */\n @Prop() enableAutocomplete: boolean = true;\n\n /**\n * Wether to keep the query or not\n */\n @Prop() keepQuery: boolean = true;\n\n /**\n * Wether the input uses async filtering\n */\n @Prop() asyncFilter: boolean = false;\n\n /**\n * Wether to show loading items\n */\n @Prop() loading: boolean = false;\n\n /**\n * Event when the query of the autocomplete changes\n */\n @Event({\n bubbles: false,\n })\n queryChange: EventEmitter<string>;\n\n /**\n * Event when the value changes\n */\n @Event({\n bubbles: false,\n })\n valueChange: EventEmitter<any>;\n\n /**\n * Event when the dropdown shows\n */\n @Event({\n bubbles: false,\n })\n dropdownShown: EventEmitter<any>;\n\n /**\n * The size of the input group used by the select\n */\n @Prop() size: 'small' | 'medium' = 'medium';\n\n /**\n * The prefix of the input group used by the select\n */\n @Prop() prefix: string;\n\n /**\n * The label of the input group used by the select\n */\n @Prop() label: string;\n\n /**\n * The helper of the input group used by the select\n */\n @Prop() helper: string;\n\n /**\n * Wether the field is required\n */\n @Prop({ reflect: true }) required: boolean;\n\n /**\n * The helper of the input group used by the select\n */\n @Prop({ reflect: true }) error: string;\n\n /**\n * Wether the input group is disabled used by the select\n */\n @Prop({ reflect: true }) disabled: boolean = false;\n\n /**\n * The host element\n */\n @Element() private _el: HTMLElement;\n\n @State() private _showDropdown: any = false;\n @State() private _selectedItem: any = null;\n\n @State() private _isAutoCompleting: boolean = false;\n\n get _items() {\n if (!this.items || this.loading) {\n return [];\n }\n\n let items =\n typeof this.items === 'string'\n ? JSON.parse(this.items)\n : this.items;\n\n if (typeof items?.[0] === 'string') {\n this.displayKey = 'text';\n this.valueKey = 'value';\n\n items = items.map((str) => ({\n value: str,\n text: str,\n }));\n }\n\n if (\n this._isAutoCompleting &&\n this.query?.length &&\n this.query !== this._selectedItem?.[this.displayKey] &&\n !this.asyncFilter\n ) {\n items = items.filter((item) => {\n if (this.queryKey) {\n return this._checkvalue(this.queryKey, item);\n }\n\n return (\n this._checkvalue(this._identifierKey, item) ||\n this._checkvalue(this.displayKey, item)\n );\n });\n }\n\n return items?.slice(0, this.maxDisplayedItems);\n }\n\n get _displayValue() {\n if (this._isAutoCompleting) {\n return this.query;\n }\n\n return this._selectedItem?.[this.displayKey];\n }\n\n get _placeholder() {\n return this._isAutoCompleting && this.autocompletePlaceholder?.length\n ? this.autocompletePlaceholder\n : this.placeholder;\n }\n\n get _identifierKey() {\n return this.identifierKey ?? this.valueKey ?? 'value';\n }\n\n componentDidLoad() {\n if (!this.valueKey && !this.identifierKey) {\n throw new Error('You must provide a valueKey or identifierKey');\n }\n\n if (this.value) {\n this._valueChange();\n return;\n }\n\n this.itemChanges();\n }\n\n render() {\n return (\n <Host class=\"p-select\">\n {this._showDropdown && (!!this._items.length || this.loading)}\n {this._isAutoCompleting}\n <p-dropdown\n disableTriggerClick={true}\n calculateWidth={true}\n insideClick={true}\n scrollable={true}\n show={\n this._showDropdown &&\n (!!this._items.length || this.loading)\n }\n >\n <p-input-group\n slot=\"trigger\"\n icon={this.icon}\n size={this.size}\n prefix={this.prefix}\n label={this.label}\n helper={this.helper}\n required={this.required}\n error={this.error}\n disabled={this.disabled}\n focused={this._showDropdown}\n focusMethod={\n this.enableAutocomplete ? 'focus' : 'click'\n }\n >\n <input\n slot=\"input\"\n type=\"text\"\n placeholder={this._placeholder}\n value={this._displayValue}\n class={`p-input cursor-pointer ${\n !this._isAutoCompleting && 'read-only'\n }`}\n onFocus={(ev) => this._onFocus(ev)}\n onMouseDown={(ev) => this._onMouseDown(ev)}\n onClick={() => this._onClick()}\n onInput={(ev) => this._onChange(ev)}\n />\n\n {this.showChevron && (\n <p-icon variant=\"chevron\" slot=\"suffix\" />\n )}\n </p-input-group>\n <div slot=\"items\">\n {this.loading\n ? this._getLoadingItems()\n : this._getItems()}\n </div>\n </p-dropdown>\n </Host>\n );\n }\n\n @Listen('click', { target: 'document', capture: true })\n protected documentClickHandler({ target }) {\n if (!this._showDropdown || childOf(target, this._el)) {\n return;\n }\n\n this._showDropdown = false;\n this._isAutoCompleting = false;\n }\n\n @Watch('value')\n private _valueChange() {\n this._preselectItem();\n }\n\n @Watch('items')\n public itemChanges() {\n this._preselectItem();\n }\n\n @Watch('_showDropdown')\n public _showDropdownChanges() {\n this.dropdownShown.emit({\n value: this._showDropdown,\n query: this.query,\n });\n }\n\n private _preselectItem() {\n if (this._isAutoCompleting && this.query?.length) {\n return;\n }\n\n let value = this.value;\n\n if (!this._selectedItem && !value && this.autoSelectFirst) {\n value = this._items[0];\n }\n\n // if (!value) {\n // this._selectValue(null);\n // return;\n // }\n\n const identifier =\n typeof value === 'object' && value !== null\n ? value[this._identifierKey]\n : value;\n const parsedValue =\n typeof identifier === 'string' || typeof identifier === 'number'\n ? identifier\n : JSON.stringify(identifier);\n\n const currentValue = this._selectedItem\n ? this._selectedItem?.[this._identifierKey]\n : null;\n const currentParsedValue =\n typeof currentValue === 'string' || typeof currentValue === 'number'\n ? currentValue\n : JSON.stringify(currentValue);\n\n if (this._selectedItem && currentParsedValue === parsedValue) {\n return;\n }\n\n if (!this._items?.length && value) {\n this._selectValue(value);\n return;\n }\n\n const item = this._items.find((i) => {\n const itemIdentifier = i?.[this._identifierKey];\n const parsedItemIdentifier =\n typeof itemIdentifier === 'string' ||\n typeof itemIdentifier === 'number'\n ? itemIdentifier\n : JSON.stringify(itemIdentifier);\n\n return parsedItemIdentifier === parsedValue;\n });\n\n this._selectValue(!!item ? item : value);\n }\n\n private _selectValue(item) {\n this._selectedItem = item;\n const value =\n !!this.valueKey && this.valueKey !== 'false' && item !== null\n ? item?.[this.valueKey]\n : item;\n\n this.query = this.keepQuery ? item?.[this.displayKey] : null;\n this.value = value;\n this.valueChange.emit(value);\n\n this._onBlur(true);\n }\n\n private _onFocus(ev) {\n if (!this.enableAutocomplete) {\n ev.preventDefault();\n ev.stopPropogation();\n\n if (!this._showDropdown) {\n this._showDropdown = true;\n }\n return;\n }\n\n this._showDropdown = true;\n this._isAutoCompleting = true;\n }\n\n private _onMouseDown(ev) {\n if (this.enableAutocomplete) {\n return;\n }\n\n ev.preventDefault();\n }\n\n private _onClick() {\n if (this.enableAutocomplete) {\n return;\n }\n\n this._showDropdown = !this._showDropdown;\n }\n\n private _onBlur(force = false) {\n if (!this.enableAutocomplete && !force) {\n return;\n }\n\n this._isAutoCompleting = false;\n this._showDropdown = false;\n }\n\n private _onChange(ev) {\n if (!this.enableAutocomplete) {\n return;\n }\n\n if (!this._isAutoCompleting) {\n this._isAutoCompleting = true;\n this._showDropdown = true;\n }\n\n this.query = ev.target.value;\n this.queryChange.emit(ev.target.value);\n }\n\n private _checkvalue(key, item) {\n return (\n item?.[key]\n ?.toString()\n ?.toLowerCase()\n .indexOf(this.query?.toLowerCase()) >= 0\n );\n }\n\n private _getItems() {\n return this._items.map((item) => (\n <p-dropdown-menu-item\n onClick={() => this._selectValue(item)}\n active={\n item[this._identifierKey] ===\n this._selectedItem?.[this._identifierKey]\n }\n >\n {item[this.displayKey]}\n </p-dropdown-menu-item>\n ));\n }\n\n private _getLoadingItems() {\n return [0, 0, 0].map(() => (\n <p-dropdown-menu-item enableHover={false}>\n <p-loader variant=\"ghost\" class=\"h-6 w-full rounded\" />\n </p-dropdown-menu-item>\n ));\n }\n}\n"],"version":3}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { r as registerInstance, h, H as Host } from './index-2c1bdb40.js';
|
|
2
2
|
|
|
3
|
-
const sliderIndicatorComponentCss = ".block{display:block!important}.h-2{height:.5rem!important}.w-2{width:.5rem!important}.bg-mystic-dark{--tw-bg-opacity:1!important;background-color:rgb(218 230 240/var(--tw-bg-opacity))!important}*{box-sizing:border-box}:host{--tw-bg-opacity:1;background-color:rgb(218 230 240/var(--tw-bg-opacity));border-radius:100%;display:block;height:.5rem;width:.5rem}:host(.active){--tw-bg-opacity:1;background-color:rgb(82 138 250/var(--tw-bg-opacity))}.
|
|
3
|
+
const sliderIndicatorComponentCss = ".block{display:block!important}.h-2{height:.5rem!important}.w-2{width:.5rem!important}.bg-mystic-dark{--tw-bg-opacity:1!important;background-color:rgb(218 230 240/var(--tw-bg-opacity))!important}*{box-sizing:border-box}:host{--tw-bg-opacity:1;background-color:rgb(218 230 240/var(--tw-bg-opacity));border-radius:100%;display:block;height:.5rem;width:.5rem}:host(.active){--tw-bg-opacity:1;background-color:rgb(82 138 250/var(--tw-bg-opacity))}.static{position:static!important}.visible{visibility:visible!important}.hidden{display:none!important}.cursor-pointer{cursor:pointer!important}.resize{resize:both!important}";
|
|
4
4
|
|
|
5
5
|
const SliderIndicator = class {
|
|
6
6
|
constructor(hostRef) {
|
|
@@ -2,7 +2,7 @@ import { r as registerInstance, c as createEvent, h, H as Host, g as getElement
|
|
|
2
2
|
import { f as formatTranslation, g as getLocaleComponentStrings } from './localization-901dc2d3.js';
|
|
3
3
|
import { d as defaultSize, a as defaultSizeOptions } from './constants-826f9460.js';
|
|
4
4
|
|
|
5
|
-
const tableComponentCss = ".flex{display:flex!important}.flex-shrink{flex-shrink:1!important}*{box-sizing:border-box}p-table{display:flex;flex-direction:column}p-table .p-input[type=checkbox]{flex-shrink:0}.static{position:static!important}.mb-14{margin-bottom:3.5rem!important}.mb-6{margin-bottom:1.5rem!important}.table{display:table!important}.hidden{display:none!important}.h-6{height:1.5rem!important}.w-6{width:1.5rem!important}.max-w-\\[20rem\\]{max-width:20rem!important}.cursor-pointer{cursor:pointer!important}.flex-col{flex-direction:column!important}.items-center{align-items:center!important}.self-center{align-self:center!important}.rounded{border-radius:.25rem!important}.py-24{padding-bottom:6rem!important;padding-top:6rem!important}.text-center{text-align:center!important}.text-sm{font-size:.875rem!important;line-height:1.25rem!important}.font-semibold{font-weight:600!important}.text-storm-medium{--tw-text-opacity:1!important;color:rgb(128 130 158/var(--tw-text-opacity))!important}.filter{filter:var(--tw-blur) var(--tw-brightness) var(--tw-contrast) var(--tw-grayscale) var(--tw-hue-rotate) var(--tw-invert) var(--tw-saturate) var(--tw-sepia) var(--tw-drop-shadow)!important}.table-cell{display:table-cell!important}.w-1\\/12{width:8.333333%!important}.w-10\\/12{width:83.333333%!important}.w-11\\/12{width:91.666667%!important}.w-2\\/12{width:16.666667%!important}.w-3\\/12{width:25%!important}.w-4\\/12{width:33.333333%!important}.w-5\\/12{width:41.666667%!important}.w-6\\/12{width:50%!important}.w-7\\/12{width:58.333333%!important}.w-8\\/12{width:66.666667%!important}.w-9\\/12{width:75%!important}.w-auto{width:auto!important}.w-full{width:100%!important}.flex-1{flex:1 1 0%!important}.justify-start{justify-content:flex-start!important}.justify-end{justify-content:flex-end!important}.justify-center{justify-content:center!important}.pr-4{padding-right:1rem!important}.text-storm-dark{--tw-text-opacity:1!important;color:rgb(39 40 56/var(--tw-text-opacity))!important}@media (min-width:40rem){.tablet\\:w-1\\/12{width:8.333333%!important}.tablet\\:w-10\\/12{width:83.333333%!important}.tablet\\:w-11\\/12{width:91.666667%!important}.tablet\\:w-2\\/12{width:16.666667%!important}.tablet\\:w-3\\/12{width:25%!important}.tablet\\:w-4\\/12{width:33.333333%!important}.tablet\\:w-5\\/12{width:41.666667%!important}.tablet\\:w-6\\/12{width:50%!important}.tablet\\:w-7\\/12{width:58.333333%!important}.tablet\\:w-8\\/12{width:66.666667%!important}.tablet\\:w-9\\/12{width:75%!important}}@media (min-width:64rem){.desktop-xs\\:w-1\\/12{width:8.333333%!important}.desktop-xs\\:w-10\\/12{width:83.333333%!important}.desktop-xs\\:w-11\\/12{width:91.666667%!important}.desktop-xs\\:w-2\\/12{width:16.666667%!important}.desktop-xs\\:w-3\\/12{width:25%!important}.desktop-xs\\:w-4\\/12{width:33.333333%!important}.desktop-xs\\:w-5\\/12{width:41.666667%!important}.desktop-xs\\:w-6\\/12{width:50%!important}.desktop-xs\\:w-7\\/12{width:58.333333%!important}.desktop-xs\\:w-8\\/12{width:66.666667%!important}.desktop-xs\\:w-9\\/12{width:75%!important}}@media (min-width:80rem){.desktop-sm\\:w-1\\/12{width:8.333333%!important}.desktop-sm\\:w-10\\/12{width:83.333333%!important}.desktop-sm\\:w-11\\/12{width:91.666667%!important}.desktop-sm\\:w-2\\/12{width:16.666667%!important}.desktop-sm\\:w-3\\/12{width:25%!important}.desktop-sm\\:w-4\\/12{width:33.333333%!important}.desktop-sm\\:w-5\\/12{width:41.666667%!important}.desktop-sm\\:w-6\\/12{width:50%!important}.desktop-sm\\:w-7\\/12{width:58.333333%!important}.desktop-sm\\:w-8\\/12{width:66.666667%!important}.desktop-sm\\:w-9\\/12{width:75%!important}}@media (min-width:85.375rem){.desktop\\:w-1\\/12{width:8.333333%!important}.desktop\\:w-10\\/12{width:83.333333%!important}.desktop\\:w-11\\/12{width:91.666667%!important}.desktop\\:w-2\\/12{width:16.666667%!important}.desktop\\:w-3\\/12{width:25%!important}.desktop\\:w-4\\/12{width:33.333333%!important}.desktop\\:w-5\\/12{width:41.666667%!important}.desktop\\:w-6\\/12{width:50%!important}.desktop\\:w-7\\/12{width:58.333333%!important}.desktop\\:w-8\\/12{width:66.666667%!important}.desktop\\:w-9\\/12{width:75%!important}}@media (min-width:90rem){.desktop-lg\\:w-1\\/12{width:8.333333%!important}.desktop-lg\\:w-10\\/12{width:83.333333%!important}.desktop-lg\\:w-11\\/12{width:91.666667%!important}.desktop-lg\\:w-2\\/12{width:16.666667%!important}.desktop-lg\\:w-3\\/12{width:25%!important}.desktop-lg\\:w-4\\/12{width:33.333333%!important}.desktop-lg\\:w-5\\/12{width:41.666667%!important}.desktop-lg\\:w-6\\/12{width:50%!important}.desktop-lg\\:w-7\\/12{width:58.333333%!important}.desktop-lg\\:w-8\\/12{width:66.666667%!important}.desktop-lg\\:w-9\\/12{width:75%!important}}@media (min-width:120rem){.desktop-xl\\:w-1\\/12{width:8.333333%!important}.desktop-xl\\:w-10\\/12{width:83.333333%!important}.desktop-xl\\:w-11\\/12{width:91.666667%!important}.desktop-xl\\:w-2\\/12{width:16.666667%!important}.desktop-xl\\:w-3\\/12{width:25%!important}.desktop-xl\\:w-4\\/12{width:33.333333%!important}.desktop-xl\\:w-5\\/12{width:41.666667%!important}.desktop-xl\\:w-6\\/12{width:50%!important}.desktop-xl\\:w-7\\/12{width:58.333333%!important}.desktop-xl\\:w-8\\/12{width:66.666667%!important}.desktop-xl\\:w-9\\/12{width:75%!important}}.h-8{height:2rem!important}@media (min-width:64rem){.desktop-xs\\:flex{display:flex!important}}.fixed{position:fixed!important}.bottom-0{bottom:0!important}.left-0{left:0!important}.ml-1{margin-left:.25rem!important}.block{display:block!important}.w-3\\/4{width:75%!important}.gap-4{gap:1rem!important}.border{border-width:1px!important}.border-solid{border-style:solid!important}.border-transparent{border-color:transparent!important}.border-t-mystic-dark{--tw-border-opacity:1!important;border-top-color:rgb(218 230 240/var(--tw-border-opacity))!important}.bg-white{--tw-bg-opacity:1!important;background-color:rgb(255 255 255/var(--tw-bg-opacity))!important}.p-4{padding:1rem!important}@media (min-width:64rem){.desktop-xs\\:hidden{display:none!important}.desktop-xs\\:w-48{width:12rem!important}.desktop-xs\\:w-auto{width:auto!important}.desktop-xs\\:flex-row{flex-direction:row!important}}.-rotate-0{--tw-rotate:-0deg!important}.-rotate-0,.-rotate-135{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))!important}.-rotate-135{--tw-rotate:-135deg!important}.-rotate-180{--tw-rotate:-180deg!important}.-rotate-180,.-rotate-225{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))!important}.-rotate-225{--tw-rotate:-225deg!important}.-rotate-25{--tw-rotate:-25deg!important}.-rotate-25,.-rotate-270{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))!important}.-rotate-270{--tw-rotate:-270deg!important}.-rotate-315{--tw-rotate:-315deg!important}.-rotate-315,.-rotate-45{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))!important}.-rotate-45{--tw-rotate:-45deg!important}.-rotate-90{--tw-rotate:-90deg!important}.-rotate-90,.rotate-0{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))!important}.rotate-0{--tw-rotate:0deg!important}.rotate-135{--tw-rotate:135deg!important}.rotate-135,.rotate-180{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))!important}.rotate-180{--tw-rotate:180deg!important}.rotate-225{--tw-rotate:225deg!important}.rotate-225,.rotate-25{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))!important}.rotate-25{--tw-rotate:25deg!important}.rotate-270{--tw-rotate:270deg!important}.rotate-270,.rotate-315{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))!important}.rotate-315{--tw-rotate:315deg!important}.rotate-45{--tw-rotate:45deg!important}.rotate-45,.rotate-90{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))!important}.rotate-90{--tw-rotate:90deg!important}.scale-x-flip{--tw-scale-x:-1!important}.scale-x-flip,.scale-y-flip{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))!important}.scale-y-flip{--tw-scale-y:-1!important}.transform{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))!important}.text-2xl{font-size:1.5rem!important;line-height:2rem!important}.text-3xl{font-size:1.875rem!important;line-height:2.25rem!important}.text-4xl{font-size:2.25rem!important;line-height:2.5rem!important}.text-5xl{font-size:3rem!important}.text-5xl,.text-6xl{line-height:1!important}.text-6xl{font-size:3.75rem!important}.text-base{font-size:1rem!important;line-height:1.5rem!important}.text-lg{font-size:1.125rem!important}.text-lg,.text-xl{line-height:1.75rem!important}.text-xl{font-size:1.25rem!important}.text-xs{font-size:.75rem!important;line-height:1rem!important}.text-xxs{font-size:.6875rem!important}.inline{display:inline!important}.px-2{padding-left:.5rem!important;padding-right:.5rem!important}.visible{visibility:visible!important}.absolute{position:absolute!important}.m-0{margin:0!important}.table-row{display:table-row!important}.text-negative{--tw-text-opacity:1!important;color:rgb(185 30 40/var(--tw-text-opacity))!important}.text-negative-light{--tw-text-opacity:1!important;color:rgb(255 204 211/var(--tw-text-opacity))!important}.hover\\:text-negative:hover{--tw-text-opacity:1!important;color:rgb(185 30 40/var(--tw-text-opacity))!important}.ml-2{margin-left:.5rem!important}.items-end{align-items:flex-end!important}.justify-between{justify-content:space-between!important}.rounded-bl-none{border-bottom-left-radius:0!important}.rounded-br-none{border-bottom-right-radius:0!important}.rounded-tl-none{border-top-left-radius:0!important}.rounded-tr-none{border-top-right-radius:0!important}.border-l-0{border-left-width:0!important}.border-r-0{border-right-width:0!important}.pl-0{padding-left:0!important}.pr-0{padding-right:0!important}";
|
|
5
|
+
const tableComponentCss = ".flex{display:flex!important}.flex-shrink{flex-shrink:1!important}*{box-sizing:border-box}p-table{display:flex;flex-direction:column}p-table .p-input[type=checkbox]{flex-shrink:0}.static{position:static!important}.mb-14{margin-bottom:3.5rem!important}.mb-6{margin-bottom:1.5rem!important}.table{display:table!important}.hidden{display:none!important}.h-6{height:1.5rem!important}.w-6{width:1.5rem!important}.max-w-\\[20rem\\]{max-width:20rem!important}.cursor-pointer{cursor:pointer!important}.flex-col{flex-direction:column!important}.items-center{align-items:center!important}.self-center{align-self:center!important}.rounded{border-radius:.25rem!important}.py-24{padding-bottom:6rem!important;padding-top:6rem!important}.text-center{text-align:center!important}.text-sm{font-size:.875rem!important;line-height:1.25rem!important}.font-semibold{font-weight:600!important}.text-storm-medium{--tw-text-opacity:1!important;color:rgb(128 130 158/var(--tw-text-opacity))!important}.filter{filter:var(--tw-blur) var(--tw-brightness) var(--tw-contrast) var(--tw-grayscale) var(--tw-hue-rotate) var(--tw-invert) var(--tw-saturate) var(--tw-sepia) var(--tw-drop-shadow)!important}.table-cell{display:table-cell!important}.w-1\\/12{width:8.333333%!important}.w-10\\/12{width:83.333333%!important}.w-11\\/12{width:91.666667%!important}.w-2\\/12{width:16.666667%!important}.w-3\\/12{width:25%!important}.w-4\\/12{width:33.333333%!important}.w-5\\/12{width:41.666667%!important}.w-6\\/12{width:50%!important}.w-7\\/12{width:58.333333%!important}.w-8\\/12{width:66.666667%!important}.w-9\\/12{width:75%!important}.w-auto{width:auto!important}.w-full{width:100%!important}.flex-1{flex:1 1 0%!important}.justify-start{justify-content:flex-start!important}.justify-end{justify-content:flex-end!important}.justify-center{justify-content:center!important}.pr-4{padding-right:1rem!important}.text-storm-dark{--tw-text-opacity:1!important;color:rgb(39 40 56/var(--tw-text-opacity))!important}@media (min-width:40rem){.tablet\\:w-1\\/12{width:8.333333%!important}.tablet\\:w-10\\/12{width:83.333333%!important}.tablet\\:w-11\\/12{width:91.666667%!important}.tablet\\:w-2\\/12{width:16.666667%!important}.tablet\\:w-3\\/12{width:25%!important}.tablet\\:w-4\\/12{width:33.333333%!important}.tablet\\:w-5\\/12{width:41.666667%!important}.tablet\\:w-6\\/12{width:50%!important}.tablet\\:w-7\\/12{width:58.333333%!important}.tablet\\:w-8\\/12{width:66.666667%!important}.tablet\\:w-9\\/12{width:75%!important}}@media (min-width:64rem){.desktop-xs\\:w-1\\/12{width:8.333333%!important}.desktop-xs\\:w-10\\/12{width:83.333333%!important}.desktop-xs\\:w-11\\/12{width:91.666667%!important}.desktop-xs\\:w-2\\/12{width:16.666667%!important}.desktop-xs\\:w-3\\/12{width:25%!important}.desktop-xs\\:w-4\\/12{width:33.333333%!important}.desktop-xs\\:w-5\\/12{width:41.666667%!important}.desktop-xs\\:w-6\\/12{width:50%!important}.desktop-xs\\:w-7\\/12{width:58.333333%!important}.desktop-xs\\:w-8\\/12{width:66.666667%!important}.desktop-xs\\:w-9\\/12{width:75%!important}}@media (min-width:80rem){.desktop-sm\\:w-1\\/12{width:8.333333%!important}.desktop-sm\\:w-10\\/12{width:83.333333%!important}.desktop-sm\\:w-11\\/12{width:91.666667%!important}.desktop-sm\\:w-2\\/12{width:16.666667%!important}.desktop-sm\\:w-3\\/12{width:25%!important}.desktop-sm\\:w-4\\/12{width:33.333333%!important}.desktop-sm\\:w-5\\/12{width:41.666667%!important}.desktop-sm\\:w-6\\/12{width:50%!important}.desktop-sm\\:w-7\\/12{width:58.333333%!important}.desktop-sm\\:w-8\\/12{width:66.666667%!important}.desktop-sm\\:w-9\\/12{width:75%!important}}@media (min-width:85.375rem){.desktop\\:w-1\\/12{width:8.333333%!important}.desktop\\:w-10\\/12{width:83.333333%!important}.desktop\\:w-11\\/12{width:91.666667%!important}.desktop\\:w-2\\/12{width:16.666667%!important}.desktop\\:w-3\\/12{width:25%!important}.desktop\\:w-4\\/12{width:33.333333%!important}.desktop\\:w-5\\/12{width:41.666667%!important}.desktop\\:w-6\\/12{width:50%!important}.desktop\\:w-7\\/12{width:58.333333%!important}.desktop\\:w-8\\/12{width:66.666667%!important}.desktop\\:w-9\\/12{width:75%!important}}@media (min-width:90rem){.desktop-lg\\:w-1\\/12{width:8.333333%!important}.desktop-lg\\:w-10\\/12{width:83.333333%!important}.desktop-lg\\:w-11\\/12{width:91.666667%!important}.desktop-lg\\:w-2\\/12{width:16.666667%!important}.desktop-lg\\:w-3\\/12{width:25%!important}.desktop-lg\\:w-4\\/12{width:33.333333%!important}.desktop-lg\\:w-5\\/12{width:41.666667%!important}.desktop-lg\\:w-6\\/12{width:50%!important}.desktop-lg\\:w-7\\/12{width:58.333333%!important}.desktop-lg\\:w-8\\/12{width:66.666667%!important}.desktop-lg\\:w-9\\/12{width:75%!important}}@media (min-width:120rem){.desktop-xl\\:w-1\\/12{width:8.333333%!important}.desktop-xl\\:w-10\\/12{width:83.333333%!important}.desktop-xl\\:w-11\\/12{width:91.666667%!important}.desktop-xl\\:w-2\\/12{width:16.666667%!important}.desktop-xl\\:w-3\\/12{width:25%!important}.desktop-xl\\:w-4\\/12{width:33.333333%!important}.desktop-xl\\:w-5\\/12{width:41.666667%!important}.desktop-xl\\:w-6\\/12{width:50%!important}.desktop-xl\\:w-7\\/12{width:58.333333%!important}.desktop-xl\\:w-8\\/12{width:66.666667%!important}.desktop-xl\\:w-9\\/12{width:75%!important}}.ml-1{margin-left:.25rem!important}.ml-2{margin-left:.5rem!important}.items-end{align-items:flex-end!important}.justify-between{justify-content:space-between!important}.rounded-bl-none{border-bottom-left-radius:0!important}.rounded-br-none{border-bottom-right-radius:0!important}.rounded-tl-none{border-top-left-radius:0!important}.rounded-tr-none{border-top-right-radius:0!important}.border-l-0{border-left-width:0!important}.border-r-0{border-right-width:0!important}.pl-0{padding-left:0!important}.pr-0{padding-right:0!important}.text-negative{--tw-text-opacity:1!important;color:rgb(185 30 40/var(--tw-text-opacity))!important}.fixed{position:fixed!important}.bottom-0{bottom:0!important}.left-0{left:0!important}.block{display:block!important}.h-8{height:2rem!important}.w-3\\/4{width:75%!important}.gap-4{gap:1rem!important}.border{border-width:1px!important}.border-solid{border-style:solid!important}.border-transparent{border-color:transparent!important}.border-t-mystic-dark{--tw-border-opacity:1!important;border-top-color:rgb(218 230 240/var(--tw-border-opacity))!important}.bg-white{--tw-bg-opacity:1!important;background-color:rgb(255 255 255/var(--tw-bg-opacity))!important}.p-4{padding:1rem!important}@media (min-width:64rem){.desktop-xs\\:flex{display:flex!important}.desktop-xs\\:hidden{display:none!important}.desktop-xs\\:w-48{width:12rem!important}.desktop-xs\\:w-auto{width:auto!important}.desktop-xs\\:flex-row{flex-direction:row!important}}.m-0{margin:0!important}.table-row{display:table-row!important}.-rotate-0{--tw-rotate:-0deg!important}.-rotate-0,.-rotate-135{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))!important}.-rotate-135{--tw-rotate:-135deg!important}.-rotate-180{--tw-rotate:-180deg!important}.-rotate-180,.-rotate-225{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))!important}.-rotate-225{--tw-rotate:-225deg!important}.-rotate-25{--tw-rotate:-25deg!important}.-rotate-25,.-rotate-270{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))!important}.-rotate-270{--tw-rotate:-270deg!important}.-rotate-315{--tw-rotate:-315deg!important}.-rotate-315,.-rotate-45{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))!important}.-rotate-45{--tw-rotate:-45deg!important}.-rotate-90{--tw-rotate:-90deg!important}.-rotate-90,.rotate-0{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))!important}.rotate-0{--tw-rotate:0deg!important}.rotate-135{--tw-rotate:135deg!important}.rotate-135,.rotate-180{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))!important}.rotate-180{--tw-rotate:180deg!important}.rotate-225{--tw-rotate:225deg!important}.rotate-225,.rotate-25{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))!important}.rotate-25{--tw-rotate:25deg!important}.rotate-270{--tw-rotate:270deg!important}.rotate-270,.rotate-315{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))!important}.rotate-315{--tw-rotate:315deg!important}.rotate-45{--tw-rotate:45deg!important}.rotate-45,.rotate-90{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))!important}.rotate-90{--tw-rotate:90deg!important}.scale-x-flip{--tw-scale-x:-1!important}.scale-x-flip,.scale-y-flip{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))!important}.scale-y-flip{--tw-scale-y:-1!important}.transform{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))!important}.text-2xl{font-size:1.5rem!important;line-height:2rem!important}.text-3xl{font-size:1.875rem!important;line-height:2.25rem!important}.text-4xl{font-size:2.25rem!important;line-height:2.5rem!important}.text-5xl{font-size:3rem!important}.text-5xl,.text-6xl{line-height:1!important}.text-6xl{font-size:3.75rem!important}.text-base{font-size:1rem!important;line-height:1.5rem!important}.text-lg{font-size:1.125rem!important}.text-lg,.text-xl{line-height:1.75rem!important}.text-xl{font-size:1.25rem!important}.text-xs{font-size:.75rem!important;line-height:1rem!important}.text-xxs{font-size:.6875rem!important}.visible{visibility:visible!important}.absolute{position:absolute!important}.text-negative-light{--tw-text-opacity:1!important;color:rgb(255 204 211/var(--tw-text-opacity))!important}.hover\\:text-negative:hover{--tw-text-opacity:1!important;color:rgb(185 30 40/var(--tw-text-opacity))!important}.inline{display:inline!important}.px-2{padding-left:.5rem!important;padding-right:.5rem!important}.blur{--tw-blur:blur(8px)!important;filter:var(--tw-blur) var(--tw-brightness) var(--tw-contrast) var(--tw-grayscale) var(--t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I,CAAC,QAAQ,EAAE;MACX,OAAO;KACV;IAED,QAAQ,CAAC,OAAO,GAAG,CAAC,QAAQ,CAAC,OAAO,CAAC;IACrC,IAAI,CAAC,eAAe,CAAC,QAAQ,EAAE,KAAK,CAAC,CAAC;GACzC;EAEO,QAAQ,CAAC,EAAe;;IAC5B,IAAI,CAAC,EAAE,EAAE;MACL,OAAO,EAAE,CAAC;KACb;IAED,IAAI,CAAA,MAAA,EAAE,aAAF,EAAE,uBAAF,EAAE,CAAE,OAAO,0CAAE,WAAW,EAAE,MAAK,aAAa,EAAE;MAC9C,OAAO,EAAE,CAAC;KACb;IAED,OAAO,IAAI,CAAC,QAAQ,CAAC,EAAE,aAAF,EAAE,uBAAF,EAAE,CAAE,aAAa,CAAC,CAAC;GAC3C;EAEO,cAAc,CAAC,EAAe;;IAClC,IAAI,CAAC,EAAE,EAAE;MACL,OAAO,IAAI,CAAC;KACf;IAED,IACI,EAAE,CAAC,YAAY,CAAC,gBAAgB,CAAC,KAAK,IAAI;MAC1C,EAAE,CAAC,YAAY,CAAC,gBAAgB,CAAC,KAAK,OAAO,EAC/C;MACE,OAAO,EAAE,CAAC;KACb;IAED,IAAI,CAAA,MAAA,EAAE,aAAF,EAAE,uBAAF,EAAE,CAAE,OAAO,0CAAE,WAAW,EAAE,MAAK,aAAa,EAAE;MAC9C,OAAO,IAAI,CAAC;KACf;IAED,OAAO,IAAI,CAAC,cAAc,CAAC,EAAE,aAAF,EAAE,uBAAF,EAAE,CAAE,aAAa,CAAC,CAAC;GACjD;;;;;;;;;;","names":[],"sources":["./src/components/organisms/table/table.component.scss?tag=p-table","./src/components/organisms/table/table.component.tsx"],"sourcesContent":["p-table {\n @apply flex flex-col;\n\n .p-input[type='checkbox'] {\n flex-shrink: 0;\n }\n}\n","import {\n Component,\n Element,\n Event,\n EventEmitter,\n h,\n Host,\n Listen,\n Prop,\n State,\n Watch,\n} from '@stencil/core';\nimport { IconVariant } from '../../../components';\nimport { QuickFilter, RowClickEvent } from '../../../types/table';\nimport { formatTranslation, getLocaleComponentStrings } from '../../../utils';\nimport { TableColumn } from '../../helpers/table-column/table-column.component';\nimport {\n defaultSize,\n defaultSizeOptions,\n} from '../../molecules/page-size-select/constants';\nimport { buttonTemplateFunc } from '../../molecules/table-header/table-header.component';\n\nexport type templateFunc = () => string;\n\n@Component({\n tag: 'p-table',\n styleUrl: 'table.component.scss',\n})\nexport class Table {\n /**\n * The items to be fed to the table\n */\n @Prop() items: string;\n\n /**\n * Wether data is loading\n */\n @Prop() loading: boolean = false;\n\n /**\n * Wether the header should show loading state\n */\n @Prop() headerLoading: boolean = false;\n\n /**\n * Wether the footer should show loading state\n */\n @Prop() footerLoading: boolean = false;\n\n /**\n * The amount of loading rows to show\n */\n @Prop() amountOfLoadingRows: number = 6;\n\n /**\n * Wether to enable selection\n */\n @Prop() enableRowSelection: boolean = true;\n\n /**\n * Wether to enable row clicking\n */\n @Prop() enableRowClick: boolean = true;\n\n /**\n * The current selection of items\n */\n @Prop() selectedRows: any[] = [];\n\n /**\n * Event whenever the current selection changes\n */\n @Event({\n bubbles: false,\n })\n selectedRowsChange: EventEmitter<any>;\n\n /**\n * The key to determine if a row is selected\n */\n @Prop() selectionKey: string;\n\n /**\n * A key to determine if a row can be selected\n */\n @Prop() canSelectKey: string;\n\n /**\n * Event whenever a row is clicked\n */\n @Event({\n bubbles: false,\n })\n rowClick: EventEmitter<RowClickEvent>;\n\n /**\n * Event whenever a row is selected\n */\n @Event({\n bubbles: false,\n })\n rowSelected: EventEmitter<any>;\n\n /**\n * Event whenever a row is deselected\n */\n @Event({\n bubbles: false,\n })\n rowDeselected: EventEmitter<any>;\n\n /**\n * Event when the table has rendered\n */\n @Event({\n bubbles: false,\n })\n hasRendered: EventEmitter<number>;\n\n /** START HEADER */\n\n /**\n * Wether to show the header\n */\n @Prop() enableHeader: boolean = true;\n\n /**\n * Quick filters to show\n */\n @Prop() quickFilters: QuickFilter[] = [];\n\n /**\n * Active quick filter identifier\n */\n @Prop() activeQuickFilterIdentifier: string;\n\n /**\n * Wether to show the search input\n */\n @Prop() enableSearch: boolean = true;\n\n /**\n * The query to show in the search bar\n */\n @Prop({ mutable: true }) query: string;\n\n /**\n * Wether to show the filter button\n */\n @Prop() enableFilter: boolean = true;\n\n /**\n * The amount of filters being selected\n */\n @Prop() selectedFiltersAmount: number;\n\n /**\n * The template for the filter button text\n */\n @Prop() filterButtonTemplate: templateFunc;\n\n /**\n * Wether to show the edit button\n */\n @Prop() enableEdit: boolean = true;\n\n /**\n * Wether the edit button is loading\n */\n @Prop() editButtonLoading: boolean = false;\n\n /**\n * The edit button icon\n */\n @Prop() editButtonIcon: IconVariant = 'pencil';\n\n /**\n * The edit button text if changed\n */\n @Prop() editButtonText: string;\n\n /**\n * The template for the edit button text\n */\n @Prop() editButtonTemplate: buttonTemplateFunc;\n\n /**\n * Event when one of the quick filters is clicked\n */\n @Event({\n bubbles: false,\n })\n quickFilter: EventEmitter<QuickFilter>;\n\n /**\n * Event when the query changes\n */\n @Event({\n bubbles: false,\n })\n queryChange: EventEmitter<string>;\n\n /**\n * Event when the filter button is clicked\n */\n @Event({\n bubbles: false,\n })\n filter: EventEmitter<null>;\n\n /**\n * Event when the edit button is clicked\n */\n @Event({\n bubbles: false,\n })\n edit: EventEmitter<null>;\n\n /** START FOOTER */\n\n /**\n * Wether to show the header\n */\n @Prop() enableFooter: boolean = true;\n\n /**\n * Wether to enable page size select\n */\n @Prop() enablePageSize: boolean = true;\n\n /**\n * Wether to enable pagination\n */\n @Prop() enablePagination: boolean = true;\n\n /**\n * Wether to enable export\n */\n @Prop() enableExport: boolean = true;\n\n /**\n * The current page\n */\n @Prop({ mutable: true, reflect: true }) page: number = 1;\n\n /**\n * The total amount of items\n */\n @Prop() total!: number;\n\n /**\n * Event whenever the page changes\n */\n @Event({\n bubbles: false,\n })\n pageChange: EventEmitter<number>;\n\n /**\n * The amount of items per page\n */\n @Prop() pageSize: number = defaultSize;\n\n /**\n * The options for the page size\n */\n @Prop() pageSizeOptions: number[] = defaultSizeOptions;\n\n /**\n * Event whenever the page changes\n */\n @Event({\n bubbles: false,\n })\n pageSizeChange: EventEmitter<number>;\n\n /**\n * Event whenever the page changes\n */\n @Event({\n bubbles: false,\n })\n export: EventEmitter<number>;\n\n /**\n * Wether to hide when there is only 1 page available\n */\n @Prop() hideOnSinglePage: boolean = true;\n\n /* Empty state start */\n @Prop() emptyStateHeader: templateFunc = () =>\n formatTranslation(this._locales.empty_state?.no_filter.header);\n @Prop() emptyStateContent: templateFunc = () =>\n formatTranslation(this._locales.empty_state?.no_filter.content);\n @Prop() emptyStateAction: templateFunc = () =>\n formatTranslation(this._locales.empty_state?.no_filter.action);\n /**\n * Wether to enable empty state action\n */\n @Prop() enableEmptyStateAction: boolean = true;\n\n @Prop() emptyStateFilteredHeader: templateFunc = () =>\n formatTranslation(this._locales.empty_state.filtered.header);\n @Prop() emptyStateFilteredContent: templateFunc = () =>\n formatTranslation(this._locales.empty_state.filtered.content);\n\n /**\n * Event whenever the empty state is clicked\n */\n @Event({\n bubbles: false,\n })\n emptyStateActionClick: EventEmitter<null>;\n\n /* Empty state end */\n\n /**\n * The host element\n */\n @Element() private _el: HTMLElement;\n\n /**\n * Locales used for this component\n */\n @State() private _locales: any = {};\n\n @State() private _columns: any[] = [];\n @State() private _items: any[] = [];\n\n private _ctrlDown = false;\n private _hasCustomFilterSlot = false;\n\n componentWillLoad() {\n this._hasCustomFilterSlot = !!this._el.querySelector(\n ':scope > [slot=\"custom-filter\"]'\n );\n\n this._setLocales();\n this._parseItems(this.items);\n this._generateColumns();\n }\n\n componentDidRender() {\n this.hasRendered.emit();\n }\n\n render() {\n return (\n <Host class=\"p-table\">\n <p-table-container>\n {this.enableHeader && (\n <p-table-header\n // quick filters\n quickFilters={this.quickFilters}\n activeQuickFilterIdentifier={\n this.activeQuickFilterIdentifier\n }\n onQuickFilter={({ detail }) =>\n this.quickFilter.emit(detail)\n }\n // search\n enableSearch={this.enableSearch}\n query={this.query}\n onQueryChange={({ detail }) =>\n this.queryChange.emit(detail)\n }\n // filter button\n enableFilter={this.enableFilter}\n selectedFiltersAmount={this.selectedFiltersAmount}\n filterButtonTemplate={this.filterButtonTemplate}\n onFilter={() => this.filter.emit()}\n // edit button\n enableEdit={this.enableEdit}\n editIcon={this.editButtonIcon}\n editText={this.editButtonText}\n editLoading={this.editButtonLoading}\n canEdit={!!this.selectedRows?.length}\n editButtonTemplate={this.editButtonTemplate}\n onEdit={() => this.edit.emit()}\n itemsSelectedAmount={this.selectedRows?.length}\n //loading\n loading={this.headerLoading}\n >\n {this._hasCustomFilterSlot && (\n <slot\n name=\"custom-filter\"\n slot=\"custom-filter\"\n />\n )}\n </p-table-header>\n )}\n\n {this._getHeader()}\n <div class=\"flex flex-col\">{this._getRows()}</div>\n\n {this.enableFooter && (\n <p-table-footer\n // overall\n hideOnSinglePage={this.hideOnSinglePage}\n // page size select\n enablePageSize={this.enablePageSize}\n pageSize={this.pageSize}\n pageSizeOptions={this.pageSizeOptions}\n onPageSizeChange={({ detail }) =>\n this.pageSizeChange.emit(detail)\n }\n // pagination\n enablePagination={this.enablePagination}\n page={this.page}\n total={this.total}\n onPageChange={({ detail }) =>\n this.pageChange.emit(detail)\n }\n // export\n enableExport={this.enableExport}\n onExport={() => this.export.emit()}\n //loading\n loading={this.footerLoading}\n ></p-table-footer>\n )}\n </p-table-container>\n </Host>\n );\n }\n\n @Listen('localeChanged', { target: 'body' })\n private async _setLocales(): Promise<void> {\n this._locales = await getLocaleComponentStrings(this._el);\n }\n\n @Listen('tableDefinitionChanged', { target: 'body' })\n onTableDefinitionUpdated() {\n this._generateColumns();\n }\n\n @Listen('keydown', { target: 'document' })\n keyDown({ key }) {\n if (key !== 'Control' || this._ctrlDown === true) {\n return;\n }\n\n this._ctrlDown = true;\n }\n\n @Listen('keyup', { target: 'document' })\n keyUp({ key }) {\n if (key !== 'Control' || this._ctrlDown === false) {\n return;\n }\n\n this._ctrlDown = false;\n }\n\n @Listen('visibilitychange', { target: 'document' })\n visibilityChange() {\n if (document.visibilityState !== 'hidden' || this._ctrlDown === false) {\n return;\n }\n\n this._ctrlDown = false;\n }\n\n @Watch('items')\n private _parseItems(items: string) {\n if (!items) {\n this._items = [];\n return;\n }\n\n if (Array.isArray(items)) {\n this._items = items;\n return;\n }\n\n this._items = JSON.parse(items);\n }\n\n private _generateColumns() {\n const definitions = this._el.querySelectorAll('p-table-column');\n const definitionsArray = Array.from(definitions);\n\n definitionsArray[definitionsArray.length - 1]['isLast'] = true;\n\n this._columns = definitionsArray;\n }\n\n private _getHeader() {\n return (\n <p-table-row variant=\"header\">\n {this._columns.map((col: TableColumn, index) => (\n <p-table-cell\n definition={col}\n value={col.name}\n variant=\"header\"\n checkbox={\n index === 0 || col.hasCheckbox\n ? this._getCheckbox(null, 'loading')\n : null\n }\n index={index}\n ></p-table-cell>\n ))}\n </p-table-row>\n );\n }\n\n private _getRows() {\n if (this.loading) {\n return Array.from(\n {\n length: this.amountOfLoadingRows,\n },\n (_, i) => (\n <p-table-row\n enableHover={\n this.enableRowSelection || this.enableRowClick\n }\n >\n {this._getLoadingColumns(i)}\n </p-table-row>\n )\n );\n }\n\n if (!this._items.length) {\n return this._getEmptyState();\n }\n\n return this._items.map((item, index) => (\n <p-table-row\n enableHover={this.enableRowSelection || this.enableRowClick}\n onClick={(ev) => this._rowClick(ev, index)}\n >\n {this._getRowColumns(item, index)}\n </p-table-row>\n ));\n }\n\n private _getRowColumns(item, index) {\n return this._columns.map((col: TableColumn, colIndex) => {\n return (\n <p-table-cell\n definition={col}\n item={item}\n checkbox={\n colIndex === 0 || col.hasCheckbox\n ? this._getCheckbox(index)\n : null\n }\n index={colIndex}\n rowIndex={index}\n ></p-table-cell>\n );\n });\n }\n\n private _getLoadingColumns(index) {\n return this._columns.map((col: TableColumn, colIndex) => {\n return (\n <p-table-cell\n definition={col}\n variant=\"loading\"\n checkbox={\n colIndex === 0 || col.hasCheckbox\n ? this._getCheckbox(index, 'loading')\n : null\n }\n index={colIndex}\n rowIndex={index}\n ></p-table-cell>\n );\n });\n }\n\n private _getCheckbox(\n rowIndex,\n variant: 'header' | 'default' | 'loading' = 'default'\n ) {\n if (!this.enableRowSelection || !this.selectionKey) {\n return;\n }\n\n if (variant === 'loading') {\n return <p-loader variant=\"ghost\" class=\"h-6 w-6 rounded\" />;\n }\n\n if (variant === 'header') {\n return (\n <input\n class=\"p-input\"\n type=\"checkbox\"\n onChange={(ev) => this._selectAllChange(ev)}\n checked={this._selectionContainsAll()}\n indeterminate={this._selectionIndeterminate()}\n />\n );\n }\n\n const item = this._items[rowIndex];\n\n return (\n <input\n class=\"p-input\"\n type=\"checkbox\"\n onChange={(ev) => this._checkboxChange(ev?.target, rowIndex)}\n disabled={this.canSelectKey && !item[this.canSelectKey]}\n checked={this._selectionContains(item, rowIndex)}\n />\n );\n }\n\n private _getEmptyState() {\n if (this.query?.length || this.selectedFiltersAmount) {\n return (\n <div class=\"flex max-w-[20rem] flex-col items-center self-center py-24 text-center\">\n <p-illustration variant=\"empty-state-search\" class=\"mb-6\" />\n <p class=\"text-storm-default font-semibold\">\n {this.emptyStateFilteredHeader()}\n </p>\n <p class=\"mb-14 text-sm text-storm-medium\">\n {this.emptyStateFilteredContent()}\n </p>\n </div>\n );\n }\n\n return (\n <div\n class={`flex max-w-[20rem] flex-col items-center self-center py-24 text-center ${\n this.enableEmptyStateAction && 'cursor-pointer'\n }`}\n onClick={() =>\n this.enableEmptyStateAction &&\n this.emptyStateActionClick.emit(null)\n }\n >\n <p-illustration variant=\"empty-state-add\" class=\"mb-6\" />\n <p class=\"text-storm-default font-semibold\">\n {this.emptyStateHeader()}\n </p>\n <p class=\"mb-6 text-sm text-storm-medium\">\n {this.emptyStateContent()}\n </p>\n {this.enableEmptyStateAction && (\n <p-button variant=\"secondary\" icon=\"plus\" size=\"small\">\n {this.emptyStateAction()}\n </p-button>\n )}\n </div>\n );\n }\n\n private _selectAllChange($event: any) {\n if (!this.enableRowSelection) {\n return;\n }\n\n const value = this._getCheckedValue($event.target);\n if (value) {\n const toAdd = [];\n for (let i = 0; i < this._items.length; i++) {\n const row = this._items[i];\n if (this.canSelectKey && !row[this.canSelectKey]) {\n continue;\n }\n\n if (this._selectionContains(row, i)) {\n continue;\n }\n\n toAdd.push(row);\n this.rowSelected.emit(row);\n }\n\n this.selectedRows = [...this.selectedRows, ...toAdd];\n this.selectedRowsChange.emit(this.selectedRows);\n return;\n }\n\n for (let i = 0; i < this.selectedRows.length; i++) {\n const value = this.selectedRows[i];\n const row = this._items.find(\n (d) =>\n this._getSelectionValue(d, i) ===\n this._getSelectionValue(value, i)\n );\n\n if (!row) {\n continue;\n }\n\n this.rowDeselected.emit(row);\n }\n\n this.selectedRows = [];\n this.selectedRowsChange.emit(this.selectedRows);\n }\n\n private _checkboxChange(target: any, index: number) {\n if (!this.enableRowSelection) {\n return;\n }\n\n const row = this._items[index];\n\n if (this.canSelectKey && !row[this.canSelectKey]) {\n target.checked = false;\n return;\n }\n\n const value = this._getCheckedValue(target);\n if (value) {\n this.selectedRows = [...this.selectedRows, row];\n this.selectedRowsChange.emit(this.selectedRows);\n this.rowSelected.emit(row);\n return;\n }\n\n const indexOfToRemove = this._selectionContains(row, index, true);\n\n // we need to do this, because splice does not trigger the selection setter.\n const selection = [...this.selectedRows];\n selection.splice(indexOfToRemove, 1);\n this.selectedRows = selection;\n this.selectedRowsChange.emit(this.selectedRows);\n this.rowDeselected.emit(row);\n }\n\n private _getCheckedValue(target: any) {\n return target?.checked;\n }\n\n private _getSelectionValue(row: any, index: number) {\n return this.selectionKey ? row?.[this.selectionKey] || index : index;\n }\n\n private _selectionContains(row, index, returnIndex = false): any {\n const returnValue = this.selectedRows.findIndex(\n (item) =>\n this._getSelectionValue(row, index) ===\n this._getSelectionValue(item, index)\n );\n return !returnIndex ? returnValue >= 0 : returnValue;\n }\n\n private _selectionContainsAll() {\n let returnValue = true;\n if (!this._items?.length) {\n return false;\n }\n\n for (let i = 0; i < this._items?.length; i++) {\n const item = this._items[i];\n const contains = this._selectionContains(item, i);\n\n if (!contains) {\n returnValue = false;\n break;\n }\n }\n\n return returnValue;\n }\n\n private _selectionIndeterminate() {\n if (!this._items?.length || !this.selectedRows?.length) {\n return false;\n }\n\n let containsCount = 0;\n for (let i = 0; i < this._items?.length; i++) {\n const item = this._items[i];\n const contains = this._selectionContains(item, i);\n\n if (contains) {\n containsCount++;\n }\n }\n\n return containsCount > 0 && containsCount !== this._items.length;\n }\n\n private _rowClick($event, index) {\n const target = $event.target;\n\n if (\n target.tagName.toLowerCase() === 'input' ||\n target.type === 'checkbox'\n ) {\n return;\n }\n\n const row = this._findRow($event.target);\n const action = this._findRowAction($event.target);\n\n if (action) {\n return;\n }\n\n if (this.enableRowClick) {\n const item = this._items[index];\n this.rowClick.emit({\n item,\n ctrlDown: this._ctrlDown,\n });\n return;\n }\n\n if (!this.enableRowSelection) {\n return;\n }\n\n const checkbox = row?.querySelector('input[type=\"checkbox\"]');\n\n if (!checkbox) {\n return;\n }\n\n checkbox.checked = !checkbox.checked;\n this._checkboxChange(checkbox, index);\n }\n\n private _findRow(el: HTMLElement) {\n if (!el) {\n return el;\n }\n\n if (el?.tagName?.toLowerCase() === 'p-table-row') {\n return el;\n }\n\n return this._findRow(el?.parentElement);\n }\n\n private _findRowAction(el: HTMLElement) {\n if (!el) {\n return null;\n }\n\n if (\n el.getAttribute('data-is-action') !== null &&\n el.getAttribute('data-is-action') !== 'false'\n ) {\n return el;\n }\n\n if (el?.tagName?.toLowerCase() === 'p-table-row') {\n return null;\n }\n\n return this._findRowAction(el?.parentElement);\n }\n}\n"],"version":3}
|
|
1
|
+
{"file":"p-table.entry.js","mappings":";;;;AAAA,MAAM,iBAAiB,GAAG,2/VAA2/V;;MC4BxgW,KAAK;;;;;;;;;;;;;;;;IA6SN,cAAS,GAAG,KAAK,CAAC;IAClB,yBAAoB,GAAG,KAAK,CAAC;;mBArSV,KAAK;yBAKC,KAAK;yBAKL,KAAK;+BAKA,CAAC;8BAKD,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ACb;IAED,OAAO,IAAI,CAAC,QAAQ,CAAC,EAAE,aAAF,EAAE,uBAAF,EAAE,CAAE,aAAa,CAAC,CAAC;GAC3C;EAEO,cAAc,CAAC,EAAe;;IAClC,IAAI,CAAC,EAAE,EAAE;MACL,OAAO,IAAI,CAAC;KACf;IAED,IACI,EAAE,CAAC,YAAY,CAAC,gBAAgB,CAAC,KAAK,IAAI;MAC1C,EAAE,CAAC,YAAY,CAAC,gBAAgB,CAAC,KAAK,OAAO,EAC/C;MACE,OAAO,EAAE,CAAC;KACb;IAED,IAAI,CAAA,MAAA,EAAE,aAAF,EAAE,uBAAF,EAAE,CAAE,OAAO,0CAAE,WAAW,EAAE,MAAK,aAAa,EAAE;MAC9C,OAAO,IAAI,CAAC;KACf;IAED,OAAO,IAAI,CAAC,cAAc,CAAC,EAAE,aAAF,EAAE,uBAAF,EAAE,CAAE,aAAa,CAAC,CAAC;GACjD;;;;;;;;;;","names":[],"sources":["./src/components/organisms/table/table.component.scss?tag=p-table","./src/components/organisms/table/table.component.tsx"],"sourcesContent":["p-table {\n @apply flex flex-col;\n\n .p-input[type='checkbox'] {\n flex-shrink: 0;\n }\n}\n","import {\n Component,\n Element,\n Event,\n EventEmitter,\n h,\n Host,\n Listen,\n Prop,\n State,\n Watch,\n} from '@stencil/core';\nimport { IconVariant } from '../../../components';\nimport { QuickFilter, RowClickEvent } from '../../../types/table';\nimport { formatTranslation, getLocaleComponentStrings } from '../../../utils';\nimport { TableColumn } from '../../helpers/table-column/table-column.component';\nimport {\n defaultSize,\n defaultSizeOptions,\n} from '../../molecules/page-size-select/constants';\nimport { buttonTemplateFunc } from '../../molecules/table-header/table-header.component';\n\nexport type templateFunc = () => string;\n\n@Component({\n tag: 'p-table',\n styleUrl: 'table.component.scss',\n})\nexport class Table {\n /**\n * The items to be fed to the table\n */\n @Prop() items: string;\n\n /**\n * Wether data is loading\n */\n @Prop() loading: boolean = false;\n\n /**\n * Wether the header should show loading state\n */\n @Prop() headerLoading: boolean = false;\n\n /**\n * Wether the footer should show loading state\n */\n @Prop() footerLoading: boolean = false;\n\n /**\n * The amount of loading rows to show\n */\n @Prop() amountOfLoadingRows: number = 6;\n\n /**\n * Wether to enable selection\n */\n @Prop() enableRowSelection: boolean = true;\n\n /**\n * Wether to enable row clicking\n */\n @Prop() enableRowClick: boolean = true;\n\n /**\n * The current selection of items\n */\n @Prop() selectedRows: any[] = [];\n\n /**\n * Event whenever the current selection changes\n */\n @Event({\n bubbles: false,\n })\n selectedRowsChange: EventEmitter<any>;\n\n /**\n * The key to determine if a row is selected\n */\n @Prop() selectionKey: string;\n\n /**\n * A key to determine if a row can be selected\n */\n @Prop() canSelectKey: string;\n\n /**\n * Event whenever a row is clicked\n */\n @Event({\n bubbles: false,\n })\n rowClick: EventEmitter<RowClickEvent>;\n\n /**\n * Event whenever a row is selected\n */\n @Event({\n bubbles: false,\n })\n rowSelected: EventEmitter<any>;\n\n /**\n * Event whenever a row is deselected\n */\n @Event({\n bubbles: false,\n })\n rowDeselected: EventEmitter<any>;\n\n /**\n * Event when the table has rendered\n */\n @Event({\n bubbles: false,\n })\n hasRendered: EventEmitter<number>;\n\n /** START HEADER */\n\n /**\n * Wether to show the header\n */\n @Prop() enableHeader: boolean = true;\n\n /**\n * Quick filters to show\n */\n @Prop() quickFilters: QuickFilter[] = [];\n\n /**\n * Active quick filter identifier\n */\n @Prop() activeQuickFilterIdentifier: string;\n\n /**\n * Wether to show the search input\n */\n @Prop() enableSearch: boolean = true;\n\n /**\n * The query to show in the search bar\n */\n @Prop({ mutable: true }) query: string;\n\n /**\n * Wether to show the filter button\n */\n @Prop() enableFilter: boolean = true;\n\n /**\n * The amount of filters being selected\n */\n @Prop() selectedFiltersAmount: number;\n\n /**\n * The template for the filter button text\n */\n @Prop() filterButtonTemplate: templateFunc;\n\n /**\n * Wether to show the edit button\n */\n @Prop() enableEdit: boolean = true;\n\n /**\n * Wether the edit button is loading\n */\n @Prop() editButtonLoading: boolean = false;\n\n /**\n * The edit button icon\n */\n @Prop() editButtonIcon: IconVariant = 'pencil';\n\n /**\n * The edit button text if changed\n */\n @Prop() editButtonText: string;\n\n /**\n * The template for the edit button text\n */\n @Prop() editButtonTemplate: buttonTemplateFunc;\n\n /**\n * Event when one of the quick filters is clicked\n */\n @Event({\n bubbles: false,\n })\n quickFilter: EventEmitter<QuickFilter>;\n\n /**\n * Event when the query changes\n */\n @Event({\n bubbles: false,\n })\n queryChange: EventEmitter<string>;\n\n /**\n * Event when the filter button is clicked\n */\n @Event({\n bubbles: false,\n })\n filter: EventEmitter<null>;\n\n /**\n * Event when the edit button is clicked\n */\n @Event({\n bubbles: false,\n })\n edit: EventEmitter<null>;\n\n /** START FOOTER */\n\n /**\n * Wether to show the header\n */\n @Prop() enableFooter: boolean = true;\n\n /**\n * Wether to enable page size select\n */\n @Prop() enablePageSize: boolean = true;\n\n /**\n * Wether to enable pagination\n */\n @Prop() enablePagination: boolean = true;\n\n /**\n * Wether to enable export\n */\n @Prop() enableExport: boolean = true;\n\n /**\n * The current page\n */\n @Prop({ mutable: true, reflect: true }) page: number = 1;\n\n /**\n * The total amount of items\n */\n @Prop() total!: number;\n\n /**\n * Event whenever the page changes\n */\n @Event({\n bubbles: false,\n })\n pageChange: EventEmitter<number>;\n\n /**\n * The amount of items per page\n */\n @Prop() pageSize: number = defaultSize;\n\n /**\n * The options for the page size\n */\n @Prop() pageSizeOptions: number[] = defaultSizeOptions;\n\n /**\n * Event whenever the page changes\n */\n @Event({\n bubbles: false,\n })\n pageSizeChange: EventEmitter<number>;\n\n /**\n * Event whenever the page changes\n */\n @Event({\n bubbles: false,\n })\n export: EventEmitter<number>;\n\n /**\n * Wether to hide when there is only 1 page available\n */\n @Prop() hideOnSinglePage: boolean = true;\n\n /* Empty state start */\n @Prop() emptyStateHeader: templateFunc = () =>\n formatTranslation(this._locales.empty_state?.no_filter.header);\n @Prop() emptyStateContent: templateFunc = () =>\n formatTranslation(this._locales.empty_state?.no_filter.content);\n @Prop() emptyStateAction: templateFunc = () =>\n formatTranslation(this._locales.empty_state?.no_filter.action);\n /**\n * Wether to enable empty state action\n */\n @Prop() enableEmptyStateAction: boolean = true;\n\n @Prop() emptyStateFilteredHeader: templateFunc = () =>\n formatTranslation(this._locales.empty_state.filtered.header);\n @Prop() emptyStateFilteredContent: templateFunc = () =>\n formatTranslation(this._locales.empty_state.filtered.content);\n\n /**\n * Event whenever the empty state is clicked\n */\n @Event({\n bubbles: false,\n })\n emptyStateActionClick: EventEmitter<null>;\n\n /* Empty state end */\n\n /**\n * The host element\n */\n @Element() private _el: HTMLElement;\n\n /**\n * Locales used for this component\n */\n @State() private _locales: any = {};\n\n @State() private _columns: any[] = [];\n @State() private _items: any[] = [];\n\n private _ctrlDown = false;\n private _hasCustomFilterSlot = false;\n\n componentWillLoad() {\n this._hasCustomFilterSlot = !!this._el.querySelector(\n ':scope > [slot=\"custom-filter\"]'\n );\n\n this._setLocales();\n this._parseItems(this.items);\n this._generateColumns();\n }\n\n componentDidRender() {\n this.hasRendered.emit();\n }\n\n render() {\n return (\n <Host class=\"p-table\">\n <p-table-container>\n {this.enableHeader && (\n <p-table-header\n // quick filters\n quickFilters={this.quickFilters}\n activeQuickFilterIdentifier={\n this.activeQuickFilterIdentifier\n }\n onQuickFilter={({ detail }) =>\n this.quickFilter.emit(detail)\n }\n // search\n enableSearch={this.enableSearch}\n query={this.query}\n onQueryChange={({ detail }) =>\n this.queryChange.emit(detail)\n }\n // filter button\n enableFilter={this.enableFilter}\n selectedFiltersAmount={this.selectedFiltersAmount}\n filterButtonTemplate={this.filterButtonTemplate}\n onFilter={() => this.filter.emit()}\n // edit button\n enableEdit={this.enableEdit}\n editIcon={this.editButtonIcon}\n editText={this.editButtonText}\n editLoading={this.editButtonLoading}\n canEdit={!!this.selectedRows?.length}\n editButtonTemplate={this.editButtonTemplate}\n onEdit={() => this.edit.emit()}\n itemsSelectedAmount={this.selectedRows?.length}\n //loading\n loading={this.headerLoading}\n >\n {this._hasCustomFilterSlot && (\n <slot\n name=\"custom-filter\"\n slot=\"custom-filter\"\n />\n )}\n </p-table-header>\n )}\n\n {this._getHeader()}\n <div class=\"flex flex-col\">{this._getRows()}</div>\n\n {this.enableFooter && (\n <p-table-footer\n // overall\n hideOnSinglePage={this.hideOnSinglePage}\n // page size select\n enablePageSize={this.enablePageSize}\n pageSize={this.pageSize}\n pageSizeOptions={this.pageSizeOptions}\n onPageSizeChange={({ detail }) =>\n this.pageSizeChange.emit(detail)\n }\n // pagination\n enablePagination={this.enablePagination}\n page={this.page}\n total={this.total}\n onPageChange={({ detail }) =>\n this.pageChange.emit(detail)\n }\n // export\n enableExport={this.enableExport}\n onExport={() => this.export.emit()}\n //loading\n loading={this.footerLoading}\n ></p-table-footer>\n )}\n </p-table-container>\n </Host>\n );\n }\n\n @Listen('localeChanged', { target: 'body' })\n private async _setLocales(): Promise<void> {\n this._locales = await getLocaleComponentStrings(this._el);\n }\n\n @Listen('tableDefinitionChanged', { target: 'body' })\n onTableDefinitionUpdated() {\n this._generateColumns();\n }\n\n @Listen('keydown', { target: 'document' })\n keyDown({ key }) {\n if (key !== 'Control' || this._ctrlDown === true) {\n return;\n }\n\n this._ctrlDown = true;\n }\n\n @Listen('keyup', { target: 'document' })\n keyUp({ key }) {\n if (key !== 'Control' || this._ctrlDown === false) {\n return;\n }\n\n this._ctrlDown = false;\n }\n\n @Listen('visibilitychange', { target: 'document' })\n visibilityChange() {\n if (document.visibilityState !== 'hidden' || this._ctrlDown === false) {\n return;\n }\n\n this._ctrlDown = false;\n }\n\n @Watch('items')\n private _parseItems(items: string) {\n if (!items) {\n this._items = [];\n return;\n }\n\n if (Array.isArray(items)) {\n this._items = items;\n return;\n }\n\n this._items = JSON.parse(items);\n }\n\n private _generateColumns() {\n const definitions = this._el.querySelectorAll('p-table-column');\n const definitionsArray = Array.from(definitions);\n\n definitionsArray[definitionsArray.length - 1]['isLast'] = true;\n\n this._columns = definitionsArray;\n }\n\n private _getHeader() {\n return (\n <p-table-row variant=\"header\">\n {this._columns.map((col: TableColumn, index) => (\n <p-table-cell\n definition={col}\n value={col.name}\n variant=\"header\"\n checkbox={\n index === 0 || col.hasCheckbox\n ? this._getCheckbox(null, 'loading')\n : null\n }\n index={index}\n ></p-table-cell>\n ))}\n </p-table-row>\n );\n }\n\n private _getRows() {\n if (this.loading) {\n return Array.from(\n {\n length: this.amountOfLoadingRows,\n },\n (_, i) => (\n <p-table-row\n enableHover={\n this.enableRowSelection || this.enableRowClick\n }\n >\n {this._getLoadingColumns(i)}\n </p-table-row>\n )\n );\n }\n\n if (!this._items.length) {\n return this._getEmptyState();\n }\n\n return this._items.map((item, index) => (\n <p-table-row\n enableHover={this.enableRowSelection || this.enableRowClick}\n onClick={(ev) => this._rowClick(ev, index)}\n >\n {this._getRowColumns(item, index)}\n </p-table-row>\n ));\n }\n\n private _getRowColumns(item, index) {\n return this._columns.map((col: TableColumn, colIndex) => {\n return (\n <p-table-cell\n definition={col}\n item={item}\n checkbox={\n colIndex === 0 || col.hasCheckbox\n ? this._getCheckbox(index)\n : null\n }\n index={colIndex}\n rowIndex={index}\n ></p-table-cell>\n );\n });\n }\n\n private _getLoadingColumns(index) {\n return this._columns.map((col: TableColumn, colIndex) => {\n return (\n <p-table-cell\n definition={col}\n variant=\"loading\"\n checkbox={\n colIndex === 0 || col.hasCheckbox\n ? this._getCheckbox(index, 'loading')\n : null\n }\n index={colIndex}\n rowIndex={index}\n ></p-table-cell>\n );\n });\n }\n\n private _getCheckbox(\n rowIndex,\n variant: 'header' | 'default' | 'loading' = 'default'\n ) {\n if (!this.enableRowSelection || !this.selectionKey) {\n return;\n }\n\n if (variant === 'loading') {\n return <p-loader variant=\"ghost\" class=\"h-6 w-6 rounded\" />;\n }\n\n if (variant === 'header') {\n return (\n <input\n class=\"p-input\"\n type=\"checkbox\"\n onChange={(ev) => this._selectAllChange(ev)}\n checked={this._selectionContainsAll()}\n indeterminate={this._selectionIndeterminate()}\n />\n );\n }\n\n const item = this._items[rowIndex];\n\n return (\n <input\n class=\"p-input\"\n type=\"checkbox\"\n onChange={(ev) => this._checkboxChange(ev?.target, rowIndex)}\n disabled={this.canSelectKey && !item[this.canSelectKey]}\n checked={this._selectionContains(item, rowIndex)}\n />\n );\n }\n\n private _getEmptyState() {\n if (this.query?.length || this.selectedFiltersAmount) {\n return (\n <div class=\"flex max-w-[20rem] flex-col items-center self-center py-24 text-center\">\n <p-illustration variant=\"empty-state-search\" class=\"mb-6\" />\n <p class=\"text-storm-default font-semibold\">\n {this.emptyStateFilteredHeader()}\n </p>\n <p class=\"mb-14 text-sm text-storm-medium\">\n {this.emptyStateFilteredContent()}\n </p>\n </div>\n );\n }\n\n return (\n <div\n class={`flex max-w-[20rem] flex-col items-center self-center py-24 text-center ${\n this.enableEmptyStateAction && 'cursor-pointer'\n }`}\n onClick={() =>\n this.enableEmptyStateAction &&\n this.emptyStateActionClick.emit(null)\n }\n >\n <p-illustration variant=\"empty-state-add\" class=\"mb-6\" />\n <p class=\"text-storm-default font-semibold\">\n {this.emptyStateHeader()}\n </p>\n <p class=\"mb-6 text-sm text-storm-medium\">\n {this.emptyStateContent()}\n </p>\n {this.enableEmptyStateAction && (\n <p-button variant=\"secondary\" icon=\"plus\" size=\"small\">\n {this.emptyStateAction()}\n </p-button>\n )}\n </div>\n );\n }\n\n private _selectAllChange($event: any) {\n if (!this.enableRowSelection) {\n return;\n }\n\n const value = this._getCheckedValue($event.target);\n if (value) {\n const toAdd = [];\n for (let i = 0; i < this._items.length; i++) {\n const row = this._items[i];\n if (this.canSelectKey && !row[this.canSelectKey]) {\n continue;\n }\n\n if (this._selectionContains(row, i)) {\n continue;\n }\n\n toAdd.push(row);\n this.rowSelected.emit(row);\n }\n\n this.selectedRows = [...this.selectedRows, ...toAdd];\n this.selectedRowsChange.emit(this.selectedRows);\n return;\n }\n\n for (let i = 0; i < this.selectedRows.length; i++) {\n const value = this.selectedRows[i];\n const row = this._items.find(\n (d) =>\n this._getSelectionValue(d, i) ===\n this._getSelectionValue(value, i)\n );\n\n if (!row) {\n continue;\n }\n\n this.rowDeselected.emit(row);\n }\n\n this.selectedRows = [];\n this.selectedRowsChange.emit(this.selectedRows);\n }\n\n private _checkboxChange(target: any, index: number) {\n if (!this.enableRowSelection) {\n return;\n }\n\n const row = this._items[index];\n\n if (this.canSelectKey && !row[this.canSelectKey]) {\n target.checked = false;\n return;\n }\n\n const value = this._getCheckedValue(target);\n if (value) {\n this.selectedRows = [...this.selectedRows, row];\n this.selectedRowsChange.emit(this.selectedRows);\n this.rowSelected.emit(row);\n return;\n }\n\n const indexOfToRemove = this._selectionContains(row, index, true);\n\n // we need to do this, because splice does not trigger the selection setter.\n const selection = [...this.selectedRows];\n selection.splice(indexOfToRemove, 1);\n this.selectedRows = selection;\n this.selectedRowsChange.emit(this.selectedRows);\n this.rowDeselected.emit(row);\n }\n\n private _getCheckedValue(target: any) {\n return target?.checked;\n }\n\n private _getSelectionValue(row: any, index: number) {\n return this.selectionKey ? row?.[this.selectionKey] || index : index;\n }\n\n private _selectionContains(row, index, returnIndex = false): any {\n const returnValue = this.selectedRows.findIndex(\n (item) =>\n this._getSelectionValue(row, index) ===\n this._getSelectionValue(item, index)\n );\n return !returnIndex ? returnValue >= 0 : returnValue;\n }\n\n private _selectionContainsAll() {\n let returnValue = true;\n if (!this._items?.length) {\n return false;\n }\n\n for (let i = 0; i < this._items?.length; i++) {\n const item = this._items[i];\n const contains = this._selectionContains(item, i);\n\n if (!contains) {\n returnValue = false;\n break;\n }\n }\n\n return returnValue;\n }\n\n private _selectionIndeterminate() {\n if (!this._items?.length || !this.selectedRows?.length) {\n return false;\n }\n\n let containsCount = 0;\n for (let i = 0; i < this._items?.length; i++) {\n const item = this._items[i];\n const contains = this._selectionContains(item, i);\n\n if (contains) {\n containsCount++;\n }\n }\n\n return containsCount > 0 && containsCount !== this._items.length;\n }\n\n private _rowClick($event, index) {\n const target = $event.target;\n\n if (\n target.tagName.toLowerCase() === 'input' ||\n target.type === 'checkbox'\n ) {\n return;\n }\n\n const row = this._findRow($event.target);\n const action = this._findRowAction($event.target);\n\n if (action) {\n return;\n }\n\n if (this.enableRowClick) {\n const item = this._items[index];\n this.rowClick.emit({\n item,\n ctrlDown: this._ctrlDown,\n });\n return;\n }\n\n if (!this.enableRowSelection) {\n return;\n }\n\n const checkbox = row?.querySelector('input[type=\"checkbox\"]');\n\n if (!checkbox) {\n return;\n }\n\n checkbox.checked = !checkbox.checked;\n this._checkboxChange(checkbox, index);\n }\n\n private _findRow(el: HTMLElement) {\n if (!el) {\n return el;\n }\n\n if (el?.tagName?.toLowerCase() === 'p-table-row') {\n return el;\n }\n\n return this._findRow(el?.parentElement);\n }\n\n private _findRowAction(el: HTMLElement) {\n if (!el) {\n return null;\n }\n\n if (\n el.getAttribute('data-is-action') !== null &&\n el.getAttribute('data-is-action') !== 'false'\n ) {\n return el;\n }\n\n if (el?.tagName?.toLowerCase() === 'p-table-row') {\n return null;\n }\n\n return this._findRowAction(el?.parentElement);\n }\n}\n"],"version":3}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { r as registerInstance, c as createEvent, h, H as Host } from './index-2c1bdb40.js';
|
|
2
2
|
|
|
3
|
-
const toastComponentCss = ".flex{display:flex!important}.w-full{width:100%!important}.items-center{align-items:center!important}.justify-between{justify-content:space-between!important}.overflow-hidden{overflow:hidden!important}.text-ellipsis{text-overflow:ellipsis!important}.rounded{border-radius:.25rem!important}.border-l-4{border-left-width:4px!important}.border-solid{border-style:solid!important}.border-l-negative{--tw-border-opacity:1!important;border-left-color:rgb(185 30 40/var(--tw-border-opacity))!important}.border-l-positive{--tw-border-opacity:1!important;border-left-color:rgb(40 209 124/var(--tw-border-opacity))!important}.border-l-unbiased{--tw-border-opacity:1!important;border-left-color:rgb(255 199 45/var(--tw-border-opacity))!important}.bg-white{--tw-bg-opacity:1!important;background-color:rgb(255 255 255/var(--tw-bg-opacity))!important}.p-4{padding:1rem!important}.shadow-4{--tw-shadow:0px 0.3125rem 1rem rgba(0,24,98,.08),0px 0.0625rem 0.1875rem rgba(0,24,98,.13)!important;--tw-shadow-colored:0px 0.3125rem 1rem var(--tw-shadow-color),0px 0.0625rem 0.1875rem var(--tw-shadow-color)!important;box-shadow:var(--tw-ring-offset-shadow,0 0 #0000),var(--tw-ring-shadow,0 0 #0000),var(--tw-shadow)!important}*{box-sizing:border-box}:host{--tw-bg-opacity:1;--tw-shadow:0px 0.3125rem 1rem rgba(0,24,98,.08),0px 0.0625rem 0.1875rem rgba(0,24,98,.13)!important;--tw-shadow-colored:0px 0.3125rem 1rem var(--tw-shadow-color),0px 0.0625rem 0.1875rem var(--tw-shadow-color)!important;align-items:center;background-color:rgb(255 255 255/var(--tw-bg-opacity));border-left-width:4px!important;border-radius:.25rem;border-style:solid!important;box-shadow:var(--tw-ring-offset-shadow,0 0 #0000),var(--tw-ring-shadow,0 0 #0000),var(--tw-shadow)!important;box-sizing:border-box;display:flex;gap:.5rem;justify-content:space-between;padding:1rem 1rem 1rem 1.25rem;width:100%}:host p{margin:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}:host(.variant-positive){--tw-border-opacity:1!important;border-left-color:rgb(40 209 124/var(--tw-border-opacity))!important}:host(.variant-unbiased){--tw-border-opacity:1!important;border-left-color:rgb(255 199 45/var(--tw-border-opacity))!important}:host(.variant-negative){--tw-border-opacity:1!important;border-left-color:rgb(185 30 40/var(--tw-border-opacity))!important}.static{position:static!important}.min-w-0{min-width:0!important}.flex-shrink-0{flex-shrink:0!important}.flex-col{flex-direction:column!important}.text-sm{font-size:.875rem!important;line-height:1.25rem!important}.font-semibold{font-weight:600!important}.text-storm{--tw-text-opacity:1!important;color:rgb(81 83 107/var(--tw-text-opacity))!important}.text-storm-medium{--tw-text-opacity:1!important;color:rgb(128 130 158/var(--tw-text-opacity))!important}.inline{display:inline!important}.justify-center{justify-content:center!important}.text-4xl{font-size:2.25rem!important;line-height:2.5rem!important}";
|
|
3
|
+
const toastComponentCss = ".flex{display:flex!important}.w-full{width:100%!important}.items-center{align-items:center!important}.justify-between{justify-content:space-between!important}.overflow-hidden{overflow:hidden!important}.text-ellipsis{text-overflow:ellipsis!important}.rounded{border-radius:.25rem!important}.border-l-4{border-left-width:4px!important}.border-solid{border-style:solid!important}.border-l-negative{--tw-border-opacity:1!important;border-left-color:rgb(185 30 40/var(--tw-border-opacity))!important}.border-l-positive{--tw-border-opacity:1!important;border-left-color:rgb(40 209 124/var(--tw-border-opacity))!important}.border-l-unbiased{--tw-border-opacity:1!important;border-left-color:rgb(255 199 45/var(--tw-border-opacity))!important}.bg-white{--tw-bg-opacity:1!important;background-color:rgb(255 255 255/var(--tw-bg-opacity))!important}.p-4{padding:1rem!important}.shadow-4{--tw-shadow:0px 0.3125rem 1rem rgba(0,24,98,.08),0px 0.0625rem 0.1875rem rgba(0,24,98,.13)!important;--tw-shadow-colored:0px 0.3125rem 1rem var(--tw-shadow-color),0px 0.0625rem 0.1875rem var(--tw-shadow-color)!important;box-shadow:var(--tw-ring-offset-shadow,0 0 #0000),var(--tw-ring-shadow,0 0 #0000),var(--tw-shadow)!important}*{box-sizing:border-box}:host{--tw-bg-opacity:1;--tw-shadow:0px 0.3125rem 1rem rgba(0,24,98,.08),0px 0.0625rem 0.1875rem rgba(0,24,98,.13)!important;--tw-shadow-colored:0px 0.3125rem 1rem var(--tw-shadow-color),0px 0.0625rem 0.1875rem var(--tw-shadow-color)!important;align-items:center;background-color:rgb(255 255 255/var(--tw-bg-opacity));border-left-width:4px!important;border-radius:.25rem;border-style:solid!important;box-shadow:var(--tw-ring-offset-shadow,0 0 #0000),var(--tw-ring-shadow,0 0 #0000),var(--tw-shadow)!important;box-sizing:border-box;display:flex;gap:.5rem;justify-content:space-between;padding:1rem 1rem 1rem 1.25rem;width:100%}:host p{margin:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}:host(.variant-positive){--tw-border-opacity:1!important;border-left-color:rgb(40 209 124/var(--tw-border-opacity))!important}:host(.variant-unbiased){--tw-border-opacity:1!important;border-left-color:rgb(255 199 45/var(--tw-border-opacity))!important}:host(.variant-negative){--tw-border-opacity:1!important;border-left-color:rgb(185 30 40/var(--tw-border-opacity))!important}.static{position:static!important}.min-w-0{min-width:0!important}.flex-shrink-0{flex-shrink:0!important}.flex-col{flex-direction:column!important}.text-sm{font-size:.875rem!important;line-height:1.25rem!important}.font-semibold{font-weight:600!important}.text-storm{--tw-text-opacity:1!important;color:rgb(81 83 107/var(--tw-text-opacity))!important}.text-storm-medium{--tw-text-opacity:1!important;color:rgb(128 130 158/var(--tw-text-opacity))!important}.inline{display:inline!important}.justify-center{justify-content:center!important}.text-4xl{font-size:2.25rem!important;line-height:2.5rem!important}.-rotate-0{--tw-rotate:-0deg!important}.-rotate-0,.-rotate-135{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))!important}.-rotate-135{--tw-rotate:-135deg!important}.-rotate-180{--tw-rotate:-180deg!important}.-rotate-180,.-rotate-225{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))!important}.-rotate-225{--tw-rotate:-225deg!important}.-rotate-25{--tw-rotate:-25deg!important}.-rotate-25,.-rotate-270{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))!important}.-rotate-270{--tw-rotate:-270deg!important}.-rotate-315{--tw-rotate:-315deg!important}.-rotate-315,.-rotate-45{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))!important}.-rotate-45{--tw-rotate:-45deg!important}.-rotate-90{--tw-rotate:-90deg!important}.-rotate-90,.rotate-0{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))!important}.rotate-0{--tw-rotate:0deg!important}.rotate-135{--tw-rotate:135deg!important}.rotate-135,.rotate-180{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))!important}.rotate-180{--tw-rotate:180deg!important}.rotate-225{--tw-rotate:225deg!important}.rotate-225,.rotate-25{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))!important}.rotate-25{--tw-rotate:25deg!important}.rotate-270{--tw-rotate:270deg!important}.rotate-270,.rotate-315{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))!important}.rotate-315{--tw-rotate:315deg!important}.rotate-45{--tw-rotate:45deg!important}.rotate-45,.rotate-90{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))!important}.rotate-90{--tw-rotate:90deg!important}.scale-x-flip{--tw-scale-x:-1!important}.scale-x-flip,.scale-y-flip{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))!important}.scale-y-flip{--tw-scale-y:-1!important}.transform{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))!important}.text-2xl{font-size:1.5rem!important;line-height:2rem!important}.text-3xl{font-size:1.875rem!important;line-height:2.25rem!important}.text-5xl{font-size:3rem!important}.text-5xl,.text-6xl{line-height:1!important}.text-6xl{font-size:3.75rem!important}.text-base{font-size:1rem!important;line-height:1.5rem!important}.text-lg{font-size:1.125rem!important}.text-lg,.text-xl{line-height:1.75rem!important}.text-xl{font-size:1.25rem!important}.text-xs{font-size:.75rem!important;line-height:1rem!important}.text-xxs{font-size:.6875rem!important}";
|
|
4
4
|
|
|
5
5
|
const Toast = class {
|
|
6
6
|
constructor(hostRef) {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"file":"p-toast.entry.js","mappings":";;AAAA,MAAM,iBAAiB,GAAG,
|
|
1
|
+
{"file":"p-toast.entry.js","mappings":";;AAAA,MAAM,iBAAiB,GAAG,mkNAAmkN;;MCShlN,KAAK;;;;mBAI0C,UAAU;;;wBAelC,IAAI;sBAKF,UAAU;;;;EAmB5C,MAAM;;IACF,QACI,EAAC,IAAI,IACD,KAAK,EAAE,mBAAmB,IAAI,CAAC,OAAO,EAAE,EACxC,OAAO,EAAE,MAAM,IAAI,CAAC,QAAQ,EAAE,IAE9B,WAAK,KAAK,EAAC,8BAA8B,IACrC,SAAG,KAAK,EAAC,0BAA0B,IAC9B,CAAA,MAAA,IAAI,CAAC,MAAM,0CAAE,MAAM,KAChB,IAAI,CAAC,MAAM,KAEX,YAAM,IAAI,EAAC,QAAQ,GAAG,CACzB,CACD,EACJ,SAAG,KAAK,EAAC,kCAAkC,IACtC,CAAA,MAAA,IAAI,CAAC,OAAO,0CAAE,MAAM,KACjB,IAAI,CAAC,OAAO,KAEZ,YAAM,IAAI,EAAC,SAAS,GAAG,CAC1B,CACD,CACF,EAEL,IAAI,CAAC,YAAY,KACd,gBACI,OAAO,EAAC,WAAW,EACnB,QAAQ,QACR,IAAI,EAAC,OAAO,EACZ,IAAI,EAAE,IAAI,CAAC,UAAU,EACrB,QAAQ,EAAE,IAAI,CAAC,cAAc,EAC7B,UAAU,EAAE,IAAI,CAAC,gBAAgB,EACjC,KAAK,EAAC,eAAe,GACvB,CACL,CACE,EACT;GACL;EAEO,QAAQ;IACZ,IAAI,IAAI,CAAC,YAAY,EAAE;MACnB,IAAI,CAAC,MAAM,CAAC,IAAI,EAAE,CAAC;KACtB;GACJ;;;;;;","names":[],"sources":["./src/components/molecules/toast/toast.component.scss?tag=p-toast&encapsulation=shadow","./src/components/molecules/toast/toast.component.tsx"],"sourcesContent":[":host {\n @apply flex justify-between items-center gap-2;\n @apply w-full p-4 pl-5;\n @apply bg-white rounded box-border;\n @apply shadow-4 #{!important};\n @apply border-l-4 border-solid #{!important};\n\n p {\n @apply m-0;\n @apply overflow-hidden text-ellipsis whitespace-nowrap;\n }\n}\n\n:host(.variant-positive) {\n @apply border-l-positive #{!important};\n}\n\n:host(.variant-unbiased) {\n @apply border-l-unbiased #{!important};\n}\n\n:host(.variant-negative) {\n @apply border-l-negative #{!important};\n}\n","import { Component, Event, EventEmitter, h, Host, Prop } from '@stencil/core';\nimport { RotateOptions } from '../../../types';\nimport { IconFlipOptions, IconVariant } from '../../atoms/icon/icon.component';\n\n@Component({\n tag: 'p-toast',\n styleUrl: 'toast.component.scss',\n shadow: true,\n})\nexport class Toast {\n /**\n * The variant of the toast\n */\n @Prop() variant: 'positive' | 'unbiased' | 'negative' = 'positive';\n\n /**\n * The header of the toast\n */\n @Prop() header?: string;\n\n /**\n * The content of the toast\n */\n @Prop() content?: string;\n\n /**\n * Wether to enable the close button\n */\n @Prop() enableAction: boolean = true;\n\n /**\n * Icon to show on the button\n */\n @Prop() actionIcon: IconVariant = 'negative';\n\n /**\n * Icon flip\n */\n @Prop() actionIconFlip: IconFlipOptions;\n\n /**\n * Icon rotate\n */\n @Prop() actionIconRotate: RotateOptions;\n\n /**\n * Button click event\n */\n @Event({\n bubbles: false\n }) action: EventEmitter<MouseEvent>;\n\n render() {\n return (\n <Host\n class={`p-toast variant-${this.variant}`}\n onClick={() => this._onClick()}\n >\n <div class=\"flex flex-col w-full min-w-0\">\n <p class=\"font-semibold text-storm\">\n {this.header?.length ? (\n this.header\n ) : (\n <slot name=\"header\" />\n )}\n </p>\n <p class=\"text-sm text-storm-medium w-full\">\n {this.content?.length ? (\n this.content\n ) : (\n <slot name=\"content\" />\n )}\n </p>\n </div>\n\n {this.enableAction && (\n <p-button\n variant=\"secondary\"\n iconOnly\n size=\"small\"\n icon={this.actionIcon}\n iconFlip={this.actionIconFlip}\n iconRotate={this.actionIconRotate}\n class=\"flex-shrink-0\"\n />\n )}\n </Host>\n );\n }\n\n private _onClick() {\n if (this.enableAction) {\n this.action.emit();\n }\n }\n}\n"],"version":3}
|