chore(): transition most recently updated components from stencil into @ionic/core

This commit is contained in:
Josh Thomas
2017-06-28 14:59:46 -05:00
parent f511aecd0a
commit 93fb58f307
38 changed files with 2462 additions and 21 deletions

View File

@ -1,7 +1,6 @@
import { Component, h, Listen, Prop, Watch, VNodeData, Ionic } from '@stencil/core';
import { Component, h, Listen, Prop, VNodeData, Ionic } from '@stencil/core';
import { BooleanInputComponent, GestureDetail } from '../../utils/interfaces';
@Component({
tag: 'ion-toggle',
styleUrls: {
@ -24,22 +23,22 @@ export class Toggle implements BooleanInputComponent {
@Prop() color: string;
@Prop() mode: string;
@Prop({ twoWay: true }) checked: boolean = false;
@Prop({ twoWay: true }) disabled: boolean = false;
@Prop({ twoWay: true }) value: string;
@Prop({ state: true }) checked: boolean = false;
@Prop({ state: true }) disabled: boolean = false;
@Prop({ state: true }) value: string;
ionViewWillLoad() {
this.emitStyle();
}
@Watch('checked')
@PropDidChange('checked')
changed(val: boolean) {
Ionic.emit(this, 'ionChange', { detail: { checked: val } });
this.emitStyle();
}
@Watch('disabled')
@PropDidChange('disabled')
disableChanged() {
this.emitStyle();
}