From fb04927ada6ef4a15e598499b9ff044c3dc5e7a3 Mon Sep 17 00:00:00 2001 From: afc163 Date: Mon, 20 Jul 2020 14:18:36 +0800 Subject: [PATCH] :memo: Add documentation for Form in Modal --- components/modal/index.en-US.md | 6 +++--- components/modal/index.zh-CN.md | 6 +++--- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/components/modal/index.en-US.md b/components/modal/index.en-US.md index 1a58a4c474..c53a1ed328 100644 --- a/components/modal/index.en-US.md +++ b/components/modal/index.en-US.md @@ -44,9 +44,9 @@ When requiring users to interact with the application, but without jumping to a #### Note -> - The state of Modal will be preserved at it's component lifecycle by default, if you wish to open it with a brand new state everytime, set `destroyOnClose` on it. -> -> - `Modal.method()` RTL mode only supports hooks. +- The state of Modal will be preserved at it's component lifecycle by default, if you wish to open it with a brand new state everytime, set `destroyOnClose` on it. +- There is a situation that using `` with Form, which won't clear fields value when closing Modal even you have set `destroyOnClose`. You need `
` in this case. +- `Modal.method()` RTL mode only supports hooks. ### Modal.method() diff --git a/components/modal/index.zh-CN.md b/components/modal/index.zh-CN.md index 11764946e2..537417591d 100644 --- a/components/modal/index.zh-CN.md +++ b/components/modal/index.zh-CN.md @@ -48,9 +48,9 @@ cover: https://gw.alipayobjects.com/zos/alicdn/3StSdUlSH/Modal.svg #### 注意 -> - `` 默认关闭后状态不会自动清空, 如果希望每次打开都是新内容,请设置 `destroyOnClose`。 -> -> - `Modal.method()` RTL 模式仅支持 hooks 用法。 +- `` 默认关闭后状态不会自动清空, 如果希望每次打开都是新内容,请设置 `destroyOnClose`。 +- `` 和 Form 一起配合使用时,设置 `destroyOnClose` 也不会在 Modal 关闭时销毁表单字段数据,需要设置 ``。 +- `Modal.method()` RTL 模式仅支持 hooks 用法。 ### Modal.method()