| 1 | # Settings Components DOX |
| 2 | |
| 3 | ## Purpose |
| 4 | |
| 5 | - Own WebUI settings shell and built-in settings subsections. |
| 6 | |
| 7 | ## Ownership |
| 8 | |
| 9 | - `settings.html` and `settings-store.js` own the settings shell and state. |
| 10 | - Subdirectories own settings areas such as agent, external, developer, MCP, backup, plugins, secrets, skills, tunnel, and A2A. |
| 11 | - `mcp/client/` owns the global/project MCP server manager, server search, raw JSON editor surface, examples modal, server tool detail modal, MCP scanner modal, scan checks, and scan prompt assets. |
| 12 | - `skills/` owns skill listing, importing, standalone skill scanning, uploaded archive scan preparation UI, scanner modal, scan checks, and scan prompt assets. |
| 13 | |
| 14 | ## Local Contracts |
| 15 | |
| 16 | - Keep settings payloads synchronized with backend APIs and plugin settings contracts. |
| 17 | - Settings tabs that expose plugin `settings_sections` must mount `settings/plugins/plugins-subsection.html` with matching `data-tab` and sidebar/nav section IDs. |
| 18 | - Do not store secrets in localStorage, URLs, or console output. |
| 19 | - Preserve Store Gating and modal footer conventions in settings components. |
| 20 | - Interface control visibility is edited as a Save/Cancel draft, persisted with instance settings, and applied through the shared frontend preference store after Settings saves successfully. |
| 21 | - Bundled controls contributed by plugins add their Interface row through |
| 22 | `interface-controls-end` and register visibility defaults with the shared |
| 23 | preference store. |
| 24 | - MCP manager tool toggles write `disabled_tools` into the draft JSON and require Apply before changing the running MCP tool set. |
| 25 | - Confirmed MCP server removals apply immediately and refresh server status; other MCP manager draft edits still require Apply. |
| 26 | - MCP manager local command forms accept shell-style command and argument lines; quote argument values that intentionally contain spaces. |
| 27 | |
| 28 | ## Work Guidance |
| 29 | |
| 30 | - Prefer subsection-local stores for complex settings areas. |
| 31 | - Coordinate plugin settings UI changes with `webui/components/plugins/` and `plugins/AGENTS.md`. |
| 32 | - Keep MCP scanner checks and prompt assets close to the MCP client modal so scanner behavior remains reviewable with the UI that invokes it. |
| 33 | - Keep Skills scanner checks and prompt assets close to the Skills settings section so scanner behavior remains reviewable with import and standalone scan entry points. |
| 34 | - Keep MCP manager search and toggle affordances consistent between global and project scope because both are rendered by the same client modal. |
| 35 | |
| 36 | ## Verification |
| 37 | |
| 38 | - Smoke-test changed settings tabs, Interface mobile/desktop selectors, and save/reload behavior after visible or API changes. |
| 39 | |
| 40 | ## Child DOX Index |
| 41 | |
| 42 | No child DOX files. |