kikytokamuro/elm-linerbar/1.0.1

LinerBarStyles

This module provides styling attributes for a linear bar chart component.

Styles

cardBodyStyles : List ( String, String )

Styles for the card body.

cardStyles : Bool -> List ( String, String )

Base styles for the card container that holds the entire chart.

  • dark: A boolean indicating whether to apply dark theme styles.
cardTitleStyles : Bool -> List ( String, String )

Styles for the title of the chart.

  • dark: A boolean indicating whether to apply dark theme styles.
legendItemButtonStyles : List ( String, String )

Styles for the legend item button (the button that contains the dot and the name).

legendItemDotStyles : String -> List ( String, String )

Styles for the colored dot in the legend.

  • color: The color of the dot, matching the bar it represents.
legendItemNameStyles : Bool -> List ( String, String )

Styles for the name of the item in the legend.

  • dark: A boolean indicating whether to apply dark theme styles.
legendItemStyles : List ( String, String )

Styles for individual legend items.

legendStyles : List ( String, String )

Styles for the legend container.

progressItemStyles : Bool -> Bool -> Bool -> Bool -> String -> Float -> List ( String, String )

Styles for individual progress bar items.

  • isActivated: Indicates if the bar is currently activated (e.g., by clicking the legend).
  • isHovered: Indicates if the mouse is currently hovering over the bar.
  • isFirstItem: Indicates if this is the first bar item in the chart.
  • isLastItem: Indicates if this is the last bar item in the chart.
  • color: The background color of the bar.
  • progressWidth: The width of the bar, expressed as a percentage (e.g., "50%").
progressStyles : List ( String, String )

Styles for the progress bar container.

Helper Functions

styleList : List ( String, String ) -> List (Attribute msg)

Helper function to convert a list of style pairs into a list of Html.Attribute for use with Html elements.