Hide element picker in production

This commit is contained in:
Mohamed Boudra
2026-05-03 14:36:01 +07:00
parent d4fa12c3f6
commit 831d0bbf6e
@@ -22,6 +22,7 @@ import {
isElectronRuntime, isElectronRuntime,
type DesktopBrowserShortcutEvent, type DesktopBrowserShortcutEvent,
} from "@/desktop/host"; } from "@/desktop/host";
import { isDev } from "@/constants/platform";
import { useBrowserStore, normalizeWorkspaceBrowserUrl } from "@/stores/browser-store"; import { useBrowserStore, normalizeWorkspaceBrowserUrl } from "@/stores/browser-store";
type ElectronWebview = HTMLElement & { type ElectronWebview = HTMLElement & {
@@ -971,17 +972,19 @@ export function BrowserPane({
/> />
</View> </View>
<View style={styles.chromeRight}> <View style={styles.chromeRight}>
<Pressable {isDev ? (
accessibilityRole="button" <Pressable
accessibilityLabel={selectorActive ? "Cancel element selector" : "Select element"} accessibilityRole="button"
onPress={handleToggleElementSelector} accessibilityLabel={selectorActive ? "Cancel element selector" : "Select element"}
style={selectorIconButtonStyle} onPress={handleToggleElementSelector}
> style={selectorIconButtonStyle}
<MousePointer2 >
size={16} <MousePointer2
color={selectorActive ? theme.colors.accent : theme.colors.foregroundMuted} size={16}
/> color={selectorActive ? theme.colors.accent : theme.colors.foregroundMuted}
</Pressable> />
</Pressable>
) : null}
</View> </View>
</View> </View>
{browser?.lastError ? ( {browser?.lastError ? (