react-edit-text
Advanced tools
Comparing version 3.0.0 to 3.0.1
@@ -0,1 +1,8 @@ | ||
## [3.0.1](https://github.com/bymi15/react-edit-text/compare/v3.0.0...v3.0.1) (2021-01-13) | ||
### Bug Fixes | ||
* allow onSave callback to be triggered when used with onChange ([6508ea4](https://github.com/bymi15/react-edit-text/commit/6508ea47411a422ce1ab63d2224534a6b665124a)) | ||
# [3.0.0](https://github.com/bymi15/react-edit-text/compare/v2.1.3...v3.0.0) (2021-01-13) | ||
@@ -2,0 +9,0 @@ |
@@ -1135,3 +1135,3 @@ function _interopDefault (ex) { return (ex && (typeof ex === 'object') && 'default' in ex) ? ex['default'] : ex; } | ||
if (!!save && _this.state.savedText !== value) { | ||
if (!!save && _this.state.savedText !== value || _this.props.value !== null) { | ||
_this.setState({ | ||
@@ -1301,3 +1301,3 @@ savedText: value | ||
if (!!save && _this.state.savedText !== value) { | ||
if (!!save && _this.state.savedText !== value || _this.props.value !== null) { | ||
var lines = value === '' ? [] : value.split(/\r?\n/); | ||
@@ -1304,0 +1304,0 @@ |
@@ -1133,3 +1133,3 @@ import React from 'react'; | ||
if (!!save && _this.state.savedText !== value) { | ||
if (!!save && _this.state.savedText !== value || _this.props.value !== null) { | ||
_this.setState({ | ||
@@ -1299,3 +1299,3 @@ savedText: value | ||
if (!!save && _this.state.savedText !== value) { | ||
if (!!save && _this.state.savedText !== value || _this.props.value !== null) { | ||
var lines = value === '' ? [] : value.split(/\r?\n/); | ||
@@ -1302,0 +1302,0 @@ |
{ | ||
"name": "react-edit-text", | ||
"version": "3.0.0", | ||
"version": "3.0.1", | ||
"description": "Simple editable text component for React", | ||
@@ -5,0 +5,0 @@ "author": "Brian Min <bymi15@yahoo.com> (https://github.com/bymi15)", |
@@ -63,6 +63,6 @@ <h1 align="center">React Edit Text</h1> | ||
| id | string | No | | HTML DOM id attribute | | ||
| name | string | No | '' | HTML input name attribute | | ||
| name | string | No | | HTML input name attribute | | ||
| className | string | No | | HTML class attribute | | ||
| value | string | No | '' | Value of the component | | ||
| defaultValue | string | No | '' | Default value of the component | | ||
| value | string | No | | Value of the component | | ||
| defaultValue | string | No | | Default value of the component | | ||
| placeholder | string | No | '' | Placeholder value | | ||
@@ -69,0 +69,0 @@ | onSave | function | No | | Callback function triggered when input is saved | |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
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
296906