Welcome to mirror list, hosted at ThFree Co, Russian Federation.

header.html « layouts - gitlab.com/gitlab-org/gitlab-docs.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
blob: 57d45c51bcb911281835cb4381326b0b7104504f (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
<div class="header">
  <div class="flex-container align-center">
    <a class="header-link logo-container flex-container justify-center align-center" href="/">
      <img src="<%= @items['/assets/images/gitlab-logo.svg'].path %>" class="logo" />
      <p>GitLab <strong>Docs</strong></p>
    </a>
    <% unless @item.identifier.to_s.split('/')[1] == 'search' %>
    <form id="search-form" action="/search/" method="get">
      <input type="text" name="q" class="docsearch" placeholder="Search" required/>
      <input type="submit" style="visibility: hidden; position:absolute;" />
    </form>
    <% end %>
  </div>
  <div class="nav-container">
    <a class="nav-toggle" id="docs-nav-toggle">
      <i class="fa fa-bars" aria-hidden="true"></i>
    </a>
    <ul class="nav">
      <% unless @item.identifier.to_s.split('/')[1] == 'search' %>
      <li class="nav-item">
        <form id="mobile-search-form" action="/mobileSearch/" method="get">
          <input type="text" name="q" class="docsearch docsearch-mobile" placeholder="Search" required/>
          <input type="submit" style="visibility: hidden; position:absolute;" />
        </form>
      </li>
      <% end %>
      <% if ENV['NANOC_ENV'] == 'production' %>
        <% @config[:products].each do |name, product| %>
          <% if product[:expose] == true %>
            <li class="nav-item">
              <a href="<%= @items["/#{product[:slug]}/#{product[:index_file]}"].path %>">
                <%= product[:short_name] %>
              </a>
            </li>
          <% end %>
        <% end %>
      <% else %>
        <% @config[:products].each do |name, product| %>
          <% if Dir.exist?("#{@config[:content_dir]}/#{product[:slug]}")%>
            <li class="nav-item">
              <a href="<%= @items["/#{product[:slug]}/#{product[:index_file]}"].path %>">
                <%= product[:short_name] %>
              </a>
            </li>
          <% end %>
        <% end %>
      <% end %>
    </ul>
  </div>
</div>