Interactive previews iPhone

Uniform Concentric Rectangle

Create a rectangle with the same corner style set on four corners.

Uniform Concentric Rectangle - iOS on iPhone - Portrait - Liquid Glass - Light Mode - Preview

Platform Compatibility

iOS 26.0+ iPadOS 26.0+ macOS 26.0+ watchOS 26.0+ tvOS 26.0+ visionOS 26.0+

Tags

SwiftUI Code

Docs
ZStack(alignment: .bottom) {
    // Respects the device frame's corner radius
    ConcentricRectangle(corners: .concentric, isUniform: true)
        .fill(Color.blue)
        .frame(height: 50)
        .frame(maxHeight: .infinity, alignment: .bottom)
        .padding(30)
        .ignoresSafeArea()

    ZStack {
        // Gets radius from parent rect
        ConcentricRectangle()
            .fill(.secondary)

        // Respects the parent rectangle's corner radius
        ConcentricRectangle(corners: .concentric, isUniform: true)
            .fill(.red)
            .frame(width: 200, height: 200)
            .padding([.trailing, .bottom])
    }
    .containerShape(
            .rect(cornerRadius: 42)
    )
    .frame(width: 250, height: 250)
    .padding(.bottom)
}

Found an issue or have a suggestion?

Created: February 28, 2026Updated: November 19, 2026

More ConcentricRectangle Components

View all
Concentric Rectangle - iOS on iPhone - Portrait - Liquid Glass - Light Mode - Preview
initializer

Concentric Rectangle

A concentric rectangle whose corner radii are defined from the same circle center as its parent element. The outermost parent is the device frame.

Explore Other Components

Browse all
ContainerRelativeShape - iOS on iPhone - Portrait - Liquid Glass - Light Mode - Preview
modifier

ContainerRelativeShape

A shape that is replaced by an inset version of the current container shape. If no container shape was defined, is replaced by a rectangle

Horizontal Radio Group Layout - macOS - Liquid Glass - Light Mode - Preview
modifier

Horizontal Radio Group Layout

Sets the style for radio group style pickers within this view to be horizontally positioned with the radio buttons inside the layout.

List Item Tint - iOS on iPhone - Portrait - Flat Design - Light Mode - Preview
modifier

List Item Tint

Sets a fixed tint color for content in a list.

UIKit Content Background colors - iOS on iPhone - Portrait - Flat Design - Light Mode - Preview
type

UIKit Content Background colors

The UIKit colors that are also used in other components like in List and GroupBox

Color Gradient - iOS on iPhone - Portrait - Flat Design - Light Mode - Preview
modifier

Color Gradient

The Color gradient modifier

Gauge - iOS on iPhone - Portrait - Liquid Glass - Light Mode - Preview
initializer

Gauge

Creates a gauge showing a value within a range and describes the gauge’s purpose and current value

SegmentedPickerStyle - iOS on iPhone - Portrait - Liquid Glass - Light Mode - Preview
style

SegmentedPickerStyle

A picker style that presents the options in a segmented control. Use this style when there are two to five options. Consider using menu when there are more than five options.

List Background Prominence - macOS - Flat Design - Light Mode - Preview
environment

List Background Prominence

The prominence of the background underneath views associated with this environment.