Tasks: square the remaining checkboxes I missed (Today timeline, Next-3, Matrix rows)

Follow-up after the first pass only caught the list-style rows. Converted the
actual tap-to-complete toggles + markers that were still circular:
- Today timeline (tlRows): marker complete/all-day → rounded square (circleD
  18→16); trailing SF-symbol toggle → rounded-square checkbox.
- Today Next-3-Days row: 20pt circle → 16pt rounded square.
- Today "Completed Today" row indicator: green circle → green rounded square.
- Calendar Month agenda (DayTimelineView): trailing SF-symbol toggle → square.
- Matrix quadrant row checkbox: circles → rounded squares.

Left intentionally circular: multi-select sheet (selection, not completion) and
workout-set checkboxes (separate domain).

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This commit is contained in:
kutesir
2026-06-25 01:07:50 +03:00
parent 1c325c108e
commit b78b965938
3 changed files with 44 additions and 19 deletions

View File

@@ -1950,9 +1950,19 @@ private struct DayTLRow: View {
Spacer(minLength: 0)
if let toggle = onToggle {
Button(action: toggle) {
Image(systemName: entry.isComplete ? "checkmark.circle.fill" : "circle")
.font(.system(size: 18))
.foregroundColor(entry.isComplete ? entry.color : AppColors.text3(cs))
ZStack {
RoundedRectangle(cornerRadius: 5, style: .continuous)
.fill(entry.isComplete ? entry.color : Color.clear)
.frame(width: 16, height: 16)
RoundedRectangle(cornerRadius: 5, style: .continuous)
.strokeBorder(entry.isComplete ? Color.clear : AppColors.text3(cs), lineWidth: 1.5)
.frame(width: 16, height: 16)
if entry.isComplete {
Image(systemName: "checkmark")
.font(.system(size: 9, weight: .bold))
.foregroundColor(.white)
}
}
}
.buttonStyle(.plain)
} else if onWorkoutTap != nil {

View File

@@ -261,12 +261,12 @@ struct QuadrantCard: View {
Color.clear.frame(height: 0).trackScrollForTabBar()
ForEach(tasks) { task in
HStack(alignment: .top, spacing: 8) {
// Circle checkbox
// Rounded-square checkbox
ZStack {
Circle()
RoundedRectangle(cornerRadius: 5, style: .continuous)
.fill(task.isComplete ? badgeColor.opacity(0.15) : badgeBg)
.frame(width: 16, height: 16)
Circle()
RoundedRectangle(cornerRadius: 5, style: .continuous)
.stroke(task.isComplete ? badgeColor.opacity(0.4) : badgeColor, lineWidth: 1.5)
.frame(width: 16, height: 16)
if task.isComplete {

View File

@@ -486,7 +486,7 @@ private struct TodayTLRow: View {
@AppStorage("todayShowDetails") private var showDetails = true
private let circleD: CGFloat = 18
private let circleD: CGFloat = 16
private let timeW: CGFloat = 46
private let trackW: CGFloat = 26
private let topGap: CGFloat = 10
@@ -520,14 +520,14 @@ private struct TodayTLRow: View {
// Marker
ZStack {
if entry.isComplete {
Circle()
RoundedRectangle(cornerRadius: 5, style: .continuous)
.fill(entry.color.opacity(0.14))
.frame(width: circleD, height: circleD)
Image(systemName: "checkmark")
.font(.system(size: 7.5, weight: .bold))
.foregroundColor(entry.color)
} else if entry.isAllDay {
Circle()
RoundedRectangle(cornerRadius: 5, style: .continuous)
.strokeBorder(entry.color, lineWidth: 1.5)
.frame(width: circleD, height: circleD)
} else {
@@ -565,9 +565,19 @@ private struct TodayTLRow: View {
bg: entry.task.quadrant.softColor
)
Button(action: onToggle) {
Image(systemName: entry.isComplete ? "checkmark.circle.fill" : "circle")
.font(.system(size: 20))
.foregroundColor(entry.isComplete ? entry.color : AppColors.text3(cs))
ZStack {
RoundedRectangle(cornerRadius: 5, style: .continuous)
.fill(entry.isComplete ? entry.color : Color.clear)
.frame(width: 16, height: 16)
RoundedRectangle(cornerRadius: 5, style: .continuous)
.strokeBorder(entry.isComplete ? Color.clear : AppColors.text3(cs), lineWidth: 1.5)
.frame(width: 16, height: 16)
if entry.isComplete {
Image(systemName: "checkmark")
.font(.system(size: 9, weight: .bold))
.foregroundColor(.white)
}
}
}
.buttonStyle(.plain)
}
@@ -639,9 +649,9 @@ struct OverdueCard: View {
ForEach(tasks) { task in
HStack(spacing: 10) {
Button { withAnimation(KisaniSpring.bounce) { onToggle(task) } } label: {
Circle()
.stroke(AppColors.red, lineWidth: 1.5)
.frame(width: 20, height: 20)
RoundedRectangle(cornerRadius: 5, style: .continuous)
.strokeBorder(AppColors.red, lineWidth: 1.5)
.frame(width: 16, height: 16)
.frame(width: 36, height: 44)
.contentShape(Rectangle())
}
@@ -1159,10 +1169,15 @@ struct CompletedTodaySection: View {
ForEach(tasks) { task in
HStack(spacing: 10) {
Image(systemName: "checkmark.circle.fill")
.font(.system(size: 18))
.foregroundColor(AppColors.green)
.frame(width: 36, height: 44)
ZStack {
RoundedRectangle(cornerRadius: 5, style: .continuous)
.fill(AppColors.green)
.frame(width: 16, height: 16)
Image(systemName: "checkmark")
.font(.system(size: 9, weight: .bold))
.foregroundColor(.white)
}
.frame(width: 36, height: 44)
VStack(alignment: .leading, spacing: 1) {
Text(task.title)