Closed anizovtsev closed 3 years ago
Hey, This PR reminded me that we experimented with this on the internal version of the picker in Duet's design system.
However, we decided it felt a little weird/confusing that there weren't consistently 12 options in the month dropdown. So we went with an alternative approach of disabling any <option>
that would fall outside min/max. Like this:
So I won't be merging this, as I will be porting over the above changes. But thanks anyway, appreciate you taking the time. Sorry to be slow!
PR for the behaviour above: #82
My version of this fix was released in v1.4.0
@anizovtsev
Hello,
I would like to thank you for the component one time more. It's pleasure to customize it. Unfortunately, I have to create something that looks like a calendar for selecting a date in the range of several months. But this small improvement could be interesting for you as well. I noticed that when you set min or max parameter (or both), the month drop down still contains all 12 months. Even thought it's not possible to select one due to min/max property. It can confuse some users (actually this is the only one reason why I had to dig into it). This small fix exclude the items that can't be selected.