krz/daybyday

iOS learning games for young children: days, months, seasons, numbers, letters, animals and more. education ios kids swift https://krz.sh/apps/daybyday/

AlphabetView.swift

062549ad26607ce9e973ed2a9a7ef6f853885f83
daybyday/AlphabetView.swift history · blame · raw

21 lines · 563 bytes

1 symbol in this file
 1//
 2//  AlphabetView.swift
 3//  DayByDay
 4//
 5
 6import SwiftUI
 7
 8/// Displays all 26 letters A–Z as large, tappable cards in a scrollable grid.
 9/// Uses a smaller minimum size to fit more letters across the screen.
10struct AlphabetView: View {
11    var body: some View {
12        CardGrid(items: LearnLetter.allCases, column: GridItem(.adaptive(minimum: 140, maximum: 300), spacing: 20), spacing: 20, minHeight: 160) { letter in
13            LetterCard(letter: letter)
14        }
15        .onDisappear { CardVoice.shared.cancel() }
16    }
17}
18
19#Preview {
20    AlphabetView()
21}