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: depth issues in BulletedList #347

Draft
wants to merge 3 commits into
base: master
Choose a base branch
from

Conversation

gloaysa
Copy link

@gloaysa gloaysa commented Oct 12, 2024

Description

BulletedList plugin was not ready to handle nested ul/ol elements inside of it.

With this change, a new function that specialises in deserialising list elements is created. We parse each li element found inside a ul/ol element recursively, creating an array of descendants of type list-item for each li found.

Fixes #345

Type of change

Please tick the relevant option.

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • This change requires a documentation update

Checklist:

  • I have performed a self-review of my own code
  • I have commented on my code, particularly in hard-to-understand areas
  • I have made corresponding changes to the documentation
  • My changes generate no new warnings
  • I have checked my code and corrected any misspellings

Copy link

vercel bot commented Oct 12, 2024

@gloaysa is attempting to deploy a commit to the dargo's projects Team on Vercel.

A member of the Team first needs to authorize it.

@gloaysa
Copy link
Author

gloaysa commented Oct 12, 2024

This PR only addresses BulletedList plugin. I will address NumberedList once this one is merged.

Things I don't like:

  • I'm returning a buildBlock wrapped into an array, since I removed the map function.
  • I'm not sure how this will affect TodoList, although I have tested it and seems to work, I'm not sure if my testing was alright.

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.

[BUG] Depth issues with md serialize/deserialize
1 participant