import { memo } from "react"; import type { GsapAnimation } from "@hyperframes/core/gsap-parser"; import { Film } from "../../icons/SystemIcons"; import { Section } from "./propertyPanelPrimitives"; import type { GsapAnimationEditCallbacks } from "./gsapAnimationCallbacks"; import { GsapAnimationList } from "./GsapAnimationList"; interface GsapAnimationSectionProps extends GsapAnimationEditCallbacks { elementId: string; animations: GsapAnimation[]; multipleTimelines?: boolean; unsupportedTimelinePattern?: boolean; onAddAnimation: (method: "to" | "from" | "set" | "fromTo") => void; } export const GsapAnimationSection = memo(function GsapAnimationSection({ elementId, animations, multipleTimelines, unsupportedTimelinePattern, onAddAnimation, ...callbacks }: GsapAnimationSectionProps) { return ( }> {multipleTimelines && (
This file has multiple GSAP timelines. Animation editing is disabled to prevent data loss — consolidate into a single timeline to enable editing.
)} {unsupportedTimelinePattern && (This timeline uses a computed key (window.__timelines[variable]) the editor can't resolve statically. Use a string-literal key (window.__timelines["id"]) or a variable declaration (const tl = gsap.timeline()) to enable editing.
)} {multipleTimelines || unsupportedTimelinePattern ? null : (