Skip to content

#1486 fix newline items in lists#1487

Merged
blikblum merged 5 commits intofoliojs:masterfrom
filecage:#1486-fix-newline-items-in-lists
Dec 22, 2023
Merged

#1486 fix newline items in lists#1487
blikblum merged 5 commits intofoliojs:masterfrom
filecage:#1486-fix-newline-items-in-lists

Conversation

@filecage
Copy link
Copy Markdown
Contributor

@filecage filecage commented Dec 20, 2023

What kind of change does this PR introduce?
Fixes #1486 by no longer using a newline character to separate list items, but actually print each list item in a single function and correctly respecting newlines of a list item.

Prior to this change, \n was used to separate list items, causing an unexpected number of bullet points when a list item contained a line break as well.

This PR also introduces a visual test for lists with different line break characters.

Checklist:

  • Unit Tests
  • Documentation (N/A)
  • Update CHANGELOG.md
  • Ready to be merged

@blikblum blikblum merged commit ebf404e into foliojs:master Dec 22, 2023
@bart
Copy link
Copy Markdown

bart commented Nov 27, 2024

Unfortunately this merge destroyed numbered lists feature. Numbers are always 1.

@filecage
Copy link
Copy Markdown
Contributor Author

Thx @bart, I can confirm the issue and will provide a followup PR. This will fix #1517.

Turns out, test coverage matters at the end of the day - who would've thought 😬

@filecage filecage mentioned this pull request Nov 27, 2024
4 tasks
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.

Printing list item with line break fails with Unsupported Number: NaN

3 participants