@jmanuelcorral/openteam 0.1.22 → 0.1.24
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cli.js +58 -29
- package/dist/commands/setup.d.ts +0 -1
- package/dist/commands/setup.d.ts.map +1 -1
- package/dist/commands/slashCommand.d.ts +32 -8
- package/dist/commands/slashCommand.d.ts.map +1 -1
- package/dist/config/schema.d.ts +0 -2
- package/dist/config/schema.d.ts.map +1 -1
- package/dist/index.js +0 -2
- package/package.json +1 -1
package/dist/cli.js
CHANGED
|
@@ -688,7 +688,6 @@ var PrivacyModeSchema = z2.enum([
|
|
|
688
688
|
var BaselineModeSchema = z2.enum(["auto", "pinned"]);
|
|
689
689
|
var DashboardHostSchema = z2.enum(["127.0.0.1", "localhost"]);
|
|
690
690
|
var DashboardConfigSchema = z2.object({
|
|
691
|
-
enabled: z2.boolean().default(false),
|
|
692
691
|
host: DashboardHostSchema.default("127.0.0.1"),
|
|
693
692
|
port: z2.number().int().min(1024).max(65535).default(4599),
|
|
694
693
|
autoPortFallback: z2.boolean().default(true),
|
|
@@ -696,7 +695,6 @@ var DashboardConfigSchema = z2.object({
|
|
|
696
695
|
recentRoutes: z2.number().int().positive().default(50),
|
|
697
696
|
openBrowser: z2.boolean().default(false)
|
|
698
697
|
}).default({
|
|
699
|
-
enabled: false,
|
|
700
698
|
host: "127.0.0.1",
|
|
701
699
|
port: 4599,
|
|
702
700
|
autoPortFallback: true,
|
|
@@ -1623,7 +1621,7 @@ async function runDashboardServe(deps, options) {
|
|
|
1623
1621
|
let runtime;
|
|
1624
1622
|
try {
|
|
1625
1623
|
runtime = await start({
|
|
1626
|
-
config:
|
|
1624
|
+
config: config.dashboard,
|
|
1627
1625
|
sessionsDir: deps.sessionsDir,
|
|
1628
1626
|
decisionsPath: deps.decisionsPath,
|
|
1629
1627
|
backlogPath: deps.backlogPath,
|
|
@@ -2983,13 +2981,21 @@ async function writeOpenTeamConfigFile(config, path = DEFAULT_CONFIG_PATH, deps
|
|
|
2983
2981
|
}
|
|
2984
2982
|
|
|
2985
2983
|
// src/commands/slashCommand.ts
|
|
2986
|
-
var
|
|
2987
|
-
|
|
2984
|
+
var OPENTEAM_COMMAND_DIR = ".opencode/command";
|
|
2985
|
+
var OPENTEAM_COMMAND_PATH = `${OPENTEAM_COMMAND_DIR}/openteam.md`;
|
|
2986
|
+
function renderCommand(description, body) {
|
|
2987
|
+
return ["---", `description: ${description}`, "---", "", body, ""].join(`
|
|
2988
|
+
`);
|
|
2989
|
+
}
|
|
2990
|
+
function fixedActionBody(action) {
|
|
2988
2991
|
return [
|
|
2989
|
-
"
|
|
2990
|
-
"
|
|
2991
|
-
|
|
2992
|
-
|
|
2992
|
+
`Llama a la herramienta \`openteam\` una sola vez con \`action: "${action}"\`.`,
|
|
2993
|
+
"Devuelve su salida tal cual, sin reinterpretarla."
|
|
2994
|
+
].join(`
|
|
2995
|
+
`);
|
|
2996
|
+
}
|
|
2997
|
+
function buildOpenteamCommand() {
|
|
2998
|
+
return renderCommand("Comandos runtime de openteam (baseline show|set|auto, doctor, agents, dashboard, report)", [
|
|
2993
2999
|
"Usa la herramienta `openteam` para ejecutar el comando indicado por el usuario: $ARGUMENTS",
|
|
2994
3000
|
"",
|
|
2995
3001
|
"Interpreta los argumentos así y llama a la herramienta `openteam` una sola vez:",
|
|
@@ -3002,10 +3008,36 @@ function buildOpenteamCommand() {
|
|
|
3002
3008
|
'- `dashboard` → `action: "dashboard"`',
|
|
3003
3009
|
'- `report` → `action: "report"`',
|
|
3004
3010
|
"",
|
|
3005
|
-
"Devuelve la salida de la herramienta tal cual, sin reinterpretarla."
|
|
3006
|
-
""
|
|
3011
|
+
"Devuelve la salida de la herramienta tal cual, sin reinterpretarla."
|
|
3007
3012
|
].join(`
|
|
3008
|
-
`);
|
|
3013
|
+
`));
|
|
3014
|
+
}
|
|
3015
|
+
function buildBaselineCommand() {
|
|
3016
|
+
return renderCommand("openteam · baseline frontier cheapest-capable (show | set <provider/model> | auto)", [
|
|
3017
|
+
"Usa la herramienta `openteam` para el baseline frontier: $ARGUMENTS",
|
|
3018
|
+
"",
|
|
3019
|
+
'- vacío o `show` → `action: "show"`',
|
|
3020
|
+
'- `set <provider/model>` → `action: "set"`, `model: "<provider/model>"`',
|
|
3021
|
+
'- `auto` → `action: "auto"`',
|
|
3022
|
+
"",
|
|
3023
|
+
"Llama a la herramienta una sola vez y devuelve su salida tal cual."
|
|
3024
|
+
].join(`
|
|
3025
|
+
`));
|
|
3026
|
+
}
|
|
3027
|
+
function buildOpenteamCommands() {
|
|
3028
|
+
const file = (name, contents) => ({
|
|
3029
|
+
name,
|
|
3030
|
+
path: `${OPENTEAM_COMMAND_DIR}/${name}.md`,
|
|
3031
|
+
contents
|
|
3032
|
+
});
|
|
3033
|
+
return [
|
|
3034
|
+
file("openteam", buildOpenteamCommand()),
|
|
3035
|
+
file("openteam-baseline", buildBaselineCommand()),
|
|
3036
|
+
file("openteam-doctor", renderCommand("openteam · diagnóstico de runtimes locales y configuración", fixedActionBody("doctor"))),
|
|
3037
|
+
file("openteam-agents", renderCommand("openteam · lista los agentes y el LLM (local/frontier + suscripción) de cada uno", fixedActionBody("agents"))),
|
|
3038
|
+
file("openteam-dashboard", renderCommand("openteam · estado y URL del dashboard web multi-sesión", fixedActionBody("dashboard"))),
|
|
3039
|
+
file("openteam-report", renderCommand("openteam · resumen de coste/ahorro (telemetría)", fixedActionBody("report")))
|
|
3040
|
+
];
|
|
3009
3041
|
}
|
|
3010
3042
|
|
|
3011
3043
|
// src/commands/setup.ts
|
|
@@ -3095,8 +3127,7 @@ function buildOpenTeamConfig(answers) {
|
|
|
3095
3127
|
localDefault
|
|
3096
3128
|
},
|
|
3097
3129
|
local: { runtimes },
|
|
3098
|
-
privacyMode: answers.privacyMode
|
|
3099
|
-
dashboard: { enabled: answers.dashboard }
|
|
3130
|
+
privacyMode: answers.privacyMode
|
|
3100
3131
|
});
|
|
3101
3132
|
}
|
|
3102
3133
|
function buildOpencodeConfig(answers) {
|
|
@@ -3340,26 +3371,20 @@ async function runSetup(deps) {
|
|
|
3340
3371
|
message: "¿Activar modo YOLO? (opencode auto-aprueba todos los permisos; no afecta a la privacidad de openteam)",
|
|
3341
3372
|
initial: false
|
|
3342
3373
|
});
|
|
3343
|
-
const dashboard = await prompt.confirm({
|
|
3344
|
-
message: "¿Exponer el dashboard web local mientras opencode está abierto? (solo loopback en el puerto 4599, sin prompts; ajustable luego en .opencode/openteam.json)",
|
|
3345
|
-
initial: false
|
|
3346
|
-
});
|
|
3347
3374
|
const answers = {
|
|
3348
3375
|
runtimes,
|
|
3349
3376
|
frontier,
|
|
3350
3377
|
routerMode,
|
|
3351
3378
|
privacyMode,
|
|
3352
|
-
yolo
|
|
3353
|
-
dashboard
|
|
3379
|
+
yolo
|
|
3354
3380
|
};
|
|
3355
3381
|
const openTeamConfig = buildOpenTeamConfig(answers);
|
|
3356
3382
|
const opencodeConfig = buildOpencodeConfig(answers);
|
|
3357
3383
|
const orchestratorAgent = buildOrchestratorAgent(frontier, { yolo });
|
|
3358
|
-
const
|
|
3384
|
+
const slashCommands = buildOpenteamCommands();
|
|
3359
3385
|
const openTeamPath = join(deps.cwd, DEFAULT_CONFIG_PATH);
|
|
3360
3386
|
const opencodePath = join(deps.cwd, OPENCODE_CONFIG_PATH);
|
|
3361
3387
|
const agentPath = join(deps.cwd, ORCHESTRATOR_AGENT_PATH);
|
|
3362
|
-
const commandPath = join(deps.cwd, OPENTEAM_COMMAND_PATH);
|
|
3363
3388
|
const existing = [];
|
|
3364
3389
|
if (await deps.fileExists(openTeamPath)) {
|
|
3365
3390
|
existing.push(DEFAULT_CONFIG_PATH);
|
|
@@ -3370,8 +3395,10 @@ async function runSetup(deps) {
|
|
|
3370
3395
|
if (await deps.fileExists(agentPath)) {
|
|
3371
3396
|
existing.push(ORCHESTRATOR_AGENT_PATH);
|
|
3372
3397
|
}
|
|
3373
|
-
|
|
3374
|
-
|
|
3398
|
+
for (const command of slashCommands) {
|
|
3399
|
+
if (await deps.fileExists(join(deps.cwd, command.path))) {
|
|
3400
|
+
existing.push(command.path);
|
|
3401
|
+
}
|
|
3375
3402
|
}
|
|
3376
3403
|
if (existing.length > 0) {
|
|
3377
3404
|
const overwrite = await prompt.confirm({
|
|
@@ -3386,25 +3413,27 @@ async function runSetup(deps) {
|
|
|
3386
3413
|
await deps.writeFile(openTeamPath, serializeOpenTeamConfig(openTeamConfig));
|
|
3387
3414
|
await deps.writeFile(opencodePath, serializeOpencodeConfig(opencodeConfig));
|
|
3388
3415
|
await deps.writeFile(agentPath, orchestratorAgent);
|
|
3389
|
-
|
|
3416
|
+
for (const command of slashCommands) {
|
|
3417
|
+
await deps.writeFile(join(deps.cwd, command.path), command.contents);
|
|
3418
|
+
}
|
|
3390
3419
|
const enabledSummary = runtimes.filter((runtime) => runtime.enabled).map((runtime) => `${runtime.id} (${runtime.defaultModelID})`).join(", ");
|
|
3391
3420
|
prompt.note([
|
|
3392
3421
|
`Baseline frontier: ${frontier.providerID}/${frontier.modelID}`,
|
|
3393
3422
|
`Runtimes locales: ${enabledSummary || "ninguno habilitado"}`,
|
|
3394
3423
|
`Modo YOLO: ${yolo ? "activado (auto-aprueba permisos)" : "desactivado"}`,
|
|
3395
|
-
|
|
3396
|
-
`Escrito: ${OPENCODE_CONFIG_PATH}, ${DEFAULT_CONFIG_PATH}, ${ORCHESTRATOR_AGENT_PATH}, ${
|
|
3424
|
+
"Dashboard web: se lanza aparte desde la CLI con 'openteam dashboard' (multi-sesión, loopback)",
|
|
3425
|
+
`Escrito: ${OPENCODE_CONFIG_PATH}, ${DEFAULT_CONFIG_PATH}, ${ORCHESTRATOR_AGENT_PATH}, ${OPENTEAM_COMMAND_DIR}/*.md (${slashCommands.length} comandos)`,
|
|
3397
3426
|
"",
|
|
3398
3427
|
"Siguientes pasos:",
|
|
3399
3428
|
` 1. Autentica el provider frontier: opencode auth login`,
|
|
3400
3429
|
reachableIds.length === 0 ? " 2. Arranca tu runtime local (Ollama/LM Studio/Foundry) antes de usarlo" : " 2. Abre opencode en este repo; openteam enruta local-first automáticamente",
|
|
3401
|
-
" 3. Pulsa Tab y elige el agente 'openteam', o
|
|
3430
|
+
" 3. Pulsa Tab y elige el agente 'openteam', o teclea / y elige un comando /openteam…"
|
|
3402
3431
|
].join(`
|
|
3403
3432
|
`), "openteam configurado");
|
|
3404
3433
|
prompt.outro("Listo. Abre opencode y selecciona el agente 'openteam'.");
|
|
3405
3434
|
return {
|
|
3406
3435
|
exitCode: 0,
|
|
3407
|
-
stdout: `openteam setup completado: ${OPENCODE_CONFIG_PATH}, ${DEFAULT_CONFIG_PATH}, ${ORCHESTRATOR_AGENT_PATH}, ${
|
|
3436
|
+
stdout: `openteam setup completado: ${OPENCODE_CONFIG_PATH}, ${DEFAULT_CONFIG_PATH}, ${ORCHESTRATOR_AGENT_PATH}, ${OPENTEAM_COMMAND_DIR}/*.md`
|
|
3408
3437
|
};
|
|
3409
3438
|
} catch (error) {
|
|
3410
3439
|
const message = error instanceof Error ? error.message : String(error);
|
package/dist/commands/setup.d.ts
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"setup.d.ts","sourceRoot":"","sources":["../../src/commands/setup.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,sBAAsB,EAAE,MAAM,uBAAuB,CAAC;AAKpE,OAAO,EAEL,KAAK,cAAc,EAEnB,KAAK,WAAW,EAChB,KAAK,UAAU,EAChB,MAAM,kBAAkB,CAAC;AAC1B,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,gBAAgB,CAAC;AACrD,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,YAAY,CAAC;AAO5C,iFAAiF;AACjF,eAAO,MAAM,oBAAoB,4BAA4B,CAAC;AAE9D,2DAA2D;AAC3D,eAAO,MAAM,oBAAoB,kBAAkB,CAAC;AAEpD,MAAM,MAAM,YAAY,GAAG;IACzB,EAAE,EAAE,cAAc,CAAC;IACnB,K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,GAAG;IACtB,GAAG,EAAE,MAAM,CAAC;IACZ,MAAM,EAAE,MAAM,OAAO,CAAC,eAAe,EAAE,CAAC,CAAC;IACzC,oBAAoB,EAAE,MAAM,OAAO,CAAC,sBAAsB,EAAE,CAAC,CAAC;IAC9D,MAAM,EAAE,QAAQ,CAAC;IACjB,SAAS,EAAE,CAAC,IAAI,EAAE,MAAM,EAAE,QAAQ,EAAE,MAAM,KAAK,OAAO,CAAC,IAAI,CAAC,CAAC;IAC7D,UAAU,EAAE,CAAC,IAAI,EAAE,MAAM,KAAK,OAAO,CAAC,OAAO,CAAC,CAAC;CAChD,CAAC;AA6IF,wBAAsB,QAAQ,CAAC,IAAI,EAAE,SAAS,GAAG,OAAO,CAAC,SAAS,CAAC,CAgNlE"}
|
|
@@ -1,15 +1,39 @@
|
|
|
1
1
|
/**
|
|
2
|
-
*
|
|
3
|
-
*
|
|
4
|
-
*
|
|
5
|
-
* nombre del comando
|
|
2
|
+
* Directorio (relativo al cwd) donde opencode descubre los slash commands del
|
|
3
|
+
* proyecto. opencode escanea `{command,commands}/**\/*.md` (singular y plural) en
|
|
4
|
+
* cada `.opencode/` del árbol y en `~/.config/opencode/`; el nombre del fichero
|
|
5
|
+
* es el nombre del comando (verificado en el source de opencode v1.17.8:
|
|
6
|
+
* `packages/opencode/src/config/command.ts`).
|
|
7
|
+
*/
|
|
8
|
+
export declare const OPENTEAM_COMMAND_DIR = ".opencode/command";
|
|
9
|
+
/**
|
|
10
|
+
* Ruta del slash command principal `/openteam` (catch-all). Se mantiene como
|
|
11
|
+
* constante estable para compatibilidad; el resto de comandos derivan de
|
|
12
|
+
* {@link OPENTEAM_COMMAND_DIR}.
|
|
6
13
|
*/
|
|
7
14
|
export declare const OPENTEAM_COMMAND_PATH = ".opencode/command/openteam.md";
|
|
15
|
+
/** Un slash command listo para escribir en disco. */
|
|
16
|
+
export type SlashCommandFile = {
|
|
17
|
+
/** Nombre del comando (fichero `<name>.md`), invocable como `/<name>`. */
|
|
18
|
+
name: string;
|
|
19
|
+
/** Ruta relativa al cwd del fichero markdown. */
|
|
20
|
+
path: string;
|
|
21
|
+
/** Contenido markdown (frontmatter + template). */
|
|
22
|
+
contents: string;
|
|
23
|
+
};
|
|
8
24
|
/**
|
|
9
|
-
* Construye el Markdown del slash command `/openteam
|
|
10
|
-
* los argumentos del usuario a una única llamada de la
|
|
11
|
-
* Debe mantenerse alineado con las acciones de
|
|
12
|
-
* `src/plugin/commandTool.ts`. Pure/determinista: sin I/O.
|
|
25
|
+
* Construye el Markdown del slash command `/openteam` (catch-all). Enseña al
|
|
26
|
+
* agente a mapear los argumentos del usuario a una única llamada de la
|
|
27
|
+
* herramienta `openteam`. Debe mantenerse alineado con las acciones de
|
|
28
|
+
* `commandArgv` en `src/plugin/commandTool.ts`. Pure/determinista: sin I/O.
|
|
13
29
|
*/
|
|
14
30
|
export declare function buildOpenteamCommand(): string;
|
|
31
|
+
/**
|
|
32
|
+
* Todos los slash commands que `openteam setup` escribe en
|
|
33
|
+
* `.opencode/command/`. Además del catch-all `/openteam`, genera un comando
|
|
34
|
+
* plano por acción (`/openteam-doctor`, `/openteam-agents`, …) para que todos
|
|
35
|
+
* aparezcan y se autocompleten en la paleta de opencode al teclear `/openteam`.
|
|
36
|
+
* Pure/determinista: sin I/O.
|
|
37
|
+
*/
|
|
38
|
+
export declare function buildOpenteamCommands(): SlashCommandFile[];
|
|
15
39
|
//# sourceMappingURL=slashCommand.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"slashCommand.d.ts","sourceRoot":"","sources":["../../src/commands/slashCommand.ts"],"names":[],"mappings":"AAAA
|
|
1
|
+
{"version":3,"file":"slashCommand.d.ts","sourceRoot":"","sources":["../../src/commands/slashCommand.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AACH,eAAO,MAAM,oBAAoB,sBAAsB,CAAC;AAExD;;;;GAIG;AACH,eAAO,MAAM,qBAAqB,kCAAwC,CAAC;AAE3E,qDAAqD;AACrD,MAAM,MAAM,gBAAgB,GAAG;IAC7B,0EAA0E;IAC1E,IAAI,EAAE,MAAM,CAAC;IACb,iDAAiD;IACjD,IAAI,EAAE,MAAM,CAAC;IACb,mDAAmD;IACnD,QAAQ,EAAE,MAAM,CAAC;CAClB,CAAC;AAkBF;;;;;GAKG;AACH,wBAAgB,oBAAoB,IAAI,MAAM,CAmB7C;AAqBD;;;;;;GAMG;AACH,wBAAgB,qBAAqB,IAAI,gBAAgB,EAAE,CAuC1D"}
|
package/dist/config/schema.d.ts
CHANGED
|
@@ -22,7 +22,6 @@ export declare const DashboardHostSchema: z.ZodEnum<{
|
|
|
22
22
|
localhost: "localhost";
|
|
23
23
|
}>;
|
|
24
24
|
export declare const DashboardConfigSchema: z.ZodDefault<z.ZodObject<{
|
|
25
|
-
enabled: z.ZodDefault<z.ZodBoolean>;
|
|
26
25
|
host: z.ZodDefault<z.ZodEnum<{
|
|
27
26
|
"127.0.0.1": "127.0.0.1";
|
|
28
27
|
localhost: "localhost";
|
|
@@ -111,7 +110,6 @@ export declare const OpenTeamConfigSchema: z.ZodObject<{
|
|
|
111
110
|
off: "off";
|
|
112
111
|
}>>;
|
|
113
112
|
dashboard: z.ZodDefault<z.ZodObject<{
|
|
114
|
-
enabled: z.ZodDefault<z.ZodBoolean>;
|
|
115
113
|
host: z.ZodDefault<z.ZodEnum<{
|
|
116
114
|
"127.0.0.1": "127.0.0.1";
|
|
117
115
|
localhost: "localhost";
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"schema.d.ts","sourceRoot":"","sources":["../../src/config/schema.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB,eAAO,MAAM,cAAc;;;iBAGzB,CAAC;AAEH,eAAO,MAAM,gBAAgB;;;;EAA6C,CAAC;AAC3E,eAAO,MAAM,iBAAiB;;;;EAI5B,CAAC;AACH,eAAO,MAAM,kBAAkB;;;EAA6B,CAAC;AAE7D,eAAO,MAAM,mBAAmB;;;EAAqC,CAAC;AAEtE,eAAO,MAAM,qBAAqB
|
|
1
|
+
{"version":3,"file":"schema.d.ts","sourceRoot":"","sources":["../../src/config/schema.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB,eAAO,MAAM,cAAc;;;iBAGzB,CAAC;AAEH,eAAO,MAAM,gBAAgB;;;;EAA6C,CAAC;AAC3E,eAAO,MAAM,iBAAiB;;;;EAI5B,CAAC;AACH,eAAO,MAAM,kBAAkB;;;EAA6B,CAAC;AAE7D,eAAO,MAAM,mBAAmB;;;EAAqC,CAAC;AAEtE,eAAO,MAAM,qBAAqB;;;;;;;;;;kBAgB9B,CAAC;AAWL,eAAO,MAAM,kBAAkB;;;;;;;;;;;;;;;;;iBAM7B,CAAC;AAEH,eAAO,MAAM,oBAAoB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;iBA2D/B,CAAC;AAEH,MAAM,MAAM,QAAQ,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,cAAc,CAAC,CAAC;AACtD,MAAM,MAAM,UAAU,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,gBAAgB,CAAC,CAAC;AAC1D,MAAM,MAAM,WAAW,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,iBAAiB,CAAC,CAAC;AAC5D,MAAM,MAAM,cAAc,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,oBAAoB,CAAC,CAAC;AAClE,MAAM,MAAM,YAAY,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,kBAAkB,CAAC,CAAC;AAC9D,MAAM,MAAM,eAAe,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,qBAAqB,CAAC,CAAC"}
|
package/dist/index.js
CHANGED
|
@@ -217,7 +217,6 @@ var PrivacyModeSchema = z.enum([
|
|
|
217
217
|
var BaselineModeSchema = z.enum(["auto", "pinned"]);
|
|
218
218
|
var DashboardHostSchema = z.enum(["127.0.0.1", "localhost"]);
|
|
219
219
|
var DashboardConfigSchema = z.object({
|
|
220
|
-
enabled: z.boolean().default(false),
|
|
221
220
|
host: DashboardHostSchema.default("127.0.0.1"),
|
|
222
221
|
port: z.number().int().min(1024).max(65535).default(4599),
|
|
223
222
|
autoPortFallback: z.boolean().default(true),
|
|
@@ -225,7 +224,6 @@ var DashboardConfigSchema = z.object({
|
|
|
225
224
|
recentRoutes: z.number().int().positive().default(50),
|
|
226
225
|
openBrowser: z.boolean().default(false)
|
|
227
226
|
}).default({
|
|
228
|
-
enabled: false,
|
|
229
227
|
host: "127.0.0.1",
|
|
230
228
|
port: 4599,
|
|
231
229
|
autoPortFallback: true,
|