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