web: add chat model picker, agent badges and a preloaded brief
Show the current model under the chat title with an OpenCode-backed picker, put an agent mark on the right of every chat row, simplify the tool summary to 'N tools', and give the reasoning and tool controls one symmetric hover box. New chats preload an editable behavior brief, and the activity spinner remains the turn's single live progress indicator.
This commit is contained in:
+128
-36
@@ -63,6 +63,22 @@
|
||||
}
|
||||
.chat-create-directories-error { color: var(--bad); }
|
||||
.chat-create-error { color: var(--bad); font-size: 13px; }
|
||||
.chat-create-instructions { display: grid; gap: 6px; }
|
||||
.chat-create-instructions-label { font-size: 13px; font-weight: 600; }
|
||||
.chat-create-instructions-input {
|
||||
width: 100%;
|
||||
min-height: 96px;
|
||||
padding: 10px 12px;
|
||||
resize: vertical;
|
||||
background: var(--color-surface-2);
|
||||
color: var(--color-text);
|
||||
border: 1px solid var(--color-border);
|
||||
border-radius: var(--radius-control);
|
||||
font: inherit;
|
||||
font-size: 13px;
|
||||
line-height: 1.5;
|
||||
}
|
||||
.chat-create-instructions-helper { margin: 0; font-size: 12px; line-height: 1.5; max-width: 64ch; }
|
||||
.chat-create-model-note { margin: 0; font-size: 12px; line-height: 1.5; max-width: 64ch; }
|
||||
.chat-create-footer {
|
||||
display: flex;
|
||||
@@ -340,10 +356,78 @@
|
||||
.chat-create { overflow-y: auto; overscroll-behavior: contain; }
|
||||
.chat-bar { flex: 0 0 auto; display: flex; gap: var(--space-s); align-items: center; justify-content: space-between; }
|
||||
.chat-bar-titles { display: grid; gap: 2px; min-width: 0; }
|
||||
.chat-bar-title { margin: 0; font-size: 16px; }
|
||||
.chat-bar-title {
|
||||
margin: 0;
|
||||
font-size: 16px;
|
||||
min-width: 0;
|
||||
overflow: hidden;
|
||||
text-overflow: ellipsis;
|
||||
white-space: nowrap;
|
||||
}
|
||||
.chat-bar-meta { font-size: 12px; }
|
||||
.chat-context { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; font-size: 12px; color: var(--muted); }
|
||||
.chat-load-older { white-space: nowrap; font-size: 12px; }
|
||||
.chat-model-button {
|
||||
display: inline-flex;
|
||||
align-items: center;
|
||||
gap: 5px;
|
||||
flex: none;
|
||||
max-width: 150px;
|
||||
min-width: 0;
|
||||
padding: 4px 8px;
|
||||
border: 1px solid var(--border);
|
||||
border-radius: var(--radius-control);
|
||||
background: var(--surface-2);
|
||||
color: var(--muted);
|
||||
font-size: 12px;
|
||||
}
|
||||
.chat-model-button:hover { background: var(--color-elevated); color: var(--text); }
|
||||
.chat-model-button-label {
|
||||
min-width: 0;
|
||||
overflow: hidden;
|
||||
text-overflow: ellipsis;
|
||||
white-space: nowrap;
|
||||
}
|
||||
.chat-model-button .chevron { flex: none; font-size: 10px; }
|
||||
/* Model picker: a bounded list of the current harness's models. */
|
||||
.chat-model-panel { width: min(480px, 100%); max-height: calc(100dvh - 48px); }
|
||||
.chat-model-helper { margin: 0; font-size: 12px; }
|
||||
.chat-model-loading { display: flex; gap: 8px; align-items: center; color: var(--muted); font-size: 13px; }
|
||||
.chat-model-error { margin: 0; color: var(--bad); font-size: 12px; }
|
||||
.chat-model-empty { margin: 0; font-size: 13px; }
|
||||
.chat-model-list {
|
||||
display: grid;
|
||||
gap: 2px;
|
||||
max-height: min(50vh, 420px);
|
||||
overflow-y: auto;
|
||||
overscroll-behavior: contain;
|
||||
border: 1px solid var(--border);
|
||||
border-radius: var(--radius-card);
|
||||
padding: 4px;
|
||||
}
|
||||
.chat-model-option {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
gap: 8px;
|
||||
width: 100%;
|
||||
min-height: 38px;
|
||||
padding: 7px 9px;
|
||||
border: 1px solid transparent;
|
||||
border-radius: var(--radius-control);
|
||||
background: transparent;
|
||||
text-align: left;
|
||||
}
|
||||
.chat-model-option:hover { background: var(--tint-hover); color: var(--text); }
|
||||
.chat-model-option.selected { border-color: var(--accent); background: var(--tint-selected); color: var(--text); }
|
||||
.chat-model-option-name {
|
||||
flex: 1 1 auto;
|
||||
min-width: 0;
|
||||
overflow: hidden;
|
||||
text-overflow: ellipsis;
|
||||
white-space: nowrap;
|
||||
}
|
||||
.chat-model-option-provider { flex: none; font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: 11px; }
|
||||
.chat-model-check { flex: none; color: var(--accent); }
|
||||
.chat-transcript-empty { padding: 24px 12px; }
|
||||
|
||||
.chat-transcript-wrap { position: relative; flex: 1 1 auto; min-height: 0; overflow: hidden; }
|
||||
@@ -400,16 +484,6 @@
|
||||
white-space: nowrap;
|
||||
}
|
||||
.chat-turn-agent { flex-direction: column; align-items: flex-start; }
|
||||
/* The tool summary is a quiet line next to the message, not a chip inside it. */
|
||||
.chat-tools { margin: 2px 0 10px; }
|
||||
.chat-tool-chip {
|
||||
padding: 2px 0;
|
||||
border: 0;
|
||||
background: transparent;
|
||||
color: var(--muted);
|
||||
font-size: 11px;
|
||||
}
|
||||
.chat-tool-chip:hover { color: var(--color-text); }
|
||||
|
||||
.chat-reasoning { margin-bottom: 8px; padding-bottom: 6px; border-bottom: 1px dashed var(--border); }
|
||||
/* Thinking sits outside and above the answer bubble, like the tool summary
|
||||
@@ -437,18 +511,6 @@
|
||||
.chat-activity-elapsed { flex: none; }
|
||||
.chat-activity-sep { color: var(--muted); flex: none; }
|
||||
.chat-activity-head > .chat-tool-chip { min-width: 0; overflow: hidden; }
|
||||
.chat-reasoning-toggle {
|
||||
display: flex;
|
||||
gap: 6px;
|
||||
align-items: center;
|
||||
flex: none;
|
||||
padding: 2px 0;
|
||||
background: transparent;
|
||||
border: 0;
|
||||
color: var(--muted);
|
||||
font-size: 12px;
|
||||
}
|
||||
.chat-reasoning-toggle:hover { color: var(--text); }
|
||||
.chat-reasoning-body {
|
||||
margin: 6px 0 2px;
|
||||
white-space: pre-wrap;
|
||||
@@ -461,24 +523,44 @@
|
||||
|
||||
/* The tool-call chip and its panel (C6). The panel is a fixed overlay, so it
|
||||
never joins the transcript's flow and opening it cannot re-flow or scroll it. */
|
||||
/* Thinking and tools are sibling controls on the same line, so they share one
|
||||
hover/focus box: identical padding, radius, height and background. */
|
||||
.chat-reasoning-toggle,
|
||||
.chat-tool-chip {
|
||||
display: inline-flex;
|
||||
align-items: center;
|
||||
gap: 6px;
|
||||
padding: 2px 0;
|
||||
border: 0;
|
||||
flex: none;
|
||||
min-height: 24px;
|
||||
max-width: 100%;
|
||||
min-width: 0;
|
||||
margin: 0;
|
||||
padding: 2px 7px;
|
||||
border: 1px solid transparent;
|
||||
border-radius: var(--radius-control);
|
||||
background: transparent;
|
||||
color: var(--muted);
|
||||
font-size: 11px;
|
||||
font: inherit;
|
||||
font-size: 12px;
|
||||
line-height: 16px;
|
||||
text-align: left;
|
||||
cursor: pointer;
|
||||
}
|
||||
.chat-tool-chip:hover { color: var(--color-text); }
|
||||
.chat-reasoning-toggle:hover,
|
||||
.chat-tool-chip:hover {
|
||||
background: var(--tint-hover);
|
||||
color: var(--color-text);
|
||||
}
|
||||
.chat-reasoning-toggle:focus-visible,
|
||||
.chat-tool-chip:focus-visible {
|
||||
outline: 2px solid var(--accent);
|
||||
outline-offset: 1px;
|
||||
}
|
||||
.chat-tool-chip-failed { border-color: var(--bad); color: var(--bad); }
|
||||
.chat-tool-icon { font-size: 12px; line-height: 1; }
|
||||
.chat-tool-icon-failed { color: var(--bad); }
|
||||
.chat-tool-long { color: var(--bad); }
|
||||
.chat-tool-chevron { color: var(--muted); }
|
||||
.chat-tool-spinner { width: 11px; height: 11px; border-width: 2px; }
|
||||
|
||||
/* C5: the in-flight turn's indicator, under the transcript after the last agent
|
||||
turn — a spinner, the phase headline, the turn's elapsed and one line per
|
||||
@@ -1027,6 +1109,8 @@
|
||||
.chat-group-directory .chat-group-title { font-size: 12px; }
|
||||
.chat-row { min-height: 96px; }
|
||||
.chat-row .row-head { padding-right: 50px; }
|
||||
.chat-backend-logo { width: 22px; height: 22px; }
|
||||
.chat-backend-logo svg { width: 20px; height: 20px; }
|
||||
.chat-star {
|
||||
top: 2px;
|
||||
right: 2px;
|
||||
@@ -1044,6 +1128,7 @@
|
||||
.chat-row-actions .chat-menu-item { padding: 8px 12px; font-size: 14px; }
|
||||
.back-button .back-chevron { width: 24px; height: 24px; }
|
||||
.chat-bar-title { font-size: 18px; }
|
||||
.chat-model-button { max-width: 118px; min-height: 36px; }
|
||||
.chat-activity { font-size: 12px; }
|
||||
.chat-send,
|
||||
.chat-stop { min-width: 44px; min-height: 44px; font-size: 18px; }
|
||||
@@ -1056,6 +1141,21 @@
|
||||
.chat-create-backends { display: flex; flex-wrap: wrap; gap: 8px; }
|
||||
.chat-create-backend { padding: 6px 12px; border: 1px solid var(--border); color: var(--muted); }
|
||||
.chat-create-backend.selected { border-color: var(--accent); background: var(--tint-selected); color: var(--text); }
|
||||
.chat-backend-logo {
|
||||
display: inline-flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
flex: none;
|
||||
margin-left: auto;
|
||||
width: 20px;
|
||||
height: 20px;
|
||||
color: var(--muted);
|
||||
}
|
||||
.chat-backend-logo svg { width: 18px; height: 18px; display: block; }
|
||||
.chat-backend-logo.chat-backend-opencode { color: var(--accent); }
|
||||
.chat-backend-logo.chat-backend-codex { color: #9ecb8f; }
|
||||
.chat-backend-logo.chat-backend-claude { color: #d8b46a; }
|
||||
.chat-backend-logo.chat-backend-pi { color: #c58fb0; }
|
||||
.chat-backend-chip {
|
||||
flex: 0 0 auto;
|
||||
padding: 1px 6px;
|
||||
@@ -1070,14 +1170,6 @@
|
||||
|
||||
/* The current tool call shares the count line. It is the one live element on
|
||||
that row, so tool handoffs do not add or remove a second status line. */
|
||||
.chat-tool-chip {
|
||||
display: inline-flex;
|
||||
align-items: center;
|
||||
gap: 4px;
|
||||
max-width: 100%;
|
||||
min-width: 0;
|
||||
text-align: left;
|
||||
}
|
||||
.chat-tool-current {
|
||||
min-width: 0;
|
||||
overflow: hidden;
|
||||
|
||||
Reference in New Issue
Block a user