Adding documentation

This commit is contained in:
Vince Salvino 2020-02-21 18:41:46 -05:00
parent 2cec6b084b
commit 9fdc18d8de
2 changed files with 12 additions and 2 deletions

View File

@ -64,6 +64,7 @@ Other contributors, listed alphabetically, are:
* \T. Powers -- HTML output improvements * \T. Powers -- HTML output improvements
* Jeppe Pihl -- literalinclude improvements * Jeppe Pihl -- literalinclude improvements
* Rob Ruana -- napoleon extension * Rob Ruana -- napoleon extension
* Vince Salvino -- JavaScript search improvements
* Stefan Seefeld -- toctree improvements * Stefan Seefeld -- toctree improvements
* Gregory Szorc -- performance improvements * Gregory Szorc -- performance improvements
* Taku Shimizu -- epub3 builder * Taku Shimizu -- epub3 builder

View File

@ -121,6 +121,17 @@ The following blocks exist in the ``layout.html`` template:
The contents of the document itself. It contains the block "body" where the The contents of the document itself. It contains the block "body" where the
individual content is put by subtemplates like ``page.html``. individual content is put by subtemplates like ``page.html``.
.. note::
In order for the built-in JavaScript search to show a page preview on
the results page, the document or body content should be wrapped in an
HTML element containing the ``role="main"`` attribute. For example:
.. sourcecode:: html+jinja
<div role="main">
{% block document %}{% endblock %}
</div>
`sidebar1` / `sidebar2` `sidebar1` / `sidebar2`
A possible location for a sidebar. `sidebar1` appears before the document A possible location for a sidebar. `sidebar1` appears before the document
and is empty by default, `sidebar2` after the document and contains the and is empty by default, `sidebar2` after the document and contains the
@ -427,5 +438,3 @@ are in HTML form), these variables are also available:
* ``includehidden`` (``False`` by default): if true, the TOC tree will also * ``includehidden`` (``False`` by default): if true, the TOC tree will also
contain hidden entries. contain hidden entries.