View Issue Details
| ID | Project | Category | View Status | Date Submitted | Last Update |
|---|---|---|---|---|---|
| 0012007 | Taler | merchant portal webui | public | 2026-11-10 23:41 | 2026-11-10 23:43 |
| Reporter | bot-cg [agent] | Assigned To | Resolution deadline | ||
| Implementer | Reviewer | ||||
| Release signed by | Deployed by | ||||
| Verifier | Communicator | CM_7 | |||
| Data protection authority notification required | No | ||||
| CSIRT notification required | No | ||||
| Estimated effort (hours) | Actual effort (hours) | 0 | |||
| Fast-track | No | ||||
| Work package | none | ||||
| Priority | normal | Severity | tweak | Reproducibility | have not tried |
| Status | new | Resolution | open | ||
| Summary | 0012007: Merchant: 'Point this portal at a different server' page does not focus the server address | ||||
| Description | What happens: The page (from sign-in / BackendHostLink 'change server') has one field, Server address; nothing is focused on arrival (BODY). Expected: Focus the server address field. Where: - packages/taler-merchant-webui/src/screens/ChangeServerUrlScreen.tsx:77 Measured in headless Chromium (document.activeElement): before: BODY after: INPUT#server-url-input[url] Proposed fix: Ref + mount useEffect focusing #server-url-input. The embedded tutorial preview is covered by LiveComponentPreview's mount guard. 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 ok; eslint clean; screenshot confirms; tutorial-previews check: no focus/scroll inside previews | ||||
| Tags | No tags attached. | ||||
| Attached Files | merchant-a--change-server-url.diff (1,548 bytes)
diff --git a/packages/taler-merchant-webui/src/screens/ChangeServerUrlScreen.tsx b/packages/taler-merchant-webui/src/screens/ChangeServerUrlScreen.tsx
index 6a208d7e3..a80fce845 100644
--- a/packages/taler-merchant-webui/src/screens/ChangeServerUrlScreen.tsx
+++ b/packages/taler-merchant-webui/src/screens/ChangeServerUrlScreen.tsx
@@ -16,7 +16,7 @@
import { ActionFooter } from "../ui/FormActionFooter.js";
import type { VNode } from "preact";
-import { useState } from "preact/hooks";
+import { useEffect, useRef, useState } from "preact/hooks";
import { TalerLogo } from "../ui/TalerLogo.js";
import { CopyErrorButton } from "../ui/CopyErrorButton.js";
import { currentBackendUrl, setCustomBackendUrl } from "../stores/session.js";
@@ -73,6 +73,11 @@ export function ChangeServerUrlScreen({
const [url, setUrl] = useState<string>(initialUrl || currentBackendUrl.value);
const [errorMsg, setErrorMsg] = useState<string>("");
const [isVerifying, setIsVerifying] = useState<boolean>(false);
+ // The address is what this page is for.
+ const urlInput = useRef<HTMLInputElement>(null);
+ useEffect(() => {
+ urlInput.current?.focus();
+ }, []);
const handleSubmit = async (e: Event) => {
e.preventDefault();
@@ -193,6 +198,7 @@ export function ChangeServerUrlScreen({
{t`Server address`} <span class="text-red-500">*</span>
</label>
<input
+ ref={urlInput}
id="server-url-input"
type="url"
value={url}
| ||||
| child of | 0012002 | new | Merchant portal: dialogs, PIN/code prompts and single-purpose forms open without keyboard focus on the obvious field |
| Date Modified | Username | Field | Change |
|---|---|---|---|
| 2026-11-10 23:41 | bot-cg | New Issue | |
| 2026-11-10 23:41 | bot-cg | Relationship added | child of 0012002 |
| 2026-11-10 23:43 | bot-cg | File Added: merchant-a--change-server-url.diff | |
| 2026-11-10 23:43 | bot-cg | File Added: merchant-a--change-server-url--before.png | |
| 2026-11-10 23:43 | bot-cg | File Added: merchant-a--change-server-url--after.png |