-
-
Notifications
You must be signed in to change notification settings - Fork 62
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
RichTextStateMarkdownParser.decode doesnt decode Lists or Highlighted text. #223
Comments
Thanks for reporting this! |
Yes, I actually learned that when I was checking out the code. But the problem is my code is already heavily dependent on MarkDown that I can't use html now. |
is there a function to convert markDown Text to Html string? |
Unfortunately no, all you can do is Convert Markdown -> RichTextState -> HTML |
Now lists should be working fine with markdown starting from |
Now Markdown supports lists and highlighted text with `` |
When I use the
richTextState.toMarkdown()
which supposedly decodes the RichTextState to a markdown string and returns String.It only decodes Bold, Italic, Code or Underline. It doesn't decode Lists.
I really crave this feature, Because I want to store the text in Room and then also show it again when user reopens the note. but the problem is: when I store the text using
richTextState.toMarkdown()
it only decodes certain values and not lists or highlighted lists.so when I reCompose the MarkDowned Text it does show text in bold or italic or underlined style. but it lacks the Lists and other very important styles.
Does this feature exist or it is coming or is it not neccessary?
this is my code:
changeNoteCardText = { changeNoteCardText(cardId.value,2,notesRichTextState.toMarkdown()) notesRichTextState.setMarkdown(removeUnwantedSymbols( notesRichTextState.toMarkdown())) changeEdit(false) } )
-and this is how I show the text:
LaunchedEffect(true) { notesRichTextState.setMarkdown(removeUnwantedSymbols( notesText)) }
The text was updated successfully, but these errors were encountered: