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