@@ -289,7 +289,7 @@ discard block |
||
289 | 289 | /** |
290 | 290 | * Run a macro on the image. |
291 | 291 | * |
292 | - * @param $macro |
|
292 | + * @param string $macro |
|
293 | 293 | * @return Image |
294 | 294 | * @throws \Exception |
295 | 295 | */ |
@@ -394,7 +394,7 @@ discard block |
||
394 | 394 | * |
395 | 395 | * @param null $format |
396 | 396 | * @param int $quality |
397 | - * @return String |
|
397 | + * @return \Intervention\Image\Image |
|
398 | 398 | */ |
399 | 399 | public function encode($format = null, $quality = null) |
400 | 400 | { |
@@ -495,7 +495,7 @@ discard block |
||
495 | 495 | /** |
496 | 496 | * Determine if the image needs to be published |
497 | 497 | * |
498 | - * @param $path |
|
498 | + * @param string $path |
|
499 | 499 | * @return bool |
500 | 500 | */ |
501 | 501 | private function shouldPublish($path) |
@@ -531,7 +531,7 @@ discard block |
||
531 | 531 | /** |
532 | 532 | * Publish an image to the publish directory. |
533 | 533 | * |
534 | - * @param $path |
|
534 | + * @param string $path |
|
535 | 535 | */ |
536 | 536 | protected function publish($path) |
537 | 537 | { |
@@ -600,7 +600,7 @@ discard block |
||
600 | 600 | /** |
601 | 601 | * Return the image srcsets by set. |
602 | 602 | * |
603 | - * @return array |
|
603 | + * @return string |
|
604 | 604 | */ |
605 | 605 | public function srcset() |
606 | 606 | { |
@@ -843,7 +843,7 @@ discard block |
||
843 | 843 | /** |
844 | 844 | * Get the image instance. |
845 | 845 | * |
846 | - * @return \Intervention\Image\Image |
|
846 | + * @return null|string |
|
847 | 847 | */ |
848 | 848 | public function getImage() |
849 | 849 | { |
@@ -940,7 +940,7 @@ discard block |
||
940 | 940 | /** |
941 | 941 | * Add an attribute. |
942 | 942 | * |
943 | - * @param $attribute |
|
943 | + * @param string $attribute |
|
944 | 944 | * @param $value |
945 | 945 | * @return $this |
946 | 946 | */ |
@@ -1015,7 +1015,7 @@ discard block |
||
1015 | 1015 | /** |
1016 | 1016 | * Set the output mode. |
1017 | 1017 | * |
1018 | - * @param $output |
|
1018 | + * @param string $output |
|
1019 | 1019 | * @return $this |
1020 | 1020 | */ |
1021 | 1021 | public function setOutput($output) |
@@ -1061,7 +1061,7 @@ discard block |
||
1061 | 1061 | /** |
1062 | 1062 | * Add a path by it's namespace hint. |
1063 | 1063 | * |
1064 | - * @param $namespace |
|
1064 | + * @param string $namespace |
|
1065 | 1065 | * @param $path |
1066 | 1066 | * @return $this |
1067 | 1067 | */ |
@@ -107,7 +107,7 @@ |
||
107 | 107 | /** |
108 | 108 | * Return if a macro exists or not. |
109 | 109 | * |
110 | - * @param $macro |
|
110 | + * @param string $macro |
|
111 | 111 | * @return bool |
112 | 112 | */ |
113 | 113 | public function isMacro($macro) |
@@ -24,7 +24,6 @@ |
||
24 | 24 | use Anomaly\Streams\Platform\Installer\InstallerCollection; |
25 | 25 | use Anomaly\Streams\Platform\Support\Collection; |
26 | 26 | use Illuminate\Console\Command; |
27 | -use Illuminate\Contracts\Config\Repository; |
|
28 | 27 | use Illuminate\Contracts\Events\Dispatcher; |
29 | 28 | use Illuminate\Foundation\Bus\DispatchesJobs; |
30 | 29 |
@@ -388,7 +388,7 @@ |
||
388 | 388 | * Get an option value. |
389 | 389 | * |
390 | 390 | * @param $key |
391 | - * @param null $default |
|
391 | + * @param integer|null $default |
|
392 | 392 | * @return mixed |
393 | 393 | */ |
394 | 394 | public function getOption($key, $default = null) |
@@ -128,7 +128,7 @@ |
||
128 | 128 | /** |
129 | 129 | * Set the constraint. |
130 | 130 | * |
131 | - * @param $constraint |
|
131 | + * @param string $constraint |
|
132 | 132 | * @return $this |
133 | 133 | */ |
134 | 134 | public function setConstraint($constraint) |
@@ -196,7 +196,7 @@ discard block |
||
196 | 196 | /** |
197 | 197 | * Set a field value. |
198 | 198 | * |
199 | - * @param $fieldSlug |
|
199 | + * @param string $fieldSlug |
|
200 | 200 | * @param $value |
201 | 201 | * @param null $locale |
202 | 202 | * @return $this |
@@ -608,7 +608,7 @@ discard block |
||
608 | 608 | * Return whether or not the assignment for |
609 | 609 | * the given field slug is translatable. |
610 | 610 | * |
611 | - * @param $fieldSlug |
|
611 | + * @param string $fieldSlug |
|
612 | 612 | * @return bool |
613 | 613 | */ |
614 | 614 | public function assignmentIsTranslatable($fieldSlug) |
@@ -1,6 +1,5 @@ |
||
1 | 1 | <?php namespace Anomaly\Streams\Platform\Ui\Table\Component\Header\Guesser; |
2 | 2 | |
3 | -use Anomaly\Streams\Platform\Addon\Module\Module; |
|
4 | 3 | use Anomaly\Streams\Platform\Addon\Module\ModuleCollection; |
5 | 4 | use Anomaly\Streams\Platform\Stream\Contract\StreamInterface; |
6 | 5 | use Anomaly\Streams\Platform\Support\Str; |
@@ -274,7 +274,7 @@ discard block |
||
274 | 274 | /** |
275 | 275 | * Fire field events. |
276 | 276 | * |
277 | - * @param $trigger |
|
277 | + * @param string $trigger |
|
278 | 278 | * @param array $payload |
279 | 279 | */ |
280 | 280 | public function fireFieldEvents($trigger, array $payload = []) |
@@ -408,7 +408,7 @@ discard block |
||
408 | 408 | /** |
409 | 409 | * Set the form model. |
410 | 410 | * |
411 | - * @param $model |
|
411 | + * @param string|null $model |
|
412 | 412 | * @return $this |
413 | 413 | */ |
414 | 414 | public function setModel($model) |
@@ -444,7 +444,7 @@ discard block |
||
444 | 444 | /** |
445 | 445 | * Get the entry object. |
446 | 446 | * |
447 | - * @return null|EntryInterface|FieldInterface|mixed |
|
447 | + * @return null|integer |
|
448 | 448 | */ |
449 | 449 | public function getEntry() |
450 | 450 | { |
@@ -685,8 +685,8 @@ discard block |
||
685 | 685 | /** |
686 | 686 | * Get an option value. |
687 | 687 | * |
688 | - * @param $key |
|
689 | - * @param null $default |
|
688 | + * @param string $key |
|
689 | + * @param string $default |
|
690 | 690 | * @return mixed |
691 | 691 | */ |
692 | 692 | public function getOption($key, $default = null) |
@@ -697,8 +697,8 @@ discard block |
||
697 | 697 | /** |
698 | 698 | * Set an option value. |
699 | 699 | * |
700 | - * @param $key |
|
701 | - * @param $value |
|
700 | + * @param string $key |
|
701 | + * @param string $value |
|
702 | 702 | * @return $this |
703 | 703 | */ |
704 | 704 | public function setOption($key, $value) |
@@ -762,7 +762,7 @@ discard block |
||
762 | 762 | /** |
763 | 763 | * Get a form option value. |
764 | 764 | * |
765 | - * @param $key |
|
765 | + * @param string $key |
|
766 | 766 | * @param null $default |
767 | 767 | * @return mixed |
768 | 768 | */ |
@@ -818,7 +818,7 @@ discard block |
||
818 | 818 | /** |
819 | 819 | * Return the form entry's ID. |
820 | 820 | * |
821 | - * @return int|mixed|null |
|
821 | + * @return null|integer |
|
822 | 822 | */ |
823 | 823 | public function getFormEntryId() |
824 | 824 | { |
@@ -854,7 +854,7 @@ discard block |
||
854 | 854 | /** |
855 | 855 | * Set the form mode. |
856 | 856 | * |
857 | - * @param $mode |
|
857 | + * @param string $mode |
|
858 | 858 | * @return $this |
859 | 859 | */ |
860 | 860 | public function setFormMode($mode) |
@@ -879,7 +879,7 @@ discard block |
||
879 | 879 | /** |
880 | 880 | * Set a form value. |
881 | 881 | * |
882 | - * @param $key |
|
882 | + * @param string $key |
|
883 | 883 | * @param $value |
884 | 884 | * @return $this |
885 | 885 | */ |
@@ -949,7 +949,7 @@ discard block |
||
949 | 949 | /** |
950 | 950 | * Set the form response. |
951 | 951 | * |
952 | - * @param null|false|Response $response |
|
952 | + * @param Response $response |
|
953 | 953 | * @return $this |
954 | 954 | */ |
955 | 955 | public function setFormResponse(Response $response) |
@@ -1021,7 +1021,7 @@ discard block |
||
1021 | 1021 | * Disable a form field. |
1022 | 1022 | * |
1023 | 1023 | * @param $fieldSlug |
1024 | - * @return FieldType |
|
1024 | + * @return Form |
|
1025 | 1025 | */ |
1026 | 1026 | public function disableFormField($fieldSlug) |
1027 | 1027 | { |
@@ -1087,7 +1087,7 @@ discard block |
||
1087 | 1087 | /** |
1088 | 1088 | * Get the form errors. |
1089 | 1089 | * |
1090 | - * @return null|MessageBag |
|
1090 | + * @return \Illuminate\Support\MessageBag |
|
1091 | 1091 | */ |
1092 | 1092 | public function getFormErrors() |
1093 | 1093 | { |
@@ -1186,9 +1186,9 @@ discard block |
||
1186 | 1186 | /** |
1187 | 1187 | * Get a request value. |
1188 | 1188 | * |
1189 | - * @param $key |
|
1189 | + * @param string $key |
|
1190 | 1190 | * @param null $default |
1191 | - * @return mixed |
|
1191 | + * @return string |
|
1192 | 1192 | */ |
1193 | 1193 | public function getRequestValue($key, $default = null) |
1194 | 1194 | { |
@@ -1211,8 +1211,7 @@ discard block |
||
1211 | 1211 | * Return a post key flag. |
1212 | 1212 | * |
1213 | 1213 | * @param $key |
1214 | - * @param null $default |
|
1215 | - * @return mixed |
|
1214 | + * @return boolean |
|
1216 | 1215 | */ |
1217 | 1216 | public function hasPostedInput($key) |
1218 | 1217 | { |
@@ -112,7 +112,7 @@ discard block |
||
112 | 112 | /** |
113 | 113 | * Fire a model event. |
114 | 114 | * |
115 | - * @param $event |
|
115 | + * @param string $event |
|
116 | 116 | * @return mixed |
117 | 117 | */ |
118 | 118 | public function fireEvent($event) |
@@ -385,11 +385,17 @@ discard block |
||
385 | 385 | return get_class($this) . 'Translation'; |
386 | 386 | } |
387 | 387 | |
388 | + /** |
|
389 | + * @return string|null |
|
390 | + */ |
|
388 | 391 | public function getRelationKey() |
389 | 392 | { |
390 | 393 | return $this->translationForeignKey ?: $this->getForeignKey(); |
391 | 394 | } |
392 | 395 | |
396 | + /** |
|
397 | + * @return string |
|
398 | + */ |
|
393 | 399 | public function getLocaleKey() |
394 | 400 | { |
395 | 401 | return $this->localeKey ?: 'locale'; |
@@ -573,6 +579,9 @@ discard block |
||
573 | 579 | return parent::fill($attributes); |
574 | 580 | } |
575 | 581 | |
582 | + /** |
|
583 | + * @param string $key |
|
584 | + */ |
|
576 | 585 | private function getTranslationByLocaleKey($key) |
577 | 586 | { |
578 | 587 | foreach ($this->translations as $translation) { |
@@ -734,6 +743,9 @@ discard block |
||
734 | 743 | return class_exists($criteria) ? $criteria : EloquentCriteria::class; |
735 | 744 | } |
736 | 745 | |
746 | + /** |
|
747 | + * @param string $key |
|
748 | + */ |
|
737 | 749 | public function __get($key) |
738 | 750 | { |
739 | 751 | if ($this->hasHook($key)) { |