Skip to content

Replace broken tooltips in devicehistory and subnet matrix#3591

Merged
Simrayz merged 5 commits intomasterfrom
fix/remove-remaining-foundation-tooltips
Oct 16, 2025
Merged

Replace broken tooltips in devicehistory and subnet matrix#3591
Simrayz merged 5 commits intomasterfrom
fix/remove-remaining-foundation-tooltips

Conversation

@Simrayz
Copy link
Copy Markdown
Contributor

@Simrayz Simrayz commented Oct 15, 2025

Scope and purpose

While upgrading jQuery libraries, I discovered that these two tools had broken tooltips still referring to Foundation code. I'm hoping this is the absolute last instances of surprise Foundation 🤞

This pull request

  • Replaces a Foundation tooltip in Device History tool with nav tooltip
  • Replaces foundation tooltips in Subnet Matrix tool with a popover, which loads data in the background
  • Removes unused stylesheets and javascript plugins

The tooltip in Subnet Matrix was replaced with a popover, as it contains links and tooltips are not clickable/persistent elements. As such, a popover is more suited for rendering information with an interactive graph (sparklines).

How to test and screenshots

Device History

  1. Open "Device History" tool, and search for a room, location, device etc.
  2. Select an item in the selects, and click "View history" (e.g. "View room history", if viewing room results)
  3. In the tables on the next page, hover the Netbox column
  4. The netbox column should display room and location info for each netbox.

Before (Branch: 5.14.x)

image

After

image

Subnet Matrix

  1. Open "Report" tool, and click "Subnet matrix" (url: /report/matrix)
  2. Choose either an ipv4 or ipv5 subnet
  3. Click on a an item in the subnet matrix, to view a popover with content.

Before (Branch: 5.14.x)

subnetmatrix-tooltip-before

After

image

Contributor Checklist

Every pull request should have this checklist filled out, no matter how small it is.
More information about contributing to NAV can be found in the
Hacker's guide to NAV.

  • Added a changelog fragment for towncrier
  • Added/amended tests for new/changed code
  • Added/changed documentation
  • Linted/formatted the code with ruff, easiest by using pre-commit
  • Wrote the commit message so that the first line continues the sentence "If applied, this commit will ...", starts with a capital letter, does not end with punctuation and is 50 characters or less long. See https://cbea.ms/git-commit/
  • Based this pull request on the correct upstream branch: For a patch/bugfix affecting the latest stable version, it should be based on that version's branch (<major>.<minor>.x). For a new feature or other additions, it should be based on master.
  • If applicable: Created new issues if this PR does not fix the issue completely/there is further work to be done
  • If it's not obvious from a linked issue, described how to interact with NAV in order for a reviewer to observe the effects of this change first-hand (commands, URLs, UI interactions)
  • If this results in changes in the UI: Added screenshots of the before and after
  • If this adds a new Python source code file: Added the boilerplate header to that file

@Simrayz Simrayz force-pushed the fix/remove-remaining-foundation-tooltips branch from f430b4c to 5c69fe1 Compare October 15, 2025 13:13
@sonarqubecloud
Copy link
Copy Markdown

@github-actions
Copy link
Copy Markdown

Test results

    27 files      27 suites   45m 46s ⏱️
 2 586 tests  2 586 ✅ 0 💤 0 ❌
19 078 runs  19 078 ✅ 0 💤 0 ❌

Results for commit 5c69fe1.

@codecov
Copy link
Copy Markdown

codecov bot commented Oct 15, 2025

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 62.21%. Comparing base (843ca70) to head (5c69fe1).
⚠️ Report is 306 commits behind head on master.

Additional details and impacted files
@@           Coverage Diff           @@
##           master    #3591   +/-   ##
=======================================
  Coverage   62.21%   62.21%           
=======================================
  Files         611      611           
  Lines       44939    44939           
  Branches       43       43           
=======================================
  Hits        27960    27960           
  Misses      16969    16969           
  Partials       10       10           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

Copy link
Copy Markdown
Member

@lunkwill42 lunkwill42 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM 😃

@Simrayz Simrayz merged commit f441293 into master Oct 16, 2025
19 checks passed
@Simrayz Simrayz deleted the fix/remove-remaining-foundation-tooltips branch October 16, 2025 21:32
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants