Typography
Un componente de texto polimórfico para encabezados, párrafos, texto destacado y estilos en línea consistentes.
We moved the checkout service off the shared database last quarter. The migration took three weekends and one very long Friday, but read latency at the p95 dropped from 340ms to 90ms and the on call rotation stopped getting paged about lock contention.
Instalación
pnpm dlx nachui add typographyAnatomía
Ejemplos
Default
We moved the checkout service off the shared database last quarter. The migration took three weekends and one very long Friday, but read latency at the p95 dropped from 340ms to 90ms and the on call rotation stopped getting paged about lock contention.
Encabezados
Moving 40 packages into one repo
Why we stopped publishing internal packages
Versioning without a release train
What broke in CI on the first day
Cache keys and lockfile drift
Appendix: migration checklist
Lead, Large y Muted
Rebuilding search on a small budget
By Lucia Mendez, 6 min read, updated Mar 14
Our old search ran on a managed cluster that cost more than the rest of the stack combined. We replaced it with Postgres full text search and kept the results people actually clicked.
Queries got 40ms slower. The bill went from $1,900 a month to $60.
Polimórfico (prop as)
Dialogs now restore focus to the element that opened them. Run pnpm add @acme/ui@2.4.0 to pick up the fix.
Referencia de API
Typography
| Prop | Tipo | Por defecto | Descripción |
|---|---|---|---|
variant | 'h1' | 'h2' | 'h3' | 'h4' | 'h5' | 'h6' | 'p' | 'blockquote' | 'lead' | 'large' | 'small' | 'muted' | 'code' | 'p' | Variante de estilo de texto |
as | React.ElementType | - | Sobrescribe el elemento HTML renderizado |
align | 'left' | 'center' | 'right' | 'justify' | - | Alineación del texto |
weight | 'light' | 'normal' | 'medium' | 'semibold' | 'bold' | 'extrabold' | - | Peso de fuente personalizado |
className | string | - | Clases CSS adicionales |
¿Encontraste algo que mejorar?
¿Notaste un error, tipografía o detalle faltante en esta página? Ayúdanos a mejorar la documentación abriendo un issue en GitHub.