BBABottomActionSheetListView.h
1.2 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
//
// BBABottomActionSheetListView.h
// BBAUIKit
//
// Created by Ning,Liujie on 2020/7/25.
// Copyright © 2020 Baidu. All rights reserved.
//
#import <UIKit/UIKit.h>
#import "BBABottomActionSheetItem.h"
typedef void (^actionSheetItemClickBlock)(NSInteger index);
@interface BBABottomActionSheetListView : UIView
/// 点击事件回调
@property (nonatomic, copy) actionSheetItemClickBlock itemClickBlock;
/// 创建展示的列表
///
/// @param title BBABottomActionSheet的标题
/// @param itemsArray 展示的文本区域的数组
/// @param customItemsArray 展示的自定义的区域数组
- (instancetype)initWithTitle:(NSString *)title
items:(NSArray <BBABottomActionSheetItem *> *)itemsArray
customItems:(NSArray <BBABottomActionSheetCustomItem *> *)customItemsArray;
/// 外部更新了已加入列表item数据或者自定义的视图,需要刷新界面,调用该方法进行界面刷新
- (void)reloadData;
/// 更新列表中的列表项,根据传入新的列表项刷新列表
- (void)reloadWithItems:(NSArray <BBABottomActionSheetItem *> *)itemsArray
customItems:(NSArray <BBABottomActionSheetCustomItem *> *)customItemsArray;
@end