提交 e3851dc5 编写于 作者: V vben

feat(moda;): can switch full screen by double-clicking on the head close #277

上级 4f8e1c1b
...@@ -3,6 +3,7 @@ ...@@ -3,6 +3,7 @@
### ✨ Features ### ✨ Features
- 新增 `settingButtonPosition`配置项,用于配置`设置`按钮位置 - 新增 `settingButtonPosition`配置项,用于配置`设置`按钮位置
- `modal`可以通过双击头部切换全屏
### ⚡ Performance Improvements ### ⚡ Performance Improvements
......
...@@ -10,7 +10,11 @@ ...@@ -10,7 +10,11 @@
</template> </template>
<template #title v-if="!$slots.title"> <template #title v-if="!$slots.title">
<ModalHeader :helpMessage="getProps.helpMessage" :title="getMergeProps.title" /> <ModalHeader
:helpMessage="getProps.helpMessage"
:title="getMergeProps.title"
@dblclick="handleTitleDbClick"
/>
</template> </template>
<template #footer v-if="!$slots.footer"> <template #footer v-if="!$slots.footer">
...@@ -193,6 +197,12 @@ ...@@ -193,6 +197,12 @@
extHeightRef.value = height; extHeightRef.value = height;
} }
function handleTitleDbClick(e: ChangeEvent) {
if (!props.canFullscreen) return;
e.stopPropagation();
handleFullScreen(e);
}
return { return {
handleCancel, handleCancel,
getBindValue, getBindValue,
...@@ -206,6 +216,7 @@ ...@@ -206,6 +216,7 @@
modalWrapperRef, modalWrapperRef,
handleExtHeight, handleExtHeight,
handleHeightChange, handleHeightChange,
handleTitleDbClick,
}; };
}, },
}); });
......
...@@ -44,6 +44,9 @@ body { ...@@ -44,6 +44,9 @@ body {
} }
a:focus, a:focus,
a:active { a:active,
outline: none; button,
div,
span {
outline: none !important;
} }
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册