From f0d9c8965907907d8ae0048bf9d70a0140c44de1 Mon Sep 17 00:00:00 2001 From: CalciumIon <1808837298@qq.com> Date: Wed, 11 Dec 2024 23:13:46 +0800 Subject: [PATCH] feat: Add pricing link to HeaderBar component MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - Introduced a new '定价' (Pricing) item in the HeaderBar navigation for better accessibility to pricing information. - Updated routing to include the new '/pricing' path. - Adjusted user display in the HeaderBar for mobile responsiveness, hiding the username on smaller screens for a cleaner interface. --- web/src/components/HeaderBar.js | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/web/src/components/HeaderBar.js b/web/src/components/HeaderBar.js index 039697b95..6234d8674 100644 --- a/web/src/components/HeaderBar.js +++ b/web/src/components/HeaderBar.js @@ -67,6 +67,11 @@ const HeaderBar = () => { itemKey: 'detail', to: '/', }, + { + text: '定价', + itemKey: 'pricing', + to: '/pricing', + }, ]; async function logout() { @@ -112,6 +117,7 @@ const HeaderBar = () => { about: '/about', login: '/login', register: '/register', + pricing: '/pricing', detail: '/detail', home: '/', }; @@ -180,7 +186,7 @@ const HeaderBar = () => { <> { @@ -205,7 +211,7 @@ const HeaderBar = () => { > {userState.user.username[0]} - {userState.user.username} + {styleState.isMobile?null:{userState.user.username}} ) : (