diff --git a/web/.storybook/stories-category-doc-pages/Typography.stories.mdx b/web/.storybook/stories-category-doc-pages/Typography.stories.mdx index d70d654dd..990de5ee1 100644 --- a/web/.storybook/stories-category-doc-pages/Typography.stories.mdx +++ b/web/.storybook/stories-category-doc-pages/Typography.stories.mdx @@ -1,29 +1,140 @@ -import { Canvas, Meta, Story } from '@storybook/addon-docs'; +import { Canvas, Meta, Story, Typeset, Source } from '@storybook/addon-docs'; -## Body +export const SampleText = 'Lorem ipsum dolor sit amet, consectetur adipiscing elit.'; -
- The quick brown fox jumps over the lazy dog. -
+# Typography + +These are the font families in use by Owncast. + +--- + +export const bodyFont = { + type: { + primary: getComputedStyle(document.documentElement).getPropertyValue( + '--theme-text-body-font-family', + ), + }, + weight: { + regular: '400', + bold: '600', + extrabold: '800', + }, + size: { + s1: 12, + s2: 14, + s3: 16, + m1: 20, + m2: 24, + m3: 28, + l1: 32, + l2: 40, + l3: 48, + }, +}; + +## {bodyFont.type.primary.split(',')[0].replaceAll('"', '')} + +### Everywhere but headings and titles. + + + +## Usage {getComputedStyle(document.documentElement).getPropertyValue('--theme-text-body-font-family')} -## Display + + +export const displayFont = { + type: { + primary: getComputedStyle(document.documentElement).getPropertyValue( + '--theme-text-display-font-family', + ), + }, + weight: { + regular: '400', + bold: '600', + extrabold: '800', + }, + size: { + s1: 12, + s2: 14, + s3: 16, + m1: 20, + m2: 24, + m3: 28, + l1: 32, + l2: 40, + l3: 48, + }, +}; + +## {displayFont.type.primary.split(',')[0].replaceAll('"','')} + +### Headings and titles. + + + +## Usage -
- The quick brown fox jumps over the lazy dog. -
{getComputedStyle(document.documentElement).getPropertyValue('--theme-text-display-font-family')} + +