SIGN IN SIGN UP

fix: remove chat-pending-dragging class on re-render to fix opacity issue (#299886)

* fix: remove chat-pending-dragging class on re-render to fix opacity issue

Fixes #297473

The 'chat-pending-dragging' class (which sets opacity: 0.4) was not being
removed when elements were re-rendered. This caused messages to randomly
appear with lower opacity if they had been dragged before the list was
updated.

The fix adds 'chat-pending-dragging' to the classList.remove() call that
clears pending-related classes during re-render.

* fix: move class cleanup before pending divider rendering

Addresses review feedback: the chat-pending-dragging class was only
being removed on the normal render path. If a recycled template was
rendered as a pending divider, it would return early before the cleanup
code ran, leaving the class and opacity stuck at 0.4.

This moves the class cleanup to run before the isPendingDividerVM check,
ensuring it's always applied regardless of element type.
C
Connor Peet committed
175e346f3fb99de026ba7f9bb6542669ec309f76
Parent: 19b032d
Committed by GitHub <[email protected]> on 3/6/2026, 11:38:18 PM