fix(layout): highlight write nav for both /write and /write/:id
This commit is contained in:
parent
4805f915c7
commit
077573af67
@ -46,7 +46,7 @@ pub fn AdminLayout() -> Element {
|
|||||||
NavItemConfig {
|
NavItemConfig {
|
||||||
route: Route::Write {},
|
route: Route::Write {},
|
||||||
label: "写文章",
|
label: "写文章",
|
||||||
is_active: matches!(route, Route::Write {}),
|
is_active: matches!(route, Route::Write {}) || matches!(route, Route::WriteEdit { .. }),
|
||||||
},
|
},
|
||||||
NavItemConfig {
|
NavItemConfig {
|
||||||
route: Route::Posts {},
|
route: Route::Posts {},
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user