| Conditions | 3 |
| Paths | 2 |
| Total Lines | 16 |
| Code Lines | 9 |
| Lines | 0 |
| Ratio | 0 % |
| Tests | 10 |
| CRAP Score | 3 |
| Changes | 0 | ||
| 1 | <?php |
||
| 28 | 20 | protected function run(): string |
|
| 29 | { |
||
| 30 | 20 | if (!isset($this->options['id'])) { |
|
| 31 | 12 | $this->options['id'] = "{$this->getId()}-button"; |
|
| 32 | } |
||
| 33 | |||
| 34 | /** @psalm-suppress InvalidArgument */ |
||
| 35 | 20 | Html::addCssClass($this->options, ['widget' => 'btn']); |
|
| 36 | |||
| 37 | 20 | return Html::tag( |
|
| 38 | 20 | $this->tagName, |
|
| 39 | 20 | $this->encodeLabels ? Html::encode($this->label) : $this->label, |
|
| 40 | 20 | $this->options |
|
| 41 | ) |
||
| 42 | 20 | ->encode($this->encodeTags) |
|
| 43 | 20 | ->render(); |
|
| 44 | } |
||
| 106 |