AdmiralUIKit Views Toast - admiral-team/admiralui-ios GitHub Wiki

Overview

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

Code

 let toastView = ToastView()
 toastView.title = "Text"
 toastView.linkText = "LinkText"
 toastView.type = .default
 toastView.imageType = .success
 toastView.linkAction = {}
 toastView.closeAction ={}

You can create a ToastView with the zero frame rectangle by specifying the following parameters in init:

 - title: Title of the toast.
 - linkText: Title of link button.
 - linkAction: Callback of the link button. If callback equal nil link button is hidden.
 - image: Image of the toast. If image equal nil image is hidden.
 - imageType: Type image.
 - imageColorType: Type color image.
 - closeAction: Callback of the close button. If callback equal nil close button is hidden.
 - type: Type color background toast.

Live Example

To run live demo with ToastView open Xcode and run project with Example target. Then in the Main -> Alerts -> ToastView

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.