@liberseek/boft-cli-win32-arm64 0.6.7 → 0.6.9
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/README.md +1 -1
- package/THIRD_PARTY_NOTICES.txt +8 -0
- package/app/codexhost-distribution.json +1 -1
- package/app/desktop-controller.mjs +137 -36
- package/app/host-runtime.mjs +4164 -3710
- package/app/plugins/antigravity/plugin.mjs +71 -244
- package/app/plugins/claude-code/plugin.mjs +271 -104
- package/app/plugins/codebuddy/assets/icon.svg +1 -0
- package/app/plugins/codebuddy/manifest.json +13 -0
- package/app/plugins/codebuddy/plugin.mjs +23159 -0
- package/app/plugins/cursor-cli/assets/icon.svg +1 -0
- package/app/plugins/cursor-cli/manifest.json +13 -0
- package/app/plugins/cursor-cli/plugin.mjs +22693 -0
- package/app/plugins/deepseek-harness/plugin.mjs +26 -46
- package/app/plugins/enabled.json +3 -1
- package/app/plugins/grok/plugin.mjs +26 -46
- package/app/plugins/hermes/plugin.mjs +268 -92
- package/app/plugins/kiro-cli/plugin.mjs +26 -46
- package/app/plugins/muse/plugin.mjs +26 -46
- package/app/plugins/omp/plugin.mjs +26 -46
- package/app/plugins/opencode/plugin.mjs +50 -51
- package/app/plugins/pi/plugin.mjs +26 -58
- package/app/renderer-extension.js +858 -1145
- package/bin/boft.exe +0 -0
- package/libexec/boft-node-repl.exe +0 -0
- package/libexec/boft-shim.exe +0 -0
- package/libexec/boft-updater.exe +0 -0
- package/licenses/Agent-Client-Protocol-SDK-LICENSE.txt +191 -0
- package/licenses/opencodex-LICENSE.txt +21 -0
- package/package.json +1 -1
|
@@ -18,7 +18,9 @@
|
|
|
18
18
|
"antigravity",
|
|
19
19
|
"hermes",
|
|
20
20
|
"muse",
|
|
21
|
-
"kiro-cli"
|
|
21
|
+
"kiro-cli",
|
|
22
|
+
"codebuddy",
|
|
23
|
+
"cursor-cli"
|
|
22
24
|
];
|
|
23
25
|
var DEFAULT_RENDERER_AGENTS = KNOWN_RENDERER_AGENTS;
|
|
24
26
|
function defaultIdFactory(sequence) {
|
|
@@ -119,24 +121,36 @@
|
|
|
119
121
|
this.#ownershipRequestGenerations.set(state, ++this.#ownershipRequestSequence);
|
|
120
122
|
return state;
|
|
121
123
|
}
|
|
122
|
-
restore(composer, agent, model, thinkingOptionId, permissionModeId
|
|
124
|
+
restore(composer, agent, model, thinkingOptionId, permissionModeId) {
|
|
123
125
|
if (!this.#enabledAgents.has(agent)) return null;
|
|
124
126
|
const state = this.#state(composer);
|
|
125
127
|
this.#pendingSubmissions.delete(state);
|
|
126
128
|
state.agent = agent;
|
|
127
129
|
state.phase = "locked";
|
|
128
|
-
if (agent === "codex" && codexAccountId) state.codexAccountId = codexAccountId;
|
|
129
|
-
else delete state.codexAccountId;
|
|
130
130
|
if (agent === "pi" && model) state.piModel = model;
|
|
131
|
+
else if (agent === "pi") delete state.piModel;
|
|
131
132
|
if (agent === "claude-code" && model) state.claudeModel = model;
|
|
133
|
+
else if (agent === "claude-code") delete state.claudeModel;
|
|
132
134
|
if (agent === "deepseek-harness" && model) state.deepSeekHarnessModel = model;
|
|
135
|
+
else if (agent === "deepseek-harness") delete state.deepSeekHarnessModel;
|
|
133
136
|
if (agent === "opencode" && model) state.openCodeModel = model;
|
|
137
|
+
else if (agent === "opencode") delete state.openCodeModel;
|
|
134
138
|
if (agent === "grok" && model) state.grokModel = model;
|
|
139
|
+
else if (agent === "grok") delete state.grokModel;
|
|
135
140
|
if (agent === "omp" && model) state.ompModel = model;
|
|
141
|
+
else if (agent === "omp") delete state.ompModel;
|
|
136
142
|
if (agent === "antigravity" && model) state.antigravityModel = model;
|
|
143
|
+
else if (agent === "antigravity") delete state.antigravityModel;
|
|
137
144
|
if (agent === "hermes" && model) state.hermesModel = model;
|
|
145
|
+
else if (agent === "hermes") delete state.hermesModel;
|
|
138
146
|
if (agent === "muse" && model) state.museModel = model;
|
|
147
|
+
else if (agent === "muse") delete state.museModel;
|
|
139
148
|
if (agent === "kiro-cli" && model) state.kiroCliModel = model;
|
|
149
|
+
else if (agent === "kiro-cli") delete state.kiroCliModel;
|
|
150
|
+
if (agent === "codebuddy" && model) state.codeBuddyModel = model;
|
|
151
|
+
else if (agent === "codebuddy") delete state.codeBuddyModel;
|
|
152
|
+
if (agent === "cursor-cli" && model) state.cursorCliModel = model;
|
|
153
|
+
else if (agent === "cursor-cli") delete state.cursorCliModel;
|
|
140
154
|
if (agent === "pi" && thinkingOptionId) state.piThinkingOptionId = thinkingOptionId;
|
|
141
155
|
else if (agent === "pi") delete state.piThinkingOptionId;
|
|
142
156
|
if (agent === "claude-code" && thinkingOptionId) {
|
|
@@ -158,6 +172,9 @@
|
|
|
158
172
|
if (agent === "kiro-cli" && thinkingOptionId) {
|
|
159
173
|
state.kiroCliThinkingOptionId = thinkingOptionId;
|
|
160
174
|
} else if (agent === "kiro-cli") delete state.kiroCliThinkingOptionId;
|
|
175
|
+
if (agent === "codebuddy" && thinkingOptionId) {
|
|
176
|
+
state.codeBuddyThinkingOptionId = thinkingOptionId;
|
|
177
|
+
} else if (agent === "codebuddy") delete state.codeBuddyThinkingOptionId;
|
|
161
178
|
if (agent !== "codex") {
|
|
162
179
|
const permissionModeByAgent = {};
|
|
163
180
|
for (const candidate of [
|
|
@@ -170,7 +187,9 @@
|
|
|
170
187
|
"antigravity",
|
|
171
188
|
"hermes",
|
|
172
189
|
"muse",
|
|
173
|
-
"kiro-cli"
|
|
190
|
+
"kiro-cli",
|
|
191
|
+
"codebuddy",
|
|
192
|
+
"cursor-cli"
|
|
174
193
|
]) {
|
|
175
194
|
const current = state.permissionModeByAgent?.[candidate];
|
|
176
195
|
if (candidate !== agent && current) permissionModeByAgent[candidate] = current;
|
|
@@ -196,6 +215,8 @@
|
|
|
196
215
|
if (agent === "antigravity") return state.antigravityModel;
|
|
197
216
|
if (agent === "muse") return state.museModel;
|
|
198
217
|
if (agent === "kiro-cli") return state.kiroCliModel;
|
|
218
|
+
if (agent === "codebuddy") return state.codeBuddyModel;
|
|
219
|
+
if (agent === "cursor-cli") return state.cursorCliModel;
|
|
199
220
|
return void 0;
|
|
200
221
|
}
|
|
201
222
|
thinkingOptionForAgent(composer, agent) {
|
|
@@ -208,6 +229,7 @@
|
|
|
208
229
|
if (agent === "antigravity") return state.antigravityThinkingOptionId;
|
|
209
230
|
if (agent === "muse") return state.museThinkingOptionId;
|
|
210
231
|
if (agent === "kiro-cli") return state.kiroCliThinkingOptionId;
|
|
232
|
+
if (agent === "codebuddy") return state.codeBuddyThinkingOptionId;
|
|
211
233
|
return void 0;
|
|
212
234
|
}
|
|
213
235
|
permissionModeForAgent(composer, agent) {
|
|
@@ -233,6 +255,9 @@
|
|
|
233
255
|
else if (agent === "antigravity") state.antigravityModel = model;
|
|
234
256
|
else if (agent === "muse") state.museModel = model;
|
|
235
257
|
else if (agent === "kiro-cli") state.kiroCliModel = model;
|
|
258
|
+
else if (agent === "codebuddy") state.codeBuddyModel = model;
|
|
259
|
+
else if (agent === "cursor-cli") state.cursorCliModel = model;
|
|
260
|
+
else state.antigravityModel = model;
|
|
236
261
|
return state;
|
|
237
262
|
}
|
|
238
263
|
setPiConfiguration(composer, model, thinkingOptionId) {
|
|
@@ -277,6 +302,10 @@
|
|
|
277
302
|
state.kiroCliThinkingOptionId = thinkingOptionId;
|
|
278
303
|
} else if (agent === "kiro-cli") {
|
|
279
304
|
delete state.kiroCliThinkingOptionId;
|
|
305
|
+
} else if (agent === "codebuddy" && thinkingOptionId) {
|
|
306
|
+
state.codeBuddyThinkingOptionId = thinkingOptionId;
|
|
307
|
+
} else if (agent === "codebuddy") {
|
|
308
|
+
delete state.codeBuddyThinkingOptionId;
|
|
280
309
|
}
|
|
281
310
|
return state;
|
|
282
311
|
}
|
|
@@ -300,13 +329,9 @@
|
|
|
300
329
|
clearPendingSubmission(composer) {
|
|
301
330
|
const state = this.#state(composer);
|
|
302
331
|
this.#pendingSubmissions.delete(state);
|
|
303
|
-
if (state.phase === "draft") delete state.codexAccountId;
|
|
304
332
|
}
|
|
305
|
-
recordSubmission(composer
|
|
333
|
+
recordSubmission(composer) {
|
|
306
334
|
const state = this.#state(composer);
|
|
307
|
-
if (state.agent === "codex" && state.phase === "draft" && !state.codexAccountId && codexAccountId) {
|
|
308
|
-
state.codexAccountId = codexAccountId;
|
|
309
|
-
}
|
|
310
335
|
this.#lastSubmittedAgent = state.agent;
|
|
311
336
|
return state;
|
|
312
337
|
}
|
|
@@ -15006,12 +15031,21 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
15006
15031
|
plan: external_exports.string().trim().min(1).max(128).optional(),
|
|
15007
15032
|
credits: accountCreditsSnapshotSchema
|
|
15008
15033
|
}).strict();
|
|
15009
|
-
var
|
|
15034
|
+
var harnessAccountIdentityShape = {
|
|
15035
|
+
harnessId: harnessIdSchema,
|
|
15036
|
+
harnessName: external_exports.string().trim().min(1).max(128)
|
|
15037
|
+
};
|
|
15038
|
+
var harnessAccountSourceSchema = external_exports.object(harnessAccountIdentityShape).strict();
|
|
15039
|
+
var harnessAccountSourceListParamsSchema = external_exports.object({}).strict();
|
|
15040
|
+
var harnessAccountSourceListResultSchema = external_exports.object({ sources: external_exports.array(harnessAccountSourceSchema).max(128) }).strict();
|
|
15041
|
+
var harnessAccountInspectParamsSchema = external_exports.object({ harnessId: harnessIdSchema, refresh: external_exports.boolean().optional() }).strict();
|
|
15042
|
+
var harnessAccountInspectResultSchema = external_exports.object({
|
|
15043
|
+
...harnessAccountIdentityShape,
|
|
15044
|
+
account: harnessAccountSnapshotSchema.nullable()
|
|
15045
|
+
}).strict();
|
|
15046
|
+
var harnessAccountListParamsSchema = external_exports.object({ refresh: external_exports.boolean().optional() }).strict();
|
|
15010
15047
|
var harnessAccountListResultSchema = external_exports.object({
|
|
15011
|
-
accounts: external_exports.array(harnessAccountSnapshotSchema.extend(
|
|
15012
|
-
harnessId: harnessIdSchema,
|
|
15013
|
-
harnessName: external_exports.string().min(1)
|
|
15014
|
-
})).max(128)
|
|
15048
|
+
accounts: external_exports.array(harnessAccountSnapshotSchema.extend(harnessAccountIdentityShape)).max(128)
|
|
15015
15049
|
}).strict();
|
|
15016
15050
|
|
|
15017
15051
|
// ../shared-contracts/dist/json-value.js
|
|
@@ -15311,7 +15345,6 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
15311
15345
|
}).strict();
|
|
15312
15346
|
var codexThreadInspectionSchema = external_exports.object({
|
|
15313
15347
|
owner: external_exports.literal("codex"),
|
|
15314
|
-
accountId: nonBlankTextSchema2.optional(),
|
|
15315
15348
|
locked: external_exports.literal(true)
|
|
15316
15349
|
}).strict();
|
|
15317
15350
|
var externalThreadInspectionSchema = external_exports.object({
|
|
@@ -15477,53 +15510,26 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
15477
15510
|
label: nonBlankTextSchema3.max(256),
|
|
15478
15511
|
email: external_exports.string().email().max(320).optional(),
|
|
15479
15512
|
planType: codexAccountPlanTypeSchema.optional(),
|
|
15480
|
-
codexHome: nonBlankTextSchema3.max(16384),
|
|
15481
|
-
active: external_exports.boolean(),
|
|
15482
|
-
isDefault: external_exports.boolean(),
|
|
15483
15513
|
authKind: codexAccountAuthKindSchema.optional(),
|
|
15484
15514
|
authIdentity: nonBlankTextSchema3.max(256).optional()
|
|
15485
15515
|
}).strict();
|
|
15486
|
-
var
|
|
15487
|
-
var
|
|
15488
|
-
|
|
15489
|
-
|
|
15490
|
-
|
|
15491
|
-
|
|
15492
|
-
|
|
15493
|
-
|
|
15494
|
-
accountId: accountIdSchema,
|
|
15495
|
-
loginId: nonBlankTextSchema3.max(1024),
|
|
15496
|
-
verificationUrl: external_exports.string().url().max(16384),
|
|
15497
|
-
userCode: nonBlankTextSchema3.max(1024)
|
|
15498
|
-
}).strict();
|
|
15499
|
-
var codexAccountLoginCancelParamsSchema = external_exports.object({ accountId: accountIdSchema.optional(), loginId: nonBlankTextSchema3.max(1024) }).strict();
|
|
15500
|
-
var codexAccountLoginCancelResultSchema = external_exports.object({ cancelled: external_exports.boolean() }).strict();
|
|
15501
|
-
var codexAccountLoginCompletedSchema = external_exports.object({
|
|
15502
|
-
accountId: accountIdSchema,
|
|
15503
|
-
loginId: nonBlankTextSchema3.max(1024),
|
|
15504
|
-
success: external_exports.boolean(),
|
|
15505
|
-
error: external_exports.string().max(4096).nullable()
|
|
15516
|
+
var codexAccountPhaseSchema = external_exports.enum(["ready", "unavailable"]);
|
|
15517
|
+
var codexAccountListResultSchema = external_exports.object({
|
|
15518
|
+
version: external_exports.literal(2),
|
|
15519
|
+
currentAccountId: accountIdSchema.nullable(),
|
|
15520
|
+
phase: codexAccountPhaseSchema,
|
|
15521
|
+
revision: external_exports.number().int().nonnegative(),
|
|
15522
|
+
instanceId: nonBlankTextSchema3.max(1024).optional(),
|
|
15523
|
+
accounts: external_exports.array(codexAccountSchema).max(1)
|
|
15506
15524
|
}).strict();
|
|
15507
|
-
var
|
|
15525
|
+
var codexAccountChangedSchema = codexAccountListResultSchema;
|
|
15526
|
+
var codexAccountUsageParamsSchema = external_exports.object({ accountId: accountIdSchema, refresh: external_exports.boolean().optional() }).strict();
|
|
15508
15527
|
var codexAccountUsageResultSchema = external_exports.object({
|
|
15509
15528
|
accountId: accountIdSchema,
|
|
15510
15529
|
usage: threadUsageSnapshotSchema.nullable(),
|
|
15511
|
-
accountCredits: accountCreditsSnapshotSchema.optional()
|
|
15512
|
-
|
|
15513
|
-
|
|
15514
|
-
accountId: accountIdSchema,
|
|
15515
|
-
idempotencyKey: external_exports.string().uuid().optional()
|
|
15516
|
-
}).strict();
|
|
15517
|
-
var codexAccountResetCreditConsumeOutcomeSchema = external_exports.enum([
|
|
15518
|
-
"reset",
|
|
15519
|
-
"nothingToReset",
|
|
15520
|
-
"noCredit",
|
|
15521
|
-
"alreadyRedeemed"
|
|
15522
|
-
]);
|
|
15523
|
-
var codexAccountResetCreditConsumeResultSchema = external_exports.object({
|
|
15524
|
-
accountId: accountIdSchema,
|
|
15525
|
-
outcome: codexAccountResetCreditConsumeOutcomeSchema,
|
|
15526
|
-
accountCredits: accountCreditsSnapshotSchema.optional()
|
|
15530
|
+
accountCredits: accountCreditsSnapshotSchema.optional(),
|
|
15531
|
+
freshness: external_exports.enum(["live", "cached"]),
|
|
15532
|
+
observedAt: external_exports.string().datetime().nullable()
|
|
15527
15533
|
}).strict();
|
|
15528
15534
|
|
|
15529
15535
|
// ../shared-contracts/dist/reasoning-transcript.js
|
|
@@ -15908,15 +15914,21 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
15908
15914
|
// src/assets/grok-agent.png
|
|
15909
15915
|
var grok_agent_default = "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAIAAAACACAYAAADDPmHLAAAAAXNSR0IArs4c6QAAEk9JREFUeNrtnQdsHEUXx5fee40xnQiQ6b23IAiJAWHACV10AQHRRG8GDJgSOggEGAEBg6gGhAIBQknoppjeezGE3kybb3+je6f1fVdm93Z2Zy870iPmfN67mffmzSv/98bzLIxZZpml2ad2n7p86vWp36cBnwZ9UjlVpcHCWvUX1q6rsJbNnsvD/4ItPnX41Jcz0Rr1Fda4xSXGt/k0MWdO4sSat6XJ+FafpuaMSJ3gQWuSjG/yaUK+8M4RPGmyzfyxPk3LF9tZgjdjbTG/M1/gzFBn3Mzvzhc1c9QdF/N78sXMLPXkO386o5lnnllT3ZogP/OzRzPNNJOac8451bBhw0qFoDOKtZ8vasZ2Pv/uuOOOaoklltDCUPKesWH8/NzVyxjzfdapcePGqa222kr/XMFFbDIRgDzIkzGC4Yceeqg6/fTTKzG/GCwyCe/mi5ox5u+3337q4YcfVvPNN1851V9KrdUEII/tZ4z5e++9t/rmm2/UeuutV2v3F3MH1bJ6+cJmiPnt7e3q77//VieccIIp84XayglAntLNEPO33XZb9dtvv2nVP9tss5mo/iGp5HJgjnxxM8L8TTbZRKv9adOmqVVWWSXs7hdqCQpAR7642WD+hhtuqD777DPFOProo6MyH+oICkAO48oY8ydNmqTmmmuusKp/CLwsCOCcbgImLBg044wz6kUtpRlmmKH4npJwaqrMX3PNNdXHH3+smf/zzz+HsfqrUbNXQJw2dIQsyFx2zSKLLKKWWWYZtfrqq+uFFFpttdXUsssuqxZeeGE199xz6/cH/z4NgeBzV1hhBfX2228rGeecc04czIfavQLsuKESIsIwmI2RNGbMGHX++eere++9V73wwgvq888/Vz/88IP69ddf1e+//16kX375Rb+Omn3xxRf1+y+44AK1++67q1VXXVU/T55dh+oNxfyll15avfzyy0XmIwiLLbaY1mAxfEaXV8CeN8QZCS244IJq9OjR6tJLL1V9fX2aqeXGf//9p+nff/8tkrxWbvCcV155RV1++eVq1KhR+nPkM23NZ6mlllLPPfec/nz5fvvvv3+cn9nrFQoQMq3iUdXrrLOOuuiii9S77747hIn8/M8//9RNpc9855139Oet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";
|
|
15910
15916
|
|
|
15911
|
-
// src/assets/antigravity-agent.svg
|
|
15912
|
-
var antigravity_agent_default = 'data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="-2 -1 28 28"><path d="M21.751 22.607c1.34 1.005 3.35.335 1.508-1.508C17.73 15.74 18.904 1 12.037 1 5.17 1 6.342 15.74.815 21.1c-2.01 2.009.167 2.511 1.507 1.506 5.192-3.517 4.857-9.714 9.715-9.714 4.857 0 4.522 6.197 9.714 9.715z" fill="url(%23ag)"/><defs><linearGradient id="ag" x1="2" y1="12" x2="22" y2="12" gradientUnits="userSpaceOnUse"><stop stop-color="%234285F4"/><stop offset=".33" stop-color="%23EA4335"/><stop offset=".66" stop-color="%23FBBC04"/><stop offset="1" stop-color="%2334A853"/></linearGradient></defs></svg>%0A';
|
|
15913
|
-
|
|
15914
15917
|
// src/assets/hermes-agent.png
|
|
15915
15918
|
var hermes_agent_default = "data:image/png;base64,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";
|
|
15916
15919
|
|
|
15920
|
+
// src/assets/antigravity-agent.svg
|
|
15921
|
+
var antigravity_agent_default = 'data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="-2 -1 28 28"><path d="M21.751 22.607c1.34 1.005 3.35.335 1.508-1.508C17.73 15.74 18.904 1 12.037 1 5.17 1 6.342 15.74.815 21.1c-2.01 2.009.167 2.511 1.507 1.506 5.192-3.517 4.857-9.714 9.715-9.714 4.857 0 4.522 6.197 9.714 9.715z" fill="url(%23ag)"/><defs><linearGradient id="ag" x1="2" y1="12" x2="22" y2="12" gradientUnits="userSpaceOnUse"><stop stop-color="%234285F4"/><stop offset=".33" stop-color="%23EA4335"/><stop offset=".66" stop-color="%23FBBC04"/><stop offset="1" stop-color="%2334A853"/></linearGradient></defs></svg>%0A';
|
|
15922
|
+
|
|
15917
15923
|
// src/assets/kiro-agent.svg
|
|
15918
15924
|
var kiro_agent_default = 'data:image/svg+xml,<svg width="1200" height="1200" viewBox="0 0 1200 1200" fill="none" xmlns="http://www.w3.org/2000/svg">%0A<rect width="1200" height="1200" rx="260" fill="%239046FF"/>%0A<mask id="mask0_1106_4856" style="mask-type:luminance" maskUnits="userSpaceOnUse" x="272" y="202" width="655" height="796">%0A<path d="M926.578 202.793H272.637V997.857H926.578V202.793Z" fill="white"/>%0A</mask>%0A<g mask="url(%23mask0_1106_4856)">%0A<path d="M398.554 818.914C316.315 1001.03 491.477 1046.74 620.672 940.156C658.687 1059.66 801.052 970.473 852.234 877.795C964.787 673.567 919.318 465.357 907.64 422.374C827.637 129.443 427.623 128.946 358.8 423.865C342.651 475.544 342.402 534.18 333.458 595.051C328.986 625.86 325.507 645.488 313.83 677.785C306.873 696.424 297.68 712.819 282.773 740.645C259.915 783.881 269.604 867.113 387.87 823.883L399.051 818.914H398.554Z" fill="white"/>%0A<path d="M636.123 549.353C603.328 549.353 598.359 510.097 598.359 486.742C598.359 465.623 602.086 448.977 609.293 438.293C615.504 428.852 624.697 424.131 636.123 424.131C647.555 424.131 657.492 428.852 664.447 438.541C672.398 449.474 676.623 466.12 676.623 486.742C676.623 525.998 661.471 549.353 636.375 549.353H636.123Z" fill="black"/>%0A<path d="M771.24 549.353C738.445 549.353 733.477 510.097 733.477 486.742C733.477 465.623 737.203 448.977 744.41 438.293C750.621 428.852 759.814 424.131 771.24 424.131C782.672 424.131 792.609 428.852 799.564 438.541C807.516 449.474 811.74 466.12 811.74 486.742C811.74 525.998 796.588 549.353 771.492 549.353H771.24Z" fill="black"/>%0A</g>%0A</svg>%0A';
|
|
15919
15925
|
|
|
15926
|
+
// src/assets/codebuddy-agent.svg
|
|
15927
|
+
var codebuddy_agent_default = 'data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" width="40" height="40" viewBox="0 0 40 40" fill="none"><g clip-path="url(%23clip0_4958_10776)"><rect x="-0.00146484" width="40" height="40" rx="8.63158" fill="%236C4DFF"></rect><path d="M30.5918 3.12856C30.984 2.77679 31.0078 2.7632 31.2955 2.74593C31.7615 2.71193 32.1882 2.93586 32.9147 3.59728C34.6119 5.13959 36.9755 8.30995 38.4449 11.0177L39.0125 12.0691L39.8143 12.4677C40.5885 12.8589 41.8587 13.6611 42.389 14.0913C42.6286 14.2894 42.6626 14.2934 42.912 14.1964C44.0375 13.7583 45.6494 14.3393 47.0714 15.7033C48.3516 16.9303 49.5781 19.0269 50.0478 20.7767C50.1164 21.0582 50.2074 21.6636 50.2405 22.1144C50.3477 23.6973 49.84 24.9617 48.8624 25.5341C48.6628 25.6493 48.6492 25.6807 48.6548 26.1783C48.6998 28.5492 48.0606 30.9165 46.7768 33.2244C45.3276 35.8156 42.7467 38.496 39.2544 41.0214C37.3789 42.3862 32.9421 44.9717 30.9361 45.8792C26.1304 48.0428 22.278 48.8718 18.9316 48.4618C16.9356 48.22 14.6761 47.4417 13.3392 46.5373C12.9873 46.294 12.9318 46.2791 12.6629 46.3561C11.2318 46.7671 9.35752 45.9219 7.76528 44.1544C7.13027 43.448 6.10508 41.7136 5.77273 40.7853C5.00409 38.6128 5.15721 36.6516 6.18105 35.4808C6.44522 35.1797 6.4538 35.1667 6.39603 34.6598C6.30065 33.8298 6.25703 32.6017 6.30061 31.809L6.33535 31.0683L5.22371 29.1019C3.50212 26.0386 2.40857 23.4663 1.98661 21.501C1.76389 20.4233 1.77734 19.9446 2.05091 19.5908C2.21741 19.3773 2.76347 19.1568 3.42155 19.0352C5.07869 18.7442 8.69327 19.0065 12.7142 19.7165L13.1316 19.789L14.0497 18.977C15.5733 17.6274 16.5858 16.8705 18.4518 15.707C20.3967 14.4901 22.5922 13.4895 25.064 12.6968L25.8564 12.4423L26.2926 11.2974C27.8535 7.17701 29.452 4.13917 30.5918 3.12856ZM17.5169 24.2439C15.7528 25.2625 14.8705 25.7716 14.2223 26.3423C11.5975 28.6536 10.6172 32.3151 11.7346 35.6292C12.0106 36.4475 12.5193 37.3301 13.5378 39.0941C14.5563 40.8582 15.0662 41.7401 15.637 42.3882C17.9483 45.0128 21.6091 45.9938 24.923 44.8764C25.7414 44.6004 26.6233 44.0909 28.3875 43.0724L38.5362 37.213C40.3004 36.1945 41.1826 35.6854 41.8308 35.1147C44.4555 32.8034 45.4363 29.1426 44.319 25.8286C44.043 25.0103 43.5343 24.1277 42.5158 22.3637C41.4974 20.5997 40.9873 19.7177 40.4166 19.0696C38.1053 16.4448 34.4441 15.4631 31.1301 16.5806C30.3118 16.8565 29.4297 17.3661 27.6656 18.3846L17.5169 24.2439Z" fill="white"></path><rect x="18.4944" y="31.334" width="4.00904" height="8.32646" rx="2.00452" transform="rotate(-30 18.4944 31.334)" fill="white"></rect><rect x="29.311" y="25.0898" width="4.00904" height="8.32646" rx="2.00452" transform="rotate(-30 29.311 25.0898)" fill="white"></rect></g><defs><clipPath id="clip0_4958_10776"><rect x="-0.00146484" width="40" height="40" rx="8.63158" fill="white"></rect></clipPath></defs></svg>';
|
|
15928
|
+
|
|
15929
|
+
// src/assets/cursor-agent.svg
|
|
15930
|
+
var cursor_agent_default = 'data:image/svg+xml,<svg fill="none" height="512" viewBox="0 0 512 512" width="512" xmlns="http://www.w3.org/2000/svg"><path d="m512 325.5c0 7.124 0 14.24-.041 21.364-.034 5.999-.103 11.998-.268 17.99-.356 13.068-1.124 26.245-3.448 39.169-2.359 13.109-6.205 25.306-12.266 37.222-5.958 11.703-13.746 22.419-23.029 31.709-9.29 9.29-20 17.072-31.71 23.03-11.909 6.061-24.113 9.907-37.222 12.266-12.923 2.324-26.101 3.092-39.169 3.448-5.999.165-11.991.233-17.99.268-7.123.048-14.24.041-21.364.041h-139c-7.124 0-14.24 0-21.364-.041-5.999-.035-11.998-.103-17.99-.268-13.068-.356-26.245-1.124-39.169-3.448-13.109-2.359-25.306-6.205-37.2219-12.266-11.7033-5.958-22.4194-13.746-31.7095-23.03-9.29-9.29-17.0717-19.999-23.0296-31.709-6.0608-11.909-9.90707-24.113-12.26557-37.222-2.32422-12.924-3.0921-26.101-3.448618-39.169-.164546-5.999-.2331071-11.991-.2673876-17.99-.0274244-7.124-.0274244-14.24-.0274244-21.364v-139c0-7.124 0-14.24.0411366-21.364.0342805-5.999.1028414-11.998.2673884-17.99.356517-13.068 1.124405-26.245 3.448615-39.169 2.3585-13.1091 6.20478-25.3061 12.26556-37.222 5.958-11.7034 13.7465-22.4195 23.0297-31.7095 9.29-9.29 19.9992-17.0717 31.7094-23.0296 11.9091-6.06084 24.1129-9.90711 37.2222-12.26561 12.923-2.32422 26.101-3.092104 39.169-3.448622 5.999-.164546 11.991-.233107 17.99-.2673875 7.117-.0342805 14.233-.0342805 21.357-.0342805h139c7.124 0 14.24 0 21.364.0411366 5.999.0342805 11.998.1028414 17.99.2673884 13.068.356517 26.245 1.124405 39.169 3.448615 13.109 2.3585 25.306 6.20478 37.222 12.26556 11.703 5.958 22.419 13.7465 31.709 23.0297 9.29 9.29 17.072 19.9992 23.03 31.7094 6.061 11.9091 9.907 24.1129 12.266 37.2222 2.324 12.923 3.092 26.101 3.448 39.169.165 5.999.233 11.991.268 17.99.048 7.123.041 14.24.041 21.364v139z" fill="%2314120b"/><path d="m186.5 4h139c7.125 0 14.231-.00004 21.341.04102 5.985.0342 11.952.10221 17.903.26562h.001c13.003.35475 25.943 1.11709 38.569 3.3877 12.775 2.29827 24.592 6.03146 36.118 11.89356v-.001c10.974 5.5867 21.052 12.8384 29.848 21.457l.847.8379c8.993 8.993 16.525 19.3594 22.292 30.6934v.001c5.678 11.1575 9.36 22.6023 11.674 34.9208l.219 1.195c2.129 11.837 2.932 23.95 3.316 36.132l.072 2.438c.164 5.958.232 11.919.266 17.904v.004c.048 7.107.041 14.207.041 21.337v129.344l-.007-.007v9.656c0 7.125 0 14.231-.041 21.341-.034 5.985-.102 11.952-.266 17.903v.001c-.354 13.003-1.117 25.943-3.387 38.569-2.227 12.376-5.8 23.853-11.351 35.037l-.543 1.08c-5.766 11.327-13.306 21.701-22.293 30.695-8.993 8.993-19.361 16.526-30.695 22.293-11.518 5.861-23.342 9.595-36.116 11.893-11.837 2.129-23.95 2.932-36.132 3.316l-2.438.072c-5.958.164-11.919.232-17.904.266h-.004c-7.107.048-14.207.041-21.337.041h-139c-7.125 0-14.231 0-21.341-.041-5.985-.034-11.952-.102-17.903-.266h-.001c-13.003-.355-25.944-1.117-38.57-3.388-12.7742-2.298-24.5914-6.031-36.1165-11.893h.001c-10.974-5.587-21.0534-12.837-29.8496-21.456l-.8467-.838c-8.7118-8.712-16.0531-18.713-21.7461-29.634l-.5459-1.06-.5439-1.081c-5.371-10.816-8.8905-21.919-11.12991-33.84l-.21973-1.196c-2.27061-12.626-3.03294-25.566-3.38769-38.569v-.001c-.16341-5.958-.23142-11.918-.26563-17.903-.02736-7.112-.02734-14.219-.02734-21.341v-139c0-7.125-.00004-14.231.04102-21.341.0342-5.985.10221-11.952.26562-17.903v-.001c.35476-13.003 1.117-25.944 3.3877-38.57 2.29828-12.7744 6.03156-24.5916 11.89356-36.1166l-.001-.001c5.7666-11.327 13.3073-21.6999 22.294-30.6934 8.9933-8.9933 19.3607-16.5261 30.6953-22.2929 11.5173-5.8615 23.3406-9.59619 36.1148-11.89458 11.837-2.12877 23.951-2.93016 36.133-3.31445l2.438-.07227c5.958-.16342 11.919-.23142 17.904-.26562l-.001-.00098c7.104-.03421 14.211-.0332 21.335-.0332z" stroke="%23edecec" stroke-opacity=".2" stroke-width="8"/><path d="m415.035 156.35-151.503-87.4695c-4.865-2.8094-10.868-2.8094-15.733 0l-151.4969 87.4695c-4.0897 2.362-6.6146 6.729-6.6146 11.459v176.383c0 4.73 2.5249 9.097 6.6146 11.458l151.5039 87.47c4.865 2.809 10.868 2.809 15.733 0l151.504-87.47c4.089-2.361 6.614-6.728 6.614-11.458v-176.383c0-4.73-2.525-9.097-6.614-11.459zm-9.516 18.528-146.255 253.32c-.988 1.707-3.599 1.01-3.599-.967v-165.872c0-3.314-1.771-6.379-4.644-8.044l-143.645-82.932c-1.707-.988-1.01-3.599.968-3.599h292.509c4.154 0 6.75 4.503 4.673 8.101h-.007z" fill="%23edecec"/></svg>';
|
|
15931
|
+
|
|
15920
15932
|
// src/assets/omp-agent.svg
|
|
15921
15933
|
var omp_agent_default = 'data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 64 64">%0A <defs>%0A <linearGradient id="omp-gradient" x1="0" y1="0" x2="1" y2="1">%0A <stop offset="0" stop-color="%23ed4abf" />%0A <stop offset=".5" stop-color="%239b4dff" />%0A <stop offset="1" stop-color="%235ad8e6" />%0A </linearGradient>%0A </defs>%0A <path%0A fill="url(%23omp-gradient)"%0A transform="translate(-14.4 -20.2) scale(1.45)"%0A d="M14 16h36v8H40v32h-8V24h-6v22h-8V24h-4z"%0A />%0A</svg>%0A';
|
|
15922
15934
|
|
|
@@ -15935,7 +15947,9 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
15935
15947
|
antigravity: "Antigravity CLI",
|
|
15936
15948
|
hermes: "Hermes",
|
|
15937
15949
|
muse: "Meta Muse Code",
|
|
15938
|
-
"kiro-cli": "Kiro CLI"
|
|
15950
|
+
"kiro-cli": "Kiro CLI",
|
|
15951
|
+
codebuddy: "CodeBuddy",
|
|
15952
|
+
"cursor-cli": "Cursor CLI (Experimental)"
|
|
15939
15953
|
};
|
|
15940
15954
|
var PI_PATHS = [
|
|
15941
15955
|
{
|
|
@@ -16010,9 +16024,9 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
16010
16024
|
image.style.flex = "none";
|
|
16011
16025
|
return image;
|
|
16012
16026
|
}
|
|
16013
|
-
if (agent === "antigravity") {
|
|
16027
|
+
if (agent === "antigravity" || agent === "kiro-cli" || agent === "codebuddy" || agent === "cursor-cli") {
|
|
16014
16028
|
const image = ownerDocument.createElement("img");
|
|
16015
|
-
image.src = antigravity_agent_default;
|
|
16029
|
+
image.src = agent === "codebuddy" ? codebuddy_agent_default : agent === "cursor-cli" ? cursor_agent_default : agent === "kiro-cli" ? kiro_agent_default : antigravity_agent_default;
|
|
16016
16030
|
image.alt = "";
|
|
16017
16031
|
image.draggable = false;
|
|
16018
16032
|
image.style.width = `${size}px`;
|
|
@@ -16029,17 +16043,10 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
16029
16043
|
image.style.width = `${size}px`;
|
|
16030
16044
|
image.style.height = `${size}px`;
|
|
16031
16045
|
image.style.objectFit = "contain";
|
|
16032
|
-
image.style.
|
|
16033
|
-
|
|
16034
|
-
|
|
16035
|
-
|
|
16036
|
-
const image = ownerDocument.createElement("img");
|
|
16037
|
-
image.src = kiro_agent_default;
|
|
16038
|
-
image.alt = "";
|
|
16039
|
-
image.draggable = false;
|
|
16040
|
-
image.style.width = `${size}px`;
|
|
16041
|
-
image.style.height = `${size}px`;
|
|
16042
|
-
image.style.objectFit = "contain";
|
|
16046
|
+
image.style.boxSizing = "border-box";
|
|
16047
|
+
image.style.padding = `${Math.max(1, Math.round(size / 16))}px`;
|
|
16048
|
+
image.style.borderRadius = "22.37%";
|
|
16049
|
+
image.style.background = "#d8d8e8";
|
|
16043
16050
|
image.style.flex = "none";
|
|
16044
16051
|
return image;
|
|
16045
16052
|
}
|
|
@@ -16067,6 +16074,51 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
16067
16074
|
return mark;
|
|
16068
16075
|
}
|
|
16069
16076
|
|
|
16077
|
+
// src/renderer-picker-popover-style.ts
|
|
16078
|
+
var STYLE_ATTRIBUTE = "data-codexhost-picker-popover-style";
|
|
16079
|
+
var PICKER_POPOVER_CLASS = "codexhost-picker-popover";
|
|
16080
|
+
var PICKER_POPOVER_BORDER_LIGHT = "#EFEFEF";
|
|
16081
|
+
var PICKER_POPOVER_BORDER_DARK = "#424242";
|
|
16082
|
+
var PICKER_POPOVER_BACKGROUND_DARK = "#2D2D2D";
|
|
16083
|
+
var PICKER_POPOVER_BACKGROUND = `light-dark(Canvas, ${PICKER_POPOVER_BACKGROUND_DARK})`;
|
|
16084
|
+
var PICKER_POPOVER_BORDER = `light-dark(${PICKER_POPOVER_BORDER_LIGHT}, ${PICKER_POPOVER_BORDER_DARK})`;
|
|
16085
|
+
var PICKER_POPOVER_RADIUS = "24px";
|
|
16086
|
+
function ensureRendererPickerPopoverStyle(ownerDocument) {
|
|
16087
|
+
if (ownerDocument.querySelector(`style[${STYLE_ATTRIBUTE}]`)) return;
|
|
16088
|
+
const style = ownerDocument.createElement("style");
|
|
16089
|
+
style.setAttribute(STYLE_ATTRIBUTE, "true");
|
|
16090
|
+
style.textContent = `
|
|
16091
|
+
.${PICKER_POPOVER_CLASS} {
|
|
16092
|
+
box-sizing: border-box;
|
|
16093
|
+
border: 1px solid ${PICKER_POPOVER_BORDER};
|
|
16094
|
+
border-radius: ${PICKER_POPOVER_RADIUS};
|
|
16095
|
+
background: ${PICKER_POPOVER_BACKGROUND};
|
|
16096
|
+
color: CanvasText;
|
|
16097
|
+
box-shadow: none;
|
|
16098
|
+
backdrop-filter: none;
|
|
16099
|
+
-webkit-backdrop-filter: none;
|
|
16100
|
+
}
|
|
16101
|
+
.${PICKER_POPOVER_CLASS} :is(input, textarea) {
|
|
16102
|
+
border: 1px solid ${PICKER_POPOVER_BORDER};
|
|
16103
|
+
background: ${PICKER_POPOVER_BACKGROUND};
|
|
16104
|
+
color: inherit;
|
|
16105
|
+
box-shadow: none;
|
|
16106
|
+
}
|
|
16107
|
+
`;
|
|
16108
|
+
(ownerDocument.head ?? ownerDocument.documentElement).append(style);
|
|
16109
|
+
}
|
|
16110
|
+
function applyRendererPickerPopoverSurface(element) {
|
|
16111
|
+
ensureRendererPickerPopoverStyle(element.ownerDocument);
|
|
16112
|
+
element.classList.add(PICKER_POPOVER_CLASS);
|
|
16113
|
+
element.style.border = `1px solid ${PICKER_POPOVER_BORDER}`;
|
|
16114
|
+
element.style.borderRadius = PICKER_POPOVER_RADIUS;
|
|
16115
|
+
element.style.background = PICKER_POPOVER_BACKGROUND;
|
|
16116
|
+
element.style.color = "CanvasText";
|
|
16117
|
+
element.style.boxShadow = "none";
|
|
16118
|
+
element.style.backdropFilter = "none";
|
|
16119
|
+
element.style.setProperty("-webkit-backdrop-filter", "none");
|
|
16120
|
+
}
|
|
16121
|
+
|
|
16070
16122
|
// ../../node_modules/lucide/dist/esm/defaultAttributes.mjs
|
|
16071
16123
|
var defaultAttributes = {
|
|
16072
16124
|
xmlns: "http://www.w3.org/2000/svg",
|
|
@@ -16540,279 +16592,6 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
16540
16592
|
return icon2;
|
|
16541
16593
|
}
|
|
16542
16594
|
|
|
16543
|
-
// src/renderer-codex-account-options.ts
|
|
16544
|
-
var ACCOUNT_COLORS = ["#5b38c9", "#239b88", "#ce6724", "#2878c7", "#b34778", "#65752a"];
|
|
16545
|
-
function shouldExpandCodexAccountOptions(accountCount) {
|
|
16546
|
-
return accountCount > 1;
|
|
16547
|
-
}
|
|
16548
|
-
function codexAccountAuthKind(account) {
|
|
16549
|
-
if (account.authKind === "api" || account.authKind === "chatgpt") return account.authKind;
|
|
16550
|
-
return account.email ? "chatgpt" : "api";
|
|
16551
|
-
}
|
|
16552
|
-
function formatCodexAccountAuthLabel(account, messages) {
|
|
16553
|
-
if (codexAccountAuthKind(account) === "api") {
|
|
16554
|
-
const identity2 = account.authIdentity?.trim() || messages.accountAuthApiIdentityFallback;
|
|
16555
|
-
return `${messages.accountAuthApiPrefix} - ${identity2}`;
|
|
16556
|
-
}
|
|
16557
|
-
const identity = account.email ?? account.authIdentity;
|
|
16558
|
-
if (!identity) return `${messages.accountAuthChatPrefix} - ${account.label}`;
|
|
16559
|
-
return `${messages.accountAuthChatPrefix} - ${identity}`;
|
|
16560
|
-
}
|
|
16561
|
-
function codexAccountDisplayName(account) {
|
|
16562
|
-
const full = account.email ?? account.label;
|
|
16563
|
-
const separator = account.email?.lastIndexOf("@") ?? -1;
|
|
16564
|
-
if (!account.email || separator <= 0 || separator === account.email.length - 1) {
|
|
16565
|
-
return { local: full, domain: null, full };
|
|
16566
|
-
}
|
|
16567
|
-
return {
|
|
16568
|
-
local: account.email.slice(0, separator),
|
|
16569
|
-
domain: account.email.slice(separator + 1),
|
|
16570
|
-
full
|
|
16571
|
-
};
|
|
16572
|
-
}
|
|
16573
|
-
function codexAccountPresentationSignature(accounts) {
|
|
16574
|
-
return accounts.map(
|
|
16575
|
-
({ accountId, label, email: email3, authKind, authIdentity }) => `${accountId}\0${label}\0${email3 ?? ""}\0${authKind ?? ""}\0${authIdentity ?? ""}`
|
|
16576
|
-
).join("");
|
|
16577
|
-
}
|
|
16578
|
-
function accountColor(accountId) {
|
|
16579
|
-
let hash2 = 0;
|
|
16580
|
-
for (const character of accountId) hash2 = hash2 * 31 + character.charCodeAt(0) >>> 0;
|
|
16581
|
-
return ACCOUNT_COLORS[hash2 % ACCOUNT_COLORS.length] ?? ACCOUNT_COLORS[0];
|
|
16582
|
-
}
|
|
16583
|
-
function accountInitial(account) {
|
|
16584
|
-
const display = codexAccountDisplayName(account).local.trim();
|
|
16585
|
-
return display.match(/[\p{L}\p{N}]/u)?.[0]?.toUpperCase() ?? "?";
|
|
16586
|
-
}
|
|
16587
|
-
function setInteractiveHighlight(button) {
|
|
16588
|
-
const update = (hovered) => {
|
|
16589
|
-
const selected = button.getAttribute("aria-checked") === "true";
|
|
16590
|
-
button.style.background = selected || hovered && !button.disabled ? `rgba(127, 127, 127, ${selected ? "0.16" : "0.1"})` : "transparent";
|
|
16591
|
-
};
|
|
16592
|
-
button.addEventListener("pointerenter", () => update(true));
|
|
16593
|
-
button.addEventListener("pointerleave", () => update(false));
|
|
16594
|
-
button.addEventListener("focus", () => update(true));
|
|
16595
|
-
button.addEventListener("blur", () => update(false));
|
|
16596
|
-
}
|
|
16597
|
-
function createRendererCodexAccountGroup(input) {
|
|
16598
|
-
const { ownerDocument: document2 } = input;
|
|
16599
|
-
const root = document2.createElement("div");
|
|
16600
|
-
root.dataset.codexAccountOptions = "true";
|
|
16601
|
-
root.hidden = true;
|
|
16602
|
-
const accountSection = document2.createElement("div");
|
|
16603
|
-
accountSection.setAttribute("role", "group");
|
|
16604
|
-
accountSection.setAttribute("aria-label", input.accountsLabel);
|
|
16605
|
-
accountSection.style.position = "relative";
|
|
16606
|
-
const header = document2.createElement("div");
|
|
16607
|
-
header.style.position = "relative";
|
|
16608
|
-
header.style.display = "flex";
|
|
16609
|
-
header.style.alignItems = "center";
|
|
16610
|
-
header.style.gap = "8px";
|
|
16611
|
-
header.style.height = "36px";
|
|
16612
|
-
header.style.padding = PICKER_ROW_PADDING;
|
|
16613
|
-
header.style.color = "inherit";
|
|
16614
|
-
header.style.font = "600 12px/1 system-ui, sans-serif";
|
|
16615
|
-
header.style.opacity = "0.72";
|
|
16616
|
-
const headerIcon = document2.createElement("span");
|
|
16617
|
-
headerIcon.setAttribute("aria-hidden", "true");
|
|
16618
|
-
headerIcon.style.display = "inline-flex";
|
|
16619
|
-
headerIcon.style.alignItems = "center";
|
|
16620
|
-
headerIcon.style.justifyContent = "center";
|
|
16621
|
-
headerIcon.style.width = "24px";
|
|
16622
|
-
headerIcon.style.height = "24px";
|
|
16623
|
-
headerIcon.style.flex = "none";
|
|
16624
|
-
headerIcon.append(createRendererAgentIcon("codex", 16, document2));
|
|
16625
|
-
header.append(headerIcon, input.accountsLabel);
|
|
16626
|
-
const list = document2.createElement("div");
|
|
16627
|
-
list.style.display = "flex";
|
|
16628
|
-
list.style.flexDirection = "column";
|
|
16629
|
-
list.style.gap = "2px";
|
|
16630
|
-
list.style.maxHeight = "132px";
|
|
16631
|
-
list.style.marginBottom = "4px";
|
|
16632
|
-
list.style.paddingLeft = "14px";
|
|
16633
|
-
list.style.overflowY = "auto";
|
|
16634
|
-
list.style.scrollbarWidth = "thin";
|
|
16635
|
-
const manage = document2.createElement("button");
|
|
16636
|
-
manage.type = "button";
|
|
16637
|
-
manage.dataset.codexAccountManage = "true";
|
|
16638
|
-
manage.setAttribute("role", "menuitem");
|
|
16639
|
-
manage.setAttribute("aria-label", input.manageAccountsLabel);
|
|
16640
|
-
manage.title = input.manageAccountsLabel;
|
|
16641
|
-
applyPickerTrailingSlot(manage);
|
|
16642
|
-
manage.style.border = "0";
|
|
16643
|
-
manage.style.borderRadius = "4px";
|
|
16644
|
-
manage.style.background = "transparent";
|
|
16645
|
-
manage.style.color = "inherit";
|
|
16646
|
-
manage.style.opacity = "0.72";
|
|
16647
|
-
manage.style.cursor = "pointer";
|
|
16648
|
-
manage.append(createPickerChromeIcon("ellipsis"));
|
|
16649
|
-
manage.addEventListener("pointerenter", () => {
|
|
16650
|
-
manage.style.background = "rgba(127, 127, 127, 0.1)";
|
|
16651
|
-
manage.style.opacity = "1";
|
|
16652
|
-
});
|
|
16653
|
-
manage.addEventListener("pointerleave", () => {
|
|
16654
|
-
manage.style.background = "transparent";
|
|
16655
|
-
manage.style.opacity = "0.72";
|
|
16656
|
-
});
|
|
16657
|
-
manage.addEventListener("click", input.onManage);
|
|
16658
|
-
header.append(manage);
|
|
16659
|
-
accountSection.append(header, list);
|
|
16660
|
-
root.append(accountSection);
|
|
16661
|
-
const badge = document2.createElement("span");
|
|
16662
|
-
badge.setAttribute("aria-hidden", "true");
|
|
16663
|
-
badge.style.display = "none";
|
|
16664
|
-
badge.style.position = "absolute";
|
|
16665
|
-
badge.style.right = "1px";
|
|
16666
|
-
badge.style.bottom = "0";
|
|
16667
|
-
badge.style.width = "9px";
|
|
16668
|
-
badge.style.height = "9px";
|
|
16669
|
-
badge.style.border = "1.5px solid Canvas";
|
|
16670
|
-
badge.style.borderRadius = "50%";
|
|
16671
|
-
badge.style.pointerEvents = "none";
|
|
16672
|
-
const options = /* @__PURE__ */ new Map();
|
|
16673
|
-
let accounts = [];
|
|
16674
|
-
let presentationSignature = "";
|
|
16675
|
-
const rebuild = (nextAccounts) => {
|
|
16676
|
-
list.replaceChildren();
|
|
16677
|
-
options.clear();
|
|
16678
|
-
for (const account of nextAccounts) {
|
|
16679
|
-
const row = document2.createElement("div");
|
|
16680
|
-
const button = document2.createElement("button");
|
|
16681
|
-
button.type = "button";
|
|
16682
|
-
button.dataset.codexAccountId = account.accountId;
|
|
16683
|
-
button.setAttribute("role", "menuitemradio");
|
|
16684
|
-
button.style.display = "flex";
|
|
16685
|
-
button.style.alignItems = "center";
|
|
16686
|
-
button.style.gap = "8px";
|
|
16687
|
-
button.style.width = "100%";
|
|
16688
|
-
button.style.height = "36px";
|
|
16689
|
-
button.style.padding = PICKER_ROW_PADDING;
|
|
16690
|
-
button.style.color = "inherit";
|
|
16691
|
-
button.style.background = "transparent";
|
|
16692
|
-
button.style.border = "0";
|
|
16693
|
-
button.style.borderRadius = "5px";
|
|
16694
|
-
button.style.textAlign = "left";
|
|
16695
|
-
button.style.cursor = "pointer";
|
|
16696
|
-
setInteractiveHighlight(button);
|
|
16697
|
-
const avatar = document2.createElement("span");
|
|
16698
|
-
avatar.textContent = accountInitial(account);
|
|
16699
|
-
avatar.style.display = "inline-flex";
|
|
16700
|
-
avatar.style.alignItems = "center";
|
|
16701
|
-
avatar.style.justifyContent = "center";
|
|
16702
|
-
avatar.style.width = "20px";
|
|
16703
|
-
avatar.style.height = "20px";
|
|
16704
|
-
avatar.style.color = "#fff";
|
|
16705
|
-
avatar.style.background = accountColor(account.accountId);
|
|
16706
|
-
avatar.style.borderRadius = "50%";
|
|
16707
|
-
avatar.style.font = "700 10px/1 system-ui, sans-serif";
|
|
16708
|
-
const authLabel = formatCodexAccountAuthLabel(account, input.messages);
|
|
16709
|
-
const name = document2.createElement("span");
|
|
16710
|
-
name.style.display = "flex";
|
|
16711
|
-
name.style.alignItems = "baseline";
|
|
16712
|
-
name.style.minWidth = "0";
|
|
16713
|
-
name.style.gap = "4px";
|
|
16714
|
-
const local = document2.createElement("strong");
|
|
16715
|
-
local.textContent = authLabel;
|
|
16716
|
-
local.style.minWidth = "0";
|
|
16717
|
-
local.style.overflow = "hidden";
|
|
16718
|
-
local.style.font = "600 13px/1 system-ui, sans-serif";
|
|
16719
|
-
local.style.textOverflow = "ellipsis";
|
|
16720
|
-
local.style.whiteSpace = "nowrap";
|
|
16721
|
-
name.append(local);
|
|
16722
|
-
const check2 = document2.createElement("span");
|
|
16723
|
-
check2.dataset.codexhostAgentTrailing = "check";
|
|
16724
|
-
check2.setAttribute("aria-hidden", "true");
|
|
16725
|
-
applyPickerTrailingSlot(check2);
|
|
16726
|
-
check2.style.visibility = "hidden";
|
|
16727
|
-
check2.style.pointerEvents = "none";
|
|
16728
|
-
check2.append(createPickerChromeIcon("tick"));
|
|
16729
|
-
button.title = authLabel;
|
|
16730
|
-
button.setAttribute("aria-label", `${input.accountsLabel}: ${authLabel}`);
|
|
16731
|
-
button.append(avatar, name);
|
|
16732
|
-
button.addEventListener("click", () => input.onSelect(account.accountId));
|
|
16733
|
-
row.style.position = "relative";
|
|
16734
|
-
row.append(button, check2);
|
|
16735
|
-
list.append(row);
|
|
16736
|
-
options.set(account.accountId, { row, button, check: check2, action: null });
|
|
16737
|
-
}
|
|
16738
|
-
presentationSignature = codexAccountPresentationSignature(nextAccounts);
|
|
16739
|
-
};
|
|
16740
|
-
const control = {
|
|
16741
|
-
root,
|
|
16742
|
-
badge,
|
|
16743
|
-
options,
|
|
16744
|
-
accounts,
|
|
16745
|
-
render({ accounts: nextAccounts, selectedAccountId, disabled, showBadge }) {
|
|
16746
|
-
const nextSignature = codexAccountPresentationSignature(nextAccounts);
|
|
16747
|
-
if (nextSignature !== presentationSignature) rebuild(nextAccounts);
|
|
16748
|
-
accounts = [...nextAccounts];
|
|
16749
|
-
control.accounts = accounts;
|
|
16750
|
-
root.hidden = accounts.length === 0;
|
|
16751
|
-
const selectedAccount = accounts.find(({ accountId }) => accountId === selectedAccountId);
|
|
16752
|
-
badge.style.display = showBadge && selectedAccount ? "block" : "none";
|
|
16753
|
-
if (selectedAccount) badge.style.background = accountColor(selectedAccount.accountId);
|
|
16754
|
-
for (const account of accounts) {
|
|
16755
|
-
const option = options.get(account.accountId);
|
|
16756
|
-
if (!option) continue;
|
|
16757
|
-
const selected = account.accountId === selectedAccountId;
|
|
16758
|
-
option.button.disabled = disabled;
|
|
16759
|
-
option.button.setAttribute("aria-checked", String(selected));
|
|
16760
|
-
option.button.setAttribute("aria-pressed", String(selected));
|
|
16761
|
-
option.button.style.background = selected ? "rgba(127, 127, 127, 0.16)" : "transparent";
|
|
16762
|
-
option.button.style.cursor = disabled ? "not-allowed" : "pointer";
|
|
16763
|
-
option.button.style.opacity = disabled && !selected ? "0.5" : "1";
|
|
16764
|
-
option.check.style.visibility = selected ? "visible" : "hidden";
|
|
16765
|
-
}
|
|
16766
|
-
}
|
|
16767
|
-
};
|
|
16768
|
-
return control;
|
|
16769
|
-
}
|
|
16770
|
-
|
|
16771
|
-
// src/renderer-picker-popover-style.ts
|
|
16772
|
-
var STYLE_ATTRIBUTE = "data-codexhost-picker-popover-style";
|
|
16773
|
-
var PICKER_POPOVER_CLASS = "codexhost-picker-popover";
|
|
16774
|
-
var PICKER_POPOVER_BORDER_LIGHT = "#EFEFEF";
|
|
16775
|
-
var PICKER_POPOVER_BORDER_DARK = "#424242";
|
|
16776
|
-
var PICKER_POPOVER_BACKGROUND_DARK = "#2D2D2D";
|
|
16777
|
-
var PICKER_POPOVER_BACKGROUND = `light-dark(Canvas, ${PICKER_POPOVER_BACKGROUND_DARK})`;
|
|
16778
|
-
var PICKER_POPOVER_BORDER = `light-dark(${PICKER_POPOVER_BORDER_LIGHT}, ${PICKER_POPOVER_BORDER_DARK})`;
|
|
16779
|
-
var PICKER_POPOVER_RADIUS = "24px";
|
|
16780
|
-
function ensureRendererPickerPopoverStyle(ownerDocument) {
|
|
16781
|
-
if (ownerDocument.querySelector(`style[${STYLE_ATTRIBUTE}]`)) return;
|
|
16782
|
-
const style = ownerDocument.createElement("style");
|
|
16783
|
-
style.setAttribute(STYLE_ATTRIBUTE, "true");
|
|
16784
|
-
style.textContent = `
|
|
16785
|
-
.${PICKER_POPOVER_CLASS} {
|
|
16786
|
-
box-sizing: border-box;
|
|
16787
|
-
border: 1px solid ${PICKER_POPOVER_BORDER};
|
|
16788
|
-
border-radius: ${PICKER_POPOVER_RADIUS};
|
|
16789
|
-
background: ${PICKER_POPOVER_BACKGROUND};
|
|
16790
|
-
color: CanvasText;
|
|
16791
|
-
box-shadow: none;
|
|
16792
|
-
backdrop-filter: none;
|
|
16793
|
-
-webkit-backdrop-filter: none;
|
|
16794
|
-
}
|
|
16795
|
-
.${PICKER_POPOVER_CLASS} :is(input, textarea) {
|
|
16796
|
-
border: 1px solid ${PICKER_POPOVER_BORDER};
|
|
16797
|
-
background: ${PICKER_POPOVER_BACKGROUND};
|
|
16798
|
-
color: inherit;
|
|
16799
|
-
box-shadow: none;
|
|
16800
|
-
}
|
|
16801
|
-
`;
|
|
16802
|
-
(ownerDocument.head ?? ownerDocument.documentElement).append(style);
|
|
16803
|
-
}
|
|
16804
|
-
function applyRendererPickerPopoverSurface(element) {
|
|
16805
|
-
ensureRendererPickerPopoverStyle(element.ownerDocument);
|
|
16806
|
-
element.classList.add(PICKER_POPOVER_CLASS);
|
|
16807
|
-
element.style.border = `1px solid ${PICKER_POPOVER_BORDER}`;
|
|
16808
|
-
element.style.borderRadius = PICKER_POPOVER_RADIUS;
|
|
16809
|
-
element.style.background = PICKER_POPOVER_BACKGROUND;
|
|
16810
|
-
element.style.color = "CanvasText";
|
|
16811
|
-
element.style.boxShadow = "none";
|
|
16812
|
-
element.style.backdropFilter = "none";
|
|
16813
|
-
element.style.setProperty("-webkit-backdrop-filter", "none");
|
|
16814
|
-
}
|
|
16815
|
-
|
|
16816
16595
|
// src/settings/harness-install.ts
|
|
16817
16596
|
var HARNESS_INSTALL_SPECS = Object.freeze({
|
|
16818
16597
|
pi: {
|
|
@@ -16874,6 +16653,18 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
16874
16653
|
binary: "kiro-cli",
|
|
16875
16654
|
posix: "curl -fsSL https://cli.kiro.dev/install | bash",
|
|
16876
16655
|
windows: "irm 'https://cli.kiro.dev/install.ps1' | iex"
|
|
16656
|
+
},
|
|
16657
|
+
codebuddy: {
|
|
16658
|
+
url: "https://www.codebuddy.ai/docs/zh/cli/overview",
|
|
16659
|
+
binary: "codebuddy",
|
|
16660
|
+
posix: "npm install -g @tencent-ai/codebuddy-code",
|
|
16661
|
+
windows: "npm install -g @tencent-ai/codebuddy-code"
|
|
16662
|
+
},
|
|
16663
|
+
"cursor-cli": {
|
|
16664
|
+
url: "https://cursor.com/docs/cli/installation",
|
|
16665
|
+
binary: "cursor-agent",
|
|
16666
|
+
posix: "curl https://cursor.com/install -fsS | bash",
|
|
16667
|
+
windows: "irm https://cursor.com/install.ps1 | iex"
|
|
16877
16668
|
}
|
|
16878
16669
|
});
|
|
16879
16670
|
function harnessInstallPlatform(window2) {
|
|
@@ -17733,41 +17524,25 @@ ${error51.stderrTail}`] : []
|
|
|
17733
17524
|
pluginsRefresh: "Scan environment",
|
|
17734
17525
|
pluginsRefreshing: "Scanning...",
|
|
17735
17526
|
connectionsDescription: "View runtime status by Host. Select an item to inspect details or complete its setup.",
|
|
17736
|
-
accountsDescription: "View
|
|
17527
|
+
accountsDescription: "View the current Codex identity and quotas, plus other Agent accounts.",
|
|
17737
17528
|
accountConnected: "Accounts",
|
|
17738
|
-
accountDefaultBadge: "
|
|
17739
|
-
accountAdd: "Add Codex account",
|
|
17529
|
+
accountDefaultBadge: "Current",
|
|
17740
17530
|
accountColumnAccount: "Account",
|
|
17741
17531
|
accountColumnActions: "Manage",
|
|
17532
|
+
accountColumnCredits: "Quota",
|
|
17742
17533
|
accountSearch: "Search accounts or Agents\u2026",
|
|
17743
|
-
accountEmpty: "No
|
|
17534
|
+
accountEmpty: "No current identities found. Sign in through Codex Desktop or your Harness's native client.",
|
|
17744
17535
|
accountNoMatches: "No matching accounts.",
|
|
17745
17536
|
accountNativeManaged: "Native management",
|
|
17746
17537
|
accountNativeManagementHint: "This account comes from {harness}'s native authentication. This page only displays identity and limits; manage sign-in, sign-out and switching in the native client.",
|
|
17747
|
-
accountMore: "Codex account actions",
|
|
17748
17538
|
accountDetailsClose: "Close account details",
|
|
17749
|
-
accountDefaultHint: "
|
|
17539
|
+
accountDefaultHint: "This is the current identity for all Codex Threads.",
|
|
17750
17540
|
accountCreditsRemaining: "Remaining",
|
|
17751
17541
|
accountCreditsLoading: "Loading limits\u2026",
|
|
17752
17542
|
accountCreditsEmpty: "No limit data available",
|
|
17753
17543
|
accountCreditsFailed: "Could not load limits",
|
|
17754
17544
|
accountCreditsRetry: "Retry",
|
|
17755
17545
|
accountCreditsRefresh: "Refresh limits",
|
|
17756
|
-
accountCreateFailed: "Could not add the Account.",
|
|
17757
|
-
accountDelete: "Delete",
|
|
17758
|
-
accountDeleteConfirm: "Delete this Account and its local data? This cannot be undone.",
|
|
17759
|
-
accountDeleting: "Deleting Account...",
|
|
17760
|
-
accountDeleteFailed: "Could not delete the Account.",
|
|
17761
|
-
accountActive: "Default",
|
|
17762
|
-
accountUse: "Set as default",
|
|
17763
|
-
accountSignIn: "Sign in",
|
|
17764
|
-
accountSigningIn: "Starting device sign-in...",
|
|
17765
|
-
accountVerificationDescription: "Open the verification page and enter this one-time code:",
|
|
17766
|
-
accountCopyCode: "Copy code",
|
|
17767
|
-
accountCopied: "Copied",
|
|
17768
|
-
accountLoginCancel: "Cancel sign-in",
|
|
17769
|
-
accountLoginSucceeded: "Sign-in completed.",
|
|
17770
|
-
accountLoginFailed: "Sign-in failed.",
|
|
17771
17546
|
accountLoadFailed: "Could not load Codex Accounts.",
|
|
17772
17547
|
accountAuthApiPrefix: "API",
|
|
17773
17548
|
accountAuthChatPrefix: "Account",
|
|
@@ -17786,14 +17561,6 @@ ${error51.stderrTail}`] : []
|
|
|
17786
17561
|
accountCreditsPeriodUnknown: "Limit",
|
|
17787
17562
|
accountCreditsBuild: "Build",
|
|
17788
17563
|
accountResetCredits: "Reset cards",
|
|
17789
|
-
accountResetCreditsUse: "Use reset",
|
|
17790
|
-
accountResetCreditsConfirm: "This uses 1 reset card and resets both the 5-hour and 7-day limits. This cannot be undone.",
|
|
17791
|
-
accountResetCreditsUsing: "Using reset card...",
|
|
17792
|
-
accountResetCreditsFailed: "Could not use the reset card.",
|
|
17793
|
-
accountResetCreditsNothingToReset: "Usage does not need a reset right now.",
|
|
17794
|
-
accountResetCreditsNoCredit: "No reset cards are available.",
|
|
17795
|
-
accountResetCreditsAlreadyRedeemed: "That reset card was already used.",
|
|
17796
|
-
accountResetCreditsSucceeded: "Limits were reset.",
|
|
17797
17564
|
accountResetCreditsDetails: "Reset card details",
|
|
17798
17565
|
accountResetCreditsCardExpiry: "Card {index} \xB7 expires {time}",
|
|
17799
17566
|
connectionAdapter: "Renderer adapter",
|
|
@@ -17969,41 +17736,25 @@ ${error51.stderrTail}`] : []
|
|
|
17969
17736
|
pluginsRefresh: "\u626B\u63CF\u73AF\u5883",
|
|
17970
17737
|
pluginsRefreshing: "\u6B63\u5728\u626B\u63CF...",
|
|
17971
17738
|
connectionsDescription: "\u6309 Host \u67E5\u770B\u8FD0\u884C\u65F6\u72B6\u6001\u3002\u9009\u62E9\u4E00\u9879\uFF0C\u5728\u53F3\u4FA7\u68C0\u67E5\u8BE6\u60C5\u6216\u5B8C\u6210\u914D\u7F6E\u3002",
|
|
17972
|
-
accountsDescription: "\u67E5\u770B\
|
|
17739
|
+
accountsDescription: "\u67E5\u770B\u5F53\u524D Codex \u8EAB\u4EFD\u4E0E\u989D\u5EA6\uFF0C\u4EE5\u53CA\u5176\u4ED6 Agent \u8D26\u53F7\u3002",
|
|
17973
17740
|
accountConnected: "\u8D26\u53F7",
|
|
17974
|
-
accountDefaultBadge: "
|
|
17975
|
-
accountAdd: "\u6DFB\u52A0 Codex \u8D26\u53F7",
|
|
17741
|
+
accountDefaultBadge: "\u5F53\u524D",
|
|
17976
17742
|
accountColumnAccount: "\u8D26\u53F7",
|
|
17977
17743
|
accountColumnActions: "\u7BA1\u7406",
|
|
17744
|
+
accountColumnCredits: "\u989D\u5EA6",
|
|
17978
17745
|
accountSearch: "\u641C\u7D22\u8D26\u53F7\u6216 Agent\u2026",
|
|
17979
|
-
accountEmpty: "\
|
|
17746
|
+
accountEmpty: "\u5C1A\u672A\u8BC6\u522B\u5230\u5F53\u524D\u8EAB\u4EFD\uFF0C\u8BF7\u5728 Codex Desktop \u6216\u5BF9\u5E94 Harness \u7684\u539F\u751F\u5BA2\u6237\u7AEF\u767B\u5F55\u3002",
|
|
17980
17747
|
accountNoMatches: "\u6CA1\u6709\u5339\u914D\u7684\u8D26\u53F7\u3002",
|
|
17981
17748
|
accountNativeManaged: "\u539F\u751F\u7BA1\u7406",
|
|
17982
17749
|
accountNativeManagementHint: "\u6B64\u8D26\u53F7\u6765\u81EA {harness} \u7684\u539F\u751F\u767B\u5F55\u3002\u8FD9\u91CC\u53EA\u8BFB\u5C55\u793A\u8EAB\u4EFD\u4E0E\u989D\u5EA6\uFF1B\u767B\u5F55\u3001\u9000\u51FA\u548C\u5207\u6362\u8BF7\u5728\u5176\u539F\u751F\u5BA2\u6237\u7AEF\u4E2D\u5B8C\u6210\u3002",
|
|
17983
|
-
accountMore: "Codex \u8D26\u53F7\u64CD\u4F5C",
|
|
17984
17750
|
accountDetailsClose: "\u5173\u95ED\u8D26\u53F7\u8BE6\u60C5",
|
|
17985
|
-
accountDefaultHint: "\
|
|
17751
|
+
accountDefaultHint: "\u6240\u6709 Codex \u4F1A\u8BDD\u5F53\u524D\u4F7F\u7528\u6B64\u8EAB\u4EFD\u3002",
|
|
17986
17752
|
accountCreditsRemaining: "\u5269\u4F59",
|
|
17987
17753
|
accountCreditsLoading: "\u6B63\u5728\u8BFB\u53D6\u989D\u5EA6\u2026",
|
|
17988
17754
|
accountCreditsEmpty: "\u6682\u65E0\u989D\u5EA6\u6570\u636E",
|
|
17989
17755
|
accountCreditsFailed: "\u989D\u5EA6\u8BFB\u53D6\u5931\u8D25",
|
|
17990
17756
|
accountCreditsRetry: "\u91CD\u8BD5",
|
|
17991
17757
|
accountCreditsRefresh: "\u5237\u65B0\u989D\u5EA6",
|
|
17992
|
-
accountCreateFailed: "\u6DFB\u52A0\u8D26\u53F7\u5931\u8D25\u3002",
|
|
17993
|
-
accountDelete: "\u5220\u9664",
|
|
17994
|
-
accountDeleteConfirm: "\u5220\u9664\u6B64\u8D26\u53F7\u53CA\u5176\u672C\u5730\u6570\u636E\uFF1F\u6B64\u64CD\u4F5C\u65E0\u6CD5\u64A4\u9500\u3002",
|
|
17995
|
-
accountDeleting: "\u6B63\u5728\u5220\u9664\u8D26\u53F7...",
|
|
17996
|
-
accountDeleteFailed: "\u5220\u9664\u8D26\u53F7\u5931\u8D25\u3002",
|
|
17997
|
-
accountActive: "\u9ED8\u8BA4\u8D26\u53F7",
|
|
17998
|
-
accountUse: "\u8BBE\u4E3A\u9ED8\u8BA4",
|
|
17999
|
-
accountSignIn: "\u767B\u5F55",
|
|
18000
|
-
accountSigningIn: "\u6B63\u5728\u542F\u52A8\u8BBE\u5907\u767B\u5F55...",
|
|
18001
|
-
accountVerificationDescription: "\u6253\u5F00\u9A8C\u8BC1\u9875\u9762\u5E76\u8F93\u5165\u4EE5\u4E0B\u4E00\u6B21\u6027\u4EE3\u7801\uFF1A",
|
|
18002
|
-
accountCopyCode: "\u590D\u5236\u4EE3\u7801",
|
|
18003
|
-
accountCopied: "\u5DF2\u590D\u5236",
|
|
18004
|
-
accountLoginCancel: "\u53D6\u6D88\u767B\u5F55",
|
|
18005
|
-
accountLoginSucceeded: "\u767B\u5F55\u6210\u529F\u3002",
|
|
18006
|
-
accountLoginFailed: "\u767B\u5F55\u5931\u8D25\u3002",
|
|
18007
17758
|
accountLoadFailed: "\u65E0\u6CD5\u52A0\u8F7D Codex \u8D26\u53F7\u3002",
|
|
18008
17759
|
accountAuthApiPrefix: "API",
|
|
18009
17760
|
accountAuthChatPrefix: "\u8D26\u53F7",
|
|
@@ -18022,14 +17773,6 @@ ${error51.stderrTail}`] : []
|
|
|
18022
17773
|
accountCreditsPeriodUnknown: "\u989D\u5EA6",
|
|
18023
17774
|
accountCreditsBuild: "Build",
|
|
18024
17775
|
accountResetCredits: "\u91CD\u7F6E\u5361",
|
|
18025
|
-
accountResetCreditsUse: "\u4F7F\u7528\u91CD\u7F6E",
|
|
18026
|
-
accountResetCreditsConfirm: "\u5C06\u6D88\u8017 1 \u5F20\u91CD\u7F6E\u5361\uFF0C\u540C\u65F6\u91CD\u7F6E 5 \u5C0F\u65F6\u548C 7 \u5929\u989D\u5EA6\u3002\u6B64\u64CD\u4F5C\u65E0\u6CD5\u64A4\u9500\u3002",
|
|
18027
|
-
accountResetCreditsUsing: "\u6B63\u5728\u4F7F\u7528\u91CD\u7F6E\u5361...",
|
|
18028
|
-
accountResetCreditsFailed: "\u4F7F\u7528\u91CD\u7F6E\u5361\u5931\u8D25\u3002",
|
|
18029
|
-
accountResetCreditsNothingToReset: "\u5F53\u524D\u989D\u5EA6\u4E0D\u9700\u8981\u91CD\u7F6E\u3002",
|
|
18030
|
-
accountResetCreditsNoCredit: "\u6CA1\u6709\u53EF\u7528\u7684\u91CD\u7F6E\u5361\u3002",
|
|
18031
|
-
accountResetCreditsAlreadyRedeemed: "\u8FD9\u5F20\u91CD\u7F6E\u5361\u5DF2\u7ECF\u4F7F\u7528\u8FC7\u3002",
|
|
18032
|
-
accountResetCreditsSucceeded: "\u989D\u5EA6\u5DF2\u91CD\u7F6E\u3002",
|
|
18033
17776
|
accountResetCreditsDetails: "\u91CD\u7F6E\u5361\u8BE6\u60C5",
|
|
18034
17777
|
accountResetCreditsCardExpiry: "\u7B2C {index} \u5F20 \xB7 {time}\u5230\u671F",
|
|
18035
17778
|
connectionAdapter: "Renderer \u9002\u914D\u5668",
|
|
@@ -18180,8 +17923,6 @@ ${error51.stderrTail}`] : []
|
|
|
18180
17923
|
const messages = rendererSettingsMessages(resolveRendererSettingsLocale(languages));
|
|
18181
17924
|
return {
|
|
18182
17925
|
...messages,
|
|
18183
|
-
codexAccountsLabel: "Codex",
|
|
18184
|
-
manageCodexAccountsLabel: messages.locale === "zh-CN" ? "\u7BA1\u7406 Codex \u8D26\u53F7" : "Manage Codex Accounts",
|
|
18185
17926
|
ownershipErrorLabel: messages.locale === "zh-CN" ? "\u65E0\u6CD5\u786E\u8BA4\u4F1A\u8BDD\u7684 Agent\uFF1B\u91CD\u65B0\u805A\u7126\u7A97\u53E3\u4EE5\u91CD\u8BD5" : "Unable to determine the Thread Agent; refocus the window to retry"
|
|
18186
17927
|
};
|
|
18187
17928
|
}
|
|
@@ -18200,9 +17941,11 @@ ${error51.stderrTail}`] : []
|
|
|
18200
17941
|
grok: "https://grok.com/",
|
|
18201
17942
|
omp: "https://github.com/can1357/oh-my-pi",
|
|
18202
17943
|
antigravity: "https://antigravity.google/product/antigravity-cli",
|
|
17944
|
+
"kiro-cli": "https://kiro.dev/docs/cli/",
|
|
17945
|
+
codebuddy: "https://www.codebuddy.ai/docs/zh/cli/overview",
|
|
17946
|
+
"cursor-cli": "https://cursor.com/docs/cli/installation",
|
|
18203
17947
|
hermes: "https://hermes-agent.nousresearch.com/docs",
|
|
18204
|
-
muse: "https://www.meta.ai/"
|
|
18205
|
-
"kiro-cli": "https://kiro.dev/docs/cli/"
|
|
17948
|
+
muse: "https://www.meta.ai/"
|
|
18206
17949
|
};
|
|
18207
17950
|
var CONTROL_ATTRIBUTE = "data-codexhost-agent-control";
|
|
18208
17951
|
var AGENT_MENU_WIDTH = 224;
|
|
@@ -18227,11 +17970,11 @@ ${error51.stderrTail}`] : []
|
|
|
18227
17970
|
checkVisible: input.selected && !actionVisible
|
|
18228
17971
|
};
|
|
18229
17972
|
}
|
|
18230
|
-
function rendererAgentPickerTooltip(state, activeAccount
|
|
18231
|
-
const account = state.agent === "codex" && activeAccount
|
|
17973
|
+
function rendererAgentPickerTooltip(state, activeAccount) {
|
|
17974
|
+
const account = state.agent === "codex" && activeAccount ? ` \xB7 ${activeAccount.email ?? activeAccount.label}` : "";
|
|
18232
17975
|
return `Agent: ${RENDERER_AGENT_LABELS[state.agent]}${account}${state.phase === "locked" ? " (locked)" : ""}`;
|
|
18233
17976
|
}
|
|
18234
|
-
function rendererAgentPickerView(state, adapterState, switching, agents, availability = {}
|
|
17977
|
+
function rendererAgentPickerView(state, adapterState, switching, agents, availability = {}) {
|
|
18235
17978
|
const optionDisabled = Object.fromEntries(
|
|
18236
17979
|
agents.map((agent) => [
|
|
18237
17980
|
agent,
|
|
@@ -18246,7 +17989,7 @@ ${error51.stderrTail}`] : []
|
|
|
18246
17989
|
);
|
|
18247
17990
|
return {
|
|
18248
17991
|
label: RENDERER_AGENT_LABELS[state.agent],
|
|
18249
|
-
triggerDisabled: switching || state.phase === "locked" || agents.length < 2
|
|
17992
|
+
triggerDisabled: switching || state.phase === "locked" || agents.length < 2,
|
|
18250
17993
|
nativeModelHidden: switching || state.agent !== "codex",
|
|
18251
17994
|
optionDisabled,
|
|
18252
17995
|
downloadVisible,
|
|
@@ -18271,7 +18014,7 @@ ${error51.stderrTail}`] : []
|
|
|
18271
18014
|
return !menu.hidden;
|
|
18272
18015
|
}
|
|
18273
18016
|
}
|
|
18274
|
-
function mountRendererAgentPicker(composerId, enabledAgents, onSelect, onDownload,
|
|
18017
|
+
function mountRendererAgentPicker(composerId, enabledAgents, onSelect, onDownload, onOpen, groupPreference = getSharedAgentGroupPreferenceStore()) {
|
|
18275
18018
|
const root = document.createElement("div");
|
|
18276
18019
|
root.setAttribute(CONTROL_ATTRIBUTE, composerId);
|
|
18277
18020
|
root.style.display = "inline-flex";
|
|
@@ -18354,24 +18097,6 @@ ${error51.stderrTail}`] : []
|
|
|
18354
18097
|
else menu.hidden = true;
|
|
18355
18098
|
trigger.setAttribute("aria-expanded", "false");
|
|
18356
18099
|
};
|
|
18357
|
-
const codexAccountGroup = createRendererCodexAccountGroup({
|
|
18358
|
-
ownerDocument: document,
|
|
18359
|
-
accountsLabel: groupMessages.codexAccountsLabel,
|
|
18360
|
-
manageAccountsLabel: groupMessages.manageCodexAccountsLabel,
|
|
18361
|
-
messages: groupMessages,
|
|
18362
|
-
onSelect(accountId) {
|
|
18363
|
-
close();
|
|
18364
|
-
trigger.focus();
|
|
18365
|
-
onSelectCodexAccount(accountId);
|
|
18366
|
-
},
|
|
18367
|
-
onManage() {
|
|
18368
|
-
close();
|
|
18369
|
-
openSettingsPage("accounts", trigger);
|
|
18370
|
-
}
|
|
18371
|
-
});
|
|
18372
|
-
const codexAccountOptions = codexAccountGroup.options;
|
|
18373
|
-
const codexAccountContainer = codexAccountGroup.root;
|
|
18374
|
-
trigger.append(codexAccountGroup.badge);
|
|
18375
18100
|
const focusOption = (position) => {
|
|
18376
18101
|
const available = [
|
|
18377
18102
|
...menu.querySelectorAll('[role="menuitemradio"], [role="menuitem"]')
|
|
@@ -18612,14 +18337,8 @@ ${error51.stderrTail}`] : []
|
|
|
18612
18337
|
initiallyHidden: true,
|
|
18613
18338
|
bordered: true
|
|
18614
18339
|
});
|
|
18615
|
-
let latestAvailability = {};
|
|
18616
18340
|
let mainAgents = [...enabledAgents];
|
|
18617
18341
|
let moreAgents = [];
|
|
18618
|
-
const isInstalled = (agent) => latestAvailability[agent] !== "notInstalled";
|
|
18619
|
-
const partitionExternal = (agents) => partitionAgentsByInstallStatus(
|
|
18620
|
-
agents.filter((agent) => agent !== "codex").map((agent) => ({ agent })),
|
|
18621
|
-
isInstalled
|
|
18622
|
-
).map((entry) => entry.agent);
|
|
18623
18342
|
const regroup = () => {
|
|
18624
18343
|
const enabledSet = new Set(enabledAgents);
|
|
18625
18344
|
const seen = /* @__PURE__ */ new Set();
|
|
@@ -18640,15 +18359,12 @@ ${error51.stderrTail}`] : []
|
|
|
18640
18359
|
seen.add(agent);
|
|
18641
18360
|
nextMain.push(agent);
|
|
18642
18361
|
}
|
|
18643
|
-
|
|
18644
|
-
|
|
18645
|
-
mainAgents = enabledSet.has("codex") ? ["codex", ...mainExternal] : mainExternal;
|
|
18646
|
-
moreAgents = moreExternal;
|
|
18362
|
+
mainAgents = nextMain;
|
|
18363
|
+
moreAgents = nextMore;
|
|
18647
18364
|
const mainChildren = [];
|
|
18648
18365
|
for (const agent of mainAgents) {
|
|
18649
18366
|
const row = rowsByAgent.get(agent);
|
|
18650
18367
|
if (row) mainChildren.push(row);
|
|
18651
|
-
if (agent === "codex") mainChildren.push(codexAccountContainer);
|
|
18652
18368
|
}
|
|
18653
18369
|
mainGroup.replaceChildren(...mainChildren);
|
|
18654
18370
|
moreRows.replaceChildren(
|
|
@@ -18721,15 +18437,6 @@ ${error51.stderrTail}`] : []
|
|
|
18721
18437
|
menu,
|
|
18722
18438
|
agents: [...enabledAgents],
|
|
18723
18439
|
options,
|
|
18724
|
-
syncAvailability(availability) {
|
|
18725
|
-
latestAvailability = availability;
|
|
18726
|
-
regroup();
|
|
18727
|
-
},
|
|
18728
|
-
codexAccounts: [],
|
|
18729
|
-
codexAccountOptions,
|
|
18730
|
-
codexAccountContainer,
|
|
18731
|
-
codexAccountGroup,
|
|
18732
|
-
selectCodexAccount: onSelectCodexAccount,
|
|
18733
18440
|
close,
|
|
18734
18441
|
dispose() {
|
|
18735
18442
|
close();
|
|
@@ -18745,18 +18452,13 @@ ${error51.stderrTail}`] : []
|
|
|
18745
18452
|
};
|
|
18746
18453
|
return control;
|
|
18747
18454
|
}
|
|
18748
|
-
function renderRendererAgentPicker(control, state, adapterState, switching, availability = {},
|
|
18749
|
-
control.syncAvailability(availability);
|
|
18750
|
-
control.codexAccounts = [...codexAccounts];
|
|
18751
|
-
const codexOption = control.options.codex;
|
|
18752
|
-
if (codexOption) codexOption.row.hidden = shouldExpandCodexAccountOptions(codexAccounts.length);
|
|
18455
|
+
function renderRendererAgentPicker(control, state, adapterState, switching, availability = {}, currentCodexAccount = null, ownershipError = false) {
|
|
18753
18456
|
const view = rendererAgentPickerView(
|
|
18754
18457
|
state,
|
|
18755
18458
|
adapterState,
|
|
18756
18459
|
switching,
|
|
18757
18460
|
control.agents,
|
|
18758
|
-
availability
|
|
18759
|
-
shouldExpandCodexAccountOptions(codexAccounts.length) ? codexAccounts.length : 0
|
|
18461
|
+
availability
|
|
18760
18462
|
);
|
|
18761
18463
|
if (control.iconSlot.dataset.agent !== state.agent) {
|
|
18762
18464
|
control.iconSlot.replaceChildren(createRendererAgentIcon(state.agent));
|
|
@@ -18768,14 +18470,7 @@ ${error51.stderrTail}`] : []
|
|
|
18768
18470
|
"aria-label",
|
|
18769
18471
|
ownershipError ? pickerGroupMessages().ownershipErrorLabel : state.phase === "locked" ? `Agent: ${view.label}` : `Select Agent, current ${view.label}`
|
|
18770
18472
|
);
|
|
18771
|
-
|
|
18772
|
-
control.codexAccountGroup.render({
|
|
18773
|
-
accounts: shouldExpandCodexAccountOptions(codexAccounts.length) ? codexAccounts : [],
|
|
18774
|
-
selectedAccountId: state.agent === "codex" ? activeAccount?.accountId ?? null : null,
|
|
18775
|
-
disabled: switching || state.phase === "locked",
|
|
18776
|
-
showBadge: state.agent === "codex" && shouldExpandCodexAccountOptions(codexAccounts.length)
|
|
18777
|
-
});
|
|
18778
|
-
control.trigger.title = ownershipError ? pickerGroupMessages().ownershipErrorLabel : rendererAgentPickerTooltip(state, activeAccount, codexAccounts.length);
|
|
18473
|
+
control.trigger.title = ownershipError ? pickerGroupMessages().ownershipErrorLabel : rendererAgentPickerTooltip(state, currentCodexAccount ?? void 0);
|
|
18779
18474
|
control.trigger.style.cursor = control.trigger.disabled ? "not-allowed" : "pointer";
|
|
18780
18475
|
control.trigger.style.opacity = control.trigger.disabled && !switching ? "0.72" : "1";
|
|
18781
18476
|
control.iconSlot.style.display = switching || ownershipError ? "none" : "inline-flex";
|
|
@@ -19552,7 +19247,14 @@ ${error51.stderrTail}`] : []
|
|
|
19552
19247
|
["Skip permissions", "\u8DF3\u8FC7\u6743\u9650\u68C0\u67E5"],
|
|
19553
19248
|
["On request", "\u6309\u8BF7\u6C42\u8BE2\u95EE"],
|
|
19554
19249
|
["Prompt unmatched", "\u672A\u5339\u914D\u65F6\u8BE2\u95EE"],
|
|
19555
|
-
["Deny unmatched", "\u672A\u5339\u914D\u65F6\u62D2\u7EDD"]
|
|
19250
|
+
["Deny unmatched", "\u672A\u5339\u914D\u65F6\u62D2\u7EDD"],
|
|
19251
|
+
["Always Ask", "\u59CB\u7EC8\u8BE2\u95EE"],
|
|
19252
|
+
["Accept Edits", "\u63A5\u53D7\u7F16\u8F91"],
|
|
19253
|
+
["Plan", "\u89C4\u5212\u6A21\u5F0F"],
|
|
19254
|
+
["Don't Ask", "\u4E0D\u8BE2\u95EE"],
|
|
19255
|
+
["Bypass Permissions", "\u7ED5\u8FC7\u6743\u9650"],
|
|
19256
|
+
["Full Access", "\u5B8C\u5168\u8BBF\u95EE"],
|
|
19257
|
+
["Delegate", "\u7531\u7236\u4F1A\u8BDD\u7BA1\u7406"]
|
|
19556
19258
|
]);
|
|
19557
19259
|
var CHINESE_PERMISSION_MODE_DESCRIPTIONS = /* @__PURE__ */ new Map([
|
|
19558
19260
|
[
|
|
@@ -19589,7 +19291,36 @@ ${error51.stderrTail}`] : []
|
|
|
19589
19291
|
"Use Antigravity CLI permission rules; headless prompts are denied safely.",
|
|
19590
19292
|
"\u4F7F\u7528 Antigravity CLI \u6743\u9650\u89C4\u5219\uFF1B\u65E0\u754C\u9762\u8FD0\u884C\u65F6\u5B89\u5168\u62D2\u7EDD\u9700\u8981\u4EA4\u4E92\u786E\u8BA4\u7684\u8BF7\u6C42\u3002"
|
|
19591
19293
|
],
|
|
19592
|
-
["Auto-approve every Antigravity CLI tool action.", "\u81EA\u52A8\u6279\u51C6\u6240\u6709 Antigravity CLI \u5DE5\u5177\u64CD\u4F5C\u3002"]
|
|
19294
|
+
["Auto-approve every Antigravity CLI tool action.", "\u81EA\u52A8\u6279\u51C6\u6240\u6709 Antigravity CLI \u5DE5\u5177\u64CD\u4F5C\u3002"],
|
|
19295
|
+
["Prompts for permission on first use of each tool", "\u9996\u6B21\u4F7F\u7528\u6BCF\u79CD\u5DE5\u5177\u65F6\u8BF7\u6C42\u6743\u9650\u3002"],
|
|
19296
|
+
[
|
|
19297
|
+
"Automatically accepts file edit permissions for the session",
|
|
19298
|
+
"\u81EA\u52A8\u63A5\u53D7\u672C\u4F1A\u8BDD\u4E2D\u7684\u6587\u4EF6\u7F16\u8F91\u6743\u9650\u3002"
|
|
19299
|
+
],
|
|
19300
|
+
[
|
|
19301
|
+
"Agent can analyze but not modify files or execute commands",
|
|
19302
|
+
"Agent \u53EF\u4EE5\u5206\u6790\uFF0C\u4F46\u4E0D\u80FD\u4FEE\u6539\u6587\u4EF6\u6216\u6267\u884C\u547D\u4EE4\u3002"
|
|
19303
|
+
],
|
|
19304
|
+
[
|
|
19305
|
+
"An AI classifier reviews actions that would normally prompt: safe ones are auto-approved, risky ones are denied. If the classifier is unavailable, the action falls back to a prompt (or is denied when prompts cannot be shown)",
|
|
19306
|
+
"\u7531 AI \u5206\u7C7B\u5668\u8BC4\u4F30\u539F\u672C\u9700\u8981\u8BE2\u95EE\u7684\u64CD\u4F5C\uFF1A\u5B89\u5168\u64CD\u4F5C\u81EA\u52A8\u6279\u51C6\uFF0C\u98CE\u9669\u64CD\u4F5C\u62D2\u7EDD\u3002\u5206\u7C7B\u5668\u4E0D\u53EF\u7528\u65F6\u6539\u4E3A\u8BE2\u95EE\uFF1B\u65E0\u6CD5\u663E\u793A\u8BE2\u95EE\u65F6\u62D2\u7EDD\u3002"
|
|
19307
|
+
],
|
|
19308
|
+
[
|
|
19309
|
+
"Does not show permission prompts; pre-approved and safe read-only actions run, everything else that would prompt is denied",
|
|
19310
|
+
"\u4E0D\u663E\u793A\u6743\u9650\u8BE2\u95EE\uFF1B\u5DF2\u83B7\u6279\u51C6\u548C\u5B89\u5168\u7684\u53EA\u8BFB\u64CD\u4F5C\u53EF\u4EE5\u6267\u884C\uFF0C\u5176\u4F59\u539F\u672C\u9700\u8981\u8BE2\u95EE\u7684\u64CD\u4F5C\u4F1A\u88AB\u62D2\u7EDD\u3002"
|
|
19311
|
+
],
|
|
19312
|
+
["Skips all permission prompts", "\u8DF3\u8FC7\u5E38\u89C4\u6743\u9650\u8BE2\u95EE\u3002"],
|
|
19313
|
+
[
|
|
19314
|
+
"Skips ALL permission checks including dangerous commands for all agents",
|
|
19315
|
+
"\u4E3A\u6240\u6709 Agent \u8DF3\u8FC7\u5168\u90E8\u6743\u9650\u68C0\u67E5\uFF0C\u5305\u62EC\u5371\u9669\u547D\u4EE4\u3002"
|
|
19316
|
+
],
|
|
19317
|
+
["Permissions managed by parent session", "\u7531\u7236\u4F1A\u8BDD\u7BA1\u7406\u6743\u9650\u3002"],
|
|
19318
|
+
[
|
|
19319
|
+
"Native agent mode with Cursor tool approvals",
|
|
19320
|
+
"\u6267\u884C\u4EFB\u52A1\uFF0C\u53EF\u4FEE\u6539\u6587\u4EF6\u548C\u8FD0\u884C\u547D\u4EE4\uFF1B\u9700\u8981\u5BA1\u6279\u7684\u64CD\u4F5C\u4ECD\u4F1A\u8BF7\u6C42\u786E\u8BA4\u3002"
|
|
19321
|
+
],
|
|
19322
|
+
["Native read-only planning mode", "\u53EA\u8BFB\u5206\u6790\u4EE3\u7801\u5E76\u5236\u5B9A\u5B9E\u65BD\u8BA1\u5212\uFF0C\u4E0D\u4FEE\u6539\u9879\u76EE\u6587\u4EF6\u3002"],
|
|
19323
|
+
["Native read-only question mode", "\u53EA\u8BFB\u67E5\u770B\u4EE3\u7801\u5E76\u56DE\u7B54\u95EE\u9898\uFF0C\u4E0D\u4FEE\u6539\u9879\u76EE\u6587\u4EF6\u3002"]
|
|
19593
19324
|
]);
|
|
19594
19325
|
function rendererHarnessMessages(locale) {
|
|
19595
19326
|
return locale === "zh-CN" ? CHINESE_HARNESS_MESSAGES : ENGLISH_HARNESS_MESSAGES;
|
|
@@ -19901,6 +19632,32 @@ ${error51.stderrTail}`] : []
|
|
|
19901
19632
|
}
|
|
19902
19633
|
}
|
|
19903
19634
|
|
|
19635
|
+
// src/renderer-codex-account-options.ts
|
|
19636
|
+
function codexAccountAuthKind(account) {
|
|
19637
|
+
return account.authKind === "api" ? "api" : "chatgpt";
|
|
19638
|
+
}
|
|
19639
|
+
function formatCodexAccountAuthLabel(account, messages) {
|
|
19640
|
+
if (codexAccountAuthKind(account) === "api") {
|
|
19641
|
+
const identity2 = account.authIdentity?.trim() || messages.accountAuthApiIdentityFallback;
|
|
19642
|
+
return `${messages.accountAuthApiPrefix} - ${identity2}`;
|
|
19643
|
+
}
|
|
19644
|
+
const identity = account.email ?? account.authIdentity;
|
|
19645
|
+
if (!identity) return `${messages.accountAuthChatPrefix} - ${account.label}`;
|
|
19646
|
+
return `${messages.accountAuthChatPrefix} - ${identity}`;
|
|
19647
|
+
}
|
|
19648
|
+
function codexAccountDisplayName(account) {
|
|
19649
|
+
const full = account.email ?? account.label;
|
|
19650
|
+
const separator = account.email?.lastIndexOf("@") ?? -1;
|
|
19651
|
+
if (!account.email || separator <= 0 || separator === account.email.length - 1) {
|
|
19652
|
+
return { local: full, domain: null, full };
|
|
19653
|
+
}
|
|
19654
|
+
return {
|
|
19655
|
+
local: account.email.slice(0, separator),
|
|
19656
|
+
domain: account.email.slice(separator + 1),
|
|
19657
|
+
full
|
|
19658
|
+
};
|
|
19659
|
+
}
|
|
19660
|
+
|
|
19904
19661
|
// src/renderer-usage-control.ts
|
|
19905
19662
|
var ENGLISH_USAGE_MESSAGES = Object.freeze({
|
|
19906
19663
|
usage: "Usage",
|
|
@@ -20375,7 +20132,7 @@ ${error51.stderrTail}`] : []
|
|
|
20375
20132
|
if (periodType === "seven_day") return messages.sevenDay;
|
|
20376
20133
|
return messages.account;
|
|
20377
20134
|
}
|
|
20378
|
-
function productLabel(product, locale) {
|
|
20135
|
+
function productLabel(product, locale = "en") {
|
|
20379
20136
|
if (product === "GrokBuild") return "Build";
|
|
20380
20137
|
if (product === "GrokChat") return "Chat";
|
|
20381
20138
|
if (product === "GrokImagine") return "Imagine";
|
|
@@ -20383,12 +20140,22 @@ ${error51.stderrTail}`] : []
|
|
|
20383
20140
|
const messages = rendererCreditsMessages(locale);
|
|
20384
20141
|
if (product === "5-hour window") return messages.fiveHour;
|
|
20385
20142
|
if (product === "7-day window") return messages.sevenDay;
|
|
20143
|
+
if (product === "Weekly window") return messages.weekly;
|
|
20386
20144
|
if (product.endsWith(" \xB7 5-hour window")) {
|
|
20387
20145
|
return `${product.slice(0, -"5-hour window".length)}${messages.fiveHour}`;
|
|
20388
20146
|
}
|
|
20389
20147
|
if (product.endsWith(" \xB7 7-day window")) {
|
|
20390
20148
|
return `${product.slice(0, -"7-day window".length)}${messages.sevenDay}`;
|
|
20391
20149
|
}
|
|
20150
|
+
if (product.endsWith(" \xB7 Weekly window")) {
|
|
20151
|
+
return `${product.slice(0, -"Weekly window".length)}${messages.weekly}`;
|
|
20152
|
+
}
|
|
20153
|
+
if (product.endsWith(" \xB7 5-hour")) {
|
|
20154
|
+
return `${product.slice(0, -"5-hour".length)}${messages.fiveHour}`;
|
|
20155
|
+
}
|
|
20156
|
+
if (product.endsWith(" \xB7 7-day")) {
|
|
20157
|
+
return `${product.slice(0, -"7-day".length)}${messages.sevenDay}`;
|
|
20158
|
+
}
|
|
20392
20159
|
return product;
|
|
20393
20160
|
}
|
|
20394
20161
|
function toneColor(tone) {
|
|
@@ -20430,7 +20197,7 @@ ${error51.stderrTail}`] : []
|
|
|
20430
20197
|
top.style.marginBottom = "5px";
|
|
20431
20198
|
const left = document.createElement("div");
|
|
20432
20199
|
const label = document.createElement("div");
|
|
20433
|
-
label.textContent = creditsPeriodLabel(credits.periodType, locale);
|
|
20200
|
+
label.textContent = credits.label ? productLabel(credits.label, locale) : creditsPeriodLabel(credits.periodType, locale);
|
|
20434
20201
|
label.style.fontSize = "12.5px";
|
|
20435
20202
|
label.style.fontWeight = "600";
|
|
20436
20203
|
left.append(label);
|
|
@@ -20697,7 +20464,8 @@ ${error51.stderrTail}`] : []
|
|
|
20697
20464
|
}
|
|
20698
20465
|
const remaining = remainingPercent(accountCredits.usedPercent);
|
|
20699
20466
|
const percent = formatRendererCreditsPercent(remaining);
|
|
20700
|
-
const
|
|
20467
|
+
const periodLabel = accountCredits.label ? productLabel(accountCredits.label, locale) : creditsPeriodLabel(accountCredits.periodType, locale);
|
|
20468
|
+
const title = `${periodLabel} ${percent}`;
|
|
20701
20469
|
const tone = rendererCreditsTone(accountCredits.usedPercent);
|
|
20702
20470
|
const ringSlot = control.trigger.querySelector("[data-codexhost-credits-ring]");
|
|
20703
20471
|
const label = control.trigger.querySelector("[data-codexhost-credits-label]");
|
|
@@ -21443,7 +21211,7 @@ ${error51.stderrTail}`] : []
|
|
|
21443
21211
|
setNativeControlHidden(control.nativeContextUsageControl, false);
|
|
21444
21212
|
setNativeControlHidden(control.nativePermissionModeControl, hidePermissionMode);
|
|
21445
21213
|
}
|
|
21446
|
-
function mountComposerAgentControl(composer, composerId, sendButton, enabledAgents, onSelect, onDownload,
|
|
21214
|
+
function mountComposerAgentControl(composer, composerId, sendButton, enabledAgents, onSelect, onDownload, onOpenProviderPicker, onSelectModel, onSelectThinking, onSelectPermissionMode, onSelectCommand) {
|
|
21447
21215
|
const nativeModelControl = captureNativeControl(nativeModelControlForComposer(composer));
|
|
21448
21216
|
const nativeContextUsageControl = captureNativeControl(
|
|
21449
21217
|
nativeContextUsageControlForComposer(composer)
|
|
@@ -21456,7 +21224,6 @@ ${error51.stderrTail}`] : []
|
|
|
21456
21224
|
enabledAgents,
|
|
21457
21225
|
onSelect,
|
|
21458
21226
|
onDownload,
|
|
21459
|
-
onSelectCodexAccount,
|
|
21460
21227
|
onOpenProviderPicker
|
|
21461
21228
|
);
|
|
21462
21229
|
const modelPicker = mountRendererModelPicker(composerId, onSelectModel, onSelectThinking);
|
|
@@ -21501,7 +21268,7 @@ ${error51.stderrTail}`] : []
|
|
|
21501
21268
|
refreshCreditsPlacement(control);
|
|
21502
21269
|
return control;
|
|
21503
21270
|
}
|
|
21504
|
-
function renderComposerAgentControl(control, state, adapterState, switching, availability = {}, modelView = { status: "idle" }, permissionModeView = { status: "idle" }, usage = null, accountCredits = null, locale = "en",
|
|
21271
|
+
function renderComposerAgentControl(control, state, adapterState, switching, availability = {}, modelView = { status: "idle" }, permissionModeView = { status: "idle" }, usage = null, accountCredits = null, locale = "en", currentCodexAccount = null, ownershipError = false) {
|
|
21505
21272
|
if (control.usage === null) {
|
|
21506
21273
|
control.usage = mountRendererUsageControl(control.composerId, locale);
|
|
21507
21274
|
}
|
|
@@ -21528,7 +21295,7 @@ ${error51.stderrTail}`] : []
|
|
|
21528
21295
|
adapterState,
|
|
21529
21296
|
switching,
|
|
21530
21297
|
availability,
|
|
21531
|
-
|
|
21298
|
+
currentCodexAccount,
|
|
21532
21299
|
ownershipError
|
|
21533
21300
|
);
|
|
21534
21301
|
reconcileComposerNativeControls(
|
|
@@ -21544,7 +21311,7 @@ ${error51.stderrTail}`] : []
|
|
|
21544
21311
|
permissionModeVisible,
|
|
21545
21312
|
locale
|
|
21546
21313
|
);
|
|
21547
|
-
const selectedCodexAccount = state.agent === "codex" && !ownershipError ?
|
|
21314
|
+
const selectedCodexAccount = state.agent === "codex" && !ownershipError ? currentCodexAccount : void 0;
|
|
21548
21315
|
if (control.usage) {
|
|
21549
21316
|
renderRendererUsageControl(
|
|
21550
21317
|
control.usage,
|
|
@@ -21560,7 +21327,7 @@ ${error51.stderrTail}`] : []
|
|
|
21560
21327
|
if (state.agent === "codex") control.harnessCommands.close();
|
|
21561
21328
|
renderRendererCreditsControl(
|
|
21562
21329
|
control.credits,
|
|
21563
|
-
selectedCodexAccount && codexAccountAuthKind(selectedCodexAccount) === "api" ? null :
|
|
21330
|
+
selectedCodexAccount && codexAccountAuthKind(selectedCodexAccount) === "api" ? null : accountCredits,
|
|
21564
21331
|
locale
|
|
21565
21332
|
);
|
|
21566
21333
|
}
|
|
@@ -21628,40 +21395,119 @@ ${error51.stderrTail}`] : []
|
|
|
21628
21395
|
}
|
|
21629
21396
|
|
|
21630
21397
|
// src/renderer-codex-account-state.ts
|
|
21631
|
-
function
|
|
21632
|
-
|
|
21633
|
-
|
|
21634
|
-
|
|
21635
|
-
|
|
21636
|
-
|
|
21637
|
-
|
|
21638
|
-
|
|
21398
|
+
function resolveCurrentCodexAccountId(accounts, currentAccountId) {
|
|
21399
|
+
return accounts.some((account) => account.accountId === currentAccountId) ? currentAccountId : null;
|
|
21400
|
+
}
|
|
21401
|
+
function shouldApplyCodexAccountSnapshot(current, next) {
|
|
21402
|
+
if (!current) return true;
|
|
21403
|
+
if (next.instanceId !== void 0 && next.instanceId !== current.instanceId) return true;
|
|
21404
|
+
if (current.instanceId !== void 0 && next.instanceId === void 0) return false;
|
|
21405
|
+
return next.revision >= current.revision;
|
|
21639
21406
|
}
|
|
21640
21407
|
var RendererCodexAccountState = class {
|
|
21641
|
-
constructor(client) {
|
|
21408
|
+
constructor(client, changed = () => void 0) {
|
|
21642
21409
|
this.client = client;
|
|
21410
|
+
let unsubscribe;
|
|
21411
|
+
try {
|
|
21412
|
+
unsubscribe = client.subscribeCodexAccounts?.((state) => {
|
|
21413
|
+
if (this.#apply(state)) changed();
|
|
21414
|
+
});
|
|
21415
|
+
} catch {
|
|
21416
|
+
}
|
|
21417
|
+
this.#unsubscribe = unsubscribe;
|
|
21643
21418
|
}
|
|
21644
21419
|
client;
|
|
21645
21420
|
accounts = [];
|
|
21646
|
-
|
|
21647
|
-
|
|
21421
|
+
currentAccountId = null;
|
|
21422
|
+
phase = "unavailable";
|
|
21423
|
+
revision = 0;
|
|
21424
|
+
instanceId;
|
|
21425
|
+
#hasSnapshot = false;
|
|
21648
21426
|
#request = null;
|
|
21649
|
-
|
|
21650
|
-
|
|
21427
|
+
#unsubscribe;
|
|
21428
|
+
get readyAccountId() {
|
|
21429
|
+
return resolveCurrentCodexAccountId(
|
|
21430
|
+
this.accounts,
|
|
21431
|
+
this.phase === "ready" ? this.currentAccountId : null
|
|
21432
|
+
);
|
|
21651
21433
|
}
|
|
21652
21434
|
refresh() {
|
|
21653
21435
|
if (this.#request) return this.#request;
|
|
21654
21436
|
this.#request = Promise.resolve().then(() => this.client.listCodexAccounts()).then((result) => {
|
|
21655
|
-
this
|
|
21656
|
-
this.overrideAccountId = this.selection.overrideAccountId;
|
|
21437
|
+
this.#apply(result);
|
|
21657
21438
|
}).catch(() => {
|
|
21658
21439
|
}).finally(() => {
|
|
21659
21440
|
this.#request = null;
|
|
21660
21441
|
});
|
|
21661
21442
|
return this.#request;
|
|
21662
21443
|
}
|
|
21444
|
+
dispose() {
|
|
21445
|
+
this.#unsubscribe?.();
|
|
21446
|
+
}
|
|
21447
|
+
#apply(result) {
|
|
21448
|
+
if (!shouldApplyCodexAccountSnapshot(
|
|
21449
|
+
this.#hasSnapshot ? { instanceId: this.instanceId, revision: this.revision } : null,
|
|
21450
|
+
result
|
|
21451
|
+
)) {
|
|
21452
|
+
return false;
|
|
21453
|
+
}
|
|
21454
|
+
this.#hasSnapshot = true;
|
|
21455
|
+
this.accounts = result.accounts;
|
|
21456
|
+
this.currentAccountId = result.currentAccountId;
|
|
21457
|
+
this.phase = result.phase;
|
|
21458
|
+
this.revision = result.revision;
|
|
21459
|
+
this.instanceId = result.instanceId;
|
|
21460
|
+
return true;
|
|
21461
|
+
}
|
|
21663
21462
|
};
|
|
21664
21463
|
|
|
21464
|
+
// ../desktop-control/dist/renderer-react-ownership.js
|
|
21465
|
+
function committedReactAncestors(value) {
|
|
21466
|
+
const MAX_VISITED_FIBERS = 2e4;
|
|
21467
|
+
const fiber = (value2) => typeof value2 === "object" && value2 !== null ? value2 : null;
|
|
21468
|
+
const first = fiber(value);
|
|
21469
|
+
if (!first)
|
|
21470
|
+
return [];
|
|
21471
|
+
const previous = [];
|
|
21472
|
+
const seen = /* @__PURE__ */ new Set();
|
|
21473
|
+
for (let node = first; node; node = fiber(node.return)) {
|
|
21474
|
+
if (seen.has(node) || seen.size >= MAX_VISITED_FIBERS)
|
|
21475
|
+
return [];
|
|
21476
|
+
seen.add(node);
|
|
21477
|
+
previous.push(node);
|
|
21478
|
+
}
|
|
21479
|
+
const rootState = fiber(previous.at(-1)?.stateNode);
|
|
21480
|
+
if (!rootState || !("current" in rootState))
|
|
21481
|
+
return previous;
|
|
21482
|
+
const current = fiber(rootState.current);
|
|
21483
|
+
if (!current)
|
|
21484
|
+
return [];
|
|
21485
|
+
const stack = [{ node: current, parent: null }];
|
|
21486
|
+
const alternate = fiber(first.alternate);
|
|
21487
|
+
seen.clear();
|
|
21488
|
+
while (stack.length > 0 && seen.size < MAX_VISITED_FIBERS) {
|
|
21489
|
+
const entry = stack.pop();
|
|
21490
|
+
if (!entry)
|
|
21491
|
+
break;
|
|
21492
|
+
if (seen.has(entry.node))
|
|
21493
|
+
return [];
|
|
21494
|
+
seen.add(entry.node);
|
|
21495
|
+
if (entry.node === first || entry.node === alternate) {
|
|
21496
|
+
const ancestors = [];
|
|
21497
|
+
for (let cursor = entry; cursor; cursor = cursor.parent)
|
|
21498
|
+
ancestors.push(cursor.node);
|
|
21499
|
+
return ancestors;
|
|
21500
|
+
}
|
|
21501
|
+
const sibling = entry.parent && fiber(entry.node.sibling);
|
|
21502
|
+
if (sibling)
|
|
21503
|
+
stack.push({ node: sibling, parent: entry.parent });
|
|
21504
|
+
const child = fiber(entry.node.child);
|
|
21505
|
+
if (child)
|
|
21506
|
+
stack.push({ node: child, parent: entry });
|
|
21507
|
+
}
|
|
21508
|
+
return [];
|
|
21509
|
+
}
|
|
21510
|
+
|
|
21665
21511
|
// src/renderer-request-sender.ts
|
|
21666
21512
|
var RendererMethodUnavailableError = class extends Error {
|
|
21667
21513
|
constructor(method, cause) {
|
|
@@ -22503,6 +22349,39 @@ ${error51.stderrTail}`] : []
|
|
|
22503
22349
|
};
|
|
22504
22350
|
}
|
|
22505
22351
|
|
|
22352
|
+
// src/renderer-external-queue.ts
|
|
22353
|
+
function isRecord5(value) {
|
|
22354
|
+
return value !== null && typeof value === "object" && !Array.isArray(value);
|
|
22355
|
+
}
|
|
22356
|
+
function installRendererExternalQueue(target) {
|
|
22357
|
+
if (!isRecord5(target) || typeof target.getTurnCoordinator !== "function" || typeof target.getConversation !== "function") {
|
|
22358
|
+
return null;
|
|
22359
|
+
}
|
|
22360
|
+
const coordinator = target.getTurnCoordinator();
|
|
22361
|
+
const queue = isRecord5(coordinator) ? coordinator.serverQueue : null;
|
|
22362
|
+
if (!isRecord5(queue) || typeof queue.isEnabled !== "function") return null;
|
|
22363
|
+
const descriptor = Object.getOwnPropertyDescriptor(queue, "isEnabled");
|
|
22364
|
+
if (!descriptor?.writable) return null;
|
|
22365
|
+
const original = queue.isEnabled;
|
|
22366
|
+
const getConversation = target.getConversation;
|
|
22367
|
+
const isEnabled = (...args) => {
|
|
22368
|
+
const threadId = args[0];
|
|
22369
|
+
if (typeof threadId === "string") {
|
|
22370
|
+
const conversation = getConversation.call(target, threadId);
|
|
22371
|
+
if (isRecord5(conversation) && conversation.id === threadId && // Reserved transport marker from externalThreadValue, retained by
|
|
22372
|
+
// Desktop in both newly created and hydrated conversation metadata.
|
|
22373
|
+
conversation.modelProvider === "codexhost") {
|
|
22374
|
+
return false;
|
|
22375
|
+
}
|
|
22376
|
+
}
|
|
22377
|
+
return original.apply(queue, args);
|
|
22378
|
+
};
|
|
22379
|
+
queue.isEnabled = isEnabled;
|
|
22380
|
+
return () => {
|
|
22381
|
+
if (queue.isEnabled === isEnabled) Object.defineProperty(queue, "isEnabled", descriptor);
|
|
22382
|
+
};
|
|
22383
|
+
}
|
|
22384
|
+
|
|
22506
22385
|
// src/renderer-session-import-client.ts
|
|
22507
22386
|
var RendererSessionImportUnavailableError = class extends Error {
|
|
22508
22387
|
constructor() {
|
|
@@ -22550,6 +22429,8 @@ ${error51.stderrTail}`] : []
|
|
|
22550
22429
|
// src/renderer-model-client.ts
|
|
22551
22430
|
var HARNESS_INSPECT_METHOD = "codexhost/harness/inspect";
|
|
22552
22431
|
var HARNESS_PLUGIN_LIST_METHOD = "codexhost/harness/plugins/list";
|
|
22432
|
+
var HARNESS_ACCOUNT_SOURCES_METHOD = "codexhost/harness/accounts/sources";
|
|
22433
|
+
var HARNESS_ACCOUNT_INSPECT_METHOD = "codexhost/harness/accounts/inspect";
|
|
22553
22434
|
var HARNESS_WEB_UI_OPEN_METHOD = "codexhost/harness/web-ui/open";
|
|
22554
22435
|
var THREAD_FORK_METHOD = "codexhost/thread/fork";
|
|
22555
22436
|
var THREAD_INSPECT_METHOD = "codexhost/thread/inspect";
|
|
@@ -22564,27 +22445,27 @@ ${error51.stderrTail}`] : []
|
|
|
22564
22445
|
var THREAD_USAGE_INSPECT_METHOD = "codexhost/thread/usage/inspect";
|
|
22565
22446
|
var THREAD_USAGE_UPDATED_METHOD = "codexhost/thread/usage/updated";
|
|
22566
22447
|
var THREAD_TOKEN_USAGE_UPDATED_METHOD = "thread/tokenUsage/updated";
|
|
22448
|
+
var TURN_COMPLETED_METHOD = "turn/completed";
|
|
22449
|
+
var THREAD_USAGE_REFRESH_METHODS = [
|
|
22450
|
+
THREAD_TOKEN_USAGE_UPDATED_METHOD,
|
|
22451
|
+
THREAD_USAGE_UPDATED_METHOD,
|
|
22452
|
+
TURN_COMPLETED_METHOD
|
|
22453
|
+
];
|
|
22567
22454
|
var UPDATE_CHECK_METHOD = "codexhost/update/check";
|
|
22568
22455
|
var UPDATE_START_METHOD = "codexhost/update/start";
|
|
22569
22456
|
var UPDATE_STATUS_METHOD = "codexhost/update/status";
|
|
22570
22457
|
var CODEX_ACCOUNT_LIST_METHOD = "codexhost/account/list";
|
|
22571
22458
|
var CODEX_ACCOUNT_REFRESH_METHOD = "codexhost/account/refresh";
|
|
22572
|
-
var
|
|
22573
|
-
|
|
22574
|
-
var CODEX_ACCOUNT_ACTIVATE_METHOD = "codexhost/account/activate";
|
|
22575
|
-
var CODEX_ACCOUNT_LOGIN_START_METHOD = "codexhost/account/login/start";
|
|
22576
|
-
var CODEX_ACCOUNT_LOGIN_CANCEL_METHOD = "codexhost/account/login/cancel";
|
|
22577
|
-
var CODEX_ACCOUNT_LOGIN_COMPLETED_METHOD = "codexhost/account/login/completed";
|
|
22578
|
-
var CODEX_ACCOUNT_RESET_CREDIT_CONSUME_METHOD = "codexhost/account/rate-limit-reset/consume";
|
|
22579
|
-
function isRecord5(value) {
|
|
22459
|
+
var CODEX_ACCOUNT_CHANGED_METHOD = "codexhost/account/changed";
|
|
22460
|
+
function isRecord6(value) {
|
|
22580
22461
|
return typeof value === "object" && value !== null && !Array.isArray(value);
|
|
22581
22462
|
}
|
|
22582
22463
|
function notifiedThreadId(notification) {
|
|
22583
|
-
if (!
|
|
22464
|
+
if (!isRecord6(notification) || !THREAD_USAGE_REFRESH_METHODS.includes(notification.method)) {
|
|
22584
22465
|
return null;
|
|
22585
22466
|
}
|
|
22586
22467
|
const params = notification.params;
|
|
22587
|
-
if (!
|
|
22468
|
+
if (!isRecord6(params)) return null;
|
|
22588
22469
|
const parsed = hostThreadIdSchema.safeParse(params.threadId);
|
|
22589
22470
|
return parsed.success ? parsed.data : null;
|
|
22590
22471
|
}
|
|
@@ -22596,15 +22477,28 @@ ${error51.stderrTail}`] : []
|
|
|
22596
22477
|
function createThreadUsageSubscriptionRelay() {
|
|
22597
22478
|
const listeners = /* @__PURE__ */ new Set();
|
|
22598
22479
|
let removeNotificationCallback = null;
|
|
22480
|
+
let connectedClient = null;
|
|
22481
|
+
let generation = 0;
|
|
22482
|
+
const disconnect = () => {
|
|
22483
|
+
generation += 1;
|
|
22484
|
+
removeNotificationCallback?.();
|
|
22485
|
+
removeNotificationCallback = null;
|
|
22486
|
+
connectedClient = null;
|
|
22487
|
+
};
|
|
22599
22488
|
return {
|
|
22600
22489
|
connect(client) {
|
|
22601
|
-
if (
|
|
22490
|
+
if (client === connectedClient && removeNotificationCallback) return;
|
|
22491
|
+
disconnect();
|
|
22492
|
+
if (!client || listeners.size === 0) return;
|
|
22493
|
+
connectedClient = client;
|
|
22494
|
+
const subscriptionGeneration = generation;
|
|
22602
22495
|
try {
|
|
22603
22496
|
removeNotificationCallback = client.subscribeThreadUsage?.((update) => {
|
|
22497
|
+
if (subscriptionGeneration !== generation) return;
|
|
22604
22498
|
for (const listener of listeners) listener(update);
|
|
22605
22499
|
}) ?? null;
|
|
22606
22500
|
} catch {
|
|
22607
|
-
|
|
22501
|
+
disconnect();
|
|
22608
22502
|
}
|
|
22609
22503
|
},
|
|
22610
22504
|
subscribe(listener) {
|
|
@@ -22612,13 +22506,11 @@ ${error51.stderrTail}`] : []
|
|
|
22612
22506
|
return () => {
|
|
22613
22507
|
listeners.delete(listener);
|
|
22614
22508
|
if (listeners.size > 0) return;
|
|
22615
|
-
|
|
22616
|
-
removeNotificationCallback = null;
|
|
22509
|
+
disconnect();
|
|
22617
22510
|
};
|
|
22618
22511
|
},
|
|
22619
22512
|
dispose() {
|
|
22620
|
-
|
|
22621
|
-
removeNotificationCallback = null;
|
|
22513
|
+
disconnect();
|
|
22622
22514
|
listeners.clear();
|
|
22623
22515
|
}
|
|
22624
22516
|
};
|
|
@@ -22705,8 +22597,8 @@ ${error51.stderrTail}`] : []
|
|
|
22705
22597
|
threadId: params.threadId,
|
|
22706
22598
|
includeTurns: false
|
|
22707
22599
|
});
|
|
22708
|
-
const thread =
|
|
22709
|
-
if (!
|
|
22600
|
+
const thread = isRecord6(native) ? native.thread : null;
|
|
22601
|
+
if (!isRecord6(thread) || thread.id !== params.threadId || typeof thread.modelProvider !== "string" || !thread.modelProvider || thread.modelProvider === "codexhost" || typeof thread.cliVersion !== "string" || !thread.cliVersion || thread.cliVersion === "codexhost") {
|
|
22710
22602
|
throw new Error("Native Thread response cannot establish Codex ownership");
|
|
22711
22603
|
}
|
|
22712
22604
|
return { owner: "codex", locked: true };
|
|
@@ -22741,7 +22633,7 @@ ${error51.stderrTail}`] : []
|
|
|
22741
22633
|
let disposed = false;
|
|
22742
22634
|
const generations = /* @__PURE__ */ new Map();
|
|
22743
22635
|
const removeNotificationCallback = notifications.addNotificationCallback(
|
|
22744
|
-
|
|
22636
|
+
THREAD_USAGE_REFRESH_METHODS,
|
|
22745
22637
|
(notification) => {
|
|
22746
22638
|
const threadId = notifiedThreadId(notification);
|
|
22747
22639
|
if (!threadId) return;
|
|
@@ -22790,16 +22682,25 @@ ${error51.stderrTail}`] : []
|
|
|
22790
22682
|
);
|
|
22791
22683
|
return codexAccountUsageResultSchema.parse(result);
|
|
22792
22684
|
},
|
|
22793
|
-
async
|
|
22794
|
-
|
|
22795
|
-
|
|
22796
|
-
|
|
22685
|
+
async listHarnessAccountSources() {
|
|
22686
|
+
return harnessAccountSourceListResultSchema.parse(
|
|
22687
|
+
await manager.sendRequest(HARNESS_ACCOUNT_SOURCES_METHOD, {})
|
|
22688
|
+
);
|
|
22689
|
+
},
|
|
22690
|
+
async inspectHarnessAccount(input) {
|
|
22691
|
+
return harnessAccountInspectResultSchema.parse(
|
|
22692
|
+
await manager.sendRequest(
|
|
22693
|
+
HARNESS_ACCOUNT_INSPECT_METHOD,
|
|
22694
|
+
harnessAccountInspectParamsSchema.parse(input)
|
|
22695
|
+
)
|
|
22797
22696
|
);
|
|
22798
|
-
return codexAccountResetCreditConsumeResultSchema.parse(result);
|
|
22799
22697
|
},
|
|
22800
|
-
async listHarnessAccounts() {
|
|
22698
|
+
async listHarnessAccounts(input = {}) {
|
|
22801
22699
|
return harnessAccountListResultSchema.parse(
|
|
22802
|
-
await manager.sendRequest(
|
|
22700
|
+
await manager.sendRequest(
|
|
22701
|
+
"codexhost/harness/accounts/list",
|
|
22702
|
+
harnessAccountListParamsSchema.parse(input)
|
|
22703
|
+
)
|
|
22803
22704
|
);
|
|
22804
22705
|
},
|
|
22805
22706
|
async listCodexAccounts() {
|
|
@@ -22810,56 +22711,16 @@ ${error51.stderrTail}`] : []
|
|
|
22810
22711
|
const result = await manager.sendRequest(CODEX_ACCOUNT_REFRESH_METHOD, {});
|
|
22811
22712
|
return codexAccountListResultSchema.parse(result);
|
|
22812
22713
|
},
|
|
22813
|
-
|
|
22814
|
-
const result = await manager.sendRequest(
|
|
22815
|
-
CODEX_ACCOUNT_CREATE_METHOD,
|
|
22816
|
-
codexAccountCreateParamsSchema.parse(input)
|
|
22817
|
-
);
|
|
22818
|
-
return codexAccountMutationResultSchema.parse(result);
|
|
22819
|
-
},
|
|
22820
|
-
async deleteCodexAccount(input) {
|
|
22821
|
-
const result = await manager.sendRequest(
|
|
22822
|
-
CODEX_ACCOUNT_DELETE_METHOD,
|
|
22823
|
-
codexAccountDeleteParamsSchema.parse(input)
|
|
22824
|
-
);
|
|
22825
|
-
return codexAccountDeleteResultSchema.parse(result);
|
|
22826
|
-
},
|
|
22827
|
-
async activateCodexAccount(input) {
|
|
22828
|
-
const result = await manager.sendRequest(
|
|
22829
|
-
CODEX_ACCOUNT_ACTIVATE_METHOD,
|
|
22830
|
-
codexAccountActivateParamsSchema.parse(input)
|
|
22831
|
-
);
|
|
22832
|
-
return codexAccountMutationResultSchema.parse(result);
|
|
22833
|
-
},
|
|
22834
|
-
async startCodexAccountLogin(input) {
|
|
22835
|
-
const result = await manager.sendRequest(
|
|
22836
|
-
CODEX_ACCOUNT_LOGIN_START_METHOD,
|
|
22837
|
-
codexAccountLoginStartParamsSchema.parse(input)
|
|
22838
|
-
);
|
|
22839
|
-
return codexAccountLoginStartResultSchema.parse(result);
|
|
22840
|
-
},
|
|
22841
|
-
async cancelCodexAccountLogin(input) {
|
|
22842
|
-
const result = await manager.sendRequest(
|
|
22843
|
-
CODEX_ACCOUNT_LOGIN_CANCEL_METHOD,
|
|
22844
|
-
codexAccountLoginCancelParamsSchema.parse(input)
|
|
22845
|
-
);
|
|
22846
|
-
return codexAccountLoginCancelResultSchema.parse(result);
|
|
22847
|
-
},
|
|
22848
|
-
subscribeCodexAccountLogin(listener) {
|
|
22714
|
+
subscribeCodexAccounts(listener) {
|
|
22849
22715
|
const notifications = notificationTarget(source);
|
|
22850
22716
|
if (!notifications?.addNotificationCallback) {
|
|
22851
|
-
throw new Error("Renderer Account
|
|
22717
|
+
throw new Error("Renderer Account notification callback is unavailable");
|
|
22852
22718
|
}
|
|
22853
|
-
return notifications.addNotificationCallback(
|
|
22854
|
-
|
|
22855
|
-
(notification)
|
|
22856
|
-
|
|
22857
|
-
|
|
22858
|
-
}
|
|
22859
|
-
const result = codexAccountLoginCompletedSchema.safeParse(notification.params);
|
|
22860
|
-
if (result.success) listener(result.data);
|
|
22861
|
-
}
|
|
22862
|
-
);
|
|
22719
|
+
return notifications.addNotificationCallback(CODEX_ACCOUNT_CHANGED_METHOD, (notification) => {
|
|
22720
|
+
if (!isRecord6(notification) || notification.method !== CODEX_ACCOUNT_CHANGED_METHOD) return;
|
|
22721
|
+
const state = codexAccountChangedSchema.safeParse(notification.params);
|
|
22722
|
+
if (state.success) listener(state.data);
|
|
22723
|
+
});
|
|
22863
22724
|
}
|
|
22864
22725
|
});
|
|
22865
22726
|
}
|
|
@@ -22909,7 +22770,7 @@ ${error51.stderrTail}`] : []
|
|
|
22909
22770
|
if (agent === "codex") return null;
|
|
22910
22771
|
return encodeHarnessPluginRoute({ harnessId: harnessPluginIdSchema.parse(agent) });
|
|
22911
22772
|
}
|
|
22912
|
-
function
|
|
22773
|
+
function isRecord7(value) {
|
|
22913
22774
|
return typeof value === "object" && value !== null && !Array.isArray(value);
|
|
22914
22775
|
}
|
|
22915
22776
|
function piTransportModelId(model, thinkingOptionId) {
|
|
@@ -23150,7 +23011,18 @@ ${error51.stderrTail}`] : []
|
|
|
23150
23011
|
return hostThreadIdSchema.parse(target[1]);
|
|
23151
23012
|
}
|
|
23152
23013
|
function isCurrentRequestBridge(value) {
|
|
23153
|
-
return
|
|
23014
|
+
return isRecord7(value) && typeof value.hostId === "string" && value.hostId.length > 0 && typeof value.sendRequest === "function" && typeof value.prewarmThreadStart === "function" && typeof value.enqueueRequest === "function";
|
|
23015
|
+
}
|
|
23016
|
+
function requestTargetOwnerFromHookState(value) {
|
|
23017
|
+
if (!isRecord7(value)) return null;
|
|
23018
|
+
const ownerFrom = (candidate) => {
|
|
23019
|
+
if (!isRecord7(candidate)) return null;
|
|
23020
|
+
const requestClient = candidate.requestClient;
|
|
23021
|
+
const bridge = isCurrentRequestBridge(requestClient) ? requestClient : isCurrentRequestBridge(candidate) ? candidate : null;
|
|
23022
|
+
if (!bridge) return null;
|
|
23023
|
+
return typeof candidate.sendRequest === "function" ? candidate : bridge;
|
|
23024
|
+
};
|
|
23025
|
+
return ownerFrom(value) ?? ownerFrom(value.manager);
|
|
23154
23026
|
}
|
|
23155
23027
|
function findActivePrewarmTargets(root) {
|
|
23156
23028
|
const editor = root.querySelector(
|
|
@@ -23173,23 +23045,13 @@ ${error51.stderrTail}`] : []
|
|
|
23173
23045
|
return [];
|
|
23174
23046
|
}
|
|
23175
23047
|
const targets = /* @__PURE__ */ new Set();
|
|
23176
|
-
|
|
23177
|
-
for (let depth = 0; depth < 200; depth += 1) {
|
|
23048
|
+
for (const fiber of committedReactAncestors(firstFiber2)) {
|
|
23178
23049
|
let hook = fiber.memoizedState;
|
|
23179
23050
|
for (let hookIndex = 0; hook && hookIndex < 100; hookIndex += 1) {
|
|
23180
|
-
const
|
|
23181
|
-
if (
|
|
23182
|
-
const requestClient = hookState.requestClient;
|
|
23183
|
-
const bridge = isCurrentRequestBridge(requestClient) ? requestClient : isCurrentRequestBridge(hookState) ? hookState : null;
|
|
23184
|
-
if (bridge) {
|
|
23185
|
-
targets.add(typeof hookState.sendRequest === "function" ? hookState : bridge);
|
|
23186
|
-
}
|
|
23187
|
-
}
|
|
23051
|
+
const owner = requestTargetOwnerFromHookState(hook.memoizedState);
|
|
23052
|
+
if (owner) targets.add(owner);
|
|
23188
23053
|
hook = typeof hook.next === "object" && hook.next !== null ? hook.next : null;
|
|
23189
23054
|
}
|
|
23190
|
-
const parent = fiber.return;
|
|
23191
|
-
if (typeof parent !== "object" && typeof parent !== "function" || parent === null) break;
|
|
23192
|
-
fiber = parent;
|
|
23193
23055
|
}
|
|
23194
23056
|
return [...targets];
|
|
23195
23057
|
}
|
|
@@ -23212,7 +23074,7 @@ ${error51.stderrTail}`] : []
|
|
|
23212
23074
|
let fiber = findComposerFiber(composer);
|
|
23213
23075
|
for (let depth = 0; fiber && depth < 120; depth += 1) {
|
|
23214
23076
|
const props = fiber.memoizedProps;
|
|
23215
|
-
if (
|
|
23077
|
+
if (isRecord7(props) && "conversationId" in props && props.conversationId != null) {
|
|
23216
23078
|
const candidate = hostThreadIdSchema.safeParse(props.conversationId);
|
|
23217
23079
|
if (!candidate.success || threadId !== void 0 && threadId !== candidate.data) {
|
|
23218
23080
|
return null;
|
|
@@ -23224,17 +23086,31 @@ ${error51.stderrTail}`] : []
|
|
|
23224
23086
|
}
|
|
23225
23087
|
return threadId;
|
|
23226
23088
|
}
|
|
23227
|
-
function
|
|
23228
|
-
if (!Array.isArray(value) || value.length !== 7 || value[3] !== value[5] || value[3] !== value[6] || !
|
|
23089
|
+
function isLegacySevenSlotDraftWrapper(value) {
|
|
23090
|
+
if (!Array.isArray(value) || value.length !== 7 || value[3] !== value[5] || value[3] !== value[6] || !isRecord7(value[3]) || typeof value[3].get !== "function" || typeof value[2] !== "string" && value[2] !== null) {
|
|
23229
23091
|
return false;
|
|
23230
23092
|
}
|
|
23231
23093
|
try {
|
|
23232
23094
|
const draft = value[3].get();
|
|
23233
|
-
return
|
|
23095
|
+
return isRecord7(draft) && "modelSettings" in draft && "isManuallyChanged" in draft;
|
|
23234
23096
|
} catch {
|
|
23235
23097
|
return false;
|
|
23236
23098
|
}
|
|
23237
23099
|
}
|
|
23100
|
+
function duplicatedClientNewThreadId(value) {
|
|
23101
|
+
if (!Array.isArray(value)) return null;
|
|
23102
|
+
const ids = value.filter(
|
|
23103
|
+
(item) => typeof item === "string" && item.startsWith("client-new-thread:")
|
|
23104
|
+
);
|
|
23105
|
+
if (ids.length < 2 || ids.some((id) => id !== ids[0])) return null;
|
|
23106
|
+
return ids[0] ?? null;
|
|
23107
|
+
}
|
|
23108
|
+
function draftIdFromMemoValue(value) {
|
|
23109
|
+
if (isLegacySevenSlotDraftWrapper(value) && typeof value[2] === "string" && value[2].startsWith("client-new-thread:")) {
|
|
23110
|
+
return value[2];
|
|
23111
|
+
}
|
|
23112
|
+
return duplicatedClientNewThreadId(value);
|
|
23113
|
+
}
|
|
23238
23114
|
function findComposerDomIdentity(composer) {
|
|
23239
23115
|
const children = Array.from(composer.children ?? []);
|
|
23240
23116
|
const portals = children.filter((child) => child.hasAttribute("data-above-composer-portal"));
|
|
@@ -23250,12 +23126,11 @@ ${error51.stderrTail}`] : []
|
|
|
23250
23126
|
let fiber = findComposerFiber(composer);
|
|
23251
23127
|
for (let depth = 0; fiber && depth < 120; depth += 1) {
|
|
23252
23128
|
const updateQueue = fiber.updateQueue;
|
|
23253
|
-
const memoCache =
|
|
23254
|
-
const data =
|
|
23129
|
+
const memoCache = isRecord7(updateQueue) ? updateQueue.memoCache : null;
|
|
23130
|
+
const data = isRecord7(memoCache) && Array.isArray(memoCache.data) ? memoCache.data : [];
|
|
23255
23131
|
for (const value of data) {
|
|
23256
|
-
|
|
23257
|
-
|
|
23258
|
-
}
|
|
23132
|
+
const draftId = draftIdFromMemoValue(value);
|
|
23133
|
+
if (draftId) draftIds.add(draftId);
|
|
23259
23134
|
}
|
|
23260
23135
|
const parent = fiber.return;
|
|
23261
23136
|
fiber = (typeof parent === "object" || typeof parent === "function") && parent !== null ? parent : null;
|
|
@@ -23279,7 +23154,7 @@ ${error51.stderrTail}`] : []
|
|
|
23279
23154
|
return ["default", draftIds.values().next().value];
|
|
23280
23155
|
}
|
|
23281
23156
|
function isDraftPrewarmPolicyReady(value) {
|
|
23282
|
-
return
|
|
23157
|
+
return isRecord7(value) && value.state === "ready" && typeof value.hostId === "string" && value.hostId.length > 0 && typeof value.select === "function" && typeof value.clear === "function";
|
|
23283
23158
|
}
|
|
23284
23159
|
function prewarmTargetHostId(target) {
|
|
23285
23160
|
const bridge = target.requestClient ?? target;
|
|
@@ -23287,7 +23162,7 @@ ${error51.stderrTail}`] : []
|
|
|
23287
23162
|
return typeof hostId === "string" && hostId.length > 0 ? hostId : null;
|
|
23288
23163
|
}
|
|
23289
23164
|
function isRendererRequestTarget(value) {
|
|
23290
|
-
if (!
|
|
23165
|
+
if (!isRecord7(value) || typeof value.sendRequest !== "function") return false;
|
|
23291
23166
|
return isCurrentRequestBridge(value.requestClient ?? value);
|
|
23292
23167
|
}
|
|
23293
23168
|
function hasPolicyRequestTarget(policy) {
|
|
@@ -23352,7 +23227,7 @@ ${error51.stderrTail}`] : []
|
|
|
23352
23227
|
const transportModelId = agent === "pi" ? piTransportModelId(model, thinkingOptionId) : agent === "claude-code" ? claudeTransportModelId(model, permissionModeId, thinkingOptionId) : agent === "deepseek-harness" ? deepSeekHarnessTransportModelId(model, permissionModeId) : agent === "opencode" ? openCodeTransportModelId(model, permissionModeId, thinkingOptionId) : agent === "grok" ? grokTransportModelId(model, permissionModeId, thinkingOptionId) : agent === "omp" ? ompTransportModelId(model, thinkingOptionId, permissionModeId) : agent === "antigravity" ? antigravityTransportModelId(model, permissionModeId, thinkingOptionId) : agent === "hermes" ? hermesTransportModelId(model, permissionModeId) : agent === "codex" ? null : model || thinkingOptionId || permissionModeId ? encodeHarnessPluginRoute({
|
|
23353
23228
|
harnessId: harnessPluginIdSchema.parse(agent),
|
|
23354
23229
|
...model ? { model } : {},
|
|
23355
|
-
...thinkingOptionId ? { thinkingOptionId } : {},
|
|
23230
|
+
...thinkingOptionId && agent !== "cursor-cli" ? { thinkingOptionId } : {},
|
|
23356
23231
|
...permissionModeId ? { permissionModeId } : {}
|
|
23357
23232
|
}) : transportModelIdForAgent(agent);
|
|
23358
23233
|
return transportModelId ? { model: transportModelId, reasoningEffort } : officialSelection;
|
|
@@ -23378,7 +23253,7 @@ ${error51.stderrTail}`] : []
|
|
|
23378
23253
|
() => findActivePrewarmTargets(document)
|
|
23379
23254
|
);
|
|
23380
23255
|
const clientsByTarget = /* @__PURE__ */ new WeakMap();
|
|
23381
|
-
const
|
|
23256
|
+
const turnControlCleanups = /* @__PURE__ */ new Set();
|
|
23382
23257
|
const modelClientForTargets = (targets, policy = null) => {
|
|
23383
23258
|
const target = targets[0];
|
|
23384
23259
|
if (targets.length !== 1 || !target) return null;
|
|
@@ -23388,8 +23263,10 @@ ${error51.stderrTail}`] : []
|
|
|
23388
23263
|
const client = createRendererModelClient([target]);
|
|
23389
23264
|
if (client) {
|
|
23390
23265
|
if (!cached2) {
|
|
23391
|
-
const
|
|
23392
|
-
if (
|
|
23266
|
+
const queueCleanup = installRendererExternalQueue(target);
|
|
23267
|
+
if (queueCleanup) turnControlCleanups.add(queueCleanup);
|
|
23268
|
+
const steeringCleanup = installRendererExternalSteering(target);
|
|
23269
|
+
if (steeringCleanup) turnControlCleanups.add(steeringCleanup);
|
|
23393
23270
|
}
|
|
23394
23271
|
clientsByTarget.set(target, { client, policy, requestClient: target.requestClient });
|
|
23395
23272
|
}
|
|
@@ -23400,6 +23277,7 @@ ${error51.stderrTail}`] : []
|
|
|
23400
23277
|
const syncActiveRoute = (route) => {
|
|
23401
23278
|
const policy = route?.policy ?? null;
|
|
23402
23279
|
const client = route ? modelClientForTargets(route.targets, route.policy) : null;
|
|
23280
|
+
usageSubscription.connect(client);
|
|
23403
23281
|
if (activeRoutePolicy === policy && activeRouteClient === client) return client;
|
|
23404
23282
|
activeRoutePolicy = policy;
|
|
23405
23283
|
activeRouteClient = client;
|
|
@@ -23413,7 +23291,6 @@ ${error51.stderrTail}`] : []
|
|
|
23413
23291
|
const currentModelClient = () => {
|
|
23414
23292
|
const client = currentRequestRoute() ? activeRouteClient : null;
|
|
23415
23293
|
if (!client) throw new Error("Renderer Model request manager is unavailable");
|
|
23416
|
-
usageSubscription.connect(client);
|
|
23417
23294
|
return client;
|
|
23418
23295
|
};
|
|
23419
23296
|
const modelControl = Object.freeze({
|
|
@@ -23452,29 +23329,35 @@ ${error51.stderrTail}`] : []
|
|
|
23452
23329
|
if (!client.inspectCodexAccountUsage) throw new Error("Codex Account Usage is unavailable");
|
|
23453
23330
|
return client.inspectCodexAccountUsage(input);
|
|
23454
23331
|
},
|
|
23455
|
-
|
|
23332
|
+
listHarnessAccountSources: () => {
|
|
23456
23333
|
const client = currentModelClient();
|
|
23457
|
-
if (!client.
|
|
23458
|
-
throw new Error("
|
|
23334
|
+
if (!client.listHarnessAccountSources) {
|
|
23335
|
+
throw new Error("Harness account source discovery is unavailable");
|
|
23459
23336
|
}
|
|
23460
|
-
return client.
|
|
23337
|
+
return client.listHarnessAccountSources();
|
|
23461
23338
|
},
|
|
23462
|
-
|
|
23339
|
+
inspectHarnessAccount: (input) => {
|
|
23340
|
+
const client = currentModelClient();
|
|
23341
|
+
if (!client.inspectHarnessAccount) {
|
|
23342
|
+
throw new Error("Harness account inspection is unavailable");
|
|
23343
|
+
}
|
|
23344
|
+
return client.inspectHarnessAccount(input);
|
|
23345
|
+
},
|
|
23346
|
+
listHarnessAccounts: (input) => {
|
|
23463
23347
|
const client = currentModelClient();
|
|
23464
23348
|
if (!client.listHarnessAccounts) throw new Error("Harness account inspection is unavailable");
|
|
23465
|
-
return client.listHarnessAccounts();
|
|
23349
|
+
return client.listHarnessAccounts(input);
|
|
23466
23350
|
},
|
|
23467
23351
|
listCodexAccounts: () => currentModelClient().listCodexAccounts(),
|
|
23468
23352
|
refreshCodexAccounts: () => {
|
|
23469
23353
|
const client = currentModelClient();
|
|
23470
23354
|
return client.refreshCodexAccounts?.() ?? client.listCodexAccounts();
|
|
23471
23355
|
},
|
|
23472
|
-
|
|
23473
|
-
|
|
23474
|
-
|
|
23475
|
-
|
|
23476
|
-
|
|
23477
|
-
subscribeCodexAccountLogin: (listener) => currentModelClient().subscribeCodexAccountLogin(listener)
|
|
23356
|
+
subscribeCodexAccounts: (listener) => {
|
|
23357
|
+
const client = currentModelClient();
|
|
23358
|
+
if (!client.subscribeCodexAccounts) throw new Error("Codex Account updates are unavailable");
|
|
23359
|
+
return client.subscribeCodexAccounts(listener);
|
|
23360
|
+
}
|
|
23478
23361
|
});
|
|
23479
23362
|
const forkControl = installRendererForkControl({
|
|
23480
23363
|
getClient: () => modelControl,
|
|
@@ -23608,7 +23491,7 @@ ${error51.stderrTail}`] : []
|
|
|
23608
23491
|
() => activeRoutingPolicy?.select(null),
|
|
23609
23492
|
() => syncActiveRoute(null),
|
|
23610
23493
|
() => forkControl.dispose(),
|
|
23611
|
-
...
|
|
23494
|
+
...turnControlCleanups,
|
|
23612
23495
|
() => usageSubscription.dispose()
|
|
23613
23496
|
];
|
|
23614
23497
|
for (const cleanup of cleanups) {
|
|
@@ -23640,16 +23523,16 @@ ${error51.stderrTail}`] : []
|
|
|
23640
23523
|
}
|
|
23641
23524
|
|
|
23642
23525
|
// src/renderer-subagent-thread-model.ts
|
|
23643
|
-
function
|
|
23526
|
+
function isRecord8(value) {
|
|
23644
23527
|
return typeof value === "object" && value !== null && !Array.isArray(value);
|
|
23645
23528
|
}
|
|
23646
23529
|
function nonBlank(value) {
|
|
23647
23530
|
return typeof value === "string" && value.trim().length > 0;
|
|
23648
23531
|
}
|
|
23649
23532
|
function threadFromReadResult(value, expectedThreadId) {
|
|
23650
|
-
if (!
|
|
23651
|
-
const directThread =
|
|
23652
|
-
const nestedThread =
|
|
23533
|
+
if (!isRecord8(value)) return null;
|
|
23534
|
+
const directThread = isRecord8(value.thread) ? value.thread : null;
|
|
23535
|
+
const nestedThread = isRecord8(value.result) && isRecord8(value.result.thread) ? value.result.thread : null;
|
|
23653
23536
|
const thread = directThread ?? nestedThread;
|
|
23654
23537
|
if (!thread) return null;
|
|
23655
23538
|
if (expectedThreadId && (!nonBlank(thread.id) || thread.id.trim() !== expectedThreadId)) {
|
|
@@ -23663,7 +23546,7 @@ ${error51.stderrTail}`] : []
|
|
|
23663
23546
|
if (typeof policy?.requestTarget !== "function") return null;
|
|
23664
23547
|
try {
|
|
23665
23548
|
const target = policy.requestTarget();
|
|
23666
|
-
return
|
|
23549
|
+
return isRecord8(target) && typeof target.sendRequest === "function" ? target : null;
|
|
23667
23550
|
} catch {
|
|
23668
23551
|
return null;
|
|
23669
23552
|
}
|
|
@@ -23704,10 +23587,10 @@ ${error51.stderrTail}`] : []
|
|
|
23704
23587
|
function subagentStatusFromReadResult(value, expectedThreadId) {
|
|
23705
23588
|
const thread = threadFromReadResult(value, expectedThreadId);
|
|
23706
23589
|
if (!thread) return null;
|
|
23707
|
-
const threadStatus =
|
|
23590
|
+
const threadStatus = isRecord8(thread.status) && nonBlank(thread.status.type) ? thread.status.type : void 0;
|
|
23708
23591
|
if (threadStatus === "systemError") return "failed";
|
|
23709
23592
|
const turns = Array.isArray(thread.turns) ? thread.turns : [];
|
|
23710
|
-
const lastTurn = [...turns].reverse().find(
|
|
23593
|
+
const lastTurn = [...turns].reverse().find(isRecord8);
|
|
23711
23594
|
const turnStatus = lastTurn && nonBlank(lastTurn.status) ? lastTurn.status : void 0;
|
|
23712
23595
|
if (turnStatus === "completed") return "completed";
|
|
23713
23596
|
if (turnStatus === "failed") return "failed";
|
|
@@ -23851,7 +23734,7 @@ ${error51.stderrTail}`] : []
|
|
|
23851
23734
|
var SUBAGENT_ROW_COPY_ATTRIBUTE = "data-codexhost-subagent-copy";
|
|
23852
23735
|
var SUBAGENT_ITEM_BUTTON_SELECTOR = 'button[data-slot="thread-summary-panel-item-button"]';
|
|
23853
23736
|
var SUBAGENT_ITEM_LABEL_SELECTOR = '[data-slot="thread-summary-panel-item-label"]';
|
|
23854
|
-
function
|
|
23737
|
+
function isRecord9(value) {
|
|
23855
23738
|
return typeof value === "object" && value !== null && !Array.isArray(value);
|
|
23856
23739
|
}
|
|
23857
23740
|
function nonBlank2(value) {
|
|
@@ -23969,12 +23852,12 @@ ${error51.stderrTail}`] : []
|
|
|
23969
23852
|
if (nonBlank2(source.status) && !target.status) {
|
|
23970
23853
|
target.status = source.status.trim();
|
|
23971
23854
|
}
|
|
23972
|
-
if (
|
|
23855
|
+
if (isRecord9(source.agentState) && nonBlank2(source.agentState.status) && !target.status) {
|
|
23973
23856
|
target.status = source.agentState.status.trim();
|
|
23974
23857
|
}
|
|
23975
|
-
if (
|
|
23858
|
+
if (isRecord9(source.agentsStates) && target.conversationId) {
|
|
23976
23859
|
const state = source.agentsStates[target.conversationId];
|
|
23977
|
-
if (
|
|
23860
|
+
if (isRecord9(state) && nonBlank2(state.status) && !target.status) {
|
|
23978
23861
|
target.status = state.status.trim();
|
|
23979
23862
|
}
|
|
23980
23863
|
}
|
|
@@ -23985,28 +23868,28 @@ ${error51.stderrTail}`] : []
|
|
|
23985
23868
|
if (Array.isArray(item.receiverThreadIds) && item.receiverThreadIds.includes(conversationId)) {
|
|
23986
23869
|
return true;
|
|
23987
23870
|
}
|
|
23988
|
-
return
|
|
23871
|
+
return isRecord9(item.agentsStates) && conversationId in item.agentsStates;
|
|
23989
23872
|
}
|
|
23990
23873
|
function harvestFromValue(value, target) {
|
|
23991
|
-
if (!
|
|
23874
|
+
if (!isRecord9(value)) return;
|
|
23992
23875
|
contribute(target, value);
|
|
23993
23876
|
const nested = [
|
|
23994
|
-
|
|
23995
|
-
|
|
23996
|
-
|
|
23997
|
-
|
|
23998
|
-
|
|
23999
|
-
|
|
23877
|
+
isRecord9(value.row) ? value.row : null,
|
|
23878
|
+
isRecord9(value.backgroundAgent) ? value.backgroundAgent : null,
|
|
23879
|
+
isRecord9(value.item) ? value.item : null,
|
|
23880
|
+
isRecord9(value.item) && isRecord9(value.item.backgroundAgent) ? value.item.backgroundAgent : null,
|
|
23881
|
+
isRecord9(value.thread) && (!target.conversationId || nonBlank2(value.thread.id) && value.thread.id.trim() === target.conversationId) ? value.thread : null,
|
|
23882
|
+
isRecord9(value.childConversation) ? value.childConversation : null
|
|
24000
23883
|
];
|
|
24001
23884
|
for (const source of nested) {
|
|
24002
23885
|
if (source) contribute(target, source);
|
|
24003
23886
|
}
|
|
24004
23887
|
if (!target.conversationId) return;
|
|
24005
23888
|
const items = Array.isArray(value.items) ? value.items : Array.isArray(value.turns) ? value.turns.flatMap(
|
|
24006
|
-
(turn) =>
|
|
23889
|
+
(turn) => isRecord9(turn) && Array.isArray(turn.items) ? turn.items : []
|
|
24007
23890
|
) : [];
|
|
24008
23891
|
for (const item of items) {
|
|
24009
|
-
if (!
|
|
23892
|
+
if (!isRecord9(item)) continue;
|
|
24010
23893
|
if (collabMatches(item, target.conversationId)) contribute(target, item, true);
|
|
24011
23894
|
}
|
|
24012
23895
|
}
|
|
@@ -24073,7 +23956,7 @@ ${error51.stderrTail}`] : []
|
|
|
24073
23956
|
const name = names[0];
|
|
24074
23957
|
if (!name) return null;
|
|
24075
23958
|
const fiber = Object.getOwnPropertyDescriptor(element, name)?.value ?? element[name];
|
|
24076
|
-
return
|
|
23959
|
+
return isRecord9(fiber) ? fiber : null;
|
|
24077
23960
|
}
|
|
24078
23961
|
function metaFromFiberProps(fiber) {
|
|
24079
23962
|
if (!fiber) return null;
|
|
@@ -24102,7 +23985,7 @@ ${error51.stderrTail}`] : []
|
|
|
24102
23985
|
};
|
|
24103
23986
|
}
|
|
24104
23987
|
function metaFromDescendants(start) {
|
|
24105
|
-
if (!start || !
|
|
23988
|
+
if (!start || !isRecord9(start.child)) return null;
|
|
24106
23989
|
const stack = [start.child];
|
|
24107
23990
|
const seen = /* @__PURE__ */ new Set();
|
|
24108
23991
|
let found = null;
|
|
@@ -24113,8 +23996,8 @@ ${error51.stderrTail}`] : []
|
|
|
24113
23996
|
seen.add(fiber);
|
|
24114
23997
|
steps += 1;
|
|
24115
23998
|
found = mergeRow(found, metaFromFiberProps(fiber));
|
|
24116
|
-
if (
|
|
24117
|
-
if (
|
|
23999
|
+
if (isRecord9(fiber.child)) stack.push(fiber.child);
|
|
24000
|
+
if (isRecord9(fiber.sibling)) stack.push(fiber.sibling);
|
|
24118
24001
|
}
|
|
24119
24002
|
return found;
|
|
24120
24003
|
}
|
|
@@ -24123,7 +24006,7 @@ ${error51.stderrTail}`] : []
|
|
|
24123
24006
|
let found = metaFromDescendants(fiber);
|
|
24124
24007
|
for (let depth = 0; fiber && depth < 12; depth += 1) {
|
|
24125
24008
|
found = mergeRow(found, metaFromFiberProps(fiber));
|
|
24126
|
-
fiber =
|
|
24009
|
+
fiber = isRecord9(fiber.return) ? fiber.return : null;
|
|
24127
24010
|
}
|
|
24128
24011
|
return found;
|
|
24129
24012
|
}
|
|
@@ -24310,11 +24193,11 @@ ${error51.stderrTail}`] : []
|
|
|
24310
24193
|
return null;
|
|
24311
24194
|
}
|
|
24312
24195
|
}
|
|
24313
|
-
function
|
|
24196
|
+
function isRecord10(value) {
|
|
24314
24197
|
return typeof value === "object" && value !== null && !Array.isArray(value);
|
|
24315
24198
|
}
|
|
24316
24199
|
function parseExternalConfiguration(value) {
|
|
24317
|
-
if (!
|
|
24200
|
+
if (!isRecord10(value)) return void 0;
|
|
24318
24201
|
const model = harnessModelRefSchema.safeParse(value.model);
|
|
24319
24202
|
if (!model.success) return void 0;
|
|
24320
24203
|
const thinkingOptionId = harnessThinkingOptionIdSchema.safeParse(value.thinkingOptionId);
|
|
@@ -24331,9 +24214,9 @@ ${error51.stderrTail}`] : []
|
|
|
24331
24214
|
const raw = storage.getItem(RENDERER_NEW_THREAD_PREFERENCE_KEY);
|
|
24332
24215
|
if (!raw) return void 0;
|
|
24333
24216
|
const parsed = JSON.parse(raw);
|
|
24334
|
-
if (!
|
|
24217
|
+
if (!isRecord10(parsed) || parsed.version !== 1) return void 0;
|
|
24335
24218
|
if (!KNOWN_RENDERER_AGENTS.some((agent) => agent === parsed.lastAgent)) return void 0;
|
|
24336
|
-
const externalByAgent =
|
|
24219
|
+
const externalByAgent = isRecord10(parsed.externalByAgent) ? parsed.externalByAgent : {};
|
|
24337
24220
|
const parsedExternal = Object.fromEntries(
|
|
24338
24221
|
KNOWN_RENDERER_AGENTS.filter(
|
|
24339
24222
|
(agent) => agent !== "codex"
|
|
@@ -24409,7 +24292,7 @@ ${error51.stderrTail}`] : []
|
|
|
24409
24292
|
var GET_LOCALE_OVERRIDE_URL = "vscode://codex/get-setting";
|
|
24410
24293
|
var GET_LOCALE_INFO_URL = "vscode://codex/locale-info";
|
|
24411
24294
|
var DEFAULT_LOCALE_REQUEST_TIMEOUT_MS = 750;
|
|
24412
|
-
function
|
|
24295
|
+
function isRecord11(value) {
|
|
24413
24296
|
return typeof value === "object" && value !== null && !Array.isArray(value);
|
|
24414
24297
|
}
|
|
24415
24298
|
function canonicalLocale(value) {
|
|
@@ -24431,7 +24314,7 @@ ${error51.stderrTail}`] : []
|
|
|
24431
24314
|
return new DOMException("The operation was aborted", "AbortError");
|
|
24432
24315
|
}
|
|
24433
24316
|
function parseLocaleOverride(value) {
|
|
24434
|
-
if (!
|
|
24317
|
+
if (!isRecord11(value) || !("value" in value)) {
|
|
24435
24318
|
throw new Error("Codex locale override response is malformed");
|
|
24436
24319
|
}
|
|
24437
24320
|
if (value.value === null) return { value: null };
|
|
@@ -24446,7 +24329,7 @@ ${error51.stderrTail}`] : []
|
|
|
24446
24329
|
return locale;
|
|
24447
24330
|
}
|
|
24448
24331
|
function parseLocaleInfo(value) {
|
|
24449
|
-
if (!
|
|
24332
|
+
if (!isRecord11(value)) throw new Error("Codex locale info response is malformed");
|
|
24450
24333
|
return {
|
|
24451
24334
|
ideLocale: optionalLocale(value.ideLocale, "IDE locale"),
|
|
24452
24335
|
systemLocale: optionalLocale(value.systemLocale, "system locale")
|
|
@@ -24475,7 +24358,7 @@ ${error51.stderrTail}`] : []
|
|
|
24475
24358
|
const onAbort = () => settle(() => reject(abortError2()));
|
|
24476
24359
|
const onMessage = (event) => {
|
|
24477
24360
|
const message2 = event.data;
|
|
24478
|
-
if (!
|
|
24361
|
+
if (!isRecord11(message2) || message2.type !== "fetch-response") return;
|
|
24479
24362
|
if (message2.requestId !== requestId) return;
|
|
24480
24363
|
if (message2.responseType !== "success" || typeof message2.status !== "number" || message2.status < 200 || message2.status >= 300 || typeof message2.bodyJsonString !== "string") {
|
|
24481
24364
|
settle(() => reject(new Error("Codex locale request failed")));
|
|
@@ -25573,7 +25456,6 @@ ${error51.stderrTail}`] : []
|
|
|
25573
25456
|
trigger.type = "button";
|
|
25574
25457
|
trigger.className = "settings-icon-button";
|
|
25575
25458
|
trigger.title = input.triggerLabel ?? input.label;
|
|
25576
|
-
trigger.disabled = input.disabled ?? false;
|
|
25577
25459
|
trigger.dataset.accountFocus = input.focusKey;
|
|
25578
25460
|
trigger.setAttribute("aria-label", trigger.title);
|
|
25579
25461
|
trigger.setAttribute("aria-haspopup", "dialog");
|
|
@@ -25599,20 +25481,7 @@ ${error51.stderrTail}`] : []
|
|
|
25599
25481
|
dialog.addEventListener("close", () => {
|
|
25600
25482
|
if (trigger.isConnected && !trigger.disabled) trigger.focus({ preventScroll: true });
|
|
25601
25483
|
});
|
|
25602
|
-
dialog.
|
|
25603
|
-
"click",
|
|
25604
|
-
(event) => {
|
|
25605
|
-
if (input.actions.some((action) => action.contains(event.target))) {
|
|
25606
|
-
trigger.focus({ preventScroll: true });
|
|
25607
|
-
dialog.close();
|
|
25608
|
-
}
|
|
25609
|
-
},
|
|
25610
|
-
{ capture: true }
|
|
25611
|
-
);
|
|
25612
|
-
const actions = document2.createElement("div");
|
|
25613
|
-
actions.className = "settings-account-dialog__actions";
|
|
25614
|
-
actions.append(...input.actions);
|
|
25615
|
-
dialog.append(close, heading, description, actions);
|
|
25484
|
+
dialog.append(close, heading, description);
|
|
25616
25485
|
trigger.addEventListener("click", () => dialog.showModal());
|
|
25617
25486
|
root.append(trigger, dialog);
|
|
25618
25487
|
return root;
|
|
@@ -25737,36 +25606,86 @@ ${error51.stderrTail}`] : []
|
|
|
25737
25606
|
const mode = display === "remaining" ? messages.accountCreditsRemaining : messages.accountCreditsUsed;
|
|
25738
25607
|
return `${creditsPeriodLabel2(period, messages)}${messages.locale === "zh-CN" ? "" : " "}${mode}`;
|
|
25739
25608
|
}
|
|
25740
|
-
function
|
|
25741
|
-
|
|
25609
|
+
function comparisonPeriod(periodType) {
|
|
25610
|
+
if (periodType === "five_hour") return "five_hour";
|
|
25611
|
+
if (periodType === "weekly" || periodType === "seven_day") return "seven_day";
|
|
25612
|
+
return null;
|
|
25613
|
+
}
|
|
25614
|
+
function scopedUsageProduct(product) {
|
|
25615
|
+
const suffixes = [
|
|
25616
|
+
[" \xB7 5-hour window", "five_hour"],
|
|
25617
|
+
[" \xB7 Weekly window", "seven_day"],
|
|
25618
|
+
[" \xB7 7-day window", "seven_day"],
|
|
25619
|
+
[" \xB7 5-hour", "five_hour"],
|
|
25620
|
+
[" \xB7 7-day", "seven_day"]
|
|
25621
|
+
];
|
|
25622
|
+
for (const [suffix, period] of suffixes) {
|
|
25623
|
+
if (!product.endsWith(suffix)) continue;
|
|
25624
|
+
const scope = product.slice(0, -suffix.length).trim();
|
|
25625
|
+
if (scope) return { scope, period };
|
|
25626
|
+
}
|
|
25627
|
+
return null;
|
|
25628
|
+
}
|
|
25629
|
+
function splitUsageWindows(credits, messages, filter) {
|
|
25630
|
+
const generic = { columns: {} };
|
|
25631
|
+
const scopedRows = /* @__PURE__ */ new Map();
|
|
25742
25632
|
const additional = [];
|
|
25633
|
+
const addScoped = (scope, period, window2) => {
|
|
25634
|
+
const rows2 = scopedRows.get(scope) ?? [];
|
|
25635
|
+
let row = rows2.find((candidate) => !candidate.columns[period]);
|
|
25636
|
+
if (!row) {
|
|
25637
|
+
row = { scope, columns: {} };
|
|
25638
|
+
rows2.push(row);
|
|
25639
|
+
scopedRows.set(scope, rows2);
|
|
25640
|
+
}
|
|
25641
|
+
row.columns[period] = { ...window2, label: scope, scoped: true };
|
|
25642
|
+
};
|
|
25643
|
+
const addWindow = (window2, period, scope) => {
|
|
25644
|
+
if (scope && period) addScoped(scope, period, window2);
|
|
25645
|
+
else if (!scope && period && !generic.columns[period]) generic.columns[period] = window2;
|
|
25646
|
+
else additional.push(window2);
|
|
25647
|
+
};
|
|
25743
25648
|
if (credits.usedPercent !== void 0) {
|
|
25744
25649
|
const primary = {
|
|
25745
25650
|
label: credits.label ?? creditsPeriodLabel2(credits.periodType, messages),
|
|
25746
25651
|
usedPercent: credits.usedPercent,
|
|
25747
|
-
resetsAt: credits.resetsAt
|
|
25652
|
+
resetsAt: credits.resetsAt,
|
|
25653
|
+
scoped: Boolean(credits.label && scopedUsageProduct(credits.label))
|
|
25748
25654
|
};
|
|
25749
|
-
|
|
25750
|
-
|
|
25751
|
-
|
|
25752
|
-
|
|
25655
|
+
const primaryScope = credits.label ? scopedUsageProduct(credits.label) : null;
|
|
25656
|
+
addWindow(
|
|
25657
|
+
primary,
|
|
25658
|
+
primaryScope?.period ?? (credits.label ? null : comparisonPeriod(credits.periodType)),
|
|
25659
|
+
primaryScope?.scope
|
|
25660
|
+
);
|
|
25753
25661
|
}
|
|
25754
25662
|
for (const product of credits.productUsage ?? []) {
|
|
25663
|
+
const scoped = scopedUsageProduct(product.product);
|
|
25755
25664
|
const window2 = {
|
|
25756
25665
|
label: creditsProductLabel(product.product, messages),
|
|
25757
25666
|
usedPercent: product.usagePercent,
|
|
25758
|
-
resetsAt: product.resetsAt
|
|
25667
|
+
resetsAt: product.resetsAt,
|
|
25668
|
+
scoped: Boolean(scoped)
|
|
25759
25669
|
};
|
|
25760
|
-
const
|
|
25761
|
-
|
|
25762
|
-
|
|
25763
|
-
|
|
25764
|
-
|
|
25765
|
-
|
|
25670
|
+
const genericPeriod = product.product === "5-hour window" ? "five_hour" : product.product === "7-day window" ? "seven_day" : null;
|
|
25671
|
+
addWindow(window2, scoped?.period ?? genericPeriod, scoped?.scope);
|
|
25672
|
+
}
|
|
25673
|
+
const structured = [...scopedRows.values()].flat();
|
|
25674
|
+
let rows = Object.keys(generic.columns).length > 0 ? [generic, ...structured] : structured;
|
|
25675
|
+
if (rows.length === 0) rows = [generic];
|
|
25676
|
+
if (filter === "weekly-only") {
|
|
25677
|
+
rows = rows.map((row) => ({
|
|
25678
|
+
...row,
|
|
25679
|
+
columns: row.columns.seven_day ? { seven_day: row.columns.seven_day } : {}
|
|
25680
|
+
})).filter((row) => row.columns.seven_day);
|
|
25681
|
+
if (rows.length === 0) rows = [{ columns: {} }];
|
|
25682
|
+
return { rows, additional: [] };
|
|
25683
|
+
}
|
|
25684
|
+
return { rows, additional };
|
|
25766
25685
|
}
|
|
25767
25686
|
function renderUsageWindow(document2, window2, messages, display) {
|
|
25768
25687
|
const meter = document2.createElement("div");
|
|
25769
|
-
meter.className = "settings-account-usage__meter";
|
|
25688
|
+
meter.className = window2.scoped ? "settings-account-usage__meter settings-account-usage__meter--scoped" : "settings-account-usage__meter";
|
|
25770
25689
|
const label = document2.createElement("span");
|
|
25771
25690
|
label.className = "settings-account-usage__title";
|
|
25772
25691
|
label.textContent = window2.label;
|
|
@@ -25795,7 +25714,9 @@ ${error51.stderrTail}`] : []
|
|
|
25795
25714
|
if (reset) meter.append(reset.timestamp);
|
|
25796
25715
|
return meter;
|
|
25797
25716
|
}
|
|
25798
|
-
function renderAccountUsage(document2, state, messages, display, onRetry,
|
|
25717
|
+
function renderAccountUsage(document2, state, messages, display, onRetry, options = {}) {
|
|
25718
|
+
const usageColumns = options.usageColumns ?? 2;
|
|
25719
|
+
const filter = options.filter ?? "all";
|
|
25799
25720
|
if (state?.status !== "ready") {
|
|
25800
25721
|
const cell = document2.createElement("td");
|
|
25801
25722
|
cell.colSpan = usageColumns;
|
|
@@ -25817,7 +25738,7 @@ ${error51.stderrTail}`] : []
|
|
|
25817
25738
|
usage.append(retry);
|
|
25818
25739
|
}
|
|
25819
25740
|
cell.append(usage);
|
|
25820
|
-
return { cells: [cell], additional: null };
|
|
25741
|
+
return { cells: [cell], continuationCells: [], additional: null };
|
|
25821
25742
|
}
|
|
25822
25743
|
const credits = state.credits;
|
|
25823
25744
|
if (credits.remaining !== void 0 && credits.unit && credits.usedPercent === void 0) {
|
|
@@ -25841,20 +25762,20 @@ ${error51.stderrTail}`] : []
|
|
|
25841
25762
|
meter.append(value);
|
|
25842
25763
|
usage.append(meter);
|
|
25843
25764
|
cell.append(usage);
|
|
25844
|
-
return { cells: [cell], additional: null };
|
|
25765
|
+
return { cells: [cell], continuationCells: [], additional: null };
|
|
25845
25766
|
}
|
|
25846
|
-
const {
|
|
25847
|
-
const
|
|
25767
|
+
const { rows, additional } = splitUsageWindows(credits, messages, filter);
|
|
25768
|
+
const renderCells = (row) => ["five_hour", "seven_day"].map((period) => {
|
|
25848
25769
|
const cell = document2.createElement("td");
|
|
25849
25770
|
cell.className = "settings-account-usage-cell";
|
|
25850
|
-
const window2 = columns[period];
|
|
25771
|
+
const window2 = row.columns[period];
|
|
25851
25772
|
if (window2) cell.append(renderUsageWindow(document2, window2, messages, display));
|
|
25852
25773
|
else {
|
|
25853
25774
|
const missing = document2.createElement("div");
|
|
25854
25775
|
missing.className = "settings-account-usage__missing";
|
|
25855
25776
|
const label = document2.createElement("span");
|
|
25856
25777
|
label.className = "settings-account-usage__title";
|
|
25857
|
-
label.textContent = creditsPeriodLabel2(period, messages);
|
|
25778
|
+
label.textContent = row.scope ?? creditsPeriodLabel2(period, messages);
|
|
25858
25779
|
const dash = document2.createElement("span");
|
|
25859
25780
|
dash.textContent = "\u2014";
|
|
25860
25781
|
dash.setAttribute("aria-hidden", "true");
|
|
@@ -25863,14 +25784,17 @@ ${error51.stderrTail}`] : []
|
|
|
25863
25784
|
}
|
|
25864
25785
|
return cell;
|
|
25865
25786
|
});
|
|
25866
|
-
|
|
25787
|
+
const [firstRow = { columns: {} }, ...continuations] = rows;
|
|
25788
|
+
const cells = renderCells(firstRow);
|
|
25789
|
+
const continuationCells = continuations.map(renderCells);
|
|
25790
|
+
if (!additional.length) return { cells, continuationCells, additional: null };
|
|
25867
25791
|
const extra = document2.createElement("div");
|
|
25868
25792
|
extra.className = "settings-account-extra-usage";
|
|
25869
25793
|
for (const window2 of additional)
|
|
25870
25794
|
extra.append(renderUsageWindow(document2, window2, messages, display));
|
|
25871
|
-
return { cells, additional: extra };
|
|
25795
|
+
return { cells, continuationCells, additional: extra };
|
|
25872
25796
|
}
|
|
25873
|
-
function renderAccountResetCredits(document2, credits, messages
|
|
25797
|
+
function renderAccountResetCredits(document2, credits, messages) {
|
|
25874
25798
|
const resetCredits = credits.resetCredits;
|
|
25875
25799
|
if (!resetCredits) return null;
|
|
25876
25800
|
const summary = document2.createElement("button");
|
|
@@ -25916,15 +25840,6 @@ ${error51.stderrTail}`] : []
|
|
|
25916
25840
|
copy.append(list);
|
|
25917
25841
|
}
|
|
25918
25842
|
details.append(copy);
|
|
25919
|
-
if (options.onUseReset) {
|
|
25920
|
-
const use = document2.createElement("button");
|
|
25921
|
-
use.type = "button";
|
|
25922
|
-
use.className = "settings-command-button settings-command-button--secondary";
|
|
25923
|
-
use.textContent = options.usingReset ? messages.accountResetCreditsUsing : messages.accountResetCreditsUse;
|
|
25924
|
-
use.disabled = options.resetDisabled;
|
|
25925
|
-
use.addEventListener("click", options.onUseReset);
|
|
25926
|
-
details.append(use);
|
|
25927
|
-
}
|
|
25928
25843
|
return { summary, details };
|
|
25929
25844
|
}
|
|
25930
25845
|
|
|
@@ -25965,7 +25880,7 @@ ${error51.stderrTail}`] : []
|
|
|
25965
25880
|
(row ?? fallback).focus({ preventScroll: true });
|
|
25966
25881
|
};
|
|
25967
25882
|
}
|
|
25968
|
-
function createAccountsTable(document2, messages, kind) {
|
|
25883
|
+
function createAccountsTable(document2, messages, kind = "chatgpt") {
|
|
25969
25884
|
const table = document2.createElement("table");
|
|
25970
25885
|
table.className = `settings-account-table settings-account-table--${kind}`;
|
|
25971
25886
|
table.setAttribute(
|
|
@@ -25984,7 +25899,7 @@ ${error51.stderrTail}`] : []
|
|
|
25984
25899
|
const updateDisplay = (display) => {
|
|
25985
25900
|
const labels = kind === "api" ? [
|
|
25986
25901
|
messages.accountColumnAccount,
|
|
25987
|
-
messages.
|
|
25902
|
+
messages.accountColumnCredits,
|
|
25988
25903
|
messages.accountColumnActions
|
|
25989
25904
|
] : [
|
|
25990
25905
|
messages.accountColumnAccount,
|
|
@@ -26080,86 +25995,46 @@ ${error51.stderrTail}`] : []
|
|
|
26080
25995
|
agent: "Codex",
|
|
26081
25996
|
plan: accountPlanLabel(account.planType),
|
|
26082
25997
|
highlighted: account.planType === "pro" || account.planType === "prolite",
|
|
26083
|
-
active:
|
|
25998
|
+
active: input.current,
|
|
26084
25999
|
mark
|
|
26085
26000
|
})
|
|
26086
26001
|
);
|
|
26087
|
-
const
|
|
26088
|
-
|
|
26089
|
-
|
|
26090
|
-
|
|
26091
|
-
messages,
|
|
26092
|
-
input.display,
|
|
26093
|
-
input.onRetry,
|
|
26094
|
-
usageColumns
|
|
26095
|
-
);
|
|
26002
|
+
const usage = renderAccountUsage(document2, input.usage, messages, input.display, input.onRetry, {
|
|
26003
|
+
usageColumns: authKind === "api" ? 1 : 2,
|
|
26004
|
+
filter: account.planType === "pro" ? "weekly-only" : "all"
|
|
26005
|
+
});
|
|
26096
26006
|
if (usage.additional) personCell.append(usage.additional);
|
|
26097
26007
|
const actionsCell = document2.createElement("td");
|
|
26098
26008
|
actionsCell.className = "settings-account-management-cell";
|
|
26099
26009
|
const management = document2.createElement("div");
|
|
26100
26010
|
management.className = "settings-account-management";
|
|
26101
|
-
|
|
26102
|
-
actions.className = "settings-account-actions";
|
|
26103
|
-
if (!account.active) {
|
|
26104
|
-
const activate = document2.createElement("button");
|
|
26105
|
-
activate.type = "button";
|
|
26106
|
-
activate.className = "settings-account-action";
|
|
26107
|
-
activate.textContent = messages.accountUse;
|
|
26108
|
-
activate.title = messages.accountDefaultHint;
|
|
26109
|
-
activate.dataset.accountFocus = `${account.accountId}:activate`;
|
|
26110
|
-
activate.disabled = input.actionsDisabled;
|
|
26111
|
-
activate.addEventListener("click", input.onActivate);
|
|
26112
|
-
actions.append(activate);
|
|
26113
|
-
}
|
|
26114
|
-
if (authKind !== "api" && !account.email) {
|
|
26115
|
-
const signIn = document2.createElement("button");
|
|
26116
|
-
signIn.type = "button";
|
|
26117
|
-
signIn.className = "settings-account-action";
|
|
26118
|
-
signIn.textContent = messages.accountSignIn;
|
|
26119
|
-
signIn.dataset.accountFocus = `${account.accountId}:login`;
|
|
26120
|
-
signIn.disabled = input.actionsDisabled;
|
|
26121
|
-
signIn.addEventListener("click", input.onSignIn);
|
|
26122
|
-
actions.append(signIn);
|
|
26123
|
-
}
|
|
26124
|
-
const more = [];
|
|
26125
|
-
if (account.email && input.usage) {
|
|
26011
|
+
if (input.usage) {
|
|
26126
26012
|
const refresh = document2.createElement("button");
|
|
26127
26013
|
refresh.type = "button";
|
|
26128
26014
|
refresh.className = "settings-account-action";
|
|
26129
26015
|
refresh.textContent = messages.accountCreditsRefresh;
|
|
26130
26016
|
refresh.dataset.accountFocus = `${account.accountId}:refresh`;
|
|
26131
|
-
refresh.disabled = input.
|
|
26017
|
+
refresh.disabled = input.usage.status === "loading";
|
|
26132
26018
|
refresh.addEventListener("click", input.onRetry);
|
|
26133
|
-
|
|
26134
|
-
}
|
|
26135
|
-
if (!account.isDefault) {
|
|
26136
|
-
const remove = document2.createElement("button");
|
|
26137
|
-
remove.type = "button";
|
|
26138
|
-
remove.className = "settings-account-action settings-account-delete";
|
|
26139
|
-
remove.textContent = messages.accountDelete;
|
|
26140
|
-
remove.dataset.accountFocus = `${account.accountId}:delete`;
|
|
26141
|
-
remove.setAttribute("aria-label", `${messages.accountDelete}: ${name.full}`);
|
|
26142
|
-
remove.disabled = input.actionsDisabled;
|
|
26143
|
-
remove.addEventListener("click", input.onDelete);
|
|
26144
|
-
more.push(remove);
|
|
26145
|
-
}
|
|
26146
|
-
if (more.length)
|
|
26147
|
-
actions.append(
|
|
26148
|
-
createAccountDetails(document2, messages, {
|
|
26149
|
-
label: messages.accountMore,
|
|
26150
|
-
triggerLabel: `${name.full} \xB7 ${messages.accountMore}`,
|
|
26151
|
-
description: name.full,
|
|
26152
|
-
focusKey: `${account.accountId}:more`,
|
|
26153
|
-
icon: "ellipsis",
|
|
26154
|
-
disabled: input.actionsDisabled,
|
|
26155
|
-
actions: more
|
|
26156
|
-
})
|
|
26157
|
-
);
|
|
26158
|
-
management.append(actions);
|
|
26019
|
+
management.append(refresh);
|
|
26020
|
+
}
|
|
26159
26021
|
actionsCell.append(management);
|
|
26022
|
+
const continuationRows = usage.continuationCells.map((cells) => {
|
|
26023
|
+
const continuation = document2.createElement("tr");
|
|
26024
|
+
continuation.className = "settings-account-row settings-account-quota-continuation-row";
|
|
26025
|
+
continuation.dataset.accountId = account.accountId;
|
|
26026
|
+
continuation.append(...cells);
|
|
26027
|
+
return continuation;
|
|
26028
|
+
});
|
|
26029
|
+
if (continuationRows.length > 0) {
|
|
26030
|
+
personCell.rowSpan = continuationRows.length + 1;
|
|
26031
|
+
personCell.className += " settings-account-spanning-cell";
|
|
26032
|
+
actionsCell.rowSpan = continuationRows.length + 1;
|
|
26033
|
+
actionsCell.className += " settings-account-spanning-cell";
|
|
26034
|
+
}
|
|
26160
26035
|
row.append(personCell, ...usage.cells, actionsCell);
|
|
26161
|
-
const reset = input.usage?.status === "ready" ? renderAccountResetCredits(document2, input.usage.credits, messages
|
|
26162
|
-
if (!reset) return [row];
|
|
26036
|
+
const reset = input.usage?.status === "ready" ? renderAccountResetCredits(document2, input.usage.credits, messages) : null;
|
|
26037
|
+
if (!reset) return [row, ...continuationRows];
|
|
26163
26038
|
const detailsRow = document2.createElement("tr");
|
|
26164
26039
|
detailsRow.className = "settings-account-details-row";
|
|
26165
26040
|
detailsRow.id = `settings-account-reset-${++resetDetailsSequence}`;
|
|
@@ -26177,9 +26052,9 @@ ${error51.stderrTail}`] : []
|
|
|
26177
26052
|
input.onResetExpanded(!detailsRow.hidden);
|
|
26178
26053
|
});
|
|
26179
26054
|
management.append(reset.summary);
|
|
26180
|
-
return [row, detailsRow];
|
|
26055
|
+
return [row, ...continuationRows, detailsRow];
|
|
26181
26056
|
}
|
|
26182
|
-
function
|
|
26057
|
+
function renderHarnessAccountRows(document2, account, messages, display) {
|
|
26183
26058
|
const row = document2.createElement("tr");
|
|
26184
26059
|
row.className = "settings-account-row";
|
|
26185
26060
|
row.dataset.harnessId = account.harnessId;
|
|
@@ -26203,10 +26078,11 @@ ${error51.stderrTail}`] : []
|
|
|
26203
26078
|
);
|
|
26204
26079
|
const usage = renderAccountUsage(
|
|
26205
26080
|
document2,
|
|
26206
|
-
{ status: "ready", credits: account.credits },
|
|
26081
|
+
{ status: "ready", credits: account.credits, freshness: "live", observedAt: null },
|
|
26207
26082
|
messages,
|
|
26208
26083
|
display,
|
|
26209
|
-
() => void 0
|
|
26084
|
+
() => void 0,
|
|
26085
|
+
{ filter: account.harnessId === "grok" ? "weekly-only" : "all" }
|
|
26210
26086
|
);
|
|
26211
26087
|
if (usage.additional) personCell.append(usage.additional);
|
|
26212
26088
|
const managementCell = document2.createElement("td");
|
|
@@ -26219,19 +26095,75 @@ ${error51.stderrTail}`] : []
|
|
|
26219
26095
|
label: `${account.harnessName} \xB7 ${messages.accountNativeManaged}`,
|
|
26220
26096
|
description: messages.accountNativeManagementHint.replace("{harness}", account.harnessName),
|
|
26221
26097
|
focusKey: `harness:${account.harnessId}:info`,
|
|
26222
|
-
icon: "info"
|
|
26223
|
-
actions: []
|
|
26098
|
+
icon: "info"
|
|
26224
26099
|
});
|
|
26225
26100
|
management.append(label, info);
|
|
26226
26101
|
managementCell.append(management);
|
|
26102
|
+
const continuationRows = usage.continuationCells.map((cells) => {
|
|
26103
|
+
const continuation = document2.createElement("tr");
|
|
26104
|
+
continuation.className = "settings-account-row settings-account-quota-continuation-row";
|
|
26105
|
+
continuation.dataset.harnessId = account.harnessId;
|
|
26106
|
+
continuation.append(...cells);
|
|
26107
|
+
return continuation;
|
|
26108
|
+
});
|
|
26109
|
+
if (continuationRows.length > 0) {
|
|
26110
|
+
personCell.rowSpan = continuationRows.length + 1;
|
|
26111
|
+
personCell.className += " settings-account-spanning-cell";
|
|
26112
|
+
managementCell.rowSpan = continuationRows.length + 1;
|
|
26113
|
+
managementCell.className += " settings-account-spanning-cell";
|
|
26114
|
+
}
|
|
26227
26115
|
row.append(personCell, ...usage.cells, managementCell);
|
|
26228
|
-
return row;
|
|
26116
|
+
return [row, ...continuationRows];
|
|
26229
26117
|
}
|
|
26230
26118
|
|
|
26231
26119
|
// src/settings/harness-accounts.ts
|
|
26120
|
+
function sortedAccounts(accounts) {
|
|
26121
|
+
return [...accounts].sort((a, b) => {
|
|
26122
|
+
if (a.harnessId === "antigravity") return b.harnessId === "antigravity" ? 0 : 1;
|
|
26123
|
+
if (b.harnessId === "antigravity") return -1;
|
|
26124
|
+
return a.harnessId.localeCompare(b.harnessId);
|
|
26125
|
+
});
|
|
26126
|
+
}
|
|
26232
26127
|
function createHarnessAccounts(signal, getClient, onChange) {
|
|
26233
26128
|
let accounts = [];
|
|
26234
26129
|
let refreshing = false;
|
|
26130
|
+
const loadProgressively = async (client, force) => {
|
|
26131
|
+
let sources;
|
|
26132
|
+
try {
|
|
26133
|
+
sources = await client.listHarnessAccountSources();
|
|
26134
|
+
} catch {
|
|
26135
|
+
return false;
|
|
26136
|
+
}
|
|
26137
|
+
if (signal.aborted) return true;
|
|
26138
|
+
const byHarnessId = new Map(accounts.map((account) => [account.harnessId, account]));
|
|
26139
|
+
await Promise.all(
|
|
26140
|
+
sources.sources.map(async (source) => {
|
|
26141
|
+
try {
|
|
26142
|
+
const result = await client.inspectHarnessAccount({
|
|
26143
|
+
harnessId: source.harnessId,
|
|
26144
|
+
...force ? { refresh: true } : {}
|
|
26145
|
+
});
|
|
26146
|
+
if (signal.aborted || result.harnessId !== source.harnessId) return;
|
|
26147
|
+
if (result.account) {
|
|
26148
|
+
byHarnessId.set(result.harnessId, {
|
|
26149
|
+
...result.account,
|
|
26150
|
+
harnessId: result.harnessId,
|
|
26151
|
+
harnessName: result.harnessName
|
|
26152
|
+
});
|
|
26153
|
+
} else {
|
|
26154
|
+
byHarnessId.delete(source.harnessId);
|
|
26155
|
+
}
|
|
26156
|
+
} catch {
|
|
26157
|
+
if (!signal.aborted) byHarnessId.delete(source.harnessId);
|
|
26158
|
+
}
|
|
26159
|
+
if (!signal.aborted) {
|
|
26160
|
+
accounts = sortedAccounts(byHarnessId.values());
|
|
26161
|
+
onChange();
|
|
26162
|
+
}
|
|
26163
|
+
})
|
|
26164
|
+
);
|
|
26165
|
+
return true;
|
|
26166
|
+
};
|
|
26235
26167
|
return {
|
|
26236
26168
|
get accounts() {
|
|
26237
26169
|
return accounts;
|
|
@@ -26239,16 +26171,25 @@ ${error51.stderrTail}`] : []
|
|
|
26239
26171
|
get refreshing() {
|
|
26240
26172
|
return refreshing;
|
|
26241
26173
|
},
|
|
26242
|
-
async refresh() {
|
|
26174
|
+
async refresh(force = false) {
|
|
26243
26175
|
if (refreshing || signal.aborted) return;
|
|
26244
26176
|
const client = getClient();
|
|
26245
|
-
if (!client
|
|
26177
|
+
if (!client) return;
|
|
26246
26178
|
refreshing = true;
|
|
26179
|
+
accounts = [];
|
|
26247
26180
|
onChange();
|
|
26248
26181
|
try {
|
|
26249
|
-
const
|
|
26250
|
-
|
|
26251
|
-
|
|
26182
|
+
const progressive = client.listHarnessAccountSources && client.inspectHarnessAccount ? await loadProgressively(
|
|
26183
|
+
{
|
|
26184
|
+
listHarnessAccountSources: client.listHarnessAccountSources.bind(client),
|
|
26185
|
+
inspectHarnessAccount: client.inspectHarnessAccount.bind(client)
|
|
26186
|
+
},
|
|
26187
|
+
force
|
|
26188
|
+
) : false;
|
|
26189
|
+
if (progressive || signal.aborted) return;
|
|
26190
|
+
if (!client.listHarnessAccounts) return;
|
|
26191
|
+
const result = await client.listHarnessAccounts(force ? { refresh: true } : {});
|
|
26192
|
+
if (!signal.aborted) accounts = sortedAccounts(result.accounts);
|
|
26252
26193
|
} catch {
|
|
26253
26194
|
if (!signal.aborted) accounts = [];
|
|
26254
26195
|
} finally {
|
|
@@ -26263,9 +26204,6 @@ ${error51.stderrTail}`] : []
|
|
|
26263
26204
|
function errorMessage(error51, fallback) {
|
|
26264
26205
|
return error51 instanceof Error && error51.message ? error51.message : fallback;
|
|
26265
26206
|
}
|
|
26266
|
-
function accountHasUsage(account) {
|
|
26267
|
-
return account.authKind === "api" || Boolean(account.email);
|
|
26268
|
-
}
|
|
26269
26207
|
function createAccountsSettingsPage(messages, getClient) {
|
|
26270
26208
|
return Object.freeze({
|
|
26271
26209
|
id: "accounts",
|
|
@@ -26274,20 +26212,16 @@ ${error51.stderrTail}`] : []
|
|
|
26274
26212
|
mount(context) {
|
|
26275
26213
|
const document2 = context.content.ownerDocument;
|
|
26276
26214
|
const header = document2.createElement("div");
|
|
26277
|
-
header.className = "settings-
|
|
26278
|
-
const
|
|
26279
|
-
const heading = document2.createElement("
|
|
26215
|
+
header.className = "settings-connection-page-header";
|
|
26216
|
+
const headingCopy = document2.createElement("div");
|
|
26217
|
+
const heading = document2.createElement("div");
|
|
26280
26218
|
heading.className = "settings-section-label";
|
|
26281
26219
|
heading.textContent = messages.pageLabels.accounts;
|
|
26282
26220
|
const description = document2.createElement("p");
|
|
26283
26221
|
description.className = "settings-page-description";
|
|
26284
26222
|
description.textContent = messages.accountsDescription;
|
|
26285
|
-
|
|
26286
|
-
|
|
26287
|
-
add.type = "button";
|
|
26288
|
-
add.className = "settings-command-button settings-command-button--secondary";
|
|
26289
|
-
add.append(createRendererSettingsIcon("add", 15), messages.accountAdd);
|
|
26290
|
-
header.append(copy, add);
|
|
26223
|
+
headingCopy.append(heading, description);
|
|
26224
|
+
header.append(headingCopy);
|
|
26291
26225
|
const status = document2.createElement("p");
|
|
26292
26226
|
status.className = "settings-account-status";
|
|
26293
26227
|
status.setAttribute("aria-live", "polite");
|
|
@@ -26310,11 +26244,14 @@ ${error51.stderrTail}`] : []
|
|
|
26310
26244
|
search.setAttribute("aria-label", messages.accountSearch);
|
|
26311
26245
|
searchWrapper.append(createRendererSettingsIcon("search", 16), search);
|
|
26312
26246
|
const displayControls = document2.createElement("div");
|
|
26313
|
-
displayControls.className = "settings-
|
|
26247
|
+
displayControls.className = "settings-segmented";
|
|
26248
|
+
displayControls.setAttribute("role", "group");
|
|
26249
|
+
displayControls.setAttribute("aria-label", messages.accountColumnCredits);
|
|
26314
26250
|
const displayButtons = /* @__PURE__ */ new Map();
|
|
26315
26251
|
for (const display of ["used", "remaining"]) {
|
|
26316
26252
|
const button = document2.createElement("button");
|
|
26317
26253
|
button.type = "button";
|
|
26254
|
+
button.className = "settings-segmented__item";
|
|
26318
26255
|
button.textContent = display === "used" ? messages.accountCreditsUsed : messages.accountCreditsRemaining;
|
|
26319
26256
|
button.addEventListener("click", () => {
|
|
26320
26257
|
usageDisplay = display;
|
|
@@ -26332,7 +26269,7 @@ ${error51.stderrTail}`] : []
|
|
|
26332
26269
|
refreshUsage.addEventListener("click", () => {
|
|
26333
26270
|
usageByAccountId.clear();
|
|
26334
26271
|
loadUsage(accounts);
|
|
26335
|
-
void harnessAccounts?.refresh();
|
|
26272
|
+
void harnessAccounts?.refresh(true);
|
|
26336
26273
|
});
|
|
26337
26274
|
search.addEventListener("input", () => render());
|
|
26338
26275
|
toolbar.append(connected, searchWrapper, displayControls, refreshUsage);
|
|
@@ -26343,140 +26280,38 @@ ${error51.stderrTail}`] : []
|
|
|
26343
26280
|
context.content.append(header, status, toolbar, groups);
|
|
26344
26281
|
const stopCountdowns = mountAccountResetCountdowns(groups, messages, context.signal);
|
|
26345
26282
|
let accounts = [];
|
|
26346
|
-
let
|
|
26347
|
-
let
|
|
26348
|
-
let
|
|
26349
|
-
let
|
|
26350
|
-
let
|
|
26351
|
-
let
|
|
26352
|
-
let loginRefreshTimer;
|
|
26283
|
+
let currentAccountId = null;
|
|
26284
|
+
let accountPhase = "unavailable";
|
|
26285
|
+
let accountRevision = 0;
|
|
26286
|
+
let accountInstanceId;
|
|
26287
|
+
let hasAccountSnapshot = false;
|
|
26288
|
+
let loadMessage = null;
|
|
26353
26289
|
const usageByAccountId = /* @__PURE__ */ new Map();
|
|
26354
|
-
let usingResetAccountId = null;
|
|
26355
26290
|
let usageDisplay = "remaining";
|
|
26356
26291
|
const expandedResetAccounts = /* @__PURE__ */ new Set();
|
|
26357
|
-
const accountBusy = () => accountCreating || accountActivating || deletingAccountId !== null || login !== null || loginStartingAccountId !== null || usingResetAccountId !== null;
|
|
26358
|
-
const clearLoginRefresh = () => {
|
|
26359
|
-
if (loginRefreshTimer === void 0) return;
|
|
26360
|
-
document2.defaultView?.clearTimeout(loginRefreshTimer);
|
|
26361
|
-
loginRefreshTimer = void 0;
|
|
26362
|
-
};
|
|
26363
|
-
const scheduleLoginRefresh = () => {
|
|
26364
|
-
clearLoginRefresh();
|
|
26365
|
-
if (!login || context.signal.aborted) return;
|
|
26366
|
-
loginRefreshTimer = document2.defaultView?.setTimeout(() => {
|
|
26367
|
-
loginRefreshTimer = void 0;
|
|
26368
|
-
if (!login || context.signal.aborted) return;
|
|
26369
|
-
void context.runLatest(
|
|
26370
|
-
() => client().refreshCodexAccounts?.() ?? client().listCodexAccounts(),
|
|
26371
|
-
{
|
|
26372
|
-
success(result) {
|
|
26373
|
-
const signedIn = result.accounts.some(
|
|
26374
|
-
(account) => account.accountId === login?.accountId && account.email
|
|
26375
|
-
);
|
|
26376
|
-
if (signedIn) {
|
|
26377
|
-
login = null;
|
|
26378
|
-
loginMessage = messages.accountLoginSucceeded;
|
|
26379
|
-
}
|
|
26380
|
-
setAccounts(result.accounts);
|
|
26381
|
-
scheduleLoginRefresh();
|
|
26382
|
-
},
|
|
26383
|
-
failure() {
|
|
26384
|
-
scheduleLoginRefresh();
|
|
26385
|
-
}
|
|
26386
|
-
}
|
|
26387
|
-
);
|
|
26388
|
-
}, 750);
|
|
26389
|
-
};
|
|
26390
|
-
const appendCodexAccount = (body, account) => {
|
|
26391
|
-
body.append(
|
|
26392
|
-
...renderAccountRows(document2, account, messages, {
|
|
26393
|
-
usage: usageByAccountId.get(account.accountId),
|
|
26394
|
-
display: usageDisplay,
|
|
26395
|
-
actionsDisabled: accountBusy(),
|
|
26396
|
-
usingReset: usingResetAccountId === account.accountId,
|
|
26397
|
-
resetDisabled: accountBusy(),
|
|
26398
|
-
resetExpanded: expandedResetAccounts.has(account.accountId),
|
|
26399
|
-
onActivate: () => mutate(() => client().activateCodexAccount({ accountId: account.accountId })),
|
|
26400
|
-
onSignIn: () => startLogin(account.accountId),
|
|
26401
|
-
onDelete: () => deleteAccount(account.accountId),
|
|
26402
|
-
onRetry: () => {
|
|
26403
|
-
usageByAccountId.delete(account.accountId);
|
|
26404
|
-
loadUsage(accounts);
|
|
26405
|
-
},
|
|
26406
|
-
onResetExpanded: (open) => {
|
|
26407
|
-
if (open) expandedResetAccounts.add(account.accountId);
|
|
26408
|
-
else expandedResetAccounts.delete(account.accountId);
|
|
26409
|
-
},
|
|
26410
|
-
...getClient()?.consumeCodexAccountResetCredit ? { onUseReset: () => useReset(account.accountId) } : {}
|
|
26411
|
-
})
|
|
26412
|
-
);
|
|
26413
|
-
if (login?.accountId !== account.accountId) return;
|
|
26414
|
-
const verification = document2.createElement("div");
|
|
26415
|
-
verification.className = "settings-account-verification";
|
|
26416
|
-
const prompt = document2.createElement("span");
|
|
26417
|
-
prompt.textContent = messages.accountVerificationDescription;
|
|
26418
|
-
const link = document2.createElement("a");
|
|
26419
|
-
link.href = login.verificationUrl;
|
|
26420
|
-
link.target = "_blank";
|
|
26421
|
-
link.rel = "noopener noreferrer";
|
|
26422
|
-
link.textContent = login.verificationUrl;
|
|
26423
|
-
link.addEventListener("click", (event) => {
|
|
26424
|
-
const bridge = document2.defaultView?.electronBridge;
|
|
26425
|
-
if (typeof bridge?.sendMessageFromView !== "function") return;
|
|
26426
|
-
event.preventDefault();
|
|
26427
|
-
void Promise.resolve(
|
|
26428
|
-
bridge.sendMessageFromView({
|
|
26429
|
-
type: "open-in-browser",
|
|
26430
|
-
url: login?.verificationUrl ?? link.href,
|
|
26431
|
-
initiator: "open_in_browser_bridge",
|
|
26432
|
-
openTarget: "external-browser",
|
|
26433
|
-
source: "manual"
|
|
26434
|
-
})
|
|
26435
|
-
).catch(() => void 0);
|
|
26436
|
-
});
|
|
26437
|
-
const code = document2.createElement("code");
|
|
26438
|
-
code.textContent = login.userCode;
|
|
26439
|
-
const copyCode = document2.createElement("button");
|
|
26440
|
-
copyCode.type = "button";
|
|
26441
|
-
copyCode.className = "settings-command-button settings-command-button--secondary";
|
|
26442
|
-
copyCode.textContent = messages.accountCopyCode;
|
|
26443
|
-
copyCode.addEventListener("click", () => {
|
|
26444
|
-
void document2.defaultView?.navigator.clipboard?.writeText(login?.userCode ?? "").then(() => {
|
|
26445
|
-
copyCode.textContent = messages.accountCopied;
|
|
26446
|
-
});
|
|
26447
|
-
});
|
|
26448
|
-
const cancel = document2.createElement("button");
|
|
26449
|
-
cancel.type = "button";
|
|
26450
|
-
cancel.className = "settings-command-button settings-command-button--secondary";
|
|
26451
|
-
cancel.textContent = messages.accountLoginCancel;
|
|
26452
|
-
cancel.addEventListener(
|
|
26453
|
-
"click",
|
|
26454
|
-
() => cancelLogin(login?.accountId ?? "", login?.loginId ?? "")
|
|
26455
|
-
);
|
|
26456
|
-
verification.append(prompt, link, code, copyCode, cancel);
|
|
26457
|
-
const verificationRow = document2.createElement("tr");
|
|
26458
|
-
const verificationCell = document2.createElement("td");
|
|
26459
|
-
verificationCell.colSpan = codexAccountAuthKind(account) === "api" ? 3 : 4;
|
|
26460
|
-
verificationCell.append(verification);
|
|
26461
|
-
verificationRow.append(verificationCell);
|
|
26462
|
-
body.append(verificationRow);
|
|
26463
|
-
};
|
|
26464
26292
|
const render = () => {
|
|
26465
26293
|
const restoreFocus = accountListFocusRestorer(groups, search);
|
|
26466
26294
|
apiGroup.body.replaceChildren();
|
|
26467
26295
|
chatGroup.body.replaceChildren();
|
|
26468
|
-
status.
|
|
26296
|
+
status.replaceChildren();
|
|
26297
|
+
if (loadMessage) status.append(loadMessage);
|
|
26469
26298
|
connectedCount.textContent = String(accounts.length + harnessAccounts.accounts.length);
|
|
26470
26299
|
apiGroup.updateDisplay(usageDisplay);
|
|
26471
26300
|
chatGroup.updateDisplay(usageDisplay);
|
|
26472
|
-
search.disabled = login !== null || loginStartingAccountId !== null;
|
|
26473
26301
|
for (const [display, button] of displayButtons) {
|
|
26474
26302
|
button.setAttribute("aria-pressed", String(display === usageDisplay));
|
|
26475
26303
|
}
|
|
26476
|
-
refreshUsage.disabled = (!getClient()?.inspectCodexAccountUsage ||
|
|
26304
|
+
refreshUsage.disabled = (!getClient()?.inspectCodexAccountUsage || accounts.length === 0) && !getClient()?.listHarnessAccounts || harnessAccounts?.refreshing === true || [...usageByAccountId.values()].some((usage) => usage.status === "loading");
|
|
26477
26305
|
const query = search.value.trim().toLocaleLowerCase();
|
|
26478
26306
|
const visibleAccounts = accounts.filter(
|
|
26479
|
-
(account) =>
|
|
26307
|
+
(account) => [
|
|
26308
|
+
"Codex",
|
|
26309
|
+
account.email ?? "",
|
|
26310
|
+
account.label,
|
|
26311
|
+
account.authIdentity ?? "",
|
|
26312
|
+
account.authKind ?? "",
|
|
26313
|
+
accountPlanLabel(account.planType) ?? ""
|
|
26314
|
+
].join(" ").toLocaleLowerCase().includes(query)
|
|
26480
26315
|
);
|
|
26481
26316
|
const visibleApi = visibleAccounts.filter(
|
|
26482
26317
|
(account) => codexAccountAuthKind(account) === "api"
|
|
@@ -26488,7 +26323,6 @@ ${error51.stderrTail}`] : []
|
|
|
26488
26323
|
(account) => `${account.harnessName} ${account.email ?? ""} ${account.label ?? ""} ${account.plan ?? ""}`.toLocaleLowerCase().includes(query)
|
|
26489
26324
|
);
|
|
26490
26325
|
displayControls.hidden = !accounts.some((account) => codexAccountAuthKind(account) !== "api") && harnessAccounts.accounts.length === 0;
|
|
26491
|
-
add.disabled = accountBusy();
|
|
26492
26326
|
groups.replaceChildren();
|
|
26493
26327
|
if (visibleApi.length + visibleChat.length + visibleHarnessAccounts.length === 0) {
|
|
26494
26328
|
const empty = document2.createElement("div");
|
|
@@ -26500,14 +26334,48 @@ ${error51.stderrTail}`] : []
|
|
|
26500
26334
|
groups.append(empty);
|
|
26501
26335
|
} else {
|
|
26502
26336
|
if (visibleApi.length) {
|
|
26503
|
-
for (const account of visibleApi)
|
|
26337
|
+
for (const account of visibleApi) {
|
|
26338
|
+
apiGroup.body.append(
|
|
26339
|
+
...renderAccountRows(document2, account, messages, {
|
|
26340
|
+
current: accountPhase === "ready" && account.accountId === currentAccountId,
|
|
26341
|
+
usage: usageByAccountId.get(account.accountId),
|
|
26342
|
+
display: usageDisplay,
|
|
26343
|
+
resetExpanded: expandedResetAccounts.has(account.accountId),
|
|
26344
|
+
onRetry: () => {
|
|
26345
|
+
usageByAccountId.delete(account.accountId);
|
|
26346
|
+
loadUsage(accounts);
|
|
26347
|
+
},
|
|
26348
|
+
onResetExpanded: (open) => {
|
|
26349
|
+
if (open) expandedResetAccounts.add(account.accountId);
|
|
26350
|
+
else expandedResetAccounts.delete(account.accountId);
|
|
26351
|
+
}
|
|
26352
|
+
})
|
|
26353
|
+
);
|
|
26354
|
+
}
|
|
26504
26355
|
groups.append(apiGroup.root);
|
|
26505
26356
|
}
|
|
26506
26357
|
if (visibleChat.length + visibleHarnessAccounts.length) {
|
|
26507
|
-
for (const account of visibleChat)
|
|
26358
|
+
for (const account of visibleChat) {
|
|
26359
|
+
chatGroup.body.append(
|
|
26360
|
+
...renderAccountRows(document2, account, messages, {
|
|
26361
|
+
current: accountPhase === "ready" && account.accountId === currentAccountId,
|
|
26362
|
+
usage: usageByAccountId.get(account.accountId),
|
|
26363
|
+
display: usageDisplay,
|
|
26364
|
+
resetExpanded: expandedResetAccounts.has(account.accountId),
|
|
26365
|
+
onRetry: () => {
|
|
26366
|
+
usageByAccountId.delete(account.accountId);
|
|
26367
|
+
loadUsage(accounts);
|
|
26368
|
+
},
|
|
26369
|
+
onResetExpanded: (open) => {
|
|
26370
|
+
if (open) expandedResetAccounts.add(account.accountId);
|
|
26371
|
+
else expandedResetAccounts.delete(account.accountId);
|
|
26372
|
+
}
|
|
26373
|
+
})
|
|
26374
|
+
);
|
|
26375
|
+
}
|
|
26508
26376
|
for (const account of visibleHarnessAccounts) {
|
|
26509
26377
|
chatGroup.body.append(
|
|
26510
|
-
|
|
26378
|
+
...renderHarnessAccountRows(document2, account, messages, usageDisplay)
|
|
26511
26379
|
);
|
|
26512
26380
|
}
|
|
26513
26381
|
groups.append(chatGroup.root);
|
|
@@ -26522,12 +26390,12 @@ ${error51.stderrTail}`] : []
|
|
|
26522
26390
|
};
|
|
26523
26391
|
const loadUsage = (nextAccounts) => {
|
|
26524
26392
|
const inspect = getClient()?.inspectCodexAccountUsage;
|
|
26525
|
-
const
|
|
26526
|
-
const keep = new Set(
|
|
26393
|
+
const saved = [...nextAccounts];
|
|
26394
|
+
const keep = new Set(saved.map((account) => account.accountId));
|
|
26527
26395
|
for (const accountId of [...usageByAccountId.keys()]) {
|
|
26528
26396
|
if (!keep.has(accountId)) usageByAccountId.delete(accountId);
|
|
26529
26397
|
}
|
|
26530
|
-
const pending =
|
|
26398
|
+
const pending = saved.filter((account) => !usageByAccountId.has(account.accountId));
|
|
26531
26399
|
if (!inspect || pending.length === 0) {
|
|
26532
26400
|
render();
|
|
26533
26401
|
return;
|
|
@@ -26546,7 +26414,12 @@ ${error51.stderrTail}`] : []
|
|
|
26546
26414
|
return;
|
|
26547
26415
|
usageByAccountId.set(
|
|
26548
26416
|
account.accountId,
|
|
26549
|
-
result.accountCredits ? {
|
|
26417
|
+
result.accountCredits ? {
|
|
26418
|
+
status: "ready",
|
|
26419
|
+
credits: result.accountCredits,
|
|
26420
|
+
freshness: result.freshness,
|
|
26421
|
+
observedAt: result.observedAt
|
|
26422
|
+
} : { status: "empty" }
|
|
26550
26423
|
);
|
|
26551
26424
|
} catch {
|
|
26552
26425
|
if (context.signal.aborted || usageByAccountId.get(account.accountId) !== loading)
|
|
@@ -26557,13 +26430,24 @@ ${error51.stderrTail}`] : []
|
|
|
26557
26430
|
})
|
|
26558
26431
|
);
|
|
26559
26432
|
};
|
|
26560
|
-
const setAccounts = (
|
|
26561
|
-
|
|
26433
|
+
const setAccounts = (result) => {
|
|
26434
|
+
if (!shouldApplyCodexAccountSnapshot(
|
|
26435
|
+
hasAccountSnapshot ? { instanceId: accountInstanceId, revision: accountRevision } : null,
|
|
26436
|
+
result
|
|
26437
|
+
)) {
|
|
26438
|
+
return;
|
|
26439
|
+
}
|
|
26440
|
+
hasAccountSnapshot = true;
|
|
26441
|
+
accounts = result.accounts;
|
|
26442
|
+
currentAccountId = result.currentAccountId;
|
|
26443
|
+
accountPhase = result.phase;
|
|
26444
|
+
accountRevision = result.revision;
|
|
26445
|
+
accountInstanceId = result.instanceId;
|
|
26562
26446
|
for (const accountId of expandedResetAccounts) {
|
|
26563
26447
|
if (!accounts.some((account) => account.accountId === accountId))
|
|
26564
26448
|
expandedResetAccounts.delete(accountId);
|
|
26565
26449
|
}
|
|
26566
|
-
loadUsage(
|
|
26450
|
+
loadUsage(accounts);
|
|
26567
26451
|
};
|
|
26568
26452
|
const refreshInBackground = () => {
|
|
26569
26453
|
if (!client().refreshCodexAccounts) return;
|
|
@@ -26571,7 +26455,7 @@ ${error51.stderrTail}`] : []
|
|
|
26571
26455
|
() => client().refreshCodexAccounts?.() ?? client().listCodexAccounts(),
|
|
26572
26456
|
{
|
|
26573
26457
|
success(result) {
|
|
26574
|
-
setAccounts(result
|
|
26458
|
+
setAccounts(result);
|
|
26575
26459
|
},
|
|
26576
26460
|
failure() {
|
|
26577
26461
|
}
|
|
@@ -26581,165 +26465,21 @@ ${error51.stderrTail}`] : []
|
|
|
26581
26465
|
const load = () => {
|
|
26582
26466
|
void context.runLatest(() => client().listCodexAccounts(), {
|
|
26583
26467
|
success(result) {
|
|
26584
|
-
|
|
26585
|
-
setAccounts(result
|
|
26468
|
+
loadMessage = null;
|
|
26469
|
+
setAccounts(result);
|
|
26586
26470
|
refreshInBackground();
|
|
26587
26471
|
},
|
|
26588
26472
|
failure(error51) {
|
|
26589
|
-
|
|
26590
|
-
render();
|
|
26591
|
-
}
|
|
26592
|
-
});
|
|
26593
|
-
};
|
|
26594
|
-
const mutate = (operation) => {
|
|
26595
|
-
if (accountBusy()) return;
|
|
26596
|
-
accountActivating = true;
|
|
26597
|
-
render();
|
|
26598
|
-
void context.runLatest(() => operation(), {
|
|
26599
|
-
success(result) {
|
|
26600
|
-
accountActivating = false;
|
|
26601
|
-
loginMessage = null;
|
|
26602
|
-
setAccounts(
|
|
26603
|
-
accounts.map((account) => ({
|
|
26604
|
-
...account.accountId === result.account.accountId ? result.account : account,
|
|
26605
|
-
active: account.accountId === result.account.accountId
|
|
26606
|
-
}))
|
|
26607
|
-
);
|
|
26608
|
-
},
|
|
26609
|
-
failure(error51) {
|
|
26610
|
-
accountActivating = false;
|
|
26611
|
-
loginMessage = errorMessage(error51, messages.accountLoadFailed);
|
|
26612
|
-
render();
|
|
26613
|
-
}
|
|
26614
|
-
});
|
|
26615
|
-
};
|
|
26616
|
-
const startLogin = (accountId) => {
|
|
26617
|
-
if (accountBusy()) return;
|
|
26618
|
-
loginStartingAccountId = accountId;
|
|
26619
|
-
loginMessage = messages.accountSigningIn;
|
|
26620
|
-
render();
|
|
26621
|
-
void context.runLatest(() => client().startCodexAccountLogin({ accountId }), {
|
|
26622
|
-
success(result) {
|
|
26623
|
-
loginStartingAccountId = null;
|
|
26624
|
-
login = result;
|
|
26625
|
-
loginMessage = null;
|
|
26626
|
-
render();
|
|
26627
|
-
scheduleLoginRefresh();
|
|
26628
|
-
},
|
|
26629
|
-
failure(error51) {
|
|
26630
|
-
loginStartingAccountId = null;
|
|
26631
|
-
loginMessage = errorMessage(error51, messages.accountLoginFailed);
|
|
26473
|
+
loadMessage = errorMessage(error51, messages.accountLoadFailed);
|
|
26632
26474
|
render();
|
|
26633
26475
|
}
|
|
26634
26476
|
});
|
|
26635
26477
|
};
|
|
26636
|
-
|
|
26637
|
-
if (accountBusy()) return;
|
|
26638
|
-
accountCreating = true;
|
|
26639
|
-
loginMessage = messages.accountSigningIn;
|
|
26640
|
-
render();
|
|
26641
|
-
void context.runLatest(() => client().createCodexAccount({}), {
|
|
26642
|
-
success(result) {
|
|
26643
|
-
accountCreating = false;
|
|
26644
|
-
loginMessage = null;
|
|
26645
|
-
search.value = "";
|
|
26646
|
-
setAccounts([
|
|
26647
|
-
...accounts.filter(({ accountId }) => accountId !== result.account.accountId),
|
|
26648
|
-
result.account
|
|
26649
|
-
]);
|
|
26650
|
-
startLogin(result.account.accountId);
|
|
26651
|
-
},
|
|
26652
|
-
failure(error51) {
|
|
26653
|
-
accountCreating = false;
|
|
26654
|
-
loginMessage = errorMessage(error51, messages.accountCreateFailed);
|
|
26655
|
-
render();
|
|
26656
|
-
}
|
|
26657
|
-
});
|
|
26658
|
-
};
|
|
26659
|
-
const resetOutcomeMessage = (outcome) => {
|
|
26660
|
-
if (outcome === "reset") return messages.accountResetCreditsSucceeded;
|
|
26661
|
-
if (outcome === "nothingToReset") return messages.accountResetCreditsNothingToReset;
|
|
26662
|
-
if (outcome === "noCredit") return messages.accountResetCreditsNoCredit;
|
|
26663
|
-
return messages.accountResetCreditsAlreadyRedeemed;
|
|
26664
|
-
};
|
|
26665
|
-
const useReset = (accountId) => {
|
|
26666
|
-
const consume = getClient()?.consumeCodexAccountResetCredit;
|
|
26667
|
-
if (!consume || accountBusy()) return;
|
|
26668
|
-
if (document2.defaultView?.confirm?.(messages.accountResetCreditsConfirm) === false) return;
|
|
26669
|
-
usingResetAccountId = accountId;
|
|
26670
|
-
loginMessage = messages.accountResetCreditsUsing;
|
|
26671
|
-
render();
|
|
26672
|
-
void context.runLatest(() => consume({ accountId, idempotencyKey: crypto.randomUUID() }), {
|
|
26673
|
-
success(result) {
|
|
26674
|
-
usingResetAccountId = null;
|
|
26675
|
-
loginMessage = resetOutcomeMessage(result.outcome);
|
|
26676
|
-
if (result.accountCredits) {
|
|
26677
|
-
usageByAccountId.set(accountId, {
|
|
26678
|
-
status: "ready",
|
|
26679
|
-
credits: result.accountCredits
|
|
26680
|
-
});
|
|
26681
|
-
} else if (result.outcome === "reset") {
|
|
26682
|
-
usageByAccountId.delete(accountId);
|
|
26683
|
-
loadUsage(accounts);
|
|
26684
|
-
}
|
|
26685
|
-
render();
|
|
26686
|
-
},
|
|
26687
|
-
failure(error51) {
|
|
26688
|
-
usingResetAccountId = null;
|
|
26689
|
-
loginMessage = errorMessage(error51, messages.accountResetCreditsFailed);
|
|
26690
|
-
render();
|
|
26691
|
-
}
|
|
26692
|
-
});
|
|
26693
|
-
};
|
|
26694
|
-
const deleteAccount = (accountId) => {
|
|
26695
|
-
const account = accounts.find((candidate) => candidate.accountId === accountId);
|
|
26696
|
-
if (!account || account.isDefault || accountBusy()) return;
|
|
26697
|
-
if (document2.defaultView?.confirm?.(messages.accountDeleteConfirm) === false) return;
|
|
26698
|
-
deletingAccountId = accountId;
|
|
26699
|
-
loginMessage = messages.accountDeleting;
|
|
26700
|
-
render();
|
|
26701
|
-
void context.runLatest(() => client().deleteCodexAccount({ accountId }), {
|
|
26702
|
-
success() {
|
|
26703
|
-
deletingAccountId = null;
|
|
26704
|
-
loginMessage = null;
|
|
26705
|
-
setAccounts(
|
|
26706
|
-
accounts.filter((candidate) => candidate.accountId !== accountId).map((candidate) => ({
|
|
26707
|
-
...candidate,
|
|
26708
|
-
active: account.active ? candidate.isDefault : candidate.active
|
|
26709
|
-
}))
|
|
26710
|
-
);
|
|
26711
|
-
},
|
|
26712
|
-
failure(error51) {
|
|
26713
|
-
deletingAccountId = null;
|
|
26714
|
-
loginMessage = errorMessage(error51, messages.accountDeleteFailed);
|
|
26715
|
-
render();
|
|
26716
|
-
}
|
|
26717
|
-
});
|
|
26718
|
-
};
|
|
26719
|
-
const cancelLogin = (accountId, loginId) => {
|
|
26720
|
-
void context.runLatest(() => client().cancelCodexAccountLogin({ accountId, loginId }), {
|
|
26721
|
-
success() {
|
|
26722
|
-
clearLoginRefresh();
|
|
26723
|
-
login = null;
|
|
26724
|
-
loginMessage = null;
|
|
26725
|
-
render();
|
|
26726
|
-
},
|
|
26727
|
-
failure(error51) {
|
|
26728
|
-
loginMessage = errorMessage(error51, messages.accountLoginFailed);
|
|
26729
|
-
render();
|
|
26730
|
-
}
|
|
26731
|
-
});
|
|
26732
|
-
};
|
|
26733
|
-
add.addEventListener("click", createAndLogin);
|
|
26734
|
-
let unsubscribe;
|
|
26478
|
+
let unsubscribeAccounts;
|
|
26735
26479
|
try {
|
|
26736
|
-
|
|
26737
|
-
|
|
26738
|
-
clearLoginRefresh();
|
|
26739
|
-
login = null;
|
|
26740
|
-
loginMessage = result.success ? messages.accountLoginSucceeded : result.error ?? messages.accountLoginFailed;
|
|
26480
|
+
unsubscribeAccounts = getClient()?.subscribeCodexAccounts?.((result) => {
|
|
26481
|
+
setAccounts(result);
|
|
26741
26482
|
render();
|
|
26742
|
-
if (result.success) load();
|
|
26743
26483
|
});
|
|
26744
26484
|
} catch {
|
|
26745
26485
|
}
|
|
@@ -26748,8 +26488,7 @@ ${error51.stderrTail}`] : []
|
|
|
26748
26488
|
load();
|
|
26749
26489
|
return () => {
|
|
26750
26490
|
stopCountdowns();
|
|
26751
|
-
|
|
26752
|
-
unsubscribe?.();
|
|
26491
|
+
unsubscribeAccounts?.();
|
|
26753
26492
|
};
|
|
26754
26493
|
}
|
|
26755
26494
|
});
|
|
@@ -27343,10 +27082,10 @@ ${error51.stderrTail}`] : []
|
|
|
27343
27082
|
}
|
|
27344
27083
|
|
|
27345
27084
|
// src/settings/shell.css
|
|
27346
|
-
var shell_default = ':host {\n /* Inherit Codex Desktop color-scheme; light-dark() tracks the host page. */\n --settings-bg: light-dark(#ffffff, #181818);\n --settings-sidebar: light-dark(#f4f4f5, #1c1c1c);\n --settings-panel: transparent;\n --settings-text: light-dark(#171717, #f5f5f5);\n --settings-muted: light-dark(#737373, #a1a1a1);\n --settings-subtle: light-dark(#8a8a8a, #777777);\n --settings-border: light-dark(rgb(15 23 42 / 10%), rgb(255 255 255 / 10%));\n --settings-divider: light-dark(rgb(15 23 42 / 10%), rgb(255 255 255 / 10%));\n --settings-hover: light-dark(rgb(15 23 42 / 5%), rgb(255 255 255 / 6%));\n --settings-active: light-dark(rgb(51 156 255 / 14%), rgb(51 156 255 / 12%));\n --settings-focus: #339cff;\n --settings-elevated: light-dark(#ffffff, #2c2c2e);\n --settings-inset: light-dark(rgb(15 23 42 / 4%), rgb(0 0 0 / 18%));\n --settings-surface: light-dark(rgb(15 23 42 / 3%), rgb(255 255 255 / 2%));\n --settings-surface-strong: light-dark(rgb(15 23 42 / 6%), rgb(255 255 255 / 6%));\n --settings-surface-hover: light-dark(#eeeeee, #303030);\n --settings-mark: light-dark(#52525b, #d4d8de);\n --settings-dialog-shadow: light-dark(\n 0 24px 64px rgb(15 23 42 / 16%),\n 0 24px 64px rgb(0 0 0 / 38%)\n );\n --settings-backdrop: light-dark(rgb(15 23 42 / 28%), rgb(0 0 0 / 52%));\n --settings-segmented-shadow:\n 0 0 0 0.5px light-dark(rgb(15 23 42 / 6%), rgb(0 0 0 / 4%)),\n 0 3px 1px 0 light-dark(rgb(15 23 42 / 4%), rgb(0 0 0 / 4%)),\n 0 3px 8px 0 light-dark(rgb(15 23 42 / 10%), rgb(0 0 0 / 12%));\n --settings-primary: light-dark(#171717, #f4f4f4);\n --settings-primary-hover: light-dark(#2f2f2f, #ffffff);\n --settings-primary-text: light-dark(#ffffff, #171717);\n --settings-warning: light-dark(#8a5500, #f5c96a);\n --settings-warning-bg: light-dark(#fff8e6, rgb(245 201 106 / 8%));\n --settings-warning-border: light-dark(#ead8a8, rgb(245 201 106 / 24%));\n --settings-danger: light-dark(#b42318, #f87171);\n --settings-danger-bg: light-dark(#fff1f0, rgb(239 68 68 / 8%));\n --settings-danger-border: light-dark(#f3c7c3, rgb(239 68 68 / 22%));\n --settings-success: light-dark(#16784a, #4ade80);\n color: var(--settings-text);\n color-scheme: inherit;\n font:\n 13px/1.5 system-ui,\n -apple-system,\n BlinkMacSystemFont,\n "Segoe UI",\n sans-serif;\n letter-spacing: 0;\n}\n\n*,\n*::before,\n*::after {\n box-sizing: border-box;\n letter-spacing: 0;\n}\n\nbutton,\ninput,\nselect {\n font: inherit;\n}\n\nbutton {\n color: inherit;\n}\n\n[hidden] {\n display: none !important;\n}\n\n.codexhost-settings-dialog {\n width: min(1120px, calc(100vw - 32px));\n height: min(780px, calc(100vh - 32px));\n max-width: none;\n max-height: none;\n margin: auto;\n padding: 0;\n overflow: hidden;\n color: var(--settings-text);\n background: var(--settings-bg);\n border: 1px solid var(--settings-border);\n border-radius: 12px;\n box-shadow: var(--settings-dialog-shadow);\n}\n\n.codexhost-settings-dialog::backdrop {\n background: var(--settings-backdrop);\n}\n\n.settings-frame,\n.settings-layout {\n width: 100%;\n height: 100%;\n min-width: 0;\n min-height: 0;\n}\n\n.settings-frame {\n display: flex;\n flex-direction: column;\n}\n\n.settings-layout {\n flex: 1;\n display: grid;\n grid-template-columns: 184px minmax(0, 1fr);\n background: var(--settings-bg);\n}\n\n.settings-sidebar {\n display: flex;\n min-width: 0;\n min-height: 0;\n flex-direction: column;\n overflow: hidden;\n background: var(--settings-sidebar);\n border-right: 1px solid var(--settings-border);\n padding-top: 14px;\n}\n\n.settings-header {\n display: flex;\n align-items: center;\n min-width: 0;\n height: 48px;\n flex: none;\n padding: 0 12px;\n border-bottom: 1px solid var(--settings-border);\n}\n\n.settings-header-actions {\n display: flex;\n align-items: center;\n flex: none;\n gap: 12px;\n margin-left: auto;\n}\n\n.settings-brand {\n display: flex;\n align-items: center;\n min-width: 0;\n gap: 7px;\n}\n\n.settings-brand__mark {\n display: inline-flex;\n align-items: center;\n justify-content: center;\n width: 26px;\n height: 26px;\n flex: none;\n color: var(--settings-text);\n}\n\n.settings-brand__mark .codexhost-settings-icon {\n width: 24px;\n height: 24px;\n object-fit: contain;\n}\n\n.settings-brand__copy {\n display: flex;\n min-width: 0;\n align-items: baseline;\n gap: 0;\n line-height: 20px;\n}\n\n.settings-brand__name {\n overflow: hidden;\n color: var(--settings-text);\n font-size: 13px;\n font-weight: 600;\n text-overflow: ellipsis;\n white-space: nowrap;\n}\n\n.settings-brand__title {\n margin-left: 8px;\n padding-left: 8px;\n color: var(--settings-muted);\n font-size: 13px;\n font-weight: 400;\n border-left: 1px solid var(--settings-border);\n}\n\n.settings-nav {\n display: flex;\n min-width: 0;\n min-height: 0;\n flex: 1;\n flex-direction: column;\n gap: 2px;\n padding: 0 7px 10px;\n overflow-y: auto;\n}\n\n.settings-nav-section-label {\n min-height: 28px;\n padding: 7px 9px 3px 4px;\n color: var(--settings-muted);\n font-size: 12px;\n font-weight: 600;\n line-height: 18px;\n}\n\n.settings-nav-section-label:not(:first-child) {\n margin-top: 8px;\n}\n\n.settings-nav-button {\n display: grid;\n grid-template-columns: 16px minmax(0, 1fr);\n align-items: center;\n width: 100%;\n position: relative;\n min-height: 34px;\n flex: none;\n gap: 9px;\n padding: 6px 9px;\n color: var(--settings-text);\n font-size: 14px;\n font-weight: 600;\n line-height: 21px;\n text-align: left;\n background: transparent;\n border: 0;\n border-radius: 8px;\n cursor: pointer;\n}\n\n.settings-nav-button .codexhost-settings-icon {\n width: 16px;\n height: 16px;\n opacity: 0.9;\n}\n\n.settings-nav-button:hover {\n background: var(--settings-hover);\n}\n\n.settings-nav-button[aria-current="page"] {\n background: var(--settings-active);\n color: var(--settings-text);\n font-weight: 500;\n}\n\n.settings-nav-button span {\n min-width: 0;\n overflow: hidden;\n text-overflow: ellipsis;\n white-space: nowrap;\n}\n\n.settings-icon-button {\n display: inline-flex;\n align-items: center;\n justify-content: center;\n width: 28px;\n height: 28px;\n flex: none;\n padding: 0;\n color: var(--settings-muted);\n background: transparent;\n border: 0;\n border-radius: 8px;\n cursor: pointer;\n}\n\n.settings-icon-button:hover {\n color: var(--settings-text);\n background: var(--settings-hover);\n}\n\n.settings-icon-button:focus-visible,\n.settings-nav-button:focus-visible {\n outline: 2px solid var(--settings-focus);\n outline-offset: 1px;\n}\n\n.settings-page {\n display: block;\n position: relative;\n min-width: 0;\n min-height: 0;\n overflow-y: auto;\n background: var(--settings-bg);\n scrollbar-gutter: stable;\n}\n\n.settings-page__content {\n width: min(930px, calc(100% - 80px));\n margin-inline: auto;\n}\n\n.settings-page__content {\n min-width: 0;\n padding: 28px 0 36px;\n}\n\n.settings-section-label {\n min-height: auto;\n padding: 0 0 28px;\n color: var(--settings-text);\n font-size: 18px;\n font-weight: 600;\n line-height: 26px;\n}\n\n.settings-status-list,\n.settings-empty {\n overflow: hidden;\n background: var(--settings-panel);\n}\n\n.settings-status-row {\n display: grid;\n grid-template-columns: minmax(170px, 1fr) auto minmax(280px, 1.45fr);\n position: relative;\n align-items: center;\n min-height: 72px;\n gap: 20px;\n padding: 12px 0;\n}\n\n.settings-status-row:not(:last-child)::after {\n content: "";\n position: absolute;\n right: 0;\n bottom: 0;\n left: 0;\n height: 1px;\n background: var(--settings-divider);\n}\n\n.settings-status-row__identity {\n display: inline-flex;\n align-items: center;\n min-width: 0;\n color: var(--settings-text);\n gap: 10px;\n font-size: 14px;\n font-weight: 500;\n line-height: 22px;\n}\n\n.settings-status-row__icon {\n display: inline-flex;\n align-items: center;\n justify-content: center;\n width: 36px;\n height: 36px;\n flex: none;\n color: var(--settings-muted);\n background: var(--settings-surface-strong);\n border-radius: 50%;\n}\n\n.settings-status-badge {\n flex: none;\n padding: 3px 8px;\n color: var(--settings-muted);\n font-size: 11px;\n font-weight: 500;\n line-height: 18px;\n background: var(--settings-surface-strong);\n border: 1px solid var(--settings-border);\n border-radius: 6px;\n}\n\n.settings-status-row__detail {\n min-width: 0;\n color: var(--settings-muted);\n font-size: 13px;\n line-height: 20px;\n}\n\n.settings-page-description {\n max-width: 760px;\n margin: -10px 0 20px;\n color: var(--settings-muted);\n font-size: 12px;\n line-height: 18px;\n}\n\n.settings-session-import-header {\n display: flex;\n align-items: flex-start;\n justify-content: space-between;\n gap: 24px;\n}\n\n.settings-session-import-header .settings-section-label {\n min-width: 0;\n}\n\n.settings-session-import-harness {\n display: flex;\n min-width: 0;\n margin: 0 0 16px;\n}\n\n.settings-session-import-harness__options {\n display: flex;\n flex-wrap: wrap;\n align-items: center;\n width: fit-content;\n max-width: 100%;\n gap: 8px;\n}\n\n.settings-session-import-harness__option {\n min-height: 32px;\n flex: none;\n padding: 6px 10px;\n color: var(--settings-muted);\n font: inherit;\n font-size: 12px;\n white-space: nowrap;\n background: transparent;\n border: 1px solid var(--settings-border);\n border-radius: 6px;\n cursor: pointer;\n}\n\n.settings-session-import-harness__option[aria-pressed="true"] {\n color: var(--settings-text);\n background: var(--settings-active);\n border-color: rgb(51 156 255 / 50%);\n}\n\n.settings-session-import-harness__option:disabled {\n opacity: 0.38;\n cursor: not-allowed;\n}\n\n.settings-session-import-harness__option:focus-visible {\n outline: 2px solid var(--settings-focus);\n outline-offset: 2px;\n}\n\n.settings-session-import-search,\n.settings-session-import-pagination {\n display: flex;\n flex-wrap: wrap;\n align-items: center;\n gap: 10px;\n}\n\n.settings-session-import-search {\n align-items: stretch;\n margin: 16px 0 0;\n}\n\n.settings-session-import-pagination {\n margin: 16px 0 0;\n}\n\n.settings-session-import-search input {\n flex: 1;\n min-width: 160px;\n}\n\n.settings-session-import-search input,\n.settings-session-import-pagination select {\n box-sizing: border-box;\n color: var(--settings-text);\n background: var(--settings-bg);\n border: 1px solid var(--settings-border);\n border-radius: 6px;\n}\n\n.settings-session-import-search input,\n.settings-session-import-search .settings-command-button {\n box-sizing: border-box;\n height: 36px;\n min-height: 36px;\n padding: 6px 10px;\n border-radius: 6px;\n}\n\n.settings-session-import-pagination select {\n min-height: 28px;\n padding: 2px 8px;\n}\n\n.settings-session-import-search input:focus-visible,\n.settings-session-import-pagination select:focus-visible {\n outline: 2px solid var(--settings-focus);\n outline-offset: 2px;\n}\n\n.settings-session-import-pagination {\n color: var(--settings-muted);\n font-size: 12px;\n line-height: 18px;\n}\n\n.settings-session-import-pagination label {\n display: flex;\n align-items: center;\n gap: 8px;\n}\n\n.settings-session-import-pagination > span {\n flex: none;\n min-width: 0;\n}\n\n.settings-session-import-pagination__navigation {\n display: flex;\n gap: 8px;\n margin-left: auto;\n}\n\n.settings-session-import-content,\n.settings-session-import-list {\n display: grid;\n gap: 10px;\n}\n\n.settings-session-import-content {\n margin-top: 16px;\n}\n\n.settings-session-import-status {\n display: flex;\n align-items: center;\n min-height: 0;\n gap: 12px;\n padding: 12px 16px;\n color: var(--settings-muted);\n background: var(--settings-panel);\n border: 1px solid var(--settings-border);\n border-radius: 8px;\n}\n\n.settings-session-import-status.is-error {\n color: #ef4444;\n}\n\n.settings-session-import-recovery {\n display: grid;\n justify-items: start;\n gap: 14px;\n padding: 16px;\n background: var(--settings-panel);\n border: 1px solid var(--settings-border);\n border-radius: 8px;\n}\n\n.settings-session-import-recovery:focus-visible {\n outline: 2px solid var(--settings-focus);\n outline-offset: 2px;\n}\n\n.settings-session-import-recovery__copy {\n display: grid;\n gap: 4px;\n}\n\n.settings-session-import-recovery__copy strong {\n color: var(--settings-text);\n font-size: 14px;\n}\n\n.settings-session-import-recovery__copy p {\n margin: 0;\n color: var(--settings-muted);\n font-size: 13px;\n line-height: 20px;\n}\n\n.settings-session-import-recovery__path {\n display: flex;\n align-items: stretch;\n width: 100%;\n min-width: 0;\n overflow: hidden;\n border: 1px solid var(--settings-border);\n border-radius: 6px;\n}\n\n.settings-session-import-recovery__path code {\n min-width: 0;\n flex: 1;\n padding: 8px 10px;\n overflow-x: auto;\n color: var(--settings-text);\n font-size: 12px;\n line-height: 20px;\n white-space: nowrap;\n}\n\n.settings-session-import-recovery__path .settings-command-button {\n min-height: 0;\n flex: none;\n border-width: 0 0 0 1px;\n border-radius: 0;\n}\n\n.settings-session-import-row {\n display: grid;\n grid-template-columns: minmax(0, 1fr) auto;\n align-items: center;\n gap: 20px;\n min-width: 0;\n padding: 16px;\n background: var(--settings-panel);\n border: 1px solid var(--settings-border);\n border-radius: 8px;\n}\n\n.settings-session-import-row__copy {\n display: grid;\n min-width: 0;\n gap: 4px;\n}\n\n.settings-session-import-row__copy strong {\n overflow: hidden;\n color: var(--settings-text);\n font-size: 14px;\n text-overflow: ellipsis;\n white-space: nowrap;\n}\n\n.settings-session-import-row__copy span,\n.settings-session-import-row__cwd {\n overflow: hidden;\n color: var(--settings-muted);\n font-size: 12px;\n line-height: 18px;\n text-overflow: ellipsis;\n white-space: nowrap;\n}\n\n.settings-session-import-row__cwd {\n display: block;\n min-width: 0;\n background: transparent;\n}\n\n.settings-session-import-row__action {\n display: flex;\n align-items: flex-end;\n flex-direction: column;\n gap: 8px;\n}\n\n.settings-session-import-running {\n color: var(--settings-muted);\n font-size: 12px;\n}\n\n.settings-preference-row {\n display: flex;\n align-items: center;\n justify-content: space-between;\n gap: 32px;\n min-height: 88px;\n padding: 18px 0;\n border-top: 1px solid var(--settings-divider);\n border-bottom: 1px solid var(--settings-divider);\n}\n\n.settings-preference-row__copy {\n display: flex;\n flex: 1 1 auto;\n flex-direction: column;\n min-width: 0;\n gap: 5px;\n}\n\n.settings-preference-row__copy strong {\n color: var(--settings-text);\n font-size: 15px;\n font-weight: 600;\n line-height: 22px;\n}\n\n.settings-preference-row__copy span {\n max-width: 680px;\n color: var(--settings-muted);\n font-size: 13px;\n line-height: 20px;\n}\n\n.settings-preference-switch {\n display: inline-flex;\n align-items: center;\n width: 42px;\n height: 24px;\n flex: none;\n padding: 2px;\n border: 0;\n border-radius: 999px;\n background: var(--settings-surface-strong);\n cursor: pointer;\n transition: background 120ms ease;\n}\n\n.settings-preference-switch[aria-checked="true"] {\n justify-content: flex-end;\n background: var(--settings-focus);\n}\n\n.settings-preference-switch:focus-visible {\n outline: 2px solid var(--settings-focus);\n outline-offset: 2px;\n}\n\n.settings-preference-switch__thumb {\n width: 20px;\n height: 20px;\n border-radius: 50%;\n background: var(--settings-primary-text);\n box-shadow: 0 1px 3px rgb(0 0 0 / 24%);\n}\n\n.settings-preference-checkbox {\n width: 18px;\n height: 18px;\n flex: none;\n margin: 0;\n accent-color: var(--settings-focus);\n cursor: pointer;\n}\n\n.settings-preference-checkbox:focus-visible {\n outline: 2px solid var(--settings-focus);\n outline-offset: 2px;\n}\n\n.settings-connection-page-header {\n display: flex;\n align-items: flex-start;\n justify-content: space-between;\n gap: 18px;\n margin-bottom: 18px;\n}\n\n.settings-connection-page-header .settings-section-label {\n padding-bottom: 0;\n}\n\n.settings-connection-page-header .settings-page-description {\n margin: 8px 0 0;\n}\n\n.settings-connection-page-header .settings-page-description + .settings-page-description {\n margin-top: 8px;\n}\n\n.settings-update-header {\n margin-bottom: 8px;\n}\n\n.settings-connections-content,\n.settings-plugins-content,\n.settings-connection-list,\n.settings-connection-rows {\n min-width: 0;\n}\n\n.settings-connections-content,\n.settings-plugins-content {\n display: grid;\n gap: 12px;\n}\n\n.settings-connection-list {\n overflow: hidden;\n background: var(--settings-surface);\n border: 1px solid var(--settings-border);\n border-radius: 10px;\n}\n\n.settings-segmented {\n display: inline-flex;\n flex-wrap: wrap;\n align-items: center;\n width: fit-content;\n max-width: 100%;\n padding: 2px;\n gap: 3px;\n background: var(--settings-surface-strong);\n border-radius: 10px;\n}\n\n.settings-segmented__item {\n position: relative;\n display: inline-flex;\n align-items: center;\n justify-content: center;\n min-height: 28px;\n padding: 4px 14px;\n color: var(--settings-muted);\n font: inherit;\n font-size: 12px;\n font-weight: 600;\n line-height: 18px;\n white-space: nowrap;\n background: transparent;\n border: 0;\n border-radius: 8px;\n cursor: pointer;\n transition:\n color 0.15s ease,\n background-color 0.15s ease,\n box-shadow 0.15s ease;\n}\n\n.settings-segmented__item:hover {\n color: var(--settings-text);\n background: var(--settings-hover);\n}\n\n.settings-segmented__item--selected,\n.settings-segmented__item[aria-selected="true"],\n.settings-segmented__item[aria-pressed="true"] {\n color: var(--settings-text);\n background: var(--settings-elevated);\n box-shadow: var(--settings-segmented-shadow);\n}\n\n.settings-segmented__item:disabled {\n opacity: 0.5;\n cursor: not-allowed;\n}\n\n.settings-segmented__item:disabled:hover {\n color: var(--settings-muted);\n background: transparent;\n}\n\n.settings-segmented__item:focus-visible,\n.settings-connection-row:focus-visible,\n.settings-connection-install-link:focus-visible,\n.settings-connection-view-error:focus-visible {\n outline: 2px solid var(--settings-focus);\n outline-offset: 1px;\n}\n\n.settings-connection-host-tabs {\n display: flex;\n align-items: center;\n min-width: 0;\n gap: 6px;\n overflow-x: auto;\n overflow-y: hidden;\n overscroll-behavior-x: contain;\n scrollbar-width: none;\n scroll-behavior: smooth;\n scroll-snap-type: x proximity;\n touch-action: pan-x;\n}\n\n.settings-connection-host-tabs::-webkit-scrollbar {\n display: none;\n}\n\n.settings-connection-host-tab {\n display: inline-flex;\n align-items: center;\n height: 30px;\n min-width: max-content;\n flex: none;\n padding: 0 9px;\n color: var(--settings-muted);\n font: inherit;\n font-size: 12px;\n line-height: 18px;\n white-space: nowrap;\n background: var(--settings-inset);\n border: 1px solid var(--settings-border);\n border-radius: 7px;\n cursor: pointer;\n scroll-snap-align: start;\n}\n\n.settings-connection-host-tab:hover {\n color: var(--settings-text);\n background: var(--settings-hover);\n}\n\n.settings-connection-host-tab[aria-selected="true"] {\n color: var(--settings-text);\n font-weight: 600;\n background: var(--settings-active);\n border-color: var(--settings-border);\n}\n\n.settings-connection-table-header,\n.settings-connection-row {\n display: grid;\n /* Component : Status : Actions = 4 : 3 : 3 */\n grid-template-columns: minmax(0, 4fr) minmax(0, 3fr) minmax(0, 3fr);\n align-items: center;\n min-width: 0;\n column-gap: 16px;\n}\n\n.settings-connection-table-header {\n min-height: 30px;\n padding: 0 10px;\n color: var(--settings-muted);\n font-size: 10px;\n font-weight: 600;\n line-height: 16px;\n text-transform: uppercase;\n letter-spacing: 0.06em;\n background: var(--settings-surface);\n border-bottom: 1px solid var(--settings-divider);\n}\n\n.settings-connection-rows > .settings-connection-row,\n.settings-connection-rows > .settings-connection-block {\n border-bottom: 1px solid var(--settings-divider);\n}\n\n.settings-connection-rows > .settings-connection-row:last-child,\n.settings-connection-rows > .settings-connection-block:last-child {\n border-bottom: 0;\n}\n\n.settings-connection-row {\n min-height: 52px;\n padding: 8px 10px;\n cursor: pointer;\n}\n\n.settings-connection-row:hover {\n background: var(--settings-hover);\n}\n\n.settings-connection-row[data-connection-selected="true"] {\n background: var(--settings-surface);\n}\n\n.settings-connection-row__identity,\n.settings-connection-inspector__identity {\n display: inline-flex;\n align-items: center;\n min-width: 0;\n gap: 8px;\n color: var(--settings-text);\n}\n\n.settings-connection-row__identity strong,\n.settings-connection-inspector__identity strong {\n min-width: 0;\n overflow-wrap: anywhere;\n font-size: 12px;\n font-weight: 500;\n line-height: 18px;\n}\n\n.settings-connection-row__mark {\n display: inline-flex;\n align-items: center;\n justify-content: center;\n width: 24px;\n height: 24px;\n flex: none;\n color: var(--settings-mark);\n font-size: 10px;\n font-weight: 700;\n background: var(--settings-surface-strong);\n border-radius: 7px;\n}\n\n.settings-connection-row__mark--logo {\n color: var(--settings-text);\n background: transparent;\n}\n\n.settings-connection-row__mark--logo > img,\n.settings-connection-row__mark--logo > svg {\n display: block;\n max-width: 18px;\n max-height: 18px;\n}\n\n.settings-connection-table-header > :last-child {\n text-align: end;\n}\n\n.settings-connection-row__status {\n display: inline-flex;\n align-items: center;\n width: fit-content;\n max-width: 100%;\n gap: 6px;\n color: var(--settings-muted);\n font-size: 11px;\n font-weight: 500;\n line-height: 18px;\n}\n\n.settings-connection-row__status::before {\n width: 6px;\n height: 6px;\n flex: none;\n content: "";\n background: currentColor;\n border-radius: 50%;\n}\n\n.settings-connection-row__status[data-connection-tone="ready"] {\n color: var(--settings-success);\n}\n\n.settings-connection-row__status[data-connection-tone="checking"] {\n color: var(--settings-warning);\n}\n\n.settings-connection-row__status[data-connection-tone="setup"] {\n color: var(--settings-muted);\n}\n\n.settings-connection-row__status[data-connection-tone="setup"]::before {\n background: transparent;\n border: 1.5px solid currentColor;\n}\n\n.settings-connection-row__status[data-connection-tone="failed"] {\n color: var(--settings-danger);\n}\n\n.settings-connection-row__action {\n display: flex;\n align-items: center;\n justify-content: flex-end;\n min-width: 0;\n gap: 4px;\n}\n\n.settings-connection-row__handle {\n display: inline-flex;\n flex: none;\n align-items: center;\n justify-content: center;\n width: 16px;\n color: var(--settings-muted);\n cursor: grab;\n opacity: 0.6;\n}\n\n.settings-connection-row__handle:hover {\n opacity: 1;\n}\n\n.settings-connection-row[draggable="true"] {\n cursor: grab;\n}\n\n.settings-connection-row[data-connection-dragging="true"] {\n opacity: 0.4;\n}\n\n.settings-connection-row[data-connection-drop-indicator="before"] {\n box-shadow: inset 0 2px 0 0 var(--settings-focus);\n}\n\n.settings-connection-row[data-connection-drop-indicator="after"] {\n box-shadow: inset 0 -2px 0 0 var(--settings-focus);\n}\n\n.settings-connection-inline-detail {\n display: grid;\n gap: 12px;\n margin-top: 2px;\n padding: 14px 12px 16px;\n border-top: 1px solid var(--settings-divider);\n background: var(--settings-inset);\n}\n\n.settings-connection-group-divider {\n padding: 10px 12px 6px;\n color: var(--settings-muted);\n font-size: 10px;\n font-weight: 600;\n line-height: 16px;\n text-transform: uppercase;\n letter-spacing: 0.06em;\n /* No border-top here: the row immediately above already carries its own\n border-bottom (it is no longer :last-child once this divider follows\n it), so adding one here would double the separator line. */\n}\n\n.settings-connection-group-divider[data-connection-drag-over="true"] {\n color: var(--settings-focus);\n background: rgb(51 156 255 / 8%);\n border-radius: 6px;\n}\n\n.settings-connection-group-more[data-connection-drag-over="true"] {\n background: rgb(51 156 255 / 8%);\n}\n\n.settings-connection-group-hint {\n display: grid;\n gap: 3px;\n margin: 0 12px 12px;\n padding: 14px 16px;\n text-align: center;\n border: 1.5px dashed var(--settings-border);\n border-radius: 10px;\n}\n\n.settings-connection-group-more[data-connection-drag-over="true"] .settings-connection-group-hint {\n border-color: var(--settings-focus);\n}\n\n.settings-connection-group-hint strong {\n color: var(--settings-text);\n font-size: 12.5px;\n font-weight: 500;\n line-height: 18px;\n}\n\n.settings-connection-group-hint span {\n color: var(--settings-muted);\n font-size: 12px;\n line-height: 17px;\n}\n\n.settings-connection-group-reset {\n display: flex;\n width: 100%;\n align-items: center;\n gap: 6px;\n padding: 10px 12px;\n color: var(--settings-muted);\n font: inherit;\n font-size: 12px;\n text-align: left;\n background: transparent;\n border: 0;\n border-top: 1px solid var(--settings-divider);\n cursor: pointer;\n}\n\n.settings-connection-group-reset:hover {\n color: var(--settings-text);\n background: var(--settings-hover);\n}\n\n.settings-connection-install-link {\n display: inline-flex;\n align-items: center;\n justify-content: center;\n width: 26px;\n height: 26px;\n padding: 0;\n color: var(--settings-focus);\n font: inherit;\n text-decoration: none;\n background: transparent;\n border: 1px solid transparent;\n border-radius: 7px;\n cursor: pointer;\n}\n\n.settings-connection-install-link:hover,\n.settings-connection-install-link:focus-visible {\n color: var(--settings-focus);\n background: var(--settings-active);\n border-color: var(--settings-border);\n}\n\n.settings-connection-view-error {\n padding: 4px 7px;\n color: var(--settings-danger);\n font: inherit;\n font-size: 11px;\n line-height: 18px;\n background: transparent;\n border: 0;\n border-radius: 6px;\n cursor: pointer;\n}\n\n.settings-connection-view-error:hover {\n color: var(--settings-danger);\n background: var(--settings-danger-bg);\n}\n\n.settings-connection-inspector {\n position: sticky;\n top: 18px;\n}\n\n.settings-connection-inspector__header {\n display: flex;\n align-items: flex-start;\n justify-content: space-between;\n min-width: 0;\n gap: 10px;\n padding: 12px;\n border-bottom: 1px solid var(--settings-divider);\n}\n\n.settings-connection-inspector__body {\n display: grid;\n min-width: 0;\n gap: 12px;\n padding: 12px;\n}\n\n.settings-connection-install-callout {\n display: grid;\n grid-template-columns: 28px minmax(0, 1fr);\n gap: 9px;\n padding: 11px;\n background: var(--settings-surface);\n border: 0;\n border-radius: 8px;\n}\n\n.settings-connection-install-callout__icon {\n display: inline-flex;\n align-items: center;\n justify-content: center;\n width: 28px;\n height: 28px;\n color: var(--settings-focus);\n background: var(--settings-active);\n border-radius: 7px;\n}\n\n.settings-connection-install-callout strong,\n.settings-connection-error-summary strong,\n.settings-connection-state-summary strong {\n display: block;\n margin: 0 0 4px;\n color: var(--settings-text);\n font-size: 12px;\n font-weight: 500;\n line-height: 18px;\n}\n\n.settings-connection-install-callout p,\n.settings-connection-error-summary p,\n.settings-connection-state-summary p,\n.settings-connection-issue-note {\n margin: 0;\n color: var(--settings-muted);\n font-size: 11px;\n line-height: 16px;\n}\n\n.settings-connection-install-command {\n display: grid;\n gap: 4px;\n margin-top: 8px;\n}\n\n.settings-connection-install-command span {\n color: var(--settings-muted);\n font-size: 10px;\n font-weight: 600;\n line-height: 14px;\n letter-spacing: 0.04em;\n text-transform: uppercase;\n}\n\n.settings-connection-install-command code {\n display: block;\n min-width: 0;\n overflow-wrap: anywhere;\n color: var(--settings-text);\n font-family: ui-monospace, "SFMono-Regular", Consolas, "Liberation Mono", monospace;\n font-size: 11px;\n line-height: 16px;\n white-space: pre-wrap;\n}\n\n.settings-connection-install-actions {\n display: flex;\n flex-wrap: wrap;\n align-items: center;\n gap: 8px;\n}\n\n.settings-connection-copy-prompt {\n position: relative;\n}\n\n.settings-connection-copy-prompt__tooltip {\n position: absolute;\n z-index: 4;\n bottom: calc(100% + 6px);\n left: 0;\n width: max-content;\n max-width: min(360px, 72vw);\n max-height: 180px;\n overflow: auto;\n padding: 8px 10px;\n color: var(--settings-text);\n font-size: 11px;\n line-height: 16px;\n white-space: pre-wrap;\n text-align: left;\n background: var(--settings-elevated);\n border: 1px solid var(--settings-border);\n border-radius: 8px;\n box-shadow: 0 10px 24px rgb(0 0 0 / 22%);\n opacity: 0;\n visibility: hidden;\n pointer-events: none;\n transition: opacity 120ms ease;\n}\n\n.settings-connection-copy-prompt:hover .settings-connection-copy-prompt__tooltip,\n.settings-connection-copy-prompt:focus-within .settings-connection-copy-prompt__tooltip {\n opacity: 1;\n visibility: visible;\n}\n\n.settings-connection-error-summary {\n padding: 13px 14px;\n color: var(--settings-danger);\n background: var(--settings-danger-bg);\n border: 1px solid var(--settings-danger-border);\n border-radius: 10px;\n}\n\n.settings-connection-error-metadata {\n display: grid;\n gap: 7px;\n padding: 12px;\n background: var(--settings-inset);\n border: 1px solid var(--settings-border);\n border-radius: 9px;\n}\n\n.settings-connection-detail-line {\n display: grid;\n grid-template-columns: 92px minmax(0, 1fr);\n gap: 10px;\n min-width: 0;\n color: var(--settings-muted);\n font-size: 10px;\n line-height: 16px;\n}\n\n.settings-connection-detail-line code {\n min-width: 0;\n overflow-wrap: anywhere;\n color: var(--settings-text);\n font-family: ui-monospace, "SFMono-Regular", Consolas, "Liberation Mono", monospace;\n white-space: pre-wrap;\n}\n\n.settings-connection-error-log-header {\n display: flex;\n align-items: center;\n justify-content: space-between;\n gap: 10px;\n}\n\n.settings-connection-error-log-header strong {\n color: var(--settings-text);\n font-size: 11px;\n font-weight: 600;\n}\n\n.settings-connection-error-log-header .settings-command-button {\n min-height: 30px;\n padding: 5px 9px;\n font-size: 11px;\n}\n\n.settings-connection-stderr {\n max-height: 220px;\n min-width: 0;\n margin: 0;\n padding: 11px;\n overflow: auto;\n color: var(--settings-text);\n font:\n 10px/16px ui-monospace,\n "SFMono-Regular",\n Consolas,\n "Liberation Mono",\n monospace;\n white-space: pre-wrap;\n overflow-wrap: anywhere;\n background: var(--settings-inset);\n border: 1px solid var(--settings-border);\n border-radius: 9px;\n}\n\n.settings-connection-error-actions {\n display: grid;\n grid-template-columns: minmax(0, 1fr);\n gap: 8px;\n}\n\n.settings-connection-error-actions .settings-command-button {\n width: 100%;\n}\n\n.settings-connection-issue-note {\n margin-top: -4px;\n}\n\n.settings-connection-state-summary {\n padding: 14px;\n background: var(--settings-surface);\n border: 1px solid var(--settings-border);\n border-radius: 10px;\n}\n\n.settings-empty {\n display: flex;\n align-items: center;\n min-height: 72px;\n padding: 12px 16px;\n}\n\n.settings-empty > div {\n display: grid;\n min-width: 0;\n gap: 2px;\n}\n\n.settings-empty strong {\n color: var(--settings-text);\n font-size: 13px;\n font-weight: 500;\n line-height: 19px;\n}\n\n.settings-empty span {\n color: var(--settings-muted);\n font-size: 13px;\n line-height: 19px;\n}\n\n.settings-about-page {\n display: flex;\n flex-direction: column;\n gap: 18px;\n box-sizing: border-box;\n min-height: min(620px, calc(100vh - 200px));\n max-width: 720px;\n}\n\n.settings-about-page > .settings-section-label {\n padding-bottom: 10px;\n}\n\n.settings-about-panel {\n display: grid;\n gap: 18px;\n padding: 24px;\n background: var(--settings-panel);\n border: 1px solid var(--settings-border);\n border-radius: 12px;\n}\n\n.settings-about-product {\n color: var(--settings-text);\n font-size: 24px;\n font-weight: 700;\n line-height: 32px;\n}\n\n.settings-about-tagline {\n color: var(--settings-text);\n font-size: 16px;\n font-weight: 600;\n line-height: 24px;\n}\n\n.settings-about-copy {\n display: grid;\n max-width: 660px;\n gap: 12px;\n}\n\n.settings-about-lead,\n.settings-about-extension,\n.settings-about-closing p,\n.settings-about-copy p {\n margin: 0;\n color: var(--settings-muted);\n font-size: 13px;\n line-height: 21px;\n}\n\n.settings-about-lead {\n color: var(--settings-text);\n font-weight: 500;\n}\n\n.settings-about-agents {\n display: grid;\n gap: 10px;\n margin: 2px 0;\n padding: 0;\n list-style: none;\n}\n\n.settings-about-agent {\n display: grid;\n gap: 4px;\n padding-left: 2px;\n}\n\n.settings-about-agent-name {\n color: var(--settings-text);\n font-size: 13px;\n font-weight: 600;\n line-height: 18px;\n}\n\n.settings-about-agent-name::before {\n content: "\xB7 ";\n color: var(--settings-muted);\n font-weight: 600;\n}\n\n.settings-about-agent-description {\n display: block;\n padding-left: 0.85em;\n color: var(--settings-muted);\n font-size: 12px;\n font-weight: 400;\n line-height: 18px;\n}\n\n.settings-about-closing {\n display: grid;\n gap: 8px;\n}\n\n.settings-about-repository {\n gap: 10px;\n}\n\n.settings-about-open-source {\n display: flex;\n align-items: center;\n flex-wrap: wrap;\n gap: 0.35em;\n margin: 0;\n color: var(--settings-muted);\n font-size: 13px;\n line-height: 21px;\n}\n\n.settings-about-repository p {\n margin: 0;\n color: var(--settings-muted);\n font-size: 13px;\n line-height: 21px;\n}\n\n.settings-about-star-callout {\n margin: 4px 0 0;\n color: var(--settings-warning);\n font-size: 14px;\n font-weight: 600;\n line-height: 22px;\n}\n\n.settings-about-repository-link {\n display: inline-flex;\n align-items: center;\n gap: 6px;\n color: #7cb8ff;\n font-weight: 600;\n line-height: 1;\n text-decoration: none;\n}\n\n.settings-about-repository-link .codexhost-settings-icon {\n display: block;\n flex: none;\n}\n\n.settings-about-repository-link:hover {\n text-decoration: underline;\n}\n\n.settings-about-brand {\n display: flex;\n align-items: center;\n justify-content: center;\n gap: 12px;\n margin-top: auto;\n padding-top: 12px;\n color: inherit;\n opacity: 0.9;\n text-decoration: none;\n transition: opacity 160ms ease;\n}\n\n.settings-about-brand:hover {\n opacity: 1;\n}\n\n.settings-about-brand-video {\n width: 40px;\n height: 40px;\n flex: none;\n overflow: hidden;\n object-fit: cover;\n border-radius: 999px;\n box-shadow: 0 1px 2px rgb(0 0 0 / 18%);\n}\n\n.settings-about-brand-copy {\n display: flex;\n flex-direction: column;\n align-items: flex-start;\n gap: 2px;\n}\n\n.settings-about-brand-name {\n color: var(--settings-text);\n font-size: 14px;\n font-weight: 800;\n letter-spacing: 0.18em;\n line-height: 18px;\n}\n\n.settings-about-brand-tagline {\n color: var(--settings-muted);\n font-size: 12px;\n font-weight: 500;\n letter-spacing: 0.18em;\n line-height: 16px;\n}\n\n.settings-page-error {\n padding: 16px;\n color: var(--settings-text);\n font-size: 13px;\n background: var(--settings-panel);\n border: 1px solid var(--settings-border);\n border-radius: 20px;\n}\n\n.settings-update-metadata {\n display: grid;\n grid-template-columns: repeat(3, minmax(0, 1fr));\n gap: 24px;\n margin-bottom: 24px;\n padding: 0 0 20px;\n border-bottom: 1px solid var(--settings-divider);\n}\n\n.settings-update-metadata__item {\n display: grid;\n min-width: 0;\n gap: 4px;\n}\n\n.settings-update-metadata__item span {\n color: var(--settings-muted);\n font-size: 12px;\n line-height: 18px;\n}\n\n.settings-update-metadata__item strong {\n min-width: 0;\n overflow-wrap: anywhere;\n color: var(--settings-text);\n font-size: 15px;\n font-weight: 500;\n line-height: 22px;\n}\n\n/* The only emphasis on this screen: a latest version newer than the installed one. */\n.settings-update-metadata__value--newer {\n color: var(--settings-focus);\n}\n\n.settings-update-panel {\n display: grid;\n gap: 12px;\n padding: 20px;\n color: var(--settings-text);\n background: var(--settings-panel);\n border: 1px solid var(--settings-border);\n border-radius: 8px;\n}\n\n/* Soft status copy and the Update action should not sit in a framed card. */\n.settings-update-panel[data-update-state="unavailable"],\n.settings-update-panel[data-update-state="failed"],\n.settings-update-panel[data-update-state="error"],\n.settings-update-panel[data-update-state="available"] {\n padding: 4px 0 0;\n border: 0;\n border-radius: 0;\n}\n\n.settings-update-panel__status-row {\n display: flex;\n align-items: center;\n flex-wrap: wrap;\n gap: 8px;\n min-width: 0;\n}\n\n.settings-update-panel__status-row .settings-update-actions {\n flex: none;\n}\n\n.settings-update-panel__status-row .settings-update-panel__head {\n flex: 1 1 auto;\n min-width: 0;\n}\n\n.settings-update-panel__head {\n display: flex;\n align-items: center;\n min-width: 0;\n gap: 8px;\n}\n\n.settings-update-panel__head .codexhost-settings-icon {\n color: var(--settings-muted);\n}\n\n.settings-update-panel[data-update-state="available"]\n .settings-update-panel__head\n .codexhost-settings-icon,\n.settings-update-panel[data-update-state="downloading"]\n .settings-update-panel__head\n .codexhost-settings-icon,\n.settings-update-panel[data-update-state="installing"]\n .settings-update-panel__head\n .codexhost-settings-icon,\n.settings-update-panel[data-update-state="restarting"]\n .settings-update-panel__head\n .codexhost-settings-icon {\n color: var(--settings-focus);\n}\n\n.settings-update-panel[data-update-state="current"]\n .settings-update-panel__head\n .codexhost-settings-icon {\n color: var(--settings-success);\n}\n\n.settings-update-panel[data-update-state="failed"]\n .settings-update-panel__head\n .codexhost-settings-icon,\n.settings-update-panel[data-update-state="error"]\n .settings-update-panel__head\n .codexhost-settings-icon {\n color: var(--settings-danger);\n}\n\n.settings-update-panel[data-update-state="unavailable"]\n .settings-update-panel__head\n .codexhost-settings-icon {\n color: var(--settings-muted);\n}\n\n.settings-update-panel__title {\n min-width: 0;\n overflow-wrap: anywhere;\n color: var(--settings-text);\n font-size: 14px;\n font-weight: 600;\n line-height: 22px;\n}\n\n.settings-update-summary,\n.settings-update-error {\n margin: 0;\n overflow-wrap: anywhere;\n font-size: 13px;\n line-height: 20px;\n}\n\n.settings-update-summary {\n color: var(--settings-muted);\n}\n\n.settings-update-error {\n color: var(--settings-danger);\n}\n\n.settings-update-progress {\n width: 100%;\n height: 8px;\n accent-color: var(--settings-focus);\n}\n\n.settings-update-progress-detail {\n color: var(--settings-muted);\n font-size: 12px;\n line-height: 18px;\n}\n\n/* Release notes scroll with the page; a scroller inside a scroller traps the wheel. */\n.settings-update-notes-section {\n min-width: 0;\n margin-top: 24px;\n padding-top: 24px;\n border-top: 1px solid var(--settings-divider);\n}\n\n.settings-update-notes-section:empty {\n display: none;\n}\n\n.settings-update-notes {\n display: grid;\n min-width: 0;\n gap: 12px;\n color: var(--settings-muted);\n font-size: 14px;\n line-height: 22px;\n overflow-wrap: anywhere;\n}\n\n.settings-update-notes > :first-child {\n margin-top: 0;\n}\n\n.settings-update-notes > :last-child {\n margin-bottom: 0;\n}\n\n.settings-update-notes h1,\n.settings-update-notes h2,\n.settings-update-notes h3,\n.settings-update-notes h4,\n.settings-update-notes h5,\n.settings-update-notes h6 {\n margin: 6px 0 0;\n color: var(--settings-text);\n font-weight: 600;\n}\n\n.settings-update-notes h1 {\n font-size: 18px;\n line-height: 26px;\n}\n\n.settings-update-notes h2 {\n font-size: 17px;\n line-height: 24px;\n}\n\n.settings-update-notes h3,\n.settings-update-notes h4,\n.settings-update-notes h5,\n.settings-update-notes h6 {\n font-size: 14px;\n line-height: 22px;\n}\n\n.settings-update-notes p,\n.settings-update-notes ul,\n.settings-update-notes ol,\n.settings-update-notes pre,\n.settings-update-notes blockquote {\n margin: 0;\n}\n\n.settings-update-notes ul,\n.settings-update-notes ol {\n padding-left: 24px;\n}\n\n.settings-update-notes li {\n padding-left: 4px;\n}\n\n.settings-update-notes li::marker {\n color: var(--settings-muted);\n font-size: 0.85em;\n}\n\n.settings-update-notes li + li {\n margin-top: 14px;\n}\n\n.settings-update-notes .release-note-translation {\n display: block;\n margin-top: 3px;\n color: var(--settings-muted);\n font-size: 13px;\n line-height: 20px;\n}\n\n.settings-update-notes blockquote {\n padding: 8px 12px;\n color: var(--settings-muted);\n border-left: 3px solid var(--settings-focus);\n background: var(--settings-surface);\n}\n\n.settings-update-notes hr {\n width: 100%;\n margin: 2px 0;\n border: 0;\n border-top: 1px solid var(--settings-divider);\n}\n\n.settings-update-notes strong {\n color: var(--settings-text);\n font-weight: 600;\n}\n\n.settings-update-notes a {\n color: var(--settings-focus);\n text-decoration: none;\n}\n\n.settings-update-notes a:hover {\n text-decoration: underline;\n}\n\n.settings-update-notes code {\n font-family: ui-monospace, "SFMono-Regular", Consolas, "Liberation Mono", monospace;\n font-size: 12px;\n}\n\n.settings-update-notes :not(pre) > code {\n padding: 1px 5px;\n background: var(--settings-surface-strong);\n border-radius: 4px;\n}\n\n.settings-update-notes pre {\n min-width: 0;\n max-width: 100%;\n padding: 10px 12px;\n overflow-x: auto;\n overflow-y: hidden;\n background: var(--settings-inset);\n border-radius: 6px;\n}\n\n.settings-update-notes pre code {\n line-height: 18px;\n white-space: pre-wrap;\n}\n\n/* Manual update sits directly under the status panel, not behind a disclosure:\n automatic updates can fail for machine-local reasons and this is the way out. */\n.settings-update-controls {\n display: grid;\n min-width: 0;\n gap: 10px;\n margin-top: 24px;\n}\n\n.settings-update-manual-title {\n color: var(--settings-text);\n font-size: 15px;\n font-weight: 600;\n line-height: 22px;\n}\n\n.settings-update-manual {\n display: grid;\n min-width: 0;\n gap: 8px;\n}\n\n.settings-update-manual[hidden] {\n display: none;\n}\n\n.settings-update-manual-description {\n margin: 0;\n color: var(--settings-muted);\n font-size: 12px;\n line-height: 18px;\n}\n\n.settings-update-manual-description.is-fallback {\n color: var(--settings-danger);\n}\n\n.settings-update-command {\n display: flex;\n align-items: stretch;\n min-width: 0;\n overflow: hidden;\n border: 1px solid var(--settings-border);\n border-radius: 6px;\n}\n\n.settings-update-command code {\n min-width: 0;\n flex: 1;\n padding: 9px 12px;\n overflow-x: auto;\n color: var(--settings-text);\n font-family: ui-monospace, "SFMono-Regular", Consolas, "Liberation Mono", monospace;\n font-size: 12px;\n line-height: 20px;\n white-space: nowrap;\n}\n\n.settings-update-command__copy {\n display: inline-flex;\n align-items: center;\n flex: none;\n gap: 6px;\n padding: 0 12px;\n color: var(--settings-muted);\n font-size: 12px;\n background: transparent;\n border: 0;\n border-left: 1px solid var(--settings-border);\n cursor: pointer;\n}\n\n.settings-update-command__copy:hover {\n color: var(--settings-text);\n background: var(--settings-hover);\n}\n\n.settings-update-command__copy:focus-visible {\n outline: 2px solid var(--settings-focus);\n outline-offset: -2px;\n}\n\n.settings-update-actions {\n display: flex;\n align-items: center;\n min-width: 0;\n gap: 12px;\n flex-wrap: wrap;\n}\n\n.settings-command-button,\n.settings-update-link {\n display: inline-flex;\n align-items: center;\n justify-content: center;\n flex: none;\n width: max-content;\n max-width: 100%;\n min-height: 30px;\n gap: 6px;\n padding: 5px 10px;\n white-space: nowrap;\n color: var(--settings-primary-text);\n font: inherit;\n font-size: 12px;\n text-decoration: none;\n background: var(--settings-primary);\n border: 1px solid var(--settings-primary);\n border-radius: 7px;\n cursor: pointer;\n}\n\n.settings-command-button--secondary,\n.settings-update-link {\n color: var(--settings-muted);\n background: transparent;\n border-color: var(--settings-border);\n}\n\n.settings-command-button--secondary .codexhost-settings-icon,\n.settings-update-link .codexhost-settings-icon {\n color: var(--settings-muted);\n}\n\n.settings-command-button:hover:not(.settings-command-button--secondary) {\n filter: brightness(1.08);\n}\n\n.settings-command-button--danger {\n color: var(--settings-danger);\n}\n\n.settings-command-button--danger:hover:not(:disabled) {\n color: #fecaca;\n background: var(--settings-danger-bg);\n border-color: var(--settings-danger-border);\n}\n\n.settings-command-button--secondary:hover,\n.settings-update-link:hover {\n color: var(--settings-text);\n background: var(--settings-hover);\n}\n\n.settings-command-button--secondary:hover .codexhost-settings-icon,\n.settings-update-link:hover .codexhost-settings-icon {\n color: var(--settings-text);\n}\n\n.settings-command-button:disabled,\n.settings-command-button[aria-disabled="true"] {\n opacity: 0.55;\n cursor: not-allowed;\n filter: none;\n}\n\n.settings-command-button:focus-visible,\n.settings-update-link:focus-visible {\n outline: 2px solid var(--settings-focus);\n outline-offset: 2px;\n}\n\n.settings-visually-hidden {\n position: absolute;\n width: 1px;\n height: 1px;\n padding: 0;\n margin: -1px;\n overflow: hidden;\n clip: rect(0, 0, 0, 0);\n white-space: nowrap;\n border: 0;\n}\n\n.settings-session-import-content {\n display: grid;\n min-width: 0;\n gap: 12px;\n margin-top: 16px;\n}\n\n.settings-session-import-list {\n display: grid;\n min-width: 0;\n overflow: hidden;\n background: var(--settings-surface);\n border: 1px solid var(--settings-border);\n border-radius: 12px;\n}\n\n.settings-session-import-row {\n display: grid;\n grid-template-columns: minmax(0, 1fr) auto;\n align-items: center;\n min-width: 0;\n gap: 16px;\n padding: 14px 16px;\n border-bottom: 1px solid var(--settings-divider);\n}\n\n.settings-session-import-row:last-child {\n border-bottom: 0;\n}\n\n.settings-session-import-row__copy {\n display: grid;\n min-width: 0;\n gap: 4px;\n}\n\n.settings-session-import-row__copy strong {\n color: var(--settings-text);\n font-size: 14px;\n font-weight: 600;\n line-height: 20px;\n}\n\n.settings-session-import-row__copy span,\n.settings-session-import-row__cwd {\n min-width: 0;\n overflow-wrap: anywhere;\n color: var(--settings-muted);\n font-size: 12px;\n line-height: 18px;\n}\n\n.settings-session-import-row__cwd {\n font-family: ui-monospace, "SFMono-Regular", Consolas, "Liberation Mono", monospace;\n}\n\n.settings-session-import-row__action {\n display: flex;\n align-items: center;\n flex: none;\n gap: 8px;\n}\n\n.settings-session-import-running {\n color: #f5c542;\n font-size: 12px;\n font-weight: 500;\n line-height: 18px;\n white-space: nowrap;\n}\n\n.settings-session-import-recovery {\n display: grid;\n min-width: 0;\n gap: 12px;\n padding: 16px;\n background: var(--settings-surface);\n border: 1px solid var(--settings-border);\n border-radius: 12px;\n}\n\n.settings-session-import-recovery__copy {\n display: grid;\n gap: 6px;\n}\n\n.settings-session-import-recovery__copy strong {\n color: var(--settings-text);\n font-size: 15px;\n font-weight: 600;\n line-height: 22px;\n}\n\n.settings-session-import-recovery__copy p {\n margin: 0;\n color: var(--settings-muted);\n font-size: 13px;\n line-height: 20px;\n}\n\n.settings-session-import-recovery__path {\n display: flex;\n align-items: center;\n min-width: 0;\n gap: 8px;\n}\n\n.settings-session-import-recovery__path code {\n min-width: 0;\n flex: 1;\n overflow-wrap: anywhere;\n color: var(--settings-text);\n font-family: ui-monospace, "SFMono-Regular", Consolas, "Liberation Mono", monospace;\n font-size: 12px;\n line-height: 18px;\n}\n\n.codexhost-settings-icon {\n display: block;\n flex: none;\n stroke: currentColor;\n}\n\n@media (max-width: 720px) {\n .codexhost-settings-dialog {\n width: calc(100vw - 16px);\n height: calc(100vh - 16px);\n border-radius: 10px;\n }\n\n .settings-layout {\n grid-template-columns: minmax(0, 1fr);\n grid-template-rows: auto minmax(0, 1fr);\n }\n\n .settings-sidebar {\n border-right: 0;\n border-bottom: 1px solid var(--settings-border);\n }\n\n .settings-header {\n height: 56px;\n padding-inline: 14px;\n }\n\n .settings-sidebar {\n padding-top: 20px;\n }\n\n .settings-nav {\n flex: none;\n flex-direction: row;\n gap: 4px;\n padding: 7px 8px 8px;\n overflow-x: auto;\n overflow-y: hidden;\n }\n\n .settings-nav-section-label {\n display: none;\n }\n\n .settings-nav-button {\n width: auto;\n min-width: max-content;\n min-height: 34px;\n grid-template-columns: 16px auto;\n border-radius: 10px;\n }\n\n .settings-page__content {\n width: calc(100% - 40px);\n }\n\n .settings-page__content {\n padding-top: 32px;\n padding-bottom: 32px;\n }\n\n .settings-section-label {\n padding-bottom: 20px;\n font-size: 20px;\n line-height: 26px;\n }\n\n .settings-update-metadata {\n grid-template-columns: minmax(0, 1fr);\n gap: 16px;\n }\n\n .settings-status-row {\n grid-template-columns: minmax(0, 1fr) auto;\n gap: 16px;\n }\n\n .settings-account-header,\n .settings-connection-page-header {\n flex-direction: column;\n }\n\n .settings-account-header > .settings-command-button,\n .settings-connection-page-header > .settings-command-button {\n width: 100%;\n }\n\n .settings-session-import-row {\n grid-template-columns: minmax(0, 1fr);\n }\n\n .settings-session-import-row__action {\n justify-content: flex-start;\n flex-wrap: wrap;\n }\n\n .settings-status-row__detail {\n grid-column: 1 / -1;\n margin: -8px 0 0 58px;\n }\n}\n\n@media (forced-colors: active) {\n :host,\n :host([data-theme="light"]),\n :host([data-theme="dark"]) {\n --settings-bg: Canvas;\n --settings-sidebar: Canvas;\n --settings-panel: Canvas;\n --settings-surface: Canvas;\n --settings-surface-hover: Highlight;\n --settings-inset: Canvas;\n --settings-text: CanvasText;\n --settings-muted: GrayText;\n --settings-subtle: GrayText;\n --settings-border: ButtonBorder;\n --settings-divider: ButtonBorder;\n --settings-hover: Highlight;\n --settings-active: Highlight;\n --settings-focus: Highlight;\n --settings-elevated: Canvas;\n --settings-surface-strong: Canvas;\n --settings-mark: CanvasText;\n --settings-primary: ButtonFace;\n --settings-primary-hover: Highlight;\n --settings-primary-text: ButtonText;\n --settings-warning: CanvasText;\n --settings-warning-bg: Canvas;\n --settings-warning-border: ButtonBorder;\n --settings-danger: CanvasText;\n --settings-danger-bg: Canvas;\n --settings-danger-border: ButtonBorder;\n --settings-success: CanvasText;\n }\n}\n\n@media (prefers-reduced-motion: reduce) {\n *,\n *::before,\n *::after {\n scroll-behavior: auto !important;\n transition-duration: 0s !important;\n }\n}\n';
|
|
27085
|
+
var shell_default = ':host {\n /* Inherit Codex Desktop color-scheme; light-dark() tracks the host page. */\n --settings-bg: light-dark(#ffffff, #181818);\n --settings-sidebar: light-dark(#f4f4f5, #1c1c1c);\n --settings-panel: transparent;\n --settings-text: light-dark(#171717, #f5f5f5);\n --settings-muted: light-dark(#737373, #a1a1a1);\n --settings-subtle: light-dark(#8a8a8a, #777777);\n --settings-border: light-dark(rgb(15 23 42 / 10%), rgb(255 255 255 / 10%));\n --settings-divider: light-dark(rgb(15 23 42 / 10%), rgb(255 255 255 / 10%));\n --settings-hover: light-dark(rgb(15 23 42 / 5%), rgb(255 255 255 / 6%));\n --settings-active: light-dark(rgb(51 156 255 / 14%), rgb(51 156 255 / 12%));\n --settings-focus: #339cff;\n --settings-elevated: light-dark(#ffffff, #2c2c2e);\n --settings-inset: light-dark(rgb(15 23 42 / 4%), rgb(0 0 0 / 18%));\n --settings-surface: light-dark(rgb(15 23 42 / 3%), rgb(255 255 255 / 2%));\n --settings-surface-strong: light-dark(rgb(15 23 42 / 6%), rgb(255 255 255 / 6%));\n --settings-surface-hover: light-dark(#eeeeee, #303030);\n --settings-mark: light-dark(#52525b, #d4d8de);\n --settings-dialog-shadow: light-dark(\n 0 24px 64px rgb(15 23 42 / 16%),\n 0 24px 64px rgb(0 0 0 / 38%)\n );\n --settings-backdrop: light-dark(rgb(15 23 42 / 28%), rgb(0 0 0 / 52%));\n --settings-segmented-shadow:\n 0 0 0 0.5px light-dark(rgb(15 23 42 / 6%), rgb(0 0 0 / 4%)),\n 0 3px 1px 0 light-dark(rgb(15 23 42 / 4%), rgb(0 0 0 / 4%)),\n 0 3px 8px 0 light-dark(rgb(15 23 42 / 10%), rgb(0 0 0 / 12%));\n --settings-primary: light-dark(#171717, #f4f4f4);\n --settings-primary-hover: light-dark(#2f2f2f, #ffffff);\n --settings-primary-text: light-dark(#ffffff, #171717);\n --settings-warning: light-dark(#8a5500, #f5c96a);\n --settings-warning-bg: light-dark(#fff8e6, rgb(245 201 106 / 8%));\n --settings-warning-border: light-dark(#ead8a8, rgb(245 201 106 / 24%));\n --settings-danger: light-dark(#b42318, #f87171);\n --settings-danger-bg: light-dark(#fff1f0, rgb(239 68 68 / 8%));\n --settings-danger-border: light-dark(#f3c7c3, rgb(239 68 68 / 22%));\n --settings-success: light-dark(#16784a, #4ade80);\n --settings-dialog-max-width: 1120px;\n --settings-dialog-max-height: 780px;\n --settings-dialog-inset: max(52px, env(titlebar-area-height, 0px));\n color: var(--settings-text);\n color-scheme: inherit;\n font:\n 13px/1.5 system-ui,\n -apple-system,\n BlinkMacSystemFont,\n "Segoe UI",\n sans-serif;\n letter-spacing: 0;\n}\n\n*,\n*::before,\n*::after {\n box-sizing: border-box;\n letter-spacing: 0;\n}\n\nbutton,\ninput,\nselect {\n font: inherit;\n}\n\nbutton {\n color: inherit;\n}\n\n[hidden] {\n display: none !important;\n}\n\n.codexhost-settings-dialog {\n width: min(var(--settings-dialog-max-width), calc(100vw - 2 * var(--settings-dialog-inset)));\n height: min(var(--settings-dialog-max-height), calc(100vh - 2 * var(--settings-dialog-inset)));\n max-width: none;\n max-height: none;\n margin: auto;\n padding: 0;\n overflow: hidden;\n color: var(--settings-text);\n background: var(--settings-bg);\n border: 1px solid var(--settings-border);\n border-radius: 12px;\n box-shadow: var(--settings-dialog-shadow);\n}\n\n.codexhost-settings-dialog::backdrop {\n background: var(--settings-backdrop);\n}\n\n.settings-frame,\n.settings-layout {\n width: 100%;\n height: 100%;\n min-width: 0;\n min-height: 0;\n}\n\n.settings-frame {\n display: flex;\n flex-direction: column;\n}\n\n.settings-layout {\n flex: 1;\n display: grid;\n grid-template-columns: 184px minmax(0, 1fr);\n background: var(--settings-bg);\n}\n\n.settings-sidebar {\n display: flex;\n min-width: 0;\n min-height: 0;\n flex-direction: column;\n overflow: hidden;\n background: var(--settings-sidebar);\n border-right: 1px solid var(--settings-border);\n padding-top: 14px;\n}\n\n.settings-header {\n display: flex;\n align-items: center;\n min-width: 0;\n height: 48px;\n flex: none;\n padding: 0 12px;\n border-bottom: 1px solid var(--settings-border);\n}\n\n.settings-header-actions {\n display: flex;\n align-items: center;\n flex: none;\n gap: 12px;\n margin-left: auto;\n}\n\n.settings-brand {\n display: flex;\n align-items: center;\n min-width: 0;\n gap: 7px;\n}\n\n.settings-brand__mark {\n display: inline-flex;\n align-items: center;\n justify-content: center;\n width: 26px;\n height: 26px;\n flex: none;\n color: var(--settings-text);\n}\n\n.settings-brand__mark .codexhost-settings-icon {\n width: 24px;\n height: 24px;\n object-fit: contain;\n}\n\n.settings-brand__copy {\n display: flex;\n min-width: 0;\n align-items: baseline;\n gap: 0;\n line-height: 20px;\n}\n\n.settings-brand__name {\n overflow: hidden;\n color: var(--settings-text);\n font-size: 13px;\n font-weight: 600;\n text-overflow: ellipsis;\n white-space: nowrap;\n}\n\n.settings-brand__title {\n margin-left: 8px;\n padding-left: 8px;\n color: var(--settings-muted);\n font-size: 13px;\n font-weight: 400;\n border-left: 1px solid var(--settings-border);\n}\n\n.settings-nav {\n display: flex;\n min-width: 0;\n min-height: 0;\n flex: 1;\n flex-direction: column;\n gap: 2px;\n padding: 0 7px 10px;\n overflow-y: auto;\n}\n\n.settings-nav-section-label {\n min-height: 28px;\n padding: 7px 9px 3px 4px;\n color: var(--settings-muted);\n font-size: 12px;\n font-weight: 600;\n line-height: 18px;\n}\n\n.settings-nav-section-label:not(:first-child) {\n margin-top: 8px;\n}\n\n.settings-nav-button {\n display: grid;\n grid-template-columns: 16px minmax(0, 1fr);\n align-items: center;\n width: 100%;\n position: relative;\n min-height: 34px;\n flex: none;\n gap: 9px;\n padding: 6px 9px;\n color: var(--settings-text);\n font-size: 14px;\n font-weight: 600;\n line-height: 21px;\n text-align: left;\n background: transparent;\n border: 0;\n border-radius: 8px;\n cursor: pointer;\n}\n\n.settings-nav-button .codexhost-settings-icon {\n width: 16px;\n height: 16px;\n opacity: 0.9;\n}\n\n.settings-nav-button:hover {\n background: var(--settings-hover);\n}\n\n.settings-nav-button[aria-current="page"] {\n background: var(--settings-active);\n color: var(--settings-text);\n font-weight: 500;\n}\n\n.settings-nav-button span {\n min-width: 0;\n overflow: hidden;\n text-overflow: ellipsis;\n white-space: nowrap;\n}\n\n.settings-icon-button {\n display: inline-flex;\n align-items: center;\n justify-content: center;\n width: 28px;\n height: 28px;\n flex: none;\n padding: 0;\n color: var(--settings-muted);\n background: transparent;\n border: 0;\n border-radius: 8px;\n cursor: pointer;\n}\n\n.settings-icon-button:hover {\n color: var(--settings-text);\n background: var(--settings-hover);\n}\n\n.settings-icon-button:focus-visible,\n.settings-nav-button:focus-visible {\n outline: 2px solid var(--settings-focus);\n outline-offset: 1px;\n}\n\n.settings-page {\n display: block;\n position: relative;\n min-width: 0;\n min-height: 0;\n overflow-y: auto;\n background: var(--settings-bg);\n scrollbar-gutter: stable;\n}\n\n.settings-page__content {\n width: min(930px, calc(100% - 80px));\n margin-inline: auto;\n}\n\n.settings-page__content {\n min-width: 0;\n padding: 28px 0 36px;\n}\n\n.settings-section-label {\n min-height: auto;\n padding: 0 0 28px;\n color: var(--settings-text);\n font-size: 18px;\n font-weight: 600;\n line-height: 26px;\n}\n\n.settings-status-list,\n.settings-empty {\n overflow: hidden;\n background: var(--settings-panel);\n}\n\n.settings-status-row {\n display: grid;\n grid-template-columns: minmax(170px, 1fr) auto minmax(280px, 1.45fr);\n position: relative;\n align-items: center;\n min-height: 72px;\n gap: 20px;\n padding: 12px 0;\n}\n\n.settings-status-row:not(:last-child)::after {\n content: "";\n position: absolute;\n right: 0;\n bottom: 0;\n left: 0;\n height: 1px;\n background: var(--settings-divider);\n}\n\n.settings-status-row__identity {\n display: inline-flex;\n align-items: center;\n min-width: 0;\n color: var(--settings-text);\n gap: 10px;\n font-size: 14px;\n font-weight: 500;\n line-height: 22px;\n}\n\n.settings-status-row__icon {\n display: inline-flex;\n align-items: center;\n justify-content: center;\n width: 36px;\n height: 36px;\n flex: none;\n color: var(--settings-muted);\n background: var(--settings-surface-strong);\n border-radius: 50%;\n}\n\n.settings-status-badge {\n flex: none;\n padding: 3px 8px;\n color: var(--settings-muted);\n font-size: 11px;\n font-weight: 500;\n line-height: 18px;\n background: var(--settings-surface-strong);\n border: 1px solid var(--settings-border);\n border-radius: 6px;\n}\n\n.settings-status-row__detail {\n min-width: 0;\n color: var(--settings-muted);\n font-size: 13px;\n line-height: 20px;\n}\n\n.settings-page-description {\n max-width: 760px;\n margin: -10px 0 20px;\n color: var(--settings-muted);\n font-size: 12px;\n line-height: 18px;\n}\n\n.settings-session-import-header {\n display: flex;\n align-items: flex-start;\n justify-content: space-between;\n gap: 24px;\n}\n\n.settings-session-import-header .settings-section-label {\n min-width: 0;\n}\n\n.settings-session-import-harness {\n display: flex;\n min-width: 0;\n margin: 0 0 16px;\n}\n\n.settings-session-import-harness__options {\n display: flex;\n flex-wrap: wrap;\n align-items: center;\n width: fit-content;\n max-width: 100%;\n gap: 8px;\n}\n\n.settings-session-import-harness__option {\n min-height: 32px;\n flex: none;\n padding: 6px 10px;\n color: var(--settings-muted);\n font: inherit;\n font-size: 12px;\n white-space: nowrap;\n background: transparent;\n border: 1px solid var(--settings-border);\n border-radius: 6px;\n cursor: pointer;\n}\n\n.settings-session-import-harness__option[aria-pressed="true"] {\n color: var(--settings-text);\n background: var(--settings-active);\n border-color: rgb(51 156 255 / 50%);\n}\n\n.settings-session-import-harness__option:disabled {\n opacity: 0.38;\n cursor: not-allowed;\n}\n\n.settings-session-import-harness__option:focus-visible {\n outline: 2px solid var(--settings-focus);\n outline-offset: 2px;\n}\n\n.settings-session-import-search,\n.settings-session-import-pagination {\n display: flex;\n flex-wrap: wrap;\n align-items: center;\n gap: 10px;\n}\n\n.settings-session-import-search {\n align-items: stretch;\n margin: 16px 0 0;\n}\n\n.settings-session-import-pagination {\n margin: 16px 0 0;\n}\n\n.settings-session-import-search input {\n flex: 1;\n min-width: 160px;\n}\n\n.settings-session-import-search input,\n.settings-session-import-pagination select {\n box-sizing: border-box;\n color: var(--settings-text);\n background: var(--settings-bg);\n border: 1px solid var(--settings-border);\n border-radius: 6px;\n}\n\n.settings-session-import-search input,\n.settings-session-import-search .settings-command-button {\n box-sizing: border-box;\n height: 36px;\n min-height: 36px;\n padding: 6px 10px;\n border-radius: 6px;\n}\n\n.settings-session-import-pagination select {\n min-height: 28px;\n padding: 2px 8px;\n}\n\n.settings-session-import-search input:focus-visible,\n.settings-session-import-pagination select:focus-visible {\n outline: 2px solid var(--settings-focus);\n outline-offset: 2px;\n}\n\n.settings-session-import-pagination {\n color: var(--settings-muted);\n font-size: 12px;\n line-height: 18px;\n}\n\n.settings-session-import-pagination label {\n display: flex;\n align-items: center;\n gap: 8px;\n}\n\n.settings-session-import-pagination > span {\n flex: none;\n min-width: 0;\n}\n\n.settings-session-import-pagination__navigation {\n display: flex;\n gap: 8px;\n margin-left: auto;\n}\n\n.settings-session-import-content,\n.settings-session-import-list {\n display: grid;\n gap: 10px;\n}\n\n.settings-session-import-content {\n margin-top: 16px;\n}\n\n.settings-session-import-status {\n display: flex;\n align-items: center;\n min-height: 0;\n gap: 12px;\n padding: 12px 16px;\n color: var(--settings-muted);\n background: var(--settings-panel);\n border: 1px solid var(--settings-border);\n border-radius: 8px;\n}\n\n.settings-session-import-status.is-error {\n color: #ef4444;\n}\n\n.settings-session-import-recovery {\n display: grid;\n justify-items: start;\n gap: 14px;\n padding: 16px;\n background: var(--settings-panel);\n border: 1px solid var(--settings-border);\n border-radius: 8px;\n}\n\n.settings-session-import-recovery:focus-visible {\n outline: 2px solid var(--settings-focus);\n outline-offset: 2px;\n}\n\n.settings-session-import-recovery__copy {\n display: grid;\n gap: 4px;\n}\n\n.settings-session-import-recovery__copy strong {\n color: var(--settings-text);\n font-size: 14px;\n}\n\n.settings-session-import-recovery__copy p {\n margin: 0;\n color: var(--settings-muted);\n font-size: 13px;\n line-height: 20px;\n}\n\n.settings-session-import-recovery__path {\n display: flex;\n align-items: stretch;\n width: 100%;\n min-width: 0;\n overflow: hidden;\n border: 1px solid var(--settings-border);\n border-radius: 6px;\n}\n\n.settings-session-import-recovery__path code {\n min-width: 0;\n flex: 1;\n padding: 8px 10px;\n overflow-x: auto;\n color: var(--settings-text);\n font-size: 12px;\n line-height: 20px;\n white-space: nowrap;\n}\n\n.settings-session-import-recovery__path .settings-command-button {\n min-height: 0;\n flex: none;\n border-width: 0 0 0 1px;\n border-radius: 0;\n}\n\n.settings-session-import-row {\n display: grid;\n grid-template-columns: minmax(0, 1fr) auto;\n align-items: center;\n gap: 20px;\n min-width: 0;\n padding: 16px;\n background: var(--settings-panel);\n border: 1px solid var(--settings-border);\n border-radius: 8px;\n}\n\n.settings-session-import-row__copy {\n display: grid;\n min-width: 0;\n gap: 4px;\n}\n\n.settings-session-import-row__copy strong {\n overflow: hidden;\n color: var(--settings-text);\n font-size: 14px;\n text-overflow: ellipsis;\n white-space: nowrap;\n}\n\n.settings-session-import-row__copy span,\n.settings-session-import-row__cwd {\n overflow: hidden;\n color: var(--settings-muted);\n font-size: 12px;\n line-height: 18px;\n text-overflow: ellipsis;\n white-space: nowrap;\n}\n\n.settings-session-import-row__cwd {\n display: block;\n min-width: 0;\n background: transparent;\n}\n\n.settings-session-import-row__action {\n display: flex;\n align-items: flex-end;\n flex-direction: column;\n gap: 8px;\n}\n\n.settings-session-import-running {\n color: var(--settings-muted);\n font-size: 12px;\n}\n\n.settings-preference-row {\n display: flex;\n align-items: center;\n justify-content: space-between;\n gap: 32px;\n min-height: 88px;\n padding: 18px 0;\n border-top: 1px solid var(--settings-divider);\n border-bottom: 1px solid var(--settings-divider);\n}\n\n.settings-preference-row__copy {\n display: flex;\n flex: 1 1 auto;\n flex-direction: column;\n min-width: 0;\n gap: 5px;\n}\n\n.settings-preference-row__copy strong {\n color: var(--settings-text);\n font-size: 15px;\n font-weight: 600;\n line-height: 22px;\n}\n\n.settings-preference-row__copy span {\n max-width: 680px;\n color: var(--settings-muted);\n font-size: 13px;\n line-height: 20px;\n}\n\n.settings-preference-switch {\n display: inline-flex;\n align-items: center;\n width: 42px;\n height: 24px;\n flex: none;\n padding: 2px;\n border: 0;\n border-radius: 999px;\n background: var(--settings-surface-strong);\n cursor: pointer;\n transition: background 120ms ease;\n}\n\n.settings-preference-switch[aria-checked="true"] {\n justify-content: flex-end;\n background: var(--settings-focus);\n}\n\n.settings-preference-switch:focus-visible {\n outline: 2px solid var(--settings-focus);\n outline-offset: 2px;\n}\n\n.settings-preference-switch__thumb {\n width: 20px;\n height: 20px;\n border-radius: 50%;\n background: var(--settings-primary-text);\n box-shadow: 0 1px 3px rgb(0 0 0 / 24%);\n}\n\n.settings-preference-checkbox {\n width: 18px;\n height: 18px;\n flex: none;\n margin: 0;\n accent-color: var(--settings-focus);\n cursor: pointer;\n}\n\n.settings-preference-checkbox:focus-visible {\n outline: 2px solid var(--settings-focus);\n outline-offset: 2px;\n}\n\n.settings-connection-page-header {\n display: flex;\n align-items: flex-start;\n justify-content: space-between;\n gap: 18px;\n margin-bottom: 18px;\n}\n\n.settings-connection-page-header .settings-section-label {\n padding-bottom: 0;\n}\n\n.settings-connection-page-header .settings-page-description {\n margin: 8px 0 0;\n}\n\n.settings-connection-page-header .settings-page-description + .settings-page-description {\n margin-top: 8px;\n}\n\n.settings-update-header {\n margin-bottom: 8px;\n}\n\n.settings-connections-content,\n.settings-plugins-content,\n.settings-connection-list,\n.settings-connection-rows {\n min-width: 0;\n}\n\n.settings-connections-content,\n.settings-plugins-content {\n display: grid;\n gap: 12px;\n}\n\n.settings-connection-list {\n overflow: hidden;\n background: var(--settings-surface);\n border: 1px solid var(--settings-border);\n border-radius: 10px;\n}\n\n.settings-segmented {\n display: inline-flex;\n flex-wrap: wrap;\n align-items: center;\n width: fit-content;\n max-width: 100%;\n padding: 2px;\n gap: 3px;\n background: var(--settings-surface-strong);\n border-radius: 10px;\n}\n\n.settings-segmented__item {\n position: relative;\n display: inline-flex;\n align-items: center;\n justify-content: center;\n min-height: 28px;\n padding: 4px 14px;\n color: var(--settings-muted);\n font: inherit;\n font-size: 12px;\n font-weight: 600;\n line-height: 18px;\n white-space: nowrap;\n background: transparent;\n border: 0;\n border-radius: 8px;\n cursor: pointer;\n transition:\n color 0.15s ease,\n background-color 0.15s ease,\n box-shadow 0.15s ease;\n}\n\n.settings-segmented__item:hover {\n color: var(--settings-text);\n background: var(--settings-hover);\n}\n\n.settings-segmented__item--selected,\n.settings-segmented__item[aria-selected="true"],\n.settings-segmented__item[aria-pressed="true"] {\n color: var(--settings-text);\n background: var(--settings-elevated);\n box-shadow: var(--settings-segmented-shadow);\n}\n\n.settings-segmented__item:disabled {\n opacity: 0.5;\n cursor: not-allowed;\n}\n\n.settings-segmented__item:disabled:hover {\n color: var(--settings-muted);\n background: transparent;\n}\n\n.settings-segmented__item:focus-visible,\n.settings-connection-row:focus-visible,\n.settings-connection-install-link:focus-visible,\n.settings-connection-view-error:focus-visible {\n outline: 2px solid var(--settings-focus);\n outline-offset: 1px;\n}\n\n.settings-connection-host-tabs {\n display: flex;\n align-items: center;\n min-width: 0;\n gap: 6px;\n overflow-x: auto;\n overflow-y: hidden;\n overscroll-behavior-x: contain;\n scrollbar-width: none;\n scroll-behavior: smooth;\n scroll-snap-type: x proximity;\n touch-action: pan-x;\n}\n\n.settings-connection-host-tabs::-webkit-scrollbar {\n display: none;\n}\n\n.settings-connection-host-tab {\n display: inline-flex;\n align-items: center;\n height: 30px;\n min-width: max-content;\n flex: none;\n padding: 0 9px;\n color: var(--settings-muted);\n font: inherit;\n font-size: 12px;\n line-height: 18px;\n white-space: nowrap;\n background: var(--settings-inset);\n border: 1px solid var(--settings-border);\n border-radius: 7px;\n cursor: pointer;\n scroll-snap-align: start;\n}\n\n.settings-connection-host-tab:hover {\n color: var(--settings-text);\n background: var(--settings-hover);\n}\n\n.settings-connection-host-tab[aria-selected="true"] {\n color: var(--settings-text);\n font-weight: 600;\n background: var(--settings-active);\n border-color: var(--settings-border);\n}\n\n.settings-connection-table-header,\n.settings-connection-row {\n display: grid;\n /* Component : Status : Actions = 4 : 3 : 3 */\n grid-template-columns: minmax(0, 4fr) minmax(0, 3fr) minmax(0, 3fr);\n align-items: center;\n min-width: 0;\n column-gap: 16px;\n}\n\n.settings-connection-table-header {\n min-height: 30px;\n padding: 0 10px;\n color: var(--settings-muted);\n font-size: 10px;\n font-weight: 600;\n line-height: 16px;\n text-transform: uppercase;\n letter-spacing: 0.06em;\n background: var(--settings-surface);\n border-bottom: 1px solid var(--settings-divider);\n}\n\n.settings-connection-rows > .settings-connection-row,\n.settings-connection-rows > .settings-connection-block {\n border-bottom: 1px solid var(--settings-divider);\n}\n\n.settings-connection-rows > .settings-connection-row:last-child,\n.settings-connection-rows > .settings-connection-block:last-child {\n border-bottom: 0;\n}\n\n.settings-connection-row {\n min-height: 52px;\n padding: 8px 10px;\n cursor: pointer;\n}\n\n.settings-connection-row:hover {\n background: var(--settings-hover);\n}\n\n.settings-connection-row[data-connection-selected="true"] {\n background: var(--settings-surface);\n}\n\n.settings-connection-row__identity,\n.settings-connection-inspector__identity {\n display: inline-flex;\n align-items: center;\n min-width: 0;\n gap: 8px;\n color: var(--settings-text);\n}\n\n.settings-connection-row__identity strong,\n.settings-connection-inspector__identity strong {\n min-width: 0;\n overflow-wrap: anywhere;\n font-size: 12px;\n font-weight: 500;\n line-height: 18px;\n}\n\n.settings-connection-row__mark {\n display: inline-flex;\n align-items: center;\n justify-content: center;\n width: 24px;\n height: 24px;\n flex: none;\n color: var(--settings-mark);\n font-size: 10px;\n font-weight: 700;\n background: var(--settings-surface-strong);\n border-radius: 7px;\n}\n\n.settings-connection-row__mark--logo {\n color: var(--settings-text);\n background: transparent;\n}\n\n.settings-connection-row__mark--logo > img,\n.settings-connection-row__mark--logo > svg {\n display: block;\n max-width: 18px;\n max-height: 18px;\n}\n\n.settings-connection-table-header > :last-child {\n text-align: end;\n}\n\n.settings-connection-row__status {\n display: inline-flex;\n align-items: center;\n width: fit-content;\n max-width: 100%;\n gap: 6px;\n color: var(--settings-muted);\n font-size: 11px;\n font-weight: 500;\n line-height: 18px;\n}\n\n.settings-connection-row__status::before {\n width: 6px;\n height: 6px;\n flex: none;\n content: "";\n background: currentColor;\n border-radius: 50%;\n}\n\n.settings-connection-row__status[data-connection-tone="ready"] {\n color: var(--settings-success);\n}\n\n.settings-connection-row__status[data-connection-tone="checking"] {\n color: var(--settings-warning);\n}\n\n.settings-connection-row__status[data-connection-tone="setup"] {\n color: var(--settings-muted);\n}\n\n.settings-connection-row__status[data-connection-tone="setup"]::before {\n background: transparent;\n border: 1.5px solid currentColor;\n}\n\n.settings-connection-row__status[data-connection-tone="failed"] {\n color: var(--settings-danger);\n}\n\n.settings-connection-row__action {\n display: flex;\n align-items: center;\n justify-content: flex-end;\n min-width: 0;\n gap: 4px;\n}\n\n.settings-connection-row__handle {\n display: inline-flex;\n flex: none;\n align-items: center;\n justify-content: center;\n width: 16px;\n color: var(--settings-muted);\n cursor: grab;\n opacity: 0.6;\n}\n\n.settings-connection-row__handle:hover {\n opacity: 1;\n}\n\n.settings-connection-row[draggable="true"] {\n cursor: grab;\n}\n\n.settings-connection-row[data-connection-dragging="true"] {\n opacity: 0.4;\n}\n\n.settings-connection-row[data-connection-drop-indicator="before"] {\n box-shadow: inset 0 2px 0 0 var(--settings-focus);\n}\n\n.settings-connection-row[data-connection-drop-indicator="after"] {\n box-shadow: inset 0 -2px 0 0 var(--settings-focus);\n}\n\n.settings-connection-inline-detail {\n display: grid;\n gap: 12px;\n margin-top: 2px;\n padding: 14px 12px 16px;\n border-top: 1px solid var(--settings-divider);\n background: var(--settings-inset);\n}\n\n.settings-connection-group-divider {\n padding: 10px 12px 6px;\n color: var(--settings-muted);\n font-size: 10px;\n font-weight: 600;\n line-height: 16px;\n text-transform: uppercase;\n letter-spacing: 0.06em;\n /* No border-top here: the row immediately above already carries its own\n border-bottom (it is no longer :last-child once this divider follows\n it), so adding one here would double the separator line. */\n}\n\n.settings-connection-group-divider[data-connection-drag-over="true"] {\n color: var(--settings-focus);\n background: rgb(51 156 255 / 8%);\n border-radius: 6px;\n}\n\n.settings-connection-group-more[data-connection-drag-over="true"] {\n background: rgb(51 156 255 / 8%);\n}\n\n.settings-connection-group-hint {\n display: grid;\n gap: 3px;\n margin: 0 12px 12px;\n padding: 14px 16px;\n text-align: center;\n border: 1.5px dashed var(--settings-border);\n border-radius: 10px;\n}\n\n.settings-connection-group-more[data-connection-drag-over="true"] .settings-connection-group-hint {\n border-color: var(--settings-focus);\n}\n\n.settings-connection-group-hint strong {\n color: var(--settings-text);\n font-size: 12.5px;\n font-weight: 500;\n line-height: 18px;\n}\n\n.settings-connection-group-hint span {\n color: var(--settings-muted);\n font-size: 12px;\n line-height: 17px;\n}\n\n.settings-connection-group-reset {\n display: flex;\n width: 100%;\n align-items: center;\n gap: 6px;\n padding: 10px 12px;\n color: var(--settings-muted);\n font: inherit;\n font-size: 12px;\n text-align: left;\n background: transparent;\n border: 0;\n border-top: 1px solid var(--settings-divider);\n cursor: pointer;\n}\n\n.settings-connection-group-reset:hover {\n color: var(--settings-text);\n background: var(--settings-hover);\n}\n\n.settings-connection-install-link {\n display: inline-flex;\n align-items: center;\n justify-content: center;\n width: 26px;\n height: 26px;\n padding: 0;\n color: var(--settings-focus);\n font: inherit;\n text-decoration: none;\n background: transparent;\n border: 1px solid transparent;\n border-radius: 7px;\n cursor: pointer;\n}\n\n.settings-connection-install-link:hover,\n.settings-connection-install-link:focus-visible {\n color: var(--settings-focus);\n background: var(--settings-active);\n border-color: var(--settings-border);\n}\n\n.settings-connection-view-error {\n padding: 4px 7px;\n color: var(--settings-danger);\n font: inherit;\n font-size: 11px;\n line-height: 18px;\n background: transparent;\n border: 0;\n border-radius: 6px;\n cursor: pointer;\n}\n\n.settings-connection-view-error:hover {\n color: var(--settings-danger);\n background: var(--settings-danger-bg);\n}\n\n.settings-connection-inspector {\n position: sticky;\n top: 18px;\n}\n\n.settings-connection-inspector__header {\n display: flex;\n align-items: flex-start;\n justify-content: space-between;\n min-width: 0;\n gap: 10px;\n padding: 12px;\n border-bottom: 1px solid var(--settings-divider);\n}\n\n.settings-connection-inspector__body {\n display: grid;\n min-width: 0;\n gap: 12px;\n padding: 12px;\n}\n\n.settings-connection-install-callout {\n display: grid;\n grid-template-columns: 28px minmax(0, 1fr);\n gap: 9px;\n padding: 11px;\n background: var(--settings-surface);\n border: 0;\n border-radius: 8px;\n}\n\n.settings-connection-install-callout__icon {\n display: inline-flex;\n align-items: center;\n justify-content: center;\n width: 28px;\n height: 28px;\n color: var(--settings-focus);\n background: var(--settings-active);\n border-radius: 7px;\n}\n\n.settings-connection-install-callout strong,\n.settings-connection-error-summary strong,\n.settings-connection-state-summary strong {\n display: block;\n margin: 0 0 4px;\n color: var(--settings-text);\n font-size: 12px;\n font-weight: 500;\n line-height: 18px;\n}\n\n.settings-connection-install-callout p,\n.settings-connection-error-summary p,\n.settings-connection-state-summary p,\n.settings-connection-issue-note {\n margin: 0;\n color: var(--settings-muted);\n font-size: 11px;\n line-height: 16px;\n}\n\n.settings-connection-install-command {\n display: grid;\n gap: 4px;\n margin-top: 8px;\n}\n\n.settings-connection-install-command span {\n color: var(--settings-muted);\n font-size: 10px;\n font-weight: 600;\n line-height: 14px;\n letter-spacing: 0.04em;\n text-transform: uppercase;\n}\n\n.settings-connection-install-command code {\n display: block;\n min-width: 0;\n overflow-wrap: anywhere;\n color: var(--settings-text);\n font-family: ui-monospace, "SFMono-Regular", Consolas, "Liberation Mono", monospace;\n font-size: 11px;\n line-height: 16px;\n white-space: pre-wrap;\n}\n\n.settings-connection-install-actions {\n display: flex;\n flex-wrap: wrap;\n align-items: center;\n gap: 8px;\n}\n\n.settings-connection-copy-prompt {\n position: relative;\n}\n\n.settings-connection-copy-prompt__tooltip {\n position: absolute;\n z-index: 4;\n bottom: calc(100% + 6px);\n left: 0;\n width: max-content;\n max-width: min(360px, 72vw);\n max-height: 180px;\n overflow: auto;\n padding: 8px 10px;\n color: var(--settings-text);\n font-size: 11px;\n line-height: 16px;\n white-space: pre-wrap;\n text-align: left;\n background: var(--settings-elevated);\n border: 1px solid var(--settings-border);\n border-radius: 8px;\n box-shadow: 0 10px 24px rgb(0 0 0 / 22%);\n opacity: 0;\n visibility: hidden;\n pointer-events: none;\n transition: opacity 120ms ease;\n}\n\n.settings-connection-copy-prompt:hover .settings-connection-copy-prompt__tooltip,\n.settings-connection-copy-prompt:focus-within .settings-connection-copy-prompt__tooltip {\n opacity: 1;\n visibility: visible;\n}\n\n.settings-connection-error-summary {\n padding: 13px 14px;\n color: var(--settings-danger);\n background: var(--settings-danger-bg);\n border: 1px solid var(--settings-danger-border);\n border-radius: 10px;\n}\n\n.settings-connection-error-metadata {\n display: grid;\n gap: 7px;\n padding: 12px;\n background: var(--settings-inset);\n border: 1px solid var(--settings-border);\n border-radius: 9px;\n}\n\n.settings-connection-detail-line {\n display: grid;\n grid-template-columns: 92px minmax(0, 1fr);\n gap: 10px;\n min-width: 0;\n color: var(--settings-muted);\n font-size: 10px;\n line-height: 16px;\n}\n\n.settings-connection-detail-line code {\n min-width: 0;\n overflow-wrap: anywhere;\n color: var(--settings-text);\n font-family: ui-monospace, "SFMono-Regular", Consolas, "Liberation Mono", monospace;\n white-space: pre-wrap;\n}\n\n.settings-connection-error-log-header {\n display: flex;\n align-items: center;\n justify-content: space-between;\n gap: 10px;\n}\n\n.settings-connection-error-log-header strong {\n color: var(--settings-text);\n font-size: 11px;\n font-weight: 600;\n}\n\n.settings-connection-error-log-header .settings-command-button {\n min-height: 30px;\n padding: 5px 9px;\n font-size: 11px;\n}\n\n.settings-connection-stderr {\n max-height: 220px;\n min-width: 0;\n margin: 0;\n padding: 11px;\n overflow: auto;\n color: var(--settings-text);\n font:\n 10px/16px ui-monospace,\n "SFMono-Regular",\n Consolas,\n "Liberation Mono",\n monospace;\n white-space: pre-wrap;\n overflow-wrap: anywhere;\n background: var(--settings-inset);\n border: 1px solid var(--settings-border);\n border-radius: 9px;\n}\n\n.settings-connection-error-actions {\n display: grid;\n grid-template-columns: minmax(0, 1fr);\n gap: 8px;\n}\n\n.settings-connection-error-actions .settings-command-button {\n width: 100%;\n}\n\n.settings-connection-issue-note {\n margin-top: -4px;\n}\n\n.settings-connection-state-summary {\n padding: 14px;\n background: var(--settings-surface);\n border: 1px solid var(--settings-border);\n border-radius: 10px;\n}\n\n.settings-empty {\n display: flex;\n align-items: center;\n min-height: 72px;\n padding: 12px 16px;\n}\n\n.settings-empty > div {\n display: grid;\n min-width: 0;\n gap: 2px;\n}\n\n.settings-empty strong {\n color: var(--settings-text);\n font-size: 13px;\n font-weight: 500;\n line-height: 19px;\n}\n\n.settings-empty span {\n color: var(--settings-muted);\n font-size: 13px;\n line-height: 19px;\n}\n\n.settings-about-page {\n display: flex;\n flex-direction: column;\n gap: 18px;\n box-sizing: border-box;\n min-height: min(620px, calc(100vh - 200px));\n max-width: 720px;\n}\n\n.settings-about-page > .settings-section-label {\n padding-bottom: 10px;\n}\n\n.settings-about-panel {\n display: grid;\n gap: 18px;\n padding: 24px;\n background: var(--settings-panel);\n border: 1px solid var(--settings-border);\n border-radius: 12px;\n}\n\n.settings-about-product {\n color: var(--settings-text);\n font-size: 24px;\n font-weight: 700;\n line-height: 32px;\n}\n\n.settings-about-tagline {\n color: var(--settings-text);\n font-size: 16px;\n font-weight: 600;\n line-height: 24px;\n}\n\n.settings-about-copy {\n display: grid;\n max-width: 660px;\n gap: 12px;\n}\n\n.settings-about-lead,\n.settings-about-extension,\n.settings-about-closing p,\n.settings-about-copy p {\n margin: 0;\n color: var(--settings-muted);\n font-size: 13px;\n line-height: 21px;\n}\n\n.settings-about-lead {\n color: var(--settings-text);\n font-weight: 500;\n}\n\n.settings-about-agents {\n display: grid;\n gap: 10px;\n margin: 2px 0;\n padding: 0;\n list-style: none;\n}\n\n.settings-about-agent {\n display: grid;\n gap: 4px;\n padding-left: 2px;\n}\n\n.settings-about-agent-name {\n color: var(--settings-text);\n font-size: 13px;\n font-weight: 600;\n line-height: 18px;\n}\n\n.settings-about-agent-name::before {\n content: "\xB7 ";\n color: var(--settings-muted);\n font-weight: 600;\n}\n\n.settings-about-agent-description {\n display: block;\n padding-left: 0.85em;\n color: var(--settings-muted);\n font-size: 12px;\n font-weight: 400;\n line-height: 18px;\n}\n\n.settings-about-closing {\n display: grid;\n gap: 8px;\n}\n\n.settings-about-repository {\n gap: 10px;\n}\n\n.settings-about-open-source {\n display: flex;\n align-items: center;\n flex-wrap: wrap;\n gap: 0.35em;\n margin: 0;\n color: var(--settings-muted);\n font-size: 13px;\n line-height: 21px;\n}\n\n.settings-about-repository p {\n margin: 0;\n color: var(--settings-muted);\n font-size: 13px;\n line-height: 21px;\n}\n\n.settings-about-star-callout {\n margin: 4px 0 0;\n color: var(--settings-warning);\n font-size: 14px;\n font-weight: 600;\n line-height: 22px;\n}\n\n.settings-about-repository-link {\n display: inline-flex;\n align-items: center;\n gap: 6px;\n color: #7cb8ff;\n font-weight: 600;\n line-height: 1;\n text-decoration: none;\n}\n\n.settings-about-repository-link .codexhost-settings-icon {\n display: block;\n flex: none;\n}\n\n.settings-about-repository-link:hover {\n text-decoration: underline;\n}\n\n.settings-about-brand {\n display: flex;\n align-items: center;\n justify-content: center;\n gap: 12px;\n margin-top: auto;\n padding-top: 12px;\n color: inherit;\n opacity: 0.9;\n text-decoration: none;\n transition: opacity 160ms ease;\n}\n\n.settings-about-brand:hover {\n opacity: 1;\n}\n\n.settings-about-brand-video {\n width: 40px;\n height: 40px;\n flex: none;\n overflow: hidden;\n object-fit: cover;\n border-radius: 999px;\n box-shadow: 0 1px 2px rgb(0 0 0 / 18%);\n}\n\n.settings-about-brand-copy {\n display: flex;\n flex-direction: column;\n align-items: flex-start;\n gap: 2px;\n}\n\n.settings-about-brand-name {\n color: var(--settings-text);\n font-size: 14px;\n font-weight: 800;\n letter-spacing: 0.18em;\n line-height: 18px;\n}\n\n.settings-about-brand-tagline {\n color: var(--settings-muted);\n font-size: 12px;\n font-weight: 500;\n letter-spacing: 0.18em;\n line-height: 16px;\n}\n\n.settings-page-error {\n padding: 16px;\n color: var(--settings-text);\n font-size: 13px;\n background: var(--settings-panel);\n border: 1px solid var(--settings-border);\n border-radius: 20px;\n}\n\n.settings-update-metadata {\n display: grid;\n grid-template-columns: repeat(3, minmax(0, 1fr));\n gap: 24px;\n margin-bottom: 24px;\n padding: 0 0 20px;\n border-bottom: 1px solid var(--settings-divider);\n}\n\n.settings-update-metadata__item {\n display: grid;\n min-width: 0;\n gap: 4px;\n}\n\n.settings-update-metadata__item span {\n color: var(--settings-muted);\n font-size: 12px;\n line-height: 18px;\n}\n\n.settings-update-metadata__item strong {\n min-width: 0;\n overflow-wrap: anywhere;\n color: var(--settings-text);\n font-size: 15px;\n font-weight: 500;\n line-height: 22px;\n}\n\n/* The only emphasis on this screen: a latest version newer than the installed one. */\n.settings-update-metadata__value--newer {\n color: var(--settings-focus);\n}\n\n.settings-update-panel {\n display: grid;\n gap: 12px;\n padding: 20px;\n color: var(--settings-text);\n background: var(--settings-panel);\n border: 1px solid var(--settings-border);\n border-radius: 8px;\n}\n\n/* Soft status copy and the Update action should not sit in a framed card. */\n.settings-update-panel[data-update-state="unavailable"],\n.settings-update-panel[data-update-state="failed"],\n.settings-update-panel[data-update-state="error"],\n.settings-update-panel[data-update-state="available"] {\n padding: 4px 0 0;\n border: 0;\n border-radius: 0;\n}\n\n.settings-update-panel__status-row {\n display: flex;\n align-items: center;\n flex-wrap: wrap;\n gap: 8px;\n min-width: 0;\n}\n\n.settings-update-panel__status-row .settings-update-actions {\n flex: none;\n}\n\n.settings-update-panel__status-row .settings-update-panel__head {\n flex: 1 1 auto;\n min-width: 0;\n}\n\n.settings-update-panel__head {\n display: flex;\n align-items: center;\n min-width: 0;\n gap: 8px;\n}\n\n.settings-update-panel__head .codexhost-settings-icon {\n color: var(--settings-muted);\n}\n\n.settings-update-panel[data-update-state="available"]\n .settings-update-panel__head\n .codexhost-settings-icon,\n.settings-update-panel[data-update-state="downloading"]\n .settings-update-panel__head\n .codexhost-settings-icon,\n.settings-update-panel[data-update-state="installing"]\n .settings-update-panel__head\n .codexhost-settings-icon,\n.settings-update-panel[data-update-state="restarting"]\n .settings-update-panel__head\n .codexhost-settings-icon {\n color: var(--settings-focus);\n}\n\n.settings-update-panel[data-update-state="current"]\n .settings-update-panel__head\n .codexhost-settings-icon {\n color: var(--settings-success);\n}\n\n.settings-update-panel[data-update-state="failed"]\n .settings-update-panel__head\n .codexhost-settings-icon,\n.settings-update-panel[data-update-state="error"]\n .settings-update-panel__head\n .codexhost-settings-icon {\n color: var(--settings-danger);\n}\n\n.settings-update-panel[data-update-state="unavailable"]\n .settings-update-panel__head\n .codexhost-settings-icon {\n color: var(--settings-muted);\n}\n\n.settings-update-panel__title {\n min-width: 0;\n overflow-wrap: anywhere;\n color: var(--settings-text);\n font-size: 14px;\n font-weight: 600;\n line-height: 22px;\n}\n\n.settings-update-summary,\n.settings-update-error {\n margin: 0;\n overflow-wrap: anywhere;\n font-size: 13px;\n line-height: 20px;\n}\n\n.settings-update-summary {\n color: var(--settings-muted);\n}\n\n.settings-update-error {\n color: var(--settings-danger);\n}\n\n.settings-update-progress {\n width: 100%;\n height: 8px;\n accent-color: var(--settings-focus);\n}\n\n.settings-update-progress-detail {\n color: var(--settings-muted);\n font-size: 12px;\n line-height: 18px;\n}\n\n/* Release notes scroll with the page; a scroller inside a scroller traps the wheel. */\n.settings-update-notes-section {\n min-width: 0;\n margin-top: 24px;\n padding-top: 24px;\n border-top: 1px solid var(--settings-divider);\n}\n\n.settings-update-notes-section:empty {\n display: none;\n}\n\n.settings-update-notes {\n display: grid;\n min-width: 0;\n gap: 12px;\n color: var(--settings-muted);\n font-size: 14px;\n line-height: 22px;\n overflow-wrap: anywhere;\n}\n\n.settings-update-notes > :first-child {\n margin-top: 0;\n}\n\n.settings-update-notes > :last-child {\n margin-bottom: 0;\n}\n\n.settings-update-notes h1,\n.settings-update-notes h2,\n.settings-update-notes h3,\n.settings-update-notes h4,\n.settings-update-notes h5,\n.settings-update-notes h6 {\n margin: 6px 0 0;\n color: var(--settings-text);\n font-weight: 600;\n}\n\n.settings-update-notes h1 {\n font-size: 18px;\n line-height: 26px;\n}\n\n.settings-update-notes h2 {\n font-size: 17px;\n line-height: 24px;\n}\n\n.settings-update-notes h3,\n.settings-update-notes h4,\n.settings-update-notes h5,\n.settings-update-notes h6 {\n font-size: 14px;\n line-height: 22px;\n}\n\n.settings-update-notes p,\n.settings-update-notes ul,\n.settings-update-notes ol,\n.settings-update-notes pre,\n.settings-update-notes blockquote {\n margin: 0;\n}\n\n.settings-update-notes ul,\n.settings-update-notes ol {\n padding-left: 24px;\n}\n\n.settings-update-notes li {\n padding-left: 4px;\n}\n\n.settings-update-notes li::marker {\n color: var(--settings-muted);\n font-size: 0.85em;\n}\n\n.settings-update-notes li + li {\n margin-top: 14px;\n}\n\n.settings-update-notes .release-note-translation {\n display: block;\n margin-top: 3px;\n color: var(--settings-muted);\n font-size: 13px;\n line-height: 20px;\n}\n\n.settings-update-notes blockquote {\n padding: 8px 12px;\n color: var(--settings-muted);\n border-left: 3px solid var(--settings-focus);\n background: var(--settings-surface);\n}\n\n.settings-update-notes hr {\n width: 100%;\n margin: 2px 0;\n border: 0;\n border-top: 1px solid var(--settings-divider);\n}\n\n.settings-update-notes strong {\n color: var(--settings-text);\n font-weight: 600;\n}\n\n.settings-update-notes a {\n color: var(--settings-focus);\n text-decoration: none;\n}\n\n.settings-update-notes a:hover {\n text-decoration: underline;\n}\n\n.settings-update-notes code {\n font-family: ui-monospace, "SFMono-Regular", Consolas, "Liberation Mono", monospace;\n font-size: 12px;\n}\n\n.settings-update-notes :not(pre) > code {\n padding: 1px 5px;\n background: var(--settings-surface-strong);\n border-radius: 4px;\n}\n\n.settings-update-notes pre {\n min-width: 0;\n max-width: 100%;\n padding: 10px 12px;\n overflow-x: auto;\n overflow-y: hidden;\n background: var(--settings-inset);\n border-radius: 6px;\n}\n\n.settings-update-notes pre code {\n line-height: 18px;\n white-space: pre-wrap;\n}\n\n/* Manual update sits directly under the status panel, not behind a disclosure:\n automatic updates can fail for machine-local reasons and this is the way out. */\n.settings-update-controls {\n display: grid;\n min-width: 0;\n gap: 10px;\n margin-top: 24px;\n}\n\n.settings-update-manual-title {\n color: var(--settings-text);\n font-size: 15px;\n font-weight: 600;\n line-height: 22px;\n}\n\n.settings-update-manual {\n display: grid;\n min-width: 0;\n gap: 8px;\n}\n\n.settings-update-manual[hidden] {\n display: none;\n}\n\n.settings-update-manual-description {\n margin: 0;\n color: var(--settings-muted);\n font-size: 12px;\n line-height: 18px;\n}\n\n.settings-update-manual-description.is-fallback {\n color: var(--settings-danger);\n}\n\n.settings-update-command {\n display: flex;\n align-items: stretch;\n min-width: 0;\n overflow: hidden;\n border: 1px solid var(--settings-border);\n border-radius: 6px;\n}\n\n.settings-update-command code {\n min-width: 0;\n flex: 1;\n padding: 9px 12px;\n overflow-x: auto;\n color: var(--settings-text);\n font-family: ui-monospace, "SFMono-Regular", Consolas, "Liberation Mono", monospace;\n font-size: 12px;\n line-height: 20px;\n white-space: nowrap;\n}\n\n.settings-update-command__copy {\n display: inline-flex;\n align-items: center;\n flex: none;\n gap: 6px;\n padding: 0 12px;\n color: var(--settings-muted);\n font-size: 12px;\n background: transparent;\n border: 0;\n border-left: 1px solid var(--settings-border);\n cursor: pointer;\n}\n\n.settings-update-command__copy:hover {\n color: var(--settings-text);\n background: var(--settings-hover);\n}\n\n.settings-update-command__copy:focus-visible {\n outline: 2px solid var(--settings-focus);\n outline-offset: -2px;\n}\n\n.settings-update-actions {\n display: flex;\n align-items: center;\n min-width: 0;\n gap: 12px;\n flex-wrap: wrap;\n}\n\n.settings-command-button,\n.settings-update-link {\n display: inline-flex;\n align-items: center;\n justify-content: center;\n flex: none;\n width: max-content;\n max-width: 100%;\n min-height: 30px;\n gap: 6px;\n padding: 5px 10px;\n white-space: nowrap;\n color: var(--settings-primary-text);\n font: inherit;\n font-size: 12px;\n text-decoration: none;\n background: var(--settings-primary);\n border: 1px solid var(--settings-primary);\n border-radius: 7px;\n cursor: pointer;\n}\n\n.settings-command-button--secondary,\n.settings-update-link {\n color: var(--settings-muted);\n background: transparent;\n border-color: var(--settings-border);\n}\n\n.settings-command-button--secondary .codexhost-settings-icon,\n.settings-update-link .codexhost-settings-icon {\n color: var(--settings-muted);\n}\n\n.settings-command-button:hover:not(.settings-command-button--secondary) {\n filter: brightness(1.08);\n}\n\n.settings-command-button--danger {\n color: var(--settings-danger);\n}\n\n.settings-command-button--danger:hover:not(:disabled) {\n color: #fecaca;\n background: var(--settings-danger-bg);\n border-color: var(--settings-danger-border);\n}\n\n.settings-command-button--secondary:hover,\n.settings-update-link:hover {\n color: var(--settings-text);\n background: var(--settings-hover);\n}\n\n.settings-command-button--secondary:hover .codexhost-settings-icon,\n.settings-update-link:hover .codexhost-settings-icon {\n color: var(--settings-text);\n}\n\n.settings-command-button:disabled,\n.settings-command-button[aria-disabled="true"] {\n opacity: 0.55;\n cursor: not-allowed;\n filter: none;\n}\n\n.settings-command-button:focus-visible,\n.settings-update-link:focus-visible {\n outline: 2px solid var(--settings-focus);\n outline-offset: 2px;\n}\n\n.settings-visually-hidden {\n position: absolute;\n width: 1px;\n height: 1px;\n padding: 0;\n margin: -1px;\n overflow: hidden;\n clip: rect(0, 0, 0, 0);\n white-space: nowrap;\n border: 0;\n}\n\n.settings-session-import-content {\n display: grid;\n min-width: 0;\n gap: 12px;\n margin-top: 16px;\n}\n\n.settings-session-import-list {\n display: grid;\n min-width: 0;\n overflow: hidden;\n background: var(--settings-surface);\n border: 1px solid var(--settings-border);\n border-radius: 12px;\n}\n\n.settings-session-import-row {\n display: grid;\n grid-template-columns: minmax(0, 1fr) auto;\n align-items: center;\n min-width: 0;\n gap: 16px;\n padding: 14px 16px;\n border-bottom: 1px solid var(--settings-divider);\n}\n\n.settings-session-import-row:last-child {\n border-bottom: 0;\n}\n\n.settings-session-import-row__copy {\n display: grid;\n min-width: 0;\n gap: 4px;\n}\n\n.settings-session-import-row__copy strong {\n color: var(--settings-text);\n font-size: 14px;\n font-weight: 600;\n line-height: 20px;\n}\n\n.settings-session-import-row__copy span,\n.settings-session-import-row__cwd {\n min-width: 0;\n overflow-wrap: anywhere;\n color: var(--settings-muted);\n font-size: 12px;\n line-height: 18px;\n}\n\n.settings-session-import-row__cwd {\n font-family: ui-monospace, "SFMono-Regular", Consolas, "Liberation Mono", monospace;\n}\n\n.settings-session-import-row__action {\n display: flex;\n align-items: center;\n flex: none;\n gap: 8px;\n}\n\n.settings-session-import-running {\n color: #f5c542;\n font-size: 12px;\n font-weight: 500;\n line-height: 18px;\n white-space: nowrap;\n}\n\n.settings-session-import-recovery {\n display: grid;\n min-width: 0;\n gap: 12px;\n padding: 16px;\n background: var(--settings-surface);\n border: 1px solid var(--settings-border);\n border-radius: 12px;\n}\n\n.settings-session-import-recovery__copy {\n display: grid;\n gap: 6px;\n}\n\n.settings-session-import-recovery__copy strong {\n color: var(--settings-text);\n font-size: 15px;\n font-weight: 600;\n line-height: 22px;\n}\n\n.settings-session-import-recovery__copy p {\n margin: 0;\n color: var(--settings-muted);\n font-size: 13px;\n line-height: 20px;\n}\n\n.settings-session-import-recovery__path {\n display: flex;\n align-items: center;\n min-width: 0;\n gap: 8px;\n}\n\n.settings-session-import-recovery__path code {\n min-width: 0;\n flex: 1;\n overflow-wrap: anywhere;\n color: var(--settings-text);\n font-family: ui-monospace, "SFMono-Regular", Consolas, "Liberation Mono", monospace;\n font-size: 12px;\n line-height: 18px;\n}\n\n.codexhost-settings-icon {\n display: block;\n flex: none;\n stroke: currentColor;\n}\n\n@media (max-width: 720px) {\n .codexhost-settings-dialog {\n border-radius: 10px;\n }\n\n .settings-layout {\n grid-template-columns: minmax(0, 1fr);\n grid-template-rows: auto minmax(0, 1fr);\n }\n\n .settings-sidebar {\n border-right: 0;\n border-bottom: 1px solid var(--settings-border);\n }\n\n .settings-header {\n height: 56px;\n padding-inline: 14px;\n }\n\n .settings-sidebar {\n padding-top: 20px;\n }\n\n .settings-nav {\n flex: none;\n flex-direction: row;\n gap: 4px;\n padding: 7px 8px 8px;\n overflow-x: auto;\n overflow-y: hidden;\n }\n\n .settings-nav-section-label {\n display: none;\n }\n\n .settings-nav-button {\n width: auto;\n min-width: max-content;\n min-height: 34px;\n grid-template-columns: 16px auto;\n border-radius: 10px;\n }\n\n .settings-page__content {\n width: calc(100% - 40px);\n }\n\n .settings-page__content {\n padding-top: 32px;\n padding-bottom: 32px;\n }\n\n .settings-section-label {\n padding-bottom: 20px;\n font-size: 20px;\n line-height: 26px;\n }\n\n .settings-update-metadata {\n grid-template-columns: minmax(0, 1fr);\n gap: 16px;\n }\n\n .settings-status-row {\n grid-template-columns: minmax(0, 1fr) auto;\n gap: 16px;\n }\n\n .settings-connection-page-header {\n flex-direction: column;\n }\n\n .settings-connection-page-header > .settings-command-button {\n width: 100%;\n }\n\n .settings-session-import-row {\n grid-template-columns: minmax(0, 1fr);\n }\n\n .settings-session-import-row__action {\n justify-content: flex-start;\n flex-wrap: wrap;\n }\n\n .settings-status-row__detail {\n grid-column: 1 / -1;\n margin: -8px 0 0 58px;\n }\n}\n\n@media (forced-colors: active) {\n :host,\n :host([data-theme="light"]),\n :host([data-theme="dark"]) {\n --settings-bg: Canvas;\n --settings-sidebar: Canvas;\n --settings-panel: Canvas;\n --settings-surface: Canvas;\n --settings-surface-hover: Highlight;\n --settings-inset: Canvas;\n --settings-text: CanvasText;\n --settings-muted: GrayText;\n --settings-subtle: GrayText;\n --settings-border: ButtonBorder;\n --settings-divider: ButtonBorder;\n --settings-hover: Highlight;\n --settings-active: Highlight;\n --settings-focus: Highlight;\n --settings-elevated: Canvas;\n --settings-surface-strong: Canvas;\n --settings-mark: CanvasText;\n --settings-primary: ButtonFace;\n --settings-primary-hover: Highlight;\n --settings-primary-text: ButtonText;\n --settings-warning: CanvasText;\n --settings-warning-bg: Canvas;\n --settings-warning-border: ButtonBorder;\n --settings-danger: CanvasText;\n --settings-danger-bg: Canvas;\n --settings-danger-border: ButtonBorder;\n --settings-success: CanvasText;\n }\n}\n\n@media (prefers-reduced-motion: reduce) {\n *,\n *::before,\n *::after {\n scroll-behavior: auto !important;\n transition-duration: 0s !important;\n }\n}\n';
|
|
27347
27086
|
|
|
27348
27087
|
// src/settings/accounts.css
|
|
27349
|
-
var accounts_default = '.settings-harness-account__logo {\n display: grid;\n place-items: center;\n width: 34px;\n height: 34px;\n}\n\n.settings-account-header {\n display: flex;\n align-items: flex-start;\n justify-content: space-between;\n gap: 20px;\n}\n\n.settings-account-header > :first-child {\n min-width: 0;\n flex: 1 1 auto;\n}\n\n.settings-account-header > .settings-command-button {\n flex: none;\n white-space: nowrap;\n margin-top: 0;\n min-height: 36px;\n padding: 8px 12px;\n border-radius: 7px;\n}\n\n.settings-account-header .settings-section-label {\n margin: 0;\n padding: 0;\n font-size: 27px;\n line-height: 1.4;\n font-weight: 650;\n letter-spacing: -0.035em;\n}\n.settings-account-header .settings-page-description {\n margin: 8px 0 0;\n font-size: 13px;\n}\n\n.settings-account-status {\n margin: 0;\n color: var(--settings-muted);\n font-size: 12px;\n}\n.settings-account-status:empty {\n display: none;\n}\n\n.settings-account-toolbar {\n margin-top: 27px;\n padding: 18px 0;\n border-top: 1px solid var(--settings-border);\n display: flex;\n align-items: center;\n gap: 14px;\n flex-wrap: wrap;\n}\n.settings-account-count {\n display: flex;\n align-items: center;\n gap: 8px;\n font-size: 13px;\n white-space: nowrap;\n}\n.settings-account-count > :last-child {\n color: var(--settings-muted);\n font-variant-numeric: tabular-nums;\n}\n.settings-account-search {\n display: flex;\n align-items: center;\n gap: 8px;\n color: var(--settings-muted);\n margin-right: auto;\n min-width: 0;\n max-width: 100%;\n}\n.settings-account-search svg {\n flex: none;\n}\n.settings-account-toolbar input {\n min-width: 80px;\n width: 210px;\n max-width: 100%;\n padding: 5px 0;\n color: var(--settings-text);\n background: transparent;\n border: 0;\n font-size: 13px;\n}\n.settings-account-toolbar input::placeholder {\n color: var(--settings-muted);\n}\n.settings-account-display-controls {\n display: flex;\n padding: 3px;\n border: 1px solid var(--settings-border);\n border-radius: 7px;\n background: var(--settings-inset);\n}\n.settings-account-display-controls button {\n padding: 4px 10px;\n color: var(--settings-muted);\n background: transparent;\n border: 0;\n border-radius: 4px;\n font-size: 12px;\n cursor: pointer;\n}\n.settings-account-display-controls button:hover {\n color: var(--settings-text);\n}\n.settings-account-display-controls button[aria-pressed="true"] {\n color: var(--settings-text);\n background: var(--settings-active);\n}\n\n.settings-account-groups {\n display: grid;\n gap: 22px;\n}\n.settings-account-group__title {\n margin: 0 0 8px;\n color: var(--settings-text);\n font-size: 13px;\n font-weight: 600;\n letter-spacing: -0.01em;\n}\n.settings-account-list {\n --account-border: light-dark(#e2e2e8, #36363b);\n --account-muted: light-dark(#676773, #a5a5af);\n border: 1px solid var(--account-border);\n border-radius: 11px;\n overflow: hidden;\n container-type: inline-size;\n}\n.settings-account-list > .settings-account-empty {\n margin: 0;\n padding: 28px 16px;\n}\n.settings-account-table {\n width: 100%;\n table-layout: fixed;\n border-collapse: collapse;\n font-size: 12px;\n}\n.settings-account-table th {\n padding: 12px 16px;\n color: var(--account-muted);\n background: light-dark(#f8f8fa, #202024);\n font-size: 11px;\n font-weight: 500;\n text-align: left;\n}\n.settings-account-table th:nth-child(1) {\n width: 32%;\n}\n.settings-account-table th:nth-child(2),\n.settings-account-table th:nth-child(3) {\n width: 24%;\n}\n.settings-account-table th:nth-child(4) {\n width: 20%;\n text-align: right;\n}\n.settings-account-table--api th:nth-child(1) {\n width: 48%;\n}\n.settings-account-table--api th:nth-child(2) {\n width: 32%;\n}\n.settings-account-table--api th:nth-child(3) {\n width: 20%;\n text-align: right;\n}\n.settings-account-table td {\n padding: 17px 16px;\n vertical-align: middle;\n border-top: 1px solid var(--settings-divider);\n}\n.settings-account-row {\n background: light-dark(#ffffff, #232326);\n}\n.settings-account-row:hover {\n background: light-dark(#f7f7fa, #26262a);\n}\n.settings-account-row__person {\n display: grid;\n grid-template-columns: 34px minmax(0, 1fr);\n align-items: center;\n gap: 11px;\n min-width: 0;\n}\n.settings-account-row__mark {\n display: grid;\n place-items: center;\n width: 34px;\n height: 34px;\n color: light-dark(#67558d, #c3baff);\n background: light-dark(#f0ecf7, #353044);\n border: 1px solid light-dark(#d9d0e6, #4d435f);\n border-radius: 10px;\n}\n.settings-account-row__identity {\n min-width: 0;\n}\n.settings-account-email {\n display: block;\n min-width: 0;\n overflow: hidden;\n font-size: 12px;\n font-weight: 550;\n text-overflow: ellipsis;\n white-space: nowrap;\n}\n.settings-account-metadata {\n display: flex;\n align-items: center;\n min-width: 0;\n gap: 5px;\n margin-top: 4px;\n color: var(--settings-muted);\n flex-wrap: wrap;\n font-size: 11px;\n overflow-wrap: anywhere;\n}\n.settings-account-plan {\n flex: none;\n padding: 0 4px;\n color: var(--settings-muted);\n border: 1px solid var(--settings-border);\n border-radius: 5px;\n font-size: 10px;\n max-width: 100%;\n overflow-wrap: anywhere;\n}\n.settings-account-plan--highlighted {\n color: light-dark(#654f91, #c8bfff);\n background: light-dark(#f2edf9, #a99bff18);\n border-color: light-dark(#d9ccea, #a99bff52);\n font-weight: 600;\n}\n.settings-account-active {\n flex: none;\n color: light-dark(#66548e, #c8bfff);\n font-size: 10px;\n white-space: nowrap;\n}\n\n.settings-account-usage {\n display: grid;\n gap: 10px;\n}\n.settings-account-usage__meter {\n display: grid;\n grid-template-columns: minmax(0, 1fr) auto;\n grid-template-rows: 20px 4px 17px;\n align-items: center;\n gap: 6px 0;\n min-width: 0;\n font-variant-numeric: tabular-nums;\n}\n:host([lang="zh-CN"]) .settings-account-usage__meter {\n grid-template-columns: 48px minmax(36px, 1fr) 72px;\n}\n.settings-account-usage__meter--balance {\n display: flex;\n grid-template-columns: none;\n justify-content: flex-start;\n gap: 6px;\n}\n.settings-account-usage__balance {\n display: inline-flex;\n align-items: baseline;\n gap: 4px;\n font-size: 14px;\n font-weight: 600;\n font-variant-numeric: tabular-nums;\n white-space: nowrap;\n}\n\n.settings-account-usage__title {\n display: none;\n min-width: 0;\n color: var(--settings-muted);\n font-size: 11px;\n overflow: hidden;\n text-overflow: ellipsis;\n white-space: nowrap;\n}\n.settings-account-extra-usage {\n display: grid;\n gap: 12px;\n margin-top: 14px;\n}\n.settings-account-extra-usage .settings-account-usage__meter {\n grid-template-rows: auto 20px 4px 17px;\n}\n.settings-account-extra-usage .settings-account-usage__title {\n display: block;\n grid-column: 1 / -1;\n white-space: normal;\n overflow-wrap: anywhere;\n}\n.settings-account-usage__percent {\n grid-column: 1 / -1;\n min-width: 0;\n display: flex;\n align-items: baseline;\n justify-content: flex-end;\n gap: 7px;\n font-size: 14px;\n font-weight: 600;\n font-variant-numeric: tabular-nums;\n white-space: nowrap;\n}\n.settings-account-usage__countdown {\n min-width: 0;\n color: var(--settings-muted);\n font-size: 10px;\n font-weight: 400;\n overflow: hidden;\n text-overflow: ellipsis;\n}\n.settings-account-usage__percent > :last-child {\n flex: none;\n}\n.settings-account-usage__percent--warn {\n color: var(--settings-warning);\n}\n.settings-account-usage__percent--hot {\n color: var(--settings-danger);\n}\n.settings-account-usage__bar {\n grid-column: 1 / -1;\n height: 4px;\n overflow: hidden;\n background: light-dark(#e3e1e8, #3c3c43);\n border-radius: 4px;\n}\n.settings-account-usage__bar > span {\n display: block;\n height: 100%;\n background: light-dark(#81769e, #9993b8);\n border-radius: inherit;\n}\n.settings-account-usage__bar--warn > span {\n background: var(--settings-warning);\n}\n.settings-account-usage__bar--hot > span {\n background: var(--settings-danger);\n}\n.settings-account-usage__sub {\n grid-column: 1 / -1;\n color: var(--account-muted);\n font-size: 10px;\n font-variant-numeric: tabular-nums;\n text-align: right;\n white-space: nowrap;\n}\n.settings-account-usage__message {\n color: var(--settings-muted);\n}\n.settings-account-usage__missing {\n display: grid;\n grid-template-columns: minmax(0, 1fr) auto;\n align-content: center;\n gap: 6px;\n min-height: 53px;\n color: var(--settings-muted);\n}\n.settings-account-usage__missing > span:not(.settings-account-usage__title) {\n grid-column: 1 / -1;\n font-size: 14px;\n}\n.settings-account-management {\n display: flex;\n flex-direction: column;\n align-items: flex-end;\n gap: 4px;\n}\n.settings-account-native {\n display: flex;\n align-items: center;\n justify-content: flex-end;\n gap: 3px;\n color: var(--settings-muted);\n font-size: 11px;\n}\n.settings-account-native .settings-icon-button {\n width: 25px;\n height: 28px;\n}\n.settings-account-usage > button {\n justify-self: start;\n}\n.settings-account-actions {\n display: flex;\n justify-content: flex-end;\n align-items: center;\n gap: 4px;\n flex-wrap: wrap;\n}\n.settings-account-action {\n padding: 4px 5px;\n min-height: 30px;\n font-size: 12px;\n color: var(--settings-text);\n background: transparent;\n border: 1px solid transparent;\n border-radius: 7px;\n white-space: nowrap;\n cursor: pointer;\n}\n.settings-account-action:hover {\n background: var(--settings-hover);\n}\n.settings-account-action:disabled {\n opacity: 0.45;\n cursor: not-allowed;\n}\n.settings-account-delete {\n color: var(--settings-danger);\n}\n.settings-account-delete:hover,\n.settings-account-delete:focus-visible {\n color: var(--settings-danger);\n background: var(--settings-danger-bg);\n}\n.settings-account-reset-summary {\n display: inline-flex;\n align-items: center;\n gap: 5px;\n min-height: 24px;\n padding: 3px 0;\n font-size: 10px;\n white-space: nowrap;\n color: var(--settings-muted);\n background: transparent;\n border: 0;\n border-radius: 5px;\n cursor: pointer;\n}\n.settings-account-reset-summary:hover {\n background: var(--settings-hover);\n}\n.settings-account-reset-summary[aria-expanded="true"] > svg:last-child {\n transform: rotate(90deg);\n}\n.settings-account-details-row > td {\n background: var(--settings-inset);\n}\n.settings-account-reset-details {\n display: flex;\n align-items: flex-start;\n justify-content: space-between;\n gap: 16px;\n flex-wrap: wrap;\n}\n.settings-account-reset-details strong {\n font-size: 12px;\n}\n.settings-account-reset-expiry {\n margin: 6px 0;\n color: var(--settings-muted);\n font-size: 11px;\n}\n.settings-account-reset-expiry.is-warn {\n color: var(--settings-warning);\n}\n.settings-account-reset-expiry.is-hot {\n color: var(--settings-danger);\n}\n.settings-account-reset-list {\n margin: 8px 0 0;\n padding: 0;\n list-style: none;\n color: var(--settings-muted);\n font-size: 11px;\n}\n.settings-account-reset-list li + li {\n margin-top: 4px;\n}\n.settings-account-empty {\n text-align: center;\n color: var(--settings-muted);\n}\n.settings-account-verification {\n display: flex;\n align-items: center;\n gap: 8px;\n flex-wrap: wrap;\n color: var(--settings-muted);\n}\n.settings-account-verification a {\n color: var(--settings-focus);\n overflow-wrap: anywhere;\n}\n.settings-account-verification code {\n padding: 5px 8px;\n color: var(--settings-text);\n font-size: 15px;\n font-weight: 600;\n letter-spacing: 0.08em;\n background: var(--settings-inset);\n border-radius: 6px;\n}\n.settings-account-list :focus-visible,\n.settings-account-toolbar :focus-visible {\n outline: 2px solid var(--settings-focus);\n outline-offset: -2px;\n}\n\n.settings-account-dialog {\n position: fixed;\n width: min(360px, calc(100vw - 40px));\n max-height: calc(100vh - 40px);\n overflow: auto;\n padding: 22px;\n color: var(--settings-text);\n background: var(--settings-elevated);\n border: 1px solid var(--settings-border);\n border-radius: 12px;\n box-shadow: var(--settings-dialog-shadow);\n text-align: left;\n}\n.settings-account-dialog::backdrop {\n background: var(--settings-backdrop);\n}\n.settings-account-dialog h2 {\n margin: 0 28px 12px 0;\n font-size: 15px;\n}\n.settings-account-dialog p {\n color: var(--settings-muted);\n font-size: 12px;\n line-height: 1.6;\n overflow-wrap: anywhere;\n}\n.settings-account-dialog__close {\n position: absolute;\n top: 12px;\n right: 12px;\n}\n.settings-account-dialog__actions {\n display: flex;\n justify-content: flex-end;\n gap: 8px;\n flex-wrap: wrap;\n}\n\n@container (max-width: 680px) {\n .settings-account-table,\n .settings-account-table tbody {\n display: block;\n }\n .settings-account-table thead {\n display: none;\n }\n .settings-account-row {\n display: grid;\n grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);\n padding: 18px;\n gap: 18px 22px;\n border-top: 1px solid var(--settings-divider);\n }\n .settings-account-row:first-child {\n border-top: 0;\n }\n .settings-account-table .settings-account-row > td {\n display: block;\n min-width: 0;\n padding: 0;\n border: 0;\n }\n .settings-account-person-cell,\n .settings-account-management-cell,\n .settings-account-usage-cell--message,\n .settings-account-table--api .settings-account-usage-cell {\n grid-column: 1 / -1;\n }\n .settings-account-table .settings-account-management-cell {\n border-top: 1px solid var(--settings-divider);\n padding-top: 8px;\n }\n .settings-account-email {\n font-size: 13px;\n }\n .settings-account-usage__title {\n display: block;\n grid-column: 1;\n }\n .settings-account-usage__percent,\n .settings-account-usage__missing > span:not(.settings-account-usage__title) {\n grid-column: 2;\n text-align: right;\n }\n .settings-account-extra-usage .settings-account-usage__percent {\n grid-column: 1 / -1;\n }\n .settings-account-management {\n flex-direction: row;\n justify-content: space-between;\n }\n .settings-account-actions {\n order: 1;\n margin-left: auto;\n }\n .settings-account-native {\n justify-content: flex-start;\n }\n .settings-account-table tr:not(.settings-account-row, [hidden]),\n .settings-account-table tr:not(.settings-account-row, [hidden]) > td {\n display: block;\n }\n}\n\n@container (max-width: 360px) {\n .settings-account-row {\n grid-template-columns: minmax(0, 1fr);\n gap: 16px;\n padding: 16px;\n }\n}\n\n@media (forced-colors: active) {\n .settings-account-usage__bar {\n border: 1px solid CanvasText;\n }\n .settings-account-usage__bar > span {\n background: Highlight;\n }\n}\n';
|
|
27088
|
+
var accounts_default = '.settings-harness-account__logo {\n display: grid;\n place-items: center;\n width: 34px;\n height: 34px;\n}\n\n.settings-account-status {\n margin: 0 0 12px;\n color: var(--settings-muted);\n font-size: 12px;\n line-height: 18px;\n}\n.settings-account-status:empty {\n display: none;\n}\n\n.settings-account-toolbar {\n display: flex;\n align-items: center;\n gap: 10px;\n flex-wrap: wrap;\n margin: 0 0 16px;\n}\n.settings-account-count {\n display: flex;\n align-items: center;\n gap: 6px;\n color: var(--settings-muted);\n font-size: 12px;\n line-height: 18px;\n white-space: nowrap;\n}\n.settings-account-count > :last-child {\n color: var(--settings-text);\n font-variant-numeric: tabular-nums;\n font-weight: 600;\n}\n.settings-account-search {\n display: flex;\n align-items: center;\n gap: 8px;\n box-sizing: border-box;\n height: 36px;\n min-width: 180px;\n max-width: 100%;\n margin-right: auto;\n padding: 0 10px;\n color: var(--settings-muted);\n background: var(--settings-bg);\n border: 1px solid var(--settings-border);\n border-radius: 6px;\n}\n.settings-account-search svg {\n flex: none;\n}\n.settings-account-search input {\n flex: 1;\n min-width: 0;\n width: 210px;\n padding: 0;\n color: var(--settings-text);\n background: transparent;\n border: 0;\n font-size: 13px;\n}\n.settings-account-search input::placeholder {\n color: var(--settings-muted);\n}\n.settings-account-search:focus-within {\n outline: 2px solid var(--settings-focus);\n outline-offset: 2px;\n}\n\n.settings-account-groups {\n display: grid;\n gap: 18px;\n}\n.settings-account-group__title {\n margin: 0 0 8px;\n color: var(--settings-text);\n font-size: 13px;\n font-weight: 600;\n letter-spacing: -0.01em;\n}\n.settings-account-list {\n overflow: hidden;\n background: var(--settings-surface);\n border: 1px solid var(--settings-border);\n border-radius: 10px;\n container-type: inline-size;\n}\n.settings-account-list > .settings-account-empty {\n margin: 0;\n padding: 28px 16px;\n}\n.settings-account-table {\n width: 100%;\n table-layout: fixed;\n border-collapse: collapse;\n font-size: 12px;\n}\n.settings-account-table th {\n padding: 10px 16px;\n color: var(--settings-muted);\n background: var(--settings-surface);\n font-size: 10px;\n font-weight: 600;\n line-height: 16px;\n text-align: left;\n}\n.settings-account-table th:nth-child(1) {\n width: 32%;\n}\n.settings-account-table th:nth-child(2),\n.settings-account-table th:nth-child(3) {\n width: 24%;\n}\n.settings-account-table th:nth-child(4) {\n width: 20%;\n text-align: right;\n}\n.settings-account-table--api th:nth-child(1) {\n width: 48%;\n}\n.settings-account-table--api th:nth-child(2) {\n width: 32%;\n}\n.settings-account-table--api th:nth-child(3) {\n width: 20%;\n text-align: right;\n}\n.settings-account-table td {\n padding: 17px 16px;\n vertical-align: middle;\n border-top: 1px solid var(--settings-divider);\n}\n.settings-account-row {\n background: transparent;\n}\n.settings-account-row:hover {\n background: var(--settings-hover);\n}\n.settings-account-row__person {\n display: grid;\n grid-template-columns: 34px minmax(0, 1fr);\n align-items: center;\n gap: 11px;\n min-width: 0;\n}\n.settings-account-row__mark {\n display: grid;\n place-items: center;\n width: 34px;\n height: 34px;\n color: light-dark(#67558d, #c3baff);\n background: light-dark(#f0ecf7, #353044);\n border: 1px solid light-dark(#d9d0e6, #4d435f);\n border-radius: 10px;\n}\n.settings-account-row__identity {\n min-width: 0;\n}\n.settings-account-email {\n display: block;\n min-width: 0;\n overflow: hidden;\n font-size: 12px;\n font-weight: 550;\n text-overflow: ellipsis;\n white-space: nowrap;\n}\n.settings-account-metadata {\n display: flex;\n align-items: center;\n min-width: 0;\n gap: 5px;\n margin-top: 4px;\n color: var(--settings-muted);\n flex-wrap: wrap;\n font-size: 11px;\n overflow-wrap: anywhere;\n}\n.settings-account-plan {\n flex: none;\n padding: 0 4px;\n color: var(--settings-muted);\n border: 1px solid var(--settings-border);\n border-radius: 5px;\n font-size: 10px;\n max-width: 100%;\n overflow-wrap: anywhere;\n}\n.settings-account-plan--highlighted {\n color: light-dark(#654f91, #c8bfff);\n background: light-dark(#f2edf9, #a99bff18);\n border-color: light-dark(#d9ccea, #a99bff52);\n font-weight: 600;\n}\n.settings-account-active {\n flex: none;\n color: light-dark(#66548e, #c8bfff);\n font-size: 10px;\n white-space: nowrap;\n}\n\n.settings-account-usage {\n display: grid;\n gap: 10px;\n}\n.settings-account-usage__meter {\n display: grid;\n grid-template-columns: minmax(0, 1fr) auto;\n grid-template-rows: 20px 4px 17px;\n align-items: center;\n gap: 6px 0;\n min-width: 0;\n font-variant-numeric: tabular-nums;\n}\n:host([lang="zh-CN"]) .settings-account-usage__meter {\n grid-template-columns: 48px minmax(36px, 1fr) 72px;\n}\n.settings-account-usage__meter--balance {\n display: flex;\n grid-template-columns: none;\n justify-content: flex-start;\n gap: 6px;\n}\n.settings-account-usage__balance {\n display: inline-flex;\n align-items: baseline;\n gap: 4px;\n font-size: 14px;\n font-weight: 600;\n font-variant-numeric: tabular-nums;\n white-space: nowrap;\n}\n.settings-account-usage__value-label {\n font-size: 14px;\n font-weight: 600;\n}\n\n.settings-account-usage__title {\n display: none;\n min-width: 0;\n color: var(--settings-muted);\n font-size: 11px;\n overflow: hidden;\n text-overflow: ellipsis;\n white-space: nowrap;\n}\n.settings-account-extra-usage {\n display: grid;\n gap: 12px;\n margin-top: 14px;\n}\n.settings-account-extra-usage .settings-account-usage__meter,\n.settings-account-usage__meter--scoped {\n grid-template-rows: auto 20px 4px 17px;\n}\n.settings-account-extra-usage .settings-account-usage__title,\n.settings-account-usage__meter--scoped .settings-account-usage__title {\n display: block;\n grid-column: 1 / -1;\n white-space: normal;\n overflow-wrap: anywhere;\n}\n.settings-account-usage__percent {\n grid-column: 1 / -1;\n min-width: 0;\n display: flex;\n align-items: baseline;\n justify-content: flex-end;\n gap: 7px;\n font-size: 14px;\n font-weight: 600;\n font-variant-numeric: tabular-nums;\n white-space: nowrap;\n}\n.settings-account-usage__countdown {\n min-width: 0;\n color: var(--settings-muted);\n font-size: 10px;\n font-weight: 400;\n overflow: hidden;\n text-overflow: ellipsis;\n}\n.settings-account-usage__percent > :last-child {\n flex: none;\n}\n.settings-account-usage__percent--warn {\n color: var(--settings-warning);\n}\n.settings-account-usage__percent--hot {\n color: var(--settings-danger);\n}\n.settings-account-usage__bar {\n grid-column: 1 / -1;\n height: 4px;\n overflow: hidden;\n background: light-dark(#e3e1e8, #3c3c43);\n border-radius: 4px;\n}\n.settings-account-usage__bar > span {\n display: block;\n height: 100%;\n background: light-dark(#81769e, #9993b8);\n border-radius: inherit;\n}\n.settings-account-usage__bar--warn > span {\n background: var(--settings-warning);\n}\n.settings-account-usage__bar--hot > span {\n background: var(--settings-danger);\n}\n.settings-account-usage__sub {\n grid-column: 1 / -1;\n color: var(--settings-muted);\n font-size: 10px;\n font-variant-numeric: tabular-nums;\n text-align: right;\n white-space: nowrap;\n}\n.settings-account-usage__message {\n color: var(--settings-muted);\n}\n.settings-account-usage__missing {\n display: grid;\n grid-template-columns: minmax(0, 1fr) auto;\n align-content: center;\n gap: 6px;\n min-height: 53px;\n color: var(--settings-muted);\n}\n.settings-account-usage__missing > span:not(.settings-account-usage__title) {\n grid-column: 1 / -1;\n font-size: 14px;\n}\n.settings-account-table .settings-account-spanning-cell {\n vertical-align: top;\n}\n.settings-account-quota-continuation-row > .settings-account-usage-cell {\n background: inherit;\n}\n.settings-account-management {\n display: flex;\n flex-direction: column;\n align-items: flex-end;\n gap: 4px;\n}\n.settings-account-native {\n display: flex;\n align-items: center;\n justify-content: flex-end;\n gap: 3px;\n color: var(--settings-muted);\n font-size: 11px;\n}\n.settings-account-native .settings-icon-button {\n width: 25px;\n height: 28px;\n}\n.settings-account-usage > button {\n justify-self: start;\n}\n.settings-account-action {\n padding: 4px 5px;\n min-height: 30px;\n font-size: 12px;\n color: var(--settings-text);\n background: transparent;\n border: 1px solid transparent;\n border-radius: 7px;\n white-space: nowrap;\n cursor: pointer;\n}\n.settings-account-action:hover {\n background: var(--settings-hover);\n}\n.settings-account-action:disabled {\n opacity: 0.45;\n cursor: not-allowed;\n}\n.settings-account-reset-summary {\n display: inline-flex;\n align-items: center;\n gap: 5px;\n min-height: 24px;\n padding: 3px 0;\n font-size: 10px;\n white-space: nowrap;\n color: var(--settings-muted);\n background: transparent;\n border: 0;\n border-radius: 5px;\n cursor: pointer;\n}\n.settings-account-reset-summary:hover {\n background: var(--settings-hover);\n}\n.settings-account-reset-summary[aria-expanded="true"] > svg:last-child {\n transform: rotate(90deg);\n}\n.settings-account-details-row > td {\n background: var(--settings-inset);\n}\n.settings-account-reset-details {\n display: flex;\n align-items: flex-start;\n justify-content: space-between;\n gap: 16px;\n flex-wrap: wrap;\n}\n.settings-account-reset-details strong {\n font-size: 12px;\n}\n.settings-account-reset-expiry {\n margin: 6px 0;\n color: var(--settings-muted);\n font-size: 11px;\n}\n.settings-account-reset-expiry.is-warn {\n color: var(--settings-warning);\n}\n.settings-account-reset-expiry.is-hot {\n color: var(--settings-danger);\n}\n.settings-account-reset-list {\n margin: 8px 0 0;\n padding: 0;\n list-style: none;\n color: var(--settings-muted);\n font-size: 11px;\n}\n.settings-account-reset-list li + li {\n margin-top: 4px;\n}\n.settings-account-empty {\n text-align: center;\n color: var(--settings-muted);\n}\n.settings-account-list :focus-visible,\n.settings-account-toolbar :focus-visible:not(.settings-segmented__item):not(input) {\n outline: 2px solid var(--settings-focus);\n outline-offset: 2px;\n}\n\n.settings-account-dialog {\n position: fixed;\n width: min(360px, calc(100vw - 40px));\n max-height: calc(100vh - 40px);\n overflow: auto;\n padding: 22px;\n color: var(--settings-text);\n background: var(--settings-elevated);\n border: 1px solid var(--settings-border);\n border-radius: 12px;\n box-shadow: var(--settings-dialog-shadow);\n text-align: left;\n}\n.settings-account-dialog::backdrop {\n background: var(--settings-backdrop);\n}\n.settings-account-dialog h2 {\n margin: 0 28px 12px 0;\n font-size: 15px;\n}\n.settings-account-dialog p {\n color: var(--settings-muted);\n font-size: 12px;\n line-height: 1.6;\n overflow-wrap: anywhere;\n}\n.settings-account-dialog__close {\n position: absolute;\n top: 12px;\n right: 12px;\n}\n\n@container (max-width: 680px) {\n .settings-account-table,\n .settings-account-table tbody {\n display: block;\n }\n .settings-account-table thead {\n display: none;\n }\n .settings-account-row {\n display: grid;\n grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);\n padding: 18px;\n gap: 18px 22px;\n border-top: 1px solid var(--settings-divider);\n }\n .settings-account-row:first-child {\n border-top: 0;\n }\n .settings-account-table .settings-account-row > td {\n display: block;\n min-width: 0;\n padding: 0;\n border: 0;\n }\n .settings-account-person-cell,\n .settings-account-management-cell,\n .settings-account-usage-cell--message,\n .settings-account-table--api .settings-account-usage-cell {\n grid-column: 1 / -1;\n }\n .settings-account-table .settings-account-management-cell {\n border-top: 1px solid var(--settings-divider);\n padding-top: 8px;\n }\n .settings-account-email {\n font-size: 13px;\n }\n .settings-account-usage__title {\n display: block;\n grid-column: 1;\n }\n .settings-account-usage__percent,\n .settings-account-usage__missing > span:not(.settings-account-usage__title) {\n grid-column: 2;\n text-align: right;\n }\n .settings-account-extra-usage .settings-account-usage__percent {\n grid-column: 1 / -1;\n }\n .settings-account-management {\n flex-direction: row;\n justify-content: space-between;\n }\n .settings-account-native {\n justify-content: flex-start;\n }\n .settings-account-table tr:not(.settings-account-row, [hidden]),\n .settings-account-table tr:not(.settings-account-row, [hidden]) > td {\n display: block;\n }\n}\n\n@container (max-width: 360px) {\n .settings-account-row {\n grid-template-columns: minmax(0, 1fr);\n gap: 16px;\n padding: 16px;\n }\n}\n\n@media (forced-colors: active) {\n .settings-account-usage__bar {\n border: 1px solid CanvasText;\n }\n .settings-account-usage__bar > span {\n background: Highlight;\n }\n}\n';
|
|
27350
27089
|
|
|
27351
27090
|
// src/settings/shell.ts
|
|
27352
27091
|
var SETTINGS_SHELL_ATTRIBUTE = "data-codexhost-settings-shell";
|
|
@@ -28103,7 +27842,9 @@ ${accounts_default}`;
|
|
|
28103
27842
|
antigravity: harnessIdSchema.parse("antigravity"),
|
|
28104
27843
|
hermes: harnessIdSchema.parse("hermes"),
|
|
28105
27844
|
muse: harnessIdSchema.parse("muse"),
|
|
28106
|
-
"kiro-cli": harnessIdSchema.parse("kiro-cli")
|
|
27845
|
+
"kiro-cli": harnessIdSchema.parse("kiro-cli"),
|
|
27846
|
+
codebuddy: harnessIdSchema.parse("codebuddy"),
|
|
27847
|
+
"cursor-cli": harnessIdSchema.parse("cursor-cli")
|
|
28107
27848
|
};
|
|
28108
27849
|
var externalAgents = [
|
|
28109
27850
|
"pi",
|
|
@@ -28115,7 +27856,9 @@ ${accounts_default}`;
|
|
|
28115
27856
|
"antigravity",
|
|
28116
27857
|
"hermes",
|
|
28117
27858
|
"muse",
|
|
28118
|
-
"kiro-cli"
|
|
27859
|
+
"kiro-cli",
|
|
27860
|
+
"codebuddy",
|
|
27861
|
+
"cursor-cli"
|
|
28119
27862
|
];
|
|
28120
27863
|
function isRetryableHarnessAvailability(availability, error51) {
|
|
28121
27864
|
return availability !== void 0 && availability !== "ready" && availability !== "notInstalled" && error51?.retryable === true;
|
|
@@ -28292,6 +28035,21 @@ ${accounts_default}`;
|
|
|
28292
28035
|
...inspection.effectivePermissionModeId ? { permissionModeId: inspection.effectivePermissionModeId } : {}
|
|
28293
28036
|
};
|
|
28294
28037
|
}
|
|
28038
|
+
if (inspection.harnessId === "kiro-cli" || inspection.harnessId === "codebuddy" || inspection.harnessId === "cursor-cli") {
|
|
28039
|
+
const route = decodeHarnessPluginRoute(inspection.transportModelId);
|
|
28040
|
+
if (!route || route.harnessId !== inspection.harnessId) {
|
|
28041
|
+
throw new Error("Plugin Thread reported an incompatible transport Model");
|
|
28042
|
+
}
|
|
28043
|
+
const model = inspection.effectiveModel ?? route.model;
|
|
28044
|
+
const thinkingOptionId = inspection.harnessId === "cursor-cli" ? void 0 : inspection.availableThinkingOptions !== void 0 ? selectableThinkingOptionId(inspection) : inspection.effectiveThinkingOptionId ?? route.thinkingOptionId;
|
|
28045
|
+
const permissionModeId = inspection.effectivePermissionModeId ?? route.permissionModeId;
|
|
28046
|
+
return {
|
|
28047
|
+
agent: inspection.harnessId,
|
|
28048
|
+
...model ? { model } : {},
|
|
28049
|
+
...thinkingOptionId ? { thinkingOptionId } : {},
|
|
28050
|
+
...permissionModeId ? { permissionModeId } : {}
|
|
28051
|
+
};
|
|
28052
|
+
}
|
|
28295
28053
|
return restoredPluginRouteOwnership(inspection);
|
|
28296
28054
|
}
|
|
28297
28055
|
function isKnownExternalRendererAgent(value) {
|
|
@@ -28479,7 +28237,9 @@ ${accounts_default}`;
|
|
|
28479
28237
|
antigravity: void 0,
|
|
28480
28238
|
hermes: void 0,
|
|
28481
28239
|
muse: void 0,
|
|
28482
|
-
"kiro-cli": void 0
|
|
28240
|
+
"kiro-cli": void 0,
|
|
28241
|
+
codebuddy: void 0,
|
|
28242
|
+
"cursor-cli": void 0
|
|
28483
28243
|
},
|
|
28484
28244
|
webUi: Object.fromEntries(
|
|
28485
28245
|
externalAgents.map((agent) => [agent, false])
|
|
@@ -28504,7 +28264,18 @@ ${accounts_default}`;
|
|
|
28504
28264
|
if (!client) return null;
|
|
28505
28265
|
const state = hostHarnessAvailabilityState(hostId);
|
|
28506
28266
|
if (state.codexAccounts?.client !== client) {
|
|
28507
|
-
state.codexAccounts
|
|
28267
|
+
state.codexAccounts?.dispose();
|
|
28268
|
+
state.codexAccounts = new RendererCodexAccountState(client, () => {
|
|
28269
|
+
queueMicrotask(() => {
|
|
28270
|
+
if (disposed || hostHarnessAvailabilityState(hostId).codexAccounts?.client !== client)
|
|
28271
|
+
return;
|
|
28272
|
+
for (const mounted of mountedByComposer.values()) {
|
|
28273
|
+
if (mounted.hostId !== hostId) continue;
|
|
28274
|
+
renderMounted(mounted);
|
|
28275
|
+
void refreshDraftCodexUsage(mounted);
|
|
28276
|
+
}
|
|
28277
|
+
});
|
|
28278
|
+
});
|
|
28508
28279
|
}
|
|
28509
28280
|
return state.codexAccounts;
|
|
28510
28281
|
};
|
|
@@ -28522,12 +28293,7 @@ ${accounts_default}`;
|
|
|
28522
28293
|
const isCurrentModelRequest = (mounted, generation) => isMountedComposer(mounted.composer) && mountedByComposer.get(mounted.composer) === mounted && controller.isCurrentModelRequest(mounted.composer, generation);
|
|
28523
28294
|
const isCurrentOwnershipRequest = (mounted, generation) => mounted.composer.isConnected && mountedByComposer.get(mounted.composer) === mounted && controller.isCurrentOwnershipRequest(mounted.composer, generation);
|
|
28524
28295
|
const notifySubmission = (composer, trigger) => {
|
|
28525
|
-
const
|
|
28526
|
-
const state = controller.recordSubmission(
|
|
28527
|
-
composer,
|
|
28528
|
-
accounts?.selection.selectedAccountId ?? void 0
|
|
28529
|
-
);
|
|
28530
|
-
if (state.agent === "codex" && accounts) accounts.overrideAccountId = null;
|
|
28296
|
+
const state = controller.recordSubmission(composer);
|
|
28531
28297
|
writeNewThreadAgentPreference(state.agent);
|
|
28532
28298
|
if (state.agent !== "codex") {
|
|
28533
28299
|
const model = controller.modelForAgent(composer, state.agent);
|
|
@@ -28551,24 +28317,22 @@ ${accounts_default}`;
|
|
|
28551
28317
|
);
|
|
28552
28318
|
};
|
|
28553
28319
|
const renderMounted = (mounted) => {
|
|
28554
|
-
const state = controller.get(mounted.composer);
|
|
28555
28320
|
const accounts = composerCodexAccounts(mounted.composer);
|
|
28556
|
-
const
|
|
28321
|
+
const currentCodexAccount = accounts?.accounts.find(
|
|
28322
|
+
({ accountId }) => accountId === accounts.readyAccountId
|
|
28323
|
+
);
|
|
28557
28324
|
renderComposerAgentControl(
|
|
28558
28325
|
mounted.control,
|
|
28559
28326
|
controller.get(mounted.composer),
|
|
28560
28327
|
adapterStatus.state,
|
|
28561
|
-
|
|
28328
|
+
controller.isSwitching(mounted.composer) || mounted.ownershipStatus === "loading",
|
|
28562
28329
|
activeHarnessAvailabilityState().availability,
|
|
28563
28330
|
mounted.modelView,
|
|
28564
28331
|
mounted.permissionModeView,
|
|
28565
28332
|
mounted.usage,
|
|
28566
28333
|
mounted.accountCredits,
|
|
28567
28334
|
settingsLifecycle.locale,
|
|
28568
|
-
|
|
28569
|
-
...account,
|
|
28570
|
-
active: account.accountId === selectedCodexAccountId
|
|
28571
|
-
})),
|
|
28335
|
+
currentCodexAccount ?? null,
|
|
28572
28336
|
mounted.ownershipStatus === "error"
|
|
28573
28337
|
);
|
|
28574
28338
|
if (mounted.control.usage) {
|
|
@@ -28642,16 +28406,16 @@ ${accounts_default}`;
|
|
|
28642
28406
|
return;
|
|
28643
28407
|
const accounts = composerCodexAccounts(mounted.composer);
|
|
28644
28408
|
const client = accounts?.client;
|
|
28645
|
-
const accountId = accounts?.
|
|
28409
|
+
const accountId = accounts?.readyAccountId;
|
|
28646
28410
|
const hostId = mounted.hostId;
|
|
28647
28411
|
const generation = ++mounted.usageRequestGeneration;
|
|
28648
28412
|
mounted.usage = null;
|
|
28649
28413
|
mounted.accountCredits = null;
|
|
28650
28414
|
renderMounted(mounted);
|
|
28651
|
-
if (
|
|
28415
|
+
if (!accountId || !client?.inspectCodexAccountUsage) return;
|
|
28652
28416
|
try {
|
|
28653
28417
|
const result = await client.inspectCodexAccountUsage({ accountId });
|
|
28654
|
-
if (disposed || mounted.hostId !== hostId || composerCodexAccounts(mounted.composer) !== accounts || !mounted.composer.isConnected || mountedByComposer.get(mounted.composer) !== mounted || mounted.usageRequestGeneration !== generation || controller.get(mounted.composer).agent !== "codex" || controller.get(mounted.composer).phase !== "draft" || controller.isSubmissionPending(mounted.composer) || threadIdFromComposerModelTarget(mounted.modelTarget) || accounts.
|
|
28418
|
+
if (disposed || mounted.hostId !== hostId || composerCodexAccounts(mounted.composer) !== accounts || !mounted.composer.isConnected || mountedByComposer.get(mounted.composer) !== mounted || mounted.usageRequestGeneration !== generation || controller.get(mounted.composer).agent !== "codex" || controller.get(mounted.composer).phase !== "draft" || controller.isSubmissionPending(mounted.composer) || threadIdFromComposerModelTarget(mounted.modelTarget) || accounts.readyAccountId !== accountId || result.accountId !== accountId)
|
|
28655
28419
|
return;
|
|
28656
28420
|
mounted.usage = result.usage;
|
|
28657
28421
|
mounted.accountCredits = composerAccountCredits(result.accountCredits);
|
|
@@ -28758,8 +28522,7 @@ ${accounts_default}`;
|
|
|
28758
28522
|
agent,
|
|
28759
28523
|
model,
|
|
28760
28524
|
thinkingOptionId,
|
|
28761
|
-
permissionModeId
|
|
28762
|
-
inspection.owner === "codex" ? inspection.accountId : void 0
|
|
28525
|
+
permissionModeId
|
|
28763
28526
|
);
|
|
28764
28527
|
if (!restored) {
|
|
28765
28528
|
throw new Error("Thread owner could not be applied to the Composer");
|
|
@@ -29475,39 +29238,6 @@ ${accounts_default}`;
|
|
|
29475
29238
|
void refreshDraftCodexUsage(mounted);
|
|
29476
29239
|
}
|
|
29477
29240
|
};
|
|
29478
|
-
const selectCodexAccount = async (mounted, accountId) => {
|
|
29479
|
-
const hostId = mounted.hostId;
|
|
29480
|
-
const accounts = composerCodexAccounts(mounted.composer);
|
|
29481
|
-
if (!accounts || accounts.switching || controller.get(mounted.composer).phase === "locked" || !accounts.accounts.some((account) => account.accountId === accountId))
|
|
29482
|
-
return;
|
|
29483
|
-
const isCurrent = () => !disposed && mounted.composer.isConnected && mountedByComposer.get(mounted.composer) === mounted && controller.get(mounted.composer).phase !== "locked" && accounts.accounts.some((account) => account.accountId === accountId) && mounted.hostId === hostId && activeModelHostId() === hostId && composerCodexAccounts(mounted.composer) === accounts;
|
|
29484
|
-
accounts.switching = true;
|
|
29485
|
-
for (const candidate of mountedByComposer.values()) {
|
|
29486
|
-
renderMounted(candidate);
|
|
29487
|
-
void refreshDraftCodexUsage(candidate);
|
|
29488
|
-
}
|
|
29489
|
-
try {
|
|
29490
|
-
if (controller.get(mounted.composer).agent !== "codex" && !await switchComposerAgent(mounted, "codex")) {
|
|
29491
|
-
return;
|
|
29492
|
-
}
|
|
29493
|
-
const policy = await waitForRendererDraftPrewarmPolicy(window);
|
|
29494
|
-
if (!isCurrent() || policy.hostId !== hostId) return;
|
|
29495
|
-
await policy.clear();
|
|
29496
|
-
if (!isCurrent() || window.__codexhostDraftPrewarmPolicyV1 !== policy) return;
|
|
29497
|
-
if (!policy.selectAccount) throw new Error("Codex Account selection is unavailable");
|
|
29498
|
-
const override = accountId === accounts.selection.activeAccountId ? null : accountId;
|
|
29499
|
-
policy.selectAccount(override);
|
|
29500
|
-
accounts.overrideAccountId = override;
|
|
29501
|
-
} catch {
|
|
29502
|
-
if (isCurrent()) void loadCodexAccounts();
|
|
29503
|
-
} finally {
|
|
29504
|
-
accounts.switching = false;
|
|
29505
|
-
for (const candidate of mountedByComposer.values()) {
|
|
29506
|
-
renderMounted(candidate);
|
|
29507
|
-
void refreshDraftCodexUsage(candidate);
|
|
29508
|
-
}
|
|
29509
|
-
}
|
|
29510
|
-
};
|
|
29511
29241
|
const openInstallPage = (agent) => {
|
|
29512
29242
|
const url2 = RENDERER_AGENT_INSTALL_URLS[agent];
|
|
29513
29243
|
window.open(url2, "_blank", "noopener,noreferrer");
|
|
@@ -29777,11 +29507,6 @@ ${accounts_default}`;
|
|
|
29777
29507
|
void switchComposerAgent(mounted2, agent);
|
|
29778
29508
|
},
|
|
29779
29509
|
openInstallPage,
|
|
29780
|
-
async (accountId) => {
|
|
29781
|
-
const mounted2 = mountedByComposer.get(composer);
|
|
29782
|
-
if (!composer.isConnected || !mounted2) return;
|
|
29783
|
-
await selectCodexAccount(mounted2, accountId);
|
|
29784
|
-
},
|
|
29785
29510
|
() => {
|
|
29786
29511
|
void loadCodexAccounts();
|
|
29787
29512
|
},
|
|
@@ -29976,26 +29701,12 @@ ${accounts_default}`;
|
|
|
29976
29701
|
const mounted = mountedByComposer.get(composer);
|
|
29977
29702
|
if (!mounted) return null;
|
|
29978
29703
|
const current = controller.get(composer);
|
|
29979
|
-
if (
|
|
29704
|
+
if (controller.isSwitching(composer) || isOwnershipSubmissionBlocked(mounted.ownershipStatus)) {
|
|
29980
29705
|
return false;
|
|
29981
29706
|
}
|
|
29982
29707
|
if (!isExternalConfigurationReady(mounted)) return false;
|
|
29983
29708
|
if (current.phase === "locked") return true;
|
|
29984
29709
|
if (!applyComposerAgent(composer)) return false;
|
|
29985
|
-
if (current.agent === "codex") {
|
|
29986
|
-
const selection = composerCodexAccounts(composer)?.selection;
|
|
29987
|
-
const accountId = controller.isSubmissionPending(composer) && current.codexAccountId ? current.codexAccountId : selection?.selectedAccountId;
|
|
29988
|
-
const override = accountId === selection?.activeAccountId ? null : accountId ?? null;
|
|
29989
|
-
const policy = window.__codexhostDraftPrewarmPolicyV1;
|
|
29990
|
-
if (override !== null && (policy?.hostId !== mounted.hostId || !policy.selectAccount)) {
|
|
29991
|
-
return false;
|
|
29992
|
-
}
|
|
29993
|
-
try {
|
|
29994
|
-
if (policy?.hostId === mounted.hostId) policy.selectAccount?.(override);
|
|
29995
|
-
} catch {
|
|
29996
|
-
return false;
|
|
29997
|
-
}
|
|
29998
|
-
}
|
|
29999
29710
|
controller.markSubmissionPending(composer);
|
|
30000
29711
|
renderMounted(mounted);
|
|
30001
29712
|
return true;
|
|
@@ -30030,7 +29741,7 @@ ${accounts_default}`;
|
|
|
30030
29741
|
const onKeyDown = (event) => {
|
|
30031
29742
|
const composer = isComposerInputIntent(event) ? composerForTarget(event.target) : null;
|
|
30032
29743
|
const mounted = composer ? mountedByComposer.get(composer) : void 0;
|
|
30033
|
-
if (composer &&
|
|
29744
|
+
if (composer && controller.isSwitching(composer)) {
|
|
30034
29745
|
blockEvent(event);
|
|
30035
29746
|
return;
|
|
30036
29747
|
}
|
|
@@ -30187,6 +29898,7 @@ ${accounts_default}`;
|
|
|
30187
29898
|
for (const state of harnessAvailabilityByHost.values()) {
|
|
30188
29899
|
state.requestGeneration += 1;
|
|
30189
29900
|
state.request = null;
|
|
29901
|
+
state.codexAccounts?.dispose();
|
|
30190
29902
|
if (state.retryTimer !== null) window.clearTimeout(state.retryTimer);
|
|
30191
29903
|
}
|
|
30192
29904
|
harnessAvailabilityByHost.clear();
|
|
@@ -30242,6 +29954,7 @@ ${accounts_default}`;
|
|
|
30242
29954
|
window.removeEventListener("focus", onWindowFocus);
|
|
30243
29955
|
for (const state of harnessAvailabilityByHost.values()) {
|
|
30244
29956
|
state.requestGeneration += 1;
|
|
29957
|
+
state.codexAccounts?.dispose();
|
|
30245
29958
|
if (state.retryTimer !== null) window.clearTimeout(state.retryTimer);
|
|
30246
29959
|
}
|
|
30247
29960
|
harnessAvailabilityByHost.clear();
|