docs(demos/switch): api demo

This commit is contained in:
Drew Rygh
2015-12-10 12:54:21 -06:00
parent 791cb2017e
commit 8929510197
4 changed files with 80 additions and 1 deletions

2
demos/switch/app.html Normal file
View File

@ -0,0 +1,2 @@
<ion-nav id="nav" [root]="rootPage" #content></ion-nav>
<ion-overlay></ion-overlay>

20
demos/switch/index.ts Normal file
View File

@ -0,0 +1,20 @@
import {App, Page, IonicApp} from 'ionic/ionic';
@App({
templateUrl: 'app.html'
})
class ApiDemoApp {
constructor() {
this.rootPage = InitialPage;
}
}
@Page({
templateUrl: 'main.html'
})
export class InitialPage {
constructor() {
}
}

57
demos/switch/main.html Normal file
View File

@ -0,0 +1,57 @@
<ion-navbar *navbar>
<ion-title>Switch</ion-title>
</ion-navbar>
<ion-content>
<ion-list>
<ion-switch value="foo" checked="true">
Frodo Baggins
</ion-switch>
<ion-switch energized>
Sam
</ion-switch>
<ion-switch danger checked="true">
Éowyn
</ion-switch>
<ion-switch royal checked="true">
Legolas
</ion-switch>
<ion-switch danger>
Gimli
</ion-switch>
<ion-switch dark checked="true">
Saruman
</ion-switch>
<ion-switch energized checked="true">
Gandalf
</ion-switch>
<ion-switch royal>
Arwen
</ion-switch>
<ion-switch secondary checked="true">
Treebeard
</ion-switch>
<ion-switch royal>
Boromir
</ion-switch>
<ion-switch dark checked="true">
Gollum
</ion-switch>
<ion-switch energized>
Galadriel
</ion-switch>
</ion-list>
<ion-content>

View File

@ -67,7 +67,7 @@ class MediaSwitch {
*
* </ion-list>
* ```
*
* @demo /docs/v2/demos/switch/
* @see {@link /docs/v2/components#switch Switch Component Docs}
*/
@Component({