This commit is contained in:
Daniel Arantes Loverde
2026-02-06 09:51:53 -03:00
parent 379bb35cfa
commit 92c2a67736
13 changed files with 574 additions and 138 deletions

View File

@@ -7,11 +7,57 @@ struct ContentView: View {
@State var appState = AppState()
var body: some View {
switch root {
case .auth:
AuthFlowView(root: $root, selectedTab: $selectedTab, tokenStore: tokenStore, appState: $appState)
case .main:
MainTabView(selectedTab: $selectedTab, root: $root, tokenStore: tokenStore, appState: $appState)
Group {
switch root {
case .auth:
AuthFlowView(root: $root, selectedTab: $selectedTab, tokenStore: tokenStore, appState: $appState)
case .main:
MainTabView(selectedTab: $selectedTab, root: $root, tokenStore: tokenStore, appState: $appState)
}
}
.sheet(item: $appState.activeModal) { modal in
switch modal {
case .addressPicker:
AddressPickerModalView()
case .filters:
FiltersModalView()
}
}
}
}
struct AddressPickerModalView: View {
var body: some View {
NavigationStack {
VStack(spacing: 12) {
Text("Selecionar endereco")
.font(AppTypography.heading2)
Text("Fluxo de endereco sera implementado na etapa de checkout/perfil.")
.font(AppTypography.body)
.multilineTextAlignment(.center)
.foregroundStyle(AppColors.textMuted)
}
.padding(24)
.frame(maxWidth: .infinity, maxHeight: .infinity)
.background(AppColors.backgroundLight)
}
}
}
struct FiltersModalView: View {
var body: some View {
NavigationStack {
VStack(spacing: 12) {
Text("Filtros")
.font(AppTypography.heading2)
Text("Filtros de busca serao ligados na integracao real da Home com API.")
.font(AppTypography.body)
.multilineTextAlignment(.center)
.foregroundStyle(AppColors.textMuted)
}
.padding(24)
.frame(maxWidth: .infinity, maxHeight: .infinity)
.background(AppColors.backgroundLight)
}
}
}