@ni/nimble-components 19.0.2 → 19.1.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.
@@ -16366,7 +16366,7 @@
16366
16366
 
16367
16367
  /**
16368
16368
  * Do not edit directly
16369
- * Generated on Wed, 17 May 2023 21:20:25 GMT
16369
+ * Generated on Mon, 22 May 2023 18:24:46 GMT
16370
16370
  */
16371
16371
  const Information100DarkUi = "#a46eff";
16372
16372
  const Information100LightUi = "#804ad9";
@@ -28007,6 +28007,10 @@
28007
28007
  * A unique id used internally in the table to identify specific column instances
28008
28008
  */
28009
28009
  this.uniqueId = uniqueId('table-column-slot');
28010
+ /**
28011
+ * Whether this column has a valid configuration.
28012
+ */
28013
+ this.validConfiguration = true;
28010
28014
  /**
28011
28015
  * The operation to use when sorting the table by this column.
28012
28016
  */
@@ -28049,6 +28053,9 @@
28049
28053
  __decorate$1([
28050
28054
  observable
28051
28055
  ], ColumnInternals.prototype, "columnConfig", void 0);
28056
+ __decorate$1([
28057
+ observable
28058
+ ], ColumnInternals.prototype, "validConfiguration", void 0);
28052
28059
  __decorate$1([
28053
28060
  observable
28054
28061
  ], ColumnInternals.prototype, "operandDataRecordFieldName", void 0);
@@ -28102,6 +28109,12 @@
28102
28109
  this.columnInternals.currentSortDirection = this.sortDirection;
28103
28110
  this.columnInternals.currentSortIndex = this.sortIndex;
28104
28111
  }
28112
+ checkValidity() {
28113
+ return this.columnInternals.validConfiguration;
28114
+ }
28115
+ get validity() {
28116
+ return {};
28117
+ }
28105
28118
  sortDirectionChanged() {
28106
28119
  if (!this.sortingDisabled) {
28107
28120
  this.columnInternals.currentSortDirection = this.sortDirection;
@@ -28162,6 +28175,7 @@
28162
28175
  this.duplicateSortIndex = false;
28163
28176
  this.duplicateGroupIndex = false;
28164
28177
  this.idFieldNameNotConfigured = false;
28178
+ this.invalidColumnConfiguration = false;
28165
28179
  this.recordIds = new Set();
28166
28180
  }
28167
28181
  getValidity() {
@@ -28173,7 +28187,8 @@
28173
28187
  missingColumnId: this.missingColumnId,
28174
28188
  duplicateSortIndex: this.duplicateSortIndex,
28175
28189
  duplicateGroupIndex: this.duplicateGroupIndex,
28176
- idFieldNameNotConfigured: this.idFieldNameNotConfigured
28190
+ idFieldNameNotConfigured: this.idFieldNameNotConfigured,
28191
+ invalidColumnConfiguration: this.invalidColumnConfiguration
28177
28192
  };
28178
28193
  }
28179
28194
  isValid() {
@@ -28250,6 +28265,10 @@
28250
28265
  this.duplicateGroupIndex = !this.validateIndicesAreUnique(groupIndices);
28251
28266
  return !this.duplicateGroupIndex;
28252
28267
  }
28268
+ validateColumnConfigurations(columns) {
28269
+ this.invalidColumnConfiguration = columns.some(x => !x.columnInternals.validConfiguration);
28270
+ return !this.invalidColumnConfiguration;
28271
+ }
28253
28272
  getPresentRecordIds(requestedRecordIds) {
28254
28273
  return requestedRecordIds.filter(id => this.recordIds.has(id));
28255
28274
  }
@@ -30598,7 +30617,12 @@
30598
30617
  if ((source instanceof TableColumn
30599
30618
  || source instanceof ColumnInternals)
30600
30619
  && typeof args === 'string') {
30601
- this.updateTracker.trackColumnPropertyChanged(args);
30620
+ if (args === 'validConfiguration') {
30621
+ this.tableValidator.validateColumnConfigurations(this.columns);
30622
+ }
30623
+ else {
30624
+ this.updateTracker.trackColumnPropertyChanged(args);
30625
+ }
30602
30626
  }
30603
30627
  }
30604
30628
  /** @internal */
@@ -30867,6 +30891,7 @@
30867
30891
  this.tableValidator.validateColumnIds(this.columns.map(x => x.columnId));
30868
30892
  this.tableValidator.validateColumnSortIndices(this.getColumnsParticipatingInSorting().map(x => x.columnInternals.currentSortIndex));
30869
30893
  this.tableValidator.validateColumnGroupIndices(this.getColumnsParticipatingInGrouping().map(x => x.columnInternals.groupIndex));
30894
+ this.tableValidator.validateColumnConfigurations(this.columns);
30870
30895
  this.validateWithData(this.table.options.data);
30871
30896
  }
30872
30897
  validateWithData(data) {