Skip to content

fix: unwrap <p> tags around <a> in top-level sidebar items #2577

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 3 commits into
base: develop
Choose a base branch
from

Conversation

sy-records
Copy link
Member

Summary

There are some issues with clicking on awesome and changelog. https://preview.docsifyjs.org/#/awesome

The solution is to remove the p tag from the top level <li><p><a></a></p></li>.

Related issue, if any:

What kind of change does this PR introduce?

Bugfix

For any code change,

  • Related documentation has been updated, if needed
  • Related tests have been added or updated, if needed

Does this PR introduce a breaking change?

Yes

Tested in the following browsers:

  • Chrome
  • Firefox
  • Safari
  • Edge

Copy link

vercel bot commented Jul 24, 2025

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
docsify-preview ✅ Ready (Inspect) Visit Preview 💬 Add feedback Jul 24, 2025 6:03am

Copy link
Member

@Koooooo-7 Koooooo-7 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think the root cause may be the styling since the display:none apply to all the non a elements.
As a single line in _sidebar.md , which does't as a group but a link, we need reconsider how to structure the sidebar and refine the css selector.

&.collapse {
      > :not(a) {
        display: none;
      }
    }

cc @jhildenbiddle

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants