forgejo/modules/markup
Gusted 54d5a8c073
[GITEA] Require Latex code to have a end sequence
- Currently the parser will look for `\[` and `$$` to detect when Latex
code starts, it will look for `\]` and `$$` respectively in order to
determine the end of the code. However if no end is found the parser
assumes the rest of the input is part of the Latex code.
- Adjust the parser's behavior to not allow the case to assume the rest
of the input is part of the Latex code and requires in order to
determine if some input is Latex code that the end sequence is also
specified.
- Example: `\[hello]` would no longer be detected as Latex code with
this patch.
- Added unit tests.
- Resolves https://codeberg.org/forgejo/forgejo/issues/1817

(cherry picked from commit 452aef1bb1)
(cherry picked from commit 8a857c24b0)
(cherry picked from commit acd1456db9)
(cherry picked from commit 6523b45073)
(cherry picked from commit e2e1a8afe7)
(cherry picked from commit a46ef652eb)
2024-01-08 17:05:47 +01:00
..
asciicast
common Make user-content-* consistent with github (#26388) 2023-08-09 09:30:31 +00:00
console
csv
external
markdown [GITEA] Require Latex code to have a end sequence 2024-01-08 17:05:47 +01:00
mdstripper
orgmode Add option to disable ambiguous unicode characters detection (#28454) 2023-12-17 14:38:54 +00:00
camo.go
camo_test.go
html.go Make cross-reference issue links work in markdown documents again (#28682) 2024-01-03 14:01:12 +08:00
html_internal_test.go Do not highlight #number in documents (#26365) 2023-08-07 15:11:25 +02:00
html_test.go Make cross-reference issue links work in markdown documents again (#28682) 2024-01-03 14:01:12 +08:00
renderer.go Add RTL rendering support to Markdown (#24816) 2023-05-20 23:02:52 +02:00
renderer_test.go
sanitizer.go Use restricted sanitizer for repository description (#28141) 2023-11-23 16:34:25 +00:00
sanitizer_test.go Use restricted sanitizer for repository description (#28141) 2023-11-23 16:34:25 +00:00