Wrap paywall into NavigationStack

This commit is contained in:
Davide 2024-10-28 20:08:13 +01:00
parent 0ec06c2c65
commit 11a0f95cdd
No known key found for this signature in database
GPG Key ID: A48836171C759F5E
2 changed files with 11 additions and 5 deletions

View File

@ -51,8 +51,10 @@ struct PaywallModifier: ViewModifier {
Text(Strings.Alerts.Iap.Restricted.message)
}
)
.themeModal(item: $paywallFeature) {
PaywallView(isPresented: isPresentingPurchase, feature: $0)
.themeModal(item: $paywallFeature) { feature in
NavigationStack {
PaywallView(isPresented: isPresentingPurchase, feature: feature)
}
}
.onChange(of: reason) {
switch $0 {

View File

@ -37,9 +37,13 @@ struct PaywallView: View {
// FIXME: #585, implement payments
var body: some View {
Text(String(describing: feature))
.toolbar(content: toolbarContent)
.navigationTitle(Strings.Global.purchase)
VStack {
Spacer()
Text(String(describing: feature).capitalized)
Spacer()
}
.toolbar(content: toolbarContent)
.navigationTitle(Strings.Global.purchase)
}
}