{% include '@bolt-components-menu/menu.twig' with {
items: [
{
content: 'Menu Item 1',
},
{
content: 'Menu Item 2',
attributes: {
target: '_blank',
},
},
]
} only %}
kebab-case
.
Prop Name | Description | Type | Default Value | Option(s) |
---|---|---|---|---|
attributes
|
A Drupal attributes object. Applies extra HTML attributes to the outer <bolt-menu> tag. |
object
| — |
|
items
|
Generates an array of items, each item is a <bolt-trigger>. While the content prop for each item can accept anything custom content, plain text is the recommended format. |
array
| — |
|
content
|
Custom content for menu items. |
string
, array
, object
|
— |
|
title
|
Controls the inset spacing of each menu item. |
string
| — |
|
spacing
|
Controls the inset spacing of each menu item. |
string
|
small
|
|
npm install @bolt/components-menu