BackgroundProminence

The prominence of backgrounds underneath other views.

StructureiOS 17.0+macOS 14.0+tvOS 17.0+watchOS 10.0+BackgroundProminence in SwiftUI

Declaration

React
type BackgroundProminence = 'increased' | 'standard';
Swift
struct BackgroundProminence

Pass a literal, or build one with SwiftUI.BackgroundProminence from import { SwiftUI } from 'swiftui-react-native'.

Type properties

Overview

Background prominence should influence foreground styling to maintain sufficient contrast against the background. For example, selected rows in a List and Table can have increased prominence backgrounds with accent color fills when focused; the foreground content above the background should be adjusted to reflect that level of prominence.

This can be read and written for views with the EnvironmentValues.backgroundProminence property.

From Apple’s SwiftUI documentation. Code samples there are Swift.

See also

More in Appearance.