Typography

shadcn/ui typography on the DESIGN.md scale. There is no component: headings and body come from the base layer, and long-form text opts into the prose utility for rhythm, blockquotes, lists, tables and inline code. Everything below is plain HTML inside one prose block.

<article className="prose">
  <h2 className="text-[34px] font-medium leading-[1.15] tracking-[-0.02em]">The Joke Tax Chronicles</h2>
  <p className="lead">Once upon a time…</p>
  …
</article>

Prose

The shadcn demo article, unchanged, wrapped in prose.

The Joke Tax Chronicles

Once upon a time, in a far-off land, there was a very lazy king who spent all day lounging on his throne. One day, his advisors came to him with a problem: the kingdom was running out of money.

The King's Plan

The king thought long and hard, and finally came up with a brilliant plan: he would tax the jokes in the kingdom.

"After all," he said, "everyone enjoys a good joke, so it's only fair that they should pay for the privilege."

The Joke Tax

The king's subjects were not amused. They grumbled and complained, but the king was firm:

  • 1st level of puns: 5 gold coins
  • 2nd level of jokes: 10 gold coins
  • 3rd level of one-liners: 20 gold coins

As a result, people stopped telling jokes, and the kingdom fell into a gloom. But there was one person who refused to let the king's foolishness get him down: a court jester named Jokester.

Jokester's Revolt

Jokester began sneaking into the castle in the middle of the night and leaving jokes all over the place: under the king's pillow, in his soup, even in the royal toilet. The king was furious, but he couldn't seem to stop Jokester.

And then, one day, the people of the kingdom discovered that the jokes left by Jokester were so funny that they couldn't help but laugh. And once they started laughing, they couldn't stop.

The People's Rebellion

The people of the kingdom, feeling uplifted by the laughter, started to tell jokes and puns again, and soon the entire kingdom was in on the joke.

King's TreasuryPeople's happiness
EmptyOverflowing
ModestSatisfied
FullEcstatic

The king, seeing how much happier his subjects were, realized the error of his ways and repealed the joke tax. Jokester was declared a hero, and the kingdom lived happily ever after.

The moral of the story is: never underestimate the power of a good laugh and always be careful of bad ideas. Run pnpm dlx shadcn@latest add if in doubt.

Footnote

  1. Taxes are collected on the first of the month.
  2. Puns are assessed at the point of delivery.

Text styles

The standalone styles from the shadcn page, each on the scale.

lead · Alcyone 18 / 400 / 1.5, muted

A modal dialog that interrupts the user with important content and expects a response.

large · Alcyone 18 / 600 / 1.4

Are you absolutely sure?

body emphasis · Alcyone 15 / 500

Email address

small · Alcyone 13 / 400 / 1.5

Enter your email address.

muted · Alcyone 13, text-muted

Enter your email address.

inline code · mono 13 on surface-2

Install with pnpm add @stocklots/ui-components.