mbr/elm-chadcn/1.0.0

ChadCn.InputGroup

Provides an input group.

The implementation follows the shadcn Base UI structure and Nova defaults.

= InlineStart
| InlineEnd
| BlockStart
| BlockEnd

Describes the visual position of an input addon.

type Config msg

Describes an input group and its addons.

new : Config msg -> Config msg

Creates an input group around an input.

withAddon : Alignment -> Html msg -> Config msg -> Config msg

Adds arbitrary content beside the input.

withAttributes : List (Attribute msg) -> Config msg -> Config msg

Adds native attributes to the input group.

withButton : Alignment -> Config msg -> Config msg -> Config msg

Adds a button beside the input.

view : Config msg -> Html msg

Renders a configured input group.