From zenbu-powers
Ant Design v5 (antd ^5.x) complete API reference for React component library. Use this skill whenever the task involves any antd v5 component: Table, Form, Select, Input, Button, Modal, notification, message, Upload, Tag, Tooltip, Badge, Image, Radio, Segmented, Switch, DatePicker, RangePicker, Popconfirm, Drawer, Descriptions, ConfigProvider, Space, Layout, Grid (Row/Col), Spin, Pagination, or the antd theme system (token, algorithm, useToken, CSS variables). Also use when code imports from 'antd', references antd TypeScript types (TableProps, FormInstance, ColumnsType, UploadFile, etc.), or when configuring antd theming/tokens. Do NOT use this skill for @ant-design/pro-components (use ant-design-pro-v2 skill instead). Version coverage: antd 5.x (tested against 5.25.x).
npx claudepluginhub zenbuapps/zenbu-powers --plugin zenbu-powersThis skill uses the workspace's default tool permissions.
This skill covers antd v5 core components organized by category. Each reference file provides
Searches, retrieves, and installs Agent Skills from prompts.chat registry using MCP tools like search_skills and get_skill. Activates for finding skills, browsing catalogs, or extending Claude.
Checks Next.js compilation errors using a running Turbopack dev server after code edits. Fixes actionable issues before reporting complete. Replaces `next build`.
Guides code writing, review, and refactoring with Karpathy-inspired rules to avoid overcomplication, ensure simplicity, surgical changes, and verifiable success criteria.
Share bugs, ideas, or general feedback.
This skill covers antd v5 core components organized by category. Each reference file provides complete API signatures, all props with types and defaults, TypeScript types, and usage patterns.
Read only the file relevant to your current task:
| File | Components | When to Read |
|---|---|---|
references/data-display.md | Table, Tag, Badge, Image, Tooltip, Descriptions | Rendering data, lists, status indicators, previews |
references/data-entry.md | Form, Input, Select, Radio, Segmented, Switch, Upload, DatePicker/RangePicker | Form building, user input, file upload, date selection |
references/feedback.md | Modal, notification, message, Popconfirm, Drawer | Dialogs, alerts, confirmations, side panels |
references/general-layout.md | Button, ConfigProvider, Space, Layout, Grid, Spin, Pagination | Buttons, layout structure, loading states, page navigation |
references/theme.md | theme, useToken, ConfigProvider theme prop | Theming, design tokens, dark mode, CSS variables |
import { Table, Form, Button, ConfigProvider, theme } from 'antd';
import type { TableProps, FormInstance, ColumnsType } from 'antd';
visible prop renamed to open across all componentsdropdownClassName renamed to popupClassNamebordered deprecated in favor of variant propmessage/notification/modal prefer hook API over static methodsvariant (v5.13.0+): 'outlined' | 'borderless' | 'filled' | 'underlined'
Applied to: Input, Select, DatePicker, Form (sets default for children)
classNames / styles: Semantic DOM customization available on nearly all components.
<Table
classNames={{ header: 'bg-gray-100', body: 'text-sm' }}
styles={{ header: { fontWeight: 600 } }}
/>
status: 'error' | 'warning' for validation display (Input, Select, DatePicker)
allowClear (v5.8.0+): boolean | { clearIcon?: ReactNode }
// Table
import type { TableProps, TableColumnsType, TablePaginationConfig } from 'antd';
const columns: TableColumnsType<DataType> = [{ title: 'Name', dataIndex: 'name' }];
// Form
import type { FormInstance, FormProps, FormItemProps, Rule } from 'antd';
const [form] = Form.useForm<FormValues>();
// Select
import type { SelectProps, DefaultOptionType } from 'antd';
// Upload
import type { UploadFile, UploadProps, UploadChangeParam } from 'antd';
// DatePicker
import type { DatePickerProps, RangePickerProps } from 'antd';
// Note: antd v5 uses dayjs by default (not moment.js)
// Theme
const { token } = theme.useToken();
// notification
const [api, contextHolder] = notification.useNotification();
// Place {contextHolder} in JSX, then call api.success({...})
// message
const [messageApi, contextHolder] = message.useMessage();
// Modal
const [modal, contextHolder] = Modal.useModal();
const confirmed = await modal.confirm({ title: '...' }); // returns boolean (v5.4.0+)
// Basic Form with useForm
const [form] = Form.useForm<{ name: string; age: number }>();
// Watch field value
const nameValue = Form.useWatch('name', form);
// Dependencies for conditional rendering
<Form.Item dependencies={['type']} noStyle>
{({ getFieldValue }) =>
getFieldValue('type') === 'other' ? <Form.Item name="detail"><Input /></Form.Item> : null
}
</Form.Item>
// Form.List for dynamic fields
<Form.List name="users">
{(fields, { add, remove }) => fields.map(field => (
<Form.Item {...field} name={[field.name, 'name']}><Input /></Form.Item>
))}
</Form.List>
// Validation
form.validateFields() // all fields
form.validateFields(['name']) // specific fields
form.validateFields({ validateOnly: true }) // no UI error (v5.5.0+)
// Controlled pagination + sorting + filtering
<Table
dataSource={data}
columns={columns}
pagination={{ current: page, pageSize, total }}
onChange={(pagination, filters, sorter, extra) => {
// extra.action: 'paginate' | 'sort' | 'filter'
}}
/>
// Virtual scrolling (v5.9.0+)
<Table virtual scroll={{ y: 500 }} columns={columns} dataSource={bigData} />
// Row selection
<Table
rowSelection={{
type: 'checkbox',
selectedRowKeys,
onChange: (keys, rows, info) => { /* info.type available v4.21.0+ */ },
}}
/>
import { ConfigProvider, theme } from 'antd';
<ConfigProvider
theme={{
algorithm: theme.darkAlgorithm, // or [theme.darkAlgorithm, theme.compactAlgorithm]
token: {
colorPrimary: '#1890ff',
borderRadius: 4,
fontSize: 14,
},
components: {
Button: { colorPrimary: '#00b96b' },
Table: { headerBg: '#fafafa' },
},
}}
>
<App />
</ConfigProvider>