@@ 154-157 (lines=4) @@ | ||
151 | public function output(Node $node, &$output = '', $level = 0) |
|
152 | { |
|
153 | $hasSelector = isset($node->selector{0}); |
|
154 | if ($hasSelector) { |
|
155 | // Generate tabs array |
|
156 | $output .= implode('', array_fill(0, $level, ' ')) . $node . ' {' . "\n"; |
|
157 | } |
|
158 | ||
159 | foreach ($node->children as $child) { |
|
160 | $this->output($child, $output, $level + 1); |
|
@@ 163-165 (lines=3) @@ | ||
160 | $this->output($child, $output, $level + 1); |
|
161 | } |
|
162 | ||
163 | if ($hasSelector) { |
|
164 | $output .= implode('', array_fill(0, $level, ' ')) . '}' . "\n"; |
|
165 | } |
|
166 | ||
167 | return $output; |
|
168 | } |