Submit

Renders a submit button (type="submit"), ie, the HTML default.

Read more Read less

Use this when you want your button to submit a form.

The default style is primary.

Examples

<.form for={@form} phx-submit="save">
  <.submit>
    Go!
  </.submit>
</.form>
Attribute Type Documentation Default Value
primary :boolean

Renders a primary button

false
secondary :boolean

Renders a secondary button

false
compact :boolean

Makes a button compact. Only works with ghost.

false
ghost :boolean

Renders a ghost button

false
link :boolean

Renders a submit button visually styled as an inline anchor (<.a>).

false
danger :boolean

Renders a danger button

false
icon :string
icon_weight :string "extrabold"
rest :global
size :string "base"
type :string

The HTML type attribute. Do not use.

Required inner_block * :slot
[Multiple values]