commit 04294001f94b2c7abac848682db02ec6d23e0303
parent 2e502ee1339c279b4111a154ea95c9b9292e57ca
Author: triesap <tyson@radroots.org>
Date: Sun, 22 Mar 2026 13:14:27 +0000
web: keep async home country lookup unavailable
- implement the new country lookup request surface with explicit unavailable errors on web
- keep the wasm backend aligned with the async country lookup contract without faking support
- preserve the existing offline geocoder unavailable state and location resolver semantics on web
- verify the web crate and wasm check lane stay green with the expanded contract
Diffstat:
1 file changed, 27 insertions(+), 3 deletions(-)
diff --git a/crates/web/src/lib.rs b/crates/web/src/lib.rs
@@ -18,9 +18,10 @@ use radroots_app_core::RadrootsLocationResolverError;
#[cfg(target_arch = "wasm32")]
use radroots_app_core::{
HomeActionKind, HomeActionResult, HomeActionState, IdentityGateState, RadrootsApp,
- RadrootsAppBackend, RadrootsLocationCountry, RadrootsLocationPoint,
- RadrootsLocationResolverError, RadrootsLocationReverseOptions, RadrootsResolvedLocation,
- RadrootsReverseLocationLookupResult, SetupActionState,
+ RadrootsAppBackend, RadrootsLocationCountry, RadrootsLocationCountryCenterLookupResult,
+ RadrootsLocationCountryListResult, RadrootsLocationPoint, RadrootsLocationResolverError,
+ RadrootsLocationReverseOptions, RadrootsResolvedLocation, RadrootsReverseLocationLookupResult,
+ SetupActionState,
};
#[cfg(any(target_arch = "wasm32", test))]
use radroots_app_core::{
@@ -143,6 +144,29 @@ impl RadrootsAppBackend for WebBackend {
Ok(None)
}
+ fn request_location_country_list(&self) -> Result<(), RadrootsLocationResolverError> {
+ Err(location_resolver_unavailable_error())
+ }
+
+ fn poll_location_country_list_result(
+ &self,
+ ) -> Result<Option<RadrootsLocationCountryListResult>, String> {
+ Ok(None)
+ }
+
+ fn request_location_country_center_lookup(
+ &self,
+ _country_id: &str,
+ ) -> Result<(), RadrootsLocationResolverError> {
+ Err(location_resolver_unavailable_error())
+ }
+
+ fn poll_location_country_center_lookup_result(
+ &self,
+ ) -> Result<Option<RadrootsLocationCountryCenterLookupResult>, String> {
+ Ok(None)
+ }
+
fn list_location_countries(
&self,
) -> Result<Vec<RadrootsLocationCountry>, RadrootsLocationResolverError> {