更改布局

This commit is contained in:
xmdhs 2023-10-10 00:42:51 +08:00
parent fa024e6ac2
commit 81c8cee2c4
No known key found for this signature in database
GPG Key ID: E809D6D43DEFCC95
2 changed files with 19 additions and 14 deletions

1
.gitignore vendored
View File

@ -1,2 +1,3 @@
cmd/testserver cmd/testserver
cmd/authlibskin/config.yaml cmd/authlibskin/config.yaml
cmd/authlibskin/skin

View File

@ -158,11 +158,13 @@ function MyDialog({ open, row, setOpen, onUpdate }: MyDialogProp) {
<DialogTitle></DialogTitle> <DialogTitle></DialogTitle>
<DialogContent sx={{ <DialogContent sx={{
display: "grid", gap: '1em', gridTemplateColumns: { display: "grid", gap: '1em', gridTemplateColumns: {
md: "auto 175px",
xs: "1fr" xs: "1fr"
},
gridTemplateAreas: {
md: "'a c' 'b b'"
} }
}}> }}>
<Box sx={{ display: "flex", flexDirection: 'column', gap: '0.5em' }}> <Box sx={{ display: "flex", flexDirection: 'column', gap: '0.5em', gridArea: "a" }}>
<TextField <TextField
margin="dense" margin="dense"
label="邮箱" label="邮箱"
@ -196,19 +198,21 @@ function MyDialog({ open, row, setOpen, onUpdate }: MyDialogProp) {
return return
}))} }))}
/> />
<FormGroup>
<FormControlLabel control={<Checkbox checked={erow?.is_admin} onChange={e => setErow(produce(v => {
v.is_admin = e.target.checked
}))} />} label="管理权限" />
<FormControlLabel control={<Checkbox checked={erow?.is_disable} onChange={e => setErow(produce(v => {
v.is_disable = e.target.checked
}))} />} label="禁用" />
<FormControlLabel control={<Checkbox checked={erow?.del_textures} onChange={e => setErow(produce(v => {
v.del_textures = e.target.checked
}))} />} label="清空材质" />
</FormGroup>
</Box> </Box>
<SkinViewUUID uuid={row?.uuid ?? ""} width={175} height={175} /> <FormGroup row sx={{ gridArea: "b" }}>
<FormControlLabel control={<Checkbox checked={erow?.is_admin} onChange={e => setErow(produce(v => {
v.is_admin = e.target.checked
}))} />} label="管理权限" />
<FormControlLabel control={<Checkbox checked={erow?.is_disable} onChange={e => setErow(produce(v => {
v.is_disable = e.target.checked
}))} />} label="禁用" />
<FormControlLabel control={<Checkbox checked={erow?.del_textures} onChange={e => setErow(produce(v => {
v.del_textures = e.target.checked
}))} />} label="清空材质" />
</FormGroup>
<Box sx={{ gridArea: "c" }}>
<SkinViewUUID uuid={row?.uuid ?? ""} width={175} height={175} />
</Box>
</DialogContent> </DialogContent>
<DialogActions> <DialogActions>
<Button onClick={handleClose}></Button> <Button onClick={handleClose}></Button>