filament/support
v3.2.98
v11.20.0
v3.5.4
PHP 8.3.10
i have a Livewire component and it use filament dropdown, when i change the team, the loading indicator not showing, the chevron icon has disappear until the status updated and notification show
i want the loading indicator can be showing on dropdown list item
<div>
<x-filament::dropdown
maxHeight="250px"
placement="left-start"
teleport="true"
>
<x-slot name="trigger">
<x-filament::dropdown.header
class="font-semibold"
color="gray"
icon="heroicon-c-user-group"
>
{{ auth()->user()->currentTeam->name ?? 'Select Team' }}
</x-filament::dropdown.header>
</x-slot>
<x-filament::dropdown.header
class="font-medium"
color="gray"
>
{{ __('Select Team') }}
</x-filament::dropdown.header>
<x-filament::dropdown.list>
@foreach(auth()->user()->allTeams() as $team)
<x-filament::dropdown.list.item
:color="auth()->user()->isCurrentTeam($team) ? 'primary' : null"
icon="heroicon-m-chevron-right"
tag="button"
:disabled="auth()->user()->isCurrentTeam($team) ?? false"
wire:click="changeTeam({{ $team }})"
>
{{ $team->name }}
</x-filament::dropdown.list.item>
@endforeach
</x-filament::dropdown.list>
</x-filament::dropdown>
</div>
<?php
namespace App\Livewire;
use App\Models\Team;
use Filament\Notifications\Notification;
use Illuminate\Contracts\View\View;
use Livewire\Component;
class SwitchTeam extends Component
{
public function render(): View
{
return view('livewire.switch-team');
}
public function changeTeam(Team $team): void
{
auth()->user()->switchTeam($team);
Notification::make()->title('Switched to '.$team->name)->success()->send();
}
}
https://github.com/holiq/FilaTeam
No response
Pay now to fund the work behind this issue.
Get updates on progress being made.
Maintainer is rewarded once the issue is completed.
You're funding impactful open source efforts
You want to contribute to this effort
You want to get funding like this too