From e309822b93d9b69f30cbe830ef3d09dfdb2c13b2 Mon Sep 17 00:00:00 2001 From: Chocobozzz Date: Tue, 5 Jun 2018 15:01:45 +0200 Subject: Add form validator translations --- .../app/videos/+video-watch/comment/video-comment-add.component.ts | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'client/src/app/videos/+video-watch/comment') diff --git a/client/src/app/videos/+video-watch/comment/video-comment-add.component.ts b/client/src/app/videos/+video-watch/comment/video-comment-add.component.ts index c70e544a3..46d7a4e9e 100644 --- a/client/src/app/videos/+video-watch/comment/video-comment-add.component.ts +++ b/client/src/app/videos/+video-watch/comment/video-comment-add.component.ts @@ -3,13 +3,13 @@ import { NotificationsService } from 'angular2-notifications' import { Observable } from 'rxjs' import { VideoCommentCreate } from '../../../../../../shared/models/videos/video-comment.model' import { FormReactive } from '../../../shared' -import { VIDEO_COMMENT_TEXT } from '../../../shared/forms/form-validators/video-comment' import { User } from '../../../shared/users' import { Video } from '../../../shared/video/video.model' import { VideoComment } from './video-comment.model' import { VideoCommentService } from './video-comment.service' import { I18n } from '@ngx-translate/i18n-polyfill' import { FormValidatorService } from '@app/shared/forms/form-validators/form-validator.service' +import { VideoCommentValidatorsService } from '@app/shared/forms/form-validators/video-comment-validators.service' @Component({ selector: 'my-video-comment-add', @@ -29,6 +29,7 @@ export class VideoCommentAddComponent extends FormReactive implements OnInit { constructor ( protected formValidatorService: FormValidatorService, + private videoCommentValidatorsService: VideoCommentValidatorsService, private notificationsService: NotificationsService, private videoCommentService: VideoCommentService, private i18n: I18n @@ -38,7 +39,7 @@ export class VideoCommentAddComponent extends FormReactive implements OnInit { ngOnInit () { this.buildForm({ - text: VIDEO_COMMENT_TEXT + text: this.videoCommentValidatorsService.VIDEO_COMMENT_TEXT }) if (this.focusOnInit === true) { -- cgit v1.2.3