11'use client' ;
2- import React , { useState } from 'react' ;
2+ import React , { useRef , useState } from 'react' ;
33import { motion } from 'framer-motion' ;
4- import { Link } from 'react-router-dom' ;
4+ import { useCursor } from '../Cursor' ;
5+ import { Box , Link } from '@chakra-ui/react' ;
56
6- const PinContainer = ( {
7+ const ThreeDPin = ( {
78 children,
89 title,
910 href,
@@ -28,7 +29,8 @@ const PinContainer = ({
2829 className = { 'relative group/pin z-50 cursor-pointer' }
2930 onMouseEnter = { onMouseEnter }
3031 onMouseLeave = { onMouseLeave }
31- to = { href ?? '/' }
32+ href = { href }
33+ isExternal
3234 >
3335 < div
3436 style = { {
@@ -51,31 +53,26 @@ const PinContainer = ({
5153 ) ;
5254} ;
5355
54- export const PinPerspective = ( {
55- title,
56- href,
57- } : {
58- title ?: string ;
59- href ?: string ;
60- } ) => {
56+ const PinPerspective = ( { title, href } : { title ?: string ; href ?: string } ) => {
6157 return (
62- < motion . div className = "pointer-events-none w-96 h-80 flex items-center justify-center opacity-0 group-hover/pin:opacity-100 z-[60] transition duration-500" >
58+ < motion . div className = "pointer-events-none w-96 h-96 flex items-center justify-center opacity-0 group-hover/pin:opacity-100 z-[60] transition duration-500" >
6359 < div className = " w-full h-full -mt-7 flex-none inset-0" >
6460 < div className = "absolute top-0 inset-x-0 flex justify-center" >
6561 < a
6662 href = { href }
67- target = { '_blank' }
6863 className = "relative flex space-x-2 items-center z-10 rounded-full bg-zinc-950 py-0.5 px-4 ring-1 ring-white/10 "
69- rel = "noreferrer"
64+ target = "_blank"
65+ rel = "noopener noreferrer"
66+ onClick = { ( ) => {
67+ console . log ( 'onClick' ) ;
68+ } }
7069 >
7170 < span className = "relative z-20 text-white text-xs font-bold inline-block py-0.5" >
7271 { title }
7372 </ span >
74-
75- < span className = "absolute -bottom-0 left-[1.125rem] h-px w-[calc(100%-2.25rem)] bg-gradient-to-r from-emerald-400/0 via-emerald-400/90 to-emerald-400/0 transition-opacity duration-500 group-hover/btn:opacity-40" > </ span >
73+ < span className = "absolute -bottom-0 left-[1.125rem] h-px w-[calc(100%-2.25rem)] bg-gradient-to-r from-emerald-400/0 via-violet-400/90 to-emerald-400/0 transition-opacity duration-500 group-hover/btn:opacity-40" > </ span >
7674 </ a >
7775 </ div >
78-
7976 < div
8077 style = { {
8178 perspective : '1000px' ,
@@ -158,4 +155,4 @@ export const PinPerspective = ({
158155 ) ;
159156} ;
160157
161- export default PinContainer ;
158+ export default ThreeDPin ;
0 commit comments