feat: 实现导航页基础功能

- 添加导航条目和分类数据模型
- 实现导航卡片网格展示
- 支持点击卡片打开链接
- 添加主题样式(渐变色、卡片阴影)
- 区分系统默认和自定义条目
- 添加分类统计信息"
This commit is contained in:
2026-09-19 21:53:15 +08:00
parent e2cc3ac30f
commit 1c98340fc5
42 changed files with 6054 additions and 140 deletions
@@ -10,6 +10,7 @@ class NavNode {
required this.id,
required this.title,
this.children = const <NavNode>[],
this.editable = false,
});
/// 唯一标识;叶子节点同时也是内容区的锚点 id。
@@ -21,6 +22,12 @@ class NavNode {
/// 子节点;为空表示这是一个直接跳转的条目。
final List<NavNode> children;
/// 这个分组是不是用户创建的(后端返回的 `editable`)。
///
/// 提交表单据此给出「已有的用户分组」建议:内置分组不可选,
/// 因为提交的内容永远进不了内置分组。
final bool editable;
/// 是否是可展开的分组。
bool get isGroup => children.isNotEmpty;