All Projects → egmoll7 → Emalertcontroller

egmoll7 / Emalertcontroller

Licence: mit
EMAlertController is a beautiful alternative to the stock iOS UIAlertController

Programming Languages

swift
15916 projects

Projects that are alternatives of or similar to Emalertcontroller

Sclalertview
Beautiful animated Alert View. Written in Objective-C
Stars: ✭ 3,426 (+1782.42%)
Mutual labels:  cocoapods, alert
Ismessages
This is simple extension for presenting system-wide notifications from top/bottom of device screen.
Stars: ✭ 299 (+64.29%)
Mutual labels:  cocoapods, alert
Alertift
Swifty, modern UIAlertController wrapper.
Stars: ✭ 242 (+32.97%)
Mutual labels:  cocoapods, alert
Cdalertview
Highly customizable alertview and alert/notification/success/error/alarm popup written in Swift
Stars: ✭ 1,056 (+480.22%)
Mutual labels:  cocoapods, alert
Statusalert
Display Apple system-like self-hiding status alerts. It is well suited for notifying user without interrupting user flow in iOS-like way.
Stars: ✭ 809 (+344.51%)
Mutual labels:  cocoapods, alert
Siren
Siren checks a user's currently installed version of your iOS app against the version that is currently available in the App Store.
Stars: ✭ 3,892 (+2038.46%)
Mutual labels:  cocoapods, alert
Harpy
Harpy checks a user's currently installed version of your iOS app against the version that is currently available in the App Store. If a new version is available, an alert can be presented to the user informing them of the newer version, and giving them the option to update the application.
Stars: ✭ 2,619 (+1339.01%)
Mutual labels:  cocoapods, alert
Lcactionsheet
一款简约而不失强大的 ActionSheet,微博、微信和 QQ 都采用了极其类似的样式,完全支持 Swift。
Stars: ✭ 809 (+344.51%)
Mutual labels:  cocoapods, alert
Ehplainalert
Plain style IOS alert
Stars: ✭ 44 (-75.82%)
Mutual labels:  cocoapods, alert
Overlaycontroller
OverlayController easily pop your custom view and provide optional transition animation. written in swift 5.0
Stars: ✭ 94 (-48.35%)
Mutual labels:  cocoapods, alert
Svprogresshud
A clean and lightweight progress HUD for your iOS and tvOS app.
Stars: ✭ 12,339 (+6679.67%)
Mutual labels:  cocoapods
Cocoalumberjack
A fast & simple, yet powerful & flexible logging framework for Mac and iOS
Stars: ✭ 12,584 (+6814.29%)
Mutual labels:  cocoapods
Toactionsheet
A custom-designed reimplementation of the UIActionSheet control for iOS
Stars: ✭ 175 (-3.85%)
Mutual labels:  cocoapods
Modernavplayer
ModernAVPlayer is a persistence AVPlayer wrapper
Stars: ✭ 179 (-1.65%)
Mutual labels:  cocoapods
Ktvhttpcache
A powerful media cache framework.
Stars: ✭ 2,113 (+1060.99%)
Mutual labels:  cocoapods
Scout
可能是东半球最灵活的 URL 监控系统
Stars: ✭ 174 (-4.4%)
Mutual labels:  alert
Multipeer
📱📲 A wrapper for the MultipeerConnectivity framework for automatic offline data transmission between devices
Stars: ✭ 170 (-6.59%)
Mutual labels:  cocoapods
Tiercel
简单易用、功能丰富的纯 Swift 下载框架
Stars: ✭ 2,241 (+1131.32%)
Mutual labels:  cocoapods
Frostmourne
frostmourne是基于Elasticsearch, InfluxDB数据,Mysql数据的监控,报警,分析系统. Monitor & alert & alarm & analyze for Elasticsearch && InfluxDB Log Data。主要使用springboot2 + vue-element-admin。 https://frostmourne-demo.github.io/
Stars: ✭ 166 (-8.79%)
Mutual labels:  alert
Glinapppurchase
Tinder Style InApp Purchase Banner
Stars: ✭ 180 (-1.1%)
Mutual labels:  cocoapods

Icon

Language license CocoaPods GitHub stars CocoaPods

EMAlertController is a beautiful alternative to the stock iOS UIAlertController. This library is fully customizable with an implementation like the native UIAlertController.

Icon

Table of Contents

Features

  • [x] Alert Image (Optional)
  • [x] Title
  • [x] Scrollable Message (Optional)
  • [x] Text Fields
  • [x] Closure when a button is pressed
  • [x] Fully Customizable
  • [x] CocoaPods

Requirements

  • iOS 9.0+
  • Xcode 9+

Installation

CocoaPods is a dependency manager for Cocoa projects. You can install it with the following command:

$ gem install cocoapods

To integrate EMAlertController into your Xcode project using CocoaPods, specify it in your Podfile:

source 'https://github.com/CocoaPods/Specs.git'
platform :ios, '9.0'
use_frameworks!

target '<Your Target Name>' do
pod 'EMAlertController'
end

Then, run the following command:

$ pod install

Usage

let alert = EMAlertController(title: "EMAlertView Title", message: "This is a simple message for the EMAlertView")

let cancel = EMAlertAction(title: "CANCEL", style: .cancel)
let confirm = EMAlertAction(title: "CONFIRM", style: .normal) {
// Perform Action
}

alert.addAction(cancel)
alert.addAction(confirm)

Customization

Alert View


Icon

let icon = UIImage(named: "imageName")

alert.iconImage = icon

Title

alert.titleText = "Sample Title"

Title Color

alert.titleColor = UIColor.red
// Default color = UIColor.black

Message

alert.messageText = "Sample message"

Message Color

alert.messageColor = UIColor.red
// Default color = UIColor.black

Message Data Detector Types

alert.dataDetectorTypes = .all

Messages Make Message Selectable

alert.isMessageSelectable = true
// This must be set to `true` in order to highlight the detected data types

Corner Radius

alert.cornerRadius = 10
// Default corner radius = 5

Background Color

alert.backgroundColor = UIColor.white
// Default color = UIColor(red: 250/255, green: 250/255, blue: 250/255, alpha: 1.0)

Background View Color

alert.backgroundViewColor = UIColor.red
// Default color = UIColor.darkGray

Background View Alpha

alert.backgroundViewAlpha = 1.0
// Default alpha = 0.2

Alert Actions


Title

action.title = "Sample Title"

Title Color

action.titleColor = UIColor.red
// Normal style action default color = UIColor(red: 53/255, green: 53/255, blue: 53/255, alpha: 1.0)
// Cancel style action default color = UIColor(red: 230/255, green: 57/255, blue: 70/255, alpha: 1.0)

Title Font

action.titleFont = UIFont.systemFont(ofSize: 14)
// Default font = UIFont.boldSystemFont(ofSize: 16)

Background Color

action.actionBackgroundColor = UIColor.red
// Default color = UIColor.clear

Button Spacing (Only when two buttons are displayed in horizontal)

alert.buttonSpacing = 0
// Default spacing = 15

TextFields


Adding a Text Field

 alert.addTextField { (textField) in
   textField?.placeholder = "Username"
 }

Getting Text from Text Field

guard let username = alert.textFields.first?.text else { return }

TODO

  • [ ] Carthage Support
  • [ ] Actions Scroll Support

License


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

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].