{"version":3,"file":"progress-bar.es5.js","sources":["../../packages/material/esm5/progress-bar/progress-bar.js","../../packages/material/esm5/progress-bar/progress-bar-module.js","../../packages/material/esm5/progress-bar/index.js"],"sourcesContent":["/**\n * @license\n * Copyright Google Inc. All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.io/license\n */\nimport { Component, ChangeDetectionStrategy, Input, ViewEncapsulation } from '@angular/core';\n/**\n * component.\n */\nvar MatProgressBar = (function () {\n function MatProgressBar() {\n /**\n * Color of the progress bar.\n */\n this.color = 'primary';\n this._value = 0;\n this._bufferValue = 0;\n /**\n * Mode of the progress bar.\n *\n * Input must be one of these values: determinate, indeterminate, buffer, query, defaults to\n * 'determinate'.\n * Mirrored to mode attribute.\n */\n this.mode = 'determinate';\n }\n Object.defineProperty(MatProgressBar.prototype, \"value\", {\n /**\n * Value of the progressbar. Defaults to zero. Mirrored to aria-valuenow.\n * @return {?}\n */\n get: function () { return this._value; },\n /**\n * @param {?} v\n * @return {?}\n */\n set: function (v) { this._value = clamp(v || 0); },\n enumerable: true,\n configurable: true\n });\n Object.defineProperty(MatProgressBar.prototype, \"bufferValue\", {\n /**\n * Buffer value of the progress bar. Defaults to zero.\n * @return {?}\n */\n get: function () { return this._bufferValue; },\n /**\n * @param {?} v\n * @return {?}\n */\n set: function (v) { this._bufferValue = clamp(v || 0); },\n enumerable: true,\n configurable: true\n });\n /**\n * Gets the current transform value for the progress bar's primary indicator.\n * @return {?}\n */\n MatProgressBar.prototype._primaryTransform = function () {\n var /** @type {?} */ scale = this.value / 100;\n return { transform: \"scaleX(\" + scale + \")\" };\n };\n /**\n * Gets the current transform value for the progress bar's buffer indicator. Only used if the\n * progress mode is set to buffer, otherwise returns an undefined, causing no transformation.\n * @return {?}\n */\n MatProgressBar.prototype._bufferTransform = function () {\n if (this.mode == 'buffer') {\n var /** @type {?} */ scale = this.bufferValue / 100;\n return { transform: \"scaleX(\" + scale + \")\" };\n }\n };\n MatProgressBar.decorators = [\n { type: Component, args: [{selector: 'mat-progress-bar',\n exportAs: 'matProgressBar',\n host: {\n 'role': 'progressbar',\n 'aria-valuemin': '0',\n 'aria-valuemax': '100',\n '[attr.aria-valuenow]': 'value',\n '[attr.mode]': 'mode',\n '[class.mat-primary]': 'color == \"primary\"',\n '[class.mat-accent]': 'color == \"accent\"',\n '[class.mat-warn]': 'color == \"warn\"',\n 'class': 'mat-progress-bar',\n },\n template: \"
\",\n styles: [\".mat-progress-bar{display:block;height:5px;overflow:hidden;position:relative;transform:translateZ(0);transition:opacity 250ms linear;width:100%}.mat-progress-bar .mat-progress-bar-element,.mat-progress-bar .mat-progress-bar-fill::after{height:100%;position:absolute;width:100%}.mat-progress-bar .mat-progress-bar-background{background-repeat:repeat-x;background-size:10px 4px;display:none}.mat-progress-bar .mat-progress-bar-buffer{transform-origin:top left;transition:transform 250ms ease}.mat-progress-bar .mat-progress-bar-secondary{display:none}.mat-progress-bar .mat-progress-bar-fill{animation:none;transform-origin:top left;transition:transform 250ms ease}.mat-progress-bar .mat-progress-bar-fill::after{animation:none;content:'';display:inline-block;left:0}.mat-progress-bar[dir=rtl],[dir=rtl] .mat-progress-bar{transform:rotateY(180deg)}.mat-progress-bar[mode=query]{transform:rotateZ(180deg)}.mat-progress-bar[mode=query][dir=rtl],[dir=rtl] .mat-progress-bar[mode=query]{transform:rotateZ(180deg) rotateY(180deg)}.mat-progress-bar[mode=indeterminate] .mat-progress-bar-fill,.mat-progress-bar[mode=query] .mat-progress-bar-fill{transition:none}.mat-progress-bar[mode=indeterminate] .mat-progress-bar-primary,.mat-progress-bar[mode=query] .mat-progress-bar-primary{animation:mat-progress-bar-primary-indeterminate-translate 2s infinite linear;left:-145.166611%}.mat-progress-bar[mode=indeterminate] .mat-progress-bar-primary.mat-progress-bar-fill::after,.mat-progress-bar[mode=query] .mat-progress-bar-primary.mat-progress-bar-fill::after{animation:mat-progress-bar-primary-indeterminate-scale 2s infinite linear}.mat-progress-bar[mode=indeterminate] .mat-progress-bar-secondary,.mat-progress-bar[mode=query] .mat-progress-bar-secondary{animation:mat-progress-bar-secondary-indeterminate-translate 2s infinite linear;left:-54.888891%;display:block}.mat-progress-bar[mode=indeterminate] .mat-progress-bar-secondary.mat-progress-bar-fill::after,.mat-progress-bar[mode=query] .mat-progress-bar-secondary.mat-progress-bar-fill::after{animation:mat-progress-bar-secondary-indeterminate-scale 2s infinite linear}.mat-progress-bar[mode=buffer] .mat-progress-bar-background{animation:mat-progress-bar-background-scroll 250ms infinite linear;display:block}@keyframes mat-progress-bar-primary-indeterminate-translate{0%{transform:translateX(0)}20%{animation-timing-function:cubic-bezier(.5,0,.70173,.49582);transform:translateX(0)}59.15%{animation-timing-function:cubic-bezier(.30244,.38135,.55,.95635);transform:translateX(83.67142%)}100%{transform:translateX(200.61106%)}}@keyframes mat-progress-bar-primary-indeterminate-scale{0%{transform:scaleX(.08)}36.65%{animation-timing-function:cubic-bezier(.33473,.12482,.78584,1);transform:scaleX(.08)}69.15%{animation-timing-function:cubic-bezier(.06,.11,.6,1);transform:scaleX(.66148)}100%{transform:scaleX(.08)}}@keyframes mat-progress-bar-secondary-indeterminate-translate{0%{animation-timing-function:cubic-bezier(.15,0,.51506,.40969);transform:translateX(0)}25%{animation-timing-function:cubic-bezier(.31033,.28406,.8,.73371);transform:translateX(37.65191%)}48.35%{animation-timing-function:cubic-bezier(.4,.62704,.6,.90203);transform:translateX(84.38617%)}100%{transform:translateX(160.27778%)}}@keyframes mat-progress-bar-secondary-indeterminate-scale{0%{animation-timing-function:cubic-bezier(.15,0,.51506,.40969);transform:scaleX(.08)}19.15%{animation-timing-function:cubic-bezier(.31033,.28406,.8,.73371);transform:scaleX(.4571)}44.15%{animation-timing-function:cubic-bezier(.4,.62704,.6,.90203);transform:scaleX(.72796)}100%{transform:scaleX(.08)}}@keyframes mat-progress-bar-background-scroll{to{transform:translateX(-10px)}}\"],\n changeDetection: ChangeDetectionStrategy.OnPush,\n encapsulation: ViewEncapsulation.None,\n preserveWhitespaces: false,\n },] },\n ];\n /**\n * @nocollapse\n */\n MatProgressBar.ctorParameters = function () { return []; };\n MatProgressBar.propDecorators = {\n 'color': [{ type: Input },],\n 'value': [{ type: Input },],\n 'bufferValue': [{ type: Input },],\n 'mode': [{ type: Input },],\n };\n return MatProgressBar;\n}());\nexport { MatProgressBar };\nfunction MatProgressBar_tsickle_Closure_declarations() {\n /** @type {?} */\n MatProgressBar.decorators;\n /**\n * @nocollapse\n * @type {?}\n */\n MatProgressBar.ctorParameters;\n /** @type {?} */\n MatProgressBar.propDecorators;\n /**\n * Color of the progress bar.\n * @type {?}\n */\n MatProgressBar.prototype.color;\n /** @type {?} */\n MatProgressBar.prototype._value;\n /** @type {?} */\n MatProgressBar.prototype._bufferValue;\n /**\n * Mode of the progress bar.\n *\n * Input must be one of these values: determinate, indeterminate, buffer, query, defaults to\n * 'determinate'.\n * Mirrored to mode attribute.\n * @type {?}\n */\n MatProgressBar.prototype.mode;\n}\n/**\n * Clamps a value to be between two numbers, by default 0 and 100.\n * @param {?} v\n * @param {?=} min\n * @param {?=} max\n * @return {?}\n */\nfunction clamp(v, min, max) {\n if (min === void 0) { min = 0; }\n if (max === void 0) { max = 100; }\n return Math.max(min, Math.min(max, v));\n}\n//# sourceMappingURL=progress-bar.js.map","/**\n * @license\n * Copyright Google Inc. All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.io/license\n */\nimport { NgModule } from '@angular/core';\nimport { CommonModule } from '@angular/common';\nimport { MatCommonModule } from '@angular/material/core';\nimport { MatProgressBar } from './progress-bar';\nvar MatProgressBarModule = (function () {\n function MatProgressBarModule() {\n }\n MatProgressBarModule.decorators = [\n { type: NgModule, args: [{\n imports: [CommonModule, MatCommonModule],\n exports: [MatProgressBar, MatCommonModule],\n declarations: [MatProgressBar],\n },] },\n ];\n /**\n * @nocollapse\n */\n MatProgressBarModule.ctorParameters = function () { return []; };\n return MatProgressBarModule;\n}());\nexport { MatProgressBarModule };\nfunction MatProgressBarModule_tsickle_Closure_declarations() {\n /** @type {?} */\n MatProgressBarModule.decorators;\n /**\n * @nocollapse\n * @type {?}\n */\n MatProgressBarModule.ctorParameters;\n}\n//# sourceMappingURL=progress-bar-module.js.map","/**\n * Generated bundle index. Do not edit.\n */\nexport { MatProgressBarModule, MatProgressBar } from './public-api';\n//# sourceMappingURL=index.js.map"],"names":[],"mappings":";;;;;;;;;;;AAQA;;;AAGA,IAAI,cAAc,IAAI,YAAY;IAC9B,SAAS,cAAc,GAAG;;;;QAItB,IAAI,CAAC,KAAK,GAAG,SAAS,CAAC;QACvB,IAAI,CAAC,MAAM,GAAG,CAAC,CAAC;QAChB,IAAI,CAAC,YAAY,GAAG,CAAC,CAAC;;;;;;;;QAQtB,IAAI,CAAC,IAAI,GAAG,aAAa,CAAC;KAC7B;IACD,MAAM,CAAC,cAAc,CAAC,cAAc,CAAC,SAAS,EAAE,OAAO,EAAE;;;;;QAKrD,GAAG,EAAE,YAAY,EAAE,OAAO,IAAI,CAAC,MAAM,CAAC,EAAE;;;;;QAKxC,GAAG,EAAE,UAAU,CAAC,EAAE,EAAE,IAAI,CAAC,MAAM,GAAG,KAAK,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC,EAAE;QAClD,UAAU,EAAE,IAAI;QAChB,YAAY,EAAE,IAAI;KACrB,CAAC,CAAC;IACH,MAAM,CAAC,cAAc,CAAC,cAAc,CAAC,SAAS,EAAE,aAAa,EAAE;;;;;QAK3D,GAAG,EAAE,YAAY,EAAE,OAAO,IAAI,CAAC,YAAY,CAAC,EAAE;;;;;QAK9C,GAAG,EAAE,UAAU,CAAC,EAAE,EAAE,IAAI,CAAC,YAAY,GAAG,KAAK,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC,EAAE;QACxD,UAAU,EAAE,IAAI;QAChB,YAAY,EAAE,IAAI;KACrB,CAAC,CAAC;;;;;IAKH,cAAc,CAAC,SAAS,CAAC,iBAAiB,GAAG,YAAY;QACr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