From c53a320698c17d98477c0384f1f644da9735f645 Mon Sep 17 00:00:00 2001 From: Christian Cleberg Date: Sat, 14 Mar 2026 09:56:39 -0500 Subject: implement more learning categories --- ShapesView.swift | 30 ++++++++++++++++++++++++++++++ 1 file changed, 30 insertions(+) create mode 100644 ShapesView.swift (limited to 'ShapesView.swift') diff --git a/ShapesView.swift b/ShapesView.swift new file mode 100644 index 0000000..347dbad --- /dev/null +++ b/ShapesView.swift @@ -0,0 +1,30 @@ +// +// ShapesView.swift +// DayByDay +// + +import SwiftUI + +/// Displays 8 shapes as large, tappable cards in a scrollable grid. +/// Adapts between 1 and 2 columns depending on available width. +struct ShapesView: View { + private let columns = [ + GridItem(.adaptive(minimum: 300, maximum: 500), spacing: 24) + ] + + var body: some View { + ScrollView { + LazyVGrid(columns: columns, spacing: 24) { + ForEach(LearnShape.allCases) { shape in + ShapeCard(shape: shape) + .frame(height: 200) + } + } + .padding(32) + } + } +} + +#Preview { + ShapesView() +} -- cgit v1.2.3