YQQPopupView
使用示例
使用方式一
YQQPopupView *popupView = [YQQPopupView popupViewWithTitle:@"这是title" detail:@"这是详情"];
[popupView show];
使用方式二
YQQPopupView *popupView = popupView = [YQQPopupView popupViewWithTitle:@"这是title" detail:@"这是详情" buttonTitles:@[@"cancel", @"ok"] selectIndex:^(NSInteger index, NSString * _Nullable inputContent) {
}];
[popupView show];
使用方式三
popupView = [YQQPopupView popupViewWithTitle:@"这是title" detail:@"这是详情" placeholder:@"请输入" buttonTitles:@[@"cancel", @"ok"] selectIndex:^(NSInteger index, NSString * _Nullable inputContent) {
}];
[popupView show];
使用方式四
popupView = [YQQPopupView popupViewWithTitle:@"这是title" detail:@"这是详情" placeholder:@"请输入" inputType:YQQPopupViewInputTypeTextField buttonTitles:@[@"cancel", @"ok"] buttonType:YQQPopupViewButtonTypeShapeless selectIndex:^(NSInteger index, NSString * _Nullable inputContent) {
}];
[popupView show];
使用方式五
popupView = [[YQQPopupView alloc] initWithTitle:@"这是title" detail:@"这是详情" placeholder:@"请输入" inputType:YQQPopupViewInputTypeTextView buttonTitles:@[@"cancel", @"ok"] buttonType:YQQPopupViewButtonTypeRoundCorner selectIndex:^(NSInteger index, NSString * _Nullable inputContent) {
}];
[popupView show];
使用方式六
YQQCustomPopupView *customeView = [YQQCustomPopupView popupViewWithIimage:[UIImage imageNamed:@"404"] buttonTitles:@[@"cancel", @"ok"] selectIndex:^(NSInteger index, NSString * _Nullable inputContent) {
}];
[customeView show];
使用方式七
YQQPopupView *popupView = [YQQPopupView popupViewWithTitle:@"这是title" detail:@"这是详情"];
popupView.useMotionEffects = YES;
popupView.closeOnTouchUpOutside = NO;
[popupView show];
安装
手动
复制代码,将YQQPopupView文件夹拖入项目中,#import "YQQPopupView.h",即可开始使用;
CocoaPods
target '<Your Target Name>' do
pod 'YQQPopupView'
end
先运行pod repo update
,再运行pod install