@songsid/agend 2.4.0-beta.5 → 2.4.0-beta.7

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.
Files changed (120) hide show
  1. package/dist/agent-cli-instructions.md +2 -0
  2. package/dist/app-message-origin.d.ts +2 -0
  3. package/dist/app-message-origin.js +3 -0
  4. package/dist/app-message-origin.js.map +1 -0
  5. package/dist/auth-api.js +2 -0
  6. package/dist/auth-api.js.map +1 -1
  7. package/dist/backend-availability.d.ts +22 -0
  8. package/dist/backend-availability.js +71 -2
  9. package/dist/backend-availability.js.map +1 -1
  10. package/dist/build-provenance.json +1 -1
  11. package/dist/channel/adapters/telegram.d.ts +2 -0
  12. package/dist/channel/adapters/telegram.js +3 -0
  13. package/dist/channel/adapters/telegram.js.map +1 -1
  14. package/dist/cli-capability.d.ts +3 -0
  15. package/dist/cli-capability.js.map +1 -1
  16. package/dist/cli-registry-check.js +1 -1
  17. package/dist/cli-registry-check.js.map +1 -1
  18. package/dist/cli-registry.d.ts +1 -0
  19. package/dist/cli-spec-antigravity.d.ts +1 -0
  20. package/dist/cli-spec-antigravity.js +3 -1
  21. package/dist/cli-spec-antigravity.js.map +1 -1
  22. package/dist/cli.js +8 -0
  23. package/dist/cli.js.map +1 -1
  24. package/dist/connect/control.d.ts +20 -0
  25. package/dist/connect/control.js +236 -0
  26. package/dist/connect/control.js.map +1 -0
  27. package/dist/connect/install.d.ts +13 -0
  28. package/dist/connect/install.js +12 -0
  29. package/dist/connect/install.js.map +1 -0
  30. package/dist/connect/protocol.d.ts +38 -0
  31. package/dist/connect/protocol.js +36 -0
  32. package/dist/connect/protocol.js.map +1 -0
  33. package/dist/connect/service.d.ts +19 -0
  34. package/dist/connect/service.js +79 -0
  35. package/dist/connect/service.js.map +1 -0
  36. package/dist/connect/stdio-entry.d.ts +1 -0
  37. package/dist/connect/stdio-entry.js +6 -0
  38. package/dist/connect/stdio-entry.js.map +1 -0
  39. package/dist/connect/stdio.d.ts +5 -0
  40. package/dist/connect/stdio.js +39 -0
  41. package/dist/connect/stdio.js.map +1 -0
  42. package/dist/daemon.js +2 -0
  43. package/dist/daemon.js.map +1 -1
  44. package/dist/fleet-manager.d.ts +12 -1
  45. package/dist/fleet-manager.js +75 -11
  46. package/dist/fleet-manager.js.map +1 -1
  47. package/dist/fleet-windows-runtime.js +4 -2
  48. package/dist/fleet-windows-runtime.js.map +1 -1
  49. package/dist/general-knowledge/skills/cross-instance-messaging/SKILL.md +2 -0
  50. package/dist/general-knowledge/skills/web-dashboard/SKILL.md +15 -1
  51. package/dist/general-knowledge/skills/worker-collaboration/SKILL.md +2 -0
  52. package/dist/hub/group-policy/model.d.ts +23 -0
  53. package/dist/hub/group-policy/model.js +3 -3
  54. package/dist/hub/group-policy/model.js.map +1 -1
  55. package/dist/hub/group-policy/store.js +3 -3
  56. package/dist/hub/group-policy/store.js.map +1 -1
  57. package/dist/hub/group-policy/team-subjects.d.ts +1 -1
  58. package/dist/hub/group-policy/team-subjects.js +1 -1
  59. package/dist/hub/group-policy/team-subjects.js.map +1 -1
  60. package/dist/hub/http/compose.js +3 -0
  61. package/dist/hub/http/compose.js.map +1 -1
  62. package/dist/hub/roles/change.js +4 -0
  63. package/dist/hub/roles/change.js.map +1 -1
  64. package/dist/hub/roles/convert.js +1 -1
  65. package/dist/hub/roles/convert.js.map +1 -1
  66. package/dist/hub/roles/delegation.js +4 -0
  67. package/dist/hub/roles/delegation.js.map +1 -1
  68. package/dist/hub/roles/evaluate.d.ts +2 -1
  69. package/dist/hub/roles/evaluate.js +14 -0
  70. package/dist/hub/roles/evaluate.js.map +1 -1
  71. package/dist/hub/roles/model.d.ts +23 -0
  72. package/dist/hub/roles/model.js +7 -2
  73. package/dist/hub/roles/model.js.map +1 -1
  74. package/dist/human-delivery-receipts.js +8 -0
  75. package/dist/human-delivery-receipts.js.map +1 -1
  76. package/dist/instructions.js +3 -0
  77. package/dist/instructions.js.map +1 -1
  78. package/dist/locale.js +50 -0
  79. package/dist/locale.js.map +1 -1
  80. package/dist/runtime-personal-answer.d.ts +25 -0
  81. package/dist/runtime-personal-answer.js +115 -0
  82. package/dist/runtime-personal-answer.js.map +1 -0
  83. package/dist/runtime-personal-profile.d.ts +34 -0
  84. package/dist/runtime-personal-profile.js +61 -0
  85. package/dist/runtime-personal-profile.js.map +1 -0
  86. package/dist/settings-api.js +5 -0
  87. package/dist/settings-api.js.map +1 -1
  88. package/dist/tool-progress.d.ts +9 -0
  89. package/dist/tool-progress.js +141 -32
  90. package/dist/tool-progress.js.map +1 -1
  91. package/dist/turn-reply-guard.d.ts +2 -2
  92. package/dist/turn-reply-guard.js +3 -3
  93. package/dist/turn-reply-guard.js.map +1 -1
  94. package/dist/ui/fleet-office-skin.js +1 -1
  95. package/dist/ui/hub-quick-pairing.js +7 -2
  96. package/dist/ui/panel-settings.js +2 -1
  97. package/dist/ui/settings-connector-strings.js +23 -0
  98. package/dist/ui/settings-connector.js +39 -0
  99. package/dist/ui/shared/app-shell.js +28 -8
  100. package/dist/ui/shared/app-themes.js +2 -2
  101. package/dist/ui/shared/app.css +207 -139
  102. package/dist/ui/shared/chat-composer.js +23 -2
  103. package/dist/ui/shared/chat-thread.js +3 -3
  104. package/dist/ui/shared/chat-work-bar.css +9 -1
  105. package/dist/ui/shared/connector-prompt.d.ts +2 -0
  106. package/dist/ui/shared/connector-prompt.js +10 -0
  107. package/dist/ui/shared/hub-chat.css +1 -1
  108. package/dist/ui/shared/hub-owner.css +1 -1
  109. package/dist/ui/shared/hub.css +5 -0
  110. package/dist/ui/shared/image-lightbox.js +35 -10
  111. package/dist/ui/shared/image-zoom.js +61 -9
  112. package/dist/ui/shared/instance-nav.js +35 -6
  113. package/dist/ui/shared/settings-connector.css +7 -0
  114. package/dist/ui/shared/theme.js +52 -0
  115. package/dist/ui/shared/tokens.css +27 -10
  116. package/dist/ui/shared/view-strings.js +6 -0
  117. package/dist/web-icons.js +3 -3
  118. package/dist/web-icons.js.map +1 -1
  119. package/dist/web-theme.js +2 -2
  120. package/package.json +1 -1
@@ -17,7 +17,7 @@ import { applyPageTheme, pageNow, resolvedMode, themesStore } from "./app-themes
17
17
  import { ErrorState, Skeleton } from "./ui-states.js";
18
18
  import { StaleTabPrompt, isStaleModuleError } from "./stale-tab.js";
19
19
  import { Dialog } from "./ui-dialog.js";
20
- import { InstanceNav, RosterNav, namesStore, setNamesPrimary, sidebarDensityStore, setSidebarDensity } from "./instance-nav.js";
20
+ import { InstanceNav, RosterNav, namesStore, phoneDrawerStore, setNamesPrimary, sidebarDensityStore, setSidebarDensity } from "./instance-nav.js";
21
21
  import { usageRailStore } from "./header-tools.js";
22
22
  import { RightRail, sidePanelStore } from "./side-panel.js";
23
23
  import { OwnerCssKeepBar } from "./owner-css.js";
@@ -405,6 +405,8 @@ function MemberPairingNoticesSlot() {
405
405
 
406
406
  function Sidebar({ route, onNewInstance, viewOnly }) {
407
407
  const app = useStore(appStore);
408
+ // M-3212: 窄版 — the phone's drawer as it was before M-3211 (app.css; a desk never shows the drawer).
409
+ const narrowDrawer = useStore(phoneDrawerStore).value === "narrow";
408
410
  const shell = useStore(shellStore);
409
411
  const canCreate = useCanCreate();
410
412
  const on = (panel) => !!route && route.panel === panel;
@@ -455,10 +457,10 @@ function Sidebar({ route, onNewInstance, viewOnly }) {
455
457
  const onFleet = !!route && route.panel === "fleet";
456
458
  const overview = html`<a class=${`side-row side-overview${onFleet ? " active" : ""}`} href=${fleetEntryPath(route)}
457
459
  aria-current=${onFleet ? "page" : undefined} onClick=${closeDrawer}><${Icon} name="org" /><span class="grow">${t("app.fleetOverview")}</span></a>`;
458
- return html`<aside id="sidebar" class="sidebar fleet-side" aria-label=${t("app.menu")}>
460
+ return html`<aside id="sidebar" class=${`sidebar fleet-side${narrowDrawer ? " drawer-narrow" : ""}`} aria-label=${t("app.menu")}>
459
461
  <div class="side-head" data-trust="navigation">
460
462
  <a class="brand" href="/ui" onClick=${closeDrawer}>${t("app.brand")}</a>
461
- <button type="button" class="icon-btn side-collapse" onClick=${toggleSidebar} aria-label=${narrow() ? t("app.closeMenu") : t("app.collapse")} title=${narrow() ? t("app.closeMenu") : t("app.collapse")} aria-controls="sidebar"><${Icon} name="sidebar" /></button>
463
+ <button type="button" class="icon-btn side-collapse" onClick=${toggleSidebar} aria-label=${narrow() ? t("app.closeMenu") : t("app.collapse")} title=${narrow() ? t("app.closeMenu") : t("app.collapse")} aria-controls="sidebar"><${Icon} name="sidebar" cls="ic-sidebar" /><${Icon} name="back" cls="ic-back" /></button>
462
464
  </div>
463
465
  ${/* AgEnD Hub P1: a member fleet's "My fleet ↔ Hub" (shown once paired; nothing loads when the switch is off) */ hubMarks().member ? html`<${HubSwitcherSlot} />` : null}
464
466
  <nav data-trust="navigation" class="side-nav" aria-label=${t("app.menu")}>
@@ -470,7 +472,7 @@ function Sidebar({ route, onNewInstance, viewOnly }) {
470
472
  ${canCreate && onNewInstance ? html`<button type="button" class="side-row side-new" onClick=${onNewInstance}><${Icon} name="plus" /><span class="grow">${t("app.newAgent")}</span></button>` : null}
471
473
  </nav>
472
474
  ${shell.side ? html`<${shell.side.Component} />` : html`<${InstanceNav} route=${route} items=${app.instances} loaded=${app.ready !== false}
473
- exec=${app.exec} awaiting=${app.awaiting} onPick=${closeDrawer} />`}
475
+ exec=${app.exec} awaiting=${app.awaiting} onPick=${closeDrawer} onNew=${canCreate && onNewInstance ? onNewInstance : null} />`}
474
476
  <${SidebarWidget} app=${app} />
475
477
  <div class="side-foot" data-trust="navigation">
476
478
  ${navLink("settings", settingsPath(), "settings", t("app.settings"))}
@@ -1253,7 +1255,13 @@ export function Shell({ panels, onNewInstance, viewOnly = false }) {
1253
1255
  // The keyboard rises and falls over a few hundred ms, and the view's resize comes when it has settled (iOS): for that
1254
1256
  // long after a field gains or loses focus the shell follows the view every frame — both ways — instead of jumping.
1255
1257
  const FOLLOW_MS = 800;
1256
- let raf = 0, followUntil = 0, fitH = 0;
1258
+ // M-3206 (the user, iPhone, beta.5): with "down" on hold, typing still flickered. While typing, iOS reports the view a
1259
+ // little differently from key to key (the suggestion bar, a few px of pan) and the shell followed each reading — its
1260
+ // height and its place — so the box (and what is above it) moved on every key and back. Once the keyboard has settled
1261
+ // (past the follow window, the field still focused, the same width), the shell's height and place change only when a
1262
+ // new reading has held for DOWN_HOLD_MS; one that comes and goes with a keystroke moves nothing. The keyboard coming up
1263
+ // (the view a keyboard shorter) and a turn (a new width) are followed at once.
1264
+ let raf = 0, followUntil = 0, fitH = 0, fitTop = 0, fitW = -1, moveSince = 0, moveTimer = 0;
1257
1265
  const now = () => (typeof performance !== "undefined" ? performance.now() : Date.now());
1258
1266
  const frame = typeof requestAnimationFrame === "function" ? requestAnimationFrame : null;
1259
1267
  const unfit = (el) => { if (el?.style) { el.style.removeProperty("height"); el.style.removeProperty("transform"); } };
@@ -1264,13 +1272,24 @@ export function Shell({ panels, onNewInstance, viewOnly = false }) {
1264
1272
  // says for the moment: a reading that dips must not hand the height back to the stylesheet for one frame.
1265
1273
  const typingNow = coarse() && isTextEntry(document.activeElement);
1266
1274
  const on = coarse() && (shellStore.get().keyboard || typingNow || now() < followUntil) && Math.abs((Number(vv.scale) || 1) - 1) < 0.01;
1267
- if (!on) { unfit(el); fitH = 0; return; }
1275
+ if (!on) { unfit(el); fitH = 0; fitTop = 0; fitW = -1; moveSince = 0; return; }
1276
+ const h = Math.round(vv.height), top = Math.max(0, Math.round(Number(vv.offsetTop) || 0)), w = Math.round(vv.width);
1277
+ const settled = fitH && typingNow && w === fitW && now() >= followUntil;
1278
+ if (settled && (h !== fitH || top !== fitTop) && !(fitH - h > KEYBOARD_MIN_PX)) {
1279
+ if (!moveSince) moveSince = now();
1280
+ const left = DOWN_HOLD_MS - (now() - moveSince);
1281
+ if (left > 0) { // not held yet: the shell stays as it is
1282
+ if (!moveTimer && typeof setTimeout === "function") moveTimer = setTimeout(() => { moveTimer = 0; fit(); }, left + 20);
1283
+ return;
1284
+ }
1285
+ }
1286
+ moveSince = 0;
1268
1287
  // A reading that says "down" while the field keeps focus is on hold (below): until it holds, the shell keeps the height
1269
1288
  // it had, so the box does not drop under a keyboard that is still there.
1270
1289
  const pending = downSince && now() - downSince < DOWN_HOLD_MS && fitH;
1271
- fitH = pending ? fitH : Math.round(vv.height);
1290
+ fitH = pending ? fitH : h;
1291
+ fitTop = top; fitW = w;
1272
1292
  el.style.setProperty("height", `${fitH}px`);
1273
- const top = Math.max(0, Math.round(Number(vv.offsetTop) || 0));
1274
1293
  if (top) el.style.setProperty("transform", `translateY(${top}px)`); else el.style.removeProperty("transform");
1275
1294
  };
1276
1295
  const follow = () => {
@@ -1322,6 +1341,7 @@ export function Shell({ panels, onNewInstance, viewOnly = false }) {
1322
1341
  vv.removeEventListener("resize", check); vv.removeEventListener("scroll", fit); document.removeEventListener("focusin", focusChanged); document.removeEventListener("focusout", focusChanged);
1323
1342
  if (raf && typeof cancelAnimationFrame === "function") cancelAnimationFrame(raf);
1324
1343
  if (downTimer && typeof clearTimeout === "function") clearTimeout(downTimer);
1344
+ if (moveTimer && typeof clearTimeout === "function") clearTimeout(moveTimer);
1325
1345
  unfit(root.current);
1326
1346
  document.removeEventListener("compositionstart", start, true); document.removeEventListener("compositionend", end, true);
1327
1347
  };
@@ -101,8 +101,8 @@ export function themeFor(name) {
101
101
 
102
102
  /** The token defaults (tokens.css; web-theme.ts THEME_DEFAULTS, pinned by a test) a theme's palette goes over. */
103
103
  const PAGE_DEFAULTS = {
104
- dark: { bg: "#212121", surface: "#2f2f2f", text: "#ececec", text2: "#b4b4b4", accent: "#7ab7ff" },
105
- light: { bg: "#ffffff", surface: "#f4f4f4", text: "#0d0d0d", text2: "#5d5d5d", accent: "#0a62c2" },
104
+ dark: { bg: "#212121", surface: "#2f2f2f", text: "#ececec", text2: "#cfcfcf", accent: "#7ab7ff" },
105
+ light: { bg: "#ffffff", surface: "#f4f4f4", text: "#0d0d0d", text2: "#4d4d4d", accent: "#0a62c2" },
106
106
  };
107
107
  /** AgEnD's status colours (tokens.css; web-theme.ts STATUS_COLORS, pinned by a test): never themed, always readable. */
108
108
  export const STATUS_COLORS = {