UNPKG

25.9 kBJavaScriptView Raw
1import { coerceNumberProperty } from '@angular/cdk/coercion';
2import * as i1 from '@angular/cdk/platform';
3import { _getShadowRoot } from '@angular/cdk/platform';
4import * as i2 from '@angular/cdk/scrolling';
5import * as i3 from '@angular/common';
6import { DOCUMENT, CommonModule } from '@angular/common';
7import * as i0 from '@angular/core';
8import { Component, ChangeDetectionStrategy, ViewEncapsulation, Optional, Inject, Input, NgModule } from '@angular/core';
9import { mixinColor, MatCommonModule } from '@angular/material/core';
10import { ANIMATION_MODULE_TYPE } from '@angular/platform-browser/animations';
11import { MAT_PROGRESS_SPINNER_DEFAULT_OPTIONS } from '@angular/material/progress-spinner';
12export { MAT_PROGRESS_SPINNER_DEFAULT_OPTIONS as MAT_LEGACY_PROGRESS_SPINNER_DEFAULT_OPTIONS, MAT_PROGRESS_SPINNER_DEFAULT_OPTIONS_FACTORY as MAT_LEGACY_PROGRESS_SPINNER_DEFAULT_OPTIONS_FACTORY } from '@angular/material/progress-spinner';
13import { Subscription } from 'rxjs';
14
15/**
16 * @license
17 * Copyright Google LLC All Rights Reserved.
18 *
19 * Use of this source code is governed by an MIT-style license that can be
20 * found in the LICENSE file at https://angular.io/license
21 */
22/**
23 * Base reference size of the spinner.
24 * @docs-private
25 */
26const BASE_SIZE = 100;
27/**
28 * Base reference stroke width of the spinner.
29 * @docs-private
30 */
31const BASE_STROKE_WIDTH = 10;
32// Boilerplate for applying mixins to MatLegacyProgressSpinner.
33/** @docs-private */
34const _MatProgressSpinnerBase = mixinColor(class {
35 constructor(_elementRef) {
36 this._elementRef = _elementRef;
37 }
38}, 'primary');
39// .0001 percentage difference is necessary in order to avoid unwanted animation frames
40// for example because the animation duration is 4 seconds, .1% accounts to 4ms
41// which are enough to see the flicker described in
42// https://github.com/angular/components/issues/8984
43const INDETERMINATE_ANIMATION_TEMPLATE = `
44 @keyframes mat-progress-spinner-stroke-rotate-DIAMETER {
45 0% { stroke-dashoffset: START_VALUE; transform: rotate(0); }
46 12.5% { stroke-dashoffset: END_VALUE; transform: rotate(0); }
47 12.5001% { stroke-dashoffset: END_VALUE; transform: rotateX(180deg) rotate(72.5deg); }
48 25% { stroke-dashoffset: START_VALUE; transform: rotateX(180deg) rotate(72.5deg); }
49
50 25.0001% { stroke-dashoffset: START_VALUE; transform: rotate(270deg); }
51 37.5% { stroke-dashoffset: END_VALUE; transform: rotate(270deg); }
52 37.5001% { stroke-dashoffset: END_VALUE; transform: rotateX(180deg) rotate(161.5deg); }
53 50% { stroke-dashoffset: START_VALUE; transform: rotateX(180deg) rotate(161.5deg); }
54
55 50.0001% { stroke-dashoffset: START_VALUE; transform: rotate(180deg); }
56 62.5% { stroke-dashoffset: END_VALUE; transform: rotate(180deg); }
57 62.5001% { stroke-dashoffset: END_VALUE; transform: rotateX(180deg) rotate(251.5deg); }
58 75% { stroke-dashoffset: START_VALUE; transform: rotateX(180deg) rotate(251.5deg); }
59
60 75.0001% { stroke-dashoffset: START_VALUE; transform: rotate(90deg); }
61 87.5% { stroke-dashoffset: END_VALUE; transform: rotate(90deg); }
62 87.5001% { stroke-dashoffset: END_VALUE; transform: rotateX(180deg) rotate(341.5deg); }
63 100% { stroke-dashoffset: START_VALUE; transform: rotateX(180deg) rotate(341.5deg); }
64 }
65`;
66/**
67 * `<mat-progress-spinner>` component.
68 * @deprecated Use `MatProgressSpinner` from `@angular/material/progress-spinner` instead. See https://material.angular.io/guide/mdc-migration for information about migrating.
69 * @breaking-change 17.0.0
70 */
71class MatLegacyProgressSpinner extends _MatProgressSpinnerBase {
72 /** The diameter of the progress spinner (will set width and height of svg). */
73 get diameter() {
74 return this._diameter;
75 }
76 set diameter(size) {
77 this._diameter = coerceNumberProperty(size);
78 this._spinnerAnimationLabel = this._getSpinnerAnimationLabel();
79 // If this is set before `ngOnInit`, the style root may not have been resolved yet.
80 if (this._styleRoot) {
81 this._attachStyleNode();
82 }
83 }
84 /** Stroke width of the progress spinner. */
85 get strokeWidth() {
86 return this._strokeWidth || this.diameter / 10;
87 }
88 set strokeWidth(value) {
89 this._strokeWidth = coerceNumberProperty(value);
90 }
91 /** Value of the progress circle. */
92 get value() {
93 return this.mode === 'determinate' ? this._value : 0;
94 }
95 set value(newValue) {
96 this._value = Math.max(0, Math.min(100, coerceNumberProperty(newValue)));
97 }
98 constructor(elementRef, _platform, _document, animationMode, defaults,
99 /**
100 * @deprecated `changeDetectorRef`, `viewportRuler` and `ngZone`
101 * parameters to become required.
102 * @breaking-change 14.0.0
103 */
104 changeDetectorRef, viewportRuler, ngZone) {
105 super(elementRef);
106 this._document = _document;
107 this._diameter = BASE_SIZE;
108 this._value = 0;
109 this._resizeSubscription = Subscription.EMPTY;
110 /** Mode of the progress circle */
111 this.mode = 'determinate';
112 const trackedDiameters = MatLegacyProgressSpinner._diameters;
113 this._spinnerAnimationLabel = this._getSpinnerAnimationLabel();
114 // The base size is already inserted via the component's structural styles. We still
115 // need to track it so we don't end up adding the same styles again.
116 if (!trackedDiameters.has(_document.head)) {
117 trackedDiameters.set(_document.head, new Set([BASE_SIZE]));
118 }
119 this._noopAnimations =
120 animationMode === 'NoopAnimations' && !!defaults && !defaults._forceAnimations;
121 if (elementRef.nativeElement.nodeName.toLowerCase() === 'mat-spinner') {
122 this.mode = 'indeterminate';
123 }
124 if (defaults) {
125 if (defaults.color) {
126 this.color = this.defaultColor = defaults.color;
127 }
128 if (defaults.diameter) {
129 this.diameter = defaults.diameter;
130 }
131 if (defaults.strokeWidth) {
132 this.strokeWidth = defaults.strokeWidth;
133 }
134 }
135 // Safari has an issue where the circle isn't positioned correctly when the page has a
136 // different zoom level from the default. This handler triggers a recalculation of the
137 // `transform-origin` when the page zoom level changes.
138 // See `_getCircleTransformOrigin` for more info.
139 // @breaking-change 14.0.0 Remove null checks for `_changeDetectorRef`,
140 // `viewportRuler` and `ngZone`.
141 if (_platform.isBrowser && _platform.SAFARI && viewportRuler && changeDetectorRef && ngZone) {
142 this._resizeSubscription = viewportRuler.change(150).subscribe(() => {
143 // When the window is resize while the spinner is in `indeterminate` mode, we
144 // have to mark for check so the transform origin of the circle can be recomputed.
145 if (this.mode === 'indeterminate') {
146 ngZone.run(() => changeDetectorRef.markForCheck());
147 }
148 });
149 }
150 }
151 ngOnInit() {
152 const element = this._elementRef.nativeElement;
153 // Note that we need to look up the root node in ngOnInit, rather than the constructor, because
154 // Angular seems to create the element outside the shadow root and then moves it inside, if the
155 // node is inside an `ngIf` and a ShadowDom-encapsulated component.
156 this._styleRoot = _getShadowRoot(element) || this._document.head;
157 this._attachStyleNode();
158 element.classList.add('mat-progress-spinner-indeterminate-animation');
159 }
160 ngOnDestroy() {
161 this._resizeSubscription.unsubscribe();
162 }
163 /** The radius of the spinner, adjusted for stroke width. */
164 _getCircleRadius() {
165 return (this.diameter - BASE_STROKE_WIDTH) / 2;
166 }
167 /** The view box of the spinner's svg element. */
168 _getViewBox() {
169 const viewBox = this._getCircleRadius() * 2 + this.strokeWidth;
170 return `0 0 ${viewBox} ${viewBox}`;
171 }
172 /** The stroke circumference of the svg circle. */
173 _getStrokeCircumference() {
174 return 2 * Math.PI * this._getCircleRadius();
175 }
176 /** The dash offset of the svg circle. */
177 _getStrokeDashOffset() {
178 if (this.mode === 'determinate') {
179 return (this._getStrokeCircumference() * (100 - this._value)) / 100;
180 }
181 return null;
182 }
183 /** Stroke width of the circle in percent. */
184 _getCircleStrokeWidth() {
185 return (this.strokeWidth / this.diameter) * 100;
186 }
187 /** Gets the `transform-origin` for the inner circle element. */
188 _getCircleTransformOrigin(svg) {
189 // Safari has an issue where the `transform-origin` doesn't work as expected when the page
190 // has a different zoom level from the default. The problem appears to be that a zoom
191 // is applied on the `svg` node itself. We can work around it by calculating the origin
192 // based on the zoom level. On all other browsers the `currentScale` appears to always be 1.
193 const scale = (svg.currentScale ?? 1) * 50;
194 return `${scale}% ${scale}%`;
195 }
196 /** Dynamically generates a style tag containing the correct animation for this diameter. */
197 _attachStyleNode() {
198 const styleRoot = this._styleRoot;
199 const currentDiameter = this._diameter;
200 const diameters = MatLegacyProgressSpinner._diameters;
201 let diametersForElement = diameters.get(styleRoot);
202 if (!diametersForElement || !diametersForElement.has(currentDiameter)) {
203 const styleTag = this._document.createElement('style');
204 styleTag.setAttribute('mat-spinner-animation', this._spinnerAnimationLabel);
205 styleTag.textContent = this._getAnimationText();
206 styleRoot.appendChild(styleTag);
207 if (!diametersForElement) {
208 diametersForElement = new Set();
209 diameters.set(styleRoot, diametersForElement);
210 }
211 diametersForElement.add(currentDiameter);
212 }
213 }
214 /** Generates animation styles adjusted for the spinner's diameter. */
215 _getAnimationText() {
216 const strokeCircumference = this._getStrokeCircumference();
217 return (INDETERMINATE_ANIMATION_TEMPLATE
218 // Animation should begin at 5% and end at 80%
219 .replace(/START_VALUE/g, `${0.95 * strokeCircumference}`)
220 .replace(/END_VALUE/g, `${0.2 * strokeCircumference}`)
221 .replace(/DIAMETER/g, `${this._spinnerAnimationLabel}`));
222 }
223 /** Returns the circle diameter formatted for use with the animation-name CSS property. */
224 _getSpinnerAnimationLabel() {
225 // The string of a float point number will include a period ‘.’ character,
226 // which is not valid for a CSS animation-name.
227 return this.diameter.toString().replace('.', '_');
228 }
229}
230/**
231 * Tracks diameters of existing instances to de-dupe generated styles (default d = 100).
232 * We need to keep track of which elements the diameters were attached to, because for
233 * elements in the Shadow DOM the style tags are attached to the shadow root, rather
234 * than the document head.
235 */
236MatLegacyProgressSpinner._diameters = new WeakMap();
237MatLegacyProgressSpinner.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.0-rc.0", ngImport: i0, type: MatLegacyProgressSpinner, deps: [{ token: i0.ElementRef }, { token: i1.Platform }, { token: DOCUMENT, optional: true }, { token: ANIMATION_MODULE_TYPE, optional: true }, { token: MAT_PROGRESS_SPINNER_DEFAULT_OPTIONS }, { token: i0.ChangeDetectorRef }, { token: i2.ViewportRuler }, { token: i0.NgZone }], target: i0.ɵɵFactoryTarget.Component });
238MatLegacyProgressSpinner.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.0-rc.0", type: MatLegacyProgressSpinner, selector: "mat-progress-spinner, mat-spinner", inputs: { color: "color", diameter: "diameter", strokeWidth: "strokeWidth", mode: "mode", value: "value" }, host: { attributes: { "role": "progressbar", "tabindex": "-1" }, properties: { "class._mat-animation-noopable": "_noopAnimations", "style.width.px": "diameter", "style.height.px": "diameter", "attr.aria-valuemin": "mode === \"determinate\" ? 0 : null", "attr.aria-valuemax": "mode === \"determinate\" ? 100 : null", "attr.aria-valuenow": "mode === \"determinate\" ? value : null", "attr.mode": "mode" }, classAttribute: "mat-progress-spinner mat-spinner" }, exportAs: ["matProgressSpinner"], usesInheritance: true, ngImport: i0, template: "<!--\n preserveAspectRatio of xMidYMid meet as the center of the viewport is the circle's\n center. The center of the circle will remain at the center of the mat-progress-spinner\n element containing the SVG.\n-->\n<!--\n All children need to be hidden for screen readers in order to support ChromeVox.\n More context in the issue: https://github.com/angular/components/issues/22165.\n-->\n<svg\n [style.width.px]=\"diameter\"\n [style.height.px]=\"diameter\"\n [attr.viewBox]=\"_getViewBox()\"\n preserveAspectRatio=\"xMidYMid meet\"\n focusable=\"false\"\n [ngSwitch]=\"mode === 'indeterminate'\"\n aria-hidden=\"true\"\n #svg>\n\n <!--\n Technically we can reuse the same `circle` element, however Safari has an issue that breaks\n the SVG rendering in determinate mode, after switching between indeterminate and determinate.\n Using a different element avoids the issue. An alternative to this is adding `display: none`\n for a split second and then removing it when switching between modes, but it's hard to know\n for how long to hide the element and it can cause the UI to blink.\n -->\n <circle\n *ngSwitchCase=\"true\"\n cx=\"50%\"\n cy=\"50%\"\n [attr.r]=\"_getCircleRadius()\"\n [style.animation-name]=\"'mat-progress-spinner-stroke-rotate-' + _spinnerAnimationLabel\"\n [style.stroke-dashoffset.px]=\"_getStrokeDashOffset()\"\n [style.stroke-dasharray.px]=\"_getStrokeCircumference()\"\n [style.stroke-width.%]=\"_getCircleStrokeWidth()\"\n [style.transform-origin]=\"_getCircleTransformOrigin(svg)\"></circle>\n\n <circle\n *ngSwitchCase=\"false\"\n cx=\"50%\"\n cy=\"50%\"\n [attr.r]=\"_getCircleRadius()\"\n [style.stroke-dashoffset.px]=\"_getStrokeDashOffset()\"\n [style.stroke-dasharray.px]=\"_getStrokeCircumference()\"\n [style.stroke-width.%]=\"_getCircleStrokeWidth()\"\n [style.transform-origin]=\"_getCircleTransformOrigin(svg)\"></circle>\n</svg>\n", styles: [".mat-progress-spinner{display:block;position:relative;overflow:hidden}.mat-progress-spinner svg{position:absolute;transform:rotate(-90deg);top:0;left:0;transform-origin:center;overflow:visible}.mat-progress-spinner circle{fill:rgba(0,0,0,0);transition:stroke-dashoffset 225ms linear}.cdk-high-contrast-active .mat-progress-spinner circle{stroke:CanvasText}.mat-progress-spinner[mode=indeterminate] svg{animation:mat-progress-spinner-linear-rotate 2000ms linear infinite}.mat-progress-spinner[mode=indeterminate] circle{transition-property:stroke;animation-duration:4000ms;animation-timing-function:cubic-bezier(0.35, 0, 0.25, 1);animation-iteration-count:infinite}.mat-progress-spinner._mat-animation-noopable svg,.mat-progress-spinner._mat-animation-noopable circle{animation:none;transition:none}@keyframes mat-progress-spinner-linear-rotate{0%{transform:rotate(0deg)}100%{transform:rotate(360deg)}}@keyframes mat-progress-spinner-stroke-rotate-100{0%{stroke-dashoffset:268.606171575px;transform:rotate(0)}12.5%{stroke-dashoffset:56.5486677px;transform:rotate(0)}12.5001%{stroke-dashoffset:56.5486677px;transform:rotateX(180deg) rotate(72.5deg)}25%{stroke-dashoffset:268.606171575px;transform:rotateX(180deg) rotate(72.5deg)}25.0001%{stroke-dashoffset:268.606171575px;transform:rotate(270deg)}37.5%{stroke-dashoffset:56.5486677px;transform:rotate(270deg)}37.5001%{stroke-dashoffset:56.5486677px;transform:rotateX(180deg) rotate(161.5deg)}50%{stroke-dashoffset:268.606171575px;transform:rotateX(180deg) rotate(161.5deg)}50.0001%{stroke-dashoffset:268.606171575px;transform:rotate(180deg)}62.5%{stroke-dashoffset:56.5486677px;transform:rotate(180deg)}62.5001%{stroke-dashoffset:56.5486677px;transform:rotateX(180deg) rotate(251.5deg)}75%{stroke-dashoffset:268.606171575px;transform:rotateX(180deg) rotate(251.5deg)}75.0001%{stroke-dashoffset:268.606171575px;transform:rotate(90deg)}87.5%{stroke-dashoffset:56.5486677px;transform:rotate(90deg)}87.5001%{stroke-dashoffset:56.5486677px;transform:rotateX(180deg) rotate(341.5deg)}100%{stroke-dashoffset:268.606171575px;transform:rotateX(180deg) rotate(341.5deg)}}"], dependencies: [{ kind: "directive", type: i3.NgSwitch, selector: "[ngSwitch]", inputs: ["ngSwitch"] }, { kind: "directive", type: i3.NgSwitchCase, selector: "[ngSwitchCase]", inputs: ["ngSwitchCase"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
239i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.0-rc.0", ngImport: i0, type: MatLegacyProgressSpinner, decorators: [{
240 type: Component,
241 args: [{ selector: 'mat-progress-spinner, mat-spinner', exportAs: 'matProgressSpinner', host: {
242 'role': 'progressbar',
243 // `mat-spinner` is here for backward compatibility.
244 'class': 'mat-progress-spinner mat-spinner',
245 // set tab index to -1 so screen readers will read the aria-label
246 // Note: there is a known issue with JAWS that does not read progressbar aria labels on FireFox
247 'tabindex': '-1',
248 '[class._mat-animation-noopable]': `_noopAnimations`,
249 '[style.width.px]': 'diameter',
250 '[style.height.px]': 'diameter',
251 '[attr.aria-valuemin]': 'mode === "determinate" ? 0 : null',
252 '[attr.aria-valuemax]': 'mode === "determinate" ? 100 : null',
253 '[attr.aria-valuenow]': 'mode === "determinate" ? value : null',
254 '[attr.mode]': 'mode',
255 }, inputs: ['color'], changeDetection: ChangeDetectionStrategy.OnPush, encapsulation: ViewEncapsulation.None, template: "<!--\n preserveAspectRatio of xMidYMid meet as the center of the viewport is the circle's\n center. The center of the circle will remain at the center of the mat-progress-spinner\n element containing the SVG.\n-->\n<!--\n All children need to be hidden for screen readers in order to support ChromeVox.\n More context in the issue: https://github.com/angular/components/issues/22165.\n-->\n<svg\n [style.width.px]=\"diameter\"\n [style.height.px]=\"diameter\"\n [attr.viewBox]=\"_getViewBox()\"\n preserveAspectRatio=\"xMidYMid meet\"\n focusable=\"false\"\n [ngSwitch]=\"mode === 'indeterminate'\"\n aria-hidden=\"true\"\n #svg>\n\n <!--\n Technically we can reuse the same `circle` element, however Safari has an issue that breaks\n the SVG rendering in determinate mode, after switching between indeterminate and determinate.\n Using a different element avoids the issue. An alternative to this is adding `display: none`\n for a split second and then removing it when switching between modes, but it's hard to know\n for how long to hide the element and it can cause the UI to blink.\n -->\n <circle\n *ngSwitchCase=\"true\"\n cx=\"50%\"\n cy=\"50%\"\n [attr.r]=\"_getCircleRadius()\"\n [style.animation-name]=\"'mat-progress-spinner-stroke-rotate-' + _spinnerAnimationLabel\"\n [style.stroke-dashoffset.px]=\"_getStrokeDashOffset()\"\n [style.stroke-dasharray.px]=\"_getStrokeCircumference()\"\n [style.stroke-width.%]=\"_getCircleStrokeWidth()\"\n [style.transform-origin]=\"_getCircleTransformOrigin(svg)\"></circle>\n\n <circle\n *ngSwitchCase=\"false\"\n cx=\"50%\"\n cy=\"50%\"\n [attr.r]=\"_getCircleRadius()\"\n [style.stroke-dashoffset.px]=\"_getStrokeDashOffset()\"\n [style.stroke-dasharray.px]=\"_getStrokeCircumference()\"\n [style.stroke-width.%]=\"_getCircleStrokeWidth()\"\n [style.transform-origin]=\"_getCircleTransformOrigin(svg)\"></circle>\n</svg>\n", styles: [".mat-progress-spinner{display:block;position:relative;overflow:hidden}.mat-progress-spinner svg{position:absolute;transform:rotate(-90deg);top:0;left:0;transform-origin:center;overflow:visible}.mat-progress-spinner circle{fill:rgba(0,0,0,0);transition:stroke-dashoffset 225ms linear}.cdk-high-contrast-active .mat-progress-spinner circle{stroke:CanvasText}.mat-progress-spinner[mode=indeterminate] svg{animation:mat-progress-spinner-linear-rotate 2000ms linear infinite}.mat-progress-spinner[mode=indeterminate] circle{transition-property:stroke;animation-duration:4000ms;animation-timing-function:cubic-bezier(0.35, 0, 0.25, 1);animation-iteration-count:infinite}.mat-progress-spinner._mat-animation-noopable svg,.mat-progress-spinner._mat-animation-noopable circle{animation:none;transition:none}@keyframes mat-progress-spinner-linear-rotate{0%{transform:rotate(0deg)}100%{transform:rotate(360deg)}}@keyframes mat-progress-spinner-stroke-rotate-100{0%{stroke-dashoffset:268.606171575px;transform:rotate(0)}12.5%{stroke-dashoffset:56.5486677px;transform:rotate(0)}12.5001%{stroke-dashoffset:56.5486677px;transform:rotateX(180deg) rotate(72.5deg)}25%{stroke-dashoffset:268.606171575px;transform:rotateX(180deg) rotate(72.5deg)}25.0001%{stroke-dashoffset:268.606171575px;transform:rotate(270deg)}37.5%{stroke-dashoffset:56.5486677px;transform:rotate(270deg)}37.5001%{stroke-dashoffset:56.5486677px;transform:rotateX(180deg) rotate(161.5deg)}50%{stroke-dashoffset:268.606171575px;transform:rotateX(180deg) rotate(161.5deg)}50.0001%{stroke-dashoffset:268.606171575px;transform:rotate(180deg)}62.5%{stroke-dashoffset:56.5486677px;transform:rotate(180deg)}62.5001%{stroke-dashoffset:56.5486677px;transform:rotateX(180deg) rotate(251.5deg)}75%{stroke-dashoffset:268.606171575px;transform:rotateX(180deg) rotate(251.5deg)}75.0001%{stroke-dashoffset:268.606171575px;transform:rotate(90deg)}87.5%{stroke-dashoffset:56.5486677px;transform:rotate(90deg)}87.5001%{stroke-dashoffset:56.5486677px;transform:rotateX(180deg) rotate(341.5deg)}100%{stroke-dashoffset:268.606171575px;transform:rotateX(180deg) rotate(341.5deg)}}"] }]
256 }], ctorParameters: function () { return [{ type: i0.ElementRef }, { type: i1.Platform }, { type: undefined, decorators: [{
257 type: Optional
258 }, {
259 type: Inject,
260 args: [DOCUMENT]
261 }] }, { type: undefined, decorators: [{
262 type: Optional
263 }, {
264 type: Inject,
265 args: [ANIMATION_MODULE_TYPE]
266 }] }, { type: undefined, decorators: [{
267 type: Inject,
268 args: [MAT_PROGRESS_SPINNER_DEFAULT_OPTIONS]
269 }] }, { type: i0.ChangeDetectorRef }, { type: i2.ViewportRuler }, { type: i0.NgZone }]; }, propDecorators: { diameter: [{
270 type: Input
271 }], strokeWidth: [{
272 type: Input
273 }], mode: [{
274 type: Input
275 }], value: [{
276 type: Input
277 }] } });
278
279/**
280 * @license
281 * Copyright Google LLC All Rights Reserved.
282 *
283 * Use of this source code is governed by an MIT-style license that can be
284 * found in the LICENSE file at https://angular.io/license
285 */
286/**
287 * @deprecated Use `MatProgressSpinnerModule` from `@angular/material/progress-spinner` instead. See https://material.angular.io/guide/mdc-migration for information about migrating.
288 * @breaking-change 17.0.0
289 */
290class MatLegacyProgressSpinnerModule {
291}
292MatLegacyProgressSpinnerModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.0-rc.0", ngImport: i0, type: MatLegacyProgressSpinnerModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
293MatLegacyProgressSpinnerModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "15.2.0-rc.0", ngImport: i0, type: MatLegacyProgressSpinnerModule, declarations: [MatLegacyProgressSpinner], imports: [MatCommonModule, CommonModule], exports: [MatLegacyProgressSpinner, MatCommonModule] });
294MatLegacyProgressSpinnerModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "15.2.0-rc.0", ngImport: i0, type: MatLegacyProgressSpinnerModule, imports: [MatCommonModule, CommonModule, MatCommonModule] });
295i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.0-rc.0", ngImport: i0, type: MatLegacyProgressSpinnerModule, decorators: [{
296 type: NgModule,
297 args: [{
298 imports: [MatCommonModule, CommonModule],
299 exports: [MatLegacyProgressSpinner, MatCommonModule],
300 declarations: [MatLegacyProgressSpinner],
301 }]
302 }] });
303
304/**
305 * @license
306 * Copyright Google LLC All Rights Reserved.
307 *
308 * Use of this source code is governed by an MIT-style license that can be
309 * found in the LICENSE file at https://angular.io/license
310 */
311/**
312 * @deprecated Import Progress Spinner instead. Note that the
313 * `mat-spinner` selector isn't deprecated.
314 * @breaking-change 8.0.0
315 */
316// tslint:disable-next-line:variable-name
317const MatLegacySpinner = MatLegacyProgressSpinner;
318
319/**
320 * @license
321 * Copyright Google LLC All Rights Reserved.
322 *
323 * Use of this source code is governed by an MIT-style license that can be
324 * found in the LICENSE file at https://angular.io/license
325 */
326
327/**
328 * Generated bundle index. Do not edit.
329 */
330
331export { MatLegacyProgressSpinner, MatLegacyProgressSpinnerModule, MatLegacySpinner };
332//# sourceMappingURL=legacy-progress-spinner.mjs.map