Merge branch 'dev' into master-fetch-dev

This commit is contained in:
奔跑的面条
2023-04-02 17:54:57 +08:00
38 changed files with 4620 additions and 1444 deletions
@@ -25,6 +25,11 @@ export const syncData = () => {
})
}
// 同步数据到预览页
export const syncDataToPreview = () => {
dispatchEvent(new CustomEvent(SavePageEnum.CHART_TO_PREVIEW, { detail: chartEditStore.getStorageInfo }))
}
// 侦听器更新
const useSyncUpdateHandle = () => {
// 定义侦听器变量
@@ -49,8 +54,8 @@ const useSyncUpdateHandle = () => {
// document.hasFocus() && syncData()
// }, editToJsonInterval)
// 失焦同步数据(暂不开启)
// addEventListener('blur', syncData)
// 失焦同步数据
addEventListener('blur', syncDataToPreview)
// 监听编辑器保存事件 刷新工作台图表
addEventListener(SavePageEnum.JSON, updateFn)
@@ -62,7 +67,7 @@ const useSyncUpdateHandle = () => {
// 关闭侦听
const unUse = () => {
// clearInterval(timer)
// removeEventListener('blur', syncData)
removeEventListener('blur', syncDataToPreview)
removeEventListener(SavePageEnum.JSON, updateFn)
}
@@ -322,6 +322,15 @@ $asideBottom: 70px;
border-radius: 25px;
}
}
&::after {
content: '';
position: absolute;
left: 0;
width: 100%;
height: 10px;
bottom: -10px;
cursor: pointer;
}
}
/* 最小化 */
&.isMini {
@@ -348,6 +357,7 @@ $asideBottom: 70px;
50% {
opacity: 0;
bottom: calc(#{$dockMiniBottom} - 10px);
pointer-events: none;
}
100% {
opacity: 1;
@@ -362,15 +372,6 @@ $asideBottom: 70px;
display: none;
}
}
&::after {
content: '';
position: absolute;
left: 0;
width: 100%;
height: 20px;
bottom: -20px;
cursor: pointer;
}
}
}
</style>