Repository navigation
Show feedback modal after resetting WAYF remembered choice - #358
Open
kayjoosten wants to merge 1 commit into
Open
kayjoosten wants to merge 1 commit into
kayjoosten wants to merge 1 commit into
Conversation
# If applied, this commit will Show the user a modal confirming the outcome of resetting their remembered WAYF login-method choice. # Why is this change needed? Prior to this change, resetting the "remember my choice" cookie via the profile page redirected back silently. The user had no feedback on whether a cookie was actually removed or whether there was none to begin with. # How does it address the issue? This change reads the wayfReset query parameter set by EngineBlock's reset endpoint (removed or none) through a new WayfResetResultResolver service, and passes it to the overview template. The template renders an auto-opening modal, reusing the existing modal helper, with copy that matches the removed/none outcome. The modal helper is extended with autoOpen and cleanParam options so the modal shows itself on load and the query parameter is stripped from the URL afterwards, and its header id is now derived from the modal's own linkId rather than loop.index so multiple modals on one page never collide. # Provide links to any relevant tickets, articles or other resources #350
kayjoosten
force-pushed
the
350-wayf-reset-feedback-modal
branch
from
October 2, 2026 11:58
1917fa1 to
4a5a1f7
Compare
johanib
reviewed
Oct 6, 2026
johanib
left a comment
Contributor
There was a problem hiding this comment.
Code seems fine, just the weird history.replace. Can we prevent this? Seems to bug out in ff?
| if (cleanParam) { | ||
| const url = new URL(window.location.href); | ||
| url.searchParams.delete(cleanParam); | ||
| window.history.replaceState(null, '', url.pathname + url.search + url.hash); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
If applied, this commit will
Show the user a modal confirming the outcome of resetting their remembered WAYF login-method choice.
Why is this change needed?
Prior to this change, resetting the "remember my choice" cookie via the profile page redirected back silently. The user had no feedback on whether a cookie was actually removed or whether there was none to begin with.
How does it address the issue?
This change reads the
wayfResetquery parameter set by EngineBlock's reset endpoint (removedornone) through a newWayfResetResultResolverservice, and passes it to the overview template. The template renders an auto-opening modal, reusing the existing modal helper, with copy that matches the removed/none outcome. The modal helper is extended withautoOpenandcleanParamoptions so the modal shows itself on load and the query parameter is stripped from the URL afterwards, and its header id is now derived from the modal's ownlinkIdrather thanloop.indexso multiple modals on one page never collide.Builds on top of #353.
Provide links to any relevant tickets, articles or other resources
Fixes #350