diff options
author | Fabio Berger <me@fabioberger.com> | 2018-03-16 02:23:21 +0800 |
---|---|---|
committer | Fabio Berger <me@fabioberger.com> | 2018-03-16 02:23:21 +0800 |
commit | f9ad97b978ae4017adca032168ae7963c94e4157 (patch) | |
tree | caa1165c04c66c010062ec99160ae6ba4b147917 /packages/website/ts/components | |
parent | b145a17d11a8f5ac70170b605030c42e60a4260c (diff) | |
download | dexon-0x-contracts-f9ad97b978ae4017adca032168ae7963c94e4157.tar.gz dexon-0x-contracts-f9ad97b978ae4017adca032168ae7963c94e4157.tar.zst dexon-0x-contracts-f9ad97b978ae4017adca032168ae7963c94e4157.zip |
Add Deployer docs to website
Diffstat (limited to 'packages/website/ts/components')
-rw-r--r-- | packages/website/ts/components/sidebar_header.tsx | 1 | ||||
-rw-r--r-- | packages/website/ts/components/top_bar/top_bar.tsx | 19 |
2 files changed, 20 insertions, 0 deletions
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<TopBarProps, TopBarState> { primaryText={this.props.translate.get(Key.Web3Wrapper, Deco.CapWords)} /> </Link>, + <Link key="subMenuItem-deployer" to={WebsitePaths.Deployer} className="text-decoration-none"> + <MenuItem + style={{ fontSize: styles.menuItem.fontSize }} + primaryText={this.props.translate.get(Key.Deployer, Deco.CapWords)} + /> + </Link>, ]; const bottomBorderStyle = this._shouldDisplayBottomBar() ? styles.bottomBar : {}; const fullWidthClasses = isFullWidthPage ? 'pr4' : ''; @@ -291,6 +297,14 @@ export class TopBar extends React.Component<TopBarProps, TopBarState> { </MenuItem> </Link> )} + {!this._isViewingDeployerDocs() && ( + <Link to={WebsitePaths.Deployer} className="text-decoration-none"> + <MenuItem className="py2"> + {this.props.translate.get(Key.Deployer, Deco.Cap)}{' '} + {this.props.translate.get(Key.Docs, Deco.Cap)} + </MenuItem> + </Link> + )} {!this._isViewingPortal() && ( <Link to={`${WebsitePaths.Portal}`} className="text-decoration-none"> <MenuItem className="py2"> @@ -321,6 +335,7 @@ export class TopBar extends React.Component<TopBarProps, TopBarState> { (!this._isViewing0xjsDocs() && !this._isViewingSmartContractsDocs() && !this._isViewingWeb3WrapperDocs() && + !this._isViewingDeployerDocs() && !this._isViewingConnectDocs()) || _.isUndefined(this.props.menu) ) { @@ -412,6 +427,9 @@ export class TopBar extends React.Component<TopBarProps, TopBarState> { 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<TopBarProps, TopBarState> { this._isViewingFAQ() || this._isViewingSmartContractsDocs() || this._isViewingWeb3WrapperDocs() || + this._isViewingDeployerDocs() || this._isViewingConnectDocs() ); } |