]>
Commit | Line | Data |
---|---|---|
1 | import { Injectable } from '@angular/core' | |
2 | import { Validators } from '@angular/forms' | |
3 | import { BuildFormValidator } from './form-validator.service' | |
4 | ||
5 | @Injectable() | |
6 | export class VideoCaptionsValidatorsService { | |
7 | readonly VIDEO_CAPTION_LANGUAGE: BuildFormValidator | |
8 | readonly VIDEO_CAPTION_FILE: BuildFormValidator | |
9 | ||
10 | constructor () { | |
11 | ||
12 | this.VIDEO_CAPTION_LANGUAGE = { | |
13 | VALIDATORS: [ Validators.required ], | |
14 | MESSAGES: { | |
15 | 'required': $localize`Video caption language is required.` | |
16 | } | |
17 | } | |
18 | ||
19 | this.VIDEO_CAPTION_FILE = { | |
20 | VALIDATORS: [ Validators.required ], | |
21 | MESSAGES: { | |
22 | 'required': $localize`Video caption file is required.` | |
23 | } | |
24 | } | |
25 | } | |
26 | } |