Skip to content

Duplicate navbarDropdown IDs Break Dropdown Menus #33

@keraattin

Description

@keraattin

Bug Description
The generated HTML report contains four elements sharing id="navbarDropdown" — one per navigation section. Duplicate IDs are invalid HTML and cause Bootstrap's JavaScript to bind dropdown behavior only to the first match, leaving the Links, Attachments, and Digests dropdowns non-functional in some browsers.

Expected Behavior or Results
Each navbar dropdown should have a unique ID so all four menus open correctly.

Reproduce Steps

  1. Run python3 email-analyzer.py -f sample.eml -o report.html
  2. Open report.html in a browser
  3. Click the Links, Attachments, or Digests navbar items — they may not open
  4. Inspect the HTML source and find four elements with id="navbarDropdown"

Desktop (please complete the following information):

  • OS with Version: Any
  • Python Version: Python 3.10+
  • Browser with Version: Firefox / Chrome (behavior varies)
  • EmailAnalyzer Project Version: v2.0

Additional context
Affected code - html_generator.py lines 276, 284, 293, 303:

<a class="nav-link dropdown-toggle" href="#" id="navbarDropdown" ...>

Fix: use unique IDs like id="headersDropdown", id="linksDropdown", id="attachmentsDropdown", id="digestsDropdown" with matching aria-labelledby attributes.

Metadata

Metadata

Assignees

Labels

No labels
No labels

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions