Fix new line not shown in html citation#753
Merged
shinyichen merged 1 commit intoadsabs:masterfrom Jan 12, 2026
Merged
Conversation
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## master #753 +/- ##
========================================
+ Coverage 71.6% 71.8% +0.3%
========================================
Files 218 217 -1
Lines 24584 24480 -104
Branches 1402 1403 +1
========================================
- Hits 17582 17564 -18
+ Misses 6970 6884 -86
Partials 32 32
🚀 New features to boost your workflow:
|
fa7b640 to
4d82fb2
Compare
thostetler
approved these changes
Jan 7, 2026
Member
thostetler
left a comment
There was a problem hiding this comment.
Looks good to me -- small suggestion to make it a little more complete when handling the new lines
Comment on lines
+14
to
+17
| const replaceNewLineWithHtml = (html: string) => { | ||
| return html.replaceAll('\n', '<br/>'); | ||
| }; | ||
|
|
Member
There was a problem hiding this comment.
Suggested change
| const replaceNewLineWithHtml = (html: string) => { | |
| return html.replaceAll('\n', '<br/>'); | |
| }; | |
| const replaceNewLineWithHtml = (html: string) => { | |
| return html?.replace(/\r\n|\r|\n/g, '<br/>'); | |
| }; | |
Just to be more complete. In case there were windows style line-endings
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Citation in HTML format uses
\nas new line, and should be converted to html tag<br/>to be rendered correctly.