@hw-component/table 1.9.86 → 1.9.88
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/.eslintcache +1 -1
- package/es/HTableBody/Options/utils.d.ts +5 -2
- package/es/HTableBody/RowCheckBox/RowItem.d.ts +2 -8
- package/es/HTableBody/RowCheckBox/hooks.d.ts +2 -2
- package/es/HTableBody/RowRadioBoxSelection.d.ts +1 -8
- package/es/HTableBody/hooks/useRowClassName.d.ts +4 -0
- package/es/HTableBody/hooks/useRowClassName.js +39 -0
- package/es/HTableBody/index.js +8 -25
- package/es/HTableBody/modal.d.ts +7 -1
- package/es/HTableBody/utils.d.ts +1 -0
- package/es/HTableHeader/RangePickerSearch.d.ts +1 -1
- package/es/TableConfig.d.ts +2 -0
- package/es/TableConfig.js +4 -2
- package/es/modal.d.ts +2 -1
- package/es/render/Text.d.ts +0 -1
- package/lib/HTableBody/Options/utils.d.ts +5 -2
- package/lib/HTableBody/RowCheckBox/RowItem.d.ts +2 -8
- package/lib/HTableBody/RowCheckBox/hooks.d.ts +2 -2
- package/lib/HTableBody/RowRadioBoxSelection.d.ts +1 -8
- package/lib/HTableBody/hooks/useRowClassName.d.ts +4 -0
- package/lib/HTableBody/hooks/useRowClassName.js +42 -0
- package/lib/HTableBody/index.js +7 -24
- package/lib/HTableBody/modal.d.ts +7 -1
- package/lib/HTableBody/utils.d.ts +1 -0
- package/lib/HTableHeader/RangePickerSearch.d.ts +1 -1
- package/lib/TableConfig.d.ts +2 -0
- package/lib/TableConfig.js +4 -2
- package/lib/modal.d.ts +2 -1
- package/lib/render/Text.d.ts +0 -1
- package/package.json +1 -1
- package/src/components/HTableBody/RowCheckBox/RowItem.tsx +2 -8
- package/src/components/HTableBody/RowCheckBox/hooks.ts +2 -2
- package/src/components/HTableBody/RowRadioBoxSelection.tsx +1 -7
- package/src/components/HTableBody/hooks/useRowClassName.ts +33 -0
- package/src/components/HTableBody/index.tsx +3 -21
- package/src/components/HTableBody/modal.ts +8 -1
- package/src/components/HTableBody/utils.ts +5 -0
- package/src/components/TableConfig.tsx +3 -0
- package/src/components/hooks/useRowObj.ts +1 -1
- package/src/components/modal.ts +6 -1
- package/src/pages/Table/index.tsx +62 -60
|
@@ -121,38 +121,47 @@ export default () => {
|
|
|
121
121
|
>
|
|
122
122
|
获取
|
|
123
123
|
</div>
|
|
124
|
-
<
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
<
|
|
124
|
+
<HTableConfig defaultSelectedRowClassName={null}>
|
|
125
|
+
<HTable
|
|
126
|
+
configData={configData}
|
|
127
|
+
rowKey={(rowData, index) => {
|
|
128
|
+
return index;
|
|
129
|
+
}}
|
|
130
|
+
table={hTable}
|
|
131
|
+
labelWidth={88}
|
|
132
|
+
action={{
|
|
133
|
+
test: (params) => {
|
|
134
|
+
console.log(params, "lllll");
|
|
135
|
+
},
|
|
136
|
+
}}
|
|
137
|
+
rowSelection={{
|
|
138
|
+
preserveSelectedRowKeys: true,
|
|
139
|
+
}}
|
|
140
|
+
affixProps={{
|
|
141
|
+
target: () => document.querySelector(".body"),
|
|
142
|
+
}}
|
|
143
|
+
scroll={{
|
|
144
|
+
x: 1000,
|
|
145
|
+
}}
|
|
146
|
+
columnsState={{
|
|
147
|
+
persistenceKey: "test",
|
|
148
|
+
persistenceType: "localStorage",
|
|
149
|
+
}}
|
|
150
|
+
formInitValues={{
|
|
151
|
+
deviceType: "1",
|
|
152
|
+
}}
|
|
153
|
+
dataSource={[{}, {}, {}]}
|
|
154
|
+
headerTitle={
|
|
155
|
+
<Space size={8}>
|
|
156
|
+
<div style={{ width: 1000 }}>
|
|
157
|
+
<Button
|
|
158
|
+
onClick={() => {
|
|
159
|
+
console.log(hTable.table.getColSettingKeys());
|
|
160
|
+
}}
|
|
161
|
+
>
|
|
162
|
+
操作
|
|
163
|
+
</Button>
|
|
164
|
+
</div>
|
|
156
165
|
<Button
|
|
157
166
|
onClick={() => {
|
|
158
167
|
console.log(hTable.table.getColSettingKeys());
|
|
@@ -160,34 +169,27 @@ export default () => {
|
|
|
160
169
|
>
|
|
161
170
|
操作
|
|
162
171
|
</Button>
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
</
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
<SettingOutlined width={24} />
|
|
185
|
-
</Tooltip>
|
|
186
|
-
);
|
|
187
|
-
},
|
|
188
|
-
}}
|
|
189
|
-
pagination={false}
|
|
190
|
-
/>
|
|
172
|
+
<Button
|
|
173
|
+
onClick={() => {
|
|
174
|
+
console.log(hTable.table.getColSettingKeys());
|
|
175
|
+
}}
|
|
176
|
+
>
|
|
177
|
+
操作
|
|
178
|
+
</Button>
|
|
179
|
+
</Space>
|
|
180
|
+
}
|
|
181
|
+
options={{
|
|
182
|
+
settingRender: () => {
|
|
183
|
+
return (
|
|
184
|
+
<Tooltip title="321312312312321">
|
|
185
|
+
<SettingOutlined width={24} />
|
|
186
|
+
</Tooltip>
|
|
187
|
+
);
|
|
188
|
+
},
|
|
189
|
+
}}
|
|
190
|
+
pagination={false}
|
|
191
|
+
/>
|
|
192
|
+
</HTableConfig>
|
|
191
193
|
</div>
|
|
192
194
|
</HFormConfigProvider>
|
|
193
195
|
);
|