Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 11 additions & 0 deletions docs/FRONTEND_REBUILD_STATUS.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,17 @@ Baseline: main `71ede3053b1d71f4c6e4f7053b355ebe301c1a1b`, checked on
the first recovery/connection fixes; #286 contributes scoped journey fixes.
Passing those slices does not establish complete product or platform acceptance.

## Neutral glass follow-up — 2026-10-10

PR #294 merged into main `4a5c8909`. The next user-directed visual pass removes
the separate V2 purple accent and decorative yellow/orange/blue/green palettes.
Shared neutral material tokens supply white filled primary controls, dark button
text and high-opacity light/dark/glass surfaces. Semantic errors, code diffs and
terminal ANSI content retain their meaning. The [palette inventory](branding/neutral-glass-palette.md)
records before/after counts, accessibility checks and original browser evidence.
This visual pass leaves the remaining environment, extension and native journey
roadmap below in place.

## Product guidance revision — 2026-10-10

The user's latest direction treats language and information architecture as part
Expand Down
7 changes: 7 additions & 0 deletions docs/PROJECT_MEMORY.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,12 @@
# Prayu Project Memory

> 2026-10-10 neutral glass follow-up: after #294 merged, the user requested removal
> of purple, yellow/orange and other independent decorative palettes. Shared
> light/dark/glass tokens now use neutral high-opacity surfaces, white filled
> primary controls and dark foregrounds. V2 and legacy components share these
> roles; danger, code diffs and terminal ANSI output retain their content meaning.
> See [palette inventory and conventions](branding/neutral-glass-palette.md).

> 2026-10-10 product guidance revision: the frontend rebuild includes user-facing
> language and information hierarchy. The connection hub groups task preparation,
> tools/collaboration and runtime settings; MCP/Plugin/LSP show actual setup stages.
Expand Down
59 changes: 59 additions & 0 deletions docs/branding/neutral-glass-palette.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,59 @@
# 中性玻璃材质与颜色收敛

2026-10-10,按用户对紫色、黄橙色和白色填充的反馈更新。基线为合并
前端重建后的 main `4a5c8909895ce4a1b0b6620f479f9abeb406402e`;它与
`75aceac721c8dfb6911a4540427da7684a02c961` 的文件树相同。

## 来源与盘点口径

截图中的紫色来自 `web/src/v2/styles.css` 的 `--v2-accent: #6b55ed`。
这个独立常量绕过了共享主题,83 条 CSS 声明在 17 个文件中引用该 token。
供应商图标槽、审批与恢复卡片、开关、背景和头像还定义了各自的彩色渐变。

盘点覆盖 `web/src` 中全部 24 个 CSS 文件,以及 TS/TSX 中的颜色常量。
CSS 使用 PostCSS 解析声明,记录 hex、rgb、hsl、white、black 的出现次数、
原始写法和规范化 RGBA。包含回退值与历史定义;这些数量表示维护复杂度。
原始品牌图片、用户内容、第三方编辑器和终端输出使用各自的内容语义。

| 项目 | 清理前 | 清理后 |
| --- | ---: | ---: |
| CSS 颜色字面量出现次数 | 787 | 136 |
| CSS 颜色不同写法 | 521 | 93 |
| CSS 规范化 RGBA 值 | 518 | 93 |
| V2 CSS 颜色出现次数 | 295 | 39 |
| V2 CSS 颜色不同写法 | 165 | 28 |
| 颜色字面量回退次数 | 96 | 0 |
| 闲置供应商 accent 元数据 | 11 | 0 |

清理前,V2 的紫色组为 8 次定义/回退、6 个色值;黄橙棕组为 28 次、24 个
色值,覆盖提示、头像和玻璃缩略图。两组现在均已移除。V2 剩余字面量为
中性阴影与高光。全局彩色 CSS 收敛到 4 个危险/代码差异色值、8 次主题定义。

## 材质约定

- 强调操作使用不透明白色填充 `--prayu-primary-bg`,深色文字
`--prayu-primary-fg`,配合边缘高光、轻阴影和明确边框。hover 使用
`--prayu-primary-hover`。主按钮、图标槽和选中控件一起核对前景与背景。
- light 使用白/浅灰面板;dark 与 glass 使用中性深灰面板。面板填充不透明度
为 88–98%,玻璃强调填充为 86–98%。浅色主按钮在三种主题中保持白底深字。
- 玻璃感来自层次、模糊、细边与反光。移除紫、黄、橙、蓝绿装饰渐变及背景
饱和度放大;V2 的强调色和焦点色直接引用共享主题。
- 普通提示、等待、就绪和连接状态使用中性材质,通过文本、图标和状态标记
传达含义。实际错误与破坏性操作使用共享 danger;代码增删保留 diff 色。
- 终端采用固定中性深色画布、灰白文字和光标,保留六种 ANSI 内容色。
- `prefers-reduced-transparency` 回退到实色并关闭模糊;高对比模式使用明确
边框;forced colors 跟随系统 Canvas、Button 和 Highlight 颜色。

新增组件复用这些语义 token。组件 CSS 使用 `var()` 关联用途,具体颜色值
集中在共享主题。字体、布局、权限、任务状态和用户输出格式沿用原有行为。

## 验证与证据

- 静态检查:颜色变量均有来源,PostCSS/Vite CSS 编译通过。主按钮文字对比
17.224:1,hover 15.114:1;按主题背景范围估算的最低辅助文字对比 5.420:1。
- 前端现有测试:186 文件、1,834 项通过;TypeScript 与生产构建通过。
- 真实 Go API 和隔离数据库提供生产静态资源;浏览器核对三种主题、390px
与 1280px 布局、键盘焦点、降低透明度和系统高对比表现。
- 本地原始截图、逐声明统计、SHA-256 和浏览器计算样式保存在忽略目录
`build/frontend-rebuild/color-audit/` 与 `build/frontend-rebuild/neutral-*`。
浏览器检查覆盖本次材质变更;原生 Windows Acrylic 与壁纸合成仍需实机观察。
2 changes: 1 addition & 1 deletion web/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<meta name="referrer" content="no-referrer" />
<meta name="color-scheme" content="light dark" />
<meta name="theme-color" content="#171614" />
<meta name="theme-color" content="#181818" />
<link rel="icon" type="image/png" sizes="32x32" href="/traverse-board-favicon-32.png" />
<link rel="apple-touch-icon" sizes="180x180" href="/apple-touch-icon.png" />
<title>Universal Code</title>
Expand Down
2 changes: 1 addition & 1 deletion web/src/components/github-review-write-form.css
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
.github-review-thread {
padding: 10px 0;
border-top: 1px solid var(--border);
border-top: 1px solid var(--prayu-border);
overflow-wrap: anywhere;
}

Expand Down
12 changes: 6 additions & 6 deletions web/src/components/inspector-workspace-navigation.css
Original file line number Diff line number Diff line change
Expand Up @@ -2,20 +2,20 @@
.inspector-workspace-common { display: flex; flex-wrap: wrap; gap: 5px; min-width: 0; }
.workspace-tabs.inspector-workspace-navigation button { min-height: 34px; padding: 5px 10px; }
.workspace-tabs.inspector-workspace-navigation .inspector-workspace-expand { margin-left: auto; font-weight: 400; }
.inspector-workspace-groups { display: grid; flex-basis: 100%; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 20px; max-height: min(42vh, 380px); overflow: auto; padding: 12px 0; border-top: 1px solid var(--border, #ddd); }
.inspector-workspace-groups { display: grid; flex-basis: 100%; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 20px; max-height: min(42vh, 380px); overflow: auto; padding: 12px 0; border-top: 1px solid var(--prayu-border); }
.inspector-workspace-groups[hidden] { display: none; }
.inspector-workspace-groups > div { display: flex; flex-direction: column; align-items: stretch; gap: 3px; min-width: 0; }
.inspector-workspace-groups > div > span { font-size: 12px; color: var(--muted, #70747b); padding: 4px 8px; }
.inspector-workspace-groups > div > span { font-size: 12px; color: var(--prayu-muted); padding: 4px 8px; }
.workspace-tabs .inspector-workspace-groups button { text-align: left; white-space: normal; justify-content: start; }
.inspector-workspace-input { border-top: 1px solid var(--border, #ddd); padding: 12px 18px; flex-shrink: 0; }
.inspector-workspace-input { border-top: 1px solid var(--prayu-border); padding: 12px 18px; flex-shrink: 0; }
.inspector-workspace-input > summary, .inspector-workspace-section > summary { cursor: pointer; font-size: 14px; line-height: 1.6; padding: 5px 0; }
.inspector-workspace-input > p, .inspector-repository-heading > p { font-size: 13px; line-height: 1.65; color: var(--muted, #70747b); }
.inspector-workspace-input > p, .inspector-repository-heading > p { font-size: 13px; line-height: 1.65; color: var(--prayu-muted); }
.workspace-view > .inspector-workspace-input > .session-composer { padding-inline: 0; border: 0; margin: 12px 0 0; }
.inspector-session-run-state { display: flex; align-items: center; flex-wrap: wrap; gap: 8px; padding: 8px 18px; font-size: 13px; }
.inspector-repository-heading h2 { font-size: 17px; font-weight: 600; margin: 0; }
.inspector-workspace-section { border-top: 1px solid var(--border, #ddd); padding-top: 8px; min-width: 0; }
.inspector-workspace-section { border-top: 1px solid var(--prayu-border); padding-top: 8px; min-width: 0; }
.inspector-workspace-section[open] > summary { margin-bottom: 12px; }
.inspector-workspace-input > summary:focus-visible, .inspector-workspace-section > summary:focus-visible { outline: 2px solid var(--prayu-focus, #4b8ef7); outline-offset: 3px; }
.inspector-workspace-input > summary:focus-visible, .inspector-workspace-section > summary:focus-visible { outline: 2px solid var(--prayu-focus); outline-offset: 3px; }
@media (max-width: 700px) {
.inspector-workspace-groups { grid-template-columns: minmax(0, 1fr); gap: 12px; }
.workspace-tabs.inspector-workspace-navigation .inspector-workspace-expand { margin-left: 0; }
Expand Down
15 changes: 8 additions & 7 deletions web/src/components/user-terminal-panel.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -69,20 +69,21 @@ export function UserTerminalPanel({ runID, sessionID, onSession }: {
fontSize: 13,
lineHeight: 1.18,
scrollback: 5000,
// Keep the terminal canvas neutral; ANSI colors preserve command-output meaning.
theme: {
background: "#171512",
foreground: "#f2e4cc",
cursor: "#f58231",
cursorAccent: "#171512",
selectionBackground: "#a94b2473",
black: "#171512",
background: "#181818",
foreground: "#ededed",
cursor: "#ededed",
cursorAccent: "#181818",
selectionBackground: "#ffffff38",
black: "#181818",
red: "#ef6b5d",
green: "#8fbf71",
yellow: "#e2b45f",
blue: "#78a9d4",
magenta: "#c792b6",
cyan: "#74b6b0",
white: "#f2e4cc",
white: "#ededed",
},
});
const fit = new FitAddon();
Expand Down
Loading
Loading