前端修复: - calendar_page: 移除不存在的 JournalEntry.content getter - responsive_scaffold: 移除不存在的 notchThickness 参数 - splash_page: SingleTickerProvider → TickerProvider (多 AnimationController) - profile_page: UserRoleType.name → .code (修复运行时崩溃) - 导入缺失的 user.dart 后端修复: - class_service: generate_class_code 取 UUID 后6位(随机部分)避免碰撞 - diary_role_seed: 移除不存在的 id 列,使用复合主键 ON CONFLICT 基础设施: - config/default.toml: CORS 改为通配符(开发模式) - scripts/dev.sh: 统一启动脚本(自动清理端口) - docs/opendesign/: Open Design 设计规格 HTML 原型稿 验证结果: flutter analyze 0 error, cargo test 77/77 通过, 17个页面全部渲染正常
33 lines
1.0 KiB
Dart
33 lines
1.0 KiB
Dart
// 暖记圆角系统
|
|
// 对齐 Open Design 原型稿 tokens.css: xs(8) / sm(10) / md(16) / lg(22) / xl(28) / pill
|
|
|
|
import 'package:flutter/material.dart';
|
|
|
|
class AppRadius {
|
|
AppRadius._();
|
|
|
|
/// 极小圆角 8px — 小型元素
|
|
static const double xs = 8;
|
|
static BorderRadius get xsBorder => BorderRadius.circular(xs);
|
|
|
|
/// 小圆角 10px — 按钮、输入框
|
|
static const double sm = 10;
|
|
static BorderRadius get smBorder => BorderRadius.circular(sm);
|
|
|
|
/// 中圆角 16px — 卡片、弹窗
|
|
static const double md = 16;
|
|
static BorderRadius get mdBorder => BorderRadius.circular(md);
|
|
|
|
/// 大圆角 22px — 大卡片、底部面板
|
|
static const double lg = 22;
|
|
static BorderRadius get lgBorder => BorderRadius.circular(lg);
|
|
|
|
/// 超大圆角 28px — 模态框、全屏面板
|
|
static const double xl = 28;
|
|
static BorderRadius get xlBorder => BorderRadius.circular(xl);
|
|
|
|
/// 胶囊型 — 标签、Chip
|
|
static const double pill = 100;
|
|
static BorderRadius get pillBorder => BorderRadius.circular(pill);
|
|
}
|