V Vaylan UI
Actions

Link button

Use button styling with ordinary or LiveView navigation.

Preview

Example

<.link_button navigate={~p"/projects"}>View projects</.link_button>

API contract

link_button/1 uses declared Phoenix attributes and slots. This table is generated from the compiled component metadata.

AttributeTypeRequiredDefaultAccepted values
href :string No nil Any value matching the declared type
navigate :string No nil Any value matching the declared type
patch :string No nil Any value matching the declared type
color :atom No nil [nil, :neutral, :primary, :secondary, :accent, :info, :success, :warning, :error]
variant :atom No nil [nil, :outline, :dash, :soft, :ghost, :link]
size :atom No nil [:xs, :sm, :md, :lg, :xl, nil]
shape :atom No nil [nil, :wide, :block, :square, :circle]
disabled :boolean No false Any value matching the declared type
class :any No nil Any value matching the declared type
rest :global No global includes ["download", "hreflang", "referrerpolicy", "rel", "target", "type"]
SlotRequiredSlot attributes
inner_block Yes No slot attributes

States and behavior

Current, disabled, loading, or active state is exposed where the component supports it.

Keyboard and accessibility