module Hasmin.Config
( Config(..)
, ColorSettings(..)
, DimensionSettings(..)
, GradientSettings(..)
, FontWeightSettings(..)
, LetterCase(..)
, SortingMethod(..)
, defaultConfig
, RulesMergeSettings(..)
) where
data ColorSettings = ColorMinOff | ColorMinOn
deriving (Show, Eq)
data DimensionSettings = DimMinOff | DimMinOn
deriving (Show, Eq)
data GradientSettings = GradientMinOff | GradientMinOn
deriving (Show, Eq)
data LetterCase = Original
| Lowercase
deriving (Show, Eq)
data SortingMethod = NoSorting | Lexicographical
deriving (Show, Eq)
data FontWeightSettings = FontWeightMinOff | FontWeightMinOn
deriving (Show, Eq)
data RulesMergeSettings = MergeRulesOn | MergeRulesOff
deriving (Show, Eq)
data Config = Config { colorSettings :: ColorSettings
, dimensionSettings :: DimensionSettings
, gradientSettings :: GradientSettings
, shouldUsePropertyTraits :: Bool
, shouldCleanRules :: Bool
, shouldMinifyTimingFunctions :: Bool
, shouldMinifyFilterFunctions :: Bool
, shouldRemoveQuotes :: Bool
, fontweightSettings :: FontWeightSettings
, shouldMinifyTransformOrigin :: Bool
, shouldMinifyMicrosyntax :: Bool
, shouldMinifyKeyframeSelectors :: Bool
, shouldMinifyTransformFunction :: Bool
, shouldConvertEscaped :: Bool
, shouldConvertNullPercentages :: Bool
, shouldRemoveEmptyBlocks :: Bool
, shouldRemoveDuplicateSelectors :: Bool
, shouldNormalizeQuotes :: Bool
, letterCase :: LetterCase
, selectorSorting :: SortingMethod
, declarationSorting :: SortingMethod
, rulesMergeSettings :: RulesMergeSettings
} deriving (Show)
defaultConfig :: Config
defaultConfig = Config { colorSettings = ColorMinOn
, dimensionSettings = DimMinOff
, gradientSettings = GradientMinOn
, shouldUsePropertyTraits = True
, shouldCleanRules = True
, shouldMinifyTimingFunctions = True
, shouldMinifyFilterFunctions = True
, shouldRemoveQuotes = True
, fontweightSettings = FontWeightMinOn
, shouldMinifyTransformOrigin = True
, shouldMinifyMicrosyntax = True
, shouldMinifyKeyframeSelectors = True
, shouldMinifyTransformFunction = True
, shouldConvertEscaped = True
, shouldConvertNullPercentages = True
, shouldRemoveEmptyBlocks = True
, shouldRemoveDuplicateSelectors = True
, shouldNormalizeQuotes = True
, letterCase = Lowercase
, selectorSorting = NoSorting
, declarationSorting = NoSorting
, rulesMergeSettings = MergeRulesOn
}