6238b86dcb
- 登录/注册(login.html/register.html 1:1):两栏卡片+品牌渐变面板+主题小衣服 pill(onSurface 变体)+记住我(记录并预填最近账号)+原型式 toast 校验; 登录 fidelity 1.4–2.1% 三主题全绿;注册暂不入闸(少 门店编号/兑换券 字段, 已记 CONTRACT,screens.mjs 留存根) - ds 原子补齐:DsToast(.toast 单例)/DsCheck(.check/.agree)/DsButton lg 档/ DsSelect 替换全部旧 DropdownButton/DsField label 在上/DsInput 后缀与密码形态 - 全屏统一:对话框按钮全 DsButton、盒式输入主题钉死(visualDensity.standard、 h38、InputDecorationTheme 渗漏修复)、图标全 lucide、JetBrains Mono 三端同源、 BrandMark 真相源 logo、只读模式写操作全量守卫(WriteGuard+DsToast) - 出入库列表:版式对齐原型(卡片对齐+搜索框居中)、KPI 近30天滚动、结清后 失效财务应收应付表;商品编辑抽屉介绍库改搜索下拉、图片双击全屏预览 - 删除旧 UI 死代码:DataTableCard/FormDialog/PageScaffold/SearchChip/ SelectProductDialog/tabStateProvider - golden/fidelity:stock-in/out 补注册(9%)、login 入册(8%)、goldens 全量重打; 修复 pubspec flutter_web_plugins 非法声明(CI pub get 阻断) Co-Authored-By: Claude Fable 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01JJ1g8XV1YhhmHRzhwWEW7o
59 lines
2.0 KiB
Dart
59 lines
2.0 KiB
Dart
// widgets/brand_mark.dart — 品牌 logo 真相源(镜像原型 about.html hero SVG)。
|
||
// 原型 64×64 viewBox:rx15 深蓝底 #0F3057 + 白描边(4, round) 山形
|
||
// M14 33→23 16→32 25→41 16→50 33 + 横线 y41(x15–49) + 横线下居中红点 (32,48) r3
|
||
// #8B2331。品牌资产主题不变(原型 SVG 硬编码,不走主题 token)——勿改配色。
|
||
import 'package:flutter/material.dart';
|
||
|
||
class BrandMark extends StatelessWidget {
|
||
final double size;
|
||
const BrandMark({super.key, this.size = 62});
|
||
|
||
static const Color _bg =
|
||
Color(0xFF0F3057); // ds-ignore: 品牌 logo 固定色(原型 SVG 硬编码,主题不变)
|
||
static const Color _stroke =
|
||
Colors.white; // ds-ignore: 品牌 logo 固定色(原型 SVG 硬编码,主题不变)
|
||
static const Color _dot =
|
||
Color(0xFF8B2331); // ds-ignore: 品牌 logo 固定色(原型 SVG 硬编码,主题不变)
|
||
|
||
@override
|
||
Widget build(BuildContext context) {
|
||
return Container(
|
||
width: size,
|
||
height: size,
|
||
decoration: BoxDecoration(
|
||
color: _bg,
|
||
// 原型 rx15/64
|
||
borderRadius: BorderRadius.circular(size * 15 / 64),
|
||
),
|
||
child: CustomPaint(painter: _MarkPainter()),
|
||
);
|
||
}
|
||
}
|
||
|
||
class _MarkPainter extends CustomPainter {
|
||
@override
|
||
void paint(Canvas canvas, Size size) {
|
||
final s = size.width / 64;
|
||
final stroke = Paint()
|
||
..color = BrandMark._stroke
|
||
..style = PaintingStyle.stroke
|
||
..strokeWidth = 4 * s
|
||
..strokeCap = StrokeCap.round
|
||
..strokeJoin = StrokeJoin.round;
|
||
|
||
final mountain = Path()
|
||
..moveTo(14 * s, 33 * s)
|
||
..lineTo(23 * s, 16 * s)
|
||
..lineTo(32 * s, 25 * s)
|
||
..lineTo(41 * s, 16 * s)
|
||
..lineTo(50 * s, 33 * s);
|
||
canvas.drawPath(mountain, stroke);
|
||
canvas.drawLine(Offset(15 * s, 41 * s), Offset(49 * s, 41 * s), stroke);
|
||
canvas.drawCircle(
|
||
Offset(32 * s, 48 * s), 3 * s, Paint()..color = BrandMark._dot);
|
||
}
|
||
|
||
@override
|
||
bool shouldRepaint(covariant CustomPainter oldDelegate) => false;
|
||
}
|