@womp/kookie-ui 0.35.7 → 0.37.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 +12 -20
- package/dist/cjs/components/_internal/base-menu.utils.js +1 -1
- package/dist/cjs/components/_internal/base-menu.utils.js.map +2 -2
- package/dist/cjs/components/_internal/menu-context.js +1 -1
- package/dist/cjs/components/_internal/menu-context.js.map +2 -2
- package/dist/cjs/components/_internal/pane-chrome.js +1 -1
- package/dist/cjs/components/_internal/pane-chrome.js.map +2 -2
- package/dist/cjs/components/_internal/shell-bottom.d.ts +3 -3
- 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 +3 -3
- 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 +3 -3
- 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 +3 -3
- package/dist/cjs/components/_internal/shell-pane.d.ts +2 -7
- package/dist/cjs/components/_internal/shell-pane.d.ts.map +1 -1
- package/dist/cjs/components/_internal/shell-pane.js +1 -1
- package/dist/cjs/components/_internal/shell-pane.js.map +3 -3
- package/dist/cjs/components/_internal/shell-resizable.d.ts +3 -9
- package/dist/cjs/components/_internal/shell-resizable.d.ts.map +1 -1
- package/dist/cjs/components/_internal/shell-resizable.js +1 -1
- package/dist/cjs/components/_internal/shell-resizable.js.map +3 -3
- package/dist/cjs/components/_internal/shell-resize.d.ts +0 -4
- 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 +1 -6
- package/dist/cjs/components/_internal/shell-rest.d.ts.map +1 -1
- package/dist/cjs/components/_internal/shell-rest.js +1 -1
- package/dist/cjs/components/_internal/shell-rest.js.map +3 -3
- package/dist/cjs/components/_internal/shell-sidebar.d.ts +3 -3
- 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 +3 -3
- package/dist/cjs/components/_internal/shell-store.d.ts +0 -10
- package/dist/cjs/components/_internal/shell-store.d.ts.map +1 -1
- package/dist/cjs/components/_internal/shell-store.js +1 -1
- package/dist/cjs/components/_internal/shell-store.js.map +3 -3
- package/dist/cjs/components/_internal/use-close-warning.d.ts +12 -0
- package/dist/cjs/components/_internal/use-close-warning.d.ts.map +1 -0
- package/dist/cjs/components/_internal/use-close-warning.js +3 -0
- package/dist/cjs/components/_internal/use-close-warning.js.map +7 -0
- package/dist/cjs/components/checkbox-group.js +1 -1
- package/dist/cjs/components/checkbox-group.js.map +3 -3
- package/dist/cjs/components/checkbox-group.primitive.d.ts +0 -10
- package/dist/cjs/components/checkbox-group.primitive.d.ts.map +1 -1
- package/dist/cjs/components/checkbox-group.primitive.js +1 -1
- package/dist/cjs/components/checkbox-group.primitive.js.map +3 -3
- package/dist/cjs/components/context-menu.d.ts +1 -5
- package/dist/cjs/components/context-menu.d.ts.map +1 -1
- package/dist/cjs/components/context-menu.js +1 -1
- package/dist/cjs/components/context-menu.js.map +3 -3
- package/dist/cjs/components/dialog.d.ts.map +1 -1
- package/dist/cjs/components/dialog.js +1 -1
- package/dist/cjs/components/dialog.js.map +4 -4
- package/dist/cjs/components/dropdown-menu.js +1 -1
- package/dist/cjs/components/dropdown-menu.js.map +2 -2
- package/dist/cjs/components/index.js +2 -2
- package/dist/cjs/components/index.js.map +4 -4
- package/dist/cjs/components/navigator.js.map +2 -2
- package/dist/cjs/components/schemas/index.d.ts +1 -1
- package/dist/cjs/components/schemas/index.d.ts.map +1 -1
- 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 +6 -112
- 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/separator.js +1 -1
- package/dist/cjs/components/separator.js.map +2 -2
- package/dist/cjs/components/sheet.d.ts +7 -4
- package/dist/cjs/components/sheet.d.ts.map +1 -1
- package/dist/cjs/components/sheet.js +1 -1
- package/dist/cjs/components/sheet.js.map +4 -4
- package/dist/cjs/components/shell.context.d.ts +1 -45
- 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 +7 -37
- package/dist/cjs/components/shell.d.ts.map +1 -1
- 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 +6 -27
- 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 +2 -2
- package/dist/cjs/components/sidebar.js +1 -1
- package/dist/cjs/components/sidebar.js.map +2 -2
- package/dist/cjs/components/toolbar.js +1 -1
- package/dist/cjs/components/toolbar.js.map +2 -2
- package/dist/cjs/hooks/use-breakpoint.js +1 -1
- package/dist/cjs/hooks/use-breakpoint.js.map +2 -2
- package/dist/cjs/index.js +4 -4
- package/dist/cjs/index.js.map +4 -4
- package/dist/esm/{chunk-LR4X7SVV.js → chunk-2K46JPUL.js} +2 -2
- package/dist/esm/chunk-3K7E4XL3.js +3 -0
- package/dist/esm/chunk-3K7E4XL3.js.map +7 -0
- package/dist/esm/chunk-3LR7KMBE.js +3 -0
- package/dist/esm/chunk-3LR7KMBE.js.map +7 -0
- package/dist/esm/{chunk-HGF4CKRY.js → chunk-3ZBEWLSO.js} +2 -2
- package/dist/esm/{chunk-26O4RBOJ.js → chunk-5BABJBV3.js} +2 -2
- package/dist/esm/{chunk-5APRBJRR.js → chunk-5GTQXMS2.js} +2 -2
- package/dist/esm/chunk-5U2LEJLU.js +3 -0
- package/dist/esm/chunk-5U2LEJLU.js.map +7 -0
- package/dist/esm/{chunk-KBSH6CBD.js → chunk-5XO3PLDH.js} +2 -2
- package/dist/esm/{chunk-SGKLJDA3.js → chunk-74JANLVU.js} +2 -2
- package/dist/esm/{chunk-TUZ665BA.js → chunk-7E3ZOVRL.js} +2 -2
- package/dist/esm/{chunk-COLJWVN7.js → chunk-AQR42GKA.js} +2 -2
- package/dist/esm/{chunk-FTNZWAPB.js → chunk-ARPUPT4M.js} +2 -2
- package/dist/esm/{chunk-OMPLFDS6.js → chunk-ASBTPKH3.js} +2 -2
- package/dist/esm/{chunk-JFJV4HL3.js → chunk-CFXFWIRM.js} +2 -2
- package/dist/esm/{chunk-YLGIP3A5.js → chunk-CJZGEHVB.js} +2 -2
- package/dist/esm/{chunk-ISCZ57VL.js → chunk-DJGZ4K3V.js} +2 -2
- package/dist/esm/{chunk-PMXIQ5B4.js → chunk-FKCKELUB.js} +2 -2
- package/dist/esm/{chunk-Y5ITMKC6.js → chunk-G7S2BMS3.js} +2 -2
- package/dist/esm/{chunk-SR42NATX.js → chunk-GHIHF55B.js} +2 -2
- package/dist/esm/chunk-H7GH3DTF.js +3 -0
- package/dist/esm/chunk-H7GH3DTF.js.map +7 -0
- package/dist/esm/{chunk-C6VGCYFQ.js → chunk-HNOT2HS4.js} +2 -2
- package/dist/esm/chunk-HWT2K2XR.js +3 -0
- package/dist/esm/chunk-HWT2K2XR.js.map +7 -0
- package/dist/esm/{chunk-D42VCLKH.js → chunk-ICO5ULJL.js} +2 -2
- package/dist/esm/{chunk-FYZXC7AL.js → chunk-JJVAVLCN.js} +2 -2
- package/dist/esm/chunk-LBAC2X4U.js +3 -0
- package/dist/esm/{chunk-5BXCPANF.js.map → chunk-LBAC2X4U.js.map} +3 -3
- package/dist/esm/{chunk-R4DMVTM3.js → chunk-M6THDAMU.js} +2 -2
- package/dist/esm/{chunk-MAA6LEE2.js → chunk-MDQ7ZHOS.js} +1 -1
- package/dist/esm/chunk-MDQ7ZHOS.js.map +7 -0
- package/dist/esm/chunk-MQA3BKF4.js +3 -0
- package/dist/esm/chunk-MQA3BKF4.js.map +7 -0
- package/dist/esm/{chunk-VBF3XALY.js → chunk-MS2ONKJJ.js} +2 -2
- package/dist/esm/chunk-MXNPCJPV.js +3 -0
- package/dist/esm/chunk-MXNPCJPV.js.map +7 -0
- package/dist/esm/{chunk-XFMAA4MD.js → chunk-NJG42JDM.js} +2 -2
- package/dist/esm/{chunk-NJ7RQYLX.js → chunk-OIJQSUUM.js} +2 -2
- package/dist/esm/{chunk-VYF6KKYM.js → chunk-ONJYRJ66.js} +2 -2
- package/dist/esm/chunk-PIVHOUEA.js +3 -0
- package/dist/esm/chunk-PIVHOUEA.js.map +7 -0
- package/dist/esm/{chunk-UH6CJXHY.js → chunk-QPGW6RJG.js} +2 -2
- package/dist/esm/{chunk-EB4AG3OL.js → chunk-REELD6CT.js} +2 -2
- package/dist/esm/chunk-RYXIRZQW.js +3 -0
- package/dist/esm/chunk-RYXIRZQW.js.map +7 -0
- package/dist/esm/chunk-S66WR5R7.js +3 -0
- package/dist/esm/{chunk-MXEOE4LA.js.map → chunk-S66WR5R7.js.map} +2 -2
- package/dist/esm/chunk-SECVO3CW.js +3 -0
- package/dist/esm/chunk-SECVO3CW.js.map +7 -0
- package/dist/esm/chunk-SHDZYFUN.js +3 -0
- package/dist/esm/chunk-SHDZYFUN.js.map +7 -0
- package/dist/esm/{chunk-3M5ZM67R.js → chunk-TCFBNE6A.js} +2 -2
- package/dist/esm/chunk-U7P64MXD.js +3 -0
- package/dist/esm/chunk-U7P64MXD.js.map +7 -0
- package/dist/esm/chunk-UFYQC5XY.js +3 -0
- package/dist/esm/chunk-UFYQC5XY.js.map +7 -0
- package/dist/esm/{chunk-QBONJMSE.js → chunk-VRQK7U7J.js} +2 -2
- package/dist/esm/{chunk-TANYRHGP.js → chunk-W3X4N4JE.js} +2 -2
- package/dist/esm/{chunk-OPYTQ34H.js → chunk-W4CPV4PO.js} +2 -2
- package/dist/esm/{chunk-G66WDIIV.js → chunk-WJKCXGVN.js} +2 -2
- package/dist/esm/{chunk-YLPCYCYA.js → chunk-WT4IDG2W.js} +2 -2
- package/dist/esm/chunk-XBDAE77C.js +3 -0
- package/dist/esm/chunk-XBDAE77C.js.map +7 -0
- package/dist/esm/{chunk-X4PWBFOT.js → chunk-YM47BXKK.js} +2 -2
- package/dist/esm/chunk-YOESAYMJ.js +3 -0
- package/dist/esm/chunk-YOESAYMJ.js.map +7 -0
- package/dist/esm/{chunk-FVRVBB6O.js → chunk-YOZXIUZY.js} +2 -2
- package/dist/esm/{chunk-OGVKMDO7.js → chunk-YRCXTCIT.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/pane-chrome.js +1 -1
- package/dist/esm/components/_internal/portal-theme.js +1 -1
- package/dist/esm/components/_internal/shell-bottom.d.ts +3 -3
- 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.map +1 -1
- package/dist/esm/components/_internal/shell-handles.js +1 -1
- package/dist/esm/components/_internal/shell-inspector.d.ts +3 -3
- 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 +2 -7
- package/dist/esm/components/_internal/shell-pane.d.ts.map +1 -1
- package/dist/esm/components/_internal/shell-pane.js +1 -1
- package/dist/esm/components/_internal/shell-resizable.d.ts +3 -9
- package/dist/esm/components/_internal/shell-resizable.d.ts.map +1 -1
- package/dist/esm/components/_internal/shell-resizable.js +1 -1
- package/dist/esm/components/_internal/shell-resize.d.ts +0 -4
- 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 +1 -6
- package/dist/esm/components/_internal/shell-rest.d.ts.map +1 -1
- package/dist/esm/components/_internal/shell-rest.js +1 -1
- package/dist/esm/components/_internal/shell-sidebar.d.ts +3 -3
- 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 +0 -10
- package/dist/esm/components/_internal/shell-store.d.ts.map +1 -1
- package/dist/esm/components/_internal/shell-store.js +1 -1
- package/dist/esm/components/_internal/use-close-warning.d.ts +12 -0
- package/dist/esm/components/_internal/use-close-warning.d.ts.map +1 -0
- package/dist/esm/components/_internal/use-close-warning.js +3 -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/button.js +1 -1
- package/dist/esm/components/chatbar.js +1 -1
- package/dist/esm/components/checkbox-group.js +1 -1
- package/dist/esm/components/checkbox-group.primitive.d.ts +0 -10
- package/dist/esm/components/checkbox-group.primitive.d.ts.map +1 -1
- package/dist/esm/components/checkbox-group.primitive.js +1 -1
- package/dist/esm/components/checkbox.js +1 -1
- package/dist/esm/components/chip.js +1 -1
- package/dist/esm/components/combobox.js +1 -1
- package/dist/esm/components/command.js +1 -1
- package/dist/esm/components/context-menu.d.ts +1 -5
- package/dist/esm/components/context-menu.d.ts.map +1 -1
- package/dist/esm/components/context-menu.js +1 -1
- package/dist/esm/components/dialog.d.ts.map +1 -1
- package/dist/esm/components/dialog.js +1 -1
- package/dist/esm/components/dropdown-menu.js +1 -1
- package/dist/esm/components/index.js +1 -1
- package/dist/esm/components/message-scroller.js +1 -1
- package/dist/esm/components/navigator.js +1 -1
- package/dist/esm/components/notice.js +1 -1
- package/dist/esm/components/popover.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.d.ts +1 -1
- package/dist/esm/components/schemas/index.d.ts.map +1 -1
- package/dist/esm/components/schemas/index.js +1 -1
- package/dist/esm/components/schemas/index.js.map +2 -2
- package/dist/esm/components/schemas/shell.schema.d.ts +6 -112
- 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/select.js +1 -1
- package/dist/esm/components/separator.js +1 -1
- package/dist/esm/components/sheet.d.ts +7 -4
- package/dist/esm/components/sheet.d.ts.map +1 -1
- package/dist/esm/components/sheet.js +1 -1
- package/dist/esm/components/shell.context.d.ts +1 -45
- 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 +7 -37
- package/dist/esm/components/shell.d.ts.map +1 -1
- package/dist/esm/components/shell.js +1 -1
- package/dist/esm/components/shell.types.d.ts +6 -27
- 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/slider.js +1 -1
- package/dist/esm/components/switch.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/theme.js +1 -1
- package/dist/esm/components/toggle.js +1 -1
- package/dist/esm/components/toolbar.js +1 -1
- package/dist/esm/components/tooltip.js +1 -1
- package/dist/esm/components/virtual-menu.js +1 -1
- package/dist/esm/hooks/use-breakpoint.js +1 -1
- package/dist/esm/index.js +1 -1
- package/package.json +1 -5
- package/schemas/index.json +13 -335
- package/schemas/shell-bottom.json +2 -63
- package/schemas/shell-inspector.json +2 -63
- package/schemas/shell-panel.json +2 -63
- package/schemas/shell-rail.json +2 -38
- package/schemas/shell-sidebar.json +5 -102
- package/schemas/shell-trigger.json +0 -6
- package/src/components/_internal/base-dialog.css +15 -0
- package/src/components/_internal/shell-bottom.tsx +6 -26
- package/src/components/_internal/shell-handles.tsx +2 -32
- package/src/components/_internal/shell-inspector.tsx +6 -26
- package/src/components/_internal/shell-pane.tsx +7 -56
- package/src/components/_internal/shell-resizable.tsx +6 -81
- package/src/components/_internal/shell-resize.tsx +0 -4
- package/src/components/_internal/shell-rest.ts +2 -11
- package/src/components/_internal/shell-sidebar.tsx +8 -30
- package/src/components/_internal/shell-store.tsx +1 -34
- package/src/components/_internal/use-close-warning.ts +38 -0
- package/src/components/checkbox-group.primitive.tsx +0 -12
- package/src/components/context-menu.tsx +1 -6
- package/src/components/dialog.tsx +6 -1
- package/src/components/schemas/index.ts +0 -1
- package/src/components/schemas/shell.schema.ts +3 -20
- package/src/components/sheet.tsx +11 -5
- package/src/components/shell.context.tsx +5 -112
- package/src/components/shell.css +1 -29
- package/src/components/shell.tsx +12 -97
- package/src/components/shell.types.ts +6 -28
- package/styles.css +12 -20
- package/dist/cjs/components/shell.hooks.d.ts +0 -10
- package/dist/cjs/components/shell.hooks.d.ts.map +0 -1
- package/dist/cjs/components/shell.hooks.js +0 -3
- package/dist/cjs/components/shell.hooks.js.map +0 -7
- package/dist/esm/chunk-2VSRZ4IT.js +0 -3
- package/dist/esm/chunk-2VSRZ4IT.js.map +0 -7
- package/dist/esm/chunk-2WFN4D52.js +0 -3
- package/dist/esm/chunk-2WFN4D52.js.map +0 -7
- package/dist/esm/chunk-4OJRLS5N.js +0 -3
- package/dist/esm/chunk-4OJRLS5N.js.map +0 -7
- package/dist/esm/chunk-4TTRPCGG.js +0 -3
- package/dist/esm/chunk-4TTRPCGG.js.map +0 -7
- package/dist/esm/chunk-5BXCPANF.js +0 -3
- package/dist/esm/chunk-B447PNRD.js +0 -3
- package/dist/esm/chunk-B447PNRD.js.map +0 -7
- package/dist/esm/chunk-BJVXB3PN.js +0 -3
- package/dist/esm/chunk-BJVXB3PN.js.map +0 -7
- package/dist/esm/chunk-HQT32HQ6.js +0 -3
- package/dist/esm/chunk-HQT32HQ6.js.map +0 -7
- package/dist/esm/chunk-KGCGT4MJ.js +0 -3
- package/dist/esm/chunk-KGCGT4MJ.js.map +0 -7
- package/dist/esm/chunk-M26LLCQC.js +0 -3
- package/dist/esm/chunk-M26LLCQC.js.map +0 -7
- package/dist/esm/chunk-MAA6LEE2.js.map +0 -7
- package/dist/esm/chunk-MXEOE4LA.js +0 -3
- package/dist/esm/chunk-QV66TN2A.js +0 -3
- package/dist/esm/chunk-QV66TN2A.js.map +0 -7
- package/dist/esm/chunk-TRJAVWCK.js +0 -3
- package/dist/esm/chunk-TRJAVWCK.js.map +0 -7
- package/dist/esm/chunk-TS4QCDSI.js +0 -3
- package/dist/esm/chunk-TS4QCDSI.js.map +0 -7
- package/dist/esm/chunk-XOAOSRTH.js +0 -3
- package/dist/esm/chunk-XOAOSRTH.js.map +0 -7
- package/dist/esm/chunk-XUCR7L4G.js +0 -3
- package/dist/esm/chunk-XUCR7L4G.js.map +0 -7
- package/dist/esm/chunk-XVN43IZL.js +0 -3
- package/dist/esm/chunk-XVN43IZL.js.map +0 -7
- package/dist/esm/components/shell.hooks.d.ts +0 -10
- package/dist/esm/components/shell.hooks.d.ts.map +0 -1
- package/dist/esm/components/shell.hooks.js +0 -3
- package/src/components/shell.hooks.ts +0 -20
- /package/dist/esm/{chunk-LR4X7SVV.js.map → chunk-2K46JPUL.js.map} +0 -0
- /package/dist/esm/{chunk-HGF4CKRY.js.map → chunk-3ZBEWLSO.js.map} +0 -0
- /package/dist/esm/{chunk-26O4RBOJ.js.map → chunk-5BABJBV3.js.map} +0 -0
- /package/dist/esm/{chunk-5APRBJRR.js.map → chunk-5GTQXMS2.js.map} +0 -0
- /package/dist/esm/{chunk-KBSH6CBD.js.map → chunk-5XO3PLDH.js.map} +0 -0
- /package/dist/esm/{chunk-SGKLJDA3.js.map → chunk-74JANLVU.js.map} +0 -0
- /package/dist/esm/{chunk-TUZ665BA.js.map → chunk-7E3ZOVRL.js.map} +0 -0
- /package/dist/esm/{chunk-COLJWVN7.js.map → chunk-AQR42GKA.js.map} +0 -0
- /package/dist/esm/{chunk-FTNZWAPB.js.map → chunk-ARPUPT4M.js.map} +0 -0
- /package/dist/esm/{chunk-OMPLFDS6.js.map → chunk-ASBTPKH3.js.map} +0 -0
- /package/dist/esm/{chunk-JFJV4HL3.js.map → chunk-CFXFWIRM.js.map} +0 -0
- /package/dist/esm/{chunk-YLGIP3A5.js.map → chunk-CJZGEHVB.js.map} +0 -0
- /package/dist/esm/{chunk-ISCZ57VL.js.map → chunk-DJGZ4K3V.js.map} +0 -0
- /package/dist/esm/{chunk-PMXIQ5B4.js.map → chunk-FKCKELUB.js.map} +0 -0
- /package/dist/esm/{chunk-Y5ITMKC6.js.map → chunk-G7S2BMS3.js.map} +0 -0
- /package/dist/esm/{chunk-SR42NATX.js.map → chunk-GHIHF55B.js.map} +0 -0
- /package/dist/esm/{chunk-C6VGCYFQ.js.map → chunk-HNOT2HS4.js.map} +0 -0
- /package/dist/esm/{chunk-D42VCLKH.js.map → chunk-ICO5ULJL.js.map} +0 -0
- /package/dist/esm/{chunk-FYZXC7AL.js.map → chunk-JJVAVLCN.js.map} +0 -0
- /package/dist/esm/{chunk-R4DMVTM3.js.map → chunk-M6THDAMU.js.map} +0 -0
- /package/dist/esm/{chunk-VBF3XALY.js.map → chunk-MS2ONKJJ.js.map} +0 -0
- /package/dist/esm/{chunk-XFMAA4MD.js.map → chunk-NJG42JDM.js.map} +0 -0
- /package/dist/esm/{chunk-NJ7RQYLX.js.map → chunk-OIJQSUUM.js.map} +0 -0
- /package/dist/esm/{chunk-VYF6KKYM.js.map → chunk-ONJYRJ66.js.map} +0 -0
- /package/dist/esm/{chunk-UH6CJXHY.js.map → chunk-QPGW6RJG.js.map} +0 -0
- /package/dist/esm/{chunk-EB4AG3OL.js.map → chunk-REELD6CT.js.map} +0 -0
- /package/dist/esm/{chunk-3M5ZM67R.js.map → chunk-TCFBNE6A.js.map} +0 -0
- /package/dist/esm/{chunk-QBONJMSE.js.map → chunk-VRQK7U7J.js.map} +0 -0
- /package/dist/esm/{chunk-TANYRHGP.js.map → chunk-W3X4N4JE.js.map} +0 -0
- /package/dist/esm/{chunk-OPYTQ34H.js.map → chunk-W4CPV4PO.js.map} +0 -0
- /package/dist/esm/{chunk-G66WDIIV.js.map → chunk-WJKCXGVN.js.map} +0 -0
- /package/dist/esm/{chunk-YLPCYCYA.js.map → chunk-WT4IDG2W.js.map} +0 -0
- /package/dist/esm/{chunk-X4PWBFOT.js.map → chunk-YM47BXKK.js.map} +0 -0
- /package/dist/esm/{chunk-FVRVBB6O.js.map → chunk-YOZXIUZY.js.map} +0 -0
- /package/dist/esm/{chunk-OGVKMDO7.js.map → chunk-YRCXTCIT.js.map} +0 -0
- /package/dist/esm/components/{shell.hooks.js.map → _internal/use-close-warning.js.map} +0 -0
|
@@ -114,44 +114,8 @@
|
|
|
114
114
|
},
|
|
115
115
|
"children": {},
|
|
116
116
|
"open": {
|
|
117
|
-
"description": "The open state, when controlled
|
|
118
|
-
"
|
|
119
|
-
{
|
|
120
|
-
"type": "boolean"
|
|
121
|
-
},
|
|
122
|
-
{
|
|
123
|
-
"anyOf": [
|
|
124
|
-
{
|
|
125
|
-
"type": "boolean"
|
|
126
|
-
},
|
|
127
|
-
{
|
|
128
|
-
"type": "object",
|
|
129
|
-
"properties": {
|
|
130
|
-
"initial": {
|
|
131
|
-
"type": "boolean"
|
|
132
|
-
},
|
|
133
|
-
"xs": {
|
|
134
|
-
"type": "boolean"
|
|
135
|
-
},
|
|
136
|
-
"sm": {
|
|
137
|
-
"type": "boolean"
|
|
138
|
-
},
|
|
139
|
-
"md": {
|
|
140
|
-
"type": "boolean"
|
|
141
|
-
},
|
|
142
|
-
"lg": {
|
|
143
|
-
"type": "boolean"
|
|
144
|
-
},
|
|
145
|
-
"xl": {
|
|
146
|
-
"type": "boolean"
|
|
147
|
-
}
|
|
148
|
-
},
|
|
149
|
-
"additionalProperties": false
|
|
150
|
-
}
|
|
151
|
-
],
|
|
152
|
-
"description": "Responsive open state"
|
|
153
|
-
}
|
|
154
|
-
]
|
|
117
|
+
"description": "The open state, when controlled",
|
|
118
|
+
"type": "boolean"
|
|
155
119
|
},
|
|
156
120
|
"defaultOpen": {
|
|
157
121
|
"description": "The starting state. A responsive object leaves the pane untouched, with that object as the answer at each breakpoint.",
|
|
@@ -237,31 +201,6 @@
|
|
|
237
201
|
},
|
|
238
202
|
"sizeUpdateMs": {
|
|
239
203
|
"type": "number"
|
|
240
|
-
},
|
|
241
|
-
"snapPoints": {
|
|
242
|
-
"description": "Deprecated, removed in 1.0",
|
|
243
|
-
"type": "array",
|
|
244
|
-
"items": {
|
|
245
|
-
"type": "number"
|
|
246
|
-
}
|
|
247
|
-
},
|
|
248
|
-
"snapTolerance": {
|
|
249
|
-
"description": "Deprecated, removed in 1.0",
|
|
250
|
-
"type": "number"
|
|
251
|
-
},
|
|
252
|
-
"collapseThreshold": {
|
|
253
|
-
"description": "Deprecated, removed in 1.0",
|
|
254
|
-
"type": "number"
|
|
255
|
-
},
|
|
256
|
-
"paneId": {
|
|
257
|
-
"description": "Deprecated, removed in 1.0",
|
|
258
|
-
"type": "string"
|
|
259
|
-
},
|
|
260
|
-
"persistence": {
|
|
261
|
-
"type": "object",
|
|
262
|
-
"properties": {},
|
|
263
|
-
"description": "Deprecated, removed in 1.0. Keep the size in your own state with `size`/`onSizeChange`.",
|
|
264
|
-
"additionalProperties": false
|
|
265
204
|
}
|
|
266
205
|
},
|
|
267
206
|
"additionalProperties": false
|
package/schemas/shell-panel.json
CHANGED
|
@@ -110,44 +110,8 @@
|
|
|
110
110
|
},
|
|
111
111
|
"children": {},
|
|
112
112
|
"open": {
|
|
113
|
-
"description": "The open state, when controlled
|
|
114
|
-
"
|
|
115
|
-
{
|
|
116
|
-
"type": "boolean"
|
|
117
|
-
},
|
|
118
|
-
{
|
|
119
|
-
"anyOf": [
|
|
120
|
-
{
|
|
121
|
-
"type": "boolean"
|
|
122
|
-
},
|
|
123
|
-
{
|
|
124
|
-
"type": "object",
|
|
125
|
-
"properties": {
|
|
126
|
-
"initial": {
|
|
127
|
-
"type": "boolean"
|
|
128
|
-
},
|
|
129
|
-
"xs": {
|
|
130
|
-
"type": "boolean"
|
|
131
|
-
},
|
|
132
|
-
"sm": {
|
|
133
|
-
"type": "boolean"
|
|
134
|
-
},
|
|
135
|
-
"md": {
|
|
136
|
-
"type": "boolean"
|
|
137
|
-
},
|
|
138
|
-
"lg": {
|
|
139
|
-
"type": "boolean"
|
|
140
|
-
},
|
|
141
|
-
"xl": {
|
|
142
|
-
"type": "boolean"
|
|
143
|
-
}
|
|
144
|
-
},
|
|
145
|
-
"additionalProperties": false
|
|
146
|
-
}
|
|
147
|
-
],
|
|
148
|
-
"description": "Responsive open state"
|
|
149
|
-
}
|
|
150
|
-
]
|
|
113
|
+
"description": "The open state, when controlled",
|
|
114
|
+
"type": "boolean"
|
|
151
115
|
},
|
|
152
116
|
"defaultOpen": {
|
|
153
117
|
"description": "The starting state. A responsive object leaves the pane untouched, with that object as the answer at each breakpoint.",
|
|
@@ -233,31 +197,6 @@
|
|
|
233
197
|
},
|
|
234
198
|
"sizeUpdateMs": {
|
|
235
199
|
"type": "number"
|
|
236
|
-
},
|
|
237
|
-
"snapPoints": {
|
|
238
|
-
"description": "Deprecated, removed in 1.0",
|
|
239
|
-
"type": "array",
|
|
240
|
-
"items": {
|
|
241
|
-
"type": "number"
|
|
242
|
-
}
|
|
243
|
-
},
|
|
244
|
-
"snapTolerance": {
|
|
245
|
-
"description": "Deprecated, removed in 1.0",
|
|
246
|
-
"type": "number"
|
|
247
|
-
},
|
|
248
|
-
"collapseThreshold": {
|
|
249
|
-
"description": "Deprecated, removed in 1.0",
|
|
250
|
-
"type": "number"
|
|
251
|
-
},
|
|
252
|
-
"paneId": {
|
|
253
|
-
"description": "Deprecated, removed in 1.0",
|
|
254
|
-
"type": "string"
|
|
255
|
-
},
|
|
256
|
-
"persistence": {
|
|
257
|
-
"type": "object",
|
|
258
|
-
"properties": {},
|
|
259
|
-
"description": "Deprecated, removed in 1.0. Keep the size in your own state with `size`/`onSizeChange`.",
|
|
260
|
-
"additionalProperties": false
|
|
261
200
|
}
|
|
262
201
|
},
|
|
263
202
|
"additionalProperties": false
|
package/schemas/shell-rail.json
CHANGED
|
@@ -111,44 +111,8 @@
|
|
|
111
111
|
},
|
|
112
112
|
"children": {},
|
|
113
113
|
"open": {
|
|
114
|
-
"description": "The open state, when controlled
|
|
115
|
-
"
|
|
116
|
-
{
|
|
117
|
-
"type": "boolean"
|
|
118
|
-
},
|
|
119
|
-
{
|
|
120
|
-
"anyOf": [
|
|
121
|
-
{
|
|
122
|
-
"type": "boolean"
|
|
123
|
-
},
|
|
124
|
-
{
|
|
125
|
-
"type": "object",
|
|
126
|
-
"properties": {
|
|
127
|
-
"initial": {
|
|
128
|
-
"type": "boolean"
|
|
129
|
-
},
|
|
130
|
-
"xs": {
|
|
131
|
-
"type": "boolean"
|
|
132
|
-
},
|
|
133
|
-
"sm": {
|
|
134
|
-
"type": "boolean"
|
|
135
|
-
},
|
|
136
|
-
"md": {
|
|
137
|
-
"type": "boolean"
|
|
138
|
-
},
|
|
139
|
-
"lg": {
|
|
140
|
-
"type": "boolean"
|
|
141
|
-
},
|
|
142
|
-
"xl": {
|
|
143
|
-
"type": "boolean"
|
|
144
|
-
}
|
|
145
|
-
},
|
|
146
|
-
"additionalProperties": false
|
|
147
|
-
}
|
|
148
|
-
],
|
|
149
|
-
"description": "Responsive open state"
|
|
150
|
-
}
|
|
151
|
-
]
|
|
114
|
+
"description": "The open state, when controlled",
|
|
115
|
+
"type": "boolean"
|
|
152
116
|
},
|
|
153
117
|
"defaultOpen": {
|
|
154
118
|
"description": "The starting state. A responsive object leaves the pane untouched, with that object as the answer at each breakpoint.",
|
|
@@ -158,109 +158,12 @@
|
|
|
158
158
|
"sizeUpdateMs": {
|
|
159
159
|
"type": "number"
|
|
160
160
|
},
|
|
161
|
-
"snapPoints": {
|
|
162
|
-
"description": "Deprecated, removed in 1.0",
|
|
163
|
-
"type": "array",
|
|
164
|
-
"items": {
|
|
165
|
-
"type": "number"
|
|
166
|
-
}
|
|
167
|
-
},
|
|
168
|
-
"snapTolerance": {
|
|
169
|
-
"description": "Deprecated, removed in 1.0",
|
|
170
|
-
"type": "number"
|
|
171
|
-
},
|
|
172
|
-
"collapseThreshold": {
|
|
173
|
-
"description": "Deprecated, removed in 1.0",
|
|
174
|
-
"type": "number"
|
|
175
|
-
},
|
|
176
|
-
"paneId": {
|
|
177
|
-
"description": "Deprecated, removed in 1.0",
|
|
178
|
-
"type": "string"
|
|
179
|
-
},
|
|
180
|
-
"persistence": {
|
|
181
|
-
"type": "object",
|
|
182
|
-
"properties": {},
|
|
183
|
-
"description": "Deprecated, removed in 1.0. Keep the size in your own state with `size`/`onSizeChange`.",
|
|
184
|
-
"additionalProperties": false
|
|
185
|
-
},
|
|
186
161
|
"state": {
|
|
187
|
-
"description": "The state, when controlled
|
|
188
|
-
"
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
"collapsed",
|
|
193
|
-
"expanded"
|
|
194
|
-
],
|
|
195
|
-
"description": "Sidebar state"
|
|
196
|
-
},
|
|
197
|
-
{
|
|
198
|
-
"anyOf": [
|
|
199
|
-
{
|
|
200
|
-
"type": "string",
|
|
201
|
-
"enum": [
|
|
202
|
-
"collapsed",
|
|
203
|
-
"expanded"
|
|
204
|
-
],
|
|
205
|
-
"description": "Sidebar state"
|
|
206
|
-
},
|
|
207
|
-
{
|
|
208
|
-
"type": "object",
|
|
209
|
-
"properties": {
|
|
210
|
-
"initial": {
|
|
211
|
-
"type": "string",
|
|
212
|
-
"enum": [
|
|
213
|
-
"collapsed",
|
|
214
|
-
"expanded"
|
|
215
|
-
],
|
|
216
|
-
"description": "Sidebar state"
|
|
217
|
-
},
|
|
218
|
-
"xs": {
|
|
219
|
-
"type": "string",
|
|
220
|
-
"enum": [
|
|
221
|
-
"collapsed",
|
|
222
|
-
"expanded"
|
|
223
|
-
],
|
|
224
|
-
"description": "Sidebar state"
|
|
225
|
-
},
|
|
226
|
-
"sm": {
|
|
227
|
-
"type": "string",
|
|
228
|
-
"enum": [
|
|
229
|
-
"collapsed",
|
|
230
|
-
"expanded"
|
|
231
|
-
],
|
|
232
|
-
"description": "Sidebar state"
|
|
233
|
-
},
|
|
234
|
-
"md": {
|
|
235
|
-
"type": "string",
|
|
236
|
-
"enum": [
|
|
237
|
-
"collapsed",
|
|
238
|
-
"expanded"
|
|
239
|
-
],
|
|
240
|
-
"description": "Sidebar state"
|
|
241
|
-
},
|
|
242
|
-
"lg": {
|
|
243
|
-
"type": "string",
|
|
244
|
-
"enum": [
|
|
245
|
-
"collapsed",
|
|
246
|
-
"expanded"
|
|
247
|
-
],
|
|
248
|
-
"description": "Sidebar state"
|
|
249
|
-
},
|
|
250
|
-
"xl": {
|
|
251
|
-
"type": "string",
|
|
252
|
-
"enum": [
|
|
253
|
-
"collapsed",
|
|
254
|
-
"expanded"
|
|
255
|
-
],
|
|
256
|
-
"description": "Sidebar state"
|
|
257
|
-
}
|
|
258
|
-
},
|
|
259
|
-
"additionalProperties": false
|
|
260
|
-
}
|
|
261
|
-
],
|
|
262
|
-
"description": "Responsive sidebar state"
|
|
263
|
-
}
|
|
162
|
+
"description": "The state, when controlled",
|
|
163
|
+
"type": "string",
|
|
164
|
+
"enum": [
|
|
165
|
+
"collapsed",
|
|
166
|
+
"expanded"
|
|
264
167
|
]
|
|
265
168
|
},
|
|
266
169
|
"defaultState": {
|
|
@@ -7,7 +7,6 @@
|
|
|
7
7
|
"target": {
|
|
8
8
|
"type": "string",
|
|
9
9
|
"enum": [
|
|
10
|
-
"left",
|
|
11
10
|
"rail",
|
|
12
11
|
"panel",
|
|
13
12
|
"sidebar",
|
|
@@ -26,11 +25,6 @@
|
|
|
26
25
|
"collapse"
|
|
27
26
|
]
|
|
28
27
|
},
|
|
29
|
-
"peekOnHover": {
|
|
30
|
-
"default": false,
|
|
31
|
-
"description": "Deprecated, removed in 1.0. Shows a preview of a closed pane on hover.",
|
|
32
|
-
"type": "boolean"
|
|
33
|
-
},
|
|
34
28
|
"type": {
|
|
35
29
|
"default": "button",
|
|
36
30
|
"description": "The button type",
|
|
@@ -113,3 +113,18 @@
|
|
|
113
113
|
white-space: nowrap;
|
|
114
114
|
border: 0;
|
|
115
115
|
}
|
|
116
|
+
|
|
117
|
+
/* A panel's top row: a Toolbar first in the content holds the title and the Close X. It sits one
|
|
118
|
+
step closer to the panel's edge than the content, stated against the panel's own padding so it
|
|
119
|
+
moves with the size, and the body starts a section's distance under it. Same as a Navigator's
|
|
120
|
+
band. The title takes the free space, so Close goes to the far end. */
|
|
121
|
+
.kui-Toolbar:where(.kui-BaseDialogContent > :first-child) {
|
|
122
|
+
margin-block-start: calc(-1 * var(--layout-space-2));
|
|
123
|
+
margin-inline: calc(-1 * var(--layout-space-2));
|
|
124
|
+
margin-block-end: var(--layout-space-6);
|
|
125
|
+
}
|
|
126
|
+
|
|
127
|
+
.kui-ToolbarTitle:where(.kui-BaseDialogContent > .kui-Toolbar:first-child > *) {
|
|
128
|
+
margin-inline-end: auto;
|
|
129
|
+
min-inline-size: 0;
|
|
130
|
+
}
|
|
@@ -7,14 +7,14 @@ import { PaneResizeContext } from './shell-resize.js';
|
|
|
7
7
|
import { BottomHandle, PaneHandle } from './shell-handles.js';
|
|
8
8
|
import { usePane, paneAttributes, usePresentationTable } from './shell-pane.js';
|
|
9
9
|
import { splitHandles, useInitialPaneSize, useResizablePane, type SizeChangeMeta } from './shell-resizable.js';
|
|
10
|
-
import { useFrameRegistration
|
|
11
|
-
import { bottomAnchoredGrowth, detailRest, toPaneValue
|
|
10
|
+
import { useFrameRegistration } from './shell-store.js';
|
|
11
|
+
import { bottomAnchoredGrowth, detailRest, toPaneValue } from './shell-rest.js';
|
|
12
12
|
import { PageScope } from './page-scope.js';
|
|
13
13
|
import { readBreakpoint } from '../../hooks/use-breakpoint.js';
|
|
14
|
-
import type { Breakpoint, CSSPropertiesWithVars, PaneBaseProps } from '../shell.types.js';
|
|
14
|
+
import type { Breakpoint, CSSPropertiesWithVars, PaneBaseProps, PaneOpenChangeReason } from '../shell.types.js';
|
|
15
15
|
|
|
16
|
-
type BottomOpenChangeMeta = { reason:
|
|
17
|
-
type BottomControlledProps = { open: boolean
|
|
16
|
+
type BottomOpenChangeMeta = { reason: PaneOpenChangeReason };
|
|
17
|
+
type BottomControlledProps = { open: boolean; onOpenChange?: (open: boolean, meta: BottomOpenChangeMeta) => void; defaultOpen?: never };
|
|
18
18
|
/** Since 0.8.0 `defaultOpen` takes a responsive object here too, as the docs already said it did. */
|
|
19
19
|
type BottomUncontrolledProps = { defaultOpen?: boolean | Partial<Record<Breakpoint, boolean>>; onOpenChange?: (open: boolean, meta: BottomOpenChangeMeta) => void; open?: never };
|
|
20
20
|
type BottomSizeControlledProps = { size: number | string; defaultSize?: never };
|
|
@@ -50,16 +50,9 @@ export const Bottom = React.forwardRef<HTMLDivElement, BottomPublicProps>((props
|
|
|
50
50
|
maxSize = 400,
|
|
51
51
|
resizable = false,
|
|
52
52
|
collapsible = true,
|
|
53
|
-
onExpand,
|
|
54
|
-
onCollapse,
|
|
55
53
|
onResize,
|
|
56
54
|
onResizeStart,
|
|
57
55
|
onResizeEnd,
|
|
58
|
-
snapPoints,
|
|
59
|
-
snapTolerance,
|
|
60
|
-
collapseThreshold,
|
|
61
|
-
paneId,
|
|
62
|
-
persistence,
|
|
63
56
|
children,
|
|
64
57
|
style,
|
|
65
58
|
size,
|
|
@@ -83,17 +76,10 @@ export const Bottom = React.forwardRef<HTMLDivElement, BottomPublicProps>((props
|
|
|
83
76
|
presentationTable: table,
|
|
84
77
|
builtIn: detailRest,
|
|
85
78
|
onChange: (value, reason) => onOpenChange?.(value !== 'closed', { reason }),
|
|
86
|
-
onExpand,
|
|
87
|
-
onCollapse,
|
|
88
79
|
size: expandedSize,
|
|
89
80
|
});
|
|
90
81
|
useFrameRegistration('bottom', flush);
|
|
91
82
|
|
|
92
|
-
React.useEffect(() => {
|
|
93
|
-
if (snapPoints !== undefined || collapseThreshold !== undefined || paneId !== undefined || persistence !== undefined) {
|
|
94
|
-
warnOnce('Shell.Bottom: `snapPoints`, `collapseThreshold`, `paneId` and `persistence` are deprecated and are removed in 1.0. Keep the size in your own state with `size`/`onSizeChange`.');
|
|
95
|
-
}
|
|
96
|
-
}, [snapPoints, collapseThreshold, paneId, persistence]);
|
|
97
83
|
|
|
98
84
|
const elementRef = React.useRef<HTMLElement | null>(null);
|
|
99
85
|
const composedRef = useComposedRefs(ref, pane.setElement, elementRef);
|
|
@@ -119,14 +105,8 @@ export const Bottom = React.forwardRef<HTMLDivElement, BottomPublicProps>((props
|
|
|
119
105
|
onResize,
|
|
120
106
|
onResizeStart,
|
|
121
107
|
onResizeEnd,
|
|
122
|
-
snapPoints,
|
|
123
|
-
snapTolerance,
|
|
124
|
-
collapseThreshold,
|
|
125
|
-
paneId,
|
|
126
|
-
persistence,
|
|
127
108
|
overlaying: pane.overlaying,
|
|
128
109
|
overlayingNow: () => table[readBreakpoint()] === 'overlay',
|
|
129
|
-
requestCollapse: () => pane.setValue('closed', 'toggle'),
|
|
130
110
|
requestToggle: () => pane.toggle('toggle'),
|
|
131
111
|
});
|
|
132
112
|
|
|
@@ -137,7 +117,7 @@ export const Bottom = React.forwardRef<HTMLDivElement, BottomPublicProps>((props
|
|
|
137
117
|
|
|
138
118
|
return (
|
|
139
119
|
<div
|
|
140
|
-
{...
|
|
120
|
+
{...domProps}
|
|
141
121
|
id={pane.id}
|
|
142
122
|
ref={composedRef}
|
|
143
123
|
className={classNames('kui-ShellPane', 'kui-ShellBottom', className)}
|
|
@@ -27,12 +27,8 @@ export const PaneHandle = React.forwardRef<HTMLDivElement, React.ComponentPropsW
|
|
|
27
27
|
onResize,
|
|
28
28
|
onResizeStart,
|
|
29
29
|
onResizeEnd,
|
|
30
|
-
snapPoints,
|
|
31
|
-
snapTolerance,
|
|
32
|
-
collapseThreshold,
|
|
33
30
|
collapsible,
|
|
34
31
|
target,
|
|
35
|
-
requestCollapse,
|
|
36
32
|
requestToggle,
|
|
37
33
|
} = usePaneResize();
|
|
38
34
|
|
|
@@ -158,9 +154,6 @@ export const PaneHandle = React.forwardRef<HTMLDivElement, React.ComponentPropsW
|
|
|
158
154
|
onResizeStart?.(startSize);
|
|
159
155
|
|
|
160
156
|
let current = startSize;
|
|
161
|
-
// The unclamped size, so `collapseThreshold` is compared before the
|
|
162
|
-
// clamp: a threshold below `minSize` can then still collapse the pane.
|
|
163
|
-
let raw = startSize;
|
|
164
157
|
let frame = 0;
|
|
165
158
|
let pending: number | null = null;
|
|
166
159
|
const flush = () => {
|
|
@@ -189,8 +182,7 @@ export const PaneHandle = React.forwardRef<HTMLDivElement, React.ComponentPropsW
|
|
|
189
182
|
if (ev === lastHandledMove) return;
|
|
190
183
|
lastHandledMove = ev;
|
|
191
184
|
const client = orientation === 'vertical' ? ev.clientX : ev.clientY;
|
|
192
|
-
|
|
193
|
-
current = clamp(raw);
|
|
185
|
+
current = clamp(startSize + (client - startClient) * sign);
|
|
194
186
|
write(container, current);
|
|
195
187
|
pending = current;
|
|
196
188
|
if (!frame) frame = requestAnimationFrame(flush);
|
|
@@ -232,29 +224,7 @@ export const PaneHandle = React.forwardRef<HTMLDivElement, React.ComponentPropsW
|
|
|
232
224
|
if (frame) cancelAnimationFrame(frame);
|
|
233
225
|
flush();
|
|
234
226
|
|
|
235
|
-
|
|
236
|
-
// A drag past the threshold closes the pane and keeps no size: the
|
|
237
|
-
// pane opens again at the size it had before the drag. The drag
|
|
238
|
-
// still ends, at that size, so a consumer that started something
|
|
239
|
-
// in onResizeStart can stop it.
|
|
240
|
-
write(container, startSize);
|
|
241
|
-
onResize?.(startSize);
|
|
242
|
-
cleanup();
|
|
243
|
-
requestCollapse?.();
|
|
244
|
-
onResizeEnd?.(startSize);
|
|
245
|
-
return;
|
|
246
|
-
}
|
|
247
|
-
|
|
248
|
-
let settled = current;
|
|
249
|
-
if (snapPoints && snapPoints.length) {
|
|
250
|
-
const nearest = snapPoints.reduce((acc, p) => (Math.abs(p - current) < Math.abs(acc - current) ? p : acc), snapPoints[0]);
|
|
251
|
-
if (Math.abs(nearest - current) <= snapTolerance) {
|
|
252
|
-
settled = clamp(nearest);
|
|
253
|
-
write(container, settled);
|
|
254
|
-
onResize?.(settled);
|
|
255
|
-
}
|
|
256
|
-
}
|
|
257
|
-
onResizeEnd?.(settled);
|
|
227
|
+
onResizeEnd?.(current);
|
|
258
228
|
cleanup();
|
|
259
229
|
};
|
|
260
230
|
|
|
@@ -7,14 +7,14 @@ import { PaneResizeContext } from './shell-resize.js';
|
|
|
7
7
|
import { InspectorHandle, PaneHandle } from './shell-handles.js';
|
|
8
8
|
import { usePane, paneAttributes, usePresentationTable } from './shell-pane.js';
|
|
9
9
|
import { splitHandles, useInitialPaneSize, useResizablePane, type SizeChangeMeta } from './shell-resizable.js';
|
|
10
|
-
import { useFrameRegistration
|
|
11
|
-
import { detailRest, endAnchoredGrowth, toPaneValue
|
|
10
|
+
import { useFrameRegistration } from './shell-store.js';
|
|
11
|
+
import { detailRest, endAnchoredGrowth, toPaneValue } from './shell-rest.js';
|
|
12
12
|
import { PageScope } from './page-scope.js';
|
|
13
13
|
import { readBreakpoint } from '../../hooks/use-breakpoint.js';
|
|
14
|
-
import type { Breakpoint, CSSPropertiesWithVars, PaneBaseProps } from '../shell.types.js';
|
|
14
|
+
import type { Breakpoint, CSSPropertiesWithVars, PaneBaseProps, PaneOpenChangeReason } from '../shell.types.js';
|
|
15
15
|
|
|
16
|
-
type InspectorOpenChangeMeta = { reason:
|
|
17
|
-
type InspectorControlledProps = { open: boolean
|
|
16
|
+
type InspectorOpenChangeMeta = { reason: PaneOpenChangeReason };
|
|
17
|
+
type InspectorControlledProps = { open: boolean; onOpenChange?: (open: boolean, meta: InspectorOpenChangeMeta) => void; defaultOpen?: never };
|
|
18
18
|
type InspectorUncontrolledProps = { defaultOpen?: boolean | Partial<Record<Breakpoint, boolean>>; onOpenChange?: (open: boolean, meta: InspectorOpenChangeMeta) => void; open?: never };
|
|
19
19
|
type InspectorSizeControlledProps = { size: number | string; defaultSize?: never };
|
|
20
20
|
type InspectorSizeUncontrolledProps = { defaultSize?: number | string; size?: never };
|
|
@@ -52,16 +52,9 @@ export const Inspector = React.forwardRef<HTMLDivElement, InspectorPublicProps>(
|
|
|
52
52
|
maxSize = 500,
|
|
53
53
|
resizable = false,
|
|
54
54
|
collapsible = true,
|
|
55
|
-
onExpand,
|
|
56
|
-
onCollapse,
|
|
57
55
|
onResize,
|
|
58
56
|
onResizeStart,
|
|
59
57
|
onResizeEnd,
|
|
60
|
-
snapPoints,
|
|
61
|
-
snapTolerance,
|
|
62
|
-
collapseThreshold,
|
|
63
|
-
paneId,
|
|
64
|
-
persistence,
|
|
65
58
|
children,
|
|
66
59
|
style,
|
|
67
60
|
onSizeChange,
|
|
@@ -85,17 +78,10 @@ export const Inspector = React.forwardRef<HTMLDivElement, InspectorPublicProps>(
|
|
|
85
78
|
presentationTable: table,
|
|
86
79
|
builtIn: detailRest,
|
|
87
80
|
onChange: (value, reason) => onOpenChange?.(value !== 'closed', { reason }),
|
|
88
|
-
onExpand,
|
|
89
|
-
onCollapse,
|
|
90
81
|
size: expandedSize,
|
|
91
82
|
});
|
|
92
83
|
useFrameRegistration('inspector', flush);
|
|
93
84
|
|
|
94
|
-
React.useEffect(() => {
|
|
95
|
-
if (snapPoints !== undefined || collapseThreshold !== undefined || paneId !== undefined || persistence !== undefined) {
|
|
96
|
-
warnOnce('Shell.Inspector: `snapPoints`, `collapseThreshold`, `paneId` and `persistence` are deprecated and are removed in 1.0. Keep the size in your own state with `size`/`onSizeChange`.');
|
|
97
|
-
}
|
|
98
|
-
}, [snapPoints, collapseThreshold, paneId, persistence]);
|
|
99
85
|
|
|
100
86
|
const elementRef = React.useRef<HTMLElement | null>(null);
|
|
101
87
|
const composedRef = useComposedRefs(ref, pane.setElement, elementRef);
|
|
@@ -121,14 +107,8 @@ export const Inspector = React.forwardRef<HTMLDivElement, InspectorPublicProps>(
|
|
|
121
107
|
onResize,
|
|
122
108
|
onResizeStart,
|
|
123
109
|
onResizeEnd,
|
|
124
|
-
snapPoints,
|
|
125
|
-
snapTolerance,
|
|
126
|
-
collapseThreshold,
|
|
127
|
-
paneId,
|
|
128
|
-
persistence,
|
|
129
110
|
overlaying: pane.overlaying,
|
|
130
111
|
overlayingNow: () => table[readBreakpoint()] === 'overlay',
|
|
131
|
-
requestCollapse: () => pane.setValue('closed', 'toggle'),
|
|
132
112
|
requestToggle: () => pane.toggle('toggle'),
|
|
133
113
|
});
|
|
134
114
|
|
|
@@ -138,7 +118,7 @@ export const Inspector = React.forwardRef<HTMLDivElement, InspectorPublicProps>(
|
|
|
138
118
|
const initialSize = useInitialPaneSize(size, defaultSize, minSize, maxSize);
|
|
139
119
|
return (
|
|
140
120
|
<div
|
|
141
|
-
{...
|
|
121
|
+
{...domProps}
|
|
142
122
|
role={domProps.role ?? 'complementary'}
|
|
143
123
|
id={pane.id}
|
|
144
124
|
ref={composedRef}
|