diff --git a/web/sections/FontSizesTab.tsx b/web/sections/FontSizesTab.tsx index d048109..4d3e8a8 100644 --- a/web/sections/FontSizesTab.tsx +++ b/web/sections/FontSizesTab.tsx @@ -1,4 +1,5 @@ import { useDevice } from '../DeviceToggle'; +import { ROLES } from './roles'; /** * How big each role is, at the width being edited. @@ -20,14 +21,6 @@ export type FontSizes = Partial> | undefined, key: 'base' | 'md' | 'lg', @@ -69,16 +62,16 @@ export const FontSizesTab = ({ return (
{ROLES.map((role) => { - const current = sizes[role.key]; + const current = sizes[role.size]; const own = current?.[key]; const from = inherited(current, key); return ( -
+
patch({ [key]: event.currentTarget.value || null } as Partial)} + value={draft[font] ?? ''} + onChange={(event) => patch({ [font]: event.currentTarget.value || null } as Partial)} className="h-8 rounded-md border border-input bg-transparent px-2 text-xs" > {/* Not "Default" — the face the stylesheet actually uses, named. Choosing it puts things back rather than setting something new, and now you can see what back is. */} {draft.fonts.map((font) => (