Skip to content

Commit 1513be0

Browse files
author
Max Shkutnyk
committed
update card colors and animation for dark mode
1 parent b14ea30 commit 1513be0

File tree

2 files changed

+5
-5
lines changed

2 files changed

+5
-5
lines changed

fern/components/cookbooks/CookbookCard.tsx

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -10,10 +10,10 @@ interface CookbookCardProps {
1010
export const CookbookCard: React.FC<CookbookCardProps> = ({ cookbook, bgColor }) => (
1111
<a
1212
href={cookbook.href}
13-
className={`block border border-gray-200 rounded-lg hover:shadow-md transition-shadow ${bgColor} dark:hover:brightness-110 dark:hover:border-gray-500 transition-colors `}
13+
className={`block border border-gray-200 rounded-lg hover:shadow-md transition-shadow ${bgColor} dark:border-gray-800 dark:hover:brightness-125 dark:hover:border-gray-400 transition-colors `}
1414
>
1515
<div className="p-6 flex flex-col justify-between h-full">
16-
<h3 className="text-base font-medium text-gray-800 mb-3">{cookbook.title}</h3>
16+
<h3 className="text-base font-medium text-gray-800 dark:dark-theme-text-color mb-3">{cookbook.title}</h3>
1717
<div>
1818
{cookbook.author?.name && (
1919
<div className="flex items-center mb-4">
@@ -22,14 +22,14 @@ export const CookbookCard: React.FC<CookbookCardProps> = ({ cookbook, bgColor })
2222
alt={cookbook.author.name}
2323
className="w-5 h-5 rounded-full mr-2"
2424
/>
25-
<span className="text-xs text-gray-600">{cookbook.author.name}</span>
25+
<span className="text-xs text-gray-600 dark:dark-theme-text-color">{cookbook.author.name}</span>
2626
</div>
2727
)}
2828
<div className="flex flex-wrap gap-1.5">
2929
{cookbook.tags.products.map(tag => (
3030
<span
3131
key={tag}
32-
className="px-1.5 py-0.5 text-[10px] text-gray-600 bg-white/50 rounded-full"
32+
className="px-1.5 py-0.5 text-[10px] text-gray-600 bg-white/50 rounded-full dark:dark-theme-text-color"
3333
>
3434
{generateDisplayTag(tag)}
3535
</span>

fern/components/cookbooks/Cookbooks.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ import { CookbookCard } from './CookbookCard';
55
import { TagCategories } from './types';
66
import { cookbooks } from './data/cookbooks';
77

8-
const CARD_COLORS = ['bg-[#EEF0EF] dark:bg-[#bcc2bf]', 'bg-[#FDF2F0] dark:bg-[#e9ada2]', 'bg-[#F8F1F9] dark:bg-[#d2b1d7]', 'bg-[#F0F2FB] dark:bg-[#a9b3e0]'];
8+
const CARD_COLORS = ['bg-[#EEF0EF] dark:bg-[#636363]', 'bg-[#FDF2F0] dark:bg-[#3b3b3b]', 'bg-[#F8F1F9] dark:bg-[#222222]', 'bg-[#F0F2FB] dark:bg-[#141414]'];
99

1010
export const Cookbooks: React.FC = () => {
1111
const [searchQuery, setSearchQuery] = useState('');

0 commit comments

Comments
 (0)