Skip to content

Commit d0bb95a

Browse files
authored
[ISSUE #5887]✨Enhance navbar styling with animated title and improved link effects (#5888)
1 parent 579de51 commit d0bb95a

File tree

2 files changed

+54
-10
lines changed

2 files changed

+54
-10
lines changed

rocketmq-website/docusaurus.config.ts

Lines changed: 6 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -94,29 +94,27 @@ const config: Config = {
9494
},
9595
items: [
9696
{
97-
type: 'docSidebar',
98-
sidebarId: 'docsSidebar',
97+
to: '/docs/introduction',
9998
position: 'left',
10099
label: 'Documentation',
100+
activeBaseRegex: '^/docs/(?!contributing|author)',
101101
},
102102
{
103103
to: '/blog',
104104
position: 'left',
105105
label: 'Release Notes',
106106
},
107107
{
108-
type: 'doc',
109-
docId: 'contributing/overview',
110-
sidebarId: 'docsSidebar',
108+
to: '/docs/contributing/overview',
111109
position: 'left',
112110
label: 'Contribute',
111+
activeBaseRegex: '^/docs/contributing',
113112
},
114113
{
115-
type: 'doc',
116-
docId: 'author',
117-
sidebarId: 'docsSidebar',
114+
to: '/docs/author',
118115
position: 'left',
119116
label: 'Author',
117+
activeBasePath: '/docs/author',
120118
},
121119
{
122120
href: 'https://github.com/mxsm/rocketmq-rust',

rocketmq-website/src/css/custom.css

Lines changed: 48 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -124,9 +124,55 @@ markdown > table {
124124
backdrop-filter: blur(10px);
125125
}
126126

127+
/* Make navbar title (RocketMQ-Rust) larger and bold with animation */
128+
.navbar__title {
129+
font-size: 1.5rem !important;
130+
font-weight: 700 !important;
131+
letter-spacing: -0.02em;
132+
background: linear-gradient(135deg, #a855f7 0%, #06b6d4 50%, #a855f7 100%);
133+
background-size: 200% auto;
134+
-webkit-background-clip: text;
135+
-webkit-text-fill-color: transparent;
136+
background-clip: text;
137+
animation: gradient-shift 3s ease infinite;
138+
transition: transform 0.3s ease;
139+
}
140+
141+
.navbar__title:hover {
142+
transform: scale(1.05);
143+
animation: gradient-shift 1.5s ease infinite;
144+
}
145+
146+
@keyframes gradient-shift {
147+
0% {
148+
background-position: 0% center;
149+
}
150+
50% {
151+
background-position: 100% center;
152+
}
153+
100% {
154+
background-position: 0% center;
155+
}
156+
}
157+
158+
@keyframes scale-in {
159+
0% {
160+
transform: scale(0.9);
161+
}
162+
50% {
163+
transform: scale(1.15);
164+
}
165+
100% {
166+
transform: scale(1);
167+
}
168+
}
169+
170+
/* Navbar links styling - removed colorful gradients, keep default */
127171
.navbar__link--active {
128-
color: var(--ifm-color-primary) !important;
129-
font-weight: 600;
172+
font-weight: 700 !important;
173+
animation: scale-in 0.4s ease-out;
174+
transform: scale(1);
175+
display: inline-block;
130176
}
131177

132178
/* Better footer */

0 commit comments

Comments
 (0)