Repository navigation
Repository: Matched GitHub's header, tab counters and repository buttons - #97
Merged
Merged
Conversation
Measured against github.com (signed in) at 1280, 1011, 900, 768, 600 and 400px. These parts are shared by every repository page, and the changes go through the theme's shared components instead of page-specific copies: - Global header: one transparent, outlined menu button before the logo opens the existing navigation drawer on every width; the logo is a bare 32px mark and is dropped below 600px; the repository breadcrumb shows a repository icon instead of the owner avatar and folds the owner into a "…" menu on narrow screens. A transparent 197px search field (the shared search component, with a new monospace shortcut hint) searches repositories from 1012px, "/" focuses it, and a search button from the shared header icons replaces it below 1012px. On mobile the header keeps only search and the inbox; the drawer holds the dashboard links. - Tabs: repository, organisation and profile tabs use the counter's tab variant (18px, semibold), 8px after the label; tab icons drop on mobile and the tabs keep a 16px gutter. - Watch, Fork and Star are single small controls with the count inside; Fork gets a split menu with forks and "Fork repository" through the shared dropdown, which gains a small size and a square icon-only trigger. The feed button is gone, as on GitHub. - Buttons: the shared control gets GitHub's 4px gap and muted icons at the small size, and sizes the branch selector and Add file buttons (14px, weight 500, 16px carets). - The Code page uses GitHub's gutter: 16px, and 32px from 1012px. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What changes
The parts every repository page shares now match GitHub, signed in, measured at 1280, 1100, 1011, 900, 768, 600 and 400px. Each change goes through the theme's shared components, so organisation and profile pages pick them up too.
/hintNarrower screens
GitHub hides tab icons once the tabs run out of room; Forgejo has more tabs, so this uses the mobile breakpoint instead of measuring.
Components touched:
components/common/button: small size uses GitHub's 4px gap; default buttons draw muted icons; a split control joins an action and its menu; an icon-only small menu trigger is a 28px square; Forgejo's native branch selector and Add file buttons are sized here.components/common/dropdown: aSmalloption for the 28px trigger.components/common/search: aShortcutoption shows a key hint and focuses the field from anywhere.base/head_navbar_icons: the collapsed search button, shared by the desktop and mobile header.Not matched: GitHub's repository switcher arrow, Copilot, and the avatar on the mobile header (Forgejo keeps the account in the drawer). The search searches repositories with Forgejo's translated "Search repos…" placeholder instead of opening GitHub's command palette. The page gutter breakpoint is fixed on the Code page; other repository pages still switch at 768px in their own container rules.
Before and after
Dark mode, in the dev preview. Each pair is before (top) and after (bottom).
Checks
bun vitest: 406 tests pass (the drawer, header geometry and phone breakpoint tests are updated);tsc -band Prettier pass.bun lintcould not run locally: the installed typescript-eslint does not support TypeScript 7.🤖 Generated with Claude Code