# Eddy-current brake

A magnet array moves across a rotating conductive disc and reveals qualitative eddy paths in the overlap. The disc and brake never touch.

> For the complete index, see [llms.txt](https://robocn.dev/llms.txt). A Markdown version of any page is available by appending `.md` to its URL or by sending an `Accept: text/markdown` header.

## Install

```bash
bunx --bun shadcn@latest add https://robocn.dev/r/eddy-current-brake.json
```

Registry item: `eddy-current-brake` · [`https://robocn.dev/r/eddy-current-brake.json`](https://robocn.dev/r/eddy-current-brake.json)

## Notes

- The disc visibly slows as overlap grows, but that timing is illustrative. No conductivity, braking torque, heat, speed or field density is calculated.

## Usage

```tsx
import { EddyCurrentBrake } from "@/components/ui/eddy-current-brake"

<EddyCurrentBrake behavior="brake" slots={12} view="iso" />
<EddyCurrentBrake engagement={0.7} discAngle={35} interactive />
```

## Props

| name | type | default | description |
| --- | --- | --- | --- |
| `engagement` | `number` | — | Controlled magnet overlap from 0 clear to 1 fully engaged. |
| `behavior` | `"brake" | "feather" | "static"` | `"brake"` | Full or shallow automatic overlap motion. |
| `discAngle` | `number` | — | Independent controlled disc angle in degrees. |
| `slots` | `0 | 6 | 12` | `6` | Vent slots in the conductive disc. |
| `interactive / onEngagementChange` | `boolean / (engagement: number) => void` | — | Move the magnet array and report overlap. |
| `view` | `"plan" | "front" | "profile" | "iso"` | `"iso"` | Where the camera stands. One eddy-current brake, four projections: straight down, straight on, side elevation, or three-quarter from above. |
| `animate` | `boolean` | `true` | Off parks the machine at phase and stops rendering. A reduced-motion preference does the same. |
| `paused` | `boolean` | `false` | Freeze where it stands. |
| `phase` | `number` | `0` | Seconds of offset, so a row of machines breaks step. |
| `variant` | `"solid" | "outline" | "blueprint" | "wire"` | `"solid"` | How the machine is painted. Geometry never changes between variants. |
| `size` | `"xs" | "sm" | "md" | "lg" | "xl" | number` | `"md"` | Rendered width in pixels, or a step on the scale. |
| `color` | `string` | `var(--robot-shell)` | Body panels — the colour the machine reads as. |
| `accent` | `string` | `var(--robot-accent)` | Status colour: tip light, live tool, readouts. |
| `metal` | `string` | `var(--robot-metal)` | Bare machined parts: collars, bolts, tool bodies. |
| `dark` | `string` | `var(--robot-dark)` | Cast joints, base, shadow side. |
| `palette` | `Partial<RobotPalette>` | — | Override any subset of roles at once, including glow and grid. |

## Source

- `src/components/ui/eddy-current-brake.tsx`
