/**
* Method to render current dropdown menu
*
* @param string $item An item to render.
*
* @return string HTML markup for the dropdown list
*
* @since 3.2
*/
public static function render($item = '')
{
$html = array();
$html[] = '<button data-bs-toggle="dropdown" class="dropdown-toggle btn btn-sm btn-secondary">';
$html[] = '<span class="caret"></span>';
if ($item) {
$html[] = '<span class="visually-hidden">' . Text::sprintf('JACTIONS', $item) . '</span>';
}
$html[] = '</button>';
$html[] = '<ul class="dropdown-menu">';
$html[] = implode('', static::$dropDownList);
$html[] = '</ul>';
static::$dropDownList = null;
return implode('', $html);
}