Restore first-class OMO Slim council support (#1981) (#1982)

cc-switch could already persist arbitrary OMO Slim agent keys and top-level fields, but the built-in metadata and UI copy still reflected the pre-council agent set. This made the upstream council feature look unsupported and pushed users toward manual JSON-only setup.

Promote council to a built-in OMO Slim agent, add copy that points top-level plugin settings at Other Fields, and lock the behavior with regression tests.

Constraint: oh-my-opencode-slim exposes council through both agents.council and top-level council config
Rejected: Add a dedicated council editor UI now | too much surface area for issue #1981
Confidence: high
Scope-risk: narrow
Reversibility: clean
Directive: Keep OMO Slim built-in agent metadata aligned with upstream agent additions before shipping UI support
Tested: pnpm exec vitest run tests/utils/omoConfig.test.ts tests/components/OmoFormFields.mergeCustomModelsIntoStore.test.ts
Tested: pnpm typecheck
Not-tested: End-to-end validation against a live oh-my-opencode-slim installation
Related: farion1231/cc-switch#1981
This commit is contained in:
Dex Miller
2026-04-10 22:36:32 +08:00
committed by GitHub
parent e4b58c7206
commit 3aef5217cb
6 changed files with 78 additions and 12 deletions
@@ -1264,12 +1264,22 @@ export function OmoFormFields({
) : undefined,
maxHeightClass: "max-h-[500px]",
children: (
<Textarea
value={otherFieldsStr}
onChange={(e) => onOtherFieldsStrChange(e.target.value)}
placeholder='{ "custom_key": "value" }'
className="font-mono text-xs min-h-[60px]"
/>
<>
<Textarea
value={otherFieldsStr}
onChange={(e) => onOtherFieldsStrChange(e.target.value)}
placeholder='{ "custom_key": "value" }'
className="font-mono text-xs min-h-[60px]"
/>
{isSlim && (
<p className="mt-1 text-[10px] text-muted-foreground">
{t("omo.slimOtherFieldsHint", {
defaultValue:
"Use this area for top-level OMO Slim config such as council, fallback, multiplexer, disabled_mcps, and todoContinuation.",
})}
</p>
)}
</>
),
})}
</div>