mirror of
https://github.com/ionic-team/ionic-framework.git
synced 2025-08-23 05:58:26 +08:00
chore(demos): update demos to work
* chore(demos): WIP refactor gulp demos task to use SystemJS move build files into dist/demos and comment out the AoT demos task for right now. This makes both `gulp demos` and `gulp demos.watch`work again. references #8411 * docs(demos): fix infinite scroll demo * chore(demos): move old demos task to demos.prod update the demos file with shared tasks, include the shared css * docs(demos): fix API demos to use correct styles * chore(demos): remove the main.ts files from each demo * chore(demos): add prod template and constant * chore(demos): remove tsconfig and package from demos * chore(demos): update app.module path to ionic * chore(demos): update app.module path to ionic * chore(demos): update prod task for demos to work with AoT also puts the demo build files into dist/ instead of the src directory * docs(demos): update deploy and docs tasks for new build * docs(scripts): update demos README * chore(demos): fix path for prod build
This commit is contained in:

committed by
Adam Bradley

parent
3701ee5e37
commit
1f83cde78b
@ -1,6 +1,98 @@
|
||||
import { NgModule } from '@angular/core';
|
||||
import { IonicApp, IonicModule } from 'ionic-angular';
|
||||
import { ApiDemoApp, ApiDemoPage } from './app.component';
|
||||
import { Component, NgModule } from '@angular/core';
|
||||
import { IonicApp, IonicModule } from '../';
|
||||
|
||||
|
||||
@Component({
|
||||
templateUrl: 'page.html'
|
||||
})
|
||||
export class ApiDemoPage {
|
||||
appType = 'Paid';
|
||||
safari = 'Shared Links';
|
||||
weather = 'sunny';
|
||||
|
||||
apps = {
|
||||
'Paid': [
|
||||
{
|
||||
name: 'Monopoly',
|
||||
price: '$0.99'
|
||||
},
|
||||
{
|
||||
name: 'Angry Birds',
|
||||
price: '$2.99'
|
||||
}
|
||||
],
|
||||
'Free': [
|
||||
{
|
||||
name: 'Snapchat',
|
||||
price: 'GET'
|
||||
},
|
||||
{
|
||||
name: 'Instagram',
|
||||
price: 'OPEN'
|
||||
}
|
||||
],
|
||||
'Top': [
|
||||
{
|
||||
name: 'Spotify',
|
||||
price: 'OPEN'
|
||||
},
|
||||
{
|
||||
name: 'Pandora',
|
||||
price: 'GET'
|
||||
}
|
||||
]
|
||||
};
|
||||
|
||||
items = {
|
||||
'Bookmarks': [
|
||||
{
|
||||
name: 'Favorites',
|
||||
icon: 'ios-star-outline'
|
||||
},
|
||||
{
|
||||
name: 'History',
|
||||
icon: 'ios-clock-outline'
|
||||
}
|
||||
],
|
||||
'Reading List': [
|
||||
{
|
||||
name: 'Terms of Service',
|
||||
icon: 'create'
|
||||
},
|
||||
{
|
||||
name: 'User Guide',
|
||||
icon: 'book'
|
||||
}
|
||||
],
|
||||
'Shared Links': [
|
||||
{
|
||||
name: 'Ionic Framework',
|
||||
icon: 'ionic'
|
||||
},
|
||||
{
|
||||
name: 'Learn Angular',
|
||||
icon: 'logo-angular'
|
||||
}
|
||||
]
|
||||
};
|
||||
|
||||
getItems(type) {
|
||||
return this.apps[type];
|
||||
}
|
||||
|
||||
getSafariItems(type) {
|
||||
return this.items[type];
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@Component({
|
||||
template: '<ion-nav [root]="root"></ion-nav>'
|
||||
})
|
||||
export class ApiDemoApp {
|
||||
root = ApiDemoPage;
|
||||
}
|
||||
|
||||
|
||||
@NgModule({
|
||||
declarations: [
|
||||
|
Reference in New Issue
Block a user