Spaces:
Running
Running
P01yH3dr0n
commited on
Commit
•
7381128
1
Parent(s):
a7f7261
read image info button fix
Browse files
app.py
CHANGED
@@ -193,9 +193,9 @@ def util_ui():
|
|
193 |
image = gr.Image(label="上传图片", sources=["upload"], interactive=True, type="pil")
|
194 |
with gr.Column(variant='panel'):
|
195 |
info = gr.HTML('')
|
196 |
-
items = gr.JSON(value=
|
197 |
png2main = gr.Button('参数发送到文生图', visible=False)
|
198 |
-
items.change(lambda i: gr.Button(visible=
|
199 |
return png2main, items, info, image
|
200 |
|
201 |
def load_javascript():
|
|
|
193 |
image = gr.Image(label="上传图片", sources=["upload"], interactive=True, type="pil")
|
194 |
with gr.Column(variant='panel'):
|
195 |
info = gr.HTML('')
|
196 |
+
items = gr.JSON(value={}, visible=False)
|
197 |
png2main = gr.Button('参数发送到文生图', visible=False)
|
198 |
+
items.change(lambda i: gr.Button(visible=True) if len(i) else gr.Button(visible=False), inputs=items, outputs=png2main)
|
199 |
return png2main, items, info, image
|
200 |
|
201 |
def load_javascript():
|