@@ -20,6 +20,7 @@ |
||
| 20 | 20 | /** |
| 21 | 21 | * Given the total amount of available space, and the width of |
| 22 | 22 | * the columns to place, calculate the optimum column widths to use. |
| 23 | + * @param double $totalWidth |
|
| 23 | 24 | */ |
| 24 | 25 | public function calculate($totalWidth, DataCellWidths $dataWidths, $minimumWidths = []) |
| 25 | 26 | { |
@@ -1,8 +1,6 @@ |
||
| 1 | 1 | <?php |
| 2 | 2 | namespace Consolidation\OutputFormatters\Transformations\Wrap; |
| 3 | 3 | |
| 4 | -use Symfony\Component\Console\Helper\TableStyle; |
|
| 5 | - |
|
| 6 | 4 | /** |
| 7 | 5 | * Calculate column widths for table cells. |
| 8 | 6 | * |
@@ -166,7 +166,7 @@ discard block |
||
| 166 | 166 | { |
| 167 | 167 | return array_reduce( |
| 168 | 168 | $widths, |
| 169 | - function ($carry, $item) { |
|
| 169 | + function($carry, $item) { |
|
| 170 | 170 | return $carry + $item; |
| 171 | 171 | } |
| 172 | 172 | ); |
@@ -180,7 +180,7 @@ discard block |
||
| 180 | 180 | protected static function longestWordLength($str) |
| 181 | 181 | { |
| 182 | 182 | $words = preg_split('#[ /-]#', $str); |
| 183 | - $lengths = array_map(function ($s) { |
|
| 183 | + $lengths = array_map(function($s) { |
|
| 184 | 184 | return strlen($s); |
| 185 | 185 | }, $words); |
| 186 | 186 | return max($lengths); |