Skip to content

Commit 9fb9bfa

Browse files
committed
fix(web): constrain question media previews and preserve video controls
Cap collapsed Markdown at one line height and restore pointer events for native video controls in both option fields. Keep ChatMarkdown unchanged. These layout and pointer-target invariants require browser CSS checks; TypeScript cannot enforce rendered geometry or hit testing. The existing issue #11132 and PR #18460 track the shared question-card boundary. Validation: 118 focused tests passed; web typecheck, targeted lint, formatting, and diff checks passed. Browser CSS reproduction confirms one-line image/video previews and video hit targets. Native playback was not verified.
1 parent 34b71e7 commit 9fb9bfa

1 file changed

Lines changed: 3 additions & 3 deletions

File tree

‎apps/web/src/components/chat/ComposerPendingUserInputPanel.tsx‎

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -231,7 +231,7 @@ const ComposerPendingUserInputCard = memo(function ComposerPendingUserInputCard(
231231
text={activeQuestion.question}
232232
cwd={cwd}
233233
threadRef={threadRef}
234-
className="line-clamp-1"
234+
className="line-clamp-1 max-h-lh"
235235
/>
236236
</span>
237237
) : null}
@@ -291,7 +291,7 @@ const ComposerPendingUserInputCard = memo(function ComposerPendingUserInputCard(
291291
text={option.label}
292292
cwd={cwd}
293293
threadRef={threadRef}
294-
className="text-sm font-medium [&_a]:pointer-events-auto [&_button]:pointer-events-auto [&_[role=button]]:pointer-events-auto"
294+
className="text-sm font-medium [&_a]:pointer-events-auto [&_button]:pointer-events-auto [&_[role=button]]:pointer-events-auto [&_video[controls]]:pointer-events-auto"
295295
/>
296296
</div>
297297
{hasDescription ? (
@@ -300,7 +300,7 @@ const ComposerPendingUserInputCard = memo(function ComposerPendingUserInputCard(
300300
text={option.description}
301301
cwd={cwd}
302302
threadRef={threadRef}
303-
className="text-secondary-label text-2xs [&_a]:pointer-events-auto [&_button]:pointer-events-auto [&_[role=button]]:pointer-events-auto"
303+
className="text-secondary-label text-2xs [&_a]:pointer-events-auto [&_button]:pointer-events-auto [&_[role=button]]:pointer-events-auto [&_video[controls]]:pointer-events-auto"
304304
/>
305305
</div>
306306
) : null}

0 commit comments

Comments
 (0)