muba-input-text 4.1.2 → 4.1.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/InputText.js +5 -2
  2. package/package.json +1 -1
package/InputText.js CHANGED
@@ -56,6 +56,10 @@ export default class InputText extends React.Component {
56
56
  }
57
57
  ]);
58
58
  this.setState({ fontLoaded: true });
59
+
60
+ if (this.props.autoFocus) {
61
+ setTimeout(() => this.input.focus(), 100);
62
+ }
59
63
  }
60
64
 
61
65
  isValidUrl(url) {
@@ -258,8 +262,7 @@ export default class InputText extends React.Component {
258
262
  selection={this.props.selection}
259
263
  selectionColor={this.props.selectionColor}
260
264
  numberOfLines={this.props.numberOfLines}
261
- maxLength={this.props.maxLength}
262
- autoFocus={this.props.autoFocus} />
265
+ maxLength={this.props.maxLength} />
263
266
  {this.props.children}
264
267
 
265
268
  {this.props.value != null && !this.props.hideCancel ?
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "muba-input-text",
3
- "version": "4.1.2",
3
+ "version": "4.1.3",
4
4
  "description": "Input text",
5
5
  "main": "InputText.js",
6
6
  "scripts": {