ContentMarginPlacement

The placement of margins.

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

Declaration

React
type ContentMarginPlacement = 'automatic' | 'scrollContent' | 'scrollIndicators';
Swift
struct ContentMarginPlacement

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

Type properties

Overview

Different views can support customizating margins that appear in different parts of that view. Use values of this type to customize those margins of a particular placement.

For example, use a ContentMarginPlacement.scrollIndicators placement to customize the margins of scrollable view's scroll indicators separately from the margins of a scrollable view's content.

Use this type with the View.contentMargins(_:for:) modifier.

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

Used by

See also

More in Other values.