Files
Unlucky-Launcher/crates/app/ui/theme/metrics.slint
T
AskaEth a5d1dec495
CI / fmt (rustfmt --check) (push) Waiting to run
CI / clippy (ubuntu-latest) (push) Waiting to run
CI / clippy (windows-latest) (push) Waiting to run
CI / test (ubuntu-latest) (push) Waiting to run
CI / test (windows-latest) (push) Waiting to run
CI / build release (ubuntu-latest) (push) Waiting to run
CI / build release (windows-latest) (push) Waiting to run
CI / runtime smoke (ubuntu x64, xvfb) (push) Waiting to run
CI / runtime smoke (macos arm64, probe) (push) Skipped
CI / update-e2e (windows x64) (push) Waiting to run
GPU evidence / GPU 判据自测(不需 GPU;跳过 ≠ 已验证) (push) Waiting to run
GPU evidence / GPU 证据 — 探测可用产物与硬件适配器 (push) Waiting to run
Guards / core 零 UI 守门 (push) Waiting to run
Guards / presenter 零 UI 守门 (push) Waiting to run
Guards / design 零第三方依赖守门 (push) Waiting to run
Guards / unsafe 落点守门(集合必须恰好等于期望) (push) Waiting to run
Guards / 文件行数 ≤400 守门 (push) Waiting to run
Guards / 依赖许可与来源(cargo-deny) (push) Waiting to run
Release guard / 发布标记语义守门(push tag → 稳定版) (push) Waiting to run
Signing status(播报,不是门禁) / 判据自测(三行/退出码/变异重放/接线) (push) Waiting to run
Signing status(播报,不是门禁) / 签名就绪度(播报) (push) Waiting to run
Release / 选槽位(默认四个:Windows 两档 + Linux 两档) (push) Waiting to run
release: v0.2.4 里程碑快照(孤儿提交,无父;树 = dev 68362e5)
本批内容见 CHANGELOG.md 的 0.2.4 段。按 D41 用孤儿快照推 main,保留「公开史只有里程碑」的模型。
2026-11-11 21:41:38 +08:00

49 lines
1.9 KiB
Plaintext

// 布局度量令牌(D16 定稿的尺寸口径集中在此):
// 导航栏折叠宽度、AI 栏宽度、标题栏高度、磁贴三档尺寸与列数。
import { TileSize } from "../models.slint";
export global Metrics {
// 间距刻度(4 的倍数,Metro 栅格)
out property <length> gap-1: 4px;
out property <length> gap-2: 8px;
out property <length> gap-3: 12px;
out property <length> gap-4: 16px;
out property <length> gap-5: 24px;
out property <length> gap-6: 32px;
out property <length> radius-sm: 2px;
out property <length> radius-md: 4px;
out property <length> radius-lg: 8px;
// 主窗口骨架
out property <length> titlebar-height: 40px;
out property <length> titlebar-button-width: 46px;
out property <length> accent-line: 2px;
out property <length> nav-expanded-width: 88px;
out property <length> nav-collapsed-width: 48px;
out property <length> ai-panel-width: 320px;
out property <length> ai-rail-width: 44px;
out property <length> page-header-height: 56px;
out property <length> running-strip-height: 32px;
out property <length> row-height: 44px;
out property <length> control-height: 32px;
out property <length> touch-target: 32px;
// 磁贴三档(Q24-3:默认中磁贴 4 列,设置可调小 6 / 大 3)
in-out property <TileSize> tile-size: TileSize.medium;
out property <int> tile-columns:
tile-size == TileSize.small ? 6
: tile-size == TileSize.large ? 3
: 4;
out property <length> tile-height:
tile-size == TileSize.small ? 104px
: tile-size == TileSize.large ? 176px
: 136px;
out property <length> tile-icon-size:
tile-size == TileSize.small ? 32px
: tile-size == TileSize.large ? 56px
: 44px;
// 小磁贴只留图标+名字+启动键,藏起徽标与最后游玩时间(空间不足)
out property <bool> tile-compact: tile-size == TileSize.small;
}