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

md-outlined-select options list height: 100% #4291

Closed
gdevacc12 opened this issue May 15, 2023 · 4 comments · Fixed by #4532 or #4539
Closed

md-outlined-select options list height: 100% #4291

gdevacc12 opened this issue May 15, 2023 · 4 comments · Fixed by #4532 or #4539

Comments

@gdevacc12
Copy link

Problem

When the list of options is longer than the height of the browser window, it is difficult to scroll through the options list to select the desired option, as the option list height is 100%.

Expected behaviour

To have the option list with a scroll bar and to be able to set the max-height of the list.

Comments

Apologies if this my ignorance on styling the component. Please advise if I missed something.

@asyncLiz
Copy link
Collaborator

Can you provide a lit.dev/playground or screenshots of the issue?

@gdevacc12
Copy link
Author

gdevacc12 commented May 16, 2023

@asyncLiz attached image.
image

@e111077
Copy link
Contributor

e111077 commented Jul 7, 2023

md menu can have max-height set on it, but unfortunately it's in the shadow root of md-select, so it's not settable. Will investigate adding a css custom property

copybara-service bot pushed a commit that referenced this issue Jul 7, 2023
copybara-service bot pushed a commit that referenced this issue Jul 7, 2023
copybara-service bot pushed a commit that referenced this issue Jul 7, 2023
copybara-service bot pushed a commit that referenced this issue Jul 11, 2023
copybara-service bot pushed a commit that referenced this issue Jul 11, 2023
copybara-service bot pushed a commit that referenced this issue Jul 12, 2023
copybara-service bot pushed a commit that referenced this issue Jul 12, 2023
@e111077
Copy link
Contributor

e111077 commented Jul 12, 2023

max-height can now be set via CSS Shadow Part. e.g.

md-outlined-select::part(menu) {
  max-height: 123px;
}

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
3 participants