-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
23 changed files
with
324 additions
and
59 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,4 @@ | ||
node_modules | ||
.env | ||
packages/contracts/src/codegen/ | ||
pnpm-lock.yaml |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,135 @@ | ||
import duck from "@/assets/img/DarkDuck.svg"; | ||
import info from "@/assets/img/battle/info.png"; | ||
import attackButton from "@/assets/img/battle/attack-button.png"; | ||
import runButton from "@/assets/img/battle/run-button.png"; | ||
import rock from "@/assets/img/battle/rock.png"; | ||
import scissors from "@/assets/img/battle/scissors.png"; | ||
import paper from "@/assets/img/battle/paper.png"; | ||
import attack from "@/assets/img/battle/attack.svg"; | ||
import tactic from "@/assets/img/battle/tactic.svg"; | ||
import "./styles.scss"; | ||
|
||
export default function Battle() { | ||
return ( | ||
<div className="mi-battle-wrap"> | ||
<div className="mi-battle"> | ||
<div className="mi-battle-character"> | ||
<div className="mi-battle-info-icon"> | ||
<img | ||
src={info} | ||
style={{ | ||
width: "64px", | ||
height: "64px", | ||
marginTop: "12px", | ||
marginLeft: "12px", | ||
}} | ||
alt="" | ||
/> | ||
</div> | ||
<div className="mi-battle-character-card"> | ||
<div className="mi-battle-character-card-hp"> | ||
<div | ||
className="hp" | ||
style={{ | ||
position: "absolute", | ||
borderRadius: "4px", | ||
borderTopLeftRadius: 0, | ||
borderBottomLeftRadius: 0, | ||
background: "#FF6161", | ||
width: "60%", | ||
height: "22px", | ||
}} | ||
></div> | ||
</div> | ||
<img | ||
src={duck} | ||
style={{ | ||
transform: "scaleX(-1)", | ||
}} | ||
alt="" | ||
/> | ||
</div> | ||
<div className="mi-battle-character-card"> | ||
<div className="mi-battle-character-card-hp"> | ||
<div | ||
className="hp" | ||
style={{ | ||
position: "absolute", | ||
borderRadius: "4px", | ||
borderTopLeftRadius: 0, | ||
borderBottomLeftRadius: 0, | ||
background: "#FF6161", | ||
width: "60%", | ||
height: "22px", | ||
}} | ||
></div> | ||
</div> | ||
<img src={duck} alt="" /> | ||
</div> | ||
<div className="mi-battle-character-info"> | ||
<div className="character-info self"> | ||
<div>HP: 30/50</div> | ||
<div>ATK: 20</div> | ||
</div> | ||
<div className="character-info opponent"> | ||
<div>HP: 30/50</div> | ||
<div>ATK: 20</div> | ||
</div> | ||
</div> | ||
</div> | ||
<div className="mi-battle-action"> | ||
<div className="action"> | ||
<div className="action-title">Action</div> | ||
<div style={{ display: "flex" }}> | ||
<img src={attackButton} alt="" /> | ||
<img src={runButton} alt="" /> | ||
</div> | ||
</div> | ||
<div className="action"> | ||
<div | ||
style={{ | ||
color: "#fff", | ||
fontSize: "24px", | ||
}} | ||
> | ||
Choose your decision | ||
</div> | ||
<div | ||
style={{ | ||
marginTop: "12px", | ||
display: "flex", | ||
justifyContent: "center", | ||
columnGap: "12px", | ||
}} | ||
> | ||
<img | ||
src={attack} | ||
style={{ | ||
width: "48px", | ||
height: "48px", | ||
}} | ||
alt="" | ||
/> | ||
<img | ||
src={tactic} | ||
style={{ | ||
width: "48px", | ||
height: "48px", | ||
}} | ||
alt="" | ||
/> | ||
</div> | ||
</div> | ||
<div className="action"> | ||
<div className="action-title">Tactic</div> | ||
<div style={{ display: "flex" }}> | ||
<img src={rock} alt="" /> | ||
<img src={scissors} alt="" /> | ||
<img src={paper} alt="" /> | ||
</div> | ||
</div> | ||
</div> | ||
</div> | ||
</div> | ||
); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,83 @@ | ||
.mi-battle-wrap { | ||
width: 100vw; | ||
height: 100vh; | ||
position: fixed; | ||
overflow: hidden; | ||
display: flex; | ||
align-items: center; | ||
justify-content: center; | ||
z-index: 999; | ||
} | ||
|
||
.mi-battle { | ||
background: rgba(65, 47, 80, 0.95); | ||
box-shadow: 5px 4px 4px -1px rgba(0, 0, 0, 0.25); | ||
border-radius: 8px; | ||
padding: 24px 20px; | ||
|
||
.mi-battle-character { | ||
background: #fff; | ||
display: flex; | ||
column-gap: 180px; | ||
position: relative; | ||
|
||
.mi-battle-info-icon { | ||
position: absolute; | ||
} | ||
|
||
.mi-battle-character-card { | ||
display: flex; | ||
flex-direction: column; | ||
position: relative; | ||
align-items: center; | ||
|
||
img { | ||
margin-top: 90px; | ||
width: 280px; | ||
} | ||
|
||
.mi-battle-character-card-hp { | ||
position: absolute; | ||
width: 160px; | ||
height: 30px; | ||
border-radius: 6px; | ||
border: 4px solid #2d2d2d; | ||
top: 120px; | ||
} | ||
} | ||
|
||
.mi-battle-character-info { | ||
display: flex; | ||
justify-content: space-between; | ||
position: absolute; | ||
bottom: 0; | ||
width: 100%; | ||
padding: 0 12px; | ||
padding-bottom: 12px; | ||
|
||
.character-info { | ||
color: #000; | ||
} | ||
} | ||
} | ||
|
||
.mi-battle-action { | ||
margin-top: 12px; | ||
display: flex; | ||
justify-content: space-between; | ||
|
||
.action { | ||
img { | ||
width: 64px; | ||
height: 64px; | ||
} | ||
|
||
.action-title { | ||
background: #fff; | ||
font-size: 26px; | ||
text-align: center; | ||
margin-bottom: 12px; | ||
} | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.