8000 List markers overlap margin of inline elements · Issue #2554 · squidfunk/mkdocs-material · GitHub
[go: up one dir, main page]

Skip to content

List markers overlap margin of inline elements #2554

@ghost

Description

I've found a bug and checked that ...

  • ... the problem doesn't occur with the default MkDocs template
  • ... the problem is not in any of my customizations (CSS, JS, template)
  • ... the documentation does not mention anything about my problem
  • ... there are no open or closed issues that are related to my problem

Description

When you add an inline admonition followed by a list (ordered or not), the list markers (numbers or bullets) are not affected by the margin of the admonition. Instead, it only applies to the <li> element.

I am pretty sure that this bug was introduced with 7.1.1 release, since I downgraded mkdocs-material to 7.1.0 and it was still fine. Users of the product I write docs for noticed the issue, and it turned out that the deployed version used 7.1.1 whereas the version in my Docker environment was still in 7.1.0.

The page that was affected also had some inline pictures, which used the .inline CSS class, so they were also affected by this bug.

Expected behavior

From local 7.1.0

image
image

Actual behavior

From deployed 7.1.1

image
image

Steps to reproduce the bug

  1. Upgrade to 7.1.1.
  2. Use a set-up like the one below.
  3. Serve the site, the bug exists.
  4. Downgrade to 7.1.0.
  5. Serve the site, the bug no longer exists.
!!! info inline "Inline admonition"
    This is some text.

- This is a list.
- This is a list.
- This is a list.
- This is a list.

Package versions

  • Python: 3.9.1
  • MkDocs: 1.1.2
  • Material: 7.1.0 (unaffected), 7.1.1 (affected)

System information

  • OS: Windows 21H1
  • Browser: Microsoft Edge (reported from Firefox too)

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugIssue reports a bugresolvedIssue is resolved, yet unreleased if open

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      0