Repository navigation
Buttons: Size Forgejo's native form buttons from one list - #90
Merged
Merged
Conversation
The review panel, the diff comment forms, the new issue page and the release form each repeated the same six declarations to bring Forgejo's own buttons to the 32px control size, because those buttons cannot take the theme-control class. The button component now carries one rule for a list of native buttons; the three copies are removed. No visual change. 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.
Stacked on #89 (base is its branch).
What
theme-controlgives a button GitHub's 32px control size, but only where the template can add the class. Forgejo's own form buttons can't take it, so three places repeated the same six declarations (heightandmin-height32px,padding: 5px 12px, 14px / 500 / 20px):styles/components/issues/pull_files_review.ts(reviewButtonfragment: review panel, diff comment form, conversation button row)styles/components/issues/issue_new.ts(new issue submit button)styles/pages/releases.css(release form buttons)components/common/button/button.cssnow has one "native controls" rule with those buttons listed, and the copies are gone. Sizing another native button means adding its selector to the list.Left alone: the merge box buttons, which use a different rule (vertical padding only, because the button group manages horizontal padding).
Verification
The before/after comparison is identical on the new release form, new issue page, an issue page and three pull request pages. The on-demand buttons were measured after the change: review panel and conversation row buttons are 32px high,
5px 12px, 14px / 500, with their margins unchanged.bun vitest(403 passed),bun checkand Prettier pass.🤖 Generated with Claude Code