From a653ef9fa8f371e3ecceee74a1376f54a20b42c3 Mon Sep 17 00:00:00 2001 From: spark Date: Mon, 13 Jan 2025 10:52:34 +0800 Subject: [PATCH] =?UTF-8?q?feat(frontend):=20=E4=BC=98=E5=8C=96=20App.vue?= =?UTF-8?q?=20=E4=B8=AD=E7=9A=84=E5=85=A8=E5=B1=8F=E5=92=8C=E9=9A=90?= =?UTF-8?q?=E8=97=8F=E5=8A=9F=E8=83=BD-=20=E4=B8=BA=E5=85=A8=E5=B1=8F?= =?UTF-8?q?=E5=92=8C=E9=9A=90=E8=97=8F=E6=8C=89=E9=92=AE=E6=B7=BB=E5=8A=A0?= =?UTF-8?q?=E4=BA=86=20title=20=E5=B1=9E=E6=80=A7=EF=BC=8C=E6=8F=90?= =?UTF-8?q?=E5=8D=87=E7=94=A8=E6=88=B7=E4=BD=93=E9=AA=8C=20-=20=E4=BC=98?= =?UTF-8?q?=E5=8C=96=E4=BA=86=E5=85=A8=E5=B1=8F=E5=88=87=E6=8D=A2=E9=80=BB?= =?UTF-8?q?=E8=BE=91=EF=BC=8C=E7=8E=B0=E5=9C=A8=E6=94=AF=E6=8C=81=E9=94=AE?= =?UTF-8?q?=E7=9B=98=E5=BF=AB=E6=8D=B7=E9=94=AE=20Ctrl+F=20=E5=92=8C=20Esc?= =?UTF-8?q?=20-=20=E8=B0=83=E6=95=B4=E4=BA=86=E5=85=A8=E5=B1=8F=E6=8C=89?= =?UTF-8?q?=E9=92=AE=E7=9A=84=E6=98=BE=E7=A4=BA=E6=96=87=E6=9C=AC=EF=BC=8C?= =?UTF-8?q?=E6=A0=B9=E6=8D=AE=E5=BD=93=E5=89=8D=E7=8A=B6=E6=80=81=E5=8A=A8?= =?UTF-8?q?=E6=80=81=E5=8F=98=E5=8C=96=20-=20=E7=A7=BB=E9=99=A4=E4=BA=86?= =?UTF-8?q?=E4=B8=8D=E5=BF=85=E8=A6=81=E7=9A=84=20console.log=20=E8=AF=AD?= =?UTF-8?q?=E5=8F=A5=EF=BC=8C=E7=AE=80=E5=8C=96=E4=BA=86=E4=BB=A3=E7=A0=81?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- frontend/package.json.md5 | 2 +- frontend/src/App.vue | 20 +++++++++++--------- 2 files changed, 12 insertions(+), 10 deletions(-) diff --git a/frontend/package.json.md5 b/frontend/package.json.md5 index 3e578c9..d2ab4a7 100644 --- a/frontend/package.json.md5 +++ b/frontend/package.json.md5 @@ -1 +1 @@ -fab5f9aa38ff92389d6726864c83c7cd \ No newline at end of file +00b8e620dca5bab58d37996f0f350d0a \ No newline at end of file diff --git a/frontend/src/App.vue b/frontend/src/App.vue index 3471e8b..62cf939 100644 --- a/frontend/src/App.vue +++ b/frontend/src/App.vue @@ -9,7 +9,7 @@ import { } from '../wailsjs/runtime' import {h, ref} from "vue"; import { RouterLink } from 'vue-router' -import {darkTheme, NIcon} from 'naive-ui' +import {darkTheme, NIcon, NText} from 'naive-ui' import { SettingsOutline, ReorderTwoOutline, @@ -31,10 +31,10 @@ const menuOptions = ref([ name: 'stock', params: { id: 'zh-CN' - } + }, } }, - { default: () => '我的自选' } + { default: () => '我的自选',} ), key: 'stock', icon: renderIcon(BarChartOutline) @@ -59,8 +59,9 @@ const menuOptions = ref([ { label: ()=> h("a", { href: '#', - onClick: toggleFullscreen - }, { default: () => '全屏' }), + onClick: toggleFullscreen, + title: '全屏 Ctrl+F 退出全屏 Esc', + }, { default: () => isFullscreen.value?'取消全屏':'全屏' }), key: 'full', icon: renderIcon(ExpandOutline), }, @@ -68,6 +69,7 @@ const menuOptions = ref([ label: ()=> h("a", { href: '#', onClick: WindowHide, + title: '隐藏到托盘区 Ctrl+H', }, { default: () => '隐藏到托盘区' }), key: 'hide', icon: renderIcon(ReorderTwoOutline), @@ -94,15 +96,15 @@ function renderIcon(icon) { return () => h(NIcon, null, { default: () => h(icon) }) } function toggleFullscreen(e) { - console.log(e) - isFullscreen.value=!isFullscreen.value + //console.log(e) if (isFullscreen.value) { WindowUnfullscreen() - e.target.innerHTML = '全屏' + //e.target.innerHTML = '全屏' } else { WindowFullscreen() - e.target.innerHTML = '取消全屏' + // e.target.innerHTML = '取消全屏' } + isFullscreen.value=!isFullscreen.value } const drag = ref(false) const lastPos= ref({x:0,y:0})