intelicoreact 0.2.30 → 0.2.31
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.
|
@@ -106,8 +106,11 @@ var AccordionTable = function AccordionTable(_ref) {
|
|
|
106
106
|
}, row.label)), /*#__PURE__*/_react.default.createElement("div", null, row.titleContent));
|
|
107
107
|
};
|
|
108
108
|
|
|
109
|
+
(0, _react.useEffect)(function () {
|
|
110
|
+
setAccordions(rows);
|
|
111
|
+
}, [rows]);
|
|
109
112
|
return /*#__PURE__*/_react.default.createElement("div", {
|
|
110
|
-
className: (0, _classnames.default)('accordion-table')
|
|
113
|
+
className: (0, _classnames.default)('accordion-table', className)
|
|
111
114
|
}, /*#__PURE__*/_react.default.createElement("div", {
|
|
112
115
|
className: "accordion-table__header"
|
|
113
116
|
}, header === null || header === void 0 ? void 0 : header.map(function (item) {
|
|
@@ -216,18 +216,26 @@ var NavLine = function NavLine(_ref) {
|
|
|
216
216
|
var onWheel = function onWheel(e) {
|
|
217
217
|
e.preventDefault();
|
|
218
218
|
e.stopPropagation();
|
|
219
|
-
var deltaY = e.deltaY
|
|
220
|
-
|
|
219
|
+
var deltaY = e.deltaY,
|
|
220
|
+
shiftKey = e.shiftKey;
|
|
221
|
+
|
|
222
|
+
if (shiftKey) {
|
|
223
|
+
if (deltaY > 0) pushScrollTask('next');else pushScrollTask('prev');
|
|
224
|
+
}
|
|
221
225
|
};
|
|
222
226
|
|
|
223
227
|
var onTabChange = function onTabChange(item) {
|
|
224
228
|
onChange(item.tabId);
|
|
225
|
-
};
|
|
226
|
-
// if (!wrapperRef?.current) return false;
|
|
227
|
-
// wrapperRef?.current?.addEventListener("mousewheel", onWheel, { passive: false });
|
|
228
|
-
// }, [wrapperRef]);
|
|
229
|
-
// Count Total NavLine Items Width
|
|
229
|
+
};
|
|
230
230
|
|
|
231
|
+
(0, _react.useEffect)(function () {
|
|
232
|
+
var _wrapperRef$current;
|
|
233
|
+
|
|
234
|
+
if (!(wrapperRef !== null && wrapperRef !== void 0 && wrapperRef.current)) return false;
|
|
235
|
+
wrapperRef === null || wrapperRef === void 0 ? void 0 : (_wrapperRef$current = wrapperRef.current) === null || _wrapperRef$current === void 0 ? void 0 : _wrapperRef$current.addEventListener("mousewheel", onWheel, {
|
|
236
|
+
passive: false
|
|
237
|
+
});
|
|
238
|
+
}, [wrapperRef]); // Count Total NavLine Items Width
|
|
231
239
|
|
|
232
240
|
(0, _react.useEffect)(function () {
|
|
233
241
|
var _navLineItems$0$ref$c, _navLineItems$, _navLineItems$$ref, _navLineItems$$ref$cu;
|
|
@@ -251,9 +259,9 @@ var NavLine = function NavLine(_ref) {
|
|
|
251
259
|
}, [navLineItems === null || navLineItems === void 0 ? void 0 : navLineItems.length]); // Count Wrapper Width
|
|
252
260
|
|
|
253
261
|
(0, _react.useEffect)(function () {
|
|
254
|
-
var _wrapperRef$current$g, _wrapperRef$
|
|
262
|
+
var _wrapperRef$current$g, _wrapperRef$current2, _wrapperRef$current2$;
|
|
255
263
|
|
|
256
|
-
setWrapperRefWidth((_wrapperRef$current$g = wrapperRef === null || wrapperRef === void 0 ? void 0 : (_wrapperRef$
|
|
264
|
+
setWrapperRefWidth((_wrapperRef$current$g = wrapperRef === null || wrapperRef === void 0 ? void 0 : (_wrapperRef$current2 = wrapperRef.current) === null || _wrapperRef$current2 === void 0 ? void 0 : (_wrapperRef$current2$ = _wrapperRef$current2.getBoundingClientRect()) === null || _wrapperRef$current2$ === void 0 ? void 0 : _wrapperRef$current2$.width) !== null && _wrapperRef$current$g !== void 0 ? _wrapperRef$current$g : 0);
|
|
257
265
|
}, [wrapperRef]); //Init NavLine Items
|
|
258
266
|
|
|
259
267
|
(0, _react.useEffect)(function () {
|