[lcenavigationview-adoption] Suppress glass button chrome via .buttonStyle(.plain)

Cascades .buttonStyle(.plain) down from each LCENavigationView
instance instead of waiting on the LCEssentials package fix
(committed separately, unpublished: LC_Essentials commit 8b0f650) to
be released and this repo's Package.resolved bumped. Overrides
iOS 26's automatic Liquid Glass chrome on LCENavigationView's
internal nav buttons - including the invisible backfilled mirror
button on whichever side has no real action - without affecting any
button that already sets its own explicit style closer to itself.
This commit is contained in:
Daniel Arantes Loverde
2026-08-24 15:18:57 -03:00
parent 18497b017a
commit 29c80d06af
16 changed files with 18 additions and 0 deletions

View File

@@ -40,6 +40,7 @@ struct AddAddressFormView: View {
.setLeftButton(image: AnyView(AppBackButtonIcon())) { dismiss() }
.setTitle(text: Text(existingAddress == nil ? "Novo endereço" : "Editar endereço").font(AppTypography.heading2).foregroundStyle(AppColors.textPrimary))
.setNavigationBarBackgroundColor(AppColors.backgroundLight)
.buttonStyle(.plain)
}
private var content: some View {

View File

@@ -62,6 +62,7 @@ struct AddCardFormView: View {
.setLeftButton(image: AnyView(AppBackButtonIcon())) { dismiss() }
.setTitle(text: Text("Novo Cartão").font(AppTypography.heading2).foregroundStyle(AppColors.textPrimary))
.setNavigationBarBackgroundColor(AppColors.backgroundLight)
.buttonStyle(.plain)
}
private var content: some View {

View File

@@ -26,6 +26,7 @@ struct AddressesView: View {
.setLeftButton(image: AnyView(AppBackButtonIcon())) { dismiss() }
.setTitle(text: Text("Meus Endereços").font(AppTypography.heading2).foregroundStyle(AppColors.textPrimary))
.setNavigationBarBackgroundColor(AppColors.backgroundLight)
.buttonStyle(.plain)
}
private var content: some View {

View File

@@ -21,6 +21,7 @@ struct CartView: View {
}
.setTitle(text: Text("Meu Carrinho").font(AppTypography.heading1).foregroundStyle(AppColors.textPrimary))
.setNavigationBarBackgroundColor(AppColors.backgroundLight)
.buttonStyle(.plain)
}
private var content: some View {

View File

@@ -115,6 +115,7 @@ struct CheckoutView: View {
.setLeftButton(image: AnyView(AppBackButtonIcon())) { dismiss() }
.setTitle(text: Text("Finalizar Pedido").font(AppTypography.heading2).foregroundStyle(AppColors.textPrimary))
.setNavigationBarBackgroundColor(AppColors.backgroundLight)
.buttonStyle(.plain)
.appBottomSafeAreaInset {
bottomBar
}
@@ -724,6 +725,7 @@ struct PaymentPixView: View {
.setLeftButton(image: AnyView(AppBackButtonIcon())) { dismiss() }
.setTitle(text: Text("Pagamento via PIX").font(AppTypography.heading2).foregroundStyle(AppColors.textPrimary))
.setNavigationBarBackgroundColor(AppColors.backgroundLight)
.buttonStyle(.plain)
.sheet(isPresented: $showChangePaymentSheet) {
ChangePaymentSheet(
pixContext: currentContext,

View File

@@ -24,6 +24,7 @@ struct OrderDetailsView: View {
.setLeftButton(image: AnyView(AppBackButtonIcon())) { dismiss() }
.setTitle(text: Text("Detalhes do Pedido").font(AppTypography.heading2).foregroundStyle(AppColors.textPrimary))
.setNavigationBarBackgroundColor(AppColors.backgroundLight)
.buttonStyle(.plain)
}
private var content: some View {

View File

@@ -44,6 +44,7 @@ struct OrderTrackingView: View {
}
.setTitle(text: Text("Pedido \(displayOrderTitle)").font(AppTypography.heading2).foregroundStyle(AppColors.textPrimary))
.setNavigationBarBackgroundColor(AppColors.backgroundLight)
.buttonStyle(.plain)
.navigationDestination(item: $reviewDraft) { draft in
MyReviewsView(initialOrder: draft)
}

View File

@@ -23,6 +23,7 @@ struct OrdersView: View {
.setLeftButton(image: AnyView(AppBackButtonIcon())) { dismiss() }
.setTitle(text: Text("Meus Pedidos").font(AppTypography.heading2).foregroundStyle(AppColors.textPrimary))
.setNavigationBarBackgroundColor(AppColors.backgroundLight)
.buttonStyle(.plain)
}
private var content: some View {

View File

@@ -17,6 +17,7 @@ struct PizzaFlavorAddonsSheet: View {
.setLeftButton(image: AnyView(AppBackButtonIcon())) { dismiss() }
.setTitle(text: Text("Adicionais").font(AppTypography.heading2).foregroundStyle(AppColors.textPrimary))
.setNavigationBarBackgroundColor(AppColors.backgroundLight)
.buttonStyle(.plain)
}
private var content: some View {

View File

@@ -225,6 +225,7 @@ struct PizzaProductDetailSheet: View {
.setLeftButton(image: AnyView(AppBackButtonIcon())) { dismiss() }
.setTitle(text: Text("Monte sua pizza").font(AppTypography.heading2).foregroundStyle(AppColors.textPrimary))
.setNavigationBarBackgroundColor(AppColors.backgroundLight)
.buttonStyle(.plain)
}
private var content: some View {

View File

@@ -79,6 +79,7 @@ struct ProductDetailSheet: View {
.setLeftButton(image: AnyView(AppBackButtonIcon())) { dismiss() }
.setTitle(text: Text("Detalhes").font(AppTypography.heading2).foregroundStyle(AppColors.textPrimary))
.setNavigationBarBackgroundColor(AppColors.backgroundLight)
.buttonStyle(.plain)
}
private var content: some View {

View File

@@ -37,6 +37,7 @@ struct PublicLocationPickerView: View {
.setLeftButton(image: AnyView(AppBackButtonIcon())) { back() }
.setTitle(text: Text(step == .state ? "Escolha seu estado" : "Escolha sua cidade").font(AppTypography.heading2).foregroundStyle(AppColors.textPrimary))
.setNavigationBarBackgroundColor(AppColors.backgroundLight)
.buttonStyle(.plain)
}
private var content: some View {

View File

@@ -37,6 +37,7 @@ struct MyReviewsView: View {
.setLeftButton(image: AnyView(AppBackButtonIcon())) { dismiss() }
.setTitle(text: Text("Minhas Avaliações").font(AppTypography.heading2).foregroundStyle(AppColors.textPrimary))
.setNavigationBarBackgroundColor(AppColors.backgroundLight)
.buttonStyle(.plain)
.navigationDestination(item: $selectedDraft) { draft in
OrderReviewView(draft: draft) {
Task { await loadReviewsFromBackend(forceRefresh: true) }
@@ -449,6 +450,7 @@ struct OrderReviewView: View {
.setLeftButton(image: AnyView(AppBackButtonIcon())) { dismiss() }
.setTitle(text: Text("Avaliar Pedido").font(AppTypography.heading2).foregroundStyle(AppColors.textPrimary))
.setNavigationBarBackgroundColor(AppColors.backgroundLight)
.buttonStyle(.plain)
}
private var content: some View {

View File

@@ -24,6 +24,7 @@ struct SavedCardsView: View {
.setLeftButton(image: AnyView(AppBackButtonIcon())) { dismiss() }
.setTitle(text: Text("Meus Cartões").font(AppTypography.heading2).foregroundStyle(AppColors.textPrimary))
.setNavigationBarBackgroundColor(AppColors.backgroundLight)
.buttonStyle(.plain)
}
private var content: some View {

View File

@@ -35,6 +35,7 @@ struct UserProfileView: View {
.setLeftButton(image: AnyView(AppBackButtonIcon())) { dismiss() }
.setTitle(text: Text("Meu Perfil").font(AppTypography.heading2).foregroundStyle(AppColors.textPrimary))
.setNavigationBarBackgroundColor(AppColors.backgroundLight)
.buttonStyle(.plain)
}
private var content: some View {