diff --git a/app/globals.css b/app/globals.css index b96ab4c9..a8a44a15 100644 --- a/app/globals.css +++ b/app/globals.css @@ -205,6 +205,7 @@ /* Scope custom fonts to document content only (not sidebar/UI chrome) */ .pageScrollWrapper { font-family: var(--theme-font, var(--font-quattro)); + font-size: var(--theme-font-base-size, 16px); } .pageScrollWrapper h1, @@ -214,6 +215,18 @@ font-family: var(--theme-heading-font, var(--theme-font, var(--font-quattro))); } + /* Scale heading sizes relative to the custom base font size */ + .pageScrollWrapper h1 { font-size: 2em; } + .pageScrollWrapper h2 { font-size: 1.625em; } + .pageScrollWrapper h3 { font-size: 1.125em; } + .pageScrollWrapper h4 { font-size: 1em; } + + /* Scale text size classes relative to the custom base font size. + Tailwind's text-sm/text-base/text-lg compile to fixed rem values + which ignore the custom base size set on .pageScrollWrapper. */ + .pageScrollWrapper .textSizeSmall { font-size: 0.875em; } + .pageScrollWrapper .textSizeLarge { font-size: 1.125em; } + .pageScrollWrapper pre { font-family: var(--theme-font, var(--font-quattro)); } diff --git a/app/lish/[did]/[publication]/[rkey]/Blocks/PublishedPageBlock.tsx b/app/lish/[did]/[publication]/[rkey]/Blocks/PublishedPageBlock.tsx index 938ec530..964cb6ed 100644 --- a/app/lish/[did]/[publication]/[rkey]/Blocks/PublishedPageBlock.tsx +++ b/app/lish/[did]/[publication]/[rkey]/Blocks/PublishedPageBlock.tsx @@ -111,7 +111,7 @@ export function DocLinkBlock(props: {