mirror of
https://github.com/heygen-com/hyperframes.git
synced 2026-09-04 07:19:52 +00:00
My generator rebuild replaced the '## Related topics' section (still required by docs/AGENTS.md) with the provenance footer, dropping it from all 168 generated Catalog pages. Emit it again as the final section so pages end with it, and stop carriedSectionsFrom() breaking at the footer marker so a human section appended below the generated tail survives a regeneration. Adds a per-page regeneration assertion so a future drop fails CI. Flagged by Magi (P1) and Rames.
57 lines
1.5 KiB
Plaintext
57 lines
1.5 KiB
Plaintext
---
|
||
title: "Portal"
|
||
description: "VFX composition block"
|
||
---
|
||
|
||
<video className="w-full aspect-video rounded-xl object-cover bg-zinc-100 dark:bg-zinc-800" src="https://static.heygen.ai/hyperframes-oss/docs/images/catalog/blocks/vfx-portal.mp4" poster="https://static.heygen.ai/hyperframes-oss/docs/images/catalog/blocks/vfx-portal.png" autoPlay muted loop playsInline />
|
||
|
||
## Install
|
||
|
||
```bash Terminal
|
||
npx hyperframes add vfx-portal
|
||
```
|
||
|
||
That writes one file: `compositions/vfx-portal.html`.
|
||
|
||
<Warning>
|
||
Live preview needs the `chrome://flags/#canvas-draw-element` flag switched on.
|
||
Rendering from the CLI switches it on for you. [How it
|
||
works](/guides/html-in-canvas)
|
||
</Warning>
|
||
|
||
## Add it to your video
|
||
|
||
It runs for 10 seconds at 1920×1080. Paste this into your composition:
|
||
|
||
```html index.html
|
||
<div
|
||
data-composition-id="vfx-portal"
|
||
data-composition-src="compositions/vfx-portal.html"
|
||
data-start="0"
|
||
data-duration="10"
|
||
data-track-index="1"
|
||
data-width="1920"
|
||
data-height="1080"
|
||
></div>
|
||
```
|
||
|
||
Move it in time with `data-start`. Put it on a different timeline row with
|
||
`data-track-index`. See [data attributes](/concepts/data-attributes) for the rest.
|
||
|
||
## Change the colors
|
||
|
||
Set these CSS variables on the block:
|
||
|
||
- `--bg-color` — Background. Defaults to `#000000`.
|
||
- `--portal-color` — Portal color. Defaults to `#fafafa`.
|
||
|
||
{/* hf:generated-footer */}
|
||
|
||
Tagged `html-in-canvas` `webgl`.
|
||
|
||
## Related topics
|
||
|
||
- [Browse the complete Catalog](/catalog)
|
||
- [Add assets and Catalog items in Studio](/studio/assets-and-blocks)
|
||
- [Build a richer composition](/go-further)
|