@vonage/vivid 5.8.0 → 5.10.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/bundled/affix.js +1 -1
- package/bundled/anchored.cjs +1 -1
- package/bundled/anchored.js +6 -6
- package/bundled/data-grid.options.cjs +1 -0
- package/bundled/data-grid.options.js +29 -0
- package/bundled/definition10.js +4 -4
- package/bundled/definition2.cjs +1 -1
- package/bundled/definition2.js +1 -1
- package/bundled/definition3.cjs +1 -1
- package/bundled/definition3.js +1 -1
- package/bundled/definition7.js +3 -3
- package/bundled/definition9.cjs +9 -9
- package/bundled/definition9.js +113 -1342
- package/bundled/floating-ui.dom.cjs +1 -0
- package/bundled/floating-ui.dom.js +1242 -0
- package/bundled/host-semantics.js +4 -4
- package/bundled/localized.cjs +1 -1
- package/bundled/localized.js +21 -16
- package/bundled/mixins.cjs +2 -2
- package/bundled/mixins.js +6 -6
- package/bundled/slottable-request.cjs +4 -0
- package/bundled/slottable-request.js +2907 -0
- package/bundled/vivid-element.cjs +3 -3
- package/bundled/vivid-element.js +89 -69
- package/card/definition.cjs +1 -1
- package/card/definition.js +1 -1
- package/card/index.cjs +10 -10
- package/card/index.js +42 -42
- package/combobox/definition.cjs +14 -15
- package/combobox/definition.js +15 -16
- package/combobox/index.cjs +4 -4
- package/combobox/index.js +82 -87
- package/country/definition.cjs +340 -0
- package/country/definition.js +334 -0
- package/country/index.cjs +12 -0
- package/country/index.js +317 -0
- package/custom-elements.json +4835 -613
- package/data-grid/definition.cjs +23 -49
- package/data-grid/definition.js +1 -27
- package/data-grid/index.cjs +27 -27
- package/data-grid/index.js +44 -64
- package/file-picker/definition.cjs +10 -8
- package/file-picker/definition.js +10 -8
- package/file-picker/index.cjs +5 -5
- package/file-picker/index.js +12 -12
- package/icon/definition.cjs +1 -1
- package/icon/definition.js +1 -1
- package/index.cjs +38 -4
- package/index.js +7 -2
- package/lib/components.d.ts +6 -1
- package/lib/country/countries-data.d.ts +6 -0
- package/lib/country/country-code-to-flag-icon.d.ts +5 -0
- package/lib/country/country.d.ts +5 -0
- package/lib/country/country.template.d.ts +3 -0
- package/lib/country/definition.d.ts +3 -0
- package/lib/popover/definition.d.ts +4 -0
- package/lib/popover/locale.d.ts +3 -0
- package/lib/popover/popover.d.ts +781 -0
- package/lib/popover/popover.template.d.ts +3 -0
- package/lib/rich-text-editor/locale.d.ts +2 -0
- package/lib/rich-text-editor/popover.d.ts +1 -0
- package/lib/rich-text-editor/rte/config.d.ts +5 -1
- package/lib/rich-text-editor/rte/document.d.ts +2 -0
- package/lib/rich-text-editor/rte/exports.d.ts +5 -0
- package/lib/rich-text-editor/rte/feature.d.ts +7 -1
- package/lib/rich-text-editor/rte/features/internal/basic-text-blocks.d.ts +1 -1
- package/lib/rich-text-editor/rte/features/internal/foreign-html.d.ts +1 -1
- package/lib/rich-text-editor/rte/features/internal/history.d.ts +1 -1
- package/lib/rich-text-editor/rte/features/internal/input-rules.d.ts +15 -0
- package/lib/rich-text-editor/rte/instance.d.ts +4 -2
- package/lib/rich-text-editor/rte/utils/feature-state.d.ts +8 -0
- package/lib/rich-text-editor/rte/utils/text-before-cursor.d.ts +2 -0
- package/lib/rich-text-editor/rte/utils/ui.d.ts +2 -0
- package/lib/rich-text-editor/rte/view.d.ts +30 -0
- package/lib/rich-text-view/definition.d.ts +5 -0
- package/lib/rich-text-view/rich-text-view.d.ts +19 -0
- package/lib/rich-text-view/rich-text-view.template.d.ts +3 -0
- package/lib/selectable-box/selectable-box.d.ts +1 -0
- package/lib/status/definition.d.ts +4 -0
- package/lib/status/status.d.ts +388 -0
- package/lib/status/status.template.d.ts +3 -0
- package/lib/table/definition.d.ts +8 -0
- package/lib/table/table-body.d.ts +3 -0
- package/lib/table/table-body.template.d.ts +3 -0
- package/lib/table/table-cell.d.ts +381 -0
- package/lib/table/table-cell.template.d.ts +3 -0
- package/lib/table/table-head.d.ts +3 -0
- package/lib/table/table-head.template.d.ts +3 -0
- package/lib/table/table-header-cell.d.ts +381 -0
- package/lib/table/table-header-cell.template.d.ts +3 -0
- package/lib/table/table-row.d.ts +381 -0
- package/lib/table/table-row.template.d.ts +3 -0
- package/lib/table/table.d.ts +3 -0
- package/lib/table/table.template.d.ts +3 -0
- package/lib/tag/tag.d.ts +1 -1
- package/lib/tag-name-map.d.ts +11 -1
- package/locales/de-DE.cjs +6 -1
- package/locales/de-DE.js +6 -1
- package/locales/en-GB.cjs +6 -1
- package/locales/en-GB.js +6 -1
- package/locales/en-US.cjs +6 -1
- package/locales/en-US.js +6 -1
- package/locales/ja-JP.cjs +6 -1
- package/locales/ja-JP.js +6 -1
- package/locales/zh-CN.cjs +6 -1
- package/locales/zh-CN.js +6 -1
- package/package.json +10 -9
- package/popover/definition.cjs +363 -0
- package/popover/definition.js +357 -0
- package/popover/index.cjs +27 -0
- package/popover/index.js +263 -0
- package/rich-text-editor/definition.cjs +12125 -14657
- package/rich-text-editor/definition.js +8876 -11412
- package/rich-text-editor/index.cjs +20 -22
- package/rich-text-editor/index.js +5046 -7096
- package/rich-text-view/definition.cjs +171 -0
- package/rich-text-view/definition.js +165 -0
- package/rich-text-view/index.cjs +1 -0
- package/rich-text-view/index.js +103 -0
- package/selectable-box/definition.cjs +16 -5
- package/selectable-box/definition.js +16 -5
- package/selectable-box/index.cjs +11 -9
- package/selectable-box/index.js +86 -78
- package/shared/localization/Locale.d.ts +2 -0
- package/shared/utils/slottable-request.d.ts +7 -0
- package/status/definition.cjs +76 -0
- package/status/definition.js +70 -0
- package/status/index.cjs +11 -0
- package/status/index.js +55 -0
- package/styles/core/all.css +2 -2
- package/styles/core/theme.css +2 -2
- package/styles/core/typography.css +1 -1
- package/styles/tokens/theme-dark.css +4 -4
- package/styles/tokens/theme-light.css +4 -4
- package/styles/tokens/vivid-2-compat.css +1 -1
- package/table/definition.cjs +168 -0
- package/table/definition.js +152 -0
- package/table/index.cjs +37 -0
- package/table/index.js +107 -0
- package/tag/definition.cjs +1 -1
- package/tag/definition.js +1 -1
- package/tag/index.cjs +24 -24
- package/tag/index.js +89 -89
- package/unbundled/_commonjsHelpers.cjs +26 -0
- package/unbundled/_commonjsHelpers.js +26 -1
- package/unbundled/data-grid.options.cjs +34 -0
- package/unbundled/data-grid.options.js +28 -0
- package/unbundled/definition.cjs +1 -1
- package/unbundled/definition.js +1 -1
- package/unbundled/slottable-request.cjs +3702 -0
- package/unbundled/slottable-request.js +3684 -0
- package/unbundled/vivid-element.cjs +1 -1
- package/unbundled/vivid-element.js +1 -1
- package/video-player/definition.cjs +11 -1
- package/video-player/definition.js +12 -2
- package/video-player/index.cjs +30 -30
- package/video-player/index.js +705 -702
- package/vivid.api.json +1957 -143
package/data-grid/definition.cjs
CHANGED
|
@@ -8,6 +8,7 @@ const visuallyHidden_definition = require('../visually-hidden/definition.cjs');
|
|
|
8
8
|
const fastElement = require('@microsoft/fast-element');
|
|
9
9
|
const _commonjsHelpers = require('../unbundled/_commonjsHelpers.cjs');
|
|
10
10
|
const fastWebUtilities = require('@microsoft/fast-web-utilities');
|
|
11
|
+
const dataGrid_options = require('../unbundled/data-grid.options.cjs');
|
|
11
12
|
const keyCodes = require('../unbundled/key-codes.cjs');
|
|
12
13
|
const hostSemantics = require('../unbundled/host-semantics.cjs');
|
|
13
14
|
const localized = require('../unbundled/localized.cjs');
|
|
@@ -882,33 +883,6 @@ const ViewBehaviorOrchestrator = Object.freeze({
|
|
|
882
883
|
},
|
|
883
884
|
});
|
|
884
885
|
|
|
885
|
-
const DataGridCellSortStates = {
|
|
886
|
-
none: "none",
|
|
887
|
-
ascending: "ascending",
|
|
888
|
-
descending: "descending",
|
|
889
|
-
other: "other"
|
|
890
|
-
};
|
|
891
|
-
const GenerateHeaderOptions = {
|
|
892
|
-
none: "none",
|
|
893
|
-
default: "default",
|
|
894
|
-
sticky: "sticky"
|
|
895
|
-
};
|
|
896
|
-
const DataGridCellTypes = {
|
|
897
|
-
default: "default",
|
|
898
|
-
columnHeader: "columnheader",
|
|
899
|
-
rowHeader: "rowheader"
|
|
900
|
-
};
|
|
901
|
-
const DataGridRowTypes = {
|
|
902
|
-
default: "default",
|
|
903
|
-
header: "header",
|
|
904
|
-
stickyHeader: "sticky-header"
|
|
905
|
-
};
|
|
906
|
-
const DataGridCellRole = {
|
|
907
|
-
columnheader: "columnheader",
|
|
908
|
-
rowheader: "rowheader",
|
|
909
|
-
default: "gridcell"
|
|
910
|
-
};
|
|
911
|
-
|
|
912
886
|
var __defProp$2 = Object.defineProperty;
|
|
913
887
|
var __decorateClass$2 = (decorators, target, key, kind) => {
|
|
914
888
|
var result = void 0 ;
|
|
@@ -932,7 +906,7 @@ class DataGridCell extends localized.Localized(hostSemantics.HostSemantics(vivid
|
|
|
932
906
|
constructor() {
|
|
933
907
|
super(...arguments);
|
|
934
908
|
// eslint-disable-next-line @repo/repo/no-attribute-default-value
|
|
935
|
-
this.cellType = DataGridCellTypes.default;
|
|
909
|
+
this.cellType = dataGrid_options.DataGridCellTypes.default;
|
|
936
910
|
this.rowData = null;
|
|
937
911
|
this.columnDefinition = null;
|
|
938
912
|
this.isActiveCell = false;
|
|
@@ -1041,7 +1015,7 @@ class DataGridCell extends localized.Localized(hostSemantics.HostSemantics(vivid
|
|
|
1041
1015
|
}
|
|
1042
1016
|
this.isActiveCell = true;
|
|
1043
1017
|
switch (this.cellType) {
|
|
1044
|
-
case DataGridCellTypes.columnHeader:
|
|
1018
|
+
case dataGrid_options.DataGridCellTypes.columnHeader:
|
|
1045
1019
|
if (this.columnDefinition !== null && this.columnDefinition.headerCellInternalFocusQueue !== true && typeof this.columnDefinition.headerCellFocusTargetCallback === "function") {
|
|
1046
1020
|
const focusTarget = this.columnDefinition.headerCellFocusTargetCallback(this);
|
|
1047
1021
|
/* v8 ignore else -- @preserve */
|
|
@@ -1070,7 +1044,7 @@ class DataGridCell extends localized.Localized(hostSemantics.HostSemantics(vivid
|
|
|
1070
1044
|
}
|
|
1071
1045
|
}
|
|
1072
1046
|
handleKeydown(e) {
|
|
1073
|
-
if (e.defaultPrevented || this.columnDefinition === null || this.cellType === DataGridCellTypes.default && this.columnDefinition.cellInternalFocusQueue !== true || this.cellType === DataGridCellTypes.columnHeader && this.columnDefinition.headerCellInternalFocusQueue !== true) {
|
|
1047
|
+
if (e.defaultPrevented || this.columnDefinition === null || this.cellType === dataGrid_options.DataGridCellTypes.default && this.columnDefinition.cellInternalFocusQueue !== true || this.cellType === dataGrid_options.DataGridCellTypes.columnHeader && this.columnDefinition.headerCellInternalFocusQueue !== true) {
|
|
1074
1048
|
return;
|
|
1075
1049
|
}
|
|
1076
1050
|
switch (e.key) {
|
|
@@ -1080,7 +1054,7 @@ class DataGridCell extends localized.Localized(hostSemantics.HostSemantics(vivid
|
|
|
1080
1054
|
return;
|
|
1081
1055
|
}
|
|
1082
1056
|
switch (this.cellType) {
|
|
1083
|
-
case DataGridCellTypes.columnHeader: {
|
|
1057
|
+
case dataGrid_options.DataGridCellTypes.columnHeader: {
|
|
1084
1058
|
if (this.columnDefinition.headerCellFocusTargetCallback !== void 0) {
|
|
1085
1059
|
const focusTarget = this.columnDefinition.headerCellFocusTargetCallback(this);
|
|
1086
1060
|
/* v8 ignore else -- @preserve */
|
|
@@ -1120,7 +1094,7 @@ class DataGridCell extends localized.Localized(hostSemantics.HostSemantics(vivid
|
|
|
1120
1094
|
return;
|
|
1121
1095
|
}
|
|
1122
1096
|
switch (this.cellType) {
|
|
1123
|
-
case DataGridCellTypes.columnHeader:
|
|
1097
|
+
case dataGrid_options.DataGridCellTypes.columnHeader:
|
|
1124
1098
|
if (this.columnDefinition.headerCellTemplate !== void 0) {
|
|
1125
1099
|
this.customCellView = this.columnDefinition.headerCellTemplate.render(
|
|
1126
1100
|
this,
|
|
@@ -1133,8 +1107,8 @@ class DataGridCell extends localized.Localized(hostSemantics.HostSemantics(vivid
|
|
|
1133
1107
|
);
|
|
1134
1108
|
}
|
|
1135
1109
|
break;
|
|
1136
|
-
case DataGridCellTypes.rowHeader:
|
|
1137
|
-
case DataGridCellTypes.default:
|
|
1110
|
+
case dataGrid_options.DataGridCellTypes.rowHeader:
|
|
1111
|
+
case dataGrid_options.DataGridCellTypes.default:
|
|
1138
1112
|
if (this.columnDefinition.cellTemplate !== void 0) {
|
|
1139
1113
|
this.customCellView = this.columnDefinition.cellTemplate.render(
|
|
1140
1114
|
this,
|
|
@@ -1150,7 +1124,7 @@ class DataGridCell extends localized.Localized(hostSemantics.HostSemantics(vivid
|
|
|
1150
1124
|
} else if (this.columnDefinition.sortDirection) {
|
|
1151
1125
|
this.sortDirection = this.columnDefinition.sortDirection;
|
|
1152
1126
|
} else {
|
|
1153
|
-
this.sortDirection = DataGridCellSortStates.none;
|
|
1127
|
+
this.sortDirection = dataGrid_options.DataGridCellSortStates.none;
|
|
1154
1128
|
}
|
|
1155
1129
|
}
|
|
1156
1130
|
disconnectCellView() {
|
|
@@ -1240,7 +1214,7 @@ class DataGridRow extends hostSemantics.HostSemantics(vividElement.VividElement)
|
|
|
1240
1214
|
constructor() {
|
|
1241
1215
|
super(...arguments);
|
|
1242
1216
|
// eslint-disable-next-line @repo/repo/no-attribute-default-value
|
|
1243
|
-
this.rowType = DataGridRowTypes.default;
|
|
1217
|
+
this.rowType = dataGrid_options.DataGridRowTypes.default;
|
|
1244
1218
|
this.rowData = null;
|
|
1245
1219
|
this.columnDefinitions = null;
|
|
1246
1220
|
this.behaviorOrchestrator = null;
|
|
@@ -1370,7 +1344,7 @@ class DataGridRow extends hostSemantics.HostSemantics(vividElement.VividElement)
|
|
|
1370
1344
|
}
|
|
1371
1345
|
}
|
|
1372
1346
|
updateItemTemplate() {
|
|
1373
|
-
this.activeCellItemTemplate = this.rowType === DataGridRowTypes.default && this.cellItemTemplate !== void 0 ? this.cellItemTemplate : this.rowType === DataGridRowTypes.default && this.cellItemTemplate === void 0 ? this.defaultCellItemTemplate : this.headerCellItemTemplate !== void 0 ? this.headerCellItemTemplate : this.defaultHeaderCellItemTemplate;
|
|
1347
|
+
this.activeCellItemTemplate = this.rowType === dataGrid_options.DataGridRowTypes.default && this.cellItemTemplate !== void 0 ? this.cellItemTemplate : this.rowType === dataGrid_options.DataGridRowTypes.default && this.cellItemTemplate === void 0 ? this.defaultCellItemTemplate : this.headerCellItemTemplate !== void 0 ? this.headerCellItemTemplate : this.defaultHeaderCellItemTemplate;
|
|
1374
1348
|
}
|
|
1375
1349
|
/**
|
|
1376
1350
|
* @internal
|
|
@@ -1443,7 +1417,7 @@ const _DataGrid = class _DataGrid extends vividElement.VividElement {
|
|
|
1443
1417
|
super();
|
|
1444
1418
|
this.noTabbing = false;
|
|
1445
1419
|
// eslint-disable-next-line @repo/repo/no-attribute-default-value
|
|
1446
|
-
this.generateHeader = GenerateHeaderOptions.default;
|
|
1420
|
+
this.generateHeader = dataGrid_options.GenerateHeaderOptions.default;
|
|
1447
1421
|
this.rowsData = [];
|
|
1448
1422
|
this.columnDefinitions = null;
|
|
1449
1423
|
this.focusRowIndex = 0;
|
|
@@ -1885,7 +1859,7 @@ const _DataGrid = class _DataGrid extends vividElement.VividElement {
|
|
|
1885
1859
|
const thisRow = this.rowElements[newFocusRowIndex];
|
|
1886
1860
|
if (thisRow.offsetTop + thisRow.offsetHeight > currentGridBottom) {
|
|
1887
1861
|
let stickyHeaderOffset = 0;
|
|
1888
|
-
if (this.generateHeader === GenerateHeaderOptions.sticky && this.generatedHeader !== null) {
|
|
1862
|
+
if (this.generateHeader === dataGrid_options.GenerateHeaderOptions.sticky && this.generatedHeader !== null) {
|
|
1889
1863
|
stickyHeaderOffset = this.generatedHeader.clientHeight;
|
|
1890
1864
|
}
|
|
1891
1865
|
this.scrollTop = thisRow.offsetTop - stickyHeaderOffset;
|
|
@@ -1934,14 +1908,14 @@ const _DataGrid = class _DataGrid extends vividElement.VividElement {
|
|
|
1934
1908
|
this.removeChild(this.generatedHeader);
|
|
1935
1909
|
this.generatedHeader = null;
|
|
1936
1910
|
}
|
|
1937
|
-
if (this.generateHeader !== GenerateHeaderOptions.none && this.columnDefinitions !== null) {
|
|
1911
|
+
if (this.generateHeader !== dataGrid_options.GenerateHeaderOptions.none && this.columnDefinitions !== null) {
|
|
1938
1912
|
const generatedHeaderElement = document.createElement(
|
|
1939
1913
|
this.rowElementTag
|
|
1940
1914
|
);
|
|
1941
1915
|
this.generatedHeader = generatedHeaderElement;
|
|
1942
1916
|
this.generatedHeader.columnDefinitions = this.columnDefinitions;
|
|
1943
1917
|
this.generatedHeader.gridTemplateColumns = this.gridTemplateColumns;
|
|
1944
|
-
this.generatedHeader.rowType = this.generateHeader === GenerateHeaderOptions.sticky ? DataGridRowTypes.stickyHeader : DataGridRowTypes.header;
|
|
1918
|
+
this.generatedHeader.rowType = this.generateHeader === dataGrid_options.GenerateHeaderOptions.sticky ? dataGrid_options.DataGridRowTypes.stickyHeader : dataGrid_options.DataGridRowTypes.header;
|
|
1945
1919
|
/* v8 ignore else -- @preserve */
|
|
1946
1920
|
if (this.firstChild !== null) {
|
|
1947
1921
|
this.insertBefore(generatedHeaderElement, this.firstChild);
|
|
@@ -2133,11 +2107,11 @@ function setHeaderRow(x) {
|
|
|
2133
2107
|
const headerRow = x.querySelector(
|
|
2134
2108
|
'[cell-type="columnheader"]'
|
|
2135
2109
|
)?.parentElement;
|
|
2136
|
-
if (x.generateHeader === GenerateHeaderOptions.default && (headerRow?.getAttribute("row-type") === DataGridRowTypes.header || headerRow?.getAttribute("row-type") === DataGridRowTypes.stickyHeader)) {
|
|
2110
|
+
if (x.generateHeader === dataGrid_options.GenerateHeaderOptions.default && (headerRow?.getAttribute("row-type") === dataGrid_options.DataGridRowTypes.header || headerRow?.getAttribute("row-type") === dataGrid_options.DataGridRowTypes.stickyHeader)) {
|
|
2137
2111
|
return;
|
|
2138
2112
|
}
|
|
2139
2113
|
if (headerRow) {
|
|
2140
|
-
const rowType = x.generateHeader === GenerateHeaderOptions.sticky ? DataGridRowTypes.stickyHeader : DataGridRowTypes.header;
|
|
2114
|
+
const rowType = x.generateHeader === dataGrid_options.GenerateHeaderOptions.sticky ? dataGrid_options.DataGridRowTypes.stickyHeader : dataGrid_options.DataGridRowTypes.header;
|
|
2141
2115
|
headerRow.setAttribute("row-type", rowType);
|
|
2142
2116
|
}
|
|
2143
2117
|
}
|
|
@@ -2227,13 +2201,13 @@ const DataGridRowTemplate = (context) => {
|
|
|
2227
2201
|
};
|
|
2228
2202
|
|
|
2229
2203
|
function shouldShowSortIcons(x) {
|
|
2230
|
-
return x.cellType === "columnheader" && x.sortDirection !== void 0 && x.sortDirection !== DataGridCellSortStates.other;
|
|
2204
|
+
return x.cellType === "columnheader" && x.sortDirection !== void 0 && x.sortDirection !== dataGrid_options.DataGridCellSortStates.other;
|
|
2231
2205
|
}
|
|
2232
2206
|
function getSortIcon(x) {
|
|
2233
|
-
if (x.sortDirection === DataGridCellSortStates.ascending) {
|
|
2207
|
+
if (x.sortDirection === dataGrid_options.DataGridCellSortStates.ascending) {
|
|
2234
2208
|
return "sort-asc-solid";
|
|
2235
2209
|
}
|
|
2236
|
-
if (x.sortDirection === DataGridCellSortStates.descending) {
|
|
2210
|
+
if (x.sortDirection === dataGrid_options.DataGridCellSortStates.descending) {
|
|
2237
2211
|
return "sort-desc-solid";
|
|
2238
2212
|
}
|
|
2239
2213
|
return "sort-solid";
|
|
@@ -2255,10 +2229,10 @@ function renderSortIcons(c) {
|
|
|
2255
2229
|
`;
|
|
2256
2230
|
}
|
|
2257
2231
|
function shouldAnnounceSortState(x) {
|
|
2258
|
-
return x.cellType === DataGridCellTypes.columnHeader && x.sortDirection !== void 0;
|
|
2232
|
+
return x.cellType === dataGrid_options.DataGridCellTypes.columnHeader && x.sortDirection !== void 0;
|
|
2259
2233
|
}
|
|
2260
2234
|
function getSortStateKey(x) {
|
|
2261
|
-
return x.sortDirection ?? DataGridCellSortStates.none;
|
|
2235
|
+
return x.sortDirection ?? dataGrid_options.DataGridCellSortStates.none;
|
|
2262
2236
|
}
|
|
2263
2237
|
function getLocalizedSortStatus(x) {
|
|
2264
2238
|
const direction = getSortStateKey(x);
|
|
@@ -2286,7 +2260,7 @@ const DataGridCellTemplate = (context) => {
|
|
|
2286
2260
|
<template
|
|
2287
2261
|
tabindex="-1"
|
|
2288
2262
|
${hostSemantics.applyHostSemantics({
|
|
2289
|
-
role: (x) => DataGridCellRole[x.cellType] ?? DataGridCellRole.default,
|
|
2263
|
+
role: (x) => dataGrid_options.DataGridCellRole[x.cellType] ?? dataGrid_options.DataGridCellRole.default,
|
|
2290
2264
|
ariaSelected: calculateAriaSelectedValue,
|
|
2291
2265
|
ariaSort: (x) => x.sortDirection ?? null
|
|
2292
2266
|
})}
|
package/data-grid/definition.js
CHANGED
|
@@ -4,6 +4,7 @@ import { VwcVisuallyHiddenElement as VisuallyHidden, visuallyHiddenDefinition }
|
|
|
4
4
|
import { html, attr, observable, RepeatDirective, normalizeBinding, Updates as Updates$1, Observable, nullableNumberConverter, children, slotted, elements, when } from '@microsoft/fast-element';
|
|
5
5
|
import { c as commonjsGlobal } from '../unbundled/_commonjsHelpers.js';
|
|
6
6
|
import { eventFocusIn, eventFocusOut, eventKeyDown, keyEscape, keyFunction2, keyEnter, keyEnd, keyHome, eventFocus, keyPageDown, keyPageUp, keyArrowDown, keyArrowUp, classNames, keySpace } from '@microsoft/fast-web-utilities';
|
|
7
|
+
import { D as DataGridCellTypes, a as DataGridCellSortStates, b as DataGridRowTypes, G as GenerateHeaderOptions, c as DataGridCellRole } from '../unbundled/data-grid.options.js';
|
|
7
8
|
import { k as keyArrowRight, a as keyArrowLeft } from '../unbundled/key-codes.js';
|
|
8
9
|
import { H as HostSemantics, a as applyHostSemantics } from '../unbundled/host-semantics.js';
|
|
9
10
|
import { L as Localized } from '../unbundled/localized.js';
|
|
@@ -878,33 +879,6 @@ const ViewBehaviorOrchestrator = Object.freeze({
|
|
|
878
879
|
},
|
|
879
880
|
});
|
|
880
881
|
|
|
881
|
-
const DataGridCellSortStates = {
|
|
882
|
-
none: "none",
|
|
883
|
-
ascending: "ascending",
|
|
884
|
-
descending: "descending",
|
|
885
|
-
other: "other"
|
|
886
|
-
};
|
|
887
|
-
const GenerateHeaderOptions = {
|
|
888
|
-
none: "none",
|
|
889
|
-
default: "default",
|
|
890
|
-
sticky: "sticky"
|
|
891
|
-
};
|
|
892
|
-
const DataGridCellTypes = {
|
|
893
|
-
default: "default",
|
|
894
|
-
columnHeader: "columnheader",
|
|
895
|
-
rowHeader: "rowheader"
|
|
896
|
-
};
|
|
897
|
-
const DataGridRowTypes = {
|
|
898
|
-
default: "default",
|
|
899
|
-
header: "header",
|
|
900
|
-
stickyHeader: "sticky-header"
|
|
901
|
-
};
|
|
902
|
-
const DataGridCellRole = {
|
|
903
|
-
columnheader: "columnheader",
|
|
904
|
-
rowheader: "rowheader",
|
|
905
|
-
default: "gridcell"
|
|
906
|
-
};
|
|
907
|
-
|
|
908
882
|
var __defProp$2 = Object.defineProperty;
|
|
909
883
|
var __decorateClass$2 = (decorators, target, key, kind) => {
|
|
910
884
|
var result = void 0 ;
|
package/data-grid/index.cjs
CHANGED
|
@@ -1,33 +1,33 @@
|
|
|
1
|
-
"use strict";const
|
|
1
|
+
"use strict";const S=require("../bundled/definition2.cjs"),n=require("../bundled/vivid-element.cjs"),$=require("../bundled/definition14.cjs"),a=require("../bundled/data-grid.options.cjs"),F=require("../bundled/repeat.cjs"),y=require("../bundled/normalize.cjs"),h=require("../bundled/key-codes.cjs"),D=require("../bundled/host-semantics.cjs"),R=require("../bundled/children.cjs"),w=require("../bundled/slotted.cjs"),O=require("../bundled/localized.cjs"),H=require("../bundled/class-names.cjs"),T=require("../bundled/when.cjs"),I="focus",E="focusin",b="focusout",g="keydown",z=":host{display:block}:host([generate-header=sticky]){max-block-size:400px}.base{--scrollbar-track-color: transparent;--scrollbar-thumb-color: color-mix(in srgb, var(--vvd-color-neutral-950), transparent 70%)}.base{scrollbar-color:var(--scrollbar-thumb-color) var(--scrollbar-track-color);scrollbar-width:thin}.base ::-webkit-scrollbar{width:4px}.base ::-webkit-scrollbar-track{background:var(--scrollbar-track-color)}.base ::-webkit-scrollbar-thumb{border:0;border-radius:4px;background-color:var(--scrollbar-fallback-track-color, var(--scrollbar-thumb-color))}.base{position:relative;overflow:auto;block-size:inherit;inline-size:100%;max-block-size:inherit}",A=".base.connotation-cta{--_connotation-color-primary: var(--vvd-data-grid-row-cta-primary, var(--vvd-color-cta-500));--_connotation-color-primary-text: var(--vvd-data-grid-row-cta-primary-text, var(--vvd-color-canvas));--_connotation-color-primary-increment: var(--vvd-data-grid-row-cta-primary-increment, var(--vvd-color-cta-600));--_connotation-color-firm: var(--vvd-data-grid-row-cta-firm, var(--vvd-color-cta-600));--_connotation-color-faint: var(--vvd-data-grid-row-cta-faint, var(--vvd-color-cta-50));--_connotation-color-soft: var(--vvd-data-grid-row-cta-soft, var(--vvd-color-cta-100));--_connotation-color-pale: var(--vvd-data-grid-row-cta-pale, var(--vvd-color-cta-300));--_connotation-color-dim: var(--vvd-data-grid-row-cta-dim, var(--vvd-color-cta-200))}.base:not(.connotation-cta){--_connotation-color-primary: var(--vvd-data-grid-row-accent-primary, var(--vvd-color-canvas-text));--_connotation-color-primary-text: var(--vvd-data-grid-row-accent-primary-text, var(--vvd-color-canvas));--_connotation-color-primary-increment: var(--vvd-data-grid-row-accent-primary-increment, var(--vvd-color-neutral-800));--_connotation-color-firm: var(--vvd-data-grid-row-accent-firm, var(--vvd-color-canvas-text));--_connotation-color-faint: var(--vvd-data-grid-row-accent-faint, var(--vvd-color-neutral-50));--_connotation-color-soft: var(--vvd-data-grid-row-accent-soft, var(--vvd-color-neutral-100));--_connotation-color-pale: var(--vvd-data-grid-row-accent-pale, var(--vvd-color-neutral-300));--_connotation-color-dim: var(--vvd-data-grid-row-accent-dim, var(--vvd-color-neutral-200))}.base{--_appearance-color-text: var(--_connotation-color-firm);--_appearance-color-fill: transparent;--_appearance-color-outline: transparent}@media (hover: hover){.base:hover:where(:not(.disabled,:disabled,.readonly)){--_appearance-color-text: var(--_connotation-color-firm);--_appearance-color-fill: var(--_connotation-color-faint);--_appearance-color-outline: transparent}}.base.hover:where(:not(.disabled,:disabled,.readonly)){--_appearance-color-text: var(--_connotation-color-firm);--_appearance-color-fill: var(--_connotation-color-faint);--_appearance-color-outline: transparent}.base.selected:where(:not(.disabled,:disabled)){--_appearance-color-text: var(--_connotation-color-firm);--_appearance-color-fill: var(--_connotation-color-soft);--_appearance-color-outline: transparent}@media (hover: hover){.base.selected:hover:where(:not(.disabled,:disabled,.readonly)){--_appearance-color-text: var(--_connotation-color-firm);--_appearance-color-fill: var(--_connotation-color-dim);--_appearance-color-outline: transparent}}.base.selected.hover:where(:not(.disabled,:disabled,.readonly)){--_appearance-color-text: var(--_connotation-color-firm);--_appearance-color-fill: var(--_connotation-color-dim);--_appearance-color-outline: transparent}.base{display:grid;width:100%;box-sizing:border-box;color:var(--vvd-color-canvas-text)}:host([row-type=sticky-header]) .base{position:sticky;z-index:9;top:0;background:var(--data-grid-row-background, var(--vvd-color-canvas))}:host([row-type=hidden-header]) .base{display:none}:host(:is([selected]):not([row-type*=header])) .base{background-color:var(--_appearance-color-fill)}",q=':host{block-size:100%;min-inline-size:80px}:host(:focus-visible){outline:none}:host([data-fixed]){position:sticky;z-index:5;background:var(--data-grid-cell-background, var(--vvd-color-surface-2dp))}:host([data-fixed]):before{position:absolute;z-index:1;top:0;right:0;width:1px;block-size:100%;box-shadow:4px 0 4px #0000001a,2px 0 2px #0000000d,1px 0 1px #0000000d;content:"";pointer-events:none}.base.connotation-cta{--_connotation-color-primary: var(--vvd-data-grid-cell-cta-primary, var(--vvd-color-cta-500));--_connotation-color-primary-text: var(--vvd-data-grid-cell-cta-primary-text, var(--vvd-color-canvas));--_connotation-color-primary-increment: var(--vvd-data-grid-cell-cta-primary-increment, var(--vvd-color-cta-600));--_connotation-color-firm: var(--vvd-data-grid-cell-cta-firm, var(--vvd-color-cta-600));--_connotation-color-soft: var(--vvd-data-grid-cell-cta-soft, var(--vvd-color-cta-100));--_connotation-color-faint: var(--vvd-data-grid-cell-cta-faint, var(--vvd-color-cta-50));--_connotation-color-pale: var(--vvd-data-grid-cell-cta-pale, var(--vvd-color-cta-300));--_connotation-color-dim: var(--vvd-data-grid-cell-cta-dim, var(--vvd-color-cta-200))}.base:not(.connotation-cta){--_connotation-color-primary: var(--vvd-data-grid-cell-accent-primary, var(--vvd-color-canvas-text));--_connotation-color-primary-text: var(--vvd-data-grid-cell-accent-primary-text, var(--vvd-color-canvas));--_connotation-color-primary-increment: var(--vvd-data-grid-cell-accent-primary-increment, var(--vvd-color-neutral-800));--_connotation-color-firm: var(--vvd-data-grid-cell-accent-firm, var(--vvd-color-canvas-text));--_connotation-color-soft: var(--vvd-data-grid-cell-accent-soft, var(--vvd-color-neutral-100));--_connotation-color-faint: var(--vvd-data-grid-cell-accent-faint, var(--vvd-color-neutral-50));--_connotation-color-pale: var(--vvd-data-grid-cell-accent-pale, var(--vvd-color-neutral-300));--_connotation-color-dim: var(--vvd-data-grid-cell-accent-dim, var(--vvd-color-neutral-200))}.base{--_appearance-color-text: var(--_connotation-color-firm);--_appearance-color-fill: transparent;--_appearance-color-outline: transparent}@media (hover: hover){.base:hover:where(:not(.disabled,:disabled,.readonly)){--_appearance-color-text: var(--_connotation-color-firm);--_appearance-color-fill: var(--_connotation-color-faint);--_appearance-color-outline: transparent}}.base.hover:where(:not(.disabled,:disabled,.readonly)){--_appearance-color-text: var(--_connotation-color-firm);--_appearance-color-fill: var(--_connotation-color-faint);--_appearance-color-outline: transparent}.base.selected:where(:not(.disabled,:disabled)){--_appearance-color-text: var(--_connotation-color-firm);--_appearance-color-fill: var(--_connotation-color-soft);--_appearance-color-outline: transparent}@media (hover: hover){.base.selected:hover:where(:not(.disabled,:disabled,.readonly)){--_appearance-color-text: var(--_connotation-color-firm);--_appearance-color-fill: var(--_connotation-color-dim);--_appearance-color-outline: transparent}}.base.selected.hover:where(:not(.disabled,:disabled,.readonly)){--_appearance-color-text: var(--_connotation-color-firm);--_appearance-color-fill: var(--_connotation-color-dim);--_appearance-color-outline: transparent}.base{display:flex;box-sizing:border-box;align-items:center;border-bottom:1px solid var(--vvd-color-neutral-300);block-size:var(--data-grid-cell-block-size, var(--_data-grid-cell-default-block-size));color:var(--_appearance-color-text);font:var(--vvd-typography-base);min-block-size:calc(1px*(48 + 4*clamp(-1,var(--vvd-size-density, 0),2)));padding-block:13px 14px;padding-inline:12px}:host(:focus-visible) .base{--focus-stroke-gap-color: transparent;box-shadow:0 0 0 4px color-mix(in srgb,var(--focus-stroke-color, var(--vvd-color-cta-500)),transparent 85%),inset 0 0 0 3px var(--focus-stroke-gap-color, currentColor);outline:1px solid var(--focus-stroke-color, var(--vvd-color-cta-500));outline-offset:calc(-1px - var(--focus-inset, 0px))}:host([cell-type=columnheader]) .base{border-color:var(--vvd-color-canvas-text);font:var(--vvd-typography-base-bold);--_data-grid-cell-default-block-size: calc(1px*(48 + 4*clamp(-1, var(--vvd-size-density, 0), 2))) ;--_data-grid-cell-default-white-space: nowrap}:host(:not([cell-type=columnheader])) .base{--_data-grid-cell-default-block-size: 100%;--_data-grid-cell-default-white-space: normal}:host(:is([selected]):not([cell-type=columnheader])) .base{background-color:var(--_appearance-color-fill)}slot{display:block;overflow:hidden;text-overflow:ellipsis;white-space:var(--data-grid-cell-white-space, var(--_data-grid-cell-default-white-space))}:host(:not([cell-type=columnheader][aria-sort])) slot{inline-size:100%}.header-icon{margin-inline-start:16px}';var L=Object.defineProperty,v=(o,e,t,i)=>{for(var l=void 0,r=o.length-1,s;r>=0;r--)(s=o[r])&&(l=s(e,t,l)||l);return l&&L(e,t,l),l};const P=n.html`
|
|
2
2
|
<template>
|
|
3
3
|
${o=>o.rowData===null||o.columnDefinition===null||o.columnDefinition.columnDataKey===null?null:o.rowData[o.columnDefinition.columnDataKey]}
|
|
4
4
|
</template>
|
|
5
|
-
`,
|
|
5
|
+
`,M=n.html`
|
|
6
6
|
<template>
|
|
7
7
|
${o=>o.columnDefinition.title===void 0?o.columnDefinition.columnDataKey:o.columnDefinition.title}
|
|
8
8
|
</template>
|
|
9
|
-
`;class f extends L.Localized(T.HostSemantics(n.VividElement)){constructor(){super(...arguments),this.cellType=p.default,this.rowData=null,this.columnDefinition=null,this.isActiveCell=!1,this.customCellView=null,this.updateCellStyle=()=>{this.gridColumn&&!this.gridColumn.includes("undefined")?this.style.gridColumn=this.gridColumn:this.style.removeProperty("grid-column")},this._selectable=!1,this.selected=!1,this.ariaSelected=null,this.ariaSort=null}cellTypeChanged(){this.$fastController.isConnected&&this.updateCellView()}gridColumnChanged(){this.$fastController.isConnected&&this.updateCellStyle()}columnDefinitionChanged(e,t){this.$fastController.isConnected&&this.updateCellView()}updateFixedStyle(){this.fixedPosition!==void 0?(this.setAttribute("data-fixed",""),this.style.left=this.fixedPosition):(this.removeAttribute("data-fixed"),this.style.removeProperty("left"))}setFixedPosition(e){this.fixedPosition=e,this.updateFixedStyle()}connectedCallback(){super.connectedCallback(),this.addEventListener(S,this.handleFocusin),this.addEventListener(C,this.handleFocusout),this.addEventListener(w,this.handleKeydown),this.style.gridColumn=`${this.columnDefinition?.gridColumn===void 0?0:this.columnDefinition.gridColumn}`,this.updateCellView(),this.updateCellStyle(),this.updateFixedStyle()}disconnectedCallback(){super.disconnectedCallback(),this.removeEventListener(S,this.handleFocusin),this.removeEventListener(C,this.handleFocusout),this.removeEventListener(w,this.handleKeydown),this.disconnectCellView()}handleFocusin(e){if(this.shadowRoot.querySelector(".base").classList.add("active"),!this.isActiveCell){switch(this.isActiveCell=!0,this.cellType){case p.columnHeader:if(this.columnDefinition!==null&&this.columnDefinition.headerCellInternalFocusQueue!==!0&&typeof this.columnDefinition.headerCellFocusTargetCallback=="function"){const t=this.columnDefinition.headerCellFocusTargetCallback(this);/* v8 ignore else -- @preserve */t!==null&&t.focus()}break;default:if(this.columnDefinition!==null&&this.columnDefinition.cellInternalFocusQueue!==!0&&typeof this.columnDefinition.cellFocusTargetCallback=="function"){const t=this.columnDefinition.cellFocusTargetCallback(this);/* v8 ignore else -- @preserve */t!==null&&t.focus()}break}this.$emit("cell-focused",this)}}handleFocusout(e){this.shadowRoot.querySelector(".base").classList.remove("active");/* v8 ignore else -- @preserve */this!==document.activeElement&&!this.contains(document.activeElement)&&(this.isActiveCell=!1)}handleKeydown(e){if(!(e.defaultPrevented||this.columnDefinition===null||this.cellType===p.default&&this.columnDefinition.cellInternalFocusQueue!==!0||this.cellType===p.columnHeader&&this.columnDefinition.headerCellInternalFocusQueue!==!0))switch(e.key){case u.keyEnter:case u.keyFunction2:if(this.contains(document.activeElement)&&document.activeElement!==this)return;switch(this.cellType){case p.columnHeader:{if(this.columnDefinition.headerCellFocusTargetCallback!==void 0){const t=this.columnDefinition.headerCellFocusTargetCallback(this);/* v8 ignore else -- @preserve */t!==null&&t.focus(),e.preventDefault()}break}default:{if(this.columnDefinition.cellFocusTargetCallback!==void 0){const t=this.columnDefinition.cellFocusTargetCallback(this);/* v8 ignore else -- @preserve */t!==null&&t.focus(),e.preventDefault()}break}}break;case u.keyEscape:{/* v8 ignore else -- @preserve */this.contains(document.activeElement)&&document.activeElement!==this&&(this.focus(),e.preventDefault());break}}}updateCellView(){if(this.disconnectCellView(),this.columnDefinition!==null){switch(this.cellType){case p.columnHeader:this.columnDefinition.headerCellTemplate!==void 0?this.customCellView=this.columnDefinition.headerCellTemplate.render(this,this):this.customCellView=B.render(this,this);break;case p.rowHeader:case p.default:this.columnDefinition.cellTemplate!==void 0?this.customCellView=this.columnDefinition.cellTemplate.render(this,this):this.customCellView=K.render(this,this);break}this.columnDefinition?.sortable?this.columnDefinition.sortDirection?this.sortDirection=this.columnDefinition.sortDirection:this.sortDirection=y.none:this.sortDirection=void 0}}disconnectCellView(){this.customCellView!==null&&(this.customCellView.dispose(),this.customCellView=null)}ariaSelectedChanged(e,t){super.ariaSelectedChanged(e,t),this._selectable=t!==null,this.selected=t==="true"}ariaSortChanged(e,t){if(super.ariaSortChanged(e,t),t===null){this.sortDirection=void 0;return}this.sortDirection=t}#e(){return this.columnDefinition&&this.columnDefinition.columnDataKey?this.columnDefinition.columnDataKey:this.textContent.trim()}_handleInteraction(){const e=this.cellType==="columnheader";return e&&this.sortDirection!==void 0&&this.$emit("sort",{columnDataKey:this.#e(),sortDirection:this.sortDirection}),(e?this.columnDefinition?.headerCellInternalFocusQueue:this.columnDefinition?.cellInternalFocusQueue)||this.$emit("cell-click",{cell:this,row:this.parentElement,isHeaderCell:e,columnDataKey:this.#e()}),!0}}b([n.attr({attribute:"cell-type"})],f.prototype,"cellType");b([n.attr({attribute:"grid-column"})],f.prototype,"gridColumn");b([n.observable],f.prototype,"rowData");b([n.observable],f.prototype,"columnDefinition");b([n.observable],f.prototype,"_selectable");b([n.attr({mode:"boolean"})],f.prototype,"selected");b([n.attr({attribute:"sort-direction"})],f.prototype,"sortDirection");var Q=Object.defineProperty,h=(o,e,t,i)=>{for(var l=void 0,r=o.length-1,a;r>=0;r--)(a=o[r])&&(l=a(e,t,l)||l);return l&&Q(e,t,l),l};class c extends T.HostSemantics(n.VividElement){constructor(){super(...arguments),this.rowType=v.default,this.rowData=null,this.columnDefinitions=null,this.behaviorOrchestrator=null,this.focusColumnIndex=0,this.updateRowStyle=()=>{this.style.gridTemplateColumns=this.gridTemplateColumns},this.ariaSelected=null,this._selectable=!1,this.selected=!1}gridTemplateColumnsChanged(){this.$fastController.isConnected&&this.updateRowStyle()}rowTypeChanged(){this.$fastController.isConnected&&this.updateItemTemplate()}cellItemTemplateChanged(){this.updateItemTemplate()}headerCellItemTemplateChanged(){this.updateItemTemplate()}connectedCallback(){super.connectedCallback();/* v8 ignore else -- @preserve */this.behaviorOrchestrator===null&&(this.updateItemTemplate(),this.behaviorOrchestrator=n.ViewBehaviorOrchestrator.create(this),this.$fastController.addBehavior(this.behaviorOrchestrator),this.behaviorOrchestrator.addBehaviorFactory(new z.RepeatDirective(x.normalizeBinding(e=>e.columnDefinitions),x.normalizeBinding(e=>e.activeCellItemTemplate),{positioning:!0}),this.appendChild(document.createComment("")))),this.addEventListener("cell-focused",this.handleCellFocus),this.addEventListener(C,this.handleFocusout),this.addEventListener(w,this.handleKeydown),this.updateRowStyle()}disconnectedCallback(){super.disconnectedCallback(),this.removeEventListener("cell-focused",this.handleCellFocus),this.removeEventListener(C,this.handleFocusout),this.removeEventListener(w,this.handleKeydown)}handleFocusout(e){/* v8 ignore else -- @preserve */this.contains(document.activeElement)||(this.focusColumnIndex=0)}handleCellFocus(e){this.focusColumnIndex=this.cellElements.indexOf(e.target),this.$emit("row-focused",this)}handleKeydown(e){if(e.defaultPrevented)return;let t=0;switch(e.key){case u.keyArrowLeft:t=Math.max(0,this.focusColumnIndex-1),this.cellElements[t].focus(),e.preventDefault();break;case u.keyArrowRight:t=Math.min(this.cellElements.length-1,this.focusColumnIndex+1),this.cellElements[t].focus(),e.preventDefault();break;case u.keyHome:e.ctrlKey||(this.cellElements[0].focus(),e.preventDefault());break;case u.keyEnd:e.ctrlKey||(this.cellElements[this.cellElements.length-1].focus(),e.preventDefault());break}}updateItemTemplate(){this.activeCellItemTemplate=this.rowType===v.default&&this.cellItemTemplate!==void 0?this.cellItemTemplate:this.rowType===v.default&&this.cellItemTemplate===void 0?this.defaultCellItemTemplate:this.headerCellItemTemplate!==void 0?this.headerCellItemTemplate:this.defaultHeaderCellItemTemplate}ariaSelectedChanged(e,t){super.ariaSelectedChanged(e,t),this._selectable=t!==null,this.selected=t==="true"}}h([n.attr({attribute:"grid-template-columns"})],c.prototype,"gridTemplateColumns");h([n.attr({attribute:"row-type"})],c.prototype,"rowType");h([n.observable],c.prototype,"rowData");h([n.observable],c.prototype,"columnDefinitions");h([n.observable],c.prototype,"cellItemTemplate");h([n.observable],c.prototype,"headerCellItemTemplate");h([n.observable],c.prototype,"rowIndex");h([n.observable],c.prototype,"activeCellItemTemplate");h([n.observable],c.prototype,"defaultCellItemTemplate");h([n.observable],c.prototype,"defaultHeaderCellItemTemplate");h([n.observable],c.prototype,"cellElements");h([n.observable],c.prototype,"_selectable");h([n.attr({mode:"boolean"})],c.prototype,"selected");var j=Object.defineProperty,d=(o,e,t,i)=>{for(var l=void 0,r=o.length-1,a;r>=0;r--)(a=o[r])&&(l=a(e,t,l)||l);return l&&j(e,t,l),l};const m={none:"none",singleRow:"single-row",multiRow:"multi-row",singleCell:"single-cell",multiCell:"multi-cell"},s=class I extends n.VividElement{constructor(){super(),this.noTabbing=!1,this.generateHeader=g.default,this.rowsData=[],this.columnDefinitions=null,this.focusRowIndex=0,this.focusColumnIndex=0,this.fixedColumnsPositions=[],this.behaviorOrchestrator=null,this.generatedHeader=null,this.isUpdatingFocus=!1,this.pendingFocusUpdate=!1,this.rowindexUpdateQueued=!1,this.columnDefinitionsStale=!0,this.generatedGridTemplateColumns="",this.focusOnCell=(e,t,i)=>{if(this.rowElements.length===0){this.focusRowIndex=0,this.focusColumnIndex=0;return}const l=Math.max(0,Math.min(this.rowElements.length-1,e)),a=this.rowElements[l].querySelectorAll('[role="cell"], [role="gridcell"], [role="columnheader"], [role="rowheader"], [data-vvd-component="data-grid-cell"]'),_=Math.max(0,Math.min(a.length-1,t)),$=a[_];i&&this.scrollHeight!==this.clientHeight&&(l<this.focusRowIndex&&this.scrollTop>0||l>this.focusRowIndex&&this.scrollTop<this.scrollHeight-this.clientHeight)&&$.scrollIntoView({block:"center",inline:"center"}),$.focus()},this.onChildListChange=(e,t)=>{/* v8 ignore else -- @preserve */e&&e.length&&(e.forEach(i=>{i.addedNodes.forEach(l=>{l.nodeType===1&&(l.getAttribute("role")==="row"||l.getAttribute("row-type")==="default")&&(l.columnDefinitions=this.columnDefinitions)})}),this.queueRowIndexUpdate())},this.queueRowIndexUpdate=()=>{this.rowindexUpdateQueued||(this.rowindexUpdateQueued=!0,n.Updates.enqueue(this.updateRowIndexes))},this.updateRowIndexes=()=>{let e=this.gridTemplateColumns;if(e===void 0){if(this.generatedGridTemplateColumns===""&&this.rowElements.length>0){const t=this.rowElements[0];this.generatedGridTemplateColumns=new Array(t.cellElements.length).fill("1fr").join(" ")}e=this.generatedGridTemplateColumns}this.rowElements.forEach((t,i)=>{const l=t;l.rowIndex=i,l.gridTemplateColumns=e,this.columnDefinitionsStale&&(l.columnDefinitions=this.columnDefinitions)}),this.rowindexUpdateQueued=!1,this.columnDefinitionsStale=!1},this.#l=e=>{(e.key==="Enter"||e.key===" ")&&this.#t(e)},this.#t=({target:e,ctrlKey:t,shiftKey:i,metaKey:l})=>{if(!(e.getAttribute("role")!=="gridcell"||e.getAttribute("cell-type")!=="default")){if(this.selectionMode===m.singleCell||this.selectionMode===m.multiCell){this.#i({target:e,ctrlKey:t,shiftKey:i,metaKey:l});return}(this.selectionMode===m.singleRow||this.selectionMode===m.multiRow)&&this.#n({target:e,ctrlKey:t,shiftKey:i,metaKey:l})}},this.#i=({target:e,ctrlKey:t,shiftKey:i,metaKey:l})=>{const r=e;if(this.selectionMode===m.multiCell&&(t||i||l))r.selected=!this.#a.includes(r);else{const a=r.selected;this._resetSelection(!0),r.selected=!a}},this.#n=({target:e,ctrlKey:t,shiftKey:i,metaKey:l})=>{const r=e.parentNode;if(this.selectionMode===m.multiRow&&(t||i||l))r.selected=!this.#r.includes(r);else{const a=r.selected;this._resetSelection(!0),r.selected=!a}},this.#o={handleChange(e,t){/* v8 ignore else -- @preserve */if(t==="columnDefinitions"){/* v8 ignore else -- @preserve */e.$fastController.isConnected&&e.toggleGeneratedHeader()}}},this._resetSelection=(e=!1)=>{const t=Array.from(this.querySelectorAll('[role="gridcell"], [cell-type="default"]')),i=Array.from(this.querySelectorAll('[role="row"], [row-type="default"]'));if(this.selectionMode===m.singleCell||this.selectionMode===m.multiCell){for(const l of t)l._selectable=!0,l.selected=e?!1:l.selected||!1;for(const l of i)l._selectable=!1,l.selected=!1}if(this.selectionMode===m.none)for(const l of[...t,...i])l._selectable=!1,l.selected=!1;if(this.selectionMode===m.singleRow||this.selectionMode===m.multiRow){for(const l of t)l._selectable=!1,l.selected=!1;for(const l of i)l._selectable=!0,l.selected=e?!1:l.selected||!1}},this.addEventListener("click",this.#t),this.addEventListener("keydown",this.#l)}static generateTemplateColumns(e){let t="";return e.forEach(i=>{t=`${t}${t===""?"":" "}1fr`}),t}noTabbingChanged(){this.$fastController.isConnected&&this.#e()}#e(){this.setAttribute("tabIndex",this.noTabbing||this.contains(document.activeElement)?"-1":"0")}generateHeaderChanged(){this.$fastController.isConnected&&this.toggleGeneratedHeader()}gridTemplateColumnsChanged(){/* v8 ignore if -- @preserve */this.$fastController.isConnected&&(this.updateRowIndexes(),this.fixedColumns&&this.fixedColumns>0&&this.applyFixedColumns())}rowsDataChanged(){this.columnDefinitions===null&&this.rowsData.length>0&&(this.columnDefinitions=I.generateColumns(this.rowsData[0])),this.$fastController.isConnected&&this.toggleGeneratedHeader()}columnDefinitionsChanged(){if(this.columnDefinitions===null){this.generatedGridTemplateColumns="";return}this.generatedGridTemplateColumns=I.generateTemplateColumns(this.columnDefinitions);/* v8 ignore if -- @preserve */this.$fastController.isConnected&&(this.columnDefinitionsStale=!0,this.queueRowIndexUpdate())}headerCellItemTemplateChanged(){/* v8 ignore if -- @preserve */this.$fastController.isConnected&&this.generatedHeader!==null&&(this.generatedHeader.headerCellItemTemplate=this.headerCellItemTemplate)}focusRowIndexChanged(){this.$fastController.isConnected&&this.queueFocusUpdate()}focusColumnIndexChanged(){this.$fastController.isConnected&&this.queueFocusUpdate()}fixedColumnsChanged(){/* v8 ignore if -- @preserve */this.$fastController.isConnected&&(this.applyFixedColumns(),this.setupResizeObserver())}setupResizeObserver(){this.resizeObserver&&(this.resizeObserver.disconnect(),this.resizeObserver=void 0),typeof ResizeObserver<"u"&&this.fixedColumns&&this.fixedColumns>0&&(this.resizeObserver=new ResizeObserver(()=>{this.applyFixedColumns()}),this.resizeObserver.observe(this))}connectedCallback(){super.connectedCallback();/* v8 ignore else -- @preserve */this.rowItemTemplate===void 0&&(this.rowItemTemplate=this.defaultRowItemTemplate);/* v8 ignore else -- @preserve */this.behaviorOrchestrator===null&&(this.behaviorOrchestrator=n.ViewBehaviorOrchestrator.create(this),this.$fastController.addBehavior(this.behaviorOrchestrator),this.behaviorOrchestrator.addBehaviorFactory(new z.RepeatDirective(x.normalizeBinding(e=>e.rowsData),x.normalizeBinding(e=>e.rowItemTemplate),{positioning:!0}),this.appendChild(document.createComment("")))),this.toggleGeneratedHeader(),this.addEventListener("row-focused",this.handleRowFocus),this.addEventListener(F,this.handleFocus),this.addEventListener(w,this.handleKeydown),this.addEventListener(C,this.handleFocusOut),this.observer=new MutationObserver(this.onChildListChange),this.observer.observe(this,{childList:!0}),this.setupResizeObserver(),n.Updates.enqueue(this.queueRowIndexUpdate),this.#e(),n.Observable.getNotifier(this).subscribe(this.#o,"columnDefinitions")}disconnectedCallback(){super.disconnectedCallback(),this.removeEventListener("row-focused",this.handleRowFocus),this.removeEventListener(F,this.handleFocus),this.removeEventListener(w,this.handleKeydown),this.removeEventListener(C,this.handleFocusOut),this.observer.disconnect(),this.resizeObserver&&(this.resizeObserver.disconnect(),this.resizeObserver=void 0),this.generatedHeader=null,n.Observable.getNotifier(this).unsubscribe(this.#o,"columnDefinitions")}handleRowFocus(e){this.isUpdatingFocus=!0;const t=e.target;this.focusRowIndex=this.rowElements.indexOf(t),this.focusColumnIndex=t.focusColumnIndex,this.setAttribute("tabIndex","-1"),this.isUpdatingFocus=!1}handleFocus(e){this.focusOnCell(this.focusRowIndex,this.focusColumnIndex,!0)}handleFocusOut(e){(e.relatedTarget===null||!this.contains(e.relatedTarget))&&this.setAttribute("tabIndex",this.noTabbing?"-1":"0")}handleKeydown(e){if(e.defaultPrevented)return;let t;const i=this.rowElements.length-1,l=this.offsetHeight+this.scrollTop,r=this.rowElements[i];switch(e.key){case u.keyArrowUp:e.preventDefault(),this.focusOnCell(this.focusRowIndex-1,this.focusColumnIndex,!0);break;case u.keyArrowDown:e.preventDefault(),this.focusOnCell(this.focusRowIndex+1,this.focusColumnIndex,!0);break;case u.keyPageUp:if(e.preventDefault(),this.rowElements.length===0){this.focusOnCell(0,0,!1);break}if(this.focusRowIndex===0){this.focusOnCell(0,this.focusColumnIndex,!1);return}for(t=this.focusRowIndex-1,t;t>=0;t--){const a=this.rowElements[t];if(a.offsetTop<this.scrollTop){this.scrollTop=a.offsetTop+a.clientHeight-this.clientHeight;break}}this.focusOnCell(t,this.focusColumnIndex,!1);break;case u.keyPageDown:if(e.preventDefault(),this.rowElements.length===0){this.focusOnCell(0,0,!1);break}if(this.focusRowIndex>=i||r.offsetTop+r.offsetHeight<=l){this.focusOnCell(i,this.focusColumnIndex,!1);return}for(t=this.focusRowIndex+1,t;t<=i;t++){const a=this.rowElements[t];if(a.offsetTop+a.offsetHeight>l){let _=0;this.generateHeader===g.sticky&&this.generatedHeader!==null&&(_=this.generatedHeader.clientHeight),this.scrollTop=a.offsetTop-_;break}}this.focusOnCell(t,this.focusColumnIndex,!1);break;case u.keyHome:{/* v8 ignore else -- @preserve */e.ctrlKey&&(e.preventDefault(),this.focusOnCell(0,0,!0));break}case u.keyEnd:{/* v8 ignore else -- @preserve */e.ctrlKey&&this.columnDefinitions!==null&&(e.preventDefault(),this.focusOnCell(this.rowElements.length-1,this.columnDefinitions.length-1,!0));break}}}queueFocusUpdate(){this.isUpdatingFocus&&this.contains(document.activeElement)||this.pendingFocusUpdate===!1&&(this.pendingFocusUpdate=!0,n.Updates.enqueue(()=>this.updateFocus()))}updateFocus(){this.pendingFocusUpdate=!1,this.focusOnCell(this.focusRowIndex,this.focusColumnIndex,!0)}toggleGeneratedHeader(){if(this.generatedHeader!==null&&(this.removeChild(this.generatedHeader),this.generatedHeader=null),this.generateHeader!==g.none&&this.columnDefinitions!==null){const e=document.createElement(this.rowElementTag);this.generatedHeader=e,this.generatedHeader.columnDefinitions=this.columnDefinitions,this.generatedHeader.gridTemplateColumns=this.gridTemplateColumns,this.generatedHeader.rowType=this.generateHeader===g.sticky?v.stickyHeader:v.header;/* v8 ignore else -- @preserve */this.firstChild!==null&&this.insertBefore(e,this.firstChild);return}}slottedRowElementsChanged(e,t){this._resetSelection()}get#r(){return this.rowElements.filter(e=>e.selected)}get#a(){return this.rowElements.reduce((e,t)=>{const l=Array.from(t.children).filter(r=>r.selected);return e.concat(l)},[])}selectionModeChanged(e){if(e===void 0){n.Updates.enqueue(this._resetSelection);return}this._resetSelection(!0)}#l;#t;#i;#n;#o;static generateColumns(e){return Object.keys(e).map((t,i)=>({columnDataKey:t,gridColumn:`${i}`}))}applyFixedColumns(){if(!this.fixedColumns||this.fixedColumns<=0){this.clearFixedColumns();return}this.calculateFixedColumnPositions(),this.applyFixedColumnStyling()}applyFixedColumnStyling(){this.rowElements.forEach(e=>{const t=e.querySelectorAll('[role="cell"], [role="gridcell"], [role="columnheader"], [cell-type="default"], [cell-type="columnheader"]');this.fixedColumnsPositions.forEach((i,l)=>{/* v8 ignore else -- @preserve */if(l<t.length){const r=t[l];/* v8 ignore else -- @preserve */typeof r.setFixedPosition=="function"&&r.setFixedPosition(`${i}px`)}})})}calculateFixedColumnPositions(){if(this.fixedColumnsPositions=[],this.rowElements.length===0)return;const e=this.rowElements[0].querySelectorAll('[role="cell"], [role="gridcell"], [role="columnheader"], [cell-type="default"], [cell-type="columnheader"]');let t=0;for(let i=0;i<Math.min(this.fixedColumns,e.length);i++)this.fixedColumnsPositions.push(t),t+=e[i].offsetWidth}clearFixedColumns(){if(this.rowElements.length===0){this.fixedColumnsPositions=[];return}this.rowElements.forEach(e=>{const t=e.querySelectorAll('[role="cell"], [role="gridcell"], [role="columnheader"], [cell-type="default"], [cell-type="columnheader"]');this.fixedColumnsPositions.forEach((i,l)=>{/* v8 ignore else -- @preserve */if(l<t.length){const r=t[l];/* v8 ignore else -- @preserve */typeof r.setFixedPosition=="function"&&r.setFixedPosition(void 0)}})}),this.fixedColumnsPositions=[]}};d([n.attr({attribute:"no-tabbing",mode:"boolean"})],s.prototype,"noTabbing");d([n.attr({attribute:"generate-header"})],s.prototype,"generateHeader");d([n.attr({attribute:"grid-template-columns"})],s.prototype,"gridTemplateColumns");d([n.observable],s.prototype,"rowsData");d([n.observable],s.prototype,"columnDefinitions");d([n.observable],s.prototype,"rowItemTemplate");d([n.observable],s.prototype,"cellItemTemplate");d([n.observable],s.prototype,"headerCellItemTemplate");d([n.observable],s.prototype,"focusRowIndex");d([n.observable],s.prototype,"focusColumnIndex");d([n.attr({attribute:"fixed-columns",converter:n.nullableNumberConverter})],s.prototype,"fixedColumns");d([n.observable],s.prototype,"defaultRowItemTemplate");d([n.observable],s.prototype,"rowElementTag");d([n.observable],s.prototype,"rowElements");d([n.observable],s.prototype,"slottedRowElements");d([n.attr({attribute:"selection-mode"})],s.prototype,"selectionMode");let N=s;function W(o){const e=o.tagFor(c);return n.html`
|
|
9
|
+
`;class f extends O.Localized(D.HostSemantics(n.VividElement)){constructor(){super(...arguments),this.cellType=a.DataGridCellTypes.default,this.rowData=null,this.columnDefinition=null,this.isActiveCell=!1,this.customCellView=null,this.updateCellStyle=()=>{this.gridColumn&&!this.gridColumn.includes("undefined")?this.style.gridColumn=this.gridColumn:this.style.removeProperty("grid-column")},this._selectable=!1,this.selected=!1,this.ariaSelected=null,this.ariaSort=null}cellTypeChanged(){this.$fastController.isConnected&&this.updateCellView()}gridColumnChanged(){this.$fastController.isConnected&&this.updateCellStyle()}columnDefinitionChanged(e,t){this.$fastController.isConnected&&this.updateCellView()}updateFixedStyle(){this.fixedPosition!==void 0?(this.setAttribute("data-fixed",""),this.style.left=this.fixedPosition):(this.removeAttribute("data-fixed"),this.style.removeProperty("left"))}setFixedPosition(e){this.fixedPosition=e,this.updateFixedStyle()}connectedCallback(){super.connectedCallback(),this.addEventListener(E,this.handleFocusin),this.addEventListener(b,this.handleFocusout),this.addEventListener(g,this.handleKeydown),this.style.gridColumn=`${this.columnDefinition?.gridColumn===void 0?0:this.columnDefinition.gridColumn}`,this.updateCellView(),this.updateCellStyle(),this.updateFixedStyle()}disconnectedCallback(){super.disconnectedCallback(),this.removeEventListener(E,this.handleFocusin),this.removeEventListener(b,this.handleFocusout),this.removeEventListener(g,this.handleKeydown),this.disconnectCellView()}handleFocusin(e){if(this.shadowRoot.querySelector(".base").classList.add("active"),!this.isActiveCell){switch(this.isActiveCell=!0,this.cellType){case a.DataGridCellTypes.columnHeader:if(this.columnDefinition!==null&&this.columnDefinition.headerCellInternalFocusQueue!==!0&&typeof this.columnDefinition.headerCellFocusTargetCallback=="function"){const t=this.columnDefinition.headerCellFocusTargetCallback(this);/* v8 ignore else -- @preserve */t!==null&&t.focus()}break;default:if(this.columnDefinition!==null&&this.columnDefinition.cellInternalFocusQueue!==!0&&typeof this.columnDefinition.cellFocusTargetCallback=="function"){const t=this.columnDefinition.cellFocusTargetCallback(this);/* v8 ignore else -- @preserve */t!==null&&t.focus()}break}this.$emit("cell-focused",this)}}handleFocusout(e){this.shadowRoot.querySelector(".base").classList.remove("active");/* v8 ignore else -- @preserve */this!==document.activeElement&&!this.contains(document.activeElement)&&(this.isActiveCell=!1)}handleKeydown(e){if(!(e.defaultPrevented||this.columnDefinition===null||this.cellType===a.DataGridCellTypes.default&&this.columnDefinition.cellInternalFocusQueue!==!0||this.cellType===a.DataGridCellTypes.columnHeader&&this.columnDefinition.headerCellInternalFocusQueue!==!0))switch(e.key){case h.keyEnter:case h.keyFunction2:if(this.contains(document.activeElement)&&document.activeElement!==this)return;switch(this.cellType){case a.DataGridCellTypes.columnHeader:{if(this.columnDefinition.headerCellFocusTargetCallback!==void 0){const t=this.columnDefinition.headerCellFocusTargetCallback(this);/* v8 ignore else -- @preserve */t!==null&&t.focus(),e.preventDefault()}break}default:{if(this.columnDefinition.cellFocusTargetCallback!==void 0){const t=this.columnDefinition.cellFocusTargetCallback(this);/* v8 ignore else -- @preserve */t!==null&&t.focus(),e.preventDefault()}break}}break;case h.keyEscape:{/* v8 ignore else -- @preserve */this.contains(document.activeElement)&&document.activeElement!==this&&(this.focus(),e.preventDefault());break}}}updateCellView(){if(this.disconnectCellView(),this.columnDefinition!==null){switch(this.cellType){case a.DataGridCellTypes.columnHeader:this.columnDefinition.headerCellTemplate!==void 0?this.customCellView=this.columnDefinition.headerCellTemplate.render(this,this):this.customCellView=M.render(this,this);break;case a.DataGridCellTypes.rowHeader:case a.DataGridCellTypes.default:this.columnDefinition.cellTemplate!==void 0?this.customCellView=this.columnDefinition.cellTemplate.render(this,this):this.customCellView=P.render(this,this);break}this.columnDefinition?.sortable?this.columnDefinition.sortDirection?this.sortDirection=this.columnDefinition.sortDirection:this.sortDirection=a.DataGridCellSortStates.none:this.sortDirection=void 0}}disconnectCellView(){this.customCellView!==null&&(this.customCellView.dispose(),this.customCellView=null)}ariaSelectedChanged(e,t){super.ariaSelectedChanged(e,t),this._selectable=t!==null,this.selected=t==="true"}ariaSortChanged(e,t){if(super.ariaSortChanged(e,t),t===null){this.sortDirection=void 0;return}this.sortDirection=t}#e(){return this.columnDefinition&&this.columnDefinition.columnDataKey?this.columnDefinition.columnDataKey:this.textContent.trim()}_handleInteraction(){const e=this.cellType==="columnheader";return e&&this.sortDirection!==void 0&&this.$emit("sort",{columnDataKey:this.#e(),sortDirection:this.sortDirection}),(e?this.columnDefinition?.headerCellInternalFocusQueue:this.columnDefinition?.cellInternalFocusQueue)||this.$emit("cell-click",{cell:this,row:this.parentElement,isHeaderCell:e,columnDataKey:this.#e()}),!0}}v([n.attr({attribute:"cell-type"})],f.prototype,"cellType");v([n.attr({attribute:"grid-column"})],f.prototype,"gridColumn");v([n.observable],f.prototype,"rowData");v([n.observable],f.prototype,"columnDefinition");v([n.observable],f.prototype,"_selectable");v([n.attr({mode:"boolean"})],f.prototype,"selected");v([n.attr({attribute:"sort-direction"})],f.prototype,"sortDirection");var U=Object.defineProperty,m=(o,e,t,i)=>{for(var l=void 0,r=o.length-1,s;r>=0;r--)(s=o[r])&&(l=s(e,t,l)||l);return l&&U(e,t,l),l};class d extends D.HostSemantics(n.VividElement){constructor(){super(...arguments),this.rowType=a.DataGridRowTypes.default,this.rowData=null,this.columnDefinitions=null,this.behaviorOrchestrator=null,this.focusColumnIndex=0,this.updateRowStyle=()=>{this.style.gridTemplateColumns=this.gridTemplateColumns},this.ariaSelected=null,this._selectable=!1,this.selected=!1}gridTemplateColumnsChanged(){this.$fastController.isConnected&&this.updateRowStyle()}rowTypeChanged(){this.$fastController.isConnected&&this.updateItemTemplate()}cellItemTemplateChanged(){this.updateItemTemplate()}headerCellItemTemplateChanged(){this.updateItemTemplate()}connectedCallback(){super.connectedCallback();/* v8 ignore else -- @preserve */this.behaviorOrchestrator===null&&(this.updateItemTemplate(),this.behaviorOrchestrator=n.ViewBehaviorOrchestrator.create(this),this.$fastController.addBehavior(this.behaviorOrchestrator),this.behaviorOrchestrator.addBehaviorFactory(new F.RepeatDirective(y.normalizeBinding(e=>e.columnDefinitions),y.normalizeBinding(e=>e.activeCellItemTemplate),{positioning:!0}),this.appendChild(document.createComment("")))),this.addEventListener("cell-focused",this.handleCellFocus),this.addEventListener(b,this.handleFocusout),this.addEventListener(g,this.handleKeydown),this.updateRowStyle()}disconnectedCallback(){super.disconnectedCallback(),this.removeEventListener("cell-focused",this.handleCellFocus),this.removeEventListener(b,this.handleFocusout),this.removeEventListener(g,this.handleKeydown)}handleFocusout(e){/* v8 ignore else -- @preserve */this.contains(document.activeElement)||(this.focusColumnIndex=0)}handleCellFocus(e){this.focusColumnIndex=this.cellElements.indexOf(e.target),this.$emit("row-focused",this)}handleKeydown(e){if(e.defaultPrevented)return;let t=0;switch(e.key){case h.keyArrowLeft:t=Math.max(0,this.focusColumnIndex-1),this.cellElements[t].focus(),e.preventDefault();break;case h.keyArrowRight:t=Math.min(this.cellElements.length-1,this.focusColumnIndex+1),this.cellElements[t].focus(),e.preventDefault();break;case h.keyHome:e.ctrlKey||(this.cellElements[0].focus(),e.preventDefault());break;case h.keyEnd:e.ctrlKey||(this.cellElements[this.cellElements.length-1].focus(),e.preventDefault());break}}updateItemTemplate(){this.activeCellItemTemplate=this.rowType===a.DataGridRowTypes.default&&this.cellItemTemplate!==void 0?this.cellItemTemplate:this.rowType===a.DataGridRowTypes.default&&this.cellItemTemplate===void 0?this.defaultCellItemTemplate:this.headerCellItemTemplate!==void 0?this.headerCellItemTemplate:this.defaultHeaderCellItemTemplate}ariaSelectedChanged(e,t){super.ariaSelectedChanged(e,t),this._selectable=t!==null,this.selected=t==="true"}}m([n.attr({attribute:"grid-template-columns"})],d.prototype,"gridTemplateColumns");m([n.attr({attribute:"row-type"})],d.prototype,"rowType");m([n.observable],d.prototype,"rowData");m([n.observable],d.prototype,"columnDefinitions");m([n.observable],d.prototype,"cellItemTemplate");m([n.observable],d.prototype,"headerCellItemTemplate");m([n.observable],d.prototype,"rowIndex");m([n.observable],d.prototype,"activeCellItemTemplate");m([n.observable],d.prototype,"defaultCellItemTemplate");m([n.observable],d.prototype,"defaultHeaderCellItemTemplate");m([n.observable],d.prototype,"cellElements");m([n.observable],d.prototype,"_selectable");m([n.attr({mode:"boolean"})],d.prototype,"selected");var V=Object.defineProperty,u=(o,e,t,i)=>{for(var l=void 0,r=o.length-1,s;r>=0;r--)(s=o[r])&&(l=s(e,t,l)||l);return l&&V(e,t,l),l};const p={none:"none",singleRow:"single-row",multiRow:"multi-row",singleCell:"single-cell",multiCell:"multi-cell"},c=class _ extends n.VividElement{constructor(){super(),this.noTabbing=!1,this.generateHeader=a.GenerateHeaderOptions.default,this.rowsData=[],this.columnDefinitions=null,this.focusRowIndex=0,this.focusColumnIndex=0,this.fixedColumnsPositions=[],this.behaviorOrchestrator=null,this.generatedHeader=null,this.isUpdatingFocus=!1,this.pendingFocusUpdate=!1,this.rowindexUpdateQueued=!1,this.columnDefinitionsStale=!0,this.generatedGridTemplateColumns="",this.focusOnCell=(e,t,i)=>{if(this.rowElements.length===0){this.focusRowIndex=0,this.focusColumnIndex=0;return}const l=Math.max(0,Math.min(this.rowElements.length-1,e)),s=this.rowElements[l].querySelectorAll('[role="cell"], [role="gridcell"], [role="columnheader"], [role="rowheader"], [data-vvd-component="data-grid-cell"]'),C=Math.max(0,Math.min(s.length-1,t)),k=s[C];i&&this.scrollHeight!==this.clientHeight&&(l<this.focusRowIndex&&this.scrollTop>0||l>this.focusRowIndex&&this.scrollTop<this.scrollHeight-this.clientHeight)&&k.scrollIntoView({block:"center",inline:"center"}),k.focus()},this.onChildListChange=(e,t)=>{/* v8 ignore else -- @preserve */e&&e.length&&(e.forEach(i=>{i.addedNodes.forEach(l=>{l.nodeType===1&&(l.getAttribute("role")==="row"||l.getAttribute("row-type")==="default")&&(l.columnDefinitions=this.columnDefinitions)})}),this.queueRowIndexUpdate())},this.queueRowIndexUpdate=()=>{this.rowindexUpdateQueued||(this.rowindexUpdateQueued=!0,n.Updates.enqueue(this.updateRowIndexes))},this.updateRowIndexes=()=>{let e=this.gridTemplateColumns;if(e===void 0){if(this.generatedGridTemplateColumns===""&&this.rowElements.length>0){const t=this.rowElements[0];this.generatedGridTemplateColumns=new Array(t.cellElements.length).fill("1fr").join(" ")}e=this.generatedGridTemplateColumns}this.rowElements.forEach((t,i)=>{const l=t;l.rowIndex=i,l.gridTemplateColumns=e,this.columnDefinitionsStale&&(l.columnDefinitions=this.columnDefinitions)}),this.rowindexUpdateQueued=!1,this.columnDefinitionsStale=!1},this.#l=e=>{(e.key==="Enter"||e.key===" ")&&this.#t(e)},this.#t=({target:e,ctrlKey:t,shiftKey:i,metaKey:l})=>{if(!(e.getAttribute("role")!=="gridcell"||e.getAttribute("cell-type")!=="default")){if(this.selectionMode===p.singleCell||this.selectionMode===p.multiCell){this.#i({target:e,ctrlKey:t,shiftKey:i,metaKey:l});return}(this.selectionMode===p.singleRow||this.selectionMode===p.multiRow)&&this.#n({target:e,ctrlKey:t,shiftKey:i,metaKey:l})}},this.#i=({target:e,ctrlKey:t,shiftKey:i,metaKey:l})=>{const r=e;if(this.selectionMode===p.multiCell&&(t||i||l))r.selected=!this.#a.includes(r);else{const s=r.selected;this._resetSelection(!0),r.selected=!s}},this.#n=({target:e,ctrlKey:t,shiftKey:i,metaKey:l})=>{const r=e.parentNode;if(this.selectionMode===p.multiRow&&(t||i||l))r.selected=!this.#r.includes(r);else{const s=r.selected;this._resetSelection(!0),r.selected=!s}},this.#o={handleChange(e,t){/* v8 ignore else -- @preserve */if(t==="columnDefinitions"){/* v8 ignore else -- @preserve */e.$fastController.isConnected&&e.toggleGeneratedHeader()}}},this._resetSelection=(e=!1)=>{const t=Array.from(this.querySelectorAll('[role="gridcell"], [cell-type="default"]')),i=Array.from(this.querySelectorAll('[role="row"], [row-type="default"]'));if(this.selectionMode===p.singleCell||this.selectionMode===p.multiCell){for(const l of t)l._selectable=!0,l.selected=e?!1:l.selected||!1;for(const l of i)l._selectable=!1,l.selected=!1}if(this.selectionMode===p.none)for(const l of[...t,...i])l._selectable=!1,l.selected=!1;if(this.selectionMode===p.singleRow||this.selectionMode===p.multiRow){for(const l of t)l._selectable=!1,l.selected=!1;for(const l of i)l._selectable=!0,l.selected=e?!1:l.selected||!1}},this.addEventListener("click",this.#t),this.addEventListener("keydown",this.#l)}static generateTemplateColumns(e){let t="";return e.forEach(i=>{t=`${t}${t===""?"":" "}1fr`}),t}noTabbingChanged(){this.$fastController.isConnected&&this.#e()}#e(){this.setAttribute("tabIndex",this.noTabbing||this.contains(document.activeElement)?"-1":"0")}generateHeaderChanged(){this.$fastController.isConnected&&this.toggleGeneratedHeader()}gridTemplateColumnsChanged(){/* v8 ignore if -- @preserve */this.$fastController.isConnected&&(this.updateRowIndexes(),this.fixedColumns&&this.fixedColumns>0&&this.applyFixedColumns())}rowsDataChanged(){this.columnDefinitions===null&&this.rowsData.length>0&&(this.columnDefinitions=_.generateColumns(this.rowsData[0])),this.$fastController.isConnected&&this.toggleGeneratedHeader()}columnDefinitionsChanged(){if(this.columnDefinitions===null){this.generatedGridTemplateColumns="";return}this.generatedGridTemplateColumns=_.generateTemplateColumns(this.columnDefinitions);/* v8 ignore if -- @preserve */this.$fastController.isConnected&&(this.columnDefinitionsStale=!0,this.queueRowIndexUpdate())}headerCellItemTemplateChanged(){/* v8 ignore if -- @preserve */this.$fastController.isConnected&&this.generatedHeader!==null&&(this.generatedHeader.headerCellItemTemplate=this.headerCellItemTemplate)}focusRowIndexChanged(){this.$fastController.isConnected&&this.queueFocusUpdate()}focusColumnIndexChanged(){this.$fastController.isConnected&&this.queueFocusUpdate()}fixedColumnsChanged(){/* v8 ignore if -- @preserve */this.$fastController.isConnected&&(this.applyFixedColumns(),this.setupResizeObserver())}setupResizeObserver(){this.resizeObserver&&(this.resizeObserver.disconnect(),this.resizeObserver=void 0),typeof ResizeObserver<"u"&&this.fixedColumns&&this.fixedColumns>0&&(this.resizeObserver=new ResizeObserver(()=>{this.applyFixedColumns()}),this.resizeObserver.observe(this))}connectedCallback(){super.connectedCallback();/* v8 ignore else -- @preserve */this.rowItemTemplate===void 0&&(this.rowItemTemplate=this.defaultRowItemTemplate);/* v8 ignore else -- @preserve */this.behaviorOrchestrator===null&&(this.behaviorOrchestrator=n.ViewBehaviorOrchestrator.create(this),this.$fastController.addBehavior(this.behaviorOrchestrator),this.behaviorOrchestrator.addBehaviorFactory(new F.RepeatDirective(y.normalizeBinding(e=>e.rowsData),y.normalizeBinding(e=>e.rowItemTemplate),{positioning:!0}),this.appendChild(document.createComment("")))),this.toggleGeneratedHeader(),this.addEventListener("row-focused",this.handleRowFocus),this.addEventListener(I,this.handleFocus),this.addEventListener(g,this.handleKeydown),this.addEventListener(b,this.handleFocusOut),this.observer=new MutationObserver(this.onChildListChange),this.observer.observe(this,{childList:!0}),this.setupResizeObserver(),n.Updates.enqueue(this.queueRowIndexUpdate),this.#e(),n.Observable.getNotifier(this).subscribe(this.#o,"columnDefinitions")}disconnectedCallback(){super.disconnectedCallback(),this.removeEventListener("row-focused",this.handleRowFocus),this.removeEventListener(I,this.handleFocus),this.removeEventListener(g,this.handleKeydown),this.removeEventListener(b,this.handleFocusOut),this.observer.disconnect(),this.resizeObserver&&(this.resizeObserver.disconnect(),this.resizeObserver=void 0),this.generatedHeader=null,n.Observable.getNotifier(this).unsubscribe(this.#o,"columnDefinitions")}handleRowFocus(e){this.isUpdatingFocus=!0;const t=e.target;this.focusRowIndex=this.rowElements.indexOf(t),this.focusColumnIndex=t.focusColumnIndex,this.setAttribute("tabIndex","-1"),this.isUpdatingFocus=!1}handleFocus(e){this.focusOnCell(this.focusRowIndex,this.focusColumnIndex,!0)}handleFocusOut(e){(e.relatedTarget===null||!this.contains(e.relatedTarget))&&this.setAttribute("tabIndex",this.noTabbing?"-1":"0")}handleKeydown(e){if(e.defaultPrevented)return;let t;const i=this.rowElements.length-1,l=this.offsetHeight+this.scrollTop,r=this.rowElements[i];switch(e.key){case h.keyArrowUp:e.preventDefault(),this.focusOnCell(this.focusRowIndex-1,this.focusColumnIndex,!0);break;case h.keyArrowDown:e.preventDefault(),this.focusOnCell(this.focusRowIndex+1,this.focusColumnIndex,!0);break;case h.keyPageUp:if(e.preventDefault(),this.rowElements.length===0){this.focusOnCell(0,0,!1);break}if(this.focusRowIndex===0){this.focusOnCell(0,this.focusColumnIndex,!1);return}for(t=this.focusRowIndex-1,t;t>=0;t--){const s=this.rowElements[t];if(s.offsetTop<this.scrollTop){this.scrollTop=s.offsetTop+s.clientHeight-this.clientHeight;break}}this.focusOnCell(t,this.focusColumnIndex,!1);break;case h.keyPageDown:if(e.preventDefault(),this.rowElements.length===0){this.focusOnCell(0,0,!1);break}if(this.focusRowIndex>=i||r.offsetTop+r.offsetHeight<=l){this.focusOnCell(i,this.focusColumnIndex,!1);return}for(t=this.focusRowIndex+1,t;t<=i;t++){const s=this.rowElements[t];if(s.offsetTop+s.offsetHeight>l){let C=0;this.generateHeader===a.GenerateHeaderOptions.sticky&&this.generatedHeader!==null&&(C=this.generatedHeader.clientHeight),this.scrollTop=s.offsetTop-C;break}}this.focusOnCell(t,this.focusColumnIndex,!1);break;case h.keyHome:{/* v8 ignore else -- @preserve */e.ctrlKey&&(e.preventDefault(),this.focusOnCell(0,0,!0));break}case h.keyEnd:{/* v8 ignore else -- @preserve */e.ctrlKey&&this.columnDefinitions!==null&&(e.preventDefault(),this.focusOnCell(this.rowElements.length-1,this.columnDefinitions.length-1,!0));break}}}queueFocusUpdate(){this.isUpdatingFocus&&this.contains(document.activeElement)||this.pendingFocusUpdate===!1&&(this.pendingFocusUpdate=!0,n.Updates.enqueue(()=>this.updateFocus()))}updateFocus(){this.pendingFocusUpdate=!1,this.focusOnCell(this.focusRowIndex,this.focusColumnIndex,!0)}toggleGeneratedHeader(){if(this.generatedHeader!==null&&(this.removeChild(this.generatedHeader),this.generatedHeader=null),this.generateHeader!==a.GenerateHeaderOptions.none&&this.columnDefinitions!==null){const e=document.createElement(this.rowElementTag);this.generatedHeader=e,this.generatedHeader.columnDefinitions=this.columnDefinitions,this.generatedHeader.gridTemplateColumns=this.gridTemplateColumns,this.generatedHeader.rowType=this.generateHeader===a.GenerateHeaderOptions.sticky?a.DataGridRowTypes.stickyHeader:a.DataGridRowTypes.header;/* v8 ignore else -- @preserve */this.firstChild!==null&&this.insertBefore(e,this.firstChild);return}}slottedRowElementsChanged(e,t){this._resetSelection()}get#r(){return this.rowElements.filter(e=>e.selected)}get#a(){return this.rowElements.reduce((e,t)=>{const l=Array.from(t.children).filter(r=>r.selected);return e.concat(l)},[])}selectionModeChanged(e){if(e===void 0){n.Updates.enqueue(this._resetSelection);return}this._resetSelection(!0)}#l;#t;#i;#n;#o;static generateColumns(e){return Object.keys(e).map((t,i)=>({columnDataKey:t,gridColumn:`${i}`}))}applyFixedColumns(){if(!this.fixedColumns||this.fixedColumns<=0){this.clearFixedColumns();return}this.calculateFixedColumnPositions(),this.applyFixedColumnStyling()}applyFixedColumnStyling(){this.rowElements.forEach(e=>{const t=e.querySelectorAll('[role="cell"], [role="gridcell"], [role="columnheader"], [cell-type="default"], [cell-type="columnheader"]');this.fixedColumnsPositions.forEach((i,l)=>{/* v8 ignore else -- @preserve */if(l<t.length){const r=t[l];/* v8 ignore else -- @preserve */typeof r.setFixedPosition=="function"&&r.setFixedPosition(`${i}px`)}})})}calculateFixedColumnPositions(){if(this.fixedColumnsPositions=[],this.rowElements.length===0)return;const e=this.rowElements[0].querySelectorAll('[role="cell"], [role="gridcell"], [role="columnheader"], [cell-type="default"], [cell-type="columnheader"]');let t=0;for(let i=0;i<Math.min(this.fixedColumns,e.length);i++)this.fixedColumnsPositions.push(t),t+=e[i].offsetWidth}clearFixedColumns(){if(this.rowElements.length===0){this.fixedColumnsPositions=[];return}this.rowElements.forEach(e=>{const t=e.querySelectorAll('[role="cell"], [role="gridcell"], [role="columnheader"], [cell-type="default"], [cell-type="columnheader"]');this.fixedColumnsPositions.forEach((i,l)=>{/* v8 ignore else -- @preserve */if(l<t.length){const r=t[l];/* v8 ignore else -- @preserve */typeof r.setFixedPosition=="function"&&r.setFixedPosition(void 0)}})}),this.fixedColumnsPositions=[]}};u([n.attr({attribute:"no-tabbing",mode:"boolean"})],c.prototype,"noTabbing");u([n.attr({attribute:"generate-header"})],c.prototype,"generateHeader");u([n.attr({attribute:"grid-template-columns"})],c.prototype,"gridTemplateColumns");u([n.observable],c.prototype,"rowsData");u([n.observable],c.prototype,"columnDefinitions");u([n.observable],c.prototype,"rowItemTemplate");u([n.observable],c.prototype,"cellItemTemplate");u([n.observable],c.prototype,"headerCellItemTemplate");u([n.observable],c.prototype,"focusRowIndex");u([n.observable],c.prototype,"focusColumnIndex");u([n.attr({attribute:"fixed-columns",converter:n.nullableNumberConverter})],c.prototype,"fixedColumns");u([n.observable],c.prototype,"defaultRowItemTemplate");u([n.observable],c.prototype,"rowElementTag");u([n.observable],c.prototype,"rowElements");u([n.observable],c.prototype,"slottedRowElements");u([n.attr({attribute:"selection-mode"})],c.prototype,"selectionMode");let K=c;function B(o){const e=o.tagFor(d);return n.html`
|
|
10
10
|
<${e}
|
|
11
11
|
:rowData="${t=>t}"
|
|
12
12
|
:cellItemTemplate="${(t,i)=>i.parent.cellItemTemplate}"
|
|
13
13
|
:headerCellItemTemplate="${(t,i)=>i.parent.headerCellItemTemplate}"
|
|
14
14
|
></${e}>
|
|
15
|
-
`}function
|
|
15
|
+
`}function Q(o){return o.selectionMode===void 0||o.selectionMode===p.none?null:o.selectionMode.includes("multi")?"true":"false"}function j(o){if(o.columnDefinitions===null){const e=o.querySelector('[cell-type="columnheader"]')?.parentElement;if(o.generateHeader===a.GenerateHeaderOptions.default&&(e?.getAttribute("row-type")===a.DataGridRowTypes.header||e?.getAttribute("row-type")===a.DataGridRowTypes.stickyHeader))return;if(e){const t=o.generateHeader===a.GenerateHeaderOptions.sticky?a.DataGridRowTypes.stickyHeader:a.DataGridRowTypes.header;e.setAttribute("row-type",t)}}}function N(o,{event:e}){e.stopPropagation()}const W=o=>{const e=B(o),t=o.tagFor(d,!0);return n.html`
|
|
16
16
|
<template
|
|
17
|
-
aria-multiselectable="${
|
|
17
|
+
aria-multiselectable="${Q}"
|
|
18
18
|
role="grid"
|
|
19
19
|
tabindex="0"
|
|
20
|
-
@sort="${
|
|
20
|
+
@sort="${N}"
|
|
21
21
|
:rowElementTag="${()=>t}"
|
|
22
22
|
:defaultRowItemTemplate="${e}"
|
|
23
|
-
${
|
|
23
|
+
${R.children({property:"rowElements",filter:w.elements("[role=row],[data-vvd-component=data-grid-row]")})}
|
|
24
24
|
>
|
|
25
25
|
<div class="base">
|
|
26
|
-
${
|
|
27
|
-
<slot ${
|
|
26
|
+
${j}
|
|
27
|
+
<slot ${w.slotted("slottedRowElements")}></slot>
|
|
28
28
|
</div>
|
|
29
29
|
</template>
|
|
30
|
-
`};function
|
|
30
|
+
`};function J(o){return o._selectable&&o.selected?"true":o._selectable&&!o.selected?"false":null}function X(o){const e=o.tagFor(f);return n.html`
|
|
31
31
|
<${e}
|
|
32
32
|
cell-type="${t=>t.isRowHeader?"rowheader":void 0}"
|
|
33
33
|
grid-column="${(t,i)=>i.index+1}"
|
|
@@ -35,41 +35,41 @@
|
|
|
35
35
|
:columnDefinition="${t=>t}"
|
|
36
36
|
selected="${(t,i)=>i.parent.ariaSelected==="true"?!0:null}"
|
|
37
37
|
></${e}>
|
|
38
|
-
`}function
|
|
38
|
+
`}function Y(o){const e=o.tagFor(f);return n.html`
|
|
39
39
|
<${e}
|
|
40
40
|
cell-type="columnheader"
|
|
41
41
|
grid-column="${(t,i)=>i.index+1}"
|
|
42
42
|
:columnDefinition="${t=>t}"
|
|
43
43
|
></${e}>
|
|
44
|
-
`}const
|
|
44
|
+
`}const Z=o=>{const e=X(o),t=Y(o),i=l=>H.classNames("base",["selected",!!l.selected]);return n.html`
|
|
45
45
|
<template
|
|
46
|
-
${
|
|
46
|
+
${D.applyHostSemantics({role:"row",ariaSelected:J})}
|
|
47
47
|
class="${l=>l.rowType!=="default"?l.rowType:""}"
|
|
48
48
|
:defaultCellItemTemplate="${e}"
|
|
49
49
|
:defaultHeaderCellItemTemplate="${t}"
|
|
50
|
-
${
|
|
50
|
+
${R.children({property:"cellElements",filter:w.elements('[role="cell"],[role="gridcell"],[role="columnheader"],[role="rowheader"],[data-vvd-component="data-grid-cell"]')})}
|
|
51
51
|
>
|
|
52
52
|
<div
|
|
53
53
|
class="${i}"
|
|
54
54
|
style="grid-template-columns: ${l=>l.gridTemplateColumns};"
|
|
55
55
|
>
|
|
56
|
-
<slot ${
|
|
56
|
+
<slot ${w.slotted("slottedCellElements")}></slot>
|
|
57
57
|
</div>
|
|
58
58
|
</template>
|
|
59
|
-
`};function
|
|
60
|
-
${
|
|
61
|
-
<${e} class="header-icon" name="${
|
|
59
|
+
`};function x(o){return o.cellType==="columnheader"&&o.sortDirection!==void 0&&o.sortDirection!==a.DataGridCellSortStates.other}function ee(o){return o.sortDirection===a.DataGridCellSortStates.ascending?"sort-asc-solid":o.sortDirection===a.DataGridCellSortStates.descending?"sort-desc-solid":"sort-solid"}function te(o){return o._selectable&&o.selected?"true":o._selectable&&!o.selected?"false":null}function oe(o){const e=o.tagFor(S.Icon);return n.html`
|
|
60
|
+
${T.when(x,n.html`
|
|
61
|
+
<${e} class="header-icon" name="${ee}"></${e}>
|
|
62
62
|
`)}
|
|
63
|
-
`}function
|
|
63
|
+
`}function le(o){return o.cellType===a.DataGridCellTypes.columnHeader&&o.sortDirection!==void 0}function G(o){return o.sortDirection??a.DataGridCellSortStates.none}function ie(o){const e=G(o);return o.locale.dataGrid.cell.sortStatus?.[e]}function ne(o){const e=G(o);return o.locale.dataGrid.cell.sortInstruction?.[e]}function re(o){return[ie(o),ne(o)].filter(e=>!!e).join(" ").trim()}function ae(o,e){return(e.key===h.keyEnter||e.key===h.keySpace)&&o._handleInteraction(),!0}const se=o=>{const e=o.tagFor($.VisuallyHidden),t=i=>H.classNames("base",["selected",!!i.selected]);return n.html`
|
|
64
64
|
<template
|
|
65
65
|
tabindex="-1"
|
|
66
|
-
${
|
|
66
|
+
${D.applyHostSemantics({role:i=>a.DataGridCellRole[i.cellType]??a.DataGridCellRole.default,ariaSelected:te,ariaSort:i=>i.sortDirection??null})}
|
|
67
67
|
@click="${i=>i._handleInteraction()}"
|
|
68
|
-
@keydown="${(i,l)=>
|
|
68
|
+
@keydown="${(i,l)=>ae(i,l.event)}"
|
|
69
69
|
>
|
|
70
70
|
<div
|
|
71
71
|
class="${t}"
|
|
72
|
-
role="${i=>
|
|
72
|
+
role="${i=>x(i)?"button":void 0}"
|
|
73
73
|
>
|
|
74
74
|
${i=>i.selected?n.html`<${e}
|
|
75
75
|
data-announcement="selection"
|
|
@@ -77,19 +77,19 @@
|
|
|
77
77
|
${l=>l.locale.dataGrid.cell.selected}
|
|
78
78
|
</${e}>`:null}
|
|
79
79
|
<slot></slot>
|
|
80
|
-
${
|
|
80
|
+
${T.when(x,n.html`<${e}
|
|
81
81
|
data-announcement="button-role"
|
|
82
82
|
>
|
|
83
83
|
${i=>i.locale.dataGrid.cell.button}
|
|
84
84
|
</${e}>
|
|
85
85
|
`)}
|
|
86
|
-
${
|
|
86
|
+
${T.when(le,n.html`<${e}
|
|
87
87
|
aria-live="polite"
|
|
88
88
|
data-announcement="sort-state"
|
|
89
89
|
>
|
|
90
|
-
${
|
|
90
|
+
${re}
|
|
91
91
|
</${e}>`)}
|
|
92
|
-
${i=>
|
|
92
|
+
${i=>oe(o)}
|
|
93
93
|
</div>
|
|
94
94
|
</template>
|
|
95
|
-
`},
|
|
95
|
+
`},ce=n.defineVividComponent("data-grid-cell",f,se,[S.iconDefinition,$.visuallyHiddenDefinition],{styles:q}),de=n.defineVividComponent("data-grid-row",d,Z,[ce],{styles:A}),ue=n.defineVividComponent("data-grid",K,W,[de],{styles:z}),he=n.createRegisterFunction(ue);he();
|