MapServer / MapServer-documentation

Source repository for the MapServer documentation, for the live website. Please submit pull requests to the 'main' branch.
https://mapserver.org
Other
34 stars 69 forks source link

Add horizontal scrollbar to TOC when required #831

Closed geographika closed 1 year ago

geographika commented 1 year ago

Currently due to long constant names there are overlaps between the TOC and the content at https://mapserver.org/mapscript/mapscript-api/index.html

image

This pull request ensures a horizontal scrollbar is used (when required) to avoid this overlap.

image

I was hoping the local TOC could be modified on that page, but it does not appeat to be possible. Failed attempts included adding:

.. toctree::
   :hidden:
   :maxdepth: 2

.. contents:: Table of Contents
   :local:
   :depth: 2

And also trying to modify localtoc2.html similar to how the Read the Docs theme works with the global TOC, but this does not work with toc:

{%- if display_toc %}
  <h3>{{ _('Current Table Of Contents') }}</h3>
  {{ toc(maxdepth=2) }}
{%- endif %}
jmckenna commented 1 year ago

thanks @geographika