{{-- Admin Button Component Kullanım: Kaydet İptal Ürünler --}} @props([ 'tag' => 'button', 'variant' => 'primary', {{-- primary | secondary | danger | ghost --}} 'size' => 'md', {{-- sm | md | lg --}} 'type' => 'button', 'href' => null, 'id' => null, 'disabled' => false, 'class' => '', ]) @php $tag = $href ? 'a' : $tag; $sizeClass = match($size) { 'sm' => 'btn-sm', 'lg' => 'btn-lg', default => '', }; $classes = trim("btn btn-{$variant} {$sizeClass} {$class}"); @endphp <{{ $tag }} {{ $id ? "id=$id" : '' }} class="{{ $classes }}" @if($tag === 'button') type="{{ $type }}" @endif @if($href) href="{{ $href }}" @endif @if($disabled) disabled aria-disabled="true" @endif {{ $attributes }} > {{ $slot }}