diff --git a/src/components/input/input-base.ts b/src/components/input/input-base.ts index 41f276026c..9016fbd6b8 100644 --- a/src/components/input/input-base.ts +++ b/src/components/input/input-base.ts @@ -1,17 +1,16 @@ -import {Directive, Input, Output, EventEmitter, HostListener, ViewChild, ElementRef} from '@angular/core'; -import {NgControl} from '@angular/common'; +import { ElementRef, EventEmitter, Input, Output, ViewChild } from '@angular/core'; +import { NgControl } from '@angular/common'; -import {Config} from '../../config/config'; -import {Content} from '../content/content'; -import {Form} from '../../util/form'; -import {Item} from '../item/item'; -import {App} from '../app/app'; -import {isTrueProperty} from '../../util/util'; -import {Label} from '../label/label'; -import {pointerCoord, hasPointerMoved, closest, copyInputAttributes, Coordinates} from '../../util/dom'; -import {NavController} from '../nav/nav-controller'; -import {NativeInput, NextInput} from './native-input'; -import {Platform} from '../../platform/platform'; +import { App } from '../app/app'; +import { closest, copyInputAttributes, Coordinates, hasPointerMoved, pointerCoord } from '../../util/dom'; +import { Config } from '../../config/config'; +import { Content } from '../content/content'; +import { Form } from '../../util/form'; +import { isTrueProperty } from '../../util/util'; +import { Item } from '../item/item'; +import { NativeInput, NextInput } from './native-input'; +import { NavController } from '../nav/nav-controller'; +import { Platform } from '../../platform/platform'; export class InputBase { @@ -23,7 +22,7 @@ export class InputBase { protected _type: string = 'text'; protected _useAssist: boolean; protected _usePadding: boolean; - protected _value = ''; + protected _value: any = ''; protected _isTouch: boolean; protected _autoFocusAssist: string; protected _autoComplete: string; @@ -34,8 +33,8 @@ export class InputBase { @Input() clearInput: any; @Input() placeholder: string = ''; @ViewChild(NativeInput) protected _native: NativeInput; - @Output() blur: EventEmitter = new EventEmitter; - @Output() focus: EventEmitter = new EventEmitter; + @Output() blur: EventEmitter = new EventEmitter(); + @Output() focus: EventEmitter = new EventEmitter(); constructor( config: Config, @@ -140,7 +139,7 @@ export class InputBase { return this._value; } - set value(val) { + set value(val: any) { this._value = val; this.checkHasValue(val); }