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.
As described in #74 markdown messages should also be renderd inside the android notification if possible.
If not at least the markdown "metadata" should be removed.
Rendering the markdown inside the android notification is basically possible, but tricky. This is because the support for spans in the notification is limited. The spans the Markwon lib generates by default are mostly ignored in notifications, so the span factory must be adapted similar to these examples to fit the android standard:
Markwon Notification Sample
Markwon RemoteView Sample
There's some scope to adapt the rendering to fit the markwon implementation, but basically this means that the rendering result and thus the appearance differ from the current. Also links are not clickable and some other things are ignored, like different text sizes for headings.
And the Markwon library doesn't produce HTML output which could also be used (also limited) in notifications.
So there are three places where the message is shown and markdown could be rendered:
The folded notification: Here also line breaks are ignored, so I show stripped text only here, while limited markdown rendering would also be possible.
The unfolded notification: Line breaks are rendered here, so I render the markdown here, even if it is limited.
The message list inside the app: No changes here. As mentioned above, the rendering result here differs from the limited rendering in the notification.
Is this an acceptable behaviour? As a fallback we can change it and only show the stripped message in the notification, which would look similar to this: