@skyux/ag-grid 14.3.10 → 14.3.12

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.
@@ -1,12 +1,12 @@
1
1
  import { NgClass, CommonModule, NgTemplateOutlet, AsyncPipe } from '@angular/common';
2
2
  import * as i0 from '@angular/core';
3
- import { NgModule, Injectable, signal, input, booleanAttribute, numberAttribute, viewChild, inject, DestroyRef, ElementRef, DOCUMENT, computed, effect, ContentChild, ChangeDetectionStrategy, Component, contentChildren, linkedSignal, ChangeDetectorRef, untracked, Directive, InjectionToken, model, output, contentChild, EnvironmentInjector, afterNextRender, HostListener, ViewChild, ViewEncapsulation, HostBinding, isSignal, Input, RendererFactory2, CSP_NONCE } from '@angular/core';
3
+ import { NgModule, inject, Injectable, signal, input, booleanAttribute, numberAttribute, viewChild, DestroyRef, ElementRef, DOCUMENT, computed, effect, ContentChild, ChangeDetectionStrategy, Component, contentChildren, linkedSignal, ChangeDetectorRef, untracked, Directive, InjectionToken, model, output, contentChild, EnvironmentInjector, afterNextRender, HostListener, ViewChild, ViewEncapsulation, HostBinding, isSignal, Input, RendererFactory2, CSP_NONCE } from '@angular/core';
4
4
  import { AgGridAngular } from 'ag-grid-angular';
5
5
  import * as i3 from '@skyux/i18n';
6
6
  import { SkyLibResourcesService, SkyI18nModule } from '@skyux/i18n';
7
7
  import { toSignal, takeUntilDestroyed, toObservable } from '@angular/core/rxjs-interop';
8
8
  import * as i1 from '@skyux/core';
9
- import { SkyMutationObserverService, SkyIdModule, SkyViewkeeperModule, SkyMediaQueryService, SkyResizeObserverService, SkyAffixModule, SkyOverlayService, SkyScrollableHostService, SKY_STACKING_CONTEXT, SkyNumericModule, SkyDynamicComponentService, SkyDynamicComponentLocation, SkyLogService } from '@skyux/core';
9
+ import { SkyCoreAdapterService, SkyMutationObserverService, SkyIdModule, SkyViewkeeperModule, SkyMediaQueryService, SkyResizeObserverService, SkyAffixModule, SkyOverlayService, SkyScrollableHostService, SKY_STACKING_CONTEXT, SkyNumericModule, SkyDynamicComponentService, SkyDynamicComponentLocation, SkyLogService } from '@skyux/core';
10
10
  import { SkyDataManagerService, SkyDataManagerState, SkyDataViewState } from '@skyux/data-manager';
11
11
  import { Observable, EMPTY, merge, Subject, map, takeUntil, switchMap, of, filter, Subscription, startWith, scan, BehaviorSubject, take, distinctUntilChanged, fromEvent, first, isObservable } from 'rxjs';
12
12
  import * as i1$5 from '@skyux/theme';
@@ -256,10 +256,7 @@ function getSkyAgGridThemeClassName(editable, themeSettings, compactLayout) {
256
256
  * @internal
257
257
  */
258
258
  class SkyAgGridAdapterService {
259
- #skyAdapterService;
260
- constructor(skyAdapterService) {
261
- this.#skyAdapterService = skyAdapterService;
262
- }
259
+ #skyAdapterService = inject(SkyCoreAdapterService);
263
260
  getElementOrParentWithClass(element, className) {
264
261
  if (element && element.classList.contains(className)) {
265
262
  return element;
@@ -299,7 +296,7 @@ class SkyAgGridAdapterService {
299
296
  focusChild.focus();
300
297
  }
301
298
  }
302
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.0", ngImport: i0, type: SkyAgGridAdapterService, deps: [{ token: i1.SkyCoreAdapterService }], target: i0.ɵɵFactoryTarget.Injectable }); }
299
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.0", ngImport: i0, type: SkyAgGridAdapterService, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
303
300
  static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.2.0", ngImport: i0, type: SkyAgGridAdapterService, providedIn: 'root' }); }
304
301
  }
305
302
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.0", ngImport: i0, type: SkyAgGridAdapterService, decorators: [{
@@ -307,7 +304,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.0", ngImpor
307
304
  args: [{
308
305
  providedIn: 'root',
309
306
  }]
310
- }], ctorParameters: () => [{ type: i1.SkyCoreAdapterService }] });
307
+ }] });
311
308
 
312
309
  /**
313
310
  * These column types can be used by setting the AG Grid [column definition `type`](https://www.ag-grid.com/angular-data-grid/column-properties/#reference-editing) to one of the following values.
@@ -2295,10 +2292,7 @@ class SkyAgGridCellRendererCurrencyValidatorComponent {
2295
2292
  set parameters(value) {
2296
2293
  this.agInit(value);
2297
2294
  }
2298
- #changeDetector;
2299
- constructor(changeDetector) {
2300
- this.#changeDetector = changeDetector;
2301
- }
2295
+ #changeDetector = inject(ChangeDetectorRef);
2302
2296
  /**
2303
2297
  * agInit is called by agGrid once after the renderer is created and provides the renderer with the information it needs.
2304
2298
  * @param params The cell renderer params that include data about the cell, column, row, and grid.
@@ -2315,7 +2309,7 @@ class SkyAgGridCellRendererCurrencyValidatorComponent {
2315
2309
  refresh(params) {
2316
2310
  return false;
2317
2311
  }
2318
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.0", ngImport: i0, type: SkyAgGridCellRendererCurrencyValidatorComponent, deps: [{ token: i0.ChangeDetectorRef }], target: i0.ɵɵFactoryTarget.Component }); }
2312
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.0", ngImport: i0, type: SkyAgGridCellRendererCurrencyValidatorComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
2319
2313
  static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.0", type: SkyAgGridCellRendererCurrencyValidatorComponent, isStandalone: true, selector: "sky-ag-grid-cell-renderer-currency-validator", inputs: { parameters: "parameters" }, ngImport: i0, template: "@if (cellRendererParams) {\n <sky-ag-grid-cell-validator-tooltip [params]=\"cellRendererParams\">\n @if (isNumeric(cellRendererParams.value)) {\n <sky-ag-grid-cell-renderer-currency [params]=\"cellRendererParams\" />\n } @else {\n {{ cellRendererParams.value }}\n }\n </sky-ag-grid-cell-validator-tooltip>\n}\n", styles: [":host{display:contents}\n"], dependencies: [{ kind: "component", type: SkyAgGridCellValidatorTooltipComponent, selector: "sky-ag-grid-cell-validator-tooltip", inputs: ["params"] }, { kind: "component", type: SkyAgGridCellRendererCurrencyComponent, selector: "sky-ag-grid-cell-renderer-currency", inputs: ["params"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
2320
2314
  }
2321
2315
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.0", ngImport: i0, type: SkyAgGridCellRendererCurrencyValidatorComponent, decorators: [{
@@ -2324,7 +2318,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.0", ngImpor
2324
2318
  SkyAgGridCellValidatorTooltipComponent,
2325
2319
  SkyAgGridCellRendererCurrencyComponent,
2326
2320
  ], template: "@if (cellRendererParams) {\n <sky-ag-grid-cell-validator-tooltip [params]=\"cellRendererParams\">\n @if (isNumeric(cellRendererParams.value)) {\n <sky-ag-grid-cell-renderer-currency [params]=\"cellRendererParams\" />\n } @else {\n {{ cellRendererParams.value }}\n }\n </sky-ag-grid-cell-validator-tooltip>\n}\n", styles: [":host{display:contents}\n"] }]
2327
- }], ctorParameters: () => [{ type: i0.ChangeDetectorRef }], propDecorators: { parameters: [{
2321
+ }], propDecorators: { parameters: [{
2328
2322
  type: Input
2329
2323
  }] } });
2330
2324
 
@@ -2332,12 +2326,12 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.0", ngImpor
2332
2326
  * @internal
2333
2327
  */
2334
2328
  class SkyAgGridCellRendererLookupComponent {
2335
- #changeDetector;
2336
- constructor(changeDetector) {
2329
+ constructor() {
2337
2330
  this.value = '';
2338
2331
  this.summaryCount = 0;
2339
- this.#changeDetector = changeDetector;
2332
+ this.#changeDetector = inject(ChangeDetectorRef);
2340
2333
  }
2334
+ #changeDetector;
2341
2335
  agInit(params) {
2342
2336
  this.summaryCount = params.value?.length || 0;
2343
2337
  this.value = `${params.valueFormatted}`;
@@ -2347,13 +2341,13 @@ class SkyAgGridCellRendererLookupComponent {
2347
2341
  this.agInit(params);
2348
2342
  return true;
2349
2343
  }
2350
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.0", ngImport: i0, type: SkyAgGridCellRendererLookupComponent, deps: [{ token: i0.ChangeDetectorRef }], target: i0.ɵɵFactoryTarget.Component }); }
2344
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.0", ngImport: i0, type: SkyAgGridCellRendererLookupComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
2351
2345
  static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.0", type: SkyAgGridCellRendererLookupComponent, isStandalone: true, selector: "sky-cell-renderer-lookup", ngImport: i0, template: "@if (summaryCount > 5) {\n {{ 'skyux_lookup_tokens_summary' | skyLibResources: summaryCount }}\n} @else {\n {{ value }}\n}\n", styles: [":host{overflow:hidden;white-space:nowrap;text-overflow:ellipsis}\n"], dependencies: [{ kind: "ngmodule", type: SkyI18nModule }, { kind: "pipe", type: i3.SkyLibResourcesPipe, name: "skyLibResources" }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
2352
2346
  }
2353
2347
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.0", ngImport: i0, type: SkyAgGridCellRendererLookupComponent, decorators: [{
2354
2348
  type: Component,
2355
2349
  args: [{ selector: 'sky-cell-renderer-lookup', changeDetection: ChangeDetectionStrategy.OnPush, imports: [SkyI18nModule], template: "@if (summaryCount > 5) {\n {{ 'skyux_lookup_tokens_summary' | skyLibResources: summaryCount }}\n} @else {\n {{ value }}\n}\n", styles: [":host{overflow:hidden;white-space:nowrap;text-overflow:ellipsis}\n"] }]
2356
- }], ctorParameters: () => [{ type: i0.ChangeDetectorRef }] });
2350
+ }] });
2357
2351
 
2358
2352
  /**
2359
2353
  * @internal