@chassis-ui/react 0.5.1 → 0.6.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +4 -3
- package/dist/accordion.js +1 -1
- package/dist/alert.js +1 -1
- package/dist/autocomplete.d.ts +1 -1
- package/dist/autocomplete.js +1 -1
- package/dist/avatar.js +1 -1
- package/dist/badge.js +1 -1
- package/dist/breadcrumb.js +1 -1
- package/dist/button-group.js +1 -1
- package/dist/button.js +1 -1
- package/dist/calendar.js +1 -1
- package/dist/card.js +1 -1
- package/dist/carousel.js +1 -1
- package/dist/checkbox.d.ts +1 -1
- package/dist/checkbox.js +1 -1
- package/dist/chip-input.js +1 -1
- package/dist/chip.js +1 -1
- package/dist/chunks/Button-Cjenm3ku.js +2 -0
- package/dist/chunks/Button-Cjenm3ku.js.map +1 -0
- package/dist/chunks/{Chip-C7QlFCvx.js → Chip-CXuYhjc3.js} +2 -2
- package/dist/chunks/{Chip-C7QlFCvx.js.map → Chip-CXuYhjc3.js.map} +1 -1
- package/dist/chunks/CloseButton-CAQ--0sB.js +2 -0
- package/dist/chunks/CloseButton-CAQ--0sB.js.map +1 -0
- package/dist/chunks/{DateField-4cdcwt0v.js → DateField-G1TP9ayt.js} +2 -2
- package/dist/chunks/{DateField-4cdcwt0v.js.map → DateField-G1TP9ayt.js.map} +1 -1
- package/dist/chunks/{FormHelp-B1eSoack.js → FormHelp-2U3P8C6b.js} +2 -2
- package/dist/chunks/{FormHelp-B1eSoack.js.map → FormHelp-2U3P8C6b.js.map} +1 -1
- package/dist/chunks/Link-B3SX50Od.js +2 -0
- package/dist/chunks/Link-B3SX50Od.js.map +1 -0
- package/dist/chunks/Menu-DBN4Mxak.js +2 -0
- package/dist/chunks/Menu-DBN4Mxak.js.map +1 -0
- package/dist/chunks/MenuToggle-DHzKm1Ed.js +2 -0
- package/dist/chunks/MenuToggle-DHzKm1Ed.js.map +1 -0
- package/dist/chunks/{RangeCalendar-mM3OeTlU.js → RangeCalendar-DRcg1Hp3.js} +2 -2
- package/dist/chunks/{RangeCalendar-mM3OeTlU.js.map → RangeCalendar-DRcg1Hp3.js.map} +1 -1
- package/dist/chunks/{VisuallyHidden-CGv-mBuQ.js → VisuallyHidden-24WfUCsJ.js} +2 -2
- package/dist/chunks/{VisuallyHidden-CGv-mBuQ.js.map → VisuallyHidden-24WfUCsJ.js.map} +1 -1
- package/dist/chunks/{accordion-BZlX2uk8.js → accordion-DiYPbV_r.js} +2 -2
- package/dist/chunks/{accordion-BZlX2uk8.js.map → accordion-DiYPbV_r.js.map} +1 -1
- package/dist/chunks/alert-oSKrhxkI.js +2 -0
- package/dist/chunks/{alert-DSLg5MBb.js.map → alert-oSKrhxkI.js.map} +1 -1
- package/dist/chunks/autocomplete-wjDWeWDh.js +2 -0
- package/dist/chunks/autocomplete-wjDWeWDh.js.map +1 -0
- package/dist/chunks/{avatar-BQBbcnk6.js → avatar-CvcvC9KA.js} +2 -2
- package/dist/chunks/{avatar-BQBbcnk6.js.map → avatar-CvcvC9KA.js.map} +1 -1
- package/dist/chunks/{badge-Ths1Qn1a.js → badge-D7XgWBXc.js} +2 -2
- package/dist/chunks/{badge-Ths1Qn1a.js.map → badge-D7XgWBXc.js.map} +1 -1
- package/dist/chunks/{breadcrumb-BTiQikk-.js → breadcrumb-DxCHVppV.js} +2 -2
- package/dist/chunks/{breadcrumb-BTiQikk-.js.map → breadcrumb-DxCHVppV.js.map} +1 -1
- package/dist/chunks/{button-group-CefkGeYL.js → button-group-CXMj0D4r.js} +2 -2
- package/dist/chunks/{button-group-CefkGeYL.js.map → button-group-CXMj0D4r.js.map} +1 -1
- package/dist/chunks/{card-CEQgHIaL.js → card-C6lPZs5J.js} +2 -2
- package/dist/chunks/{card-CEQgHIaL.js.map → card-C6lPZs5J.js.map} +1 -1
- package/dist/chunks/carousel-Ka9OA-HJ.js +2 -0
- package/dist/chunks/carousel-Ka9OA-HJ.js.map +1 -0
- package/dist/chunks/checkbox-5jv0YWoi.js +2 -0
- package/dist/chunks/checkbox-5jv0YWoi.js.map +1 -0
- package/dist/chunks/chip-input-D8EaNujM.js +2 -0
- package/dist/chunks/chip-input-D8EaNujM.js.map +1 -0
- package/dist/chunks/{collapse-CBi3RWTf.js → collapse-Bc7fnmyU.js} +2 -2
- package/dist/chunks/{collapse-CBi3RWTf.js.map → collapse-Bc7fnmyU.js.map} +1 -1
- package/dist/chunks/color-input-DBOd4Jba.js +2 -0
- package/dist/chunks/color-input-DBOd4Jba.js.map +1 -0
- package/dist/chunks/combobox-DByuUtwh.js +2 -0
- package/dist/chunks/{combobox-DNqR4d3V.js.map → combobox-DByuUtwh.js.map} +1 -1
- package/dist/chunks/context-HDVxTNPi.js.map +1 -1
- package/dist/chunks/context-menu-CGOGliw6.js +2 -0
- package/dist/chunks/context-menu-CGOGliw6.js.map +1 -0
- package/dist/chunks/datagrid-Dv_9uFef.js +2 -0
- package/dist/chunks/datagrid-Dv_9uFef.js.map +1 -0
- package/dist/chunks/datepicker-DuYmXiSe.js +2 -0
- package/dist/chunks/datepicker-DuYmXiSe.js.map +1 -0
- package/dist/chunks/dialogTitle-DMBvXZLT.js +2 -0
- package/dist/chunks/dialogTitle-DMBvXZLT.js.map +1 -0
- package/dist/chunks/{divider-C1-NoKMV.js → divider-DbWmMSrn.js} +2 -2
- package/dist/chunks/{divider-C1-NoKMV.js.map → divider-DbWmMSrn.js.map} +1 -1
- package/dist/chunks/drawer-DPxF30qn.js +2 -0
- package/dist/chunks/drawer-DPxF30qn.js.map +1 -0
- package/dist/chunks/file-input-B5YaBXjI.js +2 -0
- package/dist/chunks/file-input-B5YaBXjI.js.map +1 -0
- package/dist/chunks/{flex-C2jV5LyV.js → flex-C6CbAkVJ.js} +2 -2
- package/dist/chunks/{flex-C2jV5LyV.js.map → flex-C6CbAkVJ.js.map} +1 -1
- package/dist/chunks/floating-input-B9YAJ9d4.js +2 -0
- package/dist/chunks/floating-input-B9YAJ9d4.js.map +1 -0
- package/dist/chunks/{form-field-Bcx96ezd.js → form-field-D74QY_wP.js} +2 -2
- package/dist/chunks/{form-field-Bcx96ezd.js.map → form-field-D74QY_wP.js.map} +1 -1
- package/dist/chunks/grid-BCVkow3u.js +2 -0
- package/dist/chunks/grid-BCVkow3u.js.map +1 -0
- package/dist/chunks/{index-5qsV1-cc.d.ts → index--DV9l24Q.d.ts} +18 -14
- package/dist/chunks/{index-BAvt_oPe.d.ts → index-B2d_pjjy.d.ts} +6 -5
- package/dist/chunks/{index-CbcFEGCh.d.ts → index-BIWaMOr6.d.ts} +9 -2
- package/dist/chunks/{index-3JVLrDHv.d.ts → index-BMAdUGiM.d.ts} +7 -1
- package/dist/chunks/{index-Cpifcw5a.d.ts → index-BzYAMLX1.d.ts} +44 -4
- package/dist/chunks/{index-BbZzaApz.d.ts → index-C9RqZNjk.d.ts} +7 -1
- package/dist/chunks/{index-D0Dhs7YI.d.ts → index-CHtvpvUh.d.ts} +6 -1
- package/dist/chunks/{index-Bl-_sC4y.d.ts → index-CSmHNy8M.d.ts} +8 -2
- package/dist/chunks/{index-Davd7Cue.d.ts → index-CXzKYWtS.d.ts} +3 -2
- package/dist/chunks/{index-OnB4_h6x.d.ts → index-DV_JBDoF.d.ts} +2 -2
- package/dist/chunks/{index-Es9I0fIS.d.ts → index-DjmN2hBX.d.ts} +2 -2
- package/dist/chunks/{index-UjmJQRaG.d.ts → index-DyB9XXLJ.d.ts} +3 -3
- package/dist/chunks/{index-CSRGr7pU.d.ts → index-JCnEw-55.d.ts} +2 -6
- package/dist/chunks/{index-Ctf5hLue.d.ts → index-Me921MYl.d.ts} +15 -13
- package/dist/chunks/{index-C-IrFdKe.d.ts → index-OgWCTy2Y.d.ts} +2 -2
- package/dist/chunks/{index-BZpHSGlk.d.ts → index-bZRQGwY7.d.ts} +7 -2
- package/dist/chunks/{index-Cm3rPbI1.d.ts → index-qJGkO-ni.d.ts} +3 -3
- package/dist/chunks/{input-adorn-DV9tuWXh.js → input-adorn-D0E3Afdf.js} +2 -2
- package/dist/chunks/{input-adorn-DV9tuWXh.js.map → input-adorn-D0E3Afdf.js.map} +1 -1
- package/dist/chunks/{input-group-YB_zoKud.js → input-group-paIBtI1R.js} +2 -2
- package/dist/chunks/{input-group-YB_zoKud.js.map → input-group-paIBtI1R.js.map} +1 -1
- package/dist/chunks/{list-BPBZR66Y.js → list-Ch6vxaUs.js} +2 -2
- package/dist/chunks/{list-BPBZR66Y.js.map → list-Ch6vxaUs.js.map} +1 -1
- package/dist/chunks/menu-DTe27h5q.js +2 -0
- package/dist/chunks/{menu-Bqlhottl.js.map → menu-DTe27h5q.js.map} +1 -1
- package/dist/chunks/modal-BDQe7xyy.js +2 -0
- package/dist/chunks/modal-BDQe7xyy.js.map +1 -0
- package/dist/chunks/nativeFormReset-DgsRU9SA.js +2 -0
- package/dist/chunks/nativeFormReset-DgsRU9SA.js.map +1 -0
- package/dist/chunks/nav-DDI8Dv28.js +2 -0
- package/dist/chunks/nav-DDI8Dv28.js.map +1 -0
- package/dist/chunks/{nav-overflow-GWARvoQZ.js → nav-overflow-BxAhoMh3.js} +2 -2
- package/dist/chunks/{nav-overflow-GWARvoQZ.js.map → nav-overflow-BxAhoMh3.js.map} +1 -1
- package/dist/chunks/{navOverflow-C_QJmkPM.js → navOverflow-eSROB_mV.js} +2 -2
- package/dist/chunks/{navOverflow-C_QJmkPM.js.map → navOverflow-eSROB_mV.js.map} +1 -1
- package/dist/chunks/{navVariant-D4wiKS8I.js → navVariant-Bm5k8CY3.js} +2 -2
- package/dist/chunks/{navVariant-D4wiKS8I.js.map → navVariant-Bm5k8CY3.js.map} +1 -1
- package/dist/chunks/{navbar-C7dO0YRs.js → navbar-BYMKe2yW.js} +2 -2
- package/dist/chunks/{navbar-C7dO0YRs.js.map → navbar-BYMKe2yW.js.map} +1 -1
- package/dist/chunks/{notification-oIrUtDhl.js → notification-C1Sd4X7M.js} +2 -2
- package/dist/chunks/{notification-oIrUtDhl.js.map → notification-C1Sd4X7M.js.map} +1 -1
- package/dist/chunks/{number-field-ChPTSBwI.js → number-field-BIApgIlR.js} +2 -2
- package/dist/chunks/{number-field-ChPTSBwI.js.map → number-field-BIApgIlR.js.map} +1 -1
- package/dist/chunks/otp-input-CCkfFZID.js +2 -0
- package/dist/chunks/otp-input-CCkfFZID.js.map +1 -0
- package/dist/chunks/overlayPlacement-D2vfhhg3.js +2 -0
- package/dist/chunks/overlayPlacement-D2vfhhg3.js.map +1 -0
- package/dist/chunks/{pagination-Dvz8lccd.js → pagination-WINUPT_P.js} +2 -2
- package/dist/chunks/pagination-WINUPT_P.js.map +1 -0
- package/dist/chunks/placeholder-9rTlnMso.js +2 -0
- package/dist/chunks/{placeholder-SPoVRkKE.js.map → placeholder-9rTlnMso.js.map} +1 -1
- package/dist/chunks/polymorphic-mAKwlLiW.js +2 -0
- package/dist/chunks/{polymorphic-CZIFszAy.js.map → polymorphic-mAKwlLiW.js.map} +1 -1
- package/dist/chunks/popover-CrAJTevL.js +2 -0
- package/dist/chunks/popover-CrAJTevL.js.map +1 -0
- package/dist/chunks/{progress-CiSJDNwx.js → progress-CAqSu3jc.js} +2 -2
- package/dist/chunks/{progress-CiSJDNwx.js.map → progress-CAqSu3jc.js.map} +1 -1
- package/dist/chunks/{radio-C42F_5OD.js → radio-XlINMnQm.js} +2 -2
- package/dist/chunks/{radio-C42F_5OD.js.map → radio-XlINMnQm.js.map} +1 -1
- package/dist/chunks/range-input-tyImJHKI.js +2 -0
- package/dist/chunks/range-input-tyImJHKI.js.map +1 -0
- package/dist/chunks/{renderFormField-_6WswnEX.js → renderFormField-CaZ8-xrn.js} +2 -2
- package/dist/chunks/{renderFormField-_6WswnEX.js.map → renderFormField-CaZ8-xrn.js.map} +1 -1
- package/dist/chunks/{search-field-OFsb3t4L.js → search-field-CIYtMraB.js} +2 -2
- package/dist/chunks/{search-field-OFsb3t4L.js.map → search-field-CIYtMraB.js.map} +1 -1
- package/dist/chunks/select-CkucgA6H.js +2 -0
- package/dist/chunks/select-CkucgA6H.js.map +1 -0
- package/dist/chunks/{skeleton-B2blJGWj.js → skeleton-CXFwCjB9.js} +2 -2
- package/dist/chunks/{skeleton-B2blJGWj.js.map → skeleton-CXFwCjB9.js.map} +1 -1
- package/dist/chunks/slot-DagH0Gxq.js +2 -0
- package/dist/chunks/slot-DagH0Gxq.js.map +1 -0
- package/dist/chunks/{spinner-D8lQCW4u.js → spinner-BLQiCoQd.js} +2 -2
- package/dist/chunks/{spinner-D8lQCW4u.js.map → spinner-BLQiCoQd.js.map} +1 -1
- package/dist/chunks/{stack-DtzW54UK.js → stack-OItr30SC.js} +2 -2
- package/dist/chunks/{stack-DtzW54UK.js.map → stack-OItr30SC.js.map} +1 -1
- package/dist/chunks/{stepper-tSA84huJ.js → stepper-BLjW7UnC.js} +2 -2
- package/dist/chunks/{stepper-tSA84huJ.js.map → stepper-BLjW7UnC.js.map} +1 -1
- package/dist/chunks/switch-nt7aXQDX.js +2 -0
- package/dist/chunks/switch-nt7aXQDX.js.map +1 -0
- package/dist/chunks/table-KtPHx4FG.js +2 -0
- package/dist/chunks/table-KtPHx4FG.js.map +1 -0
- package/dist/chunks/{tabs-DMFSLjnV.js → tabs-Dh5kH5Ik.js} +2 -2
- package/dist/chunks/{tabs-DMFSLjnV.js.map → tabs-Dh5kH5Ik.js.map} +1 -1
- package/dist/chunks/{text-input-CR73x-8D.js → text-input-D3jBYiLn.js} +2 -2
- package/dist/chunks/{text-input-CR73x-8D.js.map → text-input-D3jBYiLn.js.map} +1 -1
- package/dist/chunks/{textarea-C-1cMyH4.js → textarea-2BJCzT97.js} +2 -2
- package/dist/chunks/{textarea-C-1cMyH4.js.map → textarea-2BJCzT97.js.map} +1 -1
- package/dist/chunks/{time-field-CbCfOQZz.js → time-field-ClPbatW3.js} +2 -2
- package/dist/chunks/{time-field-CbCfOQZz.js.map → time-field-ClPbatW3.js.map} +1 -1
- package/dist/chunks/toast-D5-58Ch1.js +2 -0
- package/dist/chunks/toast-D5-58Ch1.js.map +1 -0
- package/dist/chunks/tooltip-TGFFlOJL.js +2 -0
- package/dist/chunks/tooltip-TGFFlOJL.js.map +1 -0
- package/dist/chunks/tree-BO0WSxQa.js +2 -0
- package/dist/chunks/tree-BO0WSxQa.js.map +1 -0
- package/dist/chunks/useButtonSemantics-DN3OIXtG.js +2 -0
- package/dist/chunks/useButtonSemantics-DN3OIXtG.js.map +1 -0
- package/dist/chunks/{useDialogElement-BfygWBPZ.js → useDialogElement-yEgUSejP.js} +2 -2
- package/dist/chunks/useDialogElement-yEgUSejP.js.map +1 -0
- package/dist/chunks/{useFormField-DH2tlc3e.js → useFormField-q21MOgh8.js} +2 -2
- package/dist/chunks/{useFormField-DH2tlc3e.js.map → useFormField-q21MOgh8.js.map} +1 -1
- package/dist/chunks/useFormReset-BK5Yb24_.js +2 -0
- package/dist/chunks/useFormReset-BK5Yb24_.js.map +1 -0
- package/dist/chunks/useHeldBack-o-CsPcSe.js +2 -0
- package/dist/chunks/useHeldBack-o-CsPcSe.js.map +1 -0
- package/dist/chunks/{useOpenStateProps-BhjSQ3f6.js → useOpenStateProps-CdSO1nmI.js} +2 -2
- package/dist/chunks/{useOpenStateProps-BhjSQ3f6.js.map → useOpenStateProps-CdSO1nmI.js.map} +1 -1
- package/dist/chunks/useOverlayMaxHeight-5UnurH0W.js +2 -0
- package/dist/chunks/useOverlayMaxHeight-5UnurH0W.js.map +1 -0
- package/dist/chunks/{useRequiredValueInput-gYN8I-LY.js → useRequiredValueInput-CL7AIgqz.js} +2 -2
- package/dist/chunks/{useRequiredValueInput-gYN8I-LY.js.map → useRequiredValueInput-CL7AIgqz.js.map} +1 -1
- package/dist/chunks/useSelectionForMode-B_oTWvEy.js +2 -0
- package/dist/chunks/useSelectionForMode-B_oTWvEy.js.map +1 -0
- package/dist/chunks/useToastRegionQueue-QHa4v7k6.js +2 -0
- package/dist/chunks/useToastRegionQueue-QHa4v7k6.js.map +1 -0
- package/dist/chunks/useTransitionState-WEw9C0yn.js +2 -0
- package/dist/chunks/useTransitionState-WEw9C0yn.js.map +1 -0
- package/dist/chunks/{visibleState-CWyQak65.js → visibleState-DVyxSMUT.js} +2 -2
- package/dist/chunks/{visibleState-CWyQak65.js.map → visibleState-DVyxSMUT.js.map} +1 -1
- package/dist/close-button.js +1 -1
- package/dist/collapse.js +1 -1
- package/dist/color-input.d.ts +1 -1
- package/dist/color-input.js +1 -1
- package/dist/combobox.js +1 -1
- package/dist/context-menu.js +1 -1
- package/dist/datagrid.d.ts +1 -1
- package/dist/datagrid.js +1 -1
- package/dist/datepicker.js +1 -1
- package/dist/divider.js +1 -1
- package/dist/drawer.d.ts +1 -1
- package/dist/drawer.js +1 -1
- package/dist/file-input.d.ts +1 -1
- package/dist/file-input.js +1 -1
- package/dist/flex.js +1 -1
- package/dist/floating-input.d.ts +1 -1
- package/dist/floating-input.js +1 -1
- package/dist/form-field.js +1 -1
- package/dist/form.js +1 -1
- package/dist/grid.js +1 -1
- package/dist/index.d.ts +19 -19
- package/dist/index.js +1 -1
- package/dist/input-adorn.js +1 -1
- package/dist/input-group.js +1 -1
- package/dist/link.js +1 -1
- package/dist/list.js +1 -1
- package/dist/menu.js +1 -1
- package/dist/modal.d.ts +1 -1
- package/dist/modal.js +1 -1
- package/dist/nav-overflow.js +1 -1
- package/dist/nav.d.ts +1 -1
- package/dist/nav.js +1 -1
- package/dist/navbar.js +1 -1
- package/dist/notification.js +1 -1
- package/dist/number-field.js +1 -1
- package/dist/otp-input.d.ts +1 -1
- package/dist/otp-input.js +1 -1
- package/dist/pagination.d.ts +1 -1
- package/dist/pagination.js +1 -1
- package/dist/placeholder.js +1 -1
- package/dist/popover.js +1 -1
- package/dist/progress.js +1 -1
- package/dist/radio.d.ts +1 -1
- package/dist/radio.js +1 -1
- package/dist/range-input.d.ts +1 -1
- package/dist/range-input.js +1 -1
- package/dist/search-field.js +1 -1
- package/dist/select.d.ts +1 -1
- package/dist/select.js +1 -1
- package/dist/skeleton.js +1 -1
- package/dist/spinner.js +1 -1
- package/dist/stack.js +1 -1
- package/dist/stepper.js +1 -1
- package/dist/style.css +1 -1
- package/dist/switch.d.ts +1 -1
- package/dist/switch.js +1 -1
- package/dist/table.d.ts +1 -1
- package/dist/table.js +1 -1
- package/dist/tabs.js +1 -1
- package/dist/text-input.js +1 -1
- package/dist/textarea.js +1 -1
- package/dist/time-field.js +1 -1
- package/dist/toast.d.ts +1 -1
- package/dist/toast.js +1 -1
- package/dist/tooltip.js +1 -1
- package/dist/tree.js +1 -1
- package/dist/visually-hidden.js +1 -1
- package/package.json +11 -11
- package/dist/chunks/Button-ZU-x1uN_.js +0 -2
- package/dist/chunks/Button-ZU-x1uN_.js.map +0 -1
- package/dist/chunks/CloseButton-BPUI5iGX.js +0 -2
- package/dist/chunks/CloseButton-BPUI5iGX.js.map +0 -1
- package/dist/chunks/Link-DE8NSAXJ.js +0 -2
- package/dist/chunks/Link-DE8NSAXJ.js.map +0 -1
- package/dist/chunks/Menu-BiE9CzNk.js +0 -2
- package/dist/chunks/Menu-BiE9CzNk.js.map +0 -1
- package/dist/chunks/MenuToggle-W-ZSHFwF.js +0 -2
- package/dist/chunks/MenuToggle-W-ZSHFwF.js.map +0 -1
- package/dist/chunks/alert-DSLg5MBb.js +0 -2
- package/dist/chunks/autocomplete-Btcsjrh3.js +0 -2
- package/dist/chunks/autocomplete-Btcsjrh3.js.map +0 -1
- package/dist/chunks/carousel-DC-UGc6W.js +0 -2
- package/dist/chunks/carousel-DC-UGc6W.js.map +0 -1
- package/dist/chunks/checkbox-ko6CdtoT.js +0 -2
- package/dist/chunks/checkbox-ko6CdtoT.js.map +0 -1
- package/dist/chunks/chip-input-CugY8EOc.js +0 -2
- package/dist/chunks/chip-input-CugY8EOc.js.map +0 -1
- package/dist/chunks/color-input-C4zMWlvm.js +0 -2
- package/dist/chunks/color-input-C4zMWlvm.js.map +0 -1
- package/dist/chunks/combobox-DNqR4d3V.js +0 -2
- package/dist/chunks/context-menu-D3DNFN-P.js +0 -2
- package/dist/chunks/context-menu-D3DNFN-P.js.map +0 -1
- package/dist/chunks/datagrid-n9vFeXN1.js +0 -2
- package/dist/chunks/datagrid-n9vFeXN1.js.map +0 -1
- package/dist/chunks/datepicker-DqztYJD6.js +0 -2
- package/dist/chunks/datepicker-DqztYJD6.js.map +0 -1
- package/dist/chunks/drawer-CRv9jmbp.js +0 -2
- package/dist/chunks/drawer-CRv9jmbp.js.map +0 -1
- package/dist/chunks/file-input-D_Gl1h-T.js +0 -2
- package/dist/chunks/file-input-D_Gl1h-T.js.map +0 -1
- package/dist/chunks/floating-input-D4gWFfOU.js +0 -2
- package/dist/chunks/floating-input-D4gWFfOU.js.map +0 -1
- package/dist/chunks/grid-CkdPftit.js +0 -2
- package/dist/chunks/grid-CkdPftit.js.map +0 -1
- package/dist/chunks/menu-Bqlhottl.js +0 -2
- package/dist/chunks/modal-CHvsDTyl.js +0 -2
- package/dist/chunks/modal-CHvsDTyl.js.map +0 -1
- package/dist/chunks/nav-B4U_Hqs7.js +0 -2
- package/dist/chunks/nav-B4U_Hqs7.js.map +0 -1
- package/dist/chunks/otp-input-DUtCMg8P.js +0 -2
- package/dist/chunks/otp-input-DUtCMg8P.js.map +0 -1
- package/dist/chunks/overlayPlacement-Q6bcbXA5.js +0 -2
- package/dist/chunks/overlayPlacement-Q6bcbXA5.js.map +0 -1
- package/dist/chunks/pagination-Dvz8lccd.js.map +0 -1
- package/dist/chunks/placeholder-SPoVRkKE.js +0 -2
- package/dist/chunks/polymorphic-CZIFszAy.js +0 -2
- package/dist/chunks/popover-C_32yD9W.js +0 -2
- package/dist/chunks/popover-C_32yD9W.js.map +0 -1
- package/dist/chunks/range-input-DeZq_9S7.js +0 -2
- package/dist/chunks/range-input-DeZq_9S7.js.map +0 -1
- package/dist/chunks/select-DwyL6aqY.js +0 -2
- package/dist/chunks/select-DwyL6aqY.js.map +0 -1
- package/dist/chunks/slot-BQVx1Eew.js +0 -2
- package/dist/chunks/slot-BQVx1Eew.js.map +0 -1
- package/dist/chunks/switch-cp3IZg3L.js +0 -2
- package/dist/chunks/switch-cp3IZg3L.js.map +0 -1
- package/dist/chunks/table-CBTg5Yuq.js +0 -2
- package/dist/chunks/table-CBTg5Yuq.js.map +0 -1
- package/dist/chunks/toast-Dd0J2e1z.js +0 -2
- package/dist/chunks/toast-Dd0J2e1z.js.map +0 -1
- package/dist/chunks/tooltip-CmKeQwYw.js +0 -2
- package/dist/chunks/tooltip-CmKeQwYw.js.map +0 -1
- package/dist/chunks/tree-DNj_EfUl.js +0 -2
- package/dist/chunks/tree-DNj_EfUl.js.map +0 -1
- package/dist/chunks/useButtonSemantics-B1SbGaDO.js +0 -2
- package/dist/chunks/useButtonSemantics-B1SbGaDO.js.map +0 -1
- package/dist/chunks/useDialogElement-BfygWBPZ.js.map +0 -1
- package/dist/chunks/useDialogTitle-DiB4YDGI.js +0 -2
- package/dist/chunks/useDialogTitle-DiB4YDGI.js.map +0 -1
- package/dist/chunks/useFloatingOverlay-BuiI_CCn.js +0 -2
- package/dist/chunks/useFloatingOverlay-BuiI_CCn.js.map +0 -1
- package/dist/chunks/useHeldBack-eeTfpa_t.js +0 -2
- package/dist/chunks/useHeldBack-eeTfpa_t.js.map +0 -1
- package/dist/chunks/useOverlayMaxHeight-DTgbr4UQ.js +0 -2
- package/dist/chunks/useOverlayMaxHeight-DTgbr4UQ.js.map +0 -1
- package/dist/chunks/useToastRegionQueue-CuAMxAIA.js +0 -2
- package/dist/chunks/useToastRegionQueue-CuAMxAIA.js.map +0 -1
- package/dist/chunks/useTransitionState-sQUQey74.js +0 -2
- package/dist/chunks/useTransitionState-sQUQey74.js.map +0 -1
package/dist/otp-input.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use client";export{t as OtpInput}from"./chunks/otp-input-
|
|
1
|
+
"use client";export{t as OtpInput}from"./chunks/otp-input-CCkfFZID.js";
|
package/dist/pagination.d.ts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { a as Pagination, i as PaginationItemProps, n as usePagination, o as PaginationProps, r as PaginationItem, t as UsePaginationResult } from "./chunks/index-
|
|
1
|
+
import { a as Pagination, i as PaginationItemProps, n as usePagination, o as PaginationProps, r as PaginationItem, t as UsePaginationResult } from "./chunks/index-bZRQGwY7.js";
|
|
2
2
|
export { Pagination, PaginationItem, type PaginationItemProps, type PaginationProps, type UsePaginationResult, usePagination };
|
package/dist/pagination.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use client";export{t as Pagination,n as PaginationItem,r as usePagination}from"./chunks/pagination-
|
|
1
|
+
"use client";export{t as Pagination,n as PaginationItem,r as usePagination}from"./chunks/pagination-WINUPT_P.js";
|
package/dist/placeholder.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use client";export{t as Placeholder}from"./chunks/placeholder-
|
|
1
|
+
"use client";export{t as Placeholder}from"./chunks/placeholder-9rTlnMso.js";
|
package/dist/popover.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use client";export{t as Popover}from"./chunks/popover-
|
|
1
|
+
"use client";export{t as Popover}from"./chunks/popover-CrAJTevL.js";
|
package/dist/progress.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use client";export{t as Progress,n as ProgressBar}from"./chunks/progress-
|
|
1
|
+
"use client";export{t as Progress,n as ProgressBar}from"./chunks/progress-CAqSu3jc.js";
|
package/dist/radio.d.ts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { i as RadioProps, n as RadioGroupProps, r as Radio, t as RadioGroup } from "./chunks/index-
|
|
1
|
+
import { i as RadioProps, n as RadioGroupProps, r as Radio, t as RadioGroup } from "./chunks/index-B2d_pjjy.js";
|
|
2
2
|
export { Radio, RadioGroup, type RadioGroupProps, type RadioProps };
|
package/dist/radio.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use client";export{n as Radio,t as RadioGroup}from"./chunks/radio-
|
|
1
|
+
"use client";export{n as Radio,t as RadioGroup}from"./chunks/radio-XlINMnQm.js";
|
package/dist/range-input.d.ts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { n as RangeInputProps, t as RangeInput } from "./chunks/index-
|
|
1
|
+
import { n as RangeInputProps, t as RangeInput } from "./chunks/index-JCnEw-55.js";
|
|
2
2
|
export { RangeInput, type RangeInputProps };
|
package/dist/range-input.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use client";export{t as RangeInput}from"./chunks/range-input-
|
|
1
|
+
"use client";export{t as RangeInput}from"./chunks/range-input-tyImJHKI.js";
|
package/dist/search-field.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use client";export{t as SearchField}from"./chunks/search-field-
|
|
1
|
+
"use client";export{t as SearchField}from"./chunks/search-field-CIYtMraB.js";
|
package/dist/select.d.ts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { n as SelectOptionDef, r as SelectProps, t as Select } from "./chunks/index-
|
|
1
|
+
import { n as SelectOptionDef, r as SelectProps, t as Select } from "./chunks/index-qJGkO-ni.js";
|
|
2
2
|
export { Select, type SelectOptionDef, type SelectProps };
|
package/dist/select.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use client";export{t as Select}from"./chunks/select-
|
|
1
|
+
"use client";export{t as Select}from"./chunks/select-CkucgA6H.js";
|
package/dist/skeleton.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use client";export{n as Skeleton,t as SkeletonLoader}from"./chunks/skeleton-
|
|
1
|
+
"use client";export{n as Skeleton,t as SkeletonLoader}from"./chunks/skeleton-CXFwCjB9.js";
|
package/dist/spinner.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use client";export{t as Spinner}from"./chunks/spinner-
|
|
1
|
+
"use client";export{t as Spinner}from"./chunks/spinner-BLQiCoQd.js";
|
package/dist/stack.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use client";export{t as Stack}from"./chunks/stack-
|
|
1
|
+
"use client";export{t as Stack}from"./chunks/stack-OItr30SC.js";
|
package/dist/stepper.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use client";export{t as Stepper,n as StepperItem}from"./chunks/stepper-
|
|
1
|
+
"use client";export{t as Stepper,n as StepperItem}from"./chunks/stepper-BLjW7UnC.js";
|
package/dist/style.css
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
@layer colors, theme, config, root, reboot, layout, content, components, custom, helpers, utilities;@layer components{.datepicker[hidden]{display:none}.notification.showing{opacity:0}.datepicker-body{position:relative}.datepicker-months-month.selected,.datepicker-years-year.selected{color:var(--cx-primary-contrast);background-color:var(--cx-primary)}.datepicker-months-month.selected:hover,.datepicker-years-year.selected:hover{background-color:var(--cx-primary)}.datepicker-date>.datepicker-date-btn[aria-disabled=true]{pointer-events:auto;cursor:default}.datepicker-date:where(:not(.datepicker-date-selected))>.datepicker-date-btn[aria-disabled=true]{--cx-day-hover-bg-color:transparent}.datepicker-date-outside>.datepicker-date-btn{color:var(--cx-day-disabled-fg-color)}.datepicker-date-weekend:where(:not(.datepicker-date-selected):not(.datepicker-date-unavailable))>.datepicker-date-btn:where(:not([aria-disabled=true])){color:var(--cx-fg-subtle)}.datepicker-date-unavailable:where(:not(.datepicker-date-selected))>.datepicker-date-btn{color:var(--cx-day-disabled-fg-color);text-decoration:line-through}.datepicker-date-selected>.datepicker-date-btn,.datepicker-date-selected.datepicker-date[aria-current=date]>.datepicker-date-btn{color:var(--cx-primary-contrast);background-color:var(--cx-primary)}.datepicker-date-in-range{color:var(--cx-day-range-fg-color);background-color:var(--cx-day-range-bg-color)}.datepicker-date-in-range>.datepicker-date-btn:hover{background-color:unset}.datepicker-date-in-range.datepicker-date-range-start{border-start-start-radius:var(--cx-border-radius-md);border-end-start-radius:var(--cx-border-radius-md)}.datepicker-date-in-range.datepicker-date-range-end{border-start-end-radius:var(--cx-border-radius-md);border-end-end-radius:var(--cx-border-radius-md)}.datepicker-date-btn:is(.datepicker-date-range-start,.datepicker-date-range-end),.datepicker-date-btn:is(.datepicker-date-range-start,.datepicker-date-range-end):hover{color:var(--cx-primary-contrast);background-color:var(--cx-primary)}.datepicker-date-btn.datepicker-date-range-start:not(.datepicker-date-range-end){border-start-end-radius:0;border-end-end-radius:0}.datepicker-date-btn.datepicker-date-range-end:not(.datepicker-date-range-start){border-start-start-radius:0;border-end-start-radius:0}.datepicker-date[aria-current=date]>.datepicker-date-btn.datepicker-date-range-start,.datepicker-date[aria-current=date]>.datepicker-date-btn.datepicker-date-range-end{color:var(--cx-primary-contrast);background-color:var(--cx-primary)}.datepicker-presets{gap:var(--cx-gap);padding-inline:0 var(--cx-padding-x);border-inline-end:var(--cx-border-width-md) solid var(--cx-border-subtle);flex-direction:column;margin:0;list-style:none;display:flex}.datepicker-preset{padding:var(--cx-space-2xs) var(--cx-space-xs);color:var(--cx-fg-main);text-align:start;white-space:nowrap;cursor:pointer;border-radius:var(--cx-border-radius-md);background-color:#0000;border:0}.datepicker-preset:hover{background-color:var(--cx-bg-hover)}.datepicker-preset:disabled{color:var(--cx-day-disabled-fg-color);cursor:default;background-color:#0000}.datepicker-preset:focus-visible{outline:var(--cx-border-width-xl) solid var(--cx-primary);outline-offset:-1px}.datepicker-preset.selected{color:var(--cx-primary-contrast);background-color:var(--cx-primary)}.datepicker-preset.selected:hover{background-color:var(--cx-primary)}.datagrid{--cx-fg-color:var(--cx-table-td-fg-color,var(--cx-default-fg-main));--cx-bg-color:var(--cx-table-td-bg-color,var(--cx-default-bg-main));--cx-th-fg-color:var(--cx-table-th-fg-color,var(--cx-default-fg-main));--cx-th-bg-color:var(--cx-table-th-bg-color,var(--cx-default-bg-evident));--cx-hover-fg-color:var(--cx-table-hover-fg-color,var(--cx-default-fg-main));--cx-hover-bg-color:var(--cx-table-hover-bg-color,var(--cx-default-dim-slight));--cx-active-fg-color:var(--cx-table-active-fg-color,var(--cx-default-fg-main));--cx-active-bg-color:var(--cx-table-active-bg-color,var(--cx-default-bg-highlight));--cx-border-width:var(--cx-table-border-width,var(--cx-border-width-md));--cx-border-color:var(--cx-table-border-color,var(--cx-default-border-subtle));--cx-cue-color:var(--cx-table-cue-color,var(--cx-default-cue-main));--cx-cell-padding-y:var(--cx-table-cell-padding-y,.5rem);--cx-cell-padding-x:var(--cx-table-cell-padding-x,.5rem);--cx-datagrid-pin-cue-shadow-start:inset -6px 0 6px -6px #0000004d}[dir=rtl] .datagrid{--cx-datagrid-pin-cue-shadow-start:inset 6px 0 6px -6px #0000004d}.datagrid{--cx-datagrid-pin-cue-shadow-end:inset 6px 0 6px -6px #0000004d}[dir=rtl] .datagrid{--cx-datagrid-pin-cue-shadow-end:inset -6px 0 6px -6px #0000004d}.datagrid{--cx-td-font-family:var(--cx-table-td-font-family,var(--cx-font-family-ui));--cx-td-font-size:var(--cx-table-td-font-size,var(--cx-font-size-ui-sm));--cx-td-font-weight:var(--cx-table-td-font-weight,var(--cx-font-weight-ui-normal));--cx-td-line-height:var(--cx-table-td-line-height,var(--cx-line-height-ui-sm));--cx-th-font-family:var(--cx-table-th-font-family,var(--cx-font-family-ui));--cx-th-font-size:var(--cx-table-th-font-size,var(--cx-font-size-ui-sm));--cx-th-font-weight:var(--cx-table-th-font-weight,var(--cx-font-weight-ui-strong));--cx-th-line-height:var(--cx-table-th-line-height,var(--cx-line-height-ui-sm));width:100%;height:400px;vertical-align:var(--cx-table-cell-vertical-align,top);border-color:var(--cx-border-color);display:block;position:relative;overflow:auto}.datagrid [role=columnheader],.datagrid [role=gridcell],.datagrid [role=rowheader]{box-sizing:border-box;height:100%;padding:var(--cx-cell-padding-y) var(--cx-cell-padding-x);color:var(--cx-fg-color);background-color:var(--cx-bg-color);border-color:var(--cx-border-color);border-style:solid;border-width:0 0 var(--cx-border-width) 0;font:var(--cx-td-font-weight) var(--cx-td-font-size)/var(--cx-td-line-height) var(--cx-td-font-family)}.datagrid .datagrid-header [role=columnheader]{--cx-fg-color:var(--cx-th-fg-color);--cx-bg-color:var(--cx-th-bg-color);font:var(--cx-th-font-weight) var(--cx-th-font-size)/var(--cx-th-line-height) var(--cx-th-font-family)}.datagrid [role=row][data-selected]>*{--cx-fg-color:var(--cx-active-fg-color);--cx-bg-color:var(--cx-active-bg-color)}.datagrid.hoverable [role=row]:not([data-selected]):hover>*{--cx-fg-color:var(--cx-hover-fg-color);--cx-bg-color:var(--cx-hover-bg-color)}.datagrid.bordered{border:var(--cx-border-width) solid var(--cx-border-color)}.datagrid.bordered [role=columnheader],.datagrid.bordered [role=gridcell],.datagrid.bordered [role=rowheader]{border-width:0 var(--cx-border-width) var(--cx-border-width) 0}.datagrid.borderless [role=columnheader],.datagrid.borderless [role=gridcell],.datagrid.borderless [role=rowheader]{border-width:0}.datagrid [role=row]:focus-visible,.datagrid [role=gridcell]:focus-visible,.datagrid [role=columnheader]:focus-visible,.datagrid [role=rowheader]:focus-visible{outline:var(--cx-border-width-xl) solid var(--cx-primary);outline-offset:-2px}.datagrid [role=columnheader][data-allows-sorting]{cursor:pointer;user-select:none}.datagrid .datagrid-sort-icon{opacity:.6;margin-inline-start:var(--cx-space-2xs);font-size:.75em;display:inline-block}.datagrid [data-sort-direction] .datagrid-sort-icon{opacity:1}.datagrid :has(>.datagrid-header),.datagrid :has(>.datagrid-body){overflow:visible!important}.datagrid :has(>.datagrid-header){contain:none!important}.datagrid.datagrid-scrolled-start .datagrid-pin-cue-start{box-shadow:var(--cx-datagrid-pin-cue-shadow-start)}.datagrid.datagrid-scrolled-end .datagrid-pin-cue-end{box-shadow:var(--cx-datagrid-pin-cue-shadow-end)}.datagrid .datagrid-selection-cell{text-align:center;padding-inline-end:0}.datagrid-footer{--cx-fg-color:var(--cx-table-td-fg-color,var(--cx-default-fg-main));--cx-bg-color:var(--cx-table-td-bg-color,var(--cx-default-bg-main));--cx-border-width:var(--cx-table-border-width,var(--cx-border-width-md));--cx-border-color:var(--cx-table-border-color,var(--cx-default-border-subtle));--cx-cell-padding-y:var(--cx-table-cell-padding-y,.5rem);--cx-cell-padding-x:var(--cx-table-cell-padding-x,.5rem);box-sizing:border-box;padding:var(--cx-cell-padding-y) var(--cx-cell-padding-x);color:var(--cx-fg-color);background-color:var(--cx-bg-color);border-color:var(--cx-border-color);border-style:solid;border-width:var(--cx-border-width) 0 0 0}.datagrid-footer.borderless{border-width:0}.datagrid.context,.datagrid-footer.context{--cx-table-td-fg-color:var(--cx-fg-main);--cx-table-td-bg-color:var(--cx-bg-main);--cx-table-th-fg-color:var(--cx-fg-main);--cx-table-th-bg-color:var(--cx-bg-evident);--cx-table-hover-fg-color:var(--cx-fg-main);--cx-table-hover-bg-color:var(--cx-bg-evident);--cx-table-active-fg-color:var(--cx-fg-highlight);--cx-table-active-bg-color:var(--cx-bg-highlight);--cx-table-border-color:var(--cx-border-subtle);--cx-table-cue-color:var(--cx-cue-main)}@keyframes progress-bar-indeterminate{0%{transform:translate(-62.5%)scaleX(.25)}50%{transform:translate(0)scaleX(.5)}to{transform:translate(62.5%)scaleX(.25)}}.progress-bar.indeterminate{--cx-indeterminate-animation:var(--cx-progress-indeterminate-animation,1.5s linear infinite progress-bar-indeterminate);width:0;min-width:100%}@media (prefers-reduced-motion:no-preference){.progress-bar.indeterminate:not(.striped){animation:var(--cx-indeterminate-animation)}[dir=rtl] .progress-bar.indeterminate:not(.striped){scale:-1 1}}@media (prefers-reduced-motion:reduce){.progress-bar.indeterminate:not(.striped){background-image:linear-gradient(45deg,oklch(100% 5.96046e-8 90/.15) 25%,#0000 25% 50%,oklch(100% 5.96046e-8 90/.15) 50% 75%,#0000 75%,#0000);background-size:max(var(--cx-height), 1rem) max(var(--cx-height), 1rem)}}.divider{--cx-line-color:var(--cx-divider-color,var(--cx-border-subtle));--cx-line-size:var(--cx-divider-size,var(--cx-border-width-md));--cx-line-opacity:var(--cx-divider-opacity,var(--cx-opacity-solid));--cx-gap:var(--cx-divider-gap,var(--cx-space-sm));--cx-label-fg-color:var(--cx-divider-label-fg-color,var(--cx-fg-subtle));--cx-label-font-size:var(--cx-divider-label-font-size,var(--cx-font-size-ui-sm));margin:var(--cx-divider-margin,var(--cx-space-md) 0);border:0;border-block-start:var(--cx-line-size) solid var(--cx-line-color);opacity:var(--cx-line-opacity);display:block}.divider-vertical{--cx-line-color:var(--cx-divider-color,var(--cx-border-subtle));--cx-line-size:var(--cx-divider-size,var(--cx-border-width-md));--cx-line-opacity:var(--cx-divider-opacity,var(--cx-opacity-solid));width:var(--cx-line-size);background-color:var(--cx-line-color);border:0;align-self:stretch;min-height:1em;margin:0;display:inline-block}.divider-labelled{gap:var(--cx-gap);font-size:var(--cx-label-font-size);color:var(--cx-label-fg-color);opacity:1;border:0;align-items:center;display:flex}.divider-labelled:before,.divider-labelled:after{content:"";border-block-start:var(--cx-line-size) solid var(--cx-line-color);opacity:var(--cx-line-opacity);flex:1 1 0}.divider-vertical.divider-labelled{background-color:#0000;flex-direction:column;width:auto;display:inline-flex}.divider-vertical.divider-labelled:before,.divider-vertical.divider-labelled:after{border-block-start:0;border-inline-start:var(--cx-line-size) solid var(--cx-line-color);min-height:1em}.divider-start:before,.divider-end:after{display:none}.divider-label{text-align:center}.form-input.number-field{gap:var(--cx-gap);align-items:stretch;display:flex}.form-input.number-field>.ghost-input{flex:1;min-width:0}.number-field-buttons{margin-block:calc(var(--cx-border-width) - var(--cx-padding-y));border-inline-start:var(--cx-border-width) solid var(--cx-border-color);border-start-end-radius:calc(var(--cx-border-radius) - var(--cx-border-width));border-end-end-radius:calc(var(--cx-border-radius) - var(--cx-border-width));flex-direction:column;flex-shrink:0;margin-inline-end:calc(var(--cx-border-width) - var(--cx-padding-x));display:flex;overflow:hidden}.number-field-increment,.number-field-decrement{--cx-icon-size:calc(var(--cx-input-icon-size,1.25rem) * 3 / 5);min-height:0;padding:0 calc(var(--cx-padding-x) / 2);color:inherit;background-color:#0000;border:0;flex:1 1 0;justify-content:center;align-items:center;display:flex}.number-field-increment:hover:not(:disabled),.number-field-increment:active:not(:disabled),.number-field-decrement:hover:not(:disabled),.number-field-decrement:active:not(:disabled){background-color:var(--cx-file-button-bg-hover)}.number-field-increment:disabled,.number-field-decrement:disabled{--cx-icon-color:var(--cx-form-disabled-fg-active)}.number-field-increment{border-block-end:var(--cx-border-width) solid var(--cx-border-color)}.form-input.search-field{gap:var(--cx-gap);display:flex}.form-input.search-field>.ghost-input{flex:1;min-width:0}.form-input.search-field>.ghost-input::-webkit-search-cancel-button{appearance:none}.form-input.search-field .search-field-clear{--cx-icon-color:inherit;opacity:var(--cx-close-button-idle-opacity,.5)}.form-input.search-field .search-field-clear:is(:hover,:active){--cx-icon-color:inherit;opacity:var(--cx-close-button-hover-opacity,.75)}.search-field .ghost-input:disabled~.search-field-clear{display:none}.tree{--cx-padding-y:var(--cx-tree-padding-y,var(--cx-space-xs));--cx-padding-x:var(--cx-tree-padding-x,var(--cx-space-xs));--cx-gap:var(--cx-tree-gap,var(--cx-space-xs));--cx-fg-color:var(--cx-tree-fg-color,var(--cx-fg-main));--cx-bg-color:var(--cx-tree-bg-color,var(--cx-bg-main));--cx-item-fg-hover:var(--cx-tree-item-fg-hover,var(--cx-fg-main));--cx-item-bg-hover:var(--cx-tree-item-bg-hover,var(--cx-bg-even));--cx-item-fg-active:var(--cx-tree-item-fg-active,var(--cx-fg-highlight));--cx-item-bg-active:var(--cx-tree-item-bg-active,var(--cx-bg-highlight));--cx-item-fg-disabled:var(--cx-tree-item-fg-disabled,var(--cx-fg-slight));--cx-item-bg-disabled:var(--cx-tree-item-bg-disabled,var(--cx-bg-main));--cx-item-border-radius:var(--cx-tree-item-border-radius,var(--cx-border-radius-sm));--cx-item-icon-idle:var(--cx-tree-item-idle-icon-color,var(--cx-icon-main));--cx-item-icon-active:var(--cx-tree-item-active-icon-color,var(--cx-fg-highlight));--cx-item-icon-disabled:var(--cx-tree-item-disabled-icon-color,var(--cx-icon-slight));--cx-icon-size:var(--cx-tree-icon-size,var(--cx-icon-sm));--cx-toggle-size:var(--cx-tree-toggle-size,var(--cx-size-xs));--cx-indent:var(--cx-tree-indent,calc(var(--cx-toggle-size)));color:var(--cx-fg-color);background-color:var(--cx-bg-color);outline:0;flex-direction:column;display:flex}.tree:focus-visible{outline:var(--cx-focus-ring-width) solid var(--cx-focus-ring-color)}.tree-item{--cx-icon-color:var(--cx-item-icon-idle);gap:var(--cx-gap);padding:var(--cx-padding-y) var(--cx-padding-x);color:var(--cx-item-fg-color,var(--cx-fg-color));user-select:none;background-color:var(--cx-item-bg-color,var(--cx-bg-color));border-radius:var(--cx-item-border-radius);outline:0;align-items:center;padding-inline-start:calc(var(--cx-padding-x) + var(--cx-indent) * (var(--cx-tree-level,1) - 1));display:flex}.tree-item:hover{--cx-item-fg-color:var(--cx-item-fg-hover);--cx-item-bg-color:var(--cx-item-bg-hover)}.tree-item:focus-visible{outline:var(--cx-focus-ring-width) solid var(--cx-focus-ring-color);outline-offset:calc(-1 * var(--cx-focus-ring-width))}.tree-item.active,.tree-item.active:hover{--cx-icon-color:var(--cx-item-icon-active);--cx-item-fg-color:var(--cx-item-fg-active);--cx-item-bg-color:var(--cx-item-bg-active)}.tree-item.disabled,.tree-item.disabled:hover{--cx-icon-color:var(--cx-item-icon-disabled);--cx-item-fg-color:var(--cx-item-fg-disabled);--cx-item-bg-color:var(--cx-item-bg-disabled)}.tree-item-toggle,.tree-item-spacer{width:var(--cx-toggle-size);height:var(--cx-toggle-size);flex:none}.tree-item-toggle{color:inherit;border-radius:var(--cx-item-border-radius);transition:transform var(--cx-transition-duration) var(--cx-transition-timing);background:0 0;border:0;justify-content:center;align-items:center;padding:0;display:inline-flex}@media (prefers-reduced-motion:reduce){.tree-item-toggle{transition:none}}.tree-item-toggle:focus-visible{outline:var(--cx-focus-ring-width) solid var(--cx-focus-ring-color)}.tree-item.expanded .tree-item-toggle{transform:rotate(90deg)}[dir=rtl] .tree-item-toggle{transform:scaleX(-1)}[dir=rtl] .tree-item.expanded .tree-item-toggle{transform:scaleX(-1)rotate(90deg)}.tree-item .tree-item-check{flex:none;margin:0}.tree-item-icon{flex:none;display:inline-flex}.tree-item-label{flex:auto;min-width:0}}.daterangepicker-separator{margin-inline:var(--cx-gap);color:var(--cx-fg-subtle)}.datepicker-field{white-space:nowrap;width:fit-content}.datepicker-segment{padding-inline:var(--cx-space-3xs);border-radius:var(--cx-border-radius-sm);outline:0}.datepicker-segment.placeholder{color:var(--cx-form-idle-fg-inactive)}.datepicker-segment:focus{color:var(--cx-primary-contrast);background-color:var(--cx-primary)}.table-sort-icon{opacity:.6;margin-inline-start:var(--cx-space-2xs);font-size:.75em;display:inline-block}[aria-sort=ascending] .table-sort-icon,[aria-sort=descending] .table-sort-icon{opacity:1}[role=columnheader][aria-sort]{cursor:pointer;user-select:none}.table-selection-cell{text-align:center;width:1%;padding-inline-end:0}.table [role=row]:focus-visible,.table [role=gridcell]:focus-visible,.table [role=columnheader]:focus-visible,.table [role=rowheader]:focus-visible{outline:var(--cx-border-width-xl) solid var(--cx-primary);outline-offset:-2px}
|
|
1
|
+
@layer colors, theme, config, root, reboot, layout, content, components, custom, helpers, utilities;@layer components{.datepicker[hidden]{display:none}.notification.showing{opacity:0}.datepicker-body{position:relative}.datepicker-months-month.selected,.datepicker-years-year.selected{color:var(--cx-primary-contrast);background-color:var(--cx-primary)}.datepicker-months-month.selected:hover,.datepicker-years-year.selected:hover{background-color:var(--cx-primary)}.datepicker-date>.datepicker-date-btn[aria-disabled=true]{pointer-events:auto;cursor:default}.datepicker-date:where(:not(.datepicker-date-selected))>.datepicker-date-btn[aria-disabled=true]{--cx-day-hover-bg-color:transparent}.datepicker-date-outside>.datepicker-date-btn{color:var(--cx-day-disabled-fg-color)}.datepicker-date-weekend:where(:not(.datepicker-date-selected):not(.datepicker-date-unavailable))>.datepicker-date-btn:where(:not([aria-disabled=true])){color:var(--cx-fg-subtle)}.datepicker-date-unavailable:where(:not(.datepicker-date-selected))>.datepicker-date-btn{color:var(--cx-day-disabled-fg-color);text-decoration:line-through}.datepicker-date-selected>.datepicker-date-btn,.datepicker-date-selected.datepicker-date[aria-current=date]>.datepicker-date-btn{color:var(--cx-primary-contrast);background-color:var(--cx-primary)}.datepicker-date-in-range{color:var(--cx-day-range-fg-color);background-color:var(--cx-day-range-bg-color)}.datepicker-date-in-range>.datepicker-date-btn:hover{background-color:unset}.datepicker-date-in-range.datepicker-date-range-start{border-start-start-radius:var(--cx-border-radius-md);border-end-start-radius:var(--cx-border-radius-md)}.datepicker-date-in-range.datepicker-date-range-end{border-start-end-radius:var(--cx-border-radius-md);border-end-end-radius:var(--cx-border-radius-md)}.datepicker-date-btn:is(.datepicker-date-range-start,.datepicker-date-range-end),.datepicker-date-btn:is(.datepicker-date-range-start,.datepicker-date-range-end):hover{color:var(--cx-primary-contrast);background-color:var(--cx-primary)}.datepicker-date-btn.datepicker-date-range-start:not(.datepicker-date-range-end){border-start-end-radius:0;border-end-end-radius:0}.datepicker-date-btn.datepicker-date-range-end:not(.datepicker-date-range-start){border-start-start-radius:0;border-end-start-radius:0}.datepicker-date[aria-current=date]>.datepicker-date-btn.datepicker-date-range-start,.datepicker-date[aria-current=date]>.datepicker-date-btn.datepicker-date-range-end{color:var(--cx-primary-contrast);background-color:var(--cx-primary)}.datepicker-presets{gap:var(--cx-gap);padding-inline:0 var(--cx-padding-x);border-inline-end:var(--cx-border-width-md) solid var(--cx-border-subtle);flex-direction:column;margin:0;list-style:none;display:flex}.datepicker-preset{padding:var(--cx-space-2xs) var(--cx-space-xs);color:var(--cx-fg-main);text-align:start;white-space:nowrap;cursor:pointer;border-radius:var(--cx-border-radius-md);background-color:#0000;border:0}.datepicker-preset:hover{background-color:var(--cx-bg-hover)}.datepicker-preset:disabled{color:var(--cx-day-disabled-fg-color);cursor:default;background-color:#0000}.datepicker-preset:focus-visible{outline:var(--cx-border-width-xl) solid var(--cx-primary);outline-offset:-1px}.datepicker-preset.selected{color:var(--cx-primary-contrast);background-color:var(--cx-primary)}.datepicker-preset.selected:hover{background-color:var(--cx-primary)}.datagrid{--cx-fg-color:var(--cx-table-td-fg-color,var(--cx-default-fg-main));--cx-bg-color:var(--cx-table-td-bg-color,var(--cx-default-bg-main));--cx-th-fg-color:var(--cx-table-th-fg-color,var(--cx-default-fg-main));--cx-th-bg-color:var(--cx-table-th-bg-color,var(--cx-default-bg-evident));--cx-hover-fg-color:var(--cx-table-hover-fg-color,var(--cx-default-fg-main));--cx-hover-bg-color:var(--cx-table-hover-bg-color,var(--cx-default-dim-slight));--cx-active-fg-color:var(--cx-table-active-fg-color,var(--cx-default-fg-main));--cx-active-bg-color:var(--cx-table-active-bg-color,var(--cx-default-bg-highlight));--cx-border-width:var(--cx-table-border-width,var(--cx-border-width-md));--cx-border-color:var(--cx-table-border-color,var(--cx-default-border-subtle));--cx-cue-color:var(--cx-table-cue-color,var(--cx-default-cue-main));--cx-cell-padding-y:var(--cx-table-cell-padding-y,.5rem);--cx-cell-padding-x:var(--cx-table-cell-padding-x,.5rem);--cx-datagrid-pin-cue-shadow-start:inset -6px 0 6px -6px #0000004d}[dir=rtl] .datagrid{--cx-datagrid-pin-cue-shadow-start:inset 6px 0 6px -6px #0000004d}.datagrid{--cx-datagrid-pin-cue-shadow-end:inset 6px 0 6px -6px #0000004d}[dir=rtl] .datagrid{--cx-datagrid-pin-cue-shadow-end:inset -6px 0 6px -6px #0000004d}.datagrid{--cx-td-font-family:var(--cx-table-td-font-family,var(--cx-font-family-ui));--cx-td-font-size:var(--cx-table-td-font-size,var(--cx-font-size-ui-sm));--cx-td-font-weight:var(--cx-table-td-font-weight,var(--cx-font-weight-ui-normal));--cx-td-line-height:var(--cx-table-td-line-height,var(--cx-line-height-ui-sm));--cx-th-font-family:var(--cx-table-th-font-family,var(--cx-font-family-ui));--cx-th-font-size:var(--cx-table-th-font-size,var(--cx-font-size-ui-sm));--cx-th-font-weight:var(--cx-table-th-font-weight,var(--cx-font-weight-ui-strong));--cx-th-line-height:var(--cx-table-th-line-height,var(--cx-line-height-ui-sm));border-color:var(--cx-border-color);width:100%;height:400px;display:block;position:relative;overflow:auto}.datagrid [role=columnheader],.datagrid [role=gridcell],.datagrid [role=rowheader]{box-sizing:border-box;height:100%;padding:var(--cx-cell-padding-y) var(--cx-cell-padding-x);color:var(--cx-fg-color);background-color:var(--cx-bg-color);border-color:var(--cx-border-color);border-style:solid;border-width:0 0 var(--cx-border-width) 0;font:var(--cx-td-font-weight) var(--cx-td-font-size)/var(--cx-td-line-height) var(--cx-td-font-family)}.datagrid .datagrid-header [role=columnheader]{--cx-fg-color:var(--cx-th-fg-color);--cx-bg-color:var(--cx-th-bg-color);font:var(--cx-th-font-weight) var(--cx-th-font-size)/var(--cx-th-line-height) var(--cx-th-font-family)}.datagrid [role=row][data-selected]>*{--cx-fg-color:var(--cx-active-fg-color);--cx-bg-color:var(--cx-active-bg-color)}.datagrid.hoverable .datagrid-body [role=row]:not([data-selected]):hover>*{--cx-fg-color:var(--cx-hover-fg-color);--cx-bg-color:var(--cx-hover-bg-color)}.datagrid.align-top .datagrid-body [role=gridcell],.datagrid.align-top .datagrid-body [role=rowheader]{flex-direction:column;justify-content:flex-start;display:flex}.datagrid.align-top .datagrid-body .datagrid-selection-cell{align-items:center}.datagrid.align-middle .datagrid-body [role=gridcell],.datagrid.align-middle .datagrid-body [role=rowheader]{flex-direction:column;justify-content:center;display:flex}.datagrid.align-middle .datagrid-body .datagrid-selection-cell{align-items:center}.datagrid.align-bottom .datagrid-body [role=gridcell],.datagrid.align-bottom .datagrid-body [role=rowheader]{flex-direction:column;justify-content:flex-end;display:flex}.datagrid.align-bottom .datagrid-body .datagrid-selection-cell{align-items:center}.datagrid.bordered{border:var(--cx-border-width) solid var(--cx-border-color)}.datagrid.bordered [role=columnheader],.datagrid.bordered [role=gridcell],.datagrid.bordered [role=rowheader]{border-width:0 var(--cx-border-width) var(--cx-border-width) 0}.datagrid.borderless [role=columnheader],.datagrid.borderless [role=gridcell],.datagrid.borderless [role=rowheader]{border-width:0}.datagrid.sm{--cx-cell-padding-y:var(--cx-space-2xs);--cx-cell-padding-x:var(--cx-space-2xs)}.datagrid [role=row]:focus-visible,.datagrid [role=gridcell]:focus-visible,.datagrid [role=columnheader]:focus-visible,.datagrid [role=rowheader]:focus-visible{outline:var(--cx-border-width-xl) solid var(--cx-primary);outline-offset:-2px}.datagrid [role=columnheader][data-allows-sorting]{cursor:pointer;user-select:none}.datagrid .datagrid-sort-icon{opacity:.6;margin-inline-start:var(--cx-space-2xs);font-size:.75em;display:inline-block}.datagrid [data-sort-direction] .datagrid-sort-icon{opacity:1}.datagrid :has(>.datagrid-header),.datagrid :has(>.datagrid-body){overflow:visible!important}.datagrid :has(>.datagrid-header){contain:none!important}.datagrid.datagrid-scrolled-start .datagrid-pin-cue-start{box-shadow:var(--cx-datagrid-pin-cue-shadow-start)}.datagrid.datagrid-scrolled-end .datagrid-pin-cue-end{box-shadow:var(--cx-datagrid-pin-cue-shadow-end)}.datagrid .datagrid-selection-cell{text-align:center;padding-inline-end:0}.datagrid-footer{--cx-fg-color:var(--cx-table-td-fg-color,var(--cx-default-fg-main));--cx-bg-color:var(--cx-table-td-bg-color,var(--cx-default-bg-main));--cx-border-width:var(--cx-table-border-width,var(--cx-border-width-md));--cx-border-color:var(--cx-table-border-color,var(--cx-default-border-subtle));--cx-cell-padding-y:var(--cx-table-cell-padding-y,.5rem);--cx-cell-padding-x:var(--cx-table-cell-padding-x,.5rem);box-sizing:border-box;padding:var(--cx-cell-padding-y) var(--cx-cell-padding-x);color:var(--cx-fg-color);background-color:var(--cx-bg-color);border-color:var(--cx-border-color);border-style:solid;border-width:var(--cx-border-width) 0 0 0}.datagrid-footer.borderless{border-width:0}.datagrid-footer.sm{--cx-cell-padding-y:var(--cx-space-2xs);--cx-cell-padding-x:var(--cx-space-2xs)}.datagrid.context,.datagrid-footer.context{--cx-table-td-fg-color:var(--cx-fg-main);--cx-table-td-bg-color:var(--cx-bg-main);--cx-table-th-fg-color:var(--cx-fg-main);--cx-table-th-bg-color:var(--cx-bg-evident);--cx-table-hover-fg-color:var(--cx-fg-main);--cx-table-hover-bg-color:var(--cx-bg-evident);--cx-table-active-fg-color:var(--cx-fg-highlight);--cx-table-active-bg-color:var(--cx-bg-highlight);--cx-table-border-color:var(--cx-border-subtle);--cx-table-cue-color:var(--cx-cue-main)}@keyframes progress-bar-indeterminate{0%{transform:translate(-62.5%)scaleX(.25)}50%{transform:translate(0)scaleX(.5)}to{transform:translate(62.5%)scaleX(.25)}}.progress-bar.indeterminate{--cx-indeterminate-animation:var(--cx-progress-indeterminate-animation,1.5s linear infinite progress-bar-indeterminate);width:0;min-width:100%}@media (prefers-reduced-motion:no-preference){.progress-bar.indeterminate:not(.striped){animation:var(--cx-indeterminate-animation)}[dir=rtl] .progress-bar.indeterminate:not(.striped){scale:-1 1}}@media (prefers-reduced-motion:reduce){.progress-bar.indeterminate:not(.striped){background-image:linear-gradient(45deg,oklch(100% 5.96046e-8 90/.15) 25%,#0000 25% 50%,oklch(100% 5.96046e-8 90/.15) 50% 75%,#0000 75%,#0000);background-size:max(var(--cx-height), 1rem) max(var(--cx-height), 1rem)}}.divider{--cx-line-color:var(--cx-divider-color,var(--cx-border-subtle));--cx-line-size:var(--cx-divider-size,var(--cx-border-width-md));--cx-line-opacity:var(--cx-divider-opacity,var(--cx-opacity-solid));--cx-gap:var(--cx-divider-gap,var(--cx-space-sm));--cx-label-fg-color:var(--cx-divider-label-fg-color,var(--cx-fg-subtle));--cx-label-font-size:var(--cx-divider-label-font-size,var(--cx-font-size-ui-sm));margin:var(--cx-divider-margin,var(--cx-space-md) 0);border:0;border-block-start:var(--cx-line-size) solid var(--cx-line-color);opacity:var(--cx-line-opacity);display:block}.divider-vertical{--cx-line-color:var(--cx-divider-color,var(--cx-border-subtle));--cx-line-size:var(--cx-divider-size,var(--cx-border-width-md));--cx-line-opacity:var(--cx-divider-opacity,var(--cx-opacity-solid));width:var(--cx-line-size);background-color:var(--cx-line-color);border:0;align-self:stretch;min-height:1em;margin:0;display:inline-block}.divider-labelled{gap:var(--cx-gap);font-size:var(--cx-label-font-size);color:var(--cx-label-fg-color);opacity:1;border:0;align-items:center;display:flex}.divider-labelled:before,.divider-labelled:after{content:"";border-block-start:var(--cx-line-size) solid var(--cx-line-color);opacity:var(--cx-line-opacity);flex:1 1 0}.divider-vertical.divider-labelled{background-color:#0000;flex-direction:column;width:auto;display:inline-flex}.divider-vertical.divider-labelled:before,.divider-vertical.divider-labelled:after{border-block-start:0;border-inline-start:var(--cx-line-size) solid var(--cx-line-color);min-height:1em}.divider-start:before,.divider-end:after{display:none}.divider-label{text-align:center}.form-input.number-field{gap:var(--cx-gap);align-items:stretch;display:flex}.form-input.number-field>.ghost-input{flex:1;min-width:0}.number-field-buttons{margin-block:calc(var(--cx-border-width) - var(--cx-padding-y));border-inline-start:var(--cx-border-width) solid var(--cx-border-color);border-start-end-radius:calc(var(--cx-border-radius) - var(--cx-border-width));border-end-end-radius:calc(var(--cx-border-radius) - var(--cx-border-width));flex-direction:column;flex-shrink:0;margin-inline-end:calc(var(--cx-border-width) - var(--cx-padding-x));display:flex;overflow:hidden}.number-field-increment,.number-field-decrement{--cx-icon-size:calc(var(--cx-input-icon-size,1.25rem) * 3 / 5);min-height:0;padding:0 calc(var(--cx-padding-x) / 2);color:inherit;background-color:#0000;border:0;flex:1 1 0;justify-content:center;align-items:center;display:flex}.number-field-increment:hover:not(:disabled),.number-field-increment:active:not(:disabled),.number-field-decrement:hover:not(:disabled),.number-field-decrement:active:not(:disabled){background-color:var(--cx-file-button-bg-hover)}.number-field-increment:disabled,.number-field-decrement:disabled{--cx-icon-color:var(--cx-form-disabled-fg-active)}.number-field-increment{border-block-end:var(--cx-border-width) solid var(--cx-border-color)}.form-input.search-field{gap:var(--cx-gap);display:flex}.form-input.search-field>.ghost-input{flex:1;min-width:0}.form-input.search-field>.ghost-input::-webkit-search-cancel-button{appearance:none}.form-input.search-field .search-field-clear{--cx-icon-color:inherit;opacity:var(--cx-close-button-idle-opacity,.5)}.form-input.search-field .search-field-clear:is(:hover,:active){--cx-icon-color:inherit;opacity:var(--cx-close-button-hover-opacity,.75)}.search-field .ghost-input:disabled~.search-field-clear{display:none}.tree{--cx-padding-y:var(--cx-tree-padding-y,var(--cx-space-xs));--cx-padding-x:var(--cx-tree-padding-x,var(--cx-space-xs));--cx-gap:var(--cx-tree-gap,var(--cx-space-xs));--cx-fg-color:var(--cx-tree-fg-color,var(--cx-fg-main));--cx-bg-color:var(--cx-tree-bg-color,var(--cx-bg-main));--cx-item-fg-hover:var(--cx-tree-item-fg-hover,var(--cx-fg-main));--cx-item-bg-hover:var(--cx-tree-item-bg-hover,var(--cx-bg-even));--cx-item-fg-active:var(--cx-tree-item-fg-active,var(--cx-fg-highlight));--cx-item-bg-active:var(--cx-tree-item-bg-active,var(--cx-bg-highlight));--cx-item-fg-disabled:var(--cx-tree-item-fg-disabled,var(--cx-fg-slight));--cx-item-bg-disabled:var(--cx-tree-item-bg-disabled,var(--cx-bg-main));--cx-item-border-radius:var(--cx-tree-item-border-radius,var(--cx-border-radius-sm));--cx-item-icon-idle:var(--cx-tree-item-idle-icon-color,var(--cx-icon-main));--cx-item-icon-active:var(--cx-tree-item-active-icon-color,var(--cx-fg-highlight));--cx-item-icon-disabled:var(--cx-tree-item-disabled-icon-color,var(--cx-icon-slight));--cx-icon-size:var(--cx-tree-icon-size,var(--cx-icon-sm));--cx-toggle-size:var(--cx-tree-toggle-size,var(--cx-size-xs));--cx-indent:var(--cx-tree-indent,calc(var(--cx-toggle-size)));color:var(--cx-fg-color);background-color:var(--cx-bg-color);outline:0;flex-direction:column;display:flex}.tree:focus-visible{outline:var(--cx-focus-ring-width) solid var(--cx-focus-ring-color)}.tree-item{--cx-icon-color:var(--cx-item-icon-idle);gap:var(--cx-gap);padding:var(--cx-padding-y) var(--cx-padding-x);color:var(--cx-item-fg-color,var(--cx-fg-color));user-select:none;background-color:var(--cx-item-bg-color,var(--cx-bg-color));border-radius:var(--cx-item-border-radius);outline:0;align-items:center;padding-inline-start:calc(var(--cx-padding-x) + var(--cx-indent) * (var(--cx-tree-level,1) - 1));display:flex}.tree-item:hover{--cx-item-fg-color:var(--cx-item-fg-hover);--cx-item-bg-color:var(--cx-item-bg-hover)}.tree-item:focus-visible{outline:var(--cx-focus-ring-width) solid var(--cx-focus-ring-color);outline-offset:calc(-1 * var(--cx-focus-ring-width))}.tree-item.active,.tree-item.active:hover{--cx-icon-color:var(--cx-item-icon-active);--cx-item-fg-color:var(--cx-item-fg-active);--cx-item-bg-color:var(--cx-item-bg-active)}.tree-item.disabled,.tree-item.disabled:hover{--cx-icon-color:var(--cx-item-icon-disabled);--cx-item-fg-color:var(--cx-item-fg-disabled);--cx-item-bg-color:var(--cx-item-bg-disabled)}.tree-item-toggle,.tree-item-spacer{width:var(--cx-toggle-size);height:var(--cx-toggle-size);flex:none}.tree-item-toggle{color:inherit;border-radius:var(--cx-item-border-radius);transition:transform var(--cx-transition-duration) var(--cx-transition-timing);background:0 0;border:0;justify-content:center;align-items:center;padding:0;display:inline-flex}@media (prefers-reduced-motion:reduce){.tree-item-toggle{transition:none}}.tree-item-toggle:focus-visible{outline:var(--cx-focus-ring-width) solid var(--cx-focus-ring-color)}.tree-item.expanded .tree-item-toggle{transform:rotate(90deg)}[dir=rtl] .tree-item-toggle{transform:scaleX(-1)}[dir=rtl] .tree-item.expanded .tree-item-toggle{transform:scaleX(-1)rotate(90deg)}.tree-item .tree-item-check{flex:none;margin:0}.tree-item-icon{flex:none;display:inline-flex}.tree-item-label{flex:auto;min-width:0}}.daterangepicker-separator{margin-inline:var(--cx-space-xs);color:var(--cx-fg-subtle)}.datepicker-field{white-space:nowrap;width:fit-content}.datepicker-segment{padding-inline:var(--cx-space-4xs);border-radius:var(--cx-border-radius-sm);outline:0}.datepicker-segment.placeholder{color:var(--cx-form-idle-fg-inactive)}.datepicker-segment:focus{color:var(--cx-primary-contrast);background-color:var(--cx-primary)}.table.sm{--cx-cell-padding-y:var(--cx-space-2xs);--cx-cell-padding-x:var(--cx-space-2xs)}.table-sort-icon{opacity:.6;margin-inline-start:var(--cx-space-2xs);font-size:.75em;display:inline-block}[aria-sort=ascending] .table-sort-icon,[aria-sort=descending] .table-sort-icon{opacity:1}[role=columnheader][aria-sort]{cursor:pointer;user-select:none}.table-selection-cell{text-align:center;width:1%;padding-inline-end:0}.table [role=row]:focus-visible,.table [role=gridcell]:focus-visible,.table [role=columnheader]:focus-visible,.table [role=rowheader]:focus-visible{outline:var(--cx-border-width-xl) solid var(--cx-primary);outline-offset:-2px}
|
package/dist/switch.d.ts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { n as SwitchProps, t as Switch } from "./chunks/index-
|
|
1
|
+
import { n as SwitchProps, t as Switch } from "./chunks/index-BIWaMOr6.js";
|
|
2
2
|
export { Switch, type SwitchProps };
|
package/dist/switch.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use client";export{t as Switch}from"./chunks/switch-
|
|
1
|
+
"use client";export{t as Switch}from"./chunks/switch-nt7aXQDX.js";
|
package/dist/table.d.ts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { a as TableColumn, c as TableCellProps, d as Table, f as TableProps, i as TableHeaderProps, l as TableBody, n as TableRowProps, o as TableColumnProps, r as TableHeader, s as TableCell, t as TableRow, u as TableBodyProps } from "./chunks/index-
|
|
1
|
+
import { a as TableColumn, c as TableCellProps, d as Table, f as TableProps, i as TableHeaderProps, l as TableBody, n as TableRowProps, o as TableColumnProps, r as TableHeader, s as TableCell, t as TableRow, u as TableBodyProps } from "./chunks/index-C9RqZNjk.js";
|
|
2
2
|
export { Table, TableBody, type TableBodyProps, TableCell, type TableCellProps, TableColumn, type TableColumnProps, TableHeader, type TableHeaderProps, type TableProps, TableRow, type TableRowProps };
|
package/dist/table.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use client";export{o as Table,a as TableBody,i as TableCell,r as TableColumn,n as TableHeader,t as TableRow}from"./chunks/table-
|
|
1
|
+
"use client";export{o as Table,a as TableBody,i as TableCell,r as TableColumn,n as TableHeader,t as TableRow}from"./chunks/table-KtPHx4FG.js";
|
package/dist/tabs.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use client";export{t as Tab,i as TabList,r as TabPanel,n as Tabs}from"./chunks/tabs-
|
|
1
|
+
"use client";export{t as Tab,i as TabList,r as TabPanel,n as Tabs}from"./chunks/tabs-Dh5kH5Ik.js";
|
package/dist/text-input.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use client";export{t as TextInput}from"./chunks/text-input-
|
|
1
|
+
"use client";export{t as TextInput}from"./chunks/text-input-D3jBYiLn.js";
|
package/dist/textarea.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use client";export{t as Textarea}from"./chunks/textarea-
|
|
1
|
+
"use client";export{t as Textarea}from"./chunks/textarea-2BJCzT97.js";
|
package/dist/time-field.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use client";export{t as TimeField}from"./chunks/time-field-
|
|
1
|
+
"use client";export{t as TimeField}from"./chunks/time-field-ClPbatW3.js";
|
package/dist/toast.d.ts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { _ as Toast, a as closeToast, c as ToasterProps, d as ToastHeader, f as ToastHeaderProps, g as ToastBodyProps, h as ToastBody, i as addToast, l as ToastIcon, m as ToastFooterProps, n as useToast, o as toastQueue, p as ToastFooter, r as ToastContent, s as Toaster, t as UseToastResult, u as ToastIconProps, v as ToastProps } from "./chunks/index-
|
|
1
|
+
import { _ as Toast, a as closeToast, c as ToasterProps, d as ToastHeader, f as ToastHeaderProps, g as ToastBodyProps, h as ToastBody, i as addToast, l as ToastIcon, m as ToastFooterProps, n as useToast, o as toastQueue, p as ToastFooter, r as ToastContent, s as Toaster, t as UseToastResult, u as ToastIconProps, v as ToastProps } from "./chunks/index-DjmN2hBX.js";
|
|
2
2
|
export { Toast, ToastBody, type ToastBodyProps, type ToastContent, ToastFooter, type ToastFooterProps, ToastHeader, type ToastHeaderProps, ToastIcon, type ToastIconProps, type ToastProps, Toaster, type ToasterProps, type UseToastResult, addToast, closeToast, toastQueue, useToast };
|
package/dist/toast.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use client";export{o as Toast,l as ToastBody,c as ToastFooter,s as ToastHeader,a as ToastIcon,t as Toaster,n as addToast,r as closeToast,i as toastQueue,u as useToast}from"./chunks/toast-
|
|
1
|
+
"use client";export{o as Toast,l as ToastBody,c as ToastFooter,s as ToastHeader,a as ToastIcon,t as Toaster,n as addToast,r as closeToast,i as toastQueue,u as useToast}from"./chunks/toast-D5-58Ch1.js";
|
package/dist/tooltip.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use client";export{t as Tooltip}from"./chunks/tooltip-
|
|
1
|
+
"use client";export{t as Tooltip}from"./chunks/tooltip-TGFFlOJL.js";
|
package/dist/tree.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use client";export{n as Tree,t as TreeItem}from"./chunks/tree-
|
|
1
|
+
"use client";export{n as Tree,t as TreeItem}from"./chunks/tree-BO0WSxQa.js";
|
package/dist/visually-hidden.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use client";import"./chunks/focus-ring-Bs80iIBN.js";export{t as VisuallyHidden}from"./chunks/VisuallyHidden-
|
|
1
|
+
"use client";import"./chunks/focus-ring-Bs80iIBN.js";export{t as VisuallyHidden}from"./chunks/VisuallyHidden-24WfUCsJ.js";
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@chassis-ui/react",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.6.0",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"description": "Chassis UI Components Library for React.js",
|
|
6
6
|
"keywords": [
|
|
@@ -146,15 +146,15 @@
|
|
|
146
146
|
"devDependencies": {
|
|
147
147
|
"@arethetypeswrong/cli": "^0.18.5",
|
|
148
148
|
"@arethetypeswrong/core": "^0.18.5",
|
|
149
|
-
"@chassis-ui/css": "^0.
|
|
149
|
+
"@chassis-ui/css": "^0.12.0",
|
|
150
150
|
"@chassis-ui/icons": "^0.3.1",
|
|
151
151
|
"@chassis-ui/tokens": "^0.10.1",
|
|
152
152
|
"@playwright/test": "1.64.1",
|
|
153
|
-
"@storybook/addon-a11y": "^10.6.
|
|
154
|
-
"@storybook/addon-docs": "^10.6.
|
|
155
|
-
"@storybook/addon-themes": "^10.6.
|
|
156
|
-
"@storybook/addon-vitest": "^10.6.
|
|
157
|
-
"@storybook/react-vite": "^10.6.
|
|
153
|
+
"@storybook/addon-a11y": "^10.6.3",
|
|
154
|
+
"@storybook/addon-docs": "^10.6.3",
|
|
155
|
+
"@storybook/addon-themes": "^10.6.3",
|
|
156
|
+
"@storybook/addon-vitest": "^10.6.3",
|
|
157
|
+
"@storybook/react-vite": "^10.6.3",
|
|
158
158
|
"@testing-library/jest-dom": "^7.0.1",
|
|
159
159
|
"@testing-library/react": "^16.3.3",
|
|
160
160
|
"@testing-library/user-event": "^14.6.8",
|
|
@@ -169,20 +169,20 @@
|
|
|
169
169
|
"jest-axe": "^11.0.0",
|
|
170
170
|
"jsdom": "^30.1.3",
|
|
171
171
|
"playwright": "^1.64.1",
|
|
172
|
-
"postcss": "^8.5.
|
|
172
|
+
"postcss": "^8.5.31",
|
|
173
173
|
"postcss-prefix-custom-properties": "^0.1.0",
|
|
174
174
|
"publint": "^0.3.25",
|
|
175
175
|
"react": "^19.3.1",
|
|
176
176
|
"react-dom": "^19.3.1",
|
|
177
|
-
"sass": "^1.
|
|
178
|
-
"storybook": "^10.6.
|
|
177
|
+
"sass": "^1.106.1",
|
|
178
|
+
"storybook": "^10.6.3",
|
|
179
179
|
"tsdown": "0.23.1",
|
|
180
180
|
"tslib": "^2.6.0",
|
|
181
181
|
"typescript": "^6.0.3",
|
|
182
182
|
"vitest": "^4.1.12"
|
|
183
183
|
},
|
|
184
184
|
"peerDependencies": {
|
|
185
|
-
"@chassis-ui/css": ">=0.
|
|
185
|
+
"@chassis-ui/css": ">=0.12.0 <0.13.0",
|
|
186
186
|
"react": "^19.0.0",
|
|
187
187
|
"react-dom": "^19.0.0"
|
|
188
188
|
}
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
import{f as e,m as t,v as n}from"./slot-BQVx1Eew.js";import{t as r}from"./polymorphic-CZIFszAy.js";import{t as i}from"./useButtonSemantics-B1SbGaDO.js";import{t as a}from"./useDisabledAnchorGuard-CH6df46a.js";import o from"react";import s from"classnames";import{mergeProps as c}from"react-aria";function l({children:r,className:l,color:u=`primary`,component:d,disabled:f,href:p,onClick:m,pressed:h,shape:g,size:_,type:v,variant:y,...b},x){let S=v??`button`,C=t(d,p,`button`),w=n(C,p,b),T=w===`anchor`,E=e(w,p,`Button`),D=w===`component`,O=s(`button`,u,{outline:y===`outline`,smooth:y===`smooth`,link:y===`link`,active:h,disabled:w!==`button`&&f},_,g,l),k=a(T,f,m),{buttonProps:A,forkedRef:j}=i(x,{disabled:f,onClick:m}),M={className:O,onClick:k},N={"aria-pressed":h};if(w===`button`){let e=C;return/* @__PURE__ */ o.createElement(e,{...b,...M,...N,type:S,disabled:f,ref:x},r)}if(w===`input`){let e=C;return/* @__PURE__ */ o.createElement(e,{...b,...M,...N,type:S,disabled:f,ref:x})}if(T){let e=C;return/* @__PURE__ */ o.createElement(e,{...b,...M,...b.role===`button`&&N,...E,...f&&{"aria-disabled":!0,tabIndex:-1},ref:x},r)}return/* @__PURE__ */ o.createElement(C,{...D?{disabled:f,onClick:m,...v!==void 0&&{type:v},...b}:c(b,A),className:O,...N,...E,ref:D?x:j},r)}const u=r(l,`Button`);export{u as t};
|
|
2
|
-
//# sourceMappingURL=Button-ZU-x1uN_.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"Button-ZU-x1uN_.js","names":["hrefProps","linkElement","resolveLinkKind","createPolymorphicComponent","useButtonSemantics","useDisabledAnchorGuard","React","classNames","ButtonRender","typeProp","rest","type","Component","component","href","kind","isAnchor","linkProps","isComponentReference","_className","color","variant","pressed","disabled","size","shape","className","handleClick","onClick","ref","sharedProps","pressedProps","NativeButton","children","NativeInput","Anchor","mergeProps","buttonProps","forkedRef","Button"],"sources":["../../src/components/button/Button.tsx"],"sourcesContent":["import React, {\n ElementType,\n ForwardRefRenderFunction,\n MouseEventHandler,\n ReactElement,\n Ref\n} from 'react'\nimport classNames from 'classnames'\nimport { mergeProps } from 'react-aria'\n\nimport { ContextColor, ContextStyle, Shapes } from '../../types'\nimport { useButtonSemantics, useDisabledAnchorGuard } from '../../hooks'\nimport { hrefProps, linkElement, resolveLinkKind } from '../../utils/elementKind'\nimport {\n createPolymorphicComponent,\n PolymorphicComponentProps,\n PolymorphicRef,\n PolymorphicRefWithFallback\n} from '../../utils/polymorphic'\n\ntype ButtonOwnProps<C extends ElementType> = {\n /**\n * A string of all className you want applied to the base component.\n */\n className?: string\n /**\n * Sets the color of the component to one of Chassis context colors.\n */\n color?: ContextColor\n /**\n * Component used for the root node. Either a string to use a HTML element or a component.\n */\n component?: C\n /**\n * Toggle the disabled state for the component.\n */\n disabled?: boolean\n /**\n * The href attribute specifies the URL of the page the link goes to.\n */\n href?: string\n /**\n * Fires on click. Typed for every element `component` can actually render (`button`, `a`,\n * `input`, or a custom component), rather than narrowed to `HTMLButtonElement` alone.\n */\n onClick?: MouseEventHandler<HTMLButtonElement | HTMLAnchorElement | HTMLInputElement>\n /**\n * Marks the button as pressed for toggle-style usage (e.g. a formatting toolbar button).\n * Applies the `.active` class and sets `aria-pressed` so assistive technology announces\n * \"button, pressed\" rather than treating the button as a navigation link. A link (`href`, or\n * an `<a>` as `component` or the `asChild` element) has no pressed state to announce: it gets\n * the class alone, unless you give it `role=\"button\"`.\n */\n pressed?: boolean\n /**\n * Select the shape of the component.\n */\n shape?: Shapes\n /**\n * Size the component sm or lg.\n */\n size?: 'sm' | 'lg'\n /**\n * Specifies the type of button. Always specify the type attribute for the `<button>` element.\n * Different browsers may use different default types for the `<button>` element.\n */\n type?: 'button' | 'submit' | 'reset'\n /**\n * Set the button style variant. Same as `ContextStyle`, but `solid` (the unmodified default\n * look) doesn't apply as a class, and `link` — button-specific, not a context color — makes\n * the button look and behave like a hyperlink while keeping its `color`.\n */\n variant?: Exclude<ContextStyle, 'solid'> | 'link'\n}\n\nexport type ButtonProps<C extends ElementType = 'button'> = PolymorphicComponentProps<\n C,\n ButtonOwnProps<C>\n>\n\ntype ButtonComponent = (<C extends ElementType = 'button'>(\n props: ButtonProps<C> & {\n ref?: PolymorphicRefWithFallback<C, HTMLButtonElement | HTMLAnchorElement>\n }\n) => ReactElement | null) & { displayName?: string }\n\nfunction ButtonRender<C extends ElementType = 'button'>(\n {\n children,\n className,\n color = 'primary',\n component,\n disabled,\n href,\n onClick,\n pressed,\n shape,\n size,\n type: typeProp,\n variant,\n ...rest\n }: ButtonProps<C>,\n ref: PolymorphicRef<C>\n) {\n const type = typeProp ?? 'button'\n // `href` makes it an `<a>`, unless `component` or `asChild` chose the element (see\n // `linkElement`).\n const Component = linkElement(component, href, 'button')\n // The kind rather than the tag, counting a router link with `href` or `to` as an anchor: under `asChild`, `Component` is a `Slot` standing in for the\n // caller's element, and a slotted `<a>` needs what `component=\"a\"` gets.\n const kind = resolveLinkKind(Component, href, rest)\n const isAnchor = kind === 'anchor'\n const linkProps = hrefProps(kind, href, 'Button')\n\n // A component reference without a link target (a router link with `href` or `to` is an anchor,\n // see `resolveLinkKind`) has its own visual identity and is trusted to\n // handle its own keyboard/role semantics, same as `CloseButton`'s `isComponentReference` escape\n // hatch — synthesizing `role=\"button\"` and Enter/Space handling on top of it would stamp the\n // wrong ARIA role onto whatever it actually renders (e.g. an `<a>`) and can double-fire a click\n // (native anchor Enter→click, plus the synthesized keydown→click). Only a bare, non-native HTML\n // tag string (e.g. `'div'`) still needs `useButtonSemantics`'s synthesis.\n const isComponentReference = kind === 'component'\n\n const _className = classNames(\n 'button',\n color,\n {\n outline: variant === 'outline',\n smooth: variant === 'smooth',\n link: variant === 'link',\n active: pressed,\n disabled: kind !== 'button' && disabled\n },\n size,\n shape,\n className\n )\n\n // `<a>` has no real `disabled` attribute, so a disabled link button still fires click\n // (and still navigates) unless it's blocked here. Native `button`/`input` already stop\n // clicks on their own once the `disabled` attribute below is set.\n const handleClick = useDisabledAnchorGuard<\n HTMLButtonElement | HTMLAnchorElement | HTMLInputElement\n >(isAnchor, disabled, onClick)\n\n // Native `button`/`a`/`input` elements get keyboard activation, focus and disabled\n // handling for free from the browser. A custom `component` doesn't, so useButtonSemantics\n // fills in role, tabIndex and Enter/Space activation for it, matching native button behavior.\n // `ref` is cast for the same reason as the branches below — it's declared for whatever `C`\n // was passed, but this path (a non-native `component`) only ever populates it with a\n // button/anchor-shaped instance.\n const { buttonProps, forkedRef } = useButtonSemantics<HTMLButtonElement | HTMLAnchorElement>(\n ref as Ref<HTMLButtonElement | HTMLAnchorElement>,\n { disabled, onClick }\n )\n\n // Rendered as three separate branches (rather than one `<Component>` tag driven by a\n // `'button' | 'a' | 'input'`-typed variable) because a union-typed tag makes JSX\n // intersect all three elements' prop types — `onClick`/`ref` would then need to satisfy\n // `button`, `a` *and* `input` simultaneously, which `handleClick`/`ref`'s real, narrower\n // types can't. Each branch renders `Component` typed as its tag: that is the tag itself, or\n // the `Slot` holding the caller's element of that kind. `ref` is cast per branch since it's\n // declared for the generic `C`, not the specific element each branch actually renders (true by\n // construction — each branch's ref only ever populates with a matching instance). The props\n // common to all three (className/onClick) are factored out here so a future addition only\n // needs to change one place, not three.\n const sharedProps = {\n className: _className,\n onClick: handleClick\n }\n // `aria-pressed` is a state of the button role, which a `<button>`, a button `<input>` and an\n // element given button semantics below have. A link doesn't take it (axe's `aria-allowed-attr`),\n // so an anchor gets it only when the caller made it a button.\n const pressedProps = { 'aria-pressed': pressed }\n\n if (kind === 'button') {\n const NativeButton = Component as 'button'\n return (\n <NativeButton\n {...(rest as Record<string, unknown>)}\n {...sharedProps}\n {...pressedProps}\n type={type}\n disabled={disabled}\n ref={ref as Ref<HTMLButtonElement>}\n >\n {children}\n </NativeButton>\n )\n }\n\n if (kind === 'input') {\n const NativeInput = Component as 'input'\n return (\n // `rest` is cast because it's typed generically, whose event handlers don't structurally\n // match `<input>`'s own `onChange` (value-change semantics) — `component=\"input\"` is a\n // fixed set of documented attributes (`type`, `value`, `disabled`, ...), not a\n // general-purpose input, so this is a safe, deliberate escape.\n <NativeInput\n {...(rest as Record<string, unknown>)}\n {...sharedProps}\n {...pressedProps}\n type={type}\n disabled={disabled}\n ref={ref as Ref<HTMLInputElement>}\n />\n )\n }\n\n if (isAnchor) {\n const Anchor = Component as 'a'\n return (\n // `rest` is cast for the same reason as the `input` branch above — it's typed generically,\n // whose DOM event handlers are parameterized for whatever `C` was passed, which don't\n // structurally match `<a>`'s own `HTMLAnchorElement` ones (e.g. `onCopy`), even though both\n // accept a real DOM event at runtime.\n <Anchor\n {...(rest as Record<string, unknown>)}\n {...sharedProps}\n {...((rest as { role?: string }).role === 'button' && pressedProps)}\n {...linkProps}\n {...(disabled && { 'aria-disabled': true, tabIndex: -1 })}\n ref={ref as Ref<HTMLAnchorElement>}\n >\n {children}\n </Anchor>\n )\n }\n\n return (\n <Component\n {...(isComponentReference\n ? // A `type` given reaches the component too: it was taken here and dropped. The\n // default `'button'` doesn't, as nothing says the component renders a button.\n ({\n disabled,\n onClick,\n ...(typeProp !== undefined && { type: typeProp }),\n ...rest\n } as Record<string, unknown>)\n : (mergeProps(rest, buttonProps) as Record<string, unknown>))}\n className={_className}\n {...pressedProps}\n {...linkProps}\n ref={isComponentReference ? ref : forkedRef}\n >\n {children}\n </Component>\n )\n}\n\nexport const Button = createPolymorphicComponent<ButtonComponent>(\n ButtonRender as ForwardRefRenderFunction<Element, ButtonProps<ElementType>>,\n 'Button'\n)\n"],"mappings":"A,wSAsFA,SAASQ,EACP,CACE,WACA,YACA,QAAQ,UACR,YACA,WACA,OACA,UACA,UACA,QACA,OACA,KAAMC,EACN,UACA,GAAGC,GAEL,EACA,CACA,IAAMC,EAAOF,GAAY,SAGnBG,EAAYX,EAAYY,EAAWC,EAAM,QAAQ,EAGjDC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GzB,EADRL,CACQ,CAEf,CAEA,MAAaM,EAASpC,EACpBK,EACA,QACF,E"}
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
import{f as e,m as t,v as n}from"./slot-BQVx1Eew.js";import{t as r}from"./polymorphic-CZIFszAy.js";import{t as i}from"./useButtonSemantics-B1SbGaDO.js";import{t as a}from"./useDisabledAnchorGuard-CH6df46a.js";import o from"react";import s from"classnames";import{mergeProps as c}from"react-aria";function l({children:r,className:l,color:u,component:d,disabled:f,href:p,label:m,onClick:h,size:g,type:_,variant:v,...y},b){let x=_??`button`,S=t(d,p,`button`),C=n(S,p,y),w=e(C,p,`CloseButton`),T=C===`component`,E=T?l:s(`close-button`,{context:u||v,disabled:C!==`button`&&f},u,v,g,l),D=m??(r==null?`Close`:void 0),O=a(C===`anchor`,f,h),{buttonProps:k,forkedRef:A}=i(b,{disabled:f,onClick:h});if(C===`button`){let e=S;return/* @__PURE__ */ o.createElement(e,{className:E,"aria-label":D,...y,type:x,disabled:f,onClick:O,ref:b},r)}if(C===`anchor`){let e=S;return/* @__PURE__ */ o.createElement(e,{className:E,"aria-label":D,...y,...w,onClick:O,...f&&{"aria-disabled":!0,tabIndex:-1},ref:b},r)}let j=S;return/* @__PURE__ */ o.createElement(j,{className:E,"aria-label":D,...T?{color:u,size:g,variant:v,disabled:f,onClick:h,..._!==void 0&&{type:_},...y}:c(y,k),...w,ref:T?b:A},r)}const u=r(l,`CloseButton`);export{u as t};
|
|
2
|
-
//# sourceMappingURL=CloseButton-BPUI5iGX.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"CloseButton-BPUI5iGX.js","names":["hrefProps","linkElement","resolveLinkKind","createPolymorphicComponent","useButtonSemantics","useDisabledAnchorGuard","React","classNames","CloseButtonRender","typeProp","rest","type","component_","component","href","kind","linkProps","isComponentReference","_className","className","color","variant","disabled","size","_label","label","children","handleClick","onClick","ref","NativeButton","Anchor","Component","mergeProps","buttonProps","forkedRef","CloseButton"],"sources":["../../src/components/close-button/CloseButton.tsx"],"sourcesContent":["import React, {\n ElementType,\n ForwardRefRenderFunction,\n MouseEventHandler,\n ReactElement,\n Ref\n} from 'react'\nimport classNames from 'classnames'\nimport { mergeProps } from 'react-aria'\n\nimport { ContextColor, ContextStyle } from '../../types'\nimport { useButtonSemantics, useDisabledAnchorGuard } from '../../hooks'\nimport { hrefProps, linkElement, resolveLinkKind } from '../../utils/elementKind'\nimport {\n createPolymorphicComponent,\n PolymorphicComponentProps,\n PolymorphicRef,\n PolymorphicRefWithFallback\n} from '../../utils/polymorphic'\n\ntype CloseButtonOwnProps<C extends ElementType> = {\n /**\n * A string of all className you want applied to the base component.\n */\n className?: string\n /**\n * Sets the color of the component to one of Chassis context colors. Applies the\n * `context` class alongside it, so the icon picks up that color without needing\n * an ancestor `.context` wrapper.\n */\n color?: ContextColor\n /**\n * Component used for the root node. Either a string to use a HTML element or a component.\n * A custom HTML tag (e.g. `'span'`) gets button semantics — role, focus, Enter/Space\n * activation — filled in automatically. A component is trusted to handle its own semantics,\n * so pass one that's already interactive (e.g. `Button`).\n */\n component?: C\n /**\n * Toggle the disabled state for the component.\n */\n disabled?: boolean\n /**\n * The href attribute specifies the URL of the page the link goes to. Renders an `<a>` in place\n * of the `<button>`, unless `component` or `asChild` chose the element.\n */\n href?: string\n /**\n * The accessible label announced by assistive technology. Override this to\n * localize the button for non-English contexts.\n */\n label?: string\n /**\n * Fires on click. Typed for every element `component` can actually render (`button` or `a`\n * natively, plus whatever a custom `component` renders), rather than narrowed to\n * `HTMLButtonElement` alone.\n */\n onClick?: MouseEventHandler<HTMLButtonElement | HTMLAnchorElement>\n /**\n * Size the component sm or lg.\n */\n size?: 'sm' | 'lg'\n /**\n * Specifies the type of button. Always specify the type attribute for the `<button>` element.\n * Different browsers may use different default types for the `<button>` element.\n */\n type?: 'button' | 'submit' | 'reset'\n /**\n * Set the close button's context style variant. Applies the `context` class\n * alongside it, same as `color`.\n */\n variant?: ContextStyle\n}\n\nexport type CloseButtonProps<C extends ElementType = 'button'> = PolymorphicComponentProps<\n C,\n CloseButtonOwnProps<C>\n>\n\ntype CloseButtonComponent = (<C extends ElementType = 'button'>(\n props: CloseButtonProps<C> & {\n ref?: PolymorphicRefWithFallback<C, HTMLButtonElement | HTMLAnchorElement>\n }\n) => ReactElement | null) & { displayName?: string }\n\nfunction CloseButtonRender<C extends ElementType = 'button'>(\n {\n children,\n className,\n color,\n component,\n disabled,\n href,\n label,\n onClick,\n size,\n type: typeProp,\n variant,\n ...rest\n }: CloseButtonProps<C>,\n ref: PolymorphicRef<C>\n) {\n const type = typeProp ?? 'button'\n // `href` makes it an `<a>`, unless `component` or `asChild` chose the element (see\n // `linkElement`). It used to be dropped unless `component=\"a\"` was passed as well.\n const component_ = linkElement(component, href, 'button')\n // The kind rather than the tag, counting a router link with `href` or `to` as an anchor: under `asChild`, `component_` is a `Slot` standing in for the\n // caller's element, and a slotted `<a>` needs what `component=\"a\"` gets.\n const kind = resolveLinkKind(component_, href, rest)\n const linkProps = hrefProps(kind, href, 'CloseButton')\n\n // A component reference (e.g. `Button`) has its own visual identity and its own\n // `color`/`size`/`variant` semantics — CloseButton's icon styling (the `close-button`\n // class and its context/color/variant/size classes) would just conflict with it, and\n // would also swallow those props before the component ever saw them. So a component\n // reference gets none of CloseButton's own styling; `color`/`size`/`variant` pass\n // through untouched, same as `className`, letting the component interpret them itself.\n const isComponentReference = kind === 'component'\n\n // Only a bare, non-`button` HTML tag needs the `.disabled` class applied by hand — a real\n // `<button>` gets native `:disabled` styling for free (chassis-css matches both selectors,\n // `&:disabled, &.disabled`), and a component reference isn't styled by CloseButton at all\n // (see `isComponentReference` above).\n const _className = isComponentReference\n ? className\n : classNames(\n 'close-button',\n { context: color || variant, disabled: kind !== 'button' && disabled },\n color,\n variant,\n size,\n className\n )\n\n // The default icon-only close button has no visible text, so it needs the 'Close' fallback\n // as its accessible name. Once `children` renders visible content (e.g. custom text passed\n // through `component`), let that content be the accessible name instead — forcing the\n // fallback label here would silently override it (a Label-in-Name accessibility failure).\n // An explicit `label` always wins either way, same as an explicit `aria-label` always did.\n const _label = label ?? (children == null ? 'Close' : undefined)\n\n // `<a>` has no real `disabled` attribute, so a disabled link close-button still fires\n // click (and still navigates) unless it's blocked here, same guard `Button` applies.\n const handleClick = useDisabledAnchorGuard<HTMLButtonElement | HTMLAnchorElement>(\n kind === 'anchor',\n disabled,\n onClick\n )\n\n const { buttonProps, forkedRef } = useButtonSemantics<HTMLButtonElement | HTMLAnchorElement>(\n ref as Ref<HTMLButtonElement | HTMLAnchorElement>,\n { disabled, onClick }\n )\n\n // Rendered as explicit branches, same as `Button`, rather than one `<Component>` tag\n // driven by a `'button' | 'a' | ElementType`-typed variable — a union-typed tag would\n // make JSX intersect all of `button`/`a`/custom prop types at once. Each branch renders\n // `component_` typed as its tag: the tag itself, or the `Slot` holding an element of that kind.\n // `aria-label={_label}` comes before `...rest` in every branch below so that an explicit\n // `aria-label` (not destructured above, so it lands in `rest`) overrides the computed\n // fallback via JSX's last-attribute-wins rule, rather than the other way around.\n if (kind === 'button') {\n const NativeButton = component_ as 'button'\n return (\n <NativeButton\n className={_className}\n aria-label={_label}\n {...(rest as Record<string, unknown>)}\n type={type}\n disabled={disabled}\n onClick={handleClick}\n ref={ref as Ref<HTMLButtonElement>}\n >\n {children}\n </NativeButton>\n )\n }\n\n if (kind === 'anchor') {\n const Anchor = component_ as 'a'\n return (\n <Anchor\n className={_className}\n aria-label={_label}\n {...(rest as Record<string, unknown>)}\n {...linkProps}\n onClick={handleClick}\n {...(disabled && { 'aria-disabled': true, tabIndex: -1 })}\n ref={ref as Ref<HTMLAnchorElement>}\n >\n {children}\n </Anchor>\n )\n }\n\n const Component = component_ as ElementType\n\n // Only a bare, non-`button`/`a` HTML tag (e.g. `'span'`) reaches here needing synthesized\n // button semantics — a component reference is trusted to already be interactive, so it\n // skips `buttonProps` (double keyboard activation) and instead gets `color`/`size`/`variant`\n // passed through untouched, per the comment on `isComponentReference` above.\n return (\n <Component\n className={_className}\n aria-label={_label}\n {...(isComponentReference\n ? // A `type` given reaches the component too, as `Button` passes it: it was taken here\n // and dropped. The default `'button'` doesn't, as nothing says the component renders\n // a button.\n ({\n color,\n size,\n variant,\n disabled,\n onClick,\n ...(typeProp !== undefined && { type: typeProp }),\n ...rest\n } as Record<string, unknown>)\n : (mergeProps(rest, buttonProps) as Record<string, unknown>))}\n {...linkProps}\n ref={isComponentReference ? ref : forkedRef}\n >\n {children}\n </Component>\n )\n}\n\nexport const CloseButton = createPolymorphicComponent<CloseButtonComponent>(\n CloseButtonRender as ForwardRefRenderFunction<Element, CloseButtonProps<ElementType>>,\n 'CloseButton'\n)\n"],"mappings":"A,wSAqFA,SAASQ,EACP,CACE,WACA,YACA,QACA,YACA,WACA,OACA,QACA,UACA,OACA,KAAMC,EACN,UACA,GAAGC,GAEL,EACA,CACA,IAAMC,EAAOF,GAAY,SAGnBG,EAAaX,EAAYY,EAAWC,EAAM,QAAQ,EAGlDC,EAAOb,EAAgBU,EAAYE,EAAMJ,CAAI,EAC7CM,EAAYhB,EAAUe,EAAMD,EAAM,aAAa,EAQ/CG,EAAuBF,IAAS,YAMhCG,EAAaD,EACfE,EACAZ,EACE,eACA,CAAE,QAASa,GAASC,EAAS,SAAUN,IAAS,UAAYO,CAAS,EACrEF,EACAC,EACAE,EACAJ,CACF,EAOEK,EAASC,IAAUC,GAAY,KAAO,QAAU,IAAA,IAIhDC,EAActB,EAClBU,IAAS,SACTO,EACAM,CACF,EAEM,CAAE,cAAa,aAAcxB,EACjCyB,EACA,CAAE,WAAU,SAAQ,CACtB,EASA,GAAId,IAAS,SAAU,CACrB,IAAMe,EAAelB,EACrB,MACE,kBAAA,cAACkB,EAAD,CACE,UAAWZ,EACX,aAAYM,EACZ,GAAKd,EACC,OACI,WACV,QAASiB,EACJ,KAGO,EADXD,CACW,CAElB,CAEA,GAAIX,IAAS,SAAU,CACrB,IAAMgB,EAASnB,EACf,MACE,kBAAA,cAACmB,EAAD,CACE,UAAWb,EACX,aAAYM,EACZ,GAAKd,EACL,GAAIM,EACJ,QAASW,EACT,GAAKL,GAAY,CAAE,gBAAiB,GAAM,SAAU,EAAG,EAClD,KAGC,EADLI,CACK,CAEZ,CAEA,IAAMM,EAAYpB,EAMlB,MACE,kBAAA,cAACoB,EAAD,CACE,UAAWd,EACX,aAAYM,EACZ,GAAKP,EAIA,CACC,QACA,OACA,UACA,WACA,UACA,GAAIR,IAAa,IAAA,IAAa,CAAE,KAAMA,CAAS,EAC/C,GAAGC,CACL,EACCuB,EAAWvB,EAAMwB,CAAW,EACjC,GAAIlB,EACJ,IAAKC,EAAuBY,EAAMM,CAGzB,EADRT,CACQ,CAEf,CAEA,MAAaU,EAAcjC,EACzBK,EACA,aACF,E"}
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
import{f as e,m as t,p as n,v as r}from"./slot-BQVx1Eew.js";import{t as i}from"./useForkedRef-WoqMqsWE.js";import{t as a}from"./polymorphic-CZIFszAy.js";import{t as o}from"./useButtonSemantics-B1SbGaDO.js";import{t as s}from"./useDisabledAnchorGuard-CH6df46a.js";import{r as c}from"./colorClassNames-YzGWu6qm.js";import{n as l}from"./scrollspy-D_lPjb92.js";import u from"react";import d from"classnames";import{mergeProps as f}from"react-aria";function p({children:a,active:p,className:m,color:h,component:g,disabled:_,href:v,iconLink:y,onClick:b,reset:x,stretched:S,type:C=`button`,...w},T){let E=t(g,v,`a`),D=r(E,v,w),O=n(D),k=D===`component`,A=l(_),j=A.onClick,M=s(D===`anchor`,_,j?e=>{b?.(e),j(e)}:b),N=!O&&!k&&!!b,{buttonProps:P,forkedRef:F}=o(T,{disabled:_,onClick:b}),I=N?F:T,L=i(I,A.ref),R=p||!!A.mark,z=w[`aria-current`]??(p?`page`:A.mark===`current`?`true`:void 0),B=d(h&&c[h],{"icon-link":y,"fg-reset":x,"stretched-link":S},{active:R,disabled:_},m);return/* @__PURE__ */ u.createElement(E,{...f(w,N?P:{}),className:B,...e(D,v,`Link`),...z&&{"aria-current":z},...D===`anchor`&&_&&{"aria-disabled":!0,tabIndex:-1},...!N&&{onClick:M},...D===`button`&&{disabled:_,type:C},ref:A.ref?L:I},a)}const m=a(p,`Link`);export{m as t};
|
|
2
|
-
//# sourceMappingURL=Link-DE8NSAXJ.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"Link-DE8NSAXJ.js","names":["hrefProps","linkElement","isInteractiveKind","resolveLinkKind","useForkedRef","createPolymorphicComponent","useButtonSemantics","useDisabledAnchorGuard","LINK_COLOR_CLASS_NAMES","useScrollspyLink","React","classNames","LinkRender","rest","Component","component","href","kind","isInteractive","isComponentReference","spy","disabled","spyClick","handleClick","onClick","event","needsButtonSemantics","ref","ownRef","forkedRef","spyRef","isActive","active","ariaCurrent","_className","color","iconLink","reset","stretched","className","mergeProps","buttonProps","children","Link"],"sources":["../../src/components/link/Link.tsx"],"sourcesContent":["import React, {\n AriaAttributes,\n ElementType,\n ForwardRefRenderFunction,\n MouseEventHandler,\n ReactElement,\n Ref\n} from 'react'\nimport classNames from 'classnames'\nimport { mergeProps } from 'react-aria'\n\nimport { ContextColor } from '../../types'\nimport { LINK_COLOR_CLASS_NAMES } from '../../utils/colorClassNames'\nimport { useButtonSemantics, useDisabledAnchorGuard, useForkedRef } from '../../hooks'\nimport { hrefProps, isInteractiveKind, linkElement, resolveLinkKind } from '../../utils/elementKind'\nimport {\n createPolymorphicComponent,\n PolymorphicComponentProps,\n PolymorphicRef\n} from '../../utils/polymorphic'\nimport { useScrollspyLink } from '../../utils/scrollspy'\n\ntype LinkOwnProps<C extends ElementType> = {\n /**\n * Toggle the active state for the component.\n */\n active?: boolean\n /**\n * A string of all className you want applied to the component.\n */\n className?: string\n /**\n * Sets the link color to one of Chassis context colors, including its interactive\n * (`:hover`/`:focus`/`:active`/`:visited`) states.\n */\n color?: ContextColor\n /**\n * Component used for the root node. Either a string to use a HTML element or a component.\n */\n component?: C\n /**\n * Toggle the disabled state for the component.\n */\n disabled?: boolean\n /**\n * The href attribute specifies the URL of the page the link goes to. Reaches an `<a>` or a\n * component reference (a router link); dropped, with a warning in development, when\n * `component` is another element. Declared explicitly here — rather than left to flow through\n * generically from whatever `C` is — so consumers that wrap `Link` (`MenuItem`, `ListItem`,\n * `NavLink`) can read it with a concrete type regardless of `component`.\n */\n href?: string\n /**\n * Fires on click.\n */\n onClick?: MouseEventHandler<HTMLElement>\n /**\n * Aligns a leading or trailing icon with the link text using flexbox, with a gap between\n * them and an offset underline. Icons need to be passed as `children` alongside the text.\n * Named `iconLink` rather than `icon` to avoid colliding with components (e.g. `MenuItem`)\n * that already have their own, differently-typed `icon` prop for the icon content itself.\n */\n iconLink?: boolean\n /**\n * Removes the foreground color override, so the link inherits its color from the nearest\n * ancestor instead of the default link color.\n */\n reset?: boolean\n /**\n * Expands the link's click target to fill its positioned ancestor (the nearest ancestor with\n * a `position` other than `static`).\n */\n stretched?: boolean\n /**\n * Specifies the type of button. Only applies when `component=\"button\"`. Different browsers may\n * use different default types for the `<button>` element, so always specify it explicitly.\n */\n type?: 'button' | 'submit' | 'reset'\n}\n\nexport type LinkProps<C extends ElementType = 'a'> = PolymorphicComponentProps<C, LinkOwnProps<C>>\n\ntype LinkComponent = (<C extends ElementType = 'a'>(\n props: LinkProps<C> & { ref?: PolymorphicRef<C> }\n) => ReactElement | null) & { displayName?: string }\n\nfunction LinkRender<C extends ElementType = 'a'>(\n {\n children,\n active,\n className,\n color,\n component,\n disabled,\n href,\n iconLink,\n onClick,\n reset,\n stretched,\n type = 'button',\n ...rest\n }: LinkProps<C>,\n ref: PolymorphicRef<C>\n) {\n const Component = linkElement(component, href, 'a')\n // The kind rather than the tag, counting a router link with `href` or `to` as an anchor: under `asChild`, `Component` is a `Slot` standing in for the\n // caller's element, and a slotted `<a>` needs what `component=\"a\"` gets.\n const kind = resolveLinkKind(Component, href, rest)\n\n const isInteractive = isInteractiveKind(kind)\n // A component reference without a link target (a router link with `href` or `to` is an anchor,\n // see `resolveLinkKind`) has its own visual identity and is trusted to\n // handle its own keyboard/role semantics, same as `CloseButton`'s `isComponentReference` escape\n // hatch — synthesizing `role=\"button\"` and Enter/Space handling on top of it would stamp the\n // wrong ARIA role onto whatever it actually renders (e.g. an `<a>`) and can double-fire a click\n // (native anchor Enter→click, plus the synthesized keydown→click).\n const isComponentReference = kind === 'component'\n // Inside a `Scrollspy`, the link registers its element, is marked when its section is the one\n // being read, and scrolls to it smoothly when the `Scrollspy` is set to (`src/utils/scrollspy.ts`).\n const spy = useScrollspyLink(disabled)\n const spyClick = spy.onClick\n const clickHandler: MouseEventHandler<HTMLElement> | undefined = spyClick\n ? (event) => {\n onClick?.(event)\n spyClick(event)\n }\n : onClick\n // `<a>` has no real `disabled` attribute, so a disabled anchor link still fires click (and\n // still navigates) unless it's blocked here, same guard `Button`/`CloseButton` apply. A real\n // `<button>` already stops clicks on its own once the `disabled` attribute below is set.\n const handleClick = useDisabledAnchorGuard<HTMLElement>(kind === 'anchor', disabled, clickHandler)\n\n // A `component` that isn't a native interactive element gets a raw onClick with no\n // keyboard semantics otherwise — mouse-only, unlike `Button`/`CloseButton`, which\n // synthesize this via `useButtonSemantics` for exactly this \"arbitrary component\" case. A\n // component reference is excluded (see `isComponentReference` above).\n const needsButtonSemantics = !isInteractive && !isComponentReference && !!onClick\n const { buttonProps, forkedRef } = useButtonSemantics<HTMLElement>(ref as Ref<HTMLElement>, {\n disabled,\n onClick\n })\n const ownRef = needsButtonSemantics ? forkedRef : ref\n const spyRef = useForkedRef(ownRef as Ref<HTMLElement>, spy.ref)\n // A link to the section being read is `active` and `aria-current=\"true\"`: the current place in\n // the page, not the current page. A link it belongs under, such as its menu's toggle, only\n // looks active. An `active` given as a prop wins, and an `aria-current` given as one wins over\n // both: a step of a process is `\"step\"`, not the current page.\n const isActive = active || !!spy.mark\n const ownAriaCurrent = (rest as AriaAttributes)['aria-current']\n const ariaCurrent =\n ownAriaCurrent ?? (active ? 'page' : spy.mark === 'current' ? 'true' : undefined)\n\n const _className = classNames(\n color && LINK_COLOR_CLASS_NAMES[color],\n { 'icon-link': iconLink, 'fg-reset': reset, 'stretched-link': stretched },\n { active: isActive, disabled },\n className\n )\n\n return (\n <Component\n {...(mergeProps(rest, needsButtonSemantics ? buttonProps : {}) as Record<string, unknown>)}\n className={_className}\n {...hrefProps(kind, href, 'Link')}\n {...(ariaCurrent && { 'aria-current': ariaCurrent })}\n {...(kind === 'anchor' && disabled && { 'aria-disabled': true, tabIndex: -1 })}\n {...(!needsButtonSemantics && { onClick: handleClick })}\n {...(kind === 'button' && { disabled, type })}\n ref={spy.ref ? spyRef : ownRef}\n >\n {children}\n </Component>\n )\n}\n\nexport const Link = createPolymorphicComponent<LinkComponent>(\n LinkRender as ForwardRefRenderFunction<Element, LinkProps<ElementType>>,\n 'Link'\n)\n"],"mappings":"A,4bAsFA,SAASY,EACP,CACE,WACA,SACA,YACA,QACA,YACA,WACA,OACA,WACA,UACA,QACA,YACA,OAAO,SACP,GAAGC,GAEL,EACA,CACA,IAAMC,EAAYb,EAAYc,EAAWC,EAAM,GAAG,EAG5CC,EAAOd,EAAgBW,EAAWE,EAAMH,CAAI,EAE5CK,EAAgBhB,EAAkBe,CAAI,EAOtCE,EAAuBF,IAAS,YAGhCG,EAAMX,EAAiBY,CAAQ,EAC/BC,EAAWF,EAAI,QAUfG,EAAchB,EAAoCU,IAAS,SAAUI,EATVC,EAC5D,GAAU,CACTE,IAAUC,CAAK,EACfH,EAASG,CAAK,CAChB,EACAD,CAI6F,EAM3FE,EAAuB,CAACR,GAAiB,CAACC,GAAwB,CAAC,CAACK,EACpE,CAAE,cAAa,aAAclB,EAAgCqB,EAAyB,CAC1F,WACA,SACF,CAAC,EACKC,EAASF,EAAuBG,EAAYF,EAC5CG,EAAS1B,EAAawB,EAA4BR,EAAI,GAAG,EAKzDW,EAAWC,GAAU,CAAC,CAACZ,EAAI,KAE3Ba,EADkBpB,EAAwB,kBAE3BmB,EAAS,OAASZ,EAAI,OAAS,UAAY,OAAS,IAAA,IAEnEc,EAAavB,EACjBwB,GAAS3B,EAAuB2B,GAChC,CAAE,YAAaC,EAAU,WAAYC,EAAO,iBAAkBC,CAAU,EACxE,CAAE,OAAQP,EAAU,UAAS,EAC7BQ,CACF,EAEA,MACE,kBAAA,cAACzB,EAAD,CACE,GAAK0B,EAAW3B,EAAMa,EAAuBe,EAAc,CAAC,CAAC,EAC7D,UAAWP,EACX,GAAIlC,EAAUiB,EAAMD,EAAM,MAAM,EAChC,GAAKiB,GAAe,CAAE,eAAgBA,CAAY,EAClD,GAAKhB,IAAS,UAAYI,GAAY,CAAE,gBAAiB,GAAM,SAAU,EAAG,EAC5E,GAAK,CAACK,GAAwB,CAAE,QAASH,CAAY,EACrD,GAAKN,IAAS,UAAY,CAAE,WAAU,MAAK,EAC3C,IAAKG,EAAI,IAAMU,EAASF,CAGf,EADRc,CACQ,CAEf,CAEA,MAAaC,EAAOtC,EAClBO,EACA,MACF,E"}
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
import{t as e}from"./useForkedRef-WoqMqsWE.js";import{t}from"./polymorphic-CZIFszAy.js";import{t as n}from"./useIsomorphicLayoutEffect-BbqRwuqn.js";import{t as r}from"./dialogTransition-C8fYTsSa.js";import{n as i}from"./overlayStack-BXtTGCRm.js";import{r as a}from"./useFloatingOverlay-BuiI_CCn.js";import{t as o}from"./useOpenStateProps-BhjSQ3f6.js";import{t as s}from"./useOverlayMaxHeight-DTgbr4UQ.js";import{i as c,r as l}from"./overlayPlacement-Q6bcbXA5.js";import{n as ee}from"./insideEvents-CWcNrMu7.js";import{t as te}from"./navOverflow-C_QJmkPM.js";import u,{Fragment as d,createContext as f,useEffect as p,useMemo as ne,useRef as m}from"react";import re from"classnames";import{useMenuTrigger as ie,useOverlayPosition as h}from"react-aria";import{useMenuTriggerState as g}from"react-stately";const _=()=>void 0,v=f({autoClose:!0,close:_,focusStrategy:null,hide:_,menuId:``,menuStyle:{},menuTriggerProps:{},overlayRef:{current:null},placementAttr:`bottom-start`,reference:`toggle`,registerOverlay:_,show:_,targetRef:{current:null},toggle:_,toggleNodeRef:{current:null},triggerId:``,visible:!1}),y=/* @__PURE__ */ new WeakSet,b=/* @__PURE__ */ new Set;function x({children:t,autoClose:f=!0,className:_,component:x,container:S,defaultVisible:C,offset:w=[0,2],onHide:ae,onHidden:T,onShow:oe,onShown:E,onVisibleChange:D,placement:O=`bottom-start`,reference:k=`toggle`,visible:A,...se},ce){let j=x??d,M=m(null),le=e(ce,M),N=m(null),P=m(null),F=m(null),I=m(/* @__PURE__ */ new Map),L=(e,t)=>{t?I.current.set(e,t):I.current.delete(e)},R=g(o({defaultVisible:C,onVisibleChange:D,visible:A},`Menu`)),{menuTriggerProps:z,menuProps:B}=ie({},R,N);n(()=>{k===`parent`&&(P.current=M.current)},[k]);let V=m(!1);p(()=>{let e=F.current,t=!V.current;if(V.current=!0,!t){if(R.isOpen){if(oe?.(),!e){E?.();return}return r(e,()=>E?.(),!0)}if(ae?.(),!e)T?.();else return r(e,()=>T?.(),!0)}},[R.isOpen]);let{overlayProps:H,placement:U,updatePosition:ue}=h({targetRef:P,overlayRef:F,placement:c(O),offset:w[1],crossOffset:w[0],containerPadding:8,isOpen:R.isOpen,onClose:null});s(F,R.isOpen);let{menuStyle:W,placementAttr:G}=l(H.style,O,U),K=m(!0);K.current=A===void 0||!!D;let q=m(!1);q.current=A!==void 0;let J=m(!1),de=e=>R.open(e),Y=()=>{J.current=!1,R.close()},X=e=>R.toggle(e),Z=()=>{R.close(),q.current?J.current=K.current:N.current?.focus()};p(()=>{!R.isOpen&&J.current&&N.current?.focus(),J.current=!1},[R.isOpen]);let Q=a({close:Y,isOpen:R.isOpen,triggerRef:N});n(()=>{R.isOpen&&ue()},[Q]),p(()=>{if(!R.isOpen||f===!1)return;let e=/* @__PURE__ */ new WeakSet,t=t=>{if(t instanceof KeyboardEvent&&t.key!==`Tab`||e.has(t))return;e.add(t);let n=t.target,r=N.current,i=F.current;if(r?.contains(n))return;let a=!!i?.contains(n)||Array.from(I.current.values()).some(e=>e.contains(n));if(!a&&ee(t,F)||a&&y.has(t)||f===`inside`&&!a||f===`outside`&&a||a&&(t instanceof KeyboardEvent&&t.key===`Tab`||/input|select|option|textarea|form/i.test(n.tagName??``)))return;let o=document.activeElement,s=!o||o===document.body||!!i?.contains(o)||Array.from(I.current.values()).some(e=>e.contains(o));a&&s?Z():Y()},n=window.setTimeout(()=>{window.addEventListener(`click`,t),window.addEventListener(`keyup`,t),b.add(t)});return()=>{window.clearTimeout(n),window.removeEventListener(`click`,t),window.removeEventListener(`keyup`,t),b.delete(t)}},[R.isOpen,f]),p(()=>{if(R.isOpen)return i({nodes:()=>[F.current,N.current],onEscape:Z})},[R.isOpen]);let fe=ne(()=>({autoClose:f,close:Z,container:S===!0?Q??!0:S,focusStrategy:R.focusStrategy,hide:Y,menuId:B.id??``,menuStyle:W,menuTriggerProps:z,overlayRef:F,placementAttr:G,portalContainer:Q,reference:k,registerOverlay:L,show:de,targetRef:P,toggle:X,toggleNodeRef:N,triggerId:z.id??``,visible:R.isOpen}),[f,S,R.focusStrategy,B.id,W,z,G,Q,k,R.isOpen]),$=/* @__PURE__ */ u.createElement(te,null,t);return/* @__PURE__ */ u.createElement(v.Provider,{value:fe},j===d?$:/* @__PURE__ */ u.createElement(j,{className:re(_,{show:R.isOpen}),...se,ref:le},$))}const S=t(x,`Menu`);export{b as i,v as n,y as r,S as t};
|
|
2
|
-
//# sourceMappingURL=Menu-BiE9CzNk.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"Menu-BiE9CzNk.js","names":["useForkedRef","useIsomorphicLayoutEffect","executeAfterTransition","pushOverlay","useFloatingOverlay","useOpenStateProps","useOverlayMaxHeight","toAriaPlacement","resolveMenuOverlayPositioning","isEventInside","NavOverflowBoundary","React","classNames","noop","MenuContext","createContext","menuToggleClicks","openMenuDismissals","MenuRender","offsetProp","rest","Component","component","Fragment","wrapperRef","useRef","forkedRef","ref","toggleNodeRef","targetRef","overlayRef","submenuOverlaysRef","registerOverlay","node","id","state","useMenuTriggerState","useMenuTrigger","reference","mountedRef","useEffect","overlay","isInitialCommit","onShow","onShown","onHide","onHidden","resolvedPlacement","useOverlayPosition","placement","overlayProps","followsRequestsRef","visible","onVisibleChange","isControlledRef","focusReturnOwedRef","show","focusStrategy","hide","toggleVisible","close","portalContainer","updatePosition","autoClose","handled","handleDismiss","event","target","toggleNode","menuNode","isMenuTarget","active","holdsFocus","contextValue","useMemo","container","menuProps","menuTriggerProps","menuStyle","placementAttr","content","children","className","Menu","createPolymorphicComponent"],"sources":["../../src/components/menu/Menu.tsx"],"sourcesContent":["import React, {\n createContext,\n ElementType,\n ForwardRefRenderFunction,\n Fragment,\n ReactElement,\n useEffect,\n useMemo,\n useRef\n} from 'react'\nimport classNames from 'classnames'\nimport { AriaButtonProps, useMenuTrigger, useOverlayPosition } from 'react-aria'\nimport { useMenuTriggerState } from 'react-stately'\n\nimport {\n useFloatingOverlay,\n useForkedRef,\n useIsomorphicLayoutEffect,\n useOpenStateProps,\n useOverlayMaxHeight\n} from '../../hooks'\nimport { executeAfterTransition } from '../../utils/dialogTransition'\nimport { isEventInside } from '../../utils/insideEvents'\nimport {\n Placement,\n resolveMenuOverlayPositioning,\n toAriaPlacement\n} from '../../utils/overlayPlacement'\nimport { NavOverflowBoundary } from '../../utils/navOverflow'\nimport { pushOverlay } from '../../utils/overlayStack'\nimport {\n createPolymorphicComponent,\n PolymorphicComponentProps,\n PolymorphicRef\n} from '../../utils/polymorphic'\n\nexport type { Placement }\nexport type MenuFocusStrategy = 'first' | 'last'\n\nexport type MenuAutoClose = boolean | 'inside' | 'outside'\n\ntype MenuOwnProps<C extends ElementType> = {\n /**\n * Controls which clicks close the menu. `true` closes on any click inside or outside.\n * `false` leaves closing to the toggle, the Escape key and `visible`. `'inside'` closes only\n * on click inside the menu. `'outside'` closes only on click outside the menu.\n */\n autoClose?: MenuAutoClose\n /**\n * A string of all className you want applied to the base component.\n */\n className?: string\n /**\n * Component used for the root node. Either a string to use a HTML element or a component.\n * Defaults to `Fragment` — `MenuToggle`/`MenuList` render with no wrapping element, so\n * they land as direct children of whatever contains the `Menu`. This matters inside\n * `ButtonGroup`/`InputGroup`, whose CSS expects the toggle button and menu panel as direct\n * children rather than nested inside an intermediate node.\n *\n * Pass an actual element (e.g. `\"div\"`, or `\"li\"` for a navbar item) to opt back into a\n * wrapper — needed if you want to apply `className`/`style`/other rest props to a container\n * around the whole menu, for semantic wrapping like a nav `<li>`, or for `reference=\"parent\"`,\n * which positions off this wrapper and has nothing to measure against without one.\n */\n component?: C\n /**\n * Teleports the menu panel to a container element on open. Accepts an element reference, or\n * `true` to append to `document.body`, or to the open dialog the menu is in, so the panel\n * stays in that dialog's top layer.\n */\n container?: boolean | Element\n /**\n * Whether the menu is open when it first renders. Use it instead of `visible` when nothing\n * outside needs to control the menu.\n */\n defaultVisible?: boolean\n /**\n * Distance between the menu and its reference element, as `[skidding, distance]` in pixels.\n */\n offset?: [number, number]\n /**\n * Callback fired when the menu starts to hide.\n */\n onHide?: () => void\n /**\n * Callback fired after the menu finishes hiding.\n */\n onHidden?: () => void\n /**\n * Callback fired when the menu starts to show.\n */\n onShow?: () => void\n /**\n * Callback fired after the menu finishes showing.\n */\n onShown?: () => void\n /**\n * Callback fired when the menu asks to show or hide: the toggle, a click that `autoClose`\n * counts, or the Escape or Tab key. Receives the state it asks for. With `visible` set, the\n * menu changes only when `visible` does.\n */\n onVisibleChange?: (visible: boolean) => void\n /**\n * Initial placement. Chassis will flip it to keep the menu in view.\n *\n * @type 'top' | 'top-start' | 'top-end' | 'bottom' | 'bottom-start' | 'bottom-end' | 'left' | 'left-start' | 'left-end' | 'right' | 'right-start' | 'right-end'\n */\n placement?: Placement\n /**\n * Reference element used for positioning. `'toggle'` uses the trigger. `'parent'` uses this\n * component's own rendered element, useful for split buttons and button groups.\n */\n reference?: 'toggle' | 'parent'\n /**\n * Whether the menu is open. Setting it makes the menu controlled: it opens and closes only\n * when this changes, so pair it with `onVisibleChange`. Leave it unset, or use\n * `defaultVisible`, for a menu that opens and closes itself.\n */\n visible?: boolean\n}\n\nexport type MenuProps<C extends ElementType = typeof Fragment> = PolymorphicComponentProps<\n C,\n MenuOwnProps<C>\n>\n\ntype MenuComponent = (<C extends ElementType = typeof Fragment>(\n props: MenuProps<C> & { ref?: PolymorphicRef<C> }\n) => ReactElement | null) & { displayName?: string }\n\nexport interface MenuContextProps {\n autoClose: MenuAutoClose\n close: () => void\n container?: boolean | Element\n focusStrategy: MenuFocusStrategy | null\n hide: () => void\n menuId: string\n menuStyle: React.CSSProperties\n menuTriggerProps: AriaButtonProps\n overlayRef: React.MutableRefObject<HTMLElement | null>\n placementAttr: string\n /**\n * The open dialog the menu is in, or `document.body`; `null` until the menu first opens. A\n * `MenuSubmenu` portals its panel there, so inside a modal dialog it is in the top layer with\n * the menu rather than under it, where the page is inert.\n */\n portalContainer?: Element | null\n reference: 'toggle' | 'parent'\n /**\n * Registers (or, passing `null`, unregisters) a nested `MenuSubmenu`'s own portaled panel\n * element, so this `Menu`'s outside/inside click-dismiss logic recognizes clicks landing in it\n * as \"inside\" the menu — see `MenuSubmenu`'s own use for why this is necessary: its panel\n * portals straight to `document.body`, structurally detached from this menu's own DOM subtree.\n */\n registerOverlay: (id: string, node: HTMLElement | null) => void\n show: (focusStrategy?: MenuFocusStrategy | null) => void\n targetRef: React.MutableRefObject<HTMLElement | null>\n toggle: (focusStrategy?: MenuFocusStrategy | null) => void\n toggleNodeRef: React.MutableRefObject<HTMLElement | null>\n triggerId: string\n visible: boolean\n}\n\n// A fully-shaped no-op default so a `MenuToggle`/`MenuList`/`MenuSubmenu` rendered without a\n// `Menu` ancestor (or in an environment where context can't cross a component boundary, e.g.\n// some static-site prerenderers) degrades to an inert, always-closed menu instead of throwing.\nconst noop = () => undefined\n\nconst defaultMenuContext: MenuContextProps = {\n autoClose: true,\n close: noop,\n focusStrategy: null,\n hide: noop,\n menuId: '',\n menuStyle: {},\n menuTriggerProps: {},\n overlayRef: { current: null },\n placementAttr: 'bottom-start',\n reference: 'toggle',\n registerOverlay: noop,\n show: noop,\n targetRef: { current: null },\n toggle: noop,\n toggleNodeRef: { current: null },\n triggerId: '',\n visible: false\n}\n\nexport const MenuContext = createContext(defaultMenuContext)\n\n// The clicks on a `MenuToggle` or a `MenuSubmenu` trigger. One in a menu's list opens a menu of\n// its own: it is no click on an item of that list.\nexport const menuToggleClicks = new WeakSet<Event>()\n\n// The outside-click handlers of the open menus. react-aria's press handling stops the click on a\n// `MenuToggle` before it reaches `window`, where those handlers listen, so another menu stayed open\n// beside the one the click opened: the toggle hands its click to each of them itself.\nexport const openMenuDismissals = new Set<(event: Event) => void>()\n\nfunction MenuRender<C extends ElementType = typeof Fragment>(\n {\n children,\n autoClose = true,\n className,\n component,\n container,\n defaultVisible,\n offset: offsetProp = [0, 2],\n onHide,\n onHidden,\n onShow,\n onShown,\n onVisibleChange,\n placement = 'bottom-start',\n reference = 'toggle',\n visible,\n ...rest\n }: MenuProps<C>,\n ref: PolymorphicRef<C>\n) {\n const Component = component ?? (Fragment as ElementType)\n const wrapperRef = useRef<HTMLElement>(null)\n const forkedRef = useForkedRef(ref, wrapperRef)\n const toggleNodeRef = useRef<HTMLElement | null>(null)\n const targetRef = useRef<HTMLElement | null>(null)\n const overlayRef = useRef<HTMLElement | null>(null)\n // Portaled `MenuSubmenu` panels register themselves here (see `registerOverlay` below and\n // `MenuSubmenu`'s own ref callback) so `handleDismiss` can recognize clicks inside them as\n // \"inside\" this menu despite living outside `overlayRef.current`'s own DOM subtree.\n const submenuOverlaysRef = useRef<Map<string, HTMLElement>>(new Map())\n const registerOverlay = (id: string, node: HTMLElement | null) => {\n if (node) submenuOverlaysRef.current.set(id, node)\n else submenuOverlaysRef.current.delete(id)\n }\n\n // Controlled by `visible` when it is set: `show`/`hide`/`toggle` (from `MenuToggle`, autoClose\n // dismissal, an item) then only report to `onVisibleChange`.\n const state = useMenuTriggerState(\n useOpenStateProps({ defaultVisible, onVisibleChange, visible }, 'Menu')\n )\n const { menuTriggerProps, menuProps } = useMenuTrigger<unknown>({}, state, toggleNodeRef)\n\n useIsomorphicLayoutEffect(() => {\n if (reference === 'parent') {\n targetRef.current = wrapperRef.current\n }\n }, [reference])\n\n // `onShown`/`onHidden` wait for chassis-css's own opacity/transform transition on `.menu`\n // (see `_menu.scss`) to actually finish, matching `Modal`'s identically-worded \"requests to\n // be shown\" vs \"finishes showing\" contract (`Modal.tsx`'s own `executeAfterTransition` use).\n // `overlayRef.current` is `MenuList`'s root element — already in the DOM and already\n // reflecting the new `.show` class by the time this effect runs, since React commits the\n // render before passive effects execute. Falls back to firing synchronously when no\n // `MenuList` is mounted to measure (nothing to transition, so nothing to wait for).\n //\n // All four report *transitions*, so none fires for the initial commit — mounting closed is not\n // a hide. Without this guard, mounting fired `onHide` (and scheduled `onHidden`) for every menu\n // on the page before `onShow` had ever fired once, which `Menu.spec.tsx` used to have to\n // `mockClear()` past.\n const mountedRef = useRef(false)\n\n useEffect(() => {\n const overlay = overlayRef.current\n const isInitialCommit = !mountedRef.current\n mountedRef.current = true\n if (isInitialCommit) return undefined\n\n if (state.isOpen) {\n onShow?.()\n if (!overlay) {\n onShown?.()\n return undefined\n }\n return executeAfterTransition(overlay, () => onShown?.(), true)\n }\n\n onHide?.()\n if (!overlay) {\n onHidden?.()\n return undefined\n }\n return executeAfterTransition(overlay, () => onHidden?.(), true)\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [state.isOpen])\n\n const {\n overlayProps,\n placement: resolvedPlacement,\n updatePosition\n } = useOverlayPosition({\n targetRef,\n overlayRef,\n placement: toAriaPlacement(placement),\n offset: offsetProp[1],\n crossOffset: offsetProp[0],\n containerPadding: 8,\n isOpen: state.isOpen,\n // `useOverlayPosition` closes on any window scroll via a backward-compat `WeakMap` that\n // `useMenuTrigger` populates for `targetRef.current` (see `MenuToggle`'s `setRefs`).\n // Passing `null` opts out so the menu repositions with its trigger instead of vanishing —\n // matching `Autocomplete`/`Combobox`, neither of which is wired into that map.\n onClose: null\n })\n useOverlayMaxHeight(overlayRef, state.isOpen)\n\n const { menuStyle, placementAttr } = resolveMenuOverlayPositioning(\n overlayProps.style,\n placement,\n resolvedPlacement\n )\n\n // Escape closes the menu and returns focus to the toggle. Controlled, the close is a request:\n // focus returns when `visible` follows it, in the effect below, and stays where it is when\n // nothing can follow it or the caller declines. Read through a ref because the context value\n // these functions travel in is memoized.\n const followsRequestsRef = useRef(true)\n followsRequestsRef.current = visible === undefined || !!onVisibleChange\n const isControlledRef = useRef(false)\n isControlledRef.current = visible !== undefined\n const focusReturnOwedRef = useRef(false)\n\n const show = (focusStrategy?: MenuFocusStrategy | null) => state.open(focusStrategy)\n const hide = () => {\n focusReturnOwedRef.current = false\n state.close()\n }\n const toggleVisible = (focusStrategy?: MenuFocusStrategy | null) => state.toggle(focusStrategy)\n const close = () => {\n state.close()\n if (!isControlledRef.current) toggleNodeRef.current?.focus()\n else focusReturnOwedRef.current = followsRequestsRef.current\n }\n\n useEffect(() => {\n if (!state.isOpen && focusReturnOwedRef.current) toggleNodeRef.current?.focus()\n focusReturnOwedRef.current = false\n }, [state.isOpen])\n\n // The open dialog the toggle is in, if any, as `Popover` and `ContextMenu` resolve it: a list\n // teleported by `container` goes into that dialog rather than `document.body`, which lies\n // under a modal dialog's top layer, and the menu closes when the dialog does, teleported or\n // not, so a reopened dialog doesn't show a menu left open. `onShow`/`onHide` stay with the\n // effect above.\n const portalContainer = useFloatingOverlay({\n close: hide,\n isOpen: state.isOpen,\n triggerRef: toggleNodeRef\n })\n\n // The list is mounted again when it moves into the dialog, as a new element in another\n // containing block: placed again here, after its ref is set and before the paint.\n useIsomorphicLayoutEffect(() => {\n if (state.isOpen) updatePosition()\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [portalContainer])\n\n // Deferred so the click that opened the menu doesn't immediately close it, and scoped\n // to match menu.js's `clearMenus`: skip the toggle itself, honor `inside`/`outside`\n // modes, and let Tab or clicks on form controls inside the menu pass through untouched.\n useEffect(() => {\n if (!state.isOpen || autoClose === false) return undefined\n\n // A toggle's click can come both ways: from the toggle, and on `window` when nothing stopped it.\n const handled = new WeakSet<Event>()\n const handleDismiss = (event: Event) => {\n if (event instanceof KeyboardEvent && event.key !== 'Tab') return\n if (handled.has(event)) return\n handled.add(event)\n\n const target = event.target as Node\n const toggleNode = toggleNodeRef.current\n const menuNode = overlayRef.current\n\n if (toggleNode?.contains(target)) return\n\n const isMenuTarget =\n !!menuNode?.contains(target) ||\n Array.from(submenuOverlaysRef.current.values()).some((node) => node.contains(target))\n\n // An overlay opened from the menu (a popover on an item, a picker's list) is portaled out\n // of the list, and React still renders it under it (`insideEvents`). A click there is\n // neither a click on an item nor one outside the menu: it is that overlay's.\n if (!isMenuTarget && isEventInside(event, overlayRef)) return\n if (isMenuTarget && menuToggleClicks.has(event)) return\n\n if (autoClose === 'inside' && !isMenuTarget) return\n if (autoClose === 'outside' && isMenuTarget) return\n\n if (\n isMenuTarget &&\n ((event instanceof KeyboardEvent && event.key === 'Tab') ||\n /input|select|option|textarea|form/i.test((target as HTMLElement).tagName ?? ''))\n ) {\n return\n }\n\n // An item chosen returns focus to the toggle, as Escape does: the closed list is\n // `display: none`, and focus on an item in it fell to `<body>`. Only while the menu holds\n // focus, or nothing does: an item that opened a dialog has moved it there. A click outside\n // or Tab has put focus where it is going already.\n const active = document.activeElement\n const holdsFocus =\n !active ||\n active === document.body ||\n !!menuNode?.contains(active) ||\n Array.from(submenuOverlaysRef.current.values()).some((node) => node.contains(active))\n if (isMenuTarget && holdsFocus) close()\n else hide()\n }\n\n const id = window.setTimeout(() => {\n window.addEventListener('click', handleDismiss)\n window.addEventListener('keyup', handleDismiss)\n openMenuDismissals.add(handleDismiss)\n })\n\n return () => {\n window.clearTimeout(id)\n window.removeEventListener('click', handleDismiss)\n window.removeEventListener('keyup', handleDismiss)\n openMenuDismissals.delete(handleDismiss)\n }\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [state.isOpen, autoClose])\n\n // Escape should always close the menu, independent of `autoClose`'s inside/outside/false\n // modes. `MenuList`'s own `onKeyDown` handling only fires when focus is already inside the\n // panel (e.g. opened via ArrowDown) — a mouse-press open via `useMenuTrigger` leaves focus on\n // the trigger button, where that handler is unreachable. The stack of open overlays listens on\n // `window`, which catches Escape regardless of where focus currently is, and gives it to this\n // menu only while nothing opened since is still open, and never to the popover or the dialog\n // around the menu as well.\n useEffect(() => {\n if (!state.isOpen) return undefined\n\n return pushOverlay({\n nodes: () => [overlayRef.current, toggleNodeRef.current],\n onEscape: close\n })\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [state.isOpen])\n\n const contextValue: MenuContextProps = useMemo(\n () => ({\n autoClose,\n close,\n container: container === true ? (portalContainer ?? true) : container,\n focusStrategy: state.focusStrategy as MenuFocusStrategy | null,\n hide,\n menuId: menuProps.id ?? '',\n menuStyle,\n menuTriggerProps,\n overlayRef,\n placementAttr,\n portalContainer,\n reference,\n registerOverlay,\n show,\n targetRef,\n toggle: toggleVisible,\n toggleNodeRef,\n triggerId: menuTriggerProps.id ?? '',\n visible: state.isOpen\n }),\n // eslint-disable-next-line react-hooks/exhaustive-deps\n [\n autoClose,\n container,\n state.focusStrategy,\n menuProps.id,\n menuStyle,\n menuTriggerProps,\n placementAttr,\n portalContainer,\n reference,\n state.isOpen\n ]\n )\n\n // Inside a `NavOverflow`, a menu in a nav item is that item's content, not its link: a toggle\n // rendered as a `NavLink` has nothing to show in the overflow menu.\n const content = <NavOverflowBoundary>{children}</NavOverflowBoundary>\n\n return (\n <MenuContext.Provider value={contextValue}>\n {Component === Fragment ? (\n content\n ) : (\n // `show` mirrors vanilla menu.js's `this._parent.classList.add('show')` — needed for\n // e.g. `.nav-item.show .nav-link` to put a `NavLink`-rooted `MenuToggle` into its\n // pressed look while open, since a bare `.nav-link.show` has no styling of its own.\n <Component\n className={classNames(className, { show: state.isOpen })}\n {...rest}\n ref={forkedRef}\n >\n {content}\n </Component>\n )}\n </MenuContext.Provider>\n )\n}\n\nexport const Menu = createPolymorphicComponent<MenuComponent>(\n MenuRender as ForwardRefRenderFunction<Element, MenuProps<ElementType>>,\n 'Menu'\n)\n"],"mappings":"A,kyBAsKA,MAAMa,MAAa,IAAA,GAsBNC,EAAcC,EAAc,CAnBvC,UAAW,GACX,MAAOF,EACP,cAAe,KACf,KAAMA,EACN,OAAQ,GACR,UAAW,CAAC,EACZ,iBAAkB,CAAC,EACnB,WAAY,CAAE,QAAS,IAAK,EAC5B,cAAe,eACf,UAAW,SACX,gBAAiBA,EACjB,KAAMA,EACN,UAAW,CAAE,QAAS,IAAK,EAC3B,OAAQA,EACR,cAAe,CAAE,QAAS,IAAK,EAC/B,UAAW,GACX,QAAS,EAG8B,CAAkB,EAI9CG,kBAAmB,IAAI,QAKvBC,kBAAqB,IAAI,IAEtC,SAASC,EACP,CACE,WACA,YAAY,GACZ,YACA,YACA,YACA,iBACA,OAAQC,EAAa,CAAC,EAAG,CAAC,EAC1B,UACA,WACA,UACA,UACA,kBACA,YAAY,eACZ,YAAY,SACZ,UACA,GAAGC,IAEL,GACA,CACA,IAAMC,EAAYC,GAAcC,EAC1BC,EAAaC,EAAoB,IAAI,EACrCC,GAAY1B,EAAa2B,GAAKH,CAAU,EACxCI,EAAgBH,EAA2B,IAAI,EAC/CI,EAAYJ,EAA2B,IAAI,EAC3CK,EAAaL,EAA2B,IAAI,EAI5CM,EAAqBN,kBAAiC,IAAI,GAAK,EAC/DO,GAAmB,EAAY,IAA6B,CAC5DC,EAAMF,EAAmB,QAAQ,IAAIG,EAAID,CAAI,EAC5CF,EAAmB,QAAQ,OAAOG,CAAE,CAC3C,EAIMC,EAAQC,EACZ/B,EAAkB,CAAE,iBAAgB,kBAAiB,SAAQ,EAAG,MAAM,CACxE,EACM,CAAE,mBAAkB,aAAcgC,GAAwB,CAAC,EAAGF,EAAOP,CAAa,EAExF3B,MAAgC,CAC1BqC,IAAc,WAChB,EAAU,QAAU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qMqsWE.js";import{t as a}from"./polymorphic-CZIFszAy.js";import{t as o}from"./useHydrated-Dud4JEwp.js";import{t as s}from"./renderMenuItemContent-DNdj-Ukz.js";import{t as c}from"./Portal-BTDylxAi.js";import{t as l}from"./Link-DE8NSAXJ.js";import{t as u}from"./Button-ZU-x1uN_.js";import{t as d}from"./insideEvents-CWcNrMu7.js";import{i as f,n as p,r as m}from"./Menu-BiE9CzNk.js";import h,{createContext as g,forwardRef as _,useContext as v,useEffect as y,useRef as b}from"react";import x from"classnames";import{mergeProps as S,useButton as C}from"react-aria";const w=_(({className:e,...t},n)=>{let r=x(`menu-divider`,e);return/* @__PURE__ */ h.createElement(`hr`,{className:r,...t,ref:n})});w.displayName=`MenuDivider`;function T({children:e,className:t,component:n,role:r=`presentation`,...i},a){let o=n??`h4`,s=x(`menu-header`,t);return/* @__PURE__ */ h.createElement(o,{className:s,role:r,...i,ref:a},e)}const E=a(T,`MenuHeader`);function D({children:e,className:t,component:r,description:i,href:a,icon:o,onClick:c,selected:u,...d},f){let p=x(`menu-item`,{selected:u},t);return/* @__PURE__ */ h.createElement(l,{role:`menuitem`,component:n(r,a,`button`),href:a,onClick:e=>{a===`#`&&e.preventDefault(),c?.(e)},...d,className:p,ref:f},s({icon:o,label:e,description:i}))}const O=a(D,`MenuItem`),k=`:is(.menu-item, .submenu-back):not(.disabled):not(:disabled)`,A=e=>!!(e.offsetWidth||e.offsetHeight||e.getClientRects().length),j=e=>{if(!e)return[];let t=[];for(let n of Array.from(e.children))if(n.matches(k))t.push(n);else if(n.classList.contains(`submenu`)){let e=Array.from(n.children).find(e=>e.matches(k));e&&t.push(e)}return t.filter(A)},M=(e,t)=>{e.length&&(t===`first`?e[0]:e[e.length-1]).focus()},N=(e,{onArrowLeft:t,onArrowRight:n,onEscape:r})=>{let i=e.currentTarget,a=e.target;switch(e.key){case`ArrowDown`:case`ArrowUp`:{e.preventDefault(),e.stopPropagation();let t=j(i);if(!t.length)return;let n=t.indexOf(a);t[n===-1?e.key===`ArrowDown`?0:t.length-1:(n+(e.key===`ArrowDown`?1:-1)+t.length)%t.length].focus();return}case`Home`:case`End`:e.preventDefault(),e.stopPropagation(),M(j(i),e.key===`Home`?`first`:`last`);return;case`Escape`:if(!r)return;e.preventDefault(),e.stopPropagation(),r();return;case`ArrowLeft`:if(!t)return;e.preventDefault(),e.stopPropagation(),t();return;case`ArrowRight`:if(!n)return;e.preventDefault(),e.stopPropagation(),n();return}},P=g(null),F=()=>{let e=b(null);if(!e.current){let t=/* @__PURE__ */ new Map;e.current={register:(e,n)=>(t.set(e,n),()=>{t.delete(e)}),notifyOpen:e=>{t.forEach((t,n)=>{n!==e&&t()})}}}return e.current},I=g(null),L=g(!0),R=e=>e.type===`header`?/* @__PURE__ */ h.createElement(E,{key:e.id},e.label):e.type===`divider`?/* @__PURE__ */ h.createElement(w,{key:e.id}):/* @__PURE__ */ h.createElement(O,{key:e.id,href:e.href,disabled:e.disabled,selected:e.selected,onClick:e.onClick},s({icon:e.icon,label:e.label,description:e.description,selected:e.selected}));function z({children:e,className:t,component:n,items:r,onKeyDown:a,...s},l){let u=n??`div`,{close:f,container:m,focusStrategy:g,menuId:_,menuStyle:b,overlayRef:C,placementAttr:w,triggerId:T,visible:E}=v(p),D=i(l,C),O=F(),k=o(),A=E&&k;y(()=>{E&&g&&M(j(C.current),g===`last`?`last`:`first`)},[E,g]);let I=e=>{N(e,{onEscape:f}),a?.(e)},L=s[`aria-label`]?void 0:T||void 0,z=/* @__PURE__ */ h.createElement(u,{role:`menu`,id:_,"aria-labelledby":L,className:x(`menu`,{show:A},t),style:b,"data-cx-placement":w,...S(s,d(C)),onKeyDown:I,ref:D},/* @__PURE__ */ h.createElement(P.Provider,{value:O},r?r.map(R):e));return m?/* @__PURE__ */ h.createElement(c,{container:m===!0?void 0:m},z):z}const B=a(z,`MenuList`);function V({children:n,caret:a=!0,className:o,component:s,href:c,onClick:l,onKeyDown:d,tabIndex:g,..._},y){let{hide:w,menuTriggerProps:T,reference:E,targetRef:D,toggleNodeRef:O,visible:k}=v(p),A=s??u,j=b(null),M=A===u?e(c)?`anchor`:`button`:r(A,c,_),N=M===`button`,P=A===u?{href:c}:t(M,c,`MenuToggle`),{buttonProps:F}=C({...T,elementType:N?`button`:`a`},j),I=b(!1),L=i(y,e=>{j.current=e,O.current=e,E!==`parent`&&(D.current=e)}),R=e=>{I.current=e.pointerType!==`touch`&&k},z=e=>{e.preventDefault(),m.add(e.nativeEvent);for(let t of[...f])t(e.nativeEvent);I.current&&(I.current=!1,w()),l?.(e)};return/* @__PURE__ */ h.createElement(A,{...N?{type:`button`}:{},className:x({caret:a,show:k},o),...S({onPointerDown:R},_,F,{onClick:z,onKeyDown:d,...g!==void 0&&{tabIndex:g}}),...P,ref:L},n)}const H=a(V,`MenuToggle`);export{L as a,j as c,E as d,w as f,P as i,N as l,B as n,F as o,I as r,M as s,H as t,O as u};
|
|
2
|
-
//# sourceMappingURL=MenuToggle-W-ZSHFwF.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"MenuToggle-W-ZSHFwF.js","names":["hasHref","hrefProps","linkElement","resolveLinkKind","useForkedRef","createPolymorphicComponent","useHydrated","renderMenuItemContent","Portal","Link","Button","insideEventProps","openMenuDismissals","MenuContext","menuToggleClicks","React","classNames","MenuDivider","forwardRef","rest","_className","className","MenuHeaderRender","Component","component","children","MenuHeader","MenuItemRender","href","event","onClick","MenuItem","VISIBLE_ITEMS_SELECTOR","isVisible","element","getMenuItems","menu","items","child","trigger","grandchild","focusMenuItem","target","handleMenuKeyDown","currentIndex","onEscape","onArrowLeft","onArrowRight","SubmenuGroupContext","createContext","useSubmenuGroupProvider","ref","useRef","closers","id","close","key","SubmenuActionsContext","SubmenuVisibleContext","renderMenuItemDef","def","MenuListRender","useContext","forkedRef","overlayRef","submenuGroup","hydrated","shown","visible","useEffect","focusStrategy","handleKeyDown","onKeyDown","labelledBy","triggerId","content","menuId","menuStyle","placementAttr","mergeProps","container","MenuList","MenuToggleRender","buttonRef","kind","rendersButton","linkProps","useButton","menuTriggerProps","wasOpenRef","node","reference","handlePointerDown","handleClick","dismiss","hide","buttonProps","tabIndex","MenuToggle"],"sources":["../../src/components/menu/MenuDivider.tsx","../../src/components/menu/MenuHeader.tsx","../../src/components/menu/MenuItem.tsx","../../src/components/menu/menuNavigation.ts","../../src/components/menu/submenuGroup.ts","../../src/components/menu/MenuList.tsx","../../src/components/menu/MenuToggle.tsx"],"sourcesContent":["import React, { forwardRef, HTMLAttributes } from 'react'\nimport classNames from 'classnames'\n\nexport interface MenuDividerProps extends HTMLAttributes<HTMLHRElement> {\n /**\n * A string of all className you want applied to the component.\n */\n className?: string\n}\n\nexport const MenuDivider = forwardRef<HTMLHRElement, MenuDividerProps>(\n ({ className, ...rest }, ref) => {\n const _className = classNames('menu-divider', className)\n\n return <hr className={_className} {...rest} ref={ref} />\n }\n)\n\nMenuDivider.displayName = 'MenuDivider'\n","import React, { ElementType, ForwardRefRenderFunction, ReactElement } from 'react'\nimport classNames from 'classnames'\n\nimport {\n createPolymorphicComponent,\n PolymorphicComponentProps,\n PolymorphicRef\n} from '../../utils/polymorphic'\n\ntype MenuHeaderOwnProps<C extends ElementType> = {\n /**\n * A string of all className you want applied to the component.\n */\n className?: string\n /**\n * Component used for the root node. Either a string to use a HTML element or a component.\n */\n component?: C\n /**\n * ARIA role applied to the root node. Defaults to `'presentation'` — see the render function\n * for why.\n */\n role?: React.AriaRole\n}\n\nexport type MenuHeaderProps<C extends ElementType = 'h4'> = PolymorphicComponentProps<\n C,\n MenuHeaderOwnProps<C>\n>\n\ntype MenuHeaderComponent = (<C extends ElementType = 'h4'>(\n props: MenuHeaderProps<C> & { ref?: PolymorphicRef<C> }\n) => ReactElement | null) & { displayName?: string }\n\nfunction MenuHeaderRender<C extends ElementType = 'h4'>(\n { children, className, component, role = 'presentation', ...rest }: MenuHeaderProps<C>,\n ref: PolymorphicRef<C>\n) {\n const Component = component ?? 'h4'\n const _className = classNames('menu-header', className)\n\n // Always rendered as a direct child of `role=\"menu\"` (see MenuList) — ARIA's menu role only\n // permits menuitem/group/separator children, so a bare heading fails aria-required-children.\n // `role=\"presentation\"` opts the element itself out without hiding its text content.\n return (\n <Component className={_className} role={role} {...rest} ref={ref}>\n {children}\n </Component>\n )\n}\n\nexport const MenuHeader = createPolymorphicComponent<MenuHeaderComponent>(\n MenuHeaderRender as ForwardRefRenderFunction<Element, MenuHeaderProps<ElementType>>,\n 'MenuHeader'\n)\n","import React, {\n ElementType,\n ForwardRefRenderFunction,\n MouseEvent,\n ReactElement,\n ReactNode\n} from 'react'\nimport classNames from 'classnames'\n\nimport { linkElement } from '../../utils/elementKind'\nimport {\n createPolymorphicComponent,\n PolymorphicRef,\n PolymorphicRefWithFallback\n} from '../../utils/polymorphic'\nimport { renderMenuItemContent } from './renderMenuItemContent'\nimport { LinkProps, Link } from '../link/Link'\n\ntype MenuItemOwnProps = {\n /**\n * A string of all className you want applied to the component.\n */\n className?: string\n /**\n * Secondary line of text rendered below `children` (`.menu-item-description`).\n */\n description?: ReactNode\n /**\n * Icon rendered at the item's leading edge (`.menu-item-icon`).\n */\n icon?: ReactNode\n /**\n * Marks the item as the current selection in a choice list. Renders in a heavier font weight.\n * Combine with a manually-composed `.menu-item-check` icon (in `children`, or via `icon` on a\n * plain, non-selection item) to also show a checkmark — this prop alone doesn't add one, so\n * existing font-weight-only usage keeps rendering unchanged.\n */\n selected?: boolean\n}\n\nexport type MenuItemProps<C extends ElementType = 'a'> = LinkProps<C> & MenuItemOwnProps\n\ntype MenuItemComponent = (<C extends ElementType = 'a'>(\n props: MenuItemProps<C> & {\n ref?: PolymorphicRefWithFallback<C, HTMLAnchorElement | HTMLButtonElement>\n }\n) => ReactElement | null) & { displayName?: string }\n\nfunction MenuItemRender<C extends ElementType = 'a'>(\n {\n children,\n className,\n component,\n description,\n href,\n icon,\n onClick,\n selected,\n ...rest\n }: MenuItemProps<C>,\n ref: PolymorphicRef<C>\n) {\n const _className = classNames('menu-item', { selected }, className)\n\n // `href=\"#\"` is a common placeholder for menu items that act via `onClick` rather than\n // real navigation. Left alone, a plain anchor click still navigates to the empty fragment,\n // which scrolls the page to the top — so we suppress that default for the placeholder case\n // only, leaving real same-page anchors (`href=\"#some-id\"`) free to navigate as expected.\n const handleClick = (event: MouseEvent<HTMLAnchorElement | HTMLButtonElement>) => {\n if (href === '#') event.preventDefault()\n onClick?.(event)\n }\n\n // An item with `href` is an `<a>`, one without is a `<button type=\"button\">`, unless `component`\n // or `asChild` chose the element (see `linkElement`). chassis-css styles both as `.menu-item`.\n // An item without `href` used to be an `<a>` with no `href`, which isn't focusable, so keyboard\n // users couldn't reach it outside the menu's own arrow-key handling.\n return (\n <Link\n role=\"menuitem\"\n component={linkElement(component as ElementType | undefined, href, 'button')}\n href={href}\n onClick={handleClick}\n {...(rest as Record<string, unknown>)}\n className={_className}\n ref={ref as PolymorphicRef<ElementType>}\n >\n {renderMenuItemContent({ icon, label: children, description })}\n </Link>\n )\n}\n\nexport const MenuItem = createPolymorphicComponent<MenuItemComponent>(\n MenuItemRender as ForwardRefRenderFunction<Element, MenuItemProps<ElementType>>,\n 'MenuItem'\n)\n","import React from 'react'\n\n// Mirrors Chassis CSS's menu.js SELECTOR_VISIBLE_ITEMS / SELECTOR_KB_NAV_ITEMS: direct-child\n// menu items and submenu-back buttons, plus submenu trigger items nested one level inside a\n// `.submenu` wrapper (which aren't direct children of the `.menu`).\n//\n// Walks `children` directly rather than a `:scope`-based `querySelectorAll` — jsdom's selector\n// engine (nwsapi) mis-parses `:scope` queries against an element whose `id` contains a colon,\n// which is exactly the shape of React 18's default `useId()` output now that `MenuList`/\n// `MenuSubmenu` set a real `id` for `aria-controls`/`aria-labelledby` linking. Real browsers don't\n// have this bug, but walking children is just as correct and sidesteps it either way.\nconst VISIBLE_ITEMS_SELECTOR = ':is(.menu-item, .submenu-back):not(.disabled):not(:disabled)'\n\nconst isVisible = (element: HTMLElement) =>\n Boolean(element.offsetWidth || element.offsetHeight || element.getClientRects().length)\n\nexport const getMenuItems = (menu: HTMLElement | null): HTMLElement[] => {\n if (!menu) return []\n const items: HTMLElement[] = []\n for (const child of Array.from(menu.children)) {\n if (child.matches(VISIBLE_ITEMS_SELECTOR)) {\n items.push(child as HTMLElement)\n } else if (child.classList.contains('submenu')) {\n const trigger = Array.from(child.children).find((grandchild) =>\n grandchild.matches(VISIBLE_ITEMS_SELECTOR)\n )\n if (trigger) items.push(trigger as HTMLElement)\n }\n }\n return items.filter(isVisible)\n}\n\nexport const focusMenuItem = (items: HTMLElement[], target: 'first' | 'last') => {\n if (!items.length) return\n ;(target === 'first' ? items[0]! : items[items.length - 1]!).focus()\n}\n\nexport interface MenuKeyDownOptions {\n onArrowLeft?: () => void\n onArrowRight?: () => void\n onEscape?: () => void\n}\n\n// Scoped to `event.currentTarget` (the `.menu` element the handler is bound to), so the same\n// function drives keyboard navigation for both the top-level menu and any nested submenu list.\n// `onArrowLeft`/`onArrowRight` are both optional and independent (rather than a single\n// direction-agnostic \"close\" callback) so a caller under an RTL locale can wire the one that\n// actually points back toward the trigger — see `MenuSubmenu`, the only current consumer of\n// either.\nexport const handleMenuKeyDown = (\n event: React.KeyboardEvent<HTMLElement>,\n { onArrowLeft, onArrowRight, onEscape }: MenuKeyDownOptions\n): void => {\n const menu = event.currentTarget\n const target = event.target as HTMLElement\n\n switch (event.key) {\n case 'ArrowDown':\n case 'ArrowUp': {\n event.preventDefault()\n event.stopPropagation()\n const items = getMenuItems(menu)\n if (!items.length) return\n const currentIndex = items.indexOf(target)\n const nextIndex =\n currentIndex === -1\n ? event.key === 'ArrowDown'\n ? 0\n : items.length - 1\n : (currentIndex + (event.key === 'ArrowDown' ? 1 : -1) + items.length) % items.length\n // `nextIndex` is always a valid index into `items` here (0, items.length - 1, or a modulo\n // result — the `if (!items.length) return` above already ruled out the empty-array case).\n items[nextIndex]!.focus()\n return\n }\n case 'Home':\n case 'End': {\n event.preventDefault()\n event.stopPropagation()\n focusMenuItem(getMenuItems(menu), event.key === 'Home' ? 'first' : 'last')\n return\n }\n case 'Escape': {\n if (!onEscape) return\n event.preventDefault()\n event.stopPropagation()\n onEscape()\n return\n }\n case 'ArrowLeft': {\n if (!onArrowLeft) return\n event.preventDefault()\n event.stopPropagation()\n onArrowLeft()\n return\n }\n case 'ArrowRight': {\n if (!onArrowRight) return\n event.preventDefault()\n event.stopPropagation()\n onArrowRight()\n return\n }\n default:\n }\n}\n","import { createContext, useRef } from 'react'\n\n// Lets sibling `.submenu` flyouts at the same menu level close one another when a new one\n// opens, mirroring menu.js's `_closeSiblingSubmenus`. One provider instance is created per\n// menu level (the top-level `.menu` and each `.submenu`'s own nested list) and lives for the\n// lifetime of that level, so registration doesn't churn on every render.\nexport interface SubmenuGroupContextValue {\n register: (id: string, close: () => void) => () => void\n notifyOpen: (id: string) => void\n}\n\nexport const SubmenuGroupContext = createContext<SubmenuGroupContextValue | null>(null)\n\nexport const useSubmenuGroupProvider = (): SubmenuGroupContextValue => {\n const ref = useRef<SubmenuGroupContextValue | null>(null)\n\n if (!ref.current) {\n const closers = new Map<string, () => void>()\n ref.current = {\n register: (id, close) => {\n closers.set(id, close)\n return () => {\n closers.delete(id)\n }\n },\n notifyOpen: (id) => {\n closers.forEach((close, key) => {\n if (key !== id) close()\n })\n }\n }\n }\n\n return ref.current\n}\n\n// Exposes the current `.submenu`'s own close-and-refocus action to a nested `MenuSubmenuBack`\n// button, without threading it through the sibling-group registry above.\nexport interface SubmenuActionsContextValue {\n close: () => void\n}\n\nexport const SubmenuActionsContext = createContext<SubmenuActionsContextValue | null>(null)\n\n// Whether the `.submenu` a nested `MenuSubmenu` is in is open. A submenu's panel is portaled out\n// of its parent's, so nothing hides it when the parent closes: it follows this, as the first\n// level follows the `Menu` itself. `true` at the top level, where there is no parent submenu.\nexport const SubmenuVisibleContext = createContext(true)\n","import React, {\n ElementType,\n ForwardRefRenderFunction,\n ReactElement,\n ReactNode,\n useContext,\n useEffect\n} from 'react'\nimport classNames from 'classnames'\nimport { mergeProps } from 'react-aria'\n\nimport { useForkedRef } from '../../hooks'\nimport { insideEventProps } from '../../utils/insideEvents'\nimport { renderMenuItemContent } from './renderMenuItemContent'\nimport {\n createPolymorphicComponent,\n PolymorphicComponentProps,\n PolymorphicRef\n} from '../../utils/polymorphic'\nimport { useHydrated } from '../../hooks/useHydrated'\nimport { Portal } from '../portal/Portal'\nimport { MenuContext } from './Menu'\nimport { MenuDivider } from './MenuDivider'\nimport { MenuHeader } from './MenuHeader'\nimport { MenuItem } from './MenuItem'\nimport { MenuItemsDef } from './MenuItemDef'\nimport { focusMenuItem, getMenuItems, handleMenuKeyDown } from './menuNavigation'\nimport { SubmenuGroupContext, useSubmenuGroupProvider } from './submenuGroup'\n\ntype MenuListOwnProps<C extends ElementType> = {\n /**\n * A string of all className you want applied to the base component.\n */\n className?: string\n /**\n * Component used for the root node. Either a string to use a HTML element or a component.\n */\n component?: C\n /**\n * Array of item/header/divider definitions for data-driven rendering. When provided, children\n * are ignored. Covers flat items, headers, and dividers only — for nested submenus, compose\n * with `children` and `MenuSubmenu` instead.\n */\n items?: MenuItemsDef\n}\n\nexport type MenuListProps<C extends ElementType = 'div'> = PolymorphicComponentProps<\n C,\n MenuListOwnProps<C>\n>\n\ntype MenuListComponent = (<C extends ElementType = 'div'>(\n props: MenuListProps<C> & { ref?: PolymorphicRef<C> }\n) => ReactElement | null) & { displayName?: string }\n\nconst renderMenuItemDef = (def: MenuItemsDef[number]): ReactNode => {\n if (def.type === 'header') {\n return <MenuHeader key={def.id}>{def.label}</MenuHeader>\n }\n if (def.type === 'divider') {\n return <MenuDivider key={def.id} />\n }\n return (\n <MenuItem\n key={def.id}\n href={def.href}\n disabled={def.disabled}\n selected={def.selected}\n onClick={def.onClick}\n >\n {renderMenuItemContent({\n icon: def.icon,\n label: def.label,\n description: def.description,\n selected: def.selected\n })}\n </MenuItem>\n )\n}\n\nfunction MenuListRender<C extends ElementType = 'div'>(\n { children, className, component, items, onKeyDown, ...rest }: MenuListProps<C>,\n ref: PolymorphicRef<C>\n) {\n const Component = component ?? 'div'\n const {\n close,\n container,\n focusStrategy,\n menuId,\n menuStyle,\n overlayRef,\n placementAttr,\n triggerId,\n visible\n } = useContext(MenuContext)\n const forkedRef = useForkedRef(ref, overlayRef)\n const submenuGroup = useSubmenuGroupProvider()\n // The list is positioned in a layout effect, which the server never runs: a menu open on its\n // first render was painted at the top left of the page until the JavaScript had loaded. It is\n // shown once hydration has finished, where that effect has placed it.\n const hydrated = useHydrated()\n const shown = visible && hydrated\n\n // ArrowDown/ArrowUp on the trigger opens the menu with a focus strategy (see `Menu`'s\n // `useMenuTrigger` wiring) — this is where that intent actually lands, since we're not\n // adopting `useMenu`'s own collection-aware auto-focus.\n useEffect(() => {\n if (!visible || !focusStrategy) return\n focusMenuItem(getMenuItems(overlayRef.current), focusStrategy === 'last' ? 'last' : 'first')\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [visible, focusStrategy])\n\n const handleKeyDown = (event: React.KeyboardEvent<HTMLElement>) => {\n handleMenuKeyDown(event, { onEscape: close })\n onKeyDown?.(event as React.KeyboardEvent<HTMLDivElement>)\n }\n\n // Labelled by the trigger, unless the caller names the list itself: `aria-labelledby` would\n // outrank that `aria-label`. Left out when there is no trigger to point at (a `ContextMenu`'s\n // region with no id of its own has one; a list rendered with no `Menu` around it has none).\n const ariaLabel = (rest as { 'aria-label'?: string })['aria-label']\n const labelledBy = ariaLabel ? undefined : triggerId || undefined\n\n const content = (\n <Component\n role=\"menu\"\n id={menuId}\n aria-labelledby={labelledBy}\n className={classNames('menu', { show: shown }, className)}\n style={menuStyle}\n data-cx-placement={placementAttr}\n // Marks the events that reach the list through React's tree, for the `Menu` or the\n // `ContextMenu` to tell an overlay opened from an item from the page outside.\n {...(mergeProps(rest, insideEventProps(overlayRef)) as Record<string, unknown>)}\n onKeyDown={handleKeyDown}\n ref={forkedRef}\n >\n <SubmenuGroupContext.Provider value={submenuGroup}>\n {items ? items.map(renderMenuItemDef) : children}\n </SubmenuGroupContext.Provider>\n </Component>\n )\n\n if (container) {\n return <Portal container={container === true ? undefined : container}>{content}</Portal>\n }\n\n return content\n}\n\nexport const MenuList = createPolymorphicComponent<MenuListComponent>(\n MenuListRender as ForwardRefRenderFunction<Element, MenuListProps<ElementType>>,\n 'MenuList'\n)\n","import React, {\n ElementType,\n ForwardRefRenderFunction,\n ReactElement,\n useContext,\n useRef\n} from 'react'\nimport classNames from 'classnames'\nimport { mergeProps, useButton } from 'react-aria'\n\nimport { Button, ButtonProps } from '../button/Button'\nimport { MenuContext, menuToggleClicks, openMenuDismissals } from './Menu'\nimport { ContextColor, Shapes } from '../../types'\nimport {\n createPolymorphicComponent,\n PolymorphicComponentProps,\n PolymorphicRef\n} from '../../utils/polymorphic'\nimport { useForkedRef } from '../../hooks'\nimport { hasHref, hrefProps, resolveLinkKind } from '../../utils/elementKind'\n\ntype MenuToggleOwnProps<C extends ElementType> = {\n /**\n * Toggle the active state for the component.\n */\n active?: boolean\n /**\n * Draws the caret after the toggle's content. Set it to `false` for a toggle that shows what it\n * is another way, such as an icon-only \"more\" button.\n *\n * @default true\n */\n caret?: boolean\n /**\n * A string of all className you want applied to the base component.\n */\n className?: string\n /**\n * Sets the color of the component to one of Chassis context colors. Only applies to the\n * default `Button` root.\n */\n color?: ContextColor\n /**\n * Component used for the root node — the trigger element the menu opens from. Defaults to\n * `Button`; swap for e.g. `NavLink` to render a nav-item-style trigger (`.nav-link.caret`)\n * instead of a `.button.caret`. Its own props are type-checked at the call site once passed\n * here.\n */\n component?: C\n /**\n * Toggle the disabled state for the component.\n */\n disabled?: boolean\n /**\n * The href attribute specifies the URL of the page the link goes to.\n */\n href?: string\n /**\n * Select the shape of the component. Only applies to the default `Button` root.\n */\n shape?: Shapes\n /**\n * Size the component sm or lg. Only applies to the default `Button` root.\n */\n size?: 'sm' | 'lg'\n /**\n * Sets the style variant of the component, as `Button`'s own `variant` does. Only applies to\n * the default `Button` root.\n */\n variant?: ButtonProps['variant']\n}\n\nexport type MenuToggleProps<C extends ElementType = typeof Button> = PolymorphicComponentProps<\n C,\n MenuToggleOwnProps<C>\n>\n\ntype MenuToggleComponent = (<C extends ElementType = typeof Button>(\n props: MenuToggleProps<C> & { ref?: PolymorphicRef<C> }\n) => ReactElement | null) & { displayName?: string }\n\nfunction MenuToggleRender<C extends ElementType = typeof Button>(\n {\n children,\n caret = true,\n className,\n component,\n href,\n onClick,\n onKeyDown,\n tabIndex,\n ...rest\n }: MenuToggleProps<C>,\n ref: PolymorphicRef<C>\n) {\n const { hide, menuTriggerProps, reference, targetRef, toggleNodeRef, visible } =\n useContext(MenuContext)\n const Component = component ?? Button\n const buttonRef = useRef<HTMLButtonElement | null>(null)\n // What the root renders. The default `Button` renders a `<button>`, or an `<a>` given `href`.\n // Anything else is asked, like every polymorphic component asks: `NavLink` is a component\n // reference, and `component=\"button\"` a real `<button>`.\n const kind =\n Component === Button\n ? hasHref(href)\n ? 'anchor'\n : 'button'\n : resolveLinkKind(Component, href, rest)\n const rendersButton = kind === 'button'\n // `Button` applies the `href` rule itself; anything else gets `href` only if it can take one.\n const linkProps = Component === Button ? { href } : hrefProps(kind, href, 'MenuToggle')\n // `elementType` tells react-aria whether the rendered root already has native button\n // semantics or needs them emulated (`role=\"button\"`, keyboard activation).\n const { buttonProps } = useButton(\n { ...menuTriggerProps, elementType: rendersButton ? 'button' : 'a' },\n buttonRef\n )\n const wasOpenRef = useRef(false)\n\n const setRefs = (node: HTMLButtonElement | null) => {\n buttonRef.current = node\n toggleNodeRef.current = node\n if (reference !== 'parent') {\n targetRef.current = node\n }\n }\n\n const forkedRef = useForkedRef(ref, setRefs)\n\n // react-aria's `useMenuTrigger` opens (rather than toggles) on mouse/pen press start, so\n // re-clicking an already-open trigger would otherwise re-open it right back instead of\n // closing it. Capture whether it was open before that happens — ours has to run ahead of\n // `buttonProps`' own `onPointerDown` in the `mergeProps` chain below — then close it back\n // down on click. Touch is exempt: react-aria's `onPress` already toggles it correctly there.\n const handlePointerDown = (event: React.PointerEvent<HTMLButtonElement>) => {\n wasOpenRef.current = event.pointerType !== 'touch' && visible\n }\n\n // Another open menu closes on the click (`openMenuDismissals`), unless this toggle is in its\n // list (`menuToggleClicks`).\n const handleClick = (event: React.MouseEvent<HTMLButtonElement>) => {\n event.preventDefault()\n menuToggleClicks.add(event.nativeEvent)\n for (const dismiss of [...openMenuDismissals]) dismiss(event.nativeEvent)\n if (wasOpenRef.current) {\n wasOpenRef.current = false\n hide()\n }\n onClick?.(event)\n }\n\n return (\n <Component\n // A `<button>` root needs an explicit `type` to avoid an implicit form submit; other roots\n // (e.g. `NavLink`) don't render a `<button>` at all.\n {...(rendersButton ? { type: 'button' } : {})}\n // The `.caret` utility (rather than styling off `[data-cx-toggle=\"menu\"]`, as the vanilla\n // CSS docs show) keeps this element from also matching Chassis CSS's own vanilla menu.js\n // selectors on a page that happens to load both — this component reimplements all of that\n // behavior itself, so there's nothing for the vanilla plugin to usefully do with it anyway.\n // `show` mirrors `MenuList`'s own `{ show: visible }` and vanilla menu.js's\n // `this._element.classList.add('show')` — it's what puts the trigger itself into a\n // pressed look while its menu is open (`.button.show`/`.nav-item.show .nav-link`).\n className={classNames({ caret, show: visible }, className)}\n {...(mergeProps({ onPointerDown: handlePointerDown }, rest, buttonProps, {\n onClick: handleClick,\n onKeyDown,\n // The caller's, when it gives one: react-aria's own `tabIndex` would replace it.\n ...(tabIndex !== undefined && { tabIndex })\n }) as Record<string, unknown>)}\n // After `buttonProps`: for an `<a>`, react-aria returns an `href` of its own, the one it was\n // given, which is none.\n {...linkProps}\n ref={forkedRef}\n >\n {children}\n </Component>\n )\n}\n\nexport const MenuToggle = createPolymorphicComponent<MenuToggleComponent>(\n MenuToggleRender as ForwardRefRenderFunction<Element, MenuToggleProps<ElementType>>,\n 'MenuToggle'\n)\n"],"mappings":"A,ipBAUA,MAAaiB,EAAcC,GACxB,CAAE,YAAW,GAAGC,GAAQ,IAAQ,CAC/B,IAAMC,EAAaJ,EAAW,eA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