diff --git a/src/Html/Builder.php b/src/Html/Builder.php index fa2b434..9e27e92 100644 --- a/src/Html/Builder.php +++ b/src/Html/Builder.php @@ -185,7 +185,7 @@ public function table(array $attributes = [], bool $drawFooter = false, bool $dr ? ''.implode('', $this->compileTableSearchHeaders()).'' : ''; - $tableHtml .= 'theadClass ?? '').'>'; + $tableHtml .= 'getTheadClass() ?? '').'>'; $tableHtml .= ''.implode('', $th).''.$searchHtml.''; if ($drawFooter) { diff --git a/src/Html/HasTable.php b/src/Html/HasTable.php index aa6c4bb..b5a7912 100644 --- a/src/Html/HasTable.php +++ b/src/Html/HasTable.php @@ -100,6 +100,11 @@ public function setTableHeadClass(string $class): static return $this; } + public function getTheadClass(): ?string + { + return $this->theadClass; + } + /** * Remove class names from the "class" attribute of HTML table. *