@elliemae/ds-scrollable-container 3.32.2-next.1 → 3.33.0-next.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/cjs/DSScrollableContainer.js +125 -0
- package/dist/cjs/DSScrollableContainer.js.map +7 -0
- package/dist/cjs/config/index.js +30 -0
- package/dist/cjs/config/index.js.map +7 -0
- package/dist/cjs/config/useConfig.js +60 -0
- package/dist/cjs/config/useConfig.js.map +7 -0
- package/dist/cjs/exported_related/definitions.js +64 -0
- package/dist/cjs/exported_related/definitions.js.map +7 -0
- package/dist/cjs/exported_related/index.js +30 -0
- package/dist/cjs/exported_related/index.js.map +7 -0
- package/dist/cjs/index.js +2 -9
- package/dist/cjs/index.js.map +2 -2
- package/dist/cjs/react-desc-prop-types.js +40 -0
- package/dist/cjs/react-desc-prop-types.js.map +7 -0
- package/dist/cjs/styled.js +565 -0
- package/dist/cjs/styled.js.map +7 -0
- package/dist/esm/DSScrollableContainer.js +108 -0
- package/dist/esm/DSScrollableContainer.js.map +7 -0
- package/dist/esm/config/index.js +3 -0
- package/dist/esm/config/index.js.map +7 -0
- package/dist/esm/config/useConfig.js +30 -0
- package/dist/esm/config/useConfig.js.map +7 -0
- package/dist/esm/exported_related/definitions.js +34 -0
- package/dist/esm/exported_related/definitions.js.map +7 -0
- package/dist/esm/exported_related/index.js +3 -0
- package/dist/esm/exported_related/index.js.map +7 -0
- package/dist/esm/index.js +2 -5
- package/dist/esm/index.js.map +3 -3
- package/dist/esm/react-desc-prop-types.js +10 -0
- package/dist/esm/react-desc-prop-types.js.map +7 -0
- package/dist/esm/styled.js +535 -0
- package/dist/esm/styled.js.map +7 -0
- package/dist/types/DSScrollableContainer.d.ts +5 -0
- package/dist/types/config/index.d.ts +1 -0
- package/dist/types/config/useConfig.d.ts +11 -0
- package/dist/types/exported_related/definitions.d.ts +27 -0
- package/dist/types/exported_related/index.d.ts +1 -0
- package/dist/types/index.d.ts +2 -2
- package/dist/types/react-desc-prop-types.d.ts +11 -0
- package/package.json +8 -3
|
@@ -0,0 +1,125 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __create = Object.create;
|
|
3
|
+
var __defProp = Object.defineProperty;
|
|
4
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
5
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
6
|
+
var __getProtoOf = Object.getPrototypeOf;
|
|
7
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
8
|
+
var __export = (target, all) => {
|
|
9
|
+
for (var name in all)
|
|
10
|
+
__defProp(target, name, { get: all[name], enumerable: true });
|
|
11
|
+
};
|
|
12
|
+
var __copyProps = (to, from, except, desc) => {
|
|
13
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
14
|
+
for (let key of __getOwnPropNames(from))
|
|
15
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
16
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
17
|
+
}
|
|
18
|
+
return to;
|
|
19
|
+
};
|
|
20
|
+
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
|
|
21
|
+
// If the importer is in node compatibility mode or this is not an ESM
|
|
22
|
+
// file that has been converted to a CommonJS file using a Babel-
|
|
23
|
+
// compatible transform (i.e. "__esModule" has not been set), then set
|
|
24
|
+
// "default" to the CommonJS "module.exports" for node compatibility.
|
|
25
|
+
isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
|
|
26
|
+
mod
|
|
27
|
+
));
|
|
28
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
29
|
+
var DSScrollableContainer_exports = {};
|
|
30
|
+
__export(DSScrollableContainer_exports, {
|
|
31
|
+
DSScrollableContainer: () => DSScrollableContainer,
|
|
32
|
+
DSScrollableContainerWithSchema: () => DSScrollableContainerWithSchema
|
|
33
|
+
});
|
|
34
|
+
module.exports = __toCommonJS(DSScrollableContainer_exports);
|
|
35
|
+
var React = __toESM(require("react"));
|
|
36
|
+
var import_jsx_runtime = require("react/jsx-runtime");
|
|
37
|
+
var import_ds_props_helpers = require("@elliemae/ds-props-helpers");
|
|
38
|
+
var import_react_desc_prop_types = require("./react-desc-prop-types.js");
|
|
39
|
+
var import_exported_related = require("./exported_related/index.js");
|
|
40
|
+
var import_config = require("./config/index.js");
|
|
41
|
+
var import_styled = require("./styled.js");
|
|
42
|
+
const DSScrollableContainer = (props) => {
|
|
43
|
+
const {
|
|
44
|
+
propsWithDefault: { children },
|
|
45
|
+
globalAttrs,
|
|
46
|
+
xStyledAttrs,
|
|
47
|
+
osTargetRef
|
|
48
|
+
} = (0, import_config.useConfig)(props);
|
|
49
|
+
return /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(import_styled.StyledOsHostWrapper, { "data-testid": import_exported_related.DSScrollableContainerDataTestIds.ROOT, ...globalAttrs, ...xStyledAttrs, children: [
|
|
50
|
+
/* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_styled.GlobalStyleScrollContainer, {}),
|
|
51
|
+
/* @__PURE__ */ (0, import_jsx_runtime.jsxs)(
|
|
52
|
+
import_styled.StyledOsHost,
|
|
53
|
+
{
|
|
54
|
+
"data-testid": import_exported_related.DSScrollableContainerDataTestIds.HOST,
|
|
55
|
+
className: "os-host",
|
|
56
|
+
tabIndex: -1,
|
|
57
|
+
ref: osTargetRef,
|
|
58
|
+
children: [
|
|
59
|
+
/* @__PURE__ */ (0, import_jsx_runtime.jsx)(
|
|
60
|
+
import_styled.StyledOsResizeObserverHost,
|
|
61
|
+
{
|
|
62
|
+
"data-testid": import_exported_related.DSScrollableContainerDataTestIds.RESIZE_OBSERVER_HOST,
|
|
63
|
+
className: "os-resize-observer-host"
|
|
64
|
+
}
|
|
65
|
+
),
|
|
66
|
+
/* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_styled.StyledOsPadding, { "data-testid": import_exported_related.DSScrollableContainerDataTestIds.PADDING, className: "os-padding", children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_styled.StyledOsViewport, { "data-testid": import_exported_related.DSScrollableContainerDataTestIds.VIEWPORT, className: "os-viewport", children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_styled.StyledOsContent, { "data-testid": import_exported_related.DSScrollableContainerDataTestIds.CONTENT, className: "os-content", "aria-hidden": true, children }) }) }),
|
|
67
|
+
/* @__PURE__ */ (0, import_jsx_runtime.jsx)(
|
|
68
|
+
import_styled.StyledOsScrollbarHorizontal,
|
|
69
|
+
{
|
|
70
|
+
"data-testid": import_exported_related.DSScrollableContainerDataTestIds.SCROLLBAR_HORIZONTAL,
|
|
71
|
+
className: "os-scrollbar os-scrollbar-horizontal ",
|
|
72
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
|
|
73
|
+
import_styled.StyledOsScrollbarTrack,
|
|
74
|
+
{
|
|
75
|
+
"data-testid": import_exported_related.DSScrollableContainerDataTestIds.SCROLLBAR_TRACK,
|
|
76
|
+
className: "os-scrollbar-track",
|
|
77
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
|
|
78
|
+
import_styled.StyledOsScrollbarHandle,
|
|
79
|
+
{
|
|
80
|
+
"data-testid": import_exported_related.DSScrollableContainerDataTestIds.SCROLLBAR_HANDLE,
|
|
81
|
+
className: "os-scrollbar-handle"
|
|
82
|
+
}
|
|
83
|
+
)
|
|
84
|
+
}
|
|
85
|
+
)
|
|
86
|
+
}
|
|
87
|
+
),
|
|
88
|
+
/* @__PURE__ */ (0, import_jsx_runtime.jsx)(
|
|
89
|
+
import_styled.StyledOsScrollbarVertical,
|
|
90
|
+
{
|
|
91
|
+
"data-testid": import_exported_related.DSScrollableContainerDataTestIds.SCROLLBAR_VERTICAL,
|
|
92
|
+
className: "os-scrollbar os-scrollbar-vertical",
|
|
93
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
|
|
94
|
+
import_styled.StyledOsScrollbarTrack,
|
|
95
|
+
{
|
|
96
|
+
"data-testid": import_exported_related.DSScrollableContainerDataTestIds.SCROLLBAR_TRACK,
|
|
97
|
+
className: "os-scrollbar-track",
|
|
98
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
|
|
99
|
+
import_styled.StyledOsScrollbarHandle,
|
|
100
|
+
{
|
|
101
|
+
"data-testid": import_exported_related.DSScrollableContainerDataTestIds.SCROLLBAR_HANDLE,
|
|
102
|
+
className: "os-scrollbar-handle"
|
|
103
|
+
}
|
|
104
|
+
)
|
|
105
|
+
}
|
|
106
|
+
)
|
|
107
|
+
}
|
|
108
|
+
),
|
|
109
|
+
/* @__PURE__ */ (0, import_jsx_runtime.jsx)(
|
|
110
|
+
import_styled.StyledOsScrollbarCorner,
|
|
111
|
+
{
|
|
112
|
+
"data-testid": import_exported_related.DSScrollableContainerDataTestIds.SCROLLBAR_CORNER,
|
|
113
|
+
className: "os-scrollbar-corner"
|
|
114
|
+
}
|
|
115
|
+
)
|
|
116
|
+
]
|
|
117
|
+
}
|
|
118
|
+
)
|
|
119
|
+
] });
|
|
120
|
+
};
|
|
121
|
+
DSScrollableContainer.propTypes = import_react_desc_prop_types.DSScrollableContainerPropTypes;
|
|
122
|
+
DSScrollableContainer.displayName = import_exported_related.DSScrollableContainerName;
|
|
123
|
+
const DSScrollableContainerWithSchema = (0, import_ds_props_helpers.describe)(DSScrollableContainer);
|
|
124
|
+
DSScrollableContainerWithSchema.propTypes = import_react_desc_prop_types.DSScrollableContainerPropTypes;
|
|
125
|
+
//# sourceMappingURL=DSScrollableContainer.js.map
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
{
|
|
2
|
+
"version": 3,
|
|
3
|
+
"sources": ["../../src/DSScrollableContainer.tsx", "../../../../../scripts/build/transpile/react-shim.js"],
|
|
4
|
+
"sourcesContent": ["import React from 'react';\nimport { describe } from '@elliemae/ds-props-helpers';\nimport type { DSScrollableContainerT } from './react-desc-prop-types.js';\nimport { DSScrollableContainerPropTypes } from './react-desc-prop-types.js';\nimport { DSScrollableContainerDataTestIds, DSScrollableContainerName } from './exported_related/index.js';\nimport { useConfig } from './config/index.js';\nimport {\n StyledOsContent,\n StyledOsHost,\n StyledOsHostWrapper,\n StyledOsPadding,\n StyledOsResizeObserverHost,\n StyledOsScrollbarCorner,\n StyledOsScrollbarHandle,\n StyledOsScrollbarHorizontal,\n StyledOsScrollbarTrack,\n StyledOsScrollbarVertical,\n StyledOsViewport,\n GlobalStyleScrollContainer,\n} from './styled.js';\n\nconst DSScrollableContainer: React.ComponentType<DSScrollableContainerT.Props> = (props) => {\n const {\n propsWithDefault: { children },\n globalAttrs,\n xStyledAttrs,\n osTargetRef,\n } = useConfig(props);\n\n return (\n <StyledOsHostWrapper data-testid={DSScrollableContainerDataTestIds.ROOT} {...globalAttrs} {...xStyledAttrs}>\n <GlobalStyleScrollContainer />\n <StyledOsHost\n data-testid={DSScrollableContainerDataTestIds.HOST}\n className=\"os-host\"\n tabIndex={-1}\n ref={osTargetRef}\n >\n <StyledOsResizeObserverHost\n data-testid={DSScrollableContainerDataTestIds.RESIZE_OBSERVER_HOST}\n className=\"os-resize-observer-host\"\n />\n <StyledOsPadding data-testid={DSScrollableContainerDataTestIds.PADDING} className=\"os-padding\">\n <StyledOsViewport data-testid={DSScrollableContainerDataTestIds.VIEWPORT} className=\"os-viewport\">\n <StyledOsContent data-testid={DSScrollableContainerDataTestIds.CONTENT} className=\"os-content\" aria-hidden>\n {children}\n </StyledOsContent>\n </StyledOsViewport>\n </StyledOsPadding>\n <StyledOsScrollbarHorizontal\n data-testid={DSScrollableContainerDataTestIds.SCROLLBAR_HORIZONTAL}\n className=\"os-scrollbar os-scrollbar-horizontal \"\n >\n <StyledOsScrollbarTrack\n data-testid={DSScrollableContainerDataTestIds.SCROLLBAR_TRACK}\n className=\"os-scrollbar-track\"\n >\n <StyledOsScrollbarHandle\n data-testid={DSScrollableContainerDataTestIds.SCROLLBAR_HANDLE}\n className=\"os-scrollbar-handle\"\n />\n </StyledOsScrollbarTrack>\n </StyledOsScrollbarHorizontal>\n <StyledOsScrollbarVertical\n data-testid={DSScrollableContainerDataTestIds.SCROLLBAR_VERTICAL}\n className=\"os-scrollbar os-scrollbar-vertical\"\n >\n <StyledOsScrollbarTrack\n data-testid={DSScrollableContainerDataTestIds.SCROLLBAR_TRACK}\n className=\"os-scrollbar-track\"\n >\n <StyledOsScrollbarHandle\n data-testid={DSScrollableContainerDataTestIds.SCROLLBAR_HANDLE}\n className=\"os-scrollbar-handle\"\n />\n </StyledOsScrollbarTrack>\n </StyledOsScrollbarVertical>\n <StyledOsScrollbarCorner\n data-testid={DSScrollableContainerDataTestIds.SCROLLBAR_CORNER}\n className=\"os-scrollbar-corner\"\n />\n </StyledOsHost>\n </StyledOsHostWrapper>\n );\n};\n\nDSScrollableContainer.propTypes = DSScrollableContainerPropTypes;\nDSScrollableContainer.displayName = DSScrollableContainerName;\nconst DSScrollableContainerWithSchema = describe(DSScrollableContainer);\nDSScrollableContainerWithSchema.propTypes = DSScrollableContainerPropTypes;\n\nexport { DSScrollableContainer, DSScrollableContainerWithSchema };\n", "import * as React from 'react';\nexport { React };\n"],
|
|
5
|
+
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;AD+BjB;AA9BN,8BAAyB;AAEzB,mCAA+C;AAC/C,8BAA4E;AAC5E,oBAA0B;AAC1B,oBAaO;AAEP,MAAM,wBAA2E,CAAC,UAAU;AAC1F,QAAM;AAAA,IACJ,kBAAkB,EAAE,SAAS;AAAA,IAC7B;AAAA,IACA;AAAA,IACA;AAAA,EACF,QAAI,yBAAU,KAAK;AAEnB,SACE,6CAAC,qCAAoB,eAAa,yDAAiC,MAAO,GAAG,aAAc,GAAG,cAC5F;AAAA,gDAAC,4CAA2B;AAAA,IAC5B;AAAA,MAAC;AAAA;AAAA,QACC,eAAa,yDAAiC;AAAA,QAC9C,WAAU;AAAA,QACV,UAAU;AAAA,QACV,KAAK;AAAA,QAEL;AAAA;AAAA,YAAC;AAAA;AAAA,cACC,eAAa,yDAAiC;AAAA,cAC9C,WAAU;AAAA;AAAA,UACZ;AAAA,UACA,4CAAC,iCAAgB,eAAa,yDAAiC,SAAS,WAAU,cAChF,sDAAC,kCAAiB,eAAa,yDAAiC,UAAU,WAAU,eAClF,sDAAC,iCAAgB,eAAa,yDAAiC,SAAS,WAAU,cAAa,eAAW,MACvG,UACH,GACF,GACF;AAAA,UACA;AAAA,YAAC;AAAA;AAAA,cACC,eAAa,yDAAiC;AAAA,cAC9C,WAAU;AAAA,cAEV;AAAA,gBAAC;AAAA;AAAA,kBACC,eAAa,yDAAiC;AAAA,kBAC9C,WAAU;AAAA,kBAEV;AAAA,oBAAC;AAAA;AAAA,sBACC,eAAa,yDAAiC;AAAA,sBAC9C,WAAU;AAAA;AAAA,kBACZ;AAAA;AAAA,cACF;AAAA;AAAA,UACF;AAAA,UACA;AAAA,YAAC;AAAA;AAAA,cACC,eAAa,yDAAiC;AAAA,cAC9C,WAAU;AAAA,cAEV;AAAA,gBAAC;AAAA;AAAA,kBACC,eAAa,yDAAiC;AAAA,kBAC9C,WAAU;AAAA,kBAEV;AAAA,oBAAC;AAAA;AAAA,sBACC,eAAa,yDAAiC;AAAA,sBAC9C,WAAU;AAAA;AAAA,kBACZ;AAAA;AAAA,cACF;AAAA;AAAA,UACF;AAAA,UACA;AAAA,YAAC;AAAA;AAAA,cACC,eAAa,yDAAiC;AAAA,cAC9C,WAAU;AAAA;AAAA,UACZ;AAAA;AAAA;AAAA,IACF;AAAA,KACF;AAEJ;AAEA,sBAAsB,YAAY;AAClC,sBAAsB,cAAc;AACpC,MAAM,sCAAkC,kCAAS,qBAAqB;AACtE,gCAAgC,YAAY;",
|
|
6
|
+
"names": []
|
|
7
|
+
}
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __create = Object.create;
|
|
3
|
+
var __defProp = Object.defineProperty;
|
|
4
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
5
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
6
|
+
var __getProtoOf = Object.getPrototypeOf;
|
|
7
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
8
|
+
var __copyProps = (to, from, except, desc) => {
|
|
9
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
10
|
+
for (let key of __getOwnPropNames(from))
|
|
11
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
12
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
13
|
+
}
|
|
14
|
+
return to;
|
|
15
|
+
};
|
|
16
|
+
var __reExport = (target, mod, secondTarget) => (__copyProps(target, mod, "default"), secondTarget && __copyProps(secondTarget, mod, "default"));
|
|
17
|
+
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
|
|
18
|
+
// If the importer is in node compatibility mode or this is not an ESM
|
|
19
|
+
// file that has been converted to a CommonJS file using a Babel-
|
|
20
|
+
// compatible transform (i.e. "__esModule" has not been set), then set
|
|
21
|
+
// "default" to the CommonJS "module.exports" for node compatibility.
|
|
22
|
+
isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
|
|
23
|
+
mod
|
|
24
|
+
));
|
|
25
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
26
|
+
var config_exports = {};
|
|
27
|
+
module.exports = __toCommonJS(config_exports);
|
|
28
|
+
var React = __toESM(require("react"));
|
|
29
|
+
__reExport(config_exports, require("./useConfig.js"), module.exports);
|
|
30
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
{
|
|
2
|
+
"version": 3,
|
|
3
|
+
"sources": ["../../../src/config/index.ts", "../../../../../../scripts/build/transpile/react-shim.js"],
|
|
4
|
+
"sourcesContent": ["export * from './useConfig.js';\n", "import * as React from 'react';\nexport { React };\n"],
|
|
5
|
+
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;ACAA,YAAuB;ADAvB,2BAAc,2BAAd;",
|
|
6
|
+
"names": []
|
|
7
|
+
}
|
|
@@ -0,0 +1,60 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __create = Object.create;
|
|
3
|
+
var __defProp = Object.defineProperty;
|
|
4
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
5
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
6
|
+
var __getProtoOf = Object.getPrototypeOf;
|
|
7
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
8
|
+
var __export = (target, all) => {
|
|
9
|
+
for (var name in all)
|
|
10
|
+
__defProp(target, name, { get: all[name], enumerable: true });
|
|
11
|
+
};
|
|
12
|
+
var __copyProps = (to, from, except, desc) => {
|
|
13
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
14
|
+
for (let key of __getOwnPropNames(from))
|
|
15
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
16
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
17
|
+
}
|
|
18
|
+
return to;
|
|
19
|
+
};
|
|
20
|
+
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
|
|
21
|
+
// If the importer is in node compatibility mode or this is not an ESM
|
|
22
|
+
// file that has been converted to a CommonJS file using a Babel-
|
|
23
|
+
// compatible transform (i.e. "__esModule" has not been set), then set
|
|
24
|
+
// "default" to the CommonJS "module.exports" for node compatibility.
|
|
25
|
+
isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
|
|
26
|
+
mod
|
|
27
|
+
));
|
|
28
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
29
|
+
var useConfig_exports = {};
|
|
30
|
+
__export(useConfig_exports, {
|
|
31
|
+
useConfig: () => useConfig
|
|
32
|
+
});
|
|
33
|
+
module.exports = __toCommonJS(useConfig_exports);
|
|
34
|
+
var React = __toESM(require("react"));
|
|
35
|
+
var import_ds_props_helpers = require("@elliemae/ds-props-helpers");
|
|
36
|
+
var import_overlayscrollbars = __toESM(require("overlayscrollbars"));
|
|
37
|
+
var import_react = require("react");
|
|
38
|
+
var import_react_desc_prop_types = require("../react-desc-prop-types.js");
|
|
39
|
+
const options = {
|
|
40
|
+
scrollbars: {
|
|
41
|
+
autoHide: "leave",
|
|
42
|
+
autoHideDelay: 0
|
|
43
|
+
}
|
|
44
|
+
};
|
|
45
|
+
const useConfig = (props) => {
|
|
46
|
+
const propsWithDefault = props;
|
|
47
|
+
(0, import_ds_props_helpers.useValidateTypescriptPropTypes)(propsWithDefault, import_react_desc_prop_types.DSScrollableContainerPropTypes, "DSScrollableContainer");
|
|
48
|
+
const globalAttrs = (0, import_ds_props_helpers.useGetGlobalAttributes)(propsWithDefault);
|
|
49
|
+
const xStyledAttrs = (0, import_ds_props_helpers.useGetXstyledProps)(propsWithDefault);
|
|
50
|
+
const [osInstance, setOsInstance] = (0, import_react.useState)();
|
|
51
|
+
const osTargetRef = (0, import_react.useRef)(null);
|
|
52
|
+
(0, import_react.useEffect)(() => {
|
|
53
|
+
if (osTargetRef.current) {
|
|
54
|
+
const nextOsInstance = (0, import_overlayscrollbars.default)(osTargetRef.current, options);
|
|
55
|
+
setOsInstance(nextOsInstance);
|
|
56
|
+
}
|
|
57
|
+
}, [osInstance]);
|
|
58
|
+
return { propsWithDefault: props, globalAttrs, xStyledAttrs, osTargetRef };
|
|
59
|
+
};
|
|
60
|
+
//# sourceMappingURL=useConfig.js.map
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
{
|
|
2
|
+
"version": 3,
|
|
3
|
+
"sources": ["../../../src/config/useConfig.tsx", "../../../../../../scripts/build/transpile/react-shim.js"],
|
|
4
|
+
"sourcesContent": ["import type {} from '@elliemae/ds-utilities';\nimport type { GlobalAttributesT, XstyledProps } from '@elliemae/ds-props-helpers';\nimport { useGetGlobalAttributes, useValidateTypescriptPropTypes, useGetXstyledProps } from '@elliemae/ds-props-helpers';\nimport type { Options } from 'overlayscrollbars';\nimport OverlayScrollbars from 'overlayscrollbars';\nimport { useEffect, useRef, useState } from 'react';\nimport type { DSScrollableContainerT } from '../react-desc-prop-types.js';\nimport { DSScrollableContainerPropTypes } from '../react-desc-prop-types.js';\n\nconst options: Options = {\n scrollbars: {\n autoHide: 'leave',\n autoHideDelay: 0,\n },\n};\n\ninterface UseConfigT {\n propsWithDefault: DSScrollableContainerT.Props;\n globalAttributes: GlobalAttributesT;\n xstyledProps: XstyledProps;\n osTargetRef: React.RefObject<HTMLDivElement>;\n}\n\nexport const useConfig = (props: DSScrollableContainerT.Props): UseConfigT => {\n const propsWithDefault = props;\n useValidateTypescriptPropTypes(propsWithDefault, DSScrollableContainerPropTypes, 'DSScrollableContainer');\n const globalAttrs = useGetGlobalAttributes(propsWithDefault);\n const xStyledAttrs = useGetXstyledProps(propsWithDefault);\n\n const [osInstance, setOsInstance] = useState<OverlayScrollbars>();\n const osTargetRef = useRef<HTMLDivElement>(null);\n\n useEffect(() => {\n if (osTargetRef.current) {\n const nextOsInstance: OverlayScrollbars = OverlayScrollbars(osTargetRef.current, options);\n setOsInstance(nextOsInstance);\n }\n }, [osInstance]);\n\n return { propsWithDefault: props, globalAttrs, xStyledAttrs, osTargetRef };\n};\n", "import * as React from 'react';\nexport { React };\n"],
|
|
5
|
+
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADEvB,8BAA2F;AAE3F,+BAA8B;AAC9B,mBAA4C;AAE5C,mCAA+C;AAE/C,MAAM,UAAmB;AAAA,EACvB,YAAY;AAAA,IACV,UAAU;AAAA,IACV,eAAe;AAAA,EACjB;AACF;AASO,MAAM,YAAY,CAAC,UAAoD;AAC5E,QAAM,mBAAmB;AACzB,8DAA+B,kBAAkB,6DAAgC,uBAAuB;AACxG,QAAM,kBAAc,gDAAuB,gBAAgB;AAC3D,QAAM,mBAAe,4CAAmB,gBAAgB;AAExD,QAAM,CAAC,YAAY,aAAa,QAAI,uBAA4B;AAChE,QAAM,kBAAc,qBAAuB,IAAI;AAE/C,8BAAU,MAAM;AACd,QAAI,YAAY,SAAS;AACvB,YAAM,qBAAoC,yBAAAA,SAAkB,YAAY,SAAS,OAAO;AACxF,oBAAc,cAAc;AAAA,IAC9B;AAAA,EACF,GAAG,CAAC,UAAU,CAAC;AAEf,SAAO,EAAE,kBAAkB,OAAO,aAAa,cAAc,YAAY;AAC3E;",
|
|
6
|
+
"names": ["OverlayScrollbars"]
|
|
7
|
+
}
|
|
@@ -0,0 +1,64 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __create = Object.create;
|
|
3
|
+
var __defProp = Object.defineProperty;
|
|
4
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
5
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
6
|
+
var __getProtoOf = Object.getPrototypeOf;
|
|
7
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
8
|
+
var __export = (target, all) => {
|
|
9
|
+
for (var name in all)
|
|
10
|
+
__defProp(target, name, { get: all[name], enumerable: true });
|
|
11
|
+
};
|
|
12
|
+
var __copyProps = (to, from, except, desc) => {
|
|
13
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
14
|
+
for (let key of __getOwnPropNames(from))
|
|
15
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
16
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
17
|
+
}
|
|
18
|
+
return to;
|
|
19
|
+
};
|
|
20
|
+
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
|
|
21
|
+
// If the importer is in node compatibility mode or this is not an ESM
|
|
22
|
+
// file that has been converted to a CommonJS file using a Babel-
|
|
23
|
+
// compatible transform (i.e. "__esModule" has not been set), then set
|
|
24
|
+
// "default" to the CommonJS "module.exports" for node compatibility.
|
|
25
|
+
isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
|
|
26
|
+
mod
|
|
27
|
+
));
|
|
28
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
29
|
+
var definitions_exports = {};
|
|
30
|
+
__export(definitions_exports, {
|
|
31
|
+
DSScrollableContainerDataTestIds: () => DSScrollableContainerDataTestIds,
|
|
32
|
+
DSScrollableContainerName: () => DSScrollableContainerName,
|
|
33
|
+
DSScrollableContainerSlots: () => DSScrollableContainerSlots
|
|
34
|
+
});
|
|
35
|
+
module.exports = __toCommonJS(definitions_exports);
|
|
36
|
+
var React = __toESM(require("react"));
|
|
37
|
+
const DSScrollableContainerName = "DSScrollableContainer";
|
|
38
|
+
const DSScrollableContainerSlots = {
|
|
39
|
+
ROOT: "root",
|
|
40
|
+
HOST: "host",
|
|
41
|
+
RESIZE_OBSERVER_HOST: "resize-observer-host",
|
|
42
|
+
PADDING: "padding",
|
|
43
|
+
VIEWPORT: "viewport",
|
|
44
|
+
CONTENT: "content",
|
|
45
|
+
SCROLLBAR_HORIZONTAL: "scrollbar-horizontal",
|
|
46
|
+
SCROLLBAR_VERTICAL: "scrollbar-vertical",
|
|
47
|
+
SCROLLBAR_TRACK: "scrollbar-track",
|
|
48
|
+
SCROLLBAR_HANDLE: "scrollbar-handle",
|
|
49
|
+
SCROLLBAR_CORNER: "scrollbar-corner"
|
|
50
|
+
};
|
|
51
|
+
const DSScrollableContainerDataTestIds = {
|
|
52
|
+
ROOT: "ds-scrollable-container-root",
|
|
53
|
+
HOST: "ds-scrollable-container-host",
|
|
54
|
+
RESIZE_OBSERVER_HOST: "ds-scrollable-container-resize-observer-host",
|
|
55
|
+
PADDING: "ds-scrollable-container-padding",
|
|
56
|
+
VIEWPORT: "ds-scrollable-container-viewport",
|
|
57
|
+
CONTENT: "ds-scrollable-container-content",
|
|
58
|
+
SCROLLBAR_HORIZONTAL: "ds-scrollable-container-scrollbar-horizontal",
|
|
59
|
+
SCROLLBAR_VERTICAL: "ds-scrollable-container-scrollbar-vertical",
|
|
60
|
+
SCROLLBAR_TRACK: "ds-scrollable-container-scrollbar-track",
|
|
61
|
+
SCROLLBAR_HANDLE: "ds-scrollable-container-scrollbar-handle",
|
|
62
|
+
SCROLLBAR_CORNER: "ds-scrollable-container-scrollbar-corner"
|
|
63
|
+
};
|
|
64
|
+
//# sourceMappingURL=definitions.js.map
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
{
|
|
2
|
+
"version": 3,
|
|
3
|
+
"sources": ["../../../src/exported_related/definitions.ts", "../../../../../../scripts/build/transpile/react-shim.js"],
|
|
4
|
+
"sourcesContent": ["export const DSScrollableContainerName = 'DSScrollableContainer';\n\nexport const DSScrollableContainerSlots = {\n ROOT: 'root',\n HOST: 'host',\n RESIZE_OBSERVER_HOST: 'resize-observer-host',\n PADDING: 'padding',\n VIEWPORT: 'viewport',\n CONTENT: 'content',\n SCROLLBAR_HORIZONTAL: 'scrollbar-horizontal',\n SCROLLBAR_VERTICAL: 'scrollbar-vertical',\n SCROLLBAR_TRACK: 'scrollbar-track',\n SCROLLBAR_HANDLE: 'scrollbar-handle',\n SCROLLBAR_CORNER: 'scrollbar-corner',\n};\n\nexport const DSScrollableContainerDataTestIds = {\n ROOT: 'ds-scrollable-container-root',\n HOST: 'ds-scrollable-container-host',\n RESIZE_OBSERVER_HOST: 'ds-scrollable-container-resize-observer-host',\n PADDING: 'ds-scrollable-container-padding',\n VIEWPORT: 'ds-scrollable-container-viewport',\n CONTENT: 'ds-scrollable-container-content',\n SCROLLBAR_HORIZONTAL: 'ds-scrollable-container-scrollbar-horizontal',\n SCROLLBAR_VERTICAL: 'ds-scrollable-container-scrollbar-vertical',\n SCROLLBAR_TRACK: 'ds-scrollable-container-scrollbar-track',\n SCROLLBAR_HANDLE: 'ds-scrollable-container-scrollbar-handle',\n SCROLLBAR_CORNER: 'ds-scrollable-container-scrollbar-corner',\n};\n", "import * as React from 'react';\nexport { React };\n"],
|
|
5
|
+
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADAhB,MAAM,4BAA4B;AAElC,MAAM,6BAA6B;AAAA,EACxC,MAAM;AAAA,EACN,MAAM;AAAA,EACN,sBAAsB;AAAA,EACtB,SAAS;AAAA,EACT,UAAU;AAAA,EACV,SAAS;AAAA,EACT,sBAAsB;AAAA,EACtB,oBAAoB;AAAA,EACpB,iBAAiB;AAAA,EACjB,kBAAkB;AAAA,EAClB,kBAAkB;AACpB;AAEO,MAAM,mCAAmC;AAAA,EAC9C,MAAM;AAAA,EACN,MAAM;AAAA,EACN,sBAAsB;AAAA,EACtB,SAAS;AAAA,EACT,UAAU;AAAA,EACV,SAAS;AAAA,EACT,sBAAsB;AAAA,EACtB,oBAAoB;AAAA,EACpB,iBAAiB;AAAA,EACjB,kBAAkB;AAAA,EAClB,kBAAkB;AACpB;",
|
|
6
|
+
"names": []
|
|
7
|
+
}
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __create = Object.create;
|
|
3
|
+
var __defProp = Object.defineProperty;
|
|
4
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
5
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
6
|
+
var __getProtoOf = Object.getPrototypeOf;
|
|
7
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
8
|
+
var __copyProps = (to, from, except, desc) => {
|
|
9
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
10
|
+
for (let key of __getOwnPropNames(from))
|
|
11
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
12
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
13
|
+
}
|
|
14
|
+
return to;
|
|
15
|
+
};
|
|
16
|
+
var __reExport = (target, mod, secondTarget) => (__copyProps(target, mod, "default"), secondTarget && __copyProps(secondTarget, mod, "default"));
|
|
17
|
+
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
|
|
18
|
+
// If the importer is in node compatibility mode or this is not an ESM
|
|
19
|
+
// file that has been converted to a CommonJS file using a Babel-
|
|
20
|
+
// compatible transform (i.e. "__esModule" has not been set), then set
|
|
21
|
+
// "default" to the CommonJS "module.exports" for node compatibility.
|
|
22
|
+
isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
|
|
23
|
+
mod
|
|
24
|
+
));
|
|
25
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
26
|
+
var exported_related_exports = {};
|
|
27
|
+
module.exports = __toCommonJS(exported_related_exports);
|
|
28
|
+
var React = __toESM(require("react"));
|
|
29
|
+
__reExport(exported_related_exports, require("./definitions.js"), module.exports);
|
|
30
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
{
|
|
2
|
+
"version": 3,
|
|
3
|
+
"sources": ["../../../src/exported_related/index.ts", "../../../../../../scripts/build/transpile/react-shim.js"],
|
|
4
|
+
"sourcesContent": ["export * from './definitions.js';\n", "import * as React from 'react';\nexport { React };\n"],
|
|
5
|
+
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;ACAA,YAAuB;ADAvB,qCAAc,6BAAd;",
|
|
6
|
+
"names": []
|
|
7
|
+
}
|
package/dist/cjs/index.js
CHANGED
|
@@ -5,10 +5,6 @@ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
|
5
5
|
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
6
6
|
var __getProtoOf = Object.getPrototypeOf;
|
|
7
7
|
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
8
|
-
var __export = (target, all) => {
|
|
9
|
-
for (var name in all)
|
|
10
|
-
__defProp(target, name, { get: all[name], enumerable: true });
|
|
11
|
-
};
|
|
12
8
|
var __copyProps = (to, from, except, desc) => {
|
|
13
9
|
if (from && typeof from === "object" || typeof from === "function") {
|
|
14
10
|
for (let key of __getOwnPropNames(from))
|
|
@@ -28,11 +24,8 @@ var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__ge
|
|
|
28
24
|
));
|
|
29
25
|
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
30
26
|
var src_exports = {};
|
|
31
|
-
__export(src_exports, {
|
|
32
|
-
default: () => import_ds_legacy_scrollable_container.default
|
|
33
|
-
});
|
|
34
27
|
module.exports = __toCommonJS(src_exports);
|
|
35
28
|
var React = __toESM(require("react"));
|
|
36
|
-
__reExport(src_exports, require("
|
|
37
|
-
|
|
29
|
+
__reExport(src_exports, require("./DSScrollableContainer.js"), module.exports);
|
|
30
|
+
__reExport(src_exports, require("./exported_related/index.js"), module.exports);
|
|
38
31
|
//# sourceMappingURL=index.js.map
|
package/dist/cjs/index.js.map
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../src/index.tsx", "../../../../../scripts/build/transpile/react-shim.js"],
|
|
4
|
-
"sourcesContent": ["export * from '
|
|
5
|
-
"mappings": "
|
|
4
|
+
"sourcesContent": ["export * from './DSScrollableContainer.js';\nexport * from './exported_related/index.js';\n", "import * as React from 'react';\nexport { React };\n"],
|
|
5
|
+
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;ACAA,YAAuB;ADAvB,wBAAc,uCAAd;AACA,wBAAc,wCADd;",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __create = Object.create;
|
|
3
|
+
var __defProp = Object.defineProperty;
|
|
4
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
5
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
6
|
+
var __getProtoOf = Object.getPrototypeOf;
|
|
7
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
8
|
+
var __export = (target, all) => {
|
|
9
|
+
for (var name in all)
|
|
10
|
+
__defProp(target, name, { get: all[name], enumerable: true });
|
|
11
|
+
};
|
|
12
|
+
var __copyProps = (to, from, except, desc) => {
|
|
13
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
14
|
+
for (let key of __getOwnPropNames(from))
|
|
15
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
16
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
17
|
+
}
|
|
18
|
+
return to;
|
|
19
|
+
};
|
|
20
|
+
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
|
|
21
|
+
// If the importer is in node compatibility mode or this is not an ESM
|
|
22
|
+
// file that has been converted to a CommonJS file using a Babel-
|
|
23
|
+
// compatible transform (i.e. "__esModule" has not been set), then set
|
|
24
|
+
// "default" to the CommonJS "module.exports" for node compatibility.
|
|
25
|
+
isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
|
|
26
|
+
mod
|
|
27
|
+
));
|
|
28
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
29
|
+
var react_desc_prop_types_exports = {};
|
|
30
|
+
__export(react_desc_prop_types_exports, {
|
|
31
|
+
DSScrollableContainerPropTypes: () => DSScrollableContainerPropTypes
|
|
32
|
+
});
|
|
33
|
+
module.exports = __toCommonJS(react_desc_prop_types_exports);
|
|
34
|
+
var React = __toESM(require("react"));
|
|
35
|
+
var import_ds_props_helpers = require("@elliemae/ds-props-helpers");
|
|
36
|
+
const DSScrollableContainerPropTypes = {
|
|
37
|
+
...import_ds_props_helpers.globalAttributesPropTypes,
|
|
38
|
+
...import_ds_props_helpers.xstyledPropTypes
|
|
39
|
+
};
|
|
40
|
+
//# sourceMappingURL=react-desc-prop-types.js.map
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
{
|
|
2
|
+
"version": 3,
|
|
3
|
+
"sources": ["../../src/react-desc-prop-types.tsx", "../../../../../scripts/build/transpile/react-shim.js"],
|
|
4
|
+
"sourcesContent": ["import type { WeakValidationMap } from 'react';\nimport type React from 'react';\nimport type {} from '@elliemae/ds-utilities';\nimport type { GlobalAttributesT, XstyledProps } from '@elliemae/ds-props-helpers';\nimport { globalAttributesPropTypes, xstyledPropTypes } from '@elliemae/ds-props-helpers';\n\nexport declare namespace DSScrollableContainerT {\n interface OptionalProps {\n children?: React.ReactNode;\n }\n export interface Props extends OptionalProps, XstyledProps, GlobalAttributesT<HTMLDivElement> {}\n}\n\nexport const DSScrollableContainerPropTypes = {\n ...globalAttributesPropTypes,\n ...xstyledPropTypes,\n} as WeakValidationMap<unknown>;\n", "import * as React from 'react';\nexport { React };\n"],
|
|
5
|
+
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADIvB,8BAA4D;AASrD,MAAM,iCAAiC;AAAA,EAC5C,GAAG;AAAA,EACH,GAAG;AACL;",
|
|
6
|
+
"names": []
|
|
7
|
+
}
|