Skip to content
TypeScript

fix(mobile): label the pull request toast action View (#25581)

Alex4e42eaf4293c
diff --git a/apps/mobile/src/features/threads/GitActionProgressOverlay.tsx b/apps/mobile/src/features/threads/GitActionProgressOverlay.tsx
index cf472442f46..08342cefcdf 100644
--- a/apps/mobile/src/features/threads/GitActionProgressOverlay.tsx
+++ b/apps/mobile/src/features/threads/GitActionProgressOverlay.tsx
@@ -1,4 +1,3 @@
-import { sourceControlClients } from "@t3tools/client-runtime/source-control-clients";
import { tryOpenExternalUrl } from "../../lib/openExternalUrl";
import * as Haptics from "expo-haptics";
import { HeaderHeightContext } from "@react-navigation/elements";
@@ -52,11 +51,6 @@ export function GitActionProgressOverlay(props: {
if (progress.phase === "idle") {
return null;
}
- const prUrl = progress.prUrl;
- // A finished action reports only the URL it created.
- const openLabel = prUrl
- ? `Open ${(sourceControlClients.findByChangeRequestUrl(prUrl) ?? sourceControlClients.get(undefined)).changeRequest.shortLabel}`
- : null;
return (
<Animated.View
@@ -79,7 +73,7 @@ export function GitActionProgressOverlay(props: {
: "default"
}
busy={progress.phase === "running"}
- action={openLabel ? { label: openLabel, onPress: handlePress } : undefined}
+ action={progress.prUrl ? { label: "View", onPress: handlePress } : undefined}
/>
</Animated.View>
);