From c469512bd4e83fe890f3d745c04788181b74c408 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E9=9D=92=E8=8F=9C=E7=99=BD=E7=8E=89=E6=B1=A4?= <79054161+Azir-11@users.noreply.github.com> Date: Mon, 22 Jul 2024 11:39:19 +0800 Subject: [PATCH 1/5] fix(projects): fix the issue of abnormal width of the sidebar in the top menu mix and reverse mode (#562) --- src/layouts/base-layout/index.vue | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/layouts/base-layout/index.vue b/src/layouts/base-layout/index.vue index 7d00da22..7debe5d1 100644 --- a/src/layouts/base-layout/index.vue +++ b/src/layouts/base-layout/index.vue @@ -85,8 +85,13 @@ function getSiderWidth() { } function getSiderCollapsedWidth() { + const { reverseHorizontalMix } = themeStore.layout; const { collapsedWidth, mixCollapsedWidth, mixChildMenuWidth } = themeStore.sider; + if (isHorizontalMix.value && reverseHorizontalMix) { + return isActiveFirstLevelMenuHasChildren.value ? collapsedWidth : 0; + } + let w = isVerticalMix.value || isHorizontalMix.value ? mixCollapsedWidth : collapsedWidth; if (isVerticalMix.value && appStore.mixSiderFixed && childLevelMenus.value.length) { From 537700293231ace5864d0291648bd2c58e27dff2 Mon Sep 17 00:00:00 2001 From: Azir <2075125282@qq.com> Date: Mon, 22 Jul 2024 14:39:04 +0800 Subject: [PATCH 2/5] style(other): modify the Chinese name of the grayscale mode --- src/locales/langs/zh-cn.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/locales/langs/zh-cn.ts b/src/locales/langs/zh-cn.ts index f7042dc9..a19033ae 100644 --- a/src/locales/langs/zh-cn.ts +++ b/src/locales/langs/zh-cn.ts @@ -64,7 +64,7 @@ const local: App.I18n.Schema = { dark: '暗黑模式', auto: '跟随系统' }, - grayscale: '灰度模式', + grayscale: '灰色模式', layoutMode: { title: '布局模式', vertical: '左侧菜单模式', From 4e55b0e9bdd3bbc22c1ea5792922c31140d6fd32 Mon Sep 17 00:00:00 2001 From: Soybean Date: Mon, 22 Jul 2024 18:34:45 +0800 Subject: [PATCH 3/5] fix(projects): fix HorizontalMixMenu inverted. fixed #563 --- .../modules/global-menu/modules/horizontal-mix-menu.vue | 3 --- .../global-menu/modules/reversed-horizontal-mix-menu.vue | 3 --- 2 files changed, 6 deletions(-) diff --git a/src/layouts/modules/global-menu/modules/horizontal-mix-menu.vue b/src/layouts/modules/global-menu/modules/horizontal-mix-menu.vue index 83391670..66baa6cf 100644 --- a/src/layouts/modules/global-menu/modules/horizontal-mix-menu.vue +++ b/src/layouts/modules/global-menu/modules/horizontal-mix-menu.vue @@ -18,8 +18,6 @@ const themeStore = useThemeStore(); const { allMenus, childLevelMenus, activeFirstLevelMenuKey, setActiveFirstLevelMenuKey } = useMixMenuContext(); const { routerPushByKeyWithMetaQuery } = useRouterPush(); -const inverted = computed(() => !themeStore.darkMode && themeStore.sider.inverted); - const selectedKey = computed(() => { const { hideInMenu, activeMenu } = route.meta; const name = route.name as string; @@ -53,7 +51,6 @@ function handleSelectMixMenu(menu: App.Global.Menu) { !themeStore.darkMode && themeStore.sider.inverted); - const selectedKey = computed(() => { const { hideInMenu, activeMenu } = route.meta; const name = route.name as string; @@ -86,7 +84,6 @@ watch( :collapsed-width="themeStore.sider.collapsedWidth" :collapsed-icon-size="22" :options="childLevelMenus" - :inverted="inverted" :indent="18" @update:value="routerPushByKeyWithMetaQuery" /> From 840273474fa0ac5ff032c3b7be6ea8e8bd01af14 Mon Sep 17 00:00:00 2001 From: Soybean Date: Mon, 22 Jul 2024 19:01:53 +0800 Subject: [PATCH 4/5] fix(projects): fix vertical-menu will not render when the layout is from mobile --- src/layouts/modules/global-menu/index.vue | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/layouts/modules/global-menu/index.vue b/src/layouts/modules/global-menu/index.vue index e828fe9c..45434d92 100644 --- a/src/layouts/modules/global-menu/index.vue +++ b/src/layouts/modules/global-menu/index.vue @@ -1,6 +1,7 @@ From e8378318c6e5be88112829dcad9af9691f4ec042 Mon Sep 17 00:00:00 2001 From: Soybean Date: Mon, 22 Jul 2024 19:04:20 +0800 Subject: [PATCH 5/5] chore(projects): release v1.3.1 --- CHANGELOG.md | 22 ++++++++++++++++++++++ package.json | 2 +- packages/axios/package.json | 2 +- packages/color/package.json | 2 +- packages/hooks/package.json | 2 +- packages/materials/package.json | 2 +- packages/ofetch/package.json | 2 +- packages/scripts/package.json | 2 +- packages/uno-preset/package.json | 2 +- packages/utils/package.json | 2 +- 10 files changed, 31 insertions(+), 9 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index e2544fa9..870cb7b2 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,6 +1,28 @@ # Changelog +## [v1.3.1](https://github.com/honghuangdc/soybean-admin/compare/v1.3.0...v1.3.1) (2024-07-22) + +###    🐞 Bug Fixes + +- **projects**: + - fix the issue of abnormal width of the sidebar in the top menu mix and reverse mode  -  by @Azir-11 in https://github.com/honghuangdc/soybean-admin/issues/562 [(c4695)](https://github.com/honghuangdc/soybean-admin/commit/c469512) + - fix HorizontalMixMenu inverted. fixed #563  -  by @honghuangdc in https://github.com/honghuangdc/soybean-admin/issues/563 [(4e55b)](https://github.com/honghuangdc/soybean-admin/commit/4e55b0e) + - fix vertical-menu will not render when the layout is from mobile  -  by @honghuangdc [(84027)](https://github.com/honghuangdc/soybean-admin/commit/8402734) + +###    📖 Documentation + +- **projects**: update CHANGELOG  -  by @honghuangdc [(613c8)](https://github.com/honghuangdc/soybean-admin/commit/613c836) + +###    🎨 Styles + +- **other**: modify the Chinese name of the grayscale mode  -  by **Azir** [(53770)](https://github.com/honghuangdc/soybean-admin/commit/5377002) + +###    ❤️ Contributors + +[![honghuangdc](https://github.com/honghuangdc.png?size=48)](https://github.com/honghuangdc)  [![Azir-11](https://github.com/Azir-11.png?size=48)](https://github.com/Azir-11)   +[Azir](mailto:2075125282@qq.com),  + ## [v1.3.0](https://github.com/soybeanjs/soybean-admin/compare/v1.2.8...v1.3.0) (2024-07-22) ###    🚨 Breaking Changes diff --git a/package.json b/package.json index e2a4e160..2b04c2fe 100644 --- a/package.json +++ b/package.json @@ -1,7 +1,7 @@ { "name": "soybean-admin", "type": "module", - "version": "1.3.0", + "version": "1.3.1", "description": "A fresh and elegant admin template, based on Vue3、Vite3、TypeScript、NaiveUI and UnoCSS. 一个基于Vue3、Vite3、TypeScript、NaiveUI and UnoCSS的清新优雅的中后台模版。", "author": { "name": "Soybean", diff --git a/packages/axios/package.json b/packages/axios/package.json index ccc1bbd6..2a87e04c 100644 --- a/packages/axios/package.json +++ b/packages/axios/package.json @@ -1,6 +1,6 @@ { "name": "@sa/axios", - "version": "1.3.0", + "version": "1.3.1", "exports": { ".": "./src/index.ts" }, diff --git a/packages/color/package.json b/packages/color/package.json index 77c28c4a..9e6a5edf 100644 --- a/packages/color/package.json +++ b/packages/color/package.json @@ -1,6 +1,6 @@ { "name": "@sa/color", - "version": "1.3.0", + "version": "1.3.1", "exports": { ".": "./src/index.ts" }, diff --git a/packages/hooks/package.json b/packages/hooks/package.json index ec68a9cd..ed047710 100644 --- a/packages/hooks/package.json +++ b/packages/hooks/package.json @@ -1,6 +1,6 @@ { "name": "@sa/hooks", - "version": "1.3.0", + "version": "1.3.1", "exports": { ".": "./src/index.ts" }, diff --git a/packages/materials/package.json b/packages/materials/package.json index 2bb83d37..e478c01d 100644 --- a/packages/materials/package.json +++ b/packages/materials/package.json @@ -1,6 +1,6 @@ { "name": "@sa/materials", - "version": "1.3.0", + "version": "1.3.1", "exports": { ".": "./src/index.ts" }, diff --git a/packages/ofetch/package.json b/packages/ofetch/package.json index 59dda211..f353d94e 100644 --- a/packages/ofetch/package.json +++ b/packages/ofetch/package.json @@ -1,6 +1,6 @@ { "name": "@sa/fetch", - "version": "1.3.0", + "version": "1.3.1", "exports": { ".": "./src/index.ts" }, diff --git a/packages/scripts/package.json b/packages/scripts/package.json index a1a8c87c..94d1ff56 100644 --- a/packages/scripts/package.json +++ b/packages/scripts/package.json @@ -1,6 +1,6 @@ { "name": "@sa/scripts", - "version": "1.3.0", + "version": "1.3.1", "bin": { "sa": "./bin.ts" }, diff --git a/packages/uno-preset/package.json b/packages/uno-preset/package.json index ee6ffbed..78fe0e6c 100644 --- a/packages/uno-preset/package.json +++ b/packages/uno-preset/package.json @@ -1,6 +1,6 @@ { "name": "@sa/uno-preset", - "version": "1.3.0", + "version": "1.3.1", "exports": { ".": "./src/index.ts" }, diff --git a/packages/utils/package.json b/packages/utils/package.json index 86b241d6..09530aaa 100644 --- a/packages/utils/package.json +++ b/packages/utils/package.json @@ -1,6 +1,6 @@ { "name": "@sa/utils", - "version": "1.3.0", + "version": "1.3.1", "exports": { ".": "./src/index.ts" },