@paperless/core 2.0.1-beta.120 → 2.0.1-beta.122
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 +22 -0
- package/dist/build/{p-ddad483b.entry.js → p-05db72d0.entry.js} +2 -2
- package/dist/build/{p-adb1ad27.entry.js → p-0740b690.entry.js} +2 -2
- package/dist/build/{p-4630294b.js → p-22db5ddd.js} +1 -1
- package/dist/build/{p-ad08592e.entry.js → p-26a3990a.entry.js} +2 -2
- package/dist/build/p-26b8bf57.entry.js +2 -0
- package/dist/build/p-26b8bf57.entry.js.map +1 -0
- package/dist/build/{p-79ed922f.entry.js → p-2edd87f3.entry.js} +2 -2
- package/dist/build/p-474a16ab.entry.js +2 -0
- package/dist/build/p-4953f4a9.entry.js +2 -0
- package/dist/build/p-4953f4a9.entry.js.map +1 -0
- package/dist/build/p-5048c4c2.entry.js +2 -0
- package/dist/{paperless/p-347b3ec3.entry.js → build/p-8981247d.entry.js} +2 -2
- package/dist/build/{p-983c6eb3.entry.js → p-8ff7cf25.entry.js} +2 -2
- package/dist/build/p-9cf8ba05.entry.js +2 -0
- package/dist/build/p-9cf8ba05.entry.js.map +1 -0
- package/dist/build/{p-007df641.entry.js → p-add932d6.entry.js} +2 -2
- package/dist/build/p-attachment.entry.esm.js.map +1 -1
- package/dist/build/{p-b13d6a2c.entry.js → p-c4724fb7.entry.js} +2 -2
- package/dist/{paperless/p-53009290.entry.js → build/p-c879f50c.entry.js} +2 -2
- package/dist/build/{p-3bd5d63a.entry.js → p-cc3307b8.entry.js} +2 -2
- package/dist/build/{p-55a41995.entry.js → p-d6828011.entry.js} +2 -2
- package/dist/build/{p-b0fc8bea.entry.js → p-e2054751.entry.js} +2 -2
- package/dist/build/{p-505a20af.entry.js → p-ef4a690b.entry.js} +2 -2
- package/dist/build/p-stepper-item.entry.esm.js.map +1 -1
- package/dist/build/p-stepper.entry.esm.js.map +1 -1
- package/dist/build/paperless.esm.js +1 -1
- package/dist/cjs/p-attachment.cjs.entry.js +5 -8
- package/dist/cjs/p-attachment.cjs.entry.js.map +1 -1
- package/dist/cjs/p-attachment.entry.cjs.js.map +1 -1
- package/dist/cjs/p-button-group.cjs.entry.js +1 -1
- package/dist/cjs/p-calendar.cjs.entry.js +1 -1
- package/dist/cjs/p-checkbox_4.cjs.entry.js +3 -3
- package/dist/cjs/p-content-slider.cjs.entry.js +2 -2
- package/dist/cjs/p-datepicker.cjs.entry.js +2 -2
- package/dist/cjs/p-empty-state_9.cjs.entry.js +8 -8
- 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-listing.cjs.entry.js +1 -1
- package/dist/cjs/p-navbar.cjs.entry.js +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-select.cjs.entry.js +1 -1
- package/dist/cjs/p-stepper-item.cjs.entry.js +29 -24
- package/dist/cjs/p-stepper-item.cjs.entry.js.map +1 -1
- package/dist/cjs/p-stepper-item.entry.cjs.js.map +1 -1
- package/dist/cjs/p-stepper.cjs.entry.js +10 -17
- package/dist/cjs/p-stepper.cjs.entry.js.map +1 -1
- package/dist/cjs/p-stepper.entry.cjs.js.map +1 -1
- package/dist/cjs/p-toast.cjs.entry.js +1 -1
- package/dist/collection/components/atoms/stepper/item/stepper-item.component.css +1 -1
- package/dist/collection/components/atoms/stepper/item/stepper-item.component.js +28 -23
- package/dist/collection/components/atoms/stepper/item/stepper-item.component.js.map +1 -1
- package/dist/collection/components/molecules/attachment/attachment.component.js +5 -8
- package/dist/collection/components/molecules/attachment/attachment.component.js.map +1 -1
- package/dist/collection/components/molecules/button-group/button-group.component.js +1 -1
- package/dist/collection/components/molecules/calendar/calendar.component.js +1 -1
- package/dist/collection/components/molecules/content-slider/content-slider.component.js +2 -2
- package/dist/collection/components/molecules/datepicker/datepicker.component.js +2 -2
- package/dist/collection/components/molecules/dropdown/dropdown.component.js +3 -3
- 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/select/select.component.js +1 -1
- package/dist/collection/components/molecules/table/cell/table-cell.component.js +1 -1
- package/dist/collection/components/molecules/table/footer/table-footer.component.js +2 -2
- package/dist/collection/components/molecules/table/row/table-row.component.js +3 -3
- package/dist/collection/components/molecules/toast/toast.component.js +1 -1
- package/dist/collection/components/organisms/listing/listing.component.js +1 -1
- package/dist/collection/components/organisms/navbar/navbar.component.js +1 -1
- package/dist/collection/components/organisms/stepper/stepper.component.css +1 -1
- package/dist/collection/components/organisms/stepper/stepper.component.js +9 -16
- package/dist/collection/components/organisms/stepper/stepper.component.js.map +1 -1
- package/dist/components/{p-CtkrGsqa.js → p-2ZI4Mzgd.js} +8 -8
- package/dist/components/{p-CtkrGsqa.js.map → p-2ZI4Mzgd.js.map} +1 -1
- package/dist/components/{p-UP0QWP4I.js → p-BFXs5OQx.js} +3 -3
- package/dist/components/{p-UP0QWP4I.js.map → p-BFXs5OQx.js.map} +1 -1
- package/dist/components/{p-Blx3errZ.js → p-BZbrGNXl.js} +5 -5
- package/dist/components/{p-Blx3errZ.js.map → p-BZbrGNXl.js.map} +1 -1
- package/dist/components/{p-DyXjCQd1.js → p-Bb8uyInh.js} +5 -5
- package/dist/components/{p-DyXjCQd1.js.map → p-Bb8uyInh.js.map} +1 -1
- package/dist/components/{p-BdBHOvJP.js → p-CPkh1e-n.js} +4 -4
- package/dist/components/{p-BdBHOvJP.js.map → p-CPkh1e-n.js.map} +1 -1
- package/dist/components/{p-Ch3YJ0-j.js → p-ClUlzt-d.js} +3 -3
- package/dist/components/{p-Ch3YJ0-j.js.map → p-ClUlzt-d.js.map} +1 -1
- package/dist/components/{p-DtHs-SzC.js → p-Cy1bLMTg.js} +8 -8
- package/dist/components/{p-DtHs-SzC.js.map → p-Cy1bLMTg.js.map} +1 -1
- package/dist/components/{p-DdoouZCr.js → p-Da_mcBgh.js} +3 -3
- package/dist/components/{p-DdoouZCr.js.map → p-Da_mcBgh.js.map} +1 -1
- package/dist/components/{p-CxhSYJBZ.js → p-Dh_4gXYW.js} +3 -3
- package/dist/components/{p-CxhSYJBZ.js.map → p-Dh_4gXYW.js.map} +1 -1
- package/dist/components/{p-BUl1mbJp.js → p-Du_Am2CT.js} +5 -5
- package/dist/components/{p-BUl1mbJp.js.map → p-Du_Am2CT.js.map} +1 -1
- package/dist/components/p-attachment.js +5 -8
- package/dist/components/p-attachment.js.map +1 -1
- package/dist/components/p-button-group.js +1 -1
- package/dist/components/p-calendar.js +1 -1
- package/dist/components/p-content-slider.js +2 -2
- package/dist/components/p-datepicker.js +5 -5
- 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-zJvwlVQ_.js → p-jkRa9dQy.js} +3 -3
- package/dist/components/{p-zJvwlVQ_.js.map → p-jkRa9dQy.js.map} +1 -1
- package/dist/components/p-label.js +3 -3
- package/dist/components/p-listing.js +1 -1
- package/dist/components/p-navbar.js +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 +1 -1
- package/dist/components/p-select.js +3 -3
- package/dist/components/p-stepper-item.js +29 -24
- package/dist/components/p-stepper-item.js.map +1 -1
- package/dist/components/p-stepper.js +10 -17
- package/dist/components/p-stepper.js.map +1 -1
- package/dist/components/p-table-cell.js +1 -1
- package/dist/components/p-table-footer.js +1 -1
- package/dist/components/p-table-header.js +1 -1
- package/dist/components/p-table-row.js +1 -1
- package/dist/components/p-table.js +10 -10
- package/dist/components/p-toast.js +1 -1
- package/dist/esm/p-attachment.entry.js +5 -8
- package/dist/esm/p-attachment.entry.js.map +1 -1
- package/dist/esm/p-button-group.entry.js +1 -1
- package/dist/esm/p-calendar.entry.js +1 -1
- package/dist/esm/p-checkbox_4.entry.js +3 -3
- package/dist/esm/p-content-slider.entry.js +2 -2
- package/dist/esm/p-datepicker.entry.js +2 -2
- package/dist/esm/p-empty-state_9.entry.js +8 -8
- package/dist/esm/p-field_2.entry.js +3 -3
- package/dist/esm/p-label.entry.js +3 -3
- package/dist/esm/p-listing.entry.js +1 -1
- package/dist/esm/p-navbar.entry.js +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-select.entry.js +1 -1
- package/dist/esm/p-stepper-item.entry.js +29 -24
- package/dist/esm/p-stepper-item.entry.js.map +1 -1
- package/dist/esm/p-stepper.entry.js +10 -17
- package/dist/esm/p-stepper.entry.js.map +1 -1
- package/dist/esm/p-toast.entry.js +1 -1
- package/dist/index.html +1 -1
- package/dist/paperless/{p-ddad483b.entry.js → p-05db72d0.entry.js} +2 -2
- package/dist/paperless/{p-adb1ad27.entry.js → p-0740b690.entry.js} +2 -2
- package/dist/paperless/{p-ad08592e.entry.js → p-26a3990a.entry.js} +2 -2
- package/dist/paperless/p-26b8bf57.entry.js +2 -0
- package/dist/paperless/p-26b8bf57.entry.js.map +1 -0
- package/dist/paperless/{p-79ed922f.entry.js → p-2edd87f3.entry.js} +2 -2
- package/dist/paperless/p-474a16ab.entry.js +2 -0
- package/dist/paperless/p-4953f4a9.entry.js +2 -0
- package/dist/paperless/p-4953f4a9.entry.js.map +1 -0
- package/dist/paperless/p-5048c4c2.entry.js +2 -0
- package/dist/{build/p-347b3ec3.entry.js → paperless/p-8981247d.entry.js} +2 -2
- package/dist/paperless/{p-983c6eb3.entry.js → p-8ff7cf25.entry.js} +2 -2
- package/dist/paperless/p-9cf8ba05.entry.js +2 -0
- package/dist/paperless/p-9cf8ba05.entry.js.map +1 -0
- package/dist/paperless/{p-007df641.entry.js → p-add932d6.entry.js} +2 -2
- package/dist/paperless/p-attachment.entry.esm.js.map +1 -1
- package/dist/paperless/{p-b13d6a2c.entry.js → p-c4724fb7.entry.js} +2 -2
- package/dist/{build/p-53009290.entry.js → paperless/p-c879f50c.entry.js} +2 -2
- package/dist/paperless/{p-3bd5d63a.entry.js → p-cc3307b8.entry.js} +2 -2
- package/dist/paperless/{p-55a41995.entry.js → p-d6828011.entry.js} +2 -2
- package/dist/paperless/{p-b0fc8bea.entry.js → p-e2054751.entry.js} +2 -2
- package/dist/paperless/{p-505a20af.entry.js → p-ef4a690b.entry.js} +2 -2
- package/dist/paperless/p-stepper-item.entry.esm.js.map +1 -1
- package/dist/paperless/p-stepper.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-56a401d7.entry.js +0 -2
- package/dist/build/p-58f9ac89.entry.js +0 -2
- package/dist/build/p-58f9ac89.entry.js.map +0 -1
- package/dist/build/p-7adc863b.entry.js +0 -2
- package/dist/build/p-aec4f685.entry.js +0 -2
- package/dist/build/p-aec4f685.entry.js.map +0 -1
- package/dist/build/p-de598439.entry.js +0 -2
- package/dist/build/p-de598439.entry.js.map +0 -1
- package/dist/paperless/p-56a401d7.entry.js +0 -2
- package/dist/paperless/p-58f9ac89.entry.js +0 -2
- package/dist/paperless/p-58f9ac89.entry.js.map +0 -1
- package/dist/paperless/p-7adc863b.entry.js +0 -2
- package/dist/paperless/p-aec4f685.entry.js +0 -2
- package/dist/paperless/p-aec4f685.entry.js.map +0 -1
- package/dist/paperless/p-de598439.entry.js +0 -2
- package/dist/paperless/p-de598439.entry.js.map +0 -1
- /package/dist/build/{p-ddad483b.entry.js.map → p-05db72d0.entry.js.map} +0 -0
- /package/dist/build/{p-adb1ad27.entry.js.map → p-0740b690.entry.js.map} +0 -0
- /package/dist/build/{p-ad08592e.entry.js.map → p-26a3990a.entry.js.map} +0 -0
- /package/dist/build/{p-79ed922f.entry.js.map → p-2edd87f3.entry.js.map} +0 -0
- /package/dist/build/{p-56a401d7.entry.js.map → p-474a16ab.entry.js.map} +0 -0
- /package/dist/build/{p-7adc863b.entry.js.map → p-5048c4c2.entry.js.map} +0 -0
- /package/dist/build/{p-347b3ec3.entry.js.map → p-8981247d.entry.js.map} +0 -0
- /package/dist/build/{p-983c6eb3.entry.js.map → p-8ff7cf25.entry.js.map} +0 -0
- /package/dist/build/{p-007df641.entry.js.map → p-add932d6.entry.js.map} +0 -0
- /package/dist/build/{p-b13d6a2c.entry.js.map → p-c4724fb7.entry.js.map} +0 -0
- /package/dist/build/{p-53009290.entry.js.map → p-c879f50c.entry.js.map} +0 -0
- /package/dist/build/{p-3bd5d63a.entry.js.map → p-cc3307b8.entry.js.map} +0 -0
- /package/dist/build/{p-55a41995.entry.js.map → p-d6828011.entry.js.map} +0 -0
- /package/dist/build/{p-b0fc8bea.entry.js.map → p-e2054751.entry.js.map} +0 -0
- /package/dist/build/{p-505a20af.entry.js.map → p-ef4a690b.entry.js.map} +0 -0
- /package/dist/paperless/{p-ddad483b.entry.js.map → p-05db72d0.entry.js.map} +0 -0
- /package/dist/paperless/{p-adb1ad27.entry.js.map → p-0740b690.entry.js.map} +0 -0
- /package/dist/paperless/{p-ad08592e.entry.js.map → p-26a3990a.entry.js.map} +0 -0
- /package/dist/paperless/{p-79ed922f.entry.js.map → p-2edd87f3.entry.js.map} +0 -0
- /package/dist/paperless/{p-56a401d7.entry.js.map → p-474a16ab.entry.js.map} +0 -0
- /package/dist/paperless/{p-7adc863b.entry.js.map → p-5048c4c2.entry.js.map} +0 -0
- /package/dist/paperless/{p-347b3ec3.entry.js.map → p-8981247d.entry.js.map} +0 -0
- /package/dist/paperless/{p-983c6eb3.entry.js.map → p-8ff7cf25.entry.js.map} +0 -0
- /package/dist/paperless/{p-007df641.entry.js.map → p-add932d6.entry.js.map} +0 -0
- /package/dist/paperless/{p-b13d6a2c.entry.js.map → p-c4724fb7.entry.js.map} +0 -0
- /package/dist/paperless/{p-53009290.entry.js.map → p-c879f50c.entry.js.map} +0 -0
- /package/dist/paperless/{p-3bd5d63a.entry.js.map → p-cc3307b8.entry.js.map} +0 -0
- /package/dist/paperless/{p-55a41995.entry.js.map → p-d6828011.entry.js.map} +0 -0
- /package/dist/paperless/{p-b0fc8bea.entry.js.map → p-e2054751.entry.js.map} +0 -0
- /package/dist/paperless/{p-505a20af.entry.js.map → p-ef4a690b.entry.js.map} +0 -0
|
@@ -62,14 +62,14 @@ const Label = /*@__PURE__*/ proxyCustomElement(class Label extends H {
|
|
|
62
62
|
*/
|
|
63
63
|
keepMobileContent = false;
|
|
64
64
|
render() {
|
|
65
|
-
return (h("div", { key: '
|
|
65
|
+
return (h("div", { key: '9597be604690771c7963c82363a3f249a933313d', class: label({
|
|
66
66
|
variant: this.variant,
|
|
67
67
|
iconOnly: this.iconOnly,
|
|
68
68
|
keepMobileContent: this.keepMobileContent,
|
|
69
|
-
}) }, this.icon && (h("p-icon", { key: '
|
|
69
|
+
}) }, this.icon && (h("p-icon", { key: '48f6b8aae58c96ea2936ceed2a00b09ce4eee21d', class: 'flex-shrink-0', variant: this.icon, flip: this.iconFlip, rotate: this.iconRotate })), !this.iconOnly && (h("div", { key: '45395fa989ebc3b038687c71abd78ab77b17547d', class: cn('flex-1 overflow-hidden text-ellipsis whitespace-nowrap text-sm', {
|
|
70
70
|
hidden: !this.keepMobileContent,
|
|
71
71
|
'desktop-xs:block': !this.keepMobileContent,
|
|
72
|
-
}) }, h("slot", { key: '
|
|
72
|
+
}) }, h("slot", { key: '83ceeb73279dd9c3ae6512cd563fb3a56c1923ad' })))));
|
|
73
73
|
}
|
|
74
74
|
static get style() { return labelComponentCss; }
|
|
75
75
|
}, [1, "p-label", {
|
|
@@ -73,7 +73,7 @@ const Listing = /*@__PURE__*/ proxyCustomElement(class Listing extends H {
|
|
|
73
73
|
}
|
|
74
74
|
}
|
|
75
75
|
render() {
|
|
76
|
-
return (h("div", { key: '
|
|
76
|
+
return (h("div", { key: '13eabe2bacc8fe1ed570ffc5b03a453df3ca3285', class: "flex gap-1 w-full flex-col flex-wrap items-start" }, h("slot", { key: '1d11f5daa58b54d35aa38cf436f578d3d762b146', onSlotchange: () => this._generateStepsOnce() })));
|
|
77
77
|
}
|
|
78
78
|
static get style() { return listingComponentCss; }
|
|
79
79
|
}, [1, "p-listing"]);
|
|
@@ -54,7 +54,7 @@ const Navbar = /*@__PURE__*/ proxyCustomElement(class Navbar extends H {
|
|
|
54
54
|
}
|
|
55
55
|
_show = false;
|
|
56
56
|
render() {
|
|
57
|
-
return (h(Host, { key: '
|
|
57
|
+
return (h(Host, { key: 'ccea1ba5b71e5d7030fc0061c55e7b1f0cf199df' }, h("p-backdrop", { key: '6697e5a39331b9038c371528d030215019aec71b', class: backdrop({ show: this._show }), scrollLock: this._show, onClicked: () => (this._show = false) }), h("div", { key: '5dc02dabfa017fe2e0549b3464f3dae0686e7fdb', class: sidebar({ class: sidebarAndTopbar(), show: this._show }) }, h("div", { key: 'fdc11a2dba8032bcee10a3d718d3471bf08f0bc3', class: 'flex w-full items-center justify-between layout-1280:hidden' }, h("p-button", { key: 'dd627886a9bc8c5759e8d9465bf7038427599594', variant: 'secondary', icon: 'menu-arrow', iconFlip: 'horizontal', iconOnly: true, size: 'sm', onClick: () => (this._show = false) })), h("div", { key: '8eac51be7bcaeac093268cd4e6c2eb1f16f3e308', class: 'flex w-full flex-col items-stretch' }, h("slot", { key: 'd4d57618aa5354fac8b0a19c974d84ef6dd8d639', name: 'company' })), h("div", { key: '48949805268ce97c6c83a15a4e3ec1daaac73b86', class: 'flex w-full flex-col gap-6 overflow-y-auto' }, h("slot", { key: '46e52c419b8269702983519550a074a4bf217928', name: 'content' })), h("div", { key: '01bc1710293357fd8a1f85e66d88c4335c925ce4', class: 'mt-auto hidden w-full flex-col layout-1280:flex' }, h("slot", { key: 'cce5347a4e5e9a33d144ec69ae452b214435fcf1', name: 'user' }))), h("div", { key: '9191ee1056b84360e3ad0bc9a6d1101c80e00a4e', class: topbar({ class: sidebarAndTopbar() }) }, h("p-button", { key: 'caeb38522b307c81deadd55915edc4efe308cc26', variant: 'secondary', iconOnly: true, icon: 'menu-arrow', size: 'sm', onClick: () => (this._show = true) }), h("slot", { key: '18e2f632df00d70b2763d8bf4492b326b9e0eb40', name: 'topbar' }))));
|
|
58
58
|
}
|
|
59
59
|
handleCloseNavbar() {
|
|
60
60
|
this._show = false;
|
|
@@ -76,10 +76,10 @@ const NavigationItem = /*@__PURE__*/ proxyCustomElement(class NavigationItem ext
|
|
|
76
76
|
render() {
|
|
77
77
|
const TagType = this.as;
|
|
78
78
|
const active = asBoolean(this.active) || this.class?.includes('active');
|
|
79
|
-
return (h(Host, { key: '
|
|
79
|
+
return (h(Host, { key: 'c7ce92561fc86949a3d7a4cf8c0c8f7bc8c2c40b', class: cn('p-navigation-item inline-block', this.class) }, h(TagType, { key: '03c0c4fdbbc000af6b275b4cebb96abf0cc2c7d0', class: navigationItem({
|
|
80
80
|
icon: !!this.icon,
|
|
81
81
|
active,
|
|
82
|
-
}), href: this.href, target: this.target }, h("div", { key: '
|
|
82
|
+
}), href: this.href, target: this.target }, h("div", { key: '5cb39568c4cd76f31d4c064fd6436dcee7c18806', class: navigationItemIconContainer({ active }) }, h("p-icon", { key: 'cecfec8ee5fabc95cef24efb4ff64a695b84cec8', variant: this.icon })), h("span", { key: '7c8a60a7af3267febb129605ef888fe411cd850e', class: this.counter && 'has-counter' }, h("slot", { key: '8425b021164b20a0ed11e5f98d6e863dcf666b57' })), !!this.counter && this.counter !== '0' && (h("p-badge", { key: 'f760815a4da64edd25c30c4993e35157e8d86fe8' }, this.counter)), !!this.loading && h("p-loader", { key: 'ae11ad41c8b5e61d22c05c7d2422ff45003593e5', class: 'ml-auto' }))));
|
|
83
83
|
}
|
|
84
84
|
static get style() { return navigationItemComponentCss; }
|
|
85
85
|
}, [4, "p-navigation-item", {
|
|
@@ -13,7 +13,7 @@ const NavigationSection = /*@__PURE__*/ proxyCustomElement(class NavigationSecti
|
|
|
13
13
|
*/
|
|
14
14
|
header;
|
|
15
15
|
render() {
|
|
16
|
-
return (h(Host, { key: '
|
|
16
|
+
return (h(Host, { key: '0974883115ce6c02612170f71ac60a046c1aee00', class: 'flex flex-col gap-2' }, this.header?.length > 0 && (h("p-navigation-title", { key: 'a0d706b6810eca9f5bd075bae9aa79b58f5a2712' }, this.header)), h("div", { key: 'cf846c79ca2248048aa0938221a515da4a5933de', class: 'flex flex-col' }, h("slot", { key: '9620310533a013653d88c41676a4d8c70e4f9676' }))));
|
|
17
17
|
}
|
|
18
18
|
static get style() { return navigationSectionComponentCss; }
|
|
19
19
|
}, [4, "p-navigation-section", {
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { p as proxyCustomElement, H, h } from './p-tdjn65Lz.js';
|
|
2
2
|
import { c as cva } from './p-CBWjHURv.js';
|
|
3
3
|
import { d as defineCustomElement$7 } from './p-D9DxjvS-.js';
|
|
4
|
-
import { d as defineCustomElement$6 } from './p-
|
|
4
|
+
import { d as defineCustomElement$6 } from './p-Du_Am2CT.js';
|
|
5
5
|
import { d as defineCustomElement$5 } from './p-CA6-0EkK.js';
|
|
6
6
|
import { d as defineCustomElement$4 } from './p-cCxwgzDB.js';
|
|
7
7
|
import { d as defineCustomElement$3 } from './p-C-1aZ7t0.js';
|
|
@@ -4,10 +4,10 @@ import { c as cva } from './p-CBWjHURv.js';
|
|
|
4
4
|
import { d as defineCustomElement$e } from './p-FJZcncHr.js';
|
|
5
5
|
import { d as defineCustomElement$d } from './p-D9DxjvS-.js';
|
|
6
6
|
import { d as defineCustomElement$c } from './p-192xXCKV.js';
|
|
7
|
-
import { d as defineCustomElement$b } from './p-
|
|
7
|
+
import { d as defineCustomElement$b } from './p-Du_Am2CT.js';
|
|
8
8
|
import { d as defineCustomElement$a } from './p-CA6-0EkK.js';
|
|
9
9
|
import { d as defineCustomElement$9 } from './p-Bxt_h1P2.js';
|
|
10
|
-
import { d as defineCustomElement$8 } from './p-
|
|
10
|
+
import { d as defineCustomElement$8 } from './p-BZbrGNXl.js';
|
|
11
11
|
import { d as defineCustomElement$7 } from './p-DlGX7eAs.js';
|
|
12
12
|
import { d as defineCustomElement$6 } from './p-DNHN-J6Y.js';
|
|
13
13
|
import { d as defineCustomElement$5 } from './p-cCxwgzDB.js';
|
|
@@ -306,7 +306,7 @@ const Select = /*@__PURE__*/ proxyCustomElement(class Select extends H {
|
|
|
306
306
|
}
|
|
307
307
|
}
|
|
308
308
|
render() {
|
|
309
|
-
return (h("p-dropdown", { key: '
|
|
309
|
+
return (h("p-dropdown", { key: 'b6c46c5cfcaf7adf1bb28691a6fed3ebf3d3e4e9', disableTriggerClick: true, calculateWidth: true, insideClick: true, scrollable: this.enableAutocomplete ? 'large' : true, show: this._showDropdown, onIsOpen: ev => this._onDropdownOpen(ev), usePortal: this.usePortal, strategy: this.strategy }, h("p-field-container", { key: '4e0372e71ca0ce68d1e139cee396743f8647cda5', slot: 'trigger', variant: 'write', prefix: this.prefix, label: this.label, helper: this.helper, required: this.required, error: this.error, forceShowTooltip: !!this.error?.length && !this._showDropdown }, h("p-button", { key: '6b16dde8686a2196e89996becc542a954d6b0aef', class: 'w-full', slot: 'content', variant: 'secondary', size: this.size, chevron: this.showChevron ? (this._showDropdown ? 'up' : 'down') : false, disabled: this.disabled, active: this._showDropdown, error: !!this.error?.length, icon: this.error?.length ? 'warning' : this.icon, onClick: ev => this._onClick(ev) }, h("div", { key: '0009866380577d6bb04e614771dee47db91b51e1', class: 'relative min-w-0 flex-1', ref: ref => (this._inputRef = ref) }, this._displayValue))), this.loading ? this._getLoadingItems() : this._getItems(), this.showAddItem && this._getAddItem()));
|
|
310
310
|
}
|
|
311
311
|
documentClickHandler(event) {
|
|
312
312
|
if (!this._showDropdown || childOfComposed(event, this._el)) {
|
|
@@ -2,7 +2,7 @@ import { p as proxyCustomElement, H, h } from './p-tdjn65Lz.js';
|
|
|
2
2
|
import { c as cva } from './p-CBWjHURv.js';
|
|
3
3
|
import { a as asBoolean } from './p-C5CTp9IA.js';
|
|
4
4
|
|
|
5
|
-
const stepperItemComponentCss = "*{box-sizing:border-box}.static{position:static!important}.flex{display:flex!important}.h-6{height:1.5rem!important}.w-6{width:1.5rem!important}.flex-row-reverse{flex-direction:row-reverse!important}.items-start{align-items:flex-start!important}.items-end{align-items:flex-end!important}.items-center{align-items:center!important}.justify-center{justify-content:center!important}.gap-2{gap:.5rem!important}.rounded-full{border-radius:9999px!important}.border{border-width:1px!important}.border-solid{border-style:solid!important}.border-dark-teal-400{--tw-border-opacity:1!important;border-color:rgb(51 116 109/var(--tw-border-opacity,1))!important}.bg-dark-teal-400{--tw-bg-opacity:1!important;background-color:rgb(51 116 109/var(--tw-bg-opacity,1))!important}.bg-dark-teal-50{--tw-bg-opacity:1!important;background-color:rgb(229 238 237/var(--tw-bg-opacity,1))!important}.text-center{text-align:center!important}.text-sm{font-size:.875rem!important;line-height:1.25rem!important}.font-medium{font-weight:500!important}.text-black-teal-400{--tw-text-opacity:1!important;color:rgb(53 85 80/var(--tw-text-opacity,1))!important}.text-black-teal-500{--tw-text-opacity:1!important;color:rgb(3 42 36/var(--tw-text-opacity,1))!important}.text-dark-teal-400{--tw-text-opacity:1!important;color:rgb(51 116 109/var(--tw-text-opacity,1))!important}.text-white{--tw-text-opacity:1!important;color:rgb(255 255 255/var(--tw-text-opacity,1))!important}";
|
|
5
|
+
const stepperItemComponentCss = "*{box-sizing:border-box}.static{position:static!important}.flex{display:flex!important}.h-6{height:1.5rem!important}.w-6{width:1.5rem!important}.flex-1{flex:1 1 0%!important}.flex-row-reverse{flex-direction:row-reverse!important}.items-start{align-items:flex-start!important}.items-end{align-items:flex-end!important}.items-center{align-items:center!important}.justify-center{justify-content:center!important}.gap-2{gap:.5rem!important}.rounded-full{border-radius:9999px!important}.border{border-width:1px!important}.border-solid{border-style:solid!important}.border-dark-teal-400{--tw-border-opacity:1!important;border-color:rgb(51 116 109/var(--tw-border-opacity,1))!important}.bg-dark-teal-400{--tw-bg-opacity:1!important;background-color:rgb(51 116 109/var(--tw-bg-opacity,1))!important}.bg-dark-teal-50{--tw-bg-opacity:1!important;background-color:rgb(229 238 237/var(--tw-bg-opacity,1))!important}.text-center{text-align:center!important}.text-sm{font-size:.875rem!important;line-height:1.25rem!important}.font-medium{font-weight:500!important}.text-black-teal-400{--tw-text-opacity:1!important;color:rgb(53 85 80/var(--tw-text-opacity,1))!important}.text-black-teal-500{--tw-text-opacity:1!important;color:rgb(3 42 36/var(--tw-text-opacity,1))!important}.text-dark-teal-400{--tw-text-opacity:1!important;color:rgb(51 116 109/var(--tw-text-opacity,1))!important}.text-white{--tw-text-opacity:1!important;color:rgb(255 255 255/var(--tw-text-opacity,1))!important}";
|
|
6
6
|
|
|
7
7
|
const item = cva('flex gap-2', {
|
|
8
8
|
variants: {
|
|
@@ -13,26 +13,31 @@ const item = cva('flex gap-2', {
|
|
|
13
13
|
},
|
|
14
14
|
contentPosition: {
|
|
15
15
|
start: 'flex-row-reverse',
|
|
16
|
-
end: null
|
|
16
|
+
end: null,
|
|
17
17
|
},
|
|
18
|
-
}
|
|
18
|
+
},
|
|
19
19
|
});
|
|
20
|
-
const circle = cva([
|
|
20
|
+
const circle = cva([
|
|
21
|
+
'h-6 w-6 flex items-center justify-center',
|
|
22
|
+
'text-sm text-center font-medium',
|
|
23
|
+
'border border-solid border-dark-teal-400',
|
|
24
|
+
'rounded-full',
|
|
25
|
+
], {
|
|
21
26
|
variants: {
|
|
22
27
|
finished: {
|
|
23
28
|
true: null,
|
|
24
|
-
false: null
|
|
29
|
+
false: null,
|
|
25
30
|
},
|
|
26
31
|
active: {
|
|
27
32
|
true: null,
|
|
28
|
-
false: null
|
|
29
|
-
}
|
|
33
|
+
false: null,
|
|
34
|
+
},
|
|
30
35
|
},
|
|
31
36
|
compoundVariants: [
|
|
32
37
|
{
|
|
33
38
|
finished: false,
|
|
34
39
|
active: false,
|
|
35
|
-
class: 'text-dark-teal-400 bg-dark-teal-50'
|
|
40
|
+
class: 'text-dark-teal-400 bg-dark-teal-50',
|
|
36
41
|
},
|
|
37
42
|
{
|
|
38
43
|
active: true,
|
|
@@ -43,25 +48,25 @@ const circle = cva(['h-6 w-6 flex items-center justify-center', 'text-sm text-ce
|
|
|
43
48
|
active: false,
|
|
44
49
|
finished: true,
|
|
45
50
|
class: 'text-white bg-dark-teal-400',
|
|
46
|
-
}
|
|
47
|
-
]
|
|
51
|
+
},
|
|
52
|
+
],
|
|
48
53
|
});
|
|
49
|
-
const content = cva('text-sm font-medium', {
|
|
54
|
+
const content = cva('text-sm font-medium flex-1', {
|
|
50
55
|
variants: {
|
|
51
56
|
finished: {
|
|
52
57
|
true: null,
|
|
53
|
-
false: null
|
|
58
|
+
false: null,
|
|
54
59
|
},
|
|
55
60
|
active: {
|
|
56
61
|
true: null,
|
|
57
|
-
false: null
|
|
58
|
-
}
|
|
62
|
+
false: null,
|
|
63
|
+
},
|
|
59
64
|
},
|
|
60
65
|
compoundVariants: [
|
|
61
66
|
{
|
|
62
67
|
finished: false,
|
|
63
68
|
active: false,
|
|
64
|
-
class: 'text-black-teal-400'
|
|
69
|
+
class: 'text-black-teal-400',
|
|
65
70
|
},
|
|
66
71
|
{
|
|
67
72
|
active: true,
|
|
@@ -72,8 +77,8 @@ const content = cva('text-sm font-medium', {
|
|
|
72
77
|
active: false,
|
|
73
78
|
finished: true,
|
|
74
79
|
class: 'text-black-teal-500',
|
|
75
|
-
}
|
|
76
|
-
]
|
|
80
|
+
},
|
|
81
|
+
],
|
|
77
82
|
});
|
|
78
83
|
const StepperItem = /*@__PURE__*/ proxyCustomElement(class StepperItem extends H {
|
|
79
84
|
constructor() {
|
|
@@ -102,16 +107,16 @@ const StepperItem = /*@__PURE__*/ proxyCustomElement(class StepperItem extends H
|
|
|
102
107
|
*/
|
|
103
108
|
active = false;
|
|
104
109
|
render() {
|
|
105
|
-
return (h("div", { key: '
|
|
110
|
+
return (h("div", { key: '370271d4be56bd4caf5d95ef7d1674996355d464', class: item({
|
|
106
111
|
align: this.align,
|
|
107
|
-
contentPosition: this.contentPosition
|
|
108
|
-
}) }, h("div", { key: '
|
|
112
|
+
contentPosition: this.contentPosition,
|
|
113
|
+
}) }, h("div", { key: '69f53b49846faebade7d31b28be925eb69457520', class: circle({
|
|
109
114
|
active: asBoolean(this.active),
|
|
110
|
-
finished: asBoolean(this.finished)
|
|
111
|
-
}) }, this.number), h("div", { key: '
|
|
115
|
+
finished: asBoolean(this.finished),
|
|
116
|
+
}) }, this.number), h("div", { key: '406f3c2f79b45b170153527ace5815082b63fead', class: content({
|
|
112
117
|
active: asBoolean(this.active),
|
|
113
|
-
finished: asBoolean(this.finished)
|
|
114
|
-
}) }, h("slot", { key: '
|
|
118
|
+
finished: asBoolean(this.finished),
|
|
119
|
+
}) }, h("slot", { key: '35b81d821930911a114ac2af16555e8491b8ca0f' }))));
|
|
115
120
|
}
|
|
116
121
|
static get style() { return stepperItemComponentCss; }
|
|
117
122
|
}, [1, "p-stepper-item", {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"file":"p-stepper-item.js","mappings":";;;;AAAA,MAAM,uBAAuB,GAAG,
|
|
1
|
+
{"file":"p-stepper-item.js","mappings":";;;;AAAA,MAAM,uBAAuB,GAAG,87CAA87C;;ACI99C,MAAM,IAAI,GAAG,GAAG,CAAC,YAAY,EAAE;AAC9B,IAAA,QAAQ,EAAE;AACT,QAAA,KAAK,EAAE;AACN,YAAA,KAAK,EAAE,aAAa;AACpB,YAAA,MAAM,EAAE,cAAc;A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IAAI,CAAC,QAAQ,CAAC;AAClC,aAAA,CAAC,EAAA,EAEF,CAAQ,CAAA,MAAA,EAAA,EAAA,GAAA,EAAA,0CAAA,EAAA,CAAA,CACH,CACD;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","names":["__stencil_proxyCustomElement","HTMLElement"],"sources":["src/components/atoms/stepper/item/stepper-item.component.css?tag=p-stepper-item&encapsulation=shadow","src/components/atoms/stepper/item/stepper-item.component.tsx"],"sourcesContent":["","import { Component, h, Prop } from '@stencil/core';\nimport { cva } from 'class-variance-authority';\nimport { asBoolean } from '../../../../utils/as-boolean';\n\nconst item = cva('flex gap-2', {\n\tvariants: {\n\t\talign: {\n\t\t\tstart: 'items-start',\n\t\t\tcenter: 'items-center',\n\t\t\tend: 'items-end',\n\t\t},\n\t\tcontentPosition: {\n\t\t\tstart: 'flex-row-reverse',\n\t\t\tend: null,\n\t\t},\n\t},\n});\n\nconst circle = cva(\n\t[\n\t\t'h-6 w-6 flex items-center justify-center',\n\t\t'text-sm text-center font-medium',\n\t\t'border border-solid border-dark-teal-400',\n\t\t'rounded-full',\n\t],\n\t{\n\t\tvariants: {\n\t\t\tfinished: {\n\t\t\t\ttrue: null,\n\t\t\t\tfalse: null,\n\t\t\t},\n\t\t\tactive: {\n\t\t\t\ttrue: null,\n\t\t\t\tfalse: null,\n\t\t\t},\n\t\t},\n\t\tcompoundVariants: [\n\t\t\t{\n\t\t\t\tfinished: false,\n\t\t\t\tactive: false,\n\t\t\t\tclass: 'text-dark-teal-400 bg-dark-teal-50',\n\t\t\t},\n\t\t\t{\n\t\t\t\tactive: true,\n\t\t\t\tfinished: false,\n\t\t\t\tclass: 'text-white bg-dark-teal-400',\n\t\t\t},\n\t\t\t{\n\t\t\t\tactive: false,\n\t\t\t\tfinished: true,\n\t\t\t\tclass: 'text-white bg-dark-teal-400',\n\t\t\t},\n\t\t],\n\t}\n);\n\nconst content = cva('text-sm font-medium flex-1', {\n\tvariants: {\n\t\tfinished: {\n\t\t\ttrue: null,\n\t\t\tfalse: null,\n\t\t},\n\t\tactive: {\n\t\t\ttrue: null,\n\t\t\tfalse: null,\n\t\t},\n\t},\n\tcompoundVariants: [\n\t\t{\n\t\t\tfinished: false,\n\t\t\tactive: false,\n\t\t\tclass: 'text-black-teal-400',\n\t\t},\n\t\t{\n\t\t\tactive: true,\n\t\t\tfinished: false,\n\t\t\tclass: 'text-black-teal-500',\n\t\t},\n\t\t{\n\t\t\tactive: false,\n\t\t\tfinished: true,\n\t\t\tclass: 'text-black-teal-500',\n\t\t},\n\t],\n});\n\n@Component({\n\ttag: 'p-stepper-item',\n\tstyleUrl: 'stepper-item.component.css',\n\tshadow: true,\n})\nexport class StepperItem {\n\t/**\n\t * The number of the step\n\t */\n\t@Prop() number: number = 1;\n\n\t/**\n\t * The alignment of the content in case of vertical direction\n\t */\n\t@Prop() align: 'start' | 'center' | 'end' = 'center';\n\n\t/**\n\t * The position of the content in case of vertical direction\n\t */\n\t@Prop() contentPosition: 'start' | 'end' = 'end';\n\n\t/**\n\t * Wether the step is finished\n\t */\n\t@Prop() finished: boolean = false;\n\n\t/**\n\t * Wether the step is active\n\t */\n\t@Prop() active: boolean = false;\n\n\trender() {\n\t\treturn (\n\t\t\t<div\n\t\t\t\tclass={item({\n\t\t\t\t\talign: this.align,\n\t\t\t\t\tcontentPosition: this.contentPosition,\n\t\t\t\t})}\n\t\t\t>\n\t\t\t\t<div\n\t\t\t\t\tclass={circle({\n\t\t\t\t\t\tactive: asBoolean(this.active),\n\t\t\t\t\t\tfinished: asBoolean(this.finished),\n\t\t\t\t\t})}\n\t\t\t\t>\n\t\t\t\t\t{this.number}\n\t\t\t\t</div>\n\t\t\t\t<div\n\t\t\t\t\tclass={content({\n\t\t\t\t\t\tactive: asBoolean(this.active),\n\t\t\t\t\t\tfinished: asBoolean(this.finished),\n\t\t\t\t\t})}\n\t\t\t\t>\n\t\t\t\t\t<slot />\n\t\t\t\t</div>\n\t\t\t</div>\n\t\t);\n\t}\n}\n"],"version":3}
|
|
@@ -2,24 +2,15 @@ import { p as proxyCustomElement, H, h } from './p-tdjn65Lz.js';
|
|
|
2
2
|
import { c as cva } from './p-CBWjHURv.js';
|
|
3
3
|
import { d as defineCustomElement$2 } from './p-B4MNLDXF.js';
|
|
4
4
|
|
|
5
|
-
const stepperComponentCss = "*{box-sizing:border-box}.static{position:static!important}.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}.items-
|
|
5
|
+
const stepperComponentCss = "*{box-sizing:border-box}.static{position:static!important}.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}.items-center{align-items:center!important}.gap-2{gap:.5rem!important}";
|
|
6
6
|
|
|
7
7
|
const stepper = cva(['flex gap-2'], {
|
|
8
8
|
variants: {
|
|
9
9
|
direction: {
|
|
10
|
-
vertical: 'w-full flex-col flex-wrap
|
|
11
|
-
horizontal: 'h-auto items-center'
|
|
10
|
+
vertical: 'w-full flex-col flex-wrap',
|
|
11
|
+
horizontal: 'h-auto items-center',
|
|
12
12
|
},
|
|
13
|
-
contentPosition: {
|
|
14
|
-
start: null,
|
|
15
|
-
end: null
|
|
16
|
-
}
|
|
17
13
|
},
|
|
18
|
-
compoundVariants: [{
|
|
19
|
-
direction: 'vertical',
|
|
20
|
-
contentPosition: 'start',
|
|
21
|
-
class: 'items-end'
|
|
22
|
-
}]
|
|
23
14
|
});
|
|
24
15
|
const Stepper = /*@__PURE__*/ proxyCustomElement(class Stepper extends H {
|
|
25
16
|
constructor() {
|
|
@@ -138,17 +129,17 @@ const Stepper = /*@__PURE__*/ proxyCustomElement(class Stepper extends H {
|
|
|
138
129
|
stepperLine.active = i < activeStep;
|
|
139
130
|
if (heightDiff > 0 && this.direction === 'vertical') {
|
|
140
131
|
let totalHeight = 0;
|
|
141
|
-
stepperLine.style.marginTop =
|
|
142
|
-
stepperLine.style.marginBottom =
|
|
132
|
+
stepperLine.style.marginTop = '0';
|
|
133
|
+
stepperLine.style.marginBottom = '0';
|
|
143
134
|
if (this.align === 'start' || this.align === 'center') {
|
|
144
135
|
stepperLine.style.marginTop = `-${heightDiff / 16}rem`;
|
|
145
136
|
totalHeight += heightDiff;
|
|
146
137
|
}
|
|
147
|
-
if (this.align === 'center' || this.align ===
|
|
138
|
+
if (this.align === 'center' || this.align === 'end') {
|
|
148
139
|
stepperLine.style.marginBottom = `-${heightDiffNext / 16}rem`;
|
|
149
140
|
totalHeight += heightDiffNext;
|
|
150
141
|
}
|
|
151
|
-
stepperLine.style.minHeight = `calc(${
|
|
142
|
+
stepperLine.style.minHeight = `calc(${totalHeight / 16}rem)`;
|
|
152
143
|
}
|
|
153
144
|
};
|
|
154
145
|
componentDidLoad() {
|
|
@@ -161,7 +152,9 @@ const Stepper = /*@__PURE__*/ proxyCustomElement(class Stepper extends H {
|
|
|
161
152
|
}
|
|
162
153
|
}
|
|
163
154
|
render() {
|
|
164
|
-
return (h("div", { key: '
|
|
155
|
+
return (h("div", { key: '6c1f37dcbb6d9cba1a05f55eef4269082ee58950', class: stepper({
|
|
156
|
+
direction: this.direction,
|
|
157
|
+
}) }, h("slot", { key: 'eefa8e4657f229d45036d6ccda25f1c8fa24934a', onSlotchange: () => this._generateStepsOnce() })));
|
|
165
158
|
}
|
|
166
159
|
_onAlignChange() {
|
|
167
160
|
this._generateStepsOnce();
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"file":"p-stepper.js","mappings":";;;;AAAA,MAAM,mBAAmB,GAAG,gYAAgY;;ACG5Z,MAAM,OAAO,GAAG,GAAG,CAClB,CAAC,YAAY,CAAC,EACd;AACC,IAAA,QAAQ,EAAE;AACT,QAAA,SAAS,EAAE;AACV,YAAA,QAAQ,EAAE,uCAAuC;AACjD,YAAA,UAAU,EAAE;AACZ,SAAA;AACD,QAAA,eAAe,EAAE;AAChB,YAAA,KAAK,EAAE,IAAI;AACX,YAAA,G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AAW,CAAC,KAAK,CAAC,SAAS,GAAG,CAAA,KAAA,GAC5B,WAAW,GAAG,EAAE,EAClB,IAAA,CAAM;;AAER,KAAC;IAED,gBAAgB,GAAA;AACf,QAAA,IAAI,CAAC,eAAe,GAAG,IAAI,cAAc,CAAC,MAAM,IAAI,CAAC,kBAAkB,EAAE,CAAC;QAC1E,IAAI,CAAC,eAAe,CAAC,OAAO,CAAC,IAAI,CAAC,GAAG,CAAC;;IAGvC,kBAAkB,GAAA;AACjB,QAAA,IAAI,IAAI,CAAC,eAAe,EAAE;AACzB,YAAA,IAAI,CAAC,eAAe,CAAC,UAAU,EAAE;;;IAInC,MAAM,GAAA;QACL,QACC,CAAA,CAAA,KAAA,EAAA,EAAA,GAAA,EAAA,0CAAA,EAAK,KAAK,EAAE,OAAO,CAAC,EAAE,SAAS,EAAE,IAAI,CAAC,SAAS,EAAE,CAAC,EAAA,EACjD,CAAA,CAAA,MAAA,EAAA,EAAA,GAAA,EAAA,0CAAA,EAAM,YAAY,EAAE,MAAM,IAAI,CAAC,kBAAkB,EAAE,EAAA,CAAI,CAClD;;IAKE,cAAc,GAAA;QACvB,IAAI,CAAC,kBAAkB,EAAE;;IAIhB,kBAAkB,GAAA;QAC3B,IAAI,CAAC,kBAAkB,EAAE;;IAIhB,mBAAmB,GAAA;QAC5B,IAAI,CAAC,kBAAkB,EAAE;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","names":["__stencil_proxyCustomElement","HTMLElement"],"sources":["src/components/organisms/stepper/stepper.component.css?tag=p-stepper&encapsulation=shadow","src/components/organisms/stepper/stepper.component.tsx"],"sourcesContent":["","import { Component, Element, h, Prop, Watch } from '@stencil/core';\nimport { cva } from 'class-variance-authority';\n\nconst stepper = cva(\n\t['flex gap-2'],\n\t{\n\t\tvariants: {\n\t\t\tdirection: {\n\t\t\t\tvertical: 'w-full flex-col flex-wrap items-start',\n\t\t\t\thorizontal: 'h-auto items-center'\n\t\t\t},\n\t\t\tcontentPosition: {\n\t\t\t\tstart: null,\n\t\t\t\tend: null\n\t\t\t}\n\t\t},\n\t\tcompoundVariants: [{\n\t\t\tdirection: 'vertical',\n\t\t\tcontentPosition: 'start',\n\t\t\tclass: 'items-end'\n\t\t}]\n\t}\n);\n\n@Component({\n\ttag: 'p-stepper',\n\tstyleUrl: 'stepper.component.css',\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() direction: 'horizontal' | 'vertical' = 'horizontal';\n\n\t/**\n\t * The alignment of the content in case of vertical direction\n\t */\n\t@Prop() align: 'start' | 'center' | 'end' = 'center';\n\n\t/**\n\t * The position of the content in case of vertical direction\n\t */\n\t@Prop() 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.Timeout | undefined;\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.number = i + 1;\n\t\t\titem.direction = this.direction;\n\t\t\titem.align = this.direction === 'vertical' ? this.align : 'start';\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\tlet heightDiff = item.clientHeight - 24;\n\t\tlet heightDiffNext = nextItem.clientHeight - 24;\n\n\t\tif(this.align === 'center') {\n\t\t\theightDiff = heightDiff / 2;\n\t\t\theightDiffNext = heightDiffNext / 2;\n\t\t}\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\tlet totalHeight = 0;\n\n\t\t\tstepperLine.style.marginTop = \"0\";\n\t\t\tstepperLine.style.marginBottom= \"0\";\n\n\t\t\tif(this.align === 'start' || this.align === 'center') {\n\t\t\t\tstepperLine.style.marginTop = `-${heightDiff / 16}rem`;\n\t\t\t\ttotalHeight += heightDiff;\n\t\t\t}\n\n\t\t\tif(this.align === 'center' || this.align===\"end\") {\n\t\t\t\tstepperLine.style.marginBottom = `-${heightDiffNext / 16}rem`;\n\t\t\t\ttotalHeight += heightDiffNext;\n\t\t\t}\n\n\t\t\tstepperLine.style.minHeight = `calc(${\n\t\t\t\t(totalHeight / 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<div class={stepper({ direction: this.direction })}>\n\t\t\t\t<slot onSlotchange={() => this._generateStepsOnce()} />\n\t\t\t</div>\n\t\t);\n\t}\n\n\t@Watch('align')\n\tprotected _onAlignChange() {\n\t\tthis._generateStepsOnce();\n\t}\n\n\t@Watch('direction')\n\tprotected _onDirectionChange() {\n\t\tthis._generateStepsOnce();\n\t}\n\n\t@Watch('activeStep')\n\tprotected _onActiveStepChange() {\n\t\tthis._generateStepsOnce();\n\t}\n}\n"],"version":3}
|
|
1
|
+
{"file":"p-stepper.js","mappings":";;;;AAAA,MAAM,mBAAmB,GAAG,wSAAwS;;ACGpU,MAAM,OAAO,GAAG,GAAG,CAAC,CAAC,YAAY,CAAC,EAAE;AACnC,IAAA,QAAQ,EAAE;AACT,QAAA,SAAS,EAAE;AACV,YAAA,QAAQ,EAAE,2BAA2B;AACrC,YAAA,UAAU,EAAE,qBAAqB;AACjC,SAAA;AACD,KAAA;AACD,CAAA,CAAC;MAOW,OAAO,iBAAAA,kBAAA,CAAA,MAAA,OAAA,SAAAC,CAAA,CAAA;;;;;;AACnB;;AAEG;IACK,UAAU,GAAW,CAAC;AAE9B;;AAEG;IACK,gBAAgB,GAAY,IAAI;AAExC;;AAEG;IACK,SAAS,GAA8B,YAAY;AAE3D;;AAEG;IACK,KAAK,GAA+B,QAAQ;AAEpD;;AAEG;IACK,eAAe,GAAoB,KAAK;;AAOxC,IAAA,gBAAgB;AAChB,IAAA,eAAe;IAEf,kBAAkB,GAAG,MAAK;AACjC,QAAA,IAAI,IAAI,C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AAC,SAAS;aACzB,CAAC,EAAA,EAEF,CAAA,CAAA,MAAA,EAAA,EAAA,GAAA,EAAA,0CAAA,EAAM,YAAY,EAAE,MAAM,IAAI,CAAC,kBAAkB,EAAE,EAAA,CAAI,CAClD;;IAKE,cAAc,GAAA;QACvB,IAAI,CAAC,kBAAkB,EAAE;;IAIhB,kBAAkB,GAAA;QAC3B,IAAI,CAAC,kBAAkB,EAAE;;IAIhB,mBAAmB,GAAA;QAC5B,IAAI,CAAC,kBAAkB,EAAE;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","names":["__stencil_proxyCustomElement","HTMLElement"],"sources":["src/components/organisms/stepper/stepper.component.css?tag=p-stepper&encapsulation=shadow","src/components/organisms/stepper/stepper.component.tsx"],"sourcesContent":["","import { Component, Element, h, Prop, Watch } from '@stencil/core';\nimport { cva } from 'class-variance-authority';\n\nconst stepper = cva(['flex gap-2'], {\n\tvariants: {\n\t\tdirection: {\n\t\t\tvertical: 'w-full flex-col flex-wrap',\n\t\t\thorizontal: 'h-auto items-center',\n\t\t},\n\t},\n});\n\n@Component({\n\ttag: 'p-stepper',\n\tstyleUrl: 'stepper.component.css',\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() direction: 'horizontal' | 'vertical' = 'horizontal';\n\n\t/**\n\t * The alignment of the content in case of vertical direction\n\t */\n\t@Prop() align: 'start' | 'center' | 'end' = 'center';\n\n\t/**\n\t * The position of the content in case of vertical direction\n\t */\n\t@Prop() 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.Timeout | undefined;\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.number = i + 1;\n\t\t\titem.direction = this.direction;\n\t\t\titem.align = this.direction === 'vertical' ? this.align : 'start';\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\tlet heightDiff = item.clientHeight - 24;\n\t\tlet heightDiffNext = nextItem.clientHeight - 24;\n\n\t\tif (this.align === 'center') {\n\t\t\theightDiff = heightDiff / 2;\n\t\t\theightDiffNext = heightDiffNext / 2;\n\t\t}\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\tlet totalHeight = 0;\n\n\t\t\tstepperLine.style.marginTop = '0';\n\t\t\tstepperLine.style.marginBottom = '0';\n\n\t\t\tif (this.align === 'start' || this.align === 'center') {\n\t\t\t\tstepperLine.style.marginTop = `-${heightDiff / 16}rem`;\n\t\t\t\ttotalHeight += heightDiff;\n\t\t\t}\n\n\t\t\tif (this.align === 'center' || this.align === 'end') {\n\t\t\t\tstepperLine.style.marginBottom = `-${heightDiffNext / 16}rem`;\n\t\t\t\ttotalHeight += heightDiffNext;\n\t\t\t}\n\n\t\t\tstepperLine.style.minHeight = `calc(${totalHeight / 16}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<div\n\t\t\t\tclass={stepper({\n\t\t\t\t\tdirection: this.direction,\n\t\t\t\t})}\n\t\t\t>\n\t\t\t\t<slot onSlotchange={() => this._generateStepsOnce()} />\n\t\t\t</div>\n\t\t);\n\t}\n\n\t@Watch('align')\n\tprotected _onAlignChange() {\n\t\tthis._generateStepsOnce();\n\t}\n\n\t@Watch('direction')\n\tprotected _onDirectionChange() {\n\t\tthis._generateStepsOnce();\n\t}\n\n\t@Watch('activeStep')\n\tprotected _onActiveStepChange() {\n\t\tthis._generateStepsOnce();\n\t}\n}\n"],"version":3}
|
|
@@ -4,16 +4,16 @@ import { f as formatTranslation, g as getLocaleComponentStrings } from './p-DiJj
|
|
|
4
4
|
import { f as floatingMenuContainerClass } from './p-Ds9vCh4D.js';
|
|
5
5
|
import { f as isMobile } from './p-B3sNjfzc.js';
|
|
6
6
|
import { c as cn } from './p-CT54OXR2.js';
|
|
7
|
-
import { d as defineCustomElement$c, a as defaultSize, b as defaultSizeOptions } from './p-
|
|
7
|
+
import { d as defineCustomElement$c, a as defaultSize, b as defaultSizeOptions } from './p-ClUlzt-d.js';
|
|
8
8
|
import { d as defineCustomElement$v } from './p-BE9wqNth.js';
|
|
9
9
|
import { d as defineCustomElement$u } from './p-D9DxjvS-.js';
|
|
10
10
|
import { d as defineCustomElement$t } from './p-192xXCKV.js';
|
|
11
11
|
import { d as defineCustomElement$s } from './p-Cv1xoKQ6.js';
|
|
12
|
-
import { d as defineCustomElement$r } from './p-
|
|
12
|
+
import { d as defineCustomElement$r } from './p-Du_Am2CT.js';
|
|
13
13
|
import { d as defineCustomElement$q } from './p-CA6-0EkK.js';
|
|
14
14
|
import { d as defineCustomElement$p } from './p-Bxt_h1P2.js';
|
|
15
|
-
import { d as defineCustomElement$o } from './p-
|
|
16
|
-
import { d as defineCustomElement$n } from './p-
|
|
15
|
+
import { d as defineCustomElement$o } from './p-CPkh1e-n.js';
|
|
16
|
+
import { d as defineCustomElement$n } from './p-BZbrGNXl.js';
|
|
17
17
|
import { d as defineCustomElement$m } from './p-DlGX7eAs.js';
|
|
18
18
|
import { d as defineCustomElement$l } from './p-C2CsD_zr.js';
|
|
19
19
|
import { d as defineCustomElement$k } from './p-BACiQ58-.js';
|
|
@@ -21,17 +21,17 @@ import { d as defineCustomElement$j } from './p-DNHN-J6Y.js';
|
|
|
21
21
|
import { d as defineCustomElement$i } from './p-cCxwgzDB.js';
|
|
22
22
|
import { d as defineCustomElement$h } from './p-CKTvcFFn.js';
|
|
23
23
|
import { d as defineCustomElement$g } from './p-C-1aZ7t0.js';
|
|
24
|
-
import { d as defineCustomElement$f } from './p-
|
|
25
|
-
import { d as defineCustomElement$e } from './p-
|
|
24
|
+
import { d as defineCustomElement$f } from './p-2ZI4Mzgd.js';
|
|
25
|
+
import { d as defineCustomElement$e } from './p-BFXs5OQx.js';
|
|
26
26
|
import { d as defineCustomElement$d } from './p-D7OHNXA8.js';
|
|
27
27
|
import { d as defineCustomElement$b } from './p-DfRQHBer.js';
|
|
28
28
|
import { d as defineCustomElement$a } from './p-CS8aLBBd.js';
|
|
29
29
|
import { d as defineCustomElement$9 } from './p-OY7iMMA5.js';
|
|
30
|
-
import { d as defineCustomElement$8 } from './p-
|
|
30
|
+
import { d as defineCustomElement$8 } from './p-Dh_4gXYW.js';
|
|
31
31
|
import { d as defineCustomElement$7 } from './p-DB4h1B2U.js';
|
|
32
|
-
import { d as defineCustomElement$6 } from './p-
|
|
33
|
-
import { d as defineCustomElement$5 } from './p-
|
|
34
|
-
import { d as defineCustomElement$4 } from './p-
|
|
32
|
+
import { d as defineCustomElement$6 } from './p-Cy1bLMTg.js';
|
|
33
|
+
import { d as defineCustomElement$5 } from './p-Da_mcBgh.js';
|
|
34
|
+
import { d as defineCustomElement$4 } from './p-Bb8uyInh.js';
|
|
35
35
|
import { d as defineCustomElement$3 } from './p-2DRqcElr.js';
|
|
36
36
|
import { d as defineCustomElement$2 } from './p-DO22qLlU.js';
|
|
37
37
|
|
|
@@ -60,7 +60,7 @@ const Toast = /*@__PURE__*/ proxyCustomElement(class Toast extends H {
|
|
|
60
60
|
*/
|
|
61
61
|
action;
|
|
62
62
|
render() {
|
|
63
|
-
return (h(Host, { key: '
|
|
63
|
+
return (h(Host, { key: '7c2874fbba97c8fe5f6e3592ef02f5096b8776fb', onClick: () => this._onClick() }, h("div", { key: '11764a3b0c3935827929a3292c599667b95b25e3', class: indicator({ variant: this.variant }) }), h("div", { key: '80109f534d14e600643d69fe119a65ef2cc33d2f', class: content() }, h("div", { key: '681e62cb17ed77140520c65832374716e4ffa612', class: 'flex w-full min-w-0 flex-col' }, h("p", { key: '21ce7a2095920227008192e1c90e7fc8515faee3', class: 'm-0 overflow-hidden text-ellipsis whitespace-nowrap text-sm font-semibold text-white-500' }, this.header?.length ? this.header : h("slot", { name: 'header' })), h("p", { key: '1153f6ed724e56a0ed671910dc756b1e9343a249', class: 'm-0 w-full overflow-hidden text-ellipsis whitespace-nowrap text-xs text-dark-teal-200' }, this.content?.length ? this.content : h("slot", { name: 'content' }))), this.enableAction && (h("p-button", { key: '6fd6786d8474df0da1d57d7954422e59eaa71cac', variant: 'transparent', iconOnly: true, icon: this.actionIcon, iconFlip: this.actionIconFlip, iconRotate: this.actionIconRotate, class: 'flex-shrink-0' })))));
|
|
64
64
|
}
|
|
65
65
|
_onClick() {
|
|
66
66
|
if (this.enableAction) {
|
|
@@ -101,22 +101,19 @@ const Attachment = class {
|
|
|
101
101
|
_cameraFileRef;
|
|
102
102
|
render() {
|
|
103
103
|
let prefix = (h("p-icon", { key: '98d1184d2cd2c229ec68045e1a57ebc6e77b771c', class: 'text-black-teal-300', variant: 'attachment' }));
|
|
104
|
-
if (this.loading) {
|
|
105
|
-
prefix = h("p-loader", { key: 'c7b5719acde0493005d9a999773f3941e3ea0c74', color: 'white' });
|
|
106
|
-
}
|
|
107
104
|
if (this.error) {
|
|
108
|
-
prefix = (h("p-icon", { key: '
|
|
105
|
+
prefix = (h("p-icon", { key: '6bdf7a757ba3d4f9614ae0ff1d0ae4aab23bed94', variant: 'warning', class: 'text-negative-red' }));
|
|
109
106
|
}
|
|
110
107
|
// const isMobileDevice = isMobile();
|
|
111
108
|
const isMobileDevice = isTablet();
|
|
112
109
|
const baseText = 'min-w-0 flex-1 overflow-hidden text-ellipsis whitespace-nowrap text-sm';
|
|
113
|
-
return (h(Fragment, { key: '
|
|
110
|
+
return (h(Fragment, { key: 'd0c314631138f0418a71130e3506c9c24bb11f3e' }, h("p-field-container", { key: 'f11e3dc93b47c63025abde1bfc03f0cc64b6a050', variant: 'write', label: this.label, helper: this.helper, error: this.error, required: this.required, forceShowTooltip: !!this.error?.length }, h("div", { key: 'dd8fb0529546118b6e39215f83bee385bb413aec', slot: 'content', class: 'flex w-full items-start gap-2' }, h("div", { key: 'b9263a22549e5cef936ac178b2c8277caa96ffc8', class: attachment({
|
|
114
111
|
error: !!this.error?.length,
|
|
115
|
-
}) }, prefix, h("span", { key: '
|
|
112
|
+
}) }, prefix, h("span", { key: '47cc0ed86d0996a2575785f05f93e7e8075a0a7f', class: cn(baseText, 'peer empty:hidden') }, this.value), h("span", { key: '6a6c0feccdff8f71924e2461ec011ff6379f3556', class: cn(baseText, 'hidden peer-empty:block') }, this.placeholder)), h("p-tooltip", { key: '6d4fbee5737e6bfbcd03d202e4f8b7606fa4eded', content: this.mode === 'read'
|
|
116
113
|
? this.downloadTooltip
|
|
117
114
|
: this.value?.length
|
|
118
115
|
? this.deleteTooltip
|
|
119
|
-
: this.uploadTooltip }, h("p-button", { key: '
|
|
116
|
+
: this.uploadTooltip }, h("p-button", { key: 'b493da0c5ac7ae1bd791b8fc72d272cb5b10a42a', slot: 'trigger', variant: 'secondary', iconOnly: true, icon: this.mode === 'read'
|
|
120
117
|
? 'download'
|
|
121
118
|
: this.value?.length
|
|
122
119
|
? 'trash'
|
|
@@ -127,7 +124,7 @@ const Attachment = class {
|
|
|
127
124
|
: this.delete).emit() })), this.enableCameraOnMobile &&
|
|
128
125
|
this.mode === 'write' &&
|
|
129
126
|
isMobileDevice &&
|
|
130
|
-
!this.value?.length && (h("p-tooltip", { key: '
|
|
127
|
+
!this.value?.length && (h("p-tooltip", { key: '236de11a856b0f701ef79251aa2e4586ddd57900', content: this.cameraTooltip, class: 'desktop-xs:hidden' }, h("p-button", { key: '127ffe5ef98d6c5eea7be990e3631a3f066f1c7d', slot: 'trigger', variant: 'secondary', iconOnly: true, icon: 'camera', onOnClick: () => this._cameraClick() }))))), h("input", { key: '501a70ea7830308f1b53f516a0db4c671bd5aeb7', class: 'hidden', type: 'file', accept: Array.isArray(this.accept) ? this.accept?.join(',') : this.accept, ref: el => (this._fileRef = el), onChange: ev => this._onFileChange(ev) }), h("input", { key: '9be1eca163d4945987e2329d98f50a73f3f8cb2e', class: 'hidden', type: 'file', accept: 'image/*', capture: 'true', ref: el => (this._cameraFileRef = el), onChange: ev => this._onFileChange(ev) })));
|
|
131
128
|
}
|
|
132
129
|
_uploadClick() {
|
|
133
130
|
if (!this._fileRef || this.mode !== 'write') {
|