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
bc5a3760
Commit
bc5a3760
authored
Mar 19, 2023
by
Chunchi Che
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
add alert.tsx
parent
823793b9
Pipeline
#20788
passed with stages
in 15 minutes and 9 seconds
Changes
3
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
33 additions
and
33 deletions
+33
-33
src/ui/Duel/2d.tsx
src/ui/Duel/2d.tsx
+0
-33
src/ui/Duel/alert.tsx
src/ui/Duel/alert.tsx
+31
-0
src/ui/Duel/main.tsx
src/ui/Duel/main.tsx
+2
-0
No files found.
src/ui/Duel/2d.tsx
deleted
100644 → 0
View file @
823793b9
import
React
from
"
react
"
;
export
const
Button2D
=
(
props
:
{
text
:
string
;
left
:
number
;
enable
:
boolean
;
onClick
:
()
=>
void
;
})
=>
(
<
adtFullscreenUi
name=
"ui"
>
<
rectangle
name=
"rect"
height=
"20px"
width=
"60px"
isEnabled=
{
props
.
enable
}
left=
{
props
.
left
}
>
<
rectangle
>
<
babylon
-
button
name=
"close-icon"
onPointerDownObservable=
{
props
.
onClick
}
>
<
textBlock
text=
{
props
.
text
}
fontFamily=
"FontAwesome"
fontStyle=
"bold"
fontSize=
{
15
}
color=
{
props
.
enable
?
"
yellow
"
:
"
white
"
}
/>
</
babylon
-
button
>
</
rectangle
>
</
rectangle
>
</
adtFullscreenUi
>
);
src/ui/Duel/alert.tsx
0 → 100644
View file @
bc5a3760
import
{
Alert
}
from
"
antd
"
;
import
React
from
"
react
"
;
import
{
useNavigate
}
from
"
react-router-dom
"
;
import
{
useAppSelector
}
from
"
../../hook
"
;
import
{
selectUnimplemented
}
from
"
../../reducers/duel/mod
"
;
const
NeosAlert
=
()
=>
{
const
unimplemented
=
useAppSelector
(
selectUnimplemented
);
const
navigate
=
useNavigate
();
return
(
<>
{
unimplemented
?
(
<
Alert
message=
{
`Unimplemented message with code=${unimplemented}`
}
description=
"It seems that there's something unimplemented by Neos. Sincerely apologize for that. Contact use to fix this issue: <linuxgnulover@gmail.com>"
showIcon
type=
"error"
closable
afterClose=
{
()
=>
{
navigate
(
"
/
"
);
}
}
/>
)
:
(
<></>
)
}
</>
);
};
export
default
NeosAlert
;
src/ui/Duel/main.tsx
View file @
bc5a3760
...
...
@@ -25,6 +25,7 @@ import DuelTimeLine from "./timeLine";
import
{
Row
}
from
"
antd
"
;
import
SendBox
from
"
./sendBox
"
;
import
PlayerStatus
from
"
./status
"
;
import
Alert
from
"
./alert
"
;
// Ref: https://github.com/brianzinn/react-babylonjs/issues/126
const
NeosDuel
=
()
=>
{
...
...
@@ -44,6 +45,7 @@ const NeosDuel = () => {
<
PositionModal
/>
<
OptionModal
/>
<
CheckCardModalV2
/>
<
Alert
/>
</>
);
};
...
...
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