Merge pull request #15689 from ant-design/page-hader-breadcrumb

support level 2 breadcrumb
This commit is contained in:
偏右 2019-03-27 18:20:37 +08:00 committed by GitHub
commit 331dfb2a9b
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -51,7 +51,7 @@ const renderBreadcrumb = (breadcrumb: BreadcrumbProps) => {
const renderHeader = (prefixCls: string, props: PageHeaderProps) => {
const { breadcrumb, backIcon, onBack } = props;
if (breadcrumb && breadcrumb.routes && breadcrumb.routes.length > 2) {
if (breadcrumb && breadcrumb.routes && breadcrumb.routes.length >= 2) {
return renderBreadcrumb(breadcrumb);
}
return renderBack(prefixCls, backIcon, onBack);