0
NavigationView {
            VStack {
                TabView {
                    ForEach(0...4, id: \.self) { index in
                        VStack {
                            ZStack(alignment: .center) {
                                color[index]
                                Text("green")
                            }
                            Spacer()
                                .frame(height: 56)
                        }
                    }
                }
                .tabViewStyle(PageTabViewStyle())
                .edgesIgnoringSafeArea(.top)
                Button("pressed", action: { })
                Text("!!!!!")
            }
            .edgesIgnoringSafeArea(.top)
        }

Declaring PageStyleTabView within NavigationView and applying edgeIgnoreSafearea creates a margin in the top portion of the pagingControl. How can I fix this?

I tried to hide navigation bar and tried to make a pagecontrol with scrollView, but failed.

0 Answers0