lsd

LSDialogViewController

Custom Dialog for iOS written in Swift

Showing:

Popularity

Downloads/wk

0

GitHub Stars

70

Maintenance

Last Commit

2yrs ago

Contributors

0

Package

Dependencies

0

License

MIT

Categories

Readme

LSDialogViewController Logo

Language: Swift 5.0 License Platform CocoaPodsDL Carthage Compatible

LSDialogViewController is able to easily display a custom view as a dialog.

LSDialogViewController_animation

Requirement

  • Swift 2+ (Swift 5 is ready 👍)
  • iOS 8.0+

Installation

From CocoaPods

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

# for Swift 5.0
pod 'LSDialogViewController', '~> 4.0'

# for Swift 4.2
pod 'LSDialogViewController', '~> 3.0'

# for Swift 3
pod 'LSDialogViewController', '~> 0.1.9'

From Carthage

Add this to Cartfile.

github "daihase/LSDialogViewController"

And then, run this command.

$ carthage update

Usage

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

Examples


import LSDialogViewController
// to show the dialog
let dialogViewController: CustomDialogViewController = CustomDialogViewController(nibName:"CustomDialog", bundle: nil)
dialogViewController.delegate = self
self.presentDialogViewController(dialogViewController, animationPattern: animationPattern, completion: { () -> Void in })

// to dismiss the dialog
self.dismissDialogViewController(animationPattern)

Configuration

presentDialogViewController(
  // required
  dialogViewController: :UIViewController,
  // default LSAnimationPattern.FadeInOut
  animationPattern: LSAnimationPattern,
  // default LSDialogBackgroundViewType.Solid
  backgroundViewType: LSDialogBackgroundViewType,
  // default true
  dismissButtonEnabled: Bool,
  // optional
  completion: (() -> Swift.Void)?
)

Other background view type. (.Gradient .None)

Image . Image

License

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

Rate & Review

Great Documentation0
Easy to Use0
Performant0
Highly Customizable0
Bleeding Edge0
Responsive Maintainers0
Poor Documentation0
Hard to Use0
Slow0
Buggy0
Abandoned0
Unwelcoming Community0
100