- {searchTerm
- ? `${locationData.locationResult.length} ${
- locationData.locationResult.length === 1
- ? t("match", "match")
- : t("matches", "matches")
- } ${t("found", "found")}`
- : `${t("showing", "Showing")} ${pageSize} ${t("of", "of")} ${
- locationData.locationResult.length
- } ${t("locations", "locations")}`}
-
- {!isEmpty(locationData.locationResult) && (
-
{
- changeLocationData({ activeLocation: ev.toString() });
- }}
- >
- {locationData.locationResult
- .slice(0, pageSize)
- .map((entry) => (
-
- ))}
-
- )}
- {locationData.locationResult.length === 0 && (
-
-
- Sorry, no matching location was found
-
+
+ {!isLoading ? (
+ <>
+
+ {searchTerm
+ ? `${locationData?.length ?? 0} ${
+ locationData?.length === 1
+ ? t("match", "match")
+ : t("matches", "matches")
+ } ${t("found", "found")}`
+ : `${t("showing", "Showing")} ${pageSize} ${t(
+ "of",
+ "of"
+ )} ${totalResults} ${t("locations", "locations")}`}
- )}
-
-
+
+ {locationData?.length > 0 && (
+
{
+ setActiveLocation(ev.toString());
+ }}
+ >
+ {locationData.map((entry) => (
+
+ ))}
+
+ )}
+ {locationData?.length === 0 && (
+
+ {t(
+ "locationNotFound",
+ "Sorry, no matching location was found"
+ )}
+
+ )}
+
+
+ {hasMore && (
+
+
+
+ )}
+ >
+ ) : (
+
+
-
+ )}
-
+
diff --git a/packages/apps/esm-login-app/translations/en.json b/packages/apps/esm-login-app/translations/en.json
index 755bbc92c..57dbb9fb4 100644
--- a/packages/apps/esm-login-app/translations/en.json
+++ b/packages/apps/esm-login-app/translations/en.json
@@ -6,6 +6,7 @@
"error": "Error",
"found": "found",
"invalidCredentials": "Invalid username or password",
+ "loading": "Loading",
"locationNotFound": "Sorry, no matching location was found.",
"locations": "locations",
"login": "Log in",