mirror of
https://github.com/a-nyx/maputnik-with-pmtiles.git
synced 2024-12-28 02:05:25 +01:00
Added default to <CheckboxInput/> value to fix warning in console.
This commit is contained in:
parent
5be7e0c7ec
commit
4b8800e8ac
1 changed files with 5 additions and 1 deletions
|
@ -3,11 +3,15 @@ import PropTypes from 'prop-types'
|
||||||
|
|
||||||
class CheckboxInput extends React.Component {
|
class CheckboxInput extends React.Component {
|
||||||
static propTypes = {
|
static propTypes = {
|
||||||
value: PropTypes.bool.isRequired,
|
value: PropTypes.bool,
|
||||||
style: PropTypes.object,
|
style: PropTypes.object,
|
||||||
onChange: PropTypes.func,
|
onChange: PropTypes.func,
|
||||||
}
|
}
|
||||||
|
|
||||||
|
static defaultProps = {
|
||||||
|
value: false,
|
||||||
|
}
|
||||||
|
|
||||||
render() {
|
render() {
|
||||||
return <label className="maputnik-checkbox-wrapper">
|
return <label className="maputnik-checkbox-wrapper">
|
||||||
<input
|
<input
|
||||||
|
|
Loading…
Reference in a new issue