{
  "$schema": "https://ui.shadcn.com/schema/registry-item.json",
  "name": "mask-reveal-up",
  "title": "Mask Reveal Up",
  "description": "Lines reveal upward with a soft masked feel and compact stagger.",
  "dependencies": ["remotion"],
  "files": [
    {
      "path": "registry/remocn/mask-reveal-up/index.tsx",
      "content": "\"use client\";\n\nimport { Easing, interpolate, useCurrentFrame, useVideoConfig } from \"remotion\";\n\nexport interface MaskRevealUpProps {\n  text: string;\n  distance?: number;\n  fontSize?: number;\n  color?: string;\n  fontWeight?: number;\n  speed?: number;\n  className?: string;\n}\n\nexport function MaskRevealUp({\n  text,\n  distance = 30,\n  fontSize = 72,\n  color = \"#171717\",\n  fontWeight = 600,\n  speed = 1,\n  className,\n}: MaskRevealUpProps) {\n  const frame = useCurrentFrame() * speed;\n  const { durationInFrames } = useVideoConfig();\n\n  const lines = text.split(\"\\n\");\n\n  const enterDur = 23;\n  const enterTravel = 11;\n  const exitDur = 16;\n  const exitTravelFrom = 8;\n  const enterStagger = 3;\n  const exitStagger = 2;\n\n  const enterEasing = Easing.bezier(0.22, 1, 0.36, 1);\n  const exitEasing = Easing.bezier(0.64, 0, 0.78, 0);\n\n  const enterEnd = enterDur + (lines.length - 1) * enterStagger;\n  const exitStart = Math.max(\n    enterEnd,\n    durationInFrames - exitDur - (lines.length - 1) * exitStagger,\n  );\n\n  return (\n    <div\n      style={{\n        position: \"absolute\",\n        inset: 0,\n        display: \"flex\",\n        alignItems: \"center\",\n        justifyContent: \"center\",\n        background: \"transparent\",\n      }}\n    >\n      <span\n        className={className}\n        style={{\n          fontSize,\n          fontWeight,\n          color,\n          letterSpacing: \"-0.03em\",\n          lineHeight: 1.1,\n          textAlign: \"center\",\n          fontFamily:\n            \"var(--font-geist-sans), -apple-system, BlinkMacSystemFont, sans-serif\",\n        }}\n      >\n        {lines.map((line, i) => {\n          const enterLocal = frame - i * enterStagger;\n          const exitLocal = frame - exitStart - i * exitStagger;\n\n          const enterP = interpolate(enterLocal, [0, enterDur], [0, 1], {\n            extrapolateLeft: \"clamp\",\n            extrapolateRight: \"clamp\",\n            easing: enterEasing,\n          });\n\n          const exitP = interpolate(exitLocal, [0, exitDur], [0, 1], {\n            extrapolateLeft: \"clamp\",\n            extrapolateRight: \"clamp\",\n            easing: exitEasing,\n          });\n\n          const opacity = enterP * (1 - exitP);\n\n          const yEnter = interpolate(\n            enterLocal,\n            [0, enterTravel],\n            [distance, 0],\n            {\n              extrapolateLeft: \"clamp\",\n              extrapolateRight: \"clamp\",\n              easing: enterEasing,\n            },\n          );\n\n          const yExit = interpolate(\n            exitLocal,\n            [exitTravelFrom, exitDur],\n            [0, -22],\n            {\n              extrapolateLeft: \"clamp\",\n              extrapolateRight: \"clamp\",\n              easing: exitEasing,\n            },\n          );\n\n          const y = yEnter + yExit;\n\n          const blurEnter = interpolate(enterLocal, [0, enterDur], [6, 0], {\n            extrapolateLeft: \"clamp\",\n            extrapolateRight: \"clamp\",\n            easing: enterEasing,\n          });\n\n          const blurExit = interpolate(exitLocal, [0, exitDur], [0, 6], {\n            extrapolateLeft: \"clamp\",\n            extrapolateRight: \"clamp\",\n            easing: exitEasing,\n          });\n\n          const blur = blurEnter + blurExit;\n\n          return (\n            <span\n              key={i}\n              style={{\n                display: \"block\",\n                transformOrigin: \"50% 50%\",\n                opacity,\n                translate: `0 ${y}px`,\n                filter: `blur(${blur}px)`,\n              }}\n            >\n              {line}\n            </span>\n          );\n        })}\n      </span>\n    </div>\n  );\n}\n",
      "type": "registry:component",
      "target": "components/remocn/mask-reveal-up.tsx"
    }
  ],
  "type": "registry:component"
}
