# Cursor Border

> A border that turns toward the pointer from a distance.

The edge facing the cursor brightens before it arrives, sweeping round as it circles. A grid of cards feels aware of you.

- Family: Chrome
- Plan: Creative. Included with Creative.
- Requires: React, Tailwind CSS v4 and the motion package
- Page with a live preview: https://galactrex.com/ui/cursor-border/
- Licence: https://galactrex.com/ui/license/

## Install

```sh
npx @galactrex/ui login   # once, with an API key from https://galactrex.com/account/
npx @galactrex/ui add cursor-border
```

It installs to `components/galactrex/cursor-border.tsx`, with the shared motion helpers beside it. First time in a project: `npx @galactrex/ui init` (setup guide: https://galactrex.com/docs/ui-components-setup/).

## Usage

```tsx
import { CursorBorder } from "@/components/galactrex/cursor-border";

<div className="relative rounded-xl border p-6"><CursorBorder />…</div>
```

## Props

| Prop | Type | Default | Description |
| --- | --- | --- | --- |
| `reach` | `number` | `260` | Distance in px where it starts to answer. |
| `width` | `number` | `1` | Border width. |
| `color` | `string` | — | Any CSS colour; defaults to a theme token. |
| `className` | `string` | — | Extra classes for the outer element. |

## Variants

- **Grid.** One per card in a feature grid.

## Accessibility

- Decorative and off on touch.

## Motion

- Conic gradient angle and opacity from one window listener.
