source: trip-planner-front/node_modules/@angular/material/esm2015/stepper/stepper.js@ 6a3a178

Last change on this file since 6a3a178 was 6a3a178, checked in by Ema <ema_spirova@…>, 3 years ago

initial commit

  • Property mode set to 100644
File size: 33.7 KB
Line 
1/**
2 * @license
3 * Copyright Google LLC All Rights Reserved.
4 *
5 * Use of this source code is governed by an MIT-style license that can be
6 * found in the LICENSE file at https://angular.io/license
7 */
8import { Directionality } from '@angular/cdk/bidi';
9import { CdkStep, CdkStepper, STEPPER_GLOBAL_OPTIONS, } from '@angular/cdk/stepper';
10import { ChangeDetectionStrategy, ChangeDetectorRef, Component, ContentChild, ContentChildren, Directive, ElementRef, EventEmitter, forwardRef, Inject, Input, Optional, Output, QueryList, SkipSelf, ViewChildren, ViewContainerRef, ViewEncapsulation, } from '@angular/core';
11import { DOCUMENT } from '@angular/common';
12import { ErrorStateMatcher } from '@angular/material/core';
13import { TemplatePortal } from '@angular/cdk/portal';
14import { Subject, Subscription } from 'rxjs';
15import { takeUntil, distinctUntilChanged, map, startWith, switchMap } from 'rxjs/operators';
16import { MatStepHeader } from './step-header';
17import { MatStepLabel } from './step-label';
18import { matStepperAnimations } from './stepper-animations';
19import { MatStepperIcon } from './stepper-icon';
20import { MatStepContent } from './step-content';
21export class MatStep extends CdkStep {
22 constructor(stepper, _errorStateMatcher, _viewContainerRef, stepperOptions) {
23 super(stepper, stepperOptions);
24 this._errorStateMatcher = _errorStateMatcher;
25 this._viewContainerRef = _viewContainerRef;
26 this._isSelected = Subscription.EMPTY;
27 }
28 ngAfterContentInit() {
29 this._isSelected = this._stepper.steps.changes.pipe(switchMap(() => {
30 return this._stepper.selectionChange.pipe(map(event => event.selectedStep === this), startWith(this._stepper.selected === this));
31 })).subscribe(isSelected => {
32 if (isSelected && this._lazyContent && !this._portal) {
33 this._portal = new TemplatePortal(this._lazyContent._template, this._viewContainerRef);
34 }
35 });
36 }
37 ngOnDestroy() {
38 this._isSelected.unsubscribe();
39 }
40 /** Custom error state matcher that additionally checks for validity of interacted form. */
41 isErrorState(control, form) {
42 const originalErrorState = this._errorStateMatcher.isErrorState(control, form);
43 // Custom error state checks for the validity of form that is not submitted or touched
44 // since user can trigger a form change by calling for another step without directly
45 // interacting with the current form.
46 const customErrorState = !!(control && control.invalid && this.interacted);
47 return originalErrorState || customErrorState;
48 }
49}
50MatStep.decorators = [
51 { type: Component, args: [{
52 selector: 'mat-step',
53 template: "<ng-template>\n <ng-content></ng-content>\n <ng-template [cdkPortalOutlet]=\"_portal\"></ng-template>\n</ng-template>\n",
54 providers: [
55 { provide: ErrorStateMatcher, useExisting: MatStep },
56 { provide: CdkStep, useExisting: MatStep },
57 ],
58 encapsulation: ViewEncapsulation.None,
59 exportAs: 'matStep',
60 changeDetection: ChangeDetectionStrategy.OnPush
61 },] }
62];
63MatStep.ctorParameters = () => [
64 { type: MatStepper, decorators: [{ type: Inject, args: [forwardRef(() => MatStepper),] }] },
65 { type: ErrorStateMatcher, decorators: [{ type: SkipSelf }] },
66 { type: ViewContainerRef },
67 { type: undefined, decorators: [{ type: Optional }, { type: Inject, args: [STEPPER_GLOBAL_OPTIONS,] }] }
68];
69MatStep.propDecorators = {
70 stepLabel: [{ type: ContentChild, args: [MatStepLabel,] }],
71 color: [{ type: Input }],
72 _lazyContent: [{ type: ContentChild, args: [MatStepContent, { static: false },] }]
73};
74/**
75 * Proxies the public APIs from `MatStepper` to the deprecated `MatHorizontalStepper` and
76 * `MatVerticalStepper`.
77 * @deprecated Use `MatStepper` instead.
78 * @breaking-change 13.0.0
79 * @docs-private
80 */
81class _MatProxyStepperBase extends CdkStepper {
82}
83_MatProxyStepperBase.decorators = [
84 { type: Directive }
85];
86/**
87 * @deprecated Use `MatStepper` instead.
88 * @breaking-change 13.0.0
89 */
90export class MatHorizontalStepper extends _MatProxyStepperBase {
91}
92MatHorizontalStepper.decorators = [
93 { type: Directive, args: [{ selector: 'mat-horizontal-stepper' },] }
94];
95/**
96 * @deprecated Use `MatStepper` instead.
97 * @breaking-change 13.0.0
98 */
99export class MatVerticalStepper extends _MatProxyStepperBase {
100}
101MatVerticalStepper.decorators = [
102 { type: Directive, args: [{ selector: 'mat-vertical-stepper' },] }
103];
104export class MatStepper extends CdkStepper {
105 constructor(dir, changeDetectorRef, elementRef, _document) {
106 super(dir, changeDetectorRef, elementRef, _document);
107 /** Steps that belong to the current stepper, excluding ones from nested steppers. */
108 this.steps = new QueryList();
109 /** Event emitted when the current step is done transitioning in. */
110 this.animationDone = new EventEmitter();
111 /**
112 * Whether the label should display in bottom or end position.
113 * Only applies in the `horizontal` orientation.
114 */
115 this.labelPosition = 'end';
116 /** Consumer-specified template-refs to be used to override the header icons. */
117 this._iconOverrides = {};
118 /** Stream of animation `done` events when the body expands/collapses. */
119 this._animationDone = new Subject();
120 const nodeName = elementRef.nativeElement.nodeName.toLowerCase();
121 this.orientation = nodeName === 'mat-vertical-stepper' ? 'vertical' : 'horizontal';
122 }
123 ngAfterContentInit() {
124 super.ngAfterContentInit();
125 this._icons.forEach(({ name, templateRef }) => this._iconOverrides[name] = templateRef);
126 // Mark the component for change detection whenever the content children query changes
127 this.steps.changes.pipe(takeUntil(this._destroyed)).subscribe(() => {
128 this._stateChanged();
129 });
130 this._animationDone.pipe(
131 // This needs a `distinctUntilChanged` in order to avoid emitting the same event twice due
132 // to a bug in animations where the `.done` callback gets invoked twice on some browsers.
133 // See https://github.com/angular/angular/issues/24084
134 distinctUntilChanged((x, y) => x.fromState === y.fromState && x.toState === y.toState), takeUntil(this._destroyed)).subscribe(event => {
135 if (event.toState === 'current') {
136 this.animationDone.emit();
137 }
138 });
139 }
140 _stepIsNavigable(index, step) {
141 return step.completed || this.selectedIndex === index || !this.linear;
142 }
143}
144MatStepper.decorators = [
145 { type: Component, args: [{
146 selector: 'mat-stepper, mat-vertical-stepper, mat-horizontal-stepper, [matStepper]',
147 exportAs: 'matStepper, matVerticalStepper, matHorizontalStepper',
148 template: "<ng-container [ngSwitch]=\"orientation\">\n <!-- Horizontal stepper -->\n <ng-container *ngSwitchCase=\"'horizontal'\">\n <div class=\"mat-horizontal-stepper-header-container\">\n <ng-container *ngFor=\"let step of steps; let i = index; let isLast = last\">\n <ng-container\n [ngTemplateOutlet]=\"stepTemplate\"\n [ngTemplateOutletContext]=\"{step: step, i: i}\"></ng-container>\n <div *ngIf=\"!isLast\" class=\"mat-stepper-horizontal-line\"></div>\n </ng-container>\n </div>\n\n <div class=\"mat-horizontal-content-container\">\n <div *ngFor=\"let step of steps; let i = index\"\n class=\"mat-horizontal-stepper-content\" role=\"tabpanel\"\n [@horizontalStepTransition]=\"_getAnimationDirection(i)\"\n (@horizontalStepTransition.done)=\"_animationDone.next($event)\"\n [id]=\"_getStepContentId(i)\"\n [attr.aria-labelledby]=\"_getStepLabelId(i)\"\n [attr.aria-expanded]=\"selectedIndex === i\">\n <ng-container [ngTemplateOutlet]=\"step.content\"></ng-container>\n </div>\n </div>\n </ng-container>\n\n <!-- Vertical stepper -->\n <ng-container *ngSwitchCase=\"'vertical'\">\n <div class=\"mat-step\" *ngFor=\"let step of steps; let i = index; let isLast = last\">\n <ng-container\n [ngTemplateOutlet]=\"stepTemplate\"\n [ngTemplateOutletContext]=\"{step: step, i: i}\"></ng-container>\n <div class=\"mat-vertical-content-container\" [class.mat-stepper-vertical-line]=\"!isLast\">\n <div class=\"mat-vertical-stepper-content\" role=\"tabpanel\"\n [@verticalStepTransition]=\"_getAnimationDirection(i)\"\n (@verticalStepTransition.done)=\"_animationDone.next($event)\"\n [id]=\"_getStepContentId(i)\"\n [attr.aria-labelledby]=\"_getStepLabelId(i)\"\n [attr.aria-expanded]=\"selectedIndex === i\">\n <div class=\"mat-vertical-content\">\n <ng-container [ngTemplateOutlet]=\"step.content\"></ng-container>\n </div>\n </div>\n </div>\n </div>\n </ng-container>\n\n</ng-container>\n\n<!-- Common step templating -->\n<ng-template let-step=\"step\" let-i=\"i\" #stepTemplate>\n <mat-step-header\n [class.mat-horizontal-stepper-header]=\"orientation === 'horizontal'\"\n [class.mat-vertical-stepper-header]=\"orientation === 'vertical'\"\n (click)=\"step.select()\"\n (keydown)=\"_onKeydown($event)\"\n [tabIndex]=\"_getFocusIndex() === i ? 0 : -1\"\n [id]=\"_getStepLabelId(i)\"\n [attr.aria-posinset]=\"i + 1\"\n [attr.aria-setsize]=\"steps.length\"\n [attr.aria-controls]=\"_getStepContentId(i)\"\n [attr.aria-selected]=\"selectedIndex == i\"\n [attr.aria-label]=\"step.ariaLabel || null\"\n [attr.aria-labelledby]=\"(!step.ariaLabel && step.ariaLabelledby) ? step.ariaLabelledby : null\"\n [attr.aria-disabled]=\"_stepIsNavigable(i, step) ? null : true\"\n [index]=\"i\"\n [state]=\"_getIndicatorType(i, step.state)\"\n [label]=\"step.stepLabel || step.label\"\n [selected]=\"selectedIndex === i\"\n [active]=\"_stepIsNavigable(i, step)\"\n [optional]=\"step.optional\"\n [errorMessage]=\"step.errorMessage\"\n [iconOverrides]=\"_iconOverrides\"\n [disableRipple]=\"disableRipple || !_stepIsNavigable(i, step)\"\n [color]=\"step.color || color\"></mat-step-header>\n</ng-template>\n",
149 inputs: ['selectedIndex'],
150 host: {
151 '[class.mat-stepper-horizontal]': 'orientation === "horizontal"',
152 '[class.mat-stepper-vertical]': 'orientation === "vertical"',
153 '[class.mat-stepper-label-position-end]': 'orientation === "horizontal" && labelPosition == "end"',
154 '[class.mat-stepper-label-position-bottom]': 'orientation === "horizontal" && labelPosition == "bottom"',
155 '[attr.aria-orientation]': 'orientation',
156 'role': 'tablist',
157 },
158 animations: [
159 matStepperAnimations.horizontalStepTransition,
160 matStepperAnimations.verticalStepTransition,
161 ],
162 providers: [
163 { provide: CdkStepper, useExisting: MatStepper },
164 { provide: MatHorizontalStepper, useExisting: MatStepper },
165 { provide: MatVerticalStepper, useExisting: MatStepper },
166 ],
167 encapsulation: ViewEncapsulation.None,
168 changeDetection: ChangeDetectionStrategy.OnPush,
169 styles: [".mat-stepper-vertical,.mat-stepper-horizontal{display:block}.mat-horizontal-stepper-header-container{white-space:nowrap;display:flex;align-items:center}.mat-stepper-label-position-bottom .mat-horizontal-stepper-header-container{align-items:flex-start}.mat-stepper-horizontal-line{border-top-width:1px;border-top-style:solid;flex:auto;height:0;margin:0 -16px;min-width:32px}.mat-stepper-label-position-bottom .mat-stepper-horizontal-line{margin:0;min-width:0;position:relative}.mat-stepper-label-position-bottom .mat-horizontal-stepper-header:not(:first-child)::before,[dir=rtl] .mat-stepper-label-position-bottom .mat-horizontal-stepper-header:not(:last-child)::before,.mat-stepper-label-position-bottom .mat-horizontal-stepper-header:not(:last-child)::after,[dir=rtl] .mat-stepper-label-position-bottom .mat-horizontal-stepper-header:not(:first-child)::after{border-top-width:1px;border-top-style:solid;content:\"\";display:inline-block;height:0;position:absolute;width:calc(50% - 20px)}.mat-horizontal-stepper-header{display:flex;height:72px;overflow:hidden;align-items:center;padding:0 24px}.mat-horizontal-stepper-header .mat-step-icon{margin-right:8px;flex:none}[dir=rtl] .mat-horizontal-stepper-header .mat-step-icon{margin-right:0;margin-left:8px}.mat-stepper-label-position-bottom .mat-horizontal-stepper-header{box-sizing:border-box;flex-direction:column;height:auto}.mat-stepper-label-position-bottom .mat-horizontal-stepper-header:not(:last-child)::after,[dir=rtl] .mat-stepper-label-position-bottom .mat-horizontal-stepper-header:not(:first-child)::after{right:0}.mat-stepper-label-position-bottom .mat-horizontal-stepper-header:not(:first-child)::before,[dir=rtl] .mat-stepper-label-position-bottom .mat-horizontal-stepper-header:not(:last-child)::before{left:0}[dir=rtl] .mat-stepper-label-position-bottom .mat-horizontal-stepper-header:last-child::before,[dir=rtl] .mat-stepper-label-position-bottom .mat-horizontal-stepper-header:first-child::after{display:none}.mat-stepper-label-position-bottom .mat-horizontal-stepper-header .mat-step-icon{margin-right:0;margin-left:0}.mat-stepper-label-position-bottom .mat-horizontal-stepper-header .mat-step-label{padding:16px 0 0 0;text-align:center;width:100%}.mat-vertical-stepper-header{display:flex;align-items:center;height:24px}.mat-vertical-stepper-header .mat-step-icon{margin-right:12px}[dir=rtl] .mat-vertical-stepper-header .mat-step-icon{margin-right:0;margin-left:12px}.mat-horizontal-stepper-content{outline:0}.mat-horizontal-stepper-content[aria-expanded=false]{height:0;overflow:hidden}.mat-horizontal-content-container{overflow:hidden;padding:0 24px 24px 24px}.cdk-high-contrast-active .mat-horizontal-content-container{outline:solid 1px}.mat-vertical-content-container{margin-left:36px;border:0;position:relative}.cdk-high-contrast-active .mat-vertical-content-container{outline:solid 1px}[dir=rtl] .mat-vertical-content-container{margin-left:0;margin-right:36px}.mat-stepper-vertical-line::before{content:\"\";position:absolute;left:0;border-left-width:1px;border-left-style:solid}[dir=rtl] .mat-stepper-vertical-line::before{left:auto;right:0}.mat-vertical-stepper-content{overflow:hidden;outline:0}.mat-vertical-content{padding:0 24px 24px 24px}.mat-step:last-child .mat-vertical-content-container{border:none}\n"]
170 },] }
171];
172MatStepper.ctorParameters = () => [
173 { type: Directionality, decorators: [{ type: Optional }] },
174 { type: ChangeDetectorRef },
175 { type: ElementRef },
176 { type: undefined, decorators: [{ type: Inject, args: [DOCUMENT,] }] }
177];
178MatStepper.propDecorators = {
179 _stepHeader: [{ type: ViewChildren, args: [MatStepHeader,] }],
180 _steps: [{ type: ContentChildren, args: [MatStep, { descendants: true },] }],
181 _icons: [{ type: ContentChildren, args: [MatStepperIcon, { descendants: true },] }],
182 animationDone: [{ type: Output }],
183 disableRipple: [{ type: Input }],
184 color: [{ type: Input }],
185 labelPosition: [{ type: Input }]
186};
187//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoic3RlcHBlci5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uLy4uLy4uLy4uLy4uLy4uL3NyYy9tYXRlcmlhbC9zdGVwcGVyL3N0ZXBwZXIudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IkFBQUE7Ozs7OztHQU1HO0FBRUgsT0FBTyxFQUFDLGNBQWMsRUFBQyxNQUFNLG1CQUFtQixDQUFDO0F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tZSBicm93c2Vycy5cbiAgICAgIC8vIFNlZSBodHRwczovL2dpdGh1Yi5jb20vYW5ndWxhci9hbmd1bGFyL2lzc3Vlcy8yNDA4NFxuICAgICAgZGlzdGluY3RVbnRpbENoYW5nZWQoKHgsIHkpID0+IHguZnJvbVN0YXRlID09PSB5LmZyb21TdGF0ZSAmJiB4LnRvU3RhdGUgPT09IHkudG9TdGF0ZSksXG4gICAgICB0YWtlVW50aWwodGhpcy5fZGVzdHJveWVkKVxuICAgICkuc3Vic2NyaWJlKGV2ZW50ID0+IHtcbiAgICAgIGlmICgoZXZlbnQudG9TdGF0ZSBhcyBTdGVwQ29udGVudFBvc2l0aW9uU3RhdGUpID09PSAnY3VycmVudCcpIHtcbiAgICAgICAgdGhpcy5hbmltYXRpb25Eb25lLmVtaXQoKTtcbiAgICAgIH1cbiAgICB9KTtcbiAgfVxuXG4gIF9zdGVwSXNOYXZpZ2FibGUoaW5kZXg6IG51bWJlciwgc3RlcDogTWF0U3RlcCk6IGJvb2xlYW4ge1xuICAgIHJldHVybiBzdGVwLmNvbXBsZXRlZCB8fCB0aGlzLnNlbGVjdGVkSW5kZXggPT09IGluZGV4IHx8ICF0aGlzLmxpbmVhcjtcbiAgfVxufVxuIl19
Note: See TracBrowser for help on using the repository browser.