{"version":3,"sources":["webpack:///./node_modules/@ionic/core/dist/esm-es5/theme-18cbe2cc.js","webpack:///./node_modules/@ionic/core/dist/esm-es5/ion-textarea-ios.entry.js"],"names":["hostContext","selector","el","closest","createColorClasses","color","_a","length","undefined","getClassMap","classes","map","Array","isArray","split","filter","c","trim","forEach","SCHEME","openURL","url","ev","direction","router","this","test","document","querySelector","preventDefault","push","Textarea","class_1","prototype","debounceChanged","ionChange","debounce","disabledChanged","emitStyle","valueChanged","nativeInput","value","getValue","runAutoGrow","emit","connectedCallback","dispatchEvent","CustomEvent","detail","disconnectedCallback","componentDidLoad","autoGrow","style","height","scrollHeight","setFocus","focus","getInputElement","Promise","resolve","ionStyle","disabled","placeholder","hasValue","hasFocus","checkClearOnEdit","clearOnEdit","didBlurAfterEdit","focusChange","render","_this","mode","labelId","inputId","label","id","class","Object","assign","ref","autoCapitalize","autocapitalize","autoFocus","autofocus","maxLength","maxlength","minLength","minlength","name","readOnly","readonly","required","spellCheck","spellcheck","cols","rows","wrap","onInput","onBlur","onFocus","onKeyDown","defineProperty","get","enumerable","configurable","hostRef","textareaIds","ionInput","ionFocus","ionBlur"],"mappings":"+FAAA,gJACIA,EAAc,SAAUC,EAAUC,GAClC,OAAgC,OAAzBA,EAAGC,QAAQF,CAAQ,CAC9B,EAIIG,EAAqB,SAAUC,GAC/B,IAAIC,EACJ,MAAyB,UAAjB,OAAOD,GAAqC,EAAfA,EAAME,SAAeD,EAAK,CACvD,YAAa,EACjB,GACG,aAAeD,GAAS,GAC3BC,GAAME,MACd,EAWIC,EAAc,SAAUC,GACxB,IAAIC,EAAM,GAEV,OAZgBH,UADSE,EAYZA,IAVGE,MAAMC,QAAQH,CAAO,EAAIA,EAAUA,EAAQI,MAAM,GAAG,GAE3DC,OAAO,SAAUC,GAAK,OAAY,MAALA,CAAW,CAAC,EACzCL,IAAI,SAAUK,GAAK,OAAOA,EAAEC,KAAK,CAAG,CAAC,EACrCF,OAAO,SAAUC,GAAK,MAAa,KAANA,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ACb,IAAInC,EAAQ7C,KACZ,YAAiBA,KAAMgF,CAAO,EAC9BhF,KAAKgD,QAAU,aAAeiC,CAAW,GACzCjF,KAAK0C,iBAAmB,GACxB1C,KAAKuC,SAAW,GAIhBvC,KAAKwD,eAAiB,OAItBxD,KAAK0D,UAAY,GAIjB1D,KAAKyC,YAAc,GAInBzC,KAAKW,SAAW,EAIhBX,KAAKoC,SAAW,GAIhBpC,KAAK+D,KAAO/D,KAAKgD,QAIjBhD,KAAKiE,SAAW,GAIhBjE,KAAKkE,SAAW,GAIhBlE,KAAKoE,WAAa,GAIlBpE,KAAK0B,SAAW,GAIhB1B,KAAKgB,MAAQ,GACbhB,KAAKwE,QAAU,SAAU3E,GACjBgD,EAAM9B,cACN8B,EAAM7B,MAAQ6B,EAAM9B,YAAYC,OAEpC6B,EAAMhC,UAAU,EAChBgC,EAAMqC,SAAS/D,KAAKtB,CAAE,CAC1B,EACAG,KAAK0E,QAAU,WACX7B,EAAMN,SAAW,GACjBM,EAAMF,YAAY,EAClBE,EAAMsC,SAAShE,KAAK,CACxB,EACAnB,KAAKyE,OAAS,WACV5B,EAAMN,SAAW,GACjBM,EAAMF,YAAY,EAClBE,EAAMuC,QAAQjE,KAAK,CACvB,EACAnB,KAAK2E,UAAY,WACb9B,EAAML,iBAAiB,CAC3B,EACAxC,KAAKU,UAAY,YAAYV,KAAM,YAAa,CAAC,EACjDA,KAAKkF,SAAW,YAAYlF,KAAM,WAAY,CAAC,EAC/CA,KAAKmC,SAAW,YAAYnC,KAAM,WAAY,CAAC,EAC/CA,KAAKoF,QAAU,YAAYpF,KAAM,UAAW,CAAC,EAC7CA,KAAKmF,SAAW,YAAYnF,KAAM,WAAY,CAAC,CACnD,CA+IJ,IAAIiF,EAAc,C","file":"js/chunk-451c033d.a9c08dcf.js","sourcesContent":["import { __awaiter, __generator } from \"tslib\";\nvar hostContext = function (selector, el) {\n return el.closest(selector) !== null;\n};\n/**\n * Create the mode and color classes for the component based on the classes passed in\n */\nvar createColorClasses = function (color) {\n var _a;\n return (typeof color === 'string' && color.length > 0) ? (_a = {\n 'ion-color': true\n },\n _a[\"ion-color-\" + color] = true,\n _a) : undefined;\n};\nvar getClassList = function (classes) {\n if (classes !== undefined) {\n var array = Array.isArray(classes) ? classes : classes.split(' ');\n return array\n .filter(function (c) { return c != null; })\n .map(function (c) { return c.trim(); })\n .filter(function (c) { return c !== ''; });\n }\n return [];\n};\nvar getClassMap = function (classes) {\n var map = {};\n getClassList(classes).forEach(function (c) { return map[c] = true; });\n return map;\n};\nvar SCHEME = /^[a-z][a-z0-9+\\-.]*:/;\nvar openURL = function (url, ev, direction) { return __awaiter(void 0, void 0, void 0, function () {\n var router;\n return __generator(this, function (_a) {\n if (url != null && url[0] !== '#' && !SCHEME.test(url)) {\n router = document.querySelector('ion-router');\n if (router) {\n if (ev != null) {\n ev.preventDefault();\n }\n return [2 /*return*/, router.push(url, direction)];\n }\n }\n return [2 /*return*/, false];\n });\n}); };\nexport { createColorClasses as c, getClassMap as g, hostContext as h, openURL as o };\n","import { __awaiter, __generator } from \"tslib\";\nimport { r as registerInstance, d as createEvent, f as readTask, c as getIonMode, h, H as Host, e as getElement } from './core-feeeff0d.js';\nimport './config-3c7f3790.js';\nimport { d as debounceEvent, f as findItemLabel } from './helpers-46f4a262.js';\nimport { c as createColorClasses } from './theme-18cbe2cc.js';\nvar Textarea = /** @class */ (function () {\n function class_1(hostRef) {\n var _this = this;\n registerInstance(this, hostRef);\n this.inputId = \"ion-input-\" + textareaIds++;\n this.didBlurAfterEdit = false;\n this.hasFocus = false;\n /**\n * Indicates whether and how the text value should be automatically capitalized as it is entered/edited by the user.\n */\n this.autocapitalize = 'none';\n /**\n * This Boolean attribute lets you specify that a form control should have input focus when the page loads.\n */\n this.autofocus = false;\n /**\n * If `true`, the value will be cleared after focus upon edit. Defaults to `true` when `type` is `\"password\"`, `false` for all other types.\n */\n this.clearOnEdit = false;\n /**\n * Set the amount of time, in milliseconds, to wait to trigger the `ionChange` event after each keystroke.\n */\n this.debounce = 0;\n /**\n * If `true`, the user cannot interact with the textarea.\n */\n this.disabled = false;\n /**\n * The name of the control, which is submitted with the form data.\n */\n this.name = this.inputId;\n /**\n * If `true`, the user cannot modify the value.\n */\n this.readonly = false;\n /**\n * If `true`, the user must fill in a value before submitting a form.\n */\n this.required = false;\n /**\n * If `true`, the element will have its spelling and grammar checked.\n */\n this.spellcheck = false;\n /**\n * If `true`, the element height will increase based on the value.\n */\n this.autoGrow = false;\n /**\n * The value of the textarea.\n */\n this.value = '';\n this.onInput = function (ev) {\n if (_this.nativeInput) {\n _this.value = _this.nativeInput.value;\n }\n _this.emitStyle();\n _this.ionInput.emit(ev);\n };\n this.onFocus = function () {\n _this.hasFocus = true;\n _this.focusChange();\n _this.ionFocus.emit();\n };\n this.onBlur = function () {\n _this.hasFocus = false;\n _this.focusChange();\n _this.ionBlur.emit();\n };\n this.onKeyDown = function () {\n _this.checkClearOnEdit();\n };\n this.ionChange = createEvent(this, \"ionChange\", 7);\n this.ionInput = createEvent(this, \"ionInput\", 7);\n this.ionStyle = createEvent(this, \"ionStyle\", 7);\n this.ionBlur = createEvent(this, \"ionBlur\", 7);\n this.ionFocus = createEvent(this, \"ionFocus\", 7);\n }\n class_1.prototype.debounceChanged = function () {\n this.ionChange = debounceEvent(this.ionChange, this.debounce);\n };\n class_1.prototype.disabledChanged = function () {\n this.emitStyle();\n };\n /**\n * Update the native input element when the value changes\n */\n class_1.prototype.valueChanged = function () {\n var nativeInput = this.nativeInput;\n var value = this.getValue();\n if (nativeInput && nativeInput.value !== value) {\n nativeInput.value = value;\n }\n this.runAutoGrow();\n this.emitStyle();\n this.ionChange.emit({ value: value });\n };\n class_1.prototype.connectedCallback = function () {\n this.emitStyle();\n this.debounceChanged();\n {\n this.el.dispatchEvent(new CustomEvent('ionInputDidLoad', {\n detail: this.el\n }));\n }\n };\n class_1.prototype.disconnectedCallback = function () {\n {\n document.dispatchEvent(new CustomEvent('ionInputDidUnload', {\n detail: this.el\n }));\n }\n };\n class_1.prototype.componentDidLoad = function () {\n this.runAutoGrow();\n };\n // TODO: performance hit, this cause layout thrashing\n class_1.prototype.runAutoGrow = function () {\n var nativeInput = this.nativeInput;\n if (nativeInput && this.autoGrow) {\n readTask(function () {\n nativeInput.style.height = 'inherit';\n nativeInput.style.height = nativeInput.scrollHeight + 'px';\n });\n }\n };\n /**\n * Sets focus on the specified `ion-textarea`. Use this method instead of the global\n * `input.focus()`.\n */\n class_1.prototype.setFocus = function () {\n return __awaiter(this, void 0, void 0, function () {\n return __generator(this, function (_a) {\n if (this.nativeInput) {\n this.nativeInput.focus();\n }\n return [2 /*return*/];\n });\n });\n };\n /**\n * Returns the native `