blob: b73d4343abe35fa46722ce7540a8399cde0c04c3 [file] [log] [blame]
{"version":3,"file":"material-form-field.umd.min.js","sources":["../../node_modules/tslib/tslib.es6.js","../../src/material/form-field/form-field-errors.ts","../../src/material/form-field/error.ts","../../src/material/form-field/form-field-animations.ts","../../src/material/form-field/form-field-control.ts","../../src/material/form-field/hint.ts","../../src/material/form-field/label.ts","../../src/material/form-field/placeholder.ts","../../src/material/form-field/prefix.ts","../../src/material/form-field/suffix.ts","../../src/material/form-field/form-field.ts","../../src/material/form-field/form-field-module.ts"],"sourcesContent":["/*! *****************************************************************************\r\nCopyright (c) Microsoft Corporation. All rights reserved.\r\nLicensed under the Apache License, Version 2.0 (the \"License\"); you may not use\r\nthis file except in compliance with the License. You may obtain a copy of the\r\nLicense at http://www.apache.org/licenses/LICENSE-2.0\r\n\r\nTHIS CODE IS PROVIDED ON AN *AS IS* BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY\r\nKIND, EITHER EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION ANY IMPLIED\r\nWARRANTIES OR CONDITIONS OF TITLE, FITNESS FOR A PARTICULAR PURPOSE,\r\nMERCHANTABLITY OR NON-INFRINGEMENT.\r\n\r\nSee the Apache Version 2.0 License for specific language governing permissions\r\nand limitations under the License.\r\n***************************************************************************** */\r\n/* global Reflect, Promise */\r\n\r\nvar extendStatics = function(d, b) {\r\n extendStatics = Object.setPrototypeOf ||\r\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\r\n function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };\r\n return extendStatics(d, b);\r\n};\r\n\r\nexport function __extends(d, b) {\r\n extendStatics(d, b);\r\n function __() { this.constructor = d; }\r\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\r\n}\r\n\r\nexport var __assign = function() {\r\n __assign = Object.assign || function __assign(t) {\r\n for (var s, i = 1, n = arguments.length; i < n; i++) {\r\n s = arguments[i];\r\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p)) t[p] = s[p];\r\n }\r\n return t;\r\n }\r\n return __assign.apply(this, arguments);\r\n}\r\n\r\nexport function __rest(s, e) {\r\n var t = {};\r\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)\r\n t[p] = s[p];\r\n if (s != null && typeof Object.getOwnPropertySymbols === \"function\")\r\n for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) if (e.indexOf(p[i]) < 0)\r\n t[p[i]] = s[p[i]];\r\n return t;\r\n}\r\n\r\nexport function __decorate(decorators, target, key, desc) {\r\n var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;\r\n if (typeof Reflect === \"object\" && typeof Reflect.decorate === \"function\") r = Reflect.decorate(decorators, target, key, desc);\r\n else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;\r\n return c > 3 && r && Object.defineProperty(target, key, r), r;\r\n}\r\n\r\nexport function __param(paramIndex, decorator) {\r\n return function (target, key) { decorator(target, key, paramIndex); }\r\n}\r\n\r\nexport function __metadata(metadataKey, metadataValue) {\r\n if (typeof Reflect === \"object\" && typeof Reflect.metadata === \"function\") return Reflect.metadata(metadataKey, metadataValue);\r\n}\r\n\r\nexport function __awaiter(thisArg, _arguments, P, generator) {\r\n return new (P || (P = Promise))(function (resolve, reject) {\r\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\r\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\r\n function step(result) { result.done ? resolve(result.value) : new P(function (resolve) { resolve(result.value); }).then(fulfilled, rejected); }\r\n step((generator = generator.apply(thisArg, _arguments || [])).next());\r\n });\r\n}\r\n\r\nexport function __generator(thisArg, body) {\r\n var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;\r\n return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\r\n function verb(n) { return function (v) { return step([n, v]); }; }\r\n function step(op) {\r\n if (f) throw new TypeError(\"Generator is already executing.\");\r\n while (_) try {\r\n if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;\r\n if (y = 0, t) op = [op[0] & 2, t.value];\r\n switch (op[0]) {\r\n case 0: case 1: t = op; break;\r\n case 4: _.label++; return { value: op[1], done: false };\r\n case 5: _.label++; y = op[1]; op = [0]; continue;\r\n case 7: op = _.ops.pop(); _.trys.pop(); continue;\r\n default:\r\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\r\n if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\r\n if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\r\n if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\r\n if (t[2]) _.ops.pop();\r\n _.trys.pop(); continue;\r\n }\r\n op = body.call(thisArg, _);\r\n } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }\r\n if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };\r\n }\r\n}\r\n\r\nexport function __exportStar(m, exports) {\r\n for (var p in m) if (!exports.hasOwnProperty(p)) exports[p] = m[p];\r\n}\r\n\r\nexport function __values(o) {\r\n var m = typeof Symbol === \"function\" && o[Symbol.iterator], i = 0;\r\n if (m) return m.call(o);\r\n return {\r\n next: function () {\r\n if (o && i >= o.length) o = void 0;\r\n return { value: o && o[i++], done: !o };\r\n }\r\n };\r\n}\r\n\r\nexport function __read(o, n) {\r\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\r\n if (!m) return o;\r\n var i = m.call(o), r, ar = [], e;\r\n try {\r\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\r\n }\r\n catch (error) { e = { error: error }; }\r\n finally {\r\n try {\r\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\r\n }\r\n finally { if (e) throw e.error; }\r\n }\r\n return ar;\r\n}\r\n\r\nexport function __spread() {\r\n for (var ar = [], i = 0; i < arguments.length; i++)\r\n ar = ar.concat(__read(arguments[i]));\r\n return ar;\r\n}\r\n\r\nexport function __await(v) {\r\n return this instanceof __await ? (this.v = v, this) : new __await(v);\r\n}\r\n\r\nexport function __asyncGenerator(thisArg, _arguments, generator) {\r\n if (!Symbol.asyncIterator) throw new TypeError(\"Symbol.asyncIterator is not defined.\");\r\n var g = generator.apply(thisArg, _arguments || []), i, q = [];\r\n return i = {}, verb(\"next\"), verb(\"throw\"), verb(\"return\"), i[Symbol.asyncIterator] = function () { return this; }, i;\r\n function verb(n) { if (g[n]) i[n] = function (v) { return new Promise(function (a, b) { q.push([n, v, a, b]) > 1 || resume(n, v); }); }; }\r\n function resume(n, v) { try { step(g[n](v)); } catch (e) { settle(q[0][3], e); } }\r\n function step(r) { r.value instanceof __await ? Promise.resolve(r.value.v).then(fulfill, reject) : settle(q[0][2], r); }\r\n function fulfill(value) { resume(\"next\", value); }\r\n function reject(value) { resume(\"throw\", value); }\r\n function settle(f, v) { if (f(v), q.shift(), q.length) resume(q[0][0], q[0][1]); }\r\n}\r\n\r\nexport function __asyncDelegator(o) {\r\n var i, p;\r\n return i = {}, verb(\"next\"), verb(\"throw\", function (e) { throw e; }), verb(\"return\"), i[Symbol.iterator] = function () { return this; }, i;\r\n function verb(n, f) { i[n] = o[n] ? function (v) { return (p = !p) ? { value: __await(o[n](v)), done: n === \"return\" } : f ? f(v) : v; } : f; }\r\n}\r\n\r\nexport function __asyncValues(o) {\r\n if (!Symbol.asyncIterator) throw new TypeError(\"Symbol.asyncIterator is not defined.\");\r\n var m = o[Symbol.asyncIterator], i;\r\n return m ? m.call(o) : (o = typeof __values === \"function\" ? __values(o) : o[Symbol.iterator](), i = {}, verb(\"next\"), verb(\"throw\"), verb(\"return\"), i[Symbol.asyncIterator] = function () { return this; }, i);\r\n function verb(n) { i[n] = o[n] && function (v) { return new Promise(function (resolve, reject) { v = o[n](v), settle(resolve, reject, v.done, v.value); }); }; }\r\n function settle(resolve, reject, d, v) { Promise.resolve(v).then(function(v) { resolve({ value: v, done: d }); }, reject); }\r\n}\r\n\r\nexport function __makeTemplateObject(cooked, raw) {\r\n if (Object.defineProperty) { Object.defineProperty(cooked, \"raw\", { value: raw }); } else { cooked.raw = raw; }\r\n return cooked;\r\n};\r\n\r\nexport function __importStar(mod) {\r\n if (mod && mod.__esModule) return mod;\r\n var result = {};\r\n if (mod != null) for (var k in mod) if (Object.hasOwnProperty.call(mod, k)) result[k] = mod[k];\r\n result.default = mod;\r\n return result;\r\n}\r\n\r\nexport function __importDefault(mod) {\r\n return (mod && mod.__esModule) ? mod : { default: mod };\r\n}\r\n","/**\n * @license\n * Copyright Google LLC 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 */\n\n/** @docs-private */\nexport function getMatFormFieldPlaceholderConflictError(): Error {\n return Error('Placeholder attribute and child element were both specified.');\n}\n\n/** @docs-private */\nexport function getMatFormFieldDuplicatedHintError(align: string): Error {\n return Error(`A hint was already declared for 'align=\"${align}\"'.`);\n}\n\n/** @docs-private */\nexport function getMatFormFieldMissingControlError(): Error {\n return Error('mat-form-field must contain a MatFormFieldControl.');\n}\n","/**\n * @license\n * Copyright Google LLC 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 */\n\nimport {Directive, Input} from '@angular/core';\n\n\nlet nextUniqueId = 0;\n\n\n/** Single error message to be shown underneath the form field. */\n@Directive({\n selector: 'mat-error',\n host: {\n 'class': 'mat-error',\n 'role': 'alert',\n '[attr.id]': 'id',\n }\n})\nexport class MatError {\n @Input() id: string = `mat-error-${nextUniqueId++}`;\n}\n","/**\n * @license\n * Copyright Google LLC 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 {\n animate,\n state,\n style,\n transition,\n trigger,\n AnimationTriggerMetadata,\n} from '@angular/animations';\n\n/**\n * Animations used by the MatFormField.\n * @docs-private\n */\nexport const matFormFieldAnimations: {\n readonly transitionMessages: AnimationTriggerMetadata\n} = {\n /** Animation that transitions the form field's error and hint messages. */\n transitionMessages: trigger('transitionMessages', [\n // TODO(mmalerba): Use angular animations for label animation as well.\n state('enter', style({ opacity: 1, transform: 'translateY(0%)' })),\n transition('void => enter', [\n style({ opacity: 0, transform: 'translateY(-100%)' }),\n animate('300ms cubic-bezier(0.55, 0, 0.55, 0.2)'),\n ]),\n ])\n};\n","/**\n * @license\n * Copyright Google LLC 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 */\n\nimport {Observable} from 'rxjs';\nimport {NgControl} from '@angular/forms';\n\n\n/** An interface which allows a control to work inside of a `MatFormField`. */\nexport abstract class MatFormFieldControl<T> {\n /** The value of the control. */\n value: T | null;\n\n /**\n * Stream that emits whenever the state of the control changes such that the parent `MatFormField`\n * needs to run change detection.\n */\n readonly stateChanges: Observable<void>;\n\n /** The element ID for this control. */\n readonly id: string;\n\n /** The placeholder for this control. */\n readonly placeholder: string;\n\n /** Gets the NgControl for this control. */\n readonly ngControl: NgControl | null;\n\n /** Whether the control is focused. */\n readonly focused: boolean;\n\n /** Whether the control is empty. */\n readonly empty: boolean;\n\n /** Whether the `MatFormField` label should try to float. */\n readonly shouldLabelFloat: boolean;\n\n /** Whether the control is required. */\n readonly required: boolean;\n\n /** Whether the control is disabled. */\n readonly disabled: boolean;\n\n /** Whether the control is in an error state. */\n readonly errorState: boolean;\n\n /**\n * An optional name for the control type that can be used to distinguish `mat-form-field` elements\n * based on their control type. The form field will add a class,\n * `mat-form-field-type-{{controlType}}` to its root element.\n */\n readonly controlType?: string;\n\n /**\n * Whether the input is currently in an autofilled state. If property is not present on the\n * control it is assumed to be false.\n */\n readonly autofilled?: boolean;\n\n /** Sets the list of element IDs that currently describe this control. */\n abstract setDescribedByIds(ids: string[]): void;\n\n /** Handles a click on the control's container. */\n abstract onContainerClick(event: MouseEvent): void;\n}\n","/**\n * @license\n * Copyright Google LLC 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 */\n\nimport {Directive, Input} from '@angular/core';\n\n\nlet nextUniqueId = 0;\n\n\n/** Hint text to be shown underneath the form field control. */\n@Directive({\n selector: 'mat-hint',\n host: {\n 'class': 'mat-hint',\n '[class.mat-right]': 'align == \"end\"',\n '[attr.id]': 'id',\n // Remove align attribute to prevent it from interfering with layout.\n '[attr.align]': 'null',\n }\n})\nexport class MatHint {\n /** Whether to align the hint label at the start or end of the line. */\n @Input() align: 'start' | 'end' = 'start';\n\n /** Unique ID for the hint. Used for the aria-describedby on the form field control. */\n @Input() id: string = `mat-hint-${nextUniqueId++}`;\n}\n","/**\n * @license\n * Copyright Google LLC 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 */\n\nimport {Directive} from '@angular/core';\n\n\n/** The floating label for a `mat-form-field`. */\n@Directive({\n selector: 'mat-label'\n})\nexport class MatLabel {}\n","/**\n * @license\n * Copyright Google LLC 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 */\n\nimport {Directive} from '@angular/core';\n\n\n/**\n * The placeholder text for an `MatFormField`.\n * @deprecated Use `<mat-label>` to specify the label and the `placeholder` attribute to specify the\n * placeholder.\n * @breaking-change 8.0.0\n */\n@Directive({\n selector: 'mat-placeholder'\n})\nexport class MatPlaceholder {}\n","/**\n * @license\n * Copyright Google LLC 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 */\n\nimport {Directive} from '@angular/core';\n\n\n/** Prefix to be placed in front of the form field. */\n@Directive({\n selector: '[matPrefix]',\n})\nexport class MatPrefix {}\n","/**\n * @license\n * Copyright Google LLC 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 */\n\nimport {Directive} from '@angular/core';\n\n\n/** Suffix to be placed at the end of the form field. */\n@Directive({\n selector: '[matSuffix]',\n})\nexport class MatSuffix {}\n","/**\n * @license\n * Copyright Google LLC 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 */\n\nimport {Directionality} from '@angular/cdk/bidi';\nimport {coerceBooleanProperty} from '@angular/cdk/coercion';\nimport {\n AfterContentChecked,\n AfterContentInit,\n AfterViewInit,\n ChangeDetectionStrategy,\n ChangeDetectorRef,\n Component,\n ContentChild,\n ContentChildren,\n ElementRef,\n Inject,\n InjectionToken,\n Input,\n NgZone,\n Optional,\n QueryList,\n ViewChild,\n ViewEncapsulation,\n OnDestroy,\n} from '@angular/core';\nimport {\n CanColor, CanColorCtor,\n FloatLabelType,\n LabelOptions,\n MAT_LABEL_GLOBAL_OPTIONS,\n mixinColor,\n} from '@angular/material/core';\nimport {fromEvent, merge, Subject} from 'rxjs';\nimport {startWith, take, takeUntil} from 'rxjs/operators';\nimport {MatError} from './error';\nimport {matFormFieldAnimations} from './form-field-animations';\nimport {MatFormFieldControl} from './form-field-control';\nimport {\n getMatFormFieldDuplicatedHintError,\n getMatFormFieldMissingControlError,\n getMatFormFieldPlaceholderConflictError,\n} from './form-field-errors';\nimport {MatHint} from './hint';\nimport {MatLabel} from './label';\nimport {MatPlaceholder} from './placeholder';\nimport {MatPrefix} from './prefix';\nimport {MatSuffix} from './suffix';\nimport {Platform} from '@angular/cdk/platform';\nimport {NgControl} from '@angular/forms';\nimport {ANIMATION_MODULE_TYPE} from '@angular/platform-browser/animations';\n\n\nlet nextUniqueId = 0;\nconst floatingLabelScale = 0.75;\nconst outlineGapPadding = 5;\n\n\n/**\n * Boilerplate for applying mixins to MatFormField.\n * @docs-private\n */\nclass MatFormFieldBase {\n constructor(public _elementRef: ElementRef) { }\n}\n\n/**\n * Base class to which we're applying the form field mixins.\n * @docs-private\n */\nconst _MatFormFieldMixinBase: CanColorCtor & typeof MatFormFieldBase =\n mixinColor(MatFormFieldBase, 'primary');\n\n/** Possible appearance styles for the form field. */\nexport type MatFormFieldAppearance = 'legacy' | 'standard' | 'fill' | 'outline';\n\n/**\n * Represents the default options for the form field that can be configured\n * using the `MAT_FORM_FIELD_DEFAULT_OPTIONS` injection token.\n */\nexport interface MatFormFieldDefaultOptions {\n appearance?: MatFormFieldAppearance;\n}\n\n/**\n * Injection token that can be used to configure the\n * default options for all form field within an app.\n */\nexport const MAT_FORM_FIELD_DEFAULT_OPTIONS =\n new InjectionToken<MatFormFieldDefaultOptions>('MAT_FORM_FIELD_DEFAULT_OPTIONS');\n\n\n/** Container for form controls that applies Material Design styling and behavior. */\n@Component({\n moduleId: module.id,\n selector: 'mat-form-field',\n exportAs: 'matFormField',\n templateUrl: 'form-field.html',\n // MatInput is a directive and can't have styles, so we need to include its styles here\n // in form-field-input.css. The MatInput styles are fairly minimal so it shouldn't be a\n // big deal for people who aren't using MatInput.\n styleUrls: [\n 'form-field.css',\n 'form-field-fill.css',\n 'form-field-input.css',\n 'form-field-legacy.css',\n 'form-field-outline.css',\n 'form-field-standard.css',\n ],\n animations: [matFormFieldAnimations.transitionMessages],\n host: {\n 'class': 'mat-form-field',\n '[class.mat-form-field-appearance-standard]': 'appearance == \"standard\"',\n '[class.mat-form-field-appearance-fill]': 'appearance == \"fill\"',\n '[class.mat-form-field-appearance-outline]': 'appearance == \"outline\"',\n '[class.mat-form-field-appearance-legacy]': 'appearance == \"legacy\"',\n '[class.mat-form-field-invalid]': '_control.errorState',\n '[class.mat-form-field-can-float]': '_canLabelFloat',\n '[class.mat-form-field-should-float]': '_shouldLabelFloat()',\n '[class.mat-form-field-has-label]': '_hasFloatingLabel()',\n '[class.mat-form-field-hide-placeholder]': '_hideControlPlaceholder()',\n '[class.mat-form-field-disabled]': '_control.disabled',\n '[class.mat-form-field-autofilled]': '_control.autofilled',\n '[class.mat-focused]': '_control.focused',\n '[class.mat-accent]': 'color == \"accent\"',\n '[class.mat-warn]': 'color == \"warn\"',\n '[class.ng-untouched]': '_shouldForward(\"untouched\")',\n '[class.ng-touched]': '_shouldForward(\"touched\")',\n '[class.ng-pristine]': '_shouldForward(\"pristine\")',\n '[class.ng-dirty]': '_shouldForward(\"dirty\")',\n '[class.ng-valid]': '_shouldForward(\"valid\")',\n '[class.ng-invalid]': '_shouldForward(\"invalid\")',\n '[class.ng-pending]': '_shouldForward(\"pending\")',\n '[class._mat-animation-noopable]': '!_animationsEnabled',\n },\n inputs: ['color'],\n encapsulation: ViewEncapsulation.None,\n changeDetection: ChangeDetectionStrategy.OnPush,\n})\n\nexport class MatFormField extends _MatFormFieldMixinBase\n implements AfterContentInit, AfterContentChecked, AfterViewInit, OnDestroy, CanColor {\n private _labelOptions: LabelOptions;\n\n /**\n * Whether the outline gap needs to be calculated\n * immediately on the next change detection run.\n */\n private _outlineGapCalculationNeededImmediately = false;\n\n /** Whether the outline gap needs to be calculated next time the zone has stabilized. */\n private _outlineGapCalculationNeededOnStable = false;\n\n private _destroyed = new Subject<void>();\n\n /** The form-field appearance style. */\n @Input()\n get appearance(): MatFormFieldAppearance { return this._appearance; }\n set appearance(value: MatFormFieldAppearance) {\n const oldValue = this._appearance;\n\n this._appearance = value || (this._defaults && this._defaults.appearance) || 'legacy';\n\n if (this._appearance === 'outline' && oldValue !== value) {\n this._outlineGapCalculationNeededOnStable = true;\n }\n }\n _appearance: MatFormFieldAppearance;\n\n /** Whether the required marker should be hidden. */\n @Input()\n get hideRequiredMarker(): boolean { return this._hideRequiredMarker; }\n set hideRequiredMarker(value: boolean) {\n this._hideRequiredMarker = coerceBooleanProperty(value);\n }\n private _hideRequiredMarker: boolean;\n\n /** Override for the logic that disables the label animation in certain cases. */\n private _showAlwaysAnimate = false;\n\n /** Whether the floating label should always float or not. */\n get _shouldAlwaysFloat(): boolean {\n return this.floatLabel === 'always' && !this._showAlwaysAnimate;\n }\n\n /** Whether the label can float or not. */\n get _canLabelFloat(): boolean { return this.floatLabel !== 'never'; }\n\n /** State of the mat-hint and mat-error animations. */\n _subscriptAnimationState: string = '';\n\n /** Text for the form field hint. */\n @Input()\n get hintLabel(): string { return this._hintLabel; }\n set hintLabel(value: string) {\n this._hintLabel = value;\n this._processHints();\n }\n private _hintLabel = '';\n\n // Unique id for the hint label.\n _hintLabelId: string = `mat-hint-${nextUniqueId++}`;\n\n // Unique id for the internal form field label.\n _labelId = `mat-form-field-label-${nextUniqueId++}`;\n\n /**\n * Whether the label should always float, never float or float as the user types.\n *\n * Note: only the legacy appearance supports the `never` option. `never` was originally added as a\n * way to make the floating label emulate the behavior of a standard input placeholder. However\n * the form field now supports both floating labels and placeholders. Therefore in the non-legacy\n * appearances the `never` option has been disabled in favor of just using the placeholder.\n */\n @Input()\n get floatLabel(): FloatLabelType {\n return this.appearance !== 'legacy' && this._floatLabel === 'never' ? 'auto' : this._floatLabel;\n }\n set floatLabel(value: FloatLabelType) {\n if (value !== this._floatLabel) {\n this._floatLabel = value || this._labelOptions.float || 'auto';\n this._changeDetectorRef.markForCheck();\n }\n }\n private _floatLabel: FloatLabelType;\n\n /** Whether the Angular animations are enabled. */\n _animationsEnabled: boolean;\n\n /**\n * @deprecated\n * @breaking-change 8.0.0\n */\n @ViewChild('underline', {static: false}) underlineRef: ElementRef;\n\n @ViewChild('connectionContainer', {static: true}) _connectionContainerRef: ElementRef;\n @ViewChild('inputContainer', {static: false}) _inputContainerRef: ElementRef;\n @ViewChild('label', {static: false}) private _label: ElementRef;\n\n @ContentChild(MatFormFieldControl, {static: false}) _controlNonStatic: MatFormFieldControl<any>;\n @ContentChild(MatFormFieldControl, {static: true}) _controlStatic: MatFormFieldControl<any>;\n get _control() {\n // TODO(crisbeto): we need this hacky workaround in order to support both Ivy\n // and ViewEngine. We should clean this up once Ivy is the default renderer.\n return this._explicitFormFieldControl || this._controlNonStatic || this._controlStatic;\n }\n set _control(value) {\n this._explicitFormFieldControl = value;\n }\n private _explicitFormFieldControl: MatFormFieldControl<any>;\n\n @ContentChild(MatLabel, {static: false}) _labelChildNonStatic: MatLabel;\n @ContentChild(MatLabel, {static: true}) _labelChildStatic: MatLabel;\n get _labelChild() {\n return this._labelChildNonStatic || this._labelChildStatic;\n }\n\n @ContentChild(MatPlaceholder, {static: false}) _placeholderChild: MatPlaceholder;\n @ContentChildren(MatError) _errorChildren: QueryList<MatError>;\n @ContentChildren(MatHint) _hintChildren: QueryList<MatHint>;\n @ContentChildren(MatPrefix) _prefixChildren: QueryList<MatPrefix>;\n @ContentChildren(MatSuffix) _suffixChildren: QueryList<MatSuffix>;\n\n constructor(\n public _elementRef: ElementRef, private _changeDetectorRef: ChangeDetectorRef,\n @Optional() @Inject(MAT_LABEL_GLOBAL_OPTIONS) labelOptions: LabelOptions,\n @Optional() private _dir: Directionality,\n @Optional() @Inject(MAT_FORM_FIELD_DEFAULT_OPTIONS) private _defaults:\n MatFormFieldDefaultOptions, private _platform: Platform, private _ngZone: NgZone,\n @Optional() @Inject(ANIMATION_MODULE_TYPE) _animationMode: string) {\n super(_elementRef);\n\n this._labelOptions = labelOptions ? labelOptions : {};\n this.floatLabel = this._labelOptions.float || 'auto';\n this._animationsEnabled = _animationMode !== 'NoopAnimations';\n\n // Set the default through here so we invoke the setter on the first run.\n this.appearance = (_defaults && _defaults.appearance) ? _defaults.appearance : 'legacy';\n }\n\n /**\n * Gets an ElementRef for the element that a overlay attached to the form-field should be\n * positioned relative to.\n */\n getConnectedOverlayOrigin(): ElementRef {\n return this._connectionContainerRef || this._elementRef;\n }\n\n ngAfterContentInit() {\n this._validateControlChild();\n\n const control = this._control;\n\n if (control.controlType) {\n this._elementRef.nativeElement.classList.add(`mat-form-field-type-${control.controlType}`);\n }\n\n // Subscribe to changes in the child control state in order to update the form field UI.\n control.stateChanges.pipe(startWith(null!)).subscribe(() => {\n this._validatePlaceholders();\n this._syncDescribedByIds();\n this._changeDetectorRef.markForCheck();\n });\n\n // Run change detection if the value changes.\n if (control.ngControl && control.ngControl.valueChanges) {\n control.ngControl.valueChanges\n .pipe(takeUntil(this._destroyed))\n .subscribe(() => this._changeDetectorRef.markForCheck());\n }\n\n // Note that we have to run outside of the `NgZone` explicitly,\n // in order to avoid throwing users into an infinite loop\n // if `zone-patch-rxjs` is included.\n this._ngZone.runOutsideAngular(() => {\n this._ngZone.onStable.asObservable().pipe(takeUntil(this._destroyed)).subscribe(() => {\n if (this._outlineGapCalculationNeededOnStable) {\n this.updateOutlineGap();\n }\n });\n });\n\n // Run change detection and update the outline if the suffix or prefix changes.\n merge(this._prefixChildren.changes, this._suffixChildren.changes).subscribe(() => {\n this._outlineGapCalculationNeededOnStable = true;\n this._changeDetectorRef.markForCheck();\n });\n\n // Re-validate when the number of hints changes.\n this._hintChildren.changes.pipe(startWith(null)).subscribe(() => {\n this._processHints();\n this._changeDetectorRef.markForCheck();\n });\n\n // Update the aria-described by when the number of errors changes.\n this._errorChildren.changes.pipe(startWith(null)).subscribe(() => {\n this._syncDescribedByIds();\n this._changeDetectorRef.markForCheck();\n });\n\n if (this._dir) {\n this._dir.change.pipe(takeUntil(this._destroyed)).subscribe(() => this.updateOutlineGap());\n }\n }\n\n ngAfterContentChecked() {\n this._validateControlChild();\n if (this._outlineGapCalculationNeededImmediately) {\n this.updateOutlineGap();\n }\n }\n\n ngAfterViewInit() {\n // Avoid animations on load.\n this._subscriptAnimationState = 'enter';\n this._changeDetectorRef.detectChanges();\n }\n\n ngOnDestroy() {\n this._destroyed.next();\n this._destroyed.complete();\n }\n\n /** Determines whether a class from the NgControl should be forwarded to the host element. */\n _shouldForward(prop: keyof NgControl): boolean {\n const ngControl = this._control ? this._control.ngControl : null;\n return ngControl && ngControl[prop];\n }\n\n _hasPlaceholder() {\n return !!(this._control && this._control.placeholder || this._placeholderChild);\n }\n\n _hasLabel() {\n return !!this._labelChild;\n }\n\n _shouldLabelFloat() {\n return this._canLabelFloat && (this._control.shouldLabelFloat || this._shouldAlwaysFloat);\n }\n\n _hideControlPlaceholder() {\n // In the legacy appearance the placeholder is promoted to a label if no label is given.\n return this.appearance === 'legacy' && !this._hasLabel() ||\n this._hasLabel() && !this._shouldLabelFloat();\n }\n\n _hasFloatingLabel() {\n // In the legacy appearance the placeholder is promoted to a label if no label is given.\n return this._hasLabel() || this.appearance === 'legacy' && this._hasPlaceholder();\n }\n\n /** Determines whether to display hints or errors. */\n _getDisplayedMessages(): 'error' | 'hint' {\n return (this._errorChildren && this._errorChildren.length > 0 &&\n this._control.errorState) ? 'error' : 'hint';\n }\n\n /** Animates the placeholder up and locks it in position. */\n _animateAndLockLabel(): void {\n if (this._hasFloatingLabel() && this._canLabelFloat) {\n // If animations are disabled, we shouldn't go in here,\n // because the `transitionend` will never fire.\n if (this._animationsEnabled) {\n this._showAlwaysAnimate = true;\n\n fromEvent(this._label.nativeElement, 'transitionend').pipe(take(1)).subscribe(() => {\n this._showAlwaysAnimate = false;\n });\n }\n\n this.floatLabel = 'always';\n this._changeDetectorRef.markForCheck();\n }\n }\n\n /**\n * Ensure that there is only one placeholder (either `placeholder` attribute on the child control\n * or child element with the `mat-placeholder` directive).\n */\n private _validatePlaceholders() {\n if (this._control.placeholder && this._placeholderChild) {\n throw getMatFormFieldPlaceholderConflictError();\n }\n }\n\n /** Does any extra processing that is required when handling the hints. */\n private _processHints() {\n this._validateHints();\n this._syncDescribedByIds();\n }\n\n /**\n * Ensure that there is a maximum of one of each `<mat-hint>` alignment specified, with the\n * attribute being considered as `align=\"start\"`.\n */\n private _validateHints() {\n if (this._hintChildren) {\n let startHint: MatHint;\n let endHint: MatHint;\n this._hintChildren.forEach((hint: MatHint) => {\n if (hint.align === 'start') {\n if (startHint || this.hintLabel) {\n throw getMatFormFieldDuplicatedHintError('start');\n }\n startHint = hint;\n } else if (hint.align === 'end') {\n if (endHint) {\n throw getMatFormFieldDuplicatedHintError('end');\n }\n endHint = hint;\n }\n });\n }\n }\n\n /**\n * Sets the list of element IDs that describe the child control. This allows the control to update\n * its `aria-describedby` attribute accordingly.\n */\n private _syncDescribedByIds() {\n if (this._control) {\n let ids: string[] = [];\n\n if (this._getDisplayedMessages() === 'hint') {\n const startHint = this._hintChildren ?\n this._hintChildren.find(hint => hint.align === 'start') : null;\n const endHint = this._hintChildren ?\n this._hintChildren.find(hint => hint.align === 'end') : null;\n\n if (startHint) {\n ids.push(startHint.id);\n } else if (this._hintLabel) {\n ids.push(this._hintLabelId);\n }\n\n if (endHint) {\n ids.push(endHint.id);\n }\n } else if (this._errorChildren) {\n ids = this._errorChildren.map(error => error.id);\n }\n\n this._control.setDescribedByIds(ids);\n }\n }\n\n /** Throws an error if the form field's control is missing. */\n protected _validateControlChild() {\n if (!this._control) {\n throw getMatFormFieldMissingControlError();\n }\n }\n\n /**\n * Updates the width and position of the gap in the outline. Only relevant for the outline\n * appearance.\n */\n updateOutlineGap() {\n const labelEl = this._label ? this._label.nativeElement : null;\n\n if (this.appearance !== 'outline' || !labelEl || !labelEl.children.length ||\n !labelEl.textContent.trim()) {\n return;\n }\n\n if (!this._platform.isBrowser) {\n // getBoundingClientRect isn't available on the server.\n return;\n }\n // If the element is not present in the DOM, the outline gap will need to be calculated\n // the next time it is checked and in the DOM.\n if (!document.documentElement!.contains(this._elementRef.nativeElement)) {\n this._outlineGapCalculationNeededImmediately = true;\n return;\n }\n\n let startWidth = 0;\n let gapWidth = 0;\n\n const container = this._connectionContainerRef.nativeElement;\n const startEls = container.querySelectorAll('.mat-form-field-outline-start');\n const gapEls = container.querySelectorAll('.mat-form-field-outline-gap');\n\n if (this._label && this._label.nativeElement.children.length) {\n const containerRect = container.getBoundingClientRect();\n\n // If the container's width and height are zero, it means that the element is\n // invisible and we can't calculate the outline gap. Mark the element as needing\n // to be checked the next time the zone stabilizes. We can't do this immediately\n // on the next change detection, because even if the element becomes visible,\n // the `ClientRect` won't be reclaculated immediately. We reset the\n // `_outlineGapCalculationNeededImmediately` flag some we don't run the checks twice.\n if (containerRect.width === 0 && containerRect.height === 0) {\n this._outlineGapCalculationNeededOnStable = true;\n this._outlineGapCalculationNeededImmediately = false;\n return;\n }\n\n const containerStart = this._getStartEnd(containerRect);\n const labelStart = this._getStartEnd(labelEl.children[0].getBoundingClientRect());\n let labelWidth = 0;\n\n for (const child of labelEl.children) {\n labelWidth += child.offsetWidth;\n }\n startWidth = labelStart - containerStart - outlineGapPadding;\n gapWidth = labelWidth > 0 ? labelWidth * floatingLabelScale + outlineGapPadding * 2 : 0;\n }\n\n for (let i = 0; i < startEls.length; i++) {\n startEls.item(i).style.width = `${startWidth}px`;\n }\n for (let i = 0; i < gapEls.length; i++) {\n gapEls.item(i).style.width = `${gapWidth}px`;\n }\n\n this._outlineGapCalculationNeededOnStable =\n this._outlineGapCalculationNeededImmediately = false;\n }\n\n /** Gets the start end of the rect considering the current directionality. */\n private _getStartEnd(rect: ClientRect): number {\n return this._dir && this._dir.value === 'rtl' ? rect.right : rect.left;\n }\n}\n","/**\n * @license\n * Copyright Google LLC 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 */\n\nimport {CommonModule} from '@angular/common';\nimport {NgModule} from '@angular/core';\nimport {ObserversModule} from '@angular/cdk/observers';\nimport {MatError} from './error';\nimport {MatFormField} from './form-field';\nimport {MatHint} from './hint';\nimport {MatLabel} from './label';\nimport {MatPlaceholder} from './placeholder';\nimport {MatPrefix} from './prefix';\nimport {MatSuffix} from './suffix';\n\n\n@NgModule({\n declarations: [\n MatError,\n MatFormField,\n MatHint,\n MatLabel,\n MatPlaceholder,\n MatPrefix,\n MatSuffix,\n ],\n imports: [\n CommonModule,\n ObserversModule,\n ],\n exports: [\n MatError,\n MatFormField,\n MatHint,\n MatLabel,\n MatPlaceholder,\n MatPrefix,\n MatSuffix,\n ],\n})\nexport class MatFormFieldModule {}\n"],"names":["__extends","d","b","__","this","constructor","extendStatics","prototype","Object","create","getMatFormFieldPlaceholderConflictError","Error","getMatFormFieldDuplicatedHintError","align","getMatFormFieldMissingControlError","setPrototypeOf","__proto__","Array","p","hasOwnProperty","nextUniqueId","MatError","id","type","Directive","args","selector","host","class","role","[attr.id]","Input","matFormFieldAnimations","transitionMessages","trigger","state","style","opacity","transform","transition","animate","MatFormFieldControl","MatHint","[class.mat-right]","[attr.align]","MatLabel","MatPlaceholder","MatPrefix","MatSuffix","MatFormFieldBase","_elementRef","_MatFormFieldMixinBase","mixinColor","MAT_FORM_FIELD_DEFAULT_OPTIONS","InjectionToken","MatFormField","_super","_changeDetectorRef","labelOptions","_dir","_defaults","_platform","_ngZone","_animationMode","_this","call","_outlineGapCalculationNeededImmediately","_outlineGapCalculationNeededOnStable","_destroyed","Subject","_showAlwaysAnimate","_subscriptAnimationState","_hintLabel","_hintLabelId","_labelId","_labelOptions","floatLabel","float","_animationsEnabled","appearance","tslib_1.__extends","defineProperty","_appearance","value","oldValue","_hideRequiredMarker","coerceBooleanProperty","_processHints","_floatLabel","markForCheck","_explicitFormFieldControl","_controlNonStatic","_controlStatic","_labelChildNonStatic","_labelChildStatic","getConnectedOverlayOrigin","_connectionContainerRef","ngAfterContentInit","_validateControlChild","control","_control","controlType","nativeElement","classList","add","stateChanges","pipe","startWith","subscribe","_validatePlaceholders","_syncDescribedByIds","ngControl","valueChanges","takeUntil","runOutsideAngular","onStable","asObservable","updateOutlineGap","merge","_prefixChildren","changes","_suffixChildren","_hintChildren","_errorChildren","change","ngAfterContentChecked","ngAfterViewInit","detectChanges","ngOnDestroy","next","complete","_shouldForward","prop","_hasPlaceholder","placeholder","_placeholderChild","_hasLabel","_labelChild","_shouldLabelFloat","_canLabelFloat","shouldLabelFloat","_shouldAlwaysFloat","_hideControlPlaceholder","_hasFloatingLabel","_getDisplayedMessages","length","errorState","_animateAndLockLabel","fromEvent","_label","take","_validateHints","startHint_1","endHint_1","forEach","hint","hintLabel","ids","startHint","find","endHint","push","map","error","setDescribedByIds","labelEl","children","textContent","trim","isBrowser","document","contains","startWidth","gapWidth","container","startEls","querySelectorAll","gapEls","containerRect","getBoundingClientRect","width","height","containerStart","_getStartEnd","labelStart","labelWidth","_i","_a","offsetWidth","outlineGapPadding","i","item","rect","right","left","Component","exportAs","template","[class.mat-form-field-appearance-standard]","[class.mat-form-field-appearance-fill]","[class.mat-form-field-appearance-outline]","[class.mat-form-field-appearance-legacy]","[class.mat-form-field-invalid]","[class.mat-form-field-can-float]","[class.mat-form-field-should-float]","[class.mat-form-field-has-label]","[class.mat-form-field-hide-placeholder]","[class.mat-form-field-disabled]","[class.mat-form-field-autofilled]","[class.mat-focused]","[class.mat-accent]","[class.mat-warn]","[class.ng-untouched]","[class.ng-touched]","[class.ng-pristine]","[class.ng-dirty]","[class.ng-valid]","[class.ng-invalid]","[class.ng-pending]","[class._mat-animation-noopable]","inputs","encapsulation","ViewEncapsulation","None","changeDetection","ChangeDetectionStrategy","OnPush","ctorParameters","ElementRef","ChangeDetectorRef","undefined","decorators","Optional","Inject","MAT_LABEL_GLOBAL_OPTIONS","Directionality","Platform","propDecorators","hideRequiredMarker","underlineRef","ViewChild","static","_inputContainerRef","ContentChild","ContentChildren","MatFormFieldModule","NgModule","declarations","imports","CommonModule","ObserversModule","exports"],"mappings":";;;;;;;+hCAuBA,SAAgBA,GAAUC,EAAGC,GAEzB,QAASC,KAAOC,KAAKC,YAAcJ,EADnCK,EAAcL,EAAGC,GAEjBD,EAAEM,UAAkB,OAANL,EAAaM,OAAOC,OAAOP,IAAMC,EAAGI,UAAYL,EAAEK,UAAW,GAAIJ,ICjBnF,QAAgBO,KACd,MAAOC,OAAM,gEAIf,QAAgBC,GAAmCC,GACjD,MAAOF,OAAM,4CAA2CE,EAA1D,QAIA,QAAgBC,KACd,MAAOH,OAAM,sDD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