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
1
Issues
1
List
Boards
Labels
Service Desk
Milestones
Merge Requests
2
Merge Requests
2
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
MyCard
Neos
Commits
aacf8ace
Commit
aacf8ace
authored
Sep 06, 2023
by
Chunchi Che
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
optimize SelectCardsModal
parent
6482b896
Pipeline
#23381
passed with stages
in 12 minutes and 42 seconds
Changes
2
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
14 additions
and
2 deletions
+14
-2
src/ui/Duel/Message/SelectCardsModal/index.module.scss
src/ui/Duel/Message/SelectCardsModal/index.module.scss
+7
-0
src/ui/Duel/Message/SelectCardsModal/index.tsx
src/ui/Duel/Message/SelectCardsModal/index.tsx
+7
-2
No files found.
src/ui/Duel/Message/SelectCardsModal/index.module.scss
View file @
aacf8ace
...
@@ -45,6 +45,13 @@
...
@@ -45,6 +45,13 @@
margin-inline-end
:
0
;
margin-inline-end
:
0
;
margin-block-end
:
0
;
margin-block-end
:
0
;
flex-shrink
:
0
;
flex-shrink
:
0
;
&
.opponent
{
&
:
:
before
{
background-color
:
#dc0034
33
;
box-shadow
:
0
0
0
2px
#d22d2d
inset
;
}
}
}
}
.card
{
.card
{
...
...
src/ui/Duel/Message/SelectCardsModal/index.tsx
View file @
aacf8ace
import
{
CheckCard
}
from
"
@ant-design/pro-components
"
;
import
{
CheckCard
}
from
"
@ant-design/pro-components
"
;
import
{
Button
,
Card
,
Segmented
,
Space
,
Tooltip
}
from
"
antd
"
;
import
{
Button
,
Card
,
Segmented
,
Space
,
Tooltip
}
from
"
antd
"
;
import
classnames
from
"
classnames
"
;
import
{
useEffect
,
useState
}
from
"
react
"
;
import
{
useEffect
,
useState
}
from
"
react
"
;
import
{
INTERNAL_Snapshot
as
Snapshot
,
useSnapshot
}
from
"
valtio
"
;
import
{
INTERNAL_Snapshot
as
Snapshot
,
useSnapshot
}
from
"
valtio
"
;
import
{
type
CardMeta
,
Region
,
type
ygopro
}
from
"
@/api
"
;
import
{
type
CardMeta
,
Region
,
type
ygopro
}
from
"
@/api
"
;
import
{
fetchStrings
}
from
"
@/api
"
;
import
{
fetchStrings
}
from
"
@/api
"
;
import
{
CardType
,
matStore
}
from
"
@/stores
"
;
import
{
CardType
,
isMe
,
matStore
}
from
"
@/stores
"
;
import
{
YgoCard
}
from
"
@/ui/Shared
"
;
import
{
YgoCard
}
from
"
@/ui/Shared
"
;
import
{
groupBy
}
from
"
../../utils
"
;
import
{
groupBy
}
from
"
../../utils
"
;
...
@@ -176,7 +177,11 @@ export const SelectCardsModal: React.FC<SelectCardsModalProps> = ({
...
@@ -176,7 +177,11 @@ export const SelectCardsModal: React.FC<SelectCardsModalProps> = ({
className=
{
styles
.
card
}
className=
{
styles
.
card
}
/>
/>
}
}
className=
{
styles
[
"
check-card
"
]
}
className=
{
classnames
(
styles
[
"
check-card
"
],
{
[
styles
.
opponent
]:
card
.
location
?.
controller
!==
undefined
&&
!
isMe
(
card
.
location
.
controller
),
})
}
value=
{
card
}
value=
{
card
}
onClick=
{
()
=>
{
onClick=
{
()
=>
{
showCardModal
(
card
);
showCardModal
(
card
);
...
...
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