The asset-path rewrite regex (<img src="|](?:(|:\s+))(?!http)([^?"]+?.
(?:jpe?g|gif|png|svg|pdf|webp|avif))(?:?[^"\s]*)? uses a character class that only excludes ? and ".
It therefore matches across newlines and ), so any Markdown link followed later in the document by a bare path ending in an asset extension causes the whole span to be treated as a path, percent-encoded, and substituted back into the source.
Non-ASCII text in that span renders as %E3%81%82-style sequences. Minimal repro (3 lines, any processor, MathJax on or off):
あ[a](README.md)い
参照は `ref/x.pdf` です