aboutsummaryrefslogtreecommitdiffstats
path: root/test/unit/support.js
diff options
context:
space:
mode:
authorMichał Gołębiowski-Owczarek <m.goleb@gmail.com>2020-09-22 17:49:28 +0200
committerGitHub <noreply@github.com>2020-09-22 17:49:28 +0200
commite35fb62db4fb46f031056bb53e393982c03972a1 (patch)
treeae55e7e05133da5637d188d73c312c4538d8b5b4 /test/unit/support.js
parent15ae361485056b236a9484a185238f992806e1ff (diff)
downloadjquery-e35fb62db4fb46f031056bb53e393982c03972a1.tar.gz
jquery-e35fb62db4fb46f031056bb53e393982c03972a1.zip
Core: Drop support for Edge Legacy (i.e. non-Chromium Microsoft Edge)
Drop support for Edge Legacy: the non-Chromium, EdgeHTML-based Microsoft Edge version. Also, restrict some workarounds that were applied unconditionally in all browsers to run only in IE now. This slightly increases the size but reduces the performance burden on modern browsers that don't need the workarounds. Also, clean up some comments & remove some obsolete workarounds. Fixes gh-4568 Closes gh-4792
Diffstat (limited to 'test/unit/support.js')
-rw-r--r--test/unit/support.js35
1 files changed, 7 insertions, 28 deletions
diff --git a/test/unit/support.js b/test/unit/support.js
index b2d4eb350..008453085 100644
--- a/test/unit/support.js
+++ b/test/unit/support.js
@@ -58,39 +58,18 @@ testIframe(
var expected,
userAgent = window.navigator.userAgent,
expectedMap = {
- edge: {
- reliableTrDimensions: false,
- scope: undefined
- },
- ie_11: {
- reliableTrDimensions: false,
- scope: undefined
- },
- chrome: {
- reliableTrDimensions: true,
- scope: true
- },
- safari: {
- reliableTrDimensions: true,
- scope: true
- },
- firefox: {
- reliableTrDimensions: true,
- scope: true
- },
- ios: {
- reliableTrDimensions: true,
- scope: true
- }
+ ie_11: {},
+ chrome: {},
+ safari: {},
+ firefox: {},
+ ios: {}
};
- if ( /edge\//i.test( userAgent ) ) {
- expected = expectedMap.edge;
- } else if ( document.documentMode ) {
+ if ( document.documentMode ) {
expected = expectedMap.ie_11;
} else if ( /chrome/i.test( userAgent ) ) {
- // Catches Chrome on Android & Opera as well.
+ // Catches Edge, Chrome on Android & Opera as well.
expected = expectedMap.chrome;
} else if ( /\b\d+(\.\d+)+ safari/i.test( userAgent ) ) {
expected = expectedMap.safari;