Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[BUG] Sidebar menu items with custom mappings don't show as active #1335

Open
timcappalli opened this issue Dec 30, 2024 · 0 comments
Open
Labels
bug Something isn't working

Comments

@timcappalli
Copy link
Contributor

Describe the bug

When a link is manually mapped in docs.yml with different text than the title, the menu item does not show as active when clicked.

It doesn't seem to be an issue when link is just the same text with or without a space (see screenshots).

To reproduce

Steps to reproduce the behavior:

  1. Add a new docs page
  2. Add a new menu/sidebar item using a different name, and add the link attribute underneath
  3. Click the page in the sidebar

Expected behavior

The menu item should be a:active.

Log file

n/a

Screenshots

Here's the relevant docs.yml section:

- title: Reference
  pages:
    - title: Android
    - title: "iOS & iPadOS"
      link: iOS
    - title: Chrome OS
      link: chromeos
    - title: macOS
    - title: Windows
    - title: Known Issues
    - title: Specifications
      link: specs
    - title: Terms

"Chrome OS" page (working, just has a space)

image

"Windows" page (working, exact match)

image

"iOS & iPadOS" (not working, different)

image

Host environment

Please complete the following information where applicable.

  • Hinode version: 0.27.17
  • Host OS: 15.3
  • Node version:v20.16.0
  • Browser: Chrome 132.0.6834.57 (Official Build) beta (arm64)

Hugo environment

Copy the output of hugo env or npm run env here.

hugo v0.140.1+extended+withdeploy darwin/arm64 BuildDate=2024-12-23T16:26:35Z VendorInfo=brew
GOOS="darwin"
GOARCH="arm64"
GOVERSION="go1.23.4"
github.com/sass/libsass="3.6.6"
github.com/webmproject/libwebp="v1.3.2"
@timcappalli timcappalli added the bug Something isn't working label Dec 30, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant