Wrap the words of a heading set in a variable font. Leave out from to start from the weight of the text.
The sample also uses Button. One command adds them with this item:
hero.tsx
TextVariableProximity
<span>| Prop | Type | Default | Description |
|---|---|---|---|
| paused | boolean | — | The pause of the user or the page (controlled). |
| default | boolean | — | The first pause when paused is not given (uncontrolled). Default false. |
| on | — | Called when the pause changes. | |
| locale | string | — | The BCP 47 locale for the letter and word split (Intl.Segmenter). Default: the DisplayLocaleProvider locale, else "en-US". |
| children | string | — | The text. Its letters near the pointer move along the font axes from from to to. |
| from | string | — | The font-variation-settings at rest, for each axis of to. Any axis the font has: wdth, opsz, slnt, GRAD, or a custom one. Default: read from the text (wght from its font-weight, wdth from its font-stretch), so a font-bold text starts at 700. Name an axis here that the text cannot give (opsz). |
| to | string | — | The font-variation-settings under the pointer: 'wght' 900 (default). |
| radius | number | — | How far the pointer reaches, in px from the center of a letter. Default 120. |
| falloff | "distance""index" | — | How the effect falls off: by the distance of each letter (default), or by its index from the letter under the pointer, as icons in a dock (#/lib/pro/pointer-falloff-model). |
| spread | number | — | falloff="index" only: how many letters on each side react. Default 2. |
| ripple | boolean | — | A press on the text sends a ring of weight out from the press point. Default on. |
| idle | boolean | — | A slow bump crosses the text while the pointer is away (2.4s a pass, then 1.2s of rest), only on screen. paused stops it. |
| ...props | <span> attributes | — | Every other attribute goes to the <span>, with a ref. |
| Tab | Moves the focus to the link or button around the text. One sweep of weight crosses the letters from the start edge. |
|---|







