Backend\VueComponents\DropdownMenu\ItemDefinition

Overview

ItemDefinition encapsulates Dropdown menu item information.


Protected Properties

protected bool $disabled

protected string $type

protected string $label

protected string $linkHref

protected string $linkTarget

protected string $icon

protected string $command

protected array $items

protected bool $checked

protected array|null $userData

protected string|null $key

protected string|null $group


Public Methods

public __construct()

public __construct($type, $label = null, $command = null): void

public addItem()

public addItem($type, $label = null, $command = null): void

public addItemObject()

public addItemObject($item): void

public hasItems()

public hasItems(): void

public setChecked()

public setChecked($value): void

public setDisabled()

public setDisabled($value): void

public setGroup()

public setGroup($group): void

public setIcon()

public setIcon($value): void

public setKey()

public setKey($value): void

Sets optional item key attribute

public setLinkHref()

public setLinkHref($value): void

public setLinkTarget()

public setLinkTarget($value): void

public setUserData()

public setUserData($userData): void

Sets optional user data object.

public toArray()

public toArray(): void