feat(mobile): combine PR sidebar and checks parity (#5641)

Co-authored-by: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Co-authored-by: Orca <help@stably.ai>
Co-authored-by: gsxdsm <gsxdsm@users.noreply.github.com>
This commit is contained in:
Jinwoo Hong
2026-06-17 22:52:12 -07:00
committed by GitHub
co-authored by Claude Opus 4.8 Orca gsxdsm
parent a61c549d37
commit c9bd61376f
181 changed files with 19522 additions and 4464 deletions
@@ -0,0 +1,58 @@
import { Pressable, Text, View } from 'react-native'
import { ChevronLeft, RefreshCw, X } from 'lucide-react-native'
import { colors } from '../theme/mobile-theme'
import { styles } from './mobile-source-control-styles'
type Props = {
embedded: boolean
worktreeLabel: string
ioBusy: boolean
onBack: () => void
onRefresh: () => void
}
export function MobileSourceControlHeader({
embedded,
worktreeLabel,
ioBusy,
onBack,
onRefresh
}: Props) {
return (
<View style={styles.topBar}>
<Pressable
style={({ pressed }) => [styles.backButton, pressed && styles.backButtonPressed]}
onPress={onBack}
hitSlop={8}
accessibilityLabel={embedded ? 'Close source control' : 'Back to session'}
>
{embedded ? (
<X size={22} color={colors.textSecondary} strokeWidth={2.2} />
) : (
<ChevronLeft size={22} color={colors.textSecondary} strokeWidth={2.2} />
)}
</Pressable>
<View style={styles.titleBlock}>
<Text style={styles.title} numberOfLines={1}>
Source Control
</Text>
<Text style={styles.meta} numberOfLines={1}>
{worktreeLabel}
</Text>
</View>
<Pressable
style={({ pressed }) => [
styles.refreshButton,
ioBusy && styles.refreshButtonDisabled,
pressed && styles.refreshButtonPressed
]}
onPress={onRefresh}
disabled={ioBusy}
hitSlop={8}
accessibilityLabel="Refresh source control"
>
<RefreshCw size={18} color={colors.textSecondary} strokeWidth={2.1} />
</Pressable>
</View>
)
}