Commit 1e0a8c5d authored by ι™ˆεΈ…'s avatar ι™ˆεΈ…

Delete hardcode, decouple location

parent 7cc1fccd
This diff is collapsed.
......@@ -28,12 +28,12 @@ export default class PageHeader extends PureComponent {
}
componentDidUpdate(preProps) {
const {
tabActiveKey,
location: { pathname },
} = this.props;
const { location } = this.props;
if (!location || !preProps.location) {
return;
}
const prePathname = preProps.location.pathname;
if (preProps.tabActiveKey !== tabActiveKey || prePathname !== pathname) {
if (prePathname !== location.pathname) {
this.getBreadcrumbDom();
}
}
......
......@@ -22,7 +22,7 @@
}
.tabs {
margin: 0 0 -17px -8px;
margin: 0 0 0 -8px;
:global {
.ant-tabs-bar {
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment