mirror of
https://github.com/a-nyx/maputnik-with-pmtiles.git
synced 2025-01-15 04:41:19 +01:00
Filter empty strings in <FontInput/>
This commit is contained in:
parent
a066710bfb
commit
db9ad86ac2
1 changed files with 4 additions and 1 deletions
|
@ -30,7 +30,10 @@ class FontInput extends React.Component {
|
||||||
changeFont(idx, newValue) {
|
changeFont(idx, newValue) {
|
||||||
const changedValues = this.values.slice(0)
|
const changedValues = this.values.slice(0)
|
||||||
changedValues[idx] = newValue
|
changedValues[idx] = newValue
|
||||||
const filteredValues = changedValues.filter(v => v !== undefined);
|
const filteredValues = changedValues
|
||||||
|
.filter(v => v !== undefined)
|
||||||
|
.filter(v => v !== "")
|
||||||
|
|
||||||
this.props.onChange(filteredValues);
|
this.props.onChange(filteredValues);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue