possible fix for delete button
parent
da0d4844f1
commit
f0b22eff64
|
@ -131,7 +131,13 @@ export default function RecentChats(props: any) {
|
||||||
const currentChatID = context.currentChat.chat?.id;
|
const currentChatID = context.currentChat.chat?.id;
|
||||||
const recentChats = context.chat.search.query('');
|
const recentChats = context.chat.search.query('');
|
||||||
|
|
||||||
const onClick = useCallback(() => {
|
const onClick = useCallback((e: React.MouseEvent) => {
|
||||||
|
if (e.currentTarget.closest('button')) {
|
||||||
|
e.preventDefault();
|
||||||
|
e.stopPropagation();
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
if (window.matchMedia('(max-width: 40em)').matches) {
|
if (window.matchMedia('(max-width: 40em)').matches) {
|
||||||
dispatch(toggleSidebar());
|
dispatch(toggleSidebar());
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue