mirror of
https://github.com/ianstormtaylor/slate.git
synced 2025-08-22 23:12:52 +02:00
Fix chrome and edge three digit version check (#4883)
* fix chrome and edge three digit version check #4869 * add changelist
This commit is contained in:
committed by
GitHub
parent
2a620dc20d
commit
3b3b0e32df
5
.changeset/cuddly-foxes-sell.md
Normal file
5
.changeset/cuddly-foxes-sell.md
Normal file
@@ -0,0 +1,5 @@
|
|||||||
|
---
|
||||||
|
'slate-react': minor
|
||||||
|
---
|
||||||
|
|
||||||
|
Fix chrome and edge three digit version check
|
@@ -21,7 +21,7 @@ export const IS_SAFARI =
|
|||||||
// "modern" Edge was released at 79.x
|
// "modern" Edge was released at 79.x
|
||||||
export const IS_EDGE_LEGACY =
|
export const IS_EDGE_LEGACY =
|
||||||
typeof navigator !== 'undefined' &&
|
typeof navigator !== 'undefined' &&
|
||||||
/Edge?\/(?:[0-6][0-9]|[0-7][0-8])/i.test(navigator.userAgent)
|
/Edge?\/(?:[0-6][0-9]|[0-7][0-8])(\.)/i.test(navigator.userAgent)
|
||||||
|
|
||||||
export const IS_CHROME =
|
export const IS_CHROME =
|
||||||
typeof navigator !== 'undefined' && /Chrome/i.test(navigator.userAgent)
|
typeof navigator !== 'undefined' && /Chrome/i.test(navigator.userAgent)
|
||||||
@@ -30,7 +30,7 @@ export const IS_CHROME =
|
|||||||
// and older, Chrome 76+ can use `beforeInput` though.
|
// and older, Chrome 76+ can use `beforeInput` though.
|
||||||
export const IS_CHROME_LEGACY =
|
export const IS_CHROME_LEGACY =
|
||||||
typeof navigator !== 'undefined' &&
|
typeof navigator !== 'undefined' &&
|
||||||
/Chrome?\/(?:[0-7][0-5]|[0-6][0-9])/i.test(navigator.userAgent)
|
/Chrome?\/(?:[0-7][0-5]|[0-6][0-9])(\.)/i.test(navigator.userAgent)
|
||||||
|
|
||||||
// Firefox did not support `beforeInput` until `v87`.
|
// Firefox did not support `beforeInput` until `v87`.
|
||||||
export const IS_FIREFOX_LEGACY =
|
export const IS_FIREFOX_LEGACY =
|
||||||
|
Reference in New Issue
Block a user