react-resizable-panels 4.0.0-alpha.1 → 4.0.0-alpha.2
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.
|
@@ -11,11 +11,13 @@ import { SetStateAction } from 'react';
|
|
|
11
11
|
* A Group wraps a set of resizable Panel components.
|
|
12
12
|
* Group content can be resized _horizontally_ or _vertically_.
|
|
13
13
|
*
|
|
14
|
-
*
|
|
14
|
+
* Group elements always include the following data attributes:
|
|
15
15
|
*
|
|
16
16
|
* ```html
|
|
17
|
-
* <div data-group="your-group-id">
|
|
17
|
+
* <div data-group data-testid="your-group-id">
|
|
18
18
|
* ```
|
|
19
|
+
*
|
|
20
|
+
* ℹ️ [Test id](https://testing-library.com/docs/queries/bytestid/) can be used to narrow selection when unit testing.
|
|
19
21
|
*/
|
|
20
22
|
export declare function Group({ children, className, defaultLayout, disableCursor, disabled, elementRef, groupRef, id: idProp, onLayoutChange: onLayoutChangeUnstable, orientation, style }: GroupProps): JSX.Element;
|
|
21
23
|
|
|
@@ -133,11 +135,13 @@ export declare type Orientation = "horizontal" | "vertical";
|
|
|
133
135
|
* - Font sizes (em, rem)
|
|
134
136
|
* - Viewport sizes (vh, vw)
|
|
135
137
|
*
|
|
136
|
-
*
|
|
138
|
+
* Panel elements always include the following data attributes:
|
|
137
139
|
*
|
|
138
140
|
* ```html
|
|
139
|
-
* <div data-panel="your-panel-id">
|
|
141
|
+
* <div data-panel data-testid="your-panel-id">
|
|
140
142
|
* ```
|
|
143
|
+
*
|
|
144
|
+
* ℹ️ [Test id](https://testing-library.com/docs/queries/bytestid/) can be used to narrow selection when unit testing.
|
|
141
145
|
*/
|
|
142
146
|
export declare function Panel({ children, className, collapsedSize, collapsible, defaultSize, elementRef, id: idProp, maxSize, minSize, onResize: onResizeUnstable, panelRef, style }: PanelProps): JSX.Element;
|
|
143
147
|
|
|
@@ -256,11 +260,13 @@ export declare type PanelSize = {
|
|
|
256
260
|
*
|
|
257
261
|
* Separators should be rendered as the direct child of a Group component.
|
|
258
262
|
*
|
|
259
|
-
*
|
|
263
|
+
* Separator elements always include the following data attributes and role:
|
|
260
264
|
*
|
|
261
265
|
* ```html
|
|
262
|
-
* <div data-separator="your-separator-id" role="separator" />
|
|
266
|
+
* <div data-separator data-testid="your-separator-id" role="separator" />
|
|
263
267
|
* ```
|
|
268
|
+
*
|
|
269
|
+
* ℹ️ [Test id](https://testing-library.com/docs/queries/bytestid/) can be used to narrow selection when unit testing.
|
|
264
270
|
*/
|
|
265
271
|
export declare function Separator({ children, className, elementRef, id: idProp, style }: SeparatorProps): JSX.Element;
|
|
266
272
|
|
|
@@ -268,7 +274,7 @@ export declare type SeparatorProps = PropsWithChildren<{
|
|
|
268
274
|
/**
|
|
269
275
|
* CSS class name.
|
|
270
276
|
*
|
|
271
|
-
* ℹ️ Use the `data-separator
|
|
277
|
+
* ℹ️ Use the `data-separator` attribute for custom _hover_ and _active_ styles
|
|
272
278
|
*
|
|
273
279
|
* ⚠️ The following properties cannot be overridden: `flex-grow`, `flex-shrink`
|
|
274
280
|
*/
|
|
@@ -287,7 +293,7 @@ export declare type SeparatorProps = PropsWithChildren<{
|
|
|
287
293
|
/**
|
|
288
294
|
* CSS properties.
|
|
289
295
|
*
|
|
290
|
-
* ℹ️ Use the `data-separator
|
|
296
|
+
* ℹ️ Use the `data-separator` attribute for custom _hover_ and _active_ styles
|
|
291
297
|
*
|
|
292
298
|
* ⚠️ The following properties cannot be overridden: `flex-grow`, `flex-shrink`
|
|
293
299
|
*/
|