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
9fc8e195
Commit
9fc8e195
authored
Jun 28, 2023
by
hewenhao
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
feat: update
parent
f8980127
Show whitespace changes
Inline
Side-by-side
Showing
8 changed files
with
57 additions
and
3 deletions
+57
-3
.oss
assets/_passing-stage/.oss
+26
-0
banner.png
assets/_passing-stage/banner.png
+0
-0
download.png
assets/_passing-stage/download.png
+0
-0
go.png
assets/_passing-stage/go.png
+0
-0
guide.png
assets/_passing-stage/guide.png
+0
-0
upload-assets-to-oss.js
scripts/upload-assets-to-oss.js
+6
-2
assets-_passing-stage.ts
src/assets/oss/assets-_passing-stage.ts
+24
-0
index.ts
src/pages/game/play/model/index.ts
+1
-1
No files found.
assets/_passing-stage/.oss
0 → 100644
View file @
9fc8e195
{
"banner.png": {
"u": "https://cdn.jkwljy.com/passing-stage/3Rvm4hGGicy67vyZAV1WebSRh2KT/690x180",
"w": 690,
"h": 180,
"ossName": "/passing-stage/3Rvm4hGGicy67vyZAV1WebSRh2KT/690x180"
},
"go.png": {
"u": "https://cdn.jkwljy.com/passing-stage/3xjcJGxa7kkAQk4nXdZkJ2K1xos2/120x120",
"w": 120,
"h": 120,
"ossName": "/passing-stage/3xjcJGxa7kkAQk4nXdZkJ2K1xos2/120x120"
},
"guide.png": {
"u": "https://cdn.jkwljy.com/passing-stage/dB5mPgn1oNkX2NfAPf1UkPPBACb/520x204",
"w": 520,
"h": 204,
"ossName": "/passing-stage/dB5mPgn1oNkX2NfAPf1UkPPBACb/520x204"
},
"download.png": {
"u": "https://cdn.jkwljy.com/passing-stage/3e3wCmnn2uzpFE28ULKVFBo8R1Zt/60x60",
"w": 60,
"h": 60,
"ossName": "/passing-stage/3e3wCmnn2uzpFE28ULKVFBo8R1Zt/60x60"
}
}
assets/_passing-stage/banner.png
0 → 100644
View file @
9fc8e195
87.7 KB
assets/_passing-stage/download.png
0 → 100644
View file @
9fc8e195
1.75 KB
assets/_passing-stage/go.png
0 → 100644
View file @
9fc8e195
11.4 KB
assets/_passing-stage/guide.png
0 → 100644
View file @
9fc8e195
27.6 KB
scripts/upload-assets-to-oss.js
View file @
9fc8e195
...
@@ -166,13 +166,17 @@ function getFileName (relativePath, absolutPath, dimensions) {
...
@@ -166,13 +166,17 @@ function getFileName (relativePath, absolutPath, dimensions) {
.
update
(
fs
.
readFileSync
(
absolutPath
,
{
encoding
:
'binary'
}))
.
update
(
fs
.
readFileSync
(
absolutPath
,
{
encoding
:
'binary'
}))
.
digest
()
.
digest
()
const
key
=
bs58
.
encode
(
buffer
)
const
key
=
bs58
.
encode
(
buffer
)
let
prefix
=
'/pk-math'
if
(
subFolder
===
'_passing-stage'
)
{
prefix
=
'/passing-stage'
}
if
(
dimensions
)
{
if
(
dimensions
)
{
return
`
/pk-math
/
${
key
}
/
${
dimensions
.
width
}
x
${
dimensions
.
height
}
`
return
`
${
prefix
}
/
${
key
}
/
${
dimensions
.
width
}
x
${
dimensions
.
height
}
`
}
}
const
dot
=
absolutPath
.
lastIndexOf
(
'.'
)
const
dot
=
absolutPath
.
lastIndexOf
(
'.'
)
if
(
dot
<
-
1
)
{
if
(
dot
<
-
1
)
{
throw
Error
(
'File name is not right!'
)
throw
Error
(
'File name is not right!'
)
}
}
const
suffix
=
absolutPath
.
substr
(
dot
+
1
)
const
suffix
=
absolutPath
.
substr
(
dot
+
1
)
return
`
/pk-math
/
${
key
}
.
${
suffix
}
`
return
`
${
prefix
}
/
${
key
}
.
${
suffix
}
`
}
}
src/assets/oss/assets-_passing-stage.ts
0 → 100644
View file @
9fc8e195
/* eslint-disable quotes */
/* eslint-disable quote-props */
export
default
{
"banner.png"
:
{
"u"
:
"https://cdn.jkwljy.com/passing-stage/3Rvm4hGGicy67vyZAV1WebSRh2KT/690x180"
,
"w"
:
690
,
"h"
:
180
},
"go.png"
:
{
"u"
:
"https://cdn.jkwljy.com/passing-stage/3xjcJGxa7kkAQk4nXdZkJ2K1xos2/120x120"
,
"w"
:
120
,
"h"
:
120
},
"guide.png"
:
{
"u"
:
"https://cdn.jkwljy.com/passing-stage/dB5mPgn1oNkX2NfAPf1UkPPBACb/520x204"
,
"w"
:
520
,
"h"
:
204
},
"download.png"
:
{
"u"
:
"https://cdn.jkwljy.com/passing-stage/3e3wCmnn2uzpFE28ULKVFBo8R1Zt/60x60"
,
"w"
:
60
,
"h"
:
60
}
}
as
const
src/pages/game/play/model/index.ts
View file @
9fc8e195
...
@@ -120,7 +120,7 @@ const gameModel: GameModel = {
...
@@ -120,7 +120,7 @@ const gameModel: GameModel = {
const
answers
=
state
.
questionList
[
state
.
currentQuestionIndex
]?.
answers
const
answers
=
state
.
questionList
[
state
.
currentQuestionIndex
]?.
answers
const
val
=
answers
?.[
index
]
const
val
=
answers
?.[
index
]
if
(
answers
&&
val
)
{
if
(
answers
&&
val
)
{
val
.
userAnswer
=
`
${
val
.
userAnswer
===
'0'
?
''
:
(
val
.
userAnswer
||
''
)}${
detail
}
`
val
.
userAnswer
=
`
${
val
.
userAnswer
===
'0'
&&
detail
!==
'.'
?
''
:
(
val
.
userAnswer
||
''
)}${
detail
}
`
const
maxLen
=
answers
.
length
const
maxLen
=
answers
.
length
state
.
questionList
=
state
.
questionList
.
slice
()
state
.
questionList
=
state
.
questionList
.
slice
()
if
(
answers
.
length
>
1
&&
index
<
maxLen
-
1
)
{
if
(
answers
.
length
>
1
&&
index
<
maxLen
-
1
)
{
...
...
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