From eea2272f34e77a75524a02659a0a712cf8b6bf12 Mon Sep 17 00:00:00 2001 From: zombiej Date: Mon, 20 May 2019 11:43:17 +0800 Subject: [PATCH 1/2] fix form typescript doc From a4054bffe796ff75e1ab15cb501bc2eb450695c9 Mon Sep 17 00:00:00 2001 From: zombiej Date: Mon, 20 May 2019 11:46:00 +0800 Subject: [PATCH 2/2] prettier md files --- .github/PULL_REQUEST_TEMPLATE.md | 8 ++++---- .github/PULL_REQUEST_TEMPLATE/pr_cn.md | 8 ++++---- components/form/index.en-US.md | 11 ++++------- components/form/index.zh-CN.md | 11 ++++------- 4 files changed, 16 insertions(+), 22 deletions(-) diff --git a/.github/PULL_REQUEST_TEMPLATE.md b/.github/PULL_REQUEST_TEMPLATE.md index 1f2584044244..2e0551a1e66e 100644 --- a/.github/PULL_REQUEST_TEMPLATE.md +++ b/.github/PULL_REQUEST_TEMPLATE.md @@ -43,10 +43,10 @@ Please makes sure that these form are filled before submitting your pull request Describe changes from userside, and list all potential break changes or other risks. ---> -| Language | Changelog | -|---|--- -| 🇺🇸 English | | -| 🇨🇳 Chinese | | +| Language | Changelog | +| ---------- | --------- | +| 🇺🇸 English | | +| 🇨🇳 Chinese | | ### ☑️ Self Check before Merge diff --git a/.github/PULL_REQUEST_TEMPLATE/pr_cn.md b/.github/PULL_REQUEST_TEMPLATE/pr_cn.md index 20df3bc34381..697e91882fe9 100644 --- a/.github/PULL_REQUEST_TEMPLATE/pr_cn.md +++ b/.github/PULL_REQUEST_TEMPLATE/pr_cn.md @@ -43,10 +43,10 @@ > 从用户角度描述具体变化,以及可能的 breaking change 和其他风险? --> -| 语言 | 更新描述 | -|---|--- -| 🇺🇸 英文 | | -| 🇨🇳 中文 | | +| 语言 | 更新描述 | +| ------- | -------- | +| 🇺🇸 英文 | | +| 🇨🇳 中文 | | - 中文(可选): diff --git a/components/form/index.en-US.md b/components/form/index.en-US.md index 6fa0161efcc6..2ab893647a0d 100644 --- a/components/form/index.en-US.md +++ b/components/form/index.en-US.md @@ -225,7 +225,7 @@ See more advanced usage at [async-validator](https://github.com/yiminghe/async-v ## Using in TypeScript -```jsx +```tsx import { Form } from 'antd'; import { FormComponentProps } from 'antd/lib/form'; @@ -238,12 +238,9 @@ class UserForm extends React.Component { // ... } -const App = - Form.create < - UserFormProps > - { - // ... - }(UserForm); +const App = Form.create({ + // ... +})(UserForm); ```