Skip to content

Commit

Permalink
feat(antd): support disable default behavior of built-in operations i…
Browse files Browse the repository at this point in the history
…n ArrayBase (#3998)
  • Loading branch information
whinc authored Oct 23, 2023
1 parent 1c31ff8 commit c90b1df
Show file tree
Hide file tree
Showing 9 changed files with 715 additions and 21 deletions.
10 changes: 10 additions & 0 deletions packages/antd/docs/components/ArrayCards.md
Original file line number Diff line number Diff line change
Expand Up @@ -467,6 +467,8 @@ Other references https://ant.design/components/button-cn/

Note: The title attribute can receive the title mapping in the Field model, that is, uploading the title in the Field is also effective

Note: You can disable default behavior with `onClick={e => e.preventDefault()}` in props.

### ArrayCards.Copy

> Copy button
Expand All @@ -482,6 +484,8 @@ Other references https://ant.design/components/button-cn/

Note: The title attribute can receive the title mapping in the Field model, that is, uploading the title in the Field is also effective

Note: You can disable default behavior with `onClick={e => e.preventDefault()}` in props.

### ArrayCards.Remove

> Delete button
Expand All @@ -494,6 +498,8 @@ Other references https://ant.design/components/icon-cn/

Note: The title attribute can receive the title mapping in the Field model, that is, uploading the title in the Field is also effective

Note: You can disable default behavior with `onClick={e => e.preventDefault()}` in props.

### ArrayCards.MoveDown

> Move down button
Expand All @@ -506,6 +512,8 @@ Other references https://ant.design/components/icon-cn/

Note: The title attribute can receive the title mapping in the Field model, that is, uploading the title in the Field is also effective

Note: You can disable default behavior with `onClick={e => e.preventDefault()}` in props.

### ArrayCards.MoveUp

> Move up button
Expand All @@ -518,6 +526,8 @@ Other references https://ant.design/components/icon-cn/

Note: The title attribute can receive the title mapping in the Field model, that is, uploading the title in the Field is also effective

Note: You can disable default behavior with `onClick={e => e.preventDefault()}` in props.

### ArrayCards.Index

> Index Renderer
Expand Down
10 changes: 10 additions & 0 deletions packages/antd/docs/components/ArrayCards.zh-CN.md
Original file line number Diff line number Diff line change
Expand Up @@ -467,6 +467,8 @@ export default () => {

注意:title 属性可以接收 Field 模型中的 title 映射,也就是在 Field 上传 title 也是生效的

注意:使用`onClick={e => e.preventDefault()}`可禁用默认行为。

### ArrayCards.Copy

> 复制按钮
Expand All @@ -482,6 +484,8 @@ export default () => {

注意:title 属性可以接收 Field 模型中的 title 映射,也就是在 Field 上传 title 也是生效的

注意:使用`onClick={e => e.preventDefault()}`可禁用默认行为。

### ArrayCards.Remove

> 删除按钮
Expand All @@ -494,6 +498,8 @@ export default () => {

注意:title 属性可以接收 Field 模型中的 title 映射,也就是在 Field 上传 title 也是生效的

注意:使用`onClick={e => e.preventDefault()}`可禁用默认行为。

### ArrayCards.MoveDown

> 下移按钮
Expand All @@ -506,6 +512,8 @@ export default () => {

注意:title 属性可以接收 Field 模型中的 title 映射,也就是在 Field 上传 title 也是生效的

注意:使用`onClick={e => e.preventDefault()}`可禁用默认行为。

### ArrayCards.MoveUp

> 上移按钮
Expand All @@ -518,6 +526,8 @@ export default () => {

注意:title 属性可以接收 Field 模型中的 title 映射,也就是在 Field 上传 title 也是生效的

注意:使用`onClick={e => e.preventDefault()}`可禁用默认行为。

### ArrayCards.Index

> 索引渲染器
Expand Down
8 changes: 8 additions & 0 deletions packages/antd/docs/components/ArrayCollapse.md
Original file line number Diff line number Diff line change
Expand Up @@ -580,6 +580,8 @@ Other references https://ant.design/components/button-cn/

Note: The title attribute can receive the title mapping in the Field model, that is, uploading the title in the Field is also effective

Note: You can disable default behavior with `onClick={e => e.preventDefault()}` in props.

### ArrayCollapse.Remove

> Delete button
Expand All @@ -592,6 +594,8 @@ Other references https://ant.design/components/icon-cn/

Note: The title attribute can receive the title mapping in the Field model, that is, uploading the title in the Field is also effective

Note: You can disable default behavior with `onClick={e => e.preventDefault()}` in props.

### ArrayCollapse.MoveDown

> Move down button
Expand All @@ -604,6 +608,8 @@ Other references https://ant.design/components/icon-cn/

Note: The title attribute can receive the title mapping in the Field model, that is, uploading the title in the Field is also effective

Note: You can disable default behavior with `onClick={e => e.preventDefault()}` in props.

### ArrayCollapse.MoveUp

> Move up button
Expand All @@ -616,6 +622,8 @@ Other references https://ant.design/components/icon-cn/

Note: The title attribute can receive the title mapping in the Field model, that is, uploading the title in the Field is also effective

Note: You can disable default behavior with `onClick={e => e.preventDefault()}` in props.

### ArrayCollapse.Index

> Index Renderer
Expand Down
8 changes: 8 additions & 0 deletions packages/antd/docs/components/ArrayCollapse.zh-CN.md
Original file line number Diff line number Diff line change
Expand Up @@ -585,6 +585,8 @@ export default () => {

注意:title 属性可以接收 Field 模型中的 title 映射,也就是在 Field 上传 title 也是生效的

注意:使用`onClick={e => e.preventDefault()}`可禁用默认行为。

### ArrayCollapse.Remove

> 删除按钮
Expand All @@ -597,6 +599,8 @@ export default () => {

注意:title 属性可以接收 Field 模型中的 title 映射,也就是在 Field 上传 title 也是生效的

注意:使用`onClick={e => e.preventDefault()}`可禁用默认行为。

### ArrayCollapse.MoveDown

> 下移按钮
Expand All @@ -609,6 +613,8 @@ export default () => {

注意:title 属性可以接收 Field 模型中的 title 映射,也就是在 Field 上传 title 也是生效的

注意:使用`onClick={e => e.preventDefault()}`可禁用默认行为。

### ArrayCollapse.MoveUp

> 上移按钮
Expand All @@ -621,6 +627,8 @@ export default () => {

注意:title 属性可以接收 Field 模型中的 title 映射,也就是在 Field 上传 title 也是生效的

注意:使用`onClick={e => e.preventDefault()}`可禁用默认行为。

### ArrayCollapse.Index

> 索引渲染器
Expand Down
10 changes: 10 additions & 0 deletions packages/antd/docs/components/ArrayItems.md
Original file line number Diff line number Diff line change
Expand Up @@ -748,6 +748,8 @@ Other references https://ant.design/components/button-cn/

Note: The title attribute can receive the title mapping in the Field model, that is, uploading the title in the Field is also effective

Note: You can disable default behavior with `onClick={e => e.preventDefault()}` in props.

### ArrayItems.Copy

> Copy button
Expand All @@ -763,6 +765,8 @@ Other references https://ant.design/components/button-cn/

Note: The title attribute can receive the title mapping in the Field model, that is, uploading the title in the Field is also effective

Note: You can disable default behavior with `onClick={e => e.preventDefault()}` in props.

### ArrayItems.Remove

> Delete button
Expand All @@ -775,6 +779,8 @@ Other references https://ant.design/components/icon-cn/

Note: The title attribute can receive the title mapping in the Field model, that is, uploading the title in the Field is also effective

Note: You can disable default behavior with `onClick={e => e.preventDefault()}` in props.

### ArrayItems.MoveDown

> Move down button
Expand All @@ -787,6 +793,8 @@ Other references https://ant.design/components/icon-cn/

Note: The title attribute can receive the title mapping in the Field model, that is, uploading the title in the Field is also effective

Note: You can disable default behavior with `onClick={e => e.preventDefault()}` in props.

### ArrayItems.MoveUp

> Move up button
Expand All @@ -799,6 +807,8 @@ Other references https://ant.design/components/icon-cn/

Note: The title attribute can receive the title mapping in the Field model, that is, uploading the title in the Field is also effective

Note: You can disable default behavior with `onClick={e => e.preventDefault()}` in props.

### ArrayItems.Index

> Index Renderer
Expand Down
10 changes: 10 additions & 0 deletions packages/antd/docs/components/ArrayItems.zh-CN.md
Original file line number Diff line number Diff line change
Expand Up @@ -749,6 +749,8 @@ export default () => {

注意:title 属性可以接收 Field 模型中的 title 映射,也就是在 Field 上传 title 也是生效的

注意:使用`onClick={e => e.preventDefault()}`可禁用默认行为。

### ArrayItems.Copy

> 复制按钮
Expand All @@ -764,6 +766,8 @@ export default () => {

注意:title 属性可以接收 Field 模型中的 title 映射,也就是在 Field 上传 title 也是生效的

注意:使用`onClick={e => e.preventDefault()}`可禁用默认行为。

### ArrayItems.Remove

> 删除按钮
Expand All @@ -776,6 +780,8 @@ export default () => {

注意:title 属性可以接收 Field 模型中的 title 映射,也就是在 Field 上传 title 也是生效的

注意:使用`onClick={e => e.preventDefault()}`可禁用默认行为。

### ArrayItems.MoveDown

> 下移按钮
Expand All @@ -788,6 +794,8 @@ export default () => {

注意:title 属性可以接收 Field 模型中的 title 映射,也就是在 Field 上传 title 也是生效的

注意:使用`onClick={e => e.preventDefault()}`可禁用默认行为。

### ArrayItems.MoveUp

> 上移按钮
Expand All @@ -800,6 +808,8 @@ export default () => {

注意:title 属性可以接收 Field 模型中的 title 映射,也就是在 Field 上传 title 也是生效的

注意:使用`onClick={e => e.preventDefault()}`可禁用默认行为。

### ArrayItems.Index

> 索引渲染器
Expand Down
Loading

0 comments on commit c90b1df

Please sign in to comment.