-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
add: use a separate file for the menu & fix the electron builder config
- Loading branch information
1 parent
a7146d8
commit c13da59
Showing
10 changed files
with
115 additions
and
138 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
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
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 was deleted.
Oops, something went wrong.
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,27 @@ | ||
.menu { | ||
height: max-content; | ||
display: flex; | ||
flex-direction: column; | ||
padding: 10px; | ||
} | ||
|
||
.menu.left { | ||
margin-right: 20px; | ||
} | ||
|
||
.menu.right { | ||
margin-left: 20px; | ||
} | ||
|
||
.menu-item { | ||
padding: 50px 20px; | ||
margin-bottom: 5px; | ||
font-family: 'Courier New', Courier, monospace; | ||
font-weight: 600; | ||
background-color: #f0f0f0; | ||
border: 1px solid #ccc; | ||
} | ||
|
||
.menu-item:hover { | ||
background-color: #e0e0e0; | ||
} |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
import "../assets/menu.css"; | ||
import { MenuProps, PositionType } from "@renderer/types/panel"; | ||
|
||
export const Menu = ({ | ||
items, | ||
clickable, | ||
setStationType | ||
}: MenuProps) => { | ||
return ( | ||
<div className="menu"> | ||
{items.map((item) => ( | ||
<button | ||
onClick={() => | ||
clickable | ||
? setStationType(item.stationType as PositionType) | ||
: null} | ||
key={item.id} | ||
className="menu-item" | ||
> | ||
{item.label} | ||
</button> | ||
))} | ||
</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
Oops, something went wrong.