Latest 1.5
Homepage https://github.com/ShiWeiCN/Goku
License MIT
Platforms ios 8.0, requires ARC
Authors

Goku is an alert view written by swift 3, support both action sheet and alert view style. And now provide 6 styles to show your alert. If you want to use the world of Swift 3, you need Xcode 8+.

Screenshots

GIF
GIF
GIF

Easy to use

Provide a default theme of alert view. So you can use this default theme or create a theme you like.

import Goku

// 🌟 Usage 👇

self.goku.presentAlert(animated: true, closure: { (make) in
    make.theme
        .actionSheet
        .title("Okay/Cancel")
        .message("A customizable action sheet message.")
        .cancel("Cancel")
        .destructive("OK")
        .normal(["Button1", "Button2"])
        .tapped({ (index) in
            print("Tapped index is (index)")
        }
    )
})  

self.goku.presentAlert(animated: true, closure: { (make) in
    make.theme
        .alert
        .success
        .title("Congratulations!")
        .message("You've just displayed this awesome Pop Up View.")
        .cancel("Cancel")
        .normal(["Default 1", "Default 2"])
        .tapped({ (index) in
            print("Tapped index is (index)")
        }
    )
})

For more usage you can see Example

Icon image from SCLAlertView

Installation

Goku is available through Cocoapods.

Add the following line to you Podfile

pod 'Goku', '~> 1.0'

TODO

  • [ ] More animation
  • [x] More beautiful syntax
  • [x] Usage like SnapKit

License

Goku is released under the MIT license. See LICENSE for details.

Latest podspec

{
    "name": "Goku",
    "version": "1.5",
    "license": "MIT",
    "summary": "ud83dude0a Goku is an alert view written by swift 3, support both action sheet and alert view style.",
    "homepage": "https://github.com/ShiWeiCN/Goku",
    "authors": {
        "Shi Wei": "[email protected]"
    },
    "source": {
        "git": "https://github.com/ShiWeiCN/Goku.git",
        "tag": "1.5"
    },
    "platforms": {
        "ios": "8.0"
    },
    "ios": {
        "frameworks": [
            "UIKit",
            "Foundation"
        ]
    },
    "source_files": "Goku/Source/**/*.swift",
    "requires_arc": true,
    "pushed_with_swift_version": "3.1"
}

Pin It on Pinterest

Share This