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mono-repo/./node_modules/@material/floating-label/foundation.js","webpack://mono-repo/./node_modules/@material/form-field/foundation.js","webpack://mono-repo/./node_modules/@material/line-ripple/foundation.js","webpack://mono-repo/./node_modules/@material/list/foundation.js","webpack://mono-repo/./node_modules/@material/menu-surface/foundation.js","webpack://mono-repo/./node_modules/@material/menu/foundation.js","webpack://mono-repo/./node_modules/@material/notched-outline/foundation.js","webpack://mono-repo/./node_modules/@material/ripple/foundation.js","webpack://mono-repo/./node_modules/@material/tab-bar/foundation.js","webpack://mono-repo/./node_modules/@material/tab-indicator/foundation.js","webpack://mono-repo/./node_modules/@material/tab-scroller/foundation.js","webpack://mono-repo/./node_modules/@material/tab/foundation.js","webpack://mono-repo/./node_modules/@material/textfield/character-counter/foundation.js","webpack://mono-repo/./node_modules/@material/textfield/foundation.js","webpack://mono-repo/./node_modules/@material/textfield/helper-text/foundation.js","webpack://mono-repo/./node_modules/@material/textfield/icon/foundation.js"],"sourcesContent":["/**\n * @license\n * Copyright 2016 Google Inc.\n *\n * Permission is hereby granted, free of charge, to any person obtaining a copy\n * of this software and associated documentation files (the \"Software\"), to deal\n * in the Software without restriction, including without limitation the rights\n * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell\n * copies of the Software, and to permit persons to whom the Software is\n * furnished to do so, subject to the following conditions:\n *\n * The above copyright notice and this permission notice shall be included in\n * all copies or substantial portions of the Software.\n *\n * THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\n * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\n * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\n * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\n * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\n * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN\n * THE SOFTWARE.\n */\nimport * as tslib_1 from \"tslib\";\nimport { MDCFoundation } from '@material/base/foundation';\nimport { cssClasses, numbers, strings } from './constants';\nvar MDCCheckboxFoundation = /** @class */ (function (_super) {\n tslib_1.__extends(MDCCheckboxFoundation, _super);\n function MDCCheckboxFoundation(adapter) {\n var _this = _super.call(this, tslib_1.__assign({}, MDCCheckboxFoundation.defaultAdapter, adapter)) || this;\n _this.currentCheckState_ = strings.TRANSITION_STATE_INIT;\n _this.currentAnimationClass_ = '';\n _this.animEndLatchTimer_ = 0;\n _this.enableAnimationEndHandler_ = false;\n return _this;\n }\n Object.defineProperty(MDCCheckboxFoundation, \"cssClasses\", {\n get: function () {\n return cssClasses;\n },\n enumerable: true,\n configurable: true\n });\n Object.defineProperty(MDCCheckboxFoundation, \"strings\", {\n get: function () {\n return strings;\n },\n enumerable: true,\n configurable: true\n });\n Object.defineProperty(MDCCheckboxFoundation, \"numbers\", {\n get: function () {\n return numbers;\n },\n enumerable: true,\n configurable: true\n });\n Object.defineProperty(MDCCheckboxFoundation, \"defaultAdapter\", {\n get: function () {\n return {\n addClass: function () { return undefined; },\n forceLayout: function () { return undefined; },\n hasNativeControl: function () { return false; },\n isAttachedToDOM: function () { return false; },\n isChecked: function () { return false; },\n isIndeterminate: function () { return false; },\n removeClass: function () { return undefined; },\n removeNativeControlAttr: function () { return undefined; },\n setNativeControlAttr: function () { return undefined; },\n setNativeControlDisabled: function () { return undefined; },\n };\n },\n enumerable: true,\n configurable: true\n });\n MDCCheckboxFoundation.prototype.init = function () {\n this.currentCheckState_ = this.determineCheckState_();\n this.updateAriaChecked_();\n this.adapter_.addClass(cssClasses.UPGRADED);\n };\n MDCCheckboxFoundation.prototype.destroy = function () {\n clearTimeout(this.animEndLatchTimer_);\n };\n MDCCheckboxFoundation.prototype.setDisabled = function (disabled) {\n this.adapter_.setNativeControlDisabled(disabled);\n if (disabled) {\n this.adapter_.addClass(cssClasses.DISABLED);\n }\n else {\n this.adapter_.removeClass(cssClasses.DISABLED);\n }\n };\n /**\n * Handles the animationend event for the checkbox\n */\n MDCCheckboxFoundation.prototype.handleAnimationEnd = function () {\n var _this = this;\n if (!this.enableAnimationEndHandler_) {\n return;\n }\n clearTimeout(this.animEndLatchTimer_);\n this.animEndLatchTimer_ = setTimeout(function () {\n _this.adapter_.removeClass(_this.currentAnimationClass_);\n _this.enableAnimationEndHandler_ = false;\n }, numbers.ANIM_END_LATCH_MS);\n };\n /**\n * Handles the change event for the checkbox\n */\n MDCCheckboxFoundation.prototype.handleChange = function () {\n this.transitionCheckState_();\n };\n MDCCheckboxFoundation.prototype.transitionCheckState_ = function () {\n if (!this.adapter_.hasNativeControl()) {\n return;\n }\n var oldState = this.currentCheckState_;\n var newState = this.determineCheckState_();\n if (oldState === newState) {\n return;\n }\n this.updateAriaChecked_();\n var TRANSITION_STATE_UNCHECKED = strings.TRANSITION_STATE_UNCHECKED;\n var SELECTED = cssClasses.SELECTED;\n if (newState === TRANSITION_STATE_UNCHECKED) {\n this.adapter_.removeClass(SELECTED);\n }\n else {\n this.adapter_.addClass(SELECTED);\n }\n // Check to ensure that there isn't a previously existing animation class, in case for example\n // the user interacted with the checkbox before the animation was finished.\n if (this.currentAnimationClass_.length > 0) {\n clearTimeout(this.animEndLatchTimer_);\n this.adapter_.forceLayout();\n this.adapter_.removeClass(this.currentAnimationClass_);\n }\n this.currentAnimationClass_ = this.getTransitionAnimationClass_(oldState, newState);\n this.currentCheckState_ = newState;\n // Check for parentNode so that animations are only run when the element is attached\n // to the DOM.\n if (this.adapter_.isAttachedToDOM() && this.currentAnimationClass_.length > 0) {\n this.adapter_.addClass(this.currentAnimationClass_);\n this.enableAnimationEndHandler_ = true;\n }\n };\n MDCCheckboxFoundation.prototype.determineCheckState_ = function () {\n var TRANSITION_STATE_INDETERMINATE = strings.TRANSITION_STATE_INDETERMINATE, TRANSITION_STATE_CHECKED = strings.TRANSITION_STATE_CHECKED, TRANSITION_STATE_UNCHECKED = strings.TRANSITION_STATE_UNCHECKED;\n if (this.adapter_.isIndeterminate()) {\n return TRANSITION_STATE_INDETERMINATE;\n }\n return this.adapter_.isChecked() ? TRANSITION_STATE_CHECKED : TRANSITION_STATE_UNCHECKED;\n };\n MDCCheckboxFoundation.prototype.getTransitionAnimationClass_ = function (oldState, newState) {\n var TRANSITION_STATE_INIT = strings.TRANSITION_STATE_INIT, TRANSITION_STATE_CHECKED = strings.TRANSITION_STATE_CHECKED, TRANSITION_STATE_UNCHECKED = strings.TRANSITION_STATE_UNCHECKED;\n var _a = MDCCheckboxFoundation.cssClasses, ANIM_UNCHECKED_CHECKED = _a.ANIM_UNCHECKED_CHECKED, ANIM_UNCHECKED_INDETERMINATE = _a.ANIM_UNCHECKED_INDETERMINATE, ANIM_CHECKED_UNCHECKED = _a.ANIM_CHECKED_UNCHECKED, ANIM_CHECKED_INDETERMINATE = _a.ANIM_CHECKED_INDETERMINATE, ANIM_INDETERMINATE_CHECKED = _a.ANIM_INDETERMINATE_CHECKED, ANIM_INDETERMINATE_UNCHECKED = _a.ANIM_INDETERMINATE_UNCHECKED;\n switch (oldState) {\n case TRANSITION_STATE_INIT:\n if (newState === TRANSITION_STATE_UNCHECKED) {\n return '';\n }\n return newState === TRANSITION_STATE_CHECKED ? ANIM_INDETERMINATE_CHECKED : ANIM_INDETERMINATE_UNCHECKED;\n case TRANSITION_STATE_UNCHECKED:\n return newState === TRANSITION_STATE_CHECKED ? ANIM_UNCHECKED_CHECKED : ANIM_UNCHECKED_INDETERMINATE;\n case TRANSITION_STATE_CHECKED:\n return newState === TRANSITION_STATE_UNCHECKED ? ANIM_CHECKED_UNCHECKED : ANIM_CHECKED_INDETERMINATE;\n default: // TRANSITION_STATE_INDETERMINATE\n return newState === TRANSITION_STATE_CHECKED ? ANIM_INDETERMINATE_CHECKED : ANIM_INDETERMINATE_UNCHECKED;\n }\n };\n MDCCheckboxFoundation.prototype.updateAriaChecked_ = function () {\n // Ensure aria-checked is set to mixed if checkbox is in indeterminate state.\n if (this.adapter_.isIndeterminate()) {\n this.adapter_.setNativeControlAttr(strings.ARIA_CHECKED_ATTR, strings.ARIA_CHECKED_INDETERMINATE_VALUE);\n }\n else {\n // The on/off state does not need to keep track of aria-checked, since\n // the screenreader uses the checked property on the checkbox element.\n this.adapter_.removeNativeControlAttr(strings.ARIA_CHECKED_ATTR);\n }\n };\n return MDCCheckboxFoundation;\n}(MDCFoundation));\nexport { MDCCheckboxFoundation };\n// tslint:disable-next-line:no-default-export Needed for backward compatibility with MDC Web v0.44.0 and earlier.\nexport default MDCCheckboxFoundation;\n//# sourceMappingURL=foundation.js.map","/**\n * @license\n * Copyright 2016 Google Inc.\n *\n * Permission is hereby granted, free of charge, to any person obtaining a copy\n * of this software and associated documentation files (the \"Software\"), to deal\n * in the Software without restriction, including without limitation the rights\n * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell\n * copies of the Software, and to permit persons to whom the Software is\n * furnished to do so, subject to the following conditions:\n *\n * The above copyright notice and this permission notice shall be included in\n * all copies or substantial portions of the Software.\n *\n * THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\n * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\n * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\n * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\n * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\n * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN\n * THE SOFTWARE.\n */\nimport * as tslib_1 from \"tslib\";\nimport { MDCFoundation } from '@material/base/foundation';\nimport { cssClasses } from './constants';\nvar MDCFloatingLabelFoundation = /** @class */ (function (_super) {\n tslib_1.__extends(MDCFloatingLabelFoundation, _super);\n function MDCFloatingLabelFoundation(adapter) {\n var _this = _super.call(this, tslib_1.__assign({}, MDCFloatingLabelFoundation.defaultAdapter, adapter)) || this;\n _this.shakeAnimationEndHandler_ = function () { return _this.handleShakeAnimationEnd_(); };\n return _this;\n }\n Object.defineProperty(MDCFloatingLabelFoundation, \"cssClasses\", {\n get: function () {\n return cssClasses;\n },\n enumerable: true,\n configurable: true\n });\n Object.defineProperty(MDCFloatingLabelFoundation, \"defaultAdapter\", {\n /**\n * See {@link MDCFloatingLabelAdapter} for typing information on parameters and return types.\n */\n get: function () {\n // tslint:disable:object-literal-sort-keys Methods should be in the same order as the adapter interface.\n return {\n addClass: function () { return undefined; },\n removeClass: function () { return undefined; },\n getWidth: function () { return 0; },\n registerInteractionHandler: function () { return undefined; },\n deregisterInteractionHandler: function () { return undefined; },\n };\n // tslint:enable:object-literal-sort-keys\n },\n enumerable: true,\n configurable: true\n });\n MDCFloatingLabelFoundation.prototype.init = function () {\n this.adapter_.registerInteractionHandler('animationend', this.shakeAnimationEndHandler_);\n };\n MDCFloatingLabelFoundation.prototype.destroy = function () {\n this.adapter_.deregisterInteractionHandler('animationend', this.shakeAnimationEndHandler_);\n };\n /**\n * Returns the width of the label element.\n */\n MDCFloatingLabelFoundation.prototype.getWidth = function () {\n return this.adapter_.getWidth();\n };\n /**\n * Styles the label to produce a shake animation to indicate an error.\n * @param shouldShake If true, adds the shake CSS class; otherwise, removes shake class.\n */\n MDCFloatingLabelFoundation.prototype.shake = function (shouldShake) {\n var LABEL_SHAKE = MDCFloatingLabelFoundation.cssClasses.LABEL_SHAKE;\n if (shouldShake) {\n this.adapter_.addClass(LABEL_SHAKE);\n }\n else {\n this.adapter_.removeClass(LABEL_SHAKE);\n }\n };\n /**\n * Styles the label to float or dock.\n * @param shouldFloat If true, adds the float CSS class; otherwise, removes float and shake classes to dock the label.\n */\n MDCFloatingLabelFoundation.prototype.float = function (shouldFloat) {\n var _a = MDCFloatingLabelFoundation.cssClasses, LABEL_FLOAT_ABOVE = _a.LABEL_FLOAT_ABOVE, LABEL_SHAKE = _a.LABEL_SHAKE;\n if (shouldFloat) {\n this.adapter_.addClass(LABEL_FLOAT_ABOVE);\n }\n else {\n this.adapter_.removeClass(LABEL_FLOAT_ABOVE);\n this.adapter_.removeClass(LABEL_SHAKE);\n }\n };\n MDCFloatingLabelFoundation.prototype.handleShakeAnimationEnd_ = function () {\n var LABEL_SHAKE = MDCFloatingLabelFoundation.cssClasses.LABEL_SHAKE;\n this.adapter_.removeClass(LABEL_SHAKE);\n };\n return MDCFloatingLabelFoundation;\n}(MDCFoundation));\nexport { MDCFloatingLabelFoundation };\n// tslint:disable-next-line:no-default-export Needed for backward compatibility with MDC Web v0.44.0 and earlier.\nexport default MDCFloatingLabelFoundation;\n//# sourceMappingURL=foundation.js.map","/**\n * @license\n * Copyright 2017 Google Inc.\n *\n * Permission is hereby granted, free of charge, to any person obtaining a copy\n * of this software and associated documentation files (the \"Software\"), to deal\n * in the Software without restriction, including without limitation the rights\n * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell\n * copies of the Software, and to permit persons to whom the Software is\n * furnished to do so, subject to the following conditions:\n *\n * The above copyright notice and this permission notice shall be included in\n * all copies or substantial portions of the Software.\n *\n * THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\n * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\n * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\n * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\n * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\n * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN\n * THE SOFTWARE.\n */\nimport * as tslib_1 from \"tslib\";\nimport { MDCFoundation } from '@material/base/foundation';\nimport { cssClasses, strings } from './constants';\nvar MDCFormFieldFoundation = /** @class */ (function (_super) {\n tslib_1.__extends(MDCFormFieldFoundation, _super);\n function MDCFormFieldFoundation(adapter) {\n var _this = _super.call(this, tslib_1.__assign({}, MDCFormFieldFoundation.defaultAdapter, adapter)) || this;\n _this.clickHandler_ = function () { return _this.handleClick_(); };\n return _this;\n }\n Object.defineProperty(MDCFormFieldFoundation, \"cssClasses\", {\n get: function () {\n return cssClasses;\n },\n enumerable: true,\n configurable: true\n });\n Object.defineProperty(MDCFormFieldFoundation, \"strings\", {\n get: function () {\n return strings;\n },\n enumerable: true,\n configurable: true\n });\n Object.defineProperty(MDCFormFieldFoundation, \"defaultAdapter\", {\n get: function () {\n return {\n activateInputRipple: function () { return undefined; },\n deactivateInputRipple: function () { return undefined; },\n deregisterInteractionHandler: function () { return undefined; },\n registerInteractionHandler: function () { return undefined; },\n };\n },\n enumerable: true,\n configurable: true\n });\n MDCFormFieldFoundation.prototype.init = function () {\n this.adapter_.registerInteractionHandler('click', this.clickHandler_);\n };\n MDCFormFieldFoundation.prototype.destroy = function () {\n this.adapter_.deregisterInteractionHandler('click', this.clickHandler_);\n };\n MDCFormFieldFoundation.prototype.handleClick_ = function () {\n var _this = this;\n this.adapter_.activateInputRipple();\n requestAnimationFrame(function () { return _this.adapter_.deactivateInputRipple(); });\n };\n return MDCFormFieldFoundation;\n}(MDCFoundation));\nexport { MDCFormFieldFoundation };\n// tslint:disable-next-line:no-default-export Needed for backward compatibility with MDC Web v0.44.0 and earlier.\nexport default MDCFormFieldFoundation;\n//# sourceMappingURL=foundation.js.map","/**\n * @license\n * Copyright 2018 Google Inc.\n *\n * Permission is hereby granted, free of charge, to any person obtaining a copy\n * of this software and associated documentation files (the \"Software\"), to deal\n * in the Software without restriction, including without limitation the rights\n * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell\n * copies of the Software, and to permit persons to whom the Software is\n * furnished to do so, subject to the following conditions:\n *\n * The above copyright notice and this permission notice shall be included in\n * all copies or substantial portions of the Software.\n *\n * THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\n * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\n * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\n * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\n * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\n * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN\n * THE SOFTWARE.\n */\nimport * as tslib_1 from \"tslib\";\nimport { MDCFoundation } from '@material/base/foundation';\nimport { cssClasses } from './constants';\nvar MDCLineRippleFoundation = /** @class */ (function (_super) {\n tslib_1.__extends(MDCLineRippleFoundation, _super);\n function MDCLineRippleFoundation(adapter) {\n var _this = _super.call(this, tslib_1.__assign({}, MDCLineRippleFoundation.defaultAdapter, adapter)) || this;\n _this.transitionEndHandler_ = function (evt) { return _this.handleTransitionEnd(evt); };\n return _this;\n }\n Object.defineProperty(MDCLineRippleFoundation, \"cssClasses\", {\n get: function () {\n return cssClasses;\n },\n enumerable: true,\n configurable: true\n });\n Object.defineProperty(MDCLineRippleFoundation, \"defaultAdapter\", {\n /**\n * See {@link MDCLineRippleAdapter} for typing information on parameters and return types.\n */\n get: function () {\n // tslint:disable:object-literal-sort-keys Methods should be in the same order as the adapter interface.\n return {\n addClass: function () { return undefined; },\n removeClass: function () { return undefined; },\n hasClass: function () { return false; },\n setStyle: function () { return undefined; },\n registerEventHandler: function () { return undefined; },\n deregisterEventHandler: function () { return undefined; },\n };\n // tslint:enable:object-literal-sort-keys\n },\n enumerable: true,\n configurable: true\n });\n MDCLineRippleFoundation.prototype.init = function () {\n this.adapter_.registerEventHandler('transitionend', this.transitionEndHandler_);\n };\n MDCLineRippleFoundation.prototype.destroy = function () {\n this.adapter_.deregisterEventHandler('transitionend', this.transitionEndHandler_);\n };\n MDCLineRippleFoundation.prototype.activate = function () {\n this.adapter_.removeClass(cssClasses.LINE_RIPPLE_DEACTIVATING);\n this.adapter_.addClass(cssClasses.LINE_RIPPLE_ACTIVE);\n };\n MDCLineRippleFoundation.prototype.setRippleCenter = function (xCoordinate) {\n this.adapter_.setStyle('transform-origin', xCoordinate + \"px center\");\n };\n MDCLineRippleFoundation.prototype.deactivate = function () {\n this.adapter_.addClass(cssClasses.LINE_RIPPLE_DEACTIVATING);\n };\n MDCLineRippleFoundation.prototype.handleTransitionEnd = function (evt) {\n // Wait for the line ripple to be either transparent or opaque\n // before emitting the animation end event\n var isDeactivating = this.adapter_.hasClass(cssClasses.LINE_RIPPLE_DEACTIVATING);\n if (evt.propertyName === 'opacity') {\n if (isDeactivating) {\n this.adapter_.removeClass(cssClasses.LINE_RIPPLE_ACTIVE);\n this.adapter_.removeClass(cssClasses.LINE_RIPPLE_DEACTIVATING);\n }\n }\n };\n return MDCLineRippleFoundation;\n}(MDCFoundation));\nexport { MDCLineRippleFoundation };\n// tslint:disable-next-line:no-default-export Needed for backward compatibility with MDC Web v0.44.0 and earlier.\nexport default MDCLineRippleFoundation;\n//# sourceMappingURL=foundation.js.map","/**\n * @license\n * Copyright 2018 Google Inc.\n *\n * Permission is hereby granted, free of charge, to any person obtaining a copy\n * of this software and associated documentation files (the \"Software\"), to deal\n * in the Software without restriction, including without limitation the rights\n * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell\n * copies of the Software, and to permit persons to whom the Software is\n * furnished to do so, subject to the following conditions:\n *\n * The above copyright notice and this permission notice shall be included in\n * all copies or substantial portions of the Software.\n *\n * THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\n * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\n * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\n * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\n * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\n * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN\n * THE SOFTWARE.\n */\nimport * as tslib_1 from \"tslib\";\nimport { MDCFoundation } from '@material/base/foundation';\nimport { cssClasses, numbers, strings } from './constants';\nvar ELEMENTS_KEY_ALLOWED_IN = ['input', 'button', 'textarea', 'select'];\nfunction isNumberArray(selectedIndex) {\n return selectedIndex instanceof Array;\n}\nvar MDCListFoundation = /** @class */ (function (_super) {\n tslib_1.__extends(MDCListFoundation, _super);\n function MDCListFoundation(adapter) {\n var _this = _super.call(this, tslib_1.__assign({}, MDCListFoundation.defaultAdapter, adapter)) || this;\n _this.wrapFocus_ = false;\n _this.isVertical_ = true;\n _this.isSingleSelectionList_ = false;\n _this.selectedIndex_ = numbers.UNSET_INDEX;\n _this.focusedItemIndex_ = numbers.UNSET_INDEX;\n _this.useActivatedClass_ = false;\n _this.ariaCurrentAttrValue_ = null;\n _this.isCheckboxList_ = false;\n _this.isRadioList_ = false;\n return _this;\n }\n Object.defineProperty(MDCListFoundation, \"strings\", {\n get: function () {\n return strings;\n },\n enumerable: true,\n configurable: true\n });\n Object.defineProperty(MDCListFoundation, \"cssClasses\", {\n get: function () {\n return cssClasses;\n },\n enumerable: true,\n configurable: true\n });\n Object.defineProperty(MDCListFoundation, \"numbers\", {\n get: function () {\n return numbers;\n },\n enumerable: true,\n configurable: true\n });\n Object.defineProperty(MDCListFoundation, \"defaultAdapter\", {\n get: function () {\n return {\n addClassForElementIndex: function () { return undefined; },\n focusItemAtIndex: function () { return undefined; },\n getAttributeForElementIndex: function () { return null; },\n getFocusedElementIndex: function () { return 0; },\n getListItemCount: function () { return 0; },\n hasCheckboxAtIndex: function () { return false; },\n hasRadioAtIndex: function () { return false; },\n isCheckboxCheckedAtIndex: function () { return false; },\n isFocusInsideList: function () { return false; },\n isRootFocused: function () { return false; },\n notifyAction: function () { return undefined; },\n removeClassForElementIndex: function () { return undefined; },\n setAttributeForElementIndex: function () { return undefined; },\n setCheckedCheckboxOrRadioAtIndex: function () { return undefined; },\n setTabIndexForListItemChildren: function () { return undefined; },\n };\n },\n enumerable: true,\n configurable: true\n });\n MDCListFoundation.prototype.layout = function () {\n if (this.adapter_.getListItemCount() === 0) {\n return;\n }\n if (this.adapter_.hasCheckboxAtIndex(0)) {\n this.isCheckboxList_ = true;\n }\n else if (this.adapter_.hasRadioAtIndex(0)) {\n this.isRadioList_ = true;\n }\n };\n /**\n * Sets the private wrapFocus_ variable.\n */\n MDCListFoundation.prototype.setWrapFocus = function (value) {\n this.wrapFocus_ = value;\n };\n /**\n * Sets the isVertical_ private variable.\n */\n MDCListFoundation.prototype.setVerticalOrientation = function (value) {\n this.isVertical_ = value;\n };\n /**\n * Sets the isSingleSelectionList_ private variable.\n */\n MDCListFoundation.prototype.setSingleSelection = function (value) {\n this.isSingleSelectionList_ = value;\n };\n /**\n * Sets the useActivatedClass_ private variable.\n */\n MDCListFoundation.prototype.setUseActivatedClass = function (useActivated) {\n this.useActivatedClass_ = useActivated;\n };\n MDCListFoundation.prototype.getSelectedIndex = function () {\n return this.selectedIndex_;\n };\n MDCListFoundation.prototype.setSelectedIndex = function (index) {\n if (!this.isIndexValid_(index)) {\n return;\n }\n if (this.isCheckboxList_) {\n this.setCheckboxAtIndex_(index);\n }\n else if (this.isRadioList_) {\n this.setRadioAtIndex_(index);\n }\n else {\n this.setSingleSelectionAtIndex_(index);\n }\n };\n /**\n * Focus in handler for the list items.\n */\n MDCListFoundation.prototype.handleFocusIn = function (_, listItemIndex) {\n if (listItemIndex >= 0) {\n this.adapter_.setTabIndexForListItemChildren(listItemIndex, '0');\n }\n };\n /**\n * Focus out handler for the list items.\n */\n MDCListFoundation.prototype.handleFocusOut = function (_, listItemIndex) {\n var _this = this;\n if (listItemIndex >= 0) {\n this.adapter_.setTabIndexForListItemChildren(listItemIndex, '-1');\n }\n /**\n * Between Focusout & Focusin some browsers do not have focus on any element. Setting a delay to wait till the focus\n * is moved to next element.\n */\n setTimeout(function () {\n if (!_this.adapter_.isFocusInsideList()) {\n _this.setTabindexToFirstSelectedItem_();\n }\n }, 0);\n };\n /**\n * Key handler for the list.\n */\n MDCListFoundation.prototype.handleKeydown = function (evt, isRootListItem, listItemIndex) {\n var isArrowLeft = evt.key === 'ArrowLeft' || evt.keyCode === 37;\n var isArrowUp = evt.key === 'ArrowUp' || evt.keyCode === 38;\n var isArrowRight = evt.key === 'ArrowRight' || evt.keyCode === 39;\n var isArrowDown = evt.key === 'ArrowDown' || evt.keyCode === 40;\n var isHome = evt.key === 'Home' || evt.keyCode === 36;\n var isEnd = evt.key === 'End' || evt.keyCode === 35;\n var isEnter = evt.key === 'Enter' || evt.keyCode === 13;\n var isSpace = evt.key === 'Space' || evt.keyCode === 32;\n if (this.adapter_.isRootFocused()) {\n if (isArrowUp || isEnd) {\n evt.preventDefault();\n this.focusLastElement();\n }\n else if (isArrowDown || isHome) {\n evt.preventDefault();\n this.focusFirstElement();\n }\n return;\n }\n var currentIndex = this.adapter_.getFocusedElementIndex();\n if (currentIndex === -1) {\n currentIndex = listItemIndex;\n if (currentIndex < 0) {\n // If this event doesn't have a mdc-list-item ancestor from the\n // current list (not from a sublist), return early.\n return;\n }\n }\n var nextIndex;\n if ((this.isVertical_ && isArrowDown) || (!this.isVertical_ && isArrowRight)) {\n this.preventDefaultEvent_(evt);\n nextIndex = this.focusNextElement(currentIndex);\n }\n else if ((this.isVertical_ && isArrowUp) || (!this.isVertical_ && isArrowLeft)) {\n this.preventDefaultEvent_(evt);\n nextIndex = this.focusPrevElement(currentIndex);\n }\n else if (isHome) {\n this.preventDefaultEvent_(evt);\n nextIndex = this.focusFirstElement();\n }\n else if (isEnd) {\n this.preventDefaultEvent_(evt);\n nextIndex = this.focusLastElement();\n }\n else if (isEnter || isSpace) {\n if (isRootListItem) {\n // Return early if enter key is pressed on anchor element which triggers synthetic MouseEvent event.\n var target = evt.target;\n if (target && target.tagName === 'A' && isEnter) {\n return;\n }\n this.preventDefaultEvent_(evt);\n if (this.isSelectableList_()) {\n this.setSelectedIndexOnAction_(currentIndex);\n }\n this.adapter_.notifyAction(currentIndex);\n }\n }\n this.focusedItemIndex_ = currentIndex;\n if (nextIndex !== undefined) {\n this.setTabindexAtIndex_(nextIndex);\n this.focusedItemIndex_ = nextIndex;\n }\n };\n /**\n * Click handler for the list.\n */\n MDCListFoundation.prototype.handleClick = function (index, toggleCheckbox) {\n if (index === numbers.UNSET_INDEX) {\n return;\n }\n if (this.isSelectableList_()) {\n this.setSelectedIndexOnAction_(index, toggleCheckbox);\n }\n this.adapter_.notifyAction(index);\n this.setTabindexAtIndex_(index);\n this.focusedItemIndex_ = index;\n };\n /**\n * Focuses the next element on the list.\n */\n MDCListFoundation.prototype.focusNextElement = function (index) {\n var count = this.adapter_.getListItemCount();\n var nextIndex = index + 1;\n if (nextIndex >= count) {\n if (this.wrapFocus_) {\n nextIndex = 0;\n }\n else {\n // Return early because last item is already focused.\n return index;\n }\n }\n this.adapter_.focusItemAtIndex(nextIndex);\n return nextIndex;\n };\n /**\n * Focuses the previous element on the list.\n */\n MDCListFoundation.prototype.focusPrevElement = function (index) {\n var prevIndex = index - 1;\n if (prevIndex < 0) {\n if (this.wrapFocus_) {\n prevIndex = this.adapter_.getListItemCount() - 1;\n }\n else {\n // Return early because first item is already focused.\n return index;\n }\n }\n this.adapter_.focusItemAtIndex(prevIndex);\n return prevIndex;\n };\n MDCListFoundation.prototype.focusFirstElement = function () {\n this.adapter_.focusItemAtIndex(0);\n return 0;\n };\n MDCListFoundation.prototype.focusLastElement = function () {\n var lastIndex = this.adapter_.getListItemCount() - 1;\n this.adapter_.focusItemAtIndex(lastIndex);\n return lastIndex;\n };\n /**\n * Ensures that preventDefault is only called if the containing element doesn't\n * consume the event, and it will cause an unintended scroll.\n */\n MDCListFoundation.prototype.preventDefaultEvent_ = function (evt) {\n var target = evt.target;\n var tagName = (\"\" + target.tagName).toLowerCase();\n if (ELEMENTS_KEY_ALLOWED_IN.indexOf(tagName) === -1) {\n evt.preventDefault();\n }\n };\n MDCListFoundation.prototype.setSingleSelectionAtIndex_ = function (index) {\n if (this.selectedIndex_ === index) {\n return;\n }\n var selectedClassName = cssClasses.LIST_ITEM_SELECTED_CLASS;\n if (this.useActivatedClass_) {\n selectedClassName = cssClasses.LIST_ITEM_ACTIVATED_CLASS;\n }\n if (this.selectedIndex_ !== numbers.UNSET_INDEX) {\n this.adapter_.removeClassForElementIndex(this.selectedIndex_, selectedClassName);\n }\n this.adapter_.addClassForElementIndex(index, selectedClassName);\n this.setAriaForSingleSelectionAtIndex_(index);\n this.selectedIndex_ = index;\n };\n /**\n * Sets aria attribute for single selection at given index.\n */\n MDCListFoundation.prototype.setAriaForSingleSelectionAtIndex_ = function (index) {\n // Detect the presence of aria-current and get the value only during list initialization when it is in unset state.\n if (this.selectedIndex_ === numbers.UNSET_INDEX) {\n this.ariaCurrentAttrValue_ =\n this.adapter_.getAttributeForElementIndex(index, strings.ARIA_CURRENT);\n }\n var isAriaCurrent = this.ariaCurrentAttrValue_ !== null;\n var ariaAttribute = isAriaCurrent ? strings.ARIA_CURRENT : strings.ARIA_SELECTED;\n if (this.selectedIndex_ !== numbers.UNSET_INDEX) {\n this.adapter_.setAttributeForElementIndex(this.selectedIndex_, ariaAttribute, 'false');\n }\n var ariaAttributeValue = isAriaCurrent ? this.ariaCurrentAttrValue_ : 'true';\n this.adapter_.setAttributeForElementIndex(index, ariaAttribute, ariaAttributeValue);\n };\n /**\n * Toggles radio at give index. Radio doesn't change the checked state if it is already checked.\n */\n MDCListFoundation.prototype.setRadioAtIndex_ = function (index) {\n this.adapter_.setCheckedCheckboxOrRadioAtIndex(index, true);\n if (this.selectedIndex_ !== numbers.UNSET_INDEX) {\n this.adapter_.setAttributeForElementIndex(this.selectedIndex_, strings.ARIA_CHECKED, 'false');\n }\n this.adapter_.setAttributeForElementIndex(index, strings.ARIA_CHECKED, 'true');\n this.selectedIndex_ = index;\n };\n MDCListFoundation.prototype.setCheckboxAtIndex_ = function (index) {\n for (var i = 0; i < this.adapter_.getListItemCount(); i++) {\n var isChecked = false;\n if (index.indexOf(i) >= 0) {\n isChecked = true;\n }\n this.adapter_.setCheckedCheckboxOrRadioAtIndex(i, isChecked);\n this.adapter_.setAttributeForElementIndex(i, strings.ARIA_CHECKED, isChecked ? 'true' : 'false');\n }\n this.selectedIndex_ = index;\n };\n MDCListFoundation.prototype.setTabindexAtIndex_ = function (index) {\n if (this.focusedItemIndex_ === numbers.UNSET_INDEX && index !== 0) {\n // If no list item was selected set first list item's tabindex to -1.\n // Generally, tabindex is set to 0 on first list item of list that has no preselected items.\n this.adapter_.setAttributeForElementIndex(0, 'tabindex', '-1');\n }\n else if (this.focusedItemIndex_ >= 0 && this.focusedItemIndex_ !== index) {\n this.adapter_.setAttributeForElementIndex(this.focusedItemIndex_, 'tabindex', '-1');\n }\n this.adapter_.setAttributeForElementIndex(index, 'tabindex', '0');\n };\n /**\n * @return Return true if it is single selectin list, checkbox list or radio list.\n */\n MDCListFoundation.prototype.isSelectableList_ = function () {\n return this.isSingleSelectionList_ || this.isCheckboxList_ || this.isRadioList_;\n };\n MDCListFoundation.prototype.setTabindexToFirstSelectedItem_ = function () {\n var targetIndex = 0;\n if (this.isSelectableList_()) {\n if (typeof this.selectedIndex_ === 'number' && this.selectedIndex_ !== numbers.UNSET_INDEX) {\n targetIndex = this.selectedIndex_;\n }\n else if (isNumberArray(this.selectedIndex_) && this.selectedIndex_.length > 0) {\n targetIndex = this.selectedIndex_.reduce(function (currentIndex, minIndex) { return Math.min(currentIndex, minIndex); });\n }\n }\n this.setTabindexAtIndex_(targetIndex);\n };\n MDCListFoundation.prototype.isIndexValid_ = function (index) {\n var _this = this;\n if (index instanceof Array) {\n if (!this.isCheckboxList_) {\n throw new Error('MDCListFoundation: Array of index is only supported for checkbox based list');\n }\n if (index.length === 0) {\n return true;\n }\n else {\n return index.some(function (i) { return _this.isIndexInRange_(i); });\n }\n }\n else if (typeof index === 'number') {\n if (this.isCheckboxList_) {\n throw new Error('MDCListFoundation: Expected array of index for checkbox based list but got number: ' + index);\n }\n return this.isIndexInRange_(index);\n }\n else {\n return false;\n }\n };\n MDCListFoundation.prototype.isIndexInRange_ = function (index) {\n var listSize = this.adapter_.getListItemCount();\n return index >= 0 && index < listSize;\n };\n MDCListFoundation.prototype.setSelectedIndexOnAction_ = function (index, toggleCheckbox) {\n if (toggleCheckbox === void 0) { toggleCheckbox = true; }\n if (this.isCheckboxList_) {\n this.toggleCheckboxAtIndex_(index, toggleCheckbox);\n }\n else {\n this.setSelectedIndex(index);\n }\n };\n MDCListFoundation.prototype.toggleCheckboxAtIndex_ = function (index, toggleCheckbox) {\n var isChecked = this.adapter_.isCheckboxCheckedAtIndex(index);\n if (toggleCheckbox) {\n isChecked = !isChecked;\n this.adapter_.setCheckedCheckboxOrRadioAtIndex(index, isChecked);\n }\n this.adapter_.setAttributeForElementIndex(index, strings.ARIA_CHECKED, isChecked ? 'true' : 'false');\n // If none of the checkbox items are selected and selectedIndex is not initialized then provide a default value.\n var selectedIndexes = this.selectedIndex_ === numbers.UNSET_INDEX ? [] : this.selectedIndex_.slice();\n if (isChecked) {\n selectedIndexes.push(index);\n }\n else {\n selectedIndexes = selectedIndexes.filter(function (i) { return i !== index; });\n }\n this.selectedIndex_ = selectedIndexes;\n };\n return MDCListFoundation;\n}(MDCFoundation));\nexport { MDCListFoundation };\n// tslint:disable-next-line:no-default-export Needed for backward compatibility with MDC Web v0.44.0 and earlier.\nexport default MDCListFoundation;\n//# sourceMappingURL=foundation.js.map","/**\n * @license\n * Copyright 2018 Google Inc.\n *\n * Permission is hereby granted, free of charge, to any person obtaining a copy\n * of this software and associated documentation files (the \"Software\"), to deal\n * in the Software without restriction, including without limitation the rights\n * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell\n * copies of the Software, and to permit persons to whom the Software is\n * furnished to do so, subject to the following conditions:\n *\n * The above copyright notice and this permission notice shall be included in\n * all copies or substantial portions of the Software.\n *\n * THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\n * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\n * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\n * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\n * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\n * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN\n * THE SOFTWARE.\n */\nimport * as tslib_1 from \"tslib\";\nimport { MDCFoundation } from '@material/base/foundation';\nimport { Corner, CornerBit, cssClasses, numbers, strings } from './constants';\nvar MDCMenuSurfaceFoundation = /** @class */ (function (_super) {\n tslib_1.__extends(MDCMenuSurfaceFoundation, _super);\n function MDCMenuSurfaceFoundation(adapter) {\n var _this = _super.call(this, tslib_1.__assign({}, MDCMenuSurfaceFoundation.defaultAdapter, adapter)) || this;\n _this.isOpen_ = false;\n _this.isQuickOpen_ = false;\n _this.isHoistedElement_ = false;\n _this.isFixedPosition_ = false;\n _this.openAnimationEndTimerId_ = 0;\n _this.closeAnimationEndTimerId_ = 0;\n _this.animationRequestId_ = 0;\n _this.anchorCorner_ = Corner.TOP_START;\n _this.anchorMargin_ = { top: 0, right: 0, bottom: 0, left: 0 };\n _this.position_ = { x: 0, y: 0 };\n return _this;\n }\n Object.defineProperty(MDCMenuSurfaceFoundation, \"cssClasses\", {\n get: function () {\n return cssClasses;\n },\n enumerable: true,\n configurable: true\n });\n Object.defineProperty(MDCMenuSurfaceFoundation, \"strings\", {\n get: function () {\n return strings;\n },\n enumerable: true,\n configurable: true\n });\n Object.defineProperty(MDCMenuSurfaceFoundation, \"numbers\", {\n get: function () {\n return numbers;\n },\n enumerable: true,\n configurable: true\n });\n Object.defineProperty(MDCMenuSurfaceFoundation, \"Corner\", {\n get: function () {\n return Corner;\n },\n enumerable: true,\n configurable: true\n });\n Object.defineProperty(MDCMenuSurfaceFoundation, \"defaultAdapter\", {\n /**\n * @see {@link MDCMenuSurfaceAdapter} for typing information on parameters and return types.\n */\n get: function () {\n // tslint:disable:object-literal-sort-keys Methods should be in the same order as the adapter interface.\n return {\n addClass: function () { return undefined; },\n removeClass: function () { return undefined; },\n hasClass: function () { return false; },\n hasAnchor: function () { return false; },\n isElementInContainer: function () { return false; },\n isFocused: function () { return false; },\n isRtl: function () { return false; },\n getInnerDimensions: function () { return ({ height: 0, width: 0 }); },\n getAnchorDimensions: function () { return null; },\n getWindowDimensions: function () { return ({ height: 0, width: 0 }); },\n getBodyDimensions: function () { return ({ height: 0, width: 0 }); },\n getWindowScroll: function () { return ({ x: 0, y: 0 }); },\n setPosition: function () { return undefined; },\n setMaxHeight: function () { return undefined; },\n setTransformOrigin: function () { return undefined; },\n saveFocus: function () { return undefined; },\n restoreFocus: function () { return undefined; },\n notifyClose: function () { return undefined; },\n notifyOpen: function () { return undefined; },\n };\n // tslint:enable:object-literal-sort-keys\n },\n enumerable: true,\n configurable: true\n });\n MDCMenuSurfaceFoundation.prototype.init = function () {\n var _a = MDCMenuSurfaceFoundation.cssClasses, ROOT = _a.ROOT, OPEN = _a.OPEN;\n if (!this.adapter_.hasClass(ROOT)) {\n throw new Error(ROOT + \" class required in root element.\");\n }\n if (this.adapter_.hasClass(OPEN)) {\n this.isOpen_ = true;\n }\n };\n MDCMenuSurfaceFoundation.prototype.destroy = function () {\n clearTimeout(this.openAnimationEndTimerId_);\n clearTimeout(this.closeAnimationEndTimerId_);\n // Cancel any currently running animations.\n cancelAnimationFrame(this.animationRequestId_);\n };\n /**\n * @param corner Default anchor corner alignment of top-left menu surface corner.\n */\n MDCMenuSurfaceFoundation.prototype.setAnchorCorner = function (corner) {\n this.anchorCorner_ = corner;\n };\n /**\n * @param margin Set of margin values from anchor.\n */\n MDCMenuSurfaceFoundation.prototype.setAnchorMargin = function (margin) {\n this.anchorMargin_.top = margin.top || 0;\n this.anchorMargin_.right = margin.right || 0;\n this.anchorMargin_.bottom = margin.bottom || 0;\n this.anchorMargin_.left = margin.left || 0;\n };\n /** Used to indicate if the menu-surface is hoisted to the body. */\n MDCMenuSurfaceFoundation.prototype.setIsHoisted = function (isHoisted) {\n this.isHoistedElement_ = isHoisted;\n };\n /** Used to set the menu-surface calculations based on a fixed position menu. */\n MDCMenuSurfaceFoundation.prototype.setFixedPosition = function (isFixedPosition) {\n this.isFixedPosition_ = isFixedPosition;\n };\n /** Sets the menu-surface position on the page. */\n MDCMenuSurfaceFoundation.prototype.setAbsolutePosition = function (x, y) {\n this.position_.x = this.isFinite_(x) ? x : 0;\n this.position_.y = this.isFinite_(y) ? y : 0;\n };\n MDCMenuSurfaceFoundation.prototype.setQuickOpen = function (quickOpen) {\n this.isQuickOpen_ = quickOpen;\n };\n MDCMenuSurfaceFoundation.prototype.isOpen = function () {\n return this.isOpen_;\n };\n /**\n * Open the menu surface.\n */\n MDCMenuSurfaceFoundation.prototype.open = function () {\n var _this = this;\n this.adapter_.saveFocus();\n if (!this.isQuickOpen_) {\n this.adapter_.addClass(MDCMenuSurfaceFoundation.cssClasses.ANIMATING_OPEN);\n }\n this.animationRequestId_ = requestAnimationFrame(function () {\n _this.adapter_.addClass(MDCMenuSurfaceFoundation.cssClasses.OPEN);\n _this.dimensions_ = _this.adapter_.getInnerDimensions();\n _this.autoPosition_();\n if (_this.isQuickOpen_) {\n _this.adapter_.notifyOpen();\n }\n else {\n _this.openAnimationEndTimerId_ = setTimeout(function () {\n _this.openAnimationEndTimerId_ = 0;\n _this.adapter_.removeClass(MDCMenuSurfaceFoundation.cssClasses.ANIMATING_OPEN);\n _this.adapter_.notifyOpen();\n }, numbers.TRANSITION_OPEN_DURATION);\n }\n });\n this.isOpen_ = true;\n };\n /**\n * Closes the menu surface.\n */\n MDCMenuSurfaceFoundation.prototype.close = function (skipRestoreFocus) {\n var _this = this;\n if (skipRestoreFocus === void 0) { skipRestoreFocus = false; }\n if (!this.isQuickOpen_) {\n this.adapter_.addClass(MDCMenuSurfaceFoundation.cssClasses.ANIMATING_CLOSED);\n }\n requestAnimationFrame(function () {\n _this.adapter_.removeClass(MDCMenuSurfaceFoundation.cssClasses.OPEN);\n if (_this.isQuickOpen_) {\n _this.adapter_.notifyClose();\n }\n else {\n _this.closeAnimationEndTimerId_ = setTimeout(function () {\n _this.closeAnimationEndTimerId_ = 0;\n _this.adapter_.removeClass(MDCMenuSurfaceFoundation.cssClasses.ANIMATING_CLOSED);\n _this.adapter_.notifyClose();\n }, numbers.TRANSITION_CLOSE_DURATION);\n }\n });\n this.isOpen_ = false;\n if (!skipRestoreFocus) {\n this.maybeRestoreFocus_();\n }\n };\n /** Handle clicks and close if not within menu-surface element. */\n MDCMenuSurfaceFoundation.prototype.handleBodyClick = function (evt) {\n var el = evt.target;\n if (this.adapter_.isElementInContainer(el)) {\n return;\n }\n this.close();\n };\n /** Handle keys that close the surface. */\n MDCMenuSurfaceFoundation.prototype.handleKeydown = function (evt) {\n var keyCode = evt.keyCode, key = evt.key;\n var isEscape = key === 'Escape' || keyCode === 27;\n if (isEscape) {\n this.close();\n }\n };\n MDCMenuSurfaceFoundation.prototype.autoPosition_ = function () {\n var _a;\n // Compute measurements for autoposition methods reuse.\n this.measurements_ = this.getAutoLayoutMeasurements_();\n var corner = this.getOriginCorner_();\n var maxMenuSurfaceHeight = this.getMenuSurfaceMaxHeight_(corner);\n var verticalAlignment = this.hasBit_(corner, CornerBit.BOTTOM) ? 'bottom' : 'top';\n var horizontalAlignment = this.hasBit_(corner, CornerBit.RIGHT) ? 'right' : 'left';\n var horizontalOffset = this.getHorizontalOriginOffset_(corner);\n var verticalOffset = this.getVerticalOriginOffset_(corner);\n var _b = this.measurements_, anchorSize = _b.anchorSize, surfaceSize = _b.surfaceSize;\n var position = (_a = {},\n _a[horizontalAlignment] = horizontalOffset,\n _a[verticalAlignment] = verticalOffset,\n _a);\n // Center align when anchor width is comparable or greater than menu surface, otherwise keep corner.\n if (anchorSize.width / surfaceSize.width > numbers.ANCHOR_TO_MENU_SURFACE_WIDTH_RATIO) {\n horizontalAlignment = 'center';\n }\n // If the menu-surface has been hoisted to the body, it's no longer relative to the anchor element\n if (this.isHoistedElement_ || this.isFixedPosition_) {\n this.adjustPositionForHoistedElement_(position);\n }\n this.adapter_.setTransformOrigin(horizontalAlignment + \" \" + verticalAlignment);\n this.adapter_.setPosition(position);\n this.adapter_.setMaxHeight(maxMenuSurfaceHeight ? maxMenuSurfaceHeight + 'px' : '');\n };\n /**\n * @return Measurements used to position menu surface popup.\n */\n MDCMenuSurfaceFoundation.prototype.getAutoLayoutMeasurements_ = function () {\n var anchorRect = this.adapter_.getAnchorDimensions();\n var bodySize = this.adapter_.getBodyDimensions();\n var viewportSize = this.adapter_.getWindowDimensions();\n var windowScroll = this.adapter_.getWindowScroll();\n if (!anchorRect) {\n // tslint:disable:object-literal-sort-keys Positional properties are more readable when they're grouped together\n anchorRect = {\n top: this.position_.y,\n right: this.position_.x,\n bottom: this.position_.y,\n left: this.position_.x,\n width: 0,\n height: 0,\n };\n // tslint:enable:object-literal-sort-keys\n }\n return {\n anchorSize: anchorRect,\n bodySize: bodySize,\n surfaceSize: this.dimensions_,\n viewportDistance: {\n // tslint:disable:object-literal-sort-keys Positional properties are more readable when they're grouped together\n top: anchorRect.top,\n right: viewportSize.width - anchorRect.right,\n bottom: viewportSize.height - anchorRect.bottom,\n left: anchorRect.left,\n },\n viewportSize: viewportSize,\n windowScroll: windowScroll,\n };\n };\n /**\n * Computes the corner of the anchor from which to animate and position the menu surface.\n */\n MDCMenuSurfaceFoundation.prototype.getOriginCorner_ = function () {\n // Defaults: open from the top left.\n var corner = Corner.TOP_LEFT;\n var _a = this.measurements_, viewportDistance = _a.viewportDistance, anchorSize = _a.anchorSize, surfaceSize = _a.surfaceSize;\n var isBottomAligned = this.hasBit_(this.anchorCorner_, CornerBit.BOTTOM);\n var availableTop = isBottomAligned ? viewportDistance.top + anchorSize.height + this.anchorMargin_.bottom\n : viewportDistance.top + this.anchorMargin_.top;\n var availableBottom = isBottomAligned ? viewportDistance.bottom - this.anchorMargin_.bottom\n : viewportDistance.bottom + anchorSize.height - this.anchorMargin_.top;\n var topOverflow = surfaceSize.height - availableTop;\n var bottomOverflow = surfaceSize.height - availableBottom;\n if (bottomOverflow > 0 && topOverflow < bottomOverflow) {\n corner = this.setBit_(corner, CornerBit.BOTTOM);\n }\n var isRtl = this.adapter_.isRtl();\n var isFlipRtl = this.hasBit_(this.anchorCorner_, CornerBit.FLIP_RTL);\n var avoidHorizontalOverlap = this.hasBit_(this.anchorCorner_, CornerBit.RIGHT);\n var isAlignedRight = (avoidHorizontalOverlap && !isRtl) ||\n (!avoidHorizontalOverlap && isFlipRtl && isRtl);\n var availableLeft = isAlignedRight ? viewportDistance.left + anchorSize.width + this.anchorMargin_.right :\n viewportDistance.left + this.anchorMargin_.left;\n var availableRight = isAlignedRight ? viewportDistance.right - this.anchorMargin_.right :\n viewportDistance.right + anchorSize.width - this.anchorMargin_.left;\n var leftOverflow = surfaceSize.width - availableLeft;\n var rightOverflow = surfaceSize.width - availableRight;\n if ((leftOverflow < 0 && isAlignedRight && isRtl) ||\n (avoidHorizontalOverlap && !isAlignedRight && leftOverflow < 0) ||\n (rightOverflow > 0 && leftOverflow < rightOverflow)) {\n corner = this.setBit_(corner, CornerBit.RIGHT);\n }\n return corner;\n };\n /**\n * @param corner Origin corner of the menu surface.\n * @return Maximum height of the menu surface, based on available space. 0 indicates should not be set.\n */\n MDCMenuSurfaceFoundation.prototype.getMenuSurfaceMaxHeight_ = function (corner) {\n var viewportDistance = this.measurements_.viewportDistance;\n var maxHeight = 0;\n var isBottomAligned = this.hasBit_(corner, CornerBit.BOTTOM);\n var isBottomAnchored = this.hasBit_(this.anchorCorner_, CornerBit.BOTTOM);\n var MARGIN_TO_EDGE = MDCMenuSurfaceFoundation.numbers.MARGIN_TO_EDGE;\n // When maximum height is not specified, it is handled from CSS.\n if (isBottomAligned) {\n maxHeight = viewportDistance.top + this.anchorMargin_.top - MARGIN_TO_EDGE;\n if (!isBottomAnchored) {\n maxHeight += this.measurements_.anchorSize.height;\n }\n }\n else {\n maxHeight =\n viewportDistance.bottom - this.anchorMargin_.bottom + this.measurements_.anchorSize.height - MARGIN_TO_EDGE;\n if (isBottomAnchored) {\n maxHeight -= this.measurements_.anchorSize.height;\n }\n }\n return maxHeight;\n };\n /**\n * @param corner Origin corner of the menu surface.\n * @return Horizontal offset of menu surface origin corner from corresponding anchor corner.\n */\n MDCMenuSurfaceFoundation.prototype.getHorizontalOriginOffset_ = function (corner) {\n var anchorSize = this.measurements_.anchorSize;\n // isRightAligned corresponds to using the 'right' property on the surface.\n var isRightAligned = this.hasBit_(corner, CornerBit.RIGHT);\n var avoidHorizontalOverlap = this.hasBit_(this.anchorCorner_, CornerBit.RIGHT);\n if (isRightAligned) {\n var rightOffset = avoidHorizontalOverlap ? anchorSize.width - this.anchorMargin_.left : this.anchorMargin_.right;\n // For hoisted or fixed elements, adjust the offset by the difference between viewport width and body width so\n // when we calculate the right value (`adjustPositionForHoistedElement_`) based on the element position,\n // the right property is correct.\n if (this.isHoistedElement_ || this.isFixedPosition_) {\n return rightOffset - (this.measurements_.viewportSize.width - this.measurements_.bodySize.width);\n }\n return rightOffset;\n }\n return avoidHorizontalOverlap ? anchorSize.width - this.anchorMargin_.right : this.anchorMargin_.left;\n };\n /**\n * @param corner Origin corner of the menu surface.\n * @return Vertical offset of menu surface origin corner from corresponding anchor corner.\n */\n MDCMenuSurfaceFoundation.prototype.getVerticalOriginOffset_ = function (corner) {\n var anchorSize = this.measurements_.anchorSize;\n var isBottomAligned = this.hasBit_(corner, CornerBit.BOTTOM);\n var avoidVerticalOverlap = this.hasBit_(this.anchorCorner_, CornerBit.BOTTOM);\n var y = 0;\n if (isBottomAligned) {\n y = avoidVerticalOverlap ? anchorSize.height - this.anchorMargin_.top : -this.anchorMargin_.bottom;\n }\n else {\n y = avoidVerticalOverlap ? (anchorSize.height + this.anchorMargin_.bottom) : this.anchorMargin_.top;\n }\n return y;\n };\n /** Calculates the offsets for positioning the menu-surface when the menu-surface has been hoisted to the body. */\n MDCMenuSurfaceFoundation.prototype.adjustPositionForHoistedElement_ = function (position) {\n var e_1, _a;\n var _b = this.measurements_, windowScroll = _b.windowScroll, viewportDistance = _b.viewportDistance;\n var props = Object.keys(position);\n try {\n for (var props_1 = tslib_1.__values(props), props_1_1 = props_1.next(); !props_1_1.done; props_1_1 = props_1.next()) {\n var prop = props_1_1.value;\n var value = position[prop] || 0;\n // Hoisted surfaces need to have the anchor elements location on the page added to the\n // position properties for proper alignment on the body.\n value += viewportDistance[prop];\n // Surfaces that are absolutely positioned need to have additional calculations for scroll\n // and bottom positioning.\n if (!this.isFixedPosition_) {\n if (prop === 'top') {\n value += windowScroll.y;\n }\n else if (prop === 'bottom') {\n value -= windowScroll.y;\n }\n else if (prop === 'left') {\n value += windowScroll.x;\n }\n else { // prop === 'right'\n value -= windowScroll.x;\n }\n }\n position[prop] = value;\n }\n }\n catch (e_1_1) { e_1 = { error: e_1_1 }; }\n finally {\n try {\n if (props_1_1 && !props_1_1.done && (_a = props_1.return)) _a.call(props_1);\n }\n finally { if (e_1) throw e_1.error; }\n }\n };\n /**\n * The last focused element when the menu surface was opened should regain focus, if the user is\n * focused on or within the menu surface when it is closed.\n */\n MDCMenuSurfaceFoundation.prototype.maybeRestoreFocus_ = function () {\n var isRootFocused = this.adapter_.isFocused();\n var childHasFocus = document.activeElement && this.adapter_.isElementInContainer(document.activeElement);\n if (isRootFocused || childHasFocus) {\n this.adapter_.restoreFocus();\n }\n };\n MDCMenuSurfaceFoundation.prototype.hasBit_ = function (corner, bit) {\n return Boolean(corner & bit); // tslint:disable-line:no-bitwise\n };\n MDCMenuSurfaceFoundation.prototype.setBit_ = function (corner, bit) {\n return corner | bit; // tslint:disable-line:no-bitwise\n };\n /**\n * isFinite that doesn't force conversion to number type.\n * Equivalent to Number.isFinite in ES2015, which is not supported in IE.\n */\n MDCMenuSurfaceFoundation.prototype.isFinite_ = function (num) {\n return typeof num === 'number' && isFinite(num);\n };\n return MDCMenuSurfaceFoundation;\n}(MDCFoundation));\nexport { MDCMenuSurfaceFoundation };\n// tslint:disable-next-line:no-default-export Needed for backward compatibility with MDC Web v0.44.0 and earlier.\nexport default MDCMenuSurfaceFoundation;\n//# sourceMappingURL=foundation.js.map","/**\n * @license\n * Copyright 2018 Google Inc.\n *\n * Permission is hereby granted, free of charge, to any person obtaining a copy\n * of this software and associated documentation files (the \"Software\"), to deal\n * in the Software without restriction, including without limitation the rights\n * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell\n * copies of the Software, and to permit persons to whom the Software is\n * furnished to do so, subject to the following conditions:\n *\n * The above copyright notice and this permission notice shall be included in\n * all copies or substantial portions of the Software.\n *\n * THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\n * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\n * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\n * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\n * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\n * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN\n * THE SOFTWARE.\n */\nimport * as tslib_1 from \"tslib\";\nimport { MDCFoundation } from '@material/base/foundation';\nimport { MDCMenuSurfaceFoundation } from '@material/menu-surface/foundation';\nimport { cssClasses, DefaultFocusState, numbers, strings } from './constants';\nvar MDCMenuFoundation = /** @class */ (function (_super) {\n tslib_1.__extends(MDCMenuFoundation, _super);\n function MDCMenuFoundation(adapter) {\n var _this = _super.call(this, tslib_1.__assign({}, MDCMenuFoundation.defaultAdapter, adapter)) || this;\n _this.closeAnimationEndTimerId_ = 0;\n _this.defaultFocusState_ = DefaultFocusState.LIST_ROOT;\n return _this;\n }\n Object.defineProperty(MDCMenuFoundation, \"cssClasses\", {\n get: function () {\n return cssClasses;\n },\n enumerable: true,\n configurable: true\n });\n Object.defineProperty(MDCMenuFoundation, \"strings\", {\n get: function () {\n return strings;\n },\n enumerable: true,\n configurable: true\n });\n Object.defineProperty(MDCMenuFoundation, \"numbers\", {\n get: function () {\n return numbers;\n },\n enumerable: true,\n configurable: true\n });\n Object.defineProperty(MDCMenuFoundation, \"defaultAdapter\", {\n /**\n * @see {@link MDCMenuAdapter} for typing information on parameters and return types.\n */\n get: function () {\n // tslint:disable:object-literal-sort-keys Methods should be in the same order as the adapter interface.\n return {\n addClassToElementAtIndex: function () { return undefined; },\n removeClassFromElementAtIndex: function () { return undefined; },\n addAttributeToElementAtIndex: function () { return undefined; },\n removeAttributeFromElementAtIndex: function () { return undefined; },\n elementContainsClass: function () { return false; },\n closeSurface: function () { return undefined; },\n getElementIndex: function () { return -1; },\n notifySelected: function () { return undefined; },\n getMenuItemCount: function () { return 0; },\n focusItemAtIndex: function () { return undefined; },\n focusListRoot: function () { return undefined; },\n getSelectedSiblingOfItemAtIndex: function () { return -1; },\n isSelectableItemAtIndex: function () { return false; },\n };\n // tslint:enable:object-literal-sort-keys\n },\n enumerable: true,\n configurable: true\n });\n MDCMenuFoundation.prototype.destroy = function () {\n if (this.closeAnimationEndTimerId_) {\n clearTimeout(this.closeAnimationEndTimerId_);\n }\n this.adapter_.closeSurface();\n };\n MDCMenuFoundation.prototype.handleKeydown = function (evt) {\n var key = evt.key, keyCode = evt.keyCode;\n var isTab = key === 'Tab' || keyCode === 9;\n if (isTab) {\n this.adapter_.closeSurface(/** skipRestoreFocus */ true);\n }\n };\n MDCMenuFoundation.prototype.handleItemAction = function (listItem) {\n var _this = this;\n var index = this.adapter_.getElementIndex(listItem);\n if (index < 0) {\n return;\n }\n this.adapter_.notifySelected({ index: index });\n this.adapter_.closeSurface();\n // Wait for the menu to close before adding/removing classes that affect styles.\n this.closeAnimationEndTimerId_ = setTimeout(function () {\n if (_this.adapter_.isSelectableItemAtIndex(index)) {\n _this.setSelectedIndex(index);\n }\n }, MDCMenuSurfaceFoundation.numbers.TRANSITION_CLOSE_DURATION);\n };\n MDCMenuFoundation.prototype.handleMenuSurfaceOpened = function () {\n switch (this.defaultFocusState_) {\n case DefaultFocusState.FIRST_ITEM:\n this.adapter_.focusItemAtIndex(0);\n break;\n case DefaultFocusState.LAST_ITEM:\n this.adapter_.focusItemAtIndex(this.adapter_.getMenuItemCount() - 1);\n break;\n case DefaultFocusState.NONE:\n // Do nothing.\n break;\n default:\n this.adapter_.focusListRoot();\n break;\n }\n };\n /**\n * Sets default focus state where the menu should focus every time when menu\n * is opened. Focuses the list root (`DefaultFocusState.LIST_ROOT`) element by\n * default.\n */\n MDCMenuFoundation.prototype.setDefaultFocusState = function (focusState) {\n this.defaultFocusState_ = focusState;\n };\n /**\n * Selects the list item at `index` within the menu.\n * @param index Index of list item within the menu.\n */\n MDCMenuFoundation.prototype.setSelectedIndex = function (index) {\n this.validatedIndex_(index);\n if (!this.adapter_.isSelectableItemAtIndex(index)) {\n throw new Error('MDCMenuFoundation: No selection group at specified index.');\n }\n var prevSelectedIndex = this.adapter_.getSelectedSiblingOfItemAtIndex(index);\n if (prevSelectedIndex >= 0) {\n this.adapter_.removeAttributeFromElementAtIndex(prevSelectedIndex, strings.ARIA_CHECKED_ATTR);\n this.adapter_.removeClassFromElementAtIndex(prevSelectedIndex, cssClasses.MENU_SELECTED_LIST_ITEM);\n }\n this.adapter_.addClassToElementAtIndex(index, cssClasses.MENU_SELECTED_LIST_ITEM);\n this.adapter_.addAttributeToElementAtIndex(index, strings.ARIA_CHECKED_ATTR, 'true');\n };\n MDCMenuFoundation.prototype.validatedIndex_ = function (index) {\n var menuSize = this.adapter_.getMenuItemCount();\n var isIndexInRange = index >= 0 && index < menuSize;\n if (!isIndexInRange) {\n throw new Error('MDCMenuFoundation: No list item at specified index.');\n }\n };\n return MDCMenuFoundation;\n}(MDCFoundation));\nexport { MDCMenuFoundation };\n// tslint:disable-next-line:no-default-export Needed for backward compatibility with MDC Web v0.44.0 and earlier.\nexport default MDCMenuFoundation;\n//# sourceMappingURL=foundation.js.map","/**\n * @license\n * Copyright 2017 Google Inc.\n *\n * Permission is hereby granted, free of charge, to any person obtaining a copy\n * of this software and associated documentation files (the \"Software\"), to deal\n * in the Software without restriction, including without limitation the rights\n * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell\n * copies of the Software, and to permit persons to whom the Software is\n * furnished to do so, subject to the following conditions:\n *\n * The above copyright notice and this permission notice shall be included in\n * all copies or substantial portions of the Software.\n *\n * THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\n * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\n * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\n * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\n * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\n * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN\n * THE SOFTWARE.\n */\nimport * as tslib_1 from \"tslib\";\nimport { MDCFoundation } from '@material/base/foundation';\nimport { cssClasses, numbers, strings } from './constants';\nvar MDCNotchedOutlineFoundation = /** @class */ (function (_super) {\n tslib_1.__extends(MDCNotchedOutlineFoundation, _super);\n function MDCNotchedOutlineFoundation(adapter) {\n return _super.call(this, tslib_1.__assign({}, MDCNotchedOutlineFoundation.defaultAdapter, adapter)) || this;\n }\n Object.defineProperty(MDCNotchedOutlineFoundation, \"strings\", {\n get: function () {\n return strings;\n },\n enumerable: true,\n configurable: true\n });\n Object.defineProperty(MDCNotchedOutlineFoundation, \"cssClasses\", {\n get: function () {\n return cssClasses;\n },\n enumerable: true,\n configurable: true\n });\n Object.defineProperty(MDCNotchedOutlineFoundation, \"numbers\", {\n get: function () {\n return numbers;\n },\n enumerable: true,\n configurable: true\n });\n Object.defineProperty(MDCNotchedOutlineFoundation, \"defaultAdapter\", {\n /**\n * See {@link MDCNotchedOutlineAdapter} for typing information on parameters and return types.\n */\n get: function () {\n // tslint:disable:object-literal-sort-keys Methods should be in the same order as the adapter interface.\n return {\n addClass: function () { return undefined; },\n removeClass: function () { return undefined; },\n setNotchWidthProperty: function () { return undefined; },\n removeNotchWidthProperty: function () { return undefined; },\n };\n // tslint:enable:object-literal-sort-keys\n },\n enumerable: true,\n configurable: true\n });\n /**\n * Adds the outline notched selector and updates the notch width calculated based off of notchWidth.\n */\n MDCNotchedOutlineFoundation.prototype.notch = function (notchWidth) {\n var OUTLINE_NOTCHED = MDCNotchedOutlineFoundation.cssClasses.OUTLINE_NOTCHED;\n if (notchWidth > 0) {\n notchWidth += numbers.NOTCH_ELEMENT_PADDING; // Add padding from left/right.\n }\n this.adapter_.setNotchWidthProperty(notchWidth);\n this.adapter_.addClass(OUTLINE_NOTCHED);\n };\n /**\n * Removes notched outline selector to close the notch in the outline.\n */\n MDCNotchedOutlineFoundation.prototype.closeNotch = function () {\n var OUTLINE_NOTCHED = MDCNotchedOutlineFoundation.cssClasses.OUTLINE_NOTCHED;\n this.adapter_.removeClass(OUTLINE_NOTCHED);\n this.adapter_.removeNotchWidthProperty();\n };\n return MDCNotchedOutlineFoundation;\n}(MDCFoundation));\nexport { MDCNotchedOutlineFoundation };\n// tslint:disable-next-line:no-default-export Needed for backward compatibility with MDC Web v0.44.0 and earlier.\nexport default MDCNotchedOutlineFoundation;\n//# sourceMappingURL=foundation.js.map","/**\n * @license\n * Copyright 2016 Google Inc.\n *\n * Permission is hereby granted, free of charge, to any person obtaining a copy\n * of this software and associated documentation files (the \"Software\"), to deal\n * in the Software without restriction, including without limitation the rights\n * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell\n * copies of the Software, and to permit persons to whom the Software is\n * furnished to do so, subject to the following conditions:\n *\n * The above copyright notice and this permission notice shall be included in\n * all copies or substantial portions of the Software.\n *\n * THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\n * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\n * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\n * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\n * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\n * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN\n * THE SOFTWARE.\n */\nimport * as tslib_1 from \"tslib\";\nimport { MDCFoundation } from '@material/base/foundation';\nimport { cssClasses, numbers, strings } from './constants';\nimport { getNormalizedEventCoords } from './util';\n// Activation events registered on the root element of each instance for activation\nvar ACTIVATION_EVENT_TYPES = [\n 'touchstart', 'pointerdown', 'mousedown', 'keydown',\n];\n// Deactivation events registered on documentElement when a pointer-related down event occurs\nvar POINTER_DEACTIVATION_EVENT_TYPES = [\n 'touchend', 'pointerup', 'mouseup', 'contextmenu',\n];\n// simultaneous nested activations\nvar activatedTargets = [];\nvar MDCRippleFoundation = /** @class */ (function (_super) {\n tslib_1.__extends(MDCRippleFoundation, _super);\n function MDCRippleFoundation(adapter) {\n var _this = _super.call(this, tslib_1.__assign({}, MDCRippleFoundation.defaultAdapter, adapter)) || this;\n _this.activationAnimationHasEnded_ = false;\n _this.activationTimer_ = 0;\n _this.fgDeactivationRemovalTimer_ = 0;\n _this.fgScale_ = '0';\n _this.frame_ = { width: 0, height: 0 };\n _this.initialSize_ = 0;\n _this.layoutFrame_ = 0;\n _this.maxRadius_ = 0;\n _this.unboundedCoords_ = { left: 0, top: 0 };\n _this.activationState_ = _this.defaultActivationState_();\n _this.activationTimerCallback_ = function () {\n _this.activationAnimationHasEnded_ = true;\n _this.runDeactivationUXLogicIfReady_();\n };\n _this.activateHandler_ = function (e) { return _this.activate_(e); };\n _this.deactivateHandler_ = function () { return _this.deactivate_(); };\n _this.focusHandler_ = function () { return _this.handleFocus(); };\n _this.blurHandler_ = function () { return _this.handleBlur(); };\n _this.resizeHandler_ = function () { return _this.layout(); };\n return _this;\n }\n Object.defineProperty(MDCRippleFoundation, \"cssClasses\", {\n get: function () {\n return cssClasses;\n },\n enumerable: true,\n configurable: true\n });\n Object.defineProperty(MDCRippleFoundation, \"strings\", {\n get: function () {\n return strings;\n },\n enumerable: true,\n configurable: true\n });\n Object.defineProperty(MDCRippleFoundation, \"numbers\", {\n get: function () {\n return numbers;\n },\n enumerable: true,\n configurable: true\n });\n Object.defineProperty(MDCRippleFoundation, \"defaultAdapter\", {\n get: function () {\n return {\n addClass: function () { return undefined; },\n browserSupportsCssVars: function () { return true; },\n computeBoundingRect: function () { return ({ top: 0, right: 0, bottom: 0, left: 0, width: 0, height: 0 }); },\n containsEventTarget: function () { return true; },\n deregisterDocumentInteractionHandler: function () { return undefined; },\n deregisterInteractionHandler: function () { return undefined; },\n deregisterResizeHandler: function () { return undefined; },\n getWindowPageOffset: function () { return ({ x: 0, y: 0 }); },\n isSurfaceActive: function () { return true; },\n isSurfaceDisabled: function () { return true; },\n isUnbounded: function () { return true; },\n registerDocumentInteractionHandler: function () { return undefined; },\n registerInteractionHandler: function () { return undefined; },\n registerResizeHandler: function () { return undefined; },\n removeClass: function () { return undefined; },\n updateCssVariable: function () { return undefined; },\n };\n },\n enumerable: true,\n configurable: true\n });\n MDCRippleFoundation.prototype.init = function () {\n var _this = this;\n var supportsPressRipple = this.supportsPressRipple_();\n this.registerRootHandlers_(supportsPressRipple);\n if (supportsPressRipple) {\n var _a = MDCRippleFoundation.cssClasses, ROOT_1 = _a.ROOT, UNBOUNDED_1 = _a.UNBOUNDED;\n requestAnimationFrame(function () {\n _this.adapter_.addClass(ROOT_1);\n if (_this.adapter_.isUnbounded()) {\n _this.adapter_.addClass(UNBOUNDED_1);\n // Unbounded ripples need layout logic applied immediately to set coordinates for both shade and ripple\n _this.layoutInternal_();\n }\n });\n }\n };\n MDCRippleFoundation.prototype.destroy = function () {\n var _this = this;\n if (this.supportsPressRipple_()) {\n if (this.activationTimer_) {\n clearTimeout(this.activationTimer_);\n this.activationTimer_ = 0;\n this.adapter_.removeClass(MDCRippleFoundation.cssClasses.FG_ACTIVATION);\n }\n if (this.fgDeactivationRemovalTimer_) {\n clearTimeout(this.fgDeactivationRemovalTimer_);\n this.fgDeactivationRemovalTimer_ = 0;\n this.adapter_.removeClass(MDCRippleFoundation.cssClasses.FG_DEACTIVATION);\n }\n var _a = MDCRippleFoundation.cssClasses, ROOT_2 = _a.ROOT, UNBOUNDED_2 = _a.UNBOUNDED;\n requestAnimationFrame(function () {\n _this.adapter_.removeClass(ROOT_2);\n _this.adapter_.removeClass(UNBOUNDED_2);\n _this.removeCssVars_();\n });\n }\n this.deregisterRootHandlers_();\n this.deregisterDeactivationHandlers_();\n };\n /**\n * @param evt Optional event containing position information.\n */\n MDCRippleFoundation.prototype.activate = function (evt) {\n this.activate_(evt);\n };\n MDCRippleFoundation.prototype.deactivate = function () {\n this.deactivate_();\n };\n MDCRippleFoundation.prototype.layout = function () {\n var _this = this;\n if (this.layoutFrame_) {\n cancelAnimationFrame(this.layoutFrame_);\n }\n this.layoutFrame_ = requestAnimationFrame(function () {\n _this.layoutInternal_();\n _this.layoutFrame_ = 0;\n });\n };\n MDCRippleFoundation.prototype.setUnbounded = function (unbounded) {\n var UNBOUNDED = MDCRippleFoundation.cssClasses.UNBOUNDED;\n if (unbounded) {\n this.adapter_.addClass(UNBOUNDED);\n }\n else {\n this.adapter_.removeClass(UNBOUNDED);\n }\n };\n MDCRippleFoundation.prototype.handleFocus = function () {\n var _this = this;\n requestAnimationFrame(function () {\n return _this.adapter_.addClass(MDCRippleFoundation.cssClasses.BG_FOCUSED);\n });\n };\n MDCRippleFoundation.prototype.handleBlur = function () {\n var _this = this;\n requestAnimationFrame(function () {\n return _this.adapter_.removeClass(MDCRippleFoundation.cssClasses.BG_FOCUSED);\n });\n };\n /**\n * We compute this property so that we are not querying information about the client\n * until the point in time where the foundation requests it. This prevents scenarios where\n * client-side feature-detection may happen too early, such as when components are rendered on the server\n * and then initialized at mount time on the client.\n */\n MDCRippleFoundation.prototype.supportsPressRipple_ = function () {\n return this.adapter_.browserSupportsCssVars();\n };\n MDCRippleFoundation.prototype.defaultActivationState_ = function () {\n return {\n activationEvent: undefined,\n hasDeactivationUXRun: false,\n isActivated: false,\n isProgrammatic: false,\n wasActivatedByPointer: false,\n wasElementMadeActive: false,\n };\n };\n /**\n * supportsPressRipple Passed from init to save a redundant function call\n */\n MDCRippleFoundation.prototype.registerRootHandlers_ = function (supportsPressRipple) {\n var _this = this;\n if (supportsPressRipple) {\n ACTIVATION_EVENT_TYPES.forEach(function (evtType) {\n _this.adapter_.registerInteractionHandler(evtType, _this.activateHandler_);\n });\n if (this.adapter_.isUnbounded()) {\n this.adapter_.registerResizeHandler(this.resizeHandler_);\n }\n }\n this.adapter_.registerInteractionHandler('focus', this.focusHandler_);\n this.adapter_.registerInteractionHandler('blur', this.blurHandler_);\n };\n MDCRippleFoundation.prototype.registerDeactivationHandlers_ = function (evt) {\n var _this = this;\n if (evt.type === 'keydown') {\n this.adapter_.registerInteractionHandler('keyup', this.deactivateHandler_);\n }\n else {\n POINTER_DEACTIVATION_EVENT_TYPES.forEach(function (evtType) {\n _this.adapter_.registerDocumentInteractionHandler(evtType, _this.deactivateHandler_);\n });\n }\n };\n MDCRippleFoundation.prototype.deregisterRootHandlers_ = function () {\n var _this = this;\n ACTIVATION_EVENT_TYPES.forEach(function (evtType) {\n _this.adapter_.deregisterInteractionHandler(evtType, _this.activateHandler_);\n });\n this.adapter_.deregisterInteractionHandler('focus', this.focusHandler_);\n this.adapter_.deregisterInteractionHandler('blur', this.blurHandler_);\n if (this.adapter_.isUnbounded()) {\n this.adapter_.deregisterResizeHandler(this.resizeHandler_);\n }\n };\n MDCRippleFoundation.prototype.deregisterDeactivationHandlers_ = function () {\n var _this = this;\n this.adapter_.deregisterInteractionHandler('keyup', this.deactivateHandler_);\n POINTER_DEACTIVATION_EVENT_TYPES.forEach(function (evtType) {\n _this.adapter_.deregisterDocumentInteractionHandler(evtType, _this.deactivateHandler_);\n });\n };\n MDCRippleFoundation.prototype.removeCssVars_ = function () {\n var _this = this;\n var rippleStrings = MDCRippleFoundation.strings;\n var keys = Object.keys(rippleStrings);\n keys.forEach(function (key) {\n if (key.indexOf('VAR_') === 0) {\n _this.adapter_.updateCssVariable(rippleStrings[key], null);\n }\n });\n };\n MDCRippleFoundation.prototype.activate_ = function (evt) {\n var _this = this;\n if (this.adapter_.isSurfaceDisabled()) {\n return;\n }\n var activationState = this.activationState_;\n if (activationState.isActivated) {\n return;\n }\n // Avoid reacting to follow-on events fired by touch device after an already-processed user interaction\n var previousActivationEvent = this.previousActivationEvent_;\n var isSameInteraction = previousActivationEvent && evt !== undefined && previousActivationEvent.type !== evt.type;\n if (isSameInteraction) {\n return;\n }\n activationState.isActivated = true;\n activationState.isProgrammatic = evt === undefined;\n activationState.activationEvent = evt;\n activationState.wasActivatedByPointer = activationState.isProgrammatic ? false : evt !== undefined && (evt.type === 'mousedown' || evt.type === 'touchstart' || evt.type === 'pointerdown');\n var hasActivatedChild = evt !== undefined && activatedTargets.length > 0 && activatedTargets.some(function (target) { return _this.adapter_.containsEventTarget(target); });\n if (hasActivatedChild) {\n // Immediately reset activation state, while preserving logic that prevents touch follow-on events\n this.resetActivationState_();\n return;\n }\n if (evt !== undefined) {\n activatedTargets.push(evt.target);\n this.registerDeactivationHandlers_(evt);\n }\n activationState.wasElementMadeActive = this.checkElementMadeActive_(evt);\n if (activationState.wasElementMadeActive) {\n this.animateActivation_();\n }\n requestAnimationFrame(function () {\n // Reset array on next frame after the current event has had a chance to bubble to prevent ancestor ripples\n activatedTargets = [];\n if (!activationState.wasElementMadeActive\n && evt !== undefined\n && (evt.key === ' ' || evt.keyCode === 32)) {\n // If space was pressed, try again within an rAF call to detect :active, because different UAs report\n // active states inconsistently when they're called within event handling code:\n // - https://bugs.chromium.org/p/chromium/issues/detail?id=635971\n // - https://bugzilla.mozilla.org/show_bug.cgi?id=1293741\n // We try first outside rAF to support Edge, which does not exhibit this problem, but will crash if a CSS\n // variable is set within a rAF callback for a submit button interaction (#2241).\n activationState.wasElementMadeActive = _this.checkElementMadeActive_(evt);\n if (activationState.wasElementMadeActive) {\n _this.animateActivation_();\n }\n }\n if (!activationState.wasElementMadeActive) {\n // Reset activation state immediately if element was not made active.\n _this.activationState_ = _this.defaultActivationState_();\n }\n });\n };\n MDCRippleFoundation.prototype.checkElementMadeActive_ = function (evt) {\n return (evt !== undefined && evt.type === 'keydown') ? this.adapter_.isSurfaceActive() : true;\n };\n MDCRippleFoundation.prototype.animateActivation_ = function () {\n var _this = this;\n var _a = MDCRippleFoundation.strings, VAR_FG_TRANSLATE_START = _a.VAR_FG_TRANSLATE_START, VAR_FG_TRANSLATE_END = _a.VAR_FG_TRANSLATE_END;\n var _b = MDCRippleFoundation.cssClasses, FG_DEACTIVATION = _b.FG_DEACTIVATION, FG_ACTIVATION = _b.FG_ACTIVATION;\n var DEACTIVATION_TIMEOUT_MS = MDCRippleFoundation.numbers.DEACTIVATION_TIMEOUT_MS;\n this.layoutInternal_();\n var translateStart = '';\n var translateEnd = '';\n if (!this.adapter_.isUnbounded()) {\n var _c = this.getFgTranslationCoordinates_(), startPoint = _c.startPoint, endPoint = _c.endPoint;\n translateStart = startPoint.x + \"px, \" + startPoint.y + \"px\";\n translateEnd = endPoint.x + \"px, \" + endPoint.y + \"px\";\n }\n this.adapter_.updateCssVariable(VAR_FG_TRANSLATE_START, translateStart);\n this.adapter_.updateCssVariable(VAR_FG_TRANSLATE_END, translateEnd);\n // Cancel any ongoing activation/deactivation animations\n clearTimeout(this.activationTimer_);\n clearTimeout(this.fgDeactivationRemovalTimer_);\n this.rmBoundedActivationClasses_();\n this.adapter_.removeClass(FG_DEACTIVATION);\n // Force layout in order to re-trigger the animation.\n this.adapter_.computeBoundingRect();\n this.adapter_.addClass(FG_ACTIVATION);\n this.activationTimer_ = setTimeout(function () { return _this.activationTimerCallback_(); }, DEACTIVATION_TIMEOUT_MS);\n };\n MDCRippleFoundation.prototype.getFgTranslationCoordinates_ = function () {\n var _a = this.activationState_, activationEvent = _a.activationEvent, wasActivatedByPointer = _a.wasActivatedByPointer;\n var startPoint;\n if (wasActivatedByPointer) {\n startPoint = getNormalizedEventCoords(activationEvent, this.adapter_.getWindowPageOffset(), this.adapter_.computeBoundingRect());\n }\n else {\n startPoint = {\n x: this.frame_.width / 2,\n y: this.frame_.height / 2,\n };\n }\n // Center the element around the start point.\n startPoint = {\n x: startPoint.x - (this.initialSize_ / 2),\n y: startPoint.y - (this.initialSize_ / 2),\n };\n var endPoint = {\n x: (this.frame_.width / 2) - (this.initialSize_ / 2),\n y: (this.frame_.height / 2) - (this.initialSize_ / 2),\n };\n return { startPoint: startPoint, endPoint: endPoint };\n };\n MDCRippleFoundation.prototype.runDeactivationUXLogicIfReady_ = function () {\n var _this = this;\n // This method is called both when a pointing device is released, and when the activation animation ends.\n // The deactivation animation should only run after both of those occur.\n var FG_DEACTIVATION = MDCRippleFoundation.cssClasses.FG_DEACTIVATION;\n var _a = this.activationState_, hasDeactivationUXRun = _a.hasDeactivationUXRun, isActivated = _a.isActivated;\n var activationHasEnded = hasDeactivationUXRun || !isActivated;\n if (activationHasEnded && this.activationAnimationHasEnded_) {\n this.rmBoundedActivationClasses_();\n this.adapter_.addClass(FG_DEACTIVATION);\n this.fgDeactivationRemovalTimer_ = setTimeout(function () {\n _this.adapter_.removeClass(FG_DEACTIVATION);\n }, numbers.FG_DEACTIVATION_MS);\n }\n };\n MDCRippleFoundation.prototype.rmBoundedActivationClasses_ = function () {\n var FG_ACTIVATION = MDCRippleFoundation.cssClasses.FG_ACTIVATION;\n this.adapter_.removeClass(FG_ACTIVATION);\n this.activationAnimationHasEnded_ = false;\n this.adapter_.computeBoundingRect();\n };\n MDCRippleFoundation.prototype.resetActivationState_ = function () {\n var _this = this;\n this.previousActivationEvent_ = this.activationState_.activationEvent;\n this.activationState_ = this.defaultActivationState_();\n // Touch devices may fire additional events for the same interaction within a short time.\n // Store the previous event until it's safe to assume that subsequent events are for new interactions.\n setTimeout(function () { return _this.previousActivationEvent_ = undefined; }, MDCRippleFoundation.numbers.TAP_DELAY_MS);\n };\n MDCRippleFoundation.prototype.deactivate_ = function () {\n var _this = this;\n var activationState = this.activationState_;\n // This can happen in scenarios such as when you have a keyup event that blurs the element.\n if (!activationState.isActivated) {\n return;\n }\n var state = tslib_1.__assign({}, activationState);\n if (activationState.isProgrammatic) {\n requestAnimationFrame(function () { return _this.animateDeactivation_(state); });\n this.resetActivationState_();\n }\n else {\n this.deregisterDeactivationHandlers_();\n requestAnimationFrame(function () {\n _this.activationState_.hasDeactivationUXRun = true;\n _this.animateDeactivation_(state);\n _this.resetActivationState_();\n });\n }\n };\n MDCRippleFoundation.prototype.animateDeactivation_ = function (_a) {\n var wasActivatedByPointer = _a.wasActivatedByPointer, wasElementMadeActive = _a.wasElementMadeActive;\n if (wasActivatedByPointer || wasElementMadeActive) {\n this.runDeactivationUXLogicIfReady_();\n }\n };\n MDCRippleFoundation.prototype.layoutInternal_ = function () {\n var _this = this;\n this.frame_ = this.adapter_.computeBoundingRect();\n var maxDim = Math.max(this.frame_.height, this.frame_.width);\n // Surface diameter is treated differently for unbounded vs. bounded ripples.\n // Unbounded ripple diameter is calculated smaller since the surface is expected to already be padded appropriately\n // to extend the hitbox, and the ripple is expected to meet the edges of the padded hitbox (which is typically\n // square). Bounded ripples, on the other hand, are fully expected to expand beyond the surface's longest diameter\n // (calculated based on the diagonal plus a constant padding), and are clipped at the surface's border via\n // `overflow: hidden`.\n var getBoundedRadius = function () {\n var hypotenuse = Math.sqrt(Math.pow(_this.frame_.width, 2) + Math.pow(_this.frame_.height, 2));\n return hypotenuse + MDCRippleFoundation.numbers.PADDING;\n };\n this.maxRadius_ = this.adapter_.isUnbounded() ? maxDim : getBoundedRadius();\n // Ripple is sized as a fraction of the largest dimension of the surface, then scales up using a CSS scale transform\n this.initialSize_ = Math.floor(maxDim * MDCRippleFoundation.numbers.INITIAL_ORIGIN_SCALE);\n this.fgScale_ = \"\" + this.maxRadius_ / this.initialSize_;\n this.updateLayoutCssVars_();\n };\n MDCRippleFoundation.prototype.updateLayoutCssVars_ = function () {\n var _a = MDCRippleFoundation.strings, VAR_FG_SIZE = _a.VAR_FG_SIZE, VAR_LEFT = _a.VAR_LEFT, VAR_TOP = _a.VAR_TOP, VAR_FG_SCALE = _a.VAR_FG_SCALE;\n this.adapter_.updateCssVariable(VAR_FG_SIZE, this.initialSize_ + \"px\");\n this.adapter_.updateCssVariable(VAR_FG_SCALE, this.fgScale_);\n if (this.adapter_.isUnbounded()) {\n this.unboundedCoords_ = {\n left: Math.round((this.frame_.width / 2) - (this.initialSize_ / 2)),\n top: Math.round((this.frame_.height / 2) - (this.initialSize_ / 2)),\n };\n this.adapter_.updateCssVariable(VAR_LEFT, this.unboundedCoords_.left + \"px\");\n this.adapter_.updateCssVariable(VAR_TOP, this.unboundedCoords_.top + \"px\");\n }\n };\n return MDCRippleFoundation;\n}(MDCFoundation));\nexport { MDCRippleFoundation };\n// tslint:disable-next-line:no-default-export Needed for backward compatibility with MDC Web v0.44.0 and earlier.\nexport default MDCRippleFoundation;\n//# sourceMappingURL=foundation.js.map","/**\n * @license\n * Copyright 2018 Google Inc.\n *\n * Permission is hereby granted, free of charge, to any person obtaining a copy\n * of this software and associated documentation files (the \"Software\"), to deal\n * in the Software without restriction, including without limitation the rights\n * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell\n * copies of the Software, and to permit persons to whom the Software is\n * furnished to do so, subject to the following conditions:\n *\n * The above copyright notice and this permission notice shall be included in\n * all copies or substantial portions of the Software.\n *\n * THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\n * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\n * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\n * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\n * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\n * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN\n * THE SOFTWARE.\n */\nimport * as tslib_1 from \"tslib\";\nimport { MDCFoundation } from '@material/base/foundation';\nimport { numbers, strings } from './constants';\nvar ACCEPTABLE_KEYS = new Set();\n// IE11 has no support for new Set with iterable so we need to initialize this by hand\nACCEPTABLE_KEYS.add(strings.ARROW_LEFT_KEY);\nACCEPTABLE_KEYS.add(strings.ARROW_RIGHT_KEY);\nACCEPTABLE_KEYS.add(strings.END_KEY);\nACCEPTABLE_KEYS.add(strings.HOME_KEY);\nACCEPTABLE_KEYS.add(strings.ENTER_KEY);\nACCEPTABLE_KEYS.add(strings.SPACE_KEY);\nvar KEYCODE_MAP = new Map();\n// IE11 has no support for new Map with iterable so we need to initialize this by hand\nKEYCODE_MAP.set(numbers.ARROW_LEFT_KEYCODE, strings.ARROW_LEFT_KEY);\nKEYCODE_MAP.set(numbers.ARROW_RIGHT_KEYCODE, strings.ARROW_RIGHT_KEY);\nKEYCODE_MAP.set(numbers.END_KEYCODE, strings.END_KEY);\nKEYCODE_MAP.set(numbers.HOME_KEYCODE, strings.HOME_KEY);\nKEYCODE_MAP.set(numbers.ENTER_KEYCODE, strings.ENTER_KEY);\nKEYCODE_MAP.set(numbers.SPACE_KEYCODE, strings.SPACE_KEY);\nvar MDCTabBarFoundation = /** @class */ (function (_super) {\n tslib_1.__extends(MDCTabBarFoundation, _super);\n function MDCTabBarFoundation(adapter) {\n var _this = _super.call(this, tslib_1.__assign({}, MDCTabBarFoundation.defaultAdapter, adapter)) || this;\n _this.useAutomaticActivation_ = false;\n return _this;\n }\n Object.defineProperty(MDCTabBarFoundation, \"strings\", {\n get: function () {\n return strings;\n },\n enumerable: true,\n configurable: true\n });\n Object.defineProperty(MDCTabBarFoundation, \"numbers\", {\n get: function () {\n return numbers;\n },\n enumerable: true,\n configurable: true\n });\n Object.defineProperty(MDCTabBarFoundation, \"defaultAdapter\", {\n get: function () {\n // tslint:disable:object-literal-sort-keys Methods should be in the same order as the adapter interface.\n return {\n scrollTo: function () { return undefined; },\n incrementScroll: function () { return undefined; },\n getScrollPosition: function () { return 0; },\n getScrollContentWidth: function () { return 0; },\n getOffsetWidth: function () { return 0; },\n isRTL: function () { return false; },\n setActiveTab: function () { return undefined; },\n activateTabAtIndex: function () { return undefined; },\n deactivateTabAtIndex: function () { return undefined; },\n focusTabAtIndex: function () { return undefined; },\n getTabIndicatorClientRectAtIndex: function () { return ({ top: 0, right: 0, bottom: 0, left: 0, width: 0, height: 0 }); },\n getTabDimensionsAtIndex: function () { return ({ rootLeft: 0, rootRight: 0, contentLeft: 0, contentRight: 0 }); },\n getPreviousActiveTabIndex: function () { return -1; },\n getFocusedTabIndex: function () { return -1; },\n getIndexOfTabById: function () { return -1; },\n getTabListLength: function () { return 0; },\n notifyTabActivated: function () { return undefined; },\n };\n // tslint:enable:object-literal-sort-keys\n },\n enumerable: true,\n configurable: true\n });\n /**\n * Switches between automatic and manual activation modes.\n * See https://www.w3.org/TR/wai-aria-practices/#tabpanel for examples.\n */\n MDCTabBarFoundation.prototype.setUseAutomaticActivation = function (useAutomaticActivation) {\n this.useAutomaticActivation_ = useAutomaticActivation;\n };\n MDCTabBarFoundation.prototype.activateTab = function (index) {\n var previousActiveIndex = this.adapter_.getPreviousActiveTabIndex();\n if (!this.indexIsInRange_(index) || index === previousActiveIndex) {\n return;\n }\n var previousClientRect;\n if (previousActiveIndex !== -1) {\n this.adapter_.deactivateTabAtIndex(previousActiveIndex);\n previousClientRect = this.adapter_.getTabIndicatorClientRectAtIndex(previousActiveIndex);\n }\n this.adapter_.activateTabAtIndex(index, previousClientRect);\n this.scrollIntoView(index);\n this.adapter_.notifyTabActivated(index);\n };\n MDCTabBarFoundation.prototype.handleKeyDown = function (evt) {\n // Get the key from the event\n var key = this.getKeyFromEvent_(evt);\n // Early exit if the event key isn't one of the keyboard navigation keys\n if (key === undefined) {\n return;\n }\n // Prevent default behavior for movement keys, but not for activation keys, since :active is used to apply ripple\n if (!this.isActivationKey_(key)) {\n evt.preventDefault();\n }\n if (this.useAutomaticActivation_) {\n if (this.isActivationKey_(key)) {\n return;\n }\n var index = this.determineTargetFromKey_(this.adapter_.getPreviousActiveTabIndex(), key);\n this.adapter_.setActiveTab(index);\n this.scrollIntoView(index);\n }\n else {\n var focusedTabIndex = this.adapter_.getFocusedTabIndex();\n if (this.isActivationKey_(key)) {\n this.adapter_.setActiveTab(focusedTabIndex);\n }\n else {\n var index = this.determineTargetFromKey_(focusedTabIndex, key);\n this.adapter_.focusTabAtIndex(index);\n this.scrollIntoView(index);\n }\n }\n };\n /**\n * Handles the MDCTab:interacted event\n */\n MDCTabBarFoundation.prototype.handleTabInteraction = function (evt) {\n this.adapter_.setActiveTab(this.adapter_.getIndexOfTabById(evt.detail.tabId));\n };\n /**\n * Scrolls the tab at the given index into view\n * @param index The tab index to make visible\n */\n MDCTabBarFoundation.prototype.scrollIntoView = function (index) {\n // Early exit if the index is out of range\n if (!this.indexIsInRange_(index)) {\n return;\n }\n // Always scroll to 0 if scrolling to the 0th index\n if (index === 0) {\n return this.adapter_.scrollTo(0);\n }\n // Always scroll to the max value if scrolling to the Nth index\n // MDCTabScroller.scrollTo() will never scroll past the max possible value\n if (index === this.adapter_.getTabListLength() - 1) {\n return this.adapter_.scrollTo(this.adapter_.getScrollContentWidth());\n }\n if (this.isRTL_()) {\n return this.scrollIntoViewRTL_(index);\n }\n this.scrollIntoView_(index);\n };\n /**\n * Private method for determining the index of the destination tab based on what key was pressed\n * @param origin The original index from which to determine the destination\n * @param key The name of the key\n */\n MDCTabBarFoundation.prototype.determineTargetFromKey_ = function (origin, key) {\n var isRTL = this.isRTL_();\n var maxIndex = this.adapter_.getTabListLength() - 1;\n var shouldGoToEnd = key === strings.END_KEY;\n var shouldDecrement = key === strings.ARROW_LEFT_KEY && !isRTL || key === strings.ARROW_RIGHT_KEY && isRTL;\n var shouldIncrement = key === strings.ARROW_RIGHT_KEY && !isRTL || key === strings.ARROW_LEFT_KEY && isRTL;\n var index = origin;\n if (shouldGoToEnd) {\n index = maxIndex;\n }\n else if (shouldDecrement) {\n index -= 1;\n }\n else if (shouldIncrement) {\n index += 1;\n }\n else {\n index = 0;\n }\n if (index < 0) {\n index = maxIndex;\n }\n else if (index > maxIndex) {\n index = 0;\n }\n return index;\n };\n /**\n * Calculates the scroll increment that will make the tab at the given index visible\n * @param index The index of the tab\n * @param nextIndex The index of the next tab\n * @param scrollPosition The current scroll position\n * @param barWidth The width of the Tab Bar\n */\n MDCTabBarFoundation.prototype.calculateScrollIncrement_ = function (index, nextIndex, scrollPosition, barWidth) {\n var nextTabDimensions = this.adapter_.getTabDimensionsAtIndex(nextIndex);\n var relativeContentLeft = nextTabDimensions.contentLeft - scrollPosition - barWidth;\n var relativeContentRight = nextTabDimensions.contentRight - scrollPosition;\n var leftIncrement = relativeContentRight - numbers.EXTRA_SCROLL_AMOUNT;\n var rightIncrement = relativeContentLeft + numbers.EXTRA_SCROLL_AMOUNT;\n if (nextIndex < index) {\n return Math.min(leftIncrement, 0);\n }\n return Math.max(rightIncrement, 0);\n };\n /**\n * Calculates the scroll increment that will make the tab at the given index visible in RTL\n * @param index The index of the tab\n * @param nextIndex The index of the next tab\n * @param scrollPosition The current scroll position\n * @param barWidth The width of the Tab Bar\n * @param scrollContentWidth The width of the scroll content\n */\n MDCTabBarFoundation.prototype.calculateScrollIncrementRTL_ = function (index, nextIndex, scrollPosition, barWidth, scrollContentWidth) {\n var nextTabDimensions = this.adapter_.getTabDimensionsAtIndex(nextIndex);\n var relativeContentLeft = scrollContentWidth - nextTabDimensions.contentLeft - scrollPosition;\n var relativeContentRight = scrollContentWidth - nextTabDimensions.contentRight - scrollPosition - barWidth;\n var leftIncrement = relativeContentRight + numbers.EXTRA_SCROLL_AMOUNT;\n var rightIncrement = relativeContentLeft - numbers.EXTRA_SCROLL_AMOUNT;\n if (nextIndex > index) {\n return Math.max(leftIncrement, 0);\n }\n return Math.min(rightIncrement, 0);\n };\n /**\n * Determines the index of the adjacent tab closest to either edge of the Tab Bar\n * @param index The index of the tab\n * @param tabDimensions The dimensions of the tab\n * @param scrollPosition The current scroll position\n * @param barWidth The width of the tab bar\n */\n MDCTabBarFoundation.prototype.findAdjacentTabIndexClosestToEdge_ = function (index, tabDimensions, scrollPosition, barWidth) {\n /**\n * Tabs are laid out in the Tab Scroller like this:\n *\n * Scroll Position\n * +---+\n * | | Bar Width\n * | +-----------------------------------+\n * | | |\n * | V V\n * | +-----------------------------------+\n * V | Tab Scroller |\n * +------------+--------------+-------------------+\n * | Tab | Tab | Tab |\n * +------------+--------------+-------------------+\n * | |\n * +-----------------------------------+\n *\n * To determine the next adjacent index, we look at the Tab root left and\n * Tab root right, both relative to the scroll position. If the Tab root\n * left is less than 0, then we know it's out of view to the left. If the\n * Tab root right minus the bar width is greater than 0, we know the Tab is\n * out of view to the right. From there, we either increment or decrement\n * the index.\n */\n var relativeRootLeft = tabDimensions.rootLeft - scrollPosition;\n var relativeRootRight = tabDimensions.rootRight - scrollPosition - barWidth;\n var relativeRootDelta = relativeRootLeft + relativeRootRight;\n var leftEdgeIsCloser = relativeRootLeft < 0 || relativeRootDelta < 0;\n var rightEdgeIsCloser = relativeRootRight > 0 || relativeRootDelta > 0;\n if (leftEdgeIsCloser) {\n return index - 1;\n }\n if (rightEdgeIsCloser) {\n return index + 1;\n }\n return -1;\n };\n /**\n * Determines the index of the adjacent tab closest to either edge of the Tab Bar in RTL\n * @param index The index of the tab\n * @param tabDimensions The dimensions of the tab\n * @param scrollPosition The current scroll position\n * @param barWidth The width of the tab bar\n * @param scrollContentWidth The width of the scroller content\n */\n MDCTabBarFoundation.prototype.findAdjacentTabIndexClosestToEdgeRTL_ = function (index, tabDimensions, scrollPosition, barWidth, scrollContentWidth) {\n var rootLeft = scrollContentWidth - tabDimensions.rootLeft - barWidth - scrollPosition;\n var rootRight = scrollContentWidth - tabDimensions.rootRight - scrollPosition;\n var rootDelta = rootLeft + rootRight;\n var leftEdgeIsCloser = rootLeft > 0 || rootDelta > 0;\n var rightEdgeIsCloser = rootRight < 0 || rootDelta < 0;\n if (leftEdgeIsCloser) {\n return index + 1;\n }\n if (rightEdgeIsCloser) {\n return index - 1;\n }\n return -1;\n };\n /**\n * Returns the key associated with a keydown event\n * @param evt The keydown event\n */\n MDCTabBarFoundation.prototype.getKeyFromEvent_ = function (evt) {\n if (ACCEPTABLE_KEYS.has(evt.key)) {\n return evt.key;\n }\n return KEYCODE_MAP.get(evt.keyCode);\n };\n MDCTabBarFoundation.prototype.isActivationKey_ = function (key) {\n return key === strings.SPACE_KEY || key === strings.ENTER_KEY;\n };\n /**\n * Returns whether a given index is inclusively between the ends\n * @param index The index to test\n */\n MDCTabBarFoundation.prototype.indexIsInRange_ = function (index) {\n return index >= 0 && index < this.adapter_.getTabListLength();\n };\n /**\n * Returns the view's RTL property\n */\n MDCTabBarFoundation.prototype.isRTL_ = function () {\n return this.adapter_.isRTL();\n };\n /**\n * Scrolls the tab at the given index into view for left-to-right user agents.\n * @param index The index of the tab to scroll into view\n */\n MDCTabBarFoundation.prototype.scrollIntoView_ = function (index) {\n var scrollPosition = this.adapter_.getScrollPosition();\n var barWidth = this.adapter_.getOffsetWidth();\n var tabDimensions = this.adapter_.getTabDimensionsAtIndex(index);\n var nextIndex = this.findAdjacentTabIndexClosestToEdge_(index, tabDimensions, scrollPosition, barWidth);\n if (!this.indexIsInRange_(nextIndex)) {\n return;\n }\n var scrollIncrement = this.calculateScrollIncrement_(index, nextIndex, scrollPosition, barWidth);\n this.adapter_.incrementScroll(scrollIncrement);\n };\n /**\n * Scrolls the tab at the given index into view in RTL\n * @param index The tab index to make visible\n */\n MDCTabBarFoundation.prototype.scrollIntoViewRTL_ = function (index) {\n var scrollPosition = this.adapter_.getScrollPosition();\n var barWidth = this.adapter_.getOffsetWidth();\n var tabDimensions = this.adapter_.getTabDimensionsAtIndex(index);\n var scrollWidth = this.adapter_.getScrollContentWidth();\n var nextIndex = this.findAdjacentTabIndexClosestToEdgeRTL_(index, tabDimensions, scrollPosition, barWidth, scrollWidth);\n if (!this.indexIsInRange_(nextIndex)) {\n return;\n }\n var scrollIncrement = this.calculateScrollIncrementRTL_(index, nextIndex, scrollPosition, barWidth, scrollWidth);\n this.adapter_.incrementScroll(scrollIncrement);\n };\n return MDCTabBarFoundation;\n}(MDCFoundation));\nexport { MDCTabBarFoundation };\n// tslint:disable-next-line:no-default-export Needed for backward compatibility with MDC Web v0.44.0 and earlier.\nexport default MDCTabBarFoundation;\n//# sourceMappingURL=foundation.js.map","/**\n * @license\n * Copyright 2018 Google Inc.\n *\n * Permission is hereby granted, free of charge, to any person obtaining a copy\n * of this software and associated documentation files (the \"Software\"), to deal\n * in the Software without restriction, including without limitation the rights\n * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell\n * copies of the Software, and to permit persons to whom the Software is\n * furnished to do so, subject to the following conditions:\n *\n * The above copyright notice and this permission notice shall be included in\n * all copies or substantial portions of the Software.\n *\n * THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\n * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\n * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\n * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\n * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\n * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN\n * THE SOFTWARE.\n */\nimport * as tslib_1 from \"tslib\";\nimport { MDCFoundation } from '@material/base/foundation';\nimport { cssClasses, strings } from './constants';\nvar MDCTabIndicatorFoundation = /** @class */ (function (_super) {\n tslib_1.__extends(MDCTabIndicatorFoundation, _super);\n function MDCTabIndicatorFoundation(adapter) {\n return _super.call(this, tslib_1.__assign({}, MDCTabIndicatorFoundation.defaultAdapter, adapter)) || this;\n }\n Object.defineProperty(MDCTabIndicatorFoundation, \"cssClasses\", {\n get: function () {\n return cssClasses;\n },\n enumerable: true,\n configurable: true\n });\n Object.defineProperty(MDCTabIndicatorFoundation, \"strings\", {\n get: function () {\n return strings;\n },\n enumerable: true,\n configurable: true\n });\n Object.defineProperty(MDCTabIndicatorFoundation, \"defaultAdapter\", {\n get: function () {\n // tslint:disable:object-literal-sort-keys Methods should be in the same order as the adapter interface.\n return {\n addClass: function () { return undefined; },\n removeClass: function () { return undefined; },\n computeContentClientRect: function () { return ({ top: 0, right: 0, bottom: 0, left: 0, width: 0, height: 0 }); },\n setContentStyleProperty: function () { return undefined; },\n };\n // tslint:enable:object-literal-sort-keys\n },\n enumerable: true,\n configurable: true\n });\n MDCTabIndicatorFoundation.prototype.computeContentClientRect = function () {\n return this.adapter_.computeContentClientRect();\n };\n return MDCTabIndicatorFoundation;\n}(MDCFoundation));\nexport { MDCTabIndicatorFoundation };\n// tslint:disable-next-line:no-default-export Needed for backward compatibility with MDC Web v0.44.0 and earlier.\nexport default MDCTabIndicatorFoundation;\n//# sourceMappingURL=foundation.js.map","/**\n * @license\n * Copyright 2018 Google Inc.\n *\n * Permission is hereby granted, free of charge, to any person obtaining a copy\n * of this software and associated documentation files (the \"Software\"), to deal\n * in the Software without restriction, including without limitation the rights\n * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell\n * copies of the Software, and to permit persons to whom the Software is\n * furnished to do so, subject to the following conditions:\n *\n * The above copyright notice and this permission notice shall be included in\n * all copies or substantial portions of the Software.\n *\n * THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\n * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\n * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\n * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\n * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\n * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN\n * THE SOFTWARE.\n */\nimport * as tslib_1 from \"tslib\";\nimport { MDCFoundation } from '@material/base/foundation';\nimport { cssClasses, strings } from './constants';\nimport { MDCTabScrollerRTLDefault } from './rtl-default-scroller';\nimport { MDCTabScrollerRTLNegative } from './rtl-negative-scroller';\nimport { MDCTabScrollerRTLReverse } from './rtl-reverse-scroller';\nvar MDCTabScrollerFoundation = /** @class */ (function (_super) {\n tslib_1.__extends(MDCTabScrollerFoundation, _super);\n function MDCTabScrollerFoundation(adapter) {\n var _this = _super.call(this, tslib_1.__assign({}, MDCTabScrollerFoundation.defaultAdapter, adapter)) || this;\n /**\n * Controls whether we should handle the transitionend and interaction events during the animation.\n */\n _this.isAnimating_ = false;\n return _this;\n }\n Object.defineProperty(MDCTabScrollerFoundation, \"cssClasses\", {\n get: function () {\n return cssClasses;\n },\n enumerable: true,\n configurable: true\n });\n Object.defineProperty(MDCTabScrollerFoundation, \"strings\", {\n get: function () {\n return strings;\n },\n enumerable: true,\n configurable: true\n });\n Object.defineProperty(MDCTabScrollerFoundation, \"defaultAdapter\", {\n get: function () {\n // tslint:disable:object-literal-sort-keys Methods should be in the same order as the adapter interface.\n return {\n eventTargetMatchesSelector: function () { return false; },\n addClass: function () { return undefined; },\n removeClass: function () { return undefined; },\n addScrollAreaClass: function () { return undefined; },\n setScrollAreaStyleProperty: function () { return undefined; },\n setScrollContentStyleProperty: function () { return undefined; },\n getScrollContentStyleValue: function () { return ''; },\n setScrollAreaScrollLeft: function () { return undefined; },\n getScrollAreaScrollLeft: function () { return 0; },\n getScrollContentOffsetWidth: function () { return 0; },\n getScrollAreaOffsetWidth: function () { return 0; },\n computeScrollAreaClientRect: function () { return ({ top: 0, right: 0, bottom: 0, left: 0, width: 0, height: 0 }); },\n computeScrollContentClientRect: function () { return ({ top: 0, right: 0, bottom: 0, left: 0, width: 0, height: 0 }); },\n computeHorizontalScrollbarHeight: function () { return 0; },\n };\n // tslint:enable:object-literal-sort-keys\n },\n enumerable: true,\n configurable: true\n });\n MDCTabScrollerFoundation.prototype.init = function () {\n // Compute horizontal scrollbar height on scroller with overflow initially hidden, then update overflow to scroll\n // and immediately adjust bottom margin to avoid the scrollbar initially appearing before JS runs.\n var horizontalScrollbarHeight = this.adapter_.computeHorizontalScrollbarHeight();\n this.adapter_.setScrollAreaStyleProperty('margin-bottom', -horizontalScrollbarHeight + 'px');\n this.adapter_.addScrollAreaClass(MDCTabScrollerFoundation.cssClasses.SCROLL_AREA_SCROLL);\n };\n /**\n * Computes the current visual scroll position\n */\n MDCTabScrollerFoundation.prototype.getScrollPosition = function () {\n if (this.isRTL_()) {\n return this.computeCurrentScrollPositionRTL_();\n }\n var currentTranslateX = this.calculateCurrentTranslateX_();\n var scrollLeft = this.adapter_.getScrollAreaScrollLeft();\n return scrollLeft - currentTranslateX;\n };\n /**\n * Handles interaction events that occur during transition\n */\n MDCTabScrollerFoundation.prototype.handleInteraction = function () {\n // Early exit if we aren't animating\n if (!this.isAnimating_) {\n return;\n }\n // Prevent other event listeners from handling this event\n this.stopScrollAnimation_();\n };\n /**\n * Handles the transitionend event\n */\n MDCTabScrollerFoundation.prototype.handleTransitionEnd = function (evt) {\n // Early exit if we aren't animating or the event was triggered by a different element.\n var evtTarget = evt.target;\n if (!this.isAnimating_ ||\n !this.adapter_.eventTargetMatchesSelector(evtTarget, MDCTabScrollerFoundation.strings.CONTENT_SELECTOR)) {\n return;\n }\n this.isAnimating_ = false;\n this.adapter_.removeClass(MDCTabScrollerFoundation.cssClasses.ANIMATING);\n };\n /**\n * Increment the scroll value by the scrollXIncrement\n * @param scrollXIncrement The value by which to increment the scroll position\n */\n MDCTabScrollerFoundation.prototype.incrementScroll = function (scrollXIncrement) {\n // Early exit for non-operational increment values\n if (scrollXIncrement === 0) {\n return;\n }\n if (this.isRTL_()) {\n return this.incrementScrollRTL_(scrollXIncrement);\n }\n this.incrementScroll_(scrollXIncrement);\n };\n /**\n * Scrolls to the given scrollX value\n */\n MDCTabScrollerFoundation.prototype.scrollTo = function (scrollX) {\n if (this.isRTL_()) {\n return this.scrollToRTL_(scrollX);\n }\n this.scrollTo_(scrollX);\n };\n /**\n * @return Browser-specific {@link MDCTabScrollerRTL} instance.\n */\n MDCTabScrollerFoundation.prototype.getRTLScroller = function () {\n if (!this.rtlScrollerInstance_) {\n this.rtlScrollerInstance_ = this.rtlScrollerFactory_();\n }\n return this.rtlScrollerInstance_;\n };\n /**\n * @return translateX value from a CSS matrix transform function string.\n */\n MDCTabScrollerFoundation.prototype.calculateCurrentTranslateX_ = function () {\n var transformValue = this.adapter_.getScrollContentStyleValue('transform');\n // Early exit if no transform is present\n if (transformValue === 'none') {\n return 0;\n }\n // The transform value comes back as a matrix transformation in the form\n // of `matrix(a, b, c, d, tx, ty)`. We only care about tx (translateX) so\n // we're going to grab all the parenthesized values, strip out tx, and\n // parse it.\n var match = /\\((.+?)\\)/.exec(transformValue);\n if (!match) {\n return 0;\n }\n var matrixParams = match[1];\n // tslint:disable-next-line:ban-ts-ignore \"Unused vars\" should be a linter warning, not a compiler error.\n // @ts-ignore These unused variables should retain their semantic names for clarity.\n var _a = tslib_1.__read(matrixParams.split(','), 6), a = _a[0], b = _a[1], c = _a[2], d = _a[3], tx = _a[4], ty = _a[5];\n return parseFloat(tx); // tslint:disable-line:ban\n };\n /**\n * Calculates a safe scroll value that is > 0 and < the max scroll value\n * @param scrollX The distance to scroll\n */\n MDCTabScrollerFoundation.prototype.clampScrollValue_ = function (scrollX) {\n var edges = this.calculateScrollEdges_();\n return Math.min(Math.max(edges.left, scrollX), edges.right);\n };\n MDCTabScrollerFoundation.prototype.computeCurrentScrollPositionRTL_ = function () {\n var translateX = this.calculateCurrentTranslateX_();\n return this.getRTLScroller().getScrollPositionRTL(translateX);\n };\n MDCTabScrollerFoundation.prototype.calculateScrollEdges_ = function () {\n var contentWidth = this.adapter_.getScrollContentOffsetWidth();\n var rootWidth = this.adapter_.getScrollAreaOffsetWidth();\n return {\n left: 0,\n right: contentWidth - rootWidth,\n };\n };\n /**\n * Internal scroll method\n * @param scrollX The new scroll position\n */\n MDCTabScrollerFoundation.prototype.scrollTo_ = function (scrollX) {\n var currentScrollX = this.getScrollPosition();\n var safeScrollX = this.clampScrollValue_(scrollX);\n var scrollDelta = safeScrollX - currentScrollX;\n this.animate_({\n finalScrollPosition: safeScrollX,\n scrollDelta: scrollDelta,\n });\n };\n /**\n * Internal RTL scroll method\n * @param scrollX The new scroll position\n */\n MDCTabScrollerFoundation.prototype.scrollToRTL_ = function (scrollX) {\n var animation = this.getRTLScroller().scrollToRTL(scrollX);\n this.animate_(animation);\n };\n /**\n * Internal increment scroll method\n * @param scrollX The new scroll position increment\n */\n MDCTabScrollerFoundation.prototype.incrementScroll_ = function (scrollX) {\n var currentScrollX = this.getScrollPosition();\n var targetScrollX = scrollX + currentScrollX;\n var safeScrollX = this.clampScrollValue_(targetScrollX);\n var scrollDelta = safeScrollX - currentScrollX;\n this.animate_({\n finalScrollPosition: safeScrollX,\n scrollDelta: scrollDelta,\n });\n };\n /**\n * Internal increment scroll RTL method\n * @param scrollX The new scroll position RTL increment\n */\n MDCTabScrollerFoundation.prototype.incrementScrollRTL_ = function (scrollX) {\n var animation = this.getRTLScroller().incrementScrollRTL(scrollX);\n this.animate_(animation);\n };\n /**\n * Animates the tab scrolling\n * @param animation The animation to apply\n */\n MDCTabScrollerFoundation.prototype.animate_ = function (animation) {\n var _this = this;\n // Early exit if translateX is 0, which means there's no animation to perform\n if (animation.scrollDelta === 0) {\n return;\n }\n this.stopScrollAnimation_();\n // This animation uses the FLIP approach.\n // Read more here: https://aerotwist.com/blog/flip-your-animations/\n this.adapter_.setScrollAreaScrollLeft(animation.finalScrollPosition);\n this.adapter_.setScrollContentStyleProperty('transform', \"translateX(\" + animation.scrollDelta + \"px)\");\n // Force repaint\n this.adapter_.computeScrollAreaClientRect();\n requestAnimationFrame(function () {\n _this.adapter_.addClass(MDCTabScrollerFoundation.cssClasses.ANIMATING);\n _this.adapter_.setScrollContentStyleProperty('transform', 'none');\n });\n this.isAnimating_ = true;\n };\n /**\n * Stops scroll animation\n */\n MDCTabScrollerFoundation.prototype.stopScrollAnimation_ = function () {\n this.isAnimating_ = false;\n var currentScrollPosition = this.getAnimatingScrollPosition_();\n this.adapter_.removeClass(MDCTabScrollerFoundation.cssClasses.ANIMATING);\n this.adapter_.setScrollContentStyleProperty('transform', 'translateX(0px)');\n this.adapter_.setScrollAreaScrollLeft(currentScrollPosition);\n };\n /**\n * Gets the current scroll position during animation\n */\n MDCTabScrollerFoundation.prototype.getAnimatingScrollPosition_ = function () {\n var currentTranslateX = this.calculateCurrentTranslateX_();\n var scrollLeft = this.adapter_.getScrollAreaScrollLeft();\n if (this.isRTL_()) {\n return this.getRTLScroller().getAnimatingScrollPosition(scrollLeft, currentTranslateX);\n }\n return scrollLeft - currentTranslateX;\n };\n /**\n * Determines the RTL Scroller to use\n */\n MDCTabScrollerFoundation.prototype.rtlScrollerFactory_ = function () {\n // Browsers have three different implementations of scrollLeft in RTL mode,\n // dependent on the browser. The behavior is based off the max LTR\n // scrollLeft value and 0.\n //\n // * Default scrolling in RTL *\n // - Left-most value: 0\n // - Right-most value: Max LTR scrollLeft value\n //\n // * Negative scrolling in RTL *\n // - Left-most value: Negated max LTR scrollLeft value\n // - Right-most value: 0\n //\n // * Reverse scrolling in RTL *\n // - Left-most value: Max LTR scrollLeft value\n // - Right-most value: 0\n //\n // We use those principles below to determine which RTL scrollLeft\n // behavior is implemented in the current browser.\n var initialScrollLeft = this.adapter_.getScrollAreaScrollLeft();\n this.adapter_.setScrollAreaScrollLeft(initialScrollLeft - 1);\n var newScrollLeft = this.adapter_.getScrollAreaScrollLeft();\n // If the newScrollLeft value is negative,then we know that the browser has\n // implemented negative RTL scrolling, since all other implementations have\n // only positive values.\n if (newScrollLeft < 0) {\n // Undo the scrollLeft test check\n this.adapter_.setScrollAreaScrollLeft(initialScrollLeft);\n return new MDCTabScrollerRTLNegative(this.adapter_);\n }\n var rootClientRect = this.adapter_.computeScrollAreaClientRect();\n var contentClientRect = this.adapter_.computeScrollContentClientRect();\n var rightEdgeDelta = Math.round(contentClientRect.right - rootClientRect.right);\n // Undo the scrollLeft test check\n this.adapter_.setScrollAreaScrollLeft(initialScrollLeft);\n // By calculating the clientRect of the root element and the clientRect of\n // the content element, we can determine how much the scroll value changed\n // when we performed the scrollLeft subtraction above.\n if (rightEdgeDelta === newScrollLeft) {\n return new MDCTabScrollerRTLReverse(this.adapter_);\n }\n return new MDCTabScrollerRTLDefault(this.adapter_);\n };\n MDCTabScrollerFoundation.prototype.isRTL_ = function () {\n return this.adapter_.getScrollContentStyleValue('direction') === 'rtl';\n };\n return MDCTabScrollerFoundation;\n}(MDCFoundation));\nexport { MDCTabScrollerFoundation };\n// tslint:disable-next-line:no-default-export Needed for backward compatibility with MDC Web v0.44.0 and earlier.\nexport default MDCTabScrollerFoundation;\n//# sourceMappingURL=foundation.js.map","/**\n * @license\n * Copyright 2018 Google Inc.\n *\n * Permission is hereby granted, free of charge, to any person obtaining a copy\n * of this software and associated documentation files (the \"Software\"), to deal\n * in the Software without restriction, including without limitation the rights\n * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell\n * copies of the Software, and to permit persons to whom the Software is\n * furnished to do so, subject to the following conditions:\n *\n * The above copyright notice and this permission notice shall be included in\n * all copies or substantial portions of the Software.\n *\n * THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\n * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\n * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\n * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\n * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\n * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN\n * THE SOFTWARE.\n */\nimport * as tslib_1 from \"tslib\";\nimport { MDCFoundation } from '@material/base/foundation';\nimport { cssClasses, strings } from './constants';\nvar MDCTabFoundation = /** @class */ (function (_super) {\n tslib_1.__extends(MDCTabFoundation, _super);\n function MDCTabFoundation(adapter) {\n var _this = _super.call(this, tslib_1.__assign({}, MDCTabFoundation.defaultAdapter, adapter)) || this;\n _this.focusOnActivate_ = true;\n return _this;\n }\n Object.defineProperty(MDCTabFoundation, \"cssClasses\", {\n get: function () {\n return cssClasses;\n },\n enumerable: true,\n configurable: true\n });\n Object.defineProperty(MDCTabFoundation, \"strings\", {\n get: function () {\n return strings;\n },\n enumerable: true,\n configurable: true\n });\n Object.defineProperty(MDCTabFoundation, \"defaultAdapter\", {\n get: function () {\n // tslint:disable:object-literal-sort-keys Methods should be in the same order as the adapter interface.\n return {\n addClass: function () { return undefined; },\n removeClass: function () { return undefined; },\n hasClass: function () { return false; },\n setAttr: function () { return undefined; },\n activateIndicator: function () { return undefined; },\n deactivateIndicator: function () { return undefined; },\n notifyInteracted: function () { return undefined; },\n getOffsetLeft: function () { return 0; },\n getOffsetWidth: function () { return 0; },\n getContentOffsetLeft: function () { return 0; },\n getContentOffsetWidth: function () { return 0; },\n focus: function () { return undefined; },\n };\n // tslint:enable:object-literal-sort-keys\n },\n enumerable: true,\n configurable: true\n });\n MDCTabFoundation.prototype.handleClick = function () {\n // It's up to the parent component to keep track of the active Tab and\n // ensure we don't activate a Tab that's already active.\n this.adapter_.notifyInteracted();\n };\n MDCTabFoundation.prototype.isActive = function () {\n return this.adapter_.hasClass(cssClasses.ACTIVE);\n };\n /**\n * Sets whether the tab should focus itself when activated\n */\n MDCTabFoundation.prototype.setFocusOnActivate = function (focusOnActivate) {\n this.focusOnActivate_ = focusOnActivate;\n };\n /**\n * Activates the Tab\n */\n MDCTabFoundation.prototype.activate = function (previousIndicatorClientRect) {\n this.adapter_.addClass(cssClasses.ACTIVE);\n this.adapter_.setAttr(strings.ARIA_SELECTED, 'true');\n this.adapter_.setAttr(strings.TABINDEX, '0');\n this.adapter_.activateIndicator(previousIndicatorClientRect);\n if (this.focusOnActivate_) {\n this.adapter_.focus();\n }\n };\n /**\n * Deactivates the Tab\n */\n MDCTabFoundation.prototype.deactivate = function () {\n // Early exit\n if (!this.isActive()) {\n return;\n }\n this.adapter_.removeClass(cssClasses.ACTIVE);\n this.adapter_.setAttr(strings.ARIA_SELECTED, 'false');\n this.adapter_.setAttr(strings.TABINDEX, '-1');\n this.adapter_.deactivateIndicator();\n };\n /**\n * Returns the dimensions of the Tab\n */\n MDCTabFoundation.prototype.computeDimensions = function () {\n var rootWidth = this.adapter_.getOffsetWidth();\n var rootLeft = this.adapter_.getOffsetLeft();\n var contentWidth = this.adapter_.getContentOffsetWidth();\n var contentLeft = this.adapter_.getContentOffsetLeft();\n return {\n contentLeft: rootLeft + contentLeft,\n contentRight: rootLeft + contentLeft + contentWidth,\n rootLeft: rootLeft,\n rootRight: rootLeft + rootWidth,\n };\n };\n return MDCTabFoundation;\n}(MDCFoundation));\nexport { MDCTabFoundation };\n// tslint:disable-next-line:no-default-export Needed for backward compatibility with MDC Web v0.44.0 and earlier.\nexport default MDCTabFoundation;\n//# sourceMappingURL=foundation.js.map","/**\n * @license\n * Copyright 2019 Google Inc.\n *\n * Permission is hereby granted, free of charge, to any person obtaining a copy\n * of this software and associated documentation files (the \"Software\"), to deal\n * in the Software without restriction, including without limitation the rights\n * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell\n * copies of the Software, and to permit persons to whom the Software is\n * furnished to do so, subject to the following conditions:\n *\n * The above copyright notice and this permission notice shall be included in\n * all copies or substantial portions of the Software.\n *\n * THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\n * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\n * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\n * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\n * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\n * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN\n * THE SOFTWARE.\n */\nimport * as tslib_1 from \"tslib\";\nimport { MDCFoundation } from '@material/base/foundation';\nimport { cssClasses, strings } from './constants';\nvar MDCTextFieldCharacterCounterFoundation = /** @class */ (function (_super) {\n tslib_1.__extends(MDCTextFieldCharacterCounterFoundation, _super);\n function MDCTextFieldCharacterCounterFoundation(adapter) {\n return _super.call(this, tslib_1.__assign({}, MDCTextFieldCharacterCounterFoundation.defaultAdapter, adapter)) || this;\n }\n Object.defineProperty(MDCTextFieldCharacterCounterFoundation, \"cssClasses\", {\n get: function () {\n return cssClasses;\n },\n enumerable: true,\n configurable: true\n });\n Object.defineProperty(MDCTextFieldCharacterCounterFoundation, \"strings\", {\n get: function () {\n return strings;\n },\n enumerable: true,\n configurable: true\n });\n Object.defineProperty(MDCTextFieldCharacterCounterFoundation, \"defaultAdapter\", {\n /**\n * See {@link MDCTextFieldCharacterCounterAdapter} for typing information on parameters and return types.\n */\n get: function () {\n return {\n setContent: function () { return undefined; },\n };\n },\n enumerable: true,\n configurable: true\n });\n MDCTextFieldCharacterCounterFoundation.prototype.setCounterValue = function (currentLength, maxLength) {\n currentLength = Math.min(currentLength, maxLength);\n this.adapter_.setContent(currentLength + \" / \" + maxLength);\n };\n return MDCTextFieldCharacterCounterFoundation;\n}(MDCFoundation));\nexport { MDCTextFieldCharacterCounterFoundation };\n// tslint:disable-next-line:no-default-export Needed for backward compatibility with MDC Web v0.44.0 and earlier.\nexport default MDCTextFieldCharacterCounterFoundation;\n//# sourceMappingURL=foundation.js.map","/**\n * @license\n * Copyright 2016 Google Inc.\n *\n * Permission is hereby granted, free of charge, to any person obtaining a copy\n * of this software and associated documentation files (the \"Software\"), to deal\n * in the Software without restriction, including without limitation the rights\n * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell\n * copies of the Software, and to permit persons to whom the Software is\n * furnished to do so, subject to the following conditions:\n *\n * The above copyright notice and this permission notice shall be included in\n * all copies or substantial portions of the Software.\n *\n * THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\n * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\n * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\n * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\n * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\n * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN\n * THE SOFTWARE.\n */\nimport * as tslib_1 from \"tslib\";\nimport { MDCFoundation } from '@material/base/foundation';\nimport { ALWAYS_FLOAT_TYPES, cssClasses, numbers, strings, VALIDATION_ATTR_WHITELIST } from './constants';\nvar POINTERDOWN_EVENTS = ['mousedown', 'touchstart'];\nvar INTERACTION_EVENTS = ['click', 'keydown'];\nvar MDCTextFieldFoundation = /** @class */ (function (_super) {\n tslib_1.__extends(MDCTextFieldFoundation, _super);\n /**\n * @param adapter\n * @param foundationMap Map from subcomponent names to their subfoundations.\n */\n function MDCTextFieldFoundation(adapter, foundationMap) {\n if (foundationMap === void 0) { foundationMap = {}; }\n var _this = _super.call(this, tslib_1.__assign({}, MDCTextFieldFoundation.defaultAdapter, adapter)) || this;\n _this.isFocused_ = false;\n _this.receivedUserInput_ = false;\n _this.isValid_ = true;\n _this.useNativeValidation_ = true;\n _this.helperText_ = foundationMap.helperText;\n _this.characterCounter_ = foundationMap.characterCounter;\n _this.leadingIcon_ = foundationMap.leadingIcon;\n _this.trailingIcon_ = foundationMap.trailingIcon;\n _this.inputFocusHandler_ = function () { return _this.activateFocus(); };\n _this.inputBlurHandler_ = function () { return _this.deactivateFocus(); };\n _this.inputInputHandler_ = function () { return _this.handleInput(); };\n _this.setPointerXOffset_ = function (evt) { return _this.setTransformOrigin(evt); };\n _this.textFieldInteractionHandler_ = function () { return _this.handleTextFieldInteraction(); };\n _this.validationAttributeChangeHandler_ = function (attributesList) { return _this.handleValidationAttributeChange(attributesList); };\n return _this;\n }\n Object.defineProperty(MDCTextFieldFoundation, \"cssClasses\", {\n get: function () {\n return cssClasses;\n },\n enumerable: true,\n configurable: true\n });\n Object.defineProperty(MDCTextFieldFoundation, \"strings\", {\n get: function () {\n return strings;\n },\n enumerable: true,\n configurable: true\n });\n Object.defineProperty(MDCTextFieldFoundation, \"numbers\", {\n get: function () {\n return numbers;\n },\n enumerable: true,\n configurable: true\n });\n Object.defineProperty(MDCTextFieldFoundation.prototype, \"shouldAlwaysFloat_\", {\n get: function () {\n var type = this.getNativeInput_().type;\n return ALWAYS_FLOAT_TYPES.indexOf(type) >= 0;\n },\n enumerable: true,\n configurable: true\n });\n Object.defineProperty(MDCTextFieldFoundation.prototype, \"shouldFloat\", {\n get: function () {\n return this.shouldAlwaysFloat_ || this.isFocused_ || Boolean(this.getValue()) || this.isBadInput_();\n },\n enumerable: true,\n configurable: true\n });\n Object.defineProperty(MDCTextFieldFoundation.prototype, \"shouldShake\", {\n get: function () {\n return !this.isFocused_ && !this.isValid() && Boolean(this.getValue());\n },\n enumerable: true,\n configurable: true\n });\n Object.defineProperty(MDCTextFieldFoundation, \"defaultAdapter\", {\n /**\n * See {@link MDCTextFieldAdapter} for typing information on parameters and return types.\n */\n get: function () {\n // tslint:disable:object-literal-sort-keys Methods should be in the same order as the adapter interface.\n return {\n addClass: function () { return undefined; },\n removeClass: function () { return undefined; },\n hasClass: function () { return true; },\n registerTextFieldInteractionHandler: function () { return undefined; },\n deregisterTextFieldInteractionHandler: function () { return undefined; },\n registerInputInteractionHandler: function () { return undefined; },\n deregisterInputInteractionHandler: function () { return undefined; },\n registerValidationAttributeChangeHandler: function () { return new MutationObserver(function () { return undefined; }); },\n deregisterValidationAttributeChangeHandler: function () { return undefined; },\n getNativeInput: function () { return null; },\n isFocused: function () { return false; },\n activateLineRipple: function () { return undefined; },\n deactivateLineRipple: function () { return undefined; },\n setLineRippleTransformOrigin: function () { return undefined; },\n shakeLabel: function () { return undefined; },\n floatLabel: function () { return undefined; },\n hasLabel: function () { return false; },\n getLabelWidth: function () { return 0; },\n hasOutline: function () { return false; },\n notchOutline: function () { return undefined; },\n closeOutline: function () { return undefined; },\n };\n // tslint:enable:object-literal-sort-keys\n },\n enumerable: true,\n configurable: true\n });\n MDCTextFieldFoundation.prototype.init = function () {\n var _this = this;\n if (this.adapter_.isFocused()) {\n this.inputFocusHandler_();\n }\n else if (this.adapter_.hasLabel() && this.shouldFloat) {\n this.notchOutline(true);\n this.adapter_.floatLabel(true);\n }\n this.adapter_.registerInputInteractionHandler('focus', this.inputFocusHandler_);\n this.adapter_.registerInputInteractionHandler('blur', this.inputBlurHandler_);\n this.adapter_.registerInputInteractionHandler('input', this.inputInputHandler_);\n POINTERDOWN_EVENTS.forEach(function (evtType) {\n _this.adapter_.registerInputInteractionHandler(evtType, _this.setPointerXOffset_);\n });\n INTERACTION_EVENTS.forEach(function (evtType) {\n _this.adapter_.registerTextFieldInteractionHandler(evtType, _this.textFieldInteractionHandler_);\n });\n this.validationObserver_ =\n this.adapter_.registerValidationAttributeChangeHandler(this.validationAttributeChangeHandler_);\n this.setCharacterCounter_(this.getValue().length);\n };\n MDCTextFieldFoundation.prototype.destroy = function () {\n var _this = this;\n this.adapter_.deregisterInputInteractionHandler('focus', this.inputFocusHandler_);\n this.adapter_.deregisterInputInteractionHandler('blur', this.inputBlurHandler_);\n this.adapter_.deregisterInputInteractionHandler('input', this.inputInputHandler_);\n POINTERDOWN_EVENTS.forEach(function (evtType) {\n _this.adapter_.deregisterInputInteractionHandler(evtType, _this.setPointerXOffset_);\n });\n INTERACTION_EVENTS.forEach(function (evtType) {\n _this.adapter_.deregisterTextFieldInteractionHandler(evtType, _this.textFieldInteractionHandler_);\n });\n this.adapter_.deregisterValidationAttributeChangeHandler(this.validationObserver_);\n };\n /**\n * Handles user interactions with the Text Field.\n */\n MDCTextFieldFoundation.prototype.handleTextFieldInteraction = function () {\n var nativeInput = this.adapter_.getNativeInput();\n if (nativeInput && nativeInput.disabled) {\n return;\n }\n this.receivedUserInput_ = true;\n };\n /**\n * Handles validation attribute changes\n */\n MDCTextFieldFoundation.prototype.handleValidationAttributeChange = function (attributesList) {\n var _this = this;\n attributesList.some(function (attributeName) {\n if (VALIDATION_ATTR_WHITELIST.indexOf(attributeName) > -1) {\n _this.styleValidity_(true);\n return true;\n }\n return false;\n });\n if (attributesList.indexOf('maxlength') > -1) {\n this.setCharacterCounter_(this.getValue().length);\n }\n };\n /**\n * Opens/closes the notched outline.\n */\n MDCTextFieldFoundation.prototype.notchOutline = function (openNotch) {\n if (!this.adapter_.hasOutline()) {\n return;\n }\n if (openNotch) {\n var isDense = this.adapter_.hasClass(cssClasses.DENSE);\n var labelScale = isDense ? numbers.DENSE_LABEL_SCALE : numbers.LABEL_SCALE;\n var labelWidth = this.adapter_.getLabelWidth() * labelScale;\n this.adapter_.notchOutline(labelWidth);\n }\n else {\n this.adapter_.closeOutline();\n }\n };\n /**\n * Activates the text field focus state.\n */\n MDCTextFieldFoundation.prototype.activateFocus = function () {\n this.isFocused_ = true;\n this.styleFocused_(this.isFocused_);\n this.adapter_.activateLineRipple();\n if (this.adapter_.hasLabel()) {\n this.notchOutline(this.shouldFloat);\n this.adapter_.floatLabel(this.shouldFloat);\n this.adapter_.shakeLabel(this.shouldShake);\n }\n if (this.helperText_) {\n this.helperText_.showToScreenReader();\n }\n };\n /**\n * Sets the line ripple's transform origin, so that the line ripple activate\n * animation will animate out from the user's click location.\n */\n MDCTextFieldFoundation.prototype.setTransformOrigin = function (evt) {\n var touches = evt.touches;\n var targetEvent = touches ? touches[0] : evt;\n var targetClientRect = targetEvent.target.getBoundingClientRect();\n var normalizedX = targetEvent.clientX - targetClientRect.left;\n this.adapter_.setLineRippleTransformOrigin(normalizedX);\n };\n /**\n * Handles input change of text input and text area.\n */\n MDCTextFieldFoundation.prototype.handleInput = function () {\n this.autoCompleteFocus();\n this.setCharacterCounter_(this.getValue().length);\n };\n /**\n * Activates the Text Field's focus state in cases when the input value\n * changes without user input (e.g. programmatically).\n */\n MDCTextFieldFoundation.prototype.autoCompleteFocus = function () {\n if (!this.receivedUserInput_) {\n this.activateFocus();\n }\n };\n /**\n * Deactivates the Text Field's focus state.\n */\n MDCTextFieldFoundation.prototype.deactivateFocus = function () {\n this.isFocused_ = false;\n this.adapter_.deactivateLineRipple();\n var isValid = this.isValid();\n this.styleValidity_(isValid);\n this.styleFocused_(this.isFocused_);\n if (this.adapter_.hasLabel()) {\n this.notchOutline(this.shouldFloat);\n this.adapter_.floatLabel(this.shouldFloat);\n this.adapter_.shakeLabel(this.shouldShake);\n }\n if (!this.shouldFloat) {\n this.receivedUserInput_ = false;\n }\n };\n MDCTextFieldFoundation.prototype.getValue = function () {\n return this.getNativeInput_().value;\n };\n /**\n * @param value The value to set on the input Element.\n */\n MDCTextFieldFoundation.prototype.setValue = function (value) {\n // Prevent Safari from moving the caret to the end of the input when the value has not changed.\n if (this.getValue() !== value) {\n this.getNativeInput_().value = value;\n }\n this.setCharacterCounter_(value.length);\n var isValid = this.isValid();\n this.styleValidity_(isValid);\n if (this.adapter_.hasLabel()) {\n this.notchOutline(this.shouldFloat);\n this.adapter_.floatLabel(this.shouldFloat);\n this.adapter_.shakeLabel(this.shouldShake);\n }\n };\n /**\n * @return The custom validity state, if set; otherwise, the result of a native validity check.\n */\n MDCTextFieldFoundation.prototype.isValid = function () {\n return this.useNativeValidation_\n ? this.isNativeInputValid_() : this.isValid_;\n };\n /**\n * @param isValid Sets the custom validity state of the Text Field.\n */\n MDCTextFieldFoundation.prototype.setValid = function (isValid) {\n this.isValid_ = isValid;\n this.styleValidity_(isValid);\n var shouldShake = !isValid && !this.isFocused_;\n if (this.adapter_.hasLabel()) {\n this.adapter_.shakeLabel(shouldShake);\n }\n };\n /**\n * Enables or disables the use of native validation. Use this for custom validation.\n * @param useNativeValidation Set this to false to ignore native input validation.\n */\n MDCTextFieldFoundation.prototype.setUseNativeValidation = function (useNativeValidation) {\n this.useNativeValidation_ = useNativeValidation;\n };\n MDCTextFieldFoundation.prototype.isDisabled = function () {\n return this.getNativeInput_().disabled;\n };\n /**\n * @param disabled Sets the text-field disabled or enabled.\n */\n MDCTextFieldFoundation.prototype.setDisabled = function (disabled) {\n this.getNativeInput_().disabled = disabled;\n this.styleDisabled_(disabled);\n };\n /**\n * @param content Sets the content of the helper text.\n */\n MDCTextFieldFoundation.prototype.setHelperTextContent = function (content) {\n if (this.helperText_) {\n this.helperText_.setContent(content);\n }\n };\n /**\n * Sets the aria label of the leading icon.\n */\n MDCTextFieldFoundation.prototype.setLeadingIconAriaLabel = function (label) {\n if (this.leadingIcon_) {\n this.leadingIcon_.setAriaLabel(label);\n }\n };\n /**\n * Sets the text content of the leading icon.\n */\n MDCTextFieldFoundation.prototype.setLeadingIconContent = function (content) {\n if (this.leadingIcon_) {\n this.leadingIcon_.setContent(content);\n }\n };\n /**\n * Sets the aria label of the trailing icon.\n */\n MDCTextFieldFoundation.prototype.setTrailingIconAriaLabel = function (label) {\n if (this.trailingIcon_) {\n this.trailingIcon_.setAriaLabel(label);\n }\n };\n /**\n * Sets the text content of the trailing icon.\n */\n MDCTextFieldFoundation.prototype.setTrailingIconContent = function (content) {\n if (this.trailingIcon_) {\n this.trailingIcon_.setContent(content);\n }\n };\n /**\n * Sets character counter values that shows characters used and the total character limit.\n */\n MDCTextFieldFoundation.prototype.setCharacterCounter_ = function (currentLength) {\n if (!this.characterCounter_) {\n return;\n }\n var maxLength = this.getNativeInput_().maxLength;\n if (maxLength === -1) {\n throw new Error('MDCTextFieldFoundation: Expected maxlength html property on text input or textarea.');\n }\n this.characterCounter_.setCounterValue(currentLength, maxLength);\n };\n /**\n * @return True if the Text Field input fails in converting the user-supplied value.\n */\n MDCTextFieldFoundation.prototype.isBadInput_ = function () {\n // The badInput property is not supported in IE 11 💩.\n return this.getNativeInput_().validity.badInput || false;\n };\n /**\n * @return The result of native validity checking (ValidityState.valid).\n */\n MDCTextFieldFoundation.prototype.isNativeInputValid_ = function () {\n return this.getNativeInput_().validity.valid;\n };\n /**\n * Styles the component based on the validity state.\n */\n MDCTextFieldFoundation.prototype.styleValidity_ = function (isValid) {\n var INVALID = MDCTextFieldFoundation.cssClasses.INVALID;\n if (isValid) {\n this.adapter_.removeClass(INVALID);\n }\n else {\n this.adapter_.addClass(INVALID);\n }\n if (this.helperText_) {\n this.helperText_.setValidity(isValid);\n }\n };\n /**\n * Styles the component based on the focused state.\n */\n MDCTextFieldFoundation.prototype.styleFocused_ = function (isFocused) {\n var FOCUSED = MDCTextFieldFoundation.cssClasses.FOCUSED;\n if (isFocused) {\n this.adapter_.addClass(FOCUSED);\n }\n else {\n this.adapter_.removeClass(FOCUSED);\n }\n };\n /**\n * Styles the component based on the disabled state.\n */\n MDCTextFieldFoundation.prototype.styleDisabled_ = function (isDisabled) {\n var _a = MDCTextFieldFoundation.cssClasses, DISABLED = _a.DISABLED, INVALID = _a.INVALID;\n if (isDisabled) {\n this.adapter_.addClass(DISABLED);\n this.adapter_.removeClass(INVALID);\n }\n else {\n this.adapter_.removeClass(DISABLED);\n }\n if (this.leadingIcon_) {\n this.leadingIcon_.setDisabled(isDisabled);\n }\n if (this.trailingIcon_) {\n this.trailingIcon_.setDisabled(isDisabled);\n }\n };\n /**\n * @return The native text input element from the host environment, or an object with the same shape for unit tests.\n */\n MDCTextFieldFoundation.prototype.getNativeInput_ = function () {\n // this.adapter_ may be undefined in foundation unit tests. This happens when testdouble is creating a mock object\n // and invokes the shouldShake/shouldFloat getters (which in turn call getValue(), which calls this method) before\n // init() has been called from the MDCTextField constructor. To work around that issue, we return a dummy object.\n var nativeInput = this.adapter_ ? this.adapter_.getNativeInput() : null;\n return nativeInput || {\n disabled: false,\n maxLength: -1,\n type: 'input',\n validity: {\n badInput: false,\n valid: true,\n },\n value: '',\n };\n };\n return MDCTextFieldFoundation;\n}(MDCFoundation));\nexport { MDCTextFieldFoundation };\n// tslint:disable-next-line:no-default-export Needed for backward compatibility with MDC Web v0.44.0 and earlier.\nexport default MDCTextFieldFoundation;\n//# sourceMappingURL=foundation.js.map","/**\n * @license\n * Copyright 2017 Google Inc.\n *\n * Permission is hereby granted, free of charge, to any person obtaining a copy\n * of this software and associated documentation files (the \"Software\"), to deal\n * in the Software without restriction, including without limitation the rights\n * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell\n * copies of the Software, and to permit persons to whom the Software is\n * furnished to do so, subject to the following conditions:\n *\n * The above copyright notice and this permission notice shall be included in\n * all copies or substantial portions of the Software.\n *\n * THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\n * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\n * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\n * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\n * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\n * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN\n * THE SOFTWARE.\n */\nimport * as tslib_1 from \"tslib\";\nimport { MDCFoundation } from '@material/base/foundation';\nimport { cssClasses, strings } from './constants';\nvar MDCTextFieldHelperTextFoundation = /** @class */ (function (_super) {\n tslib_1.__extends(MDCTextFieldHelperTextFoundation, _super);\n function MDCTextFieldHelperTextFoundation(adapter) {\n return _super.call(this, tslib_1.__assign({}, MDCTextFieldHelperTextFoundation.defaultAdapter, adapter)) || this;\n }\n Object.defineProperty(MDCTextFieldHelperTextFoundation, \"cssClasses\", {\n get: function () {\n return cssClasses;\n },\n enumerable: true,\n configurable: true\n });\n Object.defineProperty(MDCTextFieldHelperTextFoundation, \"strings\", {\n get: function () {\n return strings;\n },\n enumerable: true,\n configurable: true\n });\n Object.defineProperty(MDCTextFieldHelperTextFoundation, \"defaultAdapter\", {\n /**\n * See {@link MDCTextFieldHelperTextAdapter} for typing information on parameters and return types.\n */\n get: function () {\n // tslint:disable:object-literal-sort-keys Methods should be in the same order as the adapter interface.\n return {\n addClass: function () { return undefined; },\n removeClass: function () { return undefined; },\n hasClass: function () { return false; },\n setAttr: function () { return undefined; },\n removeAttr: function () { return undefined; },\n setContent: function () { return undefined; },\n };\n // tslint:enable:object-literal-sort-keys\n },\n enumerable: true,\n configurable: true\n });\n /**\n * Sets the content of the helper text field.\n */\n MDCTextFieldHelperTextFoundation.prototype.setContent = function (content) {\n this.adapter_.setContent(content);\n };\n /**\n * @param isPersistent Sets the persistency of the helper text.\n */\n MDCTextFieldHelperTextFoundation.prototype.setPersistent = function (isPersistent) {\n if (isPersistent) {\n this.adapter_.addClass(cssClasses.HELPER_TEXT_PERSISTENT);\n }\n else {\n this.adapter_.removeClass(cssClasses.HELPER_TEXT_PERSISTENT);\n }\n };\n /**\n * @param isValidation True to make the helper text act as an error validation message.\n */\n MDCTextFieldHelperTextFoundation.prototype.setValidation = function (isValidation) {\n if (isValidation) {\n this.adapter_.addClass(cssClasses.HELPER_TEXT_VALIDATION_MSG);\n }\n else {\n this.adapter_.removeClass(cssClasses.HELPER_TEXT_VALIDATION_MSG);\n }\n };\n /**\n * Makes the helper text visible to the screen reader.\n */\n MDCTextFieldHelperTextFoundation.prototype.showToScreenReader = function () {\n this.adapter_.removeAttr(strings.ARIA_HIDDEN);\n };\n /**\n * Sets the validity of the helper text based on the input validity.\n */\n MDCTextFieldHelperTextFoundation.prototype.setValidity = function (inputIsValid) {\n var helperTextIsPersistent = this.adapter_.hasClass(cssClasses.HELPER_TEXT_PERSISTENT);\n var helperTextIsValidationMsg = this.adapter_.hasClass(cssClasses.HELPER_TEXT_VALIDATION_MSG);\n var validationMsgNeedsDisplay = helperTextIsValidationMsg && !inputIsValid;\n if (validationMsgNeedsDisplay) {\n this.adapter_.setAttr(strings.ROLE, 'alert');\n }\n else {\n this.adapter_.removeAttr(strings.ROLE);\n }\n if (!helperTextIsPersistent && !validationMsgNeedsDisplay) {\n this.hide_();\n }\n };\n /**\n * Hides the help text from screen readers.\n */\n MDCTextFieldHelperTextFoundation.prototype.hide_ = function () {\n this.adapter_.setAttr(strings.ARIA_HIDDEN, 'true');\n };\n return MDCTextFieldHelperTextFoundation;\n}(MDCFoundation));\nexport { MDCTextFieldHelperTextFoundation };\n// tslint:disable-next-line:no-default-export Needed for backward compatibility with MDC Web v0.44.0 and earlier.\nexport default MDCTextFieldHelperTextFoundation;\n//# sourceMappingURL=foundation.js.map","/**\n * @license\n * Copyright 2017 Google Inc.\n *\n * Permission is hereby granted, free of charge, to any person obtaining a copy\n * of this software and associated documentation files (the \"Software\"), to deal\n * in the Software without restriction, including without limitation the rights\n * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell\n * copies of the Software, and to permit persons to whom the Software is\n * furnished to do so, subject to the following conditions:\n *\n * The above copyright notice and this permission notice shall be included in\n * all copies or substantial portions of the Software.\n *\n * THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\n * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\n * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\n * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\n * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\n * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN\n * THE SOFTWARE.\n */\nimport * as tslib_1 from \"tslib\";\nimport { MDCFoundation } from '@material/base/foundation';\nimport { cssClasses, strings } from './constants';\nvar INTERACTION_EVENTS = ['click', 'keydown'];\nvar MDCTextFieldIconFoundation = /** @class */ (function (_super) {\n tslib_1.__extends(MDCTextFieldIconFoundation, _super);\n function MDCTextFieldIconFoundation(adapter) {\n var _this = _super.call(this, tslib_1.__assign({}, MDCTextFieldIconFoundation.defaultAdapter, adapter)) || this;\n _this.savedTabIndex_ = null;\n _this.interactionHandler_ = function (evt) { return _this.handleInteraction(evt); };\n return _this;\n }\n Object.defineProperty(MDCTextFieldIconFoundation, \"strings\", {\n get: function () {\n return strings;\n },\n enumerable: true,\n configurable: true\n });\n Object.defineProperty(MDCTextFieldIconFoundation, \"cssClasses\", {\n get: function () {\n return cssClasses;\n },\n enumerable: true,\n configurable: true\n });\n Object.defineProperty(MDCTextFieldIconFoundation, \"defaultAdapter\", {\n /**\n * See {@link MDCTextFieldIconAdapter} for typing information on parameters and return types.\n */\n get: function () {\n // tslint:disable:object-literal-sort-keys Methods should be in the same order as the adapter interface.\n return {\n getAttr: function () { return null; },\n setAttr: function () { return undefined; },\n removeAttr: function () { return undefined; },\n setContent: function () { return undefined; },\n registerInteractionHandler: function () { return undefined; },\n deregisterInteractionHandler: function () { return undefined; },\n notifyIconAction: function () { return undefined; },\n };\n // tslint:enable:object-literal-sort-keys\n },\n enumerable: true,\n configurable: true\n });\n MDCTextFieldIconFoundation.prototype.init = function () {\n var _this = this;\n this.savedTabIndex_ = this.adapter_.getAttr('tabindex');\n INTERACTION_EVENTS.forEach(function (evtType) {\n _this.adapter_.registerInteractionHandler(evtType, _this.interactionHandler_);\n });\n };\n MDCTextFieldIconFoundation.prototype.destroy = function () {\n var _this = this;\n INTERACTION_EVENTS.forEach(function (evtType) {\n _this.adapter_.deregisterInteractionHandler(evtType, _this.interactionHandler_);\n });\n };\n MDCTextFieldIconFoundation.prototype.setDisabled = function (disabled) {\n if (!this.savedTabIndex_) {\n return;\n }\n if (disabled) {\n this.adapter_.setAttr('tabindex', '-1');\n this.adapter_.removeAttr('role');\n }\n else {\n this.adapter_.setAttr('tabindex', this.savedTabIndex_);\n this.adapter_.setAttr('role', strings.ICON_ROLE);\n }\n };\n MDCTextFieldIconFoundation.prototype.setAriaLabel = function (label) {\n this.adapter_.setAttr('aria-label', label);\n };\n MDCTextFieldIconFoundation.prototype.setContent = function (content) {\n this.adapter_.setContent(content);\n };\n MDCTextFieldIconFoundation.prototype.handleInteraction = function (evt) {\n var isEnterKey = evt.key === 'Enter' || evt.keyCode === 13;\n if (evt.type === 'click' || isEnterKey) {\n this.adapter_.notifyIconAction();\n }\n };\n return MDCTextFieldIconFoundation;\n}(MDCFoundation));\nexport { MDCTextFieldIconFoundation };\n// tslint:disable-next-line:no-default-export Needed for backward compatibility with MDC Web v0.44.0 and earlier.\nexport default MDCTextFieldIconFoundation;\n//# sourceMappingURL=foundation.js.map"],"names":["MDCCheckboxFoundation","_super","adapter","_this","call","this","defaultAdapter","currentCheckState_","currentAnimationClass_","animEndLatchTimer_","enableAnimationEndHandler_","Object","defineProperty","get","enumerable","configurable","addClass","forceLayout","hasNativeControl","isAttachedToDOM","isChecked","isIndeterminate","removeClass","removeNativeControlAttr","setNativeControlAttr","setNativeControlDisabled","prototype","init","determineCheckState_","updateAriaChecked_","adapter_","destroy","clearTimeout","setDisabled","disabled","handleAnimationEnd","setTimeout","handleChange","transitionCheckState_","oldState","newState","TRANSITION_STATE_UNCHECKED","SELECTED","length","getTransitionAnimationClass_","TRANSITION_STATE_INDETERMINATE","TRANSITION_STATE_CHECKED","TRANSITION_STATE_INIT","_a","cssClasses","ANIM_UNCHECKED_CHECKED","ANIM_UNCHECKED_INDETERMINATE","ANIM_CHECKED_UNCHECKED","ANIM_CHECKED_INDETERMINATE","ANIM_INDETERMINATE_CHECKED","ANIM_INDETERMINATE_UNCHECKED","MDCFloatingLabelFoundation","shakeAnimationEndHandler_","handleShakeAnimationEnd_","getWidth","registerInteractionHandler","deregisterInteractionHandler","shake","shouldShake","LABEL_SHAKE","float","shouldFloat","LABEL_FLOAT_ABOVE","MDCFormFieldFoundation","clickHandler_","handleClick_","activateInputRipple","deactivateInputRipple","requestAnimationFrame","MDCLineRippleFoundation","transitionEndHandler_","evt","handleTransitionEnd","hasClass","setStyle","registerEventHandler","deregisterEventHandler","activate","setRippleCenter","xCoordinate","deactivate","isDeactivating","propertyName","ELEMENTS_KEY_ALLOWED_IN","MDCListFoundation","wrapFocus_","isVertical_","isSingleSelectionList_","selectedIndex_","focusedItemIndex_","useActivatedClass_","ariaCurrentAttrValue_","isCheckboxList_","isRadioList_","addClassForElementIndex","focusItemAtIndex","getAttributeForElementIndex","getFocusedElementIndex","getListItemCount","hasCheckboxAtIndex","hasRadioAtIndex","isCheckboxCheckedAtIndex","isFocusInsideList","isRootFocused","notifyAction","removeClassForElementIndex","setAttributeForElementIndex","setCheckedCheckboxOrRadioAtIndex","setTabIndexForListItemChildren","layout","setWrapFocus","value","setVerticalOrientation","setSingleSelection","setUseActivatedClass","useActivated","getSelectedIndex","setSelectedIndex","index","isIndexValid_","setCheckboxAtIndex_","setRadioAtIndex_","setSingleSelectionAtIndex_","handleFocusIn","_","listItemIndex","handleFocusOut","setTabindexToFirstSelectedItem_","handleKeydown","isRootListItem","isArrowLeft","key","keyCode","isArrowUp","isArrowRight","isArrowDown","isHome","isEnd","isEnter","isSpace","preventDefault","focusLastElement","focusFirstElement","currentIndex","nextIndex","preventDefaultEvent_","focusNextElement","focusPrevElement","target","tagName","isSelectableList_","setSelectedIndexOnAction_","undefined","setTabindexAtIndex_","handleClick","toggleCheckbox","prevIndex","lastIndex","toLowerCase","indexOf","selectedClassName","setAriaForSingleSelectionAtIndex_","isAriaCurrent","ariaAttribute","ariaAttributeValue","i","targetIndex","Array","reduce","minIndex","Math","min","Error","some","isIndexInRange_","listSize","toggleCheckboxAtIndex_","selectedIndexes","slice","push","filter","MDCMenuSurfaceFoundation","isOpen_","isQuickOpen_","isHoistedElement_","isFixedPosition_","openAnimationEndTimerId_","closeAnimationEndTimerId_","animationRequestId_","anchorCorner_","anchorMargin_","top","right","bottom","left","position_","x","y","hasAnchor","isElementInContainer","isFocused","isRtl","getInnerDimensions","height","width","getAnchorDimensions","getWindowDimensions","getBodyDimensions","getWindowScroll","setPosition","setMaxHeight","setTransformOrigin","saveFocus","restoreFocus","notifyClose","notifyOpen","ROOT","OPEN","cancelAnimationFrame","setAnchorCorner","corner","setAnchorMargin","margin","setIsHoisted","isHoisted","setFixedPosition","isFixedPosition","setAbsolutePosition","isFinite_","setQuickOpen","quickOpen","isOpen","open","ANIMATING_OPEN","dimensions_","autoPosition_","close","skipRestoreFocus","ANIMATING_CLOSED","maybeRestoreFocus_","handleBodyClick","el","measurements_","getAutoLayoutMeasurements_","getOriginCorner_","maxMenuSurfaceHeight","getMenuSurfaceMaxHeight_","verticalAlignment","hasBit_","horizontalAlignment","horizontalOffset","getHorizontalOriginOffset_","verticalOffset","getVerticalOriginOffset_","_b","anchorSize","surfaceSize","position","adjustPositionForHoistedElement_","anchorRect","bodySize","viewportSize","windowScroll","viewportDistance","isBottomAligned","availableTop","availableBottom","topOverflow","bottomOverflow","setBit_","isFlipRtl","avoidHorizontalOverlap","isAlignedRight","availableLeft","availableRight","leftOverflow","rightOverflow","maxHeight","isBottomAnchored","MARGIN_TO_EDGE","numbers","isRightAligned","rightOffset","avoidVerticalOverlap","e_1","props","keys","props_1","props_1_1","next","done","prop","e_1_1","error","return","childHasFocus","document","activeElement","bit","Boolean","num","isFinite","MDCMenuFoundation","defaultFocusState_","addClassToElementAtIndex","removeClassFromElementAtIndex","addAttributeToElementAtIndex","removeAttributeFromElementAtIndex","elementContainsClass","closeSurface","getElementIndex","notifySelected","getMenuItemCount","focusListRoot","getSelectedSiblingOfItemAtIndex","isSelectableItemAtIndex","handleItemAction","listItem","handleMenuSurfaceOpened","setDefaultFocusState","focusState","validatedIndex_","prevSelectedIndex","menuSize","MDCNotchedOutlineFoundation","setNotchWidthProperty","removeNotchWidthProperty","notch","notchWidth","OUTLINE_NOTCHED","closeNotch","ACTIVATION_EVENT_TYPES","POINTER_DEACTIVATION_EVENT_TYPES","activatedTargets","MDCRippleFoundation","activationAnimationHasEnded_","activationTimer_","fgDeactivationRemovalTimer_","fgScale_","frame_","initialSize_","layoutFrame_","maxRadius_","unboundedCoords_","activationState_","defaultActivationState_","activationTimerCallback_","runDeactivationUXLogicIfReady_","activateHandler_","e","activate_","deactivateHandler_","deactivate_","focusHandler_","handleFocus","blurHandler_","handleBlur","resizeHandler_","browserSupportsCssVars","computeBoundingRect","containsEventTarget","deregisterDocumentInteractionHandler","deregisterResizeHandler","getWindowPageOffset","isSurfaceActive","isSurfaceDisabled","isUnbounded","registerDocumentInteractionHandler","registerResizeHandler","updateCssVariable","supportsPressRipple","supportsPressRipple_","registerRootHandlers_","ROOT_1","UNBOUNDED_1","UNBOUNDED","layoutInternal_","FG_ACTIVATION","FG_DEACTIVATION","ROOT_2","UNBOUNDED_2","removeCssVars_","deregisterRootHandlers_","deregisterDeactivationHandlers_","setUnbounded","unbounded","BG_FOCUSED","activationEvent","hasDeactivationUXRun","isActivated","isProgrammatic","wasActivatedByPointer","wasElementMadeActive","forEach","evtType","registerDeactivationHandlers_","type","rippleStrings","strings","activationState","previousActivationEvent","previousActivationEvent_","resetActivationState_","checkElementMadeActive_","animateActivation_","VAR_FG_TRANSLATE_START","VAR_FG_TRANSLATE_END","DEACTIVATION_TIMEOUT_MS","translateStart","translateEnd","_c","getFgTranslationCoordinates_","startPoint","endPoint","rmBoundedActivationClasses_","TAP_DELAY_MS","state","animateDeactivation_","maxDim","max","sqrt","pow","PADDING","floor","INITIAL_ORIGIN_SCALE","updateLayoutCssVars_","VAR_FG_SIZE","VAR_LEFT","VAR_TOP","VAR_FG_SCALE","round","ACCEPTABLE_KEYS","Set","add","KEYCODE_MAP","Map","set","MDCTabBarFoundation","useAutomaticActivation_","scrollTo","incrementScroll","getScrollPosition","getScrollContentWidth","getOffsetWidth","isRTL","setActiveTab","activateTabAtIndex","deactivateTabAtIndex","focusTabAtIndex","getTabIndicatorClientRectAtIndex","getTabDimensionsAtIndex","rootLeft","rootRight","contentLeft","contentRight","getPreviousActiveTabIndex","getFocusedTabIndex","getIndexOfTabById","getTabListLength","notifyTabActivated","setUseAutomaticActivation","useAutomaticActivation","activateTab","previousClientRect","previousActiveIndex","indexIsInRange_","scrollIntoView","handleKeyDown","getKeyFromEvent_","isActivationKey_","determineTargetFromKey_","focusedTabIndex","handleTabInteraction","detail","tabId","isRTL_","scrollIntoViewRTL_","scrollIntoView_","origin","maxIndex","shouldGoToEnd","shouldDecrement","shouldIncrement","calculateScrollIncrement_","scrollPosition","barWidth","nextTabDimensions","relativeContentLeft","leftIncrement","rightIncrement","calculateScrollIncrementRTL_","scrollContentWidth","findAdjacentTabIndexClosestToEdge_","tabDimensions","relativeRootLeft","relativeRootRight","relativeRootDelta","findAdjacentTabIndexClosestToEdgeRTL_","rootDelta","has","scrollIncrement","scrollWidth","MDCTabIndicatorFoundation","computeContentClientRect","setContentStyleProperty","MDCTabScrollerFoundation","isAnimating_","eventTargetMatchesSelector","addScrollAreaClass","setScrollAreaStyleProperty","setScrollContentStyleProperty","getScrollContentStyleValue","setScrollAreaScrollLeft","getScrollAreaScrollLeft","getScrollContentOffsetWidth","getScrollAreaOffsetWidth","computeScrollAreaClientRect","computeScrollContentClientRect","computeHorizontalScrollbarHeight","horizontalScrollbarHeight","SCROLL_AREA_SCROLL","computeCurrentScrollPositionRTL_","currentTranslateX","calculateCurrentTranslateX_","handleInteraction","stopScrollAnimation_","evtTarget","CONTENT_SELECTOR","ANIMATING","scrollXIncrement","incrementScrollRTL_","incrementScroll_","scrollX","scrollToRTL_","scrollTo_","getRTLScroller","rtlScrollerInstance_","rtlScrollerFactory_","transformValue","match","exec","matrixParams","split","tx","parseFloat","clampScrollValue_","edges","calculateScrollEdges_","translateX","getScrollPositionRTL","currentScrollX","safeScrollX","scrollDelta","animate_","finalScrollPosition","animation","scrollToRTL","targetScrollX","incrementScrollRTL","currentScrollPosition","getAnimatingScrollPosition_","scrollLeft","getAnimatingScrollPosition","initialScrollLeft","newScrollLeft","rootClientRect","contentClientRect","rightEdgeDelta","MDCTabFoundation","focusOnActivate_","setAttr","activateIndicator","deactivateIndicator","notifyInteracted","getOffsetLeft","getContentOffsetLeft","getContentOffsetWidth","focus","isActive","setFocusOnActivate","focusOnActivate","previousIndicatorClientRect","computeDimensions","rootWidth","contentWidth","MDCTextFieldCharacterCounterFoundation","setContent","setCounterValue","currentLength","maxLength","POINTERDOWN_EVENTS","INTERACTION_EVENTS","MDCTextFieldFoundation","foundationMap","isFocused_","receivedUserInput_","isValid_","useNativeValidation_","helperText_","helperText","characterCounter_","characterCounter","leadingIcon_","leadingIcon","trailingIcon_","trailingIcon","inputFocusHandler_","activateFocus","inputBlurHandler_","deactivateFocus","inputInputHandler_","handleInput","setPointerXOffset_","textFieldInteractionHandler_","handleTextFieldInteraction","validationAttributeChangeHandler_","attributesList","handleValidationAttributeChange","getNativeInput_","shouldAlwaysFloat_","getValue","isBadInput_","isValid","registerTextFieldInteractionHandler","deregisterTextFieldInteractionHandler","registerInputInteractionHandler","deregisterInputInteractionHandler","registerValidationAttributeChangeHandler","MutationObserver","deregisterValidationAttributeChangeHandler","getNativeInput","activateLineRipple","deactivateLineRipple","setLineRippleTransformOrigin","shakeLabel","floatLabel","hasLabel","getLabelWidth","hasOutline","notchOutline","closeOutline","validationObserver_","setCharacterCounter_","nativeInput","attributeName","styleValidity_","openNotch","labelScale","labelWidth","styleFocused_","showToScreenReader","touches","targetEvent","targetClientRect","getBoundingClientRect","normalizedX","clientX","autoCompleteFocus","setValue","isNativeInputValid_","setValid","setUseNativeValidation","useNativeValidation","isDisabled","styleDisabled_","setHelperTextContent","content","setLeadingIconAriaLabel","label","setAriaLabel","setLeadingIconContent","setTrailingIconAriaLabel","setTrailingIconContent","validity","badInput","valid","INVALID","setValidity","FOCUSED","DISABLED","MDCTextFieldHelperTextFoundation","removeAttr","setPersistent","isPersistent","setValidation","isValidation","inputIsValid","helperTextIsPersistent","validationMsgNeedsDisplay","hide_","MDCTextFieldIconFoundation","savedTabIndex_","interactionHandler_","getAttr","notifyIconAction","isEnterKey"],"sourceRoot":""}