@vaadin/grid 25.0.0-alpha7 → 25.0.0-alpha9
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/package.json +11 -11
- package/src/styles/vaadin-grid-base-styles.js +421 -416
- package/src/styles/vaadin-grid-filter-base-styles.js +7 -9
- package/src/styles/vaadin-grid-sorter-base-styles.js +44 -46
- package/src/styles/vaadin-grid-tree-toggle-base-styles.js +51 -53
- package/src/vaadin-grid-column-auto-width-mixin.js +8 -2
- package/src/vaadin-grid-data-provider-mixin.js +19 -47
- package/src/vaadin-grid-filter.js +1 -1
- package/src/vaadin-grid-mixin.js +45 -11
- package/src/vaadin-grid-row-details-mixin.js +4 -4
- package/src/vaadin-grid-sorter.js +1 -1
- package/src/vaadin-grid-tree-toggle.js +1 -1
- package/src/vaadin-grid.js +1 -1
- package/web-types.json +4 -4
- package/web-types.lit.json +4 -4
|
@@ -6,15 +6,13 @@
|
|
|
6
6
|
import { css } from 'lit';
|
|
7
7
|
|
|
8
8
|
export const gridFilterStyles = css`
|
|
9
|
-
|
|
10
|
-
:
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
}
|
|
9
|
+
:host {
|
|
10
|
+
display: inline-flex;
|
|
11
|
+
max-width: 100%;
|
|
12
|
+
}
|
|
14
13
|
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
}
|
|
14
|
+
::slotted(*) {
|
|
15
|
+
width: 100%;
|
|
16
|
+
box-sizing: border-box;
|
|
19
17
|
}
|
|
20
18
|
`;
|
|
@@ -7,59 +7,57 @@ import '@vaadin/component-base/src/style-props.js';
|
|
|
7
7
|
import { css } from 'lit';
|
|
8
8
|
|
|
9
9
|
export const gridSorterStyles = css`
|
|
10
|
-
|
|
11
|
-
:
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
}
|
|
10
|
+
:host {
|
|
11
|
+
display: inline-flex;
|
|
12
|
+
align-items: center;
|
|
13
|
+
cursor: pointer;
|
|
14
|
+
max-width: 100%;
|
|
15
|
+
gap: var(--vaadin-gap-container-inline);
|
|
16
|
+
-webkit-user-select: none;
|
|
17
|
+
user-select: none;
|
|
18
|
+
-webkit-tap-highlight-color: transparent;
|
|
19
|
+
}
|
|
21
20
|
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
21
|
+
[part='content'] {
|
|
22
|
+
flex: 1 1 auto;
|
|
23
|
+
overflow: hidden;
|
|
24
|
+
text-overflow: ellipsis;
|
|
25
|
+
}
|
|
27
26
|
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
27
|
+
[part='indicators'] {
|
|
28
|
+
position: relative;
|
|
29
|
+
flex: none;
|
|
30
|
+
}
|
|
32
31
|
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
32
|
+
[part='order'] {
|
|
33
|
+
display: inline;
|
|
34
|
+
vertical-align: super;
|
|
35
|
+
font-size: 0.75em;
|
|
36
|
+
line-height: 1;
|
|
37
|
+
}
|
|
39
38
|
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
39
|
+
[part='indicators']::before {
|
|
40
|
+
content: '';
|
|
41
|
+
display: inline-block;
|
|
42
|
+
height: 12px;
|
|
43
|
+
width: 8px;
|
|
44
|
+
mask-image: var(--_vaadin-icon-sort);
|
|
45
|
+
background: currentColor;
|
|
46
|
+
}
|
|
48
47
|
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
48
|
+
:host([direction]) [part='indicators']::before {
|
|
49
|
+
padding-bottom: 6px;
|
|
50
|
+
height: 6px;
|
|
51
|
+
mask-clip: content-box;
|
|
52
|
+
}
|
|
54
53
|
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
54
|
+
:host([direction='desc']) [part='indicators']::before {
|
|
55
|
+
padding-block: 6px 0;
|
|
56
|
+
}
|
|
58
57
|
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
}
|
|
58
|
+
@media (forced-colors: active) {
|
|
59
|
+
[part='indicators']::before {
|
|
60
|
+
background: CanvasText;
|
|
63
61
|
}
|
|
64
62
|
}
|
|
65
63
|
`;
|
|
@@ -7,72 +7,70 @@ import '@vaadin/component-base/src/style-props.js';
|
|
|
7
7
|
import { css } from 'lit';
|
|
8
8
|
|
|
9
9
|
export const gridTreeToggleStyles = css`
|
|
10
|
-
|
|
11
|
-
:
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
}
|
|
10
|
+
:host {
|
|
11
|
+
display: flex;
|
|
12
|
+
max-width: 100%;
|
|
13
|
+
pointer-events: none;
|
|
14
|
+
}
|
|
16
15
|
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
16
|
+
/* Don't expand/collapse when clicking #level-spacer */
|
|
17
|
+
[part] {
|
|
18
|
+
pointer-events: auto;
|
|
19
|
+
}
|
|
21
20
|
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
21
|
+
:host([hidden]) {
|
|
22
|
+
display: none !important;
|
|
23
|
+
}
|
|
25
24
|
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
25
|
+
:host(:not([leaf])) {
|
|
26
|
+
cursor: var(--vaadin-clickable-cursor);
|
|
27
|
+
}
|
|
29
28
|
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
29
|
+
#level-spacer,
|
|
30
|
+
[part='toggle'] {
|
|
31
|
+
flex: none;
|
|
32
|
+
}
|
|
34
33
|
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
34
|
+
#level-spacer {
|
|
35
|
+
width: calc(var(--_level, 0) * var(--vaadin-grid-tree-toggle-level-offset, 16px));
|
|
36
|
+
}
|
|
38
37
|
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
38
|
+
[part='toggle'] {
|
|
39
|
+
margin-inline-end: var(--vaadin-gap-container-inline);
|
|
40
|
+
}
|
|
42
41
|
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
42
|
+
[part='toggle']::before {
|
|
43
|
+
content: '';
|
|
44
|
+
display: block;
|
|
45
|
+
width: var(--vaadin-icon-size, 1lh);
|
|
46
|
+
height: var(--vaadin-icon-size, 1lh);
|
|
47
|
+
background: currentColor;
|
|
48
|
+
mask-image: var(--_vaadin-icon-chevron-down);
|
|
49
|
+
}
|
|
51
50
|
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
51
|
+
:host(:not([expanded])) [part='toggle']::before {
|
|
52
|
+
rotate: -90deg;
|
|
53
|
+
}
|
|
55
54
|
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
}
|
|
55
|
+
@media (prefers-reduced-motion: no-preference) {
|
|
56
|
+
[part='toggle']::before {
|
|
57
|
+
transition: rotate 120ms;
|
|
60
58
|
}
|
|
59
|
+
}
|
|
61
60
|
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
61
|
+
:host([leaf]) [part='toggle'] {
|
|
62
|
+
visibility: hidden;
|
|
63
|
+
}
|
|
65
64
|
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
65
|
+
slot {
|
|
66
|
+
display: block;
|
|
67
|
+
overflow: hidden;
|
|
68
|
+
text-overflow: ellipsis;
|
|
69
|
+
}
|
|
71
70
|
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
}
|
|
71
|
+
@media (forced-colors: active) {
|
|
72
|
+
[part='toggle']::before {
|
|
73
|
+
background: CanvasText;
|
|
76
74
|
}
|
|
77
75
|
}
|
|
78
76
|
`;
|
|
@@ -59,9 +59,15 @@ export const ColumnAutoWidthMixin = (superClass) =>
|
|
|
59
59
|
}
|
|
60
60
|
|
|
61
61
|
/** @private */
|
|
62
|
-
__flatSizeChangedAutoWidth() {
|
|
62
|
+
__flatSizeChangedAutoWidth(flatSize) {
|
|
63
63
|
// Flat size changed, recalculate column widths if pending (asynchronously, to allow grid to render row elements first)
|
|
64
|
-
requestAnimationFrame(() =>
|
|
64
|
+
requestAnimationFrame(() => {
|
|
65
|
+
if (!!flatSize && !this.__hasHadRenderedRowsForColumnWidthCalculation) {
|
|
66
|
+
this.recalculateColumnWidths();
|
|
67
|
+
} else {
|
|
68
|
+
this.__tryToRecalculateColumnWidthsIfPending();
|
|
69
|
+
}
|
|
70
|
+
});
|
|
65
71
|
}
|
|
66
72
|
|
|
67
73
|
/**
|
|
@@ -7,7 +7,6 @@ import { microTask, timeOut } from '@vaadin/component-base/src/async.js';
|
|
|
7
7
|
import { DataProviderController } from '@vaadin/component-base/src/data-provider-controller/data-provider-controller.js';
|
|
8
8
|
import { Debouncer } from '@vaadin/component-base/src/debounce.js';
|
|
9
9
|
import { get } from '@vaadin/component-base/src/path-utils.js';
|
|
10
|
-
import { getBodyRowCells, updateCellsPart, updateState } from './vaadin-grid-helpers.js';
|
|
11
10
|
|
|
12
11
|
/**
|
|
13
12
|
* @polymerMixin
|
|
@@ -182,46 +181,20 @@ export const DataProviderMixin = (superClass) =>
|
|
|
182
181
|
this.requestContentUpdate();
|
|
183
182
|
}
|
|
184
183
|
|
|
185
|
-
/**
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
*/
|
|
190
|
-
_getItem(index, el) {
|
|
191
|
-
el.index = index;
|
|
192
|
-
|
|
193
|
-
const { item } = this._dataProviderController.getFlatIndexContext(index);
|
|
194
|
-
if (item) {
|
|
195
|
-
this.__updateLoading(el, false);
|
|
196
|
-
this._updateItem(el, item);
|
|
197
|
-
if (this._isExpanded(item)) {
|
|
198
|
-
this._dataProviderController.ensureFlatIndexHierarchy(index);
|
|
199
|
-
}
|
|
200
|
-
} else {
|
|
201
|
-
this.__updateLoading(el, true);
|
|
202
|
-
this._dataProviderController.ensureFlatIndexLoaded(index);
|
|
203
|
-
}
|
|
184
|
+
/** @private */
|
|
185
|
+
__getRowItem(row) {
|
|
186
|
+
const { item } = this._dataProviderController.getFlatIndexContext(row.index);
|
|
187
|
+
return item;
|
|
204
188
|
}
|
|
205
189
|
|
|
206
|
-
/**
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
*/
|
|
211
|
-
__updateLoading(row, loading) {
|
|
212
|
-
const cells = getBodyRowCells(row);
|
|
213
|
-
|
|
214
|
-
// Row state attribute
|
|
215
|
-
updateState(row, 'loading', loading);
|
|
216
|
-
|
|
217
|
-
// Cells part attribute
|
|
218
|
-
updateCellsPart(cells, 'loading-row-cell', loading);
|
|
190
|
+
/** @private */
|
|
191
|
+
__ensureRowItem(row) {
|
|
192
|
+
this._dataProviderController.ensureFlatIndexLoaded(row.index);
|
|
193
|
+
}
|
|
219
194
|
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
this._generateCellPartNames(row);
|
|
224
|
-
}
|
|
195
|
+
/** @private */
|
|
196
|
+
__ensureRowHierarchy(row) {
|
|
197
|
+
this._dataProviderController.ensureFlatIndexHierarchy(row.index);
|
|
225
198
|
}
|
|
226
199
|
|
|
227
200
|
/**
|
|
@@ -302,7 +275,7 @@ export const DataProviderMixin = (superClass) =>
|
|
|
302
275
|
if (this._flatSize !== this._dataProviderController.flatSize) {
|
|
303
276
|
// Schedule an update of all rendered rows by _debouncerApplyCachedData,
|
|
304
277
|
// to ensure that all pages associated with the rendered rows are loaded.
|
|
305
|
-
this.
|
|
278
|
+
this._shouldLoadAllRenderedRowsAfterPageLoad = true;
|
|
306
279
|
|
|
307
280
|
// TODO: Updating the flat size property can still result in a synchonous virtualizer update
|
|
308
281
|
// if the size change requires the virtualizer to increase the amount of physical elements
|
|
@@ -312,9 +285,7 @@ export const DataProviderMixin = (superClass) =>
|
|
|
312
285
|
}
|
|
313
286
|
|
|
314
287
|
// After updating the cache, check if some of the expanded items should have sub-caches loaded
|
|
315
|
-
this._getRenderedRows().forEach((row) =>
|
|
316
|
-
this._dataProviderController.ensureFlatIndexHierarchy(row.index);
|
|
317
|
-
});
|
|
288
|
+
this._getRenderedRows().forEach((row) => this.__ensureRowHierarchy(row));
|
|
318
289
|
|
|
319
290
|
this._hasData = true;
|
|
320
291
|
}
|
|
@@ -325,13 +296,14 @@ export const DataProviderMixin = (superClass) =>
|
|
|
325
296
|
this._debouncerApplyCachedData = Debouncer.debounce(this._debouncerApplyCachedData, timeOut.after(0), () => {
|
|
326
297
|
this._setLoading(false);
|
|
327
298
|
|
|
328
|
-
const
|
|
329
|
-
this.
|
|
299
|
+
const shouldLoadAllRenderedRowsAfterPageLoad = this._shouldLoadAllRenderedRowsAfterPageLoad;
|
|
300
|
+
this._shouldLoadAllRenderedRowsAfterPageLoad = false;
|
|
330
301
|
|
|
331
302
|
this._getRenderedRows().forEach((row) => {
|
|
332
|
-
|
|
333
|
-
|
|
334
|
-
|
|
303
|
+
this.__updateRow(row);
|
|
304
|
+
|
|
305
|
+
if (shouldLoadAllRenderedRowsAfterPageLoad) {
|
|
306
|
+
this.__ensureRowItem(row);
|
|
335
307
|
}
|
|
336
308
|
});
|
|
337
309
|
|
|
@@ -41,7 +41,7 @@ import { GridFilterElementMixin } from './vaadin-grid-filter-element-mixin.js';
|
|
|
41
41
|
* @extends HTMLElement
|
|
42
42
|
* @mixes GridFilterElementMixin
|
|
43
43
|
*/
|
|
44
|
-
class GridFilter extends GridFilterElementMixin(ThemableMixin(LumoInjectionMixin(
|
|
44
|
+
class GridFilter extends GridFilterElementMixin(ThemableMixin(PolylitMixin(LumoInjectionMixin(LitElement)))) {
|
|
45
45
|
static get is() {
|
|
46
46
|
return 'vaadin-grid-filter';
|
|
47
47
|
}
|
package/src/vaadin-grid-mixin.js
CHANGED
|
@@ -28,6 +28,7 @@ import {
|
|
|
28
28
|
iterateRowCells,
|
|
29
29
|
updateBooleanRowStates,
|
|
30
30
|
updateCellsPart,
|
|
31
|
+
updateState,
|
|
31
32
|
} from './vaadin-grid-helpers.js';
|
|
32
33
|
import { KeyboardNavigationMixin } from './vaadin-grid-keyboard-navigation-mixin.js';
|
|
33
34
|
import { RowDetailsMixin } from './vaadin-grid-row-details-mixin.js';
|
|
@@ -345,7 +346,7 @@ export const GridMixin = (superClass) =>
|
|
|
345
346
|
row.setAttribute('role', 'row');
|
|
346
347
|
row.setAttribute('tabindex', '-1');
|
|
347
348
|
if (this._columnTree) {
|
|
348
|
-
this.
|
|
349
|
+
this.__initRow(row, this._columnTree[this._columnTree.length - 1], 'body', false, true);
|
|
349
350
|
}
|
|
350
351
|
rows.push(row);
|
|
351
352
|
}
|
|
@@ -457,9 +458,9 @@ export const GridMixin = (superClass) =>
|
|
|
457
458
|
* @param {?string} section
|
|
458
459
|
* @param {boolean} isColumnRow
|
|
459
460
|
* @param {boolean} noNotify
|
|
460
|
-
* @
|
|
461
|
+
* @private
|
|
461
462
|
*/
|
|
462
|
-
|
|
463
|
+
__initRow(row, columns, section = 'body', isColumnRow = false, noNotify = false) {
|
|
463
464
|
const contentsFragment = document.createDocumentFragment();
|
|
464
465
|
|
|
465
466
|
iterateRowCells(row, (cell) => {
|
|
@@ -639,10 +640,15 @@ export const GridMixin = (superClass) =>
|
|
|
639
640
|
return;
|
|
640
641
|
}
|
|
641
642
|
|
|
643
|
+
row.index = index;
|
|
644
|
+
|
|
642
645
|
this._updateRowOrderParts(row, index);
|
|
643
646
|
|
|
644
647
|
this._a11yUpdateRowRowindex(row, index);
|
|
645
|
-
|
|
648
|
+
|
|
649
|
+
this.__ensureRowItem(row);
|
|
650
|
+
this.__ensureRowHierarchy(row);
|
|
651
|
+
this.__updateRow(row);
|
|
646
652
|
}
|
|
647
653
|
|
|
648
654
|
/** @private */
|
|
@@ -683,7 +689,7 @@ export const GridMixin = (superClass) =>
|
|
|
683
689
|
*/
|
|
684
690
|
_renderColumnTree(columnTree) {
|
|
685
691
|
iterateChildren(this.$.items, (row) => {
|
|
686
|
-
this.
|
|
692
|
+
this.__initRow(row, columnTree[columnTree.length - 1], 'body', false, true);
|
|
687
693
|
|
|
688
694
|
const model = this.__getRowModel(row);
|
|
689
695
|
this._updateRowOrderParts(row);
|
|
@@ -710,7 +716,7 @@ export const GridMixin = (superClass) =>
|
|
|
710
716
|
}
|
|
711
717
|
|
|
712
718
|
iterateChildren(this.$.header, (headerRow, index, rows) => {
|
|
713
|
-
this.
|
|
719
|
+
this.__initRow(headerRow, columnTree[index], 'header', index === columnTree.length - 1);
|
|
714
720
|
|
|
715
721
|
const cells = getBodyRowCells(headerRow);
|
|
716
722
|
updateCellsPart(cells, 'first-header-row-cell', index === 0);
|
|
@@ -718,7 +724,7 @@ export const GridMixin = (superClass) =>
|
|
|
718
724
|
});
|
|
719
725
|
|
|
720
726
|
iterateChildren(this.$.footer, (footerRow, index, rows) => {
|
|
721
|
-
this.
|
|
727
|
+
this.__initRow(footerRow, columnTree[columnTree.length - 1 - index], 'footer', index === 0);
|
|
722
728
|
|
|
723
729
|
const cells = getBodyRowCells(footerRow);
|
|
724
730
|
updateCellsPart(cells, 'first-footer-row-cell', index === 0);
|
|
@@ -726,7 +732,7 @@ export const GridMixin = (superClass) =>
|
|
|
726
732
|
});
|
|
727
733
|
|
|
728
734
|
// Sizer rows
|
|
729
|
-
this.
|
|
735
|
+
this.__initRow(this.$.sizer, columnTree[columnTree.length - 1]);
|
|
730
736
|
|
|
731
737
|
this._resizeHandler();
|
|
732
738
|
this._frozenCellsChanged();
|
|
@@ -741,10 +747,38 @@ export const GridMixin = (superClass) =>
|
|
|
741
747
|
|
|
742
748
|
/**
|
|
743
749
|
* @param {!HTMLElement} row
|
|
744
|
-
* @param {
|
|
745
|
-
* @
|
|
750
|
+
* @param {boolean} loading
|
|
751
|
+
* @private
|
|
746
752
|
*/
|
|
747
|
-
|
|
753
|
+
__updateRowLoading(row, loading) {
|
|
754
|
+
const cells = getBodyRowCells(row);
|
|
755
|
+
|
|
756
|
+
// Row state attribute
|
|
757
|
+
updateState(row, 'loading', loading);
|
|
758
|
+
|
|
759
|
+
// Cells part attribute
|
|
760
|
+
updateCellsPart(cells, 'loading-row-cell', loading);
|
|
761
|
+
|
|
762
|
+
if (loading) {
|
|
763
|
+
// Run style generators for the loading row to have custom names cleared
|
|
764
|
+
this._generateCellClassNames(row);
|
|
765
|
+
this._generateCellPartNames(row);
|
|
766
|
+
}
|
|
767
|
+
}
|
|
768
|
+
|
|
769
|
+
/**
|
|
770
|
+
* @param {!HTMLElement} row
|
|
771
|
+
* @private
|
|
772
|
+
*/
|
|
773
|
+
__updateRow(row) {
|
|
774
|
+
const item = this.__getRowItem(row);
|
|
775
|
+
if (item) {
|
|
776
|
+
this.__updateRowLoading(row, false);
|
|
777
|
+
} else {
|
|
778
|
+
this.__updateRowLoading(row, true);
|
|
779
|
+
return;
|
|
780
|
+
}
|
|
781
|
+
|
|
748
782
|
row._item = item;
|
|
749
783
|
const model = this.__getRowModel(row);
|
|
750
784
|
|
|
@@ -85,7 +85,7 @@ export const RowDetailsMixin = (superClass) =>
|
|
|
85
85
|
// Only update the rows if the column tree has already been initialized
|
|
86
86
|
iterateChildren(this.$.items, (row) => {
|
|
87
87
|
if (!row.querySelector('[part~=details-cell]')) {
|
|
88
|
-
this.
|
|
88
|
+
this.__initRow(row, this._columnTree[this._columnTree.length - 1]);
|
|
89
89
|
const isDetailsOpened = this._isDetailsOpened(row._item);
|
|
90
90
|
this._toggleDetailsCell(row, isDetailsOpened);
|
|
91
91
|
}
|
|
@@ -98,13 +98,13 @@ export const RowDetailsMixin = (superClass) =>
|
|
|
98
98
|
iterateChildren(this.$.items, (row) => {
|
|
99
99
|
// Re-renders the row to possibly close the previously opened details.
|
|
100
100
|
if (row.hasAttribute('details-opened')) {
|
|
101
|
-
this.
|
|
101
|
+
this.__updateRow(row);
|
|
102
102
|
return;
|
|
103
103
|
}
|
|
104
104
|
|
|
105
105
|
// Re-renders the row to open the details when a row details renderer is provided.
|
|
106
106
|
if (rowDetailsRenderer && this._isDetailsOpened(row._item)) {
|
|
107
|
-
this.
|
|
107
|
+
this.__updateRow(row);
|
|
108
108
|
}
|
|
109
109
|
});
|
|
110
110
|
}
|
|
@@ -140,7 +140,7 @@ export const RowDetailsMixin = (superClass) =>
|
|
|
140
140
|
}
|
|
141
141
|
|
|
142
142
|
// Assigns a renderer when the details cell is opened.
|
|
143
|
-
// The details cell content is rendered later in the `
|
|
143
|
+
// The details cell content is rendered later in the `__updateRow` method.
|
|
144
144
|
if (this.rowDetailsRenderer) {
|
|
145
145
|
cell._renderer = this.rowDetailsRenderer;
|
|
146
146
|
}
|
|
@@ -57,7 +57,7 @@ import { GridSorterMixin } from './vaadin-grid-sorter-mixin.js';
|
|
|
57
57
|
* @mixes ThemableMixin
|
|
58
58
|
* @mixes DirMixin
|
|
59
59
|
*/
|
|
60
|
-
class GridSorter extends GridSorterMixin(ThemableMixin(DirMixin(LumoInjectionMixin(
|
|
60
|
+
class GridSorter extends GridSorterMixin(ThemableMixin(DirMixin(PolylitMixin(LumoInjectionMixin(LitElement))))) {
|
|
61
61
|
static get is() {
|
|
62
62
|
return 'vaadin-grid-sorter';
|
|
63
63
|
}
|
|
@@ -67,7 +67,7 @@ import { GridTreeToggleMixin } from './vaadin-grid-tree-toggle-mixin.js';
|
|
|
67
67
|
* @mixes GridTreeToggleMixin
|
|
68
68
|
*/
|
|
69
69
|
class GridTreeToggle extends GridTreeToggleMixin(
|
|
70
|
-
ThemableMixin(DirMixin(LumoInjectionMixin(
|
|
70
|
+
ThemableMixin(DirMixin(PolylitMixin(LumoInjectionMixin(LitElement)))),
|
|
71
71
|
) {
|
|
72
72
|
static get is() {
|
|
73
73
|
return 'vaadin-grid-tree-toggle';
|
package/src/vaadin-grid.js
CHANGED
|
@@ -262,7 +262,7 @@ import { GridMixin } from './vaadin-grid-mixin.js';
|
|
|
262
262
|
* @mixes GridMixin
|
|
263
263
|
* @mixes ThemableMixin
|
|
264
264
|
*/
|
|
265
|
-
class Grid extends GridMixin(ElementMixin(ThemableMixin(LumoInjectionMixin(
|
|
265
|
+
class Grid extends GridMixin(ElementMixin(ThemableMixin(PolylitMixin(LumoInjectionMixin(LitElement))))) {
|
|
266
266
|
static get is() {
|
|
267
267
|
return 'vaadin-grid';
|
|
268
268
|
}
|