polished send button query
This commit is contained in:
parent
4eb6ef243b
commit
016779faf8
1 changed files with 0 additions and 1 deletions
|
|
@ -26,7 +26,6 @@ let force_go = false;
|
|||
async function chatgpt_sendMsg(msg, method ='') {
|
||||
const textArea = document.querySelector('form textarea'),
|
||||
sendButton = document.querySelector('path[d*="M15.192 8.906a1.143"]')?.parentNode.parentNode // post-GPT-4o;
|
||||
|| document.querySelector('form button[class*="main-surface-secondary"]') // pre-GPT-4o
|
||||
|| document.querySelector('[data-testid="send-button"]'); // pre-GPT-4o
|
||||
textArea.value = msg;
|
||||
textArea.dispatchEvent(new Event('input', { bubbles: true })); // enable send button
|
||||
|
|
|
|||
Loading…
Reference in a new issue