Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion packages/schemas/src/Components/Concerns/HasActions.php
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@

use Closure;
use Filament\Actions\Action;
use Filament\Actions\ActionGroup;
use Filament\Schemas\Components\Contracts\HasAffixActions;
use Filament\Schemas\Components\Contracts\HasExtraItemActions;
use Illuminate\Database\Eloquent\Model;
Expand Down Expand Up @@ -146,7 +147,7 @@ public function getDefaultActions(): array
return [];
}

public function prepareAction(Action $action): Action
public function prepareAction(Action | ActionGroup $action): Action | ActionGroup
{
return $action->schemaComponent($this);
}
Expand Down
7 changes: 4 additions & 3 deletions packages/schemas/src/Components/Concerns/HasHeaderActions.php
Original file line number Diff line number Diff line change
Expand Up @@ -4,17 +4,18 @@

use Closure;
use Filament\Actions\Action;
use Filament\Actions\ActionGroup;
use Illuminate\Support\Arr;

trait HasHeaderActions
{
/**
* @var array<Action | Closure>
* @var array<Action | ActionGroup | Closure>
*/
protected array $headerActions = [];

/**
* @param array<Action | Closure> $actions
* @param array<Action | ActionGroup | Closure> $actions
*/
public function headerActions(array $actions): static
{
Expand All @@ -27,7 +28,7 @@ public function headerActions(array $actions): static
}

/**
* @return array<Action>
* @return array<Action | ActionGroup>
*/
public function getHeaderActions(): array
{
Expand Down
Loading