Actions

 

Buttons vs. Actions: what's the difference?Actions and Buttons are functionally the same. They both run code when a user clicks them. We suggest you use buttons over actions when you design your configurator. They offer more styling options and are easier to move around as your UI design changes in the future. Actions can only appear in the action bar, which is found only in some configurator layouts. Buttons, however, can appear just about anywhere in any UI.

 

On a mobile screen, actions are collapsed under a hamburger menu.


Add an Action

To add an action to the configurator, select the 'Actions' node in the tree, and click on the '+' button.  Once you have added an action, snap rules can be added to the action by selecting the action in the tree and clicking the '+' button.

Migrating from an Action to a Button

To migrate code from an action to a button, you can copy and paste the json of the Snap code from the action's workspace to the button's workspace.

Action Properties

Property Description
Name The name of the action. This is also the text that will show in the button in the running configurator.
Icon An icon that will show up in the action button in the running configurator.
Visible

Specifies whether the action button is visible in the running configurator.

Was this article helpful?