Browse Source

Merge pull request #18871 from ant-design/upd-antd-version

chore: upd antd 4.0 version
pull/19059/head 4.0.0-alpha.4
信鑫-King 5 years ago
committed by GitHub
parent
commit
75c082a71e
No known key found for this signature in database GPG Key ID: 4AEE18F83AFDEB23
  1. 3
      README.md
  2. 18
      components/config-provider/__tests__/__snapshots__/components.test.js.snap
  3. 1
      components/tooltip/index.en-US.md
  4. 1
      components/tooltip/index.zh-CN.md
  5. 3
      components/transfer/__tests__/__snapshots__/demo.test.js.snap
  6. 24
      components/tree/__tests__/__snapshots__/demo.test.js.snap
  7. 36
      components/tree/__tests__/__snapshots__/directory.test.js.snap
  8. 5
      package.json
  9. 4
      site/theme/template/Layout/index.jsx

3
README.md

@ -10,7 +10,8 @@
An enterprise-class UI design language and React UI library. An enterprise-class UI design language and React UI library.
[![CircleCI branch](https://img.shields.io/circleci/project/github/ant-design/ant-design/master.svg?style=flat-square)](https://circleci.com/gh/ant-design/ant-design) [![Codecov](https://img.shields.io/codecov/c/github/ant-design/ant-design/master.svg?style=flat-square)](https://codecov.io/gh/ant-design/ant-design/branch/master) [![](https://flat.badgen.net/npm/v/antd?icon=npm)](https://www.npmjs.com/package/antd) [![NPM downloads](http://img.shields.io/npm/dm/antd.svg?style=flat-square)](http://npmjs.com/antd) [![CircleCI branch](https://img.shields.io/circleci/project/github/ant-design/ant-design/master.svg?style=flat-square)](https://circleci.com/gh/ant-design/ant-design) ![CI Status](https://github.com/ant-design/ant-design/workflows/Node%20CI/badge.svg)
[![Codecov](https://img.shields.io/codecov/c/github/ant-design/ant-design/master.svg?style=flat-square)](https://codecov.io/gh/ant-design/ant-design/branch/master) [![](https://flat.badgen.net/npm/v/antd?icon=npm)](https://www.npmjs.com/package/antd) [![NPM downloads](http://img.shields.io/npm/dm/antd.svg?style=flat-square)](http://npmjs.com/antd)
[![Dependencies](https://img.shields.io/david/ant-design/ant-design.svg?style=flat-square)](https://david-dm.org/ant-design/ant-design) [![DevDependencies](https://img.shields.io/david/dev/ant-design/ant-design.svg?style=flat-square)](https://david-dm.org/ant-design/ant-design?type=dev) [![Total alerts](https://flat.badgen.net/lgtm/alerts/g/ant-design/ant-design)](https://lgtm.com/projects/g/ant-design/ant-design/alerts/) [![FOSSA Status](https://app.fossa.io/api/projects/git%2Bgithub.com%2Fant-design%2Fant-design.svg?type=shield)](https://app.fossa.io/projects/git%2Bgithub.com%2Fant-design%2Fant-design?ref=badge_shield) [![Issues need help](https://flat.badgen.net/github/label-issues/ant-design/ant-design/help%20wanted/open)](https://github.com/ant-design/ant-design/issues?q=is%3Aopen+is%3Aissue+label%3A%22help+wanted%22) [![Dependencies](https://img.shields.io/david/ant-design/ant-design.svg?style=flat-square)](https://david-dm.org/ant-design/ant-design) [![DevDependencies](https://img.shields.io/david/dev/ant-design/ant-design.svg?style=flat-square)](https://david-dm.org/ant-design/ant-design?type=dev) [![Total alerts](https://flat.badgen.net/lgtm/alerts/g/ant-design/ant-design)](https://lgtm.com/projects/g/ant-design/ant-design/alerts/) [![FOSSA Status](https://app.fossa.io/api/projects/git%2Bgithub.com%2Fant-design%2Fant-design.svg?type=shield)](https://app.fossa.io/projects/git%2Bgithub.com%2Fant-design%2Fant-design?ref=badge_shield) [![Issues need help](https://flat.badgen.net/github/label-issues/ant-design/ant-design/help%20wanted/open)](https://github.com/ant-design/ant-design/issues?q=is%3Aopen+is%3Aissue+label%3A%22help+wanted%22)

18
components/config-provider/__tests__/__snapshots__/components.test.js.snap

@ -16830,8 +16830,9 @@ exports[`ConfigProvider components Tree configProvider 1`] = `
role="tree" role="tree"
> >
<input <input
style="width:0;height:0;display:flex;overflow:hidden;opacity:0" style="width:0;height:0;display:flex;overflow:hidden;opacity:0;border:0;padding:0;margin:0"
tabindex="0" tabindex="0"
value=""
/> />
</div> </div>
<div <div
@ -16866,8 +16867,9 @@ exports[`ConfigProvider components Tree configProvider 1`] = `
role="tree" role="tree"
> >
<input <input
style="width:0;height:0;display:flex;overflow:hidden;opacity:0" style="width:0;height:0;display:flex;overflow:hidden;opacity:0;border:0;padding:0;margin:0"
tabindex="0" tabindex="0"
value=""
/> />
</div> </div>
<div <div
@ -16931,8 +16933,9 @@ exports[`ConfigProvider components Tree normal 1`] = `
role="tree" role="tree"
> >
<input <input
style="width:0;height:0;display:flex;overflow:hidden;opacity:0" style="width:0;height:0;display:flex;overflow:hidden;opacity:0;border:0;padding:0;margin:0"
tabindex="0" tabindex="0"
value=""
/> />
</div> </div>
<div <div
@ -16967,8 +16970,9 @@ exports[`ConfigProvider components Tree normal 1`] = `
role="tree" role="tree"
> >
<input <input
style="width:0;height:0;display:flex;overflow:hidden;opacity:0" style="width:0;height:0;display:flex;overflow:hidden;opacity:0;border:0;padding:0;margin:0"
tabindex="0" tabindex="0"
value=""
/> />
</div> </div>
<div <div
@ -17032,8 +17036,9 @@ exports[`ConfigProvider components Tree prefixCls 1`] = `
role="tree" role="tree"
> >
<input <input
style="width:0;height:0;display:flex;overflow:hidden;opacity:0" style="width:0;height:0;display:flex;overflow:hidden;opacity:0;border:0;padding:0;margin:0"
tabindex="0" tabindex="0"
value=""
/> />
</div> </div>
<div <div
@ -17068,8 +17073,9 @@ exports[`ConfigProvider components Tree prefixCls 1`] = `
role="tree" role="tree"
> >
<input <input
style="width:0;height:0;display:flex;overflow:hidden;opacity:0" style="width:0;height:0;display:flex;overflow:hidden;opacity:0;border:0;padding:0;margin:0"
tabindex="0" tabindex="0"
value=""
/> />
</div> </div>
<div <div

1
components/tooltip/index.en-US.md

@ -35,6 +35,7 @@ The following APIs are shared by Tooltip, Popconfirm, Popover.
| trigger | Tooltip trigger mode | `hover` \| `focus` \| `click` \| `contextMenu` | `hover` | | | trigger | Tooltip trigger mode | `hover` \| `focus` \| `click` \| `contextMenu` | `hover` | |
| visible | Whether the floating tooltip card is visible or not | boolean | `false` | | | visible | Whether the floating tooltip card is visible or not | boolean | `false` | |
| onVisibleChange | Callback executed when visibility of the tooltip card is changed | (visible) => void | - | | | onVisibleChange | Callback executed when visibility of the tooltip card is changed | (visible) => void | - | |
| destroyTooltipOnHide | whether destroy tooltip when tooltip is hidden | boolean | false | |
| align | this value will be merged into placement's config, please refer to the settings [rc-tooltip](https://github.com/react-component/tooltip) | Object | - | 3.10.0 | | align | this value will be merged into placement's config, please refer to the settings [rc-tooltip](https://github.com/react-component/tooltip) | Object | - | 3.10.0 |
## Note ## Note

1
components/tooltip/index.zh-CN.md

@ -37,6 +37,7 @@ title: Tooltip
| trigger | 触发行为,可选 `hover/focus/click/contextMenu` | string | hover | | | trigger | 触发行为,可选 `hover/focus/click/contextMenu` | string | hover | |
| visible | 用于手动控制浮层显隐 | boolean | false | | | visible | 用于手动控制浮层显隐 | boolean | false | |
| onVisibleChange | 显示隐藏的回调 | (visible) => void | 无 | | | onVisibleChange | 显示隐藏的回调 | (visible) => void | 无 | |
| destroyTooltipOnHide | 是否在隐藏时销毁 Tooltip | boolean | false | |
| align | 该值将合并到 placement 的配置中,设置参考 [rc-tooltip](https://github.com/react-component/tooltip) | Object | 无 | 3.10.0 | | align | 该值将合并到 placement 的配置中,设置参考 [rc-tooltip](https://github.com/react-component/tooltip) | Object | 无 | 3.10.0 |
## 注意 ## 注意

3
components/transfer/__tests__/__snapshots__/demo.test.js.snap

@ -2343,8 +2343,9 @@ exports[`renders ./components/transfer/demo/tree-transfer.md correctly 1`] = `
role="tree" role="tree"
> >
<input <input
style="width:0;height:0;display:flex;overflow:hidden;opacity:0" style="width:0;height:0;display:flex;overflow:hidden;opacity:0;border:0;padding:0;margin:0"
tabindex="0" tabindex="0"
value=""
/> />
</div> </div>
<div <div

24
components/tree/__tests__/__snapshots__/demo.test.js.snap

@ -6,8 +6,9 @@ Array [
role="tree" role="tree"
> >
<input <input
style="width:0;height:0;display:flex;overflow:hidden;opacity:0" style="width:0;height:0;display:flex;overflow:hidden;opacity:0;border:0;padding:0;margin:0"
tabindex="0" tabindex="0"
value=""
/> />
</div>, </div>,
<div <div
@ -290,8 +291,9 @@ Array [
role="tree" role="tree"
> >
<input <input
style="width:0;height:0;display:flex;overflow:hidden;opacity:0" style="width:0;height:0;display:flex;overflow:hidden;opacity:0;border:0;padding:0;margin:0"
tabindex="0" tabindex="0"
value=""
/> />
</div>, </div>,
<div <div
@ -776,8 +778,9 @@ Array [
role="tree" role="tree"
> >
<input <input
style="width:0;height:0;display:flex;overflow:hidden;opacity:0" style="width:0;height:0;display:flex;overflow:hidden;opacity:0;border:0;padding:0;margin:0"
tabindex="0" tabindex="0"
value=""
/> />
</div>, </div>,
<div <div
@ -960,8 +963,9 @@ Array [
role="tree" role="tree"
> >
<input <input
style="width:0;height:0;display:flex;overflow:hidden;opacity:0" style="width:0;height:0;display:flex;overflow:hidden;opacity:0;border:0;padding:0;margin:0"
tabindex="0" tabindex="0"
value=""
/> />
</div>, </div>,
<div <div
@ -1304,8 +1308,9 @@ Array [
role="tree" role="tree"
> >
<input <input
style="width:0;height:0;display:flex;overflow:hidden;opacity:0" style="width:0;height:0;display:flex;overflow:hidden;opacity:0;border:0;padding:0;margin:0"
tabindex="0" tabindex="0"
value=""
/> />
</div>, </div>,
<div <div
@ -1640,8 +1645,9 @@ Array [
role="tree" role="tree"
> >
<input <input
style="width:0;height:0;display:flex;overflow:hidden;opacity:0" style="width:0;height:0;display:flex;overflow:hidden;opacity:0;border:0;padding:0;margin:0"
tabindex="0" tabindex="0"
value=""
/> />
</div>, </div>,
<div <div
@ -1757,8 +1763,9 @@ Array [
role="tree" role="tree"
> >
<input <input
style="width:0;height:0;display:flex;overflow:hidden;opacity:0" style="width:0;height:0;display:flex;overflow:hidden;opacity:0;border:0;padding:0;margin:0"
tabindex="0" tabindex="0"
value=""
/> />
</div>, </div>,
<div <div
@ -2152,8 +2159,9 @@ exports[`renders ./components/tree/demo/search.md correctly 1`] = `
role="tree" role="tree"
> >
<input <input
style="width:0;height:0;display:flex;overflow:hidden;opacity:0" style="width:0;height:0;display:flex;overflow:hidden;opacity:0;border:0;padding:0;margin:0"
tabindex="0" tabindex="0"
value=""
/> />
</div> </div>
<div <div

36
components/tree/__tests__/__snapshots__/directory.test.js.snap

@ -6,8 +6,9 @@ Array [
role="tree" role="tree"
> >
<input <input
style="width:0;height:0;display:flex;overflow:hidden;opacity:0" style="width:0;height:0;display:flex;overflow:hidden;opacity:0;border:0;padding:0;margin:0"
tabindex="0" tabindex="0"
value=""
/> />
</div>, </div>,
<div <div
@ -350,8 +351,9 @@ Array [
role="tree" role="tree"
> >
<input <input
style="width:0;height:0;display:flex;overflow:hidden;opacity:0" style="width:0;height:0;display:flex;overflow:hidden;opacity:0;border:0;padding:0;margin:0"
tabindex="0" tabindex="0"
value=""
/> />
</div>, </div>,
<div <div
@ -498,8 +500,9 @@ Array [
role="tree" role="tree"
> >
<input <input
style="width: 0px; height: 0px; display: flex; overflow: hidden; opacity: 0;" style="width: 0px; height: 0px; display: flex; overflow: hidden; opacity: 0; border: 0px; padding: 0px; margin: 0px;"
tabindex="0" tabindex="0"
value=""
/> />
</div>, </div>,
<div <div
@ -749,8 +752,9 @@ Array [
role="tree" role="tree"
> >
<input <input
style="width: 0px; height: 0px; display: flex; overflow: hidden; opacity: 0;" style="width: 0px; height: 0px; display: flex; overflow: hidden; opacity: 0; border: 0px; padding: 0px; margin: 0px;"
tabindex="0" tabindex="0"
value=""
/> />
</div>, </div>,
<div <div
@ -898,8 +902,9 @@ Array [
role="tree" role="tree"
> >
<input <input
style="width: 0px; height: 0px; display: flex; overflow: hidden; opacity: 0;" style="width: 0px; height: 0px; display: flex; overflow: hidden; opacity: 0; border: 0px; padding: 0px; margin: 0px;"
tabindex="0" tabindex="0"
value=""
/> />
</div>, </div>,
<div <div
@ -1149,8 +1154,9 @@ Array [
role="tree" role="tree"
> >
<input <input
style="width: 0px; height: 0px; display: flex; overflow: hidden; opacity: 0;" style="width: 0px; height: 0px; display: flex; overflow: hidden; opacity: 0; border: 0px; padding: 0px; margin: 0px;"
tabindex="0" tabindex="0"
value=""
/> />
</div>, </div>,
<div <div
@ -1298,8 +1304,9 @@ Array [
role="tree" role="tree"
> >
<input <input
style="width: 0px; height: 0px; display: flex; overflow: hidden; opacity: 0;" style="width: 0px; height: 0px; display: flex; overflow: hidden; opacity: 0; border: 0px; padding: 0px; margin: 0px;"
tabindex="0" tabindex="0"
value=""
/> />
</div>, </div>,
<div <div
@ -1438,8 +1445,9 @@ Array [
role="tree" role="tree"
> >
<input <input
style="width: 0px; height: 0px; display: flex; overflow: hidden; opacity: 0;" style="width: 0px; height: 0px; display: flex; overflow: hidden; opacity: 0; border: 0px; padding: 0px; margin: 0px;"
tabindex="0" tabindex="0"
value=""
/> />
</div>, </div>,
<div <div
@ -1578,8 +1586,9 @@ Array [
role="tree" role="tree"
> >
<input <input
style="width: 0px; height: 0px; display: flex; overflow: hidden; opacity: 0;" style="width: 0px; height: 0px; display: flex; overflow: hidden; opacity: 0; border: 0px; padding: 0px; margin: 0px;"
tabindex="0" tabindex="0"
value=""
/> />
</div>, </div>,
<div <div
@ -1829,8 +1838,9 @@ Array [
role="tree" role="tree"
> >
<input <input
style="width: 0px; height: 0px; display: flex; overflow: hidden; opacity: 0;" style="width: 0px; height: 0px; display: flex; overflow: hidden; opacity: 0; border: 0px; padding: 0px; margin: 0px;"
tabindex="0" tabindex="0"
value=""
/> />
</div>, </div>,
<div <div
@ -2173,8 +2183,9 @@ Array [
role="tree" role="tree"
> >
<input <input
style="width: 0px; height: 0px; display: flex; overflow: hidden; opacity: 0;" style="width: 0px; height: 0px; display: flex; overflow: hidden; opacity: 0; border: 0px; padding: 0px; margin: 0px;"
tabindex="0" tabindex="0"
value=""
/> />
</div>, </div>,
<div <div
@ -2517,8 +2528,9 @@ Array [
role="tree" role="tree"
> >
<input <input
style="width: 0px; height: 0px; display: flex; overflow: hidden; opacity: 0;" style="width: 0px; height: 0px; display: flex; overflow: hidden; opacity: 0; border: 0px; padding: 0px; margin: 0px;"
tabindex="0" tabindex="0"
value=""
/> />
</div>, </div>,
<div <div

5
package.json

@ -1,6 +1,6 @@
{ {
"name": "antd", "name": "antd",
"version": "4.0.0-alpha.3", "version": "4.0.0-alpha.4",
"description": "An enterprise-class UI design language and React components implementation", "description": "An enterprise-class UI design language and React components implementation",
"keywords": [ "keywords": [
"ant", "ant",
@ -146,6 +146,7 @@
"devDependencies": { "devDependencies": {
"@ant-design/colors": "^3.1.0", "@ant-design/colors": "^3.1.0",
"@ant-design/tools": "^8.0.4", "@ant-design/tools": "^8.0.4",
"@formatjs/intl-relativetimeformat": "^4.0.1",
"@packtracker/webpack-plugin": "^2.0.1", "@packtracker/webpack-plugin": "^2.0.1",
"@sentry/browser": "^5.4.0", "@sentry/browser": "^5.4.0",
"@types/classnames": "^2.2.8", "@types/classnames": "^2.2.8",
@ -167,7 +168,7 @@
"bisheng-plugin-toc": "^0.4.4", "bisheng-plugin-toc": "^0.4.4",
"bundlesize": "^0.18.0", "bundlesize": "^0.18.0",
"chalk": "^2.4.2", "chalk": "^2.4.2",
"cross-env": "^5.2.0", "cross-env": "^6.0.0",
"css-split-webpack-plugin": "^0.2.6", "css-split-webpack-plugin": "^0.2.6",
"dekko": "^0.2.1", "dekko": "^0.2.1",
"docsearch.js": "^2.6.3", "docsearch.js": "^2.6.3",

4
site/theme/template/Layout/index.jsx

@ -2,6 +2,10 @@ import React from 'react';
import ReactDOM from 'react-dom'; import ReactDOM from 'react-dom';
import PropTypes from 'prop-types'; import PropTypes from 'prop-types';
import { enquireScreen } from 'enquire-js'; import { enquireScreen } from 'enquire-js';
// https://github.com/formatjs/react-intl/issues/1487
import '@formatjs/intl-relativetimeformat/polyfill';
import '@formatjs/intl-relativetimeformat/dist/locale-data/zh';
import '@formatjs/intl-relativetimeformat/dist/locale-data/en';
import { IntlProvider } from 'react-intl'; import { IntlProvider } from 'react-intl';
import { Helmet } from 'react-helmet'; import { Helmet } from 'react-helmet';
import 'moment/locale/zh-cn'; import 'moment/locale/zh-cn';

Loading…
Cancel
Save