Menu
The menu element is used to display the navigation. It is hidden by default and is displayed by adding the active
attribute, for example, when a button is clicked. Špeciálne pre použitie v Menu sú navrhnuté elementy MenuItem a MenuLabel.
Basic usage
Inset
Variant: Megamenu
Variant: Nav
Collapse
The collapse
attribute displays the menu in collapsed state. In this state, the menu is collapsed and only the icon is displayed.
Atribúty a Vlastnosti
active
Description | If true , the menu is active and visible. |
Attribute | active |
Type | boolean |
Default | false |
collapse
Description | If true , the menu will be displayed in the collapsed state. |
Attribute | collapse |
Type | boolean |
Default | false |
Option
Description | Specifies a menu variant. Possible values are 'context', 'megamenu' and 'nav'. |
Attribute | Option |
Type | string |
Default | undefined |
Eventy
No events available for this component.
Metódy
No public methods available for this component.
CSS Shadow Parts
Name | Description |
---|---|
native | Refers to a div element inside an element. |
CSS Custom Vlastnosti
Name | Description |
---|---|
--wje-menu-background | Defines the background color of the menu. |
--wje-menu-border-width | Specifies the width of the menu border. |
--wje-menu-border-style | Specifies the menu border style. |
--wje-menu-border-color | Defines the color of the menu border. |
--wje-menu-border-radius | Specifies the rounding of the menu corners. |
--wje-menu-padding-top | Specifies the top inner edge of the menu. |
--wje-menu-padding-bottom | Specifies the lower inner edge of the menu. |
--wje-menu-padding-inline | Adjusts the horizontal inner edges of the menu. |
--wje-menu-margin-top | Defines the top outer edge of the menu. |
--wje-menu-margin-bottom | Defines the lower outer edge of the menu. |
--wje-menu-margin-inline | Specifies the horizontal outer edges of the menu. |
--wje-menu-collapse-width | Adjusts the width of the menu when collapsed. |
--wje-menu-shadow | Defines the menu shadow. |
--wje-menu-from-index | Specifies the z-index value of the layering menu. |
--wje-menu-submenu-offset | Sets the submenu indentation for the context variant. |
Sloty
Name | Description |
---|---|
`` | The default slot for the content of the menu element. |