Appearance : add `headerSeparatorColor` property
This commit is contained in:
parent
714bc0e193
commit
adba0b9a8d
|
|
@ -108,6 +108,11 @@ typedef NS_OPTIONS(NSUInteger, FSCalendarCaseOptions) {
|
|||
*/
|
||||
@property (strong, nonatomic) UIColor *headerTitleColor;
|
||||
|
||||
/**
|
||||
* The color oh month header separator
|
||||
*/
|
||||
@property (strong, nonatomic) UIColor *headerSeparatorColor;
|
||||
|
||||
/**
|
||||
* The date format of the month header.
|
||||
*/
|
||||
|
|
|
|||
|
|
@ -36,6 +36,7 @@
|
|||
_headerTitleFont = [UIFont systemFontOfSize:FSCalendarStandardHeaderTextSize];
|
||||
|
||||
_headerTitleColor = FSCalendarStandardTitleTextColor;
|
||||
_headerSeparatorColor = FSCalendarStandardLineColor;
|
||||
_headerDateFormat = @"MMMM yyyy";
|
||||
_headerMinimumDissolvedAlpha = 0.2;
|
||||
_weekdayTextColor = FSCalendarStandardTitleTextColor;
|
||||
|
|
@ -409,6 +410,14 @@
|
|||
}
|
||||
}
|
||||
|
||||
- (void)setHeaderSeparatorColor:(UIColor *)headerSeparatorColor
|
||||
{
|
||||
if (![_headerSeparatorColor isEqual:headerSeparatorColor]) {
|
||||
_headerSeparatorColor = headerSeparatorColor;
|
||||
[self.calendar configureAppearance];
|
||||
}
|
||||
}
|
||||
|
||||
- (void)setHeaderMinimumDissolvedAlpha:(CGFloat)headerMinimumDissolvedAlpha
|
||||
{
|
||||
if (_headerMinimumDissolvedAlpha != headerMinimumDissolvedAlpha) {
|
||||
|
|
|
|||
|
|
@ -95,6 +95,7 @@
|
|||
_titleLabel.font = self.calendar.appearance.headerTitleFont;
|
||||
_titleLabel.textColor = self.calendar.appearance.headerTitleColor;
|
||||
_titleLabel.textAlignment = self.calendar.appearance.headerTitleAlignment;
|
||||
_bottomBorder.backgroundColor = self.calendar.appearance.headerSeparatorColor;
|
||||
[self.weekdayView configureAppearance];
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue