| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115 | ////  ASVipCenterLineItemView.m//  Asteria////  Created by iOS on 2023/6/27.//#import "ASVipCenterLineItemView.h"@interface ASVipCenterLineItemView ()@property (nonatomic, strong) UILabel *titleLb;@property (nonatomic, strong) UIImageView *moreV;@property (nonatomic, strong) UIView *lineV;@property (nonatomic, strong) UIButton *bt;@end@implementation ASVipCenterLineItemView- (void)setData:(NSString *)title canGoNext:(BOOL)canGoNext {    self.titleLb.text = title;    self.bt.hidden = !canGoNext;}- (void)selectBtAction {    if (self.selectCallBack) {        self.selectCallBack();    }}- (instancetype)initWithFrame:(CGRect)frame {    self = [super initWithFrame:frame];    if (self) {        [self loadSubVs];    }    return self;}- (void)loadSubVs {    self.backgroundColor = UIColor.clearColor;    [self addSubview:self.titleLb];    [self addSubview:self.moreV];    [self addSubview:self.lineV];    [self addSubview:self.bt];        [self.titleLb mas_makeConstraints:^(MASConstraintMaker *make) {        make.height.equalTo(@78);        make.top.bottom.equalTo(self);        make.leading.equalTo(self).offset(30);    }];    [self.moreV mas_makeConstraints:^(MASConstraintMaker *make) {        make.width.equalTo(@7);        make.height.equalTo(@13);        make.centerY.equalTo(self.titleLb);        make.trailing.equalTo(self).offset(-30);    }];    [self.lineV mas_makeConstraints:^(MASConstraintMaker *make) {        make.leading.equalTo(self.titleLb);        make.trailing.equalTo(self.moreV);        make.height.equalTo(@1);        make.bottom.equalTo(self);    }];    [self.bt mas_makeConstraints:^(MASConstraintMaker *make) {        make.edges.equalTo(self);    }];}// MARK: - subVs- (UILabel *)titleLb {    if (!_titleLb) {        UILabel *lb = [UILabel baseLb];        lb.font = [UIFont fontWithName:Rob_Bold size:14];        lb.textColor = Col_000;        _titleLb = lb;    }    return _titleLb;}- (UIImageView *)moreV {    if (!_moreV) {        UIImageView *v = [UIImageView baseImgV];        v.image = [UIImage imageNamed:@"uc_more"];        _moreV = v;    }    return _moreV;}- (UIView *)lineV {    if (!_lineV) {        UIView *v = [UIView baseV];        v.backgroundColor = _043632;        v.alpha = 0.1;        _lineV = v;    }    return _lineV;}- (UIButton *)bt {    if (!_bt) {        UIButton *b = [UIButton buttonWithType:UIButtonTypeCustom];        [b addTarget:self action:@selector(selectBtAction) forControlEvents:UIControlEventTouchUpInside];        _bt = b;    }    return _bt;}@end
 |