kirupa.com

06 / COMPONENTS / READING

TL;DR

A collapsible short answer and three or four key takeaways right under an article's title. It starts closed, and its text stays in the page for search engines, AI answers, and find-in-page.

Reading1 variantcomponent

Live preview

LOCAL PREVIEW

Activate this specimen to load its real styles. No saved preferences change.

Notes

Use one TL;DR per article, as a direct child of article#tutorialInformation, right after the empty <div id="tutorialBox"></div> and before the intro. That puts it under the title and byline and inside the Markdown and plain-text twins. It's a native details element without open, so it starts collapsed and opens with a click, tap, Enter, or Space, with no JavaScript; never hide its text with script, hidden, or display: none, so search engines and find-in-page still read it. The summary is just the pixel TL;DR label and a chevron that turns when open (instantly under reduced motion). Write the answer as a plain 40-60 word reply to the question the title (or search title) asks, in the article's own casual voice, with no "In this article" or "This tutorial covers". Follow it with three or four takeaways of one or two sentences each, and make each one something the article actually says; don't add new claims, numbers, or sources, and never label figures or values as made up, illustrative, or samples. The answer and takeaways share one text size. Start each takeaway with a site icon that fits its point, set inline as --icon: url('https://www.kirupa.com/icon/<code>.svg') so the header's icon swap draws it in the reader's style; use a different icon per item and no emoji characters in the text. Don't add backgrounds, boxes, or inline colors. tools/ai_fundamentals_mirrors.py writes it into the Markdown twin as **TL;DR:** answer followed by the takeaways list; other mirror generators should do the same. Add FAQPage JSON-LD only when the article has a real question-and-answer section, never for the TL;DR itself.

Usage

TL;DR

Example composed with native selectors / Rendered markup
<details class="tldr">
  <summary class="tldr__label">TL;DR</summary>
  <p class="tldr__answer">A 40-60 word answer to the question the title asks.</p>
  <ul class="tldr__points">
    <li style="--icon: url('https://www.kirupa.com/icon/1f501.svg');">Key takeaway one.</li>
    <li style="--icon: url('https://www.kirupa.com/icon/1f4ac.svg');">Key takeaway two.</li>
    <li style="--icon: url('https://www.kirupa.com/icon/2702.svg');">Key takeaway three.</li>
  </ul>
</details>

Anatomy

Selectors:is(#mainContent, article#tutorialInformation) > .tldr#mainContent .tldr .tldr__label#mainContent .tldr .tldr__answer#mainContent .tldr .tldr__points.tldr__points li

Properties--linkForeground--bodyText

Sources

Agent Instructions / components

You are composing a current-shell KIRUPA page. Read /design/components.json and the relevant entry in /design/sections/components.md for selectors, variants, source files, and usage. Start from an adjacent working page and reuse its SSI structure and named component classes. When a link needs to look like a link inside the tutorial body, add the blueEmphasis class to its anchor, including in component examples. Style class names, IDs, and code identifiers in explanatory prose with inlineCode. Choose semantic HTML before adding JavaScript. Use visible labels, keyboard-operable controls, clear focus, and explicit loading/error/empty states. Keep forms inert in documentation specimens and label demo output. Preserve the article's reading rhythm and code overflow containment. Verify the component in each visual style and both modes. Do not initialize onboarding, tracking, a live chat request, or a subscription in a preview. Keep reference and navigation descriptions short and factual. Follow WCAG 2.2 AA for new or changed content: semantic HTML, keyboard access, visible focus, readable contrast in every theme, text alternatives, labeled controls, and explicit errors. Support zoom/reflow, respect reduced motion, and keep sound optional. Read /design/sections/accessibility.md for acceptance checks. Report unresolved barriers; automated checks alone do not establish conformance.