Details
A native disclosure for the paragraph most readers do not need, and the rule for what may go inside one.
- #authoring
- #components
A disclosure for content that is worth keeping and not worth reading twice: a full type definition, the derivation behind a number, the long version of a short answer.
It is built on the browser's own <details> and <summary>, so it works
without JavaScript, it is searchable by the browser's find, and the chevron is
the only thing added.
The full ContentEntry shape
Why adjacent assets are discovered rather than declared
A declared asset list is a second place to forget. The loader reads the entry directory, types what it finds by extension, and exposes it on the entry, so a file dropped beside the document is available to it immediately.
What not to hide
The summary has to tell the truth about the contents, because that line is all a reader has to decide with. "More information" is not a summary.
Nothing a reader needs to follow the next paragraph belongs behind a disclosure, and neither does a warning. Hiding a caveat is how it gets missed. That belongs in a callout.
Props
<Details />
summarystring
The closed-state line. Say what is inside, in plain text.
defaultOpen?boolean
Opens on load, for content shown by default but foldable away.
- Default
false
Related entries
Callouts
Semantic notices for a caveat, a tip or a danger, with the five types and when each is honest.
Steps
A numbered procedure whose rail survives the code blocks inside it.
Tabs
One panel per alternative, with keyboard navigation and a shared choice across the document.