class ToolbarButton extends AbstractExtension

Twig extension to provide the xhtml code for requested button using: `toolbar_button(path('ROUTE', { 'VARIABLE': object.PROPERTY }), 'BUTTON_NAME', 'SIZE[lg|md|sm|xs](default md)', 'USE_ANOTHER_LABEL', 'USE_ANOTHER_STYLE')

Properties

private ToolbarServiceInterface $toolbarService Stores the toolbarService

Methods

__construct(ToolbarServiceInterface $toolbarService)

No description

getFunctions()

No description

string
button(Environment $environment, $link, $button, $size = null, $label = null, $userStyle = null, $color = null)

Returns the xhtml code for the button

Details

at line 30
__construct(ToolbarServiceInterface $toolbarService)

Parameters

ToolbarServiceInterface $toolbarService

at line 35
getFunctions()

at line 53
string button(Environment $environment, $link, $button, $size = null, $label = null, $userStyle = null, $color = null)

Returns the xhtml code for the button

Parameters

Environment $environment
$link
$button
$size
$label
$userStyle
$color

Return Value

string