diff options
author | George Punter <gsp14@ic.ac.uk> | 2018-03-22 20:41:28 +0000 |
---|---|---|
committer | George Punter <gsp14@ic.ac.uk> | 2018-03-22 20:41:28 +0000 |
commit | 578af84c16b45d2f0a6cb25929a7d530c65f1b07 (patch) | |
tree | e62638bcfd1c9d1c9618709a4bcece2a8a88f559 /FMark | |
parent | 8acf8426a367eb0c244eb87bd1cba75c906b8350 (diff) | |
parent | 5291e75ef835ee1bcc9a4d19519efd166a774fd3 (diff) | |
download | FMark-578af84c16b45d2f0a6cb25929a7d530c65f1b07.tar.gz FMark-578af84c16b45d2f0a6cb25929a7d530c65f1b07.zip |
Merge branch 'readmes_examples' into separate_cite
Diffstat (limited to 'FMark')
-rw-r--r-- | FMark/src/Common/MarkdownGen/MarkdownGen.fs | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/FMark/src/Common/MarkdownGen/MarkdownGen.fs b/FMark/src/Common/MarkdownGen/MarkdownGen.fs index 2927937..5b6f50d 100644 --- a/FMark/src/Common/MarkdownGen/MarkdownGen.fs +++ b/FMark/src/Common/MarkdownGen/MarkdownGen.fs @@ -1,4 +1,5 @@ module MarkdownGen +// MarkdownGen is only used for some property-based testing and is not ready for use for anything else. open Types open Shared @@ -6,7 +7,7 @@ open Logger let logger = Logger(LogLevel.INFO) -// retunr string surrounded by pat +// return string surrounded by pat let surround pat str = let pat2 = match pat with | "(" -> ")" @@ -36,7 +37,9 @@ and mdInlineElements' b eles = | FrmtedString fStr -> mdFStr fStr | Link (ht, url) -> (mdFStr ht |> sbraSurround) + (url |> braSurround) | Picture (alt, url) -> (alt |> sbraSurround |> sprintf "!%s" ) + (url |> braSurround) - | Reference (ht, _) -> ("^" + mdFStr ht) |> sbraSurround + | InlineCitation (ht, _) -> + | InlineFootnote (ht, _) -> ("^" + mdFStr ht) |> sbraSurround + | _ -> "not implemented in MarkdownGen" List.fold convertMd (sprintf "%s" b) eles and mdInlineElements = mdInlineElements' "" |