mirror of
https://github.com/ionic-team/ionic-framework.git
synced 2026-03-13 10:22:08 +08:00
Native demo
This commit is contained in:
@@ -17,7 +17,9 @@ import {VibrationPage} from 'pages/vibration';
|
||||
templateUrl: 'main.html'
|
||||
})
|
||||
class IonicApp {
|
||||
constructor() {
|
||||
constructor(app: IonicApp) {
|
||||
this.app = app;
|
||||
|
||||
this.firstPage = CameraPage;
|
||||
console.log('First page', CameraPage);
|
||||
this.plugins = [
|
||||
@@ -30,4 +32,11 @@ class IonicApp {
|
||||
{title: 'Vibration', page: VibrationPage},
|
||||
]
|
||||
}
|
||||
|
||||
openPage(aside, plugin) {
|
||||
aside.close();
|
||||
|
||||
let nav = this.app.getComponent('myNav');
|
||||
nav.setItems([plugin.page]);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -9,7 +9,7 @@
|
||||
</ion-content>
|
||||
</ion-aside>
|
||||
|
||||
<ion-nav #content swipe-back-enabled="false"></ion-nav>
|
||||
<ion-nav id="myNav" #content swipe-back-enabled="false"></ion-nav>
|
||||
|
||||
<style>
|
||||
my-modal {
|
||||
|
||||
Reference in New Issue
Block a user