Fix UI when loading invalid style with duplicate layer ids.

Also fix for throwing error when 2 layers exist with empty strings as ids.
This commit is contained in:
orangemug
2020-03-28 10:58:47 +00:00
parent f70d078ec6
commit 74b47e7e74
6 changed files with 82 additions and 38 deletions

View File

@@ -79,6 +79,11 @@ class StringInput extends React.Component {
this.props.onChange(this.state.value);
}
},
onKeyDown: (e) => {
if (e.keyCode === 13) {
this.props.onChange(this.state.value);
}
},
required: this.props.required,
});
}