Changeset View
Changeset View
Standalone View
Standalone View
src/console/view/PhutilConsoleBlock.php
Show All 23 Lines | protected function drawView() { | ||||
$output = array(); | $output = array(); | ||||
foreach ($this->items as $spec) { | foreach ($this->items as $spec) { | ||||
$type = $spec['type']; | $type = $spec['type']; | ||||
$item = $spec['item']; | $item = $spec['item']; | ||||
switch ($type) { | switch ($type) { | ||||
case 'paragraph': | case 'paragraph': | ||||
$item = phutil_console_wrap($item)."\n"; | $item = array( | ||||
tsprintf('%s', $item)->applyWrap(), | |||||
"\n", | |||||
); | |||||
break; | break; | ||||
case 'list': | case 'list': | ||||
$item = $item; | $item = $item; | ||||
break; | break; | ||||
} | } | ||||
$output[] = $item; | $output[] = $item; | ||||
} | } | ||||
return $this->drawLines($output); | return $this->drawLines($output); | ||||
} | } | ||||
} | } |