Buttons are used to trigger specific actions or functions. For example, you can use a "Submit" button in a form to send user input to a server, or a "Save" button to save changes in an application.
Item | Name | Description | Optional |
---|---|---|---|
1 | Text label | A button's text label acts as a concise but powerful message, informing users of the action triggered by a click or tap. It serves as the button's voice, delivering clarity and guidance in a few well-chosen words. | yes |
2 | Container | The container of a button is its home, providing structure and placement within the user interface. It ensures the button is visually pleasing, strategically positioned, and accessible to users. | no |
3 | Icon | The icon of a button is like a visual cue, conveying meaning and enhancing user understanding. It's a compact symbol that complements the button's text, adding an extra layer of context or functionality. | yes |
Take a look at our button options designed for different user needs and situations. They enhance user experiences for everyday actions and critical decisions. Check out our default, primary, success, warning, and danger button variants in our overview.
This table provides guidance on when to use each button variant (Solid, Outline, Ghost, and Link) for different button types, considering their specific characteristics and purposes in user interface design.
Variants | Solid | Outline | Ghost | Link |
---|---|---|---|---|
Primary | Used to move forward in a primary (the most important) user flow. | For secondary actions related to the primary user flow. | To give suggestive actions related to the primary user flow. | To give information related to the primary user flow. |
Default | Used to move forward in a secondary user flow or when there is no specific user flow. | For secondary actions related to the secondary user flow. | To give suggestive actions related to the secondary user flow. | To give information related to the secondary user flow |
Success | For actions confirming successful operations. | For secondary actions related to the successful operation. | To give suggestive actions related to the successful operation. | To give information related to the successful operation. |
Warning | For actions requiring caution or user confirmation. | For secondary actions related to the warning. | To give suggestions related to the warning. | To give information related to the warning user flow. |
Danger | For actions confirming potentially negative consequences. | For secondary actions related to potentially negative consequences. | To give suggestions related to potentially negative consequences. | To give information related to potentially negative consequences. |
Here's an example that explains which button to use in different scenarios:
With these options you can tweak the appearance of the button in Figma. They are available in the Design Panel so you can compose the button to exactly fit the user experience need for the uses case you are working on.
Item | Options | Description |
---|---|---|
Type | solid outline ghost link | There are four button types to choose from so you can differentiate between buttons, depending on how essential they are. More info about button types |
Variant | default primary success warning danger info | Indicates the variant of the button. More info about button variants |
Size | small medium large | The button is available in three sizes. If not specified the default value is medium . |
Icon | start end | Indictes the position of the icon. |
Label | text | Value of the button. |
Icon only | boolean | Indicates if it is an icon only button. |
Users can activate a button by clicking anywhere within the button container.
When the button label is concealed, a tooltip appears on hover, revealing the label text and, when applicable, a keyboard shortcut.
Hover and Active State Transitions: When users hover over a button or the button is in an active state, the background color and/or border color smoothly transition to provide visual feedback.