提交 017a406d 编写于 作者: Q qixian.cs@outlook.com

fix ci errot

上级 22785c32
......@@ -137,6 +137,7 @@ class SettingDarwer extends PureComponent {
parent={null}
level={null}
open={collapse}
mask={false}
onHandleClick={this.togglerContent}
handleChild={
!collapse ? (
......@@ -211,7 +212,7 @@ class SettingDarwer extends PureComponent {
<Divider />
<Body title="导航设置 ">
<Body title="其他设置 ">
<List.Item
actions={[
<Select
......
......@@ -19,15 +19,6 @@ const menuMap = {
currentUser: user.currentUser,
}))
export default class Info extends Component {
static getDerivedStateFromProps(props, state) {
const { match, location } = props;
let selectKey = location.pathname.replace(`${match.path}/`, '');
selectKey = menuMap[selectKey] ? selectKey : 'base';
if (selectKey !== state.selectKey) {
return { selectKey };
}
return null;
}
constructor(props) {
super(props);
const { match, location } = props;
......@@ -38,6 +29,15 @@ export default class Info extends Component {
mode: 'inline',
};
}
static getDerivedStateFromProps(props, state) {
const { match, location } = props;
let selectKey = location.pathname.replace(`${match.path}/`, '');
selectKey = menuMap[selectKey] ? selectKey : 'base';
if (selectKey !== state.selectKey) {
return { selectKey };
}
return null;
}
componentDidMount() {
window.addEventListener('resize', this.resize);
this.resize();
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册