Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

UI - Fixed font size of buttons #1291

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
WebVPF wants to merge 1 commit into wintercms:develop
base: develop
Choose a base branch
Loading
from WebVPF:patch-2
Open

Conversation

@WebVPF
Copy link
Contributor

@WebVPF WebVPF commented Jan 21, 2025

This property (which has been removed) overrides the font size for all buttons. This causes the font to display incorrectly for buttons of different sizes: https://wintercms.com/docs/v1.2/ui/controls/button#sizes

Screenshot before:
btn-before

Screenshot after:
btn-after


Initially, the font-size property is already defined here:

.button-size(@padding-base-vertical; @padding-base-horizontal; @font-size-base; @line-height-base; @border-radius-base);

If we want the default font size to be 13px (as overridden in the property I removed), then perhaps we should change the @font-size-base parameter to @font-size-base - 1

Correct to:

.button-size(@padding-base-vertical; @padding-base-horizontal; @font-size-base - 1; @line-height-base; @border-radius-base);

I don't remember if it is possible to pass a calculated expression in parameters for LESS

Mixin:


Class sizes are listed here

// Button Sizes
// --------------------------------------------------
.btn-lg {
// line-height: ensure even-numbered height of button next to large input
.button-size(@padding-large-vertical; @padding-large-horizontal; @font-size-large; @line-height-large; @border-radius-large);
}
.btn-sm {
// line-height: ensure proper height of button next to small input
.button-size(@padding-small-vertical; @padding-small-horizontal; @font-size-small; @line-height-small; @border-radius-small);
}
.btn-xs {
.button-size(@padding-xs-vertical; @padding-xs-horizontal; @font-size-small; @line-height-small; @border-radius-small);
}

I don't have the technical ability to recompile styles from LESS.

jaxwilko reacted with thumbs up emoji
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Reviewers

No reviews

Assignees

No one assigned

Labels

None yet

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

1 participant

AltStyle によって変換されたページ (->オリジナル) /