2018-04-25 09:56:13 -05:00
|
|
|
import { NgModule } from '@angular/core'
|
|
|
|
import { RouterModule, Routes } from '@angular/router'
|
|
|
|
import { MetaGuard } from '@ngx-meta/core'
|
|
|
|
import { VideoChannelsComponent } from './video-channels.component'
|
|
|
|
import { VideoChannelVideosComponent } from './video-channel-videos/video-channel-videos.component'
|
|
|
|
import { VideoChannelAboutComponent } from './video-channel-about/video-channel-about.component'
|
2019-03-14 08:05:36 -05:00
|
|
|
import { VideoChannelPlaylistsComponent } from '@app/+video-channels/video-channel-playlists/video-channel-playlists.component'
|
2018-04-25 09:56:13 -05:00
|
|
|
|
|
|
|
const videoChannelsRoutes: Routes = [
|
|
|
|
{
|
2019-01-08 04:26:41 -06:00
|
|
|
path: ':videoChannelName',
|
2018-04-25 09:56:13 -05:00
|
|
|
component: VideoChannelsComponent,
|
|
|
|
canActivateChild: [ MetaGuard ],
|
|
|
|
children: [
|
|
|
|
{
|
|
|
|
path: '',
|
|
|
|
redirectTo: 'videos',
|
|
|
|
pathMatch: 'full'
|
|
|
|
},
|
|
|
|
{
|
|
|
|
path: 'videos',
|
|
|
|
component: VideoChannelVideosComponent,
|
|
|
|
data: {
|
|
|
|
meta: {
|
|
|
|
title: 'Video channel videos'
|
2019-03-21 10:49:46 -05:00
|
|
|
},
|
|
|
|
reuse: {
|
|
|
|
enabled: true,
|
|
|
|
key: 'video-channel-videos-list'
|
2018-04-25 09:56:13 -05:00
|
|
|
}
|
|
|
|
}
|
|
|
|
},
|
2019-03-14 08:05:36 -05:00
|
|
|
{
|
|
|
|
path: 'video-playlists',
|
|
|
|
component: VideoChannelPlaylistsComponent,
|
|
|
|
data: {
|
|
|
|
meta: {
|
|
|
|
title: 'Video channel playlists'
|
|
|
|
}
|
|
|
|
}
|
|
|
|
},
|
2018-04-25 09:56:13 -05:00
|
|
|
{
|
|
|
|
path: 'about',
|
|
|
|
component: VideoChannelAboutComponent,
|
|
|
|
data: {
|
|
|
|
meta: {
|
|
|
|
title: 'About video channel'
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
]
|
|
|
|
}
|
|
|
|
]
|
|
|
|
|
|
|
|
@NgModule({
|
|
|
|
imports: [ RouterModule.forChild(videoChannelsRoutes) ],
|
|
|
|
exports: [ RouterModule ]
|
|
|
|
})
|
|
|
|
export class VideoChannelsRoutingModule {}
|