@songsid/agend 2.4.0-beta.23 → 2.4.0-beta.25

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 (499) hide show
  1. package/README.md +1 -1
  2. package/README.zh-TW.md +1 -1
  3. package/dist/agend-home.js +5 -5
  4. package/dist/agend-home.js.map +1 -1
  5. package/dist/agent-cli-instructions.md +4 -3
  6. package/dist/agent-cli.js +32 -2
  7. package/dist/agent-cli.js.map +1 -1
  8. package/dist/agent-endpoint.js +10 -0
  9. package/dist/agent-endpoint.js.map +1 -1
  10. package/dist/agent-file-read.js +2 -2
  11. package/dist/agent-file-read.js.map +1 -1
  12. package/dist/agent-whats-new.js +11 -1
  13. package/dist/agent-whats-new.js.map +1 -1
  14. package/dist/agent-workspace.d.ts +18 -2
  15. package/dist/agent-workspace.js +15 -4
  16. package/dist/agent-workspace.js.map +1 -1
  17. package/dist/backend/antigravity.js +8 -6
  18. package/dist/backend/antigravity.js.map +1 -1
  19. package/dist/backend/claude-code.d.ts +15 -0
  20. package/dist/backend/claude-code.js +25 -3
  21. package/dist/backend/claude-code.js.map +1 -1
  22. package/dist/backend/claude-mcp-carry.d.ts +63 -0
  23. package/dist/backend/claude-mcp-carry.js +242 -0
  24. package/dist/backend/claude-mcp-carry.js.map +1 -0
  25. package/dist/backend/claude-usage-credits.d.ts +8 -0
  26. package/dist/backend/claude-usage-credits.js +121 -0
  27. package/dist/backend/claude-usage-credits.js.map +1 -0
  28. package/dist/backend/types.d.ts +30 -0
  29. package/dist/backend/types.js.map +1 -1
  30. package/dist/build-provenance.json +1 -1
  31. package/dist/channel/adapters/discord.js +7 -1
  32. package/dist/channel/adapters/discord.js.map +1 -1
  33. package/dist/channel/mcp-tools.js +7 -6
  34. package/dist/channel/mcp-tools.js.map +1 -1
  35. package/dist/channel/tool-router.js +1 -0
  36. package/dist/channel/tool-router.js.map +1 -1
  37. package/dist/cli-audited.js +9 -4
  38. package/dist/cli-audited.js.map +1 -1
  39. package/dist/cli.js +184 -21
  40. package/dist/cli.js.map +1 -1
  41. package/dist/config-validator.js +17 -1
  42. package/dist/config-validator.js.map +1 -1
  43. package/dist/config.js +2 -0
  44. package/dist/config.js.map +1 -1
  45. package/dist/contact-auth-store.d.ts +18 -0
  46. package/dist/contact-auth-store.js +55 -8
  47. package/dist/contact-auth-store.js.map +1 -1
  48. package/dist/contact-auth-types.d.ts +3 -0
  49. package/dist/contact-auth-types.js.map +1 -1
  50. package/dist/contact-change-proposals.d.ts +34 -0
  51. package/dist/contact-change-proposals.js +1 -1
  52. package/dist/contact-change-proposals.js.map +1 -1
  53. package/dist/cross-instance-notice.d.ts +1 -0
  54. package/dist/cross-instance-notice.js +9 -8
  55. package/dist/cross-instance-notice.js.map +1 -1
  56. package/dist/daemon.d.ts +46 -0
  57. package/dist/daemon.js +299 -33
  58. package/dist/daemon.js.map +1 -1
  59. package/dist/dashboard-permissions.d.ts +8 -0
  60. package/dist/dashboard-permissions.js +8 -0
  61. package/dist/dashboard-permissions.js.map +1 -1
  62. package/dist/delivery-outbox.d.ts +56 -1
  63. package/dist/delivery-outbox.js +254 -22
  64. package/dist/delivery-outbox.js.map +1 -1
  65. package/dist/fleet-context.d.ts +8 -0
  66. package/dist/fleet-lock.d.ts +67 -2
  67. package/dist/fleet-lock.js +236 -2
  68. package/dist/fleet-lock.js.map +1 -1
  69. package/dist/fleet-manager.d.ts +177 -6
  70. package/dist/fleet-manager.js +1203 -75
  71. package/dist/fleet-manager.js.map +1 -1
  72. package/dist/fleet-windows-runtime.d.ts +20 -1
  73. package/dist/fleet-windows-runtime.js +98 -18
  74. package/dist/fleet-windows-runtime.js.map +1 -1
  75. package/dist/general-knowledge/skills/concepts/SKILL.md +22 -9
  76. package/dist/general-knowledge/skills/credential-profiles/SKILL.md +6 -0
  77. package/dist/general-knowledge/skills/cross-instance-messaging/SKILL.md +7 -0
  78. package/dist/general-knowledge/skills/fleet-config/SKILL.md +3 -3
  79. package/dist/general-knowledge/skills/instance-lifecycle/SKILL.md +1 -1
  80. package/dist/general-knowledge/skills/task-board/SKILL.md +17 -0
  81. package/dist/general-knowledge/skills/web-appearance/SKILL.md +4 -0
  82. package/dist/general-knowledge/skills/web-dashboard/SKILL.md +35 -7
  83. package/dist/home-update-lock.d.ts +35 -0
  84. package/dist/home-update-lock.js +81 -0
  85. package/dist/home-update-lock.js.map +1 -0
  86. package/dist/hub/compose/member.d.ts +5 -1
  87. package/dist/hub/compose/member.js +9 -5
  88. package/dist/hub/compose/member.js.map +1 -1
  89. package/dist/hub/group-policy/resources.d.ts +1 -1
  90. package/dist/hub/member/room-ask.d.ts +5 -0
  91. package/dist/hub/member/room-ask.js +43 -16
  92. package/dist/hub/member/room-ask.js.map +1 -1
  93. package/dist/hub/member/room-mention-feedback.d.ts +2 -0
  94. package/dist/hub/member/room-mention-feedback.js +1 -1
  95. package/dist/hub/member/room-mention-feedback.js.map +1 -1
  96. package/dist/hub/member/room-post-answers.d.ts +2 -0
  97. package/dist/hub/member/room-post-answers.js +1 -1
  98. package/dist/hub/member/room-post-answers.js.map +1 -1
  99. package/dist/hub/member/room-post.d.ts +5 -0
  100. package/dist/hub/member/room-post.js +4 -1
  101. package/dist/hub/member/room-post.js.map +1 -1
  102. package/dist/hub/member/updates.d.ts +7 -1
  103. package/dist/hub/member/updates.js +7 -1
  104. package/dist/hub/member/updates.js.map +1 -1
  105. package/dist/hub/representative.d.ts +7 -0
  106. package/dist/hub/representative.js +38 -5
  107. package/dist/hub/representative.js.map +1 -1
  108. package/dist/install-lock.d.ts +15 -1
  109. package/dist/install-lock.js +16 -8
  110. package/dist/install-lock.js.map +1 -1
  111. package/dist/install-ownership.d.ts +165 -0
  112. package/dist/install-ownership.js +404 -0
  113. package/dist/install-ownership.js.map +1 -0
  114. package/dist/instance-config-impact.js +2 -0
  115. package/dist/instance-config-impact.js.map +1 -1
  116. package/dist/instance-lifecycle.d.ts +2 -0
  117. package/dist/instance-lifecycle.js +29 -1
  118. package/dist/instance-lifecycle.js.map +1 -1
  119. package/dist/instructions.d.ts +4 -0
  120. package/dist/instructions.js +4 -0
  121. package/dist/instructions.js.map +1 -1
  122. package/dist/local-pane-endpoint.d.ts +4 -1
  123. package/dist/local-pane-endpoint.js +12 -2
  124. package/dist/local-pane-endpoint.js.map +1 -1
  125. package/dist/locale.js +170 -4
  126. package/dist/locale.js.map +1 -1
  127. package/dist/native-agent-admission.d.ts +7 -0
  128. package/dist/native-agent-admission.js +46 -3
  129. package/dist/native-agent-admission.js.map +1 -1
  130. package/dist/native-mcp.d.ts +16 -1
  131. package/dist/native-mcp.js +38 -5
  132. package/dist/native-mcp.js.map +1 -1
  133. package/dist/native-pane-lifecycle.d.ts +9 -0
  134. package/dist/native-pane-lifecycle.js +23 -0
  135. package/dist/native-pane-lifecycle.js.map +1 -1
  136. package/dist/native-pane-manager.d.ts +19 -6
  137. package/dist/native-pane-manager.js +79 -4
  138. package/dist/native-pane-manager.js.map +1 -1
  139. package/dist/needs-you-hub.d.ts +3 -0
  140. package/dist/needs-you-hub.js +31 -5
  141. package/dist/needs-you-hub.js.map +1 -1
  142. package/dist/needs-you.d.ts +22 -1
  143. package/dist/needs-you.js +6 -0
  144. package/dist/needs-you.js.map +1 -1
  145. package/dist/office-share-page.js +1 -1
  146. package/dist/office-share-page.js.map +1 -1
  147. package/dist/office-share.js +2 -1
  148. package/dist/office-share.js.map +1 -1
  149. package/dist/outbound-handlers.d.ts +12 -0
  150. package/dist/outbound-handlers.js +59 -8
  151. package/dist/outbound-handlers.js.map +1 -1
  152. package/dist/outbound-schemas.d.ts +3 -0
  153. package/dist/outbound-schemas.js +7 -5
  154. package/dist/outbound-schemas.js.map +1 -1
  155. package/dist/package-preimage.js +4 -0
  156. package/dist/package-preimage.js.map +1 -1
  157. package/dist/pane-port.d.ts +1 -0
  158. package/dist/plist-args.d.ts +9 -0
  159. package/dist/plist-args.js +22 -0
  160. package/dist/plist-args.js.map +1 -0
  161. package/dist/public-preview.d.ts +4 -6
  162. package/dist/public-preview.js +5 -2
  163. package/dist/public-preview.js.map +1 -1
  164. package/dist/public-web-gateway.js +11 -3
  165. package/dist/public-web-gateway.js.map +1 -1
  166. package/dist/public-web-link.d.ts +13 -1
  167. package/dist/public-web-link.js +28 -1
  168. package/dist/public-web-link.js.map +1 -1
  169. package/dist/recover.cjs +2452 -0
  170. package/dist/remote-card-prompt.d.ts +6 -2
  171. package/dist/remote-card-prompt.js +12 -3
  172. package/dist/remote-card-prompt.js.map +1 -1
  173. package/dist/reply-draft.d.ts +12 -0
  174. package/dist/reply-draft.js +81 -0
  175. package/dist/reply-draft.js.map +1 -0
  176. package/dist/request-contact-api.d.ts +15 -0
  177. package/dist/request-contact-api.js +120 -0
  178. package/dist/request-contact-api.js.map +1 -0
  179. package/dist/request-contact-card.d.ts +36 -0
  180. package/dist/request-contact-card.js +206 -0
  181. package/dist/request-contact-card.js.map +1 -0
  182. package/dist/request-contact-gate.d.ts +79 -0
  183. package/dist/request-contact-gate.js +262 -0
  184. package/dist/request-contact-gate.js.map +1 -0
  185. package/dist/request-contact-native.d.ts +52 -0
  186. package/dist/request-contact-native.js +83 -0
  187. package/dist/request-contact-native.js.map +1 -0
  188. package/dist/request-contact-types.d.ts +86 -0
  189. package/dist/request-contact-types.js +7 -0
  190. package/dist/request-contact-types.js.map +1 -0
  191. package/dist/request-context-call-protocol.d.ts +12 -0
  192. package/dist/request-context-call-protocol.js +14 -0
  193. package/dist/request-context-call-protocol.js.map +1 -0
  194. package/dist/request-context-call.d.ts +22 -0
  195. package/dist/request-context-call.js +35 -0
  196. package/dist/request-context-call.js.map +1 -0
  197. package/dist/request-context-compatibility.d.ts +20 -0
  198. package/dist/request-context-compatibility.js +74 -0
  199. package/dist/request-context-compatibility.js.map +1 -0
  200. package/dist/request-context-drain.d.ts +39 -0
  201. package/dist/request-context-drain.js +159 -0
  202. package/dist/request-context-drain.js.map +1 -0
  203. package/dist/request-context-fence.d.ts +28 -0
  204. package/dist/request-context-fence.js +58 -0
  205. package/dist/request-context-fence.js.map +1 -0
  206. package/dist/request-context-migration.d.ts +64 -0
  207. package/dist/request-context-migration.js +158 -0
  208. package/dist/request-context-migration.js.map +1 -0
  209. package/dist/request-context-pane.d.ts +25 -0
  210. package/dist/request-context-pane.js +48 -0
  211. package/dist/request-context-pane.js.map +1 -0
  212. package/dist/request-context-policy.d.ts +74 -0
  213. package/dist/request-context-policy.js +116 -0
  214. package/dist/request-context-policy.js.map +1 -0
  215. package/dist/request-context-protocol.d.ts +137 -0
  216. package/dist/request-context-protocol.js +38 -0
  217. package/dist/request-context-protocol.js.map +1 -0
  218. package/dist/request-context-recovery.d.ts +14 -0
  219. package/dist/request-context-recovery.js +56 -0
  220. package/dist/request-context-recovery.js.map +1 -0
  221. package/dist/request-context-relay.d.ts +19 -0
  222. package/dist/request-context-relay.js +63 -0
  223. package/dist/request-context-relay.js.map +1 -0
  224. package/dist/request-context-returns.d.ts +67 -0
  225. package/dist/request-context-returns.js +211 -0
  226. package/dist/request-context-returns.js.map +1 -0
  227. package/dist/request-context-store.d.ts +26 -0
  228. package/dist/request-context-store.js +144 -0
  229. package/dist/request-context-store.js.map +1 -0
  230. package/dist/request-context-turns.d.ts +99 -0
  231. package/dist/request-context-turns.js +215 -0
  232. package/dist/request-context-turns.js.map +1 -0
  233. package/dist/request-context-view.d.ts +33 -0
  234. package/dist/request-context-view.js +36 -0
  235. package/dist/request-context-view.js.map +1 -0
  236. package/dist/request-hub-context.d.ts +130 -0
  237. package/dist/request-hub-context.js +89 -0
  238. package/dist/request-hub-context.js.map +1 -0
  239. package/dist/request-hub-output.d.ts +11 -0
  240. package/dist/request-hub-output.js +21 -0
  241. package/dist/request-hub-output.js.map +1 -0
  242. package/dist/runtime-cli-install.js +13 -11
  243. package/dist/runtime-cli-install.js.map +1 -1
  244. package/dist/runtime-client.d.ts +2 -0
  245. package/dist/runtime-client.js +17 -4
  246. package/dist/runtime-client.js.map +1 -1
  247. package/dist/runtime-coordinator.d.ts +4 -1
  248. package/dist/runtime-coordinator.js +10 -3
  249. package/dist/runtime-coordinator.js.map +1 -1
  250. package/dist/runtime-pane-assets.d.ts +1 -1
  251. package/dist/runtime-pane-assets.js +1 -1
  252. package/dist/runtime-pane-assets.js.map +1 -1
  253. package/dist/runtime-pane-host.d.ts +3 -0
  254. package/dist/runtime-pane-host.js +39 -21
  255. package/dist/runtime-pane-host.js.map +1 -1
  256. package/dist/runtime-pane-link.d.ts +6 -2
  257. package/dist/runtime-pane-link.js +17 -4
  258. package/dist/runtime-pane-link.js.map +1 -1
  259. package/dist/runtime-pane-mcp-relay.d.ts +11 -1
  260. package/dist/runtime-pane-mcp-relay.js +69 -3
  261. package/dist/runtime-pane-mcp-relay.js.map +1 -1
  262. package/dist/runtime-pane-mcp.d.ts +28 -1
  263. package/dist/runtime-pane-mcp.js +92 -15
  264. package/dist/runtime-pane-mcp.js.map +1 -1
  265. package/dist/runtime-pane-port.d.ts +6 -0
  266. package/dist/runtime-pane-port.js +23 -4
  267. package/dist/runtime-pane-port.js.map +1 -1
  268. package/dist/runtime-pane-protocol.d.ts +4 -0
  269. package/dist/runtime-pane-protocol.js +11 -4
  270. package/dist/runtime-pane-protocol.js.map +1 -1
  271. package/dist/runtime-pane-service.d.ts +1 -0
  272. package/dist/runtime-pane-service.js +25 -9
  273. package/dist/runtime-pane-service.js.map +1 -1
  274. package/dist/runtime-pane-stdio-protocol.d.ts +4 -0
  275. package/dist/runtime-pane-stdio-protocol.js +12 -5
  276. package/dist/runtime-pane-stdio-protocol.js.map +1 -1
  277. package/dist/runtime-pane-stdio.js +5 -5
  278. package/dist/runtime-pane-stdio.js.map +1 -1
  279. package/dist/runtime-protocol.d.ts +3 -0
  280. package/dist/runtime-protocol.js.map +1 -1
  281. package/dist/scheduler/db.js +26 -0
  282. package/dist/scheduler/db.js.map +1 -1
  283. package/dist/scheduler/scheduler.d.ts +6 -0
  284. package/dist/scheduler/scheduler.js +19 -1
  285. package/dist/scheduler/scheduler.js.map +1 -1
  286. package/dist/scheduler/task-board-text.d.ts +2 -0
  287. package/dist/scheduler/task-board-text.js +12 -0
  288. package/dist/scheduler/task-board-text.js.map +1 -1
  289. package/dist/scheduler/task-board.d.ts +106 -2
  290. package/dist/scheduler/task-board.js +248 -24
  291. package/dist/scheduler/task-board.js.map +1 -1
  292. package/dist/scheduler/task-files.d.ts +80 -0
  293. package/dist/scheduler/task-files.js +357 -0
  294. package/dist/scheduler/task-files.js.map +1 -0
  295. package/dist/scheduler/types.d.ts +1 -1
  296. package/dist/service-activation.js +3 -13
  297. package/dist/service-activation.js.map +1 -1
  298. package/dist/service-lock.d.ts +28 -0
  299. package/dist/service-lock.js +85 -0
  300. package/dist/service-lock.js.map +1 -0
  301. package/dist/settings-api.d.ts +8 -0
  302. package/dist/settings-api.js +41 -1
  303. package/dist/settings-api.js.map +1 -1
  304. package/dist/settings-baseline.d.ts +1 -0
  305. package/dist/settings-baseline.js +1 -1
  306. package/dist/settings-baseline.js.map +1 -1
  307. package/dist/settings-change.js +1 -1
  308. package/dist/settings-change.js.map +1 -1
  309. package/dist/settings-effect.d.ts +2 -0
  310. package/dist/settings-effect.js +5 -1
  311. package/dist/settings-effect.js.map +1 -1
  312. package/dist/state-lease.d.ts +24 -0
  313. package/dist/state-lease.js +103 -0
  314. package/dist/state-lease.js.map +1 -0
  315. package/dist/task-attach-client.d.ts +43 -0
  316. package/dist/task-attach-client.js +125 -0
  317. package/dist/task-attach-client.js.map +1 -0
  318. package/dist/task-board-tool.d.ts +12 -0
  319. package/dist/task-board-tool.js +107 -6
  320. package/dist/task-board-tool.js.map +1 -1
  321. package/dist/task-file-limits.d.ts +15 -0
  322. package/dist/task-file-limits.js +21 -0
  323. package/dist/task-file-limits.js.map +1 -0
  324. package/dist/tmux-binary.js +1 -1
  325. package/dist/tmux-binary.js.map +1 -1
  326. package/dist/tool-permissions.d.ts +32 -0
  327. package/dist/tool-permissions.js +63 -0
  328. package/dist/tool-permissions.js.map +1 -1
  329. package/dist/tool-receipt-output.d.ts +2 -0
  330. package/dist/topic-commands.js +21 -1
  331. package/dist/topic-commands.js.map +1 -1
  332. package/dist/transcript-monitor.js +3 -0
  333. package/dist/transcript-monitor.js.map +1 -1
  334. package/dist/tunnel/named-link-test.d.ts +27 -0
  335. package/dist/tunnel/named-link-test.js +41 -0
  336. package/dist/tunnel/named-link-test.js.map +1 -1
  337. package/dist/types.d.ts +13 -0
  338. package/dist/ui/agent-details-settings.js +7 -5
  339. package/dist/ui/agent-who-can-use-strings.js +125 -0
  340. package/dist/ui/agent-who-can-use.js +238 -0
  341. package/dist/ui/chat-store.js +5 -4
  342. package/dist/ui/fleet-office-card.js +37 -6
  343. package/dist/ui/fleet-office-editor.js +5 -5
  344. package/dist/ui/fleet-office-pack.d.ts +10 -0
  345. package/dist/ui/fleet-office-pack.js +65 -2
  346. package/dist/ui/fleet-office-skin.js +75 -17
  347. package/dist/ui/fleet-office-store.js +33 -2
  348. package/dist/ui/fleet-office-vehicles.js +130 -0
  349. package/dist/ui/fleet-office-zones.js +13 -4
  350. package/dist/ui/fleet-office.js +245 -46
  351. package/dist/ui/fleet-task-activity.js +9 -82
  352. package/dist/ui/fleet-task-archive.js +111 -0
  353. package/dist/ui/fleet-task-card.js +6 -4
  354. package/dist/ui/fleet-task-common.js +2 -2
  355. package/dist/ui/fleet-task-edit.js +8 -1
  356. package/dist/ui/fleet-task-files.js +196 -0
  357. package/dist/ui/fleet-task-md.js +98 -0
  358. package/dist/ui/fleet-task-menu.js +1 -1
  359. package/dist/ui/fleet-task-stats.js +2 -2
  360. package/dist/ui/fleet-task-view.js +12 -8
  361. package/dist/ui/fleet-tasks.js +42 -18
  362. package/dist/ui/panel-chat.js +15 -2
  363. package/dist/ui/panel-details.js +3 -1
  364. package/dist/ui/panel-needs.js +25 -5
  365. package/dist/ui/panel-settings.js +37 -9
  366. package/dist/ui/settings-preview-address.js +156 -0
  367. package/dist/ui/settings-registry.js +3 -0
  368. package/dist/ui/settings-shared-strings.js +9 -0
  369. package/dist/ui/settings-shared.js +6 -1
  370. package/dist/ui/settings-strings.js +6 -6
  371. package/dist/ui/shared/app-i18n.js +2 -2
  372. package/dist/ui/shared/app-needs.js +8 -1
  373. package/dist/ui/shared/app.css +131 -5
  374. package/dist/ui/shared/chat-strings.js +10 -6
  375. package/dist/ui/shared/chat-thread.js +7 -1
  376. package/dist/ui/shared/preview-panel.js +1 -1
  377. package/dist/ui/shared/preview.js +11 -2
  378. package/dist/ui/shared/task-board.css +64 -0
  379. package/dist/ui/shared/tokens.css +18 -3
  380. package/dist/ui/shared/ui-confirm.js +5 -4
  381. package/dist/ui/shared/workspace.css +7 -0
  382. package/dist/ui/usage-credits-card.js +84 -0
  383. package/dist/ui/workspace-ignored-strings.js +16 -0
  384. package/dist/ui/workspace-panel.js +15 -6
  385. package/dist/update-card.d.ts +193 -0
  386. package/dist/update-card.js +620 -0
  387. package/dist/update-card.js.map +1 -0
  388. package/dist/update-dispatch.d.ts +16 -1
  389. package/dist/update-dispatch.js +12 -4
  390. package/dist/update-dispatch.js.map +1 -1
  391. package/dist/update-forward.d.ts +73 -0
  392. package/dist/update-forward.js +283 -0
  393. package/dist/update-forward.js.map +1 -0
  394. package/dist/update-idle.d.ts +1 -0
  395. package/dist/update-idle.js +12 -3
  396. package/dist/update-idle.js.map +1 -1
  397. package/dist/update-install.d.ts +2 -1
  398. package/dist/update-install.js +18 -10
  399. package/dist/update-install.js.map +1 -1
  400. package/dist/update-journal.d.ts +351 -0
  401. package/dist/update-journal.js +717 -0
  402. package/dist/update-journal.js.map +1 -0
  403. package/dist/update-launch.js +1 -1
  404. package/dist/update-launch.js.map +1 -1
  405. package/dist/update-npm-env.d.ts +45 -12
  406. package/dist/update-npm-env.js +48 -0
  407. package/dist/update-npm-env.js.map +1 -1
  408. package/dist/update-package-restore.d.ts +75 -0
  409. package/dist/update-package-restore.js +318 -0
  410. package/dist/update-package-restore.js.map +1 -0
  411. package/dist/update-quiescence.d.ts +192 -0
  412. package/dist/update-quiescence.js +330 -0
  413. package/dist/update-quiescence.js.map +1 -0
  414. package/dist/update-readiness-host.d.ts +61 -0
  415. package/dist/update-readiness-host.js +297 -0
  416. package/dist/update-readiness-host.js.map +1 -0
  417. package/dist/update-readiness.d.ts +83 -0
  418. package/dist/update-readiness.js +459 -0
  419. package/dist/update-readiness.js.map +1 -0
  420. package/dist/update-recovery/kit.d.ts +35 -0
  421. package/dist/update-recovery/kit.js +99 -0
  422. package/dist/update-recovery/kit.js.map +1 -0
  423. package/dist/update-recovery/pre-start.d.ts +34 -0
  424. package/dist/update-recovery/pre-start.js +103 -0
  425. package/dist/update-recovery/pre-start.js.map +1 -0
  426. package/dist/update-recovery/recover-main.d.ts +1 -0
  427. package/dist/update-recovery/recover-main.js +4 -0
  428. package/dist/update-recovery/recover-main.js.map +1 -0
  429. package/dist/update-recovery/recover.d.ts +22 -0
  430. package/dist/update-recovery/recover.js +124 -0
  431. package/dist/update-recovery/recover.js.map +1 -0
  432. package/dist/update-recovery/route.d.ts +53 -0
  433. package/dist/update-recovery/route.js +262 -0
  434. package/dist/update-recovery/route.js.map +1 -0
  435. package/dist/update-recovery/runner.d.ts +58 -0
  436. package/dist/update-recovery/runner.js +196 -0
  437. package/dist/update-recovery/runner.js.map +1 -0
  438. package/dist/update-recovery/service-manager.d.ts +39 -0
  439. package/dist/update-recovery/service-manager.js +57 -0
  440. package/dist/update-recovery/service-manager.js.map +1 -0
  441. package/dist/update-restore.d.ts +44 -0
  442. package/dist/update-restore.js +355 -0
  443. package/dist/update-restore.js.map +1 -0
  444. package/dist/update-retained.d.ts +38 -0
  445. package/dist/update-retained.js +91 -0
  446. package/dist/update-retained.js.map +1 -0
  447. package/dist/update-rollback.d.ts +74 -0
  448. package/dist/update-rollback.js +221 -0
  449. package/dist/update-rollback.js.map +1 -0
  450. package/dist/update-settings.d.ts +36 -0
  451. package/dist/update-settings.js +122 -0
  452. package/dist/update-settings.js.map +1 -0
  453. package/dist/update-snapshot-manifest.d.ts +32 -0
  454. package/dist/update-snapshot-manifest.js +65 -0
  455. package/dist/update-snapshot-manifest.js.map +1 -0
  456. package/dist/update-snapshot-scope.d.ts +67 -0
  457. package/dist/update-snapshot-scope.js +172 -0
  458. package/dist/update-snapshot-scope.js.map +1 -0
  459. package/dist/update-snapshot.d.ts +34 -0
  460. package/dist/update-snapshot.js +246 -0
  461. package/dist/update-snapshot.js.map +1 -0
  462. package/dist/update-writers.d.ts +71 -0
  463. package/dist/update-writers.js +235 -0
  464. package/dist/update-writers.js.map +1 -0
  465. package/dist/web-api.d.ts +6 -0
  466. package/dist/web-api.js +140 -22
  467. package/dist/web-api.js.map +1 -1
  468. package/dist/web-chat-history.d.ts +7 -0
  469. package/dist/web-chat-history.js +15 -0
  470. package/dist/web-chat-history.js.map +1 -1
  471. package/dist/web-office-acts.d.ts +16 -0
  472. package/dist/web-office-acts.js +27 -9
  473. package/dist/web-office-acts.js.map +1 -1
  474. package/dist/web-office-pack-read.js +1 -1
  475. package/dist/web-office-pack-read.js.map +1 -1
  476. package/dist/web-office-skins.d.ts +5 -3
  477. package/dist/web-office-skins.js +20 -16
  478. package/dist/web-office-skins.js.map +1 -1
  479. package/dist/web-preview.d.ts +5 -0
  480. package/dist/web-preview.js +1 -1
  481. package/dist/web-preview.js.map +1 -1
  482. package/dist/web-settings-patch.d.ts +27 -0
  483. package/dist/web-settings-patch.js +67 -0
  484. package/dist/web-settings-patch.js.map +1 -1
  485. package/dist/web-update.d.ts +6 -0
  486. package/dist/windows-agents.d.ts +12 -0
  487. package/dist/windows-agents.js +5 -0
  488. package/dist/windows-agents.js.map +1 -1
  489. package/dist/workflow-templates/default.md +1 -0
  490. package/launcher/agend +4 -1
  491. package/launcher/agend-agent +4 -1
  492. package/launcher/agend-install.cjs +16 -8
  493. package/launcher/install-admission.d.cts +8 -0
  494. package/launcher/npm-allow-scripts.cjs +72 -0
  495. package/launcher/npm-global-prefix.cjs +81 -0
  496. package/launcher/postinstall.cjs +9 -8
  497. package/launcher/runtime-select.cjs +8 -2
  498. package/package.json +3 -2
  499. package/scripts/preinstall-guard.cjs +1 -1
@@ -72,6 +72,7 @@ import { hits, needle } from "./fleet-canvas-layout.js";
72
72
  import { AUTO_ID, LOBBY, autoLayout, backingScale, coatOf, createFlights, customLayout, deskAt, desksOf, filterOk, lampOf, layoutOk, lightOf, membersOf,
73
73
  officePose, officeRooms, signOf, workOn } from "./fleet-office-model.js";
74
74
  import { BUILT_IN_SKINS, CHAR_DEPTH, DEFAULT_PAL, PICTURE_SKINS, bubbleBox, pixelSkin, loadBuiltInSkin, loadPackSkin, modeOf, skinFor, tagBox, tagFootprint, withCharacters } from "./fleet-office-skin.js";
75
+ import { createRiders, facing, seatAt, vehicleAt } from "./fleet-office-vehicles.js";
75
76
  import { CALLING, activeFurniture, bubbleAt, hiddenBy, bubbleRank, NIGHT, WANDER, createMail, createWalkers, isNight, linesFor, npcKey, personAt, placeBubbles, routeStaysInArea, thinBubbles, walkTargets, zonesLayout } from "./fleet-office-zones.js";
76
77
  import { actsOk, createOfficeStore } from "./fleet-office-store.js";
77
78
  import { badgeOf, fixedOf, mergeLevels } from "./fleet-office-levels.js";
@@ -102,7 +103,7 @@ register("orgo", {
102
103
  b_working: "On it.|Typing…|Almost there|In the zone|One more test", b_idle: "Tea time|Ready when you are|Stretching|Anything for me?",
103
104
  b_paused: "Zzz…|Back later", b_stopped: "Off duty|Zzz…", b_needs: "Need you!|A question for you|Over here!",
104
105
  b_crashed: "Ouch, crashed|Help!", b_stuck: "Hmm, stuck?|Still thinking…",
105
- options: "Office options", hideAsleep: "Hide paused and stopped", nightOn: "Bedtime (0–6): idle agents sleep", playOn: "Drag and pat", playStill: "Off while reduced motion is on", layoutIgnored: "Its saved layout does not fit this style: drawn as the style's own.",
106
+ options: "Office options", hideAsleep: "Hide paused and stopped", hideNames: "Hide names and levels", hideMini: "Hide the minimap", nightOn: "Bedtime (0–6): idle agents sleep", playOn: "Drag and pat", playStill: "Off while reduced motion is on", layoutIgnored: "Its saved layout does not fit this style: drawn as the style's own.",
106
107
  styleForAll: "The whole fleet's style, for everyone: every device and share link", styleHere: "The whole fleet's style in this browser",
107
108
  styleFailed: "The style was not saved for everyone ({0}).", styleBusy: "Too many changes. Try again in a minute.",
108
109
  fit: "Fit the office", overview: "Overview: click to move there", fullscreen: "Fullscreen", exitFullscreen: "Exit fullscreen",
@@ -135,7 +136,7 @@ register("orgo", {
135
136
  b_working: "處理中|打字中…|快好了|專心中|再測一次", b_idle: "喝茶中|隨時可以開工|伸個懶腰|有事找我嗎?",
136
137
  b_paused: "Zzz…|晚點回來", b_stopped: "下班了|Zzz…", b_needs: "需要你!|有個問題|在這裡!",
137
138
  b_crashed: "糟糕,當掉了|救命!", b_stuck: "嗯,卡住了?|還在想…",
138
- options: "辦公室選項", hideAsleep: "隱藏暫停與停止的成員", nightOn: "0–6 點就寢:閒著的人去睡", playOn: "拖曳與摸頭", playStill: "開啟「減少動態效果」時關閉", layoutIgnored: "它儲存的配置不適用這個風格:以風格本身的配置顯示。",
139
+ options: "辦公室選項", hideAsleep: "隱藏暫停與停止的成員", hideNames: "隱藏名字和等級", hideMini: "隱藏小地圖", nightOn: "0–6 點就寢:閒著的人去睡", playOn: "拖曳與摸頭", playStill: "開啟「減少動態效果」時關閉", layoutIgnored: "它儲存的配置不適用這個風格:以風格本身的配置顯示。",
139
140
  styleForAll: "整個 fleet 的風格,所有人共用:每台裝置與分享連結都一樣", styleHere: "這個瀏覽器裡整個 fleet 的風格",
140
141
  styleFailed: "風格沒有替所有人儲存({0})。", styleBusy: "變更太頻繁,請一分鐘後再試。",
141
142
  fit: "顯示整個辦公室", overview: "總覽:點一下移到那裡", fullscreen: "全螢幕", exitFullscreen: "結束全螢幕",
@@ -227,6 +228,12 @@ const overlaps = (a, b) => a.x < b.x + b.w && b.x < a.x + a.w && a.y < b.y + b.h
227
228
  const figureBox = (sk, q) => (sk.charBox ? sk.charBox(q.look, q.at) : { x: q.at.x - 24, y: q.at.y - 52, w: 48, h: 66 });
228
229
  /** #2554: in All offices a tile's name tags show (always) from this many CSS px a unit up; below it on hover only. */
229
230
  export const TAG_MIN_K = 0.75;
231
+ /**
232
+ * M-3665: one office below this zoom (a phone's whole office, about 30 %: a 10 px tag is 3 px on the page) draws no
233
+ * name tags but the hovered, focused or found one: the names are read in the people row over the stage's foot and on
234
+ * a person's card. A desk's fit keeps them (the Fleet's 70 % and up; a Hub room's 60 %).
235
+ */
236
+ export const TAG_READ_K = 0.5;
230
237
  const PAN_KEYS = { ArrowLeft: [-1, 0], ArrowRight: [1, 0], ArrowUp: [0, -1], ArrowDown: [0, 1] };
231
238
  /** Typing: no single-key shortcut (the `f` of fullscreen) there. */
232
239
  const typing = (el) => !!el && (el.tagName === "INPUT" || el.tagName === "SELECT" || el.tagName === "TEXTAREA" || el.isContentEditable === true);
@@ -287,6 +294,8 @@ export function nearestPerson(list, x, y, r) {
287
294
  }
288
295
  /** How often the picture can change when nothing is in the air (the poses loop at 4 fps; a bubble types faster). */
289
296
  const FPS = 12;
297
+ /** At most this many frames a second while anyone walks or anything moves. */
298
+ const AIR_FPS = 30;
290
299
  const STYLES = BUILT_IN_SKINS;
291
300
  /** Paused and stopped: left out when "Hide paused and stopped" is on. */
292
301
  const ASLEEP = new Set(["paused", "stopped"]);
@@ -332,6 +341,22 @@ function looksOf(L, work, q, mode, zones, badge = () => null) {
332
341
  badge: badge(n.name), fit: n.i && n.i.tag_fit && typeof n.i.tag_fit === "object" ? n.i.tag_fit : null }];
333
342
  }));
334
343
  }
344
+ /**
345
+ * #4466: whoever's card is open (`carded`, the page's cardDesk) stands where they are now: `to` gets their place. Not
346
+ * while carried (the hold sets that), and not while calling (#4467 review: a caller walks to the Help desk as usual).
347
+ */
348
+ export function cardStay(to, carded, held, walkers, t) {
349
+ if (!carded || !carded.walks || CALLING.has(carded.state) || (held && held.name === carded.name)) return;
350
+ const at = walkers.at(carded.name, t);
351
+ if (at) to.set(carded.name, { x: at.x, y: at.y });
352
+ }
353
+ /** `view` (buildOrgView's) with each renamed person's nickname set to the name this browser gives them. */
354
+ export function renamedView(view, renames) {
355
+ if (!view || !renames || !Object.keys(renames).length) return view;
356
+ const one = (n) => (n && n.i && Object.prototype.hasOwnProperty.call(renames, n.name) ? { ...n, i: { ...n.i, display_name: renames[n.name] } } : n);
357
+ return { ...view, top: (view.top || []).map(one), teams: (view.teams || []).map((t) => ({ ...t, nodes: (t.nodes || []).map(one) })),
358
+ rest: view.rest ? { ...view.rest, nodes: (view.rest.nodes || []).map(one) } : view.rest };
359
+ }
335
360
  /** A stored office's own layout on a zones style (its overrides); `ignored`: they do not fit this style. */
336
361
  function withOverrides(baseSkin, zones, office) {
337
362
  const ov = zones && office ? office.overrides : null;
@@ -414,6 +439,32 @@ const GHOST_POSE = [["paused", "paused"], ["stopped", "paused"], ["working", "wo
414
439
  const BUBBLE_IN_AREA = 8;
415
440
  /** How faint Edit layout's figures are: seen through, yet readable over a busy picture (a dimmed person is 0.35). */
416
441
  const GHOST_ALPHA = 0.6;
442
+ /**
443
+ * M-3665: stopped — or, in a Hub room, an agent whose computer is offline — is not the same as paused, though both
444
+ * doze in the nap corner. A paused person is drawn as ever (its Zzz); a stopped one faded (OFF_ALPHA) with a small
445
+ * power-off mark beside it, on every style and every pack (the pack's own paused strip draws both).
446
+ */
447
+ const OFF_ALPHA = 0.45;
448
+ export const offLook = (look) => !!look && look.state === "stopped" && look.pose !== "away";
449
+ export function drawOffMark(ctx, x, y, env) {
450
+ const pal = (env && env.pal) || {}, r = 6;
451
+ ctx.save();
452
+ ctx.globalAlpha = 1;
453
+ ctx.fillStyle = pal.surface || "#2f2f2f"; ctx.strokeStyle = pal.text3 || "#bbbbbb"; ctx.lineWidth = 1.2;
454
+ ctx.beginPath(); ctx.arc(x, y, r + 2, 0, Math.PI * 2); ctx.fill(); ctx.stroke();
455
+ ctx.strokeStyle = pal.text2 || "#cfcfcf"; ctx.lineWidth = 1.6; ctx.lineCap = "round";
456
+ ctx.beginPath(); ctx.arc(x, y + 0.5, r - 2, -Math.PI / 2 + 0.75, Math.PI * 1.5 - 0.75); ctx.stroke(); // the power symbol's ring…
457
+ ctx.beginPath(); ctx.moveTo(x, y - r + 1); ctx.lineTo(x, y - 0.5); ctx.stroke(); // …and its bar
458
+ ctx.restore();
459
+ }
460
+ /** A person drawn by the skin; stopped (offline): faded, with the power-off mark at (mx, my). */
461
+ function drawPerson(ctx, sk, box, look, ms, env, mx, my, markScale = 1) {
462
+ if (!offLook(look)) { sk.drawCharacter(ctx, box, look, ms, env); return; }
463
+ ctx.save(); ctx.globalAlpha *= OFF_ALPHA; sk.drawCharacter(ctx, box, look, ms, env); ctx.restore();
464
+ // M-3665 (leader's check): zoomed out past TAG_READ_K the mark keeps its size at TAG_READ_K, centred where it was.
465
+ if (markScale === 1) { drawOffMark(ctx, mx, my, env); return; }
466
+ ctx.save(); ctx.translate(mx, my); ctx.scale(markScale, markScale); drawOffMark(ctx, 0, 0, env); ctx.restore();
467
+ }
417
468
  /** Edit layout's faint figures: one on each seat no one is on, { x, y, look } (the pack's default set; drawn at GHOST_ALPHA). */
418
469
  export function ghostsOf(pack, people = []) {
419
470
  const taken = (s) => people.some((q) => Math.abs(q.at.x - s.x) < 2 && Math.abs(q.at.y - s.y) < 2);
@@ -442,6 +493,24 @@ export function actLive(a, state, at = Date.now(), seen = null) {
442
493
  if (state !== "working") { seen.add(k); return true; }
443
494
  return !seen.has(k) && (!a.state || a.state === "working");
444
495
  }
496
+ /**
497
+ * Whether an agent's ride (office_set `ride`) holds now: set and not past its end, the person neither asleep nor calling
498
+ * (#4415: nothing keeps a caller from the Help desk; the ride resumes when the call is over). Working or a new turn do
499
+ * not end it (it is where they choose to be); clearing it, a new office_set or its end do.
500
+ */
501
+ /**
502
+ * #4504: what the card's pose preview offers — every pose a character set may draw, walking by direction. Here, not in
503
+ * fleet-office-pack.js: a tab opened before an upgrade may keep that module, and a named import it lacks would stop this
504
+ * one linking (#4505/#4508 review).
505
+ */
506
+ export const PREVIEW_POSES = ["idle", "working", "paused", "needs", "walkDown", "walkUp", "walkSide", "walkLeft", "eat", "pat", "dragged", "stand"];
507
+ const PREVIEW_HEADINGS = { walkDown: { dx: 0, dy: 1 }, walkUp: { dx: 0, dy: -1 }, walkSide: { dx: 1, dy: 0 }, walkLeft: { dx: -1, dy: 0 } };
508
+ /** A look showing `pose` in place (a walking direction walks on the spot); a set without that strip shows its own pose. */
509
+ export function previewLook(look, pose) {
510
+ const heading = PREVIEW_HEADINGS[pose];
511
+ return heading ? { ...look, pose: "walk", heading } : { ...look, pose, basePose: look.pose };
512
+ }
513
+ export const rideLive = (a, state, at = Date.now()) => !!a && !!a.ride && at < a.until && !ASLEEP.has(state) && !CALLING.has(state);
445
514
  /** How far beside the person an agent going to them stands. */
446
515
  const ACT_BESIDE = 48;
447
516
  /** Where an agent's act sends it at `t`: its point, beside the person it goes to (where they are now), or null. */
@@ -483,8 +552,9 @@ function paintLayers(p, env, ls, tagsOff = false) {
483
552
  for (const r of L.rooms) skin.drawRoom(g, r, env);
484
553
  for (const d of all) skin.drawDeskBack(g, d, looks.get(d.key), env);
485
554
  });
486
- const front = zones ? null : layer((g) => {
487
- for (const d of all) { const lk = looks.get(d.key); skin.drawDeskFront(g, d, tagsOff && lk && !lk.match ? { ...lk, notag: true } : lk, env); }
555
+ // Zones: the pack's foreground, painted once at the layer's scale (it was drawn from the full picture every frame).
556
+ const front = zones ? (skin.pack && skin.pack.foreground && skin.drawForeground ? layer((g) => skin.drawForeground(g, L, env)) : null) : layer((g) => {
557
+ for (const d of all) { const lk = looks.get(d.key); skin.drawDeskFront(g, d, !tagsOff || !lk || lk.match ? lk : tagsOff === "names" && CALLING.has(lk.state) ? { ...lk, badge: null } : { ...lk, notag: true }, env); }
488
558
  });
489
559
  return { ls, tagsOff, back, front };
490
560
  }
@@ -510,17 +580,26 @@ export function officeBubbleAt(hits, x, y, minSize = 0) {
510
580
  export function drawPart(ctx, p, a, ox, oy, ms, still, hot, env, tagsOff = false, defer = null, bubbleHits = null) {
511
581
  const sk = p.skin;
512
582
  const ls = layerScale(a, p.L.width, p.L.height);
513
- if (!p.layers || p.layers.ls !== ls || p.layers.tagsOff !== tagsOff) p.layers = paintLayers(p, env, ls, tagsOff);
583
+ // M-3665: the view's CSS zoom (a is bitmap px a unit: the zoom × the device ratio, Prism #4423). Below TAG_READ_K what must
584
+ // stay readable is drawn larger: the offline mark readScale times (its size at TAG_READ_K), a caller's tag callerScale.
585
+ const zk = a / ((env && env.ratio) || 1), readScale = zk < TAG_READ_K ? TAG_READ_K / zk : 1;
586
+ // A caller's tag at its full size (1×: the leader's call, "who needs you at a glance"); other floors stay at TAG_READ_K.
587
+ const callerScale = zk < 1 ? 1 / zk : 1;
588
+ // Zones zoomed in past the layers' budget (a big pack): the layer would be coarser than the screen and the picture,
589
+ // so the background and foreground are drawn from their pictures instead (only the part on screen is rasterised).
590
+ const direct = !!p.zones && ls < a - 1e-6;
591
+ if (!direct && (!p.layers || p.layers.ls !== ls || p.layers.tagsOff !== tagsOff)) p.layers = paintLayers(p, env, ls, tagsOff);
514
592
  const T = () => ctx.setTransform(a, 0, 0, a, ox, oy);
515
593
  const blit = (c) => { if (!c) return; ctx.setTransform(a / ls, 0, 0, a / ls, ox, oy); ctx.drawImage(c, 0, 0); T(); };
516
- blit(p.layers.back);
594
+ if (direct) { T(); ctx.fillStyle = env.pal.bg; ctx.fillRect(0, 0, p.L.width, p.L.height); sk.drawBackground(ctx, p.L, env); }
595
+ else blit(p.layers.back);
517
596
  T();
518
597
  const speakers = [], tags = [], titleBoxes = []; // M-3539: the area names bubbles keep off too
519
598
  const titleDraws = []; // M-3722: and redrawn over a bubble's tail that crosses one
520
599
  const up = still ? [] : p.flights.frame(ms, p.L);
521
600
  // Mail from another office (#2564): flying in at the door, or on the floor until its person picks it up.
522
601
  const post = still || !p.mail || !p.zones ? [] : p.mail.frame(ms > 0 ? ms : now(), p.L, p.walkers);
523
- let walking = false;
602
+ let walking = false, carsOn = false;
524
603
  if (p.zones) {
525
604
  // Furniture under the people; the people (nearest last) with the furniture whose depth is "y" among them, by base
526
605
  // y (a tie: the item first, the person in front); furniture over them; things in the air; the pack's foreground
@@ -538,6 +617,9 @@ export function drawPart(ctx, p, a, ox, oy, ms, still, hot, env, tagsOff = false
538
617
  });
539
618
  if (changed && typeof p.onSnacksChanged === "function") p.onSnacksChanged();
540
619
  }
620
+ // Off screen (the canvas in logical units, with room for the tallest sprite and its bubble): not drawn.
621
+ const cw = ctx.canvas && ctx.canvas.width, chh = ctx.canvas && ctx.canvas.height, M = 320;
622
+ const offView = cw ? (at) => at.x < -ox / a - M || at.x > (cw - ox) / a + M || at.y < -oy / a - M / 4 || at.y > (chh - oy) / a + M : () => false;
541
623
  const people = p.desks.map((d) => {
542
624
  const at = p.walkers.at(d.node.name, t) || { ...d.seat, walking: false };
543
625
  if (at.walking) walking = true;
@@ -546,7 +628,11 @@ export function drawPart(ctx, p, a, ox, oy, ms, still, hot, env, tagsOff = false
546
628
  const furniture = strollFurniture(p.night ? nightFurniture(sk.pack.furniture) : sk.pack.furniture, (k) => p.walkers.at(k, t));
547
629
  if (furniture.some((f) => f.walking)) walking = true;
548
630
  const placedSnacks = p.snacks ? p.snacks.placedList() : [];
631
+ const wall = Date.now(), cars = (sk.pack.vehicles || []).map((v) => ({ v, at: vehicleAt(v, wall) }));
632
+ carsOn = cars.length > 0;
549
633
  const band = [...furniture.filter((f) => f.depth === "y").map((f) => ({ y: f.y, k: 0, f })),
634
+ ...cars.map((c) => ({ y: c.at.y, k: 0.8, car: c })),
635
+ ...cars.map((c) => ({ y: Math.max(c.at.y, ...people.filter((q) => q.at.riding && p.riding && (p.riding(q.look.name) || {}).vehicle === c.v.id).map((q) => q.at.y)), k: 1.5, front: c })),
550
636
  ...placedSnacks.map((sn) => ({ y: sn.y, k: 0.5, sn })),
551
637
  ...people.map((q) => ({ y: q.at.y, k: 1, p: q })),
552
638
  ...(p.ghosts ? ghostsOf(sk.pack, people).map((g) => ({ y: g.y, k: 1, g })) : []),
@@ -601,7 +687,9 @@ export function drawPart(ctx, p, a, ox, oy, ms, still, hot, env, tagsOff = false
601
687
  for (const f of furniture) if (f.depth !== "y" && f.depth < CHAR_DEPTH) sk.drawFurniture(ctx, f, f.asleep || live.active.has(f.id), ms, env);
602
688
  for (const it of post) if (it.t === 0) sk.drawProp(ctx, it, ms, env); // a letter on the floor: under the people
603
689
  let heldPerson = null;
604
- for (const { f, p: q, g, n, sn } of band) {
690
+ for (const { f, p: q, g, n, sn, car, front } of band) {
691
+ if (car) { if (sk.drawVehicle) sk.drawVehicle(ctx, car.v, car.at, ms, env); continue; }
692
+ if (front) { if (sk.drawVehicleFront) sk.drawVehicleFront(ctx, front.v, front.at, ms, env); continue; }
605
693
  if (f) { sk.drawFurniture(ctx, f, f.asleep || live.active.has(f.id), ms, env); continue; }
606
694
  if (sn) {
607
695
  const sdef = p.snacksById && p.snacksById.get(sn.snackId);
@@ -618,6 +706,7 @@ export function drawPart(ctx, p, a, ox, oy, ms, still, hot, env, tagsOff = false
618
706
  if (g) { ctx.save(); ctx.globalAlpha = GHOST_ALPHA; sk.drawCharacter(ctx, { x: g.x - 44, y: g.y - 53, w: 88, h: 53, seat: g }, g.look, 0, env); ctx.restore(); continue; }
619
707
  if (heldName && q.look.name === heldName) { heldPerson = q; continue; } // M-3445 (#4267): drawn lifted on top below
620
708
  if (live.hidden.has(q.look.name)) continue; // #2698: drawn as the item (never while walking)
709
+ if (offView(q.at)) continue;
621
710
  const box = { ...q.d, x: q.at.x - 44, y: q.at.y - 53, w: 88, h: 53, seat: { x: q.at.x, y: q.at.y } };
622
711
  // An agent's own pose (office_set, #2578) while its act lasts and nothing calls it; walking is walking; M-3432: eating when fed.
623
712
  const posed = actPosed(p, q.look);
@@ -626,10 +715,14 @@ export function drawPart(ctx, p, a, ox, oy, ms, still, hot, env, tagsOff = false
626
715
  // A pat shows the set's `pat` strip for one full pass of it (pat.until), each pat from frame 0; a set without one keeps its pose.
627
716
  const canPat = !q.at.walking && !canEat && ms > 0 && !!p.reacts && !CALLING.has(q.look.state) && !ASLEEP.has(q.look.state) && !q.look.night;
628
717
  const patted = canPat ? patLook(posed, p.reacts.get(q.look.name), t) : null;
629
- const look = q.at.walking ? { ...q.look, pose: "walk", heading: q.at.heading }
718
+ const look0 = q.at.walking ? { ...q.look, pose: "walk", heading: q.at.heading }
630
719
  : canEat ? { ...posed, pose: "eat", basePose: posed.pose }
631
720
  : patted || posed;
632
- sk.drawCharacter(ctx, box, look, ms, env);
721
+ // #4504: the card's pose preview (this viewer's own): the picked pose in place, from its first frame (`clip`:
722
+ // Replay starts it again). Never over a call: a caller shows that they call, preview or not.
723
+ const pv = p.preview && p.preview.current;
724
+ const look = pv && pv.name === q.look.name && !q.at.walking && !CALLING.has(q.look.state) ? { ...previewLook(posed, pv.pose), clip: `#${pv.t0}` } : look0;
725
+ drawPerson(ctx, sk, box, look, ms, env, q.at.x + 20, q.at.y - 34, readScale);
633
726
  if (canEat && eating.snackId && p.snacksById && sk.drawSnack) {
634
727
  const sdef = p.snacksById.get(eating.snackId);
635
728
  if (sdef && sdef.eat) sk.drawSnack(ctx, sdef.eat, Math.max(0, t - eating.t0), q.at.x, q.at.y, env);
@@ -647,7 +740,8 @@ export function drawPart(ctx, p, a, ox, oy, ms, still, hot, env, tagsOff = false
647
740
  }
648
741
  for (const it of up) sk.drawProp(ctx, it, ms, env);
649
742
  for (const it of post) if (it.t > 0) sk.drawProp(ctx, it, ms, env);
650
- if (sk.drawForeground) sk.drawForeground(ctx, p.L, env);
743
+ if (direct) { if (sk.pack && sk.pack.foreground && sk.drawForeground) sk.drawForeground(ctx, p.L, env); }
744
+ else if (p.layers.front) blit(p.layers.front);
651
745
  // Who found no spot in an area: a count in its corner (never over its name).
652
746
  for (const [ar, n] of p.L.crowd || []) if (p.L.areas[ar] && sk.drawCrowd) sk.drawCrowd(ctx, p.L.areas[ar], n, env);
653
747
  // M-3539: an area's name a figure stands on is written again over the people (休息區 under a crowd's heads).
@@ -664,7 +758,14 @@ export function drawPart(ctx, p, a, ox, oy, ms, still, hot, env, tagsOff = false
664
758
  const over = p.L.over || new Set();
665
759
  const pinned = (q) => q.d.key === hot || !!q.look.match;
666
760
  const crowded = (q) => over.has(q.d.area) && !pinned(q);
667
- const tagged = (q) => pinned(q) || !(tagsOff || over.has(q.d.area));
761
+ // M-3665 (leader's check): too far out to read (tagsOff true), a caller still says who they are on the map — their tag
762
+ // at its full size (1×), where they stand (the chip row below lists them too). Drawn after the tags, below.
763
+ const beaconOn = tagsOff === true && readScale > 1;
764
+ const beacon = (q) => beaconOn && CALLING.has(q.look.state);
765
+ // A caller keeps their tag with names hidden (#4467 review): the Help desk always says who needs you.
766
+ const tagged = (q) => !beacon(q) && (pinned(q) || (tagsOff === "names" && CALLING.has(q.look.state)) || !(tagsOff || over.has(q.d.area)));
767
+ // Names hidden: a caller's tag is their name only; the level stays hidden (the one hovered or found keeps it).
768
+ const tagLook = (q) => (tagsOff === "names" && !pinned(q) && q.look.badge ? { ...q.look, badge: null } : q.look);
668
769
  const keep = [...titles.map((x) => x.box), ...(env.keepClear || [])];
669
770
  titleBoxes.push(...titles.map((x) => x.box)); titleDraws.push(...titles);
670
771
  const taken = [];
@@ -703,7 +804,23 @@ export function drawPart(ctx, p, a, ox, oy, ms, still, hot, env, tagsOff = false
703
804
  const FULL_TRIES = [[0, false], [TAG_ROW, false], [0, true], [COMPACT_ROW, true]];
704
805
  const tagOrder = people.filter((q) => !(live.hidden.has(q.look.name) && q.look.name !== heldName) && tagged(q))
705
806
  .map((q, i) => ({ q, i, rank: pinned(q) ? 0 : q.at.walking ? 2 : 1 })).sort((x, y) => x.rank - y.rank || x.i - y.i);
706
- for (const { q, rank } of tagOrder) place(q.at.x, q.at.y, q.look, FULL_TRIES, rank === 0);
807
+ for (const { q, rank } of tagOrder) place(q.at.x, q.at.y, tagLook(q), FULL_TRIES, rank === 0);
808
+ // The callers' tags in that mode (above), as the tags are placed: the box scaled about where they stand so it reads at
809
+ // its full size, never under an open card, clear of the kept-clear controls and of each other (there, else a row
810
+ // lower), registered (bubbles keep off it); their level left out. None clear: left to their chip in the row.
811
+ if (beaconOn) for (const q of people) {
812
+ if (!CALLING.has(q.look.state) || live.hidden.has(q.look.name) || offView(q.at)) continue;
813
+ const k = callerScale, look = { ...q.look, badge: null }, sc = (b) => ({ x: q.at.x + (b.x - q.at.x) * k, y: q.at.y + (b.y - q.at.y) * k, w: b.w * k, h: b.h * k });
814
+ for (const dy of [0, TAG_ROW]) {
815
+ const box = sc(tagBox(ctx, q.at.x, q.at.y + dy, look.label, false, look.fit));
816
+ if (covered(box) || touches(box)) continue;
817
+ ctx.save(); ctx.transform(k, 0, 0, k, q.at.x * (1 - k), q.at.y * (1 - k));
818
+ sk.drawTag(ctx, q.at.x, q.at.y + dy, look, env, false);
819
+ ctx.restore();
820
+ tags.push(box); taken.push(box);
821
+ break;
822
+ }
823
+ }
707
824
  // A furniture item's own name (#2574: an NPC drawn as furniture), tagged like a person; none on a tile too small to read.
708
825
  // #2698: an item hiding its people carries their tags too, in one row at its tag point (its own first; each keeps
709
826
  // its place in the row while another's tag is left out), and their bubbles, over its picture. The tags drawn are
@@ -717,7 +834,7 @@ export function drawPart(ctx, p, a, ox, oy, ms, still, hot, env, tagsOff = false
717
834
  }
718
835
  const order = new Map((f.activeFor || []).map((n, i) => [n, i]));
719
836
  on.sort((x, y) => (order.get(x.look.name) ?? 0) - (order.get(y.look.name) ?? 0));
720
- const row = tagRow(ctx, f.x, f.y, [...(f.label ? [npcLook(p, f)] : []), ...on.map((q) => q.look)]);
837
+ const row = tagRow(ctx, f.x, f.y, [...(f.label ? [npcLook(p, f)] : []), ...on.map(tagLook)]);
721
838
  const top = f.sprite ? Math.min(f.y - 50, stripBox(f.activeSprite || f.sprite, f.x, f.y).y + 2) : f.y - 50;
722
839
  for (const [i, r] of row.entries()) {
723
840
  const q = f.label ? on[i - 1] : on[i];
@@ -737,7 +854,7 @@ export function drawPart(ctx, p, a, ox, oy, ms, still, hot, env, tagsOff = false
737
854
  place(q.at.x, q.at.y, q.look, [[0, true], [COMPACT_ROW, true]]);
738
855
  }
739
856
  } else {
740
- for (const d of p.desks) { const look = p.looks.get(d.key); sk.drawCharacter(ctx, d, actPosed(p, look), ms, env); speakers.push({ look, x: d.x + 58, y: d.y + 12, area: p.roomOf.get(d.key) ?? null }); }
857
+ for (const d of p.desks) { const look = p.looks.get(d.key); drawPerson(ctx, sk, d, actPosed(p, look), ms, env, d.x + d.w - 14, d.y + 14, readScale); speakers.push({ look, x: d.x + 58, y: d.y + 12, area: p.roomOf.get(d.key) ?? null }); }
741
858
  blit(p.layers.front);
742
859
  // Tags left out of the layer: the hovered desk's front again, with its tag.
743
860
  const hd = tagsOff && hot ? p.desks.find((d) => d.key === hot) : null;
@@ -775,6 +892,11 @@ export function drawPart(ctx, p, a, ox, oy, ms, still, hot, env, tagsOff = false
775
892
  // Speech bubbles: a short line for the state, now and then (typed out; whole at once when still), placed so no two
776
893
  // overlap (placeBubbles; #2431).
777
894
  const bubbles = [], rp = p.reply, tSaid = Date.now(), replies = [];
895
+ // M-3743: the part of the scene on screen (the canvas, in this part's units, 8 bitmap px in): a bubble stays inside it,
896
+ // its tail still at the speaker (bubbleBox's `fit`; a speaker near an edge — a rider along the map's rim — had its
897
+ // bubble cut off). All offices: the whole canvas too (the bubbles are drawn after every tile, unclipped).
898
+ const cw = ctx.canvas && ctx.canvas.width, chh = ctx.canvas && ctx.canvas.height, edge = 8 / a;
899
+ const fit = cw > 0 && chh > 0 ? { l: -ox / a + edge, r: (cw - ox) / a - edge, t: -oy / a + edge, b: (chh - oy) / a - edge } : null;
778
900
  for (let sp of speakers) {
779
901
  if (sp.look.dim || sp.look.pose === "away") continue;
780
902
  // Talk "Over their head": a live reply, in full (wrapped), in place of the state's line.
@@ -796,9 +918,10 @@ export function drawPart(ctx, p, a, ox, oy, ms, still, hot, env, tagsOff = false
796
918
  // M-3533 R2c (Lumen): a room's own characters stand taller than the style's figures; their bubble stays inside the
797
919
  // area's box, as a figure's does (the Fleet's own office is unchanged).
798
920
  const ar = b && sk.ownCharacters && p.zones && sp.area != null ? p.L.areas && p.L.areas[sp.area] : null;
799
- if (ar && ar.rect) { const bx = bubbleBox(ctx, sp.x, sp.y, b.text), min = ar.rect.y + BUBBLE_IN_AREA; if (bx.y < min) sp = { ...sp, y: sp.y + (min - bx.y) }; }
921
+ if (ar && ar.rect) { const bx = bubbleBox(ctx, sp.x, sp.y, b.text, 0, false, fit), min = ar.rect.y + BUBBLE_IN_AREA; if (bx.y < min) sp = { ...sp, y: sp.y + (min - bx.y) }; }
800
922
  if (b) bubbles.push({ key: sp.look.name, area: sp.area, state: sp.look.state, calling: CALLING.has(sp.look.state), rank: own ? 0 : scText ? 1 : bubbleRank(sp.look.state), shown: b.shown, ...(raSays ? { keep: true } : {}),
801
- box: bubbleBox(ctx, sp.x, sp.y, b.text), ...(CALLING.has(sp.look.state) ? { flipBox: bubbleBox(ctx, sp.x, sp.y, b.text, 0, true) } : {}), tail: { x: sp.x, y: sp.y }, sp, b });
923
+ box: bubbleBox(ctx, sp.x, sp.y, b.text, 0, false, fit), ...(CALLING.has(sp.look.state) ? { flipBox: bubbleBox(ctx, sp.x, sp.y, b.text, 0, true, fit) } : {}), tail: { x: sp.x, y: sp.y }, sp, b,
924
+ boxAt: ((at) => (dy, flip) => bubbleBox(ctx, at.x, at.y, b.text, -dy, flip, fit))(sp) });
802
925
  }
803
926
  // A crowded area speaks less (thinBubbles: calls, then work, a few at most); no bubble covers a name tag. `defer`
804
927
  // (All offices): drawn after every tile, unclipped, so a bubble at a tile's edge is whole.
@@ -810,15 +933,26 @@ export function drawPart(ctx, p, a, ox, oy, ms, still, hot, env, tagsOff = false
810
933
  const inArea = (sp, text, dy, flip) => {
811
934
  const ar = sk.ownCharacters && p.zones && sp.area != null ? p.L.areas && p.L.areas[sp.area] : null;
812
935
  if (!ar || !ar.rect || !dy) return dy;
813
- const over = ar.rect.y + BUBBLE_IN_AREA - bubbleBox(ctx, sp.x, sp.y, text, -dy, flip).y;
936
+ const over = ar.rect.y + BUBBLE_IN_AREA - bubbleBox(ctx, sp.x, sp.y, text, -dy, flip, fit).y;
814
937
  return over > 0 ? Math.max(0, dy - over) : dy;
815
938
  };
816
- const say = () => { T(); const tails = []; for (const { sp, b, dy: lifted, flip = false } of placed) {
817
- const text = [...b.text].slice(0, b.shown).join(""), dy = inArea(sp, b.text, lifted, flip);
818
- sk.drawBubble(ctx, sp.x, sp.y, text, env, -dy, flip);
819
- if (text) { const box = bubbleBox(ctx, sp.x, sp.y, text, -dy, flip); tails.push({ x: sp.x - 1, y: box.y + box.h, w: 9, h: Math.max(0, sp.y - (box.y + box.h)) }); }
939
+ // The box a tail covers: the skin's own (from its foot to the speaker, M-3743), else the strip under the speaker (an older skin).
940
+ const tailOf = (sp, box) => box.tail || (box.below ? { x: sp.x - 1, y: sp.y, w: 9, h: Math.max(0, box.y - sp.y) } : { x: sp.x - 1, y: box.y + box.h, w: 9, h: Math.max(0, sp.y - (box.y + box.h)) });
941
+ // M-3743 (#4474 review): checked again where each is drawn (kept on screen, and in its area), in placing order: none over
942
+ // another's box or tail, or a name tag. A page still holding an older fleet-office-zones.js places `box` moved by dy (it
943
+ // knows no boxAt), and two boxes kept on screen could meet; with the current one this keeps every bubble it placed.
944
+ const shown = [], held = [...tags];
945
+ for (const it of placed) {
946
+ const flip = it.flip || false, dy = inArea(it.sp, it.b.text, it.dy, flip), box = bubbleBox(ctx, it.sp.x, it.sp.y, it.b.text, -dy, flip, fit), tl = tailOf(it.sp, box);
947
+ if (held.some((o) => overlaps(o, box) || overlaps(o, tl))) continue;
948
+ held.push(box, tl); shown.push({ ...it, dy, flip });
949
+ }
950
+ const say = () => { T(); const tails = []; for (const { sp, b, dy, flip } of shown) {
951
+ const text = [...b.text].slice(0, b.shown).join("");
952
+ sk.drawBubble(ctx, sp.x, sp.y, text, env, -dy, flip, fit);
953
+ if (text) tails.push(tailOf(sp, bubbleBox(ctx, sp.x, sp.y, text, -dy, flip, fit)));
820
954
  if (bubbleHits && text) {
821
- const box = bubbleBox(ctx, sp.x, sp.y, text, -dy, flip);
955
+ const box = bubbleBox(ctx, sp.x, sp.y, text, -dy, flip, fit);
822
956
  bubbleHits.push({ name: sp.look.name, box: { x: ox + box.x * a, y: oy + box.y * a, w: box.w * a, h: box.h * a } });
823
957
  }
824
958
  }
@@ -849,7 +983,7 @@ export function drawPart(ctx, p, a, ox, oy, ms, still, hot, env, tagsOff = false
849
983
  if (bubbleHits) bubbleHits.push({ name: sp.look.name, reply: true, box: { x: ox + box.x * a, y: oy + box.y * a, w: box.w * a, h: box.h * a } });
850
984
  } };
851
985
  if (defer) defer.push(say); else say();
852
- return replies.length > 0 || walking || up.length > 0 || p.flights.size() > 0 || post.some((it) => it.t > 0) || rising.length > 0 || !!reacting || (!!p.snacks && p.snacks.active(t0)) || !!(p.snackDrop && p.snackDrop.current) || !!(p.hold && p.hold.held());
986
+ return replies.length > 0 || carsOn || walking || up.length > 0 || p.flights.size() > 0 || post.some((it) => it.t > 0) || rising.length > 0 || !!reacting || (!!p.snacks && p.snacks.active(t0)) || !!(p.snackDrop && p.snackDrop.current) || !!(p.hold && p.hold.held());
853
987
  }
854
988
  /**
855
989
  * #2661: an NPC's name tag (a furniture item's label) — with the title a pack pins on it (`levels.fixed` by its id),
@@ -965,7 +1099,7 @@ function ensureDialogueStyle() {
965
1099
  link.href = assetUrl("/assets/office-dialogue.css");
966
1100
  link.setAttribute("data-office-dialogue-css", "1"); doc.head.appendChild(link);
967
1101
  }
968
- export function Office({ view, traffic, q = "", lease, onOpen, assetUrl, assetImage, opening, talk, chatUi = null, more = false, onMore = null, live = null, onLive = null,
1102
+ export function Office({ view: given, traffic, q = "", lease, onOpen, assetUrl, assetImage, opening, talk, chatUi = null, more = false, onMore = null, live = null, onLive = null,
969
1103
  oneOffice = false, readOnly = false, stream = true, storage = undefined, cardRows = null, words = null, cardAction = null, cardName = null, officesKey = undefined, foldBar = false, cardPhoto = null, characters = null }) {
970
1104
  // M-3253: on a phone the page above (fleet-canvas.js) puts a ⋯ in its bar: `more` is that sheet open, `onMore(open)`;
971
1105
  // `live` / `onLive` its Live toggle, which moves into the sheet. Without one (a share link's page) the bar stays.
@@ -1007,6 +1141,11 @@ export function Office({ view, traffic, q = "", lease, onOpen, assetUrl, assetIm
1007
1141
  const [styleErr, setStyleErr] = useState("");
1008
1142
  const style = canEdit ? hostStyle ?? ownStyle ?? "cozy" : ownStyle ?? hostStyle ?? "cozy";
1009
1143
  const [hideAsleep, setHideAsleep] = useState(() => store.hideAsleep());
1144
+ const [namesOff, setNamesOff] = useState(() => store.namesOff());
1145
+ const [miniOff, setMiniOff] = useState(() => store.miniOff());
1146
+ // The names this browser gives people: each node's nickname replaced here, so the tags, the card and the dialogue follow.
1147
+ const [renames, setRenames] = useState(() => store.renames());
1148
+ const view = useMemo(() => renamedView(given, renames), [given, renames]);
1010
1149
  // Bedtime (#2568), when it is on here: the idle sleep from NIGHT.FROM to NIGHT.TO on this device's clock (read every NIGHT.TICK).
1011
1150
  const [nightOn, setNightOn] = useState(() => store.nightOn());
1012
1151
  const [keyOpen, setKeyOpen] = useState(() => store.keyOpen());
@@ -1069,12 +1208,22 @@ export function Office({ view, traffic, q = "", lease, onOpen, assetUrl, assetIm
1069
1208
  fsRef.current = fs;
1070
1209
  const flights = useMemo(() => createFlights(), []);
1071
1210
  const walkers = useMemo(() => createWalkers(), []);
1211
+ const riders = useMemo(() => createRiders(), []);
1072
1212
  const seatsRef = useRef(new Map()); // the zones layout's last seats: kept where they can be
1073
1213
  const seatPrefsRef = useRef({}), seatKeyRef = useRef(""), seatDropRef = useRef(null);
1074
1214
  const placedRef = useRef(null); // M-3539: the office and style the walkers were last placed for
1075
1215
  // M-3539: the phone's zone chips scroll sideways when they do not fit (English); a fade at the side there is more
1076
1216
  // (data-more-left / data-more-right) says so.
1077
1217
  const pillsRef = useRef(null);
1218
+ // M-3665 (leader's check): the zoomed-out name row scrolls sideways; while there is more, its edge fades (as the pills).
1219
+ const desksRef = useRef(null);
1220
+ const desksCue = () => {
1221
+ const e = desksRef.current;
1222
+ if (!e || typeof e.toggleAttribute !== "function") return;
1223
+ const more = e.scrollWidth - e.clientWidth;
1224
+ e.toggleAttribute("data-more-left", more > 1 && e.scrollLeft > 1);
1225
+ e.toggleAttribute("data-more-right", more > 1 && e.scrollLeft < more - 1);
1226
+ };
1078
1227
  const pillsCue = () => {
1079
1228
  const e = pillsRef.current;
1080
1229
  if (!e || typeof e.toggleAttribute !== "function") return;
@@ -1283,7 +1432,8 @@ export function Office({ view, traffic, q = "", lease, onOpen, assetUrl, assetIm
1283
1432
  const size = { w: width, h: stageH > 0 ? stageH : SIZE0.h };
1284
1433
  // The canvas bitmap's px per CSS px: the device's, unless the bitmap would be too big to paint (backingScale). Zoom
1285
1434
  // snaps to whole numbers of these (fleet-office-view.js), so a pixel-level view maps a logical unit onto whole pixels.
1286
- const ratio = backingScale(size.w, size.h, dpr);
1435
+ // At most 2 px per CSS px: a 3x phone screen would paint 2.25x the pixels every frame for little visible gain.
1436
+ const ratio = backingScale(size.w, size.h, Math.min(2, dpr));
1287
1437
 
1288
1438
  // #2554: All offices — chosen, and at least two offices stored (else the whole fleet, as an office gone is).
1289
1439
  const overview = choice === ALL_ID && overviewOk(stored);
@@ -1443,6 +1593,8 @@ export function Office({ view, traffic, q = "", lease, onOpen, assetUrl, assetIm
1443
1593
  // M-3547 / M-3556: off only for reduced motion — one line under Drag and pat in Display options says so (no override).
1444
1594
  const playStillOff = playOffForMotion({ on: playOn, still, zones, overview, layout: !!layout, shared }) && !carouselPick;
1445
1595
  const hold = useMemo(() => createHold(), []), reacts = useRef(new Map()), walkNow = useRef(null), holdTimer = useRef(null);
1596
+ // #4504: the card's pose preview — { name, pose, t0 } while one is picked (this viewer's own, never stored or sent).
1597
+ const preview = useRef(null), [, setPreviewRev] = useState(0);
1446
1598
  // M-3432 (#4255): custom snacks from the active skin pack (client-local, only when play is enabled).
1447
1599
  const snacks = useMemo(() => createSnacks(), []);
1448
1600
  const snackDragCtrl = useMemo(() => createSnackDrag(), []);
@@ -1468,14 +1620,31 @@ export function Office({ view, traffic, q = "", lease, onOpen, assetUrl, assetIm
1468
1620
  // An act's walk; not someone in bed for the night (#2568: bedtime wins, as for mail).
1469
1621
  for (const d of desksOf(L)) { const a = actsHere.get(d.node.name), at = !d.night && actLive(a, d.node.state, Date.now(), actSeen.current) ? actTarget(a, L, walkers, t) : null; if (at) to.set(d.node.name, at); }
1470
1622
  for (const [name, at] of mail.targets(L, t)) to.set(name, at);
1471
- for (const [name, at] of snacks.targets(t)) to.set(name, at);
1472
- const held = hold.held(); // M-3293: carried: where the pointer is, no walk
1473
- if (held) to.set(held.name, held.at);
1474
1623
  // M-3539: a new office or style (a room's office reads its style after it opens) puts everyone at their place at
1475
1624
  // once: walking there from the old one's seats drew the asleep standing in the help desk for seconds.
1476
1625
  const placed = `${officeKey}\n${skin.id}`, fresh = placedRef.current !== placed;
1477
1626
  placedRef.current = placed;
1627
+ // A pack's vehicles: who wants to ride walks to the platform, boards when it stops there, gets off at a stop; a
1628
+ // caller gets off at once. Riders are set down where they are when their vehicle goes (fresh: the sync does).
1629
+ const vehicles = skin.pack.vehicles || [];
1630
+ let boarding = [];
1631
+ if (fresh) riders.clear();
1632
+ if (vehicles.length) {
1633
+ const byId = new Map(vehicles.map((v) => [v.id, v])), wall = Date.now(), here = desksOf(L);
1634
+ const wants = new Map(here.map((d) => { const a = actsHere.get(d.node.name); return [d.node.name, !d.night && rideLive(a, d.node.state, wall) ? a.ride : null]; }));
1635
+ const r = riders.step({ wants, vehicles: byId, wall, posOf: (n) => walkers.at(n, t), homeOf: (n) => (here.find((d) => d.node.name === n) || {}).seat || null,
1636
+ sinceOf: (n) => { const a = actsHere.get(n); return a && a.ride && typeof a.since === "number" ? a.since : null; },
1637
+ urgent: (n) => { const d = here.find((x) => x.node.name === n); return !!d && CALLING.has(d.node.state); } });
1638
+ for (const [name, at] of r.targets) to.set(name, at);
1639
+ boarding = r.board.map((b) => { const v = byId.get(b.vehicle); return [b.name, () => seatAt(v, vehicleAt(v, Date.now()), b.seat)]; });
1640
+ for (const a of r.alight) walkers.place(a.name, a.at);
1641
+ } else for (const n of riders.clear()) { const p = walkers.at(n, t); if (p) walkers.place(n, p); }
1642
+ for (const [name, at] of snacks.targets(t)) to.set(name, at);
1643
+ const held = hold.held(); // M-3293: carried: where the pointer is, no walk
1644
+ if (held) to.set(held.name, held.at);
1645
+ cardStay(to, cardDesk.current, held, walkers, t); // their card is open: no walk, unless calling
1478
1646
  walkers.sync(to, t, L, still, fresh);
1647
+ for (const [name, seat] of boarding) walkers.ride(name, seat);
1479
1648
  // Reduced motion has no loop: drawn again here, or an act's walk (set after the scene was drawn) never shows.
1480
1649
  if (still) { if (scene.current && !globalThis.document?.hidden) draw(0); } else loop.current?.wake();
1481
1650
  };
@@ -1484,7 +1653,7 @@ export function Office({ view, traffic, q = "", lease, onOpen, assetUrl, assetIm
1484
1653
  if (still) return undefined;
1485
1654
  const h = setInterval(go, WANDER.TICK);
1486
1655
  return () => clearInterval(h);
1487
- }, [L, wander, mail, skin, night, actsHere, visitMemo, ownArea]);
1656
+ }, [L, wander, mail, skin, night, actsHere, visitMemo, ownArea, riders]);
1488
1657
  // …and in each tile on a zones style; the traffic within a tile is its own, between tiles the overview's.
1489
1658
  useEffect(() => {
1490
1659
  for (const tl of tiles) if (tl.zones) tl.walkers.sync(new Map(desksOf(tl.L).map((d) => [d.node.name, d.seat])), now(), tl.L, still);
@@ -1592,6 +1761,11 @@ export function Office({ view, traffic, q = "", lease, onOpen, assetUrl, assetIm
1592
1761
  * the whole view on its data-k/x/y), the zoom's percentage, the overlay, the tooltip.
1593
1762
  */
1594
1763
  const mark = () => {
1764
+ // M-3665: too far out to read the name tags (TAG_READ_K) in one office, the stage says so: the people's names then
1765
+ // show as a row of chips over its foot (the CSS: a phone's whole office, or a desk zoomed out), each opening their card.
1766
+ // #4466 Hide names (data-names-off on the same element): the row keeps only the callers, as the tags do.
1767
+ if (ooRef.current && typeof ooRef.current.toggleAttribute === "function") ooRef.current.toggleAttribute("data-tags-off", !overview && view0().k < TAG_READ_K);
1768
+ desksCue();
1595
1769
  const v = view0(), m = miniViewRef.current;
1596
1770
  if (m) {
1597
1771
  const f = miniFrame(v, size, L.width, L.height);
@@ -1687,6 +1861,7 @@ export function Office({ view, traffic, q = "", lease, onOpen, assetUrl, assetIm
1687
1861
  store.saveFitMode(officeKey, next); setFitRev((n) => n + 1);
1688
1862
  fit(next);
1689
1863
  };
1864
+ useEffect(() => { if (!miniOff) mark(); }, [miniOff]); // shown again: placed on the view at once
1690
1865
  /** + / −: the next pixel level about the stage's middle. */
1691
1866
  const zoomStep = (dir) => { const v = view0(), k = stepK(v.k, dir, ratio, kLo); raw.current = k; setView(zoomTo(v, k, size.w / 2, size.h / 2)); };
1692
1867
  /** Bring a box (logical units) into view, unchanged when it already is. */
@@ -1805,25 +1980,25 @@ export function Office({ view, traffic, q = "", lease, onOpen, assetUrl, assetIm
1805
1980
  ? Math.max(0, ...tiles.map((tl) => packMaxFps(tl.skin && tl.skin.pack)))
1806
1981
  : packMaxFps(skin && skin.pack);
1807
1982
  const fps = Math.max(FPS, Math.min(30, Math.ceil(maxPackFps)));
1808
- const base = { ctx, ratio, BW, BH, matte, env, fps, dirty: true };
1983
+ const base = { ctx, ratio, BW, BH, matte, env, fps, dirty: true, namesOff };
1809
1984
  if (overview) {
1810
1985
  // Each tile a scene of its own, where the overview puts it (arranged.tiles, in the same order).
1811
1986
  const parts = tiles.map((tl, i) => ({ ...partOf(tl.L, tileLooks[i], tl.skin, tl.zones, tl.walkers, tl.flights), night, key: tl.key, prefix: tl.prefix, tile: arranged.tiles[i], ups: ups.current, levelsOn: !!(lv && lv.enabled), levels: wordsOf(tl.skin) }));
1812
1987
  scene.current = { ...base, overview: true, parts, lay: arranged };
1813
1988
  } else {
1814
- scene.current = { ...base, overview: false, part: { ...partOf(L, looks, skin, zones, walkers, flights), ghosts, night, mail, acts: actsHere, actSeen: actSeen.current, ups: ups.current, levelsOn: !!(lv && lv.enabled), levels: wordsOf(skin), reacts: reacts.current,
1989
+ scene.current = { ...base, overview: false, part: { ...partOf(L, looks, skin, zones, walkers, flights), ghosts, night, mail, acts: actsHere, actSeen: actSeen.current, ups: ups.current, levelsOn: !!(lv && lv.enabled), levels: wordsOf(skin), reacts: reacts.current, preview, riding: riders.riding,
1815
1990
  hold: play ? hold : null, seatDrop: seatDropRef,
1816
1991
  snacks: play ? snacks : null, snacksById, ownArea, snackDrop: snackDropRef, onSnackClaim, onSnacksChanged: () => walkNow.current?.() } };
1817
1992
  }
1818
1993
  if (still) draw(0); else loop.current?.wake();
1819
- }, [L, looks, skin, pal, size.w, size.h, ratio, matte, overview, tiles, tileLooks, arranged, ghosts, night, mail, actsHere, lv, wordsOf, play, snacksById, ownArea]);
1994
+ }, [L, looks, skin, pal, size.w, size.h, ratio, matte, overview, tiles, tileLooks, arranged, ghosts, night, mail, actsHere, lv, wordsOf, play, snacksById, ownArea, namesOff]);
1820
1995
 
1821
1996
  /** One frame at `ms` (0: still); whether anything is moving (in the air, or someone walking). */
1822
1997
  function draw(ms) {
1823
1998
  const s = scene.current;
1824
1999
  if (!s) return false;
1825
2000
  placeCard();
1826
- const { ctx, BW, BH, env } = s;
2001
+ const { ctx, BW, BH } = s, env = { ...s.env, ratio: s.ratio }; // ratio: drawPart's CSS zoom is a / ratio (Prism #4423)
1827
2002
  s.bubbleHits = [];
1828
2003
  const seenClips = ms > 0 ? new Set() : null;
1829
2004
  const clocked = (prefix) => (seenClips
@@ -1845,7 +2020,8 @@ export function Office({ view, traffic, q = "", lease, onOpen, assetUrl, assetIm
1845
2020
  s.part.cover = r.width > 0 && r.height > 0 ? { x: (r.left - c.left) * s.ratio, y: (r.top - c.top) * s.ratio, w: r.width * s.ratio, h: r.height * s.ratio } : null;
1846
2021
  } else s.part.cover = null;
1847
2022
  const e0 = clocked(""), kc = keepClearOf(canvasRef.current, v);
1848
- const moved = drawPart(ctx, s.part, a, ox, oy, ms, still, tipNow.current, kc.length ? { ...e0, keepClear: kc } : e0, false, null, s.bubbleHits);
2023
+ // M-3665 (too far out to read: no tags) and #4466 (Hide names: callers keep theirs), as the All-offices tiles do.
2024
+ const moved = drawPart(ctx, s.part, a, ox, oy, ms, still, tipNow.current, kc.length ? { ...e0, keepClear: kc } : e0, v.k < TAG_READ_K || (s.namesOff ? "names" : false), null, s.bubbleHits);
1849
2025
  if (seenClips) clipClocks.current.prune(seenClips);
1850
2026
  return drawDialogue(ctx, s, ms) || moved;
1851
2027
  }
@@ -1860,7 +2036,7 @@ export function Office({ view, traffic, q = "", lease, onOpen, assetUrl, assetIm
1860
2036
  ctx.save();
1861
2037
  ctx.setTransform(1, 0, 0, 1, 0, 0);
1862
2038
  ctx.beginPath(); ctx.rect(tx, ty, tw, th); ctx.clip();
1863
- if (drawPart(ctx, p, a * tt.s, tx, ty, ms, still, hot && hot.startsWith(p.prefix) ? hot.slice(p.prefix.length) : null, clocked(p.prefix), v.k * tt.s < TAG_MIN_K, said, s.bubbleHits)) moving = true;
2039
+ if (drawPart(ctx, p, a * tt.s, tx, ty, ms, still, hot && hot.startsWith(p.prefix) ? hot.slice(p.prefix.length) : null, clocked(p.prefix), v.k * tt.s < TAG_MIN_K || (s.namesOff ? "names" : false), said, s.bubbleHits)) moving = true;
1864
2040
  ctx.restore();
1865
2041
  ctx.setTransform(1, 0, 0, 1, 0, 0);
1866
2042
  ctx.strokeStyle = env.pal.border; ctx.lineWidth = 1;
@@ -1956,18 +2132,19 @@ export function Office({ view, traffic, q = "", lease, onOpen, assetUrl, assetIm
1956
2132
  }, [dlgOn, dlgVisible, dlgSay, width, phone, ratio]);
1957
2133
 
1958
2134
  // The loop: drawing only when the frame (FPS) changed or something is in the air; stopped while the tab is hidden,
1959
- // gone with the view. Office review: while something walks or flies, one requestAnimationFrame per display frame (the
2135
+ // gone with the view. Office review: while something walks or flies, a frame every display frame up to AIR_FPS (the
1960
2136
  // motion is smooth); when nothing moves, the poses change at most FPS times a second, so the loop sleeps (a timer)
1961
2137
  // until the next frame's start instead of waking at the display's rate only to find nothing to draw.
1962
2138
  useEffect(() => {
1963
2139
  if (still || typeof requestAnimationFrame !== "function") return undefined;
1964
- let raf = 0, timer = 0, last = -1, lastFps = FPS, air = true, gone = false;
2140
+ let raf = 0, timer = 0, last = -1, lastFps = FPS, air = true, gone = false, drawnAt = -Infinity;
1965
2141
  const tick = () => {
1966
2142
  raf = 0;
1967
2143
  if (gone || globalThis.document?.hidden || !scene.current) return;
1968
2144
  const fps = scene.current.fps || FPS;
1969
2145
  const ms = now(), frame = Math.floor((ms / 1000) * fps); // the clock the trips started on
1970
- if (scene.current.dirty || frame !== last || fps !== lastFps || air) { scene.current.dirty = false; last = frame; lastFps = fps; air = draw(ms); }
2146
+ const due = air && ms - drawnAt >= 1000 / AIR_FPS - 4; // a 60/120 Hz screen: every 2nd/4th frame
2147
+ if (scene.current.dirty || frame !== last || fps !== lastFps || due) { scene.current.dirty = false; last = frame; lastFps = fps; drawnAt = ms; air = draw(ms); }
1971
2148
  if (air) { raf = requestAnimationFrame(tick); return; }
1972
2149
  const wait = Math.max(1, Math.ceil(((frame + 1) * 1000) / fps - ms)); // until the next frame starts
1973
2150
  if (fps > FPS && wait <= 16) { raf = requestAnimationFrame(tick); return; }
@@ -2010,6 +2187,8 @@ export function Office({ view, traffic, q = "", lease, onOpen, assetUrl, assetIm
2010
2187
  area: tl.zones ? areaName(d.area) : roomOf(tl.L, d), skin: tl.skin, look: lk && lk.get(d.key) })) : []; })
2011
2188
  : desksOf(L).map((d) => ({ key: d.key, node: d.node, box: d, office: null, dot: zones ? d.seat : { x: d.x + d.w / 2, y: d.y + d.h / 2 },
2012
2189
  area: zones ? areaName(d.area) : roomOf(L, d), skin, look: looks.get(d.key) }));
2190
+ // The name row's fade (desksCue) follows who is in it and how wide the stage is, as well as the zoom (mark).
2191
+ useEffect(() => { desksCue(); }, [people.length, size.w, namesOff]);
2013
2192
  // #2861: who the dialogue box may speak for — everyone drawn here (All offices: the first tile they are in), with what
2014
2193
  // draws them; null while it is off (draw() then draws nothing of it).
2015
2194
  replyRef.current = tmode === "bubble" ? { chat, draw: chatUi.drawReply, style: chatUi.replyStyle, pace: chatUi.readPace, read: readMode } : null;
@@ -2484,8 +2663,11 @@ export function Office({ view, traffic, q = "", lease, onOpen, assetUrl, assetIm
2484
2663
  const tipText = tipDesk ? nodeText(tipDesk.node) : null;
2485
2664
  // #2661: the card's person (gone from the office, filtered out or the office changed: it closes).
2486
2665
  const cardOf = card ? people.find((d) => d.key === card && d.node.i) || null : null;
2487
- cardDesk.current = cardOf ? { name: cardOf.node.name, box: cardOf.box, walks: zones && !overview, skin: cardOf.skin } : null;
2666
+ cardDesk.current = cardOf ? { name: cardOf.node.name, state: cardOf.node.state, box: cardOf.box, walks: zones && !overview, skin: cardOf.skin } : null;
2488
2667
  useEffect(() => { if (card && !cardOf) setCard(null); }, [card, !!cardOf]);
2668
+ useEffect(() => { walkNow.current?.(); }, [cardOf ? cardOf.node.name : null]); // stop there now; walk again once it closes
2669
+ // A preview ends with its card, or when the card turns to someone else.
2670
+ useEffect(() => { if (preview.current && (!cardOf || preview.current.name !== cardOf.node.name)) { preview.current = null; setPreviewRev((x) => x + 1); loop.current?.wake(); } }, [cardOf ? cardOf.node.name : null]);
2489
2671
  const closeCard = () => {
2490
2672
  setCard(null);
2491
2673
  const from = cardFrom.current; cardFrom.current = null;
@@ -2621,6 +2803,8 @@ export function Office({ view, traffic, q = "", lease, onOpen, assetUrl, assetIm
2621
2803
  ${packs.map((pk) => html`<option key=${`pack:${pk.id}`} value=${pk.id}>${pk.name}</option>`)}
2622
2804
  </select></label>` : null}
2623
2805
  <label class="check oo-hide-asleep"><input type="checkbox" checked=${hideAsleep} onChange=${() => { const v = !hideAsleep; store.saveHideAsleep(v); setHideAsleep(v); setTip(null); }} /><span>${to("hideAsleep")}</span></label>
2806
+ <label class="check oo-hide-names"><input type="checkbox" checked=${namesOff} onChange=${() => { const v = !namesOff; store.saveNamesOff(v); setNamesOff(v); }} /><span>${to("hideNames")}</span></label>
2807
+ <label class="check oo-hide-mini"><input type="checkbox" checked=${miniOff} onChange=${() => { const v = !miniOff; store.saveMiniOff(v); setMiniOff(v); }} /><span>${to("hideMini")}</span></label>
2624
2808
  ${zones && !overview && !shared ? html`<label class="check oo-play"><input type="checkbox" checked=${playOn && !still} disabled=${still}
2625
2809
  onChange=${() => { const v = !playOn; store.savePlayOn(v); setPlayOn(v); }} /><span>${to("playOn")}</span>${playStillOff ? html`<span class="muted oo-note oo-play-still">${to("playMotionOff")}</span>` : null}</label>` : null}
2626
2810
  ${zones || overview ? html`<label class="check oo-night"><input type="checkbox" checked=${nightOn} onChange=${() => { const v = !nightOn; store.saveNightOn(v); setNightOn(v); }} /><span>${to("nightOn")}</span></label>` : null}
@@ -2649,15 +2833,23 @@ export function Office({ view, traffic, q = "", lease, onOpen, assetUrl, assetIm
2649
2833
  ${hasActions ? html`<hr class="oo-sheet-rule" />` : null}${actionItems}`;
2650
2834
  // A room's dropdown hangs from the zoom stack's top, inside the stage (which clips): it is never taller than the
2651
2835
  // stage's room below its top (Prism #3556 P2: a 340 px stage); a longer list scrolls.
2836
+ // The bar's dropdown hangs below the bar: never past the window's bottom either (#4466: a longer list, a short window).
2652
2837
  const fitPop = (el) => {
2653
- if (!el || !roomGear || !stageRef.current || typeof el.getBoundingClientRect !== "function") return;
2838
+ if (!el || typeof el.getBoundingClientRect !== "function") return;
2839
+ if (!roomGear) {
2840
+ const vh = globalThis.innerHeight;
2841
+ if (vh > 0) el.style.maxHeight = `${Math.min(popMaxHeight(vh, el.getBoundingClientRect().top), Math.floor(vh * 0.7), 480)}px`;
2842
+ return;
2843
+ }
2844
+ if (!stageRef.current) return;
2654
2845
  const st = stageRef.current.getBoundingClientRect(), top = el.getBoundingClientRect().top;
2655
2846
  if (st && st.height > 0) el.style.maxHeight = `${popMaxHeight(st.bottom, top)}px`;
2656
2847
  };
2657
2848
  const displayMenu = (opener) => html`<div class=${`oo-display${roomGear ? " oo-display-zoom" : ""}`} ref=${displayRef}>${opener}
2658
2849
  ${dispOpen ? html`<div class="oo-display-pop" role="group" aria-label=${to("display")} ref=${fitPop}><h3 class="oo-display-h">${to("display")}</h3>
2659
2850
  <div class="oo-bar oo-display-list">${optionItems}</div></div>` : null}</div>`;
2660
- return html`<div class=${`oo${fs ? ` fs ${fs}` : ""}${compact ? " phone" : ""}${dockShown ? " has-dialogue" : ""}${sidePanel && !phone ? " ot-side" : ""}`} ref=${ooRef}>
2851
+ return html`<div class=${`oo${fs ? ` fs ${fs}` : ""}${compact ? " phone" : ""}${dockShown ? " has-dialogue" : ""}${sidePanel && !phone ? " ot-side" : ""}`} ref=${ooRef}
2852
+ data-names-off=${namesOff ? "" : undefined}>
2661
2853
  ${folded ? null : html`<div class="oo-bar oo-bar-row">
2662
2854
  <div class="oo-bar-scope">${scopeItems}</div>
2663
2855
  <div class="oo-bar-actions">${actionItems}
@@ -2706,6 +2898,7 @@ export function Office({ view, traffic, q = "", lease, onOpen, assetUrl, assetIm
2706
2898
  // #4379 review: the tags it covers (or uncovers) are judged at the next frame; a still scene draws one now.
2707
2899
  if (was !== el && scene.current) { scene.current.dirty = true; const go = () => (still ? draw(0) : loop.current?.wake()); if (typeof requestAnimationFrame === "function") requestAnimationFrame(go); else go(); } }}
2708
2900
  onChat=${onOpen ? () => { const n = cardOf.node.name; setCard(null); open(n); } : null} onFind=${findCard} onClose=${closeCard}
2901
+ rename=${onOpen && !readOnly ? { value: renames[cardOf.node.name] || "", save: (v) => setRenames(store.saveRename(cardOf.node.name, v)) } : null}
2709
2902
  onReact=${play ? (kind) => {
2710
2903
  const n = cardOf.node.name;
2711
2904
  if (kind === "feed" && !ASLEEP.has(cardOf.node.state) && !cardOf.box.night) {
@@ -2721,16 +2914,22 @@ export function Office({ view, traffic, q = "", lease, onOpen, assetUrl, assetIm
2721
2914
  reacts.current.set(n, { kind, t0, ...(patSt ? { until: t0 + Math.max(PLAY.REACT_MS, stripDurationMs(patSt)) } : {}) });
2722
2915
  loop.current?.wake(); if (store.tellOn(n)) void store.tell(n, kind);
2723
2916
  } : null}
2917
+ preview=${zones && !overview && skin && skin.pack ? {
2918
+ poses: PREVIEW_POSES,
2919
+ pose: preview.current && preview.current.name === cardOf.node.name ? preview.current.pose : "",
2920
+ set: (pose) => { preview.current = pose ? { name: cardOf.node.name, pose, t0: now() } : null; setPreviewRev((x) => x + 1); loop.current?.wake(); },
2921
+ replay: () => { if (preview.current) { preview.current = { ...preview.current, t0: now() }; loop.current?.wake(); } },
2922
+ } : null}
2724
2923
  tell=${play ? { on: store.tellOn(cardOf.node.name), set: (v) => { store.saveTell(cardOf.node.name, v); setTellRev((x) => x + 1); } } : null}
2725
2924
  packCard=${cardOf.skin?.pack?.card || null}
2726
2925
  picture=${typeof cardOf.skin?.picture === "function" ? cardOf.skin.picture : null}
2727
2926
  portrait=${cardOf.skin?.pack ? portraitSrc(cardOf.skin.pack, { agent: cardOf.node.name, state: cardOf.node.state }) : null}
2728
2927
  packScale=${cardOf.skin?.pack?.scale || 2} action=${cardAction ? cardAction(cardOf.node.name) : null}
2729
2928
  photo=${cardPhoto ? cardPhoto(cardOf.node.name) : null} />` : null}
2730
- <ul class="oo-desks" aria-label=${to("desks")}>${people.map((d) => {
2929
+ <ul class="oo-desks" ref=${desksRef} onScroll=${desksCue} aria-label=${to("desks")}>${people.map((d) => {
2731
2930
  const nt = nodeText(d.node), cap = nowOf(d.node), where = d.office ? ` · ${d.office}` : "";
2732
2931
  const full = words ? `${nt.primary} — ${stateOf(d.node)}` : nt.full;
2733
- return html`<li key=${d.key}>${d.node.i
2932
+ return html`<li key=${d.key} data-call=${CALLING.has(d.node.state) ? "" : undefined}>${d.node.i
2734
2933
  ? html`<button type="button" class="oo-desk" data-name=${d.node.name} data-key=${d.key} data-slot=${Number.isInteger(d.box?.slot) ? d.box.slot : undefined} aria-label=${`${full}${where}${cap ? ` · ${cap}` : ""}.`} aria-haspopup="dialog"
2735
2934
  onFocus=${() => setTip(d.key)} onBlur=${() => setTip(null)} onClick=${() => { cardFrom.current = d.key; setCard((cur) => (cur === d.key ? null : d.key)); }}>${nt.primary}</button>`
2736
2935
  : html`<span class="oo-desk" data-name=${d.node.name} data-key=${d.key}>${full}</span>`}</li>`;
@@ -2765,14 +2964,14 @@ export function Office({ view, traffic, q = "", lease, onOpen, assetUrl, assetIm
2765
2964
  : snackDrag.kind === "place" ? html`<span class="oo-snack-hint">${to("snackPlace")}</span>` : null}
2766
2965
  </div>` : null}
2767
2966
  ${fs ? html`<div class="oo-fs-bar">${oneOffice ? null : officeSelect("oo-fs-office")}${carChrome()}</div>` : null}
2768
- <svg ref=${miniRef} class="oc-mini oo-mini" viewBox=${`0 0 ${Math.max(1, L.width)} ${Math.max(1, L.height)}`} aria-hidden="true" onClick=${onMini}>
2967
+ ${miniOff ? null : html`<svg ref=${miniRef} class="oc-mini oo-mini" viewBox=${`0 0 ${Math.max(1, L.width)} ${Math.max(1, L.height)}`} aria-hidden="true" onClick=${onMini}>
2769
2968
  <title>${to("overview")}</title>
2770
2969
  <rect class="oo-mini-matte" x=${-L.width} y=${-L.height} width=${L.width * 3} height=${L.height * 3} fill=${matte} />
2771
2970
  <rect class="oo-mini-scene" x="0" y="0" width=${L.width} height=${L.height} />
2772
2971
  ${miniRects.map((r) => html`<rect key=${r.key} class="oo-mini-room" x=${r.x} y=${r.y} width=${r.w} height=${r.h} />`)}
2773
2972
  ${people.map((d) => html`<circle key=${d.key} class=${`oo-mini-dot st-${d.node.state}${q && hits(d.node, q) ? " match" : ""}`} cx=${d.dot.x} cy=${d.dot.y} r=${dotR} />`)}
2774
2973
  <rect ref=${miniViewRef} class="oc-mini-view oo-mini-view" />
2775
- </svg>
2974
+ </svg>`}
2776
2975
  </div>
2777
2976
  ${zoneList.length ? html`<div class="oo-zone-pills" role="group" aria-label=${to("zones")} ref=${pillsRef} onScroll=${pillsCue}>
2778
2977
  <button type="button" class="btn btn-sm oo-zone-all" onClick=${() => fit()}>${to("zoneAll")}</button>