Add Cowork-inspired font defaults with sans/serif/mono tokens - #11
Merged
Conversation
Promote font families to first-class semantic tokens so tenants can retarget stacks once, and use Inter / Source Serif 4 / JetBrains Mono as open defaults (docs load them; the library still ships no font files). Co-authored-by: Cursor <cursoragent@cursor.com>
🦋 Changeset detectedLatest commit: 5a79d61 The changes in this PR will be included in the next version bump. This PR includes changesets to release 4 packages
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
headingLg is the section/panel size used across fixtures and composites; Cowork-style serif belongs on display titles only. Co-authored-by: Cursor <cursoragent@cursor.com>
Contributor
Author
|
Follow-up: serif is now only on |
Watch-build core beside docs, and apply createTheme() as inline CSS vars in the preview decorator so light/dark stories pick up dist rebuilds without fighting Linaria's namedThemes extract cache. Co-authored-by: Cursor <cursoragent@cursor.com>
Level 1 already defaults to headingXl (serif); the explicit size=\"lg\" was forcing a panel-scale sans title. Co-authored-by: Cursor <cursoragent@cursor.com>
`yarn docs` hand-rolled child tracking, SIGTERM fan-out, and a shutdown re-entrancy guard that `concurrently -k -s first` already handles for the same two-process shape in apps/docs/scripts/test-storybook-ci.mjs. The preview decorator also built a fresh theme per story render, which defeated themeToCssVars' identity cache and every useMemo in ThemeProvider. Also widen the native-spike platform-default guard to the full set of CSS generic families: it only knew ui-sans-serif and system-ui, which was complete before the serif and mono stacks existed. Co-authored-by: Cursor <cursoragent@cursor.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
sans/serif/monosemantic tokens; typography roles reference them by name, and CSS emits--silk-font-*with indirect--silk-typography-*-familyvarsheadingLg/headingXluse serif); Silk still ships no font filesTest plan
yarn test(silk-core + silk + native-spike smoke)yarn test:perfandyarn test:packed@fontsource-variable/*still falls through to system facescreateTheme({ semantic: { fontFamily: { sans: '…' } } })and confirm all sans roles retargetMade with Cursor