From 9ebcff5758d43e18d4062334f873c678660eb54d Mon Sep 17 00:00:00 2001 From: Sorunome Date: Tue, 16 Jul 2019 17:11:07 +0200 Subject: [PATCH] fix typo, add section on html details element --- proposals/2010-spoilers.md | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/proposals/2010-spoilers.md b/proposals/2010-spoilers.md index cf969902a..1d9f4dc9f 100644 --- a/proposals/2010-spoilers.md +++ b/proposals/2010-spoilers.md @@ -53,6 +53,12 @@ however that wouldn't be HTML-compliant. Instead of limiting the proposed `data-mx-spoiler` attribute only to the ``-tag it could be added to all tags, however it might make implementations for clients more complicated. +Alternatively the [details](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/details) tag could +be used. This, however, is a block element, and the spoilers are span elements. Furthermore +semantically there is a slight difference: with the details tag you hide something for a person +as it uses up a lot of screen space, while with a spoiler you hide something as a person might not +want to see it. + ## Potential issues Depending on context it might make sense to put other events, such as `m.image`, into spoilers, too. This MSC doesn't address that at all. Using @@ -60,7 +66,7 @@ too. This MSC doesn't address that at all. Using This MSC doesn't take HTML block elements into account. -Clients would have to come up with a way how to input spoilers. This could be done, for example, +Clients would have to come up with a way to input spoilers. This could be done, for example, by adding a custom markdown tag (like discord does), so that you do `Text ||spoiler||`, however that doesn't take a spoiler reason into account.