Skip to content

Commit 2a4bbc2

Browse files
samuelcoleclaude
andauthored
Give the sidebar a calm main view, with everything technical in Settings (#106)
The sidebar was a stack of eleven boxed panels led by bridge setup and model providers. It now opens on a welcome card that names the agent sites run on (Harbor's lighthouse for the built-in model, a sparkle for the person's own agent) with a Change link, over a calm horizon. Below it: Agent sessions, shown only while there are some; Activity, Site permissions and Browser agent capabilities, collapsed; and a Settings row. The bridge speaks up only when it's down, as a notice at the top. The page no longer repeats the "Harbor" title the browser's sidebar header shows. Settings is a view inside the sidebar: Your agent; Harbor's built-in model, with Model (was LLM Providers), Tools (was MCP Servers, with the directory link that was Quick Actions) and App credentials, hidden while sites run on the person's own agent; and Developer, with bridge status, Reload Harbor and the tool tester. Sections no longer sit in boxes, copy is sentence case without protocol names, and 51 style rules that matched nothing are gone. The docs and whitepaper/build.html point to the new locations. Part 4 of docs/PERMISSIONS.md (for users) now describes the sidebar and permission prompt as they are, with designed-but-unbuilt pieces under "Not built yet"; its session rows pointed to "Stop" and "Stop All" controls that never existed. Fixes HBR-143 Co-Authored-By: Claude Opus 5.5 (Claude Code) <noreply@anthropic.com>
1 parent 1184213 commit 2a4bbc2

14 files changed

Lines changed: 888 additions & 899 deletions

File tree

‎CHANGELOG.md‎

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
2828
### Changed
2929

3030
- The sidebar, permission prompt, agent-question popup and MCP directory now use the public site's brand: green-tinted ink and rules, report green for links and focus, bright green for the main action, Helvetica Neue headings, soft corners and sentence-case labels. They follow your system's light or dark setting; the sidebar and directory no longer have their own theme switch. Icons come from Lucide, bundled as SVG, instead of emoji, in these pages and in a site's chat panel; a test keeps emoji icons out of the UI sources. `extension/src/design-tokens.css` takes its palette from `whitepaper/styles.css` and writes each color once with `light-dark()`. It was a duplicated copy of itself with 32 unused tokens and 64 unused classes; those are gone. The Safari build now needs Safari 17.5, the first with `light-dark()`.
31+
- The sidebar opens on a welcome card that names the agent sites run on, with Harbor's lighthouse for the built-in model, and a **Change** link. Below it are Activity, Site permissions and Browser agent capabilities, all collapsed, then Settings. Agent sessions appear only while there are some. The bridge's status no longer sits at the top: a notice appears only when Harbor can't reach it. Everything technical moved into Settings, a view inside the sidebar: **Your agent**; **Harbor's built-in model**, with Model (was LLM Providers), Tools (was MCP Servers, now with the directory link that was Quick Actions) and App credentials, hidden while sites run on your own agent because only the built-in model uses them; and **Developer**, with bridge status, Reload Harbor and the tool tester. Sections no longer sit in boxes, and the page doesn't repeat the "Harbor" title the browser's sidebar header already shows. The docs and the public site's setup page point to the new locations.
3132
- A site's `model:prompt` and `model:tools` allows are kept per backend. After you switch between the built-in model and an agent, or between agents, the site has to ask again, and the prompt names where its requests will go; switching back restores the earlier allow. A deny applies whichever backend is selected. Switching also ends the site's open text sessions and its `agent.sessions` sessions that use a model, whichever backend they ran on, and cancels its running `agent.run`.
3233
- With an agent selected, the permission prompt says "This site's AI requests go to <agent>, your own agent", shows prompts and tools as one row, and rates it medium risk, since the site gets an agent that can use its tools.
3334
- `agent.requestPermissions()` waits up to 5 minutes for an answer, up from 30 seconds. If the page stops waiting first, its answer is discarded, so a late Allow grants nothing.
@@ -46,6 +47,10 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
4647

4748
### Fixed
4849

50+
- The permissions guide's part for users (`docs/PERMISSIONS.md`, Part 4) described a sidebar that never shipped: four tabs, a policy editor with presets and export, "Make this automatic" in Activity, and dedicated egress and sensitive-action prompts. It now describes the sidebar and permission prompt as they are, and lists the rest under "Not built yet".
51+
- Styles in the sidebar and directory that pointed at tokens Harbor never defined (`--color-surface-tertiary`, `--color-success-bg`, `--border` and six others) now use defined ones, so those backgrounds and rules render.
52+
- The directory's "installed, stopped" badge was filled with the muted text color, so its label was nearly unreadable.
53+
- Scrollbars in Harbor's pages follow the theme in Firefox. They were styled only with `-webkit-` rules, which Firefox ignores.
4954
- A policy refusal while creating a session (`agent.sessions.create()` or `agent.requestCapabilities()`: a deny rule, a quarantined site, a declined prompt) reached the page as `ERR_INTERNAL`. It now keeps the policy engine's code (`ERR_BLOCKED_BY_POLICY`, `ERR_QUARANTINED`, `ERR_PERMISSION_DENIED`), as other page calls already did.
5055
- `agent.requestCapabilities()` left out nothing: an `optional` capability the site hadn't been granted failed the whole request, as if it were required. It's now left out of the session quietly, and `session.capabilities` shows what the session got. `docs/BUILDING_ON_WEB_AGENTS_API.md`'s example also called `session.tools.call(...)`, which doesn't exist; it now uses `session.callTool(...)`.
5156
- Styles in the sidebar and directory that pointed at tokens Harbor never defined (`--color-surface-tertiary`, `--color-success-bg`, `--border` and six others) now use defined ones, so those backgrounds and rules render.

‎QUICKSTART.md‎

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -147,15 +147,15 @@ After [building everything](#build-everything) with `npm run build:safari`, foll
147147
148148
## Verify Your Setup
149149
150-
Open the **Harbor** sidebar using its toolbar icon or Firefox's sidebar selector. Confirm **Bridge: Connected**. If disconnected, see [Troubleshooting](#troubleshooting).
150+
Open the **Harbor** sidebar using its toolbar icon or Firefox's sidebar selector. It opens on a welcome card. If Harbor can't reach its bridge, a notice above the card says so; see [Troubleshooting](#troubleshooting). **Settings → Developer → Bridge** shows the connection either way.
151151
152152
### Configure a Model
153153
154154
When Apple Intelligence is available, you can use it immediately. To use another model, configure it below. Harbor honors your saved default.
155155
156-
1. In the Harbor sidebar, expand **LLM Providers** and find **Configured Models**.
156+
1. In the Harbor sidebar, open **Settings → Harbor's built-in model → Model** and find **Your models**. (This section is hidden while sites run on your own agent; choose **Harbor (built-in model)** under **Your agent** first.)
157157
2. In **Select a model to add...**, select the Ollama model you downloaded (for example, `llama3.2`). If it is missing, click the refresh button next to **Add** and check that Ollama is running.
158-
3. Click **Add**. Confirm the model now appears under **Configured Models**. The header should show a model count rather than **No models configured**.
158+
3. Click **Add**. Confirm the model now appears under **Your models**. The header should show a model count rather than **No models configured**.
159159
4. Confirm the model has the **Default** badge. If necessary, click its star button (**Set as default**); the demos use the default when no model is specified.
160160
5. Click the lightning button (**Test connection**) next to the model and confirm the **Model works!** message before opening the demo.
161161

‎README.md‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@ With the Web Agent API:
5050

5151
**Get Harbor running in 10 minutes.**
5252

53-
Follow **[QUICKSTART.md](QUICKSTART.md)** for the canonical setup: build the extension and the bridge, load Firefox, and run the demos. On supported Macs, Apple Intelligence supplies a default as soon as the on-device model is ready. For another provider, add and test a model under **LLM Providers → Configured Models**.
53+
Follow **[QUICKSTART.md](QUICKSTART.md)** for the canonical setup: build the extension and the bridge, load Firefox, and run the demos. On supported Macs, Apple Intelligence supplies a default as soon as the on-device model is ready. For another provider, add and test a model under **Settings → Harbor's built-in model → Model**.
5454

5555
The guide also covers the Getting Started demo's **Agentic Tool Use** setting and site permissions. A detected Ollama provider alone does not mean a model is configured.
5656

‎demo/web-agents/bring-your-chatbot/README.md‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ browser — opens the chat surface instead. The page writes no chat UI of its ow
1717
Harbor draws the chat panel on the page. Because the page could reach that panel, Harbor
1818
treats every message in it as the site's prompt. Your first message prompts Harbor to ask,
1919
once, whether the site may send prompts to your model (`model:prompt`). If you've selected
20-
an agent in Harbor's sidebar (the **Agent** panel, next to LLM Providers), the chat answers
20+
an agent in Harbor's sidebar (**Settings → Your agent**), the chat answers
2121
from that agent instead — with whatever it can do in your setup, including its tools and
2222
what it remembers about you — and the permission prompt says so. Either way, replies are
2323
grounded in the page's visible text (the product grid), not the MCP tools this page

‎docs/ACP_BACKEND_DESIGN.md‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -72,7 +72,7 @@ Safari reaches the bridge over HTTP without streaming. The ACP backend is Firefo
7272
| `agent.tools.list` / `agent.tools.call`, `navigator.modelContext` | Harbor. These are about the page's and Harbor's tools, not about who runs the loop. |
7373
| Browser-control APIs | Harbor. Unchanged. |
7474

75-
**When an agent is selected, everything that uses a model runs on it (maintainer decision, 2026-11-19).** Every page call in the table above does, and nothing reaches Harbor's built-in model: the extension API refuses `llm.chat` and `llm.chatStream` while an agent is selected (`ERR_AGENT_FAILED`), so a path that misses the agent fails instead of quietly using the built-in model. Switching agents, or between an agent and the built-in model, ends every open text session and every `agent.sessions` session with model access, whichever backend it ran on: a later prompt on one gets `ERR_SESSION_NOT_FOUND`, and Harbor's session registry terminates the `agent.sessions` ones too. A tools-only `agent.sessions` session isn't affected. When Harbor's registry ends an `agent.sessions` session on its own (it expired, or sat idle for an hour), the agent process behind it ends too, freeing the site's agent slot. The sidebar hides **LLM Providers** while an agent is selected, since its settings do nothing then.
75+
**When an agent is selected, everything that uses a model runs on it (maintainer decision, 2026-11-19).** Every page call in the table above does, and nothing reaches Harbor's built-in model: the extension API refuses `llm.chat` and `llm.chatStream` while an agent is selected (`ERR_AGENT_FAILED`), so a path that misses the agent fails instead of quietly using the built-in model. Switching agents, or between an agent and the built-in model, ends every open text session and every `agent.sessions` session with model access, whichever backend it ran on: a later prompt on one gets `ERR_SESSION_NOT_FOUND`, and Harbor's session registry terminates the `agent.sessions` ones too. A tools-only `agent.sessions` session isn't affected. When Harbor's registry ends an `agent.sessions` session on its own (it expired, or sat idle for an hour), the agent process behind it ends too, freeing the site's agent slot. The sidebar hides the **Harbor's built-in model** group (Model, Tools and App credentials) while an agent is selected, since its settings do nothing then.
7676

7777
How a run maps onto ACP:
7878

@@ -140,7 +140,7 @@ Harbor decides whether a site may use the person's agent. It doesn't decide how
140140

141141
### 5. Choosing the backend
142142

143-
- The sidebar gets an **Agent** panel, next to LLM Providers: a choice of *Harbor (built-in model)* or one of the configured ACP agents. Selecting an agent writes `harbor_agent_backend`; selecting the built-in choice clears it.
143+
- The sidebar gets an **Agent** panel (now **Settings → Your agent**, above the built-in model's settings): a choice of *Harbor (built-in model)* or one of the configured ACP agents. Selecting an agent writes `harbor_agent_backend`; selecting the built-in choice clears it.
144144
- Three presets ship together: goose (`goose acp`), Claude Code (`npx -y @agentclientprotocol/claude-agent-acp@0.108.1`) and Codex (`npx -y @agentclientprotocol/codex-acp@2.7.0`). Each uses the user's own install and account. A user can also add any other ACP agent as a custom entry (name, command, arguments).
145145
- A preset — like a custom entry — is a start command only. It sets no approval mode and no environment; those stay the person's own, configured in the agent's own harness (section 3).
146146
- When a preset is added, its bare command is resolved with the bridge's `acp.resolve_command`, and the absolute path is stored when the bridge found one; otherwise the bare command is kept, exactly as the preset ships. That keeps the saved record from depending on the person's shell `PATH` at `acp.open` time.

0 commit comments

Comments
 (0)