






#import "SignRoundCivilCell.h"
#import "SonBlackJoinInfo.h"
#import "Masonry.h"
#import "UIColor+FunColor.h"

@implementation SignRoundCivilCell

- (instancetype)initWithFrame:(CGRect)frame
{
    self = [super initWithFrame:frame];
    if (self) {
        
        self.backgroundColor = [UIColor clearColor];
        
        self.clipsToBounds = YES;
        
        [self addSubview:self.herDrumLabel];
        
        [self.herDrumLabel mas_makeConstraints:^(MASConstraintMaker *make) {
            make.edges.mas_equalTo(UIEdgeInsetsMake(0, 4, 0, 0));
        }];
        
    }
    return self;
}

- (void)setModel:(SonBlackJoinInfo *)model
{
    _model = model;
    _herDrumLabel.text = model.tagsEraShake;
    _herDrumLabel.font = [UIFont systemFontOfSize:model.andExecutingAcceptSpeakQuoteLocations];
    _herDrumLabel.textColor = [UIColor voiceAggregateSlashesSeasonMouthStarting:model.stableWideSuggestFinishRestingMagnitude];
    self.backgroundColor = [[UIColor voiceAggregateSlashesSeasonMouthStarting:model.localeFlowMaintainSentenceDecreaseReplies] colorWithAlphaComponent:model.clangAscenderCommentsAccountsTaskOff];
    self.layer.cornerRadius = 2;
}

- (void)bouncingEncodingLevelRenewLuminance:(void(^)(void))animations completion:(void(^)(BOOL))completion {
    SonBlackJoinInfo *info = (SonBlackJoinInfo *)_model;
    if ([info isKindOfClass:[SonBlackJoinInfo class]] && info.sessionsAskConductorAxesMean > 0) {
        self.transform = CGAffineTransformMakeTranslation(-info.sessionsAskConductorAxesMean, 0);
    }
    [super bouncingEncodingLevelRenewLuminance:animations completion:completion];
}

- (UILabel *)herDrumLabel {
    if (!_herDrumLabel) {
        _herDrumLabel = [[UILabel alloc] init];
        _herDrumLabel.backgroundColor = [UIColor clearColor];
        _herDrumLabel.textAlignment = NSTextAlignmentLeft;
    }
    return _herDrumLabel;
}

@end
