Spaces:
Runtime error
Runtime error
Commit
Β·
d76094b
1
Parent(s):
a50d0a2
Update app.py
Browse filesTry re-adding gradio columns to revert from final image error
app.py
CHANGED
@@ -378,31 +378,25 @@ with gr.Blocks(css=css) as demo:
|
|
378 |
with gr.Row().style():
|
379 |
infer_outputs = gr.Gallery(show_label=False, elem_id="generated-gallery").style(grid=[2], height="512px")
|
380 |
with gr.Row():
|
381 |
-
gr.HTML("<p
|
382 |
with gr.Row():
|
383 |
gr.Examples(examples=examples, fn=infer_examples, inputs=[text], outputs=infer_outputs, cache_examples=True)
|
384 |
-
|
385 |
-
|
386 |
-
|
387 |
-
|
388 |
-
# checkbox_states = {}
|
389 |
-
# inputs = [text]
|
390 |
-
# btn.click(
|
391 |
-
# infer,
|
392 |
-
# inputs=inputs,
|
393 |
-
# outputs=[infer_outputs, community_icon, loading_icon, share_button]
|
394 |
-
# )
|
395 |
-
# share_button.click(
|
396 |
-
# None,
|
397 |
-
# [],
|
398 |
-
# [],
|
399 |
-
# _js=share_js,
|
400 |
-
# )
|
401 |
checkbox_states = {}
|
402 |
inputs = [text]
|
403 |
btn.click(
|
404 |
infer,
|
405 |
inputs=inputs,
|
406 |
-
outputs=[infer_outputs]
|
407 |
)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
408 |
demo.queue(max_size=20).launch()
|
|
|
378 |
with gr.Row().style():
|
379 |
infer_outputs = gr.Gallery(show_label=False, elem_id="generated-gallery").style(grid=[2], height="512px")
|
380 |
with gr.Row():
|
381 |
+
gr.HTML("<p></p>")
|
382 |
with gr.Row():
|
383 |
gr.Examples(examples=examples, fn=infer_examples, inputs=[text], outputs=infer_outputs, cache_examples=True)
|
384 |
+
with gr.Group(elem_id="share-btn-container"):
|
385 |
+
community_icon = gr.HTML(community_icon_html, visible=False)
|
386 |
+
loading_icon = gr.HTML(loading_icon_html, visible=False)
|
387 |
+
share_button = gr.Button("Share to community", elem_id="share-btn", visible=False)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
388 |
checkbox_states = {}
|
389 |
inputs = [text]
|
390 |
btn.click(
|
391 |
infer,
|
392 |
inputs=inputs,
|
393 |
+
outputs=[infer_outputs, community_icon, loading_icon, share_button]
|
394 |
)
|
395 |
+
share_button.click(
|
396 |
+
None,
|
397 |
+
[],
|
398 |
+
[],
|
399 |
+
_js=share_js,
|
400 |
+
)
|
401 |
+
|
402 |
demo.queue(max_size=20).launch()
|