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

fix: refactor new line management in popups #1865

Merged
merged 1 commit into from
May 29, 2024
Merged

Conversation

yohanboniface
Copy link
Member

Basically, we do not add <br> anymore, but instead let the newline and use the css white-space: pre-line;. Also remove new lines after title.

While doing that change, I needed to reorder regex so the ones needing a newline before would still have it (bullets points).

I've added tests and removed some to cover those changes.

fix #1854

Basically, we do not add `<br>` anymore, but instead let the newline
and use the css `white-space: pre-line;`. Also remove new lines after
title.

While doing that change, I needed to reorder regex so the ones needing
a newline before would still have it (bullets points).

I've added tests and removed some to cover those changes.

fix #1854
Copy link
Contributor

@davidbgk davidbgk left a comment

Choose a reason for hiding this comment

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

Why don't we use a regular markdown parser? Newlines should generate HTML paragraphs to be consistent?

@yohanboniface yohanboniface merged commit 442928f into master May 29, 2024
3 of 4 checks passed
@yohanboniface yohanboniface deleted the popup-newlines branch May 29, 2024 18:03
@yohanboniface
Copy link
Member Author

Moving to markdown is clearly an option at some point, but at this stage our syntax is not compatible with Markdown, it's a Yoyodown thing :p

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.

Caption popup: too much spacing when using the # markup.
2 participants