mirror of
https://github.com/Sonarr/Sonarr.git
synced 2026-04-25 22:46:31 -04:00
16 lines
353 B
TypeScript
16 lines
353 B
TypeScript
import MobileDetect from 'mobile-detect';
|
|
|
|
const mobileDetect = new MobileDetect(window.navigator.userAgent);
|
|
|
|
export function isMobile() {
|
|
return mobileDetect.mobile() != null;
|
|
}
|
|
|
|
export function isIOS() {
|
|
return mobileDetect.is('iOS');
|
|
}
|
|
|
|
export function isFirefox() {
|
|
return window.navigator.userAgent.toLowerCase().indexOf('firefox/') >= 0;
|
|
}
|