DismissButtonConfig

public struct DismissButtonConfig

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

  • 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
  • The location for the bar button. The default is .left.

    Declaration

    Swift

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

    Declaration

    Swift

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

    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. The default is .left.

    style

    The style for the bar button. The default is .plain.

    content

    The content for the bar button. The default is .systemItem(.cancel).

    Return Value

    A new configuration instance.