You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Potentially out of scope as it is related to the navigator.modelContextTesting - When executeTool updates the UI normal hooks to pick up on changes to input values don't work. change and input events explicitly call out user interactions and MutationObservers won't pick up the change because element.value changes aren't DOM changes. This leaves no common way to watch for MCP driven changes resulting in potential UI desync which could hamper AI/Human hybrid workflows.
This was specifically when using the Declarative API. It may be possible in the imperative API to manually fire onChange or onInput handlers there's not a great way to hook that up in Declarative.
I'm not a browser internals expert - but the most naive approach would be flagging the changes by executeTool as user interaction which would hook into the usual event cycle. Another option could be to add an attribute data-tool-call-updated=[uuid] (or use an appropriate tooluse attribute) which would allow watching for DOM changes using a mutation observer.
This bit of Javascript allows you to know when a tool was activated:
window.addEventListener('toolactivated',({ toolName })=>{console.log(`the tool "${toolName}" execution was activated.`);// TODO: Update UI or validate form if needed.});window.addEventListener('toolcancel',({ toolName })=>{console.log(`the tool "${toolName}" execution was cancelled.`);// TODO: Let the user know. Update UI.});
It does, normally I'd like to see it trigger normal input events so it's behavior on behalf of users is treated the same as the user's own behavior. But I also understand these are not user interactions. It's frustrating to have to add extra hooks to reflect updates but pages opt into this functionality anyway.
Activity
beaufortfrancois commentedon Feb 23, 2026
This bit of Javascript allows you to know when a tool was activated:
Does this help?
schreiaj commentedon Feb 23, 2026
It does, normally I'd like to see it trigger normal input events so it's behavior on behalf of users is treated the same as the user's own behavior. But I also understand these are not user interactions. It's frustrating to have to add extra hooks to reflect updates but pages opt into this functionality anyway.