question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

[BUG(UI)]: Permalink wrapping disrupts typography

See original GitHub issue
  • I’ve read the [contribution guidelines][1] and agree with them

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

Technically this might be more of a MkDocs upstream issue, but I’m rather certain the active maintainer there would reject resolving it (based on past threads I’ve seen their involvement in at least, he would defer it to theme maintainers instead).

Github handles this by floating the symbol to the left (which is a bit more consistent in location predictability tbh). They use the following CSS:

float: left;
padding-right: 4px;
margin-left: -20px;

Perhaps supporting that by default isn’t desirable without a breaking change release. I’m also aware that you might just suggest I add custom CSS to maintain this myself and close the issue. I’m just sharing this UX issue for the benefit of others since it’s obviously not a desirable side-effect to encounter.

Expected behavior

Ideally would look like this:

_expected

This requires the permalink symbol to not contribute to the width which would collapse.

Actual behavior

Permalink is wrapped to a new line introducing a large blank space, inconsistent with typography of other headings:

_actual

Steps to reproduce the bug

  1. Enable toc.permalink.
  2. Have a heading that is roughly the width of the document containers width.
  3. Notice that visually there’s a big blank line, inconsistent with other headers.
  4. Mouse over and realize it’s a hidden permalink symbol.

Package versions

Current Docker image release (7.x)

Project configuration

Standard instance should do the trick, this is an internal bug. Using the toc.permalink extension/feature:

markdown_extensions:
  - toc:
      permalink: ⚓︎

System information

Manjaro Linux with Firefox. Present with Docker container build.

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Comments:7 (7 by maintainers)

github_iconTop GitHub Comments

1reaction
squidfunkcommented, Mar 1, 2021

Yes, I meant anchorlink. I’m sorry, I was answering from my mobile.

1reaction
squidfunkcommented, Mar 1, 2021

You can use the headerlink option: https://python-markdown.github.io/extensions/toc/

Read more comments on GitHub >

github_iconTop Results From Across the Web

How to hide the overflow content in material ui table cell ...
The current behavior is that it wraps text inside the cell. I tried adding CSS styles but to no avail. How do I...
Read more >
Troubleshooting the Flex UI - Twilio
Users will see a notification informing them of a possible disruption in the normal work of Flex UI and they will be able...
Read more >
Inspired Design Decisions With Otto Storch: When Idea, Copy ...
I loved the way its designer has playfully combined images and typography to create a design which was full of energy and movement....
Read more >
Bug listing with status UNCONFIRMED as at 2022/12/24 17 ...
Compiler wrapper to enable security hardening flags" status:UNCONFIRMED resolution: ... Bug:449666 - "URL formating issues" status:UNCONFIRMED resolution: ...
Read more >
Option to Disable Smart Links For Non-Atlassian Products in ...
The latest ui update made this even worse, the url does not show at all now. ... Might as well fix a bug...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found