Files
hyperframes/registry/components/ai-prompt-flow/demo.html
T
Miguel Ángel 9734578e60 feat(registry): bring back the video-primitive moves (#3169)
Restores the 208 catalog items reverted after their previews 404'd in
production, this time on the payload mechanism rather than the .html files
that caused the outage.

The generator no longer writes a preview document to docs/public. That writer,
and the machinery under it, existed only to produce files the docs host
discards, so it is gone rather than bypassed. Items now embed the composition
itself via a payload, which is what the previous change already does for the
items that were already in the catalog.

The variables explorer is parked, not restored: it drove its preview through
the same unpublished .html path, so it would have shown an empty frame. Items
that declare variables get the live player plus the static variables table, and
reconnecting the explorer to payloads is a follow-up.
2026-08-10 18:46:03 -04:00

169 lines
4.6 KiB
HTML
Vendored

<!doctype html>
<html lang="en">
<head>
<meta charset="UTF-8" />
<meta name="viewport" content="width=1920, height=1080" />
<title>AI Prompt Flow - Demo</title>
<script src="https://cdn.jsdelivr.net/npm/gsap@3.14.2/dist/gsap.min.js"></script>
<style>
* {
box-sizing: border-box;
}
html,
body {
margin: 0;
width: 1920px;
height: 1080px;
overflow: hidden;
}
#demo {
width: 1920px;
height: 1080px;
display: grid;
place-items: center;
background: #f4f4f5;
font-family: Inter, system-ui, sans-serif;
}
.demo-frame {
display: grid;
place-items: center;
min-width: 760px;
min-height: 520px;
padding: 56px;
/* ponytail: scale-up only; demo-frame is not a GSAP target */
transform: scale(2.2);
transform-origin: center center;
}
.hf-ui-ai-prompt-flow {
display: grid;
gap: 18px;
width: 620px;
color: #18181b;
font-family: Inter, system-ui, sans-serif;
}
.hf-ui-ai-prompt-panel,
.hf-ui-ai-prompt-result {
border: 1px solid #e4e4e7;
border-radius: 26px;
background: #ffffff;
box-shadow: 0 26px 80px rgba(0, 0, 0, 0.1);
}
.hf-ui-ai-prompt-panel {
display: grid;
gap: 16px;
padding: 28px;
}
.hf-ui-ai-prompt-label {
color: #71717a;
font-size: 13px;
font-weight: 900;
letter-spacing: 0.1em;
text-transform: uppercase;
}
.hf-ui-ai-prompt-field {
min-height: 92px;
padding: 18px;
border-radius: 18px;
background: #f4f4f5;
font-size: 22px;
font-weight: 760;
line-height: 1.25;
}
.hf-ui-ai-prompt-chips {
display: flex;
flex-wrap: wrap;
gap: 8px;
}
.hf-ui-ai-prompt-chips span {
padding: 8px 11px;
border-radius: 999px;
background: #eef2ff;
color: #4338ca;
font-size: 13px;
font-weight: 850;
}
.hf-ui-ai-prompt-panel button {
justify-self: start;
height: 46px;
padding: 0 20px;
border: 0;
border-radius: 13px;
background: #18181b;
color: #ffffff;
font-size: 15px;
font-weight: 700;
cursor: default;
}
.hf-ui-ai-prompt-result {
display: flex;
justify-content: space-between;
align-items: center;
padding: 18px 22px;
}
.hf-ui-ai-prompt-result strong {
font-size: 18px;
}
.hf-ui-ai-prompt-result span {
color: #16a34a;
font-size: 14px;
font-weight: 850;
}
</style>
</head>
<body>
<div
id="demo"
data-composition-id="ai-prompt-flow-demo"
data-start="0"
data-width="1920"
data-height="1080"
data-duration="5"
>
<div class="demo-frame">
<div class="hf-ui-ai-prompt-flow">
<div class="hf-ui-ai-prompt-panel">
<span class="hf-ui-ai-prompt-label">Prompt</span>
<div class="hf-ui-ai-prompt-field">Create a launch video for our new feature</div>
<div class="hf-ui-ai-prompt-chips">
<span>fast cuts</span><span>captions</span><span>product UI</span>
</div>
<button type="button">Generate</button>
</div>
<div class="hf-ui-ai-prompt-result">
<strong>Preview ready</strong><span>18 scenes matched</span>
</div>
</div>
</div>
<script>
const tl = gsap.timeline({ paused: true });
tl.fromTo(
".hf-ui-ai-prompt-panel",
{ opacity: 0, y: 26 },
{ opacity: 1, y: 0, duration: 0.38, ease: "power2.out" },
0.25,
);
tl.fromTo(
".hf-ui-ai-prompt-chips span",
{ y: 14, opacity: 0 },
{ y: 0, opacity: 1, duration: 0.24, stagger: 0.06, ease: "power2.out" },
0.62,
);
tl.to(
".hf-ui-ai-prompt-panel button",
{ scale: 0.96, duration: 0.12, yoyo: true, repeat: 1, ease: "power1.inOut" },
1.0,
);
tl.fromTo(
".hf-ui-ai-prompt-result",
{ opacity: 0, y: 22, scale: 0.97 },
{ opacity: 1, y: 0, scale: 1, duration: 0.36, ease: "back.out(1.3)" },
1.24,
);
tl.set({}, {}, 5);
window.__timelines = window.__timelines || {};
window.__timelines["ai-prompt-flow-demo"] = tl;
</script>
</div>
</body>
</html>