Native window chrome: one title row on every OS (no stacked bars), a contract every desktop app follows
维护者通常 1 天内回复
还没有人认领这个 Issue。
评估
- 难度
- 5/5
- 预计耗时
- 一周以上
- 新手友好度
- 15/100
- Issue 类型
- 功能
- 描述清晰度
- 基本清楚
- 活跃度
- 活跃
- 技术栈
- css, typescript
- 领域
- design, desktop-dev, frontend
调研方向
Start with the existing Windows WindowControls.svelte and the Svelte 5 component conventions in the kit, since that is the one piece of prior art the issue names. Read the per-OS rules table as the spec for TitleRow, CaptionButtons, AppMenu and the platform probe, and settle the token names (--title-row, --window-pad) before writing components. Done looks like the components and rules doc landing with the per-OS light/dark screenshot matrix and visual tests in the kit gate, then the Linux one-row fix in codeatlasdev/atlas#269. This is a design proposal spanning many files and three operating systems, so it needs a maintainer to scope it down before anyone starts.
由索引模型根据 Issue 内容生成。
描述
Why
Atlas Desktop (Tauri) runs on macOS, Windows and Linux. Each app currently decides its window chrome by itself, and on Linux the result looks improvised: a native title bar, then a GTK menubar ("Atlas File Edit View Go Window Help") in an otherwise empty band, then the page's own drag row. That is three stacked bars (codeatlasdev/atlas#269). A native app built on @codeatlasdev/ui should look deliberate everywhere, and the kit is where that rule should live, so every app gets it for free.
Proposal: a WindowChrome contract in the kit
One title row, drawn by the page, on every OS. The rules:
| macOS | Windows | Linux (GNOME, KDE, …) | Linux tiling (Hyprland, Sway, i3) | |
|---|---|---|---|---|
| Native title bar | overlay (traffic lights inside the row) | none (decorations: false) |
none | none |
| Native menubar | the system's own, at the top of the screen | none | none | none |
| Caption buttons | system traffic lights | page-drawn, right, Windows 11 metrics | page-drawn, order and side from gtk-decoration-layout / button-layout |
hidden: the WM owns the window |
| Drag / double-click | title row | title row → maximize | title row → maximize | n/a |
| Menu commands | menubar plus palette | palette plus a ⋯ app menu in the row |
palette plus ⋯ |
palette plus ⋯ |
Components and tokens:
TitleRowwith drag region, slots (leading, title, trailing), height token--title-row, and the window pad--window-pad.CaptionButtons(min / max-restore / close): per-OS glyphs, hit areas that reach the screen edge (Fitts), hover and pressed states, a red close on Windows, symbolic icons on GNOME.AppMenu(⋯): every command of the old native menu, with its shortcut; the same source as the command palette.- A platform probe the app passes in (
os,tiling,buttonLayout,prefersReducedTransparency), never sniffed fromnavigator.platformalone. - Rules doc: no stacked bars, never an empty band, one row of max
--title-rowheight, focus order, a11y names for the caption buttons, and what to test (drag, double-click, resize edges, fullscreen F11, RTL).
Acceptance
- The components and tokens in the kit, documented with a per-OS screenshot matrix.
- A visual test per OS and theme (light and dark) in the kit's gate.
- Atlas Desktop adopts it: Linux shows one row (codeatlasdev/atlas#269), and Windows moves its
WindowControls.svelteinto the kit.
- 主要语言
- TypeScript
- 星标
- 6
- 派生
- 3
- 平均合并
- 5 小时 21 分钟
- 30 天内合并 PR
- 378
环境准备
- 没有 Dockerfile 或 Docker Compose 文件
- 有 Pull Request 模板
- 阅读贡献指南
从这里开始
- 先读完整个 Issue,再读项目的贡献指南。
- 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
- Fork 仓库,在一个分支上完成修改。
- 提交 Pull Request,并在描述里引用这个 Issue 编号。
codeatlasdev/ui 的其他 Issue
-
难度 2/5 1-3 小时 新手友好度 84/100
codeatlasdev/ui#1340 ·
维护者通常 1 天内回复
-
area:a11y area:components bug
难度 2/5 1-3 小时 新手友好度 76/100
codeatlasdev/ui#1336 ·
维护者通常 1 天内回复
-
难度 2/5 1-3 小时 新手友好度 77/100
codeatlasdev/ui#1329 ·
维护者通常 1 天内回复
-
good first issue
难度 2/5 1-3 小时 新手友好度 74/100
codeatlasdev/ui#1292 · 1 条评论 ·
维护者通常 1 天内回复
-
area:components enhancement good first issue
难度 2/5 1-3 小时 新手友好度 68/100
codeatlasdev/ui#1198 ·
维护者通常 1 天内回复
相似的 Issue
-
难度 1/5 1 小时以内 新手友好度 86/100
sandbox-quantum/switch#2163 ·
维护者通常 1 天内回复
-
automated issue report
难度 1/5 1 小时以内 新手友好度 78/100
维护者通常 1 天内回复
-
area/dashboard kind/bug QA/dev-automation
难度 1/5 1 小时以内 新手友好度 75/100
维护者通常 1 天内回复
-
bug pydanty:is-working
难度 2/5 1-3 小时 新手友好度 82/100
pydantic/pydantic-ai#13939 ·
维护者通常 1 天内回复
-
self-host
难度 2/5 1-3 小时 新手友好度 70/100
funmusicplace/mirlo#2625 ·
维护者通常 1 天内回复