8000 Header destinations and the Callout's verdicts by kiran-brahma · Pull Request #82 · kiran-brahma/writing-tool · GitHub
[go: up one dir, main page]

Skip to content

Header destinations and the Callout's verdicts - #82

Merged
kiran-brahma merged 1 commit into
v1.3from
v1.3-68
Sep 26, 2026
Merged

kiran-brahma merged 1 commit into
v1.3from
v1.3-68

Conversation

@kiran-brahma
Copy link
Copy Markdown
Owner

Part of #57. Closes #68.

What changed

  • Header (stories 244–247). The header still has its three zones (brand, document actions, navigation). Editor and Library are the tabs: text-sm, with the current one filled in ink. The Pass workbench and AI Settings come next as quieter text-xs links, and the current one is underlined. How this works and Privacy sit under one Help control (src/HelpMenu.tsx). It works as a disclosure: Enter or Space opens it, its two destinations come next in the tab order, and Escape closes it and returns focus to the button. A press outside, focus leaving it, or any change of destination (including ?) also closes it. The control reads as current while How this works or Privacy is open.
  • Navigation model. src/navigation.ts gives each destination a placement (tab / link / help), plus three pure functions: destinationsAt, isHelpCurrent, and clicksBetween(from, to) for story 247. They are tested in src/navigation.test.ts, including a test that every pair of destinations is at most two clicks apart.
  • The Document menu is no longer clipped. The header had overflow-x-auto, which clipped the Document menu at 1440px. It now wraps (flex-wrap) instead of scrolling sideways, so neither the Document menu nor the Help list is clipped. The divider after Document is hidden below sm, where the header wraps.
  • Callout (stories 248–250). Addressed is a filled ink button with focus-visible:ring-offset-2. Decline is an outlined button, and Decline as violation is an underlined text link. It still appears only when the Finding carries a violation. The Callout has no key hints. It had none before this PR, and a comment now records why (ADR 0011).

No colour tokens were added and src/index.css is untouched. No Dexie migration, the findings schema is unchanged, no affordance inserts model-derived text, and there is no DOM test layer. The title field, toolbar and Status line are untouched.

Acceptance criteria

  • Editor and Library read as the primary destinations; the other four are reachable in one or two clicks from anywhere. Verified in headless Chromium in both schemes. The script clicked through all 30 ordered pairs of destinations and checked where each one landed. The most any pair took was 2 clicks, and only How this works and Privacy take 2. The same rule is unit-tested with clicksBetween.
  • The help control opens with keyboard and closes on Escape, returning focus. Verified in headless Chromium in both schemes. Tab reached the control, Enter and Space each opened it, and Tab moved to "How this works". Escape then closed it with focus back on the Help button. Choosing Privacy with the keyboard went to Privacy.
  • ? still opens the shortcuts. Verified in headless Chromium in both schemes. Pressing ? from the Library opened How this works with the Shortcuts heading in view, and the Help control read as current.
  • The Callout's three verdicts are visibly ranked; no key hints appear in it. Verified in headless Chromium in both schemes. The rule-pass Findings had no violations, so I added a model Finding with a praise violation to the local IndexedDB for this check. That made all three verdicts appear. They show as filled, outlined and text link, and the Callout's text has no key hints. I also checked the focus ring on the filled Addressed button.
  • Checked by eye in both schemes. I looked at screenshots in light and dark at 1440, 1024 and 375px: the header, the open Help list, the open Document menu, the header on the Library and AI Settings, and the Callout. The page had no horizontal scroll at any of those widths. At 375px the header wraps to two rows. These were headless screenshots, not a physical tablet.

pnpm test (79 files, 1073 tests), pnpm typecheck, pnpm run gates and pnpm build all pass.

🤖 Generated with Claude Code


Generated by Claude Code

Editor and Library are the header's tabs; the Pass workbench and AI
Settings follow as quieter links; How this works and Privacy sit under one
help control that opens from the keyboard and closes on Escape, returning
focus. Every destination is at most two clicks from every other, tested as
a rule on the destination model. The header wraps instead of scrolling
sideways, so it no longer clips the Document menu.

In the Callout, Addressed is a filled button, Decline an outlined one and
Decline as violation a text link. It carries no key hints (ADR 0011).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01FjB3Gu8vhg5enkAneTdqga
@chatgpt-codex-connector
chatgpt-codex-connector Bot commented Sep 26, 2026 •
Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
🔒 Security Review ✅ Completed 2026-09-26T10:23:34.368818Z 29e065f PR opened
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants

0