style(ideContainer): 修改侧边栏样式和布局

master
钟良源 5 months ago
parent 6a3721deb4
commit 8163646aa8

@ -671,7 +671,7 @@ const FlowEditor: React.FC = () => {
panOnScrollSpeed={0.5} panOnScrollSpeed={0.5}
> >
<Background /> <Background />
<Controls /> {/*<Controls />*/}
<Panel position="top-left"> <Panel position="top-left">
<div></div> <div></div>
<Button onClick={saveFlowDataToServer} type="primary"></Button> <Button onClick={saveFlowDataToServer} type="primary"></Button>

@ -106,7 +106,7 @@ const SideBar: React.FC<SideBarProps> = ({ onMenuSelect, selectedKey, identity }
return ( return (
<div <div
className={styles.sider} className={styles['sider']}
> >
<div className={styles['menu-container']}> <div className={styles['menu-container']}>
{menu.map((item, index) => ( {menu.map((item, index) => (
@ -135,13 +135,9 @@ const SideBar: React.FC<SideBarProps> = ({ onMenuSelect, selectedKey, identity }
}} }}
onMoving={handleSubMenuResize} onMoving={handleSubMenuResize}
> >
<div style={{ <div
width: '100%', className={styles['sub-menu']}
height: '100%', >
backgroundColor: '#f5f5f5',
borderRight: '1px solid #ddd',
position: 'relative'
}}>
<Tree <Tree
defaultExpandedKeys={['0-0']} defaultExpandedKeys={['0-0']}
onSelect={(_selectedKeys, info) => { onSelect={(_selectedKeys, info) => {

@ -6,6 +6,7 @@
background-color: var(--color-bg-2); background-color: var(--color-bg-2);
} }
.menu-container {
.menu-item { .menu-item {
padding: 12px 4px; padding: 12px 4px;
text-align: center; text-align: center;
@ -24,14 +25,12 @@
background-color: var(--color-fill-2); background-color: var(--color-fill-2);
color: rgb(var(--primary-6)); color: rgb(var(--primary-6));
} }
}
.menu-item-content { .menu-item-content {
display: flex; display: flex;
flex-direction: column; flex-direction: column;
align-items: center; align-items: center;
width: 100%; width: 100%;
}
.menu-item-icon { .menu-item-icon {
display: flex; display: flex;
@ -53,3 +52,15 @@
width: 100%; width: 100%;
padding: 0 5px; padding: 0 5px;
} }
}
}
}
.sub-menu {
width: 100%;
height: 100%;
background-color: #fcfcfc;
border-right: 1px solid #ddd;
position: relative;
border-left: 1px solid #ddd;
}
Loading…
Cancel
Save