/** @jsx jsx */ import { jsx, Theme } from "theme-ui" import Table from "./table" import theme from "../theme" interface FontFamilyProps { fonts?: Theme["fonts"] previewText?: string } const FontFamily = ({ fonts = undefined, previewText = `The quick brown fox jumps over the lazy dog`, }: FontFamilyProps) => ( div > div:nth-of-type(2)": { display: [`none`, `block`], }, ...theme.typography.fontFamily, }} > {fonts ? ( Object.entries(fonts).map(([key, value]) => (
{key}
{/* @ts-ignore */}
{value}
{previewText}
)) ) : (
No fonts defined
)}
) export default FontFamily