DlTypeman

Animate rotating words with a blinking cursor effect

The DlTypeman inline component animates a list of words by typing and deleting them in sequence, with a blinking cursor. It’s ideal for dynamic hero headlines and short, attention-grabbing phrases.

Features

  • ⌨️ type-and-delete word animation
  • 🔁 loops through a comma-separated list of words
  • ▮ blinking cursor effect
  • 🧩 theme-friendly visual adjustments
  • ⚙️ timing derives from app baseTimeout

Usage

Use :dl-typeman as an inline component providing words as a comma-separated list via the words prop. Each word is trimmed before rendering.

:dl-typeman[documentation]{words="documentation, components, performance"}

Result:

documentation

Props

Here are the properties you can use with the DlTypeman component. Each property should be set on an individual component instance; they do not affect the global configuration. More about defining properties in MDC components you can read here.

nametypedefaultdescription
lazybooleanundefined

Whether to lazy load the component.

wordsstring'documentation'

Comma-separated list of words to animate.

disabled-on-mobilebooleanundefined

Whether to show animation on mobile

iuiRecord<string, string>undefined

Special property dedicated to inline components, can be used to add TW classes for certain component markup elements.

Slots

namedescription
default

Fallback content displayed when no words are provided.

Styling

Styling from Markdown

Every DocLayer component can be styled directly within your Markdown file using dedicated slot/property configuration. This allows you to customize the appearance of the component's markup elements without modifying global styles. More about components styling you can read here.

Below you'll find the default set of Tailwind classes for the component's dedicated markup elements.

<script lang="ts">const ui = defineDoclayerComponentUi({  base: ['block', 'relative'],  cursor: [    'u-background-color-secondary',    'h-[1em]',    'w-[0.1rem]',    'ml-[0.2rem]',    'align-middle',    'hidden',    'md:inline-block!',  ],  text: [],});</script>