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
7cd2a667
Commit
7cd2a667
authored
Aug 05, 2024
by
Chunchi Che
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
add ActionHistory
parent
56493c78
Pipeline
#28898
passed with stages
in 12 minutes and 18 seconds
Changes
8
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
8 changed files
with
110 additions
and
4 deletions
+110
-4
src/ui/Duel/Main.tsx
src/ui/Duel/Main.tsx
+4
-4
src/ui/Duel/Message/ActionHistory/index.module.scss
src/ui/Duel/Message/ActionHistory/index.module.scss
+43
-0
src/ui/Duel/Message/ActionHistory/index.tsx
src/ui/Duel/Message/ActionHistory/index.tsx
+48
-0
src/ui/Duel/Message/index.ts
src/ui/Duel/Message/index.ts
+2
-0
src/ui/Duel/PlayMat/Menu/index.tsx
src/ui/Duel/PlayMat/Menu/index.tsx
+9
-0
src/ui/Duel/PlayMat/index.ts
src/ui/Duel/PlayMat/index.ts
+2
-0
src/ui/I18N/Source/Chinese/translation.json
src/ui/I18N/Source/Chinese/translation.json
+1
-0
src/ui/I18N/Source/English/translation.json
src/ui/I18N/Source/English/translation.json
+1
-0
No files found.
src/ui/Duel/Main.tsx
View file @
7cd2a667
...
@@ -8,7 +8,9 @@ import { AudioActionType, changeScene } from "@/infra/audio";
...
@@ -8,7 +8,9 @@ import { AudioActionType, changeScene } from "@/infra/audio";
import
{
matStore
,
SideStage
,
sideStore
}
from
"
@/stores
"
;
import
{
matStore
,
SideStage
,
sideStore
}
from
"
@/stores
"
;
import
{
import
{
ActionHistory
,
Alert
,
Alert
,
AnnounceModal
,
CardListModal
,
CardListModal
,
CardModal
,
CardModal
,
CheckCounterModal
,
CheckCounterModal
,
...
@@ -21,10 +23,7 @@ import {
...
@@ -21,10 +23,7 @@ import {
SortCardModal
,
SortCardModal
,
YesNoModal
,
YesNoModal
,
}
from
"
./Message
"
;
}
from
"
./Message
"
;
import
{
AnnounceModal
}
from
"
./Message/AnnounceModal
"
;
import
{
ChatBox
,
HandChain
,
LifeBar
,
Mat
,
Menu
,
Underlying
}
from
"
./PlayMat
"
;
import
{
LifeBar
,
Mat
,
Menu
,
Underlying
}
from
"
./PlayMat
"
;
import
{
ChatBox
}
from
"
./PlayMat/ChatBox
"
;
import
{
HandChain
}
from
"
./PlayMat/HandChain
"
;
export
const
loader
:
LoaderFunction
=
async
()
=>
{
export
const
loader
:
LoaderFunction
=
async
()
=>
{
// 更新场景
// 更新场景
...
@@ -88,6 +87,7 @@ export const Component: React.FC = () => {
...
@@ -88,6 +87,7 @@ export const Component: React.FC = () => {
<
EndModal
/>
<
EndModal
/>
<
ChatBox
/>
<
ChatBox
/>
<
HandChain
/>
<
HandChain
/>
<
ActionHistory
/>
</>
</>
);
);
};
};
...
...
src/ui/Duel/Message/ActionHistory/index.module.scss
0 → 100644
View file @
7cd2a667
.root
{
:global
(
.ant-drawer-content-wrapper
)
{
box-shadow
:
none
;
}
:global
(
.ant-drawer-content
)
{
display
:
flex
;
flex-direction
:
column
;
background
:
#0b0a0a
96
;
}
}
.drawer
{
width
:
100%
;
right
:
10%
;
--height
:
40rem
;
top
:
calc
((
100%
-
var
(
--
height
))
/
2
);
height
:
var
(
--
height
)
!
important
;
position
:
relative
;
border-radius
:
0
.375rem
;
:global
(
.ant-drawer-header
)
{
padding
:
1rem
0
;
:global
(
.ant-drawer-header-title
)
{
flex-direction
:
row-reverse
;
padding-left
:
1
.5rem
;
}
}
}
.container
{
position
:
relative
;
height
:
100%
;
.timeline
{
p
{
font-family
:
var
(
--
theme-font
);
font-size
:
1rem
;
}
}
}
src/ui/Duel/Message/ActionHistory/index.tsx
0 → 100644
View file @
7cd2a667
import
{
RightOutlined
}
from
"
@ant-design/icons
"
;
import
{
Drawer
,
Timeline
}
from
"
antd
"
;
import
React
from
"
react
"
;
import
{
proxy
,
useSnapshot
}
from
"
valtio
"
;
import
{
ScrollableArea
}
from
"
@/ui/Shared
"
;
import
styles
from
"
./index.module.scss
"
;
const
defaultStore
=
{
isOpen
:
false
,
};
const
store
=
proxy
(
defaultStore
);
export
const
ActionHistory
:
React
.
FC
=
()
=>
{
const
{
isOpen
}
=
useSnapshot
(
store
);
return
(
<
Drawer
open=
{
isOpen
}
placement=
"right"
rootClassName=
{
styles
.
root
}
className=
{
styles
.
drawer
}
mask=
{
false
}
closeIcon=
{
<
RightOutlined
/>
}
onClose=
{
()
=>
(
store
.
isOpen
=
false
)
}
title=
"操作历史"
// TODO: I18N
>
<
ScrollableArea
className=
{
styles
.
container
}
maxHeight=
"var(--height)"
>
<
Timeline
className=
{
styles
.
timeline
}
items=
{
[
{
color
:
"
red
"
,
children
:
<
p
>
我方发动灰流丽的效果
</
p
>,
},
{
color
:
"
blue
"
,
children
:
<
p
>
对方发动墓穴的指名者
</
p
>,
},
]
}
/>
</
ScrollableArea
>
</
Drawer
>
);
};
export
const
displayActionHistory
=
()
=>
(
store
.
isOpen
=
true
);
src/ui/Duel/Message/index.ts
View file @
7cd2a667
export
*
from
"
./ActionHistory
"
;
export
*
from
"
./Alert
"
;
export
*
from
"
./Alert
"
;
export
*
from
"
./AnnounceModal
"
;
export
*
from
"
./CardListModal
"
;
export
*
from
"
./CardListModal
"
;
export
*
from
"
./CardModal
"
;
export
*
from
"
./CardModal
"
;
export
*
from
"
./CheckCounterModal
"
;
export
*
from
"
./CheckCounterModal
"
;
...
...
src/ui/Duel/PlayMat/Menu/index.tsx
View file @
7cd2a667
...
@@ -2,6 +2,7 @@ import {
...
@@ -2,6 +2,7 @@ import {
ArrowRightOutlined
,
ArrowRightOutlined
,
CheckOutlined
,
CheckOutlined
,
CloseCircleFilled
,
CloseCircleFilled
,
FileSearchOutlined
,
MessageFilled
,
MessageFilled
,
RobotFilled
,
RobotFilled
,
RobotOutlined
,
RobotOutlined
,
...
@@ -37,6 +38,7 @@ import { useTranslation } from "react-i18next";
...
@@ -37,6 +38,7 @@ import { useTranslation } from "react-i18next";
import
{
getUIContainer
}
from
"
@/container/compat
"
;
import
{
getUIContainer
}
from
"
@/container/compat
"
;
import
{
displayActionHistory
}
from
"
../../Message
"
;
import
{
clearAllIdleInteractivities
,
clearSelectInfo
}
from
"
../../utils
"
;
import
{
clearAllIdleInteractivities
,
clearSelectInfo
}
from
"
../../utils
"
;
import
{
openChatBox
}
from
"
../ChatBox
"
;
import
{
openChatBox
}
from
"
../ChatBox
"
;
...
@@ -349,6 +351,13 @@ export const Menu = () => {
...
@@ -349,6 +351,13 @@ export const Menu = () => {
type=
"text"
type=
"text"
></
Button
>
></
Button
>
</
DropdownWithTitle
>
</
DropdownWithTitle
>
<
Tooltip
title=
{
i18n
(
"
History
"
)
}
>
<
Button
icon=
{
<
FileSearchOutlined
/>
}
onClick=
{
displayActionHistory
}
type=
"text"
/>
</
Tooltip
>
<
Tooltip
title=
"AI"
>
<
Tooltip
title=
"AI"
>
<
Button
<
Button
icon=
{
enableKuriboh
?
<
RobotFilled
/>
:
<
RobotOutlined
/>
}
icon=
{
enableKuriboh
?
<
RobotFilled
/>
:
<
RobotOutlined
/>
}
...
...
src/ui/Duel/PlayMat/index.ts
View file @
7cd2a667
export
*
from
"
./ChatBox
"
;
export
*
from
"
./HandChain
"
;
export
*
from
"
./LifeBar
"
;
export
*
from
"
./LifeBar
"
;
export
*
from
"
./Mat
"
;
export
*
from
"
./Mat
"
;
export
*
from
"
./Menu
"
;
export
*
from
"
./Menu
"
;
...
...
src/ui/I18N/Source/Chinese/translation.json
View file @
7cd2a667
...
@@ -184,6 +184,7 @@
...
@@ -184,6 +184,7 @@
},
},
"Menu"
:
{
"Menu"
:
{
"DoYouSurrunder"
:
"是否投降?"
,
"DoYouSurrunder"
:
"是否投降?"
,
"History"
:
"操作历史"
,
"Cancel"
:
"取消"
,
"Cancel"
:
"取消"
,
"Confirm"
:
"确定"
,
"Confirm"
:
"确定"
,
"SelectPhase"
:
"请选择要进入的阶段"
,
"SelectPhase"
:
"请选择要进入的阶段"
,
...
...
src/ui/I18N/Source/English/translation.json
View file @
7cd2a667
...
@@ -182,6 +182,7 @@
...
@@ -182,6 +182,7 @@
},
},
"Menu"
:
{
"Menu"
:
{
"DoYouSurrunder"
:
"Do you surrender?"
,
"DoYouSurrunder"
:
"Do you surrender?"
,
"History"
:
"Operation History"
,
"Cancel"
:
"Cancel"
,
"Cancel"
:
"Cancel"
,
"Confirm"
:
"Confirm"
,
"Confirm"
:
"Confirm"
,
"SelectPhase"
:
"Please select the phase"
,
"SelectPhase"
:
"Please select the phase"
,
...
...
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