@paperless/core 1.67.7 → 1.67.9
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 +23 -0
- package/dist/build/{p-3fca8a68.entry.js → p-32ec455c.entry.js} +2 -2
- package/dist/build/{p-3fca8a68.entry.js.map → p-32ec455c.entry.js.map} +1 -1
- package/dist/build/p-3e3a79b1.entry.js +2 -0
- package/dist/build/p-3e3a79b1.entry.js.map +1 -0
- package/dist/build/p-59014c4c.entry.js +2 -0
- package/dist/build/{p-ac60e1f8.entry.js.map → p-59014c4c.entry.js.map} +1 -1
- package/dist/build/{p-9d32d95a.entry.js → p-744f5a41.entry.js} +2 -2
- package/dist/build/{p-9d32d95a.entry.js.map → p-744f5a41.entry.js.map} +1 -1
- package/dist/build/p-a689640d.entry.js +2 -0
- package/dist/build/p-a689640d.entry.js.map +1 -0
- package/dist/build/p-f07e2154.entry.js +2 -0
- package/dist/{paperless/p-05d63d59.entry.js.map → build/p-f07e2154.entry.js.map} +1 -1
- package/dist/build/paperless.esm.js +1 -1
- package/dist/cjs/p-dropdown_2.cjs.entry.js +3 -3
- package/dist/cjs/p-dropdown_2.cjs.entry.js.map +1 -1
- package/dist/cjs/p-profile.cjs.entry.js +2 -2
- package/dist/cjs/p-profile.cjs.entry.js.map +1 -1
- package/dist/cjs/p-stepper-item.cjs.entry.js +1 -1
- package/dist/cjs/p-stepper-item.cjs.entry.js.map +1 -1
- package/dist/cjs/p-stepper.cjs.entry.js +7 -1
- package/dist/cjs/p-stepper.cjs.entry.js.map +1 -1
- package/dist/cjs/p-tab-item.cjs.entry.js +1 -1
- package/dist/cjs/p-tab-item.cjs.entry.js.map +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/collection/components/atoms/stepper-item/stepper-item.component.css +1 -1
- package/dist/collection/components/atoms/tab-item/tab-item.component.css +1 -1
- package/dist/collection/components/molecules/dropdown/dropdown.component.css +1 -1
- package/dist/collection/components/molecules/dropdown/dropdown.component.js +2 -2
- package/dist/collection/components/molecules/dropdown/dropdown.component.js.map +1 -1
- package/dist/collection/components/molecules/profile/profile.component.css +1 -1
- package/dist/collection/components/molecules/profile/profile.component.js +1 -1
- package/dist/collection/components/molecules/profile/profile.component.js.map +1 -1
- package/dist/collection/components/molecules/stepper/stepper.component.js +7 -1
- package/dist/collection/components/molecules/stepper/stepper.component.js.map +1 -1
- package/dist/collection/components/organisms/table/table.component.css +1 -1
- package/dist/components/dropdown.component.js +3 -3
- package/dist/components/dropdown.component.js.map +1 -1
- package/dist/components/p-profile.js +2 -2
- package/dist/components/p-profile.js.map +1 -1
- package/dist/components/p-stepper-item.js +1 -1
- package/dist/components/p-stepper-item.js.map +1 -1
- package/dist/components/p-stepper.js +7 -1
- package/dist/components/p-stepper.js.map +1 -1
- package/dist/components/p-tab-item.js +1 -1
- package/dist/components/p-tab-item.js.map +1 -1
- package/dist/components/p-table.js +1 -1
- package/dist/components/p-table.js.map +1 -1
- package/dist/esm/p-dropdown_2.entry.js +3 -3
- package/dist/esm/p-dropdown_2.entry.js.map +1 -1
- package/dist/esm/p-profile.entry.js +2 -2
- package/dist/esm/p-profile.entry.js.map +1 -1
- package/dist/esm/p-stepper-item.entry.js +1 -1
- package/dist/esm/p-stepper-item.entry.js.map +1 -1
- package/dist/esm/p-stepper.entry.js +7 -1
- package/dist/esm/p-stepper.entry.js.map +1 -1
- package/dist/esm/p-tab-item.entry.js +1 -1
- package/dist/esm/p-tab-item.entry.js.map +1 -1
- package/dist/esm/p-table.entry.js +1 -1
- package/dist/esm/p-table.entry.js.map +1 -1
- package/dist/index.html +1 -1
- package/dist/paperless/{p-3fca8a68.entry.js → p-32ec455c.entry.js} +2 -2
- package/dist/paperless/{p-3fca8a68.entry.js.map → p-32ec455c.entry.js.map} +1 -1
- package/dist/paperless/p-3e3a79b1.entry.js +2 -0
- package/dist/paperless/p-3e3a79b1.entry.js.map +1 -0
- package/dist/paperless/p-59014c4c.entry.js +2 -0
- package/dist/paperless/{p-ac60e1f8.entry.js.map → p-59014c4c.entry.js.map} +1 -1
- package/dist/paperless/{p-9d32d95a.entry.js → p-744f5a41.entry.js} +2 -2
- package/dist/paperless/{p-9d32d95a.entry.js.map → p-744f5a41.entry.js.map} +1 -1
- package/dist/paperless/p-a689640d.entry.js +2 -0
- package/dist/paperless/p-a689640d.entry.js.map +1 -0
- package/dist/paperless/p-f07e2154.entry.js +2 -0
- package/dist/{build/p-05d63d59.entry.js.map → paperless/p-f07e2154.entry.js.map} +1 -1
- 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 +15 -9
- package/package.json +1 -1
- package/dist/build/p-05d63d59.entry.js +0 -2
- package/dist/build/p-1a725037.entry.js +0 -2
- package/dist/build/p-1a725037.entry.js.map +0 -1
- package/dist/build/p-ac60e1f8.entry.js +0 -2
- package/dist/build/p-b25507db.entry.js +0 -2
- package/dist/build/p-b25507db.entry.js.map +0 -1
- package/dist/paperless/p-05d63d59.entry.js +0 -2
- package/dist/paperless/p-1a725037.entry.js +0 -2
- package/dist/paperless/p-1a725037.entry.js.map +0 -1
- package/dist/paperless/p-ac60e1f8.entry.js +0 -2
- package/dist/paperless/p-b25507db.entry.js +0 -2
- package/dist/paperless/p-b25507db.entry.js.map +0 -1
|
@@ -3,7 +3,7 @@ import { f as isMobile, t as tableColumSizesOptions } from './screens-c0e0dee2.j
|
|
|
3
3
|
import { f as formatTranslation, g as getLocaleComponentStrings } from './localization-2c641f90.js';
|
|
4
4
|
import { d as defaultSize, a as defaultSizeOptions } from './constants-3500ea14.js';
|
|
5
5
|
|
|
6
|
-
const tableComponentCss = ".fixed{position:fixed!important}.absolute{position:absolute!important}.relative{position:relative!important}.bottom-4{bottom:1rem!important}.left-1\\/2{left:50%!important}.flex{display:flex!important}.hidden{display:none!important}.flex-shrink{flex-shrink:1!important}.-translate-x-1\\/2{--tw-translate-x:-50%!important}.-translate-x-1\\/2,.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}*{box-sizing:border-box}p-table{display:flex;flex-direction:column;position:relative}p-table .p-input[type=checkbox]{flex-shrink:0}p-table p-table-container{position:relative}p-table p-table-container p-floating-menu-container{--tw-translate-x:-50%;animation:floatingMenuContainerIn .3s ease forwards!important;bottom:1rem;left:50%;position:fixed;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))}@media (min-width:40rem){p-table p-table-container p-floating-menu-container{bottom:4rem;position:absolute}}p-table p-table-container p-floating-menu-container:not(.shown){display:none}p-table p-table-container p-floating-menu-container.inactive{animation:floatingMenuContainerOut .3s ease forwards!important}@keyframes floatingMenuContainerOut{0%{display:flex;opacity:1;transform:translateY(0) translateX(-50%)}99%{display:flex;opacity:0;transform:translateY(100%) translateX(-50%)}to{display:none;opacity:0;transform:translateY(100%) translateX(-50%)}}@keyframes floatingMenuContainerIn{0%{display:none;opacity:0;transform:translateY(100%) translateX(-50%)}1%{display:flex;opacity:0;transform:translateY(100%) translateX(-50%)}to{display:flex;opacity:1;transform:translateY(0) translateX(-50%)}}.static{position:static!important}.mx-0{margin-left:0!important;margin-right:0!important}.mb-14{margin-bottom:3.5rem!important}.mb-6{margin-bottom:1.5rem!important}.ml-auto{margin-left:auto!important}.table{display:table!important}.h-6{height:1.5rem!important}.w-6{width:1.5rem!important}.max-w-\\[20rem\\]{max-width:20rem!important}.flex-1{flex:1 1 0%!important}.cursor-pointer{cursor:pointer!important}.flex-col{flex-direction:column!important}.items-center{align-items:center!important}.gap-2{gap:.5rem!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{--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}.opacity-0{opacity:0!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}@media (min-width:40rem){.tablet\\:flex{display:flex!important}}";
|
|
6
|
+
const tableComponentCss = ".fixed{position:fixed!important}.absolute{position:absolute!important}.relative{position:relative!important}.bottom-4{bottom:1rem!important}.left-1\\/2{left:50%!important}.flex{display:flex!important}.hidden{display:none!important}.flex-shrink{flex-shrink:1!important}.-translate-x-1\\/2{--tw-translate-x:-50%!important}.-translate-x-1\\/2,.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}*{box-sizing:border-box}p-table{display:flex;flex-direction:column;position:relative}p-table .p-input[type=checkbox]{flex-shrink:0}p-table p-table-container{position:relative}p-table p-table-container p-floating-menu-container{--tw-translate-x:-50%;animation:floatingMenuContainerIn .3s ease forwards!important;bottom:1rem;left:50%;position:fixed;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))}@media (min-width:40rem){p-table p-table-container p-floating-menu-container{bottom:4rem;position:absolute}}p-table p-table-container p-floating-menu-container:not(.shown){display:none}p-table p-table-container p-floating-menu-container.inactive{animation:floatingMenuContainerOut .3s ease forwards!important}@keyframes floatingMenuContainerOut{0%{display:flex;opacity:1;transform:translateY(0) translateX(-50%)}99%{display:flex;opacity:0;transform:translateY(100%) translateX(-50%)}to{display:none;opacity:0;transform:translateY(100%) translateX(-50%)}}@keyframes floatingMenuContainerIn{0%{display:none;opacity:0;transform:translateY(100%) translateX(-50%)}1%{display:flex;opacity:0;transform:translateY(100%) translateX(-50%)}to{display:flex;opacity:1;transform:translateY(0) translateX(-50%)}}.static{position:static!important}.mx-0{margin-left:0!important;margin-right:0!important}.mb-14{margin-bottom:3.5rem!important}.mb-6{margin-bottom:1.5rem!important}.ml-auto{margin-left:auto!important}.table{display:table!important}.h-6{height:1.5rem!important}.w-6{width:1.5rem!important}.max-w-\\[20rem\\]{max-width:20rem!important}.flex-1{flex:1 1 0%!important}.cursor-pointer{cursor:pointer!important}.resize{resize:both!important}.flex-col{flex-direction:column!important}.items-center{align-items:center!important}.gap-2{gap:.5rem!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{--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}.opacity-0{opacity:0!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}@media (min-width:40rem){.tablet\\:flex{display:flex!important}}";
|
|
7
7
|
|
|
8
8
|
const Table = class {
|
|
9
9
|
constructor(hostRef) {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"file":"p-table.entry.js","mappings":";;;;;AAAA,MAAM,iBAAiB,GAAG,onGAAonG;;MCuCjoG,KAAK;;;;;;;;;;;;;;;;IAsVT,2BAAsB,GAAqB,EAAE,CAAC;IAI9C,cAAS,GAAG,KAAK,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KAAK,MAAM,IAAI,IAAI,sBAAsB,EAAE;MAC1C,MAAM,UAAU,GAAG,IAAI,CAAC,yBAAyB,CAAC,IAAI,CAAC,QAAQ,EAAE,IAAI,CAAC,CAAC;MACvE,KAAK,CAAC,IAAI,CAAC,GAAG,UAAW,CAAC,WAAY,CAAC,IAAI,CAAE,CAAC;KAC9C;IAED,OAAO;MACN,MAAM;MACN,KAAK;MACL,WAAW,EAAE,KAAK;MAClB,KAAK,EAAE,KAAK;MACZ,IAAI,EAAE,IAAI;MACV,IAAI,EAAE,IAAI;KACK,CAAC;GACjB;;;;;;;;;;;;;","names":[],"sources":["src/components/organisms/table/table.component.scss?tag=p-table","src/components/organisms/table/table.component.tsx"],"sourcesContent":["p-table {\n\t@apply relative flex flex-col;\n\n\t.p-input[type='checkbox'] {\n\t\tflex-shrink: 0;\n\t}\n\n\tp-table-container {\n\t\t@apply relative;\n\n\t\tp-floating-menu-container {\n\t\t\t@apply fixed bottom-4 left-1/2 -translate-x-1/2 transform;\n\t\t\tanimation: forwards floatingMenuContainerIn 0.3s ease !important;\n\n\t\t\t@screen tablet {\n\t\t\t\t@apply absolute bottom-16;\n\t\t\t}\n\n\t\t\t&:not(.shown) {\n\t\t\t\t@apply hidden;\n\t\t\t}\n\n\t\t\t&.inactive {\n\t\t\t\tanimation: forwards floatingMenuContainerOut 0.3s ease !important;\n\t\t\t}\n\t\t}\n\t}\n}\n\n@keyframes floatingMenuContainerOut {\n\t0% {\n\t\tdisplay: flex;\n\t\ttransform: translateY(0) translateX(-50%);\n\t\topacity: 100;\n\t}\n\t99% {\n\t\ttransform: translateY(100%) translateX(-50%);\n\t\topacity: 0;\n\t\tdisplay: flex;\n\t}\n\t100% {\n\t\ttransform: translateY(100%) translateX(-50%);\n\t\topacity: 0;\n\t\tdisplay: none;\n\t}\n}\n\n@keyframes floatingMenuContainerIn {\n\t0% {\n\t\ttransform: translateY(100%) translateX(-50%);\n\t\topacity: 0;\n\t\tdisplay: none;\n\t}\n\t1% {\n\t\ttransform: translateY(100%) translateX(-50%);\n\t\topacity: 0;\n\t\tdisplay: flex;\n\t}\n\t100% {\n\t\ttransform: translateY(0) translateX(-50%);\n\t\topacity: 100;\n\t\tdisplay: flex;\n\t}\n}\n","import {\n\tComponent,\n\tElement,\n\tEvent,\n\tEventEmitter,\n\th,\n\tHost,\n\tListen,\n\tProp,\n\tState,\n\tWatch,\n} from '@stencil/core';\nimport { IconVariant } from '../../../components';\nimport { tableColumSizesOptions } from '../../../types/constants';\nimport {\n\tQuickFilter,\n\tRowClickEvent,\n\tTableColumnSizes,\n} from '../../../types/table';\nimport {\n\tformatTranslation,\n\tgetLocaleComponentStrings,\n\tisMobile,\n} from '../../../utils';\nimport { TableColumn } from '../../helpers/table-column/table-column.component';\nimport { TableRowAction } from '../../helpers/table-row-action/table-row-action.component';\nimport {\n\tdefaultSize,\n\tdefaultSizeOptions,\n} from '../../molecules/page-size-select/constants';\nimport { buttonTemplateFunc } from '../../molecules/table-header/table-header.component';\n\nexport type templateFunc = () => string;\nexport type amountSelectedTemplateFunc = (amount: number) => string;\n\n@Component({\n\ttag: 'p-table',\n\tstyleUrl: 'table.component.scss',\n})\nexport class Table {\n\t/**\n\t * The items to be fed to the table\n\t */\n\t@Prop() items: string;\n\n\t/**\n\t * Wether data is loading\n\t */\n\t@Prop() loading: boolean = false;\n\n\t/**\n\t * Wether the header should show loading state\n\t */\n\t@Prop() headerLoading: boolean = false;\n\n\t/**\n\t * Wether the footer should show loading state\n\t */\n\t@Prop() footerLoading: boolean = false;\n\n\t/**\n\t * The amount of loading rows to show\n\t */\n\t@Prop() amountOfLoadingRows: number = 6;\n\n\t/**\n\t * Wether to enable selection\n\t */\n\t@Prop() enableRowSelection: boolean = true;\n\n\t/**\n\t * A limit to the amount of rows that can be selected\n\t */\n\t@Prop() rowSelectionLimit: number | undefined;\n\n\t/**\n\t * Wether to enable row clicking\n\t */\n\t@Prop() enableRowClick: boolean = true;\n\n\t/**\n\t * The current selection of items\n\t */\n\t@Prop() selectedRows: any[] = [];\n\n\t/**\n\t * Wether to enable the floating menu\n\t */\n\t@Prop() enableFloatingMenu: boolean = true;\n\n\t/**\n\t * The template for amount selected item in the floating menu\n\t */\n\t@Prop() floatingMenuAmountSelectedTemplate: amountSelectedTemplateFunc = (\n\t\tamount: number\n\t) =>\n\t\tformatTranslation(\n\t\t\t(amount === 1\n\t\t\t\t? this._locales.floating_menu?.amount_selected\n\t\t\t\t: this._locales.floating_menu?.amount_selected_plural\n\t\t\t)?.replace('{{amount}}', amount)\n\t\t);\n\n\t/**\n\t * Event whenever the current selection changes\n\t */\n\t@Event({\n\t\tbubbles: false,\n\t})\n\tselectedRowsChange: EventEmitter<any>;\n\n\t/**\n\t * The key to determine if a row is selected\n\t */\n\t@Prop() selectionKey: string;\n\n\t/**\n\t * A key to determine if a row can be selected\n\t */\n\t@Prop() canSelectKey: string;\n\n\t/**\n\t * Event whenever a row is clicked\n\t */\n\t@Event({\n\t\tbubbles: false,\n\t})\n\trowClick: EventEmitter<RowClickEvent>;\n\n\t/**\n\t * Event whenever a row is selected\n\t */\n\t@Event({\n\t\tbubbles: false,\n\t})\n\trowSelected: EventEmitter<any>;\n\n\t/**\n\t * Event whenever a row is deselected\n\t */\n\t@Event({\n\t\tbubbles: false,\n\t})\n\trowDeselected: EventEmitter<any>;\n\n\t/**\n\t * Event when the table has rendered\n\t */\n\t@Event({\n\t\tbubbles: false,\n\t})\n\thasRendered: EventEmitter<number>;\n\n\t/** START HEADER */\n\n\t/**\n\t * Wether to show the header\n\t */\n\t@Prop() enableHeader: boolean = true;\n\n\t/**\n\t * Quick filters to show\n\t */\n\t@Prop() quickFilters: QuickFilter[] = [];\n\n\t/**\n\t * Active quick filter identifier\n\t */\n\t@Prop() activeQuickFilterIdentifier: string;\n\n\t/**\n\t * Wether to show the search input\n\t */\n\t@Prop() enableSearch: boolean = true;\n\n\t/**\n\t * The query to show in the search bar\n\t */\n\t@Prop({ mutable: true }) query: string;\n\n\t/**\n\t * Wether to show the filter button\n\t */\n\t@Prop() enableFilter: boolean = true;\n\n\t/**\n\t * Wether to show the filter button on desktop\n\t */\n\t@Prop() enableFilterDesktop: boolean = true;\n\n\t/**\n\t * The amount of filters being selected\n\t */\n\t@Prop() selectedFiltersAmount: number;\n\n\t/**\n\t * The template for the filter button text\n\t */\n\t@Prop() filterButtonTemplate: templateFunc;\n\n\t/**\n\t * Wether to show the action button\n\t */\n\t@Prop() enableAction: boolean = false;\n\n\t/**\n\t * Wether the action button is loading\n\t */\n\t@Prop() actionButtonLoading: boolean = false;\n\n\t/**\n\t * Wether the action button is enabled\n\t */\n\t@Prop() actionButtonEnabled: boolean = false;\n\n\t/**\n\t * The action button icon\n\t */\n\t@Prop() actionButtonIcon: IconVariant = 'pencil';\n\n\t/**\n\t * The action button text if changed\n\t */\n\t@Prop() actionButtonText: string;\n\n\t/**\n\t * The template for the action button text\n\t */\n\t@Prop() actionButtonTemplate: buttonTemplateFunc;\n\n\t/**\n\t * Event when one of the quick filters is clicked\n\t */\n\t@Event({\n\t\tbubbles: false,\n\t})\n\tquickFilter: EventEmitter<QuickFilter>;\n\n\t/**\n\t * Event when the query changes\n\t */\n\t@Event({\n\t\tbubbles: false,\n\t})\n\tqueryChange: EventEmitter<string>;\n\n\t/**\n\t * Event when the filter button is clicked\n\t */\n\t@Event({\n\t\tbubbles: false,\n\t})\n\tfilter: EventEmitter<null>;\n\n\t/**\n\t * Event when the action button is clicked\n\t */\n\t@Event({\n\t\tbubbles: false,\n\t})\n\taction: EventEmitter<null>;\n\n\t/** START FOOTER */\n\n\t/**\n\t * Wether to show the header\n\t */\n\t@Prop() enableFooter: boolean = true;\n\n\t/**\n\t * Wether to enable page size select\n\t */\n\t@Prop() enablePageSize: boolean = true;\n\n\t/**\n\t * Wether to enable pagination\n\t */\n\t@Prop() enablePagination: boolean = true;\n\n\t/**\n\t * Wether to enable export\n\t */\n\t@Prop() enableExport: boolean = true;\n\n\t/**\n\t * The current page\n\t */\n\t@Prop({ mutable: true, reflect: true }) page: number = 1;\n\n\t/**\n\t * The total amount of items\n\t */\n\t@Prop() total!: number;\n\n\t/**\n\t * Event whenever the page changes\n\t */\n\t@Event({\n\t\tbubbles: false,\n\t})\n\tpageChange: EventEmitter<number>;\n\n\t/**\n\t * The amount of items per page\n\t */\n\t@Prop() pageSize: number = defaultSize;\n\n\t/**\n\t * The options for the page size\n\t */\n\t@Prop() pageSizeOptions: number[] = defaultSizeOptions;\n\n\t/**\n\t * Event whenever the page changes\n\t */\n\t@Event({\n\t\tbubbles: false,\n\t})\n\tpageSizeChange: EventEmitter<number>;\n\n\t/**\n\t * Event whenever the page changes\n\t */\n\t@Event({\n\t\tbubbles: false,\n\t})\n\texport: EventEmitter<number>;\n\n\t/**\n\t * Wether to hide when there is only 1 page available\n\t */\n\t@Prop() hideOnSinglePage: boolean = true;\n\n\t/* Empty state start */\n\t@Prop() emptyStateHeader: templateFunc = () =>\n\t\tformatTranslation(this._locales.empty_state?.no_filter.header);\n\t@Prop() emptyStateContent: templateFunc = () =>\n\t\tformatTranslation(this._locales.empty_state?.no_filter.content);\n\t@Prop() emptyStateAction: templateFunc = () =>\n\t\tformatTranslation(this._locales.empty_state?.no_filter.action);\n\t/**\n\t * Wether to enable empty state action\n\t */\n\t@Prop() enableEmptyStateAction: boolean = true;\n\n\t@Prop() emptyStateFilteredHeader: templateFunc = () =>\n\t\tformatTranslation(this._locales.empty_state.filtered.header);\n\t@Prop() emptyStateFilteredContent: templateFunc = () =>\n\t\tformatTranslation(this._locales.empty_state.filtered.content);\n\n\t/**\n\t * Event whenever the empty state is clicked\n\t */\n\t@Event({\n\t\tbubbles: false,\n\t})\n\temptyStateActionClick: EventEmitter<null>;\n\n\t/*\n\t * Wether to show the shadow or not\n\t */\n\t@Prop() shadow: boolean = true;\n\n\t/* Empty state end */\n\n\t/**\n\t * The host element\n\t */\n\t@Element() private _el: HTMLElement;\n\n\t/**\n\t * Locales used for this component\n\t */\n\t@State() private _locales: any = {};\n\n\t@State() private _columns: any[] = [];\n\t@State() private _items: any[] = [];\n\n\t@State() private _enableRowSelection: boolean = this.enableRowSelection;\n\t@State() private _rowSelectionLimit: number | undefined;\n\n\tprivate _rowActionsFloatingAll: TableRowAction[] = [];\n\t@State() private _rowActionsFloating: TableRowAction[] = [];\n\t@State() private _rowActionsRow: TableRowAction[] = [];\n\n\tprivate _ctrlDown = false;\n\tprivate _hasCustomFilterSlot = false;\n\tprivate _hasCustomActionsSlot = false;\n\tprivate _floatingMenuShown = false;\n\tprivate _resizeTimeout: NodeJS.Timer;\n\n\tcomponentWillLoad() {\n\t\tthis._hasCustomFilterSlot = !!this._el.querySelector(\n\t\t\t':scope > [slot=\"custom-filter\"]'\n\t\t);\n\n\t\tthis._hasCustomActionsSlot = !!this._el.querySelector(\n\t\t\t':scope > [slot=\"custom-actions\"]'\n\t\t);\n\n\t\tthis._setRowSelectionData();\n\n\t\tthis._setLocales();\n\t\tthis._parseItems(this.items);\n\t\tthis._generateColumns();\n\t}\n\n\tcomponentDidRender() {\n\t\tthis.hasRendered.emit();\n\t}\n\n\trender() {\n\t\treturn (\n\t\t\t<Host class='p-table'>\n\t\t\t\t<p-table-container shadow={this.shadow}>\n\t\t\t\t\t{this.enableHeader && (\n\t\t\t\t\t\t<p-table-header\n\t\t\t\t\t\t\t// quick filters\n\t\t\t\t\t\t\tquickFilters={this.quickFilters}\n\t\t\t\t\t\t\tactiveQuickFilterIdentifier={this.activeQuickFilterIdentifier}\n\t\t\t\t\t\t\tonQuickFilter={({ detail }) => this.quickFilter.emit(detail)}\n\t\t\t\t\t\t\t// search\n\t\t\t\t\t\t\tenableSearch={this.enableSearch}\n\t\t\t\t\t\t\tquery={this.query}\n\t\t\t\t\t\t\tonQueryChange={({ detail }) => this.queryChange.emit(detail)}\n\t\t\t\t\t\t\t// filter button\n\t\t\t\t\t\t\tenableFilter={this.enableFilter}\n\t\t\t\t\t\t\tenableFilterDesktop={this.enableFilterDesktop}\n\t\t\t\t\t\t\tselectedFiltersAmount={this.selectedFiltersAmount}\n\t\t\t\t\t\t\tfilterButtonTemplate={this.filterButtonTemplate}\n\t\t\t\t\t\t\tonFilter={() => this.filter.emit()}\n\t\t\t\t\t\t\t// action button\n\t\t\t\t\t\t\tenableAction={this.enableAction}\n\t\t\t\t\t\t\tactionIcon={this.actionButtonIcon}\n\t\t\t\t\t\t\tactionText={this.actionButtonText}\n\t\t\t\t\t\t\tactionLoading={this.actionButtonLoading}\n\t\t\t\t\t\t\tcanUseAction={this.actionButtonEnabled}\n\t\t\t\t\t\t\tactionButtonTemplate={this.actionButtonTemplate}\n\t\t\t\t\t\t\tonAction={() => this.action.emit()}\n\t\t\t\t\t\t\titemsSelectedAmount={this.selectedRows?.length}\n\t\t\t\t\t\t\t//loading\n\t\t\t\t\t\t\tloading={this.headerLoading}\n\t\t\t\t\t\t>\n\t\t\t\t\t\t\t{this._hasCustomFilterSlot && (\n\t\t\t\t\t\t\t\t<slot\n\t\t\t\t\t\t\t\t\tname='custom-filter'\n\t\t\t\t\t\t\t\t\tslot='custom-filter'\n\t\t\t\t\t\t\t\t/>\n\t\t\t\t\t\t\t)}\n\n\t\t\t\t\t\t\t{this._hasCustomActionsSlot && (\n\t\t\t\t\t\t\t\t<slot\n\t\t\t\t\t\t\t\t\tname='custom-actions'\n\t\t\t\t\t\t\t\t\tslot='custom-actions'\n\t\t\t\t\t\t\t\t/>\n\t\t\t\t\t\t\t)}\n\t\t\t\t\t\t</p-table-header>\n\t\t\t\t\t)}\n\n\t\t\t\t\t{this._getHeader()}\n\t\t\t\t\t<div class='flex flex-1 flex-col'>{this._getRows()}</div>\n\n\t\t\t\t\t{this.enableFooter && (\n\t\t\t\t\t\t<p-table-footer\n\t\t\t\t\t\t\t// overall\n\t\t\t\t\t\t\thideOnSinglePage={this.hideOnSinglePage}\n\t\t\t\t\t\t\t// page size select\n\t\t\t\t\t\t\tenablePageSize={this.enablePageSize}\n\t\t\t\t\t\t\tpageSize={this.pageSize}\n\t\t\t\t\t\t\tpageSizeOptions={this.pageSizeOptions}\n\t\t\t\t\t\t\tonPageSizeChange={({ detail }) =>\n\t\t\t\t\t\t\t\tthis.pageSizeChange.emit(detail)\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t// pagination\n\t\t\t\t\t\t\tenablePagination={this.enablePagination}\n\t\t\t\t\t\t\tpage={this.page}\n\t\t\t\t\t\t\ttotal={this.total}\n\t\t\t\t\t\t\tonPageChange={({ detail }) => this.pageChange.emit(detail)}\n\t\t\t\t\t\t\t// export\n\t\t\t\t\t\t\tenableExport={this.enableExport}\n\t\t\t\t\t\t\tonExport={() => this.export.emit()}\n\t\t\t\t\t\t\t//loading\n\t\t\t\t\t\t\tloading={this.footerLoading}\n\t\t\t\t\t\t></p-table-footer>\n\t\t\t\t\t)}\n\n\t\t\t\t\t{this.enableFloatingMenu && this._enableRowSelection ? (\n\t\t\t\t\t\t<p-floating-menu-container\n\t\t\t\t\t\t\tusedInTable={true}\n\t\t\t\t\t\t\tclass={`${this.selectedRows?.length ? '' : 'inactive'} ${\n\t\t\t\t\t\t\t\tthis._floatingMenuShown ? 'shown' : ''\n\t\t\t\t\t\t\t}`}\n\t\t\t\t\t\t>\n\t\t\t\t\t\t\t<p-floating-menu-item\n\t\t\t\t\t\t\t\thover={false}\n\t\t\t\t\t\t\t\tslot='floating-menu-item'\n\t\t\t\t\t\t\t\tclass={\n\t\t\t\t\t\t\t\t\tthis._rowActionsFloating?.length ? 'hidden tablet:flex' : ''\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t>\n\t\t\t\t\t\t\t\t{this.floatingMenuAmountSelectedTemplate(\n\t\t\t\t\t\t\t\t\tthis.selectedRows?.length\n\t\t\t\t\t\t\t\t)}\n\t\t\t\t\t\t\t</p-floating-menu-item>\n\t\t\t\t\t\t\t<p-divider\n\t\t\t\t\t\t\t\tclass={`mx-0 text-storm ${\n\t\t\t\t\t\t\t\t\tthis._rowActionsFloating?.length ? 'hidden tablet:flex' : ''\n\t\t\t\t\t\t\t\t}`}\n\t\t\t\t\t\t\t\tvariant='vertical'\n\t\t\t\t\t\t\t\tslot='floating-menu-item'\n\t\t\t\t\t\t\t/>\n\t\t\t\t\t\t\t{this._rowActionsFloating?.length &&\n\t\t\t\t\t\t\t\tthis._rowActionsFloating.map(a => (\n\t\t\t\t\t\t\t\t\t<p-floating-menu-item\n\t\t\t\t\t\t\t\t\t\tslot='floating-menu-item'\n\t\t\t\t\t\t\t\t\t\tdisabled={a.disabled}\n\t\t\t\t\t\t\t\t\t\tonClick={() =>\n\t\t\t\t\t\t\t\t\t\t\t!a.disabled &&\n\t\t\t\t\t\t\t\t\t\t\t!a.loading &&\n\t\t\t\t\t\t\t\t\t\t\t!!a.action &&\n\t\t\t\t\t\t\t\t\t\t\ta.type === 'single'\n\t\t\t\t\t\t\t\t\t\t\t\t? a.action(this.selectedRows[0], false)\n\t\t\t\t\t\t\t\t\t\t\t\t: a.action(this.selectedRows, true)\n\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t>\n\t\t\t\t\t\t\t\t\t\t{a.label}{' '}\n\t\t\t\t\t\t\t\t\t\t{a.loading ? (\n\t\t\t\t\t\t\t\t\t\t\t<p-loader></p-loader>\n\t\t\t\t\t\t\t\t\t\t) : (\n\t\t\t\t\t\t\t\t\t\t\t<p-icon\n\t\t\t\t\t\t\t\t\t\t\t\tvariant={a.icon}\n\t\t\t\t\t\t\t\t\t\t\t\trotate={a.iconRotate}\n\t\t\t\t\t\t\t\t\t\t\t\tflip={a.iconFlip}\n\t\t\t\t\t\t\t\t\t\t\t/>\n\t\t\t\t\t\t\t\t\t\t)}\n\t\t\t\t\t\t\t\t\t</p-floating-menu-item>\n\t\t\t\t\t\t\t\t))}\n\t\t\t\t\t\t\t{this._rowActionsFloating?.length && (\n\t\t\t\t\t\t\t\t<p-divider\n\t\t\t\t\t\t\t\t\tclass='mx-0 text-storm'\n\t\t\t\t\t\t\t\t\tvariant='vertical'\n\t\t\t\t\t\t\t\t\tslot='floating-menu-item'\n\t\t\t\t\t\t\t\t/>\n\t\t\t\t\t\t\t)}\n\t\t\t\t\t\t\t<p-floating-menu-item\n\t\t\t\t\t\t\t\tslot='floating-menu-item'\n\t\t\t\t\t\t\t\tonClick={() => this._selectAllChange(null, false)}\n\t\t\t\t\t\t\t>\n\t\t\t\t\t\t\t\t<p-icon variant='negative' />\n\t\t\t\t\t\t\t</p-floating-menu-item>\n\t\t\t\t\t\t</p-floating-menu-container>\n\t\t\t\t\t) : (\n\t\t\t\t\t\t''\n\t\t\t\t\t)}\n\t\t\t\t</p-table-container>\n\t\t\t</Host>\n\t\t);\n\t}\n\n\t@Listen('localeChanged', { target: 'body' })\n\tprivate async _setLocales(): Promise<void> {\n\t\tthis._locales = await getLocaleComponentStrings(this._el);\n\t}\n\n\t@Listen('tableDefinitionChanged', { target: 'body' })\n\tonTableDefinitionUpdated() {\n\t\tthis._generateColumns();\n\t}\n\n\t@Listen('keydown', { target: 'document' })\n\tkeyDown({ key }) {\n\t\tif (key !== 'Control' || this._ctrlDown === true) {\n\t\t\treturn;\n\t\t}\n\n\t\tthis._ctrlDown = true;\n\t}\n\n\t@Listen('keyup', { target: 'document' })\n\tkeyUp({ key }) {\n\t\tif (key !== 'Control' || this._ctrlDown === false) {\n\t\t\treturn;\n\t\t}\n\n\t\tthis._ctrlDown = false;\n\t}\n\n\t@Listen('visibilitychange', { target: 'document' })\n\tvisibilityChange() {\n\t\tif (document.visibilityState !== 'hidden' || this._ctrlDown === false) {\n\t\t\treturn;\n\t\t}\n\n\t\tthis._ctrlDown = false;\n\t}\n\n\t@Watch('items')\n\tprivate _parseItems(items: string) {\n\t\tif (!items) {\n\t\t\tthis._items = [];\n\t\t\treturn;\n\t\t}\n\n\t\tif (Array.isArray(items)) {\n\t\t\tthis._items = items;\n\t\t\treturn;\n\t\t}\n\n\t\tthis._items = JSON.parse(items);\n\t}\n\n\t@Watch('enableRowSelection')\n\t@Watch('rowSelectionLimit')\n\t@Watch('selectedRows')\n\t@Listen('resize', { target: 'window' })\n\tprivate _setRowSelectionData() {\n\t\tif (this._resizeTimeout) {\n\t\t\tclearTimeout(this._resizeTimeout);\n\t\t}\n\n\t\t// We add a timeout here because it's a lot easier on the machine to do these when someone is done\n\t\t// resizing and playing around with their browser\n\t\tthis._resizeTimeout = setTimeout(() => {\n\t\t\tconst mobile = isMobile();\n\n\t\t\t// we hack this to any[] to make it work..\n\t\t\tconst actions = Array.from(\n\t\t\t\tthis._el.querySelectorAll(':scope > p-table-row-action')\n\t\t\t) as any[] as TableRowAction[];\n\t\t\tthis._rowActionsRow = actions.filter(\n\t\t\t\ta => a.type === 'both' || a.type === 'single'\n\t\t\t);\n\t\t\tthis._rowActionsFloatingAll = actions\n\t\t\t\t.filter(\n\t\t\t\t\ta =>\n\t\t\t\t\t\t(this.enableRowSelection &&\n\t\t\t\t\t\t\t(a.type === 'both' || a.type === 'multi')) ||\n\t\t\t\t\t\t(mobile && a.type === 'single')\n\t\t\t\t)\n\t\t\t\t.map(a => {\n\t\t\t\t\tif (a.type === 'single') {\n\t\t\t\t\t\ta.disabled = this.selectedRows?.length > 1;\n\t\t\t\t\t}\n\n\t\t\t\t\treturn a;\n\t\t\t\t});\n\n\t\t\tlet rowSelectionLimit = this.rowSelectionLimit;\n\t\t\tif (\n\t\t\t\tmobile && // we're mobile\n\t\t\t\tthis._rowActionsFloatingAll?.length && // we have atleast 1 item in _rowActionsFloating\n\t\t\t\t((rowSelectionLimit !== undefined && this.enableRowSelection) ||\n\t\t\t\t\t!this.enableRowSelection)\n\t\t\t) {\n\t\t\t\trowSelectionLimit = 1;\n\t\t\t}\n\n\t\t\tthis._rowSelectionLimit = rowSelectionLimit;\n\n\t\t\tlet enableRowSelection = this.enableRowSelection;\n\t\t\tif (\n\t\t\t\tmobile && // we're mobile\n\t\t\t\tthis._rowActionsFloatingAll?.length && // we have atleast 1 item in _rowActionsFloating\n\t\t\t\t!enableRowSelection\n\t\t\t) {\n\t\t\t\tenableRowSelection = true;\n\t\t\t}\n\n\t\t\tthis._enableRowSelection = enableRowSelection;\n\n\t\t\tif (this._floatingMenuShown) {\n\t\t\t\tthis._showFloatingMenu();\n\t\t\t}\n\t\t}, 200);\n\t}\n\n\tprivate _generateColumns() {\n\t\tconst definitions = this._el.querySelectorAll('p-table-column');\n\t\tlet definitionsArray = Array.from(definitions);\n\n\t\tdefinitionsArray = this._parseDefinitions(definitionsArray);\n\n\t\tthis._columns = definitionsArray;\n\t}\n\n\tprivate _getHeader() {\n\t\treturn (\n\t\t\t<p-table-row variant='header'>\n\t\t\t\t{this._columns.map((col: TableColumn, index) => (\n\t\t\t\t\t<p-table-cell\n\t\t\t\t\t\tdefinition={col}\n\t\t\t\t\t\tvalue={col.name}\n\t\t\t\t\t\tvariant='header'\n\t\t\t\t\t\tcheckbox={\n\t\t\t\t\t\t\tindex === 0 || col.hasCheckbox\n\t\t\t\t\t\t\t\t? this._getCheckbox(null, this.loading ? 'loading' : 'header')\n\t\t\t\t\t\t\t\t: null\n\t\t\t\t\t\t}\n\t\t\t\t\t\tindex={index}\n\t\t\t\t\t></p-table-cell>\n\t\t\t\t))}\n\t\t\t</p-table-row>\n\t\t);\n\t}\n\n\tprivate _getRows() {\n\t\tif (this.loading) {\n\t\t\treturn Array.from(\n\t\t\t\t{\n\t\t\t\t\tlength: this.amountOfLoadingRows,\n\t\t\t\t},\n\t\t\t\t(_, i) => (\n\t\t\t\t\t<p-table-row\n\t\t\t\t\t\tenableHover={this._enableRowSelection || this.enableRowClick}\n\t\t\t\t\t>\n\t\t\t\t\t\t{this._getLoadingColumns(i)}\n\t\t\t\t\t</p-table-row>\n\t\t\t\t)\n\t\t\t);\n\t\t}\n\n\t\tif (!this._items.length) {\n\t\t\treturn this._getEmptyState();\n\t\t}\n\n\t\treturn this._items.map((item, index) => (\n\t\t\t<p-table-row\n\t\t\t\tenableHover={this._enableRowSelection || this.enableRowClick}\n\t\t\t\tonClick={ev => this._rowClick(ev, index)}\n\t\t\t>\n\t\t\t\t{this._getRowColumns(item, index)}\n\t\t\t</p-table-row>\n\t\t));\n\t}\n\n\tprivate _getRowColumns(item, index) {\n\t\tconst actions = this._rowActionsRow.filter(a =>\n\t\t\ta.showFunction ? a.showFunction(item) : true\n\t\t);\n\n\t\tconst columns = this._columns.map((col: TableColumn, colIndex) => {\n\t\t\treturn (\n\t\t\t\t<p-table-cell\n\t\t\t\t\tdefinition={col}\n\t\t\t\t\titem={item}\n\t\t\t\t\tcheckbox={\n\t\t\t\t\t\tcolIndex === 0 || col.hasCheckbox ? this._getCheckbox(index) : null\n\t\t\t\t\t}\n\t\t\t\t\tindex={colIndex}\n\t\t\t\t\trowIndex={index}\n\t\t\t\t\ttableHasActions={!!actions.length && !isMobile()}\n\t\t\t\t></p-table-cell>\n\t\t\t);\n\t\t});\n\n\t\tif (actions?.length && !isMobile()) {\n\t\t\tconst def = this._parseRowActionsRowDefinition();\n\n\t\t\tif (!actions.length) {\n\t\t\t\treturn columns;\n\t\t\t}\n\n\t\t\tcolumns.push(\n\t\t\t\t<p-table-cell\n\t\t\t\t\tvariant='actions'\n\t\t\t\t\tdefinition={def}\n\t\t\t\t\titem={item}\n\t\t\t\t\tindex={this._columns.length - 1}\n\t\t\t\t\trowIndex={index}\n\t\t\t\t\ttableHasActions={true}\n\t\t\t\t>\n\t\t\t\t\t<div\n\t\t\t\t\t\tslot='actions'\n\t\t\t\t\t\tclass='ml-auto flex items-center gap-2'\n\t\t\t\t\t>\n\t\t\t\t\t\t{actions.map(a => (\n\t\t\t\t\t\t\t<p-tooltip content={a.label}>\n\t\t\t\t\t\t\t\t<p-button\n\t\t\t\t\t\t\t\t\tdata-is-action\n\t\t\t\t\t\t\t\t\tvariant='secondary'\n\t\t\t\t\t\t\t\t\tslot='trigger'\n\t\t\t\t\t\t\t\t\ticon={a.icon}\n\t\t\t\t\t\t\t\t\ticonRotate={a.iconRotate}\n\t\t\t\t\t\t\t\t\ticonFlip={a.iconFlip}\n\t\t\t\t\t\t\t\t\ticonOnly={true}\n\t\t\t\t\t\t\t\t\tsize='small'\n\t\t\t\t\t\t\t\t\tonClick={() =>\n\t\t\t\t\t\t\t\t\t\ttypeof a.action === 'function' && a.action?.(item, false)\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t></p-button>\n\t\t\t\t\t\t\t</p-tooltip>\n\t\t\t\t\t\t))}\n\t\t\t\t\t</div>\n\t\t\t\t</p-table-cell>\n\t\t\t);\n\t\t}\n\n\t\treturn columns;\n\t}\n\n\tprivate _getLoadingColumns(index) {\n\t\treturn this._columns.map((col: TableColumn, colIndex) => {\n\t\t\treturn (\n\t\t\t\t<p-table-cell\n\t\t\t\t\tdefinition={col}\n\t\t\t\t\tvariant='loading'\n\t\t\t\t\tcheckbox={\n\t\t\t\t\t\tcolIndex === 0 || col.hasCheckbox\n\t\t\t\t\t\t\t? this._getCheckbox(index, 'loading')\n\t\t\t\t\t\t\t: null\n\t\t\t\t\t}\n\t\t\t\t\tindex={colIndex}\n\t\t\t\t\trowIndex={index}\n\t\t\t\t></p-table-cell>\n\t\t\t);\n\t\t});\n\t}\n\n\tprivate _getCheckbox(\n\t\trowIndex: number,\n\t\tvariant: 'header' | 'default' | 'loading' = 'default'\n\t) {\n\t\tif (\n\t\t\t!this._enableRowSelection ||\n\t\t\t(!this.selectionKey && !this._rowActionsFloating?.length)\n\t\t) {\n\t\t\treturn;\n\t\t}\n\n\t\tif (variant === 'loading') {\n\t\t\treturn (\n\t\t\t\t<p-loader\n\t\t\t\t\tvariant='ghost'\n\t\t\t\t\tclass='h-6 w-6 rounded'\n\t\t\t\t/>\n\t\t\t);\n\t\t}\n\n\t\tif (variant === 'header') {\n\t\t\treturn (\n\t\t\t\t<input\n\t\t\t\t\tclass={`p-input ${\n\t\t\t\t\t\tthis._rowSelectionLimit !== undefined && 'opacity-0'\n\t\t\t\t\t}`}\n\t\t\t\t\ttype='checkbox'\n\t\t\t\t\tonChange={ev => this._selectAllChange(ev)}\n\t\t\t\t\tchecked={this._selectionContainsAll()}\n\t\t\t\t\tindeterminate={this._selectionIndeterminate()}\n\t\t\t\t\tdisabled={this._rowSelectionLimit !== undefined}\n\t\t\t\t/>\n\t\t\t);\n\t\t}\n\n\t\tconst item = this._items[rowIndex];\n\n\t\tconst selectionContains = this._selectionContains(rowIndex);\n\n\t\treturn (\n\t\t\t<input\n\t\t\t\tclass='p-input'\n\t\t\t\ttype='checkbox'\n\t\t\t\tonChange={ev => this._checkboxChange(ev?.target, rowIndex)}\n\t\t\t\tdisabled={\n\t\t\t\t\t(this.canSelectKey && !item[this.canSelectKey]) ||\n\t\t\t\t\t(this._rowSelectionLimit !== undefined &&\n\t\t\t\t\t\t!selectionContains &&\n\t\t\t\t\t\tthis.selectedRows.length === this._rowSelectionLimit)\n\t\t\t\t}\n\t\t\t\tchecked={selectionContains}\n\t\t\t/>\n\t\t);\n\t}\n\n\tprivate _getEmptyState() {\n\t\tif (this.query?.length || this.selectedFiltersAmount) {\n\t\t\treturn (\n\t\t\t\t<div class='flex max-w-[20rem] flex-col items-center self-center py-24 text-center'>\n\t\t\t\t\t<p-illustration\n\t\t\t\t\t\tvariant='empty-state-search'\n\t\t\t\t\t\tclass='mb-6'\n\t\t\t\t\t/>\n\t\t\t\t\t<p class='text-storm-default font-semibold'>\n\t\t\t\t\t\t{this.emptyStateFilteredHeader()}\n\t\t\t\t\t</p>\n\t\t\t\t\t<p class='mb-14 text-sm text-storm-medium'>\n\t\t\t\t\t\t{this.emptyStateFilteredContent()}\n\t\t\t\t\t</p>\n\t\t\t\t</div>\n\t\t\t);\n\t\t}\n\n\t\treturn (\n\t\t\t<div\n\t\t\t\tclass={`flex max-w-[20rem] flex-col items-center self-center py-24 text-center ${\n\t\t\t\t\tthis.enableEmptyStateAction && 'cursor-pointer'\n\t\t\t\t}`}\n\t\t\t\tonClick={() =>\n\t\t\t\t\tthis.enableEmptyStateAction && this.emptyStateActionClick.emit(null)\n\t\t\t\t}\n\t\t\t>\n\t\t\t\t<p-illustration\n\t\t\t\t\tvariant='empty-state-add'\n\t\t\t\t\tclass='mb-6'\n\t\t\t\t/>\n\t\t\t\t<p class='text-storm-default font-semibold'>\n\t\t\t\t\t{this.emptyStateHeader()}\n\t\t\t\t</p>\n\t\t\t\t<p class='mb-6 text-sm text-storm-medium'>{this.emptyStateContent()}</p>\n\t\t\t\t{this.enableEmptyStateAction && (\n\t\t\t\t\t<p-button\n\t\t\t\t\t\tvariant='secondary'\n\t\t\t\t\t\ticon='plus'\n\t\t\t\t\t\tsize='small'\n\t\t\t\t\t>\n\t\t\t\t\t\t{this.emptyStateAction()}\n\t\t\t\t\t</p-button>\n\t\t\t\t)}\n\t\t\t</div>\n\t\t);\n\t}\n\n\tprivate _selectAllChange($event: any, forceValue?: boolean) {\n\t\tif (!this._enableRowSelection) {\n\t\t\treturn;\n\t\t}\n\n\t\tconst value =\n\t\t\tforceValue === undefined\n\t\t\t\t? this._getCheckedValue($event.target)\n\t\t\t\t: forceValue;\n\t\tif (value) {\n\t\t\tconst toAdd = [];\n\t\t\tfor (let i = 0; i < this._items.length; i++) {\n\t\t\t\tconst row = this._items[i];\n\t\t\t\tif (this.canSelectKey && !row[this.canSelectKey]) {\n\t\t\t\t\tcontinue;\n\t\t\t\t}\n\n\t\t\t\tif (this._selectionContains(i)) {\n\t\t\t\t\tcontinue;\n\t\t\t\t}\n\n\t\t\t\ttoAdd.push(row);\n\t\t\t\tthis.rowSelected.emit(row);\n\n\t\t\t\tif (\n\t\t\t\t\tthis._rowSelectionLimit !== undefined &&\n\t\t\t\t\tthis.selectedRows.length + toAdd.length === this._rowSelectionLimit\n\t\t\t\t) {\n\t\t\t\t\tbreak;\n\t\t\t\t}\n\t\t\t}\n\n\t\t\tthis.selectedRows = [...this.selectedRows, ...toAdd];\n\t\t\tthis.selectedRowsChange.emit(this.selectedRows);\n\t\t\tif (this.enableFloatingMenu && !this._floatingMenuShown) {\n\t\t\t\tthis._showFloatingMenu();\n\t\t\t}\n\n\t\t\treturn;\n\t\t}\n\n\t\tfor (let i = 0; i < this.selectedRows.length; i++) {\n\t\t\tconst value = this.selectedRows[i];\n\t\t\tconst row = this._items.find(\n\t\t\t\td => this._getSelectionValue(d, i) === this._getSelectionValue(value, i)\n\t\t\t);\n\n\t\t\tif (!row) {\n\t\t\t\tcontinue;\n\t\t\t}\n\n\t\t\tthis.rowDeselected.emit(row);\n\t\t}\n\n\t\tthis.selectedRows = [];\n\t\tthis.selectedRowsChange.emit(this.selectedRows);\n\t}\n\n\tprivate _checkboxChange(target: any, index: number) {\n\t\tif (!this._enableRowSelection) {\n\t\t\treturn;\n\t\t}\n\n\t\tconst value = this._getCheckedValue(target);\n\t\tif (\n\t\t\tvalue &&\n\t\t\tthis._rowSelectionLimit !== undefined &&\n\t\t\tthis.selectedRows.length >= this._rowSelectionLimit\n\t\t) {\n\t\t\ttarget.checked = false;\n\t\t\treturn;\n\t\t}\n\n\t\tconst row = this._items[index];\n\n\t\tif (this.canSelectKey && !row[this.canSelectKey]) {\n\t\t\ttarget.checked = false;\n\t\t\treturn;\n\t\t}\n\n\t\tif (value) {\n\t\t\tthis.selectedRows = [\n\t\t\t\t...this.selectedRows,\n\t\t\t\t{\n\t\t\t\t\t...row,\n\t\t\t\t\tindex,\n\t\t\t\t},\n\t\t\t];\n\t\t\tthis.selectedRowsChange.emit(this.selectedRows);\n\t\t\tthis.rowSelected.emit(row);\n\n\t\t\tif (this.enableFloatingMenu && !this._floatingMenuShown) {\n\t\t\t\tthis._showFloatingMenu();\n\t\t\t}\n\n\t\t\treturn;\n\t\t}\n\n\t\tconst indexOfToRemove = this._selectionContains(index, true);\n\n\t\t// we need to do this, because splice does not trigger the selection setter.\n\t\tconst selection = [...this.selectedRows];\n\t\tselection.splice(indexOfToRemove, 1);\n\t\tthis.selectedRows = selection;\n\t\tthis.selectedRowsChange.emit(this.selectedRows);\n\t\tthis.rowDeselected.emit(row);\n\t}\n\n\tprivate _getCheckedValue(target: any) {\n\t\treturn target?.checked;\n\t}\n\n\tprivate _getSelectionValue(row: any, index: number) {\n\t\treturn this.selectionKey ? row?.[this.selectionKey] || index : index;\n\t}\n\n\tprivate _selectionContains(index, returnIndex = false): any {\n\t\tconst returnValue = this.selectedRows.findIndex(\n\t\t\titem => item.index === index\n\t\t);\n\t\treturn !returnIndex ? returnValue >= 0 : returnValue;\n\t}\n\n\tprivate _selectionContainsAll() {\n\t\tlet returnValue = true;\n\t\tif (!this._items?.length) {\n\t\t\treturn false;\n\t\t}\n\n\t\tif (\n\t\t\tthis._rowSelectionLimit !== undefined &&\n\t\t\tthis.selectedRows.length === this._rowSelectionLimit\n\t\t) {\n\t\t\treturn true;\n\t\t}\n\n\t\tfor (let i = 0; i < this._items?.length; i++) {\n\t\t\tconst contains = this._selectionContains(i);\n\n\t\t\tif (!contains) {\n\t\t\t\treturnValue = false;\n\t\t\t\tbreak;\n\t\t\t}\n\t\t}\n\n\t\treturn returnValue;\n\t}\n\n\tprivate _selectionIndeterminate() {\n\t\tif (!this._items?.length || !this.selectedRows?.length) {\n\t\t\treturn false;\n\t\t}\n\n\t\tif (\n\t\t\tthis._rowSelectionLimit !== undefined &&\n\t\t\tthis.selectedRows.length === this._rowSelectionLimit\n\t\t) {\n\t\t\treturn false;\n\t\t}\n\n\t\tlet containsCount = 0;\n\t\tfor (let i = 0; i < this._items?.length; i++) {\n\t\t\tconst contains = this._selectionContains(i);\n\n\t\t\tif (contains) {\n\t\t\t\tcontainsCount++;\n\t\t\t}\n\t\t}\n\n\t\treturn containsCount > 0 && containsCount !== this._items.length;\n\t}\n\n\tprivate _rowClick($event, index) {\n\t\tconst target = $event.target;\n\n\t\tif (\n\t\t\ttarget.tagName.toLowerCase() === 'input' ||\n\t\t\ttarget.type === 'checkbox'\n\t\t) {\n\t\t\treturn;\n\t\t}\n\n\t\tconst row = this._findRow($event.target);\n\t\tconst action = this._findRowAction($event.target);\n\n\t\tif (action) {\n\t\t\treturn;\n\t\t}\n\n\t\tif (this.enableRowClick) {\n\t\t\tconst item = this._items[index];\n\t\t\tthis.rowClick.emit({\n\t\t\t\titem,\n\t\t\t\tctrlDown: this._ctrlDown,\n\t\t\t});\n\t\t\treturn;\n\t\t}\n\n\t\tif (!this._enableRowSelection) {\n\t\t\treturn;\n\t\t}\n\n\t\tconst checkbox = row?.querySelector('input[type=\"checkbox\"]');\n\n\t\tif (!checkbox) {\n\t\t\treturn;\n\t\t}\n\n\t\tcheckbox.checked = !checkbox.checked;\n\t\tthis._checkboxChange(checkbox, index);\n\t}\n\n\tprivate _findRow(el: HTMLElement) {\n\t\tif (!el) {\n\t\t\treturn el;\n\t\t}\n\n\t\tif (el?.tagName?.toLowerCase() === 'p-table-row') {\n\t\t\treturn el;\n\t\t}\n\n\t\treturn this._findRow(el?.parentElement);\n\t}\n\n\tprivate _findRowAction(el: HTMLElement) {\n\t\tif (!el) {\n\t\t\treturn null;\n\t\t}\n\n\t\tif (\n\t\t\tel.getAttribute('data-is-action') !== null &&\n\t\t\tel.getAttribute('data-is-action') !== 'false'\n\t\t) {\n\t\t\treturn el;\n\t\t}\n\n\t\tif (el?.tagName?.toLowerCase() === 'p-table-row') {\n\t\t\treturn null;\n\t\t}\n\n\t\treturn this._findRowAction(el?.parentElement);\n\t}\n\n\tprivate _showFloatingMenu() {\n\t\tlet actions = this._rowActionsFloatingAll;\n\t\tif (\n\t\t\tthis.rowSelectionLimit === 1 &&\n\t\t\tactions.findIndex(\n\t\t\t\ta => (a.type === 'single' || a.type === 'both') && a.showFunction\n\t\t\t) >= 0\n\t\t) {\n\t\t\tactions = actions.filter(\n\t\t\t\ta =>\n\t\t\t\t\ta.type === 'multi' ||\n\t\t\t\t\t!a.showFunction ||\n\t\t\t\t\ta.showFunction(this.selectedRows[0])\n\t\t\t);\n\t\t}\n\n\t\tthis._rowActionsFloating = actions;\n\t\tthis._floatingMenuShown = true;\n\t}\n\n\tprivate _parseDefinitions(definitionsArray: HTMLPTableColumnElement[]) {\n\t\tconst definitions = definitionsArray.map(definition => {\n\t\t\tdefinition = this._parseDefinitionSizes(definition);\n\t\t\tdefinition.isLast = {};\n\t\t\treturn definition;\n\t\t});\n\n\t\tconst matchedIsLast = tableColumSizesOptions.reduce(\n\t\t\t(data: { [key: string]: boolean }, size) => {\n\t\t\t\tdata[size] = false;\n\t\t\t\treturn data;\n\t\t\t},\n\t\t\t{}\n\t\t);\n\n\t\tfor (let i = definitions.length - 1; i >= 0; i--) {\n\t\t\tconst definition = definitions[i];\n\n\t\t\tfor (const size of tableColumSizesOptions) {\n\t\t\t\tif (matchedIsLast[size]) {\n\t\t\t\t\tdefinition.isLast[size] = false;\n\t\t\t\t\tcontinue;\n\t\t\t\t}\n\n\t\t\t\tif (definition.parsedSizes![size] === 'hidden') {\n\t\t\t\t\tdefinition.isLast[size] = false;\n\t\t\t\t\tcontinue;\n\t\t\t\t}\n\n\t\t\t\tconst isLastAtSizeFound = this._findLastDefinitionBySize(\n\t\t\t\t\tdefinitions,\n\t\t\t\t\tsize\n\t\t\t\t);\n\t\t\t\tif (isLastAtSizeFound) {\n\t\t\t\t\tdefinition.isLast[size] = false;\n\t\t\t\t\tcontinue;\n\t\t\t\t}\n\n\t\t\t\tdefinition.isLast[size] = true;\n\t\t\t}\n\t\t}\n\n\t\treturn definitions;\n\t}\n\n\tprivate _findLastDefinitionBySize(\n\t\tdefinitions: HTMLPTableColumnElement[],\n\t\tsize: string\n\t) {\n\t\treturn definitions\n\t\t\t.slice()\n\t\t\t.reverse()\n\t\t\t.find(d => d.isLast[size] === true);\n\t}\n\n\tprivate _parseDefinitionSizes(definition: HTMLPTableColumnElement) {\n\t\tconst definitionAny = definition as any;\n\t\tlet parsedSizes: TableColumnSizes = { default: 'full' };\n\n\t\tif (\n\t\t\ttypeof definition.sizes === 'string' &&\n\t\t\t!['auto', 'hidden', 'full'].includes(definition.sizes)\n\t\t) {\n\t\t\tdefinition.sizes = JSON.parse(definition.sizes);\n\t\t}\n\n\t\tfor (const [index, size] of tableColumSizesOptions.entries()) {\n\t\t\tif (\n\t\t\t\tdefinitionAny.sizes === 'auto' ||\n\t\t\t\tdefinitionAny.sizes === 'hidden' ||\n\t\t\t\tdefinitionAny.sizes === 'full' ||\n\t\t\t\ttypeof definitionAny.sizes === 'number'\n\t\t\t) {\n\t\t\t\tparsedSizes[size] =\n\t\t\t\t\tdefinitionAny.sizes === 'auto' ? 'full' : definitionAny.sizes;\n\t\t\t\tcontinue;\n\t\t\t}\n\n\t\t\tparsedSizes[size] =\n\t\t\t\tdefinitionAny.sizes[size] ??\n\t\t\t\tparsedSizes[tableColumSizesOptions[index - 1]];\n\t\t}\n\n\t\tdefinition.parsedSizes = parsedSizes;\n\t\treturn definition;\n\t}\n\n\tprivate _parseRowActionsRowDefinition() {\n\t\tconst isLast = tableColumSizesOptions.reduce(\n\t\t\t(data: { [key: string]: boolean }, size) => {\n\t\t\t\tdata[size] = true;\n\t\t\t\treturn data;\n\t\t\t},\n\t\t\t{}\n\t\t);\n\t\tconst sizes: TableColumnSizes = { default: 0 };\n\n\t\tfor (const size of tableColumSizesOptions) {\n\t\t\tconst lastColumn = this._findLastDefinitionBySize(this._columns, size);\n\t\t\tsizes[size] = lastColumn!.parsedSizes![size]!;\n\t\t}\n\n\t\treturn {\n\t\t\tisLast,\n\t\t\tsizes,\n\t\t\tparsedSizes: sizes,\n\t\t\talign: 'end',\n\t\t\ttype: 'td',\n\t\t\tpath: null,\n\t\t} as TableColumn;\n\t}\n}\n"],"version":3}
|
|
1
|
+
{"file":"p-table.entry.js","mappings":";;;;;AAAA,MAAM,iBAAiB,GAAG,kpGAAkpG;;MCuC/pG,KAAK;;;;;;;;;;;;;;;;IAsVT,2BAAsB,GAAqB,EAAE,CAAC;IAI9C,cAAS,GAAG,KAAK,CAAC;IAClB,yBAAoB,GAAG,KAAK,CAAC;IAC7B,0BAAqB,GAAG,KAAK,CAAC;IAC9B,uBAAkB,GAAG,KAAK,CAAC;;mBApVR,KAAK;yBAKC,KAAK;yBAKL,KAAK;+BAKA,CAAC;8BAKD,IAAI;;0BAUR,IAA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Y,CAAC,IAAI,CAAE,CAAC;KAC9C;IAED,OAAO;MACN,MAAM;MACN,KAAK;MACL,WAAW,EAAE,KAAK;MAClB,KAAK,EAAE,KAAK;MACZ,IAAI,EAAE,IAAI;MACV,IAAI,EAAE,IAAI;KACK,CAAC;GACjB;;;;;;;;;;;;;","names":[],"sources":["src/components/organisms/table/table.component.scss?tag=p-table","src/components/organisms/table/table.component.tsx"],"sourcesContent":["p-table {\n\t@apply relative flex flex-col;\n\n\t.p-input[type='checkbox'] {\n\t\tflex-shrink: 0;\n\t}\n\n\tp-table-container {\n\t\t@apply relative;\n\n\t\tp-floating-menu-container {\n\t\t\t@apply fixed bottom-4 left-1/2 -translate-x-1/2 transform;\n\t\t\tanimation: forwards floatingMenuContainerIn 0.3s ease !important;\n\n\t\t\t@screen tablet {\n\t\t\t\t@apply absolute bottom-16;\n\t\t\t}\n\n\t\t\t&:not(.shown) {\n\t\t\t\t@apply hidden;\n\t\t\t}\n\n\t\t\t&.inactive {\n\t\t\t\tanimation: forwards floatingMenuContainerOut 0.3s ease !important;\n\t\t\t}\n\t\t}\n\t}\n}\n\n@keyframes floatingMenuContainerOut {\n\t0% {\n\t\tdisplay: flex;\n\t\ttransform: translateY(0) translateX(-50%);\n\t\topacity: 100;\n\t}\n\t99% {\n\t\ttransform: translateY(100%) translateX(-50%);\n\t\topacity: 0;\n\t\tdisplay: flex;\n\t}\n\t100% {\n\t\ttransform: translateY(100%) translateX(-50%);\n\t\topacity: 0;\n\t\tdisplay: none;\n\t}\n}\n\n@keyframes floatingMenuContainerIn {\n\t0% {\n\t\ttransform: translateY(100%) translateX(-50%);\n\t\topacity: 0;\n\t\tdisplay: none;\n\t}\n\t1% {\n\t\ttransform: translateY(100%) translateX(-50%);\n\t\topacity: 0;\n\t\tdisplay: flex;\n\t}\n\t100% {\n\t\ttransform: translateY(0) translateX(-50%);\n\t\topacity: 100;\n\t\tdisplay: flex;\n\t}\n}\n","import {\n\tComponent,\n\tElement,\n\tEvent,\n\tEventEmitter,\n\th,\n\tHost,\n\tListen,\n\tProp,\n\tState,\n\tWatch,\n} from '@stencil/core';\nimport { IconVariant } from '../../../components';\nimport { tableColumSizesOptions } from '../../../types/constants';\nimport {\n\tQuickFilter,\n\tRowClickEvent,\n\tTableColumnSizes,\n} from '../../../types/table';\nimport {\n\tformatTranslation,\n\tgetLocaleComponentStrings,\n\tisMobile,\n} from '../../../utils';\nimport { TableColumn } from '../../helpers/table-column/table-column.component';\nimport { TableRowAction } from '../../helpers/table-row-action/table-row-action.component';\nimport {\n\tdefaultSize,\n\tdefaultSizeOptions,\n} from '../../molecules/page-size-select/constants';\nimport { buttonTemplateFunc } from '../../molecules/table-header/table-header.component';\n\nexport type templateFunc = () => string;\nexport type amountSelectedTemplateFunc = (amount: number) => string;\n\n@Component({\n\ttag: 'p-table',\n\tstyleUrl: 'table.component.scss',\n})\nexport class Table {\n\t/**\n\t * The items to be fed to the table\n\t */\n\t@Prop() items: string;\n\n\t/**\n\t * Wether data is loading\n\t */\n\t@Prop() loading: boolean = false;\n\n\t/**\n\t * Wether the header should show loading state\n\t */\n\t@Prop() headerLoading: boolean = false;\n\n\t/**\n\t * Wether the footer should show loading state\n\t */\n\t@Prop() footerLoading: boolean = false;\n\n\t/**\n\t * The amount of loading rows to show\n\t */\n\t@Prop() amountOfLoadingRows: number = 6;\n\n\t/**\n\t * Wether to enable selection\n\t */\n\t@Prop() enableRowSelection: boolean = true;\n\n\t/**\n\t * A limit to the amount of rows that can be selected\n\t */\n\t@Prop() rowSelectionLimit: number | undefined;\n\n\t/**\n\t * Wether to enable row clicking\n\t */\n\t@Prop() enableRowClick: boolean = true;\n\n\t/**\n\t * The current selection of items\n\t */\n\t@Prop() selectedRows: any[] = [];\n\n\t/**\n\t * Wether to enable the floating menu\n\t */\n\t@Prop() enableFloatingMenu: boolean = true;\n\n\t/**\n\t * The template for amount selected item in the floating menu\n\t */\n\t@Prop() floatingMenuAmountSelectedTemplate: amountSelectedTemplateFunc = (\n\t\tamount: number\n\t) =>\n\t\tformatTranslation(\n\t\t\t(amount === 1\n\t\t\t\t? this._locales.floating_menu?.amount_selected\n\t\t\t\t: this._locales.floating_menu?.amount_selected_plural\n\t\t\t)?.replace('{{amount}}', amount)\n\t\t);\n\n\t/**\n\t * Event whenever the current selection changes\n\t */\n\t@Event({\n\t\tbubbles: false,\n\t})\n\tselectedRowsChange: EventEmitter<any>;\n\n\t/**\n\t * The key to determine if a row is selected\n\t */\n\t@Prop() selectionKey: string;\n\n\t/**\n\t * A key to determine if a row can be selected\n\t */\n\t@Prop() canSelectKey: string;\n\n\t/**\n\t * Event whenever a row is clicked\n\t */\n\t@Event({\n\t\tbubbles: false,\n\t})\n\trowClick: EventEmitter<RowClickEvent>;\n\n\t/**\n\t * Event whenever a row is selected\n\t */\n\t@Event({\n\t\tbubbles: false,\n\t})\n\trowSelected: EventEmitter<any>;\n\n\t/**\n\t * Event whenever a row is deselected\n\t */\n\t@Event({\n\t\tbubbles: false,\n\t})\n\trowDeselected: EventEmitter<any>;\n\n\t/**\n\t * Event when the table has rendered\n\t */\n\t@Event({\n\t\tbubbles: false,\n\t})\n\thasRendered: EventEmitter<number>;\n\n\t/** START HEADER */\n\n\t/**\n\t * Wether to show the header\n\t */\n\t@Prop() enableHeader: boolean = true;\n\n\t/**\n\t * Quick filters to show\n\t */\n\t@Prop() quickFilters: QuickFilter[] = [];\n\n\t/**\n\t * Active quick filter identifier\n\t */\n\t@Prop() activeQuickFilterIdentifier: string;\n\n\t/**\n\t * Wether to show the search input\n\t */\n\t@Prop() enableSearch: boolean = true;\n\n\t/**\n\t * The query to show in the search bar\n\t */\n\t@Prop({ mutable: true }) query: string;\n\n\t/**\n\t * Wether to show the filter button\n\t */\n\t@Prop() enableFilter: boolean = true;\n\n\t/**\n\t * Wether to show the filter button on desktop\n\t */\n\t@Prop() enableFilterDesktop: boolean = true;\n\n\t/**\n\t * The amount of filters being selected\n\t */\n\t@Prop() selectedFiltersAmount: number;\n\n\t/**\n\t * The template for the filter button text\n\t */\n\t@Prop() filterButtonTemplate: templateFunc;\n\n\t/**\n\t * Wether to show the action button\n\t */\n\t@Prop() enableAction: boolean = false;\n\n\t/**\n\t * Wether the action button is loading\n\t */\n\t@Prop() actionButtonLoading: boolean = false;\n\n\t/**\n\t * Wether the action button is enabled\n\t */\n\t@Prop() actionButtonEnabled: boolean = false;\n\n\t/**\n\t * The action button icon\n\t */\n\t@Prop() actionButtonIcon: IconVariant = 'pencil';\n\n\t/**\n\t * The action button text if changed\n\t */\n\t@Prop() actionButtonText: string;\n\n\t/**\n\t * The template for the action button text\n\t */\n\t@Prop() actionButtonTemplate: buttonTemplateFunc;\n\n\t/**\n\t * Event when one of the quick filters is clicked\n\t */\n\t@Event({\n\t\tbubbles: false,\n\t})\n\tquickFilter: EventEmitter<QuickFilter>;\n\n\t/**\n\t * Event when the query changes\n\t */\n\t@Event({\n\t\tbubbles: false,\n\t})\n\tqueryChange: EventEmitter<string>;\n\n\t/**\n\t * Event when the filter button is clicked\n\t */\n\t@Event({\n\t\tbubbles: false,\n\t})\n\tfilter: EventEmitter<null>;\n\n\t/**\n\t * Event when the action button is clicked\n\t */\n\t@Event({\n\t\tbubbles: false,\n\t})\n\taction: EventEmitter<null>;\n\n\t/** START FOOTER */\n\n\t/**\n\t * Wether to show the header\n\t */\n\t@Prop() enableFooter: boolean = true;\n\n\t/**\n\t * Wether to enable page size select\n\t */\n\t@Prop() enablePageSize: boolean = true;\n\n\t/**\n\t * Wether to enable pagination\n\t */\n\t@Prop() enablePagination: boolean = true;\n\n\t/**\n\t * Wether to enable export\n\t */\n\t@Prop() enableExport: boolean = true;\n\n\t/**\n\t * The current page\n\t */\n\t@Prop({ mutable: true, reflect: true }) page: number = 1;\n\n\t/**\n\t * The total amount of items\n\t */\n\t@Prop() total!: number;\n\n\t/**\n\t * Event whenever the page changes\n\t */\n\t@Event({\n\t\tbubbles: false,\n\t})\n\tpageChange: EventEmitter<number>;\n\n\t/**\n\t * The amount of items per page\n\t */\n\t@Prop() pageSize: number = defaultSize;\n\n\t/**\n\t * The options for the page size\n\t */\n\t@Prop() pageSizeOptions: number[] = defaultSizeOptions;\n\n\t/**\n\t * Event whenever the page changes\n\t */\n\t@Event({\n\t\tbubbles: false,\n\t})\n\tpageSizeChange: EventEmitter<number>;\n\n\t/**\n\t * Event whenever the page changes\n\t */\n\t@Event({\n\t\tbubbles: false,\n\t})\n\texport: EventEmitter<number>;\n\n\t/**\n\t * Wether to hide when there is only 1 page available\n\t */\n\t@Prop() hideOnSinglePage: boolean = true;\n\n\t/* Empty state start */\n\t@Prop() emptyStateHeader: templateFunc = () =>\n\t\tformatTranslation(this._locales.empty_state?.no_filter.header);\n\t@Prop() emptyStateContent: templateFunc = () =>\n\t\tformatTranslation(this._locales.empty_state?.no_filter.content);\n\t@Prop() emptyStateAction: templateFunc = () =>\n\t\tformatTranslation(this._locales.empty_state?.no_filter.action);\n\t/**\n\t * Wether to enable empty state action\n\t */\n\t@Prop() enableEmptyStateAction: boolean = true;\n\n\t@Prop() emptyStateFilteredHeader: templateFunc = () =>\n\t\tformatTranslation(this._locales.empty_state.filtered.header);\n\t@Prop() emptyStateFilteredContent: templateFunc = () =>\n\t\tformatTranslation(this._locales.empty_state.filtered.content);\n\n\t/**\n\t * Event whenever the empty state is clicked\n\t */\n\t@Event({\n\t\tbubbles: false,\n\t})\n\temptyStateActionClick: EventEmitter<null>;\n\n\t/*\n\t * Wether to show the shadow or not\n\t */\n\t@Prop() shadow: boolean = true;\n\n\t/* Empty state end */\n\n\t/**\n\t * The host element\n\t */\n\t@Element() private _el: HTMLElement;\n\n\t/**\n\t * Locales used for this component\n\t */\n\t@State() private _locales: any = {};\n\n\t@State() private _columns: any[] = [];\n\t@State() private _items: any[] = [];\n\n\t@State() private _enableRowSelection: boolean = this.enableRowSelection;\n\t@State() private _rowSelectionLimit: number | undefined;\n\n\tprivate _rowActionsFloatingAll: TableRowAction[] = [];\n\t@State() private _rowActionsFloating: TableRowAction[] = [];\n\t@State() private _rowActionsRow: TableRowAction[] = [];\n\n\tprivate _ctrlDown = false;\n\tprivate _hasCustomFilterSlot = false;\n\tprivate _hasCustomActionsSlot = false;\n\tprivate _floatingMenuShown = false;\n\tprivate _resizeTimeout: NodeJS.Timer;\n\n\tcomponentWillLoad() {\n\t\tthis._hasCustomFilterSlot = !!this._el.querySelector(\n\t\t\t':scope > [slot=\"custom-filter\"]'\n\t\t);\n\n\t\tthis._hasCustomActionsSlot = !!this._el.querySelector(\n\t\t\t':scope > [slot=\"custom-actions\"]'\n\t\t);\n\n\t\tthis._setRowSelectionData();\n\n\t\tthis._setLocales();\n\t\tthis._parseItems(this.items);\n\t\tthis._generateColumns();\n\t}\n\n\tcomponentDidRender() {\n\t\tthis.hasRendered.emit();\n\t}\n\n\trender() {\n\t\treturn (\n\t\t\t<Host class='p-table'>\n\t\t\t\t<p-table-container shadow={this.shadow}>\n\t\t\t\t\t{this.enableHeader && (\n\t\t\t\t\t\t<p-table-header\n\t\t\t\t\t\t\t// quick filters\n\t\t\t\t\t\t\tquickFilters={this.quickFilters}\n\t\t\t\t\t\t\tactiveQuickFilterIdentifier={this.activeQuickFilterIdentifier}\n\t\t\t\t\t\t\tonQuickFilter={({ detail }) => this.quickFilter.emit(detail)}\n\t\t\t\t\t\t\t// search\n\t\t\t\t\t\t\tenableSearch={this.enableSearch}\n\t\t\t\t\t\t\tquery={this.query}\n\t\t\t\t\t\t\tonQueryChange={({ detail }) => this.queryChange.emit(detail)}\n\t\t\t\t\t\t\t// filter button\n\t\t\t\t\t\t\tenableFilter={this.enableFilter}\n\t\t\t\t\t\t\tenableFilterDesktop={this.enableFilterDesktop}\n\t\t\t\t\t\t\tselectedFiltersAmount={this.selectedFiltersAmount}\n\t\t\t\t\t\t\tfilterButtonTemplate={this.filterButtonTemplate}\n\t\t\t\t\t\t\tonFilter={() => this.filter.emit()}\n\t\t\t\t\t\t\t// action button\n\t\t\t\t\t\t\tenableAction={this.enableAction}\n\t\t\t\t\t\t\tactionIcon={this.actionButtonIcon}\n\t\t\t\t\t\t\tactionText={this.actionButtonText}\n\t\t\t\t\t\t\tactionLoading={this.actionButtonLoading}\n\t\t\t\t\t\t\tcanUseAction={this.actionButtonEnabled}\n\t\t\t\t\t\t\tactionButtonTemplate={this.actionButtonTemplate}\n\t\t\t\t\t\t\tonAction={() => this.action.emit()}\n\t\t\t\t\t\t\titemsSelectedAmount={this.selectedRows?.length}\n\t\t\t\t\t\t\t//loading\n\t\t\t\t\t\t\tloading={this.headerLoading}\n\t\t\t\t\t\t>\n\t\t\t\t\t\t\t{this._hasCustomFilterSlot && (\n\t\t\t\t\t\t\t\t<slot\n\t\t\t\t\t\t\t\t\tname='custom-filter'\n\t\t\t\t\t\t\t\t\tslot='custom-filter'\n\t\t\t\t\t\t\t\t/>\n\t\t\t\t\t\t\t)}\n\n\t\t\t\t\t\t\t{this._hasCustomActionsSlot && (\n\t\t\t\t\t\t\t\t<slot\n\t\t\t\t\t\t\t\t\tname='custom-actions'\n\t\t\t\t\t\t\t\t\tslot='custom-actions'\n\t\t\t\t\t\t\t\t/>\n\t\t\t\t\t\t\t)}\n\t\t\t\t\t\t</p-table-header>\n\t\t\t\t\t)}\n\n\t\t\t\t\t{this._getHeader()}\n\t\t\t\t\t<div class='flex flex-1 flex-col'>{this._getRows()}</div>\n\n\t\t\t\t\t{this.enableFooter && (\n\t\t\t\t\t\t<p-table-footer\n\t\t\t\t\t\t\t// overall\n\t\t\t\t\t\t\thideOnSinglePage={this.hideOnSinglePage}\n\t\t\t\t\t\t\t// page size select\n\t\t\t\t\t\t\tenablePageSize={this.enablePageSize}\n\t\t\t\t\t\t\tpageSize={this.pageSize}\n\t\t\t\t\t\t\tpageSizeOptions={this.pageSizeOptions}\n\t\t\t\t\t\t\tonPageSizeChange={({ detail }) =>\n\t\t\t\t\t\t\t\tthis.pageSizeChange.emit(detail)\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t// pagination\n\t\t\t\t\t\t\tenablePagination={this.enablePagination}\n\t\t\t\t\t\t\tpage={this.page}\n\t\t\t\t\t\t\ttotal={this.total}\n\t\t\t\t\t\t\tonPageChange={({ detail }) => this.pageChange.emit(detail)}\n\t\t\t\t\t\t\t// export\n\t\t\t\t\t\t\tenableExport={this.enableExport}\n\t\t\t\t\t\t\tonExport={() => this.export.emit()}\n\t\t\t\t\t\t\t//loading\n\t\t\t\t\t\t\tloading={this.footerLoading}\n\t\t\t\t\t\t></p-table-footer>\n\t\t\t\t\t)}\n\n\t\t\t\t\t{this.enableFloatingMenu && this._enableRowSelection ? (\n\t\t\t\t\t\t<p-floating-menu-container\n\t\t\t\t\t\t\tusedInTable={true}\n\t\t\t\t\t\t\tclass={`${this.selectedRows?.length ? '' : 'inactive'} ${\n\t\t\t\t\t\t\t\tthis._floatingMenuShown ? 'shown' : ''\n\t\t\t\t\t\t\t}`}\n\t\t\t\t\t\t>\n\t\t\t\t\t\t\t<p-floating-menu-item\n\t\t\t\t\t\t\t\thover={false}\n\t\t\t\t\t\t\t\tslot='floating-menu-item'\n\t\t\t\t\t\t\t\tclass={\n\t\t\t\t\t\t\t\t\tthis._rowActionsFloating?.length ? 'hidden tablet:flex' : ''\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t>\n\t\t\t\t\t\t\t\t{this.floatingMenuAmountSelectedTemplate(\n\t\t\t\t\t\t\t\t\tthis.selectedRows?.length\n\t\t\t\t\t\t\t\t)}\n\t\t\t\t\t\t\t</p-floating-menu-item>\n\t\t\t\t\t\t\t<p-divider\n\t\t\t\t\t\t\t\tclass={`mx-0 text-storm ${\n\t\t\t\t\t\t\t\t\tthis._rowActionsFloating?.length ? 'hidden tablet:flex' : ''\n\t\t\t\t\t\t\t\t}`}\n\t\t\t\t\t\t\t\tvariant='vertical'\n\t\t\t\t\t\t\t\tslot='floating-menu-item'\n\t\t\t\t\t\t\t/>\n\t\t\t\t\t\t\t{this._rowActionsFloating?.length &&\n\t\t\t\t\t\t\t\tthis._rowActionsFloating.map(a => (\n\t\t\t\t\t\t\t\t\t<p-floating-menu-item\n\t\t\t\t\t\t\t\t\t\tslot='floating-menu-item'\n\t\t\t\t\t\t\t\t\t\tdisabled={a.disabled}\n\t\t\t\t\t\t\t\t\t\tonClick={() =>\n\t\t\t\t\t\t\t\t\t\t\t!a.disabled &&\n\t\t\t\t\t\t\t\t\t\t\t!a.loading &&\n\t\t\t\t\t\t\t\t\t\t\t!!a.action &&\n\t\t\t\t\t\t\t\t\t\t\ta.type === 'single'\n\t\t\t\t\t\t\t\t\t\t\t\t? a.action(this.selectedRows[0], false)\n\t\t\t\t\t\t\t\t\t\t\t\t: a.action(this.selectedRows, true)\n\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t>\n\t\t\t\t\t\t\t\t\t\t{a.label}{' '}\n\t\t\t\t\t\t\t\t\t\t{a.loading ? (\n\t\t\t\t\t\t\t\t\t\t\t<p-loader></p-loader>\n\t\t\t\t\t\t\t\t\t\t) : (\n\t\t\t\t\t\t\t\t\t\t\t<p-icon\n\t\t\t\t\t\t\t\t\t\t\t\tvariant={a.icon}\n\t\t\t\t\t\t\t\t\t\t\t\trotate={a.iconRotate}\n\t\t\t\t\t\t\t\t\t\t\t\tflip={a.iconFlip}\n\t\t\t\t\t\t\t\t\t\t\t/>\n\t\t\t\t\t\t\t\t\t\t)}\n\t\t\t\t\t\t\t\t\t</p-floating-menu-item>\n\t\t\t\t\t\t\t\t))}\n\t\t\t\t\t\t\t{this._rowActionsFloating?.length && (\n\t\t\t\t\t\t\t\t<p-divider\n\t\t\t\t\t\t\t\t\tclass='mx-0 text-storm'\n\t\t\t\t\t\t\t\t\tvariant='vertical'\n\t\t\t\t\t\t\t\t\tslot='floating-menu-item'\n\t\t\t\t\t\t\t\t/>\n\t\t\t\t\t\t\t)}\n\t\t\t\t\t\t\t<p-floating-menu-item\n\t\t\t\t\t\t\t\tslot='floating-menu-item'\n\t\t\t\t\t\t\t\tonClick={() => this._selectAllChange(null, false)}\n\t\t\t\t\t\t\t>\n\t\t\t\t\t\t\t\t<p-icon variant='negative' />\n\t\t\t\t\t\t\t</p-floating-menu-item>\n\t\t\t\t\t\t</p-floating-menu-container>\n\t\t\t\t\t) : (\n\t\t\t\t\t\t''\n\t\t\t\t\t)}\n\t\t\t\t</p-table-container>\n\t\t\t</Host>\n\t\t);\n\t}\n\n\t@Listen('localeChanged', { target: 'body' })\n\tprivate async _setLocales(): Promise<void> {\n\t\tthis._locales = await getLocaleComponentStrings(this._el);\n\t}\n\n\t@Listen('tableDefinitionChanged', { target: 'body' })\n\tonTableDefinitionUpdated() {\n\t\tthis._generateColumns();\n\t}\n\n\t@Listen('keydown', { target: 'document' })\n\tkeyDown({ key }) {\n\t\tif (key !== 'Control' || this._ctrlDown === true) {\n\t\t\treturn;\n\t\t}\n\n\t\tthis._ctrlDown = true;\n\t}\n\n\t@Listen('keyup', { target: 'document' })\n\tkeyUp({ key }) {\n\t\tif (key !== 'Control' || this._ctrlDown === false) {\n\t\t\treturn;\n\t\t}\n\n\t\tthis._ctrlDown = false;\n\t}\n\n\t@Listen('visibilitychange', { target: 'document' })\n\tvisibilityChange() {\n\t\tif (document.visibilityState !== 'hidden' || this._ctrlDown === false) {\n\t\t\treturn;\n\t\t}\n\n\t\tthis._ctrlDown = false;\n\t}\n\n\t@Watch('items')\n\tprivate _parseItems(items: string) {\n\t\tif (!items) {\n\t\t\tthis._items = [];\n\t\t\treturn;\n\t\t}\n\n\t\tif (Array.isArray(items)) {\n\t\t\tthis._items = items;\n\t\t\treturn;\n\t\t}\n\n\t\tthis._items = JSON.parse(items);\n\t}\n\n\t@Watch('enableRowSelection')\n\t@Watch('rowSelectionLimit')\n\t@Watch('selectedRows')\n\t@Listen('resize', { target: 'window' })\n\tprivate _setRowSelectionData() {\n\t\tif (this._resizeTimeout) {\n\t\t\tclearTimeout(this._resizeTimeout);\n\t\t}\n\n\t\t// We add a timeout here because it's a lot easier on the machine to do these when someone is done\n\t\t// resizing and playing around with their browser\n\t\tthis._resizeTimeout = setTimeout(() => {\n\t\t\tconst mobile = isMobile();\n\n\t\t\t// we hack this to any[] to make it work..\n\t\t\tconst actions = Array.from(\n\t\t\t\tthis._el.querySelectorAll(':scope > p-table-row-action')\n\t\t\t) as any[] as TableRowAction[];\n\t\t\tthis._rowActionsRow = actions.filter(\n\t\t\t\ta => a.type === 'both' || a.type === 'single'\n\t\t\t);\n\t\t\tthis._rowActionsFloatingAll = actions\n\t\t\t\t.filter(\n\t\t\t\t\ta =>\n\t\t\t\t\t\t(this.enableRowSelection &&\n\t\t\t\t\t\t\t(a.type === 'both' || a.type === 'multi')) ||\n\t\t\t\t\t\t(mobile && a.type === 'single')\n\t\t\t\t)\n\t\t\t\t.map(a => {\n\t\t\t\t\tif (a.type === 'single') {\n\t\t\t\t\t\ta.disabled = this.selectedRows?.length > 1;\n\t\t\t\t\t}\n\n\t\t\t\t\treturn a;\n\t\t\t\t});\n\n\t\t\tlet rowSelectionLimit = this.rowSelectionLimit;\n\t\t\tif (\n\t\t\t\tmobile && // we're mobile\n\t\t\t\tthis._rowActionsFloatingAll?.length && // we have atleast 1 item in _rowActionsFloating\n\t\t\t\t((rowSelectionLimit !== undefined && this.enableRowSelection) ||\n\t\t\t\t\t!this.enableRowSelection)\n\t\t\t) {\n\t\t\t\trowSelectionLimit = 1;\n\t\t\t}\n\n\t\t\tthis._rowSelectionLimit = rowSelectionLimit;\n\n\t\t\tlet enableRowSelection = this.enableRowSelection;\n\t\t\tif (\n\t\t\t\tmobile && // we're mobile\n\t\t\t\tthis._rowActionsFloatingAll?.length && // we have atleast 1 item in _rowActionsFloating\n\t\t\t\t!enableRowSelection\n\t\t\t) {\n\t\t\t\tenableRowSelection = true;\n\t\t\t}\n\n\t\t\tthis._enableRowSelection = enableRowSelection;\n\n\t\t\tif (this._floatingMenuShown) {\n\t\t\t\tthis._showFloatingMenu();\n\t\t\t}\n\t\t}, 200);\n\t}\n\n\tprivate _generateColumns() {\n\t\tconst definitions = this._el.querySelectorAll('p-table-column');\n\t\tlet definitionsArray = Array.from(definitions);\n\n\t\tdefinitionsArray = this._parseDefinitions(definitionsArray);\n\n\t\tthis._columns = definitionsArray;\n\t}\n\n\tprivate _getHeader() {\n\t\treturn (\n\t\t\t<p-table-row variant='header'>\n\t\t\t\t{this._columns.map((col: TableColumn, index) => (\n\t\t\t\t\t<p-table-cell\n\t\t\t\t\t\tdefinition={col}\n\t\t\t\t\t\tvalue={col.name}\n\t\t\t\t\t\tvariant='header'\n\t\t\t\t\t\tcheckbox={\n\t\t\t\t\t\t\tindex === 0 || col.hasCheckbox\n\t\t\t\t\t\t\t\t? this._getCheckbox(null, this.loading ? 'loading' : 'header')\n\t\t\t\t\t\t\t\t: null\n\t\t\t\t\t\t}\n\t\t\t\t\t\tindex={index}\n\t\t\t\t\t></p-table-cell>\n\t\t\t\t))}\n\t\t\t</p-table-row>\n\t\t);\n\t}\n\n\tprivate _getRows() {\n\t\tif (this.loading) {\n\t\t\treturn Array.from(\n\t\t\t\t{\n\t\t\t\t\tlength: this.amountOfLoadingRows,\n\t\t\t\t},\n\t\t\t\t(_, i) => (\n\t\t\t\t\t<p-table-row\n\t\t\t\t\t\tenableHover={this._enableRowSelection || this.enableRowClick}\n\t\t\t\t\t>\n\t\t\t\t\t\t{this._getLoadingColumns(i)}\n\t\t\t\t\t</p-table-row>\n\t\t\t\t)\n\t\t\t);\n\t\t}\n\n\t\tif (!this._items.length) {\n\t\t\treturn this._getEmptyState();\n\t\t}\n\n\t\treturn this._items.map((item, index) => (\n\t\t\t<p-table-row\n\t\t\t\tenableHover={this._enableRowSelection || this.enableRowClick}\n\t\t\t\tonClick={ev => this._rowClick(ev, index)}\n\t\t\t>\n\t\t\t\t{this._getRowColumns(item, index)}\n\t\t\t</p-table-row>\n\t\t));\n\t}\n\n\tprivate _getRowColumns(item, index) {\n\t\tconst actions = this._rowActionsRow.filter(a =>\n\t\t\ta.showFunction ? a.showFunction(item) : true\n\t\t);\n\n\t\tconst columns = this._columns.map((col: TableColumn, colIndex) => {\n\t\t\treturn (\n\t\t\t\t<p-table-cell\n\t\t\t\t\tdefinition={col}\n\t\t\t\t\titem={item}\n\t\t\t\t\tcheckbox={\n\t\t\t\t\t\tcolIndex === 0 || col.hasCheckbox ? this._getCheckbox(index) : null\n\t\t\t\t\t}\n\t\t\t\t\tindex={colIndex}\n\t\t\t\t\trowIndex={index}\n\t\t\t\t\ttableHasActions={!!actions.length && !isMobile()}\n\t\t\t\t></p-table-cell>\n\t\t\t);\n\t\t});\n\n\t\tif (actions?.length && !isMobile()) {\n\t\t\tconst def = this._parseRowActionsRowDefinition();\n\n\t\t\tif (!actions.length) {\n\t\t\t\treturn columns;\n\t\t\t}\n\n\t\t\tcolumns.push(\n\t\t\t\t<p-table-cell\n\t\t\t\t\tvariant='actions'\n\t\t\t\t\tdefinition={def}\n\t\t\t\t\titem={item}\n\t\t\t\t\tindex={this._columns.length - 1}\n\t\t\t\t\trowIndex={index}\n\t\t\t\t\ttableHasActions={true}\n\t\t\t\t>\n\t\t\t\t\t<div\n\t\t\t\t\t\tslot='actions'\n\t\t\t\t\t\tclass='ml-auto flex items-center gap-2'\n\t\t\t\t\t>\n\t\t\t\t\t\t{actions.map(a => (\n\t\t\t\t\t\t\t<p-tooltip content={a.label}>\n\t\t\t\t\t\t\t\t<p-button\n\t\t\t\t\t\t\t\t\tdata-is-action\n\t\t\t\t\t\t\t\t\tvariant='secondary'\n\t\t\t\t\t\t\t\t\tslot='trigger'\n\t\t\t\t\t\t\t\t\ticon={a.icon}\n\t\t\t\t\t\t\t\t\ticonRotate={a.iconRotate}\n\t\t\t\t\t\t\t\t\ticonFlip={a.iconFlip}\n\t\t\t\t\t\t\t\t\ticonOnly={true}\n\t\t\t\t\t\t\t\t\tsize='small'\n\t\t\t\t\t\t\t\t\tonClick={() =>\n\t\t\t\t\t\t\t\t\t\ttypeof a.action === 'function' && a.action?.(item, false)\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t></p-button>\n\t\t\t\t\t\t\t</p-tooltip>\n\t\t\t\t\t\t))}\n\t\t\t\t\t</div>\n\t\t\t\t</p-table-cell>\n\t\t\t);\n\t\t}\n\n\t\treturn columns;\n\t}\n\n\tprivate _getLoadingColumns(index) {\n\t\treturn this._columns.map((col: TableColumn, colIndex) => {\n\t\t\treturn (\n\t\t\t\t<p-table-cell\n\t\t\t\t\tdefinition={col}\n\t\t\t\t\tvariant='loading'\n\t\t\t\t\tcheckbox={\n\t\t\t\t\t\tcolIndex === 0 || col.hasCheckbox\n\t\t\t\t\t\t\t? this._getCheckbox(index, 'loading')\n\t\t\t\t\t\t\t: null\n\t\t\t\t\t}\n\t\t\t\t\tindex={colIndex}\n\t\t\t\t\trowIndex={index}\n\t\t\t\t></p-table-cell>\n\t\t\t);\n\t\t});\n\t}\n\n\tprivate _getCheckbox(\n\t\trowIndex: number,\n\t\tvariant: 'header' | 'default' | 'loading' = 'default'\n\t) {\n\t\tif (\n\t\t\t!this._enableRowSelection ||\n\t\t\t(!this.selectionKey && !this._rowActionsFloating?.length)\n\t\t) {\n\t\t\treturn;\n\t\t}\n\n\t\tif (variant === 'loading') {\n\t\t\treturn (\n\t\t\t\t<p-loader\n\t\t\t\t\tvariant='ghost'\n\t\t\t\t\tclass='h-6 w-6 rounded'\n\t\t\t\t/>\n\t\t\t);\n\t\t}\n\n\t\tif (variant === 'header') {\n\t\t\treturn (\n\t\t\t\t<input\n\t\t\t\t\tclass={`p-input ${\n\t\t\t\t\t\tthis._rowSelectionLimit !== undefined && 'opacity-0'\n\t\t\t\t\t}`}\n\t\t\t\t\ttype='checkbox'\n\t\t\t\t\tonChange={ev => this._selectAllChange(ev)}\n\t\t\t\t\tchecked={this._selectionContainsAll()}\n\t\t\t\t\tindeterminate={this._selectionIndeterminate()}\n\t\t\t\t\tdisabled={this._rowSelectionLimit !== undefined}\n\t\t\t\t/>\n\t\t\t);\n\t\t}\n\n\t\tconst item = this._items[rowIndex];\n\n\t\tconst selectionContains = this._selectionContains(rowIndex);\n\n\t\treturn (\n\t\t\t<input\n\t\t\t\tclass='p-input'\n\t\t\t\ttype='checkbox'\n\t\t\t\tonChange={ev => this._checkboxChange(ev?.target, rowIndex)}\n\t\t\t\tdisabled={\n\t\t\t\t\t(this.canSelectKey && !item[this.canSelectKey]) ||\n\t\t\t\t\t(this._rowSelectionLimit !== undefined &&\n\t\t\t\t\t\t!selectionContains &&\n\t\t\t\t\t\tthis.selectedRows.length === this._rowSelectionLimit)\n\t\t\t\t}\n\t\t\t\tchecked={selectionContains}\n\t\t\t/>\n\t\t);\n\t}\n\n\tprivate _getEmptyState() {\n\t\tif (this.query?.length || this.selectedFiltersAmount) {\n\t\t\treturn (\n\t\t\t\t<div class='flex max-w-[20rem] flex-col items-center self-center py-24 text-center'>\n\t\t\t\t\t<p-illustration\n\t\t\t\t\t\tvariant='empty-state-search'\n\t\t\t\t\t\tclass='mb-6'\n\t\t\t\t\t/>\n\t\t\t\t\t<p class='text-storm-default font-semibold'>\n\t\t\t\t\t\t{this.emptyStateFilteredHeader()}\n\t\t\t\t\t</p>\n\t\t\t\t\t<p class='mb-14 text-sm text-storm-medium'>\n\t\t\t\t\t\t{this.emptyStateFilteredContent()}\n\t\t\t\t\t</p>\n\t\t\t\t</div>\n\t\t\t);\n\t\t}\n\n\t\treturn (\n\t\t\t<div\n\t\t\t\tclass={`flex max-w-[20rem] flex-col items-center self-center py-24 text-center ${\n\t\t\t\t\tthis.enableEmptyStateAction && 'cursor-pointer'\n\t\t\t\t}`}\n\t\t\t\tonClick={() =>\n\t\t\t\t\tthis.enableEmptyStateAction && this.emptyStateActionClick.emit(null)\n\t\t\t\t}\n\t\t\t>\n\t\t\t\t<p-illustration\n\t\t\t\t\tvariant='empty-state-add'\n\t\t\t\t\tclass='mb-6'\n\t\t\t\t/>\n\t\t\t\t<p class='text-storm-default font-semibold'>\n\t\t\t\t\t{this.emptyStateHeader()}\n\t\t\t\t</p>\n\t\t\t\t<p class='mb-6 text-sm text-storm-medium'>{this.emptyStateContent()}</p>\n\t\t\t\t{this.enableEmptyStateAction && (\n\t\t\t\t\t<p-button\n\t\t\t\t\t\tvariant='secondary'\n\t\t\t\t\t\ticon='plus'\n\t\t\t\t\t\tsize='small'\n\t\t\t\t\t>\n\t\t\t\t\t\t{this.emptyStateAction()}\n\t\t\t\t\t</p-button>\n\t\t\t\t)}\n\t\t\t</div>\n\t\t);\n\t}\n\n\tprivate _selectAllChange($event: any, forceValue?: boolean) {\n\t\tif (!this._enableRowSelection) {\n\t\t\treturn;\n\t\t}\n\n\t\tconst value =\n\t\t\tforceValue === undefined\n\t\t\t\t? this._getCheckedValue($event.target)\n\t\t\t\t: forceValue;\n\t\tif (value) {\n\t\t\tconst toAdd = [];\n\t\t\tfor (let i = 0; i < this._items.length; i++) {\n\t\t\t\tconst row = this._items[i];\n\t\t\t\tif (this.canSelectKey && !row[this.canSelectKey]) {\n\t\t\t\t\tcontinue;\n\t\t\t\t}\n\n\t\t\t\tif (this._selectionContains(i)) {\n\t\t\t\t\tcontinue;\n\t\t\t\t}\n\n\t\t\t\ttoAdd.push(row);\n\t\t\t\tthis.rowSelected.emit(row);\n\n\t\t\t\tif (\n\t\t\t\t\tthis._rowSelectionLimit !== undefined &&\n\t\t\t\t\tthis.selectedRows.length + toAdd.length === this._rowSelectionLimit\n\t\t\t\t) {\n\t\t\t\t\tbreak;\n\t\t\t\t}\n\t\t\t}\n\n\t\t\tthis.selectedRows = [...this.selectedRows, ...toAdd];\n\t\t\tthis.selectedRowsChange.emit(this.selectedRows);\n\t\t\tif (this.enableFloatingMenu && !this._floatingMenuShown) {\n\t\t\t\tthis._showFloatingMenu();\n\t\t\t}\n\n\t\t\treturn;\n\t\t}\n\n\t\tfor (let i = 0; i < this.selectedRows.length; i++) {\n\t\t\tconst value = this.selectedRows[i];\n\t\t\tconst row = this._items.find(\n\t\t\t\td => this._getSelectionValue(d, i) === this._getSelectionValue(value, i)\n\t\t\t);\n\n\t\t\tif (!row) {\n\t\t\t\tcontinue;\n\t\t\t}\n\n\t\t\tthis.rowDeselected.emit(row);\n\t\t}\n\n\t\tthis.selectedRows = [];\n\t\tthis.selectedRowsChange.emit(this.selectedRows);\n\t}\n\n\tprivate _checkboxChange(target: any, index: number) {\n\t\tif (!this._enableRowSelection) {\n\t\t\treturn;\n\t\t}\n\n\t\tconst value = this._getCheckedValue(target);\n\t\tif (\n\t\t\tvalue &&\n\t\t\tthis._rowSelectionLimit !== undefined &&\n\t\t\tthis.selectedRows.length >= this._rowSelectionLimit\n\t\t) {\n\t\t\ttarget.checked = false;\n\t\t\treturn;\n\t\t}\n\n\t\tconst row = this._items[index];\n\n\t\tif (this.canSelectKey && !row[this.canSelectKey]) {\n\t\t\ttarget.checked = false;\n\t\t\treturn;\n\t\t}\n\n\t\tif (value) {\n\t\t\tthis.selectedRows = [\n\t\t\t\t...this.selectedRows,\n\t\t\t\t{\n\t\t\t\t\t...row,\n\t\t\t\t\tindex,\n\t\t\t\t},\n\t\t\t];\n\t\t\tthis.selectedRowsChange.emit(this.selectedRows);\n\t\t\tthis.rowSelected.emit(row);\n\n\t\t\tif (this.enableFloatingMenu && !this._floatingMenuShown) {\n\t\t\t\tthis._showFloatingMenu();\n\t\t\t}\n\n\t\t\treturn;\n\t\t}\n\n\t\tconst indexOfToRemove = this._selectionContains(index, true);\n\n\t\t// we need to do this, because splice does not trigger the selection setter.\n\t\tconst selection = [...this.selectedRows];\n\t\tselection.splice(indexOfToRemove, 1);\n\t\tthis.selectedRows = selection;\n\t\tthis.selectedRowsChange.emit(this.selectedRows);\n\t\tthis.rowDeselected.emit(row);\n\t}\n\n\tprivate _getCheckedValue(target: any) {\n\t\treturn target?.checked;\n\t}\n\n\tprivate _getSelectionValue(row: any, index: number) {\n\t\treturn this.selectionKey ? row?.[this.selectionKey] || index : index;\n\t}\n\n\tprivate _selectionContains(index, returnIndex = false): any {\n\t\tconst returnValue = this.selectedRows.findIndex(\n\t\t\titem => item.index === index\n\t\t);\n\t\treturn !returnIndex ? returnValue >= 0 : returnValue;\n\t}\n\n\tprivate _selectionContainsAll() {\n\t\tlet returnValue = true;\n\t\tif (!this._items?.length) {\n\t\t\treturn false;\n\t\t}\n\n\t\tif (\n\t\t\tthis._rowSelectionLimit !== undefined &&\n\t\t\tthis.selectedRows.length === this._rowSelectionLimit\n\t\t) {\n\t\t\treturn true;\n\t\t}\n\n\t\tfor (let i = 0; i < this._items?.length; i++) {\n\t\t\tconst contains = this._selectionContains(i);\n\n\t\t\tif (!contains) {\n\t\t\t\treturnValue = false;\n\t\t\t\tbreak;\n\t\t\t}\n\t\t}\n\n\t\treturn returnValue;\n\t}\n\n\tprivate _selectionIndeterminate() {\n\t\tif (!this._items?.length || !this.selectedRows?.length) {\n\t\t\treturn false;\n\t\t}\n\n\t\tif (\n\t\t\tthis._rowSelectionLimit !== undefined &&\n\t\t\tthis.selectedRows.length === this._rowSelectionLimit\n\t\t) {\n\t\t\treturn false;\n\t\t}\n\n\t\tlet containsCount = 0;\n\t\tfor (let i = 0; i < this._items?.length; i++) {\n\t\t\tconst contains = this._selectionContains(i);\n\n\t\t\tif (contains) {\n\t\t\t\tcontainsCount++;\n\t\t\t}\n\t\t}\n\n\t\treturn containsCount > 0 && containsCount !== this._items.length;\n\t}\n\n\tprivate _rowClick($event, index) {\n\t\tconst target = $event.target;\n\n\t\tif (\n\t\t\ttarget.tagName.toLowerCase() === 'input' ||\n\t\t\ttarget.type === 'checkbox'\n\t\t) {\n\t\t\treturn;\n\t\t}\n\n\t\tconst row = this._findRow($event.target);\n\t\tconst action = this._findRowAction($event.target);\n\n\t\tif (action) {\n\t\t\treturn;\n\t\t}\n\n\t\tif (this.enableRowClick) {\n\t\t\tconst item = this._items[index];\n\t\t\tthis.rowClick.emit({\n\t\t\t\titem,\n\t\t\t\tctrlDown: this._ctrlDown,\n\t\t\t});\n\t\t\treturn;\n\t\t}\n\n\t\tif (!this._enableRowSelection) {\n\t\t\treturn;\n\t\t}\n\n\t\tconst checkbox = row?.querySelector('input[type=\"checkbox\"]');\n\n\t\tif (!checkbox) {\n\t\t\treturn;\n\t\t}\n\n\t\tcheckbox.checked = !checkbox.checked;\n\t\tthis._checkboxChange(checkbox, index);\n\t}\n\n\tprivate _findRow(el: HTMLElement) {\n\t\tif (!el) {\n\t\t\treturn el;\n\t\t}\n\n\t\tif (el?.tagName?.toLowerCase() === 'p-table-row') {\n\t\t\treturn el;\n\t\t}\n\n\t\treturn this._findRow(el?.parentElement);\n\t}\n\n\tprivate _findRowAction(el: HTMLElement) {\n\t\tif (!el) {\n\t\t\treturn null;\n\t\t}\n\n\t\tif (\n\t\t\tel.getAttribute('data-is-action') !== null &&\n\t\t\tel.getAttribute('data-is-action') !== 'false'\n\t\t) {\n\t\t\treturn el;\n\t\t}\n\n\t\tif (el?.tagName?.toLowerCase() === 'p-table-row') {\n\t\t\treturn null;\n\t\t}\n\n\t\treturn this._findRowAction(el?.parentElement);\n\t}\n\n\tprivate _showFloatingMenu() {\n\t\tlet actions = this._rowActionsFloatingAll;\n\t\tif (\n\t\t\tthis.rowSelectionLimit === 1 &&\n\t\t\tactions.findIndex(\n\t\t\t\ta => (a.type === 'single' || a.type === 'both') && a.showFunction\n\t\t\t) >= 0\n\t\t) {\n\t\t\tactions = actions.filter(\n\t\t\t\ta =>\n\t\t\t\t\ta.type === 'multi' ||\n\t\t\t\t\t!a.showFunction ||\n\t\t\t\t\ta.showFunction(this.selectedRows[0])\n\t\t\t);\n\t\t}\n\n\t\tthis._rowActionsFloating = actions;\n\t\tthis._floatingMenuShown = true;\n\t}\n\n\tprivate _parseDefinitions(definitionsArray: HTMLPTableColumnElement[]) {\n\t\tconst definitions = definitionsArray.map(definition => {\n\t\t\tdefinition = this._parseDefinitionSizes(definition);\n\t\t\tdefinition.isLast = {};\n\t\t\treturn definition;\n\t\t});\n\n\t\tconst matchedIsLast = tableColumSizesOptions.reduce(\n\t\t\t(data: { [key: string]: boolean }, size) => {\n\t\t\t\tdata[size] = false;\n\t\t\t\treturn data;\n\t\t\t},\n\t\t\t{}\n\t\t);\n\n\t\tfor (let i = definitions.length - 1; i >= 0; i--) {\n\t\t\tconst definition = definitions[i];\n\n\t\t\tfor (const size of tableColumSizesOptions) {\n\t\t\t\tif (matchedIsLast[size]) {\n\t\t\t\t\tdefinition.isLast[size] = false;\n\t\t\t\t\tcontinue;\n\t\t\t\t}\n\n\t\t\t\tif (definition.parsedSizes![size] === 'hidden') {\n\t\t\t\t\tdefinition.isLast[size] = false;\n\t\t\t\t\tcontinue;\n\t\t\t\t}\n\n\t\t\t\tconst isLastAtSizeFound = this._findLastDefinitionBySize(\n\t\t\t\t\tdefinitions,\n\t\t\t\t\tsize\n\t\t\t\t);\n\t\t\t\tif (isLastAtSizeFound) {\n\t\t\t\t\tdefinition.isLast[size] = false;\n\t\t\t\t\tcontinue;\n\t\t\t\t}\n\n\t\t\t\tdefinition.isLast[size] = true;\n\t\t\t}\n\t\t}\n\n\t\treturn definitions;\n\t}\n\n\tprivate _findLastDefinitionBySize(\n\t\tdefinitions: HTMLPTableColumnElement[],\n\t\tsize: string\n\t) {\n\t\treturn definitions\n\t\t\t.slice()\n\t\t\t.reverse()\n\t\t\t.find(d => d.isLast[size] === true);\n\t}\n\n\tprivate _parseDefinitionSizes(definition: HTMLPTableColumnElement) {\n\t\tconst definitionAny = definition as any;\n\t\tlet parsedSizes: TableColumnSizes = { default: 'full' };\n\n\t\tif (\n\t\t\ttypeof definition.sizes === 'string' &&\n\t\t\t!['auto', 'hidden', 'full'].includes(definition.sizes)\n\t\t) {\n\t\t\tdefinition.sizes = JSON.parse(definition.sizes);\n\t\t}\n\n\t\tfor (const [index, size] of tableColumSizesOptions.entries()) {\n\t\t\tif (\n\t\t\t\tdefinitionAny.sizes === 'auto' ||\n\t\t\t\tdefinitionAny.sizes === 'hidden' ||\n\t\t\t\tdefinitionAny.sizes === 'full' ||\n\t\t\t\ttypeof definitionAny.sizes === 'number'\n\t\t\t) {\n\t\t\t\tparsedSizes[size] =\n\t\t\t\t\tdefinitionAny.sizes === 'auto' ? 'full' : definitionAny.sizes;\n\t\t\t\tcontinue;\n\t\t\t}\n\n\t\t\tparsedSizes[size] =\n\t\t\t\tdefinitionAny.sizes[size] ??\n\t\t\t\tparsedSizes[tableColumSizesOptions[index - 1]];\n\t\t}\n\n\t\tdefinition.parsedSizes = parsedSizes;\n\t\treturn definition;\n\t}\n\n\tprivate _parseRowActionsRowDefinition() {\n\t\tconst isLast = tableColumSizesOptions.reduce(\n\t\t\t(data: { [key: string]: boolean }, size) => {\n\t\t\t\tdata[size] = true;\n\t\t\t\treturn data;\n\t\t\t},\n\t\t\t{}\n\t\t);\n\t\tconst sizes: TableColumnSizes = { default: 0 };\n\n\t\tfor (const size of tableColumSizesOptions) {\n\t\t\tconst lastColumn = this._findLastDefinitionBySize(this._columns, size);\n\t\t\tsizes[size] = lastColumn!.parsedSizes![size]!;\n\t\t}\n\n\t\treturn {\n\t\t\tisLast,\n\t\t\tsizes,\n\t\t\tparsedSizes: sizes,\n\t\t\talign: 'end',\n\t\t\ttype: 'td',\n\t\t\tpath: null,\n\t\t} as TableColumn;\n\t}\n}\n"],"version":3}
|
package/dist/index.html
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
<!doctype html><html dir="ltr" lang="en"><head> <meta charset="utf-8"> <meta name="viewport" content="width=device-width, initial-scale=1.0, minimum-scale=1.0, maximum-scale=5.0"> <title>Stencil Component Starter</title> <script type="module" src="/build/paperless.esm.js" data-stencil data-resources-url="/build/" data-stencil-namespace="paperless"></script> <script nomodule="" src="/build/paperless.js" data-stencil></script> </head> <body> <p-button>Buttono</p-button> <script data-build="2025-03-
|
|
1
|
+
<!doctype html><html dir="ltr" lang="en"><head> <meta charset="utf-8"> <meta name="viewport" content="width=device-width, initial-scale=1.0, minimum-scale=1.0, maximum-scale=5.0"> <title>Stencil Component Starter</title> <script type="module" src="/build/paperless.esm.js" data-stencil data-resources-url="/build/" data-stencil-namespace="paperless"></script> <script nomodule="" src="/build/paperless.js" data-stencil></script> </head> <body> <p-button>Buttono</p-button> <script data-build="2025-03-31T10:20:15">
|
|
2
2
|
if ('serviceWorker' in navigator && location.protocol !== 'file:') {
|
|
3
3
|
window.addEventListener('load', function() {
|
|
4
4
|
navigator.serviceWorker.register('/sw.js')
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{r as t,h as r,H as o}from"./p-0c2cc6c4.js";const
|
|
2
|
-
//# sourceMappingURL=p-
|
|
1
|
+
import{r as t,h as r,H as o}from"./p-0c2cc6c4.js";const i=".flex{display:flex!important}.h-10{height:2.5rem!important}.whitespace-nowrap{white-space:nowrap!important}.border-0{border-width:0!important}.border-b-2{border-bottom-width:2px!important}.border-indigo{--tw-border-opacity:1!important;border-color:rgb(82 138 250/var(--tw-border-opacity))!important}.border-transparent{border-color:transparent!important}.font-semibold{font-weight:600!important}.text-indigo{--tw-text-opacity:1!important;color:rgb(82 138 250/var(--tw-text-opacity))!important}*{box-sizing:border-box}:host{--tw-text-opacity:1;align-items:center;border-color:transparent!important;border-width:0 0 2px!important;color:rgb(128 130 158/var(--tw-text-opacity));cursor:pointer;display:flex;font-weight:600;height:2.5rem;white-space:nowrap}:host(.active){--tw-border-opacity:1!important;--tw-text-opacity:1!important;border-color:rgb(82 138 250/var(--tw-border-opacity))!important;color:rgb(82 138 250/var(--tw-text-opacity))!important}.static{position:static!important}";const a=class{constructor(r){t(this,r);this.active=false}render(){return r(o,{class:`p-tab-item ${this.active&&"active"}`},r("slot",null))}};a.style=i;export{a as p_tab_item};
|
|
2
|
+
//# sourceMappingURL=p-32ec455c.entry.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["tabItemComponentCss","TabItem","render","h","Host","class","this","active"],"sources":["src/components/atoms/tab-item/tab-item.component.scss?tag=p-tab-item&encapsulation=shadow","src/components/atoms/tab-item/tab-item.component.tsx"],"sourcesContent":[":host {\n\t@apply flex h-10 items-center;\n\t@apply whitespace-nowrap font-semibold text-storm-medium;\n\t@apply cursor-pointer;\n\t@apply border-0 border-b-2 border-transparent #{!important};\n}\n\n:host(.active) {\n\t@apply border-indigo text-indigo #{!important};\n}\n","import { Component, h, Host, Prop } from '@stencil/core';\n\n@Component({\n\ttag: 'p-tab-item',\n\tstyleUrl: 'tab-item.component.scss',\n\tshadow: true,\n})\nexport class TabItem {\n\t/**\n\t * Wether the tab item is active\n\t */\n\t@Prop() active: boolean = false;\n\n\trender() {\n\t\treturn (\n\t\t\t<Host class={`p-tab-item ${this.active && 'active'}`}>\n\t\t\t\t<slot />\n\t\t\t</Host>\n\t\t);\n\t}\n}\n"],"mappings":"kDAAA,MAAMA,EAAsB,
|
|
1
|
+
{"version":3,"names":["tabItemComponentCss","TabItem","render","h","Host","class","this","active"],"sources":["src/components/atoms/tab-item/tab-item.component.scss?tag=p-tab-item&encapsulation=shadow","src/components/atoms/tab-item/tab-item.component.tsx"],"sourcesContent":[":host {\n\t@apply flex h-10 items-center;\n\t@apply whitespace-nowrap font-semibold text-storm-medium;\n\t@apply cursor-pointer;\n\t@apply border-0 border-b-2 border-transparent #{!important};\n}\n\n:host(.active) {\n\t@apply border-indigo text-indigo #{!important};\n}\n","import { Component, h, Host, Prop } from '@stencil/core';\n\n@Component({\n\ttag: 'p-tab-item',\n\tstyleUrl: 'tab-item.component.scss',\n\tshadow: true,\n})\nexport class TabItem {\n\t/**\n\t * Wether the tab item is active\n\t */\n\t@Prop() active: boolean = false;\n\n\trender() {\n\t\treturn (\n\t\t\t<Host class={`p-tab-item ${this.active && 'active'}`}>\n\t\t\t\t<slot />\n\t\t\t</Host>\n\t\t);\n\t}\n}\n"],"mappings":"kDAAA,MAAMA,EAAsB,w9B,MCOfC,EAAO,M,qCAIO,K,CAE1B,MAAAC,GACC,OACCC,EAACC,EAAI,CAACC,MAAO,cAAcC,KAAKC,QAAU,YACzCJ,EAAA,a"}
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
import{r as t,h as e,H as o,g as r}from"./p-0c2cc6c4.js";const i=".flex{display:flex!important}.table{display:table!important}.h-\\[3\\.125rem\\]{height:3.125rem!important}.h-\\[4\\.125rem\\]{height:4.125rem!important}.h-\\[6\\.5rem\\]{height:6.5rem!important}.w-full{width:100%!important}.flex-col{flex-direction:column!important}.items-center{align-items:center!important}.justify-center{justify-content:center!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}.text-sm{font-size:.875rem!important;line-height:1.25rem!important}*{box-sizing:border-box}:host{display:flex}:host .profile-content{align-items:center;display:flex;gap:.75rem;width:100%}:host .profile-content .name{display:flex;flex-direction:column;justify-content:center;overflow:hidden}:host .profile-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 .profile-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 .profile-content .name ::slotted(*){overflow:hidden;text-overflow:ellipsis;white-space:nowrap}:host([size=xsmall]){height:1.5rem}:host([size=small]){height:2rem}:host([size=table]){height:2.5rem}:host([size=medium]){height:3.125rem}:host([size=large]){height:4rem}:host([size=xlarge]){height:6.5rem}:host(.has-dropdown){cursor:pointer}:host(.has-dropdown) .profile-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) .profile-content,:host(.has-dropdown:hover) .profile-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) .profile-content p-icon{--tw-text-opacity:1;color:rgb(82 138 250/var(--tw-text-opacity))}.static{position:static!important}.absolute{position:absolute!important}.ml-auto{margin-left:auto!important}.min-w-0{min-width:0!important}";const s=class{constructor(e){t(this,e);this.variant="user";this.size="small";this._dropdownOpen=false}componentWillRender(){this._updateAvatar()}render(){const t=!!this._el.querySelector(':scope > [slot="dropdown"]');const r=this._getContent(t);const i=e("slot",{name:"dropdown"});return e(o,{class:`p-profile ${t&&"has-dropdown"} ${this._dropdownOpen&&"active"}`},t?e("p-dropdown",{class:"w-full min-w-0",strategy:"absolute",placement:this.variant==="user"?"top-end":"bottom-end",applyFullWidth:true,applyMaxWidth:false,onIsOpen:t=>this._dropdownOpen=t.detail},r,e("div",{slot:"items"},i)):r)}_getContent(t){return e("div",{class:"profile-content",slot:"trigger"},e("slot",{name:"avatar"}),e("div",{class:"name"},e("slot",{name:"title"}),e("slot",{name:"subtitle"})),t&&this._getIcon())}_updateAvatar(){var t,e;const o=this._el.querySelector('p-avatar[slot="avatar"]');if(!o){return}o.variant=(t=this.variant)!==null&&t!==void 0?t:o.variant;o.size=(e=this.size)!==null&&e!==void 0?e:o===null||o===void 0?void 0:o.size}_getIcon(){return e("p-icon",{class:"ml-auto",variant:this.variant==="company"?"chevron":"more"})}get _el(){return r(this)}};s.style=i;export{s as p_profile};
|
|
2
|
+
//# sourceMappingURL=p-3e3a79b1.entry.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["profileComponentCss","Profile","componentWillRender","this","_updateAvatar","render","hasDropdownSlot","_el","querySelector","content","_getContent","dropdownItems","h","name","Host","class","_dropdownOpen","strategy","placement","variant","applyFullWidth","applyMaxWidth","onIsOpen","ev","detail","slot","_getIcon","avatar","_a","size","_b"],"sources":["src/components/molecules/profile/profile.component.scss?tag=p-profile&encapsulation=shadow","src/components/molecules/profile/profile.component.tsx"],"sourcesContent":[":host {\n\t@apply flex;\n\n\t.profile-content {\n\t\t@apply flex w-full items-center gap-3;\n\n\t\t.name {\n\t\t\t@apply flex flex-col justify-center overflow-hidden;\n\n\t\t\t> *:nth-child(1) {\n\t\t\t\t@apply text-sm text-storm-dark;\n\t\t\t\t@apply font-semibold;\n\t\t\t}\n\n\t\t\t> *:nth-child(2) {\n\t\t\t\t@apply text-sm text-storm-vague;\n\t\t\t}\n\n\t\t\t::slotted(*) {\n\t\t\t\t@apply overflow-hidden text-ellipsis whitespace-nowrap;\n\t\t\t}\n\t\t}\n\t}\n}\n\n:host([size='xsmall']) {\n\t@apply h-6;\n}\n\n:host([size='small']) {\n\t@apply h-8;\n}\n\n:host([size='table']) {\n\t@apply h-10;\n}\n\n:host([size='medium']) {\n\t@apply h-[3.125rem];\n}\n\n:host([size='large']) {\n\t@apply h-16;\n}\n\n:host([size='xlarge']) {\n\t@apply h-[6.5rem];\n}\n\n:host(.has-dropdown) {\n\t@apply cursor-pointer;\n\n\t.profile-content {\n\t\t@apply rounded p-2;\n\t\t@apply border border-solid border-mystic-dark #{!important};\n\t}\n}\n\n:host(.has-dropdown[size='small']) {\n\t@apply h-12;\n}\n\n:host(.has-dropdown[size='medium']) {\n\t@apply h-[4.125rem];\n}\n\n:host(.has-dropdown[size='large']) {\n\t@apply h-20;\n}\n\n:host(.has-dropdown:hover),\n:host(.active) {\n\t.profile-content {\n\t\t@apply shadow-4;\n\t}\n}\n\n:host(.active) {\n\t.profile-content {\n\t\tp-icon {\n\t\t\t@apply text-indigo;\n\t\t}\n\t}\n}\n","import { Component, Element, h, Host, Prop, State } from '@stencil/core';\n\n@Component({\n\ttag: 'p-profile',\n\tstyleUrl: 'profile.component.scss',\n\tshadow: true,\n})\nexport class Profile {\n\t/**\n\t * The variant of the profile\n\t */\n\t@Prop() variant: 'company' | 'user' = 'user';\n\n\t/**\n\t * The size of the profile avatar\n\t */\n\t@Prop({ reflect: true }) size:\n\t\t| 'xsmall'\n\t\t| 'small'\n\t\t| 'table'\n\t\t| 'medium'\n\t\t| 'large'\n\t\t| 'xlarge' = 'small';\n\n\t/**\n\t * The host element\n\t */\n\t@Element() private _el: HTMLElement;\n\n\t@State() private _dropdownOpen = false;\n\n\tcomponentWillRender() {\n\t\tthis._updateAvatar();\n\t}\n\n\trender() {\n\t\tconst hasDropdownSlot = !!this._el.querySelector(\n\t\t\t':scope > [slot=\"dropdown\"]'\n\t\t);\n\t\tconst content = this._getContent(hasDropdownSlot);\n\t\tconst dropdownItems = <slot name='dropdown' />;\n\t\treturn (\n\t\t\t<Host\n\t\t\t\tclass={`p-profile ${hasDropdownSlot && 'has-dropdown'} ${\n\t\t\t\t\tthis._dropdownOpen && 'active'\n\t\t\t\t}`}\n\t\t\t>\n\t\t\t\t{hasDropdownSlot ? (\n\t\t\t\t\t<p-dropdown\n\t\t\t\t\t\tclass='w-full min-w-0'\n\t\t\t\t\t\tstrategy='absolute'\n\t\t\t\t\t\tplacement={this.variant === 'user' ? 'top-end' : 'bottom-end'}\n\t\t\t\t\t\tapplyFullWidth={true}\n\t\t\t\t\t\tapplyMaxWidth={false}\n\t\t\t\t\t\tonIsOpen={ev => (this._dropdownOpen = ev.detail)}\n\t\t\t\t\t>\n\t\t\t\t\t\t{content}\n\t\t\t\t\t\t<div slot='items'>{dropdownItems}</div>\n\t\t\t\t\t</p-dropdown>\n\t\t\t\t) : (\n\t\t\t\t\tcontent\n\t\t\t\t)}\n\t\t\t</Host>\n\t\t);\n\t}\n\n\tprivate _getContent(hasDropdownSlot: boolean) {\n\t\treturn (\n\t\t\t<div\n\t\t\t\tclass='profile-content'\n\t\t\t\tslot='trigger'\n\t\t\t>\n\t\t\t\t<slot name='avatar' />\n\t\t\t\t<div class='name'>\n\t\t\t\t\t<slot name='title' />\n\t\t\t\t\t<slot name='subtitle' />\n\t\t\t\t</div>\n\n\t\t\t\t{hasDropdownSlot && this._getIcon()}\n\t\t\t</div>\n\t\t);\n\t}\n\n\tprivate _updateAvatar() {\n\t\tconst avatar = this._el.querySelector(\n\t\t\t'p-avatar[slot=\"avatar\"]'\n\t\t) as HTMLPAvatarElement;\n\n\t\tif (!avatar) {\n\t\t\treturn;\n\t\t}\n\n\t\tavatar.variant = this.variant ?? avatar.variant;\n\t\tavatar.size = this.size ?? avatar?.size;\n\t}\n\n\tprivate _getIcon() {\n\t\treturn (\n\t\t\t<p-icon\n\t\t\t\tclass='ml-auto'\n\t\t\t\tvariant={this.variant === 'company' ? 'chevron' : 'more'}\n\t\t\t/>\n\t\t);\n\t}\n}\n"],"mappings":"yDAAA,MAAMA,EAAsB,+iF,MCOfC,EAAO,M,sCAImB,O,UAWxB,Q,mBAOmB,K,CAEjC,mBAAAC,GACCC,KAAKC,e,CAGN,MAAAC,GACC,MAAMC,IAAoBH,KAAKI,IAAIC,cAClC,8BAED,MAAMC,EAAUN,KAAKO,YAAYJ,GACjC,MAAMK,EAAgBC,EAAA,QAAMC,KAAK,aACjC,OACCD,EAACE,EAAI,CACJC,MAAO,aAAaT,GAAmB,kBACtCH,KAAKa,eAAiB,YAGtBV,EACAM,EAAA,cACCG,MAAM,iBACNE,SAAS,WACTC,UAAWf,KAAKgB,UAAY,OAAS,UAAY,aACjDC,eAAgB,KAChBC,cAAe,MACfC,SAAUC,GAAOpB,KAAKa,cAAgBO,EAAGC,QAExCf,EACDG,EAAA,OAAKa,KAAK,SAASd,IACP,E,CAQT,WAAAD,CAAYJ,GACnB,OACCM,EAAA,OACCG,MAAM,kBACNU,KAAK,WAELb,EAAA,QAAMC,KAAK,WACXD,EAAA,OAAKG,MAAM,QACVH,EAAA,QAAMC,KAAK,UACXD,EAAA,QAAMC,KAAK,cAGXP,GAAmBH,KAAKuB,W,CAKpB,aAAAtB,G,QACP,MAAMuB,EAASxB,KAAKI,IAAIC,cACvB,2BAGD,IAAKmB,EAAQ,CACZ,M,CAGDA,EAAOR,SAAUS,EAAAzB,KAAKgB,WAAO,MAAAS,SAAA,EAAAA,EAAID,EAAOR,QACxCQ,EAAOE,MAAOC,EAAA3B,KAAK0B,QAAI,MAAAC,SAAA,EAAAA,EAAIH,IAAM,MAANA,SAAM,SAANA,EAAQE,I,CAG5B,QAAAH,GACP,OACCd,EAAA,UACCG,MAAM,UACNI,QAAShB,KAAKgB,UAAY,UAAY,UAAY,Q"}
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
import{r as t,c as e,h as o,H as r,g as i}from"./p-0c2cc6c4.js";import{a,c as p,o as n,f as s,s as c}from"./p-fef32402.js";import{c as h}from"./p-4d330cfc.js";const l=".relative{position:relative!important}.block{display:block!important}.h-auto{height:auto!important}*{box-sizing:border-box}p-dropdown,p-dropdown .trigger{display:block;position:relative}p-dropdown .trigger{height:auto;width:auto}.visible{visibility:visible!important}.static{position:static!important}.fixed{position:fixed!important}.absolute{position:absolute!important}.z-dropdown{z-index:200!important}.hidden{display:none!important}";const d=class{constructor(o){t(this,o);this.isOpen=e(this,"isOpen",3);this._loaded=false;this.placement="bottom-start";this.offset=8;this.strategy="absolute";this.show=false;this.usePortal=false;this.calculateWidth=false;this.applyMaxWidth=true;this.applyFullWidth=true;this.allowOverflow=false;this.scrollable=false;this.insideClick=false;this.disableTriggerClick=false;this.applyChevron=true;this.chevronPosition="end";this.chevronDirection=undefined}componentShouldUpdate(){this._update()}disconnectedCallback(){if(this._cleanup){this._cleanup();this._cleanup=null}this._menu.remove()}componentDidRender(){this._checkButtons()}render(){const t={class:`z-dropdown hidden ${this.strategy==="fixed"?"fixed":"absolute"}`,ref:t=>this._load(t),onClick:()=>this._containerClickHandler(),role:"popover","data-placement":this.placement,"data-strategy":this.strategy};let e;if(this.usePortal){e=o("p-portal",Object.assign({},t),o("p-dropdown-menu-container",{maxWidth:!this.calculateWidth&&this.applyMaxWidth,fullWidth:this.applyFullWidth&&!this.applyMaxWidth,allowOverflow:this.allowOverflow,scrollable:this.scrollable},o("slot",{name:"items"})))}else{e=o("p-dropdown-menu-container",Object.assign({maxWidth:!this.calculateWidth&&this.applyMaxWidth,fullWidth:this.applyFullWidth&&!this.applyMaxWidth,allowOverflow:this.allowOverflow,scrollable:this.scrollable},t),o("slot",{name:"items"}))}return o(r,{class:"p-dropdown"},o("div",{class:"trigger",ref:t=>this._trigger=t,onClick:()=>this._triggerClickHandler()},o("slot",{name:"trigger"})),e)}_checkButtons(){if(!this.applyChevron){return}const t=this._el.querySelectorAll('p-button[slot="trigger"]');for(let e of[...t]){e.chevronPosition=this.chevronPosition;e.chevron=this.chevronDirection?this.chevronDirection:this.placement.indexOf("top")>=0?"up":"down"}}onShowChange(t){if(!this._loaded){return}if(!t){this._hide();return}this._show()}documentClickHandler({target:t}){if(!this._menu.hasAttribute("data-show")||h(t,this._menu)){return}this._hide()}_containerClickHandler(){if(this.insideClick){return}if(this._menu.hasAttribute("data-show")){this._hide()}}_triggerClickHandler(){if(this.disableTriggerClick){return}if(this._menu.hasAttribute("data-show")){this._hide();return}this._show()}_load(t){this._menu=t;if(t){this._update();this._loaded=true;if(this.show){setTimeout((()=>this._show()),100)}}}_show(){if(!this._loaded){return}if(this.calculateWidth){this._menu.style.width=`${this._trigger.clientWidth}px`}this._cleanup=a(this._el,this._menu,(()=>this._update()));this._menu.setAttribute("data-show","");this._menu.classList.remove("hidden");this._menu.classList.add("block");this.isOpen.emit(true);this._update()}_hide(){if(!this._loaded||this.show){return}if(this._cleanup){this._cleanup();this._cleanup=null}this._menu.removeAttribute("data-show");this._menu.classList.remove("block");this._menu.classList.add("hidden");this.isOpen.emit(false)}_update(){if(!this._menu){return}p(this._el,this._menu,{placement:this.placement,strategy:this.strategy,middleware:[n(this.offset),s(),c()]}).then((({x:t,y:e,placement:o})=>{this._menu.dataset.placement=o;Object.assign(this._menu.style,{top:`${e}px`,left:`${t}px`})}))}get _el(){return i(this)}static get watchers(){return{show:["onShowChange"]}}};d.style=l;const b=".block{display:block!important}.flex{display:flex!important}.h-4{height:1rem!important}.h-6{height:1.5rem!important}.h-8{height:2rem!important}.w-4{width:1rem!important}.w-6{width:1.5rem!important}.w-\\[2\\.375rem\\]{width:2.375rem!important}.w-full{width:100%!important}.translate-x-0{--tw-translate-x:0px!important}.translate-x-0,.translate-x-3{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}.translate-x-3{--tw-translate-x:0.75rem!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}.appearance-none{appearance:none!important}.items-center{align-items:center!important}.justify-start{justify-content:flex-start!important}.gap-2{gap:.5rem!important}.overflow-hidden{overflow:hidden!important}.text-ellipsis{text-overflow:ellipsis!important}.whitespace-nowrap{white-space:nowrap!important}.rounded{border-radius:.25rem!important}.border{border-width:1px!important}.border-solid{border-style:solid!important}.border-indigo{--tw-border-opacity:1!important;border-color:rgb(82 138 250/var(--tw-border-opacity))!important}.border-negative{--tw-border-opacity:1!important;border-color:rgb(185 30 40/var(--tw-border-opacity))!important}.bg-indigo-light{--tw-bg-opacity:1!important;background-color:rgb(241 246 255/var(--tw-bg-opacity))!important}.bg-mystic-dark{background-color:rgb(218 230 240/var(--tw-bg-opacity))!important}.bg-mystic-dark,.bg-white{--tw-bg-opacity:1!important}.bg-white{background-color:rgb(255 255 255/var(--tw-bg-opacity))!important}.bg-center{background-position:50%!important}.text-sm{font-size:.875rem!important;line-height:1.25rem!important}.font-semibold{font-weight:600!important}.outline-none{outline:2px solid transparent!important;outline-offset:2px!important}.transition-transform{transition-duration:.15s!important;transition-property:transform!important;transition-timing-function:cubic-bezier(.4,0,.2,1)!important}*{box-sizing:border-box}:host{--tw-text-opacity:1;align-items:center;border-radius:.25rem;color:rgb(81 83 107/var(--tw-text-opacity));cursor:pointer;display:flex;font-size:.875rem;font-weight:600;gap:.5rem;height:2rem;justify-content:flex-start;line-height:1.25rem;padding-left:.5rem;padding-right:.5rem;width:100%}:host input[type=checkbox].p-input{--tw-bg-opacity:1;--tw-border-opacity:1;appearance:none;background-color:rgb(255 255 255/var(--tw-bg-opacity));background-position:50%;background-repeat:no-repeat;background-size:1rem;border-color:rgb(218 230 240/var(--tw-border-opacity));border-radius:.25rem;border-style:solid;border-width:1px;height:1.5rem;outline:2px solid transparent!important;outline-offset:2px!important;width:1.5rem}:host input[type=checkbox].p-input+label{margin-left:.2rem;margin-top:.05rem}:host input[type=checkbox].p-input:hover:not(:disabled):not([disabled]):not(.disabled){cursor:pointer}:host input[type=checkbox].p-input:hover:not(:disabled):not([disabled]):not(.disabled):not(:checked):not([checked]):not(.checked):not(:indeterminate):not([indeterminate]):not(.indeterminate){--tw-border-opacity:1;background-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg width='1em' height='1em' viewBox='0 0 16 16' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M5.965 11.487 13.53 1.53c.435-.572 1.22-.7 1.8-.292l.108.077c.294.206.492.53.546.895.054.365-.04.737-.26 1.026L7.26 14.38a1.34 1.34 0 0 1-.642.463 1.302 1.302 0 0 1-1.575-.263L.362 9.6a1.356 1.356 0 0 1-.36-.99c.017-.37.181-.713.452-.95l.1-.088a1.302 1.302 0 0 1 1.82.093l3.592 3.82h-.001Z' fill='%23dae6f0' fill-rule='evenodd'/%3E%3C/svg%3E\");border-color:rgb(82 138 250/var(--tw-border-opacity))}:host input[type=checkbox].p-input.checked,:host input[type=checkbox].p-input.indeterminate,:host input[type=checkbox].p-input:checked,:host input[type=checkbox].p-input:indeterminate,:host input[type=checkbox].p-input[checked],:host input[type=checkbox].p-input[indeterminate]{--tw-border-opacity:1;--tw-bg-opacity:1;background-color:rgb(82 138 250/var(--tw-bg-opacity));border-color:rgb(82 138 250/var(--tw-border-opacity))}:host input[type=checkbox].p-input.checked,:host input[type=checkbox].p-input:checked,:host input[type=checkbox].p-input[checked]{background-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg width='1em' height='1em' viewBox='0 0 16 16' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M5.965 11.487 13.53 1.53c.435-.572 1.22-.7 1.8-.292l.108.077c.294.206.492.53.546.895.054.365-.04.737-.26 1.026L7.26 14.38a1.34 1.34 0 0 1-.642.463 1.302 1.302 0 0 1-1.575-.263L.362 9.6a1.356 1.356 0 0 1-.36-.99c.017-.37.181-.713.452-.95l.1-.088a1.302 1.302 0 0 1 1.82.093l3.592 3.82h-.001Z' fill='%23fff' fill-rule='evenodd'/%3E%3C/svg%3E\")}:host input[type=checkbox].p-input.indeterminate,:host input[type=checkbox].p-input:indeterminate,:host input[type=checkbox].p-input[indeterminate]{background-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg width='1em' height='1em' viewBox='0 0 16 16' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M4 7h8a1 1 0 0 1 0 2H4a1 1 0 1 1 0-2Z' fill='%23fff' fill-rule='evenodd'/%3E%3C/svg%3E\")}:host input[type=checkbox].p-input.disabled,:host input[type=checkbox].p-input:disabled,:host input[type=checkbox].p-input[disabled]{opacity:.4}:host input[type=checkbox].p-input.error,:host input[type=checkbox].p-input[error]{--tw-text-opacity:1;--tw-border-opacity:1!important;border-color:rgb(185 30 40/var(--tw-border-opacity))!important;color:rgb(138 15 29/var(--tw-text-opacity))}:host input[type=checkbox].p-input.error::-moz-placeholder,:host input[type=checkbox].p-input[error]::-moz-placeholder{--tw-text-opacity:1;color:rgb(255 204 211/var(--tw-text-opacity))}:host input[type=checkbox].p-input.error::placeholder,:host input[type=checkbox].p-input[error]::placeholder{--tw-text-opacity:1;color:rgb(255 204 211/var(--tw-text-opacity))}:host input[type=checkbox].p-input.error.checked,:host input[type=checkbox].p-input.error:checked,:host input[type=checkbox].p-input.error[checked],:host input[type=checkbox].p-input[error].checked,:host input[type=checkbox].p-input[error]:checked,:host input[type=checkbox].p-input[error][checked]{--tw-bg-opacity:1;background-color:rgb(185 30 40/var(--tw-bg-opacity))}:host input[type=checkbox].p-input.size-small{height:1rem;width:1rem}:host input[type=checkbox].p-input.size-small:hover:not(:disabled):not([disabled]):not(.disabled):not(:checked):not([checked]):not(.checked):not(:indeterminate):not([indeterminate]):not(.indeterminate){background-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cpath d='M2.667 2.667h10.667v10.667H2.667z'/%3E%3Cpath fill='%23DAE6F0' d='m6.644 10.325 5.044-6.638a.87.87 0 0 1 1.2-.194l.072.05a.91.91 0 0 1 .19 1.28l-5.644 7.43a.89.89 0 0 1-.427.31.868.868 0 0 1-1.05-.176l-3.12-3.32a.904.904 0 0 1-.241-.66.897.897 0 0 1 .302-.633l.067-.058a.868.868 0 0 1 1.213.062l2.394 2.547Z'/%3E%3C/g%3E%3C/svg%3E\")}:host input[type=checkbox].p-input.size-small.checked,:host input[type=checkbox].p-input.size-small:checked,:host input[type=checkbox].p-input.size-small[checked]{background-image:url(\"data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cpath d='M2.667 2.667h10.667v10.667H2.667z'/%3E%3Cpath fill='%23FFF' d='m6.644 10.325 5.044-6.638a.87.87 0 0 1 1.2-.194l.072.05a.91.91 0 0 1 .19 1.28l-5.644 7.43a.89.89 0 0 1-.427.31.868.868 0 0 1-1.05-.176l-3.12-3.32a.904.904 0 0 1-.241-.66.897.897 0 0 1 .302-.633l.067-.058a.868.868 0 0 1 1.213.062l2.394 2.547Z'/%3E%3C/g%3E%3C/svg%3E\")}:host input[type=checkbox].p-toggle{--tw-bg-opacity:1;--tw-border-opacity:1;align-items:center;appearance:none;background-color:rgb(255 255 255/var(--tw-bg-opacity));border-color:rgb(218 230 240/var(--tw-border-opacity));border-radius:1.5625rem;border-style:solid;border-width:1px;display:flex;height:1.5rem;justify-content:flex-start;padding:.25rem;width:2.375rem}:host input[type=checkbox].p-toggle:after{--tw-translate-x:0px;--tw-bg-opacity:1;background-color:rgb(218 230 240/var(--tw-bg-opacity));border-radius:100%;content:\"\";display:block;height:1rem;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));transition-duration:.1s;transition-property:transform;transition-timing-function:cubic-bezier(.4,0,.2,1);width:1rem}:host input[type=checkbox].p-toggle.checked,:host input[type=checkbox].p-toggle:checked,:host input[type=checkbox].p-toggle[checked]{--tw-border-opacity:1;--tw-bg-opacity:1;background-color:rgb(82 138 250/var(--tw-bg-opacity));border-color:rgb(82 138 250/var(--tw-border-opacity))}:host input[type=checkbox].p-toggle.checked:after,:host input[type=checkbox].p-toggle:checked:after,:host input[type=checkbox].p-toggle[checked]:after{--tw-translate-x:0.75rem;--tw-bg-opacity:1;background-color:rgb(255 255 255/var(--tw-bg-opacity));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))}:host input[type=checkbox].p-toggle.disabled,:host input[type=checkbox].p-toggle:disabled,:host input[type=checkbox].p-toggle[disabled]{opacity:.4}:host input[type=checkbox].p-toggle:hover:not(:disabled):not([disabled]):not(.disabled){cursor:pointer}:host input[type=checkbox].p-toggle:hover:not(:disabled):not([disabled]):not(.disabled):not(:checked):not([checked]):not(.checked){--tw-border-opacity:1;border-color:rgb(82 138 250/var(--tw-border-opacity))}:host input[type=checkbox].p-toggle.error,:host input[type=checkbox].p-toggle[error]{--tw-text-opacity:1;--tw-border-opacity:1!important;border-color:rgb(185 30 40/var(--tw-border-opacity))!important;color:rgb(138 15 29/var(--tw-text-opacity))}:host input[type=checkbox].p-toggle.error::-moz-placeholder,:host input[type=checkbox].p-toggle[error]::-moz-placeholder{--tw-text-opacity:1;color:rgb(255 204 211/var(--tw-text-opacity))}:host input[type=checkbox].p-toggle.error::placeholder,:host input[type=checkbox].p-toggle[error]::placeholder{--tw-text-opacity:1;color:rgb(255 204 211/var(--tw-text-opacity))}:host input[type=checkbox].p-toggle.error.checked,:host input[type=checkbox].p-toggle.error:checked,:host input[type=checkbox].p-toggle.error[checked],:host input[type=checkbox].p-toggle[error].checked,:host input[type=checkbox].p-toggle[error]:checked,:host input[type=checkbox].p-toggle[error][checked]{--tw-bg-opacity:1;background-color:rgb(185 30 40/var(--tw-bg-opacity))}:host .text-container{display:block;overflow:hidden;text-align:start;text-overflow:ellipsis;white-space:nowrap;width:100%}:host(.hover:hover){--tw-bg-opacity:1;--tw-text-opacity:1;background-color:rgb(241 246 255/var(--tw-bg-opacity));color:rgb(81 83 107/var(--tw-text-opacity))}:host(.active){--tw-bg-opacity:1;--tw-text-opacity:1;background-color:rgb(241 246 255/var(--tw-bg-opacity));color:rgb(82 138 250/var(--tw-text-opacity))}.static{position:static!important}.flex-shrink-0{flex-shrink:0!important}";const g=class{constructor(e){t(this,e);this.active=false;this.variant="default";this.enableHover=true;this.icon=undefined;this.useContainer=true}render(){return o(r,{class:`p-dropdown-menu-item ${this.active&&"active"} ${this.enableHover&&"hover"}`},this.icon&&o("p-icon",{variant:this.icon}),this.variant==="checkbox"&&o("input",{type:"checkbox",class:"p-input size-small flex-shrink-0",checked:this.active}),this.useContainer?o("div",{class:"text-container"},o("slot",null)):o("slot",null))}};g.style=b;export{d as p_dropdown,g as p_dropdown_menu_item};
|
|
2
|
+
//# sourceMappingURL=p-59014c4c.entry.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["dropdownComponentCss","Dropdown","this","_loaded","componentShouldUpdate","_update","disconnectedCallback","_cleanup","_menu","remove","componentDidRender","_checkButtons","render","dropdownContainerProps","class","strategy","ref","el","_load","onClick","_containerClickHandler","role","placement","dropdownContainer","usePortal","h","Object","assign","maxWidth","calculateWidth","applyMaxWidth","fullWidth","applyFullWidth","allowOverflow","scrollable","name","Host","_trigger","_triggerClickHandler","applyChevron","children","_el","querySelectorAll","child","chevronPosition","chevron","chevronDirection","indexOf","onShowChange","show","_hide","_show","documentClickHandler","target","hasAttribute","childOf","insideClick","disableTriggerClick","popover","setTimeout","style","width","clientWidth","autoUpdate","setAttribute","classList","add","isOpen","emit","removeAttribute","computePosition","middleware","offset","flip","shift","then","x","y","dataset","top","left","dropdownMenuItemComponentCss","DropdownMenuItem","active","enableHover","icon","variant","type","checked","useContainer"],"sources":["src/components/molecules/dropdown/dropdown.component.scss?tag=p-dropdown","src/components/molecules/dropdown/dropdown.component.tsx","src/components/atoms/dropdown-menu-item/dropdown-menu-item.component.scss?tag=p-dropdown-menu-item&encapsulation=shadow","src/components/atoms/dropdown-menu-item/dropdown-menu-item.component.tsx"],"sourcesContent":["p-dropdown {\n\t@apply relative block;\n\n\t.trigger {\n\t\t@apply relative block h-auto w-auto;\n\t}\n}\n","import {\n\tautoUpdate,\n\tcomputePosition,\n\tflip,\n\toffset,\n\tPlacement,\n\tshift,\n\tStrategy,\n} from '@floating-ui/dom';\nimport {\n\tComponent,\n\tElement,\n\tEvent,\n\tEventEmitter,\n\th,\n\tHost,\n\tListen,\n\tProp,\n\tWatch,\n} from '@stencil/core';\nimport { childOf } from '../../../utils/child-of';\n\n@Component({\n\ttag: 'p-dropdown',\n\tstyleUrl: 'dropdown.component.scss',\n})\nexport class Dropdown {\n\t/**\n\t * The content of the dropdown menu\n\t */\n\t@Prop({ reflect: true }) placement: Placement = 'bottom-start';\n\n\t/**\n\t * The offset of the dropdown menu\n\t */\n\t@Prop() offset: number = 8;\n\n\t/**\n\t * The strategy of the dropdown placement\n\t */\n\t@Prop() strategy: Strategy = 'absolute';\n\n\t/**\n\t * Wether to show the dropdown menu\n\t */\n\t@Prop() show: boolean = false;\n\n\t/**\n\t * Wether to use a portal for the dropdown container\n\t */\n\t@Prop() usePortal: boolean = false;\n\n\t/**\n\t * Wether to automatically calculate the width of the menu based on the trigger\n\t */\n\t@Prop() calculateWidth: boolean = false;\n\n\t/**\n\t * Wether to apply the max width\n\t */\n\t@Prop() applyMaxWidth: boolean = true;\n\n\t/**\n\t * Wether to apply the full width\n\t */\n\t@Prop() applyFullWidth: boolean = true;\n\n\t/**\n\t * Wether to allow overflow in the container\n\t */\n\t@Prop() allowOverflow: boolean = false;\n\n\t/**\n\t * Wether the dropdown container should be scrollable when the threshold is met.\n\t */\n\t@Prop() scrollable: boolean | 'default' | 'large' = false;\n\n\t/**\n\t * Wether to automatically close the dropdown menu after clicking inside\n\t */\n\t@Prop() insideClick: boolean = false;\n\n\t/**\n\t * Wether to automatically close the dropdown menu after clicking inside\n\t */\n\t@Prop() disableTriggerClick: boolean = false;\n\n\t/**\n\t * Wether to apply chevron automatically\n\t */\n\t@Prop() applyChevron: boolean = true;\n\n\t/**\n\t * Chevron position\n\t */\n\t@Prop() chevronPosition: 'start' | 'end' = 'end';\n\n\t/**\n\t * Chevron direction\n\t */\n\t@Prop() chevronDirection: 'up' | 'down';\n\n\t/**\n\t * The host element\n\t */\n\t@Element() private _el: HTMLElement;\n\n\t/**\n\t * Open change event\n\t */\n\t@Event({\n\t\tbubbles: false,\n\t})\n\tisOpen: EventEmitter<boolean>;\n\n\tprivate _loaded = false;\n\tprivate _trigger: HTMLElement;\n\tprivate _menu: HTMLElement;\n\tprivate _cleanup: () => void;\n\n\tcomponentShouldUpdate() {\n\t\tthis._update();\n\t}\n\n\tdisconnectedCallback() {\n\t\tif (this._cleanup) {\n\t\t\tthis._cleanup();\n\t\t\tthis._cleanup = null;\n\t\t}\n\n\t\tthis._menu.remove();\n\t}\n\n\tcomponentDidRender() {\n\t\tthis._checkButtons();\n\t}\n\n\trender() {\n\t\tconst dropdownContainerProps = {\n\t\t\tclass: `z-dropdown hidden ${\n\t\t\t\tthis.strategy === 'fixed' ? 'fixed' : 'absolute'\n\t\t\t}`,\n\t\t\tref: el => this._load(el),\n\t\t\tonClick: () => this._containerClickHandler(),\n\t\t\trole: 'popover',\n\t\t\t'data-placement': this.placement,\n\t\t\t'data-strategy': this.strategy,\n\t\t};\n\n\t\tlet dropdownContainer: HTMLElement;\n\n\t\tif (this.usePortal) {\n\t\t\tdropdownContainer = (\n\t\t\t\t<p-portal {...dropdownContainerProps}>\n\t\t\t\t\t<p-dropdown-menu-container\n\t\t\t\t\t\tmaxWidth={!this.calculateWidth && this.applyMaxWidth}\n\t\t\t\t\t\tfullWidth={this.applyFullWidth && !this.applyMaxWidth}\n\t\t\t\t\t\tallowOverflow={this.allowOverflow}\n\t\t\t\t\t\tscrollable={this.scrollable}\n\t\t\t\t\t>\n\t\t\t\t\t\t<slot name='items' />\n\t\t\t\t\t</p-dropdown-menu-container>\n\t\t\t\t</p-portal>\n\t\t\t);\n\t\t} else {\n\t\t\tdropdownContainer = (\n\t\t\t\t<p-dropdown-menu-container\n\t\t\t\t\tmaxWidth={!this.calculateWidth && this.applyMaxWidth}\n\t\t\t\t\tfullWidth={this.applyFullWidth && !this.applyMaxWidth}\n\t\t\t\t\tallowOverflow={this.allowOverflow}\n\t\t\t\t\tscrollable={this.scrollable}\n\t\t\t\t\t{...dropdownContainerProps}\n\t\t\t\t>\n\t\t\t\t\t<slot name='items' />\n\t\t\t\t</p-dropdown-menu-container>\n\t\t\t);\n\t\t}\n\n\t\treturn (\n\t\t\t<Host class='p-dropdown'>\n\t\t\t\t<div\n\t\t\t\t\tclass='trigger'\n\t\t\t\t\tref={ref => (this._trigger = ref)}\n\t\t\t\t\tonClick={() => this._triggerClickHandler()}\n\t\t\t\t>\n\t\t\t\t\t<slot name='trigger' />\n\t\t\t\t</div>\n\t\t\t\t{dropdownContainer}\n\t\t\t</Host>\n\t\t);\n\t}\n\n\tprivate _checkButtons() {\n\t\tif (!this.applyChevron) {\n\t\t\treturn;\n\t\t}\n\n\t\tconst children = this._el.querySelectorAll('p-button[slot=\"trigger\"]');\n\n\t\tfor (let child of [...children]) {\n\t\t\t(child as any).chevronPosition = this.chevronPosition;\n\t\t\t(child as any).chevron = this.chevronDirection\n\t\t\t\t? this.chevronDirection\n\t\t\t\t: this.placement.indexOf('top') >= 0\n\t\t\t\t? 'up'\n\t\t\t\t: 'down';\n\t\t}\n\t}\n\n\t@Watch('show')\n\tprotected onShowChange(show) {\n\t\tif (!this._loaded) {\n\t\t\treturn;\n\t\t}\n\n\t\tif (!show) {\n\t\t\tthis._hide();\n\t\t\treturn;\n\t\t}\n\n\t\tthis._show();\n\t}\n\n\t@Listen('click', { target: 'document', capture: true })\n\tprotected documentClickHandler({ target }) {\n\t\tif (!this._menu.hasAttribute('data-show') || childOf(target, this._menu)) {\n\t\t\treturn;\n\t\t}\n\n\t\tthis._hide();\n\t}\n\n\tprivate _containerClickHandler() {\n\t\tif (this.insideClick) {\n\t\t\treturn;\n\t\t}\n\n\t\tif (this._menu.hasAttribute('data-show')) {\n\t\t\tthis._hide();\n\t\t}\n\t}\n\n\tprivate _triggerClickHandler() {\n\t\tif (this.disableTriggerClick) {\n\t\t\treturn;\n\t\t}\n\n\t\tif (this._menu.hasAttribute('data-show')) {\n\t\t\tthis._hide();\n\t\t\treturn;\n\t\t}\n\n\t\tthis._show();\n\t}\n\n\tprivate _load(popover: HTMLElement) {\n\t\tthis._menu = popover;\n\t\tif (popover) {\n\t\t\tthis._update();\n\t\t\tthis._loaded = true;\n\n\t\t\tif (this.show) {\n\t\t\t\tsetTimeout(() => this._show(), 100);\n\t\t\t}\n\t\t}\n\t}\n\n\tprivate _show() {\n\t\tif (!this._loaded) {\n\t\t\treturn;\n\t\t}\n\n\t\t// Make the popover visible\n\t\tif (this.calculateWidth) {\n\t\t\tthis._menu.style.width = `${this._trigger.clientWidth}px`;\n\t\t}\n\n\t\tthis._cleanup = autoUpdate(this._el, this._menu, () => this._update());\n\n\t\tthis._menu.setAttribute('data-show', '');\n\t\tthis._menu.classList.remove('hidden');\n\t\tthis._menu.classList.add('flex');\n\n\t\tthis.isOpen.emit(true);\n\n\t\tthis._update();\n\t}\n\n\tprivate _hide() {\n\t\tif (!this._loaded || this.show) {\n\t\t\treturn;\n\t\t}\n\n\t\tif (this._cleanup) {\n\t\t\tthis._cleanup();\n\t\t\tthis._cleanup = null;\n\t\t}\n\n\t\t// Hide the popover\n\t\tthis._menu.removeAttribute('data-show');\n\t\tthis._menu.classList.remove('flex');\n\t\tthis._menu.classList.add('hidden');\n\n\t\tthis.isOpen.emit(false);\n\t}\n\n\tprivate _update() {\n\t\tif (!this._menu) {\n\t\t\treturn;\n\t\t}\n\n\t\tcomputePosition(this._el, this._menu, {\n\t\t\tplacement: this.placement,\n\t\t\tstrategy: this.strategy,\n\t\t\tmiddleware: [offset(this.offset), flip(), shift()],\n\t\t}).then(({ x, y, placement }) => {\n\t\t\tthis._menu.dataset.placement = placement;\n\t\t\tObject.assign(this._menu.style, {\n\t\t\t\ttop: `${y}px`,\n\t\t\t\tleft: `${x}px`,\n\t\t\t});\n\t\t});\n\t}\n}\n",":host {\n\t@import '../../../style/form/checkbox';\n\n\t@apply flex h-8 w-full items-center justify-start gap-2 rounded px-2;\n\t@apply text-sm font-semibold text-storm;\n\t@apply cursor-pointer;\n\n\t.text-container {\n\t\t@apply block w-full overflow-hidden text-ellipsis whitespace-nowrap text-start;\n\t}\n}\n\n:host(.hover:hover) {\n\t@apply bg-indigo-light text-storm;\n}\n\n:host(.active) {\n\t@apply bg-indigo-light text-indigo;\n}\n","import { Component, Host, Prop, h } from '@stencil/core';\nimport { IconVariant } from '../icon/icon.component';\n\n@Component({\n\ttag: 'p-dropdown-menu-item',\n\tstyleUrl: 'dropdown-menu-item.component.scss',\n\tshadow: true,\n})\nexport class DropdownMenuItem {\n\t/**\n\t * Wether the dropdown menu item is active\n\t */\n\t@Prop() active: boolean = false;\n\n\t/**\n\t * The variant of the item\n\t */\n\t@Prop() variant: 'default' | 'checkbox' = 'default';\n\n\t/**\n\t * Wether to enable the hover state\n\t */\n\t@Prop() enableHover: boolean = true;\n\n\t/**\n\t * Icon of the navigation item\n\t */\n\t@Prop() icon: IconVariant;\n\n\t/**\n\t * wether to use the container for text\n\t */\n\t@Prop() useContainer = true;\n\n\trender() {\n\t\treturn (\n\t\t\t<Host\n\t\t\t\tclass={`p-dropdown-menu-item ${this.active && 'active'} ${\n\t\t\t\t\tthis.enableHover && 'hover'\n\t\t\t\t}`}\n\t\t\t>\n\t\t\t\t{this.icon && <p-icon variant={this.icon} />}\n\n\t\t\t\t{this.variant === 'checkbox' && (\n\t\t\t\t\t<input\n\t\t\t\t\t\ttype='checkbox'\n\t\t\t\t\t\tclass='p-input size-small flex-shrink-0'\n\t\t\t\t\t\tchecked={this.active}\n\t\t\t\t\t/>\n\t\t\t\t)}\n\n\t\t\t\t{this.useContainer ? (\n\t\t\t\t\t<div class='text-container'>\n\t\t\t\t\t\t<slot />\n\t\t\t\t\t</div>\n\t\t\t\t) : (\n\t\t\t\t\t<slot />\n\t\t\t\t)}\n\t\t\t</Host>\n\t\t);\n\t}\n}\n"],"mappings":"+JAAA,MAAMA,EAAuB,od,MC0BhBC,EAAQ,M,wDAyFZC,KAAAC,QAAU,M,eArF8B,e,YAKvB,E,cAKI,W,UAKL,M,eAKK,M,oBAKK,M,mBAKD,K,oBAKC,K,mBAKD,M,gBAKmB,M,iBAKrB,M,yBAKQ,M,kBAKP,K,qBAKW,M,gCAyB3C,qBAAAC,GACCF,KAAKG,S,CAGN,oBAAAC,GACC,GAAIJ,KAAKK,SAAU,CAClBL,KAAKK,WACLL,KAAKK,SAAW,I,CAGjBL,KAAKM,MAAMC,Q,CAGZ,kBAAAC,GACCR,KAAKS,e,CAGN,MAAAC,GACC,MAAMC,EAAyB,CAC9BC,MAAO,qBACNZ,KAAKa,WAAa,QAAU,QAAU,aAEvCC,IAAKC,GAAMf,KAAKgB,MAAMD,GACtBE,QAAS,IAAMjB,KAAKkB,yBACpBC,KAAM,U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KAAKsE,QAASC,IAAQC,OACxCC,MAAK,EAAGC,IAAGC,IAAGvD,gBAChBpB,KAAKM,MAAMsE,QAAQxD,UAAYA,EAC/BI,OAAOC,OAAOzB,KAAKM,MAAMoD,MAAO,CAC/BmB,IAAK,GAAGF,MACRG,KAAM,GAAGJ,OACR,G,0FChUL,MAAMK,EAA+B,uoW,MCQxBC,EAAgB,M,qCAIF,M,aAKgB,U,iBAKX,K,sCAUR,I,CAEvB,MAAAtE,GACC,OACCa,EAACW,EAAI,CACJtB,MAAO,wBAAwBZ,KAAKiF,QAAU,YAC7CjF,KAAKkF,aAAe,WAGpBlF,KAAKmF,MAAQ5D,EAAA,UAAQ6D,QAASpF,KAAKmF,OAEnCnF,KAAKoF,UAAY,YACjB7D,EAAA,SACC8D,KAAK,WACLzE,MAAM,mCACN0E,QAAStF,KAAKiF,SAIfjF,KAAKuF,aACLhE,EAAA,OAAKX,MAAM,kBACVW,EAAA,cAGDA,EAAA,a"}
|
|
1
|
+
{"version":3,"names":["dropdownComponentCss","Dropdown","this","_loaded","componentShouldUpdate","_update","disconnectedCallback","_cleanup","_menu","remove","componentDidRender","_checkButtons","render","dropdownContainerProps","class","strategy","ref","el","_load","onClick","_containerClickHandler","role","placement","dropdownContainer","usePortal","h","Object","assign","maxWidth","calculateWidth","applyMaxWidth","fullWidth","applyFullWidth","allowOverflow","scrollable","name","Host","_trigger","_triggerClickHandler","applyChevron","children","_el","querySelectorAll","child","chevronPosition","chevron","chevronDirection","indexOf","onShowChange","show","_hide","_show","documentClickHandler","target","hasAttribute","childOf","insideClick","disableTriggerClick","popover","setTimeout","style","width","clientWidth","autoUpdate","setAttribute","classList","add","isOpen","emit","removeAttribute","computePosition","middleware","offset","flip","shift","then","x","y","dataset","top","left","dropdownMenuItemComponentCss","DropdownMenuItem","active","enableHover","icon","variant","type","checked","useContainer"],"sources":["src/components/molecules/dropdown/dropdown.component.scss?tag=p-dropdown","src/components/molecules/dropdown/dropdown.component.tsx","src/components/atoms/dropdown-menu-item/dropdown-menu-item.component.scss?tag=p-dropdown-menu-item&encapsulation=shadow","src/components/atoms/dropdown-menu-item/dropdown-menu-item.component.tsx"],"sourcesContent":["p-dropdown {\n\t@apply relative block;\n\n\t.trigger {\n\t\t@apply relative block h-auto w-auto;\n\t}\n}\n","import {\n\tautoUpdate,\n\tcomputePosition,\n\tflip,\n\toffset,\n\tPlacement,\n\tshift,\n\tStrategy,\n} from '@floating-ui/dom';\nimport {\n\tComponent,\n\tElement,\n\tEvent,\n\tEventEmitter,\n\th,\n\tHost,\n\tListen,\n\tProp,\n\tWatch,\n} from '@stencil/core';\nimport { childOf } from '../../../utils/child-of';\n\n@Component({\n\ttag: 'p-dropdown',\n\tstyleUrl: 'dropdown.component.scss',\n})\nexport class Dropdown {\n\t/**\n\t * The content of the dropdown menu\n\t */\n\t@Prop({ reflect: true }) placement: Placement = 'bottom-start';\n\n\t/**\n\t * The offset of the dropdown menu\n\t */\n\t@Prop() offset: number = 8;\n\n\t/**\n\t * The strategy of the dropdown placement\n\t */\n\t@Prop() strategy: Strategy = 'absolute';\n\n\t/**\n\t * Wether to show the dropdown menu\n\t */\n\t@Prop() show: boolean = false;\n\n\t/**\n\t * Wether to use a portal for the dropdown container\n\t */\n\t@Prop() usePortal: boolean = false;\n\n\t/**\n\t * Wether to automatically calculate the width of the menu based on the trigger\n\t */\n\t@Prop() calculateWidth: boolean = false;\n\n\t/**\n\t * Wether to apply the max width\n\t */\n\t@Prop() applyMaxWidth: boolean = true;\n\n\t/**\n\t * Wether to apply the full width\n\t */\n\t@Prop() applyFullWidth: boolean = true;\n\n\t/**\n\t * Wether to allow overflow in the container\n\t */\n\t@Prop() allowOverflow: boolean = false;\n\n\t/**\n\t * Wether the dropdown container should be scrollable when the threshold is met.\n\t */\n\t@Prop() scrollable: boolean | 'default' | 'large' = false;\n\n\t/**\n\t * Wether to automatically close the dropdown menu after clicking inside\n\t */\n\t@Prop() insideClick: boolean = false;\n\n\t/**\n\t * Wether to automatically close the dropdown menu after clicking inside\n\t */\n\t@Prop() disableTriggerClick: boolean = false;\n\n\t/**\n\t * Wether to apply chevron automatically\n\t */\n\t@Prop() applyChevron: boolean = true;\n\n\t/**\n\t * Chevron position\n\t */\n\t@Prop() chevronPosition: 'start' | 'end' = 'end';\n\n\t/**\n\t * Chevron direction\n\t */\n\t@Prop() chevronDirection: 'up' | 'down';\n\n\t/**\n\t * The host element\n\t */\n\t@Element() private _el: HTMLElement;\n\n\t/**\n\t * Open change event\n\t */\n\t@Event({\n\t\tbubbles: false,\n\t})\n\tisOpen: EventEmitter<boolean>;\n\n\tprivate _loaded = false;\n\tprivate _trigger: HTMLElement;\n\tprivate _menu: HTMLElement;\n\tprivate _cleanup: () => void;\n\n\tcomponentShouldUpdate() {\n\t\tthis._update();\n\t}\n\n\tdisconnectedCallback() {\n\t\tif (this._cleanup) {\n\t\t\tthis._cleanup();\n\t\t\tthis._cleanup = null;\n\t\t}\n\n\t\tthis._menu.remove();\n\t}\n\n\tcomponentDidRender() {\n\t\tthis._checkButtons();\n\t}\n\n\trender() {\n\t\tconst dropdownContainerProps = {\n\t\t\tclass: `z-dropdown hidden ${\n\t\t\t\tthis.strategy === 'fixed' ? 'fixed' : 'absolute'\n\t\t\t}`,\n\t\t\tref: el => this._load(el),\n\t\t\tonClick: () => this._containerClickHandler(),\n\t\t\trole: 'popover',\n\t\t\t'data-placement': this.placement,\n\t\t\t'data-strategy': this.strategy,\n\t\t};\n\n\t\tlet dropdownContainer: HTMLElement;\n\n\t\tif (this.usePortal) {\n\t\t\tdropdownContainer = (\n\t\t\t\t<p-portal {...dropdownContainerProps}>\n\t\t\t\t\t<p-dropdown-menu-container\n\t\t\t\t\t\tmaxWidth={!this.calculateWidth && this.applyMaxWidth}\n\t\t\t\t\t\tfullWidth={this.applyFullWidth && !this.applyMaxWidth}\n\t\t\t\t\t\tallowOverflow={this.allowOverflow}\n\t\t\t\t\t\tscrollable={this.scrollable}\n\t\t\t\t\t>\n\t\t\t\t\t\t<slot name='items' />\n\t\t\t\t\t</p-dropdown-menu-container>\n\t\t\t\t</p-portal>\n\t\t\t);\n\t\t} else {\n\t\t\tdropdownContainer = (\n\t\t\t\t<p-dropdown-menu-container\n\t\t\t\t\tmaxWidth={!this.calculateWidth && this.applyMaxWidth}\n\t\t\t\t\tfullWidth={this.applyFullWidth && !this.applyMaxWidth}\n\t\t\t\t\tallowOverflow={this.allowOverflow}\n\t\t\t\t\tscrollable={this.scrollable}\n\t\t\t\t\t{...dropdownContainerProps}\n\t\t\t\t>\n\t\t\t\t\t<slot name='items' />\n\t\t\t\t</p-dropdown-menu-container>\n\t\t\t);\n\t\t}\n\n\t\treturn (\n\t\t\t<Host class='p-dropdown'>\n\t\t\t\t<div\n\t\t\t\t\tclass='trigger'\n\t\t\t\t\tref={ref => (this._trigger = ref)}\n\t\t\t\t\tonClick={() => this._triggerClickHandler()}\n\t\t\t\t>\n\t\t\t\t\t<slot name='trigger' />\n\t\t\t\t</div>\n\t\t\t\t{dropdownContainer}\n\t\t\t</Host>\n\t\t);\n\t}\n\n\tprivate _checkButtons() {\n\t\tif (!this.applyChevron) {\n\t\t\treturn;\n\t\t}\n\n\t\tconst children = this._el.querySelectorAll('p-button[slot=\"trigger\"]');\n\n\t\tfor (let child of [...children]) {\n\t\t\t(child as any).chevronPosition = this.chevronPosition;\n\t\t\t(child as any).chevron = this.chevronDirection\n\t\t\t\t? this.chevronDirection\n\t\t\t\t: this.placement.indexOf('top') >= 0\n\t\t\t\t? 'up'\n\t\t\t\t: 'down';\n\t\t}\n\t}\n\n\t@Watch('show')\n\tprotected onShowChange(show) {\n\t\tif (!this._loaded) {\n\t\t\treturn;\n\t\t}\n\n\t\tif (!show) {\n\t\t\tthis._hide();\n\t\t\treturn;\n\t\t}\n\n\t\tthis._show();\n\t}\n\n\t@Listen('click', { target: 'document', capture: true })\n\tprotected documentClickHandler({ target }) {\n\t\tif (!this._menu.hasAttribute('data-show') || childOf(target, this._menu)) {\n\t\t\treturn;\n\t\t}\n\n\t\tthis._hide();\n\t}\n\n\tprivate _containerClickHandler() {\n\t\tif (this.insideClick) {\n\t\t\treturn;\n\t\t}\n\n\t\tif (this._menu.hasAttribute('data-show')) {\n\t\t\tthis._hide();\n\t\t}\n\t}\n\n\tprivate _triggerClickHandler() {\n\t\tif (this.disableTriggerClick) {\n\t\t\treturn;\n\t\t}\n\n\t\tif (this._menu.hasAttribute('data-show')) {\n\t\t\tthis._hide();\n\t\t\treturn;\n\t\t}\n\n\t\tthis._show();\n\t}\n\n\tprivate _load(popover: HTMLElement) {\n\t\tthis._menu = popover;\n\t\tif (popover) {\n\t\t\tthis._update();\n\t\t\tthis._loaded = true;\n\n\t\t\tif (this.show) {\n\t\t\t\tsetTimeout(() => this._show(), 100);\n\t\t\t}\n\t\t}\n\t}\n\n\tprivate _show() {\n\t\tif (!this._loaded) {\n\t\t\treturn;\n\t\t}\n\n\t\t// Make the popover visible\n\t\tif (this.calculateWidth) {\n\t\t\tthis._menu.style.width = `${this._trigger.clientWidth}px`;\n\t\t}\n\n\t\tthis._cleanup = autoUpdate(this._el, this._menu, () => this._update());\n\n\t\tthis._menu.setAttribute('data-show', '');\n\t\tthis._menu.classList.remove('hidden');\n\t\tthis._menu.classList.add('block');\n\n\t\tthis.isOpen.emit(true);\n\n\t\tthis._update();\n\t}\n\n\tprivate _hide() {\n\t\tif (!this._loaded || this.show) {\n\t\t\treturn;\n\t\t}\n\n\t\tif (this._cleanup) {\n\t\t\tthis._cleanup();\n\t\t\tthis._cleanup = null;\n\t\t}\n\n\t\t// Hide the popover\n\t\tthis._menu.removeAttribute('data-show');\n\t\tthis._menu.classList.remove('block');\n\t\tthis._menu.classList.add('hidden');\n\n\t\tthis.isOpen.emit(false);\n\t}\n\n\tprivate _update() {\n\t\tif (!this._menu) {\n\t\t\treturn;\n\t\t}\n\n\t\tcomputePosition(this._el, this._menu, {\n\t\t\tplacement: this.placement,\n\t\t\tstrategy: this.strategy,\n\t\t\tmiddleware: [offset(this.offset), flip(), shift()],\n\t\t}).then(({ x, y, placement }) => {\n\t\t\tthis._menu.dataset.placement = placement;\n\t\t\tObject.assign(this._menu.style, {\n\t\t\t\ttop: `${y}px`,\n\t\t\t\tleft: `${x}px`,\n\t\t\t});\n\t\t});\n\t}\n}\n",":host {\n\t@import '../../../style/form/checkbox';\n\n\t@apply flex h-8 w-full items-center justify-start gap-2 rounded px-2;\n\t@apply text-sm font-semibold text-storm;\n\t@apply cursor-pointer;\n\n\t.text-container {\n\t\t@apply block w-full overflow-hidden text-ellipsis whitespace-nowrap text-start;\n\t}\n}\n\n:host(.hover:hover) {\n\t@apply bg-indigo-light text-storm;\n}\n\n:host(.active) {\n\t@apply bg-indigo-light text-indigo;\n}\n","import { Component, Host, Prop, h } from '@stencil/core';\nimport { IconVariant } from '../icon/icon.component';\n\n@Component({\n\ttag: 'p-dropdown-menu-item',\n\tstyleUrl: 'dropdown-menu-item.component.scss',\n\tshadow: true,\n})\nexport class DropdownMenuItem {\n\t/**\n\t * Wether the dropdown menu item is active\n\t */\n\t@Prop() active: boolean = false;\n\n\t/**\n\t * The variant of the item\n\t */\n\t@Prop() variant: 'default' | 'checkbox' = 'default';\n\n\t/**\n\t * Wether to enable the hover state\n\t */\n\t@Prop() enableHover: boolean = true;\n\n\t/**\n\t * Icon of the navigation item\n\t */\n\t@Prop() icon: IconVariant;\n\n\t/**\n\t * wether to use the container for text\n\t */\n\t@Prop() useContainer = true;\n\n\trender() {\n\t\treturn (\n\t\t\t<Host\n\t\t\t\tclass={`p-dropdown-menu-item ${this.active && 'active'} ${\n\t\t\t\t\tthis.enableHover && 'hover'\n\t\t\t\t}`}\n\t\t\t>\n\t\t\t\t{this.icon && <p-icon variant={this.icon} />}\n\n\t\t\t\t{this.variant === 'checkbox' && (\n\t\t\t\t\t<input\n\t\t\t\t\t\ttype='checkbox'\n\t\t\t\t\t\tclass='p-input size-small flex-shrink-0'\n\t\t\t\t\t\tchecked={this.active}\n\t\t\t\t\t/>\n\t\t\t\t)}\n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QAAStF,KAAKiF,SAIfjF,KAAKuF,aACLhE,EAAA,OAAKX,MAAM,kBACVW,EAAA,cAGDA,EAAA,a"}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{r as t,h as r,H as i}from"./p-0c2cc6c4.js";const e=".absolute{position:absolute!important}.relative{position:relative!important}.left-1\\/2{left:50%!important}.top-0{top:0!important}.order-2{order:2!important}.ml-0{margin-left:0!important}.mr-4{margin-right:1rem!important}.flex{display:flex!important}.h-4{height:1rem!important}.min-h-\\[1rem\\]{min-height:1rem!important}.w-4{width:1rem!important}.w-full{width:100%!important}.min-w-\\[calc\\(100\\%-2rem\\)\\]{min-width:calc(100% - 2rem)!important}.-translate-x-1\\/2{--tw-translate-x:-50%!important}.-translate-x-1\\/2,.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}.items-end{align-items:flex-end!important}.items-center{align-items:center!important}.justify-center{justify-content:center!important}.bg-mystic-dark{--tw-bg-opacity:1!important;background-color:rgb(218 230 240/var(--tw-bg-opacity))!important}.text-sm{font-size:.875rem!important;line-height:1.25rem!important}.transition{transition-duration:.15s!important;transition-property:color,background-color,border-color,text-decoration-color,fill,stroke,opacity,box-shadow,transform,filter,backdrop-filter!important;transition-timing-function:cubic-bezier(.4,0,.2,1)!important}.duration-500{transition-duration:.5s!important}*{box-sizing:border-box}:host{align-items:flex-end;display:flex;justify-content:center;position:relative;width:100%}:host .content{--tw-text-opacity:1;color:rgb(176 178 203/var(--tw-text-opacity));font-size:.875rem;line-height:1.25rem;min-width:calc(100% - 2rem);white-space:nowrap}:host .circle{--tw-bg-opacity:1;--tw-text-opacity:1;align-items:center;background-color:rgb(218 230 240/var(--tw-bg-opacity));border-radius:100%;color:rgb(255 255 255/var(--tw-text-opacity));display:flex;flex-shrink:0;height:1rem;justify-content:center;transition-duration:.5s;transition-property:color,background-color,border-color,text-decoration-color,fill,stroke,opacity,box-shadow,transform,filter,backdrop-filter;transition-timing-function:cubic-bezier(.4,0,.2,1);width:1rem}:host .circle p-icon{display:flex!important;font-size:.625rem}:host([direction=horizontal]){flex:0;height:2.5rem}:host([direction=horizontal]) .content{min-width:0;order:1;position:absolute;top:0}:host([direction=horizontal]) .circle{order:2}:host([direction=vertical]){align-items:center;min-height:1rem}:host([direction=vertical]) .content{margin-left:1rem;order:2}:host([direction=vertical]) .circle{order:1}:host([active]) .content,:host([finished]) .content{--tw-text-opacity:1;color:rgb(82 138 250/var(--tw-text-opacity))}:host([active]) .circle,:host([finished]) .circle{--tw-bg-opacity:1;background-color:rgb(82 138 250/var(--tw-bg-opacity))}:host([direction=horizontal][align=start]) .content{left:0}:host([direction=horizontal][align=end]) .content{right:0}:host([direction=horizontal][align=center]) .content{--tw-translate-x:-50%;left:50%;text-align:center;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))}:host([direction=vertical][content-position=start]){flex-direction:row-reverse}:host([direction=vertical][content-position=start]) .content{display:flex;justify-content:flex-end;margin-left:0;margin-right:1rem}";const o=class{constructor(r){t(this,r);this.align="center";this.direction="horizontal";this.contentPosition="end";this.finished=false;this.active=false}render(){return r(i,{class:"p-stepper-item"},r("div",{class:"circle"},this.finished&&r("p-icon",{variant:"checkmark"})),r("div",{class:"content"},r("slot",{name:"content"})))}};o.style=e;export{o as p_stepper_item};
|
|
2
|
-
//# sourceMappingURL=p-
|
|
1
|
+
import{r as t,h as r,H as i}from"./p-0c2cc6c4.js";const e=".absolute{position:absolute!important}.relative{position:relative!important}.left-1\\/2{left:50%!important}.top-0{top:0!important}.order-2{order:2!important}.ml-0{margin-left:0!important}.mr-4{margin-right:1rem!important}.flex{display:flex!important}.h-4{height:1rem!important}.min-h-\\[1rem\\]{min-height:1rem!important}.w-4{width:1rem!important}.w-full{width:100%!important}.min-w-\\[calc\\(100\\%-2rem\\)\\]{min-width:calc(100% - 2rem)!important}.-translate-x-1\\/2{--tw-translate-x:-50%!important}.-translate-x-1\\/2,.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}.items-end{align-items:flex-end!important}.items-center{align-items:center!important}.justify-center{justify-content:center!important}.bg-mystic-dark{--tw-bg-opacity:1!important;background-color:rgb(218 230 240/var(--tw-bg-opacity))!important}.text-sm{font-size:.875rem!important;line-height:1.25rem!important}.transition{transition-duration:.15s!important;transition-property:color,background-color,border-color,text-decoration-color,fill,stroke,opacity,box-shadow,transform,filter,backdrop-filter!important;transition-timing-function:cubic-bezier(.4,0,.2,1)!important}.duration-500{transition-duration:.5s!important}*{box-sizing:border-box}:host{align-items:flex-end;display:flex;justify-content:center;position:relative;width:100%}:host .content{--tw-text-opacity:1;color:rgb(176 178 203/var(--tw-text-opacity));font-size:.875rem;line-height:1.25rem;min-width:calc(100% - 2rem);white-space:nowrap}:host .circle{--tw-bg-opacity:1;--tw-text-opacity:1;align-items:center;background-color:rgb(218 230 240/var(--tw-bg-opacity));border-radius:100%;color:rgb(255 255 255/var(--tw-text-opacity));display:flex;flex-shrink:0;height:1rem;justify-content:center;transition-duration:.5s;transition-property:color,background-color,border-color,text-decoration-color,fill,stroke,opacity,box-shadow,transform,filter,backdrop-filter;transition-timing-function:cubic-bezier(.4,0,.2,1);width:1rem}:host .circle p-icon{display:flex!important;font-size:.625rem}:host([direction=horizontal]){flex:0;height:2.5rem}:host([direction=horizontal]) .content{min-width:0;order:1;position:absolute;top:0}:host([direction=horizontal]) .circle{order:2}:host([direction=vertical]){align-items:center;min-height:1rem}:host([direction=vertical]) .content{margin-left:1rem;order:2}:host([direction=vertical]) .circle{order:1}:host([active]) .content,:host([finished]) .content{--tw-text-opacity:1;color:rgb(82 138 250/var(--tw-text-opacity))}:host([active]) .circle,:host([finished]) .circle{--tw-bg-opacity:1;background-color:rgb(82 138 250/var(--tw-bg-opacity))}:host([direction=horizontal][align=start]) .content{left:0}:host([direction=horizontal][align=end]) .content{right:0}:host([direction=horizontal][align=center]) .content{--tw-translate-x:-50%;left:50%;text-align:center;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))}:host([direction=vertical][content-position=start]){flex-direction:row-reverse}:host([direction=vertical][content-position=start]) .content{display:flex;justify-content:flex-end;margin-left:0;margin-right:1rem}.static{position:static!important}";const o=class{constructor(r){t(this,r);this.align="center";this.direction="horizontal";this.contentPosition="end";this.finished=false;this.active=false}render(){return r(i,{class:"p-stepper-item"},r("div",{class:"circle"},this.finished&&r("p-icon",{variant:"checkmark"})),r("div",{class:"content"},r("slot",{name:"content"})))}};o.style=e;export{o as p_stepper_item};
|
|
2
|
+
//# sourceMappingURL=p-744f5a41.entry.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["stepperItemComponentCss","StepperItem","render","h","Host","class","this","finished","variant","name"],"sources":["src/components/atoms/stepper-item/stepper-item.component.scss?tag=p-stepper-item&encapsulation=shadow","src/components/atoms/stepper-item/stepper-item.component.tsx"],"sourcesContent":[":host {\n\t@apply relative flex w-full items-end justify-center;\n\n\t.content {\n\t\t@apply min-w-[calc(100%-2rem)] whitespace-nowrap;\n\t\t@apply text-sm text-storm-light;\n\t}\n\n\t.circle {\n\t\t@apply transition duration-500 ease-in-out;\n\t\t@apply flex items-center justify-center flex-shrink-0;\n\t\t@apply h-4 w-4 rounded-round;\n\t\t@apply bg-mystic-dark text-white;\n\n\t\tp-icon {\n\t\t\t@apply flex #{!important};\n\t\t\tfont-size: 0.625rem;\n\t\t}\n\t}\n}\n\n:host([direction='horizontal']) {\n\tflex: 0;\n\t@apply h-10;\n\n\t.content {\n\t\t@apply absolute top-0 min-w-0;\n\t\t@apply order-1;\n\t}\n\n\t.circle {\n\t\t@apply order-2;\n\t}\n}\n\n:host([direction='vertical']) {\n\t@apply min-h-[1rem] items-center;\n\n\t.content {\n\t\t@apply order-2 ml-4;\n\t}\n\n\t.circle {\n\t\t@apply order-1;\n\t}\n}\n\n:host([active]),\n:host([finished]) {\n\t.content {\n\t\t@apply text-indigo;\n\t}\n\n\t.circle {\n\t\t@apply bg-indigo;\n\t}\n}\n\n:host([direction='horizontal'][align='start']) {\n\t.content {\n\t\t@apply left-0;\n\t}\n}\n\n:host([direction='horizontal'][align='end']) {\n\t.content {\n\t\t@apply right-0;\n\t}\n}\n\n:host([direction='horizontal'][align='center']) {\n\t.content {\n\t\t@apply left-1/2 -translate-x-1/2 transform text-center;\n\t}\n}\n\n:host([direction='vertical'][content-position='start']) {\n\t@apply flex-row-reverse;\n\n\t.content {\n\t\t@apply ml-0 mr-4 flex justify-end;\n\t}\n}\n","import { Component, h, Host, Prop } from '@stencil/core';\n\n@Component({\n\ttag: 'p-stepper-item',\n\tstyleUrl: 'stepper-item.component.scss',\n\tshadow: true,\n})\nexport class StepperItem {\n\t/**\n\t * The alignment of the step content\n\t */\n\t@Prop({ reflect: true }) align: 'start' | 'center' | 'end' = 'center';\n\n\t/**\n\t * The direction of the stepper step\n\t */\n\t@Prop({ reflect: true }) direction: 'horizontal' | 'vertical' =\n\t\t'horizontal';\n\n\t/**\n\t * The position of the content in case of vertical direction\n\t */\n\t@Prop({ reflect: true }) contentPosition: 'start' | 'end' = 'end';\n\n\t/**\n\t * Wether the step is finished\n\t */\n\t@Prop({ reflect: true }) finished: boolean = false;\n\n\t/**\n\t * Wether the step is active\n\t */\n\t@Prop({ reflect: true }) active: boolean = false;\n\n\trender() {\n\t\treturn (\n\t\t\t<Host class=\"p-stepper-item\">\n\t\t\t\t<div class=\"circle\">\n\t\t\t\t\t{this.finished && <p-icon variant=\"checkmark\" />}\n\t\t\t\t</div>\n\t\t\t\t<div class=\"content\">\n\t\t\t\t\t<slot name=\"content\" />\n\t\t\t\t</div>\n\t\t\t</Host>\n\t\t);\n\t}\n}\n"],"mappings":"kDAAA,MAAMA,EAA0B,
|
|
1
|
+
{"version":3,"names":["stepperItemComponentCss","StepperItem","render","h","Host","class","this","finished","variant","name"],"sources":["src/components/atoms/stepper-item/stepper-item.component.scss?tag=p-stepper-item&encapsulation=shadow","src/components/atoms/stepper-item/stepper-item.component.tsx"],"sourcesContent":[":host {\n\t@apply relative flex w-full items-end justify-center;\n\n\t.content {\n\t\t@apply min-w-[calc(100%-2rem)] whitespace-nowrap;\n\t\t@apply text-sm text-storm-light;\n\t}\n\n\t.circle {\n\t\t@apply transition duration-500 ease-in-out;\n\t\t@apply flex items-center justify-center flex-shrink-0;\n\t\t@apply h-4 w-4 rounded-round;\n\t\t@apply bg-mystic-dark text-white;\n\n\t\tp-icon {\n\t\t\t@apply flex #{!important};\n\t\t\tfont-size: 0.625rem;\n\t\t}\n\t}\n}\n\n:host([direction='horizontal']) {\n\tflex: 0;\n\t@apply h-10;\n\n\t.content {\n\t\t@apply absolute top-0 min-w-0;\n\t\t@apply order-1;\n\t}\n\n\t.circle {\n\t\t@apply order-2;\n\t}\n}\n\n:host([direction='vertical']) {\n\t@apply min-h-[1rem] items-center;\n\n\t.content {\n\t\t@apply order-2 ml-4;\n\t}\n\n\t.circle {\n\t\t@apply order-1;\n\t}\n}\n\n:host([active]),\n:host([finished]) {\n\t.content {\n\t\t@apply text-indigo;\n\t}\n\n\t.circle {\n\t\t@apply bg-indigo;\n\t}\n}\n\n:host([direction='horizontal'][align='start']) {\n\t.content {\n\t\t@apply left-0;\n\t}\n}\n\n:host([direction='horizontal'][align='end']) {\n\t.content {\n\t\t@apply right-0;\n\t}\n}\n\n:host([direction='horizontal'][align='center']) {\n\t.content {\n\t\t@apply left-1/2 -translate-x-1/2 transform text-center;\n\t}\n}\n\n:host([direction='vertical'][content-position='start']) {\n\t@apply flex-row-reverse;\n\n\t.content {\n\t\t@apply ml-0 mr-4 flex justify-end;\n\t}\n}\n","import { Component, h, Host, Prop } from '@stencil/core';\n\n@Component({\n\ttag: 'p-stepper-item',\n\tstyleUrl: 'stepper-item.component.scss',\n\tshadow: true,\n})\nexport class StepperItem {\n\t/**\n\t * The alignment of the step content\n\t */\n\t@Prop({ reflect: true }) align: 'start' | 'center' | 'end' = 'center';\n\n\t/**\n\t * The direction of the stepper step\n\t */\n\t@Prop({ reflect: true }) direction: 'horizontal' | 'vertical' =\n\t\t'horizontal';\n\n\t/**\n\t * The position of the content in case of vertical direction\n\t */\n\t@Prop({ reflect: true }) contentPosition: 'start' | 'end' = 'end';\n\n\t/**\n\t * Wether the step is finished\n\t */\n\t@Prop({ reflect: true }) finished: boolean = false;\n\n\t/**\n\t * Wether the step is active\n\t */\n\t@Prop({ reflect: true }) active: boolean = false;\n\n\trender() {\n\t\treturn (\n\t\t\t<Host class=\"p-stepper-item\">\n\t\t\t\t<div class=\"circle\">\n\t\t\t\t\t{this.finished && <p-icon variant=\"checkmark\" />}\n\t\t\t\t</div>\n\t\t\t\t<div class=\"content\">\n\t\t\t\t\t<slot name=\"content\" />\n\t\t\t\t</div>\n\t\t\t</Host>\n\t\t);\n\t}\n}\n"],"mappings":"kDAAA,MAAMA,EAA0B,21G,MCOnBC,EAAW,M,oCAIsC,S,eAM5D,a,qBAK2D,M,cAKf,M,YAKF,K,CAE3C,MAAAC,GACC,OACCC,EAACC,EAAI,CAACC,MAAM,kBACXF,EAAA,OAAKE,MAAM,UACTC,KAAKC,UAAYJ,EAAA,UAAQK,QAAQ,eAEnCL,EAAA,OAAKE,MAAM,WACVF,EAAA,QAAMM,KAAK,a"}
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
import{r as t,h as i,H as e,g as s}from"./p-0c2cc6c4.js";const o=".flex{display:flex!important}.h-auto{height:auto!important}.w-full{width:100%!important}.flex-col{flex-direction:column!important}.flex-wrap{flex-wrap:wrap!important}*{box-sizing:border-box}:host{display:flex}:host([direction=horizontal]){align-items:flex-end;height:auto}:host([direction=vertical]){align-items:flex-start;flex-direction:column;flex-wrap:wrap;min-height:100%;width:100%}:host([direction=vertical][content-position=start]){align-items:flex-end}.static{position:static!important}";const n=class{constructor(i){t(this,i);this._generateStepsOnce=()=>{if(this._generateTimeout){clearTimeout(this._generateTimeout);this._generateTimeout=null}this._generateTimeout=setTimeout((()=>this._generateSteps()),50)};this._generateSteps=async()=>{if(!this._el){return}let t=this.activeStep-1||0;const i=this._el.querySelectorAll("p-stepper-item");let e=false;for(let s=0;s<(i===null||i===void 0?void 0:i.length);s++){const o=i.item(s);if(this.enableAutoStatus){o.active=s===t;o.finished=s<t}if(!this.activeStep||t<0){if(o.active){t=s}if(t<0&&o.finished){t=s+1}}if(o.direction!==this.direction&&!e){e=true}o.direction=this.direction;o.align=this.direction==="vertical"?"start":s===0?"start":s===(i===null||i===void 0?void 0:i.length)-1?"end":"center";o.contentPosition=this.contentPosition}if(e){await new Promise((t=>setTimeout(t,200)))}for(let e=0;e<(i===null||i===void 0?void 0:i.length);e++){const s=i.item(e);if(e<i.length-1){let i=s.nextElementSibling;if(i&&i.tagName.toLowerCase()==="p-stepper-item"){const o=document.createElement("p-stepper-line");this._el.insertBefore(o,i);this._setStepperLineData(o,s,i,e,t);const n=o.previousElementSibling;if(n&&n.tagName.toLowerCase()==="p-stepper-line"){n.remove()}continue}if(i&&i.tagName.toLowerCase()==="p-stepper-line"){const o=i;i=i.nextElementSibling;if(i&&i.tagName.toLowerCase()==="p-stepper-item"){this._setStepperLineData(o,s,i,e,t)}}}if(e>0){const t=s.previousElementSibling;if(t&&t.tagName.toLowerCase()==="p-stepper-line"){t.direction=this.direction;t.active=s.active||s.finished}}}const s=this._el.querySelectorAll("p-stepper-line:not(:has(+ p-stepper-item)), p-stepper-line:first-child");for(let t=s.length-1;t>=0;t--){const i=s.item(t);i.remove()}};this._setStepperLineData=(t,i,e,s,o)=>{const n=i.clientHeight/2;const r=e.clientHeight/2;t.direction=this.direction;t.active=s<o;if(n>0&&this.direction==="vertical"){t.style.marginTop=`-${n/16}rem`;t.style.marginBottom=`-${r/16}rem`;t.style.minHeight=`calc(1rem + ${(n+r)/16}rem)`}};this.activeStep=1;this.enableAutoStatus=true;this.direction="horizontal";this.contentPosition="end"}componentDidLoad(){this._resizeObserver=new ResizeObserver((()=>this._generateStepsOnce()));this._resizeObserver.observe(this._el)}disconnectCallback(){if(this._resizeObserver){this._resizeObserver.disconnect()}}render(){return i(e,{class:"p-stepper"},i("slot",{onSlotchange:()=>this._generateStepsOnce()}))}_onActiveStepChange(){this._generateStepsOnce()}get _el(){return s(this)}static get watchers(){return{activeStep:["_onActiveStepChange"]}}};n.style=o;export{n as p_stepper};
|
|
2
|
+
//# sourceMappingURL=p-a689640d.entry.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["stepperComponentCss","Stepper","this","_generateStepsOnce","_generateTimeout","clearTimeout","setTimeout","_generateSteps","async","_el","activeStep","items","querySelectorAll","directionChanged","i","length","item","enableAutoStatus","active","finished","direction","align","contentPosition","Promise","resolve","nextItem","nextElementSibling","tagName","toLowerCase","stepperLine","document","createElement","insertBefore","_setStepperLineData","previous","previousElementSibling","remove","previousItem","lines","j","line","heightDiff","clientHeight","heightDiffNext","style","marginTop","marginBottom","minHeight","componentDidLoad","_resizeObserver","ResizeObserver","observe","disconnectCallback","disconnect","render","h","Host","class","onSlotchange","_onActiveStepChange"],"sources":["src/components/molecules/stepper/stepper.component.scss?tag=p-stepper&encapsulation=shadow","src/components/molecules/stepper/stepper.component.tsx"],"sourcesContent":[":host {\n\t@apply flex;\n}\n\n:host([direction='horizontal']) {\n\t@apply h-auto items-end;\n}\n\n:host([direction='vertical']) {\n\t@apply flex-col flex-wrap items-start;\n\t@apply w-full min-h-full;\n}\n\n:host([direction='vertical'][content-position='start']) {\n\t@apply items-end;\n}\n","import { Component, Element, h, Host, Prop, Watch } from '@stencil/core';\n\n@Component({\n\ttag: 'p-stepper',\n\tstyleUrl: 'stepper.component.scss',\n\tshadow: true,\n})\nexport class Stepper {\n\t/**\n\t * The currently active step\n\t */\n\t@Prop() activeStep: number = 1;\n\n\t/**\n\t * Wether to automatically apply active & finished to items\n\t */\n\t@Prop() enableAutoStatus: boolean = true;\n\n\t/**\n\t * The direction of the stepper\n\t */\n\t@Prop({ reflect: true }) direction: 'horizontal' | 'vertical' = 'horizontal';\n\n\t/**\n\t * The position of the content in case of vertical direction\n\t */\n\t@Prop({ reflect: true }) contentPosition: 'start' | 'end' = 'end';\n\n\t/**\n\t * The host element\n\t */\n\t@Element() private _el: HTMLElement;\n\n\tprivate _generateTimeout: NodeJS.Timer;\n\tprivate _resizeObserver: ResizeObserver;\n\n\tprivate _generateStepsOnce = () => {\n\t\tif (this._generateTimeout) {\n\t\t\tclearTimeout(this._generateTimeout);\n\t\t\tthis._generateTimeout = null;\n\t\t}\n\n\t\tthis._generateTimeout = setTimeout(() => this._generateSteps(), 50);\n\t};\n\n\tprivate _generateSteps = async () => {\n\t\tif (!this._el) {\n\t\t\treturn;\n\t\t}\n\n\t\tlet activeStep = this.activeStep - 1 || 0;\n\t\tconst items = this._el.querySelectorAll('p-stepper-item');\n\n\t\tlet directionChanged = false;\n\t\tfor (let i = 0; i < items?.length; i++) {\n\t\t\tconst item = items.item(i) as any;\n\n\t\t\tif (this.enableAutoStatus) {\n\t\t\t\titem.active = i === activeStep;\n\t\t\t\titem.finished = i < activeStep;\n\t\t\t}\n\n\t\t\tif (!this.activeStep || activeStep < 0) {\n\t\t\t\tif (item.active) {\n\t\t\t\t\tactiveStep = i;\n\t\t\t\t}\n\n\t\t\t\tif (activeStep < 0 && item.finished) {\n\t\t\t\t\tactiveStep = i + 1;\n\t\t\t\t}\n\t\t\t}\n\n\t\t\tif (item.direction !== this.direction && !directionChanged) {\n\t\t\t\tdirectionChanged = true;\n\t\t\t}\n\n\t\t\titem.direction = this.direction;\n\t\t\titem.align =\n\t\t\t\tthis.direction === 'vertical'\n\t\t\t\t\t? 'start'\n\t\t\t\t\t: i === 0\n\t\t\t\t\t? 'start'\n\t\t\t\t\t: i === items?.length - 1\n\t\t\t\t\t? 'end'\n\t\t\t\t\t: 'center';\n\t\t\titem.contentPosition = this.contentPosition;\n\t\t}\n\n\t\tif (directionChanged) {\n\t\t\t// super hacky way to ensure all elements that have a direction changed are re-rendered\n\t\t\tawait new Promise(resolve => setTimeout(resolve, 200));\n\t\t}\n\n\t\tfor (let i = 0; i < items?.length; i++) {\n\t\t\tconst item = items.item(i) as any;\n\n\t\t\tif (i < items.length - 1) {\n\t\t\t\tlet nextItem = item.nextElementSibling;\n\n\t\t\t\tif (nextItem && nextItem.tagName.toLowerCase() === 'p-stepper-item') {\n\t\t\t\t\tconst stepperLine = document.createElement('p-stepper-line');\n\t\t\t\t\tthis._el.insertBefore(stepperLine, nextItem);\n\t\t\t\t\tthis._setStepperLineData(stepperLine, item, nextItem, i, activeStep);\n\n\t\t\t\t\tconst previous = stepperLine.previousElementSibling;\n\t\t\t\t\tif (previous && previous.tagName.toLowerCase() === 'p-stepper-line') {\n\t\t\t\t\t\tprevious.remove();\n\t\t\t\t\t}\n\n\t\t\t\t\tcontinue;\n\t\t\t\t}\n\n\t\t\t\tif (nextItem && nextItem.tagName.toLowerCase() === 'p-stepper-line') {\n\t\t\t\t\tconst stepperLine = nextItem;\n\t\t\t\t\tnextItem = nextItem.nextElementSibling;\n\n\t\t\t\t\tif (nextItem && nextItem.tagName.toLowerCase() === 'p-stepper-item') {\n\t\t\t\t\t\tthis._setStepperLineData(\n\t\t\t\t\t\t\tstepperLine,\n\t\t\t\t\t\t\titem,\n\t\t\t\t\t\t\tnextItem,\n\t\t\t\t\t\t\ti,\n\t\t\t\t\t\t\tactiveStep\n\t\t\t\t\t\t);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\n\t\t\tif (i > 0) {\n\t\t\t\tconst previousItem = item.previousElementSibling;\n\t\t\t\tif (\n\t\t\t\t\tpreviousItem &&\n\t\t\t\t\tpreviousItem.tagName.toLowerCase() === 'p-stepper-line'\n\t\t\t\t) {\n\t\t\t\t\tpreviousItem.direction = this.direction;\n\t\t\t\t\tpreviousItem.active = item.active || item.finished;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\tconst lines = this._el.querySelectorAll(\n\t\t\t'p-stepper-line:not(:has(+ p-stepper-item)), p-stepper-line:first-child'\n\t\t);\n\t\tfor (let j = lines.length - 1; j >= 0; j--) {\n\t\t\tconst line = lines.item(j);\n\t\t\tline.remove();\n\t\t}\n\t};\n\n\tprivate _setStepperLineData = (\n\t\tstepperLine: HTMLPStepperLineElement,\n\t\titem: HTMLPStepperItemElement,\n\t\tnextItem: HTMLPStepperItemElement,\n\t\ti: number,\n\t\tactiveStep: number\n\t) => {\n\t\tconst heightDiff = item.clientHeight / 2;\n\t\tconst heightDiffNext = nextItem.clientHeight / 2;\n\n\t\tstepperLine.direction = this.direction;\n\t\tstepperLine.active = i < activeStep;\n\n\t\tif (heightDiff > 0 && this.direction === 'vertical') {\n\t\t\tstepperLine.style.marginTop = `-${heightDiff / 16}rem`;\n\t\t\tstepperLine.style.marginBottom = `-${heightDiffNext / 16}rem`;\n\t\t\tstepperLine.style.minHeight = `calc(1rem + ${\n\t\t\t\t(heightDiff + heightDiffNext) / 16\n\t\t\t}rem)`;\n\t\t}\n\t};\n\n\tcomponentDidLoad() {\n\t\tthis._resizeObserver = new ResizeObserver(() => this._generateStepsOnce());\n\t\tthis._resizeObserver.observe(this._el);\n\t}\n\n\tdisconnectCallback() {\n\t\tif (this._resizeObserver) {\n\t\t\tthis._resizeObserver.disconnect();\n\t\t}\n\t}\n\n\trender() {\n\t\treturn (\n\t\t\t<Host class='p-stepper'>\n\t\t\t\t<slot onSlotchange={() => this._generateStepsOnce()} />\n\t\t\t</Host>\n\t\t);\n\t}\n\n\t@Watch('activeStep')\n\tprotected _onActiveStepChange() {\n\t\tthis._gener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