Completed
Push — master ( 839e9e...4e091b )
by Costin
03:53
created

CloseComponent::toHtml()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 8

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
dl 0
loc 8
rs 10
c 0
b 0
f 0
cc 1
nc 1
nop 0
1
<?php 
2
3
namespace SoareCostin\BladeFormComponents\FormComponents;
4
5
use SoareCostin\BladeFormComponents\Form;
6
use Illuminate\Contracts\Support\Htmlable;
7
8
class CloseComponent implements Htmlable
9
{
10
    /** @var Form */
11
    protected $form;
12
13
    public function __construct()
14
    {
15
        $this->form = app(Form::class);
16
        $this->form->delete();
17
    }
18
19
    public function toHtml()
20
    {
21
        $theme = config('blade-form-components.theme');
22
23
        return view(
24
            'blade-form-components::themes.'.$theme.'.form-close'
25
        );
26
    }
27
}
28