]> git.immae.eu Git - github/Chocobozzz/PeerTube.git/blame_incremental - client/src/app/+videos/+video-watch/video-watch.component.html
Move video alert in a dedicated component
[github/Chocobozzz/PeerTube.git] / client / src / app / +videos / +video-watch / video-watch.component.html
... / ...
CommitLineData
1<div class="root" [ngClass]="{ 'theater-enabled': theaterEnabled }">
2 <!-- We need the video container for videojs so we just hide it -->
3 <div id="video-wrapper">
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>
9
10 <div id="videojs-wrapper">
11 <img class="placeholder-image" *ngIf="playerPlaceholderImgSrc" [src]="playerPlaceholderImgSrc" alt="Placeholder image" i18n-alt>
12 </div>
13
14 <my-video-watch-playlist
15 #videoWatchPlaylist
16 [playlist]="playlist" class="playlist"
17 (videoFound)="onPlaylistVideoFound($event)"
18 ></my-video-watch-playlist>
19
20 <my-plugin-placeholder pluginId="player-next"></my-plugin-placeholder>
21 </div>
22
23 <my-video-alert [video]="video"></my-video-alert>
24
25 <!-- Video information -->
26 <div *ngIf="video" class="margin-content video-bottom">
27 <div class="video-info">
28 <div class="video-info-first-row">
29 <div>
30 <ng-template #publishedTemplate>
31 <ng-container i18n>Published <my-date-toggle [date]="video.publishedAt"></my-date-toggle></ng-container>
32
33 <my-video-views-counter [video]="video"></my-video-views-counter>
34 </ng-template>
35
36 <div class="d-block d-md-none"> <!-- only shown on medium devices, has its counterpart for larger viewports below -->
37 <h1 class="video-info-name">{{ video.name }}</h1>
38
39 <div class="video-info-date-views">
40 <ng-template *ngTemplateOutlet="publishedTemplate"></ng-template>
41 </div>
42 </div>
43
44 <div class="d-flex justify-content-between flex-direction-column">
45 <div class="d-none d-md-block">
46 <h1 class="video-info-name">{{ video.name }}</h1>
47 </div>
48
49 <div class="video-info-first-row-bottom">
50 <div class="d-none d-md-block video-info-date-views">
51 <ng-template *ngTemplateOutlet="publishedTemplate"></ng-template>
52 </div>
53
54 <my-action-buttons
55 [video]="video" [isUserLoggedIn]="isUserLoggedIn()" [videoCaptions]="videoCaptions" [playlist]="playlist"
56 [currentTime]="getCurrentTime()" [currentPlaylistPosition]="getCurrentPlaylistPosition()"
57 ></my-action-buttons>
58 </div>
59 </div>
60
61 <div class="pt-3 border-top video-info-channel d-flex">
62 <div class="video-info-channel-left d-flex">
63 <my-video-avatar-channel [video]="video" [genericChannel]="isChannelDisplayNameGeneric()"></my-video-avatar-channel>
64
65 <div class="video-info-channel-left-links ml-1">
66 <ng-container *ngIf="!isChannelDisplayNameGeneric()">
67 <a [routerLink]="[ '/c', video.byVideoChannel ]" i18n-title title="Channel page">
68 {{ video.channel.displayName }}
69 </a>
70 <a [routerLink]="[ '/a', video.byAccount ]" i18n-title title="Account page">
71 <span i18n>By {{ video.byAccount }}</span>
72 </a>
73 </ng-container>
74
75 <ng-container *ngIf="isChannelDisplayNameGeneric()">
76 <a [routerLink]="[ '/a', video.byAccount ]" class="single-link" i18n-title title="Account page">
77 <span i18n>{{ video.byAccount }}</span>
78 </a>
79 </ng-container>
80 </div>
81 </div>
82
83 <my-subscribe-button #subscribeButton [videoChannels]="[video.channel]" size="small"></my-subscribe-button>
84 </div>
85 </div>
86
87 </div>
88
89 <my-video-description [video]="video"></my-video-description>
90
91 <div class="video-attributes mb-3">
92 <div class="video-attribute">
93 <span i18n class="video-attribute-label">Privacy</span>
94 <span class="video-attribute-value">{{ video.privacy.label }}</span>
95 </div>
96
97 <div *ngIf="video.isLocal === false" class="video-attribute">
98 <span i18n class="video-attribute-label">Origin</span>
99 <a class="video-attribute-value" target="_blank" rel="noopener noreferrer" [href]="getVideoUrl()">{{ video.originInstanceHost }}</a>
100 </div>
101
102 <div *ngIf="!!video.originallyPublishedAt" class="video-attribute">
103 <span i18n class="video-attribute-label">Originally published</span>
104 <span class="video-attribute-value">{{ video.originallyPublishedAt | date: 'dd MMMM yyyy' }}</span>
105 </div>
106
107 <div class="video-attribute">
108 <span i18n class="video-attribute-label">Category</span>
109 <span *ngIf="!video.category.id" class="video-attribute-value">{{ video.category.label }}</span>
110 <a
111 *ngIf="video.category.id" class="video-attribute-value"
112 [routerLink]="[ '/search' ]" [queryParams]="{ categoryOneOf: [ video.category.id ] }"
113 >{{ video.category.label }}</a>
114 </div>
115
116 <div class="video-attribute">
117 <span i18n class="video-attribute-label">Licence</span>
118 <span *ngIf="!video.licence.id" class="video-attribute-value">{{ video.licence.label }}</span>
119 <a
120 *ngIf="video.licence.id" class="video-attribute-value"
121 [routerLink]="[ '/search' ]" [queryParams]="{ licenceOneOf: [ video.licence.id ] }"
122 >{{ video.licence.label }}</a>
123 </div>
124
125 <div class="video-attribute">
126 <span i18n class="video-attribute-label">Language</span>
127 <span *ngIf="!video.language.id" class="video-attribute-value">{{ video.language.label }}</span>
128 <a
129 *ngIf="video.language.id" class="video-attribute-value"
130 [routerLink]="[ '/search' ]" [queryParams]="{ languageOneOf: [ video.language.id ] }"
131 >{{ video.language.label }}</a>
132 </div>
133
134 <div class="video-attribute video-attribute-tags">
135 <span i18n class="video-attribute-label">Tags</span>
136 <a
137 *ngFor="let tag of getVideoTags()"
138 class="video-attribute-value" [routerLink]="[ '/search' ]" [queryParams]="{ tagsOneOf: [ tag ] }"
139 >{{ tag }}</a>
140 </div>
141
142 <div class="video-attribute" *ngIf="!video.isLive">
143 <span i18n class="video-attribute-label">Duration</span>
144 <span class="video-attribute-value">{{ video.duration | myDurationFormatter }}</span>
145 </div>
146 </div>
147
148 <my-video-comments
149 class="border-top"
150 [video]="video"
151 [user]="user"
152 (timestampClicked)="handleTimestampClicked($event)"
153 ></my-video-comments>
154 </div>
155
156 <my-recommended-videos
157 [displayAsRow]="displayOtherVideosAsRow()"
158 [inputRecommendation]="{ uuid: video.uuid, tags: video.tags }"
159 [playlist]="playlist"
160 (gotRecommendations)="onRecommendations($event)"
161 ></my-recommended-videos>
162 </div>
163
164 <my-privacy-concerns></my-privacy-concerns>
165</div>
166
167<my-player-styles></my-player-styles>