refactor(events): rename all Ionic events to start with ion

BREAKING CHANGES:

Renamed all Ionic events to start with `ion`. The following events were
renamed:

- **Checkbox**
  - `change` -> `ionChange`
- **DateTime**
  - `change` -> `ionChange`
  - `cancel` -> `ionCancel`
- **InfiniteScroll**
  - `infinite` -> `ionInfinite`
- **Menu**
  - `opening` -> `ionDrag`
  - `opened` -> `ionOpen`
  - `closed` -> `ionClose`
- **Option**
  - `select` -> `ionSelect`
- **Picker**
  - `change` -> `ionChange`
- **RadioButton**
  - `select` -> `ionSelect`
- **RadioGroup**
  - `change` -> `ionChange`
- **Refresher**
  - `refresh` -> `ionRefresh`
  - `pulling` -> `ionPull`
  - `start` -> `ionStart`
- **Searchbar**
  - `input` -> `ionInput`
  - `blur` -> `ionBlur`
  - `focus` -> `ionFocus`
  - `cancel` -> `ionCancel`
  - `clear` -> `ionClear`
- **Segment**
  - `change` -> `ionChange`
  - `select` -> `ionSelect`
- **Select**
  - `change` -> `ionChange`
  - `cancel` -> `ionCancel`
- **Slides**
  - `willChange` -> `ionWillChange`
  - `didChange` -> `ionDidChange`
  - `move` -> `ionDrag`
- **TabButton**
  - `select` -> `ionSelect`
- **Tab**
  - `select` -> `ionSelect`
- **Tabs**
  - `change` -> `ionChange`
- **Toggle**
  - `change` -> `ionChange`

Closes #6568
This commit is contained in:
Brandy Carney
2016-05-31 12:01:46 -04:00
parent f6f16340e2
commit d563aa65a3
45 changed files with 172 additions and 174 deletions

View File

@@ -178,12 +178,12 @@ export class Select {
/**
* @output {any} Any expression you want to evaluate when the selection has changed.
*/
@Output() change: EventEmitter<any> = new EventEmitter();
@Output() ionChange: EventEmitter<any> = new EventEmitter();
/**
* @output {any} Any expression you want to evaluate when the selection was cancelled.
*/
@Output() cancel: EventEmitter<any> = new EventEmitter();
@Output() ionCancel: EventEmitter<any> = new EventEmitter();
constructor(
private _form: Form,
@@ -239,7 +239,7 @@ export class Select {
text: this.cancelText,
role: 'cancel',
handler: () => {
this.cancel.emit(null);
this.ionCancel.emit(null);
}
}];
@@ -268,7 +268,7 @@ export class Select {
text: input.text,
handler: () => {
this.onChange(input.value);
this.change.emit(input.value);
this.ionChange.emit(input.value);
}
};
}));
@@ -307,7 +307,7 @@ export class Select {
text: this.okText,
handler: selectedValues => {
this.onChange(selectedValues);
this.change.emit(selectedValues);
this.ionChange.emit(selectedValues);
}
});

View File

@@ -22,7 +22,7 @@
<ion-item>
<ion-label>Car Features</ion-label>
<ion-select [(ngModel)]="carFeatures" [multiple]="true" (change)="carChange($event)">
<ion-select [(ngModel)]="carFeatures" [multiple]="true" (ionChange)="carChange($event)">
<ion-option value="backupcamera">Backup Camera</ion-option>
<ion-option value="heatedseats">Headted Seats</ion-option>
<ion-option value="keyless">Keyless Entry</ion-option>

View File

@@ -14,7 +14,7 @@
<ion-item>
<ion-label>Gaming</ion-label>
<ion-select [(ngModel)]="gaming" (cancel)="gamingCancel()" (change)="gamingChange($event)">
<ion-select [(ngModel)]="gaming" (ionCancel)="gamingCancel()" (ionChange)="gamingChange($event)">
<ion-option value="nes">NES</ion-option>
<ion-option value="n64">Nintendo64</ion-option>
<ion-option value="ps">PlayStation</ion-option>
@@ -56,7 +56,7 @@
<ion-option>Pearl Jam</ion-option>
<ion-option>Smashing Pumpkins</ion-option>
<ion-option>Soundgarden</ion-option>
<ion-option (select)="stpSelect()">Stone Temple Pilots</ion-option>
<ion-option (ionSelect)="stpSelect()">Stone Temple Pilots</ion-option>
</ion-select>
</ion-item>
@@ -96,4 +96,4 @@
<br>
</p>
</ion-content>
</ion-content>