Completed
Push — main ( 9234ee...3f1eec )
by nassim
12:56
created
src/MenuItem.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -349,13 +349,13 @@  discard block
 block discarded – undo
349 349
     public function getIcon($default = null)
350 350
     {
351 351
         if ($this->icon !== null && $this->icon !== '') {
352
-            return '<i class="' . $this->icon . '"></i>';
352
+            return '<i class="'.$this->icon.'"></i>';
353 353
         }
354 354
         if ($default === null) {
355 355
             return $default;
356 356
         }
357 357
 
358
-        return '<i class="' . $default . '"></i>';
358
+        return '<i class="'.$default.'"></i>';
359 359
     }
360 360
 
361 361
     /**
@@ -561,7 +561,7 @@  discard block
 block discarded – undo
561 561
      */
562 562
     protected function getActiveStateFromRoute()
563 563
     {
564
-        return Request::is(str_replace(url('/') . '/', '', $this->getUrl()));
564
+        return Request::is(str_replace(url('/').'/', '', $this->getUrl()));
565 565
     }
566 566
 
567 567
     /**
Please login to merge, or discard this patch.
src/MenuBuilder.php 1 patch
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -124,7 +124,7 @@  discard block
 block discarded – undo
124 124
      */
125 125
     public function findBy($key, $value)
126 126
     {
127
-        return collect($this->items)->filter(function ($item) use ($key, $value) {
127
+        return collect($this->items)->filter(function($item) use ($key, $value) {
128 128
             return $item->{$key} == $value;
129 129
         })->first();
130 130
     }
@@ -295,7 +295,7 @@  discard block
 block discarded – undo
295 295
             
296 296
             foreach ($matches as $match) {
297 297
                 if (array_key_exists($match[1], $this->bindings)) {
298
-                    $key = preg_replace('/' . $match[0] . '/', $this->bindings[$match[1]], $key, 1);
298
+                    $key = preg_replace('/'.$match[0].'/', $this->bindings[$match[1]], $key, 1);
299 299
                 }
300 300
             }
301 301
         }
@@ -311,7 +311,7 @@  discard block
 block discarded – undo
311 311
      */
312 312
     protected function resolveItems(array &$items)
313 313
     {
314
-        $resolver = function ($property) {
314
+        $resolver = function($property) {
315 315
             return $this->resolve($property) ?: $property;
316 316
         };
317 317
 
@@ -410,7 +410,7 @@  discard block
 block discarded – undo
410 410
      */
411 411
     protected function formatUrl($url)
412 412
     {
413
-        $uri = !is_null($this->prefixUrl) ? $this->prefixUrl . $url : $url;
413
+        $uri = !is_null($this->prefixUrl) ? $this->prefixUrl.$url : $url;
414 414
 
415 415
         return $uri == '/' ? '/' : ltrim(rtrim($uri, '/'), '/');
416 416
     }
@@ -616,7 +616,7 @@  discard block
 block discarded – undo
616 616
     public function getOrderedItems()
617 617
     {
618 618
         if (config('menu.ordering') || $this->ordering) {
619
-            return $this->toCollection()->sortBy(function ($item) {
619
+            return $this->toCollection()->sortBy(function($item) {
620 620
                 return $item->order;
621 621
             })->all();
622 622
         }
Please login to merge, or discard this patch.
src/Menu.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -101,7 +101,7 @@
 block discarded – undo
101 101
      */
102 102
     public function modify($name, Closure $callback)
103 103
     {
104
-        $menu = collect($this->menu)->filter(function ($menu) use ($name) {
104
+        $menu = collect($this->menu)->filter(function($menu) use ($name) {
105 105
             return $menu->getName() == $name;
106 106
         })->first();
107 107
 
Please login to merge, or discard this patch.
src/Provider.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -19,8 +19,8 @@  discard block
 block discarded – undo
19 19
      */
20 20
     public function boot()
21 21
     {
22
-        $configPath = __DIR__ . '/Config/menu.php';
23
-        $viewsPath = __DIR__ . '/Resources/views';
22
+        $configPath = __DIR__.'/Config/menu.php';
23
+        $viewsPath = __DIR__.'/Resources/views';
24 24
         
25 25
         $this->mergeConfigFrom($configPath, 'menu');
26 26
         $this->loadViewsFrom($viewsPath, 'menu');
@@ -45,7 +45,7 @@  discard block
 block discarded – undo
45 45
     {
46 46
         $this->registerHtmlPackage();
47 47
 
48
-        $this->app->singleton('menu', function ($app) {
48
+        $this->app->singleton('menu', function($app) {
49 49
             return new Menu($app['view'], $app['config']);
50 50
         });
51 51
     }
Please login to merge, or discard this patch.
src/Presenters/Bootstrap3/NavPills.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -9,6 +9,6 @@
 block discarded – undo
9 9
      */
10 10
     public function getOpenTagWrapper()
11 11
     {
12
-        return PHP_EOL . '<ul class="nav nav-pills">' . PHP_EOL;
12
+        return PHP_EOL.'<ul class="nav nav-pills">'.PHP_EOL;
13 13
     }
14 14
 }
Please login to merge, or discard this patch.
src/Presenters/Bootstrap3/NavbarRight.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -9,7 +9,7 @@  discard block
 block discarded – undo
9 9
      */
10 10
     public function getOpenTagWrapper()
11 11
     {
12
-        return PHP_EOL . '<ul class="nav navbar-nav navbar-right">' . PHP_EOL;
12
+        return PHP_EOL.'<ul class="nav navbar-nav navbar-right">'.PHP_EOL;
13 13
     }
14 14
 
15 15
     /**
@@ -19,11 +19,11 @@  discard block
 block discarded – undo
19 19
     {
20 20
         return '<li class="dropdown pull-right">
21 21
 			      <a href="#" class="dropdown-toggle" data-toggle="dropdown">
22
-					' . $item->getIcon() . ' ' . $item->title . '
22
+					' . $item->getIcon().' '.$item->title.'
23 23
 			      	<b class="caret"></b>
24 24
 			      </a>
25 25
 			      <ul class="dropdown-menu">
26
-			      	' . $this->getChildMenuItems($item) . '
26
+			      	' . $this->getChildMenuItems($item).'
27 27
 			      </ul>
28 28
 		      	</li>'
29 29
         . PHP_EOL;
Please login to merge, or discard this patch.
src/Presenters/Bootstrap3/Nav.php 1 patch
Spacing   +7 added lines, -7 removed lines patch added patch discarded remove patch
@@ -9,7 +9,7 @@  discard block
 block discarded – undo
9 9
      */
10 10
     public function getOpenTagWrapper()
11 11
     {
12
-        return PHP_EOL . '<ul class="nav navmenu-nav">' . PHP_EOL;
12
+        return PHP_EOL.'<ul class="nav navmenu-nav">'.PHP_EOL;
13 13
     }
14 14
 
15 15
     /**
@@ -17,13 +17,13 @@  discard block
 block discarded – undo
17 17
      */
18 18
     public function getMenuWithDropDownWrapper($item)
19 19
     {
20
-        return '<li class="dropdown' . $this->getActiveStateOnChild($item, ' active open') . '">
20
+        return '<li class="dropdown'.$this->getActiveStateOnChild($item, ' active open').'">
21 21
 		          <a href="#" class="dropdown-toggle" data-toggle="dropdown">
22
-					' . $item->getIcon() . ' ' . $item->title . '
22
+					' . $item->getIcon().' '.$item->title.'
23 23
 			      	<b class="caret pull-right"></b>
24 24
 			      </a>
25 25
 			      <ul class="dropdown-menu navmenu-nav">
26
-			      	' . $this->getChildMenuItems($item) . '
26
+			      	' . $this->getChildMenuItems($item).'
27 27
 			      </ul>
28 28
 		      	</li>'
29 29
         . PHP_EOL;
@@ -38,13 +38,13 @@  discard block
 block discarded – undo
38 38
      */
39 39
     public function getMultiLevelDropdownWrapper($item)
40 40
     {
41
-        return '<li class="dropdown' . $this->getActiveStateOnChild($item, ' active open') . '">
41
+        return '<li class="dropdown'.$this->getActiveStateOnChild($item, ' active open').'">
42 42
 		          <a href="#" class="dropdown-toggle" data-toggle="dropdown">
43
-					' . $item->getIcon() . ' ' . $item->title . '
43
+					' . $item->getIcon().' '.$item->title.'
44 44
 			      	<b class="caret pull-right caret-right"></b>
45 45
 			      </a>
46 46
 			      <ul class="dropdown-menu navmenu-nav">
47
-			      	' . $this->getChildMenuItems($item) . '
47
+			      	' . $this->getChildMenuItems($item).'
48 48
 			      </ul>
49 49
 		      	</li>'
50 50
         . PHP_EOL;
Please login to merge, or discard this patch.
src/Presenters/Bootstrap3/NavTab.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -9,6 +9,6 @@
 block discarded – undo
9 9
      */
10 10
     public function getOpenTagWrapper()
11 11
     {
12
-        return PHP_EOL . '<ul class="nav nav-tabs">' . PHP_EOL;
12
+        return PHP_EOL.'<ul class="nav nav-tabs">'.PHP_EOL;
13 13
     }
14 14
 }
Please login to merge, or discard this patch.
src/Presenters/Bootstrap3/Sidebar.php 1 patch
Spacing   +9 added lines, -9 removed lines patch added patch discarded remove patch
@@ -35,9 +35,9 @@  discard block
 block discarded – undo
35 35
      */
36 36
     public function getMenuWithoutDropdownWrapper($item)
37 37
     {
38
-        return '<li' . $this->getActiveState($item) . '>
39
-			<a href="' . $item->getUrl() . '" ' . $item->getAttributes() . '>'
40
-        . $item->getIcon() . ' ' . $item->title . '</a></li>' . PHP_EOL;
38
+        return '<li'.$this->getActiveState($item).'>
39
+			<a href="' . $item->getUrl().'" '.$item->getAttributes().'>'
40
+        . $item->getIcon().' '.$item->title.'</a></li>'.PHP_EOL;
41 41
     }
42 42
 
43 43
     /**
@@ -74,7 +74,7 @@  discard block
 block discarded – undo
74 74
      */
75 75
     public function getHeaderWrapper($item)
76 76
     {
77
-        return '<li class="dropdown-header">' . $item->title . '</li>';
77
+        return '<li class="dropdown-header">'.$item->title.'</li>';
78 78
     }
79 79
 
80 80
     /**
@@ -85,14 +85,14 @@  discard block
 block discarded – undo
85 85
         $id = str_random();
86 86
 
87 87
         return '
88
-		<li class="' . $this->getActiveStateOnChild($item) . ' panel panel-default" id="dropdown">
89
-			<a data-toggle="collapse" href="#' . $id . '">
90
-				' . $item->getIcon() . ' ' . $item->title . ' <span class="caret"></span>
88
+		<li class="' . $this->getActiveStateOnChild($item).' panel panel-default" id="dropdown">
89
+			<a data-toggle="collapse" href="#' . $id.'">
90
+				' . $item->getIcon().' '.$item->title.' <span class="caret"></span>
91 91
 			</a>
92
-			<div id="' . $id . '" class="panel-collapse collapse ' . $this->getActiveStateOnChild($item, 'in') . '">
92
+			<div id="' . $id.'" class="panel-collapse collapse '.$this->getActiveStateOnChild($item, 'in').'">
93 93
 				<div class="panel-body">
94 94
 					<ul class="nav navbar-nav">
95
-						' . $this->getChildMenuItems($item) . '
95
+						' . $this->getChildMenuItems($item).'
96 96
 					</ul>
97 97
 				</div>
98 98
 			</div>
Please login to merge, or discard this patch.