-
Notifications
You must be signed in to change notification settings - Fork 0
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
Controls order and HTML structure #2
Comments
This is a good point, and +1 for using a flex container to group all "top controls." Aside from reversing, this would also allow users to specify arbitrary positions via |
Ya, i was checking the code out again, and I think each of the controls, when separated probably becomes a css part/css vars also, so that you can individually style all the controls however you want? |
I think this is a great idea! I like the flexibility this would provide. |
It looks like there may be some accessibility issues with rearranging the order with flex. |
From https://developer.mozilla.org/en-US/docs/Web/CSS/order
Does the visual order matter for these options? For example, if you’re tabbing through the control and can reach every one of them, does it matter which one is first or last? |
It may be a bit disorienting, but might not be the end of the world. |
i doubt the order truly matters. and also, my reason for splitting these controls up is to change the default order of the controls to: prev month, month select, year select, next month. i’m fairly confident that with that as the default order of the controls, there will be very little reason to change the order with flex ordering. imo that default order makes a ton of sense. |
I was planning on refactoring the controls to be similar to the design above. This original design was based on Chome's date picker implementation. |
hey hey, bumping this (and the other) thread! Would you be open to accepting PRs for these features/redesigns? |
Yes, please! Sorry for the delay. Life has been crazy busy. |
Love the alpha release!
I was taking a look at the docs page and poking around to see if I can use this component to create my datepicker that i'll need pretty soon, and I found something I'd like to ask about.
Currently the controls at the top are hardcoded into
left
andright
with the month & year select being left, and the next/prev month beingright
.As currently coded if I wanted to make a picker like:
I wouldnt really be able to, even with the css parts, because each of the controls elements isnt its own container inside the flexbox container of
top-controls
. I could reverse the order visually to put the arrows on the left and the month/year select on the right, but I cant put the selects in the middle of the arrows.Would you be open to a PR that changes that internal style so that all the children of
top-controls
are separate (removing the stylistic concept ofright
andleft
controls)? Additionally, could we potentially order the controls like my desired screenshot above by default (prev arrow, month select, year select, next arrow)? I think that would definitely help the configurability of this component because I think that a lot of folks will end up styling the calendar like my screenshot above, so having the default arrangement of those elements would save lots of styling on the consumer's side.Thoughts?
The text was updated successfully, but these errors were encountered: