diff options
author | Fabio Berger <me@fabioberger.com> | 2018-03-19 02:04:16 +0800 |
---|---|---|
committer | Fabio Berger <me@fabioberger.com> | 2018-03-19 02:04:16 +0800 |
commit | 5468358f2142549c68ffae0085ce7d31ea271ea4 (patch) | |
tree | 9c7886744f85a1ed6b1ced653d9312c30d5ffda2 /packages/website/ts/components/top_bar/top_bar.tsx | |
parent | 87044313c2219f7130c1856f636f3db29b0fd1c4 (diff) | |
download | dexon-0x-contracts-5468358f2142549c68ffae0085ce7d31ea271ea4.tar dexon-0x-contracts-5468358f2142549c68ffae0085ce7d31ea271ea4.tar.gz dexon-0x-contracts-5468358f2142549c68ffae0085ce7d31ea271ea4.tar.bz2 dexon-0x-contracts-5468358f2142549c68ffae0085ce7d31ea271ea4.tar.lz dexon-0x-contracts-5468358f2142549c68ffae0085ce7d31ea271ea4.tar.xz dexon-0x-contracts-5468358f2142549c68ffae0085ce7d31ea271ea4.tar.zst dexon-0x-contracts-5468358f2142549c68ffae0085ce7d31ea271ea4.zip |
Add Subprovider docs to website
Diffstat (limited to 'packages/website/ts/components/top_bar/top_bar.tsx')
-rw-r--r-- | packages/website/ts/components/top_bar/top_bar.tsx | 33 |
1 files changed, 26 insertions, 7 deletions
diff --git a/packages/website/ts/components/top_bar/top_bar.tsx b/packages/website/ts/components/top_bar/top_bar.tsx index 66efe0d24..3a6ceed34 100644 --- a/packages/website/ts/components/top_bar/top_bar.tsx +++ b/packages/website/ts/components/top_bar/top_bar.tsx @@ -120,22 +120,28 @@ export class TopBar extends React.Component<TopBarProps, TopBarState> { primaryText={this.props.translate.get(Key.StandardRelayerApi, Deco.CapWords)} /> </a>, - <Link key="subMenuItem-web3Wrapper" to={WebsitePaths.Web3Wrapper} className="text-decoration-none"> + <Link key="subMenuItem-jsonSchema" to={WebsitePaths.JSONSchemas} className="text-decoration-none"> <MenuItem style={{ fontSize: styles.menuItem.fontSize }} - primaryText={this.props.translate.get(Key.Web3Wrapper, Deco.CapWords)} + primaryText={this.props.translate.get(Key.JsonSchemas, Deco.CapWords)} /> </Link>, - <Link key="subMenuItem-deployer" to={WebsitePaths.Deployer} className="text-decoration-none"> + <Link key="subMenuItem-subproviders" to={WebsitePaths.Subproviders} className="text-decoration-none"> <MenuItem style={{ fontSize: styles.menuItem.fontSize }} - primaryText={this.props.translate.get(Key.Deployer, Deco.CapWords)} + primaryText={this.props.translate.get(Key.Subproviders, Deco.CapWords)} /> </Link>, - <Link key="subMenuItem-jsonSchema" to={WebsitePaths.JSONSchemas} className="text-decoration-none"> + <Link key="subMenuItem-web3Wrapper" to={WebsitePaths.Web3Wrapper} className="text-decoration-none"> <MenuItem style={{ fontSize: styles.menuItem.fontSize }} - primaryText={this.props.translate.get(Key.JsonSchemas, Deco.CapWords)} + 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>, <Link key="subMenuItem-sol-cov" to={WebsitePaths.SolCov} className="text-decoration-none"> @@ -333,6 +339,14 @@ export class TopBar extends React.Component<TopBarProps, TopBarState> { </MenuItem> </Link> )} + {!this._isViewingSubprovidersDocs() && ( + <Link to={WebsitePaths.Subproviders} className="text-decoration-none"> + <MenuItem className="py2"> + {this.props.translate.get(Key.Subproviders, 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"> @@ -366,6 +380,7 @@ export class TopBar extends React.Component<TopBarProps, TopBarState> { !this._isViewingDeployerDocs() && !this._isViewingJsonSchemasDocs() && !this._isViewingSolCovDocs() && + !this._isViewingSubprovidersDocs() && !this._isViewingConnectDocs()) || _.isUndefined(this.props.menu) ) { @@ -466,6 +481,9 @@ export class TopBar extends React.Component<TopBarProps, TopBarState> { private _isViewingSolCovDocs() { return _.includes(this.props.location.pathname, WebsitePaths.SolCov); } + private _isViewingSubprovidersDocs() { + return _.includes(this.props.location.pathname, WebsitePaths.Subproviders); + } private _isViewingWiki() { return _.includes(this.props.location.pathname, WebsitePaths.Wiki); } @@ -479,7 +497,8 @@ export class TopBar extends React.Component<TopBarProps, TopBarState> { this._isViewingDeployerDocs() || this._isViewingJsonSchemasDocs() || this._isViewingSolCovDocs() || + this._isViewingSubprovidersDocs() || this._isViewingConnectDocs() ); } -} +} // tslint:disable:max-file-line-count |