fix(striker-ui): auto handle inner panel header vertical spacing

main
Tsu-ba-me 3 years ago
parent ca5c0becf7
commit fbac65857d
  1. 1
      striker-ui/components/Hosts/AnvilHost.tsx
  2. 5
      striker-ui/components/Panels/InnerPanelHeader.tsx
  3. 1
      striker-ui/components/SharedStorage/SharedStorageHost.tsx

@ -31,7 +31,6 @@ const StyledBox = styled(Box)(({ theme }) => ({
[`& .${classes.state}`]: { [`& .${classes.state}`]: {
paddingLeft: '.7em', paddingLeft: '.7em',
paddingRight: '.7em', paddingRight: '.7em',
paddingTop: '2.2em',
}, },
[`& .${classes.bar}`]: { [`& .${classes.bar}`]: {

@ -7,6 +7,7 @@ const InnerPanelHeader: FC = ({ children }) => (
<Box sx={{ position: 'relative', whiteSpace: 'pre-wrap' }}> <Box sx={{ position: 'relative', whiteSpace: 'pre-wrap' }}>
<Box <Box
sx={{ sx={{
alignItems: 'center',
borderColor: DIVIDER, borderColor: DIVIDER,
borderRadius: BORDER_RADIUS, borderRadius: BORDER_RADIUS,
borderStyle: 'solid', borderStyle: 'solid',
@ -31,13 +32,13 @@ const InnerPanelHeader: FC = ({ children }) => (
</Box> </Box>
<Box <Box
sx={{ sx={{
display: 'flex',
paddingBottom: '.4em', paddingBottom: '.4em',
paddingRight: '1.7em', paddingRight: '1.7em',
width: '100%',
visibility: 'hidden', visibility: 'hidden',
}} }}
> >
{children instanceof Array ? children[0] : children} {children}
</Box> </Box>
</Box> </Box>
); );

@ -16,7 +16,6 @@ const StyledDiv = styled('div')(() => ({
[`& .${classes.fs}`]: { [`& .${classes.fs}`]: {
paddingLeft: '.7em', paddingLeft: '.7em',
paddingRight: '.7em', paddingRight: '.7em',
paddingTop: '2.2em',
}, },
[`& .${classes.bar}`]: { [`& .${classes.bar}`]: {

Loading…
Cancel
Save