fix(mobile): prevent environment row taps from swallowing switches #17677
MergedRohithkadaveru(GitHub profile, opens in a new tab)merged 5 commits into
main fromrefs/pull/17677/headmerged by juliusmarminge View on GitHubgithub-actions[bot](GitHub profile, opens in a new tab) added labelsvouch:unvouched
github-actions[bot](GitHub profile, opens in a new tab) added labelssize:M
coderabbitai[bot](GitHub profile, opens in a new tab) requested changes
apps/mobile/src/features/connection/CloudEnvironmentRows.tsx lines 419 to 423OutdatedResolvedby coderabbitai[bot](GitHub profile, opens in a new tab)@@ -404,12 +407,17 @@404407 />405408 ) : null}406409 </StatusContainer>407- </View>410+ </Pressable>408411 <ThemedSwitch412+ accessibilityLabel={`Enable ${props.label}`}409413 style={{ alignSelf: "center" }}410414 disabled={props.disabled}411415 onValueChange={props.onValueChange}412416 value={props.value}413417 />414418 {props.opensDetails || props.showChevron ? (415- <View style={{ opacity: props.opensDetails ? 1 : 0.4 }}>419+ <Pressable420+ accessibilityRole={props.onOpen ? "button" : undefined}421+ accessibilityLabel={props.onOpen ? `Manage ${props.label}` : undefined}422+ onPress={props.onOpen}423+ onLongPress={props.onRemove}apps/mobile/src/features/connection/CloudEnvironmentRows.tsx lines 419 to 425OutdatedResolvedby coderabbitai[bot](GitHub profile, opens in a new tab)@@ -404,12 +407,19 @@404407 />405408 ) : null}406409 </StatusContainer>407- </View>410+ </Pressable>408411 <ThemedSwitch412+ accessibilityLabel={`Enable ${props.label}`}409413 style={{ alignSelf: "center" }}410414 disabled={props.disabled}411415 onValueChange={props.onValueChange}412416 value={props.value}413417 />414418 {props.opensDetails || props.showChevron ? (415- <View style={{ opacity: props.opensDetails ? 1 : 0.4 }}>419+ <Pressable420+ accessibilityRole={props.onOpen ? "button" : undefined}421+ accessibilityLabel={props.onOpen ? `Manage ${props.label}` : undefined}422+ onPress={props.onOpen}423+ onLongPress={props.onRemove}424+ hitSlop={8}425+ style={{ opacity: props.opensDetails ? 1 : 0.4 }}apps/mobile/src/features/connection/ConnectionEnvironmentRow.tsx line 85OutdatedResolvedby coderabbitai[bot](GitHub profile, opens in a new tab)@@ -78,12 +78,8 @@78787979 return (8080 <Animated.View layout={LinearTransition.duration(250)} className="bg-grouped-card">81- <Pressable82- className="flex-row items-center gap-3 px-4 py-3.5 active:opacity-70"83- accessibilityRole="button"84- accessibilityLabel={85- props.opensDetails ? `Manage ${props.environment.environmentLabel}` : undefined86- }87- onPress={props.onToggle}88- >89- <View className="flex-1 gap-0.5">81+ <View className="flex-row items-center gap-3 px-4 py-3.5">82+ <Pressable83+ className="min-w-0 flex-1 gap-0.5 active:opacity-70"84+ accessibilityRole="button"85+ accessibilityLabel={`Manage ${props.environment.environmentLabel}`}coderabbitai[bot](GitHub profile, opens in a new tab) approved these changes
maria-rcks closed this
maria-rcks reopened this
Rohithkadaveru(GitHub profile, opens in a new tab) changed the title
juliusmarminge merged this97986f7
juliusmarminge closed this
Sign in to join this conversation.


macroscopeapp[bot](GitHub profile, opens in a new tab) approved these changes