shineout 3.7.7-beta.4 → 3.7.7-beta.6
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/cjs/index.js +1 -1
- package/dist/shineout.js +31 -5
- package/dist/shineout.js.map +1 -1
- package/dist/shineout.min.js +1 -1
- package/dist/shineout.min.js.map +1 -1
- package/esm/index.js +1 -1
- package/package.json +5 -5
package/cjs/index.js
CHANGED
|
@@ -522,5 +522,5 @@ function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { de
|
|
|
522
522
|
// 此文件由脚本自动生成,请勿直接修改。
|
|
523
523
|
// This file was generated automatically by a script. Please do not modify it directly.
|
|
524
524
|
var _default = exports.default = {
|
|
525
|
-
version: '3.7.7-beta.
|
|
525
|
+
version: '3.7.7-beta.6'
|
|
526
526
|
};
|
package/dist/shineout.js
CHANGED
|
@@ -12234,7 +12234,7 @@ var handleStyle = function handleStyle(style) {
|
|
|
12234
12234
|
};
|
|
12235
12235
|
/* harmony default export */ var jss_style_handleStyle = (handleStyle);
|
|
12236
12236
|
;// CONCATENATED MODULE: ../shineout-style/src/version.ts
|
|
12237
|
-
/* harmony default export */ var version = ('3.7.7-beta.
|
|
12237
|
+
/* harmony default export */ var version = ('3.7.7-beta.6');
|
|
12238
12238
|
;// CONCATENATED MODULE: ../shineout-style/src/jss-style/index.tsx
|
|
12239
12239
|
|
|
12240
12240
|
|
|
@@ -61759,7 +61759,8 @@ var scroll_table_Scroll = function Scroll(props) {
|
|
|
61759
61759
|
var wrapperRef = useForkRef(scrollRef, props.wrapperRef);
|
|
61760
61760
|
var _useRef = (0,external_root_React_commonjs2_react_commonjs_react_amd_react_.useRef)({
|
|
61761
61761
|
isMouseDown: false,
|
|
61762
|
-
lastTableHeight: 0
|
|
61762
|
+
lastTableHeight: 0,
|
|
61763
|
+
unmounted: false
|
|
61763
61764
|
}),
|
|
61764
61765
|
context = _useRef.current;
|
|
61765
61766
|
var _props$scrollHeight = props.scrollHeight,
|
|
@@ -61868,7 +61869,7 @@ var scroll_table_Scroll = function Scroll(props) {
|
|
|
61868
61869
|
|
|
61869
61870
|
// 非定高的Table但依旧采用了virtual渲染方式,需要渲染出全部的data
|
|
61870
61871
|
(0,external_root_React_commonjs2_react_commonjs_react_amd_react_.useLayoutEffect)(function () {
|
|
61871
|
-
if (!props.tableRef.current) return;
|
|
61872
|
+
if (!props.tableRef.current || context.unmounted) return;
|
|
61872
61873
|
var rootTableHeight = props.tableRef.current.clientHeight;
|
|
61873
61874
|
var container = containerRef.current;
|
|
61874
61875
|
// 判断内容滚动高度是否真的超过了容器高度
|
|
@@ -61880,6 +61881,9 @@ var scroll_table_Scroll = function Scroll(props) {
|
|
|
61880
61881
|
} else {
|
|
61881
61882
|
context.lastTableHeight = rootTableHeight;
|
|
61882
61883
|
}
|
|
61884
|
+
return function () {
|
|
61885
|
+
context.unmounted = true;
|
|
61886
|
+
};
|
|
61883
61887
|
}, [paddingTop]);
|
|
61884
61888
|
if (props.isEmpty) {
|
|
61885
61889
|
return /*#__PURE__*/(0,jsx_runtime.jsxs)("div", objectSpread2_default()(objectSpread2_default()({}, scrollRoleProps), {}, {
|
|
@@ -64905,7 +64909,7 @@ var emptyRef = {
|
|
|
64905
64909
|
onChange: inputableData.onChange,
|
|
64906
64910
|
disabled: props.disabled
|
|
64907
64911
|
});
|
|
64908
|
-
(
|
|
64912
|
+
var handleTheadAndTfootHeight = usePersistFn(function () {
|
|
64909
64913
|
var _theadRef$current, _tfootRef$current;
|
|
64910
64914
|
var theadHeight = (theadRef === null || theadRef === void 0 || (_theadRef$current = theadRef.current) === null || _theadRef$current === void 0 ? void 0 : _theadRef$current.clientHeight) || 0;
|
|
64911
64915
|
var tfootHeight = ((_tfootRef$current = tfootRef.current) === null || _tfootRef$current === void 0 ? void 0 : _tfootRef$current.clientHeight) || 0;
|
|
@@ -64914,6 +64918,28 @@ var emptyRef = {
|
|
|
64914
64918
|
} else {
|
|
64915
64919
|
context.theadAndTfootHeight = theadHeight + tfootHeight;
|
|
64916
64920
|
}
|
|
64921
|
+
});
|
|
64922
|
+
(0,external_root_React_commonjs2_react_commonjs_react_amd_react_.useEffect)(function () {
|
|
64923
|
+
handleTheadAndTfootHeight();
|
|
64924
|
+
var cancelFunc1;
|
|
64925
|
+
if (theadRef !== null && theadRef !== void 0 && theadRef.current) {
|
|
64926
|
+
cancelFunc1 = addResizeObserver(theadRef === null || theadRef === void 0 ? void 0 : theadRef.current, handleTheadAndTfootHeight, {
|
|
64927
|
+
direction: 'y',
|
|
64928
|
+
timer: 10
|
|
64929
|
+
});
|
|
64930
|
+
}
|
|
64931
|
+
var cancelFunc2;
|
|
64932
|
+
if (tfootRef !== null && tfootRef !== void 0 && tfootRef.current) {
|
|
64933
|
+
cancelFunc2 = addResizeObserver(tfootRef === null || tfootRef === void 0 ? void 0 : tfootRef.current, handleTheadAndTfootHeight, {
|
|
64934
|
+
direction: 'y',
|
|
64935
|
+
timer: 10
|
|
64936
|
+
});
|
|
64937
|
+
}
|
|
64938
|
+
return function () {
|
|
64939
|
+
var _cancelFunc, _cancelFunc2;
|
|
64940
|
+
(_cancelFunc = cancelFunc1) === null || _cancelFunc === void 0 || _cancelFunc();
|
|
64941
|
+
(_cancelFunc2 = cancelFunc2) === null || _cancelFunc2 === void 0 || _cancelFunc2();
|
|
64942
|
+
};
|
|
64917
64943
|
}, [theadRef.current, tfootRef.current]);
|
|
64918
64944
|
var virtualInfo = use_table_virtual({
|
|
64919
64945
|
disabled: !virtual,
|
|
@@ -71775,7 +71801,7 @@ var upload_interface = __webpack_require__(8821);
|
|
|
71775
71801
|
|
|
71776
71802
|
|
|
71777
71803
|
/* harmony default export */ var src_0 = ({
|
|
71778
|
-
version: '3.7.7-beta.
|
|
71804
|
+
version: '3.7.7-beta.6'
|
|
71779
71805
|
});
|
|
71780
71806
|
}();
|
|
71781
71807
|
/******/ return __webpack_exports__;
|