Adjust browser resolution; show loading spinner when browser session has started

This commit is contained in:
Saoud Rizwan
2024-10-27 16:05:26 -04:00
parent c65217ee7e
commit fbc987e220
5 changed files with 113 additions and 82 deletions

View File

@@ -1398,6 +1398,11 @@ export class Cline {
if (!didApprove) {
break
}
// NOTE: it's okay that we call this message since the partial inspect_site is finished streaming. The only scenario we have to avoid is sending messages WHILE a partial message exists at the end of the messages array. For example the api_req_finished message would interfere with the partial message, so we needed to remove that.
// await this.say("inspect_site_result", "") // no result, starts the loading spinner waiting for result
await this.say("browser_action_result", "") // starts loading spinner
await this.browserSession.launchBrowser()
browserActionResult = await this.browserSession.navigateToUrl(url)
} else {
@@ -1451,9 +1456,6 @@ export class Cline {
}
}
// NOTE: it's okay that we call this message since the partial inspect_site is finished streaming. The only scenario we have to avoid is sending messages WHILE a partial message exists at the end of the messages array. For example the api_req_finished message would interfere with the partial message, so we needed to remove that.
// await this.say("inspect_site_result", "") // no result, starts the loading spinner waiting for result
switch (action) {
case "launch":
case "click":