]> git.immae.eu Git - github/Chocobozzz/PeerTube.git/blobdiff - client/src/app/videos/video-add/video-add.component.html
Client: try to improve ux for the upload form
[github/Chocobozzz/PeerTube.git] / client / src / app / videos / video-add / video-add.component.html
index 14c7a0136534d118e469429d61e309bc46d38448..b6be0d78298fff8dd7a5f7a528b0a3c469bda841 100644 (file)
@@ -15,7 +15,7 @@
   </div>
 
   <div class="form-group">
-    <label for="tags">Tags</label>
+    <label for="tags">Tags</label> <span class="little-information">(press enter to add the tag)</span>
     <input
       type="text" class="form-control" id="currentTag"
       formControlName="currentTag" (keyup)="onTagKeyPress($event)"
     </div>
   </div>
 
+  <div *ngIf="tagsError" class="alert alert-danger">
+    {{ tagsError }}
+  </div>
+
   <div class="form-group">
     <label for="videofile">File</label>
     <div class="btn btn-default btn-file" [ngClass]="{ 'disabled': filename !== null }" >
@@ -39,6 +43,7 @@
       <input
         type="file" name="videofile" id="videofile"
         ng2FileSelect [uploader]="uploader" [disabled]="filename !== null"
+        (change)="fileChanged()"
       >
     </div>
   </div>
     </div>
   </div>
 
+  <div *ngIf="fileError" class="alert alert-danger">
+    {{ fileError }}
+  </div>
+
   <div class="form-group">
     <label for="description">Description</label>
     <textarea
@@ -69,7 +78,6 @@
   <div class="form-group">
     <input
       type="button" value="Upload" class="btn btn-default form-control"
-      [title]="getInvalidFieldsTitle()" [disabled]="!form.valid || tags.length === 0 || filename === null"
       (click)="upload()"
     >
   </div>