dcp-design-react 1.11.24 → 1.12.0
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/lib/collapse/style/index.less +24 -24
- package/lib/collapse/style/motion.less +11 -11
- package/lib/color-picker/style/index.less +119 -119
- package/lib/index.esm.js +1 -1
- package/lib/index.full.js +1 -1
- package/lib/index.js +1 -1
- package/lib/locale/lang/en.d.ts +7 -6
- package/lib/locale/lang/en.js +14 -13
- package/lib/locale/lang/zh-cn.d.ts +7 -6
- package/lib/locale/lang/zh-cn.js +14 -13
- package/lib/pivot-grid/style/context-menu.less +28 -28
- package/lib/pivot-grid/style/grid-layout.less +409 -409
- package/lib/pivot-grid/style/index.less +11 -11
- package/lib/pivot-grid/style/main.less +33 -33
- package/lib/pivot-grid/style/top-bar.less +189 -189
- package/lib/scrollbar/style/index.less +1 -2
- package/lib/search-tree/style/index.less +34 -34
- package/lib/style/index.css +102 -13
- package/lib/style/index.less +44 -44
- package/lib/style/index.min.css +1 -1
- package/lib/table/src/context/index.d.ts +6 -1
- package/lib/table/src/filter/CheckboxPanel.d.ts +7 -0
- package/lib/table/src/filter/DatePanel.d.ts +7 -0
- package/lib/table/src/filter/FooterPanel.d.ts +12 -0
- package/lib/table/src/filter/ListPanel.d.ts +11 -0
- package/lib/table/src/filter/NilPanel.d.ts +9 -0
- package/lib/table/src/filter/NumberPanel.d.ts +7 -0
- package/lib/table/src/filter/TextAreaPanel.d.ts +7 -0
- package/lib/table/src/filter/TextPanel.d.ts +7 -0
- package/lib/table/src/filter/TreePanel.d.ts +7 -0
- package/lib/table/src/filter/context.d.ts +3 -0
- package/lib/table/src/filter-sql/index.d.ts +1 -1
- package/lib/table/src/filter-sql/lib/filter_string.d.ts +1 -3
- package/lib/table/src/hooks/useImperativeMethod.d.ts +1 -0
- package/lib/table/src/hooks/useTableCore.d.ts +9 -5
- package/lib/table/src/hooks/useTableRef.d.ts +4 -9
- package/lib/table/src/hooks/useTableState.d.ts +4 -1
- package/lib/table/src/table/props.d.ts +1 -0
- package/lib/table/src/table/types.d.ts +6 -1
- package/lib/table/src/utils/index.d.ts +4 -1
- package/lib/table/style/body.less +1 -0
- package/lib/table/style/fast-search.less +151 -150
- package/lib/table/style/header.less +108 -10
- package/lib/table/style/variable.less +51 -51
- package/lib/virtual-list/src/core.d.ts +4 -5
- package/lib/virtual-list/src/useVirtual.d.ts +2 -2
- package/lib/virtual-list/src/utils.d.ts +1 -2
- package/lib/virtual-list/style/index.less +22 -22
- package/package.json +1 -1
|
@@ -1,150 +1,151 @@
|
|
|
1
|
-
/*
|
|
2
|
-
* @Author: 焦质晔
|
|
3
|
-
* @Date: 2022-03-16 19:05:30
|
|
4
|
-
* @Last Modified by: 焦质晔
|
|
5
|
-
* @Last Modified time: 2022-11-26 21:11:04
|
|
6
|
-
*/
|
|
7
|
-
.@{prefix-table}-fast-search {
|
|
8
|
-
display: inline-block;
|
|
9
|
-
padding: 5px 3px;
|
|
10
|
-
line-height: 1;
|
|
11
|
-
cursor: pointer;
|
|
12
|
-
transition: all 0.3s ease;
|
|
13
|
-
.icon {
|
|
14
|
-
font-size: 1.05em;
|
|
15
|
-
}
|
|
16
|
-
&:hover {
|
|
17
|
-
color: @v-primary-color;
|
|
18
|
-
}
|
|
19
|
-
}
|
|
20
|
-
|
|
21
|
-
.@{prefix-table}-fast-search__setting {
|
|
22
|
-
height: 100%;
|
|
23
|
-
.main {
|
|
24
|
-
display: flex;
|
|
25
|
-
flex-direction: row;
|
|
26
|
-
height: 100%;
|
|
27
|
-
.container {
|
|
28
|
-
flex: 1;
|
|
29
|
-
min-width: 0;
|
|
30
|
-
display: flex;
|
|
31
|
-
flex-direction: column;
|
|
32
|
-
.search-box {
|
|
33
|
-
display: flex;
|
|
34
|
-
align-items: center;
|
|
35
|
-
.label {
|
|
36
|
-
width:
|
|
37
|
-
}
|
|
38
|
-
}
|
|
39
|
-
.condition {
|
|
40
|
-
|
|
41
|
-
margin-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
color:
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
font-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
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
|
-
}
|
|
1
|
+
/*
|
|
2
|
+
* @Author: 焦质晔
|
|
3
|
+
* @Date: 2022-03-16 19:05:30
|
|
4
|
+
* @Last Modified by: 焦质晔
|
|
5
|
+
* @Last Modified time: 2022-11-26 21:11:04
|
|
6
|
+
*/
|
|
7
|
+
.@{prefix-table}-fast-search {
|
|
8
|
+
display: inline-block;
|
|
9
|
+
padding: 5px 3px;
|
|
10
|
+
line-height: 1;
|
|
11
|
+
cursor: pointer;
|
|
12
|
+
transition: all 0.3s ease;
|
|
13
|
+
.icon {
|
|
14
|
+
font-size: 1.05em;
|
|
15
|
+
}
|
|
16
|
+
&:hover {
|
|
17
|
+
color: @v-primary-color;
|
|
18
|
+
}
|
|
19
|
+
}
|
|
20
|
+
|
|
21
|
+
.@{prefix-table}-fast-search__setting {
|
|
22
|
+
height: 100%;
|
|
23
|
+
.main {
|
|
24
|
+
display: flex;
|
|
25
|
+
flex-direction: row;
|
|
26
|
+
height: 100%;
|
|
27
|
+
.container {
|
|
28
|
+
flex: 1;
|
|
29
|
+
min-width: 0;
|
|
30
|
+
display: flex;
|
|
31
|
+
flex-direction: column;
|
|
32
|
+
.search-box {
|
|
33
|
+
display: flex;
|
|
34
|
+
align-items: center;
|
|
35
|
+
.label {
|
|
36
|
+
width: 75px;
|
|
37
|
+
}
|
|
38
|
+
}
|
|
39
|
+
.condition {
|
|
40
|
+
padding-left: 75px;
|
|
41
|
+
margin-top: @v-module-distance;
|
|
42
|
+
margin-bottom: @v-module-distance;
|
|
43
|
+
}
|
|
44
|
+
.all-list {
|
|
45
|
+
flex: 1 0;
|
|
46
|
+
min-height: 0;
|
|
47
|
+
overflow-y: auto;
|
|
48
|
+
.rtable {
|
|
49
|
+
width: 100%;
|
|
50
|
+
border: 1px solid @v-table-border-color;
|
|
51
|
+
thead {
|
|
52
|
+
position: sticky;
|
|
53
|
+
top: 0;
|
|
54
|
+
th {
|
|
55
|
+
background-color: @v-table-header-background-color;
|
|
56
|
+
height: 30px;
|
|
57
|
+
text-align: center;
|
|
58
|
+
}
|
|
59
|
+
}
|
|
60
|
+
tbody {
|
|
61
|
+
tr {
|
|
62
|
+
&.active {
|
|
63
|
+
td {
|
|
64
|
+
background-color: @--primary-1;
|
|
65
|
+
color: @v-primary-color;
|
|
66
|
+
}
|
|
67
|
+
}
|
|
68
|
+
&:hover {
|
|
69
|
+
td {
|
|
70
|
+
text-decoration: underline;
|
|
71
|
+
}
|
|
72
|
+
}
|
|
73
|
+
td {
|
|
74
|
+
height: 30px;
|
|
75
|
+
text-align: center;
|
|
76
|
+
border-top: 1px solid @v-table-border-color;
|
|
77
|
+
cursor: pointer;
|
|
78
|
+
.text-overflow-cut();
|
|
79
|
+
max-width: 0;
|
|
80
|
+
}
|
|
81
|
+
}
|
|
82
|
+
}
|
|
83
|
+
}
|
|
84
|
+
}
|
|
85
|
+
}
|
|
86
|
+
.saved {
|
|
87
|
+
width: 240px;
|
|
88
|
+
.form-wrap {
|
|
89
|
+
display: flex;
|
|
90
|
+
}
|
|
91
|
+
.card-wrap {
|
|
92
|
+
margin-top: @v-module-distance;
|
|
93
|
+
border: 1px solid @v-table-border-color;
|
|
94
|
+
> h5 {
|
|
95
|
+
display: flex;
|
|
96
|
+
align-items: center;
|
|
97
|
+
font-size: inherit;
|
|
98
|
+
font-weight: normal;
|
|
99
|
+
margin-bottom: 0;
|
|
100
|
+
padding: 0 @v-module-distance;
|
|
101
|
+
border-bottom: 1px solid @v-table-border-color;
|
|
102
|
+
background-color: @v-table-header-background-color;
|
|
103
|
+
}
|
|
104
|
+
> ul {
|
|
105
|
+
margin-bottom: 0;
|
|
106
|
+
li {
|
|
107
|
+
display: flex;
|
|
108
|
+
align-items: center;
|
|
109
|
+
position: relative;
|
|
110
|
+
padding: 6px @v-module-distance;
|
|
111
|
+
border-bottom: 1px solid @v-table-border-color;
|
|
112
|
+
cursor: pointer;
|
|
113
|
+
transition: all 0.3s ease;
|
|
114
|
+
&:last-of-type {
|
|
115
|
+
border-bottom: 0;
|
|
116
|
+
}
|
|
117
|
+
&:hover {
|
|
118
|
+
background-color: @v-table-row-hover-background-color;
|
|
119
|
+
.close {
|
|
120
|
+
visibility: visible;
|
|
121
|
+
}
|
|
122
|
+
}
|
|
123
|
+
&.selected {
|
|
124
|
+
background-color: @v-table-row-selected-background-color;
|
|
125
|
+
}
|
|
126
|
+
.title {
|
|
127
|
+
i {
|
|
128
|
+
margin-right: 5px;
|
|
129
|
+
}
|
|
130
|
+
}
|
|
131
|
+
.close {
|
|
132
|
+
position: absolute;
|
|
133
|
+
right: @v-module-distance;
|
|
134
|
+
visibility: hidden;
|
|
135
|
+
}
|
|
136
|
+
}
|
|
137
|
+
}
|
|
138
|
+
}
|
|
139
|
+
}
|
|
140
|
+
.line {
|
|
141
|
+
border-left: 1px dashed @--border-color-base;
|
|
142
|
+
padding-left: @v-module-distance;
|
|
143
|
+
margin-left: @v-module-distance;
|
|
144
|
+
}
|
|
145
|
+
}
|
|
146
|
+
.bottom-bar {
|
|
147
|
+
display: flex;
|
|
148
|
+
justify-content: space-between;
|
|
149
|
+
align-items: center;
|
|
150
|
+
}
|
|
151
|
+
}
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
* @Author: 焦质晔
|
|
3
3
|
* @Date: 2020-02-28 22:11:53
|
|
4
4
|
* @Last Modified by: 焦质晔
|
|
5
|
-
* @Last Modified time:
|
|
5
|
+
* @Last Modified time: 2025-06-17 10:44:57
|
|
6
6
|
*/
|
|
7
7
|
.TheadAlignCenter {
|
|
8
8
|
.cell--text {
|
|
@@ -174,24 +174,122 @@
|
|
|
174
174
|
|
|
175
175
|
.head-filter__popper {
|
|
176
176
|
padding: @v-module-distance !important;
|
|
177
|
-
max-height:
|
|
177
|
+
max-height: 424px;
|
|
178
178
|
overflow-y: auto;
|
|
179
179
|
}
|
|
180
180
|
|
|
181
181
|
.head-filter--wrap {
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
182
|
+
@modulePadding: 6px;
|
|
183
|
+
.filter-list {
|
|
184
|
+
ul {
|
|
185
|
+
li {
|
|
186
|
+
display: flex;
|
|
187
|
+
align-items: center;
|
|
188
|
+
margin-bottom: @modulePadding;
|
|
189
|
+
.label {
|
|
190
|
+
width: 20px;
|
|
191
|
+
}
|
|
192
|
+
}
|
|
193
|
+
}
|
|
194
|
+
}
|
|
195
|
+
.filter-box {
|
|
196
|
+
display: flex;
|
|
197
|
+
align-items: center;
|
|
198
|
+
.condition {
|
|
199
|
+
.ant-select-selector {
|
|
200
|
+
padding: 0 @modulePadding;
|
|
201
|
+
.ant-select-selection-item {
|
|
202
|
+
padding-right: @v-module-distance;
|
|
203
|
+
}
|
|
204
|
+
}
|
|
205
|
+
.ant-select-arrow {
|
|
206
|
+
right: @modulePadding;
|
|
207
|
+
}
|
|
208
|
+
}
|
|
209
|
+
}
|
|
210
|
+
.list-panel {
|
|
211
|
+
.btn {
|
|
212
|
+
display: inline-block;
|
|
213
|
+
text-align: center;
|
|
214
|
+
text-transform: none;
|
|
215
|
+
text-decoration: none;
|
|
216
|
+
background: transparent;
|
|
217
|
+
border: 0;
|
|
218
|
+
outline: 0;
|
|
219
|
+
box-shadow: none;
|
|
220
|
+
cursor: pointer;
|
|
221
|
+
}
|
|
222
|
+
.select-all {
|
|
185
223
|
display: flex;
|
|
186
224
|
align-items: center;
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
225
|
+
justify-content: space-between;
|
|
226
|
+
margin: 5px 0 2px;
|
|
227
|
+
.action {
|
|
228
|
+
flex: 1 0;
|
|
229
|
+
}
|
|
230
|
+
.ant-checkbox + span {
|
|
231
|
+
padding-right: 4px;
|
|
232
|
+
}
|
|
233
|
+
.divider {
|
|
234
|
+
font-style: normal;
|
|
235
|
+
color: @v-font-disabled-color;
|
|
190
236
|
}
|
|
191
|
-
|
|
192
|
-
|
|
237
|
+
.invert {
|
|
238
|
+
padding: 0 4px;
|
|
239
|
+
cursor: pointer;
|
|
240
|
+
&:disabled {
|
|
241
|
+
color: @v-font-disabled-color;
|
|
242
|
+
cursor: not-allowed;
|
|
243
|
+
}
|
|
244
|
+
}
|
|
245
|
+
.total {
|
|
246
|
+
font-size: @v-font-size - 1px;
|
|
247
|
+
color: @v-font-color-placeholder;
|
|
193
248
|
}
|
|
194
249
|
}
|
|
250
|
+
.select-list {
|
|
251
|
+
margin-right: -10px;
|
|
252
|
+
.list-item {
|
|
253
|
+
width: 200px;
|
|
254
|
+
height: 26px;
|
|
255
|
+
display: flex;
|
|
256
|
+
align-items: center;
|
|
257
|
+
&:hover {
|
|
258
|
+
.right {
|
|
259
|
+
display: block;
|
|
260
|
+
}
|
|
261
|
+
}
|
|
262
|
+
.ant-checkbox-wrapper {
|
|
263
|
+
flex: auto;
|
|
264
|
+
min-width: 0;
|
|
265
|
+
& > span:nth-child(2) {
|
|
266
|
+
padding-right: 4px;
|
|
267
|
+
.text-overflow-cut();
|
|
268
|
+
}
|
|
269
|
+
}
|
|
270
|
+
.right {
|
|
271
|
+
flex-shrink: 0;
|
|
272
|
+
padding: 0;
|
|
273
|
+
font-size: @v-font-size - 1px;
|
|
274
|
+
color: @v-primary-color;
|
|
275
|
+
display: none;
|
|
276
|
+
}
|
|
277
|
+
}
|
|
278
|
+
}
|
|
279
|
+
}
|
|
280
|
+
.tree-panel {
|
|
281
|
+
width: 200px;
|
|
282
|
+
.ant-tree {
|
|
283
|
+
margin-right: -5px;
|
|
284
|
+
}
|
|
285
|
+
}
|
|
286
|
+
.footer {
|
|
287
|
+
margin-top: @modulePadding;
|
|
288
|
+
padding-top: @modulePadding + 2px;
|
|
289
|
+
margin-left: -@v-module-distance;
|
|
290
|
+
width: calc(100% + @v-module-distance + @v-module-distance);
|
|
291
|
+
padding-right: @v-module-distance;
|
|
292
|
+
border-top: 1px solid @--border-color-secondary;
|
|
195
293
|
}
|
|
196
294
|
}
|
|
197
295
|
|
|
@@ -1,51 +1,51 @@
|
|
|
1
|
-
/*
|
|
2
|
-
* @Author: 焦质晔
|
|
3
|
-
* @Date: 2020-02-28 21:58:58
|
|
4
|
-
* @Last Modified by: 焦质晔
|
|
5
|
-
* @Last Modified time: 2021-09-04 16:24:06
|
|
6
|
-
*/
|
|
7
|
-
@prefix-table: ~'@{qm-prefix}-table';
|
|
8
|
-
|
|
9
|
-
/* font-size */
|
|
10
|
-
@v-font-size: @--font-size-base;
|
|
11
|
-
@v-font-size-large: @--font-size-base;
|
|
12
|
-
@v-font-size-small: @--font-size-sm;
|
|
13
|
-
|
|
14
|
-
@v-font-color: @--text-color;
|
|
15
|
-
@v-font-color-secondary: @--text-color-secondary;
|
|
16
|
-
@v-font-color-placeholder: @--text-color-placeholder;
|
|
17
|
-
@v-font-disabled-color: @--disabled-color;
|
|
18
|
-
|
|
19
|
-
/* primary color */
|
|
20
|
-
@v-primary-color: @--primary-color;
|
|
21
|
-
@v-danger-color: @--error-color;
|
|
22
|
-
|
|
23
|
-
// module distance
|
|
24
|
-
@v-module-distance: @--padding-md;
|
|
25
|
-
|
|
26
|
-
/* border radius */
|
|
27
|
-
@v-border-radius: @--border-radius-base;
|
|
28
|
-
|
|
29
|
-
/* icon */
|
|
30
|
-
@v-icon-color: #bfbfbf;
|
|
31
|
-
|
|
32
|
-
/* table color */
|
|
33
|
-
@v-table-header-background-color: #fafafa;
|
|
34
|
-
@v-table-border-color: #e8e8e8;
|
|
35
|
-
@v-table-resizable-color: #d9d9d9;
|
|
36
|
-
@v-table-background-color: #ffffff;
|
|
37
|
-
@v-table-footer-background-color: #fafafa;
|
|
38
|
-
@v-table-column-sort-hover-color: #f2f2f2;
|
|
39
|
-
@v-table-column-sorted-color: #f5f5f5;
|
|
40
|
-
@v-table-column-filter-hover-color: #e5e5e5;
|
|
41
|
-
|
|
42
|
-
/* table row */
|
|
43
|
-
@v-table-row-height: 34px;
|
|
44
|
-
@v-table-row-height-large: 42px;
|
|
45
|
-
@v-table-row-height-small: 26px;
|
|
46
|
-
@v-table-row-line-height: 24px;
|
|
47
|
-
@v-table-row-hover-background-color: #f5f5f5;
|
|
48
|
-
@v-table-row-selected-background-color: @--primary-2;
|
|
49
|
-
@v-table-row-current-background-color: @--primary-4;
|
|
50
|
-
@v-table-row-expanded-background-color: #fafafa;
|
|
51
|
-
@v-table-row-active-color: rgba(250, 173, 20, 0.3);
|
|
1
|
+
/*
|
|
2
|
+
* @Author: 焦质晔
|
|
3
|
+
* @Date: 2020-02-28 21:58:58
|
|
4
|
+
* @Last Modified by: 焦质晔
|
|
5
|
+
* @Last Modified time: 2021-09-04 16:24:06
|
|
6
|
+
*/
|
|
7
|
+
@prefix-table: ~'@{qm-prefix}-table';
|
|
8
|
+
|
|
9
|
+
/* font-size */
|
|
10
|
+
@v-font-size: @--font-size-base;
|
|
11
|
+
@v-font-size-large: @--font-size-base;
|
|
12
|
+
@v-font-size-small: @--font-size-sm;
|
|
13
|
+
|
|
14
|
+
@v-font-color: @--text-color;
|
|
15
|
+
@v-font-color-secondary: @--text-color-secondary;
|
|
16
|
+
@v-font-color-placeholder: @--text-color-placeholder;
|
|
17
|
+
@v-font-disabled-color: @--disabled-color;
|
|
18
|
+
|
|
19
|
+
/* primary color */
|
|
20
|
+
@v-primary-color: @--primary-color;
|
|
21
|
+
@v-danger-color: @--error-color;
|
|
22
|
+
|
|
23
|
+
// module distance
|
|
24
|
+
@v-module-distance: @--padding-md;
|
|
25
|
+
|
|
26
|
+
/* border radius */
|
|
27
|
+
@v-border-radius: @--border-radius-base;
|
|
28
|
+
|
|
29
|
+
/* icon */
|
|
30
|
+
@v-icon-color: #bfbfbf;
|
|
31
|
+
|
|
32
|
+
/* table color */
|
|
33
|
+
@v-table-header-background-color: #fafafa;
|
|
34
|
+
@v-table-border-color: #e8e8e8;
|
|
35
|
+
@v-table-resizable-color: #d9d9d9;
|
|
36
|
+
@v-table-background-color: #ffffff;
|
|
37
|
+
@v-table-footer-background-color: #fafafa;
|
|
38
|
+
@v-table-column-sort-hover-color: #f2f2f2;
|
|
39
|
+
@v-table-column-sorted-color: #f5f5f5;
|
|
40
|
+
@v-table-column-filter-hover-color: #e5e5e5;
|
|
41
|
+
|
|
42
|
+
/* table row */
|
|
43
|
+
@v-table-row-height: 34px;
|
|
44
|
+
@v-table-row-height-large: 42px;
|
|
45
|
+
@v-table-row-height-small: 26px;
|
|
46
|
+
@v-table-row-line-height: 24px;
|
|
47
|
+
@v-table-row-hover-background-color: #f5f5f5;
|
|
48
|
+
@v-table-row-selected-background-color: @--primary-2;
|
|
49
|
+
@v-table-row-current-background-color: @--primary-4;
|
|
50
|
+
@v-table-row-expanded-background-color: #fafafa;
|
|
51
|
+
@v-table-row-active-color: rgba(250, 173, 20, 0.3);
|
|
@@ -76,6 +76,7 @@ export interface VirtualizerOptions<TScrollElement extends Element | Window, TIt
|
|
|
76
76
|
useScrollendEvent?: boolean;
|
|
77
77
|
enabled?: boolean;
|
|
78
78
|
isRtl?: boolean;
|
|
79
|
+
useAnimationFrameWithResizeObserver?: boolean;
|
|
79
80
|
}
|
|
80
81
|
export declare class Virtualizer<TScrollElement extends Element | Window, TItemElement extends Element> {
|
|
81
82
|
private unsubs;
|
|
@@ -83,7 +84,6 @@ export declare class Virtualizer<TScrollElement extends Element | Window, TItemE
|
|
|
83
84
|
scrollElement: TScrollElement | null;
|
|
84
85
|
targetWindow: (Window & typeof globalThis) | null;
|
|
85
86
|
isScrolling: boolean;
|
|
86
|
-
private scrollToIndexTimeoutId;
|
|
87
87
|
measurementsCache: Array<VirtualItem>;
|
|
88
88
|
private itemSizeCache;
|
|
89
89
|
private pendingMeasuredCacheIndexes;
|
|
@@ -115,7 +115,7 @@ export declare class Virtualizer<TScrollElement extends Element | Window, TItemE
|
|
|
115
115
|
startIndex: number;
|
|
116
116
|
endIndex: number;
|
|
117
117
|
} | null;
|
|
118
|
-
updateDeps(newDeps: [VirtualItem[], number, number]): void;
|
|
118
|
+
updateDeps(newDeps: [VirtualItem[], number, number, number]): void;
|
|
119
119
|
};
|
|
120
120
|
getVirtualIndexes: {
|
|
121
121
|
(): number[];
|
|
@@ -130,10 +130,9 @@ export declare class Virtualizer<TScrollElement extends Element | Window, TItemE
|
|
|
130
130
|
updateDeps(newDeps: [number[], VirtualItem[]]): void;
|
|
131
131
|
};
|
|
132
132
|
getVirtualItemForOffset: (offset: number) => VirtualItem | undefined;
|
|
133
|
-
getOffsetForAlignment: (toOffset: number, align: ScrollAlignment) => number;
|
|
134
|
-
getOffsetForIndex: (index: number, align?: ScrollAlignment) => readonly [number, "auto"] | readonly [number, "center"
|
|
133
|
+
getOffsetForAlignment: (toOffset: number, align: ScrollAlignment, itemSize?: number) => number;
|
|
134
|
+
getOffsetForIndex: (index: number, align?: ScrollAlignment) => readonly [number, "auto"] | readonly [number, "center" | "start" | "end"] | undefined;
|
|
135
135
|
private isDynamicMode;
|
|
136
|
-
private cancelScrollToIndex;
|
|
137
136
|
scrollToOffset: (toOffset: number, { align, behavior }?: ScrollToOffsetOptions) => void;
|
|
138
137
|
scrollToIndex: (index: number, { align: initialAlign, behavior }?: ScrollToIndexOptions) => void;
|
|
139
138
|
scrollBy: (delta: number, { behavior }?: ScrollToOffsetOptions) => void;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { Virtualizer } from './core';
|
|
2
2
|
import type { PartialKeys, VirtualizerOptions } from './core';
|
|
3
3
|
export * from './core';
|
|
4
|
-
export declare
|
|
5
|
-
export declare
|
|
4
|
+
export declare function useVirtualizer<TScrollElement extends Element, TItemElement extends Element>(options: PartialKeys<VirtualizerOptions<TScrollElement, TItemElement>, 'observeElementRect' | 'observeElementOffset' | 'scrollToFn'>): Virtualizer<TScrollElement, TItemElement>;
|
|
5
|
+
export declare function useWindowVirtualizer<TItemElement extends Element>(options: PartialKeys<VirtualizerOptions<Window, TItemElement>, 'getScrollElement' | 'observeElementRect' | 'observeElementOffset' | 'scrollToFn'>): Virtualizer<Window, TItemElement>;
|
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
import { AnyFunction } from '../../_utils/types';
|
|
2
1
|
export type NoInfer<A> = [A][A extends any ? 0 : never];
|
|
3
2
|
export type PartialKeys<T, K extends keyof T> = Omit<T, K> & Partial<Pick<T, K>>;
|
|
4
3
|
export declare function memo<TDeps extends ReadonlyArray<any>, TResult>(getDeps: () => [...TDeps], fn: (...args: NoInfer<[...TDeps]>) => TResult, opts: {
|
|
@@ -13,4 +12,4 @@ export declare function memo<TDeps extends ReadonlyArray<any>, TResult>(getDeps:
|
|
|
13
12
|
};
|
|
14
13
|
export declare function notUndefined<T>(value: T | undefined, msg?: string): T;
|
|
15
14
|
export declare const approxEqual: (a: number, b: number) => boolean;
|
|
16
|
-
export declare const debounce: (targetWindow: Window & typeof globalThis, fn:
|
|
15
|
+
export declare const debounce: (targetWindow: Window & typeof globalThis, fn: any, ms: any) => (this: any, ...args: Array<any>) => void;
|
|
@@ -1,22 +1,22 @@
|
|
|
1
|
-
/*
|
|
2
|
-
* @Author: 焦质晔
|
|
3
|
-
* @Date: 2024-12-02 09:06:20
|
|
4
|
-
* @Last Modified by: 焦质晔
|
|
5
|
-
* @Last Modified time: 2024-12-26 14:23:49
|
|
6
|
-
*/
|
|
7
|
-
@import '../../style/common';
|
|
8
|
-
|
|
9
|
-
@prefix-virtual-list: ~'@{qm-prefix}-virtual-list';
|
|
10
|
-
|
|
11
|
-
.@{prefix-virtual-list} {
|
|
12
|
-
.reset-container();
|
|
13
|
-
.container {
|
|
14
|
-
display: block;
|
|
15
|
-
ul {
|
|
16
|
-
will-change: transform;
|
|
17
|
-
li.list-item {
|
|
18
|
-
list-style: none;
|
|
19
|
-
}
|
|
20
|
-
}
|
|
21
|
-
}
|
|
22
|
-
}
|
|
1
|
+
/*
|
|
2
|
+
* @Author: 焦质晔
|
|
3
|
+
* @Date: 2024-12-02 09:06:20
|
|
4
|
+
* @Last Modified by: 焦质晔
|
|
5
|
+
* @Last Modified time: 2024-12-26 14:23:49
|
|
6
|
+
*/
|
|
7
|
+
@import '../../style/common';
|
|
8
|
+
|
|
9
|
+
@prefix-virtual-list: ~'@{qm-prefix}-virtual-list';
|
|
10
|
+
|
|
11
|
+
.@{prefix-virtual-list} {
|
|
12
|
+
.reset-container();
|
|
13
|
+
.container {
|
|
14
|
+
display: block;
|
|
15
|
+
ul {
|
|
16
|
+
will-change: transform;
|
|
17
|
+
li.list-item {
|
|
18
|
+
list-style: none;
|
|
19
|
+
}
|
|
20
|
+
}
|
|
21
|
+
}
|
|
22
|
+
}
|