JLW commited on
Commit
7288f94
·
1 Parent(s): 51431ad

Constrain chatbot height

Browse files
Files changed (1) hide show
  1. app.py +10 -9
app.py CHANGED
@@ -354,18 +354,19 @@ with gr.Blocks(css=".gradio-container {background-color: lightgray} ") as block:
354
  show_label=False, lines=1, type='password')
355
 
356
  with gr.Row():
357
- with gr.Column(scale=1, min_width=240):
358
- my_file = gr.File(label="Upload a file", type="file", visible=False)
359
- tmp_file = gr.File("videos/Masahiro.mp4", visible=False)
360
- tmp_file_url = "/file=" + tmp_file.value['name']
361
- htm_video = f'<video width="256" height="256" autoplay muted loop><source src={tmp_file_url} type="video/mp4" poster="Masahiro.png"></video>'
362
- video_html = gr.HTML(htm_video)
363
 
364
- trace_chain_cb = gr.Checkbox(label="Show chain", value=False)
365
- trace_chain_cb.change(update_foo, inputs=[trace_chain_cb, trace_chain_state],
366
- outputs=[trace_chain_state])
367
 
368
  # with gr.Column(scale=3):
 
369
  chatbot = gr.Chatbot()
370
 
371
  with gr.Row():
 
354
  show_label=False, lines=1, type='password')
355
 
356
  with gr.Row():
357
+ # with gr.Column(scale=1, min_width=240):
358
+ my_file = gr.File(label="Upload a file", type="file", visible=False)
359
+ tmp_file = gr.File("videos/Masahiro.mp4", visible=False)
360
+ tmp_file_url = "/file=" + tmp_file.value['name']
361
+ htm_video = f'<video width="256" height="256" autoplay muted loop><source src={tmp_file_url} type="video/mp4" poster="Masahiro.png"></video>'
362
+ video_html = gr.HTML(htm_video)
363
 
364
+ trace_chain_cb = gr.Checkbox(label="Show chain", value=False)
365
+ trace_chain_cb.change(update_foo, inputs=[trace_chain_cb, trace_chain_state],
366
+ outputs=[trace_chain_state])
367
 
368
  # with gr.Column(scale=3):
369
+ with gr.Row():
370
  chatbot = gr.Chatbot()
371
 
372
  with gr.Row():