diff --git a/packages/taler-merchant-webui/src/screens/UnauthorizedScreen.tsx b/packages/taler-merchant-webui/src/screens/UnauthorizedScreen.tsx index bbc370df1..c88323153 100644 --- a/packages/taler-merchant-webui/src/screens/UnauthorizedScreen.tsx +++ b/packages/taler-merchant-webui/src/screens/UnauthorizedScreen.tsx @@ -15,6 +15,7 @@ */ import type { VNode } from "preact"; +import { useEffect, useRef } from "preact/hooks"; import { TalerLogo } from "../ui/TalerLogo.js"; import { useTranslation } from "../context/translation.js"; import { RawLayout } from "../ui/RawLayout.js"; @@ -44,6 +45,11 @@ export function UnauthorizedScreen({ "Your session token was rejected by the server (HTTP 401 Unauthorized)." ? t`Your session token was rejected by the server (HTTP 401 Unauthorized).` : errorDetail; + // Signing in again is the only thing to do here. + const signInAgain = useRef(null); + useEffect(() => { + signInAgain.current?.focus(); + }, []); return ( @@ -87,6 +93,7 @@ export function UnauthorizedScreen({