Commit cc42eb7
Let the link preview be dismissed back to the reply plate
Quoting a message and then typing a link left the plate stuck on the web page:
neither Escape, nor the cross, nor "Remove preview" could get rid of it.
setTopInfo({type: 'webpage'}) only repaints the plate - helperType stays
'reply' - so onHelperCancel restores the previous helper by calling
helperFunc(). But willSendWebPage was dropped only AFTER that call, and
setTopInfo bails out early on `willSendWebPage && type === 'reply'`, so the
reply was never repainted: the plate kept showing a preview that was already
gone from the state. setCurrentHover got an undefined element along the way,
which also killed the hover menu holding "Remove preview" - hence "stuck".
Drop willSendWebPage before restoring the helper; lastUrl / noWebPage are
still restored afterwards, since setTopInfo's clearHelper resets them.
Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>1 parent 1d0e373 commit cc42eb7
1 file changed
Lines changed: 8 additions & 7 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
3988 | 3988 | | |
3989 | 3989 | | |
3990 | 3990 | | |
3991 | | - | |
3992 | | - | |
3993 | | - | |
3994 | | - | |
3995 | | - | |
| 3991 | + | |
| 3992 | + | |
| 3993 | + | |
| 3994 | + | |
| 3995 | + | |
3996 | 3996 | | |
3997 | | - | |
| 3997 | + | |
| 3998 | + | |
| 3999 | + | |
3998 | 4000 | | |
3999 | 4001 | | |
4000 | 4002 | | |
4001 | 4003 | | |
4002 | 4004 | | |
4003 | | - | |
4004 | 4005 | | |
4005 | 4006 | | |
4006 | 4007 | | |
| |||
0 commit comments