diff options
-rw-r--r-- | packages/0x.js/CHANGELOG.json | 2 | ||||
-rw-r--r-- | packages/0x.js/README.md | 2 | ||||
-rw-r--r-- | packages/dev-utils/CHANGELOG.json | 2 | ||||
-rw-r--r-- | packages/dev-utils/CHANGELOG.md | 2 | ||||
-rw-r--r-- | packages/web3-wrapper/README.md | 2 | ||||
-rw-r--r-- | packages/website/ts/components/top_bar/top_bar.tsx | 12 | ||||
-rw-r--r-- | packages/website/ts/index.tsx | 13 | ||||
-rw-r--r-- | packages/website/ts/types.ts | 9 |
8 files changed, 33 insertions, 11 deletions
diff --git a/packages/0x.js/CHANGELOG.json b/packages/0x.js/CHANGELOG.json index 6d5dc0dd2..96bef0ebe 100644 --- a/packages/0x.js/CHANGELOG.json +++ b/packages/0x.js/CHANGELOG.json @@ -13,7 +13,7 @@ "changes": [ { "note": - "Removed `ZeroExError.TransactionMiningTimeout` and moved it to '@0xproject/web3_wrapper' `Web3WrapperErrors.TransactionMiningTimeout`", + "Removed `ZeroExError.TransactionMiningTimeout` and moved it to '@0xproject/web3-wrapper' `Web3WrapperErrors.TransactionMiningTimeout`", "pr": 485 } ], diff --git a/packages/0x.js/README.md b/packages/0x.js/README.md index 46848cbdd..f507516c4 100644 --- a/packages/0x.js/README.md +++ b/packages/0x.js/README.md @@ -2,7 +2,7 @@ A TypeScript/Javascript library for interacting with the 0x protocol. -### Read the [Documentation](0xproject.com/docs/0xjs). +### Read the [Documentation](0xproject.com/docs/0x.js). ## Installation diff --git a/packages/dev-utils/CHANGELOG.json b/packages/dev-utils/CHANGELOG.json index 64ef4b000..a9e8e5a4a 100644 --- a/packages/dev-utils/CHANGELOG.json +++ b/packages/dev-utils/CHANGELOG.json @@ -24,7 +24,7 @@ "note": "Reduce npm package size by adding an `.npmignore` file." }, { - "note": "Move `@0xproject/web3_wrapper` to dependencies from devDependencies." + "note": "Move `@0xproject/web3-wrapper` to dependencies from devDependencies." } ], "timestamp": 1521298800 diff --git a/packages/dev-utils/CHANGELOG.md b/packages/dev-utils/CHANGELOG.md index 2e3953750..1f8062693 100644 --- a/packages/dev-utils/CHANGELOG.md +++ b/packages/dev-utils/CHANGELOG.md @@ -16,7 +16,7 @@ CHANGELOG ## v0.3.1 - _March 17, 2018_ * Reduce npm package size by adding an `.npmignore` file. - * Move `@0xproject/web3_wrapper` to dependencies from devDependencies. + * Move `@0xproject/web3-wrapper` to dependencies from devDependencies. ## v0.3.0 - _March 17, 2018_ diff --git a/packages/web3-wrapper/README.md b/packages/web3-wrapper/README.md index 1ff85420a..480684c7b 100644 --- a/packages/web3-wrapper/README.md +++ b/packages/web3-wrapper/README.md @@ -2,7 +2,7 @@ Wrapped version of web3 with a nicer interface that is used across 0x projects and packages. -### Read the [Documentation](0xproject.com/docs/web3_wrapper). +### Read the [Documentation](0xproject.com/docs/web3-wrapper). ## Installation diff --git a/packages/website/ts/components/top_bar/top_bar.tsx b/packages/website/ts/components/top_bar/top_bar.tsx index 4b2e82119..13351dcdc 100644 --- a/packages/website/ts/components/top_bar/top_bar.tsx +++ b/packages/website/ts/components/top_bar/top_bar.tsx @@ -15,7 +15,7 @@ import { TopBarMenuItem } from 'ts/components/top_bar/top_bar_menu_item'; import { DropDown } from 'ts/components/ui/drop_down'; import { Identicon } from 'ts/components/ui/identicon'; import { Dispatcher } from 'ts/redux/dispatcher'; -import { Deco, Key, ProviderType, WebsitePaths } from 'ts/types'; +import { Deco, Key, ProviderType, WebsiteLegacyPaths, WebsitePaths } from 'ts/types'; import { constants } from 'ts/utils/constants'; import { Translate } from 'ts/utils/translate'; @@ -462,7 +462,10 @@ export class TopBar extends React.Component<TopBarProps, TopBarState> { return _.includes(this.props.location.pathname, WebsitePaths.FAQ); } private _isViewing0xjsDocs() { - return _.includes(this.props.location.pathname, WebsitePaths.ZeroExJs); + return ( + _.includes(this.props.location.pathname, WebsitePaths.ZeroExJs) || + _.includes(this.props.location.pathname, WebsiteLegacyPaths.ZeroExJs) + ); } private _isViewingConnectDocs() { return _.includes(this.props.location.pathname, WebsitePaths.Connect); @@ -471,7 +474,10 @@ export class TopBar extends React.Component<TopBarProps, TopBarState> { return _.includes(this.props.location.pathname, WebsitePaths.SmartContracts); } private _isViewingWeb3WrapperDocs() { - return _.includes(this.props.location.pathname, WebsitePaths.Web3Wrapper); + return ( + _.includes(this.props.location.pathname, WebsitePaths.Web3Wrapper) || + _.includes(this.props.location.pathname, WebsiteLegacyPaths.Web3Wrapper) + ); } private _isViewingDeployerDocs() { return _.includes(this.props.location.pathname, WebsitePaths.Deployer); diff --git a/packages/website/ts/index.tsx b/packages/website/ts/index.tsx index d542bd804..5bc36da32 100644 --- a/packages/website/ts/index.tsx +++ b/packages/website/ts/index.tsx @@ -15,7 +15,7 @@ import { createLazyComponent } from 'ts/lazy_component'; import { trackedTokenStorage } from 'ts/local_storage/tracked_token_storage'; import { tradeHistoryStorage } from 'ts/local_storage/trade_history_storage'; import { reducer, State } from 'ts/redux/reducer'; -import { WebsitePaths } from 'ts/types'; +import { WebsiteLegacyPaths, WebsitePaths } from 'ts/types'; import { analytics } from 'ts/utils/analytics'; import { muiTheme } from 'ts/utils/mui_theme'; import { utils } from 'ts/utils/utils'; @@ -98,6 +98,17 @@ render( path={`${WebsitePaths.SmartContracts}/:version?`} component={LazySmartContractsDocumentation} /> + + {/* Legacy endpoints */} + <Route + path={`${WebsiteLegacyPaths.ZeroExJs}/:version?`} + component={LazyZeroExJSDocumentation} + /> + <Route + path={`${WebsiteLegacyPaths.Web3Wrapper}/:version?`} + component={LazyWeb3WrapperDocumentation} + /> + <Route component={NotFound as any} /> </Switch> </div> diff --git a/packages/website/ts/types.ts b/packages/website/ts/types.ts index dba59f704..c03e5676f 100644 --- a/packages/website/ts/types.ts +++ b/packages/website/ts/types.ts @@ -341,17 +341,22 @@ export enum Docs { SmartContracts, } +export enum WebsiteLegacyPaths { + ZeroExJs = '/docs/0xjs', + Web3Wrapper = '/docs/web3_wrapper', +} + export enum WebsitePaths { Portal = '/portal', Wiki = '/wiki', - ZeroExJs = '/docs/0xjs', + ZeroExJs = '/docs/0x.js', Home = '/', FAQ = '/faq', About = '/about', Whitepaper = '/pdfs/0x_white_paper.pdf', SmartContracts = '/docs/contracts', Connect = '/docs/connect', - Web3Wrapper = '/docs/web3_wrapper', + Web3Wrapper = '/docs/web3-wrapper', Deployer = '/docs/deployer', JSONSchemas = '/docs/json-schemas', SolCov = '/docs/sol-cov', |