From f9ad97b978ae4017adca032168ae7963c94e4157 Mon Sep 17 00:00:00 2001 From: Fabio Berger Date: Thu, 15 Mar 2018 19:23:21 +0100 Subject: Add Deployer docs to website --- packages/website/ts/components/sidebar_header.tsx | 1 + packages/website/ts/components/top_bar/top_bar.tsx | 19 +++++++++++++++++++ 2 files changed, 20 insertions(+) (limited to 'packages/website/ts/components') diff --git a/packages/website/ts/components/sidebar_header.tsx b/packages/website/ts/components/sidebar_header.tsx index 24bd30207..33c5ac857 100644 --- a/packages/website/ts/components/sidebar_header.tsx +++ b/packages/website/ts/components/sidebar_header.tsx @@ -7,6 +7,7 @@ const SHOW_DURATION_MS = 4000; const titleToIcon: { [title: string]: string } = { '0x.js': 'zeroExJs.png', Web3Wrapper: 'zeroExJs.png', + Deployer: 'zeroExJs.png', '0x Connect': 'connect.png', '0x Smart Contracts': 'contracts.png', Wiki: 'wiki.png', diff --git a/packages/website/ts/components/top_bar/top_bar.tsx b/packages/website/ts/components/top_bar/top_bar.tsx index ec8a69a9b..9cde5bf3f 100644 --- a/packages/website/ts/components/top_bar/top_bar.tsx +++ b/packages/website/ts/components/top_bar/top_bar.tsx @@ -145,6 +145,12 @@ export class TopBar extends React.Component { primaryText={this.props.translate.get(Key.Web3Wrapper, Deco.CapWords)} /> , + + + , ]; const bottomBorderStyle = this._shouldDisplayBottomBar() ? styles.bottomBar : {}; const fullWidthClasses = isFullWidthPage ? 'pr4' : ''; @@ -291,6 +297,14 @@ export class TopBar extends React.Component { )} + {!this._isViewingDeployerDocs() && ( + + + {this.props.translate.get(Key.Deployer, Deco.Cap)}{' '} + {this.props.translate.get(Key.Docs, Deco.Cap)} + + + )} {!this._isViewingPortal() && ( @@ -321,6 +335,7 @@ export class TopBar extends React.Component { (!this._isViewing0xjsDocs() && !this._isViewingSmartContractsDocs() && !this._isViewingWeb3WrapperDocs() && + !this._isViewingDeployerDocs() && !this._isViewingConnectDocs()) || _.isUndefined(this.props.menu) ) { @@ -412,6 +427,9 @@ export class TopBar extends React.Component { private _isViewingWeb3WrapperDocs() { return _.includes(this.props.location.pathname, WebsitePaths.Web3Wrapper); } + private _isViewingDeployerDocs() { + return _.includes(this.props.location.pathname, WebsitePaths.Deployer); + } private _isViewingWiki() { return _.includes(this.props.location.pathname, WebsitePaths.Wiki); } @@ -422,6 +440,7 @@ export class TopBar extends React.Component { this._isViewingFAQ() || this._isViewingSmartContractsDocs() || this._isViewingWeb3WrapperDocs() || + this._isViewingDeployerDocs() || this._isViewingConnectDocs() ); } -- cgit