Commit 1e2abd81 authored by Abdullah Yassin's avatar Abdullah Yassin
Browse files

Issue #3300175: Replace margin bottom with padding bottom on header in page.twig

parent d0c525cd
Loading
Loading
Loading
Loading
+4 −1
Original line number Diff line number Diff line
@@ -2,7 +2,10 @@
/**
 * @file
 * Template for the main page.
 * Available config:
 *  - is_front: true | false -> to determine if page is front or not
 */

#}
<div class="page">
  {% embed '@organisms/navbar/navbar.twig' with {
@@ -36,7 +39,7 @@
  {% endembed %}

  {% if page.header %}
    <header class="page__header mb-3">
    <header class="page__header {{ is_front ? '' : 'pb-3' }}">
      <div class="container">
        {{ page.header }}
      </div>
+11 −3
Original line number Diff line number Diff line
@@ -21,7 +21,6 @@ function vartheme_bs5_preprocess_html(&$variables) {

  // The path for Vartheme BS5 theme in variables.
  $variables['vartheme_bs5_path'] = \Drupal::request()->getBaseUrl() . '/' . \Drupal::service('extension.list.theme')->getPath('vartheme_bs5');

}

/**
@@ -67,7 +66,6 @@ function vartheme_bs5_theme_registry_alter(&$theme_registry) {
  foreach ($pages as $key => $template) {
    $theme_registry[$key]['path'] = $vartheme_bs5_path . '/templates/betterlogin';
  }

}

/**
@@ -104,3 +102,13 @@ function vartheme_bs5_preprocess_login_with(&$variables) {
    }
  }
}

/**
 * Implements hook_preprocess_region().
 */
function vartheme_bs5_preprocess_region(&$variables) {
  $isFront = \Drupal::service('path.matcher')->isFrontPage();
  if ($isFront && $variables["region"] === "header") {
    $variables["is_front"] = $isFront;
  }
}