diff --git a/src/components/Menu/ChatFolder.tsx b/src/components/Menu/ChatFolder.tsx
index 0178b20..365c83e 100644
--- a/src/components/Menu/ChatFolder.tsx
+++ b/src/components/Menu/ChatFolder.tsx
@@ -155,7 +155,7 @@ const ChatFolder = ({
style={{ background: color || '' }}
className={`${
color ? '' : 'hover:bg-gray-850'
- } transition-colors flex py-3 pl-3 pr-1 items-center gap-3 relative rounded-md break-all cursor-pointer`}
+ } transition-colors flex py-3 pl-3 pr-1 items-center gap-3 relative rounded-md break-all cursor-pointer parent-sibling`}
onClick={toggleExpanded}
ref={folderRef}
onMouseEnter={() => {
@@ -272,7 +272,8 @@ const ChatFolder = ({
)}
-
+
) : (
diff --git a/tailwind.config.cjs b/tailwind.config.cjs
index 0cc6849..345d2dd 100644
--- a/tailwind.config.cjs
+++ b/tailwind.config.cjs
@@ -1,4 +1,15 @@
/** @type {import('tailwindcss').Config} */
+
+function parentSiblingHoverPlugin({ addVariant, e }) {
+ addVariant('parent-sibling-hover', ({ modifySelectors, separator }) => {
+ modifySelectors(({ className }) => {
+ return `.parent-sibling:hover ~ .parent .${e(
+ `parent-sibling-hover${separator}${className}`
+ )}`;
+ });
+ });
+}
+
module.exports = {
content: ['./index.html', './src/**/*.{js,ts,jsx,tsx}'],
theme: {
@@ -52,6 +63,6 @@ module.exports = {
},
},
},
- plugins: [require('@tailwindcss/typography')],
+ plugins: [require('@tailwindcss/typography'), parentSiblingHoverPlugin],
darkMode: 'class',
};