]>
Commit | Line | Data |
---|---|---|
1 | @import '_variables'; | |
2 | @import '_mixins'; | |
3 | @import '_bootstrap-variables'; | |
4 | @import '_miniature'; | |
5 | ||
6 | $player-factor: 16/9; | |
7 | $video-info-margin-left: 44px; | |
8 | ||
9 | @function getPlayerHeight($width){ | |
10 | @return calc(#{$width} / #{$player-factor}) | |
11 | } | |
12 | ||
13 | @function getPlayerWidth($height){ | |
14 | @return calc(#{$height} * #{$player-factor}) | |
15 | } | |
16 | ||
17 | @mixin playlist-below-player { | |
18 | width: 100% !important; | |
19 | height: auto !important; | |
20 | max-height: 300px !important; | |
21 | max-width: initial; | |
22 | border-bottom: 1px solid $separator-border-color !important; | |
23 | } | |
24 | ||
25 | .root { | |
26 | &.theater-enabled #video-wrapper { | |
27 | flex-direction: column; | |
28 | justify-content: center; | |
29 | ||
30 | $height: calc(100vh - #{$header-height} - #{$theater-bottom-space}); | |
31 | ||
32 | #videojs-wrapper { | |
33 | width: 100%; | |
34 | height: $height; | |
35 | } | |
36 | ||
37 | ::ng-deep .video-js { | |
38 | height: $height; | |
39 | width: 100%; | |
40 | max-width: initial; | |
41 | } | |
42 | ||
43 | my-video-watch-playlist ::ng-deep .playlist { | |
44 | @include playlist-below-player; | |
45 | } | |
46 | } | |
47 | } | |
48 | ||
49 | .blocked-label { | |
50 | font-weight: $font-semibold; | |
51 | } | |
52 | ||
53 | #video-wrapper { | |
54 | $video-height: 66vh; | |
55 | ||
56 | background-color: #000; | |
57 | display: flex; | |
58 | justify-content: center; | |
59 | ||
60 | #videojs-wrapper { | |
61 | display: flex; | |
62 | justify-content: center; | |
63 | flex-grow: 1; | |
64 | height: $video-height; | |
65 | } | |
66 | ||
67 | .remote-server-down { | |
68 | color: #fff; | |
69 | display: flex; | |
70 | flex-direction: column; | |
71 | align-items: center; | |
72 | text-align: center; | |
73 | justify-content: center; | |
74 | background-color: #141313; | |
75 | width: 100%; | |
76 | font-size: 24px; | |
77 | height: 500px; | |
78 | ||
79 | @media screen and (max-width: 1000px) { | |
80 | font-size: 20px; | |
81 | } | |
82 | ||
83 | @media screen and (max-width: 600px) { | |
84 | font-size: 16px; | |
85 | } | |
86 | } | |
87 | ||
88 | ::ng-deep .video-js { | |
89 | width: 100%; | |
90 | max-width: getPlayerWidth(66vh); | |
91 | height: $video-height; | |
92 | ||
93 | // VideoJS create an inner video player | |
94 | video { | |
95 | outline: 0; | |
96 | position: relative !important; | |
97 | } | |
98 | } | |
99 | ||
100 | @media screen and (max-width: 600px) { | |
101 | #videojs-wrapper { | |
102 | height: getPlayerHeight(100vw) !important; | |
103 | } | |
104 | ||
105 | .remote-server-down, | |
106 | ::ng-deep .video-js { | |
107 | width: 100vw; | |
108 | height: getPlayerHeight(100vw) !important; | |
109 | } | |
110 | } | |
111 | } | |
112 | ||
113 | .alert { | |
114 | text-align: center; | |
115 | border-radius: 0; | |
116 | } | |
117 | ||
118 | .flex-direction-column { | |
119 | flex-direction: column; | |
120 | } | |
121 | ||
122 | #video-not-found { | |
123 | height: 300px; | |
124 | line-height: 300px; | |
125 | margin-top: 50px; | |
126 | text-align: center; | |
127 | font-weight: $font-semibold; | |
128 | font-size: 15px; | |
129 | } | |
130 | ||
131 | .video-bottom { | |
132 | display: flex; | |
133 | margin-top: 1.5rem; | |
134 | ||
135 | .video-info { | |
136 | flex-grow: 1; | |
137 | // Set min width for flex item | |
138 | min-width: 1px; | |
139 | max-width: 100%; | |
140 | ||
141 | .video-info-first-row { | |
142 | display: flex; | |
143 | ||
144 | & > div:first-child { | |
145 | flex-grow: 1; | |
146 | } | |
147 | ||
148 | .video-info-name { | |
149 | margin-right: 30px; | |
150 | min-height: 40px; // Align with the action buttons | |
151 | font-size: 27px; | |
152 | font-weight: $font-semibold; | |
153 | flex-grow: 1; | |
154 | } | |
155 | ||
156 | .video-info-first-row-bottom { | |
157 | display: flex; | |
158 | flex-wrap: wrap; | |
159 | align-items: center; | |
160 | width: 100%; | |
161 | } | |
162 | ||
163 | .video-info-date-views { | |
164 | align-self: start; | |
165 | margin-bottom: 10px; | |
166 | margin-right: 10px; | |
167 | font-size: 1em; | |
168 | } | |
169 | ||
170 | .video-info-channel { | |
171 | font-weight: $font-semibold; | |
172 | font-size: 15px; | |
173 | ||
174 | a { | |
175 | @include disable-default-a-behaviour; | |
176 | ||
177 | color: pvar(--mainForegroundColor); | |
178 | ||
179 | &:hover { | |
180 | opacity: 0.8; | |
181 | } | |
182 | } | |
183 | ||
184 | .video-info-channel-left { | |
185 | flex-grow: 1; | |
186 | ||
187 | .video-info-channel-left-links { | |
188 | display: flex; | |
189 | flex-direction: column; | |
190 | position: relative; | |
191 | line-height: 1.37; | |
192 | ||
193 | a:nth-of-type(2) { | |
194 | font-weight: $font-regular; | |
195 | font-size: 90%; | |
196 | } | |
197 | ||
198 | a.single-link { | |
199 | margin-top: 7px; | |
200 | } | |
201 | } | |
202 | } | |
203 | ||
204 | my-subscribe-button { | |
205 | margin-left: 5px; | |
206 | } | |
207 | } | |
208 | ||
209 | my-feed { | |
210 | margin-left: 5px; | |
211 | margin-top: 1px; | |
212 | } | |
213 | ||
214 | .video-actions-rates { | |
215 | margin: 0 0 10px 0; | |
216 | align-items: start; | |
217 | width: max-content; | |
218 | margin-left: auto; | |
219 | ||
220 | .video-actions { | |
221 | height: 40px; // Align with the title | |
222 | display: flex; | |
223 | align-items: center; | |
224 | ||
225 | .action-button:not(:first-child), | |
226 | .action-dropdown, | |
227 | my-video-actions-dropdown { | |
228 | margin-left: 5px; | |
229 | } | |
230 | ||
231 | ::ng-deep.action-button { | |
232 | @include peertube-button; | |
233 | @include button-with-icon(21px, 0, -1px); | |
234 | @include apply-svg-color(pvar(--actionButtonColor)); | |
235 | ||
236 | font-size: 100%; | |
237 | font-weight: $font-semibold; | |
238 | display: inline-block; | |
239 | padding: 0 10px 0 10px; | |
240 | white-space: nowrap; | |
241 | background-color: transparent !important; | |
242 | color: pvar(--actionButtonColor); | |
243 | text-transform: uppercase; | |
244 | ||
245 | &::after { | |
246 | display: none; | |
247 | } | |
248 | ||
249 | &:hover { | |
250 | opacity: 0.9; | |
251 | } | |
252 | ||
253 | &.action-button-like, | |
254 | &.action-button-dislike { | |
255 | filter: brightness(120%); | |
256 | ||
257 | .count { | |
258 | margin: 0 5px; | |
259 | } | |
260 | } | |
261 | ||
262 | &.action-button-like.activated { | |
263 | .count { | |
264 | color: pvar(--activatedActionButtonColor); | |
265 | } | |
266 | ||
267 | my-global-icon { | |
268 | @include apply-svg-color(pvar(--activatedActionButtonColor)); | |
269 | } | |
270 | } | |
271 | ||
272 | &.action-button-dislike.activated { | |
273 | .count { | |
274 | color: pvar(--activatedActionButtonColor); | |
275 | } | |
276 | ||
277 | my-global-icon { | |
278 | @include apply-svg-color(pvar(--activatedActionButtonColor)); | |
279 | } | |
280 | } | |
281 | ||
282 | &.action-button-support { | |
283 | color: pvar(--supportButtonColor); | |
284 | ||
285 | my-global-icon { | |
286 | @include apply-svg-color(pvar(--supportButtonColor)); | |
287 | } | |
288 | } | |
289 | ||
290 | &.action-button-support { | |
291 | my-global-icon { | |
292 | ::ng-deep path:first-child { | |
293 | fill: pvar(--supportButtonHeartColor) !important; | |
294 | } | |
295 | } | |
296 | } | |
297 | ||
298 | &.action-button-save { | |
299 | my-global-icon { | |
300 | top: 0 !important; | |
301 | right: -1px; | |
302 | } | |
303 | } | |
304 | ||
305 | .icon-text { | |
306 | margin-left: 3px; | |
307 | } | |
308 | } | |
309 | } | |
310 | ||
311 | .video-info-likes-dislikes-bar-outer-container { | |
312 | position: relative; | |
313 | } | |
314 | ||
315 | .video-info-likes-dislikes-bar-inner-container { | |
316 | position: absolute; | |
317 | height: 20px; | |
318 | } | |
319 | ||
320 | .video-info-likes-dislikes-bar { | |
321 | $likes-bar-height: 2px; | |
322 | height: $likes-bar-height; | |
323 | margin-top: -$likes-bar-height; | |
324 | width: 120px; | |
325 | background-color: #ccc; | |
326 | position: relative; | |
327 | top: 10px; | |
328 | ||
329 | .likes-bar { | |
330 | height: 100%; | |
331 | background-color: #909090; | |
332 | ||
333 | &.liked { | |
334 | background-color: pvar(--activatedActionButtonColor); | |
335 | } | |
336 | } | |
337 | } | |
338 | } | |
339 | } | |
340 | ||
341 | .video-info-description { | |
342 | margin: 20px 0; | |
343 | margin-left: $video-info-margin-left; | |
344 | font-size: 15px; | |
345 | ||
346 | .video-info-description-html { | |
347 | @include peertube-word-wrap; | |
348 | ||
349 | ::ng-deep a { | |
350 | text-decoration: none; | |
351 | } | |
352 | } | |
353 | ||
354 | .glyphicon, .description-loading { | |
355 | margin-left: 3px; | |
356 | } | |
357 | ||
358 | .description-loading { | |
359 | display: inline-block; | |
360 | } | |
361 | ||
362 | .video-info-description-more { | |
363 | cursor: pointer; | |
364 | font-weight: $font-semibold; | |
365 | color: pvar(--greyForegroundColor); | |
366 | font-size: 14px; | |
367 | ||
368 | .glyphicon { | |
369 | position: relative; | |
370 | top: 2px; | |
371 | } | |
372 | } | |
373 | } | |
374 | ||
375 | .video-attributes { | |
376 | margin-left: $video-info-margin-left; | |
377 | } | |
378 | ||
379 | .video-attributes .video-attribute { | |
380 | font-size: 13px; | |
381 | display: block; | |
382 | margin-bottom: 12px; | |
383 | ||
384 | .video-attribute-label { | |
385 | min-width: 142px; | |
386 | padding-right: 5px; | |
387 | display: inline-block; | |
388 | color: pvar(--greyForegroundColor); | |
389 | font-weight: $font-bold; | |
390 | } | |
391 | ||
392 | a.video-attribute-value { | |
393 | @include disable-default-a-behaviour; | |
394 | color: pvar(--mainForegroundColor); | |
395 | ||
396 | &:hover { | |
397 | opacity: 0.9; | |
398 | } | |
399 | } | |
400 | ||
401 | &.video-attribute-tags { | |
402 | .video-attribute-value:not(:nth-child(2)) { | |
403 | &::before { | |
404 | content: ', ' | |
405 | } | |
406 | } | |
407 | } | |
408 | } | |
409 | } | |
410 | } | |
411 | ||
412 | my-recommended-videos { | |
413 | display: block; | |
414 | padding-left: 15px; | |
415 | min-width: 250px; | |
416 | } | |
417 | ||
418 | my-video-comments { | |
419 | display: inline-block; | |
420 | width: 100%; | |
421 | margin-bottom: 20px; | |
422 | } | |
423 | ||
424 | // If the view is not expanded, take into account the menu | |
425 | .privacy-concerns { | |
426 | z-index: z(dropdown) + 1; | |
427 | width: calc(100% - #{$menu-width}); | |
428 | } | |
429 | ||
430 | @media screen and (max-width: $small-view) { | |
431 | .privacy-concerns { | |
432 | margin-left: $menu-width - 15px; // Menu is absolute | |
433 | } | |
434 | } | |
435 | ||
436 | :host-context(.expanded) { | |
437 | .privacy-concerns { | |
438 | width: 100%; | |
439 | margin-left: -15px; | |
440 | } | |
441 | } | |
442 | ||
443 | .privacy-concerns { | |
444 | position: fixed; | |
445 | bottom: 0; | |
446 | z-index: z(privacymsg); | |
447 | ||
448 | padding: 5px 15px; | |
449 | ||
450 | display: flex; | |
451 | flex-wrap: nowrap; | |
452 | align-items: center; | |
453 | justify-content: space-between; | |
454 | background-color: rgba(0, 0, 0, 0.9); | |
455 | color: #fff; | |
456 | ||
457 | .privacy-concerns-text { | |
458 | margin: 0 5px; | |
459 | } | |
460 | ||
461 | a { | |
462 | @include disable-default-a-behaviour; | |
463 | ||
464 | color: pvar(--mainColor); | |
465 | transition: color 0.3s; | |
466 | ||
467 | &:hover { | |
468 | color: #fff; | |
469 | } | |
470 | } | |
471 | ||
472 | .privacy-concerns-button { | |
473 | padding: 5px 8px 5px 7px; | |
474 | margin-left: auto; | |
475 | border-radius: 3px; | |
476 | white-space: nowrap; | |
477 | cursor: pointer; | |
478 | transition: background-color 0.3s; | |
479 | font-weight: $font-semibold; | |
480 | ||
481 | &:hover { | |
482 | background-color: #000; | |
483 | } | |
484 | } | |
485 | ||
486 | .privacy-concerns-okay { | |
487 | background-color: pvar(--mainColor); | |
488 | margin-left: 10px; | |
489 | } | |
490 | } | |
491 | ||
492 | @media screen and (max-width: 1600px) { | |
493 | .video-bottom .video-info .video-attributes .video-attribute { | |
494 | margin-bottom: 5px; | |
495 | } | |
496 | } | |
497 | ||
498 | @media screen and (max-width: 1300px) { | |
499 | .privacy-concerns { | |
500 | font-size: 12px; | |
501 | padding: 2px 5px; | |
502 | ||
503 | .privacy-concerns-text { | |
504 | margin: 0; | |
505 | } | |
506 | } | |
507 | } | |
508 | ||
509 | // Use the same breakpoint than in the typescript component to display the other video miniatures as row | |
510 | @media screen and (max-width: 1100px) { | |
511 | #video-wrapper { | |
512 | flex-direction: column; | |
513 | justify-content: center; | |
514 | ||
515 | my-video-watch-playlist ::ng-deep .playlist { | |
516 | @include playlist-below-player; | |
517 | } | |
518 | } | |
519 | ||
520 | .video-bottom { | |
521 | flex-direction: column; | |
522 | } | |
523 | ||
524 | my-recommended-videos { | |
525 | padding-left: 0; | |
526 | } | |
527 | } | |
528 | ||
529 | @media screen and (max-width: 600px) { | |
530 | .video-bottom { | |
531 | margin-top: 20px !important; | |
532 | padding-bottom: 20px !important; | |
533 | ||
534 | .video-info { | |
535 | padding: 0; | |
536 | ||
537 | .video-info-first-row { | |
538 | ||
539 | .video-info-name { | |
540 | font-size: 20px; | |
541 | height: auto; | |
542 | } | |
543 | } | |
544 | } | |
545 | } | |
546 | ||
547 | .privacy-concerns { | |
548 | width: 100%; | |
549 | } | |
550 | } | |
551 | ||
552 | @media screen and (max-width: 450px) { | |
553 | .video-bottom { | |
554 | .action-button .icon-text { | |
555 | display: none !important; | |
556 | } | |
557 | ||
558 | .video-info .video-info-first-row { | |
559 | .video-info-name { | |
560 | font-size: 18px; | |
561 | } | |
562 | ||
563 | .video-info-date-views { | |
564 | font-size: 14px; | |
565 | } | |
566 | ||
567 | .video-actions-rates { | |
568 | margin-top: 10px; | |
569 | } | |
570 | } | |
571 | ||
572 | .video-info-description { | |
573 | font-size: 14px !important; | |
574 | } | |
575 | } | |
576 | } | |
577 | ||
578 | ||
579 | // Special case for iOS, that takes into account the width for fullscreens | |
580 | #video-wrapper ::ng-deep .video-js.vjs-fullscreen { | |
581 | max-width: unset; | |
582 | } |