@@ -16,7 +16,7 @@ discard block |
||
| 16 | 16 | $request = \Drupal::request(); |
| 17 | 17 | |
| 18 | 18 | // Add language body class. |
| 19 | - $variables['attributes']['class'][] = 'lang-' . $site_language; |
|
| 19 | + $variables['attributes']['class'][] = 'lang-'.$site_language; |
|
| 20 | 20 | |
| 21 | 21 | // Classes for body element. Allows advanced theming based on context |
| 22 | 22 | $is_front_page = \Drupal::service('path.matcher')->isFrontPage(); |
@@ -30,10 +30,10 @@ discard block |
||
| 30 | 30 | $section = 'node-add'; |
| 31 | 31 | } |
| 32 | 32 | elseif (isset($arg[2]) && is_numeric($arg[1]) && ($arg[2] == 'edit' || $arg[2] == 'delete')) { |
| 33 | - $section = 'node-' . $arg[2]; |
|
| 33 | + $section = 'node-'.$arg[2]; |
|
| 34 | 34 | } |
| 35 | 35 | } |
| 36 | - $variables['attributes']['class'][] = \Drupal\Component\Utility\Html::getClass('section-' . $section); |
|
| 36 | + $variables['attributes']['class'][] = \Drupal\Component\Utility\Html::getClass('section-'.$section); |
|
| 37 | 37 | } |
| 38 | 38 | |
| 39 | 39 | // Store the menu item since it has some useful information. |
@@ -28,8 +28,7 @@ discard block |
||
| 28 | 28 | if ($arg[0] == 'node' && isset($arg[1])) { |
| 29 | 29 | if ($arg[1] == 'add') { |
| 30 | 30 | $section = 'node-add'; |
| 31 | - } |
|
| 32 | - elseif (isset($arg[2]) && is_numeric($arg[1]) && ($arg[2] == 'edit' || $arg[2] == 'delete')) { |
|
| 31 | + } elseif (isset($arg[2]) && is_numeric($arg[1]) && ($arg[2] == 'edit' || $arg[2] == 'delete')) { |
|
| 33 | 32 | $section = 'node-' . $arg[2]; |
| 34 | 33 | } |
| 35 | 34 | } |
@@ -39,8 +38,7 @@ discard block |
||
| 39 | 38 | // Store the menu item since it has some useful information. |
| 40 | 39 | if ($request->attributes->get('view_id')) { |
| 41 | 40 | $variables['attributes']['class'][] = 'views-page'; |
| 42 | - } |
|
| 43 | - elseif ($request->attributes->get('panel')) { |
|
| 41 | + } elseif ($request->attributes->get('panel')) { |
|
| 44 | 42 | $variables['attributes']['class'][] = 'panels-page'; |
| 45 | 43 | } |
| 46 | 44 | } |