{"ast":null,"code":"import { __awaiter, __generator } from \"tslib\";\nimport { r as registerInstance, e as createEvent, j as forceUpdate, h, H as Host, i as getElement } from \"./index-7a8b7a1c.js\";\nimport { c as config, b as getIonMode } from \"./ionic-global-63a97a32.js\";\nimport { f as debounceEvent, r as raf } from \"./helpers-dd7e4b7b.js\";\nimport { c as createColorClasses } from \"./theme-ff3fc52f.js\";\nvar searchbarIosCss = \".sc-ion-searchbar-ios-h{--placeholder-color:initial;--placeholder-font-style:initial;--placeholder-font-weight:initial;--placeholder-opacity:.5;-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased;display:-ms-flexbox;display:flex;position:relative;-ms-flex-align:center;align-items:center;width:100%;color:var(--color);font-family:var(--ion-font-family, inherit);-webkit-box-sizing:border-box;box-sizing:border-box}.ion-color.sc-ion-searchbar-ios-h{color:var(--ion-color-contrast)}.ion-color.sc-ion-searchbar-ios-h .searchbar-input.sc-ion-searchbar-ios{background:var(--ion-color-base)}.ion-color.sc-ion-searchbar-ios-h .searchbar-clear-button.sc-ion-searchbar-ios,.ion-color.sc-ion-searchbar-ios-h .searchbar-cancel-button.sc-ion-searchbar-ios,.ion-color.sc-ion-searchbar-ios-h .searchbar-search-icon.sc-ion-searchbar-ios{color:inherit}.searchbar-search-icon.sc-ion-searchbar-ios{color:var(--icon-color);pointer-events:none}.searchbar-input-container.sc-ion-searchbar-ios{display:block;position:relative;-ms-flex-negative:1;flex-shrink:1;width:100%}.searchbar-input.sc-ion-searchbar-ios{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;border-radius:var(--border-radius);display:block;width:100%;border:0;outline:none;background:var(--background);font-family:inherit;-webkit-box-shadow:var(--box-shadow);box-shadow:var(--box-shadow);-webkit-box-sizing:border-box;box-sizing:border-box;-webkit-appearance:none;-moz-appearance:none;appearance:none}.searchbar-input.sc-ion-searchbar-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)}.searchbar-input.sc-ion-searchbar-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)}.searchbar-input.sc-ion-searchbar-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)}.searchbar-input.sc-ion-searchbar-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)}.searchbar-input.sc-ion-searchbar-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)}.searchbar-input.sc-ion-searchbar-ios::-webkit-search-cancel-button,.searchbar-input.sc-ion-searchbar-ios::-ms-clear{display:none}.searchbar-cancel-button.sc-ion-searchbar-ios{margin-left:0;margin-right:0;margin-top:0;margin-bottom:0;display:none;height:100%;border:0;outline:none;color:var(--cancel-button-color);cursor:pointer;-webkit-appearance:none;-moz-appearance:none;appearance:none}.searchbar-cancel-button.sc-ion-searchbar-ios>div.sc-ion-searchbar-ios{display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;-ms-flex-pack:center;justify-content:center;width:100%;height:100%}.searchbar-clear-button.sc-ion-searchbar-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;display:none;min-height:0;outline:none;color:var(--clear-button-color);-webkit-appearance:none;-moz-appearance:none;appearance:none}.searchbar-has-value.searchbar-should-show-clear.sc-ion-searchbar-ios-h .searchbar-clear-button.sc-ion-searchbar-ios{display:block}.searchbar-disabled.sc-ion-searchbar-ios-h{cursor:default;opacity:0.4;pointer-events:none}.sc-ion-searchbar-ios-h{--background:rgba(var(--ion-text-color-rgb, 0, 0, 0), 0.07);--border-radius:10px;--box-shadow:none;--cancel-button-color:var(--ion-color-primary, #3880ff);--clear-button-color:var(--ion-color-step-600, #666666);--color:var(--ion-text-color, #000);--icon-color:var(--ion-color-step-600, #666666);padding-left:12px;padding-right:12px;padding-top:12px;padding-bottom:12px;height:60px;contain:strict}@supports ((-webkit-margin-start: 0) or (margin-inline-start: 0)) or (-webkit-margin-start: 0){.sc-ion-searchbar-ios-h{padding-left:unset;padding-right:unset;-webkit-padding-start:12px;padding-inline-start:12px;-webkit-padding-end:12px;padding-inline-end:12px}}.searchbar-input-container.sc-ion-searchbar-ios{height:36px}.searchbar-search-icon.sc-ion-searchbar-ios{margin-left:calc(50% - 60px);left:5px;top:0;position:absolute;width:22px;height:100%;contain:strict}@supports ((-webkit-margin-start: 0) or (margin-inline-start: 0)) or (-webkit-margin-start: 0){.searchbar-search-icon.sc-ion-searchbar-ios{margin-left:unset;-webkit-margin-start:calc(50% - 60px);margin-inline-start:calc(50% - 60px)}}[dir=rtl].sc-ion-searchbar-ios .searchbar-search-icon.sc-ion-searchbar-ios,[dir=rtl].sc-ion-searchbar-ios-h .searchbar-search-icon.sc-ion-searchbar-ios,[dir=rtl] .sc-ion-searchbar-ios-h .searchbar-search-icon.sc-ion-searchbar-ios{left:unset;right:unset;right:5px}.searchbar-input.sc-ion-searchbar-ios{padding-left:28px;padding-right:28px;padding-top:0;padding-bottom:0;height:100%;font-size:17px;font-weight:400;contain:strict}@supports ((-webkit-margin-start: 0) or (margin-inline-start: 0)) or (-webkit-margin-start: 0){.searchbar-input.sc-ion-searchbar-ios{padding-left:unset;padding-right:unset;-webkit-padding-start:28px;padding-inline-start:28px;-webkit-padding-end:28px;padding-inline-end:28px}}.searchbar-clear-button.sc-ion-searchbar-ios{right:0;top:0;background-position:center;position:absolute;width:30px;height:100%;border:0;background-color:transparent}[dir=rtl].sc-ion-searchbar-ios .searchbar-clear-button.sc-ion-searchbar-ios,[dir=rtl].sc-ion-searchbar-ios-h .searchbar-clear-button.sc-ion-searchbar-ios,[dir=rtl] .sc-ion-searchbar-ios-h .searchbar-clear-button.sc-ion-searchbar-ios{left:unset;right:unset;left:0}.searchbar-clear-icon.sc-ion-searchbar-ios{width:18px;height:100%}.searchbar-cancel-button.sc-ion-searchbar-ios{padding-left:8px;padding-right:0;padding-top:0;padding-bottom:0;-ms-flex-negative:0;flex-shrink:0;background-color:transparent;font-size:16px}@supports ((-webkit-margin-start: 0) or (margin-inline-start: 0)) or (-webkit-margin-start: 0){.searchbar-cancel-button.sc-ion-searchbar-ios{padding-left:unset;padding-right:unset;-webkit-padding-start:8px;padding-inline-start:8px;-webkit-padding-end:0;padding-inline-end:0}}.searchbar-left-aligned.sc-ion-searchbar-ios-h .searchbar-search-icon.sc-ion-searchbar-ios{margin-left:0}@supports ((-webkit-margin-start: 0) or (margin-inline-start: 0)) or (-webkit-margin-start: 0){.searchbar-left-aligned.sc-ion-searchbar-ios-h .searchbar-search-icon.sc-ion-searchbar-ios{margin-left:unset;-webkit-margin-start:0;margin-inline-start:0}}.searchbar-left-aligned.sc-ion-searchbar-ios-h .searchbar-input.sc-ion-searchbar-ios{padding-left:30px}@supports ((-webkit-margin-start: 0) or (margin-inline-start: 0)) or (-webkit-margin-start: 0){.searchbar-left-aligned.sc-ion-searchbar-ios-h .searchbar-input.sc-ion-searchbar-ios{padding-left:unset;-webkit-padding-start:30px;padding-inline-start:30px}}.searchbar-has-focus.sc-ion-searchbar-ios-h .searchbar-cancel-button.sc-ion-searchbar-ios,.searchbar-should-show-cancel.sc-ion-searchbar-ios-h .searchbar-cancel-button.sc-ion-searchbar-ios,.searchbar-animated.sc-ion-searchbar-ios-h .searchbar-cancel-button.sc-ion-searchbar-ios{display:block}.searchbar-animated.sc-ion-searchbar-ios-h .searchbar-search-icon.sc-ion-searchbar-ios,.searchbar-animated.sc-ion-searchbar-ios-h .searchbar-input.sc-ion-searchbar-ios{-webkit-transition:all 300ms ease;transition:all 300ms ease}.searchbar-animated.searchbar-has-focus.sc-ion-searchbar-ios-h .searchbar-cancel-button.sc-ion-searchbar-ios,.searchbar-animated.searchbar-should-show-cancel.sc-ion-searchbar-ios-h .searchbar-cancel-button.sc-ion-searchbar-ios{opacity:1;pointer-events:auto}.searchbar-animated.sc-ion-searchbar-ios-h .searchbar-cancel-button.sc-ion-searchbar-ios{margin-right:-100%;-webkit-transform:translate3d(0,  0,  0);transform:translate3d(0,  0,  0);-webkit-transition:all 300ms ease;transition:all 300ms ease;opacity:0;pointer-events:none}@supports ((-webkit-margin-start: 0) or (margin-inline-start: 0)) or (-webkit-margin-start: 0){.searchbar-animated.sc-ion-searchbar-ios-h .searchbar-cancel-button.sc-ion-searchbar-ios{margin-right:unset;-webkit-margin-end:-100%;margin-inline-end:-100%}}.searchbar-no-animate.sc-ion-searchbar-ios-h .searchbar-search-icon.sc-ion-searchbar-ios,.searchbar-no-animate.sc-ion-searchbar-ios-h .searchbar-input.sc-ion-searchbar-ios,.searchbar-no-animate.sc-ion-searchbar-ios-h .searchbar-cancel-button.sc-ion-searchbar-ios{-webkit-transition-duration:0ms;transition-duration:0ms}.ion-color.sc-ion-searchbar-ios-h .searchbar-cancel-button.sc-ion-searchbar-ios{color:var(--ion-color-base)}@media (any-hover: hover){.ion-color.sc-ion-searchbar-ios-h .searchbar-cancel-button.sc-ion-searchbar-ios:hover{color:var(--ion-color-tint)}}ion-toolbar.sc-ion-searchbar-ios-h,ion-toolbar .sc-ion-searchbar-ios-h{padding-top:1px;padding-bottom:15px;height:52px}ion-toolbar.ion-color.sc-ion-searchbar-ios-h:not(.ion-color),ion-toolbar.ion-color .sc-ion-searchbar-ios-h:not(.ion-color){color:inherit}ion-toolbar.ion-color.sc-ion-searchbar-ios-h:not(.ion-color) .searchbar-cancel-button.sc-ion-searchbar-ios,ion-toolbar.ion-color .sc-ion-searchbar-ios-h:not(.ion-color) .searchbar-cancel-button.sc-ion-searchbar-ios{color:currentColor}ion-toolbar.ion-color.sc-ion-searchbar-ios-h .searchbar-search-icon.sc-ion-searchbar-ios,ion-toolbar.ion-color .sc-ion-searchbar-ios-h .searchbar-search-icon.sc-ion-searchbar-ios{color:currentColor;opacity:0.5}ion-toolbar.ion-color.sc-ion-searchbar-ios-h:not(.ion-color) .searchbar-input.sc-ion-searchbar-ios,ion-toolbar.ion-color .sc-ion-searchbar-ios-h:not(.ion-color) .searchbar-input.sc-ion-searchbar-ios{background:rgba(var(--ion-color-contrast-rgb), 0.07);color:currentColor}ion-toolbar.ion-color.sc-ion-searchbar-ios-h:not(.ion-color) .searchbar-clear-button.sc-ion-searchbar-ios,ion-toolbar.ion-color .sc-ion-searchbar-ios-h:not(.ion-color) .searchbar-clear-button.sc-ion-searchbar-ios{color:currentColor;opacity:0.5}\";\nvar searchbarMdCss = \".sc-ion-searchbar-md-h{--placeholder-color:initial;--placeholder-font-style:initial;--placeholder-font-weight:initial;--placeholder-opacity:.5;-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased;display:-ms-flexbox;display:flex;position:relative;-ms-flex-align:center;align-items:center;width:100%;color:var(--color);font-family:var(--ion-font-family, inherit);-webkit-box-sizing:border-box;box-sizing:border-box}.ion-color.sc-ion-searchbar-md-h{color:var(--ion-color-contrast)}.ion-color.sc-ion-searchbar-md-h .searchbar-input.sc-ion-searchbar-md{background:var(--ion-color-base)}.ion-color.sc-ion-searchbar-md-h .searchbar-clear-button.sc-ion-searchbar-md,.ion-color.sc-ion-searchbar-md-h .searchbar-cancel-button.sc-ion-searchbar-md,.ion-color.sc-ion-searchbar-md-h .searchbar-search-icon.sc-ion-searchbar-md{color:inherit}.searchbar-search-icon.sc-ion-searchbar-md{color:var(--icon-color);pointer-events:none}.searchbar-input-container.sc-ion-searchbar-md{display:block;position:relative;-ms-flex-negative:1;flex-shrink:1;width:100%}.searchbar-input.sc-ion-searchbar-md{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;border-radius:var(--border-radius);display:block;width:100%;border:0;outline:none;background:var(--background);font-family:inherit;-webkit-box-shadow:var(--box-shadow);box-shadow:var(--box-shadow);-webkit-box-sizing:border-box;box-sizing:border-box;-webkit-appearance:none;-moz-appearance:none;appearance:none}.searchbar-input.sc-ion-searchbar-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)}.searchbar-input.sc-ion-searchbar-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)}.searchbar-input.sc-ion-searchbar-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)}.searchbar-input.sc-ion-searchbar-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)}.searchbar-input.sc-ion-searchbar-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)}.searchbar-input.sc-ion-searchbar-md::-webkit-search-cancel-button,.searchbar-input.sc-ion-searchbar-md::-ms-clear{display:none}.searchbar-cancel-button.sc-ion-searchbar-md{margin-left:0;margin-right:0;margin-top:0;margin-bottom:0;display:none;height:100%;border:0;outline:none;color:var(--cancel-button-color);cursor:pointer;-webkit-appearance:none;-moz-appearance:none;appearance:none}.searchbar-cancel-button.sc-ion-searchbar-md>div.sc-ion-searchbar-md{display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;-ms-flex-pack:center;justify-content:center;width:100%;height:100%}.searchbar-clear-button.sc-ion-searchbar-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;display:none;min-height:0;outline:none;color:var(--clear-button-color);-webkit-appearance:none;-moz-appearance:none;appearance:none}.searchbar-has-value.searchbar-should-show-clear.sc-ion-searchbar-md-h .searchbar-clear-button.sc-ion-searchbar-md{display:block}.searchbar-disabled.sc-ion-searchbar-md-h{cursor:default;opacity:0.4;pointer-events:none}.sc-ion-searchbar-md-h{--background:var(--ion-background-color, #fff);--border-radius:2px;--box-shadow:0 2px 2px 0 rgba(0, 0, 0, 0.14), 0 3px 1px -2px rgba(0, 0, 0, 0.2), 0 1px 5px 0 rgba(0, 0, 0, 0.12);--cancel-button-color:var(--ion-color-step-900, #1a1a1a);--clear-button-color:initial;--color:var(--ion-color-step-850, #262626);--icon-color:var(--ion-color-step-600, #666666);padding-left:8px;padding-right:8px;padding-top:8px;padding-bottom:8px;background:inherit}@supports ((-webkit-margin-start: 0) or (margin-inline-start: 0)) or (-webkit-margin-start: 0){.sc-ion-searchbar-md-h{padding-left:unset;padding-right:unset;-webkit-padding-start:8px;padding-inline-start:8px;-webkit-padding-end:8px;padding-inline-end:8px}}.searchbar-search-icon.sc-ion-searchbar-md{left:16px;top:11px;width:21px;height:21px}[dir=rtl].sc-ion-searchbar-md .searchbar-search-icon.sc-ion-searchbar-md,[dir=rtl].sc-ion-searchbar-md-h .searchbar-search-icon.sc-ion-searchbar-md,[dir=rtl] .sc-ion-searchbar-md-h .searchbar-search-icon.sc-ion-searchbar-md{left:unset;right:unset;right:16px}.searchbar-cancel-button.sc-ion-searchbar-md{left:5px;top:0;background-color:transparent;font-size:1.6em}[dir=rtl].sc-ion-searchbar-md .searchbar-cancel-button.sc-ion-searchbar-md,[dir=rtl].sc-ion-searchbar-md-h .searchbar-cancel-button.sc-ion-searchbar-md,[dir=rtl] .sc-ion-searchbar-md-h .searchbar-cancel-button.sc-ion-searchbar-md{left:unset;right:unset;right:5px}.searchbar-search-icon.sc-ion-searchbar-md,.searchbar-cancel-button.sc-ion-searchbar-md{position:absolute}.searchbar-search-icon.ion-activated.sc-ion-searchbar-md,.searchbar-cancel-button.ion-activated.sc-ion-searchbar-md{background-color:transparent}.searchbar-input.sc-ion-searchbar-md{padding-left:55px;padding-right:55px;padding-top:6px;padding-bottom:6px;background-position:left 8px center;height:auto;font-size:16px;font-weight:400;line-height:30px}@supports ((-webkit-margin-start: 0) or (margin-inline-start: 0)) or (-webkit-margin-start: 0){.searchbar-input.sc-ion-searchbar-md{padding-left:unset;padding-right:unset;-webkit-padding-start:55px;padding-inline-start:55px;-webkit-padding-end:55px;padding-inline-end:55px}}[dir=rtl].sc-ion-searchbar-md .searchbar-input.sc-ion-searchbar-md,[dir=rtl].sc-ion-searchbar-md-h .searchbar-input.sc-ion-searchbar-md,[dir=rtl] .sc-ion-searchbar-md-h .searchbar-input.sc-ion-searchbar-md{background-position:right 8px center}.searchbar-clear-button.sc-ion-searchbar-md{right:13px;top:0;padding-left:0;padding-right:0;padding-top:0;padding-bottom:0;position:absolute;height:100%;border:0;background-color:transparent}[dir=rtl].sc-ion-searchbar-md .searchbar-clear-button.sc-ion-searchbar-md,[dir=rtl].sc-ion-searchbar-md-h .searchbar-clear-button.sc-ion-searchbar-md,[dir=rtl] .sc-ion-searchbar-md-h .searchbar-clear-button.sc-ion-searchbar-md{left:unset;right:unset;left:13px}.searchbar-clear-button.ion-activated.sc-ion-searchbar-md{background-color:transparent}.searchbar-clear-icon.sc-ion-searchbar-md{width:22px;height:100%}.searchbar-has-focus.sc-ion-searchbar-md-h .searchbar-search-icon.sc-ion-searchbar-md{display:block}.searchbar-has-focus.sc-ion-searchbar-md-h .searchbar-cancel-button.sc-ion-searchbar-md,.searchbar-should-show-cancel.sc-ion-searchbar-md-h .searchbar-cancel-button.sc-ion-searchbar-md{display:block}.searchbar-has-focus.sc-ion-searchbar-md-h .searchbar-cancel-button.sc-ion-searchbar-md+.searchbar-search-icon.sc-ion-searchbar-md,.searchbar-should-show-cancel.sc-ion-searchbar-md-h .searchbar-cancel-button.sc-ion-searchbar-md+.searchbar-search-icon.sc-ion-searchbar-md{display:none}ion-toolbar.sc-ion-searchbar-md-h,ion-toolbar .sc-ion-searchbar-md-h{padding-left:7px;padding-right:7px;padding-top:3px;padding-bottom:3px}@supports ((-webkit-margin-start: 0) or (margin-inline-start: 0)) or (-webkit-margin-start: 0){ion-toolbar.sc-ion-searchbar-md-h,ion-toolbar .sc-ion-searchbar-md-h{padding-left:unset;padding-right:unset;-webkit-padding-start:7px;padding-inline-start:7px;-webkit-padding-end:7px;padding-inline-end:7px}}\";\n\nvar Searchbar = function () {\n  function a(a) {\n    var r = this;\n    registerInstance(this, a);\n    this.ionInput = createEvent(this, \"ionInput\", 7);\n    this.ionChange = createEvent(this, \"ionChange\", 7);\n    this.ionCancel = createEvent(this, \"ionCancel\", 7);\n    this.ionClear = createEvent(this, \"ionClear\", 7);\n    this.ionBlur = createEvent(this, \"ionBlur\", 7);\n    this.ionFocus = createEvent(this, \"ionFocus\", 7);\n    this.ionStyle = createEvent(this, \"ionStyle\", 7);\n    this.isCancelVisible = false;\n    this.shouldAlignLeft = true;\n    this.focused = false;\n    this.noAnimate = true;\n    this.animated = false;\n    this.autocomplete = \"off\";\n    this.autocorrect = \"off\";\n    this.cancelButtonIcon = config.get(\"backButtonIcon\", \"arrow-back-sharp\");\n    this.cancelButtonText = \"Cancel\";\n    this.debounce = 250;\n    this.disabled = false;\n    this.placeholder = \"Search\";\n    this.showCancelButton = \"never\";\n    this.showClearButton = \"focus\";\n    this.spellcheck = false;\n    this.type = \"search\";\n    this.value = \"\";\n\n    this.onClearInput = function (a, e) {\n      r.ionClear.emit();\n\n      if (a) {\n        a.preventDefault();\n        a.stopPropagation();\n      }\n\n      setTimeout(function () {\n        var a = r.getValue();\n\n        if (a !== \"\") {\n          r.value = \"\";\n          r.ionInput.emit();\n\n          if (e && !r.focused) {\n            r.setFocus();\n          }\n        }\n      }, 16 * 4);\n    };\n\n    this.onCancelSearchbar = function (a) {\n      if (a) {\n        a.preventDefault();\n        a.stopPropagation();\n      }\n\n      r.ionCancel.emit();\n      r.onClearInput();\n\n      if (r.nativeInput) {\n        r.nativeInput.blur();\n      }\n    };\n\n    this.onInput = function (a) {\n      var e = a.target;\n\n      if (e) {\n        r.value = e.value;\n      }\n\n      r.ionInput.emit(a);\n    };\n\n    this.onBlur = function () {\n      r.focused = false;\n      r.ionBlur.emit();\n      r.positionElements();\n    };\n\n    this.onFocus = function () {\n      r.focused = true;\n      r.ionFocus.emit();\n      r.positionElements();\n    };\n  }\n\n  a.prototype.debounceChanged = function () {\n    this.ionChange = debounceEvent(this.ionChange, this.debounce);\n  };\n\n  a.prototype.valueChanged = function () {\n    var a = this.nativeInput;\n    var r = this.getValue();\n\n    if (a && a.value !== r) {\n      a.value = r;\n    }\n\n    this.ionChange.emit({\n      value: r\n    });\n  };\n\n  a.prototype.showCancelButtonChanged = function () {\n    var a = this;\n    requestAnimationFrame(function () {\n      a.positionElements();\n      forceUpdate(a);\n    });\n  };\n\n  a.prototype.connectedCallback = function () {\n    this.emitStyle();\n  };\n\n  a.prototype.componentDidLoad = function () {\n    var a = this;\n    this.positionElements();\n    this.debounceChanged();\n    setTimeout(function () {\n      a.noAnimate = false;\n    }, 300);\n  };\n\n  a.prototype.emitStyle = function () {\n    this.ionStyle.emit({\n      searchbar: true\n    });\n  };\n\n  a.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\n        return [2];\n      });\n    });\n  };\n\n  a.prototype.getInputElement = function () {\n    return Promise.resolve(this.nativeInput);\n  };\n\n  a.prototype.positionElements = function () {\n    var a = this.getValue();\n    var r = this.shouldAlignLeft;\n    var e = getIonMode(this);\n    var o = !this.animated || a.trim() !== \"\" || !!this.focused;\n    this.shouldAlignLeft = o;\n\n    if (e !== \"ios\") {\n      return;\n    }\n\n    if (r !== o) {\n      this.positionPlaceholder();\n    }\n\n    if (this.animated) {\n      this.positionCancelButton();\n    }\n  };\n\n  a.prototype.positionPlaceholder = function () {\n    var a = this.nativeInput;\n\n    if (!a) {\n      return;\n    }\n\n    var r = document.dir === \"rtl\";\n    var e = (this.el.shadowRoot || this.el).querySelector(\".searchbar-search-icon\");\n\n    if (this.shouldAlignLeft) {\n      a.removeAttribute(\"style\");\n      e.removeAttribute(\"style\");\n    } else {\n      var o = document;\n      var i = o.createElement(\"span\");\n      i.innerText = this.placeholder || \"\";\n      o.body.appendChild(i);\n      raf(function () {\n        var o = i.offsetWidth;\n        i.remove();\n        var t = \"calc(50% - \" + o / 2 + \"px)\";\n        var n = \"calc(50% - \" + (o / 2 + 30) + \"px)\";\n\n        if (r) {\n          a.style.paddingRight = t;\n          e.style.marginRight = n;\n        } else {\n          a.style.paddingLeft = t;\n          e.style.marginLeft = n;\n        }\n      });\n    }\n  };\n\n  a.prototype.positionCancelButton = function () {\n    var a = document.dir === \"rtl\";\n    var r = (this.el.shadowRoot || this.el).querySelector(\".searchbar-cancel-button\");\n    var e = this.shouldShowCancelButton();\n\n    if (r && e !== this.isCancelVisible) {\n      var o = r.style;\n      this.isCancelVisible = e;\n\n      if (e) {\n        if (a) {\n          o.marginLeft = \"0\";\n        } else {\n          o.marginRight = \"0\";\n        }\n      } else {\n        var i = r.offsetWidth;\n\n        if (i > 0) {\n          if (a) {\n            o.marginLeft = -i + \"px\";\n          } else {\n            o.marginRight = -i + \"px\";\n          }\n        }\n      }\n    }\n  };\n\n  a.prototype.getValue = function () {\n    return this.value || \"\";\n  };\n\n  a.prototype.hasValue = function () {\n    return this.getValue() !== \"\";\n  };\n\n  a.prototype.shouldShowCancelButton = function () {\n    if (this.showCancelButton === \"never\" || this.showCancelButton === \"focus\" && !this.focused) {\n      return false;\n    }\n\n    return true;\n  };\n\n  a.prototype.shouldShowClearButton = function () {\n    if (this.showClearButton === \"never\" || this.showClearButton === \"focus\" && !this.focused) {\n      return false;\n    }\n\n    return true;\n  };\n\n  a.prototype.render = function () {\n    var a;\n    var r = this;\n    var e = this.cancelButtonText;\n    var o = this.animated && config.getBoolean(\"animated\", true);\n    var i = getIonMode(this);\n    var t = this.clearIcon || (i === \"ios\" ? \"close-circle\" : \"close-sharp\");\n    var n = this.searchIcon || (i === \"ios\" ? \"search-outline\" : \"search-sharp\");\n    var s = this.shouldShowCancelButton();\n    var c = this.showCancelButton !== \"never\" && h(\"button\", {\n      \"aria-label\": e,\n      \"aria-hidden\": s ? undefined : \"true\",\n      type: \"button\",\n      tabIndex: i === \"ios\" && !s ? -1 : undefined,\n      onMouseDown: this.onCancelSearchbar,\n      onTouchStart: this.onCancelSearchbar,\n      class: \"searchbar-cancel-button\"\n    }, h(\"div\", {\n      \"aria-hidden\": \"true\"\n    }, i === \"md\" ? h(\"ion-icon\", {\n      \"aria-hidden\": \"true\",\n      mode: i,\n      icon: this.cancelButtonIcon,\n      lazy: false\n    }) : e));\n    return h(Host, {\n      role: \"search\",\n      \"aria-disabled\": this.disabled ? \"true\" : null,\n      class: createColorClasses(this.color, (a = {}, a[i] = true, a[\"searchbar-animated\"] = o, a[\"searchbar-disabled\"] = this.disabled, a[\"searchbar-no-animate\"] = o && this.noAnimate, a[\"searchbar-has-value\"] = this.hasValue(), a[\"searchbar-left-aligned\"] = this.shouldAlignLeft, a[\"searchbar-has-focus\"] = this.focused, a[\"searchbar-should-show-clear\"] = this.shouldShowClearButton(), a[\"searchbar-should-show-cancel\"] = this.shouldShowCancelButton(), a))\n    }, h(\"div\", {\n      class: \"searchbar-input-container\"\n    }, h(\"input\", {\n      \"aria-label\": \"search text\",\n      disabled: this.disabled,\n      ref: function (a) {\n        return r.nativeInput = a;\n      },\n      class: \"searchbar-input\",\n      inputMode: this.inputmode,\n      enterKeyHint: this.enterkeyhint,\n      onInput: this.onInput,\n      onBlur: this.onBlur,\n      onFocus: this.onFocus,\n      placeholder: this.placeholder,\n      type: this.type,\n      value: this.getValue(),\n      autoComplete: this.autocomplete,\n      autoCorrect: this.autocorrect,\n      spellcheck: this.spellcheck\n    }), i === \"md\" && c, h(\"ion-icon\", {\n      \"aria-hidden\": \"true\",\n      mode: i,\n      icon: n,\n      lazy: false,\n      class: \"searchbar-search-icon\"\n    }), h(\"button\", {\n      \"aria-label\": \"reset\",\n      type: \"button\",\n      \"no-blur\": true,\n      class: \"searchbar-clear-button\",\n      onMouseDown: function (a) {\n        return r.onClearInput(a, true);\n      },\n      onTouchStart: function (a) {\n        return r.onClearInput(a, true);\n      }\n    }, h(\"ion-icon\", {\n      \"aria-hidden\": \"true\",\n      mode: i,\n      icon: t,\n      lazy: false,\n      class: \"searchbar-clear-icon\"\n    }))), i === \"ios\" && c);\n  };\n\n  Object.defineProperty(a.prototype, \"el\", {\n    get: function () {\n      return getElement(this);\n    },\n    enumerable: false,\n    configurable: true\n  });\n  Object.defineProperty(a, \"watchers\", {\n    get: function () {\n      return {\n        debounce: [\"debounceChanged\"],\n        value: [\"valueChanged\"],\n        showCancelButton: [\"showCancelButtonChanged\"]\n      };\n    },\n    enumerable: false,\n    configurable: true\n  });\n  return a;\n}();\n\nSearchbar.style = {\n  ios: searchbarIosCss,\n  md: searchbarMdCss\n};\nexport { Searchbar as ion_searchbar };","map":{"version":3,"sources":["/Users/adekanbidansteve/github/klasha/react-klasha/ionic-test/node_modules/@ionic/core/dist/esm-es5/ion-searchbar.entry.js"],"names":["__awaiter","__generator","r","registerInstance","e","createEvent","j","forceUpdate","h","H","Host","i","getElement","c","config","b","getIonMode","f","debounceEvent","raf","createColorClasses","searchbarIosCss","searchbarMdCss","Searchbar","a","ionInput","ionChange","ionCancel","ionClear","ionBlur","ionFocus","ionStyle","isCancelVisible","shouldAlignLeft","focused","noAnimate","animated","autocomplete","autocorrect","cancelButtonIcon","get","cancelButtonText","debounce","disabled","placeholder","showCancelButton","showClearButton","spellcheck","type","value","onClearInput","emit","preventDefault","stopPropagation","setTimeout","getValue","setFocus","onCancelSearchbar","nativeInput","blur","onInput","target","onBlur","positionElements","onFocus","prototype","debounceChanged","valueChanged","showCancelButtonChanged","requestAnimationFrame","connectedCallback","emitStyle","componentDidLoad","searchbar","focus","getInputElement","Promise","resolve","o","trim","positionPlaceholder","positionCancelButton","document","dir","el","shadowRoot","querySelector","removeAttribute","createElement","innerText","body","appendChild","offsetWidth","remove","t","n","style","paddingRight","marginRight","paddingLeft","marginLeft","shouldShowCancelButton","hasValue","shouldShowClearButton","render","getBoolean","clearIcon","searchIcon","s","undefined","tabIndex","onMouseDown","onTouchStart","class","mode","icon","lazy","role","color","ref","inputMode","inputmode","enterKeyHint","enterkeyhint","autoComplete","autoCorrect","Object","defineProperty","enumerable","configurable","ios","md","ion_searchbar"],"mappings":"AAAA,SAAOA,SAAP,EAAiBC,WAAjB,QAAiC,OAAjC;AAAyC,SAAOC,CAAC,IAAIC,gBAAZ,EAA6BC,CAAC,IAAIC,WAAlC,EAA8CC,CAAC,IAAIC,WAAnD,EAA+DC,CAA/D,EAAiEC,CAAC,IAAIC,IAAtE,EAA2EC,CAAC,IAAIC,UAAhF,QAA+F,qBAA/F;AAAqH,SAAOC,CAAC,IAAIC,MAAZ,EAAmBC,CAAC,IAAIC,UAAxB,QAAuC,4BAAvC;AAAoE,SAAOC,CAAC,IAAIC,aAAZ,EAA0BhB,CAAC,IAAIiB,GAA/B,QAAuC,uBAAvC;AAA+D,SAAON,CAAC,IAAIO,kBAAZ,QAAmC,qBAAnC;AAAyD,IAAIC,eAAe,GAAC,8vUAApB;AAAmxU,IAAIC,cAAc,GAAC,0vPAAnB;;AAA8wP,IAAIC,SAAS,GAAC,YAAU;AAAC,WAASC,CAAT,CAAWA,CAAX,EAAa;AAAC,QAAItB,CAAC,GAAC,IAAN;AAAWC,IAAAA,gBAAgB,CAAC,IAAD,EAAMqB,CAAN,CAAhB;AAAyB,SAAKC,QAAL,GAAcpB,WAAW,CAAC,IAAD,EAAM,UAAN,EAAiB,CAAjB,CAAzB;AAA6C,SAAKqB,SAAL,GAAerB,WAAW,CAA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AC,iBAAD,CAAV;AAA8BO,QAAAA,KAAK,EAAC,CAAC,cAAD,CAApC;AAAqDJ,QAAAA,gBAAgB,EAAC,CAAC,yBAAD;AAAtE,OAAN;AAAyG,KAAzH;AAA0HmF,IAAAA,UAAU,EAAC,KAArI;AAA2IC,IAAAA,YAAY,EAAC;AAAxJ,GAAnC;AAAkM,SAAOzG,CAAP;AAAS,CAA1wM,EAAd;;AAA2xMD,SAAS,CAACyE,KAAV,GAAgB;AAACkC,EAAAA,GAAG,EAAC7G,eAAL;AAAqB8G,EAAAA,EAAE,EAAC7G;AAAxB,CAAhB;AAAwD,SAAOC,SAAS,IAAI6G,aAApB","sourcesContent":["import{__awaiter,__generator}from\"tslib\";import{r as registerInstance,e as createEvent,j as forceUpdate,h,H as Host,i as getElement}from\"./index-7a8b7a1c.js\";import{c as config,b as getIonMode}from\"./ionic-global-63a97a32.js\";import{f as debounceEvent,r as raf}from\"./helpers-dd7e4b7b.js\";import{c as createColorClasses}from\"./theme-ff3fc52f.js\";var searchbarIosCss=\".sc-ion-searchbar-ios-h{--placeholder-color:initial;--placeholder-font-style:initial;--placeholder-font-weight:initial;--placeholder-opacity:.5;-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased;display:-ms-flexbox;display:flex;position:relative;-ms-flex-align:center;align-items:center;width:100%;color:var(--color);font-family:var(--ion-font-family, inherit);-webkit-box-sizing:border-box;box-sizing:border-box}.ion-color.sc-ion-searchbar-ios-h{color:var(--ion-color-contrast)}.ion-color.sc-ion-searchbar-ios-h .searchbar-input.sc-ion-searchbar-ios{background:var(--ion-color-base)}.ion-color.sc-ion-searchbar-ios-h .searchbar-clear-button.sc-ion-searchbar-ios,.ion-color.sc-ion-searchbar-ios-h .searchbar-cancel-button.sc-ion-searchbar-ios,.ion-color.sc-ion-searchbar-ios-h .searchbar-search-icon.sc-ion-searchbar-ios{color:inherit}.searchbar-search-icon.sc-ion-searchbar-ios{color:var(--icon-color);pointer-events:none}.searchbar-input-container.sc-ion-searchbar-ios{display:block;position:relative;-ms-flex-negative:1;flex-shrink:1;width:100%}.searchbar-input.sc-ion-searchbar-ios{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;border-radius:var(--border-radius);display:block;width:100%;border:0;outline:none;background:var(--background);font-family:inherit;-webkit-box-shadow:var(--box-shadow);box-shadow:var(--box-shadow);-webkit-box-sizing:border-box;box-sizing:border-box;-webkit-appearance:none;-moz-appearance:none;appearance:none}.searchbar-input.sc-ion-searchbar-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)}.searchbar-input.sc-ion-searchbar-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)}.searchbar-input.sc-ion-searchbar-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)}.searchbar-input.sc-ion-searchbar-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)}.searchbar-input.sc-ion-searchbar-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)}.searchbar-input.sc-ion-searchbar-ios::-webkit-search-cancel-button,.searchbar-input.sc-ion-searchbar-ios::-ms-clear{display:none}.searchbar-cancel-button.sc-ion-searchbar-ios{margin-left:0;margin-right:0;margin-top:0;margin-bottom:0;display:none;height:100%;border:0;outline:none;color:var(--cancel-button-color);cursor:pointer;-webkit-appearance:none;-moz-appearance:none;appearance:none}.searchbar-cancel-button.sc-ion-searchbar-ios>div.sc-ion-searchbar-ios{display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;-ms-flex-pack:center;justify-content:center;width:100%;height:100%}.searchbar-clear-button.sc-ion-searchbar-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;display:none;min-height:0;outline:none;color:var(--clear-button-color);-webkit-appearance:none;-moz-appearance:none;appearance:none}.searchbar-has-value.searchbar-should-show-clear.sc-ion-searchbar-ios-h .searchbar-clear-button.sc-ion-searchbar-ios{display:block}.searchbar-disabled.sc-ion-searchbar-ios-h{cursor:default;opacity:0.4;pointer-events:none}.sc-ion-searchbar-ios-h{--background:rgba(var(--ion-text-color-rgb, 0, 0, 0), 0.07);--border-radius:10px;--box-shadow:none;--cancel-button-color:var(--ion-color-primary, #3880ff);--clear-button-color:var(--ion-color-step-600, #666666);--color:var(--ion-text-color, #000);--icon-color:var(--ion-color-step-600, #666666);padding-left:12px;padding-right:12px;padding-top:12px;padding-bottom:12px;height:60px;contain:strict}@supports ((-webkit-margin-start: 0) or (margin-inline-start: 0)) or (-webkit-margin-start: 0){.sc-ion-searchbar-ios-h{padding-left:unset;padding-right:unset;-webkit-padding-start:12px;padding-inline-start:12px;-webkit-padding-end:12px;padding-inline-end:12px}}.searchbar-input-container.sc-ion-searchbar-ios{height:36px}.searchbar-search-icon.sc-ion-searchbar-ios{margin-left:calc(50% - 60px);left:5px;top:0;position:absolute;width:22px;height:100%;contain:strict}@supports ((-webkit-margin-start: 0) or (margin-inline-start: 0)) or (-webkit-margin-start: 0){.searchbar-search-icon.sc-ion-searchbar-ios{margin-left:unset;-webkit-margin-start:calc(50% - 60px);margin-inline-start:calc(50% - 60px)}}[dir=rtl].sc-ion-searchbar-ios .searchbar-search-icon.sc-ion-searchbar-ios,[dir=rtl].sc-ion-searchbar-ios-h .searchbar-search-icon.sc-ion-searchbar-ios,[dir=rtl] .sc-ion-searchbar-ios-h .searchbar-search-icon.sc-ion-searchbar-ios{left:unset;right:unset;right:5px}.searchbar-input.sc-ion-searchbar-ios{padding-left:28px;padding-right:28px;padding-top:0;padding-bottom:0;height:100%;font-size:17px;font-weight:400;contain:strict}@supports ((-webkit-margin-start: 0) or (margin-inline-start: 0)) or (-webkit-margin-start: 0){.searchbar-input.sc-ion-searchbar-ios{padding-left:unset;padding-right:unset;-webkit-padding-start:28px;padding-inline-start:28px;-webkit-padding-end:28px;padding-inline-end:28px}}.searchbar-clear-button.sc-ion-searchbar-ios{right:0;top:0;background-position:center;position:absolute;width:30px;height:100%;border:0;background-color:transparent}[dir=rtl].sc-ion-searchbar-ios .searchbar-clear-button.sc-ion-searchbar-ios,[dir=rtl].sc-ion-searchbar-ios-h .searchbar-clear-button.sc-ion-searchbar-ios,[dir=rtl] .sc-ion-searchbar-ios-h .searchbar-clear-button.sc-ion-searchbar-ios{left:unset;right:unset;left:0}.searchbar-clear-icon.sc-ion-searchbar-ios{width:18px;height:100%}.searchbar-cancel-button.sc-ion-searchbar-ios{padding-left:8px;padding-right:0;padding-top:0;padding-bottom:0;-ms-flex-negative:0;flex-shrink:0;background-color:transparent;font-size:16px}@supports ((-webkit-margin-start: 0) or (margin-inline-start: 0)) or (-webkit-margin-start: 0){.searchbar-cancel-button.sc-ion-searchbar-ios{padding-left:unset;padding-right:unset;-webkit-padding-start:8px;padding-inline-start:8px;-webkit-padding-end:0;padding-inline-end:0}}.searchbar-left-aligned.sc-ion-searchbar-ios-h .searchbar-search-icon.sc-ion-searchbar-ios{margin-left:0}@supports ((-webkit-margin-start: 0) or (margin-inline-start: 0)) or (-webkit-margin-start: 0){.searchbar-left-aligned.sc-ion-searchbar-ios-h .searchbar-search-icon.sc-ion-searchbar-ios{margin-left:unset;-webkit-margin-start:0;margin-inline-start:0}}.searchbar-left-aligned.sc-ion-searchbar-ios-h .searchbar-input.sc-ion-searchbar-ios{padding-left:30px}@supports ((-webkit-margin-start: 0) or (margin-inline-start: 0)) or (-webkit-margin-start: 0){.searchbar-left-aligned.sc-ion-searchbar-ios-h .searchbar-input.sc-ion-searchbar-ios{padding-left:unset;-webkit-padding-start:30px;padding-inline-start:30px}}.searchbar-has-focus.sc-ion-searchbar-ios-h .searchbar-cancel-button.sc-ion-searchbar-ios,.searchbar-should-show-cancel.sc-ion-searchbar-ios-h .searchbar-cancel-button.sc-ion-searchbar-ios,.searchbar-animated.sc-ion-searchbar-ios-h .searchbar-cancel-button.sc-ion-searchbar-ios{display:block}.searchbar-animated.sc-ion-searchbar-ios-h .searchbar-search-icon.sc-ion-searchbar-ios,.searchbar-animated.sc-ion-searchbar-ios-h .searchbar-input.sc-ion-searchbar-ios{-webkit-transition:all 300ms ease;transition:all 300ms ease}.searchbar-animated.searchbar-has-focus.sc-ion-searchbar-ios-h .searchbar-cancel-button.sc-ion-searchbar-ios,.searchbar-animated.searchbar-should-show-cancel.sc-ion-searchbar-ios-h .searchbar-cancel-button.sc-ion-searchbar-ios{opacity:1;pointer-events:auto}.searchbar-animated.sc-ion-searchbar-ios-h .searchbar-cancel-button.sc-ion-searchbar-ios{margin-right:-100%;-webkit-transform:translate3d(0,  0,  0);transform:translate3d(0,  0,  0);-webkit-transition:all 300ms ease;transition:all 300ms ease;opacity:0;pointer-events:none}@supports ((-webkit-margin-start: 0) or (margin-inline-start: 0)) or (-webkit-margin-start: 0){.searchbar-animated.sc-ion-searchbar-ios-h .searchbar-cancel-button.sc-ion-searchbar-ios{margin-right:unset;-webkit-margin-end:-100%;margin-inline-end:-100%}}.searchbar-no-animate.sc-ion-searchbar-ios-h .searchbar-search-icon.sc-ion-searchbar-ios,.searchbar-no-animate.sc-ion-searchbar-ios-h .searchbar-input.sc-ion-searchbar-ios,.searchbar-no-animate.sc-ion-searchbar-ios-h .searchbar-cancel-button.sc-ion-searchbar-ios{-webkit-transition-duration:0ms;transition-duration:0ms}.ion-color.sc-ion-searchbar-ios-h .searchbar-cancel-button.sc-ion-searchbar-ios{color:var(--ion-color-base)}@media (any-hover: hover){.ion-color.sc-ion-searchbar-ios-h .searchbar-cancel-button.sc-ion-searchbar-ios:hover{color:var(--ion-color-tint)}}ion-toolbar.sc-ion-searchbar-ios-h,ion-toolbar .sc-ion-searchbar-ios-h{padding-top:1px;padding-bottom:15px;height:52px}ion-toolbar.ion-color.sc-ion-searchbar-ios-h:not(.ion-color),ion-toolbar.ion-color .sc-ion-searchbar-ios-h:not(.ion-color){color:inherit}ion-toolbar.ion-color.sc-ion-searchbar-ios-h:not(.ion-color) .searchbar-cancel-button.sc-ion-searchbar-ios,ion-toolbar.ion-color .sc-ion-searchbar-ios-h:not(.ion-color) .searchbar-cancel-button.sc-ion-searchbar-ios{color:currentColor}ion-toolbar.ion-color.sc-ion-searchbar-ios-h .searchbar-search-icon.sc-ion-searchbar-ios,ion-toolbar.ion-color .sc-ion-searchbar-ios-h .searchbar-search-icon.sc-ion-searchbar-ios{color:currentColor;opacity:0.5}ion-toolbar.ion-color.sc-ion-searchbar-ios-h:not(.ion-color) .searchbar-input.sc-ion-searchbar-ios,ion-toolbar.ion-color .sc-ion-searchbar-ios-h:not(.ion-color) .searchbar-input.sc-ion-searchbar-ios{background:rgba(var(--ion-color-contrast-rgb), 0.07);color:currentColor}ion-toolbar.ion-color.sc-ion-searchbar-ios-h:not(.ion-color) .searchbar-clear-button.sc-ion-searchbar-ios,ion-toolbar.ion-color .sc-ion-searchbar-ios-h:not(.ion-color) .searchbar-clear-button.sc-ion-searchbar-ios{color:currentColor;opacity:0.5}\";var searchbarMdCss=\".sc-ion-searchbar-md-h{--placeholder-color:initial;--placeholder-font-style:initial;--placeholder-font-weight:initial;--placeholder-opacity:.5;-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased;display:-ms-flexbox;display:flex;position:relative;-ms-flex-align:center;align-items:center;width:100%;color:var(--color);font-family:var(--ion-font-family, inherit);-webkit-box-sizing:border-box;box-sizing:border-box}.ion-color.sc-ion-searchbar-md-h{color:var(--ion-color-contrast)}.ion-color.sc-ion-searchbar-md-h .searchbar-input.sc-ion-searchbar-md{background:var(--ion-color-base)}.ion-color.sc-ion-searchbar-md-h .searchbar-clear-button.sc-ion-searchbar-md,.ion-color.sc-ion-searchbar-md-h .searchbar-cancel-button.sc-ion-searchbar-md,.ion-color.sc-ion-searchbar-md-h .searchbar-search-icon.sc-ion-searchbar-md{color:inherit}.searchbar-search-icon.sc-ion-searchbar-md{color:var(--icon-color);pointer-events:none}.searchbar-input-container.sc-ion-searchbar-md{display:block;position:relative;-ms-flex-negative:1;flex-shrink:1;width:100%}.searchbar-input.sc-ion-searchbar-md{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;border-radius:var(--border-radius);display:block;width:100%;border:0;outline:none;background:var(--background);font-family:inherit;-webkit-box-shadow:var(--box-shadow);box-shadow:var(--box-shadow);-webkit-box-sizing:border-box;box-sizing:border-box;-webkit-appearance:none;-moz-appearance:none;appearance:none}.searchbar-input.sc-ion-searchbar-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)}.searchbar-input.sc-ion-searchbar-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)}.searchbar-input.sc-ion-searchbar-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)}.searchbar-input.sc-ion-searchbar-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)}.searchbar-input.sc-ion-searchbar-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)}.searchbar-input.sc-ion-searchbar-md::-webkit-search-cancel-button,.searchbar-input.sc-ion-searchbar-md::-ms-clear{display:none}.searchbar-cancel-button.sc-ion-searchbar-md{margin-left:0;margin-right:0;margin-top:0;margin-bottom:0;display:none;height:100%;border:0;outline:none;color:var(--cancel-button-color);cursor:pointer;-webkit-appearance:none;-moz-appearance:none;appearance:none}.searchbar-cancel-button.sc-ion-searchbar-md>div.sc-ion-searchbar-md{display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;-ms-flex-pack:center;justify-content:center;width:100%;height:100%}.searchbar-clear-button.sc-ion-searchbar-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;display:none;min-height:0;outline:none;color:var(--clear-button-color);-webkit-appearance:none;-moz-appearance:none;appearance:none}.searchbar-has-value.searchbar-should-show-clear.sc-ion-searchbar-md-h .searchbar-clear-button.sc-ion-searchbar-md{display:block}.searchbar-disabled.sc-ion-searchbar-md-h{cursor:default;opacity:0.4;pointer-events:none}.sc-ion-searchbar-md-h{--background:var(--ion-background-color, #fff);--border-radius:2px;--box-shadow:0 2px 2px 0 rgba(0, 0, 0, 0.14), 0 3px 1px -2px rgba(0, 0, 0, 0.2), 0 1px 5px 0 rgba(0, 0, 0, 0.12);--cancel-button-color:var(--ion-color-step-900, #1a1a1a);--clear-button-color:initial;--color:var(--ion-color-step-850, #262626);--icon-color:var(--ion-color-step-600, #666666);padding-left:8px;padding-right:8px;padding-top:8px;padding-bottom:8px;background:inherit}@supports ((-webkit-margin-start: 0) or (margin-inline-start: 0)) or (-webkit-margin-start: 0){.sc-ion-searchbar-md-h{padding-left:unset;padding-right:unset;-webkit-padding-start:8px;padding-inline-start:8px;-webkit-padding-end:8px;padding-inline-end:8px}}.searchbar-search-icon.sc-ion-searchbar-md{left:16px;top:11px;width:21px;height:21px}[dir=rtl].sc-ion-searchbar-md .searchbar-search-icon.sc-ion-searchbar-md,[dir=rtl].sc-ion-searchbar-md-h .searchbar-search-icon.sc-ion-searchbar-md,[dir=rtl] .sc-ion-searchbar-md-h .searchbar-search-icon.sc-ion-searchbar-md{left:unset;right:unset;right:16px}.searchbar-cancel-button.sc-ion-searchbar-md{left:5px;top:0;background-color:transparent;font-size:1.6em}[dir=rtl].sc-ion-searchbar-md .searchbar-cancel-button.sc-ion-searchbar-md,[dir=rtl].sc-ion-searchbar-md-h .searchbar-cancel-button.sc-ion-searchbar-md,[dir=rtl] .sc-ion-searchbar-md-h .searchbar-cancel-button.sc-ion-searchbar-md{left:unset;right:unset;right:5px}.searchbar-search-icon.sc-ion-searchbar-md,.searchbar-cancel-button.sc-ion-searchbar-md{position:absolute}.searchbar-search-icon.ion-activated.sc-ion-searchbar-md,.searchbar-cancel-button.ion-activated.sc-ion-searchbar-md{background-color:transparent}.searchbar-input.sc-ion-searchbar-md{padding-left:55px;padding-right:55px;padding-top:6px;padding-bottom:6px;background-position:left 8px center;height:auto;font-size:16px;font-weight:400;line-height:30px}@supports ((-webkit-margin-start: 0) or (margin-inline-start: 0)) or (-webkit-margin-start: 0){.searchbar-input.sc-ion-searchbar-md{padding-left:unset;padding-right:unset;-webkit-padding-start:55px;padding-inline-start:55px;-webkit-padding-end:55px;padding-inline-end:55px}}[dir=rtl].sc-ion-searchbar-md .searchbar-input.sc-ion-searchbar-md,[dir=rtl].sc-ion-searchbar-md-h .searchbar-input.sc-ion-searchbar-md,[dir=rtl] .sc-ion-searchbar-md-h .searchbar-input.sc-ion-searchbar-md{background-position:right 8px center}.searchbar-clear-button.sc-ion-searchbar-md{right:13px;top:0;padding-left:0;padding-right:0;padding-top:0;padding-bottom:0;position:absolute;height:100%;border:0;background-color:transparent}[dir=rtl].sc-ion-searchbar-md .searchbar-clear-button.sc-ion-searchbar-md,[dir=rtl].sc-ion-searchbar-md-h .searchbar-clear-button.sc-ion-searchbar-md,[dir=rtl] .sc-ion-searchbar-md-h .searchbar-clear-button.sc-ion-searchbar-md{left:unset;right:unset;left:13px}.searchbar-clear-button.ion-activated.sc-ion-searchbar-md{background-color:transparent}.searchbar-clear-icon.sc-ion-searchbar-md{width:22px;height:100%}.searchbar-has-focus.sc-ion-searchbar-md-h .searchbar-search-icon.sc-ion-searchbar-md{display:block}.searchbar-has-focus.sc-ion-searchbar-md-h .searchbar-cancel-button.sc-ion-searchbar-md,.searchbar-should-show-cancel.sc-ion-searchbar-md-h .searchbar-cancel-button.sc-ion-searchbar-md{display:block}.searchbar-has-focus.sc-ion-searchbar-md-h .searchbar-cancel-button.sc-ion-searchbar-md+.searchbar-search-icon.sc-ion-searchbar-md,.searchbar-should-show-cancel.sc-ion-searchbar-md-h .searchbar-cancel-button.sc-ion-searchbar-md+.searchbar-search-icon.sc-ion-searchbar-md{display:none}ion-toolbar.sc-ion-searchbar-md-h,ion-toolbar .sc-ion-searchbar-md-h{padding-left:7px;padding-right:7px;padding-top:3px;padding-bottom:3px}@supports ((-webkit-margin-start: 0) or (margin-inline-start: 0)) or (-webkit-margin-start: 0){ion-toolbar.sc-ion-searchbar-md-h,ion-toolbar .sc-ion-searchbar-md-h{padding-left:unset;padding-right:unset;-webkit-padding-start:7px;padding-inline-start:7px;-webkit-padding-end:7px;padding-inline-end:7px}}\";var Searchbar=function(){function a(a){var r=this;registerInstance(this,a);this.ionInput=createEvent(this,\"ionInput\",7);this.ionChange=createEvent(this,\"ionChange\",7);this.ionCancel=createEvent(this,\"ionCancel\",7);this.ionClear=createEvent(this,\"ionClear\",7);this.ionBlur=createEvent(this,\"ionBlur\",7);this.ionFocus=createEvent(this,\"ionFocus\",7);this.ionStyle=createEvent(this,\"ionStyle\",7);this.isCancelVisible=false;this.shouldAlignLeft=true;this.focused=false;this.noAnimate=true;this.animated=false;this.autocomplete=\"off\";this.autocorrect=\"off\";this.cancelButtonIcon=config.get(\"backButtonIcon\",\"arrow-back-sharp\");this.cancelButtonText=\"Cancel\";this.debounce=250;this.disabled=false;this.placeholder=\"Search\";this.showCancelButton=\"never\";this.showClearButton=\"focus\";this.spellcheck=false;this.type=\"search\";this.value=\"\";this.onClearInput=function(a,e){r.ionClear.emit();if(a){a.preventDefault();a.stopPropagation()}setTimeout((function(){var a=r.getValue();if(a!==\"\"){r.value=\"\";r.ionInput.emit();if(e&&!r.focused){r.setFocus()}}}),16*4)};this.onCancelSearchbar=function(a){if(a){a.preventDefault();a.stopPropagation()}r.ionCancel.emit();r.onClearInput();if(r.nativeInput){r.nativeInput.blur()}};this.onInput=function(a){var e=a.target;if(e){r.value=e.value}r.ionInput.emit(a)};this.onBlur=function(){r.focused=false;r.ionBlur.emit();r.positionElements()};this.onFocus=function(){r.focused=true;r.ionFocus.emit();r.positionElements()}}a.prototype.debounceChanged=function(){this.ionChange=debounceEvent(this.ionChange,this.debounce)};a.prototype.valueChanged=function(){var a=this.nativeInput;var r=this.getValue();if(a&&a.value!==r){a.value=r}this.ionChange.emit({value:r})};a.prototype.showCancelButtonChanged=function(){var a=this;requestAnimationFrame((function(){a.positionElements();forceUpdate(a)}))};a.prototype.connectedCallback=function(){this.emitStyle()};a.prototype.componentDidLoad=function(){var a=this;this.positionElements();this.debounceChanged();setTimeout((function(){a.noAnimate=false}),300)};a.prototype.emitStyle=function(){this.ionStyle.emit({searchbar:true})};a.prototype.setFocus=function(){return __awaiter(this,void 0,void 0,(function(){return __generator(this,(function(a){if(this.nativeInput){this.nativeInput.focus()}return[2]}))}))};a.prototype.getInputElement=function(){return Promise.resolve(this.nativeInput)};a.prototype.positionElements=function(){var a=this.getValue();var r=this.shouldAlignLeft;var e=getIonMode(this);var o=!this.animated||a.trim()!==\"\"||!!this.focused;this.shouldAlignLeft=o;if(e!==\"ios\"){return}if(r!==o){this.positionPlaceholder()}if(this.animated){this.positionCancelButton()}};a.prototype.positionPlaceholder=function(){var a=this.nativeInput;if(!a){return}var r=document.dir===\"rtl\";var e=(this.el.shadowRoot||this.el).querySelector(\".searchbar-search-icon\");if(this.shouldAlignLeft){a.removeAttribute(\"style\");e.removeAttribute(\"style\")}else{var o=document;var i=o.createElement(\"span\");i.innerText=this.placeholder||\"\";o.body.appendChild(i);raf((function(){var o=i.offsetWidth;i.remove();var t=\"calc(50% - \"+o/2+\"px)\";var n=\"calc(50% - \"+(o/2+30)+\"px)\";if(r){a.style.paddingRight=t;e.style.marginRight=n}else{a.style.paddingLeft=t;e.style.marginLeft=n}}))}};a.prototype.positionCancelButton=function(){var a=document.dir===\"rtl\";var r=(this.el.shadowRoot||this.el).querySelector(\".searchbar-cancel-button\");var e=this.shouldShowCancelButton();if(r&&e!==this.isCancelVisible){var o=r.style;this.isCancelVisible=e;if(e){if(a){o.marginLeft=\"0\"}else{o.marginRight=\"0\"}}else{var i=r.offsetWidth;if(i>0){if(a){o.marginLeft=-i+\"px\"}else{o.marginRight=-i+\"px\"}}}}};a.prototype.getValue=function(){return this.value||\"\"};a.prototype.hasValue=function(){return this.getValue()!==\"\"};a.prototype.shouldShowCancelButton=function(){if(this.showCancelButton===\"never\"||this.showCancelButton===\"focus\"&&!this.focused){return false}return true};a.prototype.shouldShowClearButton=function(){if(this.showClearButton===\"never\"||this.showClearButton===\"focus\"&&!this.focused){return false}return true};a.prototype.render=function(){var a;var r=this;var e=this.cancelButtonText;var o=this.animated&&config.getBoolean(\"animated\",true);var i=getIonMode(this);var t=this.clearIcon||(i===\"ios\"?\"close-circle\":\"close-sharp\");var n=this.searchIcon||(i===\"ios\"?\"search-outline\":\"search-sharp\");var s=this.shouldShowCancelButton();var c=this.showCancelButton!==\"never\"&&h(\"button\",{\"aria-label\":e,\"aria-hidden\":s?undefined:\"true\",type:\"button\",tabIndex:i===\"ios\"&&!s?-1:undefined,onMouseDown:this.onCancelSearchbar,onTouchStart:this.onCancelSearchbar,class:\"searchbar-cancel-button\"},h(\"div\",{\"aria-hidden\":\"true\"},i===\"md\"?h(\"ion-icon\",{\"aria-hidden\":\"true\",mode:i,icon:this.cancelButtonIcon,lazy:false}):e));return h(Host,{role:\"search\",\"aria-disabled\":this.disabled?\"true\":null,class:createColorClasses(this.color,(a={},a[i]=true,a[\"searchbar-animated\"]=o,a[\"searchbar-disabled\"]=this.disabled,a[\"searchbar-no-animate\"]=o&&this.noAnimate,a[\"searchbar-has-value\"]=this.hasValue(),a[\"searchbar-left-aligned\"]=this.shouldAlignLeft,a[\"searchbar-has-focus\"]=this.focused,a[\"searchbar-should-show-clear\"]=this.shouldShowClearButton(),a[\"searchbar-should-show-cancel\"]=this.shouldShowCancelButton(),a))},h(\"div\",{class:\"searchbar-input-container\"},h(\"input\",{\"aria-label\":\"search text\",disabled:this.disabled,ref:function(a){return r.nativeInput=a},class:\"searchbar-input\",inputMode:this.inputmode,enterKeyHint:this.enterkeyhint,onInput:this.onInput,onBlur:this.onBlur,onFocus:this.onFocus,placeholder:this.placeholder,type:this.type,value:this.getValue(),autoComplete:this.autocomplete,autoCorrect:this.autocorrect,spellcheck:this.spellcheck}),i===\"md\"&&c,h(\"ion-icon\",{\"aria-hidden\":\"true\",mode:i,icon:n,lazy:false,class:\"searchbar-search-icon\"}),h(\"button\",{\"aria-label\":\"reset\",type:\"button\",\"no-blur\":true,class:\"searchbar-clear-button\",onMouseDown:function(a){return r.onClearInput(a,true)},onTouchStart:function(a){return r.onClearInput(a,true)}},h(\"ion-icon\",{\"aria-hidden\":\"true\",mode:i,icon:t,lazy:false,class:\"searchbar-clear-icon\"}))),i===\"ios\"&&c)};Object.defineProperty(a.prototype,\"el\",{get:function(){return getElement(this)},enumerable:false,configurable:true});Object.defineProperty(a,\"watchers\",{get:function(){return{debounce:[\"debounceChanged\"],value:[\"valueChanged\"],showCancelButton:[\"showCancelButtonChanged\"]}},enumerable:false,configurable:true});return a}();Searchbar.style={ios:searchbarIosCss,md:searchbarMdCss};export{Searchbar as ion_searchbar};"]},"metadata":{},"sourceType":"module"}