Archived
1
0
Fork 0

Form: adding checkbox component.

This commit is contained in:
Henrik Hautakoski 2021-07-23 17:00:07 +02:00
parent 01b1b06541
commit f9d44de6cb
3 changed files with 29 additions and 0 deletions

View file

@ -0,0 +1,21 @@
<?php
namespace App\View\Components\Form;
class Checkbox extends Input
{
public function __construct($name, ?string $id = null, ?string $value = null, bool $disabled = false)
{
parent::__construct($name, $id, 'checkbox', $value, $disabled);
}
/**
* Get the view / contents that represent the component.
*
* @return \Illuminate\Contracts\View\View|\Closure|string
*/
public function render()
{
return view('components.form.inputs.checkbox');
}
}