Created
June 2, 2025 12:03
-
-
Save jacobsapps/b683cff113e2eb9e5eda93d21a0e8a71 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@Environment(\.modelContext) private var context | |
// ... | |
VStack(spacing: .zero) { | |
Text("Does this card represent you?") | |
.multilineTextAlignment(.center) | |
.font(.headline) | |
Button { | |
if let card = viewModel.card { | |
let entity = CardEntity.from(card) | |
context.insert(entity) | |
try? context.save() | |
onCardConfirmed(card) | |
} | |
} label: { | |
Text("Tap here to confirm and continue") | |
.multilineTextAlignment(.center) | |
.font(.headline) | |
.foregroundStyle(.blue) | |
} | |
.contentShape(Rectangle()) | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment