clay-server 4.8.0-beta.6 → 4.8.1-beta.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -165,7 +165,10 @@ function attachSharedBrowser(ctx) {
165
165
  requireAccess(session);
166
166
  if (!record || !record.runtime || !recordAllowed(record)) throw new Error("Open a browser first");
167
167
  if (record.handoff) throw new Error("Browser control is changing; wait for the handoff");
168
- if (action !== "inspect" && record.control !== actor) throw new Error(actor === "agent" ? "The user has temporarily taken control of this browser. Wait for them to restore Clay access; do not work around it." : "Clay has control of this browser. Take control temporarily with the lock before using it.");
168
+ // Only the authorized owner may change the viewport size while Clay controls the tab; every other
169
+ // human input still needs an explicit takeover, and the agent never gets this exemption.
170
+ var viewportResize = actor === "user" && action === "action" && event && event.kind === "resize";
171
+ if (action !== "inspect" && record.control !== actor && !viewportResize) throw new Error(actor === "agent" ? "The user has temporarily taken control of this browser. Wait for them to restore Clay access; do not work around it." : "Clay has control of this browser. Take control temporarily with the lock before using it.");
169
172
  var epoch = record.epoch;
170
173
  var generation = Number(session._sdkQueryGeneration || 0);
171
174
  await record.ready;
@@ -139,7 +139,7 @@ function render() {
139
139
  el.querySelector('.shared-browser-error').textContent = error;
140
140
  el.querySelector('.shared-browser-error').classList.toggle('hidden', !error);
141
141
  el.querySelector('.shared-browser-empty').classList.toggle('hidden', !!(browser && browser.url && state.hasFrame));
142
- renderViewportMenu(el, browser, user);
142
+ renderViewportMenu(el, browser, live && !browser.handoff && connected);
143
143
  renderBrowserActivity(el, browser, connected);
144
144
  layoutMonitor();
145
145
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "clay-server",
3
- "version": "4.8.0-beta.6",
3
+ "version": "4.8.1-beta.1",
4
4
  "description": "Self-hosted team workspace for Claude Code and Codex. Multi-user, browser-based, with persistent AI mates.",
5
5
  "bin": {
6
6
  "clay-server": "./bin/cli.js"