Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
G
GeekLearnMathWeapp
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
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
frontend
GeekLearnMathWeapp
Commits
3b01da02
Commit
3b01da02
authored
Apr 02, 2023
by
hewenhao
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
feat: vibrateShort
parent
06763543
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
2 additions
and
1 deletion
+2
-1
index.ts
src/pages/game/play/model/index.ts
+2
-1
No files found.
src/pages/game/play/model/index.ts
View file @
3b01da02
import
{
action
,
Action
,
computed
,
Computed
,
State
,
Thunk
,
thunk
}
from
'easy-peasy'
import
{
action
,
Action
,
computed
,
Computed
,
State
,
Thunk
,
thunk
}
from
'easy-peasy'
import
{
AppStoreModel
}
from
'@/store/store-model'
import
{
AppStoreModel
}
from
'@/store/store-model'
import
{
getQuestionList
,
type
StageDetail
,
getStageDetail
,
completeStage
,
StageType
,
type
CompleteStageOut
,
StageLevel
}
from
'@/api'
import
{
getQuestionList
,
type
StageDetail
,
getStageDetail
,
completeStage
,
StageType
,
type
CompleteStageOut
,
StageLevel
}
from
'@/api'
import
{
showLoading
,
hideLoading
,
showModal
,
redirectTo
}
from
'@tarojs/taro'
import
{
showLoading
,
hideLoading
,
showModal
,
redirectTo
,
vibrateShort
}
from
'@tarojs/taro'
import
{
import
{
QuestionType
,
QuestionType
,
QuestionAnswer
,
QuestionAnswer
,
...
@@ -129,6 +129,7 @@ const gameModel: GameModel = {
...
@@ -129,6 +129,7 @@ const gameModel: GameModel = {
}),
}),
updateUserAnswer
:
action
((
state
,
char
)
=>
{
updateUserAnswer
:
action
((
state
,
char
)
=>
{
vibrateShort
()
const
index
=
state
.
currentInputIndex
const
index
=
state
.
currentInputIndex
const
answers
=
state
.
questionList
[
state
.
currentQuestionIndex
]?.
answers
const
answers
=
state
.
questionList
[
state
.
currentQuestionIndex
]?.
answers
const
val
=
answers
?.[
index
]
const
val
=
answers
?.[
index
]
...
...
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