mirror of
https://github.com/go-gitea/gitea.git
synced 2026-08-01 15:14:16 +00:00
8ab5d31cf3
Backport #38707 by @silverwind `.markup del code { text-decoration: inherit }` makes inline code inside `<del>` paint its own line-through in addition to the one already propagating from the parent. Since `code` is `font-size: 85%`, the two land at different heights and render as a doubled strikethrough. The rule was inherited from primer-markdown, where it was added in https://github.com/primer/css/commit/762b8b8264aa4c4beed0a7f842f90c142eb2b310 ("so that `<del>` or `<a>` has the same effects on `<code>` tags") at a time when inline `code` was `display: inline-block`, a box that text decorations do not propagate into. That `display: inline-block` was removed 11 days later in https://github.com/primer/css/commit/f1131d5ab618ac41d4097823b511ca0b373b2ee2, which made the rule redundant, but it survived the squashed import into primer/css and every copy downstream of it. No other popular markdown stylesheet carries an equivalent rule, GitHub still ships it and shows the same doubled line. Fixes: https://github.com/go-gitea/gitea/issues/34786 Co-authored-by: silverwind <me@silverwind.io>