]> git.immae.eu Git - github/Chocobozzz/PeerTube.git/blobdiff - client/src/app/videos/+video-edit/video-add.component.html
Add tests regarding video import
[github/Chocobozzz/PeerTube.git] / client / src / app / videos / +video-edit / video-add.component.html
index f8355f3dba6aa04c15e30640e3f0588016c15ae8..1575007d276142007949f504d73a9d196931a8e5 100644 (file)
@@ -1,45 +1,17 @@
 <div class="margin-content">
   <div class="title-page title-page-single">
-    Upload your video
+    <ng-container *ngIf="secondStepType === 'import'" i18n>Import {{ videoName }}</ng-container>
+    <ng-container *ngIf="secondStepType === 'upload'" i18n>Upload {{ videoName }}</ng-container>
   </div>
 
-  <div *ngIf="error" class="alert alert-danger">{{ error }}</div>
+  <tabset class="video-add-tabset root-tabset bootstrap" [ngClass]="{ 'hide-nav': secondStepType !== undefined }">
 
-  <div class="upload-video-container">
-    <div class="upload-video">
-      <div class="icon icon-upload"></div>
+    <tab i18n-heading heading="Upload your video">
+      <my-video-upload #videoUpload (firstStepDone)="onFirstStepDone('upload', $event)"></my-video-upload>
+    </tab>
 
-      <div class="button-file">
-        <span>Select the file to upload</span>
-        <input #videofileInput type="file" name="videofile" id="videofile" (change)="fileChange($event)" />
-      </div>
-
-      <div class="form-group">
-        <select [(ngModel)]="firstStepPrivacy">
-          <option *ngFor="let privacy of videoPrivacies" [value]="privacy.id">{{ privacy.label }}</option>
-        </select>
-      </div>
-
-      <div class="form-group">
-        <select [(ngModel)]="firstStepChannel">
-          <option *ngFor="let channel of userVideoChannels" [value]="channel.id">{{ channel.label }}</option>
-        </select>
-      </div>
-    </div>
-
-
-    <form *ngIf="isUploadingVideo" novalidate [formGroup]="form">
-      <my-video-edit
-          [form]="form" [formErrors]="formErrors"
-          [validationMessages]="validationMessages" [videoPrivacies]="videoPrivacies"
-      ></my-video-edit>
-
-      <div class="submit-container">
-        <div class="submit-button" [ngClass]="{ disabled: !form.valid }">
-          <span class="icon icon-validate"></span>
-          <input type="button" value="Publish" (click)="upload()" />
-        </div>
-      </div>
-    </form>
-  </div>
+    <tab *ngIf="isVideoImportEnabled()" i18n-heading heading="Import your video">
+      <my-video-import #videoImport (firstStepDone)="onFirstStepDone('import', $event)"></my-video-import>
+    </tab>
+  </tabset>
 </div>