-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
11 changed files
with
136 additions
and
28 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
import crypto from "crypto" | ||
|
||
export default function getDigest(data: Buffer, digestType: string) { | ||
const hash = crypto.createHash(digestType).update(data).digest("hex"); | ||
return hash | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,6 @@ | ||
export default { | ||
"1.0.2": ["新增更新详情弹框", "顶栏增加版本展示", "支持选择主题色"], | ||
"1.1.0": ["侧边栏优化", "右键菜单弹出位置优化", "文件管理器滚动条修复", "文件管理器增加底部状态条", | ||
"文件可以支持选择了", "支持回车键确定密码", "任务管理器支持状态显示", "修复bug", "列表查找性能优化"] | ||
"文件可以支持选择了", "支持回车键确定密码", "任务管理器支持状态显示", "修复bug", "列表查找性能优化"], | ||
"1.2.0": ["文件哈希现已开放", "新增功能:屏幕捕获防护", "更新内容UI展示优化"] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,40 @@ | ||
import dialogBottomAction from '@/types/dialogBottomAction' | ||
import { defineStore } from 'pinia' | ||
import sharedUtils from "@/utils/sharedUtils"; | ||
|
||
interface Dialog { | ||
isDialogOpen: boolean, | ||
footer?: string, | ||
title: string, | ||
bottomActions?: Array<dialogBottomAction>, | ||
isPersistent?: boolean, | ||
width?: string, | ||
height?: string, | ||
destroyAfterClose: boolean, | ||
HTMLContent?: string, | ||
guid: string | ||
} | ||
|
||
export const useDialogStore = defineStore("dialog", { | ||
state() { | ||
return { | ||
dialogs: new Set() as Set<Dialog> | ||
} | ||
}, | ||
actions: { | ||
addDialog(dialog: Omit<Dialog, "guid">) { | ||
const guid = sharedUtils.getHash(16) | ||
this.dialogs.add({ ...dialog, guid }) | ||
}, | ||
remove(guid: string) { | ||
let tmp = null | ||
this.dialogs.forEach(item => { | ||
if (item.guid === guid) { | ||
tmp = item | ||
} | ||
}) | ||
this.dialogs.delete(tmp) | ||
} | ||
} | ||
} | ||
) |