Typography
For long-form content like articles, member communications or documentation, use the prose styles for consistent formatting. They extend the official @tailwindcss/typography plugin and are coloured with the Country Club design tokens, so they invert in dark mode automatically.
1. Install the plugin
Add the official Tailwind CSS Typography plugin:
pnpm add -D @tailwindcss/typography2. Add the prose styles
Create a typography.css file that maps the prose variables onto the kit's tokens. Because the tokens already invert in dark mode, one definition covers both themes:
/* app/typography.css — extends @tailwindcss/typography */
.prose {
--tw-prose-body: var(--muted-foreground);
--tw-prose-headings: var(--foreground);
--tw-prose-links: var(--foreground);
--tw-prose-bold: var(--foreground);
--tw-prose-bullets: var(--border);
--tw-prose-hr: var(--border);
--tw-prose-quotes: var(--foreground);
--tw-prose-quote-borders: var(--primary);
--tw-prose-captions: var(--muted-foreground);
--tw-prose-code: var(--foreground);
--tw-prose-pre-code: var(--card-foreground);
--tw-prose-pre-bg: var(--card);
--tw-prose-th-borders: var(--border);
--tw-prose-td-borders: var(--border);
}
/* Display headings use Fraunces (serif). */
.prose :is(h1, h2, h3, h4) {
font-family: var(--font-serif);
font-weight: 500;
letter-spacing: -0.01em;
}
/* Inline code: a soft chip from our tokens. */
.prose :not(pre) > code {
border-radius: 0.375rem;
background: var(--muted);
box-shadow: inset 0 0 0 1px var(--border);
padding: 0.125rem 0.375rem;
font-weight: 500;
}
.prose :not(pre) > code::before,
.prose :not(pre) > code::after {
content: "";
}3. Register the plugin and styles
In your global stylesheet, register the plugin and import the prose styles after the design system:
/* app/globals.css */
@import "tailwindcss";
@import "@countryclub/ui-react/styles.css";
@import "./typography.css";
@plugin "@tailwindcss/typography";4. Use the prose class
Add the prose class to any container of rich content:
<div className="prose">
<h1>Heading level 1</h1>
<p>The Spring Invitational returns to the East Course this May.</p>
<blockquote>
<p>There is no better way to know a course than to play it.</p>
</blockquote>
</div>Examples
Variations of the prose styles in light and dark mode.