From 2792b4cef0daf002066237f6bfb9e8964f64eace Mon Sep 17 00:00:00 2001 From: Samuel Newman Date: Thu, 20 Nov 2025 17:54:02 +0200 Subject: [PATCH] prevent webview from showing during device attest (#9425) --- src/screens/Signup/StepCaptcha/CaptchaWebView.tsx | 3 +++ src/screens/Signup/StepCaptcha/index.tsx | 1 + 2 files changed, 4 insertions(+) diff --git a/src/screens/Signup/StepCaptcha/CaptchaWebView.tsx b/src/screens/Signup/StepCaptcha/CaptchaWebView.tsx index f208951d5b..fa7b3064ee 100644 --- a/src/screens/Signup/StepCaptcha/CaptchaWebView.tsx +++ b/src/screens/Signup/StepCaptcha/CaptchaWebView.tsx @@ -21,12 +21,14 @@ export function CaptchaWebView({ url, stateParam, state, + onComplete, onSuccess, onError, }: { url: string stateParam: string state?: SignupState + onComplete: () => void onSuccess: (code: string) => void onError: (error: unknown) => void }) { @@ -71,6 +73,7 @@ export function CaptchaWebView({ // We want to delay the completion of this screen ever so slightly so that it doesn't appear to be a glitch if it completes too fast wasSuccessful.current = true + onComplete() const now = Date.now() const timeTaken = now - startedAt.current if (timeTaken < MIN_DELAY) { diff --git a/src/screens/Signup/StepCaptcha/index.tsx b/src/screens/Signup/StepCaptcha/index.tsx index e1d7afd01b..bfde057be2 100644 --- a/src/screens/Signup/StepCaptcha/index.tsx +++ b/src/screens/Signup/StepCaptcha/index.tsx @@ -156,6 +156,7 @@ function StepCaptchaInner({ url={url} stateParam={stateParam} state={state} + onComplete={() => setCompleted(true)} onSuccess={onSuccess} onError={onError} />