Skip to content

Commit

Permalink
Initial commit for Cilium theme
Browse files Browse the repository at this point in the history
This is re-design of built-in readthedocs theme,
to be more inline with cilium.io design

- Use white colors
- Use different font
- Use cilium website navigation

Signed-off-by: Sergey Generalov <[email protected]>
Signed-off-by: Alex Solovev <[email protected]>
  • Loading branch information
Alex Solovev authored and genbit committed Jun 2, 2020
1 parent 48a9c21 commit c639db2
Show file tree
Hide file tree
Showing 14 changed files with 826 additions and 508 deletions.
97 changes: 53 additions & 44 deletions docs/_templates/layout.html
Original file line number Diff line number Diff line change
Expand Up @@ -9,47 +9,56 @@
#}

{% block footer %}
{% if not READTHEDOCS %}
<div class="rst-versions" data-toggle="rst-versions" role="note" aria-label="versions">
<span class="rst-current-version" data-toggle="rst-current-version">
<span class="fa fa-book"> Read the Docs</span>
v: latest
<span class="fa fa-caret-down"></span>
</span>
<div class="rst-other-versions">
<dl>
<dt>{{ _('Versions') }}</dt>
{% if test_versions %}
{% for version in test_versions %}
<dd><a href="#">{{ version }}</a></dd>
{% endfor %}
{% else %}
<dd><a href="#">latest</a></dd>
<dd><a href="#">1.0</a></dd>
<dd><a href="#">1.1</a></dd>
{% endif %}
</dl>
<dl>
<dt>{{ _('Downloads') }}</dt>
<dd><a href="#">PDF</a></dd>
<dd><a href="#">ePub</a></dd>
<dd><a href="#">HTML</a></dd>
</dl>
<dl>
{# Translators: The phrase "Read the Docs" is not translated #}
<dt>{{ _('On Read the Docs') }}</dt>
<dd>
<a href="#">{{ _('Project Home') }}</a>
</dd>
<dd>
<a href="#">{{ _('Builds') }}</a>
</dd>
</dl>
<dl>
<dt>Debug</dt>
<dd><a href="#" data-toggle="rst-debug-badge">Swap badge position</a></dd>
</dl>
</div>
</div>
{% endif %}
{% endblock %}
{% if not READTHEDOCS %}
<div class="rst-versions" data-toggle="rst-versions" role="note" aria-label="versions">
<span class="rst-current-version" data-toggle="rst-current-version">
<span class="rst-current-version-label">Read the Docs</span>
version: latest
<span class="fa fa-caret-down"></span>
</span>
<div class="rst-other-versions">
<dl>
<dt>{{ _('Versions') }}</dt>
{% if test_versions %}
{% for version in test_versions %}
<dd><a href="#">{{ version }}</a></dd>
{% endfor %}
{% else %}
<dd><a href="#">latest</a></dd>
<dd><a href="#">1.0</a></dd>
<dd><a href="#">1.1</a></dd>
{% endif %}
</dl>
<dl>
<dt>{{ _('Downloads') }}</dt>
<dd><a href="#">PDF</a></dd>
<dd><a href="#">ePub</a></dd>
<dd><a href="#">HTML</a></dd>
</dl>
<dl>
{# Translators: The phrase "Read the Docs" is not translated #}
<dt>{{ _('On Read the Docs') }}</dt>
<dd>
<a href="#">{{ _('Project Home') }}</a>
</dd>
<dd>
<a href="#">{{ _('Builds') }}</a>
</dd>
</dl>
<!-- <dl>
<dt>Debug</dt>
<dd><a href="#" data-toggle="rst-debug-badge">Swap badge position</a></dd>
</dl> -->
<dl>
<dt>Search</dt>
<dd>
<div class="wy-side-nav-search bottom">
{% include "searchbox.html" %}
</div>
</dd>
</dl>
<small>Hosted by <a href="#">Read te Docs</a> · <a href="#">Privacy Policy</a></small>
</div>
</div>
{% endif %}
{% endblock %}
5 changes: 3 additions & 2 deletions docs/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ def is_development_build():
import sphinx_rtd_theme
from sphinx.locale import _

project = u'Read the Docs Sphinx Theme'
project = u'Cilium Docs'
slug = re.sub(r'\W+', '-', project.lower())
version = '0.5.0rc2'
release = '0.5.0rc2'
Expand All @@ -39,6 +39,7 @@ def is_development_build():
'sphinx.ext.viewcode',
'sphinxcontrib.httpdomain',
'sphinx_rtd_theme',
'sphinx_copybutton',
]

templates_path = ['_templates']
Expand Down Expand Up @@ -73,7 +74,7 @@ def is_development_build():
range(1, 100)
))

html_logo = "demo/static/logo-wordmark-light.svg"
html_logo = "demo/static/cilium-logo.svg"
html_show_sourcelink = True

htmlhelp_basename = slug
Expand Down
24 changes: 24 additions & 0 deletions docs/demo/static/cilium-logo.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
67 changes: 55 additions & 12 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@
"bourbon-neat": "~1.9",
"copy-webpack-plugin": "^5.1.1",
"css-loader": "^3.1.0",
"extract-text-webpack-plugin": "^4.0.0-beta.0",
"file-loader": "^3.0.1",
"font-awesome": "^4.7.0",
"html5shiv": "^3.7.3",
Expand Down
Loading

0 comments on commit c639db2

Please sign in to comment.