Continue on Alt + Enter

This commit is contained in:
oobabooga 2023-09-14 03:59:12 -07:00
parent 1ce3c93600
commit ecc90f9f62
2 changed files with 3 additions and 3 deletions

View File

@ -63,8 +63,8 @@ document.addEventListener("keydown", function(event) {
document.getElementById('Regenerate').click(); document.getElementById('Regenerate').click();
} }
// Continue on Ctrl + Shift + C // Continue on Alt + Enter
else if (event.ctrlKey && event.shiftKey && event.key === 'C') { else if (event.altKey && event.key === 'Enter') {
event.preventDefault(); event.preventDefault();
document.getElementById('Continue').click(); document.getElementById('Continue').click();
} }

View File

@ -41,7 +41,7 @@ def create_ui():
# Hover menu buttons # Hover menu buttons
shared.gradio['Regenerate'] = gr.Button('Regenerate (Ctrl + Enter)', elem_id='Regenerate') shared.gradio['Regenerate'] = gr.Button('Regenerate (Ctrl + Enter)', elem_id='Regenerate')
shared.gradio['Continue'] = gr.Button('Continue (Ctrl + Shift + C)', elem_id='Continue') shared.gradio['Continue'] = gr.Button('Continue (Alt + Enter)', elem_id='Continue')
shared.gradio['Remove last'] = gr.Button('Remove last reply (Ctrl + Shift + Backspace)', elem_id='Remove-last') shared.gradio['Remove last'] = gr.Button('Remove last reply (Ctrl + Shift + Backspace)', elem_id='Remove-last')
shared.gradio['Replace last reply'] = gr.Button('Replace last reply (Ctrl + Shift + L)', elem_id='Replace-last') shared.gradio['Replace last reply'] = gr.Button('Replace last reply (Ctrl + Shift + L)', elem_id='Replace-last')
shared.gradio['Copy last reply'] = gr.Button('Copy last reply (Ctrl + Shift + K)', elem_id='Copy-last') shared.gradio['Copy last reply'] = gr.Button('Copy last reply (Ctrl + Shift + K)', elem_id='Copy-last')