import { AbstractVideoList } from '../../shared/video/abstract-video-list'
import { VideoSortField } from '../../shared/video/sort-field.type'
import { VideoService } from '../../shared/video/video.service'
+import { I18n } from '@ngx-translate/i18n-polyfill'
@Component({
selector: 'my-videos-recently-added',
templateUrl: '../../shared/video/abstract-video-list.html'
})
export class VideoRecentlyAddedComponent extends AbstractVideoList implements OnInit, OnDestroy {
- titlePage = 'Recently added'
+ titlePage: string
currentRoute = '/videos/recently-added'
sort: VideoSortField = '-publishedAt'
- constructor (protected router: Router,
- protected route: ActivatedRoute,
- protected location: Location,
- protected notificationsService: NotificationsService,
- protected authService: AuthService,
- private videoService: VideoService) {
+ constructor (
+ protected router: Router,
+ protected route: ActivatedRoute,
+ protected location: Location,
+ protected notificationsService: NotificationsService,
+ protected authService: AuthService,
+ private videoService: VideoService,
+ private i18n: I18n
+ ) {
super()
+
+ this.titlePage = i18n('Recently added')
}
ngOnInit () {