Repository navigation
Type on Tailwind's whole-pixel scale: text-sm 14px, text-xs 12px, titles 24px - #2698
Conversation
9212cc0 to
cb31139
Compare
davidmckayv
left a comment
There was a problem hiding this comment.
Approved. Nothing overflows or clips at 390px, at Desktop's 1000x800 window, or under the desktop host. Taste note only: with 14px descriptions, the two-line clamp cuts some Settings descriptions at 390px. Conflicts with #2701 in page-parts.tsx, ui/item.tsx and the layout skill; the docs' row heights (71px vs 53px, really about 60px) need reconciling by whichever lands second.
|
Closing: we're keeping the sizes Guido set in #2124. |
|
Reopened: closed by mistake. |
…les 24px theme.css set every --text-* step to Tailwind's default times 15/16, so each size was a fraction of a pixel: text-sm 13.125px, text-xs 11.25px, a page title 22.5px. The steps are now Tailwind's own: text-xs 12px, text-sm 14px, text-base 16px, text-2xl 24px. --text-conversation stays as it is. The line under a row's name (ItemDescription) is text-sm in muted-foreground, the name's size, as in shadcn. Three screens that forced it back to text-xs no longer do. Rows with a description are 71px, 6px taller than before. The look's type rule, the layout skill and the comments that stated the old sizes say the new ones. The artifacts kit test reads text-sm from Tailwind's own --text-sm.
The banner's line is text-sm, centred in its 28px row. At 14px on a 20px line (was 13.125px on 18.75px) its top lands at 10px instead of 11px in OpenDuet and OpenFuse. The banner and its row are where they were, so only the measured baseline changes.
…w sizes change The line under a row's name (ItemDescription) and the three screens that set it moved to their own pull request, so this one is the type scale alone. A title over a one-line description is 67px on the new scale (was 65px). OpenBot Desktop's setup window had its own copy of the 15/16 scale. It now uses Tailwind's whole-pixel steps too, so setup and the app match. At 16px the Docker Desktop hand-off needs a fifth line at the smallest window (720x560), so the page holds five lines there instead of four. "Sizes stay" in the look and in design-system.md now says how a size changes: only with its scale, for every screen at once, agreed first.
d07fe08 to
7cd8342
Compare
davidmckayv
left a comment
There was a problem hiding this comment.
Re-approved: since my last approval this push only merges main and drops the CHANGELOG.md edit (the note is in the description). Nothing else changed.
…line at 16px The cover Windows draws before the setup page loads copies the page's first card, and its test checks styles.css still has the sizes it copied. On the whole-pixel scale the h1 is 24px (was 22.5px) at 1.3 and the lede 16px (was 15px), so the cover now draws them at those sizes.
davidmckayv
left a comment
There was a problem hiding this comment.
Re-approved at 3c7bfbc. The new commit only brings Windows' first-paint cover into line with this PR's type scale (h1 24px at 1.3, lede 16px), and its test pins the copied tokens and the sheet's sizes. Nothing else changed.
theme.css: main's whole-pixel type scale (#2698), with the conversation at 15px and the message box at 16px on a touch screen. CHANGELOG: this branch's lines move to Unreleased, since 1.2.6 and 1.2.7 have shipped, and the 15px line no longer says it matches the app's other text.
The design-system change agreed with Sam after the design audit: text moves to Tailwind's own type scale, in whole pixels, in the web app and in OpenBot Desktop's setup window. This PR is the type scale only. The line under a row's name is in its own draft PR, #2721.
This changes what #2124 kept, on purpose
#2124 ("A sharper look") kept every size on purpose: "Kept on purpose: the sidebar strip, every size, …". This PR changes that one decision, for type only. Spacing, heights, radii, icons and the conversation size stay as they are. The look's text and the docs now say how a size changes: with its scale, for every screen at once, agreed first. @guidovizoso, this is the part for you to review. Nothing else that landed in #2124 or since is undone here.
Why
theme.cssset every--text-*step to Tailwind's default times 15/16. Each size was a fraction of a pixel, and everyday text (rows, names, fields, table cells) was smaller than in ChatGPT, Claude and Grok, which use 14–15px. The root was already 16px; only type was scaled. This PR removes the 15/16 steps, so eachtext-*class means what it means in Tailwind and shadcn.The scale
text-xstext-smtext-basetext-lgtext-xltext-2xltext-3xltext-4xltext-conversationWeights do not change. Line heights are Tailwind's own, as before.
UI text and conversation text
text-sm): rows, names, fields, buttons, tool lines in a conversation.--text-conversation, which this PR does not touch. It is 16px onmainand 15px once Long answers easier to read: typeset replies, document links at text size, 15px conversation, a Bot's plan #2634 lands. Both are larger than the UI text.chat-transcript.tsx). The message box reads it too (composer.tsx).text-sm: 14px, the UI text's size.text-xs(12px), by the labels rule: a code block's language and the "via" chip. Link chips aretext-xsonmain; Long answers easier to read: typeset replies, document links at text size, 15px conversation, a Bot's plan #2634 sets them at text size.text-baseortext-smin place of the token.What changed
app/src/theme.css. The 15/16 overrides are gone.--text-conversationstays as it is on main.desktop/src/styles.css) had its own copy of the 15/16 scale. It now uses the same whole-pixel steps, so setup and the app match. At 16px the Docker Desktop hand-off needs a fifth line in the smallest window (720 × 560), so the Start page holds five lines there instead of four (setup-page-first.css,min-height: 5lh). The setup window's layout test passes all 279 cases with it.docs/app-guidelines.mdnames the new sizes.design-system.md's "No pixel value" bullet now say how a size changes: only with its scale, for every screen at once, agreed first.design-system.mdsays the type scale and the spacing grid are Tailwind's own. They are no longer "intheme.css".Layout check
I checked the workbench at 1280 × 820 and at 390px wide, in light and dark, under the default look and each skin (OpenDots, OpenDuet, OpenFuse). The screens were Settings, Bots, Apps, Skills and Home. I also checked the setup window's Start and update pages at 720 × 560. No screen scrolls sideways, and nothing clips in the sidebars, rows, buttons or the message box.
The macOS window buttons over "Back to app" in the Settings shots are a workbench bug on main: Trusted Types blocks its page scripts. The polish-ui-bugs PR fixes it. Real Desktop is not affected.
Settings, light
Bots, dark
Apps, light
Phone width, light (top row before, bottom row after)
Skins
OpenDots, Apps:
OpenDuet, Skills:
OpenFuse at 390px, dark (top before, bottom after):
OpenBot Desktop's setup window, 720 × 560
Tests
app/tests/artifacts-kit.test.ts: it asserted thattext-smcompiles to0.8203125rem. It now assertstext-smreadsvar(--text-sm)and--text-smis0.875rem. The rule it holds is the same.app/tests/skins-window-buttons.test.tsx: the update banner's text is centred in its 28px row. At 14px on a 20px line it starts 1px higher in OpenDuet and OpenFuse (y 11 → 10). The banner and its row have not moved.desktop/src-tauri/src/first_paint.rs: the cover Windows draws before the setup page loads copies the page's first card. Its test checks thatstyles.cssstill has the sizes it copied. The cover now draws the h1 at 24px (was 22.5px) and the lede at 16px (was 15px), and the test reads the new tokens.ui-look-guard.test.ts,conversation-row-text.test.tsandconnect-your-ai.test.tsxgave the old sizes. No assertion changed and no allowlist grew.conversation-row-text.test.ts: this PR keeps its rule, that a line at the title's size loses a row's hierarchy. The conversation row keeps its 12px line, and no second line moves to the title's size here.Run locally:
setupLayout.browser.test.ts(279 pass), the CSS unit tests (145 pass) and thefirst_paintRust tests.tscinapp/anddesktop/, and Biome lint and format on the changed files.Not in this PR
@themeblock intheme.cssbeside--text-conversation. Whichever lands second keeps Long answers easier to read: typeset replies, document links at text size, 15px conversation, a Bot's plan #2634's conversation lines and drops the 15/16 steps.text-[12px], set by hand because no step drew 12px.text-xsis 12px now, so they can move to it and come off the allowlist. That file is in the sidebar PR (Conversations panel: labeled New conversation and Search rows, Pinned and Recents, status in place of the age #2696), so it waits until that lands.Changelog
The web app.
was a fraction of a pixel. It is now Tailwind's own: rows, names and fields are 14px (were
13.125px), labels, times and counts 12px (were 11.25px), body text 16px and page titles 24px.
A row with a description is 2px taller. A conversation's messages keep their size.
OpenBot Desktop.
Docker Desktop's directions get a fifth line instead of being held to four.