]>
Commit | Line | Data |
---|---|---|
9a18a625 | 1 | <div class="root" [ngClass]="{ 'theater-enabled': theaterEnabled }"> |
897ec54d | 2 | <!-- We need the video container for videojs so we just hide it --> |
e2f01c47 | 3 | <div id="video-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> | |
e2f01c47 C |
9 | |
10 | <div id="videojs-wrapper"></div> | |
11 | ||
72675ebe C |
12 | <my-video-watch-playlist |
13 | #videoWatchPlaylist | |
d142c7b9 C |
14 | [playlist]="playlist" class="playlist" |
15 | (videoFound)="onPlaylistVideoFound($event)" | |
72675ebe | 16 | ></my-video-watch-playlist> |
d1992b93 | 17 | </div> |
897ec54d | 18 | |
2b3f1919 C |
19 | <div class="row"> |
20 | <div i18n class="col-md-12 alert alert-warning" *ngIf="isVideoToImport()"> | |
21 | The video is being imported, it will be available when the import is finished. | |
22 | </div> | |
516df59b | 23 | |
2b3f1919 C |
24 | <div i18n class="col-md-12 alert alert-warning" *ngIf="isVideoToTranscode()"> |
25 | The video is being transcoded, it may not work properly. | |
26 | </div> | |
2186386c | 27 | |
2b3f1919 C |
28 | <div i18n class="col-md-12 alert alert-info" *ngIf="hasVideoScheduledPublication()"> |
29 | This video will be published on {{ video.scheduledUpdate.updateAt | date: 'full' }}. | |
30 | </div> | |
191764f3 | 31 | |
a5cf76af C |
32 | <div i18n class="col-md-12 alert alert-info" *ngIf="isWaitingForLive()"> |
33 | This live has not started yet. | |
34 | </div> | |
35 | ||
36 | <div i18n class="col-md-12 alert alert-info" *ngIf="isLiveEnded()"> | |
37 | This live is finished. | |
38 | </div> | |
39 | ||
2b3f1919 | 40 | <div class="col-md-12 alert alert-danger" *ngIf="video?.blacklisted"> |
5baee5fc RK |
41 | <div class="blocked-label" i18n>This video is blocked.</div> |
42 | {{ video.blockedReason }} | |
2b3f1919 | 43 | </div> |
bbe0f064 C |
44 | </div> |
45 | ||
20206dfb | 46 | <!-- Video information --> |
2303a803 | 47 | <div *ngIf="video" class="margin-content video-bottom"> |
9a18a625 C |
48 | <div class="video-info"> |
49 | <div class="video-info-first-row"> | |
50 | <div> | |
7fc441cc | 51 | <div class="d-block d-md-none"> <!-- only shown on medium devices, has its counterpart for larger viewports below --> |
9a18a625 | 52 | <h1 class="video-info-name">{{ video.name }}</h1> |
7fc441cc | 53 | |
9a18a625 | 54 | <div i18n class="video-info-date-views"> |
3921166d | 55 | Published <my-date-toggle [date]="video.publishedAt"></my-date-toggle> <span class="views"> • {{ video.views | myNumberFormatter }} views</span> |
9a18a625 C |
56 | </div> |
57 | </div> | |
58 | ||
7fc441cc | 59 | <div class="d-flex justify-content-between flex-direction-column"> |
9a18a625 | 60 | <div class="d-none d-md-block"> |
f845c683 | 61 | <h1 class="video-info-name">{{ video.name }}</h1> |
7fc441cc | 62 | </div> |
9a18a625 | 63 | |
7fc441cc RK |
64 | <div class="video-info-first-row-bottom"> |
65 | <div i18n class="d-none d-md-block video-info-date-views"> | |
3921166d | 66 | Published <my-date-toggle [date]="video.publishedAt"></my-date-toggle> <span class="views"> • {{ video.views | myNumberFormatter }} views</span> |
2d9fea16 | 67 | </div> |
2d9fea16 | 68 | |
7fc441cc | 69 | <div class="video-actions-rates"> |
214ff6fa | 70 | <ng-template #ratePopoverText> |
71 | <span [innerHTML]="getRatePopoverText()"></span> | |
72 | </ng-template> | |
73 | ||
7fc441cc | 74 | <div class="video-actions fullWidth justify-content-end"> |
adcf9212 | 75 | <button |
214ff6fa | 76 | [ngbPopover]="getRatePopoverText() && ratePopoverText" [ngClass]="{ 'activated': userRating === 'like' }" (click)="setLike()" (keyup.enter)="setLike()" |
adcf9212 | 77 | class="action-button action-button-like" [attr.aria-pressed]="userRating === 'like'" [attr.aria-label]="tooltipLike" |
94dfca3e RK |
78 | [ngbTooltip]="tooltipLike" |
79 | placement="bottom auto" | |
7fc441cc RK |
80 | > |
81 | <my-global-icon iconName="like"></my-global-icon> | |
82 | <span *ngIf="video.likes" class="count">{{ video.likes }}</span> | |
adcf9212 | 83 | </button> |
2d3741d6 | 84 | |
adcf9212 | 85 | <button |
214ff6fa | 86 | [ngbPopover]="getRatePopoverText() && ratePopoverText" [ngClass]="{ 'activated': userRating === 'dislike' }" (click)="setDislike()" (keyup.enter)="setDislike()" |
adcf9212 | 87 | class="action-button action-button-dislike" [attr.aria-pressed]="userRating === 'dislike'" [attr.aria-label]="tooltipDislike" |
94dfca3e RK |
88 | [ngbTooltip]="tooltipDislike" |
89 | placement="bottom auto" | |
7fc441cc RK |
90 | > |
91 | <my-global-icon iconName="dislike"></my-global-icon> | |
92 | <span *ngIf="video.dislikes" class="count">{{ video.dislikes }}</span> | |
adcf9212 | 93 | </button> |
3adf3196 | 94 | |
adcf9212 | 95 | <button *ngIf="video.support" (click)="showSupportModal()" (keyup.enter)="showSupportModal()" class="action-button action-button-support" [attr.aria-label]="tooltipSupport" |
94dfca3e RK |
96 | [ngbTooltip]="tooltipSupport" |
97 | placement="bottom auto" | |
98 | > | |
adcf9212 | 99 | <my-global-icon iconName="support" aria-hidden="true"></my-global-icon> |
14571f19 | 100 | <span class="icon-text" i18n>SUPPORT</span> |
adcf9212 | 101 | </button> |
3adf3196 | 102 | |
adcf9212 | 103 | <button (click)="showShareModal()" (keyup.enter)="showShareModal()" class="action-button"> |
6ad971d5 | 104 | <my-global-icon iconName="share" aria-hidden="true"></my-global-icon> |
14571f19 | 105 | <span class="icon-text" i18n>SHARE</span> |
adcf9212 | 106 | </button> |
3adf3196 | 107 | |
7fc441cc RK |
108 | <div |
109 | class="action-dropdown" ngbDropdown placement="top" role="button" autoClose="outside" | |
110 | *ngIf="isUserLoggedIn()" (openChange)="addContent.openChange($event)" | |
94dfca3e RK |
111 | [ngbTooltip]="tooltipSaveToPlaylist" |
112 | placement="bottom auto" | |
7fc441cc | 113 | > |
adcf9212 | 114 | <button class="action-button action-button-save" ngbDropdownToggle> |
6ad971d5 | 115 | <my-global-icon iconName="playlist-add" aria-hidden="true"></my-global-icon> |
14571f19 | 116 | <span class="icon-text" i18n>SAVE</span> |
adcf9212 | 117 | </button> |
3adf3196 | 118 | |
7fc441cc RK |
119 | <div ngbDropdownMenu> |
120 | <my-video-add-to-playlist #addContent [video]="video"></my-video-add-to-playlist> | |
121 | </div> | |
122 | </div> | |
3adf3196 | 123 | |
a5cf76af | 124 | <ng-container *ngIf="!isUserLoggedIn() && !isLive()"> |
6863f814 RK |
125 | <button |
126 | *ngIf="isVideoDownloadable()" class="action-button action-button-save" | |
127 | (click)="showDownloadModal()" (keydown.enter)="showDownloadModal()" | |
128 | > | |
129 | <my-global-icon iconName="download" aria-hidden="true"></my-global-icon> | |
130 | <span class="icon-text d-none d-sm-inline" i18n>DOWNLOAD</span> | |
131 | </button> | |
82f443de | 132 | |
6863f814 RK |
133 | <my-video-download #videoDownloadModal></my-video-download> |
134 | </ng-container> | |
82f443de | 135 | |
6863f814 RK |
136 | <ng-container *ngIf="isUserLoggedIn()"> |
137 | <my-video-actions-dropdown | |
138 | placement="bottom auto" buttonDirection="horizontal" [buttonStyled]="true" [video]="video" [videoCaptions]="videoCaptions" | |
139 | (videoRemoved)="onVideoRemoved()" (modalOpened)="onModalOpened()" | |
140 | ></my-video-actions-dropdown> | |
141 | </ng-container> | |
9a18a625 | 142 | </div> |
3adf3196 | 143 | |
223b24e6 | 144 | <div class="video-info-likes-dislikes-bar-outer-container"> |
2de7f588 | 145 | <div |
223b24e6 | 146 | class="video-info-likes-dislikes-bar-inner-container" |
2de7f588 RK |
147 | *ngIf="video.likes !== 0 || video.dislikes !== 0" |
148 | [ngbTooltip]="likesBarTooltipText" | |
149 | placement="bottom" | |
150 | > | |
151 | <div | |
152 | class="video-info-likes-dislikes-bar" | |
153 | > | |
0240da5c | 154 | <div class="likes-bar" [ngClass]="{ 'liked': userRating !== 'none' }" [ngStyle]="{ 'width.%': video.likesPercent }"></div> |
2de7f588 RK |
155 | </div> |
156 | </div> | |
9a18a625 | 157 | </div> |
9a18a625 | 158 | </div> |
2d3741d6 | 159 | |
9a18a625 C |
160 | <div |
161 | class="video-info-likes-dislikes-bar" | |
162 | *ngIf="video.likes !== 0 || video.dislikes !== 0" | |
163 | [ngbTooltip]="likesBarTooltipText" | |
164 | placement="bottom" | |
165 | > | |
166 | <div class="likes-bar" [ngStyle]="{ 'width.%': video.likesPercent }"></div> | |
2d9fea16 | 167 | </div> |
1f788f20 | 168 | </div> |
9a18a625 | 169 | </div> |
6a9e1d42 | 170 | |
07fa4c97 | 171 | |
dd4f25ee RK |
172 | <div class="pt-3 border-top video-info-channel d-flex"> |
173 | <div class="video-info-channel-left d-flex"> | |
b40a2193 | 174 | <avatar-channel [video]="video" [genericChannel]="isChannelDisplayNameGeneric()"></avatar-channel> |
62fca05d | 175 | |
dd4f25ee | 176 | <div class="video-info-channel-left-links ml-1"> |
b40a2193 K |
177 | <ng-container *ngIf="!isChannelDisplayNameGeneric()"> |
178 | <a [routerLink]="[ '/video-channels', video.byVideoChannel ]" i18n-title title="Channel page"> | |
179 | {{ video.channel.displayName }} | |
180 | </a> | |
181 | <a [routerLink]="[ '/accounts', video.byAccount ]" i18n-title title="Account page"> | |
182 | <span i18n>By {{ video.byAccount }}</span> | |
183 | </a> | |
184 | </ng-container> | |
185 | ||
186 | <ng-container *ngIf="isChannelDisplayNameGeneric()"> | |
187 | <a [routerLink]="[ '/accounts', video.byAccount ]" class="single-link" i18n-title title="Account page"> | |
188 | <span i18n>{{ video.byAccount }}</span> | |
189 | </a> | |
190 | </ng-container> | |
dd4f25ee RK |
191 | </div> |
192 | </div> | |
63347a0f | 193 | |
41eb700f | 194 | <my-subscribe-button #subscribeButton [videoChannels]="[video.channel]" size="small"></my-subscribe-button> |
2d9fea16 | 195 | </div> |
2d9fea16 | 196 | </div> |
26b7305a | 197 | |
9a18a625 | 198 | </div> |
191764f3 | 199 | |
dd4f25ee | 200 | <div class="video-info-description"> |
b29bf61d RK |
201 | <div |
202 | class="video-info-description-html" | |
208c7e92 | 203 | [innerHTML]="videoHTMLDescription" |
b29bf61d RK |
204 | (timestampClicked)="handleTimestampClicked($event)" |
205 | timestampRouteTransformer | |
206 | ></div> | |
d07137b9 | 207 | |
9a18a625 C |
208 | <div class="video-info-description-more" *ngIf="completeDescriptionShown === false && video.description?.length >= 250" (click)="showMoreDescription()"> |
209 | <ng-container i18n>Show more</ng-container> | |
210 | <span *ngIf="descriptionLoading === false" class="glyphicon glyphicon-menu-down"></span> | |
211 | <my-small-loader class="description-loading" [loading]="descriptionLoading"></my-small-loader> | |
1f788f20 | 212 | </div> |
09223546 | 213 | |
9a18a625 C |
214 | <div *ngIf="completeDescriptionShown === true" (click)="showLessDescription()" class="video-info-description-more"> |
215 | <ng-container i18n>Show less</ng-container> | |
216 | <span *ngIf="descriptionLoading === false" class="glyphicon glyphicon-menu-up"></span> | |
217 | </div> | |
218 | </div> | |
adb115f5 | 219 | |
dd4f25ee | 220 | <div class="video-attributes mb-3"> |
9a18a625 C |
221 | <div class="video-attribute"> |
222 | <span i18n class="video-attribute-label">Privacy</span> | |
223 | <span class="video-attribute-value">{{ video.privacy.label }}</span> | |
224 | </div> | |
2de96f4d | 225 | |
c910f667 C |
226 | <div *ngIf="video.isLocal === false" class="video-attribute"> |
227 | <span i18n class="video-attribute-label">Origin instance</span> | |
228 | <a class="video-attribute-value" target="_blank" rel="noopener noreferrer" [href]="video.originInstanceUrl">{{ video.originInstanceHost }}</a> | |
229 | </div> | |
230 | ||
9a18a625 C |
231 | <div *ngIf="!!video.originallyPublishedAt" class="video-attribute"> |
232 | <span i18n class="video-attribute-label">Originally published</span> | |
233 | <span class="video-attribute-value">{{ video.originallyPublishedAt | date: 'dd MMMM yyyy' }}</span> | |
234 | </div> | |
2de96f4d | 235 | |
9a18a625 C |
236 | <div class="video-attribute"> |
237 | <span i18n class="video-attribute-label">Category</span> | |
238 | <span *ngIf="!video.category.id" class="video-attribute-value">{{ video.category.label }}</span> | |
239 | <a | |
240 | *ngIf="video.category.id" class="video-attribute-value" | |
241 | [routerLink]="[ '/search' ]" [queryParams]="{ categoryOneOf: [ video.category.id ] }" | |
242 | >{{ video.category.label }}</a> | |
243 | </div> | |
db216afd | 244 | |
9a18a625 C |
245 | <div class="video-attribute"> |
246 | <span i18n class="video-attribute-label">Licence</span> | |
247 | <span *ngIf="!video.licence.id" class="video-attribute-value">{{ video.licence.label }}</span> | |
248 | <a | |
249 | *ngIf="video.licence.id" class="video-attribute-value" | |
250 | [routerLink]="[ '/search' ]" [queryParams]="{ licenceOneOf: [ video.licence.id ] }" | |
251 | >{{ video.licence.label }}</a> | |
252 | </div> | |
fd45e8f4 | 253 | |
9a18a625 C |
254 | <div class="video-attribute"> |
255 | <span i18n class="video-attribute-label">Language</span> | |
256 | <span *ngIf="!video.language.id" class="video-attribute-value">{{ video.language.label }}</span> | |
257 | <a | |
258 | *ngIf="video.language.id" class="video-attribute-value" | |
259 | [routerLink]="[ '/search' ]" [queryParams]="{ languageOneOf: [ video.language.id ] }" | |
260 | >{{ video.language.label }}</a> | |
20206dfb | 261 | </div> |
09223546 | 262 | |
9a18a625 C |
263 | <div class="video-attribute video-attribute-tags"> |
264 | <span i18n class="video-attribute-label">Tags</span> | |
265 | <a | |
266 | *ngFor="let tag of getVideoTags()" | |
267 | class="video-attribute-value" [routerLink]="[ '/search' ]" [queryParams]="{ tagsOneOf: [ tag ] }" | |
268 | >{{ tag }}</a> | |
269 | </div> | |
df8340b7 | 270 | |
da0310f8 | 271 | <div class="video-attribute" *ngIf="!video.isLive"> |
df8340b7 | 272 | <span i18n class="video-attribute-label">Duration</span> |
b5b68755 | 273 | <span class="video-attribute-value">{{ video.duration | myDurationFormatter }}</span> |
62fca05d | 274 | </div> |
3b766e18 RK |
275 | </div> |
276 | ||
b29bf61d RK |
277 | <my-video-comments |
278 | class="border-top" | |
279 | [video]="video" | |
280 | [user]="user" | |
281 | (timestampClicked)="handleTimestampClicked($event)" | |
282 | ></my-video-comments> | |
d1992b93 | 283 | </div> |
9a18a625 | 284 | |
6aa54148 | 285 | <my-recommended-videos |
5c20a455 | 286 | [inputRecommendation]="{ uuid: video.uuid, tags: video.tags }" |
5c20a455 C |
287 | [playlist]="playlist" |
288 | (gotRecommendations)="onRecommendations($event)" | |
6aa54148 | 289 | ></my-recommended-videos> |
d1992b93 | 290 | </div> |
8ff3f883 | 291 | |
2b3f1919 | 292 | <div class="row privacy-concerns" *ngIf="hasAlreadyAcceptedPrivacyConcern === false"> |
2b3b76ab | 293 | <div class="privacy-concerns-text"> |
52e3beb9 RK |
294 | <span class="mr-2"> |
295 | <strong i18n>Friendly Reminder: </strong> | |
296 | <ng-container i18n> | |
297 | 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. | |
298 | </ng-container> | |
d3217560 | 299 | </span> |
5411da31 | 300 | <a i18n i18n-title title="Get more information" target="_blank" rel="noopener noreferrer" href="/about/peertube#privacy">More information</a> |
2b3b76ab C |
301 | </div> |
302 | ||
d3217560 | 303 | <div i18n class="privacy-concerns-button privacy-concerns-okay" (click)="acceptedPrivacyConcern()"> |
52e3beb9 | 304 | OK |
2b3b76ab C |
305 | </div> |
306 | </div> | |
b59f12b0 | 307 | </div> |
d1992b93 | 308 | |
5a71acd2 | 309 | <ng-container *ngIf="video !== null"> |
1f3a605e | 310 | <my-video-support #videoSupportModal [video]="video"></my-video-support> |
3a1fed11 | 311 | <my-video-share #videoShareModal [video]="video" [videoCaptions]="videoCaptions" [playlist]="playlist"></my-video-share> |
5a71acd2 | 312 | </ng-container> |