Total Complexity | 4 |
Total Lines | 25 |
Duplicated Lines | 0 % |
Coverage | 100% |
Changes | 0 |
1 | <?php |
||
11 | class DivConverter implements ConverterInterface, ConfigurationAwareInterface |
||
12 | { |
||
13 | /** @var Configuration */ |
||
14 | protected $config; |
||
15 | |||
16 | public function setConfig(Configuration $config): void |
||
19 | 99 | } |
|
20 | |||
21 | 99 | public function convert(ElementInterface $element): string |
|
22 | 99 | { |
|
23 | if ($this->config->getOption('strip_tags', false)) { |
||
24 | return $element->getValue() . "\n\n"; |
||
25 | } |
||
26 | |||
27 | return \html_entity_decode($element->getChildrenAsString()); |
||
28 | } |
||
29 | 6 | ||
30 | /** |
||
31 | 6 | * @return string[] |
|
32 | 3 | */ |
|
33 | public function getSupportedTags(): array |
||
36 | } |
||
37 | } |
||
38 |