Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

SelectField ignores disabled property #1294

Closed
Kagami opened this issue Jul 30, 2015 · 2 comments · Fixed by #1406
Closed

SelectField ignores disabled property #1294

Kagami opened this issue Jul 30, 2015 · 2 comments · Fixed by #1406
Labels
component: select This is the name of the generic UI component, not the React module!

Comments

@Kagami
Copy link

Kagami commented Jul 30, 2015

Hi. The following code produces correct selectable SelectField widget but the disabled property get ignored. I'm using the latest [email protected].

require("react-tap-event-plugin")();
var React = require("react");
var mui = require("material-ui");

var ThemeManager = new mui.Styles.ThemeManager();

var Test = React.createClass({
  childContextTypes: {
    muiTheme: React.PropTypes.object,
  },
  getChildContext: function() {
    return {muiTheme: ThemeManager.getCurrentTheme()};
  },
  render: function() {
    return (
      <mui.SelectField
        value=""
        hintText="test"
        menuItems={[{payload: 1, text: "test"}]}
        disabled={true}
      />
    );
  },
});

React.render(<Test/>, document.getElementById("main"));

Is this a bug or disabled property wasn't implemented yet for SelectField?

@Zadielerick
Copy link
Contributor

@Kagami I took a look at the current code and the disabled prop is not declared, but it is passed to drop-down-menu. However, the dropDownMenu does not call that prop at all, so this is a problem with the code, the dropDownMenu needs a disabled prop.

@mjhasbach
Copy link
Contributor

See #951

mjhasbach added a commit to mjhasbach/material-ui that referenced this issue Aug 13, 2015
mjhasbach added a commit to mjhasbach/material-ui that referenced this issue Aug 13, 2015
@oliviertassinari oliviertassinari added the status: waiting for maintainer These issues haven't been looked at yet by a maintainer label Dec 25, 2022
@zannager zannager added component: select This is the name of the generic UI component, not the React module! and removed status: waiting for maintainer These issues haven't been looked at yet by a maintainer labels Jan 13, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
component: select This is the name of the generic UI component, not the React module!
Projects
None yet
Development

Successfully merging a pull request may close this issue.

5 participants