Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update master #21

Draft
wants to merge 10 commits into
base: master
Choose a base branch
from
4 changes: 2 additions & 2 deletions conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@
# coming with Sphinx (named 'sphinx.ext.*') or your custom ones.
extensions = [
"sphinx.ext.mathjax",
"recommonmark",
"myst_parser",
"sphinx.ext.intersphinx",
] + runestone_extensions()

Expand Down Expand Up @@ -322,7 +322,7 @@
# It True, sets js files from Sphinx & Runestone to be loaded with defer attr
# substantially speeding up page rendering. May cause issues with books that
# have custom directives or raw html that assume jquery or another library
# is loaded before body is parsed.
# is loaded before body is parsed.
html_defer_js = True

# Output file base name for HTML help builder.
Expand Down
3 changes: 2 additions & 1 deletion requirements-dev.in
Original file line number Diff line number Diff line change
Expand Up @@ -8,4 +8,5 @@ selenium>=2.53.6
pyvirtualdisplay
pytest
pylint
readme-renderer>24
readme-renderer>24
myst_parser
41 changes: 33 additions & 8 deletions requirements-dev.txt
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,12 @@ alabaster==0.7.12
# via sphinx
astroid==2.5.6
# via pylint
attrs==20.3.0
atomicwrites==1.4.0
# via pytest
attrs==21.2.0
# via
# markdown-it-py
# pytest
babel==2.9.1
# via sphinx
bleach==3.3.0
Expand All @@ -27,10 +31,16 @@ codechat==1.8.6
cogapp==3.0.0
# via -r requirements.in
colorama==0.4.4
# via twine
# via
# pylint
# pytest
# sphinx
# tqdm
# twine
docutils==0.16
# via
# codechat
# myst-parser
# readme-renderer
# sphinx
easyprocess==0.3
Expand All @@ -49,19 +59,29 @@ iniconfig==1.1.1
# via pytest
isort==5.8.0
# via pylint
jinja2==2.11.3
# via sphinx
jinja2==3.0.1
# via
# myst-parser
# sphinx
keyring==23.0.1
# via twine
lazy-object-proxy==1.6.0
# via astroid
lxml==4.6.3
# via codechat
markupsafe==1.1.1
markdown-it-py==1.1.0
# via
# mdit-py-plugins
# myst-parser
markupsafe==2.0.1
# via jinja2
mccabe==0.6.1
# via pylint
packaging==20.9
mdit-py-plugins==0.2.8
# via myst-parser
myst-parser==0.15.1
# via -r requirements-dev.in
packaging==21.0
# via
# bleach
# pytest
Expand Down Expand Up @@ -95,18 +115,22 @@ pytz==2021.1
# via babel
pyvirtualdisplay==2.1
# via -r requirements-dev.in
pywin32-ctypes==0.2.0
# via keyring
pyyaml==5.4.1
# via myst-parser
readme-renderer==29.0
# via
# -r requirements-dev.in
# twine
requests-toolbelt==0.9.1
# via twine
requests==2.25.1
requests==2.26.0
# via
# requests-toolbelt
# sphinx
# twine
rfc3986==1.4.0
rfc3986==1.5.0
# via twine
selenium==3.141.0
# via -r requirements-dev.in
Expand All @@ -121,6 +145,7 @@ snowballstemmer==2.1.0
sphinx==3.5.4
# via
# -r requirements.in
# myst-parser
# sphinxcontrib-paverutils
sphinxcontrib-applehelp==1.0.2
# via sphinx
Expand Down
2 changes: 1 addition & 1 deletion requirements.in
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# *********
# |docname|
# *********
click
click<8.0
Paver>=1.2.4
six>1.12
Sphinx>=2.0.0
Expand Down
2 changes: 1 addition & 1 deletion requirements.txt
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ certifi==2020.12.5
# via requests
chardet==4.0.0
# via requests
click==7.1.2
click<8.0
# via -r requirements.in
codechat==1.8.6
# via -r requirements.in
Expand Down
38 changes: 23 additions & 15 deletions runestone/common/css/runestone-custom-sphinx-bootstrap.css
Original file line number Diff line number Diff line change
Expand Up @@ -661,6 +661,20 @@ div.flash {
position: fixed;
}

.navLink:hover {
opacity: 1;
}

.navLink a {
display: inline-block;
background-color: white;
border-style:solid;
border-color:lightgrey;
border-width:2px;
width:100px;
height:50px
}

#relations-next {
right: 35px;
}
Expand All @@ -669,28 +683,22 @@ div.flash {
left: 35px;
}

@media (max-width: 600px) {
.nextprev-list {
margin: 10px;
padding-left: 0;
height: 50px;
}

/* Styling definitions for chevron function in bookfuncs.js */
@media (max-width: 600px) {

.navLink {
z-index: 2;
display: inline;
position: static;
}

ul#top-relations-console,
ul#bottom-relations-console {
list-style: none;
text-align: center;
width: 100%;
margin: 0 auto;
padding: 40px 0 20px 0;
}

#top-relations-next,
#top-relations-prev,
#bottom-relations-next,
#bottom-relations-prev {
#relations-next,
#relations-prev {
width: 25%;
padding: 0 20px;
display: inline;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -289,6 +289,7 @@
<div class="container" id="continue-reading"></div>

<div class="container" id="main-content" role="main">

<!-- Ad Serving for Runestone Campaign -->
{% if dynamic_pages == 'True' %}
{% raw %}
Expand All @@ -310,9 +311,9 @@
<div id=scprogresscontainer>
You have attempted <span id=scprogresstotal></span> of <span id=scprogressposs></span> activities on this page <div id="subchapterprogress"></div>
</div>
{% block nextprevious %}
{% include "subchapter.html" %}
{% endblock %}

{% include "subchapter.html" %}

</div>
{%- endblock %}

Expand Down
Original file line number Diff line number Diff line change
@@ -1,33 +1,26 @@
<ul role="navigation" class="nextprev-list nextprev-list" aria-label="Change page">
{%- if prev %}
<ul>
<li id="relations-prev" style="opacity:0.4" onmouseover="mouseOverPrev()" onmouseout="mouseOutPrev()"class="navLink" title='Previous Section - {{ prev.title|extractText|extractTextII }}' data-toggle="tooltip">
<a href="{{ prev.link|e }}" aria-label="{{ prev.title|extractText|extractTextII }}">
<div style="background-color: white; border-style:solid; border-color:lightgrey; border-width:2px; width:100px; height:50px">
<i class='prevNav glyphicon glyphicon-chevron-left' style="top:50%; transform:translateY(-50%)translateX(-50%); left: 50%; color:black;"></i>
</div>
</a>
</li>
</ul>

{% endif %}
<li id="relations-prev" class="navLink" title='Previous Section - {{ prev.title|extractText|extractTextII }}' data-toggle="tooltip">
<a href="{{ prev.link|e }}" aria-label="Previous - {{ prev.title|extractText|extractTextII }}">
<i class='prevNav glyphicon glyphicon-chevron-left' style="top:50%; transform:translateY(-50%)translateX(-50%); left: 50%; color:black;"></i>
</a>
</li>
{% endif %}

{%- if next %}
<ul>
<li id="relations-next" style="opacity:0.4" onmouseover="mouseOverNext()" onmouseout="mouseOutNext()" class="navLink" title='Next Section - {{ next.title|extractText|extractTextII }}' data-toggle="tooltip" >
<a href="{{ next.link|e }}" aria-label="{{ next.title|extractText|extractTextII }}">
<div style="background-color: white; border-style:solid; border-color:lightgrey; border-width:2px; width:100px; height:50px">
<i id="relationsNextIcon" class='nextNav glyphicon glyphicon-chevron-right' style="top:50%; transform:translateY(-50%)translateX(-50%); left: 50%; color:black; "></i>
</div>
<li id="relations-next" class="navLink" title='Next Section - {{ next.title|extractText|extractTextII }}' data-toggle="tooltip" >
<a href="{{ next.link|e }}" aria-label="Next - {{ next.title|extractText|extractTextII }}">
<i id="relationsNextIcon" class='nextNav glyphicon glyphicon-chevron-right' style="top:50%; transform:translateY(-50%)translateX(-50%); left: 50%; color:black; "></i>
</a>
</li>
</ul>

{%- endif %}

<script>
document.addEventListener('load', (event) => {
$('#relations-prev').tooltip({'placement':'right', 'selector': '', 'delay': { show: 100, hide: 50}});
$('#relations-next').tooltip({'placement':'left', 'selector': '', 'delay': { show: 100, hide: 50}});
window.addEventListener('load', (event) => {
$('#relations-prev').tooltip({'placement': 'right', 'delay': { show: 100, hide: 50}});
$('#relations-next').tooltip({'placement': 'left', 'delay': { show: 100, hide: 50}});
});
</script>

Expand Down