mirror of
https://github.com/ionic-team/ionic-framework.git
synced 2025-08-18 19:21:34 +08:00
31 lines
544 B
TypeScript
31 lines
544 B
TypeScript
import {Directive} from 'angular2/angular2';
|
|
|
|
|
|
/**
|
|
* TODO
|
|
*/
|
|
@Directive({
|
|
selector: 'button,[button],[menu-toggle]',
|
|
host: {
|
|
'[class.icon-left]': 'iconLeft',
|
|
'[class.icon-right]': 'iconRight',
|
|
'[class.icon-only]': 'iconOnly'
|
|
}
|
|
})
|
|
export class Button {
|
|
|
|
constructor() {
|
|
this.iconLeft = this.iconRight = this.iconOnly = false;
|
|
}
|
|
|
|
/**
|
|
* TODO
|
|
* @param {TODO} icon TODO
|
|
*/
|
|
registerIcon(icon) {
|
|
this.iconLeft = icon.iconLeft;
|
|
this.iconRight = icon.iconRight;
|
|
this.iconOnly = icon.iconOnly;
|
|
}
|
|
}
|