Skip to content

Instantly share code, notes, and snippets.

@kasprownik
Last active January 29, 2016 17:13
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save kasprownik/9c07c84cc13b612f129a to your computer and use it in GitHub Desktop.
Save kasprownik/9c07c84cc13b612f129a to your computer and use it in GitHub Desktop.
// src/components/Text.js
import React, {PropTypes} from 'react';
import TextField from 'material-ui/lib/text-field';
export default React.createClass({
displayName: 'Text',
propTypes: {
name: PropTypes.string.isRequired,
placeholder: PropTypes.string,
label: PropTypes.string
},
render() {
return (
<div>
<TextField
hintText={this.props.placeholder}
floatingLabelText={this.props.label}/>
</div>
);
}
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment