From 6b4ea195212f91d36bff6ec243ca4b7b63a12814 Mon Sep 17 00:00:00 2001 From: chahinebrini Date: Thu, 7 May 2026 21:39:07 +0200 Subject: [PATCH] fix(compose): Share-Button onPressIn fixes keyboard-tap, native iOS-Style MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Diagnose: ComposeCard ist ListHeaderComponent der FlatList die keyboardShouldPersistTaps="handled" hat. Aber das Prop propagiert nicht rekursiv durch tiefere View-Ketten — der Share-Button-Pressable liegt zu tief, der erste Tap dismissed nur die Tastatur. Fix: onPress → onPressIn (fired beim Touch-Down vor Keyboard-Dismiss- Logic). Identisch zum Pattern beim Bild-Icon. Guard if(!content.trim() || posting) repliziert die disabled-Logik die onPress hatte. Style: native iOS Primary-Action-Button-Look: - height 44→50, px-5→px-6 - rounded-full → borderRadius 12 (Rectangle statt Pill) - Nunito_700Bold → 600SemiBold - Plain text "Teilen", kein Icon Co-Authored-By: Claude Opus 4.7 (1M context) --- apps/rebreak-native/components/ComposeCard.tsx | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/apps/rebreak-native/components/ComposeCard.tsx b/apps/rebreak-native/components/ComposeCard.tsx index 38aee96..74b3bc5 100644 --- a/apps/rebreak-native/components/ComposeCard.tsx +++ b/apps/rebreak-native/components/ComposeCard.tsx @@ -161,18 +161,20 @@ export function ComposeCard({ onPosted }: Props) { {t('common.cancel')} { if (!content.trim() || posting) return; submit(); }} disabled={!content.trim() || posting} - className="px-5 rounded-full bg-rebreak-500 items-center justify-center" + className="bg-rebreak-500 items-center justify-center" style={({ pressed }) => ({ - height: 44, + height: 50, + paddingHorizontal: 24, + borderRadius: 12, opacity: pressed || !content.trim() || posting ? 0.5 : 1, })} > {posting ? ( ) : ( - {t('community.share')} + {t('community.share')} )}