| Total Complexity | 4 |
| Total Lines | 20 |
| Duplicated Lines | 0 % |
| Changes | 1 | ||
| Bugs | 0 | Features | 1 |
| 1 | <?php declare(strict_types=1); |
||
| 10 | class Table extends Element |
||
| 11 | { |
||
| 12 | public function render(array $parameters, HTMLNode $previous): HTMLNode |
||
| 13 | { |
||
| 14 | $previous->addAttribute('class', 'table'); |
||
| 15 | |||
| 16 | if ($parameters[HTMLTable::STRIPED] ?? false) { |
||
| 17 | $previous->addAttribute('class', 'table-striped'); |
||
| 18 | } |
||
| 19 | if ($parameters[HTMLTable::BORDERED] ?? false) { |
||
| 20 | $previous->addAttribute('class', 'table-bordered'); |
||
| 21 | } |
||
| 22 | |||
| 23 | return $previous; |
||
| 24 | } |
||
| 25 | |||
| 26 | public static function getMetadata(): Metadata |
||
| 30 | } |
||
| 31 | } |
||
| 32 |