Added Better Closing Sidebar Logic (Close on Background Click) (#122)

This commit is contained in:
Awesh Choudhary
2023-03-25 17:42:06 +05:30
committed by GitHub
parent 69e05160a3
commit 291e2d9852
2 changed files with 6 additions and 4 deletions
+1 -1
View File
@@ -77,7 +77,7 @@ export const Sidebar: FC<Props> = ({ loading, conversations, lightMode, selected
}, [searchTerm, conversations]);
return (
<aside className={`h-full flex flex-none space-y-2 p-2 flex-col bg-[#202123] w-[260px] z-10 sm:relative sm:top-0 absolute top-12 bottom-0`}>
<aside className={`h-full transition-all flex flex-none space-y-2 p-2 flex-col bg-[#202123] w-[260px] z-50 sm:relative sm:top-0 fixed top-0 bottom-0`}>
<header className="flex items-center">
<button
className="flex gap-3 p-3 items-center w-[190px] rounded-md hover:bg-gray-500/10 transition-colors duration-200 text-white cursor-pointer text-sm flex-shrink-0 border border-white/20"