     
     fileprivate var textColor: UIColor? {
         
-        switch self.dayType {
+        switch self.dateType {
             
             case .past:
                 return self.configuration.appearance.pastDatesEnabled ? self.configuration.appearance.pastDateEnabledTextColor : self.configuration.appearance.pastDateDisabledTextColor

                
                if self.configuration.calendar.isDateInToday(self.date!) {
                    
                    self.dayType = .current
                }
                else if (Date() as NSDate).earlierDate(self.date!) == self.date! {
                    
                    self.dayType = .past
                }
                else {
                    
                    self.dayType = .future
                }
                
                self.configuration.calendar.isDate(self.date!, inSameDayAs: self.configuration.selectedDate()) ? self.highlight() : self.unhighlight()

    
    fileprivate var selectedBackgroundColor: UIColor? {
        
        switch self.dateType {
            
            case .past:
                return self.configuration.appearance.pastDateSelectedBackgroundColor
