Skip to content

Commit

Permalink
Merge pull request #104 from sandersjj/fix-extra-item-actions
Browse files Browse the repository at this point in the history
Fix extra item actions
  • Loading branch information
awcodes authored Feb 22, 2024
2 parents cf67977 + 340ef29 commit 1b185a5
Showing 1 changed file with 6 additions and 7 deletions.
13 changes: 6 additions & 7 deletions resources/views/components/table-repeater.blade.php
Original file line number Diff line number Diff line change
Expand Up @@ -26,13 +26,6 @@
$statePath = $getStatePath();
foreach ($containers as $uuid => $row) {
$visibleExtraItemActions = array_filter(
$extraItemActions,
fn (Action $action): bool => $action(['item' => $uuid])->isVisible(),
);
}
foreach ($extraActions as $extraAction) {
$visibleExtraActions = array_filter(
$extraActions,
Expand Down Expand Up @@ -107,6 +100,12 @@ class="table-repeater-rows-wrapper divide-y divide-gray-950/5 dark:divide-white/
>
@if (count($containers))
@foreach ($containers as $uuid => $row)
@php
$visibleExtraItemActions = array_filter(
$extraItemActions,
fn (Action $action): bool => $action(['item' => $uuid])->isVisible(),
);
@endphp
<tr
wire:key="{{ $this->getId() }}.{{ $row->getStatePath() }}.{{ $field::class }}.item"
x-sortable-item="{{ $uuid }}"
Expand Down

0 comments on commit 1b185a5

Please sign in to comment.