@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 24 lines 895 Bytes
Raw
1 import { useGT } from "gt-react-native";
2 import { View } from "react-native";
3
4 import { Notice } from "../../components/ui/Notice";
5 import { setFreshSessionPending, useComposerDraftSettings } from "../../state/use-composer-drafts";
6
7 /** Shown while `/clear` is armed; dismissing it keeps the current session. */
8 export function FreshSessionNotice(props: { readonly threadKey: string }) {
9 const gt = useGT();
10 if (useComposerDraftSettings(props.threadKey).freshContext !== true) return null;
11 return (
12 <View className="px-4 pb-3">
13 <Notice
14 message={gt(
15 "Your next message starts a fresh session. The agent won't see earlier messages in this thread.",
16 )}
17 icon="arrow.clockwise"
18 floating
19 onDismiss={() => setFreshSessionPending(props.threadKey, false)}
20 dismissLabel={gt("Keep the current session")}
21 />
22 </View>
23 );
24 }