feat: 增强地址处理逻辑,支持日本地区并优化相关测试用例

This commit is contained in:
QLHazyCoder
2026-04-26 15:59:14 +08:00
parent 6c2bec6520
commit 5271ec5b59
5 changed files with 264 additions and 13 deletions
+23
View File
@@ -5,6 +5,7 @@
AU: ['au', 'aus', 'australia', '澳大利亚'],
DE: ['de', 'deu', 'germany', 'deutschland', '德国'],
FR: ['fr', 'fra', 'france', '法国'],
JP: ['jp', 'jpn', 'japan', '日本', '日本国'],
US: ['us', 'usa', 'united states', 'united states of america', 'america', '美国'],
};
@@ -75,6 +76,28 @@
},
},
],
JP: [
{
query: 'Tokyo Marunouchi',
suggestionIndex: 1,
fallback: {
address1: 'Marunouchi 1-1',
city: 'Chiyoda-ku',
region: 'Tokyo',
postalCode: '100-0005',
},
},
{
query: 'Osaka Umeda',
suggestionIndex: 1,
fallback: {
address1: 'Umeda 3-1',
city: 'Kita-ku',
region: 'Osaka',
postalCode: '530-0001',
},
},
],
US: [
{
query: 'New York NY',