LineOne's range slider: a rounded track with a round thumb in the theme color, in three sizes.
<.range name="volume" value={50} color="primary" />
<.range field={@form[:level]} label="Level" min={0} max={10} size="lg" />
<.range name="opacity" phx-debounce="100" />It is a native <input type="range">, so it submits with its form and fires phx-change
as it is dragged.
Summary
Functions
Renders a range slider.
Functions
Renders a range slider.
Attributes
field(Phoenix.HTML.FormField) - Defaults tonil.id(:string) - Defaults to the field's id.name(:string) - Defaults to the field's name.value(:any)min(:any) - Defaults tonil.max(:any) - Defaults tonil.step(:any) - Defaults tonil.color(:string) - Defaults to"neutral". Must be one of"neutral","primary","secondary","info","success","warning", or"error".size(:string) - Defaults to"md". Must be one of"sm","md", or"lg".label(:string) - The caption. Defaults tonil.label_class(:any) - Classes of the caption text. Defaults tonil.help(:string) - The small line under the control. Defaults tonil.errors(:list) - Messages to show;fieldadds its own once the input was used. Defaults to[].disabled(:boolean) - Defaults tofalse.wrapper_class(:any) - Classes of the outer block (grid placement, spacing). Defaults tonil.class(:any) - Defaults tonil.- Global attributes are accepted. Supports all globals plus:
["form", "list"].