multimodalart HF Staff commited on
Commit
d714174
·
verified ·
1 Parent(s): 40bccc7

Fix Gradio 6 API: move theme/css to launch(), drop show_copy_button

Browse files
Files changed (1) hide show
  1. app.py +3 -3
app.py CHANGED
@@ -149,7 +149,7 @@ EXAMPLES = [
149
  ["examples/sunglasses.png", "Remove the sunglasses from the person sitting on the left."],
150
  ]
151
 
152
- with gr.Blocks(theme=gr.themes.Citrus(), css=CSS) as demo:
153
  with gr.Column(elem_id="col-container"):
154
  gr.Markdown(
155
  """
@@ -194,7 +194,7 @@ with gr.Blocks(theme=gr.themes.Citrus(), css=CSS) as demo:
194
  with gr.Column():
195
  output_image = gr.Image(label="Edited image", height=380)
196
  plan_out = gr.Textbox(
197
- label="Planner reasoning & regions", lines=12, show_copy_button=True,
198
  )
199
 
200
  gr.Examples(
@@ -212,4 +212,4 @@ with gr.Blocks(theme=gr.themes.Citrus(), css=CSS) as demo:
212
  instruction.submit(edit_image, inputs=inputs, outputs=outputs, api_name=False)
213
 
214
  if __name__ == "__main__":
215
- demo.launch(mcp_server=True)
 
149
  ["examples/sunglasses.png", "Remove the sunglasses from the person sitting on the left."],
150
  ]
151
 
152
+ with gr.Blocks() as demo:
153
  with gr.Column(elem_id="col-container"):
154
  gr.Markdown(
155
  """
 
194
  with gr.Column():
195
  output_image = gr.Image(label="Edited image", height=380)
196
  plan_out = gr.Textbox(
197
+ label="Planner reasoning & regions", lines=12,
198
  )
199
 
200
  gr.Examples(
 
212
  instruction.submit(edit_image, inputs=inputs, outputs=outputs, api_name=False)
213
 
214
  if __name__ == "__main__":
215
+ demo.launch(theme=gr.themes.Citrus(), css=CSS, mcp_server=True)