2023-07-13 11:16:24 +00:00
|
|
|
<?php
|
|
|
|
|
|
|
|
namespace App\View\Components\Forms;
|
|
|
|
|
|
|
|
use Closure;
|
|
|
|
use Illuminate\Contracts\View\View;
|
|
|
|
use Illuminate\View\Component;
|
|
|
|
|
|
|
|
class Checkbox extends Component
|
|
|
|
{
|
|
|
|
/**
|
|
|
|
* Create a new component instance.
|
|
|
|
*/
|
|
|
|
public function __construct(
|
2024-03-19 14:37:16 +00:00
|
|
|
public ?string $id = null,
|
|
|
|
public ?string $name = null,
|
|
|
|
public ?string $value = null,
|
|
|
|
public ?string $label = null,
|
|
|
|
public ?string $helper = null,
|
|
|
|
public string|bool $instantSave = false,
|
2023-08-08 09:51:36 +00:00
|
|
|
public bool $disabled = false,
|
2024-03-21 11:44:32 +00:00
|
|
|
public string $defaultClass = "dark:border-neutral-700 text-warning focus:ring-warning dark:bg-coolgray-100 rounded cursor-pointer dark:disabled:bg-base dark:disabled:cursor-not-allowed",
|
2023-08-11 18:48:52 +00:00
|
|
|
) {
|
2023-07-13 11:16:24 +00:00
|
|
|
//
|
|
|
|
}
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Get the view / contents that represent the component.
|
|
|
|
*/
|
|
|
|
public function render(): View|Closure|string
|
|
|
|
{
|
|
|
|
return view('components.forms.checkbox');
|
|
|
|
}
|
|
|
|
}
|