Skip to content

Button

A clickable button that can navigate to a URL or trigger an action. Renders as a styled <button> or <a> element.

Properties

PropertyTypeDefaultDescription
labeltext'Click me'The button text. Supports expressions.
hreftext'#'The URL to navigate to when clicked. Leave as # if using an onClick action instead.

Events

  • onClick -- Fires when the button is clicked. Attach an inline or reusable action to handle the click.

Example

A simple link button:

Label: View Details
Href: /products/`{ {row.slug}}`

A button that triggers an action (set href to # and attach an onClick action):

Label: Delete Item
Href: #
onClick: [action] delete_item

Tips

  • When using onClick with an action, set href to # to prevent navigation.
  • Use expressions in the label for dynamic text: { {if(row.is_favorite, 'Unfavorite', 'Favorite')}}.
  • Style buttons using the Design tab -- background color, padding, border-radius, and hover states.
  • For form submission, use the Submit Button widget instead -- it is specifically designed to work with the Form Container.