| Conditions | 3 |
| Paths | 3 |
| Total Lines | 12 |
| Code Lines | 7 |
| Lines | 0 |
| Ratio | 0 % |
| Tests | 8 |
| CRAP Score | 3 |
| Changes | 0 | ||
| 1 | <?php |
||
| 7 | 9 | public function getWidthByContent(int $endOfPreviousSibling = 0): int |
|
| 8 | { |
||
| 9 | 9 | $this->offsetX = $this->__get('paddingLeft') + $this->__get('borderLeft'); |
|
| 10 | 9 | if ($this->renderedWidth) { |
|
| 11 | 8 | return $this->width; |
|
| 12 | } |
||
| 13 | |||
| 14 | 9 | foreach ($this->children as $child) { |
|
| 15 | 9 | $this->width = $child->getWidthByContent(0); |
|
| 16 | } |
||
| 17 | 9 | parent::appendWidth($this->width); |
|
| 18 | 9 | return $this->width; |
|
| 19 | } |
||
| 35 |