View Issue Details
| ID | Project | Category | View Status | Date Submitted | Last Update |
|---|---|---|---|---|---|
| 0012045 | Taler | challenger | public | 2026-11-10 23:42 | 2026-11-18 17:07 |
| Reporter | bot-cg [agent] | ||||
| Communicator | CM_7 | ||||
| Priority | normal | Severity | trivial | ||
| Status | closed | Resolution | fixed | ||
| Target Version | 1.6 | Fixed in Version | 1.6 | ||
| Summary | 0012045: Challenger: developer 'Create a verification session' form does not focus the client password (or redirect URL) | ||||
| Description | What happens: Setup supports `focus` (ref={focus ? doAutoFocus : undefined} on the password field), but Routing never passed it, so #/setup/<client> focused nothing. Had it been passed, the password would be focused even when `secret` came in the URL and the field was read-only. Measured: #/setup/client1 = BODY; #/setup/client1?secret=... = BODY. Expected: Focus is on the first field the developer still has to fill in: the password, or the redirect URL when the secret is given in the URL. Nothing is focused when both are given. Where: - packages/challenger-webui/src/pages/Setup.tsx:90 - packages/challenger-webui/src/Routing.tsx:139 Measured in headless Chromium (document.activeElement): before: BODY (setup, setup-with-secret) after: INPUT#password (setup); INPUT#redirect_url (setup-with-secret, see challenger--setup-with-secret--after.png) Proposed fix: Routing passes `focus` to Setup. Setup computes which field is the first still editable and attaches the existing doAutoFocus ref to that field only. Patch against taler-typescript-core master attached; the same change is committed on branch dev/bots/autofocus (durian). Screenshots attached (focused element outlined in red): 'before' is master, 'after' is with the patch. Verified: tsc --noEmit ok; eslint + prettier clean; rendered in Chromium, before and after | ||||
| Tags | No tags attached. | ||||
| Attached Files | challenger--setup-focus.diff (1,945 bytes)
diff --git a/packages/challenger-webui/src/Routing.tsx b/packages/challenger-webui/src/Routing.tsx
index 5723d901d..8ad764e54 100644
--- a/packages/challenger-webui/src/Routing.tsx
+++ b/packages/challenger-webui/src/Routing.tsx
@@ -137,6 +137,7 @@ function PublicRouting(): VNode {
return (
<Setup
+ focus
clientId={safeDecodeURIComponent(location.values.client)}
secret={secret}
redirectURL={redirectURL}
diff --git a/packages/challenger-webui/src/pages/Setup.tsx b/packages/challenger-webui/src/pages/Setup.tsx
index c76ac982e..dc084e818 100644
--- a/packages/challenger-webui/src/pages/Setup.tsx
+++ b/packages/challenger-webui/src/pages/Setup.tsx
@@ -85,6 +85,15 @@ export function Setup({ clientId, secret, redirectURL, focus }: Props): VNode {
? invalidUrlMessage
: undefined,
});
+ // Values passed in the URL are read-only; start on the first field the
+ // developer still has to fill in.
+ const focusField = !focus
+ ? undefined
+ : secret === undefined
+ ? "password"
+ : redirectURL === undefined
+ ? "redirect_url"
+ : undefined;
const startArgs =
errors || !password || !url
? undefined
@@ -138,7 +147,7 @@ export function Setup({ clientId, secret, redirectURL, focus }: Props): VNode {
{clientPasswordLabel}
</label>
<input
- ref={focus ? doAutoFocus : undefined}
+ ref={focusField === "password" ? doAutoFocus : undefined}
id="password"
name="password"
type="password"
@@ -162,6 +171,7 @@ export function Setup({ clientId, secret, redirectURL, focus }: Props): VNode {
{redirectUrlLabel}
</label>
<input
+ ref={focusField === "redirect_url" ? doAutoFocus : undefined}
id="redirect_url"
name="redirect_url"
type="url"
| ||||
| child of | 0012024 | closed | Web UIs (bank, wallet, exchange AML/KYC, challenger, auditor, web-util forms): dialogs and single-purpose forms open without keyboard focus on the obvious field |
| commit fb42fd4355e0f9dc8380fcdee369a640fce00ee8 Author: Florian Dold <dold@taler.net> Date: Fri Nov 13 01:06:16 2026 +0100 challenger web UI: focus address and code steps once Focus the first editable setup or address field. Key code focus by the challenge session so resend countdowns do not move the cursor. Issue: https://bugs.taler.net/n/12043 Issue: https://bugs.taler.net/n/12044 Issue: https://bugs.taler.net/n/12045 Assisted-by: LLM commit c1ee0c1022645200e605a3f36ab4910a3750c180 Author: Florian Dold <dold@taler.net> Date: Fri Nov 13 01:06:11 2026 +0100 web-util: focus pages and form steps when their controls are ready FocusScope queues one initial focus request when a page, form or step opens. It waits for loading and cancels the request if the user moves focus. useFocusTarget retries pending focus when a control mounts. Explicit requestFocus calls run immediately and return success or failure. Issue: https://bugs.taler.net/n/12002 Issue: https://bugs.taler.net/n/12024 Assisted-by: LLM | |
| Date Modified | Username | Field | Change |
|---|---|---|---|
| 2026-11-10 23:42 | bot-cg | New Issue | |
| 2026-11-10 23:42 | bot-cg | Relationship added | child of 0012024 |
| 2026-11-10 23:43 | bot-cg | File Added: challenger--setup-focus.diff | |
| 2026-11-10 23:43 | bot-cg | File Added: challenger--setup--before.png | |
| 2026-11-10 23:43 | bot-cg | File Added: challenger--setup--after.png | |
| 2026-11-11 16:29 | Christian Grothoff | Severity | tweak => trivial |
| 2026-11-11 22:16 | Christian Grothoff | Implementer | => Christian Grothoff |
| 2026-11-11 22:17 | Christian Grothoff | Implementer | Christian Grothoff => |
| 2026-11-13 09:13 | bot-codex-florian-dold | Note Added: 0030492 | |
| 2026-11-13 09:13 | bot-codex-florian-dold | Status | new => closed |
| 2026-11-13 09:13 | bot-codex-florian-dold | Resolution | open => fixed |
| 2026-11-18 17:02 | Christian Grothoff | Target Version | => 1.6 |
| 2026-11-18 17:07 | Christian Grothoff | Fixed in Version | => 1.6 |