mirror of
https://github.com/jupyterhub/jupyterhub.git
synced 2025-10-15 22:13:00 +00:00
Some theme updates; no double NEXT/PREV buttons.
- Install pip in the docs conda env (or conda complains). - Do not override page.html, the next/previous buttons are now handled by alabaster_jupyterhub (this actually remove the duplicated next/prev buttons) - use alabaster_jupyterhub when building locally, this make it easy for new contributor to get the _exact_ same appearance than on readthedocs.
This commit is contained in:
@@ -4,6 +4,7 @@ name: jhub_docs
|
|||||||
channels:
|
channels:
|
||||||
- conda-forge
|
- conda-forge
|
||||||
dependencies:
|
dependencies:
|
||||||
|
- pip
|
||||||
- nodejs
|
- nodejs
|
||||||
- python=3.6
|
- python=3.6
|
||||||
- alembic
|
- alembic
|
||||||
|
@@ -1,30 +0,0 @@
|
|||||||
{% extends '!page.html' %}
|
|
||||||
|
|
||||||
{# Custom template for page.html
|
|
||||||
|
|
||||||
Alabaster theme does not provide blocks for prev/next at bottom of each page.
|
|
||||||
This is _in addition_ to the prev/next in the sidebar. The "Prev/Next" text
|
|
||||||
or symbols are handled by CSS classes in _static/custom.css
|
|
||||||
#}
|
|
||||||
|
|
||||||
{% macro prev_next(prev, next, prev_title='', next_title='') %}
|
|
||||||
{%- if prev %}
|
|
||||||
<a class='left-prev' href="{{ prev.link|e }}" title="{{ _('previous chapter')}}">{{ prev_title or prev.title }}</a>
|
|
||||||
{%- endif %}
|
|
||||||
{%- if next %}
|
|
||||||
<a class='right-next' href="{{ next.link|e }}" title="{{ _('next chapter')}}">{{ next_title or next.title }}</a>
|
|
||||||
{%- endif %}
|
|
||||||
<div style='clear:both;'></div>
|
|
||||||
{% endmacro %}
|
|
||||||
|
|
||||||
|
|
||||||
{% block body %}
|
|
||||||
<div class='prev-next-top'>
|
|
||||||
{{ prev_next(prev, next, 'Previous', 'Next') }}
|
|
||||||
</div>
|
|
||||||
|
|
||||||
{{super()}}
|
|
||||||
<div class='prev-next-bottom'>
|
|
||||||
{{ prev_next(prev, next) }}
|
|
||||||
</div>
|
|
||||||
{% endblock %}
|
|
@@ -192,9 +192,7 @@ intersphinx_mapping = {'https://docs.python.org/3/': None}
|
|||||||
# -- Read The Docs --------------------------------------------------------
|
# -- Read The Docs --------------------------------------------------------
|
||||||
|
|
||||||
on_rtd = os.environ.get('READTHEDOCS', None) == 'True'
|
on_rtd = os.environ.get('READTHEDOCS', None) == 'True'
|
||||||
if not on_rtd:
|
if on_rtd:
|
||||||
html_theme = 'alabaster'
|
|
||||||
else:
|
|
||||||
# readthedocs.org uses their theme by default, so no need to specify it
|
# readthedocs.org uses their theme by default, so no need to specify it
|
||||||
# build rest-api, since RTD doesn't run make
|
# build rest-api, since RTD doesn't run make
|
||||||
from subprocess import check_call as sh
|
from subprocess import check_call as sh
|
||||||
|
Reference in New Issue
Block a user