fix: use WebsitePaths type and update wiki link to new link
This commit is contained in:
parent
36f22ba069
commit
110d05f645
@ -14,7 +14,7 @@ import { Text } from 'ts/components/ui/text';
|
||||
import { ConfigGeneratorAddressInput } from 'ts/pages/instant/config_generator_address_input';
|
||||
import { FeePercentageSlider } from 'ts/pages/instant/fee_percentage_slider';
|
||||
import { colors } from 'ts/style/colors';
|
||||
import { WebsiteBackendTokenInfo } from 'ts/types';
|
||||
import { WebsitePaths } from 'ts/types';
|
||||
import { backendClient } from 'ts/utils/backend_client';
|
||||
import { constants } from 'ts/utils/constants';
|
||||
|
||||
@ -113,7 +113,7 @@ export class ConfigGenerator extends React.Component<ConfigGeneratorProps, Confi
|
||||
}));
|
||||
};
|
||||
private readonly _handleAffiliatePercentageLearnMoreClick = (): void => {
|
||||
window.open('/wiki#Learn-About-Affiliate-Fees', '_blank');
|
||||
window.open(`${WebsitePaths.Wiki}#Learn-About-Affiliate-Fees`, '_blank');
|
||||
};
|
||||
private readonly _handleSRASelection = (sraEndpoint: string) => {
|
||||
const newConfig: ZeroExInstantBaseConfig = {
|
||||
|
@ -7,6 +7,7 @@ import { ActionLink } from 'ts/pages/instant/action_link';
|
||||
import { CodeDemo } from 'ts/pages/instant/code_demo';
|
||||
import { ConfigGenerator } from 'ts/pages/instant/config_generator';
|
||||
import { colors } from 'ts/style/colors';
|
||||
import { WebsitePaths } from 'ts/types';
|
||||
|
||||
import { ZeroExInstantBaseConfig } from '../../../../instant/src/types';
|
||||
|
||||
@ -51,7 +52,11 @@ export class Configurator extends React.Component<ConfiguratorProps> {
|
||||
<Text fontSize="20px" lineHeight="28px" fontColor={colors.white} fontWeight={500}>
|
||||
Code Snippet
|
||||
</Text>
|
||||
<ActionLink displayText="Explore the Docs" linkSrc="/wiki#Get-Started" color={colors.grey} />
|
||||
<ActionLink
|
||||
displayText="Explore the Docs"
|
||||
linkSrc={`${WebsitePaths.Wiki}#Get-Started-With-Instant`}
|
||||
color={colors.grey}
|
||||
/>
|
||||
</Container>
|
||||
<CodeDemo key={codeToDisplay}>{codeToDisplay}</CodeDemo>
|
||||
</Container>
|
||||
|
@ -6,7 +6,7 @@ import { Image } from 'ts/components/ui/image';
|
||||
import { Text } from 'ts/components/ui/text';
|
||||
import { ActionLink, ActionLinkProps } from 'ts/pages/instant/action_link';
|
||||
import { colors } from 'ts/style/colors';
|
||||
import { ScreenWidths } from 'ts/types';
|
||||
import { ScreenWidths, WebsitePaths } from 'ts/types';
|
||||
import { utils } from 'ts/utils/utils';
|
||||
|
||||
export interface FeatureProps {
|
||||
@ -22,7 +22,7 @@ export const Features = (props: FeatureProps) => {
|
||||
};
|
||||
const exploreTheDocsLinkInfo = {
|
||||
displayText: 'Explore the docs',
|
||||
linkSrc: `${utils.getCurrentBaseUrl()}/wiki#Get-Started`,
|
||||
linkSrc: `${WebsitePaths.Wiki}#Get-Started-With-Instant`,
|
||||
};
|
||||
const tokenLinkInfos = isSmallScreen ? [getStartedLinkInfo] : [getStartedLinkInfo, exploreTheDocsLinkInfo];
|
||||
return (
|
||||
@ -41,7 +41,7 @@ export const Features = (props: FeatureProps) => {
|
||||
linkInfos={[
|
||||
{
|
||||
displayText: 'Learn about affiliate fees',
|
||||
linkSrc: `${utils.getCurrentBaseUrl()}/wiki#Learn-About-Affiliate-Fees`,
|
||||
linkSrc: `${WebsitePaths.Wiki}#Learn-About-Affiliate-Fees`,
|
||||
},
|
||||
]}
|
||||
screenWidth={props.screenWidth}
|
||||
@ -53,7 +53,7 @@ export const Features = (props: FeatureProps) => {
|
||||
linkInfos={[
|
||||
{
|
||||
displayText: 'Explore AssetBuyer',
|
||||
linkSrc: `${utils.getCurrentBaseUrl()}/docs/asset-buyer`,
|
||||
linkSrc: `${WebsitePaths.Docs}/asset-buyer`,
|
||||
},
|
||||
]}
|
||||
screenWidth={props.screenWidth}
|
||||
|
@ -14,7 +14,7 @@ import { NeedMore } from 'ts/pages/instant/need_more';
|
||||
import { Screenshots } from 'ts/pages/instant/screenshots';
|
||||
import { Dispatcher } from 'ts/redux/dispatcher';
|
||||
import { colors } from 'ts/style/colors';
|
||||
import { ScreenWidths } from 'ts/types';
|
||||
import { ScreenWidths, WebsitePaths } from 'ts/types';
|
||||
import { Translate } from 'ts/utils/translate';
|
||||
import { utils } from 'ts/utils/utils';
|
||||
|
||||
@ -67,7 +67,7 @@ export class Instant extends React.Component<InstantProps, InstantState> {
|
||||
}
|
||||
private readonly _onGetStartedClick = () => {
|
||||
if (this._isSmallScreen()) {
|
||||
utils.openUrl(`${utils.getCurrentBaseUrl()}/wiki#Get-Started`);
|
||||
utils.openUrl(`${WebsitePaths.Wiki}#Get-Started-With-Instant`);
|
||||
} else {
|
||||
this._scrollToConfigurator();
|
||||
}
|
||||
|
@ -4,7 +4,7 @@ import { Button } from 'ts/components/ui/button';
|
||||
import { Container } from 'ts/components/ui/container';
|
||||
import { Text } from 'ts/components/ui/text';
|
||||
import { colors } from 'ts/style/colors';
|
||||
import { ScreenWidths } from 'ts/types';
|
||||
import { ScreenWidths, WebsitePaths } from 'ts/types';
|
||||
import { constants } from 'ts/utils/constants';
|
||||
import { utils } from 'ts/utils/utils';
|
||||
|
||||
@ -58,5 +58,5 @@ const onGetInTouchClick = () => {
|
||||
utils.openUrl(constants.URL_ZEROEX_CHAT);
|
||||
};
|
||||
const onDocsClick = () => {
|
||||
utils.openUrl(`${utils.getCurrentBaseUrl()}/wiki#Get-Started`);
|
||||
utils.openUrl(`${WebsitePaths.Wiki}#Get-Started-With-Instant`);
|
||||
};
|
||||
|
Loading…
x
Reference in New Issue
Block a user