Components

PresentationBackground

PresentationBackground adapts SwiftUI's presentationBackground modifier into an explicit surface wrapper.

Example

Requires React 18.2+ or 19 and shared styles. See setup.

Automatic

Loading preview…

Code
'use client';
import { Text } from '@swiftuijs/ui';
import { PresentationBackground } from '@swiftuijs/ui';
export default function Example() {
    return ((<PresentationBackground>
      <Text style={{ padding: '16px 20px' }}>Default modal chrome</Text>
    </PresentationBackground>));
}

Status: adapted

More examples

Materials

API reference

PropTypeRequiredDescription
backgroundStyle'automatic' | 'thinMaterial' | 'regularMaterial' | 'clear'No—
shape'automatic' | 'rounded' | 'capsule'No—

Inherits additional props from IBaseComponent.