# v3.2.2 · HeroUI

> 补丁版本：将 React Aria 升级到 1.19.0，为 Tabs.ListContainer 添加溢出滚动，并修复清除/关闭按钮意外提交表单以及视觉隐藏输入框导致溢出滚动的问题。

- 页面: https://jiguang132.com/zh/systems/heroui/docs/releases/v3-2-2
- 改编自: HeroUI 文档 (Apache-2.0) @ 60edd8ed751b1d2a270623fbb182bbcfa8baa9af

2026 年 6 月 19 日


补丁版本：升级到 React Aria `1.19.0`（`react-aria@3.50.0`），为 [Tabs](/systems/heroui/docs/components/tabs) 的 `Tabs.ListContainer` 添加溢出滚动，并修复多个回归问题 —— 清除和关闭按钮不再提交其所在的表单，`Checkbox`、`Radio` 和 `Switch` 中的视觉隐藏输入框不再导致溢出滚动。

## 安装

升级到最新版本：


  

#### npm


    ```bash
    npm i @heroui/styles@latest @heroui/react@latest
    ```
  
  

#### pnpm


    ```bash
    pnpm add @heroui/styles@latest @heroui/react@latest
    ```
  
  

#### yarn


    ```bash
    yarn add @heroui/styles@latest @heroui/react@latest
    ```
  
  

#### bun


    ```bash
    bun add @heroui/styles@latest @heroui/react@latest
    ```
  


> 
  **正在使用 AI 助手？** 对它说「Hey Cursor，把 HeroUI 升级到最新版本」。它会自动对比版本并应用必要变更。了解更多请参阅 [HeroUI MCP 服务器](/docs/ui-for-agents/mcp-server)。


## 新功能

### Tabs

当标签列表超出可用空间时，`Tabs.ListContainer` 会自动渲染滚动箭头和边缘渐变，以便用户浏览隐藏的标签。适用于横向和纵向布局。

- **溢出滚动**：用 `Tabs.ListContainer` 包裹 `Tabs.List`，即可获得滚动箭头和边缘渐变 ([#6696](https://github.com/heroui-inc/heroui/pull/6696))


> 示例 `tabs-overflow`: 交互预览见 https://jiguang132.com/zh/systems/heroui/docs/releases/v3-2-2


## 错误修复

- **输入框**：为清除和关闭按钮设置 `type="button"`，使其在点击时不再提交所在的表单 ([#6656](https://github.com/heroui-inc/heroui/pull/6656))。
- **Checkbox / Radio / Switch**：避免视觉隐藏的输入框导致溢出滚动 ([#6657](https://github.com/heroui-inc/heroui/pull/6657))。
- **Button / Dropdown / Menu**：添加 `will-change-transform`，避免在变换过程中图标或文本发生偏移 ([#6661](https://github.com/heroui-inc/heroui/pull/6661))。
- **Chip**：将宽度设置为 `w-fit`，使 chip 根据内容自适应宽度，而非拉伸填满容器 ([#6664](https://github.com/heroui-inc/heroui/pull/6664))。
- **DatePicker / DateRangePicker**：使用 `w-fit` 替代 `min-w-(--trigger-width)`，避免弹出层宽度过宽 ([#6665](https://github.com/heroui-inc/heroui/pull/6665))。
- **Autocomplete**：修正虚拟化列表项的右内边距，使列表项不再溢出到弹出层边缘 ([#6672](https://github.com/heroui-inc/heroui/pull/6672))。
- **Toast**：在 toast 队列中捕获 ViewTransition 的 `ready` 拒绝，使被取代的过渡不再产生未处理的 Promise 拒绝 ([#6674](https://github.com/heroui-inc/heroui/pull/6674))。

## 重构

- **React 19 API**：使用 `use()` hook 替代 `useContext`，并将 `ref` 作为普通 prop 传递；将数组索引 key 替换为稳定 key ([#6688](https://github.com/heroui-inc/heroui/pull/6688))。

## 依赖

- **React Aria**：升级到 `react-aria-components@1.19.0` 和 `react-aria@3.50.0` ([#6658](https://github.com/heroui-inc/heroui/pull/6658))。
- **React Aria**：将 `react-aria`（`^3.50.0`）和 `react-aria-components`（`^1.19.0`）声明为 caret 范围，以便与 HeroUI Pro 去重 ([#6689](https://github.com/heroui-inc/heroui/pull/6689))。

## 链接

- [组件文档](/systems/heroui/docs/components)
- [GitHub 仓库](https://github.com/heroui-inc/heroui)
- [GitHub PR #6660](https://github.com/heroui-inc/heroui/pull/6660)

## 贡献者

感谢所有为本次发布做出贡献的人！

---

JGuang 全部资源索引: https://jiguang132.com/llms.txt
