S
S
Shane Matte2017-02-19 16:58:16
JavaScript
Shane Matte, 2017-02-19 16:58:16

Why are events not firing in material ui react?

Hello. I output select.

<SelectField
    floatingLabelText="Категории"
    value={this.state.catId}
    onChange={this.changeCategory}
    onClick={this.changeCategory}
    maxHeight={200}
    style={{width:'200px'}}
  >
  { 
    Object.keys(categories.categories).map((key, i) => {
      return <MenuItem key={i} value={i} primaryText={categories.categories[key].title } />
    })
  }
</SelectField>

The event doesn't fire.
I’ll write right away that the react-tap-event-plugin plugin is installed.
The list is shown after pressing the space button. The click does not work.
What is the problem?
react version 0.14.8

Answer the question

In order to leave comments, you need to log in

1 answer(s)
R
rustambmt, 2017-02-21
@rustambmt

because there is no such property onClick , only onChange
www.material-ui.com/#/components/select-field

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question