修复表格滚动高度

This commit is contained in:
whyour
2021-10-31 19:45:51 +08:00
parent 021d89379a
commit b92daedea2
3 changed files with 6 additions and 12 deletions
+2 -4
View File
@@ -367,8 +367,7 @@ const Env = ({ headerStyle, isPhone, theme }: any) => {
setTimeout(() => {
if (selectedRowIds.length === 0 || selectedIds.length === 0) {
const offset = isPhone ? 40 : 0;
setTableScrollHeight(getTableScroll({ extraHeight: 87 }) - offset);
setTableScrollHeight(getTableScroll({ extraHeight: 87 }));
}
});
};
@@ -437,9 +436,8 @@ const Env = ({ headerStyle, isPhone, theme }: any) => {
}, [searchText]);
useEffect(() => {
const offset = isPhone ? 40 : 0;
setTimeout(() => {
setTableScrollHeight(getTableScroll({ extraHeight: 87 }) - offset);
setTableScrollHeight(getTableScroll({ extraHeight: 87 }));
});
}, []);