Skip to content

Characters for section headings are not displaying properly in basics.html  #10154

@noahsprent

Description

@noahsprent

Describe the bug

What was I trying to do?
I wanted to know how to represent different levels of headings. On the basics page, there is a section about which characters Python's style guide recommends for representing different levels of headings in .rst.

What did I expect to happen:
In the .rst file preview on GitHub and the Python style guide page the characters that it is recommended be used for these levels appear in a box that makes it clear the following comma is not to be included.

What happened:
In the page in the sphinx docs the characters are not surrounded by a box (see screenshot). This might lead people (me) to (perhaps stupidly) assume that the comma is part of the recommendation. e.g. the headings should look like:

Subheading
-,-,-,-,-,-,-,-,-,

Rather than:

Subheading
----------------

How to Reproduce

Visit https://www.sphinx-doc.org/en/master/usage/restructuredtext/basics.html#sections

Expected behavior

No response

Your project

https://www.sphinx-doc.org/

Screenshots

Screenshot 2022-02-01 09 05 33

OS

Chrome OS Version 98.0.4758.67

Python version

Not relevant

Sphinx version

Not relevant

Sphinx extensions

No response

Extra tools

No response

Additional context

No response

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions