support markdown in editor

events can be edited in markdown. markup language can be set in series
template for newly created events.
This commit is contained in:
Milan
2020-03-07 22:47:52 +01:00
parent 1607b5468f
commit 9b7a1ebc88
16 changed files with 178 additions and 48 deletions

View File

@@ -10,6 +10,7 @@ use HTML::Parse();
use HTML::FormatText();
use Encode();
use HTML::Entities();
use Text::Markdown();
use log();
@@ -144,6 +145,13 @@ sub creole_to_html ($) {
return $s;
}
sub markdown_to_html($){
my $text = $_[0] // '';
print STDERR "markwon!\n";
my $html = Text::Markdown::markdown($text);
return $html;
}
sub creole_to_plain($) {
my $s = shift;