Add reload button to control interface

This commit is contained in:
Max Goodhart
2020-06-19 08:01:59 -07:00
parent 1a3c82b2a5
commit a58a94aa51
5 changed files with 81 additions and 26 deletions

View File

@@ -16,14 +16,11 @@ const viewStateMachine = Machine(
},
states: {
empty: {
entry: [
assign({
pos: {},
info: {},
url: null,
}),
'hideView',
],
entry: assign({
pos: {},
info: {},
url: null,
}),
invoke: {
src: 'clearView',
onError: {
@@ -45,6 +42,7 @@ const viewStateMachine = Machine(
}),
cond: 'urlUnchanged',
},
RELOAD: '.loading',
},
states: {
loading: {
@@ -80,6 +78,7 @@ const viewStateMachine = Machine(
running: {
initial: 'muted',
entry: 'positionView',
exit: 'hideView',
on: {
DISPLAY: {
actions: [