Skip to content

Components ​

Ready-made pieces: lower thirds, callouts, counters, cards and the like. Import them from @cutcraft/kit and write them on a track like any element. Generated from packages/kit/src/components by pnpm docs:gen.

Anatomy of a component ​

A component is an ordinary function that returns the kit's own elements: titles, shapes, SVG, and a layer where something moves every frame. So it behaves like the elements it is made of.

tsx
<LowerThird id="name" start={0.5} duration={4} name="Maya Chen" role="Founder, Shed" />
PartHow it works
idNames the component. Each element it makes has an id that starts with it: name-card, name-bar, name-name, name-role.
TimingThe same props as any element: start, or anchor with at and offset, and duration, including { until: id }. Its parts come in and go out inside that time.
Positionx and y are pixels from the frame's centre, as every element's transform.position. The defaults suit a 1920x1080 frame.
LookColours default to theme tokens ($primary, $surface, $text) and text to the theme's fonts, so a theme restyles every component.
Its own propsThe words and options it draws, listed on its page: name and role for a lower third, to and format for a counter.
In an editorIts props are editable in an inspector. Editing one of its parts writes that use out into the file as plain elements, and the edit applies to them.

Any function that returns elements works the same way, so you can write your own (Helpers). Anatomy of an element covers the parts every element shares.

MIT licensed.