fix: json stream data is truncated

This commit is contained in:
jialin
2025-01-20 22:08:08 +08:00
parent f94fcf58a7
commit db733ac9ce
7 changed files with 54 additions and 22 deletions
@@ -196,7 +196,7 @@ const TableRow: React.FC<
const handleVisibilityChange = async () => {
if (document.visibilityState === 'hidden') {
cacheDataListRef.current = [];
setChildrenData([]);
// setChildrenData([]);
}
};
@@ -295,7 +295,13 @@ const TableRow: React.FC<
{childrenData.length ? (
renderChildrenData()
) : (
<Empty image={Empty.PRESENTED_IMAGE_SIMPLE}></Empty>
<Empty
image={Empty.PRESENTED_IMAGE_SIMPLE}
style={{
marginBlock: 0,
height: 54
}}
></Empty>
)}
</Spin>
</div>
+2 -1
View File
@@ -26,6 +26,7 @@ const SealTable: React.FC<SealTableProps & { pagination: PaginationProps }> = (
onCell,
expandedRowKeys,
loading,
loadend,
expandable,
pollingChildren,
watchChildren,
@@ -117,7 +118,7 @@ const SealTable: React.FC<SealTableProps & { pagination: PaginationProps }> = (
if (!props.dataSource.length) {
return (
<div className="empty-wrapper">
<Empty image={Empty.PRESENTED_IMAGE_SIMPLE}></Empty>
<Empty image={loadend ? Empty.PRESENTED_IMAGE_SIMPLE : null}></Empty>
</div>
);
}
@@ -39,6 +39,10 @@
border-top: 0;
border-radius: 0 0 var(--ant-table-header-border-radius)
var(--ant-table-header-border-radius);
.ant-empty-image {
height: 30px;
}
}
.row-wrapper {
+1
View File
@@ -49,6 +49,7 @@ export interface SealTableProps {
pollingChildren?: boolean;
watchChildren?: boolean;
loading?: boolean;
loadend?: boolean;
onCell?: (record: any, dataIndex: string) => void;
onSort?: (dataIndex: string, order: 'ascend' | 'descend') => void;
onExpand?: (expanded: boolean, record: any, rowKey: any) => void;