multimodalart HF staff commited on
Commit
b157e21
1 Parent(s): 8428948

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +3 -3
app.py CHANGED
@@ -133,7 +133,7 @@ def save_preferences(lora_1_id, lora_1_scale, lora_2_id, lora_2_scale, prompt, g
133
  json.dump({"prompt": prompt, "file_name":image_path.name, "lora_1_id": lora_2_id, "lora_1_scale": lora_1_scale, "lora_2_id": lora_2_id, "lora_2_scale": lora_2_scale, "thumbs_direction": thumbs_direction, "seed": seed}, f)
134
  f.write("\n")
135
 
136
- return gr.update(visible=True), gr.update(interactive=False, elem_classes=f"thumbs-{thumbs_direction}-clicked"), gr.update(interactive=False)
137
 
138
  with gr.Blocks(css=css) as demo:
139
  shuffled_items = gr.State()
@@ -166,9 +166,9 @@ with gr.Blocks(css=css) as demo:
166
  output_image = gr.Image(label="Output", height=355, elem_id="output_image")
167
  with gr.Row(visible=False, elem_id="post_gen_info") as post_gen_info:
168
  with gr.Column(min_width=10):
169
- thumbs_up = gr.Button("👍", elem_classes="thumbs_up_unclicked")
170
  with gr.Column(min_width=10):
171
- thumbs_down = gr.Button("👎", elem_classes="thumbs_down_unclicked")
172
  with gr.Column(min_width=10):
173
  with gr.Group(elem_id="share-btn-container") as share_group:
174
  community_icon = gr.HTML(community_icon_html)
 
133
  json.dump({"prompt": prompt, "file_name":image_path.name, "lora_1_id": lora_2_id, "lora_1_scale": lora_1_scale, "lora_2_id": lora_2_id, "lora_2_scale": lora_2_scale, "thumbs_direction": thumbs_direction, "seed": seed}, f)
134
  f.write("\n")
135
 
136
+ return gr.update(visible=True), gr.update(interactive=False, elem_id=f"thumbs-{thumbs_direction}-clicked"), gr.update(interactive=False)
137
 
138
  with gr.Blocks(css=css) as demo:
139
  shuffled_items = gr.State()
 
166
  output_image = gr.Image(label="Output", height=355, elem_id="output_image")
167
  with gr.Row(visible=False, elem_id="post_gen_info") as post_gen_info:
168
  with gr.Column(min_width=10):
169
+ thumbs_up = gr.Button("👍", elem_id="thumbs_up_unclicked")
170
  with gr.Column(min_width=10):
171
+ thumbs_down = gr.Button("👎", elem_id="thumbs_down_unclicked")
172
  with gr.Column(min_width=10):
173
  with gr.Group(elem_id="share-btn-container") as share_group:
174
  community_icon = gr.HTML(community_icon_html)