feat: 调整侧栏全部数据样式 增加不隐藏插件执行复制的功能

This commit is contained in:
ZiuChen 2022-09-04 22:13:50 +08:00
parent 3807c73149
commit 52a3005d7e
4 changed files with 15 additions and 9 deletions

View File

@ -161,7 +161,7 @@ const watchClipboard = async (db, fn) => {
}, 250)
}
const copy = (item) => {
const copy = (item, isHideMainWindow = true) => {
switch (item.type) {
case 'text':
utools.copyText(item.data)
@ -174,7 +174,7 @@ const copy = (item) => {
utools.copyFile(paths)
break
}
utools.hideMainWindow()
isHideMainWindow && utools.hideMainWindow()
}
const paste = () => {

View File

@ -48,10 +48,11 @@ onMounted(() => {
@import '../style';
.fade-enter-active,
.fade-leave-active {
transition: opacity 0.15s ease;
transition: all 0.15s ease;
}
.fade-enter-from,
.fade-leave-to {
width: 0px;
opacity: 0;
}
</style>

View File

@ -112,7 +112,7 @@ const operation = [
const handleOperateClick = ({ id, item }) => {
switch (id) {
case 'copy':
window.copy(item)
window.copy(item, false)
break
case 'view':
emit('onDataChange', item)

View File

@ -2,14 +2,19 @@
z-index: 9999999999;
position: fixed;
top: 0;
height: 100%;
height: -webkit-fill-available;
width: 70%;
color: @text-color;
background: @bg-color;
padding: 0px 20px 0px 20px;
margin: 0px 0px;
padding: 10px 20px;
overflow-y: scroll;
word-break: break-all;
white-space: pre-wrap;
div {
background-color: @text-bg-color;
padding: 10px;
}
&::-webkit-scrollbar {
width: 10px;
height: 10px;
@ -25,10 +30,10 @@
&::-webkit-scrollbar-thumb {
background: @text-color-lighter;
border-radius: 5px;
}
&::-webkit-scrollbar-thumb:hover {
&:hover {
background: @text-color;
}
}
}
.clip-overlay {
z-index: 999999999;