FormGroup   A
last analyzed

Complexity

Total Complexity 2

Size/Duplication

Total Lines 19
Duplicated Lines 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
wmc 2
eloc 9
c 1
b 0
f 0
dl 0
loc 19
rs 10

1 Method

Rating   Name   Duplication   Size   Complexity  
A __construct() 0 6 2
1
<?php
2
3
namespace ProtoneMedia\LaravelFormComponents\Components;
4
5
class FormGroup extends Component
6
{
7
    use HandlesValidationErrors;
8
9
    public string $name;
10
    public string $label;
11
    public bool $inline = false;
12
13
    /**
14
     * Create a new component instance.
15
     *
16
     * @return void
17
     */
18
    public function __construct(string $name = '', string $label = '', bool $inline = false, bool $showErrors = true)
19
    {
20
        $this->name       = $name;
21
        $this->label      = $label;
22
        $this->inline     = $inline;
23
        $this->showErrors = $name && $showErrors;
24
    }
25
}
26