From 2b5f920cec15b0268178b8445f5b02fbad719954 Mon Sep 17 00:00:00 2001 From: zhangyun Date: Tue, 16 Apr 2024 11:35:57 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=A4=8Dissues=EF=BC=9AI9H065?= =?UTF-8?q?=EF=BC=8C=E5=88=9B=E5=BB=BAc=E8=AF=AD=E8=A8=80=E9=A1=B9?= =?UTF-8?q?=E7=9B=AE=EF=BC=8C=E4=BD=9C=E8=80=85=E6=94=AF=E6=8C=81=E7=A9=BA?= =?UTF-8?q?=E6=A0=BC?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- web/src/languages/en.json | 2 +- web/src/languages/zh.json | 2 +- web/src/views/components/Global.vue | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/web/src/languages/en.json b/web/src/languages/en.json index fcd7801..a1b7e5a 100644 --- a/web/src/languages/en.json +++ b/web/src/languages/en.json @@ -346,7 +346,7 @@ "CreateQtWidgetsTemplate": "Create Qt Widgets Application Project", "errorEmpty": "Can't be empty!", "error": "illegal!", - "errorAuthor": "Author is illegal!2-128,Only Chinese characters, numbers, letters, hyphen and underline ...", + "errorAuthor": "Author is illegal!2-128,Only Chinese characters, numbers, spaces, letters, hyphen and underline ...", "errorEmail": "Email is illegal!", "errorLibrary": "Library is illegal!", "errorRunfileName": "Run file name is illegal", diff --git a/web/src/languages/zh.json b/web/src/languages/zh.json index 5396014..58b9cd7 100644 --- a/web/src/languages/zh.json +++ b/web/src/languages/zh.json @@ -345,7 +345,7 @@ "extension.project.noprojectidefile": "没有项目标识文件", "CreateQtConsoleTemplate": "创建 Qt 控制台应用项目", "CreateQtWidgetsTemplate": "创建 Qt 桌面应用项目", - "errorAuthor": "作者格式错误!最长128,必须由中文、字母、数字、中横线、下划线等组成", + "errorAuthor": "作者格式错误!最长128,必须由中文、字母、空格、数字、中横线、下划线等组成", "errorEmpty": "不能为空", "errorEmail": "电子邮件格式错误!", "errorLibrary": "扩展链接库最长1024,必须由字母、数字、中横线、下划线组成,支持以空格间隔。", diff --git a/web/src/views/components/Global.vue b/web/src/views/components/Global.vue index 0225f44..5ed3d18 100644 --- a/web/src/views/components/Global.vue +++ b/web/src/views/components/Global.vue @@ -306,7 +306,7 @@ const byteLength = (str) => { const isAuthor = (author) => { let len = byteLength(author); if (len >= 1 && len <= 128) { - var patt = /^[\w-\.\u4e00-\u9fa5]{1,128}$/; + var patt = /^[\w-\s-\.\u4e00-\u9fa5]{1,128}$/; return patt.test(author);; } else { return false;