@parallelworks/code 0.4.0 → 0.5.0

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 (77) hide show
  1. package/README.md +39 -12
  2. package/dist/agentSwitcher.d.ts +13 -2
  3. package/dist/agentSwitcher.js +28 -6
  4. package/dist/ago.d.ts +1 -3
  5. package/dist/ago.js +1 -3
  6. package/dist/api.d.ts +200 -0
  7. package/dist/chatStrings.d.ts +1 -0
  8. package/dist/chatStrings.js +2 -1
  9. package/dist/claudeAccounts.d.ts +20 -2
  10. package/dist/claudeAccounts.js +51 -7
  11. package/dist/claudeApi.d.ts +2 -1
  12. package/dist/claudeApi.js +49 -3
  13. package/dist/command.d.ts +5 -1
  14. package/dist/command.js +6 -1
  15. package/dist/createPwCodeApi.d.ts +70 -1
  16. package/dist/createPwCodeApi.js +4 -2
  17. package/dist/index.d.ts +5 -4
  18. package/dist/index.js +5 -4
  19. package/dist/locales/en/agentTranscript.js +2 -1
  20. package/dist/locales/en/agents.js +16 -3
  21. package/dist/locales/en.d.ts +13 -0
  22. package/dist/locales/es/agentTranscript.js +2 -1
  23. package/dist/locales/es/agents.js +16 -3
  24. package/dist/locales/ja/agentTranscript.js +2 -1
  25. package/dist/locales/ja/agents.js +16 -3
  26. package/dist/locales/ko/agentTranscript.js +2 -1
  27. package/dist/locales/ko/agents.js +16 -3
  28. package/dist/locales/zh/agentTranscript.js +2 -1
  29. package/dist/locales/zh/agents.js +16 -3
  30. package/dist/notices.d.ts +2 -0
  31. package/dist/notices.js +20 -13
  32. package/dist/query.d.ts +4 -1
  33. package/dist/query.js +9 -3
  34. package/dist/session.d.ts +6 -0
  35. package/dist/session.js +5 -1
  36. package/dist/sessionEvents.d.ts +29 -2
  37. package/dist/sessionEvents.js +187 -73
  38. package/dist/sessionGroups.d.ts +3 -3
  39. package/dist/sessionGroups.js +3 -3
  40. package/dist/sessionHeader.js +6 -2
  41. package/dist/sessionList.d.ts +13 -8
  42. package/dist/sessionList.js +20 -10
  43. package/dist/sessionScreen.d.ts +5 -1
  44. package/dist/sessionScreen.js +12 -7
  45. package/dist/sessionsApi.d.ts +19 -3
  46. package/dist/sessionsApi.js +100 -12
  47. package/dist/sessionsFeed.d.ts +22 -0
  48. package/dist/sessionsFeed.js +125 -0
  49. package/dist/todos.d.ts +42 -0
  50. package/dist/todos.js +104 -0
  51. package/dist/transcript.d.ts +1 -2
  52. package/dist/transcript.js +63 -102
  53. package/dist/transcriptRead.d.ts +56 -0
  54. package/dist/transcriptRead.js +121 -0
  55. package/dist/useComposer.d.ts +14 -5
  56. package/dist/useComposer.js +20 -7
  57. package/dist/useComposerImages.js +3 -4
  58. package/dist/useComposerPastes.js +3 -8
  59. package/dist/useConversation.d.ts +6 -0
  60. package/dist/useConversation.js +72 -5
  61. package/dist/useMounted.d.ts +3 -0
  62. package/dist/useMounted.js +14 -0
  63. package/dist/useSubagent.d.ts +2 -0
  64. package/dist/useSubagent.js +2 -0
  65. package/dist/wording.d.ts +5 -2
  66. package/dist/wording.js +6 -4
  67. package/locales/en/agentTranscript.json +2 -1
  68. package/locales/en/agents.json +14 -2
  69. package/locales/es/agentTranscript.json +2 -1
  70. package/locales/es/agents.json +14 -2
  71. package/locales/ja/agentTranscript.json +2 -1
  72. package/locales/ja/agents.json +14 -2
  73. package/locales/ko/agentTranscript.json +2 -1
  74. package/locales/ko/agents.json +14 -2
  75. package/locales/zh/agentTranscript.json +2 -1
  76. package/locales/zh/agents.json +14 -2
  77. package/package.json +2 -2
@@ -8,18 +8,19 @@ var signInRequiredCode = "agents_claude_sign_in_required";
8
8
  function claudeSignInRequired(error) {
9
9
  return error?.code === signInRequiredCode;
10
10
  }
11
+ var ACCOUNT_NAME_MAX = 64;
11
12
  /** The account name `input` gives once trimmed, or null when Claude Code
12
13
  * can't take it. */
13
14
  function claudeAccountName(input) {
14
15
  const name = input.trim();
15
- if (!/^[a-zA-Z0-9_.@-]{1,64}$/.test(name) || name === "." || name === ".." || name.endsWith(".lock")) return null;
16
+ if (!/^[a-zA-Z0-9_.@-]+$/.test(name) || name.length > ACCOUNT_NAME_MAX || name === "." || name === ".." || name.endsWith(".lock")) return null;
16
17
  return name;
17
18
  }
18
19
  function unavailableNotice(allowed, installed, t) {
19
20
  if (!allowed) return t("claude.disabled");
20
21
  return installed ? null : t("claude.notInstalled");
21
22
  }
22
- function viewWords(view, host, hint, t) {
23
+ function viewWords(view, host, hint, handoff, t) {
23
24
  switch (view.kind) {
24
25
  case "signIn": return {
25
26
  title: t("claude.signInTitle"),
@@ -49,7 +50,7 @@ function viewWords(view, host, hint, t) {
49
50
  removeBody: null
50
51
  };
51
52
  default: return {
52
- title: t("claude.accounts"),
53
+ title: handoff ? t("claude.continueOnAnother") : t("claude.accounts"),
53
54
  description: t("claude.hostAccounts", { host }),
54
55
  signInNote: hint ?? t("claude.loginStaysOnHost", { host }),
55
56
  removeBody: null
@@ -104,7 +105,7 @@ function accountDetail(account, hint) {
104
105
  /** The Claude Code accounts on a machine, and the steps a panel listing them
105
106
  * takes: adding, signing in, removing after a confirmation the host shows,
106
107
  * and choosing one for the `account` setting. */
107
- function useClaudeAccountPanel(calls, { machine, machineName, sessionId, claudeInstalled, claudeAllowed, claudeLogin = false, claudeAccountRemove = false, account, onClose }) {
108
+ function useClaudeAccountPanel(calls, { machine, machineName, sessionId, claudeInstalled, claudeAllowed, claudeLogin = false, claudeAccountRemove = false, waitingAtLimit, account, onClose, onMovedOthers, onMoveError }) {
108
109
  const t = usePwCodeTranslations("agents");
109
110
  const [adding, setAdding] = useState(false);
110
111
  const [signIn, setSignIn] = useState(null);
@@ -112,10 +113,19 @@ function useClaudeAccountPanel(calls, { machine, machineName, sessionId, claudeI
112
113
  const [refreshError, setRefreshError] = useState(null);
113
114
  const [refreshingModels, setRefreshingModels] = useState(false);
114
115
  const available = claudeAllowed && claudeInstalled;
115
- const catalog = calls.useClaudeAccounts(machine, sessionId, available);
116
+ const catalog = calls.useClaudeAccounts(machine, sessionId, available, waitingAtLimit);
116
117
  const refreshModels = calls.useRefreshClaudeModels(machine, sessionId);
117
118
  const deleteAccount = calls.useRemoveClaudeAccount(machine, sessionId);
118
119
  const selected = account.value || void 0;
120
+ const takeAlong = useTakeAlong(calls, {
121
+ machine,
122
+ sessionId,
123
+ waitingAtLimit,
124
+ selected,
125
+ accounts: catalog.accounts,
126
+ onMovedOthers,
127
+ onMoveError
128
+ });
119
129
  const disabled = useRef(account.disabled);
120
130
  disabled.current = account.disabled;
121
131
  useEffect(() => {
@@ -147,6 +157,7 @@ function useClaudeAccountPanel(calls, { machine, machineName, sessionId, claudeI
147
157
  };
148
158
  const select = (name) => {
149
159
  account.onChange(name);
160
+ takeAlong.to(name);
150
161
  onClose();
151
162
  };
152
163
  const unlessDisabled = (run) => () => {
@@ -184,11 +195,12 @@ function useClaudeAccountPanel(calls, { machine, machineName, sessionId, claudeI
184
195
  } : { kind: "list" };
185
196
  const hint = signInHint(claudeLogin, t);
186
197
  const canAdd = claudeLogin && !account.disabled;
198
+ const controls = listControls(view, available, canAdd);
187
199
  return {
188
200
  available,
189
201
  notice: unavailableNotice(claudeAllowed, claudeInstalled, t),
190
202
  view,
191
- ...viewWords(view, machineName, hint, t),
203
+ ...viewWords(view, machineName, hint, takeAlong.handoff, t),
192
204
  emptyHint: hint,
193
205
  accounts: catalog.accounts,
194
206
  loading: catalog.loading,
@@ -197,7 +209,7 @@ function useClaudeAccountPanel(calls, { machine, machineName, sessionId, claudeI
197
209
  empty: !catalog.loading && !catalog.error && catalog.accounts.length === 0,
198
210
  refreshing: catalog.refreshing || refreshingModels,
199
211
  canAdd,
200
- ...listControls(view, available, canAdd),
212
+ ...controls,
201
213
  ...startRows(catalog.accounts, account.value, claudeLogin),
202
214
  isDisabled: (a) => !!account.disabled || !!a.signInRequired && !claudeLogin,
203
215
  detail: (a) => accountDetail(a, hint),
@@ -231,6 +243,37 @@ function useClaudeAccountPanel(calls, { machine, machineName, sessionId, claudeI
231
243
  await deleteAccount(name);
232
244
  if (account.value === name && !account.disabled) account.onChange("default");
233
245
  setRemoving(null);
246
+ },
247
+ handoff: takeAlong.handoff,
248
+ others: takeAlong.others,
249
+ moveOthersLabel: controls.showRefresh && takeAlong.others > 0 && !account.disabled ? t("claude.moveOthers", {
250
+ count: takeAlong.others,
251
+ account: takeAlong.from
252
+ }) : null,
253
+ moveOthers: takeAlong.moveOthers,
254
+ setMoveOthers: takeAlong.setMoveOthers
255
+ };
256
+ }
257
+ /** The other sessions on the account a session leaves, which share its limit,
258
+ * and their move along with it while the reader leaves them ticked. */
259
+ function useTakeAlong(calls, { machine, sessionId, waitingAtLimit, selected, accounts, onMovedOthers, onMoveError }) {
260
+ const t = usePwCodeTranslations("agents");
261
+ const [moveOthers, setMoveOthers] = useState(true);
262
+ const moveSessions = calls.useMoveClaudeAccountSessions(machine, sessionId);
263
+ const handoff = !!sessionId && waitingAtLimit === true;
264
+ const from = selected ?? "default";
265
+ const others = handoff ? accounts.find((a) => a.name === from)?.sessions?.filter((id) => id !== sessionId).length ?? 0 : 0;
266
+ return {
267
+ handoff,
268
+ from,
269
+ others,
270
+ moveOthers,
271
+ setMoveOthers,
272
+ to: (name) => {
273
+ if (moveOthers && others > 0 && name !== from) moveSessions(from, name).then((moved) => onMovedOthers?.(t("claude.movedOthers", {
274
+ count: moved.length,
275
+ account: name
276
+ }), moved.length, name), (cause) => onMoveError?.(cause));
234
277
  }
235
278
  };
236
279
  }
@@ -263,6 +306,7 @@ function useClaudeAccountName(onContinue) {
263
306
  return {
264
307
  name,
265
308
  invalid,
309
+ maxLength: ACCOUNT_NAME_MAX,
266
310
  change: (value) => {
267
311
  setName(value);
268
312
  setInvalid(false);
@@ -10,7 +10,7 @@ export declare function claudeApi(client: PwCodeClient): {
10
10
  useClaudeModels: (machine: string, sessionId: string | undefined, account: string | undefined, enabled: boolean, refresh?: boolean) => PwCodeQuery<ClaudeModels>;
11
11
  useRefreshClaudeModels: (machine: string, sessionId: string | undefined) => (account: string | undefined) => Promise<void>;
12
12
  useClaudeAccountNames: (machine: string, enabled: boolean) => PwCodeQuery<ClaudeAccounts>;
13
- useClaudeAccounts: (machine: string, sessionId: string | undefined, enabled: boolean) => {
13
+ useClaudeAccounts: (machine: string, sessionId: string | undefined, enabled: boolean, fresh?: boolean) => {
14
14
  accounts: ClaudeAccount[];
15
15
  loadedUsage: boolean;
16
16
  loading: boolean;
@@ -19,6 +19,7 @@ export declare function claudeApi(client: PwCodeClient): {
19
19
  refresh: () => Promise<void>;
20
20
  };
21
21
  useRemoveClaudeAccount: (machine: string, sessionId: string | undefined) => (name: string) => Promise<void>;
22
+ useMoveClaudeAccountSessions: (machine: string, sessionId: string | undefined) => (from: string, to: string) => Promise<string[]>;
22
23
  startClaudeLogin: (machine: string, account: string, sessionId: string | undefined, columns: number, rows: number) => Promise<ClaudeLoginEvent>;
23
24
  writeClaudeLogin: (machine: string, loginId: string, input: ClaudeLoginInput) => Promise<void>;
24
25
  cancelClaudeLogin: (machine: string, loginId: string) => Promise<void>;
package/dist/claudeApi.js CHANGED
@@ -1,6 +1,6 @@
1
1
  import "./apiClient.js";
2
2
  import { createQuery } from "./query.js";
3
- import { useState } from "react";
3
+ import { useEffect, useRef, useState } from "react";
4
4
  import { useSWRConfig } from "swr";
5
5
  // src/claudeApi.ts
6
6
  var cache = {
@@ -55,6 +55,15 @@ function sessionAccountOptions(machine, id, namesOnly, refresh = false) {
55
55
  }
56
56
  } };
57
57
  }
58
+ /** An account's usage with the sessions its names read gave, as that read is repeated more often. */
59
+ function withNamedSessions(named, usage) {
60
+ if (!usage) return named;
61
+ const { sessions: _stale, ...rest } = usage;
62
+ return named.sessions ? {
63
+ ...rest,
64
+ sessions: named.sessions
65
+ } : rest;
66
+ }
58
67
  function claudeLoginFinished(status) {
59
68
  return status !== "running" && status !== "checking";
60
69
  }
@@ -107,12 +116,19 @@ function claudeApi(client) {
107
116
  function useClaudeAccountNames(machine, enabled) {
108
117
  return useQuery(hostAccountsPath, enabled && machine ? hostAccountOptions(machine, true) : null, cache);
109
118
  }
110
- function useClaudeAccounts(machine, sessionId, enabled) {
119
+ /** With `fresh`, the names, which say what sessions each account runs, are read again on mount. */
120
+ function useClaudeAccounts(machine, sessionId, enabled, fresh) {
111
121
  const { mutate } = useSWRConfig();
112
122
  const [refreshing, setRefreshing] = useState(false);
113
123
  const hostNames = useClaudeAccountNames(machine, enabled && !sessionId);
114
124
  const sessionNames = useQuery(sessionAccountsPath, enabled && machine && sessionId ? sessionAccountOptions(machine, sessionId, true) : null, cache);
115
125
  const names = sessionId ? sessionNames : hostNames;
126
+ const reloadNames = names.mutate;
127
+ const cachedNames = useRef(false);
128
+ cachedNames.current = names.data !== void 0;
129
+ useEffect(() => {
130
+ if (fresh && cachedNames.current) reloadNames();
131
+ }, [fresh, reloadNames]);
116
132
  const hostUsage = useQuery(hostAccountsPath, enabled && machine && !sessionId && names.data ? hostAccountOptions(machine, false) : null, cache);
117
133
  const sessionUsage = useQuery(sessionAccountsPath, enabled && machine && sessionId && names.data ? sessionAccountOptions(machine, sessionId, false) : null, cache);
118
134
  const usage = sessionId ? sessionUsage : hostUsage;
@@ -135,7 +151,7 @@ function claudeApi(client) {
135
151
  }
136
152
  };
137
153
  return {
138
- accounts: (names.data ?? []).map((a) => metadata.get(a.name) ?? a),
154
+ accounts: (names.data ?? []).map((a) => withNamedSessions(a, metadata.get(a.name))),
139
155
  loadedUsage: !!usage.data,
140
156
  loading: names.isLoading,
141
157
  error: names.error ?? usage.error,
@@ -167,6 +183,35 @@ function claudeApi(client) {
167
183
  ], drop, { revalidate: namesOnly })] : []]));
168
184
  };
169
185
  }
186
+ /** Moves the live sessions on one account but this one to another,
187
+ * answering with those moved; the account lists read again. */
188
+ function useMoveClaudeAccountSessions(machine, sessionId) {
189
+ const { mutate } = useSWRConfig();
190
+ return async (from, to) => {
191
+ const { data, error } = await client.POST("/api/code/machines/{machine}/claude-code/accounts/{name}/move", {
192
+ params: { path: {
193
+ machine,
194
+ name: from
195
+ } },
196
+ body: {
197
+ to,
198
+ ...sessionId ? { except: sessionId } : {}
199
+ },
200
+ signal: deadline(6e4)
201
+ });
202
+ if (error) throw error;
203
+ await Promise.all([mutate([
204
+ "api",
205
+ hostAccountsPath,
206
+ hostAccountOptions(machine, true)
207
+ ]), sessionId && mutate([
208
+ "api",
209
+ sessionAccountsPath,
210
+ sessionAccountOptions(machine, sessionId, true)
211
+ ])]);
212
+ return data?.moved ?? [];
213
+ };
214
+ }
170
215
  async function startClaudeLogin(machine, account, sessionId, columns, rows) {
171
216
  const { data, error } = await client.POST(loginsPath, {
172
217
  params: { path: { machine } },
@@ -241,6 +286,7 @@ function claudeApi(client) {
241
286
  useClaudeAccountNames,
242
287
  useClaudeAccounts,
243
288
  useRemoveClaudeAccount,
289
+ useMoveClaudeAccountSessions,
244
290
  startClaudeLogin,
245
291
  writeClaudeLogin,
246
292
  cancelClaudeLogin,
package/dist/command.d.ts CHANGED
@@ -4,6 +4,10 @@ export interface PwCodeSlashCommand {
4
4
  description?: string | undefined;
5
5
  usage?: string | undefined;
6
6
  }
7
+ /** A palette entry with what it takes after its name, for the composer to show. */
8
+ export interface PwCodePaletteOption extends PwCodeSlashCommand {
9
+ argumentHint?: string | undefined;
10
+ }
7
11
  /** What a session can run from a slash, as far as typed text is dispatched by
8
12
  * it. A host that types its API from a spec asserts its type extends this. */
9
13
  export interface PwCodePalette {
@@ -35,7 +39,7 @@ export type SlashAction = {
35
39
  * custom commands, and MCP prompts expand into a turn, so they are messages;
36
40
  * built-ins run as commands, five of them on routes of their own. */
37
41
  export declare function slashAction(text: string, palette: PwCodePalette | null): SlashAction;
38
- export declare function paletteOptions(palette: PwCodePalette | null, claudeAccountDescription?: string, archiveDescription?: string): PwCodeSlashCommand[];
42
+ export declare function paletteOptions(palette: PwCodePalette | null, claudeAccountDescription?: string, archiveDescription?: string): PwCodePaletteOption[];
39
43
  /** The command a `!` line runs, read as the terminal reads it: empty for a bare
40
44
  * `!`, which runs nothing, and null for text that is not a shell escape. */
41
45
  export declare function shellCommand(text: string): string | null;
package/dist/command.js CHANGED
@@ -36,7 +36,8 @@ function paletteOptions(palette, claudeAccountDescription, archiveDescription) {
36
36
  const commands = [...palette?.commands ?? [], ...palette?.mcpPrompts ?? []].filter((c) => c.name !== "claude-code").map((c) => ({
37
37
  name: c.name,
38
38
  description: c.description,
39
- usage: c.usage
39
+ usage: c.usage,
40
+ argumentHint: argumentHint(c)
40
41
  }));
41
42
  if (archiveDescription !== void 0 && !commands.some((c) => c.name === "archive")) {
42
43
  const at = commands.findIndex((c) => c.name > "archive");
@@ -51,6 +52,10 @@ function paletteOptions(palette, claudeAccountDescription, archiveDescription) {
51
52
  description: claudeAccountDescription
52
53
  }, ...commands];
53
54
  }
55
+ function argumentHint(c) {
56
+ const name = `/${c.name} `;
57
+ return c.usage?.startsWith(name) ? c.usage.slice(name.length).trim() || void 0 : void 0;
58
+ }
54
59
  /** The command a `!` line runs, read as the terminal reads it: empty for a bare
55
60
  * `!`, which runs nothing, and null for text that is not a shell escape. */
56
61
  function shellCommand(text) {
@@ -29,12 +29,13 @@ export declare function createPwCodeApi<P extends {}>(client: Client<P> & Covers
29
29
  name: string;
30
30
  plan?: string;
31
31
  refreshing?: boolean;
32
+ sessions?: string[] | null;
32
33
  signInRequired?: boolean;
33
34
  usage?: string;
34
35
  weeklyResetsAt?: string;
35
36
  weeklyUsedPercent?: number;
36
37
  }[] | null>;
37
- useClaudeAccounts: (machine: string, sessionId: string | undefined, enabled: boolean) => {
38
+ useClaudeAccounts: (machine: string, sessionId: string | undefined, enabled: boolean, fresh?: boolean) => {
38
39
  accounts: {
39
40
  email?: string;
40
41
  error?: string;
@@ -45,6 +46,7 @@ export declare function createPwCodeApi<P extends {}>(client: Client<P> & Covers
45
46
  name: string;
46
47
  plan?: string;
47
48
  refreshing?: boolean;
49
+ sessions?: string[] | null;
48
50
  signInRequired?: boolean;
49
51
  usage?: string;
50
52
  weeklyResetsAt?: string;
@@ -57,6 +59,7 @@ export declare function createPwCodeApi<P extends {}>(client: Client<P> & Covers
57
59
  refresh: () => Promise<void>;
58
60
  };
59
61
  useRemoveClaudeAccount: (machine: string, sessionId: string | undefined) => (name: string) => Promise<void>;
62
+ useMoveClaudeAccountSessions: (machine: string, sessionId: string | undefined) => (from: string, to: string) => Promise<string[]>;
60
63
  startClaudeLogin: (machine: string, account: string, sessionId: string | undefined, columns: number, rows: number) => Promise<import("./claudeApi.js").ClaudeLoginEvent>;
61
64
  writeClaudeLogin: (machine: string, loginId: string, input: import("./claudeApi.js").ClaudeLoginInput) => Promise<void>;
62
65
  cancelClaudeLogin: (machine: string, loginId: string) => Promise<void>;
@@ -159,6 +162,8 @@ export declare function createPwCodeApi<P extends {}>(client: Client<P> & Covers
159
162
  status: "idle" | "running" | "awaiting_approval" | "live_elsewhere";
160
163
  turnStartedAt?: string;
161
164
  updatedAt: string;
165
+ usageLimitResumeAt?: string;
166
+ waitingForUsageLimit?: boolean;
162
167
  workspace: string;
163
168
  } | undefined) => {
164
169
  data: {
@@ -202,6 +207,47 @@ export declare function createPwCodeApi<P extends {}>(client: Client<P> & Covers
202
207
  workspace: string;
203
208
  workspaceUntrusted?: boolean;
204
209
  } | undefined;
210
+ preview: {
211
+ addDirs?: import("./api.js").components["schemas"]["AddedDirectory"][] | null;
212
+ allocation?: string;
213
+ allowedDirs?: import("./api.js").components["schemas"]["AllowedDirectory"][] | null;
214
+ approvals?: import("./api.js").components["schemas"]["ApprovalRequest"][] | null;
215
+ archivedAt?: string;
216
+ autoName?: string;
217
+ branch?: string;
218
+ claudeAccount?: string;
219
+ createdAt: string;
220
+ effort?: string;
221
+ goal?: import("./api.js").components["schemas"]["GoalStatus"];
222
+ group?: string;
223
+ history: import("./api.js").components["schemas"]["HistoryItem"][] | null;
224
+ id: string;
225
+ inputTokens?: number;
226
+ lastError?: string;
227
+ lastSeq?: number;
228
+ liveHost?: string;
229
+ machineId: string;
230
+ messages: number;
231
+ model: string;
232
+ name?: string;
233
+ outputTokens?: number;
234
+ permissionMode?: string;
235
+ pinnedAt?: string;
236
+ preview: string;
237
+ pullRequestStates?: {
238
+ [key: string]: string;
239
+ };
240
+ pullRequests?: string[] | null;
241
+ remoteControl?: boolean;
242
+ status: "idle" | "running" | "awaiting_approval" | "live_elsewhere";
243
+ turnId?: string;
244
+ turnStartedAt?: string;
245
+ updatedAt: string;
246
+ usageLimitResumeAt?: string;
247
+ waitingForUsageLimit?: boolean;
248
+ workspace: string;
249
+ workspaceUntrusted?: boolean;
250
+ } | undefined;
205
251
  error: PwCodeApiError | undefined;
206
252
  isLoading: boolean;
207
253
  mutate: import("swr").KeyedMutator<{
@@ -270,6 +316,7 @@ export declare function createPwCodeApi<P extends {}>(client: Client<P> & Covers
270
316
  };
271
317
  stopSubagent: (machine: string, id: string, subId: string) => Promise<unknown>;
272
318
  stopAllSubagents: (machine: string, id: string) => Promise<unknown>;
319
+ dismissSubagent: (machine: string, id: string, subId: string) => Promise<unknown>;
273
320
  useSessionWorktree: (s: {
274
321
  allocation?: string;
275
322
  approvals?: import("./api.js").components["schemas"]["ApprovalRequest"][] | null;
@@ -299,6 +346,8 @@ export declare function createPwCodeApi<P extends {}>(client: Client<P> & Covers
299
346
  status: "idle" | "running" | "awaiting_approval" | "live_elsewhere";
300
347
  turnStartedAt?: string;
301
348
  updatedAt: string;
349
+ usageLimitResumeAt?: string;
350
+ waitingForUsageLimit?: boolean;
302
351
  workspace: string;
303
352
  } | undefined) => import("./apiClient.js").PwCodeQuery<Schemas['AgentSessionWorktree']>;
304
353
  leaveWorktree: (s: {
@@ -330,6 +379,8 @@ export declare function createPwCodeApi<P extends {}>(client: Client<P> & Covers
330
379
  status: "idle" | "running" | "awaiting_approval" | "live_elsewhere";
331
380
  turnStartedAt?: string;
332
381
  updatedAt: string;
382
+ usageLimitResumeAt?: string;
383
+ waitingForUsageLimit?: boolean;
333
384
  workspace: string;
334
385
  }, removeRoot?: string) => Promise<{
335
386
  left?: Schemas['AgentWorktreeLeft'];
@@ -365,6 +416,8 @@ export declare function createPwCodeApi<P extends {}>(client: Client<P> & Covers
365
416
  status: "idle" | "running" | "awaiting_approval" | "live_elsewhere";
366
417
  turnStartedAt?: string;
367
418
  updatedAt: string;
419
+ usageLimitResumeAt?: string;
420
+ waitingForUsageLimit?: boolean;
368
421
  workspace: string;
369
422
  }, removeWorktree?: string) => Promise<unknown>;
370
423
  renameSession: (s: {
@@ -396,6 +449,8 @@ export declare function createPwCodeApi<P extends {}>(client: Client<P> & Covers
396
449
  status: "idle" | "running" | "awaiting_approval" | "live_elsewhere";
397
450
  turnStartedAt?: string;
398
451
  updatedAt: string;
452
+ usageLimitResumeAt?: string;
453
+ waitingForUsageLimit?: boolean;
399
454
  workspace: string;
400
455
  }, name: string) => Promise<unknown>;
401
456
  archiveSession: (s: {
@@ -427,6 +482,8 @@ export declare function createPwCodeApi<P extends {}>(client: Client<P> & Covers
427
482
  status: "idle" | "running" | "awaiting_approval" | "live_elsewhere";
428
483
  turnStartedAt?: string;
429
484
  updatedAt: string;
485
+ usageLimitResumeAt?: string;
486
+ waitingForUsageLimit?: boolean;
430
487
  workspace: string;
431
488
  }) => Promise<unknown>;
432
489
  archiveAfterTurn: (s: {
@@ -458,6 +515,8 @@ export declare function createPwCodeApi<P extends {}>(client: Client<P> & Covers
458
515
  status: "idle" | "running" | "awaiting_approval" | "live_elsewhere";
459
516
  turnStartedAt?: string;
460
517
  updatedAt: string;
518
+ usageLimitResumeAt?: string;
519
+ waitingForUsageLimit?: boolean;
461
520
  workspace: string;
462
521
  }) => Promise<{
463
522
  refusal: unknown;
@@ -492,6 +551,8 @@ export declare function createPwCodeApi<P extends {}>(client: Client<P> & Covers
492
551
  status: "idle" | "running" | "awaiting_approval" | "live_elsewhere";
493
552
  turnStartedAt?: string;
494
553
  updatedAt: string;
554
+ usageLimitResumeAt?: string;
555
+ waitingForUsageLimit?: boolean;
495
556
  workspace: string;
496
557
  }) => Promise<unknown>;
497
558
  pinSession: (s: {
@@ -523,6 +584,8 @@ export declare function createPwCodeApi<P extends {}>(client: Client<P> & Covers
523
584
  status: "idle" | "running" | "awaiting_approval" | "live_elsewhere";
524
585
  turnStartedAt?: string;
525
586
  updatedAt: string;
587
+ usageLimitResumeAt?: string;
588
+ waitingForUsageLimit?: boolean;
526
589
  workspace: string;
527
590
  }, pinned: boolean) => Promise<unknown>;
528
591
  groupSession: (s: {
@@ -554,6 +617,8 @@ export declare function createPwCodeApi<P extends {}>(client: Client<P> & Covers
554
617
  status: "idle" | "running" | "awaiting_approval" | "live_elsewhere";
555
618
  turnStartedAt?: string;
556
619
  updatedAt: string;
620
+ usageLimitResumeAt?: string;
621
+ waitingForUsageLimit?: boolean;
557
622
  workspace: string;
558
623
  }, group: string | null) => Promise<unknown>;
559
624
  stopSession: (s: {
@@ -585,6 +650,8 @@ export declare function createPwCodeApi<P extends {}>(client: Client<P> & Covers
585
650
  status: "idle" | "running" | "awaiting_approval" | "live_elsewhere";
586
651
  turnStartedAt?: string;
587
652
  updatedAt: string;
653
+ usageLimitResumeAt?: string;
654
+ waitingForUsageLimit?: boolean;
588
655
  workspace: string;
589
656
  }) => Promise<unknown>;
590
657
  forkSession: (s: {
@@ -616,6 +683,8 @@ export declare function createPwCodeApi<P extends {}>(client: Client<P> & Covers
616
683
  status: "idle" | "running" | "awaiting_approval" | "live_elsewhere";
617
684
  turnStartedAt?: string;
618
685
  updatedAt: string;
686
+ usageLimitResumeAt?: string;
687
+ waitingForUsageLimit?: boolean;
619
688
  workspace: string;
620
689
  }) => Promise<{
621
690
  forked?: Schemas['AgentSessionForked'];
@@ -5,6 +5,7 @@ import { directoriesApi } from "./directories.js";
5
5
  import { createQuery } from "./query.js";
6
6
  import { reachedByFeed, sessionEvents } from "./sessionEvents.js";
7
7
  import { sessionsApi } from "./sessionsApi.js";
8
+ import { sessionsFeed } from "./sessionsFeed.js";
8
9
  import { settingsApi } from "./settingsApi.js";
9
10
  import { useMemo } from "react";
10
11
  // src/createPwCodeApi.ts
@@ -15,8 +16,9 @@ import { useMemo } from "react";
15
16
  function createPwCodeApi(client, options = {}) {
16
17
  const routes = client;
17
18
  const useQuery = createQuery(routes);
18
- const sessions = sessionsApi(routes, options);
19
- const { useSessionEvents, useFedMachines } = sessionEvents(options);
19
+ const { useSessionEvents, useFedMachines, listed } = sessionEvents(options);
20
+ const feed = sessionsFeed(options, (listing) => listed(listing.machines ?? []));
21
+ const sessions = sessionsApi(routes, options, listed, feed);
20
22
  /** The AI chat a new session is to carry on, for `chatHandoffStart`;
21
23
  * undefined without one. */
22
24
  function useChatHandoff(chat) {
package/dist/index.d.ts CHANGED
@@ -22,11 +22,11 @@ export { type ClaudeSignInCalls, type ClaudeSignInState, type ClaudeSignInTermin
22
22
  export { type ClaudeAccount, type ClaudeAccountAction, type ClaudeAccountCalls, type ClaudeAccountDetail, type ClaudeAccountPanelState, type ClaudeAccountUsage, type ClaudeAccountView, type ClaudeUsageLimit, type ClaudeUsageReset, claudeAccountName, claudeSignInRequired, useClaudeAccountName, useClaudeAccountPanel, useClaudeAccountRemoval, useClaudeAccountStartRow, useClaudeAccountUsage, } from './claudeAccounts.js';
23
23
  export { changesSubagents, reachedByFeed, sessionEventsPath, } from './sessionEvents.js';
24
24
  export { githubAttachmentAsset, isSessionImageUrl, sessionGitHubImageUrl, sessionImageUrl, } from './images.js';
25
- export { type PwCodePalette, type PwCodeSlashCommand, paletteOptions, type SlashAction, shellCommand, slashAction, steerMayHaveLanded, } from './command.js';
25
+ export { type PwCodePalette, type PwCodePaletteOption, type PwCodeSlashCommand, paletteOptions, type SlashAction, shellCommand, slashAction, steerMayHaveLanded, } from './command.js';
26
26
  export { canStartHere, isComputer, isConnected, isMachineDown, isUnreachableError, machinesById, type PwCodeMachine, splitMachines, type TerminalHandoff, terminalHandoff, } from './machine.js';
27
27
  export { isPwCodeLocale, loadPwCodeMessages, type PwCodeLocale, type PwCodeMessages, type PwCodeNamespace, type PwCodeTranslator, pwCodeLocales, pwCodeNamespaces, usePwCodeTranslations, } from './messages.js';
28
28
  export { type PwCodeChatStrings, usePwCodeChatStrings } from './chatStrings.js';
29
- export { turnDuration, useCompactionNotice, useGoalNotice, useRecapNotice, useResumeTime, useTranscriptWords, } from './notices.js';
29
+ export { turnDuration, useCompactionNotice, useGoalNotice, useRecapNotice, useResumeClock, useResumeTime, useTranscriptWords, } from './notices.js';
30
30
  export { useCompactAgo } from './ago.js';
31
31
  export { pastedPullRequestLabel, pullRequestKind, pullRequestLabel, pullRequestShortLabel, } from './pullRequest.js';
32
32
  export { donePullRequestsToFold, FOLD_DONE_PULL_REQUESTS_FROM, foldPullRequests, isPullRequestState, type LabeledPullRequest, labeledPullRequests, orderPullRequests, type PullRequestFold, type PullRequestFoldGroup, type PullRequestState, type PullRequestStateOf, type PullRequestTone, type PullRequestWords, pullRequestFoldGroups, pullRequestGroupState, pullRequestStateBreaks, pullRequestStateOf, pullRequestTone, pullRequestWords, } from './pullRequestList.js';
@@ -35,11 +35,12 @@ export { handoffCommandParts, type TerminalHandoffPanel, terminalHandoffPanel, }
35
35
  export { type UsageLimitWait, useUsageLimitWait } from './usageLimit.js';
36
36
  export { type PwCodeWorktreeRef, useFollowedWorktree } from './sessionHeader.js';
37
37
  export { type HowSessionsAppearStep, howSessionsAppear, } from './howSessionsAppear.js';
38
- export { isActiveSession, isArchived, isMidTurn, isSession, needsYou, newestFirst, pathBasename, type PwCodePendingApprovals, type PwCodeSession, type RecentDirectory, recentDirectories, sessionClock, sessionKey, sessionStatusVariant, sessionVariant, sharedStoreCopy, spansMachines, triageSessions, waitsOnAnswer, } from './session.js';
38
+ export { isActiveSession, isArchived, isMidTurn, isSession, needsYou, newestFirst, pathBasename, type PwCodePendingApprovals, type PwCodeSession, type RecentDirectory, recentDirectories, sessionClock, sessionKey, sessionStatusVariant, sessionVariant, sharedStoreCopy, spansMachines, triageSessions, waitsOnAnswer, waitsOnUsageLimit, } from './session.js';
39
39
  export { groupOf, inFlightFirst, isWorking, type ListedGroup, listGroups, patchGroup, type SessionGroup, type SessionGroups, useSessionGroups, } from './sessionGroups.js';
40
40
  export { type GroupDeleteWords, groupSectionKey, isUngroupedTarget, type PwCodeSearchScorer, searchedSessions, type SessionDropTarget, type SessionGroupKey, type SessionList, type SessionListOptions, type SessionSection, type SessionSectionKind, sessionMark, sessionRailLabel, sessionRowState, sessionSearchScore, sessionSearchStatus, sessionSearchText, sessionSections, showsPinMark, useRetainedSessions, useSessionList, withArchiveSection, } from './sessionList.js';
41
41
  export { type NamePromptWords, nameToSave, type OpenSessionRef, type SessionActions, type SessionActionsOptions, type SessionConfirmation, type SessionMenuAction, type SessionMenuCommand, type SessionMenuItem, type SessionRename, type SessionRowKey, type SessionSubmenu, useSessionActions, } from './sessionActions.js';
42
42
  export { appendOwnMessage, appendSteeredMessage, applyStreamEvent, approvalAnswerBody, approvalToPart, bashRunning, type CompactionNotice, dropMessage, type GoalNotice, historyToMessages, type ImageUrl, initialTranscript, liveSessionStatus, pendingApprovals, pendingMessages, type RecapNotice, resolveApprovalEverywhere, reviewingCount, resumeCursor, type StreamEffect, subagentFrame, subagentSessionDetail, type TranscriptState, type TranscriptWords, turnRunning, type TurnVerb, } from './transcript.js';
43
+ export { type PwCodeTodoPanel, type PwCodeTodoRow, todoLabel, todoWindow, useTodoPanel, } from './todos.js';
43
44
  export { useToolStrings } from './toolStrings.js';
44
45
  export { type PwCodeSendResult, type PwCodeSteerResult, type PwCodeTakenBack, type PwCodeWithdrawResult, usePwCodeTranscript, } from './useTranscript.js';
45
46
  export { type PwCodeConversation, type PwCodeConversationState, type PwCodeNotice, transcriptMessages, usePwCodeConversation, } from './useConversation.js';
@@ -50,7 +51,7 @@ export { fitImageWith, type PwCodeImageFit } from './imageFit.js';
50
51
  export { loadErrorMessage } from './loadError.js';
51
52
  export { markdownImageLink, markdownImageSources, type PwCodeMarkdownImage, } from './images.js';
52
53
  export { type PwCodeSubagent, usePwCodeSubagent } from './useSubagent.js';
53
- export { agentMark, type PwCodeAgentLine, type PwCodeAgentState, type PwCodeAgentSwitcher, type PwCodeStateTone, type PwCodeSwitcherAgent, type PwCodeSwitcherCount, type PwCodeSwitcherRow, switcherAgent, useAgentTypeLabel, usePwCodeAgentLine, usePwCodeAgentSwitcher, } from './agentSwitcher.js';
54
+ export { agentMark, type PwCodeAgentLine, type PwCodeAgentState, type PwCodeAgentSwitcher, type PwCodeStateTone, type PwCodeSwitcherAgent, type PwCodeSwitcherCount, type PwCodeSwitcherRow, switcherAgent, useAgentTypeLabel, useDismissSubagent, usePwCodeAgentLine, usePwCodeAgentSwitcher, } from './agentSwitcher.js';
54
55
  export { IMAGE_MAX_BYTES, IMAGE_MAX_SIDE, IMAGE_READ_MAX_BYTES, IMAGE_TYPES, nextImageSeq, type PwCodeComposerImage, type PwCodeImageFile, PwCodeImageTooLarge, type PwCodeImageType, type PwCodeSavedImage, type PwCodeTakenImages, useComposerImages, withoutAppendedImages, } from './useComposerImages.js';
55
56
  export { type PwCodePresence, recapAfterLeavingMs, recapAfterTurnMs, useAwayRecap, } from './useAwayRecap.js';
56
57
  export { composerState, IMAGE_PLACEHOLDER, machineHint, rememberSentPrompt, sessionLabel, sessionStateText, sessionStatusText, } from './wording.js';
package/dist/index.js CHANGED
@@ -24,7 +24,7 @@ import { paletteOptions, shellCommand, slashAction, steerMayHaveLanded } from ".
24
24
  import { canStartHere, isComputer, isConnected, isMachineDown, isUnreachableError, machinesById, splitMachines, terminalHandoff } from "./machine.js";
25
25
  import { isPwCodeLocale, loadPwCodeMessages, pwCodeLocales, pwCodeNamespaces, usePwCodeTranslations } from "./messages.js";
26
26
  import { usePwCodeChatStrings } from "./chatStrings.js";
27
- import { turnDuration, useCompactionNotice, useGoalNotice, useRecapNotice, useResumeTime, useTranscriptWords } from "./notices.js";
27
+ import { turnDuration, useCompactionNotice, useGoalNotice, useRecapNotice, useResumeClock, useResumeTime, useTranscriptWords } from "./notices.js";
28
28
  import { useCompactAgo } from "./ago.js";
29
29
  import { pastedPullRequestLabel, pullRequestKind, pullRequestLabel, pullRequestShortLabel } from "./pullRequest.js";
30
30
  import { FOLD_DONE_PULL_REQUESTS_FROM, donePullRequestsToFold, foldPullRequests, isPullRequestState, labeledPullRequests, orderPullRequests, pullRequestFoldGroups, pullRequestGroupState, pullRequestStateBreaks, pullRequestStateOf, pullRequestTone, pullRequestWords } from "./pullRequestList.js";
@@ -33,11 +33,12 @@ import { handoffCommandParts, terminalHandoffPanel } from "./terminalHandoffPane
33
33
  import { useUsageLimitWait } from "./usageLimit.js";
34
34
  import { useFollowedWorktree } from "./sessionHeader.js";
35
35
  import { howSessionsAppear } from "./howSessionsAppear.js";
36
- import { isActiveSession, isArchived, isMidTurn, isSession, needsYou, newestFirst, pathBasename, recentDirectories, sessionClock, sessionKey, sessionStatusVariant, sessionVariant, sharedStoreCopy, spansMachines, triageSessions, waitsOnAnswer } from "./session.js";
36
+ import { isActiveSession, isArchived, isMidTurn, isSession, needsYou, newestFirst, pathBasename, recentDirectories, sessionClock, sessionKey, sessionStatusVariant, sessionVariant, sharedStoreCopy, spansMachines, triageSessions, waitsOnAnswer, waitsOnUsageLimit } from "./session.js";
37
37
  import { groupOf, inFlightFirst, isWorking, listGroups, patchGroup, useSessionGroups } from "./sessionGroups.js";
38
38
  import { groupSectionKey, isUngroupedTarget, searchedSessions, sessionMark, sessionRailLabel, sessionRowState, sessionSearchScore, sessionSearchStatus, sessionSearchText, sessionSections, showsPinMark, useRetainedSessions, useSessionList, withArchiveSection } from "./sessionList.js";
39
39
  import { nameToSave, useSessionActions } from "./sessionActions.js";
40
40
  import { appendOwnMessage, appendSteeredMessage, applyStreamEvent, approvalAnswerBody, approvalToPart, bashRunning, dropMessage, historyToMessages, initialTranscript, liveSessionStatus, pendingApprovals, pendingMessages, resolveApprovalEverywhere, resumeCursor, reviewingCount, subagentFrame, subagentSessionDetail, turnRunning } from "./transcript.js";
41
+ import { todoLabel, todoWindow, useTodoPanel } from "./todos.js";
41
42
  import { useToolStrings } from "./toolStrings.js";
42
43
  import { usePwCodeTranscript } from "./useTranscript.js";
43
44
  import { transcriptMessages, usePwCodeConversation } from "./useConversation.js";
@@ -47,8 +48,8 @@ import { claudeAccountChip, claudeOnMachine, goalLabel, newSessionDraftKey, sess
47
48
  import { fitImageWith } from "./imageFit.js";
48
49
  import { loadErrorMessage } from "./loadError.js";
49
50
  import { usePwCodeSubagent } from "./useSubagent.js";
50
- import { agentMark, switcherAgent, useAgentTypeLabel, usePwCodeAgentLine, usePwCodeAgentSwitcher } from "./agentSwitcher.js";
51
+ import { agentMark, switcherAgent, useAgentTypeLabel, useDismissSubagent, usePwCodeAgentLine, usePwCodeAgentSwitcher } from "./agentSwitcher.js";
51
52
  import { IMAGE_MAX_BYTES, IMAGE_MAX_SIDE, IMAGE_READ_MAX_BYTES, IMAGE_TYPES, PwCodeImageTooLarge, nextImageSeq, useComposerImages, withoutAppendedImages } from "./useComposerImages.js";
52
53
  import { recapAfterLeavingMs, recapAfterTurnMs, useAwayRecap } from "./useAwayRecap.js";
53
54
  import { IMAGE_PLACEHOLDER, composerState, machineHint, rememberSentPrompt, sessionLabel, sessionStateText, sessionStatusText } from "./wording.js";
54
- export { BACKGROUND_TOOL, FOLDER_LIMIT, FOLD_DONE_PULL_REQUESTS_FROM, IMAGE_MAX_BYTES, IMAGE_MAX_SIDE, IMAGE_PLACEHOLDER, IMAGE_READ_MAX_BYTES, IMAGE_TYPES, PW_CODE_PREVIEW, PwCodeImageTooLarge, QUERY_KEY_PREFIX, RECENT_LIMIT, SESSIONS_REFRESH_MS, START_SHORTLIST, agentMark, aiAllocations, allocationChoice, allocationProblem, allocationUsage, allocationsForType, allowedAccess, appendOwnMessage, appendSteeredMessage, applyStreamEvent, approvalAnswerBody, approvalToPart, backgroundOfferDelayMs, bashRunning, billsAllocation, browseStart, cachedCopyCurrent, canOpenSignInLink, canRunModel, canStartHere, changesSubagents, chatHandoffPrompt, chatHandoffStart, chatModelPreference, claudeAccountChip, claudeAccountName, claudeLoginFinished, claudeOnMachine, claudeSignInRequired, composerState, createPwCodeApi, cutSpacing, cutToFit, directoryChip, directoryScopes, donePullRequestsToFold, dropMessage, fitImageWith, foldPullRequests, foldedGroupsPreference, githubAttachmentAsset, goalElapsed, goalFacts, goalLabel, groupOf, groupSectionKey, handoffCommandParts, historyToMessages, howSessionsAppear, inFlightFirst, initialTranscript, isActiveSession, isArchived, isClaudeModel, isComputer, isConnected, isMachineDown, isMidTurn, isPathText, isPullRequestState, isPwCodeLocale, isSavedDirectory, isSession, isSessionImageUrl, isUngroupedTarget, isUnlistedDirectory, isUnreachableError, isWorking, joinDirectory, labeledPullRequests, lastModelPreference, lastSegmentAt, listGroups, listedText, liveSessionStatus, loadErrorMessage, loadPwCodeMessages, machineChip, machineHint, machineMenu, machinesById, markdownImageLink, markdownImageSources, matchingFolders, modelGroups, modelLabel, nameToSave, needsYou, newSessionDraftKey, newestFirst, nextImageSeq, offersBackground, orderPullRequests, paletteOptions, parentDirectory, pasteCardText, pasteRefs, pastedPullRequestLabel, patchGroup, patchPullRequestStates, patchSessionNames, pathBasename, pathCompletions, pathNote, pathSections, pathSegments, pendingApprovals, pendingMessages, pickedOnClose, pickerCommand, platformModelStatus, preferenceKey, promptHistory, providerIssueOf, pullRequestFoldGroups, pullRequestGroupState, pullRequestKind, pullRequestLabel, pullRequestShortLabel, pullRequestStateBreaks, pullRequestStateOf, pullRequestTone, pullRequestWords, pullRequestsRefreshMs, pwCodeEnabled, pwCodeLocales, pwCodeNamespaces, reachedByFeed, recapAfterLeavingMs, recapAfterTurnMs, recentDirectories, rememberSentPrompt, resolveApprovalEverywhere, resumeCursor, reviewingCount, runsClaude, searchedSessions, sessionActivity, sessionBanner, sessionClock, sessionContextRow, sessionDirectories, sessionDraftKey, sessionEventsPath, sessionGitHubImageUrl, sessionGroupsPreference, sessionImageUrl, sessionKey, sessionLabel, sessionLinkNotice, sessionMark, sessionModel, sessionRailLabel, sessionRowState, sessionSearchScore, sessionSearchStatus, sessionSearchText, sessionSections, sessionSettingsOptions, sessionStateText, sessionStatusText, sessionStatusVariant, sessionVariant, sharedStoreCopy, shellCommand, shortestPath, shortlistMark, showHiddenPreference, showsPinMark, slashAction, spansMachines, splitMachines, splitTypedPath, startAccountPreference, startCommands, startControls, startEffortPreference, startMachinePreference, startMachines, startModePreference, startSearch, startShortlist, startingMode, steerMayHaveLanded, stopTurn, subagentFrame, subagentSessionDetail, switcherAgent, terminalHandoff, terminalHandoffPanel, transcriptMessages, triageSessions, turnDuration, turnRunning, typedDirectory, useAgentTypeLabel, useAwayRecap, useClaudeAccountName, useClaudeAccountPanel, useClaudeAccountRemoval, useClaudeAccountStartRow, useClaudeAccountUsage, useClaudeSignIn, useCommandOutputs, useCompactAgo, useCompactionNotice, useComposerImages, useComposerPastes, useFollowedWorktree, useGoalElapsed, useGoalNotice, useLastModelPreference, useLastReadAt, useModelAllocations, useModelCatalog, useModelPicker, usePasteCards, usePlatformDefaults, usePwCodeAgentLine, usePwCodeAgentSwitcher, usePwCodeChatStrings, usePwCodeComposer, usePwCodeConversation, usePwCodeSessionScreen, usePwCodeSubagent, usePwCodeTranscript, usePwCodeTranslations, useRecapNotice, useRemoveSessionDirectory, useResumeTime, useRetainedSessions, useSessionActions, useSessionGoal, useSessionGroups, useSessionLink, useSessionList, useSessionPicker, useStaleFor, useStartAccountPreference, useStartDefaultsFromSession, useStartEffortPreference, useStartLocation, useStartMachinePreference, useStartModePreference, useStartModel, useStartPermissionMode, useStartScreen, useStartSession, useToolStrings, useTranscriptWords, useUsageLimitWait, useWorktreeChoice, visibleFolders, waitingQuestions, waitingSince, waitsOnAnswer, withArchiveSection, withoutAppendedImages, workingDirectoryText, worktreeWork };
55
+ export { BACKGROUND_TOOL, FOLDER_LIMIT, FOLD_DONE_PULL_REQUESTS_FROM, IMAGE_MAX_BYTES, IMAGE_MAX_SIDE, IMAGE_PLACEHOLDER, IMAGE_READ_MAX_BYTES, IMAGE_TYPES, PW_CODE_PREVIEW, PwCodeImageTooLarge, QUERY_KEY_PREFIX, RECENT_LIMIT, SESSIONS_REFRESH_MS, START_SHORTLIST, agentMark, aiAllocations, allocationChoice, allocationProblem, allocationUsage, allocationsForType, allowedAccess, appendOwnMessage, appendSteeredMessage, applyStreamEvent, approvalAnswerBody, approvalToPart, backgroundOfferDelayMs, bashRunning, billsAllocation, browseStart, cachedCopyCurrent, canOpenSignInLink, canRunModel, canStartHere, changesSubagents, chatHandoffPrompt, chatHandoffStart, chatModelPreference, claudeAccountChip, claudeAccountName, claudeLoginFinished, claudeOnMachine, claudeSignInRequired, composerState, createPwCodeApi, cutSpacing, cutToFit, directoryChip, directoryScopes, donePullRequestsToFold, dropMessage, fitImageWith, foldPullRequests, foldedGroupsPreference, githubAttachmentAsset, goalElapsed, goalFacts, goalLabel, groupOf, groupSectionKey, handoffCommandParts, historyToMessages, howSessionsAppear, inFlightFirst, initialTranscript, isActiveSession, isArchived, isClaudeModel, isComputer, isConnected, isMachineDown, isMidTurn, isPathText, isPullRequestState, isPwCodeLocale, isSavedDirectory, isSession, isSessionImageUrl, isUngroupedTarget, isUnlistedDirectory, isUnreachableError, isWorking, joinDirectory, labeledPullRequests, lastModelPreference, lastSegmentAt, listGroups, listedText, liveSessionStatus, loadErrorMessage, loadPwCodeMessages, machineChip, machineHint, machineMenu, machinesById, markdownImageLink, markdownImageSources, matchingFolders, modelGroups, modelLabel, nameToSave, needsYou, newSessionDraftKey, newestFirst, nextImageSeq, offersBackground, orderPullRequests, paletteOptions, parentDirectory, pasteCardText, pasteRefs, pastedPullRequestLabel, patchGroup, patchPullRequestStates, patchSessionNames, pathBasename, pathCompletions, pathNote, pathSections, pathSegments, pendingApprovals, pendingMessages, pickedOnClose, pickerCommand, platformModelStatus, preferenceKey, promptHistory, providerIssueOf, pullRequestFoldGroups, pullRequestGroupState, pullRequestKind, pullRequestLabel, pullRequestShortLabel, pullRequestStateBreaks, pullRequestStateOf, pullRequestTone, pullRequestWords, pullRequestsRefreshMs, pwCodeEnabled, pwCodeLocales, pwCodeNamespaces, reachedByFeed, recapAfterLeavingMs, recapAfterTurnMs, recentDirectories, rememberSentPrompt, resolveApprovalEverywhere, resumeCursor, reviewingCount, runsClaude, searchedSessions, sessionActivity, sessionBanner, sessionClock, sessionContextRow, sessionDirectories, sessionDraftKey, sessionEventsPath, sessionGitHubImageUrl, sessionGroupsPreference, sessionImageUrl, sessionKey, sessionLabel, sessionLinkNotice, sessionMark, sessionModel, sessionRailLabel, sessionRowState, sessionSearchScore, sessionSearchStatus, sessionSearchText, sessionSections, sessionSettingsOptions, sessionStateText, sessionStatusText, sessionStatusVariant, sessionVariant, sharedStoreCopy, shellCommand, shortestPath, shortlistMark, showHiddenPreference, showsPinMark, slashAction, spansMachines, splitMachines, splitTypedPath, startAccountPreference, startCommands, startControls, startEffortPreference, startMachinePreference, startMachines, startModePreference, startSearch, startShortlist, startingMode, steerMayHaveLanded, stopTurn, subagentFrame, subagentSessionDetail, switcherAgent, terminalHandoff, terminalHandoffPanel, todoLabel, todoWindow, transcriptMessages, triageSessions, turnDuration, turnRunning, typedDirectory, useAgentTypeLabel, useAwayRecap, useClaudeAccountName, useClaudeAccountPanel, useClaudeAccountRemoval, useClaudeAccountStartRow, useClaudeAccountUsage, useClaudeSignIn, useCommandOutputs, useCompactAgo, useCompactionNotice, useComposerImages, useComposerPastes, useDismissSubagent, useFollowedWorktree, useGoalElapsed, useGoalNotice, useLastModelPreference, useLastReadAt, useModelAllocations, useModelCatalog, useModelPicker, usePasteCards, usePlatformDefaults, usePwCodeAgentLine, usePwCodeAgentSwitcher, usePwCodeChatStrings, usePwCodeComposer, usePwCodeConversation, usePwCodeSessionScreen, usePwCodeSubagent, usePwCodeTranscript, usePwCodeTranslations, useRecapNotice, useRemoveSessionDirectory, useResumeClock, useResumeTime, useRetainedSessions, useSessionActions, useSessionGoal, useSessionGroups, useSessionLink, useSessionList, useSessionPicker, useStaleFor, useStartAccountPreference, useStartDefaultsFromSession, useStartEffortPreference, useStartLocation, useStartMachinePreference, useStartModePreference, useStartModel, useStartPermissionMode, useStartScreen, useStartSession, useTodoPanel, useToolStrings, useTranscriptWords, useUsageLimitWait, useWorktreeChoice, visibleFolders, waitingQuestions, waitingSince, waitsOnAnswer, waitsOnUsageLimit, withArchiveSection, withoutAppendedImages, workingDirectoryText, worktreeWork };
@@ -150,7 +150,8 @@ var activity = {
150
150
  };
151
151
  var input = {
152
152
  "stopGenerating": "Stop generating (Escape)",
153
- "loadingCommands": "Loading commands…"
153
+ "loadingCommands": "Loading commands…",
154
+ "emoji": "Emoji"
154
155
  };
155
156
  var thread = { "jumpToPrompt": "Go to message: {text}" };
156
157
  var find = {