Total Complexity | 6 |
Total Lines | 33 |
Duplicated Lines | 0 % |
Coverage | 100% |
Changes | 1 | ||
Bugs | 0 | Features | 0 |
1 | <?php |
||
12 | trait PlaceholderTrait |
||
13 | { |
||
14 | private ?string $placeholder = null; |
||
15 | private bool $usePlaceholder = true; |
||
16 | |||
17 | 6 | public function placeholder(?string $placeholder): self |
|
18 | { |
||
19 | 6 | $new = clone $this; |
|
20 | 6 | $new->placeholder = $placeholder; |
|
21 | 6 | return $new; |
|
22 | } |
||
23 | |||
24 | 8 | public function usePlaceholder(bool $use): self |
|
29 | } |
||
30 | |||
31 | 225 | protected function preparePlaceholderInInputAttributes(array &$attributes): void |
|
40 | } |
||
41 | } |
||
42 | } |
||
43 | |||
44 | abstract protected function getInputData(): InputDataInterface; |
||
45 | } |
||
46 |