ShareButtons
class ShareButtons extends AbstractExtension
Twig extension to provide the xhtml code for requested button using: sharebuttons(['SHARE1', 'SHARE2', 'SHARE3', etc.], 'STYLE[distinct|ellipse|toolbar](default distinct)', 'SIZE[lg|md|sm|xs](default md)', 'ALIGNMENT[left|center|right](default center)', DISPLAY_ICON[true|false](default true), DISPLAY_TEXTX[true|false](default false))
Properties
private ShareButtonsServiceInterface | $sharebuttonsService | Stores the shareButtonsServiceInterface |
Methods
getFunctions()
No description
string
sharebuttons(Environment $environment, $shares, $style = 'distinct', $size = 'md', $alignment = 'center', $displayIcon = true, $displayText = false, $url = null)
Returns the xhtml code for the button
Details
at line 31
__construct(ShareButtonsServiceInterface $sharebuttonsService)
at line 36
getFunctions()
at line 54
string
sharebuttons(Environment $environment, $shares, $style = 'distinct', $size = 'md', $alignment = 'center', $displayIcon = true, $displayText = false, $url = null)
Returns the xhtml code for the button