Spaces:
Running
Running
Update app.py
Browse files
app.py
CHANGED
@@ -96,7 +96,9 @@ with gr.Blocks(css=CSS, js=JS, theme="soft") as demo:
|
|
96 |
with gr.Row():
|
97 |
with gr.Column(scale=4):
|
98 |
img = gr.Gallery(label='flux Generated Image', columns = 1, preview=True, height=600)
|
99 |
-
|
|
|
|
|
100 |
with gr.Accordion("Advanced Options", open=True):
|
101 |
with gr.Column(scale=1):
|
102 |
width = gr.Slider(
|
@@ -151,7 +153,11 @@ with gr.Blocks(css=CSS, js=JS, theme="soft") as demo:
|
|
151 |
cache_examples="lazy",
|
152 |
examples_per_page=4,
|
153 |
)
|
154 |
-
|
|
|
|
|
|
|
|
|
155 |
prompt.submit(fn=generate_image,
|
156 |
inputs=[prompt, width, height, scales, steps, seed, nums],
|
157 |
outputs=[img, seed],
|
|
|
96 |
with gr.Row():
|
97 |
with gr.Column(scale=4):
|
98 |
img = gr.Gallery(label='flux Generated Image', columns = 1, preview=True, height=600)
|
99 |
+
with gr.Row():
|
100 |
+
prompt = gr.Textbox(label='Enter Your Prompt (Multi-Languages)', placeholder="Enter prompt...", scale=6)
|
101 |
+
sendBtn = gr.Button(scale=1, variant='primary')
|
102 |
with gr.Accordion("Advanced Options", open=True):
|
103 |
with gr.Column(scale=1):
|
104 |
width = gr.Slider(
|
|
|
153 |
cache_examples="lazy",
|
154 |
examples_per_page=4,
|
155 |
)
|
156 |
+
|
157 |
+
sendBtn.click(fn=generate_image,
|
158 |
+
inputs=[prompt, width, height, scales, steps, seed, nums],
|
159 |
+
outputs=[img, seed],
|
160 |
+
)
|
161 |
prompt.submit(fn=generate_image,
|
162 |
inputs=[prompt, width, height, scales, steps, seed, nums],
|
163 |
outputs=[img, seed],
|