react-panel-layout 0.2.0 → 0.4.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/FloatingPanelFrame-BeP9z8EI.js +98 -0
- package/dist/FloatingPanelFrame-BeP9z8EI.js.map +1 -0
- package/dist/FloatingPanelFrame-Cu50Y9xg.cjs +2 -0
- package/dist/FloatingPanelFrame-Cu50Y9xg.cjs.map +1 -0
- package/dist/GridLayout-CwuQEP7k.cjs +2 -0
- package/dist/GridLayout-CwuQEP7k.cjs.map +1 -0
- package/dist/GridLayout-DZCV1X-3.js +1338 -0
- package/dist/GridLayout-DZCV1X-3.js.map +1 -0
- package/dist/components/paneling/FloatingPanelFrame.d.ts +2 -2
- package/dist/components/window/Drawer.d.ts +0 -3
- package/dist/config.cjs +1 -1
- package/dist/config.js +1 -1
- package/dist/constants/styles.d.ts +92 -86
- package/dist/floating.cjs +1 -1
- package/dist/floating.cjs.map +1 -1
- package/dist/floating.js +7 -64
- package/dist/floating.js.map +1 -1
- package/dist/hooks/useTransitionState.d.ts +21 -0
- package/dist/index.cjs +2 -2
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.ts +2 -0
- package/dist/index.js +8 -6
- package/dist/modules/window/useDrawerState.d.ts +3 -2
- package/dist/types.d.ts +21 -0
- package/package.json +2 -1
- package/dist/GridLayout-CmzKfbPP.js +0 -1295
- package/dist/GridLayout-CmzKfbPP.js.map +0 -1
- package/dist/GridLayout-Dx3Qofl0.cjs +0 -2
- package/dist/GridLayout-Dx3Qofl0.cjs.map +0 -1
- package/dist/styles-BMEhL6I0.cjs +0 -2
- package/dist/styles-BMEhL6I0.cjs.map +0 -1
- package/dist/styles-BnvLfp6e.js +0 -49
- package/dist/styles-BnvLfp6e.js.map +0 -1
package/dist/index.d.ts
CHANGED
|
@@ -14,6 +14,8 @@ export type { HorizontalDividerProps } from "./components/resizer/HorizontalDivi
|
|
|
14
14
|
export { ResizeHandle } from "./components/resizer/ResizeHandle";
|
|
15
15
|
export type { ResizeHandleProps } from "./components/resizer/ResizeHandle";
|
|
16
16
|
export { useLayerDragHandle } from "./modules/grid/useLayerDragHandle";
|
|
17
|
+
export { useTransitionState, runTransition } from "./hooks/useTransitionState";
|
|
18
|
+
export type { TransitionMode, TransitionOptions, UseTransitionStateOptions } from "./hooks/useTransitionState";
|
|
17
19
|
export { CSS_VAR_PREFIX } from "./constants/styles";
|
|
18
20
|
export { PanelSystem } from "./modules/panels/system/PanelSystem";
|
|
19
21
|
export { buildInitialState } from "./modules/panels";
|
package/dist/index.js
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import { u as Rt, a as Pt, b as Ct, c as J, d as Dt, e as _, f as At, t as kt, R as nt, G as ot } from "./GridLayout-
|
|
2
|
-
import { D as vr, g as Ir } from "./GridLayout-
|
|
1
|
+
import { u as Rt, a as Pt, b as Ct, c as J, d as Dt, e as _, f as At, t as kt, R as nt, G as ot } from "./GridLayout-DZCV1X-3.js";
|
|
2
|
+
import { D as vr, g as Ir, r as wr, h as yr } from "./GridLayout-DZCV1X-3.js";
|
|
3
3
|
import { jsx as m, jsxs as H, Fragment as et } from "react/jsx-runtime";
|
|
4
4
|
import * as l from "react";
|
|
5
|
-
import {
|
|
6
|
-
import {
|
|
5
|
+
import { m as _t, n as Mt, o as Ot, H as Bt, r as Lt, s as $t, t as Ht, u as Nt, v as zt, w as Xt, T as Yt, x as Ft, y as jt, z as Vt, A as Kt, B as Ut, E as qt, S as Wt } from "./FloatingPanelFrame-BeP9z8EI.js";
|
|
6
|
+
import { I as Gr } from "./FloatingPanelFrame-BeP9z8EI.js";
|
|
7
7
|
const Zt = (t) => ({
|
|
8
8
|
width: Bt,
|
|
9
9
|
cursor: "col-resize",
|
|
@@ -1850,7 +1850,7 @@ const fe = (t, e) => {
|
|
|
1850
1850
|
);
|
|
1851
1851
|
};
|
|
1852
1852
|
export {
|
|
1853
|
-
|
|
1853
|
+
Gr as CSS_VAR_PREFIX,
|
|
1854
1854
|
vr as Drawer,
|
|
1855
1855
|
Ir as DrawerLayers,
|
|
1856
1856
|
ot as GridLayout,
|
|
@@ -1858,6 +1858,8 @@ export {
|
|
|
1858
1858
|
gr as PanelSystem,
|
|
1859
1859
|
nt as ResizeHandle,
|
|
1860
1860
|
br as buildInitialState,
|
|
1861
|
-
|
|
1861
|
+
wr as runTransition,
|
|
1862
|
+
fr as useLayerDragHandle,
|
|
1863
|
+
yr as useTransitionState
|
|
1862
1864
|
};
|
|
1863
1865
|
//# sourceMappingURL=index.js.map
|
|
@@ -1,6 +1,7 @@
|
|
|
1
|
+
import { type TransitionOptions } from "../../hooks/useTransitionState";
|
|
1
2
|
import type { LayerDefinition } from "../../types";
|
|
2
3
|
export declare const useDrawerState: (layers: LayerDefinition[]) => {
|
|
3
4
|
state: (layerId: string) => boolean;
|
|
4
|
-
open: (
|
|
5
|
-
close: (
|
|
5
|
+
open: (id: string, options?: TransitionOptions) => Promise<void>;
|
|
6
|
+
close: (id: string, options?: TransitionOptions) => Promise<void>;
|
|
6
7
|
};
|
package/dist/types.d.ts
CHANGED
|
@@ -64,7 +64,28 @@ export type DrawerBehavior = {
|
|
|
64
64
|
open?: boolean;
|
|
65
65
|
/** Whether clicking backdrop dismisses the drawer */
|
|
66
66
|
dismissible?: boolean;
|
|
67
|
+
/**
|
|
68
|
+
* Transition mode for drawer visibility.
|
|
69
|
+
* - "css" (default) uses CSS transform transitions.
|
|
70
|
+
* - "none" disables transitions.
|
|
71
|
+
*/
|
|
72
|
+
transitionMode?: "css" | "none";
|
|
73
|
+
/** Override transform transition duration (e.g., "240ms"). */
|
|
74
|
+
transitionDuration?: string;
|
|
75
|
+
/** Override transform transition easing (e.g., "cubic-bezier(0.22,1,0.36,1)"). */
|
|
76
|
+
transitionEasing?: string;
|
|
67
77
|
onStateChange?: (open: boolean) => void;
|
|
78
|
+
/** Use the built-in chrome (background, header padding). Defaults to true. */
|
|
79
|
+
chrome?: boolean;
|
|
80
|
+
/**
|
|
81
|
+
* Render the drawer relative to its parent container instead of the viewport.
|
|
82
|
+
* Defaults to false (fixed to viewport).
|
|
83
|
+
*/
|
|
84
|
+
inline?: boolean;
|
|
85
|
+
/**
|
|
86
|
+
* Accessible label when header.title is not provided or when rendering without a header.
|
|
87
|
+
*/
|
|
88
|
+
ariaLabel?: string;
|
|
68
89
|
header?: {
|
|
69
90
|
title?: string;
|
|
70
91
|
showCloseButton?: boolean;
|