From 627319a01f45521608eff536ce43b059eed9485e Mon Sep 17 00:00:00 2001 From: Ian Gulliver Date: Tue, 20 Oct 2026 22:09:20 -0700 Subject: [PATCH] Tasks empty state --- mac/Sources/Byre/Project.swift | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/mac/Sources/Byre/Project.swift b/mac/Sources/Byre/Project.swift index 4378781..00e2bfe 100644 --- a/mac/Sources/Byre/Project.swift +++ b/mac/Sources/Byre/Project.swift @@ -190,6 +190,12 @@ private struct ProjectBlock: View { .font(Fonts.font(11)) .foregroundStyle(Palette.muted) heading("Tasks") + if active.isEmpty { + Text("No active tasks.") + .foregroundStyle(Palette.muted) + .padding(.horizontal, 10) + .padding(.vertical, 6) + } TaskRows(active: active.filter { !$0.background }) ForEach(active.filter(\.background), id: \.id) { task in BackgroundRow(task: task) @@ -230,12 +236,7 @@ private struct TaskRows: View { @Environment(Store.self) private var store var body: some View { - if active.isEmpty { - Text("No active tasks.") - .foregroundStyle(Palette.muted) - .padding(.horizontal, 10) - .padding(.vertical, 6) - } else { + if !active.isEmpty { VStack(alignment: .leading, spacing: 0) { ForEach(nested(store, active), id: \.task.id) { row in TaskRow(task: row.task, depth: row.depth)