1 line
27 KiB
Plaintext
1 line
27 KiB
Plaintext
{"version":3,"sources":["webpack:///node_modules/@ionic/core/dist/esm/ion-input.entry.js"],"names":["inputIosCss","inputMdCss","Input","hostRef","ionInput","ionChange","ionBlur","ionFocus","ionStyle","inputId","inputIds","didBlurAfterEdit","fireFocusEvents","hasFocus","autocapitalize","autocomplete","autocorrect","autofocus","clearInput","debounce","disabled","name","readonly","required","spellcheck","type","value","onInput","ev","input","target","emit","onBlur","focusChanged","emitStyle","onFocus","onKeydown","shouldClearOnEdit","hasValue","key","clearTextInput","clearTextOnEnter","preventDefault","stopPropagation","setFocus","nativeInput","toString","el","hasAttribute","tabindex","getAttribute","undefined","removeAttribute","debounceChanged","document","dispatchEvent","CustomEvent","detail","focus","blur","Promise","resolve","clearOnEdit","placeholder","getValue","length","mode","labelId","label","id","color","ref","accept","autoCapitalize","autoComplete","autoCorrect","autoFocus","enterKeyHint","enterkeyhint","inputMode","inputmode","min","max","minLength","minlength","maxLength","maxlength","multiple","pattern","readOnly","step","size","onKeyDown","onTouchStart","onMouseDown","style","ios","md"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;;;AAAA;AAAA;AAAA;AAAA;;;AAAA;AAAA;AAAA;AAAA;;;AAAA;AAAA;AAAA;AAAA;;;AAAA;AAAA;AAAA;AAAA;;;AAAA;AAAA;AAAA;;AAKA,UAAMA,WAAW,GAAG,myJAApB;AAEA,UAAMC,UAAU,GAAG,irJAAnB;;AAEA,UAAMC,KAAK;AACP,uBAAYC,OAAZ,EAAqB;AAAA;;AAAA;;AACjB,uEAAiB,IAAjB,EAAuBA,OAAvB;AACA,eAAKC,QAAL,GAAgB,6DAAY,IAAZ,EAAkB,UAAlB,EAA8B,CAA9B,CAAhB;AACA,eAAKC,SAAL,GAAiB,6DAAY,IAAZ,EAAkB,WAAlB,EAA+B,CAA/B,CAAjB;AACA,eAAKC,OAAL,GAAe,6DAAY,IAAZ,EAAkB,SAAlB,EAA6B,CAA7B,C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IpB;AAlPG;;AAAA;AAAA,SAAX;;AAoPA,UAAI/B,QAAQ,GAAG,CAAf;AACAR,WAAK,CAAC6F,KAAN,GAAc;AACVC,WAAG,EAAEhG,WADK;AAEViG,UAAE,EAAEhG;AAFM,OAAd","file":"15-es5.js","sourcesContent":["import { r as registerInstance, e as createEvent, h, H as Host, i as getElement } from './index-92848855.js';\nimport { b as getIonMode } from './ionic-global-23e7365a.js';\nimport { d as debounceEvent, f as findItemLabel } from './helpers-5c745fbd.js';\nimport { c as createColorClasses } from './theme-5641d27f.js';\n\nconst inputIosCss = \".sc-ion-input-ios-h{--placeholder-color:initial;--placeholder-font-style:initial;--placeholder-font-weight:initial;--placeholder-opacity:.5;--padding-top:0;--padding-end:0;--padding-bottom:0;--padding-start:0;--background:transparent;--color:initial;display:-ms-flexbox;display:flex;position:relative;-ms-flex:1;flex:1;-ms-flex-align:center;align-items:center;width:100%;padding:0 !important;background:var(--background);color:var(--color);font-family:var(--ion-font-family, inherit);z-index:2}ion-item.sc-ion-input-ios-h:not(.item-label),ion-item:not(.item-label) .sc-ion-input-ios-h{--padding-start:0}.ion-color.sc-ion-input-ios-h{color:var(--ion-color-base)}.native-input.sc-ion-input-ios{border-radius:var(--border-radius);padding-left:var(--padding-start);padding-right:var(--padding-end);padding-top:var(--padding-top);padding-bottom:var(--padding-bottom);font-family:inherit;font-size:inherit;font-style:inherit;font-weight:inherit;letter-spacing:inherit;text-decoration:inherit;text-indent:inherit;text-overflow:inherit;text-transform:inherit;text-align:inherit;white-space:inherit;color:inherit;display:inline-block;-ms-flex:1;flex:1;width:100%;max-width:100%;max-height:100%;border:0;outline:none;background:transparent;-webkit-box-sizing:border-box;box-sizing:border-box;-webkit-appearance:none;-moz-appearance:none;appearance:none}@supports ((-webkit-margin-start: 0) or (margin-inline-start: 0)) or (-webkit-margin-start: 0){.native-input.sc-ion-input-ios{padding-left:unset;padding-right:unset;-webkit-padding-start:var(--padding-start);padding-inline-start:var(--padding-start);-webkit-padding-end:var(--padding-end);padding-inline-end:var(--padding-end)}}.native-input.sc-ion-input-ios::-webkit-input-placeholder{color:var(--placeholder-color);font-family:inherit;font-style:var(--placeholder-font-style);font-weight:var(--placeholder-font-weight);opacity:var(--placeholder-opacity)}.native-input.sc-ion-input-ios::-moz-placeholder{color:var(--placeholder-color);font-family:inherit;font-style:var(--placeholder-font-style);font-weight:var(--placeholder-font-weight);opacity:var(--placeholder-opacity)}.native-input.sc-ion-input-ios:-ms-input-placeholder{color:var(--placeholder-color);font-family:inherit;font-style:var(--placeholder-font-style);font-weight:var(--placeholder-font-weight);opacity:var(--placeholder-opacity)}.native-input.sc-ion-input-ios::-ms-input-placeholder{color:var(--placeholder-color);font-family:inherit;font-style:var(--placeholder-font-style);font-weight:var(--placeholder-font-weight);opacity:var(--placeholder-opacity)}.native-input.sc-ion-input-ios::placeholder{color:var(--placeholder-color);font-family:inherit;font-style:var(--placeholder-font-style);font-weight:var(--placeholder-font-weight);opacity:var(--placeholder-opacity)}.native-input.sc-ion-input-ios:-webkit-autofill{background-color:transparent}.native-input.sc-ion-input-ios:invalid{-webkit-box-shadow:none;box-shadow:none}.native-input.sc-ion-input-ios::-ms-clear{display:none}.native-input[disabled].sc-ion-input-ios{opacity:0.4}.cloned-input.sc-ion-input-ios{left:0;top:0;position:absolute;pointer-events:none}[dir=rtl].sc-ion-input-ios .cloned-input.sc-ion-input-ios,[dir=rtl].sc-ion-input-ios-h .cloned-input.sc-ion-input-ios,[dir=rtl] .sc-ion-input-ios-h .cloned-input.sc-ion-input-ios{left:unset;right:unset;right:0}.input-clear-icon.sc-ion-input-ios{margin-left:0;margin-right:0;margin-top:0;margin-bottom:0;padding-left:0;padding-right:0;padding-top:0;padding-bottom:0;background-position:center;border:0;outline:none;background-color:transparent;background-repeat:no-repeat;visibility:hidden;-webkit-appearance:none;-moz-appearance:none;appearance:none}.input-clear-icon.sc-ion-input-ios:focus{opacity:0.5}.has-value.sc-ion-input-ios-h .input-clear-icon.sc-ion-input-ios{visibility:visible}.has-focus.sc-ion-input-ios-h{pointer-events:none}.has-focus.sc-ion-input-ios-h input.sc-ion-input-ios,.has-focus.sc-ion-input-ios-h a.sc-ion-input-ios,.has-focus.sc-ion-input-ios-h button.sc-ion-input-ios{pointer-events:auto}.sc-ion-input-ios-h{--padding-top:10px;--padding-end:10px;--padding-bottom:10px;--padding-start:0;font-size:inherit}.item-label-stacked.sc-ion-input-ios-h,.item-label-stacked .sc-ion-input-ios-h,.item-label-floating.sc-ion-input-ios-h,.item-label-floating .sc-ion-input-ios-h{--padding-top:8px;--padding-bottom:8px;--padding-start:0px}.input-clear-icon.sc-ion-input-ios{background-image:url(\\\"data:image/svg+xml;charset=utf-8,<svg%20xmlns='http://www.w3.org/2000/svg'%20viewBox='0%200%20512%20512'><path%20fill='var(--ion-color-step-600,%20%23666666)'%20d='M403.1,108.9c-81.2-81.2-212.9-81.2-294.2,0s-81.2,212.9,0,294.2c81.2,81.2,212.9,81.2,294.2,0S484.3,190.1,403.1,108.9z%20M352,340.2L340.2,352l-84.4-84.2l-84,83.8L160,339.8l84-83.8l-84-83.8l11.8-11.8l84,83.8l84.4-84.2l11.8,11.8L267.6,256L352,340.2z'/></svg>\\\");width:30px;height:30px;background-size:18px}\";\n\nconst inputMdCss = \".sc-ion-input-md-h{--placeholder-color:initial;--placeholder-font-style:initial;--placeholder-font-weight:initial;--placeholder-opacity:.5;--padding-top:0;--padding-end:0;--padding-bottom:0;--padding-start:0;--background:transparent;--color:initial;display:-ms-flexbox;display:flex;position:relative;-ms-flex:1;flex:1;-ms-flex-align:center;align-items:center;width:100%;padding:0 !important;background:var(--background);color:var(--color);font-family:var(--ion-font-family, inherit);z-index:2}ion-item.sc-ion-input-md-h:not(.item-label),ion-item:not(.item-label) .sc-ion-input-md-h{--padding-start:0}.ion-color.sc-ion-input-md-h{color:var(--ion-color-base)}.native-input.sc-ion-input-md{border-radius:var(--border-radius);padding-left:var(--padding-start);padding-right:var(--padding-end);padding-top:var(--padding-top);padding-bottom:var(--padding-bottom);font-family:inherit;font-size:inherit;font-style:inherit;font-weight:inherit;letter-spacing:inherit;text-decoration:inherit;text-indent:inherit;text-overflow:inherit;text-transform:inherit;text-align:inherit;white-space:inherit;color:inherit;display:inline-block;-ms-flex:1;flex:1;width:100%;max-width:100%;max-height:100%;border:0;outline:none;background:transparent;-webkit-box-sizing:border-box;box-sizing:border-box;-webkit-appearance:none;-moz-appearance:none;appearance:none}@supports ((-webkit-margin-start: 0) or (margin-inline-start: 0)) or (-webkit-margin-start: 0){.native-input.sc-ion-input-md{padding-left:unset;padding-right:unset;-webkit-padding-start:var(--padding-start);padding-inline-start:var(--padding-start);-webkit-padding-end:var(--padding-end);padding-inline-end:var(--padding-end)}}.native-input.sc-ion-input-md::-webkit-input-placeholder{color:var(--placeholder-color);font-family:inherit;font-style:var(--placeholder-font-style);font-weight:var(--placeholder-font-weight);opacity:var(--placeholder-opacity)}.native-input.sc-ion-input-md::-moz-placeholder{color:var(--placeholder-color);font-family:inherit;font-style:var(--placeholder-font-style);font-weight:var(--placeholder-font-weight);opacity:var(--placeholder-opacity)}.native-input.sc-ion-input-md:-ms-input-placeholder{color:var(--placeholder-color);font-family:inherit;font-style:var(--placeholder-font-style);font-weight:var(--placeholder-font-weight);opacity:var(--placeholder-opacity)}.native-input.sc-ion-input-md::-ms-input-placeholder{color:var(--placeholder-color);font-family:inherit;font-style:var(--placeholder-font-style);font-weight:var(--placeholder-font-weight);opacity:var(--placeholder-opacity)}.native-input.sc-ion-input-md::placeholder{color:var(--placeholder-color);font-family:inherit;font-style:var(--placeholder-font-style);font-weight:var(--placeholder-font-weight);opacity:var(--placeholder-opacity)}.native-input.sc-ion-input-md:-webkit-autofill{background-color:transparent}.native-input.sc-ion-input-md:invalid{-webkit-box-shadow:none;box-shadow:none}.native-input.sc-ion-input-md::-ms-clear{display:none}.native-input[disabled].sc-ion-input-md{opacity:0.4}.cloned-input.sc-ion-input-md{left:0;top:0;position:absolute;pointer-events:none}[dir=rtl].sc-ion-input-md .cloned-input.sc-ion-input-md,[dir=rtl].sc-ion-input-md-h .cloned-input.sc-ion-input-md,[dir=rtl] .sc-ion-input-md-h .cloned-input.sc-ion-input-md{left:unset;right:unset;right:0}.input-clear-icon.sc-ion-input-md{margin-left:0;margin-right:0;margin-top:0;margin-bottom:0;padding-left:0;padding-right:0;padding-top:0;padding-bottom:0;background-position:center;border:0;outline:none;background-color:transparent;background-repeat:no-repeat;visibility:hidden;-webkit-appearance:none;-moz-appearance:none;appearance:none}.input-clear-icon.sc-ion-input-md:focus{opacity:0.5}.has-value.sc-ion-input-md-h .input-clear-icon.sc-ion-input-md{visibility:visible}.has-focus.sc-ion-input-md-h{pointer-events:none}.has-focus.sc-ion-input-md-h input.sc-ion-input-md,.has-focus.sc-ion-input-md-h a.sc-ion-input-md,.has-focus.sc-ion-input-md-h button.sc-ion-input-md{pointer-events:auto}.sc-ion-input-md-h{--padding-top:10px;--padding-end:0;--padding-bottom:10px;--padding-start:8px;font-size:inherit}.item-label-stacked.sc-ion-input-md-h,.item-label-stacked .sc-ion-input-md-h,.item-label-floating.sc-ion-input-md-h,.item-label-floating .sc-ion-input-md-h{--padding-top:8px;--padding-bottom:8px;--padding-start:0}.input-clear-icon.sc-ion-input-md{background-image:url(\\\"data:image/svg+xml;charset=utf-8,<svg%20xmlns='http://www.w3.org/2000/svg'%20viewBox='0%200%20512%20512'><polygon%20fill='var(--ion-color-step-600,%20%23666666)'%20points='405,136.798%20375.202,107%20256,226.202%20136.798,107%20107,136.798%20226.202,256%20107,375.202%20136.798,405%20256,285.798%20375.202,405%20405,375.202%20285.798,256'/></svg>\\\");width:30px;height:30px;background-size:22px}\";\n\nconst Input = class {\n constructor(hostRef) {\n registerInstance(this, hostRef);\n this.ionInput = createEvent(this, \"ionInput\", 7);\n this.ionChange = createEvent(this, \"ionChange\", 7);\n this.ionBlur = createEvent(this, \"ionBlur\", 7);\n this.ionFocus = createEvent(this, \"ionFocus\", 7);\n this.ionStyle = createEvent(this, \"ionStyle\", 7);\n this.inputId = `ion-input-${inputIds++}`;\n this.didBlurAfterEdit = false;\n /**\n * This is required for a WebKit bug which requires us to\n * blur and focus an input to properly focus the input in\n * an item with delegatesFocus. It will no longer be needed\n * with iOS 14.\n *\n * @internal\n */\n this.fireFocusEvents = true;\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 = 'off';\n /**\n * Indicates whether the value of the control can be automatically completed by the browser.\n */\n this.autocomplete = 'off';\n /**\n * Whether auto correction should be enabled when the user is entering/editing the text value.\n */\n this.autocorrect = 'off';\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`, a clear icon will appear in the input when there is a value. Clicking it clears the input.\n */\n this.clearInput = 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 input.\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 * The type of control to display. The default type is text.\n */\n this.type = 'text';\n /**\n * The value of the input.\n */\n this.value = '';\n this.onInput = (ev) => {\n const input = ev.target;\n if (input) {\n this.value = input.value || '';\n }\n this.ionInput.emit(ev);\n };\n this.onBlur = (ev) => {\n this.hasFocus = false;\n this.focusChanged();\n this.emitStyle();\n if (this.fireFocusEvents) {\n this.ionBlur.emit(ev);\n }\n };\n this.onFocus = (ev) => {\n this.hasFocus = true;\n this.focusChanged();\n this.emitStyle();\n if (this.fireFocusEvents) {\n this.ionFocus.emit(ev);\n }\n };\n this.onKeydown = (ev) => {\n if (this.shouldClearOnEdit()) {\n // Did the input value change after it was blurred and edited?\n // Do not clear if user is hitting Enter to submit form\n if (this.didBlurAfterEdit && this.hasValue() && ev.key !== 'Enter') {\n // Clear the input\n this.clearTextInput();\n }\n // Reset the flag\n this.didBlurAfterEdit = false;\n }\n };\n this.clearTextOnEnter = (ev) => {\n if (ev.key === 'Enter') {\n this.clearTextInput(ev);\n }\n };\n this.clearTextInput = (ev) => {\n if (this.clearInput && !this.readonly && !this.disabled && ev) {\n ev.preventDefault();\n ev.stopPropagation();\n // Attempt to focus input again after pressing clear button\n this.setFocus();\n }\n this.value = '';\n /**\n * This is needed for clearOnEdit\n * Otherwise the value will not be cleared\n * if user is inside the input\n */\n if (this.nativeInput) {\n this.nativeInput.value = '';\n }\n };\n }\n debounceChanged() {\n this.ionChange = debounceEvent(this.ionChange, this.debounce);\n }\n disabledChanged() {\n this.emitStyle();\n }\n /**\n * Update the native input element when the value changes\n */\n valueChanged() {\n this.emitStyle();\n this.ionChange.emit({ value: this.value == null ? this.value : this.value.toString() });\n }\n componentWillLoad() {\n // If the ion-input has a tabindex attribute we get the value\n // and pass it down to the native input, then remove it from the\n // ion-input to avoid causing tabbing twice on the same element\n if (this.el.hasAttribute('tabindex')) {\n const tabindex = this.el.getAttribute('tabindex');\n this.tabindex = tabindex !== null ? tabindex : undefined;\n this.el.removeAttribute('tabindex');\n }\n }\n connectedCallback() {\n this.emitStyle();\n this.debounceChanged();\n {\n document.dispatchEvent(new CustomEvent('ionInputDidLoad', {\n detail: this.el\n }));\n }\n }\n disconnectedCallback() {\n {\n document.dispatchEvent(new CustomEvent('ionInputDidUnload', {\n detail: this.el\n }));\n }\n }\n /**\n * Sets focus on the native `input` in `ion-input`. Use this method instead of the global\n * `input.focus()`.\n */\n async setFocus() {\n if (this.nativeInput) {\n this.nativeInput.focus();\n }\n }\n /**\n * Sets blur on the native `input` in `ion-input`. Use this method instead of the global\n * `input.blur()`.\n * @internal\n */\n async setBlur() {\n if (this.nativeInput) {\n this.nativeInput.blur();\n }\n }\n /**\n * Returns the native `<input>` element used under the hood.\n */\n getInputElement() {\n return Promise.resolve(this.nativeInput);\n }\n shouldClearOnEdit() {\n const { type, clearOnEdit } = this;\n return (clearOnEdit === undefined)\n ? type === 'password'\n : clearOnEdit;\n }\n getValue() {\n return typeof this.value === 'number' ? this.value.toString() :\n (this.value || '').toString();\n }\n emitStyle() {\n this.ionStyle.emit({\n 'interactive': true,\n 'input': true,\n 'has-placeholder': this.placeholder != null,\n 'has-value': this.hasValue(),\n 'has-focus': this.hasFocus,\n 'interactive-disabled': this.disabled,\n });\n }\n focusChanged() {\n // If clearOnEdit is enabled and the input blurred but has a value, set a flag\n if (!this.hasFocus && this.shouldClearOnEdit() && this.hasValue()) {\n this.didBlurAfterEdit = true;\n }\n }\n hasValue() {\n return this.getValue().length > 0;\n }\n render() {\n const mode = getIonMode(this);\n const value = this.getValue();\n const labelId = this.inputId + '-lbl';\n const label = findItemLabel(this.el);\n if (label) {\n label.id = labelId;\n }\n return (h(Host, { \"aria-disabled\": this.disabled ? 'true' : null, class: createColorClasses(this.color, {\n [mode]: true,\n 'has-value': this.hasValue(),\n 'has-focus': this.hasFocus\n }) }, h(\"input\", { class: \"native-input\", ref: input => this.nativeInput = input, \"aria-labelledby\": labelId, disabled: this.disabled, accept: this.accept, autoCapitalize: this.autocapitalize, autoComplete: this.autocomplete, autoCorrect: this.autocorrect, autoFocus: this.autofocus, enterKeyHint: this.enterkeyhint, inputMode: this.inputmode, min: this.min, max: this.max, minLength: this.minlength, maxLength: this.maxlength, multiple: this.multiple, name: this.name, pattern: this.pattern, placeholder: this.placeholder || '', readOnly: this.readonly, required: this.required, spellcheck: this.spellcheck, step: this.step, size: this.size, tabindex: this.tabindex, type: this.type, value: value, onInput: this.onInput, onBlur: this.onBlur, onFocus: this.onFocus, onKeyDown: this.onKeydown }), (this.clearInput && !this.readonly && !this.disabled) && h(\"button\", { \"aria-label\": \"reset\", type: \"button\", class: \"input-clear-icon\", onTouchStart: this.clearTextInput, onMouseDown: this.clearTextInput, onKeyDown: this.clearTextOnEnter })));\n }\n get el() { return getElement(this); }\n static get watchers() { return {\n \"debounce\": [\"debounceChanged\"],\n \"disabled\": [\"disabledChanged\"],\n \"value\": [\"valueChanged\"]\n }; }\n};\nlet inputIds = 0;\nInput.style = {\n ios: inputIosCss,\n md: inputMdCss\n};\n\nexport { Input as ion_input };\n"]} |