-
Notifications
You must be signed in to change notification settings - Fork 83
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
fix: update selected item styles to not limit height #3548
Conversation
Kudos, SonarCloud Quality Gate passed! 0 Bugs No Coverage information |
@@ -23,7 +24,7 @@ registerStyles( | |||
|
|||
/* placeholder styles */ | |||
::slotted(:not([slot]):not([selected])) { | |||
line-height: normal; | |||
line-height: 1; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
For some reason, using normal
on Windows causes the input container height to increase by 1 pixel.
This change caused the placeholder screenshot to be updated for Lumo.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Are font descenders still visible with this change, for example, j
and g
?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can confirm that this works, single-line and multiline.
@@ -54,8 +55,8 @@ registerStyles( | |||
'vaadin-select-value-button', | |||
css` | |||
:host { | |||
min-height: var(--lumo-size-m); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This rule seems to be overridden by the vaadin-input-container
styles.
min-height: var(--lumo-button-size); | ||
padding-top: var(--_lumo-selected-item-padding); | ||
padding-bottom: var(--_lumo-selected-item-padding); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Aligned with the styles used by Vaadin 21:
:host([theme~='small']) [selected] { | |
padding: 0; | |
min-height: var(--lumo-size-s); | |
} |
* fix: reset height to make custom items fit * fix: set correct slotted item height
This ticket/PR has been released with Vaadin 23.1.0.alpha1 and is also targeting the upcoming stable 23.1.0 version. |
Description
Added styles to remove fixed height inherited from
vaadin-button
to display custom item properly.Note, this only works in Lumo: multi-line items are not working using the Material theme for V14.
Fixes #3546
Type of change