Skip to content
Permalink
Browse files

fix(input): prevent input from losing focus when tapping clear button (

  • Loading branch information...
konnectappdev authored and liamdebeasi committed Apr 16, 2019
1 parent 11aa48c commit 29bb4fcb05521ef42c543374b80fc149c056c714
Showing with 6 additions and 1 deletion.
  1. +6 −1 core/src/components/input/input.tsx
@@ -307,7 +307,12 @@ export class Input implements ComponentInterface {
}
}

private clearTextInput = () => {
private clearTextInput = (ev?: Event) => {
if (this.clearInput && !this.readonly && !this.disabled && ev) {
ev.preventDefault();
ev.stopPropagation();
}

this.value = '';
}

0 comments on commit 29bb4fc

Please sign in to comment.
You can’t perform that action at this time.