1
0
Fork 0
mirror of https://github.com/M66B/FairEmail.git synced 2024-12-28 02:37:16 +00:00

Added Markwon html plugin

This commit is contained in:
M66B 2021-06-26 11:34:56 +02:00
parent 4ecb324b93
commit 4282330646
2 changed files with 5 additions and 1 deletions

View file

@ -432,6 +432,7 @@ dependencies {
// https://github.com/noties/Markwon
// https://mvnrepository.com/artifact/io.noties.markwon/core
implementation "io.noties.markwon:core:$markwon_version"
implementation "io.noties.markwon:html:$markwon_version"
// // https://github.com/QuadFlask/colorpicker
implementation "com.github.QuadFlask:colorpicker:$colorpicker_version"

View file

@ -35,6 +35,7 @@ import androidx.annotation.Nullable;
import java.io.InputStream;
import io.noties.markwon.Markwon;
import io.noties.markwon.html.HtmlPlugin;
public class FragmentDialogMarkdown extends FragmentDialogBase {
@NonNull
@ -84,7 +85,9 @@ public class FragmentDialogMarkdown extends FragmentDialogBase {
"https://github.com/M66B/FairEmail/blob/master/FAQ.md",
"https://github.com/M66B/FairEmail/blob/master/docs/FAQ-" + locale + ".md");
Markwon markwon = Markwon.create(context);
Markwon markwon = Markwon.builder(context)
.usePlugin(HtmlPlugin.create())
.build();
return markwon.toMarkdown(markdown);
}