Production-ready animations, transitions, backgrounds, and scenes for Remotion
TypeScript ai-agentsclaude-codedemo-videomcpmcp-servermodel-context-protocolmotion-designproduct-demoreactremotionshadcnvideo
{
"$schema": "https://ui.shadcn.com/schema/registry-item.json",
"name": "prompt-swell",
"title": "Prompt Swell",
"description": "A prompt swells into a builder that generates a pricing page with checklist and waitlist form.",
"dependencies": ["remotion", "@remotion/google-fonts"],
"registryDependencies": ["@remocn/gsh"],
"files": [
{
"path": "registry/remocn/prompt-swell/index.tsx",
"content": "\"use client\";\n\nimport { loadFont as loadGeist } from \"@remotion/google-fonts/Geist\";\nimport { loadFont as loadMono } from \"@remotion/google-fonts/GeistMono\";\nimport { loadFont as loadManrope } from \"@remotion/google-fonts/Manrope\";\nimport {\n AbsoluteFill,\n Easing,\n Img,\n interpolate,\n spring,\n staticFile,\n useCurrentFrame,\n useVideoConfig,\n} from \"remotion\";\nimport type { GradientParams } from \"@/lib/remocn/gsh/gradient-engine\";\nimport { GshGround } from \"@/lib/remocn/gsh/gsh-ground\";\nimport type { GshPresetId } from \"@/lib/remocn/gsh/presets\";\n\nconst geist = loadGeist(\"normal\", {\n weights: [\"300\", \"400\"],\n subsets: [\"latin\"],\n});\nconst mono = loadMono(\"normal\", { weights: [\"400\"], subsets: [\"latin\"] });\nconst manrope = loadManrope(\"normal\", {\n weights: [\"600\"],\n subsets: [\"latin\"],\n});\n\nconst ENTER = Easing.bezier(0.32, 0.72, 0, 1);\nconst RISE = Easing.bezier(0.22, 1, 0.36, 1);\nconst EXIT = Easing.bezier(0.55, 0, 1, 0.45);\nconst MOVE = Easing.bezier(0.65, 0, 0.35, 1);\nconst CAM = Easing.bezier(0.87, 0, 0.13, 1);\nconst HEAVY = { mass: 1, damping: 26, stiffness: 120 };\nconst CARD = { mass: 0.8, damping: 18, stiffness: 160 };\nconst CHIP = { mass: 0.5, damping: 12, stiffness: 200 };\n\nconst REMOCN_R_PATH =\n \"M 0.01 0.81 C 0.01 1.73, 0.36 2.79, 1.09 4.13 C 4.91 11.04, 13.45 17.16, 21.7 18.9 C 22.94 19.16, 23.18 19.16, 51.39 19.27 C 76.07 19.36, 80.02 19.4, 81.32 19.57 C 89.89 20.69, 96.2 24.68, 99.38 31.01 C 103.19 38.56, 102.53 50.1, 97.91 57.07 C 94.66 61.96, 89.68 64.99, 83.26 66 C 82.81 66.07, 70.18 66.83, 55.2 67.69 C 24.82 69.43, 27.03 69.23, 24.18 70.4 C 19.9 72.15, 14.84 75.7, 10.65 79.89 C 4.86 85.68, 1.3 91.91, 0.25 98.13 C 0.12 98.85, 0.08 103.13, 0.04 116.66 L 0 134.26 9.5 134.26 L 19 134.26 19.05 119.41 C 19.1 103.27, 19.08 103.82, 19.82 101.04 C 21.79 93.65, 27.86 88.75, 36.45 87.63 C 37.23 87.53, 39.41 87.5, 43.57 87.53 C 50.12 87.59, 50.75 87.65, 53.22 88.45 C 56.61 89.56, 59.67 91.86, 62.02 95.07 C 62.52 95.76, 69.35 103.85, 77.2 113.07 C 85.04 122.28, 91.63 130.04, 91.85 130.32 C 92.07 130.59, 92.5 131.34, 92.82 131.97 C 93.52 133.35, 94.11 133.93, 95.06 134.13 C 95.5 134.23, 98.97 134.26, 106.36 134.23 L 117.01 134.19 100.82 113.07 C 91.91 101.45, 84.52 91.78, 84.39 91.57 C 83.36 89.89, 83.66 87.53, 85.09 86 C 85.79 85.25, 86.36 84.94, 88.07 84.38 C 96.18 81.72, 104.15 76.62, 109.97 70.36 C 120.59 58.93, 124.06 44.32, 119.44 30.43 C 114.59 15.81, 101.93 4.02, 87.64 0.83 C 83.93 0.01, 88.09 0.08, 41.85 0.04 L 0.01 0 0.01 0.81 Z\";\n\nfunction RemocnR({ height, color }: { height: number; color: string }) {\n return (\n <svg\n viewBox=\"0 0 124.06 134.26\"\n height={height}\n width={(height * 124.06) / 134.26}\n style={{ display: \"block\" }}\n aria-hidden\n >\n <path fill={color} d={REMOCN_R_PATH} />\n </svg>\n );\n}\n\nfunction RemocnLogo({ fontSize, color }: { fontSize: number; color: string }) {\n return (\n <div\n style={{\n display: \"flex\",\n alignItems: \"baseline\",\n color,\n fontFamily: manrope.fontFamily,\n fontWeight: 600,\n fontSize,\n letterSpacing: \"-0.025em\",\n lineHeight: 1,\n }}\n >\n <svg\n viewBox=\"0 0 124.06 134.26\"\n style={{ height: \"0.76em\", width: \"auto\" }}\n aria-hidden\n >\n <path fill=\"currentColor\" d={REMOCN_R_PATH} />\n </svg>\n <span style={{ marginLeft: \"0.04em\" }}>emocn</span>\n </div>\n );\n}\n\nconst B = {\n card: -10,\n type: 0,\n armed: 30,\n press: 36,\n swell: 40,\n chrome: 48,\n hero: 52,\n tick1: 66,\n scroll1: 72,\n plans: 76,\n tick2: 90,\n scroll2: 96,\n tick3: 104,\n publish: 114,\n toast: 120,\n end: 156,\n};\n\nconst ramp = (f: number, start: number, dur: number, easing = ENTER) =>\n interpolate(f, [start, start + dur], [0, 1], {\n extrapolateLeft: \"clamp\",\n extrapolateRight: \"clamp\",\n easing,\n });\n\nconst mix = (a: number, b: number, t: number) => a + (b - a) * t;\n\nconst dip = (f: number, at: number, depth: number) =>\n 1 - depth * ramp(f, at, 3, MOVE) + depth * ramp(f, at + 3, 9, ENTER);\n\nconst line = (color: string, w = 1.5) => ({\n fill: \"none\",\n stroke: color,\n strokeWidth: w,\n strokeLinecap: \"round\" as const,\n strokeLinejoin: \"round\" as const,\n});\n\nfunction DirBlur({ id, y }: { id: string; y: number }) {\n return (\n <svg width={0} height={0} style={{ position: \"absolute\" }} aria-hidden>\n <filter id={id} x=\"-10%\" y=\"-20%\" width=\"120%\" height=\"140%\">\n <feGaussianBlur stdDeviation={`${y * 0.4} ${y}`} />\n </filter>\n </svg>\n );\n}\n\nexport interface PromptSwellTier {\n name: string;\n price: string;\n features?: string[];\n}\n\nexport interface PromptSwellProps {\n theme?: \"dark\" | \"light\";\n accent?: string;\n prompt?: string;\n src?: string;\n url?: string;\n steps?: string[];\n tiers?: PromptSwellTier[];\n ground?: GshPresetId;\n groundParams?: Partial<GradientParams>;\n}\n\nconst DEFAULT_FEATURES = [\n [\"12 components\", \"720p renders\", \"Community support\"],\n [\"Every component\", \"4K renders\", \"Studio templates\"],\n [\"Shared library\", \"Brand presets\", \"Priority support\"],\n];\n\nexport function PromptSwell({\n theme = \"dark\",\n accent = \"#ff7a3d\",\n prompt = \"Build a launch page for our video kit with a hero, pricing and a waitlist\",\n src = staticFile(\"studio.png\"),\n url = \"preview.remocn.dev\",\n steps = [\"Hero with product shot\", \"Pricing tiers\", \"Waitlist form\"],\n tiers = [\n { name: \"Free\", price: \"$0\" },\n { name: \"Pro\", price: \"$19\" },\n { name: \"Team\", price: \"$49\" },\n ],\n ground,\n groundParams,\n}: PromptSwellProps) {\n const frame = useCurrentFrame();\n const { width, height, fps } = useVideoConfig();\n const dark = theme === \"dark\";\n const portrait = height > width * 1.2;\n const stageW = portrait ? 720 : 1280;\n const stageH = portrait ? 1280 : 720;\n const k = width / stageW;\n\n const ink = dark ? \"#f2f1f6\" : \"#17161b\";\n const muted = dark ? \"rgba(236,234,244,0.56)\" : \"rgba(23,22,27,0.54)\";\n const faint = dark ? \"rgba(236,234,244,0.32)\" : \"rgba(23,22,27,0.32)\";\n const hair = dark ? \"rgba(255,255,255,0.09)\" : \"rgba(23,22,27,0.09)\";\n const fill = dark ? \"rgba(255,255,255,0.05)\" : \"rgba(23,22,27,0.04)\";\n const surface = dark\n ? \"linear-gradient(180deg, rgba(30,29,38,0.9) 0%, rgba(16,15,21,0.95) 100%)\"\n : \"linear-gradient(180deg, #ffffff 0%, #fbfaf8 100%)\";\n const page = dark ? \"#0b0b0f\" : \"#ffffff\";\n const pageCard = dark ? \"#131319\" : \"#ffffff\";\n const shadow = dark\n ? \"inset 0 1px 0 rgba(255,255,255,0.07), 0 1px 2px rgba(0,0,0,0.5), 0 16px 36px rgba(0,0,0,0.35), 0 60px 120px rgba(4,0,16,0.6)\"\n : \"inset 0 1px 0 #ffffff, 0 1px 2px rgba(30,30,60,0.06), 0 16px 34px rgba(30,30,60,0.08), 0 56px 110px rgba(30,30,60,0.16)\";\n\n const typeRate = 2.4;\n const typed = prompt.slice(\n 0,\n Math.max(0, Math.floor((frame - B.type) * typeRate)),\n );\n const typing = typed.length < prompt.length;\n const caretOn = typing || Math.floor(frame / 8) % 2 === 0;\n\n const cardW = portrait ? 660 : 880;\n const cardH = portrait ? 260 : 206;\n const winW = portrait ? 680 : 1196;\n const winH = portrait ? 1180 : 664;\n const sw = spring({\n frame: frame - B.swell,\n fps,\n config: HEAVY,\n durationInFrames: 30,\n });\n const swPrev = spring({\n frame: frame - 1 - B.swell,\n fps,\n config: HEAVY,\n durationInFrames: 30,\n });\n const W = mix(cardW, winW, sw);\n const H = mix(cardH, winH, sw);\n const swBlur = Math.min(6, Math.abs(sw - swPrev) * (winH - cardH) * 0.12);\n const cardIn = spring({ frame: frame - B.card, fps, config: CARD });\n const promptOut = ramp(frame, B.swell, 9, EXIT);\n const win = ramp(frame, B.chrome - 4, 14);\n\n const sendFill = ramp(frame, B.armed, 6);\n const sendDip = dip(frame, B.press, 0.14);\n\n const camPull = ramp(frame, B.press - 2, 32, CAM);\n const settle = spring({ frame: frame + 10, fps, config: HEAVY });\n const push =\n mix(portrait ? 1.08 : 1.3, 1, camPull) +\n 0.03 * ramp(frame, B.chrome, B.end - B.chrome, Easing.linear);\n const rotX =\n mix(12, 3, settle) + 4 * Math.sin(Math.PI * camPull) - 1.5 * camPull;\n const rotY = mix(-12, -3, settle) + 2 * camPull;\n\n const chromeH = 52;\n const chatW = portrait ? winW : 340;\n const chatH = portrait ? 300 : winH - chromeH;\n const view = portrait\n ? {\n x: 14,\n y: chromeH + chatH,\n w: winW - 28,\n h: winH - chromeH - chatH - 14,\n }\n : {\n x: chatW,\n y: chromeH + 14,\n w: winW - chatW - 14,\n h: winH - chromeH - 28,\n };\n const PW = view.w;\n const navH = 60;\n const heroH = portrait ? 600 : 560;\n const pricingTop = navH + heroH;\n const pricingH = portrait ? 480 : 470;\n const waitTop = pricingTop + pricingH;\n const waitH = 200;\n const pageEnd = waitTop + waitH;\n const s1 = spring({ frame: frame - B.scroll1, fps, config: HEAVY });\n const s1Prev = spring({ frame: frame - 1 - B.scroll1, fps, config: HEAVY });\n const s2 = spring({ frame: frame - B.scroll2, fps, config: HEAVY });\n const scrollA = pricingTop + 2;\n const scrollB = Math.max(\n scrollA,\n Math.min(pricingTop + 110, pageEnd - view.h + 30),\n );\n const scrollY = s1 * scrollA + s2 * (scrollB - scrollA);\n const scrollBlur = Math.min(5, Math.abs(s1 - s1Prev) * scrollA * 0.06);\n\n const tick = (i: number) => ramp(frame, [B.tick1, B.tick2, B.tick3][i], 8);\n const heroIn = ramp(frame, B.hero, 18, RISE);\n const heroImg = ramp(frame, B.hero + 6, 24, RISE);\n const planIn = (i: number) =>\n spring({ frame: frame - B.plans - i * 4, fps, config: CARD });\n const waitIn = ramp(frame, B.scroll2 + 2, 14);\n const pubDip = dip(frame, B.publish, 0.1);\n const toast = spring({ frame: frame - B.toast, fps, config: CHIP });\n const live = frame >= B.toast;\n\n const resolvedPreset: GshPresetId | undefined = ground;\n const resolvedParams: Partial<GradientParams> | undefined =\n groundParams ??\n (ground\n ? undefined\n : dark\n ? {\n kind: \"mist\",\n background: \"#0a0810\",\n colors: [\"#e9b8ff\", \"#ff9e6b\", \"#6c4dff\", \"#1a1030\"],\n }\n : {\n kind: \"spectrum\",\n background: \"#f2f1ee\",\n colors: [\"#ffb38a\", \"#ff7a3d\", \"#3552ff\", \"#b08cff\"],\n });\n\n const sendButton = (\n <div\n style={{\n width: 44,\n height: 44,\n borderRadius: 22,\n position: \"relative\",\n background: fill,\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n transform: `scale(${sendDip})`,\n }}\n >\n <div\n style={{\n position: \"absolute\",\n inset: 0,\n borderRadius: 22,\n background: accent,\n opacity: sendFill,\n boxShadow: `inset 0 1px 0 rgba(255,255,255,0.35), 0 6px 16px color-mix(in oklab, ${accent} 40%, transparent)`,\n }}\n />\n <svg\n viewBox=\"0 0 24 24\"\n width={20}\n height={20}\n style={{ position: \"relative\" }}\n aria-hidden\n >\n <path\n d=\"M12 19V5M6 11l6-6 6 6\"\n {...line(sendFill > 0.5 ? \"#fff\" : muted, 1.8)}\n />\n </svg>\n </div>\n );\n\n const check = (t: number, size: number, on: string, off: string) => (\n <div\n style={{\n width: size,\n height: size,\n borderRadius: size / 2,\n flexShrink: 0,\n border: `1.5px solid ${t > 0.05 ? \"transparent\" : off}`,\n background: t > 0.05 ? on : \"transparent\",\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n transform: `scale(${t > 0 ? 0.8 + 0.2 * t + 0.18 * Math.sin(Math.PI * t) : 1})`,\n }}\n >\n <svg\n viewBox=\"0 0 24 24\"\n width={size * 0.62}\n height={size * 0.62}\n aria-hidden\n >\n <path\n d=\"m6 12.5 4 4 8-9\"\n {...line(dark ? \"#0b0b0f\" : \"#ffffff\", 2.6)}\n strokeDasharray={20}\n strokeDashoffset={20 * (1 - t)}\n />\n </svg>\n </div>\n );\n\n const planGap = portrait ? 10 : 16;\n const planPad = portrait ? 16 : 22;\n const planW = (PW - (portrait ? 40 : 64) - planGap * 2) / 3;\n const planH = portrait ? 330 : 312;\n\n const plan = (tier: PromptSwellTier, i: number) => {\n const p = planIn(i);\n const hot = i === 1;\n const feats = tier.features ?? DEFAULT_FEATURES[i % 3];\n return (\n <div\n key={tier.name}\n style={{\n position: \"relative\",\n width: planW,\n height: planH,\n borderRadius: 16,\n background: pageCard,\n border: `1px solid ${hot ? `color-mix(in oklab, ${accent} 55%, transparent)` : hair}`,\n boxShadow: hot\n ? `0 0 0 4px color-mix(in oklab, ${accent} 10%, transparent), 0 16px 40px rgba(0,0,0,${dark ? 0.4 : 0.08})`\n : `0 1px 2px rgba(0,0,0,${dark ? 0.3 : 0.04}), 0 10px 24px rgba(0,0,0,${dark ? 0.25 : 0.05})`,\n padding: planPad,\n boxSizing: \"border-box\",\n display: \"flex\",\n flexDirection: \"column\",\n opacity: frame >= B.plans + i * 4 ? Math.min(1, p * 1.6) : 0,\n transform: `translateY(${mix(40, 0, p)}px) scale(${mix(0.94, 1, p)})`,\n }}\n >\n <div style={{ display: \"flex\", alignItems: \"center\", gap: 8 }}>\n <span style={{ fontSize: 17, color: ink }}>{tier.name}</span>\n {hot ? (\n <span\n style={{\n height: 22,\n padding: \"0 8px\",\n borderRadius: 6,\n background: `color-mix(in oklab, ${accent} 16%, transparent)`,\n color: accent,\n fontSize: 12,\n letterSpacing: \"0.06em\",\n display: \"flex\",\n alignItems: \"center\",\n fontFamily: mono.fontFamily,\n }}\n >\n POPULAR\n </span>\n ) : null}\n </div>\n <div\n style={{\n display: \"flex\",\n alignItems: \"baseline\",\n gap: 6,\n marginTop: 14,\n }}\n >\n <span\n style={{\n fontSize: portrait ? 36 : 44,\n fontWeight: 300,\n color: ink,\n letterSpacing: \"-0.045em\",\n lineHeight: 1,\n }}\n >\n {tier.price}\n </span>\n <span style={{ fontSize: 15, color: muted }}>/mo</span>\n </div>\n <div style={{ fontSize: 14, color: muted, marginTop: 8 }}>\n {i === 0 ? \"Free forever\" : \"Billed monthly\"}\n </div>\n <div style={{ height: 1, background: hair, margin: \"16px 0 14px\" }} />\n {feats.slice(0, 3).map((f) => (\n <div\n key={f}\n style={{\n display: \"flex\",\n alignItems: \"center\",\n gap: 8,\n fontSize: portrait ? 14 : 15,\n color: ink,\n marginBottom: 10,\n whiteSpace: \"nowrap\",\n }}\n >\n <svg viewBox=\"0 0 24 24\" width={16} height={16} aria-hidden>\n <path\n d=\"m5 12.5 4.5 4.5L19 7.5\"\n {...line(hot ? accent : muted, 1.8)}\n />\n </svg>\n {f}\n </div>\n ))}\n <div style={{ flex: 1 }} />\n <div\n style={{\n height: 40,\n borderRadius: 10,\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n fontSize: 15,\n color: hot ? \"#fff\" : ink,\n background: hot ? accent : fill,\n border: hot ? \"none\" : `1px solid ${hair}`,\n boxShadow: hot ? \"inset 0 1px 0 rgba(255,255,255,0.3)\" : undefined,\n }}\n >\n {i === 0 ? \"Start free\" : i === 1 ? \"Upgrade to Pro\" : \"Contact us\"}\n </div>\n </div>\n );\n };\n\n const pageContent = (\n <div\n style={{\n position: \"absolute\",\n left: 0,\n top: 0,\n width: PW,\n transform: `translateY(${-scrollY}px)`,\n filter: scrollBlur > 0.4 ? \"url(#ps-scroll)\" : undefined,\n }}\n >\n <div\n style={{\n height: navH,\n display: \"flex\",\n alignItems: \"center\",\n padding: `0 ${portrait ? 20 : 32}px`,\n gap: portrait ? 16 : 26,\n borderBottom: `1px solid ${hair}`,\n opacity: heroIn,\n }}\n >\n <RemocnLogo fontSize={22} color={ink} />\n <span style={{ flex: 1 }} />\n {(portrait ? [\"Docs\"] : [\"Components\", \"Pricing\", \"Docs\"]).map((l) => (\n <span key={l} style={{ fontSize: 15, color: muted }}>\n {l}\n </span>\n ))}\n <span\n style={{\n height: 34,\n padding: \"0 14px\",\n borderRadius: 9,\n background: ink,\n color: page,\n fontSize: 15,\n display: \"flex\",\n alignItems: \"center\",\n }}\n >\n Join waitlist\n </span>\n </div>\n <div\n style={{\n height: heroH,\n position: \"relative\",\n display: \"flex\",\n flexDirection: \"column\",\n alignItems: \"center\",\n paddingTop: portrait ? 44 : 50,\n boxSizing: \"border-box\",\n }}\n >\n <div\n style={{\n height: 30,\n padding: \"0 12px\",\n borderRadius: 15,\n border: `1px solid ${hair}`,\n display: \"flex\",\n alignItems: \"center\",\n gap: 8,\n fontSize: 14,\n color: muted,\n opacity: heroIn,\n }}\n >\n <span\n style={{ width: 6, height: 6, borderRadius: 3, background: accent }}\n />\n Now in early access\n </div>\n <div style={{ overflow: \"hidden\", marginTop: 18, paddingBottom: 6 }}>\n <div\n style={{\n fontSize: portrait ? 40 : 50,\n fontWeight: 300,\n color: ink,\n letterSpacing: \"-0.045em\",\n lineHeight: 1.05,\n textAlign: \"center\",\n maxWidth: PW - 60,\n transform: `translateY(${mix(70, 0, heroIn)}px)`,\n }}\n >\n Launch videos, built from code.\n </div>\n </div>\n <div\n style={{\n fontSize: 17,\n color: muted,\n marginTop: 12,\n textAlign: \"center\",\n maxWidth: PW - 80,\n opacity: ramp(frame, B.hero + 4, 12),\n }}\n >\n Drop-in Remotion scenes you own and edit.\n </div>\n <div\n style={{\n position: \"absolute\",\n left: portrait ? 20 : 48,\n right: portrait ? 20 : 48,\n top: portrait ? 230 : 216,\n bottom: 0,\n borderRadius: \"16px 16px 0 0\",\n overflow: \"hidden\",\n border: `1px solid ${hair}`,\n borderBottom: \"none\",\n background: dark ? \"#08080b\" : \"#ecebe7\",\n boxShadow: `0 -10px 60px color-mix(in oklab, ${accent} ${dark ? 22 : 14}%, transparent)`,\n transform: `translateY(${mix(60, 0, heroImg)}px)`,\n opacity: Math.min(1, heroImg * 1.4),\n }}\n >\n <Img\n src={src}\n style={{\n width: \"100%\",\n height: \"100%\",\n objectFit: \"cover\",\n objectPosition: \"50% 0%\",\n filter: `blur(${mix(18, 0, heroImg)}px)`,\n transform: `scale(${mix(1.1, 1, heroImg)})`,\n }}\n />\n </div>\n </div>\n <div\n style={{\n height: pricingH,\n padding: `${portrait ? 40 : 44}px ${portrait ? 20 : 32}px 0`,\n boxSizing: \"border-box\",\n borderTop: `1px solid ${hair}`,\n }}\n >\n <div\n style={{\n fontSize: portrait ? 30 : 34,\n fontWeight: 300,\n color: ink,\n letterSpacing: \"-0.04em\",\n textAlign: \"center\",\n opacity: ramp(frame, B.scroll1 + 2, 12),\n }}\n >\n Simple pricing\n </div>\n <div\n style={{\n fontSize: 16,\n color: muted,\n textAlign: \"center\",\n marginTop: 6,\n opacity: ramp(frame, B.scroll1 + 4, 12),\n }}\n >\n Start free. Upgrade when you ship.\n </div>\n <div\n style={{\n display: \"flex\",\n gap: planGap,\n marginTop: 30,\n }}\n >\n {tiers.slice(0, 3).map(plan)}\n </div>\n </div>\n <div\n style={{\n height: waitH,\n padding: `36px ${portrait ? 20 : 32}px 0`,\n boxSizing: \"border-box\",\n display: \"flex\",\n flexDirection: \"column\",\n alignItems: \"center\",\n opacity: waitIn,\n transform: `translateY(${mix(24, 0, waitIn)}px)`,\n }}\n >\n <div\n style={{\n fontSize: 26,\n fontWeight: 300,\n color: ink,\n letterSpacing: \"-0.035em\",\n }}\n >\n Get the kit first\n </div>\n <div\n style={{\n display: \"flex\",\n gap: 8,\n marginTop: 18,\n width: Math.min(460, PW - 40),\n }}\n >\n <div\n style={{\n flex: 1,\n height: 46,\n borderRadius: 11,\n border: `1px solid ${hair}`,\n background: fill,\n display: \"flex\",\n alignItems: \"center\",\n padding: \"0 14px\",\n fontSize: 16,\n color: faint,\n }}\n >\n [email protected]\n </div>\n <div\n style={{\n height: 46,\n padding: \"0 18px\",\n borderRadius: 11,\n background: accent,\n color: \"#fff\",\n fontSize: 16,\n display: \"flex\",\n alignItems: \"center\",\n boxShadow: \"inset 0 1px 0 rgba(255,255,255,0.3)\",\n }}\n >\n Join waitlist\n </div>\n </div>\n </div>\n </div>\n );\n\n return (\n <AbsoluteFill style={{ fontFamily: geist.fontFamily, overflow: \"hidden\" }}>\n <GshGround\n preset={resolvedPreset}\n params={resolvedParams}\n timeOffset={2.5}\n timeScale={0.45}\n />\n <DirBlur id=\"ps-swell\" y={swBlur} />\n <DirBlur id=\"ps-scroll\" y={scrollBlur} />\n <div\n style={{\n position: \"absolute\",\n left: 0,\n top: 0,\n width: stageW,\n height: stageH,\n transform: `scale(${k})`,\n transformOrigin: \"0 0\",\n perspective: 2200,\n }}\n >\n <div\n style={{\n position: \"absolute\",\n left: stageW / 2,\n top: stageH / 2,\n width: 0,\n height: 0,\n transformStyle: \"preserve-3d\",\n transform: `scale(${push}) rotateX(${rotX}deg) rotateY(${rotY}deg)`,\n }}\n >\n <div\n style={{\n position: \"absolute\",\n left: -W / 2,\n top: -H / 2,\n width: W,\n height: H,\n borderRadius: mix(28, 18, sw),\n background: surface,\n border: `1px solid ${hair}`,\n boxShadow: shadow,\n overflow: \"hidden\",\n opacity: Math.min(1, cardIn * 1.5),\n transform: `translateY(${mix(50, 0, cardIn)}px)`,\n filter: swBlur > 0.4 ? \"url(#ps-swell)\" : undefined,\n }}\n >\n <div\n style={{\n position: \"absolute\",\n left: (W - cardW) / 2,\n top: (H - cardH) / 2,\n width: cardW,\n height: cardH,\n opacity: 1 - promptOut,\n transform: `scale(${mix(1, 1.1, promptOut)})`,\n }}\n >\n <div\n style={{\n position: \"absolute\",\n left: 28,\n right: 28,\n top: 24,\n fontSize: portrait ? 28 : 27,\n fontWeight: 300,\n lineHeight: 1.32,\n color: typed.length ? ink : faint,\n letterSpacing: \"-0.02em\",\n }}\n >\n {typed.length ? typed : \"Describe what you want to build\"}\n <span\n style={{\n display: \"inline-block\",\n width: 2,\n height: 30,\n marginLeft: 2,\n verticalAlign: \"-6px\",\n background: accent,\n opacity: caretOn ? 1 : 0,\n }}\n />\n </div>\n <div\n style={{\n position: \"absolute\",\n left: 18,\n right: 18,\n bottom: 16,\n height: 44,\n display: \"flex\",\n alignItems: \"center\",\n gap: 10,\n }}\n >\n <div\n style={{\n width: 40,\n height: 40,\n borderRadius: 20,\n border: `1px solid ${hair}`,\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n }}\n >\n <svg viewBox=\"0 0 24 24\" width={19} height={19} aria-hidden>\n <path d=\"M12 5v14M5 12h14\" {...line(muted)} />\n </svg>\n </div>\n <div\n style={{\n height: 36,\n padding: \"0 13px\",\n borderRadius: 18,\n border: `1px solid ${hair}`,\n display: \"flex\",\n alignItems: \"center\",\n gap: 8,\n fontSize: 16,\n color: ink,\n }}\n >\n <svg viewBox=\"0 0 24 24\" width={17} height={17} aria-hidden>\n <path\n d=\"M4 5.5h16v13H4zM4 9.5h16M8 13.5h5\"\n {...line(muted)}\n />\n </svg>\n Web app\n </div>\n <div style={{ flex: 1 }} />\n <span\n style={{\n display: \"flex\",\n alignItems: \"center\",\n gap: 6,\n fontSize: 16,\n color: muted,\n }}\n >\n remocn-2\n <svg viewBox=\"0 0 24 24\" width={14} height={14} aria-hidden>\n <path d=\"m7 10 5 5 5-5\" {...line(muted)} />\n </svg>\n </span>\n <svg viewBox=\"0 0 24 24\" width={20} height={20} aria-hidden>\n <path\n d=\"M12 3.5a3 3 0 0 0-3 3v5a3 3 0 0 0 6 0v-5a3 3 0 0 0-3-3ZM6 11.5a6 6 0 0 0 12 0M12 17.5v3\"\n {...line(muted)}\n />\n </svg>\n {sendButton}\n </div>\n </div>\n\n <div\n style={{\n position: \"absolute\",\n left: (W - winW) / 2,\n top: (H - winH) / 2,\n width: winW,\n height: winH,\n opacity: win,\n }}\n >\n <div\n style={{\n position: \"absolute\",\n left: 0,\n right: 0,\n top: 0,\n height: chromeH,\n borderBottom: `1px solid ${hair}`,\n display: \"flex\",\n alignItems: \"center\",\n padding: \"0 16px\",\n gap: 12,\n }}\n >\n <div style={{ display: \"flex\", gap: 8 }}>\n {[0, 1, 2].map((i) => (\n <span\n key={i}\n style={{\n width: 12,\n height: 12,\n borderRadius: 6,\n background: fill,\n border: `1px solid ${hair}`,\n }}\n />\n ))}\n </div>\n {portrait ? null : (\n <div\n style={{\n display: \"flex\",\n alignItems: \"center\",\n gap: 8,\n marginLeft: 10,\n fontSize: 15,\n color: ink,\n }}\n >\n <RemocnR height={15} color={ink} />\n <span style={{ color: muted }}>/</span>\n launch-page\n </div>\n )}\n <div\n style={{ flex: 1, display: \"flex\", justifyContent: \"center\" }}\n >\n <div\n style={{\n height: 30,\n padding: \"0 14px\",\n borderRadius: 9,\n background: fill,\n border: `1px solid ${hair}`,\n display: \"flex\",\n alignItems: \"center\",\n gap: 8,\n fontFamily: mono.fontFamily,\n fontSize: 14,\n color: muted,\n }}\n >\n <svg viewBox=\"0 0 24 24\" width={13} height={13} aria-hidden>\n <path\n d=\"M7.5 11V8a4.5 4.5 0 0 1 9 0v3M6 11h12v9H6z\"\n {...line(muted, 2)}\n />\n </svg>\n {url}\n </div>\n </div>\n <div\n style={{\n height: 32,\n padding: \"0 14px\",\n borderRadius: 9,\n position: \"relative\",\n display: \"flex\",\n alignItems: \"center\",\n gap: 7,\n fontSize: 15,\n color: \"#fff\",\n background: accent,\n transform: `scale(${pubDip})`,\n boxShadow: `inset 0 1px 0 rgba(255,255,255,0.3), 0 6px 16px color-mix(in oklab, ${accent} 40%, transparent)`,\n }}\n >\n {live ? (\n <span\n style={{\n width: 7,\n height: 7,\n borderRadius: 4,\n background: \"#fff\",\n }}\n />\n ) : null}\n {live ? \"Live\" : \"Publish\"}\n </div>\n </div>\n\n <div\n style={{\n position: \"absolute\",\n left: 0,\n top: chromeH,\n width: chatW,\n height: chatH,\n padding: portrait ? \"18px 22px\" : \"20px 20px\",\n boxSizing: \"border-box\",\n display: \"flex\",\n flexDirection: \"column\",\n gap: 16,\n }}\n >\n <div\n style={{\n alignSelf: \"flex-end\",\n maxWidth: portrait ? \"86%\" : \"100%\",\n padding: \"12px 15px\",\n borderRadius: \"16px 16px 4px 16px\",\n background: fill,\n border: `1px solid ${hair}`,\n fontSize: 16,\n lineHeight: 1.4,\n color: ink,\n }}\n >\n {prompt}\n </div>\n <div style={{ display: \"flex\", alignItems: \"center\", gap: 10 }}>\n <div\n style={{\n width: 28,\n height: 28,\n borderRadius: 8,\n background: ink,\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n }}\n >\n <RemocnR height={13} color={page} />\n </div>\n <span style={{ fontSize: 16, color: muted }}>\n {frame >= B.tick3 + 6\n ? \"Your page is ready.\"\n : \"Building your page…\"}\n </span>\n </div>\n <div\n style={{\n display: \"flex\",\n flexDirection: \"column\",\n gap: 12,\n paddingLeft: 2,\n }}\n >\n {steps.slice(0, 3).map((st, i) => {\n const t = tick(i);\n return (\n <div\n key={st}\n style={{\n display: \"flex\",\n alignItems: \"center\",\n gap: 11,\n fontSize: 16,\n color: t > 0.5 ? ink : muted,\n }}\n >\n {check(t, 22, ink, hair)}\n <span style={{ flex: 1 }}>{st}</span>\n <span\n style={{\n fontFamily: mono.fontFamily,\n fontSize: 13,\n color: faint,\n }}\n >\n {[\"hero.tsx\", \"pricing.tsx\", \"waitlist.tsx\"][i]}\n </span>\n </div>\n );\n })}\n </div>\n {portrait ? null : (\n <>\n <div style={{ flex: 1 }} />\n <div\n style={{\n height: 50,\n borderRadius: 14,\n border: `1px solid ${hair}`,\n background: fill,\n display: \"flex\",\n alignItems: \"center\",\n padding: \"0 8px 0 14px\",\n fontSize: 16,\n color: faint,\n }}\n >\n <span style={{ flex: 1 }}>Ask for changes</span>\n <div\n style={{\n width: 34,\n height: 34,\n borderRadius: 17,\n background: fill,\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n }}\n >\n <svg\n viewBox=\"0 0 24 24\"\n width={16}\n height={16}\n aria-hidden\n >\n <path\n d=\"M12 19V5M6 11l6-6 6 6\"\n {...line(muted, 1.8)}\n />\n </svg>\n </div>\n </div>\n </>\n )}\n </div>\n\n <div\n style={{\n position: \"absolute\",\n left: view.x,\n top: view.y,\n width: view.w,\n height: view.h,\n borderRadius: 14,\n overflow: \"hidden\",\n background: page,\n border: `1px solid ${hair}`,\n boxShadow: dark\n ? \"inset 0 1px 0 rgba(255,255,255,0.04)\"\n : \"0 1px 3px rgba(30,30,60,0.06)\",\n }}\n >\n {pageContent}\n <div\n style={{\n position: \"absolute\",\n left: \"50%\",\n bottom: 18,\n height: 44,\n padding: \"0 16px 0 10px\",\n borderRadius: 22,\n background: dark ? \"#1b1b22\" : \"#17161b\",\n color: \"#fff\",\n display: \"flex\",\n alignItems: \"center\",\n gap: 10,\n fontSize: 15,\n whiteSpace: \"nowrap\",\n boxShadow:\n \"inset 0 1px 0 rgba(255,255,255,0.1), 0 12px 30px rgba(0,0,0,0.35)\",\n opacity: frame >= B.toast ? Math.min(1, toast * 2) : 0,\n transform: `translate(-50%, ${mix(70, 0, toast)}px) scale(${mix(0.85, 1, toast)})`,\n }}\n >\n <span\n style={{\n width: 26,\n height: 26,\n borderRadius: 13,\n background: \"#2fbf71\",\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n }}\n >\n <svg viewBox=\"0 0 24 24\" width={15} height={15} aria-hidden>\n <path d=\"m6 12.5 4 4 8-9\" {...line(\"#fff\", 2.4)} />\n </svg>\n </span>\n Live at\n <span style={{ fontFamily: mono.fontFamily, opacity: 0.7 }}>\n {url}\n </span>\n </div>\n </div>\n </div>\n </div>\n </div>\n </div>\n </AbsoluteFill>\n );\n}\n\nexport default PromptSwell;\n",
"type": "registry:component",
"target": "components/remocn/prompt-swell.tsx"
}
],
"type": "registry:component"
}