Merge pull request #151 from northernCold/fix-noi-ask

fix: tongyi submit doesn't work
This commit is contained in:
lencx 2024-05-12 14:33:55 +08:00 committed by GitHub
commit 9787604e25
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -299,14 +299,8 @@ class TongyiAsk extends NoiAsk {
static url = 'https://tongyi.aliyun.com/qianwen'; static url = 'https://tongyi.aliyun.com/qianwen';
static submit() { static submit() {
const inputElement = document.querySelector('textarea'); const btn = document.querySelector('div[class*=operateBtn]');
if (inputElement) { if (btn) btn.click();
const nextElement = inputElement.nextElementSibling;
if (nextElement) {
const btn = nextElement.querySelector('div[class^="chatBtn"]');
if (btn) btn.click();
}
}
} }
} }