Skip to content

Commit 67034b8

Browse files
committed
style(reports): redesign new contributor badge for cohesive display
Rework the 'New Contributor' badge to display harmoniously with sponsor buttons on highlighted cards. Changes: - Move badge from absolute position (bottom-left) to inline flow (top) - Badge now appears above name, preventing overlap with sponsor button - Add gold gradient styling to sponsor buttons on highlighted cards - Buttons match the gold foil theme for visual cohesion - Improve hover effects with subtle transforms and shadows Result: Badge and sponsor button now look like a unified design system on new contributor cards.
1 parent f0299a6 commit 67034b8

File tree

1 file changed

+23
-4
lines changed

1 file changed

+23
-4
lines changed

src/components/GitHubProfileCard.module.css

Lines changed: 23 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -44,9 +44,9 @@
4444
}
4545

4646
.badge {
47-
position: absolute;
48-
bottom: 12px;
49-
left: 12px;
47+
display: inline-flex;
48+
align-items: center;
49+
gap: 0.25rem;
5050
background: linear-gradient(135deg, #ffd700, #ffed4e);
5151
color: #8b7500;
5252
padding: 0.35rem 0.75rem;
@@ -55,6 +55,8 @@
5555
font-weight: 600;
5656
box-shadow: 0 2px 8px rgba(255, 215, 0, 0.4);
5757
letter-spacing: 0.5px;
58+
margin-bottom: 0.5rem;
59+
width: fit-content;
5860
}
5961

6062
.avatar {
@@ -117,13 +119,30 @@
117119
border-radius: 6px;
118120
font-size: 0.9rem;
119121
font-weight: 500;
120-
transition: background 0.2s ease;
122+
transition: all 0.2s ease;
123+
box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
121124
}
122125

123126
.sponsorButton:hover {
124127
background: var(--ifm-color-primary-dark);
125128
color: white;
126129
text-decoration: none;
130+
transform: translateY(-1px);
131+
box-shadow: 0 4px 8px rgba(0, 0, 0, 0.15);
132+
}
133+
134+
/* Special styling for sponsor button on highlighted cards */
135+
.highlight .sponsorButton {
136+
background: linear-gradient(135deg, #ffd700, #ffed4e);
137+
color: #8b7500;
138+
font-weight: 600;
139+
box-shadow: 0 2px 8px rgba(255, 215, 0, 0.4);
140+
}
141+
142+
.highlight .sponsorButton:hover {
143+
background: linear-gradient(135deg, #ffed4e, #ffd700);
144+
color: #6b5900;
145+
box-shadow: 0 4px 12px rgba(255, 215, 0, 0.5);
127146
}
128147

129148
.loading,

0 commit comments

Comments
 (0)