Marc Kupietz | 09b7575 | 2023-10-07 09:32:19 +0200 | [diff] [blame^] | 1 | const UA = navigator.userAgent; |
2 | |||||
3 | export const isMobile = /(iphone|ipod|ipad|android)/gi.test( UA ) || | ||||
4 | ( navigator.platform === 'MacIntel' && navigator.maxTouchPoints > 1 ); // iPadOS | ||||
5 | |||||
6 | export const isChrome = /chrome/i.test( UA ) && !/edge/i.test( UA ); | ||||
7 | |||||
8 | export const isAndroid = /android/gi.test( UA ); |