Commit Graph
9 Commits
Author SHA1 Message Date
Sergio Benitezandwxiaoguang ab9bcd6a79 fix(markdown): parse escaped alerts by default (#39633)
Previously, recognition of escaped alert markers such as `\[!NOTE\]`
accidentally depended on enabling the optional `inline-parentheses` math
setting, resulting in such escaped alerts not rendering properly.
Goldmark splits the escaped marker differently based on the setting
being enabled or disabled, and only one form was handled. This commit
handles both forms.

For example, in a README or issue:

```
> \[!NOTE\]
> text
```

Before this commit, we'd get an ordinary blockquote displaying literal
`[!NOTE]` followed by `text`. With this commit, we get the styled
admonition.

Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
2026-10-08 13:47:17 +00:00
wxiaoguang 6ff3a65708 refactor: render highlight language (#38793)
Avoid CSS injection

More details are in the comment of CodeBlockAttributes
2026-08-06 18:07:36 +08:00
Lunny Xiao 61b1a39efe chore: Move import path from code.gitea.io/gitea to gitea.dev (#37873) 2026-05-26 15:49:31 -07:00
wxiaoguang 1c69fdccdd Improve math rendering (#36124)
Fix #36108
Fix #36107
2025-12-10 15:49:24 +00:00
wxiaoguang e1c2d05bde Fix markdown render behaviors (#34122)
* Fix #27645
* Add config options `MATH_CODE_BLOCK_DETECTION`, problematic syntaxes
are disabled by default
* Fix #33639
    * Add config options `RENDER_OPTIONS_*`, old behaviors are kept
2025-04-05 11:56:48 +08:00
wxiaoguang cc5ff98e0d Refactor markdown math render (#32831)
Add more tests
2024-12-14 13:43:05 +08:00
wxiaoguang 5bc030efa2 Fix various UI bugs (#32821) 2024-12-13 01:45:32 -05:00
wxiaoguang 3c4a06273f Refactor markdown render (#32736)
and add some tests
2024-12-06 20:00:24 +08:00
wxiaoguang 0f18046df4 Refactor markdown render (#32728)
Follow up recent render system refactoring PRs (split test code), and
fine tune the math render (added some new cases)
2024-12-06 04:29:09 +00:00