apps/docs/content/docs/en/react/releases/v3-0-0-alpha-32.mdx
This release adds AI development tools, updates the Card component API, and improves the developer experience.
Update to the latest version:
<Tabs items={["npm", "pnpm", "yarn", "bun"]}>
<Tab value="npm">
bash npm i @heroui/styles@alpha @heroui/react@alpha
</Tab>
<Tab value="pnpm">
bash pnpm add @heroui/styles@alpha @heroui/react@alpha
</Tab>
<Tab value="yarn">
bash yarn add @heroui/styles@alpha @heroui/react@alpha
</Tab>
<Tab value="bun">
bash bun add @heroui/styles@alpha @heroui/react@alpha
</Tab>
</Tabs>
HeroUI now includes an MCP server that lets AI assistants like Cursor, Claude Code, and VS Code Copilot access HeroUI v3 documentation and component information directly.
Quick Setup:
Or manually add to Cursor Settings → Tools → MCP Servers:
{
"mcpServers": {
"heroui-react": {
"command": "npx",
"args": ["-y", "@heroui/react-mcp@latest"]
}
}
}
Run this command in your terminal:
claude mcp add heroui-react -- npx -y @heroui/react-mcp@latest
The Card component has been updated with a new variant system that makes it more flexible.
Breaking Changes:
surface prop with new variant systemCard.Image, Card.Details, and Card.CloseButton (use composition instead)flat, outlined, elevated, filledBefore:
<Card surface="1">
<Card.Image src="/image.jpg" />
<Card.Details>
<Card.Title>Old Card</Card.Title>
</Card.Details>
</Card>
After:
<Card variant="outlined">
<Card.Header>
</Card.Header>
<Card.Body>
<Card.Title>New Card</Card.Title>
</Card.Body>
</Card>
New Features:
Added a CloseButton component for closing dialogs, modals, and other dismissible elements.
import {CloseButton} from "@heroui/react";
// Basic usage
<CloseButton onPress={() => console.log("Closed")} />
// With custom icon
<CloseButton>
<XMarkIcon className="size-4" />
</CloseButton>
Update variant prop:
surface="1" → variant="flat"surface="2" → variant="outlined"surface="3" → variant="elevated"surface="4" → variant="filled"Update component structure:
Card.Image with `` in Card.HeaderCard.Details with Card.BodyCard.CloseButton to use new CloseButton componentUpdate imports:
// Add CloseButton if needed
import {Card, CloseButton} from "@heroui/react";
Thanks to everyone who contributed to this release!