diff --git a/src/layout/components/sidebar/horizontal.vue b/src/layout/components/sidebar/horizontal.vue
index 18cc094973..0ec91ccec6 100644
--- a/src/layout/components/sidebar/horizontal.vue
+++ b/src/layout/components/sidebar/horizontal.vue
@@ -21,6 +21,7 @@ const {
logout,
backTopMenu,
onPanel,
+ getLogo,
username,
userAvatar,
avatarsStyle,
@@ -43,7 +44,7 @@ nextTick(() => {
class="horizontal-header"
>
@@ -19,7 +19,7 @@ const { title } = useNav();
class="sidebar-logo-link"
:to="getTopMenu()?.path ?? '/'"
>
-
+
diff --git a/src/layout/hooks/useNav.ts b/src/layout/hooks/useNav.ts
index 6263991196..6bd727c7ad 100644
--- a/src/layout/hooks/useNav.ts
+++ b/src/layout/hooks/useNav.ts
@@ -124,6 +124,11 @@ export function useNav() {
return remainingPaths.includes(path);
}
+ /** 获取`logo` */
+ function getLogo() {
+ return new URL("/logo.svg", import.meta.url).href;
+ }
+
return {
title,
device,
@@ -139,6 +144,7 @@ export function useNav() {
menuSelect,
handleResize,
resolvePath,
+ getLogo,
isCollapse,
pureApp,
username,
diff --git a/src/views/components/animatecss/index.vue b/src/views/components/animatecss/index.vue
index 63a43919c2..423a6cd37f 100644
--- a/src/views/components/animatecss/index.vue
+++ b/src/views/components/animatecss/index.vue
@@ -8,7 +8,9 @@ defineOptions({
const icon = ref("");
-watch(icon, () => console.log("icon", icon.value));
+watch(icon, () => {
+ console.log("icon", icon.value);
+});