@aware([ 'indicator' ]) @props([ 'filterable' => null, 'indicator' => null, 'loading' => null, 'value' => null, ]) @php $classes = Flux::classes() ->add('group/option overflow-hidden data-hidden:hidden group flex items-center px-2 py-1.5 w-full focus:outline-hidden') ->add('rounded-md') ->add('text-left text-sm font-medium') ->add('text-zinc-800 data-active:bg-zinc-100 [&[disabled]]:text-zinc-400 dark:text-white dark:data-active:bg-zinc-600 dark:[&[disabled]]:text-zinc-400') ->add('scroll-my-[.3125rem]') // This is here so that when a user scrolls to the top or bottom of the list, the padding is included... ; $livewireAction = $attributes->whereStartsWith('wire:click')->isNotEmpty(); $alpineAction = $attributes->whereStartsWith('x-on:click')->isNotEmpty(); $loading ??= $loading ?? $livewireAction; if ($loading) { $attributes = $attributes->merge(['wire:loading.attr' => 'data-flux-loading']); } @endphp class($classes) }} data-flux-option >
{{ $slot }}