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/

Commit c4c3e91311

c4c3e913117460f5f1b5521df30d03dcdf733f1a

parent: 4c57ed8193

Unsigned

cmc <hello@cleberg.net> · 2026-10-17 22:02 UTC

Baloo 2 for child-facing headings (!13)

- Bundle Baloo 2 (variable TTF from google/fonts, 683 KB, SIL OFL) in `DayByDay/Fonts/` with `Baloo2-OFL.txt`.
- `HeadingFont.register()` runs at launch: registers the font with CoreText and sets navigation bar large and inline titles to Baloo 2 ExtraBold and Bold. The navigation appearance is global, so Grown-Ups screen titles use it too.
- `Font.heading(_:weight:)`: ExtraBold for `.heavy`/`.black`, Bold otherwise, fixed size. Replaces the 46 bold and heavy SF Rounded sites outside `Parent/` and the voice tip overlay, which keep the system font.
- `AppStore/screenshots` retaken.
- Learning-games spec notes the bundled font under the bundled-assets exception.

Baloo 2's line height is taller than SF Rounded's, so two-line labels (the iPhone Today banner) are more spread out.

Tests: 229 pass (new: `balooIsBundledAndRegistered`).

Closes #12

Layout: unified · split

AnimalCard.swift +1 −1
@@ -24,7 +24,7 @@ struct AnimalCard: View {
24 .foregroundStyle(.white) 24 .foregroundStyle(.white)
25 25
26 Text(animal.name) 26 Text(animal.name)
27 .font(.system(size: 32, weight: .bold, design: .rounded)) 27 .font(.heading(32))
28 .foregroundStyle(.white) 28 .foregroundStyle(.white)
29 } 29 }
30 } 30 }
AppStore/screenshots/ipad/01-home.png

Binary file not shown.

AppStore/screenshots/ipad/02-routine.png

Binary file not shown.

AppStore/screenshots/ipad/03-animals.png

Binary file not shown.

AppStore/screenshots/ipad/04-train.png

Binary file not shown.

AppStore/screenshots/ipad/05-trace.png

Binary file not shown.

AppStore/screenshots/ipad/06-counting.png

Binary file not shown.

AppStore/screenshots/ipad/07-calendar.png

Binary file not shown.

AppStore/screenshots/ipad/08-progress.png

Binary file not shown.

AppStore/screenshots/iphone-6.3/01-home.png

Binary file not shown.

AppStore/screenshots/iphone-6.3/02-routine.png

Binary file not shown.

AppStore/screenshots/iphone-6.3/03-animals.png

Binary file not shown.

AppStore/screenshots/iphone-6.3/04-train.png

Binary file not shown.

AppStore/screenshots/iphone-6.3/05-trace.png

Binary file not shown.

AppStore/screenshots/iphone-6.3/06-counting.png

Binary file not shown.

AppStore/screenshots/iphone-6.3/07-calendar.png

Binary file not shown.

AppStore/screenshots/iphone-6.3/08-progress.png

Binary file not shown.

AppStore/screenshots/iphone-6.9/01-home.png

Binary file not shown.

AppStore/screenshots/iphone-6.9/02-routine.png

Binary file not shown.

AppStore/screenshots/iphone-6.9/03-animals.png

Binary file not shown.

AppStore/screenshots/iphone-6.9/04-train.png

Binary file not shown.

AppStore/screenshots/iphone-6.9/05-trace.png

Binary file not shown.

AppStore/screenshots/iphone-6.9/06-counting.png

Binary file not shown.

AppStore/screenshots/iphone-6.9/07-calendar.png

Binary file not shown.

AppStore/screenshots/iphone-6.9/08-progress.png

Binary file not shown.

BodyPartCard.swift +1 −1
@@ -24,7 +24,7 @@ struct BodyPartCard: View {
24 .symbolRenderingMode(.hierarchical) 24 .symbolRenderingMode(.hierarchical)
25 25
26 Text(bodyPart.name) 26 Text(bodyPart.name)
27 .font(.system(size: 32, weight: .bold, design: .rounded)) 27 .font(.heading(32))
28 .foregroundStyle(.white) 28 .foregroundStyle(.white)
29 } 29 }
30 } 30 }
ColorCard.swift +1 −1
@@ -17,7 +17,7 @@ struct ColorCard: View {
17 .shadow(color: learnColor.color.opacity(0.4), radius: 8, y: 4) 17 .shadow(color: learnColor.color.opacity(0.4), radius: 8, y: 4)
18 18
19 Text(learnColor.name) 19 Text(learnColor.name)
20 .font(.system(size: 36, weight: .bold, design: .rounded)) 20 .font(.heading(36))
21 .foregroundStyle(.white) 21 .foregroundStyle(.white)
22 .shadow(color: .black.opacity(0.3), radius: 4, y: 2) 22 .shadow(color: .black.opacity(0.3), radius: 4, y: 2)
23 } 23 }
DayByDay/ContentView.swift +1 −1
@@ -104,7 +104,7 @@ struct CategoryTile: View {
104 .symbolRenderingMode(.hierarchical) 104 .symbolRenderingMode(.hierarchical)
105 105
106 Text(category.label) 106 Text(category.label)
107 .font(.system(size: 24, weight: .bold, design: .rounded)) 107 .font(.heading(24))
108 .foregroundStyle(.white) 108 .foregroundStyle(.white)
109 } 109 }
110 .shadow(color: category.usesGradientBackground ? .black.opacity(0.6) : .clear, radius: 2) 110 .shadow(color: category.usesGradientBackground ? .black.opacity(0.6) : .clear, radius: 2)
DayByDay/DayByDayApp.swift +1
@@ -18,6 +18,7 @@ struct DayByDayApp: App {
18 @State private var session: ProfileSession 18 @State private var session: ProfileSession
19 19
20 init() { 20 init() {
21 HeadingFont.register()
21 #if DEBUG 22 #if DEBUG
22 container = ProfileStore.makeContainer(inMemory: screenshot != nil) 23 container = ProfileStore.makeContainer(inMemory: screenshot != nil)
23 #else 24 #else
DayByDay/DayCard.swift +1 −1
@@ -33,7 +33,7 @@ struct DayCard: View {
33 .symbolRenderingMode(.hierarchical) 33 .symbolRenderingMode(.hierarchical)
34 34
35 Text(day.name) 35 Text(day.name)
36 .font(.system(size: 32, weight: .bold, design: .rounded)) 36 .font(.heading(32))
37 .foregroundStyle(.white) 37 .foregroundStyle(.white)
38 } 38 }
39 } 39 }
DayByDay/Fonts/Baloo2-OFL.txt added +93
@@ -0,0 +1,93 @@
1Copyright 2019 The Baloo 2 Project Authors (https://github.com/EkType/Baloo2)
2
3This Font Software is licensed under the SIL Open Font License, Version 1.1.
4This license is copied below, and is also available with a FAQ at:
5http://scripts.sil.org/OFL
6
7
8-----------------------------------------------------------
9SIL OPEN FONT LICENSE Version 1.1 - 26 February 2007
10-----------------------------------------------------------
11
12PREAMBLE
13The goals of the Open Font License (OFL) are to stimulate worldwide
14development of collaborative font projects, to support the font creation
15efforts of academic and linguistic communities, and to provide a free and
16open framework in which fonts may be shared and improved in partnership
17with others.
18
19The OFL allows the licensed fonts to be used, studied, modified and
20redistributed freely as long as they are not sold by themselves. The
21fonts, including any derivative works, can be bundled, embedded,
22redistributed and/or sold with any software provided that any reserved
23names are not used by derivative works. The fonts and derivatives,
24however, cannot be released under any other type of license. The
25requirement for fonts to remain under this license does not apply
26to any document created using the fonts or their derivatives.
27
28DEFINITIONS
29"Font Software" refers to the set of files released by the Copyright
30Holder(s) under this license and clearly marked as such. This may
31include source files, build scripts and documentation.
32
33"Reserved Font Name" refers to any names specified as such after the
34copyright statement(s).
35
36"Original Version" refers to the collection of Font Software components as
37distributed by the Copyright Holder(s).
38
39"Modified Version" refers to any derivative made by adding to, deleting,
40or substituting -- in part or in whole -- any of the components of the
41Original Version, by changing formats or by porting the Font Software to a
42new environment.
43
44"Author" refers to any designer, engineer, programmer, technical
45writer or other person who contributed to the Font Software.
46
47PERMISSION & CONDITIONS
48Permission is hereby granted, free of charge, to any person obtaining
49a copy of the Font Software, to use, study, copy, merge, embed, modify,
50redistribute, and sell modified and unmodified copies of the Font
51Software, subject to the following conditions:
52
531) Neither the Font Software nor any of its individual components,
54in Original or Modified Versions, may be sold by itself.
55
562) Original or Modified Versions of the Font Software may be bundled,
57redistributed and/or sold with any software, provided that each copy
58contains the above copyright notice and this license. These can be
59included either as stand-alone text files, human-readable headers or
60in the appropriate machine-readable metadata fields within text or
61binary files as long as those fields can be easily viewed by the user.
62
633) No Modified Version of the Font Software may use the Reserved Font
64Name(s) unless explicit written permission is granted by the corresponding
65Copyright Holder. This restriction only applies to the primary font name as
66presented to the users.
67
684) The name(s) of the Copyright Holder(s) or the Author(s) of the Font
69Software shall not be used to promote, endorse or advertise any
70Modified Version, except to acknowledge the contribution(s) of the
71Copyright Holder(s) and the Author(s) or with their explicit written
72permission.
73
745) The Font Software, modified or unmodified, in part or in whole,
75must be distributed entirely under this license, and must not be
76distributed under any other license. The requirement for fonts to
77remain under this license does not apply to any document created
78using the Font Software.
79
80TERMINATION
81This license becomes null and void if any of the above conditions are
82not met.
83
84DISCLAIMER
85THE FONT SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
86EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OF
87MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT
88OF COPYRIGHT, PATENT, TRADEMARK, OR OTHER RIGHT. IN NO EVENT SHALL THE
89COPYRIGHT HOLDER BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
90INCLUDING ANY GENERAL, SPECIAL, INDIRECT, INCIDENTAL, OR CONSEQUENTIAL
91DAMAGES, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
92FROM, OUT OF THE USE OR INABILITY TO USE THE FONT SOFTWARE OR FROM
93OTHER DEALINGS IN THE FONT SOFTWARE.
DayByDay/Fonts/Baloo2.ttf added

Binary file not shown.

DayByDay/Fonts/HeadingFont.swift added +33
@@ -0,0 +1,33 @@
1//
2// HeadingFont.swift
3// DayByDay
4//
5
6import CoreText
7import SwiftUI
8import UIKit
9
10/// Baloo 2 (SIL Open Font License, Baloo2-OFL.txt) for the headings and
11/// labels a child sees. The Grown-Ups screens keep the system font.
12enum HeadingFont {
13 static let bold = "Baloo2-Bold"
14 static let extraBold = "Baloo2-ExtraBold"
15
16 /// Registers the bundled font and styles navigation titles with it.
17 static func register() {
18 if let url = Bundle.main.url(forResource: "Baloo2", withExtension: "ttf") {
19 CTFontManagerRegisterFontsForURL(url as CFURL, .process, nil)
20 }
21 if let large = UIFont(name: extraBold, size: 34), let inline = UIFont(name: bold, size: 19) {
22 UINavigationBar.appearance().largeTitleTextAttributes = [.font: large]
23 UINavigationBar.appearance().titleTextAttributes = [.font: inline]
24 }
25 }
26}
27
28extension Font {
29 /// A heading in Baloo 2: ExtraBold for `.heavy` and `.black`, Bold otherwise.
30 static func heading(_ size: CGFloat, weight: Font.Weight = .bold) -> Font {
31 .custom(weight == .heavy || weight == .black ? HeadingFont.extraBold : HeadingFont.bold, fixedSize: size)
32 }
33}
DayByDay/Home/CategoryHubView.swift +1 −1
@@ -35,7 +35,7 @@ struct CategoryHubView: View {
35 Image(systemName: systemImage) 35 Image(systemName: systemImage)
36 .font(.system(size: 44)) 36 .font(.system(size: 44))
37 Text(title) 37 Text(title)
38 .font(.system(size: 32, weight: .bold, design: .rounded)) 38 .font(.heading(32))
39 Spacer(minLength: 0) 39 Spacer(minLength: 0)
40 } 40 }
41 .foregroundStyle(.white) 41 .foregroundStyle(.white)
DayByDay/Home/TodayBanner.swift +2 −2
@@ -22,7 +22,7 @@ struct TodayBanner: View {
22 .background(Circle().fill(.white)) 22 .background(Circle().fill(.white))
23 VStack(alignment: .leading, spacing: 6) { 23 VStack(alignment: .leading, spacing: 6) {
24 Text("Today is \(DayOfWeek.current.name)!") 24 Text("Today is \(DayOfWeek.current.name)!")
25 .font(.system(size: 30, weight: .heavy, design: .rounded)) 25 .font(.heading(30, weight: .heavy))
26 Text(Date.now.formatted(.dateTime.month(.wide).day())) 26 Text(Date.now.formatted(.dateTime.month(.wide).day()))
27 .font(.system(size: 22, weight: .semibold, design: .rounded)) 27 .font(.system(size: 22, weight: .semibold, design: .rounded))
28 .opacity(0.9) 28 .opacity(0.9)
@@ -30,7 +30,7 @@ struct TodayBanner: View {
30 StickerBadge(weather: sticker).frame(width: 56, height: 56) 30 StickerBadge(weather: sticker).frame(width: 56, height: 56)
31 } else { 31 } else {
32 Text("Tap for your sticker!") 32 Text("Tap for your sticker!")
33 .font(.system(size: 18, weight: .bold, design: .rounded)) 33 .font(.heading(18))
34 } 34 }
35 } 35 }
36 .foregroundStyle(.white) 36 .foregroundStyle(.white)
DayByDay/Mascot/MascotView.swift +1 −1
@@ -98,7 +98,7 @@ private struct OwlDrawing {
98 beakShape(&context) 98 beakShape(&context)
99 99
100 if mood == .puzzled { 100 if mood == .puzzled {
101 let mark = context.resolve(Text("?").font(.system(size: 24, weight: .heavy, design: .rounded)) 101 let mark = context.resolve(Text("?").font(.heading(24, weight: .heavy))
102 .foregroundStyle(MascotStyle.body)) 102 .foregroundStyle(MascotStyle.body))
103 context.draw(mark, at: CGPoint(x: 89, y: 22)) 103 context.draw(mark, at: CGPoint(x: 89, y: 22))
104 } 104 }
DayByDay/MonthCard.swift +1 −1
@@ -31,7 +31,7 @@ struct MonthCard: View {
31 .symbolRenderingMode(.hierarchical) 31 .symbolRenderingMode(.hierarchical)
32 32
33 Text(month.name) 33 Text(month.name)
34 .font(.system(size: 32, weight: .bold, design: .rounded)) 34 .font(.heading(32))
35 .foregroundStyle(.white) 35 .foregroundStyle(.white)
36 } 36 }
37 } 37 }
DayByDay/Profiles/ProfilePickerView.swift +2 −2
@@ -26,7 +26,7 @@ struct ProfilePickerView: View {
26 VStack(spacing: 12) { 26 VStack(spacing: 12) {
27 AvatarBadge(avatar: profile.avatar, color: profile.color) 27 AvatarBadge(avatar: profile.avatar, color: profile.color)
28 Text(profile.name) 28 Text(profile.name)
29 .font(.system(size: 26, weight: .bold, design: .rounded)) 29 .font(.heading(26))
30 .foregroundStyle(.primary) 30 .foregroundStyle(.primary)
31 } 31 }
32 } 32 }
@@ -67,7 +67,7 @@ struct ProfileSetupView: View {
67 MascotView(mood: .waving) 67 MascotView(mood: .waving)
68 .frame(width: 160, height: 160) 68 .frame(width: 160, height: 160)
69 Text("Welcome to Day By Day") 69 Text("Welcome to Day By Day")
70 .font(.system(size: 32, weight: .bold, design: .rounded)) 70 .font(.heading(32))
71 Text("Set up a profile for your child.") 71 Text("Set up a profile for your child.")
72 .font(.system(size: 20, design: .rounded)) 72 .font(.system(size: 20, design: .rounded))
73 .foregroundStyle(.secondary) 73 .foregroundStyle(.secondary)
DayByDay/Quiz/ChoiceTile.swift +3 −3
@@ -68,13 +68,13 @@ struct ChoiceTile: View {
68 .scaleEffect([.star, .heart].contains(shape) ? 1.15 : 1) 68 .scaleEffect([.star, .heart].contains(shape) ? 1.15 : 1)
69 case .alphabet: 69 case .alphabet:
70 Text(item.value(LearnLetter.self)!.character) 70 Text(item.value(LearnLetter.self)!.character)
71 .font(.system(size: 80, weight: .heavy, design: .rounded)) 71 .font(.heading(80, weight: .heavy))
72 .foregroundStyle(.white) 72 .foregroundStyle(.white)
73 case .numbers: 73 case .numbers:
74 let number = item.value(LearnNumber.self)! 74 let number = item.value(LearnNumber.self)!
75 VStack(spacing: 8) { 75 VStack(spacing: 8) {
76 Text("\(number.numeral)") 76 Text("\(number.numeral)")
77 .font(.system(size: 56, weight: .heavy, design: .rounded)) 77 .font(.heading(56, weight: .heavy))
78 Dots(count: number.numeral) 78 Dots(count: number.numeral)
79 } 79 }
80 .foregroundStyle(.white) 80 .foregroundStyle(.white)
@@ -101,7 +101,7 @@ struct ChoiceTile: View {
101 .font(.system(size: 52)) 101 .font(.system(size: 52))
102 .frame(height: 60) 102 .frame(height: 60)
103 Text(item.name) 103 Text(item.name)
104 .font(.system(size: 26, weight: .bold, design: .rounded)) 104 .font(.heading(26))
105 .lineLimit(1) 105 .lineLimit(1)
106 .minimumScaleFactor(0.6) 106 .minimumScaleFactor(0.6)
107 } 107 }
DayByDay/Quiz/ClothingTile.swift +1 −1
@@ -16,7 +16,7 @@ struct ClothingTile: View {
16 .font(.system(size: 56)) 16 .font(.system(size: 56))
17 .frame(height: 64) 17 .frame(height: 64)
18 Text(item.name) 18 Text(item.name)
19 .font(.system(size: 24, weight: .bold, design: .rounded)) 19 .font(.heading(24))
20 .lineLimit(1) 20 .lineLimit(1)
21 .minimumScaleFactor(0.6) 21 .minimumScaleFactor(0.6)
22 } 22 }
DayByDay/Quiz/CountingView.swift +3 −3
@@ -52,7 +52,7 @@ struct CountingView: View {
52 GameMascot(state: $mascot) 52 GameMascot(state: $mascot)
53 Button { ask(after: 0) } label: { 53 Button { ask(after: 0) } label: {
54 Label("Hear it again", systemImage: "speaker.wave.2.fill") 54 Label("Hear it again", systemImage: "speaker.wave.2.fill")
55 .font(.system(size: 24, weight: .bold, design: .rounded)) 55 .font(.heading(24))
56 .padding(.horizontal, 28) 56 .padding(.horizontal, 28)
57 .padding(.vertical, 16) 57 .padding(.vertical, 16)
58 .background(Capsule().fill(Color(.systemGray6))) 58 .background(Capsule().fill(Color(.systemGray6)))
@@ -61,7 +61,7 @@ struct CountingView: View {
61 } 61 }
62 62
63 Text(showTotal ? "\(round.target)" : " ") 63 Text(showTotal ? "\(round.target)" : " ")
64 .font(.system(size: 96, weight: .heavy, design: .rounded)) 64 .font(.heading(96, weight: .heavy))
65 .foregroundStyle(color) 65 .foregroundStyle(color)
66 .frame(height: 110) 66 .frame(height: 110)
67 .accessibilityHidden(!showTotal) 67 .accessibilityHidden(!showTotal)
@@ -89,7 +89,7 @@ struct CountingView: View {
89 if let order { 89 if let order {
90 VStack(spacing: 2) { 90 VStack(spacing: 2) {
91 Image(systemName: round.thing.symbol).font(.system(size: 30)) 91 Image(systemName: round.thing.symbol).font(.system(size: 30))
92 Text("\(order)").font(.system(size: 34, weight: .heavy, design: .rounded)) 92 Text("\(order)").font(.heading(34, weight: .heavy))
93 } 93 }
94 .foregroundStyle(.white) 94 .foregroundStyle(.white)
95 } else { 95 } else {
DayByDay/Quiz/FinishedView.swift +2 −2
@@ -16,10 +16,10 @@ struct FinishedView: View {
16 MascotView(mood: .cheering) 16 MascotView(mood: .cheering)
17 .frame(width: 180, height: 180) 17 .frame(width: 180, height: 180)
18 Text("You did it!") 18 Text("You did it!")
19 .font(.system(size: 48, weight: .heavy, design: .rounded)) 19 .font(.heading(48, weight: .heavy))
20 Button(action: onPlayAgain) { 20 Button(action: onPlayAgain) {
21 Label("Play again", systemImage: "arrow.clockwise") 21 Label("Play again", systemImage: "arrow.clockwise")
22 .font(.system(size: 28, weight: .bold, design: .rounded)) 22 .font(.heading(28))
23 .foregroundStyle(.white) 23 .foregroundStyle(.white)
24 .padding(.horizontal, 40) 24 .padding(.horizontal, 40)
25 .padding(.vertical, 20) 25 .padding(.vertical, 20)
DayByDay/Quiz/MovesView.swift +2 −2
@@ -30,7 +30,7 @@ struct MovesView: View {
30 GameMascot(state: $mascot) 30 GameMascot(state: $mascot)
31 Button { start() } label: { 31 Button { start() } label: {
32 Label("Hear it again", systemImage: "speaker.wave.2.fill") 32 Label("Hear it again", systemImage: "speaker.wave.2.fill")
33 .font(.system(size: 24, weight: .bold, design: .rounded)) 33 .font(.heading(24))
34 .padding(.horizontal, 28) 34 .padding(.horizontal, 28)
35 .padding(.vertical, 16) 35 .padding(.vertical, 16)
36 .background(Capsule().fill(Color(.systemGray6))) 36 .background(Capsule().fill(Color(.systemGray6)))
@@ -44,7 +44,7 @@ struct MovesView: View {
44 .background(RoundedRectangle(cornerRadius: 40, style: .continuous).fill(Category.bodyParts.color)) 44 .background(RoundedRectangle(cornerRadius: 40, style: .continuous).fill(Category.bodyParts.color))
45 .accessibilityLabel(part.name) 45 .accessibilityLabel(part.name)
46 Text(part.command) 46 Text(part.command)
47 .font(.system(size: 30, weight: .heavy, design: .rounded)) 47 .font(.heading(30, weight: .heavy))
48 .multilineTextAlignment(.center) 48 .multilineTextAlignment(.center)
49 } 49 }
50 .padding(24) 50 .padding(24)
DayByDay/Quiz/RoundView.swift +2 −2
@@ -59,7 +59,7 @@ struct RoundView<Choice: View>: View {
59 GameMascot(state: $mascot) 59 GameMascot(state: $mascot)
60 Button(action: speakPrompt) { 60 Button(action: speakPrompt) {
61 Label("Hear it again", systemImage: "speaker.wave.2.fill") 61 Label("Hear it again", systemImage: "speaker.wave.2.fill")
62 .font(.system(size: 24, weight: .bold, design: .rounded)) 62 .font(.heading(24))
63 .lineLimit(1) 63 .lineLimit(1)
64 .minimumScaleFactor(0.7) 64 .minimumScaleFactor(0.7)
65 .padding(.horizontal, 28) 65 .padding(.horizontal, 28)
@@ -173,7 +173,7 @@ private struct ShownItems: View {
173 173
174 private func sign(_ text: String) -> some View { 174 private func sign(_ text: String) -> some View {
175 Text(text) 175 Text(text)
176 .font(.system(size: 36, weight: .heavy, design: .rounded)) 176 .font(.heading(36, weight: .heavy))
177 .lineLimit(1) 177 .lineLimit(1)
178 .fixedSize() 178 .fixedSize()
179 } 179 }
DayByDay/Quiz/SequencePuzzleView.swift +2 −2
@@ -59,7 +59,7 @@ struct SequencePuzzleView: View {
59 GameMascot(state: $mascot) 59 GameMascot(state: $mascot)
60 Button { ask(after: 0) } label: { 60 Button { ask(after: 0) } label: {
61 Label("Hear it again", systemImage: "speaker.wave.2.fill") 61 Label("Hear it again", systemImage: "speaker.wave.2.fill")
62 .font(.system(size: 24, weight: .bold, design: .rounded)) 62 .font(.heading(24))
63 .padding(.horizontal, 28) 63 .padding(.horizontal, 28)
64 .padding(.vertical, 16) 64 .padding(.vertical, 16)
65 .background(Capsule().fill(Color(.systemGray6))) 65 .background(Capsule().fill(Color(.systemGray6)))
@@ -105,7 +105,7 @@ struct SequencePuzzleView: View {
105 ForEach(Array(labels.enumerated()), id: \.offset) { i, label in 105 ForEach(Array(labels.enumerated()), id: \.offset) { i, label in
106 VStack(spacing: 8) { 106 VStack(spacing: 8) {
107 Text(label) 107 Text(label)
108 .font(.system(size: 20, weight: .bold, design: .rounded)) 108 .font(.heading(20))
109 .lineLimit(1) 109 .lineLimit(1)
110 .minimumScaleFactor(0.6) 110 .minimumScaleFactor(0.6)
111 slot(i).frame(height: 130) 111 slot(i).frame(height: 130)
DayByDay/Quiz/SortView.swift +2 −2
@@ -58,7 +58,7 @@ struct SortView: View {
58 GameMascot(state: $mascot) 58 GameMascot(state: $mascot)
59 Button { ask(after: 0) } label: { 59 Button { ask(after: 0) } label: {
60 Label("Hear it again", systemImage: "speaker.wave.2.fill") 60 Label("Hear it again", systemImage: "speaker.wave.2.fill")
61 .font(.system(size: 24, weight: .bold, design: .rounded)) 61 .font(.heading(24))
62 .padding(.horizontal, 28) 62 .padding(.horizontal, 28)
63 .padding(.vertical, 16) 63 .padding(.vertical, 16)
64 .background(Capsule().fill(Color(.systemGray6))) 64 .background(Capsule().fill(Color(.systemGray6)))
@@ -91,7 +91,7 @@ struct SortView: View {
91 VStack(spacing: 8) { 91 VStack(spacing: 8) {
92 Text(isFruit ? "🍎🍌" : "🥕🥦").font(.system(size: 44)) 92 Text(isFruit ? "🍎🍌" : "🥕🥦").font(.system(size: 44))
93 Text(isFruit ? "Fruit" : "Vegetables") 93 Text(isFruit ? "Fruit" : "Vegetables")
94 .font(.system(size: 22, weight: .bold, design: .rounded)) 94 .font(.heading(22))
95 .foregroundStyle(.white) 95 .foregroundStyle(.white)
96 Text(contents.map(\.emoji).joined()) 96 Text(contents.map(\.emoji).joined())
97 .font(.system(size: 30)) 97 .font(.system(size: 30))
DayByDay/Quiz/TraceView.swift +1 −1
@@ -99,7 +99,7 @@ struct TraceView: View {
99 private func pill(_ title: String, _ symbol: String, action: @escaping () -> Void) -> some View { 99 private func pill(_ title: String, _ symbol: String, action: @escaping () -> Void) -> some View {
100 Button(action: action) { 100 Button(action: action) {
101 Label(title, systemImage: symbol) 101 Label(title, systemImage: symbol)
102 .font(.system(size: 19, weight: .bold, design: .rounded)) 102 .font(.heading(19))
103 .lineLimit(1) 103 .lineLimit(1)
104 .minimumScaleFactor(0.7) 104 .minimumScaleFactor(0.7)
105 .padding(.horizontal, 20) 105 .padding(.horizontal, 20)
DayByDay/Quiz/YearWheelView.swift +2 −2
@@ -41,7 +41,7 @@ struct YearWheelView: View {
41 .frame(maxWidth: 520) 41 .frame(maxWidth: 520)
42 Button(action: spin) { 42 Button(action: spin) {
43 Label("Spin!", systemImage: "arrow.clockwise.circle.fill") 43 Label("Spin!", systemImage: "arrow.clockwise.circle.fill")
44 .font(.system(size: 32, weight: .heavy, design: .rounded)) 44 .font(.heading(32, weight: .heavy))
45 .foregroundStyle(.white) 45 .foregroundStyle(.white)
46 .padding(.horizontal, 48) 46 .padding(.horizontal, 48)
47 .padding(.vertical, 22) 47 .padding(.vertical, 22)
@@ -76,7 +76,7 @@ struct YearWheelView: View {
76 .accessibilityLabel(month.name) 76 .accessibilityLabel(month.name)
77 .accessibilityAddTraits(.isButton) 77 .accessibilityAddTraits(.isButton)
78 Text(month.name.prefix(3)) 78 Text(month.name.prefix(3))
79 .font(.system(size: size * 0.06, weight: .heavy, design: .rounded)) 79 .font(.heading(size * 0.06, weight: .heavy))
80 .foregroundStyle(.white) 80 .foregroundStyle(.white)
81 .offset(y: -size * 0.38) 81 .offset(y: -size * 0.38)
82 .rotationEffect(.degrees(center)) 82 .rotationEffect(.degrees(center))
DayByDay/SeasonCard.swift +1 −1
@@ -31,7 +31,7 @@ struct SeasonCard: View {
31 .symbolRenderingMode(.hierarchical) 31 .symbolRenderingMode(.hierarchical)
32 32
33 Text(season.name) 33 Text(season.name)
34 .font(.system(size: 32, weight: .bold, design: .rounded)) 34 .font(.heading(32))
35 .foregroundStyle(.white) 35 .foregroundStyle(.white)
36 } 36 }
37 } 37 }
DayByDay/Today/StickerCalendarView.swift +3 −3
@@ -62,7 +62,7 @@ struct StickerCalendarView: View {
62 arrow("chevron.left", label: "Earlier month") { grid = grid.shifted(by: -1) } 62 arrow("chevron.left", label: "Earlier month") { grid = grid.shifted(by: -1) }
63 Spacer() 63 Spacer()
64 Text(verbatim: "\(monthName) \(grid.year)") 64 Text(verbatim: "\(monthName) \(grid.year)")
65 .font(.system(size: 28, weight: .heavy, design: .rounded)) 65 .font(.heading(28, weight: .heavy))
66 Spacer() 66 Spacer()
67 arrow("chevron.right", label: "Later month") { grid = grid.shifted(by: 1) } 67 arrow("chevron.right", label: "Later month") { grid = grid.shifted(by: 1) }
68 .disabled(!canGoLater) 68 .disabled(!canGoLater)
@@ -70,7 +70,7 @@ struct StickerCalendarView: View {
70 } 70 }
71 LazyVGrid(columns: Array(repeating: GridItem(.flexible(), spacing: 6), count: 7), spacing: 6) { 71 LazyVGrid(columns: Array(repeating: GridItem(.flexible(), spacing: 6), count: 7), spacing: 6) {
72 ForEach(Array(["S", "M", "T", "W", "T", "F", "S"].enumerated()), id: \.offset) { _, d in 72 ForEach(Array(["S", "M", "T", "W", "T", "F", "S"].enumerated()), id: \.offset) { _, d in
73 Text(d).font(.system(size: 16, weight: .bold, design: .rounded)).foregroundStyle(.primary) 73 Text(d).font(.heading(16)).foregroundStyle(.primary)
74 } 74 }
75 ForEach(Array(grid.cells.enumerated()), id: \.offset) { _, day in 75 ForEach(Array(grid.cells.enumerated()), id: \.offset) { _, day in
76 if let day { 76 if let day {
@@ -93,7 +93,7 @@ struct StickerCalendarView: View {
93 .overlay(alignment: .bottomTrailing) { 93 .overlay(alignment: .bottomTrailing) {
94 // Keep the date readable on a stickered day. 94 // Keep the date readable on a stickered day.
95 Text("\(day)") 95 Text("\(day)")
96 .font(.system(size: 11, weight: .bold, design: .rounded)) 96 .font(.heading(11))
97 .padding(3) 97 .padding(3)
98 .background(Circle().fill(Color(.systemBackground))) 98 .background(Circle().fill(Color(.systemBackground)))
99 } 99 }
DayByDay/Today/TodayRoutineView.swift +3 −3
@@ -42,7 +42,7 @@ struct TodayRoutineView: View {
42 .padding(.top, 8) 42 .padding(.top, 8)
43 Button { dismiss() } label: { 43 Button { dismiss() } label: {
44 Label("Done", systemImage: "checkmark") 44 Label("Done", systemImage: "checkmark")
45 .font(.system(size: 28, weight: .bold, design: .rounded)) 45 .font(.heading(28))
46 .foregroundStyle(.white) 46 .foregroundStyle(.white)
47 .padding(.horizontal, 44) 47 .padding(.horizontal, 44)
48 .padding(.vertical, 20) 48 .padding(.vertical, 20)
@@ -81,7 +81,7 @@ struct TodayRoutineView: View {
81 .font(.system(size: 110)) 81 .font(.system(size: 110))
82 .frame(height: 130) 82 .frame(height: 130)
83 Text(line.text) 83 Text(line.text)
84 .font(.system(size: 32, weight: .heavy, design: .rounded)) 84 .font(.heading(32, weight: .heavy))
85 .multilineTextAlignment(.center) 85 .multilineTextAlignment(.center)
86 .minimumScaleFactor(0.6) 86 .minimumScaleFactor(0.6)
87 } 87 }
@@ -127,7 +127,7 @@ struct TodayRoutineView: View {
127 GameMascot(state: $mascot) 127 GameMascot(state: $mascot)
128 Button(action: speakCurrent) { 128 Button(action: speakCurrent) {
129 Label("Hear it again", systemImage: "speaker.wave.2.fill") 129 Label("Hear it again", systemImage: "speaker.wave.2.fill")
130 .font(.system(size: 22, weight: .bold, design: .rounded)) 130 .font(.heading(22))
131 .padding(.horizontal, 24) 131 .padding(.horizontal, 24)
132 .padding(.vertical, 14) 132 .padding(.vertical, 14)
133 .background(Capsule().fill(Color(.systemGray6))) 133 .background(Capsule().fill(Color(.systemGray6)))
DayByDayTests/HeadingFontTests.swift added +13
@@ -0,0 +1,13 @@
1import SwiftUI
2import Testing
3import UIKit
4@testable import DayByDay
5
6@MainActor
7struct HeadingFontTests {
8 @Test func balooIsBundledAndRegistered() {
9 HeadingFont.register()
10 #expect(UIFont(name: HeadingFont.bold, size: 20) != nil)
11 #expect(UIFont(name: HeadingFont.extraBold, size: 20) != nil)
12 }
13}
FoodCard.swift +1 −1
@@ -23,7 +23,7 @@ struct FoodCard: View {
23 .font(.system(size: 72)) 23 .font(.system(size: 72))
24 24
25 Text(food.name) 25 Text(food.name)
26 .font(.system(size: 28, weight: .bold, design: .rounded)) 26 .font(.heading(28))
27 .foregroundStyle(.white) 27 .foregroundStyle(.white)
28 } 28 }
29 } 29 }
LetterCard.swift +1 −1
@@ -18,7 +18,7 @@ struct LetterCard: View {
18 .shadow(color: letter.color.opacity(0.4), radius: 8, y: 4) 18 .shadow(color: letter.color.opacity(0.4), radius: 8, y: 4)
19 19
20 Text(letter.character) 20 Text(letter.character)
21 .font(.system(size: 64, weight: .heavy, design: .rounded)) 21 .font(.heading(64, weight: .heavy))
22 .foregroundStyle(.white) 22 .foregroundStyle(.white)
23 } 23 }
24 .scaleEffect(isTapped ? 1.12 : 1.0) 24 .scaleEffect(isTapped ? 1.12 : 1.0)
NumberCard.swift +2 −2
@@ -26,11 +26,11 @@ struct NumberCard: View {
26 26
27 VStack(spacing: 10) { 27 VStack(spacing: 10) {
28 Text("\(number.numeral)") 28 Text("\(number.numeral)")
29 .font(.system(size: 60, weight: .heavy, design: .rounded)) 29 .font(.heading(60, weight: .heavy))
30 .foregroundStyle(.white) 30 .foregroundStyle(.white)
31 31
32 Text(number.name) 32 Text(number.name)
33 .font(.system(size: 28, weight: .bold, design: .rounded)) 33 .font(.heading(28))
34 .foregroundStyle(.white) 34 .foregroundStyle(.white)
35 35
36 // Dot pattern showing the quantity 36 // Dot pattern showing the quantity
ShapeCard.swift +1 −1
@@ -23,7 +23,7 @@ struct ShapeCard: View {
23 .foregroundStyle(.white) 23 .foregroundStyle(.white)
24 24
25 Text(shape.name) 25 Text(shape.name)
26 .font(.system(size: 32, weight: .bold, design: .rounded)) 26 .font(.heading(32))
27 .foregroundStyle(.white) 27 .foregroundStyle(.white)
28 } 28 }
29 } 29 }
WeatherCard.swift +1 −1
@@ -24,7 +24,7 @@ struct WeatherCard: View {
24 .symbolRenderingMode(.hierarchical) 24 .symbolRenderingMode(.hierarchical)
25 25
26 Text(weather.name) 26 Text(weather.name)
27 .font(.system(size: 32, weight: .bold, design: .rounded)) 27 .font(.heading(32))
28 .foregroundStyle(.white) 28 .foregroundStyle(.white)
29 } 29 }
30 } 30 }
WeatherView.swift +1 −1
@@ -20,7 +20,7 @@ struct WeatherView: View {
20 ScrollView { 20 ScrollView {
21 Button(action: rain) { 21 Button(action: rain) {
22 Label("Shake for rain!", systemImage: "cloud.rain.fill") 22 Label("Shake for rain!", systemImage: "cloud.rain.fill")
23 .font(.system(size: 22, weight: .bold, design: .rounded)) 23 .font(.heading(22))
24 .padding(.horizontal, 24) 24 .padding(.horizontal, 24)
25 .padding(.vertical, 14) 25 .padding(.vertical, 14)
26 .background(Capsule().fill(Color(.systemGray6))) 26 .background(Capsule().fill(Color(.systemGray6)))
docs/superpowers/specs/2026-10-16-learning-games-design.md +2 −1
@@ -55,7 +55,8 @@ These would make the work a failure even if it functions:
55 sounds synthesized at runtime (e.g. AVAudioEngine tone/noise generation). No 55 sounds synthesized at runtime (e.g. AVAudioEngine tone/noise generation). No
56 bundled image or audio files beyond the existing app icon, except generated 56 bundled image or audio files beyond the existing app icon, except generated
57 speech clips (`DayByDay/Voice/`, rendered with ElevenLabs under a commercial 57 speech clips (`DayByDay/Voice/`, rendered with ElevenLabs under a commercial
58 license; see 2026-10-16-better-voice.md). 58 license; see 2026-10-16-better-voice.md) and the Baloo 2 heading font
59 (`DayByDay/Fonts/`, SIL Open Font License).
59- Every MR that adds or changes art or sound gets a review by a separate 60- Every MR that adds or changes art or sound gets a review by a separate
60 reviewer agent focused on art and sound quality, before the MR is opened. 61 reviewer agent focused on art and sound quality, before the MR is opened.
61- Repo is on gitbay. One MR per part below, branched from `main`, never pushed 62- Repo is on gitbay. One MR per part below, branched from `main`, never pushed