Simple jquery based year picker which helps to:
1) Set an year as default during load(Mandatory parameter)
2) Set the start year from which year selection has to be enabled(Non mandatory parameter- if not passed, enables all years)
3) Set the end year after which year selection has to disabled(Non mandatory parameter- if not passed, enables all years)
4) Pass the style class that needs to be applied on the selected/disabled date(s)(Non mandatory parameter- if not passed, applies the default style).
5) Returns the selected year. Need to define a handler which sets the year passed by the year picker on change event to the local screen variable.
A example of scenarios where this component can be used:
Travel app: User can set the year. When the user revisits the page, he is provided with the ability to edit already saved details. The existing(saved) year need to be fetched and shown along with the ability to edit it. This year picker enables to achieve this.
Made the web block as public