chansung commited on
Commit
8a683f6
β€’
1 Parent(s): 78346fb

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +17 -4
app.py CHANGED
@@ -470,11 +470,10 @@ Lastly, there is a hidden panel on the top right corner, and it will appear when
470
 
471
  instruction_txtbox.submit(
472
  lambda: [
473
- gr.update(visible=False),
474
- gr.update(interactive=True)
475
  ],
476
  None,
477
- [example_block, regenerate]
478
  )
479
 
480
  send_event = instruction_txtbox.submit(
@@ -488,7 +487,14 @@ Lastly, there is a hidden panel on the top right corner, and it will appear when
488
  instruction_txtbox.submit(
489
  None, local_data, None,
490
  _js="(v)=>{ setStorage('local_data',v) }"
491
- )
 
 
 
 
 
 
 
492
 
493
  regenerate.click(
494
  rollback_last,
@@ -513,6 +519,13 @@ Lastly, there is a hidden panel on the top right corner, and it will appear when
513
  regenerate.click(
514
  None, local_data, None,
515
  _js="(v)=>{ setStorage('local_data',v) }"
 
 
 
 
 
 
 
516
  )
517
 
518
  stop.click(
 
470
 
471
  instruction_txtbox.submit(
472
  lambda: [
473
+ gr.update(visible=False)
 
474
  ],
475
  None,
476
+ [example_block]
477
  )
478
 
479
  send_event = instruction_txtbox.submit(
 
487
  instruction_txtbox.submit(
488
  None, local_data, None,
489
  _js="(v)=>{ setStorage('local_data',v) }"
490
+ ).then(
491
+ lambda: [
492
+ gr.update(interactive=True),
493
+ gr.update(interactive=True),
494
+ ],
495
+ None,
496
+ [regenerate, stop]
497
+ )
498
 
499
  regenerate.click(
500
  rollback_last,
 
519
  regenerate.click(
520
  None, local_data, None,
521
  _js="(v)=>{ setStorage('local_data',v) }"
522
+ ).then(
523
+ lambda: [
524
+ gr.update(interactive=True),
525
+ gr.update(interactive=True),
526
+ ],
527
+ None,
528
+ [regenerate, stop]
529
  )
530
 
531
  stop.click(