From 23130918d13827cf58d4288d408b3f8569c3dc79 Mon Sep 17 00:00:00 2001 From: Xc Date: Mon, 14 Aug 2023 19:12:29 +0800 Subject: [PATCH] =?UTF-8?q?i18ns=E7=9A=84=E7=BC=96=E8=AF=91?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- lib/data/actionAuth.d.ts | 3 +- lib/data/actionAuth.js | 4 +- lib/data/area.d.ts | 3 +- lib/data/area.dev.d.ts | 2 +- lib/data/area.dev.js | 3 +- lib/data/area.js | 4 +- lib/data/area.prod.d.ts | 2 +- lib/data/area.prod.js | 3 +- lib/data/i18n.d.ts | 3 + lib/data/i18n.js | 303 +++++++++++++++++++++++++++ lib/data/index.d.ts | 24 +-- lib/data/index.js | 21 +- lib/data/station.d.ts | 3 +- lib/data/station.js | 4 +- lib/data/subway.d.ts | 3 +- lib/data/subway.js | 4 +- lib/data/subwayStation.d.ts | 3 +- lib/data/subwayStation.js | 4 +- lib/locales/Common/zh_CN.json | 39 ++++ scripts/buildLocale.ts | 2 +- src/components/article/cell/index.ts | 2 +- src/data/actionAuth.ts | 6 +- src/data/area.dev.ts | 4 +- src/data/area.prod.ts | 4 +- src/data/area.ts | 4 +- src/data/i18n.ts | 302 ++++++++++++++++++++++++++ src/data/index.ts | 10 +- src/data/station.ts | 4 +- src/data/subway.ts | 4 +- src/data/subwayStation.ts | 4 +- src/locales/Common/zh_CN.json | 39 ++++ test/test.ts | 268 ++++++++++++++++++++++- 32 files changed, 1002 insertions(+), 86 deletions(-) create mode 100644 lib/data/i18n.d.ts create mode 100644 lib/data/i18n.js create mode 100644 lib/locales/Common/zh_CN.json create mode 100644 src/data/i18n.ts create mode 100644 src/locales/Common/zh_CN.json diff --git a/lib/data/actionAuth.d.ts b/lib/data/actionAuth.d.ts index 85648b570..41f922ecb 100644 --- a/lib/data/actionAuth.d.ts +++ b/lib/data/actionAuth.d.ts @@ -1,2 +1,3 @@ import { CreateOperationData as ActionAuth } from '../oak-app-domain/ActionAuth/Schema'; -export declare const actionAuth: ActionAuth[]; +declare const actionAuths: ActionAuth[]; +export default actionAuths; diff --git a/lib/data/actionAuth.js b/lib/data/actionAuth.js index 5979bfc55..c482eefab 100644 --- a/lib/data/actionAuth.js +++ b/lib/data/actionAuth.js @@ -1,7 +1,6 @@ "use strict"; Object.defineProperty(exports, "__esModule", { value: true }); -exports.actionAuth = void 0; -exports.actionAuth = [ +var actionAuths = [ { id: 'message-user', paths: ['user'], @@ -33,3 +32,4 @@ exports.actionAuth = [ deActions: ['create', 'update', 'select'], } ]; +exports.default = actionAuths; diff --git a/lib/data/area.d.ts b/lib/data/area.d.ts index ac85dc690..3e889e1cc 100644 --- a/lib/data/area.d.ts +++ b/lib/data/area.d.ts @@ -1 +1,2 @@ -export { area, } from './area.dev'; +declare const _default: "./area.dev"; +export default _default; diff --git a/lib/data/area.dev.d.ts b/lib/data/area.dev.d.ts index bdd600d4b..972ef5814 100644 --- a/lib/data/area.dev.d.ts +++ b/lib/data/area.dev.d.ts @@ -21,4 +21,4 @@ declare const area: ({ coordinate: number[]; }; })[]; -export { area, }; +export default area; diff --git a/lib/data/area.dev.js b/lib/data/area.dev.js index bbfbe1404..0420a1aa6 100644 --- a/lib/data/area.dev.js +++ b/lib/data/area.dev.js @@ -1,8 +1,7 @@ "use strict"; Object.defineProperty(exports, "__esModule", { value: true }); -exports.area = void 0; var tslib_1 = require("tslib"); // import area2 from './area.json'; var areaDebug_json_1 = tslib_1.__importDefault(require("./areaDebug.json")); var area = areaDebug_json_1.default; -exports.area = area; +exports.default = area; diff --git a/lib/data/area.js b/lib/data/area.js index dccb0ff4a..1958325ac 100644 --- a/lib/data/area.js +++ b/lib/data/area.js @@ -1,6 +1,4 @@ "use strict"; Object.defineProperty(exports, "__esModule", { value: true }); -exports.area = void 0; console.log('走不到这里'); -var area_dev_1 = require("./area.dev"); -Object.defineProperty(exports, "area", { enumerable: true, get: function () { return area_dev_1.area; } }); +exports.default = './area.dev'; diff --git a/lib/data/area.prod.d.ts b/lib/data/area.prod.d.ts index fd0e3517d..68dcb9f01 100644 --- a/lib/data/area.prod.d.ts +++ b/lib/data/area.prod.d.ts @@ -1,3 +1,3 @@ import { CreateOperationData } from '../oak-app-domain/Area/Schema'; declare const area: CreateOperationData[]; -export { area, }; +export default area; diff --git a/lib/data/area.prod.js b/lib/data/area.prod.js index 706c97914..648d2a1f0 100644 --- a/lib/data/area.prod.js +++ b/lib/data/area.prod.js @@ -1,5 +1,4 @@ "use strict"; Object.defineProperty(exports, "__esModule", { value: true }); -exports.area = void 0; var area = []; -exports.area = area; +exports.default = area; diff --git a/lib/data/i18n.d.ts b/lib/data/i18n.d.ts new file mode 100644 index 000000000..670e1e3ae --- /dev/null +++ b/lib/data/i18n.d.ts @@ -0,0 +1,3 @@ +import { CreateOperationData as I18n } from "../oak-app-domain/I18n/Schema"; +declare const i18ns: I18n[]; +export default i18ns; diff --git a/lib/data/i18n.js b/lib/data/i18n.js new file mode 100644 index 000000000..821304ada --- /dev/null +++ b/lib/data/i18n.js @@ -0,0 +1,303 @@ +"use strict"; +Object.defineProperty(exports, "__esModule", { value: true }); +var i18ns = [ + { + id: "0847fcee-2c29-43bc-a99d-8553d2fc0037", + namespace: "oak-general-business-p-mobile-login", + language: "zh_CN", + module: "oak-general-business", + position: "pages\\mobile\\login", + data: { + "Login": "确定", + "Send": "发送验证码", + "placeholder": { + "Captcha": "输入4位短信验证码", + "Mobile": "请输入手机号" + } + } + }, + { + id: "cc42fad1-0bc3-4762-9f13-73a3a6a140a2", + namespace: "oak-general-business-p-paper-detail", + language: "zh_CN", + module: "oak-general-business", + position: "pages\\paper\\detail", + data: { + "detail": "详情" + } + }, + { + id: "ad39d7e6-183b-43de-8cf3-ee388260035c", + namespace: "oak-general-business-p-paper-list", + language: "zh_CN", + module: "oak-general-business", + position: "pages\\paper\\list", + data: { + "action": { + "add": "添加" + } + } + }, + { + id: "1ceaa1a2-91f4-48a2-b9f7-045ef7c22bc4", + namespace: "oak-general-business-p-paper-preview", + language: "zh_CN", + module: "oak-general-business", + position: "pages\\paper\\preview", + data: { + "detail": "预览" + } + }, + { + id: "ad1b09c9-337e-4d01-b170-dea2f684024d", + namespace: "oak-general-business-p-paper-upsert", + language: "zh_CN", + module: "oak-general-business", + position: "pages\\paper\\upsert", + data: { + "submit": "提交", + "reset": "重置", + "placeholder": { + "author": "请输入作者", + "title": "请在这里输入标题", + "content": "从这里开始正文", + "abstract": "选填,摘要会在订阅号消息、转发链接等文章外的场景显露,帮助读者快速了解内容,如不填写则默认抓取正文前54字" + }, + "tips": { + "content": "请先输入一段正文(或者标题),再点击保存按钮。" + } + } + }, + { + id: "e0c24a1a-1f9d-4513-a7ea-de4889f320cc", + namespace: "oak-general-business-p-token-me", + language: "zh_CN", + module: "oak-general-business", + position: "pages\\token\\me", + data: { + "login": "登录", + "syncWeChat": "同步微信信息" + } + }, + { + id: "76a965c5-40bb-45e3-ac89-58caa0e56d5b", + namespace: "oak-general-business-p-user-info", + language: "zh_CN", + module: "oak-general-business", + position: "pages\\user\\info", + data: { + "avatar": "头像", + "mobile": "手机号", + "manage": "管理", + "bind": "绑定", + "syncWeChat": "同步微信信息", + "send": "发送验证码", + "cancel": "取消", + "unbind": "解绑", + "Mobile-Number-Verification": "手机号验证", + "unbindingWechat": "确定解绑微信账号", + "placeholder": { + "Captcha": "输入4位短信验证码" + } + } + }, + { + id: "4052589d-c5f3-4154-81c7-ae087ac565f4", + namespace: "oak-general-business-p-user-manage-detail", + language: "zh_CN", + module: "oak-general-business", + position: "pages\\user\\manage\\detail", + data: { + "mobile": "手机号", + "unset": "未设置" + } + }, + { + id: "cf4134ca-94e6-4cdb-9211-178a7fc6a897", + namespace: "oak-general-business-p-userRelation-list", + language: "zh_CN", + module: "oak-general-business", + position: "pages\\userRelation\\list", + data: { + "confirmRevokeAll": "确认删除用户的所有权限吗?", + "search": "搜索用户名" + } + }, + { + id: "1c012491-4a8c-4d83-9021-fdfb93e7069f", + namespace: "oak-general-business-p-userRelation-upsert-byMobile", + language: "zh_CN", + module: "oak-general-business", + position: "pages\\userRelation\\upsert\\byMobile", + data: { + "inputMobile": "请输入手机号查找" + } + }, + { + id: "6ab6c256-428b-4f1c-bd64-1588b05534fe", + namespace: "oak-general-business-p-userRelation-upsert-byUserEntityGrant", + language: "zh_CN", + module: "oak-general-business", + position: "pages\\userRelation\\upsert\\byUserEntityGrant", + data: { + "single": "单次", + "unlimited": "不限", + "restart": "重新生成", + "chooseNumber": "请选择分享的目标人数", + "chooseExpiresAt": "请选择有效时长", + "expiresHelp": "支持分钟、小时选择", + "shareCode": "请将二维码发给待分享权限的用户使用微信扫描", + "unit": { + "hour": "小时", + "minute": "分钟" + } + } + }, + { + id: "94787da9-99b7-4550-86c1-10fd14d83841", + namespace: "oak-general-business-p-userRelation-upsert-onUser", + language: "zh_CN", + module: "oak-general-business", + position: "pages\\userRelation\\upsert\\onUser", + data: { + "placeholder": { + "name": "请输入姓名", + "password": "密码不少于8位", + "relation": "至少应选择一个权限" + }, + "auth": "权限", + "existedUser": "现有用户", + "newUser": "新建用户" + } + }, + { + id: "15018a30-b711-4cbe-91fa-dd818cfc6403", + namespace: "oak-general-business-c-common-qrCode", + language: "zh_CN", + module: "oak-general-business", + position: "components\\common\\qrCode", + data: { + "weChat-account-successfully-bound": "微信账号绑定成功", + "weChat-authorization-login-successful": "微信授权登录成功" + } + }, + { + id: "88f40686-aa42-443d-9085-7f2036322024", + namespace: "oak-general-business-c-extraFile-forUrl", + language: "zh_CN", + module: "oak-general-business", + position: "components\\extraFile\\forUrl", + data: { + "original": "从原文中选取", + "url": "图片链接", + "uploadLocalImg": "上传本地图片", + "fillInImageLink": "填写图片链接", + "chooseImage": "选择图片" + } + }, + { + id: "5b25a288-7748-450a-9738-909a7957b958", + namespace: "oak-general-business-c-extraFile-gallery", + language: "zh_CN", + module: "oak-general-business", + position: "components\\extraFile\\gallery", + data: { + "waiting": "等待上传", + "success": "上传成功", + "uploading": "上传中" + } + }, + { + id: "cda71e7d-91a4-448e-b5be-8077a17b71f5", + namespace: "oak-general-business-c-my-info", + language: "zh_CN", + module: "oak-general-business", + position: "components\\my\\info", + data: { + "login": "登录/注册", + "unset": "未设置", + "logout": "退出", + "mobile": "手机号码", + "moreThanOne": "多于一条手机号" + } + }, + { + id: "df071449-3850-416a-a765-dafac92a0616", + namespace: "oak-general-business-c-user-login", + language: "zh_CN", + module: "oak-general-business", + position: "components\\user\\login", + data: { + "Login": "登录", + "Remember me": "记住账号", + "inPassword": "账号登录", + "inCaptcha": "手机号登录", + "inQrCode": "扫码登录", + "Send": "发送验证码", + "placeholder": { + "Captcha": "输入4位短信验证码", + "Mobile": "请输入手机号", + "Password": "请输入密码" + }, + "resendAfter": "秒后可重发" + } + }, + { + id: "a216fa43-f85f-4ff3-800d-b09f650ff5c5", + namespace: "oak-general-business-c-wechatUser-unbindBtn", + language: "zh_CN", + module: "oak-general-business", + position: "components\\wechatUser\\unbindBtn", + data: { + "unbind": "解绑", + "unbindingWechat": "确定解绑该微信账号" + } + }, + { + id: "d740c333-cdb2-4176-bcf5-02a04b52dadc", + namespace: "oak-general-business-l-common", + language: "zh_CN", + module: "oak-general-business", + position: "locales\\common", + data: { + "ptrActivate": "松开刷新", + "ptrDeactivate": "下拉刷新", + "ptrRelease": "正在刷新...", + "ptrFinish": "刷新完成", + "noData": "暂无数据", + "areYouSure": "请确认", + "action": { + "create": "创建", + "update": "更新", + "delete": "删除", + "remove": "删除", + "confirm": "确定", + "cancel": "取消", + "grant": "授权", + "revoke": "回收", + "tip": "提示", + "detail": "详情", + "editor": "编辑", + "newAdd": "新增", + "add": "添加" + }, + "reset": "重置", + "select": "查询", + "expand": "展开", + "shrink": "收起", + "back": "返回", + "$$createAt$$": "创建时间", + "$$updateAt$$": "更新时间", + "$$deleteAt$$": "删除时间", + "$$seq$$": "序号", + "message": "消息", + "more": "更多", + "view": "查看", + "scan": "扫一扫", + "bind": "绑定", + "true": "是", + "false": "否" + } + } +]; +exports.default = i18ns; diff --git a/lib/data/index.d.ts b/lib/data/index.d.ts index ad5e73ec7..f9758e914 100644 --- a/lib/data/index.d.ts +++ b/lib/data/index.d.ts @@ -2,29 +2,7 @@ declare const _default: { user: import("../oak-app-domain/User/Schema").CreateOperationData[]; mobile: import("../oak-app-domain/Mobile/Schema").CreateOperationData[]; token: import("../oak-app-domain/Token/Schema").CreateOperationData[]; - area: ({ - code: string; - level: string; - parentId: string; - name: string; - depth: number; - id: string; - center: { - type: string; - coordinate: number[]; - }; - } | { - code: string; - level: string; - parentId: null; - name: string; - depth: number; - id: string; - center: { - type: string; - coordinate: number[]; - }; - })[]; + area: string; subway: import("../oak-app-domain/Subway/Schema").CreateOperationData[]; station: import("../oak-app-domain/Station/Schema").CreateOperationData[]; subwayStation: import("../oak-app-domain/SubwayStation/Schema").CreateOperationData[]; diff --git a/lib/data/index.js b/lib/data/index.js index 394b3c0de..f9be171ca 100644 --- a/lib/data/index.js +++ b/lib/data/index.js @@ -1,18 +1,19 @@ "use strict"; Object.defineProperty(exports, "__esModule", { value: true }); +var tslib_1 = require("tslib"); var userRole_1 = require("./userRole"); -var area_1 = require("./area"); -var subway_1 = require("./subway"); -var station_1 = require("./station"); -var subwayStation_1 = require("./subwayStation"); -var actionAuth_1 = require("./actionAuth"); +var area_1 = tslib_1.__importDefault(require("./area")); +var subway_1 = tslib_1.__importDefault(require("./subway")); +var station_1 = tslib_1.__importDefault(require("./station")); +var subwayStation_1 = tslib_1.__importDefault(require("./subwayStation")); +var actionAuth_1 = tslib_1.__importDefault(require("./actionAuth")); exports.default = { user: userRole_1.users, mobile: userRole_1.mobiles, token: userRole_1.tokens, - area: area_1.area, - subway: subway_1.subway, - station: station_1.station, - subwayStation: subwayStation_1.subwayStation, - actionAuth: actionAuth_1.actionAuth, + area: area_1.default, + subway: subway_1.default, + station: station_1.default, + subwayStation: subwayStation_1.default, + actionAuth: actionAuth_1.default, }; diff --git a/lib/data/station.d.ts b/lib/data/station.d.ts index da75f2301..a145c2e90 100644 --- a/lib/data/station.d.ts +++ b/lib/data/station.d.ts @@ -1,2 +1,3 @@ import { CreateOperationData as Station } from '../oak-app-domain/Station/Schema'; -export declare const station: Station[]; +declare const station: Station[]; +export default station; diff --git a/lib/data/station.js b/lib/data/station.js index 9b5ad8e54..5bf8634ee 100644 --- a/lib/data/station.js +++ b/lib/data/station.js @@ -1,7 +1,6 @@ "use strict"; Object.defineProperty(exports, "__esModule", { value: true }); -exports.station = void 0; -exports.station = [ +var station = [ { id: '330100023133026', name: '湘湖', @@ -1543,3 +1542,4 @@ exports.station = [ areaId: '330300', }, ]; +exports.default = station; diff --git a/lib/data/subway.d.ts b/lib/data/subway.d.ts index 366694de9..25ea07cbe 100644 --- a/lib/data/subway.d.ts +++ b/lib/data/subway.d.ts @@ -1,2 +1,3 @@ import { CreateOperationData as Subway } from '../oak-app-domain/Subway/Schema'; -export declare const subway: Subway[]; +declare const subway: Subway[]; +export default subway; diff --git a/lib/data/subway.js b/lib/data/subway.js index 35315d7d0..d077b3c02 100644 --- a/lib/data/subway.js +++ b/lib/data/subway.js @@ -1,7 +1,6 @@ "use strict"; Object.defineProperty(exports, "__esModule", { value: true }); -exports.subway = void 0; -exports.subway = [ +var subway = [ { id: '330100023133', name: '1号线', @@ -78,3 +77,4 @@ exports.subway = [ areaId: '330300', }, ]; +exports.default = subway; diff --git a/lib/data/subwayStation.d.ts b/lib/data/subwayStation.d.ts index 272404d27..50ff05d25 100644 --- a/lib/data/subwayStation.d.ts +++ b/lib/data/subwayStation.d.ts @@ -1,2 +1,3 @@ import { CreateOperationData as SubwayStation } from '../oak-app-domain/SubwayStation/Schema'; -export declare const subwayStation: SubwayStation[]; +declare const subwayStation: SubwayStation[]; +export default subwayStation; diff --git a/lib/data/subwayStation.js b/lib/data/subwayStation.js index f67b5088c..14f7c2968 100644 --- a/lib/data/subwayStation.js +++ b/lib/data/subwayStation.js @@ -1,7 +1,6 @@ "use strict"; Object.defineProperty(exports, "__esModule", { value: true }); -exports.subwayStation = void 0; -exports.subwayStation = [ +var subwayStation = [ { id: '26246383-c8a1-4ce4-8d17-5cbe34e6c001', stationId: '330100023133026', @@ -1793,3 +1792,4 @@ exports.subwayStation = [ subwayId: '900000109349', }, ]; +exports.default = subwayStation; diff --git a/lib/locales/Common/zh_CN.json b/lib/locales/Common/zh_CN.json new file mode 100644 index 000000000..5cbbd3c49 --- /dev/null +++ b/lib/locales/Common/zh_CN.json @@ -0,0 +1,39 @@ +{ + "ptrActivate": "松开刷新", + "ptrDeactivate": "下拉刷新", + "ptrRelease": "正在刷新...", + "ptrFinish": "刷新完成", + "noData": "暂无数据", + "areYouSure": "请确认", + "action": { + "create": "创建", + "update": "更新", + "delete": "删除", + "remove": "删除", + "confirm": "确定", + "cancel": "取消", + "grant": "授权", + "revoke": "回收", + "tip": "提示", + "detail": "详情", + "editor": "编辑", + "newAdd": "新增", + "add": "添加" + }, + "reset": "重置", + "select": "查询", + "expand": "展开", + "shrink": "收起", + "back": "返回", + "$$createAt$$": "创建时间", + "$$updateAt$$": "更新时间", + "$$deleteAt$$": "删除时间", + "$$seq$$": "序号", + "message": "消息", + "more": "更多", + "view": "查看", + "scan": "扫一扫", + "bind": "绑定", + "true": "是", + "false": "否" +} diff --git a/scripts/buildLocale.ts b/scripts/buildLocale.ts index b0446e841..1406c76b5 100644 --- a/scripts/buildLocale.ts +++ b/scripts/buildLocale.ts @@ -1,4 +1,4 @@ -import LocaleBuilder from 'oak-domain/src/compiler/localeBuilder'; +import LocaleBuilder from 'oak-domain/lib/compiler/localeBuilder'; const localeBuilder = new LocaleBuilder(true); localeBuilder.build(); \ No newline at end of file diff --git a/src/components/article/cell/index.ts b/src/components/article/cell/index.ts index a1ead208c..ddd23189b 100644 --- a/src/components/article/cell/index.ts +++ b/src/components/article/cell/index.ts @@ -17,7 +17,7 @@ export default OakComponent({ content: '', name: '', }, - formData: function ({ data: article }) { + formData({ data: article }) { return { content: article?.content, name: article?.name, diff --git a/src/data/actionAuth.ts b/src/data/actionAuth.ts index d2755584f..808f70245 100644 --- a/src/data/actionAuth.ts +++ b/src/data/actionAuth.ts @@ -1,6 +1,6 @@ import { CreateOperationData as ActionAuth } from '../oak-app-domain/ActionAuth/Schema'; -export const actionAuth: ActionAuth[] = [ +const actionAuths: ActionAuth[] = [ { id: 'message-user', paths: ['user'], @@ -31,4 +31,6 @@ export const actionAuth: ActionAuth[] = [ destEntity: 'wechatUser', deActions: ['create', 'update', 'select'], } -]; \ No newline at end of file +]; + +export default actionAuths; \ No newline at end of file diff --git a/src/data/area.dev.ts b/src/data/area.dev.ts index b567d8255..e90a322eb 100644 --- a/src/data/area.dev.ts +++ b/src/data/area.dev.ts @@ -2,6 +2,4 @@ import area_debug from './areaDebug.json'; const area = area_debug; -export { - area, -}; \ No newline at end of file +export default area; \ No newline at end of file diff --git a/src/data/area.prod.ts b/src/data/area.prod.ts index b0fee8f4e..e946e1e32 100644 --- a/src/data/area.prod.ts +++ b/src/data/area.prod.ts @@ -1,5 +1,3 @@ import { CreateOperationData } from '../oak-app-domain/Area/Schema'; const area = [] as CreateOperationData[]; -export { - area, -}; \ No newline at end of file +export default area; \ No newline at end of file diff --git a/src/data/area.ts b/src/data/area.ts index cdfaf19db..e429bfecb 100644 --- a/src/data/area.ts +++ b/src/data/area.ts @@ -1,4 +1,2 @@ console.log('走不到这里'); -export { - area, -} from './area.dev'; \ No newline at end of file +export default './area.dev'; \ No newline at end of file diff --git a/src/data/i18n.ts b/src/data/i18n.ts new file mode 100644 index 000000000..41745e526 --- /dev/null +++ b/src/data/i18n.ts @@ -0,0 +1,302 @@ +import { CreateOperationData as I18n } from "../oak-app-domain/I18n/Schema"; +const i18ns: I18n[] = [ + { + id: "0847fcee-2c29-43bc-a99d-8553d2fc0037", + namespace: "oak-general-business-p-mobile-login", + language: "zh_CN", + module: "oak-general-business", + position: "pages\\mobile\\login", + data: { + "Login": "确定", + "Send": "发送验证码", + "placeholder": { + "Captcha": "输入4位短信验证码", + "Mobile": "请输入手机号" + } + } + }, + { + id: "cc42fad1-0bc3-4762-9f13-73a3a6a140a2", + namespace: "oak-general-business-p-paper-detail", + language: "zh_CN", + module: "oak-general-business", + position: "pages\\paper\\detail", + data: { + "detail": "详情" + } + }, + { + id: "ad39d7e6-183b-43de-8cf3-ee388260035c", + namespace: "oak-general-business-p-paper-list", + language: "zh_CN", + module: "oak-general-business", + position: "pages\\paper\\list", + data: { + "action": { + "add": "添加" + } + } + }, + { + id: "1ceaa1a2-91f4-48a2-b9f7-045ef7c22bc4", + namespace: "oak-general-business-p-paper-preview", + language: "zh_CN", + module: "oak-general-business", + position: "pages\\paper\\preview", + data: { + "detail": "预览" + } + }, + { + id: "ad1b09c9-337e-4d01-b170-dea2f684024d", + namespace: "oak-general-business-p-paper-upsert", + language: "zh_CN", + module: "oak-general-business", + position: "pages\\paper\\upsert", + data: { + "submit": "提交", + "reset": "重置", + "placeholder": { + "author": "请输入作者", + "title": "请在这里输入标题", + "content": "从这里开始正文", + "abstract": "选填,摘要会在订阅号消息、转发链接等文章外的场景显露,帮助读者快速了解内容,如不填写则默认抓取正文前54字" + }, + "tips": { + "content": "请先输入一段正文(或者标题),再点击保存按钮。" + } + } + }, + { + id: "e0c24a1a-1f9d-4513-a7ea-de4889f320cc", + namespace: "oak-general-business-p-token-me", + language: "zh_CN", + module: "oak-general-business", + position: "pages\\token\\me", + data: { + "login": "登录", + "syncWeChat": "同步微信信息" + } + }, + { + id: "76a965c5-40bb-45e3-ac89-58caa0e56d5b", + namespace: "oak-general-business-p-user-info", + language: "zh_CN", + module: "oak-general-business", + position: "pages\\user\\info", + data: { + "avatar": "头像", + "mobile": "手机号", + "manage": "管理", + "bind": "绑定", + "syncWeChat": "同步微信信息", + "send": "发送验证码", + "cancel": "取消", + "unbind": "解绑", + "Mobile-Number-Verification": "手机号验证", + "unbindingWechat": "确定解绑微信账号", + "placeholder": { + "Captcha": "输入4位短信验证码" + } + } + }, + { + id: "4052589d-c5f3-4154-81c7-ae087ac565f4", + namespace: "oak-general-business-p-user-manage-detail", + language: "zh_CN", + module: "oak-general-business", + position: "pages\\user\\manage\\detail", + data: { + "mobile": "手机号", + "unset": "未设置" + } + }, + { + id: "cf4134ca-94e6-4cdb-9211-178a7fc6a897", + namespace: "oak-general-business-p-userRelation-list", + language: "zh_CN", + module: "oak-general-business", + position: "pages\\userRelation\\list", + data: { + "confirmRevokeAll": "确认删除用户的所有权限吗?", + "search": "搜索用户名" + } + }, + { + id: "1c012491-4a8c-4d83-9021-fdfb93e7069f", + namespace: "oak-general-business-p-userRelation-upsert-byMobile", + language: "zh_CN", + module: "oak-general-business", + position: "pages\\userRelation\\upsert\\byMobile", + data: { + "inputMobile": "请输入手机号查找" + } + }, + { + id: "6ab6c256-428b-4f1c-bd64-1588b05534fe", + namespace: "oak-general-business-p-userRelation-upsert-byUserEntityGrant", + language: "zh_CN", + module: "oak-general-business", + position: "pages\\userRelation\\upsert\\byUserEntityGrant", + data: { + "single": "单次", + "unlimited": "不限", + "restart": "重新生成", + "chooseNumber": "请选择分享的目标人数", + "chooseExpiresAt": "请选择有效时长", + "expiresHelp": "支持分钟、小时选择", + "shareCode": "请将二维码发给待分享权限的用户使用微信扫描", + "unit": { + "hour": "小时", + "minute": "分钟" + } + } + }, + { + id: "94787da9-99b7-4550-86c1-10fd14d83841", + namespace: "oak-general-business-p-userRelation-upsert-onUser", + language: "zh_CN", + module: "oak-general-business", + position: "pages\\userRelation\\upsert\\onUser", + data: { + "placeholder": { + "name": "请输入姓名", + "password": "密码不少于8位", + "relation": "至少应选择一个权限" + }, + "auth": "权限", + "existedUser": "现有用户", + "newUser": "新建用户" + } + }, + { + id: "15018a30-b711-4cbe-91fa-dd818cfc6403", + namespace: "oak-general-business-c-common-qrCode", + language: "zh_CN", + module: "oak-general-business", + position: "components\\common\\qrCode", + data: { + "weChat-account-successfully-bound": "微信账号绑定成功", + "weChat-authorization-login-successful": "微信授权登录成功" + } + }, + { + id: "88f40686-aa42-443d-9085-7f2036322024", + namespace: "oak-general-business-c-extraFile-forUrl", + language: "zh_CN", + module: "oak-general-business", + position: "components\\extraFile\\forUrl", + data: { + "original": "从原文中选取", + "url": "图片链接", + "uploadLocalImg": "上传本地图片", + "fillInImageLink": "填写图片链接", + "chooseImage": "选择图片" + } + }, + { + id: "5b25a288-7748-450a-9738-909a7957b958", + namespace: "oak-general-business-c-extraFile-gallery", + language: "zh_CN", + module: "oak-general-business", + position: "components\\extraFile\\gallery", + data: { + "waiting": "等待上传", + "success": "上传成功", + "uploading": "上传中" + } + }, + { + id: "cda71e7d-91a4-448e-b5be-8077a17b71f5", + namespace: "oak-general-business-c-my-info", + language: "zh_CN", + module: "oak-general-business", + position: "components\\my\\info", + data: { + "login": "登录/注册", + "unset": "未设置", + "logout": "退出", + "mobile": "手机号码", + "moreThanOne": "多于一条手机号" + } + }, + { + id: "df071449-3850-416a-a765-dafac92a0616", + namespace: "oak-general-business-c-user-login", + language: "zh_CN", + module: "oak-general-business", + position: "components\\user\\login", + data: { + "Login": "登录", + "Remember me": "记住账号", + "inPassword": "账号登录", + "inCaptcha": "手机号登录", + "inQrCode": "扫码登录", + "Send": "发送验证码", + "placeholder": { + "Captcha": "输入4位短信验证码", + "Mobile": "请输入手机号", + "Password": "请输入密码" + }, + "resendAfter": "秒后可重发" + } + }, + { + id: "a216fa43-f85f-4ff3-800d-b09f650ff5c5", + namespace: "oak-general-business-c-wechatUser-unbindBtn", + language: "zh_CN", + module: "oak-general-business", + position: "components\\wechatUser\\unbindBtn", + data: { + "unbind": "解绑", + "unbindingWechat": "确定解绑该微信账号" + } + }, + { + id: "d740c333-cdb2-4176-bcf5-02a04b52dadc", + namespace: "oak-general-business-l-common", + language: "zh_CN", + module: "oak-general-business", + position: "locales\\common", + data: { + "ptrActivate": "松开刷新", + "ptrDeactivate": "下拉刷新", + "ptrRelease": "正在刷新...", + "ptrFinish": "刷新完成", + "noData": "暂无数据", + "areYouSure": "请确认", + "action": { + "create": "创建", + "update": "更新", + "delete": "删除", + "remove": "删除", + "confirm": "确定", + "cancel": "取消", + "grant": "授权", + "revoke": "回收", + "tip": "提示", + "detail": "详情", + "editor": "编辑", + "newAdd": "新增", + "add": "添加" + }, + "reset": "重置", + "select": "查询", + "expand": "展开", + "shrink": "收起", + "back": "返回", + "$$createAt$$": "创建时间", + "$$updateAt$$": "更新时间", + "$$deleteAt$$": "删除时间", + "$$seq$$": "序号", + "message": "消息", + "more": "更多", + "view": "查看", + "scan": "扫一扫", + "bind": "绑定", + "true": "是", + "false": "否" + } + } +]; +export default i18ns; \ No newline at end of file diff --git a/src/data/index.ts b/src/data/index.ts index 668bfcf7d..90e0fccf9 100644 --- a/src/data/index.ts +++ b/src/data/index.ts @@ -1,9 +1,9 @@ import { users, mobiles, tokens } from "./userRole"; -import { area } from "./area"; -import { subway } from "./subway"; -import { station } from "./station"; -import { subwayStation } from "./subwayStation"; -import { actionAuth } from './actionAuth'; +import area from "./area"; +import subway from "./subway"; +import station from "./station"; +import subwayStation from "./subwayStation"; +import actionAuth from './actionAuth'; export default { user: users, diff --git a/src/data/station.ts b/src/data/station.ts index a1237528b..ce31eeee5 100644 --- a/src/data/station.ts +++ b/src/data/station.ts @@ -1,5 +1,5 @@ import { CreateOperationData as Station } from '../oak-app-domain/Station/Schema'; -export const station: Station[] = [ +const station: Station[] = [ { id: '330100023133026', name: '湘湖', @@ -1541,3 +1541,5 @@ export const station: Station[] = [ areaId: '330300', }, ]; + +export default station; \ No newline at end of file diff --git a/src/data/subway.ts b/src/data/subway.ts index 8b01aa7e6..c3d3f6a01 100644 --- a/src/data/subway.ts +++ b/src/data/subway.ts @@ -1,5 +1,5 @@ import { CreateOperationData as Subway } from '../oak-app-domain/Subway/Schema'; -export const subway: Subway[] = [ +const subway: Subway[] = [ { id: '330100023133', name: '1号线', @@ -76,3 +76,5 @@ export const subway: Subway[] = [ areaId: '330300', }, ]; + +export default subway; \ No newline at end of file diff --git a/src/data/subwayStation.ts b/src/data/subwayStation.ts index 80cbc8db2..ecf3be2c2 100644 --- a/src/data/subwayStation.ts +++ b/src/data/subwayStation.ts @@ -1,5 +1,5 @@ import { CreateOperationData as SubwayStation } from '../oak-app-domain/SubwayStation/Schema'; -export const subwayStation: SubwayStation[] = [ +const subwayStation: SubwayStation[] = [ { id: '26246383-c8a1-4ce4-8d17-5cbe34e6c001', stationId: '330100023133026', @@ -1791,3 +1791,5 @@ export const subwayStation: SubwayStation[] = [ subwayId: '900000109349', }, ]; + +export default subwayStation; \ No newline at end of file diff --git a/src/locales/Common/zh_CN.json b/src/locales/Common/zh_CN.json new file mode 100644 index 000000000..e1a8b103e --- /dev/null +++ b/src/locales/Common/zh_CN.json @@ -0,0 +1,39 @@ +{ + "ptrActivate": "松开刷新", + "ptrDeactivate": "下拉刷新", + "ptrRelease": "正在刷新...", + "ptrFinish": "刷新完成", + "noData": "暂无数据", + "areYouSure": "请确认", + "action": { + "create": "创建", + "update": "更新", + "delete": "删除", + "remove": "删除", + "confirm": "确定", + "cancel": "取消", + "grant": "授权", + "revoke": "回收", + "tip": "提示", + "detail": "详情", + "editor": "编辑", + "newAdd": "新增", + "add": "添加" + }, + "reset": "重置", + "select": "查询", + "expand": "展开", + "shrink": "收起", + "back": "返回", + "$$createAt$$": "创建时间", + "$$updateAt$$": "更新时间", + "$$deleteAt$$": "删除时间", + "$$seq$$": "序号", + "message": "消息", + "more": "更多", + "view": "查看", + "scan": "扫一扫", + "bind": "绑定", + "true": "是", + "false": "否" +} diff --git a/test/test.ts b/test/test.ts index b49a2847b..3a61eb804 100644 --- a/test/test.ts +++ b/test/test.ts @@ -1,10 +1,258 @@ -import { EntityDict } from 'oak-domain/lib/types/Entity'; -import { EntityDict as BaseEntityDict } from 'oak-domain/lib/base-app-domain'; -import { EntityDict as GeneralEntityDict } from '../src/general-app-domain'; - -type TT = ED; - -type T = TT; - -type UA = Exclude<'create' | 'update', 'create'>; -const ua: UA = 'create'; \ No newline at end of file +const a = `import { CreateOperationData as I18n } from "../oak-app-domain/I18n/Schema"; +const i18ns: I18n[] = [ + { + id: "8a21419f-2bf5-4050-aee2-571f0c1070f1", + namespace: "oak-general-business-p-mobile-login", + language: "zh_CN", + module: "oak-general-business", + position: "D:\\git\\oak-general-business\\src\\pages\\mobile\\login\\locales\\zh_CN.json", + data: { + "Login": "\u786E\u5B9A", + "Send": "\u53D1\u9001\u9A8C\u8BC1\u7801", + "placeholder": { + "Captcha": "\u8F93\u51654\u4F4D\u77ED\u4FE1\u9A8C\u8BC1\u7801", + "Mobile": "\u8BF7\u8F93\u5165\u624B\u673A\u53F7" + } + } + }, + { + id: "5051b1c9-daaf-44a3-8a6a-3153b64fa259", + namespace: "oak-general-business-p-paper-detail", + language: "zh_CN", + module: "oak-general-business", + position: "D:\\git\\oak-general-business\\src\\pages\\paper\\detail\\locales\\zh_CN.json", + data: { + "detail": "\u8BE6\u60C5" + } + }, + { + id: "2322a013-f94f-4fa7-a5a6-7d69f09d63ca", + namespace: "oak-general-business-p-paper-list", + language: "zh_CN", + module: "oak-general-business", + position: "D:\\git\\oak-general-business\\src\\pages\\paper\\list\\locales\\zh_CN.json", + data: { + "action": { + "add": "\u6DFB\u52A0" + } + } + }, + { + id: "51bb1252-6a76-45ed-93a1-014f1909374c", + namespace: "oak-general-business-p-paper-preview", + language: "zh_CN", + module: "oak-general-business", + position: "D:\\git\\oak-general-business\\src\\pages\\paper\\preview\\locales\\zh_CN.json", + data: { + "detail": "\u9884\u89C8" + } + }, + { + id: "d775a296-848f-4549-93fd-1fcd25e7dea9", + namespace: "oak-general-business-p-paper-upsert", + language: "zh_CN", + module: "oak-general-business", + position: "D:\\git\\oak-general-business\\src\\pages\\paper\\upsert\\locales\\zh_CN.json", + data: { + "submit": "\u63D0\u4EA4", + "reset": "\u91CD\u7F6E", + "placeholder": { + "author": "\u8BF7\u8F93\u5165\u4F5C\u8005", + "title": "\u8BF7\u5728\u8FD9\u91CC\u8F93\u5165\u6807\u9898", + "content": "\u4ECE\u8FD9\u91CC\u5F00\u59CB\u6B63\u6587", + "abstract": "\u9009\u586B\uFF0C\u6458\u8981\u4F1A\u5728\u8BA2\u9605\u53F7\u6D88\u606F\u3001\u8F6C\u53D1\u94FE\u63A5\u7B49\u6587\u7AE0\u5916\u7684\u573A\u666F\u663E\u9732\uFF0C\u5E2E\u52A9\u8BFB\u8005\u5FEB\u901F\u4E86\u89E3\u5185\u5BB9\uFF0C\u5982\u4E0D\u586B\u5199\u5219\u9ED8\u8BA4\u6293\u53D6\u6B63\u6587\u524D54\u5B57" + }, + "tips": { + "content": "\u8BF7\u5148\u8F93\u5165\u4E00\u6BB5\u6B63\u6587\uFF08\u6216\u8005\u6807\u9898\uFF09\uFF0C\u518D\u70B9\u51FB\u4FDD\u5B58\u6309\u94AE\u3002" + } + } + }, + { + id: "d50994be-f285-4305-af75-b384270620e9", + namespace: "oak-general-business-p-token-me", + language: "zh_CN", + module: "oak-general-business", + position: "D:\\git\\oak-general-business\\src\\pages\\token\\me\\locales\\zh_CN.json", + data: { + "login": "\u767B\u5F55", + "syncWeChat": "\u540C\u6B65\u5FAE\u4FE1\u4FE1\u606F" + } + }, + { + id: "249b0a44-72d6-4d91-b166-fb6329a922ce", + namespace: "oak-general-business-p-user-info", + language: "zh_CN", + module: "oak-general-business", + position: "D:\\git\\oak-general-business\\src\\pages\\user\\info\\locales\\zh_CN.json", + data: { + "avatar": "\u5934\u50CF", + "mobile": "\u624B\u673A\u53F7", + "manage": "\u7BA1\u7406", + "bind": "\u7ED1\u5B9A", + "syncWeChat": "\u540C\u6B65\u5FAE\u4FE1\u4FE1\u606F", + "send": "\u53D1\u9001\u9A8C\u8BC1\u7801", + "cancel": "\u53D6\u6D88", + "unbind": "\u89E3\u7ED1", + "Mobile-Number-Verification": "\u624B\u673A\u53F7\u9A8C\u8BC1", + "unbindingWechat": "\u786E\u5B9A\u89E3\u7ED1\u5FAE\u4FE1\u8D26\u53F7", + "placeholder": { + "Captcha": "\u8F93\u51654\u4F4D\u77ED\u4FE1\u9A8C\u8BC1\u7801" + } + } + }, + { + id: "f2fa45ea-31a0-4c5c-a9a7-b6c09c08fbf9", + namespace: "oak-general-business-p-user-manage-detail", + language: "zh_CN", + module: "oak-general-business", + position: "D:\\git\\oak-general-business\\src\\pages\\user\\manage\\detail\\locales\\zh_CN.json", + data: { + "mobile": "\u624B\u673A\u53F7", + "unset": "\u672A\u8BBE\u7F6E" + } + }, + { + id: "82a000b9-2325-45da-a505-0fcf37676273", + namespace: "oak-general-business-p-userRelation-list", + language: "zh_CN", + module: "oak-general-business", + position: "D:\\git\\oak-general-business\\src\\pages\\userRelation\\list\\locales\\zh_CN.json", + data: { + "confirmRevokeAll": "\u786E\u8BA4\u5220\u9664\u7528\u6237\u7684\u6240\u6709\u6743\u9650\u5417\uFF1F", + "search": "\u641C\u7D22\u7528\u6237\u540D" + } + }, + { + id: "c2c47b9c-336a-4422-a1e0-7586ba93a25b", + namespace: "oak-general-business-p-userRelation-upsert-byMobile", + language: "zh_CN", + module: "oak-general-business", + position: "D:\\git\\oak-general-business\\src\\pages\\userRelation\\upsert\\byMobile\\locales\\zh_CN.json", + data: { + "inputMobile": "\u8BF7\u8F93\u5165\u624B\u673A\u53F7\u67E5\u627E" + } + }, + { + id: "ca9da17d-b64b-420a-a757-ecadcf42b66f", + namespace: "oak-general-business-p-userRelation-upsert-byUserEntityGrant", + language: "zh_CN", + module: "oak-general-business", + position: "D:\\git\\oak-general-business\\src\\pages\\userRelation\\upsert\\byUserEntityGrant\\locales\\zh_CN.json", + data: { + "single": "\u5355\u6B21", + "unlimited": "\u4E0D\u9650", + "restart": "\u91CD\u65B0\u751F\u6210", + "chooseNumber": "\u8BF7\u9009\u62E9\u5206\u4EAB\u7684\u76EE\u6807\u4EBA\u6570", + "chooseExpiresAt": "\u8BF7\u9009\u62E9\u6709\u6548\u65F6\u957F", + "expiresHelp": "\u652F\u6301\u5206\u949F\u3001\u5C0F\u65F6\u9009\u62E9", + "shareCode": "\u8BF7\u5C06\u4E8C\u7EF4\u7801\u53D1\u7ED9\u5F85\u5206\u4EAB\u6743\u9650\u7684\u7528\u6237\u4F7F\u7528\u5FAE\u4FE1\u626B\u63CF", + "unit": { + "hour": "\u5C0F\u65F6", + "minute": "\u5206\u949F" + } + } + }, + { + id: "7557e788-a6c3-46b0-90f4-01f0f4132a91", + namespace: "oak-general-business-p-userRelation-upsert-onUser", + language: "zh_CN", + module: "oak-general-business", + position: "D:\\git\\oak-general-business\\src\\pages\\userRelation\\upsert\\onUser\\locales\\zh_CN.json", + data: { + "placeholder": { + "name": "\u8BF7\u8F93\u5165\u59D3\u540D", + "password": "\u5BC6\u7801\u4E0D\u5C11\u4E8E8\u4F4D", + "relation": "\u81F3\u5C11\u5E94\u9009\u62E9\u4E00\u4E2A\u6743\u9650" + }, + "auth": "\u6743\u9650", + "existedUser": "\u73B0\u6709\u7528\u6237", + "newUser": "\u65B0\u5EFA\u7528\u6237" + } + }, + { + id: "41be2a40-0ee6-44fe-a587-bdd1e23bf936", + namespace: "oak-general-business-c-common-qrCode", + language: "zh_CN", + module: "oak-general-business", + position: "D:\\git\\oak-general-business\\src\\components\\common\\qrCode\\locales\\zh_CN.json", + data: { + "weChat-account-successfully-bound": "\u5FAE\u4FE1\u8D26\u53F7\u7ED1\u5B9A\u6210\u529F", + "weChat-authorization-login-successful": "\u5FAE\u4FE1\u6388\u6743\u767B\u5F55\u6210\u529F" + } + }, + { + id: "f3d7d7dc-11cc-4319-80d2-d3ace3287d2e", + namespace: "oak-general-business-c-extraFile-forUrl", + language: "zh_CN", + module: "oak-general-business", + position: "D:\\git\\oak-general-business\\src\\components\\extraFile\\forUrl\\locales\\zh_CN.json", + data: { + "original": "\u4ECE\u539F\u6587\u4E2D\u9009\u53D6", + "url": "\u56FE\u7247\u94FE\u63A5", + "uploadLocalImg": "\u4E0A\u4F20\u672C\u5730\u56FE\u7247", + "fillInImageLink": "\u586B\u5199\u56FE\u7247\u94FE\u63A5", + "chooseImage": "\u9009\u62E9\u56FE\u7247" + } + }, + { + id: "0af8fea9-594f-45ca-a4aa-744757c9cc18", + namespace: "oak-general-business-c-extraFile-gallery", + language: "zh_CN", + module: "oak-general-business", + position: "D:\\git\\oak-general-business\\src\\components\\extraFile\\gallery\\locales\\zh_CN.json", + data: { + "waiting": "\u7B49\u5F85\u4E0A\u4F20", + "success": "\u4E0A\u4F20\u6210\u529F", + "uploading": "\u4E0A\u4F20\u4E2D" + } + }, + { + id: "a7bb9ba7-7614-4b26-bec4-7d6bac08d7d6", + namespace: "oak-general-business-c-my-info", + language: "zh_CN", + module: "oak-general-business", + position: "D:\\git\\oak-general-business\\src\\components\\my\\info\\locales\\zh_CN.json", + data: { + "login": "\u767B\u5F55/\u6CE8\u518C", + "unset": "\u672A\u8BBE\u7F6E", + "logout": "\u9000\u51FA", + "mobile": "\u624B\u673A\u53F7\u7801", + "moreThanOne": "\u591A\u4E8E\u4E00\u6761\u624B\u673A\u53F7" + } + }, + { + id: "328d394b-97ba-46e9-a5cd-9e3520f18294", + namespace: "oak-general-business-c-user-login", + language: "zh_CN", + module: "oak-general-business", + position: "D:\\git\\oak-general-business\\src\\components\\user\\login\\locales\\zh_CN.json", + data: { + "Login": "\u767B\u5F55", + "Remember me": "\u8BB0\u4F4F\u8D26\u53F7", + "inPassword": "\u8D26\u53F7\u767B\u5F55", + "inCaptcha": "\u624B\u673A\u53F7\u767B\u5F55", + "inQrCode": "\u626B\u7801\u767B\u5F55", + "Send": "\u53D1\u9001\u9A8C\u8BC1\u7801", + "placeholder": { + "Captcha": "\u8F93\u51654\u4F4D\u77ED\u4FE1\u9A8C\u8BC1\u7801", + "Mobile": "\u8BF7\u8F93\u5165\u624B\u673A\u53F7", + "Password": "\u8BF7\u8F93\u5165\u5BC6\u7801" + }, + "resendAfter": "\u79D2\u540E\u53EF\u91CD\u53D1" + } + }, + { + id: "10e9476b-f32a-4674-a736-b47d616cd5bd", + namespace: "oak-general-business-c-wechatUser-unbindBtn", + language: "zh_CN", + module: "oak-general-business", + position: "D:\\git\\oak-general-business\\src\\components\\wechatUser\\unbindBtn\\locales\\zh_CN.json", + data: { + "unbind": "\u89E3\u7ED1", + "unbindingWechat": "\u786E\u5B9A\u89E3\u7ED1\u8BE5\u5FAE\u4FE1\u8D26\u53F7" + } + } +]; +export default i18ns;`; +const b = unescape(a.replace(/\\u/g, '%u')); +console.log(b); \ No newline at end of file