Skip to content

WhimDatingApp/JDropDownAlert

 
 

Repository files navigation

JDropDownAlert

Language [![CI Status](http://img.shields.io/travis/Steve Jo/JDropDownAlert.svg?style=flat)](https://travis-ci.org/Steve Jo/JDropDownAlert) Version License Platform Issues

JDropDownALert

Simple DropDown Alert View For Any iOS Projects.

Demo Gifs

top alert bottom alert

Usage

Top

    let alert = JDropDownAlert()
    alert.alertWith("U can use just title")
    
    alert.didTapBlock = {
      print("Top View Did Tapped")
    }
    
    let alert = JDropDownAlert()
    alert.alertWith(titleString, message: messageString)
    
    alert.didTapBlock = {
      print("Top View Did Tapped")
    }

Top With Directions

    let alert = JDropDownAlert(position: .Top, direction: .ToLeft)
    alert.alertWith(titleString, message: messageString)
    
    alert.didTapBlock = {
      print("Top View Did Tapped")
    }
    
    let alert = JDropDownAlert(position: .Top, direction: .ToRight)
    alert.alertWith(titleString, message: messageString)
    
    alert.didTapBlock = {
      print("Top View Did Tapped")
    }

Bottom

    let alert = JDropDownAlert(position: .Bottom)
    alert.alertWith(titleString, message: messageString)
    
    alert.didTapBlock = {
      print("Bottom Alert View Did Tapped")
    }

Bottom With Directions

    let alert = JDropDownAlert(position: .Bottom, direction: .ToLeft)
    alert.alertWith(titleString, message: messageString)
    
    alert.didTapBlock = {
      print("Bottom Alert View Did Tapped")
    }
    
    let alert = JDropDownAlert(position: .Bottom, direction: .ToRight)
    alert.alertWith(titleString, message: messageString)
    
    alert.didTapBlock = {
      print("Bottom Alert View Did Tapped")
    }

Different Positions and Animation Directions

  enum AlertPosition {
    case Top
    case Bottom
  }
  
  enum AnimationDirection {
    case ToLeft
    case ToRight
    case Normal
  }

To run the example project, clone the repo, and run pod install from the Example directory first.

Requirements

iOS 8.0 +

Installation

JDropDownAlert is available through CocoaPods. To install it, simply add the following line to your Podfile:

pod "JDropDownAlert"

Add the JDropDownAlert.swift in to your project.

Credits

Author

Contributors

Any contribution is welcome. Just submit a pull request.

License

JDropDownAlert is available under the MIT license. See the LICENSE file for more info.

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • Shell 54.0%
  • Swift 39.6%
  • Ruby 3.5%
  • Objective-C 2.9%