Explore SwiftUI
Visually

Discover SwiftUI components and modifiers through visual examples with ready-to-use code samples. Copy, paste, and ship.

WWDC25

What's New in iOS 26

Discover the latest SwiftUI features and enhancements from WWDC25, including iOS 26, watchOS 26, tvOS 26, visionOS 26, and macOS 26.

initializer

Role Button With Default Label

Creates a button that displays a default label.

initializer

SliderTickContentForEach

A type of slider content that creates content by iterating over a collection.

modifier

Section Index Label and Visibility

Sets the label that is used in a section index to point to this section, typically only a single character long. Changes the visibility of the list section index.

modifier

List Section Margins

Set the section margins for the specific edges.

initializer

Glass Effect Container

A view that combines multiple Liquid Glass shapes into a single shape that can morph individual shapes into one another

initializers

Title Toolbar Item Placement

Places content in the title area

modifier

Navigation Subtitle

Configures the view’s subtitle for purposes of navigation, using a localized string

modifier

ToolbarItem Shared Background Visibility

Controls the visibility of the glass background effect on items in the toolbar. In certain contexts, such as the navigation bar on iOS and the window toolbar on macOS, toolbar items will be given a glass background effect that is shared with other items in the same logical grouping

Button

initializer

Role Button With Default Label

Creates a button that displays a default label.

style

Glass Button Styles

A button style that applies glass border artwork based on the button’s context

TextField

RenameButton

A button that triggers a standard rename action

type

EditButton

A button that toggles the edit mode environment value

type

PasteButton

A system button that reads items from the pasteboard and delivers it to a closure.

style

Button Tint

Sets the buttons tint color

style

Button Roles

A value that describes the purpose of a button.

Button Border Shape

A shape used to draw a button’s border.

style

Button Styles

A type that applies standard interaction behavior and a custom appearance to all buttons within a view hierarchy

initializer

Button

Three ways to initialize a button

Toolbars

initializers

Title Toolbar Item Placement

Places content in the title area

modifier

ToolbarItem Shared Background Visibility

Controls the visibility of the glass background effect on items in the toolbar. In certain contexts, such as the navigation bar on iOS and the window toolbar on macOS, toolbar items will be given a glass background effect that is shared with other items in the same logical grouping

initializer

ToolbarSpacer

A standard space item in toolbars

Slider

initializer

SliderTickContentForEach

A type of slider content that creates content by iterating over a collection.

initializer

Custom Slider Ticks

Creates a slider to select a value from a given range, subject to a step increment, which displays the provided labels and customizable ticks.

style

Slider Color

Customizing the color of the slider

initializer

Stepped Min Max Label Slider

Creates a slider to select a value from a given range, subject to a step increment, which displays the provided labels

initializer

Stepped Slider

Creates a slider to select a value from a given range, subject to a step increment

initializer

Slider

Creates a slider to select a value from a given range

DatePicker

initializer

Future DatePicker

Creates an instance that selects multiple dates on or after some start date

initializer

MultiDatePicker

A control for picking multiple dates.

style

DatePicker Colors

Customizing the colors of the date picker

style

FieldDatePickerStyle

A date picker style that displays the components in an editable field

style

StepperFieldDatePickerStyle

A system style that displays the components in an editable field, with adjoining stepper that can increment/decrement the selected component

style

WheelDatePickerStyle

A date picker style that displays each component as columns in a scrollable wheel

style

GraphicalDatePickerStyle

A date picker style that displays an interactive calendar or clock

initializer

Hour Minute Seconds DatePicker

A DatePicker for just hour, minute, and second.

initializer

Future DatePicker

Creates an instance that selects a Date in a closed range

initializer

DatePicker Components

A date picker with only one displayed component

initializer

DatePicker

Creates an instance that selects a Date with an unbounded range

Gauge

style

Gauge Colors

Customizing the colors of different styles with minimal effort

style

CircularGaugeStyle

A gauge style that displays an open ring with a marker that appears at a point along the ring to indicate the gauge’s current value

style

LinearGaugeStyle

A gauge style that displays a bar with a marker that appears at a point along the bar to indicate the gauge’s current value

style

AccessoryLinearCapacityGaugeStyle

A gauge style that displays bar that fills from leading to trailing edges as the gauge’s current value increases

style

AccessoryLinearGaugeStyle

A gauge style that displays bar with a marker that appears at a point along the bar to indicate the gauge’s current value

style

LinearCapacityGaugeStyle

A gauge style that displays a bar that fills from leading to trailing edges as the gauge’s current value increases

style

AccessoryCircularCapacityGaugeStyle

A gauge style that displays a closed ring that’s partially filled in to indicate the gauge’s current value

style

AccessoryCircularGaugeStyle

A gauge style that displays an open ring with a marker that appears at a point along the ring to indicate the gauge’s current value

initializer

Min Max Current Value Gauge

Creates a gauge showing a value within a range and describes the gauge’s current, minimum, and maximum values

initializer

Current Value Gauge

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

initializer

Gauge

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

ProgressView

style

ProgressView Colors

Customizing the colors of the ProgressView

style

CircularProgressViewStyle

The style of a progress view that uses a circular gauge to indicate the partial completion of an activity

style

LinearProgressViewStyle

A progress view that visually indicates its progress using a horizontal bar

initializer

ProgressView

The different ProgressView initializers

ContentUnavailableView

initializer

Content Unavailable

A placeholder for empty results with optional button

type

Content Unavailable Search Text

A pre-built placeholder for empty search results with search text

type

Content Unavailable Search

A pre-built placeholder for empty search results

modifier

Context Menu Preview

A context menu with custom preview

initializer

Menu Action Button

Acts like a button and opens the menu on a secondary gesture

modifier

Context Menu

Adds a context menu to a view.

content

Nested Menu

A Menu inside a Menu

content

Menu Divider

A Menu with a Divider

content

Menu Section

A Section inside a Menu

modifier

Menu Fixed Order

Order items from top to bottom

initializer

Menu

A control for presenting a menu of actions.

ViewThatFits

initializer

ViewThatFits Vertical

A view that adapts to the available vertical space by providing the first child view that fits.

initializer

ViewThatFits

A view that adapts to the available space by providing the first child view that fits.

Divider

style

Divider Height

Customizing the height of the Divider

style

Divider Color

Customizing the color of the Divider

style

Vertical Divider

A vertical visual element that can be used to separate other content

initializer

Divider

A visual element that can be used to separate other content

List

initializer

Outline Group

A structure that computes views and disclosure groups on demand from an underlying collection of tree-structured, identified data.

initializer

Disclosure Group

A view that shows or hides another content view, based on the state of a disclosure control.

initializer

Edit Button

A button that toggles the edit mode environment value.

modifier

Section Index Label and Visibility

Sets the label that is used in a section index to point to this section, typically only a single character long. Changes the visibility of the list section index.

modifier

Move Disabled

Adds a condition for whether the view’s view hierarchy is movable.

modifier

Delete Disabled

Adds a condition for whether the view’s view hierarchy is deletable.

modifier

Refreshable List

Marks this view as refreshable.

modifier

Swipe Action

Adds custom swipe actions to a row in a list.

modifier

List Badge Prominence

Specifies the prominence of badges created by this view.

modifier

List Badge

Generates a badge for the view from an integer value.

environment

List Background Prominence

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

modifier

List Row Background

Places a custom background view behind a list row item.

modifier

Hidden List Row Separator

Sets the display mode to hidden for the separator associated with this specific row.

modifier

Hidden List Section Separator

Sets whether to hide the separator associated with a list section.

modifier

List Section Separator Tint

Sets the tint color associated with a section.

modifier

List Row Separator Tint

Sets the tint color associated with a row.

modifier

List Item Tint

Sets a fixed tint color for content in a list.

modifier

List Section Margins

Set the section margins for the specific edges.

modifier

Compact List Section Spacing

Compact spacing between sections

modifier

Custom List Section Spacing

Sets the spacing between adjacent sections in a List to a custom value.

modifier

List Row Spacing

Sets the vertical spacing between two adjacent rows in a List.

modifier

Default Min List Header Height

The default minimum height of a header in a list.

modifier

Default Min List Row Height

The default minimum height of rows in a list.

modifier

List Row Insets

Applies an inset to the rows in a list.

modifier

Increased Header Prominence

Sets the header prominence to increased for this view.

style

SidebarListStyle

The list style that describes the behavior and appearance of a sidebar list.

style

InsetGroupedListStyle

The list style that describes the behavior and appearance of an inset grouped list.

style

InsetGroupedListStyle

The list style that describes the behavior and appearance of an inset grouped list.

style

InsetListStyle

The list style that describes the behavior and appearance of an inset list.

style

EllipticalListStyle

The list style that describes the behavior and appearance of an elliptical list.

style

CarouselListStyle

The carousel list style.

style

BorderedListStyle

The list style that describes the behavior and appearance of a list with standard border.

GroupBox

modifier

GroupBox Background

Set a custom GroupBox background

initializer

GroupBox With Label

A GroupBox with Label

initializer

GroupBox

A simple GroupBox

ScrollView

style

Hard ScrollEdgeEffect

A scroll edge effect with a hard cutoff and dividing line

Color

style

Color Opacity

The Color opacity modifier

modifier

Color Gradient

The Color gradient modifier

type

UIKit Separator Colors

The UIKit separator colors that are also used in other components, such as the TextField

type

UIKit Content Background colors

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

type

UIKit Text Colors

The UIKit text colors that are also used in other components, such as the TextField

type

UIKit Fill Colors

type

UIKit Label Colors

modifier

Color Variants

HierarchicalShapeStyle, a shape style that maps to one of the numbered content styles

type

Semantic Colors

type

Standard Colors

The SwiftUI standard colors

Text

initializer

Text Format

Creates a text view that displays the formatted representation of a nonstring type supported by a corresponding format style.

Material

type

Materials

All materials

initializer

HelpLink

A button with a standard appearance that opens app-specific help documentation

initializer

TextFieldLink

A control that requests text input from the user when pressed

initializer

Custom Preview Item ShareLink

Creates an instance, with a custom label, that presents the share interface

initializer

ShareLink

A view that controls a sharing presentation

initializer

Link

A control for navigating to a URL

ControlGroup

style

PaletteControlGroupStyle

A control group style that presents its content as a palette.

style

NavigationControlGroupStyle

The navigation control group style

style

MenuControlGroupStyle

A control group style that presents its content as a menu when the user presses the control, or as a submenu when nested within a larger menu

style

CompactMenuControlGroupStyle

A control group style that presents its content as a compact menu when the user presses the control, or as a submenu when nested within a larger menu

initializer

ControlGroup

Creates a new ControlGroup with the specified children

modifier

Navigation Subtitle

Configures the view’s subtitle for purposes of navigation, using a localized string

View

modifier

ControlSize

A control version that is the default size

modifier

Background Extension Effect

Adds the background extension effect to the view. The view will be duplicated into mirrored copies which will be placed around the view on any edge with available safe area. Additionally, a blur effect will be applied on top to blur out the copies

modifier

Glass effect

Applies the Liquid Glass effect to a view

TabView

style

TabView Bottom Accessory Placement

A placement of the bottom accessory in a tab view. You can use this to adjust the content of the accessory view based on the placement

Bottom Accessory

A modifier to place content above the tabs

modifier

Hide Tab Bar On Scroll Down

Minimize the tab bar when downwards scrolling starts. Minimizing is supported for tab bars on only iPhone

GlassEffectContainer

initializer

Glass Effect Container

A view that combines multiple Liquid Glass shapes into a single shape that can morph individual shapes into one another

Shapes

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