From 4c252fe03d0738d65f6e6d0225d3a0a2d19db953 Mon Sep 17 00:00:00 2001 From: mister-ben Date: Sun, 14 May 2023 22:21:15 +0200 Subject: [PATCH] chore: remove legacy prefixes --- src/css/_utilities.scss | 40 +------------------------ src/css/components/_button.scss | 2 +- src/css/components/_loading.scss | 32 -------------------- src/css/utilities/_linear-gradient.scss | 2 -- src/js/fullscreen-api.js | 20 ------------- src/js/player.js | 2 -- 6 files changed, 2 insertions(+), 96 deletions(-) diff --git a/src/css/_utilities.scss b/src/css/_utilities.scss index 96d099f319..7dd1cce2b0 100644 --- a/src/css/_utilities.scss +++ b/src/css/_utilities.scss @@ -6,18 +6,10 @@ } @mixin transform($transform) { - -moz-transform: $transform; - -ms-transform: $transform; - -o-transform: $transform; - -webkit-transform: $transform; transform: $transform; } @mixin transition($string: $transition--default) { - -webkit-transition: $string; - -moz-transition: $string; - -ms-transition: $string; - -o-transition: $string; transition: $string; } @@ -32,44 +24,26 @@ } @mixin border-radius($radius) { - -webkit-border-radius: $radius; - -moz-border-radius: $radius; border-radius: $radius; } @mixin animation($string: spin 1s infinite linear) { - -webkit-animation: $string; - -moz-animation: $string; - -o-animation: $string; animation: $string; } @mixin display-flex($alignment: '', $justification: '') { - display: -webkit-box; - display: -webkit-flex; - display: -ms-flexbox; display: flex; @if $alignment != '' { - -webkit-box-align: $alignment; - -webkit-align-items: $alignment; - -ms-flex-align: $alignment; align-items: $alignment; } @if $justification != '' { - -webkit-box-pack: $justification; - -webkit-justify-content: $justification; - -ms-flex-pack: $justification; justify-content: $justification; } } @mixin flex($value) { - -webkit-box-flex: $value; - -moz-box-flex: $value; - -webkit-flex: $value; - -ms-flex: $value; flex: $value; } @@ -78,30 +52,18 @@ @mixin user-select($string: none) { /* iOS Safari */ -webkit-touch-callout: $string; - /* Safari */ + /* Safari, and Chrome 53 */ -webkit-user-select: $string; - /* Konqueror HTML */ - -khtml-user-select: $string; - /* Firefox */ - -moz-user-select: $string; - /* Internet Explorer/Edge */ - -ms-user-select: $string; /* Non-prefixed version, currently supported by Chrome and Opera */ user-select: $string; } // https://developer.mozilla.org/en-US/docs/Web/CSS/box-shadow @mixin box-shadow ($string: 0 0 1em rgba(0, 0, 0, 0.25)) { - -webkit-box-shadow: $string; - -moz-box-shadow: $string; box-shadow: $string; } @mixin order($value) { - -webkit-box-ordinal-group: $value; - -moz-box-ordinal-group: $value; - -ms-flex-order: $value; - -webkit-order: $value; order: $value; } diff --git a/src/css/components/_button.scss b/src/css/components/_button.scss index 740bc40739..3c7ae28ddc 100644 --- a/src/css/components/_button.scss +++ b/src/css/components/_button.scss @@ -10,8 +10,8 @@ text-decoration: none; transition: none; + // Chrome < 83 -webkit-appearance: none; - -moz-appearance: none; appearance: none; } diff --git a/src/css/components/_loading.scss b/src/css/components/_loading.scss index 2bd1792724..7dbee7da64 100644 --- a/src/css/components/_loading.scss +++ b/src/css/components/_loading.scss @@ -48,7 +48,6 @@ .vjs-seeking .vjs-loading-spinner:after, .vjs-waiting .vjs-loading-spinner:before, .vjs-waiting .vjs-loading-spinner:after { - -webkit-animation: vjs-spinner-spin 1.1s cubic-bezier(0.6, 0.2, 0, 0.8) infinite, vjs-spinner-fade 1.1s linear infinite; animation: vjs-spinner-spin 1.1s cubic-bezier(0.6, 0.2, 0, 0.8) infinite, vjs-spinner-fade 1.1s linear infinite; } @@ -60,7 +59,6 @@ .vjs-seeking .vjs-loading-spinner:after, .vjs-waiting .vjs-loading-spinner:after { border-top-color: rgb(255,255,255); - -webkit-animation-delay: 0.44s; animation-delay: 0.44s; } @@ -70,24 +68,12 @@ } } -@-webkit-keyframes vjs-spinner-show { - to { - visibility: visible; - } -} - @keyframes vjs-spinner-spin { 100% { transform: rotate(360deg); } } -@-webkit-keyframes vjs-spinner-spin { - 100% { - -webkit-transform: rotate(360deg); - } -} - @keyframes vjs-spinner-fade { 0% { border-top-color: $secondary-background-color; @@ -105,21 +91,3 @@ border-top-color: $secondary-background-color; } } - -@-webkit-keyframes vjs-spinner-fade { - 0% { - border-top-color: $secondary-background-color; - } - 20% { - border-top-color: $secondary-background-color; - } - 35% { - border-top-color: white; - } - 60% { - border-top-color: $secondary-background-color; - } - 100% { - border-top-color: $secondary-background-color; - } -} diff --git a/src/css/utilities/_linear-gradient.scss b/src/css/utilities/_linear-gradient.scss index 29ff668ff0..5adc2eb841 100644 --- a/src/css/utilities/_linear-gradient.scss +++ b/src/css/utilities/_linear-gradient.scss @@ -79,7 +79,6 @@ /// Mixin printing a linear-gradient /// as well as a plain color fallback -/// and the `-webkit-` prefixed declaration /// @access public /// @param {String | List | Angle} $direction - Linear gradient direction /// @param {Arglist} $color-stops - List of color-stops composing the gradient @@ -90,6 +89,5 @@ } background: nth(nth($color-stops, 1), 1); - background: -webkit-linear-gradient(legacy-direction($direction), $color-stops); background: linear-gradient($direction, $color-stops); } diff --git a/src/js/fullscreen-api.js b/src/js/fullscreen-api.js index 5e0ceff20d..86ad091758 100644 --- a/src/js/fullscreen-api.js +++ b/src/js/fullscreen-api.js @@ -35,26 +35,6 @@ const apiMap = [ 'webkitfullscreenchange', 'webkitfullscreenerror', '-webkit-full-screen' - ], - // Mozilla - [ - 'mozRequestFullScreen', - 'mozCancelFullScreen', - 'mozFullScreenElement', - 'mozFullScreenEnabled', - 'mozfullscreenchange', - 'mozfullscreenerror', - '-moz-full-screen' - ], - // Microsoft - [ - 'msRequestFullscreen', - 'msExitFullscreen', - 'msFullscreenElement', - 'msFullscreenEnabled', - 'MSFullscreenChange', - 'MSFullscreenError', - '-ms-fullscreen' ] ]; diff --git a/src/js/player.js b/src/js/player.js index 7d42ddd224..f5ffe664df 100644 --- a/src/js/player.js +++ b/src/js/player.js @@ -2055,8 +2055,6 @@ class Player extends Component { if (!isFs && el.matches) { isFs = el.matches(':' + this.fsApi_.fullscreen); - } else if (!isFs && el.msMatchesSelector) { - isFs = el.msMatchesSelector(':' + this.fsApi_.fullscreen); } this.isFullscreen(isFs);