ink-text-input
Advanced tools
Comparing version 1.1.0 to 1.1.1
@@ -35,2 +35,6 @@ 'use strict'; | ||
handleKeyPress(ch, key) { | ||
if (!this.props.focus) { | ||
return; | ||
} | ||
if (hasAnsi(key.sequence)) { | ||
@@ -40,3 +44,3 @@ return; | ||
const { value, onSubmit, onChange } = this.props; | ||
const { value, onChange, onSubmit } = this.props; | ||
@@ -63,3 +67,4 @@ if (key.name === 'return') { | ||
onChange: PropTypes.func, | ||
onSubmit: PropTypes.func | ||
onSubmit: PropTypes.func, | ||
focus: PropTypes.bool | ||
}; | ||
@@ -71,5 +76,6 @@ | ||
onChange: noop, | ||
onSubmit: noop | ||
onSubmit: noop, | ||
focus: true | ||
}; | ||
module.exports = TextInput; |
{ | ||
"name": "ink-text-input", | ||
"version": "1.1.0", | ||
"version": "1.1.1", | ||
"description": "Text input component for Ink", | ||
@@ -5,0 +5,0 @@ "license": "MIT", |
@@ -59,3 +59,5 @@ # ink-text-input [![Build Status](https://travis-ci.org/vadimdemedes/ink-text-input.svg?branch=master)](https://travis-ci.org/vadimdemedes/ink-text-input) | ||
<img src="media/demo.gif" width="556"> | ||
## Props | ||
@@ -62,0 +64,0 @@ |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
5281
59
92