Skip to content
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: fix Material combo box overlay sizing #8619

Merged
merged 1 commit into from
Feb 3, 2025

Conversation

sissbruecker
Copy link
Contributor

Description

The Material theme for combo box uses overflow: visible on the overlay part to allow showing the loading indicator, which is positioned upwards to cover the field's bottom border (added in vaadin/vaadin-combo-box#743). However this causes the overlay sizing logic to break, which apparently needs overflow: auto.

This fixes the styles to only apply overflow: visible when the combo box is actually loading. That should be fine as the combo box is empty in that state and the overlay sizing logic is not (as) relevant.

Before:

before.mov

After:

after.mov

Fixes vaadin/flow-components#7063

Type of change

  • Bugfix

@sissbruecker
Copy link
Contributor Author

Now sure if / how to add tests for this. Unit tests usually use Lumo styles, visual tests can't cover the loading animation. I figure it's not very relevant either with Material being deprecated.

@sissbruecker sissbruecker force-pushed the fix/material-combo-box-overlay-sizing branch from b36ca56 to 8a7bdce Compare February 3, 2025 11:29
@sissbruecker sissbruecker force-pushed the fix/material-combo-box-overlay-sizing branch from 8a7bdce to 65501cf Compare February 3, 2025 14:22
Copy link

sonarqubecloud bot commented Feb 3, 2025

@sissbruecker sissbruecker merged commit cc9555a into main Feb 3, 2025
9 checks passed
@sissbruecker sissbruecker deleted the fix/material-combo-box-overlay-sizing branch February 3, 2025 14:29
sissbruecker added a commit that referenced this pull request Feb 3, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

ComboBox with Material design has viewport overflow
3 participants