Get Updates By E-mail 

Article Written By:
Johann Dowa

Open Source iOS Component For Creating Great Looking Custom Alert Views Made With Swift

  •  
  •  
  •  
  •  
  •  

I’ve mentioned a number of custom iOS alert view components, most recently AMSmoothAlert which features a clean style and nice popping animations.

Here’s an open source component created with Swift allowing you to create similarly styled alert views called SCLAlertView-Swift from Viktor Radchenko.

SCLAlertView-Swift features several different styles of alert for errors, notice, warning and info alerts and a very simple syntax.  You can customize the title, subtitle, and button text.

This example from the readme shows a custom alert view creation:

// Advanced
SCLAlertView().showTitle(
view: self, // Parent view controller
title: "Congratulations", // Title of view
subTitle: "Operation successfully completed.", // String of view
duration: kDefaultAnimationDuration, // Duration to show before closing automatically, default: 2.0
completeText: "Done", // Optional button value, default: ""
style: .Success // Styles - see below.
)

Here are a couple of images from the readme showing two different styles of alert views created with SCLAlertView-Swift:

SCLAlertView-Swift

You can clone SCLAlertView-Swift from the Github repository at:

https://github.com/vikmeup/SCLAlertView-Swift.git

You can find SCLAlertView-Swift on Github here.

A very nicely styled custom alert view.


  •  
  •  
  •  
  •  
  •  

Submit A Resource

Have you created a useful tutorial, library or tool for iOS development that you would like to get in front of our 300,000+ monthly page views from iOS developers?

You can submit the url here.

The resources we feel will appeal to our readers the most will be posted on the front page.

Comments