Skip to content

Instantly share code, notes, and snippets.

@thenayr
Created November 17, 2016 23:18
Show Gist options
  • Save thenayr/8a014a0ecb149a8c6ceceb9f7bb64a2c to your computer and use it in GitHub Desktop.
Save thenayr/8a014a0ecb149a8c6ceceb9f7bb64a2c to your computer and use it in GitHub Desktop.
Pod component with the material texture mapping based on Pod labels.
class Pod extends React.Component {
constructor(props) {
super(props);
this.state = {
color: props.color,
clicked: false
}
this.containerMat = {
nginx: "#nginx",
ubuntu: "#ubuntu",
wordpress: "#wordpress",
redis: "#redis",
k8s: "#k8s"
}
this.clickHandler = this.clickHandler.bind(this);
}
...
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment