50 lines
2.4 KiB
PHP
50 lines
2.4 KiB
PHP
@pure
|
|
|
|
{{-- Credit: Heroicons (https://heroicons.com) --}}
|
|
|
|
@props([
|
|
'variant' => 'outline',
|
|
])
|
|
|
|
@php
|
|
$classes = Flux::classes('shrink-0')
|
|
->add(match($variant) {
|
|
'outline' => '[:where(&)]:size-6',
|
|
'solid' => '[:where(&)]:size-6',
|
|
'mini' => '[:where(&)]:size-5',
|
|
'micro' => '[:where(&)]:size-4',
|
|
});
|
|
@endphp
|
|
|
|
<?php switch ($variant): case ('outline'): ?>
|
|
<svg {{ $attributes->class($classes) }} data-flux-icon xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 24 24" stroke-width="1.5" stroke="currentColor" aria-hidden="true" data-slot="icon">
|
|
<path stroke-linecap="round" stroke-linejoin="round" d="m4.5 18.75 7.5-7.5 7.5 7.5"/>
|
|
<path stroke-linecap="round" stroke-linejoin="round" d="m4.5 12.75 7.5-7.5 7.5 7.5"/>
|
|
</svg>
|
|
|
|
<?php break; ?>
|
|
|
|
<?php case ('solid'): ?>
|
|
<svg {{ $attributes->class($classes) }} data-flux-icon xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="currentColor" aria-hidden="true" data-slot="icon">
|
|
<path fill-rule="evenodd" d="M11.47 10.72a.75.75 0 0 1 1.06 0l7.5 7.5a.75.75 0 1 1-1.06 1.06L12 12.31l-6.97 6.97a.75.75 0 0 1-1.06-1.06l7.5-7.5Z" clip-rule="evenodd"/>
|
|
<path fill-rule="evenodd" d="M11.47 4.72a.75.75 0 0 1 1.06 0l7.5 7.5a.75.75 0 1 1-1.06 1.06L12 6.31l-6.97 6.97a.75.75 0 0 1-1.06-1.06l7.5-7.5Z" clip-rule="evenodd"/>
|
|
</svg>
|
|
|
|
<?php break; ?>
|
|
|
|
<?php case ('mini'): ?>
|
|
<svg {{ $attributes->class($classes) }} data-flux-icon xmlns="http://www.w3.org/2000/svg" viewBox="0 0 20 20" fill="currentColor" aria-hidden="true" data-slot="icon">
|
|
<path fill-rule="evenodd" d="M9.47 4.72a.75.75 0 0 1 1.06 0l4.25 4.25a.75.75 0 1 1-1.06 1.06L10 6.31l-3.72 3.72a.75.75 0 1 1-1.06-1.06l4.25-4.25Zm-4.25 9.25 4.25-4.25a.75.75 0 0 1 1.06 0l4.25 4.25a.75.75 0 1 1-1.06 1.06L10 11.31l-3.72 3.72a.75.75 0 0 1-1.06-1.06Z" clip-rule="evenodd"/>
|
|
</svg>
|
|
|
|
<?php break; ?>
|
|
|
|
<?php case ('micro'): ?>
|
|
<svg {{ $attributes->class($classes) }} data-flux-icon xmlns="http://www.w3.org/2000/svg" viewBox="0 0 16 16" fill="currentColor" aria-hidden="true" data-slot="icon">
|
|
<path fill-rule="evenodd" d="M7.47 3.22a.75.75 0 0 1 1.06 0l3.25 3.25a.75.75 0 0 1-1.06 1.06L8 4.81 5.28 7.53a.75.75 0 0 1-1.06-1.06l3.25-3.25Zm-3.25 8.25 3.25-3.25a.75.75 0 0 1 1.06 0l3.25 3.25a.75.75 0 1 1-1.06 1.06L8 9.81l-2.72 2.72a.75.75 0 0 1-1.06-1.06Z" clip-rule="evenodd"/>
|
|
</svg>
|
|
|
|
<?php break; ?>
|
|
|
|
<?php endswitch; ?>
|