File tree Expand file tree Collapse file tree 2 files changed +19
-0
lines changed
docs/src/app/components/pages/components Expand file tree Collapse file tree 2 files changed +19
-0
lines changed Original file line number Diff line number Diff line change @@ -63,6 +63,18 @@ let TimePickerPage = React.createClass({
63
63
header : 'TimePicker.formatTime(time)' ,
64
64
desc : 'Formats the Date object to a current component\'s time format.' ,
65
65
} ,
66
+ {
67
+ name : 'openDialog' ,
68
+ header : 'TimePicker.openDialog()' ,
69
+ desc : 'Opens the time-picker dialog programmatically. Use this if you want to open the ' +
70
+ 'dialog in response to some event other than focus/tap on the input field, such as an ' +
71
+ 'external button click.' ,
72
+ } ,
73
+ {
74
+ name : 'focus' ,
75
+ header : 'TimePicker.focus()' ,
76
+ desc : 'An alias for the `openDialog()` method to allow more generic use alongside `TextField`.' ,
77
+ } ,
66
78
] ,
67
79
} ,
68
80
{
Original file line number Diff line number Diff line change @@ -120,6 +120,13 @@ const TimePicker = React.createClass({
120
120
this . refs . input . setValue ( this . formatTime ( t ) ) ;
121
121
} ,
122
122
123
+ /**
124
+ * Alias for `openDialog()` for an api consistent with TextField.
125
+ */
126
+ focus ( ) {
127
+ this . openDialog ( ) ;
128
+ } ,
129
+
123
130
openDialog ( ) {
124
131
this . setState ( {
125
132
dialogTime : this . getTime ( ) ,
You can’t perform that action at this time.
0 commit comments