This commit is contained in:
Daniel Arantes Loverde
2026-06-05 16:32:08 -03:00
parent e62bd60e9a
commit 18818f909a
27 changed files with 1440 additions and 137 deletions

View File

@@ -14,6 +14,7 @@ struct ProfileView: View {
@State var openAddressesOnboarding = false
@State var onboardingMessage: String? = nil
@State var showLogoutAlert = false
@State private var openOrders = false
let tabBarClearance: CGFloat = 120
var body: some View {
@@ -41,12 +42,12 @@ struct ProfileView: View {
}
.buttonStyle(.plain)
// NavigationLink {
// Text("Meus Cartões")
// } label: {
// ProfileMenuRow(icon: "creditcard.fill", title: "Meus Cartões")
// }
// .buttonStyle(.plain)
NavigationLink {
SavedCardsView(appState: $appState)
} label: {
ProfileMenuRow(icon: "creditcard.fill", title: "Meus Cartões")
}
.buttonStyle(.plain)
NavigationLink {
MyReviewsView()
@@ -120,6 +121,15 @@ struct ProfileView: View {
AddressesView(message: onboardingMessage, appState: $appState)
}
}
.navigationDestination(isPresented: $openOrders) {
OrdersView(appState: $appState)
}
.onChange(of: appState.shouldNavigateToOrders) { _, val in
if val {
appState.shouldNavigateToOrders = false
openOrders = true
}
}
}
private var header: some View {