primait/pyxis-components/9.0.3

Prima.Pyxis.Tooltip

Configuration

type Config msg

Represent the opaque Tooltip configuration.

Configuration Methods

top : List (Html msg) -> Config msg

Create a tooltip top.

bottom : List (Html msg) -> Config msg

Create a tooltip bottom.

left : List (Html msg) -> Config msg

Create a tooltip left.

brand : List (Html msg) -> Config msg

Create a tooltip brand.

error : List (Html msg) -> Config msg

Create a tooltip error.

warning : List (Html msg) -> Config msg

Create a tooltip warning.

Rendering

render : Config msg -> Html msg

Renders the Tooltip.

import Html
import Prima.Pyxis.Tooltip as Tooltip


...


type Msg =
    NoOp


type alias Model =
    {}


...


view : Html Msg
view =
        Tooltip.brand [ text "Lorem ipsum dolor sit amet" ]
          |> Tooltip.render

Options

withClass : String -> Config msg -> Config msg

Adds a class to the Tooltip.

withId : String -> Config msg -> Config msg

Adds an id Html.Attribute to the Tooltip.

Sets a type position Bottom to the Tooltip.

Sets a type position Left to the Tooltip.

Sets a type position Right to the Tooltip.

Sets a type position Top to the Tooltip.