Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
D
DG_FAF
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
template admin
DG_FAF
Commits
576030aa
Commit
576030aa
authored
Apr 23, 2023
by
李维
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
修复苹果设备单引号不被识别的问题
parent
a85af4ea
Changes
2
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
15 additions
and
1 deletion
+15
-1
DG_FAF.ts
assets/DG_FAF/scene/DG_FAF.ts
+14
-0
defaultData_DG_FAF.ts
assets/DG_FAF/script/defaultData_DG_FAF.ts
+1
-1
No files found.
assets/DG_FAF/scene/DG_FAF.ts
View file @
576030aa
...
@@ -1885,6 +1885,13 @@ export default class SceneComponent extends MyCocosSceneComponent {
...
@@ -1885,6 +1885,13 @@ export default class SceneComponent extends MyCocosSceneComponent {
// 开放型回答 只要有内容就算对
// 开放型回答 只要有内容就算对
right
=
userInputText
!=
""
;
right
=
userInputText
!=
""
;
}
else
{
}
else
{
// 替换特殊的符号
const
standardApostrophe
=
"
'
"
;
const
isoApostrophe
=
"
’
"
;
const
regApostrophe
=
new
RegExp
(
isoApostrophe
,
"
g
"
)
userInputText
=
userInputText
.
replace
(
regApostrophe
,
standardApostrophe
);
configInputText
=
configInputText
.
replace
(
regApostrophe
,
standardApostrophe
);
// 除特殊配置, 默认进行缩写通配符替换
// 除特殊配置, 默认进行缩写通配符替换
if
(
!
contentData
.
notAdaptContraction
)
{
if
(
!
contentData
.
notAdaptContraction
)
{
userInputText
=
this
.
adaptContraction
(
userInputText
);
userInputText
=
this
.
adaptContraction
(
userInputText
);
...
@@ -1986,6 +1993,13 @@ export default class SceneComponent extends MyCocosSceneComponent {
...
@@ -1986,6 +1993,13 @@ export default class SceneComponent extends MyCocosSceneComponent {
// 开放型回答 只要有内容就算对
// 开放型回答 只要有内容就算对
right
=
userInputText
!=
""
;
right
=
userInputText
!=
""
;
}
else
{
}
else
{
// 替换特殊的符号
const
standardApostrophe
=
"
'
"
;
const
isoApostrophe
=
"
’
"
;
const
regApostrophe
=
new
RegExp
(
isoApostrophe
,
"
g
"
)
userInputText
=
userInputText
.
replace
(
regApostrophe
,
standardApostrophe
);
configInputText
=
configInputText
.
replace
(
regApostrophe
,
standardApostrophe
);
// 除特殊配置, 默认进行缩写通配符替换
// 除特殊配置, 默认进行缩写通配符替换
if
(
!
option
.
notAdaptContraction
)
{
if
(
!
option
.
notAdaptContraction
)
{
userInputText
=
this
.
adaptContraction
(
userInputText
);
userInputText
=
this
.
adaptContraction
(
userInputText
);
...
...
assets/DG_FAF/script/defaultData_DG_FAF.ts
View file @
576030aa
This diff is collapsed.
Click to expand it.
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment