Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
N
Neos
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Locked Files
Issues
0
Issues
0
List
Boards
Labels
Service Desk
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Security & Compliance
Security & Compliance
Dependency List
License Compliance
Packages
Packages
List
Container Registry
Analytics
Analytics
CI / CD
Code Review
Insights
Issues
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
love_飞影
Neos
Commits
d263da4f
Commit
d263da4f
authored
Jan 19, 2023
by
chechunchi
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix
parent
b5ee2735
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
32 additions
and
25 deletions
+32
-25
src/reducers/duel/mod.ts
src/reducers/duel/mod.ts
+2
-0
src/ui/Duel/checkCardModalV2.tsx
src/ui/Duel/checkCardModalV2.tsx
+30
-25
No files found.
src/reducers/duel/mod.ts
View file @
d263da4f
...
@@ -52,6 +52,7 @@ import {
...
@@ -52,6 +52,7 @@ import {
setCheckCardModalV2FinishAbleImpl
,
setCheckCardModalV2FinishAbleImpl
,
resetCheckCardModalV2Impl
,
resetCheckCardModalV2Impl
,
setCheckCardModalV2ResponseAbleImpl
,
setCheckCardModalV2ResponseAbleImpl
,
checkCardModalV2Case
,
}
from
"
./modal/mod
"
;
}
from
"
./modal/mod
"
;
import
{
import
{
MonsterState
,
MonsterState
,
...
@@ -250,6 +251,7 @@ const duelSlice = createSlice({
...
@@ -250,6 +251,7 @@ const duelSlice = createSlice({
checkCardModalCase
(
builder
);
checkCardModalCase
(
builder
);
YesNoModalCase
(
builder
);
YesNoModalCase
(
builder
);
optionModalCase
(
builder
);
optionModalCase
(
builder
);
checkCardModalV2Case
(
builder
);
},
},
});
});
...
...
src/ui/Duel/checkCardModalV2.tsx
View file @
d263da4f
import
React
from
"
react
"
;
import
React
from
"
react
"
;
import
{
useAppSelector
}
from
"
../../hook
"
;
import
{
useAppSelector
}
from
"
../../hook
"
;
import
{
store
}
from
"
../../store
"
;
import
{
store
}
from
"
../../store
"
;
import
{
Modal
,
Button
,
Card
,
Col
}
from
"
antd
"
;
import
{
Modal
,
Button
,
Card
,
Row
,
Col
}
from
"
antd
"
;
import
{
CheckCard
}
from
"
@ant-design/pro-components
"
;
import
{
CheckCard
}
from
"
@ant-design/pro-components
"
;
import
{
import
{
selectCheckCardModalV2CancelAble
,
selectCheckCardModalV2CancelAble
,
...
@@ -65,49 +65,54 @@ const CheckCardModalV2 = () => {
...
@@ -65,49 +65,54 @@ const CheckCardModalV2 = () => {
size=
"small"
size=
"small"
onChange=
{
(
value
)
=>
{
onChange=
{
(
value
)
=>
{
if
(
responseable
)
{
if
(
responseable
)
{
dispatch
(
setCheckCardModalV2IsOpen
(
false
));
// @ts-ignore
// @ts-ignore
sendSelectUnselectCardResponse
({
selected_ptr
:
value
});
sendSelectUnselectCardResponse
({
selected_ptr
:
value
});
dispatch
(
setCheckCardModalV2ResponseAble
(
false
));
dispatch
(
setCheckCardModalV2ResponseAble
(
false
));
}
}
}
}
}
}
>
>
{
selectableOptions
.
map
((
option
,
idx
)
=>
{
<
Row
>
{
selectableOptions
.
map
((
option
,
idx
)
=>
{
return
(
<
Col
span=
{
4
}
key=
{
idx
}
>
<
CheckCard
title=
{
option
.
name
}
description=
{
option
.
desc
}
style=
{
{
width
:
120
}
}
cover=
{
<
img
alt=
{
option
.
code
.
toString
()
}
src=
{
`https://cdn02.moecube.com:444/images/ygopro-images-zh-CN/${option.code}.jpg`
}
style=
{
{
width
:
100
}
}
/>
}
value=
{
option
.
response
}
/>
</
Col
>
);
})
}
</
Row
>
</
CheckCard
.
Group
>
<
p
>
已经选择的卡片
</
p
>
<
Row
>
{
selectedOptions
.
map
((
option
,
idx
)
=>
{
return
(
return
(
<
Col
span=
{
4
}
key=
{
idx
}
>
<
Col
span=
{
4
}
key=
{
idx
}
>
<
CheckCard
<
Card
title=
{
option
.
name
}
hoverable
description=
{
option
.
desc
}
style=
{
{
width
:
120
}
}
style=
{
{
width
:
120
}
}
cover=
{
cover=
{
<
img
<
img
alt=
{
option
.
code
.
toString
()
}
alt=
{
option
.
code
.
toString
()
}
src=
{
`https://cdn02.moecube.com:444/images/ygopro-images-zh-CN/${option.code}.jpg`
}
src=
{
`https://cdn02.moecube.com:444/images/ygopro-images-zh-CN/${option.code}.jpg`
}
style=
{
{
width
:
100
}
}
/>
/>
}
}
value=
{
option
.
response
}
/>
/>
</
Col
>
</
Col
>
);
);
})
}
})
}
</
CheckCard
.
Group
>
</
Row
>
<
p
>
已经选择的卡片
</
p
>
{
selectedOptions
.
map
((
option
,
idx
)
=>
{
return
(
<
Col
span=
{
4
}
key=
{
idx
}
>
<
Card
hoverable
style=
{
{
width
:
120
}
}
cover=
{
<
img
alt=
{
option
.
code
.
toString
()
}
src=
{
`https://cdn02.moecube.com:444/images/ygopro-images-zh-CN/${option.code}.jpg`
}
/>
}
/>
</
Col
>
);
})
}
</
Modal
>
</
Modal
>
);
);
};
};
...
...
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