feat(timeline): TimelineRow + DateSection + grouping tests + Diary sheet

- TimelineRow: 时间线条目单行视图
- DateSection + TimelineGrouping: 今日/昨日/本周/更早分组
- DiaryQuickSheet: 文字日记快速记录入口
- TimelineGroupingTests: 分组逻辑烟测
- SymptomEndSheet / RootView: 配套微调
This commit is contained in:
link2026
2026-05-25 23:23:21 +08:00
parent b1b8d0a8c7
commit b63b26bce5
6 changed files with 337 additions and 14 deletions

View File

@@ -30,6 +30,7 @@ struct RootView: View {
@State private var showRecordSheet = false
@State private var activeFlow: ActiveFlow?
@State private var showSymptomStart = false
@State private var showDiary = false
var body: some View {
VStack(spacing: 0) {
@@ -56,7 +57,7 @@ struct RootView: View {
case .quick: activeFlow = .quick
case .archive: activeFlow = .archive
case .symptom: showSymptomStart = true
case .diary: break
case .diary: showDiary = true
}
}
}
@@ -64,6 +65,9 @@ struct RootView: View {
.sheet(isPresented: $showSymptomStart) {
SymptomStartSheet()
}
.sheet(isPresented: $showDiary) {
DiaryQuickSheet()
}
#if os(iOS)
.fullScreenCover(item: $activeFlow) { flow in
switch flow {