@clr/angular 17.2.1 → 17.3.1
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/accordion/stepper/stepper-panel.d.ts +1 -1
- package/button/button-loading/loading-button.d.ts +2 -2
- package/clarity.api.md +98 -72
- package/data/datagrid/built-in/filters/datagrid-numeric-filter.d.ts +1 -1
- package/data/datagrid/built-in/filters/datagrid-string-filter.d.ts +1 -1
- package/data/datagrid/datagrid-action-overflow.d.ts +2 -3
- package/data/datagrid/datagrid-detail-header.d.ts +1 -1
- package/data/datagrid/datagrid-filter.d.ts +1 -1
- package/data/datagrid/datagrid-hideable-column.d.ts +0 -1
- package/data/datagrid/datagrid-items.d.ts +0 -1
- package/data/datagrid/datagrid-pagination.d.ts +1 -1
- package/data/datagrid/datagrid-row.d.ts +5 -5
- package/data/datagrid/datagrid.d.ts +8 -5
- package/data/datagrid/providers/column-resizer.service.d.ts +1 -1
- package/data/datagrid/providers/selection.d.ts +1 -2
- package/data/datagrid/providers/table-size.service.d.ts +1 -1
- package/data/datagrid/render/cell-renderer.d.ts +1 -1
- package/data/datagrid/render/header-renderer.d.ts +1 -2
- package/data/datagrid/render/main-renderer.d.ts +4 -3
- package/data/datagrid/render/row-renderer.d.ts +2 -1
- package/data/tree-view/tree.d.ts +5 -1
- package/emphasis/alert/alert.d.ts +1 -1
- package/esm2020/accordion/stepper/stepper-panel.mjs +5 -4
- package/esm2020/button/button-loading/loading-button.mjs +1 -1
- package/esm2020/data/datagrid/built-in/filters/datagrid-numeric-filter.mjs +1 -1
- package/esm2020/data/datagrid/built-in/filters/datagrid-string-filter.mjs +1 -1
- package/esm2020/data/datagrid/datagrid-action-overflow.mjs +8 -9
- package/esm2020/data/datagrid/datagrid-column-separator.mjs +1 -1
- package/esm2020/data/datagrid/datagrid-detail-header.mjs +1 -1
- package/esm2020/data/datagrid/datagrid-detail-registerer.mjs +3 -3
- package/esm2020/data/datagrid/datagrid-filter.mjs +1 -1
- package/esm2020/data/datagrid/datagrid-hideable-column.mjs +3 -4
- package/esm2020/data/datagrid/datagrid-if-detail.mjs +2 -2
- package/esm2020/data/datagrid/datagrid-items.mjs +2 -3
- package/esm2020/data/datagrid/datagrid-pagination.mjs +3 -3
- package/esm2020/data/datagrid/datagrid-placeholder.mjs +5 -5
- package/esm2020/data/datagrid/datagrid-row.mjs +15 -9
- package/esm2020/data/datagrid/datagrid-virtual-scroll.directive.mjs +5 -5
- package/esm2020/data/datagrid/datagrid.mjs +51 -42
- package/esm2020/data/datagrid/providers/column-resizer.service.mjs +1 -1
- package/esm2020/data/datagrid/providers/selection.mjs +11 -12
- package/esm2020/data/datagrid/providers/table-size.service.mjs +1 -1
- package/esm2020/data/datagrid/render/cell-renderer.mjs +1 -1
- package/esm2020/data/datagrid/render/header-renderer.mjs +2 -3
- package/esm2020/data/datagrid/render/main-renderer.mjs +30 -19
- package/esm2020/data/datagrid/render/row-renderer.mjs +6 -3
- package/esm2020/data/datagrid/utils/key-navigation-grid.controller.mjs +2 -2
- package/esm2020/data/stack-view/stack-block.mjs +4 -2
- package/esm2020/data/tree-view/recursive-children.mjs +3 -3
- package/esm2020/data/tree-view/tree-node.mjs +5 -5
- package/esm2020/data/tree-view/tree.mjs +24 -11
- package/esm2020/emphasis/alert/alert.mjs +1 -1
- package/esm2020/forms/checkbox/checkbox-container.mjs +9 -5
- package/esm2020/forms/checkbox/checkbox.mjs +1 -1
- package/esm2020/forms/combobox/combobox-container.mjs +1 -1
- package/esm2020/forms/combobox/combobox.mjs +2 -2
- package/esm2020/forms/combobox/option-items.directive.mjs +2 -3
- package/esm2020/forms/combobox/option.mjs +6 -5
- package/esm2020/forms/combobox/options.mjs +1 -1
- package/esm2020/forms/combobox/providers/combobox-focus-handler.service.mjs +1 -1
- package/esm2020/forms/common/abstract-container.mjs +3 -3
- package/esm2020/forms/common/control.mjs +1 -1
- package/esm2020/forms/common/if-control-state/abstract-if-state.mjs +3 -3
- package/esm2020/forms/common/if-control-state/if-control-state.service.mjs +2 -3
- package/esm2020/forms/common/label.mjs +1 -1
- package/esm2020/forms/common/wrapped-control.mjs +3 -3
- package/esm2020/forms/datalist/datalist-container.mjs +2 -3
- package/esm2020/forms/datalist/datalist-input.mjs +2 -2
- package/esm2020/forms/datepicker/calendar.mjs +1 -1
- package/esm2020/forms/datepicker/date-container.mjs +4 -5
- package/esm2020/forms/datepicker/date-input.mjs +1 -1
- package/esm2020/forms/datepicker/monthpicker.mjs +1 -1
- package/esm2020/forms/datepicker/providers/date-io.service.mjs +3 -4
- package/esm2020/forms/datepicker/providers/datepicker-enabled.service.mjs +2 -2
- package/esm2020/forms/datepicker/providers/datepicker-focus.service.mjs +1 -1
- package/esm2020/forms/datepicker/yearpicker.mjs +1 -1
- package/esm2020/forms/input/input.mjs +1 -1
- package/esm2020/forms/password/password-container.mjs +2 -2
- package/esm2020/forms/password/password.mjs +3 -4
- package/esm2020/forms/radio/radio-container.mjs +9 -5
- package/esm2020/forms/radio/radio.mjs +1 -1
- package/esm2020/forms/range/range.mjs +1 -1
- package/esm2020/forms/select/select.mjs +1 -1
- package/esm2020/forms/textarea/textarea.mjs +1 -1
- package/esm2020/layout/main-container/main-container.mjs +1 -1
- package/esm2020/layout/nav/header.mjs +3 -3
- package/esm2020/layout/nav/nav-level.mjs +16 -12
- package/esm2020/layout/tabs/tab-link.directive.mjs +4 -6
- package/esm2020/layout/tabs/tabs.mjs +1 -1
- package/esm2020/layout/vertical-nav/vertical-nav-group.mjs +8 -9
- package/esm2020/layout/vertical-nav/vertical-nav-icon.mjs +2 -2
- package/esm2020/layout/vertical-nav/vertical-nav.mjs +2 -2
- package/esm2020/modal/index.mjs +2 -1
- package/esm2020/modal/modal-body.mjs +4 -4
- package/esm2020/modal/modal-configuration.service.mjs +4 -3
- package/esm2020/modal/modal.mjs +15 -5
- package/esm2020/modal/modal.module.mjs +2 -4
- package/esm2020/modal/side-panel.mjs +4 -2
- package/esm2020/popover/common/abstract-popover.mjs +1 -1
- package/esm2020/popover/dropdown/dropdown.mjs +3 -4
- package/esm2020/popover/dropdown/providers/dropdown-focus-handler.service.mjs +2 -2
- package/esm2020/popover/signpost/signpost-content.mjs +2 -3
- package/esm2020/popover/signpost/signpost-trigger.mjs +1 -1
- package/esm2020/popover/tooltip/tooltip-content.mjs +1 -1
- package/esm2020/popover/tooltip/tooltip-trigger.mjs +2 -3
- package/esm2020/timeline/timeline-step.mjs +1 -1
- package/esm2020/utils/animations/expandable-animation/expandable-animation.mjs +1 -1
- package/esm2020/utils/cdk/cdk-drag.module.mjs +1 -1
- package/esm2020/utils/cdk/cdk-trap-focus.module.mjs +1 -1
- package/esm2020/utils/conditional/if-active.directive.mjs +2 -2
- package/esm2020/utils/conditional/if-expanded.directive.mjs +2 -2
- package/esm2020/utils/conditional/if-open.directive.mjs +2 -2
- package/esm2020/utils/focus/focus-on-view-init/focus-on-view-init.mjs +4 -4
- package/esm2020/utils/focus/focus-trap/standalone-cdk-trap-focus.directive.mjs +1 -1
- package/esm2020/utils/focus/key-focus/key-focus-item.mjs +1 -1
- package/esm2020/utils/focus/key-focus/key-focus.mjs +1 -1
- package/esm2020/utils/focus/key-focus/roving-tabindex.mjs +1 -1
- package/esm2020/utils/i18n/common-strings.default.mjs +4 -1
- package/esm2020/utils/i18n/common-strings.interface.mjs +1 -1
- package/esm2020/utils/popover/popover-anchor.mjs +1 -1
- package/esm2020/utils/popover/popover-close-button.mjs +1 -1
- package/esm2020/utils/popover/popover-content.mjs +10 -4
- package/esm2020/utils/popover/popover-open-close-button.mjs +2 -2
- package/esm2020/utils/popover/providers/popover-events.service.mjs +1 -1
- package/esm2020/wizard/providers/wizard-navigation.service.mjs +8 -8
- package/esm2020/wizard/wizard-stepnav-item.mjs +13 -19
- package/esm2020/wizard/wizard.mjs +3 -3
- package/esm2020/wizard/wizard.module.mjs +3 -3
- package/fesm2015/clr-angular.mjs +293 -233
- package/fesm2015/clr-angular.mjs.map +1 -1
- package/fesm2020/clr-angular.mjs +290 -233
- package/fesm2020/clr-angular.mjs.map +1 -1
- package/forms/checkbox/checkbox.d.ts +1 -1
- package/forms/combobox/combobox-container.d.ts +2 -2
- package/forms/combobox/combobox.d.ts +4 -4
- package/forms/combobox/option-items.directive.d.ts +0 -1
- package/forms/combobox/option.d.ts +3 -3
- package/forms/combobox/options.d.ts +1 -1
- package/forms/combobox/providers/combobox-focus-handler.service.d.ts +1 -1
- package/forms/common/control.d.ts +1 -1
- package/forms/common/if-control-state/if-control-state.service.d.ts +0 -1
- package/forms/common/label.d.ts +1 -1
- package/forms/common/wrapped-control.d.ts +3 -3
- package/forms/datalist/datalist-container.d.ts +0 -1
- package/forms/datalist/datalist-input.d.ts +1 -1
- package/forms/datepicker/calendar.d.ts +1 -1
- package/forms/datepicker/date-container.d.ts +1 -2
- package/forms/datepicker/date-input.d.ts +2 -2
- package/forms/datepicker/monthpicker.d.ts +1 -1
- package/forms/datepicker/providers/date-io.service.d.ts +1 -2
- package/forms/datepicker/providers/datepicker-focus.service.d.ts +1 -1
- package/forms/datepicker/yearpicker.d.ts +1 -1
- package/forms/input/input.d.ts +1 -1
- package/forms/password/password.d.ts +1 -2
- package/forms/radio/radio.d.ts +1 -1
- package/forms/range/range.d.ts +1 -1
- package/forms/select/select.d.ts +1 -1
- package/forms/textarea/textarea.d.ts +1 -1
- package/layout/main-container/main-container.d.ts +1 -1
- package/layout/nav/nav-level.d.ts +0 -1
- package/layout/tabs/tab-link.directive.d.ts +2 -4
- package/layout/tabs/tabs.d.ts +1 -1
- package/layout/vertical-nav/vertical-nav-group.d.ts +1 -2
- package/modal/index.d.ts +1 -0
- package/modal/modal.d.ts +3 -1
- package/modal/side-panel.d.ts +1 -1
- package/package.json +5 -5
- package/popover/common/abstract-popover.d.ts +3 -3
- package/popover/dropdown/dropdown.d.ts +0 -1
- package/popover/signpost/signpost-content.d.ts +1 -2
- package/popover/signpost/signpost-trigger.d.ts +1 -1
- package/popover/tooltip/tooltip-content.d.ts +1 -1
- package/popover/tooltip/tooltip-trigger.d.ts +0 -1
- package/src/utils/popover/README.md +1 -1
- package/timeline/timeline-step.d.ts +1 -1
- package/utils/animations/expandable-animation/expandable-animation.d.ts +1 -1
- package/utils/cdk/cdk-drag.module.d.ts +1 -1
- package/utils/cdk/cdk-trap-focus.module.d.ts +1 -1
- package/utils/conditional/if-expanded.directive.d.ts +1 -1
- package/utils/focus/focus-on-view-init/focus-on-view-init.d.ts +1 -1
- package/utils/focus/focus-trap/standalone-cdk-trap-focus.directive.d.ts +1 -1
- package/utils/focus/key-focus/key-focus-item.d.ts +2 -2
- package/utils/focus/key-focus/key-focus.d.ts +1 -1
- package/utils/focus/key-focus/roving-tabindex.d.ts +1 -1
- package/utils/i18n/common-strings.interface.d.ts +2 -0
- package/utils/popover/popover-anchor.d.ts +1 -1
- package/utils/popover/popover-close-button.d.ts +1 -1
- package/utils/popover/popover-content.d.ts +1 -0
- package/utils/popover/providers/popover-events.service.d.ts +3 -3
- package/wizard/wizard.d.ts +1 -1
package/fesm2015/clr-angular.mjs
CHANGED
|
@@ -19,7 +19,6 @@ import { _RecycleViewRepeaterStrategy } from '@angular/cdk/collections';
|
|
|
19
19
|
import * as i3$1 from '@angular/cdk/scrolling';
|
|
20
20
|
import { FixedSizeVirtualScrollStrategy, CdkVirtualForOf, CdkVirtualScrollViewport } from '@angular/cdk/scrolling';
|
|
21
21
|
import * as i1$3 from '@angular/router';
|
|
22
|
-
import '@cds/core/internal-components/close-button/register.js';
|
|
23
22
|
import '@cds/core/icon/register';
|
|
24
23
|
|
|
25
24
|
/*
|
|
@@ -397,6 +396,9 @@ const commonStringsDefault = {
|
|
|
397
396
|
fileCount: '{COUNT} files',
|
|
398
397
|
clearFile: 'Clear {FILE}',
|
|
399
398
|
clearFiles: 'Clear {COUNT} files',
|
|
399
|
+
// Tree
|
|
400
|
+
selectedTreeNode: 'selected',
|
|
401
|
+
unselectedTreeNode: 'unselected',
|
|
400
402
|
};
|
|
401
403
|
|
|
402
404
|
/*
|
|
@@ -1164,6 +1166,9 @@ class ClrStepperPanel extends ClrAccordionPanel {
|
|
|
1164
1166
|
// set panel status on form status change only after the form becomes invalid
|
|
1165
1167
|
const invalidStatusTrigger = this.formGroup.statusChanges.pipe(filter(status => status === 'INVALID'));
|
|
1166
1168
|
this.subscriptions.push(this.formGroup.statusChanges.pipe(skipUntil(invalidStatusTrigger), distinctUntilChanged()).subscribe(status => {
|
|
1169
|
+
if (!this.formGroup.touched) {
|
|
1170
|
+
return;
|
|
1171
|
+
}
|
|
1167
1172
|
if (status === 'VALID') {
|
|
1168
1173
|
this.stepperService.setPanelValid(this.id);
|
|
1169
1174
|
}
|
|
@@ -1180,9 +1185,7 @@ class ClrStepperPanel extends ClrAccordionPanel {
|
|
|
1180
1185
|
this.subscriptions.push(this.stepperService.activeStep
|
|
1181
1186
|
.pipe(filter(panelId => isPlatformBrowser(this.platformId) && panelId === this.id))
|
|
1182
1187
|
.subscribe(() => {
|
|
1183
|
-
|
|
1184
|
-
//before focusing on the next stepper panel header
|
|
1185
|
-
setTimeout(() => this.headerButton.nativeElement.focus(), 1500);
|
|
1188
|
+
this.headerButton.nativeElement.focus();
|
|
1186
1189
|
}));
|
|
1187
1190
|
}
|
|
1188
1191
|
triggerAllFormControlValidationIfError(panel) {
|
|
@@ -2232,6 +2235,7 @@ class ClrPopoverContent {
|
|
|
2232
2235
|
this.subscriptions = [];
|
|
2233
2236
|
this.removeClickListenerFn = null;
|
|
2234
2237
|
this.shouldRealign = false;
|
|
2238
|
+
this.previousContentHeight = null;
|
|
2235
2239
|
// Check-collector pattern:
|
|
2236
2240
|
// In order to get accurate content height/width values, we cannot calculate alignment offsets until
|
|
2237
2241
|
// after the projected content has stabilized.
|
|
@@ -2253,9 +2257,14 @@ class ClrPopoverContent {
|
|
|
2253
2257
|
this.smartEventsService.scrollToClose = !!scrollToClose;
|
|
2254
2258
|
}
|
|
2255
2259
|
ngAfterContentChecked() {
|
|
2256
|
-
if (this.smartOpenService.open && this.view
|
|
2257
|
-
|
|
2258
|
-
this.
|
|
2260
|
+
if (this.smartOpenService.open && this.view) {
|
|
2261
|
+
const rootNodeOffsetHeight = this.view.rootNodes[0].offsetHeight;
|
|
2262
|
+
if (this.shouldRealign ||
|
|
2263
|
+
(this.previousContentHeight !== null && this.previousContentHeight !== rootNodeOffsetHeight)) {
|
|
2264
|
+
// Channel content-check event through the check-collector
|
|
2265
|
+
this.previousContentHeight = rootNodeOffsetHeight;
|
|
2266
|
+
this.checkCollector.emit();
|
|
2267
|
+
}
|
|
2259
2268
|
}
|
|
2260
2269
|
}
|
|
2261
2270
|
ngAfterViewInit() {
|
|
@@ -2373,7 +2382,7 @@ class ClrPopoverOpenCloseButton {
|
|
|
2373
2382
|
this.smartOpenService = smartOpenService;
|
|
2374
2383
|
this.openCloseChange = new EventEmitter();
|
|
2375
2384
|
this.subscriptions = [];
|
|
2376
|
-
this.subscriptions.push(
|
|
2385
|
+
this.subscriptions.push(smartOpenService.openChange.subscribe(change => {
|
|
2377
2386
|
this.openCloseChange.next(change);
|
|
2378
2387
|
}));
|
|
2379
2388
|
}
|
|
@@ -3329,7 +3338,7 @@ class ClrIfActive {
|
|
|
3329
3338
|
this.activeChange = new EventEmitter(false);
|
|
3330
3339
|
this.wasActive = false;
|
|
3331
3340
|
this.checkAndUpdateView(ifActiveService.current);
|
|
3332
|
-
this.subscription =
|
|
3341
|
+
this.subscription = ifActiveService.currentChange.subscribe(newCurrentId => {
|
|
3333
3342
|
this.checkAndUpdateView(newCurrentId);
|
|
3334
3343
|
});
|
|
3335
3344
|
}
|
|
@@ -3421,7 +3430,7 @@ class ClrIfOpen {
|
|
|
3421
3430
|
* used with de-structured / de-sugared syntax.
|
|
3422
3431
|
*/
|
|
3423
3432
|
this.openChange = new EventEmitter(false);
|
|
3424
|
-
this.subscription =
|
|
3433
|
+
this.subscription = toggleService.openChange.subscribe(change => {
|
|
3425
3434
|
this.updateView(change);
|
|
3426
3435
|
this.openChange.emit(change);
|
|
3427
3436
|
});
|
|
@@ -3491,7 +3500,7 @@ class ClrIfExpanded {
|
|
|
3491
3500
|
this._subscriptions = [];
|
|
3492
3501
|
this._subscriptions.push(expand.expandChange.subscribe(() => {
|
|
3493
3502
|
this.updateView();
|
|
3494
|
-
this.expandedChange.emit(
|
|
3503
|
+
this.expandedChange.emit(expand.expanded);
|
|
3495
3504
|
}));
|
|
3496
3505
|
}
|
|
3497
3506
|
get expanded() {
|
|
@@ -3636,7 +3645,7 @@ class ClrFocusOnViewInit {
|
|
|
3636
3645
|
this.renderer = renderer;
|
|
3637
3646
|
this.directFocus = true; // true if the element gets focused without need to set tabindex;
|
|
3638
3647
|
this.destroy$ = new Subject();
|
|
3639
|
-
this._isEnabled =
|
|
3648
|
+
this._isEnabled = focusOnViewInit;
|
|
3640
3649
|
// Angular compiler doesn't understand the type Document
|
|
3641
3650
|
// when working out the metadata for injectable parameters,
|
|
3642
3651
|
// even though it understands the injection token DOCUMENT
|
|
@@ -3647,8 +3656,8 @@ class ClrFocusOnViewInit {
|
|
|
3647
3656
|
.subscribe(() => {
|
|
3648
3657
|
if (!this.directFocus) {
|
|
3649
3658
|
// manually set attributes and styles should be removed
|
|
3650
|
-
|
|
3651
|
-
|
|
3659
|
+
renderer.removeAttribute(el.nativeElement, 'tabindex');
|
|
3660
|
+
renderer.setStyle(el.nativeElement, 'outline', null);
|
|
3652
3661
|
}
|
|
3653
3662
|
}));
|
|
3654
3663
|
}
|
|
@@ -4508,12 +4517,11 @@ var CONTROL_STATE;
|
|
|
4508
4517
|
})(CONTROL_STATE || (CONTROL_STATE = {}));
|
|
4509
4518
|
class IfControlStateService {
|
|
4510
4519
|
constructor(ngControlService) {
|
|
4511
|
-
this.ngControlService = ngControlService;
|
|
4512
4520
|
this.subscriptions = [];
|
|
4513
4521
|
// Implement our own status changes observable, since Angular controls don't
|
|
4514
4522
|
this._statusChanges = new BehaviorSubject(CONTROL_STATE.NONE);
|
|
4515
4523
|
// Wait for the control to be available
|
|
4516
|
-
this.subscriptions.push(
|
|
4524
|
+
this.subscriptions.push(ngControlService.controlChanges.subscribe(control => {
|
|
4517
4525
|
if (control) {
|
|
4518
4526
|
this.control = control;
|
|
4519
4527
|
// Subscribe to the status change events, only after touched
|
|
@@ -4769,14 +4777,14 @@ class ClrAbstractContainer {
|
|
|
4769
4777
|
this.ngControlService = ngControlService;
|
|
4770
4778
|
this._dynamic = false;
|
|
4771
4779
|
this.subscriptions = [];
|
|
4772
|
-
this.subscriptions.push(
|
|
4780
|
+
this.subscriptions.push(ifControlStateService.statusChanges.subscribe((state) => {
|
|
4773
4781
|
this.state = state;
|
|
4774
4782
|
// Make sure everything is updated before dispatching the values for helpers
|
|
4775
4783
|
setTimeout(() => {
|
|
4776
4784
|
this.updateHelpers();
|
|
4777
4785
|
});
|
|
4778
4786
|
}));
|
|
4779
|
-
this.subscriptions.push(
|
|
4787
|
+
this.subscriptions.push(ngControlService.controlChanges.subscribe(control => {
|
|
4780
4788
|
this.control = control;
|
|
4781
4789
|
}));
|
|
4782
4790
|
}
|
|
@@ -5032,10 +5040,10 @@ class WrappedFormControl {
|
|
|
5032
5040
|
this.vcr = vcr;
|
|
5033
5041
|
this.wrapperType = wrapperType;
|
|
5034
5042
|
this.ngControl = ngControl;
|
|
5035
|
-
this.index = 0;
|
|
5036
|
-
this.subscriptions = [];
|
|
5037
5043
|
this.renderer = renderer;
|
|
5038
5044
|
this.el = el;
|
|
5045
|
+
this.index = 0;
|
|
5046
|
+
this.subscriptions = [];
|
|
5039
5047
|
if (injector) {
|
|
5040
5048
|
this.ngControlService = injector.get(NgControlService, null);
|
|
5041
5049
|
this.ifControlStateService = injector.get(IfControlStateService, null);
|
|
@@ -5259,12 +5267,12 @@ class AbstractIfState {
|
|
|
5259
5267
|
this.subscriptions = [];
|
|
5260
5268
|
this.displayedContent = false;
|
|
5261
5269
|
if (ngControlService) {
|
|
5262
|
-
this.subscriptions.push(
|
|
5270
|
+
this.subscriptions.push(ngControlService.controlChanges.subscribe(control => {
|
|
5263
5271
|
this.control = control;
|
|
5264
5272
|
}));
|
|
5265
5273
|
}
|
|
5266
5274
|
if (ifControlStateService) {
|
|
5267
|
-
this.subscriptions.push(
|
|
5275
|
+
this.subscriptions.push(ifControlStateService.statusChanges.subscribe((state) => {
|
|
5268
5276
|
this.handleState(state);
|
|
5269
5277
|
}));
|
|
5270
5278
|
}
|
|
@@ -5642,8 +5650,10 @@ ClrCheckboxContainer.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", v
|
|
|
5642
5650
|
<label *ngIf="!label && addGrid()"></label>
|
|
5643
5651
|
<div class="clr-control-container" [class.clr-control-inline]="clrInline" [ngClass]="controlClass()">
|
|
5644
5652
|
<ng-content select="clr-checkbox-wrapper,clr-toggle-wrapper"></ng-content>
|
|
5645
|
-
<div class="clr-subtext-wrapper">
|
|
5646
|
-
<ng-content select="clr-control-helper"
|
|
5653
|
+
<div *ngIf="showHelper" class="clr-subtext-wrapper">
|
|
5654
|
+
<ng-content select="clr-control-helper"></ng-content>
|
|
5655
|
+
</div>
|
|
5656
|
+
<div *ngIf="showInvalid || showValid" class="clr-subtext-wrapper">
|
|
5647
5657
|
<cds-icon
|
|
5648
5658
|
*ngIf="showInvalid"
|
|
5649
5659
|
class="clr-validate-icon"
|
|
@@ -5672,8 +5682,10 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.2", ngImpor
|
|
|
5672
5682
|
<label *ngIf="!label && addGrid()"></label>
|
|
5673
5683
|
<div class="clr-control-container" [class.clr-control-inline]="clrInline" [ngClass]="controlClass()">
|
|
5674
5684
|
<ng-content select="clr-checkbox-wrapper,clr-toggle-wrapper"></ng-content>
|
|
5675
|
-
<div class="clr-subtext-wrapper">
|
|
5676
|
-
<ng-content select="clr-control-helper"
|
|
5685
|
+
<div *ngIf="showHelper" class="clr-subtext-wrapper">
|
|
5686
|
+
<ng-content select="clr-control-helper"></ng-content>
|
|
5687
|
+
</div>
|
|
5688
|
+
<div *ngIf="showInvalid || showValid" class="clr-subtext-wrapper">
|
|
5677
5689
|
<cds-icon
|
|
5678
5690
|
*ngIf="showInvalid"
|
|
5679
5691
|
class="clr-validate-icon"
|
|
@@ -6835,7 +6847,7 @@ class ClrOption {
|
|
|
6835
6847
|
this.optionSelectionService = optionSelectionService;
|
|
6836
6848
|
// A proxy with only the necessary data to be used for a11y and the focus handler service.
|
|
6837
6849
|
this.optionProxy = new OptionData(null, null);
|
|
6838
|
-
this.optionProxy.el =
|
|
6850
|
+
this.optionProxy.el = elRef.nativeElement;
|
|
6839
6851
|
}
|
|
6840
6852
|
get optionId() {
|
|
6841
6853
|
return this._id;
|
|
@@ -6863,7 +6875,8 @@ class ClrOption {
|
|
|
6863
6875
|
this.optionProxy.id = this._id;
|
|
6864
6876
|
}
|
|
6865
6877
|
}
|
|
6866
|
-
onClick() {
|
|
6878
|
+
onClick(event) {
|
|
6879
|
+
event.stopPropagation();
|
|
6867
6880
|
if (this.optionSelectionService.multiselectable) {
|
|
6868
6881
|
this.optionSelectionService.toggle(this.value);
|
|
6869
6882
|
}
|
|
@@ -6878,7 +6891,7 @@ class ClrOption {
|
|
|
6878
6891
|
}
|
|
6879
6892
|
}
|
|
6880
6893
|
ClrOption.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.2", ngImport: i0, type: ClrOption, deps: [{ token: i0.ElementRef }, { token: ClrCommonStringsService }, { token: ComboboxFocusHandler }, { token: OptionSelectionService }], target: i0.ɵɵFactoryTarget.Component });
|
|
6881
|
-
ClrOption.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.2", type: ClrOption, selector: "clr-option", inputs: { optionId: ["id", "optionId"], value: ["clrValue", "value"] }, host: { listeners: { "click": "onClick()" }, properties: { "class.clr-combobox-option": "true", "attr.role": "\"option\"", "attr.tabindex": "-1", "attr.id": "optionId", "class.active": "this.selected", "class.clr-focus": "this.focusClass" } }, ngImport: i0, template: `
|
|
6894
|
+
ClrOption.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.2", type: ClrOption, selector: "clr-option", inputs: { optionId: ["id", "optionId"], value: ["clrValue", "value"] }, host: { listeners: { "click": "onClick($event)" }, properties: { "class.clr-combobox-option": "true", "attr.role": "\"option\"", "attr.tabindex": "-1", "attr.id": "optionId", "class.active": "this.selected", "class.clr-focus": "this.focusClass" } }, ngImport: i0, template: `
|
|
6882
6895
|
<ng-content></ng-content>
|
|
6883
6896
|
<span *ngIf="selected" class="clr-sr-only">{{ commonStrings.keys.comboboxSelected }}</span>
|
|
6884
6897
|
`, isInline: true, dependencies: [{ kind: "directive", type: i5.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }] });
|
|
@@ -6912,7 +6925,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.2", ngImpor
|
|
|
6912
6925
|
args: ['class.clr-focus']
|
|
6913
6926
|
}], onClick: [{
|
|
6914
6927
|
type: HostListener,
|
|
6915
|
-
args: ['click']
|
|
6928
|
+
args: ['click', ['$event']]
|
|
6916
6929
|
}] } });
|
|
6917
6930
|
|
|
6918
6931
|
/*
|
|
@@ -7100,7 +7113,7 @@ class ClrCombobox extends WrappedFormControl {
|
|
|
7100
7113
|
control.valueAccessor = this;
|
|
7101
7114
|
}
|
|
7102
7115
|
// default to SingleSelectComboboxModel, in case the optional input [ClrMulti] isn't used
|
|
7103
|
-
|
|
7116
|
+
optionSelectionService.selectionModel = new SingleSelectComboboxModel();
|
|
7104
7117
|
this.updateControlValue();
|
|
7105
7118
|
}
|
|
7106
7119
|
get multiSelect() {
|
|
@@ -7402,11 +7415,10 @@ class ClrOptionItems {
|
|
|
7402
7415
|
this.differs = differs;
|
|
7403
7416
|
this.optionService = optionService;
|
|
7404
7417
|
this.positionService = positionService;
|
|
7405
|
-
this.vcr = vcr;
|
|
7406
7418
|
this.subscriptions = [];
|
|
7407
7419
|
this.filter = '';
|
|
7408
7420
|
this.differ = null;
|
|
7409
|
-
this.iterableProxy = new NgForOf(
|
|
7421
|
+
this.iterableProxy = new NgForOf(vcr, template, differs);
|
|
7410
7422
|
this.subscriptions.push(optionService.inputChanged.subscribe(filter => {
|
|
7411
7423
|
this.filter = filter;
|
|
7412
7424
|
this.updateItems();
|
|
@@ -7790,10 +7802,9 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.2", ngImpor
|
|
|
7790
7802
|
class ClrDatalistContainer extends ClrAbstractContainer {
|
|
7791
7803
|
constructor(controlClassService, layoutService, ngControlService, focusService, ifControlStateService) {
|
|
7792
7804
|
super(ifControlStateService, layoutService, controlClassService, ngControlService);
|
|
7793
|
-
this.focusService = focusService;
|
|
7794
7805
|
this.ifControlStateService = ifControlStateService;
|
|
7795
7806
|
this.focus = false;
|
|
7796
|
-
this.subscriptions.push(
|
|
7807
|
+
this.subscriptions.push(focusService.focusChange.subscribe(state => (this.focus = state)));
|
|
7797
7808
|
}
|
|
7798
7809
|
}
|
|
7799
7810
|
ClrDatalistContainer.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.2", ngImport: i0, type: ClrDatalistContainer, deps: [{ token: ControlClassService }, { token: LayoutService, optional: true }, { token: NgControlService }, { token: FocusService }, { token: IfControlStateService }], target: i0.ɵɵFactoryTarget.Component });
|
|
@@ -7899,7 +7910,7 @@ class ClrDatalistInput extends WrappedFormControl {
|
|
|
7899
7910
|
super(vcr, ClrDatalistContainer, injector, control, renderer, el);
|
|
7900
7911
|
this.focusService = focusService;
|
|
7901
7912
|
this.datalistIdService = datalistIdService;
|
|
7902
|
-
if (!
|
|
7913
|
+
if (!focusService) {
|
|
7903
7914
|
throw new Error('clrDatalist requires being wrapped in <clr-datalist-container>');
|
|
7904
7915
|
}
|
|
7905
7916
|
}
|
|
@@ -8681,8 +8692,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.2", ngImpor
|
|
|
8681
8692
|
* The full license information can be found in LICENSE in the root directory of this project.
|
|
8682
8693
|
*/
|
|
8683
8694
|
class DateIOService {
|
|
8684
|
-
constructor(
|
|
8685
|
-
this._localeHelperService = _localeHelperService;
|
|
8695
|
+
constructor(localeHelperService) {
|
|
8686
8696
|
this.disabledDates = {
|
|
8687
8697
|
// This is the default range. It approximates the beginning of time to the end of time.
|
|
8688
8698
|
// Unless a minDate or maxDate is set with the native HTML5 api the range is all dates
|
|
@@ -8693,7 +8703,7 @@ class DateIOService {
|
|
|
8693
8703
|
this.cldrLocaleDateFormat = DEFAULT_LOCALE_FORMAT;
|
|
8694
8704
|
this.localeDisplayFormat = LITTLE_ENDIAN;
|
|
8695
8705
|
this.delimiters = ['/', '/'];
|
|
8696
|
-
this.cldrLocaleDateFormat =
|
|
8706
|
+
this.cldrLocaleDateFormat = localeHelperService.localeDateFormat;
|
|
8697
8707
|
this.initializeLocaleDisplayFormat();
|
|
8698
8708
|
}
|
|
8699
8709
|
get placeholderText() {
|
|
@@ -9114,7 +9124,7 @@ class DatepickerEnabledService {
|
|
|
9114
9124
|
constructor(_document) {
|
|
9115
9125
|
this._document = _document;
|
|
9116
9126
|
this._isUserAgentMobile = false;
|
|
9117
|
-
if (
|
|
9127
|
+
if (_document) {
|
|
9118
9128
|
this._isUserAgentMobile = MOBILE_USERAGENT_REGEX.test(_document.defaultView.navigator.userAgent);
|
|
9119
9129
|
this._innerWidth = _document.defaultView.innerWidth;
|
|
9120
9130
|
}
|
|
@@ -9712,18 +9722,17 @@ class ClrDateContainer extends ClrAbstractContainer {
|
|
|
9712
9722
|
this.dateFormControlService = dateFormControlService;
|
|
9713
9723
|
this.dateIOService = dateIOService;
|
|
9714
9724
|
this.commonStrings = commonStrings;
|
|
9715
|
-
this.focusService = focusService;
|
|
9716
9725
|
this.viewManagerService = viewManagerService;
|
|
9717
9726
|
this.controlClassService = controlClassService;
|
|
9718
9727
|
this.layoutService = layoutService;
|
|
9719
9728
|
this.ngControlService = ngControlService;
|
|
9720
9729
|
this.ifControlStateService = ifControlStateService;
|
|
9721
9730
|
this.focus = false;
|
|
9722
|
-
this.subscriptions.push(
|
|
9731
|
+
this.subscriptions.push(focusService.focusChange.subscribe(state => {
|
|
9723
9732
|
this.focus = state;
|
|
9724
9733
|
}));
|
|
9725
|
-
this.subscriptions.push(
|
|
9726
|
-
|
|
9734
|
+
this.subscriptions.push(toggleService.openChange.subscribe(() => {
|
|
9735
|
+
dateFormControlService.markAsTouched();
|
|
9727
9736
|
}));
|
|
9728
9737
|
}
|
|
9729
9738
|
set clrPosition(position) {
|
|
@@ -10732,7 +10741,7 @@ class ClrPasswordContainer extends ClrAbstractContainer {
|
|
|
10732
10741
|
this.focus = false;
|
|
10733
10742
|
this._toggle = true;
|
|
10734
10743
|
/* The unsubscribe is handle inside the ClrAbstractContainer */
|
|
10735
|
-
this.subscriptions.push(
|
|
10744
|
+
this.subscriptions.push(focusService.focusChange.subscribe(state => {
|
|
10736
10745
|
this.focus = state;
|
|
10737
10746
|
}));
|
|
10738
10747
|
}
|
|
@@ -10884,12 +10893,11 @@ class ClrPassword extends WrappedFormControl {
|
|
|
10884
10893
|
constructor(vcr, injector, control, renderer, el, focusService, toggleService) {
|
|
10885
10894
|
super(vcr, ClrPasswordContainer, injector, control, renderer, el);
|
|
10886
10895
|
this.focusService = focusService;
|
|
10887
|
-
this.toggleService = toggleService;
|
|
10888
10896
|
this.index = 1;
|
|
10889
|
-
if (!
|
|
10897
|
+
if (!focusService) {
|
|
10890
10898
|
throw new Error('clrPassword requires being wrapped in <clr-password-container>');
|
|
10891
10899
|
}
|
|
10892
|
-
this.subscriptions.push(
|
|
10900
|
+
this.subscriptions.push(toggleService.subscribe(toggle => {
|
|
10893
10901
|
renderer.setProperty(el.nativeElement, 'type', toggle ? 'text' : 'password');
|
|
10894
10902
|
}));
|
|
10895
10903
|
}
|
|
@@ -11092,8 +11100,10 @@ ClrRadioContainer.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", vers
|
|
|
11092
11100
|
<label *ngIf="!label && addGrid()"></label>
|
|
11093
11101
|
<div class="clr-control-container" [class.clr-control-inline]="clrInline" [ngClass]="controlClass()">
|
|
11094
11102
|
<ng-content select="clr-radio-wrapper"></ng-content>
|
|
11095
|
-
<div class="clr-subtext-wrapper">
|
|
11096
|
-
<ng-content select="clr-control-helper"
|
|
11103
|
+
<div *ngIf="showHelper" class="clr-subtext-wrapper">
|
|
11104
|
+
<ng-content select="clr-control-helper"></ng-content>
|
|
11105
|
+
</div>
|
|
11106
|
+
<div *ngIf="showValid || showInvalid" class="clr-subtext-wrapper">
|
|
11097
11107
|
<cds-icon
|
|
11098
11108
|
*ngIf="showInvalid"
|
|
11099
11109
|
class="clr-validate-icon"
|
|
@@ -11122,8 +11132,10 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.2", ngImpor
|
|
|
11122
11132
|
<label *ngIf="!label && addGrid()"></label>
|
|
11123
11133
|
<div class="clr-control-container" [class.clr-control-inline]="clrInline" [ngClass]="controlClass()">
|
|
11124
11134
|
<ng-content select="clr-radio-wrapper"></ng-content>
|
|
11125
|
-
<div class="clr-subtext-wrapper">
|
|
11126
|
-
<ng-content select="clr-control-helper"
|
|
11135
|
+
<div *ngIf="showHelper" class="clr-subtext-wrapper">
|
|
11136
|
+
<ng-content select="clr-control-helper"></ng-content>
|
|
11137
|
+
</div>
|
|
11138
|
+
<div *ngIf="showValid || showInvalid" class="clr-subtext-wrapper">
|
|
11127
11139
|
<cds-icon
|
|
11128
11140
|
*ngIf="showInvalid"
|
|
11129
11141
|
class="clr-validate-icon"
|
|
@@ -12207,7 +12219,7 @@ function getTabableItems(el) {
|
|
|
12207
12219
|
'iframe',
|
|
12208
12220
|
'object',
|
|
12209
12221
|
'embed',
|
|
12210
|
-
'*[tabindex]',
|
|
12222
|
+
'*[tabindex]:not([disabled])',
|
|
12211
12223
|
'*[contenteditable=true]',
|
|
12212
12224
|
'[role=button]:not([disabled])',
|
|
12213
12225
|
].join(',');
|
|
@@ -14492,11 +14504,10 @@ class ClrDatagridItems {
|
|
|
14492
14504
|
this.template = template;
|
|
14493
14505
|
this.differs = differs;
|
|
14494
14506
|
this.items = items;
|
|
14495
|
-
this.vcr = vcr;
|
|
14496
14507
|
this.differ = null;
|
|
14497
14508
|
this.subscriptions = [];
|
|
14498
14509
|
items.smartenUp();
|
|
14499
|
-
this.iterableProxy = new NgForOf(
|
|
14510
|
+
this.iterableProxy = new NgForOf(vcr, template, differs);
|
|
14500
14511
|
this.subscriptions.push(items.change.subscribe(newItems => {
|
|
14501
14512
|
this.iterableProxy.ngForOf = newItems;
|
|
14502
14513
|
this.iterableProxy.ngDoCheck();
|
|
@@ -14569,9 +14580,9 @@ class ClrDatagridPlaceholder {
|
|
|
14569
14580
|
}
|
|
14570
14581
|
ClrDatagridPlaceholder.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.2", ngImport: i0, type: ClrDatagridPlaceholder, deps: [{ token: Items }], target: i0.ɵɵFactoryTarget.Component });
|
|
14571
14582
|
ClrDatagridPlaceholder.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.2", type: ClrDatagridPlaceholder, selector: "clr-dg-placeholder", host: { properties: { "class.datagrid-placeholder-container": "true" } }, ngImport: i0, template: `
|
|
14572
|
-
<div class="datagrid-placeholder" [class.datagrid-empty]="emptyDatagrid"
|
|
14583
|
+
<div class="datagrid-placeholder" [class.datagrid-empty]="emptyDatagrid">
|
|
14573
14584
|
<div class="datagrid-placeholder-image" *ngIf="emptyDatagrid"></div>
|
|
14574
|
-
<span
|
|
14585
|
+
<span class="datagrid-placeholder-content"><ng-content *ngIf="emptyDatagrid"></ng-content></span>
|
|
14575
14586
|
</div>
|
|
14576
14587
|
`, isInline: true, dependencies: [{ kind: "directive", type: i5.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }] });
|
|
14577
14588
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.2", ngImport: i0, type: ClrDatagridPlaceholder, decorators: [{
|
|
@@ -14579,9 +14590,9 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.2", ngImpor
|
|
|
14579
14590
|
args: [{
|
|
14580
14591
|
selector: 'clr-dg-placeholder',
|
|
14581
14592
|
template: `
|
|
14582
|
-
<div class="datagrid-placeholder" [class.datagrid-empty]="emptyDatagrid"
|
|
14593
|
+
<div class="datagrid-placeholder" [class.datagrid-empty]="emptyDatagrid">
|
|
14583
14594
|
<div class="datagrid-placeholder-image" *ngIf="emptyDatagrid"></div>
|
|
14584
|
-
<span
|
|
14595
|
+
<span class="datagrid-placeholder-content"><ng-content *ngIf="emptyDatagrid"></ng-content></span>
|
|
14585
14596
|
</div>
|
|
14586
14597
|
`,
|
|
14587
14598
|
host: { '[class.datagrid-placeholder-container]': 'true' },
|
|
@@ -14994,9 +15005,8 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.2", ngImpor
|
|
|
14994
15005
|
*/
|
|
14995
15006
|
let nbSelection = 0;
|
|
14996
15007
|
class Selection {
|
|
14997
|
-
constructor(_items,
|
|
15008
|
+
constructor(_items, filters) {
|
|
14998
15009
|
this._items = _items;
|
|
14999
|
-
this._filters = _filters;
|
|
15000
15010
|
this.preserveSelection = false;
|
|
15001
15011
|
/**
|
|
15002
15012
|
* Shift key state, for use in range selection.
|
|
@@ -15017,13 +15027,13 @@ class Selection {
|
|
|
15017
15027
|
*/
|
|
15018
15028
|
this.subscriptions = [];
|
|
15019
15029
|
this.id = 'clr-dg-selection' + nbSelection++;
|
|
15020
|
-
this.subscriptions.push(
|
|
15030
|
+
this.subscriptions.push(filters.change.subscribe(() => {
|
|
15021
15031
|
if (!this._selectable || this.preserveSelection) {
|
|
15022
15032
|
return;
|
|
15023
15033
|
}
|
|
15024
15034
|
this.clearSelection();
|
|
15025
15035
|
}));
|
|
15026
|
-
this.subscriptions.push(
|
|
15036
|
+
this.subscriptions.push(_items.allChanges.subscribe(updatedItems => {
|
|
15027
15037
|
// Reset the lockedRefs;
|
|
15028
15038
|
const updateLockedRef = [];
|
|
15029
15039
|
switch (this.selectionType) {
|
|
@@ -15035,10 +15045,10 @@ class Selection {
|
|
|
15035
15045
|
let selectionUpdated = false;
|
|
15036
15046
|
// if the currentSingle has been set before data was loaded, we look up and save the ref from current data set
|
|
15037
15047
|
if (this.currentSingle && !this.prevSingleSelectionRef) {
|
|
15038
|
-
this.prevSingleSelectionRef =
|
|
15048
|
+
this.prevSingleSelectionRef = _items.trackBy(this.currentSingle);
|
|
15039
15049
|
}
|
|
15040
15050
|
updatedItems.forEach(item => {
|
|
15041
|
-
const ref =
|
|
15051
|
+
const ref = _items.trackBy(item);
|
|
15042
15052
|
// If one of the updated items is the previously selectedSingle, set it as the new one
|
|
15043
15053
|
if (this.prevSingleSelectionRef === ref) {
|
|
15044
15054
|
newSingle = item;
|
|
@@ -15052,7 +15062,7 @@ class Selection {
|
|
|
15052
15062
|
// Therefore, we should delete the currentSingle if it used to be defined but doesn't exist anymore.
|
|
15053
15063
|
// No explicit "delete" is required, since newSingle would be undefined at this point.
|
|
15054
15064
|
// Marking it as selectionUpdated here will set currentSingle to undefined below in the setTimeout.
|
|
15055
|
-
if (
|
|
15065
|
+
if (_items.smart && !newSingle) {
|
|
15056
15066
|
selectionUpdated = true;
|
|
15057
15067
|
}
|
|
15058
15068
|
// TODO: Discussed this with Eudes and this is fine for now.
|
|
@@ -15073,7 +15083,7 @@ class Selection {
|
|
|
15073
15083
|
if (this.current.length > 0 && this.prevSelectionRefs.length !== this.current.length) {
|
|
15074
15084
|
this.prevSelectionRefs = [];
|
|
15075
15085
|
this.current.forEach(item => {
|
|
15076
|
-
this.prevSelectionRefs.push(
|
|
15086
|
+
this.prevSelectionRefs.push(_items.trackBy(item));
|
|
15077
15087
|
});
|
|
15078
15088
|
}
|
|
15079
15089
|
// Duplicate loop, when the issue is issue#2342 is revisited keep in mind that
|
|
@@ -15082,7 +15092,7 @@ class Selection {
|
|
|
15082
15092
|
//
|
|
15083
15093
|
// The both loops below that goes over updatedItems could be combined into one.
|
|
15084
15094
|
updatedItems.forEach(item => {
|
|
15085
|
-
const ref =
|
|
15095
|
+
const ref = _items.trackBy(item);
|
|
15086
15096
|
if (this.lockedRefs.indexOf(ref) > -1) {
|
|
15087
15097
|
updateLockedRef.push(ref);
|
|
15088
15098
|
}
|
|
@@ -15092,7 +15102,7 @@ class Selection {
|
|
|
15092
15102
|
// the if statement below results in broken behavior.
|
|
15093
15103
|
if (leftOver.length > 0) {
|
|
15094
15104
|
updatedItems.forEach(item => {
|
|
15095
|
-
const ref =
|
|
15105
|
+
const ref = _items.trackBy(item);
|
|
15096
15106
|
// Look in current selected refs array if item is selected, and update actual value
|
|
15097
15107
|
const selectedIndex = this.prevSelectionRefs.indexOf(ref);
|
|
15098
15108
|
if (selectedIndex > -1) {
|
|
@@ -15102,7 +15112,7 @@ class Selection {
|
|
|
15102
15112
|
});
|
|
15103
15113
|
// Filter out any unmatched items if we're using smart datagrids where we expect all items to be
|
|
15104
15114
|
// present
|
|
15105
|
-
if (
|
|
15115
|
+
if (_items.smart) {
|
|
15106
15116
|
leftOver = leftOver.filter(selected => updatedItems.indexOf(selected) > -1);
|
|
15107
15117
|
if (this.current.length !== leftOver.length) {
|
|
15108
15118
|
selectionUpdated = true;
|
|
@@ -15421,13 +15431,13 @@ class ClrDatagridRow {
|
|
|
15421
15431
|
this.detailService = detailService;
|
|
15422
15432
|
this.displayMode = displayMode;
|
|
15423
15433
|
this.vcr = vcr;
|
|
15424
|
-
this.renderer = renderer;
|
|
15425
|
-
this.el = el;
|
|
15426
15434
|
this.commonStrings = commonStrings;
|
|
15427
15435
|
this.items = items;
|
|
15428
15436
|
this.document = document;
|
|
15429
15437
|
this.selectedChanged = new EventEmitter(false);
|
|
15430
15438
|
this.expandedChange = new EventEmitter(false);
|
|
15439
|
+
this.detailDisabled = false;
|
|
15440
|
+
this.detailHidden = false;
|
|
15431
15441
|
this.displayCells = false;
|
|
15432
15442
|
this.expandAnimationTrigger = false;
|
|
15433
15443
|
/* reference to the enum so that template can access */
|
|
@@ -15448,17 +15458,17 @@ class ClrDatagridRow {
|
|
|
15448
15458
|
this.radioId = 'clr-dg-row-rd' + nbRow;
|
|
15449
15459
|
this.checkboxId = 'clr-dg-row-cb' + nbRow;
|
|
15450
15460
|
this.expandableId = expand.expandableId;
|
|
15451
|
-
this.subscriptions.push(combineLatest(
|
|
15461
|
+
this.subscriptions.push(combineLatest(expand.replace, expand.expandChange).subscribe(([expandReplaceValue, expandChangeValue]) => {
|
|
15452
15462
|
if (expandReplaceValue && expandChangeValue) {
|
|
15453
15463
|
// replaced and expanding
|
|
15454
15464
|
this.replaced = true;
|
|
15455
|
-
|
|
15465
|
+
renderer.addClass(el.nativeElement, 'datagrid-row-replaced');
|
|
15456
15466
|
}
|
|
15457
15467
|
else {
|
|
15458
15468
|
this.replaced = false;
|
|
15459
15469
|
// Handles these cases: not replaced and collapsing & replaced and
|
|
15460
15470
|
// collapsing and not replaced and expanding.
|
|
15461
|
-
|
|
15471
|
+
renderer.removeClass(el.nativeElement, 'datagrid-row-replaced');
|
|
15462
15472
|
}
|
|
15463
15473
|
}));
|
|
15464
15474
|
}
|
|
@@ -15655,11 +15665,11 @@ class ClrDatagridRow {
|
|
|
15655
15665
|
}
|
|
15656
15666
|
}
|
|
15657
15667
|
ClrDatagridRow.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.2", 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: ClrCommonStringsService }, { token: Items }, { token: DOCUMENT }], target: i0.ɵɵFactoryTarget.Component });
|
|
15658
|
-
ClrDatagridRow.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.2", type: ClrDatagridRow, selector: "clr-dg-row", inputs: { 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-selected": "selected", "attr.aria-owns": "id" } }, providers: [
|
|
15668
|
+
ClrDatagridRow.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.2", type: ClrDatagridRow, selector: "clr-dg-row", inputs: { detailDisabled: ["clrDgDetailDisabled", "detailDisabled"], detailHidden: ["clrDgDetailHidden", "detailHidden"], 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-selected": "selected", "attr.aria-owns": "id" } }, providers: [
|
|
15659
15669
|
DatagridIfExpandService,
|
|
15660
15670
|
{ provide: IfExpandService, useExisting: DatagridIfExpandService },
|
|
15661
15671
|
{ provide: LoadingListener, useExisting: DatagridIfExpandService },
|
|
15662
|
-
], queries: [{ propertyName: "dgCells", predicate: ClrDatagridCell }], viewQueries: [{ propertyName: "expandAnimation", first: true, predicate: ClrExpandableAnimation, descendants: true }, { propertyName: "detailButton", first: true, predicate: ["detailButton"], descendants: true }, { propertyName: "_stickyCells", first: true, predicate: ["stickyCells"], descendants: true, read: ViewContainerRef }, { propertyName: "_scrollableCells", first: true, predicate: ["scrollableCells"], descendants: true, read: ViewContainerRef }, { propertyName: "_calculatedCells", first: true, predicate: ["calculatedCells"], descendants: true, read: ViewContainerRef }], ngImport: i0, template: "<!--\n We need to wrap the #rowContent in label element if we are in rowSelectionMode.\n Clicking of that wrapper label will equate to clicking on the whole row, which triggers the checkbox to toggle.\n-->\n<div\n class=\"datagrid-row-clickable\"\n *ngIf=\"selection.rowSelectionMode\"\n (mousedown)=\"clearRanges($event)\"\n (click)=\"selectRow(!selected, $event)\"\n>\n <clr-expandable-animation [clrExpandTrigger]=\"expandAnimationTrigger\" *ngIf=\"expand.expandable\">\n <ng-template [ngTemplateOutlet]=\"rowContent\"></ng-template>\n </clr-expandable-animation>\n <ng-template [ngTemplateOutlet]=\"rowContent\" *ngIf=\"!expand.expandable\"></ng-template>\n</div>\n\n<clr-expandable-animation\n *ngIf=\"!selection.rowSelectionMode && expand.expandable\"\n [clrExpandTrigger]=\"expandAnimationTrigger\"\n>\n <ng-template [ngTemplateOutlet]=\"rowContent\"></ng-template>\n</clr-expandable-animation>\n\n<ng-template *ngIf=\"!selection.rowSelectionMode && !expand.expandable\" [ngTemplateOutlet]=\"rowContent\"></ng-template>\n\n<!--\n We need the \"project into template\" hacks because we need this in 2 different places\n depending 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-template #rowContent>\n <div\n role=\"row\"\n [id]=\"id\"\n class=\"datagrid-row-master datagrid-row-flex\"\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 <div\n *ngIf=\"selection.selectionType === SELECTION_TYPE.Multi\"\n class=\"datagrid-select datagrid-fixed-column datagrid-cell\"\n [ngClass]=\"{ 'clr-form-control-disabled': !clrDgSelectable }\"\n role=\"gridcell\"\n >\n <clr-checkbox-wrapper>\n <input\n tabindex=\"-1\"\n type=\"checkbox\"\n clrCheckbox\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 </clr-checkbox-wrapper>\n </div>\n <div\n *ngIf=\"selection.selectionType === SELECTION_TYPE.Single\"\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 [id]=\"radioId\"\n [name]=\"selection.id + '-radio'\"\n [value]=\"item\"\n [(ngModel)]=\"selection.currentSingle\"\n [checked]=\"selection.currentSingle === item\"\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 <div\n *ngIf=\"rowActionService.hasActionableRow\"\n class=\"datagrid-row-actions datagrid-fixed-column datagrid-cell\"\n role=\"gridcell\"\n >\n <ng-content select=\"clr-dg-action-overflow\"></ng-content>\n </div>\n <div\n *ngIf=\"globalExpandable.hasExpandableRow\"\n class=\"datagrid-expandable-caret datagrid-fixed-column datagrid-cell\"\n role=\"gridcell\"\n >\n <ng-container *ngIf=\"expand.expandable\">\n <button\n tabindex=\"-1\"\n *ngIf=\"!expand.loading\"\n (click)=\"toggleExpand()\"\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]=\"expandableId\"\n >\n <cds-icon\n shape=\"angle\"\n class=\"datagrid-expandable-caret-icon\"\n [attr.direction]=\"expand.expanded ? 'down' : 'right'\"\n [attr.title]=\"expand.expanded ? commonStrings.keys.collapse : commonStrings.keys.expand\"\n ></cds-icon>\n </button>\n <clr-spinner *ngIf=\"expand.loading\" clrSmall>{{ commonStrings.keys.loading }}</clr-spinner>\n </ng-container>\n </div>\n <div\n *ngIf=\"detailService.enabled\"\n class=\"datagrid-detail-caret datagrid-fixed-column datagrid-cell\"\n role=\"gridcell\"\n >\n <button\n tabindex=\"-1\"\n (click)=\"detailService.toggle(item, detailButton)\"\n type=\"button\"\n #detailButton\n class=\"datagrid-detail-caret-button\"\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 [attr.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 </div>\n </ng-container>\n <!-- placeholder for projecting other sticky cells as pinned-->\n </div>\n <div class=\"datagrid-row-scrollable\" [ngClass]=\"{'is-replaced': replaced && expanded}\">\n <div class=\"datagrid-scrolling-cells\">\n <ng-content select=\"clr-dg-cell\"></ng-content>\n <ng-container #scrollableCells></ng-container>\n </div>\n <!-- details here when replace, re-visit when sticky container is used for pinned cells -->\n <ng-template *ngIf=\"replaced && !expand.loading\" [ngTemplateOutlet]=\"detail\"></ng-template>\n <ng-template *ngIf=\"!replaced && !expand.loading\" [ngTemplateOutlet]=\"detail\"></ng-template>\n </div>\n </div>\n</ng-template>\n\n<ng-container #calculatedCells></ng-container>\n", dependencies: [{ kind: "directive", type: i5.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i5.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i5.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "directive", type: CdsIconCustomTag, selector: "cds-icon" }, { kind: "directive", type: ClrLabel, selector: "label", inputs: ["for"] }, { kind: "directive", type: ClrCheckbox, selector: "[clrCheckbox],[clrToggle]" }, { kind: "component", type: ClrCheckboxWrapper, selector: "clr-checkbox-wrapper,clr-toggle-wrapper" }, { kind: "directive", type: ClrRadio, selector: "[clrRadio]" }, { kind: "component", type: ClrRadioWrapper, selector: "clr-radio-wrapper" }, { kind: "directive", type: i1.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i1.CheckboxControlValueAccessor, selector: "input[type=checkbox][formControlName],input[type=checkbox][formControl],input[type=checkbox][ngModel]" }, { kind: "directive", type: i1.RadioControlValueAccessor, selector: "input[type=radio][formControlName],input[type=radio][formControl],input[type=radio][ngModel]", inputs: ["name", "formControlName", "value"] }, { kind: "directive", type: i1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "component", type: ClrExpandableAnimation, selector: "clr-expandable-animation", inputs: ["clrExpandTrigger"] }, { kind: "component", type: ClrSpinner, selector: "clr-spinner", inputs: ["clrInline", "clrInverse", "clrSmall", "clrMedium"] }, { kind: "directive", type: ClrDatagridSelectionCellDirective, selector: ".datagrid-select" }] });
|
|
15672
|
+
], queries: [{ propertyName: "dgCells", predicate: ClrDatagridCell }], viewQueries: [{ propertyName: "expandAnimation", first: true, predicate: ClrExpandableAnimation, descendants: true }, { propertyName: "detailButton", first: true, predicate: ["detailButton"], descendants: true }, { propertyName: "_stickyCells", first: true, predicate: ["stickyCells"], descendants: true, read: ViewContainerRef }, { propertyName: "_scrollableCells", first: true, predicate: ["scrollableCells"], descendants: true, read: ViewContainerRef }, { propertyName: "_calculatedCells", first: true, predicate: ["calculatedCells"], descendants: true, read: ViewContainerRef }], ngImport: i0, template: "<!--\n We need to wrap the #rowContent in label element if we are in rowSelectionMode.\n Clicking of that wrapper label will equate to clicking on the whole row, which triggers the checkbox to toggle.\n-->\n<div\n class=\"datagrid-row-clickable\"\n *ngIf=\"selection.rowSelectionMode\"\n (mousedown)=\"clearRanges($event)\"\n (click)=\"selectRow(!selected, $event)\"\n>\n <clr-expandable-animation [clrExpandTrigger]=\"expandAnimationTrigger\" *ngIf=\"expand.expandable\">\n <ng-template [ngTemplateOutlet]=\"rowContent\"></ng-template>\n </clr-expandable-animation>\n <ng-template [ngTemplateOutlet]=\"rowContent\" *ngIf=\"!expand.expandable\"></ng-template>\n</div>\n\n<clr-expandable-animation\n *ngIf=\"!selection.rowSelectionMode && expand.expandable\"\n [clrExpandTrigger]=\"expandAnimationTrigger\"\n>\n <ng-template [ngTemplateOutlet]=\"rowContent\"></ng-template>\n</clr-expandable-animation>\n\n<ng-template *ngIf=\"!selection.rowSelectionMode && !expand.expandable\" [ngTemplateOutlet]=\"rowContent\"></ng-template>\n\n<!--\n We need the \"project into template\" hacks because we need this in 2 different places\n depending 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-template #rowContent>\n <div\n role=\"row\"\n [id]=\"id\"\n class=\"datagrid-row-master datagrid-row-flex\"\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 <div\n *ngIf=\"selection.selectionType === SELECTION_TYPE.Multi\"\n class=\"datagrid-select datagrid-fixed-column datagrid-cell\"\n [ngClass]=\"{ 'clr-form-control-disabled': !clrDgSelectable }\"\n role=\"gridcell\"\n >\n <clr-checkbox-wrapper>\n <input\n tabindex=\"-1\"\n type=\"checkbox\"\n clrCheckbox\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 </clr-checkbox-wrapper>\n </div>\n <div\n *ngIf=\"selection.selectionType === SELECTION_TYPE.Single\"\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 [id]=\"radioId\"\n [name]=\"selection.id + '-radio'\"\n [value]=\"item\"\n [(ngModel)]=\"selection.currentSingle\"\n [checked]=\"selection.currentSingle === item\"\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 <div\n *ngIf=\"rowActionService.hasActionableRow\"\n class=\"datagrid-row-actions datagrid-fixed-column datagrid-cell\"\n role=\"gridcell\"\n >\n <ng-content select=\"clr-dg-action-overflow\"></ng-content>\n </div>\n <div\n *ngIf=\"globalExpandable.hasExpandableRow\"\n class=\"datagrid-expandable-caret datagrid-fixed-column datagrid-cell\"\n role=\"gridcell\"\n >\n <ng-container *ngIf=\"expand.expandable\">\n <button\n tabindex=\"-1\"\n *ngIf=\"!expand.loading\"\n (click)=\"toggleExpand()\"\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]=\"expandableId\"\n >\n <cds-icon\n shape=\"angle\"\n class=\"datagrid-expandable-caret-icon\"\n [attr.direction]=\"expand.expanded ? 'down' : 'right'\"\n [attr.title]=\"expand.expanded ? commonStrings.keys.collapse : commonStrings.keys.expand\"\n ></cds-icon>\n </button>\n <clr-spinner *ngIf=\"expand.loading\" clrSmall>{{ commonStrings.keys.loading }}</clr-spinner>\n </ng-container>\n </div>\n <div\n *ngIf=\"detailService.enabled\"\n class=\"datagrid-detail-caret datagrid-fixed-column datagrid-cell\"\n role=\"gridcell\"\n >\n <button\n tabindex=\"-1\"\n (click)=\"detailService.toggle(item, detailButton)\"\n type=\"button\"\n #detailButton\n class=\"datagrid-detail-caret-button\"\n [disabled]=\"detailDisabled\"\n *ngIf=\"!detailHidden\"\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 [attr.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 </div>\n </ng-container>\n <!-- placeholder for projecting other sticky cells as pinned-->\n </div>\n <div class=\"datagrid-row-scrollable\" [ngClass]=\"{'is-replaced': replaced && expanded}\">\n <div class=\"datagrid-scrolling-cells\">\n <ng-content select=\"clr-dg-cell\"></ng-content>\n <ng-container #scrollableCells></ng-container>\n </div>\n <!-- details here when replace, re-visit when sticky container is used for pinned cells -->\n <ng-template *ngIf=\"replaced && !expand.loading\" [ngTemplateOutlet]=\"detail\"></ng-template>\n <ng-template *ngIf=\"!replaced && !expand.loading\" [ngTemplateOutlet]=\"detail\"></ng-template>\n </div>\n </div>\n</ng-template>\n\n<ng-container #calculatedCells></ng-container>\n", dependencies: [{ kind: "directive", type: i5.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i5.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i5.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "directive", type: CdsIconCustomTag, selector: "cds-icon" }, { kind: "directive", type: ClrLabel, selector: "label", inputs: ["for"] }, { kind: "directive", type: ClrCheckbox, selector: "[clrCheckbox],[clrToggle]" }, { kind: "component", type: ClrCheckboxWrapper, selector: "clr-checkbox-wrapper,clr-toggle-wrapper" }, { kind: "directive", type: ClrRadio, selector: "[clrRadio]" }, { kind: "component", type: ClrRadioWrapper, selector: "clr-radio-wrapper" }, { kind: "directive", type: i1.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i1.CheckboxControlValueAccessor, selector: "input[type=checkbox][formControlName],input[type=checkbox][formControl],input[type=checkbox][ngModel]" }, { kind: "directive", type: i1.RadioControlValueAccessor, selector: "input[type=radio][formControlName],input[type=radio][formControl],input[type=radio][ngModel]", inputs: ["name", "formControlName", "value"] }, { kind: "directive", type: i1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "component", type: ClrExpandableAnimation, selector: "clr-expandable-animation", inputs: ["clrExpandTrigger"] }, { kind: "component", type: ClrSpinner, selector: "clr-spinner", inputs: ["clrInline", "clrInverse", "clrSmall", "clrMedium"] }, { kind: "directive", type: ClrDatagridSelectionCellDirective, selector: ".datagrid-select" }] });
|
|
15663
15673
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.2", ngImport: i0, type: ClrDatagridRow, decorators: [{
|
|
15664
15674
|
type: Component,
|
|
15665
15675
|
args: [{ selector: 'clr-dg-row', host: {
|
|
@@ -15671,7 +15681,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.2", ngImpor
|
|
|
15671
15681
|
DatagridIfExpandService,
|
|
15672
15682
|
{ provide: IfExpandService, useExisting: DatagridIfExpandService },
|
|
15673
15683
|
{ provide: LoadingListener, useExisting: DatagridIfExpandService },
|
|
15674
|
-
], template: "<!--\n We need to wrap the #rowContent in label element if we are in rowSelectionMode.\n Clicking of that wrapper label will equate to clicking on the whole row, which triggers the checkbox to toggle.\n-->\n<div\n class=\"datagrid-row-clickable\"\n *ngIf=\"selection.rowSelectionMode\"\n (mousedown)=\"clearRanges($event)\"\n (click)=\"selectRow(!selected, $event)\"\n>\n <clr-expandable-animation [clrExpandTrigger]=\"expandAnimationTrigger\" *ngIf=\"expand.expandable\">\n <ng-template [ngTemplateOutlet]=\"rowContent\"></ng-template>\n </clr-expandable-animation>\n <ng-template [ngTemplateOutlet]=\"rowContent\" *ngIf=\"!expand.expandable\"></ng-template>\n</div>\n\n<clr-expandable-animation\n *ngIf=\"!selection.rowSelectionMode && expand.expandable\"\n [clrExpandTrigger]=\"expandAnimationTrigger\"\n>\n <ng-template [ngTemplateOutlet]=\"rowContent\"></ng-template>\n</clr-expandable-animation>\n\n<ng-template *ngIf=\"!selection.rowSelectionMode && !expand.expandable\" [ngTemplateOutlet]=\"rowContent\"></ng-template>\n\n<!--\n We need the \"project into template\" hacks because we need this in 2 different places\n depending 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-template #rowContent>\n <div\n role=\"row\"\n [id]=\"id\"\n class=\"datagrid-row-master datagrid-row-flex\"\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 <div\n *ngIf=\"selection.selectionType === SELECTION_TYPE.Multi\"\n class=\"datagrid-select datagrid-fixed-column datagrid-cell\"\n [ngClass]=\"{ 'clr-form-control-disabled': !clrDgSelectable }\"\n role=\"gridcell\"\n >\n <clr-checkbox-wrapper>\n <input\n tabindex=\"-1\"\n type=\"checkbox\"\n clrCheckbox\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 </clr-checkbox-wrapper>\n </div>\n <div\n *ngIf=\"selection.selectionType === SELECTION_TYPE.Single\"\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 [id]=\"radioId\"\n [name]=\"selection.id + '-radio'\"\n [value]=\"item\"\n [(ngModel)]=\"selection.currentSingle\"\n [checked]=\"selection.currentSingle === item\"\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 <div\n *ngIf=\"rowActionService.hasActionableRow\"\n class=\"datagrid-row-actions datagrid-fixed-column datagrid-cell\"\n role=\"gridcell\"\n >\n <ng-content select=\"clr-dg-action-overflow\"></ng-content>\n </div>\n <div\n *ngIf=\"globalExpandable.hasExpandableRow\"\n class=\"datagrid-expandable-caret datagrid-fixed-column datagrid-cell\"\n role=\"gridcell\"\n >\n <ng-container *ngIf=\"expand.expandable\">\n <button\n tabindex=\"-1\"\n *ngIf=\"!expand.loading\"\n (click)=\"toggleExpand()\"\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]=\"expandableId\"\n >\n <cds-icon\n shape=\"angle\"\n class=\"datagrid-expandable-caret-icon\"\n [attr.direction]=\"expand.expanded ? 'down' : 'right'\"\n [attr.title]=\"expand.expanded ? commonStrings.keys.collapse : commonStrings.keys.expand\"\n ></cds-icon>\n </button>\n <clr-spinner *ngIf=\"expand.loading\" clrSmall>{{ commonStrings.keys.loading }}</clr-spinner>\n </ng-container>\n </div>\n <div\n *ngIf=\"detailService.enabled\"\n class=\"datagrid-detail-caret datagrid-fixed-column datagrid-cell\"\n role=\"gridcell\"\n >\n <button\n tabindex=\"-1\"\n (click)=\"detailService.toggle(item, detailButton)\"\n type=\"button\"\n #detailButton\n class=\"datagrid-detail-caret-button\"\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 [attr.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 </div>\n </ng-container>\n <!-- placeholder for projecting other sticky cells as pinned-->\n </div>\n <div class=\"datagrid-row-scrollable\" [ngClass]=\"{'is-replaced': replaced && expanded}\">\n <div class=\"datagrid-scrolling-cells\">\n <ng-content select=\"clr-dg-cell\"></ng-content>\n <ng-container #scrollableCells></ng-container>\n </div>\n <!-- details here when replace, re-visit when sticky container is used for pinned cells -->\n <ng-template *ngIf=\"replaced && !expand.loading\" [ngTemplateOutlet]=\"detail\"></ng-template>\n <ng-template *ngIf=\"!replaced && !expand.loading\" [ngTemplateOutlet]=\"detail\"></ng-template>\n </div>\n </div>\n</ng-template>\n\n<ng-container #calculatedCells></ng-container>\n" }]
|
|
15684
|
+
], template: "<!--\n We need to wrap the #rowContent in label element if we are in rowSelectionMode.\n Clicking of that wrapper label will equate to clicking on the whole row, which triggers the checkbox to toggle.\n-->\n<div\n class=\"datagrid-row-clickable\"\n *ngIf=\"selection.rowSelectionMode\"\n (mousedown)=\"clearRanges($event)\"\n (click)=\"selectRow(!selected, $event)\"\n>\n <clr-expandable-animation [clrExpandTrigger]=\"expandAnimationTrigger\" *ngIf=\"expand.expandable\">\n <ng-template [ngTemplateOutlet]=\"rowContent\"></ng-template>\n </clr-expandable-animation>\n <ng-template [ngTemplateOutlet]=\"rowContent\" *ngIf=\"!expand.expandable\"></ng-template>\n</div>\n\n<clr-expandable-animation\n *ngIf=\"!selection.rowSelectionMode && expand.expandable\"\n [clrExpandTrigger]=\"expandAnimationTrigger\"\n>\n <ng-template [ngTemplateOutlet]=\"rowContent\"></ng-template>\n</clr-expandable-animation>\n\n<ng-template *ngIf=\"!selection.rowSelectionMode && !expand.expandable\" [ngTemplateOutlet]=\"rowContent\"></ng-template>\n\n<!--\n We need the \"project into template\" hacks because we need this in 2 different places\n depending 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-template #rowContent>\n <div\n role=\"row\"\n [id]=\"id\"\n class=\"datagrid-row-master datagrid-row-flex\"\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 <div\n *ngIf=\"selection.selectionType === SELECTION_TYPE.Multi\"\n class=\"datagrid-select datagrid-fixed-column datagrid-cell\"\n [ngClass]=\"{ 'clr-form-control-disabled': !clrDgSelectable }\"\n role=\"gridcell\"\n >\n <clr-checkbox-wrapper>\n <input\n tabindex=\"-1\"\n type=\"checkbox\"\n clrCheckbox\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 </clr-checkbox-wrapper>\n </div>\n <div\n *ngIf=\"selection.selectionType === SELECTION_TYPE.Single\"\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 [id]=\"radioId\"\n [name]=\"selection.id + '-radio'\"\n [value]=\"item\"\n [(ngModel)]=\"selection.currentSingle\"\n [checked]=\"selection.currentSingle === item\"\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 <div\n *ngIf=\"rowActionService.hasActionableRow\"\n class=\"datagrid-row-actions datagrid-fixed-column datagrid-cell\"\n role=\"gridcell\"\n >\n <ng-content select=\"clr-dg-action-overflow\"></ng-content>\n </div>\n <div\n *ngIf=\"globalExpandable.hasExpandableRow\"\n class=\"datagrid-expandable-caret datagrid-fixed-column datagrid-cell\"\n role=\"gridcell\"\n >\n <ng-container *ngIf=\"expand.expandable\">\n <button\n tabindex=\"-1\"\n *ngIf=\"!expand.loading\"\n (click)=\"toggleExpand()\"\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]=\"expandableId\"\n >\n <cds-icon\n shape=\"angle\"\n class=\"datagrid-expandable-caret-icon\"\n [attr.direction]=\"expand.expanded ? 'down' : 'right'\"\n [attr.title]=\"expand.expanded ? commonStrings.keys.collapse : commonStrings.keys.expand\"\n ></cds-icon>\n </button>\n <clr-spinner *ngIf=\"expand.loading\" clrSmall>{{ commonStrings.keys.loading }}</clr-spinner>\n </ng-container>\n </div>\n <div\n *ngIf=\"detailService.enabled\"\n class=\"datagrid-detail-caret datagrid-fixed-column datagrid-cell\"\n role=\"gridcell\"\n >\n <button\n tabindex=\"-1\"\n (click)=\"detailService.toggle(item, detailButton)\"\n type=\"button\"\n #detailButton\n class=\"datagrid-detail-caret-button\"\n [disabled]=\"detailDisabled\"\n *ngIf=\"!detailHidden\"\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 [attr.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 </div>\n </ng-container>\n <!-- placeholder for projecting other sticky cells as pinned-->\n </div>\n <div class=\"datagrid-row-scrollable\" [ngClass]=\"{'is-replaced': replaced && expanded}\">\n <div class=\"datagrid-scrolling-cells\">\n <ng-content select=\"clr-dg-cell\"></ng-content>\n <ng-container #scrollableCells></ng-container>\n </div>\n <!-- details here when replace, re-visit when sticky container is used for pinned cells -->\n <ng-template *ngIf=\"replaced && !expand.loading\" [ngTemplateOutlet]=\"detail\"></ng-template>\n <ng-template *ngIf=\"!replaced && !expand.loading\" [ngTemplateOutlet]=\"detail\"></ng-template>\n </div>\n </div>\n</ng-template>\n\n<ng-container #calculatedCells></ng-container>\n" }]
|
|
15675
15685
|
}], ctorParameters: function () {
|
|
15676
15686
|
return [{ type: Selection }, { type: RowActionService }, { type: ExpandableRowsCount }, { type: DatagridIfExpandService }, { type: DetailService }, { type: DisplayModeService }, { type: i0.ViewContainerRef }, { type: i0.Renderer2 }, { type: i0.ElementRef }, { type: ClrCommonStringsService }, { type: Items }, { type: undefined, decorators: [{
|
|
15677
15687
|
type: Inject,
|
|
@@ -15683,6 +15693,12 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.2", ngImpor
|
|
|
15683
15693
|
}], expandedChange: [{
|
|
15684
15694
|
type: Output,
|
|
15685
15695
|
args: ['clrDgExpandedChange']
|
|
15696
|
+
}], detailDisabled: [{
|
|
15697
|
+
type: Input,
|
|
15698
|
+
args: ['clrDgDetailDisabled']
|
|
15699
|
+
}], detailHidden: [{
|
|
15700
|
+
type: Input,
|
|
15701
|
+
args: ['clrDgDetailHidden']
|
|
15686
15702
|
}], dgCells: [{
|
|
15687
15703
|
type: ContentChildren,
|
|
15688
15704
|
args: [ClrDatagridCell]
|
|
@@ -15973,7 +15989,7 @@ class DatagridRowRenderer {
|
|
|
15973
15989
|
}
|
|
15974
15990
|
}
|
|
15975
15991
|
DatagridRowRenderer.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.2", ngImport: i0, type: DatagridRowRenderer, deps: [{ token: ColumnsService }], target: i0.ɵɵFactoryTarget.Directive });
|
|
15976
|
-
DatagridRowRenderer.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "15.2.2", type: DatagridRowRenderer, selector: "clr-dg-row, clr-dg-row-detail", queries: [{ propertyName: "cells", predicate: DatagridCellRenderer }], ngImport: i0 });
|
|
15992
|
+
DatagridRowRenderer.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "15.2.2", type: DatagridRowRenderer, selector: "clr-dg-row, clr-dg-row-detail", queries: [{ propertyName: "expandableRow", first: true, predicate: i0.forwardRef(function () { return DatagridRowRenderer; }), descendants: true }, { propertyName: "cells", predicate: DatagridCellRenderer }], ngImport: i0 });
|
|
15977
15993
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.2", ngImport: i0, type: DatagridRowRenderer, decorators: [{
|
|
15978
15994
|
type: Directive,
|
|
15979
15995
|
args: [{
|
|
@@ -15982,6 +15998,9 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.2", ngImpor
|
|
|
15982
15998
|
}], ctorParameters: function () { return [{ type: ColumnsService }]; }, propDecorators: { cells: [{
|
|
15983
15999
|
type: ContentChildren,
|
|
15984
16000
|
args: [DatagridCellRenderer]
|
|
16001
|
+
}], expandableRow: [{
|
|
16002
|
+
type: ContentChild,
|
|
16003
|
+
args: [forwardRef(() => DatagridRowRenderer)]
|
|
15985
16004
|
}] } });
|
|
15986
16005
|
|
|
15987
16006
|
/*
|
|
@@ -15991,7 +16010,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.2", ngImpor
|
|
|
15991
16010
|
* The full license information can be found in LICENSE in the root directory of this project.
|
|
15992
16011
|
*/
|
|
15993
16012
|
class ClrDatagrid {
|
|
15994
|
-
constructor(organizer, items, expandableRows, selection, rowActionService, stateProvider, displayMode, renderer, detailService, document, el, page, commonStrings,
|
|
16013
|
+
constructor(organizer, items, expandableRows, selection, rowActionService, stateProvider, displayMode, renderer, detailService, document, el, page, commonStrings, keyNavigation, zone) {
|
|
15995
16014
|
this.organizer = organizer;
|
|
15996
16015
|
this.items = items;
|
|
15997
16016
|
this.expandableRows = expandableRows;
|
|
@@ -16005,7 +16024,6 @@ class ClrDatagrid {
|
|
|
16005
16024
|
this.el = el;
|
|
16006
16025
|
this.page = page;
|
|
16007
16026
|
this.commonStrings = commonStrings;
|
|
16008
|
-
this.columnsService = columnsService;
|
|
16009
16027
|
this.keyNavigation = keyNavigation;
|
|
16010
16028
|
this.zone = zone;
|
|
16011
16029
|
this.clrDgSingleSelectionAriaLabel = this.commonStrings.keys.singleSelectionAriaLabel;
|
|
@@ -16027,7 +16045,7 @@ class ClrDatagrid {
|
|
|
16027
16045
|
this._subscriptions = [];
|
|
16028
16046
|
const datagridId = uniqueIdFactory();
|
|
16029
16047
|
this.selectAllId = 'clr-dg-select-all-' + datagridId;
|
|
16030
|
-
|
|
16048
|
+
detailService.id = datagridId;
|
|
16031
16049
|
}
|
|
16032
16050
|
/**
|
|
16033
16051
|
* Freezes the datagrid while data is loading
|
|
@@ -16117,30 +16135,17 @@ class ClrDatagrid {
|
|
|
16117
16135
|
this.rows.forEach(row => {
|
|
16118
16136
|
this._displayedRows.insert(row._view);
|
|
16119
16137
|
});
|
|
16120
|
-
|
|
16121
|
-
|
|
16122
|
-
|
|
16123
|
-
|
|
16124
|
-
|
|
16125
|
-
|
|
16126
|
-
|
|
16127
|
-
|
|
16128
|
-
// always keep open when virtual scroll is available otherwise close it
|
|
16129
|
-
}
|
|
16130
|
-
else if (!this.hasVirtualScroller) {
|
|
16131
|
-
// Using setTimeout to make sure the inner cycles in rows are done
|
|
16132
|
-
setTimeout(() => {
|
|
16133
|
-
this.detailService.close();
|
|
16138
|
+
this.updateDetailState();
|
|
16139
|
+
// retain active cell when navigating with Up/Down Arrows, PageUp and PageDown buttons in virtual scroller
|
|
16140
|
+
if (this.hasVirtualScroller) {
|
|
16141
|
+
const active = this.keyNavigation.getActiveCell();
|
|
16142
|
+
const isFocusInsideDatagrid = this.datagrid.nativeElement.contains(document.activeElement);
|
|
16143
|
+
if (active && isFocusInsideDatagrid) {
|
|
16144
|
+
this.zone.runOutsideAngular(() => {
|
|
16145
|
+
setTimeout(() => this.keyNavigation.setActiveCell(active));
|
|
16134
16146
|
});
|
|
16135
16147
|
}
|
|
16136
16148
|
}
|
|
16137
|
-
// retain active cell when navigating with Up/Down Arrows, PageUp and PageDown buttons in virtual scroller
|
|
16138
|
-
const active = this.keyNavigation.getActiveCell();
|
|
16139
|
-
if (active) {
|
|
16140
|
-
this.zone.runOutsideAngular(() => {
|
|
16141
|
-
setTimeout(() => this.keyNavigation.setActiveCell(active));
|
|
16142
|
-
});
|
|
16143
|
-
}
|
|
16144
16149
|
}));
|
|
16145
16150
|
}
|
|
16146
16151
|
/**
|
|
@@ -16148,6 +16153,7 @@ class ClrDatagrid {
|
|
|
16148
16153
|
*/
|
|
16149
16154
|
ngAfterViewInit() {
|
|
16150
16155
|
this.keyNavigation.initializeKeyGrid(this.el.nativeElement);
|
|
16156
|
+
this.updateDetailState();
|
|
16151
16157
|
// TODO: determine if we can get rid of provider wiring in view init so that subscriptions can be done earlier
|
|
16152
16158
|
this.refresh.emit(this.stateProvider.state);
|
|
16153
16159
|
this._subscriptions.push(this.stateProvider.change.subscribe(state => this.refresh.emit(state)), this.selection.change.subscribe(s => {
|
|
@@ -16231,6 +16237,29 @@ class ClrDatagrid {
|
|
|
16231
16237
|
resize() {
|
|
16232
16238
|
this.organizer.resize();
|
|
16233
16239
|
}
|
|
16240
|
+
/**
|
|
16241
|
+
* Checks the state of detail panel and if it's opened then
|
|
16242
|
+
* find the matching row and trigger the detail panel
|
|
16243
|
+
*/
|
|
16244
|
+
updateDetailState() {
|
|
16245
|
+
// Try to update only when there is something cached and its open.
|
|
16246
|
+
if (this.detailService.state && this.detailService.isOpen) {
|
|
16247
|
+
const row = this.rows.find(row => this.items.trackBy(row.item) === this.items.trackBy(this.detailService.state));
|
|
16248
|
+
/**
|
|
16249
|
+
* Reopen updated row or close it
|
|
16250
|
+
*/
|
|
16251
|
+
if (row) {
|
|
16252
|
+
this.detailService.open(row.item, row.detailButton.nativeElement);
|
|
16253
|
+
// always keep open when virtual scroll is available otherwise close it
|
|
16254
|
+
}
|
|
16255
|
+
else if (!this.hasVirtualScroller) {
|
|
16256
|
+
// Using setTimeout to make sure the inner cycles in rows are done
|
|
16257
|
+
setTimeout(() => {
|
|
16258
|
+
this.detailService.close();
|
|
16259
|
+
});
|
|
16260
|
+
}
|
|
16261
|
+
}
|
|
16262
|
+
}
|
|
16234
16263
|
/**
|
|
16235
16264
|
* Public method to re-trigger the computation of displayed items manually
|
|
16236
16265
|
*/
|
|
@@ -16238,7 +16267,7 @@ class ClrDatagrid {
|
|
|
16238
16267
|
this.items.refresh();
|
|
16239
16268
|
}
|
|
16240
16269
|
}
|
|
16241
|
-
ClrDatagrid.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.2", 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: ClrCommonStringsService }, { token:
|
|
16270
|
+
ClrDatagrid.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.2", 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: ClrCommonStringsService }, { token: KeyNavigationGridController }, { token: i0.NgZone }], target: i0.ɵɵFactoryTarget.Component });
|
|
16242
16271
|
ClrDatagrid.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.2", type: ClrDatagrid, selector: "clr-datagrid", inputs: { loadingMoreItems: ["clrLoadingMoreItems", "loadingMoreItems"], clrDgSingleSelectionAriaLabel: "clrDgSingleSelectionAriaLabel", clrDgSingleActionableAriaLabel: "clrDgSingleActionableAriaLabel", clrDetailExpandableAriaLabel: "clrDetailExpandableAriaLabel", clrDgDisablePageFocus: "clrDgDisablePageFocus", loading: ["clrDgLoading", "loading"], selected: ["clrDgSelected", "selected"], singleSelected: ["clrDgSingleSelected", "singleSelected"], clrDgPreserveSelection: "clrDgPreserveSelection", rowSelectionMode: ["clrDgRowSelection", "rowSelectionMode"], trackBy: ["clrDgItemsTrackBy", "trackBy"] }, outputs: { selectedChanged: "clrDgSelectedChange", singleSelectedChanged: "clrDgSingleSelectedChange", refresh: "clrDgRefresh" }, host: { properties: { "class.datagrid-host": "true", "class.datagrid-detail-open": "detailService.isOpen" } }, providers: [
|
|
16243
16272
|
Selection,
|
|
16244
16273
|
Sort,
|
|
@@ -16255,7 +16284,7 @@ ClrDatagrid.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "
|
|
|
16255
16284
|
ColumnsService,
|
|
16256
16285
|
DisplayModeService,
|
|
16257
16286
|
KeyNavigationGridController,
|
|
16258
|
-
], queries: [{ propertyName: "iterator", first: true, predicate: ClrDatagridItems, descendants: true }, { propertyName: "placeholder", first: true, predicate: ClrDatagridPlaceholder, descendants: true }, { propertyName: "columns", predicate: ClrDatagridColumn }, { propertyName: "rows", predicate: ClrDatagridRow }], viewQueries: [{ propertyName: "datagrid", first: true, predicate: ["datagrid"], descendants: true, read: ElementRef }, { propertyName: "datagridTable", first: true, predicate: ["datagridTable"], descendants: true, read: ElementRef }, { propertyName: "scrollableColumns", first: true, predicate: ["scrollableColumns"], descendants: true, read: ViewContainerRef }, { propertyName: "_projectedDisplayColumns", first: true, predicate: ["projectedDisplayColumns"], 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 }], ngImport: i0, template: "<!--\n ~ Copyright (c) 2016-2024 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\">\n <div role=\"row\" class=\"datagrid-row\">\n <div class=\"datagrid-row-master datagrid-row-flex\">\n <div class=\"datagrid-row-sticky\">\n <!--header for datagrid where you can select multiple rows -->\n <div\n role=\"columnheader\"\n class=\"datagrid-column datagrid-select datagrid-fixed-column\"\n *ngIf=\"selection.selectionType === SELECTION_TYPE.Multi\"\n (keydown.space)=\"toggleAllSelected($event)\"\n >\n <div *ngIf=\"!hasVirtualScroller\" 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 type=\"checkbox\"\n [id]=\"selectAllId\"\n [(ngModel)]=\"allSelected\"\n [attr.aria-label]=\"commonStrings.keys.selectAll\"\n tabindex=\"-1\"\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 <!-- header for datagrid where you can select one row only -->\n <div\n role=\"columnheader\"\n class=\"datagrid-column datagrid-select datagrid-fixed-column\"\n *ngIf=\"selection.selectionType === SELECTION_TYPE.Single\"\n >\n <div class=\"clr-sr-only\">{{clrDgSingleSelectionAriaLabel}}</div>\n <div class=\"datagrid-column-separator\"></div>\n </div>\n <!-- header for single row action; only displayType if we have at least one actionable row in datagrid -->\n <div\n role=\"columnheader\"\n class=\"datagrid-column datagrid-row-actions datagrid-fixed-column\"\n *ngIf=\"rowActionService.hasActionableRow\"\n >\n <div class=\"clr-sr-only\">{{clrDgSingleActionableAriaLabel}}</div>\n <div class=\"datagrid-column-separator\"></div>\n </div>\n <!-- header for carets; only displayType if we have at least one expandable row in datagrid -->\n <div\n role=\"columnheader\"\n class=\"datagrid-column datagrid-expandable-caret datagrid-fixed-column\"\n *ngIf=\"expandableRows.hasExpandableRow || detailService.enabled\"\n >\n <div class=\"clr-sr-only\">{{clrDetailExpandableAriaLabel}}</div>\n <div class=\"datagrid-column-separator\"></div>\n </div>\n </div>\n <div class=\"datagrid-row-scrollable\">\n <ng-container #projectedDisplayColumns></ng-container>\n </div>\n </div>\n </div>\n </div>\n\n <div role=\"presentation\" class=\"datagrid-rows\">\n <clr-dg-row class=\"datagrid-row-loading\" *ngIf=\"loadingMoreItems\">\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 <ng-container #displayedRows></ng-container>\n\n <clr-dg-row class=\"datagrid-row-loading\" *ngIf=\"loadingMoreItems\">\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 <!-- Custom placeholder overrides the default empty one -->\n <ng-content select=\"clr-dg-placeholder\"></ng-content>\n <clr-dg-placeholder *ngIf=\"!placeholder\"></clr-dg-placeholder>\n </div>\n </div>\n </div>\n </div>\n <ng-content select=\"clr-dg-footer\"></ng-content>\n <div class=\"datagrid-spinner\" *ngIf=\"loading\">\n <clr-spinner clrMedium>Loading</clr-spinner>\n </div>\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", dependencies: [{ kind: "directive", type: i5.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: ClrLabel, selector: "label", inputs: ["for"] }, { kind: "directive", type: i1.CheckboxControlValueAccessor, selector: "input[type=checkbox][formControlName],input[type=checkbox][formControl],input[type=checkbox][ngModel]" }, { kind: "directive", type: i1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "component", type: 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: ["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, clr-dg-row-detail" }, { kind: "directive", type: ActionableOompaLoompa, selector: "clr-datagrid, clr-dg-row" }, { kind: "directive", type: ExpandableOompaLoompa, selector: "clr-datagrid, clr-dg-row" }] });
|
|
16287
|
+
], queries: [{ propertyName: "iterator", first: true, predicate: ClrDatagridItems, descendants: true }, { propertyName: "placeholder", first: true, predicate: ClrDatagridPlaceholder, descendants: true }, { propertyName: "columns", predicate: ClrDatagridColumn }, { propertyName: "rows", predicate: ClrDatagridRow }], viewQueries: [{ propertyName: "datagrid", first: true, predicate: ["datagrid"], descendants: true, read: ElementRef }, { propertyName: "datagridTable", first: true, predicate: ["datagridTable"], descendants: true, read: ElementRef }, { propertyName: "scrollableColumns", first: true, predicate: ["scrollableColumns"], descendants: true, read: ViewContainerRef }, { propertyName: "_projectedDisplayColumns", first: true, predicate: ["projectedDisplayColumns"], 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 }], ngImport: i0, template: "<!--\n ~ Copyright (c) 2016-2024 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\">\n <div role=\"row\" class=\"datagrid-row\">\n <div class=\"datagrid-row-master datagrid-row-flex\">\n <div class=\"datagrid-row-sticky\">\n <!--header for datagrid where you can select multiple rows -->\n <div\n role=\"columnheader\"\n class=\"datagrid-column datagrid-select datagrid-fixed-column\"\n *ngIf=\"selection.selectionType === SELECTION_TYPE.Multi\"\n (keydown.space)=\"toggleAllSelected($event)\"\n >\n <div *ngIf=\"!hasVirtualScroller\" 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 type=\"checkbox\"\n [id]=\"selectAllId\"\n [(ngModel)]=\"allSelected\"\n [attr.aria-label]=\"commonStrings.keys.selectAll\"\n tabindex=\"-1\"\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 <!-- header for datagrid where you can select one row only -->\n <div\n role=\"columnheader\"\n class=\"datagrid-column datagrid-select datagrid-fixed-column\"\n *ngIf=\"selection.selectionType === SELECTION_TYPE.Single\"\n >\n <div class=\"clr-sr-only\">{{clrDgSingleSelectionAriaLabel}}</div>\n <div class=\"datagrid-column-separator\"></div>\n </div>\n <!-- header for single row action; only displayType if we have at least one actionable row in datagrid -->\n <div\n role=\"columnheader\"\n class=\"datagrid-column datagrid-row-actions datagrid-fixed-column\"\n *ngIf=\"rowActionService.hasActionableRow\"\n >\n <div class=\"clr-sr-only\">{{clrDgSingleActionableAriaLabel}}</div>\n <div class=\"datagrid-column-separator\"></div>\n </div>\n <!-- header for carets; only displayType if we have at least one expandable row in datagrid -->\n <div\n role=\"columnheader\"\n class=\"datagrid-column datagrid-expandable-caret datagrid-fixed-column\"\n *ngIf=\"expandableRows.hasExpandableRow || detailService.enabled\"\n >\n <div class=\"clr-sr-only\">{{clrDetailExpandableAriaLabel}}</div>\n <div class=\"datagrid-column-separator\"></div>\n </div>\n </div>\n <div class=\"datagrid-row-scrollable\">\n <ng-container #projectedDisplayColumns></ng-container>\n </div>\n </div>\n </div>\n </div>\n\n <div role=\"presentation\" class=\"datagrid-rows\">\n <clr-dg-row class=\"datagrid-row-loading\" *ngIf=\"loadingMoreItems\">\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 <ng-container #displayedRows></ng-container>\n\n <clr-dg-row class=\"datagrid-row-loading\" *ngIf=\"loadingMoreItems\">\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 <!-- Custom placeholder overrides the default empty one -->\n <ng-content select=\"clr-dg-placeholder\"></ng-content>\n <clr-dg-placeholder *ngIf=\"!placeholder\"></clr-dg-placeholder>\n </div>\n </div>\n </div>\n </div>\n <ng-content select=\"clr-dg-footer\"></ng-content>\n <div class=\"datagrid-spinner\" *ngIf=\"loading\">\n <clr-spinner clrMedium>Loading</clr-spinner>\n </div>\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", dependencies: [{ kind: "directive", type: i5.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: ClrLabel, selector: "label", inputs: ["for"] }, { kind: "directive", type: i1.CheckboxControlValueAccessor, selector: "input[type=checkbox][formControlName],input[type=checkbox][formControl],input[type=checkbox][ngModel]" }, { kind: "directive", type: i1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "component", type: 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", "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, clr-dg-row-detail" }, { kind: "directive", type: ActionableOompaLoompa, selector: "clr-datagrid, clr-dg-row" }, { kind: "directive", type: ExpandableOompaLoompa, selector: "clr-datagrid, clr-dg-row" }] });
|
|
16259
16288
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.2", ngImport: i0, type: ClrDatagrid, decorators: [{
|
|
16260
16289
|
type: Component,
|
|
16261
16290
|
args: [{ selector: 'clr-datagrid', providers: [
|
|
@@ -16282,7 +16311,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.2", ngImpor
|
|
|
16282
16311
|
return [{ type: DatagridRenderOrganizer }, { type: Items }, { type: ExpandableRowsCount }, { type: Selection }, { type: RowActionService }, { type: StateProvider }, { type: DisplayModeService }, { type: i0.Renderer2 }, { type: DetailService }, { type: undefined, decorators: [{
|
|
16283
16312
|
type: Inject,
|
|
16284
16313
|
args: [DOCUMENT]
|
|
16285
|
-
}] }, { type: i0.ElementRef }, { type: Page }, { type: ClrCommonStringsService }, { type:
|
|
16314
|
+
}] }, { type: i0.ElementRef }, { type: Page }, { type: ClrCommonStringsService }, { type: KeyNavigationGridController }, { type: i0.NgZone }];
|
|
16286
16315
|
}, propDecorators: { loadingMoreItems: [{
|
|
16287
16316
|
type: Input,
|
|
16288
16317
|
args: ['clrLoadingMoreItems']
|
|
@@ -16389,11 +16418,10 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.2", ngImpor
|
|
|
16389
16418
|
*/
|
|
16390
16419
|
let clrDgActionId = 0;
|
|
16391
16420
|
class ClrDatagridActionOverflow {
|
|
16392
|
-
constructor(rowActionService, commonStrings, platformId,
|
|
16421
|
+
constructor(rowActionService, commonStrings, platformId, smartToggleService) {
|
|
16393
16422
|
this.rowActionService = rowActionService;
|
|
16394
16423
|
this.commonStrings = commonStrings;
|
|
16395
16424
|
this.platformId = platformId;
|
|
16396
|
-
this.zone = zone;
|
|
16397
16425
|
this.smartToggleService = smartToggleService;
|
|
16398
16426
|
this.openChange = new EventEmitter(false);
|
|
16399
16427
|
this.popoverId = uniqueIdFactory();
|
|
@@ -16405,10 +16433,10 @@ class ClrDatagridActionOverflow {
|
|
|
16405
16433
|
};
|
|
16406
16434
|
this._open = false;
|
|
16407
16435
|
this.subscriptions = [];
|
|
16408
|
-
|
|
16409
|
-
this.subscriptions.push(
|
|
16436
|
+
rowActionService.register();
|
|
16437
|
+
this.subscriptions.push(smartToggleService.openChange.subscribe(openState => {
|
|
16410
16438
|
this.open = openState;
|
|
16411
|
-
}),
|
|
16439
|
+
}), smartToggleService.popoverVisible.subscribe(visible => {
|
|
16412
16440
|
if (visible) {
|
|
16413
16441
|
this.initializeFocus();
|
|
16414
16442
|
}
|
|
@@ -16445,7 +16473,7 @@ class ClrDatagridActionOverflow {
|
|
|
16445
16473
|
}
|
|
16446
16474
|
}
|
|
16447
16475
|
}
|
|
16448
|
-
ClrDatagridActionOverflow.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.2", ngImport: i0, type: ClrDatagridActionOverflow, deps: [{ token: RowActionService }, { token: ClrCommonStringsService }, { token: PLATFORM_ID }, { token:
|
|
16476
|
+
ClrDatagridActionOverflow.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.2", ngImport: i0, type: ClrDatagridActionOverflow, deps: [{ token: RowActionService }, { token: ClrCommonStringsService }, { token: PLATFORM_ID }, { token: ClrPopoverToggleService }], target: i0.ɵɵFactoryTarget.Component });
|
|
16449
16477
|
ClrDatagridActionOverflow.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.2", type: ClrDatagridActionOverflow, 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: ClrPopoverHostDirective }], ngImport: i0, template: `
|
|
16450
16478
|
<button
|
|
16451
16479
|
tabindex="-1"
|
|
@@ -16516,7 +16544,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.2", ngImpor
|
|
|
16516
16544
|
return [{ type: RowActionService }, { type: ClrCommonStringsService }, { type: undefined, decorators: [{
|
|
16517
16545
|
type: Inject,
|
|
16518
16546
|
args: [PLATFORM_ID]
|
|
16519
|
-
}] }, { type:
|
|
16547
|
+
}] }, { type: ClrPopoverToggleService }];
|
|
16520
16548
|
}, propDecorators: { buttonLabel: [{
|
|
16521
16549
|
type: Input,
|
|
16522
16550
|
args: ['clrDgActionOverflowButtonLabel']
|
|
@@ -16973,8 +17001,8 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.2", ngImpor
|
|
|
16973
17001
|
class DatagridDetailRegisterer {
|
|
16974
17002
|
constructor(expandableRowsCount) {
|
|
16975
17003
|
this.expandableRowsCount = expandableRowsCount;
|
|
16976
|
-
if (
|
|
16977
|
-
|
|
17004
|
+
if (expandableRowsCount) {
|
|
17005
|
+
expandableRowsCount.register();
|
|
16978
17006
|
}
|
|
16979
17007
|
}
|
|
16980
17008
|
ngOnDestroy() {
|
|
@@ -17103,13 +17131,12 @@ const COLUMN_STATE_PROVIDER = {
|
|
|
17103
17131
|
class ClrDatagridHideableColumn {
|
|
17104
17132
|
constructor(titleTemplateRef, viewContainerRef, columnsService, columnState) {
|
|
17105
17133
|
this.titleTemplateRef = titleTemplateRef;
|
|
17106
|
-
this.viewContainerRef = viewContainerRef;
|
|
17107
17134
|
this.columnsService = columnsService;
|
|
17108
17135
|
this.columnState = columnState;
|
|
17109
17136
|
this.hiddenChange = new EventEmitter();
|
|
17110
17137
|
this.subscriptions = [];
|
|
17111
|
-
|
|
17112
|
-
if (!
|
|
17138
|
+
viewContainerRef.createEmbeddedView(titleTemplateRef);
|
|
17139
|
+
if (!columnState) {
|
|
17113
17140
|
throw new Error('The *clrDgHideableColumn directive can only be used inside of a clr-dg-column component.');
|
|
17114
17141
|
}
|
|
17115
17142
|
}
|
|
@@ -17196,7 +17223,7 @@ class ClrIfDetail {
|
|
|
17196
17223
|
this.stateChange = new EventEmitter(null);
|
|
17197
17224
|
this.subscriptions = [];
|
|
17198
17225
|
this.skip = false; // This keeps us from resetting the input and calling the toggle twice
|
|
17199
|
-
|
|
17226
|
+
detailService.enabled = true;
|
|
17200
17227
|
}
|
|
17201
17228
|
set state(model) {
|
|
17202
17229
|
if (!this.skip) {
|
|
@@ -17334,7 +17361,7 @@ class ClrDatagridPagination {
|
|
|
17334
17361
|
this.commonStrings = commonStrings;
|
|
17335
17362
|
this.detailService = detailService;
|
|
17336
17363
|
this.currentChanged = new EventEmitter(false);
|
|
17337
|
-
|
|
17364
|
+
page.activated = true;
|
|
17338
17365
|
}
|
|
17339
17366
|
/**
|
|
17340
17367
|
* Page size
|
|
@@ -17470,7 +17497,7 @@ class ClrDatagridPagination {
|
|
|
17470
17497
|
* Set the input's value to the new current page. This is needed because the code
|
|
17471
17498
|
* above may have changed the value from what the user entered in.
|
|
17472
17499
|
*/
|
|
17473
|
-
this.currentPageInputRef.nativeElement.value = this.page.current;
|
|
17500
|
+
this.currentPageInputRef.nativeElement.value = this.page.current.toString();
|
|
17474
17501
|
}
|
|
17475
17502
|
}
|
|
17476
17503
|
ClrDatagridPagination.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.2", ngImport: i0, type: ClrDatagridPagination, deps: [{ token: Page }, { token: ClrCommonStringsService }, { token: DetailService }], target: i0.ɵɵFactoryTarget.Component });
|
|
@@ -17819,10 +17846,10 @@ class ClrDatagridVirtualScrollDirective {
|
|
|
17819
17846
|
this.cdkVirtualForInputs = {
|
|
17820
17847
|
cdkVirtualForTrackBy: index => index,
|
|
17821
17848
|
};
|
|
17822
|
-
|
|
17823
|
-
|
|
17824
|
-
|
|
17825
|
-
this.datagridElementRef =
|
|
17849
|
+
items.smartenUp();
|
|
17850
|
+
datagrid.hasVirtualScroller = true;
|
|
17851
|
+
datagrid.detailService.preventFocusScroll = true;
|
|
17852
|
+
this.datagridElementRef = datagrid.el;
|
|
17826
17853
|
// default
|
|
17827
17854
|
this.cdkVirtualForTemplateCacheSize = 20;
|
|
17828
17855
|
this.mutationChanges.observe(this.datagridElementRef.nativeElement, {
|
|
@@ -18024,7 +18051,6 @@ class DatagridHeaderRenderer {
|
|
|
18024
18051
|
constructor(el, renderer, organizer, domAdapter, columnResizerService, columnsService, columnState) {
|
|
18025
18052
|
this.el = el;
|
|
18026
18053
|
this.renderer = renderer;
|
|
18027
|
-
this.organizer = organizer;
|
|
18028
18054
|
this.domAdapter = domAdapter;
|
|
18029
18055
|
this.columnResizerService = columnResizerService;
|
|
18030
18056
|
this.columnsService = columnsService;
|
|
@@ -18036,7 +18062,7 @@ class DatagridHeaderRenderer {
|
|
|
18036
18062
|
this.widthSet = false;
|
|
18037
18063
|
this.autoSet = false;
|
|
18038
18064
|
this.subscriptions = [];
|
|
18039
|
-
this.subscriptions.push(
|
|
18065
|
+
this.subscriptions.push(organizer.filterRenderSteps(DatagridRenderStep.CLEAR_WIDTHS).subscribe(() => this.clearWidth()));
|
|
18040
18066
|
}
|
|
18041
18067
|
ngOnDestroy() {
|
|
18042
18068
|
this.subscriptions.forEach(sub => sub.unsubscribe());
|
|
@@ -18184,14 +18210,13 @@ const domAdapterFactory = (platformId) => {
|
|
|
18184
18210
|
// Fixes build error
|
|
18185
18211
|
// @dynamic (https://github.com/angular/angular/issues/19698#issuecomment-338340211)
|
|
18186
18212
|
class DatagridMainRenderer {
|
|
18187
|
-
constructor(organizer, items, page,
|
|
18213
|
+
constructor(datagrid, organizer, items, page, el, renderer, detailService, tableSizeService, columnsService, ngZone, keyNavigation) {
|
|
18214
|
+
this.datagrid = datagrid;
|
|
18188
18215
|
this.organizer = organizer;
|
|
18189
18216
|
this.items = items;
|
|
18190
18217
|
this.page = page;
|
|
18191
|
-
this.domAdapter = domAdapter;
|
|
18192
18218
|
this.el = el;
|
|
18193
18219
|
this.renderer = renderer;
|
|
18194
|
-
this.detailService = detailService;
|
|
18195
18220
|
this.tableSizeService = tableSizeService;
|
|
18196
18221
|
this.columnsService = columnsService;
|
|
18197
18222
|
this.ngZone = ngZone;
|
|
@@ -18205,16 +18230,14 @@ class DatagridMainRenderer {
|
|
|
18205
18230
|
* 2) When rows are lazily loaded for the first time
|
|
18206
18231
|
*/
|
|
18207
18232
|
this.columnsSizesStable = false;
|
|
18208
|
-
this.subscriptions.push(this.
|
|
18209
|
-
|
|
18210
|
-
.subscribe(() => this.computeHeadersWidth()));
|
|
18211
|
-
this.subscriptions.push(this.page.sizeChange.subscribe(() => {
|
|
18233
|
+
this.subscriptions.push(organizer.filterRenderSteps(DatagridRenderStep.COMPUTE_COLUMN_WIDTHS).subscribe(() => this.computeHeadersWidth()));
|
|
18234
|
+
this.subscriptions.push(page.sizeChange.subscribe(() => {
|
|
18212
18235
|
if (this._heightSet) {
|
|
18213
18236
|
this.resetDatagridHeight();
|
|
18214
18237
|
}
|
|
18215
18238
|
}));
|
|
18216
|
-
this.subscriptions.push(
|
|
18217
|
-
this.subscriptions.push(
|
|
18239
|
+
this.subscriptions.push(detailService.stateChange.subscribe(state => this.toggleDetailPane(state)));
|
|
18240
|
+
this.subscriptions.push(items.change.subscribe(() => (this.shouldStabilizeColumns = true)));
|
|
18218
18241
|
}
|
|
18219
18242
|
ngOnInit() {
|
|
18220
18243
|
this.columnsService.columnsStateChange.subscribe(change => this.columnStateChanged(change));
|
|
@@ -18234,7 +18257,8 @@ class DatagridMainRenderer {
|
|
|
18234
18257
|
this.tableSizeService.table = this.el;
|
|
18235
18258
|
}
|
|
18236
18259
|
ngAfterViewChecked() {
|
|
18237
|
-
|
|
18260
|
+
const datagridIsVisible = this.checkAndUpdateVisibility();
|
|
18261
|
+
if (this.shouldStabilizeColumns && datagridIsVisible) {
|
|
18238
18262
|
this.stabilizeColumns();
|
|
18239
18263
|
}
|
|
18240
18264
|
if (this.shouldComputeHeight()) {
|
|
@@ -18337,16 +18361,20 @@ class DatagridMainRenderer {
|
|
|
18337
18361
|
case DatagridColumnChanges.WIDTH:
|
|
18338
18362
|
this.headers.get(columnIndex).setWidth(state);
|
|
18339
18363
|
this.rows.forEach(row => {
|
|
18364
|
+
var _a, _b;
|
|
18340
18365
|
if ((row === null || row === void 0 ? void 0 : row.cells.length) === this.columnsService.columns.length) {
|
|
18341
18366
|
row.cells.get(columnIndex).setWidth(state);
|
|
18367
|
+
(_b = (_a = row.expandableRow) === null || _a === void 0 ? void 0 : _a.cells.get(columnIndex)) === null || _b === void 0 ? void 0 : _b.setWidth(state);
|
|
18342
18368
|
}
|
|
18343
18369
|
});
|
|
18344
18370
|
break;
|
|
18345
18371
|
case DatagridColumnChanges.HIDDEN:
|
|
18346
18372
|
this.headers.get(columnIndex).setHidden(state);
|
|
18347
18373
|
this.rows.forEach(row => {
|
|
18374
|
+
var _a, _b;
|
|
18348
18375
|
if (row.cells && row.cells.length) {
|
|
18349
18376
|
row.cells.get(columnIndex).setHidden(state);
|
|
18377
|
+
(_b = (_a = row.expandableRow) === null || _a === void 0 ? void 0 : _a.cells.get(columnIndex)) === null || _b === void 0 ? void 0 : _b.setHidden(state);
|
|
18350
18378
|
}
|
|
18351
18379
|
});
|
|
18352
18380
|
this.keyNavigation.resetKeyGrid();
|
|
@@ -18355,7 +18383,9 @@ class DatagridMainRenderer {
|
|
|
18355
18383
|
if (state.hideable && state.hidden) {
|
|
18356
18384
|
this.headers.get(columnIndex).setHidden(state);
|
|
18357
18385
|
this.rows.forEach(row => {
|
|
18386
|
+
var _a;
|
|
18358
18387
|
row.setCellsState();
|
|
18388
|
+
(_a = row.expandableRow) === null || _a === void 0 ? void 0 : _a.setCellsState();
|
|
18359
18389
|
});
|
|
18360
18390
|
}
|
|
18361
18391
|
break;
|
|
@@ -18380,21 +18410,31 @@ class DatagridMainRenderer {
|
|
|
18380
18410
|
this.columnsSizesStable = true;
|
|
18381
18411
|
}
|
|
18382
18412
|
}
|
|
18413
|
+
checkAndUpdateVisibility() {
|
|
18414
|
+
if (this.el.nativeElement.offsetParent) {
|
|
18415
|
+
this.datagrid.datagrid.nativeElement.style.visibility = 'visible';
|
|
18416
|
+
return true;
|
|
18417
|
+
}
|
|
18418
|
+
else {
|
|
18419
|
+
this.datagrid.datagrid.nativeElement.style.visibility = 'hidden';
|
|
18420
|
+
return false;
|
|
18421
|
+
}
|
|
18422
|
+
}
|
|
18383
18423
|
}
|
|
18384
|
-
DatagridMainRenderer.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.2", ngImport: i0, type: DatagridMainRenderer, deps: [{ token:
|
|
18385
|
-
DatagridMainRenderer.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "15.2.2", type: DatagridMainRenderer, selector: "clr-datagrid", providers: [{ provide: DomAdapter, useFactory: domAdapterFactory, deps: [PLATFORM_ID] }], queries: [{ propertyName: "headers", predicate: DatagridHeaderRenderer }, { propertyName: "rows", predicate: DatagridRowRenderer
|
|
18424
|
+
DatagridMainRenderer.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.2", 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 }], target: i0.ɵɵFactoryTarget.Directive });
|
|
18425
|
+
DatagridMainRenderer.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "15.2.2", type: DatagridMainRenderer, selector: "clr-datagrid", providers: [{ provide: DomAdapter, useFactory: domAdapterFactory, deps: [PLATFORM_ID] }], queries: [{ propertyName: "headers", predicate: DatagridHeaderRenderer }, { propertyName: "rows", predicate: DatagridRowRenderer }], ngImport: i0 });
|
|
18386
18426
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.2", ngImport: i0, type: DatagridMainRenderer, decorators: [{
|
|
18387
18427
|
type: Directive,
|
|
18388
18428
|
args: [{
|
|
18389
18429
|
selector: 'clr-datagrid',
|
|
18390
18430
|
providers: [{ provide: DomAdapter, useFactory: domAdapterFactory, deps: [PLATFORM_ID] }],
|
|
18391
18431
|
}]
|
|
18392
|
-
}], ctorParameters: function () { return [{ type:
|
|
18432
|
+
}], ctorParameters: function () { return [{ type: ClrDatagrid }, { type: DatagridRenderOrganizer }, { type: Items }, { type: Page }, { type: i0.ElementRef }, { type: i0.Renderer2 }, { type: DetailService }, { type: TableSizeService }, { type: ColumnsService }, { type: i0.NgZone }, { type: KeyNavigationGridController }]; }, propDecorators: { headers: [{
|
|
18393
18433
|
type: ContentChildren,
|
|
18394
18434
|
args: [DatagridHeaderRenderer]
|
|
18395
18435
|
}], rows: [{
|
|
18396
18436
|
type: ContentChildren,
|
|
18397
|
-
args: [DatagridRowRenderer
|
|
18437
|
+
args: [DatagridRowRenderer]
|
|
18398
18438
|
}] } });
|
|
18399
18439
|
|
|
18400
18440
|
/*
|
|
@@ -18856,7 +18896,9 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.2", ngImpor
|
|
|
18856
18896
|
}] } });
|
|
18857
18897
|
function eventIsInputEvent(event) {
|
|
18858
18898
|
const targetElement = event === null || event === void 0 ? void 0 : event.target;
|
|
18859
|
-
return (targetElement === null || targetElement === void 0 ? void 0 : targetElement.tagName)
|
|
18899
|
+
return (targetElement === null || targetElement === void 0 ? void 0 : targetElement.tagName)
|
|
18900
|
+
? ['INPUT', 'TEXTAREA', 'BUTTON', 'A', 'SELECT', 'OPTION'].includes(targetElement.tagName)
|
|
18901
|
+
: false;
|
|
18860
18902
|
}
|
|
18861
18903
|
|
|
18862
18904
|
/*
|
|
@@ -19029,8 +19071,8 @@ class RecursiveChildren {
|
|
|
19029
19071
|
this.featuresService = featuresService;
|
|
19030
19072
|
this.expandService = expandService;
|
|
19031
19073
|
if (expandService) {
|
|
19032
|
-
this.subscription =
|
|
19033
|
-
if (!value && this.parent && !
|
|
19074
|
+
this.subscription = expandService.expandChange.subscribe(value => {
|
|
19075
|
+
if (!value && this.parent && !featuresService.eager && featuresService.recursion) {
|
|
19034
19076
|
// In the case of lazy-loading recursive trees, we clear the children on collapse.
|
|
19035
19077
|
// This is better in case they change between two user interaction, and that way
|
|
19036
19078
|
// the app itself can decide whether to cache them or not.
|
|
@@ -19647,7 +19689,7 @@ class ClrTreeNode {
|
|
|
19647
19689
|
this.typeAheadKeyBuffer = '';
|
|
19648
19690
|
this.typeAheadKeyEvent = new Subject();
|
|
19649
19691
|
this.subscriptions = [];
|
|
19650
|
-
if (
|
|
19692
|
+
if (featuresService.recursion) {
|
|
19651
19693
|
// I'm completely stuck, we have to hack into private properties until either
|
|
19652
19694
|
// https://github.com/angular/angular/issues/14935 or https://github.com/angular/angular/issues/15998
|
|
19653
19695
|
// are fixed
|
|
@@ -19830,7 +19872,7 @@ class ClrTreeNode {
|
|
|
19830
19872
|
}
|
|
19831
19873
|
setTabIndex(value) {
|
|
19832
19874
|
this.contentContainerTabindex = value;
|
|
19833
|
-
this.contentContainer.nativeElement.setAttribute('tabindex', value);
|
|
19875
|
+
this.contentContainer.nativeElement.setAttribute('tabindex', value.toString());
|
|
19834
19876
|
}
|
|
19835
19877
|
checkTabIndex(nodeId) {
|
|
19836
19878
|
if (isPlatformBrowser(this.platformId) && this.nodeId !== nodeId && this.contentContainerTabindex !== -1) {
|
|
@@ -19889,7 +19931,7 @@ class ClrTreeNode {
|
|
|
19889
19931
|
}
|
|
19890
19932
|
}
|
|
19891
19933
|
ClrTreeNode.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.2", ngImport: i0, type: ClrTreeNode, deps: [{ token: PLATFORM_ID }, { token: ClrTreeNode, optional: true, skipSelf: true }, { token: TreeFeaturesService }, { token: IfExpandService }, { token: ClrCommonStringsService }, { token: TreeFocusManagerService }, { token: i0.ElementRef }, { token: i0.Injector }], target: i0.ɵɵFactoryTarget.Component });
|
|
19892
|
-
ClrTreeNode.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.2", type: ClrTreeNode, selector: "clr-tree-node", inputs: { expandable: ["clrExpandable", "expandable"], disabled: ["clrDisabled", "disabled"], selected: ["clrSelected", "selected"], expanded: ["clrExpanded", "expanded"], clrForTypeAhead: "clrForTypeAhead" }, outputs: { selectedChange: "clrSelectedChange", expandedChange: "clrExpandedChange" }, host: { properties: { "class.clr-tree-node": "true", "class.disabled": "this._model.disabled" } }, providers: [TREE_FEATURES_PROVIDER, IfExpandService, { provide: LoadingListener, useExisting: IfExpandService }], queries: [{ propertyName: "treeNodeLinkList", predicate: ClrTreeNodeLink }], viewQueries: [{ propertyName: "contentContainer", first: true, predicate: ["contentContainer"], descendants: true, read: ElementRef, static: true }], ngImport: i0, template: "<!--\n ~ Copyright (c) 2016-2024 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<div\n #contentContainer\n role=\"treeitem\"\n class=\"clr-tree-node-content-container\"\n tabindex=\"-1\"\n [class.clr-form-control-disabled]=\"disabled\"\n [attr.aria-disabled]=\"disabled\"\n [attr.aria-expanded]=\"isExpandable() ? expanded : null\"\n [attr.aria-selected]=\"ariaSelected\"\n (keydown)=\"onKeyDown($event)\"\n (focus)=\"broadcastFocusOnContainer()\"\n>\n <button\n *ngIf=\"isExpandable() && !isModelLoading && !expandService.loading\"\n aria-hidden=\"true\"\n type=\"button\"\n tabindex=\"-1\"\n class=\"clr-treenode-caret\"\n (click)=\"expandService.toggle();\"\n (focus)=\"focusTreeNode()\"\n [disabled]=\"disabled\"\n >\n <cds-icon\n class=\"clr-treenode-caret-icon\"\n shape=\"angle\"\n [attr.direction]=\"expandService.expanded ? 'down' : 'right'\"\n ></cds-icon>\n </button>\n <div class=\"clr-treenode-spinner-container\" *ngIf=\"expandService.loading || isModelLoading\">\n <span class=\"clr-treenode-spinner spinner\"></span>\n </div>\n <div class=\"clr-checkbox-wrapper clr-treenode-checkbox\" *ngIf=\"featuresService.selectable\">\n <input\n aria-hidden=\"true\"\n type=\"checkbox\"\n id=\"{{nodeId}}-check\"\n class=\"clr-checkbox\"\n [disabled]=\"disabled\"\n [checked]=\"_model.selected.value === STATES.SELECTED\"\n [indeterminate]=\"_model.selected.value === STATES.INDETERMINATE\"\n (change)=\"_model.toggleSelection(featuresService.eager)\"\n (focus)=\"focusTreeNode()\"\n tabindex=\"-1\"\n />\n <label for=\"{{nodeId}}-check\" class=\"clr-control-label\">\n <ng-container [ngTemplateOutlet]=\"treenodeContent\"></ng-container>\n </label>\n </div>\n <div\n class=\"clr-treenode-content\"\n [class.clr-treenode-text-only]=\"treeNodeContentTextOnly\"\n (mouseup)=\"focusTreeNode()\"\n *ngIf=\"!featuresService.selectable\"\n >\n <ng-container [ngTemplateOutlet]=\"treenodeContent\"></ng-container>\n </div>\n\n <ng-template #treenodeContent>\n <ng-content></ng-content>\n <div class=\"clr-sr-only\" *ngIf=\"featuresService.selectable || ariaSelected\">\n <span
|
|
19934
|
+
ClrTreeNode.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.2", type: ClrTreeNode, selector: "clr-tree-node", inputs: { expandable: ["clrExpandable", "expandable"], disabled: ["clrDisabled", "disabled"], selected: ["clrSelected", "selected"], expanded: ["clrExpanded", "expanded"], clrForTypeAhead: "clrForTypeAhead" }, outputs: { selectedChange: "clrSelectedChange", expandedChange: "clrExpandedChange" }, host: { properties: { "class.clr-tree-node": "true", "class.disabled": "this._model.disabled" } }, providers: [TREE_FEATURES_PROVIDER, IfExpandService, { provide: LoadingListener, useExisting: IfExpandService }], queries: [{ propertyName: "treeNodeLinkList", predicate: ClrTreeNodeLink }], viewQueries: [{ propertyName: "contentContainer", first: true, predicate: ["contentContainer"], descendants: true, read: ElementRef, static: true }], ngImport: i0, template: "<!--\n ~ Copyright (c) 2016-2024 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<div\n #contentContainer\n role=\"treeitem\"\n class=\"clr-tree-node-content-container\"\n tabindex=\"-1\"\n [class.clr-form-control-disabled]=\"disabled\"\n [attr.aria-disabled]=\"disabled\"\n [attr.aria-expanded]=\"isExpandable() ? expanded : null\"\n [attr.aria-selected]=\"ariaSelected\"\n (keydown)=\"onKeyDown($event)\"\n (focus)=\"broadcastFocusOnContainer()\"\n>\n <button\n *ngIf=\"isExpandable() && !isModelLoading && !expandService.loading\"\n aria-hidden=\"true\"\n type=\"button\"\n tabindex=\"-1\"\n class=\"clr-treenode-caret\"\n (click)=\"expandService.toggle();\"\n (focus)=\"focusTreeNode()\"\n [disabled]=\"disabled\"\n >\n <cds-icon\n class=\"clr-treenode-caret-icon\"\n shape=\"angle\"\n [attr.direction]=\"expandService.expanded ? 'down' : 'right'\"\n ></cds-icon>\n </button>\n <div class=\"clr-treenode-spinner-container\" *ngIf=\"expandService.loading || isModelLoading\">\n <span class=\"clr-treenode-spinner spinner\"></span>\n </div>\n <div class=\"clr-checkbox-wrapper clr-treenode-checkbox\" *ngIf=\"featuresService.selectable\">\n <input\n aria-hidden=\"true\"\n type=\"checkbox\"\n id=\"{{nodeId}}-check\"\n class=\"clr-checkbox\"\n [disabled]=\"disabled\"\n [checked]=\"_model.selected.value === STATES.SELECTED\"\n [indeterminate]=\"_model.selected.value === STATES.INDETERMINATE\"\n (change)=\"_model.toggleSelection(featuresService.eager)\"\n (focus)=\"focusTreeNode()\"\n tabindex=\"-1\"\n />\n <label for=\"{{nodeId}}-check\" class=\"clr-control-label\">\n <ng-container [ngTemplateOutlet]=\"treenodeContent\"></ng-container>\n </label>\n </div>\n <div\n class=\"clr-treenode-content\"\n [class.clr-treenode-text-only]=\"treeNodeContentTextOnly\"\n (mouseup)=\"focusTreeNode()\"\n *ngIf=\"!featuresService.selectable\"\n >\n <ng-container [ngTemplateOutlet]=\"treenodeContent\"></ng-container>\n </div>\n\n <ng-template #treenodeContent>\n <ng-content></ng-content>\n <div class=\"clr-sr-only\" *ngIf=\"featuresService.selectable || ariaSelected\">\n <span> {{ariaSelected ? commonStrings.keys.selectedTreeNode : commonStrings.keys.unselectedTreeNode}}</span>\n </div>\n </ng-template>\n</div>\n<div\n class=\"clr-treenode-children\"\n [@toggleChildrenAnim]=\"expandService.expanded ? 'expanded' : 'collapsed'\"\n [attr.role]=\"isExpandable() && !featuresService.recursion ? 'group' : null\"\n>\n <ng-content select=\"clr-tree-node\"></ng-content>\n <ng-content select=\"[clrIfExpanded]\"></ng-content>\n <clr-recursive-children [parent]=\"_model\"></clr-recursive-children>\n</div>\n", dependencies: [{ kind: "directive", type: i5.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i5.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "directive", type: CdsIconCustomTag, selector: "cds-icon" }, { kind: "component", type: RecursiveChildren, selector: "clr-recursive-children", inputs: ["parent", "children"] }], animations: [
|
|
19893
19935
|
trigger('toggleChildrenAnim', [
|
|
19894
19936
|
transition('collapsed => expanded', [style({ height: 0 }), animate(200, style({ height: '*' }))]),
|
|
19895
19937
|
transition('expanded => collapsed', [style({ height: '*' }), animate(200, style({ height: 0 }))]),
|
|
@@ -19909,7 +19951,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.2", ngImpor
|
|
|
19909
19951
|
], host: {
|
|
19910
19952
|
'[class.clr-tree-node]': 'true',
|
|
19911
19953
|
'[class.disabled]': 'this._model.disabled',
|
|
19912
|
-
}, template: "<!--\n ~ Copyright (c) 2016-2024 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<div\n #contentContainer\n role=\"treeitem\"\n class=\"clr-tree-node-content-container\"\n tabindex=\"-1\"\n [class.clr-form-control-disabled]=\"disabled\"\n [attr.aria-disabled]=\"disabled\"\n [attr.aria-expanded]=\"isExpandable() ? expanded : null\"\n [attr.aria-selected]=\"ariaSelected\"\n (keydown)=\"onKeyDown($event)\"\n (focus)=\"broadcastFocusOnContainer()\"\n>\n <button\n *ngIf=\"isExpandable() && !isModelLoading && !expandService.loading\"\n aria-hidden=\"true\"\n type=\"button\"\n tabindex=\"-1\"\n class=\"clr-treenode-caret\"\n (click)=\"expandService.toggle();\"\n (focus)=\"focusTreeNode()\"\n [disabled]=\"disabled\"\n >\n <cds-icon\n class=\"clr-treenode-caret-icon\"\n shape=\"angle\"\n [attr.direction]=\"expandService.expanded ? 'down' : 'right'\"\n ></cds-icon>\n </button>\n <div class=\"clr-treenode-spinner-container\" *ngIf=\"expandService.loading || isModelLoading\">\n <span class=\"clr-treenode-spinner spinner\"></span>\n </div>\n <div class=\"clr-checkbox-wrapper clr-treenode-checkbox\" *ngIf=\"featuresService.selectable\">\n <input\n aria-hidden=\"true\"\n type=\"checkbox\"\n id=\"{{nodeId}}-check\"\n class=\"clr-checkbox\"\n [disabled]=\"disabled\"\n [checked]=\"_model.selected.value === STATES.SELECTED\"\n [indeterminate]=\"_model.selected.value === STATES.INDETERMINATE\"\n (change)=\"_model.toggleSelection(featuresService.eager)\"\n (focus)=\"focusTreeNode()\"\n tabindex=\"-1\"\n />\n <label for=\"{{nodeId}}-check\" class=\"clr-control-label\">\n <ng-container [ngTemplateOutlet]=\"treenodeContent\"></ng-container>\n </label>\n </div>\n <div\n class=\"clr-treenode-content\"\n [class.clr-treenode-text-only]=\"treeNodeContentTextOnly\"\n (mouseup)=\"focusTreeNode()\"\n *ngIf=\"!featuresService.selectable\"\n >\n <ng-container [ngTemplateOutlet]=\"treenodeContent\"></ng-container>\n </div>\n\n <ng-template #treenodeContent>\n <ng-content></ng-content>\n <div class=\"clr-sr-only\" *ngIf=\"featuresService.selectable || ariaSelected\">\n <span
|
|
19954
|
+
}, template: "<!--\n ~ Copyright (c) 2016-2024 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<div\n #contentContainer\n role=\"treeitem\"\n class=\"clr-tree-node-content-container\"\n tabindex=\"-1\"\n [class.clr-form-control-disabled]=\"disabled\"\n [attr.aria-disabled]=\"disabled\"\n [attr.aria-expanded]=\"isExpandable() ? expanded : null\"\n [attr.aria-selected]=\"ariaSelected\"\n (keydown)=\"onKeyDown($event)\"\n (focus)=\"broadcastFocusOnContainer()\"\n>\n <button\n *ngIf=\"isExpandable() && !isModelLoading && !expandService.loading\"\n aria-hidden=\"true\"\n type=\"button\"\n tabindex=\"-1\"\n class=\"clr-treenode-caret\"\n (click)=\"expandService.toggle();\"\n (focus)=\"focusTreeNode()\"\n [disabled]=\"disabled\"\n >\n <cds-icon\n class=\"clr-treenode-caret-icon\"\n shape=\"angle\"\n [attr.direction]=\"expandService.expanded ? 'down' : 'right'\"\n ></cds-icon>\n </button>\n <div class=\"clr-treenode-spinner-container\" *ngIf=\"expandService.loading || isModelLoading\">\n <span class=\"clr-treenode-spinner spinner\"></span>\n </div>\n <div class=\"clr-checkbox-wrapper clr-treenode-checkbox\" *ngIf=\"featuresService.selectable\">\n <input\n aria-hidden=\"true\"\n type=\"checkbox\"\n id=\"{{nodeId}}-check\"\n class=\"clr-checkbox\"\n [disabled]=\"disabled\"\n [checked]=\"_model.selected.value === STATES.SELECTED\"\n [indeterminate]=\"_model.selected.value === STATES.INDETERMINATE\"\n (change)=\"_model.toggleSelection(featuresService.eager)\"\n (focus)=\"focusTreeNode()\"\n tabindex=\"-1\"\n />\n <label for=\"{{nodeId}}-check\" class=\"clr-control-label\">\n <ng-container [ngTemplateOutlet]=\"treenodeContent\"></ng-container>\n </label>\n </div>\n <div\n class=\"clr-treenode-content\"\n [class.clr-treenode-text-only]=\"treeNodeContentTextOnly\"\n (mouseup)=\"focusTreeNode()\"\n *ngIf=\"!featuresService.selectable\"\n >\n <ng-container [ngTemplateOutlet]=\"treenodeContent\"></ng-container>\n </div>\n\n <ng-template #treenodeContent>\n <ng-content></ng-content>\n <div class=\"clr-sr-only\" *ngIf=\"featuresService.selectable || ariaSelected\">\n <span> {{ariaSelected ? commonStrings.keys.selectedTreeNode : commonStrings.keys.unselectedTreeNode}}</span>\n </div>\n </ng-template>\n</div>\n<div\n class=\"clr-treenode-children\"\n [@toggleChildrenAnim]=\"expandService.expanded ? 'expanded' : 'collapsed'\"\n [attr.role]=\"isExpandable() && !featuresService.recursion ? 'group' : null\"\n>\n <ng-content select=\"clr-tree-node\"></ng-content>\n <ng-content select=\"[clrIfExpanded]\"></ng-content>\n <clr-recursive-children [parent]=\"_model\"></clr-recursive-children>\n</div>\n" }]
|
|
19913
19955
|
}], ctorParameters: function () {
|
|
19914
19956
|
return [{ type: undefined, decorators: [{
|
|
19915
19957
|
type: Inject,
|
|
@@ -19958,18 +20000,21 @@ function trimAndLowerCase(value) {
|
|
|
19958
20000
|
* The full license information can be found in LICENSE in the root directory of this project.
|
|
19959
20001
|
*/
|
|
19960
20002
|
class ClrTree {
|
|
19961
|
-
constructor(featuresService, focusManagerService,
|
|
20003
|
+
constructor(featuresService, focusManagerService, renderer, el, ngZone) {
|
|
19962
20004
|
this.featuresService = featuresService;
|
|
19963
20005
|
this.focusManagerService = focusManagerService;
|
|
20006
|
+
this.renderer = renderer;
|
|
20007
|
+
this.el = el;
|
|
19964
20008
|
this.subscriptions = [];
|
|
19965
|
-
|
|
19966
|
-
|
|
20009
|
+
this._isMultiSelectable = false;
|
|
20010
|
+
const subscription = ngZone.runOutsideAngular(() => fromEvent(el.nativeElement, 'focusin').subscribe((event) => {
|
|
20011
|
+
if (event.target === el.nativeElement) {
|
|
19967
20012
|
// After discussing with the team, I've made it so that when the tree receives focus, the first visible node will be focused.
|
|
19968
20013
|
// This will prevent from the page scrolling abruptly to the first selected node if it exist in a deeply nested tree.
|
|
19969
|
-
|
|
20014
|
+
focusManagerService.focusFirstVisibleNode();
|
|
19970
20015
|
// when the first child gets focus,
|
|
19971
20016
|
// tree should no longer have tabindex of 0.
|
|
19972
|
-
renderer.removeAttribute(nativeElement, 'tabindex');
|
|
20017
|
+
renderer.removeAttribute(el.nativeElement, 'tabindex');
|
|
19973
20018
|
}
|
|
19974
20019
|
}));
|
|
19975
20020
|
this.subscriptions.push(subscription);
|
|
@@ -19978,17 +20023,28 @@ class ClrTree {
|
|
|
19978
20023
|
this.featuresService.eager = !value;
|
|
19979
20024
|
}
|
|
19980
20025
|
get isMultiSelectable() {
|
|
19981
|
-
return this.
|
|
20026
|
+
return this._isMultiSelectable;
|
|
19982
20027
|
}
|
|
19983
20028
|
ngAfterContentInit() {
|
|
19984
20029
|
this.setRootNodes();
|
|
19985
20030
|
this.subscriptions.push(this.rootNodes.changes.subscribe(() => {
|
|
20031
|
+
this.setMultiSelectable();
|
|
19986
20032
|
this.setRootNodes();
|
|
19987
20033
|
}));
|
|
19988
20034
|
}
|
|
19989
20035
|
ngOnDestroy() {
|
|
19990
20036
|
this.subscriptions.forEach(sub => sub.unsubscribe());
|
|
19991
20037
|
}
|
|
20038
|
+
setMultiSelectable() {
|
|
20039
|
+
if (this.featuresService.selectable && this.rootNodes.length > 0) {
|
|
20040
|
+
this._isMultiSelectable = true;
|
|
20041
|
+
this.renderer.setAttribute(this.el.nativeElement, 'aria-multiselectable', 'true');
|
|
20042
|
+
}
|
|
20043
|
+
else {
|
|
20044
|
+
this._isMultiSelectable = false;
|
|
20045
|
+
this.renderer.removeAttribute(this.el.nativeElement, 'aria-multiselectable');
|
|
20046
|
+
}
|
|
20047
|
+
}
|
|
19992
20048
|
setRootNodes() {
|
|
19993
20049
|
// if node has no parent, it's a root node
|
|
19994
20050
|
// for recursive tree, this.rootNodes registers also nested children
|
|
@@ -19996,8 +20052,8 @@ class ClrTree {
|
|
|
19996
20052
|
this.focusManagerService.rootNodeModels = this.rootNodes.map(node => node._model).filter(node => !node.parent);
|
|
19997
20053
|
}
|
|
19998
20054
|
}
|
|
19999
|
-
ClrTree.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.2", ngImport: i0, type: ClrTree, deps: [{ token: TreeFeaturesService }, { token: TreeFocusManagerService }, { token: i0.
|
|
20000
|
-
ClrTree.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.2", type: ClrTree, selector: "clr-tree", inputs: { lazy: ["clrLazy", "lazy"] }, host: { attributes: { "tabindex": "0" }, properties: { "attr.role": "\"tree\""
|
|
20055
|
+
ClrTree.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.2", ngImport: i0, type: ClrTree, deps: [{ token: TreeFeaturesService }, { token: TreeFocusManagerService }, { token: i0.Renderer2 }, { token: i0.ElementRef }, { token: i0.NgZone }], target: i0.ɵɵFactoryTarget.Component });
|
|
20056
|
+
ClrTree.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.2", type: ClrTree, selector: "clr-tree", inputs: { lazy: ["clrLazy", "lazy"] }, host: { attributes: { "tabindex": "0" }, properties: { "attr.role": "\"tree\"" } }, providers: [TREE_FEATURES_PROVIDER, TreeFocusManagerService], queries: [{ propertyName: "rootNodes", predicate: ClrTreeNode }], ngImport: i0, template: `
|
|
20001
20057
|
<ng-content></ng-content>
|
|
20002
20058
|
<clr-recursive-children
|
|
20003
20059
|
*ngIf="featuresService.recursion"
|
|
@@ -20019,10 +20075,9 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.2", ngImpor
|
|
|
20019
20075
|
host: {
|
|
20020
20076
|
tabindex: '0',
|
|
20021
20077
|
'[attr.role]': '"tree"',
|
|
20022
|
-
'[attr.aria-multiselectable]': 'isMultiSelectable',
|
|
20023
20078
|
},
|
|
20024
20079
|
}]
|
|
20025
|
-
}], ctorParameters: function () { return [{ type: TreeFeaturesService }, { type: TreeFocusManagerService }, { type: i0.
|
|
20080
|
+
}], ctorParameters: function () { return [{ type: TreeFeaturesService }, { type: TreeFocusManagerService }, { type: i0.Renderer2 }, { type: i0.ElementRef }, { type: i0.NgZone }]; }, propDecorators: { rootNodes: [{
|
|
20026
20081
|
type: ContentChildren,
|
|
20027
20082
|
args: [ClrTreeNode]
|
|
20028
20083
|
}], lazy: [{
|
|
@@ -20109,7 +20164,7 @@ class DropdownFocusHandler {
|
|
|
20109
20164
|
this._unlistenFuncs = [];
|
|
20110
20165
|
this.resetChildren();
|
|
20111
20166
|
this.moveToFirstItemWhenOpen();
|
|
20112
|
-
if (!
|
|
20167
|
+
if (!parent) {
|
|
20113
20168
|
this.handleRootFocus();
|
|
20114
20169
|
}
|
|
20115
20170
|
}
|
|
@@ -20309,11 +20364,10 @@ class ClrDropdown {
|
|
|
20309
20364
|
this.parent = parent;
|
|
20310
20365
|
this.toggleService = toggleService;
|
|
20311
20366
|
this.focusHandler = focusHandler;
|
|
20312
|
-
this.cdr = cdr;
|
|
20313
20367
|
this.isMenuClosable = true;
|
|
20314
20368
|
this.subscriptions = [];
|
|
20315
|
-
this.subscriptions.push(dropdownService.changes.subscribe(value => (
|
|
20316
|
-
this.subscriptions.push(toggleService.openChange.subscribe(() =>
|
|
20369
|
+
this.subscriptions.push(dropdownService.changes.subscribe(value => (toggleService.open = value)));
|
|
20370
|
+
this.subscriptions.push(toggleService.openChange.subscribe(() => cdr.markForCheck()));
|
|
20317
20371
|
}
|
|
20318
20372
|
ngOnDestroy() {
|
|
20319
20373
|
this.subscriptions.forEach(sub => sub.unsubscribe());
|
|
@@ -21952,12 +22006,12 @@ class ClrHeader {
|
|
|
21952
22006
|
this.isNavLevel2OnPage = false;
|
|
21953
22007
|
this.openNavLevel = null;
|
|
21954
22008
|
this.responsiveNavCodes = ResponsiveNavCodes;
|
|
21955
|
-
this._subscription =
|
|
22009
|
+
this._subscription = responsiveNavService.registeredNavs.subscribe({
|
|
21956
22010
|
next: (navLevelList) => {
|
|
21957
22011
|
this.initializeNavTriggers(navLevelList);
|
|
21958
22012
|
},
|
|
21959
22013
|
});
|
|
21960
|
-
this._subscription.add(
|
|
22014
|
+
this._subscription.add(responsiveNavService.navControl
|
|
21961
22015
|
.pipe(filter(({ controlCode }) => controlCode === ResponsiveNavCodes.NAV_CLOSE || controlCode === ResponsiveNavCodes.NAV_CLOSE_ALL))
|
|
21962
22016
|
.subscribe(() => {
|
|
21963
22017
|
this.openNavLevel = null;
|
|
@@ -22090,18 +22144,23 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.2", ngImpor
|
|
|
22090
22144
|
* This software is released under MIT license.
|
|
22091
22145
|
* The full license information can be found in LICENSE in the root directory of this project.
|
|
22092
22146
|
*/
|
|
22093
|
-
const
|
|
22094
|
-
const
|
|
22095
|
-
|
|
22096
|
-
|
|
22097
|
-
|
|
22098
|
-
|
|
22147
|
+
const createCloseButton = (document, ariaLabel) => {
|
|
22148
|
+
const closeButton = document.createElement('button');
|
|
22149
|
+
closeButton.setAttribute('aria-label', ariaLabel);
|
|
22150
|
+
closeButton.setAttribute('aria-hidden', 'true');
|
|
22151
|
+
closeButton.innerHTML = `
|
|
22152
|
+
<cds-icon
|
|
22153
|
+
inner-offset="1"
|
|
22154
|
+
shape="close"
|
|
22155
|
+
size="32"
|
|
22156
|
+
</cds-icon>
|
|
22157
|
+
`;
|
|
22099
22158
|
/**
|
|
22100
22159
|
* The button is hidden by default based on our Desktop-first approach.
|
|
22101
22160
|
*/
|
|
22102
|
-
|
|
22103
|
-
|
|
22104
|
-
return
|
|
22161
|
+
closeButton.setAttribute('hidden', 'true');
|
|
22162
|
+
closeButton.className = 'clr-nav-close';
|
|
22163
|
+
return closeButton;
|
|
22105
22164
|
};
|
|
22106
22165
|
class ClrNavLevel {
|
|
22107
22166
|
constructor(platformId, cdkTrapFocus, responsiveNavService, elementRef, renderer, injector) {
|
|
@@ -22153,7 +22212,7 @@ class ClrNavLevel {
|
|
|
22153
22212
|
this.addNavClass(this.level);
|
|
22154
22213
|
}
|
|
22155
22214
|
ngAfterViewInit() {
|
|
22156
|
-
const closeButton =
|
|
22215
|
+
const closeButton = createCloseButton(this._document, this.closeButtonAriaLabel);
|
|
22157
22216
|
this.renderer.listen(closeButton, 'click', this.close.bind(this));
|
|
22158
22217
|
this.renderer.insertBefore(this.elementRef.nativeElement, closeButton, this.elementRef.nativeElement.firstChild); // Adding the button at the top of the nav
|
|
22159
22218
|
if (this._document.body.clientWidth < LARGE_BREAKPOINT) {
|
|
@@ -22576,8 +22635,6 @@ class ClrTabLink {
|
|
|
22576
22635
|
this.ifActiveService = ifActiveService;
|
|
22577
22636
|
this.id = id;
|
|
22578
22637
|
this.el = el;
|
|
22579
|
-
this.cfr = cfr;
|
|
22580
|
-
this.viewContainerRef = viewContainerRef;
|
|
22581
22638
|
this.tabsService = tabsService;
|
|
22582
22639
|
this.tabsId = tabsId;
|
|
22583
22640
|
if (!this.tabLinkId) {
|
|
@@ -22586,9 +22643,9 @@ class ClrTabLink {
|
|
|
22586
22643
|
// Tab links can be rendered in one of two places: in the main area or inside the overflow dropdown menu.
|
|
22587
22644
|
// Here, we create a container so that its template can be used to create embeddedView on the fly.
|
|
22588
22645
|
// See TabsService's renderView() method and how it's used in Tabs class for an example.
|
|
22589
|
-
const factory =
|
|
22590
|
-
this.templateRefContainer =
|
|
22591
|
-
[
|
|
22646
|
+
const factory = cfr.resolveComponentFactory(TemplateRefContainer);
|
|
22647
|
+
this.templateRefContainer = viewContainerRef.createComponent(factory, undefined, undefined, [
|
|
22648
|
+
[el.nativeElement],
|
|
22592
22649
|
]).instance;
|
|
22593
22650
|
}
|
|
22594
22651
|
get inOverflow() {
|
|
@@ -23177,7 +23234,7 @@ class ClrVerticalNav {
|
|
|
23177
23234
|
this._navGroupRegistrationService = _navGroupRegistrationService;
|
|
23178
23235
|
this.commonStrings = commonStrings;
|
|
23179
23236
|
this._collapsedChanged = new EventEmitter(true);
|
|
23180
|
-
this._sub =
|
|
23237
|
+
this._sub = _navService.collapsedChanged.subscribe(value => {
|
|
23181
23238
|
this._collapsedChanged.emit(value);
|
|
23182
23239
|
});
|
|
23183
23240
|
}
|
|
@@ -23265,27 +23322,26 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.2", ngImpor
|
|
|
23265
23322
|
const EXPANDED_STATE = 'expanded';
|
|
23266
23323
|
const COLLAPSED_STATE = 'collapsed';
|
|
23267
23324
|
class ClrVerticalNavGroup {
|
|
23268
|
-
constructor(_itemExpand, _navGroupRegistrationService,
|
|
23325
|
+
constructor(_itemExpand, _navGroupRegistrationService, navGroupService, _navService, commonStrings) {
|
|
23269
23326
|
this._itemExpand = _itemExpand;
|
|
23270
23327
|
this._navGroupRegistrationService = _navGroupRegistrationService;
|
|
23271
|
-
this._navGroupService = _navGroupService;
|
|
23272
23328
|
this._navService = _navService;
|
|
23273
23329
|
this.commonStrings = commonStrings;
|
|
23274
23330
|
this.expandedChange = new EventEmitter(true);
|
|
23275
23331
|
this.wasExpanded = false;
|
|
23276
23332
|
this._subscriptions = [];
|
|
23277
23333
|
this._expandAnimationState = COLLAPSED_STATE;
|
|
23278
|
-
|
|
23334
|
+
_navGroupRegistrationService.registerNavGroup();
|
|
23279
23335
|
// FIXME: This subscription handles a corner case
|
|
23280
23336
|
// Vertical Nav collapse requires the animation to run first and then
|
|
23281
23337
|
// remove the nodes from the DOM. If the user directly sets the input
|
|
23282
23338
|
// on the clrIfExpanded directive, we have no chance to run the animation
|
|
23283
23339
|
// and wait for it to complete. This subscription makes sure that the
|
|
23284
23340
|
// animation states are correct for that edge case.
|
|
23285
|
-
this._subscriptions.push(
|
|
23341
|
+
this._subscriptions.push(_itemExpand.expandChange.subscribe(value => {
|
|
23286
23342
|
if (value && this.expandAnimationState === COLLAPSED_STATE) {
|
|
23287
|
-
if (
|
|
23288
|
-
|
|
23343
|
+
if (_navService.collapsed) {
|
|
23344
|
+
_navService.collapsed = false;
|
|
23289
23345
|
}
|
|
23290
23346
|
this.expandAnimationState = EXPANDED_STATE;
|
|
23291
23347
|
}
|
|
@@ -23295,7 +23351,7 @@ class ClrVerticalNavGroup {
|
|
|
23295
23351
|
}));
|
|
23296
23352
|
// 1. If the nav is collapsing, close the open nav group + save its state
|
|
23297
23353
|
// 2. If the nav is expanding, expand the nav group if the previous state was expanded
|
|
23298
|
-
this._subscriptions.push(
|
|
23354
|
+
this._subscriptions.push(_navService.animateOnCollapsed.subscribe((goingToCollapse) => {
|
|
23299
23355
|
if (goingToCollapse && this.expanded) {
|
|
23300
23356
|
this.wasExpanded = true;
|
|
23301
23357
|
this.expandAnimationState = COLLAPSED_STATE;
|
|
@@ -23306,7 +23362,7 @@ class ClrVerticalNavGroup {
|
|
|
23306
23362
|
}
|
|
23307
23363
|
}));
|
|
23308
23364
|
// If a link is clicked, expand the nav group
|
|
23309
|
-
this._subscriptions.push(
|
|
23365
|
+
this._subscriptions.push(navGroupService.expandChange.subscribe((expand) => {
|
|
23310
23366
|
if (expand && !this.expanded) {
|
|
23311
23367
|
this.expandGroup();
|
|
23312
23368
|
}
|
|
@@ -23435,7 +23491,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.2", ngImpor
|
|
|
23435
23491
|
class ClrVerticalNavIcon {
|
|
23436
23492
|
constructor(_verticalNavIconService) {
|
|
23437
23493
|
this._verticalNavIconService = _verticalNavIconService;
|
|
23438
|
-
|
|
23494
|
+
_verticalNavIconService.registerIcon();
|
|
23439
23495
|
}
|
|
23440
23496
|
ngOnDestroy() {
|
|
23441
23497
|
this._verticalNavIconService.unregisterIcon();
|
|
@@ -23603,9 +23659,10 @@ class ClrModalConfigurationService {
|
|
|
23603
23659
|
}
|
|
23604
23660
|
}
|
|
23605
23661
|
ClrModalConfigurationService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.2", ngImport: i0, type: ClrModalConfigurationService, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
|
|
23606
|
-
ClrModalConfigurationService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "15.2.2", ngImport: i0, type: ClrModalConfigurationService });
|
|
23662
|
+
ClrModalConfigurationService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "15.2.2", ngImport: i0, type: ClrModalConfigurationService, providedIn: 'root' });
|
|
23607
23663
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.2", ngImport: i0, type: ClrModalConfigurationService, decorators: [{
|
|
23608
|
-
type: Injectable
|
|
23664
|
+
type: Injectable,
|
|
23665
|
+
args: [{ providedIn: 'root' }]
|
|
23609
23666
|
}] });
|
|
23610
23667
|
|
|
23611
23668
|
/*
|
|
@@ -23664,6 +23721,13 @@ class ClrModal {
|
|
|
23664
23721
|
this._openChanged.emit(true);
|
|
23665
23722
|
this.modalStackService.trackModalOpen(this);
|
|
23666
23723
|
}
|
|
23724
|
+
backdropClick() {
|
|
23725
|
+
if (this.staticBackdrop) {
|
|
23726
|
+
this.title.nativeElement.focus();
|
|
23727
|
+
return;
|
|
23728
|
+
}
|
|
23729
|
+
this.close();
|
|
23730
|
+
}
|
|
23667
23731
|
close() {
|
|
23668
23732
|
if (this.stopClose) {
|
|
23669
23733
|
this.altClose.emit(false);
|
|
@@ -23683,7 +23747,7 @@ class ClrModal {
|
|
|
23683
23747
|
}
|
|
23684
23748
|
}
|
|
23685
23749
|
ClrModal.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.2", ngImport: i0, type: ClrModal, deps: [{ token: ScrollingService }, { token: ClrCommonStringsService }, { token: ModalStackService }, { token: ClrModalConfigurationService }], target: i0.ɵɵFactoryTarget.Component });
|
|
23686
|
-
ClrModal.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.2", type: ClrModal, selector: "clr-modal", inputs: { _open: ["clrModalOpen", "_open"], closable: ["clrModalClosable", "closable"], closeButtonAriaLabel: ["clrModalCloseButtonAriaLabel", "closeButtonAriaLabel"], size: ["clrModalSize", "size"], staticBackdrop: ["clrModalStaticBackdrop", "staticBackdrop"], skipAnimation: ["clrModalSkipAnimation", "skipAnimation"], stopClose: ["clrModalPreventClose", "stopClose"], labelledBy: ["clrModalLabelledById", "labelledBy"], bypassScrollService: ["clrModalOverrideScrollService", "bypassScrollService"] }, outputs: { _openChanged: "clrModalOpenChange", altClose: "clrModalAlternateClose" }, host: { properties: { "class.open": "this._open" } }, usesOnChanges: true, ngImport: i0, template: "<!--\n ~ Copyright (c) 2016-2024 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<div *ngIf=\"_open\" class=\"modal\" [class.modal-full-screen]=\"size == 'full-screen'\">\n <!--fixme: revisit when ngClass works with exit animation-->\n <div\n cdkTrapFocus\n [cdkTrapFocusAutoCapture]=\"true\"\n [@fadeMove]=\"fadeMove\"\n (@fadeMove.done)=\"fadeDone($event)\"\n class=\"modal-dialog\"\n [class.modal-sm]=\"size == 'sm'\"\n [class.modal-lg]=\"size == 'lg'\"\n [class.modal-xl]=\"size == 'xl'\"\n role=\"dialog\"\n aria-modal=\"true\"\n [attr.aria-hidden]=\"!_open\"\n [attr.aria-labelledby]=\"labelledBy || modalId\"\n >\n <div class=\"clr-sr-only\">{{commonStrings.keys.modalContentStart}}</div>\n <div class=\"modal-content-wrapper\">\n <!-- only used in wizards -->\n <ng-content select=\".modal-nav\"></ng-content>\n\n <div class=\"modal-content\">\n <div class=\"modal-header--accessible\">\n <div class=\"modal-title-wrapper\" id=\"{{modalId}}\" cdkFocusInitial tabindex=\"-1\">\n <ng-content select=\".modal-title\"></ng-content>\n </div>\n <button\n type=\"button\"\n [attr.aria-label]=\"closeButtonAriaLabel || commonStrings.keys.close\"\n class=\"close\"\n *ngIf=\"closable\"\n (click)=\"close()\"\n >\n <cds-icon shape=\"window-close\"></cds-icon>\n </button>\n </div>\n <div class=\"modal-body-wrapper\">\n <ng-content select=\".modal-body\"></ng-content>\n </div>\n <ng-content select=\".modal-footer\"></ng-content>\n </div>\n </div>\n <div class=\"clr-sr-only\">{{commonStrings.keys.modalContentEnd}}</div>\n </div>\n\n <div [@fade] *ngIf=\"backdrop\" class=\"modal-backdrop\" aria-hidden=\"true\" (click)=\"
|
|
23750
|
+
ClrModal.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.2", type: ClrModal, selector: "clr-modal", inputs: { _open: ["clrModalOpen", "_open"], closable: ["clrModalClosable", "closable"], closeButtonAriaLabel: ["clrModalCloseButtonAriaLabel", "closeButtonAriaLabel"], size: ["clrModalSize", "size"], staticBackdrop: ["clrModalStaticBackdrop", "staticBackdrop"], skipAnimation: ["clrModalSkipAnimation", "skipAnimation"], stopClose: ["clrModalPreventClose", "stopClose"], labelledBy: ["clrModalLabelledById", "labelledBy"], bypassScrollService: ["clrModalOverrideScrollService", "bypassScrollService"] }, outputs: { _openChanged: "clrModalOpenChange", altClose: "clrModalAlternateClose" }, host: { properties: { "class.open": "this._open" } }, viewQueries: [{ propertyName: "title", first: true, predicate: ["title"], descendants: true }], usesOnChanges: true, ngImport: i0, template: "<!--\n ~ Copyright (c) 2016-2024 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<div *ngIf=\"_open\" class=\"modal\" [class.modal-full-screen]=\"size == 'full-screen'\">\n <!--fixme: revisit when ngClass works with exit animation-->\n <div\n cdkTrapFocus\n [cdkTrapFocusAutoCapture]=\"true\"\n [@fadeMove]=\"fadeMove\"\n (@fadeMove.done)=\"fadeDone($event)\"\n class=\"modal-dialog\"\n [class.modal-sm]=\"size == 'sm'\"\n [class.modal-lg]=\"size == 'lg'\"\n [class.modal-xl]=\"size == 'xl'\"\n role=\"dialog\"\n aria-modal=\"true\"\n [attr.aria-hidden]=\"!_open\"\n [attr.aria-labelledby]=\"labelledBy || modalId\"\n >\n <div class=\"clr-sr-only\">{{commonStrings.keys.modalContentStart}}</div>\n <div class=\"modal-content-wrapper\">\n <!-- only used in wizards -->\n <ng-content select=\".modal-nav\"></ng-content>\n\n <div class=\"modal-content\">\n <div class=\"modal-header--accessible\">\n <div class=\"modal-title-wrapper\" #title id=\"{{modalId}}\" cdkFocusInitial tabindex=\"-1\">\n <ng-content select=\".modal-title\"></ng-content>\n </div>\n <button\n type=\"button\"\n [attr.aria-label]=\"closeButtonAriaLabel || commonStrings.keys.close\"\n class=\"close\"\n *ngIf=\"closable\"\n (click)=\"close()\"\n >\n <cds-icon shape=\"window-close\"></cds-icon>\n </button>\n </div>\n <div class=\"modal-body-wrapper\">\n <ng-content select=\".modal-body\"></ng-content>\n </div>\n <ng-content select=\".modal-footer\"></ng-content>\n </div>\n </div>\n <div class=\"clr-sr-only\">{{commonStrings.keys.modalContentEnd}}</div>\n </div>\n\n <div [@fade] *ngIf=\"backdrop\" class=\"modal-backdrop\" aria-hidden=\"true\" (click)=\"backdropClick()\"></div>\n</div>\n", styles: [":host{display:none}:host.open{display:inline}\n"], dependencies: [{ kind: "directive", type: i5.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: CdkTrapFocusModule_CdkTrapFocus, selector: "[cdkTrapFocus]" }, { kind: "directive", type: CdsIconCustomTag, selector: "cds-icon" }], viewProviders: [ScrollingService], animations: [
|
|
23687
23751
|
trigger('fadeMove', [
|
|
23688
23752
|
transition('* => fadeDown', [
|
|
23689
23753
|
style({ opacity: 0, transform: 'translate(0, -25%)' }),
|
|
@@ -23718,8 +23782,11 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.2", ngImpor
|
|
|
23718
23782
|
transition('void => *', [style({ opacity: 0 }), animate('0.2s ease-in-out', style({ opacity: 0.85 }))]),
|
|
23719
23783
|
transition('* => void', [animate('0.2s ease-in-out', style({ opacity: 0 }))]),
|
|
23720
23784
|
]),
|
|
23721
|
-
], template: "<!--\n ~ Copyright (c) 2016-2024 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<div *ngIf=\"_open\" class=\"modal\" [class.modal-full-screen]=\"size == 'full-screen'\">\n <!--fixme: revisit when ngClass works with exit animation-->\n <div\n cdkTrapFocus\n [cdkTrapFocusAutoCapture]=\"true\"\n [@fadeMove]=\"fadeMove\"\n (@fadeMove.done)=\"fadeDone($event)\"\n class=\"modal-dialog\"\n [class.modal-sm]=\"size == 'sm'\"\n [class.modal-lg]=\"size == 'lg'\"\n [class.modal-xl]=\"size == 'xl'\"\n role=\"dialog\"\n aria-modal=\"true\"\n [attr.aria-hidden]=\"!_open\"\n [attr.aria-labelledby]=\"labelledBy || modalId\"\n >\n <div class=\"clr-sr-only\">{{commonStrings.keys.modalContentStart}}</div>\n <div class=\"modal-content-wrapper\">\n <!-- only used in wizards -->\n <ng-content select=\".modal-nav\"></ng-content>\n\n <div class=\"modal-content\">\n <div class=\"modal-header--accessible\">\n <div class=\"modal-title-wrapper\" id=\"{{modalId}}\" cdkFocusInitial tabindex=\"-1\">\n <ng-content select=\".modal-title\"></ng-content>\n </div>\n <button\n type=\"button\"\n [attr.aria-label]=\"closeButtonAriaLabel || commonStrings.keys.close\"\n class=\"close\"\n *ngIf=\"closable\"\n (click)=\"close()\"\n >\n <cds-icon shape=\"window-close\"></cds-icon>\n </button>\n </div>\n <div class=\"modal-body-wrapper\">\n <ng-content select=\".modal-body\"></ng-content>\n </div>\n <ng-content select=\".modal-footer\"></ng-content>\n </div>\n </div>\n <div class=\"clr-sr-only\">{{commonStrings.keys.modalContentEnd}}</div>\n </div>\n\n <div [@fade] *ngIf=\"backdrop\" class=\"modal-backdrop\" aria-hidden=\"true\" (click)=\"
|
|
23722
|
-
}], ctorParameters: function () { return [{ type: ScrollingService }, { type: ClrCommonStringsService }, { type: ModalStackService }, { type: ClrModalConfigurationService }]; }, propDecorators: {
|
|
23785
|
+
], template: "<!--\n ~ Copyright (c) 2016-2024 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<div *ngIf=\"_open\" class=\"modal\" [class.modal-full-screen]=\"size == 'full-screen'\">\n <!--fixme: revisit when ngClass works with exit animation-->\n <div\n cdkTrapFocus\n [cdkTrapFocusAutoCapture]=\"true\"\n [@fadeMove]=\"fadeMove\"\n (@fadeMove.done)=\"fadeDone($event)\"\n class=\"modal-dialog\"\n [class.modal-sm]=\"size == 'sm'\"\n [class.modal-lg]=\"size == 'lg'\"\n [class.modal-xl]=\"size == 'xl'\"\n role=\"dialog\"\n aria-modal=\"true\"\n [attr.aria-hidden]=\"!_open\"\n [attr.aria-labelledby]=\"labelledBy || modalId\"\n >\n <div class=\"clr-sr-only\">{{commonStrings.keys.modalContentStart}}</div>\n <div class=\"modal-content-wrapper\">\n <!-- only used in wizards -->\n <ng-content select=\".modal-nav\"></ng-content>\n\n <div class=\"modal-content\">\n <div class=\"modal-header--accessible\">\n <div class=\"modal-title-wrapper\" #title id=\"{{modalId}}\" cdkFocusInitial tabindex=\"-1\">\n <ng-content select=\".modal-title\"></ng-content>\n </div>\n <button\n type=\"button\"\n [attr.aria-label]=\"closeButtonAriaLabel || commonStrings.keys.close\"\n class=\"close\"\n *ngIf=\"closable\"\n (click)=\"close()\"\n >\n <cds-icon shape=\"window-close\"></cds-icon>\n </button>\n </div>\n <div class=\"modal-body-wrapper\">\n <ng-content select=\".modal-body\"></ng-content>\n </div>\n <ng-content select=\".modal-footer\"></ng-content>\n </div>\n </div>\n <div class=\"clr-sr-only\">{{commonStrings.keys.modalContentEnd}}</div>\n </div>\n\n <div [@fade] *ngIf=\"backdrop\" class=\"modal-backdrop\" aria-hidden=\"true\" (click)=\"backdropClick()\"></div>\n</div>\n", styles: [":host{display:none}:host.open{display:inline}\n"] }]
|
|
23786
|
+
}], ctorParameters: function () { return [{ type: ScrollingService }, { type: ClrCommonStringsService }, { type: ModalStackService }, { type: ClrModalConfigurationService }]; }, propDecorators: { title: [{
|
|
23787
|
+
type: ViewChild,
|
|
23788
|
+
args: ['title']
|
|
23789
|
+
}], _open: [{
|
|
23723
23790
|
type: Input,
|
|
23724
23791
|
args: ['clrModalOpen']
|
|
23725
23792
|
}, {
|
|
@@ -23777,11 +23844,11 @@ class ClrModalBody {
|
|
|
23777
23844
|
this.unlisteners = [];
|
|
23778
23845
|
ngZone.runOutsideAngular(() => {
|
|
23779
23846
|
this.observer = new ResizeObserver(() => this.addOrRemoveTabIndex());
|
|
23780
|
-
this.observer.observe(
|
|
23781
|
-
this.unlisteners.push(
|
|
23847
|
+
this.observer.observe(host.nativeElement);
|
|
23848
|
+
this.unlisteners.push(renderer.listen(host.nativeElement, 'mouseup', () => {
|
|
23782
23849
|
// set the tabindex binding back when click is completed with mouseup
|
|
23783
23850
|
this.addOrRemoveTabIndex();
|
|
23784
|
-
}),
|
|
23851
|
+
}), renderer.listen(host.nativeElement, 'mousedown', () => {
|
|
23785
23852
|
// tabindex = 0 binding should be removed
|
|
23786
23853
|
// so it won't be focused when click starts with mousedown
|
|
23787
23854
|
this.removeTabIndex();
|
|
@@ -23834,14 +23901,13 @@ class ClrModalModule {
|
|
|
23834
23901
|
}
|
|
23835
23902
|
ClrModalModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.2", ngImport: i0, type: ClrModalModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
|
|
23836
23903
|
ClrModalModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "15.2.2", ngImport: i0, type: ClrModalModule, declarations: [ClrModal, ClrModalBody], imports: [CommonModule, CdkTrapFocusModule, ClrIconModule], exports: [ClrModal, ClrModalBody, ClrIconModule] });
|
|
23837
|
-
ClrModalModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "15.2.2", ngImport: i0, type: ClrModalModule,
|
|
23904
|
+
ClrModalModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "15.2.2", ngImport: i0, type: ClrModalModule, imports: [CommonModule, CdkTrapFocusModule, ClrIconModule, ClrIconModule] });
|
|
23838
23905
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.2", ngImport: i0, type: ClrModalModule, decorators: [{
|
|
23839
23906
|
type: NgModule,
|
|
23840
23907
|
args: [{
|
|
23841
23908
|
imports: [CommonModule, CdkTrapFocusModule, ClrIconModule],
|
|
23842
23909
|
declarations: [CLR_MODAL_DIRECTIVES],
|
|
23843
23910
|
exports: [CLR_MODAL_DIRECTIVES, ClrIconModule],
|
|
23844
|
-
providers: [ClrModalConfigurationService],
|
|
23845
23911
|
}]
|
|
23846
23912
|
}], ctorParameters: function () { return []; } });
|
|
23847
23913
|
|
|
@@ -23880,7 +23946,9 @@ class ClrSidePanel {
|
|
|
23880
23946
|
this.modal.close();
|
|
23881
23947
|
}
|
|
23882
23948
|
documentClick(event) {
|
|
23883
|
-
if (!this.element.nativeElement.contains(event.target) &&
|
|
23949
|
+
if (!this.element.nativeElement.contains(event.target) &&
|
|
23950
|
+
this.modal._open &&
|
|
23951
|
+
!this.configuration.backdrop) {
|
|
23884
23952
|
this.modal.close();
|
|
23885
23953
|
}
|
|
23886
23954
|
}
|
|
@@ -23997,7 +24065,6 @@ class ClrSignpostContent extends AbstractPopover {
|
|
|
23997
24065
|
constructor(injector, parentHost, commonStrings, signpostIdService, signpostFocusManager, platformId, document) {
|
|
23998
24066
|
super(injector, parentHost);
|
|
23999
24067
|
this.commonStrings = commonStrings;
|
|
24000
|
-
this.signpostIdService = signpostIdService;
|
|
24001
24068
|
this.signpostFocusManager = signpostFocusManager;
|
|
24002
24069
|
this.platformId = platformId;
|
|
24003
24070
|
this.signpostContentId = uniqueIdFactory();
|
|
@@ -24007,7 +24074,7 @@ class ClrSignpostContent extends AbstractPopover {
|
|
|
24007
24074
|
// Defaults
|
|
24008
24075
|
this.position = 'right-middle';
|
|
24009
24076
|
this.closeOnOutsideClick = true;
|
|
24010
|
-
|
|
24077
|
+
signpostIdService.setId(this.signpostContentId);
|
|
24011
24078
|
this.document = document;
|
|
24012
24079
|
}
|
|
24013
24080
|
/*********
|
|
@@ -24396,11 +24463,10 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.2", ngImpor
|
|
|
24396
24463
|
class ClrTooltipTrigger {
|
|
24397
24464
|
constructor(toggleService, tooltipIdService, tooltipMouseService) {
|
|
24398
24465
|
this.toggleService = toggleService;
|
|
24399
|
-
this.tooltipIdService = tooltipIdService;
|
|
24400
24466
|
this.tooltipMouseService = tooltipMouseService;
|
|
24401
24467
|
this.subs = [];
|
|
24402
24468
|
// The aria-described by comes from the id of content. It
|
|
24403
|
-
this.subs.push(
|
|
24469
|
+
this.subs.push(tooltipIdService.id.subscribe(tooltipId => (this.ariaDescribedBy = tooltipId)));
|
|
24404
24470
|
}
|
|
24405
24471
|
ngOnDestroy() {
|
|
24406
24472
|
this.subs.forEach(sub => sub.unsubscribe());
|
|
@@ -25514,7 +25580,7 @@ class WizardNavigationService {
|
|
|
25514
25580
|
* @memberof WizardNavigationService
|
|
25515
25581
|
*/
|
|
25516
25582
|
this._cancelWizard = new Subject();
|
|
25517
|
-
this.previousButtonSubscription =
|
|
25583
|
+
this.previousButtonSubscription = buttonService.previousBtnClicked.subscribe(() => {
|
|
25518
25584
|
const currentPage = this.currentPage;
|
|
25519
25585
|
if (this.currentPageIsFirst || currentPage.previousStepDisabled) {
|
|
25520
25586
|
return;
|
|
@@ -25524,21 +25590,21 @@ class WizardNavigationService {
|
|
|
25524
25590
|
this.previous();
|
|
25525
25591
|
}
|
|
25526
25592
|
});
|
|
25527
|
-
this.nextButtonSubscription =
|
|
25593
|
+
this.nextButtonSubscription = buttonService.nextBtnClicked.subscribe(() => {
|
|
25528
25594
|
this.checkAndCommitCurrentPage('next');
|
|
25529
25595
|
});
|
|
25530
|
-
this.dangerButtonSubscription =
|
|
25596
|
+
this.dangerButtonSubscription = buttonService.dangerBtnClicked.subscribe(() => {
|
|
25531
25597
|
this.checkAndCommitCurrentPage('danger');
|
|
25532
25598
|
});
|
|
25533
|
-
this.finishButtonSubscription =
|
|
25599
|
+
this.finishButtonSubscription = buttonService.finishBtnClicked.subscribe(() => {
|
|
25534
25600
|
this.checkAndCommitCurrentPage('finish');
|
|
25535
25601
|
});
|
|
25536
|
-
this.customButtonSubscription =
|
|
25602
|
+
this.customButtonSubscription = buttonService.customBtnClicked.subscribe((type) => {
|
|
25537
25603
|
if (!this.wizardStopNavigation) {
|
|
25538
25604
|
this.currentPage.customButtonClicked.emit(type);
|
|
25539
25605
|
}
|
|
25540
25606
|
});
|
|
25541
|
-
this.cancelButtonSubscription =
|
|
25607
|
+
this.cancelButtonSubscription = buttonService.cancelBtnClicked.subscribe(() => {
|
|
25542
25608
|
if (this.wizardStopNavigation) {
|
|
25543
25609
|
return;
|
|
25544
25610
|
}
|
|
@@ -25549,7 +25615,7 @@ class WizardNavigationService {
|
|
|
25549
25615
|
this.cancel();
|
|
25550
25616
|
}
|
|
25551
25617
|
});
|
|
25552
|
-
this.pagesResetSubscription =
|
|
25618
|
+
this.pagesResetSubscription = pageCollection.pagesReset.subscribe(() => {
|
|
25553
25619
|
this.setFirstPageCurrent();
|
|
25554
25620
|
});
|
|
25555
25621
|
}
|
|
@@ -26886,15 +26952,12 @@ ClrWizardStepnavItem.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", v
|
|
|
26886
26952
|
(click)="click()"
|
|
26887
26953
|
[attr.disabled]="isDisabled ? '' : null"
|
|
26888
26954
|
>
|
|
26889
|
-
<
|
|
26890
|
-
<cds-icon
|
|
26891
|
-
|
|
26892
|
-
|
|
26893
|
-
|
|
26894
|
-
|
|
26895
|
-
></cds-icon>
|
|
26896
|
-
<ng-content *ngIf="!hasError"></ng-content>
|
|
26897
|
-
</span>
|
|
26955
|
+
<div class="clr-wizard-stepnav-link-icon">
|
|
26956
|
+
<cds-icon *ngIf="hasError" shape="error-standard" aria-label="error"></cds-icon>
|
|
26957
|
+
<cds-icon *ngIf="!hasError && isComplete" shape="success-standard" aria-label="complete"></cds-icon>
|
|
26958
|
+
</div>
|
|
26959
|
+
|
|
26960
|
+
<div class="clr-wizard-stepnav-link-page-number"><ng-content></ng-content></div>
|
|
26898
26961
|
<span class="clr-wizard-stepnav-link-title">
|
|
26899
26962
|
<ng-template [ngTemplateOutlet]="page.navTitle"></ng-template>
|
|
26900
26963
|
</span>
|
|
@@ -26913,15 +26976,12 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.2", ngImpor
|
|
|
26913
26976
|
(click)="click()"
|
|
26914
26977
|
[attr.disabled]="isDisabled ? '' : null"
|
|
26915
26978
|
>
|
|
26916
|
-
<
|
|
26917
|
-
<cds-icon
|
|
26918
|
-
|
|
26919
|
-
|
|
26920
|
-
|
|
26921
|
-
|
|
26922
|
-
></cds-icon>
|
|
26923
|
-
<ng-content *ngIf="!hasError"></ng-content>
|
|
26924
|
-
</span>
|
|
26979
|
+
<div class="clr-wizard-stepnav-link-icon">
|
|
26980
|
+
<cds-icon *ngIf="hasError" shape="error-standard" aria-label="error"></cds-icon>
|
|
26981
|
+
<cds-icon *ngIf="!hasError && isComplete" shape="success-standard" aria-label="complete"></cds-icon>
|
|
26982
|
+
</div>
|
|
26983
|
+
|
|
26984
|
+
<div class="clr-wizard-stepnav-link-page-number"><ng-content></ng-content></div>
|
|
26925
26985
|
<span class="clr-wizard-stepnav-link-title">
|
|
26926
26986
|
<ng-template [ngTemplateOutlet]="page.navTitle"></ng-template>
|
|
26927
26987
|
</span>
|
|
@@ -27391,7 +27451,7 @@ class ClrWizard {
|
|
|
27391
27451
|
}
|
|
27392
27452
|
}
|
|
27393
27453
|
ClrWizard.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.2", ngImport: i0, type: ClrWizard, deps: [{ token: PLATFORM_ID }, { token: ClrCommonStringsService }, { token: WizardNavigationService }, { token: PageCollectionService }, { token: ButtonHubService }, { token: HeaderActionService }, { token: i0.ElementRef }, { token: i0.IterableDiffers }], target: i0.ɵɵFactoryTarget.Component });
|
|
27394
|
-
ClrWizard.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.2", type: ClrWizard, selector: "clr-wizard", inputs: { stepnavAriaLabel: ["clrWizardStepnavAriaLabel", "stepnavAriaLabel"], size: ["clrWizardSize", "size"], closable: ["clrWizardClosable", "closable"], _stopModalAnimations: ["clrWizardPreventModalAnimation", "_stopModalAnimations"], forceForward: ["clrWizardForceForwardNavigation", "forceForward"], clrWizardOpen: "clrWizardOpen", stopNext: ["clrWizardPreventDefaultNext", "stopNext"], stopCancel: ["clrWizardPreventDefaultCancel", "stopCancel"], stopNavigation: ["clrWizardPreventNavigation", "stopNavigation"], disableStepnav: ["clrWizardDisableStepnav", "disableStepnav"] }, outputs: { _openChanged: "clrWizardOpenChange", onCancel: "clrWizardOnCancel", wizardFinished: "clrWizardOnFinish", onReset: "clrWizardOnReset", currentPageChanged: "clrWizardCurrentPageChanged", onMoveNext: "clrWizardOnNext", onMovePrevious: "clrWizardOnPrevious" }, host: { properties: { "class.clr-wizard": "true", "class.wizard-md": "size == 'md'", "class.wizard-lg": "size == 'lg'", "class.wizard-xl": "size == 'xl'", "class.lastPage": "navService.currentPageIsLast" } }, providers: [WizardNavigationService, PageCollectionService, ButtonHubService, HeaderActionService], queries: [{ propertyName: "wizardTitle", first: true, predicate: ClrWizardTitle, descendants: true }, { propertyName: "pages", predicate: ClrWizardPage, descendants: true }, { propertyName: "headerActions", predicate: ClrWizardHeaderAction }], viewQueries: [{ propertyName: "pageTitle", first: true, predicate: ["pageTitle"], descendants: true }], ngImport: i0, template: "<!--\n ~ Copyright (c) 2016-2024 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<clr-modal\n [clrModalOpen]=\"_open\"\n [clrModalSize]=\"size\"\n [clrModalClosable]=\"closable\"\n [clrModalStaticBackdrop]=\"true\"\n [clrModalSkipAnimation]=\"stopModalAnimations\"\n [clrModalOverrideScrollService]=\"isInline\"\n [clrModalPreventClose]=\"true\"\n (clrModalAlternateClose)=\"modalCancel()\"\n [clrModalLabelledById]=\"wizardId\"\n>\n <div class=\"modal-nav clr-wizard-stepnav-wrapper\" role=\"region\" [attr.aria-label]=\"stepnavAriaLabel\">\n <div class=\"clr-wizard-title\" id=\"{{wizardId}}\" role=\"heading\" [attr.aria-level]=\"wizardTitle.headingLevel || 1\">\n <ng-content select=\"clr-wizard-title\"></ng-content>\n </div>\n <clr-wizard-stepnav></clr-wizard-stepnav>\n </div>\n\n <div class=\"modal-title\" role=\"heading\" [attr.aria-level]=\"navService.currentPage
|
|
27454
|
+
ClrWizard.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.2", type: ClrWizard, selector: "clr-wizard", inputs: { stepnavAriaLabel: ["clrWizardStepnavAriaLabel", "stepnavAriaLabel"], size: ["clrWizardSize", "size"], closable: ["clrWizardClosable", "closable"], _stopModalAnimations: ["clrWizardPreventModalAnimation", "_stopModalAnimations"], forceForward: ["clrWizardForceForwardNavigation", "forceForward"], clrWizardOpen: "clrWizardOpen", stopNext: ["clrWizardPreventDefaultNext", "stopNext"], stopCancel: ["clrWizardPreventDefaultCancel", "stopCancel"], stopNavigation: ["clrWizardPreventNavigation", "stopNavigation"], disableStepnav: ["clrWizardDisableStepnav", "disableStepnav"] }, outputs: { _openChanged: "clrWizardOpenChange", onCancel: "clrWizardOnCancel", wizardFinished: "clrWizardOnFinish", onReset: "clrWizardOnReset", currentPageChanged: "clrWizardCurrentPageChanged", onMoveNext: "clrWizardOnNext", onMovePrevious: "clrWizardOnPrevious" }, host: { properties: { "class.clr-wizard": "true", "class.wizard-md": "size == 'md'", "class.wizard-lg": "size == 'lg'", "class.wizard-xl": "size == 'xl'", "class.lastPage": "navService.currentPageIsLast" } }, providers: [WizardNavigationService, PageCollectionService, ButtonHubService, HeaderActionService], queries: [{ propertyName: "wizardTitle", first: true, predicate: ClrWizardTitle, descendants: true }, { propertyName: "pages", predicate: ClrWizardPage, descendants: true }, { propertyName: "headerActions", predicate: ClrWizardHeaderAction }], viewQueries: [{ propertyName: "pageTitle", first: true, predicate: ["pageTitle"], descendants: true }], ngImport: i0, template: "<!--\n ~ Copyright (c) 2016-2024 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<clr-modal\n [clrModalOpen]=\"_open\"\n [clrModalSize]=\"size\"\n [clrModalClosable]=\"closable\"\n [clrModalStaticBackdrop]=\"true\"\n [clrModalSkipAnimation]=\"stopModalAnimations\"\n [clrModalOverrideScrollService]=\"isInline\"\n [clrModalPreventClose]=\"true\"\n (clrModalAlternateClose)=\"modalCancel()\"\n [clrModalLabelledById]=\"wizardId\"\n>\n <div class=\"modal-nav clr-wizard-stepnav-wrapper\" role=\"region\" [attr.aria-label]=\"stepnavAriaLabel\">\n <div class=\"clr-wizard-title\" id=\"{{wizardId}}\" role=\"heading\" [attr.aria-level]=\"wizardTitle.headingLevel || 1\">\n <ng-content select=\"clr-wizard-title\"></ng-content>\n </div>\n <clr-wizard-stepnav></clr-wizard-stepnav>\n </div>\n\n <div class=\"modal-title\" role=\"heading\" [attr.aria-level]=\"navService.currentPage?.pageTitle.headingLevel || 2\">\n <span tabindex=\"-1\" #pageTitle class=\"modal-title-text\">\n <ng-template [ngTemplateOutlet]=\"navService.currentPageTitle\"></ng-template>\n </span>\n\n <div class=\"modal-header-actions-wrapper\" *ngIf=\"headerActionService.displayHeaderActionsWrapper\">\n <div *ngIf=\"headerActionService.showWizardHeaderActions\">\n <ng-content select=\"clr-wizard-header-action\"></ng-content>\n </div>\n <div *ngIf=\"headerActionService.currentPageHasHeaderActions\">\n <ng-template [ngTemplateOutlet]=\"navService.currentPage.headerActions\"></ng-template>\n </div>\n </div>\n </div>\n\n <div class=\"modal-body\">\n <main clr-wizard-pages-wrapper class=\"clr-wizard-content\">\n <ng-content></ng-content>\n </main>\n </div>\n <div class=\"modal-footer clr-wizard-footer\">\n <div class=\"clr-wizard-footer-buttons\">\n <div\n *ngIf=\"navService.currentPage && !navService.currentPage.hasButtons\"\n class=\"clr-wizard-footer-buttons-wrapper\"\n >\n <ng-content select=\"clr-wizard-button\"></ng-content>\n </div>\n <div\n *ngIf=\"navService.currentPage && navService.currentPage.hasButtons\"\n class=\"clr-wizard-footer-buttons-wrapper\"\n >\n <ng-template [ngTemplateOutlet]=\"navService.currentPage.buttons\"></ng-template>\n </div>\n </div>\n </div>\n</clr-modal>\n", dependencies: [{ kind: "directive", type: i5.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i5.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "component", type: ClrModal, selector: "clr-modal", inputs: ["clrModalOpen", "clrModalClosable", "clrModalCloseButtonAriaLabel", "clrModalSize", "clrModalStaticBackdrop", "clrModalSkipAnimation", "clrModalPreventClose", "clrModalLabelledById", "clrModalOverrideScrollService"], outputs: ["clrModalOpenChange", "clrModalAlternateClose"] }, { kind: "directive", type: ClrModalBody, selector: ".modal-body" }, { kind: "component", type: ClrWizardStepnav, selector: "clr-wizard-stepnav" }] });
|
|
27395
27455
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.2", ngImport: i0, type: ClrWizard, decorators: [{
|
|
27396
27456
|
type: Component,
|
|
27397
27457
|
args: [{ selector: 'clr-wizard', providers: [WizardNavigationService, PageCollectionService, ButtonHubService, HeaderActionService], host: {
|
|
@@ -27400,7 +27460,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.2", ngImpor
|
|
|
27400
27460
|
'[class.wizard-lg]': "size == 'lg'",
|
|
27401
27461
|
'[class.wizard-xl]': "size == 'xl'",
|
|
27402
27462
|
'[class.lastPage]': 'navService.currentPageIsLast',
|
|
27403
|
-
}, template: "<!--\n ~ Copyright (c) 2016-2024 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<clr-modal\n [clrModalOpen]=\"_open\"\n [clrModalSize]=\"size\"\n [clrModalClosable]=\"closable\"\n [clrModalStaticBackdrop]=\"true\"\n [clrModalSkipAnimation]=\"stopModalAnimations\"\n [clrModalOverrideScrollService]=\"isInline\"\n [clrModalPreventClose]=\"true\"\n (clrModalAlternateClose)=\"modalCancel()\"\n [clrModalLabelledById]=\"wizardId\"\n>\n <div class=\"modal-nav clr-wizard-stepnav-wrapper\" role=\"region\" [attr.aria-label]=\"stepnavAriaLabel\">\n <div class=\"clr-wizard-title\" id=\"{{wizardId}}\" role=\"heading\" [attr.aria-level]=\"wizardTitle.headingLevel || 1\">\n <ng-content select=\"clr-wizard-title\"></ng-content>\n </div>\n <clr-wizard-stepnav></clr-wizard-stepnav>\n </div>\n\n <div class=\"modal-title\" role=\"heading\" [attr.aria-level]=\"navService.currentPage
|
|
27463
|
+
}, template: "<!--\n ~ Copyright (c) 2016-2024 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<clr-modal\n [clrModalOpen]=\"_open\"\n [clrModalSize]=\"size\"\n [clrModalClosable]=\"closable\"\n [clrModalStaticBackdrop]=\"true\"\n [clrModalSkipAnimation]=\"stopModalAnimations\"\n [clrModalOverrideScrollService]=\"isInline\"\n [clrModalPreventClose]=\"true\"\n (clrModalAlternateClose)=\"modalCancel()\"\n [clrModalLabelledById]=\"wizardId\"\n>\n <div class=\"modal-nav clr-wizard-stepnav-wrapper\" role=\"region\" [attr.aria-label]=\"stepnavAriaLabel\">\n <div class=\"clr-wizard-title\" id=\"{{wizardId}}\" role=\"heading\" [attr.aria-level]=\"wizardTitle.headingLevel || 1\">\n <ng-content select=\"clr-wizard-title\"></ng-content>\n </div>\n <clr-wizard-stepnav></clr-wizard-stepnav>\n </div>\n\n <div class=\"modal-title\" role=\"heading\" [attr.aria-level]=\"navService.currentPage?.pageTitle.headingLevel || 2\">\n <span tabindex=\"-1\" #pageTitle class=\"modal-title-text\">\n <ng-template [ngTemplateOutlet]=\"navService.currentPageTitle\"></ng-template>\n </span>\n\n <div class=\"modal-header-actions-wrapper\" *ngIf=\"headerActionService.displayHeaderActionsWrapper\">\n <div *ngIf=\"headerActionService.showWizardHeaderActions\">\n <ng-content select=\"clr-wizard-header-action\"></ng-content>\n </div>\n <div *ngIf=\"headerActionService.currentPageHasHeaderActions\">\n <ng-template [ngTemplateOutlet]=\"navService.currentPage.headerActions\"></ng-template>\n </div>\n </div>\n </div>\n\n <div class=\"modal-body\">\n <main clr-wizard-pages-wrapper class=\"clr-wizard-content\">\n <ng-content></ng-content>\n </main>\n </div>\n <div class=\"modal-footer clr-wizard-footer\">\n <div class=\"clr-wizard-footer-buttons\">\n <div\n *ngIf=\"navService.currentPage && !navService.currentPage.hasButtons\"\n class=\"clr-wizard-footer-buttons-wrapper\"\n >\n <ng-content select=\"clr-wizard-button\"></ng-content>\n </div>\n <div\n *ngIf=\"navService.currentPage && navService.currentPage.hasButtons\"\n class=\"clr-wizard-footer-buttons-wrapper\"\n >\n <ng-template [ngTemplateOutlet]=\"navService.currentPage.buttons\"></ng-template>\n </div>\n </div>\n </div>\n</clr-modal>\n" }]
|
|
27404
27464
|
}], ctorParameters: function () {
|
|
27405
27465
|
return [{ type: undefined, decorators: [{
|
|
27406
27466
|
type: Inject,
|
|
@@ -27676,7 +27736,7 @@ const CLR_WIZARD_DIRECTIVES = [
|
|
|
27676
27736
|
];
|
|
27677
27737
|
class ClrWizardModule {
|
|
27678
27738
|
constructor() {
|
|
27679
|
-
ClarityIcons.addIcons(errorStandardIcon);
|
|
27739
|
+
ClarityIcons.addIcons(errorStandardIcon, successStandardIcon);
|
|
27680
27740
|
}
|
|
27681
27741
|
}
|
|
27682
27742
|
ClrWizardModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.2", ngImport: i0, type: ClrWizardModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
|
|
@@ -28069,5 +28129,5 @@ const CLR_MENU_POSITIONS = [
|
|
|
28069
28129
|
* Generated bundle index. Do not edit.
|
|
28070
28130
|
*/
|
|
28071
28131
|
|
|
28072
|
-
export { CHANGE_KEYS, CLR_ALERT_DIRECTIVES, CLR_BUTTON_GROUP_DIRECTIVES, CLR_DATAGRID_DIRECTIVES, CLR_DATEPICKER_DIRECTIVES, CLR_DROPDOWN_DIRECTIVES, CLR_ICON_DIRECTIVES, CLR_LAYOUT_DIRECTIVES, CLR_LOADING_BUTTON_DIRECTIVES, CLR_LOADING_DIRECTIVES, CLR_MENU_POSITIONS, CLR_MODAL_DIRECTIVES, CLR_NAVIGATION_DIRECTIVES, CLR_PROGRESS_BAR_DIRECTIVES, CLR_SIDEPANEL_DIRECTIVES, CLR_SIGNPOST_DIRECTIVES, CLR_SPINNER_DIRECTIVES, CLR_STACK_VIEW_DIRECTIVES, CLR_TABS_DIRECTIVES, CLR_TOOLTIP_DIRECTIVES, CLR_TREE_VIEW_DIRECTIVES, CLR_VERTICAL_NAV_DIRECTIVES, CLR_WIZARD_DIRECTIVES, CONDITIONAL_DIRECTIVES, CUSTOM_BUTTON_TYPES, CdsIconCustomTag, ClarityModule, ClrAbstractContainer, ClrAccordion, ClrAccordionContent, ClrAccordionDescription, ClrAccordionModule, ClrAccordionPanel, ClrAccordionTitle, ClrAlert, ClrAlertItem, ClrAlertModule, ClrAlertText, ClrAlerts, ClrAlertsPager, ClrAlignment, ClrAriaCurrentLink, ClrAxis, ClrButton, ClrButtonGroup, ClrButtonGroupModule, ClrButtonModule, ClrCalendar, ClrCheckbox, ClrCheckboxContainer, ClrCheckboxModule, ClrCheckboxWrapper, ClrCombobox, ClrComboboxContainer, ClrComboboxModule, ClrCommonFormsModule, ClrCommonStringsService, ClrConditionalModule, ClrControl, ClrControlContainer, ClrControlError, ClrControlHelper, ClrControlSuccess, ClrDataModule, ClrDatagrid, ClrDatagridActionBar, ClrDatagridActionOverflow, ClrDatagridCell, ClrDatagridColumn, ClrDatagridColumnSeparator, ClrDatagridColumnToggle, ClrDatagridColumnToggleButton, ClrDatagridDetail, ClrDatagridDetailBody, ClrDatagridDetailHeader, ClrDatagridFilter, ClrDatagridFooter, ClrDatagridHideableColumn, ClrDatagridItems, ClrDatagridModule, ClrDatagridPageSize, ClrDatagridPagination, ClrDatagridPlaceholder, ClrDatagridRow, ClrDatagridRowDetail, ClrDatagridSortOrder, ClrDatalist, ClrDatalistContainer, ClrDatalistInput, ClrDatalistModule, ClrDateContainer, ClrDateInput, ClrDateInputValidator, ClrDatepickerModule, ClrDatepickerViewManager, ClrDay, ClrDaypicker, ClrDestroyService, ClrDropdown, ClrDropdownItem, ClrDropdownMenu, ClrDropdownModule, ClrDropdownTrigger, ClrEmphasisModule, ClrExpandableAnimation, ClrFileInput, ClrFileInputContainer, ClrFileInputModule, ClrFileInputValidator, ClrFileInputValueAccessor, ClrFocusOnViewInit, ClrFocusOnViewInitModule, ClrForm, ClrFormLayout, ClrFormsModule, ClrHeader, ClrIconCustomTag, ClrIconModule, ClrIfActive, ClrIfDetail, ClrIfError, ClrIfExpanded, ClrIfOpen, ClrIfSuccess, ClrInput, ClrInputContainer, ClrInputModule, ClrLabel, ClrLayout, ClrLayoutModule, ClrLoading, ClrLoadingButton, ClrLoadingButtonModule, ClrLoadingModule, ClrLoadingState, ClrMainContainer, ClrMainContainerModule, ClrModal, ClrModalBody, ClrModalModule, ClrMonthpicker, ClrNavLevel, ClrNavigationModule, ClrOption, ClrOptionItems, ClrOptionSelected, ClrOptions, ClrPassword, ClrPasswordContainer, ClrPasswordModule, ClrPopoverAnchor, ClrPopoverContent, ClrPopoverEventsService, ClrPopoverHostDirective, ClrPopoverModule, ClrPopoverPositionService, ClrPopoverToggleService, ClrProgressBar, ClrProgressBarModule, ClrRadio, ClrRadioContainer, ClrRadioModule, ClrRadioWrapper, ClrRange, ClrRangeContainer, ClrRangeModule, ClrRecursiveForOf, ClrSelect, ClrSelectContainer, ClrSelectModule, ClrSelectedState, ClrSide, ClrSidePanel, ClrSidePanelModule, ClrSignpost, ClrSignpostContent, ClrSignpostModule, ClrSignpostTrigger, ClrSpinner, ClrSpinnerModule, ClrStackBlock, ClrStackContentInput, ClrStackHeader, ClrStackView, ClrStackViewCustomTags, ClrStackViewLabel, ClrStackViewModule, ClrStandaloneCdkTrapFocus, ClrStepButton, ClrStepButtonType, ClrStepper, ClrStepperModule, ClrStepperPanel, ClrStopEscapePropagationDirective, ClrTab, ClrTabContent, ClrTabLink, ClrTabOverflowContent, ClrTabs, ClrTabsModule, ClrTextarea, ClrTextareaContainer, ClrTextareaModule, ClrTimeline, ClrTimelineLayout, ClrTimelineModule, ClrTimelineStep, ClrTimelineStepDescription, ClrTimelineStepHeader, ClrTimelineStepState, ClrTimelineStepTitle, ClrTooltip, ClrTooltipContent, ClrTooltipModule, ClrTooltipTrigger, ClrTree, ClrTreeNode, ClrTreeNodeLink, ClrTreeViewModule, ClrVerticalNav, ClrVerticalNavGroup, ClrVerticalNavGroupChildren, ClrVerticalNavIcon, ClrVerticalNavLink, ClrVerticalNavModule, ClrWizard, ClrWizardButton, ClrWizardHeaderAction, ClrWizardModule, ClrWizardPage, ClrWizardPageButtons, ClrWizardPageHeaderActions, ClrWizardPageNavTitle, ClrWizardPageTitle, ClrWizardStepnav, ClrWizardStepnavItem, ClrWizardTitle, ClrYearpicker, DEFAULT_BUTTON_TYPES, DatagridNumericFilter, DatagridPropertyComparator, DatagridPropertyNumericFilter, DatagridPropertyStringFilter, DatagridStringFilter, EXPANDABLE_ANIMATION_DIRECTIVES, FOCUS_ON_VIEW_INIT, FOCUS_ON_VIEW_INIT_DIRECTIVES, IS_TOGGLE, IS_TOGGLE_PROVIDER, LoadingListener, MainContainerWillyWonka, NavDetectionOompaLoompa, TOGGLE_SERVICE, TOGGLE_SERVICE_PROVIDER, ToggleServiceFactory, WrappedFormControl, collapse, commonStringsDefault, fade, fadeSlide, isToggleFactory, slide, AccordionOompaLoompa as ÇlrAccordionOompaLoompa, AccordionWillyWonka as ÇlrAccordionWillyWonka, ActionableOompaLoompa as ÇlrActionableOompaLoompa, ActiveOompaLoompa as ÇlrActiveOompaLoompa, ClrPopoverCloseButton as ÇlrClrPopoverCloseButton, ClrPopoverModuleNext as ÇlrClrPopoverModuleNext, ClrPopoverOpenCloseButton as ÇlrClrPopoverOpenCloseButton, DatagridCellRenderer as ÇlrDatagridCellRenderer, DatagridDetailRegisterer as ÇlrDatagridDetailRegisterer, DatagridHeaderRenderer as ÇlrDatagridHeaderRenderer, DatagridMainRenderer as ÇlrDatagridMainRenderer, DatagridRowRenderer as ÇlrDatagridRowRenderer, ClrDatagridSelectionCellDirective as ÇlrDatagridSelectionCellDirective, ClrDatagridVirtualScrollDirective as ÇlrDatagridVirtualScrollDirective, DatagridWillyWonka as ÇlrDatagridWillyWonka, ExpandableOompaLoompa as ÇlrExpandableOompaLoompa, StepperOompaLoompa as ÇlrStepperOompaLoompa, StepperWillyWonka as ÇlrStepperWillyWonka, TabsWillyWonka as ÇlrTabsWillyWonka, WrappedCell as ÇlrWrappedCell, WrappedColumn as ÇlrWrappedColumn, WrappedRow as ÇlrWrappedRow };
|
|
28132
|
+
export { CHANGE_KEYS, CLR_ALERT_DIRECTIVES, CLR_BUTTON_GROUP_DIRECTIVES, CLR_DATAGRID_DIRECTIVES, CLR_DATEPICKER_DIRECTIVES, CLR_DROPDOWN_DIRECTIVES, CLR_ICON_DIRECTIVES, CLR_LAYOUT_DIRECTIVES, CLR_LOADING_BUTTON_DIRECTIVES, CLR_LOADING_DIRECTIVES, CLR_MENU_POSITIONS, CLR_MODAL_DIRECTIVES, CLR_NAVIGATION_DIRECTIVES, CLR_PROGRESS_BAR_DIRECTIVES, CLR_SIDEPANEL_DIRECTIVES, CLR_SIGNPOST_DIRECTIVES, CLR_SPINNER_DIRECTIVES, CLR_STACK_VIEW_DIRECTIVES, CLR_TABS_DIRECTIVES, CLR_TOOLTIP_DIRECTIVES, CLR_TREE_VIEW_DIRECTIVES, CLR_VERTICAL_NAV_DIRECTIVES, CLR_WIZARD_DIRECTIVES, CONDITIONAL_DIRECTIVES, CUSTOM_BUTTON_TYPES, CdsIconCustomTag, ClarityModule, ClrAbstractContainer, ClrAccordion, ClrAccordionContent, ClrAccordionDescription, ClrAccordionModule, ClrAccordionPanel, ClrAccordionTitle, ClrAlert, ClrAlertItem, ClrAlertModule, ClrAlertText, ClrAlerts, ClrAlertsPager, ClrAlignment, ClrAriaCurrentLink, ClrAxis, ClrButton, ClrButtonGroup, ClrButtonGroupModule, ClrButtonModule, ClrCalendar, ClrCheckbox, ClrCheckboxContainer, ClrCheckboxModule, ClrCheckboxWrapper, ClrCombobox, ClrComboboxContainer, ClrComboboxModule, ClrCommonFormsModule, ClrCommonStringsService, ClrConditionalModule, ClrControl, ClrControlContainer, ClrControlError, ClrControlHelper, ClrControlSuccess, ClrDataModule, ClrDatagrid, ClrDatagridActionBar, ClrDatagridActionOverflow, ClrDatagridCell, ClrDatagridColumn, ClrDatagridColumnSeparator, ClrDatagridColumnToggle, ClrDatagridColumnToggleButton, ClrDatagridDetail, ClrDatagridDetailBody, ClrDatagridDetailHeader, ClrDatagridFilter, ClrDatagridFooter, ClrDatagridHideableColumn, ClrDatagridItems, ClrDatagridModule, ClrDatagridPageSize, ClrDatagridPagination, ClrDatagridPlaceholder, ClrDatagridRow, ClrDatagridRowDetail, ClrDatagridSortOrder, ClrDatalist, ClrDatalistContainer, ClrDatalistInput, ClrDatalistModule, ClrDateContainer, ClrDateInput, ClrDateInputValidator, ClrDatepickerModule, ClrDatepickerViewManager, ClrDay, ClrDaypicker, ClrDestroyService, ClrDropdown, ClrDropdownItem, ClrDropdownMenu, ClrDropdownModule, ClrDropdownTrigger, ClrEmphasisModule, ClrExpandableAnimation, ClrFileInput, ClrFileInputContainer, ClrFileInputModule, ClrFileInputValidator, ClrFileInputValueAccessor, ClrFocusOnViewInit, ClrFocusOnViewInitModule, ClrForm, ClrFormLayout, ClrFormsModule, ClrHeader, ClrIconCustomTag, ClrIconModule, ClrIfActive, ClrIfDetail, ClrIfError, ClrIfExpanded, ClrIfOpen, ClrIfSuccess, ClrInput, ClrInputContainer, ClrInputModule, ClrLabel, ClrLayout, ClrLayoutModule, ClrLoading, ClrLoadingButton, ClrLoadingButtonModule, ClrLoadingModule, ClrLoadingState, ClrMainContainer, ClrMainContainerModule, ClrModal, ClrModalBody, ClrModalConfigurationService, ClrModalModule, ClrMonthpicker, ClrNavLevel, ClrNavigationModule, ClrOption, ClrOptionItems, ClrOptionSelected, ClrOptions, ClrPassword, ClrPasswordContainer, ClrPasswordModule, ClrPopoverAnchor, ClrPopoverContent, ClrPopoverEventsService, ClrPopoverHostDirective, ClrPopoverModule, ClrPopoverPositionService, ClrPopoverToggleService, ClrProgressBar, ClrProgressBarModule, ClrRadio, ClrRadioContainer, ClrRadioModule, ClrRadioWrapper, ClrRange, ClrRangeContainer, ClrRangeModule, ClrRecursiveForOf, ClrSelect, ClrSelectContainer, ClrSelectModule, ClrSelectedState, ClrSide, ClrSidePanel, ClrSidePanelModule, ClrSignpost, ClrSignpostContent, ClrSignpostModule, ClrSignpostTrigger, ClrSpinner, ClrSpinnerModule, ClrStackBlock, ClrStackContentInput, ClrStackHeader, ClrStackView, ClrStackViewCustomTags, ClrStackViewLabel, ClrStackViewModule, ClrStandaloneCdkTrapFocus, ClrStepButton, ClrStepButtonType, ClrStepper, ClrStepperModule, ClrStepperPanel, ClrStopEscapePropagationDirective, ClrTab, ClrTabContent, ClrTabLink, ClrTabOverflowContent, ClrTabs, ClrTabsModule, ClrTextarea, ClrTextareaContainer, ClrTextareaModule, ClrTimeline, ClrTimelineLayout, ClrTimelineModule, ClrTimelineStep, ClrTimelineStepDescription, ClrTimelineStepHeader, ClrTimelineStepState, ClrTimelineStepTitle, ClrTooltip, ClrTooltipContent, ClrTooltipModule, ClrTooltipTrigger, ClrTree, ClrTreeNode, ClrTreeNodeLink, ClrTreeViewModule, ClrVerticalNav, ClrVerticalNavGroup, ClrVerticalNavGroupChildren, ClrVerticalNavIcon, ClrVerticalNavLink, ClrVerticalNavModule, ClrWizard, ClrWizardButton, ClrWizardHeaderAction, ClrWizardModule, ClrWizardPage, ClrWizardPageButtons, ClrWizardPageHeaderActions, ClrWizardPageNavTitle, ClrWizardPageTitle, ClrWizardStepnav, ClrWizardStepnavItem, ClrWizardTitle, ClrYearpicker, DEFAULT_BUTTON_TYPES, DatagridNumericFilter, DatagridPropertyComparator, DatagridPropertyNumericFilter, DatagridPropertyStringFilter, DatagridStringFilter, EXPANDABLE_ANIMATION_DIRECTIVES, FOCUS_ON_VIEW_INIT, FOCUS_ON_VIEW_INIT_DIRECTIVES, IS_TOGGLE, IS_TOGGLE_PROVIDER, LoadingListener, MainContainerWillyWonka, NavDetectionOompaLoompa, TOGGLE_SERVICE, TOGGLE_SERVICE_PROVIDER, ToggleServiceFactory, WrappedFormControl, collapse, commonStringsDefault, fade, fadeSlide, isToggleFactory, slide, AccordionOompaLoompa as ÇlrAccordionOompaLoompa, AccordionWillyWonka as ÇlrAccordionWillyWonka, ActionableOompaLoompa as ÇlrActionableOompaLoompa, ActiveOompaLoompa as ÇlrActiveOompaLoompa, ClrPopoverCloseButton as ÇlrClrPopoverCloseButton, ClrPopoverModuleNext as ÇlrClrPopoverModuleNext, ClrPopoverOpenCloseButton as ÇlrClrPopoverOpenCloseButton, DatagridCellRenderer as ÇlrDatagridCellRenderer, DatagridDetailRegisterer as ÇlrDatagridDetailRegisterer, DatagridHeaderRenderer as ÇlrDatagridHeaderRenderer, DatagridMainRenderer as ÇlrDatagridMainRenderer, DatagridRowRenderer as ÇlrDatagridRowRenderer, ClrDatagridSelectionCellDirective as ÇlrDatagridSelectionCellDirective, ClrDatagridVirtualScrollDirective as ÇlrDatagridVirtualScrollDirective, DatagridWillyWonka as ÇlrDatagridWillyWonka, ExpandableOompaLoompa as ÇlrExpandableOompaLoompa, StepperOompaLoompa as ÇlrStepperOompaLoompa, StepperWillyWonka as ÇlrStepperWillyWonka, TabsWillyWonka as ÇlrTabsWillyWonka, WrappedCell as ÇlrWrappedCell, WrappedColumn as ÇlrWrappedColumn, WrappedRow as ÇlrWrappedRow };
|
|
28073
28133
|
//# sourceMappingURL=clr-angular.mjs.map
|