Skip to content

Bug 8726-URL-based layout persistence#8729

Open
Seth-Wadsworth wants to merge 2 commits intomakeplane:previewfrom
WSU-CptS-481-Spring-2026:SW-Bug-8726
Open

Bug 8726-URL-based layout persistence#8729
Seth-Wadsworth wants to merge 2 commits intomakeplane:previewfrom
WSU-CptS-481-Spring-2026:SW-Bug-8726

Conversation

@Seth-Wadsworth
Copy link

@Seth-Wadsworth Seth-Wadsworth commented Mar 8, 2026

Description

This PR resolves an issue where the selected layout on the Views page would reset whenever the user clicked outside the browser window or navigated between pages. The previous implementation stored layout state only in local component state, which was overwritten during re‑renders triggered by focus changes or navigation. To ensure predictable behavior and persistent layout selection, the layout state has been moved into a URL‑driven model. The selected layout is now encoded in the query parameters, allowing it to persist across navigation, refreshes, and window focus changes.

Type of Change

  • Bug fix (non-breaking change which fixes an issue)
  • Feature (non-breaking change which adds functionality)
  • Improvement (change that would cause existing functionality to not work as expected)
  • Code refactoring
  • Performance improvements
  • Documentation update

Screenshots and Media (if applicable)

Test Scenarios

Testing focused on verifying that layout selection now persists reliably across all interaction patterns that previously caused resets. Manual testing confirmed that selecting a layout correctly updates the URL and that refreshing the page restores the chosen layout. Additional regression testing validated that clicking outside the browser window no longer triggers a reset and that navigation between different views preserves the layout parameter. Unit tests were added for the updated layout‑selection logic to ensure that URL parsing and query‑parameter updates behave consistently and do not introduce regressions.

References

#8726

Summary by CodeRabbit

  • New Features
    • Layout preferences are now persisted in the URL, allowing users to bookmark and share links with specific layout configurations.
    • When visiting a shared link with a layout parameter, the app automatically applies that layout on page load.

Loading
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants