adrema/app/View/Form/SaveButton.php

23 lines
564 B
PHP
Raw Normal View History

2024-10-14 20:25:11 +02:00
<?php
namespace App\View\Form;
use Illuminate\View\Component;
class SaveButton extends Component
{
public function __construct(public string $form = '')
{
}
public function render()
{
return <<<'HTML'
<button @if($form) form="{{$form}}" @endif type="submit" class="flex items-center transition-all justify-center w-8 h-8 bg-primary-700 hover:bg-primary-600 rounded" x-tooltip="`speichern`">
<x-ui::sprite class="w-4 h-4 text-white" src="save"></x-ui::sprite>
</button>
HTML;
}
}