DismissButtonConfig

public struct DismissButtonConfig

A configuration for UIBarButtonItem. Use this configuration to create dismissal/cancel buttons for modally presented view controllers.

  • The location for the bar button.

    Declaration

    Swift

    public let location: Location
  • The style for the bar button.

    Declaration

    Swift

    public let style: Style
  • The content for the bar button.

    Declaration

    Swift

    public let content: Content
  • Initializes a new configuration instance.

    Declaration

    Swift

    public init(location: Location = .left, style: Style = .plain, content: Content = .systemItem(.cancel))

    Parameters

    location

    The location for the bar button.

    style

    The style for the bar button.

    content

    The content for the bar button.

    Return Value

    A new configuration instance.

  • Specifies a bar button’s location in a navigation bar.

    See more

    Declaration

    Swift

    public enum Location
  • Specifies a bar button’s item style.

    See more

    Declaration

    Swift

    public enum Style
  • Specifies the content (title or image) for the bar button.

    See more

    Declaration

    Swift

    public enum Content