@mirohq/design-system-scroll-area 0.1.0-dropdown.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/dist/main.js +81 -0
- package/dist/main.js.map +1 -0
- package/dist/module.js +73 -0
- package/dist/module.js.map +1 -0
- package/dist/types.d.ts +2287 -0
- package/package.json +37 -0
package/dist/main.js
ADDED
|
@@ -0,0 +1,81 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
|
+
|
|
5
|
+
var React = require('react');
|
|
6
|
+
var reactScrollArea = require('@radix-ui/react-scroll-area');
|
|
7
|
+
var designSystemStitches = require('@mirohq/design-system-stitches');
|
|
8
|
+
|
|
9
|
+
function _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'default' in e ? e : { 'default': e }; }
|
|
10
|
+
|
|
11
|
+
var React__default = /*#__PURE__*/_interopDefaultLegacy(React);
|
|
12
|
+
|
|
13
|
+
const StyledViewport = designSystemStitches.styled(reactScrollArea.Viewport);
|
|
14
|
+
const Viewport = React__default["default"].forwardRef((props, forwardRef) => /* @__PURE__ */ React__default["default"].createElement(StyledViewport, {
|
|
15
|
+
...props,
|
|
16
|
+
ref: forwardRef
|
|
17
|
+
}));
|
|
18
|
+
|
|
19
|
+
const StyledScrollbar = designSystemStitches.styled(reactScrollArea.Scrollbar, {
|
|
20
|
+
display: "flex",
|
|
21
|
+
userSelect: "none",
|
|
22
|
+
touchAction: "none",
|
|
23
|
+
background: "transparent",
|
|
24
|
+
transition: "background 160ms ease-out",
|
|
25
|
+
'&[data-orientation="vertical"]': { width: "$1", minHeight: "$2" },
|
|
26
|
+
'&[data-orientation="horizontal"]': {
|
|
27
|
+
flexDirection: "column",
|
|
28
|
+
height: "$1"
|
|
29
|
+
}
|
|
30
|
+
});
|
|
31
|
+
|
|
32
|
+
const Scrollbar = React__default["default"].forwardRef((props, forwardRef) => /* @__PURE__ */ React__default["default"].createElement(StyledScrollbar, {
|
|
33
|
+
...props,
|
|
34
|
+
ref: forwardRef
|
|
35
|
+
}));
|
|
36
|
+
|
|
37
|
+
const StyledThumb = designSystemStitches.styled(reactScrollArea.Thumb, {
|
|
38
|
+
flex: 1,
|
|
39
|
+
background: "$background-neutrals-scrolls",
|
|
40
|
+
borderRadius: "$50",
|
|
41
|
+
position: "relative",
|
|
42
|
+
"&::before": {
|
|
43
|
+
content: '""',
|
|
44
|
+
position: "absolute",
|
|
45
|
+
top: "50%",
|
|
46
|
+
left: "50%",
|
|
47
|
+
transform: "translate(-50%, -50%)",
|
|
48
|
+
width: "100%",
|
|
49
|
+
height: "100%",
|
|
50
|
+
minWidth: "$6",
|
|
51
|
+
minHeight: "$6"
|
|
52
|
+
},
|
|
53
|
+
"&:hover": {
|
|
54
|
+
backgroundColor: "$background-neutrals-scrolls-hover"
|
|
55
|
+
}
|
|
56
|
+
});
|
|
57
|
+
|
|
58
|
+
const Thumb = React__default["default"].forwardRef((props, forwardRef) => /* @__PURE__ */ React__default["default"].createElement(StyledThumb, {
|
|
59
|
+
...props,
|
|
60
|
+
ref: forwardRef
|
|
61
|
+
}));
|
|
62
|
+
|
|
63
|
+
const StyledCorner = designSystemStitches.styled(reactScrollArea.Corner);
|
|
64
|
+
const Corner = React__default["default"].forwardRef((props, forwardRef) => /* @__PURE__ */ React__default["default"].createElement(StyledCorner, {
|
|
65
|
+
...props,
|
|
66
|
+
ref: forwardRef
|
|
67
|
+
}));
|
|
68
|
+
|
|
69
|
+
const StyledScrollArea = designSystemStitches.styled(reactScrollArea.Root);
|
|
70
|
+
|
|
71
|
+
const ScrollArea = React__default["default"].forwardRef((props, forwardRef) => /* @__PURE__ */ React__default["default"].createElement(StyledScrollArea, {
|
|
72
|
+
...props,
|
|
73
|
+
ref: forwardRef
|
|
74
|
+
}));
|
|
75
|
+
ScrollArea.Viewport = Viewport;
|
|
76
|
+
ScrollArea.Scrollbar = Scrollbar;
|
|
77
|
+
ScrollArea.Thumb = Thumb;
|
|
78
|
+
ScrollArea.Corner = Corner;
|
|
79
|
+
|
|
80
|
+
exports.ScrollArea = ScrollArea;
|
|
81
|
+
//# sourceMappingURL=main.js.map
|
package/dist/main.js.map
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"main.js","sources":["../src/partials/viewport.tsx","../src/partials/scrollbar.styled.tsx","../src/partials/scrollbar.tsx","../src/partials/thumb.styled.tsx","../src/partials/thumb.tsx","../src/partials/corner.tsx","../src/scroll-area.styled.tsx","../src/scroll-area.tsx"],"sourcesContent":["import React from 'react'\nimport { Viewport as RadixViewport } from '@radix-ui/react-scroll-area'\nimport { styled } from '@mirohq/design-system-stitches'\nimport type { ElementRef } from 'react'\nimport type { StrictComponentProps } from '@mirohq/design-system-stitches'\n\nconst StyledViewport = styled(RadixViewport)\ntype StyledViewportProps = StrictComponentProps<typeof StyledViewport>\n\nexport interface ViewportProps extends StyledViewportProps {}\n\nexport const Viewport = React.forwardRef<\n ElementRef<typeof StyledViewport>,\n ViewportProps\n>((props, forwardRef) => <StyledViewport {...props} ref={forwardRef} />)\n","import { styled } from '@mirohq/design-system-stitches'\nimport { Scrollbar as RadixScrollbar } from '@radix-ui/react-scroll-area'\nimport type { StrictComponentProps } from '@mirohq/design-system-stitches'\n\nexport const StyledScrollbar = styled(RadixScrollbar, {\n display: 'flex',\n // ensures no selection\n userSelect: 'none',\n // disable browser handling of all panning and zooming gestures on touch devices\n touchAction: 'none',\n background: 'transparent',\n transition: 'background 160ms ease-out',\n '&[data-orientation=\"vertical\"]': { width: '$1', minHeight: '$2' },\n '&[data-orientation=\"horizontal\"]': {\n flexDirection: 'column',\n height: '$1',\n },\n})\n\nexport type StyledScrollbarProps = StrictComponentProps<typeof StyledScrollbar>\n","import type { ElementRef } from 'react'\nimport React from 'react'\n\nimport { StyledScrollbar } from './scrollbar.styled'\nimport type { StyledScrollbarProps } from './scrollbar.styled'\n\nexport interface ScrollbarProps extends StyledScrollbarProps {\n /**\n * Used to force mounting when more control is needed. Useful when controlling\n * animation with React animation libraries.\n */\n forceMount?: true\n\n /**\n * The orientation of the scrollbar.\n */\n orientation?: 'horizontal' | 'vertical'\n}\n\nexport const Scrollbar = React.forwardRef<\n ElementRef<typeof StyledScrollbar>,\n ScrollbarProps\n>((props, forwardRef) => <StyledScrollbar {...props} ref={forwardRef} />)\n","import { styled } from '@mirohq/design-system-stitches'\nimport { Thumb as RadixThumb } from '@radix-ui/react-scroll-area'\nimport type { StrictComponentProps } from '@mirohq/design-system-stitches'\n\nexport const StyledThumb = styled(RadixThumb, {\n flex: 1,\n background: '$background-neutrals-scrolls',\n borderRadius: '$50',\n position: 'relative',\n '&::before': {\n content: '\"\"',\n position: 'absolute',\n top: '50%',\n left: '50%',\n transform: 'translate(-50%, -50%)',\n width: '100%',\n height: '100%',\n minWidth: '$6',\n minHeight: '$6',\n },\n '&:hover': {\n backgroundColor: '$background-neutrals-scrolls-hover',\n },\n})\nexport type StyledThumbProps = StrictComponentProps<typeof StyledThumb>\n","import React from 'react'\nimport type { ElementRef } from 'react'\n\nimport { StyledThumb } from './thumb.styled'\nimport type { StyledThumbProps } from './thumb.styled'\n\nexport interface ThumbProps extends StyledThumbProps {\n /**\n * Used to force mounting when more control is needed. Useful when\n * controlling animation with React animation libraries.\n */\n forceMount?: true\n}\n\nexport const Thumb = React.forwardRef<\n ElementRef<typeof StyledThumb>,\n ThumbProps\n>((props, forwardRef) => <StyledThumb {...props} ref={forwardRef} />)\n","import React from 'react'\nimport { Corner as RadixCorner } from '@radix-ui/react-scroll-area'\nimport { styled } from '@mirohq/design-system-stitches'\nimport type { StrictComponentProps } from '@mirohq/design-system-stitches'\nimport type { ElementRef } from 'react'\n\nconst StyledCorner = styled(RadixCorner)\ntype StyledCornerProps = StrictComponentProps<typeof StyledCorner>\n\nexport interface CornerProps extends StyledCornerProps {}\n\nexport const Corner = React.forwardRef<\n ElementRef<typeof StyledCorner>,\n CornerProps\n>((props, forwardRef) => <StyledCorner {...props} ref={forwardRef} />)\n","import { styled } from '@mirohq/design-system-stitches'\nimport { Root as RadixScrollArea } from '@radix-ui/react-scroll-area'\nimport type { StrictComponentProps } from '@mirohq/design-system-stitches'\n\nexport const StyledScrollArea = styled(RadixScrollArea)\nexport type StyledScrollAreaProps = StrictComponentProps<\n typeof StyledScrollArea\n>\n","import React from 'react'\nimport type { ElementRef, ForwardRefExoticComponent } from 'react'\n\nimport { Viewport } from './partials/viewport'\nimport { Scrollbar } from './partials/scrollbar'\nimport { Thumb } from './partials/thumb'\nimport { Corner } from './partials/corner'\nimport { StyledScrollArea } from './scroll-area.styled'\nimport type { StyledScrollAreaProps } from './scroll-area.styled'\n\nexport interface ScrollAreaProps extends StyledScrollAreaProps {\n children: React.ReactNode\n\n /**\n * Describes the nature of scrollbar visibility, similar to how the scrollbar preferences in MacOS control visibility of native scrollbars.\n \"auto\" means that scrollbars are visible when content is overflowing on the corresponding orientation.\n \"always\" means that scrollbars are always visible regardless of whether the content is overflowing.\n \"scroll\" means that scrollbars are visible when the user is scrolling along its corresponding orientation.\n \"hover\" when the user is scrolling along its corresponding orientation and when the user is hovering over the scroll area.\n */\n type?: 'auto' | 'always' | 'scroll' | 'hover'\n\n /**\n * The reading direction of the scroll area. If omitted, inherits globally\n * from DirectionProvider or assumes LTR (left-to-right) reading mode.\n */\n dir?: 'ltr' | 'rtl'\n\n /**\n * If type is set to either \"scroll\" or \"hover\", this prop determines the\n * length of time, in milliseconds, before the scrollbars are hidden after the\n * user stops interacting with scrollbars.\n */\n scrollHideDelay?: number\n}\n\nexport const ScrollArea = React.forwardRef<\n ElementRef<typeof StyledScrollArea>,\n ScrollAreaProps\n>((props, forwardRef) => (\n <StyledScrollArea {...props} ref={forwardRef} />\n)) as ForwardRefExoticComponent<ScrollAreaProps> & Partials\n\ninterface Partials {\n Viewport: typeof Viewport\n Scrollbar: typeof Scrollbar\n Thumb: typeof Thumb\n Corner: typeof Corner\n}\n\nScrollArea.Viewport = Viewport\nScrollArea.Scrollbar = Scrollbar\nScrollArea.Thumb = Thumb\nScrollArea.Corner = Corner\n"],"names":["styled","RadixViewport","React","RadixScrollbar","RadixThumb","RadixCorner","RadixScrollArea"],"mappings":";;;;;;;;;;;;AAMA,MAAM,cAAA,GAAiBA,4BAAOC,wBAAa,CAAA,CAAA;AAKpC,MAAM,WAAWC,yBAAM,CAAA,UAAA,CAG5B,CAAC,KAAA,EAAO,+BAAgBA,yBAAA,CAAA,aAAA,CAAA,cAAA,EAAA;AAAA,EAAgB,GAAG,KAAA;AAAA,EAAO,GAAK,EAAA,UAAA;AAAA,CAAY,CAAE,CAAA;;ACV1D,MAAA,eAAA,GAAkBF,4BAAOG,yBAAgB,EAAA;AAAA,EACpD,OAAS,EAAA,MAAA;AAAA,EAET,UAAY,EAAA,MAAA;AAAA,EAEZ,WAAa,EAAA,MAAA;AAAA,EACb,UAAY,EAAA,aAAA;AAAA,EACZ,UAAY,EAAA,2BAAA;AAAA,EACZ,gCAAkC,EAAA,EAAE,KAAO,EAAA,IAAA,EAAM,WAAW,IAAK,EAAA;AAAA,EACjE,kCAAoC,EAAA;AAAA,IAClC,aAAe,EAAA,QAAA;AAAA,IACf,MAAQ,EAAA,IAAA;AAAA,GACV;AACF,CAAC,CAAA;;ACEM,MAAM,YAAYD,yBAAM,CAAA,UAAA,CAG7B,CAAC,KAAA,EAAO,+BAAgBA,yBAAA,CAAA,aAAA,CAAA,eAAA,EAAA;AAAA,EAAiB,GAAG,KAAA;AAAA,EAAO,GAAK,EAAA,UAAA;AAAA,CAAY,CAAE,CAAA;;AClB3D,MAAA,WAAA,GAAcF,4BAAOI,qBAAY,EAAA;AAAA,EAC5C,IAAM,EAAA,CAAA;AAAA,EACN,UAAY,EAAA,8BAAA;AAAA,EACZ,YAAc,EAAA,KAAA;AAAA,EACd,QAAU,EAAA,UAAA;AAAA,EACV,WAAa,EAAA;AAAA,IACX,OAAS,EAAA,IAAA;AAAA,IACT,QAAU,EAAA,UAAA;AAAA,I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$1, Scrollbar as Scrollbar$1, Thumb as Thumb$1, Corner as Corner$1, Root } from '@radix-ui/react-scroll-area';
|
|
3
|
+
import { styled } from '@mirohq/design-system-stitches';
|
|
4
|
+
|
|
5
|
+
const StyledViewport = styled(Viewport$1);
|
|
6
|
+
const Viewport = React.forwardRef((props, forwardRef) => /* @__PURE__ */ React.createElement(StyledViewport, {
|
|
7
|
+
...props,
|
|
8
|
+
ref: forwardRef
|
|
9
|
+
}));
|
|
10
|
+
|
|
11
|
+
const StyledScrollbar = styled(Scrollbar$1, {
|
|
12
|
+
display: "flex",
|
|
13
|
+
userSelect: "none",
|
|
14
|
+
touchAction: "none",
|
|
15
|
+
background: "transparent",
|
|
16
|
+
transition: "background 160ms ease-out",
|
|
17
|
+
'&[data-orientation="vertical"]': { width: "$1", minHeight: "$2" },
|
|
18
|
+
'&[data-orientation="horizontal"]': {
|
|
19
|
+
flexDirection: "column",
|
|
20
|
+
height: "$1"
|
|
21
|
+
}
|
|
22
|
+
});
|
|
23
|
+
|
|
24
|
+
const Scrollbar = React.forwardRef((props, forwardRef) => /* @__PURE__ */ React.createElement(StyledScrollbar, {
|
|
25
|
+
...props,
|
|
26
|
+
ref: forwardRef
|
|
27
|
+
}));
|
|
28
|
+
|
|
29
|
+
const StyledThumb = styled(Thumb$1, {
|
|
30
|
+
flex: 1,
|
|
31
|
+
background: "$background-neutrals-scrolls",
|
|
32
|
+
borderRadius: "$50",
|
|
33
|
+
position: "relative",
|
|
34
|
+
"&::before": {
|
|
35
|
+
content: '""',
|
|
36
|
+
position: "absolute",
|
|
37
|
+
top: "50%",
|
|
38
|
+
left: "50%",
|
|
39
|
+
transform: "translate(-50%, -50%)",
|
|
40
|
+
width: "100%",
|
|
41
|
+
height: "100%",
|
|
42
|
+
minWidth: "$6",
|
|
43
|
+
minHeight: "$6"
|
|
44
|
+
},
|
|
45
|
+
"&:hover": {
|
|
46
|
+
backgroundColor: "$background-neutrals-scrolls-hover"
|
|
47
|
+
}
|
|
48
|
+
});
|
|
49
|
+
|
|
50
|
+
const Thumb = React.forwardRef((props, forwardRef) => /* @__PURE__ */ React.createElement(StyledThumb, {
|
|
51
|
+
...props,
|
|
52
|
+
ref: forwardRef
|
|
53
|
+
}));
|
|
54
|
+
|
|
55
|
+
const StyledCorner = styled(Corner$1);
|
|
56
|
+
const Corner = React.forwardRef((props, forwardRef) => /* @__PURE__ */ React.createElement(StyledCorner, {
|
|
57
|
+
...props,
|
|
58
|
+
ref: forwardRef
|
|
59
|
+
}));
|
|
60
|
+
|
|
61
|
+
const StyledScrollArea = styled(Root);
|
|
62
|
+
|
|
63
|
+
const ScrollArea = React.forwardRef((props, forwardRef) => /* @__PURE__ */ React.createElement(StyledScrollArea, {
|
|
64
|
+
...props,
|
|
65
|
+
ref: forwardRef
|
|
66
|
+
}));
|
|
67
|
+
ScrollArea.Viewport = Viewport;
|
|
68
|
+
ScrollArea.Scrollbar = Scrollbar;
|
|
69
|
+
ScrollArea.Thumb = Thumb;
|
|
70
|
+
ScrollArea.Corner = Corner;
|
|
71
|
+
|
|
72
|
+
export { ScrollArea };
|
|
73
|
+
//# sourceMappingURL=module.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"module.js","sources":["../src/partials/viewport.tsx","../src/partials/scrollbar.styled.tsx","../src/partials/scrollbar.tsx","../src/partials/thumb.styled.tsx","../src/partials/thumb.tsx","../src/partials/corner.tsx","../src/scroll-area.styled.tsx","../src/scroll-area.tsx"],"sourcesContent":["import React from 'react'\nimport { Viewport as RadixViewport } from '@radix-ui/react-scroll-area'\nimport { styled } from '@mirohq/design-system-stitches'\nimport type { ElementRef } from 'react'\nimport type { StrictComponentProps } from '@mirohq/design-system-stitches'\n\nconst StyledViewport = styled(RadixViewport)\ntype StyledViewportProps = StrictComponentProps<typeof StyledViewport>\n\nexport interface ViewportProps extends StyledViewportProps {}\n\nexport const Viewport = React.forwardRef<\n ElementRef<typeof StyledViewport>,\n ViewportProps\n>((props, forwardRef) => <StyledViewport {...props} ref={forwardRef} />)\n","import { styled } from '@mirohq/design-system-stitches'\nimport { Scrollbar as RadixScrollbar } from '@radix-ui/react-scroll-area'\nimport type { StrictComponentProps } from '@mirohq/design-system-stitches'\n\nexport const StyledScrollbar = styled(RadixScrollbar, {\n display: 'flex',\n // ensures no selection\n userSelect: 'none',\n // disable browser handling of all panning and zooming gestures on touch devices\n touchAction: 'none',\n background: 'transparent',\n transition: 'background 160ms ease-out',\n '&[data-orientation=\"vertical\"]': { width: '$1', minHeight: '$2' },\n '&[data-orientation=\"horizontal\"]': {\n flexDirection: 'column',\n height: '$1',\n },\n})\n\nexport type StyledScrollbarProps = StrictComponentProps<typeof StyledScrollbar>\n","import type { ElementRef } from 'react'\nimport React from 'react'\n\nimport { StyledScrollbar } from './scrollbar.styled'\nimport type { StyledScrollbarProps } from './scrollbar.styled'\n\nexport interface ScrollbarProps extends StyledScrollbarProps {\n /**\n * Used to force mounting when more control is needed. Useful when controlling\n * animation with React animation libraries.\n */\n forceMount?: true\n\n /**\n * The orientation of the scrollbar.\n */\n orientation?: 'horizontal' | 'vertical'\n}\n\nexport const Scrollbar = React.forwardRef<\n ElementRef<typeof StyledScrollbar>,\n ScrollbarProps\n>((props, forwardRef) => <StyledScrollbar {...props} ref={forwardRef} />)\n","import { styled } from '@mirohq/design-system-stitches'\nimport { Thumb as RadixThumb } from '@radix-ui/react-scroll-area'\nimport type { StrictComponentProps } from '@mirohq/design-system-stitches'\n\nexport const StyledThumb = styled(RadixThumb, {\n flex: 1,\n background: '$background-neutrals-scrolls',\n borderRadius: '$50',\n position: 'relative',\n '&::before': {\n content: '\"\"',\n position: 'absolute',\n top: '50%',\n left: '50%',\n transform: 'translate(-50%, -50%)',\n width: '100%',\n height: '100%',\n minWidth: '$6',\n minHeight: '$6',\n },\n '&:hover': {\n backgroundColor: '$background-neutrals-scrolls-hover',\n },\n})\nexport type StyledThumbProps = StrictComponentProps<typeof StyledThumb>\n","import React from 'react'\nimport type { ElementRef } from 'react'\n\nimport { StyledThumb } from './thumb.styled'\nimport type { StyledThumbProps } from './thumb.styled'\n\nexport interface ThumbProps extends StyledThumbProps {\n /**\n * Used to force mounting when more control is needed. Useful when\n * controlling animation with React animation libraries.\n */\n forceMount?: true\n}\n\nexport const Thumb = React.forwardRef<\n ElementRef<typeof StyledThumb>,\n ThumbProps\n>((props, forwardRef) => <StyledThumb {...props} ref={forwardRef} />)\n","import React from 'react'\nimport { Corner as RadixCorner } from '@radix-ui/react-scroll-area'\nimport { styled } from '@mirohq/design-system-stitches'\nimport type { StrictComponentProps } from '@mirohq/design-system-stitches'\nimport type { ElementRef } from 'react'\n\nconst StyledCorner = styled(RadixCorner)\ntype StyledCornerProps = StrictComponentProps<typeof StyledCorner>\n\nexport interface CornerProps extends StyledCornerProps {}\n\nexport const Corner = React.forwardRef<\n ElementRef<typeof StyledCorner>,\n CornerProps\n>((props, forwardRef) => <StyledCorner {...props} ref={forwardRef} />)\n","import { styled } from '@mirohq/design-system-stitches'\nimport { Root as RadixScrollArea } from '@radix-ui/react-scroll-area'\nimport type { StrictComponentProps } from '@mirohq/design-system-stitches'\n\nexport const StyledScrollArea = styled(RadixScrollArea)\nexport type StyledScrollAreaProps = StrictComponentProps<\n typeof StyledScrollArea\n>\n","import React from 'react'\nimport type { ElementRef, ForwardRefExoticComponent } from 'react'\n\nimport { Viewport } from './partials/viewport'\nimport { Scrollbar } from './partials/scrollbar'\nimport { Thumb } from './partials/thumb'\nimport { Corner } from './partials/corner'\nimport { StyledScrollArea } from './scroll-area.styled'\nimport type { StyledScrollAreaProps } from './scroll-area.styled'\n\nexport interface ScrollAreaProps extends StyledScrollAreaProps {\n children: React.ReactNode\n\n /**\n * Describes the nature of scrollbar visibility, similar to how the scrollbar preferences in MacOS control visibility of native scrollbars.\n \"auto\" means that scrollbars are visible when content is overflowing on the corresponding orientation.\n \"always\" means that scrollbars are always visible regardless of whether the content is overflowing.\n \"scroll\" means that scrollbars are visible when the user is scrolling along its corresponding orientation.\n \"hover\" when the user is scrolling along its corresponding orientation and when the user is hovering over the scroll area.\n */\n type?: 'auto' | 'always' | 'scroll' | 'hover'\n\n /**\n * The reading direction of the scroll area. If omitted, inherits globally\n * from DirectionProvider or assumes LTR (left-to-right) reading mode.\n */\n dir?: 'ltr' | 'rtl'\n\n /**\n * If type is set to either \"scroll\" or \"hover\", this prop determines the\n * length of time, in milliseconds, before the scrollbars are hidden after the\n * user stops interacting with scrollbars.\n */\n scrollHideDelay?: number\n}\n\nexport const ScrollArea = React.forwardRef<\n ElementRef<typeof StyledScrollArea>,\n ScrollAreaProps\n>((props, forwardRef) => (\n <StyledScrollArea {...props} ref={forwardRef} />\n)) as ForwardRefExoticComponent<ScrollAreaProps> & Partials\n\ninterface Partials {\n Viewport: typeof Viewport\n Scrollbar: typeof Scrollbar\n Thumb: typeof Thumb\n Corner: typeof Corner\n}\n\nScrollArea.Viewport = Viewport\nScrollArea.Scrollbar = Scrollbar\nScrollArea.Thumb = Thumb\nScrollArea.Corner = Corner\n"],"names":["RadixViewport","RadixScrollbar","RadixThumb","RadixCorner","RadixScrollArea"],"mappings":";;;;AAMA,MAAM,cAAA,GAAiB,OAAOA,UAAa,CAAA,CAAA;AAKpC,MAAM,WAAW,KAAM,CAAA,UAAA,CAG5B,CAAC,KAAA,EAAO,+BAAgB,KAAA,CAAA,aAAA,CAAA,cAAA,EAAA;AAAA,EAAgB,GAAG,KAAA;AAAA,EAAO,GAAK,EAAA,UAAA;AAAA,CAAY,CAAE,CAAA;;ACV1D,MAAA,eAAA,GAAkB,OAAOC,WAAgB,EAAA;AAAA,EACpD,OAAS,EAAA,MAAA;AAAA,EAET,UAAY,EAAA,MAAA;AAAA,EAEZ,WAAa,EAAA,MAAA;AAAA,EACb,UAAY,EAAA,aAAA;AAAA,EACZ,UAAY,EAAA,2BAAA;AAAA,EACZ,gCAAkC,EAAA,EAAE,KAAO,EAAA,IAAA,EAAM,WAAW,IAAK,EAAA;AAAA,EACjE,kCAAoC,EAAA;AAAA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