diff options
author | Achilleas Pipinellis <axil@gitlab.com> | 2018-10-15 13:57:02 +0300 |
---|---|---|
committer | Achilleas Pipinellis <axil@gitlab.com> | 2018-10-15 13:57:02 +0300 |
commit | d3c64e46706006d9853a8bb79c01ae0b99c11b20 (patch) | |
tree | 0e35fbc03b6537df07c92b9f0118be0fc922dca7 /layouts | |
parent | e15209f6db9fb54e51100d6625c52dd7d6f3d27b (diff) | |
parent | 845bc5d2e7d63a2d2000a240a5ac463ca6f0678e (diff) |
Merge branch 'master' into 'improve-versions-menu'
# Conflicts:
# layouts/header.html
Diffstat (limited to 'layouts')
-rw-r--r-- | layouts/head.html | 3 | ||||
-rw-r--r-- | layouts/header.html | 19 |
2 files changed, 16 insertions, 6 deletions
diff --git a/layouts/head.html b/layouts/head.html index 63291657..e99be97c 100644 --- a/layouts/head.html +++ b/layouts/head.html @@ -10,6 +10,9 @@ <meta name="description" content="Documentation for GitLab Community Edition, GitLab Enterprise Edition, Omnibus GitLab, and GitLab Runner."> <% end %> <meta name="viewport" content="width=device-width, initial-scale=1, user-scalable=no"> +<% if @item[:noindex] %> + <meta name="robots" content="noindex nofollow"> +<% end %> <link rel="stylesheet" href="<%= @items['/assets/stylesheets/bootstrap.min.*'].path %>"> <link rel="stylesheet" href="<%= @items['/assets/stylesheets/stylesheet.*'].path %>"> <link rel="stylesheet" href="<%= @items['/assets/stylesheets/highlight.*'].path %>"> diff --git a/layouts/header.html b/layouts/header.html index b510913c..a039c8af 100644 --- a/layouts/header.html +++ b/layouts/header.html @@ -18,21 +18,28 @@ </a> <ul class="dropdown-menu versions-menu" aria-labelledby="versions"> <li> - <a href='/' class="versions-tooltip">master + <a href='<%= @item.identifier.without_ext + '.html' %>' class="versions-tooltip">master</a> <i class="fa fa-question-circle-o" aria-hidden="true" data-toggle="tooltip" data-placement="bottom" title="The latest docs from GitLab's master branches, to which this site defaults."></i> </a> </li> <li role="separator" class="divider"></li> - <li><a href='/<%= @items['/_data/versions.yaml'][:current].first %>/'> - <%= @items['/_data/versions.yaml'][:current].first %></a> + <li> + <a href='/<%= @items['/_data/versions.yaml'][:current].first %><%= @item.identifier.without_ext + '.html' %>'> + <%= @items['/_data/versions.yaml'][:current].first %> + </a> </li> - <% @items['/_data/versions.yaml'][:previous].each do |version| %> - <li><a href='/<%= version %>/'><%= version %></a></li> - <% end %> + <% @items['/_data/versions.yaml'][:previous].each do |version| %> + <li> + <a href='/<%= version %><%= @item.identifier.without_ext + '.html' %>'> + <%= version %> + </a> + </li> + <% end %> <li role="separator" class="divider"></li> <li><a href='/archives/'>Archives</a></li> </ul> </div> + <!-- versions dropdown--> </div> <div class="nav-container"> <a class="nav-toggle" id="docs-nav-toggle"> |