Skip to content

fix(calm-hub-ui): reload resource when the hash is edited by hand - #3531

Merged
markscott-ms merged 1 commit into
finos:mainfrom
Mittalnew:fix-hub-ui-hash-navigation
Oct 27, 2026
Merged

markscott-ms merged 1 commit into
finos:mainfrom
Mittalnew:fix-hub-ui-hash-navigation

Conversation

@Mittalnew

Copy link
Copy Markdown
Contributor

Fixes #3504

When the URL hash is edited by hand, React Router has no history state for the new location and gives it the key "default", the same key as a first page load. useResourceNavigationKey only compared location.key, so it did not see a navigation and Hub kept the previously loaded resource on screen.

For locations with the key "default", the hook now also uses the pathname to tell navigations apart. A query-only change under that key still keeps the resource, as before.

Testing: added two regression tests for locations without history state (a path change changes the key, a query-only change keeps it). The path change test fails without the fix. The existing tests in src/hub/hooks still pass and eslint is clean. I did not run the full hub with a backend locally, so I have not checked the exact steps from the issue in a browser.

@Mittalnew
Mittalnew requested a review from a team as a code owner October 27, 2026 09:46
@linux-foundation-easycla

linux-foundation-easycla Bot commented Oct 27, 2026 •

Copy link
Copy Markdown

CLA Signed
The committers listed above are authorized under a signed CLA.

  • ✅ login: Mittalnew / name: Mittal Chauhan (7c7cdda)

@markscott-ms markscott-ms left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Thank you for this fix and for the regression tests. It solves the problem in #3504.

@markscott-ms
markscott-ms merged commit b4c692d into finos:main Oct 27, 2026
22 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

calm-hub-ui Affects `calm-hub-ui`

Projects

None yet

Development

Successfully merging this pull request may close these issues.

calm-hub-ui: a URL that you edit by hand keeps the previous resource on screen

2 participants