Skip to content

Commit 0f5c47d

Browse files
authored
feature(navigation): better browser back/forward button support
* test(nav): add third page to nav/simple-nav * progress * workin' * updates * updates
1 parent 86495e1 commit 0f5c47d

File tree

130 files changed

+1265
-294
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

130 files changed

+1265
-294
lines changed

src/components/nav/test/advanced-nav-then-tabs/app/app.component.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,6 @@ import { Component } from '@angular/core';
1010
`
1111
})
1212
export class AppComponent {
13-
rootOne = 'NonTabOne';
14-
rootTwo = 'NonTabTwo';
13+
rootOne = 'NestedNavOnePageTwo';
14+
rootTwo = 'NestedNavTwoPageTwo';
1515
}
Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
import { NgModule } from '@angular/core';
2+
import { IonicPageModule } from '../../../../../..';
3+
import { NestedNavOnePageOne } from './nested-nav-one-page-one';
4+
5+
@NgModule({
6+
imports: [
7+
IonicPageModule.forChild(NestedNavOnePageOne)
8+
],
9+
declarations: [
10+
NestedNavOnePageOne
11+
]
12+
})
13+
export class NestedNavOnePageOneModule { }

src/components/nav/test/advanced-nav/pages/third-page/third-page.ts renamed to src/components/nav/test/advanced-nav-then-tabs/pages/nested-nav-one/nested-nav-one-page-one.ts

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -3,13 +3,13 @@ import { IonicPage, NavController, } from '../../../../../..';
33

44
@IonicPage()
55
@Component({
6-
templateUrl: 'third-page.html'
6+
template: `
7+
<ion-nav [root]="root"></ion-nav>
8+
`
79
})
8-
export class ThirdPage {
9-
constructor(public nav: NavController) {
10-
}
10+
export class NestedNavOnePageOne {
1111

12-
nextPage() {
13-
this.nav.push('FourthPage', { carId: '123', make: 'Toyota', model: 'Carolla'});
12+
root: string = 'NestedNavOnePageTwo';
13+
constructor(public nav: NavController) {
1414
}
1515
}
Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
import { NgModule } from '@angular/core';
2+
import { IonicPageModule } from '../../../../../..';
3+
import { NestedNavOnePageTwo } from './nested-nav-one-page-two';
4+
5+
@NgModule({
6+
imports: [
7+
IonicPageModule.forChild(NestedNavOnePageTwo)
8+
],
9+
declarations: [
10+
NestedNavOnePageTwo
11+
]
12+
})
13+
export class NestedNavOnePageTwoModule { }

src/components/nav/test/simple-nav-then-tabs/pages/first-page/first-page.ts renamed to src/components/nav/test/advanced-nav-then-tabs/pages/nested-nav-one/nested-nav-one-page-two.ts

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -3,13 +3,13 @@ import { IonicPage, NavController, } from '../../../../../..';
33

44
@IonicPage()
55
@Component({
6-
templateUrl: 'first-page.html'
6+
template: `
7+
<ion-nav [root]="root"></ion-nav>
8+
`
79
})
8-
export class FirstPage {
9-
constructor(public nav: NavController) {
10-
}
10+
export class NestedNavOnePageTwo {
1111

12-
clickMe() {
13-
this.nav.push('ThirdPage');
12+
root: string = 'NonTabOne';
13+
constructor(public nav: NavController) {
1414
}
1515
}
Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
import { NgModule } from '@angular/core';
2+
import { IonicPageModule } from '../../../../../..';
3+
import { NestedNavTwoPageOne } from './nested-nav-two-page-one';
4+
5+
@NgModule({
6+
imports: [
7+
IonicPageModule.forChild(NestedNavTwoPageOne)
8+
],
9+
declarations: [
10+
NestedNavTwoPageOne
11+
]
12+
})
13+
export class NestedNavTwoPageOneModule { }
Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
import { Component } from '@angular/core';
2+
import { IonicPage, NavController, } from '../../../../../..';
3+
4+
@IonicPage()
5+
@Component({
6+
template: `
7+
<ion-nav [root]="root"></ion-nav>
8+
`
9+
})
10+
export class NestedNavTwoPageOne {
11+
12+
root: string = 'NestedNavTwoPageTwo';
13+
constructor(public nav: NavController) {
14+
}
15+
}
Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
import { NgModule } from '@angular/core';
2+
import { IonicPageModule } from '../../../../../..';
3+
import { NestedNavTwoPageTwo } from './nested-nav-two-page-two';
4+
5+
@NgModule({
6+
imports: [
7+
IonicPageModule.forChild(NestedNavTwoPageTwo)
8+
],
9+
declarations: [
10+
NestedNavTwoPageTwo
11+
]
12+
})
13+
export class NestedNavTwoPageTwoModule { }

src/components/nav/test/simple-tabs/pages/first-page/first-page.ts renamed to src/components/nav/test/advanced-nav-then-tabs/pages/nested-nav-two/nested-nav-two-page-two.ts

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -3,13 +3,13 @@ import { IonicPage, NavController, } from '../../../../../..';
33

44
@IonicPage()
55
@Component({
6-
templateUrl: 'first-page.html'
6+
template: `
7+
<ion-nav [root]="root"></ion-nav>
8+
`
79
})
8-
export class FirstPage {
9-
constructor(public nav: NavController) {
10-
}
10+
export class NestedNavTwoPageTwo {
1111

12-
clickMe() {
13-
this.nav.push('ThirdPage');
12+
root: string = 'NonTabTwo';
13+
constructor(public nav: NavController) {
1414
}
1515
}

src/components/nav/test/advanced-nav-then-tabs/pages/non-tab-one/non-tab-one.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,6 @@ export class NonTabOne {
2121
}
2222

2323
goToTabs() {
24-
this.nav.push('TabOnePage');
24+
this.nav.push('TabsOnePage');
2525
}
2626
}

0 commit comments

Comments
 (0)