This repository was archived by the owner on Nov 30, 2022. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 55
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix(app-bar): fix appbar to work with new ion-tabs layout
- Loading branch information
1 parent
db5d1a3
commit f30ee98
Showing
7 changed files
with
110 additions
and
27 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,14 +1,16 @@ | ||
<div class="appbar" [ngClass]="{'cutout': cutoutVisible, 'left': left, 'right': right}"> | ||
<div class="appbar-rect left"> | ||
<div class="tabs"> | ||
<fiv-app-bar-tab-content [active]="tab.href === router.url" [href]="tab.href" [name]="tab.name" [icon]="tab.icon" [titleLayout]="titleLayout" *ngFor="let tab of tabsLeft"></fiv-app-bar-tab-content> | ||
<fiv-app-bar-tab-content (ionTabButtonClick)="ionTabButtonClick($event)" [active]="router.url.endsWith(tab.href)" [tab]="tab.tab" [href]="tab.href" [name]="tab.name" | ||
[icon]="tab.icon" [titleLayout]="titleLayout" *ngFor="let tab of tabsLeft"></fiv-app-bar-tab-content> | ||
</div> | ||
</div> | ||
<fiv-loading-fab (fivHidden)="onFabHidden()" [icon]="icon" [visible]="_fabVisible" #fab (click)="fabClick()"></fiv-loading-fab> | ||
<div class="rect"></div> | ||
<div class="appbar-rect right"> | ||
<div class="tabs"> | ||
<fiv-app-bar-tab-content [active]="tab.href === router.url" [href]="tab.href" [name]="tab.name" [icon]="tab.icon" [titleLayout]="titleLayout" *ngFor="let tab of tabsRight"></fiv-app-bar-tab-content> | ||
<fiv-app-bar-tab-content (ionTabButtonClick)="ionTabButtonClick($event)" [active]="router.url.endsWith(tab.href)" [tab]="tab.tab" [href]="tab.href" [name]="tab.name" | ||
[icon]="tab.icon" [titleLayout]="titleLayout" *ngFor="let tab of tabsRight"></fiv-app-bar-tab-content> | ||
</div> | ||
</div> | ||
</div> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,65 @@ | ||
import { AppBarPage } from './app-bar.page'; | ||
import { NgModule } from '@angular/core'; | ||
import { RouterModule, Routes } from '@angular/router'; | ||
|
||
|
||
const routes: Routes = [ | ||
{ | ||
path: 'tabs', | ||
component: AppBarPage, | ||
children: [ | ||
{ | ||
path: 'tab1', | ||
children: [ | ||
{ | ||
path: '', | ||
loadChildren: '../bottom-sheet/bottom-sheet.module#BottomSheetPageModule' | ||
} | ||
] | ||
}, | ||
{ | ||
path: 'tab2', | ||
children: [ | ||
{ | ||
path: '', | ||
loadChildren: '../buttons/buttons.module#ButtonsPageModule' | ||
} | ||
] | ||
}, | ||
{ | ||
path: 'tab3', | ||
children: [ | ||
{ | ||
path: '', | ||
loadChildren: '../bottom-sheet/bottom-sheet.module#BottomSheetPageModule' | ||
} | ||
] | ||
}, | ||
{ | ||
path: 'tab4', | ||
children: [ | ||
{ | ||
path: '', | ||
loadChildren: '../bottom-sheet/bottom-sheet.module#BottomSheetPageModule' | ||
} | ||
] | ||
}, | ||
{ | ||
path: '', | ||
redirectTo: '/app-bar/tabs/tab1', | ||
pathMatch: 'full', | ||
}, | ||
] | ||
}, | ||
{ | ||
path: '', | ||
redirectTo: '/app-bar/tabs/tab1', | ||
pathMatch: 'full' | ||
} | ||
]; | ||
|
||
@NgModule({ | ||
imports: [RouterModule.forChild(routes)], | ||
exports: [RouterModule] | ||
}) | ||
export class TabsPageRoutingModule { } |