fix: the height of the subtable in the form is set along with the mai… (#6518)

* fix: the height of the subtable in the form is set along with the main form height

* fix: bug
This commit is contained in:
Katherine 2025-03-20 23:17:33 +08:00 committed by GitHub
parent a2002d8329
commit f82e426daa
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 4 additions and 8 deletions

View File

@ -602,12 +602,6 @@ const InternalNocoBaseTable = React.memo(
height: 100%;
display: flex;
flex-direction: column;
.ant-table-expanded-row-fixed {
min-height: ${tableHeight}px;
}
.ant-table-body {
min-height: ${tableHeight}px;
}
.ant-table-cell {
padding: 16px 8px;
}

View File

@ -37,7 +37,9 @@ const getPageHeaderHeight = (disablePageHeader, enablePageTabs, hidePageTitle, t
token.paddingContentHorizontalLG
);
}
return token.controlHeight + token.marginXS + (token.paddingXXS + 2) * 2 + token.paddingContentHorizontalLG;
return (
token.controlHeight + token.marginXS + (token.paddingContentVertical + 2) * 2 + token.paddingContentHorizontalLG
);
} else {
if (enablePageTabs) {
return (
@ -140,12 +142,12 @@ export const useDataBlockHeight = (options?: UseDataBlockHeightOptions) => {
const { heightMode, height, title, titleHeight } = heightProps || {};
const blockHeaderHeight = title ? titleHeight : 0;
if (!heightProps?.heightMode || heightMode === HeightMode.DEFAULT) {
return;
}
if (heightMode === HeightMode.FULL_HEIGHT) {
let res = window.innerHeight - pageFullScreenHeight;
console.log(res);
if (options?.removeBlockHeaderHeight) {
res = res - blockHeaderHeight;
}