Typography
Typography components and styles for consistent and visually appealing text across your application.
export * from './default'export * from './paragraph'export * from './prose'export * from './title'
Usage
import { H1, H2, H3, H4, H5, Paragraph } from '@nerdfish/ui'
<H1>The Legend of the Golden Apple</H1><H2>Chapter 1: The Beginning</H2><Paragraph>Long ago, in a land far away, there was a magical kingdom ruled by a kindand just king. The kingdom was full of riches, and the people were happy andcontent. But one day, a dark sorcerer cast a curse upon the land, causingthe crops to wither and the rivers to dry up.</Paragraph><H3>Chapter 2: The Quest</H3><Paragraph>The king, in his wisdom, knew that the only way to break the curse was tofind the legendary Golden Apple. The Golden Apple was said to be guarded bya fierce dragon in a far-off land, and whoever could retrieve it would begranted one wish.</Paragraph><H4>Chapter 3: The Journey</H4><Paragraph>The king called forth his bravest knight, Sir Cedric, to undertake the questfor the Golden Apple. Sir Cedric set out on his journey, facing many dangersand obstacles along the way.</Paragraph><H5>Chapter 4: The Battle</H5><Paragraph>Sir Cedric finally reached the dragon's lair, where he was met with a fiercebattle. But Sir Cedric was brave and skilled, and he was able to defeat thedragon and retrieve the Golden Apple.</Paragraph><blockquote>"With this Golden Apple, I wish for the curse to be lifted and forprosperity to return to our kingdom," Sir Cedric said as he returned to theking.</blockquote><Paragraph>The king was overjoyed and bestowed many honors upon Sir Cedric, including:</Paragraph><ul><li>Knight of the Realm</li><li>Duke of the Kingdom</li><li>Protector of the Golden Apple</li></ul><Paragraph>The curse was lifted, and the kingdom returned to its former glory. SirCedric was hailed as a hero and his legend lived on for generations to come.</Paragraph><H3>The End</H3>
Prose
/* eslint-disable react/no-unescaped-entities */'use client'export function TypographyProseExample() {return (<div className="prose dark:prose-invert"><h2>Chapter 1: The Beginning</h2><p>Long ago, in a land far away, there was a magical kingdom ruled by akind and just king. The kingdom was full of riches, and the people werehappy and content. But one day, a dark sorcerer cast a curse upon theland, causing the crops to wither and the rivers to dry up.</p><h3>Chapter 2: The Quest</h3><p>The king, in his wisdom, knew that the only way to break the curse wasto find the legendary Golden Apple. The Golden Apple was said to beguarded by a fierce dragon in a far-off land, and whoever could retrieveit would be granted one wish.</p><h4>Chapter 3: The Journey</h4><p>The king called forth his bravest knight, Sir Cedric, to undertake thequest for the Golden Apple. Sir Cedric set out on his journey, facingmany dangers and obstacles along the way.</p><h5>Chapter 4: The Battle</h5><p>Sir Cedric finally reached the dragon's lair, where he was met with afierce battle. But Sir Cedric was brave and skilled, and he was able todefeat the dragon and retrieve the Golden Apple.</p><blockquote>"With this Golden Apple, I wish for the curse to be lifted and forprosperity to return to our kingdom," Sir Cedric said as he returned tothe king.</blockquote><p>The king was overjoyed and bestowed many honors upon Sir Cedric,including:</p><ul><li>Knight of the Realm</li><li>Duke of the Kingdom</li><li>Protector of the Golden Apple</li></ul><p>The curse was lifted, and the kingdom returned to its former glory. SirCedric was hailed as a hero and his legend lived on for generations tocome.</p><h3>The End</h3></div>)}
Title
'use client'import { H2 } from '@nerdfish/ui'export function TypographyTitleExample() {return (<div className="flex flex-col"><H2>Default</H2><H2 variant="primary">Primary</H2><H2 variant="secondary">Secondary</H2><H2 variant="accent">Nerdfish</H2></div>)}
Paragraph
'use client'import { Paragraph } from '@nerdfish/ui'export function TypographyParagraphExample() {return (<div className="flex flex-col"><Paragraph>Once upon a time, there was a young girl named Emily who loved nothingmore than baking cakes. Her specialty was a rich, decadent chocolatecake that was always a hit with her family and friends. One day, Emilydecided to enter her cake into a local baking competition. She spenthours perfecting the recipe and decorating the cake with intricatedesigns made from fondant. When the day of the competition arrived,Emily nervously presented her cake to the judges. After what felt likean eternity, the judges announced that Emily had won first place!Overwhelmed with joy, Emily hugged her cake tightly and knew that all ofher hard work had paid off.</Paragraph></div>)}