You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Feb 18, 2022. It is now read-only.
Copy file name to clipboardExpand all lines: README.md
+8-10Lines changed: 8 additions & 10 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -82,21 +82,24 @@ date-min-limit="" | String | false | Set a minimum date limit - you can use all
82
82
date-max-limit="" | String | false | Set a maximum date limit - you can use all the accepted date formats by the javascript `new Date()`
83
83
date-set-hidden="" | String(Boolean) | false | Set the default date to be shown only in calendar and not in the input field
84
84
date-disabled-dates="" | String([Date(), Date(), ...]) | false | Disable specific dates using an _Array_ of dates
85
+
date-refocus="" | String(Boolean) | false | Set the datepicker to re-focus the input after selecting a date
85
86
86
87
##Options
87
88
Angular datepicker allows you to use some options via `attribute` data
88
89
89
-
90
90
####Custom titles
91
+
91
92
You can set the titles for the month and year selectors with the **date-year-title=""** and **date-month-title=""** data attributes (default to is _"select month"_ and _"select year"_)
92
93
94
+
```html
93
95
<datepickerdate-month-title="selected year">
94
96
<inputng-model="date"/>
95
97
</datepicker>
96
98
97
99
<datepickerdate-year-title="selected title">
98
100
<inputng-model="date"/>
99
101
</datepicker>
102
+
```
100
103
101
104
####Custom buttons
102
105
You can customize the calendar navigation buttons content, let's make an example while using [FontAwesome](http://fontawesome.io)
@@ -106,15 +109,19 @@ You can customize the calendar navigation buttons content, let's make an example
106
109
<inputng-model="date"type="text"/>
107
110
</datepicker>
108
111
```
112
+
109
113
####Custom buttons titles for arrows
110
114
You can also set the titles for the left and right arrows with **button-next-title=""** for the right and **button-prev-title=""** for the left. By default they are labeled _"next"_ and _"prev"_.
115
+
116
+
```html
111
117
<datepickerbutton-prev-title="previous month">
112
118
<inputng-model="date"/>
113
119
</datepicker>
114
120
115
121
<datepickerbutton-next-title="next month">
116
122
<inputng-model="date"type="text"/>
117
123
</datepicker>
124
+
```
118
125
119
126
####Input as grandchild
120
127
Sometimes you cannot put date input as a first child of datepicker. In this case you may use `selector=""` to point to the CSS class of the input. Below example with using Twitter Bootstrap and FontAwesome
@@ -137,15 +144,6 @@ You have an option to make the datepicker visible when it loads with `visible-on
137
144
</datepicker>
138
145
```
139
146
140
-
####Re-focus input after selecting date
141
-
Re-focus input after selecting a date with `date-refocus` attribute.
0 commit comments