intelicoreact 0.0.99 → 0.1.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.
|
@@ -186,11 +186,14 @@ var Dropdown = function Dropdown(_ref) {
|
|
|
186
186
|
})) === null || _item$items4$find === void 0 ? void 0 : _item$items4$find.label);
|
|
187
187
|
}, null);
|
|
188
188
|
var doScrollCallback = (0, _react.useCallback)(function (e) {
|
|
189
|
-
var
|
|
190
|
-
|
|
189
|
+
var _ref2 = scrollReactionObj || {},
|
|
190
|
+
callback = _ref2.callback,
|
|
191
|
+
isWithAnyScrolling = _ref2.isWithAnyScrolling,
|
|
192
|
+
_ref2$scrollingInaccu = _ref2.scrollingInaccuracy,
|
|
193
|
+
scrollingInaccuracy = _ref2$scrollingInaccu === void 0 ? 0 : _ref2$scrollingInaccu;
|
|
191
194
|
|
|
192
195
|
if (callback && typeof callback === 'function') {
|
|
193
|
-
if (isWithAnyScrolling) callback(e);else if (e.target.clientHeight + e.target.scrollTop >= e.target.scrollHeight) callback(e);
|
|
196
|
+
if (isWithAnyScrolling) callback(e);else if (Math.round(e.target.clientHeight + e.target.scrollTop + scrollingInaccuracy) >= e.target.scrollHeight) callback(e);
|
|
194
197
|
}
|
|
195
198
|
}, [filteredOptions]);
|
|
196
199
|
(0, _react.useEffect)(function () {
|