Skip to content
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

Ensure HTML tags are properly closed in output documents #1926

Merged
merged 2 commits into from
Jun 13, 2024
Merged

Conversation

vkbo
Copy link
Owner

@vkbo vkbo commented Jun 12, 2024

Summary:

This PR rewrites the text formatting method of the HTML converter to ensure format tags aren't opened if they are already open in a paragraph, and always closed at the end of the paragraph. Since shortcodes don't actually ensure tags are closed, unlike the Markdown tag parsing, this is necessary to prevent generating unwanted formatting in the HTML.

Related Issue(s):

Closes #1919

Reviewer's Checklist:

  • The header of all files contain a reference to the repository license
  • The overall test coverage is increased or remains the same as before
  • All tests are passing
  • All flake8 checks are passing and the style guide is followed
  • Documentation (as docstrings) is complete and understandable
  • Only files that have been actively changed are committed

@vkbo vkbo added this to the Release 2.5 RC 1 milestone Jun 12, 2024
@vkbo vkbo merged commit 3e8845a into main Jun 13, 2024
8 checks passed
@vkbo vkbo deleted the close_html_tags branch June 13, 2024 13:56
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.

Incomplete shortcodes cause issues in HTML output
1 participant