Skip to content

feat(specimens): link the repository from the site header - #12

Merged
BunsDev merged 1 commit into
mainfrom
cody/spell-library-v2
Sep 28, 2026
Merged

BunsDev merged 1 commit into
mainfrom
cody/spell-library-v2

Conversation

@BunsDev

@BunsDev BunsDev commented Sep 28, 2026

Copy link
Copy Markdown
Member

Summary

This adds a GitHub link to the site header, next to search and the scheme toggle, where spell-ui puts it.

A side-by-side comparison with spell-ui found that main already delivers its docs layout:

The header's missing repository link was the only gap the reviews allowed us to close. spell-ui's marketing homepage stays out of scope because it would displace the catalog at /.

Change

  • A plain <a> styled with the exported buttonVariants({ variant: "ghost" }). It is an anchor rather than a Base UI Button with render, which would add role="button" and announce the link as a button.
  • href="https://github.com/OpenCoven/ui" (the existing repository constant), target="_blank", rel="noopener noreferrer", aria-label="OpenCoven UI on GitHub".
  • A new .repository-control class shares the scheme toggle's sizing: 36px on desktop, 44px under 68rem and on coarse pointers. It keeps its own class name so review scripts that target .scheme-control still find the theme toggle.
  • lucide-react 1.x ships no brand marks, so the GitHub mark is an inline currentColor SVG marked aria-hidden.

Verification

  • pnpm format:check && pnpm lint && pnpm typecheck && pnpm test all pass (54/54 tests).

  • scripts/visual-review.mjs against vite preview: 25/25 scenarios passing.

  • scripts/mobile-quality-review.mjs: 9/9 passing, with documentOverflow 0 in every scenario, including 320px, 320px at 200% text, and 390px RTL.

  • A direct probe of the new link:

    Viewport Size Overlaps toggle Document overflow Role
    320 44×44 no 0 link
    390 44×44 no 0 link
    1440 36×36 no none link

No review check was edited or skipped.

🤖 Generated with Claude Code

Add a GitHub link next to search and the scheme toggle, matching
spell-ui's header. It is a plain anchor styled with buttonVariants so it
stays a link to assistive tech, opens in a new tab with
rel="noopener noreferrer", and shares the scheme control's sizing: 36px
on desktop, 44px under 68rem and on coarse pointers.

lucide-react 1.x ships no brand marks, so the GitHub mark is inlined.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@vercel

vercel Bot commented Sep 28, 2026 •

Copy link
Copy Markdown
Contributor

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated
opencoven-ui Ready Ready Preview Sep 28, 2026 5:51am UTC
ui Ready Ready Preview Sep 28, 2026 5:51am UTC

Request Review

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot review overview

🟢 Approval recommended

The only noted issue is a non-blocking test-coverage nit.

Review effort: Lite
Findings: 1 Low severity

Open (1)
What changed in this PR

Adds an accessible GitHub repository link beside the search and theme controls in the specimens site header.

Changes:

  • Adds an external GitHub anchor with secure new-tab handling.
  • Adds an inline GitHub icon and accessible label.
  • Styles the repository control responsively.
File Description
apps/​specimens/​src/​specimens.css Styles the repository control across breakpoints.
apps/​specimens/​src/​app.tsx Adds the GitHub repository link and icon.

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

Comment on lines +816 to +828
<a
href={repository}
target="_blank"
rel="noopener noreferrer"
className={cn(
buttonVariants({ variant: "ghost" }),
"repository-control",
)}
aria-label="OpenCoven UI on GitHub"
title="OpenCoven UI on GitHub"
>
<GitHubMark />
</a>
@BunsDev
BunsDev merged commit 141a407 into main Sep 28, 2026
5 checks passed

This branch was successfully deployed

2 active deployments
Preview – ui — dce4fabb Deployed Sep 28, 2026 by vercel[bot]
Preview – opencoven-ui — dce4fabb Deployed Sep 28, 2026 by vercel[bot]
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