-
Notifications
You must be signed in to change notification settings - Fork 247
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
Line breaks not displaying in details section of alert details page #3338
Comments
Details are processed as markdown text, of which the default behavior is to join subsequent lines unless there is a blank line separating. I agree this is a bit confusing, especially because details are often sent as text without markdown processing. Testing it here on GitHub, it seems single-line breaks are also preserved. @Forfold any idea if the markdown library we use has an option for this? |
The weird thing is that if you look in page source, the line breaks are preserved, just not converted from \n to |
Looks like we can use https://github.com/remarkjs/remark-breaks as a plugin to However:
|
In our case, it's warranted -- since details are communicated in messages as rendered markdown and unrendered text -- it makes sense to keep them closer together. Plus, not all inputs to alerts are aware/capable of providing markdown anyway, so many alerts are just raw text when they come in. IMO that plugin makes a lot of sense for the UI. |
Describe the Bug:
The details section of an alert displays the details text with line breaks stripped.
Steps to Reproduce:
Expected Behavior:
The details section should have multiple lines
Observed Behavior:
The details section displays all of the text on one line.
Screenshots/Stack Traces:
GoAlert Interface:
Pushover:
Application Version:
v0.31.1
Additional Context:
It appears that GoAlert is just not converting line breaks (\n) into HTML
<br>
tags.The text was updated successfully, but these errors were encountered: