3 @import './_player-variables';
6 --embedForegroundColor: #{$primary-foreground-color};
8 --embedBigPlayBackgroundColor: #{$primary-background-color};
11 @mixin big-play-button-triangle-size($triangle-size) {
12 width: $triangle-size;
13 height: $triangle-size;
14 top: calc(50% - #{$triangle-size / 2});
15 left: calc(53% - #{($triangle-size / 2)});
18 .video-js.vjs-peertube-skin {
19 font-size: $font-size;
20 color: var(--embedForegroundColor);
26 .vjs-dock-description {
35 transform: scale(-1, 1);
39 .vjs-button > .vjs-icon-placeholder::before {
40 line-height: $control-bar-height;
43 .vjs-volume-level::before {
44 content: ''; /* Remove Circle From Progress Bar */
51 .vjs-big-play-button {
55 $big-play-width: 1.2em;
56 $big-play-height: 1.2em;
58 border: 4px solid #fff;
63 width: $big-play-width;
64 height: $big-play-height;
65 line-height: $big-play-height;
66 margin-left: -($big-play-width / 2);
67 margin-top: -($big-play-height / 2);
68 transition: 0.4s opacity;
75 .vjs-icon-placeholder::before {
76 @include big-play-button-triangle-size(45px);
79 background-image: url('#{$assets-path}/player/images/big-play-button.svg');
87 // Small effect when we click on the play button
88 &.vjs-has-big-play-button-clicked {
90 .vjs-big-play-button, .vjs-poster {
94 &.vjs-big-play-button, &.vjs-big-play-button::before {
96 transition: visibility 0.2s, opacity 0.2s;
99 &.vjs-poster, &.vjs-poster::before {
101 transition: visibility 0.3s, opacity 0.3s;
102 transition-delay: 0.05s;
107 // Show poster and controls when playing audio-only content
108 &.vjs-playing-audio-only-content {
115 opacity: $primary-foreground-opacity-hover;
119 // Hide the big play button on autoplay
121 .vjs-big-play-button {
122 display: none !important;
127 .vjs-big-play-button,
128 .vjs-settings-dialog {
129 background-color: var(--embedBigPlayBackgroundColor);
133 outline: none; /* Remove Blue Outline on Click*/
138 height: $control-bar-height;
139 background: linear-gradient(rgba(0, 0, 0, 0.2), rgba(0, 0, 0, 0.6));
140 box-shadow: 0 -15px 40px 10px rgba(0, 0, 0, 0.2);
141 text-shadow: 0 0 2px rgba(0, 0, 0, 0.5);
143 .vjs-progress-control,
148 .vjs-resolution-control,
149 .vjs-fullscreen-control,
151 .vjs-theater-control,
154 color: var(--embedForegroundColor) !important;
156 opacity: $primary-foreground-opacity;
157 transition: opacity .1s;
160 opacity: $primary-foreground-opacity-hover;
167 color: var(--embedForegroundColor);
168 opacity: $primary-foreground-opacity;
171 .vjs-progress-control {
173 z-index: 100; // On top of the progress bar
175 width: calc(100% - (2 * #{$progress-margin}));
176 margin-left: $progress-margin;
182 background-color: rgba(255, 255, 255, .2);
187 background: var(--embedForegroundColor);
188 transition: all .2s ease 0s;
190 // Not display the circle if the progress is not hovered
193 transition: opacity 0.1s ease;
206 background: rgba(255, 255, 255, .2);
212 .vjs-progress-control:hover .vjs-slider,
213 .vjs-progress-control .vjs-slider.vjs-sliding {
216 .vjs-play-progress::before {
223 @include disable-outline;
226 font-size: $font-size;
232 line-height: inherit;
235 font-size: $font-size;
236 display: inline-block;
240 .vjs-current-time-display {
241 line-height: calc(#{$control-bar-height} + 1px);
251 font-size: $font-size;
252 display: inline-block;
254 .vjs-duration-display {
255 line-height: calc(#{$control-bar-height} + 1px);
259 &.vjs-remaining-time {
266 line-height: $control-bar-height;
270 .vjs-peertube-displayed {
274 .vjs-peertube-hidden {
278 .download-speed-number, .upload-speed-number, .peers-number, .http-fallback {
279 font-weight: $font-semibold;
282 .download-speed-text, .upload-speed-text, .peers-text, .http-fallback {
288 background-image: url('#{$assets-path}/player/images/arrow-down.svg');
292 background-image: url('#{$assets-path}/player/images/arrow-up.svg');
298 line-height: $control-bar-height;
303 mask-image: url('#{$assets-path}/player/images/next.svg');
304 background-color: white;
306 transform: scale(2.2);
314 display: inline-block;
317 background-size: contain;
318 vertical-align: middle;
319 background-repeat: no-repeat;
327 width: 37px !important;
329 .vjs-playback-rate-value {
331 line-height: $control-bar-height;
334 .vjs-menu .vjs-menu-content {
335 width: 37px !important;
340 @include disable-outline;
342 line-height: $control-bar-height;
346 .vjs-icon-placeholder {
347 display: inline-block;
350 vertical-align: middle;
351 background: url('#{$assets-path}/player/images/volume.svg') no-repeat;
352 background-size: contain;
359 &.vjs-vol-0 .vjs-icon-placeholder {
360 background: url('#{$assets-path}/player/images/volume-mute.svg') no-repeat;
361 background-size: contain;
365 .vjs-volume-control {
371 background: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACwAAAAcCAQAAACw95UnAAAAMElEQVRIx2NgoBL4n4YKGUYNHkEG4zJg1OCRYDCpBowaPJwMppbLRg0eNXjUYBLEAXWNUA6QNm1lAAAAAElFTkSuQmCC) no-repeat;
372 background-size: 22px 14px;
382 background: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACwAAAAcAQAAAAAyhWABAAAAAnRSTlMAAHaTzTgAAAAZSURBVHgBYwAB/g9EUv+JokCqiaT+U4MCAPKPS7WUUOc1AAAAAElFTkSuQmCC) no-repeat;
383 background-size: 22px 14px;
395 .vjs-volume-panel.vjs-volume-panel-horizontal.vjs-slider-active,
396 .vjs-volume-panel.vjs-volume-panel-horizontal:active,
397 .vjs-volume-panel.vjs-volume-panel-horizontal:focus,
398 .vjs-volume-panel.vjs-volume-panel-horizontal:hover {
400 transition-property: none;
403 .vjs-volume-panel .vjs-mute-control:hover ~ .vjs-volume-control.vjs-volume-horizontal {
408 .vjs-volume-panel .vjs-mute-control:hover ~ .vjs-volume-control {
409 transition-property: none;
419 .vjs-volume-control {
420 display: inline-block;
430 @include disable-outline;
431 @include disable-default-a-behaviour;
433 text-decoration: none;
434 line-height: $control-bar-height;
435 font-weight: $font-semibold;
439 .vjs-theater-control {
440 @include disable-outline;
446 .vjs-icon-placeholder {
447 transition: transform 0.2s ease;
448 display: inline-block;
451 vertical-align: middle;
452 background: url('#{$assets-path}/player/images/theater.svg') no-repeat;
453 background-size: contain;
461 .vjs-fullscreen-control {
462 @include disable-outline;
467 .vjs-icon-placeholder {
468 display: inline-block;
471 vertical-align: middle;
472 background: url('#{$assets-path}/player/images/fullscreen.svg') no-repeat;
473 background-size: contain;
481 .vjs-menu-button-popup {
482 font-weight: $font-semibold;
485 .vjs-resolution-button {
486 @include disable-outline;
499 text-transform: none;
506 @media screen and (max-width: 750px) {
507 .vjs-theater-control {
515 .vjs-dock-description {
519 .vjs-big-play-button {
523 .vjs-icon-placeholder::before {
524 @include big-play-button-triangle-size(32px);
529 @media screen and (max-width: 570px) {
534 .vjs-big-play-button {
538 .vjs-icon-placeholder::before {
539 @include big-play-button-triangle-size(27px);
544 padding: 0 !important;
546 .vjs-peertube-displayed {
547 display: none !important;
552 @media screen and (max-width: 300px) {
557 .vjs-big-play-button {
561 .vjs-icon-placeholder::before {
562 @include big-play-button-triangle-size(20px);
566 .vjs-volume-control {
567 display: none !important;
571 padding: 0 !important;
579 // Theater mode is enabled
580 &.vjs-theater-enabled {
581 .vjs-theater-control {
584 .vjs-icon-placeholder {
585 transform: scale(0.8);
590 // On fullscreen, hide theater control
592 .vjs-theater-control {
598 // Play/pause animations
599 .vjs-has-started .vjs-play-control {
601 animation: remove-pause-button 0.25s ease;
605 animation: add-play-button 0.25s ease;
608 @keyframes remove-pause-button {
610 transform: rotate(90deg);
613 transform: rotate(0deg);
617 @keyframes add-play-button {
619 transform: rotate(-90deg);
622 transform: rotate(0deg);
627 // Error display disabled
628 .vjs-error:not(.vjs-error-display-enabled) {
633 .vjs-loading-spinner {
638 // Error display enabled
639 .vjs-error.vjs-error-display-enabled {