@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 35 lines 1.03 KB
Raw
1 import { SheetHeader } from "../../components/ui/SheetHeader";
2 import { useNavigation } from "@react-navigation/native";
3 import type { ReactNode } from "react";
4 import { View } from "react-native";
5 import { FitSheet } from "../../components/ui/FitSheet";
6
7 export function PullRequestSheetContent(props: {
8 readonly title: string;
9 readonly subtitle: string;
10 readonly busy?: boolean;
11 readonly children: ReactNode;
12 readonly footer?: ReactNode;
13 }) {
14 const navigation = useNavigation();
15 return (
16 <FitSheet
17 avoidsKeyboard
18 header={
19 <SheetHeader
20 title={props.title}
21 subtitle={props.subtitle}
22 onCancel={() => navigation.goBack()}
23 dismissDisabled={props.busy}
24 />
25 }
26 footer={props.footer}
27 keyboardShouldPersistTaps="handled"
28 contentContainerStyle={{ paddingHorizontal: 16, paddingTop: 16, paddingBottom: 20 }}
29 >
30 <View className="gap-4" pointerEvents={props.busy ? "none" : "auto"}>
31 {props.children}
32 </View>
33 </FitSheet>
34 );
35 }