Skip to content

Language tabs break if highlight shortcodes are not adjacent. #21030

Description

@damccorm

If adjacent \< highlight >`` shortcodes have an extra return between them, it breaks the language switcher tabs. This appears to be happening because the Markdown parser generates empty <p\> tags for the return. This doesn't happen in all circumstances. It seems to happen if the first shortcode is preceded by a text element and no return. The jQuery in language-switch-v2.js doesn't expect the `<p>` tags, and the CSS probably doesn't either.

It may be possible to fix this by removing <p\> tags. We shouldn't touch the Hugo markdown parser or builtin shortcodes.

 

 

Imported from Jira BEAM-12688. Original Jira may contain additional context.
Reported by: pcoet.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions