diff --git a/frontend/index.html b/frontend/index.html index f28603b..a092b09 100644 --- a/frontend/index.html +++ b/frontend/index.html @@ -41,7 +41,7 @@

松开鼠标以读取文件

上次修改时间:未选择文件

- 本应用的所有操作均在您的设备上运行,不会收集任何信息,请放心使用! + 所有计算操作均在您的设备上运行,不会收集任何信息,请放心使用!

计算完成后将校验值写入剪贴板(仅在生成模式下生效)

@@ -112,15 +112,18 @@

保存 - -

+ + +

Hash Checker

+

本应用在 GitHub 上开源
Super12138 开发

- +

遵循 GPL-3.0 协议

+

开源库
Vite
diff --git a/frontend/src/index.css b/frontend/src/index.css index 401e3d7..512d768 100644 --- a/frontend/src/index.css +++ b/frontend/src/index.css @@ -150,6 +150,10 @@ code { color: #00C853 !important; } +.no-margin { + margin: 0; +} + /* 滚动条 */ /* body::-webkit-scrollbar { width: 6px; @@ -192,7 +196,8 @@ h1 { font-weight: var(--mdui-typescale-headline-medium-weight); } -h2 { +h2, +.headline-small { line-height: var(--mdui-typescale-headline-small-line-height); font-size: var(--mdui-typescale-headline-small-size); letter-spacing: var(--mdui-typescale-headline-small-tracking); diff --git a/frontend/src/index.ts b/frontend/src/index.ts index cbb5df1..f0199ec 100644 --- a/frontend/src/index.ts +++ b/frontend/src/index.ts @@ -99,7 +99,7 @@ dropZone.addEventListener('drop', (e: DragEvent) => { // 初始化 window.addEventListener("load", () => { - initPWA(); + if (VARIANT !== "desktop") initPWA(); const isFirstUse: boolean = string2Boolean(getStorageItem("firstUse", false)); const cacheSizeValue: string = getStorageItem("cacheSize", 2048); diff --git a/frontend/src/pwa/sw.ts b/frontend/src/pwa/sw.ts index eac060d..9e7ee74 100644 --- a/frontend/src/pwa/sw.ts +++ b/frontend/src/pwa/sw.ts @@ -24,5 +24,4 @@ registerRoute(new NavigationRoute( )); self.skipWaiting(); -clientsClaim(); - +clientsClaim(); \ No newline at end of file diff --git a/frontend/src/utils/clipboard.ts b/frontend/src/utils/clipboard.ts index 3dc58de..734a516 100644 --- a/frontend/src/utils/clipboard.ts +++ b/frontend/src/utils/clipboard.ts @@ -10,7 +10,7 @@ export async function writeClipboard(text: string) { } catch (e) { dialog({ headline: '错误', - description: '无法写入剪贴板', + description: `无法写入剪贴板(${e})`, actions: [ { text: '确定' diff --git a/frontend/src/utils/text.ts b/frontend/src/utils/text.ts index 5a5aff6..d159368 100644 --- a/frontend/src/utils/text.ts +++ b/frontend/src/utils/text.ts @@ -7,7 +7,7 @@ export function compareHash(userHash: string, genHash: string): HTMLSpanElement differences.forEach((part: Change) => { const span: HTMLSpanElement = document.createElement('span'); if (part.added) { - span.style.color = 'color-red'; + span.classList.add('color-red') } if (part.removed) { span.style.textDecoration = 'line-through';