Open dandv opened 7 years ago
Smarter filtering would be nice. However, it would mean passing all addresses to the merchant, and that doesn't seem great from a privacy perspective...
Conversely, the merchant would need to pass in all the states for each country that they support. That could be more doable, but we would need a standardized list of all the states/provinces/regions in the world.
the merchant would need to pass in all the states for each country that they support
ISO3166 standardizes the country code. Provinces and regions are more of a can of worms, agreed, but perhaps filtering by country would cover 80% of the use cases.
Turns out ISO3166 also does regions (things you learn 👨🏫).
Step 1 will be do add region codes to w3c/contact-picker#65.
This issue was raised in Payment Request, but closed once we removed addresses from that API. We anticipate adding addresses back to the specification and so are re-opening this issue proactively.
We added addresses back to the specification in the 7 August 2024 CRD
If a merchant only ships to certain regions, it would be useful to pre-filter the shipping addresses the user can select from. The case of no eligible address would be quite frequent - the user could see instead an explanation provided by the merchant, along with an affordance for adding an eligible address.
Example use cases: