mirror of
https://github.com/enricoros/big-AGI.git
synced 2026-05-10 21:50:14 -07:00
ChatMessage: fix double-closure
This commit is contained in:
@@ -425,6 +425,7 @@ export function ChatMessage(props: {
|
||||
// Selection Toolbar
|
||||
|
||||
const handleCloseToolbar = React.useCallback((anchorEl: HTMLElement) => {
|
||||
window.getSelection()?.removeAllRanges?.();
|
||||
try {
|
||||
document.body.removeChild(anchorEl);
|
||||
} catch (e) {
|
||||
|
||||
Reference in New Issue
Block a user