app

Local-first trade for farms and co-ops
git clone https://radroots.dev/git/app.git
Log | Files | Refs | README | LICENSE

commit d233ed4d3ce6f0dd29c49a46a9f97f4fea52871a
parent b412f283ef77b14441c8926bb43a85e27b309aed
Author: triesap <tyson@radroots.org>
Date:   Sun, 22 Mar 2026 12:04:17 +0000

web: keep async home location lookup unavailable

- implement the async reverse-lookup request hook on web as an explicit unavailable result
- keep the new polled lookup contract honest without inventing a fake pending or success path on wasm
- preserve the existing unavailable diagnostics for the offline geocoder and location resolver on web
- verify the web crate tests and wasm cargo check stay green under the async lookup contract

Diffstat:
Mcrates/web/src/lib.rs | 16+++++++++++++++-
1 file changed, 15 insertions(+), 1 deletion(-)

diff --git a/crates/web/src/lib.rs b/crates/web/src/lib.rs @@ -20,7 +20,7 @@ use radroots_app_core::{ HomeActionKind, HomeActionResult, HomeActionState, IdentityGateState, RadrootsApp, RadrootsAppBackend, RadrootsLocationCountry, RadrootsLocationPoint, RadrootsLocationResolverError, RadrootsLocationReverseOptions, RadrootsResolvedLocation, - SetupActionState, + RadrootsReverseLocationLookupResult, SetupActionState, }; #[cfg(any(target_arch = "wasm32", test))] use radroots_app_core::{ @@ -129,6 +129,20 @@ impl RadrootsAppBackend for WebBackend { Err(location_resolver_unavailable_error()) } + fn request_reverse_location_lookup( + &self, + _point: RadrootsLocationPoint, + _options: Option<RadrootsLocationReverseOptions>, + ) -> Result<(), RadrootsLocationResolverError> { + Err(location_resolver_unavailable_error()) + } + + fn poll_reverse_location_lookup_result( + &self, + ) -> Result<Option<RadrootsReverseLocationLookupResult>, String> { + Ok(None) + } + fn list_location_countries( &self, ) -> Result<Vec<RadrootsLocationCountry>, RadrootsLocationResolverError> {