import {NgFor, NgIf} from 'angular2/angular2'; import {Ancestor} from 'angular2/src/core/annotations_impl/visibility'; import {Component, Directive} from 'angular2/src/core/annotations_impl/annotations'; import {View} from 'angular2/src/core/annotations_impl/view'; import {Routable, NavbarTemplate, Navbar, NavController, Button, Content} from 'ionic/ionic'; @Component({ selector: 'ion-view' }) @View({ template: ` Buttons

Buttons

The faithful button. Not only our favorite place to click, but a true friend.

Buttons come in lots of different colors, sizes (like those that take up the full width and those that flow inline), and shapes.

CLICKED

`, directives: [NavbarTemplate, Navbar, Content, Button, NgIf] }) export class ButtonPage { constructor(nav: NavController) { this.nav = nav; window.nav = nav; } onButtonClick(event) { console.log('On button click', event); clearTimeout(this.clickTimeout); this.clicked = true; this.clickTimeout = setTimeout(() => { this.clicked = false; }, 500); } } new Routable(ButtonPage, { url: '/components/button', tag: 'button' })