update
This commit is contained in:
@@ -1,19 +1,19 @@
|
||||
@php
|
||||
$tag = 'button';
|
||||
$href = null;
|
||||
$tag = 'button';
|
||||
$href = null;
|
||||
|
||||
if ($route) {
|
||||
$href = route($route, $params);
|
||||
$tag = 'a';
|
||||
} elseif ($url) {
|
||||
$href = $url;
|
||||
$tag = 'a';
|
||||
} elseif ($attributes->has('href')) {
|
||||
$href = $attributes->get('href');
|
||||
$tag = 'a';
|
||||
}
|
||||
if ($route) {
|
||||
$href = route($route, $params);
|
||||
$tag = 'a';
|
||||
} elseif ($url) {
|
||||
$href = $url;
|
||||
$tag = 'a';
|
||||
} elseif ($attributes->has('href')) {
|
||||
$href = $attributes->get('href');
|
||||
$tag = 'a';
|
||||
}
|
||||
|
||||
$baseClasses = 'd-inline-flex gap-2 align-items-center justify-content-center text-white border-0 shadow-md px-2 py-1 rounded-2';
|
||||
$baseClasses = 'd-inline-flex gap-2 align-items-center justify-content-center text-white border-0 shadow-lg px-3 py-2 rounded-pill';
|
||||
|
||||
$variants = [
|
||||
'primary' => 'bg-primary',
|
||||
@@ -37,7 +37,7 @@
|
||||
$variantClass = $variants[$variant] ?? $variants['primary'];
|
||||
$sizeClass = $sizes[$size] ?? $sizes['default'];
|
||||
|
||||
$classes = "{$baseClasses} {$variantClass} {$sizeClass}";
|
||||
$classes = "{$baseClasses} {$variantClass} {$sizeClass}";
|
||||
@endphp
|
||||
|
||||
@if($tag === 'a')
|
||||
|
||||
Reference in New Issue
Block a user