]>
Commit | Line | Data |
---|---|---|
b9177868 | 1 | <div *ngIf="!isUploadingVideo" class="upload-video-container" dragDrop (fileDropped)="setVideoFile($event)"> |
457bb213 | 2 | <div class="first-step-block"> |
adcf9212 | 3 | <my-global-icon class="upload-icon" iconName="upload" aria-hidden="true"></my-global-icon> |
fbad87b0 | 4 | |
c9ff8a08 | 5 | <div class="button-file form-control" [ngbTooltip]="'(extensions: ' + videoExtensions + ')'"> |
fbad87b0 | 6 | <span i18n>Select the file to upload</span> |
a6d5ff76 | 7 | <input #videofileInput type="file" name="videofile" id="videofile" [accept]="videoExtensions" (change)="fileChange()" autofocus /> |
fbad87b0 | 8 | </div> |
fbad87b0 C |
9 | |
10 | <div class="form-group form-group-channel"> | |
11 | <label i18n for="first-step-channel">Channel</label> | |
02c01341 RK |
12 | <my-select-channel |
13 | labelForId="first-step-channel" [items]="userVideoChannels" [(ngModel)]="firstStepChannelId" | |
14 | ></my-select-channel> | |
fbad87b0 C |
15 | </div> |
16 | ||
17 | <div class="form-group"> | |
18 | <label i18n for="first-step-privacy">Privacy</label> | |
02c01341 RK |
19 | <my-select-options |
20 | labelForId="first-step-privacy" [items]="videoPrivacies" [(ngModel)]="firstStepPrivacyId" | |
21 | ></my-select-options> | |
fbad87b0 | 22 | </div> |
7b992a86 C |
23 | |
24 | <ng-container *ngIf="isUploadingAudioFile"> | |
25 | <div class="form-group audio-preview"> | |
26 | <label i18n for="previewfileUpload">Video background image</label> | |
27 | ||
28 | <div i18n class="audio-image-info"> | |
29 | Image that will be merged with your audio file. | |
30 | <br /> | |
31 | The chosen image will be definitive and cannot be modified. | |
32 | </div> | |
33 | ||
34 | <my-preview-upload | |
35 | i18n-inputLabel inputLabel="Edit" inputName="previewfileUpload" [(ngModel)]="previewfileUpload" | |
36 | previewWidth="360px" previewHeight="200px" | |
37 | ></my-preview-upload> | |
38 | </div> | |
39 | ||
40 | <div class="form-group upload-audio-button"> | |
41 | <my-button className="orange-button" i18n-label [label]="getAudioUploadLabel()" icon="upload" (click)="uploadFirstStep(true)"></my-button> | |
42 | </div> | |
43 | </ng-container> | |
fbad87b0 C |
44 | </div> |
45 | </div> | |
46 | ||
7373507f | 47 | <div *ngIf="isUploadingVideo && !error" class="upload-progress-cancel"> |
e61151b0 RK |
48 | <div class="progress" i18n-title title="Total video quota"> |
49 | <div class="progress-bar" role="progressbar" [style]="{ width: videoUploadPercents + '%' }" [attr.aria-valuenow]="videoUploadPercents" aria-valuemin="0" [attr.aria-valuemax]="100"> | |
50 | <span *ngIf="videoUploadPercents === 100 && videoUploaded === false" i18n>Processing…</span> | |
51 | <span *ngIf="videoUploadPercents !== 100 || videoUploaded">{{ videoUploadPercents }}%</span> | |
52 | </div> | |
53 | </div> | |
fbad87b0 C |
54 | <input *ngIf="videoUploaded === false" type="button" value="Cancel" (click)="cancelUpload()" /> |
55 | </div> | |
56 | ||
7373507f C |
57 | <div *ngIf="error" class="alert alert-danger"> |
58 | <div i18n>Sorry, but something went wrong</div> | |
59 | {{ error }} | |
60 | </div> | |
61 | ||
674a66bb C |
62 | <div *ngIf="videoUploaded && !error" class="alert alert-info" i18n> |
63 | Congratulations! Your video is now available in your private library. | |
64 | </div> | |
65 | ||
fbad87b0 | 66 | <!-- Hidden because we want to load the component --> |
df8914c9 | 67 | <form [hidden]="!isUploadingVideo" novalidate [formGroup]="form" class="mb-3"> |
fbad87b0 C |
68 | <my-video-edit |
69 | [form]="form" [formErrors]="formErrors" [videoCaptions]="videoCaptions" | |
851f5daa | 70 | [validationMessages]="validationMessages" [userVideoChannels]="userVideoChannels" |
14e2014a | 71 | [waitTranscodingEnabled]="waitTranscodingEnabled" |
fbad87b0 C |
72 | ></my-video-edit> |
73 | ||
74 | <div class="submit-container"> | |
75 | <div i18n *ngIf="videoUploaded === false" class="message-submit">Publish will be available when upload is finished</div> | |
76 | ||
2e03d650 | 77 | <my-button className="submit-button orange-button" i18n-label label="Publish" icon="circle-tick" |
1fe1e14c RK |
78 | (click)="updateSecondStep()" (keydown.enter)="updateSecondStep()" |
79 | [disabled]="isPublishingButtonDisabled()" | |
80 | ></my-button> | |
fbad87b0 | 81 | </div> |
7373507f | 82 | </form> |