Open teklakct opened 1 month ago
When the "default" font size (16px) is used, then the EasyAdmin standard button is the same as the bootstrap small button.
// In EasyAdmin
.btn {
--bs-btn-padding-x: 8px;
--bs-btn-padding-y: 4px;
--bs-btn-font-size: 0.875rem;
}
// From boostrap
.btn-group-sm > .btn, .btn-sm {
--bs-btn-padding-x: 0.5rem; // 8px
--bs-btn-padding-y: 0.25rem; // 4px
--bs-btn-font-size: 0.875rem; // 14px
}
Perhaps marking the buttons as btn-sm
and not overriding the CSS variables is an option?
Does anyone else experience this or is it some kind of defect in my setup? I can prepare a PR with those changes but for sure I need some help to test it and avoid breaking the whole theme.
Describe the bug Seems like theme variables for buttons are overriding bootstrap variables and there is no way to use different button sizes.
How it looks like:
When variables for
.btn
are removed from the variables-theme.cssthen it looks like below
The default bootstrap button is slightly bigger than those EasyAdmin one.
To Reproduce I am currently using v4.13
Use this html in any template that extends easyadmin layout.
(OPTIONAL) Additional context The import order seems to be an issue. Boostrap variables are loaded in the first line of app.css then some of them are overridden by theme variables at line 7 of app.css
Something like that is helping:
but I am not sure how it will impact the whole theme. For sure the action buttons are noticeably bigger
--
🤔 Maybe switching from SASS to CSS might be an issue here https://github.com/EasyCorp/EasyAdminBundle/pull/6139