]> git.immae.eu Git - github/Chocobozzz/PeerTube.git/blob - client/src/app/+accounts/accounts-routing.module.ts
Add debug component to help admins to fix IP issues
[github/Chocobozzz/PeerTube.git] / client / src / app / +accounts / accounts-routing.module.ts
1 import { NgModule } from '@angular/core'
2 import { RouterModule, Routes } from '@angular/router'
3 import { MetaGuard } from '@ngx-meta/core'
4 import { AccountsComponent } from './accounts.component'
5 import { AccountVideosComponent } from './account-videos/account-videos.component'
6 import { AccountAboutComponent } from './account-about/account-about.component'
7 import { AccountVideoChannelsComponent } from './account-video-channels/account-video-channels.component'
8
9 const accountsRoutes: Routes = [
10 {
11 path: ':accountId',
12 component: AccountsComponent,
13 canActivateChild: [ MetaGuard ],
14 children: [
15 {
16 path: '',
17 redirectTo: 'videos',
18 pathMatch: 'full'
19 },
20 {
21 path: 'videos',
22 component: AccountVideosComponent,
23 data: {
24 meta: {
25 title: 'Account videos'
26 },
27 reuse: {
28 enabled: true,
29 key: 'account-videos-list'
30 }
31 }
32 },
33 {
34 path: 'video-channels',
35 component: AccountVideoChannelsComponent,
36 data: {
37 meta: {
38 title: 'Account video channels'
39 }
40 }
41 },
42 {
43 path: 'about',
44 component: AccountAboutComponent,
45 data: {
46 meta: {
47 title: 'About account'
48 }
49 }
50 }
51 ]
52 }
53 ]
54
55 @NgModule({
56 imports: [ RouterModule.forChild(accountsRoutes) ],
57 exports: [ RouterModule ]
58 })
59 export class AccountsRoutingModule {}