Switching region subpages without reload
Part of #1838
What does this MR do?
Allows changing subpages of the region page without reloading the whole page. Instead, an event signals that the vue component should be switched. This still only works for some subpages of the region page (wall, events, members, statistics, applications, pin). The others still work as normal links.
This makes the page somewhat faster and removes unnecessary queries for the header and the admin lists.
How confident are you it won't break things if deployed?
Quite sure. The links are only used in the menu on the region page and in the dropdown. I added a special treatment for the latter case, because the dropdown should keep using normal links.
Links to related issues
How to test
- Checkout branch locally
- Login as foodsaver
- Open any region's page
- Make sure that all links in the dropdown in the region menu work
- Make sure that all links in the menu on the region page work
Screenshots (if applicable)
Checklist
-
added a test, or explain why one is not needed/possible... -
no unrelated changes -
asked someone for a code review -
set a "for:" label to indicate who will be affected by this change -
set the "API change" label if changes in the API are not backward compatible -
added to the next milestone (see https://gitlab.com/foodsharing-dev/foodsharing/-/milestones, unless it has a "for:Dev" label) -
added an entry to CHANGELOG.md
-
added a short text in the release notes to /release-notes/YYYY-MM.md -
Once your MR has been merged, you are responsible to create a testing issue in the Beta Testing forum: https://foodsharing.de/region?bid=2296&sub=forum. Please change the MRs label to "state:Beta testing". - Consider writing a detailed description in German.
- Describe in a few sentences, what should be tested from a user perspective.
- Also mention different settings (e.g. different browsers, roles, ...) how this change can be tested.
- Be aware, that also non technical people should understand.
Edited by Alex