42 lines
1.1 KiB
PHP
42 lines
1.1 KiB
PHP
{{-- Credit: Lucide (https://lucide.dev) --}}
|
|
|
|
@props([
|
|
'variant' => 'outline',
|
|
])
|
|
|
|
@php
|
|
if ($variant === 'solid') {
|
|
throw new \Exception('The "solid" variant is not supported in Lucide.');
|
|
}
|
|
|
|
$classes = Flux::classes('shrink-0')
|
|
->add(match($variant) {
|
|
'outline' => '[:where(&)]:size-6',
|
|
'solid' => '[:where(&)]:size-6',
|
|
'mini' => '[:where(&)]:size-5',
|
|
'micro' => '[:where(&)]:size-4',
|
|
});
|
|
|
|
$strokeWidth = match ($variant) {
|
|
'outline' => 2,
|
|
'mini' => 2.25,
|
|
'micro' => 2.5,
|
|
};
|
|
@endphp
|
|
|
|
<svg
|
|
{{ $attributes->class($classes) }}
|
|
data-flux-icon
|
|
xmlns="http://www.w3.org/2000/svg"
|
|
viewBox="0 0 24 24"
|
|
fill="none"
|
|
stroke="currentColor"
|
|
stroke-width="{{ $strokeWidth }}"
|
|
stroke-linecap="round"
|
|
stroke-linejoin="round"
|
|
aria-hidden="true"
|
|
data-slot="icon"
|
|
>
|
|
<path d="M9.937 15.5A2 2 0 0 0 8.5 14.063l-6.135-1.582a.5.5 0 0 1 0-.962L8.5 9.936A2 2 0 0 0 9.937 8.5l1.582-6.135a.5.5 0 0 1 .963 0L14.063 8.5A2 2 0 0 0 15.5 9.937l6.135 1.581a.5.5 0 0 1 0 .964L15.5 14.063a2 2 0 0 0-1.437 1.437l-1.582 6.135a.5.5 0 0 1-.963 0z" />
|
|
</svg>
|