mirror of
https://github.com/a-nyx/maputnik-with-pmtiles.git
synced 2024-11-10 09:07:47 +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) {
|
||||
const changedValues = this.values.slice(0)
|
||||
changedValues[idx] = newValue
|
||||
const filteredValues = changedValues.filter(v => v !== undefined);
|
||||
const filteredValues = changedValues
|
||||
.filter(v => v !== undefined)
|
||||
.filter(v => v !== "")
|
||||
|
||||
this.props.onChange(filteredValues);
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue