From bde103d2fb22ff6b4a7acf92dfda6fad30e2f634 Mon Sep 17 00:00:00 2001 From: Pekes317 Date: Mon, 25 Apr 2016 08:42:22 -0500 Subject: [PATCH] fix(input): clear text input * Added Type Button To prevent the clear button to call submit function if ngSubmit is used. * Clear Input Action. Added a change value action to the clearTextInput function. It now actually clears input --- ionic/components/input/input-base.ts | 1 + ionic/components/input/input.ts | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/ionic/components/input/input-base.ts b/ionic/components/input/input-base.ts index 9c7aa05ffdb..bac4b9dc80f 100644 --- a/ionic/components/input/input-base.ts +++ b/ionic/components/input/input-base.ts @@ -406,6 +406,7 @@ export class InputBase { */ clearTextInput() { console.debug('Should clear input'); + this._value = ''; } /** diff --git a/ionic/components/input/input.ts b/ionic/components/input/input.ts index e76cc8f60f0..51d2bcd682f 100644 --- a/ionic/components/input/input.ts +++ b/ionic/components/input/input.ts @@ -67,7 +67,7 @@ import {Platform} from '../../platform/platform'; template: '' + '' + - '' + + '' + '
', directives: [ NgIf,