feat: standardized formatting conventions across pages

This commit is contained in:
Nick 2024-11-27 22:36:35 -06:00
parent d5e7cfe814
commit ead41f0ed0
19 changed files with 503 additions and 446 deletions

View file

@ -0,0 +1,38 @@
module Config.StrengthBar exposing (..)
import Config.Colour exposing (..)
import Config.Format exposing (..)
import Cuckery.Types exposing (..)
import Effect exposing (Effect)
import Element as E exposing (..)
import Element.Background as B exposing (..)
import Element.Border as D
import Element.Font as F
import Html.Attributes as H exposing (style)
import Layouts
import Page exposing (Page)
import Route exposing (Route)
import Shared
import View exposing (View)
barMaker : (Int -> String) -> Int -> Element msg
barMaker getTooltip num =
el
([ E.height <| px 12
, E.width fill
, D.rounded 10
, D.color colourTheme.nonHighlightedDarkText
, D.width 2
, B.gradient
{ angle = 90
, steps =
List.concat
[ List.repeat num colourTheme.barGreen
, List.repeat (10 - num) colourTheme.barRed
]
}
]
++ [ tooltip below (myTooltip (getTooltip num)) ]
)
none