feat(ideContainer): ide容器增加无内容的空状态渲染,sidebar组件传入onRefresh函数

master
钟良源 4 months ago
parent a9aa38a1d0
commit 7abfe6d174

Binary file not shown.

After

Width:  |  Height:  |  Size: 12 KiB

@ -52,7 +52,7 @@ function IDEContainer() {
currPage: 1,
sceneId: urlParams.id
});
if (res.code === 200) setSubMenuData({ 'appList': res.data.list });
if (res.code === 200) setSubMenuData({ 'appList': res.data.list.reverse() });
};
useEffect(() => {
@ -98,7 +98,25 @@ function IDEContainer() {
{/* 默认内容当没有选中任何tab时显示 */}
{!selected.path && (
<div></div>
<div style={{
width: '100%',
height: '100%',
display: 'flex',
justifyContent: 'center',
alignItems: 'center',
flexDirection: 'column',
backgroundColor: '#ffffff'
}}>
<img
src={'/ideContainer/empty.png'}
/>
<span style={{
fontSize: '20px',
color: 'rgba(141, 141, 153, 1)'
}}>
</span>
</div>
)}
</div>
);
@ -197,6 +215,7 @@ function IDEContainer() {
identity={urlParams.identity}
subMenuData={subMenuData}
onMenuSelect={(select) => setSelected(select)}
onRefresh={() => getAppList()}
/>
<div className={styles.content}>
<div className={styles.mainContent}>

Loading…
Cancel
Save