Sync filters between Suite and Visual Checks pages#769
Conversation
✅ Component tests succeed
|
✅ E2E tests succeed
|
978a904 to
9765364
Compare
commit: |
38bf835 to
b8aeaa9
Compare
2cd42f0 to
62d37df
Compare
shadowusr
left a comment
There was a problem hiding this comment.
One more thing that I think belongs to this PR is syncing selected tree items between two pages. So when user opens certain test and has some visual check in view, we should attempt to open it in visual checks, similarly, when selecting any visual checks and then going to suites page, we should open the exact suite&visual check that was selected on the visual checks page.
In case there's no visual check associated with suite on visual checks page, we should do nothing, preserving old behavior.
| } | ||
| localStorageWrapper.setItem('app.suitesPage.viewMode', app.suitesPage.viewMode); | ||
| localStorageWrapper.setItem('app.visualChecksPage.viewMode', app.visualChecksPage.viewMode); | ||
| localStorageWrapper.setItem('app.viewMode', app.viewMode); |
There was a problem hiding this comment.
This doesn't work: after page reload, filter resets to "All" regardless of what was chosen previously
There was a problem hiding this comment.
Fixed both problem, now view saved in localStorage (this bug was in master also) and now selected items also synced between pages
d452752 to
032cccb
Compare
shadowusr
left a comment
There was a problem hiding this comment.
Overall, looks great! Two things:
-
Could you also please check one more thing, since you’ve been changing the browser filters state logic: does filtering by browser work on the Visual Checks page at all? It doesn’t work on master, and it looks like it probably never did.
-
I’m also still a bit unsure about this flow:
- Select a test without a visual check.
- Go to the Visual Checks page, where the first item gets auto-selected.
- Go back to the Suites page, and we end up on the test that contains the first visual check in the list.
IMO, this feels a bit strange. I would expect this flow to end on the same test that was originally selected. When switching to Visual Checks, we could either show “nothing selected” or avoid treating this auto-selection of the first item as a real user selection.
But this is not critical — please take a look and do what seems best to you.
No description provided.