Instead of appearing below or alongside the main content, notes on FiveThirtyEight expand within or below the paragraph when the note tag is clicked. They could be referred to as "in-notes" instead of footnotes.
I personally find this system very efficient and believe it is the most suitable note system for the web that I have encountered. (Although I must admit, I don't want to be seen as a devoted fan of Nate Silver.)
How can I implement these in-notes?
I have searched around and found some solutions using jquery or other languages, but it seems like 538 only uses HTML and CSS.
I think I could possibly create something similar with <details>
, but I suspect there may be a better solution out there. I've checked the source code on 538, but I'm unsure which part is relevant.
Here's an example article chosen for its recent publication date. Click on the first footnote to see the in-note feature.
This link might appear to cover the same topic, but based on my lack of knowledge, I believe it doesn't address my specific question.
UPDATE: According to Elvislives, it appears that 538 does use javascript for this feature. With my limited understanding of javascript, my question now shifts to, Is it possible to create inline notes using only HTML5?