Only include date in date header (no time)

// FREEBIE
pull/1/head
Michael Kirk 7 years ago
parent 68ffd81390
commit 0b2facd369

@ -273,25 +273,11 @@ NS_ASSUME_NONNULL_BEGIN
if (self.viewItem.shouldShowDate) { if (self.viewItem.shouldShowDate) {
NSDate *date = self.viewItem.interaction.dateForSorting; NSDate *date = self.viewItem.interaction.dateForSorting;
NSString *dateString = [dateHeaderDateFormatter stringFromDate:date]; NSString *dateString = [dateHeaderDateFormatter stringFromDate:date];
NSString *timeString = [dateHeaderTimeFormatter stringFromDate:date];
self.dateHeaderLabel.font = self.dateHeaderFont;
NSAttributedString *attributedText = [NSAttributedString new]; self.dateHeaderLabel.textColor = UIColor.lightGrayColor;
attributedText = [attributedText rtlSafeAppend:dateString.localizedUppercaseString
attributes:@{ self.dateHeaderLabel.text = dateString;
NSFontAttributeName : self.dateHeaderFont,
NSForegroundColorAttributeName : [UIColor lightGrayColor],
}];
attributedText = [attributedText rtlSafeAppend:@" "
attributes:@{
NSFontAttributeName : self.dateHeaderFont,
}];
attributedText = [attributedText rtlSafeAppend:timeString
attributes:@{
NSFontAttributeName : self.dateHeaderFont,
NSForegroundColorAttributeName : [UIColor lightGrayColor],
}];
self.dateHeaderLabel.attributedText = attributedText;
[self.contentView addSubview:self.dateHeaderView]; [self.contentView addSubview:self.dateHeaderView];
[self.viewConstraints addObjectsFromArray:@[ [self.viewConstraints addObjectsFromArray:@[

Loading…
Cancel
Save