29 lines
637 B
PHP
29 lines
637 B
PHP
<?php
|
|
|
|
namespace Beike\Admin\View\Components\Form;
|
|
|
|
use Illuminate\View\Component;
|
|
|
|
class Input extends Component
|
|
{
|
|
public string $name;
|
|
public string $title;
|
|
public string $value;
|
|
public string $class;
|
|
public bool $required;
|
|
|
|
public function __construct(string $name, string $title, ?string $value, bool $required = false, ?string $class = '')
|
|
{
|
|
$this->name = $name;
|
|
$this->title = $title;
|
|
$this->value = $value;
|
|
$this->class = $class;
|
|
$this->required = $required;
|
|
}
|
|
|
|
public function render()
|
|
{
|
|
return view('admin::components.form.input');
|
|
}
|
|
}
|