From 07fa4c97ca50b83b0bee9230da97d02401b4e05f Mon Sep 17 00:00:00 2001 From: Chocobozzz Date: Tue, 20 Feb 2018 16:13:05 +0100 Subject: Add support to video support on client --- .../app/videos/+video-edit/shared/video-edit.component.html | 13 ++++++++++++- .../app/videos/+video-edit/shared/video-edit.component.scss | 4 ++++ .../app/videos/+video-edit/shared/video-edit.component.ts | 5 ++++- .../videos/+video-edit/shared/video-image.component.scss | 2 +- 4 files changed, 21 insertions(+), 3 deletions(-) (limited to 'client/src/app/videos/+video-edit/shared') diff --git a/client/src/app/videos/+video-edit/shared/video-edit.component.html b/client/src/app/videos/+video-edit/shared/video-edit.component.html index 899249778..bf2204013 100644 --- a/client/src/app/videos/+video-edit/shared/video-edit.component.html +++ b/client/src/app/videos/+video-edit/shared/video-edit.component.html @@ -111,7 +111,7 @@ -
+
+ +
+ + +
+ {{ formErrors.support }} +
+
diff --git a/client/src/app/videos/+video-edit/shared/video-edit.component.scss b/client/src/app/videos/+video-edit/shared/video-edit.component.scss index f78336fa8..1317f7426 100644 --- a/client/src/app/videos/+video-edit/shared/video-edit.component.scss +++ b/client/src/app/videos/+video-edit/shared/video-edit.component.scss @@ -59,6 +59,10 @@ padding: 0 15px !important; } } + + .advanced-settings .form-group { + margin-bottom: 20px; + } } .submit-container { diff --git a/client/src/app/videos/+video-edit/shared/video-edit.component.ts b/client/src/app/videos/+video-edit/shared/video-edit.component.ts index 85e5cc3f5..c26906551 100644 --- a/client/src/app/videos/+video-edit/shared/video-edit.component.ts +++ b/client/src/app/videos/+video-edit/shared/video-edit.component.ts @@ -1,7 +1,7 @@ import { Component, Input, OnInit } from '@angular/core' import { FormBuilder, FormControl, FormGroup } from '@angular/forms' import { ActivatedRoute, Router } from '@angular/router' -import { VIDEO_IMAGE } from '@app/shared' +import { VIDEO_IMAGE, VIDEO_SUPPORT } from '@app/shared' import { NotificationsService } from 'angular2-notifications' import 'rxjs/add/observable/forkJoin' import { ServerService } from '../../../core/server' @@ -60,6 +60,7 @@ export class VideoEditComponent implements OnInit { this.formErrors['description'] = '' this.formErrors['thumbnailfile'] = '' this.formErrors['previewfile'] = '' + this.formErrors['support'] = '' this.validationMessages['name'] = VIDEO_NAME.MESSAGES this.validationMessages['privacy'] = VIDEO_PRIVACY.MESSAGES @@ -70,6 +71,7 @@ export class VideoEditComponent implements OnInit { this.validationMessages['description'] = VIDEO_DESCRIPTION.MESSAGES this.validationMessages['thumbnailfile'] = VIDEO_IMAGE.MESSAGES this.validationMessages['previewfile'] = VIDEO_IMAGE.MESSAGES + this.validationMessages['support'] = VIDEO_SUPPORT.MESSAGES this.form.addControl('name', new FormControl('', VIDEO_NAME.VALIDATORS)) this.form.addControl('privacy', new FormControl('', VIDEO_PRIVACY.VALIDATORS)) @@ -83,6 +85,7 @@ export class VideoEditComponent implements OnInit { this.form.addControl('tags', new FormControl('')) this.form.addControl('thumbnailfile', new FormControl('')) this.form.addControl('previewfile', new FormControl('')) + this.form.addControl('support', new FormControl('')) } ngOnInit () { diff --git a/client/src/app/videos/+video-edit/shared/video-image.component.scss b/client/src/app/videos/+video-edit/shared/video-image.component.scss index c44d00b3c..98313536e 100644 --- a/client/src/app/videos/+video-edit/shared/video-image.component.scss +++ b/client/src/app/videos/+video-edit/shared/video-image.component.scss @@ -2,7 +2,7 @@ @import '_mixins'; .root { - height: 150px; + height: auto; display: flex; align-items: center; -- cgit v1.2.3