Skip to content

Commit 65b4767

Browse files
committed
colors.
1 parent 7d19297 commit 65b4767

File tree

2 files changed

+6
-3
lines changed

2 files changed

+6
-3
lines changed

src/components/PostItem.js

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,9 +19,10 @@ const PostItem = ({ slug, title, date, updatedDate, category }) => {
1919

2020
const categoryBadgeColorStyle = { backgroundColor: category === 'dev' ? 'var(--color-dev-badge)' : 'var(--color-takes-badge)' };
2121
const postBackgroundColorClass = category === 'dev' ? 'bg-dev-card-bg' : 'bg-takes-card-bg';
22+
const postHoverBackgroundColorClass = category === 'dev' ? 'hover:bg-dev-card-bg-hover' : 'hover:bg-takes-card-bg-hover';
2223

2324
return (
24-
<Link to={`/blog/${slug}`} className={`block p-8 my-4 border border-gray-700/50 rounded-lg shadow-lg cursor-pointer transition-colors group ${postBackgroundColorClass} hover:bg-red-500/10`}>
25+
<Link to={`/blog/${slug}`} className={`block p-8 my-4 border border-gray-700/50 rounded-lg shadow-lg cursor-pointer transition-colors group ${postBackgroundColorClass} ${postHoverBackgroundColorClass}`}>
2526
<article>
2627
<div className="flex items-center">
2728
<p className="text-sm text-gray-400">{formattedDate}</p>

tailwind.config.js

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -28,8 +28,10 @@ module.exports = {
2828
music: '#a855f7',
2929
series: '#ec4899',
3030
'title-hover': '#fdd4a6',
31-
'dev-card-bg': 'rgba(68, 64, 60, 0.1)',
32-
'takes-card-bg': 'rgba(6, 95, 70, 0.15)',
31+
'dev-card-bg': 'rgba(68, 64, 60, 0.1)', // stone-900/10
32+
'dev-card-bg-hover': 'rgba(120, 113, 108, 0.2)', // stone-500/20
33+
'takes-card-bg': 'rgba(6, 95, 70, 0.15)', // emerald-900/15
34+
'takes-card-bg-hover': 'rgba(16, 185, 129, 0.2)', // emerald-500/20
3335
},
3436
typography: (theme) => ({
3537
dark: {

0 commit comments

Comments
 (0)