diff --git a/src/pages/landing/jump-indices/_dBanner.js b/src/pages/landing/jump-indices/_dBanner.tsx similarity index 100% rename from src/pages/landing/jump-indices/_dBanner.js rename to src/pages/landing/jump-indices/_dBanner.tsx diff --git a/src/pages/landing/jump-indices/_dHero.js b/src/pages/landing/jump-indices/_dHero.tsx similarity index 98% rename from src/pages/landing/jump-indices/_dHero.js rename to src/pages/landing/jump-indices/_dHero.tsx index e5bd715884a..6b424f9587c 100644 --- a/src/pages/landing/jump-indices/_dHero.js +++ b/src/pages/landing/jump-indices/_dHero.tsx @@ -123,7 +123,7 @@ const StyledAnimationWrapper = styled(Flex)` ` const DHero = () => { - const animation_container = createRef() + const animation_container = createRef() useEffect(() => { const anim = lottie.loadAnimation({ container: animation_container.current, diff --git a/src/pages/landing/jump-indices/_jumpSection.js b/src/pages/landing/jump-indices/_jumpSection.tsx similarity index 100% rename from src/pages/landing/jump-indices/_jumpSection.js rename to src/pages/landing/jump-indices/_jumpSection.tsx diff --git a/src/pages/landing/jump-indices/_leverages.js b/src/pages/landing/jump-indices/_leverages.tsx similarity index 66% rename from src/pages/landing/jump-indices/_leverages.js rename to src/pages/landing/jump-indices/_leverages.tsx index f6f1e0f1a1b..16fff1e4751 100644 --- a/src/pages/landing/jump-indices/_leverages.js +++ b/src/pages/landing/jump-indices/_leverages.tsx @@ -1,8 +1,8 @@ -import React from 'react' +import React, { ReactElement } from 'react' import styled from 'styled-components' import { Flex } from 'components/containers' import { Header } from 'components/elements' -import { localize } from 'components/localization' +import { localize, Localize } from 'components/localization' import { LinkButton } from 'components/form' import device from 'themes/device.js' import TradingIcon from 'images/svg/jump-indices/jump-indices-24-7-trading.svg' @@ -80,28 +80,41 @@ const StyledLinkButton = styled(LinkButton)` padding: 11px 16px; ` +type ContentType = { + imgsrc: string + header: ReactElement + title: ReactElement +} + +const content: ContentType[] = [ + { + imgsrc: TradingIcon, + header: , + title: ( + + ), + }, + { + imgsrc: LeverageIcon, + header: , + title: ( + + ), + }, +] const Leverages = () => { return ( - - - {localize('Available 24/7')} - - {localize( - 'As jump indices are synthetics, you can trade them 24/7, 365 days of the year.', - )} - - - - - {localize('High leverage')} - - {localize( - 'Trade with high leverage ratios to have even more opportunities to increase your position size.', - )} - - + {content.map((item, index) => ( + + + {item.header} + + {item.title} + + + ))}