CNCollectionViewCell.m 889 Bytes
//
//  CNCollectionViewCell.m
//  CNLiveCMineModule_Example
//
//  Created by CNLive on 2022/1/17.
//  Copyright © 2022 杨苓玉. All rights reserved.
//

#import "CNCollectionViewCell.h"

@implementation CNCollectionViewCell
- (instancetype)initWithFrame:(CGRect)frame
{
    if (self = [super initWithFrame:frame]) {
        [self.contentView addSubview:self.titleLabel];
    }
    return self;
}

- (UILabel *)titleLabel {
    if (!_titleLabel) {
        _titleLabel = [[UILabel alloc] initWithFrame:CGRectMake(0, 0, self.frame.size.width, self.frame.size.height)];
        _titleLabel.font = [UIFont systemFontOfSize:18];
        _titleLabel.textColor = [UIColor purpleColor];
        _titleLabel.textAlignment = NSTextAlignmentCenter;
        _titleLabel.backgroundColor = [UIColor colorWithRed:247/255.0 green:246/255.0 blue:249/255.0 alpha:1];
    }
    return _titleLabel;
}
@end