]> git.immae.eu Git - github/Chocobozzz/PeerTube.git/blobdiff - client/src/app/+videos/+video-edit/video-add-components/video-go-live.component.html
Fix scheduled publication on upload
[github/Chocobozzz/PeerTube.git] / client / src / app / +videos / +video-edit / video-add-components / video-go-live.component.html
index 5657827a92acbf770069aa464836fce228743444..ecec6045baac48b218a161b008ec14a720215e6c 100644 (file)
       ></my-select-options>
     </div>
 
+    <div class="form-group live-type">
+      <div class="peertube-radio-container">
+        <input type="radio" id="permanentLiveFalse" [(ngModel)]="firstStepPermanentLive" [value]="false">
+        <label i18n for="permanentLiveFalse" class="radio">Normal live</label>
+
+        <span class="form-group-description">{{ getNormalLiveDescription() }}</span>
+      </div>
+
+      <div class="peertube-radio-container">
+        <input type="radio" id="permanentLiveTrue" [(ngModel)]="firstStepPermanentLive" [value]="true">
+        <label i18n for="permanentLiveTrue" class="radio">Permanent/recurring live</label>
+
+        <span class="form-group-description" i18n>{{ getPermanentLiveDescription() }}</span>
+      </div>
+    </div>
+
     <input
+      [disabled]="firstStepPermanentLive !== true && firstStepPermanentLive !== false"
       type="button" i18n-value value="Go Live" (click)="goLive()"
     />
   </div>
@@ -27,7 +44,7 @@
   {{ error }}
 </div>
 
-<div class="alert alert-info" i18n *ngIf="isInUpdateForm && getMaxLiveDuration()">
+<div class="alert alert-info" i18n *ngIf="isInUpdateForm && getMaxLiveDuration() >= 0">
   Max live duration is {{ getMaxLiveDuration() | myDurationFormatter }}.
   If your live reaches this limit, it will be automatically terminated.
 </div>
 <!-- Hidden because we want to load the component -->
 <form [hidden]="!isInUpdateForm" novalidate [formGroup]="form">
   <my-video-edit
-    [form]="form" [formErrors]="formErrors" [videoCaptions]="videoCaptions" [schedulePublicationPossible]="false"
+    [form]="form" [formErrors]="formErrors" [videoCaptions]="videoCaptions"
+    [forbidScheduledPublication]="true" [waitTranscodingEnabled]="isWaitTranscodingEnabled()"
     [validationMessages]="validationMessages" [userVideoChannels]="userVideoChannels" [liveVideo]="liveVideo"
     type="go-live"
   ></my-video-edit>
 
   <div class="submit-container">
-    <div class="submit-button"
-       (click)="updateSecondStep()"
-       [ngClass]="{ disabled: !form.valid }"
-    >
-      <my-global-icon iconName="circle-tick" aria-hidden="true"></my-global-icon>
-      <input type="button" i18n-value value="Update" />
-    </div>
+    <my-button className="orange-button" i18n-label label="Update" icon="circle-tick"
+      (click)="updateSecondStep()"
+      [disabled]="!form.valid"
+    ></my-button>
   </div>
 </form>