aboutsummaryrefslogtreecommitdiffhomepage
path: root/client/src/app/+videos/+video-edit/shared/video-edit.component.ts
diff options
context:
space:
mode:
authorChocobozzz <me@florianbigard.com>2021-01-26 10:56:55 +0100
committerChocobozzz <me@florianbigard.com>2021-01-26 10:56:55 +0100
commitddb62a85c5517d3437feb7d487a8a11881b68fcb (patch)
treeb27bc798a85224a2fe5406ef5a9be49d17b48d66 /client/src/app/+videos/+video-edit/shared/video-edit.component.ts
parente08ff02a9f1fb1cfbdfa8f0f602eda9419ba6cc3 (diff)
downloadPeerTube-ddb62a85c5517d3437feb7d487a8a11881b68fcb.tar.gz
PeerTube-ddb62a85c5517d3437feb7d487a8a11881b68fcb.tar.zst
PeerTube-ddb62a85c5517d3437feb7d487a8a11881b68fcb.zip
Fix wait transcoding checkbox display
Diffstat (limited to 'client/src/app/+videos/+video-edit/shared/video-edit.component.ts')
-rw-r--r--client/src/app/+videos/+video-edit/shared/video-edit.component.ts22
1 files changed, 6 insertions, 16 deletions
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 5294a57a1..80b5dce46 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
@@ -96,22 +96,6 @@ export class VideoEditComponent implements OnInit, OnDestroy {
96 this.calendarDateFormat = this.i18nPrimengCalendarService.getDateFormat() 96 this.calendarDateFormat = this.i18nPrimengCalendarService.getDateFormat()
97 } 97 }
98 98
99 get existingCaptions () {
100 return this.videoCaptions
101 .filter(c => c.action !== 'REMOVE')
102 .map(c => c.language.id)
103 }
104
105 isWaitTranscodingDisplayed () {
106 if (!this.waitTranscodingEnabled) return false
107
108 if (this.liveVideo) {
109 return this.form.value['saveReplay'] === true
110 }
111
112 return true
113 }
114
115 updateForm () { 99 updateForm () {
116 const defaultValues: any = { 100 const defaultValues: any = {
117 nsfw: 'false', 101 nsfw: 'false',
@@ -217,6 +201,12 @@ export class VideoEditComponent implements OnInit, OnDestroy {
217 if (this.schedulerInterval) clearInterval(this.schedulerInterval) 201 if (this.schedulerInterval) clearInterval(this.schedulerInterval)
218 } 202 }
219 203
204 getExistingCaptions () {
205 return this.videoCaptions
206 .filter(c => c.action !== 'REMOVE')
207 .map(c => c.language.id)
208 }
209
220 onCaptionAdded (caption: VideoCaptionEdit) { 210 onCaptionAdded (caption: VideoCaptionEdit) {
221 const existingCaption = this.videoCaptions.find(c => c.language.id === caption.language.id) 211 const existingCaption = this.videoCaptions.find(c => c.language.id === caption.language.id)
222 212