@paperless/core 2.0.1-beta.72 → 2.0.1-beta.73
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 +11 -0
- package/dist/build/p-41303d86.entry.js +2 -0
- package/dist/build/p-41303d86.entry.js.map +1 -0
- package/dist/build/p-4e704926.entry.js +2 -0
- package/dist/build/{p-b9525461.entry.js → p-5769eaeb.entry.js} +2 -2
- package/dist/build/{p-23ee29e7.entry.js → p-76edae0b.entry.js} +2 -2
- package/dist/build/{p-d8c4125f.entry.js → p-7ad4fe38.entry.js} +2 -2
- package/dist/build/{p-2a6df4f0.js → p-7f321fa0.js} +1 -1
- package/dist/build/p-8a7d3603.entry.js +2 -0
- package/dist/build/p-8a7d3603.entry.js.map +1 -0
- package/dist/build/p-8b79f2f7.entry.js +2 -0
- package/dist/build/p-8b79f2f7.entry.js.map +1 -0
- package/dist/build/{p-cc2810cc.entry.js → p-97c2bdd1.entry.js} +2 -2
- package/dist/build/{p-363b6f28.entry.js → p-9a4ba6b1.entry.js} +2 -2
- package/dist/build/p-checkbox.p-dropdown.p-dropdown-menu-container.p-dropdown-menu-item.entry.esm.js.map +1 -1
- package/dist/build/p-navbar.entry.esm.js.map +1 -1
- package/dist/build/p-profile.entry.esm.js.map +1 -1
- package/dist/build/paperless.esm.js +1 -1
- package/dist/cjs/loader.cjs.js +1 -1
- package/dist/cjs/p-checkbox.p-dropdown.p-dropdown-menu-container.p-dropdown-menu-item.entry.cjs.js.map +1 -1
- package/dist/cjs/p-checkbox_4.cjs.entry.js +1 -1
- package/dist/cjs/p-checkbox_4.cjs.entry.js.map +1 -1
- package/dist/cjs/p-empty-state_9.cjs.entry.js +2 -2
- package/dist/cjs/p-field_2.cjs.entry.js +3 -3
- package/dist/cjs/p-label.cjs.entry.js +3 -3
- package/dist/cjs/p-navbar.cjs.entry.js +1 -1
- package/dist/cjs/p-navbar.cjs.entry.js.map +1 -1
- package/dist/cjs/p-navbar.entry.cjs.js.map +1 -1
- package/dist/cjs/p-navigation-item.cjs.entry.js +2 -2
- package/dist/cjs/p-navigation-section.cjs.entry.js +1 -1
- package/dist/cjs/p-pagination_3.cjs.entry.js +4 -4
- package/dist/cjs/p-profile.cjs.entry.js +3 -3
- package/dist/cjs/p-profile.cjs.entry.js.map +1 -1
- package/dist/cjs/p-profile.entry.cjs.js.map +1 -1
- package/dist/cjs/paperless.cjs.js +1 -1
- package/dist/collection/components/molecules/dropdown/dropdown.component.js +1 -1
- package/dist/collection/components/molecules/dropdown/dropdown.component.js.map +1 -1
- package/dist/collection/components/molecules/empty-state/empty-state.component.js +2 -2
- package/dist/collection/components/molecules/field/field/field.component.js +3 -3
- package/dist/collection/components/molecules/label/label.component.js +3 -3
- package/dist/collection/components/molecules/navigation/item/navigation-item.component.js +2 -2
- package/dist/collection/components/molecules/navigation/section/navigation-section.component.js +1 -1
- package/dist/collection/components/molecules/pagination/pages/pagination-pages.component.js +1 -1
- package/dist/collection/components/molecules/pagination/pagination/pagination.component.js +3 -3
- package/dist/collection/components/molecules/profile/profile.component.css +1 -1
- package/dist/collection/components/molecules/profile/profile.component.js +4 -3
- package/dist/collection/components/molecules/profile/profile.component.js.map +1 -1
- package/dist/collection/components/organisms/navbar/navbar.component.js +2 -2
- package/dist/collection/components/organisms/navbar/navbar.component.js.map +1 -1
- package/dist/components/{p-wDNpAyi8.js → p-B2HQAHKa.js} +8 -8
- package/dist/components/{p-wDNpAyi8.js.map → p-B2HQAHKa.js.map} +1 -1
- package/dist/components/{p-CXOTEz6R.js → p-BL_3kED9.js} +4 -4
- package/dist/components/{p-CXOTEz6R.js.map → p-BL_3kED9.js.map} +1 -1
- package/dist/components/{p-RvvUXTPS.js → p-BfNx0tEt.js} +6 -6
- package/dist/components/{p-RvvUXTPS.js.map → p-BfNx0tEt.js.map} +1 -1
- package/dist/components/{p-C3qeuLGS.js → p-Bq6M4UX0.js} +3 -3
- package/dist/components/p-Bq6M4UX0.js.map +1 -0
- package/dist/components/{p-Bfsfjrch.js → p-BvpAM_Rb.js} +3 -3
- package/dist/components/{p-Bfsfjrch.js.map → p-BvpAM_Rb.js.map} +1 -1
- package/dist/components/{p-CB3gv9g7.js → p-CyabiQlx.js} +5 -5
- package/dist/components/{p-CB3gv9g7.js.map → p-CyabiQlx.js.map} +1 -1
- package/dist/components/{p-CW-Ucnco.js → p-DGQEB1OR.js} +3 -3
- package/dist/components/{p-CW-Ucnco.js.map → p-DGQEB1OR.js.map} +1 -1
- package/dist/components/{p-Cq1x_PEa.js → p-DzjemSiz.js} +3 -3
- package/dist/components/{p-Cq1x_PEa.js.map → p-DzjemSiz.js.map} +1 -1
- package/dist/components/p-datepicker.js +2 -2
- package/dist/components/p-dropdown.js +1 -1
- package/dist/components/p-empty-state.js +1 -1
- package/dist/components/p-field.js +1 -1
- package/dist/components/p-label.js +3 -3
- package/dist/components/p-navbar.js +2 -2
- package/dist/components/p-navbar.js.map +1 -1
- package/dist/components/p-navigation-item.js +2 -2
- package/dist/components/p-navigation-section.js +1 -1
- package/dist/components/p-pagination-pages.js +1 -1
- package/dist/components/p-pagination-size.js +1 -1
- package/dist/components/p-pagination.js +1 -1
- package/dist/components/p-profile.js +7 -6
- package/dist/components/p-profile.js.map +1 -1
- package/dist/components/p-select.js +2 -2
- package/dist/components/p-table-footer.js +1 -1
- package/dist/components/p-table-header.js +1 -1
- package/dist/components/p-table.js +8 -8
- package/dist/esm/loader.js +1 -1
- package/dist/esm/p-checkbox.p-dropdown.p-dropdown-menu-container.p-dropdown-menu-item.entry.js.map +1 -1
- package/dist/esm/p-checkbox_4.entry.js +1 -1
- package/dist/esm/p-checkbox_4.entry.js.map +1 -1
- package/dist/esm/p-empty-state_9.entry.js +2 -2
- package/dist/esm/p-field_2.entry.js +3 -3
- package/dist/esm/p-label.entry.js +3 -3
- package/dist/esm/p-navbar.entry.js +2 -2
- package/dist/esm/p-navbar.entry.js.map +1 -1
- package/dist/esm/p-navigation-item.entry.js +2 -2
- package/dist/esm/p-navigation-section.entry.js +1 -1
- package/dist/esm/p-pagination_3.entry.js +4 -4
- package/dist/esm/p-profile.entry.js +4 -4
- package/dist/esm/p-profile.entry.js.map +1 -1
- package/dist/esm/paperless.js +1 -1
- package/dist/index.html +1 -1
- package/dist/paperless/p-41303d86.entry.js +2 -0
- package/dist/paperless/p-41303d86.entry.js.map +1 -0
- package/dist/paperless/p-4e704926.entry.js +2 -0
- package/dist/paperless/{p-b9525461.entry.js → p-5769eaeb.entry.js} +2 -2
- package/dist/paperless/{p-23ee29e7.entry.js → p-76edae0b.entry.js} +2 -2
- package/dist/paperless/{p-d8c4125f.entry.js → p-7ad4fe38.entry.js} +2 -2
- package/dist/paperless/p-8a7d3603.entry.js +2 -0
- package/dist/paperless/p-8a7d3603.entry.js.map +1 -0
- package/dist/paperless/p-8b79f2f7.entry.js +2 -0
- package/dist/paperless/p-8b79f2f7.entry.js.map +1 -0
- package/dist/paperless/{p-cc2810cc.entry.js → p-97c2bdd1.entry.js} +2 -2
- package/dist/paperless/{p-363b6f28.entry.js → p-9a4ba6b1.entry.js} +2 -2
- package/dist/paperless/p-checkbox.p-dropdown.p-dropdown-menu-container.p-dropdown-menu-item.entry.esm.js.map +1 -1
- package/dist/paperless/p-navbar.entry.esm.js.map +1 -1
- package/dist/paperless/p-profile.entry.esm.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/package.json +1 -1
- package/dist/build/p-300a71f2.entry.js +0 -2
- package/dist/build/p-300a71f2.entry.js.map +0 -1
- package/dist/build/p-6be7dc53.entry.js +0 -2
- package/dist/build/p-6be7dc53.entry.js.map +0 -1
- package/dist/build/p-856d3eb4.entry.js +0 -2
- package/dist/build/p-d17fc631.entry.js +0 -2
- package/dist/build/p-d17fc631.entry.js.map +0 -1
- package/dist/components/p-C3qeuLGS.js.map +0 -1
- package/dist/paperless/p-300a71f2.entry.js +0 -2
- package/dist/paperless/p-300a71f2.entry.js.map +0 -1
- package/dist/paperless/p-6be7dc53.entry.js +0 -2
- package/dist/paperless/p-6be7dc53.entry.js.map +0 -1
- package/dist/paperless/p-856d3eb4.entry.js +0 -2
- package/dist/paperless/p-d17fc631.entry.js +0 -2
- package/dist/paperless/p-d17fc631.entry.js.map +0 -1
- /package/dist/build/{p-856d3eb4.entry.js.map → p-4e704926.entry.js.map} +0 -0
- /package/dist/build/{p-b9525461.entry.js.map → p-5769eaeb.entry.js.map} +0 -0
- /package/dist/build/{p-23ee29e7.entry.js.map → p-76edae0b.entry.js.map} +0 -0
- /package/dist/build/{p-d8c4125f.entry.js.map → p-7ad4fe38.entry.js.map} +0 -0
- /package/dist/build/{p-cc2810cc.entry.js.map → p-97c2bdd1.entry.js.map} +0 -0
- /package/dist/build/{p-363b6f28.entry.js.map → p-9a4ba6b1.entry.js.map} +0 -0
- /package/dist/paperless/{p-856d3eb4.entry.js.map → p-4e704926.entry.js.map} +0 -0
- /package/dist/paperless/{p-b9525461.entry.js.map → p-5769eaeb.entry.js.map} +0 -0
- /package/dist/paperless/{p-23ee29e7.entry.js.map → p-76edae0b.entry.js.map} +0 -0
- /package/dist/paperless/{p-d8c4125f.entry.js.map → p-7ad4fe38.entry.js.map} +0 -0
- /package/dist/paperless/{p-cc2810cc.entry.js.map → p-97c2bdd1.entry.js.map} +0 -0
- /package/dist/paperless/{p-363b6f28.entry.js.map → p-9a4ba6b1.entry.js.map} +0 -0
|
@@ -66,10 +66,10 @@ export class NavigationItem {
|
|
|
66
66
|
render() {
|
|
67
67
|
const TagType = this.as;
|
|
68
68
|
const active = asBoolean(this.active) || this.class?.includes('active');
|
|
69
|
-
return (h(Host, { key: '
|
|
69
|
+
return (h(Host, { key: 'a87f509578f0ce6740dd69fc69e0fa04ed0ee2b2', class: cn('p-navigation-item inline-block', this.class) }, h(TagType, { key: '4609e8924e72646b9802e869c50c80e47a78ac30', class: navigationItem({
|
|
70
70
|
icon: !!this.icon,
|
|
71
71
|
active,
|
|
72
|
-
}), href: this.href, target: this.target }, h("div", { key: '
|
|
72
|
+
}), href: this.href, target: this.target }, h("div", { key: '468f0196ea467f1dd47b3afc56abff04b76036da', class: navigationItemIconContainer({ active }) }, h("p-icon", { key: 'a868bd9dda5e0b2f45a5519a0b91b00c7fb69411', variant: this.icon })), h("span", { key: '6de006baa0a070f31f1c3dae2a12c13a45161df3', class: this.counter && 'has-counter' }, h("slot", { key: 'cb79f483fe8571267edc88b0d5ba3714b058ab69' })), !!this.counter && this.counter !== '0' && (h("p-badge", { key: '7984ff9391669ab92375d11756dc320a099ac412' }, this.counter)), !!this.loading && h("p-loader", { key: '7f9b7682218b062de8cafd6999c3d4739cdebd28', class: 'ml-auto' }))));
|
|
73
73
|
}
|
|
74
74
|
static get is() { return "p-navigation-item"; }
|
|
75
75
|
static get originalStyleUrls() {
|
package/dist/collection/components/molecules/navigation/section/navigation-section.component.js
CHANGED
|
@@ -5,7 +5,7 @@ export class NavigationSection {
|
|
|
5
5
|
*/
|
|
6
6
|
header;
|
|
7
7
|
render() {
|
|
8
|
-
return (h(Host, { key: '
|
|
8
|
+
return (h(Host, { key: '656b8844f21a7487d1988f82ef95e6f7f8071b6f', class: 'p-navigation-section flex flex-col gap-2' }, this.header?.length > 0 && (h("p-navigation-title", { key: '13774787edcc7fb4056c2b6b8780827407535dd0' }, this.header)), h("div", { key: 'b9a92a246a30ce332c6a754136cfcd2ab3f74a9a', class: 'flex flex-col' }, h("slot", { key: '090c9b6453469778bce1291541f326edac343fe9' }))));
|
|
9
9
|
}
|
|
10
10
|
static get is() { return "p-navigation-section"; }
|
|
11
11
|
static get originalStyleUrls() {
|
|
@@ -39,7 +39,7 @@ export class PaginationPages {
|
|
|
39
39
|
this._generate();
|
|
40
40
|
}
|
|
41
41
|
render() {
|
|
42
|
-
return (h(Host, { key: '
|
|
42
|
+
return (h(Host, { key: '9dbf378a056ba7c98020eda9c4912a38fa8ecd83', class: pagination({
|
|
43
43
|
hidden: this.hideOnSinglePage && this._set?.length === 3,
|
|
44
44
|
}) }, this._set?.map(p => {
|
|
45
45
|
if (p.type === 'previous' || p.type === 'next') {
|
|
@@ -59,12 +59,12 @@ export class Pagination {
|
|
|
59
59
|
_hasPaginationPages = true;
|
|
60
60
|
render() {
|
|
61
61
|
const hidePageSizeSelect = this.hideOnSinglePage && this.total <= this.pageSizeOptions?.[0];
|
|
62
|
-
return (h(Host, { key: '
|
|
62
|
+
return (h(Host, { key: 'df2e82052e56c0f9a2c9aa23db40f926df4fbcfa', class: pagination({
|
|
63
63
|
hidden: (hidePageSizeSelect && !this._hasPaginationPages) ||
|
|
64
64
|
(!this.enablePaginationSize && !this.enablePaginationPages),
|
|
65
|
-
}) }, this.enablePaginationPages && this.enablePaginationSize && (h(Fragment, { key: '
|
|
65
|
+
}) }, this.enablePaginationPages && this.enablePaginationSize && (h(Fragment, { key: '07192ba2aea4cd48faf713cb0975f17ffe46c352' }, h("p-pagination-size", { key: '6feff9779763f7956151f36b558c1a9757387886', hidden: hidePageSizeSelect, size: this.pageSize, sizeOptions: this.pageSizeOptions, onSizeChange: ({ detail }) => this._changePageSize(detail) }), !hidePageSizeSelect &&
|
|
66
66
|
this.hideOnSinglePage &&
|
|
67
|
-
this._hasPaginationPages && (h("p-divider", { key: '
|
|
67
|
+
this._hasPaginationPages && (h("p-divider", { key: 'aaca41f9cfcf58b45034a6b0a090b9e4905d605a', variant: 'vertical', class: 'mx-0 h-4 text-human-beige-700' })))), this.enablePaginationPages && (h("p-pagination-pages", { key: 'ef81d4beec0e7d01b9e41898bb8e14a5a1ea6d7d', pageSize: this.pageSize, total: this.total, page: this.page, hideOnSinglePage: this.hideOnSinglePage, onPageChange: ({ detail }) => this.pageChange.emit(detail), onPagesChange: ({ detail }) => {
|
|
68
68
|
this._hasPaginationPages = detail > 1;
|
|
69
69
|
this.pagesChange.emit(detail);
|
|
70
70
|
} }))));
|
|
@@ -1 +1 @@
|
|
|
1
|
-
*{box-sizing:border-box}.static{position:static!important}.absolute{position:absolute!important}.
|
|
1
|
+
*{box-sizing:border-box}.static{position:static!important}.absolute{position:absolute!important}.my-0{margin-bottom:0!important;margin-top:0!important}.flex{display:flex!important}.h-10{height:2.5rem!important}.w-auto{width:auto!important}.w-full{width:100%!important}.min-w-0{min-width:0!important}.max-w-full{max-width:100%!important}.flex-1{flex:1 1 0%!important}.flex-col{flex-direction:column!important}.items-start{align-items:flex-start!important}.items-center{align-items:center!important}.gap-2{gap:.5rem!important}.overflow-hidden{overflow:hidden!important}.text-ellipsis{text-overflow:ellipsis!important}.whitespace-nowrap{white-space:nowrap!important}.py-1{padding-bottom:.25rem!important;padding-top:.25rem!important}.text-sm{font-size:.875rem!important;line-height:1.25rem!important}.text-xs{font-size:.75rem!important;line-height:1rem!important}.font-medium{font-weight:500!important}.text-black-teal-300{--tw-text-opacity:1!important;color:rgb(104 127 124/var(--tw-text-opacity,1))!important}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { h
|
|
1
|
+
import { h } from "@stencil/core";
|
|
2
2
|
import { cva } from "class-variance-authority";
|
|
3
3
|
const profileContent = cva(['flex gap-2 items-center flex-1 min-w-0'], {
|
|
4
4
|
variants: {
|
|
@@ -27,7 +27,7 @@ export class Profile {
|
|
|
27
27
|
}
|
|
28
28
|
render() {
|
|
29
29
|
const content = this._getContent();
|
|
30
|
-
return
|
|
30
|
+
return this._hasDropdownSlot ? (h("p-dropdown", { strategy: 'absolute', placement: this.dropdownLocation, applyFullWidth: true, applyMaxWidth: false, onIsOpen: ev => (this._dropdownOpen = ev.detail) }, h("p-button", { variant: 'dropdown', chevron: this._dropdownOpen ? 'up' : 'down', active: this._dropdownOpen, slot: 'trigger', size: 'lg', class: 'w-full' }, content), h("div", { slot: 'items' }, h("slot", { name: 'dropdown', onSlotchange: () => this._checkDropdownSlot() })))) : (content);
|
|
31
31
|
}
|
|
32
32
|
slotchange() {
|
|
33
33
|
this._checkDropdownSlot();
|
|
@@ -41,7 +41,7 @@ export class Profile {
|
|
|
41
41
|
_getContent() {
|
|
42
42
|
return (h("div", { class: profileContent({
|
|
43
43
|
dropdown: this._hasDropdownSlot,
|
|
44
|
-
}) }, h("slot", { name: 'avatar' }), h("div", { class: 'flex min-w-0 flex-1 flex-col items-start' }, h("p", { class: 'w-auto max-w-full overflow-hidden text-ellipsis whitespace-nowrap text-sm font-medium' }, h("slot", { name: 'title' })), h("p", { class: 'w-auto max-w-full overflow-hidden text-ellipsis whitespace-nowrap text-xs text-black-teal-300' }, h("slot", { name: 'subtitle' }))), h("slot", { name: 'post-title' })));
|
|
44
|
+
}) }, h("slot", { name: 'avatar' }), h("div", { class: 'flex min-w-0 flex-1 flex-col items-start' }, h("p", { class: 'my-0 w-auto max-w-full overflow-hidden text-ellipsis whitespace-nowrap text-sm font-medium' }, h("slot", { name: 'title' })), h("p", { class: 'my-0 w-auto max-w-full overflow-hidden text-ellipsis whitespace-nowrap text-xs text-black-teal-300' }, h("slot", { name: 'subtitle' }))), h("slot", { name: 'post-title' })));
|
|
45
45
|
}
|
|
46
46
|
_updateAvatar() {
|
|
47
47
|
const avatar = this._el.querySelector('p-avatar[slot="avatar"]');
|
|
@@ -51,6 +51,7 @@ export class Profile {
|
|
|
51
51
|
avatar.size = this._hasDropdownSlot ? 'sm' : avatar.size;
|
|
52
52
|
}
|
|
53
53
|
static get is() { return "p-profile"; }
|
|
54
|
+
static get encapsulation() { return "shadow"; }
|
|
54
55
|
static get originalStyleUrls() {
|
|
55
56
|
return {
|
|
56
57
|
"$": ["profile.component.css"]
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"profile.component.js","sourceRoot":"","sources":["../../../../src/components/molecules/profile/profile.component.tsx"],"names":[],"mappings":"AAAA,OAAO,
|
|
1
|
+
{"version":3,"file":"profile.component.js","sourceRoot":"","sources":["../../../../src/components/molecules/profile/profile.component.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,OAAO,EAAE,CAAC,EAAE,MAAM,EAAE,IAAI,EAAE,KAAK,E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AAE,GAC5C,CACG,CACM,CACb,CAAC,CAAC,CAAC,CACH,OAAO,CACP,CAAC;IACH,CAAC;IAGD,UAAU;QACT,IAAI,CAAC,kBAAkB,EAAE,CAAC;IAC3B,CAAC;IAEO,kBAAkB;QACzB,IAAI,CAAC,gBAAgB,GAAG,CAAC,CAAC,IAAI,CAAC,GAAG,CAAC,aAAa,CAC/C,4BAA4B,CAC5B,CAAC;QAEF,IAAI,CAAC,IAAI,CAAC,gBAAgB,IAAI,IAAI,CAAC,aAAa,EAAE,CAAC;YAClD,IAAI,CAAC,aAAa,GAAG,KAAK,CAAC;QAC5B,CAAC;IACF,CAAC;IAEO,WAAW;QAClB,OAAO,CACN,WACC,KAAK,EAAE,cAAc,CAAC;gBACrB,QAAQ,EAAE,IAAI,CAAC,gBAAgB;aAC/B,CAAC;YAEF,YAAM,IAAI,EAAC,QAAQ,GAAG;YACtB,WAAK,KAAK,EAAC,0CAA0C;gBACpD,SAAG,KAAK,EAAC,4FAA4F;oBACpG,YAAM,IAAI,EAAC,OAAO,GAAG,CAClB;gBACJ,SAAG,KAAK,EAAC,oGAAoG;oBAC5G,YAAM,IAAI,EAAC,UAAU,GAAG,CACrB,CACC;YAEN,YAAM,IAAI,EAAC,YAAY,GAAG,CACrB,CACN,CAAC;IACH,CAAC;IAEO,aAAa;QACpB,MAAM,MAAM,GAAG,IAAI,CAAC,GAAG,CAAC,aAAa,CACpC,yBAAyB,CACH,CAAC;QAExB,IAAI,CAAC,MAAM,EAAE,CAAC;YACb,OAAO;QACR,CAAC;QAED,MAAM,CAAC,IAAI,GAAG,IAAI,CAAC,gBAAgB,CAAC,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC,MAAM,CAAC,IAAI,CAAC;IAC1D,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CACD","sourcesContent":["import { Component, Element, h, Listen, Prop, State } from '@stencil/core';\nimport { cva } from 'class-variance-authority';\n\nconst profileContent = cva(['flex gap-2 items-center flex-1 min-w-0'], {\n\tvariants: {\n\t\tdropdown: {\n\t\t\tfalse: 'h-10 py-1',\n\t\t\ttrue: null,\n\t\t},\n\t},\n});\n\n@Component({\n\ttag: 'p-profile',\n\tstyleUrl: 'profile.component.css',\n\tshadow: true,\n})\nexport class Profile {\n\t/**\n\t * The position of the dropdown\n\t */\n\t@Prop() dropdownLocation: 'top-end' | 'bottom-end' = 'bottom-end';\n\n\t/**\n\t * The host element\n\t */\n\t@Element() private _el: HTMLElement;\n\n\t@State() private _dropdownOpen = false;\n\t@State() private _hasDropdownSlot = false;\n\n\tcomponentWillLoad() {\n\t\tthis._checkDropdownSlot();\n\t}\n\n\tcomponentWillRender() {\n\t\tthis._updateAvatar();\n\t}\n\n\trender() {\n\t\tconst content = this._getContent();\n\n\t\treturn this._hasDropdownSlot ? (\n\t\t\t<p-dropdown\n\t\t\t\tstrategy='absolute'\n\t\t\t\tplacement={this.dropdownLocation}\n\t\t\t\tapplyFullWidth={true}\n\t\t\t\tapplyMaxWidth={false}\n\t\t\t\tonIsOpen={ev => (this._dropdownOpen = ev.detail)}\n\t\t\t>\n\t\t\t\t<p-button\n\t\t\t\t\tvariant='dropdown'\n\t\t\t\t\tchevron={this._dropdownOpen ? 'up' : 'down'}\n\t\t\t\t\tactive={this._dropdownOpen}\n\t\t\t\t\tslot='trigger'\n\t\t\t\t\tsize='lg'\n\t\t\t\t\tclass='w-full'\n\t\t\t\t>\n\t\t\t\t\t{content}\n\t\t\t\t</p-button>\n\t\t\t\t<div slot='items'>\n\t\t\t\t\t<slot\n\t\t\t\t\t\tname='dropdown'\n\t\t\t\t\t\tonSlotchange={() => this._checkDropdownSlot()}\n\t\t\t\t\t/>\n\t\t\t\t</div>\n\t\t\t</p-dropdown>\n\t\t) : (\n\t\t\tcontent\n\t\t);\n\t}\n\n\t@Listen('slotchange')\n\tslotchange() {\n\t\tthis._checkDropdownSlot();\n\t}\n\n\tprivate _checkDropdownSlot() {\n\t\tthis._hasDropdownSlot = !!this._el.querySelector(\n\t\t\t':scope > [slot=\"dropdown\"]'\n\t\t);\n\n\t\tif (!this._hasDropdownSlot && this._dropdownOpen) {\n\t\t\tthis._dropdownOpen = false;\n\t\t}\n\t}\n\n\tprivate _getContent() {\n\t\treturn (\n\t\t\t<div\n\t\t\t\tclass={profileContent({\n\t\t\t\t\tdropdown: this._hasDropdownSlot,\n\t\t\t\t})}\n\t\t\t>\n\t\t\t\t<slot name='avatar' />\n\t\t\t\t<div class='flex min-w-0 flex-1 flex-col items-start'>\n\t\t\t\t\t<p class='my-0 w-auto max-w-full overflow-hidden text-ellipsis whitespace-nowrap text-sm font-medium'>\n\t\t\t\t\t\t<slot name='title' />\n\t\t\t\t\t</p>\n\t\t\t\t\t<p class='my-0 w-auto max-w-full overflow-hidden text-ellipsis whitespace-nowrap text-xs text-black-teal-300'>\n\t\t\t\t\t\t<slot name='subtitle' />\n\t\t\t\t\t</p>\n\t\t\t\t</div>\n\n\t\t\t\t<slot name='post-title' />\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.size = this._hasDropdownSlot ? 'sm' : avatar.size;\n\t}\n}\n"]}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { h
|
|
1
|
+
import { h } from "@stencil/core";
|
|
2
2
|
import { cva } from "class-variance-authority";
|
|
3
3
|
const sidebarAndTopbar = cva([
|
|
4
4
|
'bg-off-white-300',
|
|
@@ -42,7 +42,7 @@ const backdrop = cva(['z-navbar-backdrop layout-1280:hidden transition-opacity']
|
|
|
42
42
|
export class Navbar {
|
|
43
43
|
_show = false;
|
|
44
44
|
render() {
|
|
45
|
-
return (h(
|
|
45
|
+
return (h("div", { key: '50afdeebec1458d202aaf3d840380dd8d5ece79c', class: 'p-navbar w-full max-h-screen-safe layout-1280:w-60 layout-1680:w-72' }, h("p-backdrop", { key: 'ecb8da8f0fd029896524ae7925cad79c2dad6b49', class: backdrop({ show: this._show }), scrollLock: this._show, onClicked: () => (this._show = false) }), h("div", { key: '7e48b33f2f19d910f47a5d8045ca586dd762541f', class: sidebar({ class: sidebarAndTopbar(), show: this._show }) }, h("div", { key: '3c11005b9d1af8a8ac0d499e43cd47d54e4091e8', class: 'flex w-full items-center justify-between layout-1280:hidden' }, h("p-button", { key: '66daa754b1cf2da6258e7c88bb78e5b2ce645163', variant: 'secondary', icon: 'menu-arrow', iconFlip: 'horizontal', iconOnly: true, size: 'sm', onClick: () => (this._show = false) })), h("div", { key: 'ed687e067f4e492ccf2545853fd0846625d12039', class: 'flex w-full flex-col items-stretch' }, h("slot", { key: '8f55a6ee6c7155d0f862938d70362af14797324e', name: 'company' })), h("div", { key: '4234bd832ae0e635a69b673690d9f4646cce90f3', class: 'flex w-full flex-col gap-6 overflow-y-auto' }, h("slot", { key: 'af211c0b11e2b446d0968508331dda7eb3a91c54', name: 'content' })), h("div", { key: 'cb5e220a919806af955aa4f03c61f1b5f00f126c', class: 'mt-auto hidden w-full flex-col layout-1280:flex' }, h("slot", { key: '336e7e37d8f624362e71d6b1e3ebdf4f21072295', name: 'user' }))), h("div", { key: '3f938b963c4632f69e71d565a78663e1ef83a534', class: topbar({ class: sidebarAndTopbar() }) }, h("p-button", { key: 'bad864a024548a22eb81524214007fbed3fdc288', variant: 'secondary', iconOnly: true, icon: 'menu-arrow', size: 'sm', onClick: () => (this._show = true) }), h("slot", { key: '8f6350e2efab5da123de951f30f554b4d4ac5dfa', name: 'topbar' }))));
|
|
46
46
|
}
|
|
47
47
|
handleCloseNavbar() {
|
|
48
48
|
this._show = false;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"navbar.component.js","sourceRoot":"","sources":["../../../../src/components/organisms/navbar/navbar.component.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,CAAC,EAAE,
|
|
1
|
+
{"version":3,"file":"navbar.component.js","sourceRoot":"","sources":["../../../../src/components/organisms/navbar/navbar.component.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,CAAC,EAAE,MAAM,EAAE,KAAK,EAAE,MAAM,eAAe,CAAC;AAC5D,OAAO,EAAE,GAAG,EAAE,MAAM,0BAA0B,CAAC;AAE/C,MAAM,gBAAgB,GAAG,GAAG,CAAC;IAC5B,kBAAkB;IAClB,4CAA4C;IAC5C,KAAK;CACL,CAAC,CAAC;AAEH,MAAM,OAAO,GAAG,GAAG,CAClB;IACC,eAAe;IAEf,2CAA2C;IAC3C,wBAAwB;IACxB,gFAAgF;IAChF,OAAO;IAEP,gBAAgB;IAChB,uBAAuB;IACvB,2DAA2D;IAE3D,UAAU;IAEV,cAAc;CACd,EACD;IACC,QAAQ,EAAE;QACT,IAAI,EAAE;YACL,KAAK,EAAE,IAAI;YACX,IAAI,EAAE,MAAM;SACZ;KACD;CACD,CACD,CAAC;AAEF,MAAM,MAAM,GAAG,GAAG,CAAC;IAClB,0CAA0C;IAC1C,0BAA0B;IAC1B,UAAU;IACV,oBAAoB;IACpB,aAAa;CACb,CAAC,CAAC;AAEH,MAAM,QAAQ,GAAG,GAAG,CACnB,CAAC,yDAAyD,CAAC,EAC3D;IACC,QAAQ,EAAE;QACT,IAAI,EAAE;YACL,KAAK,EAAE,+BAA+B;YACtC,IAAI,EAAE,aAAa;SACnB;KACD;CACD,CACD,CAAC;AAOF,MAAM,OAAO,MAAM;IACD,KAAK,GAAG,KAAK,CAAC;IAE/B,MAAM;QACL,OAAO,CACN,4DAAK,KAAK,EAAC,qEAAqE;YAC/E,mEACC,KAAK,EAAE,QAAQ,CAAC,EAAE,IAAI,EAAE,IAAI,CAAC,KAAK,EAAE,CAAC,EACrC,UAAU,EAAE,IAAI,CAAC,KAAK,EACtB,SAAS,EAAE,GAAG,EAAE,CAAC,CAAC,IAAI,CAAC,KAAK,GAAG,KAAK,CAAC,GACxB;YACd,4DAAK,KAAK,EAAE,OAAO,CAAC,EAAE,KAAK,EAAE,gBAAgB,EAAE,EAAE,IAAI,EAAE,IAAI,CAAC,KAAK,EAAE,CAAC;gBACnE,4DAAK,KAAK,EAAC,6DAA6D;oBACvE,iEACC,OAAO,EAAC,WAAW,EACnB,IAAI,EAAC,YAAY,EACjB,QAAQ,EAAC,YAAY,EACrB,QAAQ,EAAE,IAAI,EACd,IAAI,EAAC,IAAI,EACT,OAAO,EAAE,GAAG,EAAE,CAAC,CAAC,IAAI,CAAC,KAAK,GAAG,KAAK,CAAC,GACxB,CACP;gBACN,4DAAK,KAAK,EAAC,oCAAoC;oBAC9C,6DAAM,IAAI,EAAC,SAAS,GAAG,CAClB;gBACN,4DAAK,KAAK,EAAC,4CAA4C;oBACtD,6DAAM,IAAI,EAAC,SAAS,GAAG,CAClB;gBAEN,4DAAK,KAAK,EAAC,iDAAiD;oBAC3D,6DAAM,IAAI,EAAC,MAAM,GAAG,CACf,CACD;YACN,4DAAK,KAAK,EAAE,MAAM,CAAC,EAAE,KAAK,EAAE,gBAAgB,EAAE,EAAE,CAAC;gBAChD,iEACC,OAAO,EAAC,WAAW,EACnB,QAAQ,EAAE,IAAI,EACd,IAAI,EAAC,YAAY,EACjB,IAAI,EAAC,IAAI,EACT,OAAO,EAAE,GAAG,EAAE,CAAC,CAAC,IAAI,CAAC,KAAK,GAAG,IAAI,CAAC,GACvB;gBAEZ,6DAAM,IAAI,EAAC,QAAQ,GAAG,CACjB,CACD,CACN,CAAC;IACH,CAAC;IAGD,iBAAiB;QAChB,IAAI,CAAC,KAAK,GAAG,KAAK,CAAC;IACpB,CAAC;IAGD,gBAAgB;QACf,IAAI,CAAC,KAAK,GAAG,IAAI,CAAC;IACnB,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;CACD","sourcesContent":["import { Component, h, Listen, State } from '@stencil/core';\nimport { cva } from 'class-variance-authority';\n\nconst sidebarAndTopbar = cva([\n\t'bg-off-white-300',\n\t'border-0 border-solid border-off-white-700',\n\t'p-4',\n]);\n\nconst sidebar = cva(\n\t[\n\t\t'flex flex-col',\n\n\t\t'fixed left-0 top-0 z-navbar h-screen w-60',\n\t\t'w-full max-w-[16.5rem]',\n\t\t'layout-1280:relative layout-1280:z-0 layout-1280:max-w-none layout-1280:h-full',\n\t\t'gap-6',\n\n\t\t'transition-all',\n\t\t'will-change-transform',\n\t\t'-translate-x-full transform-gpu layout-1280:translate-x-0',\n\n\t\t'border-r',\n\n\t\t'safe-sidebar',\n\t],\n\t{\n\t\tvariants: {\n\t\t\tshow: {\n\t\t\t\tfalse: null,\n\t\t\t\ttrue: 'show',\n\t\t\t},\n\t\t},\n\t}\n);\n\nconst topbar = cva([\n\t'flex w-full justify-between items-center',\n\t'relative z-navbar-topbar',\n\t'border-b',\n\t'layout-1280:hidden',\n\t'safe-topbar',\n]);\n\nconst backdrop = cva(\n\t['z-navbar-backdrop layout-1280:hidden transition-opacity'],\n\t{\n\t\tvariants: {\n\t\t\tshow: {\n\t\t\t\tfalse: 'opacity-0 pointer-events-none',\n\t\t\t\ttrue: 'opacity-100',\n\t\t\t},\n\t\t},\n\t}\n);\n\n@Component({\n\ttag: 'p-navbar',\n\tstyleUrl: 'navbar.component.css',\n\tshadow: true,\n})\nexport class Navbar {\n\t@State() private _show = false;\n\n\trender() {\n\t\treturn (\n\t\t\t<div class='p-navbar w-full max-h-screen-safe layout-1280:w-60 layout-1680:w-72'>\n\t\t\t\t<p-backdrop\n\t\t\t\t\tclass={backdrop({ show: this._show })}\n\t\t\t\t\tscrollLock={this._show}\n\t\t\t\t\tonClicked={() => (this._show = false)}\n\t\t\t\t></p-backdrop>\n\t\t\t\t<div class={sidebar({ class: sidebarAndTopbar(), show: this._show })}>\n\t\t\t\t\t<div class='flex w-full items-center justify-between layout-1280:hidden'>\n\t\t\t\t\t\t<p-button\n\t\t\t\t\t\t\tvariant='secondary'\n\t\t\t\t\t\t\ticon='menu-arrow'\n\t\t\t\t\t\t\ticonFlip='horizontal'\n\t\t\t\t\t\t\ticonOnly={true}\n\t\t\t\t\t\t\tsize='sm'\n\t\t\t\t\t\t\tonClick={() => (this._show = false)}\n\t\t\t\t\t\t></p-button>\n\t\t\t\t\t</div>\n\t\t\t\t\t<div class='flex w-full flex-col items-stretch'>\n\t\t\t\t\t\t<slot name='company' />\n\t\t\t\t\t</div>\n\t\t\t\t\t<div class='flex w-full flex-col gap-6 overflow-y-auto'>\n\t\t\t\t\t\t<slot name='content' />\n\t\t\t\t\t</div>\n\n\t\t\t\t\t<div class='mt-auto hidden w-full flex-col layout-1280:flex'>\n\t\t\t\t\t\t<slot name='user' />\n\t\t\t\t\t</div>\n\t\t\t\t</div>\n\t\t\t\t<div class={topbar({ class: sidebarAndTopbar() })}>\n\t\t\t\t\t<p-button\n\t\t\t\t\t\tvariant='secondary'\n\t\t\t\t\t\ticonOnly={true}\n\t\t\t\t\t\ticon='menu-arrow'\n\t\t\t\t\t\tsize='sm'\n\t\t\t\t\t\tonClick={() => (this._show = true)}\n\t\t\t\t\t></p-button>\n\n\t\t\t\t\t<slot name='topbar' />\n\t\t\t\t</div>\n\t\t\t</div>\n\t\t);\n\t}\n\n\t@Listen('closeNavbar', { target: 'window' })\n\thandleCloseNavbar() {\n\t\tthis._show = false;\n\t}\n\n\t@Listen('openNavbar', { target: 'window' })\n\thandleOpenNavbar() {\n\t\tthis._show = true;\n\t}\n}\n"]}
|
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
import { p as proxyCustomElement, H, c as createEvent, h, F as Fragment, d as Host } from './p-BLaYz0fg.js';
|
|
2
|
-
import { d as defineCustomElement$2, a as defaultSize, b as defaultSizeOptions } from './p-
|
|
2
|
+
import { d as defineCustomElement$2, a as defaultSize, b as defaultSizeOptions } from './p-DGQEB1OR.js';
|
|
3
3
|
import { c as cva } from './p-4hDfHOnN.js';
|
|
4
4
|
import { d as defineCustomElement$a } from './p-BsVQWdLD.js';
|
|
5
5
|
import { d as defineCustomElement$9 } from './p-q_c1iUVr.js';
|
|
6
|
-
import { d as defineCustomElement$8 } from './p-
|
|
6
|
+
import { d as defineCustomElement$8 } from './p-Bq6M4UX0.js';
|
|
7
7
|
import { d as defineCustomElement$7 } from './p-CKjBhtCw.js';
|
|
8
8
|
import { d as defineCustomElement$6 } from './p-B63gPh_H.js';
|
|
9
9
|
import { d as defineCustomElement$5 } from './p-BsgE1XSo.js';
|
|
10
|
-
import { d as defineCustomElement$4 } from './p-
|
|
10
|
+
import { d as defineCustomElement$4 } from './p-DzjemSiz.js';
|
|
11
11
|
import { d as defineCustomElement$3 } from './p-DkQcmaID.js';
|
|
12
12
|
import { d as defineCustomElement$1 } from './p-ByT0XK4K.js';
|
|
13
13
|
|
|
@@ -78,12 +78,12 @@ const Pagination = /*@__PURE__*/ proxyCustomElement(class Pagination extends H {
|
|
|
78
78
|
_hasPaginationPages = true;
|
|
79
79
|
render() {
|
|
80
80
|
const hidePageSizeSelect = this.hideOnSinglePage && this.total <= this.pageSizeOptions?.[0];
|
|
81
|
-
return (h(Host, { key: '
|
|
81
|
+
return (h(Host, { key: 'df2e82052e56c0f9a2c9aa23db40f926df4fbcfa', class: pagination({
|
|
82
82
|
hidden: (hidePageSizeSelect && !this._hasPaginationPages) ||
|
|
83
83
|
(!this.enablePaginationSize && !this.enablePaginationPages),
|
|
84
|
-
}) }, this.enablePaginationPages && this.enablePaginationSize && (h(Fragment, { key: '
|
|
84
|
+
}) }, this.enablePaginationPages && this.enablePaginationSize && (h(Fragment, { key: '07192ba2aea4cd48faf713cb0975f17ffe46c352' }, h("p-pagination-size", { key: '6feff9779763f7956151f36b558c1a9757387886', hidden: hidePageSizeSelect, size: this.pageSize, sizeOptions: this.pageSizeOptions, onSizeChange: ({ detail }) => this._changePageSize(detail) }), !hidePageSizeSelect &&
|
|
85
85
|
this.hideOnSinglePage &&
|
|
86
|
-
this._hasPaginationPages && (h("p-divider", { key: '
|
|
86
|
+
this._hasPaginationPages && (h("p-divider", { key: 'aaca41f9cfcf58b45034a6b0a090b9e4905d605a', variant: 'vertical', class: 'mx-0 h-4 text-human-beige-700' })))), this.enablePaginationPages && (h("p-pagination-pages", { key: 'ef81d4beec0e7d01b9e41898bb8e14a5a1ea6d7d', pageSize: this.pageSize, total: this.total, page: this.page, hideOnSinglePage: this.hideOnSinglePage, onPageChange: ({ detail }) => this.pageChange.emit(detail), onPagesChange: ({ detail }) => {
|
|
87
87
|
this._hasPaginationPages = detail > 1;
|
|
88
88
|
this.pagesChange.emit(detail);
|
|
89
89
|
} }))));
|
|
@@ -172,6 +172,6 @@ function defineCustomElement() {
|
|
|
172
172
|
defineCustomElement();
|
|
173
173
|
|
|
174
174
|
export { Pagination as P, defineCustomElement as d };
|
|
175
|
-
//# sourceMappingURL=p-
|
|
175
|
+
//# sourceMappingURL=p-B2HQAHKa.js.map
|
|
176
176
|
|
|
177
|
-
//# sourceMappingURL=p-
|
|
177
|
+
//# sourceMappingURL=p-B2HQAHKa.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"file":"p-
|
|
1
|
+
{"file":"p-B2HQAHKa.js","mappings":";;;;;;;;;;;;;AAAA,MAAM,sBAAsB,GAAG,stBAAstB;;ACarvB,MAAM,UAAU,GAAG,GAAG,CACrB;IACC,cAAc;IACd,oBAAoB;IACpB,cAAc;IACd,8CAA8C;IAC9C,KAAK;CACL,EACD;AACC,IAAA,QAAQ,EAAE;AACT,QAAA,MAAM,EAAE;AACP,YAAA,KAAK,EAAE,MAAM;AACb,YAAA,IAAI,EAAE,QAAQ;AACd,SAAA;AACD,KAAA;AACD,CAAA,CACD;MAMY,UAAU,iBAAAA,kBAAA,CAAA,MAAA,UAAA,SAAAC,CAAA,CAAA;;;;;;;;AACtB;;AAEG;IACK,gBAAgB,GAAY,IAAI;AAExC;;AAEG;IACK,oBAAoB,GAAY,IAAI;AAE5C;;AAEG;IACK,qBAAqB,GAAY,IAAI;AAE7C;;AAEG;IACqC,IAAI,GAAW,CAAC;AAExD;;AAEG;AACK,IAAA,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B,KAAK,EAAE,IAAI,CAAC,KAAK,EACjB,IAAI,EAAE,IAAI,CAAC,IAAI,EACf,gBAAgB,EAAE,IAAI,CAAC,gBAAgB,EACvC,YAAY,EAAE,CAAC,EAAE,MAAM,EAAE,KAAK,IAAI,CAAC,UAAU,CAAC,IAAI,CAAC,MAAM,CAAC,EAC1D,aAAa,EAAE,CAAC,EAAE,MAAM,EAAE,KAAI;AAC7B,gBAAA,IAAI,CAAC,mBAAmB,GAAG,MAAM,GAAG,CAAC;AACrC,gBAAA,IAAI,CAAC,WAAW,CAAC,IAAI,CAAC,MAAM,CAAC;AAC9B,aAAC,EACA,CAAA,CACF,CACK;;AAID,IAAA,eAAe,CAAC,CAAU,EAAA;QACjC,IAAI,CAAC,CAAC,EAAE;YACP;;AAGD,QAAA,IAAI,CAAC,QAAQ,GAAG,CAAC;QACjB,IAAI,CAAC,cAAc,CAAC,IAAI,CAAC,IAAI,CAAC,QAAQ,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","names":["__stencil_proxyCustomElement","HTMLElement"],"sources":["src/components/molecules/pagination/pagination/pagination.component.css?tag=p-pagination","src/components/molecules/pagination/pagination/pagination.component.tsx"],"sourcesContent":["","import {\n\tComponent,\n\tEvent,\n\tEventEmitter,\n\tFragment,\n\th,\n\tHost,\n\tProp,\n\tState,\n} from '@stencil/core';\nimport { defaultSize, defaultSizeOptions } from '../size/constants';\nimport { cva } from 'class-variance-authority';\n\nconst pagination = cva(\n\t[\n\t\t'p-pagination',\n\t\t'items-center gap-2',\n\t\t'rounded-full',\n\t\t'bg-off-white-300 border border-off-white-700',\n\t\t'p-1',\n\t],\n\t{\n\t\tvariants: {\n\t\t\thidden: {\n\t\t\t\tfalse: 'flex',\n\t\t\t\ttrue: 'hidden',\n\t\t\t},\n\t\t},\n\t}\n);\n\n@Component({\n\ttag: 'p-pagination',\n\tstyleUrl: 'pagination.component.css',\n})\nexport class Pagination {\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/**\n\t * Wether to enable pagination size select\n\t */\n\t@Prop() enablePaginationSize: boolean = true;\n\n\t/**\n\t * Wether to enable pagination pages\n\t */\n\t@Prop() enablePaginationPages: 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 * 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\tpageChange: EventEmitter<number>;\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 * The pages that were generated\n\t */\n\t@Event({ bubbles: false }) pagesChange: EventEmitter<number>;\n\n\t@State() private _hasPaginationPages = true;\n\n\trender() {\n\t\tconst hidePageSizeSelect =\n\t\t\tthis.hideOnSinglePage && this.total <= this.pageSizeOptions?.[0];\n\n\t\treturn (\n\t\t\t<Host\n\t\t\t\tclass={pagination({\n\t\t\t\t\thidden:\n\t\t\t\t\t\t(hidePageSizeSelect && !this._hasPaginationPages) ||\n\t\t\t\t\t\t(!this.enablePaginationSize && !this.enablePaginationPages),\n\t\t\t\t})}\n\t\t\t>\n\t\t\t\t{this.enablePaginationPages && this.enablePaginationSize && (\n\t\t\t\t\t<Fragment>\n\t\t\t\t\t\t<p-pagination-size\n\t\t\t\t\t\t\thidden={hidePageSizeSelect}\n\t\t\t\t\t\t\tsize={this.pageSize}\n\t\t\t\t\t\t\tsizeOptions={this.pageSizeOptions}\n\t\t\t\t\t\t\tonSizeChange={({ detail }) => this._changePageSize(detail)}\n\t\t\t\t\t\t/>\n\n\t\t\t\t\t\t{!hidePageSizeSelect &&\n\t\t\t\t\t\t\tthis.hideOnSinglePage &&\n\t\t\t\t\t\t\tthis._hasPaginationPages && (\n\t\t\t\t\t\t\t\t<p-divider\n\t\t\t\t\t\t\t\t\tvariant='vertical'\n\t\t\t\t\t\t\t\t\tclass='mx-0 h-4 text-human-beige-700'\n\t\t\t\t\t\t\t\t/>\n\t\t\t\t\t\t\t)}\n\t\t\t\t\t</Fragment>\n\t\t\t\t)}\n\n\t\t\t\t{this.enablePaginationPages && (\n\t\t\t\t\t<p-pagination-pages\n\t\t\t\t\t\tpageSize={this.pageSize}\n\t\t\t\t\t\ttotal={this.total}\n\t\t\t\t\t\tpage={this.page}\n\t\t\t\t\t\thideOnSinglePage={this.hideOnSinglePage}\n\t\t\t\t\t\tonPageChange={({ detail }) => this.pageChange.emit(detail)}\n\t\t\t\t\t\tonPagesChange={({ detail }) => {\n\t\t\t\t\t\t\tthis._hasPaginationPages = detail > 1;\n\t\t\t\t\t\t\tthis.pagesChange.emit(detail);\n\t\t\t\t\t\t}}\n\t\t\t\t\t/>\n\t\t\t\t)}\n\t\t\t</Host>\n\t\t);\n\t}\n\n\tprivate _changePageSize(s?: number) {\n\t\tif (!s) {\n\t\t\treturn;\n\t\t}\n\n\t\tthis.pageSize = s;\n\t\tthis.pageSizeChange.emit(this.pageSize);\n\t}\n}\n"],"version":3}
|
|
@@ -64,11 +64,11 @@ const EmptyState = /*@__PURE__*/ proxyCustomElement(class EmptyState extends H {
|
|
|
64
64
|
const hasHeaderSlot = !!this._el.querySelector(':scope > [slot="header"]');
|
|
65
65
|
const hasContentSlot = !!this._el.querySelector(':scope > [slot="content"]');
|
|
66
66
|
const hasActionSlot = !!this._el.querySelector(':scope > [slot="action"]');
|
|
67
|
-
return (h("div", { key: '
|
|
67
|
+
return (h("div", { key: '7fe821ca2fca0d015930ceba5dee112e94d20180', class: emptyState({
|
|
68
68
|
enableAction: asBoolean(this.enableAction, true),
|
|
69
69
|
}), onClick: ev => this.enableAction && !this.actionLoading
|
|
70
70
|
? this.action.emit(ev)
|
|
71
|
-
: undefined }, this.illustration && (h("p-illustration", { key: '
|
|
71
|
+
: undefined }, this.illustration && (h("p-illustration", { key: '80d26a875e606ace0e03c351c95562998be9ba88', class: 'mb-8 text-teal', variant: this.illustration })), hasHeaderSlot ? (h("slot", { name: 'header' })) : (this.header?.length && (h("p", { class: 'my-0 text-center font-ambit text-sm font-bold text-black-teal' }, this.header))), hasContentSlot ? (h("slot", { name: 'content' })) : (this.content?.length && (h("p", { class: 'my-0 text-center text-sm text-black-teal-300' }, this.content))), this.enableAction &&
|
|
72
72
|
(hasActionSlot ? (h("slot", { name: 'action' })) : (h("p-button", { class: 'mt-4', icon: this.actionIcon, loading: this.actionLoading, variant: this.actionVariant }, this.actionText)))));
|
|
73
73
|
}
|
|
74
74
|
static get style() { return emptyStateComponentCss; }
|
|
@@ -118,6 +118,6 @@ function defineCustomElement() {
|
|
|
118
118
|
defineCustomElement();
|
|
119
119
|
|
|
120
120
|
export { EmptyState as E, defineCustomElement as d };
|
|
121
|
-
//# sourceMappingURL=p-
|
|
121
|
+
//# sourceMappingURL=p-BL_3kED9.js.map
|
|
122
122
|
|
|
123
|
-
//# sourceMappingURL=p-
|
|
123
|
+
//# sourceMappingURL=p-BL_3kED9.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"file":"p-
|
|
1
|
+
{"file":"p-BL_3kED9.js","mappings":";;;;;;;;AAAA,MAAM,sBAAsB,GAAG,g8BAAg8B;;ACgB/9B,MAAM,UAAU,GAAG,GAAG,CACrB,CAAC,+DAA+D,CAAC,EACjE;AACC,IAAA,QAAQ,EAAE;AACT,QAAA,YAAY,EAAE;AACb,YAAA,IAAI,EAAE,gBAAgB;AACtB,YAAA,KAAK,EAAE,IAAI;AACX,SAAA;AACD,KAAA;AACD,CAAA,CACD;MAOY,UAAU,iBAAAA,kBAAA,CAAA,MAAA,UAAA,SAAA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ACA,cAAc,IACd,CAAM,CAAA,MAAA,EAAA,EAAA,IAAI,EAAC,SAAS,EAAG,CAAA,KAEvB,IAAI,CAAC,OAAO,EAAE,MAAM,KACnB,SAAG,KAAK,EAAC,8CAA8C,EAAA,EACrD,IAAI,CAAC,OAAO,CACV,CACJ,CACD,EACA,IAAI,CAAC,YAAY;aAChB,aAAa,IACb,CAAM,CAAA,MAAA,EAAA,EAAA,IAAI,EAAC,QAAQ,EAAA,CAAG,KAEtB,CAAA,CAAA,UAAA,EAAA,EACC,KAAK,EAAC,MAAM,EACZ,IAAI,EAAE,IAAI,CAAC,UAAU,EACrB,OAAO,EAAE,IAAI,CAAC,aAAa,EAC3B,OAAO,EAAE,IAAI,CAAC,aAAa,EAAA,EAE1B,IAAI,CAAC,UAAU,CACN,CACX,CAAC,CACE;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","names":["__stencil_proxyCustomElement","HTMLElement"],"sources":["src/components/molecules/empty-state/empty-state.component.css?tag=p-empty-state&encapsulation=shadow","src/components/molecules/empty-state/empty-state.component.tsx"],"sourcesContent":["p-divider {\n\t--tw-content: '';\n}\n","import {\n\tComponent,\n\th,\n\tProp,\n\tEvent,\n\tEventEmitter,\n\tElement,\n} from '@stencil/core';\nimport { cva } from 'class-variance-authority';\nimport {\n\tButtonVariant,\n\tIconVariant,\n\tIllustrationVariant,\n} from '../../../components';\nimport { asBoolean } from '../../../utils/as-boolean';\n\nconst emptyState = cva(\n\t['flex flex-col w-full items-center justify-start max-w-[20rem]'],\n\t{\n\t\tvariants: {\n\t\t\tenableAction: {\n\t\t\t\ttrue: 'cursor-pointer',\n\t\t\t\tfalse: null,\n\t\t\t},\n\t\t},\n\t}\n);\n\n@Component({\n\ttag: 'p-empty-state',\n\tstyleUrl: 'empty-state.component.css',\n\tshadow: true,\n})\nexport class EmptyState {\n\t/**\n\t * The variant of the illustration\n\t */\n\t@Prop() illustration: IllustrationVariant;\n\n\t/**\n\t * The header of the empty state\n\t */\n\t@Prop() header: string;\n\n\t/**\n\t * The content of the empty state\n\t */\n\t@Prop() content: string;\n\n\t/**\n\t * Wether to enable the action button\n\t */\n\t@Prop() enableAction: boolean = true;\n\n\t/**\n\t * The text on the action button\n\t */\n\t@Prop() actionText: string;\n\n\t/**\n\t * The variant of the action\n\t */\n\t@Prop() actionVariant: ButtonVariant = 'secondary';\n\n\t/**\n\t * The icon for the action button\n\t */\n\t@Prop() actionIcon: IconVariant;\n\n\t/**\n\t * Wether the action is loading\n\t */\n\t@Prop() actionLoading: boolean = false;\n\n\t/**\n\t * The text on the action button\n\t */\n\t@Event() action: EventEmitter<MouseEvent>;\n\n\t/**\n\t * The host element\n\t */\n\t@Element() private _el: HTMLElement;\n\n\trender() {\n\t\tconst hasHeaderSlot = !!this._el.querySelector(':scope > [slot=\"header\"]');\n\t\tconst hasContentSlot = !!this._el.querySelector(\n\t\t\t':scope > [slot=\"content\"]'\n\t\t);\n\t\tconst hasActionSlot = !!this._el.querySelector(':scope > [slot=\"action\"]');\n\n\t\treturn (\n\t\t\t<div\n\t\t\t\tclass={emptyState({\n\t\t\t\t\tenableAction: asBoolean(this.enableAction, true),\n\t\t\t\t})}\n\t\t\t\tonClick={ev =>\n\t\t\t\t\tthis.enableAction && !this.actionLoading\n\t\t\t\t\t\t? this.action.emit(ev)\n\t\t\t\t\t\t: undefined\n\t\t\t\t}\n\t\t\t>\n\t\t\t\t{this.illustration && (\n\t\t\t\t\t<p-illustration\n\t\t\t\t\t\tclass='mb-8 text-teal'\n\t\t\t\t\t\tvariant={this.illustration}\n\t\t\t\t\t/>\n\t\t\t\t)}\n\t\t\t\t{hasHeaderSlot ? (\n\t\t\t\t\t<slot name='header' />\n\t\t\t\t) : (\n\t\t\t\t\tthis.header?.length && (\n\t\t\t\t\t\t<p class='my-0 text-center font-ambit text-sm font-bold text-black-teal'>\n\t\t\t\t\t\t\t{this.header}\n\t\t\t\t\t\t</p>\n\t\t\t\t\t)\n\t\t\t\t)}\n\t\t\t\t{hasContentSlot ? (\n\t\t\t\t\t<slot name='content' />\n\t\t\t\t) : (\n\t\t\t\t\tthis.content?.length && (\n\t\t\t\t\t\t<p class='my-0 text-center text-sm text-black-teal-300'>\n\t\t\t\t\t\t\t{this.content}\n\t\t\t\t\t\t</p>\n\t\t\t\t\t)\n\t\t\t\t)}\n\t\t\t\t{this.enableAction &&\n\t\t\t\t\t(hasActionSlot ? (\n\t\t\t\t\t\t<slot name='action' />\n\t\t\t\t\t) : (\n\t\t\t\t\t\t<p-button\n\t\t\t\t\t\t\tclass='mt-4'\n\t\t\t\t\t\t\ticon={this.actionIcon}\n\t\t\t\t\t\t\tloading={this.actionLoading}\n\t\t\t\t\t\t\tvariant={this.actionVariant}\n\t\t\t\t\t\t>\n\t\t\t\t\t\t\t{this.actionText}\n\t\t\t\t\t\t</p-button>\n\t\t\t\t\t))}\n\t\t\t</div>\n\t\t);\n\t}\n}\n"],"version":3}
|
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
import { p as proxyCustomElement, H, c as createEvent, h } from './p-BLaYz0fg.js';
|
|
2
2
|
import { c as cva } from './p-4hDfHOnN.js';
|
|
3
|
-
import { d as defineCustomElement$2, a as defaultSize, b as defaultSizeOptions } from './p-
|
|
3
|
+
import { d as defineCustomElement$2, a as defaultSize, b as defaultSizeOptions } from './p-DGQEB1OR.js';
|
|
4
4
|
import { d as defineCustomElement$b } from './p-BsVQWdLD.js';
|
|
5
5
|
import { d as defineCustomElement$a } from './p-q_c1iUVr.js';
|
|
6
|
-
import { d as defineCustomElement$9 } from './p-
|
|
6
|
+
import { d as defineCustomElement$9 } from './p-Bq6M4UX0.js';
|
|
7
7
|
import { d as defineCustomElement$8 } from './p-CKjBhtCw.js';
|
|
8
8
|
import { d as defineCustomElement$7 } from './p-B63gPh_H.js';
|
|
9
9
|
import { d as defineCustomElement$6 } from './p-BsgE1XSo.js';
|
|
10
|
-
import { d as defineCustomElement$5 } from './p-
|
|
11
|
-
import { d as defineCustomElement$4 } from './p-
|
|
10
|
+
import { d as defineCustomElement$5 } from './p-B2HQAHKa.js';
|
|
11
|
+
import { d as defineCustomElement$4 } from './p-DzjemSiz.js';
|
|
12
12
|
import { d as defineCustomElement$3 } from './p-DkQcmaID.js';
|
|
13
13
|
import { d as defineCustomElement$1 } from './p-ByT0XK4K.js';
|
|
14
14
|
|
|
@@ -216,6 +216,6 @@ function defineCustomElement() {
|
|
|
216
216
|
defineCustomElement();
|
|
217
217
|
|
|
218
218
|
export { TableFooter as T, defineCustomElement as d };
|
|
219
|
-
//# sourceMappingURL=p-
|
|
219
|
+
//# sourceMappingURL=p-BfNx0tEt.js.map
|
|
220
220
|
|
|
221
|
-
//# sourceMappingURL=p-
|
|
221
|
+
//# sourceMappingURL=p-BfNx0tEt.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"file":"p-
|
|
1
|
+
{"file":"p-BfNx0tEt.js","mappings":";;;;;;;;;;;;;;AAAA,MAAM,uBAAuB,GAAG,0oEAA0oE;;ACgB1qE,MAAM,MAAM,GAAG,GAAG,CACjB;IACC,yBAAyB;IACzB,kBAAkB;IAClB,sDAAsD;IACtD,oDAAoD;IACpD,iFAAiF;CACjF,EACD;AACC,IAAA,QAAQ,EAAE;AACT,QAAA,MAAM,EAAE;AACP,YAAA,KAAK,EAAE,iBAAiB;AACxB,YAAA,IAAI,EAAE,mBAAmB;AACzB,SAAA;AACD,QAAA,MAAM,EAAE;AACP,YAAA,KAAK,EAAE,MAAM;AACb,YAAA,IAAI,EAAE,QAAQ;AACd,SAAA;AACD,KAAA;AACD,CAAA,CACD;MAOY,WAAW,iBAAAA,kBAAA,CAAA,MAAA,WAAA,SAAAC,CAAA,CAAA;;;;;;;;;AACvB;;AAEG;IACK,oBAAoB,GAAY,IAAI;AAE5C;;AAEG;IACK,qBAAqB,GAAY,IAAI;AAE7C;;AAEG;IACK,OAAO,GAAY,KAAK;AAEhC;;AAEG;IACqC,IAAI,GAAW,CAAC;AAExD;;AAEG;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;YACnD,IAAI,CAAC,GAAG,CAAC,KAAK,CAAC,YAAY,GAAG,CAAA,CAAA,EAAI,mBAAmB,CAAA,EAAA,CAAI;;AAG1D,QAAA,IAAI,CAAC,SAAS,GAAG,MAAM,CAAC,WAAW,GAAG,IAAI,CAAC,MAAM,IAAI,CAAC;;IAIvD,QAAQ,GAAA;QACP,IAAI,CAAC,WAAW,EAAE;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","names":["__stencil_proxyCustomElement","HTMLElement"],"sources":["src/components/molecules/table/footer/table-footer.component.css?tag=p-table-footer&encapsulation=shadow","src/components/molecules/table/footer/table-footer.component.tsx"],"sourcesContent":[":host {\n\t@apply sticky;\n\t@apply z-[1];\n\n\t--tw-content: '';\n}\n","import {\n\tComponent,\n\tEvent,\n\tEventEmitter,\n\th,\n\tProp,\n\tElement,\n\tState,\n\tListen,\n} from '@stencil/core';\nimport { cva } from 'class-variance-authority';\nimport {\n\tdefaultSize,\n\tdefaultSizeOptions,\n} from '../../../molecules/pagination/size/constants';\n\nconst footer = cva(\n\t[\n\t\t'justify-center relative',\n\t\t'w-full py-8 px-6',\n\t\t'after:absolute after:top-0 after:left-0 after:z-[0]',\n\t\t'after:w-full after:h-full after:transition-opacity',\n\t\t'after:bg-gradient-to-t after:from-white after:via-white/80 after:to-transparent',\n\t],\n\t{\n\t\tvariants: {\n\t\t\tpinned: {\n\t\t\t\tfalse: 'after:opacity-0',\n\t\t\t\ttrue: 'after:opacity-100',\n\t\t\t},\n\t\t\thidden: {\n\t\t\t\tfalse: 'flex',\n\t\t\t\ttrue: 'hidden',\n\t\t\t},\n\t\t},\n\t}\n);\n\n@Component({\n\ttag: 'p-table-footer',\n\tstyleUrl: 'table-footer.component.css',\n\tshadow: true,\n})\nexport class TableFooter {\n\t/**\n\t * Wether to enable pagination size select\n\t */\n\t@Prop() enablePaginationSize: boolean = true;\n\n\t/**\n\t * Wether to enable pagination pages\n\t */\n\t@Prop() enablePaginationPages: boolean = true;\n\n\t/**\n\t * Wether we want to show loading state\n\t */\n\t@Prop() loading: boolean = false;\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 footer is hidden or nog\n\t */\n\t@Event({\n\t\tbubbles: false,\n\t})\n\thiddenChange: EventEmitter<boolean>;\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/**\n\t * The host element\n\t */\n\t@Element() private _el: HTMLElement;\n\n\t@State() private _isPinned = false;\n\t@State() private _hasPaginationPages = true;\n\n\tprivate _hidePageSizeSelect = false;\n\tprivate _hidden = false;\n\n\tcomponentDidLoad() {\n\t\tthis._checkStuck();\n\t}\n\n\tcomponentWillRender() {\n\t\tthis._hidePageSizeSelect =\n\t\t\tthis.hideOnSinglePage && this.total <= this.pageSizeOptions?.[0];\n\n\t\tconst hidden =\n\t\t\t(this._hidePageSizeSelect && !this._hasPaginationPages) ||\n\t\t\t(!this.enablePaginationSize && !this.enablePaginationPages);\n\n\t\tif (hidden !== this._hidden) {\n\t\t\tthis._hidden = hidden;\n\t\t\tthis.hiddenChange.emit(hidden);\n\t\t}\n\t}\n\n\trender() {\n\t\treturn (\n\t\t\t<div\n\t\t\t\tclass={footer({\n\t\t\t\t\tpinned: this._isPinned,\n\t\t\t\t\thidden: this._hidden,\n\t\t\t\t})}\n\t\t\t>\n\t\t\t\t{(this.enablePaginationPages || this.enablePaginationSize) &&\n\t\t\t\t\tthis.total > 0 && (\n\t\t\t\t\t\t<p-pagination\n\t\t\t\t\t\t\tclass='z-[2]'\n\t\t\t\t\t\t\tenablePaginationSize={this.enablePaginationSize}\n\t\t\t\t\t\t\tenablePaginationPages={this.enablePaginationPages}\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 }) => this._changePageSize(detail)}\n\t\t\t\t\t\t\tpage={this.page}\n\t\t\t\t\t\t\thideOnSinglePage={this.hideOnSinglePage}\n\t\t\t\t\t\t\tonPageChange={({ detail }) => this.pageChange.emit(detail)}\n\t\t\t\t\t\t\ttotal={this.total}\n\t\t\t\t\t\t\tonPagesChange={({ detail }) =>\n\t\t\t\t\t\t\t\t(this._hasPaginationPages = detail > 1)\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t/>\n\t\t\t\t\t)}\n\t\t\t</div>\n\t\t);\n\t}\n\n\tprivate _changePageSize(s?: number) {\n\t\tif (!s) {\n\t\t\treturn;\n\t\t}\n\n\t\tthis.pageSize = s;\n\t\tthis.pageSizeChange.emit(this.pageSize);\n\t}\n\n\tprivate _checkStuck() {\n\t\tconst rect = this._el.getBoundingClientRect();\n\t\tconst layout = document.querySelector('p-layout');\n\n\t\tif (layout) {\n\t\t\tconst innerContent = layout.shadowRoot.querySelector('.content');\n\t\t\tconst innerContentComputed = getComputedStyle(innerContent);\n\n\t\t\tconst layoutPaddingBottom = parseInt(\n\t\t\t\tinnerContentComputed.paddingBottom,\n\t\t\t\t10\n\t\t\t);\n\t\t\tthis._el.style.bottom = `-${layoutPaddingBottom}px`;\n\t\t\tthis._el.style.marginBottom = `-${layoutPaddingBottom}px`;\n\t\t}\n\n\t\tthis._isPinned = window.innerHeight - rect.bottom == 0;\n\t}\n\n\t@Listen('scroll', { target: 'window' })\n\tonScroll() {\n\t\tthis._checkStuck();\n\t}\n}\n"],"version":3}
|
|
@@ -148,7 +148,7 @@ const Dropdown = /*@__PURE__*/ proxyCustomElement(class Dropdown extends H {
|
|
|
148
148
|
else {
|
|
149
149
|
dropdownContainer = (h("p-dropdown-menu-container", { key: 'e68c049d65efe4456b1b5ac118422e91c9649e4b', variant: this.variant, maxWidth: !this.calculateWidth && this.applyMaxWidth, fullWidth: this.applyFullWidth && !this.applyMaxWidth, allowOverflow: this.allowOverflow, scrollable: this.scrollable, ...dropdownContainerProps }, itemsSlot));
|
|
150
150
|
}
|
|
151
|
-
return (h(Host, { key: '8639a2bcba557b68626220886aa054c9f3678e55', class: 'p-dropdown relative' }, h("div", { key: 'b29ae10c283c208c006b57af96fc94722912905c', class: 'trigger', ref: ref => (this._trigger = ref), onClick: () => this._triggerClickHandler() }, h("slot", { key: '332234009a0ad2b2576330db2fd3cf684c9f2cad', name: 'trigger' })), dropdownContainer));
|
|
151
|
+
return (h(Host, { key: '8639a2bcba557b68626220886aa054c9f3678e55', class: 'p-dropdown relative' }, h("div", { key: 'b29ae10c283c208c006b57af96fc94722912905c', class: 'trigger', ref: ref => (this._trigger = ref), onClick: () => this._triggerClickHandler() }, h("slot", { key: '332234009a0ad2b2576330db2fd3cf684c9f2cad', name: 'trigger' })), h("div", { key: 'd18903c842418c248d92832b713c4de6c614bddc', class: 'relative w-full' }, dropdownContainer)));
|
|
152
152
|
}
|
|
153
153
|
_checkButtons(active = false) {
|
|
154
154
|
if (!this.applyChevron) {
|
|
@@ -312,6 +312,6 @@ function defineCustomElement() {
|
|
|
312
312
|
defineCustomElement();
|
|
313
313
|
|
|
314
314
|
export { Dropdown as D, defineCustomElement as d };
|
|
315
|
-
//# sourceMappingURL=p-
|
|
315
|
+
//# sourceMappingURL=p-Bq6M4UX0.js.map
|
|
316
316
|
|
|
317
|
-
//# sourceMappingURL=p-
|
|
317
|
+
//# sourceM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,KAAK,EAAE;gBAC/B,GAAG,EAAE,CAAG,EAAA,CAAC,CAAI,EAAA,CAAA;gBACb,IAAI,EAAE,CAAG,EAAA,CAAC,CAAI,EAAA,CAAA;AACd,aAAA,CAAC;AACH,SAAC,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","names":["__stencil_proxyCustomElement","HTMLElement"],"sources":["src/components/molecules/dropdown/dropdown.component.css?tag=p-dropdown&encapsulation=shadow","src/components/molecules/dropdown/dropdown.component.tsx"],"sourcesContent":["","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 { cva } from 'class-variance-authority';\nimport { childOf } from '../../../utils/child-of';\n\nconst dropdownContainerClass = cva(['z-dropdown hidden'], {\n\tvariants: {\n\t\tstrategy: {\n\t\t\tabsolute: 'absolute',\n\t\t\tfixed: 'fixed',\n\t\t},\n\t\tfullWidth: {\n\t\t\tfalse: null,\n\t\t\ttrue: 'w-full',\n\t\t},\n\t\tmaxWidth: {\n\t\t\tfalse: null,\n\t\t\ttrue: 'max-w-[13.875rem]',\n\t\t},\n\t},\n\tcompoundVariants: [\n\t\t{\n\t\t\tfullWidth: false,\n\t\t\tmaxWidth: true,\n\t\t\tclass: 'w-auto',\n\t\t},\n\t],\n});\n\n@Component({\n\ttag: 'p-dropdown',\n\tstyleUrl: 'dropdown.component.css',\n\tshadow: true,\n})\nexport class Dropdown {\n\t/**\n\t * The variant of the dropdown\n\t */\n\t@Prop() variant: 'default' | 'dark-teal' = 'default';\n\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\tcomponentDidLoad() {\n\t\tthis._checkButtons();\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\tthis._checkItems();\n\t}\n\n\trender() {\n\t\tconst dropdownContainerProps = {\n\t\t\tclass: dropdownContainerClass({\n\t\t\t\tstrategy: this.strategy,\n\t\t\t\tmaxWidth: !this.calculateWidth && this.applyMaxWidth,\n\t\t\t\tfullWidth: this.applyFullWidth && !this.applyMaxWidth,\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\t\tconst itemsSlot = <slot name='items' />;\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\tvariant={this.variant}\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{itemsSlot}\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\tvariant={this.variant}\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{itemsSlot}\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 relative'>\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<div class='relative w-full'>{dropdownContainer}</div>\n\t\t\t</Host>\n\t\t);\n\t}\n\n\tprivate _checkButtons(active: boolean = false) {\n\t\tif (!this.applyChevron) {\n\t\t\treturn;\n\t\t}\n\n\t\tconst buttons = this._el.querySelectorAll<HTMLPButtonElement>(\n\t\t\t'p-button[slot=\"trigger\"]'\n\t\t);\n\n\t\tfor (let button of [...buttons]) {\n\t\t\tbutton.chevronPosition = this.chevronPosition;\n\t\t\tbutton.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\tbutton.disabled = this.disableTriggerClick;\n\t\t\tbutton.active = active;\n\t\t}\n\t}\n\n\tprivate _checkItems() {\n\t\tconst items = this._el.querySelectorAll<HTMLPDropdownMenuItemElement>(\n\t\t\t'p-dropdown-menu-item'\n\t\t);\n\n\t\tfor (let item of [...items]) {\n\t\t\titem.variant = this.variant;\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\t\tthis._checkButtons(true);\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\tthis._checkButtons(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"],"version":3}
|
|
@@ -4,7 +4,7 @@ import { f as formatTranslation, g as getLocaleComponentStrings } from './p-DiJj
|
|
|
4
4
|
import { d as defineCustomElement$c } from './p-DoonhL8V.js';
|
|
5
5
|
import { d as defineCustomElement$b } from './p-B6UH3J7_.js';
|
|
6
6
|
import { d as defineCustomElement$a } from './p-q_c1iUVr.js';
|
|
7
|
-
import { d as defineCustomElement$9 } from './p-
|
|
7
|
+
import { d as defineCustomElement$9 } from './p-CyabiQlx.js';
|
|
8
8
|
import { d as defineCustomElement$8 } from './p-C1wQaaNc.js';
|
|
9
9
|
import { d as defineCustomElement$7 } from './p-llhG3A9n.js';
|
|
10
10
|
import { d as defineCustomElement$6 } from './p-BsgE1XSo.js';
|
|
@@ -9723,6 +9723,6 @@ function defineCustomElement() {
|
|
|
9723
9723
|
defineCustomElement();
|
|
9724
9724
|
|
|
9725
9725
|
export { TableHeader as T, defineCustomElement as d };
|
|
9726
|
-
//# sourceMappingURL=p-
|
|
9726
|
+
//# sourceMappingURL=p-BvpAM_Rb.js.map
|
|
9727
9727
|
|
|
9728
|
-
//# sourceMappingURL=p-
|
|
9728
|
+
//# sourceMappingURL=p-BvpAM_Rb.js.map
|