public function __invoke(\Eva\Grid\Grid $grid) { $tableHead = $this->renderTableHead($grid); $tableBody = $this->renderTableBody($grid); $grid->appendAttribute('class', 'table table-hover'); if ($grid->getSortable()) { $grid->appendAttribute('class', 'table-sortable'); } return '<table' . $this->renderer->createAttributesString($grid->getAttributes()) . '>' . $tableHead . $tableBody . '</table>'; }