From 85a85e004766581fa5e8dcc41eae1b6170095afb Mon Sep 17 00:00:00 2001 From: moonrailgun Date: Sun, 16 Jan 2022 20:13:08 +0800 Subject: [PATCH] =?UTF-8?q?feat:=20=E5=A2=9E=E5=8A=A0=E8=8B=B1=E6=96=87?= =?UTF-8?q?=E6=A8=A1=E5=BC=8F=E7=9A=84=E5=96=B5=E8=AF=AD=E7=BF=BB=E8=AF=91?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- pnpm-lock.yaml | 10 +++++----- web/plugins/com.msgbyte.miaolang/package.json | 2 +- web/plugins/com.msgbyte.miaolang/src/miaotrans.ts | 2 ++ 3 files changed, 8 insertions(+), 6 deletions(-) diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index f80fd945..7f9d590f 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -299,9 +299,9 @@ importers: web/plugins/com.msgbyte.miaolang: specifiers: - miao-lang: ^1.0.3 + miao-lang: ^1.0.5 dependencies: - miao-lang: registry.npmmirror.com/miao-lang/1.0.3 + miao-lang: registry.npmmirror.com/miao-lang/1.0.5 web/plugins/com.msgbyte.notify: specifiers: {} @@ -12383,10 +12383,10 @@ packages: yargs-parser: registry.npmmirror.com/yargs-parser/20.2.9 dev: true - registry.npmmirror.com/miao-lang/1.0.3: - resolution: {integrity: sha1-J2mZeI9u7itgDbZqDXKz9TvL1qs=, registry: https://registry.npm.taobao.org/, tarball: https://registry.npmmirror.com/miao-lang/download/miao-lang-1.0.3.tgz} + registry.npmmirror.com/miao-lang/1.0.5: + resolution: {integrity: sha512-aXfDZJ8aXR4fnMkJyJPGWf9gH55odkYNjxPTOlN6N4MH/+2Dt8d4TvM99bjyERG/tG4XprH9Q3bBQEkwKwXrRA==, registry: https://registry.npm.taobao.org/, tarball: https://registry.npmmirror.com/miao-lang/download/miao-lang-1.0.5.tgz} name: miao-lang - version: 1.0.3 + version: 1.0.5 dependencies: js-base64: registry.npmmirror.com/js-base64/3.7.2 dev: false diff --git a/web/plugins/com.msgbyte.miaolang/package.json b/web/plugins/com.msgbyte.miaolang/package.json index 74dfb6ba..3e16278e 100644 --- a/web/plugins/com.msgbyte.miaolang/package.json +++ b/web/plugins/com.msgbyte.miaolang/package.json @@ -4,6 +4,6 @@ "version": "0.0.0", "private": true, "dependencies": { - "miao-lang": "^1.0.3" + "miao-lang": "^1.0.5" } } diff --git a/web/plugins/com.msgbyte.miaolang/src/miaotrans.ts b/web/plugins/com.msgbyte.miaolang/src/miaotrans.ts index 7e83ca07..35d32f30 100644 --- a/web/plugins/com.msgbyte.miaolang/src/miaotrans.ts +++ b/web/plugins/com.msgbyte.miaolang/src/miaotrans.ts @@ -1,9 +1,11 @@ import Miao from 'miao-lang'; import { Translate } from './translate'; +import { getLanguage } from '@capital/common'; export function encode(human: string): string { return Miao.encode(human, { calls: Translate.calls, + halfwidthSymbol: getLanguage() !== 'zh-CN', }); }