diff --git a/CHANGELOG.en-US.md b/CHANGELOG.en-US.md index b69d44b33..57a897066 100644 --- a/CHANGELOG.en-US.md +++ b/CHANGELOG.en-US.md @@ -10,6 +10,69 @@ --- +## 4.0 + +### 🔥🔥🔥 4.0 official version released 🔥🔥🔥 + +### Design specification adjustment + +- Basic rounded corner adjustment, changed from unified `2px` to four-level rounded corners, which are `2px` `4px` `6px` `8px` respectively, which are applied to different scenarios, for example, the rounded corners of the default size Button are adjusted to `6px`. +- Main color adjustment, changed from `#1890ff` to `#1677ff`. +- Overall shadow adjustment, from the original three-level shadow adjustment to two levels, which are used for resident page components (such as Card) and interactive feedback (such as Dropdown). +- Adjust the internal spacing of some components. +- Overall de-wireframing. + +### Add 5 new components + +- Segmented segment controller +- WaterMark watermark +- QrCode QR code +- FloatButton floating button +- Tour roaming guide + +### Technical adjustments + +- Deprecated less and adopted CSS-in-JS to better support dynamic themes. + - All less files are removed, and less variables no longer support leaking. + - css files are no longer included in the product. Since CSS-in-JS supports importing on demand, the original `ant-design-vue/dist/antd.css` has also been removed. If you need to reset some basic styles, please import `ant-design-vue/dist/reset .css`. + - If you need to reset the style of the component and don't want to introduce `ant-design-vue/dist/reset.css` to pollute the global style, you can try to use [App component](/components/app), to solve the problem that native elements do not have ant-design-vue specification style. +- Removed css variables and dynamic theme schemes built on top of it. +- LocaleProvider has been deprecated in 3.x (use `` instead), we have completely removed the related directories `ant-design-vue/es/locale-provider`, `ant- design-vue/lib/locale-provider`. +- `babel-plugin-import` is no longer supported, CSS-in-JS itself has the ability to load on demand, no longer need plug-in support. + +#### Component API adjustments + +- The classname API of the component popup is unified to `popupClassName`, and similar APIs such as `dropdownClassName` will be replaced. + + - AutoComplete component + - Cascader component + - Select component + - TreeSelect component + - TimePicker component + - DatePicker component + - Mentions component + +- The controlled visibility API of the component popup is unified as `open`, and `visible` and other similar APIs will be replaced. + - Drawer component `visible` becomes `open`. + - Modal component `visible` becomes `open`. + - Dropdown component `visible` becomes `open`. + - Tooltip component `visible` becomes `open`. + - Tag component `visible` has been removed. + - Slider component `tooltip` related API converges to `tooltip` property. + - Table component `filterDropdownVisible` changed to `filterDropdownOpen`. +- `getPopupContainer`: All `getPopupContainer` needs to ensure that the returned div is unique. +- Drawer `style` and `class` are migrated to the Drawer popup area, and the original attributes are replaced by `rootClassName` and `rootStyle`. + +#### Component refactoring and removal + +- Remove the `locale-provider` directory. `LocaleProvider` has been removed in v4, please use `ConfigProvider` instead. + +- Remove `xxxl` breakpoint attribute in grid layout. `xxxl` attribute has been removed in v4, you can use [theme customization](/docs/vue/customize-theme) to modify `screen[XS|SM|MD|LG|XL|XXL]` to modify the break Point value achieved. + +- The BackTop component was deprecated in `4.0.0` and moved to the FloatButton floating button. If needed, it can be imported from FloatButton. + +### [Upgrade Guide](/docs/vue/migration-v4) + ## 3.3.0-beta.3 `2022-08-11` diff --git a/CHANGELOG.zh-CN.md b/CHANGELOG.zh-CN.md index d6486a0d6..7d5774430 100644 --- a/CHANGELOG.zh-CN.md +++ b/CHANGELOG.zh-CN.md @@ -10,6 +10,69 @@ --- +## 4.0 + +### 🔥🔥🔥 4.0 正式版发布 🔥🔥🔥 + +### 设计规范调整 + +- 基础圆角调整,由统一的 `2px` 改为四级圆角,分别为 `2px` `4px` `6px` `8px`,分别应用于不同场景,比如默认尺寸的 Button 的圆角调整为了 `6px`。 +- 主色调整,由 `#1890ff` 改为 `#1677ff`。 +- 整体阴影调整,由原本的三级阴影调整为两级,分别用于常驻页面的组件(如 Card)和交互反馈(如 Dropdown)。 +- 部分组件内间距调整。 +- 整体去线框化。 + +### 新增 5 个组件 + +- Segmented 分段控制器 +- WaterMark 水印 +- QrCode 二维码 +- FloatButton 悬浮按钮 +- Tour 漫游式引导 + +### 技术调整 + +- 弃用 less,采用 CSS-in-JS,更好地支持动态主题。 + - 所有 less 文件全部移除,less 变量不再支持透出。 + - 产物中不再包含 css 文件。由于 CSS-in-JS 支持按需引入,原本的 `ant-design-vue/dist/antd.css` 也已经移除,如果需要重置一些基本样式请引入 `ant-design-vue/dist/reset.css`。 + - 如果需要组件重置样式,又不想引入 `ant-design-vue/dist/reset.css` 从而导致污染全局样式的话,可以尝试在应用最外层使用[App 组件](/components/app-cn),解决原生元素没有 ant-design-vue 规范样式的问题。 +- 移除 css variables 以及在此之上构筑的动态主题方案。 +- LocaleProvider 在 3.x 中已经废弃(使用 `` 替代),我们在 4.x 里彻底移除了相关目录 `ant-design-vue/es/locale-provider`、`ant-design-vue/lib/locale-provider`。 +- 不再支持 `babel-plugin-import`,CSS-in-JS 本身具有按需加载的能力,不再需要插件支持。 + +#### 组件 API 调整 + +- 组件弹框的 classname API 统一为 `popupClassName`,`dropdownClassName` 等类似 API 都会被替换。 + + - AutoComplete 组件 + - Cascader 组件 + - Select 组件 + - TreeSelect 组件 + - TimePicker 组件 + - DatePicker 组件 + - Mentions 组件 + +- 组件弹框的受控可见 API 统一为 `open`,`visible` 等类似 API 都会被替换。 + - Drawer 组件 `visible` 变为 `open`。 + - Modal 组件 `visible` 变为 `open`。 + - Dropdown 组件 `visible` 变为 `open`。 + - Tooltip 组件 `visible` 变为 `open`。 + - Tag 组件 `visible` 已移除。 + - Slider 组件 `tooltip` 相关 API 收敛到 `tooltip` 属性中。 + - Table 组件 `filterDropdownVisible` 变为 `filterDropdownOpen`。 +- `getPopupContainer`: 所有的 `getPopupContainer` 都需要保证返回的是唯一的 div。 +- Drawer `style` 和 `class` 迁移至 Drawer 弹层区域上,原属性替换为 `rootClassName` 和 `rootStyle`。 + +#### 组件重构与移除 + +- 移除 `locale-provider` 目录。`LocaleProvider` 在 v4 中已移除,请使用 `ConfigProvider` 替代。 + +- 移除栅格布局中的`xxxl`断点属性。 `xxxl`属性已经在 v4 被移除,您可以使用 [主题定制](/docs/vue/customize-theme-cn) 修改 `screen[XS|SM|MD|LG|XL|XXL]` 来修改断点值实现。 + +- BackTop 组件在 `4.0.0` 中废弃,移至 FloatButton 悬浮按钮中。如需使用,可以从 FloatButton 中引入。 + +### [升级指南](/docs/vue/migration-v4-cn) + ## 3.3.0-beta.3 `2022-08-11` diff --git a/package.json b/package.json index c96d4a9c8..ae3e17391 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "ant-design-vue", - "version": "4.0.0-rc.5", + "version": "4.0.0", "title": "Ant Design Vue", "description": "An enterprise-class UI design language and Vue-based implementation", "keywords": [