Move /platform/detection vars into /env (#9707)

* Add platform vars to env

* Replace /platform/detection with /env
This commit is contained in:
Eric Bailey
2026-01-16 16:28:17 -06:00
committed by GitHub
parent bd510d8468
commit 0589bd7d9e
244 changed files with 789 additions and 789 deletions
+4 -4
View File
@@ -1,11 +1,11 @@
import {Dimensions} from 'react-native'
import {isSafari} from '#/lib/browser'
import {isWeb} from '#/platform/detection'
import {IS_WEB} from '#/env'
const {height: SCREEN_HEIGHT} = Dimensions.get('window')
const IFRAME_HOST = isWeb
const IFRAME_HOST = IS_WEB
? // @ts-ignore only for web
window.location.host === 'localhost:8100'
? 'http://localhost:8100'
@@ -132,7 +132,7 @@ export function parseEmbedPlayerFromUrl(
urlp.hostname === 'www.twitch.tv' ||
urlp.hostname === 'm.twitch.tv'
) {
const parent = isWeb
const parent = IS_WEB
? // @ts-ignore only for web
window.location.hostname
: 'localhost'
@@ -559,7 +559,7 @@ export function parseTenorGif(urlp: URL):
width: Number(w),
}
if (isWeb) {
if (IS_WEB) {
if (isSafari) {
id = id.replace('AAAAC', 'AAAP1')
filename = filename.replace('.gif', '.mp4')