Skip to content

Year drop down using <select> #462

@iknowcss

Description

@iknowcss

I'd really love to have an option to show the year drop down as a traditional <select> instead of the control that is there now. I'm willing to implement and create a pull request. I wanted to check first with the author and collaborators.

  • Is this an acceptable feature?
  • If so, what would you like the API to be?

The one situation that I don't know how to handle is the one where there is not a limit on both the upper and lower bounds of the date picker year. How would the group like to handle this?

Just taking a stab in the dark here at an api:

<DatePicker
    selected={this.state.startDate}
    onChange={this.handleChange} 
    showYearDropdown 
    yearDropdownType="select"
    dateFormatCalendar="MMMM" />

yearDropdownType options would be select and scroll, default to scroll.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions