File tree Expand file tree Collapse file tree 5 files changed +5
-9
lines changed
docs/src/components/common-ui Expand file tree Collapse file tree 5 files changed +5
-9
lines changed Original file line number Diff line number Diff line change @@ -78,7 +78,7 @@ const [Drawer, drawerApi] = useVbenDrawer({
7878| --- | --- | --- | --- |
7979| appendToMain | 是否挂载到内容区域(默认挂载到body) | ` boolean ` | ` false ` |
8080| connectedComponent | 连接另一个Modal组件 | ` Component ` | - |
81- | destroyOnClose | 关闭时销毁` connectedComponent ` | ` boolean ` | ` false ` |
81+ | destroyOnClose | 关闭时销毁 | ` boolean ` | ` false ` |
8282| title | 标题 | ` string\|slot ` | - |
8383| titleTooltip | 标题提示信息 | ` string\|slot ` | - |
8484| description | 描述信息 | ` string\|slot ` | - |
Original file line number Diff line number Diff line change @@ -35,7 +35,7 @@ interface Props extends DrawerProps {
3535const props = withDefaults (defineProps <Props >(), {
3636 appendToMain: false ,
3737 closeIconPlacement: ' right' ,
38- destroyOnClose: true ,
38+ destroyOnClose: false ,
3939 drawerApi: undefined ,
4040 submitting: false ,
4141 zIndex: 1000 ,
Original file line number Diff line number Diff line change @@ -21,9 +21,7 @@ import VbenDrawer from './drawer.vue';
2121
2222const USER_DRAWER_INJECT_KEY = Symbol ( 'VBEN_DRAWER_INJECT' ) ;
2323
24- const DEFAULT_DRAWER_PROPS : Partial < DrawerProps > = {
25- destroyOnClose : true ,
26- } ;
24+ const DEFAULT_DRAWER_PROPS : Partial < DrawerProps > = { } ;
2725
2826export function setDefaultDrawerProps ( props : Partial < DrawerProps > ) {
2927 Object . assign ( DEFAULT_DRAWER_PROPS , props ) ;
Original file line number Diff line number Diff line change @@ -34,7 +34,7 @@ interface Props extends ModalProps {
3434
3535const props = withDefaults (defineProps <Props >(), {
3636 appendToMain: false ,
37- destroyOnClose: true ,
37+ destroyOnClose: false ,
3838 modalApi: undefined ,
3939});
4040
Original file line number Diff line number Diff line change @@ -17,9 +17,7 @@ import VbenModal from './modal.vue';
1717
1818const USER_MODAL_INJECT_KEY = Symbol ( 'VBEN_MODAL_INJECT' ) ;
1919
20- const DEFAULT_MODAL_PROPS : Partial < ModalProps > = {
21- destroyOnClose : true ,
22- } ;
20+ const DEFAULT_MODAL_PROPS : Partial < ModalProps > = { } ;
2321
2422export function setDefaultModalProps ( props : Partial < ModalProps > ) {
2523 Object . assign ( DEFAULT_MODAL_PROPS , props ) ;
You can’t perform that action at this time.
0 commit comments