@hw-component/table 1.9.70 → 1.9.72
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/es/HTableBody/index.js +5 -1
- package/es/render/TagsComponent.d.ts +1 -0
- package/es/render/TagsComponent.js +3 -2
- package/lib/HTableBody/index.js +5 -1
- package/lib/render/TagsComponent.d.ts +1 -0
- package/lib/render/TagsComponent.js +3 -2
- package/package.json +1 -1
- package/src/components/HTableBody/index.tsx +1 -2
- package/src/components/render/TagsComponent.tsx +4 -1
package/es/HTableBody/index.js
CHANGED
|
@@ -167,7 +167,11 @@ var Body = (function (bodyProps) {
|
|
|
167
167
|
rowKey: rowKey,
|
|
168
168
|
dataSource: records,
|
|
169
169
|
pagination: false
|
|
170
|
-
})), pagination
|
|
170
|
+
})), pagination === false ? jsx("div", {
|
|
171
|
+
style: {
|
|
172
|
+
paddingBottom: 24
|
|
173
|
+
}
|
|
174
|
+
}) : jsx(HTablePagination, _objectSpread({
|
|
171
175
|
onPageChange: onPageChange,
|
|
172
176
|
paginationStyle: paginationStyle,
|
|
173
177
|
affixProps: affixProps,
|
|
@@ -17,6 +17,7 @@ interface IProps {
|
|
|
17
17
|
maxLen?: number | null;
|
|
18
18
|
popoverContentRender?: (node: React.ReactNode) => React.ReactNode;
|
|
19
19
|
contentItemRender?: (item: any) => React.ReactNode;
|
|
20
|
+
extra?: React.ReactNode;
|
|
20
21
|
}
|
|
21
22
|
declare const TagsComponent: (props: IProps) => JSX.Element;
|
|
22
23
|
export default TagsComponent;
|
|
@@ -48,7 +48,8 @@ var TagsComponent = function TagsComponent(props) {
|
|
|
48
48
|
tooltip = props.tooltip,
|
|
49
49
|
tableInstance = props.tableInstance,
|
|
50
50
|
maxLen = props.maxLen,
|
|
51
|
-
popoverContentRender = props.popoverContentRender
|
|
51
|
+
popoverContentRender = props.popoverContentRender,
|
|
52
|
+
extra = props.extra;
|
|
52
53
|
var _fieldNames$label = fieldNames.label,
|
|
53
54
|
label = _fieldNames$label === void 0 ? "label" : _fieldNames$label,
|
|
54
55
|
_fieldNames$value = fieldNames.value,
|
|
@@ -118,7 +119,7 @@ var TagsComponent = function TagsComponent(props) {
|
|
|
118
119
|
children: jsxs(Tag, {
|
|
119
120
|
children: ["...\u7B49", data.length, "\u4E2A"]
|
|
120
121
|
})
|
|
121
|
-
})]
|
|
122
|
+
}), extra]
|
|
122
123
|
});
|
|
123
124
|
};
|
|
124
125
|
|
package/lib/HTableBody/index.js
CHANGED
|
@@ -170,7 +170,11 @@ var Body = (function (bodyProps) {
|
|
|
170
170
|
rowKey: rowKey,
|
|
171
171
|
dataSource: records,
|
|
172
172
|
pagination: false
|
|
173
|
-
})), pagination
|
|
173
|
+
})), pagination === false ? jsxRuntime.jsx("div", {
|
|
174
|
+
style: {
|
|
175
|
+
paddingBottom: 24
|
|
176
|
+
}
|
|
177
|
+
}) : jsxRuntime.jsx(index$3.default, _objectSpread({
|
|
174
178
|
onPageChange: onPageChange,
|
|
175
179
|
paginationStyle: paginationStyle,
|
|
176
180
|
affixProps: affixProps,
|
|
@@ -17,6 +17,7 @@ interface IProps {
|
|
|
17
17
|
maxLen?: number | null;
|
|
18
18
|
popoverContentRender?: (node: React.ReactNode) => React.ReactNode;
|
|
19
19
|
contentItemRender?: (item: any) => React.ReactNode;
|
|
20
|
+
extra?: React.ReactNode;
|
|
20
21
|
}
|
|
21
22
|
declare const TagsComponent: (props: IProps) => JSX.Element;
|
|
22
23
|
export default TagsComponent;
|
|
@@ -51,7 +51,8 @@ var TagsComponent = function TagsComponent(props) {
|
|
|
51
51
|
tooltip = props.tooltip,
|
|
52
52
|
tableInstance = props.tableInstance,
|
|
53
53
|
maxLen = props.maxLen,
|
|
54
|
-
popoverContentRender = props.popoverContentRender
|
|
54
|
+
popoverContentRender = props.popoverContentRender,
|
|
55
|
+
extra = props.extra;
|
|
55
56
|
var _fieldNames$label = fieldNames.label,
|
|
56
57
|
label = _fieldNames$label === void 0 ? "label" : _fieldNames$label,
|
|
57
58
|
_fieldNames$value = fieldNames.value,
|
|
@@ -121,7 +122,7 @@ var TagsComponent = function TagsComponent(props) {
|
|
|
121
122
|
children: jsxRuntime.jsxs(antd.Tag, {
|
|
122
123
|
children: ["...\u7B49", data.length, "\u4E2A"]
|
|
123
124
|
})
|
|
124
|
-
})]
|
|
125
|
+
}), extra]
|
|
125
126
|
});
|
|
126
127
|
};
|
|
127
128
|
|
package/package.json
CHANGED
|
@@ -100,7 +100,6 @@ export default (bodyProps: HTableBodyProps) => {
|
|
|
100
100
|
table: tableInstance,
|
|
101
101
|
localSorter,
|
|
102
102
|
});
|
|
103
|
-
|
|
104
103
|
return (
|
|
105
104
|
<div style={defaultTableStyle} className={`hw_table_body ${className}`}>
|
|
106
105
|
<Space size={16} direction={"vertical"} style={{ width: "100%" }}>
|
|
@@ -140,7 +139,7 @@ export default (bodyProps: HTableBodyProps) => {
|
|
|
140
139
|
dataSource={records}
|
|
141
140
|
pagination={false}
|
|
142
141
|
/>
|
|
143
|
-
{pagination
|
|
142
|
+
{pagination === false?<div style={{paddingBottom:24}}/>:(
|
|
144
143
|
<HTablePagination
|
|
145
144
|
onPageChange={onPageChange}
|
|
146
145
|
paginationStyle={paginationStyle}
|
|
@@ -15,6 +15,7 @@ interface IProps {
|
|
|
15
15
|
maxLen?: number | null;
|
|
16
16
|
popoverContentRender?:(node:React.ReactNode)=>React.ReactNode;
|
|
17
17
|
contentItemRender?:(item:any)=>React.ReactNode;
|
|
18
|
+
extra?:React.ReactNode;
|
|
18
19
|
}
|
|
19
20
|
const getTooltipProps = (
|
|
20
21
|
title: string,
|
|
@@ -46,7 +47,8 @@ const TagsComponent = (props: IProps) => {
|
|
|
46
47
|
tooltip,
|
|
47
48
|
tableInstance,
|
|
48
49
|
maxLen,
|
|
49
|
-
popoverContentRender
|
|
50
|
+
popoverContentRender,
|
|
51
|
+
extra
|
|
50
52
|
} = props;
|
|
51
53
|
const { label = "label", value = "value" } = fieldNames;
|
|
52
54
|
const { tagData, moreTag } = useMemo(() => {
|
|
@@ -118,6 +120,7 @@ const TagsComponent = (props: IProps) => {
|
|
|
118
120
|
<Tag>...等{data.length}个</Tag>
|
|
119
121
|
</Popover>
|
|
120
122
|
)}
|
|
123
|
+
{extra}
|
|
121
124
|
</Row>
|
|
122
125
|
);
|
|
123
126
|
};
|