Completed
Push — master ( 1f8dca...9227ef )
by Sebastian
03:04
created

Textarea   A

Complexity

Total Complexity 3

Size/Duplication

Total Lines 32
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 1

Importance

Changes 0
Metric Value
wmc 3
lcom 0
cbo 1
dl 0
loc 32
rs 10
c 0
b 0
f 0

3 Methods

Rating   Name   Duplication   Size   Complexity  
A autofocus() 0 4 1
A name() 0 4 1
A value() 0 4 1
1
<?php
2
3
namespace Spatie\Html\Elements;
4
5
use Spatie\Html\BaseElement;
6
7
class Textarea extends BaseElement
8
{
9
    protected $tag = 'textarea';
10
11
    /**
12
     * @return static
13
     */
14
    public function autofocus()
15
    {
16
        return $this->attribute('autofocus');
17
    }
18
19
    /**
20
     * @param string $name
21
     *
22
     * @return static
23
     */
24
    public function name(?string $name)
25
    {
26
        return $this->attribute('name', $name);
27
    }
28
29
    /**
30
     * @param string $value
31
     *
32
     * @return static
33
     */
34
    public function value(?string $value)
35
    {
36
        return $this->html($value);
37
    }
38
}
39