Skip to content
Open
Show file tree
Hide file tree
Changes from 36 commits
Commits
Show all changes
38 commits
Select commit Hold shift + click to select a range
7270793
🤖 fix: stop iPad clicks on app chrome from selecting the chat pane
ibetitsmike Jul 29, 2026
889066f
fix: scope the control selection rule to native buttons
ibetitsmike Jul 30, 2026
20f5316
tests: pin the touch selection guard with a static contract
ibetitsmike Jul 30, 2026
1a3a5e1
fix: drop the app-wide control selection rule
ibetitsmike Jul 30, 2026
039334c
tests: reject media syntax the selection contract cannot model
ibetitsmike Jul 30, 2026
18e9f15
tests: resolve the winning selection declaration
ibetitsmike Jul 30, 2026
3808e37
tests: reject malformed media conditions in the selection contract
ibetitsmike Jul 30, 2026
e192e80
tests: reject selection rules that can defeat the inherited guard
ibetitsmike Jul 30, 2026
c922a79
tests: reject app-wide selection suppression on fine pointers
ibetitsmike Jul 30, 2026
c620444
tests: close remaining gaps in the selection contract
ibetitsmike Jul 30, 2026
a3f9df7
tests: match media queries and suppression selectors exactly
ibetitsmike Jul 30, 2026
cb80fa4
tests: track Tailwind selection opt-ins the stylesheet parse cannot see
ibetitsmike Jul 30, 2026
830110c
tests: count selection opt-ins per file instead of listing files
ibetitsmike Jul 30, 2026
a3d54ef
tests: track arbitrary-property selection classes
ibetitsmike Aug 3, 2026
fc87ffe
tests: keep contract comments timeless
ibetitsmike Aug 3, 2026
bb03bc5
tests: count selection opt-ins in @source files too
ibetitsmike Aug 3, 2026
de0d186
tests: match every Tailwind selection spelling in the scans
ibetitsmike Aug 3, 2026
fdd2ec5
tests: match selection declarations case-insensitively
ibetitsmike Aug 3, 2026
ad1b031
tests: count inline selection styles as opt-ins
ibetitsmike Aug 3, 2026
0d4b5f8
tests: match kebab selection strings in any case
ibetitsmike Aug 3, 2026
80fe800
tests: pin each selection opt-in by its source line
ibetitsmike Aug 3, 2026
c9968b9
tests: pin selection opt-ins with the line that follows
ibetitsmike Aug 3, 2026
7061817
tests: reject app-shell ids as suppression subjects
ibetitsmike Aug 3, 2026
5282679
tests: track selection suppression sites like opt-ins
ibetitsmike Aug 3, 2026
9e7a2eb
tests: let Tailwind's scanner decide which files to scan
ibetitsmike Aug 3, 2026
9507186
tests: inventory selection tokens instead of snapshotting source
ibetitsmike Aug 3, 2026
e412a9b
tests: record the full Tailwind candidate in the inventory
ibetitsmike Aug 3, 2026
fc96d7e
test: require review for component-scoped selection suppression selec…
ibetitsmike Aug 3, 2026
cc47f44
test: inventory selection sites only in runtime renderer sources
ibetitsmike Aug 3, 2026
f6b3885
test: scan only renderer-reachable src segments for selection sites
ibetitsmike Aug 3, 2026
de06f58
test: exempt normal select-auto from the opt-in inventory
ibetitsmike Aug 3, 2026
6dcaa31
test: ignore comments in selection inventories
ibetitsmike Aug 3, 2026
580b3af
test: exclude Storybook helpers from selection inventory
ibetitsmike Aug 3, 2026
e155475
test: scan only executable renderer sources
ibetitsmike Aug 3, 2026
bfe66d1
test: parse runtime imports and cover vendor selection
ibetitsmike Aug 3, 2026
0e215a0
fix: inventory explicit inline selection writes
ibetitsmike Aug 4, 2026
c63d7e5
test: inventory rendered selection sites
ibetitsmike Aug 4, 2026
33ec94e
test: remove unbounded selection contract
ibetitsmike Aug 4, 2026
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
17 changes: 0 additions & 17 deletions src/browser/components/ChatPane/ChatPane.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,6 @@ import {
ChatDockSurface,
useChatDockColumnWidthClass,
} from "./chatDockColumn";
import { resolveComposerControlFocusTarget } from "./composerControlFocus";
import { useTranscriptDensity } from "@/browser/hooks/useTranscriptDensity";
import { useReviews } from "@/browser/hooks/useReviews";
import { ReviewsBanner } from "../ReviewsBanner/ReviewsBanner";
Expand Down Expand Up @@ -836,21 +835,6 @@ const ChatPaneContent: React.FC<ChatPaneContentProps> = (props) => {
[clearActiveSideQuestionScrollHold, handleScrollContainerMouseDown, isComposerDockEvent]
);

const handleComposerDockMouseDown = (event: React.MouseEvent<HTMLDivElement>) => {
if (event.defaultPrevented || event.button !== 0) {
return;
}
const control = resolveComposerControlFocusTarget(event.target, composerDockRef.current);
if (!control) {
return;
}
// Suppressing the default keeps WebKit from walking focus up to the scrollport
// (see composerControlFocus); the control then takes focus the way it already
// does on Chromium.
event.preventDefault();
control.focus({ preventScroll: true });
};

const handleTranscriptTouchMove = useCallback(() => {
clearActiveSideQuestionScrollHold();
markUserScrollIntent();
Expand Down Expand Up @@ -1787,7 +1771,6 @@ const ChatPaneContent: React.FC<ChatPaneContentProps> = (props) => {
<ChatDockColumnProvider value={chatTranscriptFullWidth}>
<div
ref={composerDockRef}
onMouseDown={handleComposerDockMouseDown}
data-testid="chat-composer-dock"
className="bg-surface-primary sticky bottom-0 z-10 mx-[-15px] break-normal whitespace-normal"
style={COMPOSER_DOCK_STYLE}
Expand Down
23 changes: 0 additions & 23 deletions src/browser/components/ChatPane/composerControlFocus.ts

This file was deleted.

25 changes: 15 additions & 10 deletions src/browser/styles/globals.css
Original file line number Diff line number Diff line change
Expand Up @@ -1127,28 +1127,33 @@ body,
background-color: var(--color-surface-primary);
}

/* Mobile improvements - only apply to touch devices */
@media (max-width: 768px) and (pointer: coarse) {
html {
-webkit-text-size-adjust: 100%;
touch-action: manipulation;
}

/* iPadOS reports pointer: coarse even with a trackpad attached, so selection suppression
must not be limited to phone widths. */
@media (pointer: coarse) {
Comment thread
ibetitsmike marked this conversation as resolved.
body {
font-size: 15px;
/* User request: prevent accidental text highlighting while tapping/scrolling on touch devices. */
-webkit-user-select: none;
user-select: none;
}

/* Keep selection/caret behavior in editable controls on touch devices. */
/* Body selection is suppressed above, so editable controls must opt back in. */
input,
textarea,
[contenteditable="true"],
[contenteditable="plaintext-only"] {
-webkit-user-select: text;
user-select: text;
}
}

@media (max-width: 768px) and (pointer: coarse) {
html {
-webkit-text-size-adjust: 100%;
touch-action: manipulation;
}

body {
font-size: 15px;
}

.mobile-hide-shortcut-hints {
display: none !important;
Expand Down
Loading
Loading