@banzamel/mineralui 2.4.2 → 2.4.3
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/README.md +1 -1
- package/dist/{MAvatar-Capz5Gbc.cjs → MAvatar-DHNB3829.cjs} +2 -2
- package/dist/{MAvatar-Capz5Gbc.cjs.map → MAvatar-DHNB3829.cjs.map} +1 -1
- package/dist/{MAvatar-DtJCj3dD.js → MAvatar-GeRL-CNO.js} +2 -2
- package/dist/{MAvatar-DtJCj3dD.js.map → MAvatar-GeRL-CNO.js.map} +1 -1
- package/dist/{MButton-C1pnL4_j.js → MButton-CEwo8lUB.js} +1 -1
- package/dist/{MButton-C1pnL4_j.js.map → MButton-CEwo8lUB.js.map} +1 -1
- package/dist/{MButton-sTKnano6.cjs → MButton-CnAr77Za.cjs} +2 -2
- package/dist/{MButton-sTKnano6.cjs.map → MButton-CnAr77Za.cjs.map} +1 -1
- package/dist/{MButtonGroup-BkNf7fzo.js → MButtonGroup-BEJxXZ8u.js} +2 -2
- package/dist/{MButtonGroup-BkNf7fzo.js.map → MButtonGroup-BEJxXZ8u.js.map} +1 -1
- package/dist/{MButtonGroup-iPv14c0V.cjs → MButtonGroup-DO1Tq3Za.cjs} +2 -2
- package/dist/{MButtonGroup-iPv14c0V.cjs.map → MButtonGroup-DO1Tq3Za.cjs.map} +1 -1
- package/dist/{MCard-azpp4YVD.js → MCard-BqSkGAgf.js} +3 -3
- package/dist/{MCard-azpp4YVD.js.map → MCard-BqSkGAgf.js.map} +1 -1
- package/dist/{MCard-DK-_FkpE.cjs → MCard-P8OoswWM.cjs} +2 -2
- package/dist/{MCard-DK-_FkpE.cjs.map → MCard-P8OoswWM.cjs.map} +1 -1
- package/dist/{MCheckbox-B7SpcD4H.js → MCheckbox-BxFBADcE.js} +1 -1
- package/dist/{MCheckbox-B7SpcD4H.js.map → MCheckbox-BxFBADcE.js.map} +1 -1
- package/dist/{MCheckbox-CIX7wp41.cjs → MCheckbox-DozwF2ai.cjs} +2 -2
- package/dist/{MCheckbox-CIX7wp41.cjs.map → MCheckbox-DozwF2ai.cjs.map} +1 -1
- package/dist/{MConflictIllustration-CZ3Md38Z.cjs → MConflictIllustration-2QL-BHYv.cjs} +2 -2
- package/dist/{MConflictIllustration-CZ3Md38Z.cjs.map → MConflictIllustration-2QL-BHYv.cjs.map} +1 -1
- package/dist/{MDetailList-Ce7KzUKC.cjs → MDetailList-CThQvoyf.cjs} +2 -2
- package/dist/{MDetailList-Ce7KzUKC.cjs.map → MDetailList-CThQvoyf.cjs.map} +1 -1
- package/dist/{MDetailList-fDhVyhm7.js → MDetailList-Cx9H81xT.js} +5 -5
- package/dist/{MDetailList-fDhVyhm7.js.map → MDetailList-Cx9H81xT.js.map} +1 -1
- package/dist/{MDropdownMenu-B_QWQhxy.cjs → MDropdownMenu-DnKcCyW6.cjs} +2 -2
- package/dist/{MDropdownMenu-B_QWQhxy.cjs.map → MDropdownMenu-DnKcCyW6.cjs.map} +1 -1
- package/dist/{MDropdownMenu-C4CuKMRZ.js → MDropdownMenu-DxbKN7Ui.js} +2 -2
- package/dist/{MDropdownMenu-C4CuKMRZ.js.map → MDropdownMenu-DxbKN7Ui.js.map} +1 -1
- package/dist/{MGrid-fTx6wFq_.cjs → MGrid-BkRSGN2t.cjs} +2 -2
- package/dist/{MGrid-fTx6wFq_.cjs.map → MGrid-BkRSGN2t.cjs.map} +1 -1
- package/dist/{MGrid-CYL3cbUI.js → MGrid-CIz-2i6X.js} +2 -2
- package/dist/{MGrid-CYL3cbUI.js.map → MGrid-CIz-2i6X.js.map} +1 -1
- package/dist/{MHeading-KDSpnCof.cjs → MHeading-AYQ8_GFP.cjs} +2 -2
- package/dist/{MHeading-KDSpnCof.cjs.map → MHeading-AYQ8_GFP.cjs.map} +1 -1
- package/dist/{MHeading-B7KgSP4T.js → MHeading-DcGxUMwC.js} +2 -2
- package/dist/{MHeading-B7KgSP4T.js.map → MHeading-DcGxUMwC.js.map} +1 -1
- package/dist/{MI18nProvider-DXRbB0VY.cjs → MI18nProvider-CqAwaswx.cjs} +2 -2
- package/dist/{MI18nProvider-DXRbB0VY.cjs.map → MI18nProvider-CqAwaswx.cjs.map} +1 -1
- package/dist/MInput-BYj2BdUe.cjs +2 -0
- package/dist/MInput-BYj2BdUe.cjs.map +1 -0
- package/dist/{MInput-C8ObGzQk.js → MInput-nodE-CZF.js} +37 -36
- package/dist/MInput-nodE-CZF.js.map +1 -0
- package/dist/MInputCVC-9XWryaTz.cjs +2 -0
- package/dist/MInputCVC-9XWryaTz.cjs.map +1 -0
- package/dist/MInputCVC-CrDTaUXm.js +321 -0
- package/dist/MInputCVC-CrDTaUXm.js.map +1 -0
- package/dist/{MInputSearch-BM8gLlJ1.js → MInputSearch-BMgCHjFk.js} +2 -2
- package/dist/{MInputSearch-BM8gLlJ1.js.map → MInputSearch-BMgCHjFk.js.map} +1 -1
- package/dist/{MInputSearch-BZDnbFB4.cjs → MInputSearch-BiVI1jNc.cjs} +2 -2
- package/dist/{MInputSearch-BZDnbFB4.cjs.map → MInputSearch-BiVI1jNc.cjs.map} +1 -1
- package/dist/{MKbd-DqMnZ7Iv.cjs → MKbd-BR1GX5oK.cjs} +2 -2
- package/dist/{MKbd-DqMnZ7Iv.cjs.map → MKbd-BR1GX5oK.cjs.map} +1 -1
- package/dist/{MKbd-v6-tJ9sP.js → MKbd-COb7oh_k.js} +1 -1
- package/dist/{MKbd-v6-tJ9sP.js.map → MKbd-COb7oh_k.js.map} +1 -1
- package/dist/{MLink-Bd8fLH1N.js → MLink-CAl6N6_z.js} +1 -1
- package/dist/{MLink-Bd8fLH1N.js.map → MLink-CAl6N6_z.js.map} +1 -1
- package/dist/{MLink-U24G6KJj.cjs → MLink-Dk_ReE6i.cjs} +2 -2
- package/dist/{MLink-U24G6KJj.cjs.map → MLink-Dk_ReE6i.cjs.map} +1 -1
- package/dist/{MLoader-CnvWqFtA.js → MLoader-CYp0OJU_.js} +4 -4
- package/dist/{MLoader-CnvWqFtA.js.map → MLoader-CYp0OJU_.js.map} +1 -1
- package/dist/{MLoader-CvFIvytw.cjs → MLoader-DvmFle31.cjs} +2 -2
- package/dist/{MLoader-CvFIvytw.cjs.map → MLoader-DvmFle31.cjs.map} +1 -1
- package/dist/{MPagination-BkvOEZpp.js → MPagination-E7IixIeo.js} +2 -2
- package/dist/{MPagination-BkvOEZpp.js.map → MPagination-E7IixIeo.js.map} +1 -1
- package/dist/{MPagination-DgQta29Q.cjs → MPagination-reDU9xTW.cjs} +2 -2
- package/dist/{MPagination-DgQta29Q.cjs.map → MPagination-reDU9xTW.cjs.map} +1 -1
- package/dist/{MPopover-Dd-GIBU6.js → MPopover-8gYD3Ogq.js} +37 -74
- package/dist/MPopover-8gYD3Ogq.js.map +1 -0
- package/dist/MPopover-B3npyAkL.cjs +2 -0
- package/dist/MPopover-B3npyAkL.cjs.map +1 -0
- package/dist/{MPortal-DUSIuINN.cjs → MPortal-CuBXhhl_.cjs} +2 -2
- package/dist/{MPortal-DUSIuINN.cjs.map → MPortal-CuBXhhl_.cjs.map} +1 -1
- package/dist/{MSimpleGrid-BzlIitcJ.cjs → MSimpleGrid-BchGYPMi.cjs} +2 -2
- package/dist/{MSimpleGrid-BzlIitcJ.cjs.map → MSimpleGrid-BchGYPMi.cjs.map} +1 -1
- package/dist/{MSimpleGrid-BWKurW6H.js → MSimpleGrid-Ui8cI0ho.js} +1 -1
- package/dist/{MSimpleGrid-BWKurW6H.js.map → MSimpleGrid-Ui8cI0ho.js.map} +1 -1
- package/dist/{MSkeleton-BoFpowFU.cjs → MSkeleton-DPa_G_2X.cjs} +2 -2
- package/dist/{MSkeleton-BoFpowFU.cjs.map → MSkeleton-DPa_G_2X.cjs.map} +1 -1
- package/dist/{MSkeleton-C5uD4Axo.js → MSkeleton-Dhu-loDO.js} +1 -1
- package/dist/{MSkeleton-C5uD4Axo.js.map → MSkeleton-Dhu-loDO.js.map} +1 -1
- package/dist/{MSlider-CqrusKJQ.js → MSlider-BRjhyBSc.js} +1 -1
- package/dist/{MSlider-CqrusKJQ.js.map → MSlider-BRjhyBSc.js.map} +1 -1
- package/dist/{MSlider-BTDBqF8t.cjs → MSlider-w5214a-W.cjs} +2 -2
- package/dist/{MSlider-BTDBqF8t.cjs.map → MSlider-w5214a-W.cjs.map} +1 -1
- package/dist/{MStack-CSCw6to2.js → MStack-Dt-rWvg3.js} +2 -2
- package/dist/{MStack-CSCw6to2.js.map → MStack-Dt-rWvg3.js.map} +1 -1
- package/dist/{MStack-B3Ldqsc-.cjs → MStack-nc6Y_9K3.cjs} +2 -2
- package/dist/{MStack-B3Ldqsc-.cjs.map → MStack-nc6Y_9K3.cjs.map} +1 -1
- package/dist/{MSubText-C-N15d4Z.js → MSubText-B0tXiuAp.js} +2 -2
- package/dist/{MSubText-C-N15d4Z.js.map → MSubText-B0tXiuAp.js.map} +1 -1
- package/dist/{MSubText-47PsgE8T.cjs → MSubText-C6v6Exa2.cjs} +2 -2
- package/dist/{MSubText-47PsgE8T.cjs.map → MSubText-C6v6Exa2.cjs.map} +1 -1
- package/dist/{MSurface-QYEygc_0.cjs → MSurface-BjE-mL1L.cjs} +2 -2
- package/dist/{MSurface-QYEygc_0.cjs.map → MSurface-BjE-mL1L.cjs.map} +1 -1
- package/dist/{MSurface-B-sjyczH.js → MSurface-CpDJCdb5.js} +2 -2
- package/dist/{MSurface-B-sjyczH.js.map → MSurface-CpDJCdb5.js.map} +1 -1
- package/dist/MTag-BgOxiahL.cjs +2 -0
- package/dist/MTag-BgOxiahL.cjs.map +1 -0
- package/dist/MTag-cw3cIGHX.js +41 -0
- package/dist/MTag-cw3cIGHX.js.map +1 -0
- package/dist/{MText-Dni707tS.cjs → MText-BDI4mdw8.cjs} +2 -2
- package/dist/{MText-Dni707tS.cjs.map → MText-BDI4mdw8.cjs.map} +1 -1
- package/dist/{MText-CL-LPcXi.js → MText-DhbAjtUE.js} +2 -2
- package/dist/{MText-CL-LPcXi.js.map → MText-DhbAjtUE.js.map} +1 -1
- package/dist/MTooltip-BAgHlv5I.cjs +2 -0
- package/dist/MTooltip-BAgHlv5I.cjs.map +1 -0
- package/dist/MTooltip-CJxvlkOX.js +92 -0
- package/dist/MTooltip-CJxvlkOX.js.map +1 -0
- package/dist/{MTreeView-B1J7uqd1.js → MTreeView-DsBnYQMT.js} +2 -2
- package/dist/{MTreeView-B1J7uqd1.js.map → MTreeView-DsBnYQMT.js.map} +1 -1
- package/dist/{MTreeView-VYp0eErQ.cjs → MTreeView-LiJ5o-zy.cjs} +2 -2
- package/dist/{MTreeView-VYp0eErQ.cjs.map → MTreeView-LiJ5o-zy.cjs.map} +1 -1
- package/dist/{arduino-BdpdaLwK.cjs → arduino-C1gw-z1N.cjs} +1 -1
- package/dist/{arduino-BdpdaLwK.cjs.map → arduino-C1gw-z1N.cjs.map} +1 -1
- package/dist/{arduino-DDDlP9Yt.js → arduino-CcVvzDWF.js} +1 -1
- package/dist/{arduino-DDDlP9Yt.js.map → arduino-CcVvzDWF.js.map} +1 -1
- package/dist/{bash-D8WbAmuA.js → bash-DkMiO80l.js} +1 -1
- package/dist/{bash-D8WbAmuA.js.map → bash-DkMiO80l.js.map} +1 -1
- package/dist/{bash-eOUFh3S1.cjs → bash-wzZkpJC-.cjs} +1 -1
- package/dist/{bash-eOUFh3S1.cjs.map → bash-wzZkpJC-.cjs.map} +1 -1
- package/dist/{c-Bur7Mn-u.cjs → c-BSPjDa0P.cjs} +1 -1
- package/dist/{c-Bur7Mn-u.cjs.map → c-BSPjDa0P.cjs.map} +1 -1
- package/dist/{c-CTKNfUJI.js → c-DtlFV5Pa.js} +1 -1
- package/dist/{c-CTKNfUJI.js.map → c-DtlFV5Pa.js.map} +1 -1
- package/dist/{calendar-bzeZRst9.js → calendar-Bq6NMNnS.js} +6 -6
- package/dist/{calendar-bzeZRst9.js.map → calendar-Bq6NMNnS.js.map} +1 -1
- package/dist/{calendar-P7MwKfWS.cjs → calendar-C57BH8Nd.cjs} +2 -2
- package/dist/{calendar-P7MwKfWS.cjs.map → calendar-C57BH8Nd.cjs.map} +1 -1
- package/dist/calendar.cjs +1 -1
- package/dist/calendar.js +1 -1
- package/dist/{calendarDates-CYkJqcnp.js → calendarDates-M_Dawj0j.js} +1 -1
- package/dist/{calendarDates-CYkJqcnp.js.map → calendarDates-M_Dawj0j.js.map} +1 -1
- package/dist/{calendarDates-AnlGcvZM.cjs → calendarDates-qm047RW2.cjs} +1 -1
- package/dist/{calendarDates-AnlGcvZM.cjs.map → calendarDates-qm047RW2.cjs.map} +1 -1
- package/dist/{cards-CFDJsdxR.js → cards-D4xJVd4q.js} +278 -277
- package/dist/cards-D4xJVd4q.js.map +1 -0
- package/dist/cards-Du6dbZSQ.cjs +2 -0
- package/dist/cards-Du6dbZSQ.cjs.map +1 -0
- package/dist/cards.cjs +1 -1
- package/dist/cards.js +2 -2
- package/dist/components/primitives/MPopover/popoverStack.d.ts +2 -0
- package/dist/{controls-BKAhqjNM.js → controls-BKoc_yel.js} +113 -112
- package/dist/controls-BKoc_yel.js.map +1 -0
- package/dist/controls-Ck-PMt__.cjs +2 -0
- package/dist/controls-Ck-PMt__.cjs.map +1 -0
- package/dist/controls.cjs +1 -1
- package/dist/controls.js +5 -5
- package/dist/{core-D5-SQcs8.js → core-B8VC-Umz.js} +1 -1
- package/dist/{core-D5-SQcs8.js.map → core-B8VC-Umz.js.map} +1 -1
- package/dist/{core-D66c1_Wo.cjs → core-w629c4ND.cjs} +1 -1
- package/dist/{core-D66c1_Wo.cjs.map → core-w629c4ND.cjs.map} +1 -1
- package/dist/{cpp-DAzz2TpY.js → cpp-BraS2arf.js} +1 -1
- package/dist/{cpp-DAzz2TpY.js.map → cpp-BraS2arf.js.map} +1 -1
- package/dist/{cpp-BMULAf-B.cjs → cpp-LIcuHkFj.cjs} +1 -1
- package/dist/{cpp-BMULAf-B.cjs.map → cpp-LIcuHkFj.cjs.map} +1 -1
- package/dist/{css-9M03GzKO.cjs → css-D6fGBtGV.cjs} +1 -1
- package/dist/{css-9M03GzKO.cjs.map → css-D6fGBtGV.cjs.map} +1 -1
- package/dist/{css-EGOXTWIl.js → css-Dy8pFAWa.js} +1 -1
- package/dist/{css-EGOXTWIl.js.map → css-Dy8pFAWa.js.map} +1 -1
- package/dist/{data-CgLutFxU.js → data-CdQximqm.js} +38 -38
- package/dist/{data-CgLutFxU.js.map → data-CdQximqm.js.map} +1 -1
- package/dist/{data-DFrkJTlF.cjs → data-PS4ygCyj.cjs} +2 -2
- package/dist/{data-DFrkJTlF.cjs.map → data-PS4ygCyj.cjs.map} +1 -1
- package/dist/data.cjs +1 -1
- package/dist/data.js +2 -2
- package/dist/{display-BnkHKW1n.js → display-YC1fVpXA.js} +19 -19
- package/dist/{display-BnkHKW1n.js.map → display-YC1fVpXA.js.map} +1 -1
- package/dist/{display--E7rI0tk.cjs → display-slIo1bQI.cjs} +2 -2
- package/dist/{display--E7rI0tk.cjs.map → display-slIo1bQI.cjs.map} +1 -1
- package/dist/display.cjs +1 -1
- package/dist/display.js +2 -2
- package/dist/dropdowns-DFbUoZ8Q.cjs +2 -0
- package/dist/dropdowns-DFbUoZ8Q.cjs.map +1 -0
- package/dist/dropdowns-nW3MY5XG.js +1715 -0
- package/dist/dropdowns-nW3MY5XG.js.map +1 -0
- package/dist/dropdowns.cjs +1 -1
- package/dist/dropdowns.js +1 -1
- package/dist/feedback-6MNb2Xyk.cjs +2 -0
- package/dist/feedback-6MNb2Xyk.cjs.map +1 -0
- package/dist/feedback-CPwJaQHY.js +259 -0
- package/dist/feedback-CPwJaQHY.js.map +1 -0
- package/dist/feedback.cjs +1 -1
- package/dist/feedback.js +5 -5
- package/dist/form-CMsZo6Dm.cjs +2 -0
- package/dist/form-CMsZo6Dm.cjs.map +1 -0
- package/dist/{form-CAFcvmUS.js → form-WU6DcQGD.js} +52 -55
- package/dist/form-WU6DcQGD.js.map +1 -0
- package/dist/form.cjs +1 -1
- package/dist/form.js +1 -1
- package/dist/frameworkTexts-BSXUtXOp.cjs +2 -0
- package/dist/{frameworkTexts-iDXhcW6k.cjs.map → frameworkTexts-BSXUtXOp.cjs.map} +1 -1
- package/dist/frameworkTexts-DP5RUl19.js +131 -0
- package/dist/{frameworkTexts-DH0Xp-Vx.js.map → frameworkTexts-DP5RUl19.js.map} +1 -1
- package/dist/i18n/frameworkTexts.d.ts +61 -0
- package/dist/i18n.cjs +1 -1
- package/dist/{icons-D_NB67he.cjs → icons-D3n9-919.cjs} +2 -2
- package/dist/{icons-D_NB67he.cjs.map → icons-D3n9-919.cjs.map} +1 -1
- package/dist/icons.cjs +1 -1
- package/dist/illustrations.cjs +1 -1
- package/dist/index.cjs +1 -1
- package/dist/index.js +40 -40
- package/dist/{inputs-B1LCddA4.js → inputs-B7rGMLMr.js} +399 -398
- package/dist/inputs-B7rGMLMr.js.map +1 -0
- package/dist/inputs-BiN62hgH.cjs +2 -0
- package/dist/inputs-BiN62hgH.cjs.map +1 -0
- package/dist/inputs.cjs +1 -1
- package/dist/inputs.js +4 -4
- package/dist/{javascript-CHSg4NGc.js → javascript-CqKLBRqa.js} +1 -1
- package/dist/{javascript-CHSg4NGc.js.map → javascript-CqKLBRqa.js.map} +1 -1
- package/dist/{javascript-CastOQF5.cjs → javascript-Oy5hkezl.cjs} +1 -1
- package/dist/{javascript-CastOQF5.cjs.map → javascript-Oy5hkezl.cjs.map} +1 -1
- package/dist/{json-DCkJ-m-p.cjs → json-BP8eqPWc.cjs} +1 -1
- package/dist/{json-DCkJ-m-p.cjs.map → json-BP8eqPWc.cjs.map} +1 -1
- package/dist/{json-Bejy9Rlg.js → json-DJkyYaPe.js} +1 -1
- package/dist/{json-Bejy9Rlg.js.map → json-DJkyYaPe.js.map} +1 -1
- package/dist/layout-BMggJ_qO.cjs +2 -0
- package/dist/layout-BMggJ_qO.cjs.map +1 -0
- package/dist/{layout-DsE4zfpg.js → layout-DBYHyCTr.js} +269 -268
- package/dist/layout-DBYHyCTr.js.map +1 -0
- package/dist/layout.cjs +1 -1
- package/dist/layout.js +6 -6
- package/dist/{layoutProps-B8y2XwHy.cjs → layoutProps-Ck4VtGm9.cjs} +1 -1
- package/dist/{layoutProps-B8y2XwHy.cjs.map → layoutProps-Ck4VtGm9.cjs.map} +1 -1
- package/dist/{layoutProps-CE5-ghKw.js → layoutProps-Cl6d1KmH.js} +1 -1
- package/dist/{layoutProps-CE5-ghKw.js.map → layoutProps-Cl6d1KmH.js.map} +1 -1
- package/dist/{licensing-DGIdtfNg.cjs → licensing-Be3g-PJt.cjs} +2 -2
- package/dist/{licensing-DGIdtfNg.cjs.map → licensing-Be3g-PJt.cjs.map} +1 -1
- package/dist/{locale-DRRl_s5-.cjs → locale-C08q7FjE.cjs} +2 -2
- package/dist/{locale-DRRl_s5-.cjs.map → locale-C08q7FjE.cjs.map} +1 -1
- package/dist/{locale-CS1-IY_I.js → locale-CjJpk9GN.js} +1 -1
- package/dist/{locale-CS1-IY_I.js.map → locale-CjJpk9GN.js.map} +1 -1
- package/dist/media-BPzMgzqE.js +405 -0
- package/dist/media-BPzMgzqE.js.map +1 -0
- package/dist/media-D63hxCAJ.cjs +2 -0
- package/dist/media-D63hxCAJ.cjs.map +1 -0
- package/dist/media.cjs +1 -1
- package/dist/media.js +2 -2
- package/dist/overlays-CCeYD6hT.js +555 -0
- package/dist/overlays-CCeYD6hT.js.map +1 -0
- package/dist/overlays-CsRN5OG8.cjs +2 -0
- package/dist/overlays-CsRN5OG8.cjs.map +1 -0
- package/dist/overlays.cjs +1 -1
- package/dist/overlays.js +3 -3
- package/dist/{php-BdVXegqn.cjs → php-Cwjc-ZYq.cjs} +1 -1
- package/dist/{php-BdVXegqn.cjs.map → php-Cwjc-ZYq.cjs.map} +1 -1
- package/dist/{php-Cb_S1hXT.js → php-Db8PWzaX.js} +1 -1
- package/dist/{php-Cb_S1hXT.js.map → php-Db8PWzaX.js.map} +1 -1
- package/dist/popoverStack--0r2oJCD.js +44 -0
- package/dist/popoverStack--0r2oJCD.js.map +1 -0
- package/dist/popoverStack-BmMk-VZJ.cjs +2 -0
- package/dist/popoverStack-BmMk-VZJ.cjs.map +1 -0
- package/dist/primitives.cjs +1 -1
- package/dist/primitives.js +1 -1
- package/dist/style-runtime.cjs +1 -1
- package/dist/style-runtime.js +1 -1
- package/dist/styles.css +1 -1
- package/dist/{theme-DgaM4CjM.cjs → theme-CJuqObWL.cjs} +2 -2
- package/dist/{theme-DgaM4CjM.cjs.map → theme-CJuqObWL.cjs.map} +1 -1
- package/dist/theme.cjs +1 -1
- package/dist/{typescript-CcGBfzlS.cjs → typescript-QKlfKtex.cjs} +1 -1
- package/dist/{typescript-CcGBfzlS.cjs.map → typescript-QKlfKtex.cjs.map} +1 -1
- package/dist/{typescript-0VHxrxf2.js → typescript-chdf_txx.js} +1 -1
- package/dist/{typescript-0VHxrxf2.js.map → typescript-chdf_txx.js.map} +1 -1
- package/dist/{typography-C4_O8len.cjs → typography-4v01oNWx.cjs} +2 -2
- package/dist/{typography-C4_O8len.cjs.map → typography-4v01oNWx.cjs.map} +1 -1
- package/dist/{typography-CAW17MDj.js → typography-C806GYT4.js} +2 -2
- package/dist/{typography-CAW17MDj.js.map → typography-C806GYT4.js.map} +1 -1
- package/dist/typography.cjs +1 -1
- package/dist/typography.js +6 -6
- package/dist/{useGhostText-Dlemg1vw.cjs → useGhostText-mibV4s1-.cjs} +2 -2
- package/dist/{useGhostText-Dlemg1vw.cjs.map → useGhostText-mibV4s1-.cjs.map} +1 -1
- package/dist/{useInteractionEffect-CFwDX5UF.cjs → useInteractionEffect-CtXlbjhC.cjs} +2 -2
- package/dist/{useInteractionEffect-CFwDX5UF.cjs.map → useInteractionEffect-CtXlbjhC.cjs.map} +1 -1
- package/dist/{useKeyboardNav-Bm-dxVq-.cjs → useKeyboardNav-CCUoRMgm.cjs} +2 -2
- package/dist/{useKeyboardNav-Bm-dxVq-.cjs.map → useKeyboardNav-CCUoRMgm.cjs.map} +1 -1
- package/dist/useModalLayer-Bf4TcEz-.js +58 -0
- package/dist/useModalLayer-Bf4TcEz-.js.map +1 -0
- package/dist/useModalLayer-DxYhhgRO.cjs +2 -0
- package/dist/useModalLayer-DxYhhgRO.cjs.map +1 -0
- package/dist/utils/useModalLayer.d.ts +10 -0
- package/dist/utils.cjs +1 -1
- package/dist/{xml-Dbm3mobK.cjs → xml-DEtyywwU.cjs} +1 -1
- package/dist/{xml-Dbm3mobK.cjs.map → xml-DEtyywwU.cjs.map} +1 -1
- package/dist/{xml-8GjNy8SM.js → xml-DnydRpfh.js} +1 -1
- package/dist/{xml-8GjNy8SM.js.map → xml-DnydRpfh.js.map} +1 -1
- package/package.json +1 -1
- package/dist/MInput-C8ObGzQk.js.map +0 -1
- package/dist/MInput-CGl2Q-rM.cjs +0 -2
- package/dist/MInput-CGl2Q-rM.cjs.map +0 -1
- package/dist/MInputCVC-Blv5PeyS.js +0 -320
- package/dist/MInputCVC-Blv5PeyS.js.map +0 -1
- package/dist/MInputCVC-lAFKTV6y.cjs +0 -2
- package/dist/MInputCVC-lAFKTV6y.cjs.map +0 -1
- package/dist/MPopover-C-e1CoV0.cjs +0 -2
- package/dist/MPopover-C-e1CoV0.cjs.map +0 -1
- package/dist/MPopover-Dd-GIBU6.js.map +0 -1
- package/dist/MTag-BjV-dXkk.cjs +0 -2
- package/dist/MTag-BjV-dXkk.cjs.map +0 -1
- package/dist/MTag-D9q6faIk.js +0 -39
- package/dist/MTag-D9q6faIk.js.map +0 -1
- package/dist/MTooltip-ChvuN4Ow.cjs +0 -2
- package/dist/MTooltip-ChvuN4Ow.cjs.map +0 -1
- package/dist/MTooltip-H3we0a7w.js +0 -57
- package/dist/MTooltip-H3we0a7w.js.map +0 -1
- package/dist/cards-CFDJsdxR.js.map +0 -1
- package/dist/cards-DeA7I2KC.cjs +0 -2
- package/dist/cards-DeA7I2KC.cjs.map +0 -1
- package/dist/controls-BKAhqjNM.js.map +0 -1
- package/dist/controls-KK-TyUTT.cjs +0 -2
- package/dist/controls-KK-TyUTT.cjs.map +0 -1
- package/dist/dropdowns-DGYg9zIh.cjs +0 -2
- package/dist/dropdowns-DGYg9zIh.cjs.map +0 -1
- package/dist/dropdowns-Dq-xAplH.js +0 -1698
- package/dist/dropdowns-Dq-xAplH.js.map +0 -1
- package/dist/feedback-CA77ShtB.cjs +0 -2
- package/dist/feedback-CA77ShtB.cjs.map +0 -1
- package/dist/feedback-CCwbdNZu.js +0 -255
- package/dist/feedback-CCwbdNZu.js.map +0 -1
- package/dist/form-CAFcvmUS.js.map +0 -1
- package/dist/form-DpfzLUOn.cjs +0 -2
- package/dist/form-DpfzLUOn.cjs.map +0 -1
- package/dist/frameworkTexts-DH0Xp-Vx.js +0 -78
- package/dist/frameworkTexts-iDXhcW6k.cjs +0 -2
- package/dist/inputs-B1LCddA4.js.map +0 -1
- package/dist/inputs-Clenc4Rm.cjs +0 -2
- package/dist/inputs-Clenc4Rm.cjs.map +0 -1
- package/dist/layout-CNoZdeXw.cjs +0 -2
- package/dist/layout-CNoZdeXw.cjs.map +0 -1
- package/dist/layout-DsE4zfpg.js.map +0 -1
- package/dist/media-DRTBXDnn.cjs +0 -2
- package/dist/media-DRTBXDnn.cjs.map +0 -1
- package/dist/media-vOQOIYFD.js +0 -402
- package/dist/media-vOQOIYFD.js.map +0 -1
- package/dist/overlays-BKk_ZXue.js +0 -568
- package/dist/overlays-BKk_ZXue.js.map +0 -1
- package/dist/overlays-Qbp4d596.cjs +0 -2
- package/dist/overlays-Qbp4d596.cjs.map +0 -1
|
@@ -1,1698 +0,0 @@
|
|
|
1
|
-
import { Ji as e, Ki as t, Li as n, Ri as r, Xi as i, qi as a } from "./icons-CBMl-kOM.js";
|
|
2
|
-
import { t as o } from "./cn-YER3QsV1.js";
|
|
3
|
-
import { a as s, i as c } from "./validators-DVYOtFnw.js";
|
|
4
|
-
import { i as l, u } from "./formatters-T0vvjMtB.js";
|
|
5
|
-
import { _ as d, a as ee, c as f, d as te, f as p, g as ne, h as m, i as h, l as g, o as _, p as v, r as re, s as ie, t as ae, u as oe } from "./dateUtils-CUY6CRCf.js";
|
|
6
|
-
import { r as se } from "./useGhostText-DG0bzcao.js";
|
|
7
|
-
import { t as ce } from "./useKeyboardNav-iEXOdEMB.js";
|
|
8
|
-
import { t as le } from "./MPopover-Dd-GIBU6.js";
|
|
9
|
-
import { r as ue } from "./MButton-C1pnL4_j.js";
|
|
10
|
-
import { t as de } from "./MCheckbox-B7SpcD4H.js";
|
|
11
|
-
import { t as y } from "./MTag-D9q6faIk.js";
|
|
12
|
-
import { t as fe } from "./MInput-C8ObGzQk.js";
|
|
13
|
-
import { t as pe } from "./locale-CS1-IY_I.js";
|
|
14
|
-
import { n as b, r as me } from "./frameworkTexts-DH0Xp-Vx.js";
|
|
15
|
-
import { i as x } from "./calendarDates-CYkJqcnp.js";
|
|
16
|
-
import { useCallback as S, useEffect as C, useMemo as w, useRef as he, useState as T } from "react";
|
|
17
|
-
import { Fragment as E, jsx as D, jsxs as O } from "react/jsx-runtime";
|
|
18
|
-
//#region src/components/dropdowns/MSelect/MSelect.tsx
|
|
19
|
-
function k({ options: e, value: n, defaultValue: r, onChange: a, multiple: s = !1, searchable: c = !1, placeholder: l = "Select...", disabled: u = !1, name: d, id: ee, variant: f = "outlined", size: te = "md", color: p, fullWidth: ne = !1, label: m, helperText: h, errorText: g, error: _ = !1, required: v = !1, loading: re = !1, clearable: ie = !1, maxHeight: ae = 300, noOptionsText: oe = "No options", renderOption: se, searchPlaceholder: fe = "Search...", renderValue: pe, className: b, style: me }) {
|
|
20
|
-
let [x, C] = T(!1), [E, k] = T(r ?? (s ? [] : "")), [A, j] = T(""), ge = he(null), M = n === void 0 ? E : n, N = _ || !!g, P = w(() => Array.isArray(M) ? M : M ? [M] : [], [M]), F = w(() => e.filter((e) => P.includes(e.value)), [e, P]), I = w(() => {
|
|
21
|
-
if (!c || !A) return e;
|
|
22
|
-
let t = A.toLowerCase();
|
|
23
|
-
return e.filter((e) => e.label.toLowerCase().includes(t));
|
|
24
|
-
}, [
|
|
25
|
-
e,
|
|
26
|
-
c,
|
|
27
|
-
A
|
|
28
|
-
]), L = w(() => {
|
|
29
|
-
let e = /* @__PURE__ */ new Map();
|
|
30
|
-
for (let t of I) {
|
|
31
|
-
let n = t.group ?? "";
|
|
32
|
-
e.has(n) || e.set(n, []), e.get(n).push(t);
|
|
33
|
-
}
|
|
34
|
-
return e;
|
|
35
|
-
}, [I]), R = I, _e = S((e) => {
|
|
36
|
-
let t = R[e];
|
|
37
|
-
if (!(!t || t.disabled)) if (s) {
|
|
38
|
-
let e = Array.isArray(M) ? M : [], r = e.includes(t.value) ? e.filter((e) => e !== t.value) : [...e, t.value];
|
|
39
|
-
n === void 0 && k(r), a?.(r);
|
|
40
|
-
} else n === void 0 && k(t.value), a?.(t.value), C(!1), j("");
|
|
41
|
-
}, [
|
|
42
|
-
R,
|
|
43
|
-
s,
|
|
44
|
-
M,
|
|
45
|
-
n,
|
|
46
|
-
a
|
|
47
|
-
]), { activeIndex: ve, setActiveIndex: z, resetIndex: B, onKeyDown: V } = ce({
|
|
48
|
-
itemCount: R.length,
|
|
49
|
-
onSelect: _e,
|
|
50
|
-
onClose: () => {
|
|
51
|
-
C(!1), j("");
|
|
52
|
-
},
|
|
53
|
-
isOpen: x
|
|
54
|
-
}), H = S(() => {
|
|
55
|
-
u || (C((e) => !e), B());
|
|
56
|
-
}, [u, B]), ye = S((e) => {
|
|
57
|
-
e.stopPropagation();
|
|
58
|
-
let t = s ? [] : "";
|
|
59
|
-
n === void 0 && k(t), a?.(t);
|
|
60
|
-
}, [
|
|
61
|
-
s,
|
|
62
|
-
n,
|
|
63
|
-
a
|
|
64
|
-
]), be = w(() => pe && F.length > 0 ? pe(s ? F : F[0]) : s && F.length > 0 ? /* @__PURE__ */ D("span", {
|
|
65
|
-
className: "tags",
|
|
66
|
-
children: F.map((e) => /* @__PURE__ */ D(y, {
|
|
67
|
-
label: e.label,
|
|
68
|
-
color: p,
|
|
69
|
-
size: te,
|
|
70
|
-
variant: "solid"
|
|
71
|
-
}, e.value))
|
|
72
|
-
}) : !s && F.length > 0 ? F[0].label : /* @__PURE__ */ D("span", {
|
|
73
|
-
className: "placeholder",
|
|
74
|
-
children: l
|
|
75
|
-
}), [
|
|
76
|
-
F,
|
|
77
|
-
s,
|
|
78
|
-
pe,
|
|
79
|
-
l,
|
|
80
|
-
p,
|
|
81
|
-
te
|
|
82
|
-
]);
|
|
83
|
-
return /* @__PURE__ */ O("div", {
|
|
84
|
-
className: o("select", p && `color-${p}`, ne && "full-width", b),
|
|
85
|
-
style: me,
|
|
86
|
-
children: [
|
|
87
|
-
m && /* @__PURE__ */ D("label", {
|
|
88
|
-
htmlFor: ee,
|
|
89
|
-
className: o("field-label", x && "focused", N && "error", v && "required"),
|
|
90
|
-
children: m
|
|
91
|
-
}),
|
|
92
|
-
/* @__PURE__ */ O("div", {
|
|
93
|
-
ref: ge,
|
|
94
|
-
className: o("trigger", `field-${f}`, `field-${te}`, x && "focused", N && "error", u && "disabled"),
|
|
95
|
-
onClick: H,
|
|
96
|
-
onKeyDown: V,
|
|
97
|
-
tabIndex: u ? -1 : 0,
|
|
98
|
-
role: "combobox",
|
|
99
|
-
"aria-expanded": x,
|
|
100
|
-
"aria-haspopup": "listbox",
|
|
101
|
-
"aria-invalid": N || void 0,
|
|
102
|
-
id: ee,
|
|
103
|
-
children: [
|
|
104
|
-
/* @__PURE__ */ D("span", {
|
|
105
|
-
className: "value",
|
|
106
|
-
children: be
|
|
107
|
-
}),
|
|
108
|
-
re && /* @__PURE__ */ D(ue, {
|
|
109
|
-
size: "sm",
|
|
110
|
-
color: p
|
|
111
|
-
}),
|
|
112
|
-
ie && P.length > 0 && !re && !u && /* @__PURE__ */ D("button", {
|
|
113
|
-
type: "button",
|
|
114
|
-
className: "clear-btn clear-btn-base",
|
|
115
|
-
onClick: ye,
|
|
116
|
-
tabIndex: -1,
|
|
117
|
-
"aria-label": "Clear selection",
|
|
118
|
-
children: /* @__PURE__ */ D(i, {})
|
|
119
|
-
}),
|
|
120
|
-
/* @__PURE__ */ D("span", {
|
|
121
|
-
className: o("arrow", x && "open"),
|
|
122
|
-
"aria-hidden": "true",
|
|
123
|
-
children: /* @__PURE__ */ D(t, {})
|
|
124
|
-
})
|
|
125
|
-
]
|
|
126
|
-
}),
|
|
127
|
-
d && /* @__PURE__ */ D("input", {
|
|
128
|
-
type: "hidden",
|
|
129
|
-
name: d,
|
|
130
|
-
value: Array.isArray(M) ? M.join(",") : M
|
|
131
|
-
}),
|
|
132
|
-
/* @__PURE__ */ D(le, {
|
|
133
|
-
className: "select-popover",
|
|
134
|
-
open: x,
|
|
135
|
-
anchorRef: ge,
|
|
136
|
-
onClose: () => {
|
|
137
|
-
C(!1), j("");
|
|
138
|
-
},
|
|
139
|
-
matchWidth: !0,
|
|
140
|
-
placement: "bottom-start",
|
|
141
|
-
children: /* @__PURE__ */ O("div", {
|
|
142
|
-
style: { maxHeight: ae },
|
|
143
|
-
className: "dropdown",
|
|
144
|
-
children: [c && /* @__PURE__ */ D("div", {
|
|
145
|
-
className: "search-box",
|
|
146
|
-
children: /* @__PURE__ */ D("input", {
|
|
147
|
-
type: "text",
|
|
148
|
-
className: "search-input",
|
|
149
|
-
placeholder: fe,
|
|
150
|
-
value: A,
|
|
151
|
-
onChange: (e) => {
|
|
152
|
-
j(e.target.value), z(0);
|
|
153
|
-
},
|
|
154
|
-
onKeyDown: V,
|
|
155
|
-
autoFocus: !0
|
|
156
|
-
})
|
|
157
|
-
}), R.length === 0 ? /* @__PURE__ */ D("div", {
|
|
158
|
-
className: "no-options",
|
|
159
|
-
children: oe
|
|
160
|
-
}) : /* @__PURE__ */ D("div", {
|
|
161
|
-
className: "options-list",
|
|
162
|
-
role: "listbox",
|
|
163
|
-
children: [...L.entries()].map(([e, t]) => /* @__PURE__ */ O("div", { children: [e && /* @__PURE__ */ D("div", {
|
|
164
|
-
className: "group-header",
|
|
165
|
-
children: e
|
|
166
|
-
}), t.map((e) => {
|
|
167
|
-
let t = R.indexOf(e), n = t === ve, r = P.includes(e.value);
|
|
168
|
-
return /* @__PURE__ */ O("div", {
|
|
169
|
-
className: o("option", n && "active", r && "selected", e.disabled && "disabled"),
|
|
170
|
-
onClick: () => !e.disabled && _e(t),
|
|
171
|
-
onMouseEnter: () => z(t),
|
|
172
|
-
role: "option",
|
|
173
|
-
"aria-selected": r,
|
|
174
|
-
"aria-disabled": e.disabled,
|
|
175
|
-
children: [s && /* @__PURE__ */ D(de, {
|
|
176
|
-
checked: r,
|
|
177
|
-
size: "sm",
|
|
178
|
-
color: p,
|
|
179
|
-
clickEffect: "none",
|
|
180
|
-
className: "select-check"
|
|
181
|
-
}), se ? se(e, n, r) : e.label]
|
|
182
|
-
}, e.value);
|
|
183
|
-
})] }, e))
|
|
184
|
-
})]
|
|
185
|
-
})
|
|
186
|
-
}),
|
|
187
|
-
(g || h) && /* @__PURE__ */ D("div", {
|
|
188
|
-
className: "bottom-row",
|
|
189
|
-
children: g ? /* @__PURE__ */ D("span", {
|
|
190
|
-
className: "field-error",
|
|
191
|
-
role: "alert",
|
|
192
|
-
children: g
|
|
193
|
-
}) : /* @__PURE__ */ D("span", {
|
|
194
|
-
className: "helper-text",
|
|
195
|
-
children: h
|
|
196
|
-
})
|
|
197
|
-
})
|
|
198
|
-
]
|
|
199
|
-
});
|
|
200
|
-
}
|
|
201
|
-
//#endregion
|
|
202
|
-
//#region src/components/dropdowns/MAutocomplete/MAutocomplete.tsx
|
|
203
|
-
function A(e) {
|
|
204
|
-
return typeof e == "string" ? e : String(e);
|
|
205
|
-
}
|
|
206
|
-
function j(e) {
|
|
207
|
-
return typeof e == "string" ? e : String(e);
|
|
208
|
-
}
|
|
209
|
-
function ge(e, t, n) {
|
|
210
|
-
if (!t) return e;
|
|
211
|
-
let r = t.toLowerCase();
|
|
212
|
-
return e.filter((e) => n(e).toLowerCase().includes(r));
|
|
213
|
-
}
|
|
214
|
-
function M({ options: e, value: t, onChange: n, getOptionLabel: r = A, getOptionValue: a = j, filterOptions: s, multiple: c = !1, debounceMs: l = 0, onInputChange: u, loading: d = !1, loadingText: ee = "Loading...", noOptionsText: f = "No options", placeholder: te = "Type to search...", disabled: p = !1, name: ne, id: m, variant: h = "outlined", size: g = "md", color: _, fullWidth: v = !1, label: re, helperText: ie, errorText: ae, error: oe = !1, required: de = !1, clearable: fe = !1, maxHeight: pe = 300, renderOption: b, renderTags: me, className: x, style: C }) {
|
|
215
|
-
let [E, k] = T(!1), [M, N] = T(""), P = he(null), F = he(null), I = oe || !!ae, L = w(() => t == null ? [] : Array.isArray(t) ? t.filter((e) => e != null) : [t], [t]), R = w(() => s ? s(e, M) : ge(e, M, r), [
|
|
216
|
-
e,
|
|
217
|
-
M,
|
|
218
|
-
s,
|
|
219
|
-
r
|
|
220
|
-
]), _e = se((e) => u?.(e), l), ve = S((e) => {
|
|
221
|
-
N(e.target.value), _e(e.target.value), E || k(!0);
|
|
222
|
-
}, [E, _e]), z = S((e) => {
|
|
223
|
-
let t = R[e];
|
|
224
|
-
if (t) if (c) {
|
|
225
|
-
let e = [...L], r = a(t), i = e.findIndex((e) => a(e) === r);
|
|
226
|
-
i >= 0 ? e.splice(i, 1) : e.push(t), n?.(e), N(""), F.current?.focus();
|
|
227
|
-
} else n?.(t), N(r(t)), k(!1);
|
|
228
|
-
}, [
|
|
229
|
-
R,
|
|
230
|
-
c,
|
|
231
|
-
L,
|
|
232
|
-
a,
|
|
233
|
-
r,
|
|
234
|
-
n
|
|
235
|
-
]), B = S((e) => {
|
|
236
|
-
let t = [...L];
|
|
237
|
-
t.splice(e, 1), n?.(c ? t : t[0] ?? "");
|
|
238
|
-
}, [
|
|
239
|
-
L,
|
|
240
|
-
n,
|
|
241
|
-
c
|
|
242
|
-
]), { activeIndex: V, setActiveIndex: H, resetIndex: ye, onKeyDown: be } = ce({
|
|
243
|
-
itemCount: R.length,
|
|
244
|
-
onSelect: z,
|
|
245
|
-
onClose: () => k(!1),
|
|
246
|
-
isOpen: E
|
|
247
|
-
}), U = S((e) => {
|
|
248
|
-
if (e.key === "Backspace" && c && !M && L.length > 0) {
|
|
249
|
-
B(L.length - 1);
|
|
250
|
-
return;
|
|
251
|
-
}
|
|
252
|
-
be(e);
|
|
253
|
-
}, [
|
|
254
|
-
M,
|
|
255
|
-
c,
|
|
256
|
-
L,
|
|
257
|
-
be,
|
|
258
|
-
B
|
|
259
|
-
]), W = S((e) => {
|
|
260
|
-
e.stopPropagation(), N(""), n?.(c ? [] : ""), F.current?.focus();
|
|
261
|
-
}, [c, n]);
|
|
262
|
-
return /* @__PURE__ */ O("div", {
|
|
263
|
-
className: o("autocomplete", _ && `color-${_}`, v && "full-width", x),
|
|
264
|
-
style: C,
|
|
265
|
-
children: [
|
|
266
|
-
re && /* @__PURE__ */ D("label", {
|
|
267
|
-
htmlFor: m,
|
|
268
|
-
className: o("field-label", E && "focused", I && "error", de && "required"),
|
|
269
|
-
children: re
|
|
270
|
-
}),
|
|
271
|
-
/* @__PURE__ */ O("div", {
|
|
272
|
-
ref: P,
|
|
273
|
-
className: o("input-wrapper", `field-${h}`, `field-${g}`, E && "focused", I && "error", p && "disabled"),
|
|
274
|
-
onClick: () => F.current?.focus(),
|
|
275
|
-
children: [
|
|
276
|
-
c && L.length > 0 && (me ? me(L, B) : /* @__PURE__ */ D("span", {
|
|
277
|
-
className: "tags",
|
|
278
|
-
children: L.map((e, t) => /* @__PURE__ */ D(y, {
|
|
279
|
-
label: r(e),
|
|
280
|
-
color: _,
|
|
281
|
-
size: g,
|
|
282
|
-
variant: "solid",
|
|
283
|
-
closable: !0,
|
|
284
|
-
onClose: () => B(t)
|
|
285
|
-
}, a(e)))
|
|
286
|
-
})),
|
|
287
|
-
/* @__PURE__ */ D("input", {
|
|
288
|
-
ref: F,
|
|
289
|
-
type: "text",
|
|
290
|
-
className: "input",
|
|
291
|
-
value: M,
|
|
292
|
-
onChange: ve,
|
|
293
|
-
onFocus: () => {
|
|
294
|
-
k(!0), ye();
|
|
295
|
-
},
|
|
296
|
-
onKeyDown: U,
|
|
297
|
-
placeholder: L.length > 0 ? "" : te,
|
|
298
|
-
disabled: p,
|
|
299
|
-
id: m,
|
|
300
|
-
"aria-expanded": E,
|
|
301
|
-
"aria-haspopup": "listbox",
|
|
302
|
-
"aria-invalid": I || void 0,
|
|
303
|
-
autoComplete: "off"
|
|
304
|
-
}),
|
|
305
|
-
d && /* @__PURE__ */ D(ue, {
|
|
306
|
-
size: "sm",
|
|
307
|
-
color: _
|
|
308
|
-
}),
|
|
309
|
-
fe && (L.length > 0 || M) && !d && !p && /* @__PURE__ */ D("button", {
|
|
310
|
-
type: "button",
|
|
311
|
-
className: "clear-btn clear-btn-base",
|
|
312
|
-
onClick: W,
|
|
313
|
-
tabIndex: -1,
|
|
314
|
-
children: /* @__PURE__ */ D(i, {})
|
|
315
|
-
})
|
|
316
|
-
]
|
|
317
|
-
}),
|
|
318
|
-
ne && /* @__PURE__ */ D("input", {
|
|
319
|
-
type: "hidden",
|
|
320
|
-
name: ne,
|
|
321
|
-
value: L.map(a).join(",")
|
|
322
|
-
}),
|
|
323
|
-
/* @__PURE__ */ D(le, {
|
|
324
|
-
className: o("autocomplete-popover", _ && `color-${_}`),
|
|
325
|
-
open: E && (R.length > 0 || d || !!M),
|
|
326
|
-
anchorRef: P,
|
|
327
|
-
onClose: () => k(!1),
|
|
328
|
-
matchWidth: !0,
|
|
329
|
-
placement: "bottom-start",
|
|
330
|
-
children: /* @__PURE__ */ D("div", {
|
|
331
|
-
style: { maxHeight: pe },
|
|
332
|
-
className: "dropdown",
|
|
333
|
-
children: d ? /* @__PURE__ */ D("div", {
|
|
334
|
-
className: "loading-msg",
|
|
335
|
-
children: ee
|
|
336
|
-
}) : R.length === 0 ? /* @__PURE__ */ D("div", {
|
|
337
|
-
className: "no-options",
|
|
338
|
-
children: f
|
|
339
|
-
}) : /* @__PURE__ */ D("div", {
|
|
340
|
-
className: "options-list",
|
|
341
|
-
role: "listbox",
|
|
342
|
-
children: R.map((e, t) => {
|
|
343
|
-
let n = t === V, i = L.some((t) => a(t) === a(e));
|
|
344
|
-
return /* @__PURE__ */ D("div", {
|
|
345
|
-
className: o("option", n && "active", i && "selected"),
|
|
346
|
-
onClick: () => z(t),
|
|
347
|
-
onMouseEnter: () => H(t),
|
|
348
|
-
role: "option",
|
|
349
|
-
"aria-selected": i,
|
|
350
|
-
children: b ? b(e, n) : r(e)
|
|
351
|
-
}, a(e));
|
|
352
|
-
})
|
|
353
|
-
})
|
|
354
|
-
})
|
|
355
|
-
}),
|
|
356
|
-
(ae || ie) && /* @__PURE__ */ D("div", {
|
|
357
|
-
className: "bottom-row",
|
|
358
|
-
children: ae ? /* @__PURE__ */ D("span", {
|
|
359
|
-
className: "field-error",
|
|
360
|
-
role: "alert",
|
|
361
|
-
children: ae
|
|
362
|
-
}) : /* @__PURE__ */ D("span", {
|
|
363
|
-
className: "helper-text",
|
|
364
|
-
children: ie
|
|
365
|
-
})
|
|
366
|
-
})
|
|
367
|
-
]
|
|
368
|
-
});
|
|
369
|
-
}
|
|
370
|
-
//#endregion
|
|
371
|
-
//#region src/utils/colorRgbVar.ts
|
|
372
|
-
var N = {
|
|
373
|
-
primary: "var(--mineral-primary-rgb)",
|
|
374
|
-
neutral: "var(--mineral-neutral-rgb)",
|
|
375
|
-
success: "var(--mineral-success-rgb)",
|
|
376
|
-
error: "var(--mineral-error-rgb)",
|
|
377
|
-
warning: "var(--mineral-warning-rgb)",
|
|
378
|
-
info: "var(--mineral-info-rgb)",
|
|
379
|
-
light: "var(--mineral-light-rgb)",
|
|
380
|
-
dark: "var(--mineral-dark-color-rgb)",
|
|
381
|
-
news: "var(--mineral-news-rgb)"
|
|
382
|
-
};
|
|
383
|
-
function P(e) {
|
|
384
|
-
return N[e ?? "primary"] ?? N.primary;
|
|
385
|
-
}
|
|
386
|
-
//#endregion
|
|
387
|
-
//#region src/components/dropdowns/MDatePicker/MDatePicker.tsx
|
|
388
|
-
var F = "Date is unavailable", I = "Invalid time";
|
|
389
|
-
function L(e) {
|
|
390
|
-
if (!e) return null;
|
|
391
|
-
if (e instanceof Date) return isNaN(e.getTime()) ? null : new Date(e.getTime());
|
|
392
|
-
let t = new Date(e);
|
|
393
|
-
return isNaN(t.getTime()) ? null : t;
|
|
394
|
-
}
|
|
395
|
-
function R(e) {
|
|
396
|
-
let t = e.replace(/DD/g, "dd").replace(/YYYY/g, "yyyy"), n = t.match(/dd|MM|yyyy/g), r = t.match(/[^dMy]/)?.[0], i = r === "/" || r === "." || r === "-" ? r : ".";
|
|
397
|
-
switch (n?.join("/")) {
|
|
398
|
-
case "MM/dd/yyyy": return {
|
|
399
|
-
inputFormat: "MM/DD/YYYY",
|
|
400
|
-
separator: i
|
|
401
|
-
};
|
|
402
|
-
case "yyyy/MM/dd": return {
|
|
403
|
-
inputFormat: "YYYY/MM/DD",
|
|
404
|
-
separator: i
|
|
405
|
-
};
|
|
406
|
-
default: return {
|
|
407
|
-
inputFormat: "DD/MM/YYYY",
|
|
408
|
-
separator: i
|
|
409
|
-
};
|
|
410
|
-
}
|
|
411
|
-
}
|
|
412
|
-
function _e(e, t) {
|
|
413
|
-
return e === "12h" ? t ? "hh:mm:ss AM" : "hh:mm AM" : t ? "HH:MM:SS" : "HH:MM";
|
|
414
|
-
}
|
|
415
|
-
function ve(e, t, n, r, i, a) {
|
|
416
|
-
return e || (n ? `${t} ${a ?? _e(r, i)}` : t);
|
|
417
|
-
}
|
|
418
|
-
function z(e, t) {
|
|
419
|
-
if (!e) return "";
|
|
420
|
-
let n = _(d(e), t.format);
|
|
421
|
-
return t.withTime ? `${n} ${g(e.getHours(), e.getMinutes(), e.getSeconds(), t.showSeconds, t.timeFormat)}` : n;
|
|
422
|
-
}
|
|
423
|
-
function B(e, t) {
|
|
424
|
-
return e ? e.length <= 2 ? e : e.length <= 4 ? `${e.slice(0, 2)}:${e.slice(2)}` : t ? `${e.slice(0, 2)}:${e.slice(2, 4)}:${e.slice(4, 6)}` : `${e.slice(0, 2)}:${e.slice(2, 4)}` : "";
|
|
425
|
-
}
|
|
426
|
-
function V(e) {
|
|
427
|
-
let t = e.toUpperCase().replace(/[^APM]/g, "");
|
|
428
|
-
return t ? t.startsWith("AM") ? "AM" : t.startsWith("PM") ? "PM" : t.startsWith("A") ? "A" : t.startsWith("P") ? "P" : "" : "";
|
|
429
|
-
}
|
|
430
|
-
function H(e, t) {
|
|
431
|
-
let n = e.trim();
|
|
432
|
-
if (!n) return {
|
|
433
|
-
datePart: "",
|
|
434
|
-
timePart: ""
|
|
435
|
-
};
|
|
436
|
-
if (!t) return {
|
|
437
|
-
datePart: n,
|
|
438
|
-
timePart: ""
|
|
439
|
-
};
|
|
440
|
-
let r = n.indexOf(" ");
|
|
441
|
-
return r === -1 ? {
|
|
442
|
-
datePart: n,
|
|
443
|
-
timePart: ""
|
|
444
|
-
} : {
|
|
445
|
-
datePart: n.slice(0, r).trim(),
|
|
446
|
-
timePart: n.slice(r + 1).trim()
|
|
447
|
-
};
|
|
448
|
-
}
|
|
449
|
-
function ye(e, t) {
|
|
450
|
-
let n = e.toUpperCase(), r = u(n), i = r.slice(0, 8), a = t.withTime ? r.slice(8, 8 + (t.showSeconds ? 6 : 4)) : "", o = l(i, t.inputFormat, t.separator);
|
|
451
|
-
if (!t.withTime) return {
|
|
452
|
-
formatted: o,
|
|
453
|
-
datePart: o,
|
|
454
|
-
timePart: ""
|
|
455
|
-
};
|
|
456
|
-
let s = B(a, t.showSeconds), c = t.timeFormat === "12h" ? V(n) : "", d = `${s}${c ? `${s ? " " : ""}${c}` : ""}`.trim();
|
|
457
|
-
if (!o) return {
|
|
458
|
-
formatted: d,
|
|
459
|
-
datePart: "",
|
|
460
|
-
timePart: d
|
|
461
|
-
};
|
|
462
|
-
let ee = i.length === 8, f = /\s/.test(n.slice(o.length));
|
|
463
|
-
return {
|
|
464
|
-
formatted: d || ee && f ? `${o} ${d}` : o,
|
|
465
|
-
datePart: o,
|
|
466
|
-
timePart: d
|
|
467
|
-
};
|
|
468
|
-
}
|
|
469
|
-
function be(e, t) {
|
|
470
|
-
return e ? g(e.getHours(), e.getMinutes(), e.getSeconds(), t, "24h") : "";
|
|
471
|
-
}
|
|
472
|
-
function U(e, t) {
|
|
473
|
-
let { datePart: n, timePart: r } = H(e, t.withTime);
|
|
474
|
-
if (!n && !r) return { status: "empty" };
|
|
475
|
-
let i = s(n, {
|
|
476
|
-
format: t.inputFormat,
|
|
477
|
-
minDate: t.minDate ?? void 0,
|
|
478
|
-
maxDate: t.maxDate ?? void 0
|
|
479
|
-
});
|
|
480
|
-
if (!i.valid) return i.error === "Incomplete date" ? {
|
|
481
|
-
status: "partial",
|
|
482
|
-
datePart: n,
|
|
483
|
-
timePart: r
|
|
484
|
-
} : {
|
|
485
|
-
status: "invalid",
|
|
486
|
-
datePart: n,
|
|
487
|
-
timePart: r,
|
|
488
|
-
result: i
|
|
489
|
-
};
|
|
490
|
-
let a = c(n, t.inputFormat);
|
|
491
|
-
return a ? t.isDisabled(a) ? {
|
|
492
|
-
status: "invalid",
|
|
493
|
-
datePart: n,
|
|
494
|
-
timePart: r,
|
|
495
|
-
result: {
|
|
496
|
-
valid: !1,
|
|
497
|
-
error: F
|
|
498
|
-
}
|
|
499
|
-
} : t.withTime ? r ? ne(r, t.timeFormat) ? {
|
|
500
|
-
status: "valid",
|
|
501
|
-
datePart: n,
|
|
502
|
-
timePart: r,
|
|
503
|
-
value: re(a, r, {
|
|
504
|
-
format: t.timeFormat,
|
|
505
|
-
showSeconds: t.showSeconds
|
|
506
|
-
})
|
|
507
|
-
} : {
|
|
508
|
-
status: "invalid",
|
|
509
|
-
datePart: n,
|
|
510
|
-
timePart: r,
|
|
511
|
-
result: {
|
|
512
|
-
valid: !1,
|
|
513
|
-
error: I
|
|
514
|
-
}
|
|
515
|
-
} : {
|
|
516
|
-
status: "valid",
|
|
517
|
-
datePart: n,
|
|
518
|
-
timePart: "",
|
|
519
|
-
value: re(a, "", {
|
|
520
|
-
format: t.timeFormat,
|
|
521
|
-
showSeconds: t.showSeconds
|
|
522
|
-
})
|
|
523
|
-
} : {
|
|
524
|
-
status: "valid",
|
|
525
|
-
datePart: n,
|
|
526
|
-
timePart: "",
|
|
527
|
-
value: d(a)
|
|
528
|
-
} : {
|
|
529
|
-
status: "invalid",
|
|
530
|
-
datePart: n,
|
|
531
|
-
timePart: r,
|
|
532
|
-
result: {
|
|
533
|
-
valid: !1,
|
|
534
|
-
error: "Invalid date"
|
|
535
|
-
}
|
|
536
|
-
};
|
|
537
|
-
}
|
|
538
|
-
function W(e) {
|
|
539
|
-
let t = e.hours >= 12 ? "PM" : "AM";
|
|
540
|
-
return {
|
|
541
|
-
hours: e.hours % 12 || 12,
|
|
542
|
-
minutes: e.minutes,
|
|
543
|
-
seconds: e.seconds,
|
|
544
|
-
meridiem: t
|
|
545
|
-
};
|
|
546
|
-
}
|
|
547
|
-
function xe(e, t) {
|
|
548
|
-
return t === "AM" ? e === 12 ? 0 : e : e === 12 ? 12 : e + 12;
|
|
549
|
-
}
|
|
550
|
-
function Se({ value: t, defaultValue: n, onChange: i, format: s = "dd.MM.yyyy", locale: c, min: l, max: ee, disabledDates: f, placeholder: m, disabled: h = !1, readOnly: _ = !1, name: se, id: ce, variant: ue = "outlined", size: de = "md", color: y, label: me, helperText: k, errorText: A, error: j = !1, required: ge = !1, clearable: M = !1, withTime: N = !1, validateOnBlur: F = !0, validateOnChange: _e = !1, onValidationChange: B, timeFormat: V = "24h", showSeconds: H = !1, minuteStep: Se = 1, timePlaceholder: G, inline: we = !1, showTodayButton: Te = !0, firstDayOfWeek: Ee = 1, fullWidth: De = !1, className: Oe, style: ke }) {
|
|
551
|
-
let K = pe(c), Ae = b(), { inputFormat: q, separator: je } = w(() => R(s), [s]), [Me, J] = T(!1), [Ne, Pe] = T(() => L(n)), [Fe, Ie] = T({ valid: !0 }), [Le, Re] = T(!1), Y = t === void 0 ? Ne : L(t), [ze, Be] = T(() => z(Y, {
|
|
552
|
-
format: s,
|
|
553
|
-
withTime: N,
|
|
554
|
-
timeFormat: V,
|
|
555
|
-
showSeconds: H
|
|
556
|
-
})), [Ve, He] = T(() => be(Y, H)), [Ue, We] = T(() => {
|
|
557
|
-
let e = Y ? d(Y) : /* @__PURE__ */ new Date();
|
|
558
|
-
return new Date(e.getFullYear(), e.getMonth(), 1);
|
|
559
|
-
}), [Ge, Ke] = T("days"), qe = he(null), Je = Y?.getTime() ?? null, Ye = L(l), Xe = L(ee), Ze = j || Le && !Fe.valid, Qe = A || (Le && !Fe.valid ? Fe.error : void 0), $e = oe(K, Ee), et = te(K);
|
|
560
|
-
C(() => {
|
|
561
|
-
if (Be(z(Y, {
|
|
562
|
-
format: s,
|
|
563
|
-
withTime: N,
|
|
564
|
-
timeFormat: V,
|
|
565
|
-
showSeconds: H
|
|
566
|
-
})), He(be(Y, H)), Y) {
|
|
567
|
-
let e = d(Y);
|
|
568
|
-
We(new Date(e.getFullYear(), e.getMonth(), 1));
|
|
569
|
-
}
|
|
570
|
-
}, [
|
|
571
|
-
s,
|
|
572
|
-
Je,
|
|
573
|
-
H,
|
|
574
|
-
V,
|
|
575
|
-
N
|
|
576
|
-
]);
|
|
577
|
-
let X = S((e) => p(e, Ye, Xe) ? Array.isArray(f) ? f.some((t) => v(t, e)) : typeof f == "function" ? f(e) : !1 : !0, [
|
|
578
|
-
f,
|
|
579
|
-
Xe,
|
|
580
|
-
Ye
|
|
581
|
-
]), Z = S((e) => {
|
|
582
|
-
Ie(e), B?.(e);
|
|
583
|
-
}, [B]), Q = S((e) => {
|
|
584
|
-
t === void 0 && Pe(e), i?.(e);
|
|
585
|
-
}, [i, t]), tt = w(() => U(ze, {
|
|
586
|
-
inputFormat: q,
|
|
587
|
-
minDate: Ye,
|
|
588
|
-
maxDate: Xe,
|
|
589
|
-
withTime: N,
|
|
590
|
-
timeFormat: V,
|
|
591
|
-
showSeconds: H,
|
|
592
|
-
isDisabled: X
|
|
593
|
-
}), [
|
|
594
|
-
q,
|
|
595
|
-
ze,
|
|
596
|
-
X,
|
|
597
|
-
Xe,
|
|
598
|
-
Ye,
|
|
599
|
-
H,
|
|
600
|
-
V,
|
|
601
|
-
N
|
|
602
|
-
]), nt = w(() => tt.status === "valid" ? d(tt.value) : Y ? d(Y) : null, [tt, Y]), $ = w(() => N ? ne(tt.status !== "empty" && tt.timePart ? tt.timePart : Ve || be(Y, H), V) ?? {
|
|
603
|
-
hours: 0,
|
|
604
|
-
minutes: 0,
|
|
605
|
-
seconds: 0
|
|
606
|
-
} : null, [
|
|
607
|
-
Ve,
|
|
608
|
-
tt,
|
|
609
|
-
Y,
|
|
610
|
-
H,
|
|
611
|
-
V,
|
|
612
|
-
N
|
|
613
|
-
]), rt = S((e) => {
|
|
614
|
-
let t = ye(e.target.value, {
|
|
615
|
-
inputFormat: q,
|
|
616
|
-
separator: je,
|
|
617
|
-
withTime: N,
|
|
618
|
-
timeFormat: V,
|
|
619
|
-
showSeconds: H
|
|
620
|
-
});
|
|
621
|
-
Be(t.formatted), He(t.timePart);
|
|
622
|
-
let n = U(t.formatted, {
|
|
623
|
-
inputFormat: q,
|
|
624
|
-
minDate: Ye,
|
|
625
|
-
maxDate: Xe,
|
|
626
|
-
withTime: N,
|
|
627
|
-
timeFormat: V,
|
|
628
|
-
showSeconds: H,
|
|
629
|
-
isDisabled: X
|
|
630
|
-
});
|
|
631
|
-
if (n.status === "empty") {
|
|
632
|
-
Z({ valid: !0 }), Q(null);
|
|
633
|
-
return;
|
|
634
|
-
}
|
|
635
|
-
if (n.status === "invalid" && _e) Z(n.result);
|
|
636
|
-
else if (n.status === "valid") {
|
|
637
|
-
Z({ valid: !0 }), We(new Date(n.value.getFullYear(), n.value.getMonth(), 1));
|
|
638
|
-
let t = H ? 6 : 4, r = N ? u(e.target.value).slice(8).length : 0;
|
|
639
|
-
(!N || r >= t) && Q(n.value);
|
|
640
|
-
}
|
|
641
|
-
}, [
|
|
642
|
-
Q,
|
|
643
|
-
Z,
|
|
644
|
-
q,
|
|
645
|
-
X,
|
|
646
|
-
Xe,
|
|
647
|
-
Ye,
|
|
648
|
-
je,
|
|
649
|
-
H,
|
|
650
|
-
V,
|
|
651
|
-
_e,
|
|
652
|
-
N
|
|
653
|
-
]), it = S(() => {
|
|
654
|
-
Re(!0);
|
|
655
|
-
let e = U(ze, {
|
|
656
|
-
inputFormat: q,
|
|
657
|
-
minDate: Ye,
|
|
658
|
-
maxDate: Xe,
|
|
659
|
-
withTime: N,
|
|
660
|
-
timeFormat: V,
|
|
661
|
-
showSeconds: H,
|
|
662
|
-
isDisabled: X
|
|
663
|
-
});
|
|
664
|
-
if (e.status === "empty") {
|
|
665
|
-
Z({ valid: !0 });
|
|
666
|
-
return;
|
|
667
|
-
}
|
|
668
|
-
if (e.status === "partial") {
|
|
669
|
-
F && Z({
|
|
670
|
-
valid: !1,
|
|
671
|
-
error: "Incomplete date"
|
|
672
|
-
});
|
|
673
|
-
return;
|
|
674
|
-
}
|
|
675
|
-
if (e.status === "invalid") {
|
|
676
|
-
if (N && e.result.error === I && e.datePart) {
|
|
677
|
-
let t = g(0, 0, 0, H, V), n = U(`${e.datePart} ${t}`, {
|
|
678
|
-
inputFormat: q,
|
|
679
|
-
minDate: Ye,
|
|
680
|
-
maxDate: Xe,
|
|
681
|
-
withTime: N,
|
|
682
|
-
timeFormat: V,
|
|
683
|
-
showSeconds: H,
|
|
684
|
-
isDisabled: X
|
|
685
|
-
});
|
|
686
|
-
if (n.status === "valid") {
|
|
687
|
-
Z({ valid: !0 }), Be(z(n.value, {
|
|
688
|
-
format: s,
|
|
689
|
-
withTime: N,
|
|
690
|
-
timeFormat: V,
|
|
691
|
-
showSeconds: H
|
|
692
|
-
})), He(be(n.value, H)), Q(n.value);
|
|
693
|
-
return;
|
|
694
|
-
}
|
|
695
|
-
}
|
|
696
|
-
F && Z(e.result);
|
|
697
|
-
return;
|
|
698
|
-
}
|
|
699
|
-
Z({ valid: !0 }), Be(z(e.value, {
|
|
700
|
-
format: s,
|
|
701
|
-
withTime: N,
|
|
702
|
-
timeFormat: V,
|
|
703
|
-
showSeconds: H
|
|
704
|
-
})), He(be(e.value, H)), Q(e.value);
|
|
705
|
-
}, [
|
|
706
|
-
Q,
|
|
707
|
-
Z,
|
|
708
|
-
s,
|
|
709
|
-
q,
|
|
710
|
-
ze,
|
|
711
|
-
X,
|
|
712
|
-
Xe,
|
|
713
|
-
Ye,
|
|
714
|
-
H,
|
|
715
|
-
V,
|
|
716
|
-
F,
|
|
717
|
-
N
|
|
718
|
-
]), at = S((e) => {
|
|
719
|
-
[
|
|
720
|
-
"Backspace",
|
|
721
|
-
"Delete",
|
|
722
|
-
"Tab",
|
|
723
|
-
"ArrowLeft",
|
|
724
|
-
"ArrowRight",
|
|
725
|
-
"Home",
|
|
726
|
-
"End",
|
|
727
|
-
"Enter"
|
|
728
|
-
].includes(e.key) || e.ctrlKey || e.metaKey || (N ? /^[0-9\s:./-APMapm]$/ : /^[0-9./-]$/).test(e.key) || e.preventDefault();
|
|
729
|
-
}, [N]), ot = S(() => {
|
|
730
|
-
Be(""), He(""), Re(!1), Z({ valid: !0 }), Q(null);
|
|
731
|
-
}, [Q, Z]), st = S((e) => {
|
|
732
|
-
e.preventDefault(), e.stopPropagation(), !(h || _ || we) && J((e) => !e);
|
|
733
|
-
}, [
|
|
734
|
-
h,
|
|
735
|
-
we,
|
|
736
|
-
_
|
|
737
|
-
]), ct = S((e) => {
|
|
738
|
-
if (X(e)) return;
|
|
739
|
-
let t = N ? Ve || g(0, 0, 0, H, V) : "", n = N ? re(e, t, {
|
|
740
|
-
format: V,
|
|
741
|
-
showSeconds: H
|
|
742
|
-
}) : d(e);
|
|
743
|
-
Re(!0), Z({ valid: !0 }), He(t), Be(z(n, {
|
|
744
|
-
format: s,
|
|
745
|
-
withTime: N,
|
|
746
|
-
timeFormat: V,
|
|
747
|
-
showSeconds: H
|
|
748
|
-
})), We(new Date(e.getFullYear(), e.getMonth(), 1)), Q(n), !N && !we && J(!1);
|
|
749
|
-
}, [
|
|
750
|
-
Q,
|
|
751
|
-
Ve,
|
|
752
|
-
Z,
|
|
753
|
-
s,
|
|
754
|
-
we,
|
|
755
|
-
X,
|
|
756
|
-
H,
|
|
757
|
-
V,
|
|
758
|
-
N
|
|
759
|
-
]), lt = S(() => {
|
|
760
|
-
let e = d(/* @__PURE__ */ new Date());
|
|
761
|
-
X(e) || ct(e);
|
|
762
|
-
}, [ct, X]), ut = w(() => {
|
|
763
|
-
if (!N) return [];
|
|
764
|
-
let e = [], t = V === "12h" ? 12 : 23, n = +(V === "12h");
|
|
765
|
-
for (let r = n; r <= t; r += 1) e.push(r);
|
|
766
|
-
return e;
|
|
767
|
-
}, [V, N]), dt = w(() => {
|
|
768
|
-
if (!N) return [];
|
|
769
|
-
let e = [];
|
|
770
|
-
for (let t = 0; t < 60; t += Se) e.push(t);
|
|
771
|
-
return e;
|
|
772
|
-
}, [Se, N]), ft = w(() => {
|
|
773
|
-
if (!N || !H) return [];
|
|
774
|
-
let e = [];
|
|
775
|
-
for (let t = 0; t < 60; t += 1) e.push(t);
|
|
776
|
-
return e;
|
|
777
|
-
}, [H, N]), pt = S((e, t, n = 0) => {
|
|
778
|
-
let r = g(e, t, n, H, V), i = nt;
|
|
779
|
-
if (Re(!0), He(r), !i) {
|
|
780
|
-
Be(r);
|
|
781
|
-
return;
|
|
782
|
-
}
|
|
783
|
-
let a = re(i, r, {
|
|
784
|
-
format: V,
|
|
785
|
-
showSeconds: H
|
|
786
|
-
});
|
|
787
|
-
Z({ valid: !0 }), Be(z(a, {
|
|
788
|
-
format: s,
|
|
789
|
-
withTime: N,
|
|
790
|
-
timeFormat: V,
|
|
791
|
-
showSeconds: H
|
|
792
|
-
})), Q(a);
|
|
793
|
-
}, [
|
|
794
|
-
Q,
|
|
795
|
-
nt,
|
|
796
|
-
Z,
|
|
797
|
-
s,
|
|
798
|
-
H,
|
|
799
|
-
V,
|
|
800
|
-
N
|
|
801
|
-
]), mt = S((e) => {
|
|
802
|
-
pt(xe($ ? W($).hours : 12, e), $?.minutes ?? 0, $?.seconds ?? 0);
|
|
803
|
-
}, [$, pt]), ht = w(() => x(Ue, Ee).map((e) => ({
|
|
804
|
-
date: e,
|
|
805
|
-
currentMonth: e.getMonth() === Ue.getMonth()
|
|
806
|
-
})), [Ee, Ue]), gt = d(/* @__PURE__ */ new Date()), _t = Y ? d(Y) : nt, vt = () => /* @__PURE__ */ O("div", {
|
|
807
|
-
className: "calendar",
|
|
808
|
-
children: [
|
|
809
|
-
/* @__PURE__ */ O("div", {
|
|
810
|
-
className: "calendar-header",
|
|
811
|
-
children: [
|
|
812
|
-
/* @__PURE__ */ D("button", {
|
|
813
|
-
type: "button",
|
|
814
|
-
className: "nav-btn",
|
|
815
|
-
onClick: () => We(ae(Ue, -1)),
|
|
816
|
-
"aria-label": Ae.previousMonth,
|
|
817
|
-
children: /* @__PURE__ */ D(e, {})
|
|
818
|
-
}),
|
|
819
|
-
/* @__PURE__ */ O("button", {
|
|
820
|
-
type: "button",
|
|
821
|
-
className: "header-title",
|
|
822
|
-
onClick: () => Ke((e) => e === "days" ? "months" : "days"),
|
|
823
|
-
children: [
|
|
824
|
-
et[Ue.getMonth()],
|
|
825
|
-
" ",
|
|
826
|
-
Ue.getFullYear()
|
|
827
|
-
]
|
|
828
|
-
}),
|
|
829
|
-
/* @__PURE__ */ D("button", {
|
|
830
|
-
type: "button",
|
|
831
|
-
className: "nav-btn",
|
|
832
|
-
onClick: () => We(ae(Ue, 1)),
|
|
833
|
-
"aria-label": Ae.nextMonth,
|
|
834
|
-
children: /* @__PURE__ */ D(a, {})
|
|
835
|
-
})
|
|
836
|
-
]
|
|
837
|
-
}),
|
|
838
|
-
Ge === "days" ? /* @__PURE__ */ O(E, { children: [/* @__PURE__ */ D("div", {
|
|
839
|
-
className: "day-names",
|
|
840
|
-
children: $e.map((e) => /* @__PURE__ */ D("span", {
|
|
841
|
-
className: "day-name",
|
|
842
|
-
children: e
|
|
843
|
-
}, e))
|
|
844
|
-
}), /* @__PURE__ */ D("div", {
|
|
845
|
-
className: "day-grid",
|
|
846
|
-
children: ht.map(({ date: e, currentMonth: t }, n) => {
|
|
847
|
-
let r = _t ? v(e, _t) : !1, i = v(e, gt), a = X(e);
|
|
848
|
-
return /* @__PURE__ */ D("button", {
|
|
849
|
-
type: "button",
|
|
850
|
-
className: o("day", !t && "other-month", i && "today", r && "selected", a && "disabled"),
|
|
851
|
-
onClick: () => ct(e),
|
|
852
|
-
disabled: a,
|
|
853
|
-
tabIndex: -1,
|
|
854
|
-
children: e.getDate()
|
|
855
|
-
}, `${e.toISOString()}-${n}`);
|
|
856
|
-
})
|
|
857
|
-
})] }) : /* @__PURE__ */ D("div", {
|
|
858
|
-
className: "month-grid",
|
|
859
|
-
children: et.map((e, t) => /* @__PURE__ */ D("button", {
|
|
860
|
-
type: "button",
|
|
861
|
-
className: o("month-cell", Ue.getMonth() === t && "selected"),
|
|
862
|
-
onClick: () => {
|
|
863
|
-
We(new Date(Ue.getFullYear(), t, 1)), Ke("days");
|
|
864
|
-
},
|
|
865
|
-
children: e.slice(0, 3)
|
|
866
|
-
}, e))
|
|
867
|
-
}),
|
|
868
|
-
Te && /* @__PURE__ */ D("div", {
|
|
869
|
-
className: "footer",
|
|
870
|
-
children: /* @__PURE__ */ D("button", {
|
|
871
|
-
type: "button",
|
|
872
|
-
className: "today-btn",
|
|
873
|
-
onClick: lt,
|
|
874
|
-
children: Ae.today
|
|
875
|
-
})
|
|
876
|
-
})
|
|
877
|
-
]
|
|
878
|
-
}), yt = () => {
|
|
879
|
-
if (!N) return null;
|
|
880
|
-
let e = $ ? W($) : null;
|
|
881
|
-
return /* @__PURE__ */ O("div", {
|
|
882
|
-
className: "date-picker-time-panel",
|
|
883
|
-
children: [/* @__PURE__ */ D("div", {
|
|
884
|
-
className: "date-picker-time-header",
|
|
885
|
-
children: "Time"
|
|
886
|
-
}), /* @__PURE__ */ O("div", {
|
|
887
|
-
className: "date-picker-time-columns",
|
|
888
|
-
children: [
|
|
889
|
-
/* @__PURE__ */ D(Ce, {
|
|
890
|
-
items: ut,
|
|
891
|
-
selected: V === "12h" ? e?.hours : $?.hours,
|
|
892
|
-
onSelect: (t) => pt(V === "12h" ? xe(t, e?.meridiem ?? "AM") : t, $?.minutes ?? 0, $?.seconds ?? 0),
|
|
893
|
-
label: "Hr"
|
|
894
|
-
}),
|
|
895
|
-
/* @__PURE__ */ D(Ce, {
|
|
896
|
-
items: dt,
|
|
897
|
-
selected: $?.minutes,
|
|
898
|
-
onSelect: (e) => pt($?.hours ?? 0, e, $?.seconds ?? 0),
|
|
899
|
-
label: "Min"
|
|
900
|
-
}),
|
|
901
|
-
H && /* @__PURE__ */ D(Ce, {
|
|
902
|
-
items: ft,
|
|
903
|
-
selected: $?.seconds,
|
|
904
|
-
onSelect: (e) => pt($?.hours ?? 0, $?.minutes ?? 0, e),
|
|
905
|
-
label: "Sec"
|
|
906
|
-
}),
|
|
907
|
-
V === "12h" && /* @__PURE__ */ D(Ce, {
|
|
908
|
-
items: ["AM", "PM"],
|
|
909
|
-
selected: e?.meridiem,
|
|
910
|
-
onSelect: mt,
|
|
911
|
-
label: "AM/PM"
|
|
912
|
-
})
|
|
913
|
-
]
|
|
914
|
-
})]
|
|
915
|
-
});
|
|
916
|
-
}, bt = () => /* @__PURE__ */ O("div", {
|
|
917
|
-
className: o("date-picker-popover-content", N && "with-time"),
|
|
918
|
-
children: [vt(), yt()]
|
|
919
|
-
}), xt = N ? V === "12h" ? H ? 22 : 19 : H ? 19 : 16 : 10, St = ve(m, s, N, V, H, G);
|
|
920
|
-
return we ? /* @__PURE__ */ O("div", {
|
|
921
|
-
className: o("date-picker", y && `color-${y}`, De && "full-width", Oe),
|
|
922
|
-
style: ke,
|
|
923
|
-
children: [
|
|
924
|
-
/* @__PURE__ */ D(fe, {
|
|
925
|
-
value: ze,
|
|
926
|
-
onChange: rt,
|
|
927
|
-
onBlur: it,
|
|
928
|
-
onKeyDown: at,
|
|
929
|
-
onClear: ot,
|
|
930
|
-
type: "text",
|
|
931
|
-
inputMode: N ? "text" : "numeric",
|
|
932
|
-
autoComplete: "off",
|
|
933
|
-
maxLength: xt,
|
|
934
|
-
placeholder: St,
|
|
935
|
-
disabled: h,
|
|
936
|
-
readOnly: _,
|
|
937
|
-
id: ce,
|
|
938
|
-
variant: ue,
|
|
939
|
-
size: de,
|
|
940
|
-
color: y,
|
|
941
|
-
label: me,
|
|
942
|
-
helperText: k,
|
|
943
|
-
error: Ze,
|
|
944
|
-
errorText: Qe,
|
|
945
|
-
required: ge,
|
|
946
|
-
clearable: M,
|
|
947
|
-
fullWidth: De
|
|
948
|
-
}),
|
|
949
|
-
bt(),
|
|
950
|
-
se && Y && /* @__PURE__ */ D("input", {
|
|
951
|
-
type: "hidden",
|
|
952
|
-
name: se,
|
|
953
|
-
value: ie(Y, N, H)
|
|
954
|
-
})
|
|
955
|
-
]
|
|
956
|
-
}) : /* @__PURE__ */ O("div", {
|
|
957
|
-
className: o("date-picker", y && `color-${y}`, De && "full-width", Oe),
|
|
958
|
-
style: ke,
|
|
959
|
-
children: [
|
|
960
|
-
/* @__PURE__ */ D("div", {
|
|
961
|
-
ref: qe,
|
|
962
|
-
className: "date-picker-input-anchor",
|
|
963
|
-
children: /* @__PURE__ */ D(fe, {
|
|
964
|
-
value: ze,
|
|
965
|
-
onChange: rt,
|
|
966
|
-
onBlur: it,
|
|
967
|
-
onKeyDown: at,
|
|
968
|
-
onClear: ot,
|
|
969
|
-
type: "text",
|
|
970
|
-
inputMode: N ? "text" : "numeric",
|
|
971
|
-
autoComplete: "off",
|
|
972
|
-
maxLength: xt,
|
|
973
|
-
placeholder: St,
|
|
974
|
-
disabled: h,
|
|
975
|
-
readOnly: _,
|
|
976
|
-
id: ce,
|
|
977
|
-
variant: ue,
|
|
978
|
-
size: de,
|
|
979
|
-
color: y,
|
|
980
|
-
label: me,
|
|
981
|
-
helperText: k,
|
|
982
|
-
error: Ze,
|
|
983
|
-
errorText: Qe,
|
|
984
|
-
required: ge,
|
|
985
|
-
clearable: M,
|
|
986
|
-
fullWidth: De,
|
|
987
|
-
endIcon: /* @__PURE__ */ D("button", {
|
|
988
|
-
type: "button",
|
|
989
|
-
className: "date-picker-toggle",
|
|
990
|
-
onMouseDown: (e) => e.preventDefault(),
|
|
991
|
-
onClick: st,
|
|
992
|
-
"aria-label": "Open calendar",
|
|
993
|
-
disabled: h || _,
|
|
994
|
-
children: /* @__PURE__ */ D(r, {})
|
|
995
|
-
})
|
|
996
|
-
})
|
|
997
|
-
}),
|
|
998
|
-
se && Y && /* @__PURE__ */ D("input", {
|
|
999
|
-
type: "hidden",
|
|
1000
|
-
name: se,
|
|
1001
|
-
value: ie(Y, N, H)
|
|
1002
|
-
}),
|
|
1003
|
-
/* @__PURE__ */ D(le, {
|
|
1004
|
-
className: "date-picker-popover",
|
|
1005
|
-
style: { "--color-rgb": P(y) },
|
|
1006
|
-
open: Me,
|
|
1007
|
-
anchorRef: qe,
|
|
1008
|
-
onClose: () => J(!1),
|
|
1009
|
-
placement: "bottom-start",
|
|
1010
|
-
children: bt()
|
|
1011
|
-
})
|
|
1012
|
-
]
|
|
1013
|
-
});
|
|
1014
|
-
}
|
|
1015
|
-
function Ce({ items: e, selected: t, onSelect: n, label: r }) {
|
|
1016
|
-
let i = he(null);
|
|
1017
|
-
C(() => {
|
|
1018
|
-
if (t === void 0 || !i.current) return;
|
|
1019
|
-
let e = i.current.querySelector(`[data-value="${t}"]`);
|
|
1020
|
-
if (e) {
|
|
1021
|
-
let t = i.current;
|
|
1022
|
-
t.scrollTop = e.offsetTop - t.clientHeight / 2 + e.offsetHeight / 2;
|
|
1023
|
-
}
|
|
1024
|
-
}, [t]);
|
|
1025
|
-
let a = (e) => typeof e == "number" ? e.toString().padStart(2, "0") : e;
|
|
1026
|
-
return /* @__PURE__ */ O("div", {
|
|
1027
|
-
className: "date-picker-time-column",
|
|
1028
|
-
children: [/* @__PURE__ */ D("div", {
|
|
1029
|
-
className: "date-picker-time-column-label",
|
|
1030
|
-
children: r
|
|
1031
|
-
}), /* @__PURE__ */ D("div", {
|
|
1032
|
-
ref: i,
|
|
1033
|
-
className: "date-picker-time-column-list",
|
|
1034
|
-
children: e.map((e) => /* @__PURE__ */ D("button", {
|
|
1035
|
-
type: "button",
|
|
1036
|
-
"data-value": e,
|
|
1037
|
-
className: o("date-picker-time-column-item", e === t && "selected"),
|
|
1038
|
-
onClick: () => n(e),
|
|
1039
|
-
children: a(e)
|
|
1040
|
-
}, e))
|
|
1041
|
-
})]
|
|
1042
|
-
});
|
|
1043
|
-
}
|
|
1044
|
-
//#endregion
|
|
1045
|
-
//#region src/components/dropdowns/MTimePicker/MTimePicker.tsx
|
|
1046
|
-
function G(e) {
|
|
1047
|
-
let t = e.hours >= 12 ? "PM" : "AM";
|
|
1048
|
-
return {
|
|
1049
|
-
hours: e.hours % 12 || 12,
|
|
1050
|
-
minutes: e.minutes,
|
|
1051
|
-
seconds: e.seconds,
|
|
1052
|
-
meridiem: t
|
|
1053
|
-
};
|
|
1054
|
-
}
|
|
1055
|
-
function we(e, t) {
|
|
1056
|
-
return t === "AM" ? e === 12 ? 0 : e : e === 12 ? 12 : e + 12;
|
|
1057
|
-
}
|
|
1058
|
-
function Te(e, t, n, r, i) {
|
|
1059
|
-
if (i === "24h") return f(e, t, n, r);
|
|
1060
|
-
let a = G({
|
|
1061
|
-
hours: e,
|
|
1062
|
-
minutes: t,
|
|
1063
|
-
seconds: n
|
|
1064
|
-
}), o = `${a.hours.toString().padStart(2, "0")}:${a.minutes.toString().padStart(2, "0")}`;
|
|
1065
|
-
return `${r ? `${o}:${a.seconds.toString().padStart(2, "0")}` : o} ${a.meridiem}`;
|
|
1066
|
-
}
|
|
1067
|
-
function Ee(e, t) {
|
|
1068
|
-
if (t === "24h") return m(e);
|
|
1069
|
-
let n = e.trim().toUpperCase().match(/^(\d{1,2}):(\d{2})(?::(\d{2}))?\s*(AM|PM)$/);
|
|
1070
|
-
if (n) {
|
|
1071
|
-
let e = parseInt(n[1], 10), t = parseInt(n[2], 10), r = n[3] ? parseInt(n[3], 10) : 0, i = n[4];
|
|
1072
|
-
return e < 1 || e > 12 || t > 59 || r > 59 ? null : {
|
|
1073
|
-
hours: we(e, i),
|
|
1074
|
-
minutes: t,
|
|
1075
|
-
seconds: r
|
|
1076
|
-
};
|
|
1077
|
-
}
|
|
1078
|
-
return m(e);
|
|
1079
|
-
}
|
|
1080
|
-
function De(e, t) {
|
|
1081
|
-
return e.hours === t.hours ? e.minutes === t.minutes ? e.seconds - t.seconds : e.minutes - t.minutes : e.hours - t.hours;
|
|
1082
|
-
}
|
|
1083
|
-
function Oe(e, t, n) {
|
|
1084
|
-
return (!t || De(e, t) >= 0) && (!n || De(e, n) <= 0);
|
|
1085
|
-
}
|
|
1086
|
-
function ke({ value: e, defaultValue: t, onChange: r, format: a = "24h", showSeconds: s = !1, minuteStep: c = 1, min: l, max: u, placeholder: d, disabled: ee = !1, readOnly: f = !1, name: te, id: p, variant: ne = "outlined", size: m = "md", color: h, label: g, helperText: _, errorText: v, error: re = !1, required: ie = !1, clearable: ae = !1, fullWidth: oe = !1, className: se, style: ce }) {
|
|
1087
|
-
let [ue, de] = T(!1), [y, fe] = T(t ?? ""), pe = he(null), b = e === void 0 ? y : e, me = re || !!v, x = Ee(b, a), C = Ee(l ?? "", a), E = Ee(u ?? "", a), k = x ? G(x) : null, A = x ? Te(x.hours, x.minutes, x.seconds, s, a) : b, j = w(() => {
|
|
1088
|
-
let e = [], t = a === "12h" ? 12 : 23, n = +(a === "12h");
|
|
1089
|
-
for (let r = n; r <= t; r++) e.push(r);
|
|
1090
|
-
return e;
|
|
1091
|
-
}, [a]), ge = w(() => {
|
|
1092
|
-
let e = [];
|
|
1093
|
-
for (let t = 0; t < 60; t += c) e.push(t);
|
|
1094
|
-
return e;
|
|
1095
|
-
}, [c]), M = w(() => {
|
|
1096
|
-
if (!s) return [];
|
|
1097
|
-
let e = [];
|
|
1098
|
-
for (let t = 0; t < 60; t++) e.push(t);
|
|
1099
|
-
return e;
|
|
1100
|
-
}, [s]), N = S((e, t, n = 0) => Oe({
|
|
1101
|
-
hours: e,
|
|
1102
|
-
minutes: t,
|
|
1103
|
-
seconds: n
|
|
1104
|
-
}, C, E), [E, C]), P = S((t, n, i = 0) => {
|
|
1105
|
-
if (!N(t, n, i)) return;
|
|
1106
|
-
let o = Te(t, n, i, s, a);
|
|
1107
|
-
e === void 0 && fe(o), r?.(o);
|
|
1108
|
-
}, [
|
|
1109
|
-
a,
|
|
1110
|
-
N,
|
|
1111
|
-
r,
|
|
1112
|
-
s,
|
|
1113
|
-
e
|
|
1114
|
-
]), F = S((t) => {
|
|
1115
|
-
let n = t.target.value;
|
|
1116
|
-
e === void 0 && fe(n);
|
|
1117
|
-
}, [e]), I = S(() => {
|
|
1118
|
-
let t = Ee(b, a);
|
|
1119
|
-
if (t && Oe(t, C, E)) {
|
|
1120
|
-
let n = Te(t.hours, t.minutes, t.seconds, s, a);
|
|
1121
|
-
e === void 0 && fe(n), r?.(n);
|
|
1122
|
-
}
|
|
1123
|
-
}, [
|
|
1124
|
-
b,
|
|
1125
|
-
a,
|
|
1126
|
-
E,
|
|
1127
|
-
C,
|
|
1128
|
-
r,
|
|
1129
|
-
s,
|
|
1130
|
-
e
|
|
1131
|
-
]), L = S((e) => {
|
|
1132
|
-
let t = k?.hours ?? 12, n = x?.minutes ?? 0, r = x?.seconds ?? 0;
|
|
1133
|
-
P(we(t, e), n, r);
|
|
1134
|
-
}, [
|
|
1135
|
-
k?.hours,
|
|
1136
|
-
P,
|
|
1137
|
-
x?.minutes,
|
|
1138
|
-
x?.seconds
|
|
1139
|
-
]), R = S((t) => {
|
|
1140
|
-
t.stopPropagation(), e === void 0 && fe(""), r?.("");
|
|
1141
|
-
}, [r, e]);
|
|
1142
|
-
return /* @__PURE__ */ O("div", {
|
|
1143
|
-
className: o("time picker", h && `color-${h}`, oe && "full-width", se),
|
|
1144
|
-
style: ce,
|
|
1145
|
-
children: [
|
|
1146
|
-
g && /* @__PURE__ */ D("label", {
|
|
1147
|
-
htmlFor: p,
|
|
1148
|
-
className: o("field-label", ue && "focused", me && "error", ie && "required"),
|
|
1149
|
-
children: g
|
|
1150
|
-
}),
|
|
1151
|
-
/* @__PURE__ */ O("div", {
|
|
1152
|
-
ref: pe,
|
|
1153
|
-
className: o("time trigger", `field-${ne}`, `field-${m}`, ue && "focused", me && "error", ee && "disabled"),
|
|
1154
|
-
onClick: () => !ee && !f && de(!0),
|
|
1155
|
-
children: [
|
|
1156
|
-
/* @__PURE__ */ D("span", {
|
|
1157
|
-
className: "time icon",
|
|
1158
|
-
children: /* @__PURE__ */ D(n, {})
|
|
1159
|
-
}),
|
|
1160
|
-
/* @__PURE__ */ D("input", {
|
|
1161
|
-
type: "text",
|
|
1162
|
-
className: "time input",
|
|
1163
|
-
value: A,
|
|
1164
|
-
onChange: F,
|
|
1165
|
-
onBlur: I,
|
|
1166
|
-
placeholder: d ?? (a === "12h" ? s ? "hh:mm:ss AM" : "hh:mm AM" : s ? "HH:MM:SS" : "HH:MM"),
|
|
1167
|
-
disabled: ee,
|
|
1168
|
-
readOnly: f,
|
|
1169
|
-
id: p,
|
|
1170
|
-
"aria-invalid": me || void 0
|
|
1171
|
-
}),
|
|
1172
|
-
ae && b && !ee && /* @__PURE__ */ D("button", {
|
|
1173
|
-
type: "button",
|
|
1174
|
-
className: "time clear clear-btn-base",
|
|
1175
|
-
onClick: R,
|
|
1176
|
-
tabIndex: -1,
|
|
1177
|
-
"aria-label": "Clear time",
|
|
1178
|
-
children: /* @__PURE__ */ D(i, {})
|
|
1179
|
-
})
|
|
1180
|
-
]
|
|
1181
|
-
}),
|
|
1182
|
-
te && /* @__PURE__ */ D("input", {
|
|
1183
|
-
type: "hidden",
|
|
1184
|
-
name: te,
|
|
1185
|
-
value: A
|
|
1186
|
-
}),
|
|
1187
|
-
/* @__PURE__ */ D(le, {
|
|
1188
|
-
className: "time picker popover",
|
|
1189
|
-
open: ue,
|
|
1190
|
-
anchorRef: pe,
|
|
1191
|
-
onClose: () => de(!1),
|
|
1192
|
-
placement: "bottom-start",
|
|
1193
|
-
children: /* @__PURE__ */ O("div", {
|
|
1194
|
-
className: "time columns",
|
|
1195
|
-
children: [
|
|
1196
|
-
/* @__PURE__ */ D(K, {
|
|
1197
|
-
items: j,
|
|
1198
|
-
selected: a === "12h" ? k?.hours : x?.hours,
|
|
1199
|
-
onSelect: (e) => P(a === "12h" ? we(e, k?.meridiem ?? "AM") : e, x?.minutes ?? 0, x?.seconds ?? 0),
|
|
1200
|
-
isDisabled: (e) => !N(a === "12h" ? we(e, k?.meridiem ?? "AM") : e, x?.minutes ?? 0, x?.seconds ?? 0),
|
|
1201
|
-
label: "Hr"
|
|
1202
|
-
}),
|
|
1203
|
-
/* @__PURE__ */ D(K, {
|
|
1204
|
-
items: ge,
|
|
1205
|
-
selected: x?.minutes,
|
|
1206
|
-
onSelect: (e) => P(x?.hours ?? 0, e, x?.seconds ?? 0),
|
|
1207
|
-
isDisabled: (e) => !N(x?.hours ?? 0, e, x?.seconds ?? 0),
|
|
1208
|
-
label: "Min"
|
|
1209
|
-
}),
|
|
1210
|
-
s && /* @__PURE__ */ D(K, {
|
|
1211
|
-
items: M,
|
|
1212
|
-
selected: x?.seconds,
|
|
1213
|
-
onSelect: (e) => P(x?.hours ?? 0, x?.minutes ?? 0, e),
|
|
1214
|
-
isDisabled: (e) => !N(x?.hours ?? 0, x?.minutes ?? 0, e),
|
|
1215
|
-
label: "Sec"
|
|
1216
|
-
}),
|
|
1217
|
-
a === "12h" && /* @__PURE__ */ D(K, {
|
|
1218
|
-
items: ["AM", "PM"],
|
|
1219
|
-
selected: k?.meridiem,
|
|
1220
|
-
onSelect: L,
|
|
1221
|
-
label: "AM/PM"
|
|
1222
|
-
})
|
|
1223
|
-
]
|
|
1224
|
-
})
|
|
1225
|
-
}),
|
|
1226
|
-
(v || _) && /* @__PURE__ */ D("div", {
|
|
1227
|
-
className: "time bottom",
|
|
1228
|
-
children: v ? /* @__PURE__ */ D("span", {
|
|
1229
|
-
className: "field-error",
|
|
1230
|
-
role: "alert",
|
|
1231
|
-
children: v
|
|
1232
|
-
}) : /* @__PURE__ */ D("span", {
|
|
1233
|
-
className: "time helper",
|
|
1234
|
-
children: _
|
|
1235
|
-
})
|
|
1236
|
-
})
|
|
1237
|
-
]
|
|
1238
|
-
});
|
|
1239
|
-
}
|
|
1240
|
-
function K({ items: e, selected: t, onSelect: n, isDisabled: r, label: i }) {
|
|
1241
|
-
let a = he(null);
|
|
1242
|
-
C(() => {
|
|
1243
|
-
if (t === void 0 || !a.current) return;
|
|
1244
|
-
let e = a.current.querySelector(`[data-value="${t}"]`);
|
|
1245
|
-
if (e) {
|
|
1246
|
-
let t = a.current;
|
|
1247
|
-
t.scrollTop = e.offsetTop - t.clientHeight / 2 + e.offsetHeight / 2;
|
|
1248
|
-
}
|
|
1249
|
-
}, [t]);
|
|
1250
|
-
let s = (e) => typeof e == "number" ? e.toString().padStart(2, "0") : e;
|
|
1251
|
-
return /* @__PURE__ */ O("div", {
|
|
1252
|
-
className: "time column",
|
|
1253
|
-
children: [/* @__PURE__ */ D("div", {
|
|
1254
|
-
className: "time column label",
|
|
1255
|
-
children: i
|
|
1256
|
-
}), /* @__PURE__ */ D("div", {
|
|
1257
|
-
ref: a,
|
|
1258
|
-
className: "time column list",
|
|
1259
|
-
children: e.map((e) => {
|
|
1260
|
-
let i = r?.(e) ?? !1;
|
|
1261
|
-
return /* @__PURE__ */ D("button", {
|
|
1262
|
-
type: "button",
|
|
1263
|
-
"data-value": e,
|
|
1264
|
-
className: o("time column item", e === t && "selected", i && "disabled"),
|
|
1265
|
-
onClick: () => n(e),
|
|
1266
|
-
disabled: i,
|
|
1267
|
-
children: s(e)
|
|
1268
|
-
}, e);
|
|
1269
|
-
})
|
|
1270
|
-
})]
|
|
1271
|
-
});
|
|
1272
|
-
}
|
|
1273
|
-
//#endregion
|
|
1274
|
-
//#region src/components/dropdowns/MDateRangePicker/MDateRangePicker.tsx
|
|
1275
|
-
function Ae(e) {
|
|
1276
|
-
if (!e) return null;
|
|
1277
|
-
if (e instanceof Date) return d(e);
|
|
1278
|
-
let t = new Date(e);
|
|
1279
|
-
return isNaN(t.getTime()) ? null : d(t);
|
|
1280
|
-
}
|
|
1281
|
-
function q(e, t) {
|
|
1282
|
-
return e.getTime() <= t.getTime() ? {
|
|
1283
|
-
start: e,
|
|
1284
|
-
end: t
|
|
1285
|
-
} : {
|
|
1286
|
-
start: t,
|
|
1287
|
-
end: e
|
|
1288
|
-
};
|
|
1289
|
-
}
|
|
1290
|
-
function je(e, t, n) {
|
|
1291
|
-
if (!t || !n) return !1;
|
|
1292
|
-
let r = e.getTime();
|
|
1293
|
-
return r > t.getTime() && r < n.getTime();
|
|
1294
|
-
}
|
|
1295
|
-
function Me(e, t, n) {
|
|
1296
|
-
return e && t ? `${_(e, n)} - ${_(t, n)}` : e ? `${_(e, n)} - ...` : "";
|
|
1297
|
-
}
|
|
1298
|
-
function J(e) {
|
|
1299
|
-
return new Date(e.getFullYear(), e.getMonth(), 1);
|
|
1300
|
-
}
|
|
1301
|
-
function Ne(e) {
|
|
1302
|
-
return new Date(e.getFullYear(), e.getMonth() + 1, 0);
|
|
1303
|
-
}
|
|
1304
|
-
function Pe(e) {
|
|
1305
|
-
let t = d(/* @__PURE__ */ new Date());
|
|
1306
|
-
return t.setDate(t.getDate() - (e - 1)), t;
|
|
1307
|
-
}
|
|
1308
|
-
function Fe(e) {
|
|
1309
|
-
let t = d(/* @__PURE__ */ new Date());
|
|
1310
|
-
return new Date(t.getFullYear(), t.getMonth() - e, t.getDate());
|
|
1311
|
-
}
|
|
1312
|
-
function Ie(e) {
|
|
1313
|
-
let t = d(/* @__PURE__ */ new Date()), n = new Date(t.getFullYear(), t.getMonth() - 1, 1);
|
|
1314
|
-
return [
|
|
1315
|
-
{
|
|
1316
|
-
label: e.presets.today,
|
|
1317
|
-
value: {
|
|
1318
|
-
start: t,
|
|
1319
|
-
end: t
|
|
1320
|
-
}
|
|
1321
|
-
},
|
|
1322
|
-
{
|
|
1323
|
-
label: e.presets.days2,
|
|
1324
|
-
value: {
|
|
1325
|
-
start: Pe(2),
|
|
1326
|
-
end: t
|
|
1327
|
-
}
|
|
1328
|
-
},
|
|
1329
|
-
{
|
|
1330
|
-
label: e.presets.days3,
|
|
1331
|
-
value: {
|
|
1332
|
-
start: Pe(3),
|
|
1333
|
-
end: t
|
|
1334
|
-
}
|
|
1335
|
-
},
|
|
1336
|
-
{
|
|
1337
|
-
label: e.presets.days7,
|
|
1338
|
-
value: {
|
|
1339
|
-
start: Pe(7),
|
|
1340
|
-
end: t
|
|
1341
|
-
}
|
|
1342
|
-
},
|
|
1343
|
-
{
|
|
1344
|
-
label: e.presets.days14,
|
|
1345
|
-
value: {
|
|
1346
|
-
start: Pe(14),
|
|
1347
|
-
end: t
|
|
1348
|
-
}
|
|
1349
|
-
},
|
|
1350
|
-
{
|
|
1351
|
-
label: e.presets.days31,
|
|
1352
|
-
value: {
|
|
1353
|
-
start: Pe(31),
|
|
1354
|
-
end: t
|
|
1355
|
-
}
|
|
1356
|
-
},
|
|
1357
|
-
{
|
|
1358
|
-
label: e.presets.thisMonth,
|
|
1359
|
-
value: {
|
|
1360
|
-
start: J(t),
|
|
1361
|
-
end: Ne(t)
|
|
1362
|
-
}
|
|
1363
|
-
},
|
|
1364
|
-
{
|
|
1365
|
-
label: e.presets.previousMonth,
|
|
1366
|
-
value: {
|
|
1367
|
-
start: J(n),
|
|
1368
|
-
end: Ne(n)
|
|
1369
|
-
}
|
|
1370
|
-
},
|
|
1371
|
-
{
|
|
1372
|
-
label: e.presets.months2,
|
|
1373
|
-
value: {
|
|
1374
|
-
start: Fe(2),
|
|
1375
|
-
end: t
|
|
1376
|
-
}
|
|
1377
|
-
},
|
|
1378
|
-
{
|
|
1379
|
-
label: e.presets.months3,
|
|
1380
|
-
value: {
|
|
1381
|
-
start: Fe(3),
|
|
1382
|
-
end: t
|
|
1383
|
-
}
|
|
1384
|
-
},
|
|
1385
|
-
{
|
|
1386
|
-
label: e.presets.months6,
|
|
1387
|
-
value: {
|
|
1388
|
-
start: Fe(6),
|
|
1389
|
-
end: t
|
|
1390
|
-
}
|
|
1391
|
-
},
|
|
1392
|
-
{
|
|
1393
|
-
label: e.presets.year1,
|
|
1394
|
-
value: {
|
|
1395
|
-
start: Fe(12),
|
|
1396
|
-
end: t
|
|
1397
|
-
}
|
|
1398
|
-
}
|
|
1399
|
-
];
|
|
1400
|
-
}
|
|
1401
|
-
function Le(e, t) {
|
|
1402
|
-
let n = e.getFullYear(), r = e.getMonth(), i = h(n, r), a = ee(n, r);
|
|
1403
|
-
t === 1 && (a = a === 0 ? 6 : a - 1);
|
|
1404
|
-
let o = [], s = r === 0 ? 11 : r - 1, c = r === 0 ? n - 1 : n, l = h(c, s);
|
|
1405
|
-
for (let e = a - 1; e >= 0; --e) o.push({
|
|
1406
|
-
date: new Date(c, s, l - e),
|
|
1407
|
-
currentMonth: !1
|
|
1408
|
-
});
|
|
1409
|
-
for (let e = 1; e <= i; e += 1) o.push({
|
|
1410
|
-
date: new Date(n, r, e),
|
|
1411
|
-
currentMonth: !0
|
|
1412
|
-
});
|
|
1413
|
-
let u = 42 - o.length, d = r === 11 ? 0 : r + 1, f = r === 11 ? n + 1 : n;
|
|
1414
|
-
for (let e = 1; e <= u; e += 1) o.push({
|
|
1415
|
-
date: new Date(f, d, e),
|
|
1416
|
-
currentMonth: !1
|
|
1417
|
-
});
|
|
1418
|
-
return o;
|
|
1419
|
-
}
|
|
1420
|
-
function Re({ value: t, defaultValue: n, onChange: s, format: c = "dd.MM.yyyy", locale: l, min: u, max: ee, disabledDates: f, placeholder: ne, disabled: m = !1, readOnly: h = !1, name: g, id: re, variant: ie = "outlined", size: se = "md", color: ce, label: ue, helperText: de, errorText: y, error: fe = !1, required: b = !1, clearable: x = !1, inline: E = !1, showTodayButton: k = !0, presets: A = !1, presetsSidebar: j = !1, firstDayOfWeek: ge = 1, fullWidth: M = !1, allowSameDay: N = !0, className: F, style: I }) {
|
|
1421
|
-
let L = pe(l), R = t ? {
|
|
1422
|
-
start: Ae(t.start),
|
|
1423
|
-
end: Ae(t.end)
|
|
1424
|
-
} : null, [_e, ve] = T(() => ({
|
|
1425
|
-
start: Ae(n?.start),
|
|
1426
|
-
end: Ae(n?.end)
|
|
1427
|
-
})), [z, B] = T(null), [V, H] = T(!1), ye = he(null), be = R ?? _e, U = be.start, W = be.end, xe = Ae(u), Se = Ae(ee), Ce = fe || !!y, G = me(), we = oe(L, ge), Te = te(L), Ee = w(() => A === !0 || j && !A ? Ie(G) : Array.isArray(A) ? A : [], [
|
|
1428
|
-
A,
|
|
1429
|
-
j,
|
|
1430
|
-
G
|
|
1431
|
-
]), [De, Oe] = T(() => {
|
|
1432
|
-
let e = U ?? /* @__PURE__ */ new Date();
|
|
1433
|
-
return new Date(e.getFullYear(), e.getMonth(), 1);
|
|
1434
|
-
}), ke = U?.getTime() ?? null;
|
|
1435
|
-
C(() => {
|
|
1436
|
-
if (!ke) return;
|
|
1437
|
-
let e = new Date(ke);
|
|
1438
|
-
Oe(new Date(e.getFullYear(), e.getMonth(), 1));
|
|
1439
|
-
}, [ke]);
|
|
1440
|
-
let K = S((e) => p(e, xe, Se) ? Array.isArray(f) ? f.some((t) => v(t, e)) : typeof f == "function" ? f(e) : !1 : !0, [
|
|
1441
|
-
f,
|
|
1442
|
-
Se,
|
|
1443
|
-
xe
|
|
1444
|
-
]), J = S((e) => {
|
|
1445
|
-
t === void 0 && ve(e), s?.(e);
|
|
1446
|
-
}, [s, t]), Ne = S((e) => {
|
|
1447
|
-
if (!K(e)) {
|
|
1448
|
-
if (!U || U && W) {
|
|
1449
|
-
J({
|
|
1450
|
-
start: e,
|
|
1451
|
-
end: null
|
|
1452
|
-
}), B(null);
|
|
1453
|
-
return;
|
|
1454
|
-
}
|
|
1455
|
-
!N && v(e, U) || (J(q(U, e)), B(null), E || H(!1));
|
|
1456
|
-
}
|
|
1457
|
-
}, [
|
|
1458
|
-
N,
|
|
1459
|
-
J,
|
|
1460
|
-
W,
|
|
1461
|
-
E,
|
|
1462
|
-
K,
|
|
1463
|
-
U
|
|
1464
|
-
]), Pe = S((e) => {
|
|
1465
|
-
e.stopPropagation(), J({
|
|
1466
|
-
start: null,
|
|
1467
|
-
end: null
|
|
1468
|
-
}), B(null);
|
|
1469
|
-
}, [J]), Fe = S(() => {
|
|
1470
|
-
let e = d(/* @__PURE__ */ new Date());
|
|
1471
|
-
K(e) || (J({
|
|
1472
|
-
start: e,
|
|
1473
|
-
end: e
|
|
1474
|
-
}), Oe(new Date(e.getFullYear(), e.getMonth(), 1)), B(null), E || H(!1));
|
|
1475
|
-
}, [
|
|
1476
|
-
J,
|
|
1477
|
-
E,
|
|
1478
|
-
K
|
|
1479
|
-
]), Re = S((e) => {
|
|
1480
|
-
let t = Ae(e.value.start), n = Ae(e.value.end);
|
|
1481
|
-
if (!t || !n) return;
|
|
1482
|
-
let r = q(t, n);
|
|
1483
|
-
K(r.start) || K(r.end) || (J(r), Oe(new Date(r.start.getFullYear(), r.start.getMonth(), 1)), B(null), E || H(!1));
|
|
1484
|
-
}, [
|
|
1485
|
-
J,
|
|
1486
|
-
E,
|
|
1487
|
-
K
|
|
1488
|
-
]), Y = U && !W ? z : null, ze = De, Be = ae(De, 1), Ve = d(/* @__PURE__ */ new Date()), He = w(() => Me(U, W, c), [
|
|
1489
|
-
W,
|
|
1490
|
-
c,
|
|
1491
|
-
U
|
|
1492
|
-
]), Ue = w(() => [ze, Be].map((e) => ({
|
|
1493
|
-
monthDate: e,
|
|
1494
|
-
days: Le(e, ge)
|
|
1495
|
-
})), [
|
|
1496
|
-
ge,
|
|
1497
|
-
ze,
|
|
1498
|
-
Be
|
|
1499
|
-
]), We = U && W ? `${_(U, c)} - ${_(W, c)}` : U ? `${_(U, c)} - ...` : ne ?? G.defaultRangePlaceholder, Ge = j && Ee.length > 0, Ke = !j && Ee.length > 0, qe = () => /* @__PURE__ */ D("div", {
|
|
1500
|
-
className: "presets-sidebar",
|
|
1501
|
-
children: Ee.map((e) => /* @__PURE__ */ D("button", {
|
|
1502
|
-
type: "button",
|
|
1503
|
-
className: "preset-sidebar-btn",
|
|
1504
|
-
onClick: () => Re(e),
|
|
1505
|
-
children: e.label
|
|
1506
|
-
}, e.label))
|
|
1507
|
-
}), Je = () => /* @__PURE__ */ O("div", {
|
|
1508
|
-
className: "calendar-body",
|
|
1509
|
-
children: [
|
|
1510
|
-
/* @__PURE__ */ O("div", {
|
|
1511
|
-
className: "calendar-top",
|
|
1512
|
-
children: [/* @__PURE__ */ O("div", {
|
|
1513
|
-
className: "calendar-caption",
|
|
1514
|
-
children: [/* @__PURE__ */ O("span", {
|
|
1515
|
-
className: "caption-title",
|
|
1516
|
-
children: [
|
|
1517
|
-
Te[ze.getMonth()],
|
|
1518
|
-
" ",
|
|
1519
|
-
ze.getFullYear()
|
|
1520
|
-
]
|
|
1521
|
-
}), /* @__PURE__ */ D("span", {
|
|
1522
|
-
className: "caption-subtitle",
|
|
1523
|
-
children: G.rangeSubtitle
|
|
1524
|
-
})]
|
|
1525
|
-
}), /* @__PURE__ */ O("div", {
|
|
1526
|
-
className: "nav-actions",
|
|
1527
|
-
children: [/* @__PURE__ */ D("button", {
|
|
1528
|
-
type: "button",
|
|
1529
|
-
className: "nav-btn",
|
|
1530
|
-
onClick: () => Oe(ae(De, -1)),
|
|
1531
|
-
"aria-label": G.previousMonth,
|
|
1532
|
-
children: /* @__PURE__ */ D(e, {})
|
|
1533
|
-
}), /* @__PURE__ */ D("button", {
|
|
1534
|
-
type: "button",
|
|
1535
|
-
className: "nav-btn",
|
|
1536
|
-
onClick: () => Oe(ae(De, 1)),
|
|
1537
|
-
"aria-label": G.nextMonth,
|
|
1538
|
-
children: /* @__PURE__ */ D(a, {})
|
|
1539
|
-
})]
|
|
1540
|
-
})]
|
|
1541
|
-
}),
|
|
1542
|
-
Ke && /* @__PURE__ */ D("div", {
|
|
1543
|
-
className: "presets",
|
|
1544
|
-
children: Ee.map((e) => /* @__PURE__ */ D("button", {
|
|
1545
|
-
type: "button",
|
|
1546
|
-
className: "preset-btn",
|
|
1547
|
-
onClick: () => Re(e),
|
|
1548
|
-
children: e.label
|
|
1549
|
-
}, e.label))
|
|
1550
|
-
}),
|
|
1551
|
-
/* @__PURE__ */ D("div", {
|
|
1552
|
-
className: "months",
|
|
1553
|
-
children: Ue.map(({ monthDate: e, days: t }) => /* @__PURE__ */ O("div", {
|
|
1554
|
-
className: "month-panel",
|
|
1555
|
-
children: [
|
|
1556
|
-
/* @__PURE__ */ O("div", {
|
|
1557
|
-
className: "month-title",
|
|
1558
|
-
children: [
|
|
1559
|
-
Te[e.getMonth()],
|
|
1560
|
-
" ",
|
|
1561
|
-
e.getFullYear()
|
|
1562
|
-
]
|
|
1563
|
-
}),
|
|
1564
|
-
/* @__PURE__ */ D("div", {
|
|
1565
|
-
className: "day-names",
|
|
1566
|
-
children: we.map((t) => /* @__PURE__ */ D("span", {
|
|
1567
|
-
className: "day-name",
|
|
1568
|
-
children: t
|
|
1569
|
-
}, `${e.toISOString()}-${t}`))
|
|
1570
|
-
}),
|
|
1571
|
-
/* @__PURE__ */ D("div", {
|
|
1572
|
-
className: "day-grid",
|
|
1573
|
-
children: t.map(({ date: t, currentMonth: n }, r) => {
|
|
1574
|
-
let i = K(t), a = U ? v(t, U) : !1, s = W ? v(t, W) : !1, c = je(t, U, W), l = !W && U && Y ? q(U, Y) : null, u = l ? je(t, l.start, l.end) : !1, d = l ? v(t, l.start) || v(t, l.end) : !1;
|
|
1575
|
-
return /* @__PURE__ */ D("button", {
|
|
1576
|
-
type: "button",
|
|
1577
|
-
className: o("day", !n && "other-month", v(t, Ve) && "today", a && "range-start selected", s && "range-end selected", c && "in-range", u && !d && "preview-range", i && "disabled"),
|
|
1578
|
-
onClick: () => Ne(t),
|
|
1579
|
-
onMouseEnter: () => U && !W && B(t),
|
|
1580
|
-
onFocus: () => U && !W && B(t),
|
|
1581
|
-
disabled: i,
|
|
1582
|
-
tabIndex: -1,
|
|
1583
|
-
children: t.getDate()
|
|
1584
|
-
}, `${e.toISOString()}-${r}`);
|
|
1585
|
-
})
|
|
1586
|
-
})
|
|
1587
|
-
]
|
|
1588
|
-
}, e.toISOString()))
|
|
1589
|
-
}),
|
|
1590
|
-
/* @__PURE__ */ O("div", {
|
|
1591
|
-
className: "footer",
|
|
1592
|
-
children: [/* @__PURE__ */ D("span", {
|
|
1593
|
-
className: "summary",
|
|
1594
|
-
children: We
|
|
1595
|
-
}), /* @__PURE__ */ O("div", {
|
|
1596
|
-
className: "footer-actions",
|
|
1597
|
-
children: [x && (U || W) && /* @__PURE__ */ D("button", {
|
|
1598
|
-
type: "button",
|
|
1599
|
-
className: "footer-btn",
|
|
1600
|
-
onClick: (e) => {
|
|
1601
|
-
e.preventDefault(), J({
|
|
1602
|
-
start: null,
|
|
1603
|
-
end: null
|
|
1604
|
-
}), B(null);
|
|
1605
|
-
},
|
|
1606
|
-
children: G.clear
|
|
1607
|
-
}), k && /* @__PURE__ */ D("button", {
|
|
1608
|
-
type: "button",
|
|
1609
|
-
className: "footer-btn",
|
|
1610
|
-
onClick: Fe,
|
|
1611
|
-
children: G.today
|
|
1612
|
-
})]
|
|
1613
|
-
})]
|
|
1614
|
-
})
|
|
1615
|
-
]
|
|
1616
|
-
}), Ye = () => /* @__PURE__ */ O("div", {
|
|
1617
|
-
className: o("date-range-calendar", Ge && "with-sidebar"),
|
|
1618
|
-
children: [Ge && qe(), Je()]
|
|
1619
|
-
});
|
|
1620
|
-
return E ? /* @__PURE__ */ O("div", {
|
|
1621
|
-
className: o("date-range-picker", ce && `color-${ce}`, M && "full-width", F),
|
|
1622
|
-
style: I,
|
|
1623
|
-
children: [ue && /* @__PURE__ */ D("label", {
|
|
1624
|
-
className: o("field-label", Ce && "error", b && "required"),
|
|
1625
|
-
children: ue
|
|
1626
|
-
}), Ye()]
|
|
1627
|
-
}) : /* @__PURE__ */ O("div", {
|
|
1628
|
-
className: o("date-range-picker", ce && `color-${ce}`, M && "full-width", F),
|
|
1629
|
-
style: I,
|
|
1630
|
-
children: [
|
|
1631
|
-
ue && /* @__PURE__ */ D("label", {
|
|
1632
|
-
htmlFor: re,
|
|
1633
|
-
className: o("field-label", V && "focused", Ce && "error", b && "required"),
|
|
1634
|
-
children: ue
|
|
1635
|
-
}),
|
|
1636
|
-
/* @__PURE__ */ O("div", {
|
|
1637
|
-
ref: ye,
|
|
1638
|
-
className: o("trigger", `field-${ie}`, `field-${se}`, V && "focused", Ce && "error", m && "disabled"),
|
|
1639
|
-
onClick: () => !m && !h && H(!0),
|
|
1640
|
-
children: [
|
|
1641
|
-
/* @__PURE__ */ D("span", {
|
|
1642
|
-
className: "icon",
|
|
1643
|
-
children: /* @__PURE__ */ D(r, {})
|
|
1644
|
-
}),
|
|
1645
|
-
/* @__PURE__ */ D("input", {
|
|
1646
|
-
type: "text",
|
|
1647
|
-
className: "input",
|
|
1648
|
-
value: He,
|
|
1649
|
-
placeholder: ne ?? G.defaultRangePlaceholder,
|
|
1650
|
-
disabled: m,
|
|
1651
|
-
readOnly: !0,
|
|
1652
|
-
id: re,
|
|
1653
|
-
"aria-invalid": Ce || void 0
|
|
1654
|
-
}),
|
|
1655
|
-
x && (U || W) && !m && /* @__PURE__ */ D("button", {
|
|
1656
|
-
type: "button",
|
|
1657
|
-
className: "clear-btn clear-btn-base",
|
|
1658
|
-
onClick: Pe,
|
|
1659
|
-
tabIndex: -1,
|
|
1660
|
-
"aria-label": G.clear,
|
|
1661
|
-
children: /* @__PURE__ */ D(i, {})
|
|
1662
|
-
})
|
|
1663
|
-
]
|
|
1664
|
-
}),
|
|
1665
|
-
g && U && W && /* @__PURE__ */ D("input", {
|
|
1666
|
-
type: "hidden",
|
|
1667
|
-
name: g,
|
|
1668
|
-
value: `${U.toISOString().split("T")[0]}:${W.toISOString().split("T")[0]}`
|
|
1669
|
-
}),
|
|
1670
|
-
/* @__PURE__ */ D(le, {
|
|
1671
|
-
className: "date-range-picker-popover",
|
|
1672
|
-
style: { "--color-rgb": P(ce) },
|
|
1673
|
-
open: V,
|
|
1674
|
-
anchorRef: ye,
|
|
1675
|
-
onClose: () => {
|
|
1676
|
-
H(!1), B(null);
|
|
1677
|
-
},
|
|
1678
|
-
placement: "bottom-start",
|
|
1679
|
-
children: Ye()
|
|
1680
|
-
}),
|
|
1681
|
-
(y || de) && /* @__PURE__ */ D("div", {
|
|
1682
|
-
className: "bottom-row",
|
|
1683
|
-
children: y ? /* @__PURE__ */ D("span", {
|
|
1684
|
-
className: "field-error",
|
|
1685
|
-
role: "alert",
|
|
1686
|
-
children: y
|
|
1687
|
-
}) : /* @__PURE__ */ D("span", {
|
|
1688
|
-
className: "helper-text",
|
|
1689
|
-
children: de
|
|
1690
|
-
})
|
|
1691
|
-
})
|
|
1692
|
-
]
|
|
1693
|
-
});
|
|
1694
|
-
}
|
|
1695
|
-
//#endregion
|
|
1696
|
-
export { k as a, M as i, ke as n, Se as r, Re as t };
|
|
1697
|
-
|
|
1698
|
-
//# sourceMappingURL=dropdowns-Dq-xAplH.js.map
|