Rework music player with bulma
This commit is contained in:
parent
aa721767fa
commit
9ffc145834
7 changed files with 154 additions and 121 deletions
|
|
@ -22,22 +22,30 @@ class Indicator extends React.Component<Props, State> {
|
|||
}
|
||||
|
||||
render() {
|
||||
const classes = classNames({
|
||||
btn: true,
|
||||
"col-auto": true,
|
||||
const button_classes = classNames({
|
||||
button: true,
|
||||
"is-primary": true,
|
||||
"level-item": true,
|
||||
// TODO(tlater): Add loading logic here
|
||||
});
|
||||
|
||||
const icon_classes = classNames({
|
||||
fas: true,
|
||||
"fa-2x": true,
|
||||
"fa-muted": this.props.muted,
|
||||
"fa-play": this.props.playing,
|
||||
"fa-pause": !this.props.playing,
|
||||
"fa-play": !this.props.playing,
|
||||
"fa-pause": this.props.playing,
|
||||
});
|
||||
|
||||
return (
|
||||
<button
|
||||
type="button"
|
||||
id="playerIndicator"
|
||||
onClick={this.click.bind(this)}
|
||||
className={classes}
|
||||
></button>
|
||||
className={button_classes}>
|
||||
<span className="icon is-medium">
|
||||
<i className={icon_classes}></i>
|
||||
</span>
|
||||
</button>
|
||||
);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Reference in a new issue