Skip to content

Commit

Permalink
fix: 修复Tabs组件文档和Editor中mountOnEnter默认值改为true和renderer保持一致 (#9920)
Browse files Browse the repository at this point in the history
Co-authored-by: jinye <jinye@baidu.com>
  • Loading branch information
CheshireJCat and jinye committed Mar 29, 2024
1 parent d9472e6 commit 6a3998a
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
2 changes: 1 addition & 1 deletion docs/zh-CN/components/tabs.md
Original file line number Diff line number Diff line change
Expand Up @@ -857,7 +857,7 @@ order: 68
| tabs[x].tip | `string` | | `3.2.0及以上版本支持` Tab 提示,当开启 `showTip` 时生效,作为 Tab 在 hover 时的提示显示,可不配置,如不设置,`tabs[x].title` 作为提示显示 |
| tabs[x].closable | `boolean` | false | 是否支持删除,优先级高于组件的 `closable` |
| tabs[x].disabled | `boolean` | false | 是否禁用 |
| mountOnEnter | `boolean` | false | 只有在点中 tab 的时候才渲染 |
| mountOnEnter | `boolean` | true | 只有在点中 tab 的时候才渲染 |
| unmountOnExit | `boolean` | false | 切换 tab 的时候销毁 |
| addable | `boolean` | false | 是否支持新增 |
| addBtnText | `string` | 增加 | 新增按钮文案 |
Expand Down
3 changes: 2 additions & 1 deletion packages/amis-editor/src/plugin/Tabs.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,8 @@ export class TabsPlugin extends BasePlugin {
title: '选项卡2',
body: []
}
]
],
mountOnEnter: true
};
previewSchema = {
...this.scaffold
Expand Down

0 comments on commit 6a3998a

Please sign in to comment.