Reputation: 232
In angular material date picker we can set min date, max date and some other features.
<md-datepicker flex ng-model="birth_date" md-placeholder="Enter birthdate" md-min-date="minbirthdate"></md-datepicker>
But we have to choose particular month or year by scrolling and crossing all the dates, months and years in between. It takes lots of time to choose particular date. Is there any way to choose direct month or year?
Upvotes: 0
Views: 1238
Reputation: 222522
With the latest version,You can set md-mode="month"
working demo below
<md-input-container flex="100" layout="column">
<div style="font-size: 10px; color: blue;" label ng-bind="::dateFields[2].label"></div>
<md-datepicker ng-model="dateFields.selectedDate"
ng-required="dateFields.required"
md-date-locale="dateFields.locale"
md-mode="month"
md-open-on-focus="true">
</md-datepicker>
</md-input-container>
Upvotes: 2