@womp/kookie-ui 0.7.0 → 0.8.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/components.css +538 -493
- package/dist/cjs/components/_internal/base-menu.utils.js +1 -1
- package/dist/cjs/components/_internal/base-menu.utils.js.map +3 -3
- package/dist/cjs/components/_internal/menu-context.js +1 -1
- package/dist/cjs/components/_internal/menu-context.js.map +3 -3
- package/dist/cjs/components/_internal/shell-bottom.d.ts +6 -7
- package/dist/cjs/components/_internal/shell-bottom.d.ts.map +1 -1
- package/dist/cjs/components/_internal/shell-bottom.js +1 -1
- package/dist/cjs/components/_internal/shell-bottom.js.map +4 -4
- package/dist/cjs/components/_internal/shell-handles.d.ts +9 -0
- package/dist/cjs/components/_internal/shell-handles.d.ts.map +1 -1
- package/dist/cjs/components/_internal/shell-handles.js +1 -1
- package/dist/cjs/components/_internal/shell-handles.js.map +3 -3
- package/dist/cjs/components/_internal/shell-inspector.d.ts +4 -6
- package/dist/cjs/components/_internal/shell-inspector.d.ts.map +1 -1
- package/dist/cjs/components/_internal/shell-inspector.js +1 -1
- package/dist/cjs/components/_internal/shell-inspector.js.map +4 -4
- package/dist/cjs/components/_internal/shell-pane.d.ts +70 -0
- package/dist/cjs/components/_internal/shell-pane.d.ts.map +1 -0
- package/dist/cjs/components/_internal/shell-pane.js +2 -0
- package/dist/cjs/components/_internal/shell-pane.js.map +7 -0
- package/dist/cjs/components/_internal/shell-resizable.d.ts +48 -0
- package/dist/cjs/components/_internal/shell-resizable.d.ts.map +1 -0
- package/dist/cjs/components/_internal/shell-resizable.js +2 -0
- package/dist/cjs/components/_internal/shell-resizable.js.map +7 -0
- package/dist/cjs/components/_internal/shell-resize.d.ts +11 -3
- package/dist/cjs/components/_internal/shell-resize.d.ts.map +1 -1
- package/dist/cjs/components/_internal/shell-resize.js +1 -1
- package/dist/cjs/components/_internal/shell-resize.js.map +2 -2
- package/dist/cjs/components/_internal/shell-rest.d.ts +27 -0
- package/dist/cjs/components/_internal/shell-rest.d.ts.map +1 -0
- package/dist/cjs/components/_internal/shell-rest.js +2 -0
- package/dist/cjs/components/_internal/shell-rest.js.map +7 -0
- package/dist/cjs/components/_internal/shell-sidebar.d.ts +7 -12
- package/dist/cjs/components/_internal/shell-sidebar.d.ts.map +1 -1
- package/dist/cjs/components/_internal/shell-sidebar.js +1 -1
- package/dist/cjs/components/_internal/shell-sidebar.js.map +4 -4
- package/dist/cjs/components/_internal/shell-store.d.ts +99 -0
- package/dist/cjs/components/_internal/shell-store.d.ts.map +1 -0
- package/dist/cjs/components/_internal/shell-store.js +2 -0
- package/dist/cjs/components/_internal/shell-store.js.map +7 -0
- package/dist/cjs/components/context-menu.js +1 -1
- package/dist/cjs/components/context-menu.js.map +3 -3
- package/dist/cjs/components/dropdown-menu.js +1 -1
- package/dist/cjs/components/dropdown-menu.js.map +3 -3
- package/dist/cjs/components/index.js +5 -5
- package/dist/cjs/components/index.js.map +4 -4
- package/dist/cjs/components/schemas/index.js +1 -1
- package/dist/cjs/components/schemas/index.js.map +3 -3
- package/dist/cjs/components/schemas/shell.schema.d.ts +277 -229
- package/dist/cjs/components/schemas/shell.schema.d.ts.map +1 -1
- package/dist/cjs/components/schemas/shell.schema.js +1 -1
- package/dist/cjs/components/schemas/shell.schema.js.map +3 -3
- package/dist/cjs/components/shell.context.d.ts +25 -114
- package/dist/cjs/components/shell.context.d.ts.map +1 -1
- package/dist/cjs/components/shell.context.js +1 -1
- package/dist/cjs/components/shell.context.js.map +4 -4
- package/dist/cjs/components/shell.d.ts +42 -21
- package/dist/cjs/components/shell.d.ts.map +1 -1
- package/dist/cjs/components/shell.hooks.d.ts +7 -23
- package/dist/cjs/components/shell.hooks.d.ts.map +1 -1
- package/dist/cjs/components/shell.hooks.js +1 -1
- package/dist/cjs/components/shell.hooks.js.map +4 -4
- package/dist/cjs/components/shell.js +1 -1
- package/dist/cjs/components/shell.js.map +4 -4
- package/dist/cjs/components/shell.types.d.ts +19 -2
- package/dist/cjs/components/shell.types.d.ts.map +1 -1
- package/dist/cjs/components/shell.types.js +1 -1
- package/dist/cjs/components/shell.types.js.map +3 -3
- package/dist/cjs/components/sidebar.js.map +3 -3
- package/dist/cjs/hooks/use-breakpoint.d.ts +5 -0
- package/dist/cjs/hooks/use-breakpoint.d.ts.map +1 -1
- package/dist/cjs/hooks/use-breakpoint.js +1 -1
- package/dist/cjs/hooks/use-breakpoint.js.map +3 -3
- package/dist/cjs/index.js +5 -5
- package/dist/cjs/index.js.map +4 -4
- package/dist/esm/{chunk-HJU4I34X.js → chunk-25X75TI7.js} +2 -2
- package/dist/esm/{chunk-4XKK32M4.js → chunk-26I257HE.js} +2 -2
- package/dist/esm/chunk-2EQWBT2S.js +2 -0
- package/dist/esm/chunk-2EQWBT2S.js.map +7 -0
- package/dist/esm/{chunk-GLERJXVS.js → chunk-2Q7BJ7YG.js} +2 -2
- package/dist/esm/{chunk-CJ27XP5Z.js → chunk-3AOFY2B4.js} +2 -2
- package/dist/esm/chunk-3J6AUDID.js +2 -0
- package/dist/esm/chunk-3J6AUDID.js.map +7 -0
- package/dist/esm/{chunk-7EWFBWBS.js → chunk-3PTSRBVY.js} +2 -2
- package/dist/esm/chunk-3XSB7YIM.js +2 -0
- package/dist/esm/{chunk-FMBECDL4.js.map → chunk-3XSB7YIM.js.map} +3 -3
- package/dist/esm/{chunk-O2U6RJTB.js → chunk-44JZYS7A.js} +2 -2
- package/dist/esm/{chunk-CTA5ODAO.js → chunk-4WU2WKUJ.js} +2 -2
- package/dist/esm/{chunk-KZWNGWIM.js → chunk-5M7STAH3.js} +2 -2
- package/dist/esm/{chunk-5WRCK4R7.js → chunk-5TAHT6VC.js} +2 -2
- package/dist/esm/{chunk-RNTCHVFI.js → chunk-6J6YX2VX.js} +2 -2
- package/dist/esm/{chunk-AGSSWWFI.js → chunk-7FKKGUHK.js} +2 -2
- package/dist/esm/{chunk-WHFJ4JUN.js → chunk-7NYODT3Z.js} +2 -2
- package/dist/esm/{chunk-NVDXXGVW.js → chunk-7PMMYHZV.js} +2 -2
- package/dist/esm/chunk-A2XVR7GL.js +2 -0
- package/dist/esm/chunk-A2XVR7GL.js.map +7 -0
- package/dist/esm/chunk-ADXZNG4F.js +2 -0
- package/dist/esm/chunk-ADXZNG4F.js.map +7 -0
- package/dist/esm/chunk-AGNIFHOE.js +2 -0
- package/dist/esm/chunk-AGNIFHOE.js.map +7 -0
- package/dist/esm/{chunk-KJUDZCYK.js → chunk-AIHQ3MVK.js} +2 -2
- package/dist/esm/{chunk-UBOOUDS4.js → chunk-AO32NT75.js} +2 -2
- package/dist/esm/chunk-BZZXXZ3O.js +2 -0
- package/dist/esm/chunk-BZZXXZ3O.js.map +7 -0
- package/dist/esm/{chunk-JDGJSNWT.js → chunk-C5RVO3C3.js} +2 -2
- package/dist/esm/{chunk-IHK3H2OM.js → chunk-CBNTPHYK.js} +2 -2
- package/dist/esm/{chunk-BBJUB52V.js → chunk-CRBOJ7N7.js} +2 -2
- package/dist/esm/{chunk-VHECAEUP.js → chunk-DCIQHXAR.js} +2 -2
- package/dist/esm/{chunk-43A5GUSI.js → chunk-EHBAK3LQ.js} +2 -2
- package/dist/esm/{chunk-K3UAS7RW.js → chunk-F3AXE27Q.js} +2 -2
- package/dist/esm/{chunk-KFR3CK24.js → chunk-FB3PD4Z3.js} +2 -2
- package/dist/esm/{chunk-MCPRXVKZ.js → chunk-FEAOFF77.js} +2 -2
- package/dist/esm/{chunk-VZSQATP6.js → chunk-G4YKBAZT.js} +2 -2
- package/dist/esm/{chunk-ECXGQQJB.js → chunk-GDAKJS64.js} +2 -2
- package/dist/esm/{chunk-VR7ZAFYN.js → chunk-GGSJXOKR.js} +2 -2
- package/dist/esm/chunk-GM7KMQDI.js +2 -0
- package/dist/esm/chunk-GMHA5CFH.js +2 -0
- package/dist/esm/chunk-GMHA5CFH.js.map +7 -0
- package/dist/esm/{chunk-CESYMTJQ.js → chunk-H4GR4262.js} +2 -2
- package/dist/esm/{chunk-WXQIIKWV.js → chunk-HBIF43PT.js} +2 -2
- package/dist/esm/chunk-HCNO7PX6.js +2 -0
- package/dist/esm/chunk-HCNO7PX6.js.map +7 -0
- package/dist/esm/{chunk-2264DHUW.js → chunk-HMSSFU6I.js} +2 -2
- package/dist/esm/chunk-HWQ3NTJP.js +2 -0
- package/dist/esm/chunk-HWQ3NTJP.js.map +7 -0
- package/dist/esm/{chunk-S5C5YRBS.js → chunk-IDUVJJYG.js} +2 -2
- package/dist/esm/{chunk-CIYF56YS.js → chunk-IK3MQHA5.js} +2 -2
- package/dist/esm/{chunk-CKMMUHKE.js → chunk-JDEBKA56.js} +2 -2
- package/dist/esm/{chunk-E67CIG6A.js → chunk-JDWCQ2XP.js} +2 -2
- package/dist/esm/{chunk-L3BWTV7I.js → chunk-JQSZF3E2.js} +2 -2
- package/dist/esm/{chunk-MEO7MJMQ.js → chunk-JQW4XYBS.js} +2 -2
- package/dist/esm/{chunk-KMPE7TJ6.js → chunk-JRFZ535T.js} +2 -2
- package/dist/esm/{chunk-CDG5WH4U.js → chunk-KEEPKI2X.js} +2 -2
- package/dist/esm/{chunk-GAV3NHYL.js → chunk-KV4SZP3F.js} +2 -2
- package/dist/esm/{chunk-FG7XM7KJ.js → chunk-LJCUPAOI.js} +2 -2
- package/dist/esm/{chunk-N4GTDLRD.js → chunk-MBCQA7UZ.js} +2 -2
- package/dist/esm/chunk-MM5IHQFM.js +2 -0
- package/dist/esm/{chunk-Y5RCH23Z.js → chunk-NQXRWBQM.js} +2 -2
- package/dist/esm/{chunk-CSKZZOI2.js → chunk-NTNMJX5M.js} +2 -2
- package/dist/esm/{chunk-V27ZAN3E.js → chunk-NV3P2CKH.js} +2 -2
- package/dist/esm/{chunk-4ME6O27S.js → chunk-O4CSXNST.js} +2 -2
- package/dist/esm/chunk-ODCVOXEV.js +2 -0
- package/dist/esm/{chunk-W2FOBR5Q.js → chunk-OEEF6KJG.js} +2 -2
- package/dist/esm/{chunk-ABSKRHVM.js → chunk-OJSOX3AX.js} +2 -2
- package/dist/esm/{chunk-JGLAE5G7.js → chunk-OQU2SKLN.js} +2 -2
- package/dist/esm/{chunk-PZ7OYATT.js → chunk-OTKQN2KY.js} +2 -2
- package/dist/esm/{chunk-QWVU2TW4.js → chunk-P27KV2LS.js} +2 -2
- package/dist/esm/{chunk-JUY7CBSL.js → chunk-PBFSBHBS.js} +2 -2
- package/dist/esm/{chunk-DSJY5RI3.js → chunk-PDUHBDFC.js} +2 -2
- package/dist/esm/{chunk-MTOLKA6S.js → chunk-POG3YABW.js} +2 -2
- package/dist/esm/chunk-PYHEBG5I.js +2 -0
- package/dist/esm/chunk-PYHEBG5I.js.map +7 -0
- package/dist/esm/{chunk-GO7OHBHW.js → chunk-PYXMGEO7.js} +2 -2
- package/dist/esm/{chunk-VNH7BJOA.js → chunk-QEGEUD4D.js} +2 -2
- package/dist/esm/chunk-QEL55MLF.js +2 -0
- package/dist/esm/{chunk-MS5J4MF6.js → chunk-QJVAS7AK.js} +2 -2
- package/dist/esm/chunk-ROSWI2CL.js +2 -0
- package/dist/esm/chunk-ROSWI2CL.js.map +7 -0
- package/dist/esm/{chunk-KCWESYMR.js → chunk-RY67WG3O.js} +2 -2
- package/dist/esm/{chunk-IFM4EMZB.js → chunk-TLGXIWAS.js} +2 -2
- package/dist/esm/{chunk-6FLLFCBU.js → chunk-UBSLEGQZ.js} +2 -2
- package/dist/esm/{chunk-VBI3AWPT.js → chunk-UNWPH3SO.js} +2 -2
- package/dist/esm/chunk-V5ZSDDVZ.js +2 -0
- package/dist/esm/chunk-V5ZSDDVZ.js.map +7 -0
- package/dist/esm/{chunk-X7V3V3W4.js → chunk-VTIL55SR.js} +2 -2
- package/dist/esm/{chunk-ALWNS44Q.js → chunk-W2LD2YE6.js} +2 -2
- package/dist/esm/{chunk-2I7QRVJ5.js → chunk-WGWUEU4K.js} +2 -2
- package/dist/esm/{chunk-EPTYNVCU.js → chunk-WIDJYVZF.js} +2 -2
- package/dist/esm/{chunk-OLAWVEAI.js → chunk-WJBOOAIO.js} +2 -2
- package/dist/esm/{chunk-7FC7HF76.js → chunk-WQCB7KSH.js} +2 -2
- package/dist/esm/{chunk-YBSRX63K.js → chunk-WZFVTC7P.js} +2 -2
- package/dist/esm/chunk-XDDKT4NF.js +2 -0
- package/dist/esm/{chunk-KFA53SVQ.js → chunk-YA5DF67M.js} +2 -2
- package/dist/esm/chunk-YA5DF67M.js.map +7 -0
- package/dist/esm/chunk-YAQBIO2B.js +2 -0
- package/dist/esm/chunk-YAQBIO2B.js.map +7 -0
- package/dist/esm/{chunk-OFUNVHZ5.js → chunk-YG66IRW4.js} +2 -2
- package/dist/esm/{chunk-WGYUWEQV.js → chunk-YVSM2LGS.js} +2 -2
- package/dist/esm/{chunk-4NTGF22C.js → chunk-Z7AZNMNX.js} +2 -2
- package/dist/esm/chunk-ZJ33QP5N.js +2 -0
- package/dist/esm/{chunk-OGXZHAQL.js → chunk-ZW26J2SA.js} +2 -2
- package/dist/esm/components/_internal/base-button.js +1 -1
- package/dist/esm/components/_internal/base-menu.utils.js +1 -1
- package/dist/esm/components/_internal/menu-context.js +1 -1
- package/dist/esm/components/_internal/shell-bottom.d.ts +6 -7
- package/dist/esm/components/_internal/shell-bottom.d.ts.map +1 -1
- package/dist/esm/components/_internal/shell-bottom.js +1 -1
- package/dist/esm/components/_internal/shell-handles.d.ts +9 -0
- package/dist/esm/components/_internal/shell-handles.d.ts.map +1 -1
- package/dist/esm/components/_internal/shell-handles.js +1 -1
- package/dist/esm/components/_internal/shell-inspector.d.ts +4 -6
- package/dist/esm/components/_internal/shell-inspector.d.ts.map +1 -1
- package/dist/esm/components/_internal/shell-inspector.js +1 -1
- package/dist/esm/components/_internal/shell-pane.d.ts +70 -0
- package/dist/esm/components/_internal/shell-pane.d.ts.map +1 -0
- package/dist/esm/components/_internal/shell-pane.js +2 -0
- package/dist/esm/components/_internal/shell-resizable.d.ts +48 -0
- package/dist/esm/components/_internal/shell-resizable.d.ts.map +1 -0
- package/dist/esm/components/_internal/shell-resizable.js +2 -0
- package/dist/esm/components/_internal/shell-resizable.js.map +7 -0
- package/dist/esm/components/_internal/shell-resize.d.ts +11 -3
- package/dist/esm/components/_internal/shell-resize.d.ts.map +1 -1
- package/dist/esm/components/_internal/shell-resize.js +1 -1
- package/dist/esm/components/_internal/shell-rest.d.ts +27 -0
- package/dist/esm/components/_internal/shell-rest.d.ts.map +1 -0
- package/dist/esm/components/_internal/shell-rest.js +2 -0
- package/dist/esm/components/_internal/shell-rest.js.map +7 -0
- package/dist/esm/components/_internal/shell-sidebar.d.ts +7 -12
- package/dist/esm/components/_internal/shell-sidebar.d.ts.map +1 -1
- package/dist/esm/components/_internal/shell-sidebar.js +1 -1
- package/dist/esm/components/_internal/shell-store.d.ts +99 -0
- package/dist/esm/components/_internal/shell-store.d.ts.map +1 -0
- package/dist/esm/components/_internal/shell-store.js +2 -0
- package/dist/esm/components/_internal/shell-store.js.map +7 -0
- package/dist/esm/components/accordion.js +1 -1
- package/dist/esm/components/alert-dialog.js +1 -1
- package/dist/esm/components/avatar.js +1 -1
- package/dist/esm/components/badge.js +1 -1
- package/dist/esm/components/blockquote.js +1 -1
- package/dist/esm/components/blockquote.props.js +1 -1
- package/dist/esm/components/box.js +1 -1
- package/dist/esm/components/button.js +1 -1
- package/dist/esm/components/callout.js +1 -1
- package/dist/esm/components/card.js +1 -1
- package/dist/esm/components/chatbar.js +1 -1
- package/dist/esm/components/checkbox-cards.js +1 -1
- package/dist/esm/components/checkbox-group.js +1 -1
- package/dist/esm/components/checkbox.js +1 -1
- package/dist/esm/components/code.js +1 -1
- package/dist/esm/components/code.props.js +1 -1
- package/dist/esm/components/combobox.js +1 -1
- package/dist/esm/components/container.js +1 -1
- package/dist/esm/components/context-menu.js +1 -1
- package/dist/esm/components/data-list.js +1 -1
- package/dist/esm/components/dialog.js +1 -1
- package/dist/esm/components/dropdown-menu.js +1 -1
- package/dist/esm/components/em.js +1 -1
- package/dist/esm/components/em.props.js +1 -1
- package/dist/esm/components/flex.js +1 -1
- package/dist/esm/components/grid.js +1 -1
- package/dist/esm/components/heading.js +1 -1
- package/dist/esm/components/heading.props.js +1 -1
- package/dist/esm/components/hover-card.js +1 -1
- package/dist/esm/components/icon-button.js +1 -1
- package/dist/esm/components/image.js +1 -1
- package/dist/esm/components/index.js +1 -1
- package/dist/esm/components/inset.js +1 -1
- package/dist/esm/components/kbd.js +1 -1
- package/dist/esm/components/link.js +1 -1
- package/dist/esm/components/link.props.js +1 -1
- package/dist/esm/components/navbar.js +1 -1
- package/dist/esm/components/popover.js +1 -1
- package/dist/esm/components/progress.js +1 -1
- package/dist/esm/components/quote.js +1 -1
- package/dist/esm/components/quote.props.js +1 -1
- package/dist/esm/components/radio-cards.js +1 -1
- package/dist/esm/components/radio-group.js +1 -1
- package/dist/esm/components/radio.js +1 -1
- package/dist/esm/components/schemas/index.js +1 -1
- package/dist/esm/components/schemas/shell.schema.d.ts +277 -229
- package/dist/esm/components/schemas/shell.schema.d.ts.map +1 -1
- package/dist/esm/components/schemas/shell.schema.js +1 -1
- package/dist/esm/components/scroll-area.js +1 -1
- package/dist/esm/components/section.js +1 -1
- package/dist/esm/components/segmented-control.js +1 -1
- package/dist/esm/components/select.js +1 -1
- package/dist/esm/components/separator.js +1 -1
- package/dist/esm/components/sheet.js +1 -1
- package/dist/esm/components/shell.context.d.ts +25 -114
- package/dist/esm/components/shell.context.d.ts.map +1 -1
- package/dist/esm/components/shell.context.js +1 -1
- package/dist/esm/components/shell.d.ts +42 -21
- package/dist/esm/components/shell.d.ts.map +1 -1
- package/dist/esm/components/shell.hooks.d.ts +7 -23
- package/dist/esm/components/shell.hooks.d.ts.map +1 -1
- package/dist/esm/components/shell.hooks.js +1 -1
- package/dist/esm/components/shell.js +1 -1
- package/dist/esm/components/shell.types.d.ts +19 -2
- package/dist/esm/components/shell.types.d.ts.map +1 -1
- package/dist/esm/components/shell.types.js +1 -1
- package/dist/esm/components/sidebar.js +1 -1
- package/dist/esm/components/skeleton.js +1 -1
- package/dist/esm/components/slider.js +1 -1
- package/dist/esm/components/spinner.js +1 -1
- package/dist/esm/components/strong.js +1 -1
- package/dist/esm/components/strong.props.js +1 -1
- package/dist/esm/components/switch.js +1 -1
- package/dist/esm/components/tab-nav.js +1 -1
- package/dist/esm/components/table.js +1 -1
- package/dist/esm/components/tabs.js +1 -1
- package/dist/esm/components/text-area.js +1 -1
- package/dist/esm/components/text-field.js +1 -1
- package/dist/esm/components/text.js +1 -1
- package/dist/esm/components/text.props.js +1 -1
- package/dist/esm/components/theme-panel.js +1 -1
- package/dist/esm/components/toggle-button.js +1 -1
- package/dist/esm/components/toggle-icon-button.js +1 -1
- package/dist/esm/components/toolbar.js +1 -1
- package/dist/esm/components/tooltip.js +1 -1
- package/dist/esm/components/user-card.js +1 -1
- package/dist/esm/components/virtual-menu.js +1 -1
- package/dist/esm/helpers/extract-props.js +1 -1
- package/dist/esm/helpers/get-margin-styles.js +1 -1
- package/dist/esm/helpers/get-responsive-styles.js +1 -1
- package/dist/esm/helpers/index.js +1 -1
- package/dist/esm/hooks/index.js +1 -1
- package/dist/esm/hooks/use-breakpoint.d.ts +5 -0
- package/dist/esm/hooks/use-breakpoint.d.ts.map +1 -1
- package/dist/esm/hooks/use-breakpoint.js +1 -1
- package/dist/esm/index.js +1 -1
- package/dist/esm/props/index.js +1 -1
- package/package.json +7 -2
- package/schemas/index.json +1655 -0
- package/schemas/shell-bottom.d.ts +2 -0
- package/schemas/shell-bottom.json +180 -76
- package/schemas/shell-content.d.ts +2 -0
- package/schemas/shell-content.json +11 -5
- package/schemas/shell-handle.d.ts +2 -0
- package/schemas/shell-handle.json +7 -5
- package/schemas/shell-header.d.ts +2 -0
- package/schemas/shell-header.json +9 -10
- package/schemas/shell-inspector.d.ts +2 -0
- package/schemas/shell-inspector.json +183 -79
- package/schemas/shell-panel.d.ts +2 -0
- package/schemas/shell-panel.json +180 -76
- package/schemas/shell-rail.d.ts +2 -0
- package/schemas/shell-rail.json +137 -64
- package/schemas/shell-root.d.ts +2 -0
- package/schemas/shell-root.json +11 -9
- package/schemas/shell-sidebar.d.ts +2 -0
- package/schemas/shell-sidebar.json +274 -85
- package/schemas/shell-trigger.d.ts +2 -0
- package/schemas/shell-trigger.json +29 -17
- package/src/components/_internal/shell-bottom.tsx +92 -361
- package/src/components/_internal/shell-handles.tsx +193 -108
- package/src/components/_internal/shell-inspector.tsx +93 -360
- package/src/components/_internal/shell-pane.tsx +283 -0
- package/src/components/_internal/shell-resizable.tsx +263 -0
- package/src/components/_internal/shell-resize.tsx +11 -3
- package/src/components/_internal/shell-rest.ts +45 -0
- package/src/components/_internal/shell-sidebar.tsx +130 -441
- package/src/components/_internal/shell-store.tsx +204 -0
- package/src/components/schemas/shell.schema.ts +162 -153
- package/src/components/shell.context.tsx +112 -124
- package/src/components/shell.css +637 -496
- package/src/components/shell.hooks.ts +12 -170
- package/src/components/shell.tsx +566 -1497
- package/src/components/shell.types.ts +22 -2
- package/src/hooks/use-breakpoint.ts +9 -0
- package/styles.css +538 -493
- package/dist/cjs/components/_internal/shell-prop-helpers.d.ts +0 -7
- package/dist/cjs/components/_internal/shell-prop-helpers.d.ts.map +0 -1
- package/dist/cjs/components/_internal/shell-prop-helpers.js +0 -2
- package/dist/cjs/components/_internal/shell-prop-helpers.js.map +0 -7
- package/dist/esm/chunk-2SZZ75RJ.js +0 -2
- package/dist/esm/chunk-2SZZ75RJ.js.map +0 -7
- package/dist/esm/chunk-4JQZUQY7.js +0 -2
- package/dist/esm/chunk-5LXFJMFB.js +0 -2
- package/dist/esm/chunk-5LXFJMFB.js.map +0 -7
- package/dist/esm/chunk-CECQNGUL.js +0 -2
- package/dist/esm/chunk-CECQNGUL.js.map +0 -7
- package/dist/esm/chunk-CEIK5U6C.js +0 -2
- package/dist/esm/chunk-CEIK5U6C.js.map +0 -7
- package/dist/esm/chunk-EE2IH2GL.js +0 -2
- package/dist/esm/chunk-EE2IH2GL.js.map +0 -7
- package/dist/esm/chunk-FMBECDL4.js +0 -2
- package/dist/esm/chunk-HSAG7C53.js +0 -2
- package/dist/esm/chunk-JJKQ7CGI.js +0 -2
- package/dist/esm/chunk-KFA53SVQ.js.map +0 -7
- package/dist/esm/chunk-KRDP5SQ7.js +0 -2
- package/dist/esm/chunk-KRDP5SQ7.js.map +0 -7
- package/dist/esm/chunk-M6DJRFJZ.js +0 -2
- package/dist/esm/chunk-M6DJRFJZ.js.map +0 -7
- package/dist/esm/chunk-MCQCG6AS.js +0 -2
- package/dist/esm/chunk-NIQT45PJ.js +0 -2
- package/dist/esm/chunk-NNO7M466.js +0 -2
- package/dist/esm/chunk-NNO7M466.js.map +0 -7
- package/dist/esm/chunk-SNHEJU2S.js +0 -2
- package/dist/esm/chunk-SNHEJU2S.js.map +0 -7
- package/dist/esm/chunk-TLWTUKKL.js +0 -2
- package/dist/esm/chunk-TLWTUKKL.js.map +0 -7
- package/dist/esm/chunk-XI5YXUCK.js +0 -2
- package/dist/esm/components/_internal/shell-prop-helpers.d.ts +0 -7
- package/dist/esm/components/_internal/shell-prop-helpers.d.ts.map +0 -1
- package/dist/esm/components/_internal/shell-prop-helpers.js +0 -2
- package/src/components/_internal/shell-prop-helpers.ts +0 -54
- /package/dist/esm/{chunk-HJU4I34X.js.map → chunk-25X75TI7.js.map} +0 -0
- /package/dist/esm/{chunk-4XKK32M4.js.map → chunk-26I257HE.js.map} +0 -0
- /package/dist/esm/{chunk-GLERJXVS.js.map → chunk-2Q7BJ7YG.js.map} +0 -0
- /package/dist/esm/{chunk-CJ27XP5Z.js.map → chunk-3AOFY2B4.js.map} +0 -0
- /package/dist/esm/{chunk-7EWFBWBS.js.map → chunk-3PTSRBVY.js.map} +0 -0
- /package/dist/esm/{chunk-O2U6RJTB.js.map → chunk-44JZYS7A.js.map} +0 -0
- /package/dist/esm/{chunk-CTA5ODAO.js.map → chunk-4WU2WKUJ.js.map} +0 -0
- /package/dist/esm/{chunk-KZWNGWIM.js.map → chunk-5M7STAH3.js.map} +0 -0
- /package/dist/esm/{chunk-5WRCK4R7.js.map → chunk-5TAHT6VC.js.map} +0 -0
- /package/dist/esm/{chunk-RNTCHVFI.js.map → chunk-6J6YX2VX.js.map} +0 -0
- /package/dist/esm/{chunk-AGSSWWFI.js.map → chunk-7FKKGUHK.js.map} +0 -0
- /package/dist/esm/{chunk-WHFJ4JUN.js.map → chunk-7NYODT3Z.js.map} +0 -0
- /package/dist/esm/{chunk-NVDXXGVW.js.map → chunk-7PMMYHZV.js.map} +0 -0
- /package/dist/esm/{chunk-KJUDZCYK.js.map → chunk-AIHQ3MVK.js.map} +0 -0
- /package/dist/esm/{chunk-UBOOUDS4.js.map → chunk-AO32NT75.js.map} +0 -0
- /package/dist/esm/{chunk-JDGJSNWT.js.map → chunk-C5RVO3C3.js.map} +0 -0
- /package/dist/esm/{chunk-IHK3H2OM.js.map → chunk-CBNTPHYK.js.map} +0 -0
- /package/dist/esm/{chunk-BBJUB52V.js.map → chunk-CRBOJ7N7.js.map} +0 -0
- /package/dist/esm/{chunk-VHECAEUP.js.map → chunk-DCIQHXAR.js.map} +0 -0
- /package/dist/esm/{chunk-43A5GUSI.js.map → chunk-EHBAK3LQ.js.map} +0 -0
- /package/dist/esm/{chunk-K3UAS7RW.js.map → chunk-F3AXE27Q.js.map} +0 -0
- /package/dist/esm/{chunk-KFR3CK24.js.map → chunk-FB3PD4Z3.js.map} +0 -0
- /package/dist/esm/{chunk-MCPRXVKZ.js.map → chunk-FEAOFF77.js.map} +0 -0
- /package/dist/esm/{chunk-VZSQATP6.js.map → chunk-G4YKBAZT.js.map} +0 -0
- /package/dist/esm/{chunk-ECXGQQJB.js.map → chunk-GDAKJS64.js.map} +0 -0
- /package/dist/esm/{chunk-VR7ZAFYN.js.map → chunk-GGSJXOKR.js.map} +0 -0
- /package/dist/esm/{chunk-4JQZUQY7.js.map → chunk-GM7KMQDI.js.map} +0 -0
- /package/dist/esm/{chunk-CESYMTJQ.js.map → chunk-H4GR4262.js.map} +0 -0
- /package/dist/esm/{chunk-WXQIIKWV.js.map → chunk-HBIF43PT.js.map} +0 -0
- /package/dist/esm/{chunk-2264DHUW.js.map → chunk-HMSSFU6I.js.map} +0 -0
- /package/dist/esm/{chunk-S5C5YRBS.js.map → chunk-IDUVJJYG.js.map} +0 -0
- /package/dist/esm/{chunk-CIYF56YS.js.map → chunk-IK3MQHA5.js.map} +0 -0
- /package/dist/esm/{chunk-CKMMUHKE.js.map → chunk-JDEBKA56.js.map} +0 -0
- /package/dist/esm/{chunk-E67CIG6A.js.map → chunk-JDWCQ2XP.js.map} +0 -0
- /package/dist/esm/{chunk-L3BWTV7I.js.map → chunk-JQSZF3E2.js.map} +0 -0
- /package/dist/esm/{chunk-MEO7MJMQ.js.map → chunk-JQW4XYBS.js.map} +0 -0
- /package/dist/esm/{chunk-KMPE7TJ6.js.map → chunk-JRFZ535T.js.map} +0 -0
- /package/dist/esm/{chunk-CDG5WH4U.js.map → chunk-KEEPKI2X.js.map} +0 -0
- /package/dist/esm/{chunk-GAV3NHYL.js.map → chunk-KV4SZP3F.js.map} +0 -0
- /package/dist/esm/{chunk-FG7XM7KJ.js.map → chunk-LJCUPAOI.js.map} +0 -0
- /package/dist/esm/{chunk-N4GTDLRD.js.map → chunk-MBCQA7UZ.js.map} +0 -0
- /package/dist/esm/{chunk-JJKQ7CGI.js.map → chunk-MM5IHQFM.js.map} +0 -0
- /package/dist/esm/{chunk-Y5RCH23Z.js.map → chunk-NQXRWBQM.js.map} +0 -0
- /package/dist/esm/{chunk-CSKZZOI2.js.map → chunk-NTNMJX5M.js.map} +0 -0
- /package/dist/esm/{chunk-V27ZAN3E.js.map → chunk-NV3P2CKH.js.map} +0 -0
- /package/dist/esm/{chunk-4ME6O27S.js.map → chunk-O4CSXNST.js.map} +0 -0
- /package/dist/esm/{chunk-HSAG7C53.js.map → chunk-ODCVOXEV.js.map} +0 -0
- /package/dist/esm/{chunk-W2FOBR5Q.js.map → chunk-OEEF6KJG.js.map} +0 -0
- /package/dist/esm/{chunk-ABSKRHVM.js.map → chunk-OJSOX3AX.js.map} +0 -0
- /package/dist/esm/{chunk-JGLAE5G7.js.map → chunk-OQU2SKLN.js.map} +0 -0
- /package/dist/esm/{chunk-PZ7OYATT.js.map → chunk-OTKQN2KY.js.map} +0 -0
- /package/dist/esm/{chunk-QWVU2TW4.js.map → chunk-P27KV2LS.js.map} +0 -0
- /package/dist/esm/{chunk-JUY7CBSL.js.map → chunk-PBFSBHBS.js.map} +0 -0
- /package/dist/esm/{chunk-DSJY5RI3.js.map → chunk-PDUHBDFC.js.map} +0 -0
- /package/dist/esm/{chunk-MTOLKA6S.js.map → chunk-POG3YABW.js.map} +0 -0
- /package/dist/esm/{chunk-GO7OHBHW.js.map → chunk-PYXMGEO7.js.map} +0 -0
- /package/dist/esm/{chunk-VNH7BJOA.js.map → chunk-QEGEUD4D.js.map} +0 -0
- /package/dist/esm/{chunk-MCQCG6AS.js.map → chunk-QEL55MLF.js.map} +0 -0
- /package/dist/esm/{chunk-MS5J4MF6.js.map → chunk-QJVAS7AK.js.map} +0 -0
- /package/dist/esm/{chunk-KCWESYMR.js.map → chunk-RY67WG3O.js.map} +0 -0
- /package/dist/esm/{chunk-IFM4EMZB.js.map → chunk-TLGXIWAS.js.map} +0 -0
- /package/dist/esm/{chunk-6FLLFCBU.js.map → chunk-UBSLEGQZ.js.map} +0 -0
- /package/dist/esm/{chunk-VBI3AWPT.js.map → chunk-UNWPH3SO.js.map} +0 -0
- /package/dist/esm/{chunk-X7V3V3W4.js.map → chunk-VTIL55SR.js.map} +0 -0
- /package/dist/esm/{chunk-ALWNS44Q.js.map → chunk-W2LD2YE6.js.map} +0 -0
- /package/dist/esm/{chunk-2I7QRVJ5.js.map → chunk-WGWUEU4K.js.map} +0 -0
- /package/dist/esm/{chunk-EPTYNVCU.js.map → chunk-WIDJYVZF.js.map} +0 -0
- /package/dist/esm/{chunk-OLAWVEAI.js.map → chunk-WJBOOAIO.js.map} +0 -0
- /package/dist/esm/{chunk-7FC7HF76.js.map → chunk-WQCB7KSH.js.map} +0 -0
- /package/dist/esm/{chunk-YBSRX63K.js.map → chunk-WZFVTC7P.js.map} +0 -0
- /package/dist/esm/{chunk-XI5YXUCK.js.map → chunk-XDDKT4NF.js.map} +0 -0
- /package/dist/esm/{chunk-OFUNVHZ5.js.map → chunk-YG66IRW4.js.map} +0 -0
- /package/dist/esm/{chunk-WGYUWEQV.js.map → chunk-YVSM2LGS.js.map} +0 -0
- /package/dist/esm/{chunk-4NTGF22C.js.map → chunk-Z7AZNMNX.js.map} +0 -0
- /package/dist/esm/{chunk-NIQT45PJ.js.map → chunk-ZJ33QP5N.js.map} +0 -0
- /package/dist/esm/{chunk-OGXZHAQL.js.map → chunk-ZW26J2SA.js.map} +0 -0
- /package/dist/esm/components/_internal/{shell-prop-helpers.js.map → shell-pane.js.map} +0 -0
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{a as i}from"./chunk-AF6XKU3W.js";import{a as e}from"./chunk-GSTOGDAJ.js";import{a as r}from"./chunk-
|
|
2
|
-
//# sourceMappingURL=chunk-
|
|
1
|
+
import{a as i}from"./chunk-AF6XKU3W.js";import{a as e}from"./chunk-GSTOGDAJ.js";import{a as r}from"./chunk-UBSLEGQZ.js";import*as t from"react";import l from"classnames";import{Switch as p}from"radix-ui";var w=t.forwardRef((s,a)=>{let{className:c,color:m,panelBackground:f,material:h,...n}=r(s,i,e),o=h||f;return t.createElement(p.Root,{"data-accent-color":m,"data-panel-background":o,"data-material":o,...n,asChild:!1,ref:a,className:l("rt-reset","rt-SwitchRoot",c)},t.createElement(p.Thumb,{className:"rt-SwitchThumb"}))});w.displayName="Switch";export{w as a};
|
|
2
|
+
//# sourceMappingURL=chunk-AIHQ3MVK.js.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{a as n}from"./chunk-GSTOGDAJ.js";import{a}from"./chunk-E23RKOQJ.js";import{a as i}from"./chunk-
|
|
2
|
-
//# sourceMappingURL=chunk-
|
|
1
|
+
import{a as n}from"./chunk-GSTOGDAJ.js";import{a}from"./chunk-E23RKOQJ.js";import{a as i}from"./chunk-PBFSBHBS.js";var l=n.m.values,f=new Set(l),p=[{key:"m",className:"rt-r-m",customProperties:["--margin"]},{key:"mx",className:"rt-r-mx",customProperties:["--margin-left","--margin-right"]},{key:"my",className:"rt-r-my",customProperties:["--margin-top","--margin-bottom"]},{key:"mt",className:"rt-r-mt",customProperties:["--margin-top"]},{key:"mr",className:"rt-r-mr",customProperties:["--margin-right"]},{key:"mb",className:"rt-r-mb",customProperties:["--margin-bottom"]},{key:"ml",className:"rt-r-ml",customProperties:["--margin-left"]}];function S(g){let e,r;for(let t=0;t<p.length;t++){let{key:c,className:u,customProperties:y}=p[t],s=g[c];if(s===void 0)continue;let[o,m]=i({className:u,customProperties:y,propValues:l,propValueSet:f,value:s});o&&(e??(e=[])).push(o),m&&(r=a(r,m))}return[e!==void 0?e.join(" "):"",r]}export{S as a};
|
|
2
|
+
//# sourceMappingURL=chunk-AO32NT75.js.map
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
import{a as q}from"./chunk-2LYX5S7H.js";import*as e from"react";var C=(n,o,c)=>Math.max(o??n,Math.min(c??n,n));function L(n){let{name:o,elementRef:c,cssVarName:f,orientation:m,minSize:a,maxSize:u,resizable:E,size:h,defaultSize:x,paneId:g,persistence:S}=n,i=e.useRef(n);e.useLayoutEffect(()=>{i.current=n});let z=e.useRef(null),P=e.useRef(0);e.useEffect(()=>()=>{z.current&&clearTimeout(z.current)},[]);let b=e.useCallback((t,r)=>{let{onSizeChange:s,sizeUpdate:l,sizeUpdateMs:p}=i.current;if(s){if(l==="debounce"){z.current&&clearTimeout(z.current),z.current=setTimeout(()=>{z.current=null,i.current.onSizeChange?.(t,r)},p);return}if(l==="throttle"){let V=Date.now();if(V-P.current<p)return;P.current=V}s(t,r)}},[]),y=e.useCallback(t=>q(t,m==="vertical"?"horizontal":"vertical"),[m]),w=e.useRef(!1),d=e.useCallback((t,r)=>{let s=c.current;if(s){s.style.setProperty(f,`${t}px`);for(let l of s.querySelectorAll(":scope > .rt-ShellResizer"))l.setAttribute("aria-valuenow",String(Math.round(t)));r&&(w.current=!0)}},[c,f]);e.useLayoutEffect(()=>{w.current||d(n.expandedSize,!1)},[n.expandedSize,d]),e.useLayoutEffect(()=>{if(h!==void 0||x===void 0)return;let t=y(x);if(typeof t!="number"||!Number.isFinite(t))return;let r=C(t,a,u);d(r,!0),b(r,{reason:"init"})},[]),e.useLayoutEffect(()=>{if(h===void 0||i.current.overlayingNow())return;let t=y(h);if(typeof t!="number"||!Number.isFinite(t))return;let r=C(t,a,u);d(r,!0),b(r,{reason:"controlled"})},[h,a,u,n.overlaying,y,d,b]);let R=e.useMemo(()=>{if(!g||S)return S;let t=`kookie-ui:shell:${o}:${g}`;return{load:()=>{if(!(typeof window>"u"))try{let r=window.localStorage.getItem(t);return r?Number(r):void 0}catch{return}},save:r=>{if(!(typeof window>"u"))try{window.localStorage.setItem(t,String(r))}catch{}}}},[o,g,S]);e.useLayoutEffect(()=>{if(!E||!R?.load||i.current.overlayingNow())return;let t=!0,r=l=>{if(!t||typeof l!="number"||!Number.isFinite(l))return;let p=C(l,a,u);d(p,!0),i.current.onResize?.(p)},s=R.load();return s instanceof Promise?s.then(r).catch(l=>{}):r(s),()=>{t=!1}},[E,R,n.overlaying,d,a,u,o]);let T=e.useCallback(t=>i.current.onResize?.(t),[]),N=e.useCallback(t=>{w.current=!0,i.current.onResizeStart?.(t)},[]),v=e.useCallback(t=>{i.current.onResizeEnd?.(t),b(t,{reason:"resize"}),R?.save?.(t)},[b,R]),k=e.useCallback(()=>i.current.requestCollapse(),[]),M=e.useCallback(()=>i.current.requestToggle(),[]);return e.useMemo(()=>({containerRef:c,controls:n.elementId,cssVarName:f,minSize:a,maxSize:u,defaultSize:n.expandedSize,orientation:m,edge:n.edge,growth:n.growth,onResize:T,onResizeStart:N,onResizeEnd:v,target:o,collapsible:n.collapsible,snapPoints:n.snapPoints,snapTolerance:n.snapTolerance??8,collapseThreshold:n.collapseThreshold,requestCollapse:k,requestToggle:M}),[c,n.elementId,f,a,u,n.expandedSize,m,n.edge,n.growth,T,N,v,o,n.collapsible,n.snapPoints,n.snapTolerance,n.collapseThreshold,k,M])}function O(n,o){let c=e.Children.toArray(n),f=c.filter(a=>e.isValidElement(a)&&a.type===o),m=c.filter(a=>!(e.isValidElement(a)&&a.type===o));return{handles:f,content:m}}export{L as a,O as b};
|
|
2
|
+
//# sourceMappingURL=chunk-BZZXXZ3O.js.map
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
{
|
|
2
|
+
"version": 3,
|
|
3
|
+
"sources": ["../../src/components/_internal/shell-resizable.tsx"],
|
|
4
|
+
"sourcesContent": ["'use client';\n\nimport * as React from 'react';\nimport { normalizeToPx } from '../../helpers/normalize-to-px.js';\nimport type { PaneName, PaneSizePersistence } from '../shell.types.js';\nimport type { PaneResizeContextValue } from './shell-resize.js';\n\nexport type SizeChangeMeta = { reason: 'init' | 'resize' | 'controlled' };\n\nexport type ResizableOptions = {\n name: PaneName;\n /** The pane's element id, which the handle names in `aria-controls`. */\n elementId: string;\n elementRef: React.RefObject<HTMLElement | null>;\n cssVarName: string;\n orientation: 'vertical' | 'horizontal';\n edge: 'start' | 'end';\n growth: (isRtl: boolean) => 1 | -1;\n expandedSize: number;\n minSize: number;\n maxSize: number;\n resizable: boolean;\n collapsible: boolean;\n size: number | string | undefined;\n defaultSize: number | string | undefined;\n onSizeChange: ((size: number, meta: SizeChangeMeta) => void) | undefined;\n sizeUpdate: 'throttle' | 'debounce' | undefined;\n sizeUpdateMs: number;\n onResize: ((size: number) => void) | undefined;\n onResizeStart: ((size: number) => void) | undefined;\n onResizeEnd: ((size: number) => void) | undefined;\n snapPoints: number[] | undefined;\n snapTolerance: number | undefined;\n collapseThreshold: number | undefined;\n paneId: string | undefined;\n persistence: PaneSizePersistence | undefined;\n /** Whether the pane is presented as an overlay right now. An overlay keeps its designed size and persists nothing. */\n overlaying: boolean;\n /** The same question asked at effect time, for a pane whose presentation is learnt after its first render. */\n overlayingNow: () => boolean;\n requestCollapse: () => void;\n requestToggle: () => void;\n};\n\n/**\n * Clamps to [min, max]. When the two cross (an app passing a maximum computed\n * from a narrow window below its fixed minimum), the minimum wins, as it did\n * in 0.7.\n */\nconst clampTo = (value: number, min: number | undefined, max: number | undefined) => Math.max(min ?? value, Math.min(max ?? value, value));\n\n/** Everything a resizable pane shares: size props, persistence, and the handle's context. */\nexport function useResizablePane(options: ResizableOptions): PaneResizeContextValue {\n const { name, elementRef, cssVarName, orientation, minSize, maxSize, resizable, size, defaultSize, paneId, persistence } = options;\n\n // The latest callbacks, so the size emitter does not change identity when a\n // consumer passes an inline function. A controlled `size` is reported again\n // only when the size, the minimum or the maximum changes.\n const latest = React.useRef(options);\n React.useLayoutEffect(() => {\n latest.current = options;\n });\n\n const debounceRef = React.useRef<ReturnType<typeof setTimeout> | null>(null);\n const throttleRef = React.useRef(0);\n React.useEffect(\n () => () => {\n if (debounceRef.current) clearTimeout(debounceRef.current);\n },\n [],\n );\n const emitSizeChange = React.useCallback((value: number, meta: SizeChangeMeta) => {\n const { onSizeChange, sizeUpdate, sizeUpdateMs } = latest.current;\n if (!onSizeChange) return;\n if (sizeUpdate === 'debounce') {\n if (debounceRef.current) clearTimeout(debounceRef.current);\n debounceRef.current = setTimeout(() => {\n debounceRef.current = null;\n latest.current.onSizeChange?.(value, meta);\n }, sizeUpdateMs);\n return;\n }\n if (sizeUpdate === 'throttle') {\n const now = Date.now();\n if (now - throttleRef.current < sizeUpdateMs) return;\n throttleRef.current = now;\n }\n onSizeChange(value, meta);\n }, []);\n\n const toPx = React.useCallback((value: number | string | undefined) => normalizeToPx(value, orientation === 'vertical' ? 'horizontal' : 'vertical'), [orientation]);\n\n /**\n * The one way a size reaches the pane: the size variable, and the value\n * every handle of this pane announces. Once anything but `expandedSize` has\n * written a size (a default, a controlled value, a persisted value or a\n * resize), the pane owns that size and a new `expandedSize` leaves it alone.\n */\n const ownedRef = React.useRef(false);\n const writeSize = React.useCallback(\n (value: number, own: boolean) => {\n const el = elementRef.current;\n if (!el) return;\n el.style.setProperty(cssVarName, `${value}px`);\n for (const handle of el.querySelectorAll(':scope > .rt-ShellResizer')) handle.setAttribute('aria-valuenow', String(Math.round(value)));\n if (own) ownedRef.current = true;\n },\n [elementRef, cssVarName],\n );\n\n // expandedSize: the size until something else sets one. Declared first, so\n // the effects below win on mount.\n React.useLayoutEffect(() => {\n if (!ownedRef.current) writeSize(options.expandedSize, false);\n }, [options.expandedSize, writeSize]);\n\n // defaultSize: applied once, on mount.\n React.useLayoutEffect(() => {\n if (size !== undefined || defaultSize === undefined) return;\n const px = toPx(defaultSize);\n if (typeof px !== 'number' || !Number.isFinite(px)) return;\n const clamped = clampTo(px, minSize, maxSize);\n writeSize(clamped, true);\n emitSizeChange(clamped, { reason: 'init' });\n // An uncontrolled initial value: applied on mount and never re-applied.\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, []);\n\n // Controlled size. A drag stands until the app passes a different value.\n // Not while the pane is an overlay: an overlay keeps its designed size, and\n // an app's frame-sized limits (a maximum taken from the window) would\n // otherwise squeeze the drawer and report the squeezed size back. The size\n // is applied again when the pane returns to the frame.\n React.useLayoutEffect(() => {\n if (size === undefined || latest.current.overlayingNow()) return;\n const px = toPx(size);\n if (typeof px !== 'number' || !Number.isFinite(px)) return;\n const clamped = clampTo(px, minSize, maxSize);\n writeSize(clamped, true);\n emitSizeChange(clamped, { reason: 'controlled' });\n }, [size, minSize, maxSize, options.overlaying, toPx, writeSize, emitSizeChange]);\n\n // A persistence adapter from `paneId` when none is given.\n const adapter = React.useMemo<PaneSizePersistence | undefined>(() => {\n if (!paneId || persistence) return persistence;\n const key = `kookie-ui:shell:${name}:${paneId}`;\n return {\n load: () => {\n if (typeof window === 'undefined') return undefined;\n try {\n const stored = window.localStorage.getItem(key);\n return stored ? Number(stored) : undefined;\n } catch (err) {\n if (process.env.NODE_ENV !== 'production') console.warn(`Shell.${name}: failed to load persisted size`, err);\n return undefined;\n }\n },\n save: (value: number) => {\n if (typeof window === 'undefined') return;\n try {\n window.localStorage.setItem(key, String(value));\n } catch (err) {\n if (process.env.NODE_ENV !== 'production') console.warn(`Shell.${name}: failed to save persisted size`, err);\n }\n },\n };\n }, [name, paneId, persistence]);\n\n // Persisted size, loaded in a layout effect and clamped, so a reload does\n // not paint the default and then jump. Only where the pane is in the frame:\n // an overlay keeps its designed size.\n React.useLayoutEffect(() => {\n if (!resizable || !adapter?.load || latest.current.overlayingNow()) return undefined;\n let mounted = true;\n const apply = (value: number | undefined) => {\n if (!mounted || typeof value !== 'number' || !Number.isFinite(value)) return;\n const clamped = clampTo(value, minSize, maxSize);\n writeSize(clamped, true);\n latest.current.onResize?.(clamped);\n };\n const loaded = adapter.load();\n if (loaded instanceof Promise) {\n loaded.then(apply).catch((err) => {\n if (process.env.NODE_ENV !== 'production') console.warn(`Shell.${name}: failed to load persisted size`, err);\n });\n } else {\n apply(loaded);\n }\n return () => {\n mounted = false;\n };\n }, [resizable, adapter, options.overlaying, writeSize, minSize, maxSize, name]);\n\n const onResize = React.useCallback((value: number) => latest.current.onResize?.(value), []);\n const onResizeStart = React.useCallback((value: number) => {\n // A resize makes the size the user's: a new expandedSize no longer moves it.\n ownedRef.current = true;\n latest.current.onResizeStart?.(value);\n }, []);\n const onResizeEnd = React.useCallback(\n (value: number) => {\n latest.current.onResizeEnd?.(value);\n emitSizeChange(value, { reason: 'resize' });\n adapter?.save?.(value);\n },\n [emitSizeChange, adapter],\n );\n const requestCollapse = React.useCallback(() => latest.current.requestCollapse(), []);\n const requestToggle = React.useCallback(() => latest.current.requestToggle(), []);\n\n return React.useMemo(\n () => ({\n containerRef: elementRef,\n controls: options.elementId,\n cssVarName,\n minSize,\n maxSize,\n defaultSize: options.expandedSize,\n orientation,\n edge: options.edge,\n growth: options.growth,\n onResize,\n onResizeStart,\n onResizeEnd,\n target: name,\n collapsible: options.collapsible,\n snapPoints: options.snapPoints,\n snapTolerance: options.snapTolerance ?? 8,\n collapseThreshold: options.collapseThreshold,\n requestCollapse,\n requestToggle,\n }),\n [\n elementRef,\n options.elementId,\n cssVarName,\n minSize,\n maxSize,\n options.expandedSize,\n orientation,\n options.edge,\n options.growth,\n onResize,\n onResizeStart,\n onResizeEnd,\n name,\n options.collapsible,\n options.snapPoints,\n options.snapTolerance,\n options.collapseThreshold,\n requestCollapse,\n requestToggle,\n ],\n );\n}\n\n/** Splits a pane's children into its handles and the rest. */\nexport function splitHandles(children: React.ReactNode, handleType: React.ElementType) {\n const all = React.Children.toArray(children);\n const handles = all.filter((el) => React.isValidElement(el) && el.type === handleType) as React.ReactElement[];\n const content = all.filter((el) => !(React.isValidElement(el) && el.type === handleType));\n return { handles, content };\n}\n"],
|
|
5
|
+
"mappings": "wCAEA,UAAYA,MAAW,QA+CvB,IAAMC,EAAU,CAACC,EAAeC,EAAyBC,IAA4B,KAAK,IAAID,GAAOD,EAAO,KAAK,IAAIE,GAAOF,EAAOA,CAAK,CAAC,EAGlI,SAASG,EAAiBC,EAAmD,CAClF,GAAM,CAAE,KAAAC,EAAM,WAAAC,EAAY,WAAAC,EAAY,YAAAC,EAAa,QAAAC,EAAS,QAAAC,EAAS,UAAAC,EAAW,KAAAC,EAAM,YAAAC,EAAa,OAAAC,EAAQ,YAAAC,CAAY,EAAIX,EAKrHY,EAAe,SAAOZ,CAAO,EAC7B,kBAAgB,IAAM,CAC1BY,EAAO,QAAUZ,CACnB,CAAC,EAED,IAAMa,EAAoB,SAA6C,IAAI,EACrEC,EAAoB,SAAO,CAAC,EAC5B,YACJ,IAAM,IAAM,CACND,EAAY,SAAS,aAAaA,EAAY,OAAO,CAC3D,EACA,CAAC,CACH,EACA,IAAME,EAAuB,cAAY,CAACnB,EAAeoB,IAAyB,CAChF,GAAM,CAAE,aAAAC,EAAc,WAAAC,EAAY,aAAAC,CAAa,EAAIP,EAAO,QAC1D,GAAKK,EACL,IAAIC,IAAe,WAAY,CACzBL,EAAY,SAAS,aAAaA,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C,EAA2BC,EAA+B,CACrF,IAAMC,EAAY,WAAS,QAAQF,CAAQ,EACrCG,EAAUD,EAAI,OAAQnB,GAAa,iBAAeA,CAAE,GAAKA,EAAG,OAASkB,CAAU,EAC/EG,EAAUF,EAAI,OAAQnB,GAAO,EAAQ,iBAAeA,CAAE,GAAKA,EAAG,OAASkB,EAAW,EACxF,MAAO,CAAE,QAAAE,EAAS,QAAAC,CAAQ,CAC5B",
|
|
6
|
+
"names": ["React", "clampTo", "value", "min", "max", "useResizablePane", "options", "name", "elementRef", "cssVarName", "orientation", "minSize", "maxSize", "resizable", "size", "defaultSize", "paneId", "persistence", "latest", "debounceRef", "throttleRef", "emitSizeChange", "meta", "onSizeChange", "sizeUpdate", "sizeUpdateMs", "now", "toPx", "normalizeToPx", "ownedRef", "writeSize", "own", "el", "handle", "px", "clamped", "adapter", "key", "stored", "mounted", "apply", "loaded", "err", "onResize", "onResizeStart", "onResizeEnd", "requestCollapse", "requestToggle", "splitHandles", "children", "handleType", "all", "handles", "content"]
|
|
7
|
+
}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{a as p}from"./chunk-OO652UQW.js";import{a as t}from"./chunk-GSTOGDAJ.js";import{a as o}from"./chunk-
|
|
2
|
-
//# sourceMappingURL=chunk-
|
|
1
|
+
import{a as p}from"./chunk-OO652UQW.js";import{a as t}from"./chunk-GSTOGDAJ.js";import{a as o}from"./chunk-UBSLEGQZ.js";import*as r from"react";import C from"classnames";import{Slot as u}from"radix-ui";var y=r.forwardRef((a,s)=>{let{asChild:m,className:d,panelBackground:n,material:i,flush:f,inset:c,...P}=o(a,p,t),e=i||n,l=m?u.Root:"div";return r.createElement(l,{ref:s,...P,"data-panel-background":e,"data-material":e,"data-flush":f?"true":void 0,"data-inset":c?"true":void 0,className:C("rt-reset","rt-BaseCard","rt-Card",d)})});y.displayName="Card";export{y as a};
|
|
2
|
+
//# sourceMappingURL=chunk-C5RVO3C3.js.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{a as M}from"./chunk-
|
|
2
|
-
//# sourceMappingURL=chunk-
|
|
1
|
+
import{a as M}from"./chunk-IDUVJJYG.js";import{a as T}from"./chunk-GFOSP3PZ.js";import{a as D}from"./chunk-K53W3ELO.js";import{a as x}from"./chunk-VX44UTQ5.js";import{a as H}from"./chunk-ERGJN7FJ.js";import{a as N}from"./chunk-GSTOGDAJ.js";import{a as w}from"./chunk-UBSLEGQZ.js";import*as e from"react";import k from"classnames";var U=e.forwardRef((o,r)=>{let j=typeof o.width=="number"?o.width:void 0,W=typeof o.height=="number"?o.height:void 0,a="fill"in o&&o.fill===!0,{as:h="img",asChild:V,fill:X,className:y,style:s,loading:O="lazy",alt:z,src:n,placeholder:l,showSkeleton:A=!1,fadeIn:i=!0,loadingAriaLabel:F="Loading image...",errorAriaLabel:G="Failed to load image",radius:_,caption:u,onLoad:P,onError:I,...q}=w(o,T,N,H,x,D),B=h!=="img"?{width:j,height:W,...a?{fill:!0}:{}}:{},[m,p]=e.useState("loading"),[J,c]=e.useState(!!l),v=e.useRef(null),K=e.useCallback(t=>{p("loaded"),c(!1),P?.(t)},[P]),Q=e.useCallback(t=>{p("error"),c(!1),I?.(t)},[I]);if(e.useEffect(()=>{let t=v.current;t&&t.complete&&t.naturalWidth>0&&(p("loaded"),c(!1))},[n]),!n)return console.warn("Image component: src prop is required"),null;let d=m==="loading",g=m==="error",E=m==="loaded",f=a?{display:"block",opacity:i?E?1:0:1,transition:i?"opacity 0.3s ease-out":"none"}:{width:"100%",height:"100%",display:"block",opacity:i?E?1:0:1,transition:i?"opacity 0.3s ease-out":"none"},R=e.createElement(h,{ref:t=>{v.current=t,typeof r=="function"?r(t):r&&(r.current=t)},loading:O,style:a?f:{...f,position:"relative",zIndex:1},className:k("rt-reset","rt-Image"),alt:z,src:n,"data-radius":_,onLoad:K,onError:Q,"aria-busy":d,"aria-invalid":g,"aria-describedby":g?"image-error":void 0,...B,...q}),L=d&&e.createElement("div",{className:"rt-sr-only","aria-live":"polite",role:"status"},F),b=g&&e.createElement("div",{id:"image-error",className:"rt-sr-only","aria-live":"polite",role:"alert"},G),C=A&&d&&e.createElement(M,{width:"100%",height:"100%",style:{position:"absolute",inset:0}}),S=l&&J&&e.createElement("img",{style:{...f,position:"absolute",inset:0,filter:"blur(4px)",opacity:.7,zIndex:0},className:k("rt-reset","rt-Image","rt-Image--placeholder"),alt:"",src:l});if(!u){let t=a?{position:"absolute",inset:0,...s}:{position:"relative",...s};return e.createElement("div",{className:y,style:t},L,b,C,S,R)}return e.createElement("div",{className:y,style:{display:"flex",flexDirection:"column",...s}},e.createElement("div",{style:{position:"relative",flex:"1 1 0%",minHeight:0}},L,b,C,S,R),e.createElement("div",{className:"rt-Image-caption",style:{flex:"0 0 auto"}},u))});U.displayName="Image";export{U as a};
|
|
2
|
+
//# sourceMappingURL=chunk-CBNTPHYK.js.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{a as c}from"./chunk-Y3A6ZU24.js";import{a as N}from"./chunk-
|
|
2
|
-
//# sourceMappingURL=chunk-
|
|
1
|
+
import{a as c}from"./chunk-Y3A6ZU24.js";import{a as N}from"./chunk-ZJ33QP5N.js";import{b as v}from"./chunk-FWB47YCH.js";import{a as m}from"./chunk-UBSLEGQZ.js";import{a as R}from"./chunk-OS3FCYZY.js";var d={};R(d,{Actions:()=>P,Logo:()=>b,Navigation:()=>f,Root:()=>l});import*as o from"react";import p from"classnames";var l=o.forwardRef((e,s)=>{let{children:i,className:n,...a}=m(e,c),r=e.position??"fixed",t=e.size??"2";return o.createElement("header",{...a,ref:s,className:p("rt-NavbarRoot",n),"data-position":r,"data-size":t},o.createElement("div",{className:"rt-NavbarContainer"},i))});l.displayName="Navbar.Root";var b=o.forwardRef(({asChild:e,gap:s="2",align:i="center",justify:n="start",className:a,...r},t)=>e?o.createElement(v,{ref:t,className:p("rt-NavbarLogo",a),...r}):o.createElement(N,{ref:t,gap:s,align:i,justify:n,className:p("rt-NavbarLogo",a),...r}));b.displayName="Navbar.Logo";var f=o.forwardRef(({asChild:e,gap:s="4",align:i="center",justify:n="center",className:a,...r},t)=>e?o.createElement(v,{ref:t,className:p("rt-NavbarNavigation",a),role:"navigation",...r}):o.createElement(N,{ref:t,gap:s,align:i,justify:n,className:p("rt-NavbarNavigation",a),role:"navigation",...r}));f.displayName="Navbar.Navigation";var P=o.forwardRef(({asChild:e,gap:s="4",align:i="center",justify:n="end",className:a,...r},t)=>e?o.createElement(v,{ref:t,className:p("rt-NavbarActions",a),...r}):o.createElement(N,{ref:t,gap:s,align:i,justify:n,className:p("rt-NavbarActions",a),...r}));P.displayName="Navbar.Actions";export{l as a,b,f as c,P as d,d as e};
|
|
2
|
+
//# sourceMappingURL=chunk-CRBOJ7N7.js.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{a as m,b as T,c as N}from"./chunk-EBQZ3Z22.js";import{b as h,c as I}from"./chunk-IX5HIHVI.js";import{b as v,c as y}from"./chunk-SEY4NA45.js";import{a as g}from"./chunk-GSTOGDAJ.js";import{a as f}from"./chunk-
|
|
2
|
-
//# sourceMappingURL=chunk-
|
|
1
|
+
import{a as m,b as T,c as N}from"./chunk-EBQZ3Z22.js";import{b as h,c as I}from"./chunk-IX5HIHVI.js";import{b as v,c as y}from"./chunk-SEY4NA45.js";import{a as g}from"./chunk-GSTOGDAJ.js";import{a as f}from"./chunk-UBSLEGQZ.js";import{a as A}from"./chunk-OS3FCYZY.js";var M={};A(M,{Content:()=>w,Group:()=>G,Item:()=>E,Label:()=>L,Root:()=>x,Separator:()=>D,Trigger:()=>b});import*as e from"react";import c from"classnames";import{Select as a,ScrollArea as S}from"radix-ui";var u=e.createContext({}),x=t=>{let{children:o,size:r=m.size.default,...l}=t;return e.createElement(a.Root,{...l},e.createElement(u.Provider,{value:e.useMemo(()=>({size:r}),[r])},o))};x.displayName="Select.Root";var b=e.forwardRef((t,o)=>{let r=e.useContext(u),{children:l,className:i,color:n,radius:P,placeholder:d,error:p,loading:s,disabled:R,readOnly:C,...V}=f({size:r?.size,...t},{size:m.size},T,g),{panelBackground:z}=t,k=e.useMemo(()=>({"aria-invalid":p||void 0,"aria-busy":s||void 0,"aria-disabled":R||void 0,"aria-readonly":C||void 0}),[p,s,R,C]);return e.createElement(a.Trigger,{asChild:!0},e.createElement("button",{"data-accent-color":n,"data-radius":P,"data-panel-background":z,"data-error":p,"data-loading":s,...V,...k,ref:o,className:c("rt-reset","rt-SelectTrigger",i)},e.createElement("span",{className:"rt-SelectTriggerInner"},e.createElement(a.Value,{placeholder:d},l)),e.createElement(a.Icon,{asChild:!0},s?e.createElement("div",{className:"rt-SelectIcon rt-SelectLoadingIcon","aria-hidden":"true"},e.createElement("svg",{width:"16",height:"16",viewBox:"0 0 16 16",fill:"none"},e.createElement("circle",{cx:"8",cy:"8",r:"7",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeDasharray:"32",strokeDashoffset:"32",className:"rt-SelectLoadingIconCircle"}))):e.createElement(I,{className:"rt-SelectIcon"}))))});b.displayName="Select.Trigger";var w=e.forwardRef((t,o)=>{let r=e.useContext(u),{className:l,children:i,color:n,container:P,...d}=f({size:r?.size,...t},{size:m.size},N),p=v(),s=n||p.accentColor;return e.createElement(a.Portal,{container:P},e.createElement(y,{asChild:!0},e.createElement(a.Content,{"data-accent-color":s,sideOffset:4,...d,asChild:!1,ref:o,className:c("rt-PopperContent","rt-BaseMenuContent","rt-SelectContent",l)},e.createElement(S.Root,{type:"auto",className:"rt-ScrollAreaRoot"},e.createElement(a.Viewport,{asChild:!0,className:c("rt-BaseMenuViewport","rt-SelectViewport")},e.createElement(S.Viewport,{className:"rt-ScrollAreaViewport",style:{overflowY:void 0}},i)),e.createElement(S.Scrollbar,{className:"rt-ScrollAreaScrollbar rt-r-size-1",orientation:"vertical"},e.createElement(S.Thumb,{className:"rt-ScrollAreaThumb"}))))))});w.displayName="Select.Content";var E=e.forwardRef((t,o)=>{let{className:r,children:l,...i}=t,n=typeof l!="string";return e.createElement(a.Item,{...i,asChild:!1,ref:o,className:c("rt-reset","rt-BaseMenuItem","rt-SelectItem",{"rt-SelectItemRich":n},r)},e.createElement(a.ItemIndicator,{className:"rt-SelectItemIndicator"},e.createElement(h,{className:"rt-SelectItemIndicatorIcon"})),e.createElement(a.ItemText,null,l))});E.displayName="Select.Item";var G=e.forwardRef(({className:t,...o},r)=>e.createElement(a.Group,{...o,asChild:!1,ref:r,className:c("rt-SelectGroup",t)}));G.displayName="Select.Group";var L=e.forwardRef(({className:t,...o},r)=>e.createElement(a.Label,{...o,asChild:!1,ref:r,className:c("rt-BaseMenuLabel","rt-SelectLabel",t)}));L.displayName="Select.Label";var D=e.forwardRef(({className:t,...o},r)=>e.createElement(a.Separator,{...o,asChild:!1,ref:r,className:c("rt-BaseMenuSeparator","rt-SelectSeparator",t)}));D.displayName="Select.Separator";export{x as a,b,w as c,E as d,G as e,L as f,D as g,M as h};
|
|
2
|
+
//# sourceMappingURL=chunk-DCIQHXAR.js.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{a as t}from"./chunk-
|
|
2
|
-
//# sourceMappingURL=chunk-
|
|
1
|
+
import{a as t}from"./chunk-XDDKT4NF.js";import{a as r}from"./chunk-UBSLEGQZ.js";import*as o from"react";import a from"classnames";import{Slot as g}from"radix-ui";var P=o.forwardRef((e,p)=>{let{asChild:s,className:n,...m}=r(e,t),f=s?g.Root:"strong";return o.createElement(f,{...m,ref:p,className:a("rt-Strong",n)})});P.displayName="Strong";export{P as a};
|
|
2
|
+
//# sourceMappingURL=chunk-EHBAK3LQ.js.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{a as b}from"./chunk-PS6NEG5A.js";import{a as v}from"./chunk-GSTOGDAJ.js";import{a as N}from"./chunk-
|
|
2
|
-
//# sourceMappingURL=chunk-
|
|
1
|
+
import{a as b}from"./chunk-PS6NEG5A.js";import{a as v}from"./chunk-GSTOGDAJ.js";import{a as N}from"./chunk-UBSLEGQZ.js";import{a as f}from"./chunk-CFNESRYI.js";import{a as P}from"./chunk-OS3FCYZY.js";var d={};P(d,{Link:()=>l,Root:()=>c});import*as a from"react";import T from"classnames";import{NavigationMenu as t}from"radix-ui";var c=a.forwardRef((r,n)=>{let{children:e,className:s,color:p,panelBackground:o,...i}=N(r,f,v);return a.createElement(t.Root,{className:"rt-TabNavRoot","data-accent-color":p,...i,asChild:!1,ref:n},a.createElement(t.List,{className:T("rt-reset","rt-BaseTabList","rt-TabNavList",s),"data-panel-background":o},e))});c.displayName="TabNav.Root";var l=a.forwardRef((r,n)=>{let{asChild:e,children:s,className:p,active:o,...i}=r;return a.createElement(t.Item,{className:"rt-TabNavItem"},a.createElement(t.Link,{...i,ref:n,className:T("rt-reset","rt-BaseTabListTrigger","rt-TabNavLink",p),onSelect:void 0,asChild:e,"aria-current":o?"page":void 0,"data-active":o||void 0},b({asChild:e,children:s},m=>a.createElement(a.Fragment,null,a.createElement("span",{className:"rt-BaseTabListTriggerInner rt-TabNavLinkInner"},m),a.createElement("span",{className:"rt-BaseTabListTriggerInnerHidden rt-TabNavLinkInnerHidden"},m)))))});l.displayName="TabNav.Link";export{c as a,l as b,d as c};
|
|
2
|
+
//# sourceMappingURL=chunk-F3AXE27Q.js.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{a,b as i}from"./chunk-IX5HIHVI.js";import{a as p}from"./chunk-F6V7GBNQ.js";import{a as c}from"./chunk-GSTOGDAJ.js";import{a as t}from"./chunk-
|
|
2
|
-
//# sourceMappingURL=chunk-
|
|
1
|
+
import{a,b as i}from"./chunk-IX5HIHVI.js";import{a as p}from"./chunk-F6V7GBNQ.js";import{a as c}from"./chunk-GSTOGDAJ.js";import{a as t}from"./chunk-UBSLEGQZ.js";import*as e from"react";import P from"classnames";import{Checkbox as s}from"radix-ui";import{useControllableState as b}from"radix-ui/internal";var y=e.forwardRef((h,m)=>{let{className:n,color:k,material:C,checked:f,defaultChecked:o,onCheckedChange:d,...l}=t(h,p,c),[r,x]=b({prop:f,defaultProp:o??!1,onChange:d});return e.createElement(s.Root,{"data-accent-color":k,"data-material":C,...l,defaultChecked:o,checked:r,onCheckedChange:x,asChild:!1,ref:m,className:P("rt-reset","rt-BaseCheckboxRoot","rt-CheckboxRoot",n)},e.createElement(s.Indicator,{asChild:!0,className:"rt-BaseCheckboxIndicator rt-CheckboxIndicator"},r==="indeterminate"?e.createElement(a,null):e.createElement(i,null)))});y.displayName="Checkbox";export{y as a};
|
|
2
|
+
//# sourceMappingURL=chunk-FB3PD4Z3.js.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{a as P}from"./chunk-
|
|
2
|
-
//# sourceMappingURL=chunk-
|
|
1
|
+
import{a as P}from"./chunk-C5RVO3C3.js";import{a as u}from"./chunk-PYXMGEO7.js";import{a as p}from"./chunk-ZJ33QP5N.js";import*as e from"react";import c from"classnames";var h=e.forwardRef((l,o)=>{let{anchor:r="top",floating:t=!1,offset:s="2",size:n="1",variant:i="ghost",material:N,className:x,style:R,children:L,...H}=l,T=r==="top"||r==="bottom",y=e.useRef(null),F=e.useCallback(a=>{y.current=a,typeof o=="function"?o(a):o&&(o.current=a)},[o]);e.useEffect(()=>{let a=y.current;if(!a)return;let m=a.parentElement;if(!m)return;let d=()=>{let b=T?a.offsetHeight:a.offsetWidth;if(t){let j=getComputedStyle(a),w=parseFloat(j.marginTop)||0;b+=w*2}T?m.style.setProperty("--rt-toolbar-height",`${b}px`):m.style.setProperty("--rt-toolbar-width",`${b}px`)};d();let g=new ResizeObserver(d);return g.observe(a),()=>g.disconnect()},[T,t]);let z=t?{margin:`var(--space-${s})`,...R}:R;return e.createElement(P,{ref:F,size:n,variant:i,material:N,"data-anchor":r,"data-floating":t||void 0,className:c("rt-Toolbar",x),style:z,...H},e.createElement("div",{className:"rt-ToolbarInner"},L))});h.displayName="Toolbar.Root";var S=e.forwardRef(({gap:l="2",align:o="center",className:r,children:t,...s},n)=>e.createElement(p,{ref:n,align:o,gap:l,className:c("rt-ToolbarSection","rt-ToolbarLeft",r),...s},t));S.displayName="Toolbar.Left";var C=e.forwardRef(({gap:l="2",align:o="center",justify:r="center",className:t,children:s,...n},i)=>e.createElement(p,{ref:i,align:o,justify:r,gap:l,className:c("rt-ToolbarSection","rt-ToolbarCenter",t),...n},s));C.displayName="Toolbar.Center";var E=e.forwardRef(({gap:l="2",align:o="center",justify:r="end",className:t,children:s,...n},i)=>e.createElement(p,{ref:i,align:o,justify:r,gap:l,className:c("rt-ToolbarSection","rt-ToolbarRight",t),...n},s));E.displayName="Toolbar.Right";var v=e.forwardRef(({className:l,size:o="2",weight:r="medium",truncate:t=!0,children:s,...n},i)=>e.createElement(u,{ref:i,size:o,weight:r,truncate:t,className:c("rt-ToolbarTitle",l),...n},s));v.displayName="Toolbar.Title";var f=h;f.Left=S;f.Center=C;f.Right=E;f.Title=v;export{h as a,S as b,C as c,E as d,v as e,f};
|
|
2
|
+
//# sourceMappingURL=chunk-FEAOFF77.js.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{a as C}from"./chunk-OJU5GCDZ.js";import{a as x}from"./chunk-GSTOGDAJ.js";import{a as P}from"./chunk-
|
|
2
|
-
//# sourceMappingURL=chunk-
|
|
1
|
+
import{a as C}from"./chunk-OJU5GCDZ.js";import{a as x}from"./chunk-GSTOGDAJ.js";import{a as P}from"./chunk-UBSLEGQZ.js";import*as t from"react";import j from"classnames";import{Slider as b}from"radix-ui";var G=t.forwardRef((v,N)=>{let{className:A,color:V,radius:k,tabIndex:y,...i}=P(v,C,x),{ticks:o,showTickLabels:M,snapToTicks:p,unit:l}=v,u=i.min??0,s=i.max??100,c=i.value??i.defaultValue??[u],S=Array.isArray(c)&&c.length>1,w=i.step,n=t.useMemo(()=>o?[...o].sort((e,r)=>e.value-r.value):[],[o]),R=t.useCallback(e=>{if(!p||!n.length)return e;let r=0,a=n.length-1;if(e<=n[r].value)return n[r].value;if(e>=n[a].value)return n[a].value;for(;r<=a;){let f=Math.floor((r+a)/2);if(n[f].value===e)return e;n[f].value<e?r=f+1:a=f-1}let D=Math.abs(e-n[a].value),E=Math.abs(e-n[r].value);return D<=E?n[a].value:n[r].value},[p,n]),h=t.useCallback(e=>{let r=a=>l?`${a} ${l}`:a.toString();return e.length===1?`${r(e[0])} out of ${r(s)}`:e.length===2?`${r(e[0])} to ${r(e[1])} out of ${r(s)}`:`${e.map(r).join(", ")} out of ${r(s)}`},[l,s]),$=t.useMemo(()=>o?o.map((e,r)=>({...e,percentage:(e.value-u)/(s-u)*100,index:r})):null,[o,u,s]),m=t.useRef(null),d=t.useRef(null),{onValueChange:g}=i,T=t.useCallback(e=>{let r=p&&o?e.map(a=>R(a)):e;if(m.current){let a=h(r);m.current.textContent=a,d.current&&clearTimeout(d.current),d.current=setTimeout(()=>{m.current&&(m.current.textContent="")},1e3)}g?.(r)},[p,o,R,h,g]);return t.useEffect(()=>()=>{d.current&&clearTimeout(d.current)},[]),t.createElement("div",{className:"rt-SliderContainer"},t.createElement("div",{ref:m,"aria-live":"polite","aria-atomic":"true",className:"sr-only",style:{position:"absolute",left:"-10000px",width:"1px",height:"1px",overflow:"hidden"}}),t.createElement(b.Root,{"data-accent-color":V,"data-radius":k,ref:N,...i,step:w,onValueChange:T,asChild:!1,className:j("rt-SliderRoot",A),"aria-valuemin":u,"aria-valuemax":s,"aria-valuenow":Array.isArray(c)?c[0]:c,"aria-valuetext":h(c),"aria-label":v["aria-label"]||`${S?"Range":"Value"} slider`},t.createElement(b.Track,{className:"rt-SliderTrack"},t.createElement(b.Range,{className:"rt-SliderRange","data-inverted":i.inverted?"":void 0})),(i.value??i.defaultValue??[]).map((e,r)=>t.createElement(b.Thumb,{key:r,className:"rt-SliderThumb",...y!==void 0?{tabIndex:y}:void 0,"aria-label":S?`${r===0?"Minimum":r===1?"Maximum":`Thumb ${r+1}`} value: ${l?`${e} ${l}`:e}`:`Slider value: ${l?`${e} ${l}`:e}`,"aria-valuetext":l?`${e} ${l}`:e.toString()}))),$&&t.createElement("div",{className:"rt-SliderTicks",role:"group","aria-label":"Slider tick marks"},$.map(e=>t.createElement("button",{key:e.index,className:"rt-SliderTick",style:{left:`${e.percentage}%`,transform:"translateX(-50%)"},onClick:()=>{let r=i.value??i.defaultValue??[u],a=Array.isArray(r)?r.map(()=>e.value):[e.value];T(a)},"aria-label":`Set to ${e.label||(l?`${e.value} ${l}`:e.value)}`,"aria-describedby":e.label?void 0:`tick-${e.index}-value`,type:"button"},t.createElement("div",{className:"rt-SliderTickMark"}),e.label&&M!==!1&&t.createElement("div",{className:"rt-SliderTickLabel"},e.label),!e.label&&t.createElement("span",{id:`tick-${e.index}-value`,className:"sr-only"},l?`${e.value} ${l}`:e.value)))))});G.displayName="Slider";export{G as a};
|
|
2
|
+
//# sourceMappingURL=chunk-G4YKBAZT.js.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{b as E,d as L}from"./chunk-
|
|
2
|
-
//# sourceMappingURL=chunk-
|
|
1
|
+
import{b as E,d as L}from"./chunk-UNWPH3SO.js";import{b as N}from"./chunk-SEY4NA45.js";import*as e from"react";import S from"classnames";import{useVirtualizer as J}from"@tanstack/react-virtual";var Q=e.memo(function({label:r,isHighlighted:o,id:u,style:x,tabIndex:y,"data-highlighted":m,"data-index":p,onMouseEnter:f,onMouseLeave:v,onClick:h,onKeyDown:g}){return e.createElement("div",{id:u,role:"menuitem",className:S("rt-reset","rt-BaseMenuItem","rt-VirtualMenuItem"),style:x,tabIndex:y,"data-highlighted":m,"data-index":p,onMouseEnter:f,onMouseLeave:v,onClick:h,onKeyDown:g},r)},(n,r)=>!(n.label!==r.label||n["data-highlighted"]!==r["data-highlighted"]||n.style.height!==r.style.height||n.style.transform!==r.style.transform||n.tabIndex!==r.tabIndex||n.id!==r.id));function w({items:n,itemLabel:r,renderItem:o,size:u,estimatedItemSize:x,overscan:y=5,onSelect:m,className:p,style:f,"aria-label":v}){let h=e.useId(),g=e.useRef(null),[T,l]=e.useState(-1),{isInsideMenu:K,size:P,itemHeight:$}=L(),{scaling:k}=N(),I=x??(u?E(u,k):$??E(P??"2",k));if(!r&&!o)throw new Error("VirtualMenu requires either itemLabel or renderItem prop");let A=e.useMemo(()=>r?typeof r=="function"?r:t=>t[r]:null,[r]),c=e.useMemo(()=>n.length===0||T<0?-1:Math.min(T,n.length-1),[T,n.length]),B=e.useMemo(()=>typeof I=="function"?I:()=>I,[I]),M=J({count:n.length,getScrollElement:()=>g.current,estimateSize:B,overscan:y}),j=M.getVirtualItems(),R=e.useRef(n),b=e.useRef(m);R.current=n,b.current=m;let d=e.useRef(M.scrollToIndex);d.current=M.scrollToIndex;let H=e.useRef(c);H.current=c;let q=e.useCallback(t=>{let s=t.currentTarget.dataset.index;s!=null&&l(Number(s))},[]),O=e.useCallback(t=>{let s=t.currentTarget.dataset.index;if(s!=null){let a=Number(s),i=R.current;a>=0&&a<i.length&&b.current?.(i[a],a)}},[]),U=e.useCallback(()=>{},[]),W=e.useCallback(t=>{if(t.key==="Enter"||t.key===" "){t.preventDefault();let s=t.currentTarget.dataset.index;if(s!=null){let a=Number(s),i=R.current;a>=0&&a<i.length&&b.current?.(i[a],a)}}},[]),Y=e.useCallback(t=>{let s=R.current,a=H.current;switch(t.key){case"ArrowDown":{t.preventDefault();let i=a<s.length-1?a+1:0;l(i),d.current(i,{align:"auto"});break}case"ArrowUp":{t.preventDefault();let i=a>0?a-1:s.length-1;l(i),d.current(i,{align:"auto"});break}case"Home":{t.preventDefault(),l(0),d.current(0,{align:"start"});break}case"End":{t.preventDefault();let i=s.length-1;l(i),d.current(i,{align:"end"});break}case"Enter":case" ":{t.preventDefault(),a>=0&&a<s.length&&b.current?.(s[a],a);break}case"Tab":{t.preventDefault();break}case"Escape":{t.currentTarget.blur();break}}},[]),V=e.useCallback(t=>`${h}-item-${t}`,[h]),_=e.useMemo(()=>({overflow:"auto",position:"relative",...f}),[f]),C=M.getTotalSize(),F=e.useMemo(()=>({height:`${C}px`,width:"100%",position:"relative"}),[C]);return e.createElement("div",{ref:g,role:K?"group":"menu","aria-label":v,"aria-activedescendant":c>=0?V(c):void 0,tabIndex:0,onKeyDown:Y,className:S("rt-VirtualMenuRoot",p),style:_},e.createElement("div",{className:"rt-VirtualMenuViewport",style:F},j.map(t=>{let s=n[t.index],a=t.index,i=c===a,G={height:t.size,transform:`translateY(${t.start}px)`},D={id:V(a),isHighlighted:i,style:G,tabIndex:i?0:-1,"data-highlighted":i?!0:void 0,"data-index":a,onMouseEnter:q,onMouseLeave:U,onClick:O,onKeyDown:W};return o?e.createElement(o,{key:t.key,item:s,index:a,...D}):e.createElement(Q,{key:t.key,label:A(s),...D})})))}w.displayName="VirtualMenu";var z=e.forwardRef(({className:n,children:r,...o},u)=>e.createElement("div",{ref:u,role:"menuitem",className:S("rt-reset","rt-BaseMenuItem","rt-VirtualMenuItem",n),...o},r));z.displayName="VirtualMenu.Item";var X=e.memo(z,(n,r)=>{let o=n.style,u=r.style;return!(o?.height!==u?.height||o?.transform!==u?.transform||n["data-highlighted"]!==r["data-highlighted"]||n.tabIndex!==r.tabIndex||n.id!==r.id||n.className!==r.className||n.children!==r.children)}),re=Object.assign(w,{Item:X});export{re as a};
|
|
2
|
+
//# sourceMappingURL=chunk-GDAKJS64.js.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{a as p}from"./chunk-CRSHBENJ.js";import{a as e}from"./chunk-GSTOGDAJ.js";import{a as o}from"./chunk-
|
|
2
|
-
//# sourceMappingURL=chunk-
|
|
1
|
+
import{a as p}from"./chunk-CRSHBENJ.js";import{a as e}from"./chunk-GSTOGDAJ.js";import{a as o}from"./chunk-UBSLEGQZ.js";import*as r from"react";import i from"classnames";var P=r.forwardRef((t,a)=>{let{className:s,color:m,decorative:n,...f}=o(t,p,e);return r.createElement("span",{"data-accent-color":m,role:n?void 0:"separator",...f,ref:a,className:i("rt-Separator",s)})});P.displayName="Separator";export{P as a};
|
|
2
|
+
//# sourceMappingURL=chunk-GGSJXOKR.js.map
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
import{a as C,b,c as O,d as $,g as B,k as _,m as q}from"./chunk-A2XVR7GL.js";import{a as S,b as U}from"./chunk-3XSB7YIM.js";import*as t from"react";var M=e=>typeof e=="object"&&e!==null;function ee(e){for(let l of["initial","xs","sm","md","lg","xl"]){let a=e[l];if(a!==void 0)return a}return"closed"}function oe(e){let{name:l,label:a,propNames:o,presentationTable:u,builtIn:h}=e,d=_(`Shell.${a}`),F=t.useId(),v=e.id??`shell-${l}${F}`,c=e.controlled!==void 0,E=M(e.controlled);E&&(`${a}${o.controlled}${o.default}`,void 0);let p=E?e.controlled:void 0,L=p??(M(e.defaultValue)?e.defaultValue:void 0),G=$(L),[J,Q]=t.useState(()=>typeof e.defaultValue=="string"?e.defaultValue:"auto"),P=t.useMemo(()=>p?C(p,()=>ee(p)):C(L,n=>h(u[n])),[G,E,u,h]),r=J;c&&(r=p?"auto":e.controlled);let W=b(u)===void 0||r==="auto"&&b(P)===void 0,{breakpoint:I,ready:z}=U(W),H=n=>{let f=b(n);return f!==void 0?f:z?n[I]:void 0},i=r==="auto"?H(P):r,y=H(u),k=y==="overlay",s=i===void 0?void 0:i!=="closed",x=s===!0&&k,j=e.defaultValue,V=t.useRef({state:r,value:i,autoTable:P,defaultValue:j,controlled:c,onChange:e.onChange,toggleNext:e.toggleNext});t.useLayoutEffect(()=>{V.current={state:r,value:i,autoTable:P,defaultValue:j,controlled:c,onChange:e.onChange,toggleNext:e.toggleNext}});let m=t.useCallback(()=>{let n=V.current;return n.value!==void 0?n.value:n.state==="auto"?n.autoTable[S()]:void 0},[]),N=t.useCallback(()=>{let n=V.current;return typeof n.defaultValue=="string"?n.defaultValue:M(n.defaultValue)?n.autoTable[S()]:void 0},[]),g=t.useCallback((n,f)=>{let R=V.current;m()!==n&&(R.onChange?.(n,f),R.controlled||Q(n))},[m]),T=t.useCallback(n=>{let f=V.current,R=m()??"closed",Z=f.toggleNext?f.toggleNext(R,N()):R==="closed"?"open":"closed";g(Z,n)},[g,m,N]),D=t.useRef(null),X=t.useCallback(n=>{D.current=n},[]);t.useLayoutEffect(()=>{let n={name:l,id:v,el:D.current,value:i,presentation:y,presentationTable:u,overlayLive:x,size:e.size,setValue:g,toggle:T};return d.entries.set(l,n),B(d),()=>{d.entries.get(l)===n&&(d.entries.delete(l),B(d))}},[d,l,v,i,y,u,x,e.size,g,T]);let w=t.useRef({onExpand:e.onExpand,onCollapse:e.onCollapse});t.useLayoutEffect(()=>{w.current={onExpand:e.onExpand,onCollapse:e.onCollapse}});let A=t.useRef({state:r,shown:s});t.useEffect(()=>{let n=A.current;n.state!==r&&n.shown!==void 0&&s!==void 0&&n.shown!==s&&(s?w.current.onExpand?.():w.current.onCollapse?.()),A.current={state:r,shown:s}},[r,s]),t.useLayoutEffect(()=>{},[]);let K=t.useRef(c);t.useEffect(()=>{},[c,a,o.controlled]);let Y=q(d,l)&&s===!1&&!k;return{store:d,id:v,state:r,value:i,shown:s,presentation:y,overlaying:k,overlayLive:x,peeking:Y,ready:z,breakpoint:I,autoTable:P,setValue:g,toggle:T,defaultHereNow:N,setElement:X}}function le(e,l){let{state:a,value:o,presentation:u,shown:h}=e;return{...l,"data-state":a==="thin"?"open":a,"data-thin":a==="thin"?"":void 0,...a==="auto"?O("auto",e.autoTable):{},"data-presentation":u,"data-mode":o===void 0?void 0:o==="closed"?"collapsed":o==="thin"?"thin":"expanded","data-open":u==="stacked"&&h?"":void 0,"data-peek":e.peeking?"":void 0}}function ue(e,l){let a=$(e),o=t.useMemo(()=>C(e,()=>l),[a,l]),u=t.useMemo(()=>b(o)===void 0?O("presentation",o):{},[o]);return{table:o,attributes:u}}export{oe as a,le as b,ue as c};
|
|
2
|
+
//# sourceMappingURL=chunk-GMHA5CFH.js.map
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
{
|
|
2
|
+
"version": 3,
|
|
3
|
+
"sources": ["../../src/components/_internal/shell-pane.tsx"],
|
|
4
|
+
"sourcesContent": ["'use client';\n\nimport * as React from 'react';\nimport { readBreakpoint, useBreakpoint } from '../../hooks/use-breakpoint.js';\nimport type { Breakpoint, PaneName, PresentationValue } from '../shell.types.js';\nimport {\n constantOf,\n notifyShellStore,\n tableAttributes,\n tableOf,\n usePeeking,\n useShellStore,\n useStableKey,\n warnOnce,\n type OpenChangeReason,\n type PaneEntry,\n type PaneValue,\n type Table,\n} from './shell-store.js';\n\ntype ResponsiveValue = PaneValue | Partial<Record<Breakpoint, PaneValue>>;\n\nexport type UsePaneOptions = {\n name: PaneName;\n /** The component's display name, for warnings: `Inspector`, `Sidebar`, \u2026 */\n label: string;\n /** The prop names a warning should use: `open`/`defaultOpen`, or `state`/`defaultState`. */\n propNames: { controlled: string; default: string };\n id: string | undefined;\n /** The controlled value. A responsive object is deprecated: it is resolved against the current breakpoint. */\n controlled: ResponsiveValue | undefined;\n /**\n * The uncontrolled default. A single value fixes where the pane starts. A\n * responsive object leaves the pane untouched (`auto`), with that object as\n * what it shows at each breakpoint.\n */\n defaultValue: ResponsiveValue | undefined;\n /** The pane's presentation at every breakpoint. Pass a memoised table. */\n presentationTable: Table<PresentationValue>;\n /** What an untouched pane shows where no default says otherwise. Pass a module-level function. */\n builtIn: (presentation: PresentationValue) => PaneValue;\n /** Reports a change a user made. Never called on mount or on a resize. */\n onChange: ((value: PaneValue, reason: OpenChangeReason) => void) | undefined;\n /** The value a toggle moves to. Defaults to open and closed in turn. */\n toggleNext?: (current: PaneValue, defaultHere: PaneValue | undefined) => PaneValue;\n onExpand: (() => void) | undefined;\n onCollapse: (() => void) | undefined;\n /** The pane's designed open width, published for the panes beside it. */\n size: number;\n};\n\nexport type PaneController = ReturnType<typeof usePane>;\n\nconst isMap = (value: ResponsiveValue | undefined): value is Partial<Record<Breakpoint, PaneValue>> => typeof value === 'object' && value !== null;\n\n/** The first value a responsive object states, smallest breakpoint first. */\nfunction firstStated(map: Partial<Record<Breakpoint, PaneValue>>): PaneValue {\n for (const bp of ['initial', 'xs', 'sm', 'md', 'lg', 'xl'] as const) {\n const value = map[bp];\n if (value !== undefined) return value;\n }\n return 'closed';\n}\n\n/** Everything the togglable panes share: their state, their registry entry and their callbacks. */\nexport function usePane(options: UsePaneOptions) {\n const { name, label, propNames, presentationTable, builtIn } = options;\n const store = useShellStore(`Shell.${label}`);\n const generatedId = React.useId();\n const id = options.id ?? `shell-${name}${generatedId}`;\n\n const controlled = options.controlled !== undefined;\n const controlledIsMap = isMap(options.controlled);\n if (controlledIsMap) {\n warnOnce(\n `Shell.${label}: a responsive \\`${propNames.controlled}\\` is deprecated and is removed in 1.0. ` +\n `Pass a boolean and decide it from your own state, or use \\`${propNames.default}\\` with a responsive object.`,\n );\n }\n\n // A responsive controlled value is resolved the way a responsive default\n // is: it becomes the table an untouched pane follows, so the stylesheet\n // answers it at each breakpoint (right in the server HTML, with no\n // callback on a crossing) and the app's prop is still the only writer.\n const controlledMap = controlledIsMap ? (options.controlled as Partial<Record<Breakpoint, PaneValue>>) : undefined;\n const autoSource = controlledMap ?? (isMap(options.defaultValue) ? options.defaultValue : undefined);\n const autoKey = useStableKey(autoSource);\n const [inner, setInner] = React.useState<'auto' | PaneValue>(() => (typeof options.defaultValue === 'string' ? options.defaultValue : 'auto'));\n\n // What an untouched pane shows at each breakpoint: a responsive default\n // where it states one, the pane's own default where it does not.\n const autoTable = React.useMemo(\n () => (controlledMap ? tableOf<PaneValue>(controlledMap, () => firstStated(controlledMap)) : tableOf<PaneValue>(autoSource, (bp) => builtIn(presentationTable[bp]))),\n // `autoKey` stands for the responsive object, which is usually a new literal each render.\n // eslint-disable-next-line react-hooks/exhaustive-deps\n [autoKey, controlledIsMap, presentationTable, builtIn],\n );\n\n let state: 'auto' | PaneValue = inner;\n if (controlled) state = controlledMap ? 'auto' : (options.controlled as PaneValue);\n\n // Only a pane whose answer depends on the window subscribes to it, so a\n // pane with one presentation and one default never re-renders on a resize.\n const needsBreakpoint = constantOf(presentationTable) === undefined || (state === 'auto' && constantOf(autoTable) === undefined);\n const { breakpoint, ready } = useBreakpoint(needsBreakpoint);\n\n /** A table's value now: known without the window when it holds one value, else once the breakpoint is known. */\n const now = <T,>(table: Table<T>): T | undefined => {\n const constant = constantOf(table);\n if (constant !== undefined) return constant;\n return ready ? table[breakpoint] : undefined;\n };\n\n const value: PaneValue | undefined = state === 'auto' ? now(autoTable) : state;\n const presentation = now(presentationTable);\n const overlaying = presentation === 'overlay';\n const shown = value === undefined ? undefined : value !== 'closed';\n const overlayLive = shown === true && overlaying;\n\n // Stable actions over the latest values, so the registry entry changes only\n // when a fact it carries changes.\n const defaultValue = options.defaultValue;\n const latest = React.useRef({ state, value, autoTable, defaultValue, controlled, onChange: options.onChange, toggleNext: options.toggleNext });\n React.useLayoutEffect(() => {\n latest.current = { state, value, autoTable, defaultValue, controlled, onChange: options.onChange, toggleNext: options.toggleNext };\n });\n\n /**\n * What the pane shows, and its default, at the window's breakpoint right\n * now. Asked at the moment of an action rather than taken from the last\n * render: a touched pane no longer follows the window, and a click can land\n * before the mirror has resolved after hydration.\n */\n const valueNow = React.useCallback((): PaneValue | undefined => {\n const current = latest.current;\n if (current.value !== undefined) return current.value;\n return current.state === 'auto' ? current.autoTable[readBreakpoint()] : undefined;\n }, []);\n const defaultHereNow = React.useCallback((): PaneValue | undefined => {\n const current = latest.current;\n if (typeof current.defaultValue === 'string') return current.defaultValue;\n return isMap(current.defaultValue) ? current.autoTable[readBreakpoint()] : undefined;\n }, []);\n\n const setValue = React.useCallback(\n (next: PaneValue, reason: OpenChangeReason) => {\n const current = latest.current;\n if (valueNow() === next) return;\n current.onChange?.(next, reason);\n if (!current.controlled) setInner(next);\n },\n [valueNow],\n );\n\n const toggle = React.useCallback(\n (reason: OpenChangeReason) => {\n const current = latest.current;\n const from = valueNow() ?? 'closed';\n const next = current.toggleNext ? current.toggleNext(from, defaultHereNow()) : from === 'closed' ? 'open' : 'closed';\n setValue(next, reason);\n },\n [setValue, valueNow, defaultHereNow],\n );\n\n // The pane's element, for the Root's containment and focus.\n const elementRef = React.useRef<HTMLElement | null>(null);\n const setElement = React.useCallback((node: HTMLElement | null) => {\n elementRef.current = node;\n }, []);\n\n // Registration. A layout effect so a Trigger's aria attributes and the\n // Root's containment are right before the browser paints.\n React.useLayoutEffect(() => {\n const entry: PaneEntry = {\n name,\n id,\n el: elementRef.current,\n value,\n presentation,\n presentationTable,\n overlayLive,\n size: options.size,\n setValue,\n toggle,\n };\n store.entries.set(name, entry);\n notifyShellStore(store);\n return () => {\n if (store.entries.get(name) === entry) {\n store.entries.delete(name);\n notifyShellStore(store);\n }\n };\n }, [store, name, id, value, presentation, presentationTable, overlayLive, options.size, setValue, toggle]);\n\n // onExpand/onCollapse fire when the pane's state changes and that changes\n // whether it is shown: a user's toggle, or a controlled prop. Never on\n // mount, and never because the window crossed a breakpoint.\n const callbacks = React.useRef({ onExpand: options.onExpand, onCollapse: options.onCollapse });\n React.useLayoutEffect(() => {\n callbacks.current = { onExpand: options.onExpand, onCollapse: options.onCollapse };\n });\n const previous = React.useRef({ state, shown });\n React.useEffect(() => {\n const before = previous.current;\n if (before.state !== state && before.shown !== undefined && shown !== undefined && before.shown !== shown) {\n if (shown) callbacks.current.onExpand?.();\n else callbacks.current.onCollapse?.();\n }\n previous.current = { state, shown };\n }, [state, shown]);\n\n // Development guards. Once per mount, not once per render.\n React.useLayoutEffect(() => {\n if (process.env.NODE_ENV === 'production') return;\n if (options.controlled !== undefined && options.defaultValue !== undefined) {\n console.error(`Shell.${label}: Do not pass both \\`${propNames.controlled}\\` and \\`${propNames.default}\\`. Choose one.`);\n }\n // Mount only: this is the once-per-mount guard.\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, []);\n const wasControlled = React.useRef(controlled);\n React.useEffect(() => {\n if (process.env.NODE_ENV === 'production') return;\n if (wasControlled.current !== controlled) {\n console.warn(`Shell.${label}: Switching between controlled and uncontrolled \\`${propNames.controlled}\\` is not supported.`);\n wasControlled.current = controlled;\n }\n }, [controlled, label, propNames.controlled]);\n\n const peeking = usePeeking(store, name) && shown === false && !overlaying;\n\n return {\n store,\n id,\n state,\n value,\n shown,\n presentation,\n overlaying,\n overlayLive,\n peeking,\n ready,\n breakpoint,\n autoTable,\n setValue,\n toggle,\n defaultHereNow,\n setElement,\n };\n}\n\n/** The data attributes every togglable pane renders. */\nexport function paneAttributes(pane: PaneController, presentationAttributes: Record<string, string>) {\n const { state, value, presentation, shown } = pane;\n return {\n ...presentationAttributes,\n 'data-state': state === 'thin' ? 'open' : state,\n 'data-thin': state === 'thin' ? '' : undefined,\n ...(state === 'auto' ? tableAttributes('auto', pane.autoTable) : {}),\n 'data-presentation': presentation,\n 'data-mode': value === undefined ? undefined : value === 'closed' ? 'collapsed' : value === 'thin' ? 'thin' : 'expanded',\n // Kept for stylesheets written against 0.7: set while a stacked pane is open.\n 'data-open': presentation === 'stacked' && shown ? '' : undefined,\n 'data-peek': pane.peeking ? '' : undefined,\n } as const;\n}\n\n/** A pane's own presentation, as a table and as the attributes the stylesheet reads. */\nexport function usePresentationTable(presentation: Parameters<typeof tableOf<PresentationValue>>[0], fallback: PresentationValue) {\n const key = useStableKey(presentation);\n const table = React.useMemo(\n () => tableOf<PresentationValue>(presentation, () => fallback),\n // `key` stands for `presentation`, which is usually a new literal each render.\n // eslint-disable-next-line react-hooks/exhaustive-deps\n [key, fallback],\n );\n // One value is the plain `data-presentation` the pane renders anyway; several\n // are written per breakpoint, so the stylesheet can place the pane before\n // any script runs.\n const attributes = React.useMemo(() => (constantOf(table) === undefined ? tableAttributes('presentation', table) : ({} as Record<string, string>)), [table]);\n return { table, attributes };\n}\n"],
|
|
5
|
+
"mappings": "4HAEA,UAAYA,MAAW,QAmDvB,IAAMC,EAASC,GAAwF,OAAOA,GAAU,UAAYA,IAAU,KAG9I,SAASC,GAAYC,EAAwD,CAC3E,QAAWC,IAAM,CAAC,UAAW,KAAM,KAAM,KAAM,KAAM,IAAI,EAAY,CACnE,IAAMH,EAAQE,EAAIC,CAAE,EACpB,GAAIH,IAAU,OAAW,OAAOA,CAClC,CACA,MAAO,Q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CAMtB,EAAG,CAACA,EAAYR,EAAOC,EAAU,UAAU,CAAC,EAE5C,IAAMkD,EAAUC,EAAWhD,EAAOL,CAAI,GAAK8B,IAAU,IAAS,CAACD,EAE/D,MAAO,CACL,MAAAxB,EACA,GAAAG,EACA,MAAAW,EACA,MAAAzB,EACA,MAAAoC,EACA,aAAAF,EACA,WAAAC,EACA,YAAAE,EACA,QAAAqB,EACA,MAAA7B,EACA,WAAAD,EACA,UAAAL,EACA,SAAAqB,EACA,OAAAG,EACA,eAAAJ,EACA,WAAAO,CACF,CACF,CAGO,SAASU,GAAeC,EAAsBC,EAAgD,CACnG,GAAM,CAAE,MAAArC,EAAO,MAAAzB,EAAO,aAAAkC,EAAc,MAAAE,CAAM,EAAIyB,EAC9C,MAAO,CACL,GAAGC,EACH,aAAcrC,IAAU,OAAS,OAASA,EAC1C,YAAaA,IAAU,OAAS,GAAK,OACrC,GAAIA,IAAU,OAASsC,EAAgB,OAAQF,EAAK,SAAS,EAAI,CAAC,EAClE,oBAAqB3B,EACrB,YAAalC,IAAU,OAAY,OAAYA,IAAU,SAAW,YAAcA,IAAU,OAAS,OAAS,WAE9G,YAAakC,IAAiB,WAAaE,EAAQ,GAAK,OACxD,YAAayB,EAAK,QAAU,GAAK,MACnC,CACF,CAGO,SAASG,GAAqB9B,EAAgE+B,EAA6B,CAChI,IAAMC,EAAM9C,EAAac,CAAY,EAC/BF,EAAc,UAClB,IAAMR,EAA2BU,EAAc,IAAM+B,CAAQ,EAG7D,CAACC,EAAKD,CAAQ,CAChB,EAIME,EAAmB,UAAQ,IAAOxC,EAAWK,CAAK,IAAM,OAAY+B,EAAgB,eAAgB/B,CAAK,EAAK,CAAC,EAA+B,CAACA,CAAK,CAAC,EAC3J,MAAO,CAAE,MAAAA,EAAO,WAAAmC,CAAW,CAC7B",
|
|
6
|
+
"names": ["React", "isMap", "value", "firstStated", "map", "bp", "usePane", "options", "name", "label", "propNames", "presentationTable", "builtIn", "store", "useShellStore", "generatedId", "id", "controlled", "controlledIsMap", "controlledMap", "autoSource", "autoKey", "useStableKey", "inner", "setInner", "autoTable", "tableOf", "state", "needsBreakpoint", "constantOf", "breakpoint", "ready", "useBreakpoint", "now", "table", "constant", "presentation", "overlaying", "shown", "overlayLive", "defaultValue", "latest", "valueNow", "current", "readBreakpoint", "defaultHereNow", "setValue", "next", "reason", "toggle", "from", "elementRef", "setElement", "node", "entry", "notifyShellStore", "callbacks", "previous", "before", "wasControlled", "peeking", "usePeeking", "paneAttributes", "pane", "presentationAttributes", "tableAttributes", "usePresentationTable", "fallback", "key", "attributes"]
|
|
7
|
+
}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{a as
|
|
2
|
-
//# sourceMappingURL=chunk-
|
|
1
|
+
import{a as u}from"./chunk-PYXMGEO7.js";import{a as c}from"./chunk-MJJ7XDIP.js";import{a as C}from"./chunk-5TAHT6VC.js";import{a as d}from"./chunk-XKBLNVOD.js";import{c as P}from"./chunk-SEY4NA45.js";import{a as f}from"./chunk-5TXQLK4G.js";import{a}from"./chunk-UBSLEGQZ.js";import{a as L}from"./chunk-OS3FCYZY.js";var I={};L(I,{Action:()=>h,Cancel:()=>x,Content:()=>v,Description:()=>E,Root:()=>y,Title:()=>T,Trigger:()=>R});import*as e from"react";import O from"classnames";import{AlertDialog as l}from"radix-ui";var y=o=>e.createElement(l.Root,{...o});y.displayName="AlertDialog.Root";var R=e.forwardRef(({children:o,...t},r)=>e.createElement(l.Trigger,{...t,ref:r,asChild:!0},c(o)));R.displayName="AlertDialog.Trigger";var{align:S,panelBackground:K,material:_,...j}=d,q={align:S},z={panelBackground:K},F={material:_},v=e.forwardRef(({align:o,...t},r)=>{let{className:N}=a({align:o},q),{panelBackground:k}=a({panelBackground:t.panelBackground},z),{material:B}=a({material:t.material},F);f(t.panelBackground);let g=B??k,{className:b,forceMount:w,container:M,panelBackground:V,material:$,...W}=a(t,j),m=e.useRef(null),H=e.useMemo(()=>i=>{m.current=i,typeof r=="function"?r(i):r&&(r.current=i)},[r]);return e.useEffect(()=>{if(typeof window>"u")return;let i=m.current;if(!i)return;let n=i.querySelectorAll('button, [href], input, select, textarea, [tabindex]:not([tabindex="-1"])');if(n.length===0)return;let p=n[0],D=n[n.length-1],A=s=>{s.key==="Tab"&&(s.shiftKey?document.activeElement===p&&(s.preventDefault(),D.focus()):document.activeElement===D&&(s.preventDefault(),p.focus()))};return i.addEventListener("keydown",A),p.focus(),()=>{i.removeEventListener("keydown",A)}},[]),e.createElement(l.Portal,{container:M,forceMount:w},e.createElement(P,{asChild:!0},e.createElement(l.Overlay,{className:"rt-BaseDialogOverlay rt-AlertDialogOverlay"},e.createElement("div",{className:"rt-BaseDialogScroll rt-AlertDialogScroll"},e.createElement("div",{className:`rt-BaseDialogScrollPadding rt-AlertDialogScrollPadding ${N}`},e.createElement(l.Content,{...W,ref:H,className:O("rt-BaseDialogContent","rt-AlertDialogContent",b),"data-material":g,"data-panel-background":g,tabIndex:-1,role:"alertdialog","aria-modal":"true","aria-describedby":"alert-dialog-description",onCloseAutoFocus:i=>{i.preventDefault(),document.body.style.pointerEvents=""}}),e.createElement("div",{"aria-live":"assertive","aria-atomic":"true",className:"rt-sr-only",id:"alert-dialog-announcement"}))))))});v.displayName="AlertDialog.Content";var T=e.forwardRef((o,t)=>e.createElement(l.Title,{asChild:!0},e.createElement(u,{size:"5",mb:"3",trim:"start",...o,asChild:!1,ref:t})));T.displayName="AlertDialog.Title";var E=e.forwardRef((o,t)=>e.createElement(l.Description,{asChild:!0},e.createElement(C,{as:"p",size:"3",...o,asChild:!1,ref:t})));E.displayName="AlertDialog.Description";var h=e.forwardRef(({children:o,...t},r)=>e.createElement(l.Action,{...t,ref:r,asChild:!0},c(o)));h.displayName="AlertDialog.Action";var x=e.forwardRef(({children:o,...t},r)=>e.createElement(l.Cancel,{...t,ref:r,asChild:!0},c(o)));x.displayName="AlertDialog.Cancel";export{y as a,R as b,v as c,T as d,E as e,h as f,x as g,I as h};
|
|
2
|
+
//# sourceMappingURL=chunk-H4GR4262.js.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{a as V}from"./chunk-CTA5ODAO.js";import{b as oe,c as ne,d as K,e as re,f as te}from"./chunk-IX5HIHVI.js";import{c as W}from"./chunk-VBI3AWPT.js";import{a as ee}from"./chunk-MJJ7XDIP.js";import{b as L,c as z}from"./chunk-SEY4NA45.js";import{a as x}from"./chunk-5TXQLK4G.js";import{b as y,c as E,d as H,e as U,f as Y}from"./chunk-3KSGRY6I.js";import{b as N,c as B,d as q,e as k,f as O}from"./chunk-NVDXXGVW.js";import{a as T}from"./chunk-6FLLFCBU.js";import{a as P,b,c as X,d as $,e as G,f as J,g as Q,h as Z,i as _}from"./chunk-JSW6J6RS.js";import{a as Te}from"./chunk-OS3FCYZY.js";var Ge={};Te(Ge,{CheckboxItem:()=>Me,Content:()=>de,Group:()=>me,Item:()=>ce,Label:()=>le,RadioGroup:()=>we,RadioItem:()=>De,Root:()=>pe,Separator:()=>Re,Sub:()=>fe,SubContent:()=>ge,SubTrigger:()=>Pe,Trigger:()=>ue,TriggerIcon:()=>ve});import*as e from"react";import d from"classnames";import{DropdownMenu as u,Slot as xe}from"radix-ui";import{useCallbackRef as ae}from"radix-ui/internal";var ie=e.createContext(!1),pe=o=>{let{open:n,defaultOpen:r=!1,onOpenChange:p}=o,[a,t]=e.useState(r),i=n??a,s=ae(p),l=e.useCallback(m=>{t(m),s(m)},[s]);return e.createElement(ie.Provider,{value:i},e.createElement(u.Root,{...o,onOpenChange:l}))};pe.displayName="DropdownMenu.Root";var ue=e.forwardRef(({children:o,...n},r)=>e.createElement(u.Trigger,{...n,ref:r,asChild:!0},ee(o)));ue.displayName="DropdownMenu.Trigger";var A=e.createContext({}),Ee={ltr:"ArrowLeft",rtl:"ArrowRight"},Ne={ltr:"ArrowRight",rtl:"ArrowLeft"};function Be(o){return o instanceof HTMLElement&&(o.isContentEditable||o.tagName==="INPUT"||o.tagName==="TEXTAREA")}function se(o){return o?.closest("[dir]")?.getAttribute("dir")==="rtl"?"rtl":"ltr"}var de=e.forwardRef((o,n)=>{let r=L();x(o.panelBackground);let p=B(o.material,o.panelBackground,r),{size:a=y.size.default,variant:t=y.variant.default}=o,{className:i,children:s,color:l,container:m,forceMount:w,material:c,panelBackground:S,submenuBehavior:v,virtualized:I=!1,onEscapeKeyDown:R,onKeyDown:h,...g}=T(o,y),D=l||r.accentColor,f=N(v,"cascade"),F=f==="drill-down",Ie=e.useContext(ie),C=X(),he=M=>{R?.(M),!(M.defaultPrevented||!F||C.getDepth()===0)&&(M.preventDefault(),C.pop("keyboard"))},ye=M=>{h?.(M),!(M.defaultPrevented||!F||C.getDepth()===0)&&(Be(M.target)||M.key===Ee[se(M.currentTarget)]&&(M.preventDefault(),C.pop("keyboard")))},Se=e.useMemo(()=>({size:a,variant:t,color:D,material:p}),[a,t,D,p]),j=e.createElement(W,{size:a},e.createElement(A.Provider,{value:Se},e.createElement($,{store:C,behavior:f,open:Ie},s)));return e.createElement(u.Portal,{container:m,forceMount:w},e.createElement(z,{asChild:!0},e.createElement(u.Content,{"data-accent-color":D,"data-material":p,"data-panel-background":p,align:"start",sideOffset:4,collisionPadding:10,...g,onEscapeKeyDown:he,onKeyDown:ye,asChild:!1,ref:n,className:d("rt-PopperContent","rt-BaseMenuContent","rt-DropdownMenuContent",i)},I?e.createElement("div",{className:d("rt-BaseMenuViewport","rt-DropdownMenuViewport","rt-virtualized")},j):e.createElement(V,{type:"auto",scrollbars:"vertical"},e.createElement("div",{className:d("rt-BaseMenuViewport","rt-DropdownMenuViewport")},j)))))});de.displayName="DropdownMenu.Content";var le=e.forwardRef(({className:o,...n},r)=>e.useContext(P)?e.createElement(u.Label,{...n,asChild:!1,ref:r,className:d("rt-BaseMenuLabel","rt-DropdownMenuLabel",o)}):null);le.displayName="DropdownMenu.Label";var ce=e.forwardRef((o,n)=>{let{className:r,children:p,color:a=H.color.default,shortcut:t,...i}=o;return e.useContext(P)?e.createElement(u.Item,{"data-accent-color":a,"aria-keyshortcuts":t?k(t):void 0,...i,ref:n,className:d("rt-reset","rt-BaseMenuItem","rt-DropdownMenuItem",r)},e.createElement(xe.Slottable,null,p),t&&e.createElement(O,{shortcut:t,className:"rt-DropdownMenuShortcut"})):null});ce.displayName="DropdownMenu.Item";var me=e.forwardRef(({className:o,...n},r)=>e.createElement(u.Group,{...n,asChild:!1,ref:r,className:d("rt-BaseMenuGroup","rt-DropdownMenuGroup",o)}));me.displayName="DropdownMenu.Group";var we=e.forwardRef(({className:o,...n},r)=>e.createElement(u.RadioGroup,{...n,asChild:!1,ref:r,className:d("rt-BaseMenuRadioGroup","rt-DropdownMenuRadioGroup",o)}));we.displayName="DropdownMenu.RadioGroup";var De=e.forwardRef((o,n)=>{let{children:r,className:p,color:a=Y.color.default,...t}=o;return e.useContext(P)?e.createElement(u.RadioItem,{...t,asChild:!1,ref:n,"data-accent-color":a,className:d("rt-BaseMenuItem","rt-BaseMenuRadioItem","rt-DropdownMenuItem","rt-DropdownMenuRadioItem",p)},r,e.createElement(u.ItemIndicator,{className:"rt-BaseMenuItemIndicator rt-DropdownMenuItemIndicator"},e.createElement(te,{className:"rt-BaseMenuItemIndicatorIcon rt-DropdownMenuItemIndicatorIcon"}))):null});De.displayName="DropdownMenu.RadioItem";var Me=e.forwardRef((o,n)=>{let{children:r,className:p,shortcut:a,color:t=U.color.default,...i}=o;return e.useContext(P)?e.createElement(u.CheckboxItem,{"aria-keyshortcuts":a?k(a):void 0,...i,asChild:!1,ref:n,"data-accent-color":t,className:d("rt-BaseMenuItem","rt-BaseMenuCheckboxItem","rt-DropdownMenuItem","rt-DropdownMenuCheckboxItem",p)},r,e.createElement(u.ItemIndicator,{className:"rt-BaseMenuItemIndicator rt-DropdownMenuItemIndicator"},e.createElement(oe,{className:"rt-BaseMenuItemIndicatorIcon rt-DropdownMenuItemIndicatorIcon"})),a&&e.createElement(O,{shortcut:a,className:"rt-DropdownMenuShortcut"})):null});Me.displayName="DropdownMenu.CheckboxItem";var fe=({label:o="Back",open:n,defaultOpen:r,onOpenChange:p,children:a})=>{let t=b(),i=e.useId(),s=e.useMemo(()=>({id:i,label:o}),[i,o]),l=G(t,i)!=="closed";e.useLayoutEffect(()=>{!t||n===void 0||(n&&!t.isOpen(i)?t.push(i,null):!n&&t.isOpen(i)&&t.close(i))},[t,n,i]);let m=e.useRef(r);e.useLayoutEffect(()=>{t&&m.current&&n===void 0&&t.push(i,null)},[]);let w=ae(p),c=e.useRef(l);return e.useEffect(()=>{!t||c.current===l||(c.current=l,w(l))},[t,l,w]),e.createElement(Z.Provider,{value:s},e.createElement(u.Sub,{open:n,defaultOpen:r,onOpenChange:t?void 0:p},a))};fe.displayName="DropdownMenu.Sub";var Pe=e.forwardRef((o,n)=>{let{className:r,children:p,onKeyDown:a,...t}=o,i=b(),s=_(),l=e.useContext(P);if(i&&s){if(!l)return null;let m=c=>{c.preventDefault(),i.push(s.id)},w=c=>{a?.(c),!(c.defaultPrevented||t.disabled)&&c.key===Ne[se(c.currentTarget)]&&(c.preventDefault(),i.push(s.id,"keyboard"))};return e.createElement(u.Item,{"aria-haspopup":"menu",...t,"data-drill-down-trigger":s.id,"data-drill-down-name":t.textValue,onSelect:m,onKeyDown:w,ref:n,className:d("rt-reset","rt-BaseMenuItem","rt-BaseMenuSubTrigger","rt-DropdownMenuItem","rt-DropdownMenuSubTrigger","rt-DropdownMenuDrillDownSubTrigger",r)},p,e.createElement("div",{className:"rt-BaseMenuShortcut rt-DropdownMenuShortcut"},e.createElement(K,{className:"rt-BaseMenuSubTriggerIcon rt-DropdownMenuSubTriggerIcon"})))}return e.createElement(u.SubTrigger,{...t,onKeyDown:a,asChild:!1,ref:n,className:d("rt-BaseMenuItem","rt-BaseMenuSubTrigger","rt-DropdownMenuItem","rt-DropdownMenuSubTrigger",r)},p,e.createElement("div",{className:"rt-BaseMenuShortcut rt-DropdownMenuShortcut"},e.createElement(K,{className:"rt-BaseMenuSubTriggerIcon rt-DropdownMenuSubTriggerIcon"})))});Pe.displayName="DropdownMenu.SubTrigger";var Re=e.forwardRef(({className:o,...n},r)=>e.useContext(P)?e.createElement(u.Separator,{...n,asChild:!1,ref:r,className:d("rt-BaseMenuSeparator","rt-DropdownMenuSeparator",o)}):null);Re.displayName="DropdownMenu.Separator";function ke({label:o,name:n}){let r=b(),p=e.useCallback(i=>{i.preventDefault(),r?.pop()},[r]),a=typeof o=="string"?o:n,t=a&&a!=="Back"?`Back from ${a}`:void 0;return e.createElement(u.Item,{"aria-label":t,textValue:a||"Back",onSelect:p,className:d("rt-reset","rt-BaseMenuItem","rt-DropdownMenuItem","rt-DropdownMenuDrillDownBackItem")},e.createElement(re,{className:"rt-BaseMenuSubTriggerIcon rt-DropdownMenuDrillDownBackIcon"}),e.createElement("span",{className:"rt-DropdownMenuDrillDownBackLabel"},o))}function Oe(o){let{loop:n,onEscapeKeyDown:r,onPointerDownOutside:p,onFocusOutside:a,onInteractOutside:t,sideOffset:i,alignOffset:s,avoidCollisions:l,collisionBoundary:m,collisionPadding:w,arrowPadding:c,sticky:S,hideWhenDetached:v,updatePositionStrategy:I,...R}=o;return R}var ge=e.forwardRef((o,n)=>{let r=b(),p=_();return r&&p?e.createElement(be,{...o,ref:n,store:r,sub:p}):e.createElement(Ce,{...o,ref:n})});ge.displayName="DropdownMenu.SubContent";var Ce=e.forwardRef((o,n)=>{let r=e.useContext(A),p=L();x(o.panelBackground);let a=o.size??r.size,t=o.variant??r.variant,i=o.color??r.color,s=o.material??o.panelBackground??r.material??B(void 0,void 0,p),{className:l,children:m,container:w,forceMount:c,color:S,material:v,panelBackground:I,virtualized:R=!1,...h}=T({...o,size:a,variant:t},E),g=N(a,E.size.default),D=e.useMemo(()=>({size:a,variant:t,color:i,material:s}),[a,t,i,s]),f=e.createElement(W,{size:a},e.createElement(A.Provider,{value:D},m));return e.createElement(u.Portal,{container:w,forceMount:c},e.createElement(z,{asChild:!0},e.createElement(u.SubContent,{"data-accent-color":i,"data-material":s,"data-panel-background":s,alignOffset:q(g,p.scaling),sideOffset:1,collisionPadding:10,...h,asChild:!1,ref:n,className:d("rt-PopperContent","rt-BaseMenuContent","rt-BaseMenuSubContent","rt-DropdownMenuContent","rt-DropdownMenuSubContent",l)},R?e.createElement("div",{className:d("rt-BaseMenuViewport","rt-DropdownMenuViewport","rt-virtualized")},f):e.createElement(V,{type:"auto",scrollbars:"vertical"},e.createElement("div",{className:d("rt-BaseMenuViewport","rt-DropdownMenuViewport")},f)))))});Ce.displayName="DropdownMenu.CascadeSubContent";var be=e.forwardRef(({store:o,sub:n,...r},p)=>{let a=G(o,n.id),t=J(o,n.id),i=Q(a==="top"?o:null);if(a==="closed")return null;let{className:s,children:l,container:m,forceMount:w,virtualized:c,size:S,variant:v,color:I,material:R,panelBackground:h,...g}=Oe(r),D=a==="top",f=t?.name||(typeof n.label=="string"?n.label:"");return e.createElement("div",{role:"group","aria-label":f||void 0,...g,ref:p,"data-drill-down-panel":n.id,"data-drill-down-active":D?!0:void 0,"data-animation-direction":D?i??void 0:void 0,className:d("rt-DropdownMenuDrillDownPanel",s)},D&&e.createElement(e.Fragment,null,e.createElement(ke,{label:n.label,name:f}),e.createElement(u.Separator,{className:"rt-BaseMenuSeparator rt-DropdownMenuSeparator"})),e.createElement(P.Provider,{value:D},l))});be.displayName="DropdownMenu.DrillDownPanel";var ve=e.forwardRef(({className:o,...n},r)=>e.createElement(ne,{...n,ref:r,className:d("rt-DropdownMenuTriggerIcon",o)}));ve.displayName="DropdownMenu.TriggerIcon";export{pe as a,ue as b,de as c,le as d,ce as e,me as f,we as g,De as h,Me as i,fe as j,Pe as k,Re as l,ge as m,ve as n,Ge as o};
|
|
2
|
-
//# sourceMappingURL=chunk-
|
|
1
|
+
import{a as V}from"./chunk-4WU2WKUJ.js";import{b as oe,c as ne,d as K,e as re,f as te}from"./chunk-IX5HIHVI.js";import{a as ee}from"./chunk-MJJ7XDIP.js";import{c as W}from"./chunk-UNWPH3SO.js";import{b as L,c as z}from"./chunk-SEY4NA45.js";import{a as x}from"./chunk-5TXQLK4G.js";import{b as y,c as E,d as H,e as U,f as Y}from"./chunk-3KSGRY6I.js";import{b as N,c as B,d as q,e as k,f as O}from"./chunk-7PMMYHZV.js";import{a as T}from"./chunk-UBSLEGQZ.js";import{a as P,b,c as X,d as $,e as G,f as J,g as Q,h as Z,i as _}from"./chunk-JSW6J6RS.js";import{a as Te}from"./chunk-OS3FCYZY.js";var Ge={};Te(Ge,{CheckboxItem:()=>Me,Content:()=>de,Group:()=>me,Item:()=>ce,Label:()=>le,RadioGroup:()=>we,RadioItem:()=>De,Root:()=>pe,Separator:()=>Re,Sub:()=>fe,SubContent:()=>ge,SubTrigger:()=>Pe,Trigger:()=>ue,TriggerIcon:()=>ve});import*as e from"react";import d from"classnames";import{DropdownMenu as u,Slot as xe}from"radix-ui";import{useCallbackRef as ae}from"radix-ui/internal";var ie=e.createContext(!1),pe=o=>{let{open:n,defaultOpen:r=!1,onOpenChange:p}=o,[a,t]=e.useState(r),i=n??a,s=ae(p),l=e.useCallback(m=>{t(m),s(m)},[s]);return e.createElement(ie.Provider,{value:i},e.createElement(u.Root,{...o,onOpenChange:l}))};pe.displayName="DropdownMenu.Root";var ue=e.forwardRef(({children:o,...n},r)=>e.createElement(u.Trigger,{...n,ref:r,asChild:!0},ee(o)));ue.displayName="DropdownMenu.Trigger";var A=e.createContext({}),Ee={ltr:"ArrowLeft",rtl:"ArrowRight"},Ne={ltr:"ArrowRight",rtl:"ArrowLeft"};function Be(o){return o instanceof HTMLElement&&(o.isContentEditable||o.tagName==="INPUT"||o.tagName==="TEXTAREA")}function se(o){return o?.closest("[dir]")?.getAttribute("dir")==="rtl"?"rtl":"ltr"}var de=e.forwardRef((o,n)=>{let r=L();x(o.panelBackground);let p=B(o.material,o.panelBackground,r),{size:a=y.size.default,variant:t=y.variant.default}=o,{className:i,children:s,color:l,container:m,forceMount:w,material:c,panelBackground:S,submenuBehavior:v,virtualized:I=!1,onEscapeKeyDown:R,onKeyDown:h,...g}=T(o,y),D=l||r.accentColor,f=N(v,"cascade"),F=f==="drill-down",Ie=e.useContext(ie),C=X(),he=M=>{R?.(M),!(M.defaultPrevented||!F||C.getDepth()===0)&&(M.preventDefault(),C.pop("keyboard"))},ye=M=>{h?.(M),!(M.defaultPrevented||!F||C.getDepth()===0)&&(Be(M.target)||M.key===Ee[se(M.currentTarget)]&&(M.preventDefault(),C.pop("keyboard")))},Se=e.useMemo(()=>({size:a,variant:t,color:D,material:p}),[a,t,D,p]),j=e.createElement(W,{size:a},e.createElement(A.Provider,{value:Se},e.createElement($,{store:C,behavior:f,open:Ie},s)));return e.createElement(u.Portal,{container:m,forceMount:w},e.createElement(z,{asChild:!0},e.createElement(u.Content,{"data-accent-color":D,"data-material":p,"data-panel-background":p,align:"start",sideOffset:4,collisionPadding:10,...g,onEscapeKeyDown:he,onKeyDown:ye,asChild:!1,ref:n,className:d("rt-PopperContent","rt-BaseMenuContent","rt-DropdownMenuContent",i)},I?e.createElement("div",{className:d("rt-BaseMenuViewport","rt-DropdownMenuViewport","rt-virtualized")},j):e.createElement(V,{type:"auto",scrollbars:"vertical"},e.createElement("div",{className:d("rt-BaseMenuViewport","rt-DropdownMenuViewport")},j)))))});de.displayName="DropdownMenu.Content";var le=e.forwardRef(({className:o,...n},r)=>e.useContext(P)?e.createElement(u.Label,{...n,asChild:!1,ref:r,className:d("rt-BaseMenuLabel","rt-DropdownMenuLabel",o)}):null);le.displayName="DropdownMenu.Label";var ce=e.forwardRef((o,n)=>{let{className:r,children:p,color:a=H.color.default,shortcut:t,...i}=o;return e.useContext(P)?e.createElement(u.Item,{"data-accent-color":a,"aria-keyshortcuts":t?k(t):void 0,...i,ref:n,className:d("rt-reset","rt-BaseMenuItem","rt-DropdownMenuItem",r)},e.createElement(xe.Slottable,null,p),t&&e.createElement(O,{shortcut:t,className:"rt-DropdownMenuShortcut"})):null});ce.displayName="DropdownMenu.Item";var me=e.forwardRef(({className:o,...n},r)=>e.createElement(u.Group,{...n,asChild:!1,ref:r,className:d("rt-BaseMenuGroup","rt-DropdownMenuGroup",o)}));me.displayName="DropdownMenu.Group";var we=e.forwardRef(({className:o,...n},r)=>e.createElement(u.RadioGroup,{...n,asChild:!1,ref:r,className:d("rt-BaseMenuRadioGroup","rt-DropdownMenuRadioGroup",o)}));we.displayName="DropdownMenu.RadioGroup";var De=e.forwardRef((o,n)=>{let{children:r,className:p,color:a=Y.color.default,...t}=o;return e.useContext(P)?e.createElement(u.RadioItem,{...t,asChild:!1,ref:n,"data-accent-color":a,className:d("rt-BaseMenuItem","rt-BaseMenuRadioItem","rt-DropdownMenuItem","rt-DropdownMenuRadioItem",p)},r,e.createElement(u.ItemIndicator,{className:"rt-BaseMenuItemIndicator rt-DropdownMenuItemIndicator"},e.createElement(te,{className:"rt-BaseMenuItemIndicatorIcon rt-DropdownMenuItemIndicatorIcon"}))):null});De.displayName="DropdownMenu.RadioItem";var Me=e.forwardRef((o,n)=>{let{children:r,className:p,shortcut:a,color:t=U.color.default,...i}=o;return e.useContext(P)?e.createElement(u.CheckboxItem,{"aria-keyshortcuts":a?k(a):void 0,...i,asChild:!1,ref:n,"data-accent-color":t,className:d("rt-BaseMenuItem","rt-BaseMenuCheckboxItem","rt-DropdownMenuItem","rt-DropdownMenuCheckboxItem",p)},r,e.createElement(u.ItemIndicator,{className:"rt-BaseMenuItemIndicator rt-DropdownMenuItemIndicator"},e.createElement(oe,{className:"rt-BaseMenuItemIndicatorIcon rt-DropdownMenuItemIndicatorIcon"})),a&&e.createElement(O,{shortcut:a,className:"rt-DropdownMenuShortcut"})):null});Me.displayName="DropdownMenu.CheckboxItem";var fe=({label:o="Back",open:n,defaultOpen:r,onOpenChange:p,children:a})=>{let t=b(),i=e.useId(),s=e.useMemo(()=>({id:i,label:o}),[i,o]),l=G(t,i)!=="closed";e.useLayoutEffect(()=>{!t||n===void 0||(n&&!t.isOpen(i)?t.push(i,null):!n&&t.isOpen(i)&&t.close(i))},[t,n,i]);let m=e.useRef(r);e.useLayoutEffect(()=>{t&&m.current&&n===void 0&&t.push(i,null)},[]);let w=ae(p),c=e.useRef(l);return e.useEffect(()=>{!t||c.current===l||(c.current=l,w(l))},[t,l,w]),e.createElement(Z.Provider,{value:s},e.createElement(u.Sub,{open:n,defaultOpen:r,onOpenChange:t?void 0:p},a))};fe.displayName="DropdownMenu.Sub";var Pe=e.forwardRef((o,n)=>{let{className:r,children:p,onKeyDown:a,...t}=o,i=b(),s=_(),l=e.useContext(P);if(i&&s){if(!l)return null;let m=c=>{c.preventDefault(),i.push(s.id)},w=c=>{a?.(c),!(c.defaultPrevented||t.disabled)&&c.key===Ne[se(c.currentTarget)]&&(c.preventDefault(),i.push(s.id,"keyboard"))};return e.createElement(u.Item,{"aria-haspopup":"menu",...t,"data-drill-down-trigger":s.id,"data-drill-down-name":t.textValue,onSelect:m,onKeyDown:w,ref:n,className:d("rt-reset","rt-BaseMenuItem","rt-BaseMenuSubTrigger","rt-DropdownMenuItem","rt-DropdownMenuSubTrigger","rt-DropdownMenuDrillDownSubTrigger",r)},p,e.createElement("div",{className:"rt-BaseMenuShortcut rt-DropdownMenuShortcut"},e.createElement(K,{className:"rt-BaseMenuSubTriggerIcon rt-DropdownMenuSubTriggerIcon"})))}return e.createElement(u.SubTrigger,{...t,onKeyDown:a,asChild:!1,ref:n,className:d("rt-BaseMenuItem","rt-BaseMenuSubTrigger","rt-DropdownMenuItem","rt-DropdownMenuSubTrigger",r)},p,e.createElement("div",{className:"rt-BaseMenuShortcut rt-DropdownMenuShortcut"},e.createElement(K,{className:"rt-BaseMenuSubTriggerIcon rt-DropdownMenuSubTriggerIcon"})))});Pe.displayName="DropdownMenu.SubTrigger";var Re=e.forwardRef(({className:o,...n},r)=>e.useContext(P)?e.createElement(u.Separator,{...n,asChild:!1,ref:r,className:d("rt-BaseMenuSeparator","rt-DropdownMenuSeparator",o)}):null);Re.displayName="DropdownMenu.Separator";function ke({label:o,name:n}){let r=b(),p=e.useCallback(i=>{i.preventDefault(),r?.pop()},[r]),a=typeof o=="string"?o:n,t=a&&a!=="Back"?`Back from ${a}`:void 0;return e.createElement(u.Item,{"aria-label":t,textValue:a||"Back",onSelect:p,className:d("rt-reset","rt-BaseMenuItem","rt-DropdownMenuItem","rt-DropdownMenuDrillDownBackItem")},e.createElement(re,{className:"rt-BaseMenuSubTriggerIcon rt-DropdownMenuDrillDownBackIcon"}),e.createElement("span",{className:"rt-DropdownMenuDrillDownBackLabel"},o))}function Oe(o){let{loop:n,onEscapeKeyDown:r,onPointerDownOutside:p,onFocusOutside:a,onInteractOutside:t,sideOffset:i,alignOffset:s,avoidCollisions:l,collisionBoundary:m,collisionPadding:w,arrowPadding:c,sticky:S,hideWhenDetached:v,updatePositionStrategy:I,...R}=o;return R}var ge=e.forwardRef((o,n)=>{let r=b(),p=_();return r&&p?e.createElement(be,{...o,ref:n,store:r,sub:p}):e.createElement(Ce,{...o,ref:n})});ge.displayName="DropdownMenu.SubContent";var Ce=e.forwardRef((o,n)=>{let r=e.useContext(A),p=L();x(o.panelBackground);let a=o.size??r.size,t=o.variant??r.variant,i=o.color??r.color,s=o.material??o.panelBackground??r.material??B(void 0,void 0,p),{className:l,children:m,container:w,forceMount:c,color:S,material:v,panelBackground:I,virtualized:R=!1,...h}=T({...o,size:a,variant:t},E),g=N(a,E.size.default),D=e.useMemo(()=>({size:a,variant:t,color:i,material:s}),[a,t,i,s]),f=e.createElement(W,{size:a},e.createElement(A.Provider,{value:D},m));return e.createElement(u.Portal,{container:w,forceMount:c},e.createElement(z,{asChild:!0},e.createElement(u.SubContent,{"data-accent-color":i,"data-material":s,"data-panel-background":s,alignOffset:q(g,p.scaling),sideOffset:1,collisionPadding:10,...h,asChild:!1,ref:n,className:d("rt-PopperContent","rt-BaseMenuContent","rt-BaseMenuSubContent","rt-DropdownMenuContent","rt-DropdownMenuSubContent",l)},R?e.createElement("div",{className:d("rt-BaseMenuViewport","rt-DropdownMenuViewport","rt-virtualized")},f):e.createElement(V,{type:"auto",scrollbars:"vertical"},e.createElement("div",{className:d("rt-BaseMenuViewport","rt-DropdownMenuViewport")},f)))))});Ce.displayName="DropdownMenu.CascadeSubContent";var be=e.forwardRef(({store:o,sub:n,...r},p)=>{let a=G(o,n.id),t=J(o,n.id),i=Q(a==="top"?o:null);if(a==="closed")return null;let{className:s,children:l,container:m,forceMount:w,virtualized:c,size:S,variant:v,color:I,material:R,panelBackground:h,...g}=Oe(r),D=a==="top",f=t?.name||(typeof n.label=="string"?n.label:"");return e.createElement("div",{role:"group","aria-label":f||void 0,...g,ref:p,"data-drill-down-panel":n.id,"data-drill-down-active":D?!0:void 0,"data-animation-direction":D?i??void 0:void 0,className:d("rt-DropdownMenuDrillDownPanel",s)},D&&e.createElement(e.Fragment,null,e.createElement(ke,{label:n.label,name:f}),e.createElement(u.Separator,{className:"rt-BaseMenuSeparator rt-DropdownMenuSeparator"})),e.createElement(P.Provider,{value:D},l))});be.displayName="DropdownMenu.DrillDownPanel";var ve=e.forwardRef(({className:o,...n},r)=>e.createElement(ne,{...n,ref:r,className:d("rt-DropdownMenuTriggerIcon",o)}));ve.displayName="DropdownMenu.TriggerIcon";export{pe as a,ue as b,de as c,le as d,ce as e,me as f,we as g,De as h,Me as i,fe as j,Pe as k,Re as l,ge as m,ve as n,Ge as o};
|
|
2
|
+
//# sourceMappingURL=chunk-HBIF43PT.js.map
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
import{b as Z}from"./chunk-HWQ3NTJP.js";import*as t from"react";import de from"classnames";var x=t.forwardRef(({className:d,children:m,...R},g)=>{let{containerRef:E,controls:_,cssVarName:A,minSize:L,maxSize:b,defaultSize:D,orientation:v,edge:ee,growth:z,onResize:y,onResizeStart:W,onResizeEnd:k,snapPoints:T,snapTolerance:te,collapseThreshold:U,collapsible:q,target:V,requestCollapse:ne,requestToggle:re}=Z(),S=t.useRef(null),oe=t.useCallback(e=>{S.current=e,typeof g=="function"?g(e):g&&(g.current=e)},[g]),C=t.useRef(null);t.useEffect(()=>()=>{C.current?.(),C.current=null},[]);let F=t.useCallback(()=>{let e=E.current;if(!e)return D;let n=Number.parseFloat(getComputedStyle(e).getPropertyValue(A));return Number.isFinite(n)?n:D},[E,A,D]),B=t.useCallback(()=>{let e=E.current,n=S.current,r=e?.closest(".rt-ShellRoot")?.getBoundingClientRect();if(!e||!r||!n)return b;let c=e.getBoundingClientRect(),p=n.getBoundingClientRect(),s=z(getComputedStyle(e).direction==="rtl"),o;v==="vertical"?o=s>0?r.right-c.left:c.right-r.left:o=s>0?r.bottom-c.top:c.bottom-r.top;let H=v==="vertical"?p.width:p.height;return!(r.width>0&&r.height>0)||!Number.isFinite(o)?b:Math.max(L,Math.min(b,Math.round(o-H)))},[E,z,b,L,v]),ie=()=>{S.current?.setAttribute("aria-valuemax",String(B()))};t.useLayoutEffect(()=>{S.current?.setAttribute("aria-valuenow",String(Math.round(F())))},[F]);let M=(e,n)=>{e.style.setProperty(A,`${n}px`),S.current?.setAttribute("aria-valuenow",String(Math.round(n)))},ae=V.charAt(0).toUpperCase()+V.slice(1);return t.createElement("div",{ref:oe,className:de("rt-ShellResizer",d),"data-orientation":v,"data-edge":ee,role:"separator",tabIndex:0,"aria-label":`Resize ${ae} pane`,"aria-controls":_,"aria-orientation":v,"aria-valuemin":L,"aria-valuemax":b,...R,onPointerDown:e=>{R.onPointerDown?.(e);let n=E.current;if(!n||e.defaultPrevented||e.button!==0)return;e.preventDefault();let r=e.currentTarget,c=e.pointerId;C.current?.();try{r.setPointerCapture(c)}catch{}let p=getComputedStyle(n),s=Number.parseFloat(p.getPropertyValue(A)),o=Number.isFinite(s)?s:D,H=v==="vertical"?e.clientX:e.clientY,se=z(p.direction==="rtl"),j=B();r.setAttribute("aria-valuemax",String(j));let X=i=>Math.min(Math.max(i,L),j);n.setAttribute("data-resizing",""),r.setAttribute("data-dragging","");let h=document.body,le=h.style.cursor,ce=h.style.userSelect;h.style.cursor=v==="vertical"?"col-resize":"row-resize",h.style.userSelect="none",W?.(o);let f=o,I=o,l=0,P=null,Y=()=>{if(l=0,P===null)return;let i=P;P=null,y?.(i)},$=null,O=!1,ue=(i,w)=>{if(i.type===w)O=!0;else if(O)return!1;return!0},u=i=>{if(!ue(i,"pointermove")||i===$)return;$=i;let w=v==="vertical"?i.clientX:i.clientY;I=o+(w-H)*se,f=X(I),M(n,f),P=f,l||(l=requestAnimationFrame(Y))},N=()=>{l&&cancelAnimationFrame(l),l=0;try{r.releasePointerCapture(c)}catch{}window.removeEventListener("pointermove",u),document.removeEventListener("pointermove",u),window.removeEventListener("mousemove",u),document.removeEventListener("mousemove",u),r.removeEventListener("pointermove",u),window.removeEventListener("pointerup",a),document.removeEventListener("pointerup",a),window.removeEventListener("mouseup",a),document.removeEventListener("mouseup",a),window.removeEventListener("pointercancel",a),document.removeEventListener("pointercancel",a),window.removeEventListener("keydown",G),r.removeEventListener("lostpointercapture",a),n.removeAttribute("data-resizing"),r.removeAttribute("data-dragging"),h.style.cursor=le,h.style.userSelect=ce,C.current=null},K=!1,a=()=>{if(K)return;if(K=!0,l&&cancelAnimationFrame(l),Y(),q&&typeof U=="number"&&I<=U){M(n,o),y?.(o),N(),ne?.(),k?.(o);return}let i=f;if(T&&T.length){let w=T.reduce((J,Q)=>Math.abs(Q-f)<Math.abs(J-f)?Q:J,T[0]);Math.abs(w-f)<=te&&(i=X(w),M(n,i),y?.(i))}k?.(i),N()},G=i=>{i.key==="Escape"&&(l&&cancelAnimationFrame(l),l=0,P=null,M(n,o),y?.(o),K=!0,k?.(o),N())};window.addEventListener("pointermove",u),document.addEventListener("pointermove",u),window.addEventListener("mousemove",u),document.addEventListener("mousemove",u),r.addEventListener("pointermove",u),window.addEventListener("pointerup",a),document.addEventListener("pointerup",a),window.addEventListener("mouseup",a),document.addEventListener("mouseup",a),window.addEventListener("pointercancel",a),document.addEventListener("pointercancel",a),window.addEventListener("keydown",G),r.addEventListener("lostpointercapture",a),C.current=N},onDoubleClick:e=>{R.onDoubleClick?.(e),!e.defaultPrevented&&q&&re?.()},onFocus:e=>{R.onFocus?.(e),ie()},onKeyDown:e=>{R.onKeyDown?.(e);let n=E.current;if(!n||e.defaultPrevented)return;let r=F(),c=B(),p=o=>Math.min(Math.max(o,L),c),s;if(e.key==="Home")s=p(L);else if(e.key==="End")s=p(c);else{let o=v==="vertical"?e.key==="ArrowRight"?1:e.key==="ArrowLeft"?-1:0:e.key==="ArrowDown"?1:e.key==="ArrowUp"?-1:0;if(o===0)return;let H=e.shiftKey?32:8;s=p(r+o*H*z(getComputedStyle(n).direction==="rtl"))}e.preventDefault(),W?.(r),M(n,s),y?.(s),k?.(s)}},m)});x.displayName="Shell.Handle";var me=t.forwardRef((d,m)=>t.createElement(x,{...d,ref:m}));me.displayName="Shell.Panel.Handle";var ve=t.forwardRef((d,m)=>t.createElement(x,{...d,ref:m}));ve.displayName="Shell.Sidebar.Handle";var pe=t.forwardRef((d,m)=>t.createElement(x,{...d,ref:m}));pe.displayName="Shell.Inspector.Handle";var fe=t.forwardRef((d,m)=>t.createElement(x,{...d,ref:m}));fe.displayName="Shell.Bottom.Handle";export{x as a,me as b,ve as c,pe as d,fe as e};
|
|
2
|
+
//# sourceMappingURL=chunk-HCNO7PX6.js.map
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
{
|
|
2
|
+
"version": 3,
|
|
3
|
+
"sources": ["../../src/components/_internal/shell-handles.tsx"],
|
|
4
|
+
"sourcesContent": ["import * as React from 'react';\nimport classNames from 'classnames';\nimport { usePaneResize } from './shell-resize.js';\n\n/**\n * The resize handle: the WAI-ARIA window splitter. `role=\"separator\"` with a\n * value, focusable because it is operable, `aria-controls` naming its pane.\n *\n * A drag writes the size variable directly on the pane and sets no React\n * state, so nothing re-renders per move. `onResize` is called at most once per\n * animation frame, and once more with the final size when the drag ends. The\n * direction and the ceiling are read once, when the drag starts.\n */\nexport const PaneHandle = React.forwardRef<HTMLDivElement, React.ComponentPropsWithoutRef<'div'>>(({ className, children, ...props }, ref) => {\n const {\n containerRef,\n controls,\n cssVarName,\n minSize,\n maxSize,\n defaultSize,\n orientation,\n edge,\n growth,\n onResize,\n onResizeStart,\n onResizeEnd,\n snapPoints,\n snapTolerance,\n collapseThreshold,\n collapsible,\n target,\n requestCollapse,\n requestToggle,\n } = usePaneResize();\n\n const handleRef = React.useRef<HTMLDivElement | null>(null);\n const setRef = React.useCallback(\n (node: HTMLDivElement | null) => {\n handleRef.current = node;\n if (typeof ref === 'function') ref(node);\n else if (ref) (ref as React.MutableRefObject<HTMLDivElement | null>).current = node;\n },\n [ref],\n );\n\n const activeCleanupRef = React.useRef<(() => void) | null>(null);\n React.useEffect(\n () => () => {\n activeCleanupRef.current?.();\n activeCleanupRef.current = null;\n },\n [],\n );\n\n /** The pane's size as the stylesheet sees it. Read at the edges of a gesture, never during one. */\n const readSize = React.useCallback(() => {\n const container = containerRef.current;\n if (!container) return defaultSize;\n const parsed = Number.parseFloat(getComputedStyle(container).getPropertyValue(cssVarName));\n return Number.isFinite(parsed) ? parsed : defaultSize;\n }, [containerRef, cssVarName, defaultSize]);\n\n /**\n * The largest size a resize may reach: the stated maximum, and never so\n * large that the handle leaves the frame. The room is measured from the\n * pane's anchored edge, which does not move, to the far edge of the frame,\n * so a pane that starts after a Rail has less room than the frame's width.\n * Without the cap a pane with a generous `maxSize` could be resized until\n * its own handle was off screen.\n */\n const ceiling = React.useCallback(() => {\n const container = containerRef.current;\n const handle = handleRef.current;\n const frame = container?.closest('.rt-ShellRoot')?.getBoundingClientRect();\n if (!container || !frame || !handle) return maxSize;\n const pane = container.getBoundingClientRect();\n const hitBox = handle.getBoundingClientRect();\n const sign = growth(getComputedStyle(container).direction === 'rtl');\n let room: number;\n if (orientation === 'vertical') room = sign > 0 ? frame.right - pane.left : pane.right - frame.left;\n else room = sign > 0 ? frame.bottom - pane.top : pane.bottom - frame.top;\n const hit = orientation === 'vertical' ? hitBox.width : hitBox.height;\n if (!(frame.width > 0 && frame.height > 0) || !Number.isFinite(room)) return maxSize;\n return Math.max(minSize, Math.min(maxSize, Math.round(room - hit)));\n }, [containerRef, growth, maxSize, minSize, orientation]);\n\n // The announced maximum is what a resize can reach now, not only the prop.\n const announceCeiling = () => {\n handleRef.current?.setAttribute('aria-valuemax', String(ceiling()));\n };\n\n // The announced value is seeded from the real size once the pane has a box.\n React.useLayoutEffect(() => {\n handleRef.current?.setAttribute('aria-valuenow', String(Math.round(readSize())));\n }, [readSize]);\n\n const write = (container: HTMLElement, size: number) => {\n container.style.setProperty(cssVarName, `${size}px`);\n handleRef.current?.setAttribute('aria-valuenow', String(Math.round(size)));\n };\n\n const targetLabel = target.charAt(0).toUpperCase() + target.slice(1);\n\n return (\n // A focusable separator with a value is the WAI-ARIA window splitter, an\n // interactive widget; jsx-a11y classes every separator as static.\n // eslint-disable-next-line jsx-a11y/no-noninteractive-element-interactions\n <div\n ref={setRef}\n className={classNames('rt-ShellResizer', className)}\n data-orientation={orientation}\n data-edge={edge}\n role=\"separator\"\n // eslint-disable-next-line jsx-a11y/no-noninteractive-tabindex\n tabIndex={0}\n aria-label={`Resize ${targetLabel} pane`}\n aria-controls={controls}\n aria-orientation={orientation}\n aria-valuemin={minSize}\n aria-valuemax={maxSize}\n {...props}\n onPointerDown={(e) => {\n props.onPointerDown?.(e);\n const container = containerRef.current;\n if (!container || e.defaultPrevented || e.button !== 0) return;\n e.preventDefault();\n const handleEl = e.currentTarget as HTMLElement;\n const pointerId = e.pointerId;\n activeCleanupRef.current?.();\n try {\n handleEl.setPointerCapture(pointerId);\n } catch {\n // Capture can fail for a pointer that is already gone; the window listeners below still carry the drag.\n }\n\n // Everything a move needs is read here, once.\n const startStyle = getComputedStyle(container);\n const parsedStart = Number.parseFloat(startStyle.getPropertyValue(cssVarName));\n const startSize = Number.isFinite(parsedStart) ? parsedStart : defaultSize;\n const startClient = orientation === 'vertical' ? e.clientX : e.clientY;\n const sign = growth(startStyle.direction === 'rtl');\n const cap = ceiling();\n handleEl.setAttribute('aria-valuemax', String(cap));\n const clamp = (v: number) => Math.min(Math.max(v, minSize), cap);\n\n container.setAttribute('data-resizing', '');\n handleEl.setAttribute('data-dragging', '');\n const body = document.body;\n const prevCursor = body.style.cursor;\n const prevUserSelect = body.style.userSelect;\n body.style.cursor = orientation === 'vertical' ? 'col-resize' : 'row-resize';\n body.style.userSelect = 'none';\n onResizeStart?.(startSize);\n\n let current = startSize;\n // The unclamped size, so `collapseThreshold` is compared before the\n // clamp: a threshold below `minSize` can then still collapse the pane.\n let raw = startSize;\n let frame = 0;\n let pending: number | null = null;\n const flush = () => {\n frame = 0;\n if (pending === null) return;\n const size = pending;\n pending = null;\n onResize?.(size);\n };\n\n // The move handler listens on the handle, the document and the window,\n // so a drag survives environments where pointer events do not reach\n // all three. One movement can therefore arrive several times: once per\n // node it propagates through, and again as the compatibility mouse\n // event. Only the first copy does any work.\n let lastHandledMove: Event | null = null;\n let seenPointerEvent = false;\n const shouldHandle = (ev: Event, pointerType: string) => {\n if (ev.type === pointerType) seenPointerEvent = true;\n else if (seenPointerEvent) return false;\n return true;\n };\n\n const handleMove = (ev: PointerEvent) => {\n if (!shouldHandle(ev, 'pointermove')) return;\n if (ev === lastHandledMove) return;\n lastHandledMove = ev;\n const client = orientation === 'vertical' ? ev.clientX : ev.clientY;\n raw = startSize + (client - startClient) * sign;\n current = clamp(raw);\n write(container, current);\n pending = current;\n if (!frame) frame = requestAnimationFrame(flush);\n };\n\n const cleanup = () => {\n if (frame) cancelAnimationFrame(frame);\n frame = 0;\n try {\n handleEl.releasePointerCapture(pointerId);\n } catch {\n // Already released.\n }\n window.removeEventListener('pointermove', handleMove as EventListener);\n document.removeEventListener('pointermove', handleMove as EventListener);\n window.removeEventListener('mousemove', handleMove as EventListener);\n document.removeEventListener('mousemove', handleMove as EventListener);\n handleEl.removeEventListener('pointermove', handleMove as EventListener);\n window.removeEventListener('pointerup', handleUp as EventListener);\n document.removeEventListener('pointerup', handleUp as EventListener);\n window.removeEventListener('mouseup', handleUp as EventListener);\n document.removeEventListener('mouseup', handleUp as EventListener);\n window.removeEventListener('pointercancel', handleUp as EventListener);\n document.removeEventListener('pointercancel', handleUp as EventListener);\n window.removeEventListener('keydown', handleKey as EventListener);\n handleEl.removeEventListener('lostpointercapture', handleUp as EventListener);\n container.removeAttribute('data-resizing');\n handleEl.removeAttribute('data-dragging');\n body.style.cursor = prevCursor;\n body.style.userSelect = prevUserSelect;\n activeCleanupRef.current = null;\n };\n\n let finished = false;\n const handleUp = () => {\n if (finished) return;\n finished = true;\n // The last move's size is delivered now rather than on the next frame.\n if (frame) cancelAnimationFrame(frame);\n flush();\n\n if (collapsible && typeof collapseThreshold === 'number' && raw <= collapseThreshold) {\n // A drag past the threshold closes the pane and keeps no size: the\n // pane opens again at the size it had before the drag. The drag\n // still ends, at that size, so a consumer that started something\n // in onResizeStart can stop it.\n write(container, startSize);\n onResize?.(startSize);\n cleanup();\n requestCollapse?.();\n onResizeEnd?.(startSize);\n return;\n }\n\n let settled = current;\n if (snapPoints && snapPoints.length) {\n const nearest = snapPoints.reduce((acc, p) => (Math.abs(p - current) < Math.abs(acc - current) ? p : acc), snapPoints[0]);\n if (Math.abs(nearest - current) <= snapTolerance) {\n settled = clamp(nearest);\n write(container, settled);\n onResize?.(settled);\n }\n }\n onResizeEnd?.(settled);\n cleanup();\n };\n\n const handleKey = (kev: KeyboardEvent) => {\n if (kev.key !== 'Escape') return;\n if (frame) cancelAnimationFrame(frame);\n frame = 0;\n pending = null;\n write(container, startSize);\n onResize?.(startSize);\n finished = true;\n onResizeEnd?.(startSize);\n cleanup();\n };\n\n window.addEventListener('pointermove', handleMove as EventListener);\n document.addEventListener('pointermove', handleMove as EventListener);\n window.addEventListener('mousemove', handleMove as EventListener);\n document.addEventListener('mousemove', handleMove as EventListener);\n handleEl.addEventListener('pointermove', handleMove as EventListener);\n window.addEventListener('pointerup', handleUp as EventListener);\n document.addEventListener('pointerup', handleUp as EventListener);\n window.addEventListener('mouseup', handleUp as EventListener);\n document.addEventListener('mouseup', handleUp as EventListener);\n window.addEventListener('pointercancel', handleUp as EventListener);\n document.addEventListener('pointercancel', handleUp as EventListener);\n window.addEventListener('keydown', handleKey as EventListener);\n handleEl.addEventListener('lostpointercapture', handleUp as EventListener);\n activeCleanupRef.current = cleanup;\n }}\n onDoubleClick={(e) => {\n props.onDoubleClick?.(e);\n if (!e.defaultPrevented && collapsible) requestToggle?.();\n }}\n onFocus={(e) => {\n props.onFocus?.(e);\n announceCeiling();\n }}\n onKeyDown={(e) => {\n props.onKeyDown?.(e);\n const container = containerRef.current;\n if (!container || e.defaultPrevented) return;\n const current = readSize();\n // The keys reach as far as a drag does: the frame caps both.\n const cap = ceiling();\n const clamp = (v: number) => Math.min(Math.max(v, minSize), cap);\n let next: number | undefined;\n if (e.key === 'Home') next = clamp(minSize);\n else if (e.key === 'End') next = clamp(cap);\n else {\n // The key moves the boundary along its axis; the pane grows or\n // shrinks the way a drag in that direction would, so Bottom's\n // ArrowUp grows it and an end-anchored pane mirrors in RTL.\n const along = orientation === 'vertical' ? (e.key === 'ArrowRight' ? 1 : e.key === 'ArrowLeft' ? -1 : 0) : e.key === 'ArrowDown' ? 1 : e.key === 'ArrowUp' ? -1 : 0;\n if (along === 0) return;\n const step = e.shiftKey ? 32 : 8;\n next = clamp(current + along * step * growth(getComputedStyle(container).direction === 'rtl'));\n }\n e.preventDefault();\n onResizeStart?.(current);\n write(container, next);\n onResize?.(next);\n onResizeEnd?.(next);\n }}\n >\n {children}\n </div>\n );\n});\nPaneHandle.displayName = 'Shell.Handle';\n\nexport const PanelHandle = React.forwardRef<HTMLDivElement, React.ComponentPropsWithoutRef<'div'>>((props, ref) => <PaneHandle {...props} ref={ref} />);\nPanelHandle.displayName = 'Shell.Panel.Handle';\n\nexport const SidebarHandle = React.forwardRef<HTMLDivElement, React.ComponentPropsWithoutRef<'div'>>((props, ref) => <PaneHandle {...props} ref={ref} />);\nSidebarHandle.displayName = 'Shell.Sidebar.Handle';\n\nexport const InspectorHandle = React.forwardRef<HTMLDivElement, React.ComponentPropsWithoutRef<'div'>>((props, ref) => <PaneHandle {...props} ref={ref} />);\nInspectorHandle.displayName = 'Shell.Inspector.Handle';\n\nexport const BottomHandle = React.forwardRef<HTMLDivElement, React.ComponentPropsWithoutRef<'div'>>((props, ref) => <PaneHandle {...props} ref={ref} />);\nBottomHandle.displayName = 'Shell.Bottom.Handle';\n"],
|
|
5
|
+
"mappings": "wCAAA,UAAYA,MAAW,QACvB,OAAOC,OAAgB,aAYhB,IAAMC,EAAmB,aAAkE,CAAC,CAAE,UAAAC,EAAW,SAAAC,EAAU,GAAGC,CAAM,EAAGC,IAAQ,CAC5I,GAAM,CACJ,aAAAC,EACA,SAAAC,EACA,WAAAC,EACA,QAAAC,EACA,QAAAC,EACA,YAAAC,EACA,YAAAC,EACA,KAAAC,GACA,OAAAC,EACA,SAAAC,EACA,cAAAC,EACA,YAAAC,EACA,WAAAC,EACA,cAAAC,GACA,kBAAAC,EACA,YAAAC,EACA,OAAAC,EACA,gBAAAC,GACA,cAAAC,EACF,EAAIC,EAAc,EAEZC,EAAkB,SAA8B,IAAI,EACpDC,GAAe,cAClBC,GAAgC,CAC/BF,EAAU,QAAUE,EAChB,OAAOvB,GAAQ,WAAYA,EAAIuB,CAAI,EAC9BvB,IAAMA,EAAsD,QAAUuB,EACjF,EACA,CAACvB,CAAG,CACN,EAEMwB,EAAyB,SAA4B,IAAI,EACzD,YACJ,IAAM,IAAM,CACVA,EAAiB,UAAU,EAC3BA,EAAiB,QAAU,IAC7B,EACA,CAAC,CACH,EAGA,IAAMC,EAAiB,cAAY,IAAM,CACvC,IAAMC,EAAYzB,EAAa,QAC/B,GAAI,CAACyB,EAAW,OAAOpB,EACvB,IAAMqB,EAAS,OAAO,WAAW,iBAAiBD,CAAS,EAAE,iBAAiBvB,CAAU,CAAC,EACzF,OAAO,OAAO,SAASwB,CAAM,EAAIA,EAASrB,CAC5C,EAAG,CAACL,EAAcE,EAAYG,CAAW,CAAC,EAUpCsB,EAAgB,cAAY,IAAM,CACtC,IAAMF,EAAYzB,EAAa,QACzB4B,EAASR,EAA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,IAAMC,GAAsB,aAAkE,CAAC9E,EAAOC,IAAQ,gBAACJ,EAAA,CAAY,GAAGG,EAAO,IAAKC,EAAK,CAAE,EACxJ6E,GAAc,YAAc,uBAErB,IAAMC,GAAwB,aAAkE,CAAC/E,EAAOC,IAAQ,gBAACJ,EAAA,CAAY,GAAGG,EAAO,IAAKC,EAAK,CAAE,EAC1J8E,GAAgB,YAAc,yBAEvB,IAAMC,GAAqB,aAAkE,CAAChF,EAAOC,IAAQ,gBAACJ,EAAA,CAAY,GAAGG,EAAO,IAAKC,EAAK,CAAE,EACvJ+E,GAAa,YAAc",
|
|
6
|
+
"names": ["React", "classNames", "PaneHandle", "className", "children", "props", "ref", "containerRef", "controls", "cssVarName", "minSize", "maxSize", "defaultSize", "orientation", "edge", "growth", "onResize", "onResizeStart", "onResizeEnd", "snapPoints", "snapTolerance", "collapseThreshold", "collapsible", "target", "requestCollapse", "requestToggle", "usePaneResize", "handleRef", "setRef", "node", "activeCleanupRef", "readSize", "container", "parsed", "ceiling", "handle", "frame", "pane", "hitBox", "sign", "room", "hit", "announceCeiling", "write", "size", "targetLabel", "classNames", "handleEl", "pointerId", "startStyle", "parsedStart", "startSize", "startClient", "cap", "clamp", "v", "body", "prevCursor", "prevUserSelect", "current", "raw", "pending", "flush", "lastHandledMove", "seenPointerEvent", "shouldHandle", "ev", "pointerType", "handleMove", "client", "cleanup", "handleUp", "handleKey", "finished", "settled", "nearest", "acc", "p", "kev", "next", "along", "step", "PanelHandle", "SidebarHandle", "InspectorHandle", "BottomHandle"]
|
|
7
|
+
}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{a as l}from"./chunk-4WVNMGI5.js";import{a as f}from"./chunk-
|
|
2
|
-
//# sourceMappingURL=chunk-
|
|
1
|
+
import{a as l}from"./chunk-4WVNMGI5.js";import{a as f}from"./chunk-C5RVO3C3.js";import{a as d}from"./chunk-25X75TI7.js";import{a as c}from"./chunk-PS6NEG5A.js";import{a as o}from"./chunk-5TAHT6VC.js";import{b as m}from"./chunk-SEY4NA45.js";import{a as t}from"./chunk-ZJ33QP5N.js";import{a as i}from"./chunk-GSTOGDAJ.js";import{a as p}from"./chunk-UBSLEGQZ.js";import*as r from"react";import M from"classnames";var N=r.forwardRef((e,u)=>{let C=m(),P=e.panelBackground??C.panelBackground,{asChild:s,children:y,className:v,src:g,fallback:h,name:x,description:n,avatarVariant:z,radius:U,color:k,panelBackground:b,flush:R,...T}=p(e,l,i),B={1:{avatar:"1",name:"1",description:"0"},2:{avatar:"2",name:"2",description:"1"},3:{avatar:"3",name:"3",description:"2"},4:{avatar:"4",name:"4",description:"3"}},D=e.size||"2",a=B[D],w=r.createElement(t,{align:"center",gap:"3"},r.createElement(d,{size:a.avatar,variant:z,radius:U,src:g,fallback:h,color:k}),r.createElement(t,{direction:"column",gap:"0",style:{minWidth:0}},r.createElement(o,{size:a.name,weight:"medium",truncate:!0},x),n&&r.createElement(o,{size:a.description,emphasis:"medium",truncate:!0},n)));return r.createElement(f,{...T,asChild:s,size:e.size,variant:e.variant,panelBackground:P,flush:R,ref:u,className:M("rt-UserCard",v)},c({asChild:s,children:y},w))});N.displayName="UserCard";export{N as a};
|
|
2
|
+
//# sourceMappingURL=chunk-HMSSFU6I.js.map
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
{
|
|
2
|
+
"version": 3,
|
|
3
|
+
"sources": ["../../src/components/_internal/shell-resize.tsx"],
|
|
4
|
+
"sourcesContent": ["import * as React from 'react';\nimport type { PaneName } from '../shell.types.js';\n\nexport interface PaneResizeContextValue {\n containerRef: React.RefObject<HTMLElement | null>;\n /** The pane the handle resizes, for `aria-controls`. */\n controls: string;\n cssVarName: string;\n minSize: number;\n maxSize: number;\n defaultSize: number;\n orientation: 'vertical' | 'horizontal';\n edge: 'start' | 'end';\n /**\n * +1 when moving the pointer toward the end of its axis grows the pane, -1\n * when it shrinks it. Read once when a drag starts, with the pane's\n * resolved direction, so no move pays for a style read.\n */\n growth: (isRtl: boolean) => 1 | -1;\n onResize?: (size: number) => void;\n onResizeStart?: (size: number) => void;\n onResizeEnd?: (size: number) => void;\n target: PaneName;\n collapsible: boolean;\n snapPoints?: number[];\n snapTolerance: number;\n collapseThreshold?: number;\n requestCollapse?: () => void;\n requestToggle?: () => void;\n}\n\nexport const PaneResizeContext = React.createContext<PaneResizeContextValue | null>(null);\n\nexport function usePaneResize() {\n const ctx = React.useContext(PaneResizeContext);\n if (!ctx) throw new Error('Shell.Handle must be used within a resizable pane');\n return ctx;\n}\n"],
|
|
5
|
+
"mappings": "AAAA,UAAYA,MAAW,QA+BhB,IAAMC,EAA0B,gBAA6C,IAAI,EAEjF,SAASC,GAAgB,CAC9B,IAAMC,EAAY,aAAWF,CAAiB,EAC9C,GAAI,CAACE,EAAK,MAAM,IAAI,MAAM,mDAAmD,EAC7E,OAAOA,CACT",
|
|
6
|
+
"names": ["React", "PaneResizeContext", "usePaneResize", "ctx"]
|
|
7
|
+
}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{a as p}from"./chunk-IBF5U4QW.js";import{a as n}from"./chunk-L6UXAITB.js";import{a as r}from"./chunk-GSTOGDAJ.js";import{a as t}from"./chunk-
|
|
2
|
-
//# sourceMappingURL=chunk-
|
|
1
|
+
import{a as p}from"./chunk-IBF5U4QW.js";import{a as n}from"./chunk-L6UXAITB.js";import{a as r}from"./chunk-GSTOGDAJ.js";import{a as t}from"./chunk-UBSLEGQZ.js";import*as e from"react";import P from"classnames";import{Slot as d}from"radix-ui";var c=e.forwardRef((s,m)=>{let{children:o,className:a,loading:i,...l}=t(s,n,r);if(!i)return o;let f=e.isValidElement(o)?d.Root:"span";return e.createElement(f,{ref:m,"aria-hidden":!0,className:P("rt-Skeleton",a),"data-inline-skeleton":e.isValidElement(o)?void 0:!0,tabIndex:-1,inert:p,...l},o)});c.displayName="Skeleton";export{c as a};
|
|
2
|
+
//# sourceMappingURL=chunk-IDUVJJYG.js.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{a as r}from"./chunk-GSTOGDAJ.js";import{a as t}from"./chunk-
|
|
2
|
-
//# sourceMappingURL=chunk-
|
|
1
|
+
import{a as r}from"./chunk-GSTOGDAJ.js";import{a as t}from"./chunk-UBSLEGQZ.js";import{a as e}from"./chunk-WMGIFPI2.js";import*as o from"react";import f from"classnames";import{composeEventHandlers as R}from"radix-ui/internal";var c=o.forwardRef((p,a)=>{let{className:i,color:s,material:n,onChange:m,onValueChange:d,...l}=t(p,e,r);return o.createElement("input",{type:"radio","data-accent-color":s,"data-material":n,...l,onChange:R(m,u=>d?.(u.currentTarget.value)),ref:a,className:f("rt-reset","rt-BaseRadioRoot","rt-RadioRoot",i)})});c.displayName="Radio";export{c as a};
|
|
2
|
+
//# sourceMappingURL=chunk-IK3MQHA5.js.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{a as s}from"./chunk-OGVKSYLL.js";import{a as C}from"./chunk-
|
|
2
|
-
//# sourceMappingURL=chunk-
|
|
1
|
+
import{a as s}from"./chunk-OGVKSYLL.js";import{a as C}from"./chunk-5TAHT6VC.js";import{a as u,b as c}from"./chunk-5T6K7VPP.js";import{a as m}from"./chunk-GSTOGDAJ.js";import{a as i}from"./chunk-UBSLEGQZ.js";import{a as N}from"./chunk-OS3FCYZY.js";var g={};N(g,{Icon:()=>f,Root:()=>R,Text:()=>d});import*as o from"react";import p from"classnames";import{Slot as h}from"radix-ui";var P=o.createContext({}),R=o.forwardRef((t,a)=>{let{size:e=s.size.default,live:r="polite",role:x="status",variant:n}=t,{asChild:v,children:y,className:T,color:l,panelBackground:I,material:E,...w}=i(t,s,m),z=v?h.Root:"div";return o.createElement(z,{"data-accent-color":l,"data-panel-background":I,"data-material":E,...w,...{role:x,"aria-live":r,"aria-atomic":!0},className:p("rt-CalloutRoot",T),ref:a},o.createElement(P.Provider,{value:o.useMemo(()=>({size:e,variant:n,color:l}),[e,n,l])},y))});R.displayName="Callout.Root";var f=o.forwardRef(({className:t,...a},e)=>o.createElement("div",{...a,className:p("rt-CalloutIcon",t),ref:e}));f.displayName="Callout.Icon";var d=o.forwardRef(({className:t,...a},e)=>{let{size:r}=o.useContext(P);return o.createElement(C,{as:"p",size:u(r,c),...a,asChild:!1,ref:e,className:p("rt-CalloutText",t)})});d.displayName="Callout.Text";export{R as a,f as b,d as c,g as d};
|
|
2
|
+
//# sourceMappingURL=chunk-JDEBKA56.js.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{a as e}from"./chunk-ARIV4AT5.js";import{a as p}from"./chunk-GSTOGDAJ.js";import{a as r}from"./chunk-
|
|
2
|
-
//# sourceMappingURL=chunk-
|
|
1
|
+
import{a as e}from"./chunk-ARIV4AT5.js";import{a as p}from"./chunk-GSTOGDAJ.js";import{a as r}from"./chunk-UBSLEGQZ.js";import*as o from"react";import a from"classnames";import{Slot as i}from"radix-ui";var P=o.forwardRef((t,s)=>{let{asChild:m,className:d,...f}=r(t,e,p),n=m?i.Root:"kbd";return o.createElement(n,{...f,ref:s,className:a("rt-reset","rt-Kbd",d)})});P.displayName="Kbd";export{P as a};
|
|
2
|
+
//# sourceMappingURL=chunk-JDWCQ2XP.js.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{
|
|
2
|
-
//# sourceMappingURL=chunk-
|
|
1
|
+
import{a as u,e as f,f as l,g as R}from"./chunk-V32EP3S7.js";import{a as x}from"./chunk-5SNHUVDA.js";import{b as P}from"./chunk-IX5HIHVI.js";import{a as G}from"./chunk-5TAHT6VC.js";import{a as n}from"./chunk-GSTOGDAJ.js";import{a}from"./chunk-UBSLEGQZ.js";import{a as E}from"./chunk-OS3FCYZY.js";var T={};E(T,{Item:()=>N,Root:()=>v});import*as o from"react";import b from"classnames";import{Context as S}from"radix-ui/internal";var I="CheckboxGroup",[_]=S.createContextScope(I,[u]),d=u(),[g,y]=_(I),v=o.forwardRef(({color:s=x.color.default,size:e=x.size.default,variant:t=x.variant.default,...r},p)=>{let{__scopeCheckboxGroup:c,className:m,...C}=a(r,n),i=d(c);return o.createElement(g,{scope:c,color:s,size:e,variant:t},o.createElement(f,{...i,...C,ref:p,className:b("rt-CheckboxGroupRoot",m)}))});v.displayName="CheckboxGroup.Root";var N=o.forwardRef((s,e)=>{let{__scopeCheckboxGroup:t,children:r,className:p,style:c,...m}=s,{size:C}=y("CheckboxGroupItem",t),i=h=>typeof h=="string"&&/^[1-9]$/.test(h)?h:"3";return r?o.createElement(G,{as:"label",size:i(C),className:b("rt-CheckboxGroupItem",p),style:c},o.createElement(k,{__scopeCheckboxGroup:t,...m,ref:e}),r&&o.createElement("span",{className:"rt-CheckboxGroupItemInner"},r)):o.createElement(k,{__scopeCheckboxGroup:t,...m,ref:e,className:p,style:c})});N.displayName="CheckboxGroup.Item";var k=o.forwardRef(({__scopeCheckboxGroup:s,...e},t)=>{let r=y("CheckboxGroupItemCheckbox",s),p=d(s),{color:c,className:m}=a({...e,...r},x,n);return o.createElement(l,{...p,"data-accent-color":c,...e,ref:t,className:b("rt-reset","rt-BaseCheckboxRoot","rt-CheckboxGroupItemCheckbox",m)},o.createElement(R,{...p,asChild:!0,className:"rt-BaseCheckboxIndicator"},o.createElement(P,null)))});k.displayName="CheckboxGroup.ItemCheckbox";export{v as a,N as b,T as c};
|
|
2
|
+
//# sourceMappingURL=chunk-JQSZF3E2.js.map
|