src/CorporateTrainingBundle/Resources/views/homepage/component/navigation/content.html.twig line 1

Open in your IDE?
  1. {% if app.request.headers.get('WEB-VIEW-ACCESS') == null %}
  2. {% set rules = {num: 7}|merge(draft.rules|default([])) %}
  3. <header class="es-header 
  4.   {% if app.request.requestUri in ['' ,'/', path('admin_homepage_decorate'), path('admin_homepage_preview'), path('admin_homepage_component_create', {code: 'navigation'})] %}
  5.   o-home-sec-navbar
  6.   {% endif %} navbar">
  7.   <div class="header-content">
  8.     <div class="header-left">
  9.       <a class="text-37393D text-18" href="{{ editing ? 'javascript:;' : path('homepage') }}">
  10.         {% if setting('site.logo') %}
  11.           <img style="height: 46px;" src="{{ filepath('../' ~ setting('site.logo'), '') }}">
  12.         {% else %}
  13.           {{ setting('site.name', 'EDUSOHO') }}
  14.         {% endif %}
  15.       </a>
  16.       <nav class="header-nav">
  17.         {% if app.user %}
  18.           <ul class="nav navbar-nav hidden-xs" id="nav">
  19.             {% include '@CorporateTraining/homepage/component/navigation/nav.html.twig' with {rules:rules} %}
  20.           </ul>
  21.         {% endif %}
  22.       </nav>
  23.     </div>
  24.     {% include '@CorporateTraining/homepage/component/navigation/user-operation.html.twig' %}
  25.   </div>
  26.   {% include '@CorporateTraining/admin/homepage/component/widgets/action.html.twig' %}
  27. </header>
  28. {% endif %}
  29. <style>
  30. .header-content {
  31.   display: flex;
  32.   justify-content: space-between;
  33.   align-items: center;
  34.   height: 72px;
  35. }
  36. .header-content .header-left {
  37.   display: flex;
  38.   align-items: center;
  39. }
  40. .header-content .header-nav {
  41.   display: inline-block;
  42. }
  43. .header-content .header-nav .nav,
  44. .header-content .header-nav .nav > li {
  45.   display: inline-block;
  46.   float: none;
  47. }
  48. .header-content .header-nav .nav > li.nav-more {
  49.   height: initial;
  50. }
  51. .header-content .header-nav .nav > li > a {
  52.   padding: 0 !important;
  53.   margin-left: 24px;
  54. }
  55. </style>