diff --git a/packages/beacon-ui/src/utils/platform.ts b/packages/beacon-ui/src/utils/platform.ts index 16a10a37c..1e9ca66ff 100644 --- a/packages/beacon-ui/src/utils/platform.ts +++ b/packages/beacon-ui/src/utils/platform.ts @@ -33,9 +33,11 @@ const isIpad = (win: Window): boolean => { return false } -export const isIOS = (win: Window): boolean => testUserAgent(win, /iPhone|iPod/i) || isIpad(win) +export const isPrivacyBrowser = (win: Window): boolean => testUserAgent(win, /Mobile DuckDuckGo/i) -export const isAndroid = (win: Window): boolean => testUserAgent(win, /android|sink/i) +export const isIOS = (win: Window): boolean => isPrivacyBrowser(win) || testUserAgent(win, /iPhone|iPod|Mobile DuckDuckGo/i) || isIpad(win) + +export const isAndroid = (win: Window): boolean => !isPrivacyBrowser(win) && testUserAgent(win, /android|sink/i) export const isTwBrowser = (win: Window): boolean => win && (win as any).ethereum?.isTrust == true