]> git.immae.eu Git - github/Chocobozzz/PeerTube.git/blame - client/src/app/account/account-routing.module.ts
Move to angular cli
[github/Chocobozzz/PeerTube.git] / client / src / app / account / account-routing.module.ts
CommitLineData
df98563e
C
1import { NgModule } from '@angular/core'
2import { RouterModule, Routes } from '@angular/router'
693b1aba 3
8b13c289
C
4import { MetaGuard } from '@ngx-meta/core'
5
f47bf2e1 6import { LoginGuard } from '../core'
df98563e 7import { AccountComponent } from './account.component'
c30745f3 8import { AccountSettingsComponent } from './account-settings/account-settings.component'
202f6b6c 9import { AccountVideosComponent } from './account-videos/account-videos.component'
693b1aba
C
10
11const accountRoutes: Routes = [
12 {
13 path: 'account',
14 component: AccountComponent,
c30745f3
C
15 canActivateChild: [ MetaGuard, LoginGuard ],
16 children: [
17 {
18 path: 'settings',
19 component: AccountSettingsComponent,
20 data: {
21 meta: {
22 title: 'Account settings'
23 }
24 }
25 },
202f6b6c
C
26 {
27 path: 'videos',
28 component: AccountVideosComponent,
29 data: {
30 meta: {
31 title: 'Account videos'
32 }
33 }
34 }
c30745f3 35 ]
693b1aba 36 }
df98563e 37]
693b1aba
C
38
39@NgModule({
40 imports: [ RouterModule.forChild(accountRoutes) ],
41 exports: [ RouterModule ]
42})
43export class AccountRoutingModule {}