Quantcast
Channel: Active questions tagged header - Stack Overflow
Viewing all articles
Browse latest Browse all 794

SwiftUI - Avoid translucent background for List header

$
0
0

I have a simple List with a header like this:

NavigationStack{  List{    Section{      View()    }header:{       Text("Section Header")     }  }  .listStyle(.plain)}

and when scrolling the list, the header gets this weird translucent background that I hate:

enter image description here

Is there a way to make the background not translucent, just dark or light based on the color scheme? I tried to set the section background to clear or custom colors with no success.


Viewing all articles
Browse latest Browse all 794

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>