bkui-vue 2.0.1-beta.39.table.2 → 2.0.1-beta.40
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/dist/index.cjs.js +63 -63
- package/dist/index.esm.js +15703 -15738
- package/dist/index.umd.js +63 -63
- package/dist/style.css +1 -1
- package/dist/style.variable.css +1 -1
- package/lib/index.js +1 -1
- package/lib/scrollbar/index.d.ts +13 -133
- package/lib/scrollbar/index.js +18490 -1332
- package/lib/scrollbar/scrollbar-core/can-use-dom.d.ts +2 -0
- package/lib/scrollbar/scrollbar-core/helpers.d.ts +5 -0
- package/lib/scrollbar/scrollbar-core/index.d.ts +242 -0
- package/lib/scrollbar/scrollbar-core/mouse-wheel.d.ts +5 -0
- package/lib/scrollbar/scrollbar-core/scrollbar-width.d.ts +1 -0
- package/lib/scrollbar/{css/scrollbar.css → scrollbar.css} +75 -90
- package/lib/scrollbar/scrollbar.less +119 -0
- package/lib/scrollbar/{css/scrollbar.variable.css → scrollbar.variable.css} +74 -89
- package/lib/styles/index.d.ts +0 -1
- package/lib/table/hooks/use-columns.d.ts +1 -4
- package/lib/table/hooks/use-layout.d.ts +0 -1
- package/lib/table/index.js +66 -140
- package/lib/table/table.css +115 -108
- package/lib/table/table.less +34 -24
- package/lib/table/table.variable.css +115 -108
- package/lib/table-column/index.js +0 -4
- package/lib/tree/tree.css +83 -90
- package/lib/tree/tree.variable.css +83 -90
- package/lib/virtual-render/index.d.ts +23 -0
- package/lib/virtual-render/index.js +106 -54
- package/lib/virtual-render/props.d.ts +6 -0
- package/lib/virtual-render/use-scrollbar.d.ts +17 -3
- package/lib/virtual-render/virtual-render.css +82 -89
- package/lib/virtual-render/virtual-render.d.ts +11 -0
- package/lib/virtual-render/virtual-render.less +11 -2
- package/lib/virtual-render/virtual-render.variable.css +82 -89
- package/lib/volar.components.d.ts +2 -0
- package/package.json +1 -1
- package/lib/scrollbar/css/scrollbar.less +0 -139
- package/lib/scrollbar/handlers/click-rail.d.ts +0 -2
- package/lib/scrollbar/handlers/drag-thumb.d.ts +0 -1
- package/lib/scrollbar/handlers/keyboard.d.ts +0 -2
- package/lib/scrollbar/handlers/mouse-wheel.d.ts +0 -2
- package/lib/scrollbar/handlers/touch.d.ts +0 -4
- package/lib/scrollbar/helper/class-names.d.ts +0 -21
- package/lib/scrollbar/helper/css.d.ts +0 -3
- package/lib/scrollbar/helper/dom.d.ts +0 -4
- package/lib/scrollbar/helper/event-manager.d.ts +0 -20
- package/lib/scrollbar/helper/util.d.ts +0 -11
- package/lib/scrollbar/process-scroll-diff.d.ts +0 -1
- package/lib/scrollbar/update-geometry.d.ts +0 -8
package/lib/table/table.css
CHANGED
@@ -145,118 +145,111 @@
|
|
145
145
|
.bk-F-scroll-y::-webkit-scrollbar-thumb {
|
146
146
|
border-radius: 4px;
|
147
147
|
}
|
148
|
-
.bk-scrollbar {
|
149
|
-
|
150
|
-
overflow
|
151
|
-
touch-action: auto;
|
152
|
-
/*
|
153
|
-
* Scrollbar rail styles
|
154
|
-
*/
|
155
|
-
/*
|
156
|
-
* Scrollbar thumb styles
|
157
|
-
*/
|
158
|
-
}
|
159
|
-
.bk-scrollbar.bk--active-x > .bk__rail-x,
|
160
|
-
.bk-scrollbar.bk--active-y > .bk__rail-y {
|
161
|
-
display: block;
|
148
|
+
.bk-scrollbar-wrapper {
|
149
|
+
position: relative;
|
150
|
+
overflow: hidden;
|
162
151
|
}
|
163
|
-
.bk-scrollbar .
|
164
|
-
|
165
|
-
|
166
|
-
|
167
|
-
.bk-scrollbar .bk__rail-x.bk--clicking,
|
168
|
-
.bk-scrollbar .bk__rail-y.bk--clicking {
|
169
|
-
background-color: #f0f1f5;
|
152
|
+
.bk-scrollbar-wrapper .bk-scrollbar-content-el {
|
153
|
+
display: inline-flex;
|
154
|
+
flex-direction: column;
|
155
|
+
width: 100%;
|
170
156
|
}
|
171
|
-
.bk-scrollbar .
|
172
|
-
|
173
|
-
opacity: 0;
|
174
|
-
transition: background-color 0.2s linear, opacity 0.2s linear;
|
175
|
-
height: 10px;
|
176
|
-
bottom: 0px;
|
157
|
+
.bk-scrollbar-wrapper .bk-scrollbar-track {
|
158
|
+
z-index: 1;
|
177
159
|
position: absolute;
|
160
|
+
right: 0;
|
161
|
+
bottom: 0;
|
162
|
+
pointer-events: none;
|
163
|
+
overflow: hidden;
|
178
164
|
}
|
179
|
-
.bk-scrollbar .
|
180
|
-
|
181
|
-
}
|
182
|
-
.bk-scrollbar .bk__rail-x.bk-size-small .bk__thumb-x {
|
183
|
-
height: 6px;
|
184
|
-
}
|
185
|
-
.bk-scrollbar .bk__rail-y {
|
186
|
-
display: none;
|
187
|
-
opacity: 0;
|
188
|
-
transition: background-color 0.2s linear, opacity 0.2s linear;
|
189
|
-
width: 10px;
|
190
|
-
right: 0px;
|
191
|
-
position: absolute;
|
192
|
-
margin-right: 2px;
|
165
|
+
.bk-scrollbar-wrapper .bk-scrollbar-track.track-small.bk-scrollbar-vertical {
|
166
|
+
width: 6px;
|
193
167
|
}
|
194
|
-
.bk-scrollbar .
|
168
|
+
.bk-scrollbar-wrapper .bk-scrollbar-track.track-small.bk-scrollbar-vertical.bk-scrollbar-hover {
|
195
169
|
width: 8px;
|
196
170
|
}
|
197
|
-
.bk-scrollbar .
|
198
|
-
|
199
|
-
}
|
200
|
-
.bk-scrollbar:hover > .bk__rail-x,
|
201
|
-
.bk-scrollbar:hover > .bk__rail-y,
|
202
|
-
.bk-scrollbar.bk--focus > .bk__rail-x,
|
203
|
-
.bk-scrollbar.bk--focus > .bk__rail-y,
|
204
|
-
.bk-scrollbar.bk--scrolling-x > .bk__rail-x,
|
205
|
-
.bk-scrollbar.bk--scrolling-y > .bk__rail-y {
|
206
|
-
opacity: 0.9;
|
171
|
+
.bk-scrollbar-wrapper .bk-scrollbar-track.track-small.bk-scrollbar-horizontal {
|
172
|
+
height: 6px;
|
207
173
|
}
|
208
|
-
.bk-scrollbar .
|
209
|
-
background-color: #dcdee5;
|
210
|
-
border-radius: 8px;
|
211
|
-
transition: background-color 0.2s linear, height 0.2s ease-in-out;
|
174
|
+
.bk-scrollbar-wrapper .bk-scrollbar-track.track-small.bk-scrollbar-horizontal.bk-scrollbar-hover {
|
212
175
|
height: 8px;
|
213
|
-
bottom: 0px;
|
214
|
-
position: absolute;
|
215
176
|
}
|
216
|
-
.bk-scrollbar .
|
217
|
-
background-color: #
|
218
|
-
|
219
|
-
transition: background-color 0.2s linear, width 0.2s ease-in-out;
|
220
|
-
width: 8px;
|
221
|
-
right: 0px;
|
222
|
-
position: absolute;
|
177
|
+
.bk-scrollbar-wrapper .bk-scrollbar-track.bk-scrollbar-hover {
|
178
|
+
background-color: #f0f1f5;
|
179
|
+
cursor: pointer;
|
223
180
|
}
|
224
|
-
.bk-scrollbar .
|
225
|
-
.bk-scrollbar .bk__rail-x:focus > .bk__thumb-x,
|
226
|
-
.bk-scrollbar .bk__rail-x.bk--clicking .bk__thumb-x {
|
181
|
+
.bk-scrollbar-wrapper .bk-scrollbar-track.bk-scrollbar-hover .bk-scrollbar::before {
|
227
182
|
background-color: #979ba5;
|
228
|
-
height: 10px;
|
229
183
|
}
|
230
|
-
.bk-scrollbar .
|
231
|
-
|
232
|
-
|
233
|
-
|
184
|
+
.bk-scrollbar-wrapper .bk-scrollbar-track.bk-scrollbar-vertical {
|
185
|
+
top: 0;
|
186
|
+
width: 8px;
|
187
|
+
transform: translate(var(--scroll-offset-x), var(--scroll-offset-y));
|
188
|
+
}
|
189
|
+
.bk-scrollbar-wrapper .bk-scrollbar-track.bk-scrollbar-vertical.bk-scrollbar-hover {
|
234
190
|
width: 10px;
|
235
191
|
}
|
236
|
-
.bk-scrollbar .bk-
|
237
|
-
|
238
|
-
.bk-scrollbar .bk-size-small.bk--clicking .bk__thumb-x {
|
192
|
+
.bk-scrollbar-wrapper .bk-scrollbar-track.bk-scrollbar-horizontal {
|
193
|
+
left: 0;
|
239
194
|
height: 8px;
|
195
|
+
transform: translate(var(--scroll-offset-x), var(--scroll-offset-y));
|
240
196
|
}
|
241
|
-
.bk-scrollbar .bk-
|
242
|
-
|
243
|
-
.bk-scrollbar .bk-size-small.bk--clicking .bk__thumb-y {
|
244
|
-
width: 8px;
|
197
|
+
.bk-scrollbar-wrapper .bk-scrollbar-track.bk-scrollbar-horizontal.bk-scrollbar-hover {
|
198
|
+
height: 10px;
|
245
199
|
}
|
246
|
-
|
247
|
-
|
248
|
-
|
249
|
-
|
250
|
-
|
200
|
+
.bk-scrollbar-wrapper .bk-scrollbar-track.bk-scrollbar-horizontal.bk-scrollbar {
|
201
|
+
right: auto;
|
202
|
+
left: 0;
|
203
|
+
top: 0;
|
204
|
+
bottom: 0;
|
205
|
+
min-height: 0;
|
206
|
+
min-width: 8px;
|
207
|
+
width: auto;
|
251
208
|
}
|
252
|
-
|
253
|
-
|
254
|
-
|
255
|
-
|
209
|
+
.bk-scrollbar-wrapper .bk-scrollbar-dragging {
|
210
|
+
pointer-events: none;
|
211
|
+
-webkit-touch-callout: none;
|
212
|
+
-webkit-user-select: none;
|
213
|
+
-khtml-user-select: none;
|
214
|
+
-moz-user-select: none;
|
215
|
+
-ms-user-select: none;
|
216
|
+
user-select: none;
|
217
|
+
}
|
218
|
+
.bk-scrollbar-wrapper .bk-scrollbar {
|
219
|
+
position: absolute;
|
220
|
+
left: 0;
|
221
|
+
right: 0;
|
222
|
+
top: 0;
|
223
|
+
bottom: 0;
|
224
|
+
}
|
225
|
+
.bk-scrollbar-wrapper .bk-scrollbar::before {
|
226
|
+
position: absolute;
|
227
|
+
content: '';
|
228
|
+
background: #dcdee5;
|
229
|
+
border-radius: 6px;
|
230
|
+
left: 0;
|
231
|
+
right: 0;
|
232
|
+
top: 0;
|
233
|
+
bottom: 0;
|
234
|
+
opacity: 0;
|
235
|
+
transition: opacity 0.2s 0.9s linear;
|
236
|
+
}
|
237
|
+
.bk-scrollbar-wrapper .bk-scrollbar.bk-scrollbar-visible::before {
|
238
|
+
opacity: 0.9;
|
239
|
+
transition-delay: 0s;
|
240
|
+
transition-duration: 0s;
|
256
241
|
}
|
257
242
|
.bk-virtual-render {
|
258
243
|
position: relative;
|
259
244
|
}
|
245
|
+
.bk-virtual-render .bk-virtual-content {
|
246
|
+
position: absolute;
|
247
|
+
top: 0;
|
248
|
+
bottom: 0;
|
249
|
+
left: 0;
|
250
|
+
width: 100%;
|
251
|
+
height: 100%;
|
252
|
+
}
|
260
253
|
.bk-virtual-render .bk-virtual-section {
|
261
254
|
width: 1px;
|
262
255
|
background: transparent;
|
@@ -1258,7 +1251,7 @@
|
|
1258
1251
|
overflow: hidden;
|
1259
1252
|
}
|
1260
1253
|
.bk-table .bk-table-body .prepend-row {
|
1261
|
-
transform:
|
1254
|
+
transform: translate3d(var(--translate-x), 0, 0);
|
1262
1255
|
}
|
1263
1256
|
.bk-table .bk-table-body .resize-column {
|
1264
1257
|
position: absolute;
|
@@ -1267,7 +1260,7 @@
|
|
1267
1260
|
left: 0;
|
1268
1261
|
width: 1px;
|
1269
1262
|
background-color: #3785ff;
|
1270
|
-
transform:
|
1263
|
+
transform: translate3d(var(--drag-offset-x), var(--translate-y), 0);
|
1271
1264
|
}
|
1272
1265
|
.bk-table .bk-table-body-content.bk-stripe table tbody tr:nth-child(even) td {
|
1273
1266
|
background-color: var(--table-strip-color);
|
@@ -1436,6 +1429,24 @@
|
|
1436
1429
|
font-weight: 400;
|
1437
1430
|
background-color: var(--background-color);
|
1438
1431
|
}
|
1432
|
+
.bk-table .bk-table-head table thead th.col-resize-hover::after,
|
1433
|
+
.bk-table .bk-table-body table thead th.col-resize-hover::after {
|
1434
|
+
position: absolute;
|
1435
|
+
top: 0;
|
1436
|
+
right: 0;
|
1437
|
+
bottom: 0;
|
1438
|
+
z-index: 1;
|
1439
|
+
width: 6px;
|
1440
|
+
pointer-events: none;
|
1441
|
+
background-color: #3785ff;
|
1442
|
+
content: '';
|
1443
|
+
transform: translateX(50%);
|
1444
|
+
cursor: col-resize;
|
1445
|
+
}
|
1446
|
+
.bk-table .bk-table-head table thead th.col-resize-hover .cell,
|
1447
|
+
.bk-table .bk-table-body table thead th.col-resize-hover .cell {
|
1448
|
+
cursor: col-resize;
|
1449
|
+
}
|
1439
1450
|
.bk-table .bk-table-head table thead th .cell,
|
1440
1451
|
.bk-table .bk-table-body table thead th .cell {
|
1441
1452
|
display: flex;
|
@@ -1443,21 +1454,17 @@
|
|
1443
1454
|
height: calc(var(--row-height) - 2px);
|
1444
1455
|
color: var(--table-head-font-color);
|
1445
1456
|
}
|
1446
|
-
.bk-table .bk-table-head table thead th
|
1447
|
-
.bk-table .bk-table-body table thead th
|
1448
|
-
|
1457
|
+
.bk-table .bk-table-head table thead th.active,
|
1458
|
+
.bk-table .bk-table-body table thead th.active,
|
1459
|
+
.bk-table .bk-table-head table thead th:hover,
|
1460
|
+
.bk-table .bk-table-body table thead th:hover {
|
1461
|
+
cursor: pointer;
|
1462
|
+
background: var(--table-row-active-bg-color);
|
1449
1463
|
}
|
1450
1464
|
.bk-table .bk-table-head table thead th.column_fixed,
|
1451
1465
|
.bk-table .bk-table-body table thead th.column_fixed {
|
1452
1466
|
transform: translateX(var(--translate-x));
|
1453
1467
|
}
|
1454
|
-
.bk-table .bk-table-head table:not(.col-resize-hover) thead th.active,
|
1455
|
-
.bk-table .bk-table-body table:not(.col-resize-hover) thead th.active,
|
1456
|
-
.bk-table .bk-table-head table:not(.col-resize-hover) thead th:hover,
|
1457
|
-
.bk-table .bk-table-body table:not(.col-resize-hover) thead th:hover {
|
1458
|
-
cursor: pointer;
|
1459
|
-
background: var(--table-row-active-bg-color);
|
1460
|
-
}
|
1461
1468
|
.bk-table .bk-table-head table tbody tr td,
|
1462
1469
|
.bk-table .bk-table-body table tbody tr td {
|
1463
1470
|
background-color: #fff;
|
@@ -1497,7 +1504,6 @@
|
|
1497
1504
|
overflow: hidden;
|
1498
1505
|
background-color: var(--background-color);
|
1499
1506
|
height: var(--row-height);
|
1500
|
-
min-height: var(--row-height);
|
1501
1507
|
}
|
1502
1508
|
.bk-table .bk-table-head.has-group .is-head-group {
|
1503
1509
|
border-bottom: 1px solid var(--table-border-color);
|
@@ -1516,14 +1522,16 @@
|
|
1516
1522
|
z-index: 1;
|
1517
1523
|
width: 6px;
|
1518
1524
|
background-color: #3785ff;
|
1519
|
-
transform:
|
1520
|
-
|
1525
|
+
transform: translate3d(var(--drag-offset-h-x), 0, 0);
|
1526
|
+
}
|
1527
|
+
.bk-table .bk-table-head .col-resize-drag:hover {
|
1528
|
+
cursor: ew-resize !important;
|
1521
1529
|
}
|
1522
1530
|
.bk-table .bk-table-head .bk-table-fixed {
|
1523
|
-
transform:
|
1531
|
+
transform: translate3d(0, 0, 0);
|
1524
1532
|
}
|
1525
1533
|
.bk-table .bk-table-head thead {
|
1526
|
-
transform:
|
1534
|
+
transform: translate3d(var(--translate-x-1), 0, 0);
|
1527
1535
|
}
|
1528
1536
|
.bk-table .bk-table-head .table-head-settings {
|
1529
1537
|
position: absolute;
|
@@ -1550,7 +1558,6 @@
|
|
1550
1558
|
display: flex;
|
1551
1559
|
width: 100%;
|
1552
1560
|
height: var(--footer-height);
|
1553
|
-
min-height: var(--footer-height);
|
1554
1561
|
align-items: center;
|
1555
1562
|
padding: 0 16px 0 22px;
|
1556
1563
|
}
|
@@ -1621,7 +1628,7 @@
|
|
1621
1628
|
bottom: 0;
|
1622
1629
|
left: 0;
|
1623
1630
|
pointer-events: none;
|
1624
|
-
transform:
|
1631
|
+
transform: translate3d(var(--translate-x), var(--translate-y), 0);
|
1625
1632
|
}
|
1626
1633
|
.bk-table .bk-table-fixed .column_fixed_right {
|
1627
1634
|
box-shadow: var(--shadow-right);
|
package/lib/table/table.less
CHANGED
@@ -41,7 +41,7 @@
|
|
41
41
|
}
|
42
42
|
|
43
43
|
.prepend-row {
|
44
|
-
transform:
|
44
|
+
transform: translate3d(var(--translate-x), 0, 0);
|
45
45
|
}
|
46
46
|
|
47
47
|
.resize-column {
|
@@ -51,7 +51,7 @@
|
|
51
51
|
left: 0;
|
52
52
|
width: 1px;
|
53
53
|
background-color: #3785ff;
|
54
|
-
transform:
|
54
|
+
transform: translate3d(var(--drag-offset-x), var(--translate-y), 0);
|
55
55
|
}
|
56
56
|
}
|
57
57
|
|
@@ -215,15 +215,37 @@
|
|
215
215
|
font-weight: 400;
|
216
216
|
background-color: var(--background-color);
|
217
217
|
|
218
|
+
&.col-resize-hover {
|
219
|
+
&::after {
|
220
|
+
position: absolute;
|
221
|
+
top: 0;
|
222
|
+
right: 0;
|
223
|
+
bottom: 0;
|
224
|
+
z-index: 1;
|
225
|
+
width: 6px;
|
226
|
+
pointer-events: none;
|
227
|
+
background-color: #3785ff;
|
228
|
+
content: '';
|
229
|
+
transform: translateX(50%);
|
230
|
+
cursor: col-resize;
|
231
|
+
}
|
232
|
+
|
233
|
+
.cell {
|
234
|
+
cursor: col-resize;
|
235
|
+
}
|
236
|
+
}
|
237
|
+
|
218
238
|
.cell {
|
219
239
|
display: flex;
|
220
240
|
align-items: center;
|
221
241
|
height: calc(var(--row-height) - 2px);
|
222
242
|
color: @table-head-font-color;
|
243
|
+
}
|
223
244
|
|
224
|
-
|
225
|
-
|
226
|
-
|
245
|
+
&.active,
|
246
|
+
&:hover {
|
247
|
+
cursor: pointer;
|
248
|
+
background: @table-row-active-bg-color;
|
227
249
|
}
|
228
250
|
|
229
251
|
&.column_fixed {
|
@@ -232,18 +254,6 @@
|
|
232
254
|
}
|
233
255
|
}
|
234
256
|
|
235
|
-
&:not(.col-resize-hover) {
|
236
|
-
thead {
|
237
|
-
th {
|
238
|
-
&.active,
|
239
|
-
&:hover {
|
240
|
-
cursor: pointer;
|
241
|
-
background: @table-row-active-bg-color;
|
242
|
-
}
|
243
|
-
}
|
244
|
-
}
|
245
|
-
}
|
246
|
-
|
247
257
|
tbody {
|
248
258
|
tr {
|
249
259
|
td {
|
@@ -298,7 +308,6 @@
|
|
298
308
|
overflow: hidden;
|
299
309
|
background-color: var(--background-color);
|
300
310
|
height: var(--row-height);
|
301
|
-
min-height: var(--row-height);
|
302
311
|
|
303
312
|
&.has-group {
|
304
313
|
.is-head-group {
|
@@ -322,16 +331,18 @@
|
|
322
331
|
z-index: 1;
|
323
332
|
width: 6px;
|
324
333
|
background-color: #3785ff;
|
325
|
-
transform:
|
326
|
-
|
334
|
+
transform: translate3d(var(--drag-offset-h-x), 0, 0);
|
335
|
+
&:hover {
|
336
|
+
cursor: ew-resize !important;
|
337
|
+
}
|
327
338
|
}
|
328
339
|
|
329
340
|
.@{bk-prefix}-table-fixed {
|
330
|
-
transform:
|
341
|
+
transform: translate3d(0, 0, 0);
|
331
342
|
}
|
332
343
|
|
333
344
|
thead {
|
334
|
-
transform:
|
345
|
+
transform: translate3d(var(--translate-x-1), 0, 0);
|
335
346
|
}
|
336
347
|
|
337
348
|
.table-head-settings {
|
@@ -363,7 +374,6 @@
|
|
363
374
|
display: flex;
|
364
375
|
width: 100%;
|
365
376
|
height: var(--footer-height);
|
366
|
-
min-height: var(--footer-height);
|
367
377
|
align-items: center;
|
368
378
|
padding: 0 16px 0 22px;
|
369
379
|
|
@@ -475,7 +485,7 @@
|
|
475
485
|
bottom: 0;
|
476
486
|
left: 0;
|
477
487
|
pointer-events: none;
|
478
|
-
transform:
|
488
|
+
transform: translate3d(var(--translate-x), var(--translate-y), 0);
|
479
489
|
|
480
490
|
.column_fixed_right {
|
481
491
|
box-shadow: var(--shadow-right);
|