Skip to content

Instantly share code, notes, and snippets.

@scott-riley
Created February 13, 2016 22:03
Show Gist options
  • Save scott-riley/b1d0395877df4a89c6da to your computer and use it in GitHub Desktop.
Save scott-riley/b1d0395877df4a89c6da to your computer and use it in GitHub Desktop.
import React, { Component, PropTypes } from 'react';
import withStyles from 'isomorphic-style-loader/lib/withStyles';
import s from './ProgressBar.scss';
class ProgressBar extends Component {
render() {
const {completed} = this.props;
const style = {
width: `${completed}%`,
};
return (
<div className={s.root}>
<div className={s.bar} style={style}></div>
</div>
);
}
}
export default withStyles(ProgressBar, s);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment