xmlui 0.7.32 → 0.7.34
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/{apiInterceptorWorker-iyzFS4kP.mjs → apiInterceptorWorker-DHDoRL37.mjs} +1 -1
- package/dist/{index-29eF52eI.mjs → index-B90aqc2f.mjs} +10337 -9968
- package/dist/index.css +1 -1
- package/dist/{lint-DgP_MIP6.mjs → lint-D3rXRbP1.mjs} +337 -337
- package/dist/scripts/bin/language-server.js +11 -0
- package/dist/scripts/src/abstractions/ComponentDefs.js +2 -1
- package/dist/scripts/src/components/Accordion/Accordion.js +5 -5
- package/dist/scripts/src/components/App/App.js +2 -2
- package/dist/scripts/src/components/App/AppNative.js +2 -2
- package/dist/scripts/src/components/AppHeader/AppHeader.js +6 -3
- package/dist/scripts/src/components/AutoComplete/AutoComplete.js +6 -6
- package/dist/scripts/src/components/Avatar/Avatar.js +3 -3
- package/dist/scripts/src/components/Badge/Badge.js +3 -3
- package/dist/scripts/src/components/Button/Button.js +15 -15
- package/dist/scripts/src/components/Button/ButtonNative.js +3 -2
- package/dist/scripts/src/components/Card/Card.js +2 -2
- package/dist/scripts/src/components/Carousel/Carousel.js +4 -1
- package/dist/scripts/src/components/ComponentProvider.js +8 -3
- package/dist/scripts/src/components/DatePicker/DatePicker.js +2 -2
- package/dist/scripts/src/components/DropdownMenu/DropdownMenu.js +10 -10
- package/dist/scripts/src/components/DropdownMenu/DropdownMenuNative.js +4 -5
- package/dist/scripts/src/components/Footer/Footer.js +1 -1
- package/dist/scripts/src/components/FormItem/FormItem.js +3 -3
- package/dist/scripts/src/components/Heading/Heading.js +21 -27
- package/dist/scripts/src/components/Heading/HeadingNative.js +2 -1
- package/dist/scripts/src/components/HtmlTags/HtmlTags.js +57 -20
- package/dist/scripts/src/components/Icon/Inspect.js +10 -0
- package/dist/scripts/src/components/IconProvider.js +3 -1
- package/dist/scripts/src/components/IconRegistryContext.js +243 -242
- package/dist/scripts/src/components/Link/Link.js +16 -13
- package/dist/scripts/src/components/Markdown/Markdown.js +3 -3
- package/dist/scripts/src/components/Markdown/MarkdownNative.js +73 -17
- package/dist/scripts/src/components/ModalDialog/ModalDialog.js +1 -1
- package/dist/scripts/src/components/NavGroup/NavGroup.js +2 -2
- package/dist/scripts/src/components/NavLink/NavLink.js +26 -23
- package/dist/scripts/src/components/NavPanel/NavPanel.js +6 -6
- package/dist/scripts/src/components/NoResult/NoResult.js +1 -1
- package/dist/scripts/src/components/OffCanvas/OffCanvas.js +4 -4
- package/dist/scripts/src/components/ProgressBar/ProgressBar.js +2 -2
- package/dist/scripts/src/components/RadioGroup/RadioGroup.js +2 -2
- package/dist/scripts/src/components/Select/Select.js +6 -6
- package/dist/scripts/src/components/Select/SelectNative.js +16 -15
- package/dist/scripts/src/components/Slider/Slider.js +1 -1
- package/dist/scripts/src/components/Table/Table.js +15 -15
- package/dist/scripts/src/components/TableOfContents/TableOfContents.js +21 -21
- package/dist/scripts/src/components/TableOfContents/TableOfContentsNative.js +2 -1
- package/dist/scripts/src/components/Text/Text.js +39 -40
- package/dist/scripts/src/components/TextBox/TextBox.js +6 -6
- package/dist/scripts/src/components/Theme/ThemeNative.js +1 -1
- package/dist/scripts/src/components-core/ComponentDecorator.js +23 -19
- package/dist/scripts/src/components-core/InspectorContext.js +2 -2
- package/dist/scripts/src/components-core/abstractions/standalone.js +2 -0
- package/dist/scripts/src/components-core/descriptorHelper.js +7 -7
- package/dist/scripts/src/components-core/interception/abstractions.js +2 -0
- package/dist/scripts/src/components-core/rendering/ComponentAdapter.js +2 -2
- package/dist/scripts/src/components-core/rendering/Container.js +21 -34
- package/dist/scripts/src/components-core/theming/layout-resolver.js +26 -26
- package/dist/scripts/src/components-core/theming/themes/base-utils.js +8 -8
- package/dist/scripts/src/components-core/theming/themes/root.js +39 -39
- package/dist/scripts/src/components-core/theming/themes/solid.js +2 -2
- package/dist/scripts/src/components-core/theming/themes/xmlui.js +2 -2
- package/dist/scripts/src/components-core/theming/transformThemeVars.js +37 -37
- package/dist/scripts/src/components-core/utils/hooks.js +2 -2
- package/dist/scripts/src/language-server/metadata.js +8206 -0
- package/dist/scripts/src/language-server/server.js +135 -0
- package/dist/scripts/src/language-server/services/completion.js +100 -0
- package/dist/scripts/src/language-server/services/hover.js +170 -0
- package/dist/scripts/src/language-server/services/syntax-node-utilities.js +22 -0
- package/dist/scripts/src/parsers/xmlui-parser/index.js +29 -0
- package/dist/scripts/src/parsers/xmlui-parser/lint.js +177 -0
- package/dist/scripts/src/parsers/xmlui-parser/xmlui-serializer.js +582 -0
- package/dist/scripts/src/parsers/xmlui-parser/xmlui-tree.js +2 -0
- package/dist/style.css +1 -1
- package/dist/xmlui-metadata.mjs +8066 -6905
- package/dist/xmlui-metadata.umd.js +11 -11
- package/dist/xmlui-parser.d.ts +1 -0
- package/dist/xmlui-parser.mjs +2 -2
- package/dist/xmlui-standalone.umd.js +165 -165
- package/dist/xmlui.d.ts +5 -3
- package/dist/xmlui.mjs +13 -12
- package/package.json +9 -4
|
@@ -104,11 +104,11 @@ exports.RootThemeDefinition = {
|
|
|
104
104
|
"color-info-900": "hsl(183, 97%, 15%)",
|
|
105
105
|
"color-info-950": "hsl(183, 97%, 10%)",
|
|
106
106
|
// --- Font weights
|
|
107
|
-
"
|
|
108
|
-
"
|
|
109
|
-
"
|
|
110
|
-
"
|
|
111
|
-
"
|
|
107
|
+
"fontWeight-light": "300",
|
|
108
|
+
"fontWeight-normal": "400",
|
|
109
|
+
"fontWeight-medium": "500",
|
|
110
|
+
"fontWeight-bold": "600",
|
|
111
|
+
"fontWeight-extra-bold": "900",
|
|
112
112
|
// --- Default text colors (component use these values as their defaults)
|
|
113
113
|
"color-text-primary": "$color-surface-950",
|
|
114
114
|
"color-text-attention": "$color-danger-600",
|
|
@@ -126,41 +126,41 @@ exports.RootThemeDefinition = {
|
|
|
126
126
|
"color-warning": "$color-warn-700",
|
|
127
127
|
"color-error": "$color-danger-600",
|
|
128
128
|
// --- Default line height values (relative to the base unit, "space-base")
|
|
129
|
-
"
|
|
130
|
-
"
|
|
131
|
-
"
|
|
132
|
-
"
|
|
133
|
-
"
|
|
134
|
-
"
|
|
129
|
+
"lineHeight-none": "1",
|
|
130
|
+
"lineHeight-tight": "1.25",
|
|
131
|
+
"lineHeight-snug": "1.375",
|
|
132
|
+
"lineHeight-normal": "1.5",
|
|
133
|
+
"lineHeight-relaxed": "1.625",
|
|
134
|
+
"lineHeight-loose": "2",
|
|
135
135
|
// --- The sans-serif font set
|
|
136
|
-
"
|
|
136
|
+
"fontFamily-sans-serif": "'Inter', -apple-system, BlinkMacSystemFont, San Francisco, Segoe UI, Roboto, Helvetica Neue, sans-serif",
|
|
137
137
|
// --- The monospace font set
|
|
138
|
-
"
|
|
138
|
+
"fontFamily-monospace": "Menlo,Monaco,Consolas,Liberation Mono,Courier New,monospace",
|
|
139
139
|
"font-feature-settings": "'cv03', 'cv04', 'cv11'",
|
|
140
140
|
// --- Some media breakpoints (review them)
|
|
141
|
-
"media-
|
|
142
|
-
"media-
|
|
143
|
-
"media-
|
|
144
|
-
"media-
|
|
145
|
-
"media-
|
|
141
|
+
"media-maxWidth-phone": "576px",
|
|
142
|
+
"media-maxWidth-landscape-phone": "768px",
|
|
143
|
+
"media-maxWidth-tablet": "992px",
|
|
144
|
+
"media-maxWidth-desktop": "1200px",
|
|
145
|
+
"media-maxWidth-large-desktop": "1400px",
|
|
146
146
|
// --- The app's default radius value
|
|
147
|
-
|
|
148
|
-
"
|
|
149
|
-
"
|
|
150
|
-
"
|
|
151
|
-
"
|
|
147
|
+
borderRadius: "4px",
|
|
148
|
+
"outlineColor--focus": "rgba($color-primary-500-rgb, .5)",
|
|
149
|
+
"outlineWidth--focus": "2px",
|
|
150
|
+
"outlineStyle--focus": "solid",
|
|
151
|
+
"outlineOffset--focus": "0",
|
|
152
152
|
// --- The app's default font family
|
|
153
|
-
"
|
|
153
|
+
"fontFamily": "$fontFamily-sans-serif",
|
|
154
154
|
// --- Various font sizes (relative to the current context)
|
|
155
|
-
"
|
|
156
|
-
"
|
|
157
|
-
"
|
|
158
|
-
"
|
|
159
|
-
"
|
|
160
|
-
"
|
|
161
|
-
"
|
|
155
|
+
"fontSize-gigantic": "3rem",
|
|
156
|
+
"fontSize-large": "1.5rem",
|
|
157
|
+
"fontSize-medium": "1.25rem",
|
|
158
|
+
"fontSize-normal": "1rem",
|
|
159
|
+
"fontSize-small": "0.875rem",
|
|
160
|
+
"fontSize-smaller": "0.75rem",
|
|
161
|
+
"fontSize-tiny": "0.625rem",
|
|
162
162
|
// --- The default font size
|
|
163
|
-
"
|
|
163
|
+
"fontSize": "$fontSize-normal",
|
|
164
164
|
// --- Predefined gap sizes
|
|
165
165
|
"gap-none": "$space-0",
|
|
166
166
|
"gap-tight": "$space-2",
|
|
@@ -177,7 +177,7 @@ exports.RootThemeDefinition = {
|
|
|
177
177
|
"space-normal": "$space-4",
|
|
178
178
|
"space-loose": "$space-8",
|
|
179
179
|
// --- Font used for body
|
|
180
|
-
"
|
|
180
|
+
"fontWeight": "$fontWeight-normal",
|
|
181
181
|
// --- Various default values (review them)
|
|
182
182
|
"color-border-dropdown-item": "$color-border",
|
|
183
183
|
// --- Various predefined shadow values
|
|
@@ -191,17 +191,17 @@ exports.RootThemeDefinition = {
|
|
|
191
191
|
// --- The default maximum content width
|
|
192
192
|
"max-content-width": "1320px",
|
|
193
193
|
"size-Icon": "1.25em",
|
|
194
|
-
"
|
|
194
|
+
"boxShadow-Avatar": "inset 0 0 0 1px rgba(4, 32, 69, 0.1)",
|
|
195
195
|
"border-size-Avatar": "0px",
|
|
196
|
-
"
|
|
197
|
-
"
|
|
196
|
+
"borderRadius-Avatar": "4px",
|
|
197
|
+
"boxShadow-header-App": "none",
|
|
198
198
|
// "height-AppHeader": "3.5rem",
|
|
199
|
-
"
|
|
200
|
-
"
|
|
199
|
+
"paddingHorizontal-NavPanel-horizontal": "1rem",
|
|
200
|
+
"paddingVertical-HeaderLogo": "0.7rem",
|
|
201
201
|
"padding-TableCell": ".75rem",
|
|
202
202
|
"padding-TableHeading": ".5rem .75rem .5rem .75rem",
|
|
203
203
|
"color-bg-TableRow--hover": "transparent",
|
|
204
|
-
"
|
|
204
|
+
"boxShadow-NavPanel-vertical": "none",
|
|
205
205
|
"width-NavPanel-vertical": "15rem",
|
|
206
206
|
},
|
|
207
207
|
tones: {
|
|
@@ -9,8 +9,8 @@ exports.SolidThemeDefinition = {
|
|
|
9
9
|
"color-surface": "hsl(0,0%,49%)",
|
|
10
10
|
"color-success": "#45a249",
|
|
11
11
|
"max-content-width": "100%",
|
|
12
|
-
|
|
13
|
-
"
|
|
12
|
+
borderRadius: "0",
|
|
13
|
+
"fontSize": "$fontSize-normal",
|
|
14
14
|
"size-Icon": "1rem",
|
|
15
15
|
}
|
|
16
16
|
};
|
|
@@ -8,9 +8,9 @@ exports.XmlUiThemeDefinition = {
|
|
|
8
8
|
// "font.inter": "https://rsms.me/inter/inter.css",
|
|
9
9
|
},
|
|
10
10
|
themeVars: {
|
|
11
|
-
"
|
|
11
|
+
"boxShadow-header-App": "none",
|
|
12
12
|
"font-size": "15px",
|
|
13
|
-
"
|
|
13
|
+
"boxShadow-Input": "$shadow-sm",
|
|
14
14
|
},
|
|
15
15
|
tones: {
|
|
16
16
|
light: {
|
|
@@ -71,7 +71,7 @@ function generateBaseFontSizes(theme) {
|
|
|
71
71
|
return {};
|
|
72
72
|
}
|
|
73
73
|
const resolvedTheme = resolveThemeVars(theme);
|
|
74
|
-
const base = resolvedTheme["
|
|
74
|
+
const base = resolvedTheme["fontSize"];
|
|
75
75
|
if (!base || typeof base !== "string") {
|
|
76
76
|
return {};
|
|
77
77
|
}
|
|
@@ -87,12 +87,12 @@ function generateBaseFontSizes(theme) {
|
|
|
87
87
|
return {};
|
|
88
88
|
}
|
|
89
89
|
const ret = {};
|
|
90
|
-
ret[`
|
|
91
|
-
ret[`
|
|
92
|
-
ret[`
|
|
93
|
-
ret[`
|
|
94
|
-
ret[`
|
|
95
|
-
ret[`
|
|
90
|
+
ret[`fontSize-large`] = `${1.5 * baseNum}${baseUnit}`;
|
|
91
|
+
ret[`fontSize-medium`] = `${1.25 * baseNum}${baseUnit}`;
|
|
92
|
+
ret[`fontSize-normal`] = base;
|
|
93
|
+
ret[`fontSize-small`] = `${0.875 * baseNum}${baseUnit}`;
|
|
94
|
+
ret[`fontSize-smaller`] = `${0.75 * baseNum}${baseUnit}`;
|
|
95
|
+
ret[`fontSize-tiny`] = `${0.625 * baseNum}${baseUnit}`;
|
|
96
96
|
return ret;
|
|
97
97
|
}
|
|
98
98
|
function generateButtonTones(theme) {
|
|
@@ -142,8 +142,8 @@ function generateButtonTones(theme) {
|
|
|
142
142
|
return ret;
|
|
143
143
|
}
|
|
144
144
|
const paddingRegEx = /^padding-(?!(?:horizontal|vertical|left|right|top|bottom)-)(.+)$/;
|
|
145
|
-
const paddingHorizontalRegEx = /^
|
|
146
|
-
const paddingVerticalRegEx = /^
|
|
145
|
+
const paddingHorizontalRegEx = /^paddingHorizontal-(.+)$/;
|
|
146
|
+
const paddingVerticalRegEx = /^paddingVertical-(.+)$/;
|
|
147
147
|
/**
|
|
148
148
|
* Segment the padding values into top, right, bottom, left to provide consistency
|
|
149
149
|
*/
|
|
@@ -156,21 +156,21 @@ function generatePaddingSegments(theme) {
|
|
|
156
156
|
Object.entries(theme).forEach(([key, value]) => {
|
|
157
157
|
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r, _s, _t, _u, _v;
|
|
158
158
|
var _w, _x, _y, _z, _0, _1, _2, _3, _4, _5, _6, _7, _8, _9, _10, _11, _12, _13, _14, _15;
|
|
159
|
-
// --- Check the "
|
|
159
|
+
// --- Check the "paddingHorizontal" theme variables
|
|
160
160
|
let match = paddingHorizontalRegEx.exec(key);
|
|
161
161
|
if (match) {
|
|
162
|
-
// --- We have a
|
|
163
|
-
const remainder = match[
|
|
164
|
-
(_a = result[_w = `
|
|
165
|
-
(_b = result[_x = `
|
|
162
|
+
// --- We have a paddingHorizontal value to segment
|
|
163
|
+
const remainder = match[1];
|
|
164
|
+
(_a = result[_w = `paddingLeft-${remainder}`]) !== null && _a !== void 0 ? _a : (result[_w] = value);
|
|
165
|
+
(_b = result[_x = `paddingRight-${remainder}`]) !== null && _b !== void 0 ? _b : (result[_x] = value);
|
|
166
166
|
}
|
|
167
|
-
// --- Check the "
|
|
167
|
+
// --- Check the "paddingVertical" theme variables
|
|
168
168
|
match = paddingVerticalRegEx.exec(key);
|
|
169
169
|
if (match) {
|
|
170
|
-
// --- We have a
|
|
171
|
-
const remainder = match[
|
|
172
|
-
(_c = result[_y = `
|
|
173
|
-
(_d = result[_z = `
|
|
170
|
+
// --- We have a paddingVertical value to segment
|
|
171
|
+
const remainder = match[1];
|
|
172
|
+
(_c = result[_y = `paddingTop-${remainder}`]) !== null && _c !== void 0 ? _c : (result[_y] = value);
|
|
173
|
+
(_d = result[_z = `paddingBottom-${remainder}`]) !== null && _d !== void 0 ? _d : (result[_z] = value);
|
|
174
174
|
}
|
|
175
175
|
// --- Check the "padding" theme variables
|
|
176
176
|
match = paddingRegEx.exec(key);
|
|
@@ -178,34 +178,34 @@ function generatePaddingSegments(theme) {
|
|
|
178
178
|
return;
|
|
179
179
|
const remainder = match[1];
|
|
180
180
|
// --- Check for horizontal and vertical padding values
|
|
181
|
-
const horizontal = theme[`
|
|
182
|
-
const vertical = theme[`
|
|
181
|
+
const horizontal = theme[`paddingHorizontal-${remainder}`];
|
|
182
|
+
const vertical = theme[`paddingVertical-${remainder}`];
|
|
183
183
|
// --- We have a padding value to segment
|
|
184
184
|
const segments = value.trim().replace(/ +/g, " ").split(" ");
|
|
185
185
|
switch (segments.length) {
|
|
186
186
|
case 1:
|
|
187
|
-
(_e = result[_0 = `
|
|
188
|
-
(_f = result[_1 = `
|
|
189
|
-
(_g = result[_2 = `
|
|
190
|
-
(_h = result[_3 = `
|
|
187
|
+
(_e = result[_0 = `paddingTop-${remainder}`]) !== null && _e !== void 0 ? _e : (result[_0] = vertical !== null && vertical !== void 0 ? vertical : segments[0]);
|
|
188
|
+
(_f = result[_1 = `paddingRight-${remainder}`]) !== null && _f !== void 0 ? _f : (result[_1] = horizontal !== null && horizontal !== void 0 ? horizontal : segments[0]);
|
|
189
|
+
(_g = result[_2 = `paddingBottom-${remainder}`]) !== null && _g !== void 0 ? _g : (result[_2] = vertical !== null && vertical !== void 0 ? vertical : segments[0]);
|
|
190
|
+
(_h = result[_3 = `paddingLeft-${remainder}`]) !== null && _h !== void 0 ? _h : (result[_3] = horizontal !== null && horizontal !== void 0 ? horizontal : segments[0]);
|
|
191
191
|
break;
|
|
192
192
|
case 2:
|
|
193
|
-
(_j = result[_4 = `
|
|
194
|
-
(_k = result[_5 = `
|
|
195
|
-
(_l = result[_6 = `
|
|
196
|
-
(_m = result[_7 = `
|
|
193
|
+
(_j = result[_4 = `paddingTop-${remainder}`]) !== null && _j !== void 0 ? _j : (result[_4] = vertical !== null && vertical !== void 0 ? vertical : segments[0]);
|
|
194
|
+
(_k = result[_5 = `paddingRight-${remainder}`]) !== null && _k !== void 0 ? _k : (result[_5] = horizontal !== null && horizontal !== void 0 ? horizontal : segments[1]);
|
|
195
|
+
(_l = result[_6 = `paddingBottom-${remainder}`]) !== null && _l !== void 0 ? _l : (result[_6] = vertical !== null && vertical !== void 0 ? vertical : segments[0]);
|
|
196
|
+
(_m = result[_7 = `paddingLeft-${remainder}`]) !== null && _m !== void 0 ? _m : (result[_7] = horizontal !== null && horizontal !== void 0 ? horizontal : segments[1]);
|
|
197
197
|
break;
|
|
198
198
|
case 3:
|
|
199
|
-
(_o = result[_8 = `
|
|
200
|
-
(_p = result[_9 = `
|
|
201
|
-
(_q = result[_10 = `
|
|
202
|
-
(_r = result[_11 = `
|
|
199
|
+
(_o = result[_8 = `paddingTop-${remainder}`]) !== null && _o !== void 0 ? _o : (result[_8] = vertical !== null && vertical !== void 0 ? vertical : segments[0]);
|
|
200
|
+
(_p = result[_9 = `paddingRight-${remainder}`]) !== null && _p !== void 0 ? _p : (result[_9] = horizontal !== null && horizontal !== void 0 ? horizontal : segments[1]);
|
|
201
|
+
(_q = result[_10 = `paddingBottom-${remainder}`]) !== null && _q !== void 0 ? _q : (result[_10] = vertical !== null && vertical !== void 0 ? vertical : segments[2]);
|
|
202
|
+
(_r = result[_11 = `paddingLeft-${remainder}`]) !== null && _r !== void 0 ? _r : (result[_11] = horizontal !== null && horizontal !== void 0 ? horizontal : segments[1]);
|
|
203
203
|
break;
|
|
204
204
|
case 4:
|
|
205
|
-
(_s = result[_12 = `
|
|
206
|
-
(_t = result[_13 = `
|
|
207
|
-
(_u = result[_14 = `
|
|
208
|
-
(_v = result[_15 = `
|
|
205
|
+
(_s = result[_12 = `paddingTop-${remainder}`]) !== null && _s !== void 0 ? _s : (result[_12] = vertical !== null && vertical !== void 0 ? vertical : segments[0]);
|
|
206
|
+
(_t = result[_13 = `paddingRight-${remainder}`]) !== null && _t !== void 0 ? _t : (result[_13] = horizontal !== null && horizontal !== void 0 ? horizontal : segments[1]);
|
|
207
|
+
(_u = result[_14 = `paddingBottom-${remainder}`]) !== null && _u !== void 0 ? _u : (result[_14] = vertical !== null && vertical !== void 0 ? vertical : segments[2]);
|
|
208
|
+
(_v = result[_15 = `paddingLeft-${remainder}`]) !== null && _v !== void 0 ? _v : (result[_15] = horizontal !== null && horizontal !== void 0 ? horizontal : segments[3]);
|
|
209
209
|
break;
|
|
210
210
|
default:
|
|
211
211
|
return;
|
|
@@ -271,7 +271,7 @@ function getScrollParent(element) {
|
|
|
271
271
|
}
|
|
272
272
|
const useScrollParent = (element) => {
|
|
273
273
|
const [scrollParent, setScrollParent] = (0, react_1.useState)(null);
|
|
274
|
-
(0,
|
|
274
|
+
(0, exports.useIsomorphicLayoutEffect)(() => {
|
|
275
275
|
setScrollParent(element ? getScrollParent(element) : null);
|
|
276
276
|
}, [element]);
|
|
277
277
|
return scrollParent;
|
|
@@ -280,7 +280,7 @@ exports.useScrollParent = useScrollParent;
|
|
|
280
280
|
// because safari doesn't support scrollend event...
|
|
281
281
|
const useScrollEventHandler = (element, { onScrollStart, onScrollEnd, }) => {
|
|
282
282
|
const thisRef = (0, react_1.useRef)({ scrolling: false });
|
|
283
|
-
(0,
|
|
283
|
+
(0, exports.useIsomorphicLayoutEffect)(() => {
|
|
284
284
|
let timer;
|
|
285
285
|
let listener = () => {
|
|
286
286
|
if (!thisRef.current.scrolling) {
|