@hyperdrive.bot/fleet-server 0.3.114 → 0.3.116
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.
- package/dist/server/server/agent/agent-prompt.d.ts +36 -0
- package/dist/server/server/agent/agent-prompt.js +45 -5
- package/dist/server/server/agent/providers/claude/transport/pty-query.d.ts +4 -0
- package/dist/server/server/agent/providers/claude/transport/pty-query.js +42 -0
- package/dist/server/server/bootstrap.js +23 -0
- package/dist/server/web-ui/_expo/static/js/web/{index-116ea33a52fc936b8729e19af8e94412.js → index-4d3aa1f9c74ac3a193b8006f00541563.js} +8 -8
- package/dist/server/web-ui/_expo/static/js/web/index-4d3aa1f9c74ac3a193b8006f00541563.js.br +0 -0
- package/dist/server/web-ui/_expo/static/js/web/{index-116ea33a52fc936b8729e19af8e94412.js.gz → index-4d3aa1f9c74ac3a193b8006f00541563.js.gz} +0 -0
- package/dist/server/web-ui/_expo/static/js/web/{index-116ea33a52fc936b8729e19af8e94412.js.map.br → index-4d3aa1f9c74ac3a193b8006f00541563.js.map.br} +0 -0
- package/dist/server/web-ui/_expo/static/js/web/{index-116ea33a52fc936b8729e19af8e94412.js.map.gz → index-4d3aa1f9c74ac3a193b8006f00541563.js.map.gz} +0 -0
- package/dist/server/web-ui/index.html +1 -1
- package/dist/server/web-ui/index.html.br +0 -0
- package/dist/server/web-ui/index.html.gz +0 -0
- package/package.json +6 -6
- package/dist/server/web-ui/_expo/static/js/web/index-116ea33a52fc936b8729e19af8e94412.js.br +0 -0
|
@@ -39,6 +39,12 @@ export interface SendPromptToAgentParams {
|
|
|
39
39
|
* schedule fires, notify-on-finish).
|
|
40
40
|
*/
|
|
41
41
|
unarchive?: boolean;
|
|
42
|
+
/**
|
|
43
|
+
* Default true. When the agent is loaded but its runtime has no live session, recycle it
|
|
44
|
+
* (kill the CLI, resume the SAME provider session) before dispatching, instead of
|
|
45
|
+
* dispatching into a route that does not exist. See recycleDetachedRuntime().
|
|
46
|
+
*/
|
|
47
|
+
recycleDetached?: boolean;
|
|
42
48
|
logger: Logger;
|
|
43
49
|
}
|
|
44
50
|
export interface StartCreatedAgentInitialPromptParams {
|
|
@@ -50,8 +56,38 @@ export interface StartCreatedAgentInitialPromptParams {
|
|
|
50
56
|
logger: Logger;
|
|
51
57
|
}
|
|
52
58
|
export declare function waitForAgentRunStartWithTimeout(agentManager: AgentManager, agentId: string): Promise<void>;
|
|
59
|
+
/**
|
|
60
|
+
* Re-establish a live provider session for an agent that is loaded but detached.
|
|
61
|
+
*
|
|
62
|
+
* `ensureAgentLoaded` returns early on `agentManager.getAgent(id)`, which answers "is this
|
|
63
|
+
* agent in MEMORY", not "does it have a live session". The two diverge whenever the runtime
|
|
64
|
+
* dies under a loaded agent: the stall backstop firing, the CLI exiting, a daemon restart
|
|
65
|
+
* that leaves the record hydrated. `runtimeInfo.sessionId` goes null while
|
|
66
|
+
* `persistence.sessionId` still names a perfectly resumable session on disk.
|
|
67
|
+
*
|
|
68
|
+
* In that state every send was accepted and dropped. The prompt reached a session object
|
|
69
|
+
* with nowhere to write, no error surfaced, and the client had already rendered the message
|
|
70
|
+
* as sent. Observed 2026-09-08 on agent `55166b53` (session `84c4c3ff`): four prompts drawn
|
|
71
|
+
* in the UI, ZERO bytes in the PTY recording, while the terminal was alive and working.
|
|
72
|
+
*
|
|
73
|
+
* `reloadAgentSession` already does the right thing - cancel any in-flight run, resume the
|
|
74
|
+
* persisted handle, close the old session, keep timeline/labels/digest - it was simply never
|
|
75
|
+
* reached, because the only caller was an explicit user-triggered reload.
|
|
76
|
+
*
|
|
77
|
+
* Returns what actually happened to the route, so the caller can say so rather than pretend
|
|
78
|
+
* the message went to the session the user was last looking at. `"no-route"` is the honest
|
|
79
|
+
* name for the one case still not recoverable here: detached AND nothing to resume from.
|
|
80
|
+
*/
|
|
81
|
+
export type RuntimeRouteOutcome = "live" | "recycled" | "no-route";
|
|
82
|
+
export declare function recycleDetachedRuntime(params: {
|
|
83
|
+
agentManager: AgentManager;
|
|
84
|
+
agentId: string;
|
|
85
|
+
agent: ManagedAgent;
|
|
86
|
+
logger: Logger;
|
|
87
|
+
}): Promise<RuntimeRouteOutcome>;
|
|
53
88
|
export declare function sendPromptToAgent(params: SendPromptToAgentParams): Promise<{
|
|
54
89
|
outOfBand: boolean;
|
|
90
|
+
route?: RuntimeRouteOutcome;
|
|
55
91
|
}>;
|
|
56
92
|
export declare function startCreatedAgentInitialPrompt(params: StartCreatedAgentInitialPromptParams): Promise<ManagedAgent>;
|
|
57
93
|
export interface SetupFinishNotificationParams {
|
|
@@ -120,6 +120,29 @@ function extractSlashCommandName(prompt) {
|
|
|
120
120
|
return null;
|
|
121
121
|
return trimmed.split(/\s/, 1)[0] ?? null;
|
|
122
122
|
}
|
|
123
|
+
export async function recycleDetachedRuntime(params) {
|
|
124
|
+
const { agentManager, agentId, agent, logger } = params;
|
|
125
|
+
// A live route is the only thing that makes a send meaningful. Absence of a session id is
|
|
126
|
+
// the fact itself here, not a proxy for it: it is the field the dispatch path writes to.
|
|
127
|
+
if (agent.runtimeInfo?.sessionId)
|
|
128
|
+
return "live";
|
|
129
|
+
// Nothing to resume FROM. Leave it alone rather than silently starting a fresh session and
|
|
130
|
+
// stranding the user's history: a new session would look identical and answer differently.
|
|
131
|
+
if (!agent.persistence) {
|
|
132
|
+
logger.warn({ agentId, provider: agent.provider }, "Agent has no live session and no persistence handle; the prompt has nowhere to go");
|
|
133
|
+
return "no-route";
|
|
134
|
+
}
|
|
135
|
+
logger.warn({
|
|
136
|
+
agentId,
|
|
137
|
+
provider: agent.provider,
|
|
138
|
+
resumedSessionId: agent.persistence.sessionId,
|
|
139
|
+
event: "agent.runtime.recycled",
|
|
140
|
+
}, "Agent loaded without a live session; recycling before dispatch");
|
|
141
|
+
// rehydrateFromDisk stays false on purpose: the timeline the user is looking at is correct,
|
|
142
|
+
// only the transport underneath it died. Wiping it would blank the screen mid-conversation.
|
|
143
|
+
await agentManager.reloadAgentSession(agentId, undefined, { rehydrateFromDisk: false });
|
|
144
|
+
return "recycled";
|
|
145
|
+
}
|
|
123
146
|
export async function sendPromptToAgent(params) {
|
|
124
147
|
const unarchive = params.unarchive ?? true;
|
|
125
148
|
// Trace WHICH caller dispatches a slash command, and nothing else.
|
|
@@ -146,21 +169,38 @@ export async function sendPromptToAgent(params) {
|
|
|
146
169
|
}
|
|
147
170
|
await unarchiveAgentState(params.agentStorage, params.agentManager, params.agentId);
|
|
148
171
|
}
|
|
149
|
-
await ensureAgentLoaded(params.agentId, {
|
|
172
|
+
const loaded = await ensureAgentLoaded(params.agentId, {
|
|
150
173
|
agentManager: params.agentManager,
|
|
151
174
|
agentStorage: params.agentStorage,
|
|
152
175
|
logger: params.logger,
|
|
153
176
|
});
|
|
177
|
+
// Loaded is not the same as alive. Without this the prompt below is written to a session
|
|
178
|
+
// with no transport and disappears without an error. See recycleDetachedRuntime().
|
|
179
|
+
let route = "live";
|
|
180
|
+
if (params.recycleDetached ?? true) {
|
|
181
|
+
route = await recycleDetachedRuntime({
|
|
182
|
+
agentManager: params.agentManager,
|
|
183
|
+
agentId: params.agentId,
|
|
184
|
+
agent: loaded,
|
|
185
|
+
logger: params.logger,
|
|
186
|
+
});
|
|
187
|
+
}
|
|
154
188
|
if (params.sessionMode) {
|
|
155
189
|
await params.agentManager.setAgentMode(params.agentId, params.sessionMode);
|
|
156
190
|
}
|
|
157
191
|
const runOptions = params.messageId
|
|
158
192
|
? { ...params.runOptions, messageId: params.messageId }
|
|
159
193
|
: params.runOptions;
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
194
|
+
// `route` rides out with the result so a caller is never told a prompt was accepted when
|
|
195
|
+
// it had no session to reach. The UI renders the message optimistically the moment it is
|
|
196
|
+
// typed; without this the only record of the drop was a log line nobody was reading.
|
|
197
|
+
return {
|
|
198
|
+
...startAgentRun(params.agentManager, params.agentId, params.prompt, params.logger, {
|
|
199
|
+
replaceRunning: true,
|
|
200
|
+
runOptions,
|
|
201
|
+
}),
|
|
202
|
+
route,
|
|
203
|
+
};
|
|
164
204
|
}
|
|
165
205
|
export async function startCreatedAgentInitialPrompt(params) {
|
|
166
206
|
const currentSnapshot = params.agentManager.getAgent(params.agentId) ?? params.snapshot ?? null;
|
|
@@ -101,6 +101,10 @@ export declare class PtyQuery implements AsyncGenerator<SDKMessage, void> {
|
|
|
101
101
|
private readonly stallTimeoutMs;
|
|
102
102
|
private stallTimer;
|
|
103
103
|
private turnInFlight;
|
|
104
|
+
/** `ptyBytesTotal` when the current stall budget was armed. See MAX_STALL_EXTENSIONS. */
|
|
105
|
+
private ptyBytesAtStallArm;
|
|
106
|
+
/** Extensions granted to the CURRENT turn; reset when a turn starts. */
|
|
107
|
+
private stallExtensions;
|
|
104
108
|
private terminalTail;
|
|
105
109
|
private offTerminalTap;
|
|
106
110
|
private readonly startedAt;
|
|
@@ -166,6 +166,18 @@ const TERMINAL_STOP_REASONS = new Set(["end_turn", "stop_sequence", "max_tokens"
|
|
|
166
166
|
* with `stallTimeoutMs`; `0` disables the backstop entirely.
|
|
167
167
|
*/
|
|
168
168
|
const TURN_STALL_TIMEOUT_MS = 10 * 60000;
|
|
169
|
+
/**
|
|
170
|
+
* How many times a stall budget may be extended because terminal bytes were still flowing.
|
|
171
|
+
*
|
|
172
|
+
* The backstop is armed off TRANSCRIPT silence, but a turn that spends the whole budget
|
|
173
|
+
* inside ONE long tool call writes nothing to `<sid>.jsonl` while the TUI is visibly alive.
|
|
174
|
+
* Observed 2026-08-22 (agent `ad553094`): the turn was declared failed while the terminal
|
|
175
|
+
* was mid tool call, and the error text even quoted the live tail that contradicted it.
|
|
176
|
+
*
|
|
177
|
+
* Bounded rather than unlimited because a wedged-but-spinning TUI also emits bytes forever;
|
|
178
|
+
* 3 extensions caps the worst case at 4x the budget instead of never terminating.
|
|
179
|
+
*/
|
|
180
|
+
const MAX_STALL_EXTENSIONS = 3;
|
|
169
181
|
/**
|
|
170
182
|
* How much terminal text to keep for diagnosis. The TUI is the only place that says what
|
|
171
183
|
* claude is actually doing while it is quiet ("Compacting conversation…", a retry notice,
|
|
@@ -295,6 +307,10 @@ export class PtyQuery {
|
|
|
295
307
|
this.numTurns = 0;
|
|
296
308
|
this.stallTimer = null;
|
|
297
309
|
this.turnInFlight = false;
|
|
310
|
+
/** `ptyBytesTotal` when the current stall budget was armed. See MAX_STALL_EXTENSIONS. */
|
|
311
|
+
this.ptyBytesAtStallArm = 0;
|
|
312
|
+
/** Extensions granted to the CURRENT turn; reset when a turn starts. */
|
|
313
|
+
this.stallExtensions = 0;
|
|
298
314
|
// terminal tail (see TERMINAL_TAIL_MAX_CHARS)
|
|
299
315
|
this.terminalTail = "";
|
|
300
316
|
this.offTerminalTap = null;
|
|
@@ -619,6 +635,7 @@ export class PtyQuery {
|
|
|
619
635
|
// confirmed claude accepted it (a real user line landed), so from here on silence
|
|
620
636
|
// means a stall, not a slow start.
|
|
621
637
|
this.turnInFlight = true;
|
|
638
|
+
this.stallExtensions = 0;
|
|
622
639
|
this.armStallTimer();
|
|
623
640
|
this.startHeartbeat();
|
|
624
641
|
}
|
|
@@ -780,6 +797,7 @@ export class PtyQuery {
|
|
|
780
797
|
}
|
|
781
798
|
this.turnStartedAt = monotonicNowMs();
|
|
782
799
|
this.turnInFlight = true;
|
|
800
|
+
this.stallExtensions = 0;
|
|
783
801
|
this.armStallTimer();
|
|
784
802
|
this.startHeartbeat();
|
|
785
803
|
return true;
|
|
@@ -851,6 +869,7 @@ export class PtyQuery {
|
|
|
851
869
|
}
|
|
852
870
|
this.turnStartedAt = monotonicNowMs();
|
|
853
871
|
this.turnInFlight = true;
|
|
872
|
+
this.stallExtensions = 0;
|
|
854
873
|
this.armStallTimer();
|
|
855
874
|
this.startHeartbeat();
|
|
856
875
|
return true;
|
|
@@ -922,6 +941,7 @@ export class PtyQuery {
|
|
|
922
941
|
// Answer accepted: the turn is live again, restart the liveness clock.
|
|
923
942
|
this.turnStartedAt = monotonicNowMs();
|
|
924
943
|
this.turnInFlight = true;
|
|
944
|
+
this.stallExtensions = 0;
|
|
925
945
|
this.armStallTimer();
|
|
926
946
|
this.startHeartbeat();
|
|
927
947
|
return true;
|
|
@@ -1506,6 +1526,9 @@ export class PtyQuery {
|
|
|
1506
1526
|
if (this.stallTimeoutMs <= 0 || !this.turnInFlight)
|
|
1507
1527
|
return;
|
|
1508
1528
|
this.clearStallTimer();
|
|
1529
|
+
// Watermark for the terminal-liveness check in onTurnStalled(). Recorded on every
|
|
1530
|
+
// (re)arm so the comparison is always against THIS budget, not the whole turn.
|
|
1531
|
+
this.ptyBytesAtStallArm = this.ptyBytesTotal;
|
|
1509
1532
|
this.stallTimer = setTimeout(() => this.onTurnStalled(), this.stallTimeoutMs);
|
|
1510
1533
|
// Never hold the event loop open just to wait for a stall.
|
|
1511
1534
|
this.stallTimer.unref?.();
|
|
@@ -1533,6 +1556,25 @@ export class PtyQuery {
|
|
|
1533
1556
|
this.armStallTimer();
|
|
1534
1557
|
return;
|
|
1535
1558
|
}
|
|
1559
|
+
// A turn with terminal bytes flowing is not stalled, whatever the transcript is doing.
|
|
1560
|
+
// `beat()` has always computed this number for the heartbeat log; nothing consulted it
|
|
1561
|
+
// when deciding to fail the turn, so a long single tool call read as a dead session.
|
|
1562
|
+
const ptyBytesThisBudget = this.ptyBytesTotal - this.ptyBytesAtStallArm;
|
|
1563
|
+
if (ptyBytesThisBudget > 0 && this.stallExtensions < MAX_STALL_EXTENSIONS) {
|
|
1564
|
+
this.stallExtensions += 1;
|
|
1565
|
+
this.recordLine(`--- stall budget elapsed but ${ptyBytesThisBudget}B of terminal output arrived; ` +
|
|
1566
|
+
`extending (${this.stallExtensions}/${MAX_STALL_EXTENSIONS}) ---`);
|
|
1567
|
+
this.logger.warn({
|
|
1568
|
+
sessionId: this.sessionId,
|
|
1569
|
+
event: "pty.turn.stall-extended",
|
|
1570
|
+
ptyBytesThisBudget,
|
|
1571
|
+
extension: this.stallExtensions,
|
|
1572
|
+
maxExtensions: MAX_STALL_EXTENSIONS,
|
|
1573
|
+
lastLine: this.lastMeaningfulLine.slice(-160),
|
|
1574
|
+
}, "PtyQuery: transcript silent but terminal alive; extending the stall budget");
|
|
1575
|
+
this.armStallTimer();
|
|
1576
|
+
return;
|
|
1577
|
+
}
|
|
1536
1578
|
this.turnInFlight = false;
|
|
1537
1579
|
this.stopHeartbeat();
|
|
1538
1580
|
const silentForMs = this.stallTimeoutMs;
|
|
@@ -1227,12 +1227,35 @@ export async function createPaseoDaemon(config, rootLogger) {
|
|
|
1227
1227
|
});
|
|
1228
1228
|
Object.assign(transport, {
|
|
1229
1229
|
onerror: (err) => {
|
|
1230
|
+
// Version negotiation is not a transport failure.
|
|
1231
|
+
//
|
|
1232
|
+
// A client that offers a protocol version newer than this server's SDK gets a 400
|
|
1233
|
+
// and RETRIES with a supported one, per the MCP spec. That is the handshake working,
|
|
1234
|
+
// not breaking. A current CLI client opens with `2026-07-28`, which no published
|
|
1235
|
+
// `@modelcontextprotocol/sdk` accepts (checked 1.20.1 through 1.30.0, all top out at
|
|
1236
|
+
// `2025-11-25`), so every agent produced one of these on connect and the tools kept
|
|
1237
|
+
// working right through it - verified 2026-09-08: `set_session_digest` landed at
|
|
1238
|
+
// 21:45:41, between two of these "errors".
|
|
1239
|
+
//
|
|
1240
|
+
// Logged at error level it was pure noise, roughly one per agent connect, and noise
|
|
1241
|
+
// at error level is how a real transport failure goes unnoticed. Downgraded to debug
|
|
1242
|
+
// and left non-fatal; every other transport error keeps its error level.
|
|
1243
|
+
if (isProtocolVersionNegotiation(err)) {
|
|
1244
|
+
logger.debug({ err: err.message }, "Agent MCP client offered an unsupported protocol version; it will retry");
|
|
1245
|
+
return;
|
|
1246
|
+
}
|
|
1230
1247
|
logger.error({ err }, "Agent MCP transport error");
|
|
1231
1248
|
},
|
|
1232
1249
|
});
|
|
1233
1250
|
await agentMcpServer.connect(transport);
|
|
1234
1251
|
return { server: agentMcpServer, transport };
|
|
1235
1252
|
};
|
|
1253
|
+
/**
|
|
1254
|
+
* True for the 400 a client gets when it offers a protocol version this server's SDK
|
|
1255
|
+
* does not know. Matched on the SDK's own wording because it throws a plain Error with
|
|
1256
|
+
* no code or status field to key on.
|
|
1257
|
+
*/
|
|
1258
|
+
const isProtocolVersionNegotiation = (err) => /unsupported protocol version/i.test(err?.message ?? "");
|
|
1236
1259
|
const runAgentMcpRequest = async (req, res) => {
|
|
1237
1260
|
// This route is exempt from the global daemon-password middleware, so it
|
|
1238
1261
|
// authenticates here using the injected capability token (or a valid
|
|
@@ -849,7 +849,7 @@ __d(function(g,r,i,a,m,e,d){"use strict";Object.defineProperty(e,"__esModule",{v
|
|
|
849
849
|
__d(function(g,r,i,a,m,e,d){"use strict";var t=this&&this.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(e,"__esModule",{value:!0}),e.shouldAppendSitemap=u,e.shouldAppendNotFound=s,e.getRootStackRouteNames=function(){const t=[n.INTERNAL_SLOT_NAME];s()&&t.push(n.NOT_FOUND_ROUTE_NAME);u()&&t.push(n.SITEMAP_ROUTE_NAME);return t};const o=t(r(d[0])),n=r(d[1]);function u(){const t=o.default.expoConfig?.extra?.router;return!1!==t?.sitemap}function s(){const t=o.default.expoConfig?.extra?.router;return!1!==t?.notFound}},717,[718,721]);
|
|
850
850
|
__d(function(g,r,i,a,m,_e,d){"use strict";function e(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(_e,'__esModule',{value:!0}),Object.defineProperty(_e,"default",{enumerable:!0,get:function(){return N}}),Object.defineProperty(_e,"AppOwnership",{enumerable:!0,get:function(){return l.AppOwnership}}),Object.defineProperty(_e,"ExecutionEnvironment",{enumerable:!0,get:function(){return l.ExecutionEnvironment}}),Object.defineProperty(_e,"UserInterfaceIdiom",{enumerable:!0,get:function(){return l.UserInterfaceIdiom}});var n=e(r(d[0])),t=r(d[1]);r(d[2]);var u=e(r(d[3])),l=r(d[4]),o=e(r(d[5]));o.default||console.warn("No native ExponentConstants module found, are you sure the expo-constants's module is linked properly?");const s=(0,t.requireOptionalNativeModule)('ExpoUpdates');let f=null;if(s){let e;s.manifest?e=s.manifest:s.manifestString&&(e=JSON.parse(s.manifestString)),e&&Object.keys(e).length>0&&(f=e)}let c=null;if(u.default.EXDevLauncher){let e;u.default.EXDevLauncher.manifestString&&(e=JSON.parse(u.default.EXDevLauncher.manifestString)),e&&Object.keys(e).length>0&&(c=e)}let p=null;if(o.default&&o.default.manifest){const e=o.default.manifest;p='string'==typeof e?JSON.parse(e):e}let b=f??c??p;const E=o.default||{},{appOwnership:O}=E,x=(0,n.default)(E,["name","appOwnership"]),v=Object.assign({},x,{appOwnership:O??null});function _(e){return!h(e)}function h(e){return'metadata'in e}function S(e=!1){if(!b){const e=null===b?'null':'undefined';if(x.executionEnvironment,l.ExecutionEnvironment.Bare,x.executionEnvironment===l.ExecutionEnvironment.StoreClient||x.executionEnvironment===l.ExecutionEnvironment.Standalone)throw new t.CodedError('ERR_CONSTANTS_MANIFEST_UNAVAILABLE',`Constants.manifest is ${e}, must be an object.`)}return b}Object.defineProperties(v,{__unsafeNoWarnManifest:{get(){const e=S(!0);return e&&_(e)?e:null},enumerable:!1},__unsafeNoWarnManifest2:{get(){const e=S(!0);return e&&h(e)?e:null},enumerable:!1},manifest:{get(){const e=S();return e&&_(e)?e:null},enumerable:!0},manifest2:{get(){const e=S();return e&&h(e)?e:null},enumerable:!0},expoConfig:{get(){const e=S(!0);return e?s&&s.isEmbeddedLaunch?p:h(e)?e.extra?.expoClient??null:_(e)?e:null:null},enumerable:!0},expoGoConfig:{get(){const e=S(!0);return e?h(e)?e.extra?.expoGo??null:_(e)?e:null:null},enumerable:!0},easConfig:{get(){const e=S(!0);return e?h(e)?e.extra?.eas??null:_(e)?e:null:null},enumerable:!0},__rawManifest_TEST:{get:()=>b,set(e){b=e},enumerable:!1}});var N=v},718,[35,4,25,637,719,720]);
|
|
851
851
|
__d(function(g,r,i,a,m,e,d){"use strict";var t,n,o;Object.defineProperty(e,'__esModule',{value:!0}),Object.defineProperty(e,"AppOwnership",{enumerable:!0,get:function(){return t}}),Object.defineProperty(e,"ExecutionEnvironment",{enumerable:!0,get:function(){return n}}),Object.defineProperty(e,"UserInterfaceIdiom",{enumerable:!0,get:function(){return o}}),(function(t){t.Expo="expo"})(t||(t={})),(function(t){t.Bare="bare",t.Standalone="standalone",t.StoreClient="storeClient"})(n||(n={})),(function(t){t.Handset="handset",t.Tablet="tablet",t.Desktop="desktop",t.TV="tv",t.Unsupported="unsupported"})(o||(o={}))},719,[]);
|
|
852
|
-
__d(function(g,r,i,a,m,e,d){"use strict";Object.defineProperty(e,'__esModule',{value:!0}),Object.defineProperty(e,"default",{enumerable:!0,get:function(){return s}});var t=r(d[0]);const n=(Date.now()+'-'+Math.floor(1e9*Math.random())).toString();function o(){if('undefined'!=typeof navigator&&'string'==typeof navigator.userAgent){const t=navigator.userAgent.toLowerCase();if(t.includes('edge'))return'Edge';if(t.includes('edg'))return'Chromium Edge';if(t.includes('opr')&&'opr'in window&&window.opr)return'Opera';if(t.includes('chrome')&&'chrome'in window&&window.chrome)return'Chrome';if(t.includes('trident'))return'IE';if(t.includes('firefox'))return'Firefox';if(t.includes('safari'))return'Safari'}}var s={get appOwnership(){return null},get executionEnvironment(){return t.ExecutionEnvironment.Bare},get sessionId(){return n},get isHeadless(){return'undefined'==typeof navigator||/\bHeadlessChrome\//.test(navigator.userAgent)},get expoVersion(){return this.manifest.sdkVersion||null},get linkingUri(){return'undefined'!=typeof location?location.origin:''},get expoRuntimeVersion(){return this.expoVersion},get deviceName(){return o()},get systemFonts(){return[]},get statusBarHeight(){return 0},get deviceYearClass(){return null},get manifest(){return"{\"name\":\"Paseo\",\"slug\":\"paseo-hyperdrive\",\"version\":\"0.3.
|
|
852
|
+
__d(function(g,r,i,a,m,e,d){"use strict";Object.defineProperty(e,'__esModule',{value:!0}),Object.defineProperty(e,"default",{enumerable:!0,get:function(){return s}});var t=r(d[0]);const n=(Date.now()+'-'+Math.floor(1e9*Math.random())).toString();function o(){if('undefined'!=typeof navigator&&'string'==typeof navigator.userAgent){const t=navigator.userAgent.toLowerCase();if(t.includes('edge'))return'Edge';if(t.includes('edg'))return'Chromium Edge';if(t.includes('opr')&&'opr'in window&&window.opr)return'Opera';if(t.includes('chrome')&&'chrome'in window&&window.chrome)return'Chrome';if(t.includes('trident'))return'IE';if(t.includes('firefox'))return'Firefox';if(t.includes('safari'))return'Safari'}}var s={get appOwnership(){return null},get executionEnvironment(){return t.ExecutionEnvironment.Bare},get sessionId(){return n},get isHeadless(){return'undefined'==typeof navigator||/\bHeadlessChrome\//.test(navigator.userAgent)},get expoVersion(){return this.manifest.sdkVersion||null},get linkingUri(){return'undefined'!=typeof location?location.origin:''},get expoRuntimeVersion(){return this.expoVersion},get deviceName(){return o()},get systemFonts(){return[]},get statusBarHeight(){return 0},get deviceYearClass(){return null},get manifest(){return"{\"name\":\"Paseo\",\"slug\":\"paseo-hyperdrive\",\"version\":\"0.3.116\",\"orientation\":\"portrait\",\"icon\":\"./assets/images/icon.png\",\"scheme\":\"paseo\",\"userInterfaceStyle\":\"automatic\",\"newArchEnabled\":true,\"web\":{\"output\":\"single\",\"favicon\":\"./assets/images/favicon.png\",\"shortName\":\"Paseo\",\"orientation\":\"portrait\",\"name\":\"Paseo\"},\"autolinking\":{\"searchPaths\":[\"../../node_modules\",\"./node_modules\"]},\"experiments\":{\"typedRoutes\":true,\"reactCompiler\":true,\"autolinkingModuleResolution\":true},\"extra\":{\"router\":{},\"eas\":{\"build\":{\"experimental\":{\"ios\":{\"appExtensions\":[{\"bundleIdentifier\":\"bot.hyperdrive.paseo.AgentActivity\",\"targetName\":\"AgentActivity\"}]}}}}},\"sdkVersion\":\"54.0.0\",\"platforms\":[\"ios\",\"android\",\"web\"]}"},get manifest2(){return null},get experienceUrl(){return'undefined'!=typeof location?location.origin:''},get debugMode(){return!1},getWebViewUserAgentAsync:async()=>'undefined'!=typeof navigator?navigator.userAgent:null}},720,[719]);
|
|
853
853
|
__d(function(g,r,i,a,m,e,d){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.SITEMAP_ROUTE_NAME=e.NOT_FOUND_ROUTE_NAME=e.INTERNAL_SLOT_NAME=void 0,e.INTERNAL_SLOT_NAME='__root',e.NOT_FOUND_ROUTE_NAME='+not-found',e.SITEMAP_ROUTE_NAME='_sitemap'},721,[]);
|
|
854
854
|
__d(function(g,r,i,a,m,e,d){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.resolveHref=void 0,e.resolveHrefStringWithSegments=function(t,{segments:n=[],params:s={}}={},{relativeToDirectory:o}={}){if(t.startsWith('.')){let c=n?.map(t=>{if(!t.startsWith('['))return t;if(t.startsWith('[...')){t=t.slice(4,-1);const n=s[t];return Array.isArray(n)?n.join('/'):n?.split(',')?.join('/')??''}return t=t.slice(1,-1),s[t]}).filter(Boolean).join('/')??'/';o&&(c=`${c}/`);const f=new URL(t,`http://hostname/${c}`);t=`${f.pathname}${f.search}`}return t};function t(t,s){for(const[o,c=""]of Object.entries(s)){const f=`[${o}]`,l=`[...${o}]`;if(t.includes(f))t=t.replace(f,n(c));else{if(!t.includes(l))continue;t=t.replace(l,n(c))}delete s[o]}return{pathname:t,params:s}}function n(t){return Array.isArray(t)?t.map(t=>n(t)).join('/'):encodeURIComponent(t.toString())}function s(t){return Object.entries(t).filter(([,t])=>null!=t).map(([t,n])=>`${t}=${encodeURIComponent(n.toString())}`).join('&')}e.resolveHref=n=>{if('string'==typeof n)return(0,e.resolveHref)({pathname:n});const o=n.pathname??'';if(!n?.params)return o;const{pathname:c,params:f}=t(o,Object.assign({},n.params)),l=s(f);return c+(l?`?${l}`:'')}},722,[]);
|
|
855
855
|
__d(function(g,r,i,a,m,e,d){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.isRoutePreloadedInStack=function(t,o){if(!t||'stack'!==t.type)return!1;return t.preloadedRoutes.some(t=>t.key===o.key)}},723,[]);
|
|
@@ -15057,7 +15057,7 @@ __d(function(g,r,i,a,m,e,d){"use strict";Object.defineProperty(e,'__esModule',{v
|
|
|
15057
15057
|
__d(function(g,r,i,a,m,e,d){"use strict";Object.defineProperty(e,'__esModule',{value:!0}),Object.defineProperty(e,"decodeOfferFragmentPayload",{enumerable:!0,get:function(){return n.decodeOfferFragmentPayload}}),Object.defineProperty(e,"buildDaemonWebSocketUrl",{enumerable:!0,get:function(){return t.buildDaemonWebSocketUrl}}),Object.defineProperty(e,"deriveLabelFromEndpoint",{enumerable:!0,get:function(){return t.deriveLabelFromEndpoint}}),Object.defineProperty(e,"extractHostPortFromWebSocketUrl",{enumerable:!0,get:function(){return t.extractHostPortFromWebSocketUrl}}),Object.defineProperty(e,"normalizeHostPort",{enumerable:!0,get:function(){return t.normalizeHostPort}}),Object.defineProperty(e,"parseConnectionUri",{enumerable:!0,get:function(){return t.parseConnectionUri}}),Object.defineProperty(e,"parseHostPort",{enumerable:!0,get:function(){return t.parseHostPort}}),Object.defineProperty(e,"serializeConnectionUri",{enumerable:!0,get:function(){return t.serializeConnectionUri}}),Object.defineProperty(e,"serializeConnectionUriForStorage",{enumerable:!0,get:function(){return t.serializeConnectionUriForStorage}}),Object.defineProperty(e,"shouldUseTlsForDefaultHostedRelay",{enumerable:!0,get:function(){return t.shouldUseTlsForDefaultHostedRelay}}),e.buildRelayWebSocketUrl=function(n){return(0,t.buildRelayWebSocketUrl)(Object.assign({},n,{role:"client"}))};var t=r(d[0]),n=r(d[1])},3412,[3392,3413]);
|
|
15058
15058
|
__d(function(g,r,i,a,m,e,d){"use strict";Object.defineProperty(e,'__esModule',{value:!0}),Object.defineProperty(e,"ConnectionOfferV2Schema",{enumerable:!0,get:function(){return t}}),Object.defineProperty(e,"ConnectionOfferSchema",{enumerable:!0,get:function(){return o}}),e.decodeOfferFragmentPayload=l,e.parseConnectionOfferFromUrl=function(n){const t=f(n);if(!t)return null;const c=l(t);return o.parse(c)};var n=r(d[0]);const t=n.z.object({v:n.z.literal(2),serverId:n.z.string().min(1),daemonPublicKeyB64:n.z.string().min(1),relay:n.z.object({endpoint:n.z.string().min(1),useTls:n.z.boolean().optional()})}),o=t;function c(n){const t=n.replace(/-/g,"+").replace(/_/g,"/"),o=t.padEnd(t.length+(4-t.length%4)%4,"="),c=globalThis.atob(o),l=Uint8Array.from(c,n=>n.charCodeAt(0));return new TextDecoder("utf-8",{fatal:!0}).decode(l)}function l(n){const t=c(n);return JSON.parse(t)}const u="#offer=";function f(n){const t=n.trim();if(!t)return null;const o=t.indexOf(u);if(-1===o)return null;const c=t.slice(o+u.length).trim();return c.length>0?c:null}},3413,[3285]);
|
|
15059
15059
|
__d(function(g,r,i,a,m,_e,d){"use strict";function e(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(_e,'__esModule',{value:!0}),_e.resolveAppVersion=function(){const e=u(t.default?.version);if(e)return e;const o=u(n.default.expoConfig?.version);if(o)return o;const f=u(n.default.manifest?.version);if(f)return f;return null};var n=e(r(d[0])),t=e(r(d[1]));function u(e){if("string"!=typeof e)return null;const n=e.trim();return 0===n.length?null:n}},3414,[718,3415]);
|
|
15060
|
-
__d(function(e,t,r,a,i,o,n){i.exports={name:"@hyperdrive.bot/fleet-app",version:"0.3.
|
|
15060
|
+
__d(function(e,t,r,a,i,o,n){i.exports={name:"@hyperdrive.bot/fleet-app",version:"0.3.116",private:!0,main:"index.ts",scripts:{start:"npm run start:expo","start:expo":"cross-env APP_VARIANT=development expo start","reset-project":"node ./scripts/reset-project.js","build:terminal-webview":"node ./scripts/build-terminal-webview-html.mjs","eas-build-post-install":"npm --prefix ../.. run build:app-deps && npm run build:terminal-webview",android:"npm run android:development","android:development":"npm --prefix ../.. run build:client && cross-env APP_VARIANT=development expo prebuild --platform android --non-interactive && cross-env APP_VARIANT=development expo run:android --variant=debug","android:production":"npm --prefix ../.. run build:client && cross-env APP_VARIANT=production expo prebuild --platform android --non-interactive && cross-env APP_VARIANT=production expo run:android --variant=release","android:release":"npm run android:production","android:clear":"node -e \"require('node:fs').rmSync('android', { recursive: true, force: true })\"",ios:"npm --prefix ../.. run build:client && expo run:ios","ios:release":"npm --prefix ../.. run build:client && expo run:ios --configuration Release",web:"npm --prefix ../.. run build:client && concurrently --kill-others --names protocol,client,expo --prefix-colors yellow,blue,magenta \"npm --prefix ../.. run watch:protocol\" \"npm --prefix ../.. run watch:client\" \"npm run web:expo\"","web:expo":"expo start --web",lint:"expo lint",typecheck:"tsgo --noEmit",test:"vitest run","test:browser":"vitest run --project browser","test:e2e":"playwright test --project='Desktop Chrome'","test:e2e:real":"cross-env E2E_FORK_PASEO_HOME_FROM=../../.dev/paseo-home playwright test --project=real-provider","test:e2e:ui":"playwright test --ui","test:coverage":"vitest run --project unit --coverage",build:"npm run build:web","build:web":"npm --prefix ../.. run build:app-deps && expo export --platform web --source-maps","profile:workspace-tabs":"node ./scripts/profile-workspace-tabs.mjs","deploy:web":"npm run build:web && wrangler pages deploy dist --project-name paseo-app --branch main"},dependencies:{"@bacons/apple-targets":"4.0.6","@datadog/browser-rum":"^6.23.0","@datadog/browser-rum-react":"^6.23.0","@datadog/mobile-react-native":"^2.7.0","@datadog/mobile-react-native-session-replay":"^2.14.8","@dnd-kit/core":"^6.3.1","@dnd-kit/sortable":"^10.0.0","@dnd-kit/utilities":"^3.2.2","@expo/image-utils":"0.8.8","@expo/plist":"0.4.9","@expo/prebuild-config":"54.0.8","@floating-ui/react-native":"^0.10.7","@gorhom/bottom-sheet":"^5.2.14","@gorhom/portal":"^1.0.14","@hyperdrive.bot/fleet-client":"*","@hyperdrive.bot/fleet-expo-two-way-audio":"*","@hyperdrive.bot/fleet-extension-sdk":"*","@hyperdrive.bot/fleet-highlight":"*","@react-native-async-storage/async-storage":"2.2.0","@react-native-masked-view/masked-view":"^0.3.2","@react-native/normalize-colors":"^0.81.5","@react-navigation/native":"^7.1.8","@sentry/electron":"^6.11.0","@sentry/react-native":"^6.20.0","@tanstack/react-query":"^5.90.11","@tanstack/react-virtual":"^3.13.21","@xterm/addon-clipboard":"^0.3.0-beta.213","@xterm/addon-fit":"^0.12.0-beta.213","@xterm/addon-image":"^0.10.0-beta.213","@xterm/addon-ligatures":"0.11.0-beta.213","@xterm/addon-search":"^0.17.0-beta.213","@xterm/addon-unicode11":"^0.10.0-beta.213","@xterm/addon-web-links":"^0.13.0-beta.213","@xterm/addon-webgl":"^0.20.0-beta.212","@xterm/xterm":"^6.1.0-beta.213",buffer:"^6.0.3",expo:"^54.0.18","expo-asset":"~12.0.12","expo-audio":"~1.0.13","expo-background-fetch":"~14.0.9","expo-build-properties":"^1.0.9","expo-camera":"~17.0.10","expo-clipboard":"~8.0.7","expo-constants":"~18.0.9","expo-crypto":"^15.0.8","expo-dev-client":"^6.0.15","expo-document-picker":"~14.0.8","expo-file-system":"~19.0.17","expo-haptics":"~15.0.7","expo-image":"~3.0.10","expo-image-manipulator":"~14.0.8","expo-image-picker":"^17.0.8","expo-keep-awake":"^15.0.7","expo-linking":"~8.0.8","expo-localization":"~17.0.9","expo-notifications":"^0.32.16","expo-router":"~6.0.13","expo-sharing":"^14.0.8","expo-speech":"~14.0.8","expo-speech-recognition":"^56.0.1","expo-splash-screen":"~31.0.10","expo-system-ui":"~6.0.7","expo-task-manager":"~14.0.9","expo-video":"~3.0.16","fast-deep-equal":"^3.1.3",htmlparser2:"^12.0.0",i18next:"^26.3.0","lucide-react-native":"^0.546.0","markdown-it":"^10.0.0","mnemonic-id":"^3.2.7",qrcode:"^1.5.4",react:"19.1.0","react-dom":"19.1.0","react-i18next":"^17.0.8","react-native":"0.81.5","react-native-draggable-flatlist":"^4.0.3","react-native-edge-to-edge":"^1.7.0","react-native-gesture-handler":"~2.28.0","react-native-keyboard-controller":"^1.21.7","react-native-markdown-display":"^7.0.2","react-native-nitro-modules":"0.35.5","react-native-reanimated":"~4.3.1","react-native-safe-area-context":"~5.6.0","react-native-screens":"~4.16.0","react-native-svg":"^15.14.0","react-native-uitextview":"^2.2.0","react-native-unistyles":"^3.2.4","react-native-web":"~0.21.0","react-native-webview":"^13.16.0","react-native-worklets":"~0.8.3","tiny-invariant":"^1.3.3","use-sync-external-store":"^1.6.0",zod:"^4.4.3",zustand:"^5.0.9"},devDependencies:{"@playwright/test":"^1.56.1","@testing-library/dom":"^10.4.1","@testing-library/react":"^16.3.2","@types/chai":"^5.2.2","@types/markdown-it":"^14.1.2","@types/qrcode":"^1.5.6","@types/react":"~19.2.0","@types/ws":"^8.18.1","@vitest/browser":"^4.1.7","@vitest/browser-playwright":"^4.1.7","@vitest/coverage-v8":"^4.1.7","@xterm/headless":"^6.1.0-beta.213",dotenv:"^17.2.3",eslint:"^9.25.0","eslint-config-expo":"~10.0.0",jsdom:"^20.0.3","material-icon-theme":"^5.32.0",playwright:"^1.56.1","serve-sim":"^0.1.40",typescript:"~5.9.2",vitest:"^4.1.6",wrangler:"^4.105.0",ws:"^8.20.0"}}},3415,[]);
|
|
15061
15061
|
__d(function(g,r,i,a,m,e,d){"use strict";Object.defineProperty(e,'__esModule',{value:!0}),e.shouldUseDesktopDaemon=function(){return(0,n.isElectronRuntime)()},e.getDesktopDaemonStatus=async function(){return c(await(0,t.invokeDesktopCommand)("desktop_daemon_status"))},e.startDesktopDaemon=async function(){return c(await(0,t.invokeDesktopCommand)("start_desktop_daemon"))},e.stopDesktopDaemon=async function(n="manual_ipc"){return c(await(0,t.invokeDesktopCommand)("stop_desktop_daemon",{reason:n}))},e.restartDesktopDaemon=async function(){return c(await(0,t.invokeDesktopCommand)("restart_desktop_daemon"))},e.getDesktopDaemonLogs=async function(){return p(await(0,t.invokeDesktopCommand)("desktop_daemon_logs"))},e.getDesktopDaemonPairing=async function(){return k(await(0,t.invokeDesktopCommand)("desktop_daemon_pairing"))},e.getCliDaemonStatus=async function(){const n=await(0,t.invokeDesktopCommand)("cli_daemon_status");if("string"!=typeof n)throw new Error("Unexpected CLI daemon status response.");return n},e.listenToLocalTransportEvents=async function(t){const u=(0,n.getDesktopHost)()?.events?.on;if("function"!=typeof u)throw new Error("Desktop events API is unavailable.");const c=await u("local-daemon-transport-event",n=>{o(n)&&t({sessionId:s(n.sessionId)??"",kind:s(n.kind)??"error",text:s(n.text),binaryBase64:s(n.binaryBase64),code:l(n.code),reason:s(n.reason),error:s(n.error)})});return"function"==typeof c?c:()=>{}},e.openLocalTransportSession=async function(n){const o=await(0,t.invokeDesktopCommand)("open_local_daemon_transport",n);if("string"!=typeof o||0===o.trim().length)throw new Error("Unexpected local transport session response.");return o},e.sendLocalTransportMessage=async function(n){await(0,t.invokeDesktopCommand)("send_local_daemon_transport_message",Object.assign({sessionId:n.sessionId},n.text?{text:n.text}:{},n.binaryBase64?{binaryBase64:n.binaryBase64}:{}))},e.closeLocalTransportSession=async function(n){await(0,t.invokeDesktopCommand)("close_local_daemon_transport",{sessionId:n})},e.getCliInstallStatus=async function(){return f(await(0,t.invokeDesktopCommand)("get_cli_install_status"))},e.installCli=async function(){return f(await(0,t.invokeDesktopCommand)("install_cli"))},e.getSkillsStatus=async function(){return y(await(0,t.invokeDesktopCommand)("get_skills_status"))},e.installSkills=async function(){return y(await(0,t.invokeDesktopCommand)("install_skills"))},e.updateSkills=async function(){return y(await(0,t.invokeDesktopCommand)("update_skills"))},e.uninstallSkills=async function(){return y(await(0,t.invokeDesktopCommand)("uninstall_skills"))};var n=r(d[0]),t=r(d[1]);function o(n){return"object"==typeof n&&null!==n}function s(n){return"string"==typeof n&&n.trim().length>0?n:null}function l(n){return"number"==typeof n&&Number.isFinite(n)?n:null}function u(n){const t=s(n)?.toLowerCase();switch(t){case"starting":return"starting";case"running":return"running";case"errored":case"error":return"errored";default:return"stopped"}}function c(n){if(!o(n))throw new Error("Unexpected desktop daemon status response.");return{serverId:s(n.serverId)??"",status:u(n.status),listen:s(n.listen),hostname:s(n.hostname),pid:l(n.pid),home:s(n.home)??"",version:s(n.version),desktopManaged:!0===n.desktopManaged,error:s(n.error)}}function p(n){if(!o(n))throw new Error("Unexpected desktop daemon logs response.");return{logPath:s(n.logPath)??"",contents:"string"==typeof n.contents?n.contents:""}}function k(n){if(!o(n))throw new Error("Unexpected desktop daemon pairing response.");return{relayEnabled:!0===n.relayEnabled,url:s(n.url),qr:s(n.qr)}}function f(n){if(!o(n))throw new Error("Unexpected install status response.");return{installed:!0===n.installed}}function w(n){switch(n){case"not-installed":case"up-to-date":case"drift":return n;default:throw new Error(`Unexpected skills status state: ${String(n)}`)}}function _(n){if(!o(n))throw new Error("Unexpected skill op response.");const t=s(n.name);if(!t)throw new Error("Skill op missing name.");switch(n.kind){case"add":return{kind:"add",name:t};case"update":return{kind:"update",name:t};case"delete":return{kind:"delete",name:t};default:throw new Error(`Unexpected skill op kind: ${String(n.kind)}`)}}function y(n){if(!o(n))throw new Error("Unexpected skills status response.");const t=Array.isArray(n.ops)?n.ops.map(_):[];return{state:w(n.state),ops:t}}},3416,[3417,3419]);
|
|
15062
15062
|
__d(function(g,r,i,a,m,e,d){"use strict";Object.defineProperty(e,'__esModule',{value:!0}),e.getDesktopHost=n,e.isElectronRuntime=o,e.isElectronRuntimeMac=function(){if(!o())return!1;if("undefined"==typeof navigator)return!1;const t=n()?.platform?.toLowerCase();if("darwin"===t||"mac"===t||"macos"===t)return!0;const u=navigator.userAgent;return u.includes("Mac OS")||u.includes("Macintosh")},r(d[0]);var t=r(d[1]);function n(){return(0,t.getElectronHost)()}function o(){return null!==n()}},3417,[25,3418]);
|
|
15063
15063
|
__d(function(g,r,i,a,m,e,d){"use strict";Object.defineProperty(e,'__esModule',{value:!0}),e.getElectronHost=function(){if("undefined"==typeof window)return null;const t=window.paseoDesktop;if(!t||"object"!=typeof t)return null;return t}},3418,[]);
|
|
@@ -16321,14 +16321,14 @@ __d(function(g,r,i,a,m,e,d){"use strict";function t(n){return null!=n&&("string"
|
|
|
16321
16321
|
__d(function(g,r,i,a,m,e,d){"use strict";Object.defineProperty(e,'__esModule',{value:!0}),e.isBinaryByPath=function(n){const s=o(n);return!!s&&t.has(s)};const t=new Set(["pdf","doc","docx","xls","xlsx","ppt","pptx","rtf","odt","ods","odp","png","jpg","jpeg","gif","webp","ico","bmp","tiff","tif","heic","heif","avif","mp3","wav","ogg","m4a","flac","opus","aac","mp4","webm","avi","mov","mkv","m4v","zip","tar","gz","bz2","xz","7z","rar","lz","zst","exe","dll","so","dylib","a","o","obj","lib","class","jar","war","dmg","iso","img","pkg","apk","ipa","msi","deb","rpm","ttf","otf","woff","woff2","eot","db","sqlite","sqlite3","mdb","pyc","pyo","pyd","bin","dat","pak"]);function o(t){if(!t)return null;const o=t.split("/").findLast(Boolean)??"";if(o.startsWith(".")&&-1===o.indexOf(".",1))return null;const n=o.lastIndexOf(".");if(n<=0)return null;const s=o.slice(n+1).toLowerCase();return 0===s.length?null:s}},4562,[]);
|
|
16322
16322
|
__d(function(g,r,i,a,m,_e,d){"use strict";Object.defineProperty(_e,'__esModule',{value:!0}),_e.HighlightedLines=function(e){const n=(0,o.c)(13),{lines:l,startLine:s}=e;if(void 0===s){let e,o;return n[0]!==l?(e=l.map(j),n[0]=l,n[1]=e):e=n[1],n[2]!==e?(o=(0,S.jsx)(t.View,{dataSet:f.CODE_SURFACE_DATASET,children:e}),n[2]=e,n[3]=o):o=n[3],o}const c=s+l.length-1,u=Math.max(2,String(c).length);let x,h;if(n[4]!==u||n[5]!==l||n[6]!==s){let e;n[8]!==u||n[9]!==s?(e=(e,t)=>(0,S.jsx)(T,{line:e,lineNumber:s+t,digits:u},e.key),n[8]=u,n[9]=s,n[10]=e):e=n[10],x=l.map(e),n[4]=u,n[5]=l,n[6]=s,n[7]=x}else x=n[7];n[11]!==x?(h=(0,S.jsx)(t.View,{dataSet:f.CODE_SURFACE_DATASET,children:x}),n[11]=x,n[12]=h):h=n[12];return h};var e,t=r(d[0]),n=r(d[1]),o=r(d[2]),l=r(d[3]),s=(e=l)&&e.__esModule?e:{default:e};r(d[4]),r(d[5]);var c=r(d[6]),u=r(d[7]),f=r(d[8]),x=r(d[9]),S=r(d[10]);const h="\u200b";function y(e){const t=(0,o.c)(4),{line:l}=e;let s,c;return t[0]!==l.tokens?(s=0===l.tokens.length?h:l.tokens.map(_),t[0]=l.tokens,t[1]=s):s=t[1],t[2]!==s?(c=(0,S.jsx)(n.Text,{selectable:!0,style:p.lineText,children:s}),t[2]=s,t[3]=c):c=t[3],c}function _(e){const{key:t,token:o}=e;return(0,S.jsx)(n.Text,{style:o.style?(0,x.syntaxTokenStyleFor)(o.style):void 0,children:o.text},t)}const T=s.default.memo(function(e){const l=(0,o.c)(10),{line:s,lineNumber:c,digits:u}=e,f=String(c);let x,h,_,T;return l[0]!==u||l[1]!==f?(x=f.padStart(u),l[0]=u,l[1]=f,l[2]=x):x=l[2],l[3]!==x?(h=(0,S.jsxs)(n.Text,{style:p.gutterText,children:[x," "]}),l[3]=x,l[4]=h):h=l[4],l[5]!==s?(_=(0,S.jsx)(y,{line:s}),l[5]=s,l[6]=_):_=l[6],l[7]!==h||l[8]!==_?(T=(0,S.jsxs)(t.View,{style:p.row,children:[h,_]}),l[7]=h,l[8]=_,l[9]=T):T=l[9],T});function j(e){return(0,S.jsx)(y,{line:e},e.key)}const p=c.StyleSheet.create(e=>({row:{flexDirection:"row",minHeight:18},gutterText:{fontFamily:e.fontFamily.mono,fontSize:e.fontSize.code,lineHeight:18,color:e.colors.foregroundMuted,opacity:.6,userSelect:"none",flexShrink:0,uni__dependencies:[0]},lineText:Object.assign({fontFamily:e.fontFamily.mono,fontSize:e.fontSize.code,color:e.colors.foreground,lineHeight:18},u.isWeb?{whiteSpace:"pre",overflowWrap:"normal"}:null,{uni__dependencies:[0]})}))},4563,[348,349,350,36,234,146,56,3420,3820,3821,279]);
|
|
16323
16323
|
__d(function(g,r,i,a,m,_e,d){"use strict";Object.defineProperty(_e,'__esModule',{value:!0}),_e.DiffViewer=function(e){const t=(0,l.c)(32),{diffLines:c,maxHeight:u,emptyLabel:y,fillAvailableHeight:h}=e,p=void 0!==h&&h,{t:S}=(0,x.useTranslation)(),[v,k]=s.default.useState(0);let C;t[0]!==y||t[1]!==S?(C=y??S("diffViewer.empty"),t[0]=y,t[1]=S,t[2]=C):C=t[2];const w=C,H=(0,f.useWebScrollbarStyle)();let L;t[3]===Symbol.for("react.memo_cache_sentinel")?(L=e=>k(e.nativeEvent.layout.width),t[3]=L):L=t[3];const E=L;let W;t[4]!==u?(W=void 0!==u&&(0,T.inlineUnistylesStyle)({maxHeight:u}),t[4]=u,t[5]=W):W=t[5];const F=p&&$.fillHeight;let M;t[6]!==W||t[7]!==F||t[8]!==H?(M=[$.verticalScroll,W,F,H],t[6]=W,t[7]=F,t[8]=H,t[9]=M):M=t[9];const A=M;let D,I;t[10]!==v?(D=v>0&&(0,T.inlineUnistylesStyle)({minWidth:v}),t[10]=v,t[11]=D):D=t[11];t[12]!==D?(I=[$.linesContainer,D],t[12]=D,t[13]=I):I=t[13];const O=I;let R;t[14]!==c?(R=c.map(z),t[14]=c,t[15]=R):R=t[15];const U=R,B=p&&$.fillHeight;let P;t[16]!==B?(P=[$.verticalContent,B],t[16]=B,t[17]=P):P=t[17];const G=P;if(!c.length){let e;return t[18]!==w?(e=(0,b.jsx)(o.View,{style:$.emptyState,children:(0,b.jsx)(n.Text,{style:$.emptyText,children:w})}),t[18]=w,t[19]=e):e=t[19],e}let q,J;t[20]!==U?(q=U.map(V),t[20]=U,t[21]=q):q=t[21];t[22]!==O||t[23]!==q?(J=(0,b.jsx)(o.View,{style:O,dataSet:_.CODE_SURFACE_DATASET,children:q}),t[22]=O,t[23]=q,t[24]=J):J=t[24];const K=J;let N;t[25]!==K||t[26]!==H?(N=(0,b.jsx)(j,{horizontal:!0,nestedScrollEnabled:!0,showsHorizontalScrollIndicator:!0,style:H,contentContainerStyle:$.horizontalContent,onLayout:E,children:K}),t[25]=K,t[26]=H,t[27]=N):N=t[27];const Q=N;let X;t[28]!==Q||t[29]!==A||t[30]!==G?(X=(0,b.jsx)(j,{style:A,contentContainerStyle:G,nestedScrollEnabled:!0,showsVerticalScrollIndicator:!0,children:Q}),t[28]=Q,t[29]=A,t[30]=G,t[31]=X):X=t[31];return X};var e,t=r(d[0]),n=r(d[1]),o=r(d[2]),l=r(d[3]),c=r(d[4]),s=(e=c)&&e.__esModule?e:{default:e},x=r(d[5]);r(d[6]),r(d[7]),r(d[8]);var u=r(d[9]),y=r(d[10]),h=r(d[11]),p=r(d[12]),f=r(d[13]),T=r(d[14]),S=r(d[15]),_=r(d[16]),v=r(d[17]),b=r(d[18]);const j=v.isWeb?t.ScrollView:u.ScrollView;function k(e){const t=(0,l.c)(35),{line:c}=e,s="header"===c.type&&$.headerLine,x="add"===c.type&&$.addLine,u="remove"===c.type&&$.removeLine,y="context"===c.type&&$.contextLine;let p;t[0]!==s||t[1]!==x||t[2]!==u||t[3]!==y?(p=[$.line,s,x,u,y],t[0]=s,t[1]=x,t[2]=u,t[3]=y,t[4]=p):p=t[4];const f=p,T="header"===c.type&&$.headerText,S="add"===c.type&&$.addText,_="remove"===c.type&&$.removeText,v="context"===c.type&&$.contextText;let j;t[5]!==T||t[6]!==S||t[7]!==_||t[8]!==v?(j=[$.lineText,T,S,_,v],t[5]=T,t[6]=S,t[7]=_,t[8]=v,t[9]=j):j=t[9];const k=j,w="add"===c.type&&$.addText,H="remove"===c.type&&$.removeText,V="context"===c.type&&$.contextText;let z;t[10]!==w||t[11]!==H||t[12]!==V?(z=[w,H,V],t[10]=w,t[11]=H,t[12]=V,t[13]=z):z=t[13];const E=z;if(c.tokens){let e,l,s,x,u;return t[14]!==c?(e=(0,h.diffLinePrefix)(c),t[14]=c,t[15]=e):e=t[15],t[16]!==E||t[17]!==e?(l=(0,b.jsx)(n.Text,{style:E,children:e}),t[16]=E,t[17]=e,t[18]=l):l=t[18],t[19]!==c.tokens?(s=(0,b.jsx)(C,{tokens:c.tokens}),t[19]=c.tokens,t[20]=s):s=t[20],t[21]!==l||t[22]!==s?(x=(0,b.jsxs)(n.Text,{style:$.lineText,children:[l,s]}),t[21]=l,t[22]=s,t[23]=x):x=t[23],t[24]!==f||t[25]!==x?(u=(0,b.jsx)(o.View,{style:f,children:x}),t[24]=f,t[25]=x,t[26]=u):u=t[26],u}let W,F;return t[27]!==c.content||t[28]!==c.segments||t[29]!==c.type||t[30]!==k?(W=c.segments?(0,b.jsxs)(n.Text,{style:$.lineText,children:[(0,b.jsx)(n.Text,{style:"add"===c.type?$.addText:$.removeText,children:c.content[0]}),c.segments.map(e=>(0,b.jsx)(L,{segment:e,lineType:c.type},`${e.changed?"c":"u"}:${e.text}`))]}):(0,b.jsx)(n.Text,{style:k,children:c.content}),t[27]=c.content,t[28]=c.segments,t[29]=c.type,t[30]=k,t[31]=W):W=t[31],t[32]!==f||t[33]!==W?(F=(0,b.jsx)(o.View,{style:f,children:W}),t[32]=f,t[33]=W,t[34]=F):F=t[34],F}function C(e){const t=(0,l.c)(6),{tokens:n}=e;let o;t[0]!==n?(o=n.map(H),t[0]=n,t[1]=o):o=t[1];const c=o;let s,x;return t[2]!==c?(s=c.map(w),t[2]=c,t[3]=s):s=t[3],t[4]!==s?(x=(0,b.jsx)(b.Fragment,{children:s}),t[4]=s,t[5]=x):x=t[5],x}function w(e){const{key:t,token:o}=e;return(0,b.jsx)(n.Text,{style:o.style?(0,p.syntaxTokenStyleFor)(o.style):void 0,children:o.text},t)}function H(e,t){return{key:`${t}-${e.text}`,token:e}}function L(e){const t=(0,l.c)(6),{segment:o,lineType:c}=e,s="add"===c?$.addText:$.removeText,x=o.changed&&("add"===c?$.addHighlight:$.removeHighlight);let u;t[0]!==s||t[1]!==x?(u=[s,x],t[0]=s,t[1]=x,t[2]=u):u=t[2];const y=u;let h;return t[3]!==o.text||t[4]!==y?(h=(0,b.jsx)(n.Text,{style:y,children:o.text}),t[3]=o.text,t[4]=y,t[5]=h):h=t[5],h}function V(e){const{key:t,line:n}=e;return(0,b.jsx)(k,{line:n},t)}function z(e,t){return{key:`${t}-${e.type}-${e.content}`,line:e}}const $=y.StyleSheet.create(e=>{const t=(0,S.getCodeInsets)(e);return{verticalScroll:{},fillHeight:{flex:1,minHeight:0},verticalContent:{flexGrow:1,paddingBottom:t.extraBottom},horizontalContent:{flexDirection:"column",paddingRight:t.extraRight},linesContainer:{alignSelf:"flex-start",padding:t.padding},line:{minWidth:"100%",paddingHorizontal:0,paddingVertical:e.spacing[1],uni__dependencies:[0]},lineText:Object.assign({fontFamily:e.fontFamily.mono,fontSize:e.fontSize.code,color:e.colors.foreground},v.isWeb?{whiteSpace:"pre",overflowWrap:"normal"}:null,{uni__dependencies:[0]}),headerLine:{backgroundColor:e.colors.surface1,uni__dependencies:[0]},headerText:{color:e.colors.foregroundMuted,uni__dependencies:[0]},addLine:{backgroundColor:"rgba(46, 160, 67, 0.15)"},addText:{color:e.colors.foreground,uni__dependencies:[0]},removeLine:{backgroundColor:"rgba(248, 81, 73, 0.1)"},removeText:{color:e.colors.foreground,uni__dependencies:[0]},addHighlight:{backgroundColor:"rgba(46, 160, 67, 0.4)"},removeHighlight:{backgroundColor:"rgba(248, 81, 73, 0.35)"},contextLine:{backgroundColor:e.colors.surface1,uni__dependencies:[0]},contextText:{color:e.colors.foregroundMuted,uni__dependencies:[0]},emptyState:{padding:e.spacing[4],alignItems:"center",justifyContent:"center",uni__dependencies:[0]},emptyText:{fontSize:e.fontSize.sm,color:e.colors.foregroundMuted,uni__dependencies:[0]}}})},4564,[2815,349,348,350,36,352,146,234,182,2482,56,4560,3821,3589,3486,3885,3820,3420,279]);
|
|
16324
|
-
__d(function(g,r,i,a,m,e,d){"use strict";Object.defineProperty(e,'__esModule',{value:!0}),Object.defineProperty(e,"default",{enumerable:!0,get:function(){return f}});var t=r(d[0]);r(d[1]);var s=r(d[2]),n=r(d[3]),o=r(d[4]),l=r(d[5]),c=r(d[6]),u=r(d[7]);function f(){const f=(0,t.c)(13),{serverId:
|
|
16325
|
-
__d(function(g,r,_i,_a,m,_e,_d){"use strict";function e(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(_e,'__esModule',{value:!0}),Object.defineProperty(_e,"UNWIRED_VERBS",{enumerable:!0,get:function(){return z}}),_e.bucketLabel=R,_e.relativeAge=P,_e.cardMetaLine=L,Object.defineProperty(_e,"ReelsScreen",{enumerable:!0,get:function(){return U}}),_e.shareTextFor=X;var t=r(_d[0]),n=r(_d[1]),s=r(_d[2]),o=r(_d[3]),l=r(_d[4]),i=r(_d[5]),c=r(_d[6]),a=r(_d[7]),d=e(r(_d[8]));r(_d[9]);var u=e(r(_d[10]));r(_d[11]),r(_d[12]),r(_d[13]),r(_d[14]),r(_d[15]),r(_d[16]);var h=r(_d[17]),p=r(_d[18]),b=r(_d[19]),y=r(_d[20]),x=r(_d[21]),f=r(_d[22]),j=r(_d[23]),S=r(_d[24]),_=r(_d[25]),k=r(_d[26]),T=r(_d[27]),v=r(_d[28]);function w(e,t,n){return t&&"hold"!==t?t:e||"hold"===t?"hold to retire, this cannot be undone":n}function C(e,t){return"terminate"===e?`${t}. Hold to confirm, this cannot be undone.`:z.has(e)?`${t}. Not wired yet.`:t}const I={share:null,automate:null},z=new Set([]);function V(e){return e.key}const D={needs_input:"needs you",failed:"failed",attention:"wants a look",pending:"waiting",running:"running",done:"done"};function R(e){return D[e]??e.replace(/_/g," ")}function P(e,t=new Date){if(!e)return"";const n=t.getTime()-e.getTime();if(!Number.isFinite(n)||n<0)return"";const s=Math.floor(n/6e4);if(s<1)return"just now";if(s<60)return`${s}m`;const o=Math.floor(s/60);return o<24?`${o}h`:`${Math.floor(o/24)}d`}function L(e){return[R(String(e.statusBucket)),P(e.lastActivityAt),`${e.provider}/${e.model}`].filter(e=>e.length>0).join(" \xb7 ")}const A=(0,a.memo)(function(e){const p=(0,c.c)(97),{session:b,visible:y,onClose:x,onSend:f,sendError:j,openDecisions:S}=e,[_,k]=(0,a.useState)(""),T=S[0]?.question??null,w=b.digest;let C;p[0]!==f||p[1]!==_?(C=()=>{const e=_.trim();e.length>0&&(f(e),k(""))},p[0]=f,p[1]=_,p[2]=C):C=p[2];const I=C,z=(0,h.useSafeAreaInsets)(),V=Y.captionSheet,[D,R]=(0,a.useState)(!1);let P,L;p[3]===Symbol.for("react.memo_cache_sentinel")?(P=()=>{const e=d.default.addListener("keyboardDidShow",()=>R(!0)),t=d.default.addListener("keyboardDidHide",()=>R(!1));return()=>{e.remove(),t.remove()}},L=[],p[3]=P,p[4]=L):(P=p[3],L=p[4]),(0,a.useEffect)(P,L);const A=D&&!1?0:z.bottom;let $;p[5]!==A?($=[Y.sheetInner,{paddingBottom:A}],p[5]=A,p[6]=$):$=p[6];const E=$;let O;p[7]!==x?(O=u.default.create({onMoveShouldSetPanResponder:de,onPanResponderRelease:(e,t)=>{t.dy>60&&x()}}),p[7]=x,p[8]=O):O=p[8];const M=O;let B,W,F;p[9]!==x||p[10]!==y?(B=()=>{if(!y||"undefined"==typeof document)return;const e=e=>{"Escape"===e.key&&x()};return document.addEventListener("keydown",e),()=>document.removeEventListener("keydown",e)},W=[x,y],p[9]=x,p[10]=y,p[11]=B,p[12]=W):(B=p[11],W=p[12]),(0,a.useEffect)(B,W),p[13]!==T||p[14]!==S.length?(F=T?(0,v.jsx)(s.Text,{style:Y.composerLabel,numberOfLines:2,testID:"reels-composer-target",children:S.length>1?`Answering the first of ${S.length} open decisions: ${T}`:`Answering: ${T}`}):null,p[13]=T,p[14]=S.length,p[15]=F):F=p[15];const N=T?"in your own words":"say what to do";let G,K,q,U,J;p[16]!==I||p[17]!==N||p[18]!==_?(G=(0,v.jsx)(n.TextInput,{value:_,onChangeText:k,placeholder:N,style:Y.composerInput,onSubmitEditing:I,returnKeyType:"send",testID:"reels-composer-input"}),p[16]=I,p[17]=N,p[18]=_,p[19]=G):G=p[19],p[20]===Symbol.for("react.memo_cache_sentinel")?(K=(0,v.jsx)(s.Text,{style:Y.link,children:"send"}),p[20]=K):K=p[20],p[21]!==I?(q=(0,v.jsx)(l.Pressable,{onPress:I,style:Y.composerSend,accessibilityRole:"button",accessibilityLabel:"Send this answer",hitSlop:8,testID:"reels-composer-send",children:K}),p[21]=I,p[22]=q):q=p[22],p[23]!==G||p[24]!==q?(U=(0,v.jsxs)(t.View,{style:Y.composer,children:[G,q]}),p[23]=G,p[24]=q,p[25]=U):U=p[25],p[26]!==U||p[27]!==F?(J=(0,v.jsxs)(t.View,{children:[F,U]}),p[26]=U,p[27]=F,p[28]=J):J=p[28];const Q=J;if(!y)return null;let X,Z,ee,te,ne,se,oe;p[29]!==x?(X=(0,v.jsx)(l.Pressable,{style:Y.captionBackdrop,onPress:x,accessibilityRole:"button",accessibilityLabel:"Close the digest",testID:"reels-caption-backdrop"}),p[29]=x,p[30]=X):X=p[30],p[31]===Symbol.for("react.memo_cache_sentinel")?(Z=(0,v.jsx)(t.View,{style:Y.sheetHandle}),p[31]=Z):Z=p[31],p[32]!==M.panHandlers?(ee=(0,v.jsx)(t.View,Object.assign({},M.panHandlers,{style:Y.sheetGrab,testID:"reels-caption-grab",children:Z})),p[32]=M.panHandlers,p[33]=ee):ee=p[33],p[34]!==b.title?(te=(0,v.jsx)(s.Text,{style:Y.sheetTitle,numberOfLines:1,children:b.title}),p[34]=b.title,p[35]=te):te=p[35],p[36]===Symbol.for("react.memo_cache_sentinel")?(ne=(0,v.jsx)(s.Text,{style:Y.sheetCloseGlyph,children:"\u2715"}),p[36]=ne):ne=p[36],p[37]!==x?(se=(0,v.jsx)(l.Pressable,{onPress:x,style:Y.sheetClose,hitSlop:8,accessibilityRole:"button",accessibilityLabel:"Close the digest",testID:"reels-caption-close",children:ne}),p[37]=x,p[38]=se):se=p[38],p[39]!==te||p[40]!==se?(oe=(0,v.jsxs)(t.View,{style:Y.sheetHead,children:[te,se]}),p[39]=te,p[40]=se,p[41]=oe):oe=p[41];const le=w?.summary;let ie;p[42]!==le?(ie=(0,v.jsx)(H,{label:"Summary",value:le,derived:!0}),p[42]=le,p[43]=ie):ie=p[43];const re=w?.goal;let ce;p[44]!==re?(ce=(0,v.jsx)(H,{label:"Goal",value:re}),p[44]=re,p[45]=ce):ce=p[45];const ae=w?.nextStep;let he,pe,be,ge,ye,me,xe,fe,je,Se,ke,Te;if(p[46]!==ae?(he=(0,v.jsx)(H,{label:"Next step",value:ae}),p[46]=ae,p[47]=he):he=p[47],p[48]!==w?.blockers?(pe=w?.blockers?.join("\n"),p[48]=w?.blockers,p[49]=pe):pe=p[49],p[50]!==pe?(be=(0,v.jsx)(H,{label:"Blockers",value:pe,danger:!0}),p[50]=pe,p[51]=be):be=p[51],p[52]!==w?.accomplishments?(ge=w?.accomplishments?.join("\n"),p[52]=w?.accomplishments,p[53]=ge):ge=p[53],p[54]!==ge?(ye=(0,v.jsx)(H,{label:"Accomplishments",value:ge,derived:!0}),p[54]=ge,p[55]=ye):ye=p[55],p[56]!==w?.keyFiles?(me=w?.keyFiles?.join("\n"),p[56]=w?.keyFiles,p[57]=me):me=p[57],p[58]!==me?(xe=(0,v.jsx)(H,{label:"Key files",value:me,derived:!0}),p[58]=me,p[59]=xe):xe=p[59],p[60]!==w?.links?(fe=w?.links?.map(ue).join("\n"),p[60]=w?.links,p[61]=fe):fe=p[61],p[62]!==fe?(je=(0,v.jsx)(H,{label:"Links",value:fe}),p[62]=fe,p[63]=je):je=p[63],p[64]!==S){let e;p[66]!==S.length?(e=(e,t)=>(0,v.jsx)(H,{label:S.length>1?`Decision ${t+1} of ${S.length}`:"Decision",value:e.question},e.id),p[66]=S.length,p[67]=e):e=p[67],Se=S.map(e),p[64]=S,p[65]=Se}else Se=p[65];p[68]!==b.tags?(ke=b.tags.join(", ")||"no tag",p[68]=b.tags,p[69]=ke):ke=p[69],p[70]!==ke?(Te=(0,v.jsx)(H,{label:"Tags",value:ke}),p[70]=ke,p[71]=Te):Te=p[71];const ve=b.kanban??"inbox";let we,Ce,Ie,ze,Ve;return p[72]!==ve?(we=(0,v.jsx)(H,{label:"Kanban",value:ve}),p[72]=ve,p[73]=we):we=p[73],p[74]!==ie||p[75]!==ce||p[76]!==he||p[77]!==be||p[78]!==ye||p[79]!==xe||p[80]!==je||p[81]!==Se||p[82]!==Te||p[83]!==we?(Ce=(0,v.jsxs)(o.ScrollView,{style:Y.sheetBody,testID:"reels-caption-body",children:[ie,ce,he,be,ye,xe,je,Se,Te,we]}),p[74]=ie,p[75]=ce,p[76]=he,p[77]=be,p[78]=ye,p[79]=xe,p[80]=je,p[81]=Se,p[82]=Te,p[83]=we,p[84]=Ce):Ce=p[84],p[85]!==j?(Ie=j?(0,v.jsxs)(s.Text,{style:Y.sendError,testID:"reels-composer-error",children:["Could not send that: ",j,". Nothing was recorded, so try again."]}):null,p[85]=j,p[86]=Ie):Ie=p[86],p[87]!==Q||p[88]!==E||p[89]!==ee||p[90]!==oe||p[91]!==Ce||p[92]!==Ie?(ze=(0,v.jsx)(i.KeyboardAvoidingView,{behavior:"height",style:V,testID:"reels-caption-sheet",children:(0,v.jsxs)(t.View,{style:E,children:[ee,oe,Ce,Ie,Q]})}),p[87]=Q,p[88]=E,p[89]=ee,p[90]=oe,p[91]=Ce,p[92]=Ie,p[93]=ze):ze=p[93],p[94]!==X||p[95]!==ze?(Ve=(0,v.jsxs)(v.Fragment,{children:[X,ze]}),p[94]=X,p[95]=ze,p[96]=Ve):Ve=p[96],Ve}),H=(0,a.memo)(function(e){const n=(0,c.c)(9),{label:o,value:l,derived:i,danger:a}=e;if(!l)return null;const d=i?" (derived)":"";let u;n[0]!==o||n[1]!==d?(u=(0,v.jsxs)(s.Text,{style:Y.fieldLabel,children:[o,d]}),n[0]=o,n[1]=d,n[2]=u):u=n[2];const h=a?Z:Y.fieldValue;let p,b;return n[3]!==h||n[4]!==l?(p=(0,v.jsx)(s.Text,{style:h,children:l}),n[3]=h,n[4]=l,n[5]=p):p=n[5],n[6]!==u||n[7]!==p?(b=(0,v.jsxs)(t.View,{style:Y.field,children:[u,p]}),n[6]=u,n[7]=p,n[8]=b):b=n[8],b}),$=(0,a.memo)(function(e){const t=(0,c.c)(23),{session:n,picked:o,isWinner:i,onToggle:a,onCrown:d}=e;let u;t[0]!==a||t[1]!==n.id?(u=()=>a(n.id),t[0]=a,t[1]=n.id,t[2]=u):u=t[2];const h=u;let p;t[3]!==d||t[4]!==n.id?(p=()=>d(n.id),t[3]=d,t[4]=n.id,t[5]=p):p=t[5];const b=p;let y="\u2610";o&&(y=i?"\u25c9":"\u2611");const x=o?ee:Y.pickRow,f=`reels-consolidate-pick-${n.id}`;let j,S,_;t[6]!==y?(j=(0,v.jsx)(s.Text,{style:Y.pickMark,children:y}),t[6]=y,t[7]=j):j=t[7],t[8]!==n.title?(S=(0,v.jsx)(s.Text,{style:Y.pickName,children:n.title}),t[8]=n.title,t[9]=S):S=t[9],t[10]!==n.lastActivityAt?(_=P(n.lastActivityAt),t[10]=n.lastActivityAt,t[11]=_):_=t[11];const k=i&&o?" \xb7 survives":"";let T,w;return t[12]!==_||t[13]!==k?(T=(0,v.jsxs)(s.Text,{style:Y.pickAux,children:[_,k]}),t[12]=_,t[13]=k,t[14]=T):T=t[14],t[15]!==b||t[16]!==x||t[17]!==f||t[18]!==j||t[19]!==S||t[20]!==T||t[21]!==h?(w=(0,v.jsxs)(l.Pressable,{onPress:h,onLongPress:b,style:x,testID:f,children:[j,S,T]}),t[15]=b,t[16]=x,t[17]=f,t[18]=j,t[19]=S,t[20]=T,t[21]=h,t[22]=w):w=t[22],w}),E=(0,a.memo)(function(e){const n=(0,c.c)(46),{candidates:i,onCancel:d,onConsolidate:u}=e;let h;n[0]===Symbol.for("react.memo_cache_sentinel")?(h={},n[0]=h):h=n[0];const[p,b]=(0,a.useState)(h);let y;if(n[1]!==i||n[2]!==p){let e;n[4]!==p?(e=e=>p[e.id],n[4]=p,n[5]=e):e=n[5],y=i.filter(e),n[1]=i,n[2]=p,n[3]=y}else y=n[3];const x=y,[f,j]=(0,a.useState)(null);let S;n[6]!==x||n[7]!==f?(S=f??x.slice().sort(he)[0]?.id??null,n[6]=x,n[7]=f,n[8]=S):S=n[8];const _=S;let k;n[9]===Symbol.for("react.memo_cache_sentinel")?(k=e=>{b(t=>{const n=Object.assign({},t);return n[e]?delete n[e]:n[e]=!0,n})},n[9]=k):k=n[9];const T=k;let w;if(n[10]!==x||n[11]!==_){let e;n[13]!==_?(e=e=>e.id!==_,n[13]=_,n[14]=e):e=n[14],w=x.filter(e).map(pe),n[10]=x,n[11]=_,n[12]=w}else w=n[12];const C=w,I=x.length>=2&&null!==_;let z;n[15]!==u||n[16]!==C||n[17]!==_?(z=()=>{_&&u(_,C)},n[15]=u,n[16]=C,n[17]=_,n[18]=z):z=n[18];const V=z;let D,R,P,L,A,H;if(n[19]===Symbol.for("react.memo_cache_sentinel")?(D=(0,v.jsx)(s.Text,{style:Y.sheetTitle,children:"Consolidate"}),R=(0,v.jsx)(s.Text,{style:Y.hint,children:"The winner keeps its transcript. The others are archived and linked to it, both ways. Nothing is deleted."}),n[19]=D,n[20]=R):(D=n[19],R=n[20]),n[21]!==i||n[22]!==p||n[23]!==_){let e;n[25]!==p||n[26]!==_?(e=e=>(0,v.jsx)($,{session:e,picked:Boolean(p[e.id]),isWinner:_===e.id,onToggle:T,onCrown:j},e.id),n[25]=p,n[26]=_,n[27]=e):e=n[27],P=i.map(e),n[21]=i,n[22]=p,n[23]=_,n[24]=P}else P=n[24];n[28]!==P?(L=(0,v.jsx)(o.ScrollView,{style:Y.pickList,children:P}),n[28]=P,n[29]=L):L=n[29],n[30]===Symbol.for("react.memo_cache_sentinel")?(A=(0,v.jsx)(s.Text,{style:Y.link,children:"cancel"}),n[30]=A):A=n[30],n[31]!==d?(H=(0,v.jsx)(l.Pressable,{onPress:d,style:Y.send,testID:"reels-consolidate-cancel",children:A}),n[31]=d,n[32]=H):H=n[32];const E=!I,O=I?Y.send:le;let M,B,W,F;return n[33]!==C.length?(M=(0,v.jsxs)(s.Text,{style:Y.link,children:["consolidate ",C.length]}),n[33]=C.length,n[34]=M):M=n[34],n[35]!==V||n[36]!==E||n[37]!==O||n[38]!==M?(B=(0,v.jsx)(l.Pressable,{onPress:V,disabled:E,style:O,testID:"reels-consolidate-commit",children:M}),n[35]=V,n[36]=E,n[37]=O,n[38]=M,n[39]=B):B=n[39],n[40]!==H||n[41]!==B?(W=(0,v.jsxs)(t.View,{style:Y.rowGap,children:[H,B]}),n[40]=H,n[41]=B,n[42]=W):W=n[42],n[43]!==L||n[44]!==W?(F=(0,v.jsxs)(t.View,{style:Y.sheet,testID:"reels-consolidate",children:[D,R,L,W]}),n[43]=L,n[44]=W,n[45]=F):F=n[45],F}),O=(0,a.memo)(function(e){const n=(0,c.c)(29),{verb:o,glyph:i,label:a,onVerb:d}=e,u="terminate"===o,{showLabel:h,progress:p,hint:b,handlers:y}=(0,j.useDestructiveHold)(d,o);let x;n[0]!==d||n[1]!==o?(x=()=>d(o),n[0]=d,n[1]=o,n[2]=x):x=n[2];const f=x,S=z.has(o);let _;n[3]!==p?(_=Math.round(100*p),n[3]=p,n[4]=_):_=n[4];const k=`${_}%`;let T;n[5]!==k?(T=[Y.verbFill,{width:k}],n[5]=k,n[6]=T):T=n[6];const C=T;if(!u){const e=S?`${a}. Not wired yet.`:a,t=`reels-verb-${o}`;let c,d;return n[7]!==i?(c=(0,v.jsx)(s.Text,{style:Y.verbGlyph,children:i}),n[7]=i,n[8]=c):c=n[8],n[9]!==e||n[10]!==t||n[11]!==c||n[12]!==f?(d=(0,v.jsx)(l.Pressable,{onPress:f,style:Y.verbChip,accessibilityRole:"button",accessibilityLabel:e,hitSlop:8,testID:t,children:c}),n[9]=e,n[10]=t,n[11]=c,n[12]=f,n[13]=d):d=n[13],d}const I=`${a}. Hold to confirm, this cannot be undone.`,V=`reels-verb-${o}`;let D,R,P,L;return n[14]!==C||n[15]!==p?(D=p>0?(0,v.jsx)(t.View,{style:C,testID:"reels-verb-hold-fill"}):null,n[14]=C,n[15]=p,n[16]=D):D=n[16],n[17]!==i?(R=(0,v.jsx)(s.Text,{style:Y.verbGlyph,children:i}),n[17]=i,n[18]=R):R=n[18],n[19]!==b||n[20]!==h?(P=h||b?(0,v.jsx)(s.Text,{style:Y.verbHoldLabel,testID:"reels-verb-terminate-hold",children:w(h,b,"hold to retire")}):null,n[19]=b,n[20]=h,n[21]=P):P=n[21],n[22]!==y||n[23]!==I||n[24]!==V||n[25]!==D||n[26]!==R||n[27]!==P?(L=(0,v.jsxs)(l.Pressable,Object.assign({},y,{style:Y.verbChip,accessibilityRole:"button",accessibilityLabel:I,hitSlop:8,testID:V,children:[D,R,P]})),n[22]=y,n[23]=I,n[24]=V,n[25]=D,n[26]=R,n[27]=P,n[28]=L):L=n[28],L}),M=(0,a.memo)(function(e){const t=(0,c.c)(10),{everyMs:n,label:o,onPick:i}=e;let a;t[0]!==n||t[1]!==i?(a=()=>i(n),t[0]=n,t[1]=i,t[2]=a):a=t[2];const d=a,u=`reels-automate-${n}`;let h,p;return t[3]!==o?(h=(0,v.jsx)(s.Text,{style:Y.pickName,children:o}),t[3]=o,t[4]=h):h=t[4],t[5]!==o||t[6]!==d||t[7]!==u||t[8]!==h?(p=(0,v.jsx)(l.Pressable,{onPress:d,style:Y.pickRow,accessibilityRole:"button",accessibilityLabel:o,testID:u,children:h}),t[5]=o,t[6]=d,t[7]=u,t[8]=h,t[9]=p):p=t[9],p}),B=["needs_input","failed","attention","pending","running","done"],W=(0,a.memo)(function(e){const t=(0,c.c)(14),{value:n,label:o,active:i,onCycle:a}=e;let d;t[0]!==a||t[1]!==n?(d=()=>a(n),t[0]=a,t[1]=n,t[2]=d):d=t[2];const u=d,h=i?te:Y.tagChip;let p;t[3]!==i?(p=oe(i),t[3]=i,t[4]=p):p=t[4];const b=`reels-filter-${n}`;let y,x;return t[5]!==o?(y=(0,v.jsx)(s.Text,{style:Y.tagChipText,children:o}),t[5]=o,t[6]=y):y=t[6],t[7]!==o||t[8]!==u||t[9]!==h||t[10]!==p||t[11]!==b||t[12]!==y?(x=(0,v.jsx)(l.Pressable,{onPress:u,style:h,accessibilityRole:"button",accessibilityState:p,accessibilityLabel:o,testID:b,children:y}),t[7]=o,t[8]=u,t[9]=h,t[10]=p,t[11]=b,t[12]=y,t[13]=x):x=t[13],x}),F=(0,a.memo)(function(e){const t=(0,c.c)(10),{target:n,label:o,onShare:i}=e;let a;t[0]!==i||t[1]!==n?(a=()=>i(n),t[0]=i,t[1]=n,t[2]=a):a=t[2];const d=a,u=`Send to ${o}`,h=`reels-share-${n}`;let p,b;return t[3]!==o?(p=(0,v.jsx)(s.Text,{style:Y.pickName,children:o}),t[3]=o,t[4]=p):p=t[4],t[5]!==d||t[6]!==u||t[7]!==h||t[8]!==p?(b=(0,v.jsx)(l.Pressable,{onPress:d,style:Y.pickRow,accessibilityRole:"button",accessibilityLabel:u,testID:h,children:p}),t[5]=d,t[6]=u,t[7]=h,t[8]=p,t[9]=b):b=t[9],b}),N=(0,a.memo)(function(e){const n=(0,c.c)(42),{verb:o,glyph:i,label:a,detail:d,onVerb:u}=e,h="terminate"===o,{showLabel:p,progress:b,hint:y,handlers:x}=(0,j.useDestructiveHold)(u,o);let f;n[0]!==u||n[1]!==o?(f=()=>u(o),n[0]=u,n[1]=o,n[2]=f):f=n[2];const S=f;let _;n[3]!==b?(_=Math.round(100*b),n[3]=b,n[4]=_):_=n[4];const k=`${_}%`;let T;n[5]!==k?(T=[Y.verbFill,{width:k}],n[5]=k,n[6]=T):T=n[6];const I=T;let V;n[7]!==h||n[8]!==x||n[9]!==S?(V=h?x:{onPress:S},n[7]=h,n[8]=x,n[9]=S,n[10]=V):V=n[10];const D=V;let R;n[11]!==a||n[12]!==o?(R=C(o,a),n[11]=a,n[12]=o,n[13]=R):R=n[13];const P=`reels-taco-${o}`;let L,A,H,$,E,O,M,B;return n[14]!==h||n[15]!==b||n[16]!==I?(L=h&&b>0?(0,v.jsx)(t.View,{style:I,testID:"reels-taco-hold-fill"}):null,n[14]=h,n[15]=b,n[16]=I,n[17]=L):L=n[17],n[18]!==i?(A=(0,v.jsx)(s.Text,{style:Y.pickMark,children:i}),n[18]=i,n[19]=A):A=n[19],n[20]!==a?(H=(0,v.jsx)(s.Text,{style:Y.pickName,children:a}),n[20]=a,n[21]=H):H=n[21],n[22]!==h||n[23]!==d||n[24]!==y||n[25]!==p?($=h?w(p,y,d):d,n[22]=h,n[23]=d,n[24]=y,n[25]=p,n[26]=$):$=n[26],n[27]!==$?(E=(0,v.jsx)(s.Text,{style:Y.hint,children:$}),n[27]=$,n[28]=E):E=n[28],n[29]!==o?(O=z.has(o)?(0,v.jsx)(s.Text,{style:Y.pickAux,children:"not wired yet"}):null,n[29]=o,n[30]=O):O=n[30],n[31]!==H||n[32]!==E||n[33]!==O?(M=(0,v.jsxs)(t.View,{style:Y.grow,children:[H,E,O]}),n[31]=H,n[32]=E,n[33]=O,n[34]=M):M=n[34],n[35]!==D||n[36]!==M||n[37]!==R||n[38]!==P||n[39]!==L||n[40]!==A?(B=(0,v.jsxs)(l.Pressable,Object.assign({},D,{style:Y.pickRow,accessibilityRole:"button",accessibilityLabel:R,testID:P,children:[L,A,M]})),n[35]=D,n[36]=M,n[37]=R,n[38]=P,n[39]=L,n[40]=A,n[41]=B):B=n[41],B}),G=(0,a.memo)(function(e){const n=(0,c.c)(7),{mode:o,text:l}=e;if("off"===o)return null;const i="text"===o?ie:Y.background,a=`reels-background-${o}`;let d,u;return n[0]!==o||n[1]!==l?(d="text"===o?(0,v.jsx)(s.Text,{style:Y.backgroundBody,numberOfLines:40,children:l}):null,n[0]=o,n[1]=l,n[2]=d):d=n[2],n[3]!==i||n[4]!==a||n[5]!==d?(u=(0,v.jsx)(t.View,{style:i,testID:a,children:d}),n[3]=i,n[4]=a,n[5]=d,n[6]=u):u=n[6],u}),K=(0,a.memo)(function(e){const n=(0,c.c)(23),{gated:o,allTags:l,onPickTag:i,decision:a,decisions:d,serverId:u,agentId:h,onAnswered:p,onVerb:x,actAllowed:f,capLabel:j}=e;if(o){let e;return n[0]!==l||n[1]!==i?(e=(0,v.jsx)(y.TagGate,{available:l,onPick:i}),n[0]=l,n[1]=i,n[2]=e):e=n[2],e}if(a){if(!f){let e,o,l,i,c;return n[3]!==j?(e=(0,v.jsx)(s.Text,{style:Y.hint,children:j}),n[3]=j,n[4]=e):e=n[4],n[5]===Symbol.for("react.memo_cache_sentinel")?(o=(0,v.jsx)(s.Text,{style:Y.cardTapHint,children:"Decisions are done for today. You can still retire or snooze this one."}),n[5]=o):o=n[5],n[6]!==x?(l=y.TACO_VERBS.map(e=>(0,v.jsx)(O,{verb:e.id,glyph:e.glyph,label:e.label,onVerb:x},e.id)),n[6]=x,n[7]=l):l=n[7],n[8]!==l?(i=(0,v.jsx)(t.View,{style:Y.rowGap,children:l}),n[8]=l,n[9]=i):i=n[9],n[10]!==e||n[11]!==i?(c=(0,v.jsxs)(t.View,{testID:"reels-cap-reached",children:[e,o,i]}),n[10]=e,n[11]=i,n[12]=c):c=n[12],c}let e;return n[13]!==h||n[14]!==d||n[15]!==p||n[16]!==u?(e=(0,v.jsx)(b.DecisionChips,{serverId:u,agentId:h,decisions:d,onAnswered:p}),n[13]=h,n[14]=d,n[15]=p,n[16]=u,n[17]=e):e=n[17],e}let S,_,k;return n[18]===Symbol.for("react.memo_cache_sentinel")?(S=(0,v.jsx)(s.Text,{style:Y.hint,children:"Nothing to decide. Why is this still open?"}),n[18]=S):S=n[18],n[19]!==x?(_=y.TACO_VERBS.map(e=>(0,v.jsx)(O,{verb:e.id,glyph:e.glyph,label:e.label,onVerb:x},e.id)),n[19]=x,n[20]=_):_=n[20],n[21]!==_?(k=(0,v.jsxs)(t.View,{testID:"reels-taco-row",children:[S,(0,v.jsx)(t.View,{style:Y.rowGap,children:_})]}),n[21]=_,n[22]=k):k=n[22],k}),q=(0,a.memo)(function(e){const n=(0,c.c)(62),{overlay:i,session:a,ring:d,onClose:u,onSend:h,onSnooze:p,onConsolidate:b,onKanban:x,onVerb:f,overlayStyle:j,sendError:S,verbError:_,openDecisions:k,onShare:T,onAutomate:w,allTags:C,statusSelection:I,tagSelection:z,onCycleStatus:V,onCycleTag:D}=e,P=a,L="caption"===i.kind;let H,$,O,G,K,q,U,Q,X;return n[0]!==P||n[1]!==u||n[2]!==h||n[3]!==k||n[4]!==S||n[5]!==L?(H=(0,v.jsx)(A,{session:P,visible:L,onClose:u,onSend:h,sendError:S,openDecisions:k},P.id),n[0]=P,n[1]=u,n[2]=h,n[3]=k,n[4]=S,n[5]=L,n[6]=H):H=n[6],n[7]!==P.snoozeCount||n[8]!==u||n[9]!==p||n[10]!==i.kind||n[11]!==j?($="snooze"===i.kind?(0,v.jsx)(t.View,{style:j,children:(0,v.jsx)(y.SnoozeSheet,{priorCount:P.snoozeCount,onCancel:u,onSnooze:p})}):null,n[7]=P.snoozeCount,n[8]=u,n[9]=p,n[10]=i.kind,n[11]=j,n[12]=$):$=n[12],n[13]!==u||n[14]!==b||n[15]!==i.kind||n[16]!==j||n[17]!==d?(O="consolidate"===i.kind?(0,v.jsx)(t.View,{style:j,children:(0,v.jsx)(E,{candidates:d,onCancel:u,onConsolidate:b})}):null,n[13]=u,n[14]=b,n[15]=i.kind,n[16]=j,n[17]=d,n[18]=O):O=n[18],n[19]!==u||n[20]!==f||n[21]!==i.kind||n[22]!==j?(G="taco"===i.kind?(0,v.jsx)(t.View,{style:j,children:(0,v.jsxs)(t.View,{style:Y.sheet,testID:"reels-taco-sheet",children:[(0,v.jsx)(s.Text,{style:Y.sheetTitle,children:"TACO"}),y.TACO_VERBS.map(e=>(0,v.jsx)(N,{verb:e.id,glyph:e.glyph,label:e.label,detail:e.detail,onVerb:f},e.id)),(0,v.jsx)(l.Pressable,{onPress:u,style:Y.send,children:(0,v.jsx)(s.Text,{style:Y.link,children:"cancel"})})]})}):null,n[19]=u,n[20]=f,n[21]=i.kind,n[22]=j,n[23]=G):G=n[23],n[24]!==C||n[25]!==u||n[26]!==V||n[27]!==D||n[28]!==i.kind||n[29]!==j||n[30]!==I||n[31]!==z?(K="filters"===i.kind?(0,v.jsx)(t.View,{style:j,children:(0,v.jsxs)(o.ScrollView,{style:Y.sheet,testID:"reels-filters-sheet",children:[(0,v.jsx)(s.Text,{style:Y.sheetTitle,children:"Filter the ring"}),(0,v.jsx)(s.Text,{style:Y.hint,children:"The same filter the sessions list uses, so setting it here sets it there."}),(0,v.jsx)(s.Text,{style:Y.fieldLabel,children:"State"}),(0,v.jsx)(t.View,{style:Y.rowGap,children:B.map(e=>(0,v.jsx)(W,{value:e,label:R(e),active:I.include.includes(e),onCycle:V},e))}),(0,v.jsx)(s.Text,{style:Y.fieldLabel,children:"Tag"}),(0,v.jsx)(t.View,{style:Y.rowGap,children:C.map(e=>(0,v.jsx)(W,{value:e,label:e,active:z.include.includes(e),onCycle:D},e))}),(0,v.jsx)(l.Pressable,{onPress:u,style:Y.send,testID:"reels-filters-done",children:(0,v.jsx)(s.Text,{style:Y.link,children:"done"})})]})}):null,n[24]=C,n[25]=u,n[26]=V,n[27]=D,n[28]=i.kind,n[29]=j,n[30]=I,n[31]=z,n[32]=K):K=n[32],n[33]!==w||n[34]!==u||n[35]!==i.kind||n[36]!==j||n[37]!==_?(q="automate"===i.kind?(0,v.jsx)(t.View,{style:j,children:(0,v.jsxs)(t.View,{style:Y.sheet,testID:"reels-automate-sheet",children:[(0,v.jsx)(s.Text,{style:Y.sheetTitle,children:"Automate"}),(0,v.jsx)(s.Text,{style:Y.hint,children:"Re-runs this session on a cadence, with its next step as the prompt."}),_?(0,v.jsx)(s.Text,{style:Y.sendError,testID:"reels-verb-error",children:_}):null,ae.map(e=>(0,v.jsx)(M,{everyMs:e.everyMs,label:e.label,onPick:w},e.id)),(0,v.jsx)(l.Pressable,{onPress:u,style:Y.send,children:(0,v.jsx)(s.Text,{style:Y.link,children:"cancel"})})]})}):null,n[33]=w,n[34]=u,n[35]=i.kind,n[36]=j,n[37]=_,n[38]=q):q=n[38],n[39]!==u||n[40]!==T||n[41]!==i.kind||n[42]!==j||n[43]!==_?(U="share"===i.kind?(0,v.jsx)(t.View,{style:j,children:(0,v.jsxs)(t.View,{style:Y.sheet,testID:"reels-share-sheet",children:[(0,v.jsx)(s.Text,{style:Y.sheetTitle,children:"Send"}),(0,v.jsx)(s.Text,{style:Y.hint,children:"Send this card somewhere a person will read it."}),_?(0,v.jsx)(s.Text,{style:Y.sendError,testID:"reels-verb-error",children:_}):null,J.map(e=>(0,v.jsx)(F,{target:e.id,label:e.label,onShare:T},e.id)),(0,v.jsx)(l.Pressable,{onPress:u,style:Y.send,children:(0,v.jsx)(s.Text,{style:Y.link,children:"cancel"})})]})}):null,n[39]=u,n[40]=T,n[41]=i.kind,n[42]=j,n[43]=_,n[44]=U):U=n[44],n[45]!==P.kanban||n[46]!==P.model||n[47]!==P.provider||n[48]!==u||n[49]!==x||n[50]!==i.kind||n[51]!==j?(Q="options"===i.kind?(0,v.jsx)(t.View,{style:j,children:(0,v.jsxs)(o.ScrollView,{style:Y.sheet,testID:"reels-options-sheet",children:[(0,v.jsx)(s.Text,{style:Y.sheetTitle,children:"Session options"}),(0,v.jsx)(s.Text,{style:Y.fieldLabel,children:"Kanban"}),(0,v.jsx)(y.KanbanPicker,{current:P.kanban,onPick:x}),(0,v.jsx)(s.Text,{style:Y.fieldLabel,children:"Provider and model"}),(0,v.jsxs)(s.Text,{style:Y.fieldValue,children:[P.provider,"/",P.model]}),(0,v.jsx)(s.Text,{style:Y.hint,children:"One control in the app, not two: combined-model-selector with favourites."}),(0,v.jsx)(l.Pressable,{onPress:u,style:Y.send,children:(0,v.jsx)(s.Text,{style:Y.link,children:"close"})})]})}):null,n[45]=P.kanban,n[46]=P.model,n[47]=P.provider,n[48]=u,n[49]=x,n[50]=i.kind,n[51]=j,n[52]=Q):Q=n[52],n[53]!==H||n[54]!==$||n[55]!==O||n[56]!==G||n[57]!==K||n[58]!==q||n[59]!==U||n[60]!==Q?(X=(0,v.jsxs)(v.Fragment,{children:[H,$,O,G,K,q,U,Q]}),n[53]=H,n[54]=$,n[55]=O,n[56]=G,n[57]=K,n[58]=q,n[59]=U,n[60]=Q,n[61]=X):X=n[61],X}),U=(0,a.memo)(function(e){const n=(0,c.c)(155),{sessions:o,allTags:i,actCap:d,background:u,now:p}=e,b=void 0===d?T.DEFAULT_ACT_CAP:d,j=void 0===u?"text":u,w=(0,S.useReelsVerbs)(),{answer:C}=(0,f.useAnswerDecision)(),[z,D]=(0,a.useState)(be);let R,P,A;n[0]!==p?(R=()=>{if(p)return;const e=setInterval(()=>D(Date.now()),6e4);return()=>clearInterval(e)},P=[p],n[0]=p,n[1]=R,n[2]=P):(R=n[1],P=n[2]),(0,a.useEffect)(R,P),n[3]!==p||n[4]!==z?(A=p??new Date(z),n[3]=p,n[4]=z,n[5]=A):A=n[5];const H=A,[$,E]=(0,a.useState)(1),[O,M]=(0,a.useState)(0),[B,W]=(0,a.useState)(0);let F;n[6]===Symbol.for("react.memo_cache_sentinel")?(F={kind:"none"},n[6]=F):F=n[6];const[N,U]=(0,a.useState)(F);let J;n[7]===Symbol.for("react.memo_cache_sentinel")?(J={},n[7]=J):J=n[7];const[Q,Z]=(0,a.useState)(J);let ee;n[8]===Symbol.for("react.memo_cache_sentinel")?(ee={},n[8]=ee):ee=n[8];const[te,ne]=(0,a.useState)(ee),[se,oe]=(0,a.useState)(null),[le,ie]=(0,a.useState)(I);let ae;n[9]===Symbol.for("react.memo_cache_sentinel")?(ae=(e,t)=>{ie(n=>Object.assign({},n,{[e]:t}))},n[9]=ae):ae=n[9];const de=ae,ue=(0,a.useRef)(null);let he;n[10]!==te||n[11]!==$||n[12]!==Q||n[13]!==H||n[14]!==o?(he={sessions:o,localTags:Q,actedLaps:te,laps:$,now:H},n[10]=te,n[11]=$,n[12]=Q,n[13]=H,n[14]=o,n[15]=he):he=n[15];const{feed:pe,activeFilters:je,statusSelection:Se,tagSelection:ke,onCycleStatus:Te,onCycleTag:ve}=(0,_.useReelsFeed)(he),we=pe[Math.min(B,Math.max(pe.length-1,0))]??null,Ce=we?.session??null,Ie=we?.lap??1;let ze;if(n[16]!==pe||n[17]!==Ie){let e;n[19]!==Ie?(e=e=>e.lap===Ie,n[19]=Ie,n[20]=e):e=n[20],ze=pe.filter(e).map(ge),n[16]=pe,n[17]=Ie,n[18]=ze}else ze=n[18];const Ve=ze,De=Ce?.id??"",Re=Ce?.serverId??"";let Pe;var Le;n[21]!==Ce?(Pe=Ce?(Le=Ce.digest,(Le?.pendingDecisions??[]).filter(e=>!e.answeredAt)):[],n[21]=Ce,n[22]=Pe):Pe=n[22];const Ae=Pe,He=Ae[0]??null;let $e;n[23]!==Ae?($e=Ae.map(ye),n[23]=Ae,n[24]=$e):$e=n[24];const Ee=$e,Oe=Ae,Me=!!Ce&&0===Ce.tags.length;let Be;n[25]!==b||n[26]!==O?(Be=(0,T.canAct)({acts:O,cap:b}),n[25]=b,n[26]=O,n[27]=Be):Be=n[27];const We=Be;let Fe;n[28]!==b||n[29]!==O?(Fe=(0,T.actCapLabel)({acts:O,cap:b}),n[28]=b,n[29]=O,n[30]=Fe):Fe=n[30];const Ne=Fe,Ge=(0,h.useSafeAreaInsets)();let Ke;n[31]!==Ge.top?(Ke=[Y.headerSlot,{paddingTop:Ge.top}],n[31]=Ge.top,n[32]=Ke):Ke=n[32];const qe=Ke,Ue=Ge.top+56;let Ye;n[33]!==Ue?(Ye=[Y.seamBanner,{paddingTop:Ue}],n[33]=Ue,n[34]=Ye):Ye=n[34];const Je=Ye;let Qe;n[35]!==Ge.bottom||n[36]!==Ge.top?(Qe=[Y.overlay,{paddingTop:Ge.top,paddingBottom:Ge.bottom}],n[35]=Ge.bottom,n[36]=Ge.top,n[37]=Qe):Qe=n[37];const Xe=Qe;let Ze;n[38]!==B?(Ze=()=>{U({kind:"none"}),ue.current?.scrollToIndex(B+1)},n[38]=B,n[39]=Ze):Ze=n[39];const et=Ze;let tt;n[40]!==Ie?(tt=e=>{ne(t=>Object.assign({},t,{[e]:Ie}))},n[40]=Ie,n[41]=tt):tt=n[41];const nt=tt;let st;n[42]===Symbol.for("react.memo_cache_sentinel")?(st=()=>{E(me)},n[42]=st):st=n[42];const ot=st;let lt,it,rt,ct,at,dt;n[43]===Symbol.for("react.memo_cache_sentinel")?(lt={id:"read",glyph:"\ud83d\udcd6",label:"read"},n[43]=lt):lt=n[43],n[44]!==Me?(it={id:"snooze",glyph:"\ud83d\ude34",label:"snooze",disabled:Me},n[44]=Me,n[45]=it):it=n[45],n[46]===Symbol.for("react.memo_cache_sentinel")?(rt={id:"share",glyph:"\ud83d\udce4",label:"send"},n[46]=rt):rt=n[46],n[47]!==Me?(ct={id:"taco",glyph:"\u2699\ufe0f",label:"TACO",disabled:Me},n[47]=Me,n[48]=ct):ct=n[48],n[49]===Symbol.for("react.memo_cache_sentinel")?(at={id:"options",glyph:"\u22ef",label:"options"},n[49]=at):at=n[49],n[50]!==it||n[51]!==ct?(dt=[lt,it,rt,ct,at],n[50]=it,n[51]=ct,n[52]=dt):dt=n[52];const ut=dt;let ht;n[53]===Symbol.for("react.memo_cache_sentinel")?(ht=()=>U({kind:"caption"}),n[53]=ht):ht=n[53];const pt=ht;let bt;n[54]===Symbol.for("react.memo_cache_sentinel")?(bt=()=>U({kind:"none"}),n[54]=bt):bt=n[54];const gt=bt;let yt;n[55]===Symbol.for("react.memo_cache_sentinel")?(yt=()=>U({kind:"filters"}),n[55]=yt):yt=n[55];const mt=yt;let xt;n[56]===Symbol.for("react.memo_cache_sentinel")?(xt=e=>{ie(I);const t=re[e];t&&U({kind:t})},n[56]=xt):xt=n[56];const ft=xt;let jt;n[57]!==De||n[58]!==Re||n[59]!==w?(jt=e=>{Z(t=>Object.assign({},t,{[De]:[e]})),w.setTags({serverId:Re,agentId:De},[e])},n[57]=De,n[58]=Re,n[59]=w,n[60]=jt):jt=n[60];const St=jt;let _t;n[61]!==et||n[62]!==De||n[63]!==Ae.length||n[64]!==nt?(_t=()=>{M(xe),nt(De),Ae.length<=1&&et()},n[61]=et,n[62]=De,n[63]=Ae.length,n[64]=nt,n[65]=_t):_t=n[65];const kt=_t;let Tt;n[66]!==et||n[67]!==De||n[68]!==nt||n[69]!==Re||n[70]!==w?(Tt=async e=>{if("terminate"===e)return await w.terminate({serverId:Re,agentId:De}),nt(De),void et();ie(I),U({kind:ce[e]})},n[66]=et,n[67]=De,n[68]=nt,n[69]=Re,n[70]=w,n[71]=Tt):Tt=n[71];const vt=Tt;let wt;n[72]!==et||n[73]!==De||n[74]!==nt||n[75]!==Re||n[76]!==w?(wt=e=>{w.snooze({serverId:Re,agentId:De},e.until,e.untilWhat,e.why),nt(De),et()},n[72]=et,n[73]=De,n[74]=nt,n[75]=Re,n[76]=w,n[77]=wt):wt=n[77];const Ct=wt;let It;n[78]!==et||n[79]!==nt||n[80]!==Re||n[81]!==w?(It=(e,t)=>{w.consolidate({serverId:Re,winnerId:e,sourceIds:t});for(const n of[e,...t])nt(n);et()},n[78]=et,n[79]=nt,n[80]=Re,n[81]=w,n[82]=It):It=n[82];const zt=It;let Vt;n[83]!==C||n[84]!==De||n[85]!==He||n[86]!==kt||n[87]!==Re?(Vt=e=>{const t=e.trim();0!==t.length&&He?(oe(null),C({serverId:Re,agentId:De,decisionId:He.id,optionId:null,note:t}).then(()=>(kt(),null)).catch(e=>{oe(e instanceof Error?e.message:String(e))})):U({kind:"none"})},n[83]=C,n[84]=De,n[85]=He,n[86]=kt,n[87]=Re,n[88]=Vt):Vt=n[88];const Dt=Vt;let Rt;n[89]!==Ce||n[90]!==w?(Rt=e=>{Ce&&(de("share",null),w.share(e,X(Ce)).then(()=>(U({kind:"none"}),null)).catch(e=>{de("share",e instanceof Error?e.message:"could not open that")}))},n[89]=Ce,n[90]=w,n[91]=Rt):Rt=n[91];const Pt=Rt;let Lt;n[92]!==et||n[93]!==Ce||n[94]!==De||n[95]!==nt||n[96]!==Re||n[97]!==w?(Lt=e=>{if(!Ce)return;de("automate",null);const t=Ce.digest?.nextStep??Ce.digest?.goal??`Continue ${Ce.title}`;w.automate({serverId:Re,agentId:De},e,t,Ce.title).then(()=>(nt(De),et(),null)).catch(e=>{de("automate",e instanceof Error?e.message:"could not create the routine")})},n[92]=et,n[93]=Ce,n[94]=De,n[95]=nt,n[96]=Re,n[97]=w,n[98]=Lt):Lt=n[98];const At=Lt;let Ht;n[99]!==De||n[100]!==Re||n[101]!==w?(Ht=e=>{w.setKanban({serverId:Re,agentId:De},e),U({kind:"none"})},n[99]=De,n[100]=Re,n[101]=w,n[102]=Ht):Ht=n[102];const $t=Ht;let Et;n[103]!==i||n[104]!==We||n[105]!==j||n[106]!==Ne||n[107]!==He||n[108]!==Oe||n[109]!==pe||n[110]!==Me||n[111]!==B||n[112]!==kt||n[113]!==vt||n[114]!==St||n[115]!==ut||n[116]!==Ve.length||n[117]!==Je?(Et=(e,n)=>{const o=n===B,c=e.session;return(0,v.jsxs)(t.View,{style:Y.card,children:[(0,v.jsx)(G,{mode:j,text:c.digest?.summary??c.title}),e.firstOfLap&&e.lap>1?(0,v.jsx)(t.View,{style:Je,testID:`reels-seam-${e.lap}`,children:(0,v.jsx)(y.LapSeam,{lap:e.lap,ringSize:Ve.length,acted:(0,k.actedThisLap)(pe.filter(t=>t.lap===e.lap-1).map(fe),e.lap-1)})}):null,(0,v.jsx)(t.View,{style:Y.middle,children:o?(0,v.jsx)(y.ReelsRail,{actions:ut,contextLabel:c.tags[0]??"untagged",onAction:ft}):null}),(0,v.jsxs)(t.View,{style:Y.bottom,children:[(0,v.jsxs)(l.Pressable,{onPress:o?pt:void 0,disabled:!o,testID:o?"reels-caption-open":void 0,accessibilityRole:"button",accessibilityLabel:`Open the full digest for ${c.title}`,style:Y.captionTap,children:[(0,v.jsx)(s.Text,{style:Y.cardTitle,children:c.title}),(0,v.jsx)(s.Text,{style:Y.cardMeta,children:L(c)}),(0,v.jsx)(s.Text,{style:Y.cardSummary,numberOfLines:4,children:c.digest?.summary??c.digest?.goal??"No digest yet."}),o?(0,v.jsx)(s.Text,{style:Y.cardTapHint,children:"tap for the whole digest and to talk to it"}):null]}),o?(0,v.jsx)(K,{gated:Me,allTags:i,onPickTag:St,decision:He,decisions:Oe,serverId:c.serverId,agentId:c.id,onAnswered:kt,onVerb:vt,actAllowed:We,capLabel:Ne}):null]})]})},n[103]=i,n[104]=We,n[105]=j,n[106]=Ne,n[107]=He,n[108]=Oe,n[109]=pe,n[110]=Me,n[111]=B,n[112]=kt,n[113]=vt,n[114]=St,n[115]=ut,n[116]=Ve.length,n[117]=Je,n[118]=Et):Et=n[118];const Ot=Et;if(!Ce){let e;return n[119]===Symbol.for("react.memo_cache_sentinel")?(e=(0,v.jsx)(t.View,{style:Y.empty,testID:"reels-empty",children:(0,v.jsx)(s.Text,{style:Y.fieldValue,children:"No sessions in the ring."})}),n[119]=e):e=n[119],e}let Mt;n[120]!==pe||n[121]!==Ot?(Mt=(0,v.jsx)(x.ReelsPager,{data:pe,keyExtractor:V,renderCard:Ot,onIndexChange:W,onEndReached:ot,controllerRef:ue}),n[120]=pe,n[121]=Ot,n[122]=Mt):Mt=n[122];const Bt=`${B+1} \xb7 lap ${Ie}`;let Wt,Ft;n[123]!==b||n[124]!==je||n[125]!==O||n[126]!==Bt?(Wt=(0,v.jsx)(y.ReelsHeader,{acts:O,cap:b,activeFilters:je,onFilter:mt,position:Bt}),n[123]=b,n[124]=je,n[125]=O,n[126]=Bt,n[127]=Wt):Wt=n[127],n[128]!==qe||n[129]!==Wt?(Ft=(0,v.jsx)(t.View,{style:qe,pointerEvents:"box-none",children:Wt}),n[128]=qe,n[129]=Wt,n[130]=Ft):Ft=n[130];const Nt="automate"===N.kind?le.automate:le.share;let Gt,Kt;return n[131]!==i||n[132]!==Ce||n[133]!==At||n[134]!==Dt||n[135]!==zt||n[136]!==Te||n[137]!==ve||n[138]!==$t||n[139]!==Pt||n[140]!==Ct||n[141]!==vt||n[142]!==Ee||n[143]!==N||n[144]!==Xe||n[145]!==Ve||n[146]!==se||n[147]!==Se||n[148]!==Nt||n[149]!==ke?(Gt=(0,v.jsx)(q,{overlay:N,session:Ce,ring:Ve,onClose:gt,onSend:Dt,onSnooze:Ct,onConsolidate:zt,onKanban:$t,onVerb:vt,overlayStyle:Xe,sendError:se,verbError:Nt,openDecisions:Ee,onShare:Pt,onAutomate:At,allTags:i,statusSelection:Se,tagSelection:ke,onCycleStatus:Te,onCycleTag:ve}),n[131]=i,n[132]=Ce,n[133]=At,n[134]=Dt,n[135]=zt,n[136]=Te,n[137]=ve,n[138]=$t,n[139]=Pt,n[140]=Ct,n[141]=vt,n[142]=Ee,n[143]=N,n[144]=Xe,n[145]=Ve,n[146]=se,n[147]=Se,n[148]=Nt,n[149]=ke,n[150]=Gt):Gt=n[150],n[151]!==Mt||n[152]!==Ft||n[153]!==Gt?(Kt=(0,v.jsxs)(t.View,{style:Y.root,testID:"reels-screen",children:[Mt,Ft,Gt]}),n[151]=Mt,n[152]=Ft,n[153]=Gt,n[154]=Kt):Kt=n[154],Kt}),Y=p.StyleSheet.create(e=>({composerLabel:{color:e.colors.foregroundMuted,fontSize:e.fontSize.xs,paddingHorizontal:e.spacing[2],paddingTop:e.spacing[1],uni__dependencies:[0]},sheetInner:{flex:1},tagChip:{minHeight:44,justifyContent:"center",borderWidth:1,borderColor:e.colors.border,borderRadius:e.borderRadius.full,paddingHorizontal:e.spacing[2],uni__dependencies:[0]},tagChipOn:{borderColor:e.colors.accent,uni__dependencies:[0]},tagChipText:{color:e.colors.foreground,fontSize:e.fontSize.xs,uni__dependencies:[0]},sheetGrab:{minHeight:44,alignItems:"center",justifyContent:"center"},sheetHandle:{width:38,height:4,borderRadius:e.borderRadius.full,backgroundColor:e.colors.border,uni__dependencies:[0]},verbFill:{position:"absolute",left:0,top:0,bottom:0,backgroundColor:e.colors.destructive,opacity:.18,borderRadius:e.borderRadius.full,uni__dependencies:[0]},sendError:{color:e.colors.destructive,fontSize:e.fontSize.xs,paddingHorizontal:e.spacing[2],uni__dependencies:[0]},verbHoldLabel:{color:e.colors.destructive,fontSize:e.fontSize.xs,uni__dependencies:[0]},captionBackdrop:Object.assign({},p.StyleSheet.absoluteFillObject,{backgroundColor:e.colors.background,opacity:.72,uni__dependencies:[0]}),sheetClose:{minWidth:44,minHeight:44,alignItems:"center",justifyContent:"center"},sheetCloseGlyph:{color:e.colors.foregroundMuted,fontSize:e.fontSize.base,uni__dependencies:[0]},card:{flex:1},seamBanner:{paddingHorizontal:e.spacing[2],uni__dependencies:[0]},headerSlot:{position:"absolute",top:0,left:0,right:0},captionTap:{minHeight:44,justifyContent:"flex-end"},root:{flex:1,backgroundColor:e.colors.background,uni__dependencies:[0]},background:Object.assign({},p.StyleSheet.absoluteFillObject,{opacity:.35,backgroundColor:e.colors.surface0,uni__dependencies:[0]}),backgroundText:{padding:e.spacing[2],uni__dependencies:[0]},backgroundBody:{color:e.colors.foregroundMuted,fontSize:e.fontSize.xs,lineHeight:20,uni__dependencies:[0]},middle:{flex:1,alignItems:"flex-end",justifyContent:"flex-end",paddingHorizontal:e.spacing[2],uni__dependencies:[0]},bottom:{padding:e.spacing[2],gap:e.spacing[1],uni__dependencies:[0]},cardTitle:{color:e.colors.foreground,fontSize:e.fontSize.base,fontWeight:"600",uni__dependencies:[0]},cardMeta:{color:e.colors.foregroundMuted,fontSize:e.fontSize.xs,marginTop:2,uni__dependencies:[0]},cardSummary:{color:e.colors.foreground,fontSize:e.fontSize.sm,marginTop:6,lineHeight:19,uni__dependencies:[0]},cardTapHint:{color:e.colors.foregroundMuted,fontSize:e.fontSize.xs,marginTop:4,uni__dependencies:[0]},hint:{color:e.colors.foregroundMuted,fontSize:e.fontSize.xs,lineHeight:17,uni__dependencies:[0]},rowGap:{flexDirection:"row",flexWrap:"wrap",gap:e.spacing[1],alignItems:"center",uni__dependencies:[0]},verbChip:{minHeight:44,minWidth:44,alignItems:"center",justifyContent:"center",overflow:"hidden",borderWidth:1,borderColor:e.colors.border,borderRadius:e.borderRadius["2xl"],paddingHorizontal:e.spacing[2],paddingVertical:e.spacing[1],uni__dependencies:[0]},verbGlyph:{fontSize:20},overlay:Object.assign({},p.StyleSheet.absoluteFillObject,{backgroundColor:e.colors.background,uni__dependencies:[0]}),sheet:{padding:e.spacing[2],gap:e.spacing[1],uni__dependencies:[0]},sheetTitle:{color:e.colors.foreground,fontSize:e.fontSize.base,fontWeight:"600",uni__dependencies:[0]},captionSheet:{position:"absolute",left:0,right:0,bottom:0,top:"42%",backgroundColor:e.colors.background,borderTopWidth:1,borderTopColor:e.colors.border,borderTopLeftRadius:e.borderRadius["2xl"],borderTopRightRadius:e.borderRadius["2xl"],uni__dependencies:[0]},sheetHead:{flexDirection:"row",justifyContent:"space-between",alignItems:"center",padding:e.spacing[2],borderBottomWidth:1,borderBottomColor:e.colors.border,uni__dependencies:[0]},sheetBody:{flex:1,padding:e.spacing[2],uni__dependencies:[0]},field:{marginBottom:e.spacing[1],uni__dependencies:[0]},fieldLabel:{color:e.colors.foregroundMuted,fontSize:e.fontSize.xs,textTransform:"uppercase",letterSpacing:.6,marginTop:e.spacing[1],uni__dependencies:[0]},fieldValue:{color:e.colors.foreground,fontSize:e.fontSize.xs,lineHeight:18,uni__dependencies:[0]},fieldDanger:{color:e.colors.destructive,uni__dependencies:[0]},composer:{flexDirection:"row",alignItems:"center",gap:e.spacing[1],padding:e.spacing[2],borderTopWidth:1,borderTopColor:e.colors.border,uni__dependencies:[0]},composerInput:{flex:1,borderWidth:1,borderColor:e.colors.border,borderRadius:e.borderRadius.full,paddingHorizontal:e.spacing[2],paddingVertical:e.spacing[1],color:e.colors.foreground,fontSize:e.fontSize.xs,uni__dependencies:[0]},composerSend:{minHeight:44,justifyContent:"center",paddingHorizontal:e.spacing[1],uni__dependencies:[0]},link:{color:e.colors.accent,fontSize:e.fontSize.xs,uni__dependencies:[0]},send:{borderWidth:1,borderColor:e.colors.accent,borderRadius:e.borderRadius["2xl"],paddingHorizontal:e.spacing[2],paddingVertical:e.spacing[1],alignSelf:"flex-start",uni__dependencies:[0]},dim:{opacity:.35},pickList:{maxHeight:400},pickRow:{minHeight:44,flexDirection:"row",alignItems:"center",gap:e.spacing[1],paddingVertical:e.spacing[1],paddingHorizontal:e.spacing[1],borderWidth:1,borderColor:e.colors.border,borderRadius:e.borderRadius["2xl"],marginBottom:4,uni__dependencies:[0]},pickRowOn:{borderColor:e.colors.accent,uni__dependencies:[0]},pickMark:{color:e.colors.accent,fontSize:e.fontSize.sm,width:22,uni__dependencies:[0]},pickName:{color:e.colors.foreground,fontSize:e.fontSize.xs,fontWeight:"600",uni__dependencies:[0]},pickAux:{color:e.colors.foregroundMuted,fontSize:e.fontSize.xs,uni__dependencies:[0]},grow:{flex:1},empty:{flex:1,alignItems:"center",justifyContent:"center",padding:e.spacing[3],uni__dependencies:[0]},seamHint:{position:"absolute",bottom:0,left:0,right:0,opacity:.5}})),J=[{id:"whatsapp",label:"WhatsApp"},{id:"slack",label:"Slack"},{id:"copy",label:"Email"}],Q=400;function X(e){const t=[`${e.title} (${R(String(e.statusBucket))})`,e.digest?.summary??e.digest?.goal??"",e.digest?.nextStep?`Next: ${e.digest.nextStep}`:"",e.digest?.blockers?.length?`Blocked: ${e.digest.blockers.join("; ")}`:""].filter(e=>e.length>0).join("\n");return t.length>Q?`${t.slice(0,399)}\u2026`:t}const Z=[Y.fieldValue,Y.fieldDanger],ee=[Y.pickRow,Y.pickRowOn],te=[Y.tagChip,Y.tagChipOn],ne={selected:!0},se={selected:!1},oe=e=>e?ne:se,le=[Y.send,Y.dim],ie=[Y.background,Y.backgroundText],re={read:"caption",snooze:"snooze",share:"share",taco:"taco",options:"options"},ce={consolidate:"consolidate",outsource:"share",automate:"automate"},ae=[{id:"hourly",label:"Every hour",everyMs:36e5},{id:"daily",label:"Every day",everyMs:864e5},{id:"weekly",label:"Every week",everyMs:6048e5}];function de(e,t){return t.dy>8}function ue(e){return`${e.kind}: ${e.label??e.url}`}function he(e,t){return(t.lastActivityAt?.getTime()??0)-(e.lastActivityAt?.getTime()??0)}function pe(e){return e.id}function be(){return Date.now()}function ge(e){return e.session}function ye(e){return{id:e.id,question:e.question}}function me(e){return e+1}function xe(e){return e+1}function fe(e){return e.session}},4566,[348,2838,349,2815,2476,4567,350,36,591,659,649,25,546,182,234,571,146,558,56,4013,4016,4568,4014,4569,4570,4571,4572,4017,279]);
|
|
16324
|
+
__d(function(g,r,i,a,m,e,d){"use strict";Object.defineProperty(e,'__esModule',{value:!0}),Object.defineProperty(e,"default",{enumerable:!0,get:function(){return f}});var t=r(d[0]);r(d[1]);var s=r(d[2]),n=r(d[3]),o=r(d[4]),l=r(d[5]),c=r(d[6]),u=r(d[7]);function f(){const f=(0,t.c)(13),{serverId:S}=(0,s.useLocalSearchParams)();let p;f[0]!==S?(p=t=>t.sessions[S??""]?.agents,f[0]=S,f[1]=p):p=f[1];const k=(0,l.useSessionStore)(p);let _;e:{if(!k){let t;f[2]===Symbol.for("react.memo_cache_sentinel")?(t=[],f[2]=t):t=f[2],_=t;break e}let t;if(f[3]!==k||f[4]!==S){let s;f[6]!==S?(s=t=>({id:t.id,serverId:S??"",title:t.title??t.id,statusBucket:(0,c.deriveSidebarStateBucket)((0,c.toBucketInput)(t)),tags:Object.entries(t.labels??{}).filter(v).map(b),digest:t.digest??null,kanban:t.labels?.kanban??null,provider:t.provider,model:t.model,lastActivityAt:t.lastActivityAt??null,snoozeCount:t.snooze?.count??0,snoozedUntil:t.snooze?.until??null}),f[6]=S,f[7]=s):s=f[7],t=(0,o.selectFeedCandidates)([...k.values()]).map(s),f[3]=k,f[4]=S,f[5]=t}else t=f[5];_=t}const y=_;let j;if(f[8]!==y){const t=new Set;for(const s of y)for(const n of s.tags)t.add(n);j=[...t].sort(),f[8]=y,f[9]=j}else j=f[9];const z=j;let A;return f[10]!==z||f[11]!==y?(A=(0,u.jsx)(n.ReelsScreen,{sessions:y,allTags:z}),f[10]=z,f[11]=y,f[12]=A):A=f[12],A}function b(t){const[s]=t;return s.slice(4)}function v(t){const[s]=t;return s.startsWith("tag:")}},4565,[350,36,379,4566,4573,3427,3441,279]);
|
|
16325
|
+
__d(function(g,r,_i,_a,m,_e,_d){"use strict";function e(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(_e,'__esModule',{value:!0}),Object.defineProperty(_e,"UNWIRED_VERBS",{enumerable:!0,get:function(){return z}}),_e.bucketLabel=R,_e.relativeAge=P,_e.cardMetaLine=L,Object.defineProperty(_e,"ReelsScreen",{enumerable:!0,get:function(){return U}}),_e.shareTextFor=X;var t=r(_d[0]),n=r(_d[1]),s=r(_d[2]),o=r(_d[3]),l=r(_d[4]),i=r(_d[5]),c=r(_d[6]),a=r(_d[7]),d=e(r(_d[8]));r(_d[9]);var u=e(r(_d[10]));r(_d[11]),r(_d[12]),r(_d[13]),r(_d[14]),r(_d[15]),r(_d[16]);var h=r(_d[17]),p=r(_d[18]),b=r(_d[19]),y=r(_d[20]),x=r(_d[21]),f=r(_d[22]),j=r(_d[23]),S=r(_d[24]),_=r(_d[25]),k=r(_d[26]),v=r(_d[27]),T=r(_d[28]);function w(e,t,n){return t&&"hold"!==t?t:e||"hold"===t?"hold to retire, this cannot be undone":n}function C(e,t){return"terminate"===e?`${t}. Hold to confirm, this cannot be undone.`:z.has(e)?`${t}. Not wired yet.`:t}const I={share:null,automate:null},z=new Set([]);function V(e){return e.key}const D={needs_input:"needs you",failed:"failed",attention:"wants a look",pending:"waiting",running:"running",done:"done"};function R(e){return D[e]??e.replace(/_/g," ")}function P(e,t=new Date){if(!e)return"";const n=t.getTime()-e.getTime();if(!Number.isFinite(n)||n<0)return"";const s=Math.floor(n/6e4);if(s<1)return"just now";if(s<60)return`${s}m`;const o=Math.floor(s/60);return o<24?`${o}h`:`${Math.floor(o/24)}d`}function L(e){return[R(String(e.statusBucket)),P(e.lastActivityAt),e.model?`${e.provider}/${e.model}`:e.provider].filter(e=>e.length>0).join(" \xb7 ")}const A=(0,a.memo)(function(e){const p=(0,c.c)(97),{session:b,visible:y,onClose:x,onSend:f,sendError:j,openDecisions:S}=e,[_,k]=(0,a.useState)(""),v=S[0]?.question??null,w=b.digest;let C;p[0]!==f||p[1]!==_?(C=()=>{const e=_.trim();e.length>0&&(f(e),k(""))},p[0]=f,p[1]=_,p[2]=C):C=p[2];const I=C,z=(0,h.useSafeAreaInsets)(),V=Y.captionSheet,[D,R]=(0,a.useState)(!1);let P,L;p[3]===Symbol.for("react.memo_cache_sentinel")?(P=()=>{const e=d.default.addListener("keyboardDidShow",()=>R(!0)),t=d.default.addListener("keyboardDidHide",()=>R(!1));return()=>{e.remove(),t.remove()}},L=[],p[3]=P,p[4]=L):(P=p[3],L=p[4]),(0,a.useEffect)(P,L);const A=D&&!1?0:z.bottom;let $;p[5]!==A?($=[Y.sheetInner,{paddingBottom:A}],p[5]=A,p[6]=$):$=p[6];const E=$;let O;p[7]!==x?(O=u.default.create({onMoveShouldSetPanResponder:de,onPanResponderRelease:(e,t)=>{t.dy>60&&x()}}),p[7]=x,p[8]=O):O=p[8];const M=O;let B,W,F;p[9]!==x||p[10]!==y?(B=()=>{if(!y||"undefined"==typeof document)return;const e=e=>{"Escape"===e.key&&x()};return document.addEventListener("keydown",e),()=>document.removeEventListener("keydown",e)},W=[x,y],p[9]=x,p[10]=y,p[11]=B,p[12]=W):(B=p[11],W=p[12]),(0,a.useEffect)(B,W),p[13]!==v||p[14]!==S.length?(F=v?(0,T.jsx)(s.Text,{style:Y.composerLabel,numberOfLines:2,testID:"reels-composer-target",children:S.length>1?`Answering the first of ${S.length} open decisions: ${v}`:`Answering: ${v}`}):null,p[13]=v,p[14]=S.length,p[15]=F):F=p[15];const N=v?"in your own words":"say what to do";let G,K,q,U,J;p[16]!==I||p[17]!==N||p[18]!==_?(G=(0,T.jsx)(n.TextInput,{value:_,onChangeText:k,placeholder:N,style:Y.composerInput,onSubmitEditing:I,returnKeyType:"send",testID:"reels-composer-input"}),p[16]=I,p[17]=N,p[18]=_,p[19]=G):G=p[19],p[20]===Symbol.for("react.memo_cache_sentinel")?(K=(0,T.jsx)(s.Text,{style:Y.link,children:"send"}),p[20]=K):K=p[20],p[21]!==I?(q=(0,T.jsx)(l.Pressable,{onPress:I,style:Y.composerSend,accessibilityRole:"button",accessibilityLabel:"Send this answer",hitSlop:8,testID:"reels-composer-send",children:K}),p[21]=I,p[22]=q):q=p[22],p[23]!==G||p[24]!==q?(U=(0,T.jsxs)(t.View,{style:Y.composer,children:[G,q]}),p[23]=G,p[24]=q,p[25]=U):U=p[25],p[26]!==U||p[27]!==F?(J=(0,T.jsxs)(t.View,{children:[F,U]}),p[26]=U,p[27]=F,p[28]=J):J=p[28];const Q=J;if(!y)return null;let X,Z,ee,te,ne,se,oe;p[29]!==x?(X=(0,T.jsx)(l.Pressable,{style:Y.captionBackdrop,onPress:x,accessibilityRole:"button",accessibilityLabel:"Close the digest",testID:"reels-caption-backdrop"}),p[29]=x,p[30]=X):X=p[30],p[31]===Symbol.for("react.memo_cache_sentinel")?(Z=(0,T.jsx)(t.View,{style:Y.sheetHandle}),p[31]=Z):Z=p[31],p[32]!==M.panHandlers?(ee=(0,T.jsx)(t.View,Object.assign({},M.panHandlers,{style:Y.sheetGrab,testID:"reels-caption-grab",children:Z})),p[32]=M.panHandlers,p[33]=ee):ee=p[33],p[34]!==b.title?(te=(0,T.jsx)(s.Text,{style:Y.sheetTitle,numberOfLines:1,children:b.title}),p[34]=b.title,p[35]=te):te=p[35],p[36]===Symbol.for("react.memo_cache_sentinel")?(ne=(0,T.jsx)(s.Text,{style:Y.sheetCloseGlyph,children:"\u2715"}),p[36]=ne):ne=p[36],p[37]!==x?(se=(0,T.jsx)(l.Pressable,{onPress:x,style:Y.sheetClose,hitSlop:8,accessibilityRole:"button",accessibilityLabel:"Close the digest",testID:"reels-caption-close",children:ne}),p[37]=x,p[38]=se):se=p[38],p[39]!==te||p[40]!==se?(oe=(0,T.jsxs)(t.View,{style:Y.sheetHead,children:[te,se]}),p[39]=te,p[40]=se,p[41]=oe):oe=p[41];const le=w?.summary;let ie;p[42]!==le?(ie=(0,T.jsx)(H,{label:"Summary",value:le,derived:!0}),p[42]=le,p[43]=ie):ie=p[43];const re=w?.goal;let ce;p[44]!==re?(ce=(0,T.jsx)(H,{label:"Goal",value:re}),p[44]=re,p[45]=ce):ce=p[45];const ae=w?.nextStep;let he,pe,be,ge,ye,me,xe,fe,je,Se,ke,ve;if(p[46]!==ae?(he=(0,T.jsx)(H,{label:"Next step",value:ae}),p[46]=ae,p[47]=he):he=p[47],p[48]!==w?.blockers?(pe=w?.blockers?.join("\n"),p[48]=w?.blockers,p[49]=pe):pe=p[49],p[50]!==pe?(be=(0,T.jsx)(H,{label:"Blockers",value:pe,danger:!0}),p[50]=pe,p[51]=be):be=p[51],p[52]!==w?.accomplishments?(ge=w?.accomplishments?.join("\n"),p[52]=w?.accomplishments,p[53]=ge):ge=p[53],p[54]!==ge?(ye=(0,T.jsx)(H,{label:"Accomplishments",value:ge,derived:!0}),p[54]=ge,p[55]=ye):ye=p[55],p[56]!==w?.keyFiles?(me=w?.keyFiles?.join("\n"),p[56]=w?.keyFiles,p[57]=me):me=p[57],p[58]!==me?(xe=(0,T.jsx)(H,{label:"Key files",value:me,derived:!0}),p[58]=me,p[59]=xe):xe=p[59],p[60]!==w?.links?(fe=w?.links?.map(ue).join("\n"),p[60]=w?.links,p[61]=fe):fe=p[61],p[62]!==fe?(je=(0,T.jsx)(H,{label:"Links",value:fe}),p[62]=fe,p[63]=je):je=p[63],p[64]!==S){let e;p[66]!==S.length?(e=(e,t)=>(0,T.jsx)(H,{label:S.length>1?`Decision ${t+1} of ${S.length}`:"Decision",value:e.question},e.id),p[66]=S.length,p[67]=e):e=p[67],Se=S.map(e),p[64]=S,p[65]=Se}else Se=p[65];p[68]!==b.tags?(ke=b.tags.join(", ")||"no tag",p[68]=b.tags,p[69]=ke):ke=p[69],p[70]!==ke?(ve=(0,T.jsx)(H,{label:"Tags",value:ke}),p[70]=ke,p[71]=ve):ve=p[71];const Te=b.kanban??"inbox";let we,Ce,Ie,ze,Ve;return p[72]!==Te?(we=(0,T.jsx)(H,{label:"Kanban",value:Te}),p[72]=Te,p[73]=we):we=p[73],p[74]!==ie||p[75]!==ce||p[76]!==he||p[77]!==be||p[78]!==ye||p[79]!==xe||p[80]!==je||p[81]!==Se||p[82]!==ve||p[83]!==we?(Ce=(0,T.jsxs)(o.ScrollView,{style:Y.sheetBody,testID:"reels-caption-body",children:[ie,ce,he,be,ye,xe,je,Se,ve,we]}),p[74]=ie,p[75]=ce,p[76]=he,p[77]=be,p[78]=ye,p[79]=xe,p[80]=je,p[81]=Se,p[82]=ve,p[83]=we,p[84]=Ce):Ce=p[84],p[85]!==j?(Ie=j?(0,T.jsxs)(s.Text,{style:Y.sendError,testID:"reels-composer-error",children:["Could not send that: ",j,". Nothing was recorded, so try again."]}):null,p[85]=j,p[86]=Ie):Ie=p[86],p[87]!==Q||p[88]!==E||p[89]!==ee||p[90]!==oe||p[91]!==Ce||p[92]!==Ie?(ze=(0,T.jsx)(i.KeyboardAvoidingView,{behavior:"height",style:V,testID:"reels-caption-sheet",children:(0,T.jsxs)(t.View,{style:E,children:[ee,oe,Ce,Ie,Q]})}),p[87]=Q,p[88]=E,p[89]=ee,p[90]=oe,p[91]=Ce,p[92]=Ie,p[93]=ze):ze=p[93],p[94]!==X||p[95]!==ze?(Ve=(0,T.jsxs)(T.Fragment,{children:[X,ze]}),p[94]=X,p[95]=ze,p[96]=Ve):Ve=p[96],Ve}),H=(0,a.memo)(function(e){const n=(0,c.c)(9),{label:o,value:l,derived:i,danger:a}=e;if(!l)return null;const d=i?" (derived)":"";let u;n[0]!==o||n[1]!==d?(u=(0,T.jsxs)(s.Text,{style:Y.fieldLabel,children:[o,d]}),n[0]=o,n[1]=d,n[2]=u):u=n[2];const h=a?Z:Y.fieldValue;let p,b;return n[3]!==h||n[4]!==l?(p=(0,T.jsx)(s.Text,{style:h,children:l}),n[3]=h,n[4]=l,n[5]=p):p=n[5],n[6]!==u||n[7]!==p?(b=(0,T.jsxs)(t.View,{style:Y.field,children:[u,p]}),n[6]=u,n[7]=p,n[8]=b):b=n[8],b}),$=(0,a.memo)(function(e){const t=(0,c.c)(23),{session:n,picked:o,isWinner:i,onToggle:a,onCrown:d}=e;let u;t[0]!==a||t[1]!==n.id?(u=()=>a(n.id),t[0]=a,t[1]=n.id,t[2]=u):u=t[2];const h=u;let p;t[3]!==d||t[4]!==n.id?(p=()=>d(n.id),t[3]=d,t[4]=n.id,t[5]=p):p=t[5];const b=p;let y="\u2610";o&&(y=i?"\u25c9":"\u2611");const x=o?ee:Y.pickRow,f=`reels-consolidate-pick-${n.id}`;let j,S,_;t[6]!==y?(j=(0,T.jsx)(s.Text,{style:Y.pickMark,children:y}),t[6]=y,t[7]=j):j=t[7],t[8]!==n.title?(S=(0,T.jsx)(s.Text,{style:Y.pickName,children:n.title}),t[8]=n.title,t[9]=S):S=t[9],t[10]!==n.lastActivityAt?(_=P(n.lastActivityAt),t[10]=n.lastActivityAt,t[11]=_):_=t[11];const k=i&&o?" \xb7 survives":"";let v,w;return t[12]!==_||t[13]!==k?(v=(0,T.jsxs)(s.Text,{style:Y.pickAux,children:[_,k]}),t[12]=_,t[13]=k,t[14]=v):v=t[14],t[15]!==b||t[16]!==x||t[17]!==f||t[18]!==j||t[19]!==S||t[20]!==v||t[21]!==h?(w=(0,T.jsxs)(l.Pressable,{onPress:h,onLongPress:b,style:x,testID:f,children:[j,S,v]}),t[15]=b,t[16]=x,t[17]=f,t[18]=j,t[19]=S,t[20]=v,t[21]=h,t[22]=w):w=t[22],w}),E=(0,a.memo)(function(e){const n=(0,c.c)(46),{candidates:i,onCancel:d,onConsolidate:u}=e;let h;n[0]===Symbol.for("react.memo_cache_sentinel")?(h={},n[0]=h):h=n[0];const[p,b]=(0,a.useState)(h);let y;if(n[1]!==i||n[2]!==p){let e;n[4]!==p?(e=e=>p[e.id],n[4]=p,n[5]=e):e=n[5],y=i.filter(e),n[1]=i,n[2]=p,n[3]=y}else y=n[3];const x=y,[f,j]=(0,a.useState)(null);let S;n[6]!==x||n[7]!==f?(S=f??x.slice().sort(he)[0]?.id??null,n[6]=x,n[7]=f,n[8]=S):S=n[8];const _=S;let k;n[9]===Symbol.for("react.memo_cache_sentinel")?(k=e=>{b(t=>{const n=Object.assign({},t);return n[e]?delete n[e]:n[e]=!0,n})},n[9]=k):k=n[9];const v=k;let w;if(n[10]!==x||n[11]!==_){let e;n[13]!==_?(e=e=>e.id!==_,n[13]=_,n[14]=e):e=n[14],w=x.filter(e).map(pe),n[10]=x,n[11]=_,n[12]=w}else w=n[12];const C=w,I=x.length>=2&&null!==_;let z;n[15]!==u||n[16]!==C||n[17]!==_?(z=()=>{_&&u(_,C)},n[15]=u,n[16]=C,n[17]=_,n[18]=z):z=n[18];const V=z;let D,R,P,L,A,H;if(n[19]===Symbol.for("react.memo_cache_sentinel")?(D=(0,T.jsx)(s.Text,{style:Y.sheetTitle,children:"Consolidate"}),R=(0,T.jsx)(s.Text,{style:Y.hint,children:"The winner keeps its transcript. The others are archived and linked to it, both ways. Nothing is deleted."}),n[19]=D,n[20]=R):(D=n[19],R=n[20]),n[21]!==i||n[22]!==p||n[23]!==_){let e;n[25]!==p||n[26]!==_?(e=e=>(0,T.jsx)($,{session:e,picked:Boolean(p[e.id]),isWinner:_===e.id,onToggle:v,onCrown:j},e.id),n[25]=p,n[26]=_,n[27]=e):e=n[27],P=i.map(e),n[21]=i,n[22]=p,n[23]=_,n[24]=P}else P=n[24];n[28]!==P?(L=(0,T.jsx)(o.ScrollView,{style:Y.pickList,children:P}),n[28]=P,n[29]=L):L=n[29],n[30]===Symbol.for("react.memo_cache_sentinel")?(A=(0,T.jsx)(s.Text,{style:Y.link,children:"cancel"}),n[30]=A):A=n[30],n[31]!==d?(H=(0,T.jsx)(l.Pressable,{onPress:d,style:Y.send,testID:"reels-consolidate-cancel",children:A}),n[31]=d,n[32]=H):H=n[32];const E=!I,O=I?Y.send:le;let M,B,W,F;return n[33]!==C.length?(M=(0,T.jsxs)(s.Text,{style:Y.link,children:["consolidate ",C.length]}),n[33]=C.length,n[34]=M):M=n[34],n[35]!==V||n[36]!==E||n[37]!==O||n[38]!==M?(B=(0,T.jsx)(l.Pressable,{onPress:V,disabled:E,style:O,testID:"reels-consolidate-commit",children:M}),n[35]=V,n[36]=E,n[37]=O,n[38]=M,n[39]=B):B=n[39],n[40]!==H||n[41]!==B?(W=(0,T.jsxs)(t.View,{style:Y.rowGap,children:[H,B]}),n[40]=H,n[41]=B,n[42]=W):W=n[42],n[43]!==L||n[44]!==W?(F=(0,T.jsxs)(t.View,{style:Y.sheet,testID:"reels-consolidate",children:[D,R,L,W]}),n[43]=L,n[44]=W,n[45]=F):F=n[45],F}),O=(0,a.memo)(function(e){const n=(0,c.c)(29),{verb:o,glyph:i,label:a,onVerb:d}=e,u="terminate"===o,{showLabel:h,progress:p,hint:b,handlers:y}=(0,j.useDestructiveHold)(d,o);let x;n[0]!==d||n[1]!==o?(x=()=>d(o),n[0]=d,n[1]=o,n[2]=x):x=n[2];const f=x,S=z.has(o);let _;n[3]!==p?(_=Math.round(100*p),n[3]=p,n[4]=_):_=n[4];const k=`${_}%`;let v;n[5]!==k?(v=[Y.verbFill,{width:k}],n[5]=k,n[6]=v):v=n[6];const C=v;if(!u){const e=S?`${a}. Not wired yet.`:a,t=`reels-verb-${o}`;let c,d;return n[7]!==i?(c=(0,T.jsx)(s.Text,{style:Y.verbGlyph,children:i}),n[7]=i,n[8]=c):c=n[8],n[9]!==e||n[10]!==t||n[11]!==c||n[12]!==f?(d=(0,T.jsx)(l.Pressable,{onPress:f,style:Y.verbChip,accessibilityRole:"button",accessibilityLabel:e,hitSlop:8,testID:t,children:c}),n[9]=e,n[10]=t,n[11]=c,n[12]=f,n[13]=d):d=n[13],d}const I=`${a}. Hold to confirm, this cannot be undone.`,V=`reels-verb-${o}`;let D,R,P,L;return n[14]!==C||n[15]!==p?(D=p>0?(0,T.jsx)(t.View,{style:C,testID:"reels-verb-hold-fill"}):null,n[14]=C,n[15]=p,n[16]=D):D=n[16],n[17]!==i?(R=(0,T.jsx)(s.Text,{style:Y.verbGlyph,children:i}),n[17]=i,n[18]=R):R=n[18],n[19]!==b||n[20]!==h?(P=h||b?(0,T.jsx)(s.Text,{style:Y.verbHoldLabel,testID:"reels-verb-terminate-hold",children:w(h,b,"hold to retire")}):null,n[19]=b,n[20]=h,n[21]=P):P=n[21],n[22]!==y||n[23]!==I||n[24]!==V||n[25]!==D||n[26]!==R||n[27]!==P?(L=(0,T.jsxs)(l.Pressable,Object.assign({},y,{style:Y.verbChip,accessibilityRole:"button",accessibilityLabel:I,hitSlop:8,testID:V,children:[D,R,P]})),n[22]=y,n[23]=I,n[24]=V,n[25]=D,n[26]=R,n[27]=P,n[28]=L):L=n[28],L}),M=(0,a.memo)(function(e){const t=(0,c.c)(10),{everyMs:n,label:o,onPick:i}=e;let a;t[0]!==n||t[1]!==i?(a=()=>i(n),t[0]=n,t[1]=i,t[2]=a):a=t[2];const d=a,u=`reels-automate-${n}`;let h,p;return t[3]!==o?(h=(0,T.jsx)(s.Text,{style:Y.pickName,children:o}),t[3]=o,t[4]=h):h=t[4],t[5]!==o||t[6]!==d||t[7]!==u||t[8]!==h?(p=(0,T.jsx)(l.Pressable,{onPress:d,style:Y.pickRow,accessibilityRole:"button",accessibilityLabel:o,testID:u,children:h}),t[5]=o,t[6]=d,t[7]=u,t[8]=h,t[9]=p):p=t[9],p}),B=["needs_input","failed","attention","pending","running","done"],W=(0,a.memo)(function(e){const t=(0,c.c)(14),{value:n,label:o,active:i,onCycle:a}=e;let d;t[0]!==a||t[1]!==n?(d=()=>a(n),t[0]=a,t[1]=n,t[2]=d):d=t[2];const u=d,h=i?te:Y.tagChip;let p;t[3]!==i?(p=oe(i),t[3]=i,t[4]=p):p=t[4];const b=`reels-filter-${n}`;let y,x;return t[5]!==o?(y=(0,T.jsx)(s.Text,{style:Y.tagChipText,children:o}),t[5]=o,t[6]=y):y=t[6],t[7]!==o||t[8]!==u||t[9]!==h||t[10]!==p||t[11]!==b||t[12]!==y?(x=(0,T.jsx)(l.Pressable,{onPress:u,style:h,accessibilityRole:"button",accessibilityState:p,accessibilityLabel:o,testID:b,children:y}),t[7]=o,t[8]=u,t[9]=h,t[10]=p,t[11]=b,t[12]=y,t[13]=x):x=t[13],x}),F=(0,a.memo)(function(e){const t=(0,c.c)(10),{target:n,label:o,onShare:i}=e;let a;t[0]!==i||t[1]!==n?(a=()=>i(n),t[0]=i,t[1]=n,t[2]=a):a=t[2];const d=a,u=`Send to ${o}`,h=`reels-share-${n}`;let p,b;return t[3]!==o?(p=(0,T.jsx)(s.Text,{style:Y.pickName,children:o}),t[3]=o,t[4]=p):p=t[4],t[5]!==d||t[6]!==u||t[7]!==h||t[8]!==p?(b=(0,T.jsx)(l.Pressable,{onPress:d,style:Y.pickRow,accessibilityRole:"button",accessibilityLabel:u,testID:h,children:p}),t[5]=d,t[6]=u,t[7]=h,t[8]=p,t[9]=b):b=t[9],b}),N=(0,a.memo)(function(e){const n=(0,c.c)(42),{verb:o,glyph:i,label:a,detail:d,onVerb:u}=e,h="terminate"===o,{showLabel:p,progress:b,hint:y,handlers:x}=(0,j.useDestructiveHold)(u,o);let f;n[0]!==u||n[1]!==o?(f=()=>u(o),n[0]=u,n[1]=o,n[2]=f):f=n[2];const S=f;let _;n[3]!==b?(_=Math.round(100*b),n[3]=b,n[4]=_):_=n[4];const k=`${_}%`;let v;n[5]!==k?(v=[Y.verbFill,{width:k}],n[5]=k,n[6]=v):v=n[6];const I=v;let V;n[7]!==h||n[8]!==x||n[9]!==S?(V=h?x:{onPress:S},n[7]=h,n[8]=x,n[9]=S,n[10]=V):V=n[10];const D=V;let R;n[11]!==a||n[12]!==o?(R=C(o,a),n[11]=a,n[12]=o,n[13]=R):R=n[13];const P=`reels-taco-${o}`;let L,A,H,$,E,O,M,B;return n[14]!==h||n[15]!==b||n[16]!==I?(L=h&&b>0?(0,T.jsx)(t.View,{style:I,testID:"reels-taco-hold-fill"}):null,n[14]=h,n[15]=b,n[16]=I,n[17]=L):L=n[17],n[18]!==i?(A=(0,T.jsx)(s.Text,{style:Y.pickMark,children:i}),n[18]=i,n[19]=A):A=n[19],n[20]!==a?(H=(0,T.jsx)(s.Text,{style:Y.pickName,children:a}),n[20]=a,n[21]=H):H=n[21],n[22]!==h||n[23]!==d||n[24]!==y||n[25]!==p?($=h?w(p,y,d):d,n[22]=h,n[23]=d,n[24]=y,n[25]=p,n[26]=$):$=n[26],n[27]!==$?(E=(0,T.jsx)(s.Text,{style:Y.hint,children:$}),n[27]=$,n[28]=E):E=n[28],n[29]!==o?(O=z.has(o)?(0,T.jsx)(s.Text,{style:Y.pickAux,children:"not wired yet"}):null,n[29]=o,n[30]=O):O=n[30],n[31]!==H||n[32]!==E||n[33]!==O?(M=(0,T.jsxs)(t.View,{style:Y.grow,children:[H,E,O]}),n[31]=H,n[32]=E,n[33]=O,n[34]=M):M=n[34],n[35]!==D||n[36]!==M||n[37]!==R||n[38]!==P||n[39]!==L||n[40]!==A?(B=(0,T.jsxs)(l.Pressable,Object.assign({},D,{style:Y.pickRow,accessibilityRole:"button",accessibilityLabel:R,testID:P,children:[L,A,M]})),n[35]=D,n[36]=M,n[37]=R,n[38]=P,n[39]=L,n[40]=A,n[41]=B):B=n[41],B}),G=(0,a.memo)(function(e){const n=(0,c.c)(7),{mode:o,text:l}=e;if("off"===o)return null;const i="text"===o?ie:Y.background,a=`reels-background-${o}`;let d,u;return n[0]!==o||n[1]!==l?(d="text"===o?(0,T.jsx)(s.Text,{style:Y.backgroundBody,numberOfLines:40,children:l}):null,n[0]=o,n[1]=l,n[2]=d):d=n[2],n[3]!==i||n[4]!==a||n[5]!==d?(u=(0,T.jsx)(t.View,{style:i,testID:a,children:d}),n[3]=i,n[4]=a,n[5]=d,n[6]=u):u=n[6],u}),K=(0,a.memo)(function(e){const n=(0,c.c)(23),{gated:o,allTags:l,onPickTag:i,decision:a,decisions:d,serverId:u,agentId:h,onAnswered:p,onVerb:x,actAllowed:f,capLabel:j}=e;if(o){let e;return n[0]!==l||n[1]!==i?(e=(0,T.jsx)(y.TagGate,{available:l,onPick:i}),n[0]=l,n[1]=i,n[2]=e):e=n[2],e}if(a){if(!f){let e,o,l,i,c;return n[3]!==j?(e=(0,T.jsx)(s.Text,{style:Y.hint,children:j}),n[3]=j,n[4]=e):e=n[4],n[5]===Symbol.for("react.memo_cache_sentinel")?(o=(0,T.jsx)(s.Text,{style:Y.cardTapHint,children:"Decisions are done for today. You can still retire or snooze this one."}),n[5]=o):o=n[5],n[6]!==x?(l=y.TACO_VERBS.map(e=>(0,T.jsx)(O,{verb:e.id,glyph:e.glyph,label:e.label,onVerb:x},e.id)),n[6]=x,n[7]=l):l=n[7],n[8]!==l?(i=(0,T.jsx)(t.View,{style:Y.rowGap,children:l}),n[8]=l,n[9]=i):i=n[9],n[10]!==e||n[11]!==i?(c=(0,T.jsxs)(t.View,{testID:"reels-cap-reached",children:[e,o,i]}),n[10]=e,n[11]=i,n[12]=c):c=n[12],c}let e;return n[13]!==h||n[14]!==d||n[15]!==p||n[16]!==u?(e=(0,T.jsx)(b.DecisionChips,{serverId:u,agentId:h,decisions:d,onAnswered:p}),n[13]=h,n[14]=d,n[15]=p,n[16]=u,n[17]=e):e=n[17],e}let S,_,k;return n[18]===Symbol.for("react.memo_cache_sentinel")?(S=(0,T.jsx)(s.Text,{style:Y.hint,children:"Nothing to decide. Why is this still open?"}),n[18]=S):S=n[18],n[19]!==x?(_=y.TACO_VERBS.map(e=>(0,T.jsx)(O,{verb:e.id,glyph:e.glyph,label:e.label,onVerb:x},e.id)),n[19]=x,n[20]=_):_=n[20],n[21]!==_?(k=(0,T.jsxs)(t.View,{testID:"reels-taco-row",children:[S,(0,T.jsx)(t.View,{style:Y.rowGap,children:_})]}),n[21]=_,n[22]=k):k=n[22],k}),q=(0,a.memo)(function(e){const n=(0,c.c)(62),{overlay:i,session:a,ring:d,onClose:u,onSend:h,onSnooze:p,onConsolidate:b,onKanban:x,onVerb:f,overlayStyle:j,sendError:S,verbError:_,openDecisions:k,onShare:v,onAutomate:w,allTags:C,statusSelection:I,tagSelection:z,onCycleStatus:V,onCycleTag:D}=e,P=a,L="caption"===i.kind;let H,$,O,G,K,q,U,Q,X;return n[0]!==P||n[1]!==u||n[2]!==h||n[3]!==k||n[4]!==S||n[5]!==L?(H=(0,T.jsx)(A,{session:P,visible:L,onClose:u,onSend:h,sendError:S,openDecisions:k},P.id),n[0]=P,n[1]=u,n[2]=h,n[3]=k,n[4]=S,n[5]=L,n[6]=H):H=n[6],n[7]!==P.snoozeCount||n[8]!==u||n[9]!==p||n[10]!==i.kind||n[11]!==j?($="snooze"===i.kind?(0,T.jsx)(t.View,{style:j,children:(0,T.jsx)(y.SnoozeSheet,{priorCount:P.snoozeCount,onCancel:u,onSnooze:p})}):null,n[7]=P.snoozeCount,n[8]=u,n[9]=p,n[10]=i.kind,n[11]=j,n[12]=$):$=n[12],n[13]!==u||n[14]!==b||n[15]!==i.kind||n[16]!==j||n[17]!==d?(O="consolidate"===i.kind?(0,T.jsx)(t.View,{style:j,children:(0,T.jsx)(E,{candidates:d,onCancel:u,onConsolidate:b})}):null,n[13]=u,n[14]=b,n[15]=i.kind,n[16]=j,n[17]=d,n[18]=O):O=n[18],n[19]!==u||n[20]!==f||n[21]!==i.kind||n[22]!==j?(G="taco"===i.kind?(0,T.jsx)(t.View,{style:j,children:(0,T.jsxs)(t.View,{style:Y.sheet,testID:"reels-taco-sheet",children:[(0,T.jsx)(s.Text,{style:Y.sheetTitle,children:"TACO"}),y.TACO_VERBS.map(e=>(0,T.jsx)(N,{verb:e.id,glyph:e.glyph,label:e.label,detail:e.detail,onVerb:f},e.id)),(0,T.jsx)(l.Pressable,{onPress:u,style:Y.send,children:(0,T.jsx)(s.Text,{style:Y.link,children:"cancel"})})]})}):null,n[19]=u,n[20]=f,n[21]=i.kind,n[22]=j,n[23]=G):G=n[23],n[24]!==C||n[25]!==u||n[26]!==V||n[27]!==D||n[28]!==i.kind||n[29]!==j||n[30]!==I||n[31]!==z?(K="filters"===i.kind?(0,T.jsx)(t.View,{style:j,children:(0,T.jsxs)(o.ScrollView,{style:Y.sheet,testID:"reels-filters-sheet",children:[(0,T.jsx)(s.Text,{style:Y.sheetTitle,children:"Filter the ring"}),(0,T.jsx)(s.Text,{style:Y.hint,children:"The same filter the sessions list uses, so setting it here sets it there."}),(0,T.jsx)(s.Text,{style:Y.fieldLabel,children:"State"}),(0,T.jsx)(t.View,{style:Y.rowGap,children:B.map(e=>(0,T.jsx)(W,{value:e,label:R(e),active:I.include.includes(e),onCycle:V},e))}),(0,T.jsx)(s.Text,{style:Y.fieldLabel,children:"Tag"}),(0,T.jsx)(t.View,{style:Y.rowGap,children:C.map(e=>(0,T.jsx)(W,{value:e,label:e,active:z.include.includes(e),onCycle:D},e))}),(0,T.jsx)(l.Pressable,{onPress:u,style:Y.send,testID:"reels-filters-done",children:(0,T.jsx)(s.Text,{style:Y.link,children:"done"})})]})}):null,n[24]=C,n[25]=u,n[26]=V,n[27]=D,n[28]=i.kind,n[29]=j,n[30]=I,n[31]=z,n[32]=K):K=n[32],n[33]!==w||n[34]!==u||n[35]!==i.kind||n[36]!==j||n[37]!==_?(q="automate"===i.kind?(0,T.jsx)(t.View,{style:j,children:(0,T.jsxs)(t.View,{style:Y.sheet,testID:"reels-automate-sheet",children:[(0,T.jsx)(s.Text,{style:Y.sheetTitle,children:"Automate"}),(0,T.jsx)(s.Text,{style:Y.hint,children:"Re-runs this session on a cadence, with its next step as the prompt."}),_?(0,T.jsx)(s.Text,{style:Y.sendError,testID:"reels-verb-error",children:_}):null,ae.map(e=>(0,T.jsx)(M,{everyMs:e.everyMs,label:e.label,onPick:w},e.id)),(0,T.jsx)(l.Pressable,{onPress:u,style:Y.send,children:(0,T.jsx)(s.Text,{style:Y.link,children:"cancel"})})]})}):null,n[33]=w,n[34]=u,n[35]=i.kind,n[36]=j,n[37]=_,n[38]=q):q=n[38],n[39]!==u||n[40]!==v||n[41]!==i.kind||n[42]!==j||n[43]!==_?(U="share"===i.kind?(0,T.jsx)(t.View,{style:j,children:(0,T.jsxs)(t.View,{style:Y.sheet,testID:"reels-share-sheet",children:[(0,T.jsx)(s.Text,{style:Y.sheetTitle,children:"Send"}),(0,T.jsx)(s.Text,{style:Y.hint,children:"Send this card somewhere a person will read it."}),_?(0,T.jsx)(s.Text,{style:Y.sendError,testID:"reels-verb-error",children:_}):null,J.map(e=>(0,T.jsx)(F,{target:e.id,label:e.label,onShare:v},e.id)),(0,T.jsx)(l.Pressable,{onPress:u,style:Y.send,children:(0,T.jsx)(s.Text,{style:Y.link,children:"cancel"})})]})}):null,n[39]=u,n[40]=v,n[41]=i.kind,n[42]=j,n[43]=_,n[44]=U):U=n[44],n[45]!==P.kanban||n[46]!==P.model||n[47]!==P.provider||n[48]!==u||n[49]!==x||n[50]!==i.kind||n[51]!==j?(Q="options"===i.kind?(0,T.jsx)(t.View,{style:j,children:(0,T.jsxs)(o.ScrollView,{style:Y.sheet,testID:"reels-options-sheet",children:[(0,T.jsx)(s.Text,{style:Y.sheetTitle,children:"Session options"}),(0,T.jsx)(s.Text,{style:Y.fieldLabel,children:"Kanban"}),(0,T.jsx)(y.KanbanPicker,{current:P.kanban,onPick:x}),(0,T.jsx)(s.Text,{style:Y.fieldLabel,children:"Provider and model"}),(0,T.jsx)(s.Text,{style:Y.fieldValue,children:P.model?`${P.provider}/${P.model}`:P.provider}),(0,T.jsx)(s.Text,{style:Y.hint,children:"One control in the app, not two: combined-model-selector with favourites."}),(0,T.jsx)(l.Pressable,{onPress:u,style:Y.send,children:(0,T.jsx)(s.Text,{style:Y.link,children:"close"})})]})}):null,n[45]=P.kanban,n[46]=P.model,n[47]=P.provider,n[48]=u,n[49]=x,n[50]=i.kind,n[51]=j,n[52]=Q):Q=n[52],n[53]!==H||n[54]!==$||n[55]!==O||n[56]!==G||n[57]!==K||n[58]!==q||n[59]!==U||n[60]!==Q?(X=(0,T.jsxs)(T.Fragment,{children:[H,$,O,G,K,q,U,Q]}),n[53]=H,n[54]=$,n[55]=O,n[56]=G,n[57]=K,n[58]=q,n[59]=U,n[60]=Q,n[61]=X):X=n[61],X}),U=(0,a.memo)(function(e){const n=(0,c.c)(155),{sessions:o,allTags:i,actCap:d,background:u,now:p}=e,b=void 0===d?v.DEFAULT_ACT_CAP:d,j=void 0===u?"text":u,w=(0,S.useReelsVerbs)(),{answer:C}=(0,f.useAnswerDecision)(),[z,D]=(0,a.useState)(be);let R,P,A;n[0]!==p?(R=()=>{if(p)return;const e=setInterval(()=>D(Date.now()),6e4);return()=>clearInterval(e)},P=[p],n[0]=p,n[1]=R,n[2]=P):(R=n[1],P=n[2]),(0,a.useEffect)(R,P),n[3]!==p||n[4]!==z?(A=p??new Date(z),n[3]=p,n[4]=z,n[5]=A):A=n[5];const H=A,[$,E]=(0,a.useState)(1),[O,M]=(0,a.useState)(0),[B,W]=(0,a.useState)(0);let F;n[6]===Symbol.for("react.memo_cache_sentinel")?(F={kind:"none"},n[6]=F):F=n[6];const[N,U]=(0,a.useState)(F);let J;n[7]===Symbol.for("react.memo_cache_sentinel")?(J={},n[7]=J):J=n[7];const[Q,Z]=(0,a.useState)(J);let ee;n[8]===Symbol.for("react.memo_cache_sentinel")?(ee={},n[8]=ee):ee=n[8];const[te,ne]=(0,a.useState)(ee),[se,oe]=(0,a.useState)(null),[le,ie]=(0,a.useState)(I);let ae;n[9]===Symbol.for("react.memo_cache_sentinel")?(ae=(e,t)=>{ie(n=>Object.assign({},n,{[e]:t}))},n[9]=ae):ae=n[9];const de=ae,ue=(0,a.useRef)(null);let he;n[10]!==te||n[11]!==$||n[12]!==Q||n[13]!==H||n[14]!==o?(he={sessions:o,localTags:Q,actedLaps:te,laps:$,now:H},n[10]=te,n[11]=$,n[12]=Q,n[13]=H,n[14]=o,n[15]=he):he=n[15];const{feed:pe,activeFilters:je,statusSelection:Se,tagSelection:ke,onCycleStatus:ve,onCycleTag:Te}=(0,_.useReelsFeed)(he),we=pe[Math.min(B,Math.max(pe.length-1,0))]??null,Ce=we?.session??null,Ie=we?.lap??1;let ze;if(n[16]!==pe||n[17]!==Ie){let e;n[19]!==Ie?(e=e=>e.lap===Ie,n[19]=Ie,n[20]=e):e=n[20],ze=pe.filter(e).map(ge),n[16]=pe,n[17]=Ie,n[18]=ze}else ze=n[18];const Ve=ze,De=Ce?.id??"",Re=Ce?.serverId??"";let Pe;var Le;n[21]!==Ce?(Pe=Ce?(Le=Ce.digest,(Le?.pendingDecisions??[]).filter(e=>!e.answeredAt)):[],n[21]=Ce,n[22]=Pe):Pe=n[22];const Ae=Pe,He=Ae[0]??null;let $e;n[23]!==Ae?($e=Ae.map(ye),n[23]=Ae,n[24]=$e):$e=n[24];const Ee=$e,Oe=Ae,Me=!!Ce&&0===Ce.tags.length;let Be;n[25]!==b||n[26]!==O?(Be=(0,v.canAct)({acts:O,cap:b}),n[25]=b,n[26]=O,n[27]=Be):Be=n[27];const We=Be;let Fe;n[28]!==b||n[29]!==O?(Fe=(0,v.actCapLabel)({acts:O,cap:b}),n[28]=b,n[29]=O,n[30]=Fe):Fe=n[30];const Ne=Fe,Ge=(0,h.useSafeAreaInsets)();let Ke;n[31]!==Ge.top?(Ke=[Y.headerSlot,{paddingTop:Ge.top}],n[31]=Ge.top,n[32]=Ke):Ke=n[32];const qe=Ke,Ue=Ge.top+56;let Ye;n[33]!==Ue?(Ye=[Y.seamBanner,{paddingTop:Ue}],n[33]=Ue,n[34]=Ye):Ye=n[34];const Je=Ye;let Qe;n[35]!==Ge.bottom||n[36]!==Ge.top?(Qe=[Y.overlay,{paddingTop:Ge.top,paddingBottom:Ge.bottom}],n[35]=Ge.bottom,n[36]=Ge.top,n[37]=Qe):Qe=n[37];const Xe=Qe;let Ze;n[38]!==B?(Ze=()=>{U({kind:"none"}),ue.current?.scrollToIndex(B+1)},n[38]=B,n[39]=Ze):Ze=n[39];const et=Ze;let tt;n[40]!==Ie?(tt=e=>{ne(t=>Object.assign({},t,{[e]:Ie}))},n[40]=Ie,n[41]=tt):tt=n[41];const nt=tt;let st;n[42]===Symbol.for("react.memo_cache_sentinel")?(st=()=>{E(me)},n[42]=st):st=n[42];const ot=st;let lt,it,rt,ct,at,dt;n[43]===Symbol.for("react.memo_cache_sentinel")?(lt={id:"read",glyph:"\ud83d\udcd6",label:"read"},n[43]=lt):lt=n[43],n[44]!==Me?(it={id:"snooze",glyph:"\ud83d\ude34",label:"snooze",disabled:Me},n[44]=Me,n[45]=it):it=n[45],n[46]===Symbol.for("react.memo_cache_sentinel")?(rt={id:"share",glyph:"\ud83d\udce4",label:"send"},n[46]=rt):rt=n[46],n[47]!==Me?(ct={id:"taco",glyph:"\u2699\ufe0f",label:"TACO",disabled:Me},n[47]=Me,n[48]=ct):ct=n[48],n[49]===Symbol.for("react.memo_cache_sentinel")?(at={id:"options",glyph:"\u22ef",label:"options"},n[49]=at):at=n[49],n[50]!==it||n[51]!==ct?(dt=[lt,it,rt,ct,at],n[50]=it,n[51]=ct,n[52]=dt):dt=n[52];const ut=dt;let ht;n[53]===Symbol.for("react.memo_cache_sentinel")?(ht=()=>U({kind:"caption"}),n[53]=ht):ht=n[53];const pt=ht;let bt;n[54]===Symbol.for("react.memo_cache_sentinel")?(bt=()=>U({kind:"none"}),n[54]=bt):bt=n[54];const gt=bt;let yt;n[55]===Symbol.for("react.memo_cache_sentinel")?(yt=()=>U({kind:"filters"}),n[55]=yt):yt=n[55];const mt=yt;let xt;n[56]===Symbol.for("react.memo_cache_sentinel")?(xt=e=>{ie(I);const t=re[e];t&&U({kind:t})},n[56]=xt):xt=n[56];const ft=xt;let jt;n[57]!==De||n[58]!==Re||n[59]!==w?(jt=e=>{Z(t=>Object.assign({},t,{[De]:[e]})),w.setTags({serverId:Re,agentId:De},[e])},n[57]=De,n[58]=Re,n[59]=w,n[60]=jt):jt=n[60];const St=jt;let _t;n[61]!==et||n[62]!==De||n[63]!==Ae.length||n[64]!==nt?(_t=()=>{M(xe),nt(De),Ae.length<=1&&et()},n[61]=et,n[62]=De,n[63]=Ae.length,n[64]=nt,n[65]=_t):_t=n[65];const kt=_t;let vt;n[66]!==et||n[67]!==De||n[68]!==nt||n[69]!==Re||n[70]!==w?(vt=async e=>{if("terminate"===e)return await w.terminate({serverId:Re,agentId:De}),nt(De),void et();ie(I),U({kind:ce[e]})},n[66]=et,n[67]=De,n[68]=nt,n[69]=Re,n[70]=w,n[71]=vt):vt=n[71];const Tt=vt;let wt;n[72]!==et||n[73]!==De||n[74]!==nt||n[75]!==Re||n[76]!==w?(wt=e=>{w.snooze({serverId:Re,agentId:De},e.until,e.untilWhat,e.why),nt(De),et()},n[72]=et,n[73]=De,n[74]=nt,n[75]=Re,n[76]=w,n[77]=wt):wt=n[77];const Ct=wt;let It;n[78]!==et||n[79]!==nt||n[80]!==Re||n[81]!==w?(It=(e,t)=>{w.consolidate({serverId:Re,winnerId:e,sourceIds:t});for(const n of[e,...t])nt(n);et()},n[78]=et,n[79]=nt,n[80]=Re,n[81]=w,n[82]=It):It=n[82];const zt=It;let Vt;n[83]!==C||n[84]!==De||n[85]!==He||n[86]!==kt||n[87]!==Re?(Vt=e=>{const t=e.trim();0!==t.length&&He?(oe(null),C({serverId:Re,agentId:De,decisionId:He.id,optionId:null,note:t}).then(()=>(kt(),null)).catch(e=>{oe(e instanceof Error?e.message:String(e))})):U({kind:"none"})},n[83]=C,n[84]=De,n[85]=He,n[86]=kt,n[87]=Re,n[88]=Vt):Vt=n[88];const Dt=Vt;let Rt;n[89]!==Ce||n[90]!==w?(Rt=e=>{Ce&&(de("share",null),w.share(e,X(Ce)).then(()=>(U({kind:"none"}),null)).catch(e=>{de("share",e instanceof Error?e.message:"could not open that")}))},n[89]=Ce,n[90]=w,n[91]=Rt):Rt=n[91];const Pt=Rt;let Lt;n[92]!==et||n[93]!==Ce||n[94]!==De||n[95]!==nt||n[96]!==Re||n[97]!==w?(Lt=e=>{if(!Ce)return;de("automate",null);const t=Ce.digest?.nextStep??Ce.digest?.goal??`Continue ${Ce.title}`;w.automate({serverId:Re,agentId:De},e,t,Ce.title).then(()=>(nt(De),et(),null)).catch(e=>{de("automate",e instanceof Error?e.message:"could not create the routine")})},n[92]=et,n[93]=Ce,n[94]=De,n[95]=nt,n[96]=Re,n[97]=w,n[98]=Lt):Lt=n[98];const At=Lt;let Ht;n[99]!==De||n[100]!==Re||n[101]!==w?(Ht=e=>{w.setKanban({serverId:Re,agentId:De},e),U({kind:"none"})},n[99]=De,n[100]=Re,n[101]=w,n[102]=Ht):Ht=n[102];const $t=Ht;let Et;n[103]!==i||n[104]!==We||n[105]!==j||n[106]!==Ne||n[107]!==He||n[108]!==Oe||n[109]!==pe||n[110]!==Me||n[111]!==B||n[112]!==kt||n[113]!==Tt||n[114]!==St||n[115]!==ut||n[116]!==Ve.length||n[117]!==Je?(Et=(e,n)=>{const o=n===B,c=e.session;return(0,T.jsxs)(t.View,{style:Y.card,children:[(0,T.jsx)(G,{mode:j,text:c.digest?.summary??c.title}),e.firstOfLap&&e.lap>1?(0,T.jsx)(t.View,{style:Je,testID:`reels-seam-${e.lap}`,children:(0,T.jsx)(y.LapSeam,{lap:e.lap,ringSize:Ve.length,acted:(0,k.actedThisLap)(pe.filter(t=>t.lap===e.lap-1).map(fe),e.lap-1)})}):null,(0,T.jsx)(t.View,{style:Y.middle,children:o?(0,T.jsx)(y.ReelsRail,{actions:ut,contextLabel:c.tags[0]??"untagged",onAction:ft}):null}),(0,T.jsxs)(t.View,{style:Y.bottom,children:[(0,T.jsxs)(l.Pressable,{onPress:o?pt:void 0,disabled:!o,testID:o?"reels-caption-open":void 0,accessibilityRole:"button",accessibilityLabel:`Open the full digest for ${c.title}`,style:Y.captionTap,children:[(0,T.jsx)(s.Text,{style:Y.cardTitle,children:c.title}),(0,T.jsx)(s.Text,{style:Y.cardMeta,children:L(c)}),(0,T.jsx)(s.Text,{style:Y.cardSummary,numberOfLines:4,children:c.digest?.summary??c.digest?.goal??"No digest yet."}),o?(0,T.jsx)(s.Text,{style:Y.cardTapHint,children:"tap for the whole digest and to talk to it"}):null]}),o?(0,T.jsx)(K,{gated:Me,allTags:i,onPickTag:St,decision:He,decisions:Oe,serverId:c.serverId,agentId:c.id,onAnswered:kt,onVerb:Tt,actAllowed:We,capLabel:Ne}):null]})]})},n[103]=i,n[104]=We,n[105]=j,n[106]=Ne,n[107]=He,n[108]=Oe,n[109]=pe,n[110]=Me,n[111]=B,n[112]=kt,n[113]=Tt,n[114]=St,n[115]=ut,n[116]=Ve.length,n[117]=Je,n[118]=Et):Et=n[118];const Ot=Et;if(!Ce){let e;return n[119]===Symbol.for("react.memo_cache_sentinel")?(e=(0,T.jsx)(t.View,{style:Y.empty,testID:"reels-empty",children:(0,T.jsx)(s.Text,{style:Y.fieldValue,children:"No sessions in the ring."})}),n[119]=e):e=n[119],e}let Mt;n[120]!==pe||n[121]!==Ot?(Mt=(0,T.jsx)(x.ReelsPager,{data:pe,keyExtractor:V,renderCard:Ot,onIndexChange:W,onEndReached:ot,controllerRef:ue}),n[120]=pe,n[121]=Ot,n[122]=Mt):Mt=n[122];const Bt=`${B+1} \xb7 lap ${Ie}`;let Wt,Ft;n[123]!==b||n[124]!==je||n[125]!==O||n[126]!==Bt?(Wt=(0,T.jsx)(y.ReelsHeader,{acts:O,cap:b,activeFilters:je,onFilter:mt,position:Bt}),n[123]=b,n[124]=je,n[125]=O,n[126]=Bt,n[127]=Wt):Wt=n[127],n[128]!==qe||n[129]!==Wt?(Ft=(0,T.jsx)(t.View,{style:qe,pointerEvents:"box-none",children:Wt}),n[128]=qe,n[129]=Wt,n[130]=Ft):Ft=n[130];const Nt="automate"===N.kind?le.automate:le.share;let Gt,Kt;return n[131]!==i||n[132]!==Ce||n[133]!==At||n[134]!==Dt||n[135]!==zt||n[136]!==ve||n[137]!==Te||n[138]!==$t||n[139]!==Pt||n[140]!==Ct||n[141]!==Tt||n[142]!==Ee||n[143]!==N||n[144]!==Xe||n[145]!==Ve||n[146]!==se||n[147]!==Se||n[148]!==Nt||n[149]!==ke?(Gt=(0,T.jsx)(q,{overlay:N,session:Ce,ring:Ve,onClose:gt,onSend:Dt,onSnooze:Ct,onConsolidate:zt,onKanban:$t,onVerb:Tt,overlayStyle:Xe,sendError:se,verbError:Nt,openDecisions:Ee,onShare:Pt,onAutomate:At,allTags:i,statusSelection:Se,tagSelection:ke,onCycleStatus:ve,onCycleTag:Te}),n[131]=i,n[132]=Ce,n[133]=At,n[134]=Dt,n[135]=zt,n[136]=ve,n[137]=Te,n[138]=$t,n[139]=Pt,n[140]=Ct,n[141]=Tt,n[142]=Ee,n[143]=N,n[144]=Xe,n[145]=Ve,n[146]=se,n[147]=Se,n[148]=Nt,n[149]=ke,n[150]=Gt):Gt=n[150],n[151]!==Mt||n[152]!==Ft||n[153]!==Gt?(Kt=(0,T.jsxs)(t.View,{style:Y.root,testID:"reels-screen",children:[Mt,Ft,Gt]}),n[151]=Mt,n[152]=Ft,n[153]=Gt,n[154]=Kt):Kt=n[154],Kt}),Y=p.StyleSheet.create(e=>({composerLabel:{color:e.colors.foregroundMuted,fontSize:e.fontSize.xs,paddingHorizontal:e.spacing[2],paddingTop:e.spacing[1],uni__dependencies:[0]},sheetInner:{flex:1},tagChip:{minHeight:44,justifyContent:"center",borderWidth:1,borderColor:e.colors.border,borderRadius:e.borderRadius.full,paddingHorizontal:e.spacing[2],uni__dependencies:[0]},tagChipOn:{borderColor:e.colors.accent,uni__dependencies:[0]},tagChipText:{color:e.colors.foreground,fontSize:e.fontSize.xs,uni__dependencies:[0]},sheetGrab:{minHeight:44,alignItems:"center",justifyContent:"center"},sheetHandle:{width:38,height:4,borderRadius:e.borderRadius.full,backgroundColor:e.colors.border,uni__dependencies:[0]},verbFill:{position:"absolute",left:0,top:0,bottom:0,backgroundColor:e.colors.destructive,opacity:.18,borderRadius:e.borderRadius.full,uni__dependencies:[0]},sendError:{color:e.colors.destructive,fontSize:e.fontSize.xs,paddingHorizontal:e.spacing[2],uni__dependencies:[0]},verbHoldLabel:{color:e.colors.destructive,fontSize:e.fontSize.xs,uni__dependencies:[0]},captionBackdrop:Object.assign({},p.StyleSheet.absoluteFillObject,{backgroundColor:e.colors.background,opacity:.72,uni__dependencies:[0]}),sheetClose:{minWidth:44,minHeight:44,alignItems:"center",justifyContent:"center"},sheetCloseGlyph:{color:e.colors.foregroundMuted,fontSize:e.fontSize.base,uni__dependencies:[0]},card:{flex:1},seamBanner:{paddingHorizontal:e.spacing[2],uni__dependencies:[0]},headerSlot:{position:"absolute",top:0,left:0,right:0},captionTap:{minHeight:44,justifyContent:"flex-end"},root:{flex:1,backgroundColor:e.colors.background,uni__dependencies:[0]},background:Object.assign({},p.StyleSheet.absoluteFillObject,{opacity:.35,backgroundColor:e.colors.surface0,uni__dependencies:[0]}),backgroundText:{padding:e.spacing[2],uni__dependencies:[0]},backgroundBody:{color:e.colors.foregroundMuted,fontSize:e.fontSize.xs,lineHeight:20,uni__dependencies:[0]},middle:{flex:1,alignItems:"flex-end",justifyContent:"flex-end",paddingHorizontal:e.spacing[2],uni__dependencies:[0]},bottom:{padding:e.spacing[2],gap:e.spacing[1],uni__dependencies:[0]},cardTitle:{color:e.colors.foreground,fontSize:e.fontSize.base,fontWeight:"600",uni__dependencies:[0]},cardMeta:{color:e.colors.foregroundMuted,fontSize:e.fontSize.xs,marginTop:2,uni__dependencies:[0]},cardSummary:{color:e.colors.foreground,fontSize:e.fontSize.sm,marginTop:6,lineHeight:19,uni__dependencies:[0]},cardTapHint:{color:e.colors.foregroundMuted,fontSize:e.fontSize.xs,marginTop:4,uni__dependencies:[0]},hint:{color:e.colors.foregroundMuted,fontSize:e.fontSize.xs,lineHeight:17,uni__dependencies:[0]},rowGap:{flexDirection:"row",flexWrap:"wrap",gap:e.spacing[1],alignItems:"center",uni__dependencies:[0]},verbChip:{minHeight:44,minWidth:44,alignItems:"center",justifyContent:"center",overflow:"hidden",borderWidth:1,borderColor:e.colors.border,borderRadius:e.borderRadius["2xl"],paddingHorizontal:e.spacing[2],paddingVertical:e.spacing[1],uni__dependencies:[0]},verbGlyph:{fontSize:20},overlay:Object.assign({},p.StyleSheet.absoluteFillObject,{backgroundColor:e.colors.background,uni__dependencies:[0]}),sheet:{padding:e.spacing[2],gap:e.spacing[1],uni__dependencies:[0]},sheetTitle:{color:e.colors.foreground,fontSize:e.fontSize.base,fontWeight:"600",uni__dependencies:[0]},captionSheet:{position:"absolute",left:0,right:0,bottom:0,top:"42%",backgroundColor:e.colors.background,borderTopWidth:1,borderTopColor:e.colors.border,borderTopLeftRadius:e.borderRadius["2xl"],borderTopRightRadius:e.borderRadius["2xl"],uni__dependencies:[0]},sheetHead:{flexDirection:"row",justifyContent:"space-between",alignItems:"center",padding:e.spacing[2],borderBottomWidth:1,borderBottomColor:e.colors.border,uni__dependencies:[0]},sheetBody:{flex:1,padding:e.spacing[2],uni__dependencies:[0]},field:{marginBottom:e.spacing[1],uni__dependencies:[0]},fieldLabel:{color:e.colors.foregroundMuted,fontSize:e.fontSize.xs,textTransform:"uppercase",letterSpacing:.6,marginTop:e.spacing[1],uni__dependencies:[0]},fieldValue:{color:e.colors.foreground,fontSize:e.fontSize.xs,lineHeight:18,uni__dependencies:[0]},fieldDanger:{color:e.colors.destructive,uni__dependencies:[0]},composer:{flexDirection:"row",alignItems:"center",gap:e.spacing[1],padding:e.spacing[2],borderTopWidth:1,borderTopColor:e.colors.border,uni__dependencies:[0]},composerInput:{flex:1,borderWidth:1,borderColor:e.colors.border,borderRadius:e.borderRadius.full,paddingHorizontal:e.spacing[2],paddingVertical:e.spacing[1],color:e.colors.foreground,fontSize:e.fontSize.xs,uni__dependencies:[0]},composerSend:{minHeight:44,justifyContent:"center",paddingHorizontal:e.spacing[1],uni__dependencies:[0]},link:{color:e.colors.accent,fontSize:e.fontSize.xs,uni__dependencies:[0]},send:{borderWidth:1,borderColor:e.colors.accent,borderRadius:e.borderRadius["2xl"],paddingHorizontal:e.spacing[2],paddingVertical:e.spacing[1],alignSelf:"flex-start",uni__dependencies:[0]},dim:{opacity:.35},pickList:{maxHeight:400},pickRow:{minHeight:44,flexDirection:"row",alignItems:"center",gap:e.spacing[1],paddingVertical:e.spacing[1],paddingHorizontal:e.spacing[1],borderWidth:1,borderColor:e.colors.border,borderRadius:e.borderRadius["2xl"],marginBottom:4,uni__dependencies:[0]},pickRowOn:{borderColor:e.colors.accent,uni__dependencies:[0]},pickMark:{color:e.colors.accent,fontSize:e.fontSize.sm,width:22,uni__dependencies:[0]},pickName:{color:e.colors.foreground,fontSize:e.fontSize.xs,fontWeight:"600",uni__dependencies:[0]},pickAux:{color:e.colors.foregroundMuted,fontSize:e.fontSize.xs,uni__dependencies:[0]},grow:{flex:1},empty:{flex:1,alignItems:"center",justifyContent:"center",padding:e.spacing[3],uni__dependencies:[0]},seamHint:{position:"absolute",bottom:0,left:0,right:0,opacity:.5}})),J=[{id:"whatsapp",label:"WhatsApp"},{id:"slack",label:"Slack"},{id:"email",label:"Email"}],Q=400;function X(e){const t=[`${e.title} (${R(String(e.statusBucket))})`,e.digest?.summary??e.digest?.goal??"",e.digest?.nextStep?`Next: ${e.digest.nextStep}`:"",e.digest?.blockers?.length?`Blocked: ${e.digest.blockers.join("; ")}`:""].filter(e=>e.length>0).join("\n");return t.length>Q?`${t.slice(0,399)}\u2026`:t}const Z=[Y.fieldValue,Y.fieldDanger],ee=[Y.pickRow,Y.pickRowOn],te=[Y.tagChip,Y.tagChipOn],ne={selected:!0},se={selected:!1},oe=e=>e?ne:se,le=[Y.send,Y.dim],ie=[Y.background,Y.backgroundText],re={read:"caption",snooze:"snooze",share:"share",taco:"taco",options:"options"},ce={consolidate:"consolidate",outsource:"share",automate:"automate"},ae=[{id:"hourly",label:"Every hour",everyMs:36e5},{id:"daily",label:"Every day",everyMs:864e5},{id:"weekly",label:"Every week",everyMs:6048e5}];function de(e,t){return t.dy>8}function ue(e){return`${e.kind}: ${e.label??e.url}`}function he(e,t){return(t.lastActivityAt?.getTime()??0)-(e.lastActivityAt?.getTime()??0)}function pe(e){return e.id}function be(){return Date.now()}function ge(e){return e.session}function ye(e){return{id:e.id,question:e.question}}function me(e){return e+1}function xe(e){return e+1}function fe(e){return e.session}},4566,[348,2838,349,2815,2476,4567,350,36,591,659,649,25,546,182,234,571,146,558,56,4013,4016,4568,4014,4569,4570,4571,4572,4017,279]);
|
|
16326
16326
|
__d(function(g,r,i,a,m,_e,d){"use strict";Object.defineProperty(_e,'__esModule',{value:!0}),Object.defineProperty(_e,"KeyboardAvoidingView",{enumerable:!0,get:function(){return u}});var e,t=r(d[0]),n=(e=t)&&e.__esModule?e:{default:e};const u=(0,r(d[1]).createUnistylesElement)(n.default)},4567,[659,274]);
|
|
16327
16327
|
__d(function(g,r,i,a,m,_e,d){"use strict";Object.defineProperty(_e,'__esModule',{value:!0}),Object.defineProperty(_e,"ReelsPager",{enumerable:!0,get:function(){return p}});var e=r(d[0]),t=r(d[1]),n=r(d[2]);r(d[3]);var o,l=r(d[4]),s=(o=l)&&o.__esModule?o:{default:o};r(d[5]);var c=r(d[6]),u=r(d[7]),h=r(d[8]);const f={itemVisiblePercentThreshold:60};function b({data:o,keyExtractor:l,renderCard:u,onIndexChange:b,onEndReached:p,controllerRef:I,testID:R}){const{height:v}=(0,s.default)(),y=(0,n.useRef)(null),T=(0,c.useSafeAreaInsets)(),w=Math.max(1,v-T.top-T.bottom),C=(0,n.useMemo)(()=>[...o],[o]),M=(0,n.useMemo)(()=>[x.list,{paddingTop:T.top,paddingBottom:T.bottom}],[T.bottom,T.top]),E=(0,n.useRef)(b);E.current=b;const S=(0,n.useRef)(({viewableItems:e})=>{const t=e[0];null!=t?.index&&E.current(t.index)}).current,_=(0,n.useRef)(f).current;I&&(I.current={scrollToIndex:e=>{e>=0&&e<C.length&&y.current?.scrollToIndex({index:e,animated:!0})}});const P=(0,n.useCallback)((e,t)=>({length:w,offset:w*t,index:t}),[w]),j=(0,n.useMemo)(()=>({height:w}),[w]),k=(0,n.useCallback)(({item:t,index:n})=>(0,h.jsx)(e.View,{style:j,children:u(t,n,w)}),[w,j,u]);return(0,h.jsx)(t.FlatList,{ref:y,style:M,testID:R??"reels-pager",data:C,keyExtractor:l,renderItem:k,getItemLayout:P,pagingEnabled:!0,snapToInterval:w,snapToAlignment:"start",disableIntervalMomentum:!0,decelerationRate:"fast",showsVerticalScrollIndicator:!1,onViewableItemsChanged:S,viewabilityConfig:_,onEndReached:p,onEndReachedThreshold:.5,initialNumToRender:2,maxToRenderPerBatch:3,windowSize:5,removeClippedSubviews:!1})}const x=u.StyleSheet.create(()=>({list:{flex:1}})),p=(0,n.memo)(b)},4568,[348,2656,36,144,686,146,558,56,279]);
|
|
16328
16328
|
__d(function(g,r,i,a,m,e,d){"use strict";Object.defineProperty(e,'__esModule',{value:!0}),Object.defineProperty(e,"FILL_TICK_MS",{enumerable:!0,get:function(){return o}}),e.useDestructiveHold=function(s,u){const _=(0,t.c)(23),[f,h]=(0,n.useState)(l.idleHold),[S,b]=(0,n.useState)(null),[v,I]=(0,n.useState)(0),y=(0,n.useRef)(null);let D;_[0]===Symbol.for("react.memo_cache_sentinel")?(D=(0,l.idleHold)(),_[0]=D):D=_[0];const H=(0,n.useRef)(D),L=(0,n.useRef)(null);let P;_[1]===Symbol.for("react.memo_cache_sentinel")?(P=()=>{null!==L.current&&(clearTimeout(L.current),L.current=null),null!==y.current&&(clearInterval(y.current),y.current=null)},_[1]=P):P=_[1];const T=P;let w;_[2]===Symbol.for("react.memo_cache_sentinel")?(w=()=>{null!==y.current&&clearInterval(y.current),y.current=setInterval(()=>{const t=(0,l.holdProgress)(H.current,Date.now(),c);I(t),t>=1&&null!==y.current&&(clearInterval(y.current),y.current=null)},o)},_[2]=w):w=_[2];const M=w;let R;_[3]===Symbol.for("react.memo_cache_sentinel")?(R=()=>{b(null);const t=(0,l.press)(Date.now());H.current=t,h(t),T(),L.current=setTimeout(()=>{const t=(0,l.tick)(H.current,Date.now());H.current=t,h(t),M()},l.UNFURL_MS)},_[3]=R):R=_[3];const p=R;let E;_[4]!==s||_[5]!==u?(E=t=>{T();const n=(0,l.release)(H.current,Date.now(),c,t);H.current=(0,l.idleHold)(),h((0,l.idleHold)()),I(0),n.commit?(b(null),Promise.resolve(s(u)).catch(t=>{b(t instanceof Error?t.message:"could not retire it")})):b("too-short"===n.reason||"not-read"===n.reason?"hold":null)},_[4]=s,_[5]=u,_[6]=E):E=_[6];const O=E;let C;_[7]!==O?(C=()=>O(!1),_[7]=O,_[8]=C):C=_[8];const U=C;let j;_[9]!==O?(j=()=>O(!0),_[9]=O,_[10]=j):j=_[10];const F=j;let V,k,K,N,q;_[11]===Symbol.for("react.memo_cache_sentinel")?(V=()=>T,k=[T],_[11]=V,_[12]=k):(V=_[11],k=_[12]);(0,n.useEffect)(V,k),_[13]!==f?(K=(0,l.isLabelVisible)(f),_[13]=f,_[14]=K):K=_[14];_[15]!==F||_[16]!==U?(N={onPressIn:p,onPressOut:U,onTouchCancel:F},_[15]=F,_[16]=U,_[17]=N):N=_[17];_[18]!==S||_[19]!==v||_[20]!==N||_[21]!==K?(q={showLabel:K,progress:v,hint:S,handlers:N},_[18]=S,_[19]=v,_[20]=N,_[21]=K,_[22]=q):q=_[22];return q};var t=r(d[0]),n=r(d[1]),l=r(d[2]);const c={holdMs:l.DESTRUCTIVE_HOLD_MS},o=40},4569,[350,36,4018]);
|
|
16329
|
-
__d(function(g,r,i,a,m,e,d){"use strict";Object.defineProperty(e,'__esModule',{value:!0}),e.shareUrlFor=y,e.consolidateSessions=v,e.useReelsVerbs=function(){const s=(0,t.c)(21),u=(0,n.useQueryClient)();let y;s[0]!==u?(y=t=>{u.invalidateQueries({queryKey:(0,o.agentHistoryQueryKey)(t)})},s[0]=u,s[1]=y):y=s[1];const w=y;let f;s[2]!==w?(f=async t=>{const{serverId:n,agentId:s}=t;await I(n).archiveAgent(s),w(n)},s[2]=w,s[3]=f):f=s[3];const
|
|
16329
|
+
__d(function(g,r,i,a,m,e,d){"use strict";Object.defineProperty(e,'__esModule',{value:!0}),e.shareUrlFor=y,e.consolidateSessions=v,e.useReelsVerbs=function(){const s=(0,t.c)(21),u=(0,n.useQueryClient)();let y;s[0]!==u?(y=t=>{u.invalidateQueries({queryKey:(0,o.agentHistoryQueryKey)(t)})},s[0]=u,s[1]=y):y=s[1];const w=y;let f;s[2]!==w?(f=async t=>{const{serverId:n,agentId:s}=t;await I(n).archiveAgent(s),w(n)},s[2]=w,s[3]=f):f=s[3];const h=f;let b;s[4]!==w?(b=async(t,n,s,o)=>{const{serverId:c,agentId:l}=t,u=await I(c).snoozeAgent(l,n,s,o);return w(c),u},s[4]=w,s[5]=b):b=s[5];const A=b;let _;s[6]!==w?(_=async(t,n)=>{const{serverId:s,agentId:o}=t;await I(s).updateAgent(o,{labels:{[l.KANBAN_LABEL_KEY]:n}}),w(s)},s[6]=w,s[7]=_):_=s[7];const E=_;let K;s[8]!==w?(K=async(t,n,s)=>{const{serverId:o,agentId:l}=t;await I(o).updateAgent(l,{labels:(0,c.buildLabelPatchForTagSet)(s,n)}),w(o)},s[8]=w,s[9]=K):K=s[9];const $=K;let C;s[10]!==w?(C=async(t,n,s,o)=>{const{serverId:c,agentId:l}=t;await I(c).scheduleCreate({prompt:s,name:o,cadence:{type:"every",everyMs:n},target:{type:"agent",agentId:l}}),w(c)},s[10]=w,s[11]=C):C=s[11];const S=C,x=p;let L;s[12]!==w?(L=async t=>{await v(t),w(t.serverId)},s[12]=w,s[13]=L):L=s[13];const N=L;let Q;s[14]!==S||s[15]!==N||s[16]!==E||s[17]!==$||s[18]!==A||s[19]!==h?(Q={terminate:h,snooze:A,consolidate:N,setKanban:E,setTags:$,automate:S,share:x},s[14]=S,s[15]=N,s[16]=E,s[17]=$,s[18]=A,s[19]=h,s[20]=Q):Q=s[20];return Q};var t=r(d[0]);r(d[1]);var n=r(d[2]),s=r(d[3]),o=r(d[4]),c=r(d[5]),l=r(d[6]),u=r(d[7]);function y(t,n){const s=encodeURIComponent(n);switch(t){case"whatsapp":return`https://wa.me/?text=${s}`;case"slack":return`slack://open?text=${s}`;case"email":return`mailto:?body=${s}`;default:return w(t)}}function w(t){throw new Error(`unhandled share target: ${String(t)}`)}function I(t){const n=(0,s.getHostRuntimeStore)().getClient(t);if(!n)throw new Error(`No client for server ${t}`);return n}async function v({serverId:t,winnerId:n,sourceIds:s}){const o=I(t);await o.consolidateAgents(n,s.filter(t=>t!==n))}async function p(t,n){await(0,u.openExternalUrl)(y(t,n))}},4570,[350,36,3030,3274,4015,4003,4008,3577]);
|
|
16330
16330
|
__d(function(g,r,_i,a,m,e,d){"use strict";Object.defineProperty(e,'__esModule',{value:!0}),e.useReelsFeed=function({sessions:n,localTags:c,actedLaps:o,laps:u,now:p}){const S=(0,s.useSessionFilterStore)(t=>t.statusSelection),f=(0,s.useSessionFilterStore)(t=>t.tagSelection),F=(0,s.useSessionFilterStore)(t=>t.cycleStatusFilter),M=(0,s.useSessionFilterStore)(t=>t.cycleTagFilter),b=((0,i.isFilterSelectionActive)(S)?1:0)+((0,i.isFilterSelectionActive)(f)?1:0),v=(0,t.useCallback)(t=>(0,i.passesFilterSelection)(String(t.statusBucket),S)&&(0,i.passesFilterSelectionMulti)(t.tags,f),[S,f]),y=(0,t.useMemo)(()=>0===b?n:n.filter(v),[b,v,n]),k=(0,t.useMemo)(()=>y.map(t=>Object.assign({},t,{tags:c[t.id]??t.tags,actedLap:o[t.id]??t.actedLap??null})),[o,y,c]),w=(0,t.useRef)(new Map),C=(0,t.useRef)(S),L=(0,t.useRef)(f);C.current===S&&L.current===f||(C.current=S,L.current=f,w.current=new Map);const h=(0,t.useMemo)(()=>new Map(k.map(t=>[t.id,t])),[k]),R=(0,t.useMemo)(()=>{const t=[];for(let s=1;s<=u;s+=1){let i=(w.current.get(s)??[]).map(t=>h.get(t)).filter(t=>void 0!==t);if(0===i.length){const t=(0,l.buildLap)({sessions:k,lap:s,now:p});t.length>0&&w.current.set(s,t.map(t=>t.id)),i=t}i.forEach((i,l)=>{t.push({session:i,lap:s,key:`${s}:${i.id}`,firstOfLap:0===l})})}return t},[h,k,u,p]),_=(0,t.useCallback)(t=>F(t),[F]),O=(0,t.useCallback)(t=>M(t),[M]);return{feed:R,activeFilters:b,statusSelection:S,tagSelection:f,onCycleStatus:_,onCycleTag:O}};var t=r(d[0]),s=r(d[1]),i=r(d[2]),l=r(d[3])},4571,[36,3617,3622,4572]);
|
|
16331
|
-
__d(function(g,r,i,_a,m,e,d){"use strict";Object.defineProperty(e,'__esModule',{value:!0}),e.ringStateRank=n,e.isSnoozed=
|
|
16331
|
+
__d(function(g,r,i,_a,m,e,d){"use strict";Object.defineProperty(e,'__esModule',{value:!0}),e.ringStateRank=n,e.isSnoozed=u,e.snoozeCancelledByFailure=a,e.isUntagged=o,e.buildLap=function({sessions:t,lap:s,now:c}){return[...t.filter(t=>a(t)||!u(t,c))].sort((t,u)=>{const a=o(t)?0:1,c=o(u)?0:1;if(a!==c)return a-c;if(1===a){const n=t.actedLap===s-1?1:0,a=u.actedLap===s-1?1:0;if(n!==a)return n-a}const l=n(String(t.statusBucket)),f=n(String(u.statusBucket));return l!==f?l-f:t.id.localeCompare(u.id)})},e.actedThisLap=function(t,n){return t.filter(t=>t.actedLap===n).length};var t=r(d[0]);function n(n){return(0,t.getWorkspaceStateBucketPriority)(n)??Number.MAX_SAFE_INTEGER}function u(t,n){if(!t.snoozedUntil)return!1;const u=Date.parse(t.snoozedUntil);return Number.isFinite(u)&&u>n.getTime()}function a(t){return"failed"===t.statusBucket}function o(t){return 0===t.tags.length}},4572,[3442]);
|
|
16332
16332
|
__d(function(g,r,i,a,m,e,d){"use strict";Object.defineProperty(e,'__esModule',{value:!0}),e.isMachineExecution=n,e.isDurable=u,e.selectFeedCandidates=function(t){return t.filter(t=>!n(t)&&!u(t))};var t=r(d[0]);function n(n){return(0,t.isMachineExecutionAgent)({labels:n.labels??{}})}function u(t){return!0===t.hasSystemPrompt&&!0===t.hasRoutine}},4573,[3437]);
|
|
16333
16333
|
__d(function(g,r,i,a,m,e,d){"use strict";Object.defineProperty(e,'__esModule',{value:!0}),Object.defineProperty(e,"default",{enumerable:!0,get:function(){return u}});var t=r(d[0]),n=r(d[1]),c=r(d[2]),o=r(d[3]);function u(){const u=(0,t.c)(1);let s;return u[0]===Symbol.for("react.memo_cache_sentinel")?(s=(0,o.jsx)(n.Redirect,{href:(0,c.buildSessionsRoute)()}),u[0]=s):s=u[0],s}},4574,[350,379,3492,279]);
|
|
16334
16334
|
__d(function(g,r,i,a,m,e,d){"use strict";Object.defineProperty(e,'__esModule',{value:!0}),Object.defineProperty(e,"default",{enumerable:!0,get:function(){return c}});var t=r(d[0]),s=r(d[1]),n=r(d[2]),o=r(d[3]),u=r(d[4]);function c(){const c=(0,t.c)(4),l=(0,s.useLocalSearchParams)();let f;if(c[0]!==l.serverId){const t="string"==typeof l.serverId?l.serverId.trim():"";f=t.length>0?(0,o.buildSettingsHostRoute)(t):(0,o.buildSettingsRoute)(),c[0]=l.serverId,c[1]=f}else f=c[1];const v=f;let b;return c[2]!==v?(b=(0,u.jsx)(n.HostRouteBootstrapBoundary,{children:(0,u.jsx)(s.Redirect,{href:v})}),c[2]=v,c[3]=b):b=c[3],b}},4575,[350,379,4480,3492,279]);
|
|
@@ -16698,5 +16698,5 @@ __d(function(g,r,_i,a,_m,_e,d){"use strict";var e,t=r(d[0]),n=this&&this.__creat
|
|
|
16698
16698
|
__r(694);
|
|
16699
16699
|
__r(341);
|
|
16700
16700
|
__r(0);
|
|
16701
|
-
//# sourceMappingURL=/_expo/static/js/web/index-
|
|
16702
|
-
//# debugId=
|
|
16701
|
+
//# sourceMappingURL=/_expo/static/js/web/index-4d3aa1f9c74ac3a193b8006f00541563.js.map
|
|
16702
|
+
//# debugId=a796c4ca-b8e1-4d34-880a-a1708333ff79
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
@@ -191,6 +191,6 @@
|
|
|
191
191
|
<body>
|
|
192
192
|
<noscript>You need to enable JavaScript to run this app.</noscript>
|
|
193
193
|
<div id="root"></div>
|
|
194
|
-
<script src="/_expo/static/js/web/index-
|
|
194
|
+
<script src="/_expo/static/js/web/index-4d3aa1f9c74ac3a193b8006f00541563.js" defer></script>
|
|
195
195
|
</body>
|
|
196
196
|
</html>
|
|
Binary file
|
|
Binary file
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@hyperdrive.bot/fleet-server",
|
|
3
|
-
"version": "0.3.
|
|
3
|
+
"version": "0.3.116",
|
|
4
4
|
"description": "Paseo backend server",
|
|
5
5
|
"license": "Apache-2.0",
|
|
6
6
|
"files": [
|
|
@@ -66,11 +66,11 @@
|
|
|
66
66
|
"@agentclientprotocol/sdk": "^0.17.1",
|
|
67
67
|
"@anthropic-ai/claude-agent-sdk": "^0.3.195",
|
|
68
68
|
"@anthropic-ai/sdk": "^0.104.2",
|
|
69
|
-
"@hyperdrive.bot/fleet-client": "0.3.
|
|
70
|
-
"@hyperdrive.bot/fleet-extension-sdk": "0.3.
|
|
71
|
-
"@hyperdrive.bot/fleet-highlight": "0.3.
|
|
72
|
-
"@hyperdrive.bot/fleet-protocol": "0.3.
|
|
73
|
-
"@hyperdrive.bot/fleet-relay": "0.3.
|
|
69
|
+
"@hyperdrive.bot/fleet-client": "0.3.116",
|
|
70
|
+
"@hyperdrive.bot/fleet-extension-sdk": "0.3.116",
|
|
71
|
+
"@hyperdrive.bot/fleet-highlight": "0.3.116",
|
|
72
|
+
"@hyperdrive.bot/fleet-protocol": "0.3.116",
|
|
73
|
+
"@hyperdrive.bot/fleet-relay": "0.3.116",
|
|
74
74
|
"@isaacs/ttlcache": "^2.1.4",
|
|
75
75
|
"@modelcontextprotocol/sdk": "^1.20.1",
|
|
76
76
|
"@opencode-ai/sdk": "1.2.6",
|