diff options
Diffstat (limited to 'src/Toolbar/Item.php')
-rw-r--r-- | src/Toolbar/Item.php | 32 |
1 files changed, 32 insertions, 0 deletions
diff --git a/src/Toolbar/Item.php b/src/Toolbar/Item.php new file mode 100644 index 0000000..168f877 --- /dev/null +++ b/src/Toolbar/Item.php @@ -0,0 +1,32 @@ +<?php + +namespace Lightscale\LaralightTables\Toolbar; + +use Lightscale\LaralightTables\TableComponent; +use Lightscale\LaralightTables\Toolbar; + +use Illuminate\View\View; +use Illuminate\Support\HtmlString; + +abstract class Item +{ + private Toolbar $toolbar; + + public function setToolbar(Toolbar $toolbar): void + { + $this->toolbar = $toolbar; + } + + public function getToolbar(): Toolbar + { + return $this->toolbar; + } + + public function getTable(): TableComponent + { + return $this->getToolbar()->getTable(); + } + + abstract public function render(): View|HtmlString|string|null; + +} |