Skip to content
Snippets Groups Projects
Unverified Commit 3480d50f authored by GyDi's avatar GyDi
Browse files

feat: adjust control ui

parent 43af5525
No related branches found
No related tags found
No related merge requests found
...@@ -2,35 +2,37 @@ import { Button } from "@mui/material"; ...@@ -2,35 +2,37 @@ import { Button } from "@mui/material";
import { appWindow } from "@tauri-apps/api/window"; import { appWindow } from "@tauri-apps/api/window";
import { import {
CloseRounded, CloseRounded,
CropLandscapeOutlined, CropSquareRounded,
HorizontalRuleRounded, HorizontalRuleRounded,
} from "@mui/icons-material"; } from "@mui/icons-material";
const LayoutControl = () => { const LayoutControl = () => {
const minWidth = 40;
return ( return (
<> <>
<Button <Button
size="small" size="small"
sx={{ minWidth: 48 }} sx={{ minWidth, svg: { transform: "scale(0.9)" } }}
onClick={() => appWindow.minimize()} onClick={() => appWindow.minimize()}
> >
<HorizontalRuleRounded /> <HorizontalRuleRounded fontSize="small" />
</Button> </Button>
<Button <Button
size="small" size="small"
sx={{ minWidth: 48 }} sx={{ minWidth, svg: { transform: "scale(0.9)" } }}
onClick={() => appWindow.toggleMaximize()} onClick={() => appWindow.toggleMaximize()}
> >
<CropLandscapeOutlined /> <CropSquareRounded fontSize="small" />
</Button> </Button>
<Button <Button
size="small" size="small"
sx={{ minWidth: 48 }} sx={{ minWidth, svg: { transform: "scale(1.05)" } }}
onClick={() => appWindow.hide()} onClick={() => appWindow.hide()}
> >
<CloseRounded /> <CloseRounded fontSize="small" />
</Button> </Button>
</> </>
); );
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment