Skip to content

Commit 8f576ce

Browse files
t3dotggclaude
andcommitted
fix(web): selected text stays visible on a revealed file line
The file link reveal tint was painted as the row's own background. In the editable file view that row paints above the editor's text selection layer, so selecting text on the revealed line showed nothing. Set the tint through --diffs-line-bg instead, which the editor paints below the selection. Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
1 parent 568c9bc commit 8f576ce

1 file changed

Lines changed: 4 additions & 1 deletion

File tree

‎apps/web/src/components/files/fileSurfaceChrome.tsx‎

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,8 +29,11 @@ export const FILE_LINK_REVEAL_UNSAFE_CSS = `
2929
color: var(--code-foreground, var(--foreground)) !important;
3030
}
3131
32+
/* Tint through --diffs-line-bg, not background-color. The editor paints row
33+
tints on a layer below its text selection; a background on the row itself
34+
covers the selection and makes selected text on this line invisible. */
3235
[${FILE_LINK_REVEAL_ATTRIBUTE}][data-line] {
33-
background-color: light-dark(
36+
--diffs-line-bg: light-dark(
3437
color-mix(
3538
in lab,
3639
var(--diffs-computed-diff-line-bg) 82%,

0 commit comments

Comments
 (0)