Handle top-level pushState navigation
Categories
(Firefox Graveyard :: Shopping, defect, P2)
Tracking
(firefox117 fixed)
Tracking | Status | |
---|---|---|
firefox117 | --- | fixed |
People
(Reporter: jhirsch, Assigned: Gijs)
References
Details
(Whiteboard: [fidefe-shopping])
Attachments
(1 file)
It turns out some shopping websites, like walmart.com, actually use pushState to navigate within same-site links. The onLocationChange
listener we're using in browser/base/content/browser.js filters out these navigations, so we aren't accurately detecting whether the user has navigated to/from product pages once they arrive on the site (unless they hard refresh the page).
We'll need to change how we detect navigation to ensure the product page check always fires on pushState-supported sites.
Reporter | ||
Updated•2 years ago
|
Updated•2 years ago
|
Assignee | ||
Comment 1•2 years ago
|
||
This will be due to the LOCATION_CHANGE_SAME_DOCUMENT
flag, fwiw. Just picking up onLocationChange
without checking for that flag would work.
Reporter | ||
Comment 2•2 years ago
•
|
||
This will be due to the LOCATION_CHANGE_SAME_DOCUMENT flag, fwiw. Just picking up onLocationChange without checking for that flag would work.
Thanks, at Mossop's suggestion we're detecting navigations using TabsProgressListener.onLocationChange
.
Is there a different spot we can insert into (not sure I see one), should I tack an update call into the spot where ReaderMode gets same-page navigation updates (https://searchfox.org/mozilla-central/source/browser/base/content/browser.js#5972), or should I create a webProgressListener just for the sidebar?
Assignee | ||
Comment 3•2 years ago
|
||
(In reply to Jared Hirsch [:jhirsch] (he/him) (Needinfo please) from comment #2)
This will be due to the LOCATION_CHANGE_SAME_DOCUMENT flag, fwiw. Just picking up onLocationChange without checking for that flag would work.
Thanks, at Mossop's suggestion we're detecting navigations using
TabsProgressListener.onLocationChange
.Is there a different spot we can insert into (not sure I see one), should I tack an update call into the spot where ReaderMode gets same-page navigation updates (https://searchfox.org/mozilla-central/source/browser/base/content/browser.js#5972), or should I create a webProgressListener just for the sidebar?
I think moving the call from this location to the reader mode block should work. Does that help or am I misunderstanding the question?
Reporter | ||
Updated•2 years ago
|
Assignee | ||
Comment 5•2 years ago
|
||
Stealing per discussion with Jared.
Assignee | ||
Comment 6•2 years ago
|
||
Comment 8•2 years ago
|
||
bugherder |
Updated•3 months ago
|
Description
•