mirror of
https://github.com/oobabooga/text-generation-webui.git
synced 2024-11-25 17:29:22 +01:00
Confirm the chat history rename with enter
This commit is contained in:
parent
4d730a759a
commit
a9f49a7574
@ -267,6 +267,11 @@ def create_event_handlers():
|
|||||||
lambda: [gr.update(visible=False)] * 3, None, gradio('rename_to', 'rename_to-confirm', 'rename_to-cancel'), show_progress=False).then(
|
lambda: [gr.update(visible=False)] * 3, None, gradio('rename_to', 'rename_to-confirm', 'rename_to-cancel'), show_progress=False).then(
|
||||||
lambda x, y: gr.update(choices=chat.find_all_histories(x), value=y), gradio('interface_state', 'rename_to'), gradio('unique_id'))
|
lambda x, y: gr.update(choices=chat.find_all_histories(x), value=y), gradio('interface_state', 'rename_to'), gradio('unique_id'))
|
||||||
|
|
||||||
|
shared.gradio['rename_to'].submit(
|
||||||
|
chat.rename_history, gradio('unique_id', 'rename_to', 'character_menu', 'mode'), None).then(
|
||||||
|
lambda: [gr.update(visible=False)] * 3, None, gradio('rename_to', 'rename_to-confirm', 'rename_to-cancel'), show_progress=False).then(
|
||||||
|
lambda x, y: gr.update(choices=chat.find_all_histories(x), value=y), gradio('interface_state', 'rename_to'), gradio('unique_id'))
|
||||||
|
|
||||||
shared.gradio['load_chat_history'].upload(
|
shared.gradio['load_chat_history'].upload(
|
||||||
ui.gather_interface_values, gradio(shared.input_elements), gradio('interface_state')).then(
|
ui.gather_interface_values, gradio(shared.input_elements), gradio('interface_state')).then(
|
||||||
chat.start_new_chat, gradio('interface_state'), gradio('history')).then(
|
chat.start_new_chat, gradio('interface_state'), gradio('history')).then(
|
||||||
|
Loading…
Reference in New Issue
Block a user