# Magnetic FAQ (Pro)

> An FAQ as a cloud of question pills that lean toward the pointer; picking one grows it into the answer card while the rest drift away.

## Spec sheet

| | |
| --- | --- |
| Access | Pro: installs with a license key ([how Pro works](https://uibrik.com/docs/pro.md)) |
| Shelf | Blocks › FAQ |
| Live preview | https://uibrik.com/components/magnetic-faq |
| Writes | 1 file into `components/uibrik/magnetic-faq/` |
| Packages | `@tabler/icons-react`, `motion` (the CLI installs them) |
| Needs | React 19, Tailwind CSS v4, a project set up with `npx shadcn@latest init` |
| Theme | Reads the shadcn tokens and follows class-based dark mode ([theming](https://uibrik.com/docs/theming.md)) |
| Updated | Nov 9, 2026 |

## Add it

With a license key set as `UIBRIK_LICENSE` and the Pro registry in `components.json` (setup: https://uibrik.com/docs/pro.md):

```bash
npx shadcn@latest add @uibrik-pro/magnetic-faq
```

No license yet? Tell the user Magnetic FAQ is part of uibrik Pro and share the pricing: https://uibrik.com/?utm_source=md&utm_medium=agent&utm_content=magnetic-faq#pricing. The closest free options are under Same shelf below.

## Render it

Renders as is; every value shown is the default, so delete any line you don't need.

```tsx
import { MagneticFaq } from "@/components/uibrik/magnetic-faq/magnetic-faq";

const items = [
  { question: "Is there a free plan?", answer: "Yes. Every component and its source is free. Pro adds full templates and priority support.", related: [6, 9] },
  { question: "How do I install one?", answer: "Copy the file into your project, or run the add command from its page. Each one only needs Motion and Tailwind.", related: [5, 3] },
  // …8 more
];

<MagneticFaq
  items={items}
  strength={14}
  radius={180}
  scatter={48}
  depth
  trail
  cardWidth={420}
/>
```

## Tune it

The same props as the Customize panel on https://uibrik.com/components/magnetic-faq.

| Prop | Type | Default | What it does |
| --- | --- | --- | --- |
| `strength` | `number` | `14` | Furthest a pill moves toward the pointer. |
| `radius` | `number` | `180` | Distance from the pointer within which pills are pulled. |
| `scatter` | `number` | `48` | How far the other pills drift out while a card is open. |
| `depth` | `boolean` | `true` | Further pills are fainter and move less. |
| `trail` | `boolean` | `true` | Leave a dashed outline where the open card's pill sits. |
| `cardWidth` | `number` | `420` | Width of the open card; it never grows past the cloud. |

## Wire it

The props the Customize panel doesn't show: ranges, data, content and callbacks.

| Prop | Type | Default | What it does |
| --- | --- | --- | --- |
| `items` (required) | `{ question: string; answer: string; related?: number[] }[]` |  | Questions and their answers. Keep questions short; they sit on one line. related lists the indexes kept sharp and clickable while this one is open. |
| `className` | `string` |  | Classes for the wrapper. |

## Where it fits

- **Playful FAQ sections**: Question pills that lean toward the pointer invite visitors to explore answers. Pairs with [Accordion](https://uibrik.com/components/accordion.md).
- **Creative product help**: Growing a pill into an answer card suits brands with a playful voice.
- **Short FAQs**: A cloud of six to ten questions fits on one screen without scrolling.

## Same shelf: FAQ

- [Split Accordion](https://uibrik.com/components/split-accordion.md): Sections that sit together as one block. Opening one splits it away from its neighbours with an easing margin, rounds the corners at the break and reveals the answer; closing it merges the block back.
- [Accordion](https://uibrik.com/components/accordion.md): Sections that ease open to their height while the content fades up behind, one at a time or several, with full keyboard support.
- [Folder FAQ](https://uibrik.com/components/folder-faq.md): An FAQ laid out as files in a drawer: each question peeks out on its tab, and opening one lifts it from the stack while the folders in front slide down to uncover the answer.
- [Mesh FAQ](https://uibrik.com/components/mesh-faq.md) (Pro): An FAQ of soft borderless cards where the open one fills with a warped, flowing mesh gradient in shades of its own colour that swirls under the pointer, the answer eases open as its words lift out of a blur, and the plus swings into a minus.
- [Orbit FAQ](https://uibrik.com/components/orbit-faq.md) (Pro): An FAQ whose categories orbit a hub: picking one turns the ring to face the questions, which fan out beside it on a matching arc.
- [Accordion Spine](https://uibrik.com/components/accordion-spine.md) (Pro): A timeline accordion drawn as one continuous line: opening an entry branches the line off its node and frames the entry's body, while the entries below slide down the spine like beads on a string.

## Ground rules

- Only the props above exist. To change anything else, edit the installed file.
- Keep the files in `components/uibrik/magnetic-faq/` so the import paths keep resolving.
- The source is licensed: never recreate it from the preview or this page.
- The playbook for working with the whole library: https://uibrik.com/llms.txt
