Enforce multiline on key-value editor (Fixes #745)

This commit is contained in:
Gregory Schier 2018-02-08 17:14:54 +08:00
parent e57bc871f2
commit f746eff4ca
2 changed files with 6 additions and 1 deletions

3
.github/stale.yml vendored
View File

@ -2,9 +2,10 @@ daysUntilStale: 60
daysUntilClose: 7
exemptLabels:
- High Priority
- Needs PR
- Accepted
- Help Wanted
- Blocked
- Bug
staleLabel: Stale
markComment: >
This issue has been automatically marked as stale because it has not had

View File

@ -62,6 +62,10 @@ class KeyValueEditorRow extends PureComponent {
}
_handleValuePaste (e) {
if (!this.props.allowMultiline) {
return;
}
const value = e.clipboardData.getData('text/plain');
if (value && value.includes('\n')) {
e.preventDefault();