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({
6363 header : 'TimePicker.formatTime(time)' ,
6464 desc : 'Formats the Date object to a current component\'s time format.' ,
6565 } ,
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+ } ,
6678 ] ,
6779 } ,
6880 {
Original file line number Diff line number Diff line change @@ -120,6 +120,13 @@ const TimePicker = React.createClass({
120120 this . refs . input . setValue ( this . formatTime ( t ) ) ;
121121 } ,
122122
123+ /**
124+ * Alias for `openDialog()` for an api consistent with TextField.
125+ */
126+ focus ( ) {
127+ this . openDialog ( ) ;
128+ } ,
129+
123130 openDialog ( ) {
124131 this . setState ( {
125132 dialogTime : this . getTime ( ) ,
You can’t perform that action at this time.
0 commit comments