igniteui-angular 19.1.5 → 19.1.7

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.
Files changed (39) hide show
  1. package/fesm2022/igniteui-angular.mjs +42 -31
  2. package/fesm2022/igniteui-angular.mjs.map +1 -1
  3. package/lib/core/styles/components/switch/_switch-component.scss +0 -65
  4. package/lib/core/styles/components/switch/_switch-theme.scss +0 -81
  5. package/lib/core/styles/components/tree/_tree-theme.scss +1 -3
  6. package/lib/grids/common/random.d.ts +5 -0
  7. package/lib/grids/hierarchical-grid/events.d.ts +1 -0
  8. package/lib/query-builder/query-builder-tree.component.d.ts +2 -2
  9. package/migrations/migration-collection.json +5 -0
  10. package/migrations/update-19_1_6/changes/theme-changes.json +35 -0
  11. package/migrations/update-19_1_6/index.d.ts +3 -0
  12. package/migrations/update-19_1_6/index.js +18 -0
  13. package/package.json +2 -2
  14. package/styles/igniteui-angular-dark.css +1 -1
  15. package/styles/igniteui-angular.css +1 -1
  16. package/styles/igniteui-bootstrap-dark.css +1 -1
  17. package/styles/igniteui-bootstrap-light.css +1 -1
  18. package/styles/igniteui-dark-green.css +1 -1
  19. package/styles/igniteui-fluent-dark-excel.css +1 -1
  20. package/styles/igniteui-fluent-dark-word.css +1 -1
  21. package/styles/igniteui-fluent-dark.css +1 -1
  22. package/styles/igniteui-fluent-light-excel.css +1 -1
  23. package/styles/igniteui-fluent-light-word.css +1 -1
  24. package/styles/igniteui-fluent-light.css +1 -1
  25. package/styles/igniteui-indigo-dark.css +1 -1
  26. package/styles/igniteui-indigo-light.css +1 -1
  27. package/styles/maps/igniteui-angular-dark.css.map +1 -1
  28. package/styles/maps/igniteui-angular.css.map +1 -1
  29. package/styles/maps/igniteui-bootstrap-dark.css.map +1 -1
  30. package/styles/maps/igniteui-bootstrap-light.css.map +1 -1
  31. package/styles/maps/igniteui-dark-green.css.map +1 -1
  32. package/styles/maps/igniteui-fluent-dark-excel.css.map +1 -1
  33. package/styles/maps/igniteui-fluent-dark-word.css.map +1 -1
  34. package/styles/maps/igniteui-fluent-dark.css.map +1 -1
  35. package/styles/maps/igniteui-fluent-light-excel.css.map +1 -1
  36. package/styles/maps/igniteui-fluent-light-word.css.map +1 -1
  37. package/styles/maps/igniteui-fluent-light.css.map +1 -1
  38. package/styles/maps/igniteui-indigo-dark.css.map +1 -1
  39. package/styles/maps/igniteui-indigo-light.css.map +1 -1
@@ -17261,7 +17261,7 @@ class IgxGridForOfDirective extends IgxForOfDirective {
17261
17261
  changes.forEachItem((item) => {
17262
17262
  if (item.previousIndex !== null &&
17263
17263
  (numRemovedItems < 2 || !identityChanges.length || identityChanges[item.currentIndex])
17264
- && this.igxForScrollOrientation !== "horizontal") {
17264
+ && this.igxForScrollOrientation !== "horizontal" && this.individualSizeCache.length > 0) {
17265
17265
  // Reuse cache on those who have previousIndex.
17266
17266
  // When there are more than one removed items currently the changes are not readable so ones with identity change
17267
17267
  // should be racalculated.
@@ -49257,15 +49257,10 @@ class IgxQueryBuilderTreeComponent {
49257
49257
  */
49258
49258
  set fields(fields) {
49259
49259
  this._fields = fields;
49260
+ this._fields = this._fields?.map(f => ({ ...f, filters: this.getFilters(f), pipeArgs: this.getPipeArgs(f) }));
49260
49261
  if (!this._fields && this.isAdvancedFiltering()) {
49261
49262
  this._fields = this.entities[0].fields;
49262
49263
  }
49263
- if (this._fields) {
49264
- this._fields.forEach(field => {
49265
- this.setFilters(field);
49266
- this.setFormat(field);
49267
- });
49268
- }
49269
49264
  }
49270
49265
  /**
49271
49266
  * Returns the expression tree.
@@ -50037,7 +50032,7 @@ class IgxQueryBuilderTreeComponent {
50037
50032
  this.fieldSelect.input.nativeElement.focus();
50038
50033
  }
50039
50034
  else if (this.selectedField.filters.condition(this.selectedCondition)?.isUnary) {
50040
- this.conditionSelect.input.nativeElement.focus();
50035
+ this.conditionSelect?.input.nativeElement.focus();
50041
50036
  }
50042
50037
  else {
50043
50038
  const input = this.searchValueInput?.nativeElement || this.picker?.getEditElement();
@@ -50303,45 +50298,41 @@ class IgxQueryBuilderTreeComponent {
50303
50298
  };
50304
50299
  return ctx;
50305
50300
  }
50306
- setFormat(field) {
50307
- if (!field.pipeArgs) {
50308
- field.pipeArgs = { digitsInfo: DEFAULT_PIPE_DIGITS_INFO };
50301
+ getPipeArgs(field) {
50302
+ let pipeArgs = { ...field.pipeArgs };
50303
+ if (!pipeArgs) {
50304
+ pipeArgs = { digitsInfo: DEFAULT_PIPE_DIGITS_INFO };
50309
50305
  }
50310
- if (!field.pipeArgs.format) {
50311
- field.pipeArgs.format = field.dataType === DataType.Time ?
50306
+ if (!pipeArgs.format) {
50307
+ pipeArgs.format = field.dataType === DataType.Time ?
50312
50308
  DEFAULT_PIPE_TIME_FORMAT : field.dataType === DataType.DateTime ?
50313
50309
  DEFAULT_PIPE_DATE_TIME_FORMAT : DEFAULT_PIPE_DATE_FORMAT;
50314
50310
  }
50311
+ return pipeArgs;
50315
50312
  }
50316
50313
  selectDefaultCondition() {
50317
50314
  if (this.selectedField && this.selectedField.filters) {
50318
50315
  this.selectedCondition = this.selectedField.filters.conditionList().indexOf('equals') >= 0 ? 'equals' : this.selectedField.filters.conditionList()[0];
50319
50316
  }
50320
50317
  }
50321
- setFilters(field) {
50318
+ getFilters(field) {
50322
50319
  if (!field.filters) {
50323
50320
  switch (field.dataType) {
50324
50321
  case DataType.Boolean:
50325
- field.filters = IgxBooleanFilteringOperand.instance();
50326
- break;
50322
+ return IgxBooleanFilteringOperand.instance();
50327
50323
  case DataType.Number:
50328
50324
  case DataType.Currency:
50329
50325
  case DataType.Percent:
50330
- field.filters = IgxNumberFilteringOperand.instance();
50331
- break;
50326
+ return IgxNumberFilteringOperand.instance();
50332
50327
  case DataType.Date:
50333
- field.filters = IgxDateFilteringOperand.instance();
50334
- break;
50328
+ return IgxDateFilteringOperand.instance();
50335
50329
  case DataType.Time:
50336
- field.filters = IgxTimeFilteringOperand.instance();
50337
- break;
50330
+ return IgxTimeFilteringOperand.instance();
50338
50331
  case DataType.DateTime:
50339
- field.filters = IgxDateTimeFilteringOperand.instance();
50340
- break;
50332
+ return IgxDateTimeFilteringOperand.instance();
50341
50333
  case DataType.String:
50342
50334
  default:
50343
- field.filters = IgxStringFilteringOperand.instance();
50344
- break;
50335
+ return IgxStringFilteringOperand.instance();
50345
50336
  }
50346
50337
  }
50347
50338
  }
@@ -51576,6 +51567,24 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.1.6", ngImpor
51576
51567
  type: Input
51577
51568
  }] } });
51578
51569
 
51570
+ /**
51571
+ * Use the function to get a random UUID string when secure context is not guaranteed making crypto.randomUUID unavailable.
51572
+ * @returns A random UUID string.
51573
+ */
51574
+ function getUUID() {
51575
+ if (typeof crypto.randomUUID === 'function') {
51576
+ return crypto.randomUUID();
51577
+ }
51578
+ // Secure fallback using crypto.getRandomValues()
51579
+ const bytes = new Uint8Array(16);
51580
+ crypto.getRandomValues(bytes);
51581
+ // Set version (4) and variant (RFC 4122)
51582
+ bytes[6] = (bytes[6] & 0x0f) | 0x40; // Version 4
51583
+ bytes[8] = (bytes[8] & 0x3f) | 0x80; // Variant 1
51584
+ const a = [...bytes].map((b) => b.toString(16).padStart(2, '0')).join('');
51585
+ return `${a.slice(0, 8)}-${a.slice(8, 12)}-${a.slice(12, 16)}-${a.slice(16, 20)}-${a.slice(20)}`;
51586
+ }
51587
+
51579
51588
  /**
51580
51589
  * @hidden @internal
51581
51590
  */
@@ -51593,7 +51602,7 @@ class ExpressionUI {
51593
51602
  this.isSelected = false;
51594
51603
  this.isVisible = true;
51595
51604
  // Use IDs to identify expressions clearly and use to track them in template @for cycles.
51596
- this.expressionId = crypto.randomUUID();
51605
+ this.expressionId = getUUID();
51597
51606
  }
51598
51607
  }
51599
51608
  /**
@@ -66386,7 +66395,7 @@ class IgxGridBaseDirective {
66386
66395
  const primaryColumn = this._columns.find(col => col.field === this.primaryKey);
66387
66396
  const idType = this.data.length ?
66388
66397
  this.resolveDataTypes(this.data[0][this.primaryKey]) : primaryColumn ? primaryColumn.dataType : 'string';
66389
- return idType === 'string' ? crypto.randomUUID() : FAKE_ROW_ID--;
66398
+ return idType === 'string' ? getUUID() : FAKE_ROW_ID--;
66390
66399
  }
66391
66400
  /**
66392
66401
  * @hidden
@@ -85871,7 +85880,7 @@ class IgxGridHierarchicalPipe {
85871
85880
  childGridsData[childKey] = childData;
85872
85881
  });
85873
85882
  if (grid.gridAPI.get_row_expansion_state(v)) {
85874
- result.push({ rowID: primaryKey ? v[primaryKey] : v, childGridsData });
85883
+ result.push({ rowID: primaryKey ? v[primaryKey] : v, childGridsData, parentRowData: v });
85875
85884
  }
85876
85885
  });
85877
85886
  return result;
@@ -86224,7 +86233,8 @@ class IgxChildGridRowComponent {
86224
86233
  this.layout.gridCreated.emit({
86225
86234
  owner: this.layout,
86226
86235
  parentID: this.data.rowID,
86227
- grid: this.hGrid
86236
+ grid: this.hGrid,
86237
+ parentRowData: this.data.parentRowData,
86228
86238
  });
86229
86239
  }
86230
86240
  /**
@@ -86239,7 +86249,8 @@ class IgxChildGridRowComponent {
86239
86249
  this.layout.gridInitialized.emit({
86240
86250
  owner: this.layout,
86241
86251
  parentID: this.data.rowID,
86242
- grid: this.hGrid
86252
+ grid: this.hGrid,
86253
+ parentRowData: this.data.parentRowData,
86243
86254
  });
86244
86255
  this.hGrid.cdr.detectChanges();
86245
86256
  }