Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/alexanderjarvis/PXAlertView
A drop-in replacement for UIAlertView that is more customisable and skinnable
https://github.com/alexanderjarvis/PXAlertView
Last synced: about 1 month ago
JSON representation
A drop-in replacement for UIAlertView that is more customisable and skinnable
- Host: GitHub
- URL: https://github.com/alexanderjarvis/PXAlertView
- Owner: alexanderjarvis
- License: mit
- Created: 2013-09-30T12:27:10.000Z (about 11 years ago)
- Default Branch: master
- Last Pushed: 2016-11-21T04:17:59.000Z (about 8 years ago)
- Last Synced: 2024-10-10T10:35:43.325Z (2 months ago)
- Language: Objective-C
- Size: 1.15 MB
- Stars: 592
- Watchers: 19
- Forks: 95
- Open Issues: 10
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
- awesome - PXAlertView - A drop-in replacement for UIAlertView that is more customisable and skinnable (etc)
- awesome - PXAlertView - A drop-in replacement for UIAlertView that is more customisable and skinnable (etc)
README
# PXAlertView
PXAlertView is a UIAlertView replacement similar to the style in iOS 7 but with a block based API and the ability to customise the styling and add custom views.
## Preview
![Demo Animation](animation.gif)## Features
* Simple block syntax instead of delegates
* Animations that match UIAlertView in iOS 7
* Fully customisable
* Add your own UIView beneath the title## Installation
Add the following to your [CocoaPods](http://cocoapods.org/) Podfile
pod 'PXAlertView', '~> 0.1.0'
or clone as a git submodule,
or just copy ```PXAlertView.h``` and ```.m``` into your project.
## Usage
See [PXAlertView.h](Classes/PXAlertView.h) for the complete API.
### An Example
```Objective-C
[PXAlertView showAlertWithTitle:@"The Matrix"
message:@"Pick the Red pill, or the blue pill"
cancelTitle:@"Blue"
otherTitle:@"Red"
completion:^(BOOL cancelled, NSInteger buttonIndex) {
if (cancelled) {
NSLog(@"Cancel (Blue) button pressed");
} else {
NSLog(@"Other (Red) button pressed");
}
}];
```## TODO
* Add style that matches iOS 7 exactly
* Ability to dynamically specify the styling of AlertView: default/dark## License
PXAlertView is available under the MIT license. See the LICENSE file for more info.