@ni/nimble-components 20.1.16 → 20.1.17

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.
@@ -16288,7 +16288,7 @@
16288
16288
 
16289
16289
  /**
16290
16290
  * Do not edit directly
16291
- * Generated on Mon, 28 Aug 2023 20:50:10 GMT
16291
+ * Generated on Tue, 29 Aug 2023 16:12:22 GMT
16292
16292
  */
16293
16293
 
16294
16294
  const Information100DarkUi = "#a46eff";
@@ -64560,7 +64560,7 @@ img.ProseMirror-separator {
64560
64560
  this.updateText();
64561
64561
  }
64562
64562
  updateText() {
64563
- if (this.columnConfig?.formatter) {
64563
+ if (this.columnConfig) {
64564
64564
  this.text = formatNumericDate(this.columnConfig.formatter, this.groupHeaderValue);
64565
64565
  }
64566
64566
  else {
@@ -64654,7 +64654,7 @@ img.ProseMirror-separator {
64654
64654
  this.updateText();
64655
64655
  }
64656
64656
  updateText() {
64657
- if (this.columnConfig?.formatter) {
64657
+ if (this.columnConfig) {
64658
64658
  this.text = formatNumericDate(this.columnConfig.formatter, this.cellRecord?.value);
64659
64659
  }
64660
64660
  else {
@@ -64670,6 +64670,14 @@ img.ProseMirror-separator {
64670
64670
  DesignSystem.getOrCreate().withPrefix('nimble').register(dateTextCellView());
64671
64671
  const tableColumnDateTextCellViewTag = DesignSystem.tagFor(TableColumnDateTextCellView);
64672
64672
 
64673
+ /**
64674
+ * Formatting scheme for the date-text table column
64675
+ */
64676
+ const DateTextFormat = {
64677
+ default: undefined,
64678
+ custom: 'custom'
64679
+ };
64680
+
64673
64681
  /**
64674
64682
  * Generic Validator Utility extends Tracker Utility for validation purposes
64675
64683
  */
@@ -64829,15 +64837,22 @@ img.ProseMirror-separator {
64829
64837
  this.updateColumnConfig();
64830
64838
  }
64831
64839
  updateColumnConfig() {
64832
- const columnConfig = {
64833
- formatter: this.createFormatter()
64834
- };
64835
- this.columnInternals.columnConfig = columnConfig;
64836
- this.validator.setCustomOptionsValidity(columnConfig.formatter !== undefined);
64840
+ const formatter = this.createFormatter();
64841
+ if (formatter) {
64842
+ const columnConfig = {
64843
+ formatter
64844
+ };
64845
+ this.columnInternals.columnConfig = columnConfig;
64846
+ this.validator.setCustomOptionsValidity(true);
64847
+ }
64848
+ else {
64849
+ this.columnInternals.columnConfig = undefined;
64850
+ this.validator.setCustomOptionsValidity(false);
64851
+ }
64837
64852
  }
64838
64853
  createFormatter() {
64839
64854
  let options;
64840
- if (!this.format) {
64855
+ if (this.format === DateTextFormat.default) {
64841
64856
  options = {
64842
64857
  dateStyle: 'medium',
64843
64858
  timeStyle: 'medium'