reexamine_keyboard

A set of rules for making an interface usable with a keyboard. It covers skip links, shortcuts, focus movement, tab order, and keeping keyboard users inside open dialogs until they close them.

In plain words
What is it for?
Use it when building or reviewing websites and web applications. It helps check keyboard shortcuts, modals, menus, focus targets, tab order, and accessible navigation.
Why use it?
It prevents keyboard users from getting lost, trapped, or forced to navigate through irrelevant content. It also keeps focus in a predictable order.

Cursor rule for Cursor

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add rules/homenshum/nodebenchai/reexamine_keyboard
Clone the repo
git clone --depth 1 https://github.com/HomenShum/NodeBenchAI

Made for: Cursor.

Per session 0 Nothing until a file matches its globs; then the whole rule loads.
When invoked 411 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5 $0.00000 $0.00411
Opus 5 $0.00000 $0.00205
Sonnet 5 $0.00000 $0.00082
Haiku 4.5 $0.00000 $0.00041

Measured 2d ago against content hash 593d214d52b4, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

reexamine_keyboard scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 2d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

.cursor/rules/reexamine_keyboard.mdc · 37 lines

What it actually says

Re-examine: Keyboard Efficiency

  • First focusable element on page: <a href="#main-content" class="sr-only focus:not-sr-only">Skip to main content</a>
  • Multiple skip links for complex layouts: "Skip to search", "Skip to results"
  • Target element needs tabindex="-1" if it's not natively focusable

Keyboard shortcuts

  • Search: Ctrl+K or / to focus search input
  • Escape: close modals, dropdowns, lightboxes, cancel operations
  • Arrow keys: navigate within lists, carousels, tab bars
  • Enter/Space: activate buttons and interactive cards
  • Document shortcuts in a help overlay (accessible via ? key)

Tab order

  • Logical reading order: left-to-right, top-to-bottom (matches visual layout)
  • Never use tabindex > 0 — it breaks natural flow
  • tabindex="0" only on custom interactive elements that need to be in tab order
  • tabindex="-1" for programmatically focusable elements (skip link targets, error summaries)

Focus traps

  • Modals/dialogs: Tab wraps within the dialog (last → first → last)
  • Escape key always closes the trap
  • On close, return focus to the element that opened the modal
  • aria-modal="true" + role="dialog" on the container

Cards and list items

  • If a card is clickable, the entire card should be a <button> or contain a primary <a>
  • Enter and Space should both trigger the card action
  • Keyboard hint on hover: consider showing "(Enter to open)" for non-obvious interactive elements
Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 2d ago First seen · 37 lines · 411 tokens per session scan A 593d214d52b4

Subscribe to this mod's changes

reexamine_keyboard is a cursor rule published in the GitHub repository HomenShum/NodeBenchAI (14 stars, last pushed 19d ago), licensed MIT. It costs nothing until one of its globs matches a file; then it loads 411 tokens. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.