From 326484465f75d9638f62565d857d7db9174fabe9 Mon Sep 17 00:00:00 2001 From: Jack Date: Wed, 13 Nov 2019 14:34:10 +0800 Subject: [PATCH 01/42] fix: type interface SliderProps (#19713) --- components/slider/index.tsx | 1 + 1 file changed, 1 insertion(+) diff --git a/components/slider/index.tsx b/components/slider/index.tsx index 01103e78e4..ff61df4f9f 100644 --- a/components/slider/index.tsx +++ b/components/slider/index.tsx @@ -31,6 +31,7 @@ export interface SliderProps { prefixCls?: string; tooltipPrefixCls?: string; range?: boolean; + reverse?: boolean; min?: number; max?: number; step?: number | null; From dfe7fd3231cc38843e0566312055e8663778d76c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=8F=B6=E6=9E=AB?= Date: Wed, 13 Nov 2019 17:29:46 +0800 Subject: [PATCH 02/42] feat: code add stackblitz (#19714) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * feat: code add stackblitz * fix: style * Update site/theme/static/demo.less Co-Authored-By: 偏右 --- package.json | 1 + site/theme/en-US.js | 1 + site/theme/static/demo.less | 10 +++++ site/theme/template/Content/Demo.jsx | 55 ++++++++++++++++++++-------- site/theme/zh-CN.js | 1 + 5 files changed, 52 insertions(+), 16 deletions(-) diff --git a/package.json b/package.json index 1246880fea..48078bcbef 100644 --- a/package.json +++ b/package.json @@ -147,6 +147,7 @@ "@ant-design/tools": "^8.0.4", "@packtracker/webpack-plugin": "^2.0.1", "@sentry/browser": "^5.4.0", + "@stackblitz/sdk": "^1.3.0", "@types/classnames": "^2.2.8", "@types/gtag.js": "^0.0.3", "@types/lodash": "^4.14.139", diff --git a/site/theme/en-US.js b/site/theme/en-US.js index 2b7ddffb7d..35553d1c0e 100644 --- a/site/theme/en-US.js +++ b/site/theme/en-US.js @@ -24,6 +24,7 @@ module.exports = { 'app.demo.code.hide': 'Hide code', 'app.demo.codepen': 'Open in CodePen', 'app.demo.codesandbox': 'Open in CodeSandbox', + 'app.demo.stackblitz': 'Open in Stackblitz', 'app.demo.riddle': 'Open in Riddle', 'app.home.slogan': "The world's second most popular React UI framework", 'app.home.introduce': diff --git a/site/theme/static/demo.less b/site/theme/static/demo.less index fd7c9145c2..fb244d4500 100644 --- a/site/theme/static/demo.less +++ b/site/theme/static/demo.less @@ -193,6 +193,16 @@ } } + &-code-action { + width: 20px; + height: 20px; + color: @site-text-color-secondary; + font-size: 16px; + line-height: 18px; + cursor: pointer; + transition: all 0.24s; + } + &-code-copy { width: 20px; height: 20px; diff --git a/site/theme/template/Content/Demo.jsx b/site/theme/template/Content/Demo.jsx index c57ea0d97a..322d3cfc1d 100644 --- a/site/theme/template/Content/Demo.jsx +++ b/site/theme/template/Content/Demo.jsx @@ -6,6 +6,7 @@ import CopyToClipboard from 'react-copy-to-clipboard'; import classNames from 'classnames'; import LZString from 'lz-string'; import { Icon, Tooltip } from 'antd'; +import stackblitzSdk from '@stackblitz/sdk'; import EditButton from './EditButton'; import ErrorBoundary from './ErrorBoundary'; import BrowserFrame from '../BrowserFrame'; @@ -98,8 +99,16 @@ class Demo extends React.Component { render() { const { - meta, src, content, preview, highlightedCode, style, - highlightedStyle, expand, utils, intl: { locale }, + meta, + src, + content, + preview, + highlightedCode, + style, + highlightedStyle, + expand, + utils, + intl: { locale }, } = this.props; const { copied, copyTooltipVisible } = this.state; if (!this.liveDemo) { @@ -181,30 +190,34 @@ class Demo extends React.Component { }, { react: 'latest', 'react-dom': 'latest', antd: 'latest' }, ); - const codesanboxPrefillConfig = { - files: { - 'package.json': { - content: { - dependencies, - }, - }, - 'index.css': { - content: (style || '').replace(new RegExp(`#${meta.id}\\s*`, 'g'), ''), - }, - 'index.js': { - content: ` + const indexJsContent = ` import React from 'react'; import ReactDOM from 'react-dom'; import 'antd/dist/antd.css'; import './index.css'; ${sourceCode.replace('mountNode', "document.getElementById('container')")} - `, - }, + `; + const indexCssContent = (style || '').replace(new RegExp(`#${meta.id}\\s*`, 'g'), ''); + const codesanboxPrefillConfig = { + files: { + 'package.json': { content: { dependencies } }, + 'index.css': { content: indexCssContent }, + 'index.js': { content: indexJsContent }, 'index.html': { content: html, }, }, }; + const stackblitzPrefillConfig = { + title: `${localizedTitle} - Ant Design Demo`, + template: 'create-react-app', + dependencies, + files: { + 'index.css': indexCssContent, + 'index.js': indexJsContent, + 'index.html': html, + }, + }; return (
@@ -276,6 +289,16 @@ ${sourceCode.replace('mountNode', "document.getElementById('container')")} /> + }> + { + stackblitzSdk.openProject(stackblitzPrefillConfig); + }} + > + + + this.handleCodeCopied(meta.id)}> Date: Thu, 14 Nov 2019 10:18:03 +0800 Subject: [PATCH 03/42] fix: add missing null option type (#19722) See-also: https://ant.design/components/table/#components-table-demo-reset-filter --- components/table/interface.tsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/components/table/interface.tsx b/components/table/interface.tsx index 6f16089e1f..86cc4d83d0 100644 --- a/components/table/interface.tsx +++ b/components/table/interface.tsx @@ -55,7 +55,7 @@ export interface ColumnProps { className?: string; fixed?: boolean | typeof ColumnFixedPlacements[number]; filterIcon?: React.ReactNode | ((filtered: boolean) => React.ReactNode); - filteredValue?: any[]; + filteredValue?: any[] | null; sortOrder?: SortOrder | boolean; children?: ColumnProps[]; onCellClick?: (record: T, event: Event) => void; From 8b705e3224c33339fdb360c15bced9175b2c4932 Mon Sep 17 00:00:00 2001 From: cnjs <1269075501@qq.com> Date: Thu, 14 Nov 2019 16:21:20 +0800 Subject: [PATCH 04/42] fix: update Select type interface (#19730) * fix: update Select type interface * format: Select type interface --- components/select/index.tsx | 1 + 1 file changed, 1 insertion(+) diff --git a/components/select/index.tsx b/components/select/index.tsx index 7d7b68fa9b..943400edd0 100755 --- a/components/select/index.tsx +++ b/components/select/index.tsx @@ -95,6 +95,7 @@ export interface OptionProps { children?: React.ReactNode; className?: string; style?: React.CSSProperties; + [key: string]: any; } export interface OptGroupProps { From 4079f363400bf73732333ecc3a3c238d7c594853 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E9=AA=97=E4=BD=A0=E6=98=AF=E5=B0=8F=E7=8C=AB=E5=92=AA?= Date: Thu, 14 Nov 2019 21:34:13 +0800 Subject: [PATCH 05/42] Revert "fix: update Select type interface (#19730)" (#19733) This reverts commit 8b705e3224c33339fdb360c15bced9175b2c4932. --- components/select/index.tsx | 1 - 1 file changed, 1 deletion(-) diff --git a/components/select/index.tsx b/components/select/index.tsx index 943400edd0..7d7b68fa9b 100755 --- a/components/select/index.tsx +++ b/components/select/index.tsx @@ -95,7 +95,6 @@ export interface OptionProps { children?: React.ReactNode; className?: string; style?: React.CSSProperties; - [key: string]: any; } export interface OptGroupProps { From 2f30c806a38a1d44f66a12c43fe9156fa0a339e5 Mon Sep 17 00:00:00 2001 From: Jelle de Jong Date: Fri, 15 Nov 2019 09:42:17 +0100 Subject: [PATCH 06/42] fix: Update NL-nl locales (#19734) * Update NL-nl locales * Fix for tests --- .../__snapshots__/index.test.js.snap | 32 +++++++++---------- components/locale/nl_NL.tsx | 19 +++++++++++ 2 files changed, 35 insertions(+), 16 deletions(-) diff --git a/components/locale-provider/__tests__/__snapshots__/index.test.js.snap b/components/locale-provider/__tests__/__snapshots__/index.test.js.snap index 48b5292742..1efde460ac 100644 --- a/components/locale-provider/__tests__/__snapshots__/index.test.js.snap +++ b/components/locale-provider/__tests__/__snapshots__/index.test.js.snap @@ -173135,7 +173135,7 @@ exports[`Locale Provider should display the text as nl 1`] = ` class="ant-pagination-item-link" > Date: Fri, 15 Nov 2019 17:23:14 +0800 Subject: [PATCH 07/42] fix: drawer footer fixed (#19751) * fix footer fiexd * fix test --- components/drawer/demo/form-in-drawer.md | 3 ++- components/drawer/style/drawer.less | 4 ++++ 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/components/drawer/demo/form-in-drawer.md b/components/drawer/demo/form-in-drawer.md index 34945afac5..184d265fa9 100644 --- a/components/drawer/demo/form-in-drawer.md +++ b/components/drawer/demo/form-in-drawer.md @@ -45,6 +45,7 @@ class DrawerForm extends React.Component { width={720} onClose={this.onClose} visible={this.state.visible} + bodyStyle={{ paddingBottom: 80 }} >
@@ -140,7 +141,7 @@ class DrawerForm extends React.Component {
Date: Fri, 15 Nov 2019 19:00:56 +0100 Subject: [PATCH 08/42] Fix Documentation for Menu API (#19757) --- components/menu/index.en-US.md | 4 ++-- components/menu/index.zh-CN.md | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/components/menu/index.en-US.md b/components/menu/index.en-US.md index c0ef714d64..4c83958bed 100644 --- a/components/menu/index.en-US.md +++ b/components/menu/index.en-US.md @@ -16,12 +16,12 @@ More layouts with navigation: [Layout](/components/layout). ## API ```html - + Menu SubMenuItem - + ``` ### Menu diff --git a/components/menu/index.zh-CN.md b/components/menu/index.zh-CN.md index 7aed8eaa48..01132d89bb 100644 --- a/components/menu/index.zh-CN.md +++ b/components/menu/index.zh-CN.md @@ -17,12 +17,12 @@ subtitle: 导航菜单 ## API ```html - + 菜单项 子菜单项 - + ``` ### Menu From 26b9e1f887be342a410ca6363296fc0cbcc3363f Mon Sep 17 00:00:00 2001 From: Wei Zhu Date: Sat, 16 Nov 2019 11:39:13 +0800 Subject: [PATCH 09/42] test: introduce codesandbox ci (#19721) * introduce codesandbox ci * set skipLibCheck temporarilly * remove packtracker temporarilly * debug env --- .codesandbox/ci.json | 3 +++ package.json | 1 + tsconfig.json | 3 ++- webpack.config.js | 10 ---------- 4 files changed, 6 insertions(+), 11 deletions(-) create mode 100644 .codesandbox/ci.json diff --git a/.codesandbox/ci.json b/.codesandbox/ci.json new file mode 100644 index 0000000000..baa4107aaa --- /dev/null +++ b/.codesandbox/ci.json @@ -0,0 +1,3 @@ +{ + "sandboxes": ["wk04r016q8"] +} diff --git a/package.json b/package.json index 48078bcbef..ae1b11edaa 100644 --- a/package.json +++ b/package.json @@ -42,6 +42,7 @@ "scripts": { "api-collection": "antd-tools run api-collection", "authors": "git log --format='%aN <%aE>' | sort -u | grep -v 'users.noreply.github.com' | grep -v 'gitter.im' | grep -v '.local>' | grep -v 'alibaba-inc.com' | grep -v 'alipay.com' | grep -v 'taobao.com' > AUTHORS.txt", + "build": "node -e 'console.log(process.env)' && npm run compile && npm run dist", "bundlesize": "bundlesize", "check-commit": "node ./scripts/check-commit.js", "compile": "antd-tools run compile", diff --git a/tsconfig.json b/tsconfig.json index 850ce0de17..cf511ab415 100644 --- a/tsconfig.json +++ b/tsconfig.json @@ -14,7 +14,8 @@ "noUnusedLocals": true, "noImplicitAny": true, "target": "es6", - "lib": ["dom", "es2017"] + "lib": ["dom", "es2017"], + "skipLibCheck": true }, "exclude": ["node_modules", "lib", "es"] } diff --git a/webpack.config.js b/webpack.config.js index 0b01f92d9d..cc2abb9a25 100644 --- a/webpack.config.js +++ b/webpack.config.js @@ -1,7 +1,6 @@ /* eslint no-param-reassign: 0 */ // This config is for building dist files const getWebpackConfig = require('@ant-design/tools/lib/getWebpackConfig'); -const PacktrackerPlugin = require('@packtracker/webpack-plugin'); const { webpack } = getWebpackConfig; @@ -36,15 +35,6 @@ if (process.env.RUN_ENV === 'PRODUCTION') { ignoreMomentLocale(config); externalMoment(config); addLocales(config); - // https://docs.packtracker.io/uploading-your-webpack-stats/webpack-plugin - config.plugins.push( - new PacktrackerPlugin({ - project_token: '8adbb892-ee4a-4d6f-93bb-a03219fb6778', - upload: process.env.CI === 'true', - fail_build: true, - exclude_assets: name => !['antd.min.js', 'antd.min.css'].includes(name), - }), - ); }); } From 5ecd32a83f185327973794ff9808aa184a0f750e Mon Sep 17 00:00:00 2001 From: afc163 Date: Fri, 15 Nov 2019 17:30:05 +0800 Subject: [PATCH 10/42] site: :memo: Add GA event for opening in stackblitz --- site/theme/template/Content/Demo.jsx | 1 + 1 file changed, 1 insertion(+) diff --git a/site/theme/template/Content/Demo.jsx b/site/theme/template/Content/Demo.jsx index 322d3cfc1d..26051f59e1 100644 --- a/site/theme/template/Content/Demo.jsx +++ b/site/theme/template/Content/Demo.jsx @@ -293,6 +293,7 @@ ${sourceCode.replace('mountNode', "document.getElementById('container')")} { + this.track({ type: 'stackblitz', demo: meta.id }); stackblitzSdk.openProject(stackblitzPrefillConfig); }} > From 91faa7e4cb5bfc89b551aac2424685a342c5cf56 Mon Sep 17 00:00:00 2001 From: afc163 Date: Sat, 16 Nov 2019 16:24:28 +0800 Subject: [PATCH 11/42] :clapper: improve notification placement demo --- .../__tests__/__snapshots__/demo.test.js.snap | 158 ++++++++++++------ components/notification/demo/placement.md | 46 +++-- 2 files changed, 127 insertions(+), 77 deletions(-) diff --git a/components/notification/__tests__/__snapshots__/demo.test.js.snap b/components/notification/__tests__/__snapshots__/demo.test.js.snap index 0c458c1333..35169fe4f4 100644 --- a/components/notification/__tests__/__snapshots__/demo.test.js.snap +++ b/components/notification/__tests__/__snapshots__/demo.test.js.snap @@ -46,64 +46,116 @@ exports[`renders ./components/notification/demo/duration.md correctly 1`] = ` exports[`renders ./components/notification/demo/placement.md correctly 1`] = `
-
- -
+ + diff --git a/components/notification/demo/placement.md b/components/notification/demo/placement.md index cd652cfb6d..44df9428fe 100755 --- a/components/notification/demo/placement.md +++ b/components/notification/demo/placement.md @@ -7,44 +7,42 @@ title: ## zh-CN -可以设置通知从右上角、右下角、左下角、左上角弹出。 +通知从右上角、右下角、左下角、左上角弹出。 ## en-US A notification box can appear from the `topRight`, `bottomRight`, `bottomLeft` or `topLeft` of the viewport. ```jsx -import { Button, Select, notification } from 'antd'; +import { Button, Icon, notification, Divider } from 'antd'; -const { Option } = Select; -const options = ['topLeft', 'topRight', 'bottomLeft', 'bottomRight']; -const openNotification = () => { - notification.open({ - message: 'Notification Title', +const openNotification = placement => { + notification.info({ + message: `Notification ${placement}`, description: 'This is the content of the notification. This is the content of the notification. This is the content of the notification.', + placement, }); }; ReactDOM.render(
- - + + + +
, mountNode, From 5ff193cf609d4bd5c431cf878883bfb2a068d131 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E4=BA=8C=E8=B4=A7=E6=9C=BA=E5=99=A8=E4=BA=BA?= Date: Sun, 17 Nov 2019 11:06:37 +0800 Subject: [PATCH 12/42] docs: 3.25.2 changelog (#19768) * docs: 3.25.2 changelog * fix link --- CHANGELOG.en-US.md | 12 ++++++++++++ CHANGELOG.zh-CN.md | 12 ++++++++++++ package.json | 2 +- 3 files changed, 25 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.en-US.md b/CHANGELOG.en-US.md index 8637604717..67b09a728e 100644 --- a/CHANGELOG.en-US.md +++ b/CHANGELOG.en-US.md @@ -15,6 +15,18 @@ timeline: true --- +## 3.25.2 + +`2019-11-17` + +- 🐞 Fix Upload List do not have tooltip when upload failed. [#19689](https://github.com/ant-design/ant-design/pull/19689) [@qq645381995](https://github.com/qq645381995) +- 💄 Fix Transfer search style to avoid text overlap with clear icon. [#19693](https://github.com/ant-design/ant-design/pull/19693) [@Abdullah700](https://github.com/Abdullah700) +- 🇳🇱 Update `NL-nl` locales. [#19734](https://github.com/ant-design/ant-design/pull/19734) [@hoest](https://github.com/hoest) +- TypeScript + - 🐞 Fix Table FilterDropdownProps definition. [#19701](https://github.com/ant-design/ant-design/pull/19701) [@DeanVanNiekerk](https://github.com/DeanVanNiekerk) + - 🛠 Slider add `reverse` definition. [#19713](https://github.com/ant-design/ant-design/pull/19713) [@jacklee814](https://github.com/jacklee814) + - 🐞 Update Table `filteredValue` definition. [#19722](https://github.com/ant-design/ant-design/pull/19722) [@andelf](https://github.com/andelf) + ## 3.25.1 `2019-11-10` diff --git a/CHANGELOG.zh-CN.md b/CHANGELOG.zh-CN.md index baa24ca0e3..277cc4d865 100644 --- a/CHANGELOG.zh-CN.md +++ b/CHANGELOG.zh-CN.md @@ -15,6 +15,18 @@ timeline: true --- +## 3.25.2 + +`2019-11-17` + +- 🐞 修复 Upload List 上传错误时没有鼠标悬浮提示的问题。[#19689](https://github.com/ant-design/ant-design/pull/19689) [@qq645381995](https://github.com/qq645381995) +- 💄 修复 Transfer 输入框内容会与清除按钮重叠的问题。[#19693](https://github.com/ant-design/ant-design/pull/19693) [@Abdullah700](https://github.com/Abdullah700) +- 🇳🇱 更新 `NL-nl` 国际化。[#19734](https://github.com/ant-design/ant-design/pull/19734) [@hoest](https://github.com/hoest) +- TypeScript + - 🐞 修复 Table FilterDropdownProps 定义。[#19701](https://github.com/ant-design/ant-design/pull/19701) [@DeanVanNiekerk](https://github.com/DeanVanNiekerk) + - 🛠 Slider 添加 `reverse` 定义。[#19713](https://github.com/ant-design/ant-design/pull/19713) [@jacklee814](https://github.com/jacklee814) + - 🐞 更新 Table `filteredValue` 定义。[#19722](https://github.com/ant-design/ant-design/pull/19722) [@andelf](https://github.com/andelf) + ## 3.25.1 `2019-11-10` diff --git a/package.json b/package.json index ae1b11edaa..00e0569dc1 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "antd", - "version": "3.25.1", + "version": "3.25.2", "description": "An enterprise-class UI design language and React components implementation", "keywords": [ "ant", From eefa24b6fad9f6e872f06302f8b460a9a0204b89 Mon Sep 17 00:00:00 2001 From: "depfu[bot]" <23717796+depfu[bot]@users.noreply.github.com> Date: Sun, 17 Nov 2019 13:41:03 +0000 Subject: [PATCH 13/42] Update stylelint to version 12.0.0 --- package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.json b/package.json index 00e0569dc1..a80435d33b 100644 --- a/package.json +++ b/package.json @@ -234,7 +234,7 @@ "rimraf": "^3.0.0", "scrollama": "^2.0.0", "simple-git": "^1.113.0", - "stylelint": "^11.0.0", + "stylelint": "^12.0.0", "stylelint-config-prettier": "^6.0.0", "stylelint-config-rational-order": "^0.1.2", "stylelint-config-standard": "^19.0.0", From c34f9ea4b44be5263a300f1604012cd11253886f Mon Sep 17 00:00:00 2001 From: orzyyyy Date: Sun, 17 Nov 2019 19:37:44 +0800 Subject: [PATCH 14/42] perf: use peaceiris/actions-gh-pages for deploy --- .github/workflows/deploy-site.yml | 23 +++++++++++++++-------- 1 file changed, 15 insertions(+), 8 deletions(-) diff --git a/.github/workflows/deploy-site.yml b/.github/workflows/deploy-site.yml index a2813160f0..9ac9e384b5 100644 --- a/.github/workflows/deploy-site.yml +++ b/.github/workflows/deploy-site.yml @@ -9,13 +9,20 @@ jobs: build-and-deploy: runs-on: ubuntu-latest steps: - - name: Checkout + - name: checkout uses: actions/checkout@master - - name: Deploy website - uses: JamesIves/github-pages-deploy-action@master - env: - ACCESS_TOKEN: ${{ secrets.ACCESS_TOKEN }} - BRANCH: gh-pages - FOLDER: _site - BUILD_SCRIPT: npm install && npm run predeploy + - name: install + run: npm install + + - name: build + run: npm run predeploy + + - name: deploy + uses: peaceiris/actions-gh-pages@v2.5.0 + env: + ACTIONS_DEPLOY_KEY: ${{ secrets.ACCESS_TOKEN }} + PUBLISH_BRANCH: gh-pages + PUBLISH_DIR: ./_site + with: + emptyCommits: false From 62b2ba38ee7ea27f02a8bcad3d5d39b35244d50f Mon Sep 17 00:00:00 2001 From: orzyyyy Date: Sun, 17 Nov 2019 19:38:49 +0800 Subject: [PATCH 15/42] fix: adjust indent --- .github/workflows/deploy-site.yml | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/.github/workflows/deploy-site.yml b/.github/workflows/deploy-site.yml index 9ac9e384b5..52f5c2fc5e 100644 --- a/.github/workflows/deploy-site.yml +++ b/.github/workflows/deploy-site.yml @@ -19,10 +19,10 @@ jobs: run: npm run predeploy - name: deploy - uses: peaceiris/actions-gh-pages@v2.5.0 - env: - ACTIONS_DEPLOY_KEY: ${{ secrets.ACCESS_TOKEN }} - PUBLISH_BRANCH: gh-pages - PUBLISH_DIR: ./_site - with: - emptyCommits: false + uses: peaceiris/actions-gh-pages@v2.5.0 + env: + ACTIONS_DEPLOY_KEY: ${{ secrets.ACCESS_TOKEN }} + PUBLISH_BRANCH: gh-pages + PUBLISH_DIR: ./_site + with: + emptyCommits: false From ce59719a55350aae5b8c39664b0fa822f70bdb80 Mon Sep 17 00:00:00 2001 From: orzyyyy Date: Mon, 18 Nov 2019 07:51:49 +0800 Subject: [PATCH 16/42] fix: missing config file of circleci --- package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.json b/package.json index a80435d33b..915483f65b 100644 --- a/package.json +++ b/package.json @@ -46,7 +46,7 @@ "bundlesize": "bundlesize", "check-commit": "node ./scripts/check-commit.js", "compile": "antd-tools run compile", - "predeploy": "antd-tools run clean && npm run site && cp netlify.toml CNAME _site && cp .circleci/config.yml _site && npm run site:test", + "predeploy": "antd-tools run clean && npm run site && cp netlify.toml CNAME _site && cp .circleci/ _site -r && npm run site:test", "deploy": "bisheng gh-pages --push-only", "deploy:china-mirror": "git checkout gh-pages && git pull origin gh-pages && git push git@gitee.com:ant-design/ant-design.git gh-pages", "dist": "antd-tools run dist", From 4cae32842fc8d376fad6891b8327752a8d9b51c1 Mon Sep 17 00:00:00 2001 From: Wei Zhu Date: Mon, 18 Nov 2019 12:47:55 +0800 Subject: [PATCH 17/42] chore: add packtracker back --- package.json | 2 +- webpack.config.js | 13 +++++++++++++ 2 files changed, 14 insertions(+), 1 deletion(-) diff --git a/package.json b/package.json index 915483f65b..d5227380cc 100644 --- a/package.json +++ b/package.json @@ -42,7 +42,7 @@ "scripts": { "api-collection": "antd-tools run api-collection", "authors": "git log --format='%aN <%aE>' | sort -u | grep -v 'users.noreply.github.com' | grep -v 'gitter.im' | grep -v '.local>' | grep -v 'alibaba-inc.com' | grep -v 'alipay.com' | grep -v 'taobao.com' > AUTHORS.txt", - "build": "node -e 'console.log(process.env)' && npm run compile && npm run dist", + "build": "npm run compile && npm run dist", "bundlesize": "bundlesize", "check-commit": "node ./scripts/check-commit.js", "compile": "antd-tools run compile", diff --git a/webpack.config.js b/webpack.config.js index cc2abb9a25..98a98f795c 100644 --- a/webpack.config.js +++ b/webpack.config.js @@ -1,6 +1,7 @@ /* eslint no-param-reassign: 0 */ // This config is for building dist files const getWebpackConfig = require('@ant-design/tools/lib/getWebpackConfig'); +const PacktrackerPlugin = require('@packtracker/webpack-plugin'); const { webpack } = getWebpackConfig; @@ -35,6 +36,18 @@ if (process.env.RUN_ENV === 'PRODUCTION') { ignoreMomentLocale(config); externalMoment(config); addLocales(config); + // skip codesandbox ci + if (!process.env.CSB_REPO) { + // https://docs.packtracker.io/uploading-your-webpack-stats/webpack-plugin + config.plugins.push( + new PacktrackerPlugin({ + project_token: '8adbb892-ee4a-4d6f-93bb-a03219fb6778', + upload: process.env.CI === 'true', + fail_build: true, + exclude_assets: name => !['antd.min.js', 'antd.min.css'].includes(name), + }), + ); + } }); } From d2e98b1bb9f2e65f969149055ab8ab45767bd6ab Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=8F=B6=E6=9E=AB?= Date: Mon, 18 Nov 2019 18:20:04 +0800 Subject: [PATCH 18/42] fix: style (#19783) --- .../__snapshots__/components.test.js.snap | 12 +++-- components/upload/UploadList.tsx | 6 ++- .../__tests__/__snapshots__/demo.test.js.snap | 52 ++++++++++++++----- .../__snapshots__/uploadlist.test.js.snap | 48 ++++++++++++----- components/upload/style/index.less | 6 +++ 5 files changed, 94 insertions(+), 30 deletions(-) diff --git a/components/config-provider/__tests__/__snapshots__/components.test.js.snap b/components/config-provider/__tests__/__snapshots__/components.test.js.snap index c6d08c7f02..0ff571740c 100644 --- a/components/config-provider/__tests__/__snapshots__/components.test.js.snap +++ b/components/config-provider/__tests__/__snapshots__/components.test.js.snap @@ -17362,7 +17362,9 @@ exports[`ConfigProvider components Upload configProvider 1`] = `
-
+
-
+
-
+
{
); - + const listContainerNameClass = classNames({ + [`${prefixCls}-list-picture-card-container`]: listType === 'picture-card', + }); return ( -
+
{file.status === 'error' ? {dom} : {dom}}
); diff --git a/components/upload/__tests__/__snapshots__/demo.test.js.snap b/components/upload/__tests__/__snapshots__/demo.test.js.snap index 5b45820448..bdcd76daaa 100644 --- a/components/upload/__tests__/__snapshots__/demo.test.js.snap +++ b/components/upload/__tests__/__snapshots__/demo.test.js.snap @@ -33,7 +33,9 @@ exports[`renders ./components/upload/demo/defaultFileList.md correctly 1`] = `
-
+
-
+
-
+
@@ -340,7 +346,9 @@ exports[`renders ./components/upload/demo/fileList.md correctly 1`] = `
-
+
-
+
-
+
-
+
-
+
-
+
@@ -1014,7 +1032,9 @@ exports[`renders ./components/upload/demo/picture-style.md correctly 1`] = `
-
+
-
+
@@ -1203,7 +1225,9 @@ exports[`renders ./components/upload/demo/picture-style.md correctly 1`] = `
-
+
-
+
diff --git a/components/upload/__tests__/__snapshots__/uploadlist.test.js.snap b/components/upload/__tests__/__snapshots__/uploadlist.test.js.snap index 67476e880d..9961cf2cc9 100644 --- a/components/upload/__tests__/__snapshots__/uploadlist.test.js.snap +++ b/components/upload/__tests__/__snapshots__/uploadlist.test.js.snap @@ -403,7 +403,9 @@ exports[`Upload List should non-image format file preview 1`] = `
-
+
-
+
-
+
-
+
-
+
-
+
-
+
-
+
-
+
-
+
-
+
-
+
Date: Mon, 18 Nov 2019 15:02:25 +0100 Subject: [PATCH 19/42] chore: Update sk_SK locales (#19787) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * Update sk_SK locales ### 🤔 This is a ... - [ ] New feature - [x] Bug fix - [ ] Site / document update - [ ] Component style update - [ ] TypeScript definition update - [ ] Refactoring - [ ] Code style optimization - [ ] Test Case - [ ] Branch merge - [ ] Other (about what?) ### 🔗 Related issue link sk_SK locales are missing some translations. * update snapshot --- .../__snapshots__/index.test.js.snap | 32 +++++++++---------- components/locale/sk_SK.tsx | 19 +++++++++++ 2 files changed, 35 insertions(+), 16 deletions(-) diff --git a/components/locale-provider/__tests__/__snapshots__/index.test.js.snap b/components/locale-provider/__tests__/__snapshots__/index.test.js.snap index 1efde460ac..5522c39dcb 100644 --- a/components/locale-provider/__tests__/__snapshots__/index.test.js.snap +++ b/components/locale-provider/__tests__/__snapshots__/index.test.js.snap @@ -210459,7 +210459,7 @@ exports[`Locale Provider should display the text as sk 1`] = ` class="ant-pagination-item-link" > Date: Mon, 18 Nov 2019 16:02:33 +0100 Subject: [PATCH 20/42] Update link to latest ColumnProps (#19789) * Update link to latest ColumnProps * update CN docs --- components/table/index.en-US.md | 2 +- components/table/index.zh-CN.md | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/components/table/index.en-US.md b/components/table/index.en-US.md index f8483495c6..6fb6230cea 100644 --- a/components/table/index.en-US.md +++ b/components/table/index.en-US.md @@ -62,7 +62,7 @@ const columns = [ | tableLayout | [table-layout](https://developer.mozilla.org/en-US/docs/Web/CSS/table-layout) attribute of table element | - \| 'auto' \| 'fixed' | -
`fixed` when header/columns are fixed, or using `column.ellipsis` | 3.24.0 | | bordered | Whether to show all table borders | boolean | `false` | | | childrenColumnName | The column contains children to display | string\[] | children | 3.4.2 | -| columns | Columns of table | [ColumnProps](https://git.io/vMMXC)\[] | - | | +| columns | Columns of table | [ColumnProps](https://git.io/JeKZW)\[] | - | | | components | Override default table elements | [TableComponents](https://git.io/fANxz) | - | | | dataSource | Data record array to be displayed | any\[] | - | | | defaultExpandAllRows | Expand all rows initially | boolean | `false` | | diff --git a/components/table/index.zh-CN.md b/components/table/index.zh-CN.md index b856920f5d..958742b66b 100644 --- a/components/table/index.zh-CN.md +++ b/components/table/index.zh-CN.md @@ -67,7 +67,7 @@ const columns = [ | tableLayout | 表格元素的 [table-layout](https://developer.mozilla.org/zh-CN/docs/Web/CSS/table-layout) 属性,设为 `fixed` 表示内容不会影响列的布局 | - \| 'auto' \| 'fixed' | 无
固定表头/列或使用了 `column.ellipsis` 时,默认值为 `fixed` | 3.24.0 | | bordered | 是否展示外边框和列边框 | boolean | false | | | childrenColumnName | 指定树形结构的列名 | string\[] | children | 3.4.2 | -| columns | 表格列的配置描述,具体项见下表 | [ColumnProps](https://git.io/vMMXC)\[] | - | | +| columns | 表格列的配置描述,具体项见下表 | [ColumnProps](https://git.io/JeKZW)\[] | - | | | components | 覆盖默认的 table 元素 | [TableComponents](https://git.io/fANxz) | - | | | dataSource | 数据数组 | any\[] | | | | defaultExpandAllRows | 初始时,是否展开所有行 | boolean | false | | From 4d09b26f82839ed0b4c116f71aba61ffdf6f8993 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=8F=AA=E6=8D=B1=E5=AE=85?= Date: Tue, 19 Nov 2019 11:06:41 +0800 Subject: [PATCH 21/42] ci: enable cache and multithreading for GA (#19786) * ci: enable cache for GA * feat: multithreading * fix: pipeline * chore: remove useless step * chore: retrigger * chore: debug * chore: debug * chore: pull hack out * fix: add cache for package-lock.json * chore: remove debug code --- .github/workflows/test.yml | 209 ++++++++++++++++++++++++++++++++++++- 1 file changed, 205 insertions(+), 4 deletions(-) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 293855ded5..1ec8689f54 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -3,16 +3,217 @@ name: test on: [push] jobs: - build: - + setup: runs-on: ubuntu-latest steps: - name: checkout uses: actions/checkout@master + - name: cache package-lock.json + uses: actions/cache@v1 + with: + path: package-temp-dir + key: lock-${{ github.sha }} + + - name: create package-lock.json + run: npm i --package-lock-only + + - name: hack for singe file + run: | + mkdir package-temp-dir + cp package-lock.json package-temp-dir + + - name: cache node_modules + id: node_modules_cache_id + uses: actions/cache@v1 + with: + path: node_modules + key: node_modules-${{ hashFiles('**/package-temp-dir/package-lock.json') }} + - name: install - run: npm install + if: steps.node_modules_cache_id.outputs.cache-hit != 'true' + run: npm ci + + compile: + runs-on: ubuntu-latest + + steps: + - name: checkout + uses: actions/checkout@master + + - name: restore cache from package-lock.json + uses: actions/cache@v1 + with: + path: package-temp-dir + key: lock-${{ github.sha }} + + - name: restore cache from node_modules + uses: actions/cache@v1 + with: + path: node_modules + key: node_modules-${{ hashFiles('**/package-temp-dir/package-lock.json') }} + + - name: cache lib + uses: actions/cache@v1 + with: + path: lib + key: lib-${{ github.sha }} + + - name: cache es + uses: actions/cache@v1 + with: + path: es + key: es-${{ github.sha }} + + - name: compile + run: npm run compile + + - name: check + run: node ./tests/dekko/lib.test.js + + needs: setup + + dist: + runs-on: ubuntu-latest + + steps: + - name: checkout + uses: actions/checkout@master + + - name: restore cache from package-lock.json + uses: actions/cache@v1 + with: + path: package-temp-dir + key: lock-${{ github.sha }} + + - name: restore cache from node_modules + uses: actions/cache@v1 + with: + path: node_modules + key: node_modules-${{ hashFiles('**/package-temp-dir/package-lock.json') }} + + - name: dist + run: npm run dist + + - name: check + run: node ./tests/dekko/dist.test.js - name: test - run: npm run test-all + run: npm test + env: + LIB_DIR: dist + + needs: setup + + lint: + runs-on: ubuntu-latest + + steps: + - name: checkout + uses: actions/checkout@master + + - name: restore cache from package-lock.json + uses: actions/cache@v1 + with: + path: package-temp-dir + key: lock-${{ github.sha }} + + - name: restore cache from node_modules + uses: actions/cache@v1 + with: + path: node_modules + key: node_modules-${{ hashFiles('**/package-temp-dir/package-lock.json') }} + + - name: lint + run: npm run lint + + needs: setup + + node: + runs-on: ubuntu-latest + + steps: + - name: checkout + uses: actions/checkout@master + + - name: restore cache from package-lock.json + uses: actions/cache@v1 + with: + path: package-temp-dir + key: lock-${{ github.sha }} + + - name: restore cache from node_modules + uses: actions/cache@v1 + with: + path: node_modules + key: node_modules-${{ hashFiles('**/package-temp-dir/package-lock.json') }} + + - name: test + run: npm test + + needs: setup + + lib: + runs-on: ubuntu-latest + + steps: + - name: checkout + uses: actions/checkout@master + + - name: restore cache from package-lock.json + uses: actions/cache@v1 + with: + path: package-temp-dir + key: lock-${{ github.sha }} + + - name: restore cache from node_modules + uses: actions/cache@v1 + with: + path: node_modules + key: node_modules-${{ hashFiles('**/package-temp-dir/package-lock.json') }} + + - name: restore cache from lib + uses: actions/cache@v1 + with: + path: lib + key: lib-${{ github.sha }} + + - name: test + run: npm test + env: + LIB_DIR: lib + + needs: compile + + es: + runs-on: ubuntu-latest + + steps: + - name: checkout + uses: actions/checkout@master + + - name: restore cache from package-lock.json + uses: actions/cache@v1 + with: + path: package-temp-dir + key: lock-${{ github.sha }} + + - name: restore cache from node_modules + uses: actions/cache@v1 + with: + path: node_modules + key: node_modules-${{ hashFiles('**/package-temp-dir/package-lock.json') }} + + - name: restore cache from es + uses: actions/cache@v1 + with: + path: es + key: es-${{ github.sha }} + + - name: test + run: npm test + env: + LIB_DIR: es + + needs: compile From eb8dc9f715a53ce7db3b5ba624e43b802692864e Mon Sep 17 00:00:00 2001 From: orzyyyy Date: Tue, 19 Nov 2019 11:18:42 +0800 Subject: [PATCH 22/42] docs: update badge of github action --- README.md | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/README.md b/README.md index 85769b621b..c86ea47585 100644 --- a/README.md +++ b/README.md @@ -10,7 +10,7 @@ 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) ![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) [![](https://badgen.net/npm/v/antd/next)](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/test/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) [![](https://badgen.net/npm/v/antd/next)](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) @@ -36,8 +36,8 @@ English | [简体中文](./README-zh_CN.md) - [Electron](http://electron.atom.io/) | [IE / Edge](http://godban.github.io/browsers-support-badges/)
IE / Edge | [Firefox](http://godban.github.io/browsers-support-badges/)
Firefox | [Chrome](http://godban.github.io/browsers-support-badges/)
Chrome | [Safari](http://godban.github.io/browsers-support-badges/)
Safari | [Opera](http://godban.github.io/browsers-support-badges/)
Opera | [Electron](http://godban.github.io/browsers-support-badges/)
Electron | -| --- | --- | --- | --- | --- | --- | -| IE9, IE10, IE11, Edge | last 2 versions | last 2 versions | last 2 versions | last 2 versions | last 2 versions | +| --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| IE9, IE10, IE11, Edge | last 2 versions | last 2 versions | last 2 versions | last 2 versions | last 2 versions | ## 📦 Install @@ -52,14 +52,14 @@ yarn add antd ## 🔨 Usage ```jsx -import { DatePicker } from 'antd'; +import { DatePicker } from "antd"; ReactDOM.render(, mountNode); ``` And import style manually: ```jsx -import 'antd/dist/antd.css'; // or 'antd/dist/antd.less' +import "antd/dist/antd.css"; // or 'antd/dist/antd.less' ``` Or [import components on demand](https://ant.design/docs/react/getting-started#Import-on-Demand). From 26648cc0b1497d0ee8c1c9abe1435a2bc7a4247e Mon Sep 17 00:00:00 2001 From: "dependabot-preview[bot]" <27856297+dependabot-preview[bot]@users.noreply.github.com> Date: Tue, 19 Nov 2019 19:32:15 +0800 Subject: [PATCH 23/42] chore(deps-dev): bump @typescript-eslint/parser from 2.7.0 to 2.8.0 (#19806) Bumps [@typescript-eslint/parser](https://github.com/typescript-eslint/typescript-eslint/tree/HEAD/packages/parser) from 2.7.0 to 2.8.0. - [Release notes](https://github.com/typescript-eslint/typescript-eslint/releases) - [Changelog](https://github.com/typescript-eslint/typescript-eslint/blob/master/packages/parser/CHANGELOG.md) - [Commits](https://github.com/typescript-eslint/typescript-eslint/commits/v2.8.0/packages/parser) Signed-off-by: dependabot-preview[bot] --- package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.json b/package.json index d5227380cc..9f5b3cdeb4 100644 --- a/package.json +++ b/package.json @@ -159,7 +159,7 @@ "@types/shallowequal": "^1.1.1", "@types/warning": "^3.0.0", "@typescript-eslint/eslint-plugin": "^2.0.0", - "@typescript-eslint/parser": "~2.7.0", + "@typescript-eslint/parser": "~2.8.0", "antd-theme-generator": "^1.1.6", "babel-eslint": "^10.0.1", "babel-plugin-add-react-displayname": "^0.0.5", From 69549a86480155630d88f4fd24ca31c5f2fa7d54 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=81=8F=E5=8F=B3?= Date: Tue, 19 Nov 2019 20:30:44 +0800 Subject: [PATCH 24/42] :bug: fix menu link color inside badge (#19810) close #19809 --- components/menu/style/index.less | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/components/menu/style/index.less b/components/menu/style/index.less index c10e2e3e9c..6ebbb75223 100644 --- a/components/menu/style/index.less +++ b/components/menu/style/index.less @@ -74,6 +74,14 @@ } } + // https://github.com/ant-design/ant-design/issues/19809 + &-item > .@{ant-prefix}-badge > a { + color: @menu-item-color; + &:hover { + color: @menu-highlight-color; + } + } + &-item-divider { height: 1px; overflow: hidden; From 307278783964be681afc7f3012869c47db9348a8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E9=AA=97=E4=BD=A0=E6=98=AF=E5=B0=8F=E7=8C=AB=E5=92=AA?= Date: Wed, 20 Nov 2019 11:46:56 +0800 Subject: [PATCH 25/42] chore: add @types/jest dependencies (#19816) --- package.json | 1 + 1 file changed, 1 insertion(+) diff --git a/package.json b/package.json index 9f5b3cdeb4..ec719aa0b5 100644 --- a/package.json +++ b/package.json @@ -151,6 +151,7 @@ "@stackblitz/sdk": "^1.3.0", "@types/classnames": "^2.2.8", "@types/gtag.js": "^0.0.3", + "@types/jest": "^24.0.23", "@types/lodash": "^4.14.139", "@types/prop-types": "^15.7.1", "@types/raf": "^3.4.0", From c57d7f3a6ccbcd96046b57d08245fc847a91f20d Mon Sep 17 00:00:00 2001 From: Josiah Rooney Date: Wed, 20 Nov 2019 15:39:57 -0800 Subject: [PATCH 26/42] Update index.en-US.md (#19848) Improved the grammar of the documentation. --- components/config-provider/index.en-US.md | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/components/config-provider/index.en-US.md b/components/config-provider/index.en-US.md index adaa004b57..7c8cd6bd4f 100644 --- a/components/config-provider/index.en-US.md +++ b/components/config-provider/index.en-US.md @@ -9,7 +9,7 @@ title: ConfigProvider ## Usage -This component provides a configuration to all React components underneath itself via the [context API](https://facebook.github.io/react/docs/context.html), In the render tree all components will have access to the provided config. +This component provides a configuration to all React components underneath itself via the [context API](https://facebook.github.io/react/docs/context.html). In the render tree all components will have access to the provided config. ```jsx import { ConfigProvider } from 'antd'; @@ -25,7 +25,7 @@ return ( ### Content Security Policy -Some component use dynamic style to support wave effect. You can config `csp` prop if Content Security Policy (CSP) is enabled: +Some components use dynamic style to support wave effect. You can config `csp` prop if Content Security Policy (CSP) is enabled: ```jsx @@ -47,6 +47,6 @@ Some component use dynamic style to support wave effect. You can config `csp` pr ## FAQ -#### Locale problem is still existed in DatePicker even ConfigProvider `locale` is used? +#### Does the locale problem still exist in DatePicker even if ConfigProvider `locale` is used? -Please make sure you set moment locale by `moment.locale('zh-cn')`, or you don't have two moment of different version. +Please make sure you set moment locale by `moment.locale('zh-cn')` or that you don't have two different versions of moment. From 5ff3a77dced89cc270156b4a9ae570d6e99b145c Mon Sep 17 00:00:00 2001 From: Alexander Kachkaev Date: Thu, 21 Nov 2019 03:56:21 +0000 Subject: [PATCH 27/42] Export tooltop helper interfaces (#19846) --- components/tooltip/index.tsx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/components/tooltip/index.tsx b/components/tooltip/index.tsx index a0dc3ee8d2..a82465fc18 100644 --- a/components/tooltip/index.tsx +++ b/components/tooltip/index.tsx @@ -65,12 +65,12 @@ export interface AbstractTooltipProps { export type RenderFunction = () => React.ReactNode; -interface TooltipPropsWithOverlay extends AbstractTooltipProps { +export interface TooltipPropsWithOverlay extends AbstractTooltipProps { title?: React.ReactNode | RenderFunction; overlay: React.ReactNode | RenderFunction; } -interface TooltipPropsWithTitle extends AbstractTooltipProps { +export interface TooltipPropsWithTitle extends AbstractTooltipProps { title: React.ReactNode | RenderFunction; overlay?: React.ReactNode | RenderFunction; } From 3906f4fc009c15fd6c2a5941d53171c1d398f370 Mon Sep 17 00:00:00 2001 From: chen wen jun <731028571@qq.com> Date: Thu, 21 Nov 2019 17:49:36 +0800 Subject: [PATCH 28/42] Update index.en-US.md (#19868) correct `maxTagTextLength` description --- components/select/index.en-US.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/components/select/index.en-US.md b/components/select/index.en-US.md index f8c4968ff8..93353b2202 100644 --- a/components/select/index.en-US.md +++ b/components/select/index.en-US.md @@ -39,7 +39,7 @@ Select component to select value from options. | getPopupContainer | Parent Node which the selector should be rendered to. Default to `body`. When position issues happen, try to modify it into scrollable content and position it relative. [Example](https://codesandbox.io/s/4j168r7jw0) | function(triggerNode) | () => document.body | | | labelInValue | whether to embed label in value, turn the format of value from `string` to `{key: string, label: ReactNode}` | boolean | false | | | maxTagCount | Max tag count to show | number | - | | -| maxTagTextLength | Max tag count to show | number | - | 3.18.0 | +| maxTagTextLength | Max tag text length to show | number | - | 3.18.0 | | maxTagPlaceholder | Placeholder for not showing tags | ReactNode/function(omittedValues) | - | | | mode | Set mode of Select | 'default' \| 'multiple' \| 'tags' | 'default' | | | notFoundContent | Specify content to show when no result matches.. | string | 'Not Found' | | From 102efd529a9e4b368bb30f6d74bd893f73d0af90 Mon Sep 17 00:00:00 2001 From: Josiah Rooney Date: Thu, 21 Nov 2019 17:22:20 -0800 Subject: [PATCH 29/42] docs: Improved grammar in AutoComplete docs (#19875) Improved grammar in documentation for the AutoComplete component. --- components/auto-complete/index.en-US.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/components/auto-complete/index.en-US.md b/components/auto-complete/index.en-US.md index eb5f85567a..b926c45bd3 100644 --- a/components/auto-complete/index.en-US.md +++ b/components/auto-complete/index.en-US.md @@ -52,8 +52,8 @@ const dataSource = ['12345', '23456', '34567']; ## FAQ -### Why text composition system not works well with onSearch in controlled mode? +### Why doesn't the text composition system work well with onSearch in controlled mode? -Please use `onChange` to manage control state. `onSearch` is used for searching input which is not same as `onChange`. Besides, click on the option also not trigger the `onSearch` event. +Please use `onChange` to manage control state. `onSearch` is used for searching input which is not same as `onChange`. Besides, clicking on the option will not trigger the `onSearch` event. Related issue: [#18230](https://github.com/ant-design/ant-design/issues/18230) [#17916](https://github.com/ant-design/ant-design/issues/17916) From 040fe5696a71eb1e6875accd063a05eda1c88cf8 Mon Sep 17 00:00:00 2001 From: Amumu Date: Fri, 22 Nov 2019 15:47:02 +0800 Subject: [PATCH 30/42] fix time-picker disabled item focus style (#19812) --- components/time-picker/style/index.less | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/components/time-picker/style/index.less b/components/time-picker/style/index.less index 0c6149d32d..ea450721ec 100644 --- a/components/time-picker/style/index.less +++ b/components/time-picker/style/index.less @@ -124,6 +124,10 @@ background: transparent; cursor: not-allowed; } + &:focus { + color: @btn-disable-color; + font-weight: inherit; + } } } From fecdfd9c770119251d6d3bbbece758b95bf3a31b Mon Sep 17 00:00:00 2001 From: "depfu[bot]" <23717796+depfu[bot]@users.noreply.github.com> Date: Sat, 23 Nov 2019 19:37:45 +0800 Subject: [PATCH 31/42] Update rc-tabs to version 9.7.0 (#19726) --- package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.json b/package.json index ec719aa0b5..f5ab420bb6 100644 --- a/package.json +++ b/package.json @@ -128,7 +128,7 @@ "rc-steps": "~3.5.0", "rc-switch": "~1.9.0", "rc-table": "~6.9.4", - "rc-tabs": "~9.6.4", + "rc-tabs": "~9.7.0", "rc-time-picker": "~3.7.1", "rc-tooltip": "~3.7.3", "rc-tree": "~2.1.0", From be30d4bfa4e398b1ad78361b4f3257037b663656 Mon Sep 17 00:00:00 2001 From: afc163 Date: Sat, 23 Nov 2019 19:33:05 +0800 Subject: [PATCH 32/42] =?UTF-8?q?docs:=20=F0=9F=94=A5=20announce=20brand?= =?UTF-8?q?=20new=20antv.vision?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- docs/react/recommendation.en-US.md | 16 ++++++++-------- docs/react/recommendation.zh-CN.md | 16 ++++++++-------- site/theme/en-US.js | 1 + site/theme/template/Home/Banner.jsx | 27 ++++++++++++++++++--------- site/theme/zh-CN.js | 1 + 5 files changed, 36 insertions(+), 25 deletions(-) diff --git a/docs/react/recommendation.en-US.md b/docs/react/recommendation.en-US.md index baf06e8550..59e039756c 100644 --- a/docs/react/recommendation.en-US.md +++ b/docs/react/recommendation.en-US.md @@ -7,7 +7,7 @@ title: Third-Party Libraries | Category | Recommended Components | | --- | --- | -| Visualization and charts | [🔥 AntV 数据可视化解决方案](https://antv.alipay.com) [BizCharts](https://github.com/alibaba/BizCharts) [recharts](https://github.com/recharts/recharts/) [viser](https://viserjs.github.io/) | +| Visualization and charts | [🔥 AntV 数据可视化解决方案](https://antv.vision) [BizCharts](https://github.com/alibaba/BizCharts) [recharts](https://github.com/recharts/recharts/) [viser](https://viserjs.github.io/) | | Router | [react-router](https://github.com/ReactTraining/react-router) | | Layout | [@rebass/grid](https://github.com/rebassjs/grid) [react-blocks](http://whoisandy.github.io/react-blocks/) [react-flexbox-grid](https://github.com/roylee0704/react-flexbox-grid) | | Drag and drop | [react-beautiful-dnd](https://github.com/atlassian/react-beautiful-dnd/) [react-dnd](https://github.com/gaearon/react-dnd) [react-sortable-hoc](https://github.com/clauderic/react-sortable-hoc) | @@ -40,14 +40,14 @@ title: Third-Party Libraries There are some products to recommend for developer/designer/product manager. -| Category | Recommended Products | -| --- | --- | -| Documentation | [🐦 Yuque](https://www.yuque.com/?chInfo=ch_antd) | -| Icon | [Iconfont](https://www.iconfont.cn/) | -| Sketch plugin | [Kitchen](https://kitchen.alipay.com) | +| Category | Recommended Products | +| ----------------- | --------------------------------------------------------------------- | +| Documentation | [🐦 Yuque](https://www.yuque.com/?chInfo=ch_antd) | +| Icon | [Iconfont](https://www.iconfont.cn/) | +| Sketch plugin | [Kitchen](https://kitchen.alipay.com) | | Online Playground | [codesandbox](https://codesandbox.io/) [codepen](https://codepen.io/) | -| Image Compressor | [tinypng](https://tinypng.com/) | -| Charts Dictionary | [G2](https://antv.alipay.com/zh-cn/g2/3.x/demo/index.html) [图之典](http://tuzhidian.com/) | +| Image Compressor | [tinypng](https://tinypng.com/) | +| Charts Dictionary | [图之典](http://tuzhidian.com/) |