@skyux/ag-grid 7.0.0-beta.11 → 7.0.0-beta.13

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,35 +1,35 @@
1
- import * as i2 from '@angular/common';
1
+ import * as i2$3 from '@angular/common';
2
2
  import { DOCUMENT, CommonModule } from '@angular/common';
3
3
  import * as i0 from '@angular/core';
4
- import { Injectable, Component, ChangeDetectionStrategy, Inject, ContentChild, Directive, Input, ContentChildren, TemplateRef, ViewChildren, ViewChild, EventEmitter, Output, NgModule, ElementRef, ViewEncapsulation, Optional, HostBinding } from '@angular/core';
4
+ import { Injectable, ElementRef, Component, ChangeDetectionStrategy, ViewChild, ViewEncapsulation, Optional, HostBinding, Input, Inject, ContentChild, Directive, ContentChildren, TemplateRef, ViewChildren, EventEmitter, Output, NgModule } from '@angular/core';
5
5
  import * as i1 from '@skyux/core';
6
- import { SkyAffixAutoFitContext, SkyNumericModule, SkyDynamicComponentLocation, SkyViewkeeperModule } from '@skyux/core';
7
- import * as i1$1 from '@skyux/data-manager';
6
+ import { SkyDynamicComponentLocation, SkyAffixAutoFitContext, SkyNumericModule, SkyViewkeeperModule } from '@skyux/core';
7
+ import * as i1$4 from '@skyux/data-manager';
8
8
  import { SkyDataManagerModule } from '@skyux/data-manager';
9
9
  import * as i3 from '@skyux/i18n';
10
10
  import { getLibStringForLocale, SkyI18nModule, SKY_LIB_RESOURCES_PROVIDERS } from '@skyux/i18n';
11
11
  import * as i3$2 from '@skyux/indicators';
12
12
  import { SkyStatusIndicatorModule, SkyIconModule } from '@skyux/indicators';
13
- import * as i2$1 from '@skyux/layout';
13
+ import * as i2$4 from '@skyux/layout';
14
14
  import { SkyInlineDeleteModule } from '@skyux/layout';
15
- import * as i1$3 from '@skyux/theme';
15
+ import * as i1$2 from '@skyux/theme';
16
16
  import { SkyThemeModule } from '@skyux/theme';
17
17
  import { AgGridAngular, AgGridModule } from 'ag-grid-angular';
18
- import { Subject, fromEvent, BehaviorSubject, Subscription } from 'rxjs';
19
- import { takeUntil, filter, first } from 'rxjs/operators';
20
- import { __classPrivateFieldGet, __classPrivateFieldSet } from 'tslib';
21
- import * as i1$2 from '@angular/forms';
18
+ import { fromEvent, Subject, BehaviorSubject, Subscription } from 'rxjs';
19
+ import { first, takeUntil, filter } from 'rxjs/operators';
20
+ import { __classPrivateFieldSet, __classPrivateFieldGet } from 'tslib';
21
+ import * as i1$1 from '@angular/forms';
22
22
  import { UntypedFormGroup, UntypedFormControl, ReactiveFormsModule, FormsModule } from '@angular/forms';
23
- import * as i2$2 from '@skyux/lookup';
23
+ import { KeyCode, PopupComponent, Events, Column, RowNode } from 'ag-grid-community';
24
+ import * as i2 from '@skyux/lookup';
24
25
  import { SkyAutocompleteModule, SkyLookupModule } from '@skyux/lookup';
25
- import { KeyCode, PopupComponent, Events, RowNode } from 'ag-grid-community';
26
- import * as i2$3 from '@skyux/autonumeric';
26
+ import * as i2$1 from '@skyux/autonumeric';
27
27
  import { SkyAutonumericModule } from '@skyux/autonumeric';
28
- import * as i2$4 from '@skyux/datetime';
28
+ import * as i2$2 from '@skyux/datetime';
29
29
  import { SkyDatepickerModule } from '@skyux/datetime';
30
30
  import * as i3$1 from '@skyux/forms';
31
31
  import { SkyInputBoxModule, SkyCheckboxModule } from '@skyux/forms';
32
- import * as i1$4 from '@skyux/popovers';
32
+ import * as i1$3 from '@skyux/popovers';
33
33
  import { SkyPopoverMessageType, SkyPopoverModule } from '@skyux/popovers';
34
34
 
35
35
  class SkyAgGridAdapterService {
@@ -83,976 +83,514 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.0", ngImpor
83
83
  }]
84
84
  }], ctorParameters: function () { return [{ type: i1.SkyCoreAdapterService }]; } });
85
85
 
86
- var _SkyAgGridWrapperComponent_instances, _SkyAgGridWrapperComponent_ngUnsubscribe, _SkyAgGridWrapperComponent_moveHorizontalScroll;
87
- let idIndex = 0;
88
- class SkyAgGridWrapperComponent {
89
- constructor(adapterService, changeDetector, elementRef, document) {
90
- this.adapterService = adapterService;
91
- this.changeDetector = changeDetector;
92
- this.elementRef = elementRef;
93
- this.document = document;
94
- _SkyAgGridWrapperComponent_instances.add(this);
95
- this._viewkeeperClasses = [];
96
- _SkyAgGridWrapperComponent_ngUnsubscribe.set(this, new Subject());
97
- idIndex++;
98
- this.afterAnchorId = 'sky-ag-grid-nav-anchor-after-' + idIndex;
99
- this.beforeAnchorId = 'sky-ag-grid-nav-anchor-before-' + idIndex;
100
- this.gridId = 'sky-ag-grid-' + idIndex;
101
- }
102
- get viewkeeperClasses() {
103
- return this._viewkeeperClasses;
104
- }
105
- set viewkeeperClasses(value) {
106
- this._viewkeeperClasses = value;
107
- this.changeDetector.markForCheck();
108
- }
109
- ngAfterContentInit() {
110
- var _a;
111
- if (this.agGrid.gridOptions &&
112
- this.agGrid.gridOptions.domLayout === 'autoHeight') {
113
- if ((_a = this.agGrid.gridOptions.context) === null || _a === void 0 ? void 0 : _a.enableTopScroll) {
114
- this.viewkeeperClasses.push('.ag-header', '.ag-body-horizontal-scroll');
115
- }
116
- else {
117
- this.viewkeeperClasses.push('.ag-header');
118
- }
119
- }
120
- this.agGrid.gridReady.pipe(takeUntil(__classPrivateFieldGet(this, _SkyAgGridWrapperComponent_ngUnsubscribe, "f"))).subscribe(() => {
121
- __classPrivateFieldGet(this, _SkyAgGridWrapperComponent_instances, "m", _SkyAgGridWrapperComponent_moveHorizontalScroll).call(this);
122
- });
123
- this.agGrid.firstDataRendered
124
- .pipe(takeUntil(__classPrivateFieldGet(this, _SkyAgGridWrapperComponent_ngUnsubscribe, "f")))
125
- .subscribe(() => {
126
- __classPrivateFieldGet(this, _SkyAgGridWrapperComponent_instances, "m", _SkyAgGridWrapperComponent_moveHorizontalScroll).call(this);
127
- });
128
- this.agGrid.rowDataChanged
129
- .pipe(takeUntil(__classPrivateFieldGet(this, _SkyAgGridWrapperComponent_ngUnsubscribe, "f")))
130
- .subscribe(() => {
131
- __classPrivateFieldGet(this, _SkyAgGridWrapperComponent_instances, "m", _SkyAgGridWrapperComponent_moveHorizontalScroll).call(this);
132
- });
133
- }
134
- ngOnDestroy() {
135
- __classPrivateFieldGet(this, _SkyAgGridWrapperComponent_ngUnsubscribe, "f").next();
136
- __classPrivateFieldGet(this, _SkyAgGridWrapperComponent_ngUnsubscribe, "f").complete();
137
- }
86
+ /**
87
+ * @internal
88
+ */
89
+ function applySkyLookupPropertiesDefaults(skyLookupProperties) {
90
+ return {
91
+ addClick: skyLookupProperties.addClick || undefined,
92
+ ariaLabel: skyLookupProperties.ariaLabel || '',
93
+ autocompleteAttribute: skyLookupProperties.autocompleteAttribute || 'off',
94
+ data: skyLookupProperties.data || [],
95
+ debounceTime: skyLookupProperties.debounceTime || 0,
96
+ descriptorProperty: skyLookupProperties.descriptorProperty || 'name',
97
+ disabled: skyLookupProperties.disabled || false,
98
+ enableShowMore: skyLookupProperties.enableShowMore || false,
99
+ idProperty: skyLookupProperties.idProperty || undefined,
100
+ placeholderText: skyLookupProperties.placeholderText || '',
101
+ propertiesToSearch: skyLookupProperties.propertiesToSearch || undefined,
102
+ search: skyLookupProperties.search || undefined,
103
+ searchAsync: skyLookupProperties.searchAsync || undefined,
104
+ searchFilters: skyLookupProperties.searchFilters || [],
105
+ searchResultsLimit: skyLookupProperties.searchResultsLimit || undefined,
106
+ searchResultTemplate: skyLookupProperties.searchResultTemplate || undefined,
107
+ searchTextMinimumCharacters: skyLookupProperties.searchTextMinimumCharacters || 1,
108
+ selectMode: skyLookupProperties.selectMode || undefined,
109
+ showAddButton: skyLookupProperties.showAddButton || false,
110
+ showMoreConfig: skyLookupProperties.showMoreConfig || {},
111
+ wrapperClass: 'ag-custom-component-popup',
112
+ };
113
+ }
114
+
115
+ /** The intiial action that a cell editor should take when initialized. */
116
+ var SkyAgGridCellEditorInitialAction;
117
+ (function (SkyAgGridCellEditorInitialAction) {
118
+ /** The cell should be cleared. */
119
+ SkyAgGridCellEditorInitialAction[SkyAgGridCellEditorInitialAction["Delete"] = 0] = "Delete";
120
+ /** The cell value should be highlighted. */
121
+ SkyAgGridCellEditorInitialAction[SkyAgGridCellEditorInitialAction["Highlighted"] = 1] = "Highlighted";
122
+ /** The cell value should be replaced with the initializing value. */
123
+ SkyAgGridCellEditorInitialAction[SkyAgGridCellEditorInitialAction["Replace"] = 2] = "Replace";
124
+ /** The cell should not be modified and the cursor is placed at the end of the value. */
125
+ SkyAgGridCellEditorInitialAction[SkyAgGridCellEditorInitialAction["Untouched"] = 3] = "Untouched";
126
+ })(SkyAgGridCellEditorInitialAction || (SkyAgGridCellEditorInitialAction = {}));
127
+
128
+ class SkyAgGridCellEditorUtils {
138
129
  /**
139
- * Prevent closing a modal when focused in AG Grid.
130
+ * Gets the intiial action that a cell editor should take when initialized.
131
+ * @param params The editor's initializing parameters.
140
132
  */
141
- onKeyUpEscape($event) {
142
- $event.stopPropagation();
143
- this.agGrid.api.stopEditing(true);
144
- }
145
- onGridKeydown(event) {
146
- if (this.agGrid && !this.isInEditMode && event.key === 'Tab') {
147
- const idToFocus = event.shiftKey
148
- ? this.beforeAnchorId
149
- : this.afterAnchorId;
150
- this.adapterService.setFocusedElementById(this.elementRef.nativeElement, idToFocus);
151
- }
152
- }
153
- onAnchorFocus(event) {
154
- const gridId = this.gridId;
155
- const relatedTarget = event.relatedTarget;
156
- const previousFocusedId = relatedTarget && relatedTarget.id;
157
- const previousWasCell = relatedTarget &&
158
- !!this.adapterService.getElementOrParentWithClass(relatedTarget, 'ag-cell');
159
- if (previousFocusedId !== gridId && !previousWasCell) {
160
- const columns = this.agGrid.columnApi.getAllDisplayedColumns();
161
- const firstColumn = columns && columns[0];
162
- const rowIndex = this.agGrid.api.getFirstDisplayedRow();
163
- if (firstColumn && rowIndex >= 0) {
164
- this.agGrid.api.setFocusedCell(rowIndex, firstColumn);
133
+ static getEditorInitialAction(params) {
134
+ if (params.cellStartedEdit) {
135
+ if (params.eventKey === KeyCode.BACKSPACE ||
136
+ params.eventKey === KeyCode.DELETE) {
137
+ return SkyAgGridCellEditorInitialAction.Delete;
165
138
  }
166
- }
167
- }
168
- get isInEditMode() {
169
- /* Sanity check */
170
- /* istanbul ignore else */
171
- if (this.agGrid && this.agGrid.api) {
172
- const primaryGridEditing = this.agGrid.api.getEditingCells().length > 0;
173
- if (primaryGridEditing) {
174
- return true;
139
+ else if (params.charPress) {
140
+ return SkyAgGridCellEditorInitialAction.Replace;
175
141
  }
176
142
  else {
177
- let innerEditing = false;
178
- this.agGrid.api.forEachDetailGridInfo((detailGrid) => {
179
- if (detailGrid.api.getEditingCells().length > 0) {
180
- innerEditing = true;
181
- }
182
- });
183
- return innerEditing;
143
+ if (params.eventKey !== KeyCode.F2) {
144
+ return SkyAgGridCellEditorInitialAction.Highlighted;
145
+ }
146
+ else {
147
+ return SkyAgGridCellEditorInitialAction.Untouched;
148
+ }
184
149
  }
185
150
  }
186
151
  else {
187
- return false;
152
+ return SkyAgGridCellEditorInitialAction.Untouched;
188
153
  }
189
154
  }
190
155
  }
191
- _SkyAgGridWrapperComponent_ngUnsubscribe = new WeakMap(), _SkyAgGridWrapperComponent_instances = new WeakSet(), _SkyAgGridWrapperComponent_moveHorizontalScroll = function _SkyAgGridWrapperComponent_moveHorizontalScroll() {
192
- var _a;
193
- if (this.agGrid && this.agGrid.api) {
194
- const toTop = !!((_a = this.agGrid.gridOptions.context) === null || _a === void 0 ? void 0 : _a.enableTopScroll);
195
- const root = this.elementRef.nativeElement.querySelector('.ag-root');
196
- const header = root.querySelector('.ag-header');
197
- const floatingBottom = root.querySelector('.ag-floating-bottom');
198
- const scrollbar = root.querySelector('.ag-body-horizontal-scroll');
199
- if (header && floatingBottom && scrollbar) {
200
- if (scrollbar.style.height !==
201
- scrollbar.style.getPropertyValue('--sky-ag-body-horizontal-scroll-width')) {
202
- scrollbar.style.setProperty('--sky-ag-body-horizontal-scroll-width', scrollbar.style.height);
203
- }
204
- const isTop = !!root.children[1].matches('.ag-body-horizontal-scroll');
205
- if (toTop && !isTop) {
206
- const fragment = this.document.createDocumentFragment();
207
- fragment.appendChild(scrollbar);
208
- header.after(fragment);
209
- }
210
- else if (!toTop && isTop) {
211
- const fragment = this.document.createDocumentFragment();
212
- fragment.appendChild(scrollbar);
213
- floatingBottom.after(fragment);
214
- }
156
+
157
+ var _SkyAgGridCellEditorAutocompleteComponent_triggerType;
158
+ /**
159
+ * @internal
160
+ */
161
+ class SkyAgGridCellEditorAutocompleteComponent {
162
+ constructor() {
163
+ this.editorForm = new UntypedFormGroup({
164
+ selection: new UntypedFormControl(),
165
+ });
166
+ this.skyComponentProperties = {};
167
+ _SkyAgGridCellEditorAutocompleteComponent_triggerType.set(this, void 0);
168
+ }
169
+ agInit(params) {
170
+ this.params = params;
171
+ __classPrivateFieldSet(this, _SkyAgGridCellEditorAutocompleteComponent_triggerType, SkyAgGridCellEditorUtils.getEditorInitialAction(params), "f");
172
+ const control = this.editorForm.get('selection');
173
+ switch (__classPrivateFieldGet(this, _SkyAgGridCellEditorAutocompleteComponent_triggerType, "f")) {
174
+ case SkyAgGridCellEditorInitialAction.Delete:
175
+ control.setValue(undefined);
176
+ break;
177
+ case SkyAgGridCellEditorInitialAction.Replace:
178
+ case SkyAgGridCellEditorInitialAction.Highlighted:
179
+ case SkyAgGridCellEditorInitialAction.Untouched:
180
+ default:
181
+ control.setValue(params.value);
182
+ break;
215
183
  }
184
+ this.columnHeader = this.params.colDef && this.params.colDef.headerName;
185
+ this.rowNumber = this.params.rowIndex + 1;
186
+ this.skyComponentProperties = this.params.skyComponentProperties || {};
216
187
  }
217
- };
218
- SkyAgGridWrapperComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridWrapperComponent, deps: [{ token: SkyAgGridAdapterService }, { token: i0.ChangeDetectorRef }, { token: i0.ElementRef }, { token: DOCUMENT }], target: i0.ɵɵFactoryTarget.Component });
219
- SkyAgGridWrapperComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.2.0", type: SkyAgGridWrapperComponent, selector: "sky-ag-grid-wrapper", queries: [{ propertyName: "agGrid", first: true, predicate: AgGridAngular, descendants: true, static: true }], ngImport: i0, template: "<span\n class=\"nav-anchor\"\n tabindex=\"0\"\n [id]=\"beforeAnchorId\"\n (focusin)=\"onAnchorFocus($event)\"\n>\n</span>\n<div\n class=\"sky-ag-grid\"\n [ngClass]=\"{\n 'sky-ag-grid-top-scrollbar':\n agGrid?.gridOptions?.context &&\n agGrid?.gridOptions?.context['enableTopScroll']\n }\"\n tabindex=\"0\"\n [id]=\"gridId\"\n [skyViewkeeper]=\"viewkeeperClasses\"\n (keydown)=\"onGridKeydown($event)\"\n (keyup.escape)=\"onKeyUpEscape($event)\"\n>\n <ng-content></ng-content>\n</div>\n<span\n tabindex=\"0\"\n class=\"nav-anchor\"\n [id]=\"afterAnchorId\"\n (focusin)=\"onAnchorFocus($event)\"\n>\n</span>\n", dependencies: [{ kind: "directive", type: i2.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i1.λ3, selector: "[skyViewkeeper]", inputs: ["skyViewkeeper"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
220
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridWrapperComponent, decorators: [{
188
+ afterGuiAttached() {
189
+ this.input.nativeElement.focus();
190
+ if (__classPrivateFieldGet(this, _SkyAgGridCellEditorAutocompleteComponent_triggerType, "f") === SkyAgGridCellEditorInitialAction.Replace) {
191
+ this.input.nativeElement.select();
192
+ this.input.nativeElement.setRangeText(this.params.charPress);
193
+ // Ensure the cursor is at the end of the text.
194
+ this.input.nativeElement.setSelectionRange(this.params.charPress.length, this.params.charPress.length);
195
+ this.input.nativeElement.dispatchEvent(new Event('input'));
196
+ }
197
+ if (__classPrivateFieldGet(this, _SkyAgGridCellEditorAutocompleteComponent_triggerType, "f") === SkyAgGridCellEditorInitialAction.Highlighted) {
198
+ this.input.nativeElement.select();
199
+ }
200
+ }
201
+ getValue() {
202
+ const val = this.editorForm.get('selection').value;
203
+ return val !== undefined && val !== null ? val : undefined;
204
+ }
205
+ }
206
+ _SkyAgGridCellEditorAutocompleteComponent_triggerType = new WeakMap();
207
+ SkyAgGridCellEditorAutocompleteComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellEditorAutocompleteComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
208
+ SkyAgGridCellEditorAutocompleteComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.2.0", type: SkyAgGridCellEditorAutocompleteComponent, selector: "sky-ag-grid-cell-editor-autocomplete", viewQueries: [{ propertyName: "input", first: true, predicate: ["skyCellEditorAutocomplete"], descendants: true, read: ElementRef }], ngImport: i0, template: "<div class=\"sky-ag-grid-cell-editor-autocomplete\" [formGroup]=\"editorForm\">\n <sky-autocomplete\n [data]=\"skyComponentProperties.data\"\n [debounceTime]=\"skyComponentProperties.debounceTime\"\n [descriptorProperty]=\"skyComponentProperties.descriptorProperty\"\n [propertiesToSearch]=\"skyComponentProperties.propertiesToSearch\"\n [search]=\"skyComponentProperties.search\"\n [searchFilters]=\"skyComponentProperties.searchFilters\"\n [searchResultsLimit]=\"skyComponentProperties.searchResultsLimit\"\n [searchResultTemplate]=\"skyComponentProperties.searchResultTemplate\"\n [searchTextMinimumCharacters]=\"\n skyComponentProperties.searchTextMinimumCharacters\n \"\n (selectionChange)=\"\n skyComponentProperties.selectionChange &&\n skyComponentProperties.selectionChange($event)\n \"\n >\n <input\n formControlName=\"selection\"\n skyAutocomplete\n #skyCellEditorAutocomplete\n type=\"text\"\n [attr.aria-label]=\"\n 'sky_ag_grid_cell_editor_autocomplete_aria_label'\n | skyLibResources: columnHeader:rowNumber\n \"\n />\n </sky-autocomplete>\n</div>\n", styles: ["sky-autocomplete input{border:none;box-shadow:none}\n"], dependencies: [{ kind: "directive", type: i1$1.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i1$1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1$1.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i1$1.FormGroupDirective, selector: "[formGroup]", inputs: ["formGroup"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "directive", type: i1$1.FormControlName, selector: "[formControlName]", inputs: ["formControlName", "disabled", "ngModel"], outputs: ["ngModelChange"] }, { kind: "component", type: i2.λ2, selector: "sky-autocomplete", inputs: ["ariaLabelledBy", "data", "debounceTime", "descriptorProperty", "enableShowMore", "messageStream", "wrapperClass", "propertiesToSearch", "search", "searchResultTemplate", "searchTextMinimumCharacters", "searchFilters", "searchResultsLimit", "showAddButton", "noResultsFoundText", "searchAsyncDisabled"], outputs: ["addClick", "showMoreClick", "selectionChange", "searchAsync"] }, { kind: "directive", type: i2.λ1, selector: "input[skyAutocomplete], textarea[skyAutocomplete]", inputs: ["autocompleteAttribute", "disabled"] }, { kind: "pipe", type: i3.SkyLibResourcesPipe, name: "skyLibResources" }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
209
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellEditorAutocompleteComponent, decorators: [{
221
210
  type: Component,
222
- args: [{ selector: 'sky-ag-grid-wrapper', changeDetection: ChangeDetectionStrategy.OnPush, template: "<span\n class=\"nav-anchor\"\n tabindex=\"0\"\n [id]=\"beforeAnchorId\"\n (focusin)=\"onAnchorFocus($event)\"\n>\n</span>\n<div\n class=\"sky-ag-grid\"\n [ngClass]=\"{\n 'sky-ag-grid-top-scrollbar':\n agGrid?.gridOptions?.context &&\n agGrid?.gridOptions?.context['enableTopScroll']\n }\"\n tabindex=\"0\"\n [id]=\"gridId\"\n [skyViewkeeper]=\"viewkeeperClasses\"\n (keydown)=\"onGridKeydown($event)\"\n (keyup.escape)=\"onKeyUpEscape($event)\"\n>\n <ng-content></ng-content>\n</div>\n<span\n tabindex=\"0\"\n class=\"nav-anchor\"\n [id]=\"afterAnchorId\"\n (focusin)=\"onAnchorFocus($event)\"\n>\n</span>\n" }]
223
- }], ctorParameters: function () {
224
- return [{ type: SkyAgGridAdapterService }, { type: i0.ChangeDetectorRef }, { type: i0.ElementRef }, { type: Document, decorators: [{
225
- type: Inject,
226
- args: [DOCUMENT]
227
- }] }];
228
- }, propDecorators: { agGrid: [{
229
- type: ContentChild,
230
- args: [AgGridAngular, {
231
- static: true,
232
- }]
211
+ args: [{ selector: 'sky-ag-grid-cell-editor-autocomplete', changeDetection: ChangeDetectionStrategy.OnPush, template: "<div class=\"sky-ag-grid-cell-editor-autocomplete\" [formGroup]=\"editorForm\">\n <sky-autocomplete\n [data]=\"skyComponentProperties.data\"\n [debounceTime]=\"skyComponentProperties.debounceTime\"\n [descriptorProperty]=\"skyComponentProperties.descriptorProperty\"\n [propertiesToSearch]=\"skyComponentProperties.propertiesToSearch\"\n [search]=\"skyComponentProperties.search\"\n [searchFilters]=\"skyComponentProperties.searchFilters\"\n [searchResultsLimit]=\"skyComponentProperties.searchResultsLimit\"\n [searchResultTemplate]=\"skyComponentProperties.searchResultTemplate\"\n [searchTextMinimumCharacters]=\"\n skyComponentProperties.searchTextMinimumCharacters\n \"\n (selectionChange)=\"\n skyComponentProperties.selectionChange &&\n skyComponentProperties.selectionChange($event)\n \"\n >\n <input\n formControlName=\"selection\"\n skyAutocomplete\n #skyCellEditorAutocomplete\n type=\"text\"\n [attr.aria-label]=\"\n 'sky_ag_grid_cell_editor_autocomplete_aria_label'\n | skyLibResources: columnHeader:rowNumber\n \"\n />\n </sky-autocomplete>\n</div>\n", styles: ["sky-autocomplete input{border:none;box-shadow:none}\n"] }]
212
+ }], propDecorators: { input: [{
213
+ type: ViewChild,
214
+ args: ['skyCellEditorAutocomplete', { read: ElementRef }]
233
215
  }] } });
234
216
 
217
+ var _SkyAgGridCellEditorCurrencyComponent_triggerType;
235
218
  /**
236
219
  * @internal
237
220
  */
238
- class SkyAgGridDataManagerAdapterDirective {
239
- constructor(changeDetector, dataManagerSvc) {
221
+ class SkyAgGridCellEditorCurrencyComponent {
222
+ constructor(changeDetector) {
240
223
  this.changeDetector = changeDetector;
241
- this.dataManagerSvc = dataManagerSvc;
242
- this.ngUnsubscribe = new Subject();
224
+ this.skyComponentProperties = {};
225
+ this.editorForm = new UntypedFormGroup({
226
+ currency: new UntypedFormControl(),
227
+ });
228
+ _SkyAgGridCellEditorCurrencyComponent_triggerType.set(this, void 0);
243
229
  }
244
- ngAfterContentInit() {
245
- this.dataManagerSvc.setViewkeeperClasses(this.viewId, ['.ag-header']);
246
- this.viewConfig = this.dataManagerSvc.getViewById(this.viewId);
247
- this.checkForAgGrid();
248
- this.checkForSkyAgGridWrapper();
249
- this.agGridList.changes
250
- .pipe(takeUntil(this.ngUnsubscribe))
251
- .subscribe(() => this.checkForAgGrid());
252
- this.skyAgGridWrapperList.changes
253
- .pipe(takeUntil(this.ngUnsubscribe))
254
- .subscribe(() => this.checkForSkyAgGridWrapper());
255
- }
256
- ngOnDestroy() {
257
- this.ngUnsubscribe.next();
258
- this.ngUnsubscribe.complete();
259
- }
260
- checkForAgGrid() {
261
- const agGridCount = this.agGridList.length;
262
- /* istanbul ignore else */
263
- if (agGridCount === 0) {
264
- this.unregisterAgGrid();
265
- }
266
- else if (this.agGridList.first !== this.currentAgGrid) {
267
- this.registerAgGrid();
268
- }
269
- if (agGridCount > 1) {
270
- console.warn('More than one ag-grid child component was found. Using the first ag-Grid.');
271
- }
272
- }
273
- checkForSkyAgGridWrapper() {
274
- const skyAgGridWrapperCount = this.skyAgGridWrapperList.length;
275
- /* istanbul ignore else */
276
- if (skyAgGridWrapperCount === 0) {
277
- this.unregisterSkyAgGridWrapper();
278
- }
279
- else if (this.skyAgGridWrapperList.first !== this.currentSkyAgGridWrapper) {
280
- this.registerSkyAgGridWrapper();
281
- }
282
- if (skyAgGridWrapperCount > 1) {
283
- console.warn('More than one ag-grid child component was found. Using the first ag-Grid.');
284
- }
230
+ /**
231
+ * agInit is called by agGrid once after the editor is created and provides the editor with the information it needs.
232
+ * @param params The cell editor params that include data about the cell, column, row, and grid.
233
+ */
234
+ agInit(params) {
235
+ this.params = params;
236
+ this.columnHeader = this.params.colDef.headerName;
237
+ this.rowNumber = this.params.rowIndex + 1;
238
+ this.columnWidth = this.params.column.getActualWidth();
239
+ this.rowHeightWithoutBorders =
240
+ this.params.node && this.params.node.rowHeight - 4;
241
+ this.skyComponentProperties = this.params.skyComponentProperties || {
242
+ decimalPlaces: 2,
243
+ currencySymbol: '$',
244
+ };
285
245
  }
286
- unregisterAgGrid() {
287
- this.currentAgGrid = undefined;
288
- /* istanbul ignore if */
289
- if (this.dataStateSub) {
290
- this.dataStateSub.unsubscribe();
246
+ /**
247
+ * afterGuiAttached is called by agGrid after the editor is rendered in the DOM. Once it is attached the editor is ready to be focused on.
248
+ */
249
+ afterGuiAttached() {
250
+ this.input.nativeElement.focus();
251
+ // This setup is in `afterGuiAttached` due to the lifecycle of autonumeric which will highlight the initial value if it is in place when it renders.
252
+ // Since we don't want that, we set the initial value after autonumeric initializes.
253
+ __classPrivateFieldSet(this, _SkyAgGridCellEditorCurrencyComponent_triggerType, SkyAgGridCellEditorUtils.getEditorInitialAction(this.params), "f");
254
+ const control = this.editorForm.get('currency');
255
+ switch (__classPrivateFieldGet(this, _SkyAgGridCellEditorCurrencyComponent_triggerType, "f")) {
256
+ case SkyAgGridCellEditorInitialAction.Delete:
257
+ control.setValue(undefined);
258
+ break;
259
+ case SkyAgGridCellEditorInitialAction.Replace:
260
+ control.setValue(parseFloat(this.params.charPress) || undefined);
261
+ break;
262
+ case SkyAgGridCellEditorInitialAction.Highlighted:
263
+ case SkyAgGridCellEditorInitialAction.Untouched:
264
+ default:
265
+ control.setValue(parseFloat(this.params.value));
266
+ break;
291
267
  }
292
- }
293
- unregisterSkyAgGridWrapper() {
294
- this.currentSkyAgGridWrapper = undefined;
295
- }
296
- registerSkyAgGridWrapper() {
297
- this.unregisterSkyAgGridWrapper();
298
- this.currentSkyAgGridWrapper = this.skyAgGridWrapperList.first;
268
+ this.changeDetector.markForCheck();
269
+ // Without the `setTimeout` there is inconsistent behavior with the highlighting when no initial value is present.
299
270
  setTimeout(() => {
300
- if (this.currentSkyAgGridWrapper) {
301
- this.currentSkyAgGridWrapper.viewkeeperClasses = [];
302
- }
303
- });
304
- }
305
- registerAgGrid() {
306
- this.unregisterAgGrid();
307
- const agGrid = this.agGridList.first;
308
- this.currentAgGrid = agGrid;
309
- agGrid.gridReady.pipe(takeUntil(this.ngUnsubscribe)).subscribe(() => {
310
- var _a;
311
- this.viewConfig.onSelectAllClick = this.selectAll.bind(this);
312
- this.viewConfig.onClearAllClick = this.clearAll.bind(this);
313
- this.dataManagerSvc.updateViewConfig(this.viewConfig);
314
- this.dataStateSub = this.dataManagerSvc
315
- .getDataStateUpdates(this.viewConfig.id)
316
- .pipe(takeUntil(this.ngUnsubscribe))
317
- .subscribe((dataState) => {
318
- this.currentDataState = dataState;
319
- this.displayColumns(dataState);
320
- });
321
- if ((_a = agGrid.gridOptions.context) === null || _a === void 0 ? void 0 : _a.enableTopScroll) {
322
- this.dataManagerSvc.setViewkeeperClasses(this.viewId, [
323
- '.ag-header',
324
- '.ag-body-horizontal-scroll',
325
- ]);
326
- }
327
- agGrid.api.sizeColumnsToFit();
328
- });
329
- agGrid.columnMoved
330
- .pipe(takeUntil(this.ngUnsubscribe), filter((event) => ![
331
- 'gridInitializing',
332
- 'uiColumnResized',
333
- 'uiColumnDragged',
334
- 'api',
335
- ].includes(event.source)))
336
- .subscribe((value) => {
337
- this.updateColumnsInCurrentDataState(value.columnApi);
338
- });
339
- agGrid.dragStopped
340
- .pipe(takeUntil(this.ngUnsubscribe))
341
- .subscribe((value) => {
342
- this.updateColumnsInCurrentDataState(value.columnApi);
343
- });
344
- agGrid.rowSelected
345
- .pipe(takeUntil(this.ngUnsubscribe))
346
- .subscribe((event) => {
347
- const row = event.node;
348
- const selectedIds = this.currentDataState.selectedIds || [];
349
- const rowIndex = selectedIds.indexOf(row.data.id);
350
- if (row.isSelected() && rowIndex === -1) {
351
- selectedIds.push(row.data.id);
352
- }
353
- else if (!row.isSelected() && rowIndex !== -1) {
354
- selectedIds.splice(rowIndex, 1);
355
- }
356
- this.currentDataState.selectedIds = selectedIds;
357
- this.dataManagerSvc.updateDataState(this.currentDataState, this.viewConfig.id);
358
- this.changeDetector.markForCheck();
359
- });
360
- agGrid.sortChanged.pipe(takeUntil(this.ngUnsubscribe)).subscribe(() => {
361
- const gridColumnStates = agGrid.columnApi.getColumnState();
362
- let sortOption;
363
- /* istanbul ignore else */
364
- if (gridColumnStates.length) {
365
- const activeSortColumnState = gridColumnStates.find((aGridColumnState) => aGridColumnState.sortIndex === 0);
366
- const dataManagerConfig = this.dataManagerSvc.getCurrentDataManagerConfig();
367
- /* istanbul ignore else */
368
- if (dataManagerConfig.sortOptions && activeSortColumnState) {
369
- sortOption = dataManagerConfig.sortOptions.find((option) => {
370
- return (option.propertyName === activeSortColumnState.colId &&
371
- option.descending === (activeSortColumnState.sort === 'desc'));
372
- });
373
- }
374
- else {
375
- sortOption = undefined;
376
- }
271
+ if (__classPrivateFieldGet(this, _SkyAgGridCellEditorCurrencyComponent_triggerType, "f") === SkyAgGridCellEditorInitialAction.Highlighted) {
272
+ this.input.nativeElement.select();
377
273
  }
378
- this.currentDataState.activeSortOption = sortOption;
379
- this.dataManagerSvc.updateDataState(this.currentDataState, this.viewConfig.id);
380
- });
381
- }
382
- updateColumnsInCurrentDataState(columnApi) {
383
- const columnOrder = this.getColumnOrder(columnApi);
384
- const viewState = this.currentDataState.getViewStateById(this.viewConfig.id);
385
- if (viewState.displayedColumnIds.length !== columnOrder.length ||
386
- viewState.displayedColumnIds.some((col, i) => col !== columnOrder[i])) {
387
- viewState.displayedColumnIds = columnOrder;
388
- this.dataManagerSvc.updateDataState(this.currentDataState.addOrUpdateView(this.viewConfig.id, viewState), this.viewConfig.id);
389
- }
390
- }
391
- getColumnOrder(columnApi) {
392
- return columnApi
393
- .getColumnState()
394
- .filter((state) => !state.hide)
395
- .map((state) => state.colId);
396
- }
397
- displayColumns(dataState) {
398
- const agGrid = this.currentAgGrid;
399
- const viewState = dataState.getViewStateById(this.viewConfig.id);
400
- let displayedColumnIds = [];
401
- /*istanbul ignore else*/
402
- if (viewState.displayedColumnIds) {
403
- displayedColumnIds = viewState.displayedColumnIds;
404
- }
405
- const columnOrder = this.getColumnOrder(agGrid.columnApi);
406
- if (displayedColumnIds.length !== columnOrder.length ||
407
- displayedColumnIds.some((col, i) => col !== columnOrder[i])) {
408
- const hideColumns = agGrid.columnApi
409
- .getColumnState()
410
- .map((col) => col.colId)
411
- .filter((colId) => !displayedColumnIds.includes(colId));
412
- agGrid.columnApi.setColumnsVisible(hideColumns, false);
413
- agGrid.columnApi.setColumnsVisible(displayedColumnIds, true);
414
- agGrid.columnApi.moveColumns(displayedColumnIds, 0);
415
- }
274
+ }, 100);
416
275
  }
417
- selectAll() {
418
- const agGrid = this.agGridList.first;
419
- agGrid.api.selectAll();
276
+ /**
277
+ * getValue is called by agGrid when editing is stopped to get the new value of the cell.
278
+ */
279
+ getValue() {
280
+ const val = this.editorForm.get('currency').value;
281
+ return val !== undefined && val !== null ? val : undefined;
420
282
  }
421
- clearAll() {
422
- const agGrid = this.agGridList.first;
423
- agGrid.api.deselectAll();
283
+ /**
284
+ * The autoNumeric library's event handler suppresses the escape key event. This additional handler re-enables AG Grid's default functionality.
285
+ */
286
+ onPressEscape() {
287
+ this.params.api.stopEditing(true);
288
+ this.params.api.setFocusedCell(this.params.rowIndex, this.params.column);
424
289
  }
425
290
  }
426
- SkyAgGridDataManagerAdapterDirective.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridDataManagerAdapterDirective, deps: [{ token: i0.ChangeDetectorRef }, { token: i1$1.SkyDataManagerService }], target: i0.ɵɵFactoryTarget.Directive });
427
- SkyAgGridDataManagerAdapterDirective.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "14.2.0", type: SkyAgGridDataManagerAdapterDirective, selector: "[skyAgGridDataManagerAdapter]", inputs: { viewId: "viewId" }, queries: [{ propertyName: "agGridList", predicate: AgGridAngular, descendants: true }, { propertyName: "skyAgGridWrapperList", predicate: SkyAgGridWrapperComponent, descendants: true }], ngImport: i0 });
428
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridDataManagerAdapterDirective, decorators: [{
429
- type: Directive,
430
- args: [{
431
- selector: '[skyAgGridDataManagerAdapter]',
432
- }]
433
- }], ctorParameters: function () { return [{ type: i0.ChangeDetectorRef }, { type: i1$1.SkyDataManagerService }]; }, propDecorators: { viewId: [{
434
- type: Input
435
- }], agGridList: [{
436
- type: ContentChildren,
437
- args: [AgGridAngular, { descendants: true }]
438
- }], skyAgGridWrapperList: [{
439
- type: ContentChildren,
440
- args: [SkyAgGridWrapperComponent, { descendants: true }]
291
+ _SkyAgGridCellEditorCurrencyComponent_triggerType = new WeakMap();
292
+ SkyAgGridCellEditorCurrencyComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellEditorCurrencyComponent, deps: [{ token: i0.ChangeDetectorRef }], target: i0.ɵɵFactoryTarget.Component });
293
+ SkyAgGridCellEditorCurrencyComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.2.0", type: SkyAgGridCellEditorCurrencyComponent, selector: "sky-ag-grid-cell-editor-currency", viewQueries: [{ propertyName: "input", first: true, predicate: ["skyCellEditorCurrency"], descendants: true, read: ElementRef }], ngImport: i0, template: "<ng-container [formGroup]=\"editorForm\">\n <input\n formControlName=\"currency\"\n type=\"text\"\n [attr.aria-label]=\"\n 'sky_ag_grid_cell_editor_currency_aria_label'\n | skyLibResources: columnHeader:rowNumber\n \"\n [style.width.px]=\"columnWidth\"\n [style.height.px]=\"rowHeightWithoutBorders\"\n [skyAutonumeric]=\"skyComponentProperties\"\n [skyAutonumericFormChangesUnformatted]=\"!!params?.charPress\"\n (keyup.escape)=\"onPressEscape()\"\n #skyCellEditorCurrency\n />\n</ng-container>\n", styles: ["input{border:none;padding-left:11px}\n"], dependencies: [{ kind: "directive", type: i1$1.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i1$1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1$1.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i1$1.FormGroupDirective, selector: "[formGroup]", inputs: ["formGroup"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "directive", type: i1$1.FormControlName, selector: "[formControlName]", inputs: ["formControlName", "disabled", "ngModel"], outputs: ["ngModelChange"] }, { kind: "directive", type: i2$1.λ1, selector: "input[skyAutonumeric]", inputs: ["skyAutonumeric", "skyAutonumericFormChangesUnformatted"] }, { kind: "pipe", type: i3.SkyLibResourcesPipe, name: "skyLibResources" }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
294
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellEditorCurrencyComponent, decorators: [{
295
+ type: Component,
296
+ args: [{ selector: 'sky-ag-grid-cell-editor-currency', changeDetection: ChangeDetectionStrategy.OnPush, template: "<ng-container [formGroup]=\"editorForm\">\n <input\n formControlName=\"currency\"\n type=\"text\"\n [attr.aria-label]=\"\n 'sky_ag_grid_cell_editor_currency_aria_label'\n | skyLibResources: columnHeader:rowNumber\n \"\n [style.width.px]=\"columnWidth\"\n [style.height.px]=\"rowHeightWithoutBorders\"\n [skyAutonumeric]=\"skyComponentProperties\"\n [skyAutonumericFormChangesUnformatted]=\"!!params?.charPress\"\n (keyup.escape)=\"onPressEscape()\"\n #skyCellEditorCurrency\n />\n</ng-container>\n", styles: ["input{border:none;padding-left:11px}\n"] }]
297
+ }], ctorParameters: function () { return [{ type: i0.ChangeDetectorRef }]; }, propDecorators: { input: [{
298
+ type: ViewChild,
299
+ args: ['skyCellEditorCurrency', { read: ElementRef }]
441
300
  }] } });
442
301
 
302
+ var _SkyAgGridCellEditorDatepickerComponent_triggerType;
443
303
  /**
444
- * Component for rendering the inline delete template in the overlay.
445
304
  * @internal
446
305
  */
447
- class SkyAgGridRowDeleteComponent {
448
- }
449
- SkyAgGridRowDeleteComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridRowDeleteComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
450
- SkyAgGridRowDeleteComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.2.0", type: SkyAgGridRowDeleteComponent, selector: "ng-component", viewQueries: [{ propertyName: "inlineDeleteTemplateRef", first: true, predicate: ["inlineDeleteTemplateRef"], descendants: true, read: TemplateRef }, { propertyName: "inlineDeleteRefs", predicate: ["inlineDeleteRef"], descendants: true }], ngImport: i0, template: `
451
- <ng-template
452
- let-row
453
- let-tableWidth="tableWidth()"
454
- let-getRowDeleteItem="getRowDeleteItem"
455
- let-cancelRowDelete="cancelRowDelete"
456
- let-confirmRowDelete="confirmRowDelete"
457
- #inlineDeleteTemplateRef
458
- >
459
- <div
460
- class="sky-ag-grid-row-delete"
461
- [id]="'row-delete-ref-' + row.id"
462
- [ngStyle]="{
463
- height: row.rowHeight + 'px',
464
- position: 'fixed',
465
- width: tableWidth + 'px'
466
- }"
467
- #inlineDeleteRef
468
- >
469
- <sky-inline-delete
470
- [pending]="getRowDeleteItem(row).pending"
471
- (cancelTriggered)="cancelRowDelete(row)"
472
- (deleteTriggered)="confirmRowDelete(row)"
473
- ></sky-inline-delete>
474
- </div>
475
- </ng-template>
476
- `, isInline: true, dependencies: [{ kind: "directive", type: i2.NgStyle, selector: "[ngStyle]", inputs: ["ngStyle"] }, { kind: "component", type: i2$1.λ8, selector: "sky-inline-delete", inputs: ["pending"], outputs: ["cancelTriggered", "deleteTriggered"] }] });
477
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridRowDeleteComponent, decorators: [{
478
- type: Component,
479
- args: [{
480
- template: `
481
- <ng-template
482
- let-row
483
- let-tableWidth="tableWidth()"
484
- let-getRowDeleteItem="getRowDeleteItem"
485
- let-cancelRowDelete="cancelRowDelete"
486
- let-confirmRowDelete="confirmRowDelete"
487
- #inlineDeleteTemplateRef
488
- >
489
- <div
490
- class="sky-ag-grid-row-delete"
491
- [id]="'row-delete-ref-' + row.id"
492
- [ngStyle]="{
493
- height: row.rowHeight + 'px',
494
- position: 'fixed',
495
- width: tableWidth + 'px'
496
- }"
497
- #inlineDeleteRef
498
- >
499
- <sky-inline-delete
500
- [pending]="getRowDeleteItem(row).pending"
501
- (cancelTriggered)="cancelRowDelete(row)"
502
- (deleteTriggered)="confirmRowDelete(row)"
503
- ></sky-inline-delete>
504
- </div>
505
- </ng-template>
506
- `,
507
- }]
508
- }], propDecorators: { inlineDeleteRefs: [{
509
- type: ViewChildren,
510
- args: ['inlineDeleteRef']
511
- }], inlineDeleteTemplateRef: [{
512
- type: ViewChild,
513
- args: ['inlineDeleteTemplateRef', { read: TemplateRef }]
514
- }] } });
515
-
516
- class SkyAgGridRowDeleteDirective {
517
- constructor(affixService, changeDetector, elementRef, overlayService, viewContainerRef) {
518
- this.affixService = affixService;
306
+ class SkyAgGridCellEditorDatepickerComponent extends PopupComponent {
307
+ constructor(changeDetector, themeSvc) {
308
+ super();
519
309
  this.changeDetector = changeDetector;
520
- this.elementRef = elementRef;
521
- this.overlayService = overlayService;
522
- this.viewContainerRef = viewContainerRef;
523
- /**
524
- * Emits a `SkyAgGridRowDeleteCancelArgs` object when a row's inline delete is cancelled.
525
- */
526
- this.rowDeleteCancel = new EventEmitter();
527
- /**
528
- * Emits a `SkyAgGridRowDeleteConfirmArgs` object when a row's inline delete is confirmed.
529
- */
530
- this.rowDeleteConfirm = new EventEmitter();
531
- /**
532
- * Emits when the list of ids of the data in the rows where inline deletes are shown changes.
533
- */
534
- this.rowDeleteIdsChange = new EventEmitter();
535
- this.rowDeleteConfigs = [];
536
- this.ngUnsubscribe = new Subject();
537
- this.rowDeleteContents = {};
310
+ this.themeSvc = themeSvc;
311
+ this.editorForm = new UntypedFormGroup({
312
+ date: new UntypedFormControl(),
313
+ });
314
+ this.skyComponentProperties = {};
315
+ _SkyAgGridCellEditorDatepickerComponent_triggerType.set(this, void 0);
538
316
  }
539
317
  /**
540
- * Specifies the ids of the data in the rows on which inline delete's should be shown.
318
+ * agInit is called by agGrid once after the editor is created and provides the editor with the information it needs.
319
+ * @param params The cell editor params that include data about the cell, column, row, and grid.
541
320
  */
542
- set rowDeleteIds(value) {
543
- this._rowDeleteIds = value;
544
- if (!value) {
545
- for (const config of this.rowDeleteConfigs) {
546
- this.destroyRowDelete(config.id);
547
- }
548
- this.changeDetector.markForCheck();
549
- return;
321
+ agInit(params) {
322
+ var _a, _b;
323
+ this.params = params;
324
+ __classPrivateFieldSet(this, _SkyAgGridCellEditorDatepickerComponent_triggerType, SkyAgGridCellEditorUtils.getEditorInitialAction(params), "f");
325
+ const control = this.editorForm.get('date');
326
+ switch (__classPrivateFieldGet(this, _SkyAgGridCellEditorDatepickerComponent_triggerType, "f")) {
327
+ case SkyAgGridCellEditorInitialAction.Delete:
328
+ control.setValue(undefined);
329
+ break;
330
+ case SkyAgGridCellEditorInitialAction.Replace:
331
+ control.setValue(params.charPress);
332
+ break;
333
+ case SkyAgGridCellEditorInitialAction.Highlighted:
334
+ case SkyAgGridCellEditorInitialAction.Untouched:
335
+ default:
336
+ control.setValue(params.value);
337
+ break;
550
338
  }
551
- for (const id of value) {
552
- const existingConfig = this.rowDeleteConfigs.find((config) => config.id === id);
553
- if (existingConfig) {
554
- existingConfig.pending = false;
339
+ if ((_a = this.params.skyComponentProperties) === null || _a === void 0 ? void 0 : _a.disabled) {
340
+ control.disable();
341
+ }
342
+ this.changeDetector.markForCheck();
343
+ this.skyComponentProperties = this.params.skyComponentProperties || {};
344
+ this.columnWidth = this.params.column.getActualWidth();
345
+ this.columnWidthWithoutBorders = this.columnWidth - 2;
346
+ this.rowHeightWithoutBorders =
347
+ this.params.node && this.params.node.rowHeight - 3;
348
+ (_b = this.themeSvc) === null || _b === void 0 ? void 0 : _b.settingsChange.subscribe((themeSettings) => {
349
+ if (themeSettings.currentSettings.theme.name === 'modern') {
350
+ this.columnWidthWithoutBorders = this.columnWidth;
351
+ this.rowHeightWithoutBorders =
352
+ this.params.node && this.params.node.rowHeight;
555
353
  }
556
354
  else {
557
- this.rowDeleteConfigs.push({
558
- id: id,
559
- pending: false,
560
- });
561
- const overlay = this.overlayService.create({
562
- enableScroll: true,
563
- showBackdrop: false,
564
- closeOnNavigation: true,
565
- enableClose: false,
566
- enablePointerEvents: true,
567
- });
568
- overlay.attachTemplate(this.rowDeleteComponent.inlineDeleteTemplateRef, {
569
- $implicit: this.agGrid.api.getRowNode(id),
570
- tableWidth: () => {
571
- return this.tableWidth;
572
- },
573
- getRowDeleteItem: (row) => this.getRowDeleteItem(row),
574
- cancelRowDelete: (row) => this.cancelRowDelete(row),
575
- confirmRowDelete: (row) => this.confirmRowDelete(row),
576
- });
577
- /**
578
- * We are manually setting the z-index here because overlays will always be on top of
579
- * the omnibar. This manual setting is 2 less than the omnibar's z-index of 1000 and one less than
580
- * the header row's viewkeeper which is 999. We discussed changing the overlay service to allow for this
581
- * but decided against that change at this time due to its niche nature.
582
- */
583
- overlay.componentRef.instance.zIndex = '998';
584
- setTimeout(() => {
585
- const inlineDeleteRef = this.rowDeleteComponent.inlineDeleteRefs
586
- .toArray()
587
- .find((elRef) => {
588
- return elRef.nativeElement.id === 'row-delete-ref-' + id;
589
- });
590
- const affixer = this.affixService.createAffixer(inlineDeleteRef);
591
- this.affixToRow(affixer, id);
592
- this.rowDeleteContents[id] = {
593
- affixer: affixer,
594
- overlay: overlay,
595
- };
596
- });
355
+ this.columnWidthWithoutBorders = this.columnWidth - 2;
356
+ this.rowHeightWithoutBorders =
357
+ this.params.node && this.params.node.rowHeight - 3;
597
358
  }
359
+ });
360
+ }
361
+ /**
362
+ * afterGuiAttached is called by agGrid after the editor is rendered in the DOM. Once it is attached the editor is ready to be focused on.
363
+ */
364
+ afterGuiAttached() {
365
+ const datepickerInputEl = this.datepickerInput
366
+ .nativeElement;
367
+ datepickerInputEl.focus();
368
+ // Programatically set the value of in the input; however, do not do this via the form control so that the value is not formatted when editing starts.
369
+ // Watch for the first blur and fire a 'change' event as programatic changes won't queue a change event, but we need to do this so that formatting happens if the user tabs to the calendar button.
370
+ if (__classPrivateFieldGet(this, _SkyAgGridCellEditorDatepickerComponent_triggerType, "f") === SkyAgGridCellEditorInitialAction.Replace) {
371
+ fromEvent(datepickerInputEl, 'blur')
372
+ .pipe(first())
373
+ .subscribe(() => {
374
+ datepickerInputEl.dispatchEvent(new Event('change'));
375
+ });
376
+ datepickerInputEl.select();
377
+ datepickerInputEl.setRangeText(this.params.charPress);
378
+ // Ensure the cursor is at the end of the text.
379
+ datepickerInputEl.setSelectionRange(this.params.charPress.length, this.params.charPress.length);
598
380
  }
599
- for (const config of this.rowDeleteConfigs) {
600
- if (value.indexOf(config.id) < 0) {
601
- this.destroyRowDelete(config.id);
602
- }
381
+ // this.changeDetector.markForCheck();
382
+ if (__classPrivateFieldGet(this, _SkyAgGridCellEditorDatepickerComponent_triggerType, "f") === SkyAgGridCellEditorInitialAction.Highlighted) {
383
+ datepickerInputEl.select();
603
384
  }
604
- this.changeDetector.markForCheck();
605
- }
606
- get rowDeleteIds() {
607
- return this._rowDeleteIds;
608
385
  }
609
- get tableWidth() {
610
- return this.elementRef.nativeElement.querySelectorAll('.sky-ag-grid')[0]
611
- .offsetWidth;
386
+ /**
387
+ * getValue is called by agGrid when editing is stopped to get the new value of the cell.
388
+ */
389
+ getValue() {
390
+ this.datepickerInput.nativeElement.blur();
391
+ return this.editorForm.get('date').value;
612
392
  }
613
- ngAfterContentInit() {
614
- this.rowDeleteComponent = this.viewContainerRef.createComponent(SkyAgGridRowDeleteComponent).instance;
615
- this.agGrid.rowDataChanged
616
- .pipe(takeUntil(this.ngUnsubscribe))
617
- .subscribe(() => {
618
- this.updateRowDeleteStates();
619
- });
620
- this.agGrid.rowDataUpdated
621
- .pipe(takeUntil(this.ngUnsubscribe))
622
- .subscribe(() => {
623
- this.updateRowDeleteStates();
624
- });
625
- this.agGrid.sortChanged
626
- .pipe(takeUntil(this.ngUnsubscribe))
627
- .subscribe(() => {
628
- this.updateRowDeleteStates();
629
- });
630
- this.agGrid.filterChanged
631
- .pipe(takeUntil(this.ngUnsubscribe))
632
- .subscribe(() => {
633
- this.updateRowDeleteStates();
393
+ }
394
+ _SkyAgGridCellEditorDatepickerComponent_triggerType = new WeakMap();
395
+ SkyAgGridCellEditorDatepickerComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellEditorDatepickerComponent, deps: [{ token: i0.ChangeDetectorRef }, { token: i1$2.SkyThemeService, optional: true }], target: i0.ɵɵFactoryTarget.Component });
396
+ SkyAgGridCellEditorDatepickerComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.2.0", type: SkyAgGridCellEditorDatepickerComponent, selector: "sky-ag-grid-cell-editor-datepicker", viewQueries: [{ propertyName: "datepickerInput", first: true, predicate: ["skyCellEditorDatepickerInput"], descendants: true, read: ElementRef }], usesInheritance: true, ngImport: i0, template: "<div\n class=\"sky-ag-grid-cell-editor-datepicker\"\n [formGroup]=\"editorForm\"\n [style.width.px]=\"columnWidthWithoutBorders\"\n>\n <sky-datepicker\n data-sky-id=\"cell-datepicker\"\n pickerClass=\"ag-custom-component-popup\"\n >\n <input\n formControlName=\"date\"\n skyDatepickerInput\n [minDate]=\"skyComponentProperties.minDate\"\n [maxDate]=\"skyComponentProperties.maxDate\"\n [dateFormat]=\"skyComponentProperties.dateFormat\"\n [startingDay]=\"skyComponentProperties.startingDay\"\n [skyDatepickerNoValidate]=\"skyComponentProperties.skyDatepickerNoValidate\"\n [style.height.px]=\"rowHeightWithoutBorders\"\n #skyCellEditorDatepickerInput\n />\n </sky-datepicker>\n</div>\n", styles: [".sky-ag-grid-cell-editor-datepicker{position:relative;top:1px;left:1px}.sky-ag-grid-cell-editor-datepicker sky-datepicker input.sky-form-control{box-shadow:none;border-width:1px;border-style:solid;border-color:transparent #cdcfd2 transparent transparent}.sky-ag-grid-cell-editor-datepicker sky-datepicker .sky-input-group-datepicker-btn{border-radius:0}:host-context(.sky-theme-modern) .sky-ag-grid-cell-editor-datepicker{position:static;top:initial;left:initial}:host-context(.sky-theme-modern) .sky-ag-grid-cell-editor-datepicker sky-datepicker input.sky-form-control{border-radius:0;border:1px solid #1870B8}:host-context(.sky-theme-modern) .sky-ag-grid-cell-editor-datepicker sky-datepicker input.sky-form-control:focus{border-width:2px!important}.sky-theme-modern .sky-ag-grid-cell-editor-datepicker{position:static;top:initial;left:initial}.sky-theme-modern .sky-ag-grid-cell-editor-datepicker sky-datepicker input.sky-form-control{border-radius:0;border:1px solid #1870B8}.sky-theme-modern .sky-ag-grid-cell-editor-datepicker sky-datepicker input.sky-form-control:focus{border-width:2px!important}\n"], dependencies: [{ kind: "component", type: i2$2.λ2, selector: "sky-datepicker", inputs: ["pickerClass"], outputs: ["calendarDateRangeChange"] }, { kind: "directive", type: i2$2.λ3, selector: "[skyDatepickerInput]", inputs: ["dateFormat", "disabled", "maxDate", "minDate", "skyDatepickerInput", "skyDatepickerNoValidate", "startingDay", "strict"] }, { kind: "directive", type: i1$1.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i1$1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1$1.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i1$1.FormGroupDirective, selector: "[formGroup]", inputs: ["formGroup"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "directive", type: i1$1.FormControlName, selector: "[formControlName]", inputs: ["formControlName", "disabled", "ngModel"], outputs: ["ngModelChange"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
397
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellEditorDatepickerComponent, decorators: [{
398
+ type: Component,
399
+ args: [{ selector: 'sky-ag-grid-cell-editor-datepicker', changeDetection: ChangeDetectionStrategy.OnPush, encapsulation: ViewEncapsulation.None, template: "<div\n class=\"sky-ag-grid-cell-editor-datepicker\"\n [formGroup]=\"editorForm\"\n [style.width.px]=\"columnWidthWithoutBorders\"\n>\n <sky-datepicker\n data-sky-id=\"cell-datepicker\"\n pickerClass=\"ag-custom-component-popup\"\n >\n <input\n formControlName=\"date\"\n skyDatepickerInput\n [minDate]=\"skyComponentProperties.minDate\"\n [maxDate]=\"skyComponentProperties.maxDate\"\n [dateFormat]=\"skyComponentProperties.dateFormat\"\n [startingDay]=\"skyComponentProperties.startingDay\"\n [skyDatepickerNoValidate]=\"skyComponentProperties.skyDatepickerNoValidate\"\n [style.height.px]=\"rowHeightWithoutBorders\"\n #skyCellEditorDatepickerInput\n />\n </sky-datepicker>\n</div>\n", styles: [".sky-ag-grid-cell-editor-datepicker{position:relative;top:1px;left:1px}.sky-ag-grid-cell-editor-datepicker sky-datepicker input.sky-form-control{box-shadow:none;border-width:1px;border-style:solid;border-color:transparent #cdcfd2 transparent transparent}.sky-ag-grid-cell-editor-datepicker sky-datepicker .sky-input-group-datepicker-btn{border-radius:0}:host-context(.sky-theme-modern) .sky-ag-grid-cell-editor-datepicker{position:static;top:initial;left:initial}:host-context(.sky-theme-modern) .sky-ag-grid-cell-editor-datepicker sky-datepicker input.sky-form-control{border-radius:0;border:1px solid #1870B8}:host-context(.sky-theme-modern) .sky-ag-grid-cell-editor-datepicker sky-datepicker input.sky-form-control:focus{border-width:2px!important}.sky-theme-modern .sky-ag-grid-cell-editor-datepicker{position:static;top:initial;left:initial}.sky-theme-modern .sky-ag-grid-cell-editor-datepicker sky-datepicker input.sky-form-control{border-radius:0;border:1px solid #1870B8}.sky-theme-modern .sky-ag-grid-cell-editor-datepicker sky-datepicker input.sky-form-control:focus{border-width:2px!important}\n"] }]
400
+ }], ctorParameters: function () {
401
+ return [{ type: i0.ChangeDetectorRef }, { type: i1$2.SkyThemeService, decorators: [{
402
+ type: Optional
403
+ }] }];
404
+ }, propDecorators: { datepickerInput: [{
405
+ type: ViewChild,
406
+ args: ['skyCellEditorDatepickerInput', { read: ElementRef }]
407
+ }] } });
408
+
409
+ var _SkyAgGridCellEditorLookupComponent_triggerType;
410
+ /**
411
+ * @internal
412
+ */
413
+ class SkyAgGridCellEditorLookupComponent {
414
+ constructor(changeDetector, elementRef) {
415
+ this.changeDetector = changeDetector;
416
+ this.elementRef = elementRef;
417
+ this.isAlive = false;
418
+ this.editorForm = new UntypedFormGroup({
419
+ selection: new UntypedFormControl({
420
+ value: [],
421
+ disabled: false,
422
+ }),
634
423
  });
424
+ this.useAsyncSearch = false;
425
+ _SkyAgGridCellEditorLookupComponent_triggerType.set(this, void 0);
635
426
  }
636
- ngOnDestroy() {
637
- this.ngUnsubscribe.next();
638
- this.ngUnsubscribe.complete();
639
- Object.keys(this.rowDeleteContents).forEach((id) => {
640
- this.destroyRowDelete(id);
427
+ agInit(params) {
428
+ this.params = params;
429
+ if (!Array.isArray(this.params.value)) {
430
+ throw new Error(`Lookup value must be an array`);
431
+ }
432
+ __classPrivateFieldSet(this, _SkyAgGridCellEditorLookupComponent_triggerType, SkyAgGridCellEditorUtils.getEditorInitialAction(params), "f");
433
+ const control = this.editorForm.get('selection');
434
+ switch (__classPrivateFieldGet(this, _SkyAgGridCellEditorLookupComponent_triggerType, "f")) {
435
+ case SkyAgGridCellEditorInitialAction.Delete:
436
+ control.setValue([]);
437
+ break;
438
+ case SkyAgGridCellEditorInitialAction.Replace:
439
+ case SkyAgGridCellEditorInitialAction.Highlighted:
440
+ case SkyAgGridCellEditorInitialAction.Untouched:
441
+ default:
442
+ control.setValue(params.value);
443
+ break;
444
+ }
445
+ if (this.params.skyComponentProperties.disabled) {
446
+ control.disable();
447
+ }
448
+ this.skyComponentProperties = this.updateComponentProperties(this.params);
449
+ this.useAsyncSearch =
450
+ typeof this.skyComponentProperties.searchAsync === 'function';
451
+ this.isAlive = true;
452
+ this.width = this.params.column.getActualWidth();
453
+ this.params.column.addEventListener('uiColumnResized', (event) => {
454
+ this.width = event.column.getActualWidth();
455
+ this.changeDetector.markForCheck();
641
456
  });
457
+ this.changeDetector.markForCheck();
642
458
  }
643
- cancelRowDelete(row) {
644
- this.rowDeleteConfigs = this.rowDeleteConfigs.filter((config) => config.id !== row.id);
645
- this.rowDeleteCancel.emit({ id: row.id });
646
- this.destroyRowDelete(row.id);
459
+ isCancelAfterEnd() {
460
+ // Shut down components to commit values before final value syncs to grid.
461
+ this.isAlive = false;
462
+ this.changeDetector.detectChanges();
463
+ return false;
647
464
  }
648
- confirmRowDelete(row) {
649
- this.rowDeleteConfigs.find((config) => config.id === row.id).pending = true;
650
- this.rowDeleteConfirm.emit({ id: row.id });
465
+ getGui() {
466
+ return this.elementRef.nativeElement;
651
467
  }
652
- getRowDeleteItem(row) {
653
- return this.rowDeleteConfigs.find((rowDelete) => rowDelete.id === row.id);
468
+ getValue() {
469
+ return this.editorForm.get('selection').value;
654
470
  }
655
- affixToRow(affixer, id) {
656
- let rowElement = this.elementRef.nativeElement.querySelector(`
657
- [row-id="${id}"] div[aria-colindex="1"],
658
- .ag-row.sky-ag-grid-row-${id} div[aria-colindex="1"]
659
- `);
660
- // This covers cases where AG Grid places the column index on an inner element (such as with the `enableCellTextSelection` option)
661
- // This appears to have been fixed by AG Grid in version 24 and so it is not testable after that version.
662
- /* istanbul ignore if */
663
- if (!rowElement) {
664
- const columns = this.elementRef.nativeElement.querySelectorAll('[row-id="' + id + '"] > div');
665
- for (let i = 0; i < columns.length; i++) {
666
- if (columns[i].querySelector('[aria-colindex="1"]')) {
667
- rowElement = columns[i];
668
- break;
669
- }
670
- }
671
- }
672
- affixer.affixTo(rowElement, {
673
- autoFitContext: SkyAffixAutoFitContext.Viewport,
674
- isSticky: true,
675
- placement: 'above',
676
- verticalAlignment: 'top',
677
- horizontalAlignment: 'left',
678
- enableAutoFit: false,
679
- });
471
+ isPopup() {
472
+ return true;
680
473
  }
681
- destroyRowDelete(id) {
682
- var _a;
683
- const rowDeleteContents = this.rowDeleteContents[id];
684
- /* sanity check */
685
- /* istanbul ignore else */
686
- if (rowDeleteContents) {
687
- rowDeleteContents.affixer.destroy();
688
- this.overlayService.close(rowDeleteContents.overlay);
689
- delete this.rowDeleteContents[id];
690
- this.rowDeleteConfigs = this.rowDeleteConfigs.filter((config) => config.id !== id);
691
- this._rowDeleteIds = (_a = this.rowDeleteIds) === null || _a === void 0 ? void 0 : _a.filter((arrayId) => arrayId !== id);
692
- this.rowDeleteIdsChange.emit(this._rowDeleteIds);
474
+ afterGuiAttached() {
475
+ const lookupInput = this.elementRef.nativeElement.querySelector('.sky-lookup-input');
476
+ lookupInput.focus();
477
+ if (__classPrivateFieldGet(this, _SkyAgGridCellEditorLookupComponent_triggerType, "f") === SkyAgGridCellEditorInitialAction.Replace) {
478
+ lookupInput.select();
479
+ lookupInput.setRangeText(this.params.charPress);
480
+ // Ensure the cursor is at the end of the text.
481
+ lookupInput.setSelectionRange(lookupInput.value.length, lookupInput.value.length);
482
+ lookupInput.dispatchEvent(new Event('input'));
483
+ }
484
+ if (__classPrivateFieldGet(this, _SkyAgGridCellEditorLookupComponent_triggerType, "f") === SkyAgGridCellEditorInitialAction.Highlighted) {
485
+ lookupInput.select();
693
486
  }
694
487
  }
695
- updateRowDeleteStates() {
696
- this.rowDeleteConfigs.forEach((config) => {
697
- if (!this.agGrid.api.getRowNode(config.id)) {
698
- this.destroyRowDelete(config.id);
699
- }
700
- else {
701
- // We must reaffix things when the data changes because the rows rerender and the previous element that the delete was affixed
702
- // to is destroyed.
703
- this.affixToRow(this.rowDeleteContents[config.id].affixer, config.id);
704
- }
705
- });
706
- this.changeDetector.markForCheck();
488
+ updateComponentProperties(params) {
489
+ const skyLookupProperties = params.skyComponentProperties;
490
+ return applySkyLookupPropertiesDefaults(skyLookupProperties);
707
491
  }
708
492
  }
709
- SkyAgGridRowDeleteDirective.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridRowDeleteDirective, deps: [{ token: i1.SkyAffixService }, { token: i0.ChangeDetectorRef }, { token: i0.ElementRef }, { token: i1.SkyOverlayService }, { token: i0.ViewContainerRef }], target: i0.ɵɵFactoryTarget.Directive });
710
- SkyAgGridRowDeleteDirective.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "14.2.0", type: SkyAgGridRowDeleteDirective, selector: "[skyAgGridRowDelete]", inputs: { rowDeleteIds: "rowDeleteIds" }, outputs: { rowDeleteCancel: "rowDeleteCancel", rowDeleteConfirm: "rowDeleteConfirm", rowDeleteIdsChange: "rowDeleteIdsChange" }, queries: [{ propertyName: "agGrid", first: true, predicate: AgGridAngular, descendants: true }], ngImport: i0 });
711
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridRowDeleteDirective, decorators: [{
712
- type: Directive,
713
- args: [{
714
- selector: '[skyAgGridRowDelete]',
715
- }]
716
- }], ctorParameters: function () { return [{ type: i1.SkyAffixService }, { type: i0.ChangeDetectorRef }, { type: i0.ElementRef }, { type: i1.SkyOverlayService }, { type: i0.ViewContainerRef }]; }, propDecorators: { rowDeleteIds: [{
717
- type: Input
718
- }], rowDeleteCancel: [{
719
- type: Output
720
- }], rowDeleteConfirm: [{
721
- type: Output
722
- }], rowDeleteIdsChange: [{
723
- type: Output
724
- }], agGrid: [{
725
- type: ContentChild,
726
- args: [AgGridAngular]
493
+ _SkyAgGridCellEditorLookupComponent_triggerType = new WeakMap();
494
+ SkyAgGridCellEditorLookupComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellEditorLookupComponent, deps: [{ token: i0.ChangeDetectorRef }, { token: i0.ElementRef }], target: i0.ɵɵFactoryTarget.Component });
495
+ SkyAgGridCellEditorLookupComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.2.0", type: SkyAgGridCellEditorLookupComponent, selector: "sky-ag-grid-cell-editor-lookup", host: { properties: { "style.width.px": "this.width" } }, ngImport: i0, template: "<sky-input-box\n *ngIf=\"isAlive && useAsyncSearch\"\n [disabled]=\"skyComponentProperties?.disabled\"\n [formGroup]=\"editorForm\"\n>\n <sky-lookup\n [ariaLabel]=\"skyComponentProperties?.ariaLabel\"\n [autocompleteAttribute]=\"skyComponentProperties?.autocompleteAttribute\"\n [data]=\"skyComponentProperties?.data\"\n [debounceTime]=\"skyComponentProperties?.debounceTime\"\n [descriptorProperty]=\"skyComponentProperties?.descriptorProperty\"\n [enableShowMore]=\"skyComponentProperties?.enableShowMore\"\n formControlName=\"selection\"\n [idProperty]=\"skyComponentProperties?.idProperty\"\n [placeholderText]=\"skyComponentProperties?.placeholderText\"\n [propertiesToSearch]=\"skyComponentProperties?.propertiesToSearch\"\n [searchFilters]=\"skyComponentProperties?.searchFilters\"\n [searchResultsLimit]=\"skyComponentProperties?.searchResultsLimit\"\n [searchResultTemplate]=\"skyComponentProperties?.searchResultTemplate\"\n [searchTextMinimumCharacters]=\"\n skyComponentProperties?.searchTextMinimumCharacters\n \"\n (searchAsync)=\"skyComponentProperties.searchAsync($event)\"\n [selectMode]=\"skyComponentProperties?.selectMode\"\n [showAddButton]=\"skyComponentProperties?.showAddButton\"\n [showMoreConfig]=\"skyComponentProperties?.showMoreConfig\"\n [wrapperClass]=\"skyComponentProperties?.wrapperClass\"\n >\n </sky-lookup>\n</sky-input-box>\n<sky-input-box\n *ngIf=\"isAlive && !useAsyncSearch\"\n [disabled]=\"skyComponentProperties?.disabled\"\n [formGroup]=\"editorForm\"\n>\n <sky-lookup\n [ariaLabel]=\"skyComponentProperties?.ariaLabel\"\n [autocompleteAttribute]=\"skyComponentProperties?.autocompleteAttribute\"\n [data]=\"skyComponentProperties?.data\"\n [debounceTime]=\"skyComponentProperties?.debounceTime\"\n [descriptorProperty]=\"skyComponentProperties?.descriptorProperty\"\n [enableShowMore]=\"skyComponentProperties?.enableShowMore\"\n formControlName=\"selection\"\n [idProperty]=\"skyComponentProperties?.idProperty\"\n [placeholderText]=\"skyComponentProperties?.placeholderText\"\n [propertiesToSearch]=\"skyComponentProperties?.propertiesToSearch\"\n [search]=\"skyComponentProperties?.search\"\n [searchFilters]=\"skyComponentProperties?.searchFilters\"\n [searchResultsLimit]=\"skyComponentProperties?.searchResultsLimit\"\n [searchResultTemplate]=\"skyComponentProperties?.searchResultTemplate\"\n [searchTextMinimumCharacters]=\"\n skyComponentProperties?.searchTextMinimumCharacters\n \"\n [selectMode]=\"skyComponentProperties?.selectMode\"\n [showAddButton]=\"skyComponentProperties?.showAddButton\"\n [showMoreConfig]=\"skyComponentProperties?.showMoreConfig\"\n [wrapperClass]=\"skyComponentProperties?.wrapperClass\"\n >\n </sky-lookup>\n</sky-input-box>\n", styles: [":host{display:block}\n"], dependencies: [{ kind: "directive", type: i2$3.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i1$1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1$1.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i1$1.FormGroupDirective, selector: "[formGroup]", inputs: ["formGroup"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "directive", type: i1$1.FormControlName, selector: "[formControlName]", inputs: ["formControlName", "disabled", "ngModel"], outputs: ["ngModelChange"] }, { kind: "component", type: i3$1.λ10, selector: "sky-input-box", inputs: ["hasErrors", "disabled"] }, { kind: "component", type: i2.λ4, selector: "sky-lookup", inputs: ["ariaLabel", "ariaLabelledBy", "autocompleteAttribute", "data", "disabled", "enableShowMore", "placeholderText", "idProperty", "showAddButton", "showMoreConfig", "selectMode", "wrapperClass"], outputs: ["addClick"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
496
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellEditorLookupComponent, decorators: [{
497
+ type: Component,
498
+ args: [{ selector: 'sky-ag-grid-cell-editor-lookup', changeDetection: ChangeDetectionStrategy.OnPush, template: "<sky-input-box\n *ngIf=\"isAlive && useAsyncSearch\"\n [disabled]=\"skyComponentProperties?.disabled\"\n [formGroup]=\"editorForm\"\n>\n <sky-lookup\n [ariaLabel]=\"skyComponentProperties?.ariaLabel\"\n [autocompleteAttribute]=\"skyComponentProperties?.autocompleteAttribute\"\n [data]=\"skyComponentProperties?.data\"\n [debounceTime]=\"skyComponentProperties?.debounceTime\"\n [descriptorProperty]=\"skyComponentProperties?.descriptorProperty\"\n [enableShowMore]=\"skyComponentProperties?.enableShowMore\"\n formControlName=\"selection\"\n [idProperty]=\"skyComponentProperties?.idProperty\"\n [placeholderText]=\"skyComponentProperties?.placeholderText\"\n [propertiesToSearch]=\"skyComponentProperties?.propertiesToSearch\"\n [searchFilters]=\"skyComponentProperties?.searchFilters\"\n [searchResultsLimit]=\"skyComponentProperties?.searchResultsLimit\"\n [searchResultTemplate]=\"skyComponentProperties?.searchResultTemplate\"\n [searchTextMinimumCharacters]=\"\n skyComponentProperties?.searchTextMinimumCharacters\n \"\n (searchAsync)=\"skyComponentProperties.searchAsync($event)\"\n [selectMode]=\"skyComponentProperties?.selectMode\"\n [showAddButton]=\"skyComponentProperties?.showAddButton\"\n [showMoreConfig]=\"skyComponentProperties?.showMoreConfig\"\n [wrapperClass]=\"skyComponentProperties?.wrapperClass\"\n >\n </sky-lookup>\n</sky-input-box>\n<sky-input-box\n *ngIf=\"isAlive && !useAsyncSearch\"\n [disabled]=\"skyComponentProperties?.disabled\"\n [formGroup]=\"editorForm\"\n>\n <sky-lookup\n [ariaLabel]=\"skyComponentProperties?.ariaLabel\"\n [autocompleteAttribute]=\"skyComponentProperties?.autocompleteAttribute\"\n [data]=\"skyComponentProperties?.data\"\n [debounceTime]=\"skyComponentProperties?.debounceTime\"\n [descriptorProperty]=\"skyComponentProperties?.descriptorProperty\"\n [enableShowMore]=\"skyComponentProperties?.enableShowMore\"\n formControlName=\"selection\"\n [idProperty]=\"skyComponentProperties?.idProperty\"\n [placeholderText]=\"skyComponentProperties?.placeholderText\"\n [propertiesToSearch]=\"skyComponentProperties?.propertiesToSearch\"\n [search]=\"skyComponentProperties?.search\"\n [searchFilters]=\"skyComponentProperties?.searchFilters\"\n [searchResultsLimit]=\"skyComponentProperties?.searchResultsLimit\"\n [searchResultTemplate]=\"skyComponentProperties?.searchResultTemplate\"\n [searchTextMinimumCharacters]=\"\n skyComponentProperties?.searchTextMinimumCharacters\n \"\n [selectMode]=\"skyComponentProperties?.selectMode\"\n [showAddButton]=\"skyComponentProperties?.showAddButton\"\n [showMoreConfig]=\"skyComponentProperties?.showMoreConfig\"\n [wrapperClass]=\"skyComponentProperties?.wrapperClass\"\n >\n </sky-lookup>\n</sky-input-box>\n", styles: [":host{display:block}\n"] }]
499
+ }], ctorParameters: function () { return [{ type: i0.ChangeDetectorRef }, { type: i0.ElementRef }]; }, propDecorators: { width: [{
500
+ type: HostBinding,
501
+ args: ['style.width.px']
727
502
  }] } });
728
503
 
504
+ var _SkyAgGridCellEditorNumberComponent_triggerType;
729
505
  /**
730
- * NOTICE: DO NOT MODIFY THIS FILE!
731
- * The contents of this file were automatically generated by
732
- * the 'ng generate @skyux/i18n:lib-resources-module lib/modules/shared/sky-ag-grid' schematic.
733
- * To update this file, simply rerun the command.
506
+ * @internal
734
507
  */
735
- const RESOURCES = {
736
- 'EN-US': {
737
- sky_ag_grid_row_selector_aria_label: {
738
- message: 'Row selector for row {0}',
739
- },
740
- sky_ag_grid_cell_editor_number_aria_label: {
741
- message: 'Editable number {0} for row {1}',
742
- },
743
- sky_ag_grid_cell_editor_text_aria_label: {
744
- message: 'Editable text {0} for row {1}',
745
- },
746
- sky_ag_grid_cell_editor_autocomplete_aria_label: {
747
- message: 'Editable autocomplete {0} for row {1}',
748
- },
749
- sky_ag_grid_cell_renderer_number_validator_message: {
750
- message: 'Enter a valid number.',
751
- },
752
- sky_ag_grid_cell_renderer_currency_validator_message: {
753
- message: 'Enter a valid currency.',
754
- },
755
- skyux_lookup_tokens_summary: { message: '{0} items selected' },
756
- sky_ag_grid_cell_editor_currency_aria_label: {
757
- message: 'Editable currency {0} for row {1}',
758
- },
759
- sky_ag_grid_column_group_header_expand_aria_label: {
760
- message: 'Expand column group {0}',
761
- },
762
- sky_ag_grid_column_group_header_collapse_aria_label: {
763
- message: 'Collapse column group {0}',
764
- },
765
- },
766
- };
767
- class SkyAgGridResourcesProvider {
768
- getString(localeInfo, name) {
769
- return getLibStringForLocale(RESOURCES, localeInfo.locale, name);
508
+ class SkyAgGridCellEditorNumberComponent {
509
+ constructor() {
510
+ this.editorForm = new UntypedFormGroup({
511
+ number: new UntypedFormControl(),
512
+ });
513
+ _SkyAgGridCellEditorNumberComponent_triggerType.set(this, void 0);
770
514
  }
771
- }
772
- /**
773
- * Import into any component library module that needs to use resource strings.
774
- */
775
- class SkyAgGridResourcesModule {
776
- }
777
- SkyAgGridResourcesModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridResourcesModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
778
- SkyAgGridResourcesModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridResourcesModule, exports: [SkyI18nModule] });
779
- SkyAgGridResourcesModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridResourcesModule, providers: [
780
- {
781
- provide: SKY_LIB_RESOURCES_PROVIDERS,
782
- useClass: SkyAgGridResourcesProvider,
783
- multi: true,
784
- },
785
- ], imports: [SkyI18nModule] });
786
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridResourcesModule, decorators: [{
787
- type: NgModule,
788
- args: [{
789
- exports: [SkyI18nModule],
790
- providers: [
791
- {
792
- provide: SKY_LIB_RESOURCES_PROVIDERS,
793
- useClass: SkyAgGridResourcesProvider,
794
- multi: true,
795
- },
796
- ],
797
- }]
798
- }] });
799
-
800
- /** The intiial action that a cell editor should take when initialized. */
801
- var SkyAgGridCellEditorInitialAction;
802
- (function (SkyAgGridCellEditorInitialAction) {
803
- /** The cell should be cleared. */
804
- SkyAgGridCellEditorInitialAction[SkyAgGridCellEditorInitialAction["Delete"] = 0] = "Delete";
805
- /** The cell value should be highlighted. */
806
- SkyAgGridCellEditorInitialAction[SkyAgGridCellEditorInitialAction["Highlighted"] = 1] = "Highlighted";
807
- /** The cell value should be replaced with the initializing value. */
808
- SkyAgGridCellEditorInitialAction[SkyAgGridCellEditorInitialAction["Replace"] = 2] = "Replace";
809
- /** The cell should not be modified and the cursor is placed at the end of the value. */
810
- SkyAgGridCellEditorInitialAction[SkyAgGridCellEditorInitialAction["Untouched"] = 3] = "Untouched";
811
- })(SkyAgGridCellEditorInitialAction || (SkyAgGridCellEditorInitialAction = {}));
812
-
813
- class SkyAgGridCellEditorUtils {
814
515
  /**
815
- * Gets the intiial action that a cell editor should take when initialized.
816
- * @param params The editor's initializing parameters.
516
+ * agInit is called by agGrid once after the editor is created and provides the editor with the information it needs.
517
+ * @param params The cell editor params that include data about the cell, column, row, and grid.
817
518
  */
818
- static getEditorInitialAction(params) {
819
- if (params.cellStartedEdit) {
820
- if (params.eventKey === KeyCode.BACKSPACE ||
821
- params.eventKey === KeyCode.DELETE) {
822
- return SkyAgGridCellEditorInitialAction.Delete;
823
- }
824
- else if (params.charPress) {
825
- return SkyAgGridCellEditorInitialAction.Replace;
826
- }
827
- else {
828
- if (params.eventKey !== KeyCode.F2) {
829
- return SkyAgGridCellEditorInitialAction.Highlighted;
830
- }
831
- else {
832
- return SkyAgGridCellEditorInitialAction.Untouched;
833
- }
834
- }
835
- }
836
- else {
837
- return SkyAgGridCellEditorInitialAction.Untouched;
838
- }
839
- }
840
- }
841
-
842
- var _SkyAgGridCellEditorAutocompleteComponent_triggerType;
843
- /**
844
- * @internal
845
- */
846
- class SkyAgGridCellEditorAutocompleteComponent {
847
- constructor() {
848
- this.editorForm = new UntypedFormGroup({
849
- selection: new UntypedFormControl(),
850
- });
851
- this.skyComponentProperties = {};
852
- _SkyAgGridCellEditorAutocompleteComponent_triggerType.set(this, void 0);
853
- }
854
519
  agInit(params) {
520
+ var _a, _b;
855
521
  this.params = params;
856
- __classPrivateFieldSet(this, _SkyAgGridCellEditorAutocompleteComponent_triggerType, SkyAgGridCellEditorUtils.getEditorInitialAction(params), "f");
857
- const control = this.editorForm.get('selection');
858
- switch (__classPrivateFieldGet(this, _SkyAgGridCellEditorAutocompleteComponent_triggerType, "f")) {
522
+ __classPrivateFieldSet(this, _SkyAgGridCellEditorNumberComponent_triggerType, SkyAgGridCellEditorUtils.getEditorInitialAction(params), "f");
523
+ const control = this.editorForm.get('number');
524
+ switch (__classPrivateFieldGet(this, _SkyAgGridCellEditorNumberComponent_triggerType, "f")) {
859
525
  case SkyAgGridCellEditorInitialAction.Delete:
860
526
  control.setValue(undefined);
861
527
  break;
862
528
  case SkyAgGridCellEditorInitialAction.Replace:
529
+ control.setValue(parseFloat(this.params.charPress) || undefined);
530
+ break;
863
531
  case SkyAgGridCellEditorInitialAction.Highlighted:
864
532
  case SkyAgGridCellEditorInitialAction.Untouched:
865
533
  default:
866
534
  control.setValue(params.value);
867
535
  break;
868
536
  }
869
- this.columnHeader = this.params.colDef && this.params.colDef.headerName;
870
- this.rowNumber = this.params.rowIndex + 1;
871
- this.skyComponentProperties = this.params.skyComponentProperties || {};
872
- }
873
- afterGuiAttached() {
874
- this.input.nativeElement.focus();
875
- if (__classPrivateFieldGet(this, _SkyAgGridCellEditorAutocompleteComponent_triggerType, "f") === SkyAgGridCellEditorInitialAction.Replace) {
876
- this.input.nativeElement.select();
877
- this.input.nativeElement.setRangeText(this.params.charPress);
878
- // Ensure the cursor is at the end of the text.
879
- this.input.nativeElement.setSelectionRange(this.params.charPress.length, this.params.charPress.length);
880
- this.input.nativeElement.dispatchEvent(new Event('input'));
881
- }
882
- if (__classPrivateFieldGet(this, _SkyAgGridCellEditorAutocompleteComponent_triggerType, "f") === SkyAgGridCellEditorInitialAction.Highlighted) {
883
- this.input.nativeElement.select();
884
- }
885
- }
886
- getValue() {
887
- const val = this.editorForm.get('selection').value;
888
- return val !== undefined && val !== null ? val : undefined;
889
- }
890
- }
891
- _SkyAgGridCellEditorAutocompleteComponent_triggerType = new WeakMap();
892
- SkyAgGridCellEditorAutocompleteComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellEditorAutocompleteComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
893
- SkyAgGridCellEditorAutocompleteComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.2.0", type: SkyAgGridCellEditorAutocompleteComponent, selector: "sky-ag-grid-cell-editor-autocomplete", viewQueries: [{ propertyName: "input", first: true, predicate: ["skyCellEditorAutocomplete"], descendants: true, read: ElementRef }], ngImport: i0, template: "<div class=\"sky-ag-grid-cell-editor-autocomplete\" [formGroup]=\"editorForm\">\n <sky-autocomplete\n [data]=\"skyComponentProperties.data\"\n [debounceTime]=\"skyComponentProperties.debounceTime\"\n [descriptorProperty]=\"skyComponentProperties.descriptorProperty\"\n [propertiesToSearch]=\"skyComponentProperties.propertiesToSearch\"\n [search]=\"skyComponentProperties.search\"\n [searchFilters]=\"skyComponentProperties.searchFilters\"\n [searchResultsLimit]=\"skyComponentProperties.searchResultsLimit\"\n [searchResultTemplate]=\"skyComponentProperties.searchResultTemplate\"\n [searchTextMinimumCharacters]=\"\n skyComponentProperties.searchTextMinimumCharacters\n \"\n (selectionChange)=\"\n skyComponentProperties.selectionChange &&\n skyComponentProperties.selectionChange($event)\n \"\n >\n <input\n formControlName=\"selection\"\n skyAutocomplete\n #skyCellEditorAutocomplete\n type=\"text\"\n [attr.aria-label]=\"\n 'sky_ag_grid_cell_editor_autocomplete_aria_label'\n | skyLibResources: columnHeader:rowNumber\n \"\n />\n </sky-autocomplete>\n</div>\n", styles: ["sky-autocomplete input{border:none;box-shadow:none}\n"], dependencies: [{ kind: "directive", type: i1$2.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i1$2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1$2.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i1$2.FormGroupDirective, selector: "[formGroup]", inputs: ["formGroup"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "directive", type: i1$2.FormControlName, selector: "[formControlName]", inputs: ["formControlName", "disabled", "ngModel"], outputs: ["ngModelChange"] }, { kind: "component", type: i2$2.λ2, selector: "sky-autocomplete", inputs: ["ariaLabelledBy", "data", "debounceTime", "descriptorProperty", "enableShowMore", "messageStream", "wrapperClass", "propertiesToSearch", "search", "searchResultTemplate", "searchTextMinimumCharacters", "searchFilters", "searchResultsLimit", "showAddButton", "noResultsFoundText", "searchAsyncDisabled"], outputs: ["addClick", "showMoreClick", "selectionChange", "searchAsync"] }, { kind: "directive", type: i2$2.λ1, selector: "input[skyAutocomplete], textarea[skyAutocomplete]", inputs: ["autocompleteAttribute", "disabled"] }, { kind: "pipe", type: i3.SkyLibResourcesPipe, name: "skyLibResources" }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
894
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellEditorAutocompleteComponent, decorators: [{
895
- type: Component,
896
- args: [{ selector: 'sky-ag-grid-cell-editor-autocomplete', changeDetection: ChangeDetectionStrategy.OnPush, template: "<div class=\"sky-ag-grid-cell-editor-autocomplete\" [formGroup]=\"editorForm\">\n <sky-autocomplete\n [data]=\"skyComponentProperties.data\"\n [debounceTime]=\"skyComponentProperties.debounceTime\"\n [descriptorProperty]=\"skyComponentProperties.descriptorProperty\"\n [propertiesToSearch]=\"skyComponentProperties.propertiesToSearch\"\n [search]=\"skyComponentProperties.search\"\n [searchFilters]=\"skyComponentProperties.searchFilters\"\n [searchResultsLimit]=\"skyComponentProperties.searchResultsLimit\"\n [searchResultTemplate]=\"skyComponentProperties.searchResultTemplate\"\n [searchTextMinimumCharacters]=\"\n skyComponentProperties.searchTextMinimumCharacters\n \"\n (selectionChange)=\"\n skyComponentProperties.selectionChange &&\n skyComponentProperties.selectionChange($event)\n \"\n >\n <input\n formControlName=\"selection\"\n skyAutocomplete\n #skyCellEditorAutocomplete\n type=\"text\"\n [attr.aria-label]=\"\n 'sky_ag_grid_cell_editor_autocomplete_aria_label'\n | skyLibResources: columnHeader:rowNumber\n \"\n />\n </sky-autocomplete>\n</div>\n", styles: ["sky-autocomplete input{border:none;box-shadow:none}\n"] }]
897
- }], propDecorators: { input: [{
898
- type: ViewChild,
899
- args: ['skyCellEditorAutocomplete', { read: ElementRef }]
900
- }] } });
901
-
902
- class SkyAgGridCellEditorAutocompleteModule {
903
- }
904
- SkyAgGridCellEditorAutocompleteModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellEditorAutocompleteModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
905
- SkyAgGridCellEditorAutocompleteModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellEditorAutocompleteModule, declarations: [SkyAgGridCellEditorAutocompleteComponent], imports: [ReactiveFormsModule,
906
- SkyAgGridResourcesModule,
907
- SkyAutocompleteModule], exports: [SkyAgGridCellEditorAutocompleteComponent] });
908
- SkyAgGridCellEditorAutocompleteModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellEditorAutocompleteModule, imports: [ReactiveFormsModule,
909
- SkyAgGridResourcesModule,
910
- SkyAutocompleteModule] });
911
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellEditorAutocompleteModule, decorators: [{
912
- type: NgModule,
913
- args: [{
914
- imports: [
915
- ReactiveFormsModule,
916
- SkyAgGridResourcesModule,
917
- SkyAutocompleteModule,
918
- ],
919
- declarations: [SkyAgGridCellEditorAutocompleteComponent],
920
- exports: [SkyAgGridCellEditorAutocompleteComponent],
921
- }]
922
- }] });
923
-
924
- var _SkyAgGridCellEditorCurrencyComponent_triggerType;
925
- /**
926
- * @internal
927
- */
928
- class SkyAgGridCellEditorCurrencyComponent {
929
- constructor(changeDetector) {
930
- this.changeDetector = changeDetector;
931
- this.skyComponentProperties = {};
932
- this.editorForm = new UntypedFormGroup({
933
- currency: new UntypedFormControl(),
934
- });
935
- _SkyAgGridCellEditorCurrencyComponent_triggerType.set(this, void 0);
936
- }
937
- /**
938
- * agInit is called by agGrid once after the editor is created and provides the editor with the information it needs.
939
- * @param params The cell editor params that include data about the cell, column, row, and grid.
940
- */
941
- agInit(params) {
942
- this.params = params;
537
+ this.max = (_a = params.skyComponentProperties) === null || _a === void 0 ? void 0 : _a.max;
538
+ this.min = (_b = params.skyComponentProperties) === null || _b === void 0 ? void 0 : _b.min;
943
539
  this.columnHeader = this.params.colDef.headerName;
944
540
  this.rowNumber = this.params.rowIndex + 1;
945
541
  this.columnWidth = this.params.column.getActualWidth();
946
542
  this.rowHeightWithoutBorders =
947
543
  this.params.node && this.params.node.rowHeight - 4;
948
- this.skyComponentProperties = this.params.skyComponentProperties || {
949
- decimalPlaces: 2,
950
- currencySymbol: '$',
951
- };
952
544
  }
953
545
  /**
954
546
  * afterGuiAttached is called by agGrid after the editor is rendered in the DOM. Once it is attached the editor is ready to be focused on.
955
547
  */
956
548
  afterGuiAttached() {
957
549
  this.input.nativeElement.focus();
958
- // This setup is in `afterGuiAttached` due to the lifecycle of autonumeric which will highlight the initial value if it is in place when it renders.
959
- // Since we don't want that, we set the initial value after autonumeric initializes.
960
- __classPrivateFieldSet(this, _SkyAgGridCellEditorCurrencyComponent_triggerType, SkyAgGridCellEditorUtils.getEditorInitialAction(this.params), "f");
961
- const control = this.editorForm.get('currency');
962
- switch (__classPrivateFieldGet(this, _SkyAgGridCellEditorCurrencyComponent_triggerType, "f")) {
963
- case SkyAgGridCellEditorInitialAction.Delete:
964
- control.setValue(undefined);
965
- break;
966
- case SkyAgGridCellEditorInitialAction.Replace:
967
- control.setValue(parseFloat(this.params.charPress) || undefined);
968
- break;
969
- case SkyAgGridCellEditorInitialAction.Highlighted:
970
- case SkyAgGridCellEditorInitialAction.Untouched:
971
- default:
972
- control.setValue(parseFloat(this.params.value));
973
- break;
550
+ if (__classPrivateFieldGet(this, _SkyAgGridCellEditorNumberComponent_triggerType, "f") === SkyAgGridCellEditorInitialAction.Highlighted) {
551
+ this.input.nativeElement.select();
974
552
  }
975
- this.changeDetector.markForCheck();
976
- // Without the `setTimeout` there is inconsistent behavior with the highlighting when no initial value is present.
977
- setTimeout(() => {
978
- if (__classPrivateFieldGet(this, _SkyAgGridCellEditorCurrencyComponent_triggerType, "f") === SkyAgGridCellEditorInitialAction.Highlighted) {
979
- this.input.nativeElement.select();
980
- }
981
- }, 100);
982
553
  }
983
554
  /**
984
555
  * getValue is called by agGrid when editing is stopped to get the new value of the cell.
985
556
  */
986
557
  getValue() {
987
- const val = this.editorForm.get('currency').value;
558
+ const val = this.editorForm.get('number').value;
988
559
  return val !== undefined && val !== null ? val : undefined;
989
560
  }
990
- /**
991
- * The autoNumeric library's event handler suppresses the escape key event. This additional handler re-enables AG Grid's default functionality.
992
- */
993
- onPressEscape() {
994
- this.params.api.stopEditing(true);
995
- this.params.api.setFocusedCell(this.params.rowIndex, this.params.column);
996
- }
997
561
  }
998
- _SkyAgGridCellEditorCurrencyComponent_triggerType = new WeakMap();
999
- SkyAgGridCellEditorCurrencyComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellEditorCurrencyComponent, deps: [{ token: i0.ChangeDetectorRef }], target: i0.ɵɵFactoryTarget.Component });
1000
- SkyAgGridCellEditorCurrencyComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.2.0", type: SkyAgGridCellEditorCurrencyComponent, selector: "sky-ag-grid-cell-editor-currency", viewQueries: [{ propertyName: "input", first: true, predicate: ["skyCellEditorCurrency"], descendants: true, read: ElementRef }], ngImport: i0, template: "<ng-container [formGroup]=\"editorForm\">\n <input\n formControlName=\"currency\"\n type=\"text\"\n [attr.aria-label]=\"\n 'sky_ag_grid_cell_editor_currency_aria_label'\n | skyLibResources: columnHeader:rowNumber\n \"\n [style.width.px]=\"columnWidth\"\n [style.height.px]=\"rowHeightWithoutBorders\"\n [skyAutonumeric]=\"skyComponentProperties\"\n [skyAutonumericFormChangesUnformatted]=\"!!params?.charPress\"\n (keyup.escape)=\"onPressEscape()\"\n #skyCellEditorCurrency\n />\n</ng-container>\n", styles: ["input{border:none;padding-left:11px}\n"], dependencies: [{ kind: "directive", type: i1$2.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i1$2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1$2.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i1$2.FormGroupDirective, selector: "[formGroup]", inputs: ["formGroup"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "directive", type: i1$2.FormControlName, selector: "[formControlName]", inputs: ["formControlName", "disabled", "ngModel"], outputs: ["ngModelChange"] }, { kind: "directive", type: i2$3.λ1, selector: "input[skyAutonumeric]", inputs: ["skyAutonumeric", "skyAutonumericFormChangesUnformatted"] }, { kind: "pipe", type: i3.SkyLibResourcesPipe, name: "skyLibResources" }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
1001
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellEditorCurrencyComponent, decorators: [{
562
+ _SkyAgGridCellEditorNumberComponent_triggerType = new WeakMap();
563
+ SkyAgGridCellEditorNumberComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellEditorNumberComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
564
+ SkyAgGridCellEditorNumberComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.2.0", type: SkyAgGridCellEditorNumberComponent, selector: "sky-ag-grid-cell-editor-number", viewQueries: [{ propertyName: "input", first: true, predicate: ["skyCellEditorNumber"], descendants: true, read: ElementRef }], ngImport: i0, template: "<ng-container [formGroup]=\"editorForm\">\n <input\n formControlName=\"number\"\n type=\"number\"\n [attr.aria-label]=\"\n 'sky_ag_grid_cell_editor_number_aria_label'\n | skyLibResources: columnHeader:rowNumber\n \"\n [style.width.px]=\"columnWidth\"\n [style.height.px]=\"rowHeightWithoutBorders\"\n [max]=\"max\"\n [min]=\"min\"\n #skyCellEditorNumber\n />\n</ng-container>\n", styles: ["input{border:none;text-align:right}\n"], dependencies: [{ kind: "directive", type: i1$1.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i1$1.NumberValueAccessor, selector: "input[type=number][formControlName],input[type=number][formControl],input[type=number][ngModel]" }, { kind: "directive", type: i1$1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1$1.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i1$1.MinValidator, selector: "input[type=number][min][formControlName],input[type=number][min][formControl],input[type=number][min][ngModel]", inputs: ["min"] }, { kind: "directive", type: i1$1.MaxValidator, selector: "input[type=number][max][formControlName],input[type=number][max][formControl],input[type=number][max][ngModel]", inputs: ["max"] }, { kind: "directive", type: i1$1.FormGroupDirective, selector: "[formGroup]", inputs: ["formGroup"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "directive", type: i1$1.FormControlName, selector: "[formControlName]", inputs: ["formControlName", "disabled", "ngModel"], outputs: ["ngModelChange"] }, { kind: "pipe", type: i3.SkyLibResourcesPipe, name: "skyLibResources" }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
565
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellEditorNumberComponent, decorators: [{
1002
566
  type: Component,
1003
- args: [{ selector: 'sky-ag-grid-cell-editor-currency', changeDetection: ChangeDetectionStrategy.OnPush, template: "<ng-container [formGroup]=\"editorForm\">\n <input\n formControlName=\"currency\"\n type=\"text\"\n [attr.aria-label]=\"\n 'sky_ag_grid_cell_editor_currency_aria_label'\n | skyLibResources: columnHeader:rowNumber\n \"\n [style.width.px]=\"columnWidth\"\n [style.height.px]=\"rowHeightWithoutBorders\"\n [skyAutonumeric]=\"skyComponentProperties\"\n [skyAutonumericFormChangesUnformatted]=\"!!params?.charPress\"\n (keyup.escape)=\"onPressEscape()\"\n #skyCellEditorCurrency\n />\n</ng-container>\n", styles: ["input{border:none;padding-left:11px}\n"] }]
1004
- }], ctorParameters: function () { return [{ type: i0.ChangeDetectorRef }]; }, propDecorators: { input: [{
567
+ args: [{ selector: 'sky-ag-grid-cell-editor-number', changeDetection: ChangeDetectionStrategy.OnPush, template: "<ng-container [formGroup]=\"editorForm\">\n <input\n formControlName=\"number\"\n type=\"number\"\n [attr.aria-label]=\"\n 'sky_ag_grid_cell_editor_number_aria_label'\n | skyLibResources: columnHeader:rowNumber\n \"\n [style.width.px]=\"columnWidth\"\n [style.height.px]=\"rowHeightWithoutBorders\"\n [max]=\"max\"\n [min]=\"min\"\n #skyCellEditorNumber\n />\n</ng-container>\n", styles: ["input{border:none;text-align:right}\n"] }]
568
+ }], propDecorators: { input: [{
1005
569
  type: ViewChild,
1006
- args: ['skyCellEditorCurrency', { read: ElementRef }]
570
+ args: ['skyCellEditorNumber', { read: ElementRef }]
1007
571
  }] } });
1008
572
 
1009
- class SkyAgGridCellEditorCurrencyModule {
1010
- }
1011
- SkyAgGridCellEditorCurrencyModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellEditorCurrencyModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
1012
- SkyAgGridCellEditorCurrencyModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellEditorCurrencyModule, declarations: [SkyAgGridCellEditorCurrencyComponent], imports: [SkyAgGridResourcesModule,
1013
- ReactiveFormsModule,
1014
- SkyAutonumericModule], exports: [SkyAgGridCellEditorCurrencyComponent] });
1015
- SkyAgGridCellEditorCurrencyModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellEditorCurrencyModule, imports: [SkyAgGridResourcesModule,
1016
- ReactiveFormsModule,
1017
- SkyAutonumericModule] });
1018
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellEditorCurrencyModule, decorators: [{
1019
- type: NgModule,
1020
- args: [{
1021
- imports: [
1022
- SkyAgGridResourcesModule,
1023
- ReactiveFormsModule,
1024
- SkyAutonumericModule,
1025
- ],
1026
- declarations: [SkyAgGridCellEditorCurrencyComponent],
1027
- exports: [SkyAgGridCellEditorCurrencyComponent],
1028
- }]
1029
- }] });
1030
-
1031
- var _SkyAgGridCellEditorDatepickerComponent_triggerType;
573
+ var _SkyAgGridCellEditorTextComponent_triggerType;
1032
574
  /**
1033
575
  * @internal
1034
576
  */
1035
- class SkyAgGridCellEditorDatepickerComponent extends PopupComponent {
1036
- constructor(changeDetector, themeSvc) {
1037
- super();
1038
- this.changeDetector = changeDetector;
1039
- this.themeSvc = themeSvc;
577
+ class SkyAgGridCellEditorTextComponent {
578
+ constructor() {
1040
579
  this.editorForm = new UntypedFormGroup({
1041
- date: new UntypedFormControl(),
580
+ text: new UntypedFormControl(),
1042
581
  });
1043
- this.skyComponentProperties = {};
1044
- _SkyAgGridCellEditorDatepickerComponent_triggerType.set(this, void 0);
582
+ _SkyAgGridCellEditorTextComponent_triggerType.set(this, void 0);
1045
583
  }
1046
584
  /**
1047
585
  * agInit is called by agGrid once after the editor is created and provides the editor with the information it needs.
1048
586
  * @param params The cell editor params that include data about the cell, column, row, and grid.
1049
587
  */
1050
588
  agInit(params) {
1051
- var _a, _b;
589
+ var _a;
1052
590
  this.params = params;
1053
- __classPrivateFieldSet(this, _SkyAgGridCellEditorDatepickerComponent_triggerType, SkyAgGridCellEditorUtils.getEditorInitialAction(params), "f");
1054
- const control = this.editorForm.get('date');
1055
- switch (__classPrivateFieldGet(this, _SkyAgGridCellEditorDatepickerComponent_triggerType, "f")) {
591
+ __classPrivateFieldSet(this, _SkyAgGridCellEditorTextComponent_triggerType, SkyAgGridCellEditorUtils.getEditorInitialAction(params), "f");
592
+ const control = this.editorForm.get('text');
593
+ switch (__classPrivateFieldGet(this, _SkyAgGridCellEditorTextComponent_triggerType, "f")) {
1056
594
  case SkyAgGridCellEditorInitialAction.Delete:
1057
595
  control.setValue(undefined);
1058
596
  break;
@@ -1065,512 +603,133 @@ class SkyAgGridCellEditorDatepickerComponent extends PopupComponent {
1065
603
  control.setValue(params.value);
1066
604
  break;
1067
605
  }
1068
- if ((_a = this.params.skyComponentProperties) === null || _a === void 0 ? void 0 : _a.disabled) {
1069
- control.disable();
1070
- }
1071
- this.changeDetector.markForCheck();
1072
- this.skyComponentProperties = this.params.skyComponentProperties || {};
606
+ this.maxlength = (_a = params.skyComponentProperties) === null || _a === void 0 ? void 0 : _a.maxlength;
607
+ this.columnHeader = this.params.colDef.headerName;
608
+ this.rowNumber = this.params.rowIndex + 1;
1073
609
  this.columnWidth = this.params.column.getActualWidth();
1074
- this.columnWidthWithoutBorders = this.columnWidth - 2;
1075
610
  this.rowHeightWithoutBorders =
1076
- this.params.node && this.params.node.rowHeight - 3;
1077
- (_b = this.themeSvc) === null || _b === void 0 ? void 0 : _b.settingsChange.subscribe((themeSettings) => {
1078
- if (themeSettings.currentSettings.theme.name === 'modern') {
1079
- this.columnWidthWithoutBorders = this.columnWidth;
1080
- this.rowHeightWithoutBorders =
1081
- this.params.node && this.params.node.rowHeight;
1082
- }
1083
- else {
1084
- this.columnWidthWithoutBorders = this.columnWidth - 2;
1085
- this.rowHeightWithoutBorders =
1086
- this.params.node && this.params.node.rowHeight - 3;
1087
- }
1088
- });
611
+ this.params.node && this.params.node.rowHeight - 4;
1089
612
  }
1090
613
  /**
1091
614
  * afterGuiAttached is called by agGrid after the editor is rendered in the DOM. Once it is attached the editor is ready to be focused on.
1092
615
  */
1093
616
  afterGuiAttached() {
1094
- const datepickerInputEl = this.datepickerInput
1095
- .nativeElement;
1096
- datepickerInputEl.focus();
1097
- // Programatically set the value of in the input; however, do not do this via the form control so that the value is not formatted when editing starts.
1098
- // Watch for the first blur and fire a 'change' event as programatic changes won't queue a change event, but we need to do this so that formatting happens if the user tabs to the calendar button.
1099
- if (__classPrivateFieldGet(this, _SkyAgGridCellEditorDatepickerComponent_triggerType, "f") === SkyAgGridCellEditorInitialAction.Replace) {
1100
- fromEvent(datepickerInputEl, 'blur')
1101
- .pipe(first())
1102
- .subscribe(() => {
1103
- datepickerInputEl.dispatchEvent(new Event('change'));
1104
- });
1105
- datepickerInputEl.select();
1106
- datepickerInputEl.setRangeText(this.params.charPress);
1107
- // Ensure the cursor is at the end of the text.
1108
- datepickerInputEl.setSelectionRange(this.params.charPress.length, this.params.charPress.length);
1109
- }
1110
- // this.changeDetector.markForCheck();
1111
- if (__classPrivateFieldGet(this, _SkyAgGridCellEditorDatepickerComponent_triggerType, "f") === SkyAgGridCellEditorInitialAction.Highlighted) {
1112
- datepickerInputEl.select();
617
+ this.input.nativeElement.focus();
618
+ if (__classPrivateFieldGet(this, _SkyAgGridCellEditorTextComponent_triggerType, "f") === SkyAgGridCellEditorInitialAction.Highlighted) {
619
+ this.input.nativeElement.select();
1113
620
  }
1114
621
  }
1115
622
  /**
1116
623
  * getValue is called by agGrid when editing is stopped to get the new value of the cell.
1117
624
  */
1118
625
  getValue() {
1119
- this.datepickerInput.nativeElement.blur();
1120
- return this.editorForm.get('date').value;
626
+ return this.editorForm.get('text').value || undefined;
1121
627
  }
1122
628
  }
1123
- _SkyAgGridCellEditorDatepickerComponent_triggerType = new WeakMap();
1124
- SkyAgGridCellEditorDatepickerComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellEditorDatepickerComponent, deps: [{ token: i0.ChangeDetectorRef }, { token: i1$3.SkyThemeService, optional: true }], target: i0.ɵɵFactoryTarget.Component });
1125
- SkyAgGridCellEditorDatepickerComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.2.0", type: SkyAgGridCellEditorDatepickerComponent, selector: "sky-ag-grid-cell-editor-datepicker", viewQueries: [{ propertyName: "datepickerInput", first: true, predicate: ["skyCellEditorDatepickerInput"], descendants: true, read: ElementRef }], usesInheritance: true, ngImport: i0, template: "<div\n class=\"sky-ag-grid-cell-editor-datepicker\"\n [formGroup]=\"editorForm\"\n [style.width.px]=\"columnWidthWithoutBorders\"\n>\n <sky-datepicker\n data-sky-id=\"cell-datepicker\"\n pickerClass=\"ag-custom-component-popup\"\n >\n <input\n formControlName=\"date\"\n skyDatepickerInput\n [minDate]=\"skyComponentProperties.minDate\"\n [maxDate]=\"skyComponentProperties.maxDate\"\n [dateFormat]=\"skyComponentProperties.dateFormat\"\n [startingDay]=\"skyComponentProperties.startingDay\"\n [skyDatepickerNoValidate]=\"skyComponentProperties.skyDatepickerNoValidate\"\n [style.height.px]=\"rowHeightWithoutBorders\"\n #skyCellEditorDatepickerInput\n />\n </sky-datepicker>\n</div>\n", styles: [".sky-ag-grid-cell-editor-datepicker{position:relative;top:1px;left:1px}.sky-ag-grid-cell-editor-datepicker sky-datepicker input.sky-form-control{box-shadow:none;border-width:1px;border-style:solid;border-color:transparent #cdcfd2 transparent transparent}.sky-ag-grid-cell-editor-datepicker sky-datepicker .sky-input-group-datepicker-btn{border-radius:0}:host-context(.sky-theme-modern) .sky-ag-grid-cell-editor-datepicker{position:static;top:initial;left:initial}:host-context(.sky-theme-modern) .sky-ag-grid-cell-editor-datepicker sky-datepicker input.sky-form-control{border-radius:0;border:1px solid #1870B8}:host-context(.sky-theme-modern) .sky-ag-grid-cell-editor-datepicker sky-datepicker input.sky-form-control:focus{border-width:2px!important}.sky-theme-modern .sky-ag-grid-cell-editor-datepicker{position:static;top:initial;left:initial}.sky-theme-modern .sky-ag-grid-cell-editor-datepicker sky-datepicker input.sky-form-control{border-radius:0;border:1px solid #1870B8}.sky-theme-modern .sky-ag-grid-cell-editor-datepicker sky-datepicker input.sky-form-control:focus{border-width:2px!important}\n"], dependencies: [{ kind: "component", type: i2$4.λ2, selector: "sky-datepicker", inputs: ["pickerClass"], outputs: ["calendarDateRangeChange"] }, { kind: "directive", type: i2$4.λ3, selector: "[skyDatepickerInput]", inputs: ["dateFormat", "disabled", "maxDate", "minDate", "skyDatepickerInput", "skyDatepickerNoValidate", "startingDay", "strict"] }, { kind: "directive", type: i1$2.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i1$2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1$2.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i1$2.FormGroupDirective, selector: "[formGroup]", inputs: ["formGroup"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "directive", type: i1$2.FormControlName, selector: "[formControlName]", inputs: ["formControlName", "disabled", "ngModel"], outputs: ["ngModelChange"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
1126
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellEditorDatepickerComponent, decorators: [{
629
+ _SkyAgGridCellEditorTextComponent_triggerType = new WeakMap();
630
+ SkyAgGridCellEditorTextComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellEditorTextComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
631
+ SkyAgGridCellEditorTextComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.2.0", type: SkyAgGridCellEditorTextComponent, selector: "sky-ag-grid-cell-editor-text", viewQueries: [{ propertyName: "input", first: true, predicate: ["skyCellEditorText"], descendants: true, read: ElementRef }], ngImport: i0, template: "<ng-container [formGroup]=\"editorForm\">\n <input\n formControlName=\"text\"\n type=\"text\"\n [attr.aria-label]=\"\n 'sky_ag_grid_cell_editor_text_aria_label'\n | skyLibResources: columnHeader:rowNumber\n \"\n [style.width.px]=\"columnWidth\"\n [style.height.px]=\"rowHeightWithoutBorders\"\n [maxlength]=\"maxlength\"\n #skyCellEditorText\n />\n</ng-container>\n", styles: ["input{border:none;padding-left:11px}\n"], dependencies: [{ kind: "directive", type: i1$1.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i1$1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1$1.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i1$1.MaxLengthValidator, selector: "[maxlength][formControlName],[maxlength][formControl],[maxlength][ngModel]", inputs: ["maxlength"] }, { kind: "directive", type: i1$1.FormGroupDirective, selector: "[formGroup]", inputs: ["formGroup"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "directive", type: i1$1.FormControlName, selector: "[formControlName]", inputs: ["formControlName", "disabled", "ngModel"], outputs: ["ngModelChange"] }, { kind: "pipe", type: i3.SkyLibResourcesPipe, name: "skyLibResources" }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
632
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellEditorTextComponent, decorators: [{
1127
633
  type: Component,
1128
- args: [{ selector: 'sky-ag-grid-cell-editor-datepicker', changeDetection: ChangeDetectionStrategy.OnPush, encapsulation: ViewEncapsulation.None, template: "<div\n class=\"sky-ag-grid-cell-editor-datepicker\"\n [formGroup]=\"editorForm\"\n [style.width.px]=\"columnWidthWithoutBorders\"\n>\n <sky-datepicker\n data-sky-id=\"cell-datepicker\"\n pickerClass=\"ag-custom-component-popup\"\n >\n <input\n formControlName=\"date\"\n skyDatepickerInput\n [minDate]=\"skyComponentProperties.minDate\"\n [maxDate]=\"skyComponentProperties.maxDate\"\n [dateFormat]=\"skyComponentProperties.dateFormat\"\n [startingDay]=\"skyComponentProperties.startingDay\"\n [skyDatepickerNoValidate]=\"skyComponentProperties.skyDatepickerNoValidate\"\n [style.height.px]=\"rowHeightWithoutBorders\"\n #skyCellEditorDatepickerInput\n />\n </sky-datepicker>\n</div>\n", styles: [".sky-ag-grid-cell-editor-datepicker{position:relative;top:1px;left:1px}.sky-ag-grid-cell-editor-datepicker sky-datepicker input.sky-form-control{box-shadow:none;border-width:1px;border-style:solid;border-color:transparent #cdcfd2 transparent transparent}.sky-ag-grid-cell-editor-datepicker sky-datepicker .sky-input-group-datepicker-btn{border-radius:0}:host-context(.sky-theme-modern) .sky-ag-grid-cell-editor-datepicker{position:static;top:initial;left:initial}:host-context(.sky-theme-modern) .sky-ag-grid-cell-editor-datepicker sky-datepicker input.sky-form-control{border-radius:0;border:1px solid #1870B8}:host-context(.sky-theme-modern) .sky-ag-grid-cell-editor-datepicker sky-datepicker input.sky-form-control:focus{border-width:2px!important}.sky-theme-modern .sky-ag-grid-cell-editor-datepicker{position:static;top:initial;left:initial}.sky-theme-modern .sky-ag-grid-cell-editor-datepicker sky-datepicker input.sky-form-control{border-radius:0;border:1px solid #1870B8}.sky-theme-modern .sky-ag-grid-cell-editor-datepicker sky-datepicker input.sky-form-control:focus{border-width:2px!important}\n"] }]
1129
- }], ctorParameters: function () {
1130
- return [{ type: i0.ChangeDetectorRef }, { type: i1$3.SkyThemeService, decorators: [{
1131
- type: Optional
1132
- }] }];
1133
- }, propDecorators: { datepickerInput: [{
634
+ args: [{ selector: 'sky-ag-grid-cell-editor-text', changeDetection: ChangeDetectionStrategy.OnPush, template: "<ng-container [formGroup]=\"editorForm\">\n <input\n formControlName=\"text\"\n type=\"text\"\n [attr.aria-label]=\"\n 'sky_ag_grid_cell_editor_text_aria_label'\n | skyLibResources: columnHeader:rowNumber\n \"\n [style.width.px]=\"columnWidth\"\n [style.height.px]=\"rowHeightWithoutBorders\"\n [maxlength]=\"maxlength\"\n #skyCellEditorText\n />\n</ng-container>\n", styles: ["input{border:none;padding-left:11px}\n"] }]
635
+ }], propDecorators: { input: [{
1134
636
  type: ViewChild,
1135
- args: ['skyCellEditorDatepickerInput', { read: ElementRef }]
637
+ args: ['skyCellEditorText', { read: ElementRef }]
1136
638
  }] } });
1137
639
 
1138
- class SkyAgGridCellEditorDatepickerModule {
1139
- }
1140
- SkyAgGridCellEditorDatepickerModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellEditorDatepickerModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
1141
- SkyAgGridCellEditorDatepickerModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellEditorDatepickerModule, declarations: [SkyAgGridCellEditorDatepickerComponent], imports: [SkyDatepickerModule, ReactiveFormsModule], exports: [SkyAgGridCellEditorDatepickerComponent] });
1142
- SkyAgGridCellEditorDatepickerModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellEditorDatepickerModule, imports: [SkyDatepickerModule, ReactiveFormsModule] });
1143
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellEditorDatepickerModule, decorators: [{
1144
- type: NgModule,
1145
- args: [{
1146
- imports: [SkyDatepickerModule, ReactiveFormsModule],
1147
- declarations: [SkyAgGridCellEditorDatepickerComponent],
1148
- exports: [SkyAgGridCellEditorDatepickerComponent],
1149
- }]
1150
- }] });
1151
-
1152
- /**
1153
- * @internal
1154
- */
1155
- function applySkyLookupPropertiesDefaults(skyLookupProperties) {
1156
- return {
1157
- addClick: skyLookupProperties.addClick || undefined,
1158
- ariaLabel: skyLookupProperties.ariaLabel || '',
1159
- autocompleteAttribute: skyLookupProperties.autocompleteAttribute || 'off',
1160
- data: skyLookupProperties.data || [],
1161
- debounceTime: skyLookupProperties.debounceTime || 0,
1162
- descriptorProperty: skyLookupProperties.descriptorProperty || 'name',
1163
- disabled: skyLookupProperties.disabled || false,
1164
- enableShowMore: skyLookupProperties.enableShowMore || false,
1165
- idProperty: skyLookupProperties.idProperty || undefined,
1166
- placeholderText: skyLookupProperties.placeholderText || '',
1167
- propertiesToSearch: skyLookupProperties.propertiesToSearch || undefined,
1168
- search: skyLookupProperties.search || undefined,
1169
- searchAsync: skyLookupProperties.searchAsync || undefined,
1170
- searchFilters: skyLookupProperties.searchFilters || [],
1171
- searchResultsLimit: skyLookupProperties.searchResultsLimit || undefined,
1172
- searchResultTemplate: skyLookupProperties.searchResultTemplate || undefined,
1173
- searchTextMinimumCharacters: skyLookupProperties.searchTextMinimumCharacters || 1,
1174
- selectMode: skyLookupProperties.selectMode || undefined,
1175
- showAddButton: skyLookupProperties.showAddButton || false,
1176
- showMoreConfig: skyLookupProperties.showMoreConfig || {},
1177
- wrapperClass: 'ag-custom-component-popup',
1178
- };
1179
- }
1180
-
1181
- var _SkyAgGridCellEditorLookupComponent_triggerType;
1182
640
  /**
1183
641
  * @internal
1184
642
  */
1185
- class SkyAgGridCellEditorLookupComponent {
1186
- constructor(changeDetector, elementRef) {
643
+ class SkyAgGridCellValidatorTooltipComponent {
644
+ constructor(changeDetector) {
1187
645
  this.changeDetector = changeDetector;
1188
- this.elementRef = elementRef;
1189
- this.isAlive = false;
1190
- this.editorForm = new UntypedFormGroup({
1191
- selection: new UntypedFormControl({
1192
- value: [],
1193
- disabled: false,
1194
- }),
1195
- });
1196
- this.useAsyncSearch = false;
1197
- _SkyAgGridCellEditorLookupComponent_triggerType.set(this, void 0);
646
+ this.popoverMessageStream = new Subject();
1198
647
  }
1199
- agInit(params) {
1200
- this.params = params;
1201
- if (!Array.isArray(this.params.value)) {
1202
- throw new Error(`Lookup value must be an array`);
1203
- }
1204
- __classPrivateFieldSet(this, _SkyAgGridCellEditorLookupComponent_triggerType, SkyAgGridCellEditorUtils.getEditorInitialAction(params), "f");
1205
- const control = this.editorForm.get('selection');
1206
- switch (__classPrivateFieldGet(this, _SkyAgGridCellEditorLookupComponent_triggerType, "f")) {
1207
- case SkyAgGridCellEditorInitialAction.Delete:
1208
- control.setValue([]);
1209
- break;
1210
- case SkyAgGridCellEditorInitialAction.Replace:
1211
- case SkyAgGridCellEditorInitialAction.Highlighted:
1212
- case SkyAgGridCellEditorInitialAction.Untouched:
1213
- default:
1214
- control.setValue(params.value);
1215
- break;
648
+ set params(value) {
649
+ var _a, _b, _c, _d, _e, _f, _g;
650
+ this.cellRendererParams = value;
651
+ /*istanbul ignore next*/
652
+ (_a = this.cellRendererParams.api) === null || _a === void 0 ? void 0 : _a.addEventListener(Events.EVENT_CELL_FOCUSED, (eventParams) => {
653
+ // We want to close any popovers that are opened when other cells are focused, but open a popover if the current cell is focused.
654
+ if (!(eventParams.column instanceof Column) ||
655
+ eventParams.column.getColId() !==
656
+ this.cellRendererParams.column.getColId() ||
657
+ eventParams.rowIndex !== this.cellRendererParams.rowIndex) {
658
+ this.hidePopover();
659
+ }
660
+ });
661
+ /*istanbul ignore next*/
662
+ (_b = this.cellRendererParams.eGridCell) === null || _b === void 0 ? void 0 : _b.addEventListener('keyup', (event) => {
663
+ if (['ArrowDown', 'ArrowLeft', 'ArrowRight', 'ArrowUp'].includes(event.key)) {
664
+ this.showPopover();
665
+ }
666
+ });
667
+ (_c = this.cellRendererParams.eGridCell) === null || _c === void 0 ? void 0 : _c.addEventListener('mouseenter', () => {
668
+ this.scheduleDelayedPopover();
669
+ });
670
+ (_d = this.cellRendererParams.eGridCell) === null || _d === void 0 ? void 0 : _d.addEventListener('mouseleave', () => {
671
+ this.hidePopover();
672
+ });
673
+ /*istanbul ignore next*/
674
+ (_e = this.cellRendererParams.api) === null || _e === void 0 ? void 0 : _e.addEventListener(Events.EVENT_CELL_EDITING_STARTED, () => {
675
+ this.hidePopover();
676
+ });
677
+ if (typeof ((_f = this.cellRendererParams.skyComponentProperties) === null || _f === void 0 ? void 0 : _f.validatorMessage) === 'function') {
678
+ this.validatorMessage =
679
+ this.cellRendererParams.skyComponentProperties.validatorMessage(this.cellRendererParams.value, this.cellRendererParams.data, this.cellRendererParams.rowIndex);
1216
680
  }
1217
- if (this.params.skyComponentProperties.disabled) {
1218
- control.disable();
681
+ else {
682
+ this.validatorMessage =
683
+ (_g = this.cellRendererParams.skyComponentProperties) === null || _g === void 0 ? void 0 : _g.validatorMessage;
1219
684
  }
1220
- this.skyComponentProperties = this.updateComponentProperties(this.params);
1221
- this.useAsyncSearch =
1222
- typeof this.skyComponentProperties.searchAsync === 'function';
1223
- this.isAlive = true;
1224
- this.width = this.params.column.getActualWidth();
1225
- this.params.column.addEventListener('uiColumnResized', (event) => {
1226
- this.width = event.column.getActualWidth();
1227
- this.changeDetector.markForCheck();
1228
- });
1229
685
  this.changeDetector.markForCheck();
1230
686
  }
1231
- isCancelAfterEnd() {
1232
- // Shut down components to commit values before final value syncs to grid.
1233
- this.isAlive = false;
1234
- this.changeDetector.detectChanges();
1235
- return false;
1236
- }
1237
- getGui() {
1238
- return this.elementRef.nativeElement;
1239
- }
1240
- getValue() {
1241
- return this.editorForm.get('selection').value;
687
+ hidePopover() {
688
+ this.cancelDelayedPopover();
689
+ this.popoverMessageStream.next({ type: SkyPopoverMessageType.Close });
1242
690
  }
1243
- isPopup() {
1244
- return true;
691
+ showPopover() {
692
+ this.cancelDelayedPopover();
693
+ this.popoverMessageStream.next({ type: SkyPopoverMessageType.Open });
1245
694
  }
1246
- afterGuiAttached() {
1247
- const lookupInput = this.elementRef.nativeElement.querySelector('.sky-lookup-input');
1248
- lookupInput.focus();
1249
- if (__classPrivateFieldGet(this, _SkyAgGridCellEditorLookupComponent_triggerType, "f") === SkyAgGridCellEditorInitialAction.Replace) {
1250
- lookupInput.select();
1251
- lookupInput.setRangeText(this.params.charPress);
1252
- // Ensure the cursor is at the end of the text.
1253
- lookupInput.setSelectionRange(lookupInput.value.length, lookupInput.value.length);
1254
- lookupInput.dispatchEvent(new Event('input'));
1255
- }
1256
- if (__classPrivateFieldGet(this, _SkyAgGridCellEditorLookupComponent_triggerType, "f") === SkyAgGridCellEditorInitialAction.Highlighted) {
1257
- lookupInput.select();
695
+ scheduleDelayedPopover() {
696
+ /* istanbul ignore else */
697
+ if (!this._hoverTimeout) {
698
+ this._hoverTimeout = window.setTimeout(() => {
699
+ this.showPopover();
700
+ }, 300);
1258
701
  }
1259
702
  }
1260
- updateComponentProperties(params) {
1261
- const skyLookupProperties = params.skyComponentProperties;
1262
- return applySkyLookupPropertiesDefaults(skyLookupProperties);
703
+ cancelDelayedPopover() {
704
+ if (this._hoverTimeout) {
705
+ window.clearTimeout(this._hoverTimeout);
706
+ this._hoverTimeout = undefined;
707
+ }
1263
708
  }
1264
709
  }
1265
- _SkyAgGridCellEditorLookupComponent_triggerType = new WeakMap();
1266
- SkyAgGridCellEditorLookupComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellEditorLookupComponent, deps: [{ token: i0.ChangeDetectorRef }, { token: i0.ElementRef }], target: i0.ɵɵFactoryTarget.Component });
1267
- SkyAgGridCellEditorLookupComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.2.0", type: SkyAgGridCellEditorLookupComponent, selector: "sky-ag-grid-cell-editor-lookup", host: { properties: { "style.width.px": "this.width" } }, ngImport: i0, template: "<sky-input-box\n *ngIf=\"isAlive && useAsyncSearch\"\n [disabled]=\"skyComponentProperties?.disabled\"\n [formGroup]=\"editorForm\"\n>\n <sky-lookup\n [ariaLabel]=\"skyComponentProperties?.ariaLabel\"\n [autocompleteAttribute]=\"skyComponentProperties?.autocompleteAttribute\"\n [data]=\"skyComponentProperties?.data\"\n [debounceTime]=\"skyComponentProperties?.debounceTime\"\n [descriptorProperty]=\"skyComponentProperties?.descriptorProperty\"\n [enableShowMore]=\"skyComponentProperties?.enableShowMore\"\n formControlName=\"selection\"\n [idProperty]=\"skyComponentProperties?.idProperty\"\n [placeholderText]=\"skyComponentProperties?.placeholderText\"\n [propertiesToSearch]=\"skyComponentProperties?.propertiesToSearch\"\n [searchFilters]=\"skyComponentProperties?.searchFilters\"\n [searchResultsLimit]=\"skyComponentProperties?.searchResultsLimit\"\n [searchResultTemplate]=\"skyComponentProperties?.searchResultTemplate\"\n [searchTextMinimumCharacters]=\"\n skyComponentProperties?.searchTextMinimumCharacters\n \"\n (searchAsync)=\"skyComponentProperties.searchAsync($event)\"\n [selectMode]=\"skyComponentProperties?.selectMode\"\n [showAddButton]=\"skyComponentProperties?.showAddButton\"\n [showMoreConfig]=\"skyComponentProperties?.showMoreConfig\"\n [wrapperClass]=\"skyComponentProperties?.wrapperClass\"\n >\n </sky-lookup>\n</sky-input-box>\n<sky-input-box\n *ngIf=\"isAlive && !useAsyncSearch\"\n [disabled]=\"skyComponentProperties?.disabled\"\n [formGroup]=\"editorForm\"\n>\n <sky-lookup\n [ariaLabel]=\"skyComponentProperties?.ariaLabel\"\n [autocompleteAttribute]=\"skyComponentProperties?.autocompleteAttribute\"\n [data]=\"skyComponentProperties?.data\"\n [debounceTime]=\"skyComponentProperties?.debounceTime\"\n [descriptorProperty]=\"skyComponentProperties?.descriptorProperty\"\n [enableShowMore]=\"skyComponentProperties?.enableShowMore\"\n formControlName=\"selection\"\n [idProperty]=\"skyComponentProperties?.idProperty\"\n [placeholderText]=\"skyComponentProperties?.placeholderText\"\n [propertiesToSearch]=\"skyComponentProperties?.propertiesToSearch\"\n [search]=\"skyComponentProperties?.search\"\n [searchFilters]=\"skyComponentProperties?.searchFilters\"\n [searchResultsLimit]=\"skyComponentProperties?.searchResultsLimit\"\n [searchResultTemplate]=\"skyComponentProperties?.searchResultTemplate\"\n [searchTextMinimumCharacters]=\"\n skyComponentProperties?.searchTextMinimumCharacters\n \"\n [selectMode]=\"skyComponentProperties?.selectMode\"\n [showAddButton]=\"skyComponentProperties?.showAddButton\"\n [showMoreConfig]=\"skyComponentProperties?.showMoreConfig\"\n [wrapperClass]=\"skyComponentProperties?.wrapperClass\"\n >\n </sky-lookup>\n</sky-input-box>\n", styles: [":host{display:block}\n"], dependencies: [{ kind: "directive", type: i2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i1$2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1$2.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i1$2.FormGroupDirective, selector: "[formGroup]", inputs: ["formGroup"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "directive", type: i1$2.FormControlName, selector: "[formControlName]", inputs: ["formControlName", "disabled", "ngModel"], outputs: ["ngModelChange"] }, { kind: "component", type: i3$1.λ10, selector: "sky-input-box", inputs: ["hasErrors", "disabled"] }, { kind: "component", type: i2$2.λ4, selector: "sky-lookup", inputs: ["ariaLabel", "ariaLabelledBy", "autocompleteAttribute", "data", "disabled", "enableShowMore", "placeholderText", "idProperty", "showAddButton", "showMoreConfig", "selectMode", "wrapperClass"], outputs: ["addClick"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
1268
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellEditorLookupComponent, decorators: [{
710
+ SkyAgGridCellValidatorTooltipComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellValidatorTooltipComponent, deps: [{ token: i0.ChangeDetectorRef }], target: i0.ɵɵFactoryTarget.Component });
711
+ SkyAgGridCellValidatorTooltipComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.2.0", type: SkyAgGridCellValidatorTooltipComponent, selector: "sky-ag-grid-cell-validator-tooltip", inputs: { params: "params" }, ngImport: i0, template: "<div\n [skyPopover]=\"validatorPopover\"\n [skyPopoverMessageStream]=\"popoverMessageStream\"\n class=\"sky-validator-cell\"\n>\n <ng-content></ng-content>\n <sky-status-indicator\n descriptionType=\"none\"\n indicatorType=\"danger\"\n class=\"sky-pull-right\"\n ></sky-status-indicator>\n</div>\n<sky-popover #validatorPopover popoverType=\"danger\">\n {{ validatorMessage }}\n</sky-popover>\n", styles: [":host div.sky-validator-cell{height:100%;width:100%}:host div.sky-validator-cell:focus{outline:none}\n"], dependencies: [{ kind: "component", type: i1$3.λ6, selector: "sky-popover", inputs: ["alignment", "dismissOnBlur", "placement", "popoverTitle", "popoverType"], outputs: ["popoverClosed", "popoverOpened"] }, { kind: "directive", type: i1$3.λ7, selector: "[skyPopover]", inputs: ["skyPopover", "skyPopoverAlignment", "skyPopoverMessageStream", "skyPopoverPlacement", "skyPopoverTrigger"] }, { kind: "component", type: i3$2.λ10, selector: "sky-status-indicator", inputs: ["indicatorType", "descriptionType", "customDescription"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
712
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellValidatorTooltipComponent, decorators: [{
1269
713
  type: Component,
1270
- args: [{ selector: 'sky-ag-grid-cell-editor-lookup', changeDetection: ChangeDetectionStrategy.OnPush, template: "<sky-input-box\n *ngIf=\"isAlive && useAsyncSearch\"\n [disabled]=\"skyComponentProperties?.disabled\"\n [formGroup]=\"editorForm\"\n>\n <sky-lookup\n [ariaLabel]=\"skyComponentProperties?.ariaLabel\"\n [autocompleteAttribute]=\"skyComponentProperties?.autocompleteAttribute\"\n [data]=\"skyComponentProperties?.data\"\n [debounceTime]=\"skyComponentProperties?.debounceTime\"\n [descriptorProperty]=\"skyComponentProperties?.descriptorProperty\"\n [enableShowMore]=\"skyComponentProperties?.enableShowMore\"\n formControlName=\"selection\"\n [idProperty]=\"skyComponentProperties?.idProperty\"\n [placeholderText]=\"skyComponentProperties?.placeholderText\"\n [propertiesToSearch]=\"skyComponentProperties?.propertiesToSearch\"\n [searchFilters]=\"skyComponentProperties?.searchFilters\"\n [searchResultsLimit]=\"skyComponentProperties?.searchResultsLimit\"\n [searchResultTemplate]=\"skyComponentProperties?.searchResultTemplate\"\n [searchTextMinimumCharacters]=\"\n skyComponentProperties?.searchTextMinimumCharacters\n \"\n (searchAsync)=\"skyComponentProperties.searchAsync($event)\"\n [selectMode]=\"skyComponentProperties?.selectMode\"\n [showAddButton]=\"skyComponentProperties?.showAddButton\"\n [showMoreConfig]=\"skyComponentProperties?.showMoreConfig\"\n [wrapperClass]=\"skyComponentProperties?.wrapperClass\"\n >\n </sky-lookup>\n</sky-input-box>\n<sky-input-box\n *ngIf=\"isAlive && !useAsyncSearch\"\n [disabled]=\"skyComponentProperties?.disabled\"\n [formGroup]=\"editorForm\"\n>\n <sky-lookup\n [ariaLabel]=\"skyComponentProperties?.ariaLabel\"\n [autocompleteAttribute]=\"skyComponentProperties?.autocompleteAttribute\"\n [data]=\"skyComponentProperties?.data\"\n [debounceTime]=\"skyComponentProperties?.debounceTime\"\n [descriptorProperty]=\"skyComponentProperties?.descriptorProperty\"\n [enableShowMore]=\"skyComponentProperties?.enableShowMore\"\n formControlName=\"selection\"\n [idProperty]=\"skyComponentProperties?.idProperty\"\n [placeholderText]=\"skyComponentProperties?.placeholderText\"\n [propertiesToSearch]=\"skyComponentProperties?.propertiesToSearch\"\n [search]=\"skyComponentProperties?.search\"\n [searchFilters]=\"skyComponentProperties?.searchFilters\"\n [searchResultsLimit]=\"skyComponentProperties?.searchResultsLimit\"\n [searchResultTemplate]=\"skyComponentProperties?.searchResultTemplate\"\n [searchTextMinimumCharacters]=\"\n skyComponentProperties?.searchTextMinimumCharacters\n \"\n [selectMode]=\"skyComponentProperties?.selectMode\"\n [showAddButton]=\"skyComponentProperties?.showAddButton\"\n [showMoreConfig]=\"skyComponentProperties?.showMoreConfig\"\n [wrapperClass]=\"skyComponentProperties?.wrapperClass\"\n >\n </sky-lookup>\n</sky-input-box>\n", styles: [":host{display:block}\n"] }]
1271
- }], ctorParameters: function () { return [{ type: i0.ChangeDetectorRef }, { type: i0.ElementRef }]; }, propDecorators: { width: [{
1272
- type: HostBinding,
1273
- args: ['style.width.px']
714
+ args: [{ selector: 'sky-ag-grid-cell-validator-tooltip', changeDetection: ChangeDetectionStrategy.OnPush, template: "<div\n [skyPopover]=\"validatorPopover\"\n [skyPopoverMessageStream]=\"popoverMessageStream\"\n class=\"sky-validator-cell\"\n>\n <ng-content></ng-content>\n <sky-status-indicator\n descriptionType=\"none\"\n indicatorType=\"danger\"\n class=\"sky-pull-right\"\n ></sky-status-indicator>\n</div>\n<sky-popover #validatorPopover popoverType=\"danger\">\n {{ validatorMessage }}\n</sky-popover>\n", styles: [":host div.sky-validator-cell{height:100%;width:100%}:host div.sky-validator-cell:focus{outline:none}\n"] }]
715
+ }], ctorParameters: function () { return [{ type: i0.ChangeDetectorRef }]; }, propDecorators: { params: [{
716
+ type: Input
1274
717
  }] } });
1275
718
 
1276
- class SkyAgGridCellEditorLookupModule {
1277
- }
1278
- SkyAgGridCellEditorLookupModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellEditorLookupModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
1279
- SkyAgGridCellEditorLookupModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellEditorLookupModule, declarations: [SkyAgGridCellEditorLookupComponent], imports: [CommonModule,
1280
- ReactiveFormsModule,
1281
- SkyI18nModule,
1282
- SkyInputBoxModule,
1283
- SkyLookupModule], exports: [SkyAgGridCellEditorLookupComponent] });
1284
- SkyAgGridCellEditorLookupModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellEditorLookupModule, imports: [CommonModule,
1285
- ReactiveFormsModule,
1286
- SkyI18nModule,
1287
- SkyInputBoxModule,
1288
- SkyLookupModule] });
1289
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellEditorLookupModule, decorators: [{
1290
- type: NgModule,
1291
- args: [{
1292
- declarations: [SkyAgGridCellEditorLookupComponent],
1293
- exports: [SkyAgGridCellEditorLookupComponent],
1294
- imports: [
1295
- CommonModule,
1296
- ReactiveFormsModule,
1297
- SkyI18nModule,
1298
- SkyInputBoxModule,
1299
- SkyLookupModule,
1300
- ],
1301
- }]
1302
- }] });
1303
-
1304
- var _SkyAgGridCellEditorNumberComponent_triggerType;
1305
719
  /**
1306
720
  * @internal
1307
721
  */
1308
- class SkyAgGridCellEditorNumberComponent {
722
+ class SkyAgGridCellRendererCurrencyComponent {
1309
723
  constructor() {
1310
- this.editorForm = new UntypedFormGroup({
1311
- number: new UntypedFormControl(),
1312
- });
1313
- _SkyAgGridCellEditorNumberComponent_triggerType.set(this, void 0);
724
+ this.skyComponentProperties = {};
725
+ this.numericOptions = {};
726
+ }
727
+ set params(value) {
728
+ this.agInit(value);
1314
729
  }
1315
730
  /**
1316
- * agInit is called by agGrid once after the editor is created and provides the editor with the information it needs.
1317
- * @param params The cell editor params that include data about the cell, column, row, and grid.
1318
- */
1319
- agInit(params) {
1320
- var _a, _b;
1321
- this.params = params;
1322
- __classPrivateFieldSet(this, _SkyAgGridCellEditorNumberComponent_triggerType, SkyAgGridCellEditorUtils.getEditorInitialAction(params), "f");
1323
- const control = this.editorForm.get('number');
1324
- switch (__classPrivateFieldGet(this, _SkyAgGridCellEditorNumberComponent_triggerType, "f")) {
1325
- case SkyAgGridCellEditorInitialAction.Delete:
1326
- control.setValue(undefined);
1327
- break;
1328
- case SkyAgGridCellEditorInitialAction.Replace:
1329
- control.setValue(parseFloat(this.params.charPress) || undefined);
1330
- break;
1331
- case SkyAgGridCellEditorInitialAction.Highlighted:
1332
- case SkyAgGridCellEditorInitialAction.Untouched:
1333
- default:
1334
- control.setValue(params.value);
1335
- break;
1336
- }
1337
- this.max = (_a = params.skyComponentProperties) === null || _a === void 0 ? void 0 : _a.max;
1338
- this.min = (_b = params.skyComponentProperties) === null || _b === void 0 ? void 0 : _b.min;
1339
- this.columnHeader = this.params.colDef.headerName;
1340
- this.rowNumber = this.params.rowIndex + 1;
1341
- this.columnWidth = this.params.column.getActualWidth();
1342
- this.rowHeightWithoutBorders =
1343
- this.params.node && this.params.node.rowHeight - 4;
1344
- }
1345
- /**
1346
- * afterGuiAttached is called by agGrid after the editor is rendered in the DOM. Once it is attached the editor is ready to be focused on.
1347
- */
1348
- afterGuiAttached() {
1349
- this.input.nativeElement.focus();
1350
- if (__classPrivateFieldGet(this, _SkyAgGridCellEditorNumberComponent_triggerType, "f") === SkyAgGridCellEditorInitialAction.Highlighted) {
1351
- this.input.nativeElement.select();
1352
- }
1353
- }
1354
- /**
1355
- * getValue is called by agGrid when editing is stopped to get the new value of the cell.
1356
- */
1357
- getValue() {
1358
- const val = this.editorForm.get('number').value;
1359
- return val !== undefined && val !== null ? val : undefined;
1360
- }
1361
- }
1362
- _SkyAgGridCellEditorNumberComponent_triggerType = new WeakMap();
1363
- SkyAgGridCellEditorNumberComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellEditorNumberComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
1364
- SkyAgGridCellEditorNumberComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.2.0", type: SkyAgGridCellEditorNumberComponent, selector: "sky-ag-grid-cell-editor-number", viewQueries: [{ propertyName: "input", first: true, predicate: ["skyCellEditorNumber"], descendants: true, read: ElementRef }], ngImport: i0, template: "<ng-container [formGroup]=\"editorForm\">\n <input\n formControlName=\"number\"\n type=\"number\"\n [attr.aria-label]=\"\n 'sky_ag_grid_cell_editor_number_aria_label'\n | skyLibResources: columnHeader:rowNumber\n \"\n [style.width.px]=\"columnWidth\"\n [style.height.px]=\"rowHeightWithoutBorders\"\n [max]=\"max\"\n [min]=\"min\"\n #skyCellEditorNumber\n />\n</ng-container>\n", styles: ["input{border:none;text-align:right}\n"], dependencies: [{ kind: "directive", type: i1$2.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i1$2.NumberValueAccessor, selector: "input[type=number][formControlName],input[type=number][formControl],input[type=number][ngModel]" }, { kind: "directive", type: i1$2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1$2.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i1$2.MinValidator, selector: "input[type=number][min][formControlName],input[type=number][min][formControl],input[type=number][min][ngModel]", inputs: ["min"] }, { kind: "directive", type: i1$2.MaxValidator, selector: "input[type=number][max][formControlName],input[type=number][max][formControl],input[type=number][max][ngModel]", inputs: ["max"] }, { kind: "directive", type: i1$2.FormGroupDirective, selector: "[formGroup]", inputs: ["formGroup"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "directive", type: i1$2.FormControlName, selector: "[formControlName]", inputs: ["formControlName", "disabled", "ngModel"], outputs: ["ngModelChange"] }, { kind: "pipe", type: i3.SkyLibResourcesPipe, name: "skyLibResources" }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
1365
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellEditorNumberComponent, decorators: [{
1366
- type: Component,
1367
- args: [{ selector: 'sky-ag-grid-cell-editor-number', changeDetection: ChangeDetectionStrategy.OnPush, template: "<ng-container [formGroup]=\"editorForm\">\n <input\n formControlName=\"number\"\n type=\"number\"\n [attr.aria-label]=\"\n 'sky_ag_grid_cell_editor_number_aria_label'\n | skyLibResources: columnHeader:rowNumber\n \"\n [style.width.px]=\"columnWidth\"\n [style.height.px]=\"rowHeightWithoutBorders\"\n [max]=\"max\"\n [min]=\"min\"\n #skyCellEditorNumber\n />\n</ng-container>\n", styles: ["input{border:none;text-align:right}\n"] }]
1368
- }], propDecorators: { input: [{
1369
- type: ViewChild,
1370
- args: ['skyCellEditorNumber', { read: ElementRef }]
1371
- }] } });
1372
-
1373
- class SkyAgGridCellEditorNumberModule {
1374
- }
1375
- SkyAgGridCellEditorNumberModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellEditorNumberModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
1376
- SkyAgGridCellEditorNumberModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellEditorNumberModule, declarations: [SkyAgGridCellEditorNumberComponent], imports: [SkyAgGridResourcesModule, ReactiveFormsModule], exports: [SkyAgGridCellEditorNumberComponent] });
1377
- SkyAgGridCellEditorNumberModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellEditorNumberModule, imports: [SkyAgGridResourcesModule, ReactiveFormsModule] });
1378
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellEditorNumberModule, decorators: [{
1379
- type: NgModule,
1380
- args: [{
1381
- imports: [SkyAgGridResourcesModule, ReactiveFormsModule],
1382
- declarations: [SkyAgGridCellEditorNumberComponent],
1383
- exports: [SkyAgGridCellEditorNumberComponent],
1384
- }]
1385
- }] });
1386
-
1387
- var _SkyAgGridCellEditorTextComponent_triggerType;
1388
- /**
1389
- * @internal
1390
- */
1391
- class SkyAgGridCellEditorTextComponent {
1392
- constructor() {
1393
- this.editorForm = new UntypedFormGroup({
1394
- text: new UntypedFormControl(),
1395
- });
1396
- _SkyAgGridCellEditorTextComponent_triggerType.set(this, void 0);
1397
- }
1398
- /**
1399
- * agInit is called by agGrid once after the editor is created and provides the editor with the information it needs.
1400
- * @param params The cell editor params that include data about the cell, column, row, and grid.
1401
- */
1402
- agInit(params) {
1403
- var _a;
1404
- this.params = params;
1405
- __classPrivateFieldSet(this, _SkyAgGridCellEditorTextComponent_triggerType, SkyAgGridCellEditorUtils.getEditorInitialAction(params), "f");
1406
- const control = this.editorForm.get('text');
1407
- switch (__classPrivateFieldGet(this, _SkyAgGridCellEditorTextComponent_triggerType, "f")) {
1408
- case SkyAgGridCellEditorInitialAction.Delete:
1409
- control.setValue(undefined);
1410
- break;
1411
- case SkyAgGridCellEditorInitialAction.Replace:
1412
- control.setValue(params.charPress);
1413
- break;
1414
- case SkyAgGridCellEditorInitialAction.Highlighted:
1415
- case SkyAgGridCellEditorInitialAction.Untouched:
1416
- default:
1417
- control.setValue(params.value);
1418
- break;
1419
- }
1420
- this.maxlength = (_a = params.skyComponentProperties) === null || _a === void 0 ? void 0 : _a.maxlength;
1421
- this.columnHeader = this.params.colDef.headerName;
1422
- this.rowNumber = this.params.rowIndex + 1;
1423
- this.columnWidth = this.params.column.getActualWidth();
1424
- this.rowHeightWithoutBorders =
1425
- this.params.node && this.params.node.rowHeight - 4;
1426
- }
1427
- /**
1428
- * afterGuiAttached is called by agGrid after the editor is rendered in the DOM. Once it is attached the editor is ready to be focused on.
1429
- */
1430
- afterGuiAttached() {
1431
- this.input.nativeElement.focus();
1432
- if (__classPrivateFieldGet(this, _SkyAgGridCellEditorTextComponent_triggerType, "f") === SkyAgGridCellEditorInitialAction.Highlighted) {
1433
- this.input.nativeElement.select();
1434
- }
1435
- }
1436
- /**
1437
- * getValue is called by agGrid when editing is stopped to get the new value of the cell.
1438
- */
1439
- getValue() {
1440
- return this.editorForm.get('text').value || undefined;
1441
- }
1442
- }
1443
- _SkyAgGridCellEditorTextComponent_triggerType = new WeakMap();
1444
- SkyAgGridCellEditorTextComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellEditorTextComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
1445
- SkyAgGridCellEditorTextComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.2.0", type: SkyAgGridCellEditorTextComponent, selector: "sky-ag-grid-cell-editor-text", viewQueries: [{ propertyName: "input", first: true, predicate: ["skyCellEditorText"], descendants: true, read: ElementRef }], ngImport: i0, template: "<ng-container [formGroup]=\"editorForm\">\n <input\n formControlName=\"text\"\n type=\"text\"\n [attr.aria-label]=\"\n 'sky_ag_grid_cell_editor_text_aria_label'\n | skyLibResources: columnHeader:rowNumber\n \"\n [style.width.px]=\"columnWidth\"\n [style.height.px]=\"rowHeightWithoutBorders\"\n [maxlength]=\"maxlength\"\n #skyCellEditorText\n />\n</ng-container>\n", styles: ["input{border:none;padding-left:11px}\n"], dependencies: [{ kind: "directive", type: i1$2.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i1$2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1$2.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i1$2.MaxLengthValidator, selector: "[maxlength][formControlName],[maxlength][formControl],[maxlength][ngModel]", inputs: ["maxlength"] }, { kind: "directive", type: i1$2.FormGroupDirective, selector: "[formGroup]", inputs: ["formGroup"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "directive", type: i1$2.FormControlName, selector: "[formControlName]", inputs: ["formControlName", "disabled", "ngModel"], outputs: ["ngModelChange"] }, { kind: "pipe", type: i3.SkyLibResourcesPipe, name: "skyLibResources" }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
1446
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellEditorTextComponent, decorators: [{
1447
- type: Component,
1448
- args: [{ selector: 'sky-ag-grid-cell-editor-text', changeDetection: ChangeDetectionStrategy.OnPush, template: "<ng-container [formGroup]=\"editorForm\">\n <input\n formControlName=\"text\"\n type=\"text\"\n [attr.aria-label]=\"\n 'sky_ag_grid_cell_editor_text_aria_label'\n | skyLibResources: columnHeader:rowNumber\n \"\n [style.width.px]=\"columnWidth\"\n [style.height.px]=\"rowHeightWithoutBorders\"\n [maxlength]=\"maxlength\"\n #skyCellEditorText\n />\n</ng-container>\n", styles: ["input{border:none;padding-left:11px}\n"] }]
1449
- }], propDecorators: { input: [{
1450
- type: ViewChild,
1451
- args: ['skyCellEditorText', { read: ElementRef }]
1452
- }] } });
1453
-
1454
- class SkyAgGridCellEditorTextModule {
1455
- }
1456
- SkyAgGridCellEditorTextModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellEditorTextModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
1457
- SkyAgGridCellEditorTextModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellEditorTextModule, declarations: [SkyAgGridCellEditorTextComponent], imports: [SkyAgGridResourcesModule, ReactiveFormsModule], exports: [SkyAgGridCellEditorTextComponent] });
1458
- SkyAgGridCellEditorTextModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellEditorTextModule, imports: [SkyAgGridResourcesModule, ReactiveFormsModule] });
1459
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellEditorTextModule, decorators: [{
1460
- type: NgModule,
1461
- args: [{
1462
- imports: [SkyAgGridResourcesModule, ReactiveFormsModule],
1463
- declarations: [SkyAgGridCellEditorTextComponent],
1464
- exports: [SkyAgGridCellEditorTextComponent],
1465
- }]
1466
- }] });
1467
-
1468
- /**
1469
- * @internal
1470
- */
1471
- class SkyAgGridCellValidatorTooltipComponent {
1472
- constructor(changeDetector) {
1473
- this.changeDetector = changeDetector;
1474
- this.popoverMessageStream = new Subject();
1475
- }
1476
- set params(value) {
1477
- var _a, _b, _c, _d, _e, _f, _g;
1478
- this.cellRendererParams = value;
1479
- /*istanbul ignore next*/
1480
- (_a = this.cellRendererParams.api) === null || _a === void 0 ? void 0 : _a.addEventListener(Events.EVENT_CELL_FOCUSED, (eventParams) => {
1481
- // We want to close any popovers that are opened when other cells are focused, but open a popover if the current cell is focused.
1482
- if (eventParams.column.getColId() !==
1483
- this.cellRendererParams.column.getColId() ||
1484
- eventParams.rowIndex !== this.cellRendererParams.rowIndex) {
1485
- this.hidePopover();
1486
- }
1487
- });
1488
- /*istanbul ignore next*/
1489
- (_b = this.cellRendererParams.eGridCell) === null || _b === void 0 ? void 0 : _b.addEventListener('keyup', (event) => {
1490
- if (['ArrowDown', 'ArrowLeft', 'ArrowRight', 'ArrowUp'].includes(event.key)) {
1491
- this.showPopover();
1492
- }
1493
- });
1494
- (_c = this.cellRendererParams.eGridCell) === null || _c === void 0 ? void 0 : _c.addEventListener('mouseenter', () => {
1495
- this.scheduleDelayedPopover();
1496
- });
1497
- (_d = this.cellRendererParams.eGridCell) === null || _d === void 0 ? void 0 : _d.addEventListener('mouseleave', () => {
1498
- this.hidePopover();
1499
- });
1500
- /*istanbul ignore next*/
1501
- (_e = this.cellRendererParams.api) === null || _e === void 0 ? void 0 : _e.addEventListener(Events.EVENT_CELL_EDITING_STARTED, () => {
1502
- this.hidePopover();
1503
- });
1504
- if (typeof ((_f = this.cellRendererParams.skyComponentProperties) === null || _f === void 0 ? void 0 : _f.validatorMessage) === 'function') {
1505
- this.validatorMessage =
1506
- this.cellRendererParams.skyComponentProperties.validatorMessage(this.cellRendererParams.value, this.cellRendererParams.data, this.cellRendererParams.rowIndex);
1507
- }
1508
- else {
1509
- this.validatorMessage =
1510
- (_g = this.cellRendererParams.skyComponentProperties) === null || _g === void 0 ? void 0 : _g.validatorMessage;
1511
- }
1512
- this.changeDetector.markForCheck();
1513
- }
1514
- hidePopover() {
1515
- this.cancelDelayedPopover();
1516
- this.popoverMessageStream.next({ type: SkyPopoverMessageType.Close });
1517
- }
1518
- showPopover() {
1519
- this.cancelDelayedPopover();
1520
- this.popoverMessageStream.next({ type: SkyPopoverMessageType.Open });
1521
- }
1522
- scheduleDelayedPopover() {
1523
- /* istanbul ignore else */
1524
- if (!this._hoverTimeout) {
1525
- this._hoverTimeout = window.setTimeout(() => {
1526
- this.showPopover();
1527
- }, 300);
1528
- }
1529
- }
1530
- cancelDelayedPopover() {
1531
- if (this._hoverTimeout) {
1532
- window.clearTimeout(this._hoverTimeout);
1533
- this._hoverTimeout = undefined;
1534
- }
1535
- }
1536
- }
1537
- SkyAgGridCellValidatorTooltipComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellValidatorTooltipComponent, deps: [{ token: i0.ChangeDetectorRef }], target: i0.ɵɵFactoryTarget.Component });
1538
- SkyAgGridCellValidatorTooltipComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.2.0", type: SkyAgGridCellValidatorTooltipComponent, selector: "sky-ag-grid-cell-validator-tooltip", inputs: { params: "params" }, ngImport: i0, template: "<div\n [skyPopover]=\"validatorPopover\"\n [skyPopoverMessageStream]=\"popoverMessageStream\"\n class=\"sky-validator-cell\"\n>\n <ng-content></ng-content>\n <sky-status-indicator\n descriptionType=\"none\"\n indicatorType=\"danger\"\n class=\"sky-pull-right\"\n ></sky-status-indicator>\n</div>\n<sky-popover #validatorPopover popoverType=\"danger\">\n {{ validatorMessage }}\n</sky-popover>\n", styles: [":host div.sky-validator-cell{height:100%;width:100%}:host div.sky-validator-cell:focus{outline:none}\n"], dependencies: [{ kind: "component", type: i1$4.λ6, selector: "sky-popover", inputs: ["alignment", "dismissOnBlur", "placement", "popoverTitle", "popoverType"], outputs: ["popoverClosed", "popoverOpened"] }, { kind: "directive", type: i1$4.λ7, selector: "[skyPopover]", inputs: ["skyPopover", "skyPopoverAlignment", "skyPopoverMessageStream", "skyPopoverPlacement", "skyPopoverTrigger"] }, { kind: "component", type: i3$2.λ10, selector: "sky-status-indicator", inputs: ["indicatorType", "descriptionType", "customDescription"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
1539
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellValidatorTooltipComponent, decorators: [{
1540
- type: Component,
1541
- args: [{ selector: 'sky-ag-grid-cell-validator-tooltip', changeDetection: ChangeDetectionStrategy.OnPush, template: "<div\n [skyPopover]=\"validatorPopover\"\n [skyPopoverMessageStream]=\"popoverMessageStream\"\n class=\"sky-validator-cell\"\n>\n <ng-content></ng-content>\n <sky-status-indicator\n descriptionType=\"none\"\n indicatorType=\"danger\"\n class=\"sky-pull-right\"\n ></sky-status-indicator>\n</div>\n<sky-popover #validatorPopover popoverType=\"danger\">\n {{ validatorMessage }}\n</sky-popover>\n", styles: [":host div.sky-validator-cell{height:100%;width:100%}:host div.sky-validator-cell:focus{outline:none}\n"] }]
1542
- }], ctorParameters: function () { return [{ type: i0.ChangeDetectorRef }]; }, propDecorators: { params: [{
1543
- type: Input
1544
- }] } });
1545
-
1546
- class SkyAgGridCellValidatorModule {
1547
- }
1548
- SkyAgGridCellValidatorModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellValidatorModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
1549
- SkyAgGridCellValidatorModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellValidatorModule, declarations: [SkyAgGridCellValidatorTooltipComponent], imports: [CommonModule, SkyPopoverModule, SkyStatusIndicatorModule], exports: [SkyAgGridCellValidatorTooltipComponent] });
1550
- SkyAgGridCellValidatorModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellValidatorModule, imports: [CommonModule, SkyPopoverModule, SkyStatusIndicatorModule] });
1551
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellValidatorModule, decorators: [{
1552
- type: NgModule,
1553
- args: [{
1554
- declarations: [SkyAgGridCellValidatorTooltipComponent],
1555
- exports: [SkyAgGridCellValidatorTooltipComponent],
1556
- imports: [CommonModule, SkyPopoverModule, SkyStatusIndicatorModule],
1557
- }]
1558
- }] });
1559
-
1560
- /**
1561
- * @internal
1562
- */
1563
- class SkyAgGridCellRendererCurrencyComponent {
1564
- constructor() {
1565
- this.skyComponentProperties = {};
1566
- this.numericOptions = {};
1567
- }
1568
- set params(value) {
1569
- this.agInit(value);
1570
- }
1571
- /**
1572
- * agInit is called by agGrid once after the renderer is created and provides the renderer with the information it needs.
1573
- * @param params The cell renderer params that include data about the cell, column, row, and grid.
731
+ * agInit is called by agGrid once after the renderer is created and provides the renderer with the information it needs.
732
+ * @param params The cell renderer params that include data about the cell, column, row, and grid.
1574
733
  */
1575
734
  agInit(params) {
1576
735
  this.updateProperties(params);
@@ -1628,7 +787,7 @@ class SkyAgGridCellRendererCurrencyValidatorComponent {
1628
787
  }
1629
788
  }
1630
789
  SkyAgGridCellRendererCurrencyValidatorComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellRendererCurrencyValidatorComponent, deps: [{ token: i0.ChangeDetectorRef }], target: i0.ɵɵFactoryTarget.Component });
1631
- SkyAgGridCellRendererCurrencyValidatorComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.2.0", type: SkyAgGridCellRendererCurrencyValidatorComponent, selector: "sky-ag-grid-cell-renderer-currency-validator", inputs: { parameters: "parameters" }, ngImport: i0, template: "<sky-ag-grid-cell-validator-tooltip [params]=\"cellRendererParams\">\n <sky-ag-grid-cell-renderer-currency\n *ngIf=\"isNumeric(cellRendererParams.value); else rawValue\"\n [params]=\"cellRendererParams\"\n ></sky-ag-grid-cell-renderer-currency>\n <ng-template #rawValue>{{ cellRendererParams.value }}</ng-template>\n</sky-ag-grid-cell-validator-tooltip>\n", dependencies: [{ kind: "directive", type: i2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { 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 });
790
+ SkyAgGridCellRendererCurrencyValidatorComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.2.0", type: SkyAgGridCellRendererCurrencyValidatorComponent, selector: "sky-ag-grid-cell-renderer-currency-validator", inputs: { parameters: "parameters" }, ngImport: i0, template: "<sky-ag-grid-cell-validator-tooltip [params]=\"cellRendererParams\">\n <sky-ag-grid-cell-renderer-currency\n *ngIf=\"isNumeric(cellRendererParams.value); else rawValue\"\n [params]=\"cellRendererParams\"\n ></sky-ag-grid-cell-renderer-currency>\n <ng-template #rawValue>{{ cellRendererParams.value }}</ng-template>\n</sky-ag-grid-cell-validator-tooltip>\n", dependencies: [{ kind: "directive", type: i2$3.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { 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 });
1632
791
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellRendererCurrencyValidatorComponent, decorators: [{
1633
792
  type: Component,
1634
793
  args: [{ selector: 'sky-ag-grid-cell-renderer-currency-validator', changeDetection: ChangeDetectionStrategy.OnPush, template: "<sky-ag-grid-cell-validator-tooltip [params]=\"cellRendererParams\">\n <sky-ag-grid-cell-renderer-currency\n *ngIf=\"isNumeric(cellRendererParams.value); else rawValue\"\n [params]=\"cellRendererParams\"\n ></sky-ag-grid-cell-renderer-currency>\n <ng-template #rawValue>{{ cellRendererParams.value }}</ng-template>\n</sky-ag-grid-cell-validator-tooltip>\n" }]
@@ -1636,83 +795,33 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.0", ngImpor
1636
795
  type: Input
1637
796
  }] } });
1638
797
 
1639
- class SkyAgGridCellRendererCurrencyModule {
1640
- }
1641
- SkyAgGridCellRendererCurrencyModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellRendererCurrencyModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
1642
- SkyAgGridCellRendererCurrencyModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellRendererCurrencyModule, declarations: [SkyAgGridCellRendererCurrencyComponent,
1643
- SkyAgGridCellRendererCurrencyValidatorComponent], imports: [CommonModule,
1644
- SkyAgGridResourcesModule,
1645
- SkyAgGridCellValidatorModule,
1646
- FormsModule,
1647
- SkyNumericModule], exports: [SkyAgGridCellRendererCurrencyComponent,
1648
- SkyAgGridCellRendererCurrencyValidatorComponent] });
1649
- SkyAgGridCellRendererCurrencyModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellRendererCurrencyModule, imports: [CommonModule,
1650
- SkyAgGridResourcesModule,
1651
- SkyAgGridCellValidatorModule,
1652
- FormsModule,
1653
- SkyNumericModule] });
1654
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellRendererCurrencyModule, decorators: [{
1655
- type: NgModule,
1656
- args: [{
1657
- imports: [
1658
- CommonModule,
1659
- SkyAgGridResourcesModule,
1660
- SkyAgGridCellValidatorModule,
1661
- FormsModule,
1662
- SkyNumericModule,
1663
- ],
1664
- declarations: [
1665
- SkyAgGridCellRendererCurrencyComponent,
1666
- SkyAgGridCellRendererCurrencyValidatorComponent,
1667
- ],
1668
- exports: [
1669
- SkyAgGridCellRendererCurrencyComponent,
1670
- SkyAgGridCellRendererCurrencyValidatorComponent,
1671
- ],
1672
- }]
1673
- }] });
1674
-
1675
- /**
1676
- * @internal
1677
- */
1678
- class SkyAgGridCellRendererLookupComponent {
1679
- constructor(changeDetector) {
1680
- this.changeDetector = changeDetector;
1681
- this.value = '';
1682
- this.summaryCount = 0;
1683
- }
1684
- agInit(params) {
1685
- var _a;
1686
- this.summaryCount = ((_a = params.value) === null || _a === void 0 ? void 0 : _a.length) || 0;
1687
- this.value = `${params.valueFormatted}`;
1688
- this.changeDetector.markForCheck();
1689
- }
1690
- refresh(params) {
1691
- this.agInit(params);
1692
- return true;
1693
- }
798
+ /**
799
+ * @internal
800
+ */
801
+ class SkyAgGridCellRendererLookupComponent {
802
+ constructor(changeDetector) {
803
+ this.changeDetector = changeDetector;
804
+ this.value = '';
805
+ this.summaryCount = 0;
806
+ }
807
+ agInit(params) {
808
+ var _a;
809
+ this.summaryCount = ((_a = params.value) === null || _a === void 0 ? void 0 : _a.length) || 0;
810
+ this.value = `${params.valueFormatted}`;
811
+ this.changeDetector.markForCheck();
812
+ }
813
+ refresh(params) {
814
+ this.agInit(params);
815
+ return true;
816
+ }
1694
817
  }
1695
818
  SkyAgGridCellRendererLookupComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellRendererLookupComponent, deps: [{ token: i0.ChangeDetectorRef }], target: i0.ɵɵFactoryTarget.Component });
1696
- SkyAgGridCellRendererLookupComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.2.0", type: SkyAgGridCellRendererLookupComponent, selector: "sky-cell-renderer-lookup", ngImport: i0, template: "<ng-container *ngIf=\"summaryCount > 5; else showValue\">\n {{ 'skyux_lookup_tokens_summary' | skyLibResources: summaryCount }}\n</ng-container>\n<ng-template #showValue>{{ value }}</ng-template>\n", styles: [":host{overflow:hidden;white-space:nowrap;text-overflow:ellipsis}\n"], dependencies: [{ kind: "directive", type: i2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "pipe", type: i3.SkyLibResourcesPipe, name: "skyLibResources" }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
819
+ SkyAgGridCellRendererLookupComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.2.0", type: SkyAgGridCellRendererLookupComponent, selector: "sky-cell-renderer-lookup", ngImport: i0, template: "<ng-container *ngIf=\"summaryCount > 5; else showValue\">\n {{ 'skyux_lookup_tokens_summary' | skyLibResources: summaryCount }}\n</ng-container>\n<ng-template #showValue>{{ value }}</ng-template>\n", styles: [":host{overflow:hidden;white-space:nowrap;text-overflow:ellipsis}\n"], dependencies: [{ kind: "directive", type: i2$3.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "pipe", type: i3.SkyLibResourcesPipe, name: "skyLibResources" }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
1697
820
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellRendererLookupComponent, decorators: [{
1698
821
  type: Component,
1699
822
  args: [{ selector: 'sky-cell-renderer-lookup', changeDetection: ChangeDetectionStrategy.OnPush, template: "<ng-container *ngIf=\"summaryCount > 5; else showValue\">\n {{ 'skyux_lookup_tokens_summary' | skyLibResources: summaryCount }}\n</ng-container>\n<ng-template #showValue>{{ value }}</ng-template>\n", styles: [":host{overflow:hidden;white-space:nowrap;text-overflow:ellipsis}\n"] }]
1700
823
  }], ctorParameters: function () { return [{ type: i0.ChangeDetectorRef }]; } });
1701
824
 
1702
- class SkyAgGridCellRendererLookupModule {
1703
- }
1704
- SkyAgGridCellRendererLookupModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellRendererLookupModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
1705
- SkyAgGridCellRendererLookupModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellRendererLookupModule, declarations: [SkyAgGridCellRendererLookupComponent], imports: [CommonModule, SkyAgGridResourcesModule], exports: [SkyAgGridCellRendererLookupComponent] });
1706
- SkyAgGridCellRendererLookupModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellRendererLookupModule, imports: [CommonModule, SkyAgGridResourcesModule] });
1707
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellRendererLookupModule, decorators: [{
1708
- type: NgModule,
1709
- args: [{
1710
- declarations: [SkyAgGridCellRendererLookupComponent],
1711
- exports: [SkyAgGridCellRendererLookupComponent],
1712
- imports: [CommonModule, SkyAgGridResourcesModule],
1713
- }]
1714
- }] });
1715
-
1716
825
  /**
1717
826
  * @internal
1718
827
  */
@@ -1763,26 +872,12 @@ class SkyAgGridCellRendererRowSelectorComponent {
1763
872
  }
1764
873
  }
1765
874
  SkyAgGridCellRendererRowSelectorComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellRendererRowSelectorComponent, deps: [{ token: i0.ChangeDetectorRef }], target: i0.ɵɵFactoryTarget.Component });
1766
- SkyAgGridCellRendererRowSelectorComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.2.0", type: SkyAgGridCellRendererRowSelectorComponent, selector: "sky-ag-grid-cell-renderer-row-selector", ngImport: i0, template: "<sky-checkbox\n data-sky-id=\"row-checkbox\"\n [tabindex]=\"-1\"\n [label]=\"'sky_ag_grid_row_selector_aria_label' | skyLibResources: rowNumber\"\n [attr.aria-label]=\"\n 'sky_ag_grid_row_selector_aria_label' | skyLibResources: rowNumber\n \"\n [(ngModel)]=\"checked\"\n (change)=\"updateRow()\"\n>\n</sky-checkbox>\n", styles: [".sky-ag-grid-cell-row-selector .sky-switch-control{top:-6px}\n"], dependencies: [{ kind: "component", type: i3$1.λ3, selector: "sky-checkbox", inputs: ["label", "labelledBy", "id", "disabled", "tabindex", "name", "icon", "checkboxType", "checked", "required"], outputs: ["change", "checkedChange", "disabledChange"] }, { kind: "directive", type: i1$2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1$2.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "pipe", type: i3.SkyLibResourcesPipe, name: "skyLibResources" }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
875
+ SkyAgGridCellRendererRowSelectorComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.2.0", type: SkyAgGridCellRendererRowSelectorComponent, selector: "sky-ag-grid-cell-renderer-row-selector", ngImport: i0, template: "<sky-checkbox\n data-sky-id=\"row-checkbox\"\n [tabindex]=\"-1\"\n [label]=\"'sky_ag_grid_row_selector_aria_label' | skyLibResources: rowNumber\"\n [attr.aria-label]=\"\n 'sky_ag_grid_row_selector_aria_label' | skyLibResources: rowNumber\n \"\n [(ngModel)]=\"checked\"\n (change)=\"updateRow()\"\n>\n</sky-checkbox>\n", styles: [".sky-ag-grid-cell-row-selector .sky-switch-control{top:-6px}\n"], dependencies: [{ kind: "component", type: i3$1.λ3, selector: "sky-checkbox", inputs: ["label", "labelledBy", "id", "disabled", "tabindex", "name", "icon", "checkboxType", "checked", "required"], outputs: ["change", "checkedChange", "disabledChange"] }, { kind: "directive", type: i1$1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1$1.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "pipe", type: i3.SkyLibResourcesPipe, name: "skyLibResources" }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
1767
876
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellRendererRowSelectorComponent, decorators: [{
1768
877
  type: Component,
1769
878
  args: [{ selector: 'sky-ag-grid-cell-renderer-row-selector', changeDetection: ChangeDetectionStrategy.OnPush, encapsulation: ViewEncapsulation.None, template: "<sky-checkbox\n data-sky-id=\"row-checkbox\"\n [tabindex]=\"-1\"\n [label]=\"'sky_ag_grid_row_selector_aria_label' | skyLibResources: rowNumber\"\n [attr.aria-label]=\"\n 'sky_ag_grid_row_selector_aria_label' | skyLibResources: rowNumber\n \"\n [(ngModel)]=\"checked\"\n (change)=\"updateRow()\"\n>\n</sky-checkbox>\n", styles: [".sky-ag-grid-cell-row-selector .sky-switch-control{top:-6px}\n"] }]
1770
879
  }], ctorParameters: function () { return [{ type: i0.ChangeDetectorRef }]; } });
1771
880
 
1772
- class SkyAgGridCellRendererRowSelectorModule {
1773
- }
1774
- SkyAgGridCellRendererRowSelectorModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellRendererRowSelectorModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
1775
- SkyAgGridCellRendererRowSelectorModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellRendererRowSelectorModule, declarations: [SkyAgGridCellRendererRowSelectorComponent], imports: [SkyAgGridResourcesModule, SkyCheckboxModule, FormsModule], exports: [SkyAgGridCellRendererRowSelectorComponent] });
1776
- SkyAgGridCellRendererRowSelectorModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellRendererRowSelectorModule, imports: [SkyAgGridResourcesModule, SkyCheckboxModule, FormsModule] });
1777
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellRendererRowSelectorModule, decorators: [{
1778
- type: NgModule,
1779
- args: [{
1780
- imports: [SkyAgGridResourcesModule, SkyCheckboxModule, FormsModule],
1781
- declarations: [SkyAgGridCellRendererRowSelectorComponent],
1782
- exports: [SkyAgGridCellRendererRowSelectorComponent],
1783
- }]
1784
- }] });
1785
-
1786
881
  /**
1787
882
  * @internal
1788
883
  */
@@ -1817,20 +912,6 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.0", ngImpor
1817
912
  type: Input
1818
913
  }] } });
1819
914
 
1820
- class SkyAgGridCellRendererValidatorTooltipModule {
1821
- }
1822
- SkyAgGridCellRendererValidatorTooltipModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellRendererValidatorTooltipModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
1823
- SkyAgGridCellRendererValidatorTooltipModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellRendererValidatorTooltipModule, declarations: [SkyAgGridCellRendererValidatorTooltipComponent], imports: [SkyAgGridCellValidatorModule], exports: [SkyAgGridCellRendererValidatorTooltipComponent] });
1824
- SkyAgGridCellRendererValidatorTooltipModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellRendererValidatorTooltipModule, imports: [SkyAgGridCellValidatorModule] });
1825
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellRendererValidatorTooltipModule, decorators: [{
1826
- type: NgModule,
1827
- args: [{
1828
- declarations: [SkyAgGridCellRendererValidatorTooltipComponent],
1829
- exports: [SkyAgGridCellRendererValidatorTooltipComponent],
1830
- imports: [SkyAgGridCellValidatorModule],
1831
- }]
1832
- }] });
1833
-
1834
915
  /**
1835
916
  * To display a help button beside the column group header, create a component that includes the help button element,
1836
917
  * such as `sky-help-inline`, include a `SkyAgGridHeaderGroupInfo` parameter in the constructor to access the column
@@ -1920,7 +1001,7 @@ _SkyAgGridHeaderGroupComponent_columnGroup = new WeakMap(), _SkyAgGridHeaderGrou
1920
1001
  }
1921
1002
  };
1922
1003
  SkyAgGridHeaderGroupComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridHeaderGroupComponent, deps: [{ token: i0.ChangeDetectorRef }, { token: i1.SkyDynamicComponentService }], target: i0.ɵɵFactoryTarget.Component });
1923
- SkyAgGridHeaderGroupComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.2.0", type: SkyAgGridHeaderGroupComponent, selector: "sky-header-group", viewQueries: [{ propertyName: "inlineHelpContainer", first: true, predicate: ["inlineHelpContainer"], descendants: true, read: ElementRef, static: true }], ngImport: i0, template: "<span class=\"header-group-text\" role=\"presentation\">{{\n params?.displayName\n}}</span>\n<button\n *ngIf=\"isExpanded$ | async; else openIcons\"\n class=\"sky-btn sky-btn-icon-borderless\"\n (click)=\"setExpanded(false)\"\n [attr.aria-label]=\"\n 'sky_ag_grid_column_group_header_collapse_aria_label'\n | skyLibResources: params?.displayName\n \"\n>\n <sky-icon *skyThemeIf=\"'default'\" icon=\"angle-double-left\"></sky-icon>\n <sky-icon\n *skyThemeIf=\"'modern'\"\n icon=\"double-chevron-left\"\n iconType=\"skyux\"\n ></sky-icon>\n</button>\n<ng-template #openIcons>\n <button\n class=\"sky-btn sky-btn-icon-borderless\"\n (click)=\"setExpanded(true)\"\n [attr.aria-label]=\"\n 'sky_ag_grid_column_group_header_expand_aria_label'\n | skyLibResources: params?.displayName\n \"\n >\n <sky-icon *skyThemeIf=\"'default'\" icon=\"angle-double-right\"></sky-icon>\n <sky-icon\n *skyThemeIf=\"'modern'\"\n icon=\"double-chevron-right\"\n iconType=\"skyux\"\n ></sky-icon>\n </button>\n</ng-template>\n<span class=\"sky-control-help-container\" #inlineHelpContainer></span>\n", styles: [":host{display:flex;max-width:100%;padding-right:12px;padding-left:12px;align-items:center;align-content:center}.header-group-text{flex-grow:0;flex-shrink:1;overflow:hidden;text-overflow:ellipsis}button{cursor:pointer;margin-left:var(--sky-margin-inline-sm);flex-grow:0;flex-shrink:0}\n"], dependencies: [{ kind: "directive", type: i2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: i3$2.λ4, selector: "sky-icon", inputs: ["icon", "iconType", "size", "fixedWidth", "variant"] }, { kind: "directive", type: i1$3.λ3, selector: "[skyThemeIf]", inputs: ["skyThemeIf"] }, { kind: "pipe", type: i2.AsyncPipe, name: "async" }, { kind: "pipe", type: i3.SkyLibResourcesPipe, name: "skyLibResources" }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
1004
+ SkyAgGridHeaderGroupComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.2.0", type: SkyAgGridHeaderGroupComponent, selector: "sky-header-group", viewQueries: [{ propertyName: "inlineHelpContainer", first: true, predicate: ["inlineHelpContainer"], descendants: true, read: ElementRef, static: true }], ngImport: i0, template: "<span class=\"header-group-text\" role=\"presentation\">{{\n params?.displayName\n}}</span>\n<button\n *ngIf=\"isExpanded$ | async; else openIcons\"\n class=\"sky-btn sky-btn-icon-borderless\"\n (click)=\"setExpanded(false)\"\n [attr.aria-label]=\"\n 'sky_ag_grid_column_group_header_collapse_aria_label'\n | skyLibResources: params?.displayName\n \"\n>\n <sky-icon *skyThemeIf=\"'default'\" icon=\"angle-double-left\"></sky-icon>\n <sky-icon\n *skyThemeIf=\"'modern'\"\n icon=\"double-chevron-left\"\n iconType=\"skyux\"\n ></sky-icon>\n</button>\n<ng-template #openIcons>\n <button\n class=\"sky-btn sky-btn-icon-borderless\"\n (click)=\"setExpanded(true)\"\n [attr.aria-label]=\"\n 'sky_ag_grid_column_group_header_expand_aria_label'\n | skyLibResources: params?.displayName\n \"\n >\n <sky-icon *skyThemeIf=\"'default'\" icon=\"angle-double-right\"></sky-icon>\n <sky-icon\n *skyThemeIf=\"'modern'\"\n icon=\"double-chevron-right\"\n iconType=\"skyux\"\n ></sky-icon>\n </button>\n</ng-template>\n<span class=\"sky-control-help-container\" #inlineHelpContainer></span>\n", styles: [":host{display:flex;max-width:100%;padding-right:12px;padding-left:12px;align-items:center;align-content:center}.header-group-text{flex-grow:0;flex-shrink:1;overflow:hidden;text-overflow:ellipsis}button{cursor:pointer;margin-left:var(--sky-margin-inline-sm);flex-grow:0;flex-shrink:0}\n"], dependencies: [{ kind: "directive", type: i2$3.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: i3$2.λ4, selector: "sky-icon", inputs: ["icon", "iconType", "size", "fixedWidth", "variant"] }, { kind: "directive", type: i1$2.λ3, selector: "[skyThemeIf]", inputs: ["skyThemeIf"] }, { kind: "pipe", type: i2$3.AsyncPipe, name: "async" }, { kind: "pipe", type: i3.SkyLibResourcesPipe, name: "skyLibResources" }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
1924
1005
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridHeaderGroupComponent, decorators: [{
1925
1006
  type: Component,
1926
1007
  args: [{ selector: 'sky-header-group', changeDetection: ChangeDetectionStrategy.OnPush, template: "<span class=\"header-group-text\" role=\"presentation\">{{\n params?.displayName\n}}</span>\n<button\n *ngIf=\"isExpanded$ | async; else openIcons\"\n class=\"sky-btn sky-btn-icon-borderless\"\n (click)=\"setExpanded(false)\"\n [attr.aria-label]=\"\n 'sky_ag_grid_column_group_header_collapse_aria_label'\n | skyLibResources: params?.displayName\n \"\n>\n <sky-icon *skyThemeIf=\"'default'\" icon=\"angle-double-left\"></sky-icon>\n <sky-icon\n *skyThemeIf=\"'modern'\"\n icon=\"double-chevron-left\"\n iconType=\"skyux\"\n ></sky-icon>\n</button>\n<ng-template #openIcons>\n <button\n class=\"sky-btn sky-btn-icon-borderless\"\n (click)=\"setExpanded(true)\"\n [attr.aria-label]=\"\n 'sky_ag_grid_column_group_header_expand_aria_label'\n | skyLibResources: params?.displayName\n \"\n >\n <sky-icon *skyThemeIf=\"'default'\" icon=\"angle-double-right\"></sky-icon>\n <sky-icon\n *skyThemeIf=\"'modern'\"\n icon=\"double-chevron-right\"\n iconType=\"skyux\"\n ></sky-icon>\n </button>\n</ng-template>\n<span class=\"sky-control-help-container\" #inlineHelpContainer></span>\n", styles: [":host{display:flex;max-width:100%;padding-right:12px;padding-left:12px;align-items:center;align-content:center}.header-group-text{flex-grow:0;flex-shrink:1;overflow:hidden;text-overflow:ellipsis}button{cursor:pointer;margin-left:var(--sky-margin-inline-sm);flex-grow:0;flex-shrink:0}\n"] }]
@@ -2045,7 +1126,7 @@ _SkyAgGridHeaderComponent_subscriptions = new WeakMap(), _SkyAgGridHeaderCompone
2045
1126
  }, _SkyAgGridHeaderComponent_updateSortIndex = function _SkyAgGridHeaderComponent_updateSortIndex() {
2046
1127
  const sortIndex = this.params.column.getSortIndex();
2047
1128
  const otherSortColumns = this.params.columnApi
2048
- .getAllColumns()
1129
+ .getColumns()
2049
1130
  .some((column) => column.getColId() !== this.params.column.getColId() &&
2050
1131
  !!column.getSort());
2051
1132
  if (sortIndex !== undefined && sortIndex !== null && otherSortColumns) {
@@ -2056,109 +1137,15 @@ _SkyAgGridHeaderComponent_subscriptions = new WeakMap(), _SkyAgGridHeaderCompone
2056
1137
  }
2057
1138
  };
2058
1139
  SkyAgGridHeaderComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridHeaderComponent, deps: [{ token: i0.ChangeDetectorRef }, { token: i1.SkyDynamicComponentService }], target: i0.ɵɵFactoryTarget.Component });
2059
- SkyAgGridHeaderComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.2.0", type: SkyAgGridHeaderComponent, selector: "sky-ag-grid-header", viewQueries: [{ propertyName: "inlineHelpContainer", first: true, predicate: ["inlineHelpContainer"], descendants: true, read: ElementRef, static: true }], ngImport: i0, template: "<div class=\"ag-cell-label-container\" role=\"presentation\">\n <span\n *ngIf=\"params?.enableMenu\"\n class=\"ag-header-icon ag-header-cell-menu-button\"\n aria-hidden=\"true\"\n (click)=\"onMenuClick($event)\"\n >\n <sky-icon *skyThemeIf=\"'default'\" icon=\"menu\"></sky-icon>\n <sky-icon *skyThemeIf=\"'modern'\" icon=\"menu\" iconType=\"skyux\"></sky-icon>\n </span>\n <div\n class=\"ag-header-cell-label\"\n role=\"presentation\"\n (click)=\"onSortRequested($event)\"\n >\n <span class=\"ag-header-cell-text\">{{ params?.displayName }}</span>\n <span\n *ngIf=\"filterEnabled$ | async\"\n class=\"ag-header-icon ag-header-label-icon ag-filter-icon\"\n aria-hidden=\"true\"\n >\n <sky-icon *skyThemeIf=\"'default'\" icon=\"filter\"></sky-icon>\n <sky-icon\n *skyThemeIf=\"'modern'\"\n icon=\"filter\"\n iconType=\"skyux\"\n ></sky-icon>\n </span>\n <span *ngIf=\"params?.enableSorting\" class=\"ag-sort-indicator-container\">\n <sky-icon\n *ngIf=\"(sortOrder$ | async) === 'desc'\"\n icon=\"caret-down\"\n class=\"ag-header-label-icon\"\n ></sky-icon>\n <sky-icon\n *ngIf=\"(sortOrder$ | async) === 'asc'\"\n icon=\"caret-up\"\n class=\"ag-header-label-icon\"\n ></sky-icon>\n <span\n *ngIf=\"sortIndexDisplay$ | async as sortIndexDisplay\"\n class=\"ag-sort-indicator-icon ag-sort-order\"\n aria-hidden=\"true\"\n >{{ sortIndexDisplay }}</span\n >\n </span>\n </div>\n</div>\n<span class=\"sky-control-help-container\" #inlineHelpContainer></span>\n", styles: [":host{display:flex;max-width:100%;padding-right:12px;padding-left:12px;align-items:center;align-content:center}.ag-header-cell-label{padding-right:0;padding-left:0}button{cursor:pointer;flex-grow:0;flex-shrink:0}\n"], dependencies: [{ kind: "directive", type: i2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: i3$2.λ4, selector: "sky-icon", inputs: ["icon", "iconType", "size", "fixedWidth", "variant"] }, { kind: "directive", type: i1$3.λ3, selector: "[skyThemeIf]", inputs: ["skyThemeIf"] }, { kind: "pipe", type: i2.AsyncPipe, name: "async" }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
1140
+ SkyAgGridHeaderComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.2.0", type: SkyAgGridHeaderComponent, selector: "sky-ag-grid-header", viewQueries: [{ propertyName: "inlineHelpContainer", first: true, predicate: ["inlineHelpContainer"], descendants: true, read: ElementRef, static: true }], ngImport: i0, template: "<div class=\"ag-cell-label-container\" role=\"presentation\">\n <span\n *ngIf=\"params?.enableMenu\"\n class=\"ag-header-icon ag-header-cell-menu-button\"\n aria-hidden=\"true\"\n (click)=\"onMenuClick($event)\"\n >\n <sky-icon *skyThemeIf=\"'default'\" icon=\"menu\"></sky-icon>\n <sky-icon *skyThemeIf=\"'modern'\" icon=\"menu\" iconType=\"skyux\"></sky-icon>\n </span>\n <div\n class=\"ag-header-cell-label\"\n role=\"presentation\"\n (click)=\"onSortRequested($event)\"\n >\n <span class=\"ag-header-cell-text\">{{ params?.displayName }}</span>\n <span\n *ngIf=\"filterEnabled$ | async\"\n class=\"ag-header-icon ag-header-label-icon ag-filter-icon\"\n aria-hidden=\"true\"\n >\n <sky-icon *skyThemeIf=\"'default'\" icon=\"filter\"></sky-icon>\n <sky-icon\n *skyThemeIf=\"'modern'\"\n icon=\"filter\"\n iconType=\"skyux\"\n ></sky-icon>\n </span>\n <span *ngIf=\"params?.enableSorting\" class=\"ag-sort-indicator-container\">\n <sky-icon\n *ngIf=\"(sortOrder$ | async) === 'desc'\"\n icon=\"caret-down\"\n class=\"ag-header-label-icon\"\n ></sky-icon>\n <sky-icon\n *ngIf=\"(sortOrder$ | async) === 'asc'\"\n icon=\"caret-up\"\n class=\"ag-header-label-icon\"\n ></sky-icon>\n <span\n *ngIf=\"sortIndexDisplay$ | async as sortIndexDisplay\"\n class=\"ag-sort-indicator-icon ag-sort-order\"\n aria-hidden=\"true\"\n >{{ sortIndexDisplay }}</span\n >\n </span>\n </div>\n</div>\n<span class=\"sky-control-help-container\" #inlineHelpContainer></span>\n", styles: [":host{display:flex;max-width:100%;align-items:center;align-content:center}.ag-header-cell-label{padding-right:0;padding-left:0}button{cursor:pointer;flex-grow:0;flex-shrink:0}\n"], dependencies: [{ kind: "directive", type: i2$3.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: i3$2.λ4, selector: "sky-icon", inputs: ["icon", "iconType", "size", "fixedWidth", "variant"] }, { kind: "directive", type: i1$2.λ3, selector: "[skyThemeIf]", inputs: ["skyThemeIf"] }, { kind: "pipe", type: i2$3.AsyncPipe, name: "async" }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
2060
1141
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridHeaderComponent, decorators: [{
2061
1142
  type: Component,
2062
- args: [{ selector: 'sky-ag-grid-header', changeDetection: ChangeDetectionStrategy.OnPush, template: "<div class=\"ag-cell-label-container\" role=\"presentation\">\n <span\n *ngIf=\"params?.enableMenu\"\n class=\"ag-header-icon ag-header-cell-menu-button\"\n aria-hidden=\"true\"\n (click)=\"onMenuClick($event)\"\n >\n <sky-icon *skyThemeIf=\"'default'\" icon=\"menu\"></sky-icon>\n <sky-icon *skyThemeIf=\"'modern'\" icon=\"menu\" iconType=\"skyux\"></sky-icon>\n </span>\n <div\n class=\"ag-header-cell-label\"\n role=\"presentation\"\n (click)=\"onSortRequested($event)\"\n >\n <span class=\"ag-header-cell-text\">{{ params?.displayName }}</span>\n <span\n *ngIf=\"filterEnabled$ | async\"\n class=\"ag-header-icon ag-header-label-icon ag-filter-icon\"\n aria-hidden=\"true\"\n >\n <sky-icon *skyThemeIf=\"'default'\" icon=\"filter\"></sky-icon>\n <sky-icon\n *skyThemeIf=\"'modern'\"\n icon=\"filter\"\n iconType=\"skyux\"\n ></sky-icon>\n </span>\n <span *ngIf=\"params?.enableSorting\" class=\"ag-sort-indicator-container\">\n <sky-icon\n *ngIf=\"(sortOrder$ | async) === 'desc'\"\n icon=\"caret-down\"\n class=\"ag-header-label-icon\"\n ></sky-icon>\n <sky-icon\n *ngIf=\"(sortOrder$ | async) === 'asc'\"\n icon=\"caret-up\"\n class=\"ag-header-label-icon\"\n ></sky-icon>\n <span\n *ngIf=\"sortIndexDisplay$ | async as sortIndexDisplay\"\n class=\"ag-sort-indicator-icon ag-sort-order\"\n aria-hidden=\"true\"\n >{{ sortIndexDisplay }}</span\n >\n </span>\n </div>\n</div>\n<span class=\"sky-control-help-container\" #inlineHelpContainer></span>\n", styles: [":host{display:flex;max-width:100%;padding-right:12px;padding-left:12px;align-items:center;align-content:center}.ag-header-cell-label{padding-right:0;padding-left:0}button{cursor:pointer;flex-grow:0;flex-shrink:0}\n"] }]
1143
+ args: [{ selector: 'sky-ag-grid-header', changeDetection: ChangeDetectionStrategy.OnPush, template: "<div class=\"ag-cell-label-container\" role=\"presentation\">\n <span\n *ngIf=\"params?.enableMenu\"\n class=\"ag-header-icon ag-header-cell-menu-button\"\n aria-hidden=\"true\"\n (click)=\"onMenuClick($event)\"\n >\n <sky-icon *skyThemeIf=\"'default'\" icon=\"menu\"></sky-icon>\n <sky-icon *skyThemeIf=\"'modern'\" icon=\"menu\" iconType=\"skyux\"></sky-icon>\n </span>\n <div\n class=\"ag-header-cell-label\"\n role=\"presentation\"\n (click)=\"onSortRequested($event)\"\n >\n <span class=\"ag-header-cell-text\">{{ params?.displayName }}</span>\n <span\n *ngIf=\"filterEnabled$ | async\"\n class=\"ag-header-icon ag-header-label-icon ag-filter-icon\"\n aria-hidden=\"true\"\n >\n <sky-icon *skyThemeIf=\"'default'\" icon=\"filter\"></sky-icon>\n <sky-icon\n *skyThemeIf=\"'modern'\"\n icon=\"filter\"\n iconType=\"skyux\"\n ></sky-icon>\n </span>\n <span *ngIf=\"params?.enableSorting\" class=\"ag-sort-indicator-container\">\n <sky-icon\n *ngIf=\"(sortOrder$ | async) === 'desc'\"\n icon=\"caret-down\"\n class=\"ag-header-label-icon\"\n ></sky-icon>\n <sky-icon\n *ngIf=\"(sortOrder$ | async) === 'asc'\"\n icon=\"caret-up\"\n class=\"ag-header-label-icon\"\n ></sky-icon>\n <span\n *ngIf=\"sortIndexDisplay$ | async as sortIndexDisplay\"\n class=\"ag-sort-indicator-icon ag-sort-order\"\n aria-hidden=\"true\"\n >{{ sortIndexDisplay }}</span\n >\n </span>\n </div>\n</div>\n<span class=\"sky-control-help-container\" #inlineHelpContainer></span>\n", styles: [":host{display:flex;max-width:100%;align-items:center;align-content:center}.ag-header-cell-label{padding-right:0;padding-left:0}button{cursor:pointer;flex-grow:0;flex-shrink:0}\n"] }]
2063
1144
  }], ctorParameters: function () { return [{ type: i0.ChangeDetectorRef }, { type: i1.SkyDynamicComponentService }]; }, propDecorators: { inlineHelpContainer: [{
2064
1145
  type: ViewChild,
2065
1146
  args: ['inlineHelpContainer', { read: ElementRef, static: true }]
2066
1147
  }] } });
2067
1148
 
2068
- class SkyAgGridModule {
2069
- }
2070
- SkyAgGridModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
2071
- SkyAgGridModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridModule, declarations: [SkyAgGridDataManagerAdapterDirective,
2072
- SkyAgGridHeaderComponent,
2073
- SkyAgGridHeaderGroupComponent,
2074
- SkyAgGridRowDeleteComponent,
2075
- SkyAgGridRowDeleteDirective,
2076
- SkyAgGridWrapperComponent], imports: [AgGridModule,
2077
- CommonModule,
2078
- SkyAgGridCellEditorAutocompleteModule,
2079
- SkyAgGridCellEditorDatepickerModule,
2080
- SkyAgGridCellEditorLookupModule,
2081
- SkyAgGridCellEditorNumberModule,
2082
- SkyAgGridCellEditorCurrencyModule,
2083
- SkyAgGridCellRendererCurrencyModule,
2084
- SkyAgGridCellRendererLookupModule,
2085
- SkyAgGridCellRendererRowSelectorModule,
2086
- SkyAgGridCellRendererValidatorTooltipModule,
2087
- SkyAgGridCellValidatorModule,
2088
- SkyAgGridCellEditorTextModule,
2089
- SkyDataManagerModule,
2090
- SkyI18nModule,
2091
- SkyIconModule,
2092
- SkyInlineDeleteModule,
2093
- SkyViewkeeperModule,
2094
- SkyThemeModule], exports: [SkyAgGridDataManagerAdapterDirective,
2095
- SkyAgGridRowDeleteComponent,
2096
- SkyAgGridRowDeleteDirective,
2097
- SkyAgGridWrapperComponent,
2098
- SkyAgGridHeaderComponent,
2099
- SkyAgGridHeaderGroupComponent] });
2100
- SkyAgGridModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridModule, imports: [AgGridModule,
2101
- CommonModule,
2102
- SkyAgGridCellEditorAutocompleteModule,
2103
- SkyAgGridCellEditorDatepickerModule,
2104
- SkyAgGridCellEditorLookupModule,
2105
- SkyAgGridCellEditorNumberModule,
2106
- SkyAgGridCellEditorCurrencyModule,
2107
- SkyAgGridCellRendererCurrencyModule,
2108
- SkyAgGridCellRendererLookupModule,
2109
- SkyAgGridCellRendererRowSelectorModule,
2110
- SkyAgGridCellRendererValidatorTooltipModule,
2111
- SkyAgGridCellValidatorModule,
2112
- SkyAgGridCellEditorTextModule,
2113
- SkyDataManagerModule,
2114
- SkyI18nModule,
2115
- SkyIconModule,
2116
- SkyInlineDeleteModule,
2117
- SkyViewkeeperModule,
2118
- SkyThemeModule] });
2119
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridModule, decorators: [{
2120
- type: NgModule,
2121
- args: [{
2122
- declarations: [
2123
- SkyAgGridDataManagerAdapterDirective,
2124
- SkyAgGridHeaderComponent,
2125
- SkyAgGridHeaderGroupComponent,
2126
- SkyAgGridRowDeleteComponent,
2127
- SkyAgGridRowDeleteDirective,
2128
- SkyAgGridWrapperComponent,
2129
- ],
2130
- imports: [
2131
- AgGridModule,
2132
- CommonModule,
2133
- SkyAgGridCellEditorAutocompleteModule,
2134
- SkyAgGridCellEditorDatepickerModule,
2135
- SkyAgGridCellEditorLookupModule,
2136
- SkyAgGridCellEditorNumberModule,
2137
- SkyAgGridCellEditorCurrencyModule,
2138
- SkyAgGridCellRendererCurrencyModule,
2139
- SkyAgGridCellRendererLookupModule,
2140
- SkyAgGridCellRendererRowSelectorModule,
2141
- SkyAgGridCellRendererValidatorTooltipModule,
2142
- SkyAgGridCellValidatorModule,
2143
- SkyAgGridCellEditorTextModule,
2144
- SkyDataManagerModule,
2145
- SkyI18nModule,
2146
- SkyIconModule,
2147
- SkyInlineDeleteModule,
2148
- SkyViewkeeperModule,
2149
- SkyThemeModule,
2150
- ],
2151
- exports: [
2152
- SkyAgGridDataManagerAdapterDirective,
2153
- SkyAgGridRowDeleteComponent,
2154
- SkyAgGridRowDeleteDirective,
2155
- SkyAgGridWrapperComponent,
2156
- SkyAgGridHeaderComponent,
2157
- SkyAgGridHeaderGroupComponent,
2158
- ],
2159
- }]
2160
- }] });
2161
-
2162
1149
  /**
2163
1150
  * @internal
2164
1151
  */
@@ -2277,6 +1264,7 @@ var SkyHeaderClass;
2277
1264
  SkyHeaderClass["RightAligned"] = "sky-ag-grid-header-right-aligned";
2278
1265
  })(SkyHeaderClass || (SkyHeaderClass = {}));
2279
1266
 
1267
+ var _SkyAgGridService_instances, _SkyAgGridService_currentTheme, _SkyAgGridService_getRowHeight;
2280
1268
  function autocompleteComparator(value1, value2) {
2281
1269
  if (value1 && value2) {
2282
1270
  if (value1.name > value2.name) {
@@ -2334,15 +1322,18 @@ let rowNodeId = -1;
2334
1322
  class SkyAgGridService {
2335
1323
  constructor(agGridAdapterService, themeSvc, resources) {
2336
1324
  this.agGridAdapterService = agGridAdapterService;
2337
- this.themeSvc = themeSvc;
2338
1325
  this.resources = resources;
1326
+ _SkyAgGridService_instances.add(this);
2339
1327
  this.ngUnsubscribe = new Subject();
2340
1328
  this.keyMap = new WeakMap();
1329
+ _SkyAgGridService_currentTheme.set(this, undefined);
2341
1330
  /*istanbul ignore else*/
2342
- if (this.themeSvc) {
2343
- this.themeSvc.settingsChange
1331
+ if (themeSvc) {
1332
+ themeSvc.settingsChange
2344
1333
  .pipe(takeUntil(this.ngUnsubscribe))
2345
- .subscribe((settingsChange) => (this.currentTheme = settingsChange.currentSettings));
1334
+ .subscribe((settingsChange) => {
1335
+ __classPrivateFieldSet(this, _SkyAgGridService_currentTheme, settingsChange.currentSettings, "f");
1336
+ });
2346
1337
  }
2347
1338
  }
2348
1339
  ngOnDestroy() {
@@ -2369,6 +1360,10 @@ class SkyAgGridService {
2369
1360
  const mergedGridOptions = this.mergeGridOptions(defaultGridOptions, args.gridOptions);
2370
1361
  return mergedGridOptions;
2371
1362
  }
1363
+ getHeaderHeight() {
1364
+ var _a, _b;
1365
+ return ((_b = (_a = __classPrivateFieldGet(this, _SkyAgGridService_currentTheme, "f")) === null || _a === void 0 ? void 0 : _a.theme) === null || _b === void 0 ? void 0 : _b.name) === 'modern' ? 60 : 37;
1366
+ }
2372
1367
  mergeGridOptions(defaultGridOptions, providedGridOptions) {
2373
1368
  const mergedGridOptions = Object.assign(Object.assign(Object.assign({}, defaultGridOptions), providedGridOptions), { components: Object.assign(Object.assign({}, providedGridOptions.components), defaultGridOptions.components), columnTypes: Object.assign(Object.assign({}, providedGridOptions.columnTypes), defaultGridOptions.columnTypes), defaultColDef: Object.assign(Object.assign(Object.assign({}, defaultGridOptions.defaultColDef), providedGridOptions.defaultColDef), {
2374
1369
  // allow consumers to override all defaultColDef properties except cellClassRules, which we reserve for styling
@@ -2380,7 +1375,7 @@ class SkyAgGridService {
2380
1375
  return mergedGridOptions;
2381
1376
  }
2382
1377
  getDefaultGridOptions(args) {
2383
- var _a, _b, _c, _d, _e, _f;
1378
+ var _a, _b;
2384
1379
  // cellClassRules can be functions or string expressions
2385
1380
  const cellClassRuleTrueExpression = () => true;
2386
1381
  function getEditableFn(isUneditable) {
@@ -2430,7 +1425,7 @@ class SkyAgGridService {
2430
1425
  cellClassRules: Object.assign({ [SkyCellClass.Date]: cellClassRuleTrueExpression }, editableCellClassRules),
2431
1426
  cellEditor: SkyAgGridCellEditorDatepickerComponent,
2432
1427
  comparator: dateComparator,
2433
- minWidth: ((_b = (_a = this.currentTheme) === null || _a === void 0 ? void 0 : _a.theme) === null || _b === void 0 ? void 0 : _b.name) === 'modern' ? 180 : 160,
1428
+ minWidth: ((_b = (_a = __classPrivateFieldGet(this, _SkyAgGridService_currentTheme, "f")) === null || _a === void 0 ? void 0 : _a.theme) === null || _b === void 0 ? void 0 : _b.name) === 'modern' ? 180 : 160,
2434
1429
  valueFormatter: (params) => this.dateFormatter(params, args.locale),
2435
1430
  },
2436
1431
  [SkyCellType.Lookup]: {
@@ -2512,7 +1507,7 @@ class SkyAgGridService {
2512
1507
  return undefined;
2513
1508
  }
2514
1509
  },
2515
- headerHeight: ((_d = (_c = this.currentTheme) === null || _c === void 0 ? void 0 : _c.theme) === null || _d === void 0 ? void 0 : _d.name) === 'modern' ? 60 : 37,
1510
+ headerHeight: this.getHeaderHeight(),
2516
1511
  icons: {
2517
1512
  sortDescending: this.getIconTemplate('caret-down'),
2518
1513
  sortAscending: this.getIconTemplate('caret-up'),
@@ -2523,7 +1518,8 @@ class SkyAgGridService {
2523
1518
  columnMovePin: this.getIconTemplate('arrows'),
2524
1519
  },
2525
1520
  onCellFocused: () => this.onCellFocused(),
2526
- rowHeight: ((_f = (_e = this.currentTheme) === null || _e === void 0 ? void 0 : _e.theme) === null || _f === void 0 ? void 0 : _f.name) === 'modern' ? 60 : 38,
1521
+ rowHeight: __classPrivateFieldGet(this, _SkyAgGridService_instances, "m", _SkyAgGridService_getRowHeight).call(this),
1522
+ getRowHeight: () => __classPrivateFieldGet(this, _SkyAgGridService_instances, "m", _SkyAgGridService_getRowHeight).call(this),
2527
1523
  rowMultiSelectWithClick: true,
2528
1524
  rowSelection: 'multiple',
2529
1525
  singleClickEdit: true,
@@ -2572,7 +1568,7 @@ class SkyAgGridService {
2572
1568
  }
2573
1569
  getDefaultEditableGridOptions(args) {
2574
1570
  const defaultGridOptions = this.getDefaultGridOptions(args);
2575
- defaultGridOptions.rowSelection = 'none';
1571
+ defaultGridOptions.rowSelection = undefined;
2576
1572
  return defaultGridOptions;
2577
1573
  }
2578
1574
  dateFormatter(params, locale = 'en-us') {
@@ -2607,7 +1603,11 @@ class SkyAgGridService {
2607
1603
  return false;
2608
1604
  }
2609
1605
  }
2610
- SkyAgGridService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridService, deps: [{ token: SkyAgGridAdapterService }, { token: i1$3.SkyThemeService, optional: true }, { token: i3.SkyLibResourcesService, optional: true }], target: i0.ɵɵFactoryTarget.Injectable });
1606
+ _SkyAgGridService_currentTheme = new WeakMap(), _SkyAgGridService_instances = new WeakSet(), _SkyAgGridService_getRowHeight = function _SkyAgGridService_getRowHeight() {
1607
+ var _a, _b;
1608
+ return ((_b = (_a = __classPrivateFieldGet(this, _SkyAgGridService_currentTheme, "f")) === null || _a === void 0 ? void 0 : _a.theme) === null || _b === void 0 ? void 0 : _b.name) === 'modern' ? 60 : 38;
1609
+ };
1610
+ SkyAgGridService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridService, deps: [{ token: SkyAgGridAdapterService }, { token: i1$2.SkyThemeService, optional: true }, { token: i3.SkyLibResourcesService, optional: true }], target: i0.ɵɵFactoryTarget.Injectable });
2611
1611
  SkyAgGridService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridService, providedIn: 'any' });
2612
1612
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridService, decorators: [{
2613
1613
  type: Injectable,
@@ -2615,13 +1615,1081 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.0", ngImpor
2615
1615
  providedIn: 'any',
2616
1616
  }]
2617
1617
  }], ctorParameters: function () {
2618
- return [{ type: SkyAgGridAdapterService }, { type: i1$3.SkyThemeService, decorators: [{
1618
+ return [{ type: SkyAgGridAdapterService }, { type: i1$2.SkyThemeService, decorators: [{
2619
1619
  type: Optional
2620
1620
  }] }, { type: i3.SkyLibResourcesService, decorators: [{
2621
1621
  type: Optional
2622
1622
  }] }];
2623
1623
  } });
2624
1624
 
1625
+ var _SkyAgGridWrapperComponent_instances, _SkyAgGridWrapperComponent_agGridService, _SkyAgGridWrapperComponent_ngUnsubscribe, _SkyAgGridWrapperComponent_themeSvc, _SkyAgGridWrapperComponent_wrapperClasses, _SkyAgGridWrapperComponent_currentTheme, _SkyAgGridWrapperComponent_moveHorizontalScroll;
1626
+ let idIndex = 0;
1627
+ class SkyAgGridWrapperComponent {
1628
+ constructor(adapterService, changeDetector, elementRef, document, agGridService, themeSvc) {
1629
+ this.adapterService = adapterService;
1630
+ this.changeDetector = changeDetector;
1631
+ this.elementRef = elementRef;
1632
+ this.document = document;
1633
+ _SkyAgGridWrapperComponent_instances.add(this);
1634
+ this._viewkeeperClasses = [];
1635
+ _SkyAgGridWrapperComponent_agGridService.set(this, void 0);
1636
+ _SkyAgGridWrapperComponent_ngUnsubscribe.set(this, new Subject());
1637
+ _SkyAgGridWrapperComponent_themeSvc.set(this, void 0);
1638
+ _SkyAgGridWrapperComponent_wrapperClasses.set(this, new BehaviorSubject([`ag-theme-sky-default`]));
1639
+ _SkyAgGridWrapperComponent_currentTheme.set(this, undefined);
1640
+ idIndex++;
1641
+ this.afterAnchorId = 'sky-ag-grid-nav-anchor-after-' + idIndex;
1642
+ this.beforeAnchorId = 'sky-ag-grid-nav-anchor-before-' + idIndex;
1643
+ this.gridId = 'sky-ag-grid-' + idIndex;
1644
+ __classPrivateFieldSet(this, _SkyAgGridWrapperComponent_agGridService, agGridService, "f");
1645
+ __classPrivateFieldSet(this, _SkyAgGridWrapperComponent_themeSvc, themeSvc, "f");
1646
+ this.wrapperClasses$ = __classPrivateFieldGet(this, _SkyAgGridWrapperComponent_wrapperClasses, "f").asObservable();
1647
+ }
1648
+ get viewkeeperClasses() {
1649
+ return this._viewkeeperClasses;
1650
+ }
1651
+ set viewkeeperClasses(value) {
1652
+ this._viewkeeperClasses = value;
1653
+ this.changeDetector.markForCheck();
1654
+ }
1655
+ ngAfterContentInit() {
1656
+ var _a;
1657
+ if (this.agGrid.gridOptions &&
1658
+ this.agGrid.gridOptions.domLayout === 'autoHeight') {
1659
+ if ((_a = this.agGrid.gridOptions.context) === null || _a === void 0 ? void 0 : _a.enableTopScroll) {
1660
+ this.viewkeeperClasses.push('.ag-header', '.ag-body-horizontal-scroll');
1661
+ }
1662
+ else {
1663
+ this.viewkeeperClasses.push('.ag-header');
1664
+ }
1665
+ }
1666
+ this.agGrid.gridReady.pipe(takeUntil(__classPrivateFieldGet(this, _SkyAgGridWrapperComponent_ngUnsubscribe, "f"))).subscribe(() => {
1667
+ __classPrivateFieldGet(this, _SkyAgGridWrapperComponent_instances, "m", _SkyAgGridWrapperComponent_moveHorizontalScroll).call(this);
1668
+ });
1669
+ this.agGrid.firstDataRendered
1670
+ .pipe(takeUntil(__classPrivateFieldGet(this, _SkyAgGridWrapperComponent_ngUnsubscribe, "f")))
1671
+ .subscribe(() => {
1672
+ __classPrivateFieldGet(this, _SkyAgGridWrapperComponent_instances, "m", _SkyAgGridWrapperComponent_moveHorizontalScroll).call(this);
1673
+ });
1674
+ this.agGrid.rowDataUpdated
1675
+ .pipe(takeUntil(__classPrivateFieldGet(this, _SkyAgGridWrapperComponent_ngUnsubscribe, "f")))
1676
+ .subscribe(() => {
1677
+ __classPrivateFieldGet(this, _SkyAgGridWrapperComponent_instances, "m", _SkyAgGridWrapperComponent_moveHorizontalScroll).call(this);
1678
+ });
1679
+ this.agGrid.cellEditingStarted
1680
+ .pipe(takeUntil(__classPrivateFieldGet(this, _SkyAgGridWrapperComponent_ngUnsubscribe, "f")))
1681
+ .subscribe((params) => {
1682
+ if (params.colDef.type) {
1683
+ const types = Array.isArray(params.colDef.type)
1684
+ ? params.colDef.type
1685
+ : [params.colDef.type];
1686
+ const addClasses = types.map((t) => `sky-ag-grid-cell-editing-${t}`);
1687
+ __classPrivateFieldGet(this, _SkyAgGridWrapperComponent_wrapperClasses, "f").next([
1688
+ ...__classPrivateFieldGet(this, _SkyAgGridWrapperComponent_wrapperClasses, "f").getValue(),
1689
+ ...addClasses,
1690
+ ]);
1691
+ }
1692
+ });
1693
+ this.agGrid.cellEditingStopped
1694
+ .pipe(takeUntil(__classPrivateFieldGet(this, _SkyAgGridWrapperComponent_ngUnsubscribe, "f")))
1695
+ .subscribe(() => {
1696
+ __classPrivateFieldGet(this, _SkyAgGridWrapperComponent_wrapperClasses, "f").next(__classPrivateFieldGet(this, _SkyAgGridWrapperComponent_wrapperClasses, "f")
1697
+ .getValue()
1698
+ .filter((c) => c.startsWith('ag-theme-')));
1699
+ });
1700
+ }
1701
+ ngOnDestroy() {
1702
+ __classPrivateFieldGet(this, _SkyAgGridWrapperComponent_ngUnsubscribe, "f").next();
1703
+ __classPrivateFieldGet(this, _SkyAgGridWrapperComponent_ngUnsubscribe, "f").complete();
1704
+ }
1705
+ ngOnInit() {
1706
+ var _a;
1707
+ (_a = __classPrivateFieldGet(this, _SkyAgGridWrapperComponent_themeSvc, "f")) === null || _a === void 0 ? void 0 : _a.settingsChange.pipe(takeUntil(__classPrivateFieldGet(this, _SkyAgGridWrapperComponent_ngUnsubscribe, "f"))).subscribe((settings) => {
1708
+ let agThemeClass;
1709
+ if (settings.currentSettings.theme.name === 'modern') {
1710
+ agThemeClass = `ag-theme-sky-modern-${settings.currentSettings.mode.name}`;
1711
+ }
1712
+ else {
1713
+ agThemeClass = `ag-theme-sky-default`;
1714
+ }
1715
+ __classPrivateFieldGet(this, _SkyAgGridWrapperComponent_wrapperClasses, "f").next([
1716
+ ...__classPrivateFieldGet(this, _SkyAgGridWrapperComponent_wrapperClasses, "f")
1717
+ .getValue()
1718
+ .filter((c) => !c.startsWith('ag-theme-')),
1719
+ agThemeClass,
1720
+ ]);
1721
+ if (!__classPrivateFieldGet(this, _SkyAgGridWrapperComponent_currentTheme, "f")) {
1722
+ // Initial theme settings.
1723
+ __classPrivateFieldSet(this, _SkyAgGridWrapperComponent_currentTheme, settings.currentSettings, "f");
1724
+ }
1725
+ else if (this.agGrid.api) {
1726
+ // On subsequent theme changes, we need to call the api to re-render the grid.
1727
+ __classPrivateFieldSet(this, _SkyAgGridWrapperComponent_currentTheme, settings.currentSettings, "f");
1728
+ this.agGrid.api.setHeaderHeight(__classPrivateFieldGet(this, _SkyAgGridWrapperComponent_agGridService, "f").getHeaderHeight());
1729
+ this.agGrid.api.resetRowHeights();
1730
+ this.agGrid.api.refreshCells();
1731
+ }
1732
+ });
1733
+ }
1734
+ /**
1735
+ * Prevent closing a modal when focused in AG Grid.
1736
+ */
1737
+ onKeyUpEscape($event) {
1738
+ $event.stopPropagation();
1739
+ this.agGrid.api.stopEditing(true);
1740
+ }
1741
+ onGridKeydown(event) {
1742
+ if (this.agGrid && !this.isInEditMode && event.key === 'Tab') {
1743
+ const idToFocus = event.shiftKey
1744
+ ? this.beforeAnchorId
1745
+ : this.afterAnchorId;
1746
+ this.adapterService.setFocusedElementById(this.elementRef.nativeElement, idToFocus);
1747
+ }
1748
+ }
1749
+ onAnchorFocus(event) {
1750
+ const gridId = this.gridId;
1751
+ const relatedTarget = event.relatedTarget;
1752
+ const previousFocusedId = relatedTarget && relatedTarget.id;
1753
+ const previousWasCell = relatedTarget &&
1754
+ !!this.adapterService.getElementOrParentWithClass(relatedTarget, 'ag-cell');
1755
+ if (previousFocusedId !== gridId && !previousWasCell) {
1756
+ const columns = this.agGrid.columnApi.getAllDisplayedColumns();
1757
+ const firstColumn = columns && columns[0];
1758
+ const rowIndex = this.agGrid.api.getFirstDisplayedRow();
1759
+ if (firstColumn && rowIndex >= 0) {
1760
+ this.agGrid.api.setFocusedCell(rowIndex, firstColumn);
1761
+ }
1762
+ }
1763
+ }
1764
+ get isInEditMode() {
1765
+ /* Sanity check */
1766
+ /* istanbul ignore else */
1767
+ if (this.agGrid && this.agGrid.api) {
1768
+ const primaryGridEditing = this.agGrid.api.getEditingCells().length > 0;
1769
+ if (primaryGridEditing) {
1770
+ return true;
1771
+ }
1772
+ else {
1773
+ let innerEditing = false;
1774
+ this.agGrid.api.forEachDetailGridInfo((detailGrid) => {
1775
+ if (detailGrid.api.getEditingCells().length > 0) {
1776
+ innerEditing = true;
1777
+ }
1778
+ });
1779
+ return innerEditing;
1780
+ }
1781
+ }
1782
+ else {
1783
+ return false;
1784
+ }
1785
+ }
1786
+ }
1787
+ _SkyAgGridWrapperComponent_agGridService = new WeakMap(), _SkyAgGridWrapperComponent_ngUnsubscribe = new WeakMap(), _SkyAgGridWrapperComponent_themeSvc = new WeakMap(), _SkyAgGridWrapperComponent_wrapperClasses = new WeakMap(), _SkyAgGridWrapperComponent_currentTheme = new WeakMap(), _SkyAgGridWrapperComponent_instances = new WeakSet(), _SkyAgGridWrapperComponent_moveHorizontalScroll = function _SkyAgGridWrapperComponent_moveHorizontalScroll() {
1788
+ var _a;
1789
+ if (this.agGrid && this.agGrid.api) {
1790
+ const toTop = !!((_a = this.agGrid.gridOptions.context) === null || _a === void 0 ? void 0 : _a.enableTopScroll);
1791
+ const root = this.elementRef.nativeElement.querySelector('.ag-root');
1792
+ const header = root.querySelector('.ag-header');
1793
+ const floatingBottom = root.querySelector('.ag-floating-bottom');
1794
+ const scrollbar = root.querySelector('.ag-body-horizontal-scroll');
1795
+ if (header && floatingBottom && scrollbar) {
1796
+ if (scrollbar.style.height !==
1797
+ scrollbar.style.getPropertyValue('--sky-ag-body-horizontal-scroll-width')) {
1798
+ scrollbar.style.setProperty('--sky-ag-body-horizontal-scroll-width', scrollbar.style.height);
1799
+ }
1800
+ const isTop = !!root.children[1].matches('.ag-body-horizontal-scroll');
1801
+ if (toTop && !isTop) {
1802
+ const fragment = this.document.createDocumentFragment();
1803
+ fragment.appendChild(scrollbar);
1804
+ header.after(fragment);
1805
+ }
1806
+ else if (!toTop && isTop) {
1807
+ const fragment = this.document.createDocumentFragment();
1808
+ fragment.appendChild(scrollbar);
1809
+ floatingBottom.after(fragment);
1810
+ }
1811
+ }
1812
+ }
1813
+ };
1814
+ SkyAgGridWrapperComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridWrapperComponent, deps: [{ token: SkyAgGridAdapterService }, { token: i0.ChangeDetectorRef }, { token: i0.ElementRef }, { token: DOCUMENT }, { token: SkyAgGridService }, { token: i1$2.SkyThemeService, optional: true }], target: i0.ɵɵFactoryTarget.Component });
1815
+ SkyAgGridWrapperComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.2.0", type: SkyAgGridWrapperComponent, selector: "sky-ag-grid-wrapper", queries: [{ propertyName: "agGrid", first: true, predicate: AgGridAngular, descendants: true, static: true }], ngImport: i0, template: "<span\n class=\"nav-anchor\"\n tabindex=\"0\"\n [id]=\"beforeAnchorId\"\n (focusin)=\"onAnchorFocus($event)\"\n>\n</span>\n<div\n class=\"sky-ag-grid\"\n [class.sky-ag-grid-top-scrollbar]=\"\n agGrid?.gridOptions?.context &&\n agGrid?.gridOptions?.context['enableTopScroll']\n \"\n [ngClass]=\"wrapperClasses$ | async\"\n tabindex=\"0\"\n [id]=\"gridId\"\n [skyViewkeeper]=\"viewkeeperClasses\"\n (keydown)=\"onGridKeydown($event)\"\n (keyup.escape)=\"onKeyUpEscape($event)\"\n>\n <ng-content></ng-content>\n</div>\n<span\n tabindex=\"0\"\n class=\"nav-anchor\"\n [id]=\"afterAnchorId\"\n (focusin)=\"onAnchorFocus($event)\"\n>\n</span>\n", dependencies: [{ kind: "directive", type: i2$3.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i1.λ3, selector: "[skyViewkeeper]", inputs: ["skyViewkeeper"] }, { kind: "pipe", type: i2$3.AsyncPipe, name: "async" }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
1816
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridWrapperComponent, decorators: [{
1817
+ type: Component,
1818
+ args: [{ selector: 'sky-ag-grid-wrapper', changeDetection: ChangeDetectionStrategy.OnPush, template: "<span\n class=\"nav-anchor\"\n tabindex=\"0\"\n [id]=\"beforeAnchorId\"\n (focusin)=\"onAnchorFocus($event)\"\n>\n</span>\n<div\n class=\"sky-ag-grid\"\n [class.sky-ag-grid-top-scrollbar]=\"\n agGrid?.gridOptions?.context &&\n agGrid?.gridOptions?.context['enableTopScroll']\n \"\n [ngClass]=\"wrapperClasses$ | async\"\n tabindex=\"0\"\n [id]=\"gridId\"\n [skyViewkeeper]=\"viewkeeperClasses\"\n (keydown)=\"onGridKeydown($event)\"\n (keyup.escape)=\"onKeyUpEscape($event)\"\n>\n <ng-content></ng-content>\n</div>\n<span\n tabindex=\"0\"\n class=\"nav-anchor\"\n [id]=\"afterAnchorId\"\n (focusin)=\"onAnchorFocus($event)\"\n>\n</span>\n" }]
1819
+ }], ctorParameters: function () {
1820
+ return [{ type: SkyAgGridAdapterService }, { type: i0.ChangeDetectorRef }, { type: i0.ElementRef }, { type: Document, decorators: [{
1821
+ type: Inject,
1822
+ args: [DOCUMENT]
1823
+ }] }, { type: SkyAgGridService }, { type: i1$2.SkyThemeService, decorators: [{
1824
+ type: Optional
1825
+ }] }];
1826
+ }, propDecorators: { agGrid: [{
1827
+ type: ContentChild,
1828
+ args: [AgGridAngular, {
1829
+ static: true,
1830
+ }]
1831
+ }] } });
1832
+
1833
+ /**
1834
+ * @internal
1835
+ */
1836
+ class SkyAgGridDataManagerAdapterDirective {
1837
+ constructor(changeDetector, dataManagerSvc) {
1838
+ this.changeDetector = changeDetector;
1839
+ this.dataManagerSvc = dataManagerSvc;
1840
+ this.ngUnsubscribe = new Subject();
1841
+ }
1842
+ ngAfterContentInit() {
1843
+ this.dataManagerSvc.setViewkeeperClasses(this.viewId, ['.ag-header']);
1844
+ this.viewConfig = this.dataManagerSvc.getViewById(this.viewId);
1845
+ this.checkForAgGrid();
1846
+ this.checkForSkyAgGridWrapper();
1847
+ this.agGridList.changes
1848
+ .pipe(takeUntil(this.ngUnsubscribe))
1849
+ .subscribe(() => this.checkForAgGrid());
1850
+ this.skyAgGridWrapperList.changes
1851
+ .pipe(takeUntil(this.ngUnsubscribe))
1852
+ .subscribe(() => this.checkForSkyAgGridWrapper());
1853
+ }
1854
+ ngOnDestroy() {
1855
+ this.ngUnsubscribe.next();
1856
+ this.ngUnsubscribe.complete();
1857
+ }
1858
+ checkForAgGrid() {
1859
+ const agGridCount = this.agGridList.length;
1860
+ /* istanbul ignore else */
1861
+ if (agGridCount === 0) {
1862
+ this.unregisterAgGrid();
1863
+ }
1864
+ else if (this.agGridList.first !== this.currentAgGrid) {
1865
+ this.registerAgGrid();
1866
+ }
1867
+ if (agGridCount > 1) {
1868
+ console.warn('More than one ag-grid child component was found. Using the first ag-Grid.');
1869
+ }
1870
+ }
1871
+ checkForSkyAgGridWrapper() {
1872
+ const skyAgGridWrapperCount = this.skyAgGridWrapperList.length;
1873
+ /* istanbul ignore else */
1874
+ if (skyAgGridWrapperCount === 0) {
1875
+ this.unregisterSkyAgGridWrapper();
1876
+ }
1877
+ else if (this.skyAgGridWrapperList.first !== this.currentSkyAgGridWrapper) {
1878
+ this.registerSkyAgGridWrapper();
1879
+ }
1880
+ if (skyAgGridWrapperCount > 1) {
1881
+ console.warn('More than one ag-grid child component was found. Using the first ag-Grid.');
1882
+ }
1883
+ }
1884
+ unregisterAgGrid() {
1885
+ this.currentAgGrid = undefined;
1886
+ /* istanbul ignore if */
1887
+ if (this.dataStateSub) {
1888
+ this.dataStateSub.unsubscribe();
1889
+ }
1890
+ }
1891
+ unregisterSkyAgGridWrapper() {
1892
+ this.currentSkyAgGridWrapper = undefined;
1893
+ }
1894
+ registerSkyAgGridWrapper() {
1895
+ this.unregisterSkyAgGridWrapper();
1896
+ this.currentSkyAgGridWrapper = this.skyAgGridWrapperList.first;
1897
+ setTimeout(() => {
1898
+ if (this.currentSkyAgGridWrapper) {
1899
+ this.currentSkyAgGridWrapper.viewkeeperClasses = [];
1900
+ }
1901
+ });
1902
+ }
1903
+ registerAgGrid() {
1904
+ this.unregisterAgGrid();
1905
+ const agGrid = this.agGridList.first;
1906
+ this.currentAgGrid = agGrid;
1907
+ agGrid.gridReady.pipe(takeUntil(this.ngUnsubscribe)).subscribe(() => {
1908
+ var _a;
1909
+ this.viewConfig.onSelectAllClick = this.selectAll.bind(this);
1910
+ this.viewConfig.onClearAllClick = this.clearAll.bind(this);
1911
+ this.dataManagerSvc.updateViewConfig(this.viewConfig);
1912
+ this.dataStateSub = this.dataManagerSvc
1913
+ .getDataStateUpdates(this.viewConfig.id)
1914
+ .pipe(takeUntil(this.ngUnsubscribe))
1915
+ .subscribe((dataState) => {
1916
+ this.currentDataState = dataState;
1917
+ this.displayColumns(dataState);
1918
+ });
1919
+ if ((_a = agGrid.gridOptions.context) === null || _a === void 0 ? void 0 : _a.enableTopScroll) {
1920
+ this.dataManagerSvc.setViewkeeperClasses(this.viewId, [
1921
+ '.ag-header',
1922
+ '.ag-body-horizontal-scroll',
1923
+ ]);
1924
+ }
1925
+ agGrid.api.sizeColumnsToFit();
1926
+ });
1927
+ agGrid.columnMoved
1928
+ .pipe(takeUntil(this.ngUnsubscribe), filter((event) => ![
1929
+ 'gridInitializing',
1930
+ 'uiColumnResized',
1931
+ 'uiColumnDragged',
1932
+ 'api',
1933
+ ].includes(event.source)))
1934
+ .subscribe((value) => {
1935
+ this.updateColumnsInCurrentDataState(value.columnApi);
1936
+ });
1937
+ agGrid.dragStopped
1938
+ .pipe(takeUntil(this.ngUnsubscribe))
1939
+ .subscribe((value) => {
1940
+ this.updateColumnsInCurrentDataState(value.columnApi);
1941
+ });
1942
+ agGrid.rowSelected
1943
+ .pipe(takeUntil(this.ngUnsubscribe))
1944
+ .subscribe((event) => {
1945
+ const row = event.node;
1946
+ const selectedIds = this.currentDataState.selectedIds || [];
1947
+ const rowIndex = selectedIds.indexOf(row.data.id);
1948
+ if (row.isSelected() && rowIndex === -1) {
1949
+ selectedIds.push(row.data.id);
1950
+ }
1951
+ else if (!row.isSelected() && rowIndex !== -1) {
1952
+ selectedIds.splice(rowIndex, 1);
1953
+ }
1954
+ this.currentDataState.selectedIds = selectedIds;
1955
+ this.dataManagerSvc.updateDataState(this.currentDataState, this.viewConfig.id);
1956
+ this.changeDetector.markForCheck();
1957
+ });
1958
+ agGrid.sortChanged.pipe(takeUntil(this.ngUnsubscribe)).subscribe(() => {
1959
+ const gridColumnStates = agGrid.columnApi.getColumnState();
1960
+ let sortOption;
1961
+ /* istanbul ignore else */
1962
+ if (gridColumnStates.length) {
1963
+ const activeSortColumnState = gridColumnStates.find((aGridColumnState) => aGridColumnState.sortIndex === 0);
1964
+ const dataManagerConfig = this.dataManagerSvc.getCurrentDataManagerConfig();
1965
+ /* istanbul ignore else */
1966
+ if (dataManagerConfig.sortOptions && activeSortColumnState) {
1967
+ sortOption = dataManagerConfig.sortOptions.find((option) => {
1968
+ return (option.propertyName === activeSortColumnState.colId &&
1969
+ option.descending === (activeSortColumnState.sort === 'desc'));
1970
+ });
1971
+ }
1972
+ else {
1973
+ sortOption = undefined;
1974
+ }
1975
+ }
1976
+ this.currentDataState.activeSortOption = sortOption;
1977
+ this.dataManagerSvc.updateDataState(this.currentDataState, this.viewConfig.id);
1978
+ });
1979
+ }
1980
+ updateColumnsInCurrentDataState(columnApi) {
1981
+ const columnOrder = this.getColumnOrder(columnApi);
1982
+ const viewState = this.currentDataState.getViewStateById(this.viewConfig.id);
1983
+ if (viewState.displayedColumnIds.length !== columnOrder.length ||
1984
+ viewState.displayedColumnIds.some((col, i) => col !== columnOrder[i])) {
1985
+ viewState.displayedColumnIds = columnOrder;
1986
+ this.dataManagerSvc.updateDataState(this.currentDataState.addOrUpdateView(this.viewConfig.id, viewState), this.viewConfig.id);
1987
+ }
1988
+ }
1989
+ getColumnOrder(columnApi) {
1990
+ return columnApi
1991
+ .getColumnState()
1992
+ .filter((state) => !state.hide)
1993
+ .map((state) => state.colId);
1994
+ }
1995
+ displayColumns(dataState) {
1996
+ const agGrid = this.currentAgGrid;
1997
+ const viewState = dataState.getViewStateById(this.viewConfig.id);
1998
+ let displayedColumnIds = [];
1999
+ /*istanbul ignore else*/
2000
+ if (viewState.displayedColumnIds) {
2001
+ displayedColumnIds = viewState.displayedColumnIds;
2002
+ }
2003
+ const columnOrder = this.getColumnOrder(agGrid.columnApi);
2004
+ if (displayedColumnIds.length !== columnOrder.length ||
2005
+ displayedColumnIds.some((col, i) => col !== columnOrder[i])) {
2006
+ const hideColumns = agGrid.columnApi
2007
+ .getColumnState()
2008
+ .map((col) => col.colId)
2009
+ .filter((colId) => !displayedColumnIds.includes(colId));
2010
+ agGrid.columnApi.setColumnsVisible(hideColumns, false);
2011
+ agGrid.columnApi.setColumnsVisible(displayedColumnIds, true);
2012
+ agGrid.columnApi.moveColumns(displayedColumnIds, 0);
2013
+ }
2014
+ }
2015
+ selectAll() {
2016
+ const agGrid = this.agGridList.first;
2017
+ agGrid.api.selectAll();
2018
+ }
2019
+ clearAll() {
2020
+ const agGrid = this.agGridList.first;
2021
+ agGrid.api.deselectAll();
2022
+ }
2023
+ }
2024
+ SkyAgGridDataManagerAdapterDirective.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridDataManagerAdapterDirective, deps: [{ token: i0.ChangeDetectorRef }, { token: i1$4.SkyDataManagerService }], target: i0.ɵɵFactoryTarget.Directive });
2025
+ SkyAgGridDataManagerAdapterDirective.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "14.2.0", type: SkyAgGridDataManagerAdapterDirective, selector: "[skyAgGridDataManagerAdapter]", inputs: { viewId: "viewId" }, queries: [{ propertyName: "agGridList", predicate: AgGridAngular, descendants: true }, { propertyName: "skyAgGridWrapperList", predicate: SkyAgGridWrapperComponent, descendants: true }], ngImport: i0 });
2026
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridDataManagerAdapterDirective, decorators: [{
2027
+ type: Directive,
2028
+ args: [{
2029
+ selector: '[skyAgGridDataManagerAdapter]',
2030
+ }]
2031
+ }], ctorParameters: function () { return [{ type: i0.ChangeDetectorRef }, { type: i1$4.SkyDataManagerService }]; }, propDecorators: { viewId: [{
2032
+ type: Input
2033
+ }], agGridList: [{
2034
+ type: ContentChildren,
2035
+ args: [AgGridAngular, { descendants: true }]
2036
+ }], skyAgGridWrapperList: [{
2037
+ type: ContentChildren,
2038
+ args: [SkyAgGridWrapperComponent, { descendants: true }]
2039
+ }] } });
2040
+
2041
+ /**
2042
+ * Component for rendering the inline delete template in the overlay.
2043
+ * @internal
2044
+ */
2045
+ class SkyAgGridRowDeleteComponent {
2046
+ }
2047
+ SkyAgGridRowDeleteComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridRowDeleteComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
2048
+ SkyAgGridRowDeleteComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.2.0", type: SkyAgGridRowDeleteComponent, selector: "ng-component", viewQueries: [{ propertyName: "inlineDeleteTemplateRef", first: true, predicate: ["inlineDeleteTemplateRef"], descendants: true, read: TemplateRef }, { propertyName: "inlineDeleteRefs", predicate: ["inlineDeleteRef"], descendants: true }], ngImport: i0, template: `
2049
+ <ng-template
2050
+ let-row
2051
+ let-tableWidth="tableWidth()"
2052
+ let-getRowDeleteItem="getRowDeleteItem"
2053
+ let-cancelRowDelete="cancelRowDelete"
2054
+ let-confirmRowDelete="confirmRowDelete"
2055
+ #inlineDeleteTemplateRef
2056
+ >
2057
+ <div
2058
+ class="sky-ag-grid-row-delete"
2059
+ [id]="'row-delete-ref-' + row.id"
2060
+ [ngStyle]="{
2061
+ height: row.rowHeight + 'px',
2062
+ position: 'fixed',
2063
+ width: tableWidth + 'px'
2064
+ }"
2065
+ #inlineDeleteRef
2066
+ >
2067
+ <sky-inline-delete
2068
+ [pending]="getRowDeleteItem(row).pending"
2069
+ (cancelTriggered)="cancelRowDelete(row)"
2070
+ (deleteTriggered)="confirmRowDelete(row)"
2071
+ ></sky-inline-delete>
2072
+ </div>
2073
+ </ng-template>
2074
+ `, isInline: true, dependencies: [{ kind: "directive", type: i2$3.NgStyle, selector: "[ngStyle]", inputs: ["ngStyle"] }, { kind: "component", type: i2$4.λ8, selector: "sky-inline-delete", inputs: ["pending"], outputs: ["cancelTriggered", "deleteTriggered"] }] });
2075
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridRowDeleteComponent, decorators: [{
2076
+ type: Component,
2077
+ args: [{
2078
+ template: `
2079
+ <ng-template
2080
+ let-row
2081
+ let-tableWidth="tableWidth()"
2082
+ let-getRowDeleteItem="getRowDeleteItem"
2083
+ let-cancelRowDelete="cancelRowDelete"
2084
+ let-confirmRowDelete="confirmRowDelete"
2085
+ #inlineDeleteTemplateRef
2086
+ >
2087
+ <div
2088
+ class="sky-ag-grid-row-delete"
2089
+ [id]="'row-delete-ref-' + row.id"
2090
+ [ngStyle]="{
2091
+ height: row.rowHeight + 'px',
2092
+ position: 'fixed',
2093
+ width: tableWidth + 'px'
2094
+ }"
2095
+ #inlineDeleteRef
2096
+ >
2097
+ <sky-inline-delete
2098
+ [pending]="getRowDeleteItem(row).pending"
2099
+ (cancelTriggered)="cancelRowDelete(row)"
2100
+ (deleteTriggered)="confirmRowDelete(row)"
2101
+ ></sky-inline-delete>
2102
+ </div>
2103
+ </ng-template>
2104
+ `,
2105
+ }]
2106
+ }], propDecorators: { inlineDeleteRefs: [{
2107
+ type: ViewChildren,
2108
+ args: ['inlineDeleteRef']
2109
+ }], inlineDeleteTemplateRef: [{
2110
+ type: ViewChild,
2111
+ args: ['inlineDeleteTemplateRef', { read: TemplateRef }]
2112
+ }] } });
2113
+
2114
+ class SkyAgGridRowDeleteDirective {
2115
+ constructor(affixService, changeDetector, elementRef, overlayService, viewContainerRef) {
2116
+ this.affixService = affixService;
2117
+ this.changeDetector = changeDetector;
2118
+ this.elementRef = elementRef;
2119
+ this.overlayService = overlayService;
2120
+ this.viewContainerRef = viewContainerRef;
2121
+ /**
2122
+ * Emits a `SkyAgGridRowDeleteCancelArgs` object when a row's inline delete is cancelled.
2123
+ */
2124
+ this.rowDeleteCancel = new EventEmitter();
2125
+ /**
2126
+ * Emits a `SkyAgGridRowDeleteConfirmArgs` object when a row's inline delete is confirmed.
2127
+ */
2128
+ this.rowDeleteConfirm = new EventEmitter();
2129
+ /**
2130
+ * Emits when the list of ids of the data in the rows where inline deletes are shown changes.
2131
+ */
2132
+ this.rowDeleteIdsChange = new EventEmitter();
2133
+ this.rowDeleteConfigs = [];
2134
+ this.ngUnsubscribe = new Subject();
2135
+ this.rowDeleteContents = {};
2136
+ }
2137
+ /**
2138
+ * Specifies the ids of the data in the rows on which inline delete's should be shown.
2139
+ */
2140
+ set rowDeleteIds(value) {
2141
+ this._rowDeleteIds = value;
2142
+ if (!value) {
2143
+ for (const config of this.rowDeleteConfigs) {
2144
+ this.destroyRowDelete(config.id);
2145
+ }
2146
+ this.changeDetector.markForCheck();
2147
+ return;
2148
+ }
2149
+ for (const id of value) {
2150
+ const existingConfig = this.rowDeleteConfigs.find((config) => config.id === id);
2151
+ if (existingConfig) {
2152
+ existingConfig.pending = false;
2153
+ }
2154
+ else {
2155
+ this.rowDeleteConfigs.push({
2156
+ id: id,
2157
+ pending: false,
2158
+ });
2159
+ const overlay = this.overlayService.create({
2160
+ enableScroll: true,
2161
+ showBackdrop: false,
2162
+ closeOnNavigation: true,
2163
+ enableClose: false,
2164
+ enablePointerEvents: true,
2165
+ });
2166
+ overlay.attachTemplate(this.rowDeleteComponent.inlineDeleteTemplateRef, {
2167
+ $implicit: this.agGrid.api.getRowNode(id),
2168
+ tableWidth: () => {
2169
+ return this.tableWidth;
2170
+ },
2171
+ getRowDeleteItem: (row) => this.getRowDeleteItem(row),
2172
+ cancelRowDelete: (row) => this.cancelRowDelete(row),
2173
+ confirmRowDelete: (row) => this.confirmRowDelete(row),
2174
+ });
2175
+ /**
2176
+ * We are manually setting the z-index here because overlays will always be on top of
2177
+ * the omnibar. This manual setting is 2 less than the omnibar's z-index of 1000 and one less than
2178
+ * the header row's viewkeeper which is 999. We discussed changing the overlay service to allow for this
2179
+ * but decided against that change at this time due to its niche nature.
2180
+ */
2181
+ overlay.componentRef.instance.zIndex = '998';
2182
+ setTimeout(() => {
2183
+ const inlineDeleteRef = this.rowDeleteComponent.inlineDeleteRefs
2184
+ .toArray()
2185
+ .find((elRef) => {
2186
+ return elRef.nativeElement.id === 'row-delete-ref-' + id;
2187
+ });
2188
+ const affixer = this.affixService.createAffixer(inlineDeleteRef);
2189
+ this.affixToRow(affixer, id);
2190
+ this.rowDeleteContents[id] = {
2191
+ affixer: affixer,
2192
+ overlay: overlay,
2193
+ };
2194
+ });
2195
+ }
2196
+ }
2197
+ for (const config of this.rowDeleteConfigs) {
2198
+ if (value.indexOf(config.id) < 0) {
2199
+ this.destroyRowDelete(config.id);
2200
+ }
2201
+ }
2202
+ this.changeDetector.markForCheck();
2203
+ }
2204
+ get rowDeleteIds() {
2205
+ return this._rowDeleteIds;
2206
+ }
2207
+ get tableWidth() {
2208
+ return this.elementRef.nativeElement.querySelectorAll('.sky-ag-grid')[0]
2209
+ .offsetWidth;
2210
+ }
2211
+ ngAfterContentInit() {
2212
+ this.rowDeleteComponent = this.viewContainerRef.createComponent(SkyAgGridRowDeleteComponent).instance;
2213
+ this.agGrid.rowDataUpdated
2214
+ .pipe(takeUntil(this.ngUnsubscribe))
2215
+ .subscribe(() => {
2216
+ this.updateRowDeleteStates();
2217
+ });
2218
+ this.agGrid.sortChanged
2219
+ .pipe(takeUntil(this.ngUnsubscribe))
2220
+ .subscribe(() => {
2221
+ this.updateRowDeleteStates();
2222
+ });
2223
+ this.agGrid.filterChanged
2224
+ .pipe(takeUntil(this.ngUnsubscribe))
2225
+ .subscribe(() => {
2226
+ this.updateRowDeleteStates();
2227
+ });
2228
+ }
2229
+ ngOnDestroy() {
2230
+ this.ngUnsubscribe.next();
2231
+ this.ngUnsubscribe.complete();
2232
+ Object.keys(this.rowDeleteContents).forEach((id) => {
2233
+ this.destroyRowDelete(id);
2234
+ });
2235
+ }
2236
+ cancelRowDelete(row) {
2237
+ this.rowDeleteConfigs = this.rowDeleteConfigs.filter((config) => config.id !== row.id);
2238
+ this.rowDeleteCancel.emit({ id: row.id });
2239
+ this.destroyRowDelete(row.id);
2240
+ }
2241
+ confirmRowDelete(row) {
2242
+ this.rowDeleteConfigs.find((config) => config.id === row.id).pending = true;
2243
+ this.rowDeleteConfirm.emit({ id: row.id });
2244
+ }
2245
+ getRowDeleteItem(row) {
2246
+ return this.rowDeleteConfigs.find((rowDelete) => rowDelete.id === row.id);
2247
+ }
2248
+ affixToRow(affixer, id) {
2249
+ let rowElement = this.elementRef.nativeElement.querySelector(`
2250
+ [row-id="${id}"] div[aria-colindex="1"],
2251
+ .ag-row.sky-ag-grid-row-${id} div[aria-colindex="1"]
2252
+ `);
2253
+ // This covers cases where AG Grid places the column index on an inner element (such as with the `enableCellTextSelection` option)
2254
+ // This appears to have been fixed by AG Grid in version 24 and so it is not testable after that version.
2255
+ /* istanbul ignore if */
2256
+ if (!rowElement) {
2257
+ const columns = this.elementRef.nativeElement.querySelectorAll('[row-id="' + id + '"] > div');
2258
+ for (let i = 0; i < columns.length; i++) {
2259
+ if (columns[i].querySelector('[aria-colindex="1"]')) {
2260
+ rowElement = columns[i];
2261
+ break;
2262
+ }
2263
+ }
2264
+ }
2265
+ affixer.affixTo(rowElement, {
2266
+ autoFitContext: SkyAffixAutoFitContext.Viewport,
2267
+ isSticky: true,
2268
+ placement: 'above',
2269
+ verticalAlignment: 'top',
2270
+ horizontalAlignment: 'left',
2271
+ enableAutoFit: false,
2272
+ });
2273
+ }
2274
+ destroyRowDelete(id) {
2275
+ var _a;
2276
+ const rowDeleteContents = this.rowDeleteContents[id];
2277
+ /* sanity check */
2278
+ /* istanbul ignore else */
2279
+ if (rowDeleteContents) {
2280
+ rowDeleteContents.affixer.destroy();
2281
+ this.overlayService.close(rowDeleteContents.overlay);
2282
+ delete this.rowDeleteContents[id];
2283
+ this.rowDeleteConfigs = this.rowDeleteConfigs.filter((config) => config.id !== id);
2284
+ this._rowDeleteIds = (_a = this.rowDeleteIds) === null || _a === void 0 ? void 0 : _a.filter((arrayId) => arrayId !== id);
2285
+ this.rowDeleteIdsChange.emit(this._rowDeleteIds);
2286
+ }
2287
+ }
2288
+ updateRowDeleteStates() {
2289
+ this.rowDeleteConfigs.forEach((config) => {
2290
+ if (!this.agGrid.api.getRowNode(config.id)) {
2291
+ this.destroyRowDelete(config.id);
2292
+ }
2293
+ else {
2294
+ // We must reaffix things when the data changes because the rows rerender and the previous element that the delete was affixed
2295
+ // to is destroyed.
2296
+ this.affixToRow(this.rowDeleteContents[config.id].affixer, config.id);
2297
+ }
2298
+ });
2299
+ this.changeDetector.markForCheck();
2300
+ }
2301
+ }
2302
+ SkyAgGridRowDeleteDirective.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridRowDeleteDirective, deps: [{ token: i1.SkyAffixService }, { token: i0.ChangeDetectorRef }, { token: i0.ElementRef }, { token: i1.SkyOverlayService }, { token: i0.ViewContainerRef }], target: i0.ɵɵFactoryTarget.Directive });
2303
+ SkyAgGridRowDeleteDirective.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "14.2.0", type: SkyAgGridRowDeleteDirective, selector: "[skyAgGridRowDelete]", inputs: { rowDeleteIds: "rowDeleteIds" }, outputs: { rowDeleteCancel: "rowDeleteCancel", rowDeleteConfirm: "rowDeleteConfirm", rowDeleteIdsChange: "rowDeleteIdsChange" }, queries: [{ propertyName: "agGrid", first: true, predicate: AgGridAngular, descendants: true }], ngImport: i0 });
2304
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridRowDeleteDirective, decorators: [{
2305
+ type: Directive,
2306
+ args: [{
2307
+ selector: '[skyAgGridRowDelete]',
2308
+ }]
2309
+ }], ctorParameters: function () { return [{ type: i1.SkyAffixService }, { type: i0.ChangeDetectorRef }, { type: i0.ElementRef }, { type: i1.SkyOverlayService }, { type: i0.ViewContainerRef }]; }, propDecorators: { rowDeleteIds: [{
2310
+ type: Input
2311
+ }], rowDeleteCancel: [{
2312
+ type: Output
2313
+ }], rowDeleteConfirm: [{
2314
+ type: Output
2315
+ }], rowDeleteIdsChange: [{
2316
+ type: Output
2317
+ }], agGrid: [{
2318
+ type: ContentChild,
2319
+ args: [AgGridAngular]
2320
+ }] } });
2321
+
2322
+ /**
2323
+ * NOTICE: DO NOT MODIFY THIS FILE!
2324
+ * The contents of this file were automatically generated by
2325
+ * the 'ng generate @skyux/i18n:lib-resources-module lib/modules/shared/sky-ag-grid' schematic.
2326
+ * To update this file, simply rerun the command.
2327
+ */
2328
+ const RESOURCES = {
2329
+ 'EN-US': {
2330
+ sky_ag_grid_row_selector_aria_label: {
2331
+ message: 'Row selector for row {0}',
2332
+ },
2333
+ sky_ag_grid_cell_editor_number_aria_label: {
2334
+ message: 'Editable number {0} for row {1}',
2335
+ },
2336
+ sky_ag_grid_cell_editor_text_aria_label: {
2337
+ message: 'Editable text {0} for row {1}',
2338
+ },
2339
+ sky_ag_grid_cell_editor_autocomplete_aria_label: {
2340
+ message: 'Editable autocomplete {0} for row {1}',
2341
+ },
2342
+ sky_ag_grid_cell_renderer_number_validator_message: {
2343
+ message: 'Enter a valid number.',
2344
+ },
2345
+ sky_ag_grid_cell_renderer_currency_validator_message: {
2346
+ message: 'Enter a valid currency.',
2347
+ },
2348
+ skyux_lookup_tokens_summary: { message: '{0} items selected' },
2349
+ sky_ag_grid_cell_editor_currency_aria_label: {
2350
+ message: 'Editable currency {0} for row {1}',
2351
+ },
2352
+ sky_ag_grid_column_group_header_expand_aria_label: {
2353
+ message: 'Expand column group {0}',
2354
+ },
2355
+ sky_ag_grid_column_group_header_collapse_aria_label: {
2356
+ message: 'Collapse column group {0}',
2357
+ },
2358
+ },
2359
+ };
2360
+ class SkyAgGridResourcesProvider {
2361
+ getString(localeInfo, name) {
2362
+ return getLibStringForLocale(RESOURCES, localeInfo.locale, name);
2363
+ }
2364
+ }
2365
+ /**
2366
+ * Import into any component library module that needs to use resource strings.
2367
+ */
2368
+ class SkyAgGridResourcesModule {
2369
+ }
2370
+ SkyAgGridResourcesModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridResourcesModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
2371
+ SkyAgGridResourcesModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridResourcesModule, exports: [SkyI18nModule] });
2372
+ SkyAgGridResourcesModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridResourcesModule, providers: [
2373
+ {
2374
+ provide: SKY_LIB_RESOURCES_PROVIDERS,
2375
+ useClass: SkyAgGridResourcesProvider,
2376
+ multi: true,
2377
+ },
2378
+ ], imports: [SkyI18nModule] });
2379
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridResourcesModule, decorators: [{
2380
+ type: NgModule,
2381
+ args: [{
2382
+ exports: [SkyI18nModule],
2383
+ providers: [
2384
+ {
2385
+ provide: SKY_LIB_RESOURCES_PROVIDERS,
2386
+ useClass: SkyAgGridResourcesProvider,
2387
+ multi: true,
2388
+ },
2389
+ ],
2390
+ }]
2391
+ }] });
2392
+
2393
+ class SkyAgGridCellEditorAutocompleteModule {
2394
+ }
2395
+ SkyAgGridCellEditorAutocompleteModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellEditorAutocompleteModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
2396
+ SkyAgGridCellEditorAutocompleteModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellEditorAutocompleteModule, declarations: [SkyAgGridCellEditorAutocompleteComponent], imports: [ReactiveFormsModule,
2397
+ SkyAgGridResourcesModule,
2398
+ SkyAutocompleteModule], exports: [SkyAgGridCellEditorAutocompleteComponent] });
2399
+ SkyAgGridCellEditorAutocompleteModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellEditorAutocompleteModule, imports: [ReactiveFormsModule,
2400
+ SkyAgGridResourcesModule,
2401
+ SkyAutocompleteModule] });
2402
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellEditorAutocompleteModule, decorators: [{
2403
+ type: NgModule,
2404
+ args: [{
2405
+ imports: [
2406
+ ReactiveFormsModule,
2407
+ SkyAgGridResourcesModule,
2408
+ SkyAutocompleteModule,
2409
+ ],
2410
+ declarations: [SkyAgGridCellEditorAutocompleteComponent],
2411
+ exports: [SkyAgGridCellEditorAutocompleteComponent],
2412
+ }]
2413
+ }] });
2414
+
2415
+ class SkyAgGridCellEditorCurrencyModule {
2416
+ }
2417
+ SkyAgGridCellEditorCurrencyModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellEditorCurrencyModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
2418
+ SkyAgGridCellEditorCurrencyModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellEditorCurrencyModule, declarations: [SkyAgGridCellEditorCurrencyComponent], imports: [SkyAgGridResourcesModule,
2419
+ ReactiveFormsModule,
2420
+ SkyAutonumericModule], exports: [SkyAgGridCellEditorCurrencyComponent] });
2421
+ SkyAgGridCellEditorCurrencyModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellEditorCurrencyModule, imports: [SkyAgGridResourcesModule,
2422
+ ReactiveFormsModule,
2423
+ SkyAutonumericModule] });
2424
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellEditorCurrencyModule, decorators: [{
2425
+ type: NgModule,
2426
+ args: [{
2427
+ imports: [
2428
+ SkyAgGridResourcesModule,
2429
+ ReactiveFormsModule,
2430
+ SkyAutonumericModule,
2431
+ ],
2432
+ declarations: [SkyAgGridCellEditorCurrencyComponent],
2433
+ exports: [SkyAgGridCellEditorCurrencyComponent],
2434
+ }]
2435
+ }] });
2436
+
2437
+ class SkyAgGridCellEditorDatepickerModule {
2438
+ }
2439
+ SkyAgGridCellEditorDatepickerModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellEditorDatepickerModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
2440
+ SkyAgGridCellEditorDatepickerModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellEditorDatepickerModule, declarations: [SkyAgGridCellEditorDatepickerComponent], imports: [SkyDatepickerModule, ReactiveFormsModule], exports: [SkyAgGridCellEditorDatepickerComponent] });
2441
+ SkyAgGridCellEditorDatepickerModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellEditorDatepickerModule, imports: [SkyDatepickerModule, ReactiveFormsModule] });
2442
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellEditorDatepickerModule, decorators: [{
2443
+ type: NgModule,
2444
+ args: [{
2445
+ imports: [SkyDatepickerModule, ReactiveFormsModule],
2446
+ declarations: [SkyAgGridCellEditorDatepickerComponent],
2447
+ exports: [SkyAgGridCellEditorDatepickerComponent],
2448
+ }]
2449
+ }] });
2450
+
2451
+ class SkyAgGridCellEditorLookupModule {
2452
+ }
2453
+ SkyAgGridCellEditorLookupModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellEditorLookupModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
2454
+ SkyAgGridCellEditorLookupModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellEditorLookupModule, declarations: [SkyAgGridCellEditorLookupComponent], imports: [CommonModule,
2455
+ ReactiveFormsModule,
2456
+ SkyI18nModule,
2457
+ SkyInputBoxModule,
2458
+ SkyLookupModule], exports: [SkyAgGridCellEditorLookupComponent] });
2459
+ SkyAgGridCellEditorLookupModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellEditorLookupModule, imports: [CommonModule,
2460
+ ReactiveFormsModule,
2461
+ SkyI18nModule,
2462
+ SkyInputBoxModule,
2463
+ SkyLookupModule] });
2464
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellEditorLookupModule, decorators: [{
2465
+ type: NgModule,
2466
+ args: [{
2467
+ declarations: [SkyAgGridCellEditorLookupComponent],
2468
+ exports: [SkyAgGridCellEditorLookupComponent],
2469
+ imports: [
2470
+ CommonModule,
2471
+ ReactiveFormsModule,
2472
+ SkyI18nModule,
2473
+ SkyInputBoxModule,
2474
+ SkyLookupModule,
2475
+ ],
2476
+ }]
2477
+ }] });
2478
+
2479
+ class SkyAgGridCellEditorNumberModule {
2480
+ }
2481
+ SkyAgGridCellEditorNumberModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellEditorNumberModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
2482
+ SkyAgGridCellEditorNumberModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellEditorNumberModule, declarations: [SkyAgGridCellEditorNumberComponent], imports: [SkyAgGridResourcesModule, ReactiveFormsModule], exports: [SkyAgGridCellEditorNumberComponent] });
2483
+ SkyAgGridCellEditorNumberModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellEditorNumberModule, imports: [SkyAgGridResourcesModule, ReactiveFormsModule] });
2484
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellEditorNumberModule, decorators: [{
2485
+ type: NgModule,
2486
+ args: [{
2487
+ imports: [SkyAgGridResourcesModule, ReactiveFormsModule],
2488
+ declarations: [SkyAgGridCellEditorNumberComponent],
2489
+ exports: [SkyAgGridCellEditorNumberComponent],
2490
+ }]
2491
+ }] });
2492
+
2493
+ class SkyAgGridCellEditorTextModule {
2494
+ }
2495
+ SkyAgGridCellEditorTextModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellEditorTextModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
2496
+ SkyAgGridCellEditorTextModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellEditorTextModule, declarations: [SkyAgGridCellEditorTextComponent], imports: [SkyAgGridResourcesModule, ReactiveFormsModule], exports: [SkyAgGridCellEditorTextComponent] });
2497
+ SkyAgGridCellEditorTextModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellEditorTextModule, imports: [SkyAgGridResourcesModule, ReactiveFormsModule] });
2498
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellEditorTextModule, decorators: [{
2499
+ type: NgModule,
2500
+ args: [{
2501
+ imports: [SkyAgGridResourcesModule, ReactiveFormsModule],
2502
+ declarations: [SkyAgGridCellEditorTextComponent],
2503
+ exports: [SkyAgGridCellEditorTextComponent],
2504
+ }]
2505
+ }] });
2506
+
2507
+ class SkyAgGridCellValidatorModule {
2508
+ }
2509
+ SkyAgGridCellValidatorModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellValidatorModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
2510
+ SkyAgGridCellValidatorModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellValidatorModule, declarations: [SkyAgGridCellValidatorTooltipComponent], imports: [CommonModule, SkyPopoverModule, SkyStatusIndicatorModule], exports: [SkyAgGridCellValidatorTooltipComponent] });
2511
+ SkyAgGridCellValidatorModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellValidatorModule, imports: [CommonModule, SkyPopoverModule, SkyStatusIndicatorModule] });
2512
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellValidatorModule, decorators: [{
2513
+ type: NgModule,
2514
+ args: [{
2515
+ declarations: [SkyAgGridCellValidatorTooltipComponent],
2516
+ exports: [SkyAgGridCellValidatorTooltipComponent],
2517
+ imports: [CommonModule, SkyPopoverModule, SkyStatusIndicatorModule],
2518
+ }]
2519
+ }] });
2520
+
2521
+ class SkyAgGridCellRendererCurrencyModule {
2522
+ }
2523
+ SkyAgGridCellRendererCurrencyModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellRendererCurrencyModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
2524
+ SkyAgGridCellRendererCurrencyModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellRendererCurrencyModule, declarations: [SkyAgGridCellRendererCurrencyComponent,
2525
+ SkyAgGridCellRendererCurrencyValidatorComponent], imports: [CommonModule,
2526
+ SkyAgGridResourcesModule,
2527
+ SkyAgGridCellValidatorModule,
2528
+ FormsModule,
2529
+ SkyNumericModule], exports: [SkyAgGridCellRendererCurrencyComponent,
2530
+ SkyAgGridCellRendererCurrencyValidatorComponent] });
2531
+ SkyAgGridCellRendererCurrencyModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellRendererCurrencyModule, imports: [CommonModule,
2532
+ SkyAgGridResourcesModule,
2533
+ SkyAgGridCellValidatorModule,
2534
+ FormsModule,
2535
+ SkyNumericModule] });
2536
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellRendererCurrencyModule, decorators: [{
2537
+ type: NgModule,
2538
+ args: [{
2539
+ imports: [
2540
+ CommonModule,
2541
+ SkyAgGridResourcesModule,
2542
+ SkyAgGridCellValidatorModule,
2543
+ FormsModule,
2544
+ SkyNumericModule,
2545
+ ],
2546
+ declarations: [
2547
+ SkyAgGridCellRendererCurrencyComponent,
2548
+ SkyAgGridCellRendererCurrencyValidatorComponent,
2549
+ ],
2550
+ exports: [
2551
+ SkyAgGridCellRendererCurrencyComponent,
2552
+ SkyAgGridCellRendererCurrencyValidatorComponent,
2553
+ ],
2554
+ }]
2555
+ }] });
2556
+
2557
+ class SkyAgGridCellRendererLookupModule {
2558
+ }
2559
+ SkyAgGridCellRendererLookupModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellRendererLookupModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
2560
+ SkyAgGridCellRendererLookupModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellRendererLookupModule, declarations: [SkyAgGridCellRendererLookupComponent], imports: [CommonModule, SkyAgGridResourcesModule], exports: [SkyAgGridCellRendererLookupComponent] });
2561
+ SkyAgGridCellRendererLookupModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellRendererLookupModule, imports: [CommonModule, SkyAgGridResourcesModule] });
2562
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellRendererLookupModule, decorators: [{
2563
+ type: NgModule,
2564
+ args: [{
2565
+ declarations: [SkyAgGridCellRendererLookupComponent],
2566
+ exports: [SkyAgGridCellRendererLookupComponent],
2567
+ imports: [CommonModule, SkyAgGridResourcesModule],
2568
+ }]
2569
+ }] });
2570
+
2571
+ class SkyAgGridCellRendererRowSelectorModule {
2572
+ }
2573
+ SkyAgGridCellRendererRowSelectorModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellRendererRowSelectorModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
2574
+ SkyAgGridCellRendererRowSelectorModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellRendererRowSelectorModule, declarations: [SkyAgGridCellRendererRowSelectorComponent], imports: [SkyAgGridResourcesModule, SkyCheckboxModule, FormsModule], exports: [SkyAgGridCellRendererRowSelectorComponent] });
2575
+ SkyAgGridCellRendererRowSelectorModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellRendererRowSelectorModule, imports: [SkyAgGridResourcesModule, SkyCheckboxModule, FormsModule] });
2576
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellRendererRowSelectorModule, decorators: [{
2577
+ type: NgModule,
2578
+ args: [{
2579
+ imports: [SkyAgGridResourcesModule, SkyCheckboxModule, FormsModule],
2580
+ declarations: [SkyAgGridCellRendererRowSelectorComponent],
2581
+ exports: [SkyAgGridCellRendererRowSelectorComponent],
2582
+ }]
2583
+ }] });
2584
+
2585
+ class SkyAgGridCellRendererValidatorTooltipModule {
2586
+ }
2587
+ SkyAgGridCellRendererValidatorTooltipModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellRendererValidatorTooltipModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
2588
+ SkyAgGridCellRendererValidatorTooltipModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellRendererValidatorTooltipModule, declarations: [SkyAgGridCellRendererValidatorTooltipComponent], imports: [SkyAgGridCellValidatorModule], exports: [SkyAgGridCellRendererValidatorTooltipComponent] });
2589
+ SkyAgGridCellRendererValidatorTooltipModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellRendererValidatorTooltipModule, imports: [SkyAgGridCellValidatorModule] });
2590
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridCellRendererValidatorTooltipModule, decorators: [{
2591
+ type: NgModule,
2592
+ args: [{
2593
+ declarations: [SkyAgGridCellRendererValidatorTooltipComponent],
2594
+ exports: [SkyAgGridCellRendererValidatorTooltipComponent],
2595
+ imports: [SkyAgGridCellValidatorModule],
2596
+ }]
2597
+ }] });
2598
+
2599
+ class SkyAgGridModule {
2600
+ }
2601
+ SkyAgGridModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
2602
+ SkyAgGridModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridModule, declarations: [SkyAgGridDataManagerAdapterDirective,
2603
+ SkyAgGridHeaderComponent,
2604
+ SkyAgGridHeaderGroupComponent,
2605
+ SkyAgGridRowDeleteComponent,
2606
+ SkyAgGridRowDeleteDirective,
2607
+ SkyAgGridWrapperComponent], imports: [AgGridModule,
2608
+ CommonModule,
2609
+ SkyAgGridCellEditorAutocompleteModule,
2610
+ SkyAgGridCellEditorDatepickerModule,
2611
+ SkyAgGridCellEditorLookupModule,
2612
+ SkyAgGridCellEditorNumberModule,
2613
+ SkyAgGridCellEditorCurrencyModule,
2614
+ SkyAgGridCellRendererCurrencyModule,
2615
+ SkyAgGridCellRendererLookupModule,
2616
+ SkyAgGridCellRendererRowSelectorModule,
2617
+ SkyAgGridCellRendererValidatorTooltipModule,
2618
+ SkyAgGridCellValidatorModule,
2619
+ SkyAgGridCellEditorTextModule,
2620
+ SkyDataManagerModule,
2621
+ SkyI18nModule,
2622
+ SkyIconModule,
2623
+ SkyInlineDeleteModule,
2624
+ SkyViewkeeperModule,
2625
+ SkyThemeModule], exports: [SkyAgGridDataManagerAdapterDirective,
2626
+ SkyAgGridRowDeleteComponent,
2627
+ SkyAgGridRowDeleteDirective,
2628
+ SkyAgGridWrapperComponent,
2629
+ SkyAgGridHeaderComponent,
2630
+ SkyAgGridHeaderGroupComponent] });
2631
+ SkyAgGridModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridModule, imports: [AgGridModule,
2632
+ CommonModule,
2633
+ SkyAgGridCellEditorAutocompleteModule,
2634
+ SkyAgGridCellEditorDatepickerModule,
2635
+ SkyAgGridCellEditorLookupModule,
2636
+ SkyAgGridCellEditorNumberModule,
2637
+ SkyAgGridCellEditorCurrencyModule,
2638
+ SkyAgGridCellRendererCurrencyModule,
2639
+ SkyAgGridCellRendererLookupModule,
2640
+ SkyAgGridCellRendererRowSelectorModule,
2641
+ SkyAgGridCellRendererValidatorTooltipModule,
2642
+ SkyAgGridCellValidatorModule,
2643
+ SkyAgGridCellEditorTextModule,
2644
+ SkyDataManagerModule,
2645
+ SkyI18nModule,
2646
+ SkyIconModule,
2647
+ SkyInlineDeleteModule,
2648
+ SkyViewkeeperModule,
2649
+ SkyThemeModule] });
2650
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.0", ngImport: i0, type: SkyAgGridModule, decorators: [{
2651
+ type: NgModule,
2652
+ args: [{
2653
+ declarations: [
2654
+ SkyAgGridDataManagerAdapterDirective,
2655
+ SkyAgGridHeaderComponent,
2656
+ SkyAgGridHeaderGroupComponent,
2657
+ SkyAgGridRowDeleteComponent,
2658
+ SkyAgGridRowDeleteDirective,
2659
+ SkyAgGridWrapperComponent,
2660
+ ],
2661
+ imports: [
2662
+ AgGridModule,
2663
+ CommonModule,
2664
+ SkyAgGridCellEditorAutocompleteModule,
2665
+ SkyAgGridCellEditorDatepickerModule,
2666
+ SkyAgGridCellEditorLookupModule,
2667
+ SkyAgGridCellEditorNumberModule,
2668
+ SkyAgGridCellEditorCurrencyModule,
2669
+ SkyAgGridCellRendererCurrencyModule,
2670
+ SkyAgGridCellRendererLookupModule,
2671
+ SkyAgGridCellRendererRowSelectorModule,
2672
+ SkyAgGridCellRendererValidatorTooltipModule,
2673
+ SkyAgGridCellValidatorModule,
2674
+ SkyAgGridCellEditorTextModule,
2675
+ SkyDataManagerModule,
2676
+ SkyI18nModule,
2677
+ SkyIconModule,
2678
+ SkyInlineDeleteModule,
2679
+ SkyViewkeeperModule,
2680
+ SkyThemeModule,
2681
+ ],
2682
+ exports: [
2683
+ SkyAgGridDataManagerAdapterDirective,
2684
+ SkyAgGridRowDeleteComponent,
2685
+ SkyAgGridRowDeleteDirective,
2686
+ SkyAgGridWrapperComponent,
2687
+ SkyAgGridHeaderComponent,
2688
+ SkyAgGridHeaderGroupComponent,
2689
+ ],
2690
+ }]
2691
+ }] });
2692
+
2625
2693
  // Export any types that should be included in the root.
2626
2694
 
2627
2695
  /**