You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
|[`boundsPadding`](https://react-compare-slider.vercel.app/?path=/story/demos--bounds-padding)|`number`||`0`| Padding to limit the slideable bounds in pixels on the X-axis (landscape) or Y-axis (portrait).|
71
-
|[`changePositionOnHover`](https://react-compare-slider.vercel.app/?path=/story/demos--change-position-on-hover)|`boolean`||`false`| Whether the slider should follow the pointer on hover.|
72
-
|[`disabled`](https://react-compare-slider.vercel.app/?path=/story/demos--disabled)|`boolean`||`false`|Whether to disable slider movement (items are still interactable). |
|`itemOne`|`ReactNode`| ✓ |`undefined`|First component to show in slider. |
75
-
|`itemTwo`|`ReactNode`|✓|`undefined`|Second component to show in slider.|
76
-
|[`keyboardIncrement`](https://react-compare-slider.vercel.app/?path=/story/demos--keyboard-increment)|`` number\|`${number}%` ``||`5%`| Percentage or pixel amount to move when the slider handle is focused and keyboard arrow is pressed. |
77
-
|[`onlyHandleDraggable`](https://react-compare-slider.vercel.app/?path=/story/demos--only-handle-draggable)|`boolean`||`false`| Whether to only change position when handle is interacted with (useful for touch devices). |
78
-
|[`onPositionChange`](https://react-compare-slider.vercel.app/?path=/story/demos--on-position-change)|`function`||`undefined`| Callback on position change, returns current position percentage as argument `(position) => { ... }`. |
79
-
|[`portrait`](https://react-compare-slider.vercel.app/?path=/story/demos--portrait)|`boolean`||`false`| Whether to use portrait orientation. |
80
-
|[`position`](https://react-compare-slider.vercel.app/?path=/story/demos--position)|`number`||`50`| Initial percentage position of divide (`0-100`).|
81
-
|[`transition`](https://react-compare-slider.vercel.app/?path=/story/demos--transition)|`string`||`undefined`| Shorthand CSS `transition` property to apply to handle movement. E.g. `.5s ease-in-out`|
82
-
|[`browsingContext`](https://react-compare-slider.vercel.app/?path=/story/demos--browsing-context)|`Window`||`undefined`| Custom browsing context to use instead of the global `window` object when listening for pointer events. |
70
+
| [`boundsPadding`](https://react-compare-slider.vercel.app/?path=/story/demos--bounds-padding) | `number` | | `0` | Padding to limit the slideable bounds in pixels on the X-axis (landscape) or Y-axis (portrait).
71
+
| `browsingContext` | `globalThis` | | `globalThis` | Context to bind events to (useful for iframes).
72
+
| [`changePositionOnHover`](https://react-compare-slider.vercel.app/?path=/story/demos--change-position-on-hover) | `boolean`| | `false`| Whether the slider should follow the pointer on hover.
73
+
| [`disabled`](https://react-compare-slider.vercel.app/?path=/story/demos--disabled) | `boolean` | | `false`| Whether to disable slider movement (items are still interactable).
| `itemOne` | `ReactNode` | ✓ | `undefined` | First component to show in slider.
76
+
| `itemTwo`| `ReactNode`| ✓ | `undefined`| Second component to show in slider.
77
+
| [`keyboardIncrement`](https://react-compare-slider.vercel.app/?path=/story/demos--keyboard-increment) | `` number\|`${number}%` ``| | `5%` | Percentage or pixel amount to move when the slider handle is focused and keyboard arrow is pressed.
78
+
| [`onlyHandleDraggable`](https://react-compare-slider.vercel.app/?path=/story/demos--only-handle-draggable)| `boolean`| | `false` | Whether to only change position when handle is interacted with (useful for touch devices).
79
+
| [`onPositionChange`](https://react-compare-slider.vercel.app/?path=/story/demos--on-position-change) | `(position: number) => void`| | `undefined`| Callback on position change, returns current position percentage as argument.
80
+
| [`portrait`](https://react-compare-slider.vercel.app/?path=/story/demos--portrait) | `boolean` || `false`| Whether to use portrait orientation.
81
+
| [`position`](https://react-compare-slider.vercel.app/?path=/story/demos--position) | `number` || `50` | Initial percentage position of divide (`0-100`).
82
+
| [`transition`](https://react-compare-slider.vercel.app/?path=/story/demos--transition)| `string` | | `undefined` | Shorthand CSS `transition` property to apply to handle movement. E.g. `.5s ease-in-out`
83
83
84
84
[API docs](https://react-compare-slider.vercel.app/?path=/docs/docs-api--docs) for more information.
0 commit comments