|
|
@@ -1,6 +1,6 @@
|
|
|
import React, { PureComponent, createElement } from 'react';
|
|
|
import pathToRegexp from 'path-to-regexp';
|
|
|
-import { Breadcrumb, Tabs, Card } from 'antd';
|
|
|
+import { Breadcrumb, Tabs, Skeleton } from 'antd';
|
|
|
import classNames from 'classnames';
|
|
|
import styles from './index.less';
|
|
|
import { urlToList } from '../_utils/pathTools';
|
|
|
@@ -200,34 +200,36 @@ export default class PageHeader extends PureComponent {
|
|
|
activeKeyProps.activeKey = tabActiveKey;
|
|
|
}
|
|
|
return (
|
|
|
- <Card className={clsString} bodyStyle={{ padding: 0 }} loading={loading}>
|
|
|
- {breadcrumb}
|
|
|
- <div className={styles.detail}>
|
|
|
- {logo && <div className={styles.logo}>{logo}</div>}
|
|
|
- <div className={styles.main}>
|
|
|
- <div className={styles.row}>
|
|
|
- {title && <h1 className={styles.title}>{title}</h1>}
|
|
|
- {action && <div className={styles.action}>{action}</div>}
|
|
|
- </div>
|
|
|
- <div className={styles.row}>
|
|
|
- {content && <div className={styles.content}>{content}</div>}
|
|
|
- {extraContent && <div className={styles.extraContent}>{extraContent}</div>}
|
|
|
+ <div className={clsString}>
|
|
|
+ <Skeleton loading={loading}>
|
|
|
+ {breadcrumb}
|
|
|
+ <div className={styles.detail}>
|
|
|
+ {logo && <div className={styles.logo}>{logo}</div>}
|
|
|
+ <div className={styles.main}>
|
|
|
+ <div className={styles.row}>
|
|
|
+ {title && <h1 className={styles.title}>{title}</h1>}
|
|
|
+ {action && <div className={styles.action}>{action}</div>}
|
|
|
+ </div>
|
|
|
+ <div className={styles.row}>
|
|
|
+ {content && <div className={styles.content}>{content}</div>}
|
|
|
+ {extraContent && <div className={styles.extraContent}>{extraContent}</div>}
|
|
|
+ </div>
|
|
|
</div>
|
|
|
</div>
|
|
|
- </div>
|
|
|
- {tabList && tabList.length ? (
|
|
|
- <Tabs
|
|
|
- className={styles.tabs}
|
|
|
- {...activeKeyProps}
|
|
|
- onChange={this.onChange}
|
|
|
- tabBarExtraContent={tabBarExtraContent}
|
|
|
- >
|
|
|
- {tabList.map(item => (
|
|
|
- <TabPane tab={item.tab} key={item.key} />
|
|
|
- ))}
|
|
|
- </Tabs>
|
|
|
- ) : null}
|
|
|
- </Card>
|
|
|
+ {tabList && tabList.length ? (
|
|
|
+ <Tabs
|
|
|
+ className={styles.tabs}
|
|
|
+ {...activeKeyProps}
|
|
|
+ onChange={this.onChange}
|
|
|
+ tabBarExtraContent={tabBarExtraContent}
|
|
|
+ >
|
|
|
+ {tabList.map(item => (
|
|
|
+ <TabPane tab={item.tab} key={item.key} />
|
|
|
+ ))}
|
|
|
+ </Tabs>
|
|
|
+ ) : null}
|
|
|
+ </Skeleton>
|
|
|
+ </div>
|
|
|
);
|
|
|
}
|
|
|
}
|