This component no longer exists. It was in PaceUI GSAP’s manifest when we first indexed it and is not there now — the registry served its inventory on 2026-08-06 and this item was not on it. The install command below will fail. It is kept here because a tutorial somewhere still tells people to run it.
Tilt Card
paceui-gsap/tilt-cardRemovedComponent
Interactive 3D tilt card that responds to cursor, adds depth and motion
Live preview
live · rendered by the registry
Rendered by PaceUI GSAP on their own page — this is the component running, not a screenshot of it.Install it
npx shadcn@latest add https://gsap.paceui.com/r/tilt-card.jsonSource
1"use client";23import { ComponentProps, useRef } from "react";45import { useGSAP } from "@gsap/react";6import gsap from "gsap";78import { cn } from "@/lib/utils";910type TiltCardProps = {11 maxTilt?: number;12 highlightClassName?: string;13 wrapperClassName?: string;14} & ComponentProps<"div">;1516export const TiltCard = ({17 children,18 highlightClassName,19 className,20 wrapperClassName,21 maxTilt = 10,22 ...props23}: TiltCardProps) => {24 const containerRef = useRef<HTMLDivElement | null>(null);25 const cardRef = useRef<HTMLDivElement | null>(null);26 const highlightRef = useRef<HTMLDivElement | null>(null);2728 useGSAP(29 () => {30 const container = containerRef.current;31 const card = cardRef.current;32 const highlight = highlightRef.current;33 if (!container || !card || !highlight) return;3435 const handleMouseLeave = () => {36 gsap.to(card, {37 rotateX: 0,38 rotateY: 0,39 duration: 0.6,40 ease: "power3.out",41 });42 };4344 const handleMouseMove = (e: MouseEvent) => {45 const bounds = card.getBoundingClientRect();46 const offsetX = e.clientX - bounds.left;47 const offsetY = e.clientY - bounds.top;48 const centerX = bounds.width / 2;49 const centerY = bounds.height / 2;50 const percentX = (offsetX - centerX) / centerX;51 const percentY = (offsetY - centerY) / centerY;5253 gsap.to(card, {54 rotateY: percentX * maxTilt,55 rotateX: -percentY * maxTilt,56 duration: 0.3,57 ease: "power3.out",58 });59 gsap.to(highlight, {60 left: bounds.width - offsetX + "px",61 top: bounds.height - offsetY + "px",62 duration: 0.3,63 ease: "power3.out",64 });65 };6667 container.addEventListener("mousemove", handleMouseMove);68 container.addEventListener("mouseleave", handleMouseLeave);6970 return () => {71 container.removeEventListener("mousemove", handleMouseMove);72 container.removeEventListener("mouseleave", handleMouseLeave);73 };74 },75 { scope: containerRef },76 );7778 return (79// … truncated
What it pulls in
npm packages
