ToastView SwiftUI - admiral-team/admiralui-ios GitHub Wiki

Class

An input field with an informer. It is necessary if additional information may be required to fill in the field correctly.


Declaration

public struct ToastView: View

Overview

A view notify the user of a changing information. It has image or circle timer view, text, link button for get more information and close button for remove notification from screen.

Toast view can be of two types.

The first type is default type for presenting on top screen and after some time view will close. This type serves for presenting important information. For example it can be message about error connection or message from friend.

The second type is action type for presenting on bottom screen and toast view contain timer for presenting when view will close. It type allow cancel action while view don't close.

Live example

Configure a ToastView

ToastView(
     title: "At break point",
     linkText: "Link Text",
     linkAction: {},
     imageType: .info,
     imageColorType: .info,
     closeAction: {},
     type: .default
)

Contribution

You can help us to find bugs or ask us to add features.

  • To start issue please use ready-made templates.
  • To make changes to the repository, you need to create a fork of the project, make changes to the code and create a pull request in our project. You can read more about this in the Github documentation.