Overview
Trigger is an unstyled component used to convey a call to action. Part of the Bolt “Components” CSS framework that powers the Bolt Design System.
Install via NPM
npm install @bolt/components-trigger
Description
Triggers add button or link behavior to any content without the default button or link styles.
Usage
{% include "@bolt-components-trigger/trigger.twig" with {
content: "This is a trigger"
} only %}
Schema
Note: when assigning component props as HTML attributes on a web component, make sure to use kebab-case
.
Prop Name | Description | Type | Default Value | Option(s) |
---|---|---|---|---|
|
A Drupal-style attributes object with extra attributes to append to this component. |
object
| — |
|
|
Main content of the trigger (Twig only). |
string , array , object |
— |
|
|
Contains a URL that the link points to. This may also be passed as part of |
string
| — |
|
|
Specifies where to display the linked URL. This may also be passed as part of |
string
| — |
|
|
Determines the button tag type for semantic buttons |
string
|
button
|
|
|
Type of cursor shown on hover. |
string
|
pointer
|
|
|
The name of a method on the |
string
| — |
|
|
|
string
| — |
|
|
Set the display property |
string
|
inline
|
|
|
Turn off the default outline on focus |
boolean
|
false
|
|
|
Make trigger unusable and un-clickable. Only applies to |
boolean
|
false
|
|