From a0efe76c93065b737a38bb9b06c06bcb37613fde Mon Sep 17 00:00:00 2001
From: wangfan <2547096351@qq.com>
Date: Sun, 19 Jan 2025 14:48:00 +0800
Subject: [PATCH] =?UTF-8?q?feat:=20=E6=8B=BC=E9=9F=B3=E8=BD=AC=E6=8D=A2?=
=?UTF-8?q?=E7=BB=84=E4=BB=B6?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
package.json | 1 +
pnpm-lock.yaml | 8 +++
src/components.d.ts | 2 +
src/components/pinyin-pro/index.vue | 56 +++++++++++++++++++
src/lang/modules/enUS.ts | 4 +-
src/lang/modules/zhCN.ts | 4 +-
src/mock/_data/system_menu.ts | 17 ++++++
src/views/component/pinyin/pinyin.vue | 77 +++++++++++++++++++++++++++
8 files changed, 167 insertions(+), 2 deletions(-)
create mode 100644 src/components/pinyin-pro/index.vue
create mode 100644 src/views/component/pinyin/pinyin.vue
diff --git a/package.json b/package.json
index 981b4e8..6a38931 100644
--- a/package.json
+++ b/package.json
@@ -50,6 +50,7 @@
"nprogress": "^0.2.0",
"pinia": "^2.3.0",
"pinia-plugin-persistedstate": "^3.2.1",
+ "pinyin-pro": "^3.26.0",
"print-js": "^1.6.0",
"qrcode": "^1.5.4",
"sortablejs": "^1.15.2",
diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml
index 83c95fc..743a036 100644
--- a/pnpm-lock.yaml
+++ b/pnpm-lock.yaml
@@ -62,6 +62,9 @@ importers:
pinia-plugin-persistedstate:
specifier: ^3.2.1
version: 3.2.1(pinia@2.3.0(typescript@5.4.3)(vue@3.4.21(typescript@5.4.3)))
+ pinyin-pro:
+ specifier: ^3.26.0
+ version: 3.26.0
print-js:
specifier: ^1.6.0
version: 1.6.0
@@ -3272,6 +3275,9 @@ packages:
typescript:
optional: true
+ pinyin-pro@3.26.0:
+ resolution: {integrity: sha512-HcBZZb0pvm0/JkPhZHWA5Hqp2cWHXrrW/WrV+OtaYYM+kf35ffvZppIUuGmyuQ7gDr1JDJKMkbEE+GN0wfMoGg==}
+
pkg-types@1.0.3:
resolution: {integrity: sha512-nN7pYi0AQqJnoLPC9eHFQ8AcyaixBUOwvqc5TDnIKCMEE6I0y8P7OKA7fPexsXGCGxQDl/cmrLAp26LhcwxZ4A==}
@@ -7674,6 +7680,8 @@ snapshots:
transitivePeerDependencies:
- '@vue/composition-api'
+ pinyin-pro@3.26.0: {}
+
pkg-types@1.0.3:
dependencies:
jsonc-parser: 3.2.1
diff --git a/src/components.d.ts b/src/components.d.ts
index cfb0bc8..e8eda05 100644
--- a/src/components.d.ts
+++ b/src/components.d.ts
@@ -9,11 +9,13 @@ declare module 'vue' {
export interface GlobalComponents {
BarcodeDraw: typeof import('./components/barcode-draw/index.vue')['default']
CodeView: typeof import('./components/code-view/index.vue')['default']
+ copy: typeof import('./components/pinyin-pro/index copy.vue')['default']
ExternalLinkPage: typeof import('./components/external-link-page/index.vue')['default']
FillPage: typeof import('./components/fill-page/index.vue')['default']
InternalLinkPage: typeof import('./components/internal-link-page/index.vue')['default']
LangProvider: typeof import('./components/lang-provider/index.vue')['default']
MainTransition: typeof import('./components/main-transition/index.vue')['default']
+ PinyinPro: typeof import('./components/pinyin-pro/index.vue')['default']
QrcodeDraw: typeof import('./components/qrcode-draw/index.vue')['default']
RouterLink: typeof import('vue-router')['RouterLink']
RouterView: typeof import('vue-router')['RouterView']
diff --git a/src/components/pinyin-pro/index.vue b/src/components/pinyin-pro/index.vue
new file mode 100644
index 0000000..4350380
--- /dev/null
+++ b/src/components/pinyin-pro/index.vue
@@ -0,0 +1,56 @@
+
+
+
+
+
+
+
diff --git a/src/lang/modules/enUS.ts b/src/lang/modules/enUS.ts
index e55eff5..9e368cf 100644
--- a/src/lang/modules/enUS.ts
+++ b/src/lang/modules/enUS.ts
@@ -24,7 +24,8 @@ export default {
["notice"]: "Notice",
["message"]: "Message",
["backlog"]: "Backlog",
- ["switch-language-to-preview"]: "Please switch the language to preview the internationalization effect"
+ ["switch-language-to-preview"]: "Please switch the language to preview the internationalization effect",
+ ["please-enter-something"]: "Please enter something"
},
menu: {
["home"]: "home",
@@ -59,6 +60,7 @@ export default {
["fingerprintjs2"]: "fingerprintjs2",
["barcode"]: "barcode",
["qrcode"]: "qrcode",
+ ["pinyin"]: "pinyin",
["markdown"]: "Markdown",
["directive"]: "directive",
["anti-shake"]: "anti-shake",
diff --git a/src/lang/modules/zhCN.ts b/src/lang/modules/zhCN.ts
index b85065a..9d1e11a 100644
--- a/src/lang/modules/zhCN.ts
+++ b/src/lang/modules/zhCN.ts
@@ -24,7 +24,8 @@ export default {
["notice"]: "通知",
["message"]: "消息",
["backlog"]: "待办",
- ["switch-language-to-preview"]: "请切换语言来预览国际化效果"
+ ["switch-language-to-preview"]: "请切换语言来预览国际化效果",
+ ["please-enter-something"]: "请输入"
},
menu: {
["home"]: "首页",
@@ -59,6 +60,7 @@ export default {
["fingerprintjs2"]: "浏览器指纹",
["barcode"]: "条形码",
["qrcode"]: "二维码",
+ ["pinyin"]: "拼音",
["markdown"]: "Markdown",
["directive"]: "自定义指令",
["anti-shake"]: "防抖",
diff --git a/src/mock/_data/system_menu.ts b/src/mock/_data/system_menu.ts
index 137c95a..50c8104 100644
--- a/src/mock/_data/system_menu.ts
+++ b/src/mock/_data/system_menu.ts
@@ -588,6 +588,23 @@ export default [
icon: "icon-menu",
sort: 10
}
+ },
+ {
+ path: "/component/pinyin",
+ name: "pinyin",
+ component: "component/pinyin/pinyin",
+ meta: {
+ title: "pinyin",
+ hide: false,
+ disable: false,
+ keepAlive: true,
+ affix: false,
+ link: "",
+ iframe: false,
+ roles: ["admin"],
+ icon: "icon-menu",
+ sort: 11
+ }
}
]
},
diff --git a/src/views/component/pinyin/pinyin.vue b/src/views/component/pinyin/pinyin.vue
new file mode 100644
index 0000000..69187a5
--- /dev/null
+++ b/src/views/component/pinyin/pinyin.vue
@@ -0,0 +1,77 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+