chat interface

This commit is contained in:
2026-04-21 14:19:50 +02:00
parent caa9604704
commit 30e3dbb42b
11 changed files with 173 additions and 97 deletions

View File

@@ -26,10 +26,9 @@ function AnimatedCard({
className,
position = 0,
size = "default",
tlId = undefined,
scrollOnly = false,
...props
}: React.ComponentProps<"div"> & { size?: "default" | "sm", position: gsap.Position, tlId?: string, scrollOnly?: boolean }) {
}: React.ComponentProps<"div"> & { size?: "default" | "sm", position?: gsap.Position, scrollOnly?: boolean }) {
const gsapContext = useGsapContext()
const ref = useRef<HTMLDivElement | null>(null)
useGSAP(() => {
@@ -47,7 +46,7 @@ function AnimatedCard({
console.log(isInView)
const fromVars = { x: -100, opacity: 0, duration: 0.5 }
if (isInView && !scrollOnly) {
gsapContext?.addAnimation(gsap.from(ref.current, fromVars), position, tlId)
gsapContext?.addAnimation(gsap.from(ref.current, fromVars), position)
} else {
gsap.from(ref.current,
{