Converted to SASS/SCSS

This commit is contained in:
Sam Potts
2017-12-20 15:14:05 +00:00
parent aab53fa91f
commit 6864149989
79 changed files with 7008 additions and 9976 deletions

View File

@ -0,0 +1,31 @@
// --------------------------------------------------------------
// Animations
// --------------------------------------------------------------
@keyframes plyr-progress {
to {
background-position: $plyr-progress-loading-size 0;
}
}
@keyframes plyr-popup {
0% {
opacity: 0.5;
transform: translateY(10px);
}
to {
opacity: 1;
transform: translateY(0);
}
}
@keyframes plyr-fade-in {
from {
opacity: 0;
}
to {
opacity: 1;
}
}

99
src/sass/lib/mixins.scss Normal file
View File

@ -0,0 +1,99 @@
// ==========================================================================
// Plyr mixins
// https://github.com/sampotts/plyr
// ==========================================================================
// Nicer focus styles
// ---------------------------------------
@mixin plyr-tab-focus($color: $plyr-tab-focus-default-color) {
box-shadow: 0 0 0 3px rgba($color, 0.35);
outline: 0;
}
// Font smoothing
// ---------------------------------------
@mixin plyr-font-smoothing($mode: true) {
@if $mode {
-moz-osx-font-smoothing: grayscale;
-webkit-font-smoothing: antialiased;
} @else {
-moz-osx-font-smoothing: auto;
-webkit-font-smoothing: subpixel-antialiased;
}
}
// <input type="range"> styling
// ---------------------------------------
@mixin plyr-range-track() {
background: transparent;
border: 0;
border-radius: ($plyr-range-track-height / 2);
height: $plyr-range-track-height;
transition: all 0.3s ease;
user-select: none;
}
@mixin plyr-range-thumb() {
background: $plyr-range-thumb-bg;
border: $plyr-range-thumb-border;
border-radius: 100%;
box-shadow: $plyr-range-thumb-shadow;
box-sizing: border-box;
height: $plyr-range-thumb-height;
position: relative;
transition: background 0.2s ease, border 0.2s ease, transform 0.2s ease;
width: $plyr-range-thumb-height;
}
@mixin plyr-range-thumb-active() {
background: $plyr-range-thumb-active-bg;
border-color: $plyr-range-thumb-active-border-color;
transform: scale(unit($plyr-range-thumb-active-height / $plyr-range-thumb-height));
}
// Fullscreen styles
// ---------------------------------------
@mixin plyr-fullscreen-active() {
background: #000;
border-radius: 0 !important;
height: 100%;
margin: 0;
width: 100%;
video {
height: 100%;
}
.plyr__video-wrapper {
height: 100%;
width: 100%;
}
.plyr__video-embed {
// Revert overflow change
overflow: visible;
}
// Vimeo requires some different styling
&.plyr--vimeo .plyr__video-wrapper {
height: 0;
top: 50%;
transform: translateY(-50%);
}
// Display correct icon
.plyr__control .icon--exit-fullscreen {
display: block;
+ svg {
display: none;
}
}
// Large captions in full screen on larger screens
@media (min-width: $plyr-bp-lg) {
.plyr__captions {
font-size: $plyr-font-size-captions-large;
}
}
}