@clr/angular 18.3.0 → 18.4.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/fesm2022/clr-angular-accordion.mjs +28 -28
- package/fesm2022/clr-angular-accordion.mjs.map +1 -1
- package/fesm2022/clr-angular-button.mjs +27 -27
- package/fesm2022/clr-angular-button.mjs.map +1 -1
- package/fesm2022/clr-angular-card.mjs +417 -0
- package/fesm2022/clr-angular-card.mjs.map +1 -0
- package/fesm2022/clr-angular-collapsible-panel.mjs +6 -6
- package/fesm2022/clr-angular-collapsible-panel.mjs.map +1 -1
- package/fesm2022/clr-angular-data-datagrid.mjs +1105 -352
- package/fesm2022/clr-angular-data-datagrid.mjs.map +1 -1
- package/fesm2022/clr-angular-data-stack-view.mjs +23 -23
- package/fesm2022/clr-angular-data-stack-view.mjs.map +1 -1
- package/fesm2022/clr-angular-data-tree-view.mjs +283 -48
- package/fesm2022/clr-angular-data-tree-view.mjs.map +1 -1
- package/fesm2022/clr-angular-data.mjs +4 -4
- package/fesm2022/clr-angular-data.mjs.map +1 -1
- package/fesm2022/clr-angular-emphasis-alert.mjs +26 -26
- package/fesm2022/clr-angular-emphasis-alert.mjs.map +1 -1
- package/fesm2022/clr-angular-emphasis-badge.mjs +3 -3
- package/fesm2022/clr-angular-emphasis-badge.mjs.map +1 -1
- package/fesm2022/clr-angular-emphasis-label.mjs +3 -3
- package/fesm2022/clr-angular-emphasis-label.mjs.map +1 -1
- package/fesm2022/clr-angular-emphasis.mjs +4 -4
- package/fesm2022/clr-angular-emphasis.mjs.map +1 -1
- package/fesm2022/clr-angular-forms-checkbox.mjs +13 -13
- package/fesm2022/clr-angular-forms-checkbox.mjs.map +1 -1
- package/fesm2022/clr-angular-forms-combobox.mjs +35 -35
- package/fesm2022/clr-angular-forms-combobox.mjs.map +1 -1
- package/fesm2022/clr-angular-forms-common.mjs +69 -69
- package/fesm2022/clr-angular-forms-common.mjs.map +1 -1
- package/fesm2022/clr-angular-forms-datalist.mjs +17 -17
- package/fesm2022/clr-angular-forms-datalist.mjs.map +1 -1
- package/fesm2022/clr-angular-forms-datepicker.mjs +73 -73
- package/fesm2022/clr-angular-forms-datepicker.mjs.map +1 -1
- package/fesm2022/clr-angular-forms-file-input.mjs +36 -36
- package/fesm2022/clr-angular-forms-file-input.mjs.map +1 -1
- package/fesm2022/clr-angular-forms-input.mjs +10 -10
- package/fesm2022/clr-angular-forms-input.mjs.map +1 -1
- package/fesm2022/clr-angular-forms-number-input.mjs +11 -11
- package/fesm2022/clr-angular-forms-number-input.mjs.map +1 -1
- package/fesm2022/clr-angular-forms-password.mjs +11 -11
- package/fesm2022/clr-angular-forms-password.mjs.map +1 -1
- package/fesm2022/clr-angular-forms-radio.mjs +13 -13
- package/fesm2022/clr-angular-forms-radio.mjs.map +1 -1
- package/fesm2022/clr-angular-forms-range.mjs +10 -10
- package/fesm2022/clr-angular-forms-range.mjs.map +1 -1
- package/fesm2022/clr-angular-forms-select.mjs +10 -10
- package/fesm2022/clr-angular-forms-select.mjs.map +1 -1
- package/fesm2022/clr-angular-forms-textarea.mjs +10 -10
- package/fesm2022/clr-angular-forms-textarea.mjs.map +1 -1
- package/fesm2022/clr-angular-forms.mjs +4 -4
- package/fesm2022/clr-angular-forms.mjs.map +1 -1
- package/fesm2022/clr-angular-icon.mjs +81 -41
- package/fesm2022/clr-angular-icon.mjs.map +1 -1
- package/fesm2022/clr-angular-layout-breadcrumbs.mjs +10 -10
- package/fesm2022/clr-angular-layout-breadcrumbs.mjs.map +1 -1
- package/fesm2022/clr-angular-layout-main-container.mjs +7 -7
- package/fesm2022/clr-angular-layout-main-container.mjs.map +1 -1
- package/fesm2022/clr-angular-layout-nav.mjs +22 -22
- package/fesm2022/clr-angular-layout-nav.mjs.map +1 -1
- package/fesm2022/clr-angular-layout-tabs.mjs +35 -35
- package/fesm2022/clr-angular-layout-tabs.mjs.map +1 -1
- package/fesm2022/clr-angular-layout-vertical-nav.mjs +31 -31
- package/fesm2022/clr-angular-layout-vertical-nav.mjs.map +1 -1
- package/fesm2022/clr-angular-layout.mjs +4 -4
- package/fesm2022/clr-angular-layout.mjs.map +1 -1
- package/fesm2022/clr-angular-modal.mjs +26 -26
- package/fesm2022/clr-angular-modal.mjs.map +1 -1
- package/fesm2022/clr-angular-popover-common.mjs +69 -34
- package/fesm2022/clr-angular-popover-common.mjs.map +1 -1
- package/fesm2022/clr-angular-popover-dropdown.mjs +63 -26
- package/fesm2022/clr-angular-popover-dropdown.mjs.map +1 -1
- package/fesm2022/clr-angular-popover-signpost.mjs +27 -25
- package/fesm2022/clr-angular-popover-signpost.mjs.map +1 -1
- package/fesm2022/clr-angular-popover-tooltip.mjs +19 -19
- package/fesm2022/clr-angular-popover-tooltip.mjs.map +1 -1
- package/fesm2022/clr-angular-popover.mjs +4 -4
- package/fesm2022/clr-angular-popover.mjs.map +1 -1
- package/fesm2022/clr-angular-progress-progress-bars.mjs +7 -7
- package/fesm2022/clr-angular-progress-progress-bars.mjs.map +1 -1
- package/fesm2022/clr-angular-progress-spinner.mjs +7 -7
- package/fesm2022/clr-angular-progress-spinner.mjs.map +1 -1
- package/fesm2022/clr-angular-stepper.mjs +31 -31
- package/fesm2022/clr-angular-stepper.mjs.map +1 -1
- package/fesm2022/clr-angular-timeline.mjs +23 -23
- package/fesm2022/clr-angular-timeline.mjs.map +1 -1
- package/fesm2022/clr-angular-utils-conditional.mjs +16 -16
- package/fesm2022/clr-angular-utils-conditional.mjs.map +1 -1
- package/fesm2022/clr-angular-utils-loading.mjs +7 -7
- package/fesm2022/clr-angular-utils-loading.mjs.map +1 -1
- package/fesm2022/clr-angular-utils.mjs +144 -152
- package/fesm2022/clr-angular-utils.mjs.map +1 -1
- package/fesm2022/clr-angular-wizard.mjs +51 -51
- package/fesm2022/clr-angular-wizard.mjs.map +1 -1
- package/fesm2022/clr-angular.mjs +9 -4
- package/fesm2022/clr-angular.mjs.map +1 -1
- package/package.json +9 -5
- package/types/clr-angular-card.d.ts +110 -0
- package/types/clr-angular-data-datagrid.d.ts +293 -17
- package/types/clr-angular-data-tree-view.d.ts +126 -88
- package/types/clr-angular-forms-datepicker.d.ts +1 -1
- package/types/clr-angular-forms-file-input.d.ts +1 -1
- package/types/clr-angular-icon.d.ts +14 -2
- package/types/clr-angular-popover-common.d.ts +6 -0
- package/types/clr-angular-popover-dropdown.d.ts +33 -4
- package/types/clr-angular-utils.d.ts +61 -20
- package/types/clr-angular.d.ts +8 -6
- package/schematics/vitest.config.d.ts +0 -2
- package/schematics/vitest.config.js +0 -17
- package/schematics/vitest.config.js.map +0 -1
|
@@ -1,24 +1,24 @@
|
|
|
1
1
|
import * as i0 from '@angular/core';
|
|
2
|
-
import {
|
|
2
|
+
import { signal, Injectable, InjectionToken, Directive, ViewChild, Component, PLATFORM_ID, Inject, DOCUMENT, EventEmitter, ElementRef, booleanAttribute, Input, Output, Optional, inject, ContentChild, ChangeDetectionStrategy, ContentChildren, forwardRef, HostListener, ViewContainerRef, runInInjectionContext, createEnvironmentInjector, ChangeDetectorRef, NgZone, Renderer2, EnvironmentInjector, TemplateRef, IterableDiffers, afterNextRender, RendererStyleFlags2, ViewChildren, SkipSelf, NgModule } from '@angular/core';
|
|
3
3
|
import * as i2 from '@clr/angular/utils';
|
|
4
|
-
import { uniqueIdFactory, Keys, HostWrapper, IfExpandService, ClrLoadingState, ClrExpandableAnimationDirective, LoadingListener, WillyWonka, OompaLoompa, ClrKeyFocus, DomAdapter, ClrIfExpanded, CdkDragModule, CdkTrapFocusModule, ClrLoadingModule, ClrConditionalModule, ClrOutsideClickModule, ClrExpandableAnimationModule, ClrKeyFocusModule } from '@clr/angular/utils';
|
|
4
|
+
import { uniqueIdFactory, Keys, HostWrapper, IfExpandService, ClrLoadingState, ClrExpandableAnimationDirective, LoadingListener, WillyWonka, OompaLoompa, ClrKeyFocus, FocusableItem, FOCUS_SERVICE_PROVIDER, BASIC_FOCUSABLE_ITEM_PROVIDER, DomAdapter, ClrIfExpanded, CdkDragModule, CdkTrapFocusModule, ClrLoadingModule, ClrConditionalModule, ClrOutsideClickModule, ClrExpandableAnimationModule, ClrKeyFocusModule } from '@clr/angular/utils';
|
|
5
5
|
import * as i12 from 'rxjs';
|
|
6
6
|
import { Subject, BehaviorSubject, fromEvent, ReplaySubject, combineLatest, merge, of } from 'rxjs';
|
|
7
7
|
import { filter, takeUntil, delay, debounceTime, map, switchMap } from 'rxjs/operators';
|
|
8
8
|
import * as i3 from '@clr/angular/popover/common';
|
|
9
|
-
import { ClrPopoverPosition, ClrPopoverType, ClrPopoverHostDirective, mapPopoverKeyToPosition, ClrPopoverModuleNext } from '@clr/angular/popover/common';
|
|
9
|
+
import { ClrPopoverPosition, ClrPopoverType, ClrPopoverHostDirective, mapPopoverKeyToPosition, ClrPopoverContent, ClrPopoverModuleNext } from '@clr/angular/popover/common';
|
|
10
10
|
import * as i1 from '@clr/angular/modal';
|
|
11
11
|
import * as i10 from '@angular/common';
|
|
12
12
|
import { isPlatformBrowser, NgForOf, CommonModule } from '@angular/common';
|
|
13
|
-
import * as
|
|
14
|
-
import { ClarityIcons, ellipsisVerticalIcon, viewColumnsIcon, windowCloseIcon, arrowIcon, timesIcon, twoWayArrowsIcon, stepForward2Icon, angleDoubleIcon, filterGridCircleIcon, filterGridIcon, ClrIcon } from '@clr/angular/icon';
|
|
15
|
-
import * as i4 from '@clr/angular/forms/common';
|
|
13
|
+
import * as i4 from '@clr/angular/icon';
|
|
14
|
+
import { ClarityIcons, ellipsisVerticalIcon, ellipsisGridCircleIcon, viewColumnsIcon, windowCloseIcon, arrowIcon, timesIcon, twoWayArrowsIcon, stepForward2Icon, angleDoubleIcon, filterGridCircleIcon, filterGridIcon, pinIcon, unpinIcon, ClrIcon } from '@clr/angular/icon';
|
|
15
|
+
import * as i4$1 from '@clr/angular/forms/common';
|
|
16
16
|
import { ClrControlLabel } from '@clr/angular/forms/common';
|
|
17
|
-
import * as i5
|
|
17
|
+
import * as i5 from '@clr/angular/forms/number-input';
|
|
18
18
|
import { ClrNumberInputModule } from '@clr/angular/forms/number-input';
|
|
19
19
|
import * as i14 from '@angular/forms';
|
|
20
20
|
import { NG_VALUE_ACCESSOR, FormsModule } from '@angular/forms';
|
|
21
|
-
import * as i5$
|
|
21
|
+
import * as i5$1 from '@clr/angular/forms/input';
|
|
22
22
|
import { ClrInputModule } from '@clr/angular/forms/input';
|
|
23
23
|
import { ClrSignpost } from '@clr/angular/popover/signpost';
|
|
24
24
|
import * as i13 from '@clr/angular/forms/radio';
|
|
@@ -29,7 +29,9 @@ import * as i2$1 from '@angular/cdk/bidi';
|
|
|
29
29
|
import { Directionality } from '@angular/cdk/bidi';
|
|
30
30
|
import { coerceNumberProperty } from '@angular/cdk/coercion';
|
|
31
31
|
import * as i3$1 from '@angular/cdk/scrolling';
|
|
32
|
-
import { FixedSizeVirtualScrollStrategy, VIRTUAL_SCROLL_STRATEGY,
|
|
32
|
+
import { FixedSizeVirtualScrollStrategy, VIRTUAL_SCROLL_STRATEGY, CdkVirtualScrollable, CdkVirtualScrollViewport, ScrollDispatcher, ViewportRuler, CDK_VIRTUAL_SCROLL_VIEWPORT, CdkVirtualForOf } from '@angular/cdk/scrolling';
|
|
33
|
+
import * as i6 from '@clr/angular/popover/dropdown';
|
|
34
|
+
import { DropdownFocusHandler, ClrDropdown, ClrDropdownMenu, ROOT_DROPDOWN_PROVIDER, ClrDropdownItem, ClrDropdownModule } from '@clr/angular/popover/dropdown';
|
|
33
35
|
import * as i7 from '@clr/angular/forms/checkbox';
|
|
34
36
|
import { ClrCheckboxModule } from '@clr/angular/forms/checkbox';
|
|
35
37
|
import { ClrSelectModule } from '@clr/angular/forms/select';
|
|
@@ -384,6 +386,46 @@ var ClrDatagridAriaSortOrder;
|
|
|
384
386
|
ClrDatagridAriaSortOrder["DESC"] = "descending";
|
|
385
387
|
})(ClrDatagridAriaSortOrder || (ClrDatagridAriaSortOrder = {}));
|
|
386
388
|
|
|
389
|
+
/*
|
|
390
|
+
* Copyright (c) 2016-2026 Broadcom. All Rights Reserved.
|
|
391
|
+
* The term "Broadcom" refers to Broadcom Inc. and/or its subsidiaries.
|
|
392
|
+
* This software is released under MIT license.
|
|
393
|
+
* The full license information can be found in LICENSE in the root directory of this project.
|
|
394
|
+
*/
|
|
395
|
+
/**
|
|
396
|
+
* Lets `clr-dg-column-actions` and the filter of the same column find each other without either
|
|
397
|
+
* importing the other, and without depending on the order they are declared in.
|
|
398
|
+
*
|
|
399
|
+
* It is provided by `ClrDatagridColumn`, so every filter flavour resolves the same instance - a
|
|
400
|
+
* projected `clr-dg-filter` is a content child of the column, and the `clr-dg-string-filter` and
|
|
401
|
+
* `clr-dg-numeric-filter` the column creates for `clrDgField` live in its view.
|
|
402
|
+
*/
|
|
403
|
+
class ColumnActionsService {
|
|
404
|
+
constructor() {
|
|
405
|
+
/**
|
|
406
|
+
* Whether the filter keeps its own toggle in the column header. An actions menu turns this off and
|
|
407
|
+
* opens the filter itself, so the header keeps a single control per column - unless
|
|
408
|
+
* `clrDgKeepFilterInHeader` asks to keep the toggle.
|
|
409
|
+
*
|
|
410
|
+
* A signal rather than a plain flag because the menu and the filter are siblings: either can be
|
|
411
|
+
* created first, and the filter has to react whenever the answer changes.
|
|
412
|
+
*/
|
|
413
|
+
this.filterInHeader = signal(true, ...(ngDevMode ? [{ debugName: "filterInHeader" }] : /* istanbul ignore next */ []));
|
|
414
|
+
/**
|
|
415
|
+
* Whether the column has an actions menu at all, whatever it does with the filter. While it does,
|
|
416
|
+
* the column drops its own pin toggle, because the menu offers Pin Column instead.
|
|
417
|
+
*/
|
|
418
|
+
this.menuPresent = signal(false, ...(ngDevMode ? [{ debugName: "menuPresent" }] : /* istanbul ignore next */ []));
|
|
419
|
+
/** The filter rendered for this column, if it has one. */
|
|
420
|
+
this.filter = signal(null, ...(ngDevMode ? [{ debugName: "filter" }] : /* istanbul ignore next */ []));
|
|
421
|
+
}
|
|
422
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: ColumnActionsService, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
|
|
423
|
+
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: ColumnActionsService }); }
|
|
424
|
+
}
|
|
425
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: ColumnActionsService, decorators: [{
|
|
426
|
+
type: Injectable
|
|
427
|
+
}] });
|
|
428
|
+
|
|
387
429
|
/*
|
|
388
430
|
* Copyright (c) 2016-2026 Broadcom. All Rights Reserved.
|
|
389
431
|
* The term "Broadcom" refers to Broadcom Inc. and/or its subsidiaries.
|
|
@@ -453,10 +495,10 @@ class StateDebouncer {
|
|
|
453
495
|
this._change.next();
|
|
454
496
|
}
|
|
455
497
|
}
|
|
456
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.
|
|
457
|
-
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.
|
|
498
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: StateDebouncer, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
|
|
499
|
+
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: StateDebouncer }); }
|
|
458
500
|
}
|
|
459
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.
|
|
501
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: StateDebouncer, decorators: [{
|
|
460
502
|
type: Injectable
|
|
461
503
|
}] });
|
|
462
504
|
|
|
@@ -605,10 +647,10 @@ class Page {
|
|
|
605
647
|
this.preventEmit = preventEmit;
|
|
606
648
|
this.size = 0;
|
|
607
649
|
}
|
|
608
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.
|
|
609
|
-
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.
|
|
650
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: Page, deps: [{ token: StateDebouncer }], target: i0.ɵɵFactoryTarget.Injectable }); }
|
|
651
|
+
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: Page }); }
|
|
610
652
|
}
|
|
611
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.
|
|
653
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: Page, decorators: [{
|
|
612
654
|
type: Injectable
|
|
613
655
|
}], ctorParameters: () => [{ type: StateDebouncer }] });
|
|
614
656
|
|
|
@@ -706,10 +748,10 @@ class FiltersProvider {
|
|
|
706
748
|
this._change.next(filters);
|
|
707
749
|
this.stateDebouncer.changeDone();
|
|
708
750
|
}
|
|
709
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.
|
|
710
|
-
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.
|
|
751
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: FiltersProvider, deps: [{ token: Page }, { token: StateDebouncer }], target: i0.ɵɵFactoryTarget.Injectable }); }
|
|
752
|
+
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: FiltersProvider }); }
|
|
711
753
|
}
|
|
712
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.
|
|
754
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: FiltersProvider, decorators: [{
|
|
713
755
|
type: Injectable
|
|
714
756
|
}], ctorParameters: () => [{ type: Page }, { type: StateDebouncer }] });
|
|
715
757
|
class RegisteredFilter {
|
|
@@ -751,10 +793,10 @@ class DatagridFilterRegistrar {
|
|
|
751
793
|
delete this.registered;
|
|
752
794
|
}
|
|
753
795
|
}
|
|
754
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.
|
|
755
|
-
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "21.
|
|
796
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: DatagridFilterRegistrar, deps: [{ token: FiltersProvider }], target: i0.ɵɵFactoryTarget.Directive }); }
|
|
797
|
+
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "21.2.25", type: DatagridFilterRegistrar, isStandalone: true, ngImport: i0 }); }
|
|
756
798
|
}
|
|
757
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.
|
|
799
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: DatagridFilterRegistrar, decorators: [{
|
|
758
800
|
type: Directive
|
|
759
801
|
}], ctorParameters: () => [{ type: FiltersProvider }] });
|
|
760
802
|
|
|
@@ -772,14 +814,14 @@ class WrappedColumn {
|
|
|
772
814
|
ngOnDestroy() {
|
|
773
815
|
this.columnView.destroy();
|
|
774
816
|
}
|
|
775
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.
|
|
776
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "21.
|
|
817
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: WrappedColumn, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
818
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "21.2.25", type: WrappedColumn, isStandalone: false, selector: "dg-wrapped-column", viewQueries: [{ propertyName: "templateRef", first: true, predicate: ["columnPortal"], descendants: true }], ngImport: i0, template: `
|
|
777
819
|
<ng-template #columnPortal>
|
|
778
820
|
<ng-content></ng-content>
|
|
779
821
|
</ng-template>
|
|
780
822
|
`, isInline: true }); }
|
|
781
823
|
}
|
|
782
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.
|
|
824
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: WrappedColumn, decorators: [{
|
|
783
825
|
type: Component,
|
|
784
826
|
args: [{
|
|
785
827
|
selector: 'dg-wrapped-column',
|
|
@@ -870,10 +912,10 @@ class Sort {
|
|
|
870
912
|
emitChange() {
|
|
871
913
|
this._change.next(this);
|
|
872
914
|
}
|
|
873
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.
|
|
874
|
-
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.
|
|
915
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: Sort, deps: [{ token: StateDebouncer }], target: i0.ɵɵFactoryTarget.Injectable }); }
|
|
916
|
+
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: Sort }); }
|
|
875
917
|
}
|
|
876
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.
|
|
918
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: Sort, decorators: [{
|
|
877
919
|
type: Injectable
|
|
878
920
|
}], ctorParameters: () => [{ type: StateDebouncer }] });
|
|
879
921
|
|
|
@@ -946,10 +988,10 @@ class DetailService {
|
|
|
946
988
|
isRowOpen(item) {
|
|
947
989
|
return !!(this.toggleState && this.cache === item);
|
|
948
990
|
}
|
|
949
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.
|
|
950
|
-
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.
|
|
991
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: DetailService, deps: [{ token: i1.ModalStackService }], target: i0.ɵɵFactoryTarget.Injectable }); }
|
|
992
|
+
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: DetailService }); }
|
|
951
993
|
}
|
|
952
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.
|
|
994
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: DetailService, decorators: [{
|
|
953
995
|
type: Injectable
|
|
954
996
|
}], ctorParameters: () => [{ type: i1.ModalStackService }] });
|
|
955
997
|
|
|
@@ -1016,10 +1058,10 @@ class ColumnsService {
|
|
|
1016
1058
|
column.next(changedState);
|
|
1017
1059
|
this.columnsStateChange.next(changedState);
|
|
1018
1060
|
}
|
|
1019
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.
|
|
1020
|
-
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.
|
|
1061
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: ColumnsService, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
|
|
1062
|
+
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: ColumnsService }); }
|
|
1021
1063
|
}
|
|
1022
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.
|
|
1064
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: ColumnsService, decorators: [{
|
|
1023
1065
|
type: Injectable
|
|
1024
1066
|
}] });
|
|
1025
1067
|
|
|
@@ -1065,10 +1107,10 @@ class DatagridRenderOrganizer {
|
|
|
1065
1107
|
this.alreadySized = true;
|
|
1066
1108
|
this._renderStep.next(DatagridRenderStep.CALCULATE_MODE_OFF);
|
|
1067
1109
|
}
|
|
1068
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.
|
|
1069
|
-
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.
|
|
1110
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: DatagridRenderOrganizer, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
|
|
1111
|
+
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: DatagridRenderOrganizer }); }
|
|
1070
1112
|
}
|
|
1071
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.
|
|
1113
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: DatagridRenderOrganizer, decorators: [{
|
|
1072
1114
|
type: Injectable
|
|
1073
1115
|
}] });
|
|
1074
1116
|
|
|
@@ -1119,10 +1161,10 @@ class ColumnResizerService {
|
|
|
1119
1161
|
this.isWithinMaxResizeRange = true;
|
|
1120
1162
|
}
|
|
1121
1163
|
}
|
|
1122
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.
|
|
1123
|
-
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.
|
|
1164
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: ColumnResizerService, deps: [{ token: i0.ElementRef }, { token: i2.DomAdapter }, { token: DatagridRenderOrganizer }], target: i0.ɵɵFactoryTarget.Injectable }); }
|
|
1165
|
+
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: ColumnResizerService }); }
|
|
1124
1166
|
}
|
|
1125
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.
|
|
1167
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: ColumnResizerService, decorators: [{
|
|
1126
1168
|
type: Injectable
|
|
1127
1169
|
}], ctorParameters: () => [{ type: i0.ElementRef }, { type: i2.DomAdapter }, { type: DatagridRenderOrganizer }] });
|
|
1128
1170
|
|
|
@@ -1158,10 +1200,10 @@ class TableSizeService {
|
|
|
1158
1200
|
}
|
|
1159
1201
|
return `${this.tableRef.clientHeight}px`;
|
|
1160
1202
|
}
|
|
1161
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.
|
|
1162
|
-
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.
|
|
1203
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: TableSizeService, deps: [{ token: PLATFORM_ID }], target: i0.ɵɵFactoryTarget.Injectable }); }
|
|
1204
|
+
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: TableSizeService }); }
|
|
1163
1205
|
}
|
|
1164
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.
|
|
1206
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: TableSizeService, decorators: [{
|
|
1165
1207
|
type: Injectable
|
|
1166
1208
|
}], ctorParameters: () => [{ type: undefined, decorators: [{
|
|
1167
1209
|
type: Inject,
|
|
@@ -1272,8 +1314,8 @@ class ClrDatagridColumnSeparator {
|
|
|
1272
1314
|
isArrowRightKeyEvent(event) {
|
|
1273
1315
|
return event.key === Keys.ArrowRight;
|
|
1274
1316
|
}
|
|
1275
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.
|
|
1276
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "21.
|
|
1317
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: ClrDatagridColumnSeparator, deps: [{ token: ColumnResizerService }, { token: i0.Renderer2 }, { token: i0.NgZone }, { token: TableSizeService }, { token: i2.ClrCommonStringsService }, { token: DOCUMENT }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
1318
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "21.2.25", type: ClrDatagridColumnSeparator, isStandalone: false, selector: "clr-dg-column-separator", host: { properties: { "class.datagrid-column-separator": "true" } }, viewQueries: [{ propertyName: "resizeTrackerRef", first: true, predicate: ["resizeTracker"], descendants: true }, { propertyName: "columnHandleRef", first: true, predicate: ["columnHandle"], descendants: true }], ngImport: i0, template: `
|
|
1277
1319
|
<button
|
|
1278
1320
|
type="button"
|
|
1279
1321
|
class="datagrid-column-handle"
|
|
@@ -1292,7 +1334,7 @@ class ClrDatagridColumnSeparator {
|
|
|
1292
1334
|
<div class="datagrid-column-resize-tracker" #resizeTracker></div>
|
|
1293
1335
|
`, isInline: true, dependencies: [{ kind: "directive", type: i2.CdkDragModule_CdkDrag, selector: "[cdkDrag]" }] }); }
|
|
1294
1336
|
}
|
|
1295
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.
|
|
1337
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: ClrDatagridColumnSeparator, decorators: [{
|
|
1296
1338
|
type: Component,
|
|
1297
1339
|
args: [{
|
|
1298
1340
|
selector: 'clr-dg-column-separator',
|
|
@@ -2013,10 +2055,10 @@ class KeyNavigationGridController {
|
|
|
2013
2055
|
}
|
|
2014
2056
|
elementToFocus.focus(options);
|
|
2015
2057
|
}
|
|
2016
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.
|
|
2017
|
-
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.
|
|
2058
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: KeyNavigationGridController, deps: [{ token: i0.NgZone }], target: i0.ɵɵFactoryTarget.Injectable }); }
|
|
2059
|
+
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: KeyNavigationGridController }); }
|
|
2018
2060
|
}
|
|
2019
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.
|
|
2061
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: KeyNavigationGridController, decorators: [{
|
|
2020
2062
|
type: Injectable
|
|
2021
2063
|
}], ctorParameters: () => [{ type: i0.NgZone }] });
|
|
2022
2064
|
|
|
@@ -2032,11 +2074,12 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.1.3", ngImpor
|
|
|
2032
2074
|
* since it can be anything (not just a text input).
|
|
2033
2075
|
*/
|
|
2034
2076
|
class ClrDatagridFilter extends DatagridFilterRegistrar {
|
|
2035
|
-
constructor(_filters, commonStrings, popoverService, keyNavigation) {
|
|
2077
|
+
constructor(_filters, commonStrings, popoverService, keyNavigation, columnActions) {
|
|
2036
2078
|
super(_filters);
|
|
2037
2079
|
this.commonStrings = commonStrings;
|
|
2038
2080
|
this.popoverService = popoverService;
|
|
2039
2081
|
this.keyNavigation = keyNavigation;
|
|
2082
|
+
this.columnActions = columnActions;
|
|
2040
2083
|
this.openChange = new EventEmitter(false);
|
|
2041
2084
|
this.ariaExpanded = false;
|
|
2042
2085
|
this.popoverId = uniqueIdFactory();
|
|
@@ -2047,7 +2090,14 @@ class ClrDatagridFilter extends DatagridFilterRegistrar {
|
|
|
2047
2090
|
this.subs.push(popoverService.openChange.subscribe(change => {
|
|
2048
2091
|
this.ariaExpanded = change;
|
|
2049
2092
|
this.openChange.emit(change);
|
|
2093
|
+
// Set here rather than in the open setter, so it applies however the filter is opened - its
|
|
2094
|
+
// own toggle, clrDgFilterOpen, or the column actions menu.
|
|
2095
|
+
if (keyNavigation) {
|
|
2096
|
+
keyNavigation.skipItemFocus = change;
|
|
2097
|
+
}
|
|
2050
2098
|
}));
|
|
2099
|
+
// Optional so the filter keeps working outside a column, e.g. in isolated tests.
|
|
2100
|
+
columnActions?.filter.set(this);
|
|
2051
2101
|
}
|
|
2052
2102
|
get open() {
|
|
2053
2103
|
return this.popoverService.open;
|
|
@@ -2056,9 +2106,6 @@ class ClrDatagridFilter extends DatagridFilterRegistrar {
|
|
|
2056
2106
|
if (this.popoverService.open !== open) {
|
|
2057
2107
|
this.popoverService.open = open;
|
|
2058
2108
|
this.openChange.emit(open);
|
|
2059
|
-
if (this.keyNavigation) {
|
|
2060
|
-
this.keyNavigation.skipItemFocus = open;
|
|
2061
|
-
}
|
|
2062
2109
|
}
|
|
2063
2110
|
}
|
|
2064
2111
|
set customFilter(filter) {
|
|
@@ -2073,26 +2120,36 @@ class ClrDatagridFilter extends DatagridFilterRegistrar {
|
|
|
2073
2120
|
ngOnDestroy() {
|
|
2074
2121
|
super.ngOnDestroy();
|
|
2075
2122
|
this.subs.forEach(sub => sub.unsubscribe());
|
|
2123
|
+
if (this.columnActions?.filter() === this) {
|
|
2124
|
+
this.columnActions.filter.set(null);
|
|
2125
|
+
}
|
|
2126
|
+
}
|
|
2127
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: ClrDatagridFilter, deps: [{ token: FiltersProvider }, { token: i2.ClrCommonStringsService }, { token: i3.ClrPopoverService }, { token: KeyNavigationGridController, optional: true }, { token: ColumnActionsService, optional: true }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
2128
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.25", type: ClrDatagridFilter, isStandalone: false, selector: "clr-dg-filter", inputs: { open: ["clrDgFilterOpen", "open", booleanAttribute], customFilter: ["clrDgFilter", "customFilter"] }, outputs: { openChange: "clrDgFilterOpenChange" }, providers: [{ provide: CustomFilter, useExisting: ClrDatagridFilter }], viewQueries: [{ propertyName: "anchor", first: true, predicate: ["anchor"], descendants: true, read: ElementRef }], usesInheritance: true, ngImport: i0, template: `
|
|
2129
|
+
<!--
|
|
2130
|
+
The toggle stands down when the column has a clr-dg-column-actions menu, which then owns
|
|
2131
|
+
opening this filter. Nothing else here changes: the popover is still driven through the
|
|
2132
|
+
column's ClrPopoverService, the menu just points its origin at its own trigger instead.
|
|
2133
|
+
-->
|
|
2134
|
+
@if (columnActions?.filterInHeader() ?? true) {
|
|
2135
|
+
<button
|
|
2136
|
+
class="datagrid-filter-toggle"
|
|
2137
|
+
type="button"
|
|
2138
|
+
#anchor
|
|
2139
|
+
[attr.aria-expanded]="ariaExpanded"
|
|
2140
|
+
[attr.aria-controls]="popoverId"
|
|
2141
|
+
clrPopoverOrigin
|
|
2142
|
+
clrPopoverOpenCloseButton
|
|
2143
|
+
[class.datagrid-filter-open]="open"
|
|
2144
|
+
[class.datagrid-filtered]="active"
|
|
2145
|
+
>
|
|
2146
|
+
<cds-icon
|
|
2147
|
+
[status]="active ? 'info' : null"
|
|
2148
|
+
[shape]="active ? 'filter-grid-circle' : 'filter-grid'"
|
|
2149
|
+
solid
|
|
2150
|
+
></cds-icon>
|
|
2151
|
+
</button>
|
|
2076
2152
|
}
|
|
2077
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.1.3", ngImport: i0, type: ClrDatagridFilter, deps: [{ token: FiltersProvider }, { token: i2.ClrCommonStringsService }, { token: i3.ClrPopoverService }, { token: KeyNavigationGridController, optional: true }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
2078
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "16.1.0", version: "21.1.3", type: ClrDatagridFilter, isStandalone: false, selector: "clr-dg-filter", inputs: { open: ["clrDgFilterOpen", "open", booleanAttribute], customFilter: ["clrDgFilter", "customFilter"] }, outputs: { openChange: "clrDgFilterOpenChange" }, providers: [{ provide: CustomFilter, useExisting: ClrDatagridFilter }], viewQueries: [{ propertyName: "anchor", first: true, predicate: ["anchor"], descendants: true, read: ElementRef }], usesInheritance: true, ngImport: i0, template: `
|
|
2079
|
-
<button
|
|
2080
|
-
class="datagrid-filter-toggle"
|
|
2081
|
-
type="button"
|
|
2082
|
-
#anchor
|
|
2083
|
-
[attr.aria-expanded]="ariaExpanded"
|
|
2084
|
-
[attr.aria-controls]="popoverId"
|
|
2085
|
-
clrPopoverOrigin
|
|
2086
|
-
clrPopoverOpenCloseButton
|
|
2087
|
-
[class.datagrid-filter-open]="open"
|
|
2088
|
-
[class.datagrid-filtered]="active"
|
|
2089
|
-
>
|
|
2090
|
-
<cds-icon
|
|
2091
|
-
[status]="active ? 'info' : null"
|
|
2092
|
-
[shape]="active ? 'filter-grid-circle' : 'filter-grid'"
|
|
2093
|
-
solid
|
|
2094
|
-
></cds-icon>
|
|
2095
|
-
</button>
|
|
2096
2153
|
|
|
2097
2154
|
<div
|
|
2098
2155
|
class="datagrid-filter"
|
|
@@ -2110,32 +2167,39 @@ class ClrDatagridFilter extends DatagridFilterRegistrar {
|
|
|
2110
2167
|
|
|
2111
2168
|
<ng-content></ng-content>
|
|
2112
2169
|
</div>
|
|
2113
|
-
`, isInline: true, dependencies: [{ kind: "directive", type: i2.CdkTrapFocusModule_CdkTrapFocus, selector: "[cdkTrapFocus]" }, { kind: "component", type:
|
|
2170
|
+
`, isInline: true, dependencies: [{ kind: "directive", type: i2.CdkTrapFocusModule_CdkTrapFocus, selector: "[cdkTrapFocus]" }, { kind: "component", type: i4.ClrIcon, selector: "clr-icon, cds-icon", inputs: ["shape", "size", "direction", "flip", "solid", "status", "inverse", "badge", "innerOffset"] }, { kind: "directive", type: i3.ClrPopoverOrigin, selector: "[clrPopoverOrigin]" }, { kind: "directive", type: i3.ClrPopoverCloseButton, selector: "[clrPopoverCloseButton]", outputs: ["clrPopoverOnCloseChange"] }, { kind: "directive", type: i3.ClrPopoverOpenCloseButton, selector: "[clrPopoverOpenCloseButton]", outputs: ["clrPopoverOpenCloseChange"] }, { kind: "directive", type: i3.ClrPopoverContent, selector: "[clrPopoverContent]", inputs: ["clrPopoverContent", "clrPopoverContentAt", "clrPopoverContentAvailablePositions", "clrPopoverContentType", "clrPopoverContentOutsideClickToClose", "clrPopoverContentScrollToClose", "clrPopoverContentOrigin"] }] }); }
|
|
2114
2171
|
}
|
|
2115
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.
|
|
2172
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: ClrDatagridFilter, decorators: [{
|
|
2116
2173
|
type: Component,
|
|
2117
2174
|
args: [{
|
|
2118
2175
|
selector: 'clr-dg-filter',
|
|
2119
2176
|
// We register this component as a CustomFilter, for the parent column to detect it.
|
|
2120
2177
|
providers: [{ provide: CustomFilter, useExisting: ClrDatagridFilter }],
|
|
2121
2178
|
template: `
|
|
2122
|
-
|
|
2123
|
-
|
|
2124
|
-
|
|
2125
|
-
|
|
2126
|
-
|
|
2127
|
-
|
|
2128
|
-
|
|
2129
|
-
|
|
2130
|
-
|
|
2131
|
-
|
|
2132
|
-
|
|
2133
|
-
|
|
2134
|
-
|
|
2135
|
-
|
|
2136
|
-
|
|
2137
|
-
|
|
2138
|
-
|
|
2179
|
+
<!--
|
|
2180
|
+
The toggle stands down when the column has a clr-dg-column-actions menu, which then owns
|
|
2181
|
+
opening this filter. Nothing else here changes: the popover is still driven through the
|
|
2182
|
+
column's ClrPopoverService, the menu just points its origin at its own trigger instead.
|
|
2183
|
+
-->
|
|
2184
|
+
@if (columnActions?.filterInHeader() ?? true) {
|
|
2185
|
+
<button
|
|
2186
|
+
class="datagrid-filter-toggle"
|
|
2187
|
+
type="button"
|
|
2188
|
+
#anchor
|
|
2189
|
+
[attr.aria-expanded]="ariaExpanded"
|
|
2190
|
+
[attr.aria-controls]="popoverId"
|
|
2191
|
+
clrPopoverOrigin
|
|
2192
|
+
clrPopoverOpenCloseButton
|
|
2193
|
+
[class.datagrid-filter-open]="open"
|
|
2194
|
+
[class.datagrid-filtered]="active"
|
|
2195
|
+
>
|
|
2196
|
+
<cds-icon
|
|
2197
|
+
[status]="active ? 'info' : null"
|
|
2198
|
+
[shape]="active ? 'filter-grid-circle' : 'filter-grid'"
|
|
2199
|
+
solid
|
|
2200
|
+
></cds-icon>
|
|
2201
|
+
</button>
|
|
2202
|
+
}
|
|
2139
2203
|
|
|
2140
2204
|
<div
|
|
2141
2205
|
class="datagrid-filter"
|
|
@@ -2158,6 +2222,8 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.1.3", ngImpor
|
|
|
2158
2222
|
}]
|
|
2159
2223
|
}], ctorParameters: () => [{ type: FiltersProvider }, { type: i2.ClrCommonStringsService }, { type: i3.ClrPopoverService }, { type: KeyNavigationGridController, decorators: [{
|
|
2160
2224
|
type: Optional
|
|
2225
|
+
}] }, { type: ColumnActionsService, decorators: [{
|
|
2226
|
+
type: Optional
|
|
2161
2227
|
}] }], propDecorators: { openChange: [{
|
|
2162
2228
|
type: Output,
|
|
2163
2229
|
args: ['clrDgFilterOpenChange']
|
|
@@ -2310,8 +2376,8 @@ class DatagridNumericFilter extends DatagridFilterRegistrar {
|
|
|
2310
2376
|
sub.unsubscribe();
|
|
2311
2377
|
});
|
|
2312
2378
|
}
|
|
2313
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.
|
|
2314
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "21.
|
|
2379
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: DatagridNumericFilter, deps: [{ token: FiltersProvider }, { token: i2.DomAdapter }, { token: i2.ClrCommonStringsService }, { token: i3.ClrPopoverService }, { token: i0.NgZone }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
2380
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "21.2.25", type: DatagridNumericFilter, isStandalone: false, selector: "clr-dg-numeric-filter", inputs: { minPlaceholder: ["clrFilterMinPlaceholder", "minPlaceholder"], maxPlaceholder: ["clrFilterMaxPlaceholder", "maxPlaceholder"], fromLabel: ["clrFilterFromLabel", "fromLabel"], toLabel: ["clrFilterToLabel", "toLabel"], value: ["clrFilterValue", "value"], customNumericFilter: ["clrDgNumericFilter", "customNumericFilter"] }, outputs: { filterValueChange: "clrFilterValueChange" }, providers: [{ provide: CustomFilter, useExisting: DatagridNumericFilter }], viewQueries: [{ propertyName: "input", first: true, predicate: ["input_low"], descendants: true }, { propertyName: "filterContainer", first: true, predicate: ClrDatagridFilter, descendants: true }], usesInheritance: true, ngImport: i0, template: `
|
|
2315
2381
|
<clr-dg-filter [clrDgFilter]="registered" [(clrDgFilterOpen)]="open">
|
|
2316
2382
|
<div class="datagrid-numeric-filter-form">
|
|
2317
2383
|
<clr-number-input-container>
|
|
@@ -2344,9 +2410,9 @@ class DatagridNumericFilter extends DatagridFilterRegistrar {
|
|
|
2344
2410
|
</clr-number-input-container>
|
|
2345
2411
|
</div>
|
|
2346
2412
|
</clr-dg-filter>
|
|
2347
|
-
`, isInline: true, dependencies: [{ kind: "directive", type: i4.ClrControlLabel, selector: "label", inputs: ["id", "for"] }, { kind: "directive", type: i5
|
|
2413
|
+
`, isInline: true, dependencies: [{ kind: "directive", type: i4$1.ClrControlLabel, selector: "label", inputs: ["id", "for"] }, { kind: "directive", type: i5.ClrNumberInput, selector: "input[type=\"number\"][clrNumberInput]" }, { kind: "component", type: i5.ClrNumberInputContainer, selector: "clr-number-input-container" }, { kind: "directive", type: i14.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: i14.NumberValueAccessor, selector: "input[type=number][formControlName],input[type=number][formControl],input[type=number][ngModel]" }, { kind: "directive", type: i14.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i14.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "component", type: ClrDatagridFilter, selector: "clr-dg-filter", inputs: ["clrDgFilterOpen", "clrDgFilter"], outputs: ["clrDgFilterOpenChange"] }] }); }
|
|
2348
2414
|
}
|
|
2349
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.
|
|
2415
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: DatagridNumericFilter, decorators: [{
|
|
2350
2416
|
type: Component,
|
|
2351
2417
|
args: [{
|
|
2352
2418
|
selector: 'clr-dg-numeric-filter',
|
|
@@ -2520,8 +2586,8 @@ class DatagridStringFilter extends DatagridFilterRegistrar {
|
|
|
2520
2586
|
COLUMN: columnTitleElement?.textContent.trim() || '',
|
|
2521
2587
|
});
|
|
2522
2588
|
}
|
|
2523
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.
|
|
2524
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "21.
|
|
2589
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: DatagridStringFilter, deps: [{ token: FiltersProvider }, { token: i2.DomAdapter }, { token: i2.ClrCommonStringsService }, { token: i3.ClrPopoverService }, { token: i0.ElementRef }, { token: i0.ChangeDetectorRef }, { token: i0.NgZone }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
2590
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "21.2.25", type: DatagridStringFilter, isStandalone: false, selector: "clr-dg-string-filter", inputs: { placeholder: ["clrFilterPlaceholder", "placeholder"], label: ["clrFilterLabel", "label"], customStringFilter: ["clrDgStringFilter", "customStringFilter"], value: ["clrFilterValue", "value"] }, outputs: { filterValueChange: "clrFilterValueChange" }, providers: [{ provide: CustomFilter, useExisting: DatagridStringFilter }], viewQueries: [{ propertyName: "input", first: true, predicate: ["input"], descendants: true }, { propertyName: "filterContainer", first: true, predicate: ClrDatagridFilter, descendants: true }], usesInheritance: true, usesOnChanges: true, ngImport: i0, template: `
|
|
2525
2591
|
<clr-dg-filter [clrDgFilter]="registered" [(clrDgFilterOpen)]="open">
|
|
2526
2592
|
<clr-input-container>
|
|
2527
2593
|
<label>{{ labelValue }}</label>
|
|
@@ -2537,9 +2603,9 @@ class DatagridStringFilter extends DatagridFilterRegistrar {
|
|
|
2537
2603
|
/>
|
|
2538
2604
|
</clr-input-container>
|
|
2539
2605
|
</clr-dg-filter>
|
|
2540
|
-
`, isInline: true, dependencies: [{ kind: "directive", type: i4.ClrControlLabel, selector: "label", inputs: ["id", "for"] }, { kind: "directive", type: i5$
|
|
2606
|
+
`, isInline: true, dependencies: [{ kind: "directive", type: i4$1.ClrControlLabel, selector: "label", inputs: ["id", "for"] }, { kind: "directive", type: i5$1.ClrInput, selector: "[clrInput]" }, { kind: "component", type: i5$1.ClrInputContainer, selector: "clr-input-container" }, { kind: "directive", type: i14.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: i14.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i14.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "component", type: ClrDatagridFilter, selector: "clr-dg-filter", inputs: ["clrDgFilterOpen", "clrDgFilter"], outputs: ["clrDgFilterOpenChange"] }] }); }
|
|
2541
2607
|
}
|
|
2542
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.
|
|
2608
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: DatagridStringFilter, decorators: [{
|
|
2543
2609
|
type: Component,
|
|
2544
2610
|
args: [{
|
|
2545
2611
|
selector: 'clr-dg-string-filter',
|
|
@@ -2604,23 +2670,22 @@ class ClrDatagridColumn extends DatagridFilterRegistrar {
|
|
|
2604
2670
|
this.columnsService = columnsService;
|
|
2605
2671
|
this.columnState = columnState;
|
|
2606
2672
|
this.disableUnsort = false;
|
|
2607
|
-
|
|
2608
|
-
|
|
2609
|
-
|
|
2610
|
-
|
|
2611
|
-
|
|
2612
|
-
|
|
2613
|
-
|
|
2614
|
-
// */
|
|
2615
|
-
// @Input({ alias: 'clrDgPinnable', transform: booleanAttribute }) pinnable = false;
|
|
2673
|
+
/**
|
|
2674
|
+
* Lets the user pin and unpin the column from within the datagrid. It only offers the control - the
|
|
2675
|
+
* pinned state itself stays on `clrDgPinned`.
|
|
2676
|
+
* The control is a pin toggle in the column header, or Pin Column in the column's
|
|
2677
|
+
* `clr-dg-column-actions` when it has one - never both, so the header keeps one control per action.
|
|
2678
|
+
*/
|
|
2679
|
+
this.pinnable = false;
|
|
2616
2680
|
this.sortOrderChange = new EventEmitter();
|
|
2617
|
-
|
|
2618
|
-
// @Output('clrDgPinnedChange') pinnedChange = new EventEmitter<boolean>();
|
|
2681
|
+
this.pinnedChange = new EventEmitter();
|
|
2619
2682
|
this.filterValueChange = new EventEmitter();
|
|
2620
2683
|
/**
|
|
2621
2684
|
* A custom filter for this column that can be provided in the projected content
|
|
2622
2685
|
*/
|
|
2623
2686
|
this.customFilter = false;
|
|
2687
|
+
// Provided by this column itself, and shared with its actions menu and filter.
|
|
2688
|
+
this.columnActions = inject(ColumnActionsService);
|
|
2624
2689
|
/*
|
|
2625
2690
|
* What type is this column? This defaults to STRING, but can also be
|
|
2626
2691
|
* set to NUMBER. Unsupported types default to STRING. Users can set it
|
|
@@ -2846,10 +2911,7 @@ class ClrDatagridColumn extends DatagridFilterRegistrar {
|
|
|
2846
2911
|
return;
|
|
2847
2912
|
}
|
|
2848
2913
|
if (!this.disableUnsort && reverse === undefined && this.sortOrder === ClrDatagridSortOrder.DESC) {
|
|
2849
|
-
this.
|
|
2850
|
-
this._sort.clear();
|
|
2851
|
-
this._sortDirection = null;
|
|
2852
|
-
this.sortOrderChange.emit(this._sortOrder);
|
|
2914
|
+
this.clearSort();
|
|
2853
2915
|
return;
|
|
2854
2916
|
}
|
|
2855
2917
|
this._sort.toggle(this._sortBy, reverse);
|
|
@@ -2859,21 +2921,34 @@ class ClrDatagridColumn extends DatagridFilterRegistrar {
|
|
|
2859
2921
|
this._sortDirection = this._sortOrder === ClrDatagridSortOrder.DESC ? 'down' : 'up';
|
|
2860
2922
|
this.sortOrderChange.emit(this._sortOrder);
|
|
2861
2923
|
}
|
|
2862
|
-
|
|
2863
|
-
|
|
2864
|
-
|
|
2865
|
-
|
|
2866
|
-
|
|
2867
|
-
|
|
2868
|
-
|
|
2869
|
-
|
|
2870
|
-
|
|
2871
|
-
|
|
2872
|
-
|
|
2873
|
-
|
|
2874
|
-
|
|
2875
|
-
|
|
2876
|
-
|
|
2924
|
+
/**
|
|
2925
|
+
* Returns the datagrid to its unsorted state. Both the tri-state title button and the sort actions
|
|
2926
|
+
* in `clr-dg-column-actions` go through here, so the two cannot drift apart.
|
|
2927
|
+
*/
|
|
2928
|
+
clearSort() {
|
|
2929
|
+
if (!this.sortable || this._sortOrder === ClrDatagridSortOrder.UNSORTED) {
|
|
2930
|
+
return;
|
|
2931
|
+
}
|
|
2932
|
+
this._sortOrder = ClrDatagridSortOrder.UNSORTED;
|
|
2933
|
+
this._sort.clear();
|
|
2934
|
+
this._sortDirection = null;
|
|
2935
|
+
this.sortOrderChange.emit(this._sortOrder);
|
|
2936
|
+
}
|
|
2937
|
+
/**
|
|
2938
|
+
* Pins or unpins the column. Going through the `pinned` setter keeps the rendering in sync, and the
|
|
2939
|
+
* output lets the application follow a change it did not initiate - without it a one-way
|
|
2940
|
+
* [clrDgPinned] binding would write the old value straight back.
|
|
2941
|
+
*/
|
|
2942
|
+
togglePinned() {
|
|
2943
|
+
this.pinned = !this.pinned;
|
|
2944
|
+
this.pinnedChange.emit(this.pinned);
|
|
2945
|
+
}
|
|
2946
|
+
onPinToggleClick(event) {
|
|
2947
|
+
// The header is a drop target for the column ordering addon and a click target for the sort
|
|
2948
|
+
// button next to the toggle, so the toggle keeps its click to itself.
|
|
2949
|
+
event.stopPropagation();
|
|
2950
|
+
this.togglePinned();
|
|
2951
|
+
}
|
|
2877
2952
|
listenForDetailPaneChanges() {
|
|
2878
2953
|
return this.detailService.stateChange.subscribe(state => {
|
|
2879
2954
|
if (this.showSeparator !== !state) {
|
|
@@ -2917,26 +2992,9 @@ class ClrDatagridColumn extends DatagridFilterRegistrar {
|
|
|
2917
2992
|
delete this.initFilterValue;
|
|
2918
2993
|
}
|
|
2919
2994
|
}
|
|
2920
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.
|
|
2921
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.
|
|
2995
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: ClrDatagridColumn, deps: [{ token: i0.ElementRef }, { token: Sort }, { token: FiltersProvider }, { token: i0.ViewContainerRef }, { token: DetailService }, { token: i0.ChangeDetectorRef }, { token: i2.ClrCommonStringsService }, { token: ColumnsService }, { token: COLUMN_STATE, optional: true }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
2996
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.25", type: ClrDatagridColumn, isStandalone: false, selector: "clr-dg-column", inputs: { filterStringPlaceholder: ["clrFilterStringPlaceholder", "filterStringPlaceholder"], filterNumberMaxPlaceholder: ["clrFilterNumberMaxPlaceholder", "filterNumberMaxPlaceholder"], filterNumberMinPlaceholder: ["clrFilterNumberMinPlaceholder", "filterNumberMinPlaceholder"], disableUnsort: ["clrDgDisableUnsort", "disableUnsort"], pinnable: ["clrDgPinnable", "pinnable", booleanAttribute], pinned: ["clrDgPinned", "pinned", booleanAttribute], colType: ["clrDgColType", "colType"], field: ["clrDgField", "field"], sortBy: ["clrDgSortBy", "sortBy"], sortOrder: ["clrDgSortOrder", "sortOrder"], updateFilterValue: ["clrFilterValue", "updateFilterValue"] }, outputs: { sortOrderChange: "clrDgSortOrderChange", pinnedChange: "clrDgPinnedChange", filterValueChange: "clrFilterValueChange" }, host: { attributes: { "role": "columnheader" }, properties: { "class.datagrid-column": "true", "attr.aria-sort": "ariaSort" } }, providers: [ColumnActionsService], queries: [{ propertyName: "projectedFilter", first: true, predicate: CustomFilter, descendants: true }], viewQueries: [{ propertyName: "titleContainer", first: true, predicate: ["titleContainer"], descendants: true, read: ElementRef }], usesInheritance: true, usesOnChanges: true, hostDirectives: [{ directive: i3.ClrPopoverHostDirective }], ngImport: i0, template: `
|
|
2922
2997
|
<div class="datagrid-column-flex">
|
|
2923
|
-
<!--
|
|
2924
|
-
clrDgPinnable is disabled for now. Restoring it means uncommenting this block together with
|
|
2925
|
-
the pinnable input, the clrDgPinnedChange output and togglePinned() below, the
|
|
2926
|
-
.datagrid-column-pin styles, the pin/unpin icons in ClrDatagridModule and the
|
|
2927
|
-
pinColumn/unpinColumn common strings.
|
|
2928
|
-
|
|
2929
|
-
@if (pinnable) {
|
|
2930
|
-
<button
|
|
2931
|
-
class="datagrid-column-pin"
|
|
2932
|
-
type="button"
|
|
2933
|
-
[attr.aria-label]="pinned ? commonStrings.keys.unpinColumn : commonStrings.keys.pinColumn"
|
|
2934
|
-
(click)="togglePinned($event)"
|
|
2935
|
-
>
|
|
2936
|
-
<cds-icon [size]="'12'" [shape]="pinned ? 'unpin' : 'pin'" solid aria-hidden="true"></cds-icon>
|
|
2937
|
-
</button>
|
|
2938
|
-
}
|
|
2939
|
-
-->
|
|
2940
2998
|
@if (sortable) {
|
|
2941
2999
|
<button class="datagrid-column-title" (click)="sort()" type="button" #titleContainer>
|
|
2942
3000
|
<ng-container *ngTemplateOutlet="columnTitle"></ng-container>
|
|
@@ -2976,35 +3034,37 @@ class ClrDatagridColumn extends DatagridFilterRegistrar {
|
|
|
2976
3034
|
<ng-container *ngTemplateOutlet="columnTitle"></ng-container>
|
|
2977
3035
|
</span>
|
|
2978
3036
|
}
|
|
3037
|
+
|
|
3038
|
+
<!--
|
|
3039
|
+
The actions menu needs its own slot: the default ng-content lives inside the #columnTitle
|
|
3040
|
+
template, which is rendered inside the sort button, so an unselected clr-dg-column-actions
|
|
3041
|
+
would end up as a button within a button.
|
|
3042
|
+
-->
|
|
3043
|
+
<ng-content select="clr-dg-column-actions"></ng-content>
|
|
3044
|
+
|
|
3045
|
+
@if (pinnable && !columnActions.menuPresent()) {
|
|
3046
|
+
<button
|
|
3047
|
+
class="datagrid-column-pin"
|
|
3048
|
+
type="button"
|
|
3049
|
+
[attr.aria-label]="pinned ? commonStrings.keys.unpinColumn : commonStrings.keys.pinColumn"
|
|
3050
|
+
(click)="onPinToggleClick($event)"
|
|
3051
|
+
>
|
|
3052
|
+
<cds-icon [size]="'12'" [shape]="pinned ? 'unpin' : 'pin'" solid aria-hidden="true"></cds-icon>
|
|
3053
|
+
</button>
|
|
3054
|
+
}
|
|
3055
|
+
|
|
2979
3056
|
@if (showSeparator) {
|
|
2980
3057
|
<clr-dg-column-separator></clr-dg-column-separator>
|
|
2981
3058
|
}
|
|
2982
3059
|
</div>
|
|
2983
|
-
`, isInline: true, dependencies: [{ kind: "directive", type: i10.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "component", type:
|
|
3060
|
+
`, isInline: true, dependencies: [{ kind: "directive", type: i10.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "component", type: i4.ClrIcon, selector: "clr-icon, cds-icon", inputs: ["shape", "size", "direction", "flip", "solid", "status", "inverse", "badge", "innerOffset"] }, { kind: "component", type: ClrDatagridColumnSeparator, selector: "clr-dg-column-separator" }, { kind: "component", type: DatagridNumericFilter, selector: "clr-dg-numeric-filter", inputs: ["clrFilterMinPlaceholder", "clrFilterMaxPlaceholder", "clrFilterFromLabel", "clrFilterToLabel", "clrFilterValue", "clrDgNumericFilter"], outputs: ["clrFilterValueChange"] }, { kind: "component", type: DatagridStringFilter, selector: "clr-dg-string-filter", inputs: ["clrFilterPlaceholder", "clrFilterLabel", "clrDgStringFilter", "clrFilterValue"], outputs: ["clrFilterValueChange"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
2984
3061
|
}
|
|
2985
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.
|
|
3062
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: ClrDatagridColumn, decorators: [{
|
|
2986
3063
|
type: Component,
|
|
2987
3064
|
args: [{
|
|
2988
3065
|
selector: 'clr-dg-column',
|
|
2989
3066
|
template: `
|
|
2990
3067
|
<div class="datagrid-column-flex">
|
|
2991
|
-
<!--
|
|
2992
|
-
clrDgPinnable is disabled for now. Restoring it means uncommenting this block together with
|
|
2993
|
-
the pinnable input, the clrDgPinnedChange output and togglePinned() below, the
|
|
2994
|
-
.datagrid-column-pin styles, the pin/unpin icons in ClrDatagridModule and the
|
|
2995
|
-
pinColumn/unpinColumn common strings.
|
|
2996
|
-
|
|
2997
|
-
@if (pinnable) {
|
|
2998
|
-
<button
|
|
2999
|
-
class="datagrid-column-pin"
|
|
3000
|
-
type="button"
|
|
3001
|
-
[attr.aria-label]="pinned ? commonStrings.keys.unpinColumn : commonStrings.keys.pinColumn"
|
|
3002
|
-
(click)="togglePinned($event)"
|
|
3003
|
-
>
|
|
3004
|
-
<cds-icon [size]="'12'" [shape]="pinned ? 'unpin' : 'pin'" solid aria-hidden="true"></cds-icon>
|
|
3005
|
-
</button>
|
|
3006
|
-
}
|
|
3007
|
-
-->
|
|
3008
3068
|
@if (sortable) {
|
|
3009
3069
|
<button class="datagrid-column-title" (click)="sort()" type="button" #titleContainer>
|
|
3010
3070
|
<ng-container *ngTemplateOutlet="columnTitle"></ng-container>
|
|
@@ -3044,12 +3104,33 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.1.3", ngImpor
|
|
|
3044
3104
|
<ng-container *ngTemplateOutlet="columnTitle"></ng-container>
|
|
3045
3105
|
</span>
|
|
3046
3106
|
}
|
|
3107
|
+
|
|
3108
|
+
<!--
|
|
3109
|
+
The actions menu needs its own slot: the default ng-content lives inside the #columnTitle
|
|
3110
|
+
template, which is rendered inside the sort button, so an unselected clr-dg-column-actions
|
|
3111
|
+
would end up as a button within a button.
|
|
3112
|
+
-->
|
|
3113
|
+
<ng-content select="clr-dg-column-actions"></ng-content>
|
|
3114
|
+
|
|
3115
|
+
@if (pinnable && !columnActions.menuPresent()) {
|
|
3116
|
+
<button
|
|
3117
|
+
class="datagrid-column-pin"
|
|
3118
|
+
type="button"
|
|
3119
|
+
[attr.aria-label]="pinned ? commonStrings.keys.unpinColumn : commonStrings.keys.pinColumn"
|
|
3120
|
+
(click)="onPinToggleClick($event)"
|
|
3121
|
+
>
|
|
3122
|
+
<cds-icon [size]="'12'" [shape]="pinned ? 'unpin' : 'pin'" solid aria-hidden="true"></cds-icon>
|
|
3123
|
+
</button>
|
|
3124
|
+
}
|
|
3125
|
+
|
|
3047
3126
|
@if (showSeparator) {
|
|
3048
3127
|
<clr-dg-column-separator></clr-dg-column-separator>
|
|
3049
3128
|
}
|
|
3050
3129
|
</div>
|
|
3051
3130
|
`,
|
|
3052
3131
|
hostDirectives: [ClrPopoverHostDirective],
|
|
3132
|
+
// Shared by clr-dg-column-actions and this column's filter, whichever order they are created in.
|
|
3133
|
+
providers: [ColumnActionsService],
|
|
3053
3134
|
host: {
|
|
3054
3135
|
'[class.datagrid-column]': 'true',
|
|
3055
3136
|
'[attr.aria-sort]': 'ariaSort',
|
|
@@ -3075,9 +3156,15 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.1.3", ngImpor
|
|
|
3075
3156
|
}], disableUnsort: [{
|
|
3076
3157
|
type: Input,
|
|
3077
3158
|
args: ['clrDgDisableUnsort']
|
|
3159
|
+
}], pinnable: [{
|
|
3160
|
+
type: Input,
|
|
3161
|
+
args: [{ alias: 'clrDgPinnable', transform: booleanAttribute }]
|
|
3078
3162
|
}], sortOrderChange: [{
|
|
3079
3163
|
type: Output,
|
|
3080
3164
|
args: ['clrDgSortOrderChange']
|
|
3165
|
+
}], pinnedChange: [{
|
|
3166
|
+
type: Output,
|
|
3167
|
+
args: ['clrDgPinnedChange']
|
|
3081
3168
|
}], filterValueChange: [{
|
|
3082
3169
|
type: Output,
|
|
3083
3170
|
args: ['clrFilterValueChange']
|
|
@@ -3271,10 +3358,10 @@ class Items {
|
|
|
3271
3358
|
}
|
|
3272
3359
|
this.emitChange();
|
|
3273
3360
|
}
|
|
3274
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.
|
|
3275
|
-
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.
|
|
3361
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: Items, deps: [{ token: FiltersProvider }, { token: Sort }, { token: Page }], target: i0.ɵɵFactoryTarget.Injectable }); }
|
|
3362
|
+
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: Items }); }
|
|
3276
3363
|
}
|
|
3277
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.
|
|
3364
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: Items, decorators: [{
|
|
3278
3365
|
type: Injectable
|
|
3279
3366
|
}], ctorParameters: () => [{ type: FiltersProvider }, { type: Sort }, { type: Page }] });
|
|
3280
3367
|
|
|
@@ -3331,10 +3418,10 @@ class ClrDatagridItems {
|
|
|
3331
3418
|
this.subscriptions.forEach(sub => sub.unsubscribe());
|
|
3332
3419
|
this.items.smartenDown();
|
|
3333
3420
|
}
|
|
3334
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.
|
|
3335
|
-
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "21.
|
|
3421
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: ClrDatagridItems, deps: [{ token: i0.TemplateRef }, { token: i0.IterableDiffers }, { token: Items }, { token: i0.ViewContainerRef }], target: i0.ɵɵFactoryTarget.Directive }); }
|
|
3422
|
+
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "21.2.25", type: ClrDatagridItems, isStandalone: false, selector: "[clrDgItems][clrDgItemsOf]", inputs: { rawItems: ["clrDgItemsOf", "rawItems"], trackBy: ["clrDgItemsTrackBy", "trackBy"] }, ngImport: i0 }); }
|
|
3336
3423
|
}
|
|
3337
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.
|
|
3424
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: ClrDatagridItems, decorators: [{
|
|
3338
3425
|
type: Directive,
|
|
3339
3426
|
args: [{
|
|
3340
3427
|
selector: '[clrDgItems][clrDgItemsOf]',
|
|
@@ -3364,8 +3451,8 @@ class ClrDatagridPlaceholder {
|
|
|
3364
3451
|
get emptyDatagrid() {
|
|
3365
3452
|
return !this.items.loading && (!this.items.displayed || this.items.displayed.length === 0);
|
|
3366
3453
|
}
|
|
3367
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.
|
|
3368
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.
|
|
3454
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: ClrDatagridPlaceholder, deps: [{ token: Items }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
3455
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.25", type: ClrDatagridPlaceholder, isStandalone: false, selector: "clr-dg-placeholder", host: { properties: { "class.datagrid-placeholder-container": "true" } }, ngImport: i0, template: `
|
|
3369
3456
|
<div class="datagrid-placeholder" [class.datagrid-empty]="emptyDatagrid">
|
|
3370
3457
|
@if (emptyDatagrid) {
|
|
3371
3458
|
<div class="datagrid-placeholder-image"></div>
|
|
@@ -3378,7 +3465,7 @@ class ClrDatagridPlaceholder {
|
|
|
3378
3465
|
</div>
|
|
3379
3466
|
`, isInline: true }); }
|
|
3380
3467
|
}
|
|
3381
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.
|
|
3468
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: ClrDatagridPlaceholder, decorators: [{
|
|
3382
3469
|
type: Component,
|
|
3383
3470
|
args: [{
|
|
3384
3471
|
selector: 'clr-dg-placeholder',
|
|
@@ -3412,14 +3499,14 @@ class WrappedCell {
|
|
|
3412
3499
|
ngOnDestroy() {
|
|
3413
3500
|
this.cellView.destroy();
|
|
3414
3501
|
}
|
|
3415
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.
|
|
3416
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "21.
|
|
3502
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: WrappedCell, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
3503
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "21.2.25", type: WrappedCell, isStandalone: false, selector: "dg-wrapped-cell", viewQueries: [{ propertyName: "templateRef", first: true, predicate: ["cellPortal"], descendants: true }], ngImport: i0, template: `
|
|
3417
3504
|
<ng-template #cellPortal>
|
|
3418
3505
|
<ng-content></ng-content>
|
|
3419
3506
|
</ng-template>
|
|
3420
3507
|
`, isInline: true }); }
|
|
3421
3508
|
}
|
|
3422
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.
|
|
3509
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: WrappedCell, decorators: [{
|
|
3423
3510
|
type: Component,
|
|
3424
3511
|
args: [{
|
|
3425
3512
|
selector: 'dg-wrapped-cell',
|
|
@@ -3451,10 +3538,10 @@ class ClrDatagridCell {
|
|
|
3451
3538
|
ngOnInit() {
|
|
3452
3539
|
this.wrappedInjector = new HostWrapper(WrappedCell, this.vcr);
|
|
3453
3540
|
}
|
|
3454
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.
|
|
3455
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "21.
|
|
3541
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: ClrDatagridCell, deps: [{ token: i0.ViewContainerRef }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
3542
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "21.2.25", type: ClrDatagridCell, isStandalone: false, selector: "clr-dg-cell", host: { attributes: { "role": "gridcell" }, properties: { "class.datagrid-cell": "true", "class.datagrid-signpost-trigger": "signpost.length > 0" } }, queries: [{ propertyName: "signpost", predicate: ClrSignpost }], ngImport: i0, template: `<ng-content></ng-content>`, isInline: true }); }
|
|
3456
3543
|
}
|
|
3457
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.
|
|
3544
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: ClrDatagridCell, decorators: [{
|
|
3458
3545
|
type: Component,
|
|
3459
3546
|
args: [{
|
|
3460
3547
|
selector: 'clr-dg-cell',
|
|
@@ -3514,10 +3601,10 @@ class DatagridIfExpandService extends IfExpandService {
|
|
|
3514
3601
|
setReplace(replaceValue) {
|
|
3515
3602
|
this._replace.next(replaceValue);
|
|
3516
3603
|
}
|
|
3517
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.
|
|
3518
|
-
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.
|
|
3604
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: DatagridIfExpandService, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
|
|
3605
|
+
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: DatagridIfExpandService }); }
|
|
3519
3606
|
}
|
|
3520
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.
|
|
3607
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: DatagridIfExpandService, decorators: [{
|
|
3521
3608
|
type: Injectable
|
|
3522
3609
|
}], ctorParameters: () => [] });
|
|
3523
3610
|
|
|
@@ -3576,14 +3663,14 @@ class WrappedRow {
|
|
|
3576
3663
|
ngOnDestroy() {
|
|
3577
3664
|
this.rowView.destroy();
|
|
3578
3665
|
}
|
|
3579
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.
|
|
3580
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "21.
|
|
3666
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: WrappedRow, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
3667
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "21.2.25", type: WrappedRow, isStandalone: false, selector: "dg-wrapped-row", viewQueries: [{ propertyName: "templateRef", first: true, predicate: ["rowPortal"], descendants: true }], ngImport: i0, template: `
|
|
3581
3668
|
<ng-template #rowPortal>
|
|
3582
3669
|
<ng-content></ng-content>
|
|
3583
3670
|
</ng-template>
|
|
3584
3671
|
`, isInline: true }); }
|
|
3585
3672
|
}
|
|
3586
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.
|
|
3673
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: WrappedRow, decorators: [{
|
|
3587
3674
|
type: Component,
|
|
3588
3675
|
args: [{
|
|
3589
3676
|
selector: 'dg-wrapped-row',
|
|
@@ -3933,10 +4020,10 @@ class Selection {
|
|
|
3933
4020
|
updateCurrentSelectionRefs() {
|
|
3934
4021
|
this._currentSelectionRefs = this._current?.map(item => this._items.identifyBy(item)) || [];
|
|
3935
4022
|
}
|
|
3936
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.
|
|
3937
|
-
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.
|
|
4023
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: Selection, deps: [{ token: Items }, { token: FiltersProvider }, { token: i0.IterableDiffers }], target: i0.ɵɵFactoryTarget.Injectable }); }
|
|
4024
|
+
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: Selection }); }
|
|
3938
4025
|
}
|
|
3939
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.
|
|
4026
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: Selection, decorators: [{
|
|
3940
4027
|
type: Injectable
|
|
3941
4028
|
}], ctorParameters: () => [{ type: Items }, { type: FiltersProvider }, { type: i0.IterableDiffers }] });
|
|
3942
4029
|
|
|
@@ -3962,10 +4049,10 @@ class RowActionService {
|
|
|
3962
4049
|
unregister() {
|
|
3963
4050
|
this.actionableCount--;
|
|
3964
4051
|
}
|
|
3965
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.
|
|
3966
|
-
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.
|
|
4052
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: RowActionService, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
|
|
4053
|
+
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: RowActionService }); }
|
|
3967
4054
|
}
|
|
3968
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.
|
|
4055
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: RowActionService, decorators: [{
|
|
3969
4056
|
type: Injectable
|
|
3970
4057
|
}] });
|
|
3971
4058
|
|
|
@@ -3993,10 +4080,10 @@ class ExpandableRowsCount {
|
|
|
3993
4080
|
unregister() {
|
|
3994
4081
|
this.expandableCount--;
|
|
3995
4082
|
}
|
|
3996
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.
|
|
3997
|
-
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.
|
|
4083
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: ExpandableRowsCount, deps: [{ token: DetailService }], target: i0.ɵɵFactoryTarget.Injectable }); }
|
|
4084
|
+
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: ExpandableRowsCount }); }
|
|
3998
4085
|
}
|
|
3999
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.
|
|
4086
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: ExpandableRowsCount, decorators: [{
|
|
4000
4087
|
type: Injectable
|
|
4001
4088
|
}], ctorParameters: () => [{ type: DetailService }] });
|
|
4002
4089
|
|
|
@@ -4023,10 +4110,10 @@ class DisplayModeService {
|
|
|
4023
4110
|
ngOnDestroy() {
|
|
4024
4111
|
this.subscriptions.forEach(sub => sub.unsubscribe());
|
|
4025
4112
|
}
|
|
4026
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.
|
|
4027
|
-
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.
|
|
4113
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: DisplayModeService, deps: [{ token: DatagridRenderOrganizer }], target: i0.ɵɵFactoryTarget.Injectable }); }
|
|
4114
|
+
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: DisplayModeService }); }
|
|
4028
4115
|
}
|
|
4029
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.
|
|
4116
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: DisplayModeService, decorators: [{
|
|
4030
4117
|
type: Injectable
|
|
4031
4118
|
}], ctorParameters: () => [{ type: DatagridRenderOrganizer }] });
|
|
4032
4119
|
|
|
@@ -4074,8 +4161,8 @@ class ClrDatagridSingleSelectionValueAccessor {
|
|
|
4074
4161
|
const value = this.keyOf(this.value);
|
|
4075
4162
|
this.renderer.setProperty(this.elementRef.nativeElement, 'checked', state === value);
|
|
4076
4163
|
}
|
|
4077
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.
|
|
4078
|
-
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "21.
|
|
4164
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: ClrDatagridSingleSelectionValueAccessor, deps: [{ token: i0.Renderer2 }, { token: i0.ElementRef }], target: i0.ɵɵFactoryTarget.Directive }); }
|
|
4165
|
+
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "21.2.25", type: ClrDatagridSingleSelectionValueAccessor, isStandalone: true, selector: "input[type=radio][clrDgSingleSelectionRadio]", inputs: { value: "value", clrDgIdentityFn: "clrDgIdentityFn" }, host: { listeners: { "change": "onChange(value)", "blur": "onTouched()" } }, providers: [
|
|
4079
4166
|
{
|
|
4080
4167
|
provide: NG_VALUE_ACCESSOR,
|
|
4081
4168
|
useExisting: forwardRef(() => ClrDatagridSingleSelectionValueAccessor),
|
|
@@ -4083,7 +4170,7 @@ class ClrDatagridSingleSelectionValueAccessor {
|
|
|
4083
4170
|
},
|
|
4084
4171
|
], ngImport: i0 }); }
|
|
4085
4172
|
}
|
|
4086
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.
|
|
4173
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: ClrDatagridSingleSelectionValueAccessor, decorators: [{
|
|
4087
4174
|
type: Directive,
|
|
4088
4175
|
args: [{
|
|
4089
4176
|
selector: 'input[type=radio][clrDgSingleSelectionRadio]',
|
|
@@ -4126,10 +4213,10 @@ class ClrDatagridSelectionCellDirective {
|
|
|
4126
4213
|
event.target.querySelector('input')?.click();
|
|
4127
4214
|
}
|
|
4128
4215
|
}
|
|
4129
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.
|
|
4130
|
-
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "21.
|
|
4216
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: ClrDatagridSelectionCellDirective, deps: [{ token: Selection }], target: i0.ɵɵFactoryTarget.Directive }); }
|
|
4217
|
+
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "21.2.25", type: ClrDatagridSelectionCellDirective, isStandalone: false, selector: ".datagrid-select", host: { listeners: { "click": "onSelectionCellClick($event)" } }, ngImport: i0 }); }
|
|
4131
4218
|
}
|
|
4132
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.
|
|
4219
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: ClrDatagridSelectionCellDirective, decorators: [{
|
|
4133
4220
|
type: Directive,
|
|
4134
4221
|
args: [{
|
|
4135
4222
|
selector: '.datagrid-select',
|
|
@@ -4179,6 +4266,13 @@ class ClrDatagridRow {
|
|
|
4179
4266
|
this._detailCloseLabel = '';
|
|
4180
4267
|
this._rowSelectionLabel = '';
|
|
4181
4268
|
this.subscriptions = [];
|
|
4269
|
+
/**
|
|
4270
|
+
* The placeholder cells we create from `fixedCellTemplate` for the calculate pass. Unlike the
|
|
4271
|
+
* cell views, which belong to their `WrappedCell`, these are created here on every pass, so
|
|
4272
|
+
* they are ours to destroy. Detaching them from the container only unlinks them - the views
|
|
4273
|
+
* themselves would stay alive and keep the whole row, and the datagrid with it, in memory.
|
|
4274
|
+
*/
|
|
4275
|
+
this.fixedCellViews = [];
|
|
4182
4276
|
// By default, every item is selectable; it becomes not selectable only if it's explicitly set to false
|
|
4183
4277
|
this._selectable = true;
|
|
4184
4278
|
nbRow++;
|
|
@@ -4302,6 +4396,7 @@ class ClrDatagridRow {
|
|
|
4302
4396
|
this._pinnedCells.detach();
|
|
4303
4397
|
}
|
|
4304
4398
|
// remove cell views from calculated view
|
|
4399
|
+
this.destroyFixedCellViews();
|
|
4305
4400
|
for (let i = this._calculatedCells.length; i > 0; i--) {
|
|
4306
4401
|
this._calculatedCells.detach();
|
|
4307
4402
|
}
|
|
@@ -4314,9 +4409,11 @@ class ClrDatagridRow {
|
|
|
4314
4409
|
this.globalExpandable.hasExpandableRow,
|
|
4315
4410
|
this.detailService.enabled,
|
|
4316
4411
|
];
|
|
4317
|
-
fixedCellConditions
|
|
4318
|
-
.
|
|
4319
|
-
|
|
4412
|
+
fixedCellConditions.filter(Boolean).forEach(() => {
|
|
4413
|
+
const fixedCellView = this._fixedCellTemplate.createEmbeddedView(null);
|
|
4414
|
+
this.fixedCellViews.push(fixedCellView);
|
|
4415
|
+
this._calculatedCells.insert(fixedCellView);
|
|
4416
|
+
});
|
|
4320
4417
|
this.dgCells.forEach(cell => {
|
|
4321
4418
|
if (!cell._view.destroyed) {
|
|
4322
4419
|
this._calculatedCells.insert(cell._view);
|
|
@@ -4332,6 +4429,7 @@ class ClrDatagridRow {
|
|
|
4332
4429
|
}));
|
|
4333
4430
|
}
|
|
4334
4431
|
ngOnDestroy() {
|
|
4432
|
+
this.destroyFixedCellViews();
|
|
4335
4433
|
this.subscriptions.forEach((sub) => sub.unsubscribe());
|
|
4336
4434
|
}
|
|
4337
4435
|
toggle(selected = !this.selected) {
|
|
@@ -4382,6 +4480,16 @@ class ClrDatagridRow {
|
|
|
4382
4480
|
this.toggle(selected);
|
|
4383
4481
|
}
|
|
4384
4482
|
}
|
|
4483
|
+
destroyFixedCellViews() {
|
|
4484
|
+
// On teardown Angular has already destroyed the views in our container by the time it runs our
|
|
4485
|
+
// `ngOnDestroy`, so only the calculate/display transition has live ones to release here.
|
|
4486
|
+
this.fixedCellViews.forEach(view => {
|
|
4487
|
+
if (!view.destroyed) {
|
|
4488
|
+
view.destroy();
|
|
4489
|
+
}
|
|
4490
|
+
});
|
|
4491
|
+
this.fixedCellViews = [];
|
|
4492
|
+
}
|
|
4385
4493
|
/**
|
|
4386
4494
|
* Projects the cells into the display containers. Cells of pinned columns go into their static
|
|
4387
4495
|
* container so they stay visible during horizontal scroll; the rest stay scrollable. Cells are
|
|
@@ -4419,14 +4527,14 @@ class ClrDatagridRow {
|
|
|
4419
4527
|
this.selection.rangeStart = this.item;
|
|
4420
4528
|
}
|
|
4421
4529
|
}
|
|
4422
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.
|
|
4423
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.
|
|
4530
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: ClrDatagridRow, deps: [{ token: Selection }, { token: RowActionService }, { token: ExpandableRowsCount }, { token: DatagridIfExpandService }, { token: DetailService }, { token: DisplayModeService }, { token: i0.ViewContainerRef }, { token: i0.Renderer2 }, { token: i0.ElementRef }, { token: i2.ClrCommonStringsService }, { token: Items }, { token: ColumnsService }, { token: DOCUMENT }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
4531
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.25", type: ClrDatagridRow, isStandalone: false, selector: "clr-dg-row", inputs: { detailDisabled: ["clrDgDetailDisabled", "detailDisabled"], detailHidden: ["clrDgDetailHidden", "detailHidden"], skeletonLoading: ["clrDgSkeletonLoading", "skeletonLoading"], item: ["clrDgItem", "item"], clrDgSelectable: "clrDgSelectable", selected: ["clrDgSelected", "selected"], expanded: ["clrDgExpanded", "expanded"], clrDgDetailOpenLabel: "clrDgDetailOpenLabel", clrDgDetailCloseLabel: "clrDgDetailCloseLabel", clrDgRowSelectionLabel: "clrDgRowSelectionLabel" }, outputs: { selectedChanged: "clrDgSelectedChange", expandedChange: "clrDgExpandedChange" }, host: { attributes: { "role": "rowgroup" }, properties: { "class.datagrid-row": "true", "class.datagrid-row-skeleton": "skeletonLoading", "class.datagrid-selected": "selected", "attr.aria-owns": "id" } }, providers: [
|
|
4424
4532
|
DatagridIfExpandService,
|
|
4425
4533
|
{ provide: IfExpandService, useExisting: DatagridIfExpandService },
|
|
4426
4534
|
{ provide: LoadingListener, useExisting: DatagridIfExpandService },
|
|
4427
|
-
], queries: [{ propertyName: "dgCells", predicate: ClrDatagridCell }], viewQueries: [{ propertyName: "expandAnimation", first: true, predicate: ClrExpandableAnimationDirective, descendants: true }, { propertyName: "detailButton", first: true, predicate: ["detailButton"], descendants: true }, { propertyName: "_stickyCells", first: true, predicate: ["stickyCells"], descendants: true, read: ViewContainerRef }, { propertyName: "_pinnedCells", first: true, predicate: ["pinnedCells"], descendants: true, read: ViewContainerRef }, { propertyName: "_scrollableCells", first: true, predicate: ["scrollableCells"], descendants: true, read: ViewContainerRef }, { propertyName: "_calculatedCells", first: true, predicate: ["calculatedCells"], descendants: true, read: ViewContainerRef }, { propertyName: "_fixedCellTemplate", first: true, predicate: ["fixedCellTemplate"], descendants: true }], ngImport: i0, template: "<!--\n ~ Copyright (c) 2016-2026 Broadcom. All Rights Reserved.\n ~ The term \"Broadcom\" refers to Broadcom Inc. and/or its subsidiaries.\n ~ This software is released under MIT license.\n ~ The full license information can be found in LICENSE in the root directory of this project.\n -->\n<div\n role=\"row\"\n [id]=\"id\"\n class=\"datagrid-row-master datagrid-row-flex\"\n (mousedown)=\"clearRanges($event)\"\n (click)=\"selectRow(!selected, $event)\"\n [class.datagrid-row-clickable]=\"selection.rowSelectionMode\"\n [class.datagrid-row-detail-open]=\"detailService.isRowOpen(item)\"\n>\n <div class=\"datagrid-row-sticky\">\n <!-- Sticky elements here -->\n <ng-container #stickyCells>\n @if (selection.selectionType === SELECTION_TYPE.Multi) {\n <div\n class=\"datagrid-select datagrid-fixed-column datagrid-cell\"\n [ngClass]=\"{ 'clr-form-control-disabled': !clrDgSelectable }\"\n role=\"gridcell\"\n >\n <div class=\"clr-checkbox-wrapper\">\n <input\n tabindex=\"-1\"\n type=\"checkbox\"\n [ngModel]=\"selected\"\n (ngModelChange)=\"toggle($event)\"\n [id]=\"checkboxId\"\n [disabled]=\"clrDgSelectable ? null : true\"\n [attr.aria-disabled]=\"clrDgSelectable ? null : true\"\n />\n <!-- Usage of class clr-col-null here prevents clr-col-* classes from being added when a datagrid is wrapped inside clrForm -->\n <label [for]=\"checkboxId\" class=\"clr-control-label clr-col-null\" (click)=\"clearRanges($event)\">\n <span class=\"clr-sr-only\">{{clrDgRowSelectionLabel || commonStrings.keys.select}}</span>\n </label>\n </div>\n </div>\n } @if (selection.selectionType === SELECTION_TYPE.Single) {\n <div\n class=\"datagrid-select datagrid-fixed-column datagrid-cell\"\n [ngClass]=\"{ 'clr-form-control-disabled': !clrDgSelectable }\"\n role=\"gridcell\"\n >\n <clr-radio-wrapper>\n <input\n tabindex=\"-1\"\n type=\"radio\"\n clrRadio\n clrDgSingleSelectionRadio\n [clrDgIdentityFn]=\"identifyBy\"\n [id]=\"radioId\"\n [name]=\"selection.id + '-radio'\"\n [value]=\"item\"\n [ngModel]=\"selection.currentSingle\"\n (ngModelChange)=\"selection.current = [$event]\"\n [disabled]=\"clrDgSelectable ? null : true\"\n [attr.aria-disabled]=\"clrDgSelectable ? null : true\"\n />\n <label class=\"clr-control-label clr-col-null\" [for]=\"radioId\">\n <span class=\"clr-sr-only\">{{ clrDgRowSelectionLabel || commonStrings.keys.select }}</span>\n </label>\n </clr-radio-wrapper>\n </div>\n } @if (rowActionService.hasActionableRow) {\n <div class=\"datagrid-row-actions datagrid-fixed-column datagrid-cell\" role=\"gridcell\">\n <ng-content select=\"clr-dg-action-overflow\"></ng-content>\n </div>\n } @if (globalExpandable.hasExpandableRow) {\n <div class=\"datagrid-expandable-caret datagrid-fixed-column datagrid-cell\" role=\"gridcell\">\n @if (expand.expandable) { @if (!expand.loading) {\n <button\n tabindex=\"-1\"\n (click)=\"toggleExpand($event)\"\n type=\"button\"\n class=\"datagrid-expandable-caret-button\"\n [attr.aria-expanded]=\"expand.expanded\"\n [attr.aria-label]=\"expand.expanded ? clrDgDetailCloseLabel : clrDgDetailOpenLabel\"\n [attr.aria-controls]=\"expand.hasExpandTemplate && !expand.expanded ? null : expandableId\"\n >\n <cds-icon\n shape=\"angle\"\n class=\"datagrid-expandable-caret-icon\"\n [direction]=\"expand.expanded ? 'down' : 'right'\"\n [attr.title]=\"expand.expanded ? commonStrings.keys.collapse : commonStrings.keys.expand\"\n ></cds-icon>\n </button>\n } @if (expand.loading) {\n <clr-spinner clrSmall>{{ commonStrings.keys.loading }}</clr-spinner>\n } }\n </div>\n } @if (detailService.enabled) {\n <div class=\"datagrid-detail-caret datagrid-fixed-column datagrid-cell\" role=\"gridcell\">\n @if (!detailHidden) {\n <button\n tabindex=\"-1\"\n (click)=\"openDetails($event, detailButton)\"\n type=\"button\"\n #detailButton\n class=\"datagrid-detail-caret-button\"\n [disabled]=\"detailDisabled\"\n [class.is-open]=\"detailService.isRowOpen(item)\"\n [attr.aria-label]=\"detailService.isRowOpen(item) ? clrDgDetailCloseLabel : clrDgDetailOpenLabel\"\n [attr.aria-expanded]=\"detailService.isRowOpen(item)\"\n [attr.aria-controls]=\"detailService.id\"\n aria-haspopup=\"dialog\"\n >\n <cds-icon\n shape=\"angle-double\"\n [direction]=\"detailService.isRowOpen(item) ? 'left' : 'right'\"\n class=\"datagrid-detail-caret-icon\"\n [attr.title]=\"detailService.isRowOpen(item) ? commonStrings.keys.close: commonStrings.keys.open\"\n ></cds-icon>\n </button>\n }\n </div>\n }\n </ng-container>\n </div>\n <div\n class=\"datagrid-row-scrollable\"\n [ngClass]=\"{'is-replaced': replaced && expanded}\"\n [clrExpandableAnimation]=\"expandAnimationTrigger\"\n >\n <div class=\"datagrid-scrolling-cells\">\n <div class=\"datagrid-pinned-cells\">\n <ng-container #pinnedCells></ng-container>\n </div>\n <ng-content select=\"clr-dg-cell\"></ng-content>\n <ng-container #scrollableCells></ng-container>\n </div>\n\n @if (!expand.loading) {\n <ng-template [ngTemplateOutlet]=\"detail\"></ng-template>\n }\n </div>\n</div>\n<!--\nWe need the \"project into template\" hacks because we need this in 2 different places\ndepending on whether the details replace the row or not.\n-->\n<ng-template #detail>\n <ng-content select=\"clr-dg-row-detail\"></ng-content>\n</ng-template>\n\n<ng-container #calculatedCells></ng-container>\n\n<ng-template #fixedCellTemplate>\n <div class=\"datagrid-fixed-column datagrid-cell\" role=\"gridcell\"></div>\n</ng-template>\n", dependencies: [{ kind: "directive", type: i10.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i10.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "component", type:
|
|
4535
|
+
], queries: [{ propertyName: "dgCells", predicate: ClrDatagridCell }], viewQueries: [{ propertyName: "expandAnimation", first: true, predicate: ClrExpandableAnimationDirective, descendants: true }, { propertyName: "detailButton", first: true, predicate: ["detailButton"], descendants: true }, { propertyName: "_stickyCells", first: true, predicate: ["stickyCells"], descendants: true, read: ViewContainerRef }, { propertyName: "_pinnedCells", first: true, predicate: ["pinnedCells"], descendants: true, read: ViewContainerRef }, { propertyName: "_scrollableCells", first: true, predicate: ["scrollableCells"], descendants: true, read: ViewContainerRef }, { propertyName: "_calculatedCells", first: true, predicate: ["calculatedCells"], descendants: true, read: ViewContainerRef }, { propertyName: "_fixedCellTemplate", first: true, predicate: ["fixedCellTemplate"], descendants: true }], ngImport: i0, template: "<!--\n ~ Copyright (c) 2016-2026 Broadcom. All Rights Reserved.\n ~ The term \"Broadcom\" refers to Broadcom Inc. and/or its subsidiaries.\n ~ This software is released under MIT license.\n ~ The full license information can be found in LICENSE in the root directory of this project.\n -->\n<div\n role=\"row\"\n [id]=\"id\"\n class=\"datagrid-row-master datagrid-row-flex\"\n (mousedown)=\"clearRanges($event)\"\n (click)=\"selectRow(!selected, $event)\"\n [class.datagrid-row-clickable]=\"selection.rowSelectionMode\"\n [class.datagrid-row-detail-open]=\"detailService.isRowOpen(item)\"\n>\n <div class=\"datagrid-row-sticky\">\n <!-- Sticky elements here -->\n <ng-container #stickyCells>\n @if (selection.selectionType === SELECTION_TYPE.Multi) {\n <div\n class=\"datagrid-select datagrid-fixed-column datagrid-cell\"\n [ngClass]=\"{ 'clr-form-control-disabled': !clrDgSelectable }\"\n role=\"gridcell\"\n >\n <div class=\"clr-checkbox-wrapper\">\n <input\n tabindex=\"-1\"\n type=\"checkbox\"\n [ngModel]=\"selected\"\n (ngModelChange)=\"toggle($event)\"\n [id]=\"checkboxId\"\n [disabled]=\"clrDgSelectable ? null : true\"\n [attr.aria-disabled]=\"clrDgSelectable ? null : true\"\n />\n <!-- Usage of class clr-col-null here prevents clr-col-* classes from being added when a datagrid is wrapped inside clrForm -->\n <label [for]=\"checkboxId\" class=\"clr-control-label clr-col-null\" (click)=\"clearRanges($event)\">\n <span class=\"clr-sr-only\">{{clrDgRowSelectionLabel || commonStrings.keys.select}}</span>\n </label>\n </div>\n </div>\n } @if (selection.selectionType === SELECTION_TYPE.Single) {\n <div\n class=\"datagrid-select datagrid-fixed-column datagrid-cell\"\n [ngClass]=\"{ 'clr-form-control-disabled': !clrDgSelectable }\"\n role=\"gridcell\"\n >\n <clr-radio-wrapper>\n <input\n tabindex=\"-1\"\n type=\"radio\"\n clrRadio\n clrDgSingleSelectionRadio\n [clrDgIdentityFn]=\"identifyBy\"\n [id]=\"radioId\"\n [name]=\"selection.id + '-radio'\"\n [value]=\"item\"\n [ngModel]=\"selection.currentSingle\"\n (ngModelChange)=\"selection.current = [$event]\"\n [disabled]=\"clrDgSelectable ? null : true\"\n [attr.aria-disabled]=\"clrDgSelectable ? null : true\"\n />\n <label class=\"clr-control-label clr-col-null\" [for]=\"radioId\">\n <span class=\"clr-sr-only\">{{ clrDgRowSelectionLabel || commonStrings.keys.select }}</span>\n </label>\n </clr-radio-wrapper>\n </div>\n } @if (rowActionService.hasActionableRow) {\n <div class=\"datagrid-row-actions datagrid-fixed-column datagrid-cell\" role=\"gridcell\">\n <ng-content select=\"clr-dg-action-overflow\"></ng-content>\n </div>\n } @if (globalExpandable.hasExpandableRow) {\n <div class=\"datagrid-expandable-caret datagrid-fixed-column datagrid-cell\" role=\"gridcell\">\n @if (expand.expandable) { @if (!expand.loading) {\n <button\n tabindex=\"-1\"\n (click)=\"toggleExpand($event)\"\n type=\"button\"\n class=\"datagrid-expandable-caret-button\"\n [attr.aria-expanded]=\"expand.expanded\"\n [attr.aria-label]=\"expand.expanded ? clrDgDetailCloseLabel : clrDgDetailOpenLabel\"\n [attr.aria-controls]=\"expand.hasExpandTemplate && !expand.expanded ? null : expandableId\"\n >\n <cds-icon\n shape=\"angle\"\n class=\"datagrid-expandable-caret-icon\"\n [direction]=\"expand.expanded ? 'down' : 'right'\"\n [attr.title]=\"expand.expanded ? commonStrings.keys.collapse : commonStrings.keys.expand\"\n ></cds-icon>\n </button>\n } @if (expand.loading) {\n <clr-spinner clrSmall>{{ commonStrings.keys.loading }}</clr-spinner>\n } }\n </div>\n } @if (detailService.enabled) {\n <div class=\"datagrid-detail-caret datagrid-fixed-column datagrid-cell\" role=\"gridcell\">\n @if (!detailHidden) {\n <button\n tabindex=\"-1\"\n (click)=\"openDetails($event, detailButton)\"\n type=\"button\"\n #detailButton\n class=\"datagrid-detail-caret-button\"\n [disabled]=\"detailDisabled\"\n [class.is-open]=\"detailService.isRowOpen(item)\"\n [attr.aria-label]=\"detailService.isRowOpen(item) ? clrDgDetailCloseLabel : clrDgDetailOpenLabel\"\n [attr.aria-expanded]=\"detailService.isRowOpen(item)\"\n [attr.aria-controls]=\"detailService.id\"\n aria-haspopup=\"dialog\"\n >\n <cds-icon\n shape=\"angle-double\"\n [direction]=\"detailService.isRowOpen(item) ? 'left' : 'right'\"\n class=\"datagrid-detail-caret-icon\"\n [attr.title]=\"detailService.isRowOpen(item) ? commonStrings.keys.close: commonStrings.keys.open\"\n ></cds-icon>\n </button>\n }\n </div>\n }\n </ng-container>\n </div>\n <div\n class=\"datagrid-row-scrollable\"\n [ngClass]=\"{'is-replaced': replaced && expanded}\"\n [clrExpandableAnimation]=\"expandAnimationTrigger\"\n >\n <div class=\"datagrid-scrolling-cells\">\n <div class=\"datagrid-pinned-cells\">\n <ng-container #pinnedCells></ng-container>\n </div>\n <ng-content select=\"clr-dg-cell\"></ng-content>\n <ng-container #scrollableCells></ng-container>\n </div>\n\n @if (!expand.loading) {\n <ng-template [ngTemplateOutlet]=\"detail\"></ng-template>\n }\n </div>\n</div>\n<!--\nWe need the \"project into template\" hacks because we need this in 2 different places\ndepending on whether the details replace the row or not.\n-->\n<ng-template #detail>\n <ng-content select=\"clr-dg-row-detail\"></ng-content>\n</ng-template>\n\n<ng-container #calculatedCells></ng-container>\n\n<ng-template #fixedCellTemplate>\n <div class=\"datagrid-fixed-column datagrid-cell\" role=\"gridcell\"></div>\n</ng-template>\n", dependencies: [{ kind: "directive", type: i10.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i10.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "component", type: i4.ClrIcon, selector: "clr-icon, cds-icon", inputs: ["shape", "size", "direction", "flip", "solid", "status", "inverse", "badge", "innerOffset"] }, { kind: "directive", type: i4$1.ClrControlLabel, selector: "label", inputs: ["id", "for"] }, { kind: "directive", type: i13.ClrRadio, selector: "[clrRadio]" }, { kind: "component", type: i13.ClrRadioWrapper, selector: "clr-radio-wrapper" }, { kind: "directive", type: i14.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: i14.CheckboxControlValueAccessor, selector: "input[type=checkbox][formControlName],input[type=checkbox][formControl],input[type=checkbox][ngModel]" }, { kind: "directive", type: i14.RadioControlValueAccessor, selector: "input[type=radio][formControlName],input[type=radio][formControl],input[type=radio][ngModel]", inputs: ["name", "formControlName", "value"] }, { kind: "directive", type: i14.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i14.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "directive", type: i2.ClrExpandableAnimationDirective, selector: "[clrExpandableAnimation]", inputs: ["clrExpandableAnimation"] }, { kind: "component", type: i15.ClrSpinner, selector: "clr-spinner", inputs: ["clrInline", "clrInverse", "clrSmall", "clrMedium"] }, { kind: "directive", type: ClrDatagridSingleSelectionValueAccessor, selector: "input[type=radio][clrDgSingleSelectionRadio]", inputs: ["value", "clrDgIdentityFn"] }, { kind: "directive", type: ClrDatagridSelectionCellDirective, selector: ".datagrid-select" }] }); }
|
|
4428
4536
|
}
|
|
4429
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.
|
|
4537
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: ClrDatagridRow, decorators: [{
|
|
4430
4538
|
type: Component,
|
|
4431
4539
|
args: [{ selector: 'clr-dg-row', host: {
|
|
4432
4540
|
'[class.datagrid-row]': 'true',
|
|
@@ -4530,6 +4638,14 @@ class ClrDatagridVirtualScrollDirective {
|
|
|
4530
4638
|
this.shouldUpdateAriaRowIndexes = false;
|
|
4531
4639
|
this.subscriptions = [];
|
|
4532
4640
|
this.topIndex = 0;
|
|
4641
|
+
/**
|
|
4642
|
+
* Injectors for the CDK virtual scroll instances we create by hand, in the order they have to be
|
|
4643
|
+
* destroyed. Destroying them is what runs the CDK teardown: their `ngOnDestroy` and, importantly,
|
|
4644
|
+
* the `DestroyRef` cleanup `CdkVirtualScrollViewport` registers for the effect it creates on the
|
|
4645
|
+
* application injector. Leaving them alive keeps that effect registered, which retains the
|
|
4646
|
+
* viewport and the entire datagrid view tree for as long as the application lives.
|
|
4647
|
+
*/
|
|
4648
|
+
this.cdkInjectors = [];
|
|
4533
4649
|
// @deprecated remove the mutation observer when `datagrid-compact` class is deleted
|
|
4534
4650
|
this.mutationChanges = new MutationObserver((mutations) => {
|
|
4535
4651
|
mutations.forEach((mutation) => {
|
|
@@ -4637,7 +4753,7 @@ class ClrDatagridVirtualScrollDirective {
|
|
|
4637
4753
|
ngAfterViewInit() {
|
|
4638
4754
|
runInInjectionContext(this.injector, () => {
|
|
4639
4755
|
this.virtualScrollViewport = this.createVirtualScrollViewportForDatagrid(this.changeDetectorRef, this.ngZone, this.renderer2, this.directionality, this.scrollDispatcher, this.viewportRuler, this.datagridElementRef, this.virtualScrollStrategy);
|
|
4640
|
-
this.cdkVirtualFor = createCdkVirtualForOfDirective(this.viewContainerRef, this.templateRef, this.iterableDiffers, this.virtualScrollViewport, this.ngZone);
|
|
4756
|
+
this.cdkVirtualFor = this.createCdkVirtualForOfDirective(this.viewContainerRef, this.templateRef, this.iterableDiffers, this.virtualScrollViewport, this.ngZone);
|
|
4641
4757
|
this.virtualScrollViewport.ngOnInit();
|
|
4642
4758
|
});
|
|
4643
4759
|
this.gridRoleElement = this.datagridElementRef.nativeElement.querySelector('[role="grid"]');
|
|
@@ -4668,12 +4784,21 @@ class ClrDatagridVirtualScrollDirective {
|
|
|
4668
4784
|
}
|
|
4669
4785
|
}
|
|
4670
4786
|
ngOnDestroy() {
|
|
4671
|
-
|
|
4672
|
-
|
|
4787
|
+
// Ours first: CDK teardown emits on the streams we subscribe to, and third-party teardown that
|
|
4788
|
+
// throws must not be able to leave our own observer and subscriptions behind.
|
|
4673
4789
|
this.mutationChanges?.disconnect();
|
|
4674
4790
|
this.subscriptions.forEach(subscription => {
|
|
4675
4791
|
subscription.unsubscribe();
|
|
4676
4792
|
});
|
|
4793
|
+
try {
|
|
4794
|
+
// Destroying the injectors calls `ngOnDestroy` on the CDK instances they created and runs the
|
|
4795
|
+
// `DestroyRef` cleanup CDK registered for them, so we must not call those hooks ourselves.
|
|
4796
|
+
this.cdkInjectors.forEach(injector => injector.destroy());
|
|
4797
|
+
}
|
|
4798
|
+
finally {
|
|
4799
|
+
// An injector cannot be destroyed twice, so drop them even if one of them threw.
|
|
4800
|
+
this.cdkInjectors.length = 0;
|
|
4801
|
+
}
|
|
4677
4802
|
}
|
|
4678
4803
|
scrollUp(offset, behavior = 'auto') {
|
|
4679
4804
|
this.scrollToIndex(this.topIndex - offset, behavior);
|
|
@@ -4729,13 +4854,62 @@ class ClrDatagridVirtualScrollDirective {
|
|
|
4729
4854
|
createVirtualScrollViewportForDatagrid(changeDetectorRef, ngZone, renderer2, directionality, scrollDispatcher, viewportRuler, datagridElementRef, virtualScrollStrategy) {
|
|
4730
4855
|
const datagridContentElement = datagridElementRef.nativeElement.querySelector('.datagrid-content');
|
|
4731
4856
|
const datagridRowsElement = datagridElementRef.nativeElement.querySelector('.datagrid-rows');
|
|
4732
|
-
|
|
4857
|
+
return this.createCdkVirtualScrollViewport(new ElementRef(datagridContentElement), new ElementRef(datagridRowsElement), changeDetectorRef, ngZone, renderer2, virtualScrollStrategy, directionality, scrollDispatcher, viewportRuler, null);
|
|
4858
|
+
}
|
|
4859
|
+
createCdkVirtualScrollViewport(datagridDivElementRef, contentWrapper, changeDetectorRef, ngZone, renderer2, virtualScrollStrategy, directionality, scrollDispatcher, viewportRuler, scrollable) {
|
|
4860
|
+
const injector = createEnvironmentInjector([
|
|
4861
|
+
{ provide: ElementRef, useValue: datagridDivElementRef },
|
|
4862
|
+
{ provide: ChangeDetectorRef, useValue: changeDetectorRef },
|
|
4863
|
+
{ provide: NgZone, useValue: ngZone },
|
|
4864
|
+
{ provide: Renderer2, useValue: renderer2 },
|
|
4865
|
+
{ provide: VIRTUAL_SCROLL_STRATEGY, useValue: virtualScrollStrategy },
|
|
4866
|
+
{ provide: CdkVirtualScrollable, useValue: scrollable },
|
|
4867
|
+
{ provide: CdkVirtualScrollViewport, useClass: CdkVirtualScrollViewport },
|
|
4868
|
+
], this.createApplicationInjector(directionality, scrollDispatcher, viewportRuler));
|
|
4869
|
+
const virtualScrollViewport = injector.get(CdkVirtualScrollViewport);
|
|
4870
|
+
virtualScrollViewport._contentWrapper = contentWrapper;
|
|
4871
|
+
// Registered before the caller creates anything else, so a half-finished init still tears down
|
|
4872
|
+
// what it did manage to create.
|
|
4873
|
+
this.cdkInjectors.push(injector);
|
|
4733
4874
|
return virtualScrollViewport;
|
|
4734
4875
|
}
|
|
4735
|
-
|
|
4736
|
-
|
|
4876
|
+
/**
|
|
4877
|
+
* `Directionality`, `ScrollDispatcher` and `ViewportRuler` belong to the application, not to us.
|
|
4878
|
+
* Angular registers every value an injector hands out that has an `ngOnDestroy` - `useValue`
|
|
4879
|
+
* providers included - and calls it from `injector.destroy()`, so putting them in an injector we
|
|
4880
|
+
* destroy would end scroll, resize and text-direction notification for the whole application the
|
|
4881
|
+
* first time a virtual scroll datagrid goes away. They live in this parent, which nothing destroys,
|
|
4882
|
+
* so the viewport still resolves the very instances our host injector gave us - including a
|
|
4883
|
+
* `Directionality` overridden by an ancestor `[dir]`.
|
|
4884
|
+
*/
|
|
4885
|
+
createApplicationInjector(directionality, scrollDispatcher, viewportRuler) {
|
|
4886
|
+
return createEnvironmentInjector([
|
|
4887
|
+
{ provide: Directionality, useValue: directionality },
|
|
4888
|
+
{ provide: ScrollDispatcher, useValue: scrollDispatcher },
|
|
4889
|
+
{ provide: ViewportRuler, useValue: viewportRuler },
|
|
4890
|
+
], inject(EnvironmentInjector));
|
|
4891
|
+
}
|
|
4892
|
+
createCdkVirtualForOfDirective(viewContainerRef, templateRef, iterableDiffers, virtualScrollViewport, ngZone) {
|
|
4893
|
+
// `CdkVirtualForOf` resolves the viewport with `skipSelf`, so it has to come from a parent
|
|
4894
|
+
// injector rather than the one that provides `CdkVirtualForOf` itself. That parent holds nothing
|
|
4895
|
+
// but the value provider, and destroying it would run the viewport's `ngOnDestroy` a second time
|
|
4896
|
+
// on top of the one its own injector already runs, so it is left to be garbage collected.
|
|
4897
|
+
const virtualScrollViewportInjector = createEnvironmentInjector([{ provide: CDK_VIRTUAL_SCROLL_VIEWPORT, useValue: virtualScrollViewport }], inject(EnvironmentInjector));
|
|
4898
|
+
const cdkVirtualForInjector = createEnvironmentInjector([
|
|
4899
|
+
{ provide: ViewContainerRef, useValue: viewContainerRef },
|
|
4900
|
+
{ provide: TemplateRef, useValue: templateRef },
|
|
4901
|
+
{ provide: IterableDiffers, useValue: iterableDiffers },
|
|
4902
|
+
{ provide: NgZone, useValue: ngZone },
|
|
4903
|
+
{ provide: CdkVirtualForOf, useClass: CdkVirtualForOf },
|
|
4904
|
+
], virtualScrollViewportInjector);
|
|
4905
|
+
// `CdkVirtualForOf` reads from the viewport, so it has to go away first.
|
|
4906
|
+
this.cdkInjectors.unshift(cdkVirtualForInjector);
|
|
4907
|
+
return cdkVirtualForInjector.get(CdkVirtualForOf);
|
|
4908
|
+
}
|
|
4909
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: ClrDatagridVirtualScrollDirective, deps: [{ token: i0.ChangeDetectorRef }, { token: i0.IterableDiffers }, { token: Items }, { token: i0.NgZone }, { token: i0.Renderer2 }, { token: i0.TemplateRef }, { token: i0.ViewContainerRef }, { token: i2$1.Directionality }, { token: i3$1.ScrollDispatcher }, { token: i3$1.ViewportRuler }, { token: forwardRef(() => ClrDatagrid) }, { token: i0.EnvironmentInjector }], target: i0.ɵɵFactoryTarget.Directive }); }
|
|
4910
|
+
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "21.2.25", type: ClrDatagridVirtualScrollDirective, isStandalone: false, selector: "[clrVirtualScroll],[ClrVirtualScroll]", inputs: { persistItems: ["clrVirtualPersistItems", "persistItems"], cdkVirtualForOf: ["clrVirtualRowsOf", "cdkVirtualForOf"], cdkVirtualForTrackBy: ["clrVirtualRowsTrackBy", "cdkVirtualForTrackBy"], cdkVirtualForTemplate: ["clrVirtualRowsTemplate", "cdkVirtualForTemplate"], cdkVirtualForTemplateCacheSize: ["clrVirtualRowsTemplateCacheSize", "cdkVirtualForTemplateCacheSize"], itemSize: ["clrVirtualRowsItemSize", "itemSize"], minBufferPx: ["clrVirtualRowsMinBufferPx", "minBufferPx"], maxBufferPx: ["clrVirtualRowsMaxBufferPx", "maxBufferPx"], dataRange: ["clrVirtualDataRange", "dataRange"] }, outputs: { renderedRangeChange: "renderedRangeChange" }, providers: [Items], ngImport: i0 }); }
|
|
4737
4911
|
}
|
|
4738
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.
|
|
4912
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: ClrDatagridVirtualScrollDirective, decorators: [{
|
|
4739
4913
|
type: Directive,
|
|
4740
4914
|
args: [{
|
|
4741
4915
|
selector: '[clrVirtualScroll],[ClrVirtualScroll]',
|
|
@@ -4775,43 +4949,6 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.1.3", ngImpor
|
|
|
4775
4949
|
type: Input,
|
|
4776
4950
|
args: ['clrVirtualDataRange']
|
|
4777
4951
|
}] } });
|
|
4778
|
-
function createCdkVirtualScrollViewport(datagridDivElementRef, contentWrapper, changeDetectorRef, ngZone, renderer2, virtualScrollStrategy, directionality, scrollDispatcher, viewportRuler, scrollable) {
|
|
4779
|
-
const virtualScrollViewportInjector = Injector.create({
|
|
4780
|
-
parent: inject(EnvironmentInjector),
|
|
4781
|
-
providers: [
|
|
4782
|
-
{ provide: ElementRef, useValue: datagridDivElementRef },
|
|
4783
|
-
{ provide: ChangeDetectorRef, useValue: changeDetectorRef },
|
|
4784
|
-
{ provide: NgZone, useValue: ngZone },
|
|
4785
|
-
{ provide: Renderer2, useValue: renderer2 },
|
|
4786
|
-
{ provide: VIRTUAL_SCROLL_STRATEGY, useValue: virtualScrollStrategy },
|
|
4787
|
-
{ provide: Directionality, useValue: directionality },
|
|
4788
|
-
{ provide: ScrollDispatcher, useValue: scrollDispatcher },
|
|
4789
|
-
{ provide: ViewportRuler, useValue: viewportRuler },
|
|
4790
|
-
{ provide: CdkVirtualScrollable, useValue: scrollable },
|
|
4791
|
-
{ provide: CdkVirtualScrollViewport, useClass: CdkVirtualScrollViewport },
|
|
4792
|
-
],
|
|
4793
|
-
});
|
|
4794
|
-
const viewPort = virtualScrollViewportInjector.get(CdkVirtualScrollViewport);
|
|
4795
|
-
viewPort._contentWrapper = contentWrapper;
|
|
4796
|
-
return viewPort;
|
|
4797
|
-
}
|
|
4798
|
-
function createCdkVirtualForOfDirective(viewContainerRef, templateRef, iterableDiffers, virtualScrollViewport, ngZone) {
|
|
4799
|
-
const virtualScrollViewportInjector = Injector.create({
|
|
4800
|
-
parent: inject(EnvironmentInjector),
|
|
4801
|
-
providers: [{ provide: CDK_VIRTUAL_SCROLL_VIEWPORT, useValue: virtualScrollViewport }],
|
|
4802
|
-
});
|
|
4803
|
-
const cdkVirtualForInjector = Injector.create({
|
|
4804
|
-
parent: virtualScrollViewportInjector,
|
|
4805
|
-
providers: [
|
|
4806
|
-
{ provide: ViewContainerRef, useValue: viewContainerRef },
|
|
4807
|
-
{ provide: TemplateRef, useValue: templateRef },
|
|
4808
|
-
{ provide: IterableDiffers, useValue: iterableDiffers },
|
|
4809
|
-
{ provide: NgZone, useValue: ngZone },
|
|
4810
|
-
{ provide: CdkVirtualForOf, useClass: CdkVirtualForOf },
|
|
4811
|
-
],
|
|
4812
|
-
});
|
|
4813
|
-
return cdkVirtualForInjector.get(CdkVirtualForOf);
|
|
4814
|
-
}
|
|
4815
4952
|
|
|
4816
4953
|
/*
|
|
4817
4954
|
* Copyright (c) 2016-2026 Broadcom. All Rights Reserved.
|
|
@@ -4873,10 +5010,10 @@ class StateProvider {
|
|
|
4873
5010
|
}
|
|
4874
5011
|
return state;
|
|
4875
5012
|
}
|
|
4876
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.
|
|
4877
|
-
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.
|
|
5013
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: StateProvider, deps: [{ token: FiltersProvider }, { token: Sort }, { token: Page }, { token: StateDebouncer }], target: i0.ɵɵFactoryTarget.Injectable }); }
|
|
5014
|
+
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: StateProvider }); }
|
|
4878
5015
|
}
|
|
4879
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.
|
|
5016
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: StateProvider, decorators: [{
|
|
4880
5017
|
type: Injectable
|
|
4881
5018
|
}], ctorParameters: () => [{ type: FiltersProvider }, { type: Sort }, { type: Page }, { type: StateDebouncer }] });
|
|
4882
5019
|
|
|
@@ -4933,10 +5070,10 @@ class DatagridCellRenderer {
|
|
|
4933
5070
|
this.renderer.removeClass(this.el.nativeElement, STRICT_WIDTH_CLASS);
|
|
4934
5071
|
this.renderer.setStyle(this.el.nativeElement, 'width', null);
|
|
4935
5072
|
}
|
|
4936
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.
|
|
4937
|
-
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "21.
|
|
5073
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: DatagridCellRenderer, deps: [{ token: i0.ElementRef }, { token: i0.Renderer2 }, { token: DatagridRenderOrganizer }], target: i0.ɵɵFactoryTarget.Directive }); }
|
|
5074
|
+
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "21.2.25", type: DatagridCellRenderer, isStandalone: false, selector: "clr-dg-cell", ngImport: i0 }); }
|
|
4938
5075
|
}
|
|
4939
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.
|
|
5076
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: DatagridCellRenderer, decorators: [{
|
|
4940
5077
|
type: Directive,
|
|
4941
5078
|
args: [{
|
|
4942
5079
|
selector: 'clr-dg-cell',
|
|
@@ -5003,10 +5140,10 @@ class DatagridRowRenderer {
|
|
|
5003
5140
|
}
|
|
5004
5141
|
}));
|
|
5005
5142
|
}
|
|
5006
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.
|
|
5007
|
-
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "21.
|
|
5143
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: DatagridRowRenderer, deps: [{ token: ColumnsService }, { token: i0.ElementRef }], target: i0.ɵɵFactoryTarget.Directive }); }
|
|
5144
|
+
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "21.2.25", type: DatagridRowRenderer, isStandalone: false, selector: "clr-dg-row", queries: [{ propertyName: "cells", predicate: DatagridCellRenderer }], ngImport: i0 }); }
|
|
5008
5145
|
}
|
|
5009
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.
|
|
5146
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: DatagridRowRenderer, decorators: [{
|
|
5010
5147
|
type: Directive,
|
|
5011
5148
|
args: [{
|
|
5012
5149
|
selector: 'clr-dg-row',
|
|
@@ -5024,10 +5161,10 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.1.3", ngImpor
|
|
|
5024
5161
|
* The full license information can be found in LICENSE in the root directory of this project.
|
|
5025
5162
|
*/
|
|
5026
5163
|
class DatagridWillyWonka extends WillyWonka {
|
|
5027
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.
|
|
5028
|
-
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "21.
|
|
5164
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: DatagridWillyWonka, deps: null, target: i0.ɵɵFactoryTarget.Directive }); }
|
|
5165
|
+
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "21.2.25", type: DatagridWillyWonka, isStandalone: false, selector: "clr-datagrid", usesInheritance: true, ngImport: i0 }); }
|
|
5029
5166
|
}
|
|
5030
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.
|
|
5167
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: DatagridWillyWonka, decorators: [{
|
|
5031
5168
|
type: Directive,
|
|
5032
5169
|
args: [{
|
|
5033
5170
|
selector: 'clr-datagrid',
|
|
@@ -5052,10 +5189,10 @@ class ActionableOompaLoompa extends OompaLoompa {
|
|
|
5052
5189
|
get flavor() {
|
|
5053
5190
|
return this.rowActions.hasActionableRow;
|
|
5054
5191
|
}
|
|
5055
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.
|
|
5056
|
-
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "21.
|
|
5192
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: ActionableOompaLoompa, deps: [{ token: i0.ChangeDetectorRef }, { token: DatagridWillyWonka, optional: true }, { token: RowActionService }], target: i0.ɵɵFactoryTarget.Directive }); }
|
|
5193
|
+
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "21.2.25", type: ActionableOompaLoompa, isStandalone: false, selector: "clr-datagrid, clr-dg-row", usesInheritance: true, ngImport: i0 }); }
|
|
5057
5194
|
}
|
|
5058
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.
|
|
5195
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: ActionableOompaLoompa, decorators: [{
|
|
5059
5196
|
type: Directive,
|
|
5060
5197
|
args: [{
|
|
5061
5198
|
selector: 'clr-datagrid, clr-dg-row',
|
|
@@ -5082,10 +5219,10 @@ class ExpandableOompaLoompa extends OompaLoompa {
|
|
|
5082
5219
|
get flavor() {
|
|
5083
5220
|
return this.expandableCount.hasExpandableRow;
|
|
5084
5221
|
}
|
|
5085
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.
|
|
5086
|
-
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "21.
|
|
5222
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: ExpandableOompaLoompa, deps: [{ token: i0.ChangeDetectorRef }, { token: DatagridWillyWonka, optional: true }, { token: ExpandableRowsCount }], target: i0.ɵɵFactoryTarget.Directive }); }
|
|
5223
|
+
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "21.2.25", type: ExpandableOompaLoompa, isStandalone: false, selector: "clr-datagrid, clr-dg-row", usesInheritance: true, ngImport: i0 }); }
|
|
5087
5224
|
}
|
|
5088
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.
|
|
5225
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: ExpandableOompaLoompa, decorators: [{
|
|
5089
5226
|
type: Directive,
|
|
5090
5227
|
args: [{
|
|
5091
5228
|
selector: 'clr-datagrid, clr-dg-row',
|
|
@@ -5142,6 +5279,13 @@ class ClrDatagrid {
|
|
|
5142
5279
|
*/
|
|
5143
5280
|
this._subscriptions = [];
|
|
5144
5281
|
this._virtualScrollSubscriptions = [];
|
|
5282
|
+
/**
|
|
5283
|
+
* The placeholder columns we create from `fixedColumnTemplate` for the calculate pass. Unlike
|
|
5284
|
+
* the column views, which belong to their `WrappedColumn`, these are created here on every
|
|
5285
|
+
* pass, so they are ours to destroy. Detaching them from the container only unlinks them - the
|
|
5286
|
+
* views themselves would stay alive and keep the whole datagrid in memory.
|
|
5287
|
+
*/
|
|
5288
|
+
this.fixedColumnViews = [];
|
|
5145
5289
|
this.cachedRowsHeight = 0;
|
|
5146
5290
|
this.cachedContentHeight = 0;
|
|
5147
5291
|
this.resizeObserver = new ResizeObserver(entries => {
|
|
@@ -5311,6 +5455,7 @@ class ClrDatagrid {
|
|
|
5311
5455
|
this._projectedStickyColumns.detach();
|
|
5312
5456
|
}
|
|
5313
5457
|
// Remove any projected columns from the projectedCalculationColumns container
|
|
5458
|
+
this.destroyFixedColumnViews();
|
|
5314
5459
|
for (let i = this._projectedCalculationColumns.length; i > 0; i--) {
|
|
5315
5460
|
this._projectedCalculationColumns.detach();
|
|
5316
5461
|
}
|
|
@@ -5350,9 +5495,11 @@ class ClrDatagrid {
|
|
|
5350
5495
|
this.selection.selectionType !== this.SELECTION_TYPE.None,
|
|
5351
5496
|
this.expandableRows.hasExpandableRow || this.detailService.enabled,
|
|
5352
5497
|
];
|
|
5353
|
-
fixedColumnConditions
|
|
5354
|
-
.
|
|
5355
|
-
|
|
5498
|
+
fixedColumnConditions.filter(Boolean).forEach(() => {
|
|
5499
|
+
const fixedColumnView = this._fixedColumnTemplate.createEmbeddedView(null);
|
|
5500
|
+
this.fixedColumnViews.push(fixedColumnView);
|
|
5501
|
+
this._projectedCalculationColumns.insert(fixedColumnView);
|
|
5502
|
+
});
|
|
5356
5503
|
this.columns.forEach(column => {
|
|
5357
5504
|
this._projectedCalculationColumns.insert(column._view);
|
|
5358
5505
|
});
|
|
@@ -5384,10 +5531,16 @@ class ClrDatagrid {
|
|
|
5384
5531
|
this.selection.checkForChanges();
|
|
5385
5532
|
}
|
|
5386
5533
|
ngOnDestroy() {
|
|
5534
|
+
this.destroyFixedColumnViews();
|
|
5387
5535
|
this._subscriptions.forEach((sub) => sub.unsubscribe());
|
|
5388
5536
|
this._virtualScrollSubscriptions.forEach((sub) => sub.unsubscribe());
|
|
5389
5537
|
this.resizeObserver.disconnect();
|
|
5390
5538
|
this.rowControlsObserver.disconnect();
|
|
5539
|
+
// If the detail pane is left open, close it so the DetailService unregisters itself from the
|
|
5540
|
+
// root ModalStackService instead of staying referenced there after this datagrid is gone.
|
|
5541
|
+
if (this.detailService.isOpen) {
|
|
5542
|
+
this.detailService.close();
|
|
5543
|
+
}
|
|
5391
5544
|
}
|
|
5392
5545
|
toggleAllSelected($event) {
|
|
5393
5546
|
$event.preventDefault();
|
|
@@ -5425,6 +5578,16 @@ class ClrDatagrid {
|
|
|
5425
5578
|
dataChanged() {
|
|
5426
5579
|
this.items.refresh();
|
|
5427
5580
|
}
|
|
5581
|
+
destroyFixedColumnViews() {
|
|
5582
|
+
// On teardown Angular has already destroyed the views in our container by the time it runs our
|
|
5583
|
+
// `ngOnDestroy`, so only the calculate/display transition has live ones to release here.
|
|
5584
|
+
this.fixedColumnViews.forEach(view => {
|
|
5585
|
+
if (!view.destroyed) {
|
|
5586
|
+
view.destroy();
|
|
5587
|
+
}
|
|
5588
|
+
});
|
|
5589
|
+
this.fixedColumnViews = [];
|
|
5590
|
+
}
|
|
5428
5591
|
toggleVirtualScrollSubscriptions() {
|
|
5429
5592
|
const hasVirtualScroll = !!this.virtualScroll;
|
|
5430
5593
|
// the virtual scroll will handle the scrolling
|
|
@@ -5516,8 +5679,8 @@ class ClrDatagrid {
|
|
|
5516
5679
|
this.renderer.removeClass(rowsWrapper, scrollClass);
|
|
5517
5680
|
}
|
|
5518
5681
|
}
|
|
5519
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.
|
|
5520
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.
|
|
5682
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: ClrDatagrid, deps: [{ token: DatagridRenderOrganizer }, { token: Items }, { token: ExpandableRowsCount }, { token: Selection }, { token: RowActionService }, { token: StateProvider }, { token: DisplayModeService }, { token: i0.Renderer2 }, { token: DetailService }, { token: DOCUMENT }, { token: i0.ElementRef }, { token: Page }, { token: i2.ClrCommonStringsService }, { token: KeyNavigationGridController }, { token: i0.NgZone }, { token: ColumnsService }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
5683
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.25", type: ClrDatagrid, isStandalone: false, selector: "clr-datagrid", inputs: { loadingMoreItems: ["clrLoadingMoreItems", "loadingMoreItems"], clrDgSingleSelectionAriaLabel: "clrDgSingleSelectionAriaLabel", clrDgSingleActionableAriaLabel: "clrDgSingleActionableAriaLabel", clrDetailExpandableAriaLabel: "clrDetailExpandableAriaLabel", clrDgDisablePageFocus: "clrDgDisablePageFocus", customSelectAllEnabled: ["clrDgCustomSelectAllEnabled", "customSelectAllEnabled"], selectAllDisabled: ["clrDgSelectAllDisabled", "selectAllDisabled"], loading: ["clrDgLoading", "loading"], selectionType: ["clrDgSelectionType", "selectionType", selectionTypeAttribute], selected: ["clrDgSelected", "selected"], clrDgPreserveSelection: "clrDgPreserveSelection", rowSelectionMode: ["clrDgRowSelection", "rowSelectionMode"], identityFn: ["clrDgItemsIdentityFn", "identityFn"] }, outputs: { selectedChanged: "clrDgSelectedChange", refresh: "clrDgRefresh", customSelectAll: "clrDgCustomSelectAll" }, host: { properties: { "class.datagrid-host": "true", "class.datagrid-detail-open": "detailService.isOpen", "class.datagrid-detail-overlay": "isDetailOverlay", "class.datagrid-virtual-scroll": "!!virtualScroll" } }, providers: [
|
|
5521
5684
|
Selection,
|
|
5522
5685
|
Sort,
|
|
5523
5686
|
FiltersProvider,
|
|
@@ -5533,9 +5696,9 @@ class ClrDatagrid {
|
|
|
5533
5696
|
ColumnsService,
|
|
5534
5697
|
DisplayModeService,
|
|
5535
5698
|
KeyNavigationGridController,
|
|
5536
|
-
], queries: [{ propertyName: "iterator", first: true, predicate: ClrDatagridItems, descendants: true }, { propertyName: "placeholder", first: true, predicate: ClrDatagridPlaceholder, descendants: true }, { propertyName: "_virtualScroll", predicate: i0.forwardRef(() => ClrDatagridVirtualScrollDirective) }, { propertyName: "columns", predicate: ClrDatagridColumn }, { propertyName: "rows", predicate: ClrDatagridRow, emitDistinctChangesOnly: false }], viewQueries: [{ propertyName: "datagrid", first: true, predicate: ["datagrid"], descendants: true, read: ElementRef }, { propertyName: "datagridTable", first: true, predicate: ["datagridTable"], descendants: true, read: ElementRef }, { propertyName: "datagridHeader", first: true, predicate: ["datagridHeader"], descendants: true, read: ElementRef }, { propertyName: "contentWrapper", first: true, predicate: ["contentWrapper"], descendants: true, read: ElementRef, static: true }, { propertyName: "rowsWrapper", first: true, predicate: ["rowsWrapper"], descendants: true, read: ElementRef, static: true }, { propertyName: "scrollableColumns", first: true, predicate: ["scrollableColumns"], descendants: true, read: ViewContainerRef }, { propertyName: "_projectedDisplayColumns", first: true, predicate: ["projectedDisplayColumns"], descendants: true, read: ViewContainerRef }, { propertyName: "_projectedStickyColumns", first: true, predicate: ["projectedStickyColumns"], descendants: true, read: ViewContainerRef }, { propertyName: "_projectedCalculationColumns", first: true, predicate: ["projectedCalculationColumns"], descendants: true, read: ViewContainerRef }, { propertyName: "_displayedRows", first: true, predicate: ["displayedRows"], descendants: true, read: ViewContainerRef }, { propertyName: "_calculationRows", first: true, predicate: ["calculationRows"], descendants: true, read: ViewContainerRef }, { propertyName: "_fixedColumnTemplate", first: true, predicate: ["fixedColumnTemplate"], descendants: true }, { propertyName: "selectAllCheckbox", first: true, predicate: ["selectAllCheckbox"], descendants: true }, { propertyName: "rowControls", first: true, predicate: ["rowControls"], descendants: true, read: ElementRef }, { propertyName: "stickyHeaders", predicate: ["stickyHeader"], descendants: true }], ngImport: i0, template: "<!--\n ~ Copyright (c) 2016-2026 Broadcom. All Rights Reserved.\n ~ The term \"Broadcom\" refers to Broadcom Inc. and/or its subsidiaries.\n ~ This software is released under MIT license.\n ~ The full license information can be found in LICENSE in the root directory of this project.\n -->\n\n<ng-content select=\"clr-dg-action-bar\"></ng-content>\n<div class=\"datagrid-outer-wrapper\">\n <div class=\"datagrid-inner-wrapper\">\n <div class=\"datagrid\" #datagrid [attr.aria-hidden]=\"detailService.isOpen ? true : null\">\n <div class=\"datagrid-table-wrapper\">\n <div role=\"grid\" class=\"datagrid-table\" tabindex=\"-1\" #datagridTable>\n <div role=\"rowgroup\" class=\"datagrid-header\" #datagridHeader>\n <div role=\"row\" class=\"datagrid-row\">\n <div class=\"datagrid-row-master datagrid-row-flex\">\n <div class=\"datagrid-row-sticky\" #rowControls>\n <!--header for datagrid where you can select multiple rows -->\n @if (selection.selectionType === SELECTION_TYPE.Multi) {\n <div\n #stickyHeader\n role=\"columnheader\"\n class=\"datagrid-column datagrid-select datagrid-fixed-column\"\n (keydown.space)=\"toggleAllSelected($event)\"\n >\n @if (!virtualScroll || customSelectAllEnabled) {\n <div class=\"clr-checkbox-wrapper\">\n <!-- We need to move focus and space-key handling to the parent because of keyboard arrow key navigation,\n which is not able to transfer focus directly on the input when focused with the tab key -->\n <input\n #selectAllCheckbox\n type=\"checkbox\"\n [id]=\"selectAllId\"\n [(ngModel)]=\"allSelected\"\n [attr.aria-label]=\"commonStrings.keys.selectAll\"\n tabindex=\"-1\"\n [attr.disabled]=\"selectAllDisabled ? true : null\"\n />\n <!-- Usage of class clr-col-null here prevents clr-col-* classes from being added when a datagrid is wrapped inside clrForm -->\n <label [for]=\"selectAllId\" class=\"clr-control-label clr-col-null\">\n <span class=\"clr-sr-only\">{{commonStrings.keys.selectAll}}</span>\n </label>\n </div>\n }\n <div class=\"datagrid-column-separator\"></div>\n </div>\n }\n <!-- header for datagrid where you can select one row only -->\n @if (selection.selectionType === SELECTION_TYPE.Single) {\n <div #stickyHeader role=\"columnheader\" class=\"datagrid-column datagrid-select datagrid-fixed-column\">\n <div class=\"clr-sr-only\">{{clrDgSingleSelectionAriaLabel}}</div>\n <div class=\"datagrid-column-separator\"></div>\n </div>\n }\n <!-- header for single row action; only displayType if we have at least one actionable row in datagrid -->\n @if (rowActionService.hasActionableRow) {\n <div\n #stickyHeader\n role=\"columnheader\"\n class=\"datagrid-column datagrid-row-actions datagrid-fixed-column\"\n >\n <div class=\"clr-sr-only\">{{clrDgSingleActionableAriaLabel}}</div>\n <div class=\"datagrid-column-separator\"></div>\n </div>\n }\n <!-- header for carets; only displayType if we have at least one expandable row in datagrid -->\n @if (expandableRows.hasExpandableRow || detailService.enabled) {\n <div\n #stickyHeader\n role=\"columnheader\"\n class=\"datagrid-column datagrid-expandable-caret datagrid-fixed-column\"\n >\n <div class=\"clr-sr-only\">{{clrDetailExpandableAriaLabel}}</div>\n <div class=\"datagrid-column-separator\"></div>\n </div>\n }\n </div>\n <div class=\"datagrid-row-scrollable\">\n <div class=\"datagrid-pinned-cells\">\n <ng-container #projectedStickyColumns></ng-container>\n </div>\n <ng-container #projectedDisplayColumns></ng-container>\n </div>\n @if (virtualScroll) {\n <div class=\"datagrid-row-sticky datagrid-row-sticky-scroll\">\n <div class=\"datagrid-column\"></div>\n </div>\n }\n </div>\n </div>\n </div>\n\n <div class=\"datagrid-content\" [class.datagrid-content-virtual]=\"virtualScroll\" #contentWrapper>\n @if (virtualScroll) {\n <div class=\"datagrid-content-virtual-spacer\" [style.height]=\"virtualScroll?.totalContentHeight\"></div>\n }\n <div role=\"presentation\" #rowsWrapper class=\"datagrid-rows\">\n @if (loadingMoreItems) {\n <clr-dg-row class=\"datagrid-row-loading\">\n <clr-dg-cell>\n <clr-spinner clrMedium></clr-spinner>\n <span>{{ commonStrings.keys.loading }}</span>\n </clr-dg-cell>\n </clr-dg-row>\n }\n\n <ng-container #displayedRows></ng-container>\n\n @if (loadingMoreItems) {\n <clr-dg-row class=\"datagrid-row-loading\">\n <clr-dg-cell>\n <clr-spinner clrMedium></clr-spinner>\n <span>{{ commonStrings.keys.loading }}</span>\n </clr-dg-cell>\n </clr-dg-row>\n }\n\n <!-- Custom placeholder overrides the default empty one -->\n <ng-content select=\"clr-dg-placeholder\"></ng-content>\n @if (!placeholder) {\n <clr-dg-placeholder></clr-dg-placeholder>\n }\n </div>\n </div>\n </div>\n </div>\n </div>\n <ng-content select=\"clr-dg-footer\"></ng-content>\n @if (loading) {\n <div class=\"datagrid-spinner\">\n <clr-spinner clrMedium>Loading</clr-spinner>\n </div>\n }\n </div>\n <ng-content select=\"[clrIfDetail],clr-dg-detail\"></ng-content>\n</div>\n\n<div class=\"datagrid-calculation-table\">\n <div class=\"datagrid-calculation-header\">\n <ng-container #projectedCalculationColumns></ng-container>\n </div>\n <ng-container #calculationRows></ng-container>\n</div>\n\n<ng-template #fixedColumnTemplate>\n <div class=\"datagrid-column datagrid-fixed-column\"></div>\n</ng-template>\n", dependencies: [{ kind: "directive", type: i4.ClrControlLabel, selector: "label", inputs: ["id", "for"] }, { kind: "directive", type: i14.CheckboxControlValueAccessor, selector: "input[type=checkbox][formControlName],input[type=checkbox][formControl],input[type=checkbox][ngModel]" }, { kind: "directive", type: i14.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i14.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "component", type: i15.ClrSpinner, selector: "clr-spinner", inputs: ["clrInline", "clrInverse", "clrSmall", "clrMedium"] }, { kind: "component", type: ClrDatagridCell, selector: "clr-dg-cell" }, { kind: "component", type: ClrDatagridPlaceholder, selector: "clr-dg-placeholder" }, { kind: "component", type: ClrDatagridRow, selector: "clr-dg-row", inputs: ["clrDgDetailDisabled", "clrDgDetailHidden", "clrDgSkeletonLoading", "clrDgItem", "clrDgSelectable", "clrDgSelected", "clrDgExpanded", "clrDgDetailOpenLabel", "clrDgDetailCloseLabel", "clrDgRowSelectionLabel"], outputs: ["clrDgSelectedChange", "clrDgExpandedChange"] }, { kind: "directive", type: ClrDatagridSelectionCellDirective, selector: ".datagrid-select" }, { kind: "directive", type: DatagridCellRenderer, selector: "clr-dg-cell" }, { kind: "directive", type: DatagridRowRenderer, selector: "clr-dg-row" }, { kind: "directive", type: ActionableOompaLoompa, selector: "clr-datagrid, clr-dg-row" }, { kind: "directive", type: ExpandableOompaLoompa, selector: "clr-datagrid, clr-dg-row" }] }); }
|
|
5699
|
+
], queries: [{ propertyName: "iterator", first: true, predicate: ClrDatagridItems, descendants: true }, { propertyName: "placeholder", first: true, predicate: ClrDatagridPlaceholder, descendants: true }, { propertyName: "_virtualScroll", predicate: i0.forwardRef(() => ClrDatagridVirtualScrollDirective) }, { propertyName: "columns", predicate: ClrDatagridColumn }, { propertyName: "rows", predicate: ClrDatagridRow, emitDistinctChangesOnly: false }], viewQueries: [{ propertyName: "datagrid", first: true, predicate: ["datagrid"], descendants: true, read: ElementRef }, { propertyName: "datagridTable", first: true, predicate: ["datagridTable"], descendants: true, read: ElementRef }, { propertyName: "datagridHeader", first: true, predicate: ["datagridHeader"], descendants: true, read: ElementRef }, { propertyName: "contentWrapper", first: true, predicate: ["contentWrapper"], descendants: true, read: ElementRef, static: true }, { propertyName: "rowsWrapper", first: true, predicate: ["rowsWrapper"], descendants: true, read: ElementRef, static: true }, { propertyName: "scrollableColumns", first: true, predicate: ["scrollableColumns"], descendants: true, read: ViewContainerRef }, { propertyName: "_projectedDisplayColumns", first: true, predicate: ["projectedDisplayColumns"], descendants: true, read: ViewContainerRef }, { propertyName: "_projectedStickyColumns", first: true, predicate: ["projectedStickyColumns"], descendants: true, read: ViewContainerRef }, { propertyName: "_projectedCalculationColumns", first: true, predicate: ["projectedCalculationColumns"], descendants: true, read: ViewContainerRef }, { propertyName: "_displayedRows", first: true, predicate: ["displayedRows"], descendants: true, read: ViewContainerRef }, { propertyName: "_calculationRows", first: true, predicate: ["calculationRows"], descendants: true, read: ViewContainerRef }, { propertyName: "_fixedColumnTemplate", first: true, predicate: ["fixedColumnTemplate"], descendants: true }, { propertyName: "selectAllCheckbox", first: true, predicate: ["selectAllCheckbox"], descendants: true }, { propertyName: "rowControls", first: true, predicate: ["rowControls"], descendants: true, read: ElementRef }, { propertyName: "stickyHeaders", predicate: ["stickyHeader"], descendants: true }], ngImport: i0, template: "<!--\n ~ Copyright (c) 2016-2026 Broadcom. All Rights Reserved.\n ~ The term \"Broadcom\" refers to Broadcom Inc. and/or its subsidiaries.\n ~ This software is released under MIT license.\n ~ The full license information can be found in LICENSE in the root directory of this project.\n -->\n\n<ng-content select=\"clr-dg-action-bar\"></ng-content>\n<div class=\"datagrid-outer-wrapper\">\n <div class=\"datagrid-inner-wrapper\">\n <div class=\"datagrid\" #datagrid [attr.aria-hidden]=\"detailService.isOpen ? true : null\">\n <div class=\"datagrid-table-wrapper\">\n <div role=\"grid\" class=\"datagrid-table\" tabindex=\"-1\" #datagridTable>\n <div role=\"rowgroup\" class=\"datagrid-header\" #datagridHeader>\n <div role=\"row\" class=\"datagrid-row\">\n <div class=\"datagrid-row-master datagrid-row-flex\">\n <div class=\"datagrid-row-sticky\" #rowControls>\n <!--header for datagrid where you can select multiple rows -->\n @if (selection.selectionType === SELECTION_TYPE.Multi) {\n <div\n #stickyHeader\n role=\"columnheader\"\n class=\"datagrid-column datagrid-select datagrid-fixed-column\"\n (keydown.space)=\"toggleAllSelected($event)\"\n >\n @if (!virtualScroll || customSelectAllEnabled) {\n <div class=\"clr-checkbox-wrapper\">\n <!-- We need to move focus and space-key handling to the parent because of keyboard arrow key navigation,\n which is not able to transfer focus directly on the input when focused with the tab key -->\n <input\n #selectAllCheckbox\n type=\"checkbox\"\n [id]=\"selectAllId\"\n [(ngModel)]=\"allSelected\"\n [attr.aria-label]=\"commonStrings.keys.selectAll\"\n tabindex=\"-1\"\n [attr.disabled]=\"selectAllDisabled ? true : null\"\n />\n <!-- Usage of class clr-col-null here prevents clr-col-* classes from being added when a datagrid is wrapped inside clrForm -->\n <label [for]=\"selectAllId\" class=\"clr-control-label clr-col-null\">\n <span class=\"clr-sr-only\">{{commonStrings.keys.selectAll}}</span>\n </label>\n </div>\n }\n <div class=\"datagrid-column-separator\"></div>\n </div>\n }\n <!-- header for datagrid where you can select one row only -->\n @if (selection.selectionType === SELECTION_TYPE.Single) {\n <div #stickyHeader role=\"columnheader\" class=\"datagrid-column datagrid-select datagrid-fixed-column\">\n <div class=\"clr-sr-only\">{{clrDgSingleSelectionAriaLabel}}</div>\n <div class=\"datagrid-column-separator\"></div>\n </div>\n }\n <!-- header for single row action; only displayType if we have at least one actionable row in datagrid -->\n @if (rowActionService.hasActionableRow) {\n <div\n #stickyHeader\n role=\"columnheader\"\n class=\"datagrid-column datagrid-row-actions datagrid-fixed-column\"\n >\n <div class=\"clr-sr-only\">{{clrDgSingleActionableAriaLabel}}</div>\n <div class=\"datagrid-column-separator\"></div>\n </div>\n }\n <!-- header for carets; only displayType if we have at least one expandable row in datagrid -->\n @if (expandableRows.hasExpandableRow || detailService.enabled) {\n <div\n #stickyHeader\n role=\"columnheader\"\n class=\"datagrid-column datagrid-expandable-caret datagrid-fixed-column\"\n >\n <div class=\"clr-sr-only\">{{clrDetailExpandableAriaLabel}}</div>\n <div class=\"datagrid-column-separator\"></div>\n </div>\n }\n </div>\n <div class=\"datagrid-row-scrollable\">\n <div class=\"datagrid-pinned-cells\">\n <ng-container #projectedStickyColumns></ng-container>\n </div>\n <ng-container #projectedDisplayColumns></ng-container>\n </div>\n @if (virtualScroll) {\n <div class=\"datagrid-row-sticky datagrid-row-sticky-scroll\">\n <div class=\"datagrid-column\"></div>\n </div>\n }\n </div>\n </div>\n </div>\n\n <div class=\"datagrid-content\" [class.datagrid-content-virtual]=\"virtualScroll\" #contentWrapper>\n @if (virtualScroll) {\n <div class=\"datagrid-content-virtual-spacer\" [style.height]=\"virtualScroll?.totalContentHeight\"></div>\n }\n <div role=\"presentation\" #rowsWrapper class=\"datagrid-rows\">\n @if (loadingMoreItems) {\n <clr-dg-row class=\"datagrid-row-loading\">\n <clr-dg-cell>\n <clr-spinner clrMedium></clr-spinner>\n <span>{{ commonStrings.keys.loading }}</span>\n </clr-dg-cell>\n </clr-dg-row>\n }\n\n <ng-container #displayedRows></ng-container>\n\n @if (loadingMoreItems) {\n <clr-dg-row class=\"datagrid-row-loading\">\n <clr-dg-cell>\n <clr-spinner clrMedium></clr-spinner>\n <span>{{ commonStrings.keys.loading }}</span>\n </clr-dg-cell>\n </clr-dg-row>\n }\n\n <!-- Custom placeholder overrides the default empty one -->\n <ng-content select=\"clr-dg-placeholder\"></ng-content>\n @if (!placeholder) {\n <clr-dg-placeholder></clr-dg-placeholder>\n }\n </div>\n </div>\n </div>\n </div>\n </div>\n <ng-content select=\"clr-dg-footer\"></ng-content>\n @if (loading) {\n <div class=\"datagrid-spinner\">\n <clr-spinner clrMedium>Loading</clr-spinner>\n </div>\n }\n </div>\n <ng-content select=\"[clrIfDetail],clr-dg-detail\"></ng-content>\n</div>\n\n<div class=\"datagrid-calculation-table\">\n <div class=\"datagrid-calculation-header\">\n <ng-container #projectedCalculationColumns></ng-container>\n </div>\n <ng-container #calculationRows></ng-container>\n</div>\n\n<ng-template #fixedColumnTemplate>\n <div class=\"datagrid-column datagrid-fixed-column\"></div>\n</ng-template>\n", dependencies: [{ kind: "directive", type: i4$1.ClrControlLabel, selector: "label", inputs: ["id", "for"] }, { kind: "directive", type: i14.CheckboxControlValueAccessor, selector: "input[type=checkbox][formControlName],input[type=checkbox][formControl],input[type=checkbox][ngModel]" }, { kind: "directive", type: i14.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i14.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "component", type: i15.ClrSpinner, selector: "clr-spinner", inputs: ["clrInline", "clrInverse", "clrSmall", "clrMedium"] }, { kind: "component", type: ClrDatagridCell, selector: "clr-dg-cell" }, { kind: "component", type: ClrDatagridPlaceholder, selector: "clr-dg-placeholder" }, { kind: "component", type: ClrDatagridRow, selector: "clr-dg-row", inputs: ["clrDgDetailDisabled", "clrDgDetailHidden", "clrDgSkeletonLoading", "clrDgItem", "clrDgSelectable", "clrDgSelected", "clrDgExpanded", "clrDgDetailOpenLabel", "clrDgDetailCloseLabel", "clrDgRowSelectionLabel"], outputs: ["clrDgSelectedChange", "clrDgExpandedChange"] }, { kind: "directive", type: ClrDatagridSelectionCellDirective, selector: ".datagrid-select" }, { kind: "directive", type: DatagridCellRenderer, selector: "clr-dg-cell" }, { kind: "directive", type: DatagridRowRenderer, selector: "clr-dg-row" }, { kind: "directive", type: ActionableOompaLoompa, selector: "clr-datagrid, clr-dg-row" }, { kind: "directive", type: ExpandableOompaLoompa, selector: "clr-datagrid, clr-dg-row" }] }); }
|
|
5537
5700
|
}
|
|
5538
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.
|
|
5701
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: ClrDatagrid, decorators: [{
|
|
5539
5702
|
type: Component,
|
|
5540
5703
|
args: [{ selector: 'clr-datagrid', providers: [
|
|
5541
5704
|
Selection,
|
|
@@ -5674,10 +5837,10 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.1.3", ngImpor
|
|
|
5674
5837
|
* The full license information can be found in LICENSE in the root directory of this project.
|
|
5675
5838
|
*/
|
|
5676
5839
|
class ClrDatagridActionBar {
|
|
5677
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.
|
|
5678
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "21.
|
|
5840
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: ClrDatagridActionBar, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
5841
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "21.2.25", type: ClrDatagridActionBar, isStandalone: false, selector: "clr-dg-action-bar", host: { properties: { "class.datagrid-action-bar": "true" } }, ngImport: i0, template: `<ng-content></ng-content>`, isInline: true }); }
|
|
5679
5842
|
}
|
|
5680
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.
|
|
5843
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: ClrDatagridActionBar, decorators: [{
|
|
5681
5844
|
type: Component,
|
|
5682
5845
|
args: [{
|
|
5683
5846
|
selector: 'clr-dg-action-bar',
|
|
@@ -5748,8 +5911,8 @@ class ClrDatagridActionOverflow {
|
|
|
5748
5911
|
}
|
|
5749
5912
|
}
|
|
5750
5913
|
}
|
|
5751
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.
|
|
5752
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "21.
|
|
5914
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: ClrDatagridActionOverflow, deps: [{ token: RowActionService }, { token: i2.ClrCommonStringsService }, { token: PLATFORM_ID }, { token: i3.ClrPopoverService }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
5915
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "21.2.25", type: ClrDatagridActionOverflow, isStandalone: false, selector: "clr-dg-action-overflow", inputs: { buttonLabel: ["clrDgActionOverflowButtonLabel", "buttonLabel"], open: ["clrDgActionOverflowOpen", "open"] }, outputs: { openChange: "clrDgActionOverflowOpenChange" }, viewQueries: [{ propertyName: "keyFocus", first: true, predicate: ClrKeyFocus, descendants: true }], hostDirectives: [{ directive: i3.ClrPopoverHostDirective }], ngImport: i0, template: `
|
|
5753
5916
|
<button
|
|
5754
5917
|
tabindex="-1"
|
|
5755
5918
|
class="datagrid-action-toggle"
|
|
@@ -5785,9 +5948,9 @@ class ClrDatagridActionOverflow {
|
|
|
5785
5948
|
>
|
|
5786
5949
|
<ng-content></ng-content>
|
|
5787
5950
|
</div>
|
|
5788
|
-
`, isInline: true, dependencies: [{ kind: "directive", type: i2.CdkTrapFocusModule_CdkTrapFocus, selector: "[cdkTrapFocus]" }, { kind: "component", type:
|
|
5951
|
+
`, isInline: true, dependencies: [{ kind: "directive", type: i2.CdkTrapFocusModule_CdkTrapFocus, selector: "[cdkTrapFocus]" }, { kind: "component", type: i4.ClrIcon, selector: "clr-icon, cds-icon", inputs: ["shape", "size", "direction", "flip", "solid", "status", "inverse", "badge", "innerOffset"] }, { kind: "directive", type: i3.ClrPopoverOrigin, selector: "[clrPopoverOrigin]" }, { kind: "directive", type: i3.ClrPopoverOpenCloseButton, selector: "[clrPopoverOpenCloseButton]", outputs: ["clrPopoverOpenCloseChange"] }, { kind: "directive", type: i3.ClrPopoverContent, selector: "[clrPopoverContent]", inputs: ["clrPopoverContent", "clrPopoverContentAt", "clrPopoverContentAvailablePositions", "clrPopoverContentType", "clrPopoverContentOutsideClickToClose", "clrPopoverContentScrollToClose", "clrPopoverContentOrigin"] }, { kind: "component", type: i2.ClrKeyFocus, selector: "[clrKeyFocus]", inputs: ["clrDirection", "clrFocusOnLoad", "clrKeyFocus"], outputs: ["clrFocusChange"] }] }); }
|
|
5789
5952
|
}
|
|
5790
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.
|
|
5953
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: ClrDatagridActionOverflow, decorators: [{
|
|
5791
5954
|
type: Component,
|
|
5792
5955
|
args: [{
|
|
5793
5956
|
selector: 'clr-dg-action-overflow',
|
|
@@ -5848,6 +6011,591 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.1.3", ngImpor
|
|
|
5848
6011
|
args: ['clrDgActionOverflowOpen']
|
|
5849
6012
|
}] } });
|
|
5850
6013
|
|
|
6014
|
+
/*
|
|
6015
|
+
* Copyright (c) 2016-2026 Broadcom. All Rights Reserved.
|
|
6016
|
+
* The term "Broadcom" refers to Broadcom Inc. and/or its subsidiaries.
|
|
6017
|
+
* This software is released under MIT license.
|
|
6018
|
+
* The full license information can be found in LICENSE in the root directory of this project.
|
|
6019
|
+
*/
|
|
6020
|
+
/**
|
|
6021
|
+
* The focus handler of the `clr-dg-column-actions` menu, with the items projected into the menu
|
|
6022
|
+
* appended to the ones it declares. ClrDropdownMenu only hands over its own content query, which
|
|
6023
|
+
* cannot see projected items, and it hands it over again whenever that query changes - so the
|
|
6024
|
+
* projected ones are added here, where every one of those hand-overs passes through.
|
|
6025
|
+
*/
|
|
6026
|
+
class ColumnActionsFocusHandler extends DropdownFocusHandler {
|
|
6027
|
+
constructor() {
|
|
6028
|
+
super(...arguments);
|
|
6029
|
+
this.ownItems = [];
|
|
6030
|
+
this.projectedItems = [];
|
|
6031
|
+
}
|
|
6032
|
+
addChildren(children) {
|
|
6033
|
+
this.ownItems = children;
|
|
6034
|
+
super.addChildren([...children, ...this.projectedItems]);
|
|
6035
|
+
}
|
|
6036
|
+
// The menu resets its children when it closes, and the items it declared go with it.
|
|
6037
|
+
resetChildren() {
|
|
6038
|
+
this.ownItems = [];
|
|
6039
|
+
super.resetChildren();
|
|
6040
|
+
}
|
|
6041
|
+
setProjectedItems(items) {
|
|
6042
|
+
this.projectedItems = items;
|
|
6043
|
+
this.addChildren(this.ownItems);
|
|
6044
|
+
}
|
|
6045
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: ColumnActionsFocusHandler, deps: null, target: i0.ɵɵFactoryTarget.Injectable }); }
|
|
6046
|
+
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: ColumnActionsFocusHandler }); }
|
|
6047
|
+
}
|
|
6048
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: ColumnActionsFocusHandler, decorators: [{
|
|
6049
|
+
type: Injectable
|
|
6050
|
+
}] });
|
|
6051
|
+
|
|
6052
|
+
/*
|
|
6053
|
+
* Copyright (c) 2016-2026 Broadcom. All Rights Reserved.
|
|
6054
|
+
* The term "Broadcom" refers to Broadcom Inc. and/or its subsidiaries.
|
|
6055
|
+
* This software is released under MIT license.
|
|
6056
|
+
* The full license information can be found in LICENSE in the root directory of this project.
|
|
6057
|
+
*/
|
|
6058
|
+
/**
|
|
6059
|
+
* Groups the actions of a single column behind one menu in the column header. It only gathers
|
|
6060
|
+
* controls that already exist on the column - the behavior itself stays on `ClrDatagridColumn`,
|
|
6061
|
+
* so the menu and the header controls can never drift apart.
|
|
6062
|
+
*
|
|
6063
|
+
* Each item is rendered only when the column can actually perform it, so the menu never offers a
|
|
6064
|
+
* dead option - that covers both what the column can never do, such as sorting when it is not
|
|
6065
|
+
* sortable, and what it cannot do right now, such as clearing a sort while nothing is sorted.
|
|
6066
|
+
* Anything projected into the component is appended after the built-in items.
|
|
6067
|
+
*
|
|
6068
|
+
* A column that has a filter gets a filter action automatically, and the filter drops its own toggle
|
|
6069
|
+
* for as long as this menu is present - the header keeps one control per column rather than two. The
|
|
6070
|
+
* trigger also takes over showing that the column is filtered, which the toggle used to do.
|
|
6071
|
+
* `clrDgKeepFilterInHeader` opts back into the toggle, and then the menu drops the filter action in
|
|
6072
|
+
* exchange: a column offers one way to reach its filter, never both at once.
|
|
6073
|
+
*
|
|
6074
|
+
* Projected items can be `clrDgColumnAction`s, plain `clrDropdownItem`s, or a nested `clr-dropdown`.
|
|
6075
|
+
* They join the arrow key order after the built-in items as long as they are projected directly -
|
|
6076
|
+
* an item wrapped in an element of its own is not found. A nested dropdown's own items stay in its
|
|
6077
|
+
* own menu.
|
|
6078
|
+
*
|
|
6079
|
+
* The component is the dropdown itself rather than wrapping one, so that a projected item can reach
|
|
6080
|
+
* it: injection resolves from where a node is declared, and an item declared outside this component
|
|
6081
|
+
* would sit outside the injector of any `clr-dropdown` in its template.
|
|
6082
|
+
*/
|
|
6083
|
+
class ClrDatagridColumnActions extends ClrDropdown {
|
|
6084
|
+
constructor(column, commonStrings, columnActions,
|
|
6085
|
+
// The column's own popover service, shared with its filter. This component brings its own for
|
|
6086
|
+
// the menu, so the menu and the filter never fight over one overlay - which is also why this one
|
|
6087
|
+
// has to be resolved from the column rather than from here.
|
|
6088
|
+
columnPopover, changeDetectorRef, injector, filters, parent, popoverService, focusHandler, dropdownService) {
|
|
6089
|
+
super(parent, popoverService, focusHandler, changeDetectorRef, dropdownService);
|
|
6090
|
+
this.column = column;
|
|
6091
|
+
this.commonStrings = commonStrings;
|
|
6092
|
+
this.columnActions = columnActions;
|
|
6093
|
+
this.columnPopover = columnPopover;
|
|
6094
|
+
this.changeDetectorRef = changeDetectorRef;
|
|
6095
|
+
this.injector = injector;
|
|
6096
|
+
this.filters = filters;
|
|
6097
|
+
// Exposed so the template can compare against the enum.
|
|
6098
|
+
this.ClrDatagridSortOrder = ClrDatagridSortOrder;
|
|
6099
|
+
this._keepFilterInHeader = false;
|
|
6100
|
+
// Named for this component rather than inherited: ClrDropdown keeps its own private list.
|
|
6101
|
+
this.subs = [];
|
|
6102
|
+
this.columnActionsFocusHandler = inject(ColumnActionsFocusHandler);
|
|
6103
|
+
this.isMenuClosable = false;
|
|
6104
|
+
// Tells the filter to drop its own toggle - from here on this menu is the only way to open it,
|
|
6105
|
+
// unless clrDgKeepFilterInHeader asked to keep both. Reading the backing field rather than the
|
|
6106
|
+
// getter covers the default: Angular only invokes the setter above when the input is actually
|
|
6107
|
+
// bound, and by then the field initializer has already run.
|
|
6108
|
+
columnActions.filterInHeader.set(this._keepFilterInHeader);
|
|
6109
|
+
// Tells the column to drop its pin toggle, since Pin Column is offered here instead.
|
|
6110
|
+
columnActions.menuPresent.set(true);
|
|
6111
|
+
}
|
|
6112
|
+
/**
|
|
6113
|
+
* Keeps the filter's own toggle in the column header instead of moving it into this menu, and the
|
|
6114
|
+
* menu drops its filter action in exchange - a column offers one way to reach its filter at a
|
|
6115
|
+
* time, never two.
|
|
6116
|
+
*/
|
|
6117
|
+
get keepFilterInHeader() {
|
|
6118
|
+
return this._keepFilterInHeader;
|
|
6119
|
+
}
|
|
6120
|
+
set keepFilterInHeader(value) {
|
|
6121
|
+
this._keepFilterInHeader = value;
|
|
6122
|
+
this.columnActions.filterInHeader.set(value);
|
|
6123
|
+
}
|
|
6124
|
+
/**
|
|
6125
|
+
* The menu is a live view of the column, so the label has to be read at render time rather than
|
|
6126
|
+
* cached - the column title can change, and so can the sort state it reports.
|
|
6127
|
+
*/
|
|
6128
|
+
get triggerLabel() {
|
|
6129
|
+
const title = this.column.titleContainer?.nativeElement.textContent.trim();
|
|
6130
|
+
return title
|
|
6131
|
+
? this.commonStrings.parse(this.commonStrings.keys.datagridColumnActionsAriaLabel, { COLUMN: title })
|
|
6132
|
+
: this.commonStrings.keys.columnActions;
|
|
6133
|
+
}
|
|
6134
|
+
get sortOrder() {
|
|
6135
|
+
return this.column.sortOrder;
|
|
6136
|
+
}
|
|
6137
|
+
get canClearSort() {
|
|
6138
|
+
return this.sortOrder !== ClrDatagridSortOrder.UNSORTED && !this.column.disableUnsort;
|
|
6139
|
+
}
|
|
6140
|
+
get hasFilter() {
|
|
6141
|
+
return !!this.columnActions.filter();
|
|
6142
|
+
}
|
|
6143
|
+
/**
|
|
6144
|
+
* Hiding the filter toggle also hides the only sign that a column is filtered, so the trigger and
|
|
6145
|
+
* the filter action carry that state instead.
|
|
6146
|
+
*/
|
|
6147
|
+
get filterActive() {
|
|
6148
|
+
return !!this.columnActions.filter()?.active && !this.keepFilterInHeader;
|
|
6149
|
+
}
|
|
6150
|
+
/**
|
|
6151
|
+
* Whether the filter this menu opens is open, for the filter action to report the same way the
|
|
6152
|
+
* toggle it replaced did. Read from the column's popover service rather than from the filter,
|
|
6153
|
+
* because that service is what the action opens.
|
|
6154
|
+
*/
|
|
6155
|
+
get filterOpen() {
|
|
6156
|
+
return this.columnPopover.open;
|
|
6157
|
+
}
|
|
6158
|
+
/**
|
|
6159
|
+
* The popover the filter action opens, so it can point at what it controls - again the same thing
|
|
6160
|
+
* the replaced toggle pointed at.
|
|
6161
|
+
*/
|
|
6162
|
+
get filterPopoverId() {
|
|
6163
|
+
return this.columnActions.filter()?.popoverId ?? null;
|
|
6164
|
+
}
|
|
6165
|
+
/**
|
|
6166
|
+
* The items projected into the menu. The menu's own content query cannot see them, so they are
|
|
6167
|
+
* handed to the focus handler from here.
|
|
6168
|
+
*
|
|
6169
|
+
* Only direct children are queried, not descendants: a nested `clr-dropdown` is one item here - its
|
|
6170
|
+
* focus handler - and the items inside it belong to its own menu, not to this one.
|
|
6171
|
+
*/
|
|
6172
|
+
set projectedItems(items) {
|
|
6173
|
+
this.projectedItemsSubscription?.unsubscribe();
|
|
6174
|
+
this.projectedItemsSubscription = items.changes.subscribe(() => this.columnActionsFocusHandler.setProjectedItems(items.toArray()));
|
|
6175
|
+
this.columnActionsFocusHandler.setProjectedItems(items.toArray());
|
|
6176
|
+
}
|
|
6177
|
+
set menuPopoverContent(popoverContent) {
|
|
6178
|
+
this._menuPopoverContent = popoverContent;
|
|
6179
|
+
// A dropdown menu closes on scroll by default. This one stays open so that pinning or
|
|
6180
|
+
// reordering a column - which can itself move the page under the menu - does not also close it.
|
|
6181
|
+
if (popoverContent) {
|
|
6182
|
+
popoverContent.scrollToClose = false;
|
|
6183
|
+
}
|
|
6184
|
+
}
|
|
6185
|
+
ngAfterViewInit() {
|
|
6186
|
+
// The trigger and the filter action show whether the column is filtered, and this component is
|
|
6187
|
+
// OnPush, so it has to be told when a filter value changes.
|
|
6188
|
+
if (this.filters) {
|
|
6189
|
+
this.subs.push(this.filters.change.subscribe(() => this.changeDetectorRef.markForCheck()));
|
|
6190
|
+
}
|
|
6191
|
+
// Same for the filter action reporting whether the filter is open: opening it goes through this
|
|
6192
|
+
// template and refreshes the view on its own, but closing it does not - that is an outside click
|
|
6193
|
+
// or an escape key handled by the overlay, and the item would be left announcing itself expanded.
|
|
6194
|
+
this.subs.push(this.columnPopover.openChange.subscribe(open => {
|
|
6195
|
+
this.changeDetectorRef.markForCheck();
|
|
6196
|
+
// openFilter() links the filter's popover to this menu's so they scroll together.
|
|
6197
|
+
// Clearing it here keeps the link scoped to one filter opening.
|
|
6198
|
+
if (!open) {
|
|
6199
|
+
this.columnPopover.parent = null;
|
|
6200
|
+
}
|
|
6201
|
+
}));
|
|
6202
|
+
}
|
|
6203
|
+
ngOnDestroy() {
|
|
6204
|
+
super.ngOnDestroy();
|
|
6205
|
+
this.subs.forEach(sub => sub.unsubscribe());
|
|
6206
|
+
this.projectedItemsSubscription?.unsubscribe();
|
|
6207
|
+
// Hands the filter and the pin their own toggles back, in case the menu is removed while the
|
|
6208
|
+
// column stays.
|
|
6209
|
+
this.columnActions.filterInHeader.set(true);
|
|
6210
|
+
this.columnActions.menuPresent.set(false);
|
|
6211
|
+
// doesn't really matter who the current column popover parent is. The original value is null returning it to that.
|
|
6212
|
+
this.columnPopover.parent = null;
|
|
6213
|
+
}
|
|
6214
|
+
/**
|
|
6215
|
+
* Returns focus to the trigger before closing, the same order `clrDropdownItem` uses - moving focus
|
|
6216
|
+
* first means it lands correctly even when the action opens a modal.
|
|
6217
|
+
*/
|
|
6218
|
+
closeMenu() {
|
|
6219
|
+
this.focusHandler.focus();
|
|
6220
|
+
this.popoverService.open = false;
|
|
6221
|
+
}
|
|
6222
|
+
/**
|
|
6223
|
+
* Re-anchors the open menu to the trigger, for an action that moves the column it belongs to
|
|
6224
|
+
* instead of closing the menu behind it.
|
|
6225
|
+
*
|
|
6226
|
+
* Deferred to after the next render rather than run straight away, because the action that asked
|
|
6227
|
+
* for this has only just been clicked - the column is relocated by the change detection that
|
|
6228
|
+
* follows, so measuring the trigger now would re-anchor the menu to where it already is.
|
|
6229
|
+
*/
|
|
6230
|
+
repositionMenu() {
|
|
6231
|
+
afterNextRender(() => this.popoverService.updatePosition(), { injector: this.injector });
|
|
6232
|
+
}
|
|
6233
|
+
/**
|
|
6234
|
+
* Moves focus to one of the projected actions, keeping the menu's keyboard handling in step with
|
|
6235
|
+
* it.
|
|
6236
|
+
*
|
|
6237
|
+
* Called by `clrDgColumnAction` when the item takes focus, so that focusing an item by any means -
|
|
6238
|
+
* including a plain `focus()` from outside, after an action rebuilt the menu - leaves space and
|
|
6239
|
+
* enter acting on that same item rather than on whatever the menu focused when it opened.
|
|
6240
|
+
*/
|
|
6241
|
+
focusAction(item) {
|
|
6242
|
+
this.focusHandler.moveTo(item);
|
|
6243
|
+
}
|
|
6244
|
+
/**
|
|
6245
|
+
* The menu states a direction rather than cycling through them, so asking for the direction the
|
|
6246
|
+
* column already has is a no-op.
|
|
6247
|
+
*
|
|
6248
|
+
* The guard is needed because `Sort.toggle()` reads `forceReverse: false` as "toggle" rather than
|
|
6249
|
+
* "ascending" - `forceReverse || !this._reverse` falls through to the toggle for a falsy value - so
|
|
6250
|
+
* `sort(false)` on an already ascending column would flip it to descending. The tri-state title
|
|
6251
|
+
* button never hits that path, because it always calls `sort()` without an argument.
|
|
6252
|
+
*/
|
|
6253
|
+
sort(descending) {
|
|
6254
|
+
const requested = descending ? ClrDatagridSortOrder.DESC : ClrDatagridSortOrder.ASC;
|
|
6255
|
+
if (this.sortOrder !== requested) {
|
|
6256
|
+
this.column.sort(descending);
|
|
6257
|
+
}
|
|
6258
|
+
}
|
|
6259
|
+
/**
|
|
6260
|
+
* Pins or unpins the column, then re-anchors this menu to the trigger.
|
|
6261
|
+
*
|
|
6262
|
+
* Pinning moves the column between the datagrid's static and scrollable containers, and the
|
|
6263
|
+
* trigger this menu is anchored to travels with it - far enough that the menu would otherwise be
|
|
6264
|
+
* left hanging next to where the column used to be. The menu stays open on purpose, so the action
|
|
6265
|
+
* it now offers is the one that undoes the pin the user just applied.
|
|
6266
|
+
*
|
|
6267
|
+
* The columns are relocated on the render cycle the pinned state change schedules, not while this
|
|
6268
|
+
* runs, so the overlay can only be re-anchored once that has happened - which `repositionMenu`
|
|
6269
|
+
* takes care of.
|
|
6270
|
+
*/
|
|
6271
|
+
togglePinned() {
|
|
6272
|
+
this.column.togglePinned();
|
|
6273
|
+
this.repositionMenu();
|
|
6274
|
+
}
|
|
6275
|
+
/**
|
|
6276
|
+
* Opens the filter of this column, anchored to the "Filter Column" menu item itself (`#trigger`
|
|
6277
|
+
* above), so the popover positions off the item that was actually clicked rather than the kebab.
|
|
6278
|
+
*
|
|
6279
|
+
* The popover is driven through the column's ClrPopoverService rather than through
|
|
6280
|
+
* `ClrDatagridFilter.open`, because that is the one thing every filter flavour has in common - a
|
|
6281
|
+
* projected clr-dg-filter, and the string and numeric filters the column builds for clrDgField,
|
|
6282
|
+
* all share this service. Setting `origin` is all it takes to re-anchor it: `clrPopoverOrigin` is
|
|
6283
|
+
* itself only an assignment to that property, and with the toggle gone nothing else claims it.
|
|
6284
|
+
*
|
|
6285
|
+
* `parent` links the filter's popover to this menu's, so that scrolling while both are open closes
|
|
6286
|
+
* or repositions them together rather than leaving one behind. It is cleared again once the filter
|
|
6287
|
+
* closes, in the `openChange` subscription below, so it never outlives the menu session that set it.
|
|
6288
|
+
*/
|
|
6289
|
+
openFilter(event) {
|
|
6290
|
+
// reroute filter popover origin to filter trigger and set dropdown menu as parent.
|
|
6291
|
+
this.columnPopover.origin = this.trigger;
|
|
6292
|
+
this.columnPopover.parent = this._menuPopoverContent;
|
|
6293
|
+
// The popover closes on an outside click, and ignores exactly one event while doing so: the one
|
|
6294
|
+
// that opened it. Without this, the very click on this menu item would close the filter again.
|
|
6295
|
+
this.columnPopover.openEvent = event;
|
|
6296
|
+
this.columnPopover.open = true;
|
|
6297
|
+
}
|
|
6298
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: ClrDatagridColumnActions, deps: [{ token: ClrDatagridColumn }, { token: i2.ClrCommonStringsService }, { token: ColumnActionsService }, { token: i3.ClrPopoverService, skipSelf: true }, { token: i0.ChangeDetectorRef }, { token: i0.Injector }, { token: FiltersProvider, optional: true }, { token: i6.ClrDropdown, optional: true, skipSelf: true }, { token: i3.ClrPopoverService }, { token: i6.DropdownFocusHandler }, { token: i6.RootDropdownService }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
6299
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.25", type: ClrDatagridColumnActions, isStandalone: false, selector: "clr-dg-column-actions", inputs: { keepFilterInHeader: ["clrDgKeepFilterInHeader", "keepFilterInHeader", booleanAttribute] }, host: { properties: { "class.datagrid-column-actions": "true" } }, providers: [
|
|
6300
|
+
ROOT_DROPDOWN_PROVIDER,
|
|
6301
|
+
FOCUS_SERVICE_PROVIDER,
|
|
6302
|
+
ColumnActionsFocusHandler,
|
|
6303
|
+
{ provide: DropdownFocusHandler, useExisting: ColumnActionsFocusHandler },
|
|
6304
|
+
{ provide: FocusableItem, useExisting: ColumnActionsFocusHandler },
|
|
6305
|
+
{ provide: ClrDropdown, useExisting: ClrDatagridColumnActions },
|
|
6306
|
+
], queries: [{ propertyName: "projectedItems", predicate: FocusableItem }], viewQueries: [{ propertyName: "trigger", first: true, predicate: ["trigger"], descendants: true, read: ElementRef }, { propertyName: "menuPopoverContent", first: true, predicate: ClrDropdownMenu, descendants: true, read: ClrPopoverContent }], usesInheritance: true, ngImport: i0, template: `
|
|
6307
|
+
<button
|
|
6308
|
+
class="datagrid-column-actions-toggle"
|
|
6309
|
+
type="button"
|
|
6310
|
+
clrDropdownTrigger
|
|
6311
|
+
[class.datagrid-column-actions-filtered]="filterActive"
|
|
6312
|
+
[attr.aria-label]="triggerLabel"
|
|
6313
|
+
>
|
|
6314
|
+
<cds-icon
|
|
6315
|
+
[size]="filterActive ? '16' : '12'"
|
|
6316
|
+
[shape]="filterActive ? 'ellipsis-grid-circle' : 'ellipsis-vertical'"
|
|
6317
|
+
[status]="filterActive ? 'info' : null"
|
|
6318
|
+
aria-hidden="true"
|
|
6319
|
+
/>
|
|
6320
|
+
</button>
|
|
6321
|
+
|
|
6322
|
+
<clr-dropdown-menu *clrIfOpen clrPosition="bottom-right">
|
|
6323
|
+
@if (column.sortable) {
|
|
6324
|
+
<!--
|
|
6325
|
+
The two directions are one exclusive setting rather than two commands, so they are radio
|
|
6326
|
+
items: the applied one is then announced as such. The active class alone would leave it
|
|
6327
|
+
visible only to a sighted user - the column header's aria-sort is not read from in here.
|
|
6328
|
+
-->
|
|
6329
|
+
<button
|
|
6330
|
+
type="button"
|
|
6331
|
+
clrDropdownItem
|
|
6332
|
+
role="menuitemradio"
|
|
6333
|
+
[attr.aria-checked]="sortOrder === ClrDatagridSortOrder.ASC"
|
|
6334
|
+
[class.active]="sortOrder === ClrDatagridSortOrder.ASC"
|
|
6335
|
+
(click)="sort(false)"
|
|
6336
|
+
>
|
|
6337
|
+
<cds-icon shape="arrow" direction="up" aria-hidden="true"></cds-icon>
|
|
6338
|
+
{{ commonStrings.keys.sortColumnAscending }}
|
|
6339
|
+
</button>
|
|
6340
|
+
<button
|
|
6341
|
+
type="button"
|
|
6342
|
+
clrDropdownItem
|
|
6343
|
+
role="menuitemradio"
|
|
6344
|
+
[attr.aria-checked]="sortOrder === ClrDatagridSortOrder.DESC"
|
|
6345
|
+
[class.active]="sortOrder === ClrDatagridSortOrder.DESC"
|
|
6346
|
+
(click)="sort(true)"
|
|
6347
|
+
>
|
|
6348
|
+
<cds-icon shape="arrow" direction="down" aria-hidden="true"></cds-icon>
|
|
6349
|
+
{{ commonStrings.keys.sortColumnDescending }}
|
|
6350
|
+
</button>
|
|
6351
|
+
@if (canClearSort) {
|
|
6352
|
+
<button type="button" clrDropdownItem (click)="column.clearSort()">
|
|
6353
|
+
<cds-icon shape="times" aria-hidden="true"></cds-icon>
|
|
6354
|
+
{{ commonStrings.keys.clearColumnSort }}
|
|
6355
|
+
</button>
|
|
6356
|
+
}
|
|
6357
|
+
}
|
|
6358
|
+
|
|
6359
|
+
@if (column.pinnable) {
|
|
6360
|
+
@if (column.sortable) {
|
|
6361
|
+
<div class="dropdown-divider" role="separator"></div>
|
|
6362
|
+
}
|
|
6363
|
+
<button type="button" clrDropdownItem (click)="togglePinned()">
|
|
6364
|
+
<cds-icon
|
|
6365
|
+
[shape]="column.pinned ? 'unpin' : 'pin'"
|
|
6366
|
+
solid
|
|
6367
|
+
size="12"
|
|
6368
|
+
style="margin: 2px;"
|
|
6369
|
+
aria-hidden="true"
|
|
6370
|
+
></cds-icon>
|
|
6371
|
+
{{ column.pinned ? commonStrings.keys.unpinColumn : commonStrings.keys.pinColumn }}
|
|
6372
|
+
</button>
|
|
6373
|
+
}
|
|
6374
|
+
|
|
6375
|
+
@if (hasFilter && !keepFilterInHeader) {
|
|
6376
|
+
@if (column.sortable || column.pinnable) {
|
|
6377
|
+
<div class="dropdown-divider" role="separator"></div>
|
|
6378
|
+
}
|
|
6379
|
+
<!--
|
|
6380
|
+
This item stands in for the filter's own toggle, so it takes over the state that toggle
|
|
6381
|
+
announced: that it opens a dialog, and whether that dialog is open right now.
|
|
6382
|
+
-->
|
|
6383
|
+
<button
|
|
6384
|
+
type="button"
|
|
6385
|
+
#trigger
|
|
6386
|
+
clrDropdownItem
|
|
6387
|
+
aria-haspopup="dialog"
|
|
6388
|
+
[attr.aria-expanded]="filterOpen"
|
|
6389
|
+
[attr.aria-controls]="filterPopoverId"
|
|
6390
|
+
(click)="openFilter($event)"
|
|
6391
|
+
>
|
|
6392
|
+
<cds-icon [shape]="filterActive ? 'filter-grid-circle' : 'filter-grid'" solid aria-hidden="true"></cds-icon>
|
|
6393
|
+
{{ commonStrings.keys.filterColumn }}
|
|
6394
|
+
</button>
|
|
6395
|
+
}
|
|
6396
|
+
|
|
6397
|
+
<ng-content></ng-content>
|
|
6398
|
+
</clr-dropdown-menu>
|
|
6399
|
+
`, isInline: true, dependencies: [{ kind: "component", type: i4.ClrIcon, selector: "clr-icon, cds-icon", inputs: ["shape", "size", "direction", "flip", "solid", "status", "inverse", "badge", "innerOffset"] }, { kind: "directive", type: i3.ClrIfOpen, selector: "[clrIfOpen]", inputs: ["clrIfOpen"], outputs: ["clrIfOpenChange"] }, { kind: "component", type: i6.ClrDropdownMenu, selector: "clr-dropdown-menu", inputs: ["clrPosition"] }, { kind: "directive", type: i6.ClrDropdownTrigger, selector: "[clrDropdownTrigger],[clrDropdownToggle]" }, { kind: "directive", type: i6.ClrDropdownItem, selector: "[clrDropdownItem]", inputs: ["role", "clrDisabled", "id"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
6400
|
+
}
|
|
6401
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: ClrDatagridColumnActions, decorators: [{
|
|
6402
|
+
type: Component,
|
|
6403
|
+
args: [{
|
|
6404
|
+
selector: 'clr-dg-column-actions',
|
|
6405
|
+
template: `
|
|
6406
|
+
<button
|
|
6407
|
+
class="datagrid-column-actions-toggle"
|
|
6408
|
+
type="button"
|
|
6409
|
+
clrDropdownTrigger
|
|
6410
|
+
[class.datagrid-column-actions-filtered]="filterActive"
|
|
6411
|
+
[attr.aria-label]="triggerLabel"
|
|
6412
|
+
>
|
|
6413
|
+
<cds-icon
|
|
6414
|
+
[size]="filterActive ? '16' : '12'"
|
|
6415
|
+
[shape]="filterActive ? 'ellipsis-grid-circle' : 'ellipsis-vertical'"
|
|
6416
|
+
[status]="filterActive ? 'info' : null"
|
|
6417
|
+
aria-hidden="true"
|
|
6418
|
+
/>
|
|
6419
|
+
</button>
|
|
6420
|
+
|
|
6421
|
+
<clr-dropdown-menu *clrIfOpen clrPosition="bottom-right">
|
|
6422
|
+
@if (column.sortable) {
|
|
6423
|
+
<!--
|
|
6424
|
+
The two directions are one exclusive setting rather than two commands, so they are radio
|
|
6425
|
+
items: the applied one is then announced as such. The active class alone would leave it
|
|
6426
|
+
visible only to a sighted user - the column header's aria-sort is not read from in here.
|
|
6427
|
+
-->
|
|
6428
|
+
<button
|
|
6429
|
+
type="button"
|
|
6430
|
+
clrDropdownItem
|
|
6431
|
+
role="menuitemradio"
|
|
6432
|
+
[attr.aria-checked]="sortOrder === ClrDatagridSortOrder.ASC"
|
|
6433
|
+
[class.active]="sortOrder === ClrDatagridSortOrder.ASC"
|
|
6434
|
+
(click)="sort(false)"
|
|
6435
|
+
>
|
|
6436
|
+
<cds-icon shape="arrow" direction="up" aria-hidden="true"></cds-icon>
|
|
6437
|
+
{{ commonStrings.keys.sortColumnAscending }}
|
|
6438
|
+
</button>
|
|
6439
|
+
<button
|
|
6440
|
+
type="button"
|
|
6441
|
+
clrDropdownItem
|
|
6442
|
+
role="menuitemradio"
|
|
6443
|
+
[attr.aria-checked]="sortOrder === ClrDatagridSortOrder.DESC"
|
|
6444
|
+
[class.active]="sortOrder === ClrDatagridSortOrder.DESC"
|
|
6445
|
+
(click)="sort(true)"
|
|
6446
|
+
>
|
|
6447
|
+
<cds-icon shape="arrow" direction="down" aria-hidden="true"></cds-icon>
|
|
6448
|
+
{{ commonStrings.keys.sortColumnDescending }}
|
|
6449
|
+
</button>
|
|
6450
|
+
@if (canClearSort) {
|
|
6451
|
+
<button type="button" clrDropdownItem (click)="column.clearSort()">
|
|
6452
|
+
<cds-icon shape="times" aria-hidden="true"></cds-icon>
|
|
6453
|
+
{{ commonStrings.keys.clearColumnSort }}
|
|
6454
|
+
</button>
|
|
6455
|
+
}
|
|
6456
|
+
}
|
|
6457
|
+
|
|
6458
|
+
@if (column.pinnable) {
|
|
6459
|
+
@if (column.sortable) {
|
|
6460
|
+
<div class="dropdown-divider" role="separator"></div>
|
|
6461
|
+
}
|
|
6462
|
+
<button type="button" clrDropdownItem (click)="togglePinned()">
|
|
6463
|
+
<cds-icon
|
|
6464
|
+
[shape]="column.pinned ? 'unpin' : 'pin'"
|
|
6465
|
+
solid
|
|
6466
|
+
size="12"
|
|
6467
|
+
style="margin: 2px;"
|
|
6468
|
+
aria-hidden="true"
|
|
6469
|
+
></cds-icon>
|
|
6470
|
+
{{ column.pinned ? commonStrings.keys.unpinColumn : commonStrings.keys.pinColumn }}
|
|
6471
|
+
</button>
|
|
6472
|
+
}
|
|
6473
|
+
|
|
6474
|
+
@if (hasFilter && !keepFilterInHeader) {
|
|
6475
|
+
@if (column.sortable || column.pinnable) {
|
|
6476
|
+
<div class="dropdown-divider" role="separator"></div>
|
|
6477
|
+
}
|
|
6478
|
+
<!--
|
|
6479
|
+
This item stands in for the filter's own toggle, so it takes over the state that toggle
|
|
6480
|
+
announced: that it opens a dialog, and whether that dialog is open right now.
|
|
6481
|
+
-->
|
|
6482
|
+
<button
|
|
6483
|
+
type="button"
|
|
6484
|
+
#trigger
|
|
6485
|
+
clrDropdownItem
|
|
6486
|
+
aria-haspopup="dialog"
|
|
6487
|
+
[attr.aria-expanded]="filterOpen"
|
|
6488
|
+
[attr.aria-controls]="filterPopoverId"
|
|
6489
|
+
(click)="openFilter($event)"
|
|
6490
|
+
>
|
|
6491
|
+
<cds-icon [shape]="filterActive ? 'filter-grid-circle' : 'filter-grid'" solid aria-hidden="true"></cds-icon>
|
|
6492
|
+
{{ commonStrings.keys.filterColumn }}
|
|
6493
|
+
</button>
|
|
6494
|
+
}
|
|
6495
|
+
|
|
6496
|
+
<ng-content></ng-content>
|
|
6497
|
+
</clr-dropdown-menu>
|
|
6498
|
+
`,
|
|
6499
|
+
host: {
|
|
6500
|
+
'[class.datagrid-column-actions]': 'true',
|
|
6501
|
+
},
|
|
6502
|
+
// ClrDropdown's providers are not inherited, so they have to be repeated for this component to be
|
|
6503
|
+
// one. Its host directives and host bindings - the popover host, and the dropdown classes - are
|
|
6504
|
+
// inherited, and must not be repeated.
|
|
6505
|
+
providers: [
|
|
6506
|
+
ROOT_DROPDOWN_PROVIDER,
|
|
6507
|
+
FOCUS_SERVICE_PROVIDER,
|
|
6508
|
+
ColumnActionsFocusHandler,
|
|
6509
|
+
{ provide: DropdownFocusHandler, useExisting: ColumnActionsFocusHandler },
|
|
6510
|
+
{ provide: FocusableItem, useExisting: ColumnActionsFocusHandler },
|
|
6511
|
+
{ provide: ClrDropdown, useExisting: ClrDatagridColumnActions },
|
|
6512
|
+
],
|
|
6513
|
+
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
6514
|
+
standalone: false,
|
|
6515
|
+
}]
|
|
6516
|
+
}], ctorParameters: () => [{ type: ClrDatagridColumn }, { type: i2.ClrCommonStringsService }, { type: ColumnActionsService }, { type: i3.ClrPopoverService, decorators: [{
|
|
6517
|
+
type: SkipSelf
|
|
6518
|
+
}] }, { type: i0.ChangeDetectorRef }, { type: i0.Injector }, { type: FiltersProvider, decorators: [{
|
|
6519
|
+
type: Optional
|
|
6520
|
+
}] }, { type: i6.ClrDropdown, decorators: [{
|
|
6521
|
+
type: SkipSelf
|
|
6522
|
+
}, {
|
|
6523
|
+
type: Optional
|
|
6524
|
+
}] }, { type: i3.ClrPopoverService }, { type: i6.DropdownFocusHandler }, { type: i6.RootDropdownService }], propDecorators: { trigger: [{
|
|
6525
|
+
type: ViewChild,
|
|
6526
|
+
args: ['trigger', { read: ElementRef }]
|
|
6527
|
+
}], keepFilterInHeader: [{
|
|
6528
|
+
type: Input,
|
|
6529
|
+
args: [{ alias: 'clrDgKeepFilterInHeader', transform: booleanAttribute }]
|
|
6530
|
+
}], projectedItems: [{
|
|
6531
|
+
type: ContentChildren,
|
|
6532
|
+
args: [FocusableItem]
|
|
6533
|
+
}], menuPopoverContent: [{
|
|
6534
|
+
type: ViewChild,
|
|
6535
|
+
args: [ClrDropdownMenu, { read: ClrPopoverContent }]
|
|
6536
|
+
}] } });
|
|
6537
|
+
|
|
6538
|
+
/*
|
|
6539
|
+
* Copyright (c) 2016-2026 Broadcom. All Rights Reserved.
|
|
6540
|
+
* The term "Broadcom" refers to Broadcom Inc. and/or its subsidiaries.
|
|
6541
|
+
* This software is released under MIT license.
|
|
6542
|
+
* The full license information can be found in LICENSE in the root directory of this project.
|
|
6543
|
+
*/
|
|
6544
|
+
/**
|
|
6545
|
+
* An application provided item in a `clr-dg-column-actions` menu. It is the dropdown item - same
|
|
6546
|
+
* inputs, styling and arrow key order - with what a column action needs on top: it closes the menu
|
|
6547
|
+
* when picked, or re-anchors it after an action that leaves it open.
|
|
6548
|
+
*/
|
|
6549
|
+
class ClrDatagridColumnAction extends ClrDropdownItem {
|
|
6550
|
+
constructor(columnActions, item, dropdownService, el, renderer) {
|
|
6551
|
+
super(columnActions, dropdownService, item, el, renderer);
|
|
6552
|
+
this.columnActions = columnActions;
|
|
6553
|
+
/**
|
|
6554
|
+
* Whether activating this item should close the menu.
|
|
6555
|
+
*/
|
|
6556
|
+
this.canClosePopover = true;
|
|
6557
|
+
}
|
|
6558
|
+
// Space and enter both turn into a click, so this covers the keyboard as well.
|
|
6559
|
+
onColumnActionClick() {
|
|
6560
|
+
if (this.disabled) {
|
|
6561
|
+
return;
|
|
6562
|
+
}
|
|
6563
|
+
if (this.canClosePopover) {
|
|
6564
|
+
this.columnActions.closeMenu();
|
|
6565
|
+
}
|
|
6566
|
+
else {
|
|
6567
|
+
this.columnActions.repositionMenu();
|
|
6568
|
+
}
|
|
6569
|
+
}
|
|
6570
|
+
/**
|
|
6571
|
+
* Focus can arrive from anywhere - the arrow keys, or a plain `focus()` from an application that
|
|
6572
|
+
* moved the column this action belongs to and rebuilt the menu. Reporting it keeps space and enter
|
|
6573
|
+
* acting on this item rather than on whatever the menu focused when it opened.
|
|
6574
|
+
*/
|
|
6575
|
+
onFocus() {
|
|
6576
|
+
this.columnActions.focusAction(this.focusableItem);
|
|
6577
|
+
}
|
|
6578
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: ClrDatagridColumnAction, deps: [{ token: ClrDatagridColumnActions }, { token: i2.FocusableItem }, { token: i6.RootDropdownService }, { token: i0.ElementRef }, { token: i0.Renderer2 }], target: i0.ɵɵFactoryTarget.Directive }); }
|
|
6579
|
+
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "16.1.0", version: "21.2.25", type: ClrDatagridColumnAction, isStandalone: false, selector: "[clrDgColumnAction]", inputs: { canClosePopover: ["clrCanClosePopover", "canClosePopover", booleanAttribute] }, host: { listeners: { "click": "onColumnActionClick()", "focus": "onFocus()" } }, providers: [BASIC_FOCUSABLE_ITEM_PROVIDER], usesInheritance: true, ngImport: i0 }); }
|
|
6580
|
+
}
|
|
6581
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: ClrDatagridColumnAction, decorators: [{
|
|
6582
|
+
type: Directive,
|
|
6583
|
+
args: [{
|
|
6584
|
+
selector: '[clrDgColumnAction]',
|
|
6585
|
+
providers: [BASIC_FOCUSABLE_ITEM_PROVIDER],
|
|
6586
|
+
standalone: false,
|
|
6587
|
+
}]
|
|
6588
|
+
}], ctorParameters: () => [{ type: ClrDatagridColumnActions }, { type: i2.FocusableItem }, { type: i6.RootDropdownService }, { type: i0.ElementRef }, { type: i0.Renderer2 }], propDecorators: { canClosePopover: [{
|
|
6589
|
+
type: Input,
|
|
6590
|
+
args: [{ alias: 'clrCanClosePopover', transform: booleanAttribute }]
|
|
6591
|
+
}], onColumnActionClick: [{
|
|
6592
|
+
type: HostListener,
|
|
6593
|
+
args: ['click']
|
|
6594
|
+
}], onFocus: [{
|
|
6595
|
+
type: HostListener,
|
|
6596
|
+
args: ['focus']
|
|
6597
|
+
}] } });
|
|
6598
|
+
|
|
5851
6599
|
/*
|
|
5852
6600
|
* Copyright (c) 2016-2026 Broadcom. All Rights Reserved.
|
|
5853
6601
|
* The term "Broadcom" refers to Broadcom Inc. and/or its subsidiaries.
|
|
@@ -5884,8 +6632,8 @@ class ClrDatagridColumnToggleButton {
|
|
|
5884
6632
|
hideableColumns() {
|
|
5885
6633
|
return this.columnsService.columns.filter(column => column.value.hideable);
|
|
5886
6634
|
}
|
|
5887
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.
|
|
5888
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "21.
|
|
6635
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: ClrDatagridColumnToggleButton, deps: [{ token: i2.ClrCommonStringsService }, { token: ColumnsService }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
6636
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "21.2.25", type: ClrDatagridColumnToggleButton, isStandalone: false, selector: "clr-dg-column-toggle-button", outputs: { clrAllSelected: "clrAllSelected" }, ngImport: i0, template: `
|
|
5889
6637
|
<button
|
|
5890
6638
|
class="btn btn-sm btn-link switch-button"
|
|
5891
6639
|
(click)="selectAll()"
|
|
@@ -5896,7 +6644,7 @@ class ClrDatagridColumnToggleButton {
|
|
|
5896
6644
|
</button>
|
|
5897
6645
|
`, isInline: true }); }
|
|
5898
6646
|
}
|
|
5899
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.
|
|
6647
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: ClrDatagridColumnToggleButton, decorators: [{
|
|
5900
6648
|
type: Component,
|
|
5901
6649
|
args: [{
|
|
5902
6650
|
selector: 'clr-dg-column-toggle-button',
|
|
@@ -5968,8 +6716,8 @@ class ClrDatagridColumnToggle {
|
|
|
5968
6716
|
allColumnsSelected() {
|
|
5969
6717
|
this.allSelectedElement.nativeElement.focus();
|
|
5970
6718
|
}
|
|
5971
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.
|
|
5972
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.
|
|
6719
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: ClrDatagridColumnToggle, deps: [{ token: i2.ClrCommonStringsService }, { token: ColumnsService }, { token: i3.ClrPopoverService }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
6720
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.25", type: ClrDatagridColumnToggle, isStandalone: false, selector: "clr-dg-column-toggle", host: { properties: { "class.column-switch-wrapper": "true", "class.active": "openState" } }, viewQueries: [{ propertyName: "allSelectedElement", first: true, predicate: ["allSelected"], descendants: true, read: ElementRef }], hostDirectives: [{ directive: i3.ClrPopoverHostDirective }], ngImport: i0, template: `
|
|
5973
6721
|
<button
|
|
5974
6722
|
role="button"
|
|
5975
6723
|
type="button"
|
|
@@ -6032,9 +6780,9 @@ class ClrDatagridColumnToggle {
|
|
|
6032
6780
|
<clr-dg-column-toggle-button (clrAllSelected)="allColumnsSelected()"></clr-dg-column-toggle-button>
|
|
6033
6781
|
</div>
|
|
6034
6782
|
</div>
|
|
6035
|
-
`, isInline: true, dependencies: [{ kind: "directive", type: i10.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "directive", type: i2.CdkTrapFocusModule_CdkTrapFocus, selector: "[cdkTrapFocus]" }, { kind: "component", type:
|
|
6783
|
+
`, isInline: true, dependencies: [{ kind: "directive", type: i10.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "directive", type: i2.CdkTrapFocusModule_CdkTrapFocus, selector: "[cdkTrapFocus]" }, { kind: "component", type: i4.ClrIcon, selector: "clr-icon, cds-icon", inputs: ["shape", "size", "direction", "flip", "solid", "status", "inverse", "badge", "innerOffset"] }, { kind: "directive", type: i4$1.ClrControlLabel, selector: "label", inputs: ["id", "for"] }, { kind: "directive", type: i7.ClrCheckbox, selector: "[clrCheckbox],[clrToggle]" }, { kind: "component", type: i7.ClrCheckboxWrapper, selector: "clr-checkbox-wrapper,clr-toggle-wrapper" }, { kind: "directive", type: i14.CheckboxControlValueAccessor, selector: "input[type=checkbox][formControlName],input[type=checkbox][formControl],input[type=checkbox][ngModel]" }, { kind: "directive", type: i14.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i14.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "directive", type: i3.ClrPopoverOrigin, selector: "[clrPopoverOrigin]" }, { kind: "directive", type: i3.ClrPopoverCloseButton, selector: "[clrPopoverCloseButton]", outputs: ["clrPopoverOnCloseChange"] }, { kind: "directive", type: i3.ClrPopoverOpenCloseButton, selector: "[clrPopoverOpenCloseButton]", outputs: ["clrPopoverOpenCloseChange"] }, { kind: "directive", type: i3.ClrPopoverContent, selector: "[clrPopoverContent]", inputs: ["clrPopoverContent", "clrPopoverContentAt", "clrPopoverContentAvailablePositions", "clrPopoverContentType", "clrPopoverContentOutsideClickToClose", "clrPopoverContentScrollToClose", "clrPopoverContentOrigin"] }, { kind: "component", type: ClrDatagridColumnToggleButton, selector: "clr-dg-column-toggle-button", outputs: ["clrAllSelected"] }] }); }
|
|
6036
6784
|
}
|
|
6037
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.
|
|
6785
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: ClrDatagridColumnToggle, decorators: [{
|
|
6038
6786
|
type: Component,
|
|
6039
6787
|
args: [{
|
|
6040
6788
|
selector: 'clr-dg-column-toggle',
|
|
@@ -6128,8 +6876,8 @@ class ClrDatagridDetailHeader {
|
|
|
6128
6876
|
ngAfterViewInit() {
|
|
6129
6877
|
this.title.nativeElement.focus();
|
|
6130
6878
|
}
|
|
6131
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.
|
|
6132
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "21.
|
|
6879
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: ClrDatagridDetailHeader, deps: [{ token: DetailService }, { token: i2.ClrCommonStringsService }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
6880
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "21.2.25", type: ClrDatagridDetailHeader, isStandalone: false, selector: "clr-dg-detail-header", host: { properties: { "class.datagrid-detail-header": "true" } }, viewQueries: [{ propertyName: "title", first: true, predicate: ["title"], descendants: true }], ngImport: i0, template: `
|
|
6133
6881
|
<div #title class="datagrid-detail-header-title" tabindex="-1" [id]="titleId">
|
|
6134
6882
|
<ng-content></ng-content>
|
|
6135
6883
|
</div>
|
|
@@ -6143,9 +6891,9 @@ class ClrDatagridDetailHeader {
|
|
|
6143
6891
|
<cds-icon shape="times"></cds-icon>
|
|
6144
6892
|
</button>
|
|
6145
6893
|
</div>
|
|
6146
|
-
`, isInline: true, dependencies: [{ kind: "component", type:
|
|
6894
|
+
`, isInline: true, dependencies: [{ kind: "component", type: i4.ClrIcon, selector: "clr-icon, cds-icon", inputs: ["shape", "size", "direction", "flip", "solid", "status", "inverse", "badge", "innerOffset"] }] }); }
|
|
6147
6895
|
}
|
|
6148
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.
|
|
6896
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: ClrDatagridDetailHeader, decorators: [{
|
|
6149
6897
|
type: Component,
|
|
6150
6898
|
args: [{
|
|
6151
6899
|
selector: 'clr-dg-detail-header',
|
|
@@ -6234,8 +6982,8 @@ class ClrDatagridDetail {
|
|
|
6234
6982
|
close() {
|
|
6235
6983
|
this.detailService.close();
|
|
6236
6984
|
}
|
|
6237
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.
|
|
6238
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.
|
|
6985
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: ClrDatagridDetail, deps: [{ token: DetailService }, { token: i2.ClrCommonStringsService }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
6986
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.25", type: ClrDatagridDetail, isStandalone: false, selector: "clr-dg-detail", inputs: { ariaLabelledBy: ["clrDetailAriaLabelledBy", "ariaLabelledBy"], ariaLabel: ["clrDetailAriaLabel", "ariaLabel"], detailWidth: ["clrDetailWidth", "detailWidth"] }, host: { properties: { "class.datagrid-detail-pane": "true", "class.datagrid-detail-custom-width": "isCustomWidth", "style.width.%": "width" } }, queries: [{ propertyName: "header", first: true, predicate: ClrDatagridDetailHeader, descendants: true }], ngImport: i0, template: `
|
|
6239
6987
|
@if (detailService.isOpen) {
|
|
6240
6988
|
<div
|
|
6241
6989
|
cdkTrapFocus
|
|
@@ -6254,7 +7002,7 @@ class ClrDatagridDetail {
|
|
|
6254
7002
|
}
|
|
6255
7003
|
`, isInline: true, dependencies: [{ kind: "directive", type: i2.CdkTrapFocusModule_CdkTrapFocus, selector: "[cdkTrapFocus]" }] }); }
|
|
6256
7004
|
}
|
|
6257
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.
|
|
7005
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: ClrDatagridDetail, decorators: [{
|
|
6258
7006
|
type: Component,
|
|
6259
7007
|
args: [{
|
|
6260
7008
|
selector: 'clr-dg-detail',
|
|
@@ -6306,14 +7054,14 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.1.3", ngImpor
|
|
|
6306
7054
|
* The full license information can be found in LICENSE in the root directory of this project.
|
|
6307
7055
|
*/
|
|
6308
7056
|
class ClrDatagridDetailBody {
|
|
6309
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.
|
|
6310
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "21.
|
|
7057
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: ClrDatagridDetailBody, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
7058
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "21.2.25", type: ClrDatagridDetailBody, isStandalone: false, selector: "clr-dg-detail-body", host: { properties: { "class.datagrid-detail-body": "true" } }, ngImport: i0, template: `
|
|
6311
7059
|
<div class="clr-dg-detail-body-wrapper">
|
|
6312
7060
|
<ng-content></ng-content>
|
|
6313
7061
|
</div>
|
|
6314
7062
|
`, isInline: true }); }
|
|
6315
7063
|
}
|
|
6316
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.
|
|
7064
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: ClrDatagridDetailBody, decorators: [{
|
|
6317
7065
|
type: Component,
|
|
6318
7066
|
args: [{
|
|
6319
7067
|
selector: 'clr-dg-detail-body',
|
|
@@ -6405,10 +7153,10 @@ class ClrDatagridHideableColumn {
|
|
|
6405
7153
|
ngOnDestroy() {
|
|
6406
7154
|
this.subscriptions.forEach(sub => sub.unsubscribe());
|
|
6407
7155
|
}
|
|
6408
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.
|
|
6409
|
-
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "21.
|
|
7156
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: ClrDatagridHideableColumn, deps: [{ token: i0.TemplateRef }, { token: i0.ViewContainerRef }, { token: ColumnsService }, { token: COLUMN_STATE, optional: true }], target: i0.ɵɵFactoryTarget.Directive }); }
|
|
7157
|
+
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "21.2.25", type: ClrDatagridHideableColumn, isStandalone: false, selector: "[clrDgHideableColumn]", inputs: { clrDgHideableColumn: "clrDgHideableColumn", clrDgHidden: "clrDgHidden" }, outputs: { hiddenChange: "clrDgHiddenChange" }, ngImport: i0 }); }
|
|
6410
7158
|
}
|
|
6411
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.
|
|
7159
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: ClrDatagridHideableColumn, decorators: [{
|
|
6412
7160
|
type: Directive,
|
|
6413
7161
|
args: [{
|
|
6414
7162
|
selector: '[clrDgHideableColumn]',
|
|
@@ -6507,10 +7255,10 @@ class ClrIfDetail {
|
|
|
6507
7255
|
},
|
|
6508
7256
|
});
|
|
6509
7257
|
}
|
|
6510
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.
|
|
6511
|
-
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "21.
|
|
7258
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: ClrIfDetail, deps: [{ token: i0.TemplateRef }, { token: i0.ViewContainerRef }, { token: DetailService }], target: i0.ɵɵFactoryTarget.Directive }); }
|
|
7259
|
+
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "21.2.25", type: ClrIfDetail, isStandalone: false, selector: "[clrIfDetail]", inputs: { state: ["clrIfDetail", "state"] }, outputs: { stateChange: "clrIfDetailChange" }, ngImport: i0 }); }
|
|
6512
7260
|
}
|
|
6513
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.
|
|
7261
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: ClrIfDetail, decorators: [{
|
|
6514
7262
|
type: Directive,
|
|
6515
7263
|
args: [{
|
|
6516
7264
|
selector: '[clrIfDetail]',
|
|
@@ -6633,8 +7381,8 @@ class ClrDatagridRowDetail {
|
|
|
6633
7381
|
container.insert(cell._view);
|
|
6634
7382
|
}
|
|
6635
7383
|
}
|
|
6636
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.
|
|
6637
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.
|
|
7384
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: ClrDatagridRowDetail, deps: [{ token: Selection }, { token: RowActionService }, { token: DatagridIfExpandService }, { token: ExpandableRowsCount }, { token: i2.ClrCommonStringsService }, { token: ColumnsService }, { token: DisplayModeService }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
7385
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.25", type: ClrDatagridRowDetail, isStandalone: false, selector: "clr-dg-row-detail", inputs: { _beginningOfExpandableContentAriaText: ["clrRowDetailBeginningAriaText", "_beginningOfExpandableContentAriaText"], _endOfExpandableContentAriaText: ["clrRowDetailEndAriaText", "_endOfExpandableContentAriaText"], replace: ["clrDgReplace", "replace"] }, host: { attributes: { "role": "row" }, properties: { "class.datagrid-row-flex": "true", "class.datagrid-row-detail": "true", "attr.id": "expand.expandableId" } }, queries: [{ propertyName: "cells", predicate: ClrDatagridCell }], viewQueries: [{ propertyName: "_pinnedCells", first: true, predicate: ["pinnedCells"], descendants: true, read: ViewContainerRef }, { propertyName: "_scrollableCells", first: true, predicate: ["scrollableCells"], descendants: true, read: ViewContainerRef }, { propertyName: "_plainCells", first: true, predicate: ["plainCells"], descendants: true, read: ViewContainerRef }], ngImport: i0, template: `
|
|
6638
7386
|
<div class="clr-sr-only">
|
|
6639
7387
|
{{ beginningOfExpandableContentAriaText }}
|
|
6640
7388
|
{{ commonStrings.keys.datagridExpandableRowsHelperText }}
|
|
@@ -6669,7 +7417,7 @@ class ClrDatagridRowDetail {
|
|
|
6669
7417
|
<div class="clr-sr-only">{{ endOfExpandableContentAriaText }}</div>
|
|
6670
7418
|
`, isInline: true, dependencies: [{ kind: "directive", type: i10.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "component", type: ClrDatagridCell, selector: "clr-dg-cell" }, { kind: "directive", type: DatagridCellRenderer, selector: "clr-dg-cell" }] }); }
|
|
6671
7419
|
}
|
|
6672
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.
|
|
7420
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: ClrDatagridRowDetail, decorators: [{
|
|
6673
7421
|
type: Component,
|
|
6674
7422
|
args: [{
|
|
6675
7423
|
selector: 'clr-dg-row-detail',
|
|
@@ -6756,8 +7504,8 @@ class ClrDatagridFooter {
|
|
|
6756
7504
|
get hasHideableColumns() {
|
|
6757
7505
|
return this.columnsService.hasHideableColumns;
|
|
6758
7506
|
}
|
|
6759
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.
|
|
6760
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.
|
|
7507
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: ClrDatagridFooter, deps: [{ token: Selection }, { token: DetailService }, { token: ColumnsService }, { token: i2.ClrCommonStringsService }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
7508
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.25", type: ClrDatagridFooter, isStandalone: false, selector: "clr-dg-footer", host: { properties: { "class.datagrid-footer": "true" } }, ngImport: i0, template: `
|
|
6761
7509
|
@if (selection.selectionType === SELECTION_TYPE.Multi && selection.current?.length > 0) {
|
|
6762
7510
|
<div class="clr-form-control-disabled">
|
|
6763
7511
|
<clr-checkbox-wrapper class="datagrid-footer-select">
|
|
@@ -6776,9 +7524,9 @@ class ClrDatagridFooter {
|
|
|
6776
7524
|
</div>
|
|
6777
7525
|
}
|
|
6778
7526
|
<ng-content select="clr-dg-pagination"></ng-content>
|
|
6779
|
-
`, isInline: true, dependencies: [{ kind: "directive", type: i4.ClrControlLabel, selector: "label", inputs: ["id", "for"] }, { kind: "directive", type: i7.ClrCheckbox, selector: "[clrCheckbox],[clrToggle]" }, { kind: "component", type: i7.ClrCheckboxWrapper, selector: "clr-checkbox-wrapper,clr-toggle-wrapper" }, { kind: "component", type: ClrDatagridColumnToggle, selector: "clr-dg-column-toggle" }] }); }
|
|
7527
|
+
`, isInline: true, dependencies: [{ kind: "directive", type: i4$1.ClrControlLabel, selector: "label", inputs: ["id", "for"] }, { kind: "directive", type: i7.ClrCheckbox, selector: "[clrCheckbox],[clrToggle]" }, { kind: "component", type: i7.ClrCheckboxWrapper, selector: "clr-checkbox-wrapper,clr-toggle-wrapper" }, { kind: "component", type: ClrDatagridColumnToggle, selector: "clr-dg-column-toggle" }] }); }
|
|
6780
7528
|
}
|
|
6781
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.
|
|
7529
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: ClrDatagridFooter, decorators: [{
|
|
6782
7530
|
type: Component,
|
|
6783
7531
|
args: [{
|
|
6784
7532
|
selector: 'clr-dg-footer',
|
|
@@ -6830,8 +7578,8 @@ class ClrDatagridPageSize {
|
|
|
6830
7578
|
this.pageSizeOptions = [this.page.size];
|
|
6831
7579
|
}
|
|
6832
7580
|
}
|
|
6833
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.
|
|
6834
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.
|
|
7581
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: ClrDatagridPageSize, deps: [{ token: Page }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
7582
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.25", type: ClrDatagridPageSize, isStandalone: false, selector: "clr-dg-page-size", inputs: { pageSizeOptions: ["clrPageSizeOptions", "pageSizeOptions"], pageSizeOptionsId: ["clrPageSizeOptionsId", "pageSizeOptionsId"] }, viewQueries: [{ propertyName: "label", first: true, predicate: ClrControlLabel, descendants: true, static: true }], ngImport: i0, template: `
|
|
6835
7583
|
<label [for]="pageSizeOptionsId"><ng-content></ng-content></label>
|
|
6836
7584
|
<div class="clr-select-wrapper">
|
|
6837
7585
|
<select [id]="pageSizeOptionsId" [class.clr-page-size-select]="true" [(ngModel)]="page.size">
|
|
@@ -6840,9 +7588,9 @@ class ClrDatagridPageSize {
|
|
|
6840
7588
|
}
|
|
6841
7589
|
</select>
|
|
6842
7590
|
</div>
|
|
6843
|
-
`, isInline: true, dependencies: [{ kind: "directive", type: i4.ClrControlLabel, selector: "label", inputs: ["id", "for"] }, { kind: "directive", type: i14.NgSelectOption, selector: "option", inputs: ["ngValue", "value"] }, { kind: "directive", type: i14.ɵNgSelectMultipleOption, selector: "option", inputs: ["ngValue", "value"] }, { kind: "directive", type: i14.SelectControlValueAccessor, selector: "select:not([multiple])[formControlName],select:not([multiple])[formControl],select:not([multiple])[ngModel]", inputs: ["compareWith"] }, { kind: "directive", type: i14.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i14.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }] }); }
|
|
7591
|
+
`, isInline: true, dependencies: [{ kind: "directive", type: i4$1.ClrControlLabel, selector: "label", inputs: ["id", "for"] }, { kind: "directive", type: i14.NgSelectOption, selector: "option", inputs: ["ngValue", "value"] }, { kind: "directive", type: i14.ɵNgSelectMultipleOption, selector: "option", inputs: ["ngValue", "value"] }, { kind: "directive", type: i14.SelectControlValueAccessor, selector: "select:not([multiple])[formControlName],select:not([multiple])[formControl],select:not([multiple])[ngModel]", inputs: ["compareWith"] }, { kind: "directive", type: i14.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i14.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }] }); }
|
|
6844
7592
|
}
|
|
6845
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.
|
|
7593
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: ClrDatagridPageSize, decorators: [{
|
|
6846
7594
|
type: Component,
|
|
6847
7595
|
args: [{
|
|
6848
7596
|
selector: 'clr-dg-page-size',
|
|
@@ -7019,8 +7767,8 @@ class ClrDatagridPagination {
|
|
|
7019
7767
|
*/
|
|
7020
7768
|
this.currentPageInputRef.nativeElement.value = this.page.current.toString();
|
|
7021
7769
|
}
|
|
7022
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.
|
|
7023
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.
|
|
7770
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: ClrDatagridPagination, deps: [{ token: Page }, { token: i2.ClrCommonStringsService }, { token: DetailService }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
7771
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.25", type: ClrDatagridPagination, isStandalone: false, selector: "clr-dg-pagination", inputs: { disableCurrentPageInput: ["clrDgPageInputDisabled", "disableCurrentPageInput"], pageSize: ["clrDgPageSize", "pageSize"], totalItems: ["clrDgTotalItems", "totalItems"], lastPage: ["clrDgLastPage", "lastPage"], currentPage: ["clrDgPage", "currentPage"] }, outputs: { currentChanged: "clrDgPageChange" }, host: { properties: { "class.pagination": "true" } }, queries: [{ propertyName: "_pageSizeComponent", first: true, predicate: ClrDatagridPageSize, descendants: true }], viewQueries: [{ propertyName: "currentPageInputRef", first: true, predicate: ["currentPageInput"], descendants: true }], ngImport: i0, template: `
|
|
7024
7772
|
@if (!detailService.isOpen) {
|
|
7025
7773
|
@if (_pageSizeComponent) {
|
|
7026
7774
|
<div class="pagination-size">
|
|
@@ -7120,9 +7868,9 @@ class ClrDatagridPagination {
|
|
|
7120
7868
|
</button>
|
|
7121
7869
|
</div>
|
|
7122
7870
|
}
|
|
7123
|
-
`, isInline: true, dependencies: [{ kind: "component", type:
|
|
7871
|
+
`, isInline: true, dependencies: [{ kind: "component", type: i4.ClrIcon, selector: "clr-icon, cds-icon", inputs: ["shape", "size", "direction", "flip", "solid", "status", "inverse", "badge", "innerOffset"] }] }); }
|
|
7124
7872
|
}
|
|
7125
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.
|
|
7873
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: ClrDatagridPagination, decorators: [{
|
|
7126
7874
|
type: Component,
|
|
7127
7875
|
args: [{
|
|
7128
7876
|
selector: 'clr-dg-pagination',
|
|
@@ -7320,10 +8068,10 @@ class DatagridDetailRegisterer {
|
|
|
7320
8068
|
this.expandableRowsCount.unregister();
|
|
7321
8069
|
}
|
|
7322
8070
|
}
|
|
7323
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.
|
|
7324
|
-
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "21.
|
|
8071
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: DatagridDetailRegisterer, deps: [{ token: ExpandableRowsCount, optional: true }], target: i0.ɵɵFactoryTarget.Directive }); }
|
|
8072
|
+
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "21.2.25", type: DatagridDetailRegisterer, isStandalone: false, selector: "[clrIfExpanded]", ngImport: i0 }); }
|
|
7325
8073
|
}
|
|
7326
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.
|
|
8074
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: DatagridDetailRegisterer, decorators: [{
|
|
7327
8075
|
type: Directive,
|
|
7328
8076
|
args: [{
|
|
7329
8077
|
selector: '[clrIfExpanded]',
|
|
@@ -7430,10 +8178,10 @@ class DatagridHeaderRenderer {
|
|
|
7430
8178
|
}
|
|
7431
8179
|
return width;
|
|
7432
8180
|
}
|
|
7433
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.
|
|
7434
|
-
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "21.
|
|
8181
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: DatagridHeaderRenderer, deps: [{ token: i0.ElementRef }, { token: i0.Renderer2 }, { token: DatagridRenderOrganizer }, { token: i2.DomAdapter }, { token: ColumnResizerService }, { token: ColumnsService }, { token: COLUMN_STATE }], target: i0.ɵɵFactoryTarget.Directive }); }
|
|
8182
|
+
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "21.2.25", type: DatagridHeaderRenderer, isStandalone: false, selector: "clr-dg-column", outputs: { resizeEmitter: "clrDgColumnResize" }, providers: [ColumnResizerService, COLUMN_STATE_PROVIDER], ngImport: i0 }); }
|
|
7435
8183
|
}
|
|
7436
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.
|
|
8184
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: DatagridHeaderRenderer, decorators: [{
|
|
7437
8185
|
type: Directive,
|
|
7438
8186
|
args: [{
|
|
7439
8187
|
selector: 'clr-dg-column',
|
|
@@ -7487,10 +8235,10 @@ class NoopDomAdapter {
|
|
|
7487
8235
|
focus(_element) {
|
|
7488
8236
|
// Do nothing
|
|
7489
8237
|
}
|
|
7490
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.
|
|
7491
|
-
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.
|
|
8238
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: NoopDomAdapter, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
|
|
8239
|
+
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: NoopDomAdapter }); }
|
|
7492
8240
|
}
|
|
7493
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.
|
|
8241
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: NoopDomAdapter, decorators: [{
|
|
7494
8242
|
type: Injectable
|
|
7495
8243
|
}] });
|
|
7496
8244
|
|
|
@@ -7784,10 +8532,10 @@ class DatagridMainRenderer {
|
|
|
7784
8532
|
}
|
|
7785
8533
|
});
|
|
7786
8534
|
}
|
|
7787
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.
|
|
7788
|
-
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "21.
|
|
8535
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: DatagridMainRenderer, deps: [{ token: ClrDatagrid }, { token: DatagridRenderOrganizer }, { token: Items }, { token: Page }, { token: i0.ElementRef }, { token: i0.Renderer2 }, { token: DetailService }, { token: TableSizeService }, { token: ColumnsService }, { token: i0.NgZone }, { token: KeyNavigationGridController }, { token: i0.ChangeDetectorRef }], target: i0.ɵɵFactoryTarget.Directive }); }
|
|
8536
|
+
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "21.2.25", type: DatagridMainRenderer, isStandalone: false, selector: "clr-datagrid", providers: [{ provide: DomAdapter, useFactory: domAdapterFactory, deps: [PLATFORM_ID] }], queries: [{ propertyName: "headers", predicate: DatagridHeaderRenderer }, { propertyName: "rows", predicate: DatagridRowRenderer }], ngImport: i0 }); }
|
|
7789
8537
|
}
|
|
7790
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.
|
|
8538
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: DatagridMainRenderer, decorators: [{
|
|
7791
8539
|
type: Directive,
|
|
7792
8540
|
args: [{
|
|
7793
8541
|
selector: 'clr-datagrid',
|
|
@@ -7818,10 +8566,10 @@ class DatagridRowDetailRenderer extends DatagridRowRenderer {
|
|
|
7818
8566
|
this.parentRow.expandableRows = [];
|
|
7819
8567
|
super.ngOnDestroy();
|
|
7820
8568
|
}
|
|
7821
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.
|
|
7822
|
-
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "21.
|
|
8569
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: DatagridRowDetailRenderer, deps: [{ token: DatagridRowRenderer }, { token: ColumnsService }, { token: i0.ElementRef }], target: i0.ɵɵFactoryTarget.Directive }); }
|
|
8570
|
+
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "21.2.25", type: DatagridRowDetailRenderer, isStandalone: false, selector: "clr-dg-row-detail", usesInheritance: true, ngImport: i0 }); }
|
|
7823
8571
|
}
|
|
7824
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.
|
|
8572
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: DatagridRowDetailRenderer, decorators: [{
|
|
7825
8573
|
type: Directive,
|
|
7826
8574
|
args: [{
|
|
7827
8575
|
selector: 'clr-dg-row-detail',
|
|
@@ -7842,6 +8590,8 @@ const CLR_DATAGRID_DIRECTIVES = [
|
|
|
7842
8590
|
ClrDatagridActionOverflow,
|
|
7843
8591
|
ClrDatagridCell,
|
|
7844
8592
|
ClrDatagridColumn,
|
|
8593
|
+
ClrDatagridColumnAction,
|
|
8594
|
+
ClrDatagridColumnActions,
|
|
7845
8595
|
ClrDatagridColumnSeparator,
|
|
7846
8596
|
ClrDatagridDetail,
|
|
7847
8597
|
ClrDatagridDetailBody,
|
|
@@ -7881,20 +8631,18 @@ const CLR_DATAGRID_STANDALONE_DIRECTIVES = [ClrDatagridSingleSelectionValueAcces
|
|
|
7881
8631
|
const CLR_DATAGRID_SHARED_DIRECTIVES = [ClrIfExpanded];
|
|
7882
8632
|
class ClrDatagridModule {
|
|
7883
8633
|
constructor() {
|
|
7884
|
-
ClarityIcons.addIcons(ellipsisVerticalIcon, viewColumnsIcon, windowCloseIcon, arrowIcon, timesIcon, twoWayArrowsIcon, stepForward2Icon, angleDoubleIcon, filterGridCircleIcon, filterGridIcon
|
|
7885
|
-
|
|
7886
|
-
|
|
7887
|
-
|
|
7888
|
-
);
|
|
7889
|
-
}
|
|
7890
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.1.3", ngImport: i0, type: ClrDatagridModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
|
|
7891
|
-
static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "21.1.3", ngImport: i0, type: ClrDatagridModule, declarations: [
|
|
8634
|
+
ClarityIcons.addIcons(ellipsisVerticalIcon, ellipsisGridCircleIcon, viewColumnsIcon, windowCloseIcon, arrowIcon, timesIcon, twoWayArrowsIcon, stepForward2Icon, angleDoubleIcon, filterGridCircleIcon, filterGridIcon, pinIcon, unpinIcon);
|
|
8635
|
+
}
|
|
8636
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: ClrDatagridModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
|
|
8637
|
+
static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "21.2.25", ngImport: i0, type: ClrDatagridModule, declarations: [
|
|
7892
8638
|
// Core
|
|
7893
8639
|
ClrDatagrid,
|
|
7894
8640
|
ClrDatagridActionBar,
|
|
7895
8641
|
ClrDatagridActionOverflow,
|
|
7896
8642
|
ClrDatagridCell,
|
|
7897
8643
|
ClrDatagridColumn,
|
|
8644
|
+
ClrDatagridColumnAction,
|
|
8645
|
+
ClrDatagridColumnActions,
|
|
7898
8646
|
ClrDatagridColumnSeparator,
|
|
7899
8647
|
ClrDatagridDetail,
|
|
7900
8648
|
ClrDatagridDetailBody,
|
|
@@ -7943,6 +8691,7 @@ class ClrDatagridModule {
|
|
|
7943
8691
|
ClrExpandableAnimationModule,
|
|
7944
8692
|
ClrSpinnerModule,
|
|
7945
8693
|
ClrPopoverModuleNext,
|
|
8694
|
+
ClrDropdownModule,
|
|
7946
8695
|
ClrKeyFocusModule, ClrDatagridSingleSelectionValueAccessor, ClrIfExpanded], exports: [
|
|
7947
8696
|
// Core
|
|
7948
8697
|
ClrDatagrid,
|
|
@@ -7950,6 +8699,8 @@ class ClrDatagridModule {
|
|
|
7950
8699
|
ClrDatagridActionOverflow,
|
|
7951
8700
|
ClrDatagridCell,
|
|
7952
8701
|
ClrDatagridColumn,
|
|
8702
|
+
ClrDatagridColumnAction,
|
|
8703
|
+
ClrDatagridColumnActions,
|
|
7953
8704
|
ClrDatagridColumnSeparator,
|
|
7954
8705
|
ClrDatagridDetail,
|
|
7955
8706
|
ClrDatagridDetailBody,
|
|
@@ -7983,7 +8734,7 @@ class ClrDatagridModule {
|
|
|
7983
8734
|
// Built-in shortcuts
|
|
7984
8735
|
DatagridNumericFilter,
|
|
7985
8736
|
DatagridStringFilter, ClrDatagridSingleSelectionValueAccessor, ClrIfExpanded] }); }
|
|
7986
|
-
static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "21.
|
|
8737
|
+
static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: ClrDatagridModule, imports: [CommonModule,
|
|
7987
8738
|
CdkDragModule,
|
|
7988
8739
|
CdkTrapFocusModule,
|
|
7989
8740
|
ClrIcon,
|
|
@@ -7999,9 +8750,10 @@ class ClrDatagridModule {
|
|
|
7999
8750
|
ClrExpandableAnimationModule,
|
|
8000
8751
|
ClrSpinnerModule,
|
|
8001
8752
|
ClrPopoverModuleNext,
|
|
8753
|
+
ClrDropdownModule,
|
|
8002
8754
|
ClrKeyFocusModule] }); }
|
|
8003
8755
|
}
|
|
8004
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.
|
|
8756
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: ClrDatagridModule, decorators: [{
|
|
8005
8757
|
type: NgModule,
|
|
8006
8758
|
args: [{
|
|
8007
8759
|
imports: [
|
|
@@ -8021,6 +8773,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.1.3", ngImpor
|
|
|
8021
8773
|
ClrExpandableAnimationModule,
|
|
8022
8774
|
ClrSpinnerModule,
|
|
8023
8775
|
ClrPopoverModuleNext,
|
|
8776
|
+
ClrDropdownModule,
|
|
8024
8777
|
ClrKeyFocusModule,
|
|
8025
8778
|
CLR_DATAGRID_STANDALONE_DIRECTIVES,
|
|
8026
8779
|
CLR_DATAGRID_SHARED_DIRECTIVES,
|
|
@@ -8041,5 +8794,5 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.1.3", ngImpor
|
|
|
8041
8794
|
* Generated bundle index. Do not edit.
|
|
8042
8795
|
*/
|
|
8043
8796
|
|
|
8044
|
-
export { ActionableOompaLoompa, CLR_DATAGRID_DIRECTIVES, ClrDatagrid, ClrDatagridActionBar, ClrDatagridActionOverflow, ClrDatagridAriaSortOrder, ClrDatagridCell, ClrDatagridColumn, ClrDatagridColumnSeparator, ClrDatagridColumnToggle, ClrDatagridColumnToggleButton, ClrDatagridDetail, ClrDatagridDetailBody, ClrDatagridDetailHeader, ClrDatagridFilter, ClrDatagridFooter, ClrDatagridHideableColumn, ClrDatagridItems, ClrDatagridModule, ClrDatagridPageSize, ClrDatagridPagination, ClrDatagridPlaceholder, ClrDatagridRow, ClrDatagridRowDetail, ClrDatagridSelectionCellDirective, ClrDatagridSingleSelectionValueAccessor, ClrDatagridSortOrder, ClrDatagridVirtualScrollDirective, ClrIfDetail, DatagridCellRenderer, DatagridDetailRegisterer, DatagridHeaderRenderer, DatagridMainRenderer, DatagridNumericFilter, DatagridPropertyComparator, DatagridPropertyNumericFilter, DatagridPropertyStringFilter, DatagridRowDetailRenderer, DatagridRowRenderer, DatagridStringFilter, DatagridWillyWonka, ExpandableOompaLoompa, Selection, SelectionType, WrappedCell, WrappedColumn, WrappedRow, selectionTypeAttribute };
|
|
8797
|
+
export { ActionableOompaLoompa, CLR_DATAGRID_DIRECTIVES, ClrDatagrid, ClrDatagridActionBar, ClrDatagridActionOverflow, ClrDatagridAriaSortOrder, ClrDatagridCell, ClrDatagridColumn, ClrDatagridColumnAction, ClrDatagridColumnActions, ClrDatagridColumnSeparator, ClrDatagridColumnToggle, ClrDatagridColumnToggleButton, ClrDatagridDetail, ClrDatagridDetailBody, ClrDatagridDetailHeader, ClrDatagridFilter, ClrDatagridFooter, ClrDatagridHideableColumn, ClrDatagridItems, ClrDatagridModule, ClrDatagridPageSize, ClrDatagridPagination, ClrDatagridPlaceholder, ClrDatagridRow, ClrDatagridRowDetail, ClrDatagridSelectionCellDirective, ClrDatagridSingleSelectionValueAccessor, ClrDatagridSortOrder, ClrDatagridVirtualScrollDirective, ClrIfDetail, DatagridCellRenderer, DatagridDetailRegisterer, DatagridHeaderRenderer, DatagridMainRenderer, DatagridNumericFilter, DatagridPropertyComparator, DatagridPropertyNumericFilter, DatagridPropertyStringFilter, DatagridRowDetailRenderer, DatagridRowRenderer, DatagridStringFilter, DatagridWillyWonka, ExpandableOompaLoompa, Selection, SelectionType, WrappedCell, WrappedColumn, WrappedRow, selectionTypeAttribute };
|
|
8045
8798
|
//# sourceMappingURL=clr-angular-data-datagrid.mjs.map
|