Make sidebar header configurable

This commit is contained in:
Fabio Berger
2018-03-06 20:38:45 +01:00
parent 01e505a5f4
commit f8b8a10b8f
6 changed files with 57 additions and 38 deletions

View File

@@ -51,6 +51,7 @@ export interface DocumentationProps {
availableVersions: string[];
docsInfo: DocsInfo;
docAgnosticFormat?: DocAgnosticFormat;
sidebarHeader?: React.ReactNode;
sourceUrl: string;
}
@@ -109,7 +110,7 @@ export class Documentation extends React.Component<DocumentationProps, Documenta
<NestedSidebarMenu
selectedVersion={this.props.selectedVersion}
versions={this.props.availableVersions}
title={this.props.docsInfo.displayName}
sidebarHeader={this.props.sidebarHeader}
topLevelMenu={this.props.docsInfo.getMenu(this.props.selectedVersion)}
menuSubsectionsBySection={menuSubsectionsBySection}
/>