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