Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

popstate event always prevented for non-modal states #2

Open
zipper opened this issue May 22, 2023 · 0 comments
Open

popstate event always prevented for non-modal states #2

zipper opened this issue May 22, 2023 · 0 comments
Assignees

Comments

@zipper
Copy link
Contributor

zipper commented May 22, 2023

There is a problem for non-modal request, where AjaxModalExtension calls event.stopImmediatePropagation() for every non-modal state retrieved. Therefore no other popstate handlers will be run, even from other extensions or unrelated page scripts (if they were added after this callback).

Originally this event.stopImmediatePropagation() has been added for preventing extra request when closing modal which has been opened with data-naja-snippet-cache="off". In that case, there was an unnecessary request made.

@zipper zipper self-assigned this May 22, 2023
@zipper zipper changed the title Naja popstate event always prevented popstate event always prevented May 22, 2023
@zipper zipper changed the title popstate event always prevented popstate event always prevented for non-modal states May 22, 2023
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

No branches or pull requests

1 participant