Card::__construct()   A
last analyzed

Complexity

Conditions 1
Paths 1

Size

Total Lines 7
Code Lines 4

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
cc 1
eloc 4
nc 1
nop 4
dl 0
loc 7
rs 10
c 0
b 0
f 0
1
<?php
2
3
namespace Pratiksh\Adminetic\View\Components;
4
5
use Illuminate\View\Component;
6
7
class Card extends Component
8
{
9
    public $title;
10
11
    public $icon;
12
13
    public $bg_color;
14
15
    public $card_footer_enabled;
16
17
    /**
18
     * Create a new component instance.
19
     *
20
     * @return void
21
     */
22
    public function __construct($title, $icon = null, $bg_color = null, $card_footer_enabled = false)
23
    {
24
        //
25
        $this->title = $title;
26
        $this->icon = $icon;
27
        $this->bg_color = $bg_color;
28
        $this->card_footer_enabled = $card_footer_enabled;
29
    }
30
31
    /**
32
     * Get the view / contents that represent the component.
33
     *
34
     * @return \Illuminate\Contracts\View\View|\Closure|string
35
     */
36
    public function render()
37
    {
38
        return view('adminetic::components.card');
39
    }
40
}
41