@devries-cameron20 / t3code Mirror · read-only
Fork 0

The best way to control Claude Code, Codex and more from any computer or phone

Mirrored from https://github.com/Camo67/t3code.git

Synced Nov 21, 04:45 UTC

main
tsx 51 lines 1.8 KB
Raw
1 import Constants from "expo-constants";
2 import { Image } from "expo-image";
3 import { msg, T, useMessages } from "gt-react-native";
4 import { View } from "react-native";
5
6 import { AppText as Text } from "./ui/AppText";
7 import { T3_CODE_BRAND_MARK_SOURCE } from "./brandAssets";
8
9 const appVariant = Constants.expoConfig?.extra?.appVariant;
10 const DEFAULT_STAGE_LABEL =
11 appVariant === "development"
12 ? msg("Dev", { $context: "app release stage badge" })
13 : appVariant === "preview"
14 ? msg("Preview", { $context: "app release stage badge" })
15 : msg("Beta", { $context: "app release stage badge" });
16
17 export function BrandMark(props: { readonly compact?: boolean; readonly stageLabel?: string }) {
18 const m = useMessages();
19 const compact = props.compact ?? false;
20 const iconSize = compact ? 32 : 44;
21 const stageLabel = props.stageLabel ?? m(DEFAULT_STAGE_LABEL);
22
23 return (
24 <View className="flex-row items-center gap-3">
25 <Image
26 source={T3_CODE_BRAND_MARK_SOURCE}
27 accessibilityIgnoresInvertColors
28 style={{
29 width: iconSize,
30 height: iconSize,
31 borderRadius: compact ? 10 : 14,
32 }}
33 />
34 <View className="gap-1">
35 <View className="flex-row items-center gap-2">
36 <Text className="text-lg font-t3-bold tracking-[-0.4px] text-foreground">T3 Code</Text>
37 <View className="rounded-full bg-subtle px-2 py-1">
38 <Text className="text-3xs font-t3-bold tracking-[1.1px] uppercase text-foreground-muted">
39 {stageLabel}
40 </Text>
41 </View>
42 </View>
43 {!compact ? (
44 <Text className="text-xs font-medium text-foreground-muted">
45 <T>Mobile control surface for your live coding environments</T>
46 </Text>
47 ) : null}
48 </View>
49 </View>
50 );
51 }