Mentions, emojis, etc don't work properly in usercard details

If you put a details section in your bio and open it, the HTML properties don’t work. Happens even on the latest discourse.


1개의 좋아요


When using the details feature in discourse, and putting it in your bio [first 2 lines], when you click it, it shows as:

[text put in] <br>

Is this not by design, rather than a bug? :thinking:

For obvious security reasons, we support a very limited set of styling / markdown in the user card.

While this doesn’t look like a security issue, I think it’s a bug since we should not allow <details> tags.

4개의 좋아요

Turns out the issue was our excerpt parser which was trying to be too clever with <details>.

I decided it doesn’t quite make sense to have those in the excerpt and instead replaced the whole content of the <details> block with “▶ summary” (“summary” being what’s written as the summary of the details block), like how they appear in the browser by default.

https://github.com/discourse/discourse/pull/30229

2개의 좋아요

This topic was automatically closed after 13 hours. New replies are no longer allowed.