mirror of https://github.com/docker/docs.git
Remove 'edit this page' button when there's no source file
This commit is contained in:
parent
6dc089e6f0
commit
d3be283007
|
@ -13,16 +13,16 @@
|
|||
{% endif %}
|
||||
{% endfor %}
|
||||
{% endif %}
|
||||
<!-- edit overrides -->
|
||||
{% for override in site.data.not_edited_here.overrides %}
|
||||
{% if page.url contains override.path %}
|
||||
{% assign overridden="true" %}
|
||||
{% capture editsource %}{{ override.source }}{{ page.path }}{% endcapture %}
|
||||
{% break %}
|
||||
{% endif %}
|
||||
<!-- Logic for 'edit this button' -->
|
||||
{% assign edit_url = "https://github.com/docker/docker.github.io/edit/master/" | append: page.path %}
|
||||
{% for entry in site.data.not_edited_here.overrides %}
|
||||
{% if page.url contains entry.path %}
|
||||
{% if entry.source %}{% assign edit_url = entry.source %}{% else %}{% assign edit_url = "" %}{% endif %}
|
||||
{% break %}
|
||||
{% endif %}
|
||||
{% endfor %}
|
||||
{% if overridden != "true" %}{% capture editsource %}https://github.com/docker/docker.github.io/edit/master/{{ page.path }}{% endcapture %}{% endif %}
|
||||
<!-- Start of {{ page.path }} -->
|
||||
|
||||
<!-- End of logic for 'edit this button' -->
|
||||
<!DOCTYPE html>
|
||||
<html class="js flexbox flexboxlegacy canvas canvastext webgl no-touch geolocation postmessage websqldatabase indexeddb hashchange history draganddrop websockets rgba hsla multiplebgs backgroundsize borderimage borderradius boxshadow textshadow opacity cssanimations csscolumns cssgradients cssreflections csstransforms no-csstransforms3d csstransitions fontface no-generatedcontent video audio localstorage sessionstorage webworkers applicationcache svg inlinesvg smil svgclippaths retina-display is_not_retina chrome version webkit" lang="en">
|
||||
<head>
|
||||
|
@ -211,7 +211,9 @@ ng\:form {
|
|||
<div style="text-align: center; margin-top: 50px">
|
||||
<img src="/images/chat.png" alt="chat icon" style="margin-right: 10px">
|
||||
<b>Feedback?</b> Suggestions? Can't find something in the docs?<br/>
|
||||
<a href="https://github.com/docker/docker.github.io/edit/master/{{ page.path }}" class="nomunge">Edit this page</a> <span style="color:#D8E0E0">●</span>
|
||||
{% if edit_url != "" %}
|
||||
<a href="https://github.com/docker/docker.github.io/edit/master/{{ page.path }}" class="nomunge">Edit this page</a> <span style="color:#D8E0E0">●</span>
|
||||
{% endif %}
|
||||
<a href="https://github.com/docker/docker.github.io/issues/new?title=Feedback for: {{ page.path }}&assignee={% if page.assignee %}{{ page.assignee }}{% else %}{{ page.defaultassignee }}{% endif %}&body=File: [{{ page.path }}](https://docs.docker.com{{ page.url }})" class="nomunge">Request docs changes</a> <span style="color:#D8E0E0">●</span> <a href="https://www.docker.com/docker-support-services">Get support</a> <br />Rate this page:
|
||||
<div id="pd_rating_holder_8453675"></div>
|
||||
<script type="text/javascript">
|
||||
|
@ -262,7 +264,9 @@ ng\:form {
|
|||
<button type="submit" class="search-submit btn btn-default">Search</button>
|
||||
</form>
|
||||
</span>
|
||||
<span><a href="{{ editsource }}" class="button darkblue-btn nomunge" style="color:#FFFFFF; width:100%; margin: 0px;">Edit This Page</a></span>
|
||||
{% if edit_url != "" %}
|
||||
<span><a href="{{ edit_url }}" class="button darkblue-btn nomunge" style="color:#FFFFFF; width:100%; margin: 0px;">Edit This Page</a></span>
|
||||
{% endif %}
|
||||
<nav id="TableOfContents">
|
||||
</nav>
|
||||
</section>
|
||||
|
|
Loading…
Reference in New Issue