View
public extension View
-
Adds a replacement button for
Views being presented in aNavigationStack.Declaration
Swift
@MainActor public func goBackButton(buttonImage: Image? = nil, useGlassBackground: Bool? = nil, selectionAction: (() -> Void)?) -> some ViewParameters
buttonImageThe button image to show for the back button.
useGlassBackgroundDetermines whether the Liquid Glass background should be shown in iOS 26. The default visibility is
automatic.selectionActionAn optional action to perform when the back button is tapped.
Return Value
The
Viewwhich provides the navigation bar customization. -
Handles the removal of a Destination from the Destinations ecosystem when its associated
Viewdisappears.Declaration
Swift
@MainActor public func onDestinationDisappear<DestinationType, ContentType, TabType>(destination: any ViewDestinationable<DestinationType, ContentType, TabType>, navigationDestination: (any NavigatingViewDestinationable)? = nil, action: (() -> Void)? = nil) -> some View where DestinationType : RoutableDestinations, ContentType : ContentTypeable, TabType : TabTypeableParameters
destinationA
Destinationwhose disappearance should be tracked.navigationDestinationA Destination whose
Viewcontains aNavigationStack.actionAn optional action to perform when the
Viewdisappears.Return Value
A
Viewwhich runs the removal logic and optional action when it disappears. -
Provides a
ViewModifierwhich can present a Destination as a sheet.Declaration
Swift
@MainActor public func destinationSheet(presentation: SheetPresentation) -> some ViewParameters
presentationThe configuration object for a sheet presentation.
Return Value
The
Viewwhich provides the sheet presentation.
View on GitHub