mirror of
https://github.com/HackPlan/TTGSnackbar.git
synced 2026-04-22 10:47:56 +08:00
Update README; Fix travis.yml
This commit is contained in:
@@ -4,7 +4,7 @@ cache: cocoapods
|
||||
podfile: Example/Podfile
|
||||
before_install:
|
||||
- gem install cocoapods --pre --no-rdoc --no-ri --no-document --quiet
|
||||
- pod install --project-directory=Example-Swift
|
||||
- pod install --project-directory=Example
|
||||
script:
|
||||
- set -o pipefail
|
||||
- xcodebuild -version
|
||||
|
||||
10
README.md
10
README.md
@@ -41,13 +41,13 @@ import TTGSnackbar
|
||||
|
||||
# Usage
|
||||
## Show a simple message
|
||||

|
||||

|
||||
```
|
||||
let snackbar = TTGSnackbar.init(message: "Message", duration: .Short)
|
||||
snackbar.show()
|
||||
```
|
||||
## Show a simple message with an action button
|
||||

|
||||

|
||||
```
|
||||
let snackbar = TTGSnackbar.init(message: "Message", duration: .Middle, actionText: "Action")
|
||||
{ (snackbar) -> Void in
|
||||
@@ -57,7 +57,7 @@ snackbar.show()
|
||||
```
|
||||
|
||||
## Show a simple message with a long running action
|
||||

|
||||

|
||||
```
|
||||
let snackbar = TTGSnackbar.init(message: "Message", duration: .Forever, actionText: "Action")
|
||||
{ (snackbar) -> Void in
|
||||
@@ -71,7 +71,7 @@ snackbar.show()
|
||||
```
|
||||
|
||||
## Show a simple message with two action buttons
|
||||

|
||||

|
||||
```
|
||||
let snackbar: TTGSnackbar = TTGSnackbar.init(message: "Two actions !", duration: .Long)
|
||||
|
||||
@@ -89,7 +89,7 @@ snackbar.show()
|
||||
```
|
||||
|
||||
## Show a simple message with an icon image
|
||||

|
||||

|
||||
```
|
||||
let snackbar: TTGSnackbar = TTGSnackbar.init(message: "Two actions !", duration: .Long)
|
||||
|
||||
|
||||
BIN
Resources/snackbar_1.png
Normal file
BIN
Resources/snackbar_1.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 1.7 KiB |
BIN
Resources/snackbar_2.png
Normal file
BIN
Resources/snackbar_2.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 2.4 KiB |
BIN
Resources/snackbar_3.png
Normal file
BIN
Resources/snackbar_3.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 2.2 KiB |
BIN
Resources/snackbar_4.png
Normal file
BIN
Resources/snackbar_4.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 4.1 KiB |
BIN
Resources/snackbar_5.jpg
Normal file
BIN
Resources/snackbar_5.jpg
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 6.6 KiB |
Reference in New Issue
Block a user