add live updates when sketch is playing
This commit is contained in:
parent
8b04d04bb3
commit
18dd7c6541
2 changed files with 10 additions and 0 deletions
|
@ -46,6 +46,10 @@ class PreviewFrame extends React.Component {
|
|||
this.clearPreview();
|
||||
}
|
||||
}
|
||||
|
||||
if (this.props.isPlaying && this.props.content != prevProps.content) {
|
||||
this.renderSketch();
|
||||
}
|
||||
}
|
||||
|
||||
componentWillUnmount() {
|
||||
|
|
|
@ -1,6 +1,12 @@
|
|||
.toolbar__play-button {
|
||||
@extend %toolbar-button;
|
||||
margin-right: #{15 / $base-font-size}rem;
|
||||
&.playing {
|
||||
background-color: $light-button-background-hover-color;
|
||||
& g {
|
||||
fill: $light-button-hover-color;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.toolbar__stop-button {
|
||||
|
|
Loading…
Reference in a new issue