Move /platform/detection vars into /env (#9707)
* Add platform vars to env * Replace /platform/detection with /env
This commit is contained in:
@@ -12,11 +12,11 @@ import {
|
||||
toNiceDomain,
|
||||
} from '#/lib/strings/url-helpers'
|
||||
import {logger} from '#/logger'
|
||||
import {isNative} from '#/platform/detection'
|
||||
import {useInAppBrowser} from '#/state/preferences/in-app-browser'
|
||||
import {useTheme} from '#/alf'
|
||||
import {useDialogContext} from '#/components/Dialog'
|
||||
import {useGlobalDialogsControlContext} from '#/components/dialogs/Context'
|
||||
import {IS_NATIVE} from '#/env'
|
||||
|
||||
export function useOpenLink() {
|
||||
const enabled = useInAppBrowser()
|
||||
@@ -41,7 +41,7 @@ export function useOpenLink() {
|
||||
}
|
||||
}
|
||||
|
||||
if (isNative && !url.startsWith('mailto:')) {
|
||||
if (IS_NATIVE && !url.startsWith('mailto:')) {
|
||||
if (override === undefined && enabled === undefined) {
|
||||
// consent dialog is a global dialog, and while it's possible to nest dialogs,
|
||||
// the actual components need to be nested. sibling dialogs on iOS are not supported.
|
||||
|
||||
Reference in New Issue
Block a user