85782aeb93
move this to the `onKeyDown` prop Revert "do the same for tablets" This reverts commit 47c709e2734f2acf34f89dd5aca42a75a2b56270. do the same for tablets don't submit message if the device is a phone on web move `onTouchStart` to `browser.ts` globals
8 lines
313 B
TypeScript
8 lines
313 B
TypeScript
// https://stackoverflow.com/questions/7944460/detect-safari-browser
|
|
export const isSafari = /^((?!chrome|android).)*safari/i.test(
|
|
navigator.userAgent,
|
|
)
|
|
export const isFirefox = /firefox|fxios/i.test(navigator.userAgent)
|
|
export const isTouchDevice =
|
|
'ontouchstart' in window || navigator.maxTouchPoints > 1
|