Better accessibility

This commit is contained in:
Kujiu 2023-09-27 18:09:22 +02:00
parent 988f1af97e
commit 80d7f88c14
Signed by: kujiu
GPG key ID: ABBB2CAC6855599F
10 changed files with 39 additions and 32 deletions

View file

@ -2,6 +2,11 @@
Changes Changes
======= =======
3.0.2 (*2023-09-27*)
====================
- Improve accessibility
3.0.1 (*2023-08-17*) 3.0.1 (*2023-08-17*)
==================== ====================

View file

@ -4,7 +4,7 @@ build-backend = "flit_core.buildapi"
[project] [project]
name = "sphinx_nervproject_theme" name = "sphinx_nervproject_theme"
version = "3.0.1" version = "3.0.2"
requires-python = ">=3.8" requires-python = ">=3.8"
dependencies = [ dependencies = [
"Sphinx>=7.0.0", "Sphinx>=7.0.0",

View file

@ -83,30 +83,8 @@
{%- block header %}{%- include "util/navbar.html" %}{% endblock %} {%- block header %}{%- include "util/navbar.html" %}{% endblock %}
<div id="appflex"> <div id="appflex">
{%- block sidebar %}
{% if builder=='html' %}
<div class="sidebar" id="sidebar">
{# sidebar navlinks displayed only on mobile #}
<nav class="nav-links can-hide">
{% block side_links %}
{%- include "util/navlinks.html" %}
{%- include "util/extlinks.html" %}
{% endblock %}
</nav>
{%- if sidebars != None %}
{%- for sidebartemplate in sidebars %}
{%- include sidebartemplate %}
{%- endfor %}
{%- endif %}
</div>
{% endif %}
{%- endblock %}
<div class="page"> <div class="page">
{%- block document %} {%- block document %}
{% block body_header %}
{%- include "util/bodyheader.html" %}
{%- endblock body_header %}
<main class="content"> <main class="content">
{% block body %} {% endblock %} {% block body %} {% endblock %}
{% if builder=='html' %} {% if builder=='html' %}
@ -141,9 +119,31 @@
</div> </div>
{% endif %} {% endif %}
</main> </main>
{% block body_header %}
{%- include "util/bodyheader.html" %}
{%- endblock body_header %}
{%- endblock %} {%- endblock %}
{%- include "util/pagenav.html" %} {%- include "util/pagenav.html" %}
</div> </div>
{%- block sidebar %}
{% if builder=='html' %}
<div class="sidebar" id="sidebar">
{# sidebar navlinks displayed only on mobile #}
<nav class="nav-links can-hide">
{% block side_links %}
{%- include "util/navlinks.html" %}
{%- include "util/extlinks.html" %}
{% endblock %}
</nav>
{%- if sidebars != None %}
{%- for sidebartemplate in sidebars %}
{%- include sidebartemplate %}
{%- endfor %}
{%- endif %}
</div>
{% endif %}
{%- endblock %}
</div> </div>

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View file

@ -151,6 +151,7 @@ body {
flex-grow: 1; flex-grow: 1;
.page { .page {
order: 5;
width: 100%; width: 100%;
} }
} }
@ -182,7 +183,7 @@ body {
a, a:visited { a, a:visited {
font-weight: 500; font-weight: 500;
color: @AClr; color: @AClr;
text-decoration: none; text-decoration: underline;
} }
p a code, p a:visited code { p a code, p a:visited code {
@ -254,6 +255,7 @@ a.header-anchor, a:visited.header-anchor {
padding-right: 0.23em; padding-right: 0.23em;
margin-top: 0.125em; margin-top: 0.125em;
opacity: 0; opacity: 0;
text-decoration: none;
&:hover { &:hover {
text-decoration: none; text-decoration: none;
} }
@ -808,7 +810,7 @@ ul.ablog-cloud li {
} }
ul.ablog-cloud a, ul.ablog-cloud a:visited { ul.ablog-cloud a, ul.ablog-cloud a:visited {
text-decoration: none; text-decoration: underline;
vertical-align: middle; vertical-align: middle;
} }

View file

@ -1,6 +1,6 @@
// responsive breakpoints // responsive breakpoints
@MQNarrow: 95ex; @MQNarrow: 150ex;
@MQMobile: 72ex; @MQMobile: 92ex;
@MQMobileNarrow: 42ex; @MQMobileNarrow: 42ex;
// Print header and footer // Print header and footer