Spaces:
Sleeping
Sleeping
chinese_paragraph_save_history_button.click(
Browse files
app.py
CHANGED
@@ -1494,6 +1494,12 @@ def show_elements():
|
|
1494 |
def hide_elements():
|
1495 |
return gr.update(visible=False)
|
1496 |
|
|
|
|
|
|
|
|
|
|
|
|
|
1497 |
def duplicate_element(element):
|
1498 |
return element
|
1499 |
|
@@ -3492,6 +3498,12 @@ with gr.Blocks(theme=THEME, css=CSS) as demo:
|
|
3492 |
chinese_full_paragraph_save_output_history = gr.Markdown()
|
3493 |
|
3494 |
chinese_paragraph_save_history_button.click(
|
|
|
|
|
|
|
|
|
|
|
|
|
3495 |
fn=update_history_accordion,
|
3496 |
inputs=[],
|
3497 |
outputs=[chinese_grapragh_practice_history_accordion]
|
@@ -3521,6 +3533,10 @@ with gr.Blocks(theme=THEME, css=CSS) as demo:
|
|
3521 |
chinese_full_paragraph_refine_output_table_history,
|
3522 |
chinese_full_paragraph_save_output_history
|
3523 |
]
|
|
|
|
|
|
|
|
|
3524 |
)
|
3525 |
|
3526 |
chinese_full_paragraph_evaluate_button.click(
|
|
|
1494 |
def hide_elements():
|
1495 |
return gr.update(visible=False)
|
1496 |
|
1497 |
+
def enable_elements():
|
1498 |
+
return gr.update(interactive=True)
|
1499 |
+
|
1500 |
+
def disable_elements():
|
1501 |
+
return gr.update(interactive=False)
|
1502 |
+
|
1503 |
def duplicate_element(element):
|
1504 |
return element
|
1505 |
|
|
|
3498 |
chinese_full_paragraph_save_output_history = gr.Markdown()
|
3499 |
|
3500 |
chinese_paragraph_save_history_button.click(
|
3501 |
+
fn=disable_elements,
|
3502 |
+
inputs=[],
|
3503 |
+
outputs=[
|
3504 |
+
chinese_paragraph_save_history_button
|
3505 |
+
]
|
3506 |
+
).then(
|
3507 |
fn=update_history_accordion,
|
3508 |
inputs=[],
|
3509 |
outputs=[chinese_grapragh_practice_history_accordion]
|
|
|
3533 |
chinese_full_paragraph_refine_output_table_history,
|
3534 |
chinese_full_paragraph_save_output_history
|
3535 |
]
|
3536 |
+
).then(
|
3537 |
+
fn=enable_elements,
|
3538 |
+
inputs=[],
|
3539 |
+
outputs=[chinese_paragraph_save_history_button]
|
3540 |
)
|
3541 |
|
3542 |
chinese_full_paragraph_evaluate_button.click(
|