]> git.immae.eu Git - github/Chocobozzz/PeerTube.git/blame - client/src/app/videos/+video-watch/video-watch.component.html
Enable video watch
[github/Chocobozzz/PeerTube.git] / client / src / app / videos / +video-watch / video-watch.component.html
CommitLineData
191764f3 1<div class="root-row row">
897ec54d 2 <!-- We need the video container for videojs so we just hide it -->
4a7591e1 3 <div id="video-element-wrapper">
6d88de72
C
4 <div *ngIf="remoteServerDown" class="remote-server-down">
5 Sorry, but this video is not available because the remote instance is not responding.
6 <br />
7 Please try again later.
8 </div>
d1992b93 9 </div>
897ec54d 10
516df59b
C
11 <div i18n class="alert alert-warning" *ngIf="isVideoToImport()">
12 The video is being imported, it will be available when the import is finished.
13 </div>
14
bbe0f064 15 <div i18n class="alert alert-warning" *ngIf="isVideoToTranscode()">
2186386c
C
16 The video is being transcoded, it may not work properly.
17 </div>
18
bbe0f064 19 <div i18n class="alert alert-info" *ngIf="hasVideoScheduledPublication()">
191764f3
C
20 This video will be published on {{ video.scheduledUpdate.updateAt | date: 'full' }}.
21 </div>
22
23 <div class="alert alert-danger" *ngIf="video?.blacklisted">
24 <div class="blacklisted-label" i18n>This video is blacklisted.</div>
25 {{ video.blacklistedReason }}
bbe0f064
C
26 </div>
27
20206dfb 28 <!-- Video information -->
2303a803 29 <div *ngIf="video" class="margin-content video-bottom">
2d9fea16 30 <div class="row fullWidth">
3b766e18 31 <div class="col-12 col-lg-auto video-info">
2d9fea16
RK
32 <div class="video-info-first-row">
33 <div>
34 <div class="d-block d-sm-none"> <!-- only shown on small devices, has its conterpart for larger viewports below -->
f845c683 35 <h1 class="video-info-name">{{ video.name }}</h1>
2d9fea16
RK
36 <div i18n class="video-info-date-views">
37 Published {{ video.publishedAt | myFromNow }} - {{ video.views | myNumberFormatter }} views
38 </div>
20206dfb 39 </div>
2d3741d6 40
2d9fea16
RK
41 <div class="d-flex justify-content-between align-items-sm-end">
42 <div class="d-none d-sm-block">
f845c683 43 <h1 class="video-info-name">{{ video.name }}</h1>
2d9fea16
RK
44
45 <div i18n class="video-info-date-views">
46 Published {{ video.publishedAt | myFromNow }} - {{ video.views | myNumberFormatter }} views
47 </div>
2d3741d6 48 </div>
2d9fea16
RK
49
50 <div class="video-actions-rates">
51 <div class="video-actions fullWidth justify-content-end">
52 <div
53 *ngIf="isUserLoggedIn()" [ngClass]="{ 'activated': userRating === 'like' }" (click)="setLike()"
54 class="action-button action-button-like" role="button" [attr.aria-pressed]="userRating === 'like'"
55 >
56 <span class="icon icon-like" i18n-title title="Like this video" ></span>
57 </div>
2d3741d6 58
2d9fea16
RK
59 <div
60 *ngIf="isUserLoggedIn()" [ngClass]="{ 'activated': userRating === 'dislike' }" (click)="setDislike()"
61 class="action-button action-button-dislike" role="button" [attr.aria-pressed]="userRating === 'dislike'"
62 >
63 <span class="icon icon-dislike" i18n-title title="Dislike this video"></span>
64 </div>
2d3741d6 65
2d9fea16
RK
66 <div *ngIf="video.support" (click)="showSupportModal()" class="action-button action-button-support">
67 <span class="icon icon-support"></span>
68 <span class="icon-text" i18n>Support</span>
69 </div>
2d3741d6 70
2d9fea16
RK
71 <div (click)="showShareModal()" class="action-button action-button-share" role="button">
72 <span class="icon icon-share"></span>
73 <span class="icon-text" i18n>Share</span>
74 </div>
2d3741d6 75
2d9fea16
RK
76 <div class="action-more" ngbDropdown placement="top" role="button">
77 <div class="action-button" ngbDropdownToggle role="button">
78 <span class="icon icon-more"></span>
79 </div>
2d3741d6 80
2d9fea16
RK
81 <div ngbDropdownMenu>
82 <a class="dropdown-item" i18n-title title="Download the video" href="#" (click)="showDownloadModal($event)">
83 <span class="icon icon-download"></span> <ng-container i18n>Download</ng-container>
84 </a>
2d3741d6 85
2d9fea16
RK
86 <a *ngIf="isUserLoggedIn()" class="dropdown-item" i18n-title title="Report this video" href="#" (click)="showReportModal($event)">
87 <span class="icon icon-alert"></span> <ng-container i18n>Report</ng-container>
88 </a>
2d3741d6 89
2d9fea16
RK
90 <a *ngIf="isVideoUpdatable()" class="dropdown-item" i18n-title title="Update this video" href="#" [routerLink]="[ '/videos/update', video.uuid ]">
91 <span class="icon icon-edit"></span> <ng-container i18n>Update</ng-container>
92 </a>
2d3741d6 93
2d9fea16
RK
94 <a *ngIf="isVideoBlacklistable()" class="dropdown-item" i18n-title title="Blacklist this video" href="#" (click)="showBlacklistModal($event)">
95 <span class="icon icon-blacklist"></span> <ng-container i18n>Blacklist</ng-container>
96 </a>
2d3741d6 97
2d9fea16
RK
98 <a *ngIf="isVideoUnblacklistable()" class="dropdown-item" i18n-title title="Unblacklist this video" href="#" (click)="unblacklistVideo($event)">
99 <span class="icon icon-unblacklist"></span> <ng-container i18n>Unblacklist</ng-container>
100 </a>
2d3741d6 101
2d9fea16
RK
102 <a *ngIf="isVideoRemovable()" class="dropdown-item" i18n-title title="Delete this video" href="#" (click)="removeVideo($event)">
103 <span class="icon icon-delete"></span> <ng-container i18n>Delete</ng-container>
104 </a>
105 </div>
106 </div>
107 </div>
2d3741d6 108
2d9fea16
RK
109 <div
110 class="video-info-likes-dislikes-bar"
111 *ngIf="video.likes !== 0 || video.dislikes !== 0"
8ff3f883 112 [ngbTooltip]="likesBarTooltipText"
2d9fea16 113 placement="bottom"
8ff3f883 114 >
2d9fea16
RK
115 <div class="likes-bar" [ngStyle]="{ 'width.%': video.likesPercent }"></div>
116 </div>
117 </div>
1f788f20 118 </div>
6a9e1d42 119
07fa4c97 120
2d9fea16 121 <div class="pt-3 border-top video-info-channel">
21131ac1 122 <a [routerLink]="[ '/video-channels', video.byVideoChannel ]" i18n-title title="Go the channel page">
2d9fea16 123 {{ video.channel.displayName }}
6e07c3de 124
2d9fea16
RK
125 <img [src]="video.videoChannelAvatarUrl" alt="Video channel avatar" />
126 </a>
1f788f20 127
660d11e9 128 <my-subscribe-button #subscribeButton [videoChannel]="video.channel" size="small"></my-subscribe-button>
2d9fea16 129 </div>
63347a0f 130
2d9fea16
RK
131 <div class="video-info-by">
132 <a [routerLink]="[ '/accounts', video.byAccount ]" i18n-title title="Go to the account page">
133 <span i18n>By {{ video.byAccount }}</span>
134 <img [src]="video.accountAvatarUrl" alt="Account avatar" />
135 </a>
2d9fea16
RK
136 </div>
137 </div>
63347a0f 138
2d9fea16 139 </div>
26b7305a 140
2d9fea16
RK
141 <div class="video-info-description">
142 <div class="video-info-description-html" [innerHTML]="videoHTMLDescription"></div>
191764f3 143
2d9fea16
RK
144 <div class="video-info-description-more" *ngIf="completeDescriptionShown === false && video.description?.length >= 250" (click)="showMoreDescription()">
145 <ng-container i18n>Show more</ng-container>
146 <span *ngIf="descriptionLoading === false" class="glyphicon glyphicon-menu-down"></span>
147 <my-loader class="description-loading" [loading]="descriptionLoading"></my-loader>
1f788f20 148 </div>
d07137b9 149
2d9fea16
RK
150 <div *ngIf="completeDescriptionShown === true" (click)="showLessDescription()" class="video-info-description-more">
151 <ng-container i18n>Show less</ng-container>
152 <span *ngIf="descriptionLoading === false" class="glyphicon glyphicon-menu-up"></span>
1f788f20
C
153 </div>
154 </div>
09223546 155
2d9fea16
RK
156 <div class="video-attributes">
157 <div class="video-attribute">
158 <span i18n class="video-attribute-label">Privacy</span>
159 <span class="video-attribute-value">{{ video.privacy.label }}</span>
160 </div>
adb115f5 161
162 <div class="video-attribute">
163 <span i18n class="video-attribute-label">Originally published on</span>
164 <span *ngIf="!video.originallyPublishedAt" class="video-attribute-value">Unknown</span>
165 <span *ngIf="video.originallyPublishedAt" class="video-attribute-value">
166 {{ video.originallyPublishedAt | date: 'dd MMMM yyyy' }}
167 </span>
168 </div>
2de96f4d 169
2d9fea16
RK
170 <div class="video-attribute">
171 <span i18n class="video-attribute-label">Category</span>
172 <span *ngIf="!video.category.id" class="video-attribute-value">{{ video.category.label }}</span>
173 <a
174 *ngIf="video.category.id" class="video-attribute-value"
175 [routerLink]="[ '/search' ]" [queryParams]="{ categoryOneOf: [ video.category.id ] }"
176 >{{ video.category.label }}</a>
177 </div>
2de96f4d 178
2d9fea16
RK
179 <div class="video-attribute">
180 <span i18n class="video-attribute-label">Licence</span>
181 <span *ngIf="!video.licence.id" class="video-attribute-value">{{ video.licence.label }}</span>
182 <a
183 *ngIf="video.licence.id" class="video-attribute-value"
184 [routerLink]="[ '/search' ]" [queryParams]="{ licenceOneOf: [ video.licence.id ] }"
185 >{{ video.licence.label }}</a>
186 </div>
db216afd 187
2d9fea16
RK
188 <div class="video-attribute">
189 <span i18n class="video-attribute-label">Language</span>
190 <span *ngIf="!video.language.id" class="video-attribute-value">{{ video.language.label }}</span>
191 <a
192 *ngIf="video.language.id" class="video-attribute-value"
193 [routerLink]="[ '/search' ]" [queryParams]="{ languageOneOf: [ video.language.id ] }"
194 >{{ video.language.label }}</a>
195 </div>
fd45e8f4 196
2d9fea16
RK
197 <div class="video-attribute video-attribute-tags">
198 <span i18n class="video-attribute-label">Tags</span>
199 <a
200 *ngFor="let tag of getVideoTags()"
201 class="video-attribute-value" [routerLink]="[ '/search' ]" [queryParams]="{ tagsOneOf: [ tag ] }"
202 >{{ tag }}</a>
203 </div>
20206dfb 204 </div>
09223546 205
3b766e18
RK
206 <my-video-comments [video]="video" [user]="user"></my-video-comments>
207 </div>
208
8ff3f883 209 <my-recommended-videos [inputRecommendation]="{ uuid: video.uuid, tags: video.tags }" [user]="user"></my-recommended-videos>
d1992b93
C
210 </div>
211 </div>
8ff3f883 212
2b3b76ab 213 <div class="privacy-concerns" *ngIf="hasAlreadyAcceptedPrivacyConcern === false">
2b3b76ab 214 <div class="privacy-concerns-text">
2d9fea16 215 <strong i18n>Friendly Reminder: </strong>
989e526a 216 <ng-container i18n>
a54991da 217 the sharing system used for this video implies that some technical information about your system (such as a public IP address) can be sent to other peers.
989e526a 218 </ng-container>
78f912ed 219 <a i18n i18n-title title="Get more information" target="_blank" rel="noopener noreferrer" href="/about/peertube">More information</a>
2b3b76ab
C
220 </div>
221
989e526a 222 <div i18n class="privacy-concerns-okay" (click)="acceptedPrivacyConcern()">
2b3b76ab
C
223 OK
224 </div>
225 </div>
d1992b93 226
ad42bea3 227<ng-template [ngIf]="video !== null">
07fa4c97 228 <my-video-support #videoSupportModal [video]="video"></my-video-support>
4f8c0eb0 229 <my-video-share #videoShareModal [video]="video"></my-video-share>
a96aed15 230 <my-video-download #videoDownloadModal [video]="video"></my-video-download>
4f8c0eb0 231 <my-video-report #videoReportModal [video]="video"></my-video-report>
26b7305a 232 <my-video-blacklist #videoBlacklistModal [video]="video"></my-video-blacklist>
ad42bea3 233</ng-template>