View Source PetalComponents.Input (petal_components v2.2.0)
Renders pure inputs (no label or errors).
Summary
Functions
Attributes
id(:any) - Defaults tonil.name(:any)label(:string)value(:any)type(:string) - Defaults to"text".field(Phoenix.HTML.FormField) - a form field struct retrieved from the form, for example: @form[:email].checked(:boolean) - the checked flag for checkbox inputs.prompt(:string) - the prompt for select inputs. Defaults tonil.options(:list) - the options to pass to Phoenix.HTML.Form.options_for_select/2.multiple(:boolean) - the multiple flag for select inputs. Defaults tofalse.class(:any) - the class to add to the input. Defaults tonil.- Global attributes are accepted. Supports all globals plus:
["autocomplete", "autocorrect", "autocapitalize", "disabled", "form", "max", "maxlength", "min", "minlength", "list", "pattern", "placeholder", "readonly", "required", "size", "step", "value", "name", "multiple", "prompt", "selected", "default", "year", "month", "day", "hour", "minute", "second", "builder", "options", "layout", "cols", "rows", "wrap", "checked", "accept"].
Functions
Attributes
id(:any) - Defaults tonil.name(:any)label(:string)value(:any)type(:string) - Defaults to"text".field(Phoenix.HTML.FormField) - a form field struct retrieved from the form, for example: @form[:email].checked(:boolean) - the checked flag for checkbox inputs.prompt(:string) - the prompt for select inputs. Defaults tonil.options(:list) - the options to pass to Phoenix.HTML.Form.options_for_select/2.multiple(:boolean) - the multiple flag for select inputs. Defaults tofalse.class(:any) - the class to add to the input. Defaults tonil.- Global attributes are accepted. Supports all globals plus:
["autocomplete", "autocorrect", "autocapitalize", "disabled", "form", "max", "maxlength", "min", "minlength", "list", "pattern", "placeholder", "readonly", "required", "size", "step", "value", "name", "multiple", "prompt", "selected", "default", "year", "month", "day", "hour", "minute", "second", "builder", "options", "layout", "cols", "rows", "wrap", "checked", "accept"].