-
Notifications
You must be signed in to change notification settings - Fork 3.7k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
#1517: Mark Chrome for Android as not supporting native DnD
- Loading branch information
Showing
2 changed files
with
9 additions
and
16 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,17 +1,10 @@ | ||
function userAgent(pattern) { | ||
return !!navigator.userAgent.match(pattern); | ||
return !!/*@__PURE__*/navigator.userAgent.match(pattern); | ||
} | ||
|
||
const IE11OrLess = /*@__PURE__*/userAgent(/(?:Trident.*rv[ :]?11\.|msie|iemobile|Windows Phone)/i); | ||
const Edge = /*@__PURE__*/userAgent(/Edge/i); | ||
const FireFox = /*@__PURE__*/userAgent(/firefox/i); | ||
const Safari = /*@__PURE__*/userAgent(/safari/i) && !userAgent(/chrome/i) && !userAgent(/android/i); | ||
const IOS = /*@__PURE__*/userAgent(/iP(ad|od|hone)/i); | ||
|
||
export { | ||
IE11OrLess, | ||
Edge, | ||
FireFox, | ||
Safari, | ||
IOS | ||
}; | ||
export const IE11OrLess = userAgent(/(?:Trident.*rv[ :]?11\.|msie|iemobile|Windows Phone)/i); | ||
export const Edge = userAgent(/Edge/i); | ||
export const FireFox = userAgent(/firefox/i); | ||
export const Safari = userAgent(/safari/i) && !userAgent(/chrome/i) && !userAgent(/android/i); | ||
export const IOS = userAgent(/iP(ad|od|hone)/i); | ||
export const ChromeForAndroid = userAgent(/chrome/i) && userAgent(/android/i); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters