react-resizable-panels 4.5.0 → 4.5.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.
@@ -23,7 +23,7 @@ declare type BaseSeparatorAttributes = Omit<HTMLAttributes<HTMLDivElement>, "rol
23
23
  *
24
24
  * ℹ️ [Test id](https://testing-library.com/docs/queries/bytestid/) can be used to narrow selection when unit testing.
25
25
  */
26
- export declare function Group({ children, className, defaultLayout, disableCursor, disabled, elementRef: elementRefProp, groupRef, id: idProp, onLayoutChange: onLayoutChangeUnstable, onLayoutChanged: onLayoutChangedUnstable, orientation, style, ...rest }: GroupProps): JSX.Element;
26
+ export declare function Group({ children, className, defaultLayout, disableCursor, disabled, elementRef: elementRefProp, groupRef, id: idProp, onLayoutChange: onLayoutChangeUnstable, onLayoutChanged: onLayoutChangedUnstable, orientation, resizeTargetMinimumSize, style, ...rest }: GroupProps): JSX.Element;
27
27
 
28
28
  export declare namespace Group {
29
29
  var displayName: string;
@@ -113,6 +113,21 @@ export declare type GroupProps = HTMLAttributes<HTMLDivElement> & {
113
113
  * This method is recommended when saving layouts to some storage api.
114
114
  */
115
115
  onLayoutChanged?: (layout: Layout) => void | undefined;
116
+ /**
117
+ * Minimum size of the resizable hit target area (either `Separator` or `Panel` edge)
118
+ * This threshold ensures are large enough to avoid mis-clicks.
119
+ *
120
+ * - Coarse inputs (typically a finger on a touchscreen) have reduced accuracy;
121
+ * to ensure accessibility and ease of use, hit targets should be larger to prevent mis-clicks.
122
+ * - Fine inputs (typically a mouse) can be smaller
123
+ *
124
+ * ℹ️ [Apple interface guidelines](https://developer.apple.com/design/human-interface-guidelines/accessibility) suggest `20pt` (`27px`) on desktops and `28pt` (`37px`) for touch devices
125
+ * In practice this seems to be much larger than many of their own applications use though.
126
+ */
127
+ resizeTargetMinimumSize?: {
128
+ coarse: number;
129
+ fine: number;
130
+ };
116
131
  /**
117
132
  * Specifies the resizable orientation ("horizontal" or "vertical"); defaults to "horizontal"
118
133
  */