diff --git a/康康/Features/Indicator/CustomMetricEditor.swift b/康康/Features/Indicator/CustomMetricEditor.swift index 2190a5c..6c357bf 100644 --- a/康康/Features/Indicator/CustomMetricEditor.swift +++ b/康康/Features/Indicator/CustomMetricEditor.swift @@ -13,7 +13,7 @@ let customMetricIconChoices: [String] = [ ] /// 名称冲突判定结果。`detectNameConflict` 返回此值用于 UI 警告。 -enum CustomMetricNameConflict: Equatable { +nonisolated enum CustomMetricNameConflict: Equatable { case none case builtin(String) // 撞到 MonitorMetric.displayName case existingCustom(String) // 撞到其他 CustomMonitorMetric.name diff --git a/康康/Features/Trends/SeriesBucket.swift b/康康/Features/Trends/SeriesBucket.swift index 127c97e..601ae09 100644 --- a/康康/Features/Trends/SeriesBucket.swift +++ b/康康/Features/Trends/SeriesBucket.swift @@ -5,7 +5,7 @@ import Foundation /// 趋势桶的来源类别。 /// - `.monitor`:长期监测预设 / 自定义 / 血压(按 seriesKey 分组)。 /// - `.lab`:任意出现 ≥2 次的化验/手动/报告指标(按 name+unit 分组,无 seriesKey)。 -enum SeriesKind { case monitor, lab } +nonisolated enum SeriesKind { case monitor, lab } /// 长期监测系列在 Trends 折线图里的展示桶。 /// 单系列(血糖/体重/...)= 1 个 SeriesLine;血压特殊 = 收缩 + 舒张 2 条线同卡。 diff --git a/康康/Services/ExportTrendBuilder.swift b/康康/Services/ExportTrendBuilder.swift index 36a3acf..d0e74e6 100644 --- a/康康/Services/ExportTrendBuilder.swift +++ b/康康/Services/ExportTrendBuilder.swift @@ -8,7 +8,7 @@ import Foundation /// 从根上杜绝小模型编造趋势数字(§10#5 失败回退 / §12#6 禁止编造)。 struct ExportTrend: Sendable { - enum Direction: Sendable { + nonisolated enum Direction: Sendable { case up, down, flat var arrow: String { switch self {