admin-ui-starter-kit 0.6.2 → 0.6.4
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/dist/_shared/{auth-B_KVUjsB.cjs → auth-DdezEtKK.cjs} +2 -2
- package/dist/_shared/{auth-B_KVUjsB.cjs.map → auth-DdezEtKK.cjs.map} +1 -1
- package/dist/_shared/{auth-C_TgyzDl.js → auth-e7yab9pK.js} +2 -2
- package/dist/_shared/{auth-C_TgyzDl.js.map → auth-e7yab9pK.js.map} +1 -1
- package/dist/_shared/{buttons-C8jy-jMd.cjs → buttons-Bek9F7qK.cjs} +2 -2
- package/dist/_shared/{buttons-C8jy-jMd.cjs.map → buttons-Bek9F7qK.cjs.map} +1 -1
- package/dist/_shared/{buttons-MxvdokeK.js → buttons-DcynMPnE.js} +2 -2
- package/dist/_shared/{buttons-MxvdokeK.js.map → buttons-DcynMPnE.js.map} +1 -1
- package/dist/_shared/cards-CbbHly7W.cjs +2 -0
- package/dist/_shared/cards-CbbHly7W.cjs.map +1 -0
- package/dist/_shared/{cards-CtBoSZG9.js → cards-RZxRLx3f.js} +6 -6
- package/dist/_shared/cards-RZxRLx3f.js.map +1 -0
- package/dist/_shared/{comments-DGBxF9fD.js → comments-BJqgvSFY.js} +2 -2
- package/dist/_shared/{comments-DGBxF9fD.js.map → comments-BJqgvSFY.js.map} +1 -1
- package/dist/_shared/{comments-C8iXy9XO.cjs → comments-BjPciQfo.cjs} +2 -2
- package/dist/_shared/{comments-C8iXy9XO.cjs.map → comments-BjPciQfo.cjs.map} +1 -1
- package/dist/_shared/{data-display-C_44_V-W.cjs → data-display-C21skrV4.cjs} +2 -2
- package/dist/_shared/{data-display-C_44_V-W.cjs.map → data-display-C21skrV4.cjs.map} +1 -1
- package/dist/_shared/{data-display-CRFaMkxT.js → data-display-C5-1dZua.js} +71 -71
- package/dist/_shared/{data-display-CRFaMkxT.js.map → data-display-C5-1dZua.js.map} +1 -1
- package/dist/_shared/{forms-qnwoUqxf.js → forms-BoquZE2Y.js} +3 -3
- package/dist/_shared/{forms-qnwoUqxf.js.map → forms-BoquZE2Y.js.map} +1 -1
- package/dist/_shared/{forms-rmKcy5uO.cjs → forms-CzrEYejY.cjs} +2 -2
- package/dist/_shared/{forms-rmKcy5uO.cjs.map → forms-CzrEYejY.cjs.map} +1 -1
- package/dist/_shared/{page-C6EzwvTz.cjs → page-D8UMXREv.cjs} +2 -2
- package/dist/_shared/{page-C6EzwvTz.cjs.map → page-D8UMXREv.cjs.map} +1 -1
- package/dist/_shared/{page-DCW1eWCJ.js → page-D9LNsHMN.js} +2 -2
- package/dist/_shared/{page-DCW1eWCJ.js.map → page-D9LNsHMN.js.map} +1 -1
- package/dist/_shared/{settings-QOBrbgdN.js → settings-BeZOIEJB.js} +2 -2
- package/dist/_shared/{settings-QOBrbgdN.js.map → settings-BeZOIEJB.js.map} +1 -1
- package/dist/_shared/{settings-DbAyxMrX.cjs → settings-DI-K34bW.cjs} +2 -2
- package/dist/_shared/{settings-DbAyxMrX.cjs.map → settings-DI-K34bW.cjs.map} +1 -1
- package/dist/_shared/{table-CUA_A-oO.js → table-B_pqCQxC.js} +3 -3
- package/dist/_shared/table-B_pqCQxC.js.map +1 -0
- package/dist/_shared/table-CGVOXtdv.cjs +2 -0
- package/dist/_shared/table-CGVOXtdv.cjs.map +1 -0
- package/dist/components/base/buttons/index.cjs +1 -1
- package/dist/components/base/buttons/index.js +1 -1
- package/dist/components/base/cards/index.cjs +1 -1
- package/dist/components/base/cards/index.js +1 -1
- package/dist/components/base/forms/index.cjs +1 -1
- package/dist/components/base/forms/index.js +1 -1
- package/dist/components/base/table/index.cjs +1 -1
- package/dist/components/base/table/index.js +1 -1
- package/dist/components/composed/admin/index.cjs +1 -1
- package/dist/components/composed/admin/index.js +2 -2
- package/dist/components/composed/ai/index.cjs +1 -1
- package/dist/components/composed/ai/index.js +2 -2
- package/dist/components/composed/analytics/index.cjs +1 -1
- package/dist/components/composed/analytics/index.js +1 -1
- package/dist/components/composed/cards/index.cjs +1 -1
- package/dist/components/composed/cards/index.js +2 -2
- package/dist/components/composed/commerce/index.cjs +1 -1
- package/dist/components/composed/commerce/index.js +2 -2
- package/dist/components/composed/dark-surfaces/index.cjs +1 -1
- package/dist/components/composed/dark-surfaces/index.js +1 -1
- package/dist/components/composed/data-display/index.cjs +1 -1
- package/dist/components/composed/data-display/index.js +1 -1
- package/dist/components/composed/data-display/metadata/metadata-list.d.ts.map +1 -1
- package/dist/components/composed/navigation/index.cjs +1 -1
- package/dist/components/composed/navigation/index.js +1 -1
- package/dist/components/composed/timelines/index.cjs +1 -1
- package/dist/components/composed/timelines/index.js +1 -1
- package/dist/components/features/activities/index.cjs +1 -1
- package/dist/components/features/activities/index.js +1 -1
- package/dist/components/features/card/index.cjs +1 -1
- package/dist/components/features/card/index.js +1 -1
- package/dist/components/features/comments/index.cjs +1 -1
- package/dist/components/features/comments/index.js +1 -1
- package/dist/components/features/event-log/index.cjs +1 -1
- package/dist/components/features/event-log/index.js +2 -2
- package/dist/components/features/media-library/index.cjs +1 -1
- package/dist/components/features/media-library/index.js +1 -1
- package/dist/components/features/products/index.cjs +1 -1
- package/dist/components/features/products/index.js +4 -4
- package/dist/components/features/resource/index.cjs +1 -1
- package/dist/components/features/resource/index.js +2 -2
- package/dist/components/features/schema-form/index.cjs +1 -1
- package/dist/components/features/schema-form/index.js +2 -2
- package/dist/components/layout/auth/index.cjs +1 -1
- package/dist/components/layout/auth/index.js +1 -1
- package/dist/components/layout/index.cjs +1 -1
- package/dist/components/layout/index.js +3 -3
- package/dist/components/layout/page/index.cjs +1 -1
- package/dist/components/layout/page/index.js +1 -1
- package/dist/components/layout/settings/index.cjs +1 -1
- package/dist/components/layout/settings/index.js +1 -1
- package/dist/showcase/assets/{AreaChart-CFYg5vW0.js → AreaChart-Y0ZwblHU.js} +1 -1
- package/dist/showcase/assets/{CompositeItem-C1v8tfgt.js → CompositeItem-BIY_Cp7P.js} +1 -1
- package/dist/showcase/assets/{CompositeRoot-DVtTCBlx.js → CompositeRoot-DSPvBRQr.js} +1 -1
- package/dist/showcase/assets/{DialogTrigger-CiVZgbZe.js → DialogTrigger-DHUp8vXe.js} +1 -1
- package/dist/showcase/assets/{LabelableContext-CNcXHqnK.js → LabelableContext-CasUI4hR.js} +1 -1
- package/dist/showcase/assets/{PreviewLayout-CBTybzKu.js → PreviewLayout-B_l930k0.js} +1 -1
- package/dist/showcase/assets/{RadioGroup-DTNAD-0J.js → RadioGroup-BgZ-UH79.js} +1 -1
- package/dist/showcase/assets/{ScrollAreaCorner-Gau2B-d1.js → ScrollAreaCorner-BbwFElLA.js} +1 -1
- package/dist/showcase/assets/{Separator-DOIh4aar.js → Separator-dQuencsA.js} +1 -1
- package/dist/showcase/assets/{ToolbarRootContext-BbugmthZ.js → ToolbarRootContext-BE0hbejq.js} +1 -1
- package/dist/showcase/assets/{accordion-CB4ePZYm.js → accordion-D93ZNsLn.js} +1 -1
- package/dist/showcase/assets/{accordion-variants-De2q5GIH.js → accordion-variants-Bl4bIQH4.js} +1 -1
- package/dist/showcase/assets/{action-menu-wJVcvfmC.js → action-menu--rEgMzDi.js} +1 -1
- package/dist/showcase/assets/{actions-BL1lpPFC.js → actions-3iedOWD9.js} +1 -1
- package/dist/showcase/assets/{activities-C578ZINa.js → activities-CyrAWFlu.js} +1 -1
- package/dist/showcase/assets/{activities-feed-card-BeXMgsNO.js → activities-feed-card-bhIATc2O.js} +1 -1
- package/dist/showcase/assets/{admin-DKJPb23G.js → admin-CZzNsj2q.js} +1 -1
- package/dist/showcase/assets/{ai-ewP8qLOJ.js → ai-CasHwkW4.js} +1 -1
- package/dist/showcase/assets/{ai-artifact-BaYtjrP5.js → ai-artifact-BgWvrLAb.js} +1 -1
- package/dist/showcase/assets/{ai-chat-DxxlaytU.js → ai-chat-seS9aW-1.js} +1 -1
- package/dist/showcase/assets/{ai-elements-BWraZPyC.js → ai-elements-Tku5_ous.js} +1 -1
- package/dist/showcase/assets/{ai-tool-call-Da4srLLe.js → ai-tool-call-BU6xbmXG.js} +1 -1
- package/dist/showcase/assets/{alert-CQI2pomK.js → alert-6Emt6KX2.js} +1 -1
- package/dist/showcase/assets/{alert-S12iMEhF.js → alert-B6aLWiRW.js} +1 -1
- package/dist/showcase/assets/{alert-xINZmLgm.js → alert-CtoTQ0vN.js} +1 -1
- package/dist/showcase/assets/{api-key-list-CL6je8dF.js → api-key-list-C0glWR3z.js} +1 -1
- package/dist/showcase/assets/{api-key-list-wxmuRN1m.js → api-key-list-DcWSbY3u.js} +1 -1
- package/dist/showcase/assets/{app-sidebar-LVtcgiT_.js → app-sidebar-D_eNP_jh.js} +1 -1
- package/dist/showcase/assets/arrow-down-qyKZ1H5j.js +1 -0
- package/dist/showcase/assets/arrow-left-C9I0h_su.js +1 -0
- package/dist/showcase/assets/arrow-right-DswaRsr6.js +1 -0
- package/dist/showcase/assets/arrow-up-5BijPOxK.js +1 -0
- package/dist/showcase/assets/arrow-up-right-CbVVNT6g.js +1 -0
- package/dist/showcase/assets/{avatar-Bv9x1eBh.js → avatar-BYHVCvVW.js} +1 -1
- package/dist/showcase/assets/{avatar-D29-FL5U.js → avatar-BlLAVC87.js} +1 -1
- package/dist/showcase/assets/{avatar-BEvs3dD_.js → avatar-DQTXjcS4.js} +1 -1
- package/dist/showcase/assets/{avatar-CC3R0R-x.js → avatar-DveZy09C.js} +1 -1
- package/dist/showcase/assets/{badge-B1YIk7bi.js → badge-Bth3mRTh.js} +1 -1
- package/dist/showcase/assets/{badge-check-DGmg0_g_.js → badge-check-DocF8Ho3.js} +1 -1
- package/dist/showcase/assets/{bell-Cq9n0a2v.js → bell-DXBoeAzi.js} +1 -1
- package/dist/showcase/assets/{bot-DxRjlJlO.js → bot-Ch-Y1HK8.js} +1 -1
- package/dist/showcase/assets/{box-CIh-_2DI.js → box-72m9QSDa.js} +1 -1
- package/dist/showcase/assets/{braces-BI_smuFG.js → braces-CC17X3TE.js} +1 -1
- package/dist/showcase/assets/{brain-BCAmDdGT.js → brain-Dvbla_5x.js} +1 -1
- package/dist/showcase/assets/{brand-CYmrK-FI.js → brand-D5ciAq8v.js} +1 -1
- package/dist/showcase/assets/{breadcrumb-DXOwTQNp.js → breadcrumb-BBCaOVyz.js} +1 -1
- package/dist/showcase/assets/{breadcrumb-DdDGc08y.js → breadcrumb-Bt8yVTCj.js} +1 -1
- package/dist/showcase/assets/{breadcrumbs-SwqzwYW_.js → breadcrumbs-CkVWfcAN.js} +1 -1
- package/dist/showcase/assets/{briefcase-CKrv_pkI.js → briefcase-8rQTJwpE.js} +1 -1
- package/dist/showcase/assets/{building-2-4f1nNGpT.js → building-2-CV7gTtXz.js} +1 -1
- package/dist/showcase/assets/{button-B9I1TrfQ.js → button-HGjoBio3.js} +1 -1
- package/dist/showcase/assets/{button-group-DUfRVZy2.js → button-group-LWToSCrp.js} +1 -1
- package/dist/showcase/assets/{buttons-Crl8nJKG.js → buttons-Bn_dX6Kk.js} +1 -1
- package/dist/showcase/assets/{calendar-4Uqeswbn.js → calendar-BTsffmY8.js} +1 -1
- package/dist/showcase/assets/{calendar-DxjW_eNc.js → calendar-Bhpyn4u0.js} +1 -1
- package/dist/showcase/assets/{calendar-Cl5l4Ip1.js → calendar-DjrUTKcD.js} +1 -1
- package/dist/showcase/assets/{calendar-days-DmDuaOAc.js → calendar-days-BKCkzWjV.js} +1 -1
- package/dist/showcase/assets/{camera-j8dT39qf.js → camera-EjpDG3mc.js} +1 -1
- package/dist/showcase/assets/{card-DRalKV4i.js → card-Bp6iGuOF.js} +1 -1
- package/dist/showcase/assets/{card-BQ_zBZlQ.js → card-CHc6AVFt.js} +1 -1
- package/dist/showcase/assets/card-primitives-Bv6XGPJd.js +1 -0
- package/dist/showcase/assets/{card-radio-group-Dq7AUPTp.js → card-radio-group-Ce9FsiSv.js} +1 -1
- package/dist/showcase/assets/{cards-MR2JolOy.js → cards-_CGG9zir.js} +1 -1
- package/dist/showcase/assets/{carousel-DMceNGDq.js → carousel-BVbsKH2W.js} +1 -1
- package/dist/showcase/assets/{cell-renderers-VbI9xEAd.js → cell-renderers-CosD6Gby.js} +1 -1
- package/dist/showcase/assets/{chart-DW4naldz.js → chart-CwOp8Sf8.js} +1 -1
- package/dist/showcase/assets/{chart-column-CbUwWFn7.js → chart-column-sz871NdJ.js} +1 -1
- package/dist/showcase/assets/{checkbox-BqwbtGCF.js → checkbox-BO38TYqr.js} +1 -1
- package/dist/showcase/assets/checkbox-W4MhlPlJ.js +1 -0
- package/dist/showcase/assets/chevron-down-BFh1Fz2P.js +1 -0
- package/dist/showcase/assets/chevron-left-C5_X5glO.js +1 -0
- package/dist/showcase/assets/chevron-up-DPH3boVS.js +1 -0
- package/dist/showcase/assets/chevrons-up-down-CM5mIDaw.js +1 -0
- package/dist/showcase/assets/circle-BFDzL1iF.js +1 -0
- package/dist/showcase/assets/{circle-alert-BObXfzSP.js → circle-alert-C6MbOB0m.js} +1 -1
- package/dist/showcase/assets/circle-check-C0X85t4j.js +1 -0
- package/dist/showcase/assets/circle-check-big-CBaodck_.js +1 -0
- package/dist/showcase/assets/circle-dot-DdRpIhnL.js +1 -0
- package/dist/showcase/assets/{circle-question-mark-BeRdyU_C.js → circle-question-mark-CKlcead7.js} +1 -1
- package/dist/showcase/assets/{circle-x-Dh3sb4UC.js → circle-x-MO44aKHe.js} +1 -1
- package/dist/showcase/assets/clock-3-CXQJFcbh.js +1 -0
- package/dist/showcase/assets/clock-GhBJJ6n1.js +1 -0
- package/dist/showcase/assets/{code-xml-q7JPxij0.js → code-xml-BSX7Qyi5.js} +1 -1
- package/dist/showcase/assets/{collapsible-DDV7VHy5.js → collapsible-CZLTO5EH.js} +1 -1
- package/dist/showcase/assets/{collapsible-BbiGHywy.js → collapsible-LrDO_sSQ.js} +1 -1
- package/dist/showcase/assets/{combobox-Dv_OkynR.js → combobox-TmDBXkM-.js} +1 -1
- package/dist/showcase/assets/{command-BSmiujfZ.js → command-9-r1qrJt.js} +1 -1
- package/dist/showcase/assets/{command-Cw81GF7c.js → command-DGne3l9s.js} +1 -1
- package/dist/showcase/assets/{comment-composer-C09JANlW.js → comment-composer-BI0qnvuY.js} +1 -1
- package/dist/showcase/assets/{comment-item-DsQshj1L.js → comment-item-Cedds6Lm.js} +1 -1
- package/dist/showcase/assets/{comments-CO3QCKyX.js → comments-De02NOns.js} +1 -1
- package/dist/showcase/assets/{commerce-BvnnX8Ui.js → commerce-DldtS83o.js} +1 -1
- package/dist/showcase/assets/{composite-BjZbcKJw.js → composite-BjZZlzzb.js} +1 -1
- package/dist/showcase/assets/{contact-card-Dq50G6UK.js → contact-card-muCZ3uXV.js} +1 -1
- package/dist/showcase/assets/{content-container-BQZdQhX2.js → content-container-BxSLICeL.js} +1 -1
- package/dist/showcase/assets/{copyable-BdfWxV6u.js → copyable-DYhhmTqM.js} +1 -1
- package/dist/showcase/assets/{copyable-lUNYfscm.js → copyable-MNU75-J9.js} +1 -1
- package/dist/showcase/assets/{course-card-BTIFY84q.js → course-card-Dl1wsuJx.js} +1 -1
- package/dist/showcase/assets/{cpu-CzkgJ-zb.js → cpu-CsWq4fcX.js} +1 -1
- package/dist/showcase/assets/{credit-card-D_wnXbTK.js → credit-card-B0AUZiWw.js} +1 -1
- package/dist/showcase/assets/{css-variables-BVjcOHGr.js → css-variables-Be7DzahT.js} +1 -1
- package/dist/showcase/assets/{currency-BCX6yQ2j.js → currency-BtPM_Xtw.js} +1 -1
- package/dist/showcase/assets/{dark-surfaces-BO6sWHrV.js → dark-surfaces-DRFERSEv.js} +1 -1
- package/dist/showcase/assets/{data-view-DqpNNGp5.js → data-view-DmWd0h7G.js} +2 -2
- package/dist/showcase/assets/{data-view-C8ThO9ha.js → data-view-DnLH2o0i.js} +1 -1
- package/dist/showcase/assets/{database-Ad0l2Bjl.js → database-C0YqGaQ_.js} +1 -1
- package/dist/showcase/assets/{date-block-CMKpiRdA.js → date-block-BQH25FLS.js} +1 -1
- package/dist/showcase/assets/{date-picker-CRogiefV.js → date-picker-BF-jevhh.js} +1 -1
- package/dist/showcase/assets/{date-pickers-CuRRGP-F.js → date-pickers-q2v3ajJm.js} +1 -1
- package/dist/showcase/assets/{dense-info-BL_cGFVK.js → dense-info-Cb-roqDU.js} +1 -1
- package/dist/showcase/assets/{design-system-consistency-BarrI2Uj.js → design-system-consistency-DMSJknaM.js} +1 -1
- package/dist/showcase/assets/{dialog-DbEG3v2T.js → dialog-C0ALRmbP.js} +1 -1
- package/dist/showcase/assets/{dialog-BEKecyE3.js → dialog-CbXon08k.js} +1 -1
- package/dist/showcase/assets/{display-utilities-CQRcCpjT.js → display-utilities-kBUVw7o3.js} +1 -1
- package/dist/showcase/assets/{dist-q3PLGr1_.js → dist-CTSkWj_M.js} +1 -1
- package/dist/showcase/assets/{dist-CS2Ky1_m.js → dist-W8bxVfew.js} +1 -1
- package/dist/showcase/assets/{dollar-sign-lghPxE96.js → dollar-sign-VNxVZleW.js} +1 -1
- package/dist/showcase/assets/{download-Cx5kUzHm.js → download-Ds_6eIpx.js} +1 -1
- package/dist/showcase/assets/{dropdown-menu-CXYQqRJA.js → dropdown-menu-C1G_y9dv.js} +1 -1
- package/dist/showcase/assets/{dropzone-DK0kBLfC.js → dropzone-CxOLmdkt.js} +1 -1
- package/dist/showcase/assets/{earth-BgJkqIAs.js → earth-HLyEI1oq.js} +1 -1
- package/dist/showcase/assets/{ellipsis-CP0hyAeS.js → ellipsis-BLyAd9A-.js} +1 -1
- package/dist/showcase/assets/{ellipsis-vertical-BdpRiDbb.js → ellipsis-vertical-TG4mYU2J.js} +1 -1
- package/dist/showcase/assets/{empty-CO_e2e_g.js → empty-B54k9xAG.js} +1 -1
- package/dist/showcase/assets/{empty-item-D39AT9RK.js → empty-item-BmA4rmq7.js} +1 -1
- package/dist/showcase/assets/{empty-state-Luba-tbF.js → empty-state-CH7gjjg7.js} +1 -1
- package/dist/showcase/assets/{empty-state-CTQjlkxC.js → empty-state-hUKvmKa-.js} +1 -1
- package/dist/showcase/assets/{enhanced-activities-e2k5R4sk.js → enhanced-activities-BRDVL9RR.js} +1 -1
- package/dist/showcase/assets/{enhanced-combobox-CY9QcVEl.js → enhanced-combobox-2wbQJS6R.js} +1 -1
- package/dist/showcase/assets/{esm-DPz8A4Wl.js → esm-CUTefMLr.js} +1 -1
- package/dist/showcase/assets/{event-calendar-DuQntfyO.js → event-calendar-Bf9xFZlt.js} +1 -1
- package/dist/showcase/assets/{event-log-B8B_0-q5.js → event-log-CeRDSL-h.js} +1 -1
- package/dist/showcase/assets/{example-Rrx9vj75.js → example-CJMJcnb4.js} +1 -1
- package/dist/showcase/assets/{external-link-BkCjE03j.js → external-link-CvXhYrnd.js} +1 -1
- package/dist/showcase/assets/{eye-BKhfxIeD.js → eye-Cl_GfUKH.js} +1 -1
- package/dist/showcase/assets/{feature-announcement-CRN6kk4B.js → feature-announcement-Dw0SokLo.js} +1 -1
- package/dist/showcase/assets/{file-BBUnjRPN.js → file-CJFWrwy1.js} +1 -1
- package/dist/showcase/assets/{file-text-Clv0qFr3.js → file-text-BTTFP8Jo.js} +1 -1
- package/dist/showcase/assets/{filter-layout-Bskvgeps.js → filter-layout-DUVqG5Ql.js} +1 -1
- package/dist/showcase/assets/{filters-DqE5xQEz.js → filters-BLcCaplV.js} +1 -1
- package/dist/showcase/assets/{flag-BQ0Brbw9.js → flag-BxI3EGPG.js} +1 -1
- package/dist/showcase/assets/{folder-open-CuUaUrxa.js → folder-open-4d8qsiAj.js} +1 -1
- package/dist/showcase/assets/{form-field-Dg_Az7lk.js → form-field-Dhy0eM5B.js} +1 -1
- package/dist/showcase/assets/{format-BnF8gL8z.js → format-zGqa9Olc.js} +1 -1
- package/dist/showcase/assets/{forms-D2SGtkKv.js → forms-D99qG5Gb.js} +1 -1
- package/dist/showcase/assets/{funnel-qCC9cfXa.js → funnel-Cg7SOShf.js} +1 -1
- package/dist/showcase/assets/{generic-0wwhvFWa.js → generic-CfrG943t.js} +1 -1
- package/dist/showcase/assets/{getPseudoElementBounds-DyTpOaBA.js → getPseudoElementBounds-lw5shsdM.js} +1 -1
- package/dist/showcase/assets/{gift-ibO6X3CO.js → gift-BXtKbzvA.js} +1 -1
- package/dist/showcase/assets/{giftcard-cards-BJ0gmgv0.js → giftcard-cards-CqYaN0jC.js} +1 -1
- package/dist/showcase/assets/{git-branch-QLvR3_wX.js → git-branch-BWAuIMOQ.js} +1 -1
- package/dist/showcase/assets/{global-search-BtYqFKyN.js → global-search-CHUva8pR.js} +1 -1
- package/dist/showcase/assets/{global-search-B2zvjiO2.js → global-search-Df7JovOG.js} +1 -1
- package/dist/showcase/assets/{globe-Byoz7QmA.js → globe-CvIW_foU.js} +1 -1
- package/dist/showcase/assets/{gradient-card-CymI8itB.js → gradient-card-CdM2J1Hv.js} +1 -1
- package/dist/showcase/assets/{hash-DL-sHZny.js → hash-wBs5gyr_.js} +1 -1
- package/dist/showcase/assets/{header-C9RMgEgD.js → header-DXPFmpUT.js} +1 -1
- package/dist/showcase/assets/{header-notifications-BT643QVK.js → header-notifications-FsnCJLpe.js} +1 -1
- package/dist/showcase/assets/{heart-gHsYuS4V.js → heart-B4fOMIr6.js} +1 -1
- package/dist/showcase/assets/{hooks-Dj4gswMj.js → hooks-DtMOMalj.js} +1 -1
- package/dist/showcase/assets/{house-Dew9jimg.js → house-hebmAxEE.js} +1 -1
- package/dist/showcase/assets/{icon-badge-GMIN-bca.js → icon-badge-DrZ5qGpa.js} +1 -1
- package/dist/showcase/assets/{icon-badge-C-mGQdGQ.js → icon-badge-JEug_P_U.js} +1 -1
- package/dist/showcase/assets/{image-Cda8layy.js → image-CxNywgkb.js} +1 -1
- package/dist/showcase/assets/{inbox-hJEV8TEx.js → inbox-DqAmGdDd.js} +1 -1
- package/dist/showcase/assets/index-DujM0kEF.css +2 -0
- package/dist/showcase/assets/{index-o71HAmc3.js → index-jD-KSiHu.js} +2 -2
- package/dist/showcase/assets/inertValue-Dg9TwvOb.js +1 -0
- package/dist/showcase/assets/{info-B4aULRpz.js → info-B5fZn_ZC.js} +1 -1
- package/dist/showcase/assets/{inline-stat-CDQocPgN.js → inline-stat-CklKufoA.js} +1 -1
- package/dist/showcase/assets/{inline-stat-BzXB3FNC.js → inline-stat-Dep7oHIi.js} +1 -1
- package/dist/showcase/assets/{input-CYTQ9nWN.js → input-CkNgwwCs.js} +1 -1
- package/dist/showcase/assets/{input-CLysAarX.js → input-DAPMRlKO.js} +1 -1
- package/dist/showcase/assets/{input-group-DYMTMed1.js → input-group-06D68uB6.js} +1 -1
- package/dist/showcase/assets/{input-group-DtkAnPaQ.js → input-group-Bq9aXQPG.js} +1 -1
- package/dist/showcase/assets/{inputs-C2flJn12.js → inputs-C8G3y-zR.js} +1 -1
- package/dist/showcase/assets/{installation-CCvBKDNO.js → installation-BV5xOvoE.js} +1 -1
- package/dist/showcase/assets/{invoice-header-C1G_aVIm.js → invoice-header-BcUxzT68.js} +1 -1
- package/dist/showcase/assets/{invoice-items-Ak0CMjDh.js → invoice-items-B42Jfxl7.js} +1 -1
- package/dist/showcase/assets/{invoice-mini-B7Dda49y.js → invoice-mini-RJGdlErg.js} +1 -1
- package/dist/showcase/assets/{invoice-table-Bl9InDl0.js → invoice-table--MdP6ysv.js} +1 -1
- package/dist/showcase/assets/isSameDay-srttAIjD.js +1 -0
- package/dist/showcase/assets/isToday-BPub5Zvi.js +1 -0
- package/dist/showcase/assets/{italic-CJzEjX5j.js → italic-1BNA_XlU.js} +1 -1
- package/dist/showcase/assets/{item-BL_Y_0ou.js → item-B9KyqUGa.js} +1 -1
- package/dist/showcase/assets/{item-nf1zOtF7.js → item-DoIlPm6J.js} +1 -1
- package/dist/showcase/assets/{item-Oe2aHuvr.js → item-ffIfXEGd.js} +1 -1
- package/dist/showcase/assets/{kanban-CB5Hghoo.js → kanban-Cfad3edR.js} +1 -1
- package/dist/showcase/assets/{key-round-BQwcojkz.js → key-round-J11Zc216.js} +1 -1
- package/dist/showcase/assets/{label-HtkE4eII.js → label-DqaB8ZB2.js} +1 -1
- package/dist/showcase/assets/{languages-69N5-h2e.js → languages-D9UaP3QU.js} +1 -1
- package/dist/showcase/assets/{layers-CBPYgoAb.js → layers-QXZ9Jfej.js} +1 -1
- package/dist/showcase/assets/{layout-app-shell-BfNh8jd0.js → layout-app-shell-CW1eRJmU.js} +1 -1
- package/dist/showcase/assets/{layout-auth-Ct29XkSH.js → layout-auth-j4K6lveg.js} +1 -1
- package/dist/showcase/assets/{layout-containers-DWN4xKbf.js → layout-containers-NclLtsV0.js} +1 -1
- package/dist/showcase/assets/{layout-header-DUX4zFrH.js → layout-header-B8AOTiwL.js} +1 -1
- package/dist/showcase/assets/{layout-page-CsqULW71.js → layout-page-DM79QHyW.js} +1 -1
- package/dist/showcase/assets/{layout-primitives-CQJ0_wTo.js → layout-primitives-Dyop-WMt.js} +1 -1
- package/dist/showcase/assets/{layout-sidebar-la-tC4xZ.js → layout-sidebar-uBNaHqjD.js} +1 -1
- package/dist/showcase/assets/{layout-users-6fAYxZ3Z.js → layout-users-BkhDiOOz.js} +1 -1
- package/dist/showcase/assets/{layout-workspace-BbDOjmrE.js → layout-workspace-C2hSimZW.js} +1 -1
- package/dist/showcase/assets/{lib-C46V0Rr-.js → lib-CDssULuD.js} +1 -1
- package/dist/showcase/assets/{list-checks-BkQYzehf.js → list-checks-DA2jqXdm.js} +1 -1
- package/dist/showcase/assets/{lock-CMrS2EKU.js → lock-BDZLNQLR.js} +1 -1
- package/dist/showcase/assets/{lock-keyhole-B1BEkNvm.js → lock-keyhole-CWYENd9O.js} +1 -1
- package/dist/showcase/assets/{mail-Bo_4xDQw.js → mail-CCdaRmft.js} +1 -1
- package/dist/showcase/assets/{mail-check-BprACMug.js → mail-check-DZF1VbCX.js} +1 -1
- package/dist/showcase/assets/{map-Br-xZYf0.js → map-CDFEmmZH.js} +3 -3
- package/dist/showcase/assets/{map-pin-COrIVMWa.js → map-pin-CdV-R6nt.js} +1 -1
- package/dist/showcase/assets/{media-library-DyPu-kR9.js → media-library-BJyn1s9d.js} +1 -1
- package/dist/showcase/assets/{mention-inline-suggestions-BTunE4RJ.js → mention-inline-suggestions-DPO6FhXx.js} +1 -1
- package/dist/showcase/assets/{mentions-BXSq2eCS.js → mentions-DtWHbcS6.js} +1 -1
- package/dist/showcase/assets/{menus-USrp5qP5.js → menus-BmjngFE4.js} +1 -1
- package/dist/showcase/assets/{message-square-Cyrr-QgJ.js → message-square-bM29txT3.js} +1 -1
- package/dist/showcase/assets/{metadata-list-BJTye3J8.js → metadata-list-DvYTAJri.js} +1 -1
- package/dist/showcase/assets/metadata-list-xVUTVyy9.js +1 -0
- package/dist/showcase/assets/{metric-DdC_pWnF.js → metric-BPNCh4eA.js} +1 -1
- package/dist/showcase/assets/{metric-bar-PGG8KQS0.js → metric-bar-BX4sCMrM.js} +1 -1
- package/dist/showcase/assets/{metric-grid-ZqDufV_5.js → metric-grid-IyHP3nmU.js} +1 -1
- package/dist/showcase/assets/{metric-trend-chip-BhCRReMp.js → metric-trend-chip-Dih8eR17.js} +1 -1
- package/dist/showcase/assets/{metrics-analytics-bar-U3gehGfQ.js → metrics-analytics-bar-DK16RNMs.js} +1 -1
- package/dist/showcase/assets/{metrics-analytics-cards-CzbLGAWi.js → metrics-analytics-cards-Byyl13YT.js} +1 -1
- package/dist/showcase/assets/{metrics-comparison-B1z3nUpo.js → metrics-comparison-DGHFMBL-.js} +1 -1
- package/dist/showcase/assets/{metrics-heatmap-DZeqRxFz.js → metrics-heatmap-Bl6C7i0j.js} +1 -1
- package/dist/showcase/assets/{metrics-inline-badge-CPyhCHXj.js → metrics-inline-badge-Bz79zbNK.js} +1 -1
- package/dist/showcase/assets/{metrics-kpi-row-COVuNReW.js → metrics-kpi-row-DzZ9dRFY.js} +1 -1
- package/dist/showcase/assets/{metrics-micro-grid-BNSrw6sM.js → metrics-micro-grid-DyoQiuzr.js} +1 -1
- package/dist/showcase/assets/{metrics-overview-3IHComMd.js → metrics-overview-DoyHPEZw.js} +1 -1
- package/dist/showcase/assets/{metrics-stat-cards-6Owbjvmc.js → metrics-stat-cards-B1b7NFqW.js} +1 -1
- package/dist/showcase/assets/minus-BE2L5hVc.js +1 -0
- package/dist/showcase/assets/{money-display-CUkeS9k1.js → money-display-CXQ_8LfA.js} +1 -1
- package/dist/showcase/assets/{month-year-picker-CCCTmZHv.js → month-year-picker-ra8FEN8F.js} +1 -1
- package/dist/showcase/assets/{navigation-BUReVn4R.js → navigation-CFfVZQJ1.js} +1 -1
- package/dist/showcase/assets/{navigation-CSzYKdcR.js → navigation-Da0MVkqr.js} +1 -1
- package/dist/showcase/assets/{navigation-extras-DmUhDPMz.js → navigation-extras-LpsdoXfx.js} +1 -1
- package/dist/showcase/assets/{onboarding-checklist-C3JhV5Gb.js → onboarding-checklist-DPNatNOk.js} +1 -1
- package/dist/showcase/assets/{overflow-tab-bar-CEdrls-W.js → overflow-tab-bar-C0vTzcEY.js} +1 -1
- package/dist/showcase/assets/{overlays-C1UodoAu.js → overlays-Blmbun0J.js} +1 -1
- package/dist/showcase/assets/{overlays-BKKEzmF4.js → overlays-t0joc10Y.js} +1 -1
- package/dist/showcase/assets/{overview-Dq0MqK32.js → overview-Ckq8vbOR.js} +1 -1
- package/dist/showcase/assets/{package-BaQGBJmO.js → package-Cjod_a06.js} +1 -1
- package/dist/showcase/assets/{package-check-C8HJfDxS.js → package-check-JRHaNnkl.js} +1 -1
- package/dist/showcase/assets/{page-DvMaeo43.js → page-9xr7xnuW.js} +1 -1
- package/dist/showcase/assets/page-action-button-BRXnfsEx.js +1 -0
- package/dist/showcase/assets/{page-header-Y-96EPMp.js → page-header-Bdlxfn_9.js} +1 -1
- package/dist/showcase/assets/{pagination-yLAHxKpc.js → pagination-CeaYhOvv.js} +1 -1
- package/dist/showcase/assets/{pagination-Br1AfDte.js → pagination-DdZZHvNF.js} +1 -1
- package/dist/showcase/assets/{paperclip-BBDKiZeH.js → paperclip-BRM-yXTB.js} +1 -1
- package/dist/showcase/assets/{password-input-iwrucadb.js → password-input-1FVEugoO.js} +1 -1
- package/dist/showcase/assets/{pencil-BUhkJ_Nn.js → pencil-DiG2dQ8F.js} +1 -1
- package/dist/showcase/assets/{phone-DtJDFH70.js → phone-BREyNZN-.js} +1 -1
- package/dist/showcase/assets/plus-CQcelTNc.js +1 -0
- package/dist/showcase/assets/{popover-C8YAdHfL.js → popover-Czmwspmc.js} +1 -1
- package/dist/showcase/assets/{popover-menu-C5M9Up4M.js → popover-menu-beuCaiLt.js} +1 -1
- package/dist/showcase/assets/{popover-D9ZDWqLl.js → popover-uqk7myG2.js} +1 -1
- package/dist/showcase/assets/{products-DrKTk8Aw.js → products-DGNqIbLs.js} +1 -1
- package/dist/showcase/assets/{progress-CpD58Wl0.js → progress-D76Df908.js} +1 -1
- package/dist/showcase/assets/{progress-C1qKfCZB.js → progress-DjUprSDD.js} +1 -1
- package/dist/showcase/assets/{props-table-C6gPyO49.js → props-table-DoDq8Mvr.js} +1 -1
- package/dist/showcase/assets/{quote-BXTU9evS.js → quote-BvGGgyJ0.js} +1 -1
- package/dist/showcase/assets/{receipt-Dwc4p04P.js → receipt-rgnlMgyi.js} +1 -1
- package/dist/showcase/assets/{receipt-text-DBEu6Gym.js → receipt-text-CBQrVlnU.js} +1 -1
- package/dist/showcase/assets/{refinement-guide-DeO_yM8U.js → refinement-guide-B_BpIMxm.js} +1 -1
- package/dist/showcase/assets/{refresh-cw-BpV3OG_s.js → refresh-cw-C-yHy6B7.js} +1 -1
- package/dist/showcase/assets/{resolveValueLabel-DZTrDdG0.js → resolveValueLabel-0bwEvIG-.js} +1 -1
- package/dist/showcase/assets/{resource-BLGoRFou.js → resource-8f61BZ8t.js} +1 -1
- package/dist/showcase/assets/{resource-D5AQesdN.js → resource-BEh6R0gu.js} +1 -1
- package/dist/showcase/assets/{resource-selector-card-BKzeUE0k.js → resource-selector-card-DJwXY_Ms.js} +1 -1
- package/dist/showcase/assets/{rich-text-editor-k1dtT5bX.js → rich-text-editor-D433iv0N.js} +1 -1
- package/dist/showcase/assets/{rich-text-editor-DYkPamiq.js → rich-text-editor-vTRfWsOK.js} +1 -1
- package/dist/showcase/assets/rotate-ccw-JuE4H14F.js +1 -0
- package/dist/showcase/assets/{route-5uO9C0gV.js → route-eSu1bFNn.js} +1 -1
- package/dist/showcase/assets/{save-DONvClxa.js → save-Bpjj-rBP.js} +1 -1
- package/dist/showcase/assets/{schema-form-BMQmx4JI.js → schema-form-DmOpxd96.js} +1 -1
- package/dist/showcase/assets/{scroll-area-CxwfyjX3.js → scroll-area-B9OdCBy9.js} +1 -1
- package/dist/showcase/assets/{scroll-area-CnAyhKQ_.js → scroll-area-BH80l2As.js} +1 -1
- package/dist/showcase/assets/{section-Dd6X6IKg.js → section-BPNIPavy.js} +1 -1
- package/dist/showcase/assets/{select-CJSyu7sS.js → select-BauiG1a3.js} +1 -1
- package/dist/showcase/assets/{select-Du9VvUxt.js → select-CPopSr5c.js} +1 -1
- package/dist/showcase/assets/{send-3ANJL7UB.js → send-DNCcBKXs.js} +1 -1
- package/dist/showcase/assets/{separator-BiXjWmP-.js → separator-BK0beCOv.js} +1 -1
- package/dist/showcase/assets/{separator-y9i6EG-N.js → separator-CKM9A-mm.js} +1 -1
- package/dist/showcase/assets/{settings-2-Ynd1Lcz4.js → settings-2-B8fz7JZB.js} +1 -1
- package/dist/showcase/assets/{settings-CqdZB-OI.js → settings-Cy2y3sQw.js} +1 -1
- package/dist/showcase/assets/{sheet-CzFOcAwE.js → sheet-C7VWkXE1.js} +1 -1
- package/dist/showcase/assets/{shield-Dmxwcn3w.js → shield-ClPev4gS.js} +1 -1
- package/dist/showcase/assets/{shield-alert-RrMsBuWp.js → shield-alert-6XO5YZ5u.js} +1 -1
- package/dist/showcase/assets/{shield-check-Bnw8RAvI.js → shield-check-DSfGVZq0.js} +1 -1
- package/dist/showcase/assets/{shopping-bag-DGXTQNOf.js → shopping-bag-DzMrGvpF.js} +1 -1
- package/dist/showcase/assets/{showcase-DMRZCqmg.js → showcase-DuZaO6q9.js} +1 -1
- package/dist/showcase/assets/{sidebar-C0tsWnrh.js → sidebar-7y9EQYWf.js} +1 -1
- package/dist/showcase/assets/{sidebar.context-DXGEPgaT.js → sidebar.context-DUheJD8t.js} +1 -1
- package/dist/showcase/assets/{skeleton-BFa4FHSC.js → skeleton-Dgr8Vabr.js} +1 -1
- package/dist/showcase/assets/{skeleton-DOJ1RAcJ.js → skeleton-HSpErFqw.js} +1 -1
- package/dist/showcase/assets/{slider-BjQs0C8N.js → slider-B7f81APg.js} +1 -1
- package/dist/showcase/assets/{smart-card-BwSFemlj.js → smart-card-p97LLZCW.js} +1 -1
- package/dist/showcase/assets/{sonner-BXMIK3eQ.js → sonner-CWazrN19.js} +1 -1
- package/dist/showcase/assets/{sortable.esm-BeBA3gT5.js → sortable.esm-uufol7Mz.js} +1 -1
- package/dist/showcase/assets/{sparkles-Bc0I4qTf.js → sparkles-Z4V23xKK.js} +1 -1
- package/dist/showcase/assets/{spinner-mtwVRe8M.js → spinner-BUgjAjWE.js} +1 -1
- package/dist/showcase/assets/{spinner-HyNCtTyd.js → spinner-CXu7z8-j.js} +1 -1
- package/dist/showcase/assets/{spinner-LskR5l9T.js → spinner-DCwR0mnD.js} +1 -1
- package/dist/showcase/assets/{square-pen-BrZ2OxTe.js → square-pen-jwp_OWMQ.js} +1 -1
- package/dist/showcase/assets/{stacked-avatars-DOAFRjmZ.js → stacked-avatars-CHEpTotO.js} +1 -1
- package/dist/showcase/assets/{star-lUSxI166.js → star-Ck8Lg5hm.js} +1 -1
- package/dist/showcase/assets/startOfDay-BzULZHy4.js +1 -0
- package/dist/showcase/assets/{styles-COpnijXU.js → styles-CNYitflH.js} +1 -1
- package/dist/showcase/assets/{suggestions-ftPYc9p6.js → suggestions-CSF9MlKl.js} +1 -1
- package/dist/showcase/assets/{switch-DirKCDsg.js → switch-BX9KSLIF.js} +1 -1
- package/dist/showcase/assets/{switch-DoPIN_UN.js → switch-Bn0WaWa9.js} +1 -1
- package/dist/showcase/assets/{sync-C2DEiaQz.js → sync-BuKBnqWW.js} +1 -1
- package/dist/showcase/assets/{table-Dex8CcfW.js → table-DNJcLaud.js} +42 -20
- package/dist/showcase/assets/{table-D6GywZEx.js → table-NfpOWGsG.js} +1 -1
- package/dist/showcase/assets/{table-actions-CJg82sW0.js → table-actions-Ci9Yszp0.js} +1 -1
- package/dist/showcase/assets/{tabs-C0fSpkON.js → tabs-CYNFQdIr.js} +1 -1
- package/dist/showcase/assets/{tabs-B9tgdMRD.js → tabs-Cm_p6znb.js} +1 -1
- package/dist/showcase/assets/{tags-input-CJSpILy6.js → tags-input-DE4QZqS_.js} +1 -1
- package/dist/showcase/assets/{text-button-CoPZBQiq.js → text-button-D9llh4pU.js} +1 -1
- package/dist/showcase/assets/{text-link-d9JIRU2N.js → text-link-ZT6QGJOL.js} +1 -1
- package/dist/showcase/assets/{textarea-BN4PUX-V.js → textarea-CgcHuGVq.js} +1 -1
- package/dist/showcase/assets/{textarea-CBhdtg5X.js → textarea-D2uT_GJt.js} +1 -1
- package/dist/showcase/assets/{timelines-F_mzbAPA.js → timelines-BEFO7tJ0.js} +1 -1
- package/dist/showcase/assets/{toggle-group-8ESepeYW.js → toggle-group-oYpa59lN.js} +1 -1
- package/dist/showcase/assets/{toggles-B2Cg5NVG.js → toggles-BL93YmQo.js} +1 -1
- package/dist/showcase/assets/{toggles-group-BTmtSzAa.js → toggles-group-BG-xiQCY.js} +1 -1
- package/dist/showcase/assets/{tooltip-DNsHZ3ZE.js → tooltip-BMI7zHwP.js} +1 -1
- package/dist/showcase/assets/{trash-2-Bf5dpRjn.js → trash-2-CtRtVsCy.js} +1 -1
- package/dist/showcase/assets/trending-up-2NQ-P8vB.js +1 -0
- package/dist/showcase/assets/{truck-CqmeajvP.js → truck-Cl0nyN_j.js} +1 -1
- package/dist/showcase/assets/{typography-DJjQO_Ld.js → typography-C7pCPhg7.js} +1 -1
- package/dist/showcase/assets/{ui-badge-BwkZfeBs.js → ui-badge-BvmuMzSq.js} +1 -1
- package/dist/showcase/assets/{ui-card-B3mtVa60.js → ui-card-B7ziOMAn.js} +1 -1
- package/dist/showcase/assets/{ui-table-DM-avYTi.js → ui-table-BEFHakBU.js} +1 -1
- package/dist/showcase/assets/{upload-tray-CFI_7lcB.js → upload-tray-CMKqTtEp.js} +1 -1
- package/dist/showcase/assets/{use-layout-link-BI4MRSHG.js → use-layout-link-nEU6ctSs.js} +1 -1
- package/dist/showcase/assets/{useAnchoredPopupScrollLock-DRs8fnir.js → useAnchoredPopupScrollLock-B1xyKMh7.js} +1 -1
- package/dist/showcase/assets/{useAriaLabelledBy-DhgmwFn7.js → useAriaLabelledBy-BMlFgz-H.js} +1 -1
- package/dist/showcase/assets/{useCollapsiblePanel-vGthv_MA.js → useCollapsiblePanel-BEzH6TC2.js} +1 -1
- package/dist/showcase/assets/{useCompositeItem-g1FeYTbw.js → useCompositeItem-CIuww7-p.js} +1 -1
- package/dist/showcase/assets/{useCompositeListItem-CyULeWSL.js → useCompositeListItem-PrMTh4tz.js} +1 -1
- package/dist/showcase/assets/{useLabelableId-CBWpOnwZ.js → useLabelableId-BBLkeLGr.js} +1 -1
- package/dist/showcase/assets/{useOpenInteractionType-CQSuD7yw.js → useOpenInteractionType-CW0quo3l.js} +1 -1
- package/dist/showcase/assets/useRender-6NNMHJJU.js +1 -0
- package/dist/showcase/assets/{useTriggerFocusGuards-B6KAsVMk.js → useTriggerFocusGuards-DEza_iee.js} +1 -1
- package/dist/showcase/assets/{useValueChanged-DXek_Wx7.js → useValueChanged-BmWIb3SN.js} +1 -1
- package/dist/showcase/assets/user-BDIP5UPS.js +1 -0
- package/dist/showcase/assets/{user-plus-C69GplWt.js → user-plus-BCqHFh2h.js} +1 -1
- package/dist/showcase/assets/{users-DDgUGkgw.js → users-Bh7xGRX2.js} +1 -1
- package/dist/showcase/assets/{vendor-profile-Zfh99jtA.js → vendor-profile-BlYcRbPI.js} +1 -1
- package/dist/showcase/assets/{video-CDERYmRS.js → video-BucshqNW.js} +1 -1
- package/dist/showcase/assets/{wrench-PjtfaRuJ.js → wrench-DQvhyTEb.js} +1 -1
- package/dist/showcase/assets/x-DyuS4YRT.js +1 -0
- package/dist/showcase/assets/{zap-CzjU6LH0.js → zap-Dpn8_pnQ.js} +1 -1
- package/dist/showcase/index.html +2 -2
- package/dist/style.css +1 -1
- package/package.json +1 -1
- package/dist/_shared/cards-BKFwMTjM.cjs +0 -2
- package/dist/_shared/cards-BKFwMTjM.cjs.map +0 -1
- package/dist/_shared/cards-CtBoSZG9.js.map +0 -1
- package/dist/_shared/table-CUA_A-oO.js.map +0 -1
- package/dist/_shared/table-mPchjiRn.cjs +0 -2
- package/dist/_shared/table-mPchjiRn.cjs.map +0 -1
- package/dist/showcase/assets/arrow-down-JuqwH6gj.js +0 -1
- package/dist/showcase/assets/arrow-left-BFq65-Ch.js +0 -1
- package/dist/showcase/assets/arrow-right-B4iFg3l1.js +0 -1
- package/dist/showcase/assets/arrow-up-RWJP_FHU.js +0 -1
- package/dist/showcase/assets/arrow-up-right-DdWl37XF.js +0 -1
- package/dist/showcase/assets/card-primitives-Bn6nhqUA.js +0 -1
- package/dist/showcase/assets/checkbox-BJ1yDAQ3.js +0 -1
- package/dist/showcase/assets/chevron-down-CBa5t2E0.js +0 -1
- package/dist/showcase/assets/chevron-left-Dqne-r3m.js +0 -1
- package/dist/showcase/assets/chevron-up-DiMFydbr.js +0 -1
- package/dist/showcase/assets/chevrons-up-down-umMKLBIL.js +0 -1
- package/dist/showcase/assets/circle-check-BPhdxh7K.js +0 -1
- package/dist/showcase/assets/circle-check-big-BsQpd0CS.js +0 -1
- package/dist/showcase/assets/circle-dbSBYjvr.js +0 -1
- package/dist/showcase/assets/circle-dot-Bj1an-fp.js +0 -1
- package/dist/showcase/assets/clock-3-R65SwQwa.js +0 -1
- package/dist/showcase/assets/clock-BApGqXwn.js +0 -1
- package/dist/showcase/assets/index-CCxHwV7T.css +0 -2
- package/dist/showcase/assets/inertValue-BRyHstYf.js +0 -1
- package/dist/showcase/assets/isSameDay-Bd_8WAf0.js +0 -1
- package/dist/showcase/assets/isToday-DSGtoEUa.js +0 -1
- package/dist/showcase/assets/metadata-list-CoRYXjEw.js +0 -1
- package/dist/showcase/assets/minus-CwzskYaZ.js +0 -1
- package/dist/showcase/assets/page-action-button-B5ZGYpYy.js +0 -1
- package/dist/showcase/assets/plus-4gOvUk-5.js +0 -1
- package/dist/showcase/assets/rotate-ccw-Dajwztf1.js +0 -1
- package/dist/showcase/assets/startOfDay-BLhx9b6k.js +0 -1
- package/dist/showcase/assets/trending-up-RSklVrcZ.js +0 -1
- package/dist/showcase/assets/useRender-Dm8qJkvr.js +0 -1
- package/dist/showcase/assets/user-B35DABNz.js +0 -1
- package/dist/showcase/assets/x-FNPo6qUv.js +0 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
import{d as e}from"./index-
|
|
1
|
+
import{d as e}from"./index-jD-KSiHu.js";import{n as t}from"./CSPContext-Bfs88_eg.js";function n(e,t){return Math.max(0,e-t)}function r(e,n){if(n<=0)return 0;let r=t(e,0,n),i=r,a=n-r,o=i<=1,s=a<=1;return o&&s?i<=a?0:n:o?0:s?n:r}var i=e(),a=`base-ui-disable-scrollbar`,o={className:a,getElement(e){return(0,i.jsx)(`style`,{nonce:e,href:a,precedence:`base-ui:low`,children:`.${a}{scrollbar-width:none}.${a}::-webkit-scrollbar{display:none}`})}};export{n,r,o as t};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{n as e,r as t}from"./chunk-QTnfLwEv.js";import{t as n}from"./react-sKtkuLrH.js";import{n as r,o as i,p as a,t as o}from"./section-
|
|
1
|
+
import{n as e,r as t}from"./chunk-QTnfLwEv.js";import{t as n}from"./react-sKtkuLrH.js";import{n as r,o as i,p as a,t as o}from"./section-BPNIPavy.js";import{t as s}from"./building-2-CV7gTtXz.js";import{r as c,t as l}from"./example-CJMJcnb4.js";import{N as u,a as d,d as f,n as p}from"./index-jD-KSiHu.js";import{t as m}from"./props-table-DoDq8Mvr.js";import{c as h,i as g,r as _,t as v,u as y}from"./item-ffIfXEGd.js";import{t as b}from"./enhanced-combobox-2wbQJS6R.js";import{t as x}from"./input-CkNgwwCs.js";var S=t(n(),1),C=e=>new Promise(t=>{setTimeout(t,e)});function w(e){let{fetchData:t,minQueryLength:n=1,debounceMs:r=250,requestDelay:i=0,preload:a=!1,onError:o}=e,[s,c]=(0,S.useState)([]),[l,u]=(0,S.useState)(``),[d,f]=(0,S.useState)(null),[p,m]=(0,S.useState)(!1),[h,g]=(0,S.useState)(!1),_=(0,S.useRef)(t),v=(0,S.useRef)(o);return _.current=t,v.current=o,(0,S.useEffect)(()=>{let e=!1,t=null;return l.length>=n||a&&l.length===0?(t=setTimeout(()=>{(async()=>{g(!0);try{i>0&&await C(i);let t=await _.current(l);e||c(Array.isArray(t)?t:[])}catch(t){e||(c(e=>e.length===0?e:[]),v.current?.(t,l))}finally{e||g(!1)}})()},r),()=>{e=!0,t&&clearTimeout(t)}):(c(e=>e.length===0?e:[]),()=>{t&&clearTimeout(t)})},[r,n,a,i,l]),{items:s,isLoading:h,searchValue:l,setSearchValue:u,selectedValue:d,setSelectedValue:f,open:p,setOpen:m}}var T={placeholder:`Search...`,emptyMessage:`No results found.`,loadingMessage:`Searching...`,startTypingMessage:`Type to search.`},E=f();function D(e){let{fetchData:t,itemKey:n,itemText:r,onValueChange:i,renderItem:a,minQueryLength:o=1,debounceMs:s=250,requestDelay:c=0,preload:l=!1,allowClear:d=!0,clearInputOnClose:f=!1,disabled:m=!1,className:h,onError:g,strings:_}=e,v=u(T,_),{items:y,isLoading:x,searchValue:C,setSearchValue:D,selectedValue:O,setSelectedValue:k,open:A,setOpen:j}=w({fetchData:t,minQueryLength:o,debounceMs:s,requestDelay:c,preload:l,onError:g}),M=(0,S.useMemo)(()=>({placeholder:v.placeholder,noResults:v.emptyMessage,searching:v.loadingMessage,typeToSearch:v.startTypingMessage}),[v]);return(0,E.jsx)(b,{className:p(`suggestions--component`,h),items:y,searchValue:C,onSearchValueChange:D,selectedValue:O,onSelectedValueChange:e=>{k(e),i?.(e)},getItemLabel:r,getItemKey:e=>String(n(e)),renderItem:a,minSearchLength:o,isLoading:x,strings:M,clearable:d,open:A,onOpenChange:e=>{j(e),!e&&f&&D(``)},disabled:m})}D.displayName=`SuggestionsCombobox`;var O=e({AccountSuggestionsCombobox:()=>j,HeadlessSuggestionsState:()=>M}),k=[{id:`northwind`,name:`Northwind Retail`,plan:`Pro`,region:`EU`},{id:`summit`,name:`Summit Tours`,plan:`Scale`,region:`US`},{id:`atlas`,name:`Atlas Supply`,plan:`Enterprise`,region:`APAC`}];async function A(e){let t=e.trim().toLowerCase();return t?k.filter(e=>`${e.name} ${e.plan} ${e.region}`.toLowerCase().includes(t)):k}function j(){let[e,t]=(0,S.useState)(null);return(0,E.jsxs)(`div`,{className:`max-w-md space-y-3`,children:[(0,E.jsx)(D,{fetchData:A,itemKey:e=>e.id,itemText:e=>e.name,onValueChange:t,preload:!0,minQueryLength:0,clearInputOnClose:!0,renderItem:e=>(0,E.jsxs)(v,{size:`small`,className:`border-0 bg-transparent p-0 shadow-none`,children:[(0,E.jsx)(h,{variant:`icon`,children:(0,E.jsx)(s,{className:`size-icon`,"aria-hidden":!0})}),(0,E.jsxs)(_,{children:[(0,E.jsx)(y,{children:e.name}),(0,E.jsxs)(g,{clamp:1,children:[e.plan,` - `,e.region]})]})]}),strings:{placeholder:`Search accounts`,emptyMessage:`No accounts match this query.`}}),e?(0,E.jsxs)(`div`,{className:`flex items-center gap-2`,children:[(0,E.jsx)(a,{size:`xs`,type:`secondary`,children:`Selected`}),(0,E.jsx)(i,{variant:`secondary`,children:e.name})]}):null]})}function M(){let e=w({fetchData:A,minQueryLength:1,debounceMs:0,preload:!1});return(0,E.jsxs)(`div`,{className:`max-w-md space-y-3`,children:[(0,E.jsxs)(`div`,{className:`flex gap-2`,children:[(0,E.jsx)(x,{value:e.searchValue,onChange:t=>e.setSearchValue(t.target.value),placeholder:`Type an account`}),(0,E.jsx)(c,{type:`button`,variant:`secondary`,icon:d,children:`Search`})]}),(0,E.jsx)(`div`,{className:`rounded-md border border-border/60`,children:e.items.length===0?(0,E.jsx)(`div`,{className:`px-3 py-2`,children:(0,E.jsx)(a,{size:`xs`,type:`secondary`,children:`Enter a query to load consumer-owned results.`})}):e.items.map(t=>(0,E.jsxs)(c,{type:`button`,variant:`secondary`,buttonStyle:`ghost`,fullWidth:!0,className:`h-auto justify-between rounded-none border-b border-border/50 px-3 py-2 text-left last:border-b-0`,onClick:()=>e.setSelectedValue(t),children:[(0,E.jsx)(a,{size:`sm`,weight:`medium`,children:t.name}),(0,E.jsx)(a,{size:`xs`,type:`secondary`,children:t.plan})]},t.id))})]})}var N=`import { useState } from 'react';
|
|
2
2
|
import { Building2, Search } from 'lucide-react';
|
|
3
3
|
|
|
4
4
|
import { Badge } from '@/components/base/badge';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{r as e}from"./chunk-QTnfLwEv.js";import{t}from"./react-sKtkuLrH.js";import{Gt as n,Qt as ee,Wt as te,ar as r,br as ne,cr as i,fr as a,g as re,lr as ie,mr as ae,nr as o,pr as oe,vn as se}from"./example-
|
|
1
|
+
import{r as e}from"./chunk-QTnfLwEv.js";import{t}from"./react-sKtkuLrH.js";import{Gt as n,Qt as ee,Wt as te,ar as r,br as ne,cr as i,fr as a,g as re,lr as ie,mr as ae,nr as o,pr as oe,vn as se}from"./example-CJMJcnb4.js";import{d as ce,n as s}from"./index-jD-KSiHu.js";import{t as c}from"./useControlled-BHUji6Sp.js";import{t as l}from"./useValueChanged-BmWIb3SN.js";import{c as u,n as d,o as f,r as p,t as m}from"./LabelableContext-CasUI4hR.js";import{t as h}from"./useLabelableId-BBLkeLGr.js";import{t as g}from"./useAriaLabelledBy-BMlFgz-H.js";var _=e(t(),1),v=_.createContext(void 0);function y(){let e=_.useContext(v);if(e===void 0)throw Error(a(63));return e}var b=function(e){return e.checked=`data-checked`,e.unchecked=`data-unchecked`,e.disabled=`data-disabled`,e.readonly=`data-readonly`,e.required=`data-required`,e.valid=`data-valid`,e.invalid=`data-invalid`,e.touched=`data-touched`,e.dirty=`data-dirty`,e.filled=`data-filled`,e.focused=`data-focused`,e}({}),x={...u,checked(e){return e?{[b.checked]:``}:{[b.unchecked]:``}}},S=ce(),C=_.forwardRef(function(e,t){let{checked:a,className:ce,defaultChecked:s,"aria-labelledby":u,form:y,id:b,inputRef:C,name:w,nativeButton:T=!1,onCheckedChange:E,readOnly:D=!1,required:O=!1,disabled:k=!1,render:le,uncheckedValue:A,value:j,style:ue,...M}=e,{clearErrors:N}=d(),{state:P,setTouched:F,setDirty:I,validityData:L,setFilled:R,setFocused:z,validationMode:de,disabled:B,name:V,validation:H}=f(),{labelId:U}=m(),W=B||k,G=V??w,K=_.useRef(null),fe=i(K,C,H.inputRef),q=_.useRef(null),J=re(),Y=h({id:b,implicit:!1,controlRef:q}),X=T?void 0:Y,[Z,pe]=c({controlled:a,default:!!s,name:`Switch`,state:`checked`});p(q,J,Z,void 0,!W,w),ae(()=>{K.current&&R(K.current.checked)},[K,R]),l(Z,()=>{N(G),I(Z!==L.initialValue),R(Z),H.change(Z)});let{getButtonProps:me,buttonRef:he}=ie({disabled:W,native:T}),ge=g(u,U,K,!T,X),_e={id:T?Y:J,role:`switch`,"aria-checked":Z,"aria-readonly":D||void 0,"aria-required":O||void 0,"aria-labelledby":ge,onFocus(){W||z(!0)},onBlur(){let e=K.current;!e||W||(F(!0),z(!1),de===`onBlur`&&H.commit(e.checked))},onClick(e){if(D||W)return;e.preventDefault();let t=K.current;t&&t.dispatchEvent(new(ne(t)).PointerEvent(`click`,{bubbles:!0,shiftKey:e.shiftKey,ctrlKey:e.ctrlKey,altKey:e.altKey,metaKey:e.metaKey}))}},Q=oe({checked:Z,disabled:W,form:y,id:X,name:G,required:O,style:G?n:te,tabIndex:-1,type:`checkbox`,"aria-hidden":!0,ref:fe,onChange(e){if(e.nativeEvent.defaultPrevented)return;if(D){e.preventDefault();return}let t=e.currentTarget.checked,n=ee(se,e.nativeEvent);E?.(t,n),!n.isCanceled&&pe(t)},onFocus(){q.current?.focus()}},e=>H.getValidationProps(W,e),j===void 0?r:{value:j}),$=_.useMemo(()=>({...P,checked:Z,disabled:W,readOnly:D,required:O}),[P,Z,W,D,O]),ve=o(`span`,e,{state:$,ref:[t,q,he],props:[_e,M,me,e=>H.getValidationProps(W,e)],stateAttributesMapping:x});return(0,S.jsxs)(v.Provider,{value:$,children:[ve,!Z&&G&&A!==void 0&&(0,S.jsx)(`input`,{type:`hidden`,form:y,name:G,value:A,disabled:W}),(0,S.jsx)(`input`,{...Q,suppressHydrationWarning:!0})]})}),w=_.forwardRef(function(e,t){let{render:n,className:ee,style:te,...r}=e;return o(`span`,e,{state:y(),ref:t,stateAttributesMapping:x,props:r})});function T({className:e,size:t=`default`,...n}){return(0,S.jsx)(C,{"data-slot":`switch`,"data-size":t,className:s(`data-checked:bg-primary data-unchecked:bg-input focus-visible:border-ring focus-visible:ring-ring/50 aria-invalid:ring-destructive/20 aria-invalid:border-destructive shrink-0 rounded-full border border-transparent focus-visible:ring-[3px] aria-invalid:ring-[3px] data-[size=default]:h-5 data-[size=default]:w-9 data-[size=sm]:h-4 data-[size=sm]:w-7 peer group/switch relative inline-flex items-center transition-all outline-none after:absolute after:-inset-x-3 after:-inset-y-2 data-disabled:cursor-not-allowed data-disabled:opacity-50`,e),...n,children:(0,S.jsx)(w,{"data-slot":`switch-thumb`,className:`bg-background rounded-full shadow-sm group-data-[size=default]/switch:size-4 group-data-[size=sm]/switch:size-3 group-data-[size=default]/switch:data-checked:translate-x-[16px] group-data-[size=sm]/switch:data-checked:translate-x-[12px] group-data-[size=default]/switch:data-unchecked:translate-x-0.5 group-data-[size=sm]/switch:data-unchecked:translate-x-0.5 pointer-events-none block ring-0 transition-transform`})})}export{T as t};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{r as e}from"./chunk-QTnfLwEv.js";import{t}from"./react-sKtkuLrH.js";import{d as n,n as r}from"./index-
|
|
1
|
+
import{r as e}from"./chunk-QTnfLwEv.js";import{t}from"./react-sKtkuLrH.js";import{d as n,n as r}from"./index-jD-KSiHu.js";import{t as i}from"./switch-BX9KSLIF.js";var a=e(t(),1),o=n(),s=(0,a.forwardRef)(function({onCheckedChange:e,invalid:t,className:n,...s},c){let l=(0,a.useId)(),u=(0,a.useMemo)(()=>s.name?String(s.name):s.id?String(s.id):`switch-${l}`,[l,s.id,s.name]),d=s.id??u,f=(0,a.useCallback)(t=>{e?.({target:{name:u,value:t}})},[u,e]);return(0,o.jsx)(i,{ref:c,...s,onCheckedChange:f,id:d,name:u,"aria-invalid":t||void 0,className:r(`switch--component`,t&&`data-[state=unchecked]:border-destructive`,n)})});s.displayName=`Switch`;var c=(0,a.forwardRef)(function({onCheckedChange:e,invalid:t,className:n,...a},s){return(0,o.jsx)(i,{ref:s,...a,onCheckedChange:t=>e?.(t),"aria-invalid":t||void 0,className:r(t&&`data-[state=unchecked]:border-destructive`,n)})});c.displayName=`ToggleSwitch`;export{c as n,s as t};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{n as e,r as t}from"./chunk-QTnfLwEv.js";import{t as n}from"./react-sKtkuLrH.js";import{n as r,p as i,t as a}from"./section-
|
|
1
|
+
import{n as e,r as t}from"./chunk-QTnfLwEv.js";import{t as n}from"./react-sKtkuLrH.js";import{n as r,p as i,t as a}from"./section-BPNIPavy.js";import{r as o,t as s}from"./example-CJMJcnb4.js";import{t as c}from"./clock-3-CXQJFcbh.js";import{t as l}from"./database-C0YqGaQ_.js";import{t as u}from"./receipt-text-CBQrVlnU.js";import{t as d}from"./refresh-cw-C-yHy6B7.js";import{N as f,d as p,n as m}from"./index-jD-KSiHu.js";import{t as h}from"./props-table-DoDq8Mvr.js";import{t as g}from"./label-DqaB8ZB2.js";import{t as _}from"./smart-card-p97LLZCW.js";import{i as v,t as y}from"./index.esm-BXmcbSs7.js";import{n as b,t as x}from"./card-radio-group-Ce9FsiSv.js";import{t as S}from"./dialog-C0ALRmbP.js";var C=e=>({getError:t=>{if(e)return e[t]},hasError:t=>e!==void 0&&e[t]!==void 0}),w={hoursLabel:`Sync window`,hoursDescription:`Choose how far back the integration should reconcile records.`,optionsLabel:`Options`,optionsDescription:`Limit the run when the repair only needs a specific record family.`},T=p(),E=e=>{let{formId:t,options:n,syncOptions:r,defaultHours:a=`24`,onSubmit:o,errors:s,strings:c}=e,l=f(w,c),{getError:u}=C(Object.fromEntries(Object.entries(s??{}).map(([e,t])=>[e,Array.isArray(t)?t[0]:t]))),{control:d,handleSubmit:p}=v({defaultValues:{hours:a,options:[]}});return(0,T.jsxs)(`form`,{id:t,onSubmit:p(e=>{o({hours:Number(e.hours),financials_only:e.options.includes(`financials_only`)})}),className:m(`sync-range-dialog-form--component`,`grid gap-4`),children:[(0,T.jsxs)(`section`,{className:`sync-range-dialog-form--section grid gap-2.5`,children:[(0,T.jsxs)(`div`,{className:`sync-range-dialog-form--section-header grid gap-1`,children:[(0,T.jsx)(g,{children:l.hoursLabel}),(0,T.jsx)(i,{size:`xs`,type:`secondary`,children:l.hoursDescription})]}),(0,T.jsx)(y,{name:`hours`,control:d,rules:{required:!0},render:({field:e})=>(0,T.jsx)(x,{options:n,value:e.value,onChange:e.onChange,name:e.name,columns:2,invalid:!!u(`hours`)})}),u(`hours`)&&(0,T.jsx)(i,{type:`error`,children:u(`hours`)})]}),!!r&&r.length>0&&(0,T.jsxs)(`section`,{className:`sync-range-dialog-form--section grid gap-2.5 rounded-md border border-border/70 bg-muted/20 p-3`,children:[(0,T.jsxs)(`div`,{className:`sync-range-dialog-form--section-header grid gap-1`,children:[(0,T.jsx)(g,{children:l.optionsLabel}),(0,T.jsx)(i,{size:`xs`,type:`secondary`,children:l.optionsDescription})]}),(0,T.jsx)(y,{name:`options`,control:d,render:({field:e})=>(0,T.jsx)(b,{options:r,value:e.value,onChange:e.onChange,columns:2})})]})]})};E.displayName=`SyncRangeDialogForm`;var D=e({InlineSyncForm:()=>N,SyncDialogPattern:()=>M}),O=t(n(),1),k=[{value:`6`,label:`6 hours`,description:`Recent corrections only.`,icon:c},{value:`24`,label:`24 hours`,description:`Recommended for daily operations.`,icon:l},{value:`48`,label:`48 hours`,description:`Use after a long import pause.`,icon:d}],A=[{value:`financials_only`,label:`Financial records only`,description:`Skip profile and note updates.`,icon:u}];function j({value:e}){return e?(0,T.jsxs)(i,{size:`xs`,type:`secondary`,children:[`Submitted `,e.hours,` hours`,e.financials_only?` with financial records only.`:` with all records.`]}):null}function M(){let[e,t]=(0,O.useState)(!1),[n,r]=(0,O.useState)(null);return(0,T.jsxs)(_,{title:`Integration repair`,description:`Launch a callback-owned sync flow from any page, card, or action menu.`,headerEnd:(0,T.jsx)(j,{value:n}),children:[(0,T.jsx)(o,{type:`button`,variant:`primary`,icon:d,onClick:()=>t(!0),children:`Open sync dialog`}),(0,T.jsx)(S,{open:e,onOpenChange:t,title:`Sync records`,description:`Choose how far back the integration should reconcile records.`,formId:`sync-range-dialog-form`,size:`lg`,children:(0,T.jsx)(E,{formId:`sync-range-dialog-form`,options:k,syncOptions:A,defaultHours:`24`,strings:{hoursLabel:`Reconciliation window`,optionsLabel:`Record scope`},onSubmit:e=>{r(e),t(!1)}})})]})}function N(){let[e,t]=(0,O.useState)(null);return(0,T.jsx)(_,{title:`Inline repair form`,description:`Use the same form in a page section when the host app owns the submit button placement.`,footerSlot:(0,T.jsxs)(`div`,{className:`flex items-center justify-between gap-3`,children:[(0,T.jsx)(j,{value:e}),(0,T.jsx)(o,{type:`submit`,form:`inline-sync-range-form`,variant:`primary`,children:`Run sync`})]}),className:`max-w-2xl`,children:(0,T.jsx)(E,{formId:`inline-sync-range-form`,options:k,syncOptions:A,defaultHours:`6`,onSubmit:t,strings:{hoursLabel:`Repair window`,optionsLabel:`Sync scope`}})})}var P=`import { useState } from 'react';
|
|
2
2
|
import { Clock3, Database, ReceiptText, RefreshCw } from 'lucide-react';
|
|
3
3
|
|
|
4
4
|
import { Button } from '@/components/base/buttons';
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{n as e,r as t}from"./chunk-QTnfLwEv.js";import{t as n}from"./react-sKtkuLrH.js";import{a as r,i,n as ee,t as a}from"./filter-layout-Bskvgeps.js";import{n as o,o as s,p as c,t as l}from"./section-Dd6X6IKg.js";import{t as u}from"./badge-check-DGmg0_g_.js";import{r as d,t as f}from"./example-Rrx9vj75.js";import{t as p}from"./circle-check-BPhdxh7K.js";import{t as m}from"./circle-x-Dh3sb4UC.js";import{t as h}from"./clock-BApGqXwn.js";import{a as g,i as te,n as ne,o as re,r as _,t as ie}from"./data-view-DqpNNGp5.js";import{t as ae}from"./shopping-bag-DGXTQNOf.js";import{t as v}from"./square-pen-BrZ2OxTe.js";import{t as y}from"./trash-2-Bf5dpRjn.js";import{t as b}from"./truck-CqmeajvP.js";import{t as x}from"./user-B35DABNz.js";import{a as S,d as C}from"./index-o71HAmc3.js";import{t as w}from"./props-table-C6gPyO49.js";import{t as oe}from"./icon-badge-GMIN-bca.js";import{t as se}from"./smart-card-BwSFemlj.js";import{t as ce}from"./customers-DvBxRjHv.js";import{t as le}from"./orders-BFwWtubb.js";import{t as ue}from"./input-CYTQ9nWN.js";import{a as de,i as fe,n as pe,o as me,r as he,s as ge,t as T}from"./cell-renderers-VbI9xEAd.js";import{t as E}from"./page-DvMaeo43.js";var D=e({BasicDefault:()=>M,CellRenderers:()=>U,ComfortableTable:()=>N,DataViewChrome:()=>J,EmptyState:()=>X,FilteredTabbedOrdersTable:()=>H,IndexTableCells:()=>W,PaginationExample:()=>L,RealisticOrdersTable:()=>V,StickyHeaderAndFirstColumn:()=>Y,SurfaceFlatInsideSmartCardTableRendersNoChrome:()=>F,SurfaceGlassHeaderTransparentCleanOutlineNoMutedHeader:()=>P,WithColumnVisibility:()=>K,WithCustomToolbar:()=>q,WithRowSelection:()=>G,WithSortingRowActions:()=>I}),O=t(n(),1),k=C(),A=[{id:`ORD-001`,customer:`Sarah Smitha`,amount:`2,450 USD`,status:`paid`,date:`Mar 24`},{id:`ORD-002`,customer:`Daniel Smith`,amount:`370 USD`,status:`pending`,date:`Mar 25`},{id:`ORD-003`,customer:`Emma Garcia`,amount:`320 USD`,status:`paid`,date:`Mar 26`},{id:`ORD-004`,customer:`David Williams`,amount:`580 USD`,status:`overdue`,date:`Mar 14`},{id:`ORD-005`,customer:`Nadia Kowalski`,amount:`120 USD`,status:`paid`,date:`Mar 27`}],j=[{accessorKey:`id`,header:`Order`,cell:({getValue:e})=>(0,k.jsxs)(`div`,{className:`flex items-center gap-space-md`,children:[(0,k.jsx)(oe,{icon:ae,size:`small`,shape:`square`,tone:`primary`}),(0,k.jsx)(c,{tag:`span`,size:`inherit`,weight:`semibold`,className:`font-mono`,children:String(e())})]})},{accessorKey:`customer`,header:`Customer`,cell:({row:e})=>(0,k.jsx)(T,{name:e.original.customer})},{accessorKey:`amount`,header:`Amount`,meta:{align:`end`},cell:({getValue:e})=>(0,k.jsx)(c,{tag:`span`,size:`inherit`,weight:`semibold`,className:`tabular-nums`,children:String(e())})},{accessorKey:`status`,header:`Status`,cell:({getValue:e})=>{let t=e();return(0,k.jsx)(s,{variant:t===`paid`?`success`:t===`pending`?`warning`:`error`,dot:!0,children:t})}},{accessorKey:`date`,header:`Date`,cell:({getValue:e})=>(0,k.jsx)(c,{tag:`span`,size:`inherit`,type:`secondary`,className:`tabular-nums`,children:String(e())})}];function M(){return(0,k.jsx)(g,{columns:j,data:A})}function N(){return(0,k.jsx)(g,{columns:j,data:A,size:`default`,rowActions:()=>[{id:`edit`,label:`Edit`,icon:(0,k.jsx)(v,{className:`size-icon`}),onClick:()=>{}},{id:`delete`,label:`Delete`,icon:(0,k.jsx)(y,{className:`size-icon`}),variant:`destructive`,onClick:()=>{}}]})}function P(){return(0,k.jsx)(g,{columns:j,data:A,surface:`glass`,headerTransparent:!0})}function F(){return(0,k.jsx)(se,{padding:`small`,className:`w-full min-w-0 max-w-full overflow-hidden`,children:(0,k.jsx)(g,{columns:j,data:A,surface:`flat`,headerTransparent:!0})})}function I(){return(0,k.jsx)(g,{columns:j,data:A,enableSorting:!0,rowActions:()=>[{id:`edit`,label:`Edit`,icon:(0,k.jsx)(v,{className:`size-icon`}),onClick:()=>{}},{id:`delete`,label:`Delete`,icon:(0,k.jsx)(y,{className:`size-icon`}),variant:`destructive`,onClick:()=>{}}]})}function L(){return(0,k.jsx)(re,{pagination:{current_page:3,last_page:12,per_page:10,total:117,path:`/orders`,prev_page_url:`/orders?page=2`,next_page_url:`/orders?page=4`},onPageChange:()=>{}})}var R=le.map(e=>({id:e.id,number:e.number,customer:ce.find(t=>t.id===e.customerId)?.name??`—`,totalUsd:e.totalUsd,status:e.status})),_e=[{label:`Paid`,value:`paid`,icon:null},{label:`Pending`,value:`pending`,icon:null},{label:`Shipped`,value:`shipped`,icon:null},{label:`Cancelled`,value:`cancelled`,icon:null}],ve=[...new Set(R.map(e=>e.customer))].map(e=>({label:e,value:e,icon:null})),z=[{key:`q`,label:`Search`,type:r.SEARCH,operator:i.CONTAINS,placeholder:`Search orders or customers…`,icon:(0,k.jsx)(S,{className:`size-icon`}),displayConfig:{display:`always`}},{key:`status`,label:`Status`,pluralLabel:`statuses`,type:r.MULTI_SELECT,operator:i.IN,icon:(0,k.jsx)(u,{className:`size-icon`}),displayConfig:{display:`always`},options:_e},{key:`customer`,label:`Customer`,type:r.MULTI_SELECT,operator:i.IN,icon:(0,k.jsx)(x,{className:`size-icon`}),displayConfig:{display:`collapsed`},options:ve}],ye=[{id:`all`,label:`All`,count:R.length,presets:[]},{id:`open`,label:`Open`,count:R.filter(e=>e.status===`pending`).length,presets:[{key:`status`,value:[`pending`],operator:i.IN}]},{id:`paid`,label:`Paid`,count:R.filter(e=>e.status===`paid`).length,presets:[{key:`status`,value:[`paid`],operator:i.IN}]},{id:`fulfillment`,label:`Fulfillment`,count:R.filter(e=>e.status===`shipped`).length,presets:[{key:`status`,value:[`shipped`],operator:i.IN}]}];function be(e,t){return e.filter(e=>t.every(t=>{if(t.value.length===0)return!0;if(t.key===`q`){let n=t.value.join(` `).trim().toLowerCase();return n?`${e.number} ${e.customer}`.toLowerCase().includes(n):!0}return t.key===`status`?t.value.includes(e.status):t.key===`customer`?t.value.includes(e.customer):!0}))}var B=[{accessorKey:`number`,header:`Order`,cell:({getValue:e})=>(0,k.jsx)(c,{tag:`span`,size:`inherit`,weight:`medium`,className:`font-mono`,children:String(e())})},{accessorKey:`customer`,header:`Customer`},{accessorKey:`totalUsd`,header:`Total`,cell:({getValue:e})=>(0,k.jsxs)(c,{tag:`span`,size:`inherit`,className:`tabular-nums`,children:[`$`,e().toLocaleString()]})},{accessorKey:`status`,header:`Status`,cell:({getValue:e})=>{let t=e();return(0,k.jsx)(s,{variant:t===`paid`?`success`:t===`pending`?`warning`:t===`cancelled`?`error`:`info`,dot:!0,children:t})}}];function V(){return(0,k.jsx)(g,{columns:B,data:R,enableSorting:!0,rowActions:()=>[{id:`edit`,label:`Edit`,icon:(0,k.jsx)(v,{className:`size-icon`}),onClick:()=>{}},{id:`delete`,label:`Delete`,icon:(0,k.jsx)(y,{className:`size-icon`}),variant:`destructive`,onClick:()=>{}}]})}function H(){let[e,t]=(0,O.useState)([]),[n,r]=(0,O.useState)({}),i=(0,O.useMemo)(()=>be(R,e),[e]),o=Object.keys(n).length;return(0,k.jsx)(ee,{filters:z,activeFilters:e,onFilterChange:t,children:(0,k.jsx)(E,{width:`full`,className:`data-table-integration--component rounded-lg border border-border bg-background`,bodyClassName:`min-w-0`,header:{title:`Orders`,headingTag:`h3`,titleBadges:[{label:`${i.length} shown`,variant:`secondary`},...o>0?[{label:`${o} selected`,variant:`info`}]:[]],description:`Tabs, filter state, selection, column controls, sticky header, and compact table density in one surface.`,actions:(0,k.jsxs)(`div`,{className:`flex shrink-0 items-center gap-space-md`,children:[(0,k.jsx)(d,{variant:`secondary`,buttonStyle:`outline`,children:`Export`}),(0,k.jsx)(d,{children:`New order`})]}),actionsClassName:`pt-1`},children:(0,k.jsxs)(`div`,{className:`data-table-integration--surface overflow-hidden rounded-lg border border-border bg-card`,children:[(0,k.jsx)(`div`,{className:`data-table-integration--filters border-b border-border/70 px-surface py-surface`,children:(0,k.jsx)(a,{variant:`compact`,showClearFilters:!0,tabs:ye})}),(0,k.jsx)(g,{columns:B,data:i,surface:`flat`,headerTransparent:!1,enableSorting:!0,enableColumnVisibility:!0,enableRowSelection:!0,rowSelection:n,onRowSelectionChange:r,getRowId:e=>e.id,stickyHeader:!0,maxBodyHeight:360,emptyStateMessage:`No orders match the current view.`,rowActions:()=>[{id:`open`,label:`Open`,icon:(0,k.jsx)(v,{className:`size-icon`}),onClick:()=>{}},{id:`delete`,label:`Delete`,icon:(0,k.jsx)(y,{className:`size-icon`}),variant:`destructive`,onClick:()=>{}}],bulkActions:({selectedRowCount:e})=>(0,k.jsx)(d,{variant:`secondary`,buttonStyle:`outline`,disabled:e===0,children:`Archive selected`}),footerContent:(0,k.jsxs)(`div`,{className:`flex flex-col gap-space-sm sm:flex-row sm:items-center sm:justify-between`,children:[(0,k.jsxs)(c,{tag:`span`,size:`xs`,type:`secondary`,children:[i.length,` of `,R.length,` orders`]}),(0,k.jsx)(c,{tag:`span`,size:`xs`,type:`secondary`,children:`Compact density is the library default.`})]})})]})})})}var xe=[{id:`1`,customer:`Sarah Smitha`,avatarUrl:`https://api.dicebear.com/7.x/avataaars/svg?seed=sarah`,createdAt:`2026-04-12`,total:2450,status:`paid`},{id:`2`,customer:`Daniel Smith`,avatarUrl:`https://api.dicebear.com/7.x/avataaars/svg?seed=dan`,createdAt:`2026-04-13`,total:370,status:`pending`},{id:`3`,customer:`Emma Garcia`,avatarUrl:`https://api.dicebear.com/7.x/avataaars/svg?seed=emma`,createdAt:`2026-04-15`,total:1280,status:`shipped`},{id:`4`,customer:`David Williams`,avatarUrl:`https://api.dicebear.com/7.x/avataaars/svg?seed=david`,createdAt:`2026-04-09`,total:580,status:`cancelled`}],Se={paid:{label:`Paid`,variant:`success`,icon:p},pending:{label:`Pending`,variant:`warning`,icon:h},shipped:{label:`Shipped`,variant:`info`,icon:b},cancelled:{label:`Cancelled`,variant:`destructive`,icon:m}},Ce=[{accessorKey:`customer`,header:`Customer`,cell:({row:e})=>(0,k.jsx)(T,{name:e.original.customer,imageUrl:e.original.avatarUrl,subtitle:`#${e.original.id}`})},{accessorKey:`status`,header:`Status`,cell:({getValue:e})=>(0,k.jsx)(me,{value:e(),map:Se})},{accessorKey:`total`,header:`Total`,cell:({getValue:e})=>(0,k.jsx)(pe,{value:e(),currency:`USD`,weight:`semibold`})},{accessorKey:`createdAt`,header:`Created`,cell:({getValue:e})=>(0,k.jsx)(he,{value:e()})}];function U(){return(0,k.jsx)(g,{columns:Ce,data:xe})}var we=[{id:`USR-001`,name:`Sarah Smitha`,email:`sarah@example.com`,role:`Owner`,createdAt:`2026-05-14`,statuses:[`active`,`verified`,`twoFactor`]},{id:`USR-002`,name:`Daniel Smith`,email:`daniel@example.com`,role:`Admin`,createdAt:`2026-05-22`,statuses:[`active`,`verified`]},{id:`USR-003`,name:`Emma Garcia`,email:`emma@example.com`,role:`Support`,createdAt:`2026-06-02`,statuses:[`active`]}],Te=[{accessorKey:`name`,header:`User`,cell:({row:e})=>(0,k.jsx)(de,{title:e.original.name,subtitle:e.original.email,metadata:[{label:`Role`,value:e.original.role}],href:`#/users/${e.original.id}`})},{id:`status`,header:`Status`,cell:({row:e})=>(0,k.jsx)(ge,{items:[{id:`active`,label:`Active`,variant:`success`,hidden:!e.original.statuses.includes(`active`)},{id:`verified`,label:`Verified`,variant:`info`,hidden:!e.original.statuses.includes(`verified`)},{id:`twoFactor`,label:`2FA`,variant:`secondary`,hidden:!e.original.statuses.includes(`twoFactor`)}]})},{accessorKey:`createdAt`,header:`Created`,cell:({getValue:e})=>(0,k.jsx)(fe,{value:e(),secondary:`Synced today`})}];function W(){return(0,k.jsx)(g,{columns:Te,data:we,enableRowSelection:!0,getRowId:e=>e.id,rowActionsMenuLabel:e=>`Actions for ${e.name}`,rowActions:()=>[{id:`open`,label:`Open`,onClick:()=>{}},{id:`disable`,label:`Disable`,variant:`destructive`,onClick:()=>{}}],bulkActions:({selectedRowCount:e})=>(0,k.jsx)(d,{variant:`secondary`,disabled:e===0,children:`Bulk update`}),maxBodyHeight:320,stickyToolbar:!0})}function G(){let[e,t]=(0,O.useState)({});return(0,k.jsxs)(`div`,{className:`flex w-full min-w-0 max-w-full flex-col gap-space-md overflow-hidden`,children:[(0,k.jsx)(g,{columns:j,data:A,enableRowSelection:!0,rowSelection:e,onRowSelectionChange:t,getRowId:e=>e.id}),(0,k.jsxs)(c,{size:`xs`,type:`secondary`,children:[`selected: `,Object.keys(e).length===0?`—`:Object.keys(e).join(`, `)]})]})}function K(){return(0,k.jsx)(g,{columns:j,data:A,enableSorting:!0,enableColumnVisibility:!0})}function q(){return(0,k.jsx)(g,{columns:j,data:A,enableColumnVisibility:!0,topbarContent:(0,k.jsxs)(`div`,{className:`flex items-center gap-space-md`,children:[(0,k.jsx)(c,{weight:`semibold`,children:`Orders`}),(0,k.jsx)(s,{variant:`secondary`,children:A.length})]})})}function J(){let[e,t]=(0,O.useState)(`all`);return(0,k.jsx)(ne,{header:(0,k.jsxs)(`div`,{className:`space-y-1`,children:[(0,k.jsx)(c,{weight:`semibold`,children:`Orders data view`}),(0,k.jsx)(c,{size:`xs`,type:`secondary`,children:`Controlled chrome around the table; the app owns query state and data fetching.`})]}),toolbar:(0,k.jsx)(_,{search:(0,k.jsx)(ue,{"aria-label":`Search orders`,placeholder:`Search orders...`,className:`w-56`}),views:(0,k.jsx)(te,{value:e,onValueChange:t,views:[{id:`all`,label:`All`,count:117},{id:`review`,label:`Needs review`,count:8},{id:`drafts`,label:`Drafts`,count:16}]}),actions:(0,k.jsx)(d,{variant:`secondary`,children:`Export`})}),footer:(0,k.jsx)(ie,{page:2,pageCount:8,total:`117 orders`,onPageChange:()=>{}}),children:(0,k.jsx)(g,{columns:j,data:A,surface:`flat`})})}function Y(){return(0,k.jsx)(g,{columns:j,data:[...A,...A,...A],stickyHeader:!0,stickyFirstColumn:!0,maxBodyHeight:256})}function X(){return(0,k.jsx)(g,{columns:j,data:[],emptyStateMessage:`No orders match the current filters.`})}var Z=`import { useMemo, useState } from 'react';
|
|
1
|
+
import{n as e,r as t}from"./chunk-QTnfLwEv.js";import{t as n}from"./react-sKtkuLrH.js";import{a as r,i,n as ee,t as te}from"./filter-layout-DUVqG5Ql.js";import{n as a,o,p as s,t as c}from"./section-BPNIPavy.js";import{t as l}from"./badge-check-DocF8Ho3.js";import{r as u,t as d}from"./example-CJMJcnb4.js";import{t as ne}from"./circle-check-C0X85t4j.js";import{t as f}from"./circle-x-MO44aKHe.js";import{t as p}from"./clock-GhBJJ6n1.js";import{a as m,i as h,n as re,o as g,r as _,t as v}from"./data-view-DmWd0h7G.js";import{t as y}from"./shopping-bag-DzMrGvpF.js";import{t as b}from"./square-pen-jwp_OWMQ.js";import{t as x}from"./trash-2-CtRtVsCy.js";import{t as S}from"./truck-Cl0nyN_j.js";import{t as C}from"./user-BDIP5UPS.js";import{a as w,d as T}from"./index-jD-KSiHu.js";import{t as E}from"./props-table-DoDq8Mvr.js";import{t as ie}from"./smart-card-p97LLZCW.js";import{t as ae}from"./customers-DvBxRjHv.js";import{t as oe}from"./orders-BFwWtubb.js";import{t as se}from"./input-CkNgwwCs.js";import{a as D,i as ce,n as le,o as O,r as ue,s as de,t as fe}from"./cell-renderers-CosD6Gby.js";import{t as pe}from"./page-9xr7xnuW.js";var me=e({BasicDefault:()=>N,CellRenderers:()=>U,ComfortableTable:()=>P,DataViewChrome:()=>J,EmptyState:()=>X,FilteredTabbedOrdersTable:()=>H,IndexTableCells:()=>W,PaginationExample:()=>R,RealisticOrdersTable:()=>V,StickyHeaderAndFirstColumn:()=>Y,SurfaceFlatInsideSmartCardTableRendersNoChrome:()=>I,SurfaceGlassHeaderTransparentCleanOutlineNoMutedHeader:()=>F,WithColumnVisibility:()=>K,WithCustomToolbar:()=>q,WithRowSelection:()=>G,WithSortingRowActions:()=>L}),k=t(n(),1),A=T(),j=[{id:`ORD-001`,customer:`Sarah Smitha`,amount:`2,450 USD`,status:`paid`,date:`Mar 24`},{id:`ORD-002`,customer:`Daniel Smith`,amount:`370 USD`,status:`pending`,date:`Mar 25`},{id:`ORD-003`,customer:`Emma Garcia`,amount:`320 USD`,status:`paid`,date:`Mar 26`},{id:`ORD-004`,customer:`David Williams`,amount:`580 USD`,status:`overdue`,date:`Mar 14`},{id:`ORD-005`,customer:`Nadia Kowalski`,amount:`120 USD`,status:`paid`,date:`Mar 27`}],M=[{accessorKey:`id`,header:`Order`,cell:({row:e,getValue:t})=>(0,A.jsx)(D,{title:String(t()),href:`#/orders/${e.original.id}`,fallback:(0,A.jsx)(y,{className:`size-icon`,"aria-hidden":`true`}),mediaClassName:`size-avatar-sm rounded-md bg-primary/10 text-primary`,titleClassName:`font-mono font-semibold`})},{accessorKey:`customer`,header:`Customer`,cell:({row:e})=>(0,A.jsx)(fe,{name:e.original.customer})},{accessorKey:`amount`,header:`Amount`,meta:{align:`end`},cell:({getValue:e})=>(0,A.jsx)(s,{tag:`span`,size:`inherit`,weight:`semibold`,className:`tabular-nums`,children:String(e())})},{accessorKey:`status`,header:`Status`,cell:({getValue:e})=>{let t=e();return(0,A.jsx)(o,{variant:t===`paid`?`success`:t===`pending`?`warning`:`error`,dot:!0,children:t})}},{accessorKey:`date`,header:`Date`,cell:({getValue:e})=>(0,A.jsx)(s,{tag:`span`,size:`inherit`,type:`secondary`,className:`tabular-nums`,children:String(e())})}];function N(){return(0,A.jsx)(m,{columns:M,data:j})}function P(){return(0,A.jsx)(m,{columns:M,data:j,size:`default`,rowActions:()=>[{id:`edit`,label:`Edit`,icon:(0,A.jsx)(b,{className:`size-icon`}),onClick:()=>{}},{id:`delete`,label:`Delete`,icon:(0,A.jsx)(x,{className:`size-icon`}),variant:`destructive`,onClick:()=>{}}]})}function F(){return(0,A.jsx)(m,{columns:M,data:j,surface:`glass`,headerTransparent:!0})}function I(){return(0,A.jsx)(ie,{padding:`small`,className:`w-full min-w-0 max-w-full overflow-hidden`,children:(0,A.jsx)(m,{columns:M,data:j,surface:`flat`,headerTransparent:!0})})}function L(){return(0,A.jsx)(m,{columns:M,data:j,enableSorting:!0,rowActions:()=>[{id:`edit`,label:`Edit`,icon:(0,A.jsx)(b,{className:`size-icon`}),onClick:()=>{}},{id:`delete`,label:`Delete`,icon:(0,A.jsx)(x,{className:`size-icon`}),variant:`destructive`,onClick:()=>{}}]})}function R(){return(0,A.jsx)(g,{pagination:{current_page:3,last_page:12,per_page:10,total:117,path:`/orders`,prev_page_url:`/orders?page=2`,next_page_url:`/orders?page=4`},onPageChange:()=>{}})}var z=oe.map(e=>({id:e.id,number:e.number,customer:ae.find(t=>t.id===e.customerId)?.name??`—`,totalUsd:e.totalUsd,status:e.status})),he=[{label:`Paid`,value:`paid`,icon:null},{label:`Pending`,value:`pending`,icon:null},{label:`Shipped`,value:`shipped`,icon:null},{label:`Cancelled`,value:`cancelled`,icon:null}],ge=[...new Set(z.map(e=>e.customer))].map(e=>({label:e,value:e,icon:null})),_e=[{key:`q`,label:`Search`,type:r.SEARCH,operator:i.CONTAINS,placeholder:`Search orders or customers…`,icon:(0,A.jsx)(w,{className:`size-icon`}),displayConfig:{display:`always`}},{key:`status`,label:`Status`,pluralLabel:`statuses`,type:r.MULTI_SELECT,operator:i.IN,icon:(0,A.jsx)(l,{className:`size-icon`}),displayConfig:{display:`always`},options:he},{key:`customer`,label:`Customer`,type:r.MULTI_SELECT,operator:i.IN,icon:(0,A.jsx)(C,{className:`size-icon`}),displayConfig:{display:`collapsed`},options:ge}],ve=[{id:`all`,label:`All`,count:z.length,presets:[]},{id:`open`,label:`Open`,count:z.filter(e=>e.status===`pending`).length,presets:[{key:`status`,value:[`pending`],operator:i.IN}]},{id:`paid`,label:`Paid`,count:z.filter(e=>e.status===`paid`).length,presets:[{key:`status`,value:[`paid`],operator:i.IN}]},{id:`fulfillment`,label:`Fulfillment`,count:z.filter(e=>e.status===`shipped`).length,presets:[{key:`status`,value:[`shipped`],operator:i.IN}]}];function ye(e,t){return e.filter(e=>t.every(t=>{if(t.value.length===0)return!0;if(t.key===`q`){let n=t.value.join(` `).trim().toLowerCase();return n?`${e.number} ${e.customer}`.toLowerCase().includes(n):!0}return t.key===`status`?t.value.includes(e.status):t.key===`customer`?t.value.includes(e.customer):!0}))}var B=[{accessorKey:`number`,header:`Order`,cell:({row:e,getValue:t})=>(0,A.jsx)(D,{title:String(t()),href:`#/orders/${e.original.id}`,fallback:(0,A.jsx)(y,{className:`size-icon`,"aria-hidden":`true`}),mediaClassName:`size-avatar-sm rounded-md bg-primary/10 text-primary`,titleClassName:`font-mono font-semibold`})},{accessorKey:`customer`,header:`Customer`},{accessorKey:`totalUsd`,header:`Total`,cell:({getValue:e})=>(0,A.jsxs)(s,{tag:`span`,size:`inherit`,className:`tabular-nums`,children:[`$`,e().toLocaleString()]})},{accessorKey:`status`,header:`Status`,cell:({getValue:e})=>{let t=e();return(0,A.jsx)(o,{variant:t===`paid`?`success`:t===`pending`?`warning`:t===`cancelled`?`error`:`info`,dot:!0,children:t})}}];function V(){return(0,A.jsx)(m,{columns:B,data:z,enableSorting:!0,rowActions:()=>[{id:`edit`,label:`Edit`,icon:(0,A.jsx)(b,{className:`size-icon`}),onClick:()=>{}},{id:`delete`,label:`Delete`,icon:(0,A.jsx)(x,{className:`size-icon`}),variant:`destructive`,onClick:()=>{}}]})}function H(){let[e,t]=(0,k.useState)([]),[n,r]=(0,k.useState)({}),i=(0,k.useMemo)(()=>ye(z,e),[e]),a=Object.keys(n).length;return(0,A.jsx)(ee,{filters:_e,activeFilters:e,onFilterChange:t,children:(0,A.jsx)(pe,{width:`full`,className:`data-table-integration--component rounded-lg border border-border bg-background`,bodyClassName:`min-w-0`,header:{title:`Orders`,headingTag:`h3`,titleBadges:[{label:`${i.length} shown`,variant:`secondary`},...a>0?[{label:`${a} selected`,variant:`info`}]:[]],description:`Tabs, filter state, selection, column controls, sticky header, and compact table density in one surface.`,actions:(0,A.jsxs)(`div`,{className:`flex shrink-0 items-center gap-space-md`,children:[(0,A.jsx)(u,{variant:`secondary`,buttonStyle:`outline`,children:`Export`}),(0,A.jsx)(u,{children:`New order`})]}),actionsClassName:`pt-1`},children:(0,A.jsxs)(`div`,{className:`data-table-integration--surface overflow-hidden rounded-lg border border-border bg-card`,children:[(0,A.jsx)(`div`,{className:`data-table-integration--filters border-b border-border/70 px-surface py-surface`,children:(0,A.jsx)(te,{variant:`compact`,showClearFilters:!0,tabs:ve})}),(0,A.jsx)(m,{columns:B,data:i,surface:`flat`,headerTransparent:!1,enableSorting:!0,enableColumnVisibility:!0,enableRowSelection:!0,rowSelection:n,onRowSelectionChange:r,getRowId:e=>e.id,stickyHeader:!0,maxBodyHeight:360,emptyStateMessage:`No orders match the current view.`,rowActions:()=>[{id:`open`,label:`Open`,icon:(0,A.jsx)(b,{className:`size-icon`}),onClick:()=>{}},{id:`delete`,label:`Delete`,icon:(0,A.jsx)(x,{className:`size-icon`}),variant:`destructive`,onClick:()=>{}}],bulkActions:({selectedRowCount:e})=>(0,A.jsx)(u,{variant:`secondary`,buttonStyle:`outline`,disabled:e===0,children:`Archive selected`}),footerContent:(0,A.jsxs)(`div`,{className:`flex flex-col gap-space-sm sm:flex-row sm:items-center sm:justify-between`,children:[(0,A.jsxs)(s,{tag:`span`,size:`xs`,type:`secondary`,children:[i.length,` of `,z.length,` orders`]}),(0,A.jsx)(s,{tag:`span`,size:`xs`,type:`secondary`,children:`Compact density is the library default.`})]})})]})})})}var be=[{id:`1`,customer:`Sarah Smitha`,avatarUrl:`https://api.dicebear.com/7.x/avataaars/svg?seed=sarah`,createdAt:`2026-04-12`,total:2450,status:`paid`},{id:`2`,customer:`Daniel Smith`,avatarUrl:`https://api.dicebear.com/7.x/avataaars/svg?seed=dan`,createdAt:`2026-04-13`,total:370,status:`pending`},{id:`3`,customer:`Emma Garcia`,avatarUrl:`https://api.dicebear.com/7.x/avataaars/svg?seed=emma`,createdAt:`2026-04-15`,total:1280,status:`shipped`},{id:`4`,customer:`David Williams`,avatarUrl:`https://api.dicebear.com/7.x/avataaars/svg?seed=david`,createdAt:`2026-04-09`,total:580,status:`cancelled`}],xe={paid:{label:`Paid`,variant:`success`,icon:ne},pending:{label:`Pending`,variant:`warning`,icon:p},shipped:{label:`Shipped`,variant:`info`,icon:S},cancelled:{label:`Cancelled`,variant:`destructive`,icon:f}},Se=[{accessorKey:`customer`,header:`Customer`,cell:({row:e})=>(0,A.jsx)(D,{title:e.original.customer,imageUrl:e.original.avatarUrl,subtitle:`#${e.original.id}`,href:`#/customers/${e.original.id}`})},{accessorKey:`status`,header:`Status`,cell:({getValue:e})=>(0,A.jsx)(O,{value:e(),map:xe})},{accessorKey:`total`,header:`Total`,cell:({getValue:e})=>(0,A.jsx)(le,{value:e(),currency:`USD`,weight:`semibold`})},{accessorKey:`createdAt`,header:`Created`,cell:({getValue:e})=>(0,A.jsx)(ue,{value:e()})}];function U(){return(0,A.jsx)(m,{columns:Se,data:be})}var Ce=[{id:`USR-001`,name:`Sarah Smitha`,email:`sarah@example.com`,role:`Owner`,createdAt:`2026-05-14`,statuses:[`active`,`verified`,`twoFactor`]},{id:`USR-002`,name:`Daniel Smith`,email:`daniel@example.com`,role:`Admin`,createdAt:`2026-05-22`,statuses:[`active`,`verified`]},{id:`USR-003`,name:`Emma Garcia`,email:`emma@example.com`,role:`Support`,createdAt:`2026-06-02`,statuses:[`active`]}],we=[{accessorKey:`name`,header:`User`,cell:({row:e})=>(0,A.jsx)(D,{title:e.original.name,subtitle:e.original.email,metadata:[{label:`Role`,value:e.original.role}],href:`#/users/${e.original.id}`})},{id:`status`,header:`Status`,cell:({row:e})=>(0,A.jsx)(de,{items:[{id:`active`,label:`Active`,variant:`success`,hidden:!e.original.statuses.includes(`active`)},{id:`verified`,label:`Verified`,variant:`info`,hidden:!e.original.statuses.includes(`verified`)},{id:`twoFactor`,label:`2FA`,variant:`secondary`,hidden:!e.original.statuses.includes(`twoFactor`)}]})},{accessorKey:`createdAt`,header:`Created`,cell:({getValue:e})=>(0,A.jsx)(ce,{value:e(),secondary:`Synced today`})}];function W(){return(0,A.jsx)(m,{columns:we,data:Ce,enableRowSelection:!0,getRowId:e=>e.id,rowActionsMenuLabel:e=>`Actions for ${e.name}`,rowActions:()=>[{id:`open`,label:`Open`,onClick:()=>{}},{id:`disable`,label:`Disable`,variant:`destructive`,onClick:()=>{}}],bulkActions:({selectedRowCount:e})=>(0,A.jsx)(u,{variant:`secondary`,disabled:e===0,children:`Bulk update`}),maxBodyHeight:320,stickyToolbar:!0})}function G(){let[e,t]=(0,k.useState)({});return(0,A.jsxs)(`div`,{className:`flex w-full min-w-0 max-w-full flex-col gap-space-md overflow-hidden`,children:[(0,A.jsx)(m,{columns:M,data:j,enableRowSelection:!0,rowSelection:e,onRowSelectionChange:t,getRowId:e=>e.id}),(0,A.jsxs)(s,{size:`xs`,type:`secondary`,children:[`selected: `,Object.keys(e).length===0?`—`:Object.keys(e).join(`, `)]})]})}function K(){return(0,A.jsx)(m,{columns:M,data:j,enableSorting:!0,enableColumnVisibility:!0})}function q(){return(0,A.jsx)(m,{columns:M,data:j,enableColumnVisibility:!0,topbarContent:(0,A.jsxs)(`div`,{className:`flex items-center gap-space-md`,children:[(0,A.jsx)(s,{weight:`semibold`,children:`Orders`}),(0,A.jsx)(o,{variant:`secondary`,children:j.length})]})})}function J(){let[e,t]=(0,k.useState)(`all`);return(0,A.jsx)(re,{header:(0,A.jsxs)(`div`,{className:`space-y-1`,children:[(0,A.jsx)(s,{weight:`semibold`,children:`Orders data view`}),(0,A.jsx)(s,{size:`xs`,type:`secondary`,children:`Controlled chrome around the table; the app owns query state and data fetching.`})]}),toolbar:(0,A.jsx)(_,{search:(0,A.jsx)(se,{"aria-label":`Search orders`,placeholder:`Search orders...`,className:`w-56`}),views:(0,A.jsx)(h,{value:e,onValueChange:t,views:[{id:`all`,label:`All`,count:117},{id:`review`,label:`Needs review`,count:8},{id:`drafts`,label:`Drafts`,count:16}]}),actions:(0,A.jsx)(u,{variant:`secondary`,children:`Export`})}),footer:(0,A.jsx)(v,{page:2,pageCount:8,total:`117 orders`,onPageChange:()=>{}}),children:(0,A.jsx)(m,{columns:M,data:j,surface:`flat`})})}function Y(){return(0,A.jsx)(m,{columns:M,data:[...j,...j,...j],stickyHeader:!0,stickyFirstColumn:!0,maxBodyHeight:256})}function X(){return(0,A.jsx)(m,{columns:M,data:[],emptyStateMessage:`No orders match the current filters.`})}var Z=`import { useMemo, useState } from 'react';
|
|
2
2
|
import { type ColumnDef, type RowSelectionState } from '@tanstack/react-table';
|
|
3
3
|
import { BadgeCheck, Edit, Search, Trash2, ShoppingBag, CheckCircle2, Clock, User, XCircle, Truck } from 'lucide-react';
|
|
4
4
|
import {
|
|
@@ -31,7 +31,6 @@ import {
|
|
|
31
31
|
import { Pagination } from '@/components/base/table/pagination';
|
|
32
32
|
import { Badge } from '@/components/base/badge';
|
|
33
33
|
import { Button } from '@/components/base/buttons';
|
|
34
|
-
import { IconBadge } from '@/components/base/display/icon-badge';
|
|
35
34
|
import { Input } from '@/components/base/forms';
|
|
36
35
|
import { Page } from '@/components/layout/page';
|
|
37
36
|
import { Text } from '@/components/typography';
|
|
@@ -57,13 +56,14 @@ const columns: ColumnDef<Order>[] = [
|
|
|
57
56
|
{
|
|
58
57
|
accessorKey: 'id',
|
|
59
58
|
header: 'Order',
|
|
60
|
-
cell: ({ getValue }) => (
|
|
61
|
-
<
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
59
|
+
cell: ({ row, getValue }) => (
|
|
60
|
+
<ResourceCell
|
|
61
|
+
title={String(getValue())}
|
|
62
|
+
href={\`#/orders/\${row.original.id}\`}
|
|
63
|
+
fallback={<ShoppingBag className="size-icon" aria-hidden="true" />}
|
|
64
|
+
mediaClassName="size-avatar-sm rounded-md bg-primary/10 text-primary"
|
|
65
|
+
titleClassName="font-mono font-semibold"
|
|
66
|
+
/>
|
|
67
67
|
),
|
|
68
68
|
},
|
|
69
69
|
{
|
|
@@ -274,7 +274,19 @@ function filterOrders(rows: RealOrder[], activeFilters: ActiveFilter[]) {
|
|
|
274
274
|
}
|
|
275
275
|
|
|
276
276
|
const realColumns: ColumnDef<RealOrder>[] = [
|
|
277
|
-
{
|
|
277
|
+
{
|
|
278
|
+
accessorKey: 'number',
|
|
279
|
+
header: 'Order',
|
|
280
|
+
cell: ({ row, getValue }) => (
|
|
281
|
+
<ResourceCell
|
|
282
|
+
title={String(getValue())}
|
|
283
|
+
href={\`#/orders/\${row.original.id}\`}
|
|
284
|
+
fallback={<ShoppingBag className="size-icon" aria-hidden="true" />}
|
|
285
|
+
mediaClassName="size-avatar-sm rounded-md bg-primary/10 text-primary"
|
|
286
|
+
titleClassName="font-mono font-semibold"
|
|
287
|
+
/>
|
|
288
|
+
),
|
|
289
|
+
},
|
|
278
290
|
{ accessorKey: 'customer', header: 'Customer' },
|
|
279
291
|
{
|
|
280
292
|
accessorKey: 'totalUsd',
|
|
@@ -424,7 +436,14 @@ const cellDemoColumns: ColumnDef<CellDemoRow>[] = [
|
|
|
424
436
|
{
|
|
425
437
|
accessorKey: 'customer',
|
|
426
438
|
header: 'Customer',
|
|
427
|
-
cell: ({ row }) =>
|
|
439
|
+
cell: ({ row }) => (
|
|
440
|
+
<ResourceCell
|
|
441
|
+
title={row.original.customer}
|
|
442
|
+
imageUrl={row.original.avatarUrl}
|
|
443
|
+
subtitle={\`#\${row.original.id}\`}
|
|
444
|
+
href={\`#/customers/\${row.original.id}\`}
|
|
445
|
+
/>
|
|
446
|
+
),
|
|
428
447
|
},
|
|
429
448
|
{
|
|
430
449
|
accessorKey: 'status',
|
|
@@ -649,16 +668,19 @@ export function EmptyState() {
|
|
|
649
668
|
/>
|
|
650
669
|
);
|
|
651
670
|
}
|
|
652
|
-
`;function Q(e){let t={code:`code`,p:`p`,...e.components};return
|
|
653
|
-
and surface tokens. Pass `,(0,
|
|
654
|
-
optionally enable `,(0,
|
|
655
|
-
compact through `,(0,
|
|
671
|
+
`;function Q(e){let t={code:`code`,p:`p`,...e.components};return me||$(`Examples`,!1),N||$(`Examples.BasicDefault`,!0),U||$(`Examples.CellRenderers`,!0),P||$(`Examples.ComfortableTable`,!0),J||$(`Examples.DataViewChrome`,!0),X||$(`Examples.EmptyState`,!0),H||$(`Examples.FilteredTabbedOrdersTable`,!0),W||$(`Examples.IndexTableCells`,!0),R||$(`Examples.PaginationExample`,!0),V||$(`Examples.RealisticOrdersTable`,!0),Y||$(`Examples.StickyHeaderAndFirstColumn`,!0),I||$(`Examples.SurfaceFlatInsideSmartCardTableRendersNoChrome`,!0),F||$(`Examples.SurfaceGlassHeaderTransparentCleanOutlineNoMutedHeader`,!0),K||$(`Examples.WithColumnVisibility`,!0),q||$(`Examples.WithCustomToolbar`,!0),G||$(`Examples.WithRowSelection`,!0),L||$(`Examples.WithSortingRowActions`,!0),(0,A.jsxs)(a,{title:`Table`,description:`DataTable + Pagination — TanStack-React-Table-backed, with sorting, row actions, sticky header, calibrated table rhythm, and three surface chromes.`,layer:`base`,status:`ready`,sourcePath:`src/components/base/table`,children:[(0,A.jsx)(c,{title:`Overview`,id:`overview`,children:(0,A.jsxs)(t.p,{children:[(0,A.jsx)(t.code,{children:`DataTable<T>`}),` wraps `,(0,A.jsx)(t.code,{children:`@tanstack/react-table`}),` with our typography, density,
|
|
672
|
+
and surface tokens. Pass `,(0,A.jsx)(t.code,{children:`columns`}),` (typed against your row shape) and `,(0,A.jsx)(t.code,{children:`data`}),`,
|
|
673
|
+
optionally enable `,(0,A.jsx)(t.code,{children:`sorting`}),` and supply `,(0,A.jsx)(t.code,{children:`rowActions`}),`. The default table scale is
|
|
674
|
+
compact through `,(0,A.jsx)(t.code,{children:`UIProvider`}),`; use `,(0,A.jsx)(t.code,{children:`size="default"`}),` only when a table needs the
|
|
656
675
|
more comfortable row rhythm. Actual cell padding and typography route through
|
|
657
676
|
row, surface, and text variables.
|
|
658
|
-
|
|
659
|
-
`,(0,
|
|
660
|
-
|
|
661
|
-
|
|
677
|
+
For index tables, make the first meaningful resource column a link by rendering
|
|
678
|
+
`,(0,A.jsx)(t.code,{children:`<ResourceCell href="...">`}),` or by passing `,(0,A.jsx)(t.code,{children:`renderLink`}),` to `,(0,A.jsx)(t.code,{children:`ResourceCell`}),`; the
|
|
679
|
+
consumer still owns router integration.
|
|
680
|
+
Pair with `,(0,A.jsx)(t.code,{children:`Pagination`}),` for the canonical Laravel-paginator shape.`]})}),(0,A.jsxs)(c,{title:`Default`,id:`default`,children:[(0,A.jsx)(d,{name:`BasicDefault`,source:Z,children:(0,A.jsx)(N,{})}),(0,A.jsx)(d,{name:`ComfortableTable`,source:Z,children:(0,A.jsx)(P,{})})]}),(0,A.jsxs)(c,{title:`Surfaces`,id:`surfaces`,children:[(0,A.jsx)(d,{name:`SurfaceGlassHeaderTransparentCleanOutlineNoMutedHeader`,source:Z,children:(0,A.jsx)(F,{})}),(0,A.jsx)(d,{name:`SurfaceFlatInsideSmartCardTableRendersNoChrome`,source:Z,children:(0,A.jsx)(I,{})})]}),(0,A.jsx)(c,{title:`Features`,id:`features`,children:(0,A.jsx)(d,{name:`WithSortingRowActions`,source:Z,children:(0,A.jsx)(L,{})})}),(0,A.jsxs)(c,{title:`Cell renderers`,id:`cell-renderers`,children:[(0,A.jsxs)(t.p,{children:[(0,A.jsx)(t.code,{children:`StatusCell`}),`, `,(0,A.jsx)(t.code,{children:`StatusClusterCell`}),`, `,(0,A.jsx)(t.code,{children:`DateCell`}),`, `,(0,A.jsx)(t.code,{children:`DateMetaCell`}),`,
|
|
681
|
+
`,(0,A.jsx)(t.code,{children:`CurrencyCell`}),`, `,(0,A.jsx)(t.code,{children:`AvatarCell`}),`, and `,(0,A.jsx)(t.code,{children:`ResourceCell`}),` are reusable column-cell
|
|
682
|
+
renderers exported from `,(0,A.jsx)(t.code,{children:`base/table`}),`. Compose them inside your column `,(0,A.jsx)(t.code,{children:`cell`}),`
|
|
683
|
+
function to keep index tables consistent.`]}),(0,A.jsx)(d,{name:`CellRenderers`,source:Z,children:(0,A.jsx)(U,{})}),(0,A.jsx)(d,{name:`IndexTableCells`,source:Z,children:(0,A.jsx)(W,{})})]}),(0,A.jsx)(c,{title:`Selection`,id:`selection`,children:(0,A.jsx)(d,{name:`WithRowSelection`,source:Z,children:(0,A.jsx)(G,{})})}),(0,A.jsxs)(c,{title:`Toolbar`,id:`toolbar`,children:[(0,A.jsx)(d,{name:`WithColumnVisibility`,source:Z,children:(0,A.jsx)(K,{})}),(0,A.jsx)(d,{name:`WithCustomToolbar`,source:Z,children:(0,A.jsx)(q,{})}),(0,A.jsx)(d,{name:`DataViewChrome`,source:Z,children:(0,A.jsx)(J,{})})]}),(0,A.jsxs)(c,{title:`Integrated filters`,id:`integrated-filters`,children:[(0,A.jsxs)(t.p,{children:[`Use `,(0,A.jsx)(t.code,{children:`features/filters`}),` beside `,(0,A.jsx)(t.code,{children:`DataTable`}),`; do not make the base table own
|
|
662
684
|
query state. This mirrors the consumer shape: tabs and filters update row data,
|
|
663
685
|
while the table owns selection, sorting, sticky header, column controls, and row
|
|
664
|
-
actions.`]}),(0,
|
|
686
|
+
actions.`]}),(0,A.jsx)(d,{name:`FilteredTabbedOrdersTable`,source:Z,children:(0,A.jsx)(H,{})})]}),(0,A.jsx)(c,{title:`Sticky`,id:`sticky`,children:(0,A.jsx)(d,{name:`StickyHeaderAndFirstColumn`,source:Z,children:(0,A.jsx)(Y,{})})}),(0,A.jsx)(c,{title:`States`,id:`states`,children:(0,A.jsx)(d,{name:`EmptyState`,source:Z,children:(0,A.jsx)(X,{})})}),(0,A.jsx)(c,{title:`Pagination`,id:`pagination`,children:(0,A.jsx)(d,{name:`PaginationExample`,source:Z,children:(0,A.jsx)(R,{})})}),(0,A.jsx)(c,{title:`Realistic usage`,id:`realistic`,children:(0,A.jsx)(d,{name:`RealisticOrdersTable`,source:Z,children:(0,A.jsx)(V,{})})}),(0,A.jsxs)(c,{title:`API`,id:`api`,children:[(0,A.jsx)(E,{component:`DataTable`}),(0,A.jsx)(E,{component:`Pagination`}),(0,A.jsx)(E,{component:`ResourceCell`}),(0,A.jsx)(E,{component:`StatusClusterCell`}),(0,A.jsx)(E,{component:`DateMetaCell`}),(0,A.jsx)(E,{component:`DataViewShell`}),(0,A.jsx)(E,{component:`DataViewToolbar`}),(0,A.jsx)(E,{component:`DataViewPagination`}),(0,A.jsx)(E,{component:`SavedViewTabs`})]})]})}function Te(e={}){let{wrapper:t}=e.components||{};return t?(0,A.jsx)(t,{...e,children:(0,A.jsx)(Q,{...e})}):Q(e)}function $(e,t){throw Error(`Expected `+(t?`component`:`object`)+" `"+e+"` to be defined: you likely forgot to import, pass, or provide it.")}export{Te as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import"./chunk-QTnfLwEv.js";import{t as e}from"./react-sKtkuLrH.js";import{d as t,n}from"./index-
|
|
1
|
+
import"./chunk-QTnfLwEv.js";import{t as e}from"./react-sKtkuLrH.js";import{d as t,n}from"./index-jD-KSiHu.js";e();var r=t();function i({className:e,containerClassName:t,...i}){return(0,r.jsx)(`div`,{"data-slot":`table-container`,className:n(`relative w-full overflow-x-auto`,t),children:(0,r.jsx)(`table`,{"data-slot":`table`,className:n(`w-full caption-bottom text-sm`,e),...i})})}function a({className:e,...t}){return(0,r.jsx)(`thead`,{"data-slot":`table-header`,className:n(`[&_tr]:border-b`,e),...t})}function o({className:e,...t}){return(0,r.jsx)(`tbody`,{"data-slot":`table-body`,className:n(`[&_tr:last-child]:border-0`,e),...t})}function s({className:e,...t}){return(0,r.jsx)(`tr`,{"data-slot":`table-row`,className:n(`hover:bg-muted/50 data-[state=selected]:bg-muted border-b transition-colors`,e),...t})}function c({className:e,...t}){return(0,r.jsx)(`th`,{"data-slot":`table-head`,className:n(`text-foreground h-10 px-2 text-left align-middle font-medium whitespace-nowrap [&:has([role=checkbox])]:pr-0`,e),...t})}function l({className:e,...t}){return(0,r.jsx)(`td`,{"data-slot":`table-cell`,className:n(`p-2 align-middle whitespace-nowrap [&:has([role=checkbox])]:pr-0`,e),...t})}function u({className:e,...t}){return(0,r.jsx)(`caption`,{"data-slot":`table-caption`,className:n(`text-muted-foreground mt-4 text-sm`,e),...t})}export{c as a,l as i,o as n,a as o,u as r,s,i as t};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{r as e}from"./chunk-QTnfLwEv.js";import{t}from"./react-sKtkuLrH.js";import{r as n}from"./example-
|
|
1
|
+
import{r as e}from"./chunk-QTnfLwEv.js";import{t}from"./react-sKtkuLrH.js";import{r as n}from"./example-CJMJcnb4.js";import{t as r}from"./ellipsis-BLyAd9A-.js";import{d as i,n as a}from"./index-jD-KSiHu.js";import{n as o,t as s}from"./action-menu--rEgMzDi.js";var c=e(t(),1),l=e=>{let t=e.replace(/[_-]+/g,` `).replace(/\s+/g,` `).trim();return t?t.replace(/\b\w/g,e=>e.toUpperCase()):`Column`},u={emptyState:{message:`No results found.`},actions:{triggerLabel:`Actions`,srLabel:`Row actions menu`},filter:{searchPlaceholder:`Filter...`,columnsButton:`Columns`},columnVisibility:{title:`Toggle columns`,triggerLabel:`Columns`,formatLabel:(e,t)=>t&&t.trim().length>0?t:l(e)},toolbar:{scrollLeft:`Scroll left`,scrollRight:`Scroll right`,columns:`Toggle columns`,dense:`Compact view`,comfortable:`Comfortable view`},pagination:{showing:`Showing`,to:`to`,of:`of`,entries:`results`,previous:`Previous`,next:`Next`,page:`Page`,rowsPerPage:`Rows per page`,ariaLabel:`Pagination navigation`},selection:{summary:(e,t)=>`${e} of ${t} row${t===1?``:`s`} selected.`,row:e=>`Select row ${e+1}`,selectAll:`Select all rows`,clear:`Clear selection`},accessibility:{scrollRegion:`Table scroll area`}},d=(e,t)=>({...e,...t??{}}),f=e=>e?{emptyState:d(u.emptyState,e.emptyState),actions:d(u.actions,e.actions),filter:d(u.filter,e.filter),columnVisibility:d(u.columnVisibility,e.columnVisibility),toolbar:d(u.toolbar,e.toolbar),pagination:d(u.pagination,e.pagination),selection:d(u.selection,e.selection),accessibility:d(u.accessibility,e.accessibility)}:u,p=i();function m(e){let{row:t,actions:i,menuLabel:l,displayMode:d=`menu`,responsiveBreakpoint:f=1040,strings:m}=e,h=m??u,g=l??h.actions.triggerLabel,_=(0,c.useMemo)(()=>{let e=typeof i==`function`?i(t):i;return Array.isArray(e)?e:[]},[i,t]),v=(0,c.useMemo)(()=>{let e=e=>typeof e==`function`?e(t):e;return _.filter(t=>{let n=e(t.isVisible);return n===void 0?!0:n}).map(t=>({...t,disabled:e(t.isDisabled)??t.disabled??!1}))},[_,t]),y=v.length>0,[b,x]=(0,c.useState)(!1),S=v.filter(e=>e.variant!==`destructive`),C=v.filter(e=>e.variant===`destructive`),w=[...S,...C];if((0,c.useEffect)(()=>{if(d!==`auto`||!y){x(!1);return}let e=()=>{try{x(window.innerWidth<=f)}catch{x(!1)}};return e(),window.addEventListener(`resize`,e),()=>window.removeEventListener(`resize`,e)},[d,y,f]),!y)return null;let T=d===`auto`?b?`menu`:`inline`:d,E=e=>{if(e){if(typeof e==`function`)return e;if((0,c.isValidElement)(e)&&typeof e.type==`function`)return e.type}},D=e=>{switch(e){case`destructive`:return{variant:`error`,buttonStyle:`solid`};case`outline`:return{variant:`secondary`,buttonStyle:`outline`};case`secondary`:return{variant:`secondary`,buttonStyle:`solid`};case`ghost`:return{variant:`secondary`,buttonStyle:`ghost`};case`link`:return{variant:`secondary`,buttonStyle:`ghost`,className:`underline underline-offset-4`};default:return{variant:`primary`,buttonStyle:`solid`}}},O=e=>{switch(e){case`default`:return`primary`;case`destructive`:return`error`;default:return`secondary`}};return T===`inline`?(0,p.jsx)(`div`,{className:a(`table-actions--component`,`flex items-center gap-space-sm`),children:w.map((e,r)=>{let i=e.id||`${e.label}-${r}`,o=D(e.variant??`ghost`);return(0,p.jsxs)(n,{variant:o.variant,buttonStyle:o.buttonStyle,size:`small`,className:a(`text-inherit leading-tight`,o.className),disabled:!!e.disabled,onClick:()=>{e.onClick?.(t)},children:[!!e.icon&&(0,p.jsx)(`span`,{className:`mr-space-sm inline-flex`,children:e.icon}),e.label]},i)})}):(0,p.jsx)(s,{label:void 0,icon:r,srText:g||h.actions.srLabel,closeOnSelect:!0,align:`end`,density:`table`,children:w.map((e,n)=>{let r=e.id||`${e.label}-${n}`,i=()=>{e.onClick?.(t)},a=E(e.icon),s=e.icon?(0,p.jsx)(`span`,{className:`inline-flex items-center`,children:e.icon}):null,c=a?null:(0,p.jsxs)(`div`,{className:`flex w-full items-center gap-space-md`,children:[s,(0,p.jsx)(`span`,{children:e.label})]}),l=O(e.variant);return(0,p.jsx)(o,{label:e.label,icon:a,variant:l,disabled:!!e.disabled,onClick:i,children:c},r)})})}m.displayName=`DataTableActions`;export{u as n,f as r,m as t};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{n as e}from"./chunk-QTnfLwEv.js";import{n as t,t as n}from"./section-
|
|
1
|
+
import{n as e}from"./chunk-QTnfLwEv.js";import{n as t,t as n}from"./section-BPNIPavy.js";import{t as r}from"./example-CJMJcnb4.js";import{d as i}from"./index-jD-KSiHu.js";import{i as a,n as o,r as s,t as c}from"./tabs-Cm_p6znb.js";var l=e({Default:()=>d}),u=i();function d(){return(0,u.jsx)(u.Fragment,{children:(0,u.jsxs)(c,{defaultValue:`overview`,children:[(0,u.jsxs)(s,{children:[(0,u.jsx)(a,{value:`overview`,children:`Overview`}),(0,u.jsx)(a,{value:`activity`,children:`Activity`}),(0,u.jsx)(a,{value:`settings`,children:`Settings`})]}),(0,u.jsx)(o,{value:`overview`,className:`mt-3 text-sm`,children:`Overview panel content.`}),(0,u.jsx)(o,{value:`activity`,className:`mt-3 text-sm`,children:`Activity panel content.`}),(0,u.jsx)(o,{value:`settings`,className:`mt-3 text-sm`,children:`Settings panel content.`})]})})}var f=`import { Tabs, TabsContent, TabsList, TabsTrigger } from '@/components/ui/tabs';
|
|
2
2
|
|
|
3
3
|
export function Default() {
|
|
4
4
|
return (
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{r as e}from"./chunk-QTnfLwEv.js";import{t}from"./react-sKtkuLrH.js";import{c as n}from"./section-Dd6X6IKg.js";import{J as r,K as i,Kt as a,Mn as o,Qt as s,X as c,Y as l,_n as u,fr as d,g as f,hr as p,in as m,ir as h,jn as g,ln as _,lr as v,mr as y,nr as b,vn as x}from"./example-Rrx9vj75.js";import{d as S,n as C}from"./index-o71HAmc3.js";import{t as w}from"./inertValue-BRyHstYf.js";import{t as T}from"./useControlled-BHUji6Sp.js";import{n as E,r as D}from"./useCompositeListItem-CyULeWSL.js";import{t as O}from"./useCompositeItem-g1FeYTbw.js";import{n as k,t as A}from"./CompositeRoot-DVtTCBlx.js";var j=e(t(),1),M=j.createContext(void 0);function N(){let e=j.useContext(M);if(e===void 0)throw Error(d(64));return e}var P=function(e){return e.activationDirection=`data-activation-direction`,e.orientation=`data-orientation`,e}({}),F={tabActivationDirection:e=>({[P.activationDirection]:e})},I=S(),L=j.forwardRef(function(e,t){let{className:n,defaultValue:r=0,onValueChange:i,orientation:a=`horizontal`,render:o,value:c,style:l,...d}=e,f=e.defaultValue!==void 0,h=j.useRef([]),[g,v]=j.useState(()=>new Map),[x,S]=T({controlled:c,default:r,name:`Tabs`,state:`value`}),C=c!==void 0,[w,E]=j.useState(()=>new Map),O=j.useRef(void 0),k=j.useCallback(e=>{if(e===void 0)return null;for(let[t,n]of w.entries())if(n!=null&&e===(n.value??n.index))return t;return null},[w]),[A,N]=j.useState(()=>({previousValue:x,tabActivationDirection:`none`})),{previousValue:P,tabActivationDirection:L}=A,z=L,B=!1;P!==x&&(z=R(P,x,a,w),B=P!=null&&x!=null&&k(x)==null);let V=B?P:x,H=P!==V||L!==z;y(()=>{H&&N({previousValue:V,tabActivationDirection:z})},[V,H,z]);let U=p((e,t)=>{t.activationDirection=R(x,e,a,w),i?.(e,t),!t.isCanceled&&S(e)}),W=p((e,t)=>{i?.(e,s(t,void 0,void 0,{activationDirection:`none`}))}),G=p((e,t)=>{v(n=>{if(n.get(e)===t)return n;let r=new Map(n);return r.set(e,t),r})}),K=p((e,t)=>{v(n=>{if(!n.has(e)||n.get(e)!==t)return n;let r=new Map(n);return r.delete(e),r})}),q=j.useCallback(e=>g.get(e),[g]),J=j.useCallback(e=>{for(let t of w.values())if(e===t?.value)return t?.id},[w]),Y=j.useMemo(()=>({getTabElementBySelectedValue:k,getTabIdByPanelValue:J,getTabPanelIdByValue:q,onValueChange:U,orientation:a,registerMountedTabPanel:G,setTabMap:E,unregisterMountedTabPanel:K,tabActivationDirection:z,value:x}),[k,J,q,U,a,G,E,K,z,x]),X=j.useMemo(()=>{for(let e of w.values())if(e!=null&&e.value===x)return e},[w,x]),Z=j.useMemo(()=>{for(let e of w.values())if(e!=null&&!e.disabled)return e.value},[w]),Q=j.useRef(!f),$=j.useRef(r),ee=j.useRef(f),te=j.useRef(!1);y(()=>{if(C)return;function e(e,t){S(e),N(t=>t.previousValue===e&&t.tabActivationDirection===`none`?t:{previousValue:e,tabActivationDirection:`none`}),W(e,t),Q.current=!1}if(w.size===0){te.current&&x!==null&&!O.current?.isConnected&&e(null,u);return}te.current=!0,O.current=w.keys().next().value;let t=X?.disabled,n=X==null&&x!==null;if(!t&&x===$.current&&(ee.current=!1),ee.current&&t&&x===$.current)return;let r=Q.current;if(t||n){let n=Z??null;if(x===n){Q.current=!1;return}let i=u;r?i=_:t&&(i=m),e(n,i);return}r&&X!=null&&(W(x,_),Q.current=!1)},[Z,C,W,X,S,w,x]);let ne=b(`div`,e,{state:{orientation:a,tabActivationDirection:z},ref:t,props:d,stateAttributesMapping:F});return(0,I.jsx)(M.Provider,{value:Y,children:(0,I.jsx)(D,{elementsRef:h,children:ne})})});function R(e,t,n,r){if(e==null||t==null)return`none`;let i=null,a=null;for(let[n,o]of r.entries()){if(o==null)continue;let r=o.value??o.index;if(e===r&&(i=n),t===r&&(a=n),i!=null&&a!=null)break}if(i==null||a==null)return i!==a&&(typeof e==`number`||typeof e==`string`)&&typeof e==typeof t?n===`horizontal`?t>e?`right`:`left`:t>e?`down`:`up`:`none`;let o=i.getBoundingClientRect(),s=a.getBoundingClientRect();if(n===`horizontal`){if(s.left<o.left)return`left`;if(s.left>o.left)return`right`}else{if(s.top<o.top)return`up`;if(s.top>o.top)return`down`}return`none`}var z=j.createContext(void 0);function B(){let e=j.useContext(z);if(e===void 0)throw Error(d(65));return e}var V=j.forwardRef(function(e,t){let{className:n,disabled:r=!1,render:i,value:c,id:l,nativeButton:u=!0,style:d,...p}=e,{value:m,getTabPanelIdByValue:h,orientation:_,tabActivationDirection:S}=N(),{activateOnFocus:C,highlightedTabIndex:w,onTabActivation:T,registerTabResizeObserverElement:E,setHighlightedTabIndex:D,tabsListElement:A}=B(),M=f(l),{compositeProps:P,compositeRef:I,index:L}=O({metadata:j.useMemo(()=>({disabled:r,id:M,value:c}),[r,M,c])}),R=c===m,z=j.useRef(!1),V=j.useRef(null);y(()=>{let e=V.current;if(e)return E(e)},[E]),y(()=>{if(z.current){z.current=!1;return}if(!(R&&L>-1&&w!==L))return;let e=A;if(e!=null){let t=g(a(e));if(t&&o(e,t))return}r||D(L)},[R,L,w,D,r,A]);let{getButtonProps:H,buttonRef:U}=v({disabled:r,native:u,focusableWhenDisabled:!0}),W=h(c),G=j.useRef(!1),K=j.useRef(!1);function q(e){R||r||T(c,s(x,e.nativeEvent,void 0,{activationDirection:`none`}))}function J(e){R||(L>-1&&!r&&D(L),!r&&C&&(!G.current||G.current&&K.current)&&T(c,s(x,e.nativeEvent,void 0,{activationDirection:`none`})))}function Y(e){if(R||r)return;G.current=!0;function t(){G.current=!1,K.current=!1}(!e.button||e.button===0)&&(K.current=!0,a(e.currentTarget).addEventListener(`pointerup`,t,{once:!0}))}return b(`button`,e,{state:{disabled:r,active:R,orientation:_,tabActivationDirection:S},ref:[t,U,I,V],props:[P,{role:`tab`,"aria-controls":W,"aria-selected":R,id:M,onClick:q,onFocus:J,onPointerDown:Y,[k]:R?``:void 0,onKeyDownCapture(){z.current=!0}},p,H],stateAttributesMapping:F})}),H=function(e){return e.index=`data-index`,e.activationDirection=`data-activation-direction`,e.orientation=`data-orientation`,e.hidden=`data-hidden`,e[e.startingStyle=r.startingStyle]=`startingStyle`,e[e.endingStyle=r.endingStyle]=`endingStyle`,e}({}),U={...F,...l},W=j.forwardRef(function(e,t){let{className:n,value:r,render:a,keepMounted:o=!1,style:s,...l}=e,{value:u,getTabIdByPanelValue:d,orientation:p,tabActivationDirection:m,registerMountedTabPanel:h,unregisterMountedTabPanel:g}=N(),_=f(),{ref:v,index:x}=E({metadata:j.useMemo(()=>({id:_,value:r}),[_,r])}),S=r===u,{mounted:C,transitionStatus:T,setMounted:D}=c(S),O=!C,k=d(r),A={hidden:O,orientation:p,tabActivationDirection:m,transitionStatus:T},M=j.useRef(null),P=b(`div`,e,{state:A,ref:[t,v,M],props:[{"aria-labelledby":k,hidden:O,id:_,role:`tabpanel`,tabIndex:S?0:-1,inert:w(!S),[H.index]:x},l],stateAttributesMapping:U});return i({open:S,ref:M,onComplete(){S||D(!1)}}),y(()=>{if(!(O&&!o)&&_!=null)return h(r,_),()=>{g(r,_)}},[O,o,r,_,h,g]),o||C?P:null}),G=j.forwardRef(function(e,t){let{activateOnFocus:n=!1,className:r,loopFocus:i=!0,render:a,style:o,...s}=e,{onValueChange:c,orientation:l,value:u,setTabMap:d,tabActivationDirection:f}=N(),[m,g]=j.useState(0),[_,v]=j.useState(null),b=j.useRef(new Set),x=j.useRef(new Set),S=j.useRef(null);y(()=>{if(typeof ResizeObserver>`u`)return;let e=new ResizeObserver(()=>{b.current.forEach(e=>{e()})});return S.current=e,_&&e.observe(_),x.current.forEach(t=>{e.observe(t)}),()=>{e.disconnect(),S.current=null}},[_]);let C=p(e=>(b.current.add(e),()=>{b.current.delete(e)})),w=p(e=>(x.current.add(e),S.current?.observe(e),()=>{x.current.delete(e),S.current?.unobserve(e)})),T=p((e,t)=>{e!==u&&c(e,t)}),E={orientation:l,tabActivationDirection:f},D={"aria-orientation":l===`vertical`?`vertical`:void 0,role:`tablist`},O=j.useMemo(()=>({activateOnFocus:n,highlightedTabIndex:m,registerIndicatorUpdateListener:C,registerTabResizeObserverElement:w,onTabActivation:T,setHighlightedTabIndex:g,tabsListElement:_}),[n,m,C,w,T,g,_]);return(0,I.jsx)(z.Provider,{value:O,children:(0,I.jsx)(A,{render:a,className:r,style:o,state:E,refs:[t,v],props:[D,s],stateAttributesMapping:F,highlightedIndex:m,enableHomeAndEndKeys:!0,loopFocus:i,orientation:l,onHighlightedIndexChange:g,onMapChange:d,disabledIndices:h})})});function K({className:e,orientation:t=`horizontal`,...n}){return(0,I.jsx)(L,{"data-slot":`tabs`,"data-orientation":t,className:C(`gap-2 group/tabs flex data-[orientation=horizontal]:flex-col`,e),...n})}var q=n(`rounded-lg p-[3px] group-data-horizontal/tabs:h-9 data-[variant=line]:rounded-none group/tabs-list text-muted-foreground inline-flex w-fit items-center justify-center group-data-[orientation=vertical]/tabs:h-fit group-data-[orientation=vertical]/tabs:flex-col`,{variants:{variant:{default:`bg-muted`,line:`gap-1 bg-transparent`}},defaultVariants:{variant:`default`}});function J({className:e,variant:t=`default`,...n}){return(0,I.jsx)(G,{"data-slot":`tabs-list`,"data-variant":t,className:C(q({variant:t}),e),...n})}function Y({className:e,...t}){return(0,I.jsx)(V,{"data-slot":`tabs-trigger`,className:C(`gap-1.5 rounded-md border border-transparent px-2 py-1 text-sm font-medium group-data-[variant=default]/tabs-list:data-active:shadow-sm group-data-[variant=line]/tabs-list:data-active:shadow-none [&_svg:not([class*='size-'])]:size-4 focus-visible:border-ring focus-visible:ring-ring/50 focus-visible:outline-ring text-foreground/60 hover:text-foreground relative inline-flex h-[calc(100%-1px)] flex-1 items-center justify-center whitespace-nowrap transition-all group-data-[orientation=vertical]/tabs:w-full group-data-[orientation=vertical]/tabs:justify-start focus-visible:ring-[3px] focus-visible:outline-1 disabled:pointer-events-none disabled:opacity-50 aria-disabled:pointer-events-none aria-disabled:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0`,`group-data-[variant=line]/tabs-list:bg-transparent group-data-[variant=line]/tabs-list:data-active:bg-transparent dark:group-data-[variant=line]/tabs-list:data-active:border-transparent dark:group-data-[variant=line]/tabs-list:data-active:bg-transparent`,`data-active:bg-background data-active:text-foreground`,`after:bg-foreground after:absolute after:opacity-0 after:transition-opacity group-data-[orientation=horizontal]/tabs:after:inset-x-0 group-data-[orientation=horizontal]/tabs:after:bottom-[-5px] group-data-[orientation=horizontal]/tabs:after:h-0.5 group-data-[orientation=vertical]/tabs:after:inset-y-0 group-data-[orientation=vertical]/tabs:after:-right-1 group-data-[orientation=vertical]/tabs:after:w-0.5 group-data-[variant=line]/tabs-list:data-active:after:opacity-100`,e),...t})}function X({className:e,...t}){return(0,I.jsx)(W,{"data-slot":`tabs-content`,className:C(`text-sm flex-1 outline-none`,e),...t})}export{Y as i,X as n,J as r,K as t};
|
|
1
|
+
import{r as e}from"./chunk-QTnfLwEv.js";import{t}from"./react-sKtkuLrH.js";import{c as n}from"./section-BPNIPavy.js";import{J as r,K as i,Kt as a,Mn as o,Qt as s,X as c,Y as l,_n as u,fr as d,g as f,hr as p,in as m,ir as h,jn as g,ln as _,lr as v,mr as y,nr as b,vn as x}from"./example-CJMJcnb4.js";import{d as S,n as C}from"./index-jD-KSiHu.js";import{t as w}from"./inertValue-Dg9TwvOb.js";import{t as T}from"./useControlled-BHUji6Sp.js";import{n as E,r as D}from"./useCompositeListItem-PrMTh4tz.js";import{t as O}from"./useCompositeItem-CIuww7-p.js";import{n as k,t as A}from"./CompositeRoot-DSPvBRQr.js";var j=e(t(),1),M=j.createContext(void 0);function N(){let e=j.useContext(M);if(e===void 0)throw Error(d(64));return e}var P=function(e){return e.activationDirection=`data-activation-direction`,e.orientation=`data-orientation`,e}({}),F={tabActivationDirection:e=>({[P.activationDirection]:e})},I=S(),L=j.forwardRef(function(e,t){let{className:n,defaultValue:r=0,onValueChange:i,orientation:a=`horizontal`,render:o,value:c,style:l,...d}=e,f=e.defaultValue!==void 0,h=j.useRef([]),[g,v]=j.useState(()=>new Map),[x,S]=T({controlled:c,default:r,name:`Tabs`,state:`value`}),C=c!==void 0,[w,E]=j.useState(()=>new Map),O=j.useRef(void 0),k=j.useCallback(e=>{if(e===void 0)return null;for(let[t,n]of w.entries())if(n!=null&&e===(n.value??n.index))return t;return null},[w]),[A,N]=j.useState(()=>({previousValue:x,tabActivationDirection:`none`})),{previousValue:P,tabActivationDirection:L}=A,z=L,B=!1;P!==x&&(z=R(P,x,a,w),B=P!=null&&x!=null&&k(x)==null);let V=B?P:x,H=P!==V||L!==z;y(()=>{H&&N({previousValue:V,tabActivationDirection:z})},[V,H,z]);let U=p((e,t)=>{t.activationDirection=R(x,e,a,w),i?.(e,t),!t.isCanceled&&S(e)}),W=p((e,t)=>{i?.(e,s(t,void 0,void 0,{activationDirection:`none`}))}),G=p((e,t)=>{v(n=>{if(n.get(e)===t)return n;let r=new Map(n);return r.set(e,t),r})}),K=p((e,t)=>{v(n=>{if(!n.has(e)||n.get(e)!==t)return n;let r=new Map(n);return r.delete(e),r})}),q=j.useCallback(e=>g.get(e),[g]),J=j.useCallback(e=>{for(let t of w.values())if(e===t?.value)return t?.id},[w]),Y=j.useMemo(()=>({getTabElementBySelectedValue:k,getTabIdByPanelValue:J,getTabPanelIdByValue:q,onValueChange:U,orientation:a,registerMountedTabPanel:G,setTabMap:E,unregisterMountedTabPanel:K,tabActivationDirection:z,value:x}),[k,J,q,U,a,G,E,K,z,x]),X=j.useMemo(()=>{for(let e of w.values())if(e!=null&&e.value===x)return e},[w,x]),Z=j.useMemo(()=>{for(let e of w.values())if(e!=null&&!e.disabled)return e.value},[w]),Q=j.useRef(!f),$=j.useRef(r),ee=j.useRef(f),te=j.useRef(!1);y(()=>{if(C)return;function e(e,t){S(e),N(t=>t.previousValue===e&&t.tabActivationDirection===`none`?t:{previousValue:e,tabActivationDirection:`none`}),W(e,t),Q.current=!1}if(w.size===0){te.current&&x!==null&&!O.current?.isConnected&&e(null,u);return}te.current=!0,O.current=w.keys().next().value;let t=X?.disabled,n=X==null&&x!==null;if(!t&&x===$.current&&(ee.current=!1),ee.current&&t&&x===$.current)return;let r=Q.current;if(t||n){let n=Z??null;if(x===n){Q.current=!1;return}let i=u;r?i=_:t&&(i=m),e(n,i);return}r&&X!=null&&(W(x,_),Q.current=!1)},[Z,C,W,X,S,w,x]);let ne=b(`div`,e,{state:{orientation:a,tabActivationDirection:z},ref:t,props:d,stateAttributesMapping:F});return(0,I.jsx)(M.Provider,{value:Y,children:(0,I.jsx)(D,{elementsRef:h,children:ne})})});function R(e,t,n,r){if(e==null||t==null)return`none`;let i=null,a=null;for(let[n,o]of r.entries()){if(o==null)continue;let r=o.value??o.index;if(e===r&&(i=n),t===r&&(a=n),i!=null&&a!=null)break}if(i==null||a==null)return i!==a&&(typeof e==`number`||typeof e==`string`)&&typeof e==typeof t?n===`horizontal`?t>e?`right`:`left`:t>e?`down`:`up`:`none`;let o=i.getBoundingClientRect(),s=a.getBoundingClientRect();if(n===`horizontal`){if(s.left<o.left)return`left`;if(s.left>o.left)return`right`}else{if(s.top<o.top)return`up`;if(s.top>o.top)return`down`}return`none`}var z=j.createContext(void 0);function B(){let e=j.useContext(z);if(e===void 0)throw Error(d(65));return e}var V=j.forwardRef(function(e,t){let{className:n,disabled:r=!1,render:i,value:c,id:l,nativeButton:u=!0,style:d,...p}=e,{value:m,getTabPanelIdByValue:h,orientation:_,tabActivationDirection:S}=N(),{activateOnFocus:C,highlightedTabIndex:w,onTabActivation:T,registerTabResizeObserverElement:E,setHighlightedTabIndex:D,tabsListElement:A}=B(),M=f(l),{compositeProps:P,compositeRef:I,index:L}=O({metadata:j.useMemo(()=>({disabled:r,id:M,value:c}),[r,M,c])}),R=c===m,z=j.useRef(!1),V=j.useRef(null);y(()=>{let e=V.current;if(e)return E(e)},[E]),y(()=>{if(z.current){z.current=!1;return}if(!(R&&L>-1&&w!==L))return;let e=A;if(e!=null){let t=g(a(e));if(t&&o(e,t))return}r||D(L)},[R,L,w,D,r,A]);let{getButtonProps:H,buttonRef:U}=v({disabled:r,native:u,focusableWhenDisabled:!0}),W=h(c),G=j.useRef(!1),K=j.useRef(!1);function q(e){R||r||T(c,s(x,e.nativeEvent,void 0,{activationDirection:`none`}))}function J(e){R||(L>-1&&!r&&D(L),!r&&C&&(!G.current||G.current&&K.current)&&T(c,s(x,e.nativeEvent,void 0,{activationDirection:`none`})))}function Y(e){if(R||r)return;G.current=!0;function t(){G.current=!1,K.current=!1}(!e.button||e.button===0)&&(K.current=!0,a(e.currentTarget).addEventListener(`pointerup`,t,{once:!0}))}return b(`button`,e,{state:{disabled:r,active:R,orientation:_,tabActivationDirection:S},ref:[t,U,I,V],props:[P,{role:`tab`,"aria-controls":W,"aria-selected":R,id:M,onClick:q,onFocus:J,onPointerDown:Y,[k]:R?``:void 0,onKeyDownCapture(){z.current=!0}},p,H],stateAttributesMapping:F})}),H=function(e){return e.index=`data-index`,e.activationDirection=`data-activation-direction`,e.orientation=`data-orientation`,e.hidden=`data-hidden`,e[e.startingStyle=r.startingStyle]=`startingStyle`,e[e.endingStyle=r.endingStyle]=`endingStyle`,e}({}),U={...F,...l},W=j.forwardRef(function(e,t){let{className:n,value:r,render:a,keepMounted:o=!1,style:s,...l}=e,{value:u,getTabIdByPanelValue:d,orientation:p,tabActivationDirection:m,registerMountedTabPanel:h,unregisterMountedTabPanel:g}=N(),_=f(),{ref:v,index:x}=E({metadata:j.useMemo(()=>({id:_,value:r}),[_,r])}),S=r===u,{mounted:C,transitionStatus:T,setMounted:D}=c(S),O=!C,k=d(r),A={hidden:O,orientation:p,tabActivationDirection:m,transitionStatus:T},M=j.useRef(null),P=b(`div`,e,{state:A,ref:[t,v,M],props:[{"aria-labelledby":k,hidden:O,id:_,role:`tabpanel`,tabIndex:S?0:-1,inert:w(!S),[H.index]:x},l],stateAttributesMapping:U});return i({open:S,ref:M,onComplete(){S||D(!1)}}),y(()=>{if(!(O&&!o)&&_!=null)return h(r,_),()=>{g(r,_)}},[O,o,r,_,h,g]),o||C?P:null}),G=j.forwardRef(function(e,t){let{activateOnFocus:n=!1,className:r,loopFocus:i=!0,render:a,style:o,...s}=e,{onValueChange:c,orientation:l,value:u,setTabMap:d,tabActivationDirection:f}=N(),[m,g]=j.useState(0),[_,v]=j.useState(null),b=j.useRef(new Set),x=j.useRef(new Set),S=j.useRef(null);y(()=>{if(typeof ResizeObserver>`u`)return;let e=new ResizeObserver(()=>{b.current.forEach(e=>{e()})});return S.current=e,_&&e.observe(_),x.current.forEach(t=>{e.observe(t)}),()=>{e.disconnect(),S.current=null}},[_]);let C=p(e=>(b.current.add(e),()=>{b.current.delete(e)})),w=p(e=>(x.current.add(e),S.current?.observe(e),()=>{x.current.delete(e),S.current?.unobserve(e)})),T=p((e,t)=>{e!==u&&c(e,t)}),E={orientation:l,tabActivationDirection:f},D={"aria-orientation":l===`vertical`?`vertical`:void 0,role:`tablist`},O=j.useMemo(()=>({activateOnFocus:n,highlightedTabIndex:m,registerIndicatorUpdateListener:C,registerTabResizeObserverElement:w,onTabActivation:T,setHighlightedTabIndex:g,tabsListElement:_}),[n,m,C,w,T,g,_]);return(0,I.jsx)(z.Provider,{value:O,children:(0,I.jsx)(A,{render:a,className:r,style:o,state:E,refs:[t,v],props:[D,s],stateAttributesMapping:F,highlightedIndex:m,enableHomeAndEndKeys:!0,loopFocus:i,orientation:l,onHighlightedIndexChange:g,onMapChange:d,disabledIndices:h})})});function K({className:e,orientation:t=`horizontal`,...n}){return(0,I.jsx)(L,{"data-slot":`tabs`,"data-orientation":t,className:C(`gap-2 group/tabs flex data-[orientation=horizontal]:flex-col`,e),...n})}var q=n(`rounded-lg p-[3px] group-data-horizontal/tabs:h-9 data-[variant=line]:rounded-none group/tabs-list text-muted-foreground inline-flex w-fit items-center justify-center group-data-[orientation=vertical]/tabs:h-fit group-data-[orientation=vertical]/tabs:flex-col`,{variants:{variant:{default:`bg-muted`,line:`gap-1 bg-transparent`}},defaultVariants:{variant:`default`}});function J({className:e,variant:t=`default`,...n}){return(0,I.jsx)(G,{"data-slot":`tabs-list`,"data-variant":t,className:C(q({variant:t}),e),...n})}function Y({className:e,...t}){return(0,I.jsx)(V,{"data-slot":`tabs-trigger`,className:C(`gap-1.5 rounded-md border border-transparent px-2 py-1 text-sm font-medium group-data-[variant=default]/tabs-list:data-active:shadow-sm group-data-[variant=line]/tabs-list:data-active:shadow-none [&_svg:not([class*='size-'])]:size-4 focus-visible:border-ring focus-visible:ring-ring/50 focus-visible:outline-ring text-foreground/60 hover:text-foreground relative inline-flex h-[calc(100%-1px)] flex-1 items-center justify-center whitespace-nowrap transition-all group-data-[orientation=vertical]/tabs:w-full group-data-[orientation=vertical]/tabs:justify-start focus-visible:ring-[3px] focus-visible:outline-1 disabled:pointer-events-none disabled:opacity-50 aria-disabled:pointer-events-none aria-disabled:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0`,`group-data-[variant=line]/tabs-list:bg-transparent group-data-[variant=line]/tabs-list:data-active:bg-transparent dark:group-data-[variant=line]/tabs-list:data-active:border-transparent dark:group-data-[variant=line]/tabs-list:data-active:bg-transparent`,`data-active:bg-background data-active:text-foreground`,`after:bg-foreground after:absolute after:opacity-0 after:transition-opacity group-data-[orientation=horizontal]/tabs:after:inset-x-0 group-data-[orientation=horizontal]/tabs:after:bottom-[-5px] group-data-[orientation=horizontal]/tabs:after:h-0.5 group-data-[orientation=vertical]/tabs:after:inset-y-0 group-data-[orientation=vertical]/tabs:after:-right-1 group-data-[orientation=vertical]/tabs:after:w-0.5 group-data-[variant=line]/tabs-list:data-active:after:opacity-100`,e),...t})}function X({className:e,...t}){return(0,I.jsx)(W,{"data-slot":`tabs-content`,className:C(`text-sm flex-1 outline-none`,e),...t})}export{Y as i,X as n,J as r,K as t};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{r as e}from"./chunk-QTnfLwEv.js";import{t}from"./react-sKtkuLrH.js";import{o as n,p as r,x as i}from"./section-Dd6X6IKg.js";import{Or as a}from"./example-Rrx9vj75.js";import{t as o}from"./minus-CwzskYaZ.js";import{t as s}from"./plus-4gOvUk-5.js";import{t as c}from"./x-FNPo6qUv.js";import{N as l,d as u,n as d}from"./index-o71HAmc3.js";import{t as f}from"./text-button-CoPZBQiq.js";import{t as p}from"./label-HtkE4eII.js";import{t as m}from"./checkbox-BqwbtGCF.js";import{f as h}from"./form-sizing-C3UG5WKC.js";import{t as g}from"./input-CYTQ9nWN.js";import{t as _}from"./switch-DirKCDsg.js";var v=e(t(),1),y=u(),b={decrement:`Decrement`,increment:`Increment`},x=(e,t,n)=>{if(!e)return``;let r=e;if(r=r.replace(/,/g,`.`),r=n?r.replace(/[^\d.-]/g,``):r.replace(/[^\d.]/g,``),n&&r.includes(`-`)){let e=r.startsWith(`-`);r=r.replace(/-/g,``),e&&(r=`-`+r)}let i=r.split(`.`);return i.length>2&&(r=i[0]+`.`+i.slice(1).join(``)),i.length===2&&i[1].length>t&&(r=i[0]+`.`+i[1].substring(0,t)),r},S=(e,t,n)=>{if(!e||e===`-`)return!0;let r=parseFloat(e);return Number.isNaN(r)?!0:!(t!==void 0&&r<t||n!==void 0&&r>n)};function C(e,t,n){let r=10**t,i=e*r;switch(n){case`floor`:return Math.floor(i)/r;case`ceil`:return Math.ceil(i)/r;case`half-even`:{let e=Math.floor(i),t=i-e;return t>.5?(e+1)/r:t<.5?e/r:(e%2==0?e:e+1)/r}default:return Math.round(i)/r}}function w(e,t,n){let r=e;return t!==void 0&&(r=Math.max(t,r)),n!==void 0&&(r=Math.min(n,r)),r}function T(e,t,n,r,i=`round`){let a=r??0,o=(e-a)/n,s=a+((i===`floor`?Math.floor(o):i===`ceil`?Math.ceil(o):Math.round(o))+t)*n;return Number(s.toFixed(12))}function E(e,t,n){let r=Object.getOwnPropertyDescriptor(window.HTMLInputElement.prototype,`value`)?.set;r?r.call(e,t):e.value=t,n&&n({target:e,currentTarget:e,type:`change`,bubbles:!1,cancelable:!1})}var D={small:`w-control-small`,default:`w-control`};function O({decimalPlaces:e=2,min:t,max:n,allowNegative:r=!0,allowEmpty:a=!0,step:c,roundingMode:u=`round`,normalizeOnBlur:f=!0,onChange:p,onBlur:m,placeholder:_,className:O,value:k,defaultValue:A,disabled:j,size:M,strings:N,...P},F){let{defaultControlSize:I}=i(),L=h(M,I),R=l(b,N),z=Math.min(12,Math.max(0,e)),B=v.useRef(null),V=(0,v.useCallback)(e=>{let i=e.target.value;if(!i&&a){p?.(e);return}let o=x(i,z,r);if(S(o,t,n))if(o!==i){let t={...e,target:{...e.target,value:o},currentTarget:{...e.currentTarget,value:o}};p?.(t)}else p?.(e)},[p,z,r,a,t,n]),H=(0,v.useCallback)(e=>{if(m?.(e),!f)return;let r=e.target.value;if(!r&&a)return;let i=Number.parseFloat(r.replace(`,`,`.`));if(!Number.isFinite(i))return;let o=C(w(i,t,n),z,u).toFixed(z);o!==r&&B.current&&E(B.current,o,p)},[m,p,f,a,t,n,z,u]),U=(0,v.useCallback)(e=>{if(j||c===void 0)return;let r=B.current;if(!r)return;let i=r.value,a=Number.parseFloat(i.replace(`,`,`.`));E(r,C(w(T(Number.isFinite(a)?a:t??0,e,c,t,u),t,n),z,u).toFixed(z),p)},[j,c,t,n,u,z,p]),W=typeof c==`number`&&c>0,G=_??(z>0?`0.${`0`.repeat(z)}`:`0`);return W?(0,y.jsxs)(`div`,{className:d(`decimal-input--component`,`flex items-stretch overflow-hidden rounded-radius border border-input bg-transparent`,`focus-within:border-ring focus-within:ring-ring/50 focus-within:ring-[3px]`,P[`aria-invalid`]&&`border-destructive ring-destructive/20`,j&&`opacity-50 cursor-not-allowed`),children:[(0,y.jsx)(`button`,{type:`button`,tabIndex:-1,"aria-label":R.decrement,disabled:j,onClick:()=>U(-1),className:d(`inline-flex shrink-0 items-center justify-center border-r border-input text-muted-foreground transition-colors`,D[L],`hover:bg-muted hover:text-foreground`,`disabled:cursor-not-allowed disabled:opacity-50`),children:(0,y.jsx)(o,{className:L===`small`?`size-icon-sm`:`size-icon`})}),(0,y.jsx)(g,{size:L,ref:e=>{B.current=e,typeof F==`function`?F(e):F&&(F.current=e)},type:`text`,inputMode:z>0?`decimal`:`numeric`,placeholder:G,onChange:V,onBlur:H,value:k,defaultValue:A,disabled:j,className:d(`flex-1 tabular-nums text-center border-0 shadow-none rounded-none focus-visible:ring-0 focus-visible:border-0`,O),...P}),(0,y.jsx)(`button`,{type:`button`,tabIndex:-1,"aria-label":R.increment,disabled:j,onClick:()=>U(1),className:d(`inline-flex shrink-0 items-center justify-center border-l border-input text-muted-foreground transition-colors`,D[L],`hover:bg-muted hover:text-foreground`,`disabled:cursor-not-allowed disabled:opacity-50`),children:(0,y.jsx)(s,{className:L===`small`?`size-icon-sm`:`size-icon`})})]}):(0,y.jsx)(g,{size:L,ref:e=>{B.current=e,typeof F==`function`?F(e):F&&(F.current=e)},type:`text`,inputMode:z>0?`decimal`:`numeric`,placeholder:G,onChange:V,onBlur:H,value:k,defaultValue:A,disabled:j,className:d(`tabular-nums text-end`,O),...P})}var k=v.forwardRef(O);k.displayName=`DecimalInput`;function A({label:e,description:t,hint:n,icon:i,name:a,value:o,defaultValue:s,onChange:c,disabled:l=!1,invalid:u,className:f}){let m=o!==void 0,[h,g]=(0,v.useState)(s??!1),b=m?o??!1:h,x=(0,v.useId)(),S=(0,v.useMemo)(()=>a??x,[a,x]),C=typeof t==`string`&&t.trim()!==``,w=C?`${S}-description`:void 0,T=(0,v.useCallback)(e=>{l||(m||g(e),c?.(e))},[l,m,c]),E=(0,v.useCallback)(e=>{e.target.closest(`[role="switch"]`)||T(!b)},[b,T]);return(0,y.jsxs)(`div`,{"aria-invalid":u||void 0,onClick:E,className:d(`switch-card--component`,`group relative flex items-start gap-3 rounded-lg border bg-card p-4 transition-[background,border-color,box-shadow] duration-150`,`border-border`,b&&`border-primary bg-primary/[0.04]`,`aria-invalid:border-destructive aria-invalid:ring-2 aria-invalid:ring-destructive/20`,!l&&`cursor-pointer hover:border-foreground/20 hover:bg-muted/30`,l&&`cursor-not-allowed opacity-50`,f),children:[!!a&&(0,y.jsx)(`input`,{type:`hidden`,name:a,value:b?`1`:`0`,"aria-hidden":`true`}),!!i&&(0,y.jsx)(`span`,{className:d(`mt-0.5 inline-flex size-9 shrink-0 items-center justify-center rounded-md transition-colors`,b?`bg-primary/10 text-primary`:`bg-muted/50 text-muted-foreground group-hover:bg-muted group-hover:text-foreground`),children:(0,y.jsx)(i,{className:`size-4`})}),(0,y.jsxs)(`div`,{className:`min-w-0 flex-1 space-y-0.5`,children:[(0,y.jsx)(p,{htmlFor:S,className:d(`block font-semibold tracking-tight`,l?`cursor-not-allowed`:`cursor-pointer`),children:e}),!!C&&(0,y.jsx)(r,{type:`secondary`,className:`leading-snug`,children:t}),!!n&&(0,y.jsx)(r,{size:`xs`,type:`discrete`,className:`leading-snug`,children:n})]}),(0,y.jsx)(`div`,{className:`mt-1 flex shrink-0 items-center`,children:(0,y.jsx)(_,{id:S,checked:b,onCheckedChange:e=>T(e),disabled:l,"aria-label":e,"aria-describedby":w})}),!!C&&(0,y.jsx)(`span`,{id:`${S}-description`,className:`sr-only`,children:t})]})}A.displayName=`SwitchCard`;function j({label:e,description:t,kind:n=`switch`,value:i,defaultValue:a,onChange:o,disabled:s=!1,invalid:c=!1,name:l,className:u,controlPosition:f=`trailing`}){let h=i!==void 0,[g,b]=(0,v.useState)(a??!1),x=h?i??!1:g,S=(0,v.useId)(),C=(0,v.useCallback)(e=>{s||(h||b(e),o?.(e))},[s,h,o]),w=e=>{e.target.closest(`[role="switch"], [role="checkbox"], input[type="checkbox"]`)||C(!x)},T=n===`switch`?(0,y.jsx)(_,{id:S,name:l,checked:x,onCheckedChange:e=>C(e),disabled:s,"aria-invalid":c||void 0}):(0,y.jsx)(m,{id:S,name:l,checked:x,onCheckedChange:e=>C(e===!0),disabled:s,"aria-invalid":c||void 0}),E=(0,y.jsxs)(`div`,{className:`min-w-0 flex-1`,children:[(0,y.jsx)(p,{htmlFor:S,className:d(`block leading-snug`,s?`cursor-not-allowed opacity-50`:`cursor-pointer`),children:e}),!!t&&(0,y.jsx)(r,{size:`xs`,type:`secondary`,className:`mt-0.5 leading-snug`,children:t})]});return(0,y.jsxs)(`div`,{role:`group`,onClick:w,className:d(`toggle-field--component`,`flex items-start gap-3 rounded-md py-1`,s&&`pointer-events-none`,u),children:[f===`leading`&&(0,y.jsx)(`div`,{className:`mt-0.5 flex shrink-0`,children:T}),E,f===`trailing`&&(0,y.jsx)(`div`,{className:`mt-0.5 flex shrink-0`,children:T})]})}j.displayName=`ToggleField`;var M={placeholder:`Add a tag…`,emptyRecommendations:`No recommendations found.`,clearAll:`Clear all`,summary:(e,t)=>`${e} / ${t} tags`};function N({value:e=[],onChange:t,placeholder:i,recommendations:o,maxTags:s,showMaxTags:u=!1,allowDuplicates:p=!1,validate:m,disabled:h=!1,showClearAll:_=!1,renderTag:b,delimiter:x=/[\n,]/,addOnBlur:S=!0,minLength:C=1,maxLength:w,emptyMessage:T,sortTags:E=!1,caseSensitive:D=!1,field:O,invalid:k,className:A,strings:j}){let N=l(l(M,i!==void 0||T!==void 0?{placeholder:i,emptyRecommendations:T}:void 0),j),[P,F]=(0,v.useState)(``),[I,L]=(0,v.useState)(!1),[R,z]=(0,v.useState)(-1),B=(0,v.useRef)(null),V=(0,v.useCallback)(e=>{if(typeof e==`string`)return e;if(O&&typeof e==`object`&&e){let t=e[O];return typeof t==`string`?t:t==null?``:String(t)}return String(e)},[O]),H=(0,v.useCallback)(t=>typeof e[0]==`string`||e.length===0?t:O?{[O]:t}:t,[O,e]),U=(0,v.useMemo)(()=>o?o.map(e=>e&&typeof e==`object`&&`value`in e&&`label`in e?e:{value:e,label:V(e)}):[],[o,V]),W=(0,v.useMemo)(()=>{if(!U.length||!P)return U;let t=D?P:P.toLowerCase(),n=new Set(e.map(e=>{let t=V(e);return D?t:t.toLowerCase()}));return U.filter(e=>{let r=D?e.label:e.label.toLowerCase(),i=V(e.value),a=D?i:i.toLowerCase();return(r.includes(t)||a.includes(t))&&(p||!n.has(a))})},[U,P,e,p,D,V]),G=(0,v.useMemo)(()=>E?[...e].sort((e,t)=>{let n=V(e),r=V(t);return n.localeCompare(r)}):e,[e,E,V]),K=(0,v.useCallback)(n=>{let r=typeof n==`string`?H(n):n,i=V(r).trim();if(!i||i.length<C||w&&i.length>w||s&&e.length>=s||!p&&e.some(e=>{let t=V(e);return D?t===i:t.toLowerCase()===i.toLowerCase()})||m&&!m(r))return;let a=[...e,r];t?.(a),F(``),L(!1),z(-1)},[e,t,s,p,m,C,w,D,V,H]),q=(0,v.useCallback)(n=>{let r=e.filter((e,t)=>t!==n);t?.(r)},[e,t]),J=(0,v.useCallback)(e=>{let t=e.target.value;F(t),z(-1),o&&o.length>0&&L(!0)},[o]),Y=(0,v.useCallback)(t=>{h||(t.key===`Enter`?(t.preventDefault(),I&&R>=0&&R<W.length?(K(W[R].value),z(-1)):P.trim()&&K(P)):t.key===`Tab`?P&&(t.preventDefault(),K(P)):t.key===`ArrowDown`?(t.preventDefault(),I&&z(e=>e<W.length-1?e+1:e)):t.key===`ArrowUp`?(t.preventDefault(),I&&z(e=>e>0?e-1:0)):t.key===`Escape`?(L(!1),z(-1)):t.key===`Backspace`&&!P&&e.length>0&&q(e.length-1))},[h,I,R,W,P,K,q,e.length]),X=(0,v.useCallback)(e=>{h||(e.preventDefault(),e.clipboardData.getData(`text`).split(x).map(e=>e.trim()).filter(Boolean).forEach(e=>K(e)))},[h,x,K]),Z=(0,v.useCallback)(()=>{setTimeout(()=>{L(!1),S&&P&&K(P)},200)},[S,P,K]),Q=(0,v.useCallback)(()=>{t?.([]),F(``)},[t]),$=(0,v.useCallback)((e,t,r)=>{let i=`${V(e)}-${t}`;return(0,y.jsxs)(n,{variant:`secondary`,className:d(`tags-input--component`,`gap-1 pr-1 font-normal`),children:[V(e),(0,y.jsx)(`button`,{type:`button`,"aria-label":`Remove ${V(e)}`,className:d(`inline-flex size-icon items-center justify-center rounded-full`,`text-muted-foreground/70 hover:bg-foreground/10 hover:text-foreground`,`outline-none focus-visible:ring-2 focus-visible:ring-ring/50`,`disabled:opacity-50 disabled:pointer-events-none`),onClick:()=>r(t),disabled:h,children:(0,y.jsx)(c,{className:`size-icon-sm`,"aria-hidden":`true`})})]},i)},[V,h]),ee=!!k;return(0,y.jsxs)(`div`,{className:d(`w-full relative`,A),children:[(0,y.jsxs)(`div`,{className:`relative`,children:[(0,y.jsx)(g,{ref:B,type:`text`,placeholder:N.placeholder,value:P,onChange:J,onKeyDown:Y,onPaste:X,onBlur:Z,onFocus:()=>{o&&W.length>0&&L(!0)},disabled:h||s!==void 0&&e.length>=s,invalid:ee,maxLength:w,className:`w-full`}),!!o&&!!I&&(0,y.jsx)(`div`,{className:`absolute top-full left-0 right-0 z-50 mt-1 max-h-[200px] overflow-y-auto rounded-md bg-popover p-1 text-sm text-popover-foreground shadow-md ring-1 ring-foreground/10`,children:W.length>0?W.map((t,n)=>{let r=V(t.value),i=e.some(e=>V(e)===V(t.value));return(0,y.jsxs)(`button`,{type:`button`,onMouseDown:e=>{e.preventDefault(),K(t.value),z(-1),B.current?.focus()},onMouseEnter:()=>z(n),className:d(`relative flex w-full cursor-pointer items-center justify-between gap-space-sm rounded-md px-control-sm py-row-y text-xs`,`hover:bg-accent hover:text-accent-foreground`,`focus-visible:outline-none`,R===n&&`bg-accent text-accent-foreground`),children:[(0,y.jsx)(`span`,{children:t.label}),(0,y.jsx)(a,{className:d(`ml-auto size-icon-sm`,i?`opacity-100`:`opacity-0`)})]},r)}):(0,y.jsx)(r,{tag:`div`,size:`xs`,type:`secondary`,className:`px-2 py-row-y`,children:N.emptyRecommendations})})]}),G.length>0&&(0,y.jsxs)(`div`,{className:`mt-space-md flex flex-wrap items-center gap-space-sm`,children:[G.map((e,t)=>b?b(e,t,q):$(e,t,q)),!!_&&e.length>0&&!h&&(0,y.jsx)(f,{type:`button`,size:`small`,onClick:Q,className:`ml-auto`,children:N.clearAll})]}),!!s&&!!u&&(0,y.jsx)(r,{size:`xs`,type:`secondary`,className:`mt-1`,children:N.summary(e.length,s)})]})}N.displayName=`TagsInput`;export{k as i,j as n,A as r,N as t};
|
|
1
|
+
import{r as e}from"./chunk-QTnfLwEv.js";import{t}from"./react-sKtkuLrH.js";import{o as n,p as r,x as i}from"./section-BPNIPavy.js";import{Or as a}from"./example-CJMJcnb4.js";import{t as o}from"./minus-BE2L5hVc.js";import{t as s}from"./plus-CQcelTNc.js";import{t as c}from"./x-DyuS4YRT.js";import{N as l,d as u,n as d}from"./index-jD-KSiHu.js";import{t as f}from"./text-button-D9llh4pU.js";import{t as p}from"./label-DqaB8ZB2.js";import{t as m}from"./checkbox-BO38TYqr.js";import{f as h}from"./form-sizing-C3UG5WKC.js";import{t as g}from"./input-CkNgwwCs.js";import{t as _}from"./switch-BX9KSLIF.js";var v=e(t(),1),y=u(),b={decrement:`Decrement`,increment:`Increment`},x=(e,t,n)=>{if(!e)return``;let r=e;if(r=r.replace(/,/g,`.`),r=n?r.replace(/[^\d.-]/g,``):r.replace(/[^\d.]/g,``),n&&r.includes(`-`)){let e=r.startsWith(`-`);r=r.replace(/-/g,``),e&&(r=`-`+r)}let i=r.split(`.`);return i.length>2&&(r=i[0]+`.`+i.slice(1).join(``)),i.length===2&&i[1].length>t&&(r=i[0]+`.`+i[1].substring(0,t)),r},S=(e,t,n)=>{if(!e||e===`-`)return!0;let r=parseFloat(e);return Number.isNaN(r)?!0:!(t!==void 0&&r<t||n!==void 0&&r>n)};function C(e,t,n){let r=10**t,i=e*r;switch(n){case`floor`:return Math.floor(i)/r;case`ceil`:return Math.ceil(i)/r;case`half-even`:{let e=Math.floor(i),t=i-e;return t>.5?(e+1)/r:t<.5?e/r:(e%2==0?e:e+1)/r}default:return Math.round(i)/r}}function w(e,t,n){let r=e;return t!==void 0&&(r=Math.max(t,r)),n!==void 0&&(r=Math.min(n,r)),r}function T(e,t,n,r,i=`round`){let a=r??0,o=(e-a)/n,s=a+((i===`floor`?Math.floor(o):i===`ceil`?Math.ceil(o):Math.round(o))+t)*n;return Number(s.toFixed(12))}function E(e,t,n){let r=Object.getOwnPropertyDescriptor(window.HTMLInputElement.prototype,`value`)?.set;r?r.call(e,t):e.value=t,n&&n({target:e,currentTarget:e,type:`change`,bubbles:!1,cancelable:!1})}var D={small:`w-control-small`,default:`w-control`};function O({decimalPlaces:e=2,min:t,max:n,allowNegative:r=!0,allowEmpty:a=!0,step:c,roundingMode:u=`round`,normalizeOnBlur:f=!0,onChange:p,onBlur:m,placeholder:_,className:O,value:k,defaultValue:A,disabled:j,size:M,strings:N,...P},F){let{defaultControlSize:I}=i(),L=h(M,I),R=l(b,N),z=Math.min(12,Math.max(0,e)),B=v.useRef(null),V=(0,v.useCallback)(e=>{let i=e.target.value;if(!i&&a){p?.(e);return}let o=x(i,z,r);if(S(o,t,n))if(o!==i){let t={...e,target:{...e.target,value:o},currentTarget:{...e.currentTarget,value:o}};p?.(t)}else p?.(e)},[p,z,r,a,t,n]),H=(0,v.useCallback)(e=>{if(m?.(e),!f)return;let r=e.target.value;if(!r&&a)return;let i=Number.parseFloat(r.replace(`,`,`.`));if(!Number.isFinite(i))return;let o=C(w(i,t,n),z,u).toFixed(z);o!==r&&B.current&&E(B.current,o,p)},[m,p,f,a,t,n,z,u]),U=(0,v.useCallback)(e=>{if(j||c===void 0)return;let r=B.current;if(!r)return;let i=r.value,a=Number.parseFloat(i.replace(`,`,`.`));E(r,C(w(T(Number.isFinite(a)?a:t??0,e,c,t,u),t,n),z,u).toFixed(z),p)},[j,c,t,n,u,z,p]),W=typeof c==`number`&&c>0,G=_??(z>0?`0.${`0`.repeat(z)}`:`0`);return W?(0,y.jsxs)(`div`,{className:d(`decimal-input--component`,`flex items-stretch overflow-hidden rounded-radius border border-input bg-transparent`,`focus-within:border-ring focus-within:ring-ring/50 focus-within:ring-[3px]`,P[`aria-invalid`]&&`border-destructive ring-destructive/20`,j&&`opacity-50 cursor-not-allowed`),children:[(0,y.jsx)(`button`,{type:`button`,tabIndex:-1,"aria-label":R.decrement,disabled:j,onClick:()=>U(-1),className:d(`inline-flex shrink-0 items-center justify-center border-r border-input text-muted-foreground transition-colors`,D[L],`hover:bg-muted hover:text-foreground`,`disabled:cursor-not-allowed disabled:opacity-50`),children:(0,y.jsx)(o,{className:L===`small`?`size-icon-sm`:`size-icon`})}),(0,y.jsx)(g,{size:L,ref:e=>{B.current=e,typeof F==`function`?F(e):F&&(F.current=e)},type:`text`,inputMode:z>0?`decimal`:`numeric`,placeholder:G,onChange:V,onBlur:H,value:k,defaultValue:A,disabled:j,className:d(`flex-1 tabular-nums text-center border-0 shadow-none rounded-none focus-visible:ring-0 focus-visible:border-0`,O),...P}),(0,y.jsx)(`button`,{type:`button`,tabIndex:-1,"aria-label":R.increment,disabled:j,onClick:()=>U(1),className:d(`inline-flex shrink-0 items-center justify-center border-l border-input text-muted-foreground transition-colors`,D[L],`hover:bg-muted hover:text-foreground`,`disabled:cursor-not-allowed disabled:opacity-50`),children:(0,y.jsx)(s,{className:L===`small`?`size-icon-sm`:`size-icon`})})]}):(0,y.jsx)(g,{size:L,ref:e=>{B.current=e,typeof F==`function`?F(e):F&&(F.current=e)},type:`text`,inputMode:z>0?`decimal`:`numeric`,placeholder:G,onChange:V,onBlur:H,value:k,defaultValue:A,disabled:j,className:d(`tabular-nums text-end`,O),...P})}var k=v.forwardRef(O);k.displayName=`DecimalInput`;function A({label:e,description:t,hint:n,icon:i,name:a,value:o,defaultValue:s,onChange:c,disabled:l=!1,invalid:u,className:f}){let m=o!==void 0,[h,g]=(0,v.useState)(s??!1),b=m?o??!1:h,x=(0,v.useId)(),S=(0,v.useMemo)(()=>a??x,[a,x]),C=typeof t==`string`&&t.trim()!==``,w=C?`${S}-description`:void 0,T=(0,v.useCallback)(e=>{l||(m||g(e),c?.(e))},[l,m,c]),E=(0,v.useCallback)(e=>{e.target.closest(`[role="switch"]`)||T(!b)},[b,T]);return(0,y.jsxs)(`div`,{"aria-invalid":u||void 0,onClick:E,className:d(`switch-card--component`,`group relative flex items-start gap-3 rounded-lg border bg-card p-4 transition-[background,border-color,box-shadow] duration-150`,`border-border`,b&&`border-primary bg-primary/[0.04]`,`aria-invalid:border-destructive aria-invalid:ring-2 aria-invalid:ring-destructive/20`,!l&&`cursor-pointer hover:border-foreground/20 hover:bg-muted/30`,l&&`cursor-not-allowed opacity-50`,f),children:[!!a&&(0,y.jsx)(`input`,{type:`hidden`,name:a,value:b?`1`:`0`,"aria-hidden":`true`}),!!i&&(0,y.jsx)(`span`,{className:d(`mt-0.5 inline-flex size-9 shrink-0 items-center justify-center rounded-md transition-colors`,b?`bg-primary/10 text-primary`:`bg-muted/50 text-muted-foreground group-hover:bg-muted group-hover:text-foreground`),children:(0,y.jsx)(i,{className:`size-4`})}),(0,y.jsxs)(`div`,{className:`min-w-0 flex-1 space-y-0.5`,children:[(0,y.jsx)(p,{htmlFor:S,className:d(`block font-semibold tracking-tight`,l?`cursor-not-allowed`:`cursor-pointer`),children:e}),!!C&&(0,y.jsx)(r,{type:`secondary`,className:`leading-snug`,children:t}),!!n&&(0,y.jsx)(r,{size:`xs`,type:`discrete`,className:`leading-snug`,children:n})]}),(0,y.jsx)(`div`,{className:`mt-1 flex shrink-0 items-center`,children:(0,y.jsx)(_,{id:S,checked:b,onCheckedChange:e=>T(e),disabled:l,"aria-label":e,"aria-describedby":w})}),!!C&&(0,y.jsx)(`span`,{id:`${S}-description`,className:`sr-only`,children:t})]})}A.displayName=`SwitchCard`;function j({label:e,description:t,kind:n=`switch`,value:i,defaultValue:a,onChange:o,disabled:s=!1,invalid:c=!1,name:l,className:u,controlPosition:f=`trailing`}){let h=i!==void 0,[g,b]=(0,v.useState)(a??!1),x=h?i??!1:g,S=(0,v.useId)(),C=(0,v.useCallback)(e=>{s||(h||b(e),o?.(e))},[s,h,o]),w=e=>{e.target.closest(`[role="switch"], [role="checkbox"], input[type="checkbox"]`)||C(!x)},T=n===`switch`?(0,y.jsx)(_,{id:S,name:l,checked:x,onCheckedChange:e=>C(e),disabled:s,"aria-invalid":c||void 0}):(0,y.jsx)(m,{id:S,name:l,checked:x,onCheckedChange:e=>C(e===!0),disabled:s,"aria-invalid":c||void 0}),E=(0,y.jsxs)(`div`,{className:`min-w-0 flex-1`,children:[(0,y.jsx)(p,{htmlFor:S,className:d(`block leading-snug`,s?`cursor-not-allowed opacity-50`:`cursor-pointer`),children:e}),!!t&&(0,y.jsx)(r,{size:`xs`,type:`secondary`,className:`mt-0.5 leading-snug`,children:t})]});return(0,y.jsxs)(`div`,{role:`group`,onClick:w,className:d(`toggle-field--component`,`flex items-start gap-3 rounded-md py-1`,s&&`pointer-events-none`,u),children:[f===`leading`&&(0,y.jsx)(`div`,{className:`mt-0.5 flex shrink-0`,children:T}),E,f===`trailing`&&(0,y.jsx)(`div`,{className:`mt-0.5 flex shrink-0`,children:T})]})}j.displayName=`ToggleField`;var M={placeholder:`Add a tag…`,emptyRecommendations:`No recommendations found.`,clearAll:`Clear all`,summary:(e,t)=>`${e} / ${t} tags`};function N({value:e=[],onChange:t,placeholder:i,recommendations:o,maxTags:s,showMaxTags:u=!1,allowDuplicates:p=!1,validate:m,disabled:h=!1,showClearAll:_=!1,renderTag:b,delimiter:x=/[\n,]/,addOnBlur:S=!0,minLength:C=1,maxLength:w,emptyMessage:T,sortTags:E=!1,caseSensitive:D=!1,field:O,invalid:k,className:A,strings:j}){let N=l(l(M,i!==void 0||T!==void 0?{placeholder:i,emptyRecommendations:T}:void 0),j),[P,F]=(0,v.useState)(``),[I,L]=(0,v.useState)(!1),[R,z]=(0,v.useState)(-1),B=(0,v.useRef)(null),V=(0,v.useCallback)(e=>{if(typeof e==`string`)return e;if(O&&typeof e==`object`&&e){let t=e[O];return typeof t==`string`?t:t==null?``:String(t)}return String(e)},[O]),H=(0,v.useCallback)(t=>typeof e[0]==`string`||e.length===0?t:O?{[O]:t}:t,[O,e]),U=(0,v.useMemo)(()=>o?o.map(e=>e&&typeof e==`object`&&`value`in e&&`label`in e?e:{value:e,label:V(e)}):[],[o,V]),W=(0,v.useMemo)(()=>{if(!U.length||!P)return U;let t=D?P:P.toLowerCase(),n=new Set(e.map(e=>{let t=V(e);return D?t:t.toLowerCase()}));return U.filter(e=>{let r=D?e.label:e.label.toLowerCase(),i=V(e.value),a=D?i:i.toLowerCase();return(r.includes(t)||a.includes(t))&&(p||!n.has(a))})},[U,P,e,p,D,V]),G=(0,v.useMemo)(()=>E?[...e].sort((e,t)=>{let n=V(e),r=V(t);return n.localeCompare(r)}):e,[e,E,V]),K=(0,v.useCallback)(n=>{let r=typeof n==`string`?H(n):n,i=V(r).trim();if(!i||i.length<C||w&&i.length>w||s&&e.length>=s||!p&&e.some(e=>{let t=V(e);return D?t===i:t.toLowerCase()===i.toLowerCase()})||m&&!m(r))return;let a=[...e,r];t?.(a),F(``),L(!1),z(-1)},[e,t,s,p,m,C,w,D,V,H]),q=(0,v.useCallback)(n=>{let r=e.filter((e,t)=>t!==n);t?.(r)},[e,t]),J=(0,v.useCallback)(e=>{let t=e.target.value;F(t),z(-1),o&&o.length>0&&L(!0)},[o]),Y=(0,v.useCallback)(t=>{h||(t.key===`Enter`?(t.preventDefault(),I&&R>=0&&R<W.length?(K(W[R].value),z(-1)):P.trim()&&K(P)):t.key===`Tab`?P&&(t.preventDefault(),K(P)):t.key===`ArrowDown`?(t.preventDefault(),I&&z(e=>e<W.length-1?e+1:e)):t.key===`ArrowUp`?(t.preventDefault(),I&&z(e=>e>0?e-1:0)):t.key===`Escape`?(L(!1),z(-1)):t.key===`Backspace`&&!P&&e.length>0&&q(e.length-1))},[h,I,R,W,P,K,q,e.length]),X=(0,v.useCallback)(e=>{h||(e.preventDefault(),e.clipboardData.getData(`text`).split(x).map(e=>e.trim()).filter(Boolean).forEach(e=>K(e)))},[h,x,K]),Z=(0,v.useCallback)(()=>{setTimeout(()=>{L(!1),S&&P&&K(P)},200)},[S,P,K]),Q=(0,v.useCallback)(()=>{t?.([]),F(``)},[t]),$=(0,v.useCallback)((e,t,r)=>{let i=`${V(e)}-${t}`;return(0,y.jsxs)(n,{variant:`secondary`,className:d(`tags-input--component`,`gap-1 pr-1 font-normal`),children:[V(e),(0,y.jsx)(`button`,{type:`button`,"aria-label":`Remove ${V(e)}`,className:d(`inline-flex size-icon items-center justify-center rounded-full`,`text-muted-foreground/70 hover:bg-foreground/10 hover:text-foreground`,`outline-none focus-visible:ring-2 focus-visible:ring-ring/50`,`disabled:opacity-50 disabled:pointer-events-none`),onClick:()=>r(t),disabled:h,children:(0,y.jsx)(c,{className:`size-icon-sm`,"aria-hidden":`true`})})]},i)},[V,h]),ee=!!k;return(0,y.jsxs)(`div`,{className:d(`w-full relative`,A),children:[(0,y.jsxs)(`div`,{className:`relative`,children:[(0,y.jsx)(g,{ref:B,type:`text`,placeholder:N.placeholder,value:P,onChange:J,onKeyDown:Y,onPaste:X,onBlur:Z,onFocus:()=>{o&&W.length>0&&L(!0)},disabled:h||s!==void 0&&e.length>=s,invalid:ee,maxLength:w,className:`w-full`}),!!o&&!!I&&(0,y.jsx)(`div`,{className:`absolute top-full left-0 right-0 z-50 mt-1 max-h-[200px] overflow-y-auto rounded-md bg-popover p-1 text-sm text-popover-foreground shadow-md ring-1 ring-foreground/10`,children:W.length>0?W.map((t,n)=>{let r=V(t.value),i=e.some(e=>V(e)===V(t.value));return(0,y.jsxs)(`button`,{type:`button`,onMouseDown:e=>{e.preventDefault(),K(t.value),z(-1),B.current?.focus()},onMouseEnter:()=>z(n),className:d(`relative flex w-full cursor-pointer items-center justify-between gap-space-sm rounded-md px-control-sm py-row-y text-xs`,`hover:bg-accent hover:text-accent-foreground`,`focus-visible:outline-none`,R===n&&`bg-accent text-accent-foreground`),children:[(0,y.jsx)(`span`,{children:t.label}),(0,y.jsx)(a,{className:d(`ml-auto size-icon-sm`,i?`opacity-100`:`opacity-0`)})]},r)}):(0,y.jsx)(r,{tag:`div`,size:`xs`,type:`secondary`,className:`px-2 py-row-y`,children:N.emptyRecommendations})})]}),G.length>0&&(0,y.jsxs)(`div`,{className:`mt-space-md flex flex-wrap items-center gap-space-sm`,children:[G.map((e,t)=>b?b(e,t,q):$(e,t,q)),!!_&&e.length>0&&!h&&(0,y.jsx)(f,{type:`button`,size:`small`,onClick:Q,className:`ml-auto`,children:N.clearAll})]}),!!s&&!!u&&(0,y.jsx)(r,{size:`xs`,type:`secondary`,className:`mt-1`,children:N.summary(e.length,s)})]})}N.displayName=`TagsInput`;export{k as i,j as n,A as r,N as t};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{r as e}from"./chunk-QTnfLwEv.js";import{t}from"./react-sKtkuLrH.js";import{x as n}from"./section-
|
|
1
|
+
import{r as e}from"./chunk-QTnfLwEv.js";import{t}from"./react-sKtkuLrH.js";import{x as n}from"./section-BPNIPavy.js";import{$n as r}from"./example-CJMJcnb4.js";import{d as i,n as a}from"./index-jD-KSiHu.js";var o=e(t(),1),s=i(),c={small:`small`,default:`default`},l={small:`small`,default:`default`},u={small:`text-xs h-auto px-0`,default:`text-sm h-auto px-0`},d=o.forwardRef(({className:e,type:t=`button`,size:i,disabled:o,...d},f)=>{let{defaultControlSize:p}=n(),m=i??l[p??`default`]??`default`;return(0,s.jsx)(r,{ref:f,type:t,variant:`primary`,buttonStyle:`ghost`,size:c[m],disabled:o,className:a(`text-button--component`,`inline-flex items-center justify-center underline decoration-neutral-300 underline-offset-4 transition-colors duration-300 ease-out hover:decoration-current`,`text-primary focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2`,`disabled:pointer-events-none disabled:opacity-50`,u[m],e),...d})});d.displayName=`TextButton`;export{d as t};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{d as e,n as t}from"./index-
|
|
1
|
+
import{d as e,n as t}from"./index-jD-KSiHu.js";var n=e(),r={inherit:`text-inherit`,sm:`text-sm`,xs:`text-xs`,base:`text-base`,lg:`text-lg`,xl:`text-xl`},i={main:`text-foreground`,inverse:`text-background`,secondary:`text-muted-foreground`,discrete:`text-muted-foreground`,error:`text-destructive`,success:`text-success`,primary:`text-primary`},a={normal:`leading-normal`,relaxed:`leading-relaxed`,loose:`leading-loose`,tight:`leading-tight`,snug:`leading-snug`,none:`leading-none`},o={regular:`font-normal`,medium:`font-medium`,semibold:`font-semibold`,bold:`font-bold`},s={center:`text-center`,right:`text-right`,left:`text-left`};function c({type:e=`main`,size:c=`sm`,align:l=`left`,lineHeight:u=`normal`,weight:d=`regular`,className:f=``,underline:p=!0,children:m,...h}){return(0,n.jsx)(`a`,{className:t(i[e],r[c],s[l],a[u],o[d],p&&`underline decoration-neutral-300 underline-offset-4 transition-colors duration-300 ease-out hover:decoration-current! dark:decoration-neutral-500`,f),"data-typography":`link`,...h,children:m})}c.displayName=`TextLink`;export{c as t};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import"./chunk-QTnfLwEv.js";import{t as e}from"./react-sKtkuLrH.js";import{d as t,n}from"./index-
|
|
1
|
+
import"./chunk-QTnfLwEv.js";import{t as e}from"./react-sKtkuLrH.js";import{d as t,n}from"./index-jD-KSiHu.js";e();var r=t();function i({className:e,...t}){return(0,r.jsx)(`textarea`,{"data-slot":`textarea`,className:n(`border-input focus-visible:border-ring focus-visible:ring-ring/50 aria-invalid:ring-destructive/20 aria-invalid:border-destructive rounded-md border bg-transparent px-2.5 py-2 text-base shadow-xs transition-[color,box-shadow] focus-visible:ring-[3px] aria-invalid:ring-[3px] md:text-sm placeholder:text-muted-foreground flex field-sizing-content min-h-16 w-full outline-none disabled:cursor-not-allowed disabled:opacity-50`,e),...t})}export{i as t};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{r as e}from"./chunk-QTnfLwEv.js";import{t}from"./react-sKtkuLrH.js";import{p as n,x as r}from"./section-
|
|
1
|
+
import{r as e}from"./chunk-QTnfLwEv.js";import{t}from"./react-sKtkuLrH.js";import{p as n,x as r}from"./section-BPNIPavy.js";import{Er as i}from"./example-CJMJcnb4.js";import{t as a}from"./circle-x-MO44aKHe.js";import{N as o,d as s,n as c}from"./index-jD-KSiHu.js";import{t as l}from"./use-form-field-state-CGGJFfWu.js";import{d as u,f as d}from"./form-sizing-C3UG5WKC.js";var f=e(t(),1),p=s(),m={clear:`Clear textarea`},h=f.forwardRef(({className:e,maxLength:t,showCharacterCount:s,clearable:h,onClear:g,isLoading:_,invalid:v,size:y,autoResize:b=!1,minRows:x=2,maxRows:S,onChange:C,value:w,defaultValue:T,id:E,strings:D,...O},k)=>{let A=(0,f.useRef)(null),j=o(m,D),{defaultControlSize:M}=r(),N=d(y,M),{id:P,value:F,isReactHookForm:I,characterCount:L,hasCharacterLimit:R,showCount:z,hasValue:B,updateValue:V,clearValue:H,wouldExceedLimit:U}=l({controlledValue:w,defaultValue:T,maxLength:t,showCharacterCount:s,providedId:E,idPrefix:`textarea`,hasOnChange:C!==void 0}),W=!!v,G=(0,f.useRef)(0),K=(0,f.useCallback)(()=>{if(!b||!A.current)return;let e=A.current;G.current===0&&(G.current=parseInt(getComputedStyle(e).lineHeight)||20),e.style.height=`auto`;let t=G.current,n=t*x,r=S?t*S:1/0,i=Math.min(Math.max(e.scrollHeight,n),r);e.style.height=`${i}px`},[b,S,x]);(0,f.useEffect)(()=>{K()},[F,b,K]);let q=(0,f.useCallback)(e=>{let t=e.target.value;U(t)||(V(t),C?.(e),b&&setTimeout(K,0))},[C,V,U,b,K]),J=(0,f.useCallback)(()=>{H(),C?.({target:{value:``},currentTarget:{value:``}}),g?.(),A.current?.focus(),b&&setTimeout(K,0)},[H,C,g,b,K]),Y=h&&B&&!_;return(0,p.jsxs)(`div`,{className:c(`textarea--component`,`relative w-full`),children:[(0,p.jsx)(`textarea`,{ref:e=>{typeof k==`function`?k(e):k&&(k.current=e),A.current=e},id:P,...!I&&{value:F},onChange:q,maxLength:t,"aria-invalid":W||void 0,disabled:O.disabled||_,rows:x,style:{resize:b?`none`:O.style?.resize,overflow:b&&S?`auto`:`visible`,...O.style},className:c(`placeholder:text-muted-foreground selection:bg-primary selection:text-primary-foreground`,`border-input flex w-full rounded-radius border bg-transparent px-control py-control-y-offset`,`transition-[color,box-shadow] outline-none`,`disabled:pointer-events-none disabled:cursor-not-allowed disabled:opacity-50`,u[N],`focus-visible:border-ring focus-visible:ring-ring/50 focus-visible:ring-[3px]`,`aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 aria-invalid:border-destructive`,Y&&`pr-control-addon`,z&&`pr-control-count`,e),...O}),!!z&&(0,p.jsx)(`div`,{className:c(`pointer-events-none absolute top-control-y-offset right-control-px text-xs tabular-nums`,O.disabled&&`opacity-50`,W?`text-destructive`:`text-muted-foreground`),"aria-live":`polite`,role:`status`,children:(0,p.jsxs)(n,{tag:`span`,size:`xs`,type:W?`error`:`secondary`,children:[L,R?`/${t}`:``]})}),!!_&&!z&&(0,p.jsx)(`div`,{className:c(`pointer-events-none absolute top-control-y-offset right-control-px`,W?`text-destructive`:`text-muted-foreground/80`),children:(0,p.jsx)(i,{className:`size-icon animate-spin`,"aria-hidden":`true`})}),!!Y&&!z&&(0,p.jsx)(`button`,{type:`button`,className:`text-muted-foreground/80 hover:text-foreground focus-visible:border-ring focus-visible:ring-ring/50 absolute top-control-y-offset right-control-px flex size-control-clear-icon items-center justify-center rounded transition-[color,box-shadow] outline-none focus-visible:z-10 focus-visible:ring-[3px] disabled:pointer-events-none disabled:cursor-not-allowed disabled:opacity-50`,"aria-label":j.clear,onClick:J,disabled:_,children:(0,p.jsx)(a,{className:`size-icon`,"aria-hidden":`true`})})]})});h.displayName=`Textarea`;export{h as t};
|