diff options
author | Dave Arter <davea@mysociety.org> | 2018-01-29 11:44:32 +0000 |
---|---|---|
committer | Dave Arter <davea@mysociety.org> | 2018-01-30 09:21:20 +0000 |
commit | 692a00d19ccce5bebeb0255c773ff69235620c58 (patch) | |
tree | 494b3c0461eff56fa78f2812e78f69f8dac40984 | |
parent | 7b9a1fc9bf336884bad4d26c799b5233839b8617 (diff) |
Show loading message on /around page load
The map and sidebar are empty on /around when the page loads, and JS is used
to pull in the relevant reports and populate the page. The previous message
indicated that there were no reports at all, but in fact they were being loaded
asynchronously. This commit shows a more helpful message whilst the pins are
being loaded.
-rw-r--r-- | CHANGELOG.md | 3 | ||||
-rw-r--r-- | templates/web/base/around/on_map_list_items.html | 6 |
2 files changed, 7 insertions, 2 deletions
diff --git a/CHANGELOG.md b/CHANGELOG.md index 89606fe01..5a8a73575 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,7 +2,8 @@ * Unreleased - Front end improvements: - - Zoom out as much as necessary on body map page, even on mobile. #1958 + - Zoom out as much as necessary on body map page, even on mobile. #1958 + - Show loading message on initial /around map load #1976 - Bugfixes: - Fix bug specifying category in URL on /around. #1950 - Fix bug with multiple select-multiples on a page. #1951 diff --git a/templates/web/base/around/on_map_list_items.html b/templates/web/base/around/on_map_list_items.html index fafe7f433..e1be87754 100644 --- a/templates/web/base/around/on_map_list_items.html +++ b/templates/web/base/around/on_map_list_items.html @@ -14,7 +14,11 @@ </li> [% ELSE %] <li class="item-list__item item-list__item--empty"> - <p>[% loc('There are no reports to show.') %]</p> + [% IF c.get_param('js') %] + <p>[% loc('Loading reports…') %]</p> + [% ELSE %] + <p>[% loc('There are no reports to show.') %]</p> + [% END %] </li> [% END %] </ul> |