@true-engineering/true-react-common-ui-kit 3.0.0-alpha.10 → 3.0.0-alpha.12
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.
|
@@ -22297,6 +22297,7 @@
|
|
|
22297
22297
|
currentComponentName: "FlexibleTable"
|
|
22298
22298
|
});
|
|
22299
22299
|
var _useState = _sliced_to_array$8(React.useState(false), 2), isHorizontallyScrolled = _useState[0], setIsHorizontallyScrolled = _useState[1];
|
|
22300
|
+
var _useState1 = _sliced_to_array$8(React.useState(false), 2), hasScrollBar = _useState1[0], setHasScrollBar = _useState1[1];
|
|
22300
22301
|
var observer = React.useRef();
|
|
22301
22302
|
var scrollRef = React.useRef(null);
|
|
22302
22303
|
var ref = refForScroll !== null && refForScroll !== void 0 ? refForScroll : scrollRef;
|
|
@@ -22327,6 +22328,7 @@
|
|
|
22327
22328
|
if (scrollContainer === null || !isHorizontallyScrollable || !isFirstColumnSticky) {
|
|
22328
22329
|
return;
|
|
22329
22330
|
}
|
|
22331
|
+
setHasScrollBar(hasHorizontalScrollBar(scrollContainer));
|
|
22330
22332
|
var scrollHandler = function(e) {
|
|
22331
22333
|
setIsHorizontallyScrolled(e.target.scrollLeft > 0);
|
|
22332
22334
|
};
|
|
@@ -22335,7 +22337,7 @@
|
|
|
22335
22337
|
return scrollContainer.removeEventListener("scroll", scrollHandler);
|
|
22336
22338
|
};
|
|
22337
22339
|
}, [
|
|
22338
|
-
|
|
22340
|
+
ref
|
|
22339
22341
|
]);
|
|
22340
22342
|
var _activeRows_includes;
|
|
22341
22343
|
return /* @__PURE__ */ jsx("div", _object_spread_props$e(_object_spread$f({
|
|
@@ -22343,7 +22345,7 @@
|
|
|
22343
22345
|
className: clsx(_define_property$g({}, classes.scroll, isHorizontallyScrollable))
|
|
22344
22346
|
}, addDataAttributes({
|
|
22345
22347
|
scrolled: isHorizontallyScrolled ? true : void 0,
|
|
22346
|
-
scrollable: isHorizontallyScrollable &&
|
|
22348
|
+
scrollable: isHorizontallyScrollable && hasScrollBar ? true : void 0
|
|
22347
22349
|
})), {
|
|
22348
22350
|
children: /* @__PURE__ */ jsxs("table", _object_spread_props$e(_object_spread$f({
|
|
22349
22351
|
className: classes.root
|