chiark / gitweb /
css: hint that two-column navbar should have successive numbering.
authorVladimír Vondruš <mosra@centrum.cz>
Sat, 18 Nov 2017 14:17:44 +0000 (15:17 +0100)
committerVladimír Vondruš <mosra@centrum.cz>
Sat, 18 Nov 2017 14:17:44 +0000 (15:17 +0100)
And apply that to the theme as well.

doc/css/page-layout.rst
pelican-theme/templates/base.html

index 2ff5af2fe83ce24332fd0f908bce0cb38f38df70..48cdd9552c46acdcaeb3d488e2ad89f28950e39e 100644 (file)
@@ -158,7 +158,8 @@ add a thinner subtitle.
 
 To save vertical space on small screens, it's possible to split the navbar
 contents into two (or more) columns using standard m.css
-`grid functionality <{filename}/css/grid.rst>`_:
+`grid functionality <{filename}/css/grid.rst>`_. For better accessibility,
+specify the start index on the second :html:`<ol>` element.
 
 .. code:: html
     :hl_lines: 7 8 9 10 11 12 13 14 15 16 17 18 19
@@ -177,7 +178,7 @@ contents into two (or more) columns using standard m.css
                 <li><a href="#">Showcase</a></li>
                 <li><a href="#">Download</a></li>
               </ol>
-              <ol class="m-col-t-6 m-col-m-none">
+              <ol class="m-col-t-6 m-col-m-none" start="4">
                 <li><a href="#">Blog</a></li>
                 <li><a href="#">Contact</a></li>
               </ol>
@@ -211,7 +212,7 @@ appear as an indented sub-list.
                 <li><a href="#">Showcase</a></li>
                 <li><a href="#">Download</a></li>
               </ol>
-              <ol class="m-col-t-6 m-col-m-none">
+              <ol class="m-col-t-6 m-col-m-none" start="4">
                 <li>
                   <a href="#">Blog</a>
                   <ol>
index 67dcb315946187e15db5b8e4cf0a9628a2fe60e9..4a180600be00d5fde1f46972ce8b05aff027718f 100644 (file)
@@ -45,7 +45,8 @@
             </li>
             {% endfor %}
           </ol>
-          <ol class="m-col-t-6 m-col-m-none">
+          {% set start = M_LINKS_NAVBAR1|length + 1 %}
+          <ol class="m-col-t-6 m-col-m-none" start="{{ start }}">
             {% for title, link, slug, sub in M_LINKS_NAVBAR2 %}
             <li>
               <a href="{{ link|format_siteurl }}"{% if (page and page.highlight == slug) or slug == page_slug %} id="m-navbar-current"{% endif %}>{{ title }}</a>