//
//  DefaultTheme.swift
//  1Weather
//
//  Created by Dmitry Stepanets on 28.11.2020.
//

import UIKit

struct DefaultTheme: ThemeProtocol {
    //Base
    var name: String {
        return "Default"
    }
    
    var baseBackgroundColor: UIColor {
        return UIColor(named: "background_color") ?? .red
    }
    
    var containerBackgroundColor: UIColor {
        return UIColor(named: "container_background_color") ?? .red
    }
    
    //Navigation bar
    var navigationBarBackgroundColor: UIColor {
        return baseBackgroundColor
    }
    
    var navigationTintColor: UIColor {
        return primaryTextColor
    }
    
    //Tab bar
    var tabBarBackgroundColor: UIColor {
        return UIColor(named: "tab_background") ?? .red
    }
    
    var tabBarTintColor: UIColor {
        return UIColor(named: "tab_tint_color") ?? .red
    }
    
    var tabBarNormalColor: UIColor {
        return UIColor(named: "tab_normal_color") ?? .red
    }
    
    //Text
    var primaryTextColor: UIColor {
        return UIColor(named: "primary_text_color") ?? .red
    }
    
    var secondaryTextColor: UIColor {
        return UIColor(named: "secondary_text_color") ?? .red
    }
    
    //Progress
    var progressBackgroundColor: UIColor {
        return UIColor(named: "progress_color") ?? .red
    }
    
    var progressIndicatorColor: UIColor {
        return UIColor(named: "progress_indicator_color") ?? .red
    }
    
    //Period button
    var periodButtonBackgroundColor: UIColor {
        return UIColor(named: "period_button_background") ?? .red
    }
    
    var periodButtonSelectedBackgroundColor: UIColor {
        return UIColor(named: "period_button_selected_background") ?? .red
    }
    
    var periodButtonBorderColor: UIColor {
        return UIColor(named: "period_button_border_color") ?? .red
    }
    
    var periodButtonShadowColor: UIColor {
        return UIColor(named: "period_button_shadow_color") ?? .red
    }
    
    
    //Segmented control
    var segmentTextColor: UIColor {
        return UIColor(named: "segment_text_color") ?? .red
    }
    
    var segmentSelectedTextColor: UIColor {
        return UIColor(named: "segment_selected_text_color") ?? .red
    }
    
    var segmentSelectedGradient: [UIColor] {
        let start = UIColor(named: "segment_selected_start_color") ?? .red
        let end = UIColor(named: "segment_selected_end_color") ?? .red
        return [start, end]
    }
    
    var segmentBorderColor: UIColor {
        return UIColor(named: "segment_border_color") ?? .red
    }
    
    var segmentBackgroundColor: UIColor {
        return UIColor(named: "segment_bg_color") ?? .red
    }
    
    //Graph
    var graphColor: UIColor {
        return UIColor(named: "graph_color") ?? .red
    }
    
    var graphTintColor: UIColor {
        return UIColor(named: "graph_tint_color") ?? .red
    }
}
