https://github.com/vberihuete/dctoastview
This is part of the DC UI libraries to handle a simple Stack view and Auto layout friendly Toast View
https://github.com/vberihuete/dctoastview
alertview autolayout cocoapods ios message spm stackview swift swift-4 swift-package-manager toast toast-message
Last synced: 6 months ago
JSON representation
This is part of the DC UI libraries to handle a simple Stack view and Auto layout friendly Toast View
- Host: GitHub
- URL: https://github.com/vberihuete/dctoastview
- Owner: vberihuete
- Created: 2018-11-25T21:58:20.000Z (almost 7 years ago)
- Default Branch: master
- Last Pushed: 2019-12-07T15:38:48.000Z (almost 6 years ago)
- Last Synced: 2025-04-08T20:03:16.874Z (6 months ago)
- Topics: alertview, autolayout, cocoapods, ios, message, spm, stackview, swift, swift-4, swift-package-manager, toast, toast-message
- Language: Swift
- Homepage:
- Size: 162 KB
- Stars: 4
- Watchers: 2
- Forks: 1
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# DCToast
A Toast View made in swift using auto layout and stack views.

## Requirements
iOS 11 or above and swift 4.2
## Installation
DCToastView is available through Swift package manager. To install
it, simply add this git repository into your xcode spm depenencies:## How to
After you have your cocoapods set up done and already added the pod for DCToastView, you just need to import in the View Controller you will like to use the Filter View.
```swift
import DCToast
```Then just call the shared Toast Presenter instance to show or remove a toast message
```swift
ToastPresenter.shared.show(in: self.view, message: "This is a toast")
``````swift
ToastPresenter.shared.remove()
```Constructor properties go as follows:
* **view**: The view in which the toast is going to be presented
* **message**: The message that the toast will show
* **toastPlace**: The place which can be .down or .up
* **backgroundColor**: The background color of the toast; defaults to black
* **textColor**: The text color of the message; defaults to white
* **timeOut**: The amount of seconds for the toast to dismiss if not provided it means that the toast will be sticky (will remain until touched); defaults to nil
* **roundness**: How round the toast will be: .none, .low, .mid, .high; defaults to .mid## Author
Vincent Berihuete, vberihuete@gmail.com
## License
DCToastView is available under the MIT license. See the LICENSE file for more info.