Latest 1.3.0
Homepage https://github.com/Meniny/MXMaterialAlert-in-Objective-C
License MIT
Platforms ios 7.0, requires ARC
Dependencies MXBaseAlert
Frameworks Foundation, UIKit

MXMaterialAlert-in-Objective-C

MXMaterialAlert is a material style alert view for iOS.

Installation with CocoaPods

pod 'MXMaterialAlert'

Usage

#import "MXMaterialAlert.h"
MXMaterialAlert *material = [MXMaterialAlert makeWithTitle:@"Title" format:@"Some content hereļ¼Œhahahahahha😄", arc4random_uniform(999)];
[material addButton:@"Confirm" forType:MXMaterialAlertButtonTypeConfirm];

__weak typeof(self) weakSelf = self;
[material setOnClickListener:^(NSString *title, NSUInteger index) {
  __strong typeof(self) strongSelf = weakSelf;
  [strongSelf doSomeOtherThings];
}];

[material show];
[[MXAlertDefault standardDefaults] setDefaultNegativeButtonColor:[UIColor myColor]];

Preview

one button

two buttons

moew buttons

Latest podspec

{
    "name": "MXMaterialAlert",
    "version": "1.3.0",
    "summary": "A material style alert view for iOS.",
    "description": "The first stable version of MXMaterialAlert, a material style alert view for iOS.",
    "homepage": "https://github.com/Meniny/MXMaterialAlert-in-Objective-C",
    "license": "MIT",
    "authors": "Elias Abel",
    "platforms": {
        "ios": "7.0"
    },
    "source": {
        "git": "https://github.com/Meniny/MXMaterialAlert-in-Objective-C.git",
        "tag": "1.3.0"
    },
    "source_files": "MXMaterialAlert-OC/*",
    "frameworks": [
        "Foundation",
        "UIKit"
    ],
    "dependencies": {
        "MXBaseAlert": []
    },
    "requires_arc": true
}

Pin It on Pinterest

Share This