@@ -125,9 +125,11 @@ const CodevCard = ({ codev, color }: Props) => {
125125 onMouseEnter = { ( ) => setHovered ( true ) }
126126 onMouseLeave = { ( ) => setHovered ( false ) }
127127 >
128- < div
129- onClick = { ( ) => window . location . href = `https://www.codebility.tech/profiles/${ codev . id } ` }
130- className = "group relative flex h-full w-full flex-col items-center justify-between rounded-lg border border-white/20 bg-white/10 p-4 shadow-2xl backdrop-blur-md transition-all duration-300 cursor-pointer hover:bg-white/20 hover:scale-[1.02] dark:border-white/10 dark:bg-white/5 dark:hover:bg-white/10"
128+ < div
129+ onClick = { ( ) =>
130+ ( window . location . href = `https://www.codebility.tech/profiles/${ codev . id } ` )
131+ }
132+ className = "group relative flex h-full w-full cursor-pointer flex-col items-center justify-between rounded-lg border border-white/20 bg-white/10 p-4 shadow-2xl backdrop-blur-md transition-all duration-300 hover:scale-[1.02] hover:bg-white/20 dark:border-white/10 dark:bg-white/5 dark:hover:bg-white/10"
131133 >
132134 { /* Background decoration */ }
133135 < div className = "from-customBlue-50/30 dark:from-customBlue-950/10 absolute inset-0 bg-gradient-to-br to-purple-50/30 opacity-0 transition-opacity duration-300 group-hover:opacity-100 dark:to-purple-950/10" />
@@ -202,7 +204,11 @@ const CodevCard = ({ codev, color }: Props) => {
202204 < Tooltip delayDuration = { 100 } >
203205 < TooltipTrigger asChild >
204206 { /* Line 217: Added stopPropagation to prevent card click when button is clicked */ }
205- < Link href = { `/profiles/${ codev . id } ` } target = "_blank" onClick = { ( e ) => e . stopPropagation ( ) } >
207+ < Link
208+ href = { `/profiles/${ codev . id } ` }
209+ target = "_blank"
210+ onClick = { ( e ) => e . stopPropagation ( ) }
211+ >
206212 < Button
207213 variant = "outline"
208214 size = "icon"
@@ -241,10 +247,17 @@ const CodevCard = ({ codev, color }: Props) => {
241247 />
242248 ) : null }
243249 </ div >
244- < CodevHireCodevButton codevId = { codev . id } hovered = { hovered } />
250+ < div
251+ className = "relative z-20"
252+ onMouseEnter = { ( e ) => e . stopPropagation ( ) }
253+ onMouseLeave = { ( e ) => e . stopPropagation ( ) }
254+ onClick = { ( e ) => e . stopPropagation ( ) }
255+ >
256+ < CodevHireCodevButton codevId = { codev . id } />
257+ </ div >
245258 </ div >
246259 </ div >
247260 ) ;
248261} ;
249262
250- export default CodevCard ;
263+ export default CodevCard ;
0 commit comments