From d3e8b62581356d55d82f977aa7c8b947b8d13787 Mon Sep 17 00:00:00 2001 From: ZF sun <34314687@qq.com> Date: Thu, 2 Jul 2026 16:56:13 +0800 Subject: [PATCH] docs(i18n): update request failed error prompt to include error info add {err} placeholder to both en-us and zh-cn language packs for request failed error message, also fix indentation consistency in zh-cn common.js --- lang/en-us/common.js | 2 +- lang/zh-cn/common.js | 94 ++++++++++++++++++++++---------------------- 2 files changed, 48 insertions(+), 48 deletions(-) diff --git a/lang/en-us/common.js b/lang/en-us/common.js index ccc46bb..b919d19 100644 --- a/lang/en-us/common.js +++ b/lang/en-us/common.js @@ -131,7 +131,7 @@ export const lang = { // domain not in whitelist: {url} is the domain placeholder domainNotInList: '{url} is not in the request domain whitelist', // request failed: {url} is the domain placeholder - requestFailed: '{url} request failed', + requestFailed: '{url} request failed. {err}', }, // share utility diff --git a/lang/zh-cn/common.js b/lang/zh-cn/common.js index 15bc5e2..e463ef3 100644 --- a/lang/zh-cn/common.js +++ b/lang/zh-cn/common.js @@ -8,52 +8,52 @@ export const lang = { member: '个人中心' }, - //公共 - common: { - //语言包名称 - name: '中文', - mescrollTextInOffset: '下拉刷新', - mescrollTextOutOffset: '释放更新', - mescrollEmpty: "暂无相关数据", - goodsRecommendTitle: '猜你喜欢', - currencySymbol: '¥', - submit: '提交', - searchTip: '请输入搜索关键词', - // 版本更新 - updateTip: '更新提示', - updateReady: '新版本已经准备好,是否重启应用?', - // 网络状态 - networkLost: '网络失去链接', - networkCheck: '请检查网络链接', - // 配置相关 - config: { - siteJsNotConfigured: '小程序发行环境下,必须配置site.js文件,不然将使用默认配置,影响小程序定制分发!' - }, - // 平台检测 - platform: { - wechatOfficialAccount: '微信公众号', - wechatMiniProgram: '微信小程序', - alipayMiniProgram: '支付宝小程序', - baiduMiniProgram: '百度小程序', - toutiaoMiniProgram: '头条小程序', - qqMiniProgram: 'QQ小程序', - kuaishouMiniProgram: '快手小程序', - jdMiniProgram: '京东小程序', - miniProgram360: '360小程序', - xhsMiniProgram: '小红书小程序', - harmonyService: '鸿蒙元服务', - app: 'APP', - pc: 'PC端', - h5: 'H5', - unknown: '未知平台', - }, - }, - - // 导航工具 - navigation: { - serviceUnavailable: '导航服务暂时不可用', - }, - + //公共 + common: { + //语言包名称 + name: '中文', + mescrollTextInOffset: '下拉刷新', + mescrollTextOutOffset: '释放更新', + mescrollEmpty: "暂无相关数据", + goodsRecommendTitle: '猜你喜欢', + currencySymbol: '¥', + submit: '提交', + searchTip: '请输入搜索关键词', + // 版本更新 + updateTip: '更新提示', + updateReady: '新版本已经准备好,是否重启应用?', + // 网络状态 + networkLost: '网络失去链接', + networkCheck: '请检查网络链接', + // 配置相关 + config: { + siteJsNotConfigured: '小程序发行环境下,必须配置site.js文件,不然将使用默认配置,影响小程序定制分发!' + }, + // 平台检测 + platform: { + wechatOfficialAccount: '微信公众号', + wechatMiniProgram: '微信小程序', + alipayMiniProgram: '支付宝小程序', + baiduMiniProgram: '百度小程序', + toutiaoMiniProgram: '头条小程序', + qqMiniProgram: 'QQ小程序', + kuaishouMiniProgram: '快手小程序', + jdMiniProgram: '京东小程序', + miniProgram360: '360小程序', + xhsMiniProgram: '小红书小程序', + harmonyService: '鸿蒙元服务', + app: 'APP', + pc: 'PC端', + h5: 'H5', + unknown: '未知平台', + }, + }, + + // 导航工具 + navigation: { + serviceUnavailable: '导航服务暂时不可用', + }, + //客服 customer: { weChatKefu: '微信客服', @@ -131,7 +131,7 @@ export const lang = { // 域名不在合法列表中: {url} 为域名占位符 domainNotInList: '{url}不在request 合法域名列表中', // 请求失败: {url} 为域名占位符 - requestFailed: '{url}请求失败', + requestFailed: '{url}请求失败. {err}', }, // share 分享工具