diff --git a/lib/Locale/Po4a/Text.pm b/lib/Locale/Po4a/Text.pm index 0946670be..573f2b123 100644 --- a/lib/Locale/Po4a/Text.pm +++ b/lib/Locale/Po4a/Text.pm @@ -784,7 +784,11 @@ sub parse_markdown { $paragraph .= "$nextline"; ( $nextline, $nextref ) = $self->shiftline(); } - do_paragraph( $self, $paragraph, $wrapped_mode, $type ); + my $t = $self->translate( + $paragraph, $self->{ref}, $type, + "wrap" => 0 + ); + $self->pushline($t); $self->pushline($nextline); $paragraph = ""; $end_of_paragraph = 1; diff --git a/t/fmt/txt-markdown/PandocFencedCodeBlocks.md b/t/fmt/txt-markdown/PandocFencedCodeBlocks.md index 8098a8326..fe18e4807 100644 --- a/t/fmt/txt-markdown/PandocFencedCodeBlocks.md +++ b/t/fmt/txt-markdown/PandocFencedCodeBlocks.md @@ -48,6 +48,11 @@ qsort (x:xs) = qsort (filter (< x) xs) ++ [x] ++ qsort (filter (>= x) xs) ``` +```diff +- Code block that includes bullet-like text. +- Ensure that it doesn't get interpreted. +``` + This first pandoc fenced_div is non-nested. ::::: {#special .sidebar} diff --git a/t/fmt/txt-markdown/PandocFencedCodeBlocks.norm b/t/fmt/txt-markdown/PandocFencedCodeBlocks.norm index 8098a8326..fe18e4807 100644 --- a/t/fmt/txt-markdown/PandocFencedCodeBlocks.norm +++ b/t/fmt/txt-markdown/PandocFencedCodeBlocks.norm @@ -48,6 +48,11 @@ qsort (x:xs) = qsort (filter (< x) xs) ++ [x] ++ qsort (filter (>= x) xs) ``` +```diff +- Code block that includes bullet-like text. +- Ensure that it doesn't get interpreted. +``` + This first pandoc fenced_div is non-nested. ::::: {#special .sidebar} diff --git a/t/fmt/txt-markdown/PandocFencedCodeBlocks.po b/t/fmt/txt-markdown/PandocFencedCodeBlocks.po index a16a3502a..38c893179 100644 --- a/t/fmt/txt-markdown/PandocFencedCodeBlocks.po +++ b/t/fmt/txt-markdown/PandocFencedCodeBlocks.po @@ -7,7 +7,7 @@ msgid "" msgstr "" "Project-Id-Version: PACKAGE VERSION\n" -"POT-Creation-Date: 2020-04-28 18:23+0200\n" +"POT-Creation-Date: 2025-01-28 09:30+0300\n" "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" "Last-Translator: FULL NAME \n" "Language-Team: LANGUAGE \n" @@ -69,14 +69,24 @@ msgstr "" "LINE2\n" "``````````\n" +#. type: Fenced code block (diff) +#: PandocFencedCodeBlocks.md:51 +#, no-wrap +msgid "" +"- Code block that includes bullet-like text.\n" +"- Ensure that it doesn't get interpreted.\n" +msgstr "" +"- cODE BLOCK THAT INCLUDES BULLET-LIKE TEXT.\n" +"- eNSURE THAT IT DOESN'T GET INTERPRETED.\n" + #. type: Plain text -#: PandocFencedCodeBlocks.md:52 +#: PandocFencedCodeBlocks.md:57 #, markdown-text msgid "This first pandoc fenced_div is non-nested." msgstr "tHIS FIRST PANDOC FENCED DIV IS NON-NESTED." #. type: Fenced div block ({#special .sidebar}) -#: PandocFencedCodeBlocks.md:53 +#: PandocFencedCodeBlocks.md:58 #, no-wrap msgid "" "Here is a paragraph.\n" @@ -88,13 +98,13 @@ msgstr "" "aND ANOTHER.\n" #. type: Plain text -#: PandocFencedCodeBlocks.md:59 +#: PandocFencedCodeBlocks.md:64 #, markdown-text msgid "The second pandoc fenced div is nested." msgstr "tHE SECOND PANDOC FENCED DIV IS NESTED." #. type: Fenced div block (Warning ::::::) -#: PandocFencedCodeBlocks.md:60 +#: PandocFencedCodeBlocks.md:65 #, no-wrap msgid "" "This is a warning.\n" @@ -104,13 +114,13 @@ msgstr "" "\n" #. type: Fenced div block (Warning ::::::|Danger) -#: PandocFencedCodeBlocks.md:60 +#: PandocFencedCodeBlocks.md:65 #, no-wrap msgid "This is a warning within a warning.\n" msgstr "tHIS IS A WARNING WITHIN A WARNING.\n" #. type: Plain text -#: PandocFencedCodeBlocks.md:68 +#: PandocFencedCodeBlocks.md:73 #, markdown-text msgid "Some extra text." msgstr "sOME EXTRA TEXT." diff --git a/t/fmt/txt-markdown/PandocFencedCodeBlocks.pot b/t/fmt/txt-markdown/PandocFencedCodeBlocks.pot index 289814bd7..a49d845a9 100644 --- a/t/fmt/txt-markdown/PandocFencedCodeBlocks.pot +++ b/t/fmt/txt-markdown/PandocFencedCodeBlocks.pot @@ -7,7 +7,7 @@ msgid "" msgstr "" "Project-Id-Version: PACKAGE VERSION\n" -"POT-Creation-Date: 2020-04-28 18:23+0200\n" +"POT-Creation-Date: 2025-01-28 09:44+0300\n" "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" "Last-Translator: FULL NAME \n" "Language-Team: LANGUAGE \n" @@ -55,14 +55,22 @@ msgid "" "``````````\n" msgstr "" +#. type: Fenced code block (diff) +#: PandocFencedCodeBlocks.md:51 +#, no-wrap +msgid "" +"- Code block that includes bullet-like text.\n" +"- Ensure that it doesn't get interpreted.\n" +msgstr "" + #. type: Plain text -#: PandocFencedCodeBlocks.md:52 +#: PandocFencedCodeBlocks.md:57 #, markdown-text msgid "This first pandoc fenced_div is non-nested." msgstr "" #. type: Fenced div block ({#special .sidebar}) -#: PandocFencedCodeBlocks.md:53 +#: PandocFencedCodeBlocks.md:58 #, no-wrap msgid "" "Here is a paragraph.\n" @@ -71,13 +79,13 @@ msgid "" msgstr "" #. type: Plain text -#: PandocFencedCodeBlocks.md:59 +#: PandocFencedCodeBlocks.md:64 #, markdown-text msgid "The second pandoc fenced div is nested." msgstr "" #. type: Fenced div block (Warning ::::::) -#: PandocFencedCodeBlocks.md:60 +#: PandocFencedCodeBlocks.md:65 #, no-wrap msgid "" "This is a warning.\n" @@ -85,13 +93,13 @@ msgid "" msgstr "" #. type: Fenced div block (Warning ::::::|Danger) -#: PandocFencedCodeBlocks.md:60 +#: PandocFencedCodeBlocks.md:65 #, no-wrap msgid "This is a warning within a warning.\n" msgstr "" #. type: Plain text -#: PandocFencedCodeBlocks.md:68 +#: PandocFencedCodeBlocks.md:73 #, markdown-text msgid "Some extra text." msgstr "" diff --git a/t/fmt/txt-markdown/PandocFencedCodeBlocks.trans b/t/fmt/txt-markdown/PandocFencedCodeBlocks.trans index 9e8ce469e..f62a75292 100644 --- a/t/fmt/txt-markdown/PandocFencedCodeBlocks.trans +++ b/t/fmt/txt-markdown/PandocFencedCodeBlocks.trans @@ -48,6 +48,11 @@ QSORT (X:XS) = QSORT (FILTER (< X) XS) ++ [X] ++ QSORT (FILTER (>= X) XS) ``` +```diff +- cODE BLOCK THAT INCLUDES BULLET-LIKE TEXT. +- eNSURE THAT IT DOESN'T GET INTERPRETED. +``` + tHIS FIRST PANDOC FENCED DIV IS NON-NESTED. ::::: {#special .sidebar}