]> git.immae.eu Git - github/Chocobozzz/PeerTube.git/blame - client/src/app/+videos/+video-watch/video-watch.component.scss
Increase global font size
[github/Chocobozzz/PeerTube.git] / client / src / app / +videos / +video-watch / video-watch.component.scss
CommitLineData
8cbc40b2
C
1@use 'sass:math';
2@use '_variables' as *;
3@use '_mixins' as *;
fa12eacc 4@use '_bootstrap-variables';
8cbc40b2 5@use '_miniature' as *;
19f22055 6
d4f0b2ec
C
7$video-height: 66vh;
8
931d3430 9@function getPlayerHeight ($width) {
b0c43e36 10 @return calc(#{$width} / #{$video-watch-player-factor});
9a18a625
C
11}
12
931d3430 13@function getPlayerWidth ($height) {
b0c43e36 14 @return calc(#{$height} * #{$video-watch-player-factor});
9a18a625
C
15}
16
17@mixin playlist-below-player {
72675ebe
C
18 width: 100% !important;
19 height: auto !important;
20 max-height: 300px !important;
67c68723 21 max-width: initial;
72675ebe 22 border-bottom: 1px solid $separator-border-color !important;
9a18a625
C
23}
24
d4f0b2ec
C
25.blocked-label {
26 font-weight: $font-semibold;
27}
28
29.placeholder-image {
30 height: 100%;
71ab0c07
C
31 max-width: 100%;
32 object-fit: contain;
d4f0b2ec
C
33}
34
d4f0b2ec
C
35.flex-direction-column {
36 flex-direction: column;
37}
38
9a18a625 39.root {
9a18a625 40 &.theater-enabled #video-wrapper {
931d3430
C
41 $height: calc(100vh - #{$header-height} - #{$theater-bottom-space});
42
9a18a625
C
43 flex-direction: column;
44 justify-content: center;
45
46 #videojs-wrapper {
47 width: 100%;
f8c00564 48 height: $height;
9a18a625
C
49 }
50
03652b31 51 ::ng-deep .video-js {
9a18a625
C
52 height: $height;
53 width: 100%;
466e3f20 54 max-width: initial;
9a18a625
C
55 }
56
03652b31 57 my-video-watch-playlist ::ng-deep .playlist {
9a18a625
C
58 @include playlist-below-player;
59 }
60 }
191764f3
C
61}
62
e2f01c47 63#video-wrapper {
be6a4802
C
64 background-color: #000;
65 display: flex;
66 justify-content: center;
6d88de72 67
03652b31 68 ::ng-deep .video-js {
58f3c3f1 69 width: 100%;
d4f0b2ec 70 max-width: getPlayerWidth($video-height);
a5cf76af 71 height: $video-height;
3b492bff 72
7b272fd7
C
73 // VideoJS create an inner video player
74 video {
75 outline: 0;
b9828abe 76 position: relative !important;
7b272fd7 77 }
be6a4802 78 }
e56b20f5
C
79}
80
d4f0b2ec
C
81#videojs-wrapper {
82 display: flex;
83 justify-content: center;
84 flex-grow: 1;
85 height: $video-height;
2186386c
C
86}
87
d4f0b2ec
C
88.remote-server-down {
89 color: #fff;
90 display: flex;
7fc441cc 91 flex-direction: column;
d4f0b2ec
C
92 align-items: center;
93 text-align: center;
94 justify-content: center;
95 background-color: #141313;
96 width: 100%;
97 font-size: 24px;
98 height: 500px;
99
100 @media screen and (max-width: 1000px) {
101 font-size: 20px;
102 }
103
104 @media screen and (max-width: 600px) {
105 font-size: 16px;
106 }
7fc441cc
RK
107}
108
9c89a45c
C
109#video-not-found {
110 height: 300px;
111 line-height: 300px;
112 margin-top: 50px;
113 text-align: center;
fb4fd623 114 font-weight: $font-semibold;
9c89a45c
C
115}
116
b1fa3eba 117.video-bottom {
9a18a625 118 display: flex;
46788f21 119 margin-top: 1.5rem;
d4f0b2ec 120}
d1992b93 121
d4f0b2ec
C
122.video-info {
123 flex-grow: 1;
124 // Set min width for flex item
125 min-width: 1px;
126 max-width: 100%;
127}
128
129.video-info-first-row {
130 display: flex;
131
132 > div:first-child {
b1fa3eba 133 flex-grow: 1;
d4f0b2ec
C
134 }
135}
136
137.video-info-name {
138 @include peertube-word-wrap;
139
140 @include margin-right(30px);
141
142 min-height: 40px; // Align with the action buttons
143 font-size: 27px;
144 font-weight: $font-semibold;
145 flex-grow: 1;
146}
147
148.video-info-first-row-bottom {
149 display: flex;
150 flex-wrap: wrap;
151 align-items: center;
152 width: 100%;
153}
154
155.video-info-date-views {
156 @include margin-right(10px);
157
158 margin-bottom: 10px;
159 align-self: start;
5b0ec7cd 160 font-size: 14px;
d4f0b2ec
C
161}
162
163.video-info-channel {
164 font-weight: $font-semibold;
d4f0b2ec
C
165
166 a {
167 @include disable-default-a-behaviour;
168 @include peertube-word-wrap;
169
170 color: pvar(--mainForegroundColor);
171
172 &:hover {
173 opacity: 0.8;
174 }
175 }
176}
177
178.video-info-channel-left {
179 flex-grow: 1;
180
181 .video-info-channel-left-links {
182 display: flex;
183 flex-direction: column;
184 position: relative;
185 line-height: 1.37;
186
187 a:nth-of-type(2) {
188 font-weight: $font-regular;
189 font-size: 90%;
d1992b93
C
190 }
191
d4f0b2ec
C
192 a.single-link {
193 margin-top: 7px;
dd4f25ee 194 }
d4f0b2ec
C
195 }
196}
197
198my-subscribe-button {
199 @include margin-left(5px);
200}
201
c894a1ea 202my-video-attributes {
d4f0b2ec
C
203 @include margin-left($video-watch-info-margin-left);
204
c894a1ea
C
205 display: block;
206 margin-bottom: 15px;
0f7407d9 207}
41c3dfac 208
06a55579
C
209my-action-buttons {
210 @include margin-left(auto);
211 @include margin-right(0);
212
213 display: block;
214 margin-top: 0;
215 margin-bottom: 10px;
216
217 align-items: start;
218 width: max-content;
219}
220
0f7407d9 221my-recommended-videos {
27bc9586
C
222 @include padding-left(15px);
223
0f7407d9 224 display: block;
0f7407d9 225 min-width: 250px;
d1992b93 226}
41c3dfac 227
1d6587aa
C
228my-video-comments {
229 display: inline-block;
66467298 230 width: 100%;
1d6587aa
C
231 margin-bottom: 20px;
232}
233
0f7407d9 234// Use the same breakpoint than in the typescript component to display the other video miniatures as row
9a18a625 235@media screen and (max-width: 1100px) {
3143ae17
C
236 #video-wrapper {
237 flex-direction: column;
238 justify-content: center;
239
03652b31 240 my-video-watch-playlist ::ng-deep .playlist {
3143ae17
C
241 @include playlist-below-player;
242 }
243 }
244
9a18a625
C
245 .video-bottom {
246 flex-direction: column;
0f7407d9 247 }
9a18a625 248
0f7407d9 249 my-recommended-videos {
27bc9586 250 @include padding-left(0);
9a18a625
C
251 }
252}
253
1f788f20 254@media screen and (max-width: 600px) {
d4f0b2ec
C
255 #videojs-wrapper {
256 height: getPlayerHeight(100vw) !important;
257
258 .remote-server-down,
259 ::ng-deep .video-js {
260 width: 100vw;
261 height: getPlayerHeight(100vw) !important;
262 }
263 }
264
b2731bff 265 .video-bottom {
c2a89b70 266 margin-top: 20px !important;
46788f21 267 padding-bottom: 20px !important;
d4f0b2ec 268 }
1f788f20 269
d4f0b2ec
C
270 .video-info {
271 padding: 0;
272 }
1f788f20 273
d4f0b2ec
C
274 .video-info-name {
275 font-size: 20px;
276 height: auto;
b2731bff
C
277 }
278}
07fa4c97
C
279
280@media screen and (max-width: 450px) {
d4f0b2ec
C
281 .video-info-name {
282 font-size: 18px;
283 }
284
285 .video-info-date-views {
286 font-size: 14px;
07fa4c97 287 }
06a55579
C
288
289 my-action-buttons {
290 margin-top: 10px;
291 }
07fa4c97 292}
d45f3641 293
d45f3641
C
294// Special case for iOS, that takes into account the width for fullscreens
295#video-wrapper ::ng-deep .video-js.vjs-fullscreen {
296 max-width: unset;
297}