Skip to content

fix(webui): translate the drag overlay and policy toast - #7952

Merged
kovtcharov-amd merged 5 commits into
amd:mainfrom
tylerbea:fix/hunt-ATT5-arabic-drag-overlay
Nov 13, 2026
Merged

kovtcharov-amd merged 5 commits into
amd:mainfrom
tylerbea:fix/hunt-ATT5-arabic-drag-overlay

Conversation

@tylerbea

@tylerbea tylerbea commented Nov 13, 2026 •

Copy link
Copy Markdown
Contributor

In Arabic, dragging a file over a chat showed "Drop files to index them for this chat" in English only, with no Arabic and no gloss. The drop message, the scroll-to-bottom button and the policy-blocked toast (including its View receipt link) now read in Arabic with the usual English gloss.

Closes #7953

Before After

Test plan

  • npm test on the ChatView and i18n files passes, including a new Arabic case for the toast and drag overlay in ChatView.policyAlert.test.tsx
  • npm run build passes
  • Arabic, open chat, file dragged over it: overlay reads in Arabic (shots)
  • Reviewer: drag a file over a chat in English; text is unchanged. Not exercised by hand: the scroll button and the blocked-tool toast (covered by the unit test only)
🔍 Technical details
  • ChatView.tsx had these strings as JSX literals outside useT; new keys chat.dropOverlay, chat.scrollBottom, chat.policyBlocked, chat.policyViewReceipt in en.ts and ar.ts; "Receipt unavailable" reuses activity.policy.receiptUnavailable.
  • hardcodedText.baseline.json lowered for ChatView.tsx.

In Arabic, dragging a file over a chat showed an English-only drop message, and the scroll-to-bottom button and policy-blocked toast were English too. They now read in Arabic with the English gloss.
@github-actions

Copy link
Copy Markdown
Contributor

Verdict: Approve

Moves the last hard-coded English strings in the chat view (the drag-and-drop overlay, the scroll-to-bottom button, and the policy-blocked toast with its receipt link) through the translation layer, with Arabic text for each. The strings are unchanged in English and the change is small and well covered; nothing blocks merge.

Real-world evidence

No evidence bundle was produced for this run. The PR description embeds before/after screenshots of the Arabic drag overlay. The scroll button and blocked-tool toast are covered by the new Arabic unit test only, as the author notes. Apart from those screenshots, the verdict rests on static review.

🔍 Technical details

Issues found: none blocking.

Checked

  • Every new key (chat.dropOverlay, chat.scrollBottom, chat.policyBlocked, chat.policyViewReceipt) is in both en.ts and ar.ts. The English values match the old literals byte for byte, so ChatView.autoScroll.test.tsx:338 (name: 'Scroll to bottom') and the existing 'Receipt unavailable' assertions still hold.
  • activity.policy.receiptUnavailable already exists in both locales (en.ts:593, ar.ts:593), so reusing it is correct.
  • hardcodedText.baseline.json 14 → 7 is enforced exactly by hardcodedText.test.ts:149-152, which fails if the count shrinks without lowering the baseline. A wrong number would fail CI.
  • No docs describe these strings, so there is nothing to update.

Strengths

  • The new Arabic test switches locale mid-session and checks both the toast and the overlay, which is the real user path rather than a mount-in-Arabic shortcut.
  • Reusing the existing receipt-unavailable key avoids a duplicate translation.

@kovtcharov-amd kovtcharov-amd added bug Something isn't working agent-ui Agent UI changes multilingual Language support: translations, right-to-left layout, Arabic and other non-English languages labels Nov 13, 2026
@github-actions github-actions Bot added the tests Test changes label Nov 13, 2026
@kovtcharov-amd
kovtcharov-amd added this pull request to the merge queue Nov 13, 2026
Merged via the queue into amd:main with commit 46b823b Nov 13, 2026
60 of 61 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

agent-ui Agent UI changes bug Something isn't working multilingual Language support: translations, right-to-left layout, Arabic and other non-English languages tests Test changes

Projects

None yet

Development

Successfully merging this pull request may close these issues.

In Arabic, dragging a file over a chat shows the drop message only in English

2 participants