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

Date Picker Pager: Option to stay compact #16

Open
StefanOltmann opened this issue Jan 9, 2024 · 2 comments
Open

Date Picker Pager: Option to stay compact #16

StefanOltmann opened this issue Jan 9, 2024 · 2 comments
Labels

Comments

@StefanOltmann
Copy link

StefanOltmann commented Jan 9, 2024

I think it's great that you made the picker filling the max width. This may be truly what in most of the cases is the expected behavior.

In my case I would like to have either an option to stay in the fixed size width to have it centered or to introduce a width constant I could use to constrain it's size with an outer box.

At this time I need to do the math myself to see what width it needs.
That's not too hard, but for convenience I think you should offer that option.

Currently the "natural" width is 7x42+8x2 dp.

grafik
@alexzhirkevich
Copy link
Owner

It fills width because it uses lazy row under the hood.

This will happen otherwise:
image

@StefanOltmann
Copy link
Author

Okay, I understand.

So my suggestion is to have optionally a Box around it that constraints the width to 310.dp - the natural width the component has with no additional paddings.

Or put the 310.dp as an public constant somewhere.

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

No branches or pull requests

2 participants