import { Component, OnInit } from '@angular/core'
import { Title } from '@angular/platform-browser'
import { Router } from '@angular/router'
-import { HttpStatusCode } from '@shared/core-utils/miscs/http-error-codes'
+import { HttpStatusCode } from '@shared/models'
@Component({
selector: 'my-page-not-found',
})
export class PageNotFoundComponent implements OnInit {
status = HttpStatusCode.NOT_FOUND_404
- type: string
+ type: 'video' | 'other' = 'other'
public constructor (
private titleService: Title,
return window.location.pathname
}
- getRessourceName () {
- switch (this.type) {
- case 'video':
- return $localize`video`
- default:
- return $localize`ressource`
- }
- }
-
getMascotName () {
switch (this.status) {
case HttpStatusCode.I_AM_A_TEAPOT_418: