module Donate.Types exposing (..)


type alias Donate =
    { donateImage : String
    , donateLink : String
    , donateName : String
    , donateFees : String
    , donatePreference : Int
    , donatePros : List Pros
    , donateCons : List Cons
    , donateFeatures : List Features
    }


type alias Features =
    { free : Maybe Bool
    , subscriptions : Maybe Bool
    , openSource : Maybe Bool
    , fastPayments : Maybe Bool
    , userFriendly : Maybe Bool
    , anonymous : Maybe Bool
    , rewardTiers : Maybe Bool
    }


type alias Pros =
    { pro : String
    }


type alias Cons =
    { con : String
    }


formatName : String -> String
formatName name =
    name
        |> String.toLower
        |> String.replace " " ""
        |> String.replace "-" ""
