Completed
Push — master ( 024746...0b49f1 )
by Song
04:00
created
src/Form/Field/Checkbox.php 1 patch
Doc Comments   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -21,7 +21,7 @@
 block discarded – undo
21 21
      *
22 22
      * @param array|callable|string $options
23 23
      *
24
-     * @return $this|mixed
24
+     * @return Checkbox
25 25
      */
26 26
     public function options($options = [])
27 27
     {
Please login to merge, or discard this patch.
src/Form/Field/ImageField.php 1 patch
Doc Comments   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -28,7 +28,7 @@
 block discarded – undo
28 28
      *
29 29
      * @param string $target
30 30
      *
31
-     * @return mixed
31
+     * @return string
32 32
      */
33 33
     public function callInterventionMethods($target)
34 34
     {
Please login to merge, or discard this patch.
src/Form/Field/PlainInput.php 1 patch
Doc Comments   +9 added lines patch added patch discarded remove patch
@@ -8,6 +8,9 @@  discard block
 block discarded – undo
8 8
 
9 9
     protected $append;
10 10
 
11
+    /**
12
+     * @param string $string
13
+     */
11 14
     public function prepend($string)
12 15
     {
13 16
         if (is_null($this->prepend)) {
@@ -17,6 +20,9 @@  discard block
 block discarded – undo
17 20
         return $this;
18 21
     }
19 22
 
23
+    /**
24
+     * @param string $string
25
+     */
20 26
     public function append($string)
21 27
     {
22 28
         if (is_null($this->append)) {
@@ -33,6 +39,9 @@  discard block
 block discarded – undo
33 39
         }
34 40
     }
35 41
 
42
+    /**
43
+     * @param string $attribute
44
+     */
36 45
     protected function defaultAttribute($attribute, $value)
37 46
     {
38 47
         if (!array_key_exists($attribute, $this->attributes)) {
Please login to merge, or discard this patch.
src/Form/NestedForm.php 2 patches
Doc Comments   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -292,7 +292,7 @@
 block discarded – undo
292 292
     /**
293 293
      * Get the html and script of template.
294 294
      *
295
-     * @return array
295
+     * @return string[]
296 296
      */
297 297
     public function getTemplateHtmlAndScript()
298 298
     {
Please login to merge, or discard this patch.
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -173,7 +173,7 @@
 block discarded – undo
173 173
         if (array_key_exists($key, $this->original)) {
174 174
             $values = $this->original[$key];
175 175
         }
176
-        $this->fields->each(function (Field $field) use ($values) {
176
+        $this->fields->each(function(Field $field) use ($values) {
177 177
             $field->setOriginal($values);
178 178
         });
179 179
     }
Please login to merge, or discard this patch.
src/Grid/Column.php 2 patches
Doc Comments   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -125,7 +125,7 @@  discard block
 block discarded – undo
125 125
     /**
126 126
      * Extend column displayer.
127 127
      *
128
-     * @param $name
128
+     * @param string $name
129 129
      * @param $displayer
130 130
      */
131 131
     public static function extend($name, $displayer)
@@ -159,7 +159,7 @@  discard block
 block discarded – undo
159 159
     /**
160 160
      * Set model for column.
161 161
      *
162
-     * @param $model
162
+     * @param Model $model
163 163
      */
164 164
     public function setModel($model)
165 165
     {
@@ -216,7 +216,7 @@  discard block
 block discarded – undo
216 216
     /**
217 217
      * Get name of this column.
218 218
      *
219
-     * @return mixed
219
+     * @return string
220 220
      */
221 221
     public function getName()
222 222
     {
@@ -226,7 +226,7 @@  discard block
 block discarded – undo
226 226
     /**
227 227
      * Format label.
228 228
      *
229
-     * @param $label
229
+     * @param string $label
230 230
      *
231 231
      * @return mixed
232 232
      */
@@ -240,7 +240,7 @@  discard block
 block discarded – undo
240 240
     /**
241 241
      * Get label of the column.
242 242
      *
243
-     * @return mixed
243
+     * @return string
244 244
      */
245 245
     public function getLabel()
246 246
     {
Please login to merge, or discard this patch.
Spacing   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -311,7 +311,7 @@  discard block
 block discarded – undo
311 311
      */
312 312
     public function values(array $values, $default = null)
313 313
     {
314
-        return $this->display(function ($value) use ($values, $default) {
314
+        return $this->display(function($value) use ($values, $default) {
315 315
             return array_get($values, $value, $default);
316 316
         });
317 317
     }
@@ -423,7 +423,7 @@  discard block
 block discarded – undo
423 423
         $grid = $this->grid;
424 424
         $column = $this;
425 425
 
426
-        $this->display(function ($value) use ($grid, $column, $class) {
426
+        $this->display(function($value) use ($grid, $column, $class) {
427 427
             $definition = new $class($value, $grid, $column, $this);
428 428
 
429 429
             return $definition->display();
@@ -440,7 +440,7 @@  discard block
 block discarded – undo
440 440
     protected function htmlEntityEncode($item)
441 441
     {
442 442
         if (is_array($item)) {
443
-            array_walk_recursive($item, function (&$value) {
443
+            array_walk_recursive($item, function(&$value) {
444 444
                 $value = htmlentities($value);
445 445
             });
446 446
         } else {
@@ -520,7 +520,7 @@  discard block
 block discarded – undo
520 520
      */
521 521
     protected function callSupportDisplayer($abstract, $arguments)
522 522
     {
523
-        return $this->display(function ($value) use ($abstract, $arguments) {
523
+        return $this->display(function($value) use ($abstract, $arguments) {
524 524
             if (is_array($value) || $value instanceof Arrayable) {
525 525
                 return call_user_func_array([collect($value), $abstract], $arguments);
526 526
             }
@@ -544,7 +544,7 @@  discard block
 block discarded – undo
544 544
     protected function callBuiltinDisplayer($abstract, $arguments)
545 545
     {
546 546
         if ($abstract instanceof Closure) {
547
-            return $this->display(function ($value) use ($abstract, $arguments) {
547
+            return $this->display(function($value) use ($abstract, $arguments) {
548 548
                 return $abstract->call($this, ...array_merge([$value], $arguments));
549 549
             });
550 550
         }
@@ -553,7 +553,7 @@  discard block
 block discarded – undo
553 553
             $grid = $this->grid;
554 554
             $column = $this;
555 555
 
556
-            return $this->display(function ($value) use ($abstract, $grid, $column, $arguments) {
556
+            return $this->display(function($value) use ($abstract, $grid, $column, $arguments) {
557 557
                 $displayer = new $abstract($value, $grid, $column, $this);
558 558
 
559 559
                 return call_user_func_array([$displayer, 'display'], $arguments);
Please login to merge, or discard this patch.
src/Grid/Displayers/Actions.php 2 patches
Doc Comments   +1 added lines patch added patch discarded remove patch
@@ -108,6 +108,7 @@
 block discarded – undo
108 108
 
109 109
     /**
110 110
      * {@inheritdoc}
111
+     * @param \Closure $callback
111 112
      */
112 113
     public function display($callback = null)
113 114
     {
Please login to merge, or discard this patch.
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -128,7 +128,7 @@
 block discarded – undo
128 128
         $actions = $this->prepends;
129 129
 
130 130
         foreach ($this->actions as $action) {
131
-            $method = 'render' . ucfirst($action);
131
+            $method = 'render'.ucfirst($action);
132 132
             array_push($actions, $this->{$method}());
133 133
         }
134 134
 
Please login to merge, or discard this patch.
src/Traits/ModelTree.php 2 patches
Doc Comments   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -229,7 +229,7 @@
 block discarded – undo
229 229
     /**
230 230
      * Get options for Select field in form.
231 231
      *
232
-     * @return \Illuminate\Support\Collection
232
+     * @return callable
233 233
      */
234 234
     public static function selectOptions()
235 235
     {
Please login to merge, or discard this patch.
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -196,7 +196,7 @@  discard block
 block discarded – undo
196 196
     {
197 197
         static::$branchOrder = array_flip(array_flatten($order));
198 198
 
199
-        static::$branchOrder = array_map(function ($item) {
199
+        static::$branchOrder = array_map(function($item) {
200 200
             return ++$item;
201 201
         }, static::$branchOrder);
202 202
     }
@@ -290,7 +290,7 @@  discard block
 block discarded – undo
290 290
     {
291 291
         parent::boot();
292 292
 
293
-        static::saving(function (Model $branch) {
293
+        static::saving(function(Model $branch) {
294 294
             $parentColumn = $branch->getParentColumn();
295 295
 
296 296
             if (Request::has($parentColumn) && Request::input($parentColumn) == $branch->getKey()) {
Please login to merge, or discard this patch.
src/Tree.php 2 patches
Doc Comments   -1 removed lines patch added patch discarded remove patch
@@ -282,7 +282,6 @@
 block discarded – undo
282 282
     /**
283 283
      * Return all items of the tree.
284 284
      *
285
-     * @param array $items
286 285
      */
287 286
     public function getItems()
288 287
     {
Please login to merge, or discard this patch.
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -103,7 +103,7 @@
 block discarded – undo
103 103
     protected function initBranchCallback()
104 104
     {
105 105
         if (is_null($this->branchCallback)) {
106
-            $this->branchCallback = function ($branch) {
106
+            $this->branchCallback = function($branch) {
107 107
                 $key = $branch[$this->model->getKeyName()];
108 108
                 $title = $branch[$this->model->getTitleColumn()];
109 109
 
Please login to merge, or discard this patch.
src/Tree/Tools.php 2 patches
Doc Comments   -1 removed lines patch added patch discarded remove patch
@@ -26,7 +26,6 @@
 block discarded – undo
26 26
     /**
27 27
      * Create a new Tools instance.
28 28
      *
29
-     * @param Builder $builder
30 29
      */
31 30
     public function __construct(Tree $tree)
32 31
     {
Please login to merge, or discard this patch.
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -55,7 +55,7 @@
 block discarded – undo
55 55
      */
56 56
     public function render()
57 57
     {
58
-        return $this->tools->map(function ($tool) {
58
+        return $this->tools->map(function($tool) {
59 59
             if ($tool instanceof Renderable) {
60 60
                 return $tool->render();
61 61
             }
Please login to merge, or discard this patch.