Skip to content

Commit 9a69de9

Browse files
Williawarclaude
andcommitted
fix(web): express composer glass step-in in rem to track interface font size
The context strip is laid out in rem (w-[calc(100%-2.75rem)]) but the glass slab's shape() stepped in with px constants, so the slab overhung the strip's border whenever Typography > Interface font size was not 16. Convert the step-in positions and their curve controls to rem (22px -> 1.375rem, 9.85px -> 0.6156rem, 38px -> 1.375rem + 16px, 29.16px -> 1.375rem + 7.16px); the composer's 22px top radius and the strip's 16px/7.16px bottom radius are px by design and stay px. Fixes #5662 Co-Authored-By: Claude Fable 5 <[email protected]>
1 parent a20923c commit 9a69de9

1 file changed

Lines changed: 17 additions & 13 deletions

File tree

‎apps/web/src/index.css‎

Lines changed: 17 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -458,27 +458,31 @@ html[data-mobile-composer-route-transition="true"]::view-transition-old(t3-mobil
458458
.chat-composer-glass-shell-with-context::before {
459459
border-radius: 0;
460460
/*
461-
* One continuous glass layer: a 22px composer joined to a 16px strip,
462-
* whose visible sides align with the composer's bottom tangents.
461+
* One continuous glass layer: a 22px composer joined to a 16px strip. The
462+
* strip is inset 1.375rem per side, so the step-in positions and their
463+
* curve controls stay in rem to keep tracking it at non-default interface
464+
* font sizes; the composer's 22px top radius and the strip's 16px bottom
465+
* radius are px by design.
463466
*/
464467
clip-path: shape(
465468
from 0 22px,
466469
curve to 22px 0 with 0 9.85px / 9.85px 0,
467470
line to calc(100% - 22px) 0,
468471
curve to 100% 22px with calc(100% - 9.85px) 0 / 100% 9.85px,
469-
line to 100% calc(100% - var(--chat-composer-context-extension) - 22px),
470-
curve to calc(100% - 22px) calc(100% - var(--chat-composer-context-extension)) with 100%
471-
calc(100% - var(--chat-composer-context-extension) - 9.85px) / calc(100% - 9.85px)
472+
line to 100% calc(100% - var(--chat-composer-context-extension) - 1.375rem),
473+
curve to calc(100% - 1.375rem) calc(100% - var(--chat-composer-context-extension)) with 100%
474+
calc(100% - var(--chat-composer-context-extension) - 0.6156rem) / calc(100% - 0.6156rem)
472475
calc(100% - var(--chat-composer-context-extension)),
473-
line to calc(100% - 22px) calc(100% - 16px),
474-
curve to calc(100% - 38px) 100% with calc(100% - 22px) calc(100% - 7.16px) /
475-
calc(100% - 29.16px) 100%,
476-
line to 38px 100%,
477-
curve to 22px calc(100% - 16px) with 29.16px 100% / 22px calc(100% - 7.16px),
478-
line to 22px calc(100% - var(--chat-composer-context-extension)),
479-
curve to 0 calc(100% - var(--chat-composer-context-extension) - 22px) with 9.85px
476+
line to calc(100% - 1.375rem) calc(100% - 16px),
477+
curve to calc(100% - 1.375rem - 16px) 100% with calc(100% - 1.375rem) calc(100% - 7.16px) /
478+
calc(100% - 1.375rem - 7.16px) 100%,
479+
line to calc(1.375rem + 16px) 100%,
480+
curve to 1.375rem calc(100% - 16px) with calc(1.375rem + 7.16px) 100% / 1.375rem
481+
calc(100% - 7.16px),
482+
line to 1.375rem calc(100% - var(--chat-composer-context-extension)),
483+
curve to 0 calc(100% - var(--chat-composer-context-extension) - 1.375rem) with 0.6156rem
480484
calc(100% - var(--chat-composer-context-extension)) / 0
481-
calc(100% - var(--chat-composer-context-extension) - 9.85px),
485+
calc(100% - var(--chat-composer-context-extension) - 0.6156rem),
482486
line to 0 22px,
483487
close
484488
);

0 commit comments

Comments
 (0)